okz0ea
Last Updated: February 25, 2016
·
2.105K
· abhishek77in
Profile pic

vim: avoid typos

vim

Quickly check for variable across file and avoid typo by pressing * over your variable in normal mode.

make sure you have set hlsearch in your vimrc
or do :set hlsearch in command-line mode

note: * searches forward for the next occurrence of that word, and # searches backwards.

tip: place :nnoremap <CR> :nohlsearch<cr> in your vimrc to remove highlighting on hitting return/enter key

Say Thanks
Respond