motiejus/dotfiles

Unnamed repository; edit this file 'description' to name the repository.
git clone https://git.jakstys.lt/motiejus/dotfiles.git
Log | Tree | Refs | README | LICENSE

commit d28b1e7cf4478c28dcdbf9caa87dfb5d75a54383 (tree)
parent 4bbeec5938109c680aec2309837911afb64d9363
Author: Tim Pope <code@tpope.net>
Date:   Sun, 24 Jan 2010 22:59:42 -0500

Work around git-branch-info.vim stupidity

Diffstat:
Mplugin/fugitive.vim | 5++++-
1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/plugin/fugitive.vim b/plugin/fugitive.vim @@ -101,6 +101,9 @@ function! s:ExtractGitDir(path) abort endfunction function! s:Detect() + if exists('b:git_dir') && b:git_dir ==# '' + unlet b:git_dir + endif if !exists('b:git_dir') let dir = s:ExtractGitDir(expand('%:p')) if dir != '' @@ -131,7 +134,7 @@ let s:repo_prototype = {} let s:repos = {} function! s:repo(...) abort - let dir = a:0 ? a:1 : (exists('b:git_dir') ? b:git_dir : s:ExtractGitDir(expand('%:p'))) + let dir = a:0 ? a:1 : (exists('b:git_dir') && b:git_dir !=# '' ? b:git_dir : s:ExtractGitDir(expand('%:p'))) if dir !=# '' if has_key(s:repos,dir) let repo = get(s:repos,dir)