Static site that displays Pedro Primor’s résumé as an embedded PDF, with an EN / PT language switcher.
Live site: https://cv.primor.me/
| File | Purpose |
|---|---|
cv_en.tex |
LaTeX source (English) |
cv_pt.tex |
LaTeX source (European Portuguese) |
CV.pdf |
Built English résumé (default on the site) |
CV_pt.pdf |
Built Portuguese résumé |
index.html |
Landing page; EN/PT toggle embeds CV.pdf or CV_pt.pdf |
cover_letter.pdf |
Optional asset (not linked from the homepage) |
scripts/build-site.sh |
Packages static assets into dist/ for Cloudflare Pages |
Makefile |
Build PDFs (make cv) and site bundle (make site) |
Install a minimal TeX distribution and the packages used by the CV sources:
brew install --cask basictex
eval "$(/usr/libexec/path_helper)" # or open a new terminal
# sudo does not inherit /Library/TeX/texbin — use the full path or env PATH=...
sudo /Library/TeX/texbin/tlmgr update --self
sudo /Library/TeX/texbin/tlmgr install latexmk \
preprint tools hyperref pdftex babel-english babel-portuges xcolor \
enumitem titlesec fancyhdr marvosym ragged2e footmisc \
fontawesome collection-fontsrecommendedtabularx lives in the tools package (there is no separate tlmgr install tabularx). fullpage.sty comes from preprint. If the first build still fails, install the name from the log, e.g. sudo /Library/TeX/texbin/tlmgr install preprint.
make cv # both PDFs
make cv-en # cv_en.tex → CV.pdf only
make cv-pt # cv_pt.tex → CV_pt.pdf only
make site # dist/ for Cloudflare Pages (run after make cv if .tex changed)
open CV.pdf # macOS
open CV_pt.pdfmake and make cv are equivalent. make clean removes LaTeX intermediates and both PDFs; run make cv again to regenerate.
| Path | What you do | What CI does |
|---|---|---|
| Pull request | Edit cv_en.tex and/or cv_pt.tex, run make cv, commit matching PDF(s) |
Fails if CV.pdf or CV_pt.pdf ≠ build output, or either PDF is not exactly 1 page |
Push to main |
May commit .tex only |
Rebuilds and commits CV.pdf and CV_pt.pdf if needed |
- Edit
cv_en.texand/orcv_pt.tex(keep structure in sync when both languages should match). Prose followsdocs/writing-style.md; read it before rewording a bullet. - Run
make cvand spot-check both PDFs (header icons, links, one page each). - Commit and push (see table above).
- After Cloudflare Pages redeploys (usually 1–2 minutes), verify https://cv.primor.me/ and toggle EN/PT. Use a hard refresh if a PDF looks cached.
Prefer a branch and pull request for non-trivial edits:
git checkout -b update-cv
# edit cv_en.tex and/or cv_pt.tex, then make cv
git add cv_en.tex cv_pt.tex CV.pdf CV_pt.pdf
git commit -m "Update CV"
git push -u origin update-cv
gh pr create --webPDF only
open CV.pdf # macOS
open CV_pt.pdfHomepage (iframe + language toggle, matches production layout)
make site
python3 -m http.server 8080 --directory dist
# http://localhost:8080/Run make cv before make site if you changed either .tex file so the embedded PDFs match the sources.
Hosting is Cloudflare Pages on cv.primor.me. Apex primor.me is not served by this project.
-
In Cloudflare: Workers & Pages → Create → Pages → Connect to Git →
pprimor/cv. -
Build settings (production branch
main):Setting Value Framework preset None Build command bash scripts/build-site.shBuild output directory dist -
Deploy once and confirm the
*.pages.devpreview servesindex.htmland both PDFs. -
Custom domains → add
cv.primor.me(CNAMEcv→ your Pages hostname). Do not attach apexprimor.meorwwwto this project. -
Disable GitHub Pages for this repo after cutover.
Pushes to main trigger a Pages deploy. The Build CV workflow keeps CV.pdf and CV_pt.pdf in sync with the LaTeX sources; Pages serves the packaged static files. No database or application server in this repo.
CV.pdf remains the canonical English URL for bookmarks and external links (https://cv.primor.me/CV.pdf). Portuguese is available at CV_pt.pdf and via the site toggle.
If you add branch protection on main, allow github-actions[bot] to push (or exempt its [skip actions] commits) so auto-rebuilt PDFs can land after tex-only merges.
- PR failed on PDF drift — CI rebuilt one or both PDFs and they did not match your branch. Run
make cvlocally, commit the updatedCV.pdfand/orCV_pt.pdf, and push. - PR failed on page count — Each PDF must be exactly one page. Trim content or spacing in the relevant
.texfile, runmake cv, and verify withpdfinfo CV.pdf CV_pt.pdf | awk '/^Pages:/'. - PDF does not update on the site — Wait for the Pages deploy, then hard-refresh or try a private window. Cloudflare Pages skips any commit whose message contains
[skip ci], so never put that token in a commit body; the workflow uses[skip actions]for its PDF commits. - Iframe blank in some browsers — Open CV.pdf or CV_pt.pdf directly; the embed uses same-origin relative paths, not Google Docs viewer.
- Wrong repo in links — Remote uses
pprimor/cv; keep GitHub URLs in docs aligned with that. tlmgr: command not foundunder sudo — Usesudo /Library/TeX/texbin/tlmgr …(sudo resetsPATH).latexmkorpdflatexnot found — Runeval "$(/usr/libexec/path_helper)"or open a new terminal; installlatexmkwithtlmgras above.