]> git.phdru.name Git - phdru.name/phdru.name.git/commitdiff
Fixed bugs.
authorOleg Broytman <phd@phdru.name>
Sat, 25 Feb 2006 13:27:27 +0000 (13:27 +0000)
committerOleg Broytman <phd@phdru.name>
Sat, 25 Feb 2006 13:27:27 +0000 (13:27 +0000)
git-svn-id: file:///home/phd/archive/SVN/phdru.name/scripts@4 7bb0bf08-9e0d-0410-b083-99cee3bf18b8

reindex_blog.py

index 43c4f8b4342389643585f4958d655b8f718e4798..716605bf2a7a529e55ab5a35050ffbfb038595fc 100755 (executable)
@@ -42,7 +42,7 @@ if not months:
 days = []
 for month in months:
    year, m = month.split(os.sep)
-   if month not in years:
+   if year not in years:
       years[year] = {}
    years[year][m] = days_of_month = []
    for day in os.listdir(month):
@@ -200,7 +200,7 @@ $phd_pp_ru.respond(self)
    if old_text <> new_text:
       print "Writing", index_name
       index_tmpl = open(index_name, 'w')
-      index_tmpl.write(new_test)
+      index_tmpl.write(new_text)
       index_tmpl.close()