Skip to content

Keep BINCLUSIVE.md in sync in CI

b8e gen renders BINCLUSIVE.md from binclusive.json and injects a pointer to it into AGENTS.md/CLAUDE.md. Because BINCLUSIVE.md is generated, it drifts the moment someone edits binclusive.json and forgets to regenerate — or hand-edits the generated file directly.

If you want CI to catch that drift, run b8e gen --check as a build step:

Terminal window
b8e gen --check

--check re-renders the contract in memory, compares it against BINCLUSIVE.md and the injected pointer on disk, writes nothing, and exits non-zero if either has drifted. A passing check proves the committed files match binclusive.json.

Add it as its own step so a red check names drift specifically:

- run: b8e gen --check

When the check fails, the fix is local — regenerate and commit:

Terminal window
b8e gen
git add BINCLUSIVE.md AGENTS.md CLAUDE.md
git commit -m "chore: regenerate BINCLUSIVE.md"

Point b8e gen --check at a subdirectory by passing its path if binclusive.json does not live at the repository root:

Terminal window
b8e gen --check ./packages/app

For the owned-file and pointer model, see the gen reference.