Install my vimrc -O ~/.vimrc

Force sudo on save

:w !sudo tee %

or if you have my .vimrc just use


Editing multiples columns using visual mode

Press CTRL+v to select multiples columns or lines.

Then press I and type what you want to insert in all selection then press ESC.

Search and Replace

To search just press / and type what you want to find

To replace all:


If you wanna to replace only a block of lines:

:set nu

Then get the first line you want to replace and the last line then:

:10,30 s/foo/bar/g

The /g is to replace multiple times.



Will replace "foo foo foo"  to "bar foo foo"

Using /g will replace it all.


Will replace "foo foo foo"  to "bar bar bar"

Protected: Cisco Tips

This content is password protected. To view it please enter your password below: