ViM: vimrc

vimrc is the configuration file used by ViM. It is typically ~/.vimrc in Linux and C:\Program Files\Vim\vimrc in Windows. I currently use ViM across 3 computers with both Windows and Linux. I have my custom vimrc file which works across all these setups.

I like to keep my vimrc under source control (currently Mercurial). To make this convenient and have a single copy across partitions, I replace the default ~/.vimrc or C:\Program Files\Vim\vimrc with the following text:

source C:\FoobarRep\vimrc

Here, C:\FoobarRep\ is the directory of my repository where vimrc resides. For Linux, use the mounted path of the same directory.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.