-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
77 lines (68 loc) · 3.21 KB
/
Makefile
File metadata and controls
77 lines (68 loc) · 3.21 KB
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
# CV Templates
# Copyright (C) 2025 Mariusz Matusiak <mariusz.m.matusiak@gmail.com>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published
# by the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# 1. Assign latexbin to your LaTeX executable path
latexbin=latexmk
latexopts=-pdf -outdir=output_ -silent -cd
academic_src_files=$(wildcard academic/*.tex)
industry_src_files=$(wildcard industry/*.tex)
coverletter_src_files=$(wildcard cover_letter/*.tex)
data_src_files=$(wildcard data/*.tex)
timestamp=`date +%Y%m%d`
# 2. Provide your signature as a lower case dash-separated string, like firstname_lastname.
signature=winnie_the_pooh
# 3. Provide a path to a directory where you want to have your documents copied.
cv_storage=CVs
# 4. Provide the company name as a lower case dash-separated string (optional), like: gmake all company=company_name_inc.
ifdef company
company_dashed="_${company}"
endif
# 5. Provide the location as a lower case dash-separated string (optional), like: gmake all location=los_angeles_ca.
ifdef location
location_dashed="_${location}"
endif
# 6. Provide the job name as a lower case dash-separated string (optional), like: gmake all job=senior_sw_engineer.
ifdef job
job_dashed="_${job}"
endif
# .ONESHELL requires at least make v3.8 (installed by brew as gmake)
.ONESHELL:
all : academic industry letter
.PHONY : all academic industry letter clean
academic : ${academic_src_files} ${data_src_files}
${latexbin} ${latexopts} academic/academic_cv.tex
cp academic/output_/academic_cv.pdf ${signature}_academic_cv_${timestamp}.pdf
mkdir -p ${cv_storage}/"${company}"
cp academic/output_/academic_cv.pdf ${cv_storage}/"${company}"/${signature}_academic_cv${company_dashed}${location_dashed}${job_dashed}_${timestamp}.pdf
industry : ${industry_src_files} ${data_src_files}
${latexbin} ${latexopts} industry/resume.tex
cp industry/output_/resume.pdf ${signature}_resume_${timestamp}.pdf
mkdir -p ${cv_storage}/"${company}"
cp industry/output_/resume.pdf ${cv_storage}/"${company}"/${signature}_resume${company_dashed}${location_dashed}${job_dashed}_${timestamp}.pdf
letter : ${coverletter_src_files} ${data_src_files}
${latexbin} ${latexopts} cover_letter/letter.tex
cp cover_letter/output_/letter.pdf ${signature}_cover_letter_${timestamp}.pdf
mkdir -p ${cv_storage}/"${company}"
cp cover_letter/output_/letter.pdf ${cv_storage}/"${company}"/${signature}_cover_letter${company_dashed}${location_dashed}${job_dashed}_${timestamp}.pdf
list_files : ${academic_src_files} ${industry_src_files} ${coverletter_src_files} ${data_src_files}
ls -l $?
clean :
rm -r academic/output_
rm academic/*.pdf
rm -r industry/output_
rm industry/*.pdf
rm -r cover_letter/output_
rm cover_letter/*.pdf
rm *.pdf