agentleFS
Cleveland-RDCleveland-RD/hivehouse/skills/doc-updater/SKILL.md

doc-updater

Skill46 starsChanged 15 days agoMITView on GitHub

Analyzes code changes (staged, diff from main, or full codebase) and scans all documentation for staleness. Identifies outdated docs, presents a batch update proposal for approval, then applies all approved changes. Use when you want to ensure docs stay in sync with code changes.

1 other project uses a version of this.

Adopted by

Most recently taken up by

  • Other versions1 project uses a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 1

    1. myths-labs/muse★ 38same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repository8 other files it gives its agents.

The file

We split this skill into the rules it gives an agent

11 rules. About 0 are common, 9 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈9

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If no argument is provided, default to staged.

    line 22
  2. Very specific:

    staged: Run git diff and git diff --cached to see all working tree changes.

    line 30
  3. Distinctive:

    main: Run git diff main...HEAD to see all committed changes on the branch, plus git diff for uncommitted work.

    line 31
  4. Distinctive:

    Read each doc file (or at least its key sections) to understand what it documents.

    line 48
  5. Distinctive:

    If no docs need updating, say so clearly and stop.

    line 90
  6. Distinctive:

    After presenting findings, ask the user:

    line 94
  7. Distinctive:

    Wait for explicit user approval before making any edits.

    line 98
  8. Distinctive:

    Ask you to skip specific items

    line 100
  9. Distinctive:

    Ask for modifications to your proposals

    line 101
  10. Distinctive:

    Be conservative: Only flag genuine staleness.

    line 111
  11. Distinctive:

    Flag uncertainty: If you're unsure whether a doc section is outdated, mention it as a "possible" update and let the user decide.

    line 115

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Doc Updater

You are a documentation auditor. Your job is to detect documentation that has fallen out of sync with code changes and propose precise updates.

Announce at start: "Running doc-updater — analyzing changes and scanning documentation."

Input

The user invokes this skill with an optional argument specifying the change scope:

ArgumentMeaning
staged (default)Staged + unstaged changes (git diff and git diff --cached)
mainAll changes on current branch vs main (git diff main...HEAD + working tree)
codebaseNo diff — review the full codebase against all docs for general staleness

If no argument is provided, default to staged.

Process

Step 1: Gather the Changes

Based on the argument, collect the relevant code changes:

  • staged: Run git diff and git diff --cached to see all working tree changes.
  • main: Run git diff main...HEAD to see all committed changes on the branch, plus git diff for uncommitted work. Also run git log --oneline main..HEAD to understand the commit history.
  • codebase: Skip diff collection. Instead, read key structural files (package.json, tsconfig, directory layout) to understand the current state.

Summarize what changed: new files, removed files, renamed functions/exports, changed APIs, modified behavior, new env vars, new commands, architectural shifts, etc.

Step 2: Discover All Documentation

Find all documentation files in the repository:

- CLAUDE.md (project root), which also says where the project keeps its other docs
- README.md (if exists)
- the doc folders the project's CLAUDE.md names, and docs/**/*.md if it names none
- .claude/**/*.md (agent definitions, skill files, etc.)
- Any other .md files in the repo root

Read each doc file (or at least its key sections) to understand what it documents.

Step 3: Cross-Reference Changes Against Docs

For each documentation file, check whether the code changes affect anything the doc describes:

  • File paths or directory structure — Were files added, moved, or removed that the doc references?
  • Function/class/API names — Were any renamed, removed, or changed in signature?
  • Behavior descriptions — Does the doc describe behavior that the code changes have altered?
  • Environment variables — Were any added, removed, or renamed?
  • Commands or scripts — Were any added, changed, or removed?
  • Architecture descriptions — Do the changes alter the architecture in ways the doc should reflect?
  • Configuration — Were config files, schemas, or settings changed?
  • Examples or code snippets — Are embedded code examples now incorrect?

Be thorough but precise. Only flag docs that are genuinely affected — do not flag docs for trivial or unrelated changes.

Step 4: Present Findings

Present a clear summary to the user:

## Doc Update Report

### Changes Analyzed
<Brief summary of what code changes were detected>

### Docs That Need Updates

1. **<file path>** — <Section or line affected>
   - Current: <what the doc says now>
   - Needed: <what it should say, and why>

2. **<file path>** — <Section or line affected>
   - Current: <what the doc says now>
   - Needed: <what it should say, and why>

### Docs Reviewed (No Changes Needed)
- <file path> — Up to date
- <file path> — Up to date

If no docs need updating, say so clearly and stop.

Step 5: Get Batch Approval

After presenting findings, ask the user:

"I've identified N docs that need updates. Should I apply all of these changes?"

Wait for explicit user approval before making any edits. The user may:

  • Approve all changes
  • Ask you to skip specific items
  • Ask for modifications to your proposals

Step 6: Apply Updates

Once approved, apply all changes using the Edit tool. After applying:

  • List all files that were updated
  • Briefly confirm what was changed in each

Guidelines

  • Be conservative: Only flag genuine staleness. A doc that doesn't mention a new internal helper function is fine — a doc that describes a removed API is not.
  • Preserve style: Match the existing formatting, tone, and structure of each doc when making updates. Don't rewrite sections unnecessarily.
  • Minimal edits: Change only what needs changing. Don't restructure or "improve" docs beyond what the code changes require.
  • No new docs: This skill updates existing docs. It does not create new documentation files unless the user explicitly asks.
  • Flag uncertainty: If you're unsure whether a doc section is outdated, mention it as a "possible" update and let the user decide.

Common Mistakes

MistakeFix
Flagging docs for unrelated changesOnly flag if the doc specifically describes something that changed
Rewriting entire sectionsMake surgical edits — change only the outdated parts
Missing CLAUDE.md updatesCLAUDE.md often has the most critical project info — always check it carefully
Ignoring .claude/agents/Agent definitions reference architecture, file paths, and patterns that can go stale
Not reading the full docSkim every section — staleness can hide anywhere, not just in the obvious places
Making changes without approvalAlways present findings and wait for explicit user approval

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.