Browse Source

do not sync when `sync` is set to `no`

events
gmarik 15 years ago
parent
commit
60a46cd58e
2 changed files with 6 additions and 1 deletions
  1. +5
    -1
      autoload/vundle/config.vim
  2. +1
    -0
      autoload/vundle/installer.vim

+ 5
- 1
autoload/vundle/config.vim View File

@ -81,8 +81,12 @@ endf
let s:bundle = {} let s:bundle = {}
func! s:bundle.nosync()
return has_key(self, 'sync') && 'no' == self.sync()
endf
func! s:bundle.path() func! s:bundle.path()
if has_key(self, 'sync') && 'no' == self.sync
if self.nosync()
if isdirectory(expand(self.uri)) if isdirectory(expand(self.uri))
let path = expand(self.uri) let path = expand(self.uri)
endif endif


+ 1
- 0
autoload/vundle/installer.vim View File

@ -62,6 +62,7 @@ func! s:helptags(rtp) abort
endf endf
func! s:sync(bang, bundle) abort func! s:sync(bang, bundle) abort
if a:bundle.nosync() | return 0 | endif
let git_dir = expand(a:bundle.path().'/.git') let git_dir = expand(a:bundle.path().'/.git')
if isdirectory(git_dir) if isdirectory(git_dir)
if !(a:bang) | return 0 | endif if !(a:bang) | return 0 | endif


Loading…
Cancel
Save