X-Git-Url: http://git.sthu.org/?a=blobdiff_plain;ds=sidebyside;f=bib2html.py;h=72a57718d7ab96976e315531b5774b74d7d37dae;hb=9ff084ff106b955d5dcc9ceb3b31ba4c1f0d46c5;hp=64286f25ed25a3c513164c6481194e67f8280be2;hpb=e9ca613da889135e668f419e7b8f3b0aaa265dfb;p=shutils.git diff --git a/bib2html.py b/bib2html.py index 64286f2..72a5771 100755 --- a/bib2html.py +++ b/bib2html.py @@ -136,11 +136,16 @@ def entryDateSortKey(p): 'apr' : '04', 'may' : '05', 'jun' : '06', \ 'jul' : '07', 'aug' : '08', 'sep' : '09', \ 'oct' : '10', 'nov' : '11', 'dec' : '12'} + + if not 'month' in e.fields: + return e.fields['year'] + month = e.fields['month'].lower()[0:3] if month in month2num: month = month2num[month] else: month = "" + return e.fields['year'] + "-" + month