mirror of
https://github.com/tpope/vim-fugitive.git
synced 2025-11-14 14:23:51 -05:00
Don't complete directories as subcommands
This commit is contained in:
@@ -2780,7 +2780,7 @@ function! s:CompletableSubcommands(dir) abort
|
|||||||
endif
|
endif
|
||||||
let cpath = s:cpath(path)
|
let cpath = s:cpath(path)
|
||||||
if !has_key(s:path_subcommands, cpath)
|
if !has_key(s:path_subcommands, cpath)
|
||||||
let s:path_subcommands[cpath] = filter(map(s:GlobComplete(path.'/git-', '*', 1),'substitute(v:val,"\\.exe$","","")'), 'v:val !~# "--"')
|
let s:path_subcommands[cpath] = filter(map(s:GlobComplete(path.'/git-', '*', 1),'substitute(v:val,"\\.exe$","","")'), 'v:val !~# "--\\|/"')
|
||||||
endif
|
endif
|
||||||
call extend(commands, s:path_subcommands[cpath])
|
call extend(commands, s:path_subcommands[cpath])
|
||||||
endfor
|
endfor
|
||||||
|
|||||||
Reference in New Issue
Block a user