我使用spf13作为我的 vim 插件集合。
This是 .vimrc 文件。
如何仅覆盖“常规”组 bundle ?
或者,更具体地说,如何禁用或替换一个插件?
谢谢!
更新:抱歉,也许我没有说清楚,我真正想要的是禁用或替换 .vimrc.local 或 .vimrc.bundles.local 中的插件
我不想碰 .vimrc 文件。
更新2:谢谢大家。我已经弄清楚了。
“让 NERDTreeChDirMode=0 并设置 noautochdir”应该有效。 但我还需要注释掉这一点(autocmd BufEnter * if bufname("") !~ "^[A-Za-z0-9]*://"| lcd %:p:h | endif) 。
最佳答案
这记录在 .vimrc 中SPF13。
" In your .vimrc.bundles.local file"
" list only the plugin groups you will use
if !exists('g:spf13_bundle_groups')
let g:spf13_bundle_groups=['general', 'programming', 'php', 'ruby', 'python', 'javascript', 'html', 'misc']
endif
从列表中删除general
,或者,例如php
、ruby
,如果您不进行 php 或 ruby 开发。
对于特定插件,在 .vimrc 中 grep 查找该插件,并注释掉加载 Bundle 的行,例如:
" Javascript
if count(g:spf13_bundle_groups, 'javascript')
" disable JSON plugin:
" Bundle 'leshill/vim-json'
Bundle 'groenewege/vim-less'
Bundle 'taxilian/vim-web-indent'
endif
关于vim - 如何禁用或替换此 .vimrc 文件的特定插件?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11711645/