Browse Source

simplify system call wrapping for cmd.exe

pull/589/head
Claus Reinke 11 years ago
parent
commit
29cfcf008f
1 changed files with 3 additions and 7 deletions
  1. +3
    -7
      autoload/vundle/installer.vim

+ 3
- 7
autoload/vundle/installer.vim View File

@ -513,14 +513,10 @@ endf
" return -- the return value from system() " return -- the return value from system()
" --------------------------------------------------------------------------- " ---------------------------------------------------------------------------
func! vundle#installer#system(cmd) abort func! vundle#installer#system(cmd) abort
" would this suffice?
" return system('"'.a:cmd.'"')
if has("win32") || has("win64") if has("win32") || has("win64")
let slash = &shellslash
set noshellslash
let result = system(shellescape(a:cmd))
if slash | set shellslash | endif
return result
" see cmd.exe docs (scroll down to remarks):
" https://technet.microsoft.com/de-de/library/cc771320(v=ws.10).aspx
return system('"'.a:cmd.'"')
else else
return system(a:cmd) return system(a:cmd)
endif endif


Loading…
Cancel
Save