-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvitae.typ
147 lines (125 loc) · 2.65 KB
/
vitae.typ
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
#let hsep() = {
line(length: 100%, stroke: rgb(0, 0, 0, 75))
}
#let vsep() = {
set text(fill: rgb(0, 0, 0, 200), size: 12pt, weight: "bold")
[ | ]
}
#let iconify_link(l) = {
grid(
columns: 2,
gutter: 5pt,
image("assets/icons/" + l.icon + ".svg", width: 12pt),
[ #v(2pt); #link(l.url, l.display); ],
)
}
#let render_links(links) = {
show link: underline
grid(
columns: links.len(),
gutter: 7pt,
..links.map(iconify_link),
)
}
#let section_heading(name) = {
grid(
columns: 2,
gutter: 1fr,
[ = #name #h(5pt) ],
[ #v(5pt) #line(length: 100%, stroke: 1.5pt) ]
)
}
#let render_header(name, links) = {
set align(center)
[
#set text(font: "Libre Baskerville", size: 13pt)
= #name
]
render_links(links)
}
#let render_summary(summary) = {
section_heading("Summary")
[
#set text(size: 10pt)
#par(summary)
]
}
#let render_experience(ex) = {
section_heading("Experience")
for job in ex {
[ == #job.company ]
for pos in job.positions {
grid(
columns: 2,
gutter: 1fr,
[
#strong(emph(pos.role)) #vsep() #emph(pos.team)
],
[
#set align(right)
#pos.location
#vsep()
#strong(pos.start) -- #strong(pos.end)
]
)
for point in pos.info {
[ - #eval(point, mode: "markup") ]
}
}
}
}
#let render_education(education) = {
section_heading("Education")
for school in education {
grid(
columns: 2,
gutter: 1fr,
[
== #school.name
#eval(school.degree, mode: "markup") #vsep() #eval(school.grade, mode: "markup")
],
[
#set align(right)
=== #school.start -- #school.end
#school.location
]
)
// for point in school.info {
// [ - #eval(point, mode: "markup") ]
// }
}
}
#let render_skills(skills) = {
section_heading("Skills")
for (section, values) in skills.pairs() {
strong(section + ": ")
values.join(" " + sym.circle.filled.tiny + " ")
linebreak()
}
}
#let render_cv(data) = {
render_header(data.name, data.links)
render_summary(data.summary)
render_experience(data.experience)
render_education(data.education)
render_skills(data.skills)
}
#let data = yaml("data.yaml")
#set document(
title: data.name + " -- CV",
author: data.name
)
#set page(
paper: "a4",
margin: (
x: 1cm,
y: 0.8cm
),
// footer: [
// #set align(right)
// #set text(size: 9pt, fill: rgb(0, 0, 0, 150))
// Updated on -- #datetime.today().display("[day] [month repr:long], [year]")
// ],
)
#set text(font: "Calibri", size: 10pt)
#render_cv(data)