Author: fw Date: 2011-05-06 19:07:21 +0000 (Fri, 06 May 2011) New Revision: 16636 Modified: bin/gen-DSA.py Log: bin/gen-DSA.py: pad days in date strings with zero if necessary Modified: bin/gen-DSA.py ==================================================================--- bin/gen-DSA.py 2011-05-06 19:03:19 UTC (rev 16635) +++ bin/gen-DSA.py 2011-05-06 19:07:21 UTC (rev 16636) @@ -144,7 +144,7 @@ tm = time.gmtime(time.time()) def getdate(months=" January February March April May June July August September October November December".split()): - return "{0} {1:0}, {2}".format(months[tm.tm_mon], tm.tm_mday, tm.tm_year) + return "{0} {1:02}, {2}".format(months[tm.tm_mon], tm.tm_mday, tm.tm_year) dsa_list_path = debian_support.findresource(*"data DSA list".split()) def checklist(): @@ -156,7 +156,7 @@ def fordsalist(versions, months=" Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec".split()): - lines = ["[{0:0} {1} {2}] DSA-{3} {4} - {5}\n".format( + lines = ["[{0:02} {1} {2}] DSA-{3} {4} - {5}\n".format( tm.tm_mday, months[tm.tm_mon], tm.tm_year, opt_dsaid, opt_package, opt_vulnerability)] if opt_cve: