diff options
Diffstat (limited to 'md2latex')
-rwxr-xr-x | md2latex | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/md2latex b/md2latex new file mode 100755 index 0000000..4d2bdd2 --- /dev/null +++ b/md2latex @@ -0,0 +1,13 @@ +#!/bin/sh +TARGET="$1" + +sed '/^# /d' "$1.md" | pandoc -f markdown -o "$1.html" +cat ../preamble.tex > "$1.tex" + +echo '\begin{document}' >> "$1.tex" +printf '\\textbf{Databases} %s \\hfill Loek Le Blansch (2180996)\n' "`echo "$1" | sed 's/-/ /g'`" >> "$1.tex" +pandoc "$1.html" -t latex | sed 's/svg/pdf/g' >> "$1.tex" +echo '\end{document}' >> "$1.tex" + +latexmk -quiet "$1.tex" +latexmk -quiet -c "$1.tex" |