Skip to content

Instantly share code, notes, and snippets.

@ericvanjohnson
Created July 24, 2012 00:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ericvanjohnson/3167097 to your computer and use it in GitHub Desktop.
Save ericvanjohnson/3167097 to your computer and use it in GitHub Desktop.
VI Tricks
# List of useful Vim tricks. Most taken from @vimtips on Twitter
# CTRL-w | and CTRL-W _ maximize your current split vertically and horizontally, respectively. CTRL-W = equalizes 'em CTRL-w s CTRL-w T will open current buffer in new tab (via @vrybas_)
# qa starts a recording in register 'a'. q stops it. @a repeats the recording. 5@a repeats it 5 times.
# Comment out lines containing _pattern_ (if '#' is your comment character/sequence) (via @vrybas_)
:g/_pattern_/s/^/#/g
# re-tab all files in the buffers list.
:tab sball
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment