From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/84608 Path: news.gmane.org!not-for-mail From: =?utf-8?Q?Peter_M=C3=BCnster?= Newsgroups: gmane.emacs.gnus.general Subject: Re: Automatic GPG signing Date: Fri, 13 Jun 2014 13:32:16 +0200 Message-ID: <87wqclkptr.fsf@micropit.roche-blanche.homenet.org> References: <87oaxy0wpa.fsf@descartes.rss.mhs.man.ac.uk> <874mzqlyws.fsf@hillenius.net> <87oaxx2lah.fsf@descartes.rss.mhs.man.ac.uk> <8761k5m5ga.fsf@micropit.roche-blanche.homenet.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1402659175 28017 80.91.229.3 (13 Jun 2014 11:32:55 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 13 Jun 2014 11:32:55 +0000 (UTC) To: ding@gnus.org Original-X-From: ding-owner+M32853@lists.math.uh.edu Fri Jun 13 13:32:49 2014 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1WvPiu-0006Dp-Tf for ding-account@gmane.org; Fri, 13 Jun 2014 13:32:46 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1WvPik-00051t-7M; Fri, 13 Jun 2014 06:32:34 -0500 Original-Received: from mx1.math.uh.edu ([129.7.128.32]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1WvPii-00051h-HT for ding@lists.math.uh.edu; Fri, 13 Jun 2014 06:32:32 -0500 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx1.math.uh.edu with esmtps (TLSv1:AES128-SHA:128) (Exim 4.76) (envelope-from ) id 1WvPih-000264-Dt for ding@lists.math.uh.edu; Fri, 13 Jun 2014 06:32:32 -0500 Original-Received: from plane.gmane.org ([80.91.229.3]) by quimby.gnus.org with esmtp (Exim 4.80) (envelope-from ) id 1WvPig-0003Hu-26 for ding@gnus.org; Fri, 13 Jun 2014 13:32:30 +0200 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1WvPie-000611-Jv for ding@gnus.org; Fri, 13 Jun 2014 13:32:28 +0200 Original-Received: from arennes-651-1-364-33.w2-14.abo.wanadoo.fr ([2.14.203.33]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 13 Jun 2014 13:32:28 +0200 Original-Received: from pmlists by arennes-651-1-364-33.w2-14.abo.wanadoo.fr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 13 Jun 2014 13:32:28 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 38 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: arennes-651-1-364-33.w2-14.abo.wanadoo.fr User-Agent: Gnus/5.130012 (=?utf-8?Q?=E7=9C=9F?= Gnus v0.12) Emacs/24.4.50 (gnu/linux) Cancel-Lock: sha1:cAfD1eWRStjOTAjFHSfxbaU+Wms= X-Spam-Score: -2.5 (--) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:84608 Archived-At: On Fri, Jun 13 2014, Peter Münster wrote: > (defun pm/message-send () > (unless (message-field-value gnus-delay-header) ; see http://article.gmane.org/gmane.emacs.gnus.general/84598 > (unless (string-equal pm/role "list") ; no gpg stuff in lists > (if (jl-epg-check-unique-keys (jl-mail-recipients)) > (mml-secure-message-sign-encrypt) > (mml-secure-message-sign))) > (or (pm/spell) (keyboard-quit)))) ; see http://article.gmane.org/gmane.emacs.gnus.general/84461 > > (add-hook 'message-send-hook 'pm/message-send) Sorry, for this to work, I had to remove some lines from jl-encrypt.el: --8<---------------cut here---------------start------------->8--- $ diff -u jl-encrypt.el~ jl-encrypt.el --- jl-encrypt.el~ 2014-05-26 16:32:09.973674503 +0200 +++ jl-encrypt.el 2014-05-26 20:12:24.641922293 +0200 @@ -203,15 +203,12 @@ ;; (all necessary public keys are available). ;; In the past, this could have prevented me from sending plaintext e-mails ;; that should have been sent encrypted. -(define-key message-mode-map (kbd "C-c C-c") 'jl-message-send-and-exit) -(define-key message-mode-map (kbd "C-c C-s") 'jl-message-send) ;; Make gnus insert MML encryption tags if keys for all recipients are ;; available. Thus, if you reply (or wide reply) to a message or edit ;; a saved draft, then MML encryption tags will be inserted right away. ;; Moreover, if jl-encrypt-insert-signature is always, an MML signature ;; tag will be added immediately. -(add-hook 'gnus-message-setup-hook 'jl-encrypt-if-possible) (defgroup jl-encrypt nil "Customization options for jl-encrypt.el.") --8<---------------cut here---------------end--------------->8--- -- Peter