Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need help reconfiguring my vim!! In the process of working with it, I decided to download the .vim files and reinstall. After reinstalling I have had some major problems with my vimruntime. My vim files are located at /usr/asf/vim. I can't figure out where to get the original syntax files that come with a fresh install of ubuntu. Currently Vim is outputting the error

"E484: Can't open file /usr/share/vim/vim74/syntax/syntax.vim"

I no longer have a .vim file. I have tried a ton of things. I became so frustrated in fact that I did a sudo apt-get install vim-* do load all relative packages. I have visited and have gone to the software center. I still can't get

 :syntax on

to work. I would really appreciate help on this.

share|improve this question
/usr/asf? What madness is this? Anyhow, if you want to reinstall vim, try sudo apt-get purge vim; sudo apt-get install vim – DopeGhoti Jan 14 '14 at 2:37
I tried that. It still isn't giving me the syntax files. – and0rsk Jan 14 '14 at 2:47
After a fresh install, you should be able to execute vim -N -u NONE -i NONE -c 'syntax on' and have syntax highlighting when you then edit some file. You should also be able to execute :scriptnames and see a list of the loaded runtime files, probably starting with 1: /usr/share/vim/vim74/syntax/syntax.vim. – garyjohn Jan 14 '14 at 3:08
Something else you might try: /usr/bin/dpkg --get-selections | grep vim to see which vim packages you have installed. The list on my Ubuntu system includes vim-common and vim-runtime. I thought those were automatically installed with vim, but maybe you have to install those separately. – garyjohn Jan 14 '14 at 3:17
@garyjohn, it didn't work but I think I know now it is a problem with the runtime environment. I think I had some conflicts somewhere in the system and so the runtime enviorment was beings stored in another location. Here's the funny thing though, when I ran locate syntax.vim I can't find the syntax file although I found all the other scripts located in /usr/share/vim/addons/ – and0rsk Jan 14 '14 at 4:19
up vote 1 down vote accepted

To install a proper Vim on ubuntu, run this command in your terminal:

$ sudo apt-get install vim-gnome

This should get you a working Vim (both CLI and GUI).

Your user directory is:


often shortened to:


That's where you are supposed to put your configuration:

~/.vim/  <= the directory where you put colorschemes and plugins
~/.vimrc <= the file where you put your settings/mappings

These directory and file are not created by Vim: you must create them yourself.

$ cd
$ mkdir .vim
$ touch .vimrc

NEVER do anything in /usr/share/vim. NEVER.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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