From 84378a9d81e815cf29d387430bacdbaf3476bf7c Mon Sep 17 00:00:00 2001 From: xndcn Date: Wed, 8 Aug 2018 17:44:02 +0800 Subject: [PATCH] Fix g:nerdtree_tabs_autofind=1 not working #94 It seems that g:nerdtree_tabs_autofind=1 is not working if NERDTree is opened manually by `:NERDTreeTabsToggle` --- nerdtree_plugin/vim-nerdtree-tabs.vim | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/nerdtree_plugin/vim-nerdtree-tabs.vim b/nerdtree_plugin/vim-nerdtree-tabs.vim index 7da573a..8407a9a 100644 --- a/nerdtree_plugin/vim-nerdtree-tabs.vim +++ b/nerdtree_plugin/vim-nerdtree-tabs.vim @@ -143,6 +143,10 @@ fun! s:NERDTreeOpenAllTabs() let l:current_tab = tabpagenr() tabdo call s:NERDTreeMirrorOrCreate() exe 'tabn ' . l:current_tab + if g:nerdtree_tabs_autofind + call s:NERDTreeUnfocus() + call s:NERDTreeFindFile() + endif endfun " }}}