Skip to content

docs: branch-cleanup triage + deletion script (87 stale branches) - #110

Merged
THOClabs merged 1 commit into
mainfrom
chore/branch-cleanup-triage
Aug 6, 2026
Merged

docs: branch-cleanup triage + deletion script (87 stale branches)#110
THOClabs merged 1 commit into
mainfrom
chore/branch-cleanup-triage

Conversation

@THOClabs

@THOClabs THOClabs commented Aug 6, 2026

Copy link
Copy Markdown
Owner

Summary

Explains and resolves the 87-branch pileup. Adds docs/BRANCH_CLEANUP.md (full classification + rationale) and scripts/delete_stale_branches.sh (turnkey remote deletion, run locally since the automation sandbox can't push branch deletes).

Findings

All are safe to delete. The doc flags three distinct un-salvaged features in the swarm — hourly scanner, event journal, space-weather client — as salvage candidates to recover before deletion if wanted (otherwise they're discarded with the swarm).

Testing

  • Docs + shell script only; no code paths touched.

🤖 Generated with Claude Code


Generated by Claude Code


Note

Low Risk
Documentation and an opt-in maintenance script only; no runtime or application code paths change. Operational risk is limited to mistaken remote branch deletion if the script is run without review.

Overview
Adds docs/BRANCH_CLEANUP.md to document 87 stale origin branches against main: why the count is high (squash-merged branches still look unmerged, plus a March 2026 NEO/hourly-scan branch swarm), and how they are grouped (MERGED, SWARM, REVIEW, OLD-DEFAULT). The doc includes a full branch table and calls out three optional salvage features on swarm branches (hourly scanner, event journal, space-weather client) to recover before deletion.

Adds scripts/delete_stale_branches.sh, a local-only script that runs git push origin --delete for each listed branch (automation cannot delete remotes). master is left commented out for manual verification.

Reviewed by Cursor Bugbot for commit 5903328. Bugbot is set up for automated code reviews on this repo. Configure here.

Explains the 87-branch pileup (a March 2026 NEO/hourly-scan swarm of ~59 near-
duplicate AI branches + 15 already-squash-merged-this-session + 12 old reviews +
legacy master) and classifies every branch. All are safe to delete; the NEO core
was salvaged to main (#108/#109). Flags three distinct un-salvaged features
(hourly scanner, event journal, space-weather client) as salvage candidates
before the swarm is deleted. scripts/delete_stale_branches.sh is turnkey (remote
deletion is blocked from the automation sandbox, so it's run locally).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SKZMQ755R7q38SKqJsCQsg
@THOClabs
THOClabs merged commit 1001e2a into main Aug 6, 2026

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 5903328. Configure here.

git push origin --delete claude/nightwatch-frontend-demo-takdve
git push origin --delete claude/install-review-org-37y4ck
git push origin --delete claude/repo-landscape-audit-mdpb4f
git push origin --delete cursor/nightwatch-demo-console-86da

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Script aborts on delete failure

Medium Severity

With set -e, any failed git push origin --delete ends the script immediately, so later branches are never removed. A missing remote ref, permission error, or network blip on one line leaves cleanup incomplete and makes a full re-run fail again at the same step unless lines are edited manually.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 5903328. Configure here.

THOClabs added a commit that referenced this pull request Aug 7, 2026
#112)

Preserves the durable content of three open-PR branches before the v0.1.1
branch purge closes them:

- .claude/agents/ (7 review subagents) + .claude/commands/full-review.md
  from PR #93's branch — repo-state-independent review tooling; the stale
  July review reports on that branch are intentionally NOT taken.
- docs/design/ Claude Design frontend prompt pack (3 files) from PR #92's
  branch — targets the v0.2 frontend; NEO data-model sections predate
  #108/#109 and need a refresh before use (noted in its provenance table).
- docs/audits/ archive of AUDIT_LANDSCAPE.md + REVIEW_RECONCILIATION.md
  from PR #90's branch, with HISTORICAL SNAPSHOT headers — findings were
  fixed by #94-#110; preserved as engineering history. Its
  STALE_BRANCH_TRIAGE.md is dropped (superseded by #110).

Part 1/Step 2 of the v0.1.1 main-only consolidation.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
@THOClabs
THOClabs deleted the chore/branch-cleanup-triage branch August 7, 2026 04:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants