Browse Source

vim: fix term exit logic

Thomas Dy 5 years ago
parent
commit
b7d48717a4
1 changed files with 2 additions and 3 deletions
  1. 2 3
      .vim/init.vim

+ 2 - 3
.vim/init.vim

@@ -36,9 +36,6 @@ let g:lightline = {
       \ },
       \ }
 
-autocmd FileType fzf setlocal nonumber norelativenumber
-autocmd FileType fzf tnoremap <buffer> jj <Esc>
-
 " ------ settings ------
 
 " change terminal title
@@ -131,6 +128,8 @@ if has('nvim')
   autocmd TermOpen term://* startinsert
   autocmd BufWinEnter,WinEnter term://* startinsert
   autocmd BufLeave term://* stopinsert
+  autocmd FileType fzf tnoremap <buffer> jj <Esc>
+  autocmd TermOpen * setlocal nonumber norelativenumber
 
   nnoremap <Leader>tv :vsp term://zsh<CR>
   nnoremap <Leader>to :term<CR>