docs-cleaner
An agent skill by daymade, from daymade/claude-code-skills. Tags: code-quality, documentation, migration, review, validation.
What it does
Consolidates redundant documentation while preserving all valuable content; keeps a doc set truthful after things change. Modes: (1) POST-CHANGE GOVERNANCE — when code, scripts, config, env vars, ports, paths, deployment, auth, tests, or a documented procedure changed; also "which docs are now wrong", "check docs for inconsistencies", "过时的命令/路径", "文档同步". Use it even when the user mentions only the change and never the docs — updating them is part of the change, not optional cleanup. (2) CONSOLIDATION — "clean up docs", "documentation bloat", "reduce documentation sprawl", "consolidate documentation", "too many doc files", "merge redundant docs", "merge these docs", "文档太多/太乱", multiple files covering the same topic, or documentation exceeding 500 lines across multiple files on similar topics. Finds stale copies of a fact changed in only one place, values that should never have been persisted (counts, totals, "N items", restated summaries), rival definitions that drift apart, and orphaned cross-references.
Install
With the skills CLI, which installs into Claude Code, Codex, Cursor and other agents:
npx skills add daymade/claude-code-skills --skill docs-cleaner
Or copy the skill folder into Claude Code's skills directory by hand (~/.claude/skills for every project, or .claude/skills inside one):
git clone --depth 1 https://github.com/daymade/claude-code-skills
cp -r claude-code-skills/daymade-docs/docs-cleaner ~/.claude/skills/docs-cleaner
Safety box score
Grade C, moderate risk: 32 of 100 risk points, rated 2026-10-20. The grade rates what the skill and its scripts can reach on the machine of whoever installs it, across eight categories from shell execution to secrets access. How the score works.
This skill is a documentation-maintenance workflow: it searches repositories, rewrites markdown, moves retired docs into `_archive/`, and deletes redundant files after review. The main risks are local file loss, optional environment changes from installing `lychee`, and occasional outbound network traffic when checking external links.
| Category | Level | Why |
|---|---|---|
| Code & shell execution | 1 (low) | It relies on shell commands and a Python snippet (`rg`, `git show`, `git grep`, `lychee`, `python3 -c`) to inspect files, but the execution is bounded to documentation checks rather than arbitrary code. |
| Network access | 1 (low) | The workflow can check live links with `lychee docs/` and explicitly notes that it "also checks external URLs," so it may contact remote hosts, but that is limited to link validation. |
| Filesystem reach | 2 (moderate) | It can rewrite, move, archive, and delete docs, including `git mv` into `_archive/` and "Delete the redundant source files," which is a meaningful local-data blast radius. |
| Secrets & credentials | 0 (none) | It does not ask for tokens, passwords, keychains, browser sessions, or `.env` contents, and no step touches credential stores. |
| Privilege & persistence | 2 (moderate) | It recommends installing tooling with `brew install lychee` / `cargo install lychee`, which changes the user environment and may require package-manager privileges. |
| Instruction hijack surface | 0 (none) | I do not see instructions to ignore higher-level rules, follow remote prompts, hide actions, or otherwise override the agent's normal safeguards. |
| Irreversible actions | 2 (moderate) | The skill can archive, delete, and rewrite documentation on its own once the review gate is passed, so it has real write/delete autonomy within the repo. |
| Transparency | 0 (none) | The shipped files are plain Markdown with readable commands and no binaries, encoded blobs, or downloaded installers. |
Before installing
- Read `SKILL.md`'s archive/delete steps first: it can move docs into `_archive/` and remove files.
- Decide whether you want `lychee` installed (`brew install lychee` or `cargo install lychee`) before letting the agent run it.
- If your docs include external links, confirm whether link checks should be offline-only or allowed to reach the network.
Rated 2026-10-20 by an automated review of 3 files from the skill's repository.
Source
- Repository
- daymade/claude-code-skills (all skills from this repository)
- Path
- daymade-docs/docs-cleaner/SKILL.md
- Branch
- main
- Updated
- 2026-09-20
Related skills
- skill-reviewer — Reviews and improves Claude Code skills against official best practices.
- principle-minimize-reader-load — Apply when reviewing or shaping code that's hard to trace.
- principle-test-behavior-not-implementation — Apply when you write, change, or keep a test. Call the code the way its users do and assert the result they observe against a literal expected value.
- remediating-with-aws-security-agent — Pull AWS Security Agent findings (penetration tests and code reviews) and drive remediation.
- thermo-nuclear-code-quality-review — Run an extremely strict maintainability review for abstraction quality, giant files, and spaghetti-condition growth.
- typescript-best-practices — TypeScript best practices. Use when reading or editing any .ts or .tsx file.