From: Simon Ruderich Date: Sun, 13 Dec 2009 11:16:54 +0000 (+0100) Subject: vimrc: Disable 'list' and 'number' in help buffers. X-Git-Url: https://ruderich.org/simon/gitweb/?a=commitdiff_plain;ds=sidebyside;h=6a44ab1cf2b37c6954e53b9336a76f6e1ac26130;p=config%2Fdotfiles.git vimrc: Disable 'list' and 'number' in help buffers. --- diff --git a/vimrc b/vimrc index 35d84d5..040dad1 100644 --- a/vimrc +++ b/vimrc @@ -249,6 +249,17 @@ if has('autocmd') " But not for Git commits, go to beginning of the file. autocmd BufReadPost COMMIT_EDITMSG normal! gg +" Make sure 'list' and 'number' is disabled in help files. This is necessary +" when switching to a help buffer which is in the background with :buffer as +" these options are local to windows (and not only to buffers). This happens +" because I often want to use only one window and thus the help buffer is in +" the background. + autocmd BufWinEnter *.txt + \ if &filetype == 'help' | + \ setlocal nolist | + \ setlocal nonumber | + \ endif + " AFTER/FTPLUGIN AUTO COMMANDS " Disable spell checking for files which don't need it.