@kennethsolomon/shipkit 1.0.0

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.
Files changed (117) hide show
  1. package/README.md +321 -0
  2. package/bin/shipkit.js +146 -0
  3. package/commands/sk/brainstorm.md +63 -0
  4. package/commands/sk/branch.md +35 -0
  5. package/commands/sk/config.md +96 -0
  6. package/commands/sk/execute-plan.md +85 -0
  7. package/commands/sk/features.md +238 -0
  8. package/commands/sk/finish-feature.md +154 -0
  9. package/commands/sk/help.md +103 -0
  10. package/commands/sk/hotfix.md +61 -0
  11. package/commands/sk/plan.md +30 -0
  12. package/commands/sk/release.md +72 -0
  13. package/commands/sk/security-check.md +188 -0
  14. package/commands/sk/set-profile.md +71 -0
  15. package/commands/sk/status.md +25 -0
  16. package/commands/sk/update-task.md +35 -0
  17. package/commands/sk/write-plan.md +72 -0
  18. package/package.json +23 -0
  19. package/skills/sk:accessibility/LICENSE.txt +177 -0
  20. package/skills/sk:accessibility/SKILL.md +150 -0
  21. package/skills/sk:api-design/LICENSE.txt +177 -0
  22. package/skills/sk:api-design/SKILL.md +158 -0
  23. package/skills/sk:brainstorming/SKILL.md +124 -0
  24. package/skills/sk:debug/SKILL.md +252 -0
  25. package/skills/sk:debug/debug_conductor.py +177 -0
  26. package/skills/sk:debug/lib/__init__.py +1 -0
  27. package/skills/sk:debug/lib/bug_gatherer.py +55 -0
  28. package/skills/sk:debug/lib/context_reader.py +139 -0
  29. package/skills/sk:debug/lib/findings_writer.py +76 -0
  30. package/skills/sk:debug/lib/lessons_writer.py +165 -0
  31. package/skills/sk:debug/lib/step_runner.py +326 -0
  32. package/skills/sk:features/SKILL.md +238 -0
  33. package/skills/sk:frontend-design/LICENSE.txt +177 -0
  34. package/skills/sk:frontend-design/SKILL.md +191 -0
  35. package/skills/sk:laravel-init/SKILL.md +37 -0
  36. package/skills/sk:laravel-new/SKILL.md +68 -0
  37. package/skills/sk:lint/SKILL.md +113 -0
  38. package/skills/sk:perf/LICENSE.txt +177 -0
  39. package/skills/sk:perf/SKILL.md +188 -0
  40. package/skills/sk:release/SKILL.md +113 -0
  41. package/skills/sk:release/references/android-checklist.md +269 -0
  42. package/skills/sk:release/references/ios-checklist.md +339 -0
  43. package/skills/sk:release/release.sh +378 -0
  44. package/skills/sk:review/SKILL.md +346 -0
  45. package/skills/sk:review/references/security-checklist.md +223 -0
  46. package/skills/sk:schema-migrate/SKILL.md +125 -0
  47. package/skills/sk:schema-migrate/orms/drizzle.md +546 -0
  48. package/skills/sk:schema-migrate/orms/laravel.md +367 -0
  49. package/skills/sk:schema-migrate/orms/prisma.md +357 -0
  50. package/skills/sk:schema-migrate/orms/rails.md +351 -0
  51. package/skills/sk:schema-migrate/orms/sqlalchemy.md +385 -0
  52. package/skills/sk:schema-migrate/references/detection.md +110 -0
  53. package/skills/sk:setup-claude/SKILL.md +365 -0
  54. package/skills/sk:setup-claude/references/detection.md +6 -0
  55. package/skills/sk:setup-claude/references/templates.md +11 -0
  56. package/skills/sk:setup-claude/scripts/apply_setup_claude.py +443 -0
  57. package/skills/sk:setup-claude/scripts/detect_arch_changes.py +437 -0
  58. package/skills/sk:setup-claude/templates/.claude/docs/arch-changelog-guide.md.template +6 -0
  59. package/skills/sk:setup-claude/templates/.claude/docs/changelog-guide.md.template +12 -0
  60. package/skills/sk:setup-claude/templates/CHANGELOG.md.template +21 -0
  61. package/skills/sk:setup-claude/templates/CLAUDE.md.template +299 -0
  62. package/skills/sk:setup-claude/templates/arch-changelog-guide.md.template +3 -0
  63. package/skills/sk:setup-claude/templates/changelog-guide.md.template +3 -0
  64. package/skills/sk:setup-claude/templates/commands/brainstorm.md.template +74 -0
  65. package/skills/sk:setup-claude/templates/commands/execute-plan.md.template +57 -0
  66. package/skills/sk:setup-claude/templates/commands/features.md.template +238 -0
  67. package/skills/sk:setup-claude/templates/commands/finish-feature.md.template +155 -0
  68. package/skills/sk:setup-claude/templates/commands/plan.md.template +30 -0
  69. package/skills/sk:setup-claude/templates/commands/re-setup.md.template +38 -0
  70. package/skills/sk:setup-claude/templates/commands/release.md.template +74 -0
  71. package/skills/sk:setup-claude/templates/commands/security-check.md.template +172 -0
  72. package/skills/sk:setup-claude/templates/commands/status.md.template +17 -0
  73. package/skills/sk:setup-claude/templates/commands/write-plan.md.template +34 -0
  74. package/skills/sk:setup-claude/templates/finish-feature.md.template +3 -0
  75. package/skills/sk:setup-claude/templates/plan.md.template +3 -0
  76. package/skills/sk:setup-claude/templates/status.md.template +3 -0
  77. package/skills/sk:setup-claude/templates/tasks/findings.md.template +19 -0
  78. package/skills/sk:setup-claude/templates/tasks/lessons.md.template +26 -0
  79. package/skills/sk:setup-claude/templates/tasks/progress.md.template +20 -0
  80. package/skills/sk:setup-claude/templates/tasks/security-findings.md.template +5 -0
  81. package/skills/sk:setup-claude/templates/tasks/todo.md.template +26 -0
  82. package/skills/sk:setup-claude/templates/tasks/workflow-status.md.template +31 -0
  83. package/skills/sk:setup-claude/templates/tasks-findings.md.template +3 -0
  84. package/skills/sk:setup-claude/templates/tasks-lessons.md.template +3 -0
  85. package/skills/sk:setup-claude/templates/tasks-progress.md.template +3 -0
  86. package/skills/sk:setup-claude/templates/tasks-todo.md.template +3 -0
  87. package/skills/sk:setup-claude/tests/test_apply_setup_claude.py +193 -0
  88. package/skills/sk:setup-optimizer/SKILL.md +184 -0
  89. package/skills/sk:setup-optimizer/lib/__init__.py +24 -0
  90. package/skills/sk:setup-optimizer/lib/detect.py +205 -0
  91. package/skills/sk:setup-optimizer/lib/discover.py +221 -0
  92. package/skills/sk:setup-optimizer/lib/enrich.py +163 -0
  93. package/skills/sk:setup-optimizer/lib/merge.py +277 -0
  94. package/skills/sk:setup-optimizer/lib/sidecar.py +129 -0
  95. package/skills/sk:setup-optimizer/optimize_claude.py +174 -0
  96. package/skills/sk:setup-optimizer/templates/CLAUDE.md.template +105 -0
  97. package/skills/sk:skill-creator/LICENSE.txt +202 -0
  98. package/skills/sk:skill-creator/SKILL.md +479 -0
  99. package/skills/sk:skill-creator/agents/analyzer.md +274 -0
  100. package/skills/sk:skill-creator/agents/comparator.md +202 -0
  101. package/skills/sk:skill-creator/agents/grader.md +223 -0
  102. package/skills/sk:skill-creator/assets/eval_review.html +146 -0
  103. package/skills/sk:skill-creator/eval-viewer/generate_review.py +471 -0
  104. package/skills/sk:skill-creator/eval-viewer/viewer.html +1325 -0
  105. package/skills/sk:skill-creator/references/schemas.md +430 -0
  106. package/skills/sk:skill-creator/scripts/aggregate_benchmark.py +401 -0
  107. package/skills/sk:skill-creator/scripts/generate_report.py +326 -0
  108. package/skills/sk:skill-creator/scripts/improve_description.py +248 -0
  109. package/skills/sk:skill-creator/scripts/package_skill.py +136 -0
  110. package/skills/sk:skill-creator/scripts/quick_validate.py +103 -0
  111. package/skills/sk:skill-creator/scripts/run_eval.py +310 -0
  112. package/skills/sk:skill-creator/scripts/run_loop.py +332 -0
  113. package/skills/sk:skill-creator/scripts/utils.py +47 -0
  114. package/skills/sk:smart-commit/SKILL.md +175 -0
  115. package/skills/sk:test/SKILL.md +171 -0
  116. package/skills/sk:write-tests/SKILL.md +195 -0
  117. package/skills/sk:write-tests/references/patterns.md +209 -0
package/README.md ADDED
@@ -0,0 +1,321 @@
1
+ # SHIPKIT
2
+
3
+ A structured, quality-gated workflow system for Claude Code.
4
+
5
+ Ship features with TDD, auto-detecting linters, security audits, and AI-powered code review — all wired into a single repeatable workflow.
6
+
7
+ [![npm](https://img.shields.io/npm/v/@kennethsolomon%2Fshipkit)](https://www.npmjs.com/package/@kennethsolomon/shipkit)
8
+ [![license](https://img.shields.io/badge/license-MIT-blue)](LICENSE)
9
+ [![platform](https://img.shields.io/badge/platform-Mac%20%2F%20Linux%20%2F%20Windows-lightgrey)](#)
10
+
11
+ ```
12
+ npx @kennethsolomon/shipkit
13
+ ```
14
+
15
+ Works on Mac, Linux, and Windows.
16
+
17
+ ```
18
+ ~ $ npx @kennethsolomon/shipkit
19
+
20
+
21
+ |
22
+ /|\
23
+ / | \
24
+ / | \
25
+ / | \
26
+ / ☠ | ☠ \
27
+ / | \
28
+ /______|______\
29
+ ▄████████████████▄
30
+ █ ◉ ◉ █
31
+ ▀██████████████▀
32
+ ≋ ≋ ≋ ≋ ≋
33
+
34
+ ShipKit v1.0.0
35
+ A structured workflow toolkit for Claude Code.
36
+ by Kenneth Solomon
37
+
38
+ ✓ Installed commands/sk (15 commands)
39
+ ✓ Installed skills (19 skills)
40
+
41
+ Done! Run /sk:help to get started.
42
+
43
+ ~ $
44
+ ```
45
+
46
+ ---
47
+
48
+ > "Stop winging it. Ship with a system."
49
+
50
+ ---
51
+
52
+ ## How It Works
53
+
54
+ ShipKit installs a set of slash commands and skills into your Claude Code config (`~/.claude/`). Each command is a focused instruction set that Claude follows — no magic, just structured prompts that enforce quality gates.
55
+
56
+ The workflow is linear: **Explore → Design → Plan → Branch → Test → Implement → Lint → Verify → Security → Review → Ship.**
57
+
58
+ Every gate must pass before the next step. If lint fails, you fix it. If tests don't cover new code, you write them. Security issues block the PR. This isn't optional — it's the whole point.
59
+
60
+ ---
61
+
62
+ ## Installation
63
+
64
+ ```bash
65
+ npx @kennethsolomon/shipkit
66
+ ```
67
+
68
+ Or clone and install locally (symlinks — changes reflect immediately):
69
+
70
+ ```bash
71
+ git clone https://github.com/kennethsolomon/shipkit.git
72
+ cd shipkit
73
+ ./install.sh
74
+ ```
75
+
76
+ ### Update
77
+
78
+ ```bash
79
+ npx @kennethsolomon/shipkit
80
+ ```
81
+
82
+ Re-running always installs the latest version.
83
+
84
+ ### Uninstall
85
+
86
+ ```bash
87
+ npx @kennethsolomon/shipkit --uninstall
88
+ ```
89
+
90
+ ---
91
+
92
+ ## Workflow
93
+
94
+ ### Feature Flow
95
+
96
+ ```
97
+ Brainstorm → Plan → Branch → [Schema] → Write Tests → Implement → Commit
98
+ → Lint ✓ → Test ✓ → Security ✓ → Review ✓ → Update Task → Finish
99
+ ```
100
+
101
+ | # | Command | Purpose |
102
+ |---|---------|---------|
103
+ | 1 | read `tasks/todo.md` | Pick the next task |
104
+ | 2 | read `tasks/lessons.md` | Review past corrections |
105
+ | 3 | `/sk:brainstorm` | Clarify requirements — no code |
106
+ | 4 | `/sk:frontend-design` | UI design spec *(skip if backend-only)* |
107
+ | 5 | `/sk:api-design` | API contracts *(skip if no new endpoints)* |
108
+ | 6 | `/sk:accessibility` | WCAG 2.1 AA audit on design *(skip if no frontend)* |
109
+ | 7 | `/sk:write-plan` | Write plan to `tasks/todo.md` |
110
+ | 8 | `/sk:branch` | Create branch from current task |
111
+ | 9 | `/sk:schema-migrate` | Schema change analysis *(skip if no DB changes)* |
112
+ | 10 | `/sk:write-tests` | TDD red: write failing tests first |
113
+ | 11 | `/sk:execute-plan` | TDD green: make tests pass |
114
+ | 12 | `/sk:smart-commit` | Conventional commit |
115
+ | 13 | **`/sk:lint`** | **GATE** — all linters must pass |
116
+ | 14 | `/sk:smart-commit` | Auto-skip if already clean |
117
+ | 15 | **`/sk:test`** | **GATE** — 100% coverage on new code |
118
+ | 16 | `/sk:smart-commit` | Auto-skip if already clean |
119
+ | 17 | **`/sk:security-check`** | **GATE** — 0 issues |
120
+ | 18 | `/sk:smart-commit` | Auto-skip if already clean |
121
+ | 19 | **`/sk:review`** | **GATE** — 0 issues including nitpicks |
122
+ | 20 | `/sk:smart-commit` | Auto-skip if already clean |
123
+ | 21 | `/sk:update-task` | Mark done, log completion |
124
+ | 22 | `/sk:finish-feature` | Changelog + PR |
125
+ | 23 | `/sk:release` | Version bump + tag *(optional)* |
126
+
127
+ ### Bug Fix Flow
128
+
129
+ ```
130
+ Debug → Plan → Branch → Write Tests → Implement → Lint ✓ → Test ✓ → Security ✓ → Review ✓ → Finish
131
+ ```
132
+
133
+ | # | Command | Purpose |
134
+ |---|---------|---------|
135
+ | 1 | `/sk:debug` | Root-cause analysis |
136
+ | 2 | `/sk:write-plan` | Fix plan |
137
+ | 3 | `/sk:branch` | Create branch |
138
+ | 4 | `/sk:write-tests` | Reproduce the bug in a test |
139
+ | 5 | `/sk:execute-plan` | Fix — make the test pass |
140
+ | 6–9 | lint → test → security → review | Quality gates |
141
+ | 10 | `/sk:finish-feature` | Changelog + PR |
142
+
143
+ ### Hotfix Flow
144
+
145
+ For production issues that need to ship immediately. Skips brainstorm, design, and TDD. **Quality gates are non-negotiable even in a hotfix.**
146
+
147
+ ```
148
+ Debug → Branch → Fix → Smoke Test → Lint ✓ → Test ✓ → Security ✓ → Review ✓ → Finish
149
+ ```
150
+
151
+ | # | Command | Purpose |
152
+ |---|---------|---------|
153
+ | 1 | `/sk:debug` | Root-cause analysis — understand before touching code |
154
+ | 2 | `/sk:branch` | Auto-named from the bug description |
155
+ | 3 | implement directly | No write-tests phase — go straight to the fix |
156
+ | 4 | run existing tests | Existing tests MUST still pass |
157
+ | 5 | `/sk:smart-commit` | Commit the fix |
158
+ | 6 | **`/sk:lint`** | **GATE** |
159
+ | 7 | **`/sk:test`** | **GATE** |
160
+ | 8 | **`/sk:security-check`** | **GATE** |
161
+ | 9 | **`/sk:review`** | **GATE** |
162
+ | 10 | `/sk:update-task` | Mark done |
163
+ | 11 | `/sk:finish-feature` | Changelog + PR — mark as hotfix |
164
+
165
+ After merging: add a regression test and a lesson to `tasks/lessons.md`.
166
+
167
+ ---
168
+
169
+ ## Commands
170
+
171
+ ### Planning & Design
172
+
173
+ | Command | Description |
174
+ |---------|-------------|
175
+ | `/sk:brainstorm` | Explore requirements and design before writing any code |
176
+ | `/sk:frontend-design` | Create UI design specs and mockups |
177
+ | `/sk:api-design` | Design REST or GraphQL API contracts |
178
+ | `/sk:accessibility` | WCAG 2.1 AA audit on design or existing frontend |
179
+ | `/sk:write-plan` | Write a decision-complete plan to `tasks/todo.md` |
180
+ | `/sk:plan` | Create or refresh task planning files |
181
+ | `/sk:setup-claude` | Bootstrap project scaffolding (CLAUDE.md + tasks/) |
182
+ | `/sk:setup-optimizer` | Enrich CLAUDE.md by scanning the codebase |
183
+
184
+ ### Development
185
+
186
+ | Command | Description |
187
+ |---------|-------------|
188
+ | `/sk:branch` | Create a feature branch from the current task |
189
+ | `/sk:schema-migrate` | Analyze pending schema changes (Prisma, Drizzle, Eloquent, SQLAlchemy, ActiveRecord) |
190
+ | `/sk:write-tests` | TDD: write failing tests before implementation |
191
+ | `/sk:execute-plan` | Implement the plan in small batches |
192
+ | `/sk:debug` | Structured bug investigation: reproduce → isolate → fix |
193
+ | `/sk:hotfix` | Emergency fix workflow — skips design and TDD |
194
+
195
+ ### Quality Gates
196
+
197
+ | Command | Description |
198
+ |---------|-------------|
199
+ | `/sk:lint` | Auto-detect and run all linters (Pint, ESLint, PHPStan, Prettier…) |
200
+ | `/sk:test` | Auto-detect and run all test suites, verify 100% coverage on new code |
201
+ | `/sk:security-check` | OWASP security audit across changed code |
202
+ | `/sk:perf` | Performance audit: bundle size, N+1 queries, Core Web Vitals |
203
+ | `/sk:review` | Rigorous self-review across 7 dimensions |
204
+
205
+ ### Shipping
206
+
207
+ | Command | Description |
208
+ |---------|-------------|
209
+ | `/sk:smart-commit` | Generate conventional commit messages with approval |
210
+ | `/sk:update-task` | Mark current task done, log completion |
211
+ | `/sk:finish-feature` | Write changelog entry + create PR |
212
+ | `/sk:release` | Version bump + CHANGELOG + git tag + push |
213
+ | `/sk:features` | Sync docs/features/ specs with the codebase |
214
+
215
+ ### Laravel
216
+
217
+ | Command | Description |
218
+ |---------|-------------|
219
+ | `/sk:laravel-new` | Scaffold a fresh Laravel app with production-ready conventions |
220
+ | `/sk:laravel-init` | Configure an existing Laravel project |
221
+
222
+ ### Configuration
223
+
224
+ | Command | Description |
225
+ |---------|-------------|
226
+ | `/sk:config` | View and edit project config (`.shipkit/config.json`) |
227
+ | `/sk:set-profile` | Switch model routing profile for this project |
228
+
229
+ ### Meta
230
+
231
+ | Command | Description |
232
+ |---------|-------------|
233
+ | `/sk:help` | Show all commands and workflow overview |
234
+ | `/sk:status` | Show workflow and task status at a glance |
235
+ | `/sk:skill-creator` | Create or improve ShipKit skills |
236
+
237
+ ---
238
+
239
+ ## Model Routing Profiles
240
+
241
+ ShipKit routes each skill to the right model automatically based on your project profile.
242
+ Set it once with `/sk:set-profile <name>` — config is saved to `.shipkit/config.json`.
243
+
244
+ | Profile | Philosophy | Best for |
245
+ |---------|-----------|---------|
246
+ | `full-sail` | Opus on everything that matters | High-stakes work, client projects |
247
+ | `quality` | Opus for planning + review, Sonnet for implementation | Most professional projects |
248
+ | `balanced` | Sonnet across the board *(default)* | Day-to-day development |
249
+ | `budget` | Haiku where possible, Sonnet for gates | Side projects, prototyping |
250
+
251
+ | Skill group | full-sail | quality | balanced | budget |
252
+ |-------------|-----------|---------|----------|--------|
253
+ | brainstorm, write-plan, debug, execute-plan, review | opus | opus | sonnet | sonnet |
254
+ | write-tests, frontend-design, api-design, security-check | opus | sonnet | sonnet | sonnet |
255
+ | perf, schema-migrate, accessibility | opus | sonnet | sonnet | haiku |
256
+ | lint, test | sonnet | sonnet | haiku | haiku |
257
+ | smart-commit, branch, update-task | haiku | haiku | haiku | haiku |
258
+
259
+ `opus` = inherit (uses your current session model).
260
+
261
+ ### Other config settings
262
+
263
+ ```json
264
+ {
265
+ "profile": "balanced",
266
+ "auto_commit": true,
267
+ "skip_gates": [],
268
+ "coverage_threshold": 100,
269
+ "branch_pattern": "feature/{slug}",
270
+ "model_overrides": { "sk:review": "opus" }
271
+ }
272
+ ```
273
+
274
+ | Setting | Default | Description |
275
+ |---------|---------|-------------|
276
+ | `profile` | `balanced` | Model routing profile |
277
+ | `auto_commit` | `true` | Auto-commit after each gate passes |
278
+ | `skip_gates` | `[]` | Gates to skip — e.g. `["perf","accessibility"]` for backend-only projects |
279
+ | `coverage_threshold` | `100` | Minimum test coverage % on new code |
280
+ | `branch_pattern` | `feature/{slug}` | Branch naming convention |
281
+ | `model_overrides` | `{}` | Per-skill model overrides that take precedence over profile |
282
+
283
+ ---
284
+
285
+ ## Stack Support
286
+
287
+ ShipKit auto-detects your stack — no configuration needed.
288
+
289
+ | Area | Supported |
290
+ |------|-----------|
291
+ | **Linters** | Pint, ESLint, PHPStan, Rector, Prettier, Biome, Stylelint |
292
+ | **Test runners** | Pest, PHPUnit, Jest, Vitest, Playwright |
293
+ | **Schema / ORM** | Prisma, Drizzle, Eloquent, SQLAlchemy + Alembic, ActiveRecord |
294
+ | **Frameworks** | Laravel, Next.js, Nuxt, React, Vue, Node.js |
295
+ | **Release** | npm, Composer, iOS (App Store), Android (Play Store) |
296
+
297
+ ---
298
+
299
+ ## Project Setup
300
+
301
+ To wire ShipKit into a new project:
302
+
303
+ ```
304
+ /sk:setup-claude
305
+ ```
306
+
307
+ This creates `tasks/todo.md`, `tasks/lessons.md`, and a project-specific `CLAUDE.md` with the full workflow baked in.
308
+
309
+ ---
310
+
311
+ ## Why ShipKit
312
+
313
+ Claude Code is powerful but context degrades as the window fills. Unstructured sessions lead to skipped tests, no lint, missing security review, and PRs that broke things in ways nobody caught.
314
+
315
+ ShipKit fixes that with a repeatable system: every feature goes through the same gates in the same order. Quality isn't optional — it's structural.
316
+
317
+ ---
318
+
319
+ ## License
320
+
321
+ MIT — by [Kenneth Solomon](https://github.com/kennethsolomon)
package/bin/shipkit.js ADDED
@@ -0,0 +1,146 @@
1
+ #!/usr/bin/env node
2
+ 'use strict';
3
+
4
+ const fs = require('fs');
5
+ const path = require('path');
6
+ const os = require('os');
7
+
8
+ const pkg = require('../package.json');
9
+
10
+ // ── ANSI ────────────────────────────────────────────────────────────────────
11
+ const cyan = '\x1b[36m';
12
+ const green = '\x1b[32m';
13
+ const yellow = '\x1b[33m';
14
+ const bold = '\x1b[1m';
15
+ const dim = '\x1b[2m';
16
+ const reset = '\x1b[0m';
17
+
18
+ // ── Pirate ship ASCII art ────────────────────────────────────────────────────
19
+ const banner = `
20
+ ${cyan} ⚑${reset}
21
+ ${cyan} |${reset}
22
+ ${cyan} /|\\${reset}
23
+ ${cyan} / | \\${reset}
24
+ ${cyan} / | \\${reset}
25
+ ${cyan} / | \\${reset}
26
+ ${cyan} / ☠ | ☠ \\${reset}
27
+ ${cyan} / | \\${reset}
28
+ ${cyan} /______|______\\${reset}
29
+ ${cyan} ▄████████████████▄${reset}
30
+ ${cyan} █ ◉ ◉ █${reset}
31
+ ${cyan} ▀██████████████▀${reset}
32
+ ${cyan} ≋ ≋ ≋ ≋ ≋${reset}
33
+
34
+ ${bold}ShipKit${reset} ${dim}v${pkg.version}${reset}
35
+ A structured workflow toolkit for Claude Code.
36
+ by Kenneth Solomon
37
+
38
+ `;
39
+
40
+ // ── Helpers ──────────────────────────────────────────────────────────────────
41
+ function getClaudeDir() {
42
+ if (process.platform === 'win32') {
43
+ return path.join(process.env.APPDATA || os.homedir(), 'Claude');
44
+ }
45
+ return path.join(os.homedir(), '.claude');
46
+ }
47
+
48
+ function copyDir(src, dest) {
49
+ fs.mkdirSync(dest, { recursive: true });
50
+ for (const entry of fs.readdirSync(src, { withFileTypes: true })) {
51
+ const srcPath = path.join(src, entry.name);
52
+ const destPath = path.join(dest, entry.name);
53
+ if (entry.isDirectory()) {
54
+ copyDir(srcPath, destPath);
55
+ } else {
56
+ fs.copyFileSync(srcPath, destPath);
57
+ }
58
+ }
59
+ }
60
+
61
+ function countFiles(dir, ext) {
62
+ if (!fs.existsSync(dir)) return 0;
63
+ return fs.readdirSync(dir).filter(f => f.endsWith(ext)).length;
64
+ }
65
+
66
+ // ── Uninstall ────────────────────────────────────────────────────────────────
67
+ function uninstall() {
68
+ process.stdout.write(banner);
69
+ const claudeDir = getClaudeDir();
70
+ const commandsDest = path.join(claudeDir, 'commands', 'sk');
71
+ const skillsDest = path.join(claudeDir, 'skills');
72
+
73
+ if (fs.existsSync(commandsDest)) {
74
+ fs.rmSync(commandsDest, { recursive: true, force: true });
75
+ console.log(` ${green}✓${reset} Removed commands/sk`);
76
+ }
77
+
78
+ // Remove only sk: prefixed skill dirs
79
+ if (fs.existsSync(skillsDest)) {
80
+ const removed = fs.readdirSync(skillsDest, { withFileTypes: true })
81
+ .filter(e => e.isDirectory() && e.name.startsWith('sk:'))
82
+ .map(e => {
83
+ fs.rmSync(path.join(skillsDest, e.name), { recursive: true, force: true });
84
+ return e.name;
85
+ });
86
+ console.log(` ${green}✓${reset} Removed ${removed.length} skills`);
87
+ }
88
+
89
+ console.log(`\n ${green}Done!${reset} ShipKit uninstalled.\n`);
90
+ }
91
+
92
+ // ── Install ──────────────────────────────────────────────────────────────────
93
+ function install() {
94
+ process.stdout.write(banner);
95
+
96
+ const claudeDir = getClaudeDir();
97
+ const pkgDir = path.join(__dirname, '..');
98
+
99
+ // Check Claude dir exists
100
+ if (!fs.existsSync(claudeDir)) {
101
+ fs.mkdirSync(claudeDir, { recursive: true });
102
+ }
103
+
104
+ // Install commands/sk/
105
+ const commandsSrc = path.join(pkgDir, 'commands', 'sk');
106
+ const commandsDest = path.join(claudeDir, 'commands', 'sk');
107
+
108
+ if (fs.existsSync(commandsSrc)) {
109
+ copyDir(commandsSrc, commandsDest);
110
+ const count = countFiles(commandsSrc, '.md');
111
+ console.log(` ${green}✓${reset} Installed commands/sk ${dim}(${count} commands)${reset}`);
112
+ } else {
113
+ console.log(` ${yellow}!${reset} commands/sk not found — skipping`);
114
+ }
115
+
116
+ // Install skills/sk:*/
117
+ const skillsSrc = path.join(pkgDir, 'skills');
118
+ const skillsDest = path.join(claudeDir, 'skills');
119
+ let skillCount = 0;
120
+
121
+ if (fs.existsSync(skillsSrc)) {
122
+ const skillDirs = fs.readdirSync(skillsSrc, { withFileTypes: true })
123
+ .filter(e => e.isDirectory());
124
+
125
+ for (const entry of skillDirs) {
126
+ const src = path.join(skillsSrc, entry.name);
127
+ const dest = path.join(skillsDest, entry.name);
128
+ copyDir(src, dest);
129
+ skillCount++;
130
+ }
131
+ console.log(` ${green}✓${reset} Installed skills ${dim}(${skillCount} skills)${reset}`);
132
+ } else {
133
+ console.log(` ${yellow}!${reset} skills/ not found — skipping`);
134
+ }
135
+
136
+ console.log(`\n ${green}Done!${reset} Run ${cyan}/sk:help${reset} to get started.\n`);
137
+ }
138
+
139
+ // ── Entry point ──────────────────────────────────────────────────────────────
140
+ const args = process.argv.slice(2);
141
+
142
+ if (args.includes('--uninstall') || args.includes('-u')) {
143
+ uninstall();
144
+ } else {
145
+ install();
146
+ }
@@ -0,0 +1,63 @@
1
+ ---
2
+ description: "Start with design questions before writing code."
3
+ ---
4
+
5
+ <!-- Generated by /sk:setup-claude -->
6
+
7
+ # /sk:brainstorm
8
+
9
+ Explore design and clarify requirements **before** any code is written.
10
+
11
+ ## Hard Rules
12
+
13
+ - **DO NOT write, edit, or generate any code.** No files, no snippets, no pseudo-implementations.
14
+ - **DO NOT create a plan.** That is `/sk:write-plan`'s job.
15
+ - **DO NOT run build/sk:test/sk:lint commands.** You are in design mode only.
16
+ - You may **read** existing code to understand the current state, but nothing more.
17
+
18
+ ## Steps
19
+
20
+ 1. **Read context files first:**
21
+ - If `tasks/findings.md` exists and has content, read **only sections relevant to the
22
+ current phase/task** — skip decisions from completed or unrelated phases. Summarize
23
+ prior decisions and ask: extend, revise, or start fresh?
24
+ - If `tasks/lessons.md` exists, read it in full. Apply every active lesson as a design
25
+ constraint throughout this brainstorm — treat each prevention rule as a hard constraint
26
+ when proposing approaches.
27
+ - If `tasks/security-findings.md` exists and has audit results, skim for recurring
28
+ patterns — factor security constraints into proposed approaches (e.g., if prior audits
29
+ flagged missing input validation, ensure new designs account for it).
30
+
31
+ 2. **Understand the request** — Ask clarifying questions about what the user wants. Do not assume. Cover:
32
+ - What problem are we solving?
33
+ - Who is it for?
34
+ - What are the expected inputs/outputs or behaviors?
35
+ - Are there constraints (performance, compatibility, existing patterns)?
36
+
37
+ 3. **Parallel codebase research** — Launch 3 Explore agents **in parallel** (read-only) before proposing approaches:
38
+ - **Agent 1 — Affected areas:** Explore models, services, controllers, and files directly related to the task. Map the relevant code surface.
39
+ - **Agent 2 — Existing patterns:** Explore how similar features were built in this project. Identify conventions, shared abstractions, and naming patterns to follow.
40
+ - **Agent 3 — Tests & edge cases:** Explore existing test coverage for the affected area. Identify gaps, edge cases, and validation patterns already in use.
41
+
42
+ Wait for all three agents to return, then synthesize their findings into a brief summary before moving to step 4.
43
+
44
+ 4. **Propose approaches** — Present 2–3 design options with trade-offs:
45
+ - Approach name + 1-sentence summary
46
+ - Pros and cons
47
+ - Complexity estimate (small / medium / large)
48
+ - Which existing patterns it follows or breaks
49
+
50
+ 5. **Get alignment** — Ask the user which approach they prefer (or if they want a hybrid). Do not proceed without explicit approval on the direction.
51
+
52
+ 6. **Record findings** — Write discoveries and the agreed-upon direction to `tasks/findings.md`:
53
+ - Problem statement
54
+ - Key decisions made
55
+ - Chosen approach + rationale
56
+ - Open questions (if any remain)
57
+
58
+ ## When Done
59
+
60
+ Tell the user:
61
+ > "Brainstorming complete. Findings saved to `tasks/findings.md`. Run `/sk:write-plan` to create the implementation plan."
62
+
63
+ **Do not proceed to planning or implementation yourself.** The user must explicitly invoke the next step.
@@ -0,0 +1,35 @@
1
+ ---
2
+ description: "Create a feature branch from the current task in tasks/todo.md."
3
+ ---
4
+
5
+ # /sk:branch
6
+
7
+ Create a feature branch for the current task.
8
+
9
+ ## Steps
10
+
11
+ ### 1. Read Current Task
12
+ - Read `tasks/todo.md` and find the next incomplete task (first unchecked checkbox)
13
+ - Extract a short name from the task description
14
+
15
+ ### 2. Check Prerequisites
16
+ - Ensure working directory is clean (`git status`). If dirty, warn the user and stop.
17
+ - Ensure you're on the main branch. If not, ask the user to confirm branching from the current branch.
18
+
19
+ ### 3. Pull Latest
20
+ ```bash
21
+ git pull origin main
22
+ ```
23
+
24
+ ### 4. Create Branch
25
+ - Generate branch name: `feature/<short-task-name>` (kebab-case, max 50 chars)
26
+ - Example task: "Add server metrics dashboard" → `feature/server-metrics-dashboard`
27
+ - Example task: "Fix duplicate episode notifications" → `fix/duplicate-episode-notifications`
28
+ - Use `fix/` prefix for bug fixes, `feature/` for new features, `refactor/` for refactoring
29
+ ```bash
30
+ git checkout -b <branch-name>
31
+ ```
32
+
33
+ ### 5. Confirm
34
+ - Show the user the branch name created
35
+ - Show which task this branch is for
@@ -0,0 +1,96 @@
1
+ ---
2
+ description: "View and edit ShipKit project configuration (.shipkit/sk:config.json)."
3
+ ---
4
+
5
+ # /sk:config
6
+
7
+ View and manage ShipKit configuration for this project.
8
+
9
+ ## Config File
10
+
11
+ ShipKit stores per-project config in `.shipkit/sk:config.json` at the project root.
12
+ If the file does not exist, display defaults and offer to create it.
13
+
14
+ ## Steps
15
+
16
+ ### 1 — Read current config
17
+
18
+ Check if `.shipkit/sk:config.json` exists. If yes, read and parse it.
19
+ If not, use defaults:
20
+
21
+ ```json
22
+ {
23
+ "profile": "balanced",
24
+ "auto_commit": true,
25
+ "skip_gates": [],
26
+ "coverage_threshold": 100,
27
+ "branch_pattern": "feature/{slug}",
28
+ "model_overrides": {}
29
+ }
30
+ ```
31
+
32
+ ### 2 — Display current config
33
+
34
+ Show a formatted table explaining every setting and its current value:
35
+
36
+ | Setting | Value | Description |
37
+ |---------|-------|-------------|
38
+ | `profile` | `<value>` | Model routing profile (full-sail / quality / balanced / budget) |
39
+ | `auto_commit` | `<value>` | Auto-run `/sk:smart-commit` after each gate passes |
40
+ | `skip_gates` | `<value>` | Gates to skip (e.g. `["perf","accessibility"]` for backend-only projects) |
41
+ | `coverage_threshold` | `<value>` | Minimum test coverage % on new code (default: 100) |
42
+ | `branch_pattern` | `<value>` | Branch naming pattern (`feature/{slug}`, `feat/{slug}`, etc.) |
43
+ | `model_overrides` | `<value>` | Per-skill model overrides e.g. `{ "sk:review": "opus" }` |
44
+
45
+ Then show the model table for the **current profile**:
46
+
47
+ #### Model assignments — `<profile>` profile
48
+
49
+ | Skill | Model |
50
+ |-------|-------|
51
+ | brainstorm, write-plan, debug, execute-plan, review | `<model>` |
52
+ | write-tests, frontend-design, api-design, security-check | `<model>` |
53
+ | perf, schema-migrate, accessibility | `<model>` |
54
+ | lint, test | `<model>` |
55
+ | smart-commit, branch, update-task | `haiku` |
56
+
57
+ Use this model table to fill in values:
58
+
59
+ | Skill | full-sail | quality | balanced | budget |
60
+ |-------|-----------|---------|----------|--------|
61
+ | brainstorm, write-plan, debug, execute-plan, review | opus | opus | sonnet | sonnet |
62
+ | write-tests, frontend-design, api-design, security-check | opus | sonnet | sonnet | sonnet |
63
+ | perf, schema-migrate, accessibility | opus | sonnet | sonnet | haiku |
64
+ | lint, test | sonnet | sonnet | haiku | haiku |
65
+ | smart-commit, branch, update-task | haiku | haiku | haiku | haiku |
66
+
67
+ Note: `opus` resolves to `inherit` — Claude uses whatever model the current session is running on.
68
+
69
+ ### 3 — Offer to edit
70
+
71
+ Ask: "Which setting would you like to change? (or press Enter to exit)"
72
+
73
+ If the user specifies a setting:
74
+
75
+ - `profile` → show `/sk:set-profile` options and apply
76
+ - `auto_commit` → toggle true/false
77
+ - `skip_gates` → show available gates (`lint`, `test`, `security-check`, `perf`, `accessibility`, `review`) and let user pick
78
+ - `coverage_threshold` → accept a number 0-100
79
+ - `branch_pattern` → accept a pattern string (show examples: `feature/{slug}`, `feat/{slug}`, `{slug}`)
80
+ - `model_overrides` → accept JSON or guided per-skill input
81
+
82
+ ### 4 — Write config
83
+
84
+ If any setting was changed:
85
+ 1. Create `.shipkit/` directory if it does not exist
86
+ 2. Write updated config to `.shipkit/sk:config.json`
87
+ 3. Add `.shipkit/sk:config.json` to `.gitignore` if not already present
88
+ 4. Confirm: "Config saved to `.shipkit/sk:config.json`"
89
+
90
+ If no changes, exit cleanly.
91
+
92
+ ## Notes
93
+
94
+ - Config is **per-project** — each repo has its own `.shipkit/sk:config.json`
95
+ - `model_overrides` takes precedence over `profile` for individual skills
96
+ - Gitignore: `.shipkit/sk:config.json` is personal preference — don't commit it unless the team agrees on a shared profile