vimrc: wrap PlugInstall in augroup
This commit is contained in:
parent
e1d79a8b6b
commit
31b35a8fb1
11
.vim/vimrc
11
.vim/vimrc
@ -10,10 +10,13 @@ if empty(glob('~/.vim/autoload/plug.vim'))
|
|||||||
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
|
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Run PlugInstall if there are missing plugins
|
augroup plug_auto_install
|
||||||
autocmd VimEnter * if len(filter(values(g:plugs), '!isdirectory(v:val.dir)'))
|
autocmd!
|
||||||
\| PlugInstall --sync | source $MYVIMRC
|
" Run PlugInstall if there are missing plugins
|
||||||
\| endif
|
autocmd VimEnter * if len(filter(values(g:plugs), '!isdirectory(v:val.dir)'))
|
||||||
|
\| PlugInstall --sync | source $MYVIMRC
|
||||||
|
\| endif
|
||||||
|
augroup END
|
||||||
|
|
||||||
" both "filetype indent on" and "syntax on" are called by Plug, keeping DRY
|
" both "filetype indent on" and "syntax on" are called by Plug, keeping DRY
|
||||||
call plug#begin()
|
call plug#begin()
|
||||||
|
Loading…
Reference in New Issue
Block a user