@jeiemgi/cckit 0.9.0 → 0.10.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 (305) hide show
  1. package/.claude-plugin/plugin.json +1 -1
  2. package/AGENTS.md +169 -21
  3. package/README.md +491 -35
  4. package/SECURITY.md +5 -0
  5. package/bin/cckit +182 -17
  6. package/cckit.config.json +1 -1
  7. package/commands/kit-doctor.md +13 -5
  8. package/commands/kit-export-project.md +0 -2
  9. package/commands/kit-export-training.md +6 -9
  10. package/commands/kit-init.md +43 -13
  11. package/commands/kit-routines.md +1 -1
  12. package/commands/kit-update.md +11 -6
  13. package/databases/supabase/guide.html +106 -0
  14. package/databases/supabase/nextjs/lib/supabase/client.ts +9 -0
  15. package/databases/supabase/nextjs/lib/supabase/server.ts +29 -0
  16. package/databases/supabase.json +70 -0
  17. package/integrations/emil-design-eng.json +41 -0
  18. package/integrations/graft.json +81 -0
  19. package/integrations/impeccable.json +42 -0
  20. package/integrations/integration.schema.json +215 -0
  21. package/integrations/lavish.json +43 -0
  22. package/integrations/mempalace.json +28 -0
  23. package/integrations/mlx-lm.json +32 -0
  24. package/integrations/web-design-guidelines.json +42 -0
  25. package/kit.config.schema.json +183 -5
  26. package/package.json +4 -1
  27. package/profiles/automation.json +7 -1
  28. package/profiles/content.json +10 -2
  29. package/profiles/marketing.json +57 -0
  30. package/profiles/minimal.json +7 -1
  31. package/profiles/research.json +7 -1
  32. package/profiles/software.json +7 -1
  33. package/recipes/nextjs-shadcn.json +49 -0
  34. package/scripts/agent-skills-external.txt +45 -0
  35. package/scripts/agent-skills-lint-test.sh +131 -0
  36. package/scripts/agent-skills-lint.sh +115 -0
  37. package/scripts/agent-template-lint-test.sh +42 -0
  38. package/scripts/agent-template-lint.sh +58 -0
  39. package/scripts/annotate-setup.sh +1 -1
  40. package/scripts/autopilot-run-test.sh +338 -0
  41. package/scripts/autopilot-run.sh +448 -0
  42. package/scripts/autopilot-test.sh +8 -0
  43. package/scripts/autopilot.sh +10 -1
  44. package/scripts/benchmark/benchmark-test.sh +85 -0
  45. package/scripts/benchmark/checkpoint-test.sh +314 -0
  46. package/scripts/benchmark/checkpoint.sh +408 -0
  47. package/scripts/benchmark/lib/model.sh +31 -6
  48. package/scripts/benchmark/report.sh +17 -2
  49. package/scripts/benchmark/run-quality.sh +36 -10
  50. package/scripts/benchmark/verb-timings-test.sh +124 -0
  51. package/scripts/benchmark/verb-timings.sh +149 -0
  52. package/scripts/check.sh +29 -19
  53. package/scripts/content-skills-test.sh +144 -0
  54. package/scripts/copilot-loop-test.sh +25 -0
  55. package/scripts/database-supabase-test.sh +121 -0
  56. package/scripts/docs-marketing-words-test.sh +73 -0
  57. package/scripts/docs-record-tables-test.sh +72 -0
  58. package/scripts/hook-adapter-test.sh +193 -0
  59. package/scripts/init-content-test.sh +225 -0
  60. package/scripts/init-guided-test.sh +474 -0
  61. package/scripts/init-recipes-test.sh +104 -0
  62. package/scripts/init-upgrade-test.sh +341 -2
  63. package/scripts/init.sh +746 -95
  64. package/scripts/instruction-budget-baseline.txt +8 -0
  65. package/scripts/instruction-budget-lint-test.sh +166 -0
  66. package/scripts/instruction-budget-lint.sh +219 -0
  67. package/scripts/integrations-check-test.sh +200 -0
  68. package/scripts/integrations-check.sh +157 -0
  69. package/scripts/kit-add-test.sh +214 -0
  70. package/scripts/kit-add.sh +305 -5
  71. package/scripts/kit-adopt-test.sh +16 -0
  72. package/scripts/kit-adopt.sh +3 -2
  73. package/scripts/kit-digest.sh +2 -2
  74. package/scripts/kit-doctor-test.sh +293 -0
  75. package/scripts/kit-doctor.sh +272 -140
  76. package/scripts/kit-export-project-test.sh +3 -3
  77. package/scripts/kit-remove-test.sh +19 -0
  78. package/scripts/kit-routines.sh +2 -2
  79. package/scripts/kit-self-update.sh +1 -1
  80. package/scripts/kit-version-check-test.sh +4 -0
  81. package/scripts/kit-version-check.sh +4 -2
  82. package/scripts/knowledge-lint.sh +4 -4
  83. package/scripts/leak-fence-test.sh +89 -0
  84. package/scripts/lib/adapter-select-test.sh +136 -0
  85. package/scripts/lib/adapter-select.sh +158 -0
  86. package/scripts/lib/agent-def-test.sh +69 -0
  87. package/scripts/lib/agent-def.sh +106 -0
  88. package/scripts/lib/agent-launch-test.sh +212 -0
  89. package/scripts/lib/agent-launch.sh +335 -0
  90. package/scripts/lib/board-view-test.sh +11 -0
  91. package/scripts/lib/board-view.sh +42 -26
  92. package/scripts/lib/branch-owner-test.sh +26 -0
  93. package/scripts/lib/branch-owner.sh +16 -9
  94. package/scripts/lib/captain-test.sh +105 -0
  95. package/scripts/lib/captain.sh +87 -8
  96. package/scripts/lib/codex-hooks-test.sh +100 -0
  97. package/scripts/lib/codex-hooks.sh +69 -0
  98. package/scripts/lib/commitlint.sh +1 -1
  99. package/scripts/lib/content-kinds-gc-test.sh +88 -0
  100. package/scripts/lib/copilot-test.sh +70 -4
  101. package/scripts/lib/copilot.sh +66 -14
  102. package/scripts/lib/effort-dispatch-test.sh +3 -3
  103. package/scripts/lib/effort-metrics-test.sh +178 -1
  104. package/scripts/lib/effort-metrics.sh +175 -35
  105. package/scripts/lib/effort-ops-test.sh +205 -7
  106. package/scripts/lib/effort-ops.sh +198 -43
  107. package/scripts/lib/effort-parity-test.sh +49 -13
  108. package/scripts/lib/effort-plan-test.sh +337 -0
  109. package/scripts/lib/effort-plan.sh +200 -23
  110. package/scripts/lib/effort.sh +56 -11
  111. package/scripts/lib/errors-header-test.sh +1 -1
  112. package/scripts/lib/gh-project-test.sh +35 -1
  113. package/scripts/lib/gh-project.sh +23 -16
  114. package/scripts/lib/gh-rest-test.sh +32 -3
  115. package/scripts/lib/gh-rest.sh +17 -2
  116. package/scripts/lib/hook-refresh.sh +1 -1
  117. package/scripts/lib/init-github.sh +412 -0
  118. package/scripts/lib/init-guide.sh +630 -0
  119. package/scripts/lib/integration-install-test.sh +343 -0
  120. package/scripts/lib/integration-install.sh +257 -0
  121. package/scripts/lib/integrations-test.sh +366 -0
  122. package/scripts/lib/integrations.sh +244 -0
  123. package/scripts/lib/kinds-test.sh +125 -0
  124. package/scripts/lib/kinds.sh +66 -0
  125. package/scripts/lib/kit-brief-test.sh +22 -3
  126. package/scripts/lib/kit-brief.sh +45 -5
  127. package/scripts/lib/kit-config-resolve.sh +2 -2
  128. package/scripts/lib/kit-config-test.sh +64 -1
  129. package/scripts/lib/kit-config.sh +37 -1
  130. package/scripts/lib/kit-events.sh +7 -0
  131. package/scripts/lib/kit-gc-test.sh +173 -1
  132. package/scripts/lib/kit-gc.sh +226 -37
  133. package/scripts/lib/kit-hotfix.sh +216 -0
  134. package/scripts/lib/kit-interview-test.sh +93 -0
  135. package/scripts/lib/kit-interview.sh +117 -8
  136. package/scripts/lib/kit-lib-test.sh +1 -1
  137. package/scripts/lib/kit-lib.sh +3 -3
  138. package/scripts/lib/kit-local.sh +2 -2
  139. package/scripts/lib/kit-manifest.sh +33 -1
  140. package/scripts/lib/kit-profile-test.sh +3 -3
  141. package/scripts/lib/kit-status-test.sh +112 -4
  142. package/scripts/lib/kit-status.sh +246 -16
  143. package/scripts/lib/kit-task-ops-test.sh +37 -0
  144. package/scripts/lib/kit-task-ops.sh +175 -31
  145. package/scripts/lib/kto-hotfix-test.sh +232 -0
  146. package/scripts/lib/kto-task-close-test.sh +1 -1
  147. package/scripts/lib/kto-task-new-test.sh +95 -0
  148. package/scripts/lib/kto-task-pr-merge-test.sh +37 -3
  149. package/scripts/lib/kto-task-pr-test.sh +70 -0
  150. package/scripts/lib/leak-fence.sh +89 -0
  151. package/scripts/lib/light-task-run-test.sh +255 -0
  152. package/scripts/lib/light-task-test.sh +309 -0
  153. package/scripts/lib/light-task.sh +706 -0
  154. package/scripts/lib/next-test.sh +99 -0
  155. package/scripts/lib/next.sh +9 -3
  156. package/scripts/lib/orchestration-runtime-test.sh +72 -0
  157. package/scripts/lib/orchestration-runtime.sh +57 -5
  158. package/scripts/lib/plan-machine-test.sh +15 -2
  159. package/scripts/lib/plan-machine.sh +20 -7
  160. package/scripts/lib/plan-next-test.sh +1 -1
  161. package/scripts/lib/plan-next.sh +4 -4
  162. package/scripts/lib/pr-evidence-test.sh +3 -3
  163. package/scripts/lib/pr-evidence.sh +1 -1
  164. package/scripts/lib/qa-lane-test.sh +626 -0
  165. package/scripts/lib/qa-lane.sh +1357 -0
  166. package/scripts/lib/qa-lanes-test.sh +175 -0
  167. package/scripts/lib/react-detect.sh +1 -1
  168. package/scripts/lib/render-test.sh +1 -1
  169. package/scripts/lib/review-page-test.sh +318 -0
  170. package/scripts/lib/review-page.sh +369 -0
  171. package/scripts/lib/review-stage-test.sh +62 -11
  172. package/scripts/lib/review-stage.sh +42 -60
  173. package/scripts/lib/role-identity-test.sh +65 -0
  174. package/scripts/lib/role-identity.sh +25 -2
  175. package/scripts/lib/secret-guard.sh +3 -3
  176. package/scripts/lib/session-registry-test.sh +111 -0
  177. package/scripts/lib/session-registry.sh +233 -0
  178. package/scripts/lib/stage-receipt-test.sh +14 -1
  179. package/scripts/lib/stage-receipt.sh +13 -8
  180. package/scripts/lib/task-source-file.sh +309 -0
  181. package/scripts/lib/task-source.sh +130 -0
  182. package/scripts/lib/upgrade-report-test.sh +120 -0
  183. package/scripts/lib/upgrade-report.sh +138 -0
  184. package/scripts/lib/version-bump.sh +3 -3
  185. package/scripts/lib/wave-result-test.sh +80 -0
  186. package/scripts/lib/wave-result.sh +127 -0
  187. package/scripts/lib/worker-brief-test.sh +5 -0
  188. package/scripts/lib/worker-brief.sh +2 -2
  189. package/scripts/lib/worktree-issue-test.sh +30 -1
  190. package/scripts/lib/worktree-issue.sh +82 -12
  191. package/scripts/lib/worktree-ports-test.sh +57 -4
  192. package/scripts/lib/worktree-start-test.sh +197 -0
  193. package/scripts/lib/worktree-start.sh +153 -31
  194. package/scripts/lib/zsh-safety-test.sh +19 -3
  195. package/scripts/marketing-walkthrough-test.sh +152 -0
  196. package/scripts/night-grant-test.sh +37 -0
  197. package/scripts/night-grant.sh +448 -0
  198. package/scripts/night-run-test.sh +8 -0
  199. package/scripts/night-run.mjs +275 -0
  200. package/scripts/night-run.test.mjs +324 -0
  201. package/scripts/orchestrate-test.sh +190 -0
  202. package/scripts/orchestrate.sh +79 -8
  203. package/scripts/portable-test.sh +11 -2
  204. package/scripts/publish.sh +28 -3
  205. package/scripts/review-lint-test.sh +7 -7
  206. package/scripts/review-lint.sh +2 -2
  207. package/scripts/review-rules.conf +8 -0
  208. package/scripts/rule-recipes-test.sh +96 -0
  209. package/scripts/self-install-test.sh +39 -9
  210. package/scripts/setup-labels.sh +18 -1
  211. package/scripts/setup-milestones.sh +1 -1
  212. package/scripts/showcase.sh +1 -1
  213. package/scripts/skill-frontmatter-lint-test.sh +4 -4
  214. package/scripts/skill-frontmatter-lint.sh +1 -1
  215. package/scripts/status-test.sh +113 -2
  216. package/scripts/status.sh +16 -3
  217. package/scripts/task-sync-test.sh +154 -0
  218. package/scripts/task-sync.sh +243 -32
  219. package/scripts/test-runner-test.sh +158 -0
  220. package/scripts/test.sh +131 -23
  221. package/scripts/update-path-test.sh +279 -0
  222. package/scripts/ux-ds-audit.sh +1 -1
  223. package/scripts/ux-graph-scan.sh +6 -6
  224. package/scripts/wave-worker.sh +54 -0
  225. package/skills/kit-add/SKILL.md +77 -0
  226. package/skills/kit-autopilot/SKILL.md +123 -12
  227. package/skills/kit-cleanup/SKILL.md +5 -2
  228. package/skills/kit-contribute/SKILL.md +4 -4
  229. package/skills/kit-docs-writer/SKILL.md +16 -6
  230. package/skills/kit-effort-close/SKILL.md +17 -8
  231. package/skills/kit-effort-new/SKILL.md +15 -9
  232. package/skills/kit-effort-pr/SKILL.md +15 -7
  233. package/skills/kit-effort-start/SKILL.md +5 -2
  234. package/skills/kit-gc/SKILL.md +5 -2
  235. package/skills/kit-next/SKILL.md +5 -1
  236. package/skills/kit-onboard/SKILL.md +3 -3
  237. package/skills/kit-page/SKILL.md +93 -0
  238. package/skills/kit-plan-next/SKILL.md +8 -4
  239. package/skills/kit-security-sweep/SKILL.md +1 -3
  240. package/skills/kit-ship/SKILL.md +2 -3
  241. package/skills/kit-status/SKILL.md +35 -4
  242. package/skills/kit-task-new/SKILL.md +3 -3
  243. package/skills/kit-task-pr/SKILL.md +7 -2
  244. package/skills/kit-task-pr-merge/SKILL.md +7 -2
  245. package/skills/kit-task-start/SKILL.md +7 -7
  246. package/skills/kit-task-sync/SKILL.md +19 -3
  247. package/skills/kit-ux-audit/SKILL.md +3 -2
  248. package/templates/agents/auto-dev.md +5 -4
  249. package/templates/agents/backend.md +1 -1
  250. package/templates/agents/designer.md +2 -0
  251. package/templates/agents/devops.md +1 -1
  252. package/templates/agents/editor.md +9 -1
  253. package/templates/agents/frontend.md +1 -1
  254. package/templates/agents/local-delegate.md +1 -1
  255. package/templates/agents/pm.md +5 -5
  256. package/templates/agents/tech-lead.md +1 -1
  257. package/templates/benchmarks/SCHEMA.md +9 -3
  258. package/templates/codex/hooks.json.tmpl +89 -0
  259. package/templates/hooks/guard-base-branch-commit.sh.tmpl +13 -7
  260. package/templates/hooks/guard-raw-git-ops.sh.tmpl +12 -12
  261. package/templates/hooks/mempal_followup.sh.tmpl +2 -2
  262. package/templates/hooks/mempal_session_start.sh.tmpl +1 -1
  263. package/templates/hooks/prepush_gate.sh.tmpl +4 -2
  264. package/templates/hooks/repo-hygiene.sh.tmpl +3 -2
  265. package/templates/instructions.md.tmpl +174 -0
  266. package/templates/kit.config.json.tmpl +3 -3
  267. package/templates/knowledge-INDEX.md.tmpl +1 -1
  268. package/templates/lib/kit-sigil.sh.tmpl +1 -1
  269. package/templates/rules/authoring.md +106 -0
  270. package/templates/rules/branch-naming.md +40 -4
  271. package/templates/rules/code-retrieval.md +63 -0
  272. package/templates/rules/delegation-brief.md +0 -3
  273. package/templates/rules/design-routing.md +3 -3
  274. package/templates/rules/effort-model.md +14 -10
  275. package/templates/rules/gate-and-review.md +94 -0
  276. package/templates/rules/issue-lifecycle.md +88 -0
  277. package/templates/rules/knowledge-base.md +1 -1
  278. package/templates/rules/mempalace.md +1 -1
  279. package/templates/rules/merge-safety.md +108 -0
  280. package/templates/rules/naming-and-ids.md +23 -17
  281. package/templates/rules/plain-language.md +59 -0
  282. package/templates/rules/plan-next.md +9 -11
  283. package/templates/rules/react-annotate.md +6 -0
  284. package/templates/rules/review-pages.md +49 -0
  285. package/templates/rules/risk-tiered-review.md +13 -4
  286. package/templates/rules/shared-checkout.md +106 -0
  287. package/templates/rules/skill-gaps.md +2 -7
  288. package/templates/rules/task-management.md +13 -1
  289. package/templates/skills/brand-voice/SKILL.md +91 -0
  290. package/templates/skills/brand-voice/references/voice-template.md +61 -0
  291. package/templates/skills/campaign/SKILL.md +123 -0
  292. package/templates/skills/campaign/references/plan-template.md +55 -0
  293. package/templates/skills/concrete/SKILL.md +2 -2
  294. package/templates/skills/copywriting/SKILL.md +8 -1
  295. package/templates/skills/feature-build-refine/SKILL.md +2 -4
  296. package/templates/skills/morning-briefing/SKILL.md +2 -2
  297. package/templates/skills/page-design/SKILL.md +145 -0
  298. package/templates/skills/page-design/add.json +5 -0
  299. package/templates/skills/page-design/references/design-file-template.md +40 -0
  300. package/templates/skills/page-design/references/generic-page-patterns.md +43 -0
  301. package/templates/skills/page-design/references/minimum-rules.md +42 -0
  302. package/templates/skills/speckit/SKILL.md +4 -5
  303. package/templates/skills/supabase-patterns/SKILL.md +1 -1
  304. package/commands/kit-add.md +0 -42
  305. package/templates/CLAUDE.md.tmpl +0 -106
package/README.md CHANGED
@@ -12,7 +12,7 @@
12
12
  [![Docs](https://img.shields.io/badge/docs-cckit.dev-0A7E8C.svg)](https://cckit.dev)
13
13
  [![Platforms: macOS · Linux · WSL](https://img.shields.io/badge/platforms-macOS%20%C2%B7%20Linux%20%C2%B7%20WSL-555.svg)](#platforms--requirements)
14
14
 
15
- **[📖 Documentation](https://cckit.dev)** · [The idea](https://cckit.dev/philosophy/) · [Tutorials](https://cckit.dev/tutorials/) · [Quick start](#quick-start) · [Contributing](CONTRIBUTING.md) · [Code of Conduct](CODE_OF_CONDUCT.md)
15
+ **[📖 Documentation](https://cckit.dev)** · [The idea](https://cckit.dev/philosophy/) · [Guides](https://cckit.dev/software/) · [Quick start](#quick-start) · [Contributing](CONTRIBUTING.md) · [Code of Conduct](CODE_OF_CONDUCT.md)
16
16
 
17
17
  The whole idea in one line:
18
18
 
@@ -28,10 +28,9 @@ run a shell can drive every operation.
28
28
  ## Why
29
29
 
30
30
  - **One lifecycle, one source of truth.** Start an issue, get an isolated worktree and branch, open
31
- a PR, merge, and clean up — each step is one command, correct by construction. The board is both
32
- the plan and the proof.
31
+ a PR, merge, and clean up — each step is one command. The board is both the plan and the proof.
33
32
  - **Sessions that pick up where you left off.** `cckit handoff "<note>"` saves a resume-here note;
34
- bare `cckit` prints it at the start of the next session — context survives the context window.
33
+ bare `cckit` prints it at the start of the next session.
35
34
  - **Sessions that talk to each other.** `cckit msg send <branch|project:branch|all> [--steer]
36
35
  "<text>"` mails any parallel session on the machine — same project or another; the kit's mail
37
36
  hook delivers it to a *live* session between tool calls, and a `--steer` message redirects a
@@ -41,7 +40,7 @@ run a shell can drive every operation.
41
40
  - **Scales from one issue to a wave.** The same verbs that take one issue to a merged PR also plan
42
41
  and run a whole wave of parallel agents — with a captain that gates and merges behind policy
43
42
  floors.
44
- - **Zero hard dependencies.** Pure bash with graceful fallbacks; it auto-detects optional tools
43
+ - **Zero hard dependencies.** Pure bash with fallbacks; it auto-detects optional tools
45
44
  (`gh`, `jq`, `fzf`, `gum`) and degrades instead of failing.
46
45
  - **Portable.** No company, framework, or repo is baked in — everything is driven from
47
46
  `cckit.config.json`.
@@ -81,50 +80,194 @@ cd cckit && ./scripts/install.sh # symlinks bin/cckit onto your PATH
81
80
  | Linux | ✅ native |
82
81
  | Windows | ✅ via WSL or Git Bash (not native cmd/PowerShell) |
83
82
 
84
- Requirements: `bash` 4+, `git`, and `gh` (GitHub CLI) authenticated. `jq` recommended.
83
+ Requirements: `bash` 3.2+, `git`, `gh` (GitHub CLI) authenticated, `jq` and `perl`. `cckit doctor` checks each one.
85
84
 
86
85
  ## Quick start
87
86
 
88
87
  ```bash
89
- cckit doctor # onboarding preflight: deps, gh auth
90
- cckit init --profile software # scaffold cckit.config.json + .claude/ for this repo
91
- # profiles: software · content · research · automation · minimal
88
+ cckit doctor # onboarding preflight: deps, gh auth, and each integration you switched on
89
+ # asks before installing; with no terminal and no --fix it only reports
90
+ cckit init [<folder>] # guided setup, end to end: names what the folder is, asks what is
91
+ # missing, scaffolds cckit.config.json + .claude/, then git + GitHub
92
+ # (repository, develop, labels, protection) after ONE confirmation.
93
+ # A new project starts from a recipe. See "Set up a project" below.
94
+ cckit init --profile software --no-github # scaffold only: nothing outside the folder
95
+ # profiles: software · content · marketing · research · automation · minimal
96
+ # --adapter claude|codex|both picks the agent (default claude);
97
+ # codex writes AGENTS.md + .agents/ and no .claude/ tree;
98
+ # both get the commit guards + session-mail hooks (Codex: in
99
+ # .codex/hooks.json, merged with yours — trust them with /hooks)
100
+ # and one specialist agent per role from the same role source:
101
+ # .claude/agents/<role>/AGENT.md and .codex/agents/<role>.toml
102
+ cckit add # list the optional integrations + modules; `cckit add <name>` switches one on
103
+ # `cckit add page-design`: the page-design skill, in a project that already exists
104
+ # `cckit add graft`: code-graph retrieval + the code-retrieval rule
105
+ # `cckit add lavish --set enable=no`: turn review pages off (on by default)
106
+ cckit page mode # `page`, or `terminal: <why>` — can this session show a review page?
92
107
  cckit plan-next # propose what to build next, grounded in current capabilities
93
- cckit status # where are we: local undone work, PRs to attend, cleanup available
94
- cckit next # the next unblocked issue + how to start it
108
+ cckit status # where are we: light tasks, next effort per flow, local undone work, PRs to attend, cleanup available
109
+ cckit next # the next unblocked issue + how to start it + the weekly cadence
95
110
  cckit start 42 # isolated worktree + branch for issue #42, bootstrapped:
96
111
  # env files copied, dev port assigned, deps installed at the
97
112
  # selected targets — worktree.installPaths if set (those dirs
98
113
  # regardless of their manifests), else a root that declares
99
114
  # deps or is a workspace root with members, else nothing
100
115
  # (KIT_WT_INSTALL=0 skips the install entirely)
116
+ # refused when another live session already claims #42;
117
+ # `cckit start --force 42` (or KIT_FORCE=1) starts anyway
118
+ cckit claims # which live session is working which issue (read-only)
101
119
  cckit brief 42 # the delegation brief for #42, read out of the repo not memory
102
120
  cckit lib # every scripts/lib helper: functions, purpose, error contract
103
121
  cckit pr 42 "what changed" # commit, push, open the PR
122
+ cckit pr 42 "what changed" --base main # target main, not the integration branch; the push
123
+ # exports the target as KIT_PR_BASE for a git pre-push hook
124
+ cckit hotfix 268 # cherry-pick merged PR 268 (or a commit sha) onto main (--base B
125
+ # for another branch): worktree from origin/main, cherry-pick -x,
126
+ # push, PR titled after the source with `Cherry-pick of #268`;
127
+ # a rebase-merged PR is carried commit by commit
128
+ cckit task new "<title>" # light tasks: work tracked in tasks/, no GitHub issue —
129
+ # task list · task next · task start <id> · task finish <id> "<summary>"
130
+ cckit task run <id> # hand one light task to a headless agent: start, one round, the gate
131
+ # (--check, else tasks.check), finish, the review link. Never merges
104
132
  cckit sync # board state, what's unblocked
133
+ cckit sync --cached 60 # the board as one JSON document, from a cache at most 60s old
134
+ # (--json / --write / --watch [secs] / --plan — for a TUI or statusline)
105
135
  cckit handoff "resume note" # save a handoff — bare `cckit` prints it next session
106
- cckit gc # report prunable branches + worktrees (deletes nothing)
136
+ cckit gc # report prunable branches + worktrees, detached worktrees included (deletes nothing); a failed GitHub read shows as UNKNOWN, kept
107
137
  cckit cleanup [--yes] # act on that report: delete the SAFE + LANDED rows, prune listed zombies, keep orphans/stashes
108
138
  ```
109
139
 
110
140
  Adopting cckit in a repo that already has history? `cckit scan` detects the stack, `cckit adopt`
111
141
  records kit-shaped files the repo already has, and `cckit status` answers "where are we" — local
112
142
  undone work, the open PRs waiting on a human, and the cleanup available, plus the board and the
113
- resume handoff in one screen. Run `cckit help` for the full verb list, or
143
+ resume handoff in one screen. It ends with the instruction-file line: the bytes `CLAUDE.md` and the
144
+ rules without a `paths:` frontmatter put into every session, against Claude Code's 150k limit, and
145
+ the three largest files (`cckit doctor` prints the same line; `scripts/instruction-budget-lint.sh`
146
+ is the gate behind it). Run `cckit help` for the full verb list, or
114
147
  `cckit <verb> --help` for any one.
115
148
 
149
+ Updating a project an older cckit scaffolded? `cckit update` says whether it is behind (exit 10) and
150
+ names the command; `cckit migrate` moves an old layout to the current one;
151
+ `cckit init --upgrade --dry-run` runs the upgrade on a temporary copy and prints the files it would
152
+ add or modify; `cckit init --upgrade` applies it and prints that same list as `Changed on disk`.
153
+ Existing files and every path under `upgrade.removed` are kept, and a version bump alone changes one
154
+ line of the config. The path, with what it changes and what it never touches:
155
+ [Update a project](https://cckit.dev/getting-started/update/).
156
+
157
+
158
+ ## Set up a project: `cckit init`
159
+
160
+ `cckit init [<folder>]` takes a folder from whatever state it is in to a project `cckit start` can
161
+ work on. It assumes no technical knowledge: it says what it found, asks in plain language, and
162
+ every question has one recommended answer.
163
+
164
+ **1. It names the folder before writing anything.**
165
+
166
+ | The folder is | What init does |
167
+ | --- | --- |
168
+ | a git repository with a GitHub remote | scaffolds the kit, then runs the setup steps that are still missing |
169
+ | a git repository with no remote | the same, and creates the GitHub repository |
170
+ | a project (for example a `package.json`) with no git | the same, starting from `git init` |
171
+ | files, but nothing that marks a project | asks: set it up here, start a new project in its own folder, or stop |
172
+ | empty, or not there yet | asks whether this is a new project, then what it starts from |
173
+ | your home directory, `~/Desktop`, `~/Documents`, `~/Downloads`, `/` | never scaffolds there. Asks whether this is a new project and which folder it gets; with no terminal and no answers file it exits 2 |
174
+
175
+ **2. A new project starts from a recipe.** A recipe is a JSON file in `recipes/`; adding a file adds
176
+ a recipe. One ships: `nextjs-shadcn` (Next.js, shadcn/ui, pnpm). A recipe's `config` object is
177
+ merged into the project config: `nextjs-shadcn` sets `tasks.check` to `pnpm build && pnpm lint`,
178
+ the gate `cckit task run` uses, and `tasks.design` to `true`, which installs the `page-design`
179
+ skill and makes every task of the project a [page task](#pages-are-built-with-named-design-skills). init then asks whether the project
180
+ needs a database and offers the options in `databases/`. One ships: `supabase`. It adds
181
+ `@supabase/supabase-js` and `@supabase/ssr`, `lib/supabase/client.ts` and `lib/supabase/server.ts`,
182
+ and the two variable names in `.env.local` with placeholders. A guide page
183
+ (`databases/supabase/guide.html`) shows where to create the Supabase project and where each value
184
+ is; init opens it with `npx -y lavish-axi` when a browser is available and prints the same steps
185
+ otherwise. You type the values into `.env.local` yourself: cckit never prints or reads them back,
186
+ and git ignores the file.
187
+
188
+ **3. Git and GitHub, after one confirmation.** init lists every step first, then asks once on a
189
+ terminal. With no terminal it runs them only with `--yes`; without it the kit files are written and
190
+ the run ends by saying the setup did not run and what that leaves undone: the kit files are not
191
+ committed (with the command that commits them), and, when the config's base branch does not exist
192
+ in the repository, that `cckit start` and `cckit task start` cannot cut from it. Without the setup
193
+ the base branch written to the config is one the repository has: its GitHub default, else `main`,
194
+ else the branch that is checked out.
195
+
196
+ | Step | Skipped when |
197
+ | --- | --- |
198
+ | `git init` (branch `main`) and the first commit, the kit files included | the folder is a repository / it has a commit |
199
+ | one commit holding the kit files, on the base branch, in a repository that already had commits. No env file, nothing git ignores, no script of the project's own, nothing the project had staged | the project config is already tracked. Fails, naming the branch to switch to, when the folder is on another branch than the base |
200
+ | `gh repo create`, private (`--public` for public) | `origin` is set; an existing `<owner>/<name>` is connected instead |
201
+ | branch `develop` created and pushed; default branch on a repository init created. When GitHub already has the base branch, the kit files commit is pushed to it | GitHub has the branch and nothing is waiting / an existing repository keeps its default |
202
+ | labels and milestones | only the missing ones are created |
203
+ | "automatically delete head branches" | already on |
204
+ | protection of the base branch: pull request required, branch up to date, linear history, no force-push | already protected. A plan that refuses it (HTTP 403 on a private repository of a free account) is reported as skipped with that reason |
205
+ | Projects v2 field ids | the project has no board |
206
+ | `cckit doctor` report | never |
207
+
208
+ init adds `.cckit/` (cckit's local state) and `.claude/worktrees/` (the folders `cckit start` and
209
+ `cckit task start` create) to the project's `.gitignore`, next to `.claude/settings.local.json` and
210
+ the ownership manifest. In a project whose task list is light tasks, the closing next steps name
211
+ `cckit task new` and `cckit task start` and no label or milestone script.
212
+
213
+ Each step prints `done`, `skipped` or `failed`. A failed step does not stop the later ones, and the
214
+ run exits 1 after all of them. A re-run skips what is finished: on a set-up project it changes
215
+ nothing and every line says `skipped`.
216
+
217
+ ```bash
218
+ cckit init my-app # guided: answers the questions on a terminal
219
+ cckit init my-app --dry-run --recipe nextjs-shadcn --database supabase # print every step, write nothing
220
+ cckit init my-app --answers answers.json --yes # no terminal: answers from a file, setup confirmed
221
+ cckit init --profile software --no-github # the scaffold alone, as before
222
+ ```
223
+
224
+ `--answers` takes a JSON object keyed by question: `new_project` (`yes`/`no`), `folder_use`
225
+ (`here`/`new`/`cancel`), `project_name`, `location`, `recipe`, `database_needed` (`yes`/`no`),
226
+ `database`, `profile`. A question the file does not answer takes the recommended option, and the
227
+ run says so. `--upgrade` is unchanged and never enters this flow.
228
+
116
229
  ## Efforts and slug handles
117
230
 
118
231
  A big piece of work is an **effort** — a parent issue with sub-issues. `cckit effort new "<name>" "sub :: desc" …`
119
232
  creates the parent issue (the four-section plan body), applies the `ctx/kind/priority/role/flow` labels, and lints
120
- every sub-issue title — the same effort `/kit-effort-new` produces, since both call one shared core. The `--flow`
233
+ every sub-issue title — the same effort `/kit-effort-new` produces, since both call one shared core. `--kind` sets
234
+ the `kind:` label on the parent and every sub: one of `feat fix task chore security scaffold ci adr spike plan`
235
+ (default `task`), the same closed set `cckit start` uses as the branch prefix, or a content kind — `post`,
236
+ `campaign`, `brand`, `research` — which is a label only: it starts on `task/`, `plan/`, `task/` and `spike/`
237
+ respectively and titles its PR `docs:`. Any other value is refused before anything is created. In `cckit plan` and `cckit effort plan` an issue with no `ctx:` label shows `?` and weighs 2;
238
+ a `ctx:` value outside `S|M|L|XL` also weighs 2 and warns on stderr. The `--flow`
121
239
  vocabulary (the `[Flow]` title tags) reads from `effort.flows` in the project config, so `cckit effort new --flow X`
122
- works out of the box in any configured repo (an explicit `EFFORT_FLOWS` env var still wins per invocation).
240
+ works in any configured repo (an explicit `EFFORT_FLOWS` env var still wins per invocation).
123
241
  `cckit effort close` is likewise the **single close implementation** (the `/kit-effort-close` skill is a thin caller
124
242
  of the same function): pre-squash work-record snapshot + metrics, squash-merge, close parent + subs, board
125
243
  Status=Done, worktree/branch GC, an optional knowledge-ingest hook, and an advisory kit-sync drift check.
126
-
127
- The GitHub issue **number** stays the canonical key, but every effort also has a memorable **slug** handle (the one
244
+ The drift check flags `.claude/rules/` files only when the kit ships a rule of that name; a project's own rules are not flagged.
245
+ The metrics judge reads its hosted endpoint from `CCKIT_MODEL_URL` / `CCKIT_MODEL` / `CCKIT_MODEL_TOKEN`; a project
246
+ with its own variables names them in the config (`model.urlEnv` / `model.modelEnv` / `model.tokenEnv` — env var
247
+ names, never values).
248
+
249
+ **The effort metrics record.** `cckit effort close` appends one JSON line per effort to
250
+ `<git-common-dir>/effort-metrics/records.jsonl`: diff signals (`files`, `added`, `removed`, `commits`), a build time
251
+ and a token count, each with the source it came from. Nothing in it is estimated — a figure with no source is `null`.
252
+
253
+ | Field | Source | `null` when |
254
+ | --- | --- | --- |
255
+ | `build_seconds` + `build_source` | `effort-start`: close time minus the stamp `cckit effort start` writes to `effort-metrics/<N>.start` when it creates the branch. `first-commit`: with no stamp (an effort started before the stamp existed, or on another machine), close time minus the author time of the oldest commit on the effort branch | the branch has no stamp and no commit of its own |
256
+ | `tokens_real` + `tokens_source` | `transcripts`: the sessions listed in `<git-common-dir>/kit-usage.jsonl`, summed from their Claude transcripts. cckit ships no writer for that log, so this applies only where a project keeps one. `autopilot-run`: the usage the runtime printed during `cckit autopilot run` on the effort branch and its `sub/<N><letter>` branches, read from `.cckit/autopilot/*.json`. Interactive sessions are not in that figure | neither source has a figure; `tokens_null_reason` says which: `no-usage-source`, `no-session-matched`, or `autopilot-usage-unknown` (a run whose rounds printed no usage — a partial sum would be an undercount) |
257
+ | `cost_real_usd` + `cost_source` | `list-price` for a transcript sum; `runtime` for the cost Claude prints in a headless run | no token figure, or the runtime printed no cost (Codex) |
258
+
259
+ Records written before the source fields existed have no `build_source`, `tokens_source` or `tokens_null_reason` key;
260
+ they are left as written.
261
+
262
+ `cckit merge` refuses a PR whose head is an `effort/*` branch and names `cckit effort close <N>`: its squash would
263
+ skip that snapshot. `KIT_FORCE=1 cckit merge <pr>` merges anyway, with a warning.
264
+ Before the squash deletes `effort/<N>-…` it re-targets every open PR based on that branch to the base branch
265
+ (`↻ PR <n> re-targeted to develop`) — GitHub closes a PR, unmerged, when its base branch is deleted. If a
266
+ re-target fails, or the list of those PRs cannot be read, the close refuses, names the PR, and merges nothing.
267
+ A project gate goes in `effort.preCloseHook`: it runs as `<hook> <effort#> <sub#…>` from the effort worktree
268
+ before the snapshot and the merge, a non-zero exit refuses the close, and `KIT_FORCE=1` skips it with a notice.
269
+
270
+ The GitHub issue **number** stays the canonical key, but every effort also has a **slug** handle (the one
128
271
  already in its `effort/<N>-<slug>` branch). Effort commands take the slug *or* the number interchangeably:
129
272
 
130
273
  ```bash
@@ -134,9 +277,13 @@ cckit effort pr slug-handles
134
277
  cckit effort close slug-handles
135
278
  ```
136
279
 
280
+ `cckit effort pr` titles the PR as a Conventional Commit subject carrying the effort id —
281
+ `feat(core): adoption hardening [#115]` (scope from the `flow:` label, type from `--type` or the
282
+ `kind:` label) — and refuses to open a PR whose title its commitlint gate would reject.
283
+
137
284
  A pure-digits argument is always a number; anything else is resolved to the canonical number by
138
285
  matching `effort/*` branches, the `slug:<slug>` label, then open effort titles. An unknown or
139
- ambiguous slug fails with a clear error rather than guessing. Efforts render as `slug #N`.
286
+ ambiguous slug fails with an error rather than guessing. Efforts render as `slug #N`.
140
287
 
141
288
  ### Ordering work — `cckit effort chain`
142
289
 
@@ -194,48 +341,308 @@ round-trip buys a count that is right either way.
194
341
  config per invocation.
195
342
  - This gates **efforts only**. `cckit start <issue>` (a plain task worktree) has no WIP limit.
196
343
  - **No network, no problem.** `EFFORT_WIP_REMOTE=0` skips the origin query and counts local heads
197
- plus your cached `refs/remotes`. If origin is simply unreachable, the count falls back to those
344
+ plus your cached `refs/remotes`. If origin is unreachable, the count falls back to those
198
345
  same cached refs, prints one line saying the count may be stale, and the start proceeds.
199
346
 
347
+ ### The weekly cadence
348
+
349
+ The three ordering tools above — the priority sort, `cckit effort chain` and the WIP limit — are
350
+ read on a fixed weekly rhythm. `cckit next` and `cckit status` both end their human output with it,
351
+ from one shared function, so the line cannot differ between the two verbs:
352
+
353
+ | When | Run | What it gives you |
354
+ | --- | --- | --- |
355
+ | Monday | `cckit plan` | the week's order: waves layered from the `blocked_by` edges, and **inside a wave the issues sorted `priority:p0` → `p1` → `p2` → `p3`**, unlabeled last |
356
+ | Daily | `cckit next` | the unblocked set and the one command that starts the top issue |
357
+ | Friday | `cckit gc` | the branches and worktrees that can be pruned — a report, it deletes nothing (`cckit cleanup` acts on it) |
358
+
359
+ Priority never overrides a dependency: a p3 issue that blocks a p0 issue sits in an earlier wave and
360
+ still runs first. For efforts, `cckit status` opens with a **Next effort per flow** table — per
361
+ flow, the effort with no open blocker, p0 → p3 then lowest number, plus how many are still waiting.
362
+ `cckit status --llm` carries those rows as `next_efforts` (and a project's light tasks as
363
+ `light_tasks`: counts by state plus the tasks that need someone to act, read from local git); the cadence line is human output only,
364
+ so `cckit next --llm` rows stay `{number,ctx,title}`.
365
+
366
+ **`cckit effort plan` can read a local snapshot instead of GitHub.** By default it makes one
367
+ listing call plus one `blocked_by` call per open effort. Set `effort.planSource` in
368
+ `cckit.config.json` to an executable and the plan calls it instead, as `<source> <owner/repo>` from
369
+ the project root:
370
+
371
+ ```text
372
+ # age: 2h
373
+ 241<TAB>Core<TAB>M<TAB>order and cadence
374
+ 257<TAB>Core<TAB>L<TAB>release gates<TAB>241
375
+ ```
376
+
377
+ Columns are `number`, `flow`, `ctx`, `title` and an optional comma-separated `blockers` list; the
378
+ `# age:` line is optional. A source that is not executable, exits non-zero or prints no rows falls
379
+ back to GitHub. The plan prints a `source:` line under its header — the source used, its age when it
380
+ reports one, and the reason for a fallback — so a plan built from a snapshot never passes for a live
381
+ one. `EFFORT_PLAN_SOURCE` overrides the config per invocation.
382
+
383
+ ## Light tasks — work without GitHub issues
384
+
385
+ A team that does not track its work in GitHub issues keeps the list in the project: one file per
386
+ task under `tasks/`.
387
+
388
+ ```bash
389
+ cckit task new "Write the spring newsletter" # prints the id, writes tasks/<id>.md
390
+ cckit task next # the task to take next
391
+ cckit task list # every open task: draft · todo · shared · doing · review
392
+ cckit task start <id> # worktree + branch light/<id>-<slug> (alias: take)
393
+ cckit task finish <id> "what was done" # mark done on the branch, push, open the PR (alias: done)
394
+ cckit task share "Q1 backlog" # one PR that adds this checkout's drafts to the base
395
+ cckit task run <id> --check "pnpm build" # start + ONE headless agent round + finish: prints the PR link
396
+ ```
397
+
398
+ - **Review is a pull request.** `finish` opens it; the task reads `done` when it merges. The
399
+ approver needs a GitHub account, the task list does not.
400
+ - **State is derived from git**, not stored twice: on the base branch = `todo`, a `light/<id>-…`
401
+ branch = `doing`, that branch saying done = `review`, the base branch saying done = `done`.
402
+ - **One file per task** so two branches that each add a task merge without a conflict.
403
+ - **`cckit gc` keeps a live task's branch**: `PROTECTED: light task <id> still OPEN`.
404
+ - **Sources.** Tasks are read through one interface (`scripts/lib/task-source.sh`). The `file`
405
+ source ships; another store plugs in as `scripts/lib/task-source-<name>.sh` plus
406
+ `tasks.source: "<name>"`.
407
+ - **Delegating a task.** `cckit task run <id>` does `start`, one `cckit autopilot run` objective
408
+ built from the task's title and notes, and `finish --all`, then prints the pull request link. The
409
+ gate is `--check "<cmd>"`, else `tasks.check` in the config, else none. A failing gate exits 6
410
+ and a round that changed nothing exits 5; neither opens a pull request. `--no-finish` stops
411
+ before the pull request. A stopped earlier run for the task is discarded. It never merges.
412
+ - **Page tasks.** A task whose kind is `page`, or any task where the config sets
413
+ `tasks.design: true`, is run with the `page-design` skill, and its pull request lists the skills
414
+ the run loaded. See [Pages are built with named design skills](#pages-are-built-with-named-design-skills).
415
+ - **Default list.** `tasks.default: "light"` makes a bare `cckit next` answer from this list;
416
+ `cckit task default` prints `light` or `issues`. The `campaign` skill reads it to record a
417
+ campaign's pieces as light tasks or as an effort's sub-issues.
418
+
419
+ Guide: [Light tasks](https://cckit.dev/project-management/light-tasks/).
420
+
421
+ ### Marketing profile
422
+
423
+ `cckit init --profile marketing` sets a project up for a team that does not use git. It is the
424
+ `content` profile (PM, Editor, Designer and Researcher agents; the `copywriting` skill) plus:
425
+
426
+ - **Light tasks as the default list** (`tasks.default: "light"`): a bare `cckit next` answers from
427
+ `cckit task`, and no GitHub issue is created per task. Review is still a pull request.
428
+ - **Plain language** (`plainLanguage.enabled: true` and the `plain-language` rule): the agent says
429
+ draft, review and approve, and names worktree, branch and pull request only when asked.
430
+ - **`brand-voice`**: records the voice, key messages and banned phrasings in `brand/voice.md`;
431
+ `copywriting` reads it before it writes.
432
+ - **`campaign`**: one goal becomes a plan file and its pieces — light tasks, or an effort's
433
+ sub-issues when `cckit task default` prints `issues`.
434
+ - **`page-design`**: a page is built with three named third-party design skills in a fixed order,
435
+ with a design brief before the code and a self-review after. See
436
+ [Pages are built with named design skills](#pages-are-built-with-named-design-skills).
437
+ - **Content kinds** `post`, `campaign`, `brand`, `research` as `kind:` labels, and a pull request
438
+ body with a review checklist for a draft (`pr.bodyStyle: "content"`).
439
+
440
+ ```bash
441
+ cckit init --profile marketing --no-github --dry-run # print what it would write
442
+ cckit task new --kind post "<title>" # record a piece
443
+ cckit task new --kind page "<title>" # record a page: `task run` uses the page-design skill for it
444
+ cckit next # the piece to take next
445
+ cckit task start <id> # a folder and branch for it
446
+ cckit task finish <id> "<summary>" --all # open the pull request; --all includes new files
447
+ cckit task run <id> # or hand the piece to a headless agent: one round, then the pull request
448
+ ```
449
+
450
+ Guide: [cckit init reference → The marketing profile](https://cckit.dev/init-reference/#the-marketing-profile).
451
+
452
+ ### Pages are built with named design skills
453
+
454
+ cckit ships one skill of its own, `page-design`, that coordinates three third-party design skills.
455
+ It holds the order and the rules; it contains none of their content.
456
+
457
+ | Order | Skill | Decides | Source · licence |
458
+ | --- | --- | --- | --- |
459
+ | 1 | `impeccable` | direction: what the page is for, its type, layout and colour, and what it must not look like | [pbakaus/impeccable](https://github.com/pbakaus/impeccable) · Apache-2.0 |
460
+ | 2 | `emil-design-eng` | interaction and motion on the chosen design | [emilkowalski/skills](https://github.com/emilkowalski/skills) · MIT |
461
+ | 3 | `web-design-guidelines` | the audit of the finished code; its accessibility and reduced-motion findings win a disagreement | [vercel-labs/agent-skills](https://github.com/vercel-labs/agent-skills) · MIT per its README (the repository has no LICENSE file) |
462
+
463
+ **What `page-design` makes the agent do.**
464
+
465
+ - Write a design brief to `docs/design/<task-id>.md` before any code: the audience, ONE visual
466
+ idea, type, colour, and at least four concrete patterns of a generic generated page that this
467
+ page refuses to have (a centred hero with two buttons, three icon cards in a row, one default
468
+ sans-serif for everything, a fade-in on every section).
469
+ - Apply each skill for what it decides, in the order above.
470
+ - Write a self-review against the brief into the same file after the build.
471
+ - Never use `impeccable`'s live mode in an unattended run.
472
+ - Report the audit as `not run` when its rules cannot be fetched (`web-design-guidelines` fetches
473
+ them from GitHub on every run), never as passed.
474
+ - When one of the three is not installed: write `<skill>: not installed` in the design file and
475
+ continue with cckit's own minimum rules for that step. The missing skill is never reported as
476
+ used.
477
+
478
+ **Where it is installed.** `cckit init` installs it with the marketing profile and the
479
+ `nextjs-shadcn` recipe. In a project that already exists:
480
+
481
+ ```bash
482
+ cckit add page-design
483
+ ```
484
+
485
+ That sets `tasks.design: true` in the project config and copies the skill into the skills folder of
486
+ each adapter the project selects (`.claude/skills/page-design/`, `.agents/skills/page-design/`). It
487
+ asks nothing, needs no version bump, and keeps a copy that is already there. `cckit init --upgrade`
488
+ does not do this for a project already at the installed version: it answers `already at <version>`
489
+ and adds nothing. With `tasks.design: true` and no skill folder, `cckit doctor` prints a failing
490
+ `page-design skill` row that names the command.
491
+
492
+ **Install the three skills in a project.** They are optional and cckit never installs them
493
+ unasked. Each is an integration: `cckit add` switches it on, `cckit doctor --fix` installs it with
494
+ your recorded consent.
495
+
496
+ ```bash
497
+ cckit add impeccable && cckit add emil-design-eng && cckit add web-design-guidelines
498
+ cckit doctor --fix
499
+ ```
500
+
501
+ The commands the doctor runs, which also work by hand from the project folder:
502
+
503
+ ```bash
504
+ npx -y impeccable install --providers=claude --scope=project
505
+ npx -y skills@latest add emilkowalski/skills --skill emil-design-eng -a claude-code -y
506
+ npx -y skills@latest add vercel-labs/agent-skills --skill web-design-guidelines -a claude-code -y
507
+ ```
508
+
509
+ They install for Claude Code, into the project. The `skills` CLI needs Node.js 22.20 or later.
510
+ `impeccable` runs an engine binary that ships with it or is downloaded once into
511
+ `~/.impeccable/bin/`, fetches visual directions from the impeccable.style catalogue when a new
512
+ design starts, and its installer can add a hook that runs on every UI file the agent edits.
513
+
514
+ **What one run showed.** One run is on record: on 2026-11-13 `cckit doctor --fix` installed all three in a Next.js project, with no terminal prompt. `impeccable` also wrote four `.claude/agents/impeccable-*.md` files, the `skills` CLI wrote `skills-lock.json`, and `.claude/settings.json` was not modified, so no design hook was added in that run. The doctor names those extra files on the row of
515
+ an install it has just made. Other versions of the installers are not covered by that run; the
516
+ monthly integrations check is what re-runs the commands.
517
+
518
+ **Not verified.** No page built with the three skills installed has been compared with one built without them
519
+ yet, so this section describes what the skill instructs, not a measured result.
520
+
521
+ **What the review shows.** For a page task, `cckit task run` records which skills the run loaded
522
+ from the events the agent CLI prints, not from what the agent says, and the pull request it opens
523
+ carries them:
524
+
525
+ ```text
526
+ ## Design
527
+
528
+ Design skills loaded in this run: page-design, impeccable.
529
+ Design skills not loaded in this run: emil-design-eng, web-design-guidelines.
530
+ Read from the events the agent CLI (claude) printed during the run: a skill is listed when its call returned without an error. What the agent wrote about itself is not used.
531
+
532
+ Design brief and self-review: `docs/design/<id>.md`.
533
+ ```
534
+
535
+ A run that loaded none says `No design skill was loaded in this run.` A run whose output held no
536
+ event says the list is not known. The review checklist asks the reviewer to open the page in a
537
+ browser and compare it with the brief.
538
+
200
539
  ## Waves — parallel agentic development
201
540
 
202
541
  `cckit wave` reads your open efforts and proposes the incoming waves of work — parallel agent tasks
203
- that gate and merge themselves. This is the part that turns one keyboard into a small team:
542
+ that gate and merge themselves:
204
543
 
205
544
  ```bash
206
545
  cckit plan # the wave plan: deps-ordered, p0-first inside a wave, file-disjoint
207
- cckit wave # a Task-subagent fan-out brief Claude Code enacts (proposes the next wave)
546
+ cckit wave # the wave-0 fan-out brief the driving agent enacts: same wave data for
547
+ # every runtime, dispatch wording per adapter (--adapter claude|codex|both)
208
548
  cckit orchestrate 12 14 17 # run N flows in parallel worktrees (tmux by default)
549
+ cckit orchestrate --results --wait 600 # how each worker ended: success · failure · interrupted
209
550
  cckit orchestrate --runtime herdr --agent codex 12 14 17 # persistent, state-aware agent terminals
210
551
  cckit watch --merge # the captain: gate open PRs, squash-merge the CLEAN ones, advance
211
552
  # (policy floors hold PRs touching CI, lockfiles, or secrets for review)
212
553
  cckit watch --loop # self-pace gate/merge passes until steady state
213
554
  cckit autopilot # select unblocked work, then call orchestrate --detach under a cap
555
+ cckit autopilot run 12 --agent codex --objective "make the tests pass" --until "pnpm test" --max-iters 5
556
+ # ONE headless objective on this branch (claude -p / codex exec): code
557
+ # stops it on a limit, a failing gate, or a round that changed nothing;
558
+ # an --until that already passes ends it with no round (exit 0, said
559
+ # on stderr): --check is the flag for a gate on the work;
560
+ # a killed runner's agent is stopped, or the next start is refused
561
+ # while it lives; --resume counts the cut-short round as usage
562
+ # unknown, not zero
563
+ KIT_BASE_BRANCH=effort/42-auth cckit orchestrate 44 # cut an effort's sub from the effort branch
214
564
  ```
215
565
 
566
+ `KIT_BASE_BRANCH` in the environment overrides `github.baseBranch` for that one invocation, so a
567
+ sub-issue starts with the commits its effort has already landed. The branch has to exist on origin,
568
+ and `orchestrate` prints a line naming the override and the config value it replaced.
569
+
570
+ **Night mode** runs approved waves unattended under a token budget the Workflow runtime enforces.
571
+ The owner posts one `<!-- night-grant -->` comment on the plan parent — budget, waves, waivers — and
572
+ `/kit-autopilot` reads it with `scripts/night-grant.sh`, then launches `scripts/night-run.mjs`. Only
573
+ a grant written by the repository owner (or a login in `night.grantors`) counts. The run is no wider
574
+ than `effort.wipLimit`, stops at the first wave that did not fully merge, and finishes on the gate.
575
+ See [Night mode](https://cckit.dev/config-and-permissions/#night-mode).
576
+
216
577
  Set `review.command` in your config and the captain sends every PR it would merge to an agent
217
578
  reviewer first, records the verdict as a stage receipt, and refuses to merge on a `fail`. You name
218
579
  the command that runs the reviewer — cckit pipes it a brief on stdin and reads the report off
219
- stdout, so it asserts nothing about any agent's flags. A PR with **no** verdict recorded reads
580
+ stdout, so it asserts nothing about any agent's flags. (`review.headless: true` instead has cckit
581
+ build `claude -p` / `codex exec` from the review profile.) A PR with **no** verdict recorded reads
220
582
  `verify`, never merges silently: absence of evidence is not a pass. Off until you configure it.
221
583
  → [the agent review stage](https://cckit.dev/config-and-permissions/#the-agent-review-stage)
222
584
 
585
+ Plans, decisions with options and grilling rounds open as a **review page** you annotate and answer,
586
+ instead of long terminal prose. It is on by default in every project; the page tool is
587
+ [Lavish](https://github.com/kunchenguid/lavish-axi) (third-party, run through `npx`, not affiliated
588
+ with cckit).
589
+
590
+ ```bash
591
+ cckit page mode # `page`, or `terminal: <reason>`
592
+ cckit page open .lavish/<name>.html --fallback .lavish/<name>.md
593
+ # opens the page; with no browser, or when the tool fails, prints the
594
+ # markdown and exits 0
595
+ cckit page poll .lavish/<name>.html # wait for the reader's feedback
596
+ cckit page answer --kind decision --title "<what was decided>" --issue <issue> --body-file <file>
597
+ # a comment on the issue when the project uses GitHub and --issue is
598
+ # given; else docs/answers/<date>-<kind>-<slug>.md, to commit
599
+ ```
600
+
601
+ A session with no browser gets terminal output and exit 0: CI, an unattended run (`cckit autopilot
602
+ run` and the tmux wave worker export `CCKIT_HEADLESS=1`), a headless agent session, SSH, a machine
603
+ with no display. `reviewPages.enabled: false` (`cckit add lavish --set enable=no`) turns pages off,
604
+ and `CCKIT_PAGES=terminal` does it for one command. A plan page before `cckit effort start` is
605
+ recommended; `effort start` checks nothing.
606
+ → [Review pages](https://cckit.dev/project-management/plan-pages/)
607
+
608
+ For review by a person on the running app, `cckit qa` drives one review stack per lane — a lane is
609
+ an issue number, so an effort's worktree is one lane. Declare how the project boots once
610
+ (`/kit-add qa`: the stack command, its port env vars, one readiness probe per service, a fallback
611
+ route, the names of the test-credential env vars), then:
612
+
613
+ ```bash
614
+ cckit qa up # launch the declared stack on this lane's ports; exit 0 only once
615
+ # every readiness probe answers 2xx/3xx; refuses (exit 2) when
616
+ # a lane port is already in use
617
+ cckit qa open # open the changed screen: the PR body's `QA route:` line, else qa.route
618
+ cckit qa verdict pass # record the verdict against the reviewed commit (a push makes it stale)
619
+ cckit qa verdict fail --note "what is wrong" # also mails the notes to the builder's branch
620
+ cckit qa stop # stop the stack; exit 0 only when nothing listens on the lane's ports
621
+ # (a listener the lane did not launch is left running; --force stops it)
622
+ cckit qa lanes # read-only table of every lane: branch, ports, up, verdict, worktree
623
+ ```
624
+
625
+ Set `captain.mergePolicy.requireQa` and `cckit watch` holds a PR until a pass is recorded against
626
+ its current head. Off by default. → [the QA lane](https://cckit.dev/review/qa-lane/)
627
+
223
628
  ## Driven by agents
224
629
 
225
630
  cckit is meant to be operated by an agent loop, not only a human. See [`AGENTS.md`](AGENTS.md) for
226
631
  the contract. Every verb accepts `--llm` for structured output — uniform payloads come back as
227
- **TOON** (token-efficient), so the plan, board, and fan-out cost the model far fewer tokens:
632
+ **TOON**, so the plan, board, and fan-out cost the model fewer tokens than the same rows as JSON:
228
633
 
229
634
  ```bash
230
635
  cckit sync --llm # board state for an agent to reason over
231
636
  cckit plan --llm # the wave plan as TOON rows
232
- cckit wave --llm # the fan-out (one subagent prompt per issue) as TOON
637
+ cckit wave --llm # the fan-out (one worker prompt per issue) as TOON
638
+ cckit orchestrate --results --llm # each worker's collected result as JSON
233
639
  ```
234
640
 
235
641
  Human output renders as markdown — rich via `glow` in a terminal, native in the Claude Code
236
- transcript, pipe-safe everywhere. Every human-facing verb (`sync`, `plan`, `next`, `status`) shares
237
- one rendering seam, so board tables, wave plans, and the status dashboard read the same in every
238
- surface and never leak escape codes down a pipe (`cckit render` exposes the seam for any script).
642
+ transcript, verbatim when piped. Every human-facing verb (`sync`, `plan`, `next`, `status`) goes
643
+ through one renderer (`cckit_render`, `scripts/lib/render.sh`), so board tables, wave plans, and the
644
+ status dashboard read the same in all three and print no escape codes into a pipe (`cckit render` exposes
645
+ it for any script).
239
646
 
240
647
  ### Cloud sessions
241
648
 
@@ -253,30 +660,43 @@ Claude Code cloud sessions reach GitHub through a proxy that refuses GraphQL, an
253
660
 
254
661
  ## cckit builds cckit
255
662
 
256
- None of this is theoretical. cckit is developed *with* cckit — every feature, fix, and tutorial went
663
+ cckit is developed *with* cckit — every feature, fix, and tutorial went
257
664
  through its own lifecycle: an issue, an isolated worktree, a pull request, a merge. The receipts are
258
665
  public: [every issue closed in the repo →](https://github.com/jeiemgi/cckit/issues?q=is%3Aissue%20state%3Aclosed)
259
666
  — including [the effort that produced this README](https://github.com/jeiemgi/cckit/issues/160).
260
- The board is both the plan and the proof.
261
667
 
262
668
  cckit also runs on the rules and skills it ships. `templates/` is what `cckit init` writes into a
263
669
  project; `.claude/skills/` and `.claude/rules/` here are the subset cckit applies to its own work —
264
670
  `concrete` (the anti-slop catalogue every commit and PR body goes through) and
265
- `karpathy-guidelines`, plus the rules that govern this repo's branches, efforts, PR titles and
266
- delegation. It is a subset on purpose: several templates target stacks cckit does not have.
671
+ `karpathy-guidelines`, plus the rules that govern this repo's branches, efforts, PR titles,
672
+ delegation and issue lifecycle (`issue-lifecycle.md`: deliverables are native sub-issues, an
673
+ approved plan is executed without re-confirming each merge, and a close op — not `Closes #N` —
674
+ closes the issue) and merge safety (`merge-safety.md`: bring a branch onto the current base before
675
+ merging, ship a coupled chain as one PR, re-run the gate on the integration branch) and authoring (`authoring.md`: docs and README change with the behaviour, a pasted prompt carries no issue number, a summary names the work and drops machine flags) and review pages (`review-pages.md`: a plan, a decision or a grilling round opens as a page, terminal output where there is no browser, the answer written back — see [Review pages](https://cckit.dev/project-management/plan-pages/)) and the shared checkout (`shared-checkout.md`: the primary checkout is never moved by hand, all work happens in a worktree, a freshly merged verb is called from a current worktree — see [Multi-session safety](https://cckit.dev/development/many-sessions/) and the [install & update matrix](https://cckit.dev/install-matrix/)). Every shipped rule is listed in [Rules cckit ships](https://cckit.dev/rules/) — `gate-and-review.md` (the gate blocks the push and its output goes on the PR; every AI-reviewer finding is fixed or rebutted before the merge) ships to projects and is skipped here.
676
+ It is a subset on purpose: several templates target stacks cckit does not have.
267
677
  `scripts/self-install-test.sh` holds the manifest, the reason for every skip, and the assertion that
268
678
  the installed copies have not drifted from their templates.
269
679
 
270
680
  ## Documentation
271
681
 
272
682
  Full docs live at **[cckit.dev](https://cckit.dev)** — start with
273
- [the idea](https://cckit.dev/philosophy/) if you want the why. The
274
- [tutorials](https://cckit.dev/tutorials/) are step-by-step "How to X with Claude Code"
275
- guides, each labelled **Beginner / Intermediate / Advanced** and carrying a **"Copy as Markdown"
276
- prompt** you can paste straight into Claude Code — start exactly where you are. The
683
+ [the idea](https://cckit.dev/philosophy/) if you want the why. The Software track starts at
684
+ [cckit.dev/software](https://cckit.dev/software/). Each area holds its own step-by-step guides;
685
+ most are labelled **Beginner / Intermediate / Advanced** and carry a **"Copy as Markdown"
686
+ prompt** you can paste straight into Claude Code. The
277
687
  [cookbook](https://cckit.dev/cookbook/) holds lifecycle recipes, and the
278
688
  [CLI reference](https://cckit.dev/cli-reference/) covers every verb.
279
689
 
690
+ The site has two tracks, switched from the top bar. **Software** is for developers: its sidebar
691
+ lists 43 pages in the order a team works in (Start here, Philosophy, Getting started, Project
692
+ management, Design, Development, Review, Ship, then the optional Memory area and Reference), with
693
+ only the current group open. Every other page is linked from its area's "More guides" page or from
694
+ [All reference pages](https://cckit.dev/reference/). **[Marketing](https://cckit.dev/marketing/)** is
695
+ ten pages for a marketing team that works by talking to Claude and never opens a terminal; the
696
+ same ten pages are in Spanish at [cckit.dev/es/marketing](https://cckit.dev/es/marketing/).
697
+ `pnpm build` in `docs-site/` fails when a Marketing page says "worktree", "branch" or "PR" outside
698
+ its glossary page.
699
+
280
700
  ## Project layout
281
701
 
282
702
  ```
@@ -285,10 +705,22 @@ cckit/
285
705
  scripts/lib/*.sh # the git-mechanics bundle (effort, worktree, gh, gc, …)
286
706
  # each declares `# errors:` — see CONTRIBUTING.md
287
707
  scripts/benchmark/ # doc-retrieval benchmark harness (cckit bench)
708
+ benchmarks/runs/ # recorded benchmark checkpoints, one file per release (format: its README.md)
288
709
  .claude-plugin/ # the Claude Code plugin manifest
289
710
  skills/ commands/ # Claude Code skills + slash commands
290
711
  profiles/ templates/ # init profiles + scaffold templates
291
712
  routines/ modules/ # scheduled routines + optional modules
713
+ integrations/ # one JSON descriptor per optional third-party tool + its schema
714
+ # (mempalace.json, mlx-lm.json, graft.json, lavish.json — the last is on
715
+ # by default and never installed unasked; impeccable.json,
716
+ # emil-design-eng.json, web-design-guidelines.json — the design skills
717
+ # the page-design skill coordinates). `cckit doctor` installs each one the
718
+ # config switches on through scripts/lib/integration-install.sh, only
719
+ # with consent recorded in .cckit/consent (`--fix`, or yes at the prompt)
720
+ # scripts/integrations-check.sh installs each one for real and names the
721
+ # step that broke; .github/workflows/integrations-check.yml runs it on
722
+ # the 1st of every month and opens an issue on a failure
723
+ # user-facing page: https://cckit.dev/integrations/
292
724
  docs-site/ # documentation source — Astro/Starlight (deployed to cckit.dev)
293
725
  .claude/skills/ # the subset of templates/skills/ cckit installs for ITSELF
294
726
  .claude/rules/ # the subset of templates/rules/ cckit installs for ITSELF
@@ -296,11 +728,35 @@ cckit/
296
728
  cckit.config.json # project configuration (no hardcoded org/repo)
297
729
  ```
298
730
 
731
+ Every `skills:` entry in `templates/agents/*.md` has to resolve: `scripts/agent-skills-lint.sh` (a
732
+ step of `bash scripts/check.sh`) fails on a name that is not under `skills/` or `templates/skills/`,
733
+ not a `plugin:skill` reference, and not declared third-party in `scripts/agent-skills-external.txt`.
734
+ See [Codified review gates](https://cckit.dev/review/gates/).
735
+
299
736
  `cckit init` also scaffolds `benchmarks/` — a per-project **documentation benchmark** that scores how
300
737
  well an agent finds and uses your own canonical docs (retrieval / adversarial / abstain / quality
301
738
  tiers). Run `cckit bench report` after a docs or kit-version change to catch findability regressions;
302
739
  see the [benchmark guide](https://cckit.dev/benchmark/).
303
740
 
741
+ cckit's own sets are in `benchmarks/`: 55 retrieval, adversarial and abstain questions and 12 judged
742
+ quality claims over `docs-site/src/content/docs`. Recorded runs of the first three tiers are under
743
+ `benchmarks/runs/`.
744
+
745
+ cckit records its own benchmark per release: `cckit bench checkpoint <X.Y.Z>` appends a scored run to
746
+ `benchmarks/runs/<X.Y.Z>.json`, a version can hold several checkpoints, and `cckit release <X.Y.Z>`
747
+ refuses when the version has none or its last one scores lower than the checkpoint before it
748
+ (`--skip-bench-check` overrides and says so). The two are compared over the questions both asked,
749
+ matched by set file and id, so a question set that grew does not lower the score; two checkpoints
750
+ with no question in common are not compared and the newer one is a new baseline. Every checkpoint
751
+ is published at [cckit.dev/benchmark-results](https://cckit.dev/benchmark-results/), a page
752
+ generated from those files.
753
+
754
+ A checkpoint can also carry verb timings. `cckit bench verbs --json` runs nine read-only verbs
755
+ (`status`, `sync`, `next`, `plan`, `gc`, `effort plan`, `claims`, `task list`, `qa lanes`) 3 times
756
+ each and prints the fastest and median wall time in milliseconds and the number of times each ran
757
+ `gh`; `cckit bench checkpoint <X.Y.Z> --verbs <that file>` stores it in the checkpoint and the
758
+ results page shows it. Take the timings on an idle machine.
759
+
304
760
  ## Built with cckit
305
761
 
306
762
  Using cckit in your project? Add a badge (optional, but appreciated):