From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?iso-8859-1?Q?Vincent_Bela=EFche?= Newsgroups: gmane.emacs.devel Subject: ISO dates, correction on Org documentation Date: Fri, 18 Sep 2009 07:44:35 +0200 Message-ID: <87iqfglscc.fsf@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: ger.gmane.org 1253338460 9703 80.91.229.12 (19 Sep 2009 05:34:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 19 Sep 2009 05:34:20 +0000 (UTC) Cc: emacs-devel@gnu.org To: carsten.dominik@gmail.com Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Sep 19 07:34:13 2009 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MosaK-0000NG-Ls for ged-emacs-devel@m.gmane.org; Sat, 19 Sep 2009 07:34:12 +0200 Original-Received: from localhost ([127.0.0.1]:60451 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MosaJ-0003ZH-V9 for ged-emacs-devel@m.gmane.org; Sat, 19 Sep 2009 01:34:11 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MosaC-0003ZB-Ut for emacs-devel@gnu.org; Sat, 19 Sep 2009 01:34:05 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Mosa7-0003Yx-TP for emacs-devel@gnu.org; Sat, 19 Sep 2009 01:34:03 -0400 Original-Received: from [199.232.76.173] (port=51131 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mosa7-0003Yu-Ly for emacs-devel@gnu.org; Sat, 19 Sep 2009 01:33:59 -0400 Original-Received: from smtp28.orange.fr ([80.12.242.101]:11716) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Mosa7-0002RS-65 for emacs-devel@gnu.org; Sat, 19 Sep 2009 01:33:59 -0400 Original-Received: from me-wanadoo.net (localhost [127.0.0.1]) by mwinf2819.orange.fr (SMTP Server) with ESMTP id 8559C80000A7; Sat, 19 Sep 2009 07:33:57 +0200 (CEST) Original-Received: from me-wanadoo.net (localhost [127.0.0.1]) by mwinf2819.orange.fr (SMTP Server) with ESMTP id 79A3480000A0; Sat, 19 Sep 2009 07:33:57 +0200 (CEST) Original-Received: from COCOTTE (ARennes-353-1-44-5.w86-214.abo.wanadoo.fr [86.214.79.5]) by mwinf2819.orange.fr (SMTP Server) with ESMTP id 0899280000A7; Sat, 19 Sep 2009 07:33:56 +0200 (CEST) X-ME-UUID: 20090919053357353.0899280000A7@mwinf2819.orange.fr X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:115478 Archived-At: --=-=-= Content-Disposition: inline Hello Dominik, The Org mode documentation says that Org mode uses ISO time stamps. Although Org mode date/time format is inspired by ISO, it is not fully compliant, see for instance http://fr.wikipedia.org/wiki/ISO_8601 on ISO date and time format. I corrected the documentation and attached a patch. FYI, in ISO date/time format looks like this: 2009-09-18T07:16 while Org mode is like that <2009-09-18 ven. 07:16> (this timestamp was generated by `C-c .' on my machine, `ven.' means `Fri' in French). Intervals and are supported by ISO, with a `/' separator, while org uses a `-' separator which is ambiguous in ISO (+ or - are used for the time zone). ISO also supports intervals specified with a duration with the `P' seperator, such intervals may be defined relative to begin date or end date ISO also supports repetitions with the `R' separator, while Org uses a `+' separator. If ever you want to implement ISO 8601 format into Org, I suggests that ISO8601 timesamps/time interval are encapsulated into `' where the leading `I' would help Org to disambiguate from native Org mode format (although in case where `T', `P' or `R' is used, it is possible to guess it's an ISO format. So the example I gave would be: There could also be some relaxed ISO using an `i' prefix like this: where the day short name (eg. `ven.') is shown between backets, as it is cool to have this information. Relaxed ISO would just strip _anything_ between brackets before interpreting the timestamp, so it would be quite robust to locale stuff (like `ven.' instead of `Fri'). Very best regards, Vincent. PS: I may contribute on this, if you wish. --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=org.texi.diff Content-Description: ISO dates, correction on Org documentation *** org.texi.old Fri Sep 11 19:30:09 2009 --- org.texi Fri Sep 18 04:59:29 2009 *************** *** 4831,4844 **** @cindex deadlines @cindex scheduling ! A timestamp is a specification of a date (possibly with a time or a range ! of times) in a special format, either @samp{<2003-09-16 Tue>} or @samp{<2003-09-16 Tue 09:39>} or @samp{<2003-09-16 Tue ! 12:00-12:30>}@footnote{This is the standard ISO date/time format. To ! use an alternative format, see @ref{Custom time format}.}. A timestamp ! can appear anywhere in the headline or body of an Org tree entry. Its ! presence causes entries to be shown on specific dates in the agenda ! (@pxref{Weekly/daily agenda}). We distinguish: @table @var @item Plain timestamp; Event; Appointment --- 4831,4844 ---- @cindex deadlines @cindex scheduling ! A timestamp is a specification of a date (possibly with a time or a range of ! times) in a special format, either @samp{<2003-09-16 Tue>} or @samp{<2003-09-16 Tue 09:39>} or @samp{<2003-09-16 Tue ! 12:00-12:30>}@footnote{This format is inspired by the standard ISO 8601 ! date/time format. To use an alternative format, see @ref{Custom time ! format}.}. A timestamp can appear anywhere in the headline or body of an Org ! tree entry. Its presence causes entries to be shown on specific dates in the ! agenda (@pxref{Weekly/daily agenda}). We distinguish: @table @var @item Plain timestamp; Event; Appointment *************** *** 4985,4992 **** @cindex time, reading in minibuffer @vindex org-read-date-prefer-future ! When Org mode prompts for a date/time, the default is shown as an ISO ! date, and the prompt therefore seems to ask for an ISO date. But it will in fact accept any string containing some date and/or time information, and it is really smart about interpreting your input. You can, for example, use @kbd{C-y} to paste a (possibly multi-line) string --- 4985,4993 ---- @cindex time, reading in minibuffer @vindex org-read-date-prefer-future ! When Org mode prompts for a date/time, the default value is shown in default ! date/time format which looks like an ISO date, and the prompt therefore seems ! to ask for a date/time in this format. But it will in fact accept any string containing some date and/or time information, and it is really smart about interpreting your input. You can, for example, use @kbd{C-y} to paste a (possibly multi-line) string --=-=-=--