jcadima
12/15/2019 - 6:59 AM

Vim search and replace globally


https://stackoverflow.com/questions/19994922/find-and-replace-strings-in-vim-on-multiple-lines

Find each occurrence of 'foo' (in all lines), and replace it with 'bar'.
:%s/foo/bar/g


For specific lines:
:6,10s/foo/bar/g