[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[emacs-wiki-discuss] Re: gnus sent messages
From: |
Sacha Chua |
Subject: |
[emacs-wiki-discuss] Re: gnus sent messages |
Date: |
Sat, 17 Jun 2006 18:44:44 -0400 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
Charles Hachten <address@hidden> writes:
> But recently I started wondering whether it was possible to further
> integrate planner with gnus such that when you send a message using
> gnus, a link to the sent letter could be or would automatically be
> listed on a planner day page. Is this possible? I'm not really a
> programmer so I wouldn't be able to do it myself.
Mmkay, this snippet seems to work for me...
;;;_+ Keep track of sent messages
(defun sacha/planner-gnus-track-sent ()
"Add this to `message-sent-hook' to keep track of messages sent on your daily
page.
Result: Adds it to * E-mail."
;; Grab the header
(let (text)
(setq text
(planner-make-link
(concat "gnus://" gnus-newsgroup-name "/"
(planner-gnus-get-message-id))
(concat (planner-get-name-from-address (planner-gnus-get-address
"To"))
": "
(message-fetch-field "Subject"))))
(save-window-excursion
(save-excursion
(planner-goto-today)
(planner-seek-to-first "E-mail sent")
(insert " - " text "\n"))))
nil)
(add-hook 'message-mode-hook
(lambda ()
(add-hook 'message-sent-hook 'sacha/planner-gnus-track-sent)))
--
Sacha Chua <address@hidden> - http://sacha.free.net.ph/
Technology evangelist wannabe and apprentice of all things
University of Toronto - IBM Center for Advanced Studies, Toronto
Interest: enterprise social computing (particularly bookmarking)
- [emacs-wiki-discuss] Re: gnus sent messages,
Sacha Chua <=