mirror of
https://github.com/tpope/vim-fugitive.git
synced 2025-12-11 06:22:02 +08:00
Convert all FugitivePrepare() int arguments to buffer names
This commit is contained in:
@@ -324,6 +324,11 @@ function! s:PreparePathArgs(cmd, dir, literal) abort
|
|||||||
call insert(a:cmd, '--literal-pathspecs')
|
call insert(a:cmd, '--literal-pathspecs')
|
||||||
endif
|
endif
|
||||||
let split = index(a:cmd, '--')
|
let split = index(a:cmd, '--')
|
||||||
|
for i in range(split < 0 ? len(a:cmd) : split)
|
||||||
|
if type(a:cmd[i]) == type(0)
|
||||||
|
let a:cmd[i] = fugitive#Path(bufname(a:cmd[i]), './', a:dir)
|
||||||
|
endif
|
||||||
|
endfor
|
||||||
if split < 0
|
if split < 0
|
||||||
return a:cmd
|
return a:cmd
|
||||||
endif
|
endif
|
||||||
|
|||||||
Reference in New Issue
Block a user