Add build script for cover letters
parent
80754fd617
commit
f67f0ed36b
|
@ -0,0 +1,11 @@
|
||||||
|
#!/bin/sh
|
||||||
|
hash="$(git rev-parse HEAD)"
|
||||||
|
body="<text>$(pandoc --from=markdown $1)</text>"
|
||||||
|
company="$2" || ""
|
||||||
|
date="$(date +'%d %B %Y')"
|
||||||
|
signature="$(base64 ./assets/signature.svg)"
|
||||||
|
|
||||||
|
mkdir -p ../dist
|
||||||
|
|
||||||
|
echo $body | xsltproc --stringparam company "$company" --stringparam date "$date" --stringparam signature "$signature" ./templates/letter.xsl - > ./dist/letter.html
|
||||||
|
weasyprint --quiet ./dist/letter.html ./dist/letter.pdf
|
Loading…
Reference in New Issue