import pickle
try:
- blog_file = open(blog_filename, "rb")
+ blog_file = open('../../../../phdru.name/ru/' + blog_filename, "rb")
except IOError:
blog_dict = {}
else:
return value1 or value2
elif op == 'NOT':
return not _test_post(post, tree[1])
+ elif op == 'PARENS':
+ return _test_post(post, tree[1])
else:
raise ValueError("Cannot get there")
for post in posts:
if _test_post(post, tree):
_posts.append((
- '/'.join((year, month, day, post[0].replace('.tmpl', '.html'))),
+ year, month, day,
+ '/'.join((year, month, day, post[0][:-len("tmpl")] + "html")),
post[1]))
- _posts.sort()
+ _posts.sort(reverse=True)
return _posts