resume/build.sh

24 lines
795 B
Bash
Raw Normal View History

2023-10-23 20:34:42 +00:00
#!/bin/bash
2024-12-03 19:23:58 +00:00
BUILDFILES=("resume.tex","altacv.cls","README.md","build.sh","output.txt","resume.pdf","cover_letter.tex", "cover_letter.pdf")
echo "Building resume and cover letter."
echo "Deleting output.txt"
2023-10-23 20:34:42 +00:00
rm output.txt
echo "Building resume" | tee -a output.txt
echo -e "Generating resume PDF" | tee -a output.txt
2024-09-24 20:08:21 +00:00
pdflatex resume.tex -o resume.pdf > /dev/null
2024-12-03 19:23:58 +00:00
echo -e "Generating cover letter PDF" | tee -a output.txt
pdflatex cover_letter.tex -o cover_letter.pdf > /dev/null
2023-10-23 20:34:42 +00:00
echo -e "Deleting build files" | tee -a output.txt
FILES=$(ls -r)
for file in $FILES
do
if [[ " ${BUILDFILES[*]} " != *"$file"* ]];
then
rm $file
fi
done
2024-12-03 19:23:58 +00:00
echo -e "Creating resume PDF" | tee -a output.txt
2024-09-24 20:08:21 +00:00
convert -density 300 -colorspace sRGB resume.pdf -alpha off resume.png
2023-10-23 20:34:42 +00:00
echo -e "Done." | tee -a output.txt