|
| 1 | +# Installation Guide |
| 2 | + |
| 3 | +This guide shows you how to install CockroachDB Skills for use with Claude Code. |
| 4 | + |
| 5 | +## Prerequisites |
| 6 | + |
| 7 | +- **Claude Code** - [Download and install Claude Code](https://claude.ai/download) |
| 8 | +- **Git** - For cloning the repository |
| 9 | + |
| 10 | +## Installation Options |
| 11 | + |
| 12 | +Choose the approach that fits your workflow: |
| 13 | + |
| 14 | +### Option 1: Project-Level Installation (Recommended for Teams) |
| 15 | + |
| 16 | +Skills are available only within a specific project directory. |
| 17 | + |
| 18 | +**When to use:** Working on a CockroachDB project and want these skills available only in that context. |
| 19 | + |
| 20 | +```bash |
| 21 | +# 1. Clone the repository |
| 22 | +git clone https://github.com/cockroachlabs/cockroachdb-skills.git |
| 23 | + |
| 24 | +# 2. Navigate to your project directory |
| 25 | +cd /path/to/your-cockroachdb-project |
| 26 | + |
| 27 | +# 3. Create the skills directory |
| 28 | +mkdir -p .claude/skills |
| 29 | + |
| 30 | +# 4. Create a symlink to the skills |
| 31 | +ln -s /path/to/cockroachdb-skills/skills .claude/skills/cockroachdb-skills |
| 32 | +``` |
| 33 | + |
| 34 | +### Option 2: User-Level Installation (Global Access) |
| 35 | + |
| 36 | +Skills are available in all Claude Code sessions, across all projects. |
| 37 | + |
| 38 | +**When to use:** You work with CockroachDB frequently and want these skills always available. |
| 39 | + |
| 40 | +```bash |
| 41 | +# 1. Clone the repository |
| 42 | +git clone https://github.com/cockroachlabs/cockroachdb-skills.git |
| 43 | + |
| 44 | +# 2. Create the user-level skills directory |
| 45 | +mkdir -p ~/.claude/skills |
| 46 | + |
| 47 | +# 3. Create a symlink to the skills |
| 48 | +ln -s /path/to/cockroachdb-skills/skills ~/.claude/skills/cockroachdb-skills |
| 49 | +``` |
| 50 | + |
| 51 | +### Option 3: Direct Copy (Without Symlinks) |
| 52 | + |
| 53 | +For environments where symbolic links aren't supported (some Windows configurations). |
| 54 | + |
| 55 | +**Project-level:** |
| 56 | +```bash |
| 57 | +# Clone and copy to project |
| 58 | +git clone https://github.com/cockroachlabs/cockroachdb-skills.git |
| 59 | +mkdir -p /path/to/your-project/.claude/skills |
| 60 | +cp -r cockroachdb-skills/skills /path/to/your-project/.claude/skills/cockroachdb-skills |
| 61 | +``` |
| 62 | + |
| 63 | +**User-level:** |
| 64 | +```bash |
| 65 | +# Clone and copy to user directory |
| 66 | +git clone https://github.com/cockroachlabs/cockroachdb-skills.git |
| 67 | +mkdir -p ~/.claude/skills |
| 68 | +cp -r cockroachdb-skills/skills ~/.claude/skills/cockroachdb-skills |
| 69 | +``` |
| 70 | + |
| 71 | +**Note:** When using the copy method, you'll need to manually update the skills when the repository is updated. |
| 72 | + |
| 73 | +## Verification |
| 74 | + |
| 75 | +After installation, verify that Claude Code can discover the skills: |
| 76 | + |
| 77 | +### 1. Start Claude Code |
| 78 | + |
| 79 | +Start Claude Code in a terminal or open it in your IDE. |
| 80 | + |
| 81 | +### 2. Ask Claude to List Skills |
| 82 | + |
| 83 | +``` |
| 84 | +What CockroachDB skills are available? |
| 85 | +``` |
| 86 | + |
| 87 | +**Expected response:** |
| 88 | +Claude should list the skills grouped by domain, such as: |
| 89 | +- Onboarding and Migrations (molt-fetch, molt-verify, molt-replicator) |
| 90 | +- Performance and Scaling (analyzing-range-distribution, profiling-statement-fingerprints) |
| 91 | +- Security and Governance (configuring-sso-and-scim, managing-tls-certificates) |
| 92 | +- Operations and Lifecycle (reviewing-cluster-health, upgrading-cluster-version) |
| 93 | +- And more... |
| 94 | + |
| 95 | +### 3. Test a Skill |
| 96 | + |
| 97 | +Try invoking a skill by describing a task: |
| 98 | + |
| 99 | +``` |
| 100 | +Help me check if my CockroachDB cluster is healthy |
| 101 | +``` |
| 102 | + |
| 103 | +Claude should use the `reviewing-cluster-health` skill to provide guidance. |
| 104 | + |
| 105 | +## Troubleshooting |
| 106 | + |
| 107 | +### Skills Not Discovered |
| 108 | + |
| 109 | +**Problem:** Claude doesn't recognize the CockroachDB skills. |
| 110 | + |
| 111 | +**Solutions:** |
| 112 | +1. **Check directory structure:** |
| 113 | + ```bash |
| 114 | + # For project-level |
| 115 | + ls -la .claude/skills/cockroachdb-skills/ |
| 116 | + |
| 117 | + # For user-level |
| 118 | + ls -la ~/.claude/skills/cockroachdb-skills/ |
| 119 | + ``` |
| 120 | + |
| 121 | + You should see skill directories like `onboarding-and-migrations/`, `security-and-governance/`, etc. |
| 122 | + |
| 123 | +2. **Verify SKILL.md files exist:** |
| 124 | + ```bash |
| 125 | + find .claude/skills/cockroachdb-skills -name "SKILL.md" |
| 126 | + ``` |
| 127 | + |
| 128 | + This should return multiple SKILL.md files. |
| 129 | + |
| 130 | +3. **Restart Claude Code** - Sometimes a restart is needed for skill discovery. |
| 131 | + |
| 132 | +4. **Check symlink:** |
| 133 | + ```bash |
| 134 | + # Verify symlink points to correct location |
| 135 | + ls -l .claude/skills/cockroachdb-skills |
| 136 | + ``` |
| 137 | + |
| 138 | +### Permission Errors |
| 139 | + |
| 140 | +**Problem:** Permission denied when creating symlinks or directories. |
| 141 | + |
| 142 | +**Solutions:** |
| 143 | +- On macOS/Linux: Use `sudo` if needed for user-level installation |
| 144 | +- On Windows: Run terminal as Administrator |
| 145 | +- Check file permissions: `chmod` and `chown` as needed |
| 146 | + |
| 147 | +### Symlink Not Supported |
| 148 | + |
| 149 | +**Problem:** Your environment doesn't support symbolic links. |
| 150 | + |
| 151 | +**Solution:** Use [Option 3: Direct Copy](#option-3-direct-copy-without-symlinks) instead. |
| 152 | + |
| 153 | +### Skills Appear Outdated |
| 154 | + |
| 155 | +**Problem:** Skills don't reflect recent repository updates. |
| 156 | + |
| 157 | +**Solutions:** |
| 158 | + |
| 159 | +**If using symlinks:** |
| 160 | +```bash |
| 161 | +# Navigate to the cloned repository |
| 162 | +cd /path/to/cockroachdb-skills |
| 163 | + |
| 164 | +# Pull latest changes |
| 165 | +git pull origin main |
| 166 | +``` |
| 167 | + |
| 168 | +**If using direct copy:** |
| 169 | +```bash |
| 170 | +# Pull latest changes |
| 171 | +cd /path/to/cockroachdb-skills |
| 172 | +git pull origin main |
| 173 | + |
| 174 | +# Re-copy to installation location |
| 175 | +# For project-level: |
| 176 | +cp -r skills /path/to/your-project/.claude/skills/cockroachdb-skills |
| 177 | + |
| 178 | +# For user-level: |
| 179 | +cp -r skills ~/.claude/skills/cockroachdb-skills |
| 180 | +``` |
| 181 | + |
| 182 | +## Updating Skills |
| 183 | + |
| 184 | +### With Symlinks (Options 1 & 2) |
| 185 | + |
| 186 | +Simply pull the latest changes from the repository: |
| 187 | + |
| 188 | +```bash |
| 189 | +cd /path/to/cockroachdb-skills |
| 190 | +git pull origin main |
| 191 | +``` |
| 192 | + |
| 193 | +The symlink ensures Claude Code automatically uses the updated skills. |
| 194 | + |
| 195 | +### With Direct Copy (Option 3) |
| 196 | + |
| 197 | +After pulling updates, re-copy the skills: |
| 198 | + |
| 199 | +```bash |
| 200 | +cd /path/to/cockroachdb-skills |
| 201 | +git pull origin main |
| 202 | + |
| 203 | +# Then copy to your installation location (see Option 3 above) |
| 204 | +``` |
| 205 | + |
| 206 | +## Uninstalling |
| 207 | + |
| 208 | +### Remove Project-Level Skills |
| 209 | + |
| 210 | +```bash |
| 211 | +rm .claude/skills/cockroachdb-skills |
| 212 | +``` |
| 213 | + |
| 214 | +### Remove User-Level Skills |
| 215 | + |
| 216 | +```bash |
| 217 | +rm ~/.claude/skills/cockroachdb-skills |
| 218 | +``` |
| 219 | + |
| 220 | +Or if you used direct copy: |
| 221 | + |
| 222 | +```bash |
| 223 | +rm -rf ~/.claude/skills/cockroachdb-skills |
| 224 | +``` |
| 225 | + |
| 226 | +## Next Steps |
| 227 | + |
| 228 | +- **[Usage Guide](usage.md)** - Learn how to discover and invoke skills |
| 229 | +- **[Browse Skills](../skills/)** - Explore available skills by domain |
| 230 | +- **[Contributing](../CONTRIBUTING.md)** - Help improve these skills |
| 231 | + |
| 232 | +## Getting Help |
| 233 | + |
| 234 | +- **[CockroachDB Documentation](https://www.cockroachlabs.com/docs/)** - Official CockroachDB docs |
| 235 | +- **[Claude Code Documentation](https://claude.ai/docs)** - Claude Code features and usage |
| 236 | +- **[GitHub Issues](https://github.com/cockroachlabs/cockroachdb-skills/issues)** - Report problems or request features |
0 commit comments