Add scheduled workflow to prune merged and stale remote branches#577
Add scheduled workflow to prune merged and stale remote branches#577Copilot wants to merge 1 commit into
Conversation
Co-authored-by: shanselman <2892+shanselman@users.noreply.github.com>
|
Codex review: needs real behavior proof before merge. Reviewed May 28, 2026, 7:38 PM ET / 23:38 UTC. Summary Reproducibility: not applicable. this is an administrative workflow PR, not a product bug with a current-main reproduction path. The relevant check is policy and live-branch dry-run proof rather than reproducing a failure. Review metrics: 2 noteworthy metrics.
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Risk before merge
Maintainer options:
Next step before merge
Security Review findings
Review detailsBest possible solution: Land branch cleanup only after maintainers approve the deletion policy, the write-capable action is pinned, and a dry-run or manual execution log proves the candidate set against the live branch inventory. Do we have a high-confidence way to reproduce the issue? Not applicable; this is an administrative workflow PR, not a product bug with a current-main reproduction path. The relevant check is policy and live-branch dry-run proof rather than reproducing a failure. Is this the best way to solve the issue? No, not as submitted; the safer solution is to pin the write-capable action and prove the deletion candidate set in dry-run/manual mode before enabling a weekly schedule. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found, but no applicable review policy affected this item. Codex review notes: model gpt-5.5, reasoning high; reviewed against 281656fc017e. Label changesLabel changes:
Label justifications:
Evidence reviewedSecurity concerns:
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
141 remote branches accumulated with no automated cleanup — 85
repo-assist/branches (many chained retry suffixes), 13 already merged into master, 39 older than 60 days with no open PR.Adds
prune-branches.yml— a weekly scheduled workflow (workflow_dispatch-triggerable) that:masterisidenticalorbehindmaster/main/release, GitHub-protected branches, andmemory/*(repo-assist state)Recommended follow-up
Enable "Automatically delete head branches" in repo Settings → General to prevent future post-merge accumulation.