VIM commands - Server Admin must always remember



           VIM  ( vi improved) is a powerful text editor which is more sophisticated than gedit . Also , unlike gedit, you can always expect vim to be available in any Linux system.The vim editor supports  sophisticated text manipulation which are very useful for system administration. In fact, if you are familiar with the vi utility, you will find that vim includes vi features, plus many other features such as split screen editing , color formatting of known file types, and text highlighting for copying and changing text , to name a few.

VIM Operations :
- Open a file  -> vim filename
- Insert mode  -> i
- Return to command mode  -> Esc
- To save the file -> w
-  To save and quit  -> wq
- Quit , abandoning changes (from ex mode)  ->q!
- Undo changes  -> u
- Quit file  -> q
- Set the line number  ->: set nu
- Unset the line number  ->set nonu
- Copy  ->yy
- Paste  ->p
-  Delete a line  -> dd
- Delete a word  -> dw
- To search a particular work within a file ->  /
- To go to the given line number  -> Line no: + Shift + g

Comments