On Sat, 14 Jun 2014 10:32:49 +0200 Ivan Kanis <i...@kanis.fr> 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