Skip to content

Commit Protocol (Standard 95)

Follow these steps to ensure every commit is high-fidelity, documented, and reaches the correct target branch.

// turbo-all

[!TIP] Modern Workflow: Use the /converge command to automate this entire protocol with high-fidelity verification.

1. Local Development (Ghost Isolation)

We treat the Local environment as our primary development sandbox.

  1. Spawn: At the start of a major task, the agent runs git checkout -b ghost/[TASK_ID]-[slug].
  2. Persistence: All incremental commits happen on this isolated branch.
  3. Ghost Verification: Run pnpm pre-flight and pnpm test on the ghost branch before any merge attempt.

2. The Gatekeepers (Verification Loop)

Before promoting from ghost to tst, the "Convergence Loop" must be executed:

  1. Auto-Correction: pnpm sunrise handles tag fixes.
  2. Docs Fast-Track: Skips heavy audits for documentation-only changes.
  3. Seeding Expansion: If logic changes impact data structures (e.g., Governance weights), you MUST update or create a companion .seed.ts script (Standard 105).
  4. Run: pnpm dataseeder:[name] to provision the local sandbox.
  5. AutoTesting: Run the domain-specific verification script.
  6. Run: pnpm autotester:[name].
  7. Local Pre-Commit: The .git/hooks/pre-commit script is the final local barrier.
  8. Staging Verification: After pushing to stg, re-run AutoTesters against the live environment to ensure environment parity.

2. Structured Commitment

  1. Stage Changes: git add .
  2. Commit Message: Use the format feat(domain): description or fix(domain): description.
  3. Cite relevant Standards (e.g., (STND-90)).

4. The Autononous Collapse (Merging)

Once a task is verified and a walkthrough.md is accepted:

  1. Testing Integration: git checkout tst
  2. Integrate: git merge --no-ff ghost/[TASK_ID]-[slug] -m "feat(task): collapse ghost branch [TASK_ID] into tst"
  3. Push: git push origin tst
  4. Staging Promotion: git checkout stg && git merge tst --no-ff -m "chore(sync): promote tst to stg" && git push origin stg
  5. Cleanup: git branch -d ghost/[TASK_ID]-[slug]

5. Handover

  1. Update daily_handoff_[DATE].md with the final merge hash and state.