CloseBranch — Git skill for Claude Code
Close out a branch after its PR is merged/closed - switches to the PR's base branch (main, or the todo's arc branch), pulls latest, deletes local and remote branch.
How to install CloseBranch
Installs to ~/.claude/skills/keithdv-claudeskills-closebranch/SKILL.md
mkdir -p ~/.claude/skills/keithdv-claudeskills-closebranch && curl -fsSL https://raw.githubusercontent.com/keithdv/ClaudeSkills/HEAD/commands/closeBranch.md -o ~/.claude/skills/keithdv-claudeskills-closebranch/SKILL.md Restart Claude Code, or start a new session, for it to be picked up.
What CloseBranch does
name: closeBranch description: Close out a branch after its PR is merged/closed - switches to the PR's base branch (main, or the todo's arc branch), pulls latest, deletes local and remote branch argument-hint: "" allowed-tools: ["Bash"]
Clean up after a merged or closed PR by switching to the branch the PR targeted and deleting the branch.
Under the iterative-todo branch model a plan or punchlist branch PRs into the todo's **arc branch** (`{id}-arc` — e.g. `lcr-rewrite`), and the arc P
Alternatives in Git
- Intel — On-demand intelligence fetch for a target — CVEs, disclosed reports, new features 3.8k ★
- Drive Acquisition — Work GitHub issues that drive acquisition — verify relevance, close stale ones, fan out at most two engineer a 324 ★
- Push All.SKILL — Use when the user explicitly asks to stage all current changes, create a commit, and push to the remote after 262 ★
Full documentation available on GitHub
View Source RepositoryRelated Skills
Sweep For Archive
Close-out sweep over a recent window — verify what closed was really delivered, complete anything whose PR mer
Dip
Post-merge cleanup — switch to base branch, pull latest, delete the merged feature branch, restore any stash.
Agents Close Gitworktree
You are closing out a git worktree after completing (or abandoning) work. This command updates the tracking re
Sync Develop
Schedule sync with develop branch - adds to TODO, executes at convenient moment (after current task). Use when
PR Merged
Post-merge cleanup — checkout main, pull latest, delete the feature branch, and close the linked work item.
Git Pull
Pull the latest changes from the remote for the current branch.
Related Agents
Branch Janitor
Post-merge cleanup agent — after the human confirms a PR/branch merge, removes stale agent worktrees, deletes
Branch Gardener
Triages local branches and stashes in a managed repo (merged, stale, superseded, unpushed) and proposes deleti
Transcript Miner
Use when mining Claude Code transcripts for friction — where the tooling was wrong — at the end of a work stre