home · contact · privacy
Simplify HTML file link path determination.
authorChristian Heller <c.heller@plomlompom.de>
Thu, 22 Dec 2016 19:13:03 +0000 (20:13 +0100)
committerChristian Heller <c.heller@plomlompom.de>
Thu, 22 Dec 2016 19:13:03 +0000 (20:13 +0100)
processor/metadata/default.feed_snippet.do
processor/metadata/default.index_snippet.do

index b09eaa056e62537b10df8f8cd987554943b1e151..3321ac4071f684123499a6fcc3174fec2a87439f 100644 (file)
@@ -9,8 +9,7 @@ intermediate_file="${1%.feed_snippet}.intermediate"
 redo-ifchange "$intermediate_file"
 
 # Get variables, write entry.
-html_file=`escape_url "${src_file%.*}.html"`
-html_file=${html_file#*/}
+html_file=$(escape_url "${1%.feed_snippet}.html")
 lastmod=`stat -c%y "$src_file"`
 lastmod_rfc3339=`date -u "+%Y-%m-%dT%TZ" -d "$lastmod"`
 published=`stat -c%y "$uuid_file"`
index d95b27b176de639c32025094c107269c74473367..e332350f23fe81f6b1b27dd5ac1208e5d4930053 100644 (file)
@@ -9,6 +9,6 @@ html_file="${src_file%.*}.html"
 redo-ifchange "$html_file"
 
 # Get variables, write entry.
-title_html=`cat "$intermediate_file" | head -1`
-html_file_escaped=`escape_url "${html_file#*/}"`
+title_html=$(cat "$intermediate_file" | head -1)
+html_file_escaped=$(escape_url "${1%.index_snippet}.html")
 printf "<li><a href=\"%s\" />%s</a></li>\n" "$html_file_escaped" "$title_html"