diff options
author | Michael Reed <michael@michaelreed.io> | 2017-07-13 01:36:27 -0400 |
---|---|---|
committer | Michael Reed <michael@michaelreed.io> | 2017-07-13 01:36:53 -0400 |
commit | a8d89665de6da20a8793886e03f153e922f6e519 (patch) | |
tree | 40df28854a3fb4f523abc1cf0c6853287bdfa883 /www | |
parent | 8c7d21cbf45a4279dcffae95ce626a0dc9006a30 (diff) | |
download | librebootfr-a8d89665de6da20a8793886e03f153e922f6e519.tar.gz librebootfr-a8d89665de6da20a8793886e03f153e922f6e519.zip |
www/publish.sh: Clean up shellcheck warnings
All of the warnings were of type SC2086 [1]: Double quote to prevent
globbing and word splitting.
[1]: https://github.com/koalaman/shellcheck/wiki/Sc2086
Diffstat (limited to 'www')
-rwxr-xr-x | www/publish.sh | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/www/publish.sh b/www/publish.sh index 9c3a4fcd..8e25d920 100755 --- a/www/publish.sh +++ b/www/publish.sh @@ -70,14 +70,14 @@ TOC=$(grep -q "^x-toc-enable: true$" "$TMPFILE" && printf '%s\n' "--toc --toc-de SMART=$(pandoc -v | grep -q '2\.0' || printf '%s\n' "--smart") || SMART="" # chuck through pandoc -pandoc $TOC $SMART "$TMPFILE" -s --css /global.css $OPTS \ - --template template.html --metadata return="$RETURN"> $FILE.html +pandoc $TOC $SMART "$TMPFILE" -s --css /global.css "$OPTS" \ + --template template.html --metadata return="$RETURN" > "$FILE.html" # additionally, produce bare file for RSS -pandoc $1 > $FILE.bare.html +pandoc "$1" > "$FILE.bare.html" # generate section title anchors as [link] -sed -i -e 's_^<h\([123]\) id="\(.*\)">\(.*\)</h\1>_<div class="h"><h\1 id="\2">\3</h\1><a aria-hidden="true" href="#\2">[link]</a></div>_' $FILE.html +sed -i -e 's_^<h\([123]\) id="\(.*\)">\(.*\)</h\1>_<div class="h"><h\1 id="\2">\3</h\1><a aria-hidden="true" href="#\2">[link]</a></div>_' "$FILE.html" # clean up temporary file rm -f "$TMPFILE" |