Skip to content

Instantly share code, notes, and snippets.

@jesperbjensen
Created July 23, 2011 12:10
Show Gist options
  • Save jesperbjensen/1101357 to your computer and use it in GitHub Desktop.
Save jesperbjensen/1101357 to your computer and use it in GitHub Desktop.
vim-cheats
Using Vim settings from https://github.com/carlhuda/janus
:ls List open buffers
Ctrl+w c Closes the current window
o Begin a new line below the current one
:/searchterm Searches for the search word. Use n and N to move back
and forth
:map KEY COMMAND Creates a new command. Use <Leader> to choose the leader
key and <Enter> to execute it, for exsample.
H or M or L Moves to the first, middle or last line on screen.
:wa Save all changed files
vi<Char> Selected everything between two of the chars. Like 'inside this line'
va<Char> Like above, but instead its around of the Char
vib Selected everything between ( and )
viB Selects everthing between { and } (see more here :help
text-objects)
:noh Clears the search highlighting
Ctrl+R Redo
:split Splits a window horizontaly
:vsplit Splits a window verticaly
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment