]> git.phdru.name Git - phdru.name/phdru.name.git/blob - make-files
Fix(phd.py): Change URL for Lurk
[phdru.name/phdru.name.git] / make-files
1 #! /bin/sh
2
3 umask 022
4 PYTHONPATH=.
5 PYTHONIOENCODING=koi8-r:replace
6 export PYTHONPATH PYTHONIOENCODING
7
8 if [ \! -e phd_site.py -o phd_site.tmpl -nt phd_site.py ]; then
9    cheetah compile --encoding=koi8-r --settings='encoding="koi8-r"' --nobackup phd_site.tmpl &&
10    compyle phd_site.py
11 fi &&
12
13 for tmpl in "$@"; do
14    dir="`dirname \"$tmpl\"`"
15    outfile="`basename \"$tmpl\" .tmpl`.html"
16    echo "$tmpl => $dir/$outfile"
17    cheetah fill --encoding=koi8-r --settings='encoding="koi8-r"' \
18       --nobackup --stdout "$tmpl" | iconv -f utf-8 -t koi8-r >"$dir/$outfile" || exit 1
19 done
20
21 exec sitemap_gen.py --config=sitemaps/phdru.name-config.xml