O'Reilly logo

Mastering Vim by Ruslan Osipov

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Keeping .vimrc organized

If you use and customize Vim a lot, your .vimrc file tends to grow rather quickly, and it's important to make it easy to navigate. If you ever take a break from working with your .vimrc and come back later, you'll thank yourself.

Comments are crucial for making sure you remember what's going on. If you take just one thing from this chapter, make sure it is comments. Just like when working with code, comments save you wasting time trying to understand what's going on.

I try to make a point of documenting every configuration bit with a corresponding comment:

" Show last command in the status line.set showcmd" Highlight cursor line.set cursorline" Ruler (line, column and % at the right bottom).set ruler" Display line ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required