VIM Best tips and tricks
Original author - http://rayninfo.co.uk/vimtips.html *vimtips.txt* For Vim version 7.3. ------------------------------------------------------------------------------ " new items marked [N] , corrected items marked [C] " *best-searching* /joe/e : cursor set to End of match 3/joe/e+1 : find 3rd joe cursor set to End of match plus 1 [C] /joe/s-2 : cursor set to Start of match minus 2 /joe/+3 : find joe move cursor 3 lines down /^joe.*fred.*bill/ : find joe AND fred AND Bill (Joe at start of line) /^[A-J]/ : search for lines beginning with one or more A-J /begin\_.*end : search over possible multiple lines /fred\_s*joe/ : any whitespace including newline [C] /fred\|joe : Search for FRED OR JOE /.*fred\&.*joe : Search for FRED AND JOE in any ORDER! /\<fred\>/ : search for fred but not alf...