Vim Useful Tricks
source link: https://iiiyu.com/2021/06/15/vim-useful-tricks/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
Vim Useful Tricks
Hi everyone. Today I want to share a vim trick.
It’s very useful when I was coding every day.
So hope you like it.
Problem
I have those situation every day. I want to change ‘target’. So how can I do?
foo target boo
foo "target target"
foo 'target target'
foo (target target)
foo {target target}
foo [target target]
foo <target target>
foo <div>target target</div>
This article is very subjective. If you do not feel comfortable viewing it, please close it as soon as possible.
If you think my article can help you, you can subscribe to this site by using RSS.
ci anything
We can use ci
combining commands.
When your cursor on ‘target’ this word. We can use
ciw
foo target boo
ci"
foo "target target"
ci'
foo 'target target'
ci(
foo (target target)
ci{
foo {target target}
ci[
foo [target target]
ci<
foo <target target>
cit
foo <div>target target</div>
Referrals
Photo by Pankaj Patel on Unsplash
Vim Useful Tricks
Ewan Xiao
June 15th 2021
January 5th 2022
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK