mirror of
https://github.com/SpaceVim/SpaceVim.git
synced 2025-01-23 22:20:06 +08:00
Merge pull request #79 from SpaceVim/custom_plugins
Add option for custom plugins
This commit is contained in:
commit
5a0ad933cd
@ -135,6 +135,11 @@ let g:spacevim_plugin_groups = ['core', 'web']
|
||||
|
||||
" if there is a particular plugin you don't like, you can define this variable to disable them entirely
|
||||
let g:spacevim_disabled_plugins=['vim-foo', 'vim-bar']
|
||||
" if you want to add some custom plugins, use this options.
|
||||
let g:spacevim_custom_plugins = [
|
||||
\ ['plasticboy/vim-markdown', 'on_ft' : 'markdown'],
|
||||
\ ['wsdjeg/GitHub.vim'],
|
||||
\ ]
|
||||
|
||||
" anything defined here are simply overrides
|
||||
set wildignore+=\*/node_modules/\*
|
||||
|
@ -111,6 +111,15 @@ let g:spacevim_plugin_groups = []
|
||||
" <
|
||||
let g:spacevim_disabled_plugins = []
|
||||
""
|
||||
" Add custom plugins
|
||||
" >
|
||||
" let g:spacevim_custom_plugins = [
|
||||
" \ ['plasticboy/vim-markdown', 'on_ft' : 'markdown'],
|
||||
" \ ['wsdjeg/GitHub.vim'],
|
||||
" \ ]
|
||||
" <
|
||||
let g:spacevim_custom_plugins = []
|
||||
""
|
||||
" enable/disable SpaceVim with powerline symbols.
|
||||
let g:spacevim_enable_powerline_fonts = 1
|
||||
""
|
||||
|
@ -428,6 +428,13 @@ function! s:load_plugins() abort
|
||||
endif
|
||||
endfor
|
||||
endfor
|
||||
for plugin in g:spacevim_custom_plugins
|
||||
if len(plugin) == 2
|
||||
call zvim#plug#add(plugin[0], plugin[1])
|
||||
else
|
||||
call zvim#plug#add(plugin[0])
|
||||
endif
|
||||
endfor
|
||||
endfunction
|
||||
|
||||
function! s:disable_plugins(plugin_list) abort
|
||||
|
@ -108,6 +108,15 @@ Disable plugins by names. example:
|
||||
let g:spacevim_disabled_plugins = ['vim-foo', 'vim-bar']
|
||||
<
|
||||
|
||||
*g:spacevim_custom_plugins*
|
||||
Add custom plugins
|
||||
>
|
||||
let g:spacevim_custom_plugins = [
|
||||
\ ['plasticboy/vim-markdown', 'on_ft' : 'markdown'],
|
||||
\ ['wsdjeg/GitHub.vim'],
|
||||
\ ]
|
||||
<
|
||||
|
||||
*g:spacevim_enable_powerline_fonts*
|
||||
enable/disable SpaceVim with powerline symbols.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user