comparison mercurial/util.py @ 1958:f92cf4a8cedd

merge with crew
author Benoit Boissinot <benoit.boissinot@ens-lyon.org>
date Wed, 15 Mar 2006 07:15:13 +0100
parents 16750010813d 379ab45b91b7
children df8416346bb7
comparison
equal deleted inserted replaced
1957:295010327271 1958:f92cf4a8cedd
740 tz = time.altzone 740 tz = time.altzone
741 else: 741 else:
742 tz = time.timezone 742 tz = time.timezone
743 return time.mktime(lt), tz 743 return time.mktime(lt), tz
744 744
745 def datestr(date=None, format='%c'): 745 def datestr(date=None, format='%a %b %d %H:%M:%S %Y'):
746 """represent a (unixtime, offset) tuple as a localized time. 746 """represent a (unixtime, offset) tuple as a localized time.
747 unixtime is seconds since the epoch, and offset is the time zone's 747 unixtime is seconds since the epoch, and offset is the time zone's
748 number of seconds away from UTC.""" 748 number of seconds away from UTC."""
749 t, tz = date or makedate() 749 t, tz = date or makedate()
750 return ("%s %+03d%02d" % 750 return ("%s %+03d%02d" %