vi
goto line
:12 ENTER
search and replace
:%s/foo/bar/g
view hidden chars
:set list
:set nolist
reformat tabs to 4 spaces
:set tabstop=4 expandtab
:retab 4
# convert endline
:set ff=unix
:set ff=dos
# vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4 textwidth=75
# quit
:q!
:qc
# include file
:r /path/to/file
Links
http://www.lagmonster.org/docs/vi2.html
http://vim.wikia.com/wiki/Search_and_replace