From: Easior <easior@126.com>
To: Xah Lee <xahlee@gmail.com>
Cc: help-gnu-emacs@gnu.org
Subject: Re: elpa package loading problem?
Date: Thu, 29 Nov 2012 15:09:52 +0800 [thread overview]
Message-ID: <87k3t47um7.fsf@noah.localdomain> (raw)
In-Reply-To: <fd2a9da0-ce1c-434d-807f-1a0dcbb46285@pr7g2000pbb.googlegroups.com> (Xah Lee's message of "Sat, 2 Jun 2012 09:44:29 -0700 (PDT)")
>>>>> "XL" == Xah Lee <xahlee@gmail.com> writes:
XL> does anyone have problems with emacs package system?
XL> recently, installed several packages with it: {“rainbow-mode”,
XL> “bookmark+”, “smex”, “expand-region”}.
XL> But they all have a similar problem related to autoload. For example,
XL> let's say rainbow-mode. When in css, it's not loaded. You have to
XL> manually call it. So, if you want it to load automatically when in
XL> css, you have to add stuff to your init file. Then, this means the
XL> package system does not really automatically manage things. You still
XL> have know some elisp, and manually add things to your init file. (we
XL> talking about basic activation, not advanced customization)
XL> The issue is more pronounced with modes such as bookmark+, smex,
XL> expand-region. For example, in bookmark+, when i start my emacs, call
XL> bookmark 【Ctrl+x r l】, it gives a error about some current-bookmark-
XL> file var not defined. Apparently, the problem is that bookmark+ must
XL> be properly initialized before i start my bookmark. (when calling
XL> bookmark-bmenu-list, it does automatically load bookmark+, but isn't
XL> properly initialized) Here, i've spent some 20 min but haven't
XL> succeeded in making it work. (i suppose i'll need to take time to
XL> understand how elpa loading mechanism works.)
XL> Similar things happen with smex, expand-region. For example, smex
XL> requires you to define a key for M-x. So i added (global-set-key (kbd
XL> "<apps>") 'smex) in my init. But after starting emacs, i press the
XL> apps key, i get: “Symbol's function definition is void: smex”. If i
XL> put (require 'smex), restart, i get “Debugger entered--Lisp error:
XL> (file-error "Cannot open load file" "smex")”. Next step is to add the
XL> load path, which i haven't tried yet. But that seems to defeat half of
XL> goodness of package system.
XL> Any insight on this?
XL> for emacs 24, is this the way things are?
It's just my question.
However, I also found something strange with package.el in emacs 24.
I installed command-frequency.el, info+.el, maxfame.el etc, by elpa.
Those package couldn't load properly if I add the following lines:
,------------------------------------------------
| (require 'command-frequency)
| (eval-after-load "info" '(require 'info+))
| (require 'maxframe)
| (add-hook 'window-setup-hook 'maximize-frame t)
`------------------------------------------------
to the file ~/.emacs. The *Bugtrace* reports that
If I adjust my dotemacs file as follows
,------------------------------------------------
| ;; (require 'command-frequency)
| ;; (eval-after-load "info" '(require 'info+))
| ;; (require 'maxframe)
| (add-hook 'window-setup-hook 'maximize-frame t)
`------------------------------------------------
then the maxframe.el works well while command-frequency.el and
info+.el didn't take any effects. I found those files named
<package>-<autoloads>.el when I entered into the elpa directory.
Based on these facts, I understand that
* packages installed by elpa couldn't required in ~/.emacs since
they would be autoloaded through the autoloads files. Furthermore,
the autoloads files are generated from the ;;##autoload lines in
package sources.
* maxfame.el works since the function, maximize-frame, is in the
autoloads file.
* command-frequency.el doesn't work because there is nothing in its
autoloads file.
Is it right?
Question:
Is there a way to make info+.el, command-frequency.el run by elpa?
What can I do?
Thanks in advance.
Best regards,
Easior
-----
Ich bin von heute und ehedam, aber etwas ist in mir, das ist vor
morgen und übermorgen und einstmal.
Friedrich Wilhelm Nietzsche
next prev parent reply other threads:[~2012-11-29 7:09 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-02 16:44 elpa package loading problem? Xah Lee
2012-06-04 8:58 ` José A. Romero L.
2012-06-04 19:18 ` José A. Romero L.
2012-06-04 23:09 ` Xah Lee
2012-11-29 7:09 ` Easior [this message]
2012-11-30 4:18 ` Jude DaShiell
[not found] ` <mailman.14118.1354247749.855.help-gnu-emacs@gnu.org>
2012-11-30 4:53 ` Xah Lee
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87k3t47um7.fsf@noah.localdomain \
--to=easior@126.com \
--cc=help-gnu-emacs@gnu.org \
--cc=xahlee@gmail.com \
/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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.