aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2003-05-23 02:44:18 +0000
committerNick Mathewson <nickm@torproject.org>2003-05-23 02:44:18 +0000
commit9f98a5610bfe7b40d9ffe751dbf87a851d823f29 (patch)
treeaeec3e5acc8847435d2e83ac054c0bdbe0845e3b
parenta5d4c56336ec216006fe830f630b7de5dde5c67a (diff)
downloadanonbib-9f98a5610bfe7b40d9ffe751dbf87a851d823f29.tar.gz
better TODO
svn:r31
-rw-r--r--TODO8
-rw-r--r--reconcile.py19
2 files changed, 22 insertions, 5 deletions
diff --git a/TODO b/TODO
index 914e61a..e79f6e0 100644
--- a/TODO
+++ b/TODO
@@ -29,10 +29,10 @@ Next:
- Look for urls in wherepublished.
- Forgive newlines in wherepublished, note.
D "Systems, Zero Knowledge"?
- - Make CSS and HTML pass the validator
+ o Make CSS and HTML pass the validators
o When sorting by author, make "Paul F. Syverson" the same person
as "Paul Syverson" unless somebody says different.
- - When sorting within a year
-What the heck is the algorithm for sorting within a year,
- when sorting by date? What should it be?
+ - When sorting by date, entries with unknown months go into a magic
+ "month zero" before January. Is this right?
+
diff --git a/reconcile.py b/reconcile.py
index 8228528..88e1209 100644
--- a/reconcile.py
+++ b/reconcile.py
@@ -171,7 +171,24 @@ class MasterBibTeX(BibTeX.BibTeX):
for g, m in matches:
print "%%%% goodness", g
print m
-
+
+
+def noteToURL(note):
+ " returns tp, url "
+ note = note.replace("\n", " ")
+ m = re.match(r'\s*(?:\\newline\s*)*\s*\\url{(.*)}\s*(?:\\newline\s*)*',
+ note)
+ if not m:
+ return None
+ url = m.group(1)
+ for suffix, tp in ((".html", "html"),
+ (".ps", "ps"),
+ (".ps.gz", "ps_gz"),
+ (".pdf", "pdf"),
+ (".txt", "txt")):
+ if url.endswith(suffix):
+ return tp,url
+ return "???", url
all_ok = 1
def emit(f,ent):