claudekit-cli 1.5.1 â 1.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +596 -11
- package/bin/ck-darwin-arm64 +0 -0
- package/bin/ck-darwin-x64 +0 -0
- package/bin/ck-linux-x64 +0 -0
- package/bin/ck-win32-x64.exe +0 -0
- package/package.json +27 -10
package/README.md
CHANGED
|
@@ -13,6 +13,16 @@ Command-line tool for bootstrapping and updating ClaudeKit projects.
|
|
|
13
13
|
- Secure credential storage using OS keychain
|
|
14
14
|
- Beautiful CLI interface with interactive prompts
|
|
15
15
|
|
|
16
|
+
## Documentation
|
|
17
|
+
|
|
18
|
+
Comprehensive documentation is available in the `/docs` directory:
|
|
19
|
+
|
|
20
|
+
- **[Project Overview & PDR](./docs/project-overview-pdr.md)** - Product requirements, features, roadmap, and success metrics
|
|
21
|
+
- **[Codebase Summary](./docs/codebase-summary.md)** - High-level overview, structure, key components, and metrics
|
|
22
|
+
- **[Code Standards](./docs/code-standards.md)** - Coding conventions, best practices, and quality guidelines
|
|
23
|
+
- **[System Architecture](./docs/system-architecture.md)** - Architecture diagrams, data flow, and integration points
|
|
24
|
+
- **[Binary Distribution](./docs/binary-distribution.md)** - Platform-specific binary compilation and distribution
|
|
25
|
+
|
|
16
26
|
## Prerequisites
|
|
17
27
|
|
|
18
28
|
Before using ClaudeKit CLI, you need to:
|
|
@@ -85,6 +95,14 @@ ck new --kit engineer --exclude "*.log" --exclude "temp/**"
|
|
|
85
95
|
|
|
86
96
|
# Multiple patterns
|
|
87
97
|
ck new --exclude "*.log" --exclude "*.tmp" --exclude "cache/**"
|
|
98
|
+
|
|
99
|
+
# With optional package installations (interactive)
|
|
100
|
+
ck new
|
|
101
|
+
|
|
102
|
+
# With optional package installations (non-interactive)
|
|
103
|
+
ck new --opencode --gemini
|
|
104
|
+
ck new --opencode
|
|
105
|
+
ck new --gemini
|
|
88
106
|
```
|
|
89
107
|
|
|
90
108
|
### Update Existing Project
|
|
@@ -122,6 +140,105 @@ ck versions --limit 50
|
|
|
122
140
|
ck versions --all
|
|
123
141
|
```
|
|
124
142
|
|
|
143
|
+
### Diagnose Issues
|
|
144
|
+
|
|
145
|
+
Run diagnostics to troubleshoot authentication and repository access problems:
|
|
146
|
+
|
|
147
|
+
```bash
|
|
148
|
+
# Run comprehensive diagnostics
|
|
149
|
+
ck diagnose
|
|
150
|
+
|
|
151
|
+
# Check specific kit
|
|
152
|
+
ck diagnose --kit engineer
|
|
153
|
+
|
|
154
|
+
# Get detailed output
|
|
155
|
+
ck diagnose --verbose
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
### Doctor Command
|
|
159
|
+
|
|
160
|
+
Check your current ClaudeKit setup and available components:
|
|
161
|
+
|
|
162
|
+
```bash
|
|
163
|
+
# Show ClaudeKit setup overview
|
|
164
|
+
ck doctor
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
**What the doctor command shows:**
|
|
168
|
+
- **Global Setup**: Installation status, version, and component counts
|
|
169
|
+
- **Project Setup**: Current project information and available components
|
|
170
|
+
- **Summary**: Overall setup status and total available components
|
|
171
|
+
- **Helpful Tips**: Next steps and related commands
|
|
172
|
+
|
|
173
|
+
**Example output:**
|
|
174
|
+
```
|
|
175
|
+
CK Global Setup
|
|
176
|
+
Location: /Users/user/.claude
|
|
177
|
+
Version: 1.0.0
|
|
178
|
+
Components: 0 agents, 0 commands, 0 workflows, 0 skills
|
|
179
|
+
|
|
180
|
+
CK Project Setup
|
|
181
|
+
Location: ./my-project/.claude
|
|
182
|
+
Version: 1.10.4
|
|
183
|
+
Name: claudekit-engineer
|
|
184
|
+
Components: 15 agents, 11 commands, 4 workflows, 31 skills
|
|
185
|
+
|
|
186
|
+
Total Available Components:
|
|
187
|
+
đ¤ Agents: 15
|
|
188
|
+
⥠Commands: 11
|
|
189
|
+
đ Workflows: 4
|
|
190
|
+
đ ī¸ Skills: 31
|
|
191
|
+
```
|
|
192
|
+
|
|
193
|
+
**What it checks:**
|
|
194
|
+
- â
GitHub CLI installation and authentication status
|
|
195
|
+
- â
Environment variables (GITHUB_TOKEN, GH_TOKEN)
|
|
196
|
+
- â
Token format validation
|
|
197
|
+
- â
Authentication method being used
|
|
198
|
+
- â
Repository access for each kit
|
|
199
|
+
- â
Release availability
|
|
200
|
+
- â
System information
|
|
201
|
+
|
|
202
|
+
**Example output:**
|
|
203
|
+
```
|
|
204
|
+
đ ClaudeKit CLI Diagnostics
|
|
205
|
+
|
|
206
|
+
âââââââââââââââââââââââââââââââââââââââââ
|
|
207
|
+
Diagnostic Results:
|
|
208
|
+
âââââââââââââââââââââââââââââââââââââââââ
|
|
209
|
+
|
|
210
|
+
â
GitHub CLI
|
|
211
|
+
GitHub CLI is installed and authenticated
|
|
212
|
+
This is the recommended authentication method
|
|
213
|
+
|
|
214
|
+
â
Environment Variables
|
|
215
|
+
GITHUB_TOKEN is set and has valid format
|
|
216
|
+
Token: ghp_xxx...
|
|
217
|
+
|
|
218
|
+
â
Authentication
|
|
219
|
+
Successfully authenticated via Environment Variable
|
|
220
|
+
Token: ghp_xxx...
|
|
221
|
+
|
|
222
|
+
â
Repository Access (engineer)
|
|
223
|
+
You have access to owner/claudekit-engineer
|
|
224
|
+
|
|
225
|
+
â
Releases (engineer)
|
|
226
|
+
Found 12 release(s)
|
|
227
|
+
Latest: v1.5.0 (1/15/2025)
|
|
228
|
+
|
|
229
|
+
âšī¸ System Information
|
|
230
|
+
Windows x64
|
|
231
|
+
Node.js: v20.11.0
|
|
232
|
+
Working directory: C:\Projects\my-app
|
|
233
|
+
ClaudeKit CLI: v1.5.1
|
|
234
|
+
|
|
235
|
+
âââââââââââââââââââââââââââââââââââââââââ
|
|
236
|
+
Summary: 6 passed, 0 failed, 0 warnings
|
|
237
|
+
âââââââââââââââââââââââââââââââââââââââââ
|
|
238
|
+
|
|
239
|
+
All checks passed! đ
|
|
240
|
+
```
|
|
241
|
+
|
|
125
242
|
### Other Commands
|
|
126
243
|
|
|
127
244
|
```bash
|
|
@@ -160,25 +277,291 @@ ck new --verbose --log-file debug.log
|
|
|
160
277
|
|
|
161
278
|
## Authentication
|
|
162
279
|
|
|
163
|
-
The CLI requires
|
|
280
|
+
The CLI requires GitHub authentication to download releases from private repositories.
|
|
281
|
+
|
|
282
|
+
### Authentication Flow
|
|
283
|
+
|
|
284
|
+
```
|
|
285
|
+
âââââââââââââââââââââââââââââââââââââââââââââââââââ
|
|
286
|
+
â Multi-Tier Authentication â
|
|
287
|
+
â â
|
|
288
|
+
â 1. GitHub CLI (gh auth token) â
|
|
289
|
+
â â (if not available) â
|
|
290
|
+
â 2. Environment Variables (GITHUB_TOKEN) â
|
|
291
|
+
â â (if not set) â
|
|
292
|
+
â 3. Config File (~/.claudekit/config.json) â
|
|
293
|
+
â â (if not found) â
|
|
294
|
+
â 4. OS Keychain (secure storage) â
|
|
295
|
+
â â (if not stored) â
|
|
296
|
+
â 5. User Prompt (with save option) â
|
|
297
|
+
âââââââââââââââââââââââââââââââââââââââââââââââââââ
|
|
298
|
+
```
|
|
299
|
+
|
|
300
|
+
### Quick Setup by Platform
|
|
301
|
+
|
|
302
|
+
<details>
|
|
303
|
+
<summary><strong>đĒ Windows (PowerShell) - Recommended Setup</strong></summary>
|
|
304
|
+
|
|
305
|
+
**Option 1: GitHub CLI (Easiest & Recommended)**
|
|
306
|
+
|
|
307
|
+
```powershell
|
|
308
|
+
# Install GitHub CLI
|
|
309
|
+
winget install GitHub.cli
|
|
310
|
+
|
|
311
|
+
# Authenticate with GitHub
|
|
312
|
+
gh auth login
|
|
313
|
+
# Select: "Login with a web browser"
|
|
314
|
+
# Follow the browser prompts
|
|
315
|
+
|
|
316
|
+
# Verify authentication
|
|
317
|
+
gh auth status
|
|
318
|
+
|
|
319
|
+
# You're ready! Use ClaudeKit CLI
|
|
320
|
+
ck new --kit engineer
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
**Option 2: Personal Access Token**
|
|
324
|
+
|
|
325
|
+
1. **Accept Repository Invitation**: Check your email for the GitHub repository invitation and accept it
|
|
326
|
+
2. **Create Token**: Go to [GitHub Token Settings](https://github.com/settings/tokens/new?scopes=repo&description=ClaudeKit%20CLI)
|
|
327
|
+
- Description: "ClaudeKit CLI"
|
|
328
|
+
- Scopes: Check `repo` (Full control of private repositories)
|
|
329
|
+
- Click "Generate token" and copy it
|
|
330
|
+
3. **Set Environment Variable Permanently**:
|
|
331
|
+
```powershell
|
|
332
|
+
# Set for current user (persists across sessions)
|
|
333
|
+
[System.Environment]::SetEnvironmentVariable(
|
|
334
|
+
"GITHUB_TOKEN",
|
|
335
|
+
"ghp_YOUR_TOKEN_HERE",
|
|
336
|
+
[System.EnvironmentVariableTarget]::User
|
|
337
|
+
)
|
|
338
|
+
|
|
339
|
+
# Restart PowerShell to apply changes
|
|
340
|
+
```
|
|
341
|
+
4. **Verify**:
|
|
342
|
+
```powershell
|
|
343
|
+
# Check if token is set
|
|
344
|
+
$env:GITHUB_TOKEN
|
|
345
|
+
```
|
|
346
|
+
|
|
347
|
+
**Note**: Setting via `$env:GITHUB_TOKEN = "ghp_xxx"` only works for the current session. Use the method above for permanent setup.
|
|
348
|
+
|
|
349
|
+
</details>
|
|
164
350
|
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
3. **OS Keychain**: Retrieves stored token from system keychain
|
|
168
|
-
4. **User Prompt**: Prompts for token input and offers to save it securely
|
|
351
|
+
<details>
|
|
352
|
+
<summary><strong>đ macOS / đ§ Linux - Setup</strong></summary>
|
|
169
353
|
|
|
170
|
-
|
|
354
|
+
**Option 1: GitHub CLI (Recommended)**
|
|
171
355
|
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
356
|
+
```bash
|
|
357
|
+
# macOS
|
|
358
|
+
brew install gh
|
|
359
|
+
|
|
360
|
+
# Linux (Debian/Ubuntu)
|
|
361
|
+
sudo apt install gh
|
|
362
|
+
|
|
363
|
+
# Authenticate
|
|
364
|
+
gh auth login
|
|
175
365
|
|
|
176
|
-
|
|
366
|
+
# Verify
|
|
367
|
+
gh auth status
|
|
368
|
+
```
|
|
369
|
+
|
|
370
|
+
**Option 2: Environment Variable**
|
|
177
371
|
|
|
178
372
|
```bash
|
|
373
|
+
# Add to ~/.bashrc, ~/.zshrc, or ~/.profile
|
|
179
374
|
export GITHUB_TOKEN=ghp_your_token_here
|
|
375
|
+
|
|
376
|
+
# Reload shell
|
|
377
|
+
source ~/.bashrc # or ~/.zshrc
|
|
378
|
+
```
|
|
379
|
+
|
|
380
|
+
</details>
|
|
381
|
+
|
|
382
|
+
### Why Use GitHub CLI?
|
|
383
|
+
|
|
384
|
+
```
|
|
385
|
+
GitHub CLI Benefits:
|
|
386
|
+
ââ â
Automatic token management
|
|
387
|
+
ââ â
Secure storage in OS credential manager
|
|
388
|
+
ââ â
Proper OAuth scopes (no manual setup)
|
|
389
|
+
ââ â
Token auto-refresh
|
|
390
|
+
ââ â
Works across all ClaudeKit commands
|
|
391
|
+
ââ â
One-time setup
|
|
392
|
+
```
|
|
393
|
+
|
|
394
|
+
## Troubleshooting
|
|
395
|
+
|
|
396
|
+
### Quick Diagnostic Tool
|
|
397
|
+
|
|
398
|
+
Before diving into manual troubleshooting, run the diagnostic tool to automatically check for common issues:
|
|
399
|
+
|
|
400
|
+
```bash
|
|
401
|
+
ck diagnose
|
|
402
|
+
```
|
|
403
|
+
|
|
404
|
+
This will check:
|
|
405
|
+
- GitHub CLI status
|
|
406
|
+
- Environment variables
|
|
407
|
+
- Token validity and format
|
|
408
|
+
- Repository access
|
|
409
|
+
- Release availability
|
|
410
|
+
|
|
411
|
+
### Common Issues & Solutions
|
|
412
|
+
|
|
413
|
+
<details>
|
|
414
|
+
<summary><strong>â "Access denied to repository" or "Cannot access ClaudeKit"</strong></summary>
|
|
415
|
+
|
|
416
|
+
**This error means authentication is working, but you don't have access to the repository.**
|
|
417
|
+
|
|
418
|
+
```
|
|
419
|
+
Possible Causes:
|
|
420
|
+
ââ 1. Haven't accepted GitHub repository invitation
|
|
421
|
+
ââ 2. Token lacks 'repo' scope
|
|
422
|
+
ââ 3. Token expired or revoked
|
|
423
|
+
ââ 4. Not added as collaborator yet
|
|
424
|
+
```
|
|
425
|
+
|
|
426
|
+
**Solutions:**
|
|
427
|
+
|
|
428
|
+
1. **Check Email for Repository Invitation**
|
|
429
|
+
- Look for email from GitHub with subject "You've been invited to join..."
|
|
430
|
+
- Click "Accept invitation"
|
|
431
|
+
- Wait a few minutes for permissions to propagate
|
|
432
|
+
|
|
433
|
+
2. **Use GitHub CLI (Recommended)**
|
|
434
|
+
```bash
|
|
435
|
+
gh auth login
|
|
436
|
+
# This handles scopes automatically
|
|
437
|
+
```
|
|
438
|
+
|
|
439
|
+
3. **Verify Token Scopes**
|
|
440
|
+
- Go to: https://github.com/settings/tokens
|
|
441
|
+
- Find your token
|
|
442
|
+
- Ensure `repo` scope is checked (not just `public_repo`)
|
|
443
|
+
- If missing, create a new token with proper scopes
|
|
444
|
+
|
|
445
|
+
4. **Test Repository Access**
|
|
446
|
+
```bash
|
|
447
|
+
# Try cloning the repository
|
|
448
|
+
git clone https://github.com/[owner]/claudekit-engineer.git
|
|
449
|
+
|
|
450
|
+
# If this fails, you don't have access yet
|
|
451
|
+
```
|
|
452
|
+
|
|
453
|
+
</details>
|
|
454
|
+
|
|
455
|
+
<details>
|
|
456
|
+
<summary><strong>â "Authentication failed" (401 Error)</strong></summary>
|
|
457
|
+
|
|
458
|
+
**This means the token is invalid or not being read.**
|
|
459
|
+
|
|
460
|
+
**Solutions:**
|
|
461
|
+
|
|
462
|
+
1. **Verify Token is Set**
|
|
463
|
+
```powershell
|
|
464
|
+
# Windows PowerShell
|
|
465
|
+
$env:GITHUB_TOKEN
|
|
466
|
+
|
|
467
|
+
# macOS/Linux
|
|
468
|
+
echo $GITHUB_TOKEN
|
|
469
|
+
```
|
|
470
|
+
|
|
471
|
+
2. **Check Token Format**
|
|
472
|
+
- Classic tokens start with `ghp_`
|
|
473
|
+
- Fine-grained tokens start with `github_pat_`
|
|
474
|
+
- Token should be 40+ characters
|
|
475
|
+
|
|
476
|
+
3. **Use GitHub CLI Instead**
|
|
477
|
+
```bash
|
|
478
|
+
gh auth login
|
|
479
|
+
```
|
|
480
|
+
|
|
481
|
+
4. **Restart Terminal**
|
|
482
|
+
- Environment variables may not be loaded
|
|
483
|
+
- Close and reopen terminal/PowerShell
|
|
484
|
+
|
|
485
|
+
</details>
|
|
486
|
+
|
|
487
|
+
<details>
|
|
488
|
+
<summary><strong>đĒ Windows: Token Not Persisting Between Sessions</strong></summary>
|
|
489
|
+
|
|
490
|
+
**Problem**: Setting `$env:GITHUB_TOKEN = "ghp_xxx"` doesn't work after closing PowerShell.
|
|
491
|
+
|
|
492
|
+
**Solution**: Use permanent environment variable:
|
|
493
|
+
|
|
494
|
+
```powershell
|
|
495
|
+
# Set for current user (permanent)
|
|
496
|
+
[System.Environment]::SetEnvironmentVariable(
|
|
497
|
+
"GITHUB_TOKEN",
|
|
498
|
+
"ghp_YOUR_TOKEN_HERE",
|
|
499
|
+
[System.EnvironmentVariableTarget]::User
|
|
500
|
+
)
|
|
501
|
+
|
|
502
|
+
# Restart PowerShell
|
|
503
|
+
```
|
|
504
|
+
|
|
505
|
+
Or use GitHub CLI for automatic management:
|
|
506
|
+
```powershell
|
|
507
|
+
winget install GitHub.cli
|
|
508
|
+
gh auth login
|
|
509
|
+
```
|
|
510
|
+
|
|
511
|
+
</details>
|
|
512
|
+
|
|
513
|
+
<details>
|
|
514
|
+
<summary><strong>â "No releases found" Error</strong></summary>
|
|
515
|
+
|
|
516
|
+
**Possible Causes:**
|
|
517
|
+
- Repository has no releases yet
|
|
518
|
+
- Token doesn't have access to releases
|
|
519
|
+
|
|
520
|
+
**Solutions:**
|
|
521
|
+
1. Contact support to verify releases exist
|
|
522
|
+
2. Check repository directly on GitHub
|
|
523
|
+
3. Use `ck versions --kit engineer` to list available versions
|
|
524
|
+
|
|
525
|
+
</details>
|
|
526
|
+
|
|
527
|
+
<details>
|
|
528
|
+
<summary><strong>đ Enable Verbose Mode for Debugging</strong></summary>
|
|
529
|
+
|
|
530
|
+
Get detailed logs to diagnose issues:
|
|
531
|
+
|
|
532
|
+
```bash
|
|
533
|
+
# Enable verbose output
|
|
534
|
+
ck new --verbose
|
|
535
|
+
|
|
536
|
+
# Save logs to file
|
|
537
|
+
ck new --verbose --log-file debug.log
|
|
538
|
+
|
|
539
|
+
# Or use environment variable
|
|
540
|
+
CLAUDEKIT_VERBOSE=1 ck new
|
|
180
541
|
```
|
|
181
542
|
|
|
543
|
+
This shows:
|
|
544
|
+
- Authentication method used
|
|
545
|
+
- API requests/responses
|
|
546
|
+
- Token validation (sanitized)
|
|
547
|
+
- File operations
|
|
548
|
+
- Error stack traces
|
|
549
|
+
|
|
550
|
+
</details>
|
|
551
|
+
|
|
552
|
+
### Getting Help
|
|
553
|
+
|
|
554
|
+
If you're still having issues:
|
|
555
|
+
|
|
556
|
+
1. **Run with verbose mode**: `ck new --verbose --log-file debug.log`
|
|
557
|
+
2. **Check the log file**: Review `debug.log` for detailed errors
|
|
558
|
+
3. **Report issue**: https://github.com/mrgoonie/claudekit-cli/issues
|
|
559
|
+
4. **Include**:
|
|
560
|
+
- Operating system (Windows/macOS/Linux)
|
|
561
|
+
- CLI version: `ck --version`
|
|
562
|
+
- Error message (with tokens removed)
|
|
563
|
+
- Steps to reproduce
|
|
564
|
+
|
|
182
565
|
## Available Kits
|
|
183
566
|
|
|
184
567
|
ClaudeKit offers premium starter kits available for purchase at [ClaudeKit.cc](https://claudekit.cc):
|
|
@@ -401,8 +784,10 @@ claudekit-cli/
|
|
|
401
784
|
|
|
402
785
|
### 1. Commands
|
|
403
786
|
- **`ck new`**: Create new project from release
|
|
404
|
-
- **`ck update`**: Update existing project
|
|
787
|
+
- **`ck update`**: Update existing project or install globally with `--global` flag
|
|
405
788
|
- **`ck versions`**: List available versions of ClaudeKit repositories
|
|
789
|
+
- **`ck doctor`**: Show current ClaudeKit setup and component overview
|
|
790
|
+
- **`ck diagnose`**: Run diagnostics to troubleshoot authentication and access issues
|
|
406
791
|
- **`ck --version`**: Show CLI version
|
|
407
792
|
- **`ck --help`**: Show help
|
|
408
793
|
|
|
@@ -419,6 +804,206 @@ claudekit-cli/
|
|
|
419
804
|
- **Merge**: Smart file merging with conflict detection
|
|
420
805
|
- **Protected Files**: .env, *.key, *.pem, node_modules/, .git/, etc.
|
|
421
806
|
|
|
807
|
+
## Frequently Asked Questions (FAQ)
|
|
808
|
+
|
|
809
|
+
<details>
|
|
810
|
+
<summary><strong>Q: Do I need to install the `gh` CLI to use ClaudeKit CLI?</strong></summary>
|
|
811
|
+
|
|
812
|
+
**A:** No, but it's highly recommended for the best experience.
|
|
813
|
+
|
|
814
|
+
**Without gh CLI:**
|
|
815
|
+
- Must manually create Personal Access Token
|
|
816
|
+
- Must set environment variable or enter token each time
|
|
817
|
+
- Must manage token renewal manually
|
|
818
|
+
|
|
819
|
+
**With gh CLI:**
|
|
820
|
+
- One-time `gh auth login` setup
|
|
821
|
+
- Automatic token management
|
|
822
|
+
- Better security (OAuth vs static token)
|
|
823
|
+
- Works seamlessly across all tools
|
|
824
|
+
|
|
825
|
+
</details>
|
|
826
|
+
|
|
827
|
+
<details>
|
|
828
|
+
<summary><strong>Q: Can I use the CLI if I'm already added to the repository?</strong></summary>
|
|
829
|
+
|
|
830
|
+
**A:** Yes! If you're added as a collaborator:
|
|
831
|
+
|
|
832
|
+
1. **Using CLI** (with gh or token):
|
|
833
|
+
```bash
|
|
834
|
+
ck new --kit engineer
|
|
835
|
+
```
|
|
836
|
+
|
|
837
|
+
2. **Direct git clone** (alternative):
|
|
838
|
+
```bash
|
|
839
|
+
git clone https://github.com/owner/claudekit-engineer.git
|
|
840
|
+
```
|
|
841
|
+
|
|
842
|
+
3. **Manual download** (from GitHub UI):
|
|
843
|
+
- Go to repository â Releases
|
|
844
|
+
- Download latest release zip
|
|
845
|
+
- Extract manually
|
|
846
|
+
|
|
847
|
+
The CLI provides additional benefits like smart merging, exclude patterns, and automatic updates.
|
|
848
|
+
|
|
849
|
+
</details>
|
|
850
|
+
|
|
851
|
+
<details>
|
|
852
|
+
<summary><strong>Q: What GitHub token scopes do I need?</strong></summary>
|
|
853
|
+
|
|
854
|
+
**A:** For private repositories, you need the **`repo`** scope.
|
|
855
|
+
|
|
856
|
+
```
|
|
857
|
+
Required Scope:
|
|
858
|
+
ââ repo (Full control of private repositories)
|
|
859
|
+
ââ repo:status
|
|
860
|
+
ââ repo_deployment
|
|
861
|
+
ââ public_repo
|
|
862
|
+
ââ repo:invite
|
|
863
|
+
ââ security_events
|
|
864
|
+
```
|
|
865
|
+
|
|
866
|
+
**Creating token with correct scope:**
|
|
867
|
+
1. Go to: https://github.com/settings/tokens/new?scopes=repo&description=ClaudeKit%20CLI
|
|
868
|
+
2. The `repo` scope will be pre-selected
|
|
869
|
+
3. Click "Generate token"
|
|
870
|
+
|
|
871
|
+
**Common mistake:** Using `public_repo` scope only - this doesn't work for private repositories.
|
|
872
|
+
|
|
873
|
+
</details>
|
|
874
|
+
|
|
875
|
+
<details>
|
|
876
|
+
<summary><strong>Q: Why am I getting "Access denied" even though I set GITHUB_TOKEN?</strong></summary>
|
|
877
|
+
|
|
878
|
+
**A:** "Access denied" with a valid token means you don't have repository access, not that authentication failed.
|
|
879
|
+
|
|
880
|
+
**Checklist:**
|
|
881
|
+
- â
Token is being read correctly (you'd get "Authentication failed" otherwise)
|
|
882
|
+
- â You haven't accepted the GitHub repository invitation
|
|
883
|
+
- â Token lacks `repo` scope (has `public_repo` only)
|
|
884
|
+
- â You're not added as a collaborator yet
|
|
885
|
+
|
|
886
|
+
**Solution:**
|
|
887
|
+
1. Check email for GitHub invitation
|
|
888
|
+
2. Accept invitation
|
|
889
|
+
3. Wait 2-5 minutes for permissions to sync
|
|
890
|
+
4. Try again: `ck new --kit engineer`
|
|
891
|
+
|
|
892
|
+
</details>
|
|
893
|
+
|
|
894
|
+
<details>
|
|
895
|
+
<summary><strong>Q: How do I make my token persist in PowerShell?</strong></summary>
|
|
896
|
+
|
|
897
|
+
**A:** Use permanent environment variable:
|
|
898
|
+
|
|
899
|
+
```powershell
|
|
900
|
+
[System.Environment]::SetEnvironmentVariable(
|
|
901
|
+
"GITHUB_TOKEN",
|
|
902
|
+
"ghp_YOUR_TOKEN",
|
|
903
|
+
[System.EnvironmentVariableTarget]::User
|
|
904
|
+
)
|
|
905
|
+
```
|
|
906
|
+
|
|
907
|
+
Then restart PowerShell.
|
|
908
|
+
|
|
909
|
+
**Or use GitHub CLI** (no manual token management needed):
|
|
910
|
+
```powershell
|
|
911
|
+
winget install GitHub.cli
|
|
912
|
+
gh auth login
|
|
913
|
+
```
|
|
914
|
+
|
|
915
|
+
</details>
|
|
916
|
+
|
|
917
|
+
<details>
|
|
918
|
+
<summary><strong>Q: Can I download releases without using the CLI?</strong></summary>
|
|
919
|
+
|
|
920
|
+
**A:** Yes, if you're a collaborator:
|
|
921
|
+
|
|
922
|
+
1. **Via Browser:**
|
|
923
|
+
- Go to repository on GitHub
|
|
924
|
+
- Click "Releases"
|
|
925
|
+
- Download the release zip/tarball
|
|
926
|
+
|
|
927
|
+
2. **Via Git:**
|
|
928
|
+
```bash
|
|
929
|
+
git clone https://github.com/owner/claudekit-engineer.git
|
|
930
|
+
```
|
|
931
|
+
|
|
932
|
+
3. **Via gh CLI:**
|
|
933
|
+
```bash
|
|
934
|
+
gh release download latest --repo owner/claudekit-engineer
|
|
935
|
+
```
|
|
936
|
+
|
|
937
|
+
However, the ClaudeKit CLI provides:
|
|
938
|
+
- Smart file merging during updates
|
|
939
|
+
- Protected file preservation
|
|
940
|
+
- Exclude pattern support
|
|
941
|
+
- Automatic wrapper directory detection
|
|
942
|
+
- Progress tracking
|
|
943
|
+
|
|
944
|
+
</details>
|
|
945
|
+
|
|
946
|
+
<details>
|
|
947
|
+
<summary><strong>Q: What's the difference between 401, 403, and 404 errors?</strong></summary>
|
|
948
|
+
|
|
949
|
+
**A:** Different errors mean different things:
|
|
950
|
+
|
|
951
|
+
```
|
|
952
|
+
401 Unauthorized:
|
|
953
|
+
ââ Token is invalid, expired, or not provided
|
|
954
|
+
Solution: Check token format, regenerate if needed
|
|
955
|
+
|
|
956
|
+
403 Forbidden:
|
|
957
|
+
ââ Token is valid but lacks required scopes
|
|
958
|
+
Solution: Recreate token with 'repo' scope
|
|
959
|
+
|
|
960
|
+
404 Not Found (on private repos):
|
|
961
|
+
ââ Token is valid but you don't have repository access
|
|
962
|
+
Solution: Accept GitHub invitation, wait for permissions
|
|
963
|
+
```
|
|
964
|
+
|
|
965
|
+
</details>
|
|
966
|
+
|
|
967
|
+
<details>
|
|
968
|
+
<summary><strong>Q: How do I know which authentication method is being used?</strong></summary>
|
|
969
|
+
|
|
970
|
+
**A:** Run with verbose mode:
|
|
971
|
+
|
|
972
|
+
```bash
|
|
973
|
+
ck new --verbose
|
|
974
|
+
```
|
|
975
|
+
|
|
976
|
+
You'll see output like:
|
|
977
|
+
```
|
|
978
|
+
[DEBUG] Using GitHub CLI authentication
|
|
979
|
+
# or
|
|
980
|
+
[DEBUG] Using environment variable authentication
|
|
981
|
+
# or
|
|
982
|
+
[DEBUG] Using keychain authentication
|
|
983
|
+
```
|
|
984
|
+
|
|
985
|
+
</details>
|
|
986
|
+
|
|
987
|
+
<details>
|
|
988
|
+
<summary><strong>Q: Is my GitHub token secure when using this CLI?</strong></summary>
|
|
989
|
+
|
|
990
|
+
**A:** Yes, multiple security measures are in place:
|
|
991
|
+
|
|
992
|
+
- â
Tokens are sanitized in all logs (replaced with `***`)
|
|
993
|
+
- â
Tokens stored in OS keychain are encrypted
|
|
994
|
+
- â
Tokens are never written to files in plain text
|
|
995
|
+
- â
Config file references keychain storage only
|
|
996
|
+
- â
HTTPS used for all GitHub API requests
|
|
997
|
+
- â
No telemetry or external logging
|
|
998
|
+
|
|
999
|
+
**Token storage locations:**
|
|
1000
|
+
- **gh CLI**: Windows Credential Manager / macOS Keychain / Linux Secret Service
|
|
1001
|
+
- **Keychain**: OS-encrypted secure storage
|
|
1002
|
+
- **Environment**: Session memory only
|
|
1003
|
+
- **Config file**: Reference only ("`stored_in_keychain`")
|
|
1004
|
+
|
|
1005
|
+
</details>
|
|
1006
|
+
|
|
422
1007
|
## License
|
|
423
1008
|
|
|
424
1009
|
MIT
|
package/bin/ck-darwin-arm64
CHANGED
|
Binary file
|
package/bin/ck-darwin-x64
CHANGED
|
Binary file
|
package/bin/ck-linux-x64
CHANGED
|
Binary file
|
package/bin/ck-win32-x64.exe
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,24 +1,40 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claudekit-cli",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.9.2",
|
|
4
4
|
"description": "CLI tool for bootstrapping and updating ClaudeKit projects",
|
|
5
5
|
"type": "module",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "git+https://github.com/mrgoonie/claudekit-cli.git"
|
|
9
|
+
},
|
|
10
|
+
"publishConfig": {
|
|
11
|
+
"access": "public",
|
|
12
|
+
"registry": "https://registry.npmjs.org"
|
|
13
|
+
},
|
|
6
14
|
"bin": {
|
|
7
|
-
"ck": "
|
|
15
|
+
"ck": "bin/ck.js"
|
|
8
16
|
},
|
|
9
17
|
"files": [
|
|
10
18
|
"bin"
|
|
11
19
|
],
|
|
12
20
|
"scripts": {
|
|
13
|
-
"dev": "bun run src/index.ts
|
|
14
|
-
"build": "bun build src/index.ts --outdir dist --target node --external keytar --external @octokit/rest
|
|
15
|
-
"compile": "bun build src/index.ts --compile --outfile ck
|
|
21
|
+
"dev": "bun run src/index.ts",
|
|
22
|
+
"build": "bun build src/index.ts --outdir dist --target node --external keytar --external @octokit/rest",
|
|
23
|
+
"compile": "bun build src/index.ts --compile --outfile ck",
|
|
16
24
|
"compile:binary": "bun build src/index.ts --compile --outfile bin/ck",
|
|
17
|
-
"
|
|
18
|
-
"
|
|
19
|
-
"
|
|
20
|
-
"
|
|
21
|
-
"
|
|
25
|
+
"prepublishOnly": "npm run build && npm run compile && npm run build:platform-binaries",
|
|
26
|
+
"build:platform-binaries": "bun run scripts/build-platform-binaries.js",
|
|
27
|
+
"test": "bun test",
|
|
28
|
+
"test:watch": "bun test --watch",
|
|
29
|
+
"test:quick": "./scripts/dev-quick-start.sh test",
|
|
30
|
+
"lint": "biome check .",
|
|
31
|
+
"lint:fix": "biome check --fix .",
|
|
32
|
+
"lint:fix-unsafe": "biome check --fix --unsafe .",
|
|
33
|
+
"format": "biome format --write .",
|
|
34
|
+
"typecheck": "tsc --noEmit",
|
|
35
|
+
"dev:quick": "./scripts/dev-quick-start.sh",
|
|
36
|
+
"dev:all": "./scripts/dev-quick-start.sh all",
|
|
37
|
+
"metrics": "bun run scripts/workflow-metrics.ts"
|
|
22
38
|
},
|
|
23
39
|
"keywords": [
|
|
24
40
|
"cli",
|
|
@@ -41,6 +57,7 @@
|
|
|
41
57
|
"fs-extra": "^11.2.0",
|
|
42
58
|
"ignore": "^5.3.2",
|
|
43
59
|
"keytar": "^7.9.0",
|
|
60
|
+
"minimatch": "^10.1.1",
|
|
44
61
|
"ora": "^9.0.0",
|
|
45
62
|
"picocolors": "^1.1.1",
|
|
46
63
|
"tar": "^7.4.3",
|