Last active
August 29, 2015 14:10
-
-
Save juaniyyoo/4ae87608374cf1c84e55 to your computer and use it in GitHub Desktop.
Vim CheatSheet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# VIM : | |
## Command mode : | |
gf : Go to file | |
>i{ : Indent within { | |
>a{ : Indent with { | |
dap : Delete Outter paragraph | |
dip : Delete inner paragraph | |
ye : Yank to the end of the current word | |
* : Look for the current word in the document | |
n : Keep searching forward | |
N : Keep searching backward | |
Ctrl + w : Go to window mode | |
Ctrl + v : Go to view mode | |
Ctrl + g : Diplay opened file | |
:buffers : Display buffers | |
:bn : Go to next buffer | |
:bp : Go to previous buffer | |
:bd : Close buffer | |
:sp : Split screen horizontally | |
:vsp : Split screen vertically | |
:regiters : Display registers | |
:<number> : Go to the line number <number> | |
:saveas : Save file with a new name | |
:e : Reload file | |
:w : Save | |
:w! : Save (force) | |
:q : Quit | |
:q! : Quit (force) | |
:wq : Save + Quit | |
:wq! : Save + Quit (force) | |
:qa : Quit all | |
:e <file> : Open file | |
:s/regex// : Replace on the current line | |
:%s/regex// : Replace over all the document | |
:<n>,<m>s/// : Replace from line <n> to line <m> | |
:d/regex/g : Remove line over all the document | |
## Insert mode : | |
Ctrl + r : Access the registers to paste |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment