6

I am trying to install different plug-ins in vim. I have installed vim using sudo apt-get install vim. But the downloaded files for these plug-ins need to be placed in ~/.vim folder. But there is no such folder. I've found a vim folder in /etc and also in /usr/share directories. Which one to use..??

0

5 Answers 5

6

You can copy the plugins in the /etc/vim folder, if you want them to be available for all users:

sudo cp -rv /route/to/nameoftheplugin /etc/vim/

Or, if you only need them for your use, just create the vim directory in your home:

mkdir ~/.vim

Then to open that folder, just type:

nautilus ~/.vim
2
  • I have copied the plugin files to /etc/vim. The plugin is snipmate. Now when I open a C file the plugin is not working.. :/ Jan 5, 2014 at 14:44
  • You should read the information about how that specific plugin works, maybe you need to unpack it, or give it executable permissions? The plugin should come with some kind of install information. Jan 5, 2014 at 15:35
3

Just create it,

mkdir ~/.vim

and then move the plug-in files to said folder.

1

You need to create the .vim folder in your home folder. All plugins will go into the ~/.vim/plugins folder. Your personal initialization options will go into the ~/.vimrc file.

1

The following worked for me: open the vim editor and type :echo $VIMRUNTIME

in my case it was /usr/share/vim/vim74

Go to the plugin directory inside your runtime directory and copy your plugin file there.

I've copied yaml.vim for YAML syntax highlighting. Works perfectly fine.

0

The .vim folder can be found in your Home directory. The dot(.) at the beginning means the vim folder is hidden. Extract the plugins into the .vim folder for installing the vim plugins.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .