How to make vim pathogen to reload plugins?
I was in the same boat before util I find an awesome plugin(vim-reload) to do these stuffs automatic in an amazing way.You should have a shot at this plugin.
If you use a modern version of vim, you can use its built-in package manager, which has a convenient function to reload all plugins:
:packloadall
http://vimhelp.appspot.com/repeat.txt.html#%3Apackloadall
Pathogen just manipulates the 'runtimepath'
option; the situation with plugin reloads is therefore the same as with the plain default plugin structure. (Other plugin managers may offer this kind of reload / dynamic enable functionality; I suppose you want to stick with Pathogen.)
To retroactively enable a plugin in a running Vim session, you need to :source
all (usually that's only one) plugin scripts that have been added. For a plugin named foobar
, that would be:
:source ~/.vim/bundle/foobar/plugin/foobar.vim
If you can get Pathogen to re-initialize the 'runtimepath'
(or augment it yourself via :set rtp+=~/.vim/bundle/foobar
), you can also use the shorter
:runtime plugin/foobar.vim