From: Chris Marusich <cmmarusich@gmail.com>
To: Alex Kost <alezost@gmail.com>
Cc: guix-devel@gnu.org
Subject: Re: Having trouble packaging DefaultEncrypt for Emacs
Date: Thu, 13 Apr 2017 00:38:58 -0700 [thread overview]
Message-ID: <877f2orc31.fsf@gmail.com> (raw)
In-Reply-To: <87d1ci2h07.fsf@gmail.com> (Alex Kost's message of "Wed, 12 Apr 2017 10:59:36 +0300")
[-- Attachment #1: Type: text/plain, Size: 1753 bytes --]
Alex Kost <alezost@gmail.com> writes:
> Alex Kost (2017-04-11 23:04 +0300) wrote:
>
>> Chris Marusich (2017-04-11 00:40 -0700) wrote:
>>
>>> Alex Kost <alezost@gmail.com> writes:
>>>
>>>> Note, however, that in most cases (not in this case) using "require" is
>>>> not needed at all! Usually it is enough to have the generated
>>>> autoloads. For example, if you install 'magit', you don't need to (and
>>>> shouldn't!) put "(require 'magit)" in your emacs config. You can use
>>>> "M-x magit-status" right away as 'magit-status' command is "autoloaded".
>>>
>>> That's good to know. I guess this module didn't do the "autoload magic"
>>> that some modules, like magit, do?
>>
>> Unlike such packages as magit, this package doesn't provide any
>> interactive command (thus there is no point to autoload anything), it
>> just extends the existing Emacs functionality when it is loaded. It
>> does so simply by adding a couple of hooks, so if you would like to
>> avoid loading this package on Emacs start, you can add these hooks
>> yourself:
>>
>> (add-hook 'gnus-message-setup-hook 'mml-secure-encrypt-if-possible)
>> (add-hook 'message-send-hook 'mml-secure-check-encryption-p)
>
> Oops, I forgot one thing:
>
> (autoload 'mml-secure-encrypt-if-possible "jl-encrypt")
> (autoload 'mml-secure-check-encryption-p "jl-encrypt")
>
>> If you add the above 2 lines to your emacs config (instead of the
>> "require" line), "jl-encrypt" package will not be loaded on Emacs
>> start. It will be loaded when you'll begin to write a message.
Neat! I didn't know much about the "autoload" stuff. I've read the
section in the manual, and thanks to these examples, it makes more
sense. Thank you!
--
Chris
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
prev parent reply other threads:[~2017-04-13 7:39 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-09 0:21 Having trouble packaging DefaultEncrypt for Emacs Chris Marusich
2017-04-10 10:10 ` Alex Kost
2017-04-10 10:31 ` Alex Kost
2017-04-11 8:22 ` Chris Marusich
2017-04-11 7:40 ` Chris Marusich
2017-04-11 20:04 ` Alex Kost
2017-04-12 7:59 ` Alex Kost
2017-04-13 7:38 ` Chris Marusich [this message]
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=877f2orc31.fsf@gmail.com \
--to=cmmarusich@gmail.com \
--cc=alezost@gmail.com \
--cc=guix-devel@gnu.org \
/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/guix.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.