git-branch-cleanup
Installation
SKILL.md
Git Branch Cleanup
Systematically identify and remove branches that are no longer needed. Stale branches accumulate fast — especially when PRs auto-delete the remote branch on merge but the local tracking ref and local branch stick around. This skill walks through the cleanup safely so nothing important gets lost.
Workflow
Step 1: Refresh remote state
Start by fetching and pruning so the local view of remote branches is
accurate. Without this, you'd see stale origin/* refs for branches
GitHub already deleted on merge.
git fetch origin --prune