help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: adding hook to auto-mode-alist load


From: Lute Kamstra
Subject: Re: adding hook to auto-mode-alist load
Date: Fri, 22 Aug 2003 17:57:45 +0200
User-agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3.50 (gnu/linux)

bojohan+news@dd.chalmers.se (Johan Bockgård) writes:

> AFAICS auto-mode-alist just specifies a function to call. Is there any
> reason the following is not a good idea?
>
> (defun foo ()
>   (paragraph-indent-text-mode)
>   (turn-on-auto-fill))
>
> (setq auto-mode-alist (cons '("\.plan$" . foo) auto-mode-alist))

Apart from the fact that it's better to use 

(add-to-list 'auto-mode-alist '("\.plan$" . foo))

in case you eval your .emacs more than once, this seems like a fine
solution to me.

  Lute.

-- 
(spook) => "supercomputer LABLINK rs9512c"
(insert-file-contents "~/.signature") => (error "`~/.signature' too rude")


reply via email to

[Prev in Thread] Current Thread [Next in Thread]