Emacs: Crypto: How to get automatic encryption?

David Edmondson dme at dme.org
Tue Jan 17 07:39:52 PST 2012


>        (if (and force (re-search-forward "<#secure [> >]*>\n" nil t))
> 	   (replace-match "" nil nil))
>        ;; If we can encrypt, do so, else just sign.
>        (if (or force (not (re-search-forward "<#secure [> >]*>\n" nil t)))

Is this second test for `force' necessary? If `force' is set then you'll
remove the <#secure..> just above, so it will not be found here.

> 	   (if (anarcat/message-guess-encryption)
> 	       (insert "<#secure method=pgpmime mode=signencrypt>\n")
> 	     (insert "<#secure method=pgpmime mode=sign>\n"))
> 	 )
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://notmuchmail.org/pipermail/notmuch/attachments/20120117/90e8e822/attachment.pgp>


More information about the notmuch mailing list