X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;ds=sidebyside;f=doc%2Fgetdate.texi;h=e7947800d383c8eea895aba760b5b16f84350e3a;hb=63983c0aac914c1a585cb6a7d0b16dc170b6ee3e;hp=0150ff21f34b1fba3a7609f83f43876f1821cafc;hpb=04cdf1f369b660e295350b6d0a0cfdfd74eacca5;p=gnulib.git diff --git a/doc/getdate.texi b/doc/getdate.texi index 0150ff21f..e7947800d 100644 --- a/doc/getdate.texi +++ b/doc/getdate.texi @@ -1,10 +1,10 @@ @c GNU date syntax documentation @c Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -@c 2003, 2004, 2005 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006 Free Software Foundation, Inc. @c Permission is granted to copy, distribute and/or modify this document -@c under the terms of the GNU Free Documentation License, Version 1.1 or +@c under the terms of the GNU Free Documentation License, Version 1.3 or @c any later version published by the Free Software Foundation; with no @c Invariant Sections, with no Front-Cover Texts, and with no Back-Cover @c Texts. A copy of the license is included in the ``GNU Free @@ -144,6 +144,11 @@ between round parentheses, as long as included parentheses are properly nested. Hyphens not followed by a digit are currently ignored. Leading zeros on numbers are ignored. +Invalid dates like @samp{2005-02-29} or times like @samp{24:00} are +rejected. In the typical case of a host that does not support leap +seconds, a time like @samp{23:59:60} is rejected even if it +corresponds to a valid leap second. + @node Calendar date items @section Calendar date items @@ -238,7 +243,8 @@ a number between 0 and 23, @var{minute} is a number between 0 and @samp{.} or @samp{,} and a fraction containing one or more digits. Alternatively, @samp{:@var{second}} can be omitted, in which case it is taken to -be zero. +be zero. On the rare hosts that support leap seconds, @var{second} +may be 60. @findex am @r{in date strings} @findex pm @r{in date strings} @@ -259,16 +265,19 @@ which uses @samp{12m} for noon and @samp{12pm} for midnight.) The time may alternatively be followed by a time zone correction, expressed as @samp{@var{s}@var{hh}@var{mm}}, where @var{s} is @samp{+} or @samp{-}, @var{hh} is a number of zone hours and @var{mm} is a number -of zone minutes. You can also separate @var{hh} from @var{mm} with a colon. +of zone minutes. +The zone minutes term, @var{mm}, may be omitted, in which case +the one- or two-digit correction is interpreted as a number of hours. +You can also separate @var{hh} from @var{mm} with a colon. When a time zone correction is given this way, it forces interpretation of the time relative to Coordinated Universal Time (@sc{utc}), overriding any previous specification for the time zone or the local time zone. For example, @samp{+0530} and @samp{+05:30} both stand for the time zone 5.5 hours -ahead of @sc{utc} (e.g., India). The @var{minute} -part of the time of day may not be elided when a time zone correction -is used. This is the best way to specify a time zone correction by -fractional parts of an hour. +ahead of @sc{utc} (e.g., India). +This is the best way to +specify a time zone correction by fractional parts of an hour. +The maximum zone correction is 24 hours. Either @samp{am}/@samp{pm} or a time zone correction may be specified, but not both. @@ -464,8 +473,8 @@ integers and can represent times from 1901-12-13 20:45:52 through of seconds with nanosecond subcounts, and can represent all the times in the known lifetime of the universe to a resolution of 1 nanosecond. -On most systems, these counts ignore the presence of leap seconds. -For example, on most systems @samp{@@915148799} represents 1998-12-31 +On most hosts, these counts ignore the presence of leap seconds. +For example, on most hosts @samp{@@915148799} represents 1998-12-31 23:59:59 @sc{utc}, @samp{@@915148800} represents 1999-01-01 00:00:00 @sc{utc}, and there is no way to represent the intervening leap second 1998-12-31 23:59:60 @sc{utc}.