# HG changeset patch # User TK Soh # Date 1142402490 28800 # Node ID 379ab45b91b78a21da028211aa395eda61ffe6b1 # Parent 696230e52e4dc9bb2b78e59c60b6c41027e5d974 change default strftime format for better portability On some systems, such as Solaris and HP-UX, "%c" format give output without the leading zero on the single-digit month-day. diff -r 696230e52e4d -r 379ab45b91b7 mercurial/util.py --- a/mercurial/util.py Tue Mar 14 21:40:46 2006 -0800 +++ b/mercurial/util.py Tue Mar 14 22:01:30 2006 -0800 @@ -742,7 +742,7 @@ tz = time.timezone return time.mktime(lt), tz -def datestr(date=None, format='%c'): +def datestr(date=None, format='%a %b %d %H:%M:%S %Y'): """represent a (unixtime, offset) tuple as a localized time. unixtime is seconds since the epoch, and offset is the time zone's number of seconds away from UTC.""" diff -r 696230e52e4d -r 379ab45b91b7 tests/test-remove --- a/tests/test-remove Tue Mar 14 21:40:46 2006 -0800 +++ b/tests/test-remove Tue Mar 14 22:01:30 2006 -0800 @@ -8,10 +8,10 @@ rm foo hg remove foo hg commit -m 2 -d "1000000 0" -hg export 0 | sed -e "s/Thu Jan 01/Thu Jan 1/" -hg export 1 | sed -e "s/Thu Jan 01/Thu Jan 1/" -hg log -p -r 0 | sed -e "s/Thu Jan 01/Thu Jan 1/" -hg log -p -r 1 | sed -e "s/Thu Jan 01/Thu Jan 1/" +hg export 0 +hg export 1 +hg log -p -r 0 +hg log -p -r 1 cd .. hg clone a b diff -r 696230e52e4d -r 379ab45b91b7 tests/test-remove.out --- a/tests/test-remove.out Tue Mar 14 21:40:46 2006 -0800 +++ b/tests/test-remove.out Tue Mar 14 22:01:30 2006 -0800 @@ -5,7 +5,7 @@ 1 diff -r 000000000000 -r 8ba83d44753d foo ---- /dev/null Thu Jan 1 00:00:00 1970 +0000 +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/foo Mon Jan 12 13:46:40 1970 +0000 @@ -0,0 +1,1 @@ +a @@ -17,7 +17,7 @@ diff -r 8ba83d44753d -r a1fce69c50d9 foo --- a/foo Mon Jan 12 13:46:40 1970 +0000 -+++ /dev/null Thu Jan 1 00:00:00 1970 +0000 ++++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,1 +0,0 @@ -a changeset: 0:8ba83d44753d @@ -26,7 +26,7 @@ summary: 1 diff -r 000000000000 -r 8ba83d44753d foo ---- /dev/null Thu Jan 1 00:00:00 1970 +0000 +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/foo Mon Jan 12 13:46:40 1970 +0000 @@ -0,0 +1,1 @@ +a @@ -40,7 +40,7 @@ diff -r 8ba83d44753d -r a1fce69c50d9 foo --- a/foo Mon Jan 12 13:46:40 1970 +0000 -+++ /dev/null Thu Jan 1 00:00:00 1970 +0000 ++++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,1 +0,0 @@ -a