Browse Source

Fix vundle#installer#relative_path

Escape \ in paths in order to match the bundle path part correctly on
Windows.
pull/116/head
Marwan Al Jubeh 12 years ago
parent
commit
484d560485
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      autoload/vundle/installer.vim

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

@ -277,7 +277,8 @@ func! vundle#installer#relative_path(bundle) abort
let cmd = 'cd '.vundle#installer#shellesc(g:bundle_dir).' && git rev-parse --show-prefix'
let cmd = vundle#installer#shellesc_cd(cmd)
let prefix = s:strip(s:system(cmd))
return prefix.substitute(a:bundle.path(), g:bundle_dir, '', '')
let pattern = '\V'.substitute(g:bundle_dir, '\\', '\\\\', 'g')
return prefix.substitute(a:bundle.path(), pattern, '', '')
endf
" ---------------------------------------------------------------------------


Loading…
Cancel
Save