From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matt Lundin Subject: Re: icalendar: exporting times of day specified in heading? Date: Wed, 17 Mar 2010 09:26:03 -0400 Message-ID: <87ocinuljo.fsf@fastmail.fm> References: <15490.1263652716@cpc1-cmbg14-2-0-cust6.5-4.cable.virginmedia.com> <11681.1265116614@maps> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NrtFl-0000gF-1K for emacs-orgmode@gnu.org; Wed, 17 Mar 2010 09:25:41 -0400 Received: from [140.186.70.92] (port=39830 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NrtFj-0000fm-Mw for emacs-orgmode@gnu.org; Wed, 17 Mar 2010 09:25:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NrtFh-00059T-Nr for emacs-orgmode@gnu.org; Wed, 17 Mar 2010 09:25:39 -0400 Received: from out3.smtp.messagingengine.com ([66.111.4.27]:60308) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NrtFh-000596-Kl for emacs-orgmode@gnu.org; Wed, 17 Mar 2010 09:25:37 -0400 In-Reply-To: <11681.1265116614@maps> (Stephen Eglen's message of "Tue, 02 Feb 2010 13:16:54 +0000") 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: Stephen Eglen Cc: emacs-orgmode@gnu.org, Carsten Dominik Hi Stephen, Sorry for the late reply, but I've just begun using "i d" to enter dates into my org files and I have a few comments on the patch you submitted in February. Stephen Eglen writes: >> >> I often use org-agenda-diary-entry to make simple entries into >> an agenda.org file. I see that the agenda is clever enough to recognise >> if a time range has been typed into the heading. However, this time >> range is not exported by the icalendar code. > > Attached is a patch to the code underlying 'i d' entries in the *Org > Agenda* buffer. If a time of day is specified in the entry, it is > extracted from the entry and put into the timestamp of the diary entry. > (The .ics exporting code recognises these timestamps and therefore the > ics export code does not need altering.) > > For example, given the following three entries added using 'i d' from > *Org Agenda*: > > i d RET test 1 12:00-14:00 classes RET > i d RET test 2 did you get 7am wake up call? RET > i d RET test 3 find 3--5 volunteers RET > > then the following entries are added to agenda.org: > > *** 2010-02-03 Wednesday > > **** test 3 find 3--5 volunteers > <2010-02-03 Wed> > **** test 2 did you get wake up call? > <2010-02-03 Wed 07:00> > **** test 1 classes > <2010-02-03 Wed 12:00-14:00> When I enter the time of day after typing "i d", the time of day is added to the timestamp (as above) but is *not* removed the headline. E.g., --8<---------------cut here---------------start------------->8--- "Day entry: 9:00am go shopping [RET]" --8<---------------cut here---------------end--------------->8--- ...results in the following headline... --8<---------------cut here---------------start------------->8--- * 9:00am go shopping <2010-03-17 Wed 09:00> --8<---------------cut here---------------end--------------->8--- As a consequence, the agenda line duplicates the time of day. --8<---------------cut here---------------start------------->8--- index: 9:00...... 9:00am go shopping --8<---------------cut here---------------end--------------->8--- I'd be curious to know whether others can duplicate this bug. > As this behvaiour may not be desired by all, I've currently put the code > conditional on org-agenda-search-headline-for-time being non-nil (the > default is t). If that variable is nil, then the above three test > entries generates the regular tree: Might I request an independent variable for this? While I would like the agenda to scan my headlines for time of day specifications (and thus have org-agenda-search-headline-for-time set to t), I am not sure I want org-agenda-add-entry-to-org-agenda-diary-file to alter the information I enter at the "Day entry: " prompt. Thanks, Matt