mhinz / vim-startify

:link: The fancy start screen for Vim.
MIT License
5.3k stars 186 forks source link

Restart Startify after plugin installation on startup (tip) #485

Open TamaMcGlinn opened 3 years ago

TamaMcGlinn commented 3 years ago

This is not a bug, just a suggestion for user configuration, so feel free to close this one immediately.

If you are using Vim-Plug, you probably have something like this in your vimrc to install plugins on startup. However, this version also closes the buffer again after that and shows Startify:

" Run PlugInstall if there are missing plugins
augroup plugins_check
  autocmd VimEnter * if len(filter(values(g:plugs), '!isdirectory(v:val.dir)'))
    \| PlugInstall --sync | source $MYVIMRC | execute 'close' | execute 'Startify'
  \| endif
augroup END