Don't require shell quoting for colons

References https://github.com/tpope/vim-fugitive/issues/1289
This commit is contained in:
Tim Pope 2019-07-15 15:33:14 -04:00
parent dafb994c92
commit 4c650c699d

View File

@ -46,7 +46,7 @@ endfunction
function! s:shellesc(arg) abort
if type(a:arg) == type([])
return join(map(copy(a:arg), 's:shellesc(v:val)'))
elseif a:arg =~ '^[A-Za-z0-9_/.-]\+$'
elseif a:arg =~ '^[A-Za-z0-9_/:.-]\+$'
return a:arg
elseif s:winshell()
return '"'.s:gsub(s:gsub(a:arg, '"', '""'), '\%', '"%"').'"'