diff --git a/vim/config/keyboard.vim b/vim/config/keyboard.vim index 1f64b3e..d8b07d5 100644 --- a/vim/config/keyboard.vim +++ b/vim/config/keyboard.vim @@ -527,10 +527,12 @@ autocmd FileType gundo map h k "help - autocmd FileType help map q ':q' - autocmd FileType help map ?? ':q' - autocmd FileType help map ?> ':q' - autocmd FileType help map ?< ':q' + if !&diff + autocmd FileType help map q ':q' + autocmd FileType help map ?? ':q' + autocmd FileType help map ?> ':q' + autocmd FileType help map ?< ':q' + endif "markdown: launch table of contents instead of the tagbar autocmd FileType mkd map ':Toch' diff --git a/vim/config/plugins.vim b/vim/config/plugins.vim index 95f305c..3f5a6d1 100644 --- a/vim/config/plugins.vim +++ b/vim/config/plugins.vim @@ -114,8 +114,11 @@ if !exists("g:autostarttagbar") let g:autostarttagbar=0 endif - if (g:autostarttagbar == 1) - autocmd VimEnter * nested :call tagbar#autoopen(1) + + if !&diff + if (g:autostarttagbar == 1) + autocmd VimEnter * nested :call tagbar#autoopen(1) + endif endif let g:tagbar_sort=0