mirror of
https://github.com/tpope/vim-fugitive.git
synced 2025-11-12 05:13:53 -05:00
Don't treat buftype=nofile buffer names as file names
Resolves: https://github.com/tpope/vim-fugitive/issues/1905
This commit is contained in:
@@ -7221,7 +7221,7 @@ function! fugitive#BrowseCommand(line1, count, range, bang, mods, arg, ...) abor
|
||||
endif
|
||||
exe s:DirCheck(dir)
|
||||
if empty(expanded)
|
||||
let bufname = s:BufName('%')
|
||||
let bufname = &buftype =~# '^\%(nofile\|terminal\)$' ? '' : s:BufName('%')
|
||||
let expanded = s:DirRev(bufname)[1]
|
||||
if empty(expanded)
|
||||
let expanded = fugitive#Path(bufname, ':(top)', dir)
|
||||
|
||||
Reference in New Issue
Block a user