Improved date support
mpm at selenic.com
Tue Dec 12 21:38:23 CST 2006
On Tue, Dec 12, 2006 at 09:32:10PM -0600, TK Soh wrote:
> On 12/12/06, Matt Mackall <mpm at selenic.com> wrote:
> >> Is the date UTC? I tried on the latest crew and got this:
> >No. It's localtime unless you add a timezone. "hg help dates" is a
> >little clearer about this than my message. Dec 12 in SGT runs from
> >Dec 11 16:00 UTC to Dec 12 16:00 UTC
> So the search/comparison is done on UTC basis? Meaning the cs dates
> and the --date argument are 'converted' to UTC prior to action?
Date arguments are converted to (seconds since epoch UTC, timezone
offset), which matches the internal storage format.
Comparisons are made only on the seconds field of that tuple.
For date ranges, "Dec 12" is converted to "Dec 12 00:00:00 to Dec 12
23:59:59". Similar conversion apply for "Dec 12 04:00", "Dec", and "2006".
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial-devel