VIM: Session-Management

This commit is contained in:
Tobias Manske 2022-06-28 02:52:45 +02:00
parent cb7712421c
commit fb1d1c0998
Signed by: tobias
GPG Key ID: E83C743C1FC2F79A
2 changed files with 10 additions and 4 deletions

View File

@ -210,10 +210,13 @@ nnoremap <silent> <space>k :<C-u>CocPrev<CR>
" Resume latest coc list " Resume latest coc list
nnoremap <silent> <space>p :<C-u>CocListResume<CR> nnoremap <silent> <space>p :<C-u>CocListResume<CR>
if !exists('SessionLoad')
" Open Tagbar " Open Tagbar
autocmd VimEnter * nested :call tagbar#autoopen(1) autocmd VimEnter * nested :call tagbar#autoopen(1)
" Open NerdTREE " Open NerdTREE
autocmd VimEnter * NERDTree | wincmd p autocmd VimEnter * NERDTree | wincmd p
endif
" If another buffer tries to replace NERDTree, put it in the other window, and bring back NERDTree. " If another buffer tries to replace NERDTree, put it in the other window, and bring back NERDTree.
autocmd BufEnter * if bufname('#') =~ 'NERD_tree_\d\+' && bufname('%') !~ 'NERD_tree_\d\+' && winnr('$') > 1 | autocmd BufEnter * if bufname('#') =~ 'NERD_tree_\d\+' && bufname('%') !~ 'NERD_tree_\d\+' && winnr('$') > 1 |

View File

@ -37,6 +37,9 @@ Plug 'roxma/vim-window-resize-easy'
" Better comments " Better comments
Plug 'scrooloose/nerdcommenter' Plug 'scrooloose/nerdcommenter'
" Session Management
Plug 'tpope/vim-obsession'
" Work on brackets in pairs " Work on brackets in pairs
Plug 'jiangmiao/auto-pairs' Plug 'jiangmiao/auto-pairs'