Skip to content

Commit 92a66df

Browse files
committed
Complete installed plugins also for VundleUpdate
1 parent 1df432a commit 92a66df

2 files changed

Lines changed: 6 additions & 3 deletions

File tree

autoload/vundle.vim

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ com! -nargs=? -bang -complete=custom,vundle#scripts#complete VundleSearch Plugi
3232
com! -nargs=? -bang VundleClean PluginClean<bang>
3333
com! -nargs=0 VundleDocs PluginDocs
3434
com! VundleUpdate PluginInstall!
35+
com! -nargs=* -complete=custom,vundle#scripts#complete VundleUpdate PluginInstall! <args>
3536

3637
" Deprecated Commands
3738
com! -nargs=+ Bundle call vundle#config#bundle(<args>)

autoload/vundle/scripts.vim

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,15 @@ endf
3636
"
3737
" a, c, d -- see :h command-completion-custom
3838
" return -- all valid plugin names from vim-scripts.org as completion
39-
" candidates, see also :h command-completion-custom
39+
" candidates, or all installed plugin names when running an 'Update
40+
" variant'. see also :h command-completion-custom
4041
" ---------------------------------------------------------------------------
4142
func! vundle#scripts#complete(a,c,d)
42-
" Return only installed plugins if updating
43-
if match(a:c, '\v^Plugin%(Install!|Update)') == 0
43+
if match(a:c, '\v^%(Plugin|Vundle)%(Install!|Update)') == 0
44+
" Only installed plugins if updating
4445
return join(map(copy(g:bundles), 'v:val.name'), "\n")
4546
else
47+
" Or all known plugins otherwise
4648
return join(s:load_scripts(0),"\n")
4749
endif
4850
endf

0 commit comments

Comments
 (0)