diff options
author | Jonas Smedegaard <dr@jones.dk> | 2012-08-31 15:12:31 +0200 |
---|---|---|
committer | Jonas Smedegaard <dr@jones.dk> | 2012-08-31 15:12:31 +0200 |
commit | 4d3abe74035d7d3c2c5d6927cc0cbb9032486b30 (patch) | |
tree | 4aed209e55abf9c02095d102bf8a4c3394f56589 /report/mkmd.sh | |
parent | 140be416cbc17bed349697c205af07d2f3070089 (diff) |
Add tidying scripts.
Diffstat (limited to 'report/mkmd.sh')
-rwxr-xr-x | report/mkmd.sh | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/report/mkmd.sh b/report/mkmd.sh new file mode 100755 index 0000000..39ec83d --- /dev/null +++ b/report/mkmd.sh @@ -0,0 +1,18 @@ +#!/bin/sh + +set -e + +#stem="Greens-IslandsofResiliences" +stem="Greens-IslandsofResilience" + +pdftohtml -q -c -s -i -noframes -stdout "$stem.pdf" tmp + +infile=tmp.html + +outfile="${2:-$(basename "$infile" .html).md}" + +#perl ./normalize-html.pl tmp.html | less +perl ./normalize-html.pl tmp.html \ + |pandoc --normalize --no-wrap --parse-raw -f html -t markdown -o "$stem.md" + +pandoc --standalone --toc -f markdown -t html5 -i "$stem.md" -o "$stem.html" |