remove nvim autoclose when NERDtree last buffer

This commit is contained in:
2022-02-02 23:58:17 -07:00
parent 6028748da8
commit d159f1d56a

View File

@@ -16,10 +16,6 @@ nnoremap <leader><space> <cmd>NERDTreeToggle<cr>
" Start NERDTree when Vim is started without file arguments.
autocmd StdinReadPre * let s:std_in=1
autocmd VimEnter * if argc() == 0 && !exists('s:std_in') | NERDTree | endif
" Close the tab if NERDTree is the only window remaining in it.
autocmd BufEnter * if winnr('$') == 1 && exists('b:NERDTree') && b:NERDTree.isTabTree() | quit | endif
" Exit Vim if NERDTree is the only window remaining in the only tab.
autocmd BufEnter * if tabpagenr('$') == 1 && winnr('$') == 1 && exists('b:NERDTree') && b:NERDTree.isTabTree() | quit | endif
" Set to open Vista Sidebar
nnoremap ;<space> <cmd>Vista!!<cr>