From c496931fdd604b1461a378d3b7f2123d5866354a Mon Sep 17 00:00:00 2001 From: jhermann Date: Wed, 23 Jan 2002 20:00:50 +0000 Subject: [PATCH] %e is a UNIXism and not documented for Python git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@597 57a73879-2fb5-44c3-a270-3262357dd7e2 --- roundup/date.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/roundup/date.py b/roundup/date.py index bc96c83..d9ac758 100644 --- a/roundup/date.py +++ b/roundup/date.py @@ -15,7 +15,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -# $Id: date.py,v 1.17 2002-01-16 07:02:57 richard Exp $ +# $Id: date.py,v 1.18 2002-01-23 20:00:50 jhermann Exp $ __doc__ = """ Date, time and time interval handling. @@ -168,8 +168,10 @@ class Date: def pretty(self): ''' print up the date date using a pretty format... ''' - return time.strftime('%e %B %Y', (self.year, self.month, + str = time.strftime('%d %B %Y', (self.year, self.month, self.day, self.hour, self.minute, self.second, 0, 0, 0)) + if str[0] == '0': return ' ' + str[1:] + return str def set(self, spec, offset=0, date_re=re.compile(r''' (((?P\d\d\d\d)-)?((?P\d\d?)-(?P\d\d?))?)? # yyyy-mm-dd @@ -383,6 +385,10 @@ if __name__ == '__main__': # # $Log: not supported by cvs2svn $ +# Revision 1.17 2002/01/16 07:02:57 richard +# . lots of date/interval related changes: +# - more relaxed date format for input +# # Revision 1.16 2002/01/08 11:56:24 richard # missed an import _ # -- 2.30.2