Content Preview
--- description: Clean up merged branches locally and on remote, keeping only main, dev, and gh-pages. --- Clean up stale branches that have been merged or are no longer needed. ## Steps 1. **List local branches** to delete (excluding `main`, `dev`, `gh-pages`): ```bash git branch | grep -v -E '^\*|main$|dev$|gh-pages$' ``` Report what will be deleted. If no branches found, say "No local branches to clean" and skip to step 3. 2. **Delete local branches** that are fully merged: ```bash git
How to Use
Recommended: Install to project (local)
mkdir -p .claude/skills
curl -o .claude/skills/clean.md \
https://raw.githubusercontent.com/alirezarezvani/claude-skills/main/.claude/commands/git/clean.mdSkill is scoped to this project only. Add .claude/skills/ to your .gitignoreif you don't want to commit it.
Alternative: Clone full repo
git clone https://github.com/alirezarezvani/claude-skillsThen reference at .claude/commands/git/clean.md
Related Skills
clean-branches
Clean up merged and stale git branches
commandscleanbranches
by qdhenry · claude-command-suite
clean-code
This skill embodies the principles of "Clean Code" by Robert C. Martin (Uncle Bob). Use it to transform "code that works" into "code that is clean."
generalcleancode
by sickn33 (Antigravity) · antigravity-awesome-skills
audit-clean-arch
Comprehensive audit of Rust codebase against Clean Architecture principles, identifying violations and improvement opportunities
commandsauditcleanarch
by qdhenry · claude-command-suite
list-commands
List all registered Tauri IPC commands (invoke handlers) in a running app
commandslistcommands
by qdhenry · claude-command-suite