Skip to content

CI & Pre-Push Gates

Specification > Delivery & Safety

Publishing a change passes through gates that protect the shared branch: an ordered pre-push checklist a human runs before sending work, and continuous integration that runs automatically once the work arrives. This chapter defines those gates, the order in which the local checks run, and the requirement that documentation and its index stay consistent.


Once a change reaches the remote, automated verification runs without further prompting. CI is the backstop that confirms the published state actually builds and passes.

RuleLevel
Tests MUST run automatically on every pushMUST
Test coverage MUST be measured and uploaded as part of the runMUST
A failing CI run SHOULD be treated as a blocking signal for the affected branchSHOULD

This chapter describes the gates and their guarantees, not the pipeline configuration: how the automation is wired is an implementation detail and is intentionally out of scope.

Before a human chooses to push, an ordered checklist runs locally. The order is deliberate — cheaper, broader checks come first so that a problem is caught before more expensive verification runs.

StepGatePurpose
1DocsDocumentation and its index are current and consistent
2SecurityNo secrets, credentials, or sensitive data are about to be published
3TestsThe test suite passes locally
RuleLevel
The pre-push checklist MUST run in the order docs, then security, then testsMUST
A failed gate MUST stop the checklist before the pushMUST
The push MUST remain an explicit human decision after the checklist passesMUST

The checklist does not replace the human decision to publish; it qualifies the state as push-ready and leaves the choice to a person.

Documentation and its index MUST stay bidirectionally in sync. Every page is reachable from the index, and every index entry points to a page that exists. Drift in either direction is a defect.

DefectDescriptionLevel
Orphan pageA page exists but is not reachable from the indexMUST NOT
Dead referenceAn index entry or link points to a page that does not existMUST NOT
Stale duplicateAn outdated copy of a page lingers alongside its replacementMUST NOT
RuleLevel
The documentation set and its index MUST remain bidirectionally consistentMUST
The docs gate SHOULD detect orphans, dead references, and stale duplicates before a pushSHOULD