These are my favorite Vim plugins of 2014 ranked in no particular order.
Multiple Cursors
vim-multiple-cursors lets you select and edit multiple words at once. Very convenient for renaming variables. Coming from Sublime Text 2 this was one feature I couldn’t live without.
Exchange
vim-exchange makes it easy to exchange
text from one place to an other.
I always found myself copying and pasting text and it usually took twice as long
because I would accidentally overwrite my yanked text with the dw command. Now I
can simply cxw on the first text and cxw
to swap them.
Targets
targets.vim improves upon the “change inside brackets/quotes” functionality. You can change text inside a pair of brackets without being on the same line. Can change inside commas, pluses and more. A recent update now lets you quickly change arguments of methods.
I originally thought the plugin wasn’t too useful and I don’t like overwriting vim functionality but installed it anyway. It quickly became one of my favorites.
Smart gf
smeatgf.vim adds a command for
quick method lookup. When you come across a method you are not familiar with,
you can gf
on the word to find the definition.
Super Tab
supertab allows you to use
Indent Object
vim-indent-object implements a
new selector based on indentation. This is very useful for moving around blocks
of code or re-indenting pasted text and it’s not possible to use
yap
.
One of my most used plugins.
Qargs
vim-qargs lets you invoke a command on all items in a quickfix menu. I use this with ack.vim to do a global search & replace.
Sneak
vim-sneak implements a minimalist motion that jumps to any location specified by two characters. It searches through the whole file and can jump through matches.
Surround
vim-surround implements a surround
function which lets you add, change or remove brackets/quotes from objects. Add brackets to a word with yswb
. Take then away with
dsb
.
Highly recommended, this plugin is vital for productivity.
Operator Gsearch
vim-operator-gsearch implements a shortcut (g/) that grabs the text you motioned and searches with that in ack or whatever you have setup. This speeds up my workflow by not having to type in anything.
Ctrlp
ctrlp.vim is a full-path fuzzy file, buffer, most recently used and tag finder. Hit ctrlP, type in the wanted file and select it.
I use this all the time. The given search engine isn’t very efficient, so I replaced it with ag. Here is my script:
It’s so fast cache can be turned off and will also respect your .gitignore files.
Tcomment
tcomment.vim provides an easy to use, file-type sensible commenter. Being able to quickly comment out paragraphs, lines and anything with a motion is very useful.
I usually couple this with the indenter plugin to quickly comment out if
statements. (gcaI
.)
Colorschemes
vim-colorschemes adds plenty of awesome colorschemes. I added leader shortcuts to quickly switch between some of my favorite colorschemes.
Scratch
scratch.vim adds a scratch window for notes and hides when inactive. I use this for writing up a small todo list.