Vim — Most used commands for efficient text editing
Movement commands
Vim is known for fast navigation. Common movement keys:
Note: For uppercase letters, hold Shift.
h: leftj: downk: upl: rightw: next wordb: previous word0: start of line$: end of linegg: start of fileG: end of fileCtrl+f: next pageCtrl+b: previous page
Editing commands
i: insert before cursorI: insert at start of linea: insert after cursorA: insert at end of lineo: new line below and insertO: new line above and insertr: replace character under cursors: delete char and insertx: delete char under cursordw: delete worddd: delete lineyy: yank (copy) linep: paste after cursoru: undoCtrl+r: redo
Save and quit
:w: write (save):q: quit:wq: write and quit:q!: quit without saving
Vim is a powerful, customizable editor that can significantly improve your efficiency.