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.
npx skills add viknesh20-20/claude-code-tool-kit --skill git-cleanupgit clone --depth 1 https://github.com/viknesh20-20/claude-code-tool-kitWrote 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.
[](https://agentmods.dev/skills/viknesh20-20/claude-code-tool-kit/git-cleanup)<a href="https://agentmods.dev/skills/viknesh20-20/claude-code-tool-kit/git-cleanup"><img src="https://agentmods.dev/badge/skills/viknesh20-20/claude-code-tool-kit/git-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.
<a href="https://agentmods.dev/skills/viknesh20-20/claude-code-tool-kit/git-cleanup"><img src="https://agentmods.dev/badge/skills/viknesh20-20/claude-code-tool-kit/git-cleanup.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00032 | $0.00580 |
| Opus 5.5 | $0.00013 | $0.00232 |
| Sonnet 5.5 | $0.00006 | $0.00116 |
| Haiku 4.5 | $0.00003 | $0.00058 |
Grade A, and why
git-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 1mo 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.
How it starts
The opening of the file, as written. The whole thing — 93 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Git Repository Cleanup
Current State
!git branch -a 2>/dev/null | head -30
!git remote -v 2>/dev/null
!git stash list 2>/dev/null
Cleanup Steps
Step 1: Identify Merged Branches
List local branches already merged into main/master:
git branch --merged main 2>/dev/null || git branch --merged master 2>/dev/null
Present the list to the user and ask for confirmation before deleting.
Safe to delete (already merged):
git branch -d <branch-name>
Step 2: Identify Stale Remote Branches
Prune remote tracking refs that no longer exist:
git remote prune origin --dry-run
After confirmation:
git remote prune origin
Step 3: Identify Old Unmerged Branches
List branches with no commits in the last 90 days:
git for-each-ref --sort=committerdate --format='%(committerdate:short) %(refname:short)' refs/heads/ | head -20
Never delete unmerged branches without explicit user approval.
Step 4: Clean Up Stashes
List all stashes:
git stash list
For old stashes (>30 days), suggest review and cleanup.
Step 5: Repository Size Analysis
Check for large files:
git rev-list --objects --all | git cat-file --batch-check='%(objecttype) %(objectname) %(objectsize) %(rest)' | sort -k3 -n -r | head -20
Step 6: Garbage Collection
git gc --auto
Output
Cleanup Summary
| Action | Count | Status |
|---|---|---|
| Merged branches deleted | X | Done/Pending |
| Stale remote refs pruned | X | Done/Pending |
| Old stashes reviewed | X | Done/Pending |
Branches NOT Deleted (unmerged)
List branches that were skipped with last commit date.
Space Recovered
Before and after repository size (if gc was run).
Rules
- NEVER force-delete (
git branch -D) without explicit user confirmation - NEVER delete main, master, develop, or release branches
- Always show what will be deleted before doing it
- Prefer
--dry-runfirst, then execute
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.
- 1mo ago First seen · 93 lines · 32 tokens per session scan A 15fbe84b1ca0
git-cleanup is a skill published in the GitHub repository viknesh20-20/claude-code-tool-kit (7 stars, last pushed 5mo ago), licensed MIT. It adds 32 tokens to every session and 580 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-08-31.
Other skills, from other repositories
github-pr-workflow
Prepare a GitHub pull request from a feature branch — branch hygiene, commit shape, title/body, verification notes, screenshots for UI work, and replies to review comments.
gh-find-prs
Survey open Codewhale PRs and triage each for mergeability and disposition against the real landing branch.
contributor-onboarding
Help a new contributor get productive on this checkout - inspect sync state against main, build, run the repository's exact verification gate, and produce a local what's-new digest. Never fetches, pulls, or modifies a dirty tree on its own. Explicit-only.
codew-release-qa-sweep
Use before claiming Codewhale release work is done: run the full gate sweep and list the manual QA targets.
aidlc-portfolio
Coordinate multiple AI-DLC workflows across repositories and Git worktrees using an evidence-backed portfolio catalog and deterministic workspace tooling. Use when initializing an AI-DLC portfolio workspace, discovering organization or business context, registering projects and dependencies, creating child intents and…
github
Use gh as the primary interface for GitHub data and actions. Keep this skill focused on basic operations and command safety, not maintainer triage strategy.