aboutsummaryrefslogtreecommitdiff
path: root/www/publish.sh
diff options
context:
space:
mode:
authorAndrew Robbins <contact@andrewrobbins.info>2017-06-23 11:54:02 -0400
committerAndrew Robbins <contact@andrewrobbins.info>2017-06-23 13:18:45 -0400
commit19d30a9fb1a4bddb2a23333398a4dba0e581f31b (patch)
tree1375cbc21d14ad220bd98228a7925166461dfa4a /www/publish.sh
parent363455950f9c351b0a87a31fb5641a635bd352a7 (diff)
downloadlibrebootfr-19d30a9fb1a4bddb2a23333398a4dba0e581f31b.tar.gz
librebootfr-19d30a9fb1a4bddb2a23333398a4dba0e581f31b.zip
Swapped out 'echo' calls w/ 'printf ...'
Continuation of pull request #217 re: printf usage.
Diffstat (limited to 'www/publish.sh')
-rwxr-xr-xwww/publish.sh8
1 files changed, 4 insertions, 4 deletions
diff --git a/www/publish.sh b/www/publish.sh
index e1ebe016..0be47a78 100755
--- a/www/publish.sh
+++ b/www/publish.sh
@@ -19,7 +19,7 @@
[ "x${DEBUG+set}" = 'xset' ] && set -v
set -e
-echo $1
+printf '%s\n' $1
FILE=${1%.md}
cat $1 > temp.md
@@ -46,7 +46,7 @@ else
fi
if [[ $FILE = *suppliers ]]; then
- env printf '\n%s\n' "<strong><a href=\"/git.html#editing-the-website-and-documentation-wiki-style\">Edit this page</a></strong> -- <a href=\"../\">Back to previous page</a>" >> temp.md
+ printf '\n%s\n' "<strong><a href=\"/git.html#editing-the-website-and-documentation-wiki-style\">Edit this page</a></strong> -- <a href=\"../\">Back to previous page</a>" >> temp.md
fi
if [ "${FILE}" != "./docs/fdl-1.3" ] && [ "${FILE}" != "./conduct" ]; then
@@ -62,10 +62,10 @@ sed temp.md -i -e 's/\.md\(#[a-z\-]*\)*)/.html\1)/g'
sed temp.md -i -e 's/\.md\(#[a-z\-]*\)*]/.html\1]/g'
# work around issue #2872
-TOC=$(grep -q "^x-toc-enable: true$" temp.md && echo "--toc --toc-depth=2") || TOC=""
+TOC=$(grep -q "^x-toc-enable: true$" temp.md && printf '%s\n' "--toc --toc-depth=2") || TOC=""
# work around heterogenous pandoc versions
-SMART=$(pandoc -v | grep -q '2\.0' || echo "--smart") || SMART=""
+SMART=$(pandoc -v | grep -q '2\.0' || printf '%s\n' "--smart") || SMART=""
# chuck through pandoc
pandoc $TOC $SMART temp.md -s --css /global.css $OPTS \