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

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

Re: eval-after-load weirdness


From: Miles Bader
Subject: Re: eval-after-load weirdness
Date: Wed, 23 May 2007 07:59:22 +0900

Trent Buck <address@hidden> writes:
> because my modular .emacs setup has each configuration module named
> after the library it configures (e.g. ~/.emacs-prefs/vc.el for the vc
> library), eval-after-load thinks "vc" has already been loaded.
...
> Some solutions suggested on #emacs:
>     - stuff everything back into a single .emacs;
>     - prefix filenames with digits (e.g. 20vc.el), like system V init
>       scripts; and
>     - instead of LOADing each config module, FIND-FILE it and then
>       EVAL-BUFFER it.

You could also just remove the init files from `load-history' after the
fact.

E.g. (at the end of your .emacs):

   (let ((remove-regexp
          (concat "\\`" (regexp-quote (file-truename "~/.emacs-prefs/"))))
         (new-load-hist nil))
     (dolist (entry load-history)
       (unless (string-match remove-regexp (car entry))
         (push entry new-load-hist)))
     (setq load-history (nreverse new-load-hist)))

-miles
-- 
(\(\
(^.^)
(")")
*This is the cute bunny virus, please copy this into your sig so it can spread.




reply via email to

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