diff options
| author | Nick Mathewson <nickm@torproject.org> | 2004-02-22 00:18:18 +0000 |
|---|---|---|
| committer | Nick Mathewson <nickm@torproject.org> | 2004-02-22 00:18:18 +0000 |
| commit | 3118c4faf912213683061c76248d70adcee78340 (patch) | |
| tree | d7d3afb7afd5f3230ae4191488d87478afe86b7a /writeHTML.py | |
| parent | 19593ff205af53d2467c68384704fdf3cd12b94e (diff) | |
| download | anonbib-3118c4faf912213683061c76248d70adcee78340.tar.gz | |
Implement a 'draft' article category for submitted but unpublished stuff.
If you create an entry with year=='forthcoming', it will appear in a
year called "Forthcoming", in the CSS class 'draftEntry'.
Add draft-tor-design-2004 as an example.
svn:r88
Diffstat (limited to 'writeHTML.py')
| -rw-r--r-- | writeHTML.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/writeHTML.py b/writeHTML.py index 543857a..9f6a0fa 100644 --- a/writeHTML.py +++ b/writeHTML.py @@ -102,8 +102,11 @@ f.close() entries = BibTeX.sortEntriesByDate(bib.entries) entries = BibTeX.splitSortedEntriesBy(entries, 'year') -if entries[-1][0].startswith("<span class='bad'>"): - entries[-1] = ("Unknown", entries[-1][1]) +for idx in -1, -2: + if entries[idx][0].startswith("<span class='bad'>"): + entries[idx] = ("Unknown", entries[idx][1]) + elif entries[idx][0].startswith("forthcoming"): + entries[idx] = ("Forthcoming", entries[idx][1]) sections = [ ent[0] for ent in entries ] first_year = int(entries[0][1][0]['year']) |
