From 497a143384f5299f33f3b61ee87b9e44caef29b1 Mon Sep 17 00:00:00 2001 From: David Kerkeslager Date: Tue, 24 Aug 2010 21:24:24 -0400 Subject: [PATCH] Added bad whitespace highlighting. --- .vimrc | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.vimrc b/.vimrc index 92fe292..e0ba2ef 100644 --- a/.vimrc +++ b/.vimrc @@ -18,6 +18,16 @@ set tabstop=4 set shiftwidth=4 set expandtab +"Highlight bad spacing +highlight BadSpacing term=standout ctermbg=cyan +augroup Spacing + autocmd! + " Highlight tabulators and trailing spaces (nasty bastards) + autocmd BufNewFile,BufReadPre * match BadSpacing /\(\t\| *$\)/ + " Only highlight trailing space in tab-filled formats + autocmd FileType help,make match BadSpacing / *$/ +augroup END + " Search as you type. set incsearch -- 2.20.1