Thu Mar 26 19:58:42 UTC 2009 gaetan.lehmann@jouy.inra.fr
* add the year in the date field if the patch wasn't made in the current year
diff -rN -u old-darcsweb/darcsweb.cgi new-darcsweb/darcsweb.cgi
--- old-darcsweb/darcsweb.cgi 2015-10-12 15:02:47.000000000 +0000
+++ new-darcsweb/darcsweb.cgi 2015-10-12 15:02:47.000000000 +0000
@@ -128,7 +128,11 @@
# the cached entries will have old data; so in this case just
# return a nice string
t = time.localtime(epoch)
- s = time.strftime("%d %b %H:%M", t)
+ currentYear = time.localtime()[0]
+ if t[0] == currentYear:
+ s = time.strftime("%d %b %H:%M", t)
+ else:
+ s = time.strftime("%d %b %Y %H:%M", t)
return s
age = int(time.time()) - int(epoch)
if age > 60*60*24*365*2: