Skip to content

Latest commit

 

History

History
22 lines (15 loc) · 453 Bytes

tip5.md

File metadata and controls

22 lines (15 loc) · 453 Bytes

Tip5: Find and Replace by Hand

Search 'target' and replace all the 'target'

:%s/target/replacemnet/g

But one by one?

/target

search document for next match.

*

execute a search for the word under the cursor at that moment.

*nn

cycle through all matches, taking us back to where we started.

cw

delete to the end of the word and drop us into Insert mode.

Example

tip5