date issue converting a cvs repo

Ken Blake kblake2 at gmail.com
Fri May 1 14:13:28 CDT 2009


On Fri, May 1, 2009 at 10:43 AM, Stephen Rasku <mercurial at srasku.net> wrote:
> On Fri, May 1, 2009 at 08:25, Ken Blake <kblake2 at gmail.com> wrote:
>> I converted my companies cvs repo to hg with no problems but when I
>> ran hg serve I noticed the first date listed as "in the future".
>
> Is the changeset that's in the future the Mercurial file .hgtags or
> does it contain files from your CVS repository?
>
Yes, it is the .hgtags file with the author convert-repo.  Now enough
time has past that it no longer is in the future.

I picked a commit of mine to compare the dates:
my local mercurial repo:  2009-04-10 14:35 -0500
cvs repo:                         2009/04/10 20:21:58
converted hg repo:          2009-04-10 20:21 +0000

The first line shows when I committed to my local repo and has the
local time.  Roughly 45 minutes later I committed the change to the
cvs repo which is in UTC.  Later I converted the cvs repo and used hg
log to get the date of the same commit (3rd line), which is the same
time as cvs reports so it too is in UTC.

Both the hg server and entering hg log from the command line report
the same time.  If the server just reported the date in UTC I could
understand that since it may be difficult to know the client's time
zone but then how does it compute a future offset if it doesn't know
the local time?

It appears that hg log converts to local time in my development repo,
but doesn't convert dates in the converted cvs repo.  I don't
understand why these are behaving differently.

Ken


More information about the Mercurial mailing list