unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Kevin Rodgers <kevin.d.rodgers@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: flyspell-mode -- external localwords defitions?
Date: Mon, 27 Oct 2008 22:04:55 -0600	[thread overview]
Message-ID: <ge6311$vlu$1@ger.gmane.org> (raw)
In-Reply-To: <utzb05hzu.fsf@terrapin.northbound-train.com>

Joe Casadonte wrote:
> I have a set of files that I would like to have share a common set of
> localworlds.  It's a pain to keep copying them around from one file to
> the next; is there an existing way to have an external localwords
> definition?

Here's what I came up with (untested):

(defvar ispell-external-local-words-file-name nil
   "If non-nil, a file containing words to accept in the current buffer.
See `ispell-words-keyword'.")

(defadvice flyspell-process-localwords (around external-local-words
					       activate)
   "Visit `ispell-external-local-words-file-name' to find the words."
   (if ispell-external-local-words-file-name
       (save-current-buffer
	(set-buffer (find-file-noselect ispell-external-local-words-file-name))
	ad-do-it)
     ad-do-it))

-- 
Kevin Rodgers
Denver, Colorado, USA





      reply	other threads:[~2008-10-28  4:04 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-26  0:15 flyspell-mode -- external localwords defitions? Joe Casadonte
2008-10-28  4:04 ` Kevin Rodgers [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='ge6311$vlu$1@ger.gmane.org' \
    --to=kevin.d.rodgers@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).