Monday, June 15, 2009

Highlight lines longer than N characters in Vim

To highlight characters that go over a 90 column limit in Vim add the following to your .vimrc: highlight OverLength ctermbg=grey guibg=#EEEEEE
au BufWinEnter * let w:m1=matchadd('OverLength', printf('\%%>%dv.\+', 90), -1)

No comments:

Post a Comment