From ec2cb87d63c4a31a880705630ee6a1c5886e4c4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emmanuel=20Beno=C3=AEt?= Date: Mon, 23 Feb 2015 11:15:27 +0100 Subject: [PATCH] NeoBundle: local plugin configuration support --- config-bits/10-neobundle.vim | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/config-bits/10-neobundle.vim b/config-bits/10-neobundle.vim index 1336ac5..05562ec 100644 --- a/config-bits/10-neobundle.vim +++ b/config-bits/10-neobundle.vim @@ -37,7 +37,7 @@ call neobundle#begin( g:bundles_dir ) " Load NeoBundle itself, as well as VimProc NeoBundleFetch 'Shougo/neobundle.vim' -" Load all plugins from bundles-init/*.load +" Load all plugins from bundles-init/*.load.vim let s:binit_dir = g:vim_home . "/bundles-init" for s:plfn in glob( s:binit_dir . "/*.load.vim" , 0 , 1 ) execute "source" s:plfn @@ -47,8 +47,9 @@ for s:plfn in glob( s:binit_dir . "/*.load.vim" , 0 , 1 ) let s:bundle = neobundle#get( s:pname ) function! s:bundle.hooks.on_post_source( bundle ) - let cfgfile = s:binit_dir . "/" . a:bundle.name . ".cfg.vim" - if filereadable( l:cfgfile ) + let cfgfile = GetConfigFilePath( "bundles-init" , + \ a:bundle.name . ".cfg.vim" ) + if l:cfgfile != "" execute "source" l:cfgfile endif endfunction