vim: find and replace
- Search for a word:
/foo
- Change the next match: type
cgn
, write your replacement, then press<Esc>
- Repeat or skip:
- Press
.
to repeat the change on the next match - Press
n
to skip to the next match without changing it
- Press
✌🏼 Like my content? Subscribe via RSS feed.