@jeiemgi/cckit 0.8.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.
- package/.claude-plugin/plugin.json +1 -1
- package/AGENTS.md +169 -21
- package/README.md +505 -35
- package/SECURITY.md +5 -0
- package/bin/cckit +189 -20
- package/cckit.config.json +1 -1
- package/commands/kit-doctor.md +13 -5
- package/commands/kit-export-project.md +0 -2
- package/commands/kit-export-training.md +6 -9
- package/commands/kit-init.md +43 -13
- package/commands/kit-routines.md +1 -1
- package/commands/kit-update.md +11 -6
- package/databases/supabase/guide.html +106 -0
- package/databases/supabase/nextjs/lib/supabase/client.ts +9 -0
- package/databases/supabase/nextjs/lib/supabase/server.ts +29 -0
- package/databases/supabase.json +70 -0
- package/integrations/emil-design-eng.json +41 -0
- package/integrations/graft.json +81 -0
- package/integrations/impeccable.json +42 -0
- package/integrations/integration.schema.json +215 -0
- package/integrations/lavish.json +43 -0
- package/integrations/mempalace.json +28 -0
- package/integrations/mlx-lm.json +32 -0
- package/integrations/web-design-guidelines.json +42 -0
- package/kit.config.schema.json +183 -5
- package/package.json +4 -1
- package/profiles/automation.json +7 -1
- package/profiles/content.json +10 -2
- package/profiles/marketing.json +57 -0
- package/profiles/minimal.json +7 -1
- package/profiles/research.json +7 -1
- package/profiles/software.json +7 -1
- package/recipes/nextjs-shadcn.json +49 -0
- package/scripts/agent-skills-external.txt +45 -0
- package/scripts/agent-skills-lint-test.sh +131 -0
- package/scripts/agent-skills-lint.sh +115 -0
- package/scripts/agent-template-lint-test.sh +42 -0
- package/scripts/agent-template-lint.sh +58 -0
- package/scripts/annotate-setup.sh +1 -1
- package/scripts/autopilot-run-test.sh +338 -0
- package/scripts/autopilot-run.sh +448 -0
- package/scripts/autopilot-test.sh +8 -0
- package/scripts/autopilot.sh +10 -1
- package/scripts/benchmark/benchmark-test.sh +85 -0
- package/scripts/benchmark/checkpoint-test.sh +314 -0
- package/scripts/benchmark/checkpoint.sh +408 -0
- package/scripts/benchmark/lib/model.sh +31 -6
- package/scripts/benchmark/report.sh +17 -2
- package/scripts/benchmark/run-quality.sh +36 -10
- package/scripts/benchmark/verb-timings-test.sh +124 -0
- package/scripts/benchmark/verb-timings.sh +149 -0
- package/scripts/check.sh +29 -19
- package/scripts/content-skills-test.sh +144 -0
- package/scripts/copilot-loop-test.sh +25 -0
- package/scripts/database-supabase-test.sh +121 -0
- package/scripts/docs-marketing-words-test.sh +73 -0
- package/scripts/docs-record-tables-test.sh +72 -0
- package/scripts/guard-raw-git-ops-test.sh +8 -0
- package/scripts/hook-adapter-test.sh +193 -0
- package/scripts/init-content-test.sh +225 -0
- package/scripts/init-guided-test.sh +474 -0
- package/scripts/init-recipes-test.sh +104 -0
- package/scripts/init-upgrade-test.sh +341 -2
- package/scripts/init.sh +746 -95
- package/scripts/instruction-budget-baseline.txt +8 -0
- package/scripts/instruction-budget-lint-test.sh +166 -0
- package/scripts/instruction-budget-lint.sh +219 -0
- package/scripts/integrations-check-test.sh +200 -0
- package/scripts/integrations-check.sh +157 -0
- package/scripts/kit-add-test.sh +214 -0
- package/scripts/kit-add.sh +305 -5
- package/scripts/kit-adopt-test.sh +16 -0
- package/scripts/kit-adopt.sh +3 -2
- package/scripts/kit-digest.sh +2 -2
- package/scripts/kit-doctor-test.sh +293 -0
- package/scripts/kit-doctor.sh +272 -140
- package/scripts/kit-export-project-test.sh +3 -3
- package/scripts/kit-remove-test.sh +19 -0
- package/scripts/kit-routines.sh +2 -2
- package/scripts/kit-self-update.sh +1 -1
- package/scripts/kit-version-check-test.sh +4 -0
- package/scripts/kit-version-check.sh +4 -2
- package/scripts/knowledge-lint.sh +4 -4
- package/scripts/leak-fence-test.sh +89 -0
- package/scripts/lib/adapter-select-test.sh +136 -0
- package/scripts/lib/adapter-select.sh +158 -0
- package/scripts/lib/agent-def-test.sh +69 -0
- package/scripts/lib/agent-def.sh +106 -0
- package/scripts/lib/agent-launch-test.sh +212 -0
- package/scripts/lib/agent-launch.sh +335 -0
- package/scripts/lib/board-view-test.sh +11 -0
- package/scripts/lib/board-view.sh +42 -26
- package/scripts/lib/branch-owner-test.sh +26 -0
- package/scripts/lib/branch-owner.sh +16 -9
- package/scripts/lib/captain-test.sh +105 -0
- package/scripts/lib/captain.sh +87 -8
- package/scripts/lib/codex-hooks-test.sh +100 -0
- package/scripts/lib/codex-hooks.sh +69 -0
- package/scripts/lib/commitlint.sh +1 -1
- package/scripts/lib/content-kinds-gc-test.sh +88 -0
- package/scripts/lib/copilot-test.sh +70 -4
- package/scripts/lib/copilot.sh +66 -14
- package/scripts/lib/effort-dispatch-test.sh +3 -3
- package/scripts/lib/effort-metrics-test.sh +178 -1
- package/scripts/lib/effort-metrics.sh +188 -35
- package/scripts/lib/effort-ops-test.sh +217 -7
- package/scripts/lib/effort-ops.sh +281 -49
- package/scripts/lib/effort-parity-test.sh +49 -13
- package/scripts/lib/effort-plan-test.sh +337 -0
- package/scripts/lib/effort-plan.sh +200 -23
- package/scripts/lib/effort-slug.sh +16 -2
- package/scripts/lib/effort.sh +67 -12
- package/scripts/lib/errors-header-test.sh +1 -1
- package/scripts/lib/gh-project-test.sh +35 -1
- package/scripts/lib/gh-project.sh +37 -16
- package/scripts/lib/gh-rest-test.sh +330 -0
- package/scripts/lib/gh-rest.sh +304 -0
- package/scripts/lib/hook-refresh.sh +1 -1
- package/scripts/lib/init-github.sh +412 -0
- package/scripts/lib/init-guide.sh +630 -0
- package/scripts/lib/integration-install-test.sh +343 -0
- package/scripts/lib/integration-install.sh +257 -0
- package/scripts/lib/integrations-test.sh +366 -0
- package/scripts/lib/integrations.sh +244 -0
- package/scripts/lib/kinds-test.sh +125 -0
- package/scripts/lib/kinds.sh +66 -0
- package/scripts/lib/kit-brief-test.sh +22 -3
- package/scripts/lib/kit-brief.sh +45 -5
- package/scripts/lib/kit-config-resolve.sh +2 -2
- package/scripts/lib/kit-config-test.sh +64 -1
- package/scripts/lib/kit-config.sh +37 -1
- package/scripts/lib/kit-events.sh +7 -0
- package/scripts/lib/kit-gc-test.sh +173 -1
- package/scripts/lib/kit-gc.sh +244 -37
- package/scripts/lib/kit-hotfix.sh +216 -0
- package/scripts/lib/kit-interview-test.sh +93 -0
- package/scripts/lib/kit-interview.sh +117 -8
- package/scripts/lib/kit-lib-test.sh +1 -1
- package/scripts/lib/kit-lib.sh +3 -3
- package/scripts/lib/kit-local.sh +2 -2
- package/scripts/lib/kit-manifest.sh +33 -1
- package/scripts/lib/kit-profile-test.sh +3 -3
- package/scripts/lib/kit-status-test.sh +112 -4
- package/scripts/lib/kit-status.sh +246 -16
- package/scripts/lib/kit-task-ops-test.sh +37 -0
- package/scripts/lib/kit-task-ops.sh +362 -89
- package/scripts/lib/kto-hotfix-test.sh +232 -0
- package/scripts/lib/kto-task-close-test.sh +83 -0
- package/scripts/lib/kto-task-new-test.sh +95 -0
- package/scripts/lib/kto-task-pr-merge-test.sh +97 -6
- package/scripts/lib/kto-task-pr-test.sh +70 -0
- package/scripts/lib/leak-fence.sh +89 -0
- package/scripts/lib/light-task-run-test.sh +255 -0
- package/scripts/lib/light-task-test.sh +309 -0
- package/scripts/lib/light-task.sh +706 -0
- package/scripts/lib/next-test.sh +99 -0
- package/scripts/lib/next.sh +9 -3
- package/scripts/lib/orchestration-runtime-test.sh +72 -0
- package/scripts/lib/orchestration-runtime.sh +57 -5
- package/scripts/lib/plan-machine-test.sh +15 -2
- package/scripts/lib/plan-machine.sh +20 -7
- package/scripts/lib/plan-next-test.sh +1 -1
- package/scripts/lib/plan-next.sh +4 -4
- package/scripts/lib/pr-evidence-test.sh +3 -3
- package/scripts/lib/pr-evidence.sh +1 -1
- package/scripts/lib/qa-lane-test.sh +626 -0
- package/scripts/lib/qa-lane.sh +1357 -0
- package/scripts/lib/qa-lanes-test.sh +175 -0
- package/scripts/lib/react-detect.sh +1 -1
- package/scripts/lib/render-test.sh +1 -1
- package/scripts/lib/review-page-test.sh +318 -0
- package/scripts/lib/review-page.sh +369 -0
- package/scripts/lib/review-stage-test.sh +62 -11
- package/scripts/lib/review-stage.sh +42 -60
- package/scripts/lib/role-identity-test.sh +65 -0
- package/scripts/lib/role-identity.sh +25 -2
- package/scripts/lib/secret-guard.sh +3 -3
- package/scripts/lib/session-registry-test.sh +111 -0
- package/scripts/lib/session-registry.sh +233 -0
- package/scripts/lib/stage-receipt-test.sh +14 -1
- package/scripts/lib/stage-receipt.sh +13 -8
- package/scripts/lib/task-source-file.sh +309 -0
- package/scripts/lib/task-source.sh +130 -0
- package/scripts/lib/test-env-test.sh +3 -3
- package/scripts/lib/test-env.sh +7 -4
- package/scripts/lib/upgrade-report-test.sh +120 -0
- package/scripts/lib/upgrade-report.sh +138 -0
- package/scripts/lib/version-bump.sh +3 -3
- package/scripts/lib/wave-result-test.sh +80 -0
- package/scripts/lib/wave-result.sh +127 -0
- package/scripts/lib/worker-brief-test.sh +5 -0
- package/scripts/lib/worker-brief.sh +2 -2
- package/scripts/lib/worktree-issue-test.sh +30 -1
- package/scripts/lib/worktree-issue.sh +93 -9
- package/scripts/lib/worktree-ports-test.sh +57 -4
- package/scripts/lib/worktree-start-test.sh +197 -0
- package/scripts/lib/worktree-start.sh +169 -32
- package/scripts/lib/zsh-safety-test.sh +19 -3
- package/scripts/marketing-walkthrough-test.sh +152 -0
- package/scripts/night-grant-test.sh +37 -0
- package/scripts/night-grant.sh +448 -0
- package/scripts/night-run-test.sh +8 -0
- package/scripts/night-run.mjs +275 -0
- package/scripts/night-run.test.mjs +324 -0
- package/scripts/orchestrate-test.sh +190 -0
- package/scripts/orchestrate.sh +79 -8
- package/scripts/portable-test.sh +11 -2
- package/scripts/publish.sh +28 -3
- package/scripts/review-lint-test.sh +7 -7
- package/scripts/review-lint.sh +2 -2
- package/scripts/review-rules.conf +8 -0
- package/scripts/rule-recipes-test.sh +96 -0
- package/scripts/self-install-test.sh +39 -9
- package/scripts/setup-labels.sh +18 -1
- package/scripts/setup-milestones.sh +1 -1
- package/scripts/showcase.sh +1 -1
- package/scripts/skill-frontmatter-lint-test.sh +4 -4
- package/scripts/skill-frontmatter-lint.sh +1 -1
- package/scripts/status-test.sh +113 -2
- package/scripts/status.sh +16 -3
- package/scripts/task-sync-test.sh +154 -0
- package/scripts/task-sync.sh +243 -32
- package/scripts/test-runner-test.sh +158 -0
- package/scripts/test.sh +131 -23
- package/scripts/update-path-test.sh +279 -0
- package/scripts/ux-ds-audit.sh +1 -1
- package/scripts/ux-graph-scan.sh +6 -6
- package/scripts/wave-worker.sh +54 -0
- package/skills/kit-add/SKILL.md +77 -0
- package/skills/kit-autopilot/SKILL.md +123 -12
- package/skills/kit-cleanup/SKILL.md +5 -2
- package/skills/kit-contribute/SKILL.md +4 -4
- package/skills/kit-docs-writer/SKILL.md +16 -6
- package/skills/kit-effort-close/SKILL.md +17 -8
- package/skills/kit-effort-new/SKILL.md +15 -9
- package/skills/kit-effort-pr/SKILL.md +15 -7
- package/skills/kit-effort-start/SKILL.md +5 -2
- package/skills/kit-gc/SKILL.md +5 -2
- package/skills/kit-next/SKILL.md +5 -1
- package/skills/kit-onboard/SKILL.md +3 -3
- package/skills/kit-page/SKILL.md +93 -0
- package/skills/kit-plan-next/SKILL.md +8 -4
- package/skills/kit-security-sweep/SKILL.md +1 -3
- package/skills/kit-ship/SKILL.md +2 -3
- package/skills/kit-status/SKILL.md +35 -4
- package/skills/kit-task-new/SKILL.md +3 -3
- package/skills/kit-task-pr/SKILL.md +7 -2
- package/skills/kit-task-pr-merge/SKILL.md +7 -2
- package/skills/kit-task-start/SKILL.md +7 -7
- package/skills/kit-task-sync/SKILL.md +19 -3
- package/skills/kit-ux-audit/SKILL.md +3 -2
- package/templates/agents/auto-dev.md +5 -4
- package/templates/agents/backend.md +1 -1
- package/templates/agents/designer.md +2 -0
- package/templates/agents/devops.md +1 -1
- package/templates/agents/editor.md +9 -1
- package/templates/agents/frontend.md +1 -1
- package/templates/agents/local-delegate.md +1 -1
- package/templates/agents/pm.md +5 -5
- package/templates/agents/tech-lead.md +1 -1
- package/templates/benchmarks/SCHEMA.md +9 -3
- package/templates/codex/hooks.json.tmpl +89 -0
- package/templates/hooks/guard-base-branch-commit.sh.tmpl +13 -7
- package/templates/hooks/guard-raw-git-ops.sh.tmpl +27 -14
- package/templates/hooks/mempal_followup.sh.tmpl +2 -2
- package/templates/hooks/mempal_session_start.sh.tmpl +1 -1
- package/templates/hooks/prepush_gate.sh.tmpl +4 -2
- package/templates/hooks/repo-hygiene.sh.tmpl +3 -2
- package/templates/instructions.md.tmpl +174 -0
- package/templates/kit.config.json.tmpl +3 -3
- package/templates/knowledge-INDEX.md.tmpl +1 -1
- package/templates/lib/kit-sigil.sh.tmpl +1 -1
- package/templates/rules/authoring.md +106 -0
- package/templates/rules/branch-naming.md +40 -4
- package/templates/rules/code-retrieval.md +63 -0
- package/templates/rules/delegation-brief.md +0 -3
- package/templates/rules/design-routing.md +3 -3
- package/templates/rules/effort-model.md +14 -10
- package/templates/rules/gate-and-review.md +94 -0
- package/templates/rules/issue-lifecycle.md +88 -0
- package/templates/rules/knowledge-base.md +1 -1
- package/templates/rules/mempalace.md +1 -1
- package/templates/rules/merge-safety.md +108 -0
- package/templates/rules/naming-and-ids.md +23 -17
- package/templates/rules/plain-language.md +59 -0
- package/templates/rules/plan-next.md +9 -11
- package/templates/rules/react-annotate.md +6 -0
- package/templates/rules/review-pages.md +49 -0
- package/templates/rules/risk-tiered-review.md +13 -4
- package/templates/rules/shared-checkout.md +106 -0
- package/templates/rules/skill-gaps.md +2 -7
- package/templates/rules/task-management.md +13 -1
- package/templates/skills/brand-voice/SKILL.md +91 -0
- package/templates/skills/brand-voice/references/voice-template.md +61 -0
- package/templates/skills/campaign/SKILL.md +123 -0
- package/templates/skills/campaign/references/plan-template.md +55 -0
- package/templates/skills/concrete/SKILL.md +2 -2
- package/templates/skills/copywriting/SKILL.md +8 -1
- package/templates/skills/feature-build-refine/SKILL.md +2 -4
- package/templates/skills/morning-briefing/SKILL.md +2 -2
- package/templates/skills/page-design/SKILL.md +145 -0
- package/templates/skills/page-design/add.json +5 -0
- package/templates/skills/page-design/references/design-file-template.md +40 -0
- package/templates/skills/page-design/references/generic-page-patterns.md +43 -0
- package/templates/skills/page-design/references/minimum-rules.md +42 -0
- package/templates/skills/speckit/SKILL.md +4 -5
- package/templates/skills/supabase-patterns/SKILL.md +1 -1
- package/commands/kit-add.md +0 -42
- package/templates/CLAUDE.md.tmpl +0 -106
package/SECURITY.md
CHANGED
|
@@ -12,6 +12,11 @@ examples, templates):
|
|
|
12
12
|
- **Your private denylist** — copy `privacy-denylist.example` to `.cckit/privacy-denylist`
|
|
13
13
|
(gitignored) and list terms private to you (org, hosts, emails). Nothing project-specific is
|
|
14
14
|
hardcoded in cckit; you declare what is yours.
|
|
15
|
+
- **The leak fence** (`scripts/lib/leak-fence.sh`, gate step 3) — fails on any tracked line that
|
|
16
|
+
contains a private word: a product name, a client, a person, a private path. The built-in pattern
|
|
17
|
+
is always on; yours go in `.cckit/leak-words` (local, gitignored, one extended regex per line) or
|
|
18
|
+
the `CCKIT_LEAK_WORDS` repository secret for CI. The list is never committed, and a hit prints
|
|
19
|
+
`file:line` without the matched text, so a public CI log cannot leak it either.
|
|
15
20
|
- **Enforcement** — runs in the local gate (`scripts/check.sh`) and as a pre-commit hook
|
|
16
21
|
(`githooks/pre-commit`; enable with `git config core.hooksPath githooks`). A finding blocks the
|
|
17
22
|
commit.
|
package/bin/cckit
CHANGED
|
@@ -7,20 +7,46 @@
|
|
|
7
7
|
# cckit resume: print the last session's resume-here handoff
|
|
8
8
|
# cckit handoff "<note>" save a resume-here note for the next session
|
|
9
9
|
# cckit install [bin-dir] symlink cckit onto your PATH (global install)
|
|
10
|
-
# cckit init
|
|
10
|
+
# cckit init [<folder>] guided setup: detect the folder, ask, scaffold, then git + GitHub after
|
|
11
|
+
# one confirmation (--yes with no terminal; --no-github = scaffold only;
|
|
12
|
+
# --answers FILE, --recipe <id>, --database <id>, --public, --dry-run)
|
|
13
|
+
# --adapter <claude|codex|both> selects the agent (default claude)
|
|
11
14
|
# cckit start <issue> [slug] isolated worktree + branch for an issue
|
|
12
|
-
# cckit pr <issue> <summary>
|
|
13
|
-
#
|
|
15
|
+
# cckit pr <issue> <summary> [--base <branch>] commit + push + open the PR (--base: target <branch>, not the
|
|
16
|
+
# integration branch; the push exports it as KIT_PR_BASE)
|
|
17
|
+
# cckit hotfix <pr|sha> [--base B] cherry-pick a merged PR or commit onto B (default main):
|
|
18
|
+
# worktree from origin/B, cherry-pick -x, push, PR `Cherry-pick of #N`
|
|
19
|
+
# cckit close <issue> <summary> [--reason completed|not-planned|duplicate] [--duplicate-of N]
|
|
20
|
+
# [--superseded-by N] close the issue with a reason + summary comment; board Done
|
|
14
21
|
# cckit new [--role R --kind K --priority P --milestone M --blocked-by "#1" --body B|--body-file F] "<title>"
|
|
15
22
|
# file ONE issue: labels + board (Todo) in one step (never raw gh issue create)
|
|
16
|
-
# cckit
|
|
23
|
+
# cckit task <new|list|next|start|finish|run|share|default> light tasks: work tracked in the project, no GitHub issue
|
|
24
|
+
# task new [--priority pN --kind K --body B|--body-file F] "<title>" record a task (one file
|
|
25
|
+
# under tasks/; a draft in this checkout until it is started or shared)
|
|
26
|
+
# task list [--all] · task next every open task and its state · the one to take next
|
|
27
|
+
# task start [--force] [--no-push] <id> worktree + branch light/<id>-<slug> from the base (alias: take)
|
|
28
|
+
# task finish [<id>] "<summary>" [--all] mark it done on its branch, push, open the pull request;
|
|
29
|
+
# the task is done when that PR merges (alias: done). --all also commits new files
|
|
30
|
+
# task run <id> [--check "<cmd>"] [--max-iters N] [--max-seconds N] [--agent <cmd>] [--no-finish]
|
|
31
|
+
# start the task, run ONE headless objective built from its title and notes, finish it and
|
|
32
|
+
# print the review link. Gate: --check, else tasks.check in the config. Never merges
|
|
33
|
+
# task share ["<summary>"] one pull request that adds this checkout's drafts to the base;
|
|
34
|
+
# they list as shared until it merges. Re-run to retry a share whose push or PR failed
|
|
35
|
+
# task default print light | issues: the project's default list (tasks.default).
|
|
36
|
+
# With light, a bare `cckit next` prints what `cckit task next` prints
|
|
37
|
+
# cckit merge [<pr>] [--merge|--rebase] merge the PR (squash by default; rebases on conflict), close
|
|
38
|
+
# its issues, GC the branch, update the PR's base (develop or effort/<N>);
|
|
39
|
+
# refuses an effort/* head: that PR merges with cckit effort close <N>
|
|
17
40
|
# cckit contribute "<summary>" open a contribution PR to cckit, gated on scripts/check.sh
|
|
18
41
|
# (from the cckit checkout or worktree you are in; else the installed one)
|
|
19
42
|
# cckit sync [--llm] board state / what's unblocked
|
|
43
|
+
# sync --json | --write | --cached [TTL] | --watch [SECS] | --plan
|
|
44
|
+
# the dashboard layer: one JSON summary, cached atomically in
|
|
45
|
+
# <git-common-dir>/kit-sync-cache.json (--llm stays TOON)
|
|
20
46
|
# cckit plan [--llm] [--effort N] wave plan: deps-ordered, p0-first in a wave, file-disjoint (TOON --llm)
|
|
21
47
|
# cckit plan-next [--llm] forward plan: current skills/verbs/rules/docs -> what to build next
|
|
22
48
|
# cckit effort <new|chain|start|pr|close|plan> the effort lifecycle
|
|
23
|
-
# effort new [--flow F --role R --priority p1 --goal G --scope S --for-agents A
|
|
49
|
+
# effort new [--flow F --role R --kind K --priority p1 --goal G --scope S --for-agents A
|
|
24
50
|
# --verification V --depends-on "#1,#2" --milestone M] "<name>" ["sub :: desc" …]
|
|
25
51
|
# parent (4-section body + ctx/kind/priority/role/flow labels) + linted native sub-issues
|
|
26
52
|
# effort chain <a> <b> [<c> …] linear order: b blocked_by a, c blocked_by b, + a
|
|
@@ -31,33 +57,61 @@
|
|
|
31
57
|
# EFFORT_WIP_REMOTE=0 or an unreachable origin uses the cache and still starts). Refuses
|
|
32
58
|
# before writing anything; --force (or KIT_FORCE=1) starts anyway, at limit 0 too.
|
|
33
59
|
# `cckit start <issue>` is not affected.
|
|
34
|
-
# effort pr [<N>] [--summary S|--summary-file F] [--for-agents A|--for-agents-file F] [--title T]
|
|
35
|
-
# the ONE effort PR: inherits labels + milestone, rich body, board In Review
|
|
60
|
+
# effort pr [<N>] [--summary S|--summary-file F] [--for-agents A|--for-agents-file F] [--title T] [--type T]
|
|
61
|
+
# the ONE effort PR: inherits labels + milestone, rich body, board In Review. Title is a
|
|
62
|
+
# Conventional Commit subject carrying the id — `type(scope): name [#N]` (scope = flow:
|
|
63
|
+
# label, type = --type or the kind: label, default feat); refused before gh when it fails
|
|
64
|
+
# commitlint. pr.titleStyle = issue-title keeps `[Role] [#N] name`, unchecked.
|
|
36
65
|
# cckit orchestrate <a> <b> … run N flows in parallel worktrees (--runtime tmux|herdr)
|
|
66
|
+
# cckit orchestrate --results how each worker ended: success | failure | interrupted
|
|
37
67
|
# cckit autopilot [<a> …] unattended multi-flow: drive (or auto-pick) issues under a cap
|
|
68
|
+
# cckit autopilot run [<issue>] --objective "<text>" ONE bounded headless objective on this branch
|
|
38
69
|
# cckit watch [--merge] [--loop] captain: gate open PRs, squash-merge CLEAN, advance the wave
|
|
39
70
|
# cckit next [--effort N] everyday helper: the unblocked set + how to start the top issue
|
|
71
|
+
# + the weekly cadence (plan Monday, next daily, gc Friday)
|
|
40
72
|
# cckit wave [--effort N] read open efforts, propose incoming waves: fan-out + captain drive
|
|
41
73
|
# cckit msg <send|read|list> session mail across projects: steer a live session (--steer)
|
|
74
|
+
# cckit claims live session claims: which session is working which issue (read-only)
|
|
42
75
|
# cckit gc [--prune [--yes]] report (default) or prune merged + landed branches and worktrees
|
|
43
76
|
# cckit cleanup [--yes] guided destructive sweep over the gc report (plan first)
|
|
44
|
-
# cckit status
|
|
77
|
+
# cckit status where are we: board, next effort per flow, local undone work,
|
|
78
|
+
# PRs waiting on a human, cleanup available, resume handoff
|
|
45
79
|
# cckit scan [--llm] detect this repo's stack + kit state (JSON)
|
|
46
80
|
# cckit debug [--check] <args> optional browser-debug via chrome-devtools-axi (auto-detected)
|
|
47
81
|
# cckit encode-context stdin JSON -> compact TOON (uniform arrays; JSON fallback)
|
|
48
82
|
# cckit render stdin markdown -> rich (glow on a TTY; verbatim when piped)
|
|
49
|
-
# cckit doctor onboarding preflight (deps, gh auth)
|
|
83
|
+
# cckit doctor onboarding preflight (deps, gh auth, selected agent CLIs)
|
|
84
|
+
# cckit add [<name>] [--set k=v] list integrations + modules; with a name, switch one on in the config
|
|
85
|
+
# cckit page <mode|open|poll|reply|end|answer>
|
|
86
|
+
# review pages: open a plan/decision/grill as a page (terminal
|
|
87
|
+
# output where there is no browser), and record the answer
|
|
50
88
|
# cckit update check whether this project is behind the installed cckit
|
|
51
89
|
# cckit migrate reshuffle an old kit layout to the current one
|
|
52
90
|
# cckit adopt record kit-shaped files a repo already has into the manifest
|
|
53
91
|
# cckit digest <path|url> summarize a file or URL (local model)
|
|
54
92
|
# cckit bench [run|report|…] doc-retrieval benchmark: score how well docs are found + used
|
|
55
|
-
# cckit
|
|
93
|
+
# cckit bench checkpoint <ver> record a benchmark run as a checkpoint of release <ver>
|
|
94
|
+
# (checkpoints: list them · check <ver>: the release gate · page)
|
|
95
|
+
# cckit bench verbs [--json] wall time + gh call count of the read-only verbs
|
|
96
|
+
# (attach to a checkpoint: bench checkpoint <ver> --verbs <file>)
|
|
97
|
+
# cckit release <ver> [--publish] cut a release (dry-run by default); refuses when <ver> has no
|
|
98
|
+
# benchmark checkpoint or scores lower (--skip-bench-check overrides)
|
|
56
99
|
# cckit version [--llm] the installed cckit version
|
|
57
100
|
# cckit commands [--llm] list every verb (the command catalog)
|
|
58
101
|
# cckit lib [--llm] [--all] list every scripts/lib helper: functions, purpose, error contract
|
|
59
102
|
# cckit brief <issue> the delegation brief for an issue, from real state
|
|
60
103
|
# cckit receipt <issue> … record/read one stage receipt (a worker's durable report)
|
|
104
|
+
# cckit qa <up|ready> [--lane N] [--timeout S] launch the declared review stack on this lane's
|
|
105
|
+
# ports; exit 0 only once every readiness probe answers
|
|
106
|
+
# cckit qa open [--lane N] [--pr N] [--route /p] [--print] open the screen the change touched
|
|
107
|
+
# (the PR body's `QA route:` line, else qa.route) on a usable lane
|
|
108
|
+
# cckit qa stop [--lane N] [--force] stop the lane's stack — supervisors before listeners — and
|
|
109
|
+
# exit 0 only when nothing listens on the lane's ports
|
|
110
|
+
# cckit qa verdict [pass|fail] [--lane N] [--note T] [--shot F] record the verdict against the
|
|
111
|
+
# reviewed commit (PR comment upserted, a fail mailed to the builder);
|
|
112
|
+
# with no pass|fail, read it back: pass · fail · stale · none
|
|
113
|
+
# cckit qa lanes [--llm] read-only table of every lane: branch, ports, up (listeners on
|
|
114
|
+
# its ports), verdict (pass · fail · stale · none), worktree
|
|
61
115
|
# cckit completions [bash|zsh] print a shell-completion script to source
|
|
62
116
|
# cckit help
|
|
63
117
|
set -eu
|
|
@@ -82,6 +136,7 @@ LIB="$ROOT/scripts/lib"
|
|
|
82
136
|
# (config-path.sh, #69) that every kit entrypoint uses.
|
|
83
137
|
# shellcheck source=/dev/null
|
|
84
138
|
source "$LIB/config-path.sh"
|
|
139
|
+
_KIT_CONFIG_GIVEN="${KIT_CONFIG:+1}" # 1 = the caller named a config; init keeps only that one (#487)
|
|
85
140
|
if [ -z "${KIT_CONFIG:-}" ]; then
|
|
86
141
|
KIT_CONFIG="$(kit_config_find "$PWD" || true)"
|
|
87
142
|
[ -n "$KIT_CONFIG" ] || KIT_CONFIG="$ROOT/cckit.config.json"
|
|
@@ -167,24 +222,37 @@ case "$cmd" in
|
|
|
167
222
|
# shellcheck source=/dev/null
|
|
168
223
|
source "$LIB/role-identity.sh"; source "$LIB/worktree-start.sh"
|
|
169
224
|
if cckit_is_json; then
|
|
170
|
-
|
|
171
|
-
|
|
225
|
+
# `&& … ||` keeps `set -e` from exiting on a refused start before the JSON result is printed.
|
|
226
|
+
out="$(wt_start "$@" 2>&1)" && rc=0 || rc=$?
|
|
227
|
+
# The issue is the first non-flag argument: `start --force 42` reports 42, not `--force`.
|
|
228
|
+
start_issue=""; for a in "$@"; do case "$a" in -*) ;; *) start_issue="$a"; break ;; esac; done
|
|
229
|
+
cckit_json verb start issue "$start_issue" ok "$([ "$rc" -eq 0 ] && echo true || echo false)" \
|
|
172
230
|
detail "$(printf '%s' "$out" | tail -1)"
|
|
173
231
|
exit "$rc"
|
|
174
232
|
fi
|
|
175
233
|
wt_start "$@"
|
|
176
234
|
;;
|
|
177
235
|
pr|close)
|
|
236
|
+
if [ "$cmd" = pr ]; then case "${1:-}" in -h|--help)
|
|
237
|
+
echo 'cckit pr <issue> "<summary>" ["<commit-msg>"] [--base <branch>]'; exit 0 ;; esac; fi
|
|
178
238
|
# shellcheck source=/dev/null
|
|
179
239
|
source "$LIB/kit-config.sh" && load_kit_config
|
|
180
240
|
# shellcheck source=/dev/null
|
|
181
241
|
source "$LIB/role-identity.sh"; source "$LIB/gh-project.sh"; source "$LIB/kit-task-ops.sh"
|
|
242
|
+
if [ "$cmd" = close ]; then case "${1:-}" in -h|--help)
|
|
243
|
+
echo 'cckit close <issue> ["<summary>"] [--reason completed|not-planned|duplicate] [--duplicate-of N] [--superseded-by N]'; exit 0 ;; esac; fi
|
|
182
244
|
if cckit_is_json; then
|
|
183
245
|
case "$cmd" in
|
|
184
246
|
pr) out="$(kto_task_pr "$@" 2>&1)"; rc=$? ;;
|
|
185
247
|
close) out="$(kto_task_close "$@" 2>&1)"; rc=$? ;;
|
|
186
248
|
esac
|
|
187
249
|
url="$(printf '%s' "$out" | grep -oE 'https://[^ ]+/pull/[0-9]+' | tail -1)"
|
|
250
|
+
# pr: --base may come before the issue number, so skip it when reporting the issue (#391).
|
|
251
|
+
if [ "$cmd" = pr ]; then
|
|
252
|
+
while [ "$#" -gt 0 ]; do
|
|
253
|
+
case "$1" in --base) shift; [ "$#" -gt 0 ] && shift ;; --base=*) shift ;; *) break ;; esac
|
|
254
|
+
done
|
|
255
|
+
fi
|
|
188
256
|
cckit_json verb "$cmd" issue "${1:-}" ok "$([ "$rc" -eq 0 ] && echo true || echo false)" \
|
|
189
257
|
url "$url" detail "$(printf '%s' "$out" | tail -1)"
|
|
190
258
|
exit "$rc"
|
|
@@ -194,6 +262,23 @@ case "$cmd" in
|
|
|
194
262
|
close) kto_task_close "$@" ;;
|
|
195
263
|
esac
|
|
196
264
|
;;
|
|
265
|
+
hotfix)
|
|
266
|
+
# Carry ONE merged change to the release branch (#360): its own PR path, because a cherry-pick
|
|
267
|
+
# has no issue for `cckit pr` to read or close.
|
|
268
|
+
# shellcheck source=/dev/null
|
|
269
|
+
source "$LIB/kit-config.sh" && load_kit_config
|
|
270
|
+
# shellcheck source=/dev/null
|
|
271
|
+
source "$LIB/worktree-start.sh"; source "$LIB/kit-hotfix.sh"
|
|
272
|
+
if cckit_is_json; then
|
|
273
|
+
out="$(kto_hotfix "$@" 2>&1)" && rc=0 || rc=$?
|
|
274
|
+
url="$(printf '%s' "$out" | grep -oE 'https://[^ ]+/pull/[0-9]+' | tail -1)"
|
|
275
|
+
cckit_json verb hotfix source "${1:-}" ok "$([ "$rc" -eq 0 ] && echo true || echo false)" \
|
|
276
|
+
url "$url" worktree "$(printf '%s\n' "$out" | sed -n 's/^worktree: //p' | tail -1)" \
|
|
277
|
+
detail "$(printf '%s' "$out" | tail -1)"
|
|
278
|
+
exit "$rc"
|
|
279
|
+
fi
|
|
280
|
+
kto_hotfix "$@"
|
|
281
|
+
;;
|
|
197
282
|
new)
|
|
198
283
|
# File ONE issue through kto_task_new (labels + board add + Role/Status fields). This verb is why
|
|
199
284
|
# an agent never needs raw `gh issue create`, which skips the board (#361). Multi-part work is
|
|
@@ -230,15 +315,31 @@ case "$cmd" in
|
|
|
230
315
|
fi
|
|
231
316
|
kto_task_new "$n_title" "$n_role" "$n_kind" "$n_prio" "$n_ms" "$n_plan" "$n_blocked" "$n_body"; echo
|
|
232
317
|
;;
|
|
318
|
+
task)
|
|
319
|
+
# Light tasks (#450): work tracked through a task source (the `file` source: one tracked file
|
|
320
|
+
# per task) and not through GitHub issues. One dispatcher in the lib, as `qa` and `receipt` do.
|
|
321
|
+
# kit-task-ops.sh is loaded for kto_pr_title only, so the PR title is built by the same code
|
|
322
|
+
# `cckit pr` uses.
|
|
323
|
+
# shellcheck source=/dev/null
|
|
324
|
+
source "$LIB/kit-config.sh" && load_kit_config
|
|
325
|
+
# shellcheck source=/dev/null
|
|
326
|
+
source "$LIB/worktree-issue.sh"; source "$LIB/worktree-start.sh"
|
|
327
|
+
# shellcheck source=/dev/null
|
|
328
|
+
source "$LIB/commitlint.sh"; source "$LIB/kit-task-ops.sh"
|
|
329
|
+
# shellcheck source=/dev/null
|
|
330
|
+
source "$LIB/light-task.sh"
|
|
331
|
+
lt_cli "$@"
|
|
332
|
+
;;
|
|
233
333
|
merge)
|
|
234
|
-
#
|
|
334
|
+
# Merge (squash by default, --merge / --rebase, #376) through kto_task_pr_merge: rebase on conflict, close the PR's linked issues (native
|
|
235
335
|
# auto-close only fires on the default branch), then clean the branch + worktree. The verb behind
|
|
236
|
-
# every raw `gh pr merge` (#361). An effort's PR merges with `cckit effort close <N
|
|
336
|
+
# every raw `gh pr merge` (#361). An effort's PR merges with `cckit effort close <N>`: an
|
|
337
|
+
# effort/* head is refused here (#379; KIT_FORCE=1 overrides).
|
|
237
338
|
# shellcheck source=/dev/null
|
|
238
339
|
source "$LIB/kit-config.sh" && load_kit_config
|
|
239
340
|
# shellcheck source=/dev/null
|
|
240
341
|
source "$LIB/role-identity.sh"; source "$LIB/gh-project.sh"; source "$LIB/kit-task-ops.sh"
|
|
241
|
-
case "${1:-}" in -h|--help) echo 'cckit merge [<pr>]
|
|
342
|
+
case "${1:-}" in -h|--help) echo 'cckit merge [<pr>] [--squash|--merge|--rebase] merge (squash by default; rebases on conflict), close linked issues, GC branch + worktree, update the PR base'; exit 0 ;; esac
|
|
242
343
|
kto_task_pr_merge "$@"
|
|
243
344
|
;;
|
|
244
345
|
sync) exec "$ROOT/scripts/task-sync.sh" "$@" ;;
|
|
@@ -279,6 +380,7 @@ case "$cmd" in
|
|
|
279
380
|
landed="$(printf '%s\n' "$out" | awk '/^ LANDED branches/{print $3}')"
|
|
280
381
|
orphan="$(printf '%s\n' "$out" | awk '/^ ORPHAN kept/{print $3}')"
|
|
281
382
|
protected="$(printf '%s\n' "$out" | awk '/^ PROTECTED kept/{print $3}')"
|
|
383
|
+
unknown="$(printf '%s\n' "$out" | awk '/^ UNKNOWN kept/{print $3}')"
|
|
282
384
|
stash="$(printf '%s\n' "$out" | awk '/^ stashes kept/{print $3}')"
|
|
283
385
|
zombie="$(printf '%s\n' "$out" | awk '/^ ZOMBIE worktrees/{print $3}')"
|
|
284
386
|
rfail="$(printf '%s\n' "$out" | awk '/^ remote deletes failed/{print $4}')"
|
|
@@ -286,7 +388,7 @@ case "$cmd" in
|
|
|
286
388
|
if [ "$cleanup_rc" -eq 0 ]; then case " $* " in *" --yes "*|*" -y "*) applied=yes ;; esac; fi
|
|
287
389
|
err="$(tr '\n' ' ' < "$cleanup_err" | sed 's/[[:space:]]*$//')"; rm -f "$cleanup_err"
|
|
288
390
|
cckit_json verb cleanup safe "${safe:-0}" landed "${landed:-0}" worktrees "${wt:-0}" orphan "${orphan:-0}" \
|
|
289
|
-
protected "${protected:-0}" stash "${stash:-0}" zombie "${zombie:-0}" applied "$applied" \
|
|
391
|
+
protected "${protected:-0}" unknown "${unknown:-0}" stash "${stash:-0}" zombie "${zombie:-0}" applied "$applied" \
|
|
290
392
|
remote_failed "${rfail:-0}" rc "$cleanup_rc" error "$err"
|
|
291
393
|
[ "$cleanup_rc" -eq 0 ] || exit "$cleanup_rc"
|
|
292
394
|
else
|
|
@@ -311,7 +413,8 @@ case "$cmd" in
|
|
|
311
413
|
landed="$(printf '%s\n' "$out" | grep -c '> LANDED ' || true)"
|
|
312
414
|
protected="$(printf '%s\n' "$out" | grep -c 'PROTECTED:' || true)"
|
|
313
415
|
orphan="$(printf '%s\n' "$out" | grep -c 'ORPHAN' || true)"
|
|
314
|
-
|
|
416
|
+
unknown="$(printf '%s\n' "$out" | grep -c '> UNKNOWN ' || true)"
|
|
417
|
+
cckit_json verb gc safe "$safe" landed "$landed" protected "$protected" orphan "$orphan" unknown "$unknown"
|
|
315
418
|
else
|
|
316
419
|
kit_gc_analyze "$@"
|
|
317
420
|
fi
|
|
@@ -324,6 +427,19 @@ case "$cmd" in
|
|
|
324
427
|
# Everyday-dev helper: surface the unblocked set + the one command to start the top issue.
|
|
325
428
|
# shellcheck source=/dev/null
|
|
326
429
|
source "$LIB/kit-config.sh" && load_kit_config
|
|
430
|
+
# tasks.default = light (the marketing profile): a bare `cckit next` answers from the light
|
|
431
|
+
# task list — the same output as `cckit task next`. Any argument (`--effort <N>`, a filter)
|
|
432
|
+
# asks about issues and takes the issue path, as does every project whose default is issues.
|
|
433
|
+
if [ "$#" -eq 0 ]; then
|
|
434
|
+
# shellcheck source=/dev/null
|
|
435
|
+
source "$LIB/task-source.sh"
|
|
436
|
+
if [ "$(task_default_name)" = "light" ]; then
|
|
437
|
+
# shellcheck source=/dev/null
|
|
438
|
+
source "$LIB/worktree-issue.sh"; source "$LIB/light-task.sh"
|
|
439
|
+
lt_cli next
|
|
440
|
+
exit $?
|
|
441
|
+
fi
|
|
442
|
+
fi
|
|
327
443
|
# shellcheck source=/dev/null
|
|
328
444
|
source "$LIB/next.sh"; next_issue "$@"
|
|
329
445
|
;;
|
|
@@ -365,6 +481,7 @@ case "$cmd" in
|
|
|
365
481
|
migrate) exec "$ROOT/scripts/kit-migrate.sh" "$@" ;;
|
|
366
482
|
adopt) exec "$ROOT/scripts/kit-adopt.sh" "$@" ;;
|
|
367
483
|
doctor) exec "$ROOT/scripts/kit-doctor.sh" "$@" ;;
|
|
484
|
+
add) exec "$ROOT/scripts/kit-add.sh" "$@" ;;
|
|
368
485
|
digest) exec "$ROOT/scripts/kit-digest.sh" "$@" ;;
|
|
369
486
|
bench)
|
|
370
487
|
# Documentation benchmark (#200) — score how well this project finds + uses its OWN canonical
|
|
@@ -373,14 +490,31 @@ case "$cmd" in
|
|
|
373
490
|
BENCH_ROOT="$PWD/scripts/benchmark"; [ -d "$BENCH_ROOT" ] || BENCH_ROOT="$ROOT/scripts/benchmark"
|
|
374
491
|
export BENCH_KIT_ROOT="$ROOT"
|
|
375
492
|
sub="${1:-report}"; shift || true
|
|
493
|
+
BENCH_USAGE='cckit bench <run|quality|report|gate|stop-check> [--dry] [--json]
|
|
494
|
+
cckit bench checkpoint <X.Y.Z> [--passes N] [--from <run.json>] [--model <name>] [--note <text>] [--verbs <timings.json>]
|
|
495
|
+
cckit bench checkpoints [--json] | check <X.Y.Z> | page [--out <file>] [--check]
|
|
496
|
+
cckit bench verbs [--runs N] [--checkout <dir>] [--verb "<verb>"] [--json] (attach: checkpoint <X.Y.Z> --verbs <file>)'
|
|
376
497
|
case "$sub" in
|
|
377
498
|
run) exec bash "$BENCH_ROOT/run.sh" "$@" ;;
|
|
378
499
|
quality) exec bash "$BENCH_ROOT/run-quality.sh" "$@" ;;
|
|
379
500
|
report) exec bash "$BENCH_ROOT/report.sh" "$@" ;;
|
|
380
501
|
gate) exec bash "$BENCH_ROOT/gate.sh" "$@" ;;
|
|
381
502
|
stop-check) exec bash "$BENCH_ROOT/stop-check.sh" "$@" ;;
|
|
382
|
-
|
|
383
|
-
|
|
503
|
+
# Recorded checkpoints per release version (#452). A project scaffolded before checkpoint.sh
|
|
504
|
+
# existed has no copy of it, so these fall back to cckit's own.
|
|
505
|
+
checkpoint|checkpoints|check|page)
|
|
506
|
+
CP="$BENCH_ROOT/checkpoint.sh"; [ -f "$CP" ] || CP="$ROOT/scripts/benchmark/checkpoint.sh"
|
|
507
|
+
case "$sub" in
|
|
508
|
+
checkpoint) exec bash "$CP" record "$@" ;;
|
|
509
|
+
checkpoints) exec bash "$CP" list "$@" ;;
|
|
510
|
+
*) exec bash "$CP" "$sub" "$@" ;;
|
|
511
|
+
esac ;;
|
|
512
|
+
# Wall time + gh call count of the read-only verbs (#452). Same fallback as the checkpoint verbs.
|
|
513
|
+
verbs)
|
|
514
|
+
VT="$BENCH_ROOT/verb-timings.sh"; [ -f "$VT" ] || VT="$ROOT/scripts/benchmark/verb-timings.sh"
|
|
515
|
+
exec bash "$VT" "$@" ;;
|
|
516
|
+
-h|--help) echo "$BENCH_USAGE"; exit 0 ;;
|
|
517
|
+
*) echo "$BENCH_USAGE" >&2; exit 2 ;;
|
|
384
518
|
esac
|
|
385
519
|
;;
|
|
386
520
|
scan) source "$LIB/project-scan.sh"; project_scan "$@" ;;
|
|
@@ -396,6 +530,20 @@ case "$cmd" in
|
|
|
396
530
|
[ "$croot" = "$ROOT" ] || echo "contribute: using the checkout at $croot" >&2
|
|
397
531
|
cd "$croot"; exec "$croot/scripts/contribute.sh" "$@" ;;
|
|
398
532
|
status|ui) exec "$ROOT/scripts/status.sh" "$@" ;;
|
|
533
|
+
claims)
|
|
534
|
+
# Live session claims (#384) — which session is working which issue. Read-only: a dead claim is
|
|
535
|
+
# skipped here and reaped by the next `cckit start` on that issue, never by this verb.
|
|
536
|
+
# shellcheck source=/dev/null
|
|
537
|
+
source "$LIB/session-registry.sh"
|
|
538
|
+
if cckit_is_json; then sreg_list "$PWD" --json; exit 0; fi
|
|
539
|
+
rows="$(sreg_list "$PWD")"
|
|
540
|
+
if [ -z "$rows" ]; then echo "(no live claims)"; exit 0; fi
|
|
541
|
+
printf '%-7s %-8s %-17s %-42s %s\n' "ISSUE" "PID" "SINCE" "BRANCH" "WORKTREE"
|
|
542
|
+
printf '%s\n' "$rows" | while IFS=$'\t' read -r c_issue c_branch c_wt c_pid c_host c_started; do
|
|
543
|
+
c_since="$(date -r "$c_started" '+%Y-%m-%d %H:%M' 2>/dev/null || date -d "@$c_started" '+%Y-%m-%d %H:%M' 2>/dev/null || echo "$c_started")"
|
|
544
|
+
printf '%-7s %-8s %-17s %-42s %s\n' "#$c_issue" "$c_pid" "$c_since" "$c_branch" "$c_wt"
|
|
545
|
+
done
|
|
546
|
+
;;
|
|
399
547
|
resume) source "$LIB/handoff.sh"; handoff_read ;;
|
|
400
548
|
handoff) source "$LIB/handoff.sh"; handoff_write "$@" ;;
|
|
401
549
|
msg)
|
|
@@ -411,7 +559,13 @@ case "$cmd" in
|
|
|
411
559
|
esac
|
|
412
560
|
;;
|
|
413
561
|
install) exec "$ROOT/scripts/install.sh" "$@" ;;
|
|
414
|
-
init)
|
|
562
|
+
init)
|
|
563
|
+
# init resolves the config from the folder it sets up. The KIT_CONFIG this dispatcher worked out
|
|
564
|
+
# is the invoking directory's project or, outside any project, cckit's OWN config: read as the
|
|
565
|
+
# new project's, that one gave every fresh project cckit's base branch and label set (#487).
|
|
566
|
+
# A KIT_CONFIG the caller exported is kept.
|
|
567
|
+
[ -n "$_KIT_CONFIG_GIVEN" ] || unset KIT_CONFIG
|
|
568
|
+
exec "$ROOT/scripts/init.sh" "$@" ;;
|
|
415
569
|
commands)
|
|
416
570
|
# The command catalog - verbs parsed from this dispatcher's own case labels (single source).
|
|
417
571
|
verbs="$(grep -oE '^ [a-z][a-z|-]*\)' "$BIN/cckit" | sed 's/[) ]//g' | tr '|' '\n' | grep -vE '^(-|$)' | sort -u)"
|
|
@@ -452,6 +606,21 @@ case "$cmd" in
|
|
|
452
606
|
source "$LIB/stage-receipt.sh"
|
|
453
607
|
sr_cli "$@"
|
|
454
608
|
;;
|
|
609
|
+
qa)
|
|
610
|
+
# The QA lane (#295): launch the stack command the project declared under `qa`, on this lane's
|
|
611
|
+
# port block, and report USABLE only when every readiness probe answers. One dispatcher in the
|
|
612
|
+
# lib, as `receipt` does with sr_cli, so later subcommands land there and not here.
|
|
613
|
+
# shellcheck source=/dev/null
|
|
614
|
+
source "$LIB/qa-lane.sh"
|
|
615
|
+
qa_cli "$@"
|
|
616
|
+
;;
|
|
617
|
+
page)
|
|
618
|
+
# Review pages (#451): a plan, a decision or a grilling round opens as a page when this session
|
|
619
|
+
# has a browser, and prints to the terminal when it does not. One dispatcher in the lib.
|
|
620
|
+
# shellcheck source=/dev/null
|
|
621
|
+
source "$LIB/review-page.sh"
|
|
622
|
+
rp_cli "$@"
|
|
623
|
+
;;
|
|
455
624
|
completions)
|
|
456
625
|
case "${1:-bash}" in
|
|
457
626
|
bash) cat "$ROOT/completions/cckit.bash" ;;
|
package/cckit.config.json
CHANGED
package/commands/kit-doctor.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Onboarding preflight — check deps (Homebrew, git, gh, jq, perl, node, pnpm), authenticate gh + add scope:project, optionally set up SSH.
|
|
3
|
-
argument-hint: "[--dry-run] [--no-install] [--dismiss-local]"
|
|
2
|
+
description: Onboarding preflight — check deps (Homebrew, git, gh, jq, perl, node, pnpm), authenticate gh + add scope:project, optionally set up SSH. Report-only unless run with --fix (or answered yes in a terminal); with --fix it installs what it can and pauses only for sudo password (Homebrew) and browser OAuth (gh auth login).
|
|
3
|
+
argument-hint: "[--fix] [--dry-run] [--no-install] [--dismiss-local]"
|
|
4
4
|
allowed-tools: Bash
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -15,16 +15,24 @@ Run the kit-doctor script to check all dependencies and authentication required
|
|
|
15
15
|
| Tier 0 | Homebrew (macOS bootstrap — installs if missing, requires sudo password) |
|
|
16
16
|
| Tier 1 | `git`, `gh` (≥2.29 for Projects v2), `jq`, `perl` — auto-installs via brew |
|
|
17
17
|
| Tier 2 | `node`, `pnpm`, `vercel` (if .vercel/ exists), `turbo`/`playwright` (dev deps only) |
|
|
18
|
-
|
|
|
19
|
-
|
|
|
18
|
+
| Agents | The CLI of each adapter the project selected (`adapters` in the config; absent means `claude`): `claude` and/or `codex`, present with its version or absent. Absent is a warning and a manual action — the doctor never installs an agent CLI |
|
|
19
|
+
| Integrations | One row per descriptor in `integrations/` whose config key is on: `mempalace CLI` (`.memory.enabled`) and `mlx-lm` (`.local.enabled`, Apple silicon only). `Lavish` (review pages) is on by default: with `.reviewPages.enabled` unset and neither `lavish-axi` nor `npx` on PATH its row is a skip — not installed, not a failure; with the key set to `true` it is a row like the others. A missing tool is installed by the shared runner (`scripts/lib/integration-install.sh`) from the descriptor's ordered candidates — never plain `pip`. Installs need consent recorded in `.cckit/consent`: `--fix` or a yes at the prompt records it; a run with neither (no terminal, no `--fix`) reports the tool missing and installs nothing; `--dry-run`/`--no-install` only report |
|
|
20
|
+
| Local | Only when `.local.enabled` — starts `mlx_lm.server` in background with a port health check (first run downloads ~4.5 GB) |
|
|
21
|
+
| Memory | Only when `.memory.enabled` — seeds the per-wing wake-up header (`.claude/mempal-identity.<wing>.txt`) and refreshes a stale session-start hook. Seed + refresh obey the consent guard: `--fix` applies them, `--dry-run`/`--no-install` only report |
|
|
20
22
|
| Auth | `gh auth status`, scope `project`, `git config user.name/email` |
|
|
21
|
-
| Repo | `github.baseBranch` vs the repo's GitHub default branch — a mismatch means `Closes #N` won't auto-close issues on GitHub-UI merges (report-only; `cckit
|
|
23
|
+
| Repo | `github.baseBranch` vs the repo's GitHub default branch — a mismatch means `Closes #N` won't auto-close issues on GitHub-UI merges (report-only; `cckit merge` already closes them explicitly) |
|
|
24
|
+
| Instruction files | The bytes `CLAUDE.md` + every `.claude/rules/*.md` without a `paths:` frontmatter load into every session, against Claude Code's 150k limit, and the three largest files. Warns over the limit (report-only; `scripts/instruction-budget-lint.sh --report` lists every file) |
|
|
22
25
|
| SSH | Optional: detect existing key; `KIT_DOCTOR_SSH=1` triggers guided ed25519 setup |
|
|
23
26
|
|
|
24
27
|
## Flags
|
|
25
28
|
|
|
29
|
+
- *(no flag)* — in a terminal it asks before installing. Run from Claude Code there is no terminal, so
|
|
30
|
+
it is report-only: no package install, no `pnpm install`, no seeded or refreshed file, no server start
|
|
31
|
+
- `--fix` (alias `--yes`) — install what is missing and seed/refresh files without asking. Pass it only
|
|
32
|
+
when the user asked for installs
|
|
26
33
|
- `--dry-run` — report only, touch nothing (no installs, no server start)
|
|
27
34
|
- `--no-install` — check + auth only, skip package installs
|
|
35
|
+
- `--agents` — only the agent-runtime rows; no installs, no network; exits 1 when a selected runtime is absent
|
|
28
36
|
- `--dismiss-local` — silence the "local layer down" SessionStart notice until the next x.y kit update (writes `.local.dismissed` to `kit.config.json`); session-only alternative: `KIT_LOCAL_DISMISS=1`
|
|
29
37
|
|
|
30
38
|
## Steps
|
|
@@ -41,8 +41,6 @@ two artifacts, and checks the project is portable.
|
|
|
41
41
|
bash "${CLAUDE_PLUGIN_ROOT}/scripts/kit-export-project.sh" $ARGUMENTS
|
|
42
42
|
```
|
|
43
43
|
|
|
44
|
-
(or `kit export $ARGUMENTS` — the CLI dispatches to the same canonical script.)
|
|
45
|
-
|
|
46
44
|
2. For a full export, tell the user the two manual steps claude.ai needs:
|
|
47
45
|
- paste `.kit-export/claude-instructions.md` into the Project's custom-instructions box
|
|
48
46
|
- upload `.kit-export/project-knowledge/` as the Project's knowledge
|
|
@@ -6,14 +6,11 @@ allowed-tools: Bash, Read, AskUserQuestion
|
|
|
6
6
|
|
|
7
7
|
# /kit-export-training — export sessions as redacted training data
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
Nothing here is automatic — it runs **only when explicitly invoked**, and it never uploads anything.
|
|
16
|
-
The output is plain JSONL on disk; what you do with it is your call.
|
|
9
|
+
This command is the **consent gate** in front of a dataset builder
|
|
10
|
+
(`chat-datasets/build_dataset.py`): it lets a builder choose which sessions to export, **always**
|
|
11
|
+
runs the builder with redaction ON (secret / key / token / email masking is the builder's default;
|
|
12
|
+
this command never passes `--no-redact`), and prints where it wrote plus a reminder that redaction
|
|
13
|
+
must be verified before sharing.
|
|
17
14
|
|
|
18
15
|
Handler (under `${CLAUDE_PLUGIN_ROOT}`):
|
|
19
16
|
- `scripts/kit-export-training.sh [--builder PATH] [--match KEY ...] [--dirs DIR ...] [--sessions FILE ...] [--out PATH] [--split FRAC] [--final-only] [--drop-narration]`
|
|
@@ -26,7 +23,7 @@ Handler (under `${CLAUDE_PLUGIN_ROOT}`):
|
|
|
26
23
|
`--builder` / `KIT_DATASET_BUILDER`.
|
|
27
24
|
2. **Select what to export** — default is the **current git project** (matched by its slug under
|
|
28
25
|
`~/.claude/projects`). Let the builder choose instead:
|
|
29
|
-
- `--match KEY ...` — project-dir name substrings (e.g. `cckit
|
|
26
|
+
- `--match KEY ...` — project-dir name substrings (e.g. `cckit acme`)
|
|
30
27
|
- `--sessions FILE ...` — individual `*.jsonl` transcripts (staged into a temp dir)
|
|
31
28
|
- `--dirs DIR ...` — explicit `~/.claude/projects/<dir>` directories
|
|
32
29
|
3. **Confirm (opt-in)** — on a TTY the handler asks before writing anything; aborting writes
|
package/commands/kit-init.md
CHANGED
|
@@ -24,11 +24,11 @@ You are initializing the current project with the **claude-kit** setup. The kit
|
|
|
24
24
|
- If it's a single project (a `.git` here, or one app), continue here.
|
|
25
25
|
- Suggest a layout that favors the kit — `CLAUDE.md` + `.claude/` at the project root, plans under
|
|
26
26
|
`docs/plans/`, the kit's `scripts/` alongside; **one repo = one kit setup**. See
|
|
27
|
-
[
|
|
27
|
+
[cckit init reference → What the kit writes](https://cckit.dev/init-reference/#what-the-kit-writes).
|
|
28
28
|
|
|
29
29
|
**Then gather inputs.** If `$ARGUMENTS` already names a profile and the key values, use them.
|
|
30
30
|
Otherwise ask the user with `AskUserQuestion`:
|
|
31
|
-
- **Profile** — `software`, `content`, `research`, or `minimal`
|
|
31
|
+
- **Profile** — `software`, `content`, `marketing`, `research`, `automation`, or `minimal`
|
|
32
32
|
(read `${CLAUDE_PLUGIN_ROOT}/profiles/*.json` to describe each)
|
|
33
33
|
- **GitHub repo** — `owner/repo` (offer `gh api user --jq .login` as the default owner)
|
|
34
34
|
- **Projects v2 board** — board number if they use one, else "off"
|
|
@@ -43,7 +43,7 @@ You are initializing the current project with the **claude-kit** setup. The kit
|
|
|
43
43
|
`software` profile and **self-activate** only when their technology is in the project's
|
|
44
44
|
`package.json` — nothing to choose at init.
|
|
45
45
|
|
|
46
|
-
Skip questions already answered in `$ARGUMENTS`. Derive
|
|
46
|
+
Skip questions already answered in `$ARGUMENTS`. Derive defaults (project name =
|
|
47
47
|
repo name, slug = lowercased name) and only confirm the non-obvious ones.
|
|
48
48
|
|
|
49
49
|
2. **Run the engine** from the project root:
|
|
@@ -56,20 +56,25 @@ You are initializing the current project with the **claude-kit** setup. The kit
|
|
|
56
56
|
--repo "<owner/repo>" \
|
|
57
57
|
[--project-number <N>] \
|
|
58
58
|
[--memory on] \
|
|
59
|
-
[--lang "<language>"]
|
|
59
|
+
[--lang "<language>"] \
|
|
60
|
+
[--adapter <claude|codex|both>]
|
|
60
61
|
```
|
|
61
62
|
|
|
63
|
+
`--adapter` selects the agent adapter(s), default `claude`. `codex` writes `AGENTS.md` and
|
|
64
|
+
`.agents/{skills,rules}` from the same templates; `both` writes both trees. The selection is stored
|
|
65
|
+
as `adapters` in the config.
|
|
66
|
+
|
|
62
67
|
It substitutes `{{VARS}}`, resolves `<!-- IF:FLAG -->` blocks, and writes `CLAUDE.md`,
|
|
63
68
|
`.claude/{kit.config.json,agents,skills,rules,settings.local.json}`, and `scripts/`.
|
|
64
69
|
|
|
65
70
|
Tip: add `--dry-run` to print the exact scaffold plan (files, hooks, onboarding tools) **without
|
|
66
71
|
writing anything** — useful to confirm the profile first. Offer the user a dry-run preview if the
|
|
67
|
-
profile/target is
|
|
72
|
+
profile/target is uncertain.
|
|
68
73
|
|
|
69
|
-
3. **Set up external tools — opt-in.** Configure the CLIs the scaffold relies on.
|
|
70
|
-
**
|
|
71
|
-
|
|
72
|
-
|
|
74
|
+
3. **Set up external tools — opt-in.** Configure the CLIs the scaffold relies on. For each tool,
|
|
75
|
+
**explain what it is and why it's needed, then install/authenticate only with the user's
|
|
76
|
+
go-ahead**. A declined tool leaves the matching features dormant (they don't error) and can be
|
|
77
|
+
re-run anytime.
|
|
73
78
|
|
|
74
79
|
**GitHub CLI (`gh`)** — backs the whole task/PR workflow (issues, PRs, labels, milestones).
|
|
75
80
|
- Detect: `gh auth status`. If not authenticated, explain every `task-*` skill needs it and,
|
|
@@ -94,11 +99,36 @@ You are initializing the current project with the **claude-kit** setup. The kit
|
|
|
94
99
|
- `gws` missing → explain it and ask the user for their install method; **do not guess a package
|
|
95
100
|
name or installer**. Re-check `command -v gws`.
|
|
96
101
|
|
|
97
|
-
4. **Report** what was written (echo the engine's summary) and
|
|
98
|
-
|
|
102
|
+
4. **Report** what was written (echo the engine's summary) and its closing lines.
|
|
103
|
+
|
|
104
|
+
5. **Git and GitHub setup.** The engine does this itself: `git init` + first commit, one commit
|
|
105
|
+
holding the kit files on the base branch when the repository already had commits, the GitHub
|
|
106
|
+
repository (private unless `--public`), the base branch `develop` (pushed with that commit),
|
|
107
|
+
labels, milestones, delete-head-branches, base-branch protection, Projects v2 ids, the doctor
|
|
108
|
+
report. You have no terminal, so it runs only with `--yes`, and the scaffold in step 2 ends
|
|
109
|
+
with "Git and GitHub setup: not run" followed by one "Not done:" block per thing left undone
|
|
110
|
+
(the kit files are not committed; the base branch does not exist). Relay those blocks: until
|
|
111
|
+
the kit files are committed, a task started in the project gets a folder without them. Show
|
|
112
|
+
the user the plan first, then run it on their go-ahead:
|
|
113
|
+
|
|
114
|
+
```bash
|
|
115
|
+
"${CLAUDE_PLUGIN_ROOT}/scripts/init.sh" --target "$PWD" --dry-run # the steps, nothing written
|
|
116
|
+
"${CLAUDE_PLUGIN_ROOT}/scripts/init.sh" --target "$PWD" --yes # run them; finished steps are skipped
|
|
117
|
+
```
|
|
99
118
|
|
|
100
|
-
|
|
101
|
-
|
|
119
|
+
Each step prints `done`, `skipped` or `failed`; relay the failed ones with their reason. Pass
|
|
120
|
+
`--no-github` in step 2 when the user wants the files only. Creating a repository and changing
|
|
121
|
+
branch protection are outward-facing: never pass `--yes` without the user's go-ahead.
|
|
122
|
+
|
|
123
|
+
**A new project.** When the target is an empty folder, a folder with no project in it, or the
|
|
124
|
+
user's home directory, ask the engine's questions with `AskUserQuestion` (is this a new project,
|
|
125
|
+
its name and folder, the recipe from `${CLAUDE_PLUGIN_ROOT}/recipes/*.json`, whether it needs a
|
|
126
|
+
database and which one from `${CLAUDE_PLUGIN_ROOT}/databases/*.json`; each descriptor marks the
|
|
127
|
+
recommended one), write the answers to a JSON file and pass `--answers <file>`. Keys:
|
|
128
|
+
`new_project`, `folder_use`, `project_name`, `location`, `recipe`, `database_needed`, `database`,
|
|
129
|
+
`profile`. Never scaffold into a home directory. For a database, the engine prints the steps to get
|
|
130
|
+
the credentials; the user types the values into the env file — do not ask for them in chat and do
|
|
131
|
+
not write them yourself.
|
|
102
132
|
|
|
103
133
|
6. **Audit stack conformance** (when the `software` profile activated a stack-gated build skill).
|
|
104
134
|
The build skills (`feature-build-refine`, `supabase-patterns`, …) self-activate from
|
package/commands/kit-routines.md
CHANGED
|
@@ -10,7 +10,7 @@ Plugin-direct command. Engine at `${CLAUDE_PLUGIN_ROOT}/scripts/kit-routines.sh`
|
|
|
10
10
|
|
|
11
11
|
The kit ships a set of **suggested routines** (briefing, board sweep, GC, knowledge-lint,
|
|
12
12
|
kit-wire-check, security-sweep). Each is an OS cron job scoped to this project. Nothing is
|
|
13
|
-
created without your explicit opt-in
|
|
13
|
+
created without your explicit opt-in.
|
|
14
14
|
|
|
15
15
|
## Steps
|
|
16
16
|
|