From 384c9e1d8ec25646396d53868ec0044e0b3ecbfc Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Sun, 30 Jun 2019 21:11:31 -0400 Subject: [PATCH] Support :tcd in initialization --- plugin/fugitive.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugin/fugitive.vim b/plugin/fugitive.vim index b1af3ac..9688aab 100644 --- a/plugin/fugitive.vim +++ b/plugin/fugitive.vim @@ -159,7 +159,7 @@ function! FugitiveExtractGitDir(path) abort endif let root = resolve(path) if root !=# path - silent! exe haslocaldir() ? 'lcd .' : 'cd .' + silent! exe (haslocaldir() ? 'lcd' : exists(':tcd') && haslocaldir(-1) ? 'tcd' : 'cd') '.' endif let previous = "" let env_git_dir = len($GIT_DIR) ? s:Slash(simplify(fnamemodify($GIT_DIR, ':p:s?[\/]$??'))) : ''