7 ms·
Woah, how did I not know about that tip about omitting the search pattern? Love it and will be using that lots! As a thank you, I'll leave you with the way I l
by pigcat 11mo ago
Woah, how did I not know about that tip about omitting the search pattern? Love it and will be using that lots!
As a thank you, I'll leave you with the way I learned to search/replace, just to give you a slightly different flavour: asterisk, cgn ([c]hange [g]o [n]ext), type replaced, then . (period, to repeat) until I'm done.
- wuhhh 11mo agoRight back at you, that’s super neat!
- whatevertrevor 11mo agoLet me add my third way of doing this in vim: :%s/<CTRL-R><CTRL-W>/replacement/(gcn) As you can guess <CTRL-W> invokes a special register that contains the "word" currently under the cursor.