diff --git a/.claude/commands/apply.md b/.claude/commands/apply.md index 0c7387e6..ec489921 100644 --- a/.claude/commands/apply.md +++ b/.claude/commands/apply.md @@ -337,7 +337,14 @@ Failures here are template-level problems: fix them in the `` source (e. ### 5e. Clean up build artifacts -After the final clean compile, delete intermediate build files the compile command left behind — LaTeX toolchains leave `.aux`/`.log`/`.out`; a custom template's toolchain may leave nothing beyond the PDF. Keep the source file and the `.pdf`. +After the final clean compile (and after 5b-5d have passed), delete the intermediate files the compile command left behind. Keep the source (``/``), the `.pdf`, and every template asset (`cover.cls`, `OpenFonts/`, a custom template's files). + +- **Stock or custom LaTeX toolchain:** + ```bash + rm -f cv/main__.{aux,log,out,fls,fdb_latexmk,synctex.gz} cover_letters/cover__.{aux,log,out,fls,fdb_latexmk,synctex.gz} + ``` +- **Custom template whose compile command redirects to `build/`:** also `rm -rf cv/build cover_letters/build` (`/add-template` Step 4 already says `/apply` must delete it). +- **Zero-artifact toolchain (e.g. `typst compile`):** nothing to delete. --- diff --git a/CHANGELOG.md b/CHANGELOG.md index e433efbb..47a1d30b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,15 @@ per-file diff commands. `trustedDependencies`, the same set `security_guards.py` forbids in-tree, so a borrowed portal carrying one is read before it runs. `--dry-run` lists what it would install. +### Changed + +- **`/apply` Step 5e names explicit cleanup shell commands for build intermediates** + (#531, `.claude/commands/apply.md`) - the step previously described deleting `.aux`/`.log`/`.out` + in prose, leaving artifact cleanup vulnerable to being skipped by agents. It now specifies explicit + `rm` commands for stock/custom LaTeX toolchains and redirected `build/` directories, timed after + log-inspecting steps 5b-5d complete, and explicitly preserves template assets (`cover.cls`, + `OpenFonts/`, custom template files). + ### Fixed - **Fork-skip guards no longer run on a fork during a local test run** (`tests/_upstream.py`,