From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ulf Stegemann Subject: Store link in message mode Date: Mon, 15 Nov 2010 13:43:14 +0100 Message-ID: Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from [140.186.70.92] (port=35655 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PHyPE-0006lB-NI for emacs-orgmode@gnu.org; Mon, 15 Nov 2010 07:43:34 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PHyPA-0007xg-Nt for emacs-orgmode@gnu.org; Mon, 15 Nov 2010 07:43:32 -0500 Received: from lo.gmane.org ([80.91.229.12]:41470) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PHyPA-0007xF-C3 for emacs-orgmode@gnu.org; Mon, 15 Nov 2010 07:43:28 -0500 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1PHyP8-0006OJ-8E for emacs-orgmode@gnu.org; Mon, 15 Nov 2010 13:43:26 +0100 Received: from london.zeitform.net ([146.140.213.100]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 15 Nov 2010 13:43:26 +0100 Received: from ulf-news by london.zeitform.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 15 Nov 2010 13:43:26 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org After it's now possible for me to store an org link upon sending a message[1] I thought it might be even better to approach this problem in a more general way. The idea is to use `org-store-link' in message mode to create a link for the (yet to come) copy of the message. Currently `org-store-link' seems to be rather pointless in message mode as it creates a link to a draft (temporary) message file. Extending `org-gnus-store-link' to let it create a gnus link to the copy of the message when in message mode seems to be more reasonable. However, there are some, er, `issues' with this. 1) This will only work with Gnus. Message mode is in principle independent of Gnus but non-Gnus users will not benefit from `org-store-link' in message mode. 2) Storing a link in message mode effectively creates a link to something (the mail copy) that's (still) inexistent. This means that the link remains invalid until the message is actually sent (or more precisely: the copy is created upon sending). Furthermore, the link will be invalid if - the message is not sent; - the Gcc header is modified to point to a different group; - the message id is changed. And of course, the link description will be incorrect if Subject, From and/or To headers are changed between calling `org-store-link' and creating the message's copy. If you think --despite of those issues-- it's worth adding the creation of gnus links while in message mode I could provide a patch. I'd probably add the functionality to `org-gnus-store-link' but I'm not an org code expert and a different location may be more appropriate. What do you think? Ulf References: [1] see http://thread.gmane.org/gmane.emacs.orgmode/31280