wize-dev-kit 0.14.0 → 0.16.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 (226) hide show
  1. package/ARCH.md +24 -77
  2. package/CHANGELOG.md +24 -0
  3. package/DECISIONS.md +1 -27
  4. package/README.md +7 -2
  5. package/ROSTER.md +3 -11
  6. package/adapters/README.md +7 -7
  7. package/adapters/antigravity/README.md +5 -5
  8. package/adapters/claude-code/README.md +1 -1
  9. package/adapters/codex/README.md +5 -5
  10. package/adapters/codex/adapter.yaml +1 -1
  11. package/adapters/codex/render.js +1 -1
  12. package/adapters/continue/README.md +5 -5
  13. package/adapters/cursor/README.md +2 -2
  14. package/adapters/generic/README.md +1 -1
  15. package/adapters/kimi-code/README.md +5 -5
  16. package/adapters/kimi-code/render.js +2 -2
  17. package/adapters/opencode/README.md +3 -3
  18. package/adapters/opencode/render.js +1 -27
  19. package/adapters/windsurf/README.md +3 -3
  20. package/package.json +1 -1
  21. package/schemas/agent.schema.json +2 -2
  22. package/schemas/workflow.schema.json +1 -1
  23. package/src/app-overlay/wize-app-release-channels/workflow.md +0 -2
  24. package/src/app-overlay/wize-app-scaffold/workflow.md +0 -2
  25. package/src/app-overlay/wize-app-store-listing/workflow.md +0 -2
  26. package/src/builder-skills/wize-create-agent/workflow.md +0 -2
  27. package/src/builder-skills/wize-create-skill/workflow.md +0 -2
  28. package/src/builder-skills/wize-create-workflow/workflow.md +0 -2
  29. package/src/core-skills/module.yaml +3 -0
  30. package/src/core-skills/wize-advanced-elicitation/skill.md +0 -2
  31. package/src/core-skills/wize-brainstorming/skill.md +0 -2
  32. package/src/core-skills/wize-eli5/skill.md +72 -0
  33. package/src/core-skills/wize-review-adversarial/skill.md +0 -3
  34. package/src/core-skills/wize-shard-doc/skill.md +0 -2
  35. package/src/method-skills/1-analysis/wize-agent-analyst/agent.yaml +0 -3
  36. package/src/method-skills/1-analysis/wize-document-project/workflow.md +20 -213
  37. package/src/method-skills/1-analysis/wize-prfaq/workflow.md +11 -152
  38. package/src/method-skills/1-analysis/wize-product-brief/workflow.md +19 -92
  39. package/src/method-skills/1-analysis/wize-research/workflow.md +12 -39
  40. package/src/method-skills/1-analysis/wize-trigger-map/workflow.md +16 -82
  41. package/src/method-skills/2-plan-workflows/wize-create-prd/workflow.md +23 -135
  42. package/src/method-skills/2-plan-workflows/wize-ux-design/workflow.md +28 -134
  43. package/src/method-skills/2-plan-workflows/wize-ux-scenarios/workflow.md +15 -93
  44. package/src/method-skills/2-plan-workflows/wize-validate-prd/workflow.md +12 -108
  45. package/src/method-skills/3-solutioning/wize-check-implementation-readiness/workflow.md +11 -103
  46. package/src/method-skills/3-solutioning/wize-create-architecture/workflow.md +48 -55
  47. package/src/method-skills/3-solutioning/wize-create-epics-and-stories/workflow.md +15 -154
  48. package/src/method-skills/3-solutioning/wize-design-system/workflow.md +22 -184
  49. package/src/method-skills/3-solutioning/wize-nfr-principles/workflow.md +17 -145
  50. package/src/method-skills/3-solutioning/wize-tech-vision/workflow.md +22 -130
  51. package/src/method-skills/4-implementation/wize-agent-dev/persona.md +0 -12
  52. package/src/method-skills/4-implementation/wize-code-review/workflow.md +12 -54
  53. package/src/method-skills/4-implementation/wize-create-story/workflow.md +10 -154
  54. package/src/method-skills/4-implementation/wize-dev-story/workflow.md +17 -185
  55. package/src/method-skills/4-implementation/wize-quick-dev/workflow.md +18 -136
  56. package/src/method-skills/4-implementation/wize-retrospective/workflow.md +10 -114
  57. package/src/method-skills/4-implementation/wize-sprint-planning/workflow.md +11 -78
  58. package/src/method-skills/4-implementation/wize-sprint-status/workflow.md +11 -45
  59. package/src/method-skills/module.yaml +0 -28
  60. package/src/orchestrator-skills/module.yaml +1 -7
  61. package/src/orchestrator-skills/wize-help/skill.md +67 -227
  62. package/src/orchestrator-skills/wize-onboarding/workflow.md +14 -78
  63. package/src/orchestrator-skills/wize-orchestrator/agent.yaml +0 -2
  64. package/src/orchestrator-skills/wize-orchestrator/persona.md +3 -44
  65. package/src/orchestrator-skills/wize-party-mode/workflow.md +0 -2
  66. package/src/tea-skills/wize-tea-design/workflow.md +13 -107
  67. package/src/tea-skills/wize-tea-gate/workflow.md +25 -118
  68. package/src/tea-skills/wize-tea-nfr/workflow.md +14 -107
  69. package/src/tea-skills/wize-tea-review/workflow.md +13 -123
  70. package/src/tea-skills/wize-tea-risk/workflow.md +10 -113
  71. package/src/tea-skills/wize-tea-trace/workflow.md +12 -86
  72. package/src/web-overlay/wize-web-deploy/workflow.md +0 -2
  73. package/src/web-overlay/wize-web-scaffold/workflow.md +0 -2
  74. package/src/web-overlay/wize-web-seo-audit/workflow.md +0 -2
  75. package/tools/check-eli5-all-adapters.js +50 -0
  76. package/tools/installer/onboarding.js +20 -14
  77. package/tools/installer/render-shared.js +14 -158
  78. package/tools/installer/validators/run-all.js +2 -3
  79. package/tools/installer/wize-cli.js +70 -499
  80. package/AGENTS.md +0 -37
  81. package/README.es.md +0 -294
  82. package/README.pt-BR.md +0 -292
  83. package/docs/harnesses/antigravity.md +0 -20
  84. package/docs/harnesses/antigravity.pt-BR.md +0 -20
  85. package/docs/harnesses/claude-code.md +0 -23
  86. package/docs/harnesses/claude-code.pt-BR.md +0 -23
  87. package/docs/harnesses/codex.md +0 -21
  88. package/docs/harnesses/codex.pt-BR.md +0 -21
  89. package/docs/harnesses/continue.md +0 -21
  90. package/docs/harnesses/continue.pt-BR.md +0 -21
  91. package/docs/harnesses/cursor.md +0 -22
  92. package/docs/harnesses/cursor.pt-BR.md +0 -22
  93. package/docs/harnesses/generic.md +0 -20
  94. package/docs/harnesses/generic.pt-BR.md +0 -20
  95. package/docs/harnesses/kimi-code.md +0 -19
  96. package/docs/harnesses/kimi-code.pt-BR.md +0 -19
  97. package/docs/harnesses/opencode.md +0 -31
  98. package/docs/harnesses/opencode.pt-BR.md +0 -31
  99. package/docs/harnesses/windsurf.md +0 -22
  100. package/docs/harnesses/windsurf.pt-BR.md +0 -22
  101. package/src/core-skills/wize-customize/skill.md +0 -116
  102. package/src/core-skills/wize-editorial-review-prose/skill.md +0 -94
  103. package/src/core-skills/wize-editorial-review-structure/skill.md +0 -99
  104. package/src/core-skills/wize-grill/skill.md +0 -77
  105. package/src/core-skills/wize-index-docs/skill.md +0 -119
  106. package/src/core-skills/wize-pre-pr-check/skill.md +0 -134
  107. package/src/core-skills/wize-review-edge-case-hunter/skill.md +0 -115
  108. package/src/core-skills/wize-spec/assets/headless-schemas.md +0 -39
  109. package/src/core-skills/wize-spec/assets/spec-template.md +0 -40
  110. package/src/core-skills/wize-spec/customize.toml +0 -20
  111. package/src/core-skills/wize-spec/skill.md +0 -112
  112. package/src/method-skills/1-analysis/wize-document-project/documentation-requirements.csv +0 -12
  113. package/src/method-skills/1-analysis/wize-document-project/templates/api-contracts-template.md +0 -38
  114. package/src/method-skills/1-analysis/wize-document-project/templates/architecture-template.md +0 -54
  115. package/src/method-skills/1-analysis/wize-document-project/templates/component-inventory-template.md +0 -40
  116. package/src/method-skills/1-analysis/wize-document-project/templates/contribution-guide-template.md +0 -34
  117. package/src/method-skills/1-analysis/wize-document-project/templates/data-models-template.md +0 -36
  118. package/src/method-skills/1-analysis/wize-document-project/templates/deep-dive-template.md +0 -312
  119. package/src/method-skills/1-analysis/wize-document-project/templates/deployment-guide-template.md +0 -42
  120. package/src/method-skills/1-analysis/wize-document-project/templates/development-guide-template.md +0 -61
  121. package/src/method-skills/1-analysis/wize-document-project/templates/index-template.md +0 -185
  122. package/src/method-skills/1-analysis/wize-document-project/templates/project-overview-template.md +0 -110
  123. package/src/method-skills/1-analysis/wize-document-project/templates/project-scan-report-schema.json +0 -159
  124. package/src/method-skills/1-analysis/wize-document-project/templates/source-tree-template.md +0 -142
  125. package/src/method-skills/1-analysis/wize-domain-research/customize.toml +0 -14
  126. package/src/method-skills/1-analysis/wize-domain-research/domain-steps/step-01-init.md +0 -49
  127. package/src/method-skills/1-analysis/wize-domain-research/domain-steps/step-02-domain-analysis.md +0 -39
  128. package/src/method-skills/1-analysis/wize-domain-research/domain-steps/step-03-competitive-landscape.md +0 -39
  129. package/src/method-skills/1-analysis/wize-domain-research/domain-steps/step-04-regulatory-focus.md +0 -39
  130. package/src/method-skills/1-analysis/wize-domain-research/domain-steps/step-05-technical-trends.md +0 -39
  131. package/src/method-skills/1-analysis/wize-domain-research/domain-steps/step-06-research-synthesis.md +0 -43
  132. package/src/method-skills/1-analysis/wize-domain-research/research.template.md +0 -31
  133. package/src/method-skills/1-analysis/wize-domain-research/workflow.md +0 -58
  134. package/src/method-skills/1-analysis/wize-market-research/customize.toml +0 -14
  135. package/src/method-skills/1-analysis/wize-market-research/research.template.md +0 -31
  136. package/src/method-skills/1-analysis/wize-market-research/steps/step-01-init.md +0 -57
  137. package/src/method-skills/1-analysis/wize-market-research/steps/step-02-customer-behavior.md +0 -39
  138. package/src/method-skills/1-analysis/wize-market-research/steps/step-03-customer-pain-points.md +0 -37
  139. package/src/method-skills/1-analysis/wize-market-research/steps/step-04-customer-decisions.md +0 -39
  140. package/src/method-skills/1-analysis/wize-market-research/steps/step-05-competitive-analysis.md +0 -37
  141. package/src/method-skills/1-analysis/wize-market-research/steps/step-06-research-completion.md +0 -47
  142. package/src/method-skills/1-analysis/wize-market-research/workflow.md +0 -66
  143. package/src/method-skills/1-analysis/wize-refresh-knowledge/workflow.md +0 -129
  144. package/src/method-skills/1-analysis/wize-technical-research/customize.toml +0 -14
  145. package/src/method-skills/1-analysis/wize-technical-research/research.template.md +0 -31
  146. package/src/method-skills/1-analysis/wize-technical-research/technical-steps/step-01-init.md +0 -49
  147. package/src/method-skills/1-analysis/wize-technical-research/technical-steps/step-02-technical-overview.md +0 -45
  148. package/src/method-skills/1-analysis/wize-technical-research/technical-steps/step-03-integration-patterns.md +0 -39
  149. package/src/method-skills/1-analysis/wize-technical-research/technical-steps/step-04-architectural-patterns.md +0 -39
  150. package/src/method-skills/1-analysis/wize-technical-research/technical-steps/step-05-implementation-research.md +0 -42
  151. package/src/method-skills/1-analysis/wize-technical-research/technical-steps/step-06-research-synthesis.md +0 -46
  152. package/src/method-skills/1-analysis/wize-technical-research/workflow.md +0 -60
  153. package/src/method-skills/2-plan-workflows/wize-edit-prd/workflow.md +0 -110
  154. package/src/method-skills/3-solutioning/wize-create-architecture/architecture-decision-template.md +0 -41
  155. package/src/method-skills/3-solutioning/wize-create-architecture/customize.toml +0 -20
  156. package/src/method-skills/3-solutioning/wize-create-architecture/steps/step-01-init.md +0 -95
  157. package/src/method-skills/3-solutioning/wize-create-architecture/steps/step-01b-continue.md +0 -32
  158. package/src/method-skills/3-solutioning/wize-create-architecture/steps/step-02-context.md +0 -126
  159. package/src/method-skills/3-solutioning/wize-create-architecture/steps/step-03-starter.md +0 -110
  160. package/src/method-skills/3-solutioning/wize-create-architecture/steps/step-04-decisions.md +0 -129
  161. package/src/method-skills/3-solutioning/wize-create-architecture/steps/step-05-patterns.md +0 -109
  162. package/src/method-skills/3-solutioning/wize-create-architecture/steps/step-06-structure.md +0 -97
  163. package/src/method-skills/3-solutioning/wize-create-architecture/steps/step-07-validation.md +0 -124
  164. package/src/method-skills/3-solutioning/wize-create-architecture/steps/step-08-complete.md +0 -59
  165. package/src/method-skills/3-solutioning/wize-project-context/workflow.md +0 -120
  166. package/src/method-skills/4-implementation/wize-changelog/workflow.md +0 -184
  167. package/src/method-skills/4-implementation/wize-checkpoint-preview/workflow.md +0 -117
  168. package/src/method-skills/4-implementation/wize-code-review/customize.toml +0 -21
  169. package/src/method-skills/4-implementation/wize-code-review/steps/step-01-gather-context.md +0 -64
  170. package/src/method-skills/4-implementation/wize-code-review/steps/step-02-review.md +0 -40
  171. package/src/method-skills/4-implementation/wize-code-review/steps/step-03-triage.md +0 -43
  172. package/src/method-skills/4-implementation/wize-code-review/steps/step-04-present.md +0 -100
  173. package/src/method-skills/4-implementation/wize-correct-course/workflow.md +0 -93
  174. package/src/method-skills/4-implementation/wize-investigate/workflow.md +0 -123
  175. package/src/method-skills/4-implementation/wize-release/workflow.md +0 -162
  176. package/src/orchestrator-skills/wize/skill.md +0 -164
  177. package/src/orchestrator-skills/wize-check/skill.md +0 -98
  178. package/src/security-overlay/_shared/allowlist.js +0 -154
  179. package/src/security-overlay/_shared/backlog.js +0 -169
  180. package/src/security-overlay/_shared/cli-runner.js +0 -87
  181. package/src/security-overlay/_shared/cvss.js +0 -108
  182. package/src/security-overlay/_shared/detect.js +0 -125
  183. package/src/security-overlay/_shared/install-script.js +0 -205
  184. package/src/security-overlay/_shared/invoke-phase.js +0 -86
  185. package/src/security-overlay/_shared/owasp.js +0 -56
  186. package/src/security-overlay/_shared/partial.js +0 -225
  187. package/src/security-overlay/_shared/preflight.js +0 -175
  188. package/src/security-overlay/_shared/scope-gate.js +0 -172
  189. package/src/security-overlay/_shared/scope-parser.js +0 -147
  190. package/src/security-overlay/agents/red-teamer/agent.yaml +0 -54
  191. package/src/security-overlay/agents/red-teamer/persona.md +0 -49
  192. package/src/security-overlay/data/common.txt +0 -115
  193. package/src/security-overlay/data/owasp-top10.json +0 -15
  194. package/src/security-overlay/data/tool-allowlist.json +0 -31
  195. package/src/security-overlay/skills/wize-sec-enumerate/scripts/run-enumerate.js +0 -180
  196. package/src/security-overlay/skills/wize-sec-enumerate/skill.md +0 -34
  197. package/src/security-overlay/skills/wize-sec-exploit/data/common.txt +0 -117
  198. package/src/security-overlay/skills/wize-sec-exploit/scripts/run-ffuf.js +0 -147
  199. package/src/security-overlay/skills/wize-sec-exploit/scripts/run-nikto.js +0 -145
  200. package/src/security-overlay/skills/wize-sec-exploit/scripts/run-nuclei.js +0 -176
  201. package/src/security-overlay/skills/wize-sec-exploit/scripts/run-sqlmap.js +0 -139
  202. package/src/security-overlay/skills/wize-sec-pentest/scripts/run-pipeline.js +0 -184
  203. package/src/security-overlay/skills/wize-sec-pentest/skill.md +0 -54
  204. package/src/security-overlay/skills/wize-sec-recon/scripts/run-gitleaks.js +0 -139
  205. package/src/security-overlay/skills/wize-sec-recon/scripts/run-osv.js +0 -227
  206. package/src/security-overlay/skills/wize-sec-recon/scripts/run-recon.js +0 -162
  207. package/src/security-overlay/skills/wize-sec-recon/skill.md +0 -37
  208. package/src/security-overlay/skills/wize-sec-report/scripts/render-report.js +0 -1033
  209. package/src/security-overlay/skills/wize-sec-scope/scripts/generate-scope.js +0 -106
  210. package/src/security-overlay/skills/wize-sec-scope/skill.md +0 -52
  211. package/src/tea-skills/wize-qa-generate-e2e-tests/workflow.md +0 -121
  212. package/tools/installer/baseline.js +0 -128
  213. package/tools/installer/commands/agent.js +0 -197
  214. package/tools/installer/commands/doctor.js +0 -319
  215. package/tools/installer/commands/document-project.js +0 -93
  216. package/tools/installer/commands/sync.js +0 -45
  217. package/tools/installer/commands/update.js +0 -172
  218. package/tools/installer/document-project/batch-scanner.js +0 -93
  219. package/tools/installer/document-project/classify.js +0 -170
  220. package/tools/installer/document-project/modes/deep-dive.js +0 -196
  221. package/tools/installer/document-project/modes/full-rescan.js +0 -15
  222. package/tools/installer/document-project/modes/initial-scan.js +0 -100
  223. package/tools/installer/document-project/modes/quick.js +0 -211
  224. package/tools/installer/document-project/render-index.js +0 -101
  225. package/tools/installer/document-project/state.js +0 -110
  226. package/tools/installer/version-check.js +0 -117
@@ -3,10 +3,9 @@
3
3
  * wize-dev-kit — CLI entry point
4
4
  * Subcommands: install, update, uninstall, list, sync, agent, workflow, help
5
5
  *
6
- * v0.14.0 — Full-lifecycle CLI with install, update, uninstall, list, sync,
7
- * agent, workflow, validate, doctor, and document-project commands. Adapters
8
- * render for 9 IDE targets. Security overlay ships with 8 tools.
9
- * `install --yes` now enables all harnesses + all overlays by default.
6
+ * This is a v0.1 scaffold. The interactive prompt logic and adapter rendering
7
+ * are stubs; the dispatcher and basic install/uninstall create the .wize/
8
+ * folder layout so downstream agents can be activated.
10
9
  */
11
10
  'use strict';
12
11
 
@@ -14,16 +13,8 @@ const fs = require('node:fs');
14
13
  const os = require('node:os');
15
14
  const path = require('node:path');
16
15
  const readline = require('node:readline');
17
- const { execSync } = require('node:child_process');
18
16
  const prompts = require('prompts');
19
17
  const { applyGitignore, generateUserToml } = require('./setup-helpers.js');
20
- const { cmdUpdate, loadProjectConfig } = require('./commands/update.js');
21
- const { printUpdateHintIfAny } = require('./version-check.js');
22
- const { cmdSync: cmdSyncReal } = require('./commands/sync.js');
23
- const { cmdAgentList, cmdAgentCreate, cmdAgentEdit } = require('./commands/agent.js');
24
- const { cmdDoctor, adapterTargetPath } = require('./commands/doctor.js');
25
- const { cmdDocumentProject } = require('./commands/document-project.js');
26
- const { compose: composeOnboarding } = require('./onboarding.js');
27
18
 
28
19
  const INTERACTIVE = process.stdout.isTTY && process.stdin.isTTY;
29
20
 
@@ -45,8 +36,7 @@ const TARGETS = [
45
36
  const PROFILES = [
46
37
  { code: 'core', label: 'Wize Dev Core', required: true },
47
38
  { code: 'web-overlay', label: 'Wize Web Dev (overlay)', required: false },
48
- { code: 'app-overlay', label: 'Wize App Development (overlay)', required: false },
49
- { code: 'security-overlay', label: 'Wize Security (AI Pentester overlay)', required: false }
39
+ { code: 'app-overlay', label: 'Wize App Development (overlay)', required: false }
50
40
  ];
51
41
 
52
42
  // Common BCP-47 short codes. Users can type any other value freely.
@@ -77,8 +67,6 @@ Commands:
77
67
  agent <create|list> Manage agents (built-in or custom).
78
68
  workflow <create|list> Manage workflows.
79
69
  validate Run schema + lint + dry-run validators.
80
- doctor Diagnose the kit + project state, suggest fixes.
81
- document-project Document the current repo (quick | initial_scan | full_rescan | deep_dive).
82
70
  help Show this message.
83
71
 
84
72
  Documentation:
@@ -98,131 +86,18 @@ function logo() {
98
86
  ].join('\n');
99
87
  }
100
88
 
101
- // Pipe-safe line reader.
102
- //
103
- // `readline.question()` has two bugs that bite us when stdin is a pipe (e.g.
104
- // `printf ... | wize-dev-kit install` or our CI smoke test):
105
- // 1. Opening a new createInterface per call closes stdin on .close().
106
- // 2. Even with a shared interface, the second `question` after a single
107
- // empty line ("\n") never resolves — readline's question machinery
108
- // stalls in non-TTY mode.
109
- //
110
- // We replace it with an event-based queue: subscribe to `line` once, push
111
- // resolved promises in order. Empty lines are propagated as `""`. EOF is
112
- // treated as end of the queue (remaining waiters resolve with `""`).
113
- let _rl = null;
114
- let _queue = [];
115
- let _waiters = [];
116
-
117
- function getRl() {
118
- if (_rl) return _rl;
119
- _rl = readline.createInterface({ input: process.stdin, terminal: false });
120
- _rl.on('line', (line) => {
121
- if (_waiters.length) _waiters.shift()(line);
122
- else _queue.push(line);
123
- });
124
- _rl.on('close', () => {
125
- while (_waiters.length) _waiters.shift()('');
126
- });
127
- process.on('exit', () => { if (_rl) { _rl.close(); _rl = null; } });
128
- return _rl;
129
- }
130
-
131
89
  function prompt(question) {
132
- process.stdout.write(question);
133
- getRl();
134
- // In interactive mode, discard any residual lines left by previous
135
- // prompts (e.g. the prompts library) so this prompt always waits for
136
- // fresh user input. In non-TTY / piped mode, those queued lines are
137
- // intentional input and must be consumed in order.
138
- if (INTERACTIVE) {
139
- _queue = [];
140
- }
141
- if (_queue.length) return Promise.resolve(_queue.shift().trim());
142
- return new Promise(resolve => _waiters.push((line) => resolve(line.trim())));
90
+ const rl = readline.createInterface({ input: process.stdin, output: process.stdout });
91
+ return new Promise(resolve => rl.question(question, ans => { rl.close(); resolve(ans.trim()); }));
143
92
  }
144
93
 
145
94
  async function confirm(question, defaultYes = true) {
146
- if (INTERACTIVE) {
147
- const { value } = await prompts({
148
- type: 'confirm',
149
- name: 'value',
150
- message: question,
151
- initial: defaultYes
152
- });
153
- if (value === undefined) process.exit(130);
154
- return value;
155
- }
156
95
  const hint = defaultYes ? '[Y/n]' : '[y/N]';
157
96
  const ans = (await prompt(`${question} ${hint} `)).toLowerCase();
158
97
  if (!ans) return defaultYes;
159
98
  return ans.startsWith('y');
160
99
  }
161
100
 
162
- async function promptText(question, defaultValue = '') {
163
- if (INTERACTIVE) {
164
- const { value } = await prompts({
165
- type: 'text',
166
- name: 'value',
167
- message: question,
168
- initial: defaultValue
169
- });
170
- if (value === undefined) process.exit(130);
171
- return value.trim();
172
- }
173
- const ans = (await prompt(`${question} [${defaultValue}]: `)).trim();
174
- return ans || defaultValue;
175
- }
176
-
177
- async function promptTextMandatory(question, defaultValue = '') {
178
- if (INTERACTIVE) {
179
- if (defaultValue) {
180
- const { keep } = await prompts({
181
- type: 'confirm',
182
- name: 'keep',
183
- message: `${question} (use "${defaultValue}"?)`,
184
- initial: true
185
- });
186
- if (keep === undefined) process.exit(130);
187
- if (keep) return defaultValue;
188
- }
189
- const { value } = await prompts({
190
- type: 'text',
191
- name: 'value',
192
- message: question
193
- });
194
- if (value === undefined) process.exit(130);
195
- const trimmed = value.trim();
196
- if (trimmed) return trimmed;
197
- if (defaultValue) return defaultValue;
198
- return promptTextMandatory(question, defaultValue);
199
- }
200
- // Non-TTY: keep asking until non-empty.
201
- for (;;) {
202
- const ans = (await prompt(`${question}: `)).trim();
203
- if (ans) return ans;
204
- if (defaultValue) return defaultValue;
205
- console.log('Please provide a value.');
206
- }
207
- }
208
-
209
- async function select(label, choices, defaultValue) {
210
- if (INTERACTIVE) {
211
- const initial = choices.findIndex(c => c.value === defaultValue);
212
- const { picked } = await prompts({
213
- type: 'select',
214
- name: 'picked',
215
- message: label,
216
- choices: choices.map(c => ({ title: c.title, value: c.value, description: c.description })),
217
- initial: initial === -1 ? 0 : initial
218
- });
219
- if (picked === undefined) process.exit(130);
220
- return picked;
221
- }
222
- // Non-TTY fallback: return default.
223
- return defaultValue;
224
- }
225
-
226
101
  async function selectLanguage(label, defaultCode = 'en') {
227
102
  if (INTERACTIVE) {
228
103
  const choices = LANGUAGES.map(l => ({
@@ -427,169 +302,49 @@ function renderAdapters({ kitRoot, projectRoot, targets, profiles }) {
427
302
  return results;
428
303
  }
429
304
 
430
- // Parse --key value and --flag from an argv slice. Returns { flags, positional }.
431
- function parseArgs(args) {
432
- const flags = {};
433
- const positional = [];
434
- for (let i = 0; i < args.length; i++) {
435
- const a = args[i];
436
- if (a.startsWith('--')) {
437
- const key = a.slice(2);
438
- if (key.includes('=')) {
439
- const [k, v] = key.split('=', 2);
440
- flags[k] = v;
441
- } else if (i + 1 < args.length && !args[i + 1].startsWith('--')) {
442
- flags[key] = args[++i];
443
- } else {
444
- flags[key] = true;
445
- }
446
- } else {
447
- positional.push(a);
448
- }
449
- }
450
- return { flags, positional };
451
- }
452
-
453
- function resolveProfiles(flags) {
454
- if (!flags.profiles) return null;
455
- const codes = flags.profiles.split(',').map(s => s.trim()).filter(Boolean);
456
- const resolved = [];
457
- for (const c of codes) {
458
- const p = PROFILES.find(p => p.code === c);
459
- if (p) resolved.push(p);
460
- else console.log(`⚠ perfil desconhecido: "${c}" — ignorado`);
461
- }
462
- if (resolved.length === 0) return null;
463
- return resolved;
464
- }
465
-
466
- function resolveTargets(flags) {
467
- if (!flags.targets) return null;
468
- const codes = flags.targets.split(',').map(s => s.trim()).filter(Boolean);
469
- const resolved = [];
470
- for (const c of codes) {
471
- const t = TARGETS.find(t => t.code === c);
472
- if (t) resolved.push(t);
473
- else console.log(`⚠ target desconhecido: "${c}" — ignorado`);
474
- }
475
- if (resolved.length === 0) return null;
476
- return resolved;
477
- }
478
-
479
- function resolveLang(flags) {
480
- if (!flags.lang) return null;
481
- const code = flags.lang.trim();
482
- if (/^[A-Za-z]{2,3}(-[A-Za-z0-9]{2,8})?$/.test(code)) return code;
483
- console.log(`⚠ código de idioma inválido: "${code}" — usando pt-BR`);
484
- return null;
485
- }
486
-
487
- function resolveName(flags) {
488
- if (flags.name) return flags.name.trim();
489
- if (flags.yes) {
490
- try { return execSync('git config user.name', { encoding: 'utf-8' }).trim(); } catch (_) {}
491
- return process.env.USER || process.env.USERNAME || 'Developer';
492
- }
493
- return null;
494
- }
495
-
496
- // --yes quick install: everything on. All harnesses + all overlays, so
497
- // `npx wize-dev-kit install --yes` is a true one-shot full install.
498
- function defaultProfiles() {
499
- return PROFILES.slice();
500
- }
501
-
502
- function defaultTargets() {
503
- return TARGETS.slice();
504
- }
505
-
506
305
  async function cmdInstall(args) {
507
306
  const cwd = process.cwd();
508
- const { flags } = parseArgs(args);
509
- const dryRun = !!flags['dry-run'];
510
- const nonInteractive = !!flags.yes;
511
-
512
307
  console.log(logo());
513
- if (dryRun) console.log('[DRY-RUN] Nenhum arquivo será modificado.\n');
514
- console.log('Instalando Wize Development Kit em:', cwd);
515
-
308
+ console.log('Installing Wize Development Kit into:', cwd);
516
309
  if (!isGitRepo(cwd)) {
517
- console.log('\n⚠ não é um repositório git. Inicialize o git primeiro ou prossiga por sua conta e risco.');
518
- if (nonInteractive) {
519
- console.log('Modo não-interativo: abortando. Use --yes apenas em repositórios git.');
520
- process.exit(1);
521
- }
522
- const ok = await confirm('Continuar mesmo assim?', false);
310
+ console.log('\n⚠ not a git repo. Initialize git first or proceed at your own risk.');
311
+ const ok = await confirm('Continue anyway?', false);
523
312
  if (!ok) process.exit(1);
524
313
  }
525
314
 
526
315
  const detection = detectBrownfield(cwd);
527
316
  if (detection.brownfield) {
528
- console.log(`\nSinais de brownfield detectados: ${detection.signals.join(', ')}`);
529
- } else {
530
- console.log('\nRepositório greenfield detectado.');
531
- }
532
-
533
- // Resolve flags or fall back to interactive prompts.
534
- let project_name, profiles, targets, communication_language, document_output_language, user_name, wantsGitignore;
535
-
536
- if (nonInteractive) {
537
- project_name = flags.name ? resolveName(flags) : (path.basename(cwd));
538
- profiles = resolveProfiles(flags) || defaultProfiles();
539
- targets = resolveTargets(flags) || defaultTargets();
540
- communication_language = resolveLang(flags) || 'pt-BR';
541
- document_output_language = resolveLang(flags) || communication_language;
542
- user_name = resolveName(flags);
543
- wantsGitignore = true;
317
+ console.log(`\nBrownfield signals detected: ${detection.signals.join(', ')}`);
544
318
  } else {
545
- project_name = (await promptText(`Nome do projeto`, path.basename(cwd))) || path.basename(cwd);
546
- profiles = await multiSelect('Selecione o(s) perfil(is) para instalar', PROFILES);
547
- targets = await multiSelect('Selecione o(s) IDE target(s)', TARGETS);
548
-
549
- communication_language = await selectLanguage(
550
- 'Idioma de comunicação (como os agentes vão falar com você no chat)',
551
- 'pt-BR'
552
- );
553
- document_output_language = await selectLanguage(
554
- `Idioma dos documentos (idioma usado nos arquivos gerados; ENTER para "${communication_language}")`,
555
- communication_language
556
- );
557
-
558
- const defaultName = (os.userInfo().username || '').trim();
559
- user_name = await promptTextMandatory(
560
- 'Como os agentes devem te chamar?',
561
- defaultName
562
- );
563
-
564
- wantsGitignore = await confirm(
565
- 'Adicionar as entradas sugeridas ao .gitignore (user.toml + scratch + outputs de adapters)?',
566
- true
567
- );
568
- }
569
-
570
- // Show resolved config.
571
- console.log(`\nConfiguração:`);
572
- console.log(` Projeto: ${project_name}`);
573
- console.log(` Perfis: ${profiles.map(p => p.code).join(', ')}`);
574
- console.log(` IDE targets: ${targets.map(t => t.code).join(', ')}`);
575
- console.log(` Idioma comm: ${communication_language}`);
576
- console.log(` Idioma docs: ${document_output_language}`);
577
- if (user_name) console.log(` Nome: ${user_name}`);
578
- if (dryRun) console.log(` Modo: dry-run`);
579
-
580
- if (dryRun) {
581
- console.log('\n[DRY-RUN] Criaria estrutura .wize/:');
582
- for (const dir of WIZE_DIRS) console.log(` - ${dir}/`);
583
- console.log(`[DRY-RUN] Escreveria .wize/config/project.toml`);
584
- console.log(`[DRY-RUN] Escreveria .wize/config/user.toml`);
585
- console.log(`[DRY-RUN] Escreveria .wize/config/tea.toml`);
586
- if (wantsGitignore) console.log(`[DRY-RUN] Atualizaria .gitignore`);
587
- console.log(`\n[DRY-RUN] Geraria adapters para: ${targets.map(t => t.code).join(', ')}`);
588
- console.log('\n[DRY-RUN] Concluído. Nenhum arquivo foi modificado.');
589
- return;
590
- }
591
-
592
- console.log('\nCriando estrutura .wize/...');
319
+ console.log('\nGreenfield repo detected.');
320
+ }
321
+
322
+ const project_name = (await prompt(`Project name [${path.basename(cwd)}]: `)) || path.basename(cwd);
323
+ const profiles = await multiSelect('Select profile(s) to install', PROFILES);
324
+ const targets = await multiSelect('Select IDE target(s)', TARGETS);
325
+
326
+ const communication_language = await selectLanguage(
327
+ 'Communication language (how agents will talk to you in chat)',
328
+ 'en'
329
+ );
330
+ const document_output_language = await selectLanguage(
331
+ `Document output language (language used in generated files; ENTER for "${communication_language}")`,
332
+ communication_language
333
+ );
334
+
335
+ // Personal touch — the user_name lands in .wize/config/user.toml (per-developer).
336
+ const defaultName = (os.userInfo().username || '').trim();
337
+ const user_name = (await prompt(
338
+ `How should the agents call you? [${defaultName || 'leave blank'}]: `
339
+ )).trim() || defaultName;
340
+
341
+ // Gitignore — opt-in, idempotent.
342
+ const wantsGitignore = await confirm(
343
+ 'Add the suggested entries to .gitignore (user.toml + scratch + generated adapter outputs)?',
344
+ true
345
+ );
346
+
347
+ console.log('\nCreating .wize/ skeleton...');
593
348
  for (const dir of WIZE_DIRS) mkdirp(path.join(cwd, dir));
594
349
 
595
350
  writeIfMissing(path.join(cwd, '.wize/config/project.toml'), projectToml({
@@ -598,26 +353,20 @@ async function cmdInstall(args) {
598
353
  writeIfMissing(path.join(cwd, '.wize/config/user.toml'), generateUserToml({ name: user_name }));
599
354
  writeIfMissing(path.join(cwd, '.wize/config/tea.toml'), teaToml());
600
355
 
601
- console.log('✓ .wize/ criado');
602
- console.log(`✓ perfis: ${profiles.map(p => p.code).join(', ')}`);
356
+ console.log('✓ .wize/ created');
357
+ console.log(`✓ profiles: ${profiles.map(p => p.code).join(', ')}`);
603
358
  console.log(`✓ ide targets: ${targets.map(t => t.code).join(', ')}`);
604
- if (user_name) console.log(`✓ user.toml: agentes vão te chamar de "${user_name}"`);
605
-
606
- if (profiles.some(p => p.code === 'security-overlay')) {
607
- console.log('\n⚠ security-overlay selecionado — uso autorizado apenas.');
608
- console.log(' Uso autorizado. Você é responsável por obter permissão antes de testar alvos que não são seus.');
609
- console.log(' O kit detecta alvos fora do scope.md e recusa automaticamente; ainda assim, use com responsabilidade.');
610
- }
359
+ if (user_name) console.log(`✓ user.toml: agents will call you "${user_name}"`);
611
360
 
612
361
  if (wantsGitignore) {
613
362
  const r = applyGitignore(cwd);
614
- if (r.changed) console.log(`✓ .gitignore ${r.mode} com o bloco wize-dev-kit`);
615
- else console.log(`= .gitignore já está atualizado`);
363
+ if (r.changed) console.log(`✓ .gitignore ${r.mode} with the wize-dev-kit block`);
364
+ else console.log(`= .gitignore already up to date`);
616
365
  } else {
617
- console.log('= .gitignore não modificado (você optou por não adicionar as entradas sugeridas)');
366
+ console.log('= .gitignore untouched (you opted out of suggested entries)');
618
367
  }
619
368
 
620
- console.log('\nGerando adapters IDE...');
369
+ console.log('\nGenerating IDE adapters...');
621
370
  const renderResults = renderAdapters({
622
371
  kitRoot: KIT_ROOT,
623
372
  projectRoot: cwd,
@@ -625,191 +374,33 @@ async function cmdInstall(args) {
625
374
  profiles
626
375
  });
627
376
  for (const r of renderResults) {
628
- if (r.skipped) console.log(` - ${r.code}: pulado (${r.reason})`);
629
- else if (r.written) console.log(` ✓ ${r.code}: ${r.written} skill(s) emitidas`);
377
+ if (r.skipped) console.log(` - ${r.code}: skipped (${r.reason})`);
378
+ else if (r.written) console.log(` ✓ ${r.code}: ${r.written} skill(s) emitted`);
630
379
  else if (r.error) console.log(` ✖ ${r.code}: ${r.error}`);
631
380
  }
632
381
 
633
382
  if (detection.brownfield) {
634
- if (process.env.WIZE_SKIP_BASELINE === '1') {
635
- console.log('\nWIZE_SKIP_BASELINE=1 — baseline não será executado.');
636
- } else if (!INTERACTIVE || nonInteractive) {
637
- console.log('\nInstalação não-interativa detectada; executando baseline rápido...');
638
- cmdDocumentProject({ kitRoot: KIT_ROOT, projectRoot: cwd, args: ['quick'], opts: { log: console.log } });
639
- } else {
640
- const mode = await select(
641
- 'Documentar o repositório existente agora?',
642
- [
643
- { title: 'Baseline rápido (padrão, 6 arquivos)', value: 'quick' },
644
- { title: 'Scan inicial (documentos de padrão + condicionais)', value: 'initial_scan' },
645
- { title: 'Rescan completo (arquiva estado anterior, re-executa)', value: 'full_rescan' },
646
- { title: 'Pular documentação por enquanto', value: 'skip' }
647
- ],
648
- 'quick'
649
- );
650
- if (mode !== 'skip') {
651
- cmdDocumentProject({ kitRoot: KIT_ROOT, projectRoot: cwd, args: [mode], opts: { log: console.log } });
652
- } else {
653
- console.log('\nDocumentação pulada. Execute `wize-dev-kit document-project` depois.');
654
- }
383
+ const baseline = await confirm('\nRun `wize-document-project` to baseline the existing repo now?', true);
384
+ if (baseline) {
385
+ console.log('(stub) Pepper + Peggy would now produce the baseline docs in .wize/knowledge/document-project/.');
655
386
  }
656
387
  }
657
388
 
658
- console.log('\n──────────────────────────────────────────────────────────────');
659
- console.log('Concluído.');
660
- console.log('');
661
- console.log('⚠ Reinicie seu IDE — muitos harnesses carregam skills apenas na inicialização.');
662
- console.log(composeOnboarding(detection, profiles));
663
- console.log('');
664
- console.log('Mantenha o kit sincronizado:');
665
- console.log(' • `npx wize-dev-kit update` atualizar adapters após nova versão do kit');
666
- console.log(' • `npx wize-dev-kit sync` re-renderizar adapters após editar config');
667
- console.log(' • `npx wize-dev-kit agent list | create | edit <code>` gerenciar agentes');
668
- console.log('──────────────────────────────────────────────────────────────');
669
- }
670
-
671
- // AGENTS.md signature — used to detect whether the file was generated by the kit.
672
- const AGENTS_SIGNATURE = '# Agents — Wize Development Kit';
673
-
674
- function isKitAgentsMd(filePath) {
675
- if (!fs.existsSync(filePath)) return false;
676
- try {
677
- const head = fs.readFileSync(filePath, 'utf-8').slice(0, 200);
678
- return head.includes(AGENTS_SIGNATURE);
679
- } catch { return false; }
680
- }
681
-
682
- // Delete wize-* entries from an adapter target directory. Returns count of
683
- // removed items (files + dirs). Safe: only deletes entries whose name starts
684
- // with "wize-".
685
- function cleanAdapterTarget(targetDir) {
686
- if (!fs.existsSync(targetDir)) return 0;
687
- let count = 0;
688
- let entries;
689
- try { entries = fs.readdirSync(targetDir); } catch { return 0; }
690
- for (const name of entries) {
691
- if (!name.startsWith('wize-')) continue;
692
- const full = path.join(targetDir, name);
693
- try {
694
- fs.rmSync(full, { recursive: true, force: true });
695
- count++;
696
- } catch { /* skip permission errors */ }
697
- }
698
- return count;
389
+ console.log('\nDone. Activate Wizer in your IDE and say: "Brief me on this project."');
699
390
  }
700
391
 
701
- async function cmdUninstall(args) {
392
+ async function cmdUninstall() {
702
393
  const cwd = process.cwd();
703
- const { flags } = parseArgs(args || []);
704
- const dryRun = !!flags['dry-run'];
705
-
706
- if (dryRun) console.log('[DRY-RUN] Nenhum arquivo será removido.\n');
707
-
708
- const wizeDir = path.join(cwd, '.wize');
709
- if (!fs.existsSync(wizeDir)) {
710
- console.log('Nenhuma pasta .wize/ encontrada aqui.');
394
+ const dir = path.join(cwd, '.wize');
395
+ if (!fs.existsSync(dir)) {
396
+ console.log('No .wize/ folder found here.');
711
397
  return;
712
398
  }
713
-
714
- // Read project.toml to discover which IDE targets were configured.
715
- let ideTargets = [];
716
- try {
717
- const cfg = loadProjectConfig(cwd);
718
- ideTargets = (cfg.install && cfg.install.ide_targets) || [];
719
- } catch { /* project.toml may be missing or corrupt */ }
720
-
721
- // Build the list of what would be removed.
722
- const toRemove = [];
723
-
724
- // 1. Adapter target dirs (wize-* entries).
725
- const adapterDirs = [];
726
- for (const code of ideTargets) {
727
- const dir = adapterTargetPath(code, cwd);
728
- if (!dir) continue;
729
- if (!fs.existsSync(dir)) continue;
730
- let entries;
731
- try { entries = fs.readdirSync(dir); } catch { continue; }
732
- for (const name of entries) {
733
- if (!name.startsWith('wize-')) continue;
734
- adapterDirs.push({ target: code, dir, name, full: path.join(dir, name) });
735
- }
736
- }
737
-
738
- // 2. .wize/ directory.
739
- toRemove.push({ kind: 'diretório', path: wizeDir, label: '.wize/' });
740
-
741
- // 3. AGENTS.md if kit-generated.
742
- const agentsMd = path.join(cwd, 'AGENTS.md');
743
- if (isKitAgentsMd(agentsMd)) {
744
- toRemove.push({ kind: 'arquivo', path: agentsMd, label: 'AGENTS.md' });
745
- }
746
-
747
- // Show what will be removed.
748
- if (adapterDirs.length > 0) {
749
- console.log('Arquivos de adapter que serão removidos:');
750
- const byTarget = {};
751
- for (const a of adapterDirs) {
752
- byTarget[a.target] = byTarget[a.target] || [];
753
- byTarget[a.target].push(a.name);
754
- }
755
- for (const [code, names] of Object.entries(byTarget)) {
756
- console.log(` ${code}: ${names.length} entrada(s) (${names.slice(0, 5).join(', ')}${names.length > 5 ? '...' : ''})`);
757
- }
758
- } else {
759
- console.log('Nenhum arquivo de adapter wize-* encontrado.');
760
- }
761
-
762
- console.log(`\nSerá removido:`);
763
- for (const item of toRemove) {
764
- console.log(` - ${item.label} (${item.kind})`);
765
- }
766
- if (adapterDirs.length > 0) {
767
- console.log(` - ${adapterDirs.length} entrada(s) wize-* nos diretórios de adapter`);
768
- }
769
-
770
- if (dryRun) {
771
- console.log('\n[DRY-RUN] Concluído. Nenhum arquivo foi removido.');
772
- return;
773
- }
774
-
775
- const totalItems = toRemove.length + adapterDirs.length;
776
- if (totalItems === 0) {
777
- console.log('\nNada para remover.');
778
- return;
779
- }
780
-
781
- const ok = await confirm(`\nRemover ${totalItems} item(ns)? O código-fonte do seu projeto não será afetado.`, false);
782
- if (!ok) {
783
- console.log('Cancelado.');
784
- return;
785
- }
786
-
787
- // Capture AGENTS.md status before deletion.
788
- const hadAgentsMd = isKitAgentsMd(agentsMd);
789
-
790
- // Delete adapter entries first.
791
- let adapterCount = 0;
792
- for (const a of adapterDirs) {
793
- try {
794
- fs.rmSync(a.full, { recursive: true, force: true });
795
- adapterCount++;
796
- } catch (err) {
797
- console.log(` ✖ erro ao remover ${a.name}: ${err.message}`);
798
- }
799
- }
800
-
801
- // Delete .wize/ and AGENTS.md.
802
- for (const item of toRemove) {
803
- try {
804
- fs.rmSync(item.path, { recursive: true, force: true });
805
- } catch (err) {
806
- console.log(` ✖ erro ao remover ${item.label}: ${err.message}`);
807
- }
808
- }
809
-
810
- console.log(`\n✓ Removido: .wize/ + ${adapterCount} entrada(s) de adapter`);
811
- if (hadAgentsMd) console.log('✓ AGENTS.md removido');
812
- console.log('\nO código-fonte do seu projeto não foi alterado.');
399
+ const ok = await confirm(`Remove ${dir}? Your project source code is not touched.`, false);
400
+ if (!ok) return;
401
+ fs.rmSync(dir, { recursive: true, force: true });
402
+ console.log('Removed .wize/.');
403
+ console.log('(stub) IDE adapter files (.claude/skills/wize-*, .cursor/rules/wize-*) would be cleaned here.');
813
404
  }
814
405
 
815
406
  function cmdList() {
@@ -827,10 +418,9 @@ function cmdList() {
827
418
  ['wize-agent-dev', 'Shuri']
828
419
  ];
829
420
  for (const [code, name] of list) console.log(` ${code.padEnd(36)} ${name}`);
830
- console.log(` ${'wize-sec-red-teamer'.padEnd(36)} Natasha Romanoff (security-overlay, opt-in)`);
831
421
 
832
422
  console.log('\nWorkflows directories:');
833
- const phases = ['1-analysis', '2-plan', '3-solutioning', '4-implementation'];
423
+ const phases = ['1-analysis', '2-plan-workflows', '3-solutioning', '4-implementation'];
834
424
  for (const phase of phases) {
835
425
  const dir = path.join(KIT_ROOT, 'src/method-skills', phase);
836
426
  if (!fs.existsSync(dir)) continue;
@@ -842,18 +432,17 @@ function cmdList() {
842
432
  }
843
433
 
844
434
  function cmdSync() {
845
- return cmdSyncReal({ kitRoot: KIT_ROOT, projectRoot: process.cwd() });
435
+ console.log('(stub) Sync would regenerate IDE adapter files for active targets in .wize/config/project.toml.');
846
436
  }
847
437
 
848
438
  function cmdAgent(args) {
849
439
  const sub = args[0] || 'list';
850
- const rest = args.slice(1);
851
- const ctx = { kitRoot: KIT_ROOT, projectRoot: process.cwd() };
852
- if (sub === 'list') return cmdAgentList(ctx);
853
- if (sub === 'create') return cmdAgentCreate(ctx);
854
- if (sub === 'edit') return cmdAgentEdit({ ...ctx, code: rest[0] });
440
+ if (sub === 'list') return cmdList();
441
+ if (sub === 'create') {
442
+ console.log('(stub) Interactive agent creation. See src/builder-skills/wize-create-agent/workflow.md.');
443
+ return;
444
+ }
855
445
  console.log(`Unknown agent subcommand: ${sub}`);
856
- console.log('Available: list | create | edit <code>');
857
446
  }
858
447
 
859
448
  function cmdWorkflow(args) {
@@ -870,39 +459,21 @@ function cmdValidate() {
870
459
  require('./validators/run-all.js')(KIT_ROOT);
871
460
  }
872
461
 
873
- // Commands worth nudging the user about when a newer version exists. Skipped
874
- // for `update` (already updating), `install` (already setting up), `uninstall`
875
- // (already leaving), `validate` (developer-tool), and `version` (the user is
876
- // already asking about versions).
877
- const HINT_COMMANDS = new Set(['list', 'sync', 'agent', 'workflow', 'help', 'doctor', 'document-project']);
878
-
879
462
  async function main() {
880
463
  const [cmd, ...rest] = process.argv.slice(2);
881
464
  if (!cmd || cmd === 'help' || cmd === '--help' || cmd === '-h') {
882
- await printUpdateHintIfAny(KIT_VERSION);
883
465
  console.log(HELP);
884
466
  return;
885
467
  }
886
- if (HINT_COMMANDS.has(cmd)) {
887
- await printUpdateHintIfAny(KIT_VERSION);
888
- }
889
468
  switch (cmd) {
890
469
  case 'install': return cmdInstall(rest);
891
- case 'update': return cmdUpdate({ kitRoot: KIT_ROOT, projectRoot: process.cwd() });
892
- case 'uninstall': return cmdUninstall(rest);
470
+ case 'update': console.log('(stub) Update: diff + preserve customizations. Not yet implemented.'); return;
471
+ case 'uninstall': return cmdUninstall();
893
472
  case 'list': return cmdList();
894
473
  case 'sync': return cmdSync();
895
474
  case 'agent': return cmdAgent(rest);
896
475
  case 'workflow': return cmdWorkflow(rest);
897
476
  case 'validate': return cmdValidate();
898
- case 'doctor': return cmdDoctor({ kitRoot: KIT_ROOT, projectRoot: process.cwd() });
899
- case 'document-project':
900
- return cmdDocumentProject({
901
- kitRoot: KIT_ROOT,
902
- projectRoot: process.cwd(),
903
- args: rest,
904
- opts: { log: console.log }
905
- });
906
477
  case 'version':
907
478
  case '--version':
908
479
  case '-v':