From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pieter Praet Subject: Re: [OT] Deactivate flyspell on a file by file basis Date: Fri, 03 Jun 2011 17:44:26 +0200 Message-ID: <87fwnqudgl.fsf@praet.org> References: <8261.1307114334@alphaville.dokosmarshall.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from eggs.gnu.org ([140.186.70.92]:50760) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QSWY6-0008VY-9h for emacs-orgmode@gnu.org; Fri, 03 Jun 2011 11:44:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QSWY4-0003su-FG for emacs-orgmode@gnu.org; Fri, 03 Jun 2011 11:44:34 -0400 Received: from mail-wy0-f169.google.com ([74.125.82.169]:46002) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QSWY4-0003sl-1W for emacs-orgmode@gnu.org; Fri, 03 Jun 2011 11:44:32 -0400 Received: by wyf19 with SMTP id 19so1900734wyf.0 for ; Fri, 03 Jun 2011 08:44:30 -0700 (PDT) In-Reply-To: <8261.1307114334@alphaville.dokosmarshall.org> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Marcelo de Moraes Serpa Cc: nicholas.dokos@hp.com, Org Mode On Fri, 03 Jun 2011 11:18:54 -0400, Nick Dokos wrote: > Marcelo de Moraes Serpa 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. 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