Do what the user means for LANG= in g:fugitive_git_executable

This commit is contained in:
Tim Pope 2019-07-23 13:42:19 -04:00
parent 1fe6202848
commit 15df3f8959
2 changed files with 3 additions and 5 deletions

View File

@ -6,8 +6,10 @@ if exists('g:autoloaded_fugitive')
endif
let g:autoloaded_fugitive = 1
if !exists('g:fugitive_git_executable') || g:fugitive_git_executable =~# '^LANG='
if !exists('g:fugitive_git_executable')
let g:fugitive_git_executable = 'git'
elseif g:fugitive_git_executable =~# '^\w\+='
let g:fugitive_git_executable = 'env ' . g:fugitive_git_executable
endif
" Section: Utility

View File

@ -8,10 +8,6 @@ if exists('g:loaded_fugitive')
endif
let g:loaded_fugitive = 1
if get(g:, 'fugitive_git_executable', '') =~# '^LANG='
echoerr 'Including "LANG=..." in g:fugitive_git_executable is no longer necessary or supported. Remove the "let g:fugitive_git_executable = ..." line from your vimrc.'
endif
function! FugitiveGitDir(...) abort
if !a:0 || a:1 ==# -1
return get(b:, 'git_dir', '')