Annexure C: Vim Commands

Basic Navigation

CommandDescription
h, j, k, lMove left, down, up, right.
0Move to the beginning of the line.
$Move to the end of the line.
ggMove to the beginning of the file.
GMove to the end of the file.

Editing

CommandDescription
iEnter insert mode.
EscExit insert mode.
xDelete a character.
ddDelete a line.
yyCopy a line.
pPaste copied text.
uUndo the last change.
Ctrl + rRedo the last change.

Saving And Exiting

CommandDescription
:wSave the file.
:qQuit Vim.
:wqSave and quit.
:q!Quit without saving.

Prev: Annexure B | Next: Annexure D