Clean Gone Branches

•
726
•

Streamlines your Git workflow by identifying and removing local branches that no longer exist on the remote repository.

This skill automates the cleanup of stale local Git branches to maintain a clutter-free development environment. It performs a remote fetch with pruning, identifies local branches marked as 'gone', and intelligently checks for associated Git worktrees to ensure safe removal. By handling the detection and deletion of obsolete references in one step, it helps developers keep their local repository synchronized with the remote state without manual tracking or repetitive command execution.

主要功能

01Identification of local branches marked as [gone]
02Automated remote pruning using git fetch --prune
03726 GitHub stars
04Bulk deletion of obsolete local tracking branches
05Comprehensive reporting of all removed branches and worktrees
06Integrated Git worktree detection and safe removal

使用场景

01Standardizing local repository state across different development machines
02Post-sprint cleanup after multiple feature branches are merged and deleted on the remote
03Automated maintenance of long-lived projects with high branch turnover