tidy

tidy is a skill for Claude Code from Eigenwise/eigenwise-toolshed. It costs 39 tokens per session (788 once invoked), scanned A, original, MIT.

A Git worktree cleanup tool that reviews every linked worktree and marks it either safe to remove or keep. A worktree is a separate working folder connected to the same Git repository.

In plain words
What is it for?
Use it to inspect all worktrees, explain why each can stay or go, and remove only the ones marked safe.
Why use it?
It prevents accidental deletion of folders with uncommitted files, unique local data, unfinished Git operations, or commits not safely available elsewhere.

Skill for Claude Code

Written for Claude Code: ${CLAUDE_PLUGIN_ROOT} variable.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the sidequest plugin — 6 skills, 3 agents shipped together

Good fit Use it to inspect all worktrees, explain why each can stay or go, and remove only the ones marked safe.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add Eigenwise/eigenwise-toolshed
Claude Code
/plugin install sidequest

Made for: Claude Code.

Or install sidequest, the plugin that ships this one along with the rest of its 6 skills, 3 agents.

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 tidy

README.md
[![agentmods](https://agentmods.dev/badge/skills/eigenwise/eigenwise-toolshed/tidy/github.svg)](https://agentmods.dev/skills/eigenwise/eigenwise-toolshed/tidy)
Your own site
<a href="https://agentmods.dev/skills/eigenwise/eigenwise-toolshed/tidy"><img src="https://agentmods.dev/badge/skills/eigenwise/eigenwise-toolshed/tidy/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 tidy

Your own site · 80×15
<a href="https://agentmods.dev/skills/eigenwise/eigenwise-toolshed/tidy"><img src="https://agentmods.dev/badge/skills/eigenwise/eigenwise-toolshed/tidy.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 39 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 788 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.
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.00039 $0.00788
Opus 5.5 $0.00016 $0.00315
Sonnet 5.5 $0.00008 $0.00158
Haiku 4.5 $0.00004 $0.00079

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

Security

Grade A, and why

tidy 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 4d 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.

plugins/sidequest/skills/tidy/SKILL.md · 36 lines

How it starts

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

Tidy

Say which worktrees are finished and remove those, wherever they live and whoever made them. A worktree marked keep is never touched.

Steps

  1. Look. From the main checkout run:

    node "${CLAUDE_PLUGIN_ROOT}/scripts/worktrees.mjs"
    

    It prints one row per linked worktree: path, branch, uncommitted or untracked files, commits on no remote and not merged into the main checkout's branch, locked, last commit date, and the verdict. safe means nothing is uncommitted, nothing is only there, no rebase, merge or bisect is in progress, and it is not locked. Only there includes ignored files: one the main checkout lacks or holds with other content (a .env, a local database), or an ignored folder the main checkout does not have. Installed or built folders the main checkout has too still read safe. Anything else is keep with the reason.

  2. Show it. Paste the table, then one line: how many can go, how many stay and why, in plain words (12 can go. 5 stay: 3 have uncommitted files, 2 hold a commit that is on no remote.). When the script prints a line starting Safe, and named by a person, show that line as it is before anything is removed: those folders or branches carry a name someone chose, not an agent's. Agent-named safe ones stay a count.

  3. Remove. When the person asked for the cleanup, go on at once. Otherwise ask once whether to remove the safe ones and wait for the yes. Then run:

    node "${CLAUDE_PLUGIN_ROOT}/scripts/worktrees.mjs" --remove-safe --named
    

    --named takes the person-named ones you showed in step 2 too; without it they stay. It re-reads every worktree, removes only the ones that are safe right now with a plain git worktree remove (never forced), and deletes a branch only when another branch or a remote holds its commits and git branch -d accepts it. Before a folder goes, any junction or symbolic link inside it that leads into the main checkout is taken away as a link, so the removal cannot delete files through it. The same run also lists local worktree-agent-* branches that have no worktree, safe when merged or empty and keep with the commit count otherwise. Hundreds of safe ones print as one count line with the keeps named, so show that line as it is and never list them one by one. To find worktree folders an older version left under the home directory that git no longer knows, pass the folder to look under (the older version's worktree folder, one folder per project inside it) as an argument to both commands. A folder is safe only when every file in it matches something the repository already holds; --remove-safe removes just those.

  4. Report what it removed, which branches it kept and why, and what stays.

Read the full file on GitHub · 36 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. 4d ago First seen · 36 lines · 39 tokens per session scan A 07a3585bc4af

Subscribe to this mod's changes

tidy is a skill published in the GitHub repository Eigenwise/eigenwise-toolshed (290 stars, last pushed today), licensed MIT. It adds 39 tokens to every session and 788 once invoked, about $0.0002 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-11-26.

Related

tidy compared with skills from other repositories

tidy next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
tidyEigenwise/eigenwise-toolshedSkill290todayMITA39Claude Code
release-notesphuryn/pm-skillsSkill28k21d agoMITA57Claude Code
cloudflare-workers-ci-cdsecondsky/claude-skillsSkill2578d agoMITA50Claude Code
glabNikiforovAll/claude-code-rulesSkill14328d agoApache-2.0A59Claude Code
version-bumpNikiforovAll/claude-code-rulesSkill14328d agoApache-2.0A48Claude Code
claude-code-bash-patternssecondsky/claude-skillsSkill2578d agoMITB52Claude Code
catchupAvijit07x/claude-dbSkill2372d agoApache-2.0B71Claude Code, Codex