X-Git-Url: https://git.llucax.com/software/blitiri.git/blobdiff_plain/5e45cd0354881aee35f582b4c233eb8341ebc7a3..7d653403b505dc4de30d1e7026922e9e144c77d6:/blitiri.cgi diff --git a/blitiri.cgi b/blitiri.cgi index 1dadce5..79e4171 100755 --- a/blitiri.cgi +++ b/blitiri.cgi @@ -14,6 +14,12 @@ # Directory where entries are stored data_path = "/tmp/blog/data" +# Are comments allowed? (if False, comments_path option is not used) +enable_comments = False + +# Directory where comments are stored (must be writeable by the web server) +comments_path = "/tmp/blog/comments" + # Path where templates are stored. Use an empty string for the built-in # default templates. If they're not found, the built-in ones will be used. templates_path = "/tmp/blog/templates" @@ -42,6 +48,8 @@ encoding = "utf8" import sys import os +import errno +import shutil import time import datetime import calendar @@ -60,17 +68,22 @@ except: pass +# Pimp *_path config variables to support relative paths +data_path = os.path.realpath(data_path) +templates_path = os.path.realpath(templates_path) + # Default template -default_main_header = """ - +default_main_header = """\ + + - + - + %(title)s @@ -82,8 +95,7 @@ default_main_header = """ """ default_main_footer = """ -

-



+