dart-branch-cleanup

dart-branch-cleanup is a skill for Claude Code from dartsim/dart. It costs 17 tokens per session (995 once invoked), scanned A, original, BSD-2-Clause.

A repository workflow for finding stale branches and, when explicitly approved, cleaning them up. A branch is a separate line of development in Git.

In plain words
What is it for?
It is for listing stale remote branches, checking branch ownership and safety, and preparing or performing approved cleanup.
Why use it?
It reduces confusion from old branches while keeping inspection separate from potentially destructive deletion.

Skill for Claude Code

Written for Claude Code: $ARGUMENTS substitution. Also seen: reads .claude/ paths; positional $N argument; mentions Claude Code.

Good fit It is for listing stale remote branches, checking branch ownership and safety, and preparing or performing approved cleanup.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/dartsim/dart/dart-branch-cleanup
About the project

DART is an open-source C++23 physics engine that simulates the movement and interactions of articulated rigid-body systems for robotics, animation, and machine learning. Researchers and developers use it for kinematics, dynamics, collision handling, constraints, and loading robot models, with C++ and Python interfaces. The catalogue add-ons support workflows built around this engine.

dartsim/dart · 1,223 stars · on GitHub · dart.readthedocs.io

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add dartsim/dart --skill dart-branch-cleanup
Clone the repo
git clone --depth 1 https://github.com/dartsim/dart

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for dart-branch-cleanup

README.md
[![agentmods](https://agentmods.dev/badge/skills/dartsim/dart/dart-branch-cleanup/github.svg)](https://agentmods.dev/skills/dartsim/dart/dart-branch-cleanup)
Your own site
<a href="https://agentmods.dev/skills/dartsim/dart/dart-branch-cleanup"><img src="https://agentmods.dev/badge/skills/dartsim/dart/dart-branch-cleanup/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for dart-branch-cleanup

Your own site · 80×15
<a href="https://agentmods.dev/skills/dartsim/dart/dart-branch-cleanup"><img src="https://agentmods.dev/badge/skills/dartsim/dart/dart-branch-cleanup.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 17 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 995 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00017 $0.00995
Opus 5.5 $0.00007 $0.00398
Sonnet 5.5 $0.00003 $0.00199
Haiku 4.5 $0.00002 $0.00100

Measured 23d ago against content hash 2d68549d4d5b, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

dart-branch-cleanup scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 23d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/dart-branch-cleanup/SKILL.md · 108 lines

How it starts

The opening of the file, as written. The whole thing — 108 lines — stays where its author put it; the contents beside it link to each section on GitHub.

dart-branch-cleanup

Use this skill to run the DART dart-branch-cleanup workflow. The editable workflow source lives in .claude/commands/; this generated skill is its entrypoint for Codex and Muse.

Invocation

  • Claude Code: /dart-branch-cleanup <arguments>
  • Codex: $dart-branch-cleanup <arguments>
  • Muse: /dart-branch-cleanup <arguments>

Treat the text after the skill name, or the user's request when the skill is loaded on demand, as $ARGUMENTS. When the workflow references $1, $2, etc., map those to the positional values supplied by the user.

Command Body

Analyze or clean branches: $ARGUMENTS

Required Reading

@AGENTS.md @docs/onboarding/ci-cd.md @docs/onboarding/contributing.md

Modes

  • analyze: inspect only, no deletions
  • action: prepare follow-up, or delete only after ownership/safety are clear and the maintainer/user gives explicit approval for each local or remote branch deletion

Default to analyze if the requested mode is ambiguous.

Workflow

  1. git fetch --all --no-prune
  2. List stale remote-tracking refs without deleting them:
    git remote prune origin --dry-run
    
    If origin uses SSH and port 22 is unavailable, keep the check read-only and use a temporary HTTPS rewrite instead of changing repository config:
    git -c url.https://github.com/[email protected]: \
      fetch --all --no-prune
    git -c url.https://github.com/[email protected]: \
      remote prune origin --dry-run
    
    To confirm that a remote PR branch was deleted without updating refs, query GitHub directly over HTTPS:
    git ls-remote --heads https://github.com/dartsim/dart.git <BRANCH>
    
  3. Determine the target/base branch from the PR or task, usually origin/main for development work.
  4. For each branch:
    git rev-list --left-right --count <TARGET>...<BRANCH>
    git log --oneline <TARGET>..<BRANCH>
    git diff --stat <TARGET>..<BRANCH>
    git cherry -v <TARGET> <BRANCH>
    
  5. Before any explicitly approved local branch deletion, check whether the branch is checked out by a linked worktree:
    git worktree list --porcelain
    git -C <WORKTREE> status --short --branch
    
    Dirty linked worktrees must not be removed, detached, or reset during branch cleanup. Only after explicit maintainer/user approval, switch that worktree to a preservation branch at the same commit to free the obsolete branch name before deleting the merged branch.
  6. The command git branch --merged may not prove ancestry for PR branches that landed through a squash or merge commit. Use the merged PR state plus an empty tree diff or equivalent git cherry -v output as the deletion signal; if the history relationship is unclear, keep the branch.
  7. Classify recommendations only; deleting a candidate requires explicit maintainer/user approval:
    • ahead=0: safe deletion candidate
    • equivalent commits already landed: deletion candidate
    • no-PR branch whose fix may already be solved differently on the target: confirm supersession with a focused A/B or content check before deciding; superseded is a deletion candidate, otherwise keep or open a follow-up
    • small, current, useful diff: keep or rebase into PR
    • large or unclear diff: document follow-up before action
  8. Ask for explicit maintainer/user approval before pruning refs or deleting any local or remote branch, even when ownership, branch purpose, and remote impact look clear.

Read the full file on GitHub · 108 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 23d ago Changed · +1 lines 2d68549d4d5b
  2. 26d ago Changed 8b41a049fcc3
  3. 1mo ago Changed e1c4a8da42d1
  4. 1mo ago Changed 54e713742939
  5. 2mo ago Changed 8d768d790d8f
  6. 2mo ago Changed 6191e022d289
  7. 2mo ago First seen · 107 lines · 17 tokens per session scan A 48919fdfa973

Subscribe to this mod's changes

dart-branch-cleanup is a skill published in the GitHub repository dartsim/dart (1,223 stars, last pushed yesterday), licensed BSD-2-Clause. It adds 17 tokens to every session and 995 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-01.

Related

dart-branch-cleanup compared with skills from other repositories

dart-branch-cleanup next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
dart-branch-cleanupdartsim/dartSkill1.2kyesterdayBSD-2-ClauseA17Claude Code
evaluating-cosmos-policyOrchestra-Research/AI-Research-SKILLsSkill14k27d agoMITA51Claude Code
merge-batchdiegosouzapw/OmniRouteSkill83k5d agoMITA46Claude Code
prowler-commitprowler-cloud/prowlerSkill15kyesterdayApache-2.0A44Claude Code, Codex
gh-auth-isolationgithub/gh-awSkill5.6kyesterdayMITA20Claude Code, Codex
comet-githubrpamis/cometSkill3.3kyesterdayMITA72Claude Code, Codex
release-helperSahir619/fable-methodSkill2.3k1mo agoMITA43Claude Code