From a6dc53fe20316523a990e2424fb693a3bfc8a94f Mon Sep 17 00:00:00 2001 From: Borgar Date: Sun, 12 Jun 2011 20:35:48 +0000 Subject: [PATCH] Adding a date format with seconds. --- pelican/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pelican/utils.py b/pelican/utils.py index 8e48c2e9..2fb76670 100644 --- a/pelican/utils.py +++ b/pelican/utils.py @@ -15,7 +15,7 @@ def get_date(string): If no format matches the given date, raise a ValuEerror """ formats = ['%Y-%m-%d %H:%M', '%Y/%m/%d %H:%M', '%Y-%m-%d', '%Y/%m/%d', - '%d/%m/%Y', '%d.%m.%Y', '%d.%m.%Y %H:%M'] + '%d/%m/%Y', '%d.%m.%Y', '%d.%m.%Y %H:%M', '%Y-%m-%d %H:%M:%S'] for date_format in formats: try: return datetime.strptime(string, date_format)