Support Git for Windows bundled MSYS Vim

References: https://github.com/tpope/vim-fugitive/issues/1970
This commit is contained in:
Tim Pope
2022-05-30 16:39:06 -04:00
parent 5bf3fd40f6
commit 596621dc6e

View File

@@ -526,9 +526,15 @@ else
return a:path
endfunction
function! FugitiveVimPath(path) abort
return a:path
endfunction
if has('win32unix') && filereadable('/git-bash.exe')
function! FugitiveVimPath(path) abort
return substitute(a:path, '^\(\a\):', '/\l\1', '')
endfunction
else
function! FugitiveVimPath(path) abort
return a:path
endfunction
endif
endif