Sunday, February 3, 2013

Search in Vim


On a single line you can use fo and then ; to go forward (or , backward).
On multiple line, you must use /o and then n to go forward (or N backward).
Alternatively, your problem might be solved by using regexp and substitute, ie :%s/[your odd character]//g
To manage to copy and paste your "odd character", you should go in visual using v to select the character, then y<ESC>.
Then type : :%s/<CTRL+r>"//g
<CTRL+r>" will copy the content of the copy register in the command line.

No comments:

Post a Comment