Manage Vim Plugin With Pathogen

pathogen.vim Manage your 'runtimepath' with ease. In practical terms, pathogen.vim makes it super easy to install plugins and runtime files in their own private directories.

Installation

Install to ~/.vim/autoload/pathogen.vim. Or copy and paste:

mkdir -p ~/.vim/autoload ~/.vim/bundle && \

curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim

Runtime Path Manipulation

Add this to your vimrc:

execute pathogen#infect()

If you're brand new to Vim and lacking a vimrc, vim ~/.vimrc and paste in the following super-minimal example:

execute pathogen#infect()

syntax on

filetype plugin indent on

Now any plugins you wish to install can be extracted to a subdirectory under ~/.vim/bundle, and they will be added to the 'runtimepath'.

An Example to Install a Plugin

cd ~/.vim/bundle && \

git clone git://github.com/tpope/vim-sensible.git

Now sensible.vim is installed.

References

Technorati 标签: vim,plugin
posted @ 2015-12-20 18:58  luckysimple  阅读(210)  评论(0编辑  收藏  举报