From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ted Zlatanov Subject: Re: Capturing outgoing gnus e-mail Date: Wed, 24 Sep 2014 17:04:35 -0400 Message-ID: <87ppekk9wc.fsf@lifelogs.com> References: <8761k3rivi.fsf@kanis.fr> Reply-To: ding@gnus.org Mime-Version: 1.0 Content-Type: text/plain Return-path: To: ding@gnus.org Cc: emacs-orgmode@gnu.org List-Id: emacs-orgmode.gnu.org On Sat, 14 Jun 2014 10:32:49 +0200 Ivan Kanis wrote: IK> I would like to capture outgoing e-mail in my org file. IK> I use the gcc mechanism in gnus with a nnml backend. IK> I think I have read on the org mailing list that someone has implemented IK> that feature. I did a search but could not find the article. IK> I tried implementing it myself. I had a look at the function IK> gnus-inews-do-gcc. It has the group and the article number. However org IK> link expect the Message-ID header. How do I get it? Well, I use the following to maintain a diary file. It's probably equally easy to use a Org file: (defun message-to-diary () (make-diary-entry (concat (format-time-string "%B %d, %Y %H:%M" (gnus-date-get-time (message-fetch-field "date"))) (if (message-fetch-field "newsgroups") (concat " Sent news To: " (message-fetch-field "newsgroups")) (concat " Sent mail To: " (message-fetch-field "to"))) " Subject: \"" (message-fetch-field "subject") "\"" " Message-ID: " (message-fetch-field "message-id"))) (save-buffer "diary")) (add-hook 'message-sent-hook 'message-to-diary) HTH Ted