Show Menu
Cheatography

nvim cheat sheets Cheat Sheet by

NeoVim cheat sheets best

Motions

Command
Descri­ption
h
Left
j
Down
k
Up
l
Right

Edition

Command
Descri­ption
yy
Copy line
yyp
Duplicate current line
yw
Copy word
nºy
Copy the nº of lines
cw
Change word
dd
Delete line
daw
Delete a word
dip/dap
Delete all lines up to the next blank line (parag­raph)
L
End of file
H
Start of file
M
Half of file
xp
Invert two characters
u
Undo changes
C-r
Redo changes

Comment

Command
Descri­ption
gcc
Comments on the current line
gbc
Add block comment
nºgcc
Comments the number of lines
gcw
Comments a word
gc$
Comments from the cursor at end of line
gc}
Comments until the next blank line
gca}
Comments around curly brackets {}
gcip
Comments inside of paragraph
gcnº[j/k]
Toggle nº lines after or before the cursor

Others

Command
Descri­ption
 
 
 
 

Cursor

Command
Descri­ption
o
Insert cursor below
O
Insert cursor above
i
Insert cursor left
I
Insert cursor start line
a
Insert cursor right
A
Insert cursor end line
^
Start of line
$
End of line
G
Move to end of file
gg
Move to start of file
nºG
Move to line number nº

Personal

Command
Descri­ption
<le­ade­r>r
replace the current word in the entire file
<le­ade­r>t
Open the terminal
<le­ade­r>ff
Open find files
<le­ade­r>fg
Open find files globally
<le­ade­r>fb
List all buffers
<le­ade­r>ps
Open grep command for search files

Visual

Command
Descri­ption
J
Move the selected line(s) below
K
Move the selected line(s) above
vaw/viw
Select a word
vas
Select the sentence
vap
Select the paragraph
ggVG
Select all file

Shortcuts

Command
Descri­ption
C-b
:Ex
:R
Close Explor­e(:Ex)
tr
:bp
ty
:bn
td
:bd

Buffers

Command
Descri­ption
:db
Delete buffer
:ls
List buffers
:buffer nº
Jump to the buffer nº
:bn
Next buffer
:bp
Previous buffer
 

Commands

Command
Descri­ption
:Ex
Open tree files
%
Create a new file
d
Create a new directory
:w
Save file
:q
Quit
:wa
Save all buffers
:tabe
Create a new tab
/[word]
Search in file
n
Next
N
Previous
:move +nº
Move the line nº below
:move -nº
Move the line nº above
:%s/ol­d/new/g
Replace word in file globally
:!
Execute a command (terminal)
:r!
Executes the command and inserts the result into the file
:sav
Saves in a new file
:so
Runs Ex-com­mands or ".lu­a" files from file

Git Conflict

Command
Descri­ption
co
Choose ours
ct
Choose theirs
cb
Choose Both
c0
Choose none
]x
Move to previous conflict
[x
Move to next conflict

Split and Tabs

Command
Descri­ption
:sp
Split window horizo­ntally
:vsp
Split window vertically
:tabe
Create a new tab
:tabc
Close current tab
:tabn
Next tab
:tabp
Previous tab

Others

Command
Descri­ption
 
 
 
 
 
   
 

Comments

No comments yet. Add yours below!

Add a Comment

Your Comment

Please enter your name.

    Please enter your email address

      Please enter your Comment.

          Related Cheat Sheets

          Sublime Text 2 Windows Keyboard Shortcuts
          Wikipedia Cheat Sheet
          Vim NERDTree Cheat Sheet