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

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

Re: .emacs not loading libraries


From: Emanuel Berg
Subject: Re: .emacs not loading libraries
Date: Sat, 17 Oct 2015 17:34:17 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux)

Mart van de Wege <mvdwege@gmail.com> writes:

> I've installed a bunch of libraries from elpa, and
> I found at least one of them is not available unless
> I do an explicit M-x load-library
>
> Now, I thought to add that to my .emacs, but neither
> (load-library "org-alert")

... you mean that interactive `load-library' works but
not as Lisp? If you check out the source for
load-library, the only thing it is is an interactive
interface to `load'. So probably it helps you with the
path when called with M-x. Without it, try using the
whole path. Or why not ditch it altogether in favor of
load? That should eliminate the interactive/Lisp
discrepancy, if any. load searches `load-path' and
appends .elc (first), then .el.

> (require 'org-alert)

If what you `require' isn't provided require is also
an interface to load. So use load to troubleshot this.

> .emacs.d/elpa/ is in my load-path.

Try to add a tilde

    ~/.emacs.d/elpa

or the complete path:

    /home/user/.emacs.d/elpa/

to test, put a file test.el in ~/.emacs.d

    (setq load-path '("~/.emacs.d/"))
    (load "test.el")

This works for me, but not if I do without the tilde
and then do `cd' to another directory.

-- 
underground experts united
http://user.it.uu.se/~embe8573




reply via email to

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