AGENTS.md
AGENTS.md
Rules every agent working in this repository MUST follow. These are hard requirements, not suggestions.
This is Junhao Hu’s academic personal website (Academic Pages / Jekyll). The same information (publications, projects, experience, awards, services) lives in two places that must never drift apart: the website content and the LaTeX CV.
1. Keep the CV and the website in sync
Any change to content (e.g. adding/moving/renaming a publication, updating experience, awards, services) MUST be applied to both:
- Website: the relevant file under
_pages/(e.g. publications go in_pages/publications.md). - CV source: the matching LaTeX file under
_cv_src/(e.g. publications go in_cv_src/sections/publication.tex).
Never update one and leave the other stale.
2. Always recompile the CV and place the PDF
After editing any _cv_src/** file, you MUST recompile and publish the PDF:
cd _cv_src
pdflatex -interaction=nonstopmode -halt-on-error main.tex # run twice for refs
/bin/cp -f main.pdf ../files/cv.pdf
- Run
pdflatextwice so cross-references/pages resolve. - The published PDF served by the site is
files/cv.pdf— the build output_cv_src/main.pdfmust be copied there. - Use
/bin/cp -f(or\cp -f); plaincpis aliased to interactive mode and will silently fail to overwrite. - Verify the change landed, e.g.
pdftotext files/cv.pdf - | grep <keyword>.
3. Never commit or push without explicit confirmation
Do NOT run git commit or git push until Junhao (the repo owner) has personally reviewed the changes and confirmed. Make the edits, report what was done, and wait for his go-ahead. This applies even when the work looks complete.
4. Before every commit/push, guarantee files/cv.pdf is up to date
Whenever you commit and push, the committed files/cv.pdf MUST be the freshly recompiled version reflecting the current _cv_src/** source — never a stale build. Make it a habit: every time you touch the CV, recompile it and move the result into files/ (see rule 2), so the PDF is never left behind.
Before committing, verify the published PDF matches the source build, e.g.:
cd _cv_src && pdflatex -interaction=nonstopmode -halt-on-error main.tex # twice
/bin/cp -f main.pdf ../files/cv.pdf
md5sum _cv_src/main.pdf ../files/cv.pdf # the two hashes must be identical
If the hashes differ (or you skipped the recompile), do not commit until the latest PDF is in place.
