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 darellchua2/opencode-config-template --skill deprecated-code-cleanup-skillgit clone --depth 1 https://github.com/darellchua2/opencode-config-templateWrote 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/darellchua2/opencode-config-template/deprecated-code-cleanup-skill)<a href="https://agentmods.dev/skills/darellchua2/opencode-config-template/deprecated-code-cleanup-skill"><img src="https://agentmods.dev/badge/skills/darellchua2/opencode-config-template/deprecated-code-cleanup-skill/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/darellchua2/opencode-config-template/deprecated-code-cleanup-skill"><img src="https://agentmods.dev/badge/skills/darellchua2/opencode-config-template/deprecated-code-cleanup-skill.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.00054 | $0.00958 |
| Opus 5.5 | $0.00022 | $0.00383 |
| Sonnet 5.5 | $0.00011 | $0.00192 |
| Haiku 4.5 | $0.00005 | $0.00096 |
Grade C, and why
deprecated-code-cleanup-skill scanned grade C with 1 finding 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.
Recursive force deletehighDestructive command
rm -rf with a variable or a broad path is one typo away from removing the wrong tree.
When protocol is enabled, this skill defaults to `Iterations: 10` (sufficient for typical single-pass workflows). Override with `Iterations: N` for specific tasks. Safety blocks: `.env`, `node_modules/`, `rm -rf`, `git p How it starts
The opening of the file, as written. The whole thing — 66 lines — stays where its author put it; the contents beside it link to each section on GitHub.
What I do
Remove @deprecated code from TypeScript/Next.js codebases with dependency-traced, tier-based safety (proven: ~800+ lines removed across ~50 files, zero typecheck/lint errors). Discovery → dependency trace → tier classification → phased removal → verify after every phase.
When to use me
Removing deprecated functions/interfaces/modules; post-migration cleanup; barrel-file audit; pre-release debt removal. Ask when scope is unclear, protected modules exist, or a Tier-3 migration path is preferred.
Prereqs: tsc, npm run lint, npm run build available; clean git tree for rollback.
Phases (strict order; verify after each)
Phase 0 — Discovery & classification (analysis only): grep -rn '@deprecated' src/ --include='*.ts' --include='*.tsx'. For EACH item, trace consumers through ALL import forms — alias (from "@/path"), relative (from "./module" — the most-missed form), dynamic (import(), barrel re-exports (index.ts); JSDoc @see references are comment-only, ignore. Propagate through deprecated chains: if a deprecated item's only consumer is also deprecated, both are dead. Then classify into tiers and verify page.tsx reachability (no active App Router entry may transitively reach it):
| Tier | Definition | Action |
|---|---|---|
| 1 | Zero non-deprecated consumers | Delete |
| 2 | Consumers exist, all trivially migratable | Migrate consumers, then delete |
| 3 | Migration-dependent (consumer rework non-trivial) | Plan per-item; delete only after migration |
| 4 | Public API / externally consumed | Keep + document (removal is a semver-major decision) |
Phase 1 — Dead files (Tier 1, zero importers): delete file, check for orphaned tests/styles beside it.
Phase 2 — Dead exports (from surviving files): remove the export + its local helpers if now unused; leave the file.
Phase 3 — Migration-dependent (Tier 3): per item — migrate consumers first, delete in the same phase, never leave consumers importing a deleted symbol.
Phase 4 — Barrel audit: index.ts re-exports of deleted symbols must go; a barrel whose exports are ALL dead is itself dead — delete it and fix importers to direct paths.
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 Changed · -422 lines 83b0e5d1fcb8
- 1mo ago First seen · 488 lines · 54 tokens per session scan C 12cd822aef24
deprecated-code-cleanup-skill is a skill published in the GitHub repository darellchua2/opencode-config-template (6 stars, last pushed 28d ago), licensed Apache-2.0. It adds 54 tokens to every session and 958 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it C with 1 finding (recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
codebase-refactoring
Three-part workflow to improve overall codebase health with jscpd — find and fix duplicated code, find and remove or refactor dead code, then find and simplify the largest/most complex files. Starts from --dashboard/--health to prioritize and ends by re-measuring the score.
recipe-diagnose
Investigate problem, verify findings, and derive solutions.
roam
Codebase comprehension via roam-code CLI. Use when exploring codebases, planning modifications, debugging failures, assessing PR risk, or checking architecture health. Triggers on: understanding project structure, pre-change safety checks, finding symbols/files, blast radius analysis, affected tests, health scoring…
dorodango
Polishes working code through successive quality passes in fresh subagents. Use after tests pass when code needs multi-dimension refinement before release.
ring:searching-code
Forensic code search and analysis with optional Chain of Draft (CoD) ultra-concise mode. Five-phase methodology (clarification, planning, execution, analysis, synthesis) with severity assessment. Use for targeted investigation of specific patterns, bugs, or vulnerabilities. Skip for broad architecture mapping (use…
ring:using-assert
Using lib-observability/assert, Lerian's runtime assertion package, in two modes. Sweep Mode detects panic()/log.Fatal zero-panic violations, DIY invariant checks, hand-rolled domain predicates, and missing InitAssertionMetrics. Reference Mode catalogs the asserter lifecycle, domain predicates, observability trident…