fix(ci): pin Tailwind scan scope so prose can't break the CSS drift check #4
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/pin-tailwind-scan-scope"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What broke
After merging #3, CI failed on the new
Verify compiled CSS is up to datestep: a freshtailwindcssbuild emitted an.invisibleutility that the committedpassage.cssdidn't contain. The drift check did its job — the committed CSS genuinely didn't match a fresh build.Root cause
Tailwind v4's automatic source detection scans every non-ignored file in the repo — including markdown. My docs edit in
ef1c991added the word "invisible" to AGENTS.md ("this is invisible at compile time"); candidate extraction turned that prose word into a utility, and every future docs edit would risk the same. Editing docs without thinking to rebuild CSS is exactly the trap this step can't tolerate.Fix
input.css:@import "tailwindcss" source(none);+ explicit@sourcelines — onlyinternal/web/templates/and the two JS files are scanned. Prose can no longer generate CSS, in any file, ever.passage.css: drops 11 prose-generated utilities (absolute,fixed,relative,transition, …). Verified none are used in any template (scripted intersection of template class attributes vs the dropped set).Verification
./tools/build-css.sh && git diff --exit-code internal/web/static/passage.csspasses — the exact CI stepgo test -race ./internal/webgreen