On Fri, 03 Jun 2011 17:44:26 +0200, Pieter Praet <pie...@praet.org> wrote:
> On Fri, 03 Jun 2011 11:18:54 -0400, Nick Dokos <nicholas.do...@hp.com> wrote:
> > Marcelo de Moraes Serpa <celose...@gmail.com> wrote:
> > 
> > 
> > > I use flyspell-mode for writing articles, but I don't need it for my 
> > > gtd.org file. Is there a way to
> > > exclude it (flyspell) from acting based on the filename of the buffer?
> > > 
> > 
> > You can use file local variables for things like this. There is an
> > ``eval'' pseudo-variable to allow you to execute code. See the emacs
> > manual for details, but it would look something like this (untested and
> > you have to put it at the end of the file):
> > 
> > ...
> > # Local Variables:
> > # eval: (flyspell-mode 0)
> > # End:
> 
> Although this can get rather annoying due to
> enable-local-variables related popups.

s/enable-local-variables/enable-local-eval

... though enable-local-variables applies as well.

Sorry for the noise.

> 
> I use something similar to this:
> 
> (add-hook 'find-file-hook
>           (lambda ()
>             (or (member (buffer-file-name)
>                         '("/path/to/some/file"
>                           "/path/to/other/file"))
>                 (flyspell-mode 1))))
> 
> > Nick
> > 
> 
> Peace
> 
> -- 
> Pieter

Peace

-- 
Pieter

Reply via email to