GNU bug report logs -
#41890
28.0.50; [PATCH]: Add bindings for project.el
Previous Next
Reported by: Theodor Thornhill <theo <at> thornhill.no>
Date: Tue, 16 Jun 2020 09:51:02 UTC
Severity: normal
Tags: patch
Found in version 28.0.50
Done: Dmitry Gutov <dgutov <at> yandex.ru>
Bug is archived. No further changes may be made.
Full log
Message #77 received at 41890 <at> debbugs.gnu.org (full text, mbox):
On 17.06.2020 19:33, Eli Zaretskii wrote:
>> On 17.06.2020 17:27, Eli Zaretskii wrote:
>>> I mean it isn't preloaded, but is loaded on demand.
>>
>> Okay, but... the commands in the keymap will all be autoloaded. So
>> whenever somebody calls them, the aforementioned optional package will
>> get loaded. I'm not sure what the practical issue with that is.
>
> I don't see how this is related to the issue at hand. All I'm saying
> is that a package, including its key bindings, shouldn't be loaded
> until some of its feature is invoked.
But if we autoload the bindings definition forms, wouldn't that have
essentially the same effect?
> Therefore, the best place for a
> package's keybindings is in the package itself. What you describe
> seems to fit this principle.
Okay.
>> The issue on the other side (keeping the keymap definition in
>> project.el) is that it's an ELPA package as well. And so far we've said
>> that ELPA packages shouldn't significantly modify a user's Emacs just by
>> the virtue of being installed.
>
> We could make the keybindings autoloaded without having them defined
> them when the package loads, couldn't we? By having the define-key on
> the same line as the autoload cookie, like bookmark.el does.
That would generally be considered problematic because the keymap would
take effect right after the user updates to the newest version of
project.el. Because package.el also compiles and evaluates autoloads.
Anyway, I'll apply this patch now, but we can continue this discussion.
This bug report was last modified 4 years and 357 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.