Local mirror of Claude Code documentation files from https://docs.anthropic.com/en/docs/claude-code/, automatically updated with semantic versioning.
One-command installation:
curl -fsSL https://raw.githubusercontent.com/mnestorov/cc-docs-mirror/main/scripts/bin/install.sh | bash
This sets up the /docs
command in Claude Code with automatic updates.
- π Instant documentation access - Read docs without web delays
- π Automatic updates - Stays current with latest Claude Code docs
- π Changelog integration - Access Claude Code release notes with
/docs changelog
- π Smart search - Find docs with natural language queries
- π Cross-platform - Works on macOS and Linux
- β‘ Fast - Local files mean instant access
/docs # List all available documentation
/docs hooks # Read hooks documentation instantly
/docs mcp # Read MCP documentation
/docs changelog # Read Claude Code release notes
/docs -t # Check sync status with GitHub
/docs -t hooks # Check updates, then read hooks docs
/docs what's new # See recent documentation changes
/docs how do I use environment variables?
/docs explain memory management
/docs find all mentions of authentication
- git - Repository management
- jq - JSON processing
- curl - Downloads
- python3 - For documentation fetching (optional)
- Claude Code - Obviously! π
git clone https://github.com/mnestorov/cc-docs-mirror.git
cd cc-docs
./scripts/bin/install.sh
The project includes an enhanced Python script for fetching documentation with progress visualization:
# Install Python dependencies
cd scripts
pip install -r requirements.txt
# Run the documentation fetcher
python fetch_claude_docs.py
Features:
- π Progress bars with real-time updates
- π Smart retry logic with exponential backoff
- β Content validation to ensure quality
- π Detailed statistics and success rates
- π― Automatic discovery of new documentation pages
cc-docs/
βββ docs/ # Mirror of official documentation
βββ scripts/
β βββ fetch_claude_docs.py # Enhanced documentation fetcher
β βββ requirements.txt # Python dependencies
β βββ bin/ # Shell scripts
β βββ install.sh # Main installer
β βββ claude-docs-helper.sh # Core functionality
β βββ uninstall.sh # Uninstaller
β βββ update-version.sh # Version updater
βββ .github/workflows/ # GitHub Actions for automation
βββ package.json # Semantic release configuration
βββ .releaserc.json # Release automation rules
- GitHub Actions fetches documentation changes every few hours
- Semantic versioning tracks releases automatically
- Pre-tool hooks check for updates when you read docs
- Git pull updates happen automatically when new content is available
# Check if command exists
ls ~/.claude/commands/docs.md
# Restart Claude Code and try again
# Or reinstall:
curl -fsSL https://raw.githubusercontent.com/mnestorov/cc-docs-mirror/main/scripts/bin/install.sh | bash
# Force update check
/docs -t
# Manual update
cd ~/.claude-code-docs && git pull
- Missing dependencies: Install
git
,jq
,curl
- Permission errors: Check
~/.claude/
directory permissions - Network issues: Check if GitHub Actions are running: View Actions
From anywhere, run:
~/.claude-code-docs/scripts/bin/uninstall.sh
Or use the docs command:
/docs uninstall
The uninstaller will remove:
- The /docs command from
~/.claude/commands/docs.md
- The auto-update hook from
~/.claude/settings.json
- The installation directory
~/.claude-code-docs
If you prefer to uninstall manually:
- Remove the command file:
rm -f ~/.claude/commands/docs.md
-
Remove the hook from Claude settings: Edit
~/.claude/settings.json
to remove the PreToolUse hook that references claude-code-docs. -
Remove the installation directory:
rm -rf ~/.claude-code-docs
If you have multiple installations, the uninstaller will notify you about other locations it finds. You'll need to remove each one separately.
To find all installations:
find ~ -name "claude-code-docs" -type d 2>/dev/null | grep -v ".claude-code-docs"
The uninstaller creates a backup of your Claude settings at ~/.claude/settings.json.backup
before removing hooks, just in case.
To reinstall after uninstalling:
curl -fsSL https://raw.githubusercontent.com/mnestorov/cc-docs-mirror/main/scripts/bin/install.sh | bash
We welcome contributions from the community! Please see our Contributing Guidelines for detailed information.
-
Fork & Clone:
git clone https://github.com/YOUR_USERNAME/cc-docs-mirror.git cd cc-docs-mirror npm install
-
Make Changes following our conventions:
- Use conventional commits (
feat:
,fix:
,docs:
) - Test your changes locally
- Update documentation as needed
- Use conventional commits (
-
Submit a Pull Request with a clear description
- πͺ Windows Support: Help make scripts work on Windows (high priority!)
- π Bug Reports: Open an issue with reproduction steps
- π‘ Feature Requests: Start a discussion for new ideas
- π Documentation: Improve guides, add examples, fix typos
- β‘ Performance: Optimize fetching and processing speed
- π Translations: Help internationalize the project
See CONTRIBUTING.md for complete guidelines, code style, and development setup.
- Repository cloned over HTTPS from GitHub
- All operations confined to
~/.claude-code-docs
- No external data transmission (beyond git operations)
- Hooks only run
git pull
for documentation updates
For additional security, you can fork the repository and install from your own fork.
Documentation content belongs to Anthropic.
This mirror tool is open source under MIT license.
- πͺ Windows support
- π Enhanced search capabilities
- π± Better mobile/terminal UI
- π Offline-first improvements
- π¨ Customizable themes
- π Usage analytics (optional)
- π Multi-language support
Thanks to all contributors who help make this project better!
Want to see your name here? Check out our Contributing Guidelines!
- Anthropic for Claude Code and excellent documentation
- Community contributors who help improve this tool
- Claude Code users who provide feedback and feature requests
- Open source community for inspiration and best practices
- π Documentation: Check the sections above
- π¬ Discussions: GitHub Discussions
- π Bug Reports: GitHub Issues
- π§ Contact: Open an issue for questions
Made with β€οΈ for the community