extract common code

This commit is contained in:
gmarik
2011-08-05 23:45:55 -05:00
parent b9226caacb
commit 57474f97a7
2 changed files with 9 additions and 31 deletions

View File

@@ -4,7 +4,7 @@ func! vundle#installer#new(bang, ...) abort
\ map(copy(a:000), 'vundle#config#init_bundle(v:val, {})')
let names = map(copy(bundles), 'v:val.name_spec')
call s:display(['" Installing'], names)
call vundle#scripts#view('Installer',['" Installing'], names)
exec ":1"
redraw!
@@ -23,24 +23,6 @@ func! vundle#installer#new(bang, ...) abort
echo 'Done! Helptags: '.len(helptags).' bundles processed'
endf
func! s:display(headers, results)
if exists('g:vundle_view')
exec g:vundle_view.'bd!'
endif
let results = map(a:results, ' printf("Bundle ' ."'%s'".'", v:val) ')
silent pedit [Vundle] installer
wincmd P | wincmd H
let g:vundle_view = bufnr('%')
call append(0, a:headers + results)
setl ft=vundle
call vundle#scripts#setup_view()
endf
func! s:sign(status)
if (!has('signs'))
return