Date: 2026-08-28
Repository: MSKazemi/idkmesh
User request: reduce the very large branch population, merge useful work toward main, and delete garbage/stale branches.
The repository branch population was reduced from 170 to 71 without bulk-merging stale branch history into main.
The cleanup followed the canonical Branch Steward distinction:
After the final fresh Branch Steward audit, the remaining 71 refs correspond to main plus unique/extract-or-retire work, evidence-preservation branches, one draft/human-review hold, and one integration-review branch.
No open pull request was merged during this cleanup.
The user’s request to merge useful branches therefore did not justify overriding those project review gates. Already-integrated source branches were deleted instead of being merged a second time.
The GitHub connector did not expose a direct delete-ref operation, so a temporary one-shot GitHub Actions workflow was used under the user’s explicit branch-cleanup authorization. The workflow had bounded contents: write permission, exact expected-head checks, no force update, and no merge/rebase operation. Evidence artifacts were retained for each pass, and the workflow was removed from main after use.
The first one-shot manifest was broader than the canonical Branch Steward retirement queue. It contained 102 entries rather than the canonical 98 candidates from the last complete pre-cleanup audit.
The first execution deleted 86 exact-head refs. Review of its evidence artifact exposed that 28 deleted refs belonged to unique/evidence-preservation or extract-or-retire lanes rather than the retirement lane.
Those 28 branch refs were immediately restored to their exact original commit SHAs. No commit objects or branch contents were lost. This correction was performed before continuing the cleanup.
Evidence:
332091997189700943564A second manifest was rebuilt from the actual canonical Branch Steward retirement queue and excluded the restored evidence/unique-work refs by construction.
The remaining 40 unchanged canonical retirement candidates were deleted successfully:
Evidence:
332097528399701122522The repository then had 75 branches.
A fresh Branch Convergence Audit on the 75-branch state (main at 48f2144b0721fac61f57bc245b5c413621fb8044) found only four remaining retirement candidates:
feature/project-domain-contracts-v0 — integrated via PR;feature/idkgraph-p1-review-session-validator — integrated via PR;fix/branch-audit-rate-limit-feedback — integrated via PR;feature/active-compute-pulse — closed/unmerged with no unique commits.Fresh audit evidence:
332098849719701161122The first tiny four-ref execution failed safely because it attempted git push --delete without a checked-out Git repository. Its evidence proved 0 refs were deleted and the branch count remained 75.
332099704849701181878The transport was changed to GitHub’s ref API while preserving the same four exact-head candidates. The corrected run succeeded:
Final evidence:
332100892149701229671The temporary write-capable retirement workflow was deleted from main immediately afterward.
initial branches = 170
final branches = 71
net reduction = 99 branches
reduction rate = 58.2%
No stale branch was merged merely to reduce branch count. No force update was used. Unique/evidence branches accidentally included by the first broad manifest were restored exactly before the canonical cleanup proceeded.
The remaining branch population should not be bulk-deleted. The fresh Branch Steward classification indicates that it is dominated by unique-work/extraction and evidence-preservation lanes rather than garbage.
Next branch reductions should therefore happen through convergence, not blind deletion:
main branch protection/rulesets before granting any persistent autonomous branch-write authority.Branch count is not itself a sufficient deletion objective. A retirement operation must be tied to a typed state (integrated-via-pr, no-unique-commits, etc.) and exact immutable head evidence. When an execution manifest and the canonical classifier disagree, fail closed or restore first, then continue from a fresh classification.