diff --git a/plug.vim b/plug.vim index f7564ea..aa2716d 100644 --- a/plug.vim +++ b/plug.vim @@ -138,6 +138,7 @@ function! s:define_commands() endif command! -nargs=* -bar -bang -complete=customlist,s:names PlugInstall call s:install(0, []) command! -nargs=* -bar -bang -complete=customlist,s:names PlugUpdate call s:update(0, []) + command! -nargs=* -bar -bang -complete=customlist,s:names PlugOpen call s:open('',) command! -nargs=0 -bar -bang PlugClean call s:clean(0) command! -nargs=0 -bar PlugUpgrade if s:upgrade() | execute 'source' s:esc(s:me) | endif command! -nargs=0 -bar PlugStatus call s:status() @@ -592,6 +593,10 @@ function! s:update(force, names) call s:update_impl(1, a:force, a:names) endfunction +function! s:open(force, name) + exec ':Sexplore'.a:force.' '.g:plug_home.'/'.a:name.'/' +endfunction + function! plug#helptags() if !exists('g:plugs') return s:err('plug#begin was not called')