From 809efd3f629704996c7104d36265995f472955f3 Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Tue, 17 Aug 2021 20:43:53 -0400 Subject: [PATCH] Fix :Gedit .git with nonstandard .git dir --- autoload/fugitive.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/autoload/fugitive.vim b/autoload/fugitive.vim index 84dbc8b..63bb5f0 100644 --- a/autoload/fugitive.vim +++ b/autoload/fugitive.vim @@ -1453,7 +1453,7 @@ function! fugitive#Find(object, ...) abort let tree = s:Tree(dir) let base = len(tree) ? tree : 'fugitive://' . dir . '//0' if rev ==# '.git' - let f = len(tree) ? tree . '/.git' : dir + let f = len(tree) && len(getftype(tree . '/.git')) ? tree . '/.git' : dir elseif rev =~# '^\.git/' let f = strpart(rev, 5) let fdir = dir . '/'