[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [Libvir] removing trailing blanks (and keeping them away)



On Mon, Feb 04, 2008 at 06:45:33PM +0000, Daniel P. Berrange wrote:
> On Mon, Feb 04, 2008 at 06:42:01PM +0000, Richard W.M. Jones wrote:
> > Jim Meyering wrote:
> > I looked into it, and there is a show-trailing-whitespace variable in 
> > emacs, so one might consider modifying our "standard" trailer to be:
> > 
> > /*
> >  * Local variables:
> >  *  indent-tabs-mode: nil
> >  *  c-indent-level: 4
> >  *  c-basic-offset: 4
> >  *  tab-width: 4
> >  *  show-trailing-whitespace: t        <--- NB
> >  * End:
> >  */
> > 
> > HOWEVER this doesn't work, or at least not automatically.  Emacs 
> > complains: "The local variables list in foo.c contains values that may 
> > not be safe" and marks show-trailing-whitespace as one such variable. 
> > Although one can mark it as safe in your local preferences, every emacs 
> > user would have to do this.
> > 
> > I've no idea why show-trailing-whitespace should be unsafe.
> 
> Hmm, I've got the following in my $HOME/.emacsrc file
> 
> (require 'show-wspace) 
> (add-hook 'font-lock-mode-hook 'highlight-trailing-whitespace)
> 
> Which does the trick for me

But is useless for anyone else unless I also mention that it requires a
copy of

  http://www.emacswiki.org/cgi-bin/wiki/show-wspace.el

in your emacs lisp search path

Dan.
-- 
|=- Red Hat, Engineering, Emerging Technologies, Boston.  +1 978 392 2496 -=|
|=-           Perl modules: http://search.cpan.org/~danberr/              -=|
|=-               Projects: http://freshmeat.net/~danielpb/               -=|
|=-  GnuPG: 7D3B9505   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505  -=| 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]