sync-docs
Sync documentation with code. Use when user asks to update docs, check docs, fix stale documentation, update changelog, or after code changes.
npx skills add agent-sh/agentsys --skill sync-docs --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# sync-docs Unified skill for syncing documentation with code state. Combines discovery, analysis, and CHANGELOG update into a single workflow. ## Parse Arguments ```javascript const args = '$ARGUMENTS'.split(' ').filter(Boolean); const mode = args.find(a => ['report', 'apply'].includes(a)) || 'report'; const scope = args.find(a => a.startsWith('--scope='))?.split('=')[1] || 'recent'; const includeUndocumented = args.includes('--include-undocumented'); ``` ## Quick Start - Agent Instructions **Step 1**: Get changed files (use Bash): ```bash # Recent changes (default scope) git diff --name-only origin/main..HEAD 2>/dev/null || git diff --name-only HEAD~5..HEAD # Or for all files git ls-files '*.md' ``` **Step 2**: Find docs that reference changed files (use Grep): - Search for filenames, function names, class names in `*.md` files - Check README.md, CHANGELOG.md, docs/*.md **Step 3**: Analyze each doc for issues: - Version mismatches (compare doc versions to package.json) - Removed exports (symbols in docs but not in code) - Outdated code examples - Import path changes **Step 4**: Check CHANGELOG: - Look for `## [Unreleased]` section - Compare recent commit messages to CHANGELOG ent
- Parse Arguments
- Quick Start - Agent Instructions
- Input
- Architecture
- Implementation Details (Reference)
- Phase 1: Detect Project Context
- Phase 1.5: Ensure Repo-Map
- Phase 2: Find Related Documentation
- Phase 3: Analyze Documentation Issues
- Phase 4: Check CHANGELOG
- Phase 5: Return Structured Results
- Output Format
- Usage by Agents
- sync-docs-agent (standalone /sync-docs)
Recent changes (default scope) git diff --name-only origin/main..HEAD 2>/dev/null || git diff --name-only HEAD~5..HEAD Or for all files git ls-files '*.md'
What does the sync-docs skill do?
Sync documentation with code. Use when user asks to update docs, check docs, fix stale documentation, update changelog, or after code changes.
How do I install it?
Run `npx skills add agent-sh/agentsys --skill sync-docs --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From agent-sh/agentsys, a repository with 923 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.