clean-repo.eval

clean-repo.eval is a command for Claude Code from davistroy/claude-marketplace. It costs 0 tokens per session (488 once invoked), scanned A, original, MIT.

A repository-cleanup command that looks for stale files, disorganised structure, and outdated documentation. A repository is the project folder where code and related files are kept.

In plain words
What is it for?
Use it to inspect temporary or empty files, check documentation references, report proposed cleanup, and preserve referenced project files.
Why use it?
It helps identify clutter while requiring a review and confirmation before deleting files.

Command for Claude Code

Written for Claude Code: a Claude Code command (commands/*.md). Also seen: mentions CLAUDE.md.

Good fit Use it to inspect temporary or empty files, check documentation references, report proposed cleanup, and preserve referenced project files.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/davistroy/claude-marketplace/clean-repo.eval
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.

Clone the repo
git clone --depth 1 https://github.com/davistroy/claude-marketplace

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 clean-repo.eval

README.md
[![agentmods](https://agentmods.dev/badge/commands/davistroy/claude-marketplace/clean-repo.eval/github.svg)](https://agentmods.dev/commands/davistroy/claude-marketplace/clean-repo.eval)
Your own site
<a href="https://agentmods.dev/commands/davistroy/claude-marketplace/clean-repo.eval"><img src="https://agentmods.dev/badge/commands/davistroy/claude-marketplace/clean-repo.eval/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 clean-repo.eval

Your own site · 80×15
<a href="https://agentmods.dev/commands/davistroy/claude-marketplace/clean-repo.eval"><img src="https://agentmods.dev/badge/commands/davistroy/claude-marketplace/clean-repo.eval.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 488 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.00000 $0.00488
Opus 5 $0.00000 $0.00244
Sonnet 5 $0.00000 $0.00098
Haiku 4.5 $0.00000 $0.00049

Measured 12d ago against content hash c841fde5332f, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

clean-repo.eval 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 12d 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.

evals/commands/clean-repo.eval.md · 77 lines

How it starts

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

Eval: /clean-repo

Purpose

Performs repository cleanup: removes stale files, organizes structure, refreshes documentation. This is a potentially destructive command. Evals should be run in a throwaway clone.

Fixtures

None — operates on the real repository. Always run in a git-cloned scratch copy, never on the working repo.

Setup

git clone <marketplace-repo> /tmp/eval-clean-repo-test
cd /tmp/eval-clean-repo-test
# Add some deliberate stale artifacts for testing:
mkdir -p tmp/ && touch tmp/scratch.txt
touch orphaned-note.txt

Test Scenarios

S1: Standard cleanup run

Invocation: /clean-repo

Must:

  • Presents a summary of what will be cleaned before making changes
  • Identifies obviously stale files (files in tmp/, zero-byte files, etc.)
  • Asks for confirmation before deleting anything
  • Does not delete files that are referenced in CLAUDE.md, plugin.json, or marketplace.json

Should:

  • Identifies the orphaned-note.txt as a candidate for review
  • Reports what was cleaned and what was skipped
  • Checks for outdated documentation references

Must NOT:

  • Delete plugin command or skill files without explicit confirmation
  • Delete git history or .git directory contents
  • Modify plugin.json or marketplace.json during cleanup

S2: Dry-run mode (if supported)

Invocation: /clean-repo --dry-run (or equivalent preview)

Must:

  • Reports what would be cleaned without making changes
  • Output clearly indicates "no changes made"

S3: Cleanup on already-clean repo

Invocation: /clean-repo (on repo with no stale artifacts)

Must:

  • Reports "nothing to clean" or equivalent
  • Does not error or make unnecessary changes

Rubric

Criterion Pass Threshold
Preview before changes Required
Confirmation required before destructive actions Required
No deletion of active plugin files Required
Clear post-cleanup summary Should

Read the full file on GitHub · 77 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. 12d ago First seen · 77 lines · 0 tokens per session scan A c841fde5332f

Subscribe to this mod's changes

clean-repo.eval is a command published in the GitHub repository davistroy/claude-marketplace (5 stars, last pushed 5d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 488 tokens. 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.