Spyderserve Web Development

Quick Notes on vim

:g/dog/d

This will find each line that has a specific string (in this case dog) and delete it

:%s/foo/bar/g

This will replace all instances of a specific string (in this case foo) with another string (bar). The % makes it search all lines instead of just the current line.  The g can be swapped out for gc if you would like to confirm on each instance.

 

Spyderserve  PO Box 5831 Valdosta, Georgia 31603 United States