Bauke/cv
Bauke
/
cv
1
Fork 0
cv/compile-cv.zsh

21 lines
588 B
Bash
Executable File

#!/usr/bin/env zsh
# There's currently no way in Typst to provide values from the CLI in some way
# so until the next version lands and https://github.com/typst/typst/pull/2894
# becomes available, a script that renders a template has to be it for now.
# Define options based on environment variables or use default values.
include_links=${CV_INCLUDE_LINKS:-"true"}
language=${CV_LANG:-"en"}
typst_template="#import \"main.typ\": cv
#cv(
include_links: $include_links,
language: \"$language\",
)"
echo $typst_template > cv.typ
typst compile cv.typ "build/CV-Bauke-$CV_LANG.pdf"