update-user-docs
Automatically updates documentation based on PR changes to keep user guides current.
Install
mkdir -p .claude/skills/update-user-docs && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/17122" && unzip -o skill.zip -d .claude/skills/update-user-docs && rm skill.zipInstalls to .claude/skills/update-user-docs
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Auto-update user-facing documentation when a feature or behavior change ships. Run when dev invokes manually so they can add the doc to a PR ready-for-review. Optionally pass a PR number for an already-merged PR.Key capabilities
- →Auto-update user-facing documentation
- →Identify changed files and affected platforms from git diffs
- →Gather context from commit messages and Linear tickets
- →Determine if documentation updates are needed based on scope
- →Prefer updating existing pages for feature extensions
- →Create new pages for completely new features
How it works
This skill gathers context from git diffs, commit messages, and PR details to determine necessary documentation updates and then drafts changes to user-facing markdown files.
Inputs & outputs
When to use update-user-docs
- →Update docs from a merged PR
- →Sync docs based on branch diff
- →Generate documentation for a feature release
About this skill
Update Docs
Auto-update user-facing documentation when a feature or behavior change ships.
If $ARGUMENTS is provided, treat it as a GitHub PR number. Use gh pr view $ARGUMENTS to get the PR diff, changed files, and description. Use this instead of the current branch context.
If no argument is provided, use the current branch's diff against main, commit messages, and any linked Linear ticket to determine what changed.
Guardrails
- Edit live docs only under
apps/website/content/**. - Put Obsidian docs under
apps/website/content/obsidian/**. - Put Roam docs under
apps/website/content/roam/**. - Do not edit legacy docs route shells or deleted legacy docs paths such as
apps/website/app/(docs)/docs/*/pages,docMap.ts,navigation.ts, orsharedPages. - Do not update runtime code, app routes, or package interfaces unless the dev explicitly asks for that separately.
- Use existing Nextra Markdown, MDX, and
nextra/componentsfeatures before proposing custom styling or layout. - Use the existing global
NodeTagMDX component for discourse candidate tag pills, such as<NodeTag type="clm" />. Allowedtypevalues areque,clm,evd,src,hyp,res, andiss. Do not create one-off tag styling or CSS in docs content. - Do not add or change theme, layout, route, component, or CSS code while adding documentation content. If existing Nextra features are not enough, flag the author to create a separate Linear ticket for new Nextra functionality.
When to Run
On demand. Two modes:
- Current branch - Run while on a feature branch that's ready for PR or review.
- Merged PR - Pass a PR number to generate docs for an already-merged PR that's missing documentation.
Step 1: Gather Context
If running for the current branch
Collect information from three sources:
- Changed files - Run
git diff main...HEAD --name-onlyto identify what changed. Use file paths to determine the affected platform (see scope-detection.md for mapping). - Commit messages - Run
git log main...HEAD --onelinefor a summary of what was done. - Linear ticket - If a Linear ticket is linked by branch name or PR description, pull the title, description, and acceptance criteria for additional context. Use the Linear connector if available. If it is not available, prompt the dev to install Linear MCP using these instructions: https://linear.app/docs/mcp
If running for a merged PR
Use the PR number to gather context via gh:
- PR details - Run
gh pr view <PR_NUMBER>to get the title, description, and linked issues. - Changed files - Run
gh pr diff <PR_NUMBER> --name-onlyto identify what changed. Use file paths to determine the affected platform. - Linear ticket - If a Linear ticket is referenced in the PR title, branch name, or description, pull additional context from it.
Step 2: Determine If Docs Are Needed
Apply the scope detection heuristic. See scope-detection.md for the full yes/no lists and file path to platform mapping.
If no docs update is needed, inform the dev and stop.
Step 3: New Page vs Update Existing
- Search existing docs only under
apps/website/content/**. - Prefer updating an existing page when the change extends or corrects an already-documented feature.
- Create a new page when the feature or workflow has no natural existing home.
- If multiple plausible homes exist, ask the dev which page or section should own the content.
Defaults:
- Completely new feature with no existing coverage -> new page.
- Extending or modifying an already-documented feature -> update the existing page.
- Change applies to both platforms -> update both platform docs unless the existing docs already share a conceptual page through both sidebars.
Step 4: Write or Update the Doc
Follow the formatting rules in doc-conventions.md.
For an existing page:
- Edit the Markdown or MDX file under the relevant
apps/website/content/**path. - Preserve existing frontmatter and local style.
- Verify any new links point to live docs routes or existing files.
For a new page:
- Choose the correct platform and section directory, such as
apps/website/content/obsidian/core-features/orapps/website/content/roam/guides/. - Add a kebab-case
.mdor.mdxfile with frontmatter. - Add the page slug to the nearest
_meta.tsfile so it appears in the sidebar. See navigation-mapping.md. - Update
apps/website/docsRouteMap.tsonly when a flat legacy redirect like/docs/<platform>/<slug>should continue to resolve to the new sectioned route.
Step 5: Verification
- Present the draft changes to the dev for review.
- List any screenshots that still need to be captured.
- Flag broken cross-links, missing route map redirects, or stale content observed while editing.
- Leave all changes as unstaged modifications. The dev reviews and commits themselves.
When not to use it
- →When the user needs to edit live docs outside of `apps/website/content/**`
- →When the user needs to update runtime code, app routes, or package interfaces
- →When the user needs to add or change theme, layout, route, component, or CSS code
Limitations
- →Edits live docs only under `apps/website/content/**`
- →Does not update runtime code, app routes, or package interfaces
- →Does not add or change theme, layout, route, component, or CSS code
How it compares
This workflow automates the process of synchronizing user documentation with code changes, reducing manual effort and ensuring accuracy.
Compared to similar skills
update-user-docs side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| update-user-docs (this skill) | 0 | 5mo | No flags | Intermediate |
| documentation-review | 11 | 5mo | No flags | Beginner |
| docs-review | 10 | 8mo | No flags | Beginner |
| workthrough | 10 | 9mo | Review | Beginner |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
documentation-review
stacklok
Reviews documentation for factual accuracy
docs-review
metabase
Review documentation changes for compliance with the Metabase writing style guide. Use when reviewing pull requests, files, or diffs containing documentation markdown files.
workthrough
bear2u
Automatically document all development work and code modifications in a structured workthrough format. Use this skill after completing any development task, bug fix, feature implementation, or code refactoring to create comprehensive documentation.
claude-md-improver
anthropics
Audit and improve CLAUDE.md files in repositories. Use when user asks to check, audit, update, improve, or fix CLAUDE.md files. Scans for all CLAUDE.md files, evaluates quality against templates, outputs quality report, then makes targeted updates. Also use when the user mentions "CLAUDE.md maintenance" or "project memory optimization".
anti-slop
rand
Comprehensive toolkit for detecting and eliminating "AI slop" - generic, low-quality AI-generated patterns in natural language, code, and design. Use when reviewing or improving content quality, preventing generic AI patterns, cleaning up existing content, or enforcing quality standards in writing, code, or design work.
agent-md-refactor
davila7
Refactor bloated AGENTS.md, CLAUDE.md, or similar agent instruction files to follow progressive disclosure principles. Splits monolithic files into organized, linked documentation.