I have installed vim by

sudo apt-get install vim

Now I want to customize it, but there are two vimrc files – one in /etc, second is in /usr/share folder. Both have a vimrc file.

Why are there two vim folders and which one should I use?

link|improve this question

79% accept rate
feedback

1 Answer

up vote 9 down vote accepted

Neither. You want to create a new file, .vimrc – notice the dot at the beginning – and place it in your $HOME (/home/your-username/) folder. (It'll be hidden from ls without -a option because of the dot.)

link|improve this answer
thanks, but why then there are vim folders in /etc and /usr/share? – Sergey Aug 15 '11 at 13:40
3  
The one in /usr/share is the default settings that come with the program applied to all users, and will be overwritten if you upgrade your vim package -- so you don't want to make changes there. The one in /etc is for making changes which affect all users that won't be overwritten when the package is updated. But a .vimrc is a very personal thing, and generally, you only want to make changes that affect you, so they go in your home folder. – frabjous Aug 15 '11 at 14:08
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.