diff options
Diffstat (limited to 'gup')
| -rwxr-xr-x | gup/pdf.gup | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/gup/pdf.gup b/gup/pdf.gup index 7604813..3b3aa3a 100755 --- a/gup/pdf.gup +++ b/gup/pdf.gup | |||
| @@ -1,8 +1,9 @@ | |||
| 1 | #!/usr/bin/env zsh | 1 | #!/usr/bin/env zsh |
| 2 | 2 | ||
| 3 | gup -u ${2%.pdf}.md | 3 | base=(${2%.pdf}.(md|lhs)([1])) |
| 4 | 4 | ||
| 5 | for i in 0 1; do | 5 | gup -u ${base} preamble.tex |
| 6 | pandoc -t latex -o $2 -V "geometry=margin=2cm" -V "fontfamily=libertine" -H preamble.tex --listings --latex-engine=lualatex ${2%.pdf}.md >&2 | 6 | |
| 7 | for i ({0..1}); do | ||
| 8 | pandoc -t latex -o $1 -V "geometry=margin=2cm" -V "fontfamily=libertine" -H preamble.tex --listings --latex-engine=lualatex ${base} >&2 | ||
| 7 | done | 9 | done |
| 8 | [[ -e $2 ]] && touch $2 | ||
