@wrongstack/cli 1.0.35 → 1.0.37

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 (168) hide show
  1. package/dist/{acp-T77EAEDB.js → acp-HCGUTFNE.js} +11 -8
  2. package/dist/ascii-mode-B6PKLRHM.js +8 -0
  3. package/dist/{audit-KCBTHUQI.js → audit-NH7NUKBV.js} +3 -2
  4. package/dist/{auth-M6LXZTDA.js → auth-ANOVZVHE.js} +12 -11
  5. package/dist/auto-discover-providers-V75ICIBG.js +8 -0
  6. package/dist/{automation-MCDFCIMV.js → automation-O7ZRZSFS.js} +20 -4
  7. package/dist/{bench-MMZHFHDL.js → bench-NDYES33Y.js} +3 -2
  8. package/dist/boot/governance-evidence-candidate.d.ts +1 -1
  9. package/dist/boot/system-prompt-menu.d.ts +7 -0
  10. package/dist/boot/tui-settings-adapter.d.ts +0 -12
  11. package/dist/{boot-auto-thin-YMAZI3QL.js → boot-auto-thin-7D4OVEWA.js} +5 -4
  12. package/dist/boot-provider-selection.d.ts +9 -0
  13. package/dist/{chronicle-PBJS7BN6.js → chronicle-WBK3TJRB.js} +2 -1
  14. package/dist/{chunk-R4QGL6GB.js → chunk-2MV474XR.js} +1 -1
  15. package/dist/{chunk-AFOH6CHO.js → chunk-3EXRPTAU.js} +1 -1
  16. package/dist/{chunk-2EZ2DHOW.js → chunk-3R3OADC5.js} +2 -2
  17. package/dist/{chunk-RKU66D2O.js → chunk-57PSSEBR.js} +1 -1
  18. package/dist/{chunk-2CMMWRQH.js → chunk-5TRZZHMN.js} +2 -2
  19. package/dist/{chunk-RWNI5OWT.js → chunk-6KJU6POA.js} +6 -6
  20. package/dist/{chunk-AKESWZH5.js → chunk-6VPWQ4TG.js} +2 -2
  21. package/dist/{chunk-CJSHS2K7.js → chunk-75OLD563.js} +1 -1
  22. package/dist/{chunk-4UWCMBPG.js → chunk-76JE54WD.js} +7 -5
  23. package/dist/{chunk-7BNBD4PE.js → chunk-7IY2UTBE.js} +2 -2
  24. package/dist/{chunk-6Z6C6ZHH.js → chunk-AWRZWPJ3.js} +20 -26
  25. package/dist/{chunk-TXAFIERF.js → chunk-BAWRRA6O.js} +2 -2
  26. package/dist/{chunk-DAKVBMD4.js → chunk-BCKVNORU.js} +1 -1
  27. package/dist/{chunk-4BX2YDTQ.js → chunk-BIGSVBPI.js} +45 -4
  28. package/dist/{chunk-CZTXF6HY.js → chunk-BJ4LDJ4H.js} +1 -1
  29. package/dist/{chunk-KMU7GF7X.js → chunk-C2BBH4S4.js} +2 -2
  30. package/dist/chunk-C4654QI2.js +8 -0
  31. package/dist/{chunk-M4G5FO7F.js → chunk-C5JP6DJN.js} +1 -1
  32. package/dist/{chunk-LDV4ERNV.js → chunk-CIGEY7NU.js} +5 -5
  33. package/dist/{chunk-WTJDSTYD.js → chunk-CVVQ5NCN.js} +5 -5
  34. package/dist/{chunk-D3K4NYQL.js → chunk-DXHQFV5V.js} +1 -1
  35. package/dist/{chunk-SUDNPYWD.js → chunk-FM7DPSYA.js} +2 -2
  36. package/dist/{chunk-YL4KCHZG.js → chunk-FPUB5WWP.js} +1 -1
  37. package/dist/{chunk-P3Q3KMFH.js → chunk-FUJHWQV4.js} +1 -1
  38. package/dist/{chunk-ERX4BLKP.js → chunk-GFQH77OH.js} +1 -1
  39. package/dist/{chunk-DIOODAYM.js → chunk-H53EXXAU.js} +3 -3
  40. package/dist/{chunk-F5DCFAKI.js → chunk-HKMOIIPQ.js} +1 -1
  41. package/dist/{chunk-AUQDGU5D.js → chunk-HQBY6OFT.js} +1 -1
  42. package/dist/{chunk-6SIUTX75.js → chunk-IJLIAPCW.js} +1 -2
  43. package/dist/{chunk-QD544J2B.js → chunk-JTTV2EVA.js} +1 -1
  44. package/dist/{chunk-UKP7H2U4.js → chunk-KHFFJ2LC.js} +1 -1
  45. package/dist/{chunk-4TVYGG6G.js → chunk-MKM4X2AM.js} +1 -1
  46. package/dist/chunk-ML3US333.js +61 -0
  47. package/dist/{chunk-HLSHFXTO.js → chunk-NL2ABOAS.js} +2 -2
  48. package/dist/{chunk-Q7E3BPDU.js → chunk-OGVSKS4Q.js} +1 -1
  49. package/dist/chunk-OZCYZYN2.js +3708 -0
  50. package/dist/{chunk-EWKESL4L.js → chunk-P24ZPPYH.js} +1 -1
  51. package/dist/chunk-PY2LMG2V.js +1 -0
  52. package/dist/{chunk-CSAPOCBP.js → chunk-QC6CLAK7.js} +1 -1
  53. package/dist/{chunk-HXJYHAR4.js → chunk-QVITQ425.js} +1 -1
  54. package/dist/{chunk-GZSKLXYG.js → chunk-RAWHRRUJ.js} +10 -10
  55. package/dist/{chunk-PA4VBCXS.js → chunk-RBZVDWTL.js} +1 -1
  56. package/dist/{chunk-YMXXOOFN.js → chunk-SPSHEZ46.js} +1 -1
  57. package/dist/{chunk-TWSQTQKR.js → chunk-T4TGMTH2.js} +3 -3
  58. package/dist/{chunk-LKFKO4JW.js → chunk-TZPKOS5G.js} +3 -3
  59. package/dist/{chunk-X4LW5CZM.js → chunk-UBDLNC3N.js} +1 -1
  60. package/dist/{chunk-SDJCLEK6.js → chunk-UFRVTBV6.js} +1 -1
  61. package/dist/{chunk-VCYZ3WZV.js → chunk-UOQPDZ5H.js} +1 -1
  62. package/dist/{chunk-PZQBGUVZ.js → chunk-UVF3BGET.js} +1 -1
  63. package/dist/{chunk-HHRYIDOW.js → chunk-VAQXOZKP.js} +34 -7
  64. package/dist/{chunk-4XCBEUBX.js → chunk-VHC47E7U.js} +1 -1
  65. package/dist/{chunk-LKPEBZBE.js → chunk-VI2HE4A5.js} +1 -1
  66. package/dist/chunk-W23PY4IJ.js +44 -0
  67. package/dist/{chunk-AT2A7RJZ.js → chunk-WDXNBYGD.js} +1 -1
  68. package/dist/{chunk-NRXWOMK7.js → chunk-XT3NAHRX.js} +1 -1
  69. package/dist/{chunk-ZYACRPLN.js → chunk-ZCXZGYO5.js} +6 -3
  70. package/dist/{chunk-65VNCAF6.js → chunk-ZNNFEKDZ.js} +2 -2
  71. package/dist/{chunk-CDY4D5QK.js → chunk-ZTSTMFYW.js} +2 -2
  72. package/dist/{chunk-YTEOAWOJ.js → chunk-ZXX3MJRL.js} +1 -1
  73. package/dist/{cli-context-II57EHD2.js → cli-context-V6NKFU2X.js} +166 -100
  74. package/dist/{cli-main-YR2WJCPL.js → cli-main-LHQTVOYW.js} +963 -246
  75. package/dist/{config-transfer-VOIFY7U4.js → config-transfer-Y7XJMJRN.js} +8 -5
  76. package/dist/{diag-doctor-BIZAFIAT.js → diag-doctor-5SVYK2DR.js} +5 -4
  77. package/dist/execute-deps.d.ts +8 -0
  78. package/dist/{execution-IBAZ2EIU.js → execution-BAP566QC.js} +103 -33
  79. package/dist/{export-VVRIOWFV.js → export-W27PTU6Y.js} +3 -2
  80. package/dist/fleet/host-director-setup.d.ts +2 -0
  81. package/dist/fleet/host-skill-companion.d.ts +73 -0
  82. package/dist/fleet/host.d.ts +1 -0
  83. package/dist/fleet/skill-companion-policy.d.ts +33 -0
  84. package/dist/{governance-RYSHV675.js → governance-A32M4ILK.js} +2 -1
  85. package/dist/{hq-5OIEKB4V.js → hq-JD5AZVMG.js} +8 -7
  86. package/dist/hq-server/snapshot.d.ts +1 -1
  87. package/dist/hq-server/socket-credentials.d.ts +1 -1
  88. package/dist/hq-server/ws.d.ts +1 -1
  89. package/dist/{hq-server-DU3ZH3X7.js → hq-server-BI23EPM7.js} +7 -5
  90. package/dist/{hq-service-LYZV7EK7.js → hq-service-TQNPIRHL.js} +8 -7
  91. package/dist/hq-ttl-RKRF7AQX.js +8 -0
  92. package/dist/{hq-tunnel-NIJ5EP2Y.js → hq-tunnel-6VU4IWV4.js} +2 -1
  93. package/dist/{import-claude-code-AYG24RG2.js → import-claude-code-D4F6ZE7I.js} +6 -5
  94. package/dist/index.js +9 -8
  95. package/dist/{init-DRMMFG2G.js → init-5PLABNLR.js} +2 -1
  96. package/dist/ip-allowlist-YDOFO7XJ.js +10 -0
  97. package/dist/{kanban-run-mirror-22HQ5FNG.js → kanban-run-mirror-SZ3S3S3Z.js} +3 -2
  98. package/dist/kanban-supervisor-55XPUHAM.js +8 -0
  99. package/dist/live-settings-input.d.ts +8 -0
  100. package/dist/{mailbox-serve-S536N66F.js → mailbox-serve-MMQCHOHI.js} +5 -3
  101. package/dist/{mcp-LBS45HWZ.js → mcp-2XWBJEQN.js} +4 -3
  102. package/dist/{modeldiag-NEPTLFZW.js → modeldiag-ERXYJODJ.js} +8 -7
  103. package/dist/{per-subcommand-help-VKPV3OEY.js → per-subcommand-help-D6J4ZXW2.js} +4 -3
  104. package/dist/{permissions-PL27UHYD.js → permissions-6YJ64W65.js} +3 -2
  105. package/dist/plugin-config.d.ts +6 -0
  106. package/dist/{plugin-usage-3TZGROK7.js → plugin-usage-TYF5HY4K.js} +6 -5
  107. package/dist/{plugins-ITH4SLO6.js → plugins-XGAXDLPT.js} +6 -5
  108. package/dist/pre-launch/launch-prompts.d.ts +21 -2
  109. package/dist/pre-launch.d.ts +1 -1
  110. package/dist/{project-AOQI5XTK.js → project-V5KNTLV4.js} +2 -1
  111. package/dist/{project-manifest-FTFDCCTZ.js → project-manifest-HXCID644.js} +3 -2
  112. package/dist/{project-picker-NZYJKQQC.js → project-picker-FUSLXKSA.js} +4 -3
  113. package/dist/{projects-T4CZCA25.js → projects-FWRJHW3S.js} +2 -1
  114. package/dist/{providers-models-37DUV2GW.js → providers-models-CDI5GVBX.js} +7 -6
  115. package/dist/{proxy-wiring-K2DORFFL.js → proxy-wiring-FIW6HFJV.js} +4 -3
  116. package/dist/{quick-CNB4Z3HS.js → quick-NPC3N3ZX.js} +2 -1
  117. package/dist/{remote-C74BCNND.js → remote-AKKRJEHK.js} +5 -4
  118. package/dist/{replay-DEI566CW.js → replay-5FOPERB2.js} +2 -1
  119. package/dist/{replay-JJ2NOWD6.js → replay-URJFMQCU.js} +3 -2
  120. package/dist/{rewind-7AULJS7F.js → rewind-GAUXWSTU.js} +3 -2
  121. package/dist/{sage-FFKUOCQL.js → sage-6KKXK2ZS.js} +11 -6
  122. package/dist/{sage-sync-ZMTHB477.js → sage-sync-IN3WKEBN.js} +5 -3
  123. package/dist/{sandbox-TYGD6FI2.js → sandbox-EZQ76MNY.js} +2 -1
  124. package/dist/{sdd-runtime-PF72WHLO.js → sdd-runtime-6MFUXWJK.js} +4 -3
  125. package/dist/{session-move-P2EC2COA.js → session-move-F3N45UQQ.js} +2 -1
  126. package/dist/{sessions-config-VE26SB56.js → sessions-config-SJVQXCIE.js} +7 -6
  127. package/dist/{sessions-doctor-QUL37U32.js → sessions-doctor-DZQTDQRY.js} +2 -1
  128. package/dist/short-circuit-flags-647S5WBL.js +11 -0
  129. package/dist/{simpleui-dist-7BQISSEP.js → simpleui-dist-EE3TJRBG.js} +2 -1
  130. package/dist/{skill-suggest-THANK3LV.js → skill-suggest-LZV2TIPQ.js} +22 -6
  131. package/dist/slash-commands/browser.d.ts +3 -0
  132. package/dist/slash-commands/command-context.d.ts +3 -0
  133. package/dist/slash-commands/doctor.d.ts +0 -9
  134. package/dist/{standalone-auto-update-VQC4GYCM.js → standalone-auto-update-X5SK4M5B.js} +17 -5
  135. package/dist/{standalone-update-HZHDZZOR.js → standalone-update-6U4NP5MN.js} +4 -3
  136. package/dist/subcommands-EGZPBQOO.js +10 -0
  137. package/dist/{tools-skills-33AI6K6S.js → tools-skills-55QVTMSK.js} +2 -1
  138. package/dist/{typesafe-NHC322W5.js → typesafe-YBEADNAH.js} +8 -7
  139. package/dist/{typesafe-brain-replay-C5276FVR.js → typesafe-brain-replay-XBU5RZDY.js} +2 -1
  140. package/dist/{typesafe-judgment-check-GGYYV5UF.js → typesafe-judgment-check-XRLBF5JV.js} +2 -1
  141. package/dist/{typesafe-topic-replay-DB2AYL7V.js → typesafe-topic-replay-L6NKFYPM.js} +4 -3
  142. package/dist/{typesafe-triage-replay-27NDAZ3V.js → typesafe-triage-replay-IRV2HHLN.js} +3 -2
  143. package/dist/{update-6OEPAEUV.js → update-54W7GUS5.js} +6 -5
  144. package/dist/{update-check-VLVT4IV2.js → update-check-JBGP4ZFI.js} +4 -3
  145. package/dist/utils/win32-cmd.d.ts +1 -1
  146. package/dist/{version-JB2UAV2A.js → version-Q6KJ23GB.js} +3 -2
  147. package/dist/version-help-RBZC5GZZ.js +11 -0
  148. package/dist/webui-server/credential-watcher.d.ts +3 -1
  149. package/dist/webui-server/provider-config.d.ts +12 -5
  150. package/dist/{webui-server-6IC3SLZG.js → webui-server-HIUY3RHD.js} +59 -49
  151. package/dist/wiring/management-tools.d.ts +9 -1
  152. package/dist/wiring/slash-commands.d.ts +3 -0
  153. package/dist/{wrongtrace-gate-counters-7C2EAAZL.js → wrongtrace-gate-counters-K44XG3H3.js} +3 -2
  154. package/dist/{wrongtrace-telemetry-3ASFKOZO.js → wrongtrace-telemetry-YS6SUBXK.js} +3 -2
  155. package/dist/ws-runtime.d.ts +6 -0
  156. package/package.json +39 -39
  157. package/LICENSE +0 -21
  158. package/dist/ascii-mode-SG4PRNLP.js +0 -7
  159. package/dist/auto-discover-providers-JX346GOM.js +0 -7
  160. package/dist/chunk-BHXAKTBE.js +0 -10
  161. package/dist/chunk-LDXXMPMS.js +0 -61
  162. package/dist/chunk-TGSPCFBT.js +0 -1
  163. package/dist/hq-ttl-N4DAIAVX.js +0 -7
  164. package/dist/ip-allowlist-NHXO6AKJ.js +0 -9
  165. package/dist/kanban-supervisor-67ECABTD.js +0 -7
  166. package/dist/short-circuit-flags-EXJBJ5GT.js +0 -10
  167. package/dist/subcommands-DTKBXLPU.js +0 -9
  168. package/dist/version-help-JQGRPDJW.js +0 -10
@@ -4,15 +4,19 @@ import {
4
4
  loadCachedAcpRegistry,
5
5
  refreshAcpRegistry,
6
6
  setupProvider
7
- } from "./chunk-65VNCAF6.js";
7
+ } from "./chunk-ZNNFEKDZ.js";
8
8
  import {
9
9
  createHqCommandDispatcher
10
- } from "./chunk-NRXWOMK7.js";
10
+ } from "./chunk-XT3NAHRX.js";
11
11
  import {
12
12
  startCliHqConnection
13
- } from "./chunk-4UWCMBPG.js";
14
- import "./chunk-SDJCLEK6.js";
15
- import "./chunk-F5DCFAKI.js";
13
+ } from "./chunk-76JE54WD.js";
14
+ import {
15
+ WebSocketServer
16
+ } from "./chunk-OZCYZYN2.js";
17
+ import "./chunk-UFRVTBV6.js";
18
+ import "./chunk-HKMOIIPQ.js";
19
+ import "./chunk-W23PY4IJ.js";
16
20
 
17
21
  // src/subcommands/handlers/acp-agents.ts
18
22
  import {
@@ -331,7 +335,6 @@ import {
331
335
  WsBridgeTransport
332
336
  } from "@wrongstack/acp/agent";
333
337
  import { leaderDeliveryHub } from "@wrongstack/core/coordination";
334
- import { WebSocketServer } from "ws";
335
338
 
336
339
  // src/acp-hq-telemetry.ts
337
340
  import * as path from "node:path";
@@ -1112,7 +1115,7 @@ var acpCmd = async (args, deps) => {
1112
1115
  const sub = args[0];
1113
1116
  const loginIndex = sub === "auth" ? 0 : (sub === "server" || sub === "serve") && args[1] === "auth" ? 1 : -1;
1114
1117
  if (loginIndex >= 0) {
1115
- const { authCmd } = await import("./auth-M6LXZTDA.js");
1118
+ const { authCmd } = await import("./auth-ANOVZVHE.js");
1116
1119
  return authCmd(args.slice(loginIndex + 1), deps);
1117
1120
  }
1118
1121
  if (!sub || sub === "server" || sub === "serve") {
@@ -1193,4 +1196,4 @@ parallel:
1193
1196
  export {
1194
1197
  acpCmd
1195
1198
  };
1196
- //# sourceMappingURL=acp-T77EAEDB.js.map
1199
+ //# sourceMappingURL=acp-HCGUTFNE.js.map
@@ -0,0 +1,8 @@
1
+ import {
2
+ applyAsciiMode
3
+ } from "./chunk-UVF3BGET.js";
4
+ import "./chunk-W23PY4IJ.js";
5
+ export {
6
+ applyAsciiMode
7
+ };
8
+ //# sourceMappingURL=ascii-mode-B6PKLRHM.js.map
@@ -1,6 +1,7 @@
1
1
  import {
2
2
  restoreFlags
3
- } from "./chunk-CSAPOCBP.js";
3
+ } from "./chunk-QC6CLAK7.js";
4
+ import "./chunk-W23PY4IJ.js";
4
5
 
5
6
  // src/subcommands/handlers/audit.ts
6
7
  import { ToolAuditLog } from "@wrongstack/core/storage";
@@ -102,4 +103,4 @@ async function listAudits(log, dir, deps) {
102
103
  export {
103
104
  auditCmd
104
105
  };
105
- //# sourceMappingURL=audit-KCBTHUQI.js.map
106
+ //# sourceMappingURL=audit-NH7NUKBV.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  providerCloudConfig
3
- } from "./chunk-TXAFIERF.js";
3
+ } from "./chunk-BAWRRA6O.js";
4
4
  import {
5
5
  addCustomProvider,
6
6
  addFromCatalog,
@@ -20,12 +20,12 @@ import {
20
20
  runOAuthLoginKind,
21
21
  runOAuthLoginMenu,
22
22
  validateFamily
23
- } from "./chunk-GZSKLXYG.js";
23
+ } from "./chunk-RAWHRRUJ.js";
24
24
  import {
25
25
  renderAuthLocalHelpToString,
26
26
  wantsLocalHelp
27
- } from "./chunk-YTEOAWOJ.js";
28
- import "./chunk-RKU66D2O.js";
27
+ } from "./chunk-ZXX3MJRL.js";
28
+ import "./chunk-57PSSEBR.js";
29
29
  import {
30
30
  loadConfigProviders,
31
31
  maskedKey,
@@ -33,18 +33,19 @@ import {
33
33
  normalizeKeys,
34
34
  nowIso,
35
35
  writeKeysBack
36
- } from "./chunk-ZYACRPLN.js";
36
+ } from "./chunk-ZCXZGYO5.js";
37
37
  import {
38
38
  activeProfileConfigPath
39
- } from "./chunk-YMXXOOFN.js";
40
- import "./chunk-4BX2YDTQ.js";
39
+ } from "./chunk-SPSHEZ46.js";
40
+ import "./chunk-BIGSVBPI.js";
41
41
  import {
42
42
  restoreFlags
43
- } from "./chunk-CSAPOCBP.js";
44
- import "./chunk-DAKVBMD4.js";
43
+ } from "./chunk-QC6CLAK7.js";
44
+ import "./chunk-BCKVNORU.js";
45
45
  import {
46
46
  parseAuthFlags
47
- } from "./chunk-CJSHS2K7.js";
47
+ } from "./chunk-75OLD563.js";
48
+ import "./chunk-W23PY4IJ.js";
48
49
 
49
50
  // src/subcommands/handlers/auth.ts
50
51
  import { color as color6 } from "@wrongstack/core/utils";
@@ -748,4 +749,4 @@ async function runAuthRemove(deps, providerId) {
748
749
  export {
749
750
  authCmd
750
751
  };
751
- //# sourceMappingURL=auth-M6LXZTDA.js.map
752
+ //# sourceMappingURL=auth-ANOVZVHE.js.map
@@ -0,0 +1,8 @@
1
+ import {
2
+ discoverAndMergeProviders
3
+ } from "./chunk-RBZVDWTL.js";
4
+ import "./chunk-W23PY4IJ.js";
5
+ export {
6
+ discoverAndMergeProviders
7
+ };
8
+ //# sourceMappingURL=auto-discover-providers-V75ICIBG.js.map
@@ -1,3 +1,4 @@
1
+ import "./chunk-W23PY4IJ.js";
1
2
 
2
3
  // src/subcommands/handlers/automation.ts
3
4
  import { randomBytes } from "node:crypto";
@@ -38,7 +39,10 @@ async function resolveAutomationCredentialBundle(refs, paths, vault) {
38
39
  let config = profiles.get(ref.profile);
39
40
  if (!config) {
40
41
  config = decryptConfigSecrets(
41
- JSON.parse(await readFile(paths.profileConfig(ref.profile), "utf8")),
42
+ // A leading UTF-8 BOM is valid (RFC 8259); the config loader accepts it.
43
+ JSON.parse(
44
+ (await readFile(paths.profileConfig(ref.profile), "utf8")).replace(/^\uFEFF/, "")
45
+ ),
42
46
  vault
43
47
  );
44
48
  profiles.set(ref.profile, config);
@@ -201,7 +205,10 @@ var automationCmd = async (args, deps) => {
201
205
  for (const ref of spec.credentials ?? []) {
202
206
  try {
203
207
  const profile = JSON.parse(
204
- await readFile2(deps.paths.profileConfig(ref.profile), "utf8")
208
+ (await readFile2(deps.paths.profileConfig(ref.profile), "utf8")).replace(
209
+ /^\uFEFF/,
210
+ ""
211
+ )
205
212
  );
206
213
  const provider = profile.providers && Object.hasOwn(profile.providers, ref.provider) ? profile.providers[ref.provider] : void 0;
207
214
  const key = provider?.apiKeys?.find(
@@ -326,8 +333,17 @@ Token file: ${path.join(directory, "token.txt")}
326
333
  mode: 384
327
334
  })
328
335
  );
336
+ let lastTickError;
329
337
  while (!abort.signal.aborted) {
330
- await service.tick();
338
+ try {
339
+ await service.tick();
340
+ lastTickError = void 0;
341
+ } catch (error) {
342
+ const message = toErrorMessage(error);
343
+ if (message !== lastTickError) deps.renderer.write(`automation: ${message}
344
+ `);
345
+ lastTickError = message;
346
+ }
331
347
  await new Promise((resolve2) => {
332
348
  const done = () => {
333
349
  clearTimeout(timer);
@@ -366,4 +382,4 @@ Token file: ${path.join(directory, "token.txt")}
366
382
  export {
367
383
  automationCmd
368
384
  };
369
- //# sourceMappingURL=automation-MCDFCIMV.js.map
385
+ //# sourceMappingURL=automation-O7ZRZSFS.js.map
@@ -1,6 +1,7 @@
1
1
  import {
2
2
  CLI_VERSION
3
- } from "./chunk-F5DCFAKI.js";
3
+ } from "./chunk-HKMOIIPQ.js";
4
+ import "./chunk-W23PY4IJ.js";
4
5
 
5
6
  // src/subcommands/handlers/bench.ts
6
7
  import * as fs from "node:fs/promises";
@@ -523,4 +524,4 @@ async function benchList(_args, deps) {
523
524
  export {
524
525
  benchCmd
525
526
  };
526
- //# sourceMappingURL=bench-MMZHFHDL.js.map
527
+ //# sourceMappingURL=bench-NDYES33Y.js.map
@@ -1,2 +1,2 @@
1
- export { createGovernanceEvidenceCandidate, } from '@wrongstack/runtime/governance-bootstrap';
1
+ export { createGovernanceEvidenceCandidate } from '@wrongstack/runtime/governance-bootstrap';
2
2
  //# sourceMappingURL=governance-evidence-candidate.d.ts.map
@@ -63,6 +63,11 @@ export declare function runSystemPromptMenu(deps: {
63
63
  * replaced silently — the gate still defaults to it.
64
64
  */
65
65
  suggestScout?: boolean | undefined;
66
+ /**
67
+ * `launch.rememberStartupChoices`: return the saved variant without the
68
+ * "Continue with …?" question. No effect on first run (nothing saved).
69
+ */
70
+ reuseLast?: boolean | undefined;
66
71
  }): Promise<SystemInstructionVariant>;
67
72
  /** Outcome of {@link maybeRunSystemPromptMenu}. */
68
73
  export interface SystemPromptMenuOutcome {
@@ -115,5 +120,7 @@ export declare function maybeRunSystemPromptMenu(opts: {
115
120
  persist?: typeof persistSystemPromptVariant | undefined;
116
121
  /** The launch folder is not a project — see `runSystemPromptMenu`. */
117
122
  outsideProject?: boolean | undefined;
123
+ /** Reuse the saved variant without asking — see `runSystemPromptMenu`. */
124
+ reuseLast?: boolean | undefined;
118
125
  }): Promise<SystemPromptMenuOutcome>;
119
126
  //# sourceMappingURL=system-prompt-menu.d.ts.map
@@ -1,15 +1,3 @@
1
- /**
2
- * TUI Settings adapter — extracted from the runTui() options literal.
3
- *
4
- * Phase C step 1. The getSettings/saveSettings pair (~337 lines) reads
5
- * config from the ConfigStore and persists changes to disk. This module
6
- * owns both functions, receiving its dependencies through a typed context.
7
- *
8
- * `getSettings()` maps the full Config into the flat LiveSettingsInput
9
- * shape the TUI SettingsPicker consumes. `saveSettings()` does the
10
- * reverse: read → modify → encrypt → atomic-write for every section,
11
- * then syncs the in-memory store and applies live runtime effects.
12
- */
13
1
  import type { ConfigStore, FleetChatVerbosity, SecretVault } from '@wrongstack/core/types';
14
2
  import type { WstackPaths } from '@wrongstack/core/utils';
15
3
  import type { LiveSettingsInput } from '../live-settings-input.js';
@@ -1,10 +1,11 @@
1
1
  import {
2
2
  persistConfigSetting
3
- } from "./chunk-KMU7GF7X.js";
3
+ } from "./chunk-C2BBH4S4.js";
4
4
  import {
5
5
  activeProfileConfigPath
6
- } from "./chunk-YMXXOOFN.js";
7
- import "./chunk-4BX2YDTQ.js";
6
+ } from "./chunk-SPSHEZ46.js";
7
+ import "./chunk-BIGSVBPI.js";
8
+ import "./chunk-W23PY4IJ.js";
8
9
 
9
10
  // src/boot/boot-auto-thin.ts
10
11
  import {
@@ -99,4 +100,4 @@ async function runBootAutoThin(deps) {
99
100
  export {
100
101
  runBootAutoThin
101
102
  };
102
- //# sourceMappingURL=boot-auto-thin-YMAZI3QL.js.map
103
+ //# sourceMappingURL=boot-auto-thin-7D4OVEWA.js.map
@@ -44,6 +44,15 @@ export declare function resolveBundledPromptsDir(): string | undefined;
44
44
  * warning + exit.
45
45
  */
46
46
  export declare function isHomeDirectory(cwd: string, userHome: string): boolean;
47
+ /**
48
+ * `launch.rememberStartupChoices` (TUI Settings → "Reuse startup choices"):
49
+ * when on, the boot gates reuse the saved provider/model, system-prompt
50
+ * variant and mode/YOLO/autonomy without asking "Continue with these?".
51
+ * Unset means on; only an explicit `false` brings the questions back.
52
+ */
53
+ export declare function shouldReuseStartupChoices(config: Pick<Config, 'launch'>): boolean;
54
+ /** One dim line telling the user how to get the startup questions back. */
55
+ export declare const REUSE_STARTUP_CHOICES_HINT = "(ask every launch: /settings reuse-startup-choices off)";
47
56
  /**
48
57
  * Determine whether the first-run YOLO disclosure notice should be printed
49
58
  * to stderr. Exported for testing.
@@ -1,3 +1,4 @@
1
+ import "./chunk-W23PY4IJ.js";
1
2
 
2
3
  // src/subcommands/handlers/chronicle.ts
3
4
  import { statSync } from "node:fs";
@@ -275,4 +276,4 @@ function tryStat(file) {
275
276
  export {
276
277
  chronicleCmd
277
278
  };
278
- //# sourceMappingURL=chronicle-PBJS7BN6.js.map
279
+ //# sourceMappingURL=chronicle-WBK3TJRB.js.map
@@ -7,4 +7,4 @@ import {
7
7
  export {
8
8
  createKanbanSupervisor
9
9
  };
10
- //# sourceMappingURL=chunk-R4QGL6GB.js.map
10
+ //# sourceMappingURL=chunk-2MV474XR.js.map
@@ -236,4 +236,4 @@ export {
236
236
  recordTimeseriesSignal,
237
237
  sanitizeApiError
238
238
  };
239
- //# sourceMappingURL=chunk-AFOH6CHO.js.map
239
+ //# sourceMappingURL=chunk-3EXRPTAU.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  renderAuthLocalHelpToString
3
- } from "./chunk-YTEOAWOJ.js";
3
+ } from "./chunk-ZXX3MJRL.js";
4
4
 
5
5
  // src/subcommands/handlers/per-subcommand-help.ts
6
6
  import { color as color3 } from "@wrongstack/core/utils";
@@ -1296,4 +1296,4 @@ export {
1296
1296
  subcommandsWithFocusedHelp,
1297
1297
  renderGenericHelp
1298
1298
  };
1299
- //# sourceMappingURL=chunk-2EZ2DHOW.js.map
1299
+ //# sourceMappingURL=chunk-3R3OADC5.js.map
@@ -113,4 +113,4 @@ export {
113
113
  hasApiKey,
114
114
  buildPickableProviders
115
115
  };
116
- //# sourceMappingURL=chunk-RKU66D2O.js.map
116
+ //# sourceMappingURL=chunk-57PSSEBR.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  theme
3
- } from "./chunk-QD544J2B.js";
3
+ } from "./chunk-JTTV2EVA.js";
4
4
 
5
5
  // src/boot/tool-restriction-flags.ts
6
6
  function parseToolList(flag, value) {
@@ -608,4 +608,4 @@ export {
608
608
  detectProjectFacts,
609
609
  renderAgentsTemplate
610
610
  };
611
- //# sourceMappingURL=chunk-2CMMWRQH.js.map
611
+ //# sourceMappingURL=chunk-5TRZZHMN.js.map
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  buildWin32CmdShimInvocation
3
- } from "./chunk-BHXAKTBE.js";
3
+ } from "./chunk-C4654QI2.js";
4
4
  import {
5
5
  checkForUpdate
6
- } from "./chunk-DIOODAYM.js";
6
+ } from "./chunk-H53EXXAU.js";
7
7
 
8
8
  // src/subcommands/handlers/update.ts
9
9
  import { spawn } from "node:child_process";
@@ -80,9 +80,9 @@ async function runUpdateCommand(args, deps) {
80
80
  }
81
81
  if (isStandaloneBinary()) {
82
82
  const [{ updateStandaloneBinary }, { standaloneUpdater }, { STANDALONE_TARGET }] = await Promise.all([
83
- import("./standalone-update-HZHDZZOR.js"),
84
- import("./standalone-auto-update-VQC4GYCM.js"),
85
- import("./version-JB2UAV2A.js")
83
+ import("./standalone-update-6U4NP5MN.js"),
84
+ import("./standalone-auto-update-X5SK4M5B.js"),
85
+ import("./version-Q6KJ23GB.js")
86
86
  ]);
87
87
  const updater = standaloneUpdater({
88
88
  executable: realpathSync(process.execPath),
@@ -406,4 +406,4 @@ export {
406
406
  detectUpdatePackageManager,
407
407
  detectUpdatePackageName
408
408
  };
409
- //# sourceMappingURL=chunk-RWNI5OWT.js.map
409
+ //# sourceMappingURL=chunk-6KJU6POA.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  API_VERSION,
3
3
  CLI_VERSION
4
- } from "./chunk-F5DCFAKI.js";
4
+ } from "./chunk-HKMOIIPQ.js";
5
5
 
6
6
  // src/subcommands/handlers/version-help.ts
7
7
  import * as os from "node:os";
@@ -157,4 +157,4 @@ export {
157
157
  versionCmd,
158
158
  helpCmd
159
159
  };
160
- //# sourceMappingURL=chunk-AKESWZH5.js.map
160
+ //# sourceMappingURL=chunk-6VPWQ4TG.js.map
@@ -311,4 +311,4 @@ export {
311
311
  parseAuthFlags,
312
312
  parseSpawnFlags
313
313
  };
314
- //# sourceMappingURL=chunk-CJSHS2K7.js.map
314
+ //# sourceMappingURL=chunk-75OLD563.js.map
@@ -1,10 +1,12 @@
1
+ import {
2
+ WebSocket
3
+ } from "./chunk-OZCYZYN2.js";
1
4
  import {
2
5
  CLI_VERSION
3
- } from "./chunk-F5DCFAKI.js";
6
+ } from "./chunk-HKMOIIPQ.js";
4
7
 
5
8
  // src/hq-publisher.ts
6
9
  import { createHqPublisherFromEnv, resolveHqConfig } from "@wrongstack/core/hq";
7
- import { WebSocket } from "ws";
8
10
 
9
11
  // src/kanban-hq-sync.ts
10
12
  import {
@@ -413,9 +415,9 @@ function pruneExpiredTombstones(state, now) {
413
415
  return changed;
414
416
  }
415
417
  async function readState(projectRoot) {
418
+ const raw = await readKanbanMetadata(projectRoot, SYNC_STATE_KEY);
419
+ if (raw === null) return { boards: {}, tombstones: {} };
416
420
  try {
417
- const raw = await readKanbanMetadata(projectRoot, SYNC_STATE_KEY);
418
- if (raw === null) return { boards: {}, tombstones: {} };
419
421
  const parsed = JSON.parse(raw);
420
422
  return { boards: parsed.boards ?? {}, tombstones: parsed.tombstones ?? {} };
421
423
  } catch {
@@ -686,4 +688,4 @@ function startCliHqConnection(options) {
686
688
  export {
687
689
  startCliHqConnection
688
690
  };
689
- //# sourceMappingURL=chunk-4UWCMBPG.js.map
691
+ //# sourceMappingURL=chunk-76JE54WD.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  loadManifest
3
- } from "./chunk-X4LW5CZM.js";
3
+ } from "./chunk-UBDLNC3N.js";
4
4
 
5
5
  // src/project-picker.ts
6
6
  import { color } from "@wrongstack/core/utils";
@@ -415,4 +415,4 @@ export {
415
415
  skipDivider,
416
416
  runProjectPicker
417
417
  };
418
- //# sourceMappingURL=chunk-7BNBD4PE.js.map
418
+ //# sourceMappingURL=chunk-7IY2UTBE.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  terminalLink,
3
3
  terminalText
4
- } from "./chunk-HXJYHAR4.js";
4
+ } from "./chunk-QVITQ425.js";
5
5
  import {
6
6
  MAX_AGENT_RINGS,
7
7
  MAX_TRANSCRIPT_SESSIONS,
@@ -24,10 +24,14 @@ import {
24
24
  sanitizeApiError,
25
25
  truncateHqSummary,
26
26
  writeInvalidBody
27
- } from "./chunk-AFOH6CHO.js";
27
+ } from "./chunk-3EXRPTAU.js";
28
28
  import {
29
29
  createHqIpAllowlist
30
- } from "./chunk-Q7E3BPDU.js";
30
+ } from "./chunk-OGVSKS4Q.js";
31
+ import {
32
+ WebSocket,
33
+ WebSocketServer
34
+ } from "./chunk-OZCYZYN2.js";
31
35
 
32
36
  // src/hq-server.ts
33
37
  import { randomUUID as randomUUID6 } from "node:crypto";
@@ -49,7 +53,7 @@ import {
49
53
  watchHqAuthFile
50
54
  } from "@wrongstack/core/hq";
51
55
  import { createCompatibilityTrustBoundary } from "@wrongstack/core/security";
52
- import { WebSocket as WebSocket4, WebSocketServer } from "ws";
56
+ import { isPidAlive } from "@wrongstack/core/utils";
53
57
 
54
58
  // src/hq-recovery-html.ts
55
59
  var HQ_RECOVERY_HTML = `<!doctype html>
@@ -1685,7 +1689,6 @@ import { tokenHasCapability, validateHqCommand } from "@wrongstack/core/hq";
1685
1689
 
1686
1690
  // src/hq-server/snapshot.ts
1687
1691
  import { summarizeCommandLatency } from "@wrongstack/core/hq";
1688
- import { WebSocket } from "ws";
1689
1692
  var HQ_SNAPSHOT_BROADCAST_DEBOUNCE_MS = 100;
1690
1693
  var HQ_SNAPSHOT_PERSIST_MIN_INTERVAL_MS = 3e3;
1691
1694
  var HQ_BROWSER_MAX_BUFFERED_BYTES = 32 * 1024 * 1024;
@@ -2889,8 +2892,8 @@ async function handleApiAgentMessages(req, res, match, agentMessages) {
2889
2892
  // src/hq-server/routes/system-handlers.ts
2890
2893
  async function handleApiSystemUpdate(res) {
2891
2894
  const [{ checkForUpdate }, { detectUpdatePackageName }] = await Promise.all([
2892
- import("./update-check-VLVT4IV2.js"),
2893
- import("./update-6OEPAEUV.js")
2895
+ import("./update-check-JBGP4ZFI.js"),
2896
+ import("./update-54W7GUS5.js")
2894
2897
  ]);
2895
2898
  const packageName = detectUpdatePackageName();
2896
2899
  const info = await checkForUpdate({ packageName });
@@ -3780,11 +3783,10 @@ function createHqServerShutdown(params) {
3780
3783
 
3781
3784
  // src/hq-server/socket-credentials.ts
3782
3785
  import { hqTokenKey as hqTokenKey2, isTokenExpired as isTokenExpired4 } from "@wrongstack/core/hq";
3783
- import { WebSocket as WebSocket2 } from "ws";
3784
3786
  function createHqSocketCredentialEnforcer(state) {
3785
3787
  const closeSessionSockets = (sessionId, reason) => {
3786
3788
  for (const [browser, boundSessionId] of state.browserSocketSessions) {
3787
- if (boundSessionId === sessionId && browser.readyState === WebSocket2.OPEN) {
3789
+ if (boundSessionId === sessionId && browser.readyState === WebSocket.OPEN) {
3788
3790
  browser.close(1008, reason);
3789
3791
  }
3790
3792
  }
@@ -3801,7 +3803,7 @@ function createHqSocketCredentialEnforcer(state) {
3801
3803
  const frame = JSON.stringify({ type: "hq.auth_revoked", revokedTokenKeys: keys });
3802
3804
  const revokedIds = new Set(ids);
3803
3805
  for (const ws of state.browsers) {
3804
- if (ws.readyState !== WebSocket2.OPEN) continue;
3806
+ if (ws.readyState !== WebSocket.OPEN) continue;
3805
3807
  const sessionId = state.browserSocketSessions.get(ws);
3806
3808
  if (sessionId !== void 0) {
3807
3809
  const session = state.sessions.get(sessionId);
@@ -3817,7 +3819,7 @@ function createHqSocketCredentialEnforcer(state) {
3817
3819
  for (const [browser, key] of state.browserSocketTokenKeys ?? []) {
3818
3820
  const token = state.mutableAuth.browserTokenObjs.get(key);
3819
3821
  const live = state.mutableAuth.browserTokens.has(key) && token !== void 0 && !isTokenExpired4(token, now);
3820
- if (!live && browser.readyState === WebSocket2.OPEN) {
3822
+ if (!live && browser.readyState === WebSocket.OPEN) {
3821
3823
  browser.close(1008, "Browser token expired or revoked");
3822
3824
  }
3823
3825
  }
@@ -3852,7 +3854,6 @@ import {
3852
3854
  tokenHasCapability as tokenHasCapability3
3853
3855
  } from "@wrongstack/core/hq";
3854
3856
  import { toErrorMessage as toErrorMessage2 } from "@wrongstack/core/utils";
3855
- import { WebSocket as WebSocket3 } from "ws";
3856
3857
 
3857
3858
  // src/hq-server/sage-sync-send.ts
3858
3859
  import { chunkHqSageRecords } from "@wrongstack/core/hq";
@@ -4524,7 +4525,7 @@ function handleClient(ws, clients, browsers, eventLog, auth, snapshotBroadcaster
4524
4525
  for (const [otherWs, otherClient] of clients) {
4525
4526
  if (otherWs === ws || otherClient.clientId !== payload.client.clientId) continue;
4526
4527
  const otherTokenKey = otherClient.authToken === void 0 ? void 0 : hqTokenKey3(otherClient.authToken);
4527
- if (otherTokenKey !== helloTokenKey && otherWs.readyState === WebSocket3.OPEN) {
4528
+ if (otherTokenKey !== helloTokenKey && otherWs.readyState === WebSocket.OPEN) {
4528
4529
  ws.close(4003, "clientId is held by another credential");
4529
4530
  return;
4530
4531
  }
@@ -4640,7 +4641,7 @@ function handleClient(ws, clients, browsers, eventLog, auth, snapshotBroadcaster
4640
4641
  }
4641
4642
  if (toSend.length > 0) {
4642
4643
  const batch = JSON.stringify({ type: "hq.command_batch", commands: toSend });
4643
- if (ws.readyState === WebSocket3.OPEN) ws.send(batch);
4644
+ if (ws.readyState === WebSocket.OPEN) ws.send(batch);
4644
4645
  const dispatchedAt = Date.now();
4645
4646
  for (const cmd of toSend) {
4646
4647
  auditLog?.update(cmd.commandId, { status: "delivered", dispatchedAt });
@@ -5002,14 +5003,7 @@ async function startHqServerWithAuth(options, host, port, dataDir, firstRunAuth)
5002
5003
  const metadataPath = path8.join(projectDir, ".mailbox-server.json");
5003
5004
  const ownerPid = await fs4.readFile(metadataPath, "utf8").then((raw) => JSON.parse(raw).pid).catch(() => void 0);
5004
5005
  if (ownerPid === void 0) return;
5005
- let ownerAlive = false;
5006
- try {
5007
- process.kill(ownerPid, 0);
5008
- ownerAlive = true;
5009
- } catch {
5010
- ownerAlive = false;
5011
- }
5012
- if (!ownerAlive) {
5006
+ if (!isPidAlive(ownerPid)) {
5013
5007
  await fs4.rm(metadataPath, { force: true }).catch(() => {
5014
5008
  });
5015
5009
  return;
@@ -5031,7 +5025,7 @@ async function startHqServerWithAuth(options, host, port, dataDir, firstRunAuth)
5031
5025
  const msg = toAlertMessage(alert);
5032
5026
  const data = JSON.stringify(msg);
5033
5027
  for (const ws of browsers) {
5034
- if (ws.readyState === WebSocket4.OPEN) ws.send(data);
5028
+ if (ws.readyState === WebSocket.OPEN) ws.send(data);
5035
5029
  }
5036
5030
  },
5037
5031
  onPersist: (alert) => persistence.alertLog.append(alert)
@@ -5153,7 +5147,7 @@ async function startHqServerWithAuth(options, host, port, dataDir, firstRunAuth)
5153
5147
  const closeSocketsOfRemovedSessions = (before) => {
5154
5148
  for (const [browser, sessionId] of browserSocketSessions) {
5155
5149
  if (!before.has(sessionId) || sessions.has(sessionId)) continue;
5156
- if (browser.readyState === WebSocket4.OPEN) {
5150
+ if (browser.readyState === WebSocket.OPEN) {
5157
5151
  browser.close(1008, "Browser session revoked");
5158
5152
  }
5159
5153
  }
@@ -5171,7 +5165,7 @@ async function startHqServerWithAuth(options, host, port, dataDir, firstRunAuth)
5171
5165
  serverTime: (/* @__PURE__ */ new Date()).toISOString()
5172
5166
  });
5173
5167
  for (const browser of browsers) {
5174
- if (browser.readyState === WebSocket4.OPEN) browser.send(heartbeat);
5168
+ if (browser.readyState === WebSocket.OPEN) browser.send(heartbeat);
5175
5169
  }
5176
5170
  }, options.browserHeartbeatIntervalMs ?? BROWSER_HEARTBEAT_INTERVAL_MS);
5177
5171
  browserHeartbeatTimer.unref?.();
@@ -5367,4 +5361,4 @@ export {
5367
5361
  startHqServer,
5368
5362
  HqInsecureExposureError2 as HqInsecureExposureError
5369
5363
  };
5370
- //# sourceMappingURL=chunk-6Z6C6ZHH.js.map
5364
+ //# sourceMappingURL=chunk-AWRZWPJ3.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  loadConfigProviders,
3
3
  mutateConfigProviders
4
- } from "./chunk-ZYACRPLN.js";
4
+ } from "./chunk-ZCXZGYO5.js";
5
5
 
6
6
  // src/provider-cloud-config.ts
7
7
  import {
@@ -34,4 +34,4 @@ async function providerCloudConfig(id, updates, configPath, vault) {
34
34
  export {
35
35
  providerCloudConfig
36
36
  };
37
- //# sourceMappingURL=chunk-TXAFIERF.js.map
37
+ //# sourceMappingURL=chunk-BAWRRA6O.js.map
@@ -33,4 +33,4 @@ function openBrowser(url) {
33
33
  export {
34
34
  openBrowser
35
35
  };
36
- //# sourceMappingURL=chunk-DAKVBMD4.js.map
36
+ //# sourceMappingURL=chunk-BCKVNORU.js.map