Skip to main content
ClaudeWave
Slash Command6k repo starsupdated 5mo ago

docs-sync

The docs-sync command identifies documentation that needs updating by comparing recent code changes in TypeScript files against related documentation files, then verifies whether code examples, API signatures, and prop types remain accurate. Use this command when deploying code changes to catch outdated or incorrect documentation before release.

Install in Claude Code
Copy
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/ChrisWiles/claude-code-showcase/HEAD/.claude/commands/docs-sync.md -o ~/.claude/commands/docs-sync.md
Then start a new Claude Code session; the slash command loads automatically.

docs-sync.md

# Documentation Sync

Check if documentation matches the current code state.

## Instructions

1. **Find recent code changes**:
   ```bash
   git log --since="30 days ago" --name-only --pretty=format: -- "*.ts" "*.tsx" | sort -u
   ```

2. **Find related documentation**:
   - Search `/docs/` for files mentioning changed code
   - Check README files near changed code
   - Look for TSDoc comments in changed files

3. **Verify documentation accuracy**:
   - Do code examples still work?
   - Are API signatures correct?
   - Are prop types up to date?

4. **Report only actual problems**:
   - Documentation is a living document
   - Only flag things that are WRONG, not missing
   - Don't suggest documentation for documentation's sake

5. **Output a checklist** of documentation that needs updating