about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rwxr-xr-xvienna12
1 files changed, 6 insertions, 6 deletions
diff --git a/vienna b/vienna index 253f5c8..907dddf 100755 --- a/vienna +++ b/vienna
@@ -56,7 +56,7 @@ configure() {
56 # Options 56 # Options
57 PHTML_OPTIONS="${VIENNA_PHTML_OPTIONS:-expand entities}" 57 PHTML_OPTIONS="${VIENNA_PHTML_OPTIONS:-expand entities}"
58 # File extensions 58 # File extensions
59 PAGE_RAW_EXT="${VIENNA_PAGE_RAW_EXT:-htm}" 59 RAW_PAGE_EXTENSION="${VIENNA_RAW_PAGE_EXTENSION:-htm}"
60 # Logging 60 # Logging
61 LOG=true 61 LOG=true
62 ## Parse command line arguments 62 ## Parse command line arguments
@@ -133,15 +133,15 @@ main() {
133 log vienna build 133 log vienna build
134 # Build pages 134 # Build pages
135 alias pagep=true 135 alias pagep=true
136 genpage *."$PAGE_RAW_EXT" || exit 2 136 genpage *."$RAW_PAGE_EXTENSION" || exit 2
137 alias pagep=false 137 alias pagep=false
138 # Build index 138 # Build index
139 alias indexp=true 139 alias indexp=true
140 genlist index_item "$INDEX_TEMPLATE" *."$PAGE_RAW_EXT" >"$OUTDIR/index.html" || exit 2 140 genlist index_item "$INDEX_TEMPLATE" *."$RAW_PAGE_EXTENSION" >"$OUTDIR/index.html" || exit 2
141 alias indexp=false 141 alias indexp=false
142 # Build feed 142 # Build feed
143 alias feedp=true 143 alias feedp=true
144 genlist feed_item "$FEED_TEMPLATE" *."$PAGE_RAW_EXT" >"$OUTDIR/feed.xml" || exit 2 144 genlist feed_item "$FEED_TEMPLATE" *."$RAW_PAGE_EXTENSION" >"$OUTDIR/feed.xml" || exit 2
145 alias feedp=false 145 alias feedp=false
146 # Copy static files 146 # Copy static files
147 static * || exit 2 147 static * || exit 2
@@ -425,7 +425,7 @@ genpage() { # genpage PAGE...
425 for FILE; do 425 for FILE; do
426 test -f "$FILE" || continue 426 test -f "$FILE" || continue
427 log genpage "$FILE" 427 log genpage "$FILE"
428 outd="$OUTDIR/${FILE%.$PAGE_RAW_EXT}" 428 outd="$OUTDIR/${FILE%.$RAW_PAGE_EXTENSION}"
429 outf="$outd/index.html" 429 outf="$outd/index.html"
430 tmpf="$TEMPDIR/$FILE.tmp" 430 tmpf="$TEMPDIR/$FILE.tmp"
431 META="$TEMPDIR/$FILE.meta" 431 META="$TEMPDIR/$FILE.meta"
@@ -447,7 +447,7 @@ genlist() { # genlist PERITEM_FUNC TEMPLATE_FILE PAGE...
447 while read -r FILE; do 447 while read -r FILE; do
448 test -f "$FILE" || continue 448 test -f "$FILE" || continue
449 log genlist "$peritem_func:" "$FILE" 449 log genlist "$peritem_func:" "$FILE"
450 LINK="$URL_ROOT${URL_ROOT:+/}${FILE%.$PAGE_RAW_EXT}" 450 LINK="$URL_ROOT${URL_ROOT:+/}${FILE%.$RAW_PAGE_EXTENSION}"
451 META="$TEMPDIR/$FILE.meta" 451 META="$TEMPDIR/$FILE.meta"
452 "$peritem_func" "$FILE" 452 "$peritem_func" "$FILE"
453 done | expand "$template_file" 453 done | expand "$template_file"