Hot tip for vim users: highlight spaces at end of lines

Chris Sherlock chris.sherlock79 at gmail.com
Fri Jan 1 01:21:21 PST 2016


Probably best to use:

augroup trailing_whitespace
   autocmd!
   autocmd BufWritePre *.c :%s/\s\+$//e
   autocmd BufWritePre *.h :%s/\s\+$//e
   autocmd BufWritePre *.cxx :%s/\s\+$//e
   autocmd BufWritePre *.hxx :%s/\s\+$//e
augroup END

> On 1 Jan 2016, at 4:53 AM, Daniel Robertson <danlrobertson89 at gmail.com> wrote:
> 
> In light of Norbert's comment maybe add *.cxx *.hxx
> 
> augroup trailing_whitespace
>    autocmd!
>    autocmd BufWritePre *.cxx :%s/\s\+$//e
>    autocmd BufWritePre *.hxx :%s/\s\+$//e
> augroup END
> 



More information about the LibreOffice mailing list