Adeodato Simó wrote:
Fri Jun 23 22:01:52 CEST 2006 Adeodato Simó <[EMAIL PROTECTED]>
* bzr target: fix conversion of date to local timestamp
Calculate local timestamp from supplied date correctly, taking into
account that mktime() cares about the local timezone. Also, provide a
correct timezone to bzr if the commit happened in DST while tailor runs
during standard time, or viceversa.
Fri Jun 23 22:02:48 CEST 2006 Adeodato Simó <[EMAIL PROTECTED]>
* bzr target: use date.tzinfo if present
Allow further control over the timezone of each commit by using
date.tzinfo if present to calculate the timezone, instead of assuming
the local timezone. date.tzinfo can be provided eg. in a before-commit
function.
Hi,
first of all, thanks a lot for the nice and clear test case. Then to
provide even the fixes for bzr!
I was about to apply your patches, when I realized that a similar fix
would reasonably be mirrored on other backends too.
More, I'm not pleased about forcing use of an hook to fix the dst bit.
What about generalizing the concept
[DEFAULT]
verbose = False
[dummy]
target = bzr:dummy
source = svn:dummy
root-directory = /tmp/tailor
state-file = dummy.state
[bzr:dummy]
subdir = bzr
timezone = UTC
[svn:dummy]
subdir = svn
module = /
repository = file:///tmp/tailor/dummy
timezone = Europe/Madrid
Both timezones would default to local one (basically what happens right
now). By specifying one, the backend should perform the needed
conversion to/from UTC (respectively for the source and the target backend).
What do you think?
I'm sad not having much spare time for tailor right now, but I'll try to
figure out how your test could be integrated and generalized for other
backends. That would be beautiful.
thanks again,
ciao, lele.
_______________________________________________
Tailor mailing list
[email protected]
http://lists.zooko.com/mailman/listinfo/tailor