unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Auto load at startup
@ 2003-10-13 14:43 Sébastien Kirche
  0 siblings, 0 replies; 3+ messages in thread
From: Sébastien Kirche @ 2003-10-13 14:43 UTC (permalink / raw)


Hi,
for auto-loading elisp libraries at startup from a custom directory,
I though it was necessary to add something like

(add-to-list 'load-path "~/.my_elisp_dir/")

but it seems like emacs don't care of subdirs of my_elisp_dir.
Thus I have errors at startup if I add some

(require 'package)

if the named package is in a subdir.

But i put inside my_elisp_dir a file subdirs.el that *sould* have load 
these packages ?

Also, i found the following in the emacswiki :

,----[ Including subdirectories ]
|
| By default Emacs doesn't include subdirectories of a directory
| which is added to load-path. But you can do it by issuing a command
| in startup file:
|
| (normal-top-level-add-subdirs-to-load-path)
|
| which will add all subdirs of current directory. Note: current 
directory
| is not necessary that one, where your script is executed at the 
moment.
| So you first need to change directory to required one:
|
| (progn (cd "~/elisp") (normal-top-level-add-subdirs-to-load-path))
|
| In this example assumed that you want to add all subdirs of ~/elisp 
directory.
`----

I tried this tip that seems to work, but I would like to understand why 
the subdirs.el fails/isn't sufficient.

Thanks for help
Sébastien Kirche

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-10-14  8:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.1597.1066056301.21628.help-gnu-emacs@gnu.org>
2003-10-13 17:43 ` Auto load at startup Kevin Rodgers
2003-10-14  8:43   ` Sébastien Kirche
2003-10-13 14:43 Sébastien Kirche

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).