Compare commits
No commits in common. "007e711c2c35fdb8aa0e9007b8d42680522567cb" and "e50b6e70b766d791ec36270cdf5cea0747ad8987" have entirely different histories.
007e711c2c
...
e50b6e70b7
|
@ -2,4 +2,3 @@
|
||||||
.vscode/
|
.vscode/
|
||||||
build/
|
build/
|
||||||
data/
|
data/
|
||||||
cv.typ
|
|
||||||
|
|
|
@ -23,7 +23,12 @@ args = ["trash", "build"]
|
||||||
[tasks.compile]
|
[tasks.compile]
|
||||||
clear = true
|
clear = true
|
||||||
dependencies = ["ensure-build-dir"]
|
dependencies = ["ensure-build-dir"]
|
||||||
script = "./compile-cv.zsh"
|
command = "typst"
|
||||||
|
args = [
|
||||||
|
"compile",
|
||||||
|
"cv-${CV_LANG}.typ",
|
||||||
|
"build/CV-Bauke-${CV_LANG}.pdf"
|
||||||
|
]
|
||||||
|
|
||||||
# Ensure that the build directory exists.
|
# Ensure that the build directory exists.
|
||||||
[tasks.ensure-build-dir]
|
[tasks.ensure-build-dir]
|
||||||
|
@ -36,4 +41,4 @@ args = ["-p", "build"]
|
||||||
[tasks.watch]
|
[tasks.watch]
|
||||||
clear = true
|
clear = true
|
||||||
command = "watchexec"
|
command = "watchexec"
|
||||||
args = ["-e", "toml,typ", "-i", "cv.typ", "--no-vcs-ignore", "makers build"]
|
args = ["-e", "toml,typ", "--no-vcs-ignore", "makers build"]
|
||||||
|
|
|
@ -1,20 +0,0 @@
|
||||||
#!/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"
|
|
|
@ -1,7 +0,0 @@
|
||||||
#import "../utilities/localize.typ": localize
|
|
||||||
|
|
||||||
#let experience_section(data, language) = [
|
|
||||||
== #localize(data, "experience", language)
|
|
||||||
|
|
||||||
#eval(localize(data, "experience_body", language))
|
|
||||||
]
|
|
|
@ -1,48 +0,0 @@
|
||||||
#import "../utilities/icon-with-text.typ": icon_with_text
|
|
||||||
#import "../utilities/localize.typ": localize
|
|
||||||
|
|
||||||
#let personal_project(data, language) = {
|
|
||||||
let icon_size = 1.4em
|
|
||||||
|
|
||||||
let personal_project_name = localize(data, "name", language)
|
|
||||||
|
|
||||||
let personal_project_heading = heading(level: 3, link(data.link, personal_project_name));
|
|
||||||
|
|
||||||
let personal_project_header = if "header_image" in data {
|
|
||||||
icon_with_text(
|
|
||||||
clip_icon: true,
|
|
||||||
icon: "../" + data.header_image,
|
|
||||||
icon_alt_text: personal_project_name,
|
|
||||||
icon_size: icon_size,
|
|
||||||
personal_project_heading,
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
personal_project_heading
|
|
||||||
}
|
|
||||||
|
|
||||||
// Use a grid to space out the header and the body.
|
|
||||||
grid(
|
|
||||||
gutter: 0.5em,
|
|
||||||
// Set the height explicitly so the ones with icons don't look different
|
|
||||||
// from the ones without.
|
|
||||||
box(
|
|
||||||
height: icon_size,
|
|
||||||
// Use another grid to position the title and date.
|
|
||||||
grid(
|
|
||||||
columns: (1fr, auto),
|
|
||||||
personal_project_header,
|
|
||||||
align(horizon, text(size: 0.9em, localize(data, "date", language))),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
// The body can contain Typst code so we use `eval()` to render it.
|
|
||||||
eval(localize(data, "body", language)),
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
#let personal_projects_section(data, language) = [
|
|
||||||
== #localize(data.locale, "personal_projects", language)
|
|
||||||
|
|
||||||
#for data in data.personal_projects {
|
|
||||||
personal_project(data, language)
|
|
||||||
}
|
|
||||||
]
|
|
Loading…
Reference in New Issue