Vim Cheatsheet
Start & Quit
vim file " open file
:n " go to line n
:w " write (save)
:w filename " save as
:q " quit
:q! " quit without saving
:wq / :x " write and quit
:wa " write all buffers
:qa " quit allModes & Inserts
i " insert before cursor
I " insert at line start
a " append after cursor
A " append at line end
o / O " open new line below/above
s / S " substitute char / whole line
cc / C " change line / to EOL
R " replace (overwrite) mode
Esc " back to Normal modeMovement (Normal Mode)
Find Characters (on line)
Select (Visual)
Edit: Delete / Change / Yank (Copy) / Put (Paste)
Counts & Repeats
Indent & Format
Search & Replace
Buffers, Tabs & Windows
Marks & Jumps
Registers & System Clipboard
Macros
Files, Explore, and Info
Folding (built-in)
Useful Settings (put in vimrc)
Command-Line Fu
Quick Reference Table
Last updated