@posthog/wizard 2.65.0 → 2.67.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 (119) hide show
  1. package/dist/{add-mcp-server-to-clients-ArtlMX9-.js → add-mcp-server-to-clients-DHTRbyJX.js} +228 -64
  2. package/dist/add-mcp-server-to-clients-DHTRbyJX.js.map +1 -0
  3. package/dist/{agent-interface-ORzGEFNM.js → agent-interface-tM_b0l__.js} +458 -76
  4. package/dist/agent-interface-tM_b0l__.js.map +1 -0
  5. package/dist/{agent-prompt-loader-D3w6sc34.js → agent-prompt-loader-BSMh5bfD.js} +5 -5
  6. package/dist/{agent-prompt-loader-D3w6sc34.js.map → agent-prompt-loader-BSMh5bfD.js.map} +1 -1
  7. package/dist/{agent-runner-Ca-e2TOQ.js → agent-runner-DD65OMkB.js} +153 -71
  8. package/dist/agent-runner-DD65OMkB.js.map +1 -0
  9. package/dist/analytics-B4Igh5nv.js +2 -0
  10. package/dist/{analytics-zBrIVjMV.js → analytics-CtIYzkK4.js} +2 -2
  11. package/dist/{analytics-zBrIVjMV.js.map → analytics-CtIYzkK4.js.map} +1 -1
  12. package/dist/{api-Wgb7AhrP.js → api-BJft9v6K.js} +3 -3
  13. package/dist/{api-Wgb7AhrP.js.map → api-BJft9v6K.js.map} +1 -1
  14. package/dist/bin.js +245 -102
  15. package/dist/bin.js.map +1 -1
  16. package/dist/{bounded-fs-DqsVmh4r.js → bounded-fs-BWqoFQvQ.js} +3 -3
  17. package/dist/{bounded-fs-DqsVmh4r.js.map → bounded-fs-BWqoFQvQ.js.map} +1 -1
  18. package/dist/{ci-install-D1QqmJIc.js → ci-install-BXGnVI7T.js} +18 -9
  19. package/dist/ci-install-BXGnVI7T.js.map +1 -0
  20. package/dist/{debug-Cm1hvkVy.js → debug-BsHD83Vy.js} +4 -4
  21. package/dist/debug-BsHD83Vy.js.map +1 -0
  22. package/dist/{debug-CtQ13sCW.js → debug-mO3yg4Z7.js} +1 -1
  23. package/dist/{defaults-BHhXrX9F.js → defaults-DI642M3n.js} +1 -1
  24. package/dist/{defaults-BHhXrX9F.js.map → defaults-DI642M3n.js.map} +1 -1
  25. package/dist/{env-api-key-CdI2XZIz.js → env-api-key-DS0ghlcO.js} +2 -2
  26. package/dist/{env-api-key-CdI2XZIz.js.map → env-api-key-DS0ghlcO.js.map} +1 -1
  27. package/dist/{environment-BhFvfkQg.js → environment-C7CKGIOE.js} +4 -4
  28. package/dist/{environment-BhFvfkQg.js.map → environment-C7CKGIOE.js.map} +1 -1
  29. package/dist/errors-BHervYGs.js +156 -0
  30. package/dist/errors-BHervYGs.js.map +1 -0
  31. package/dist/{file-watcher-Dciz09Rr.js → file-watcher-D1bdo9mq.js} +2 -2
  32. package/dist/{file-watcher-Dciz09Rr.js.map → file-watcher-D1bdo9mq.js.map} +1 -1
  33. package/dist/{headless-ui-B4FnKm11.js → headless-ui-6QuByWZ_.js} +2 -2
  34. package/dist/{headless-ui-B4FnKm11.js.map → headless-ui-6QuByWZ_.js.map} +1 -1
  35. package/dist/{interactive-DxHFVYr2.js → interactive-DUpW84WU.js} +2 -2
  36. package/dist/{interactive-DxHFVYr2.js.map → interactive-DUpW84WU.js.map} +1 -1
  37. package/dist/{local-dev-BN6NKQ0B.js → local-dev-DPZiIPCK.js} +1 -1
  38. package/dist/{local-dev-BN6NKQ0B.js.map → local-dev-DPZiIPCK.js.map} +1 -1
  39. package/dist/{mcp-t0UxAPur.js → mcp-CHo9h-WV.js} +2 -2
  40. package/dist/{mcp-t0UxAPur.js.map → mcp-CHo9h-WV.js.map} +1 -1
  41. package/dist/mcp-install-smoke-test.ts +477 -0
  42. package/dist/{mcp-prompt-streaming-ro98iUDc.js → mcp-prompt-streaming-CHRPxxd0.js} +4 -4
  43. package/dist/{mcp-prompt-streaming-ro98iUDc.js.map → mcp-prompt-streaming-CHRPxxd0.js.map} +1 -1
  44. package/dist/{non-interactive-BA2L_jDT.js → non-interactive-Cr-chffe.js} +7 -2
  45. package/dist/non-interactive-Cr-chffe.js.map +1 -0
  46. package/dist/{orchestrator-tools-vZmNsHy9.js → orchestrator-tools-Tx18_TMb.js} +3 -3
  47. package/dist/{orchestrator-tools-vZmNsHy9.js.map → orchestrator-tools-Tx18_TMb.js.map} +1 -1
  48. package/dist/{package-json-D0DCWpe5.js → package-json-GEU2VZlS.js} +1 -1
  49. package/dist/{package-json-D0DCWpe5.js.map → package-json-GEU2VZlS.js.map} +1 -1
  50. package/dist/{package-manager-DgqJdAQk.js → package-manager-CLfc31yf.js} +4 -4
  51. package/dist/package-manager-CLfc31yf.js.map +1 -0
  52. package/dist/{pi-nwrCARRp.js → pi-RlnYUHdb.js} +12 -11
  53. package/dist/{pi-nwrCARRp.js.map → pi-RlnYUHdb.js.map} +1 -1
  54. package/dist/{playground-xkEke_h0.js → playground-DQ633rje.js} +7 -7
  55. package/dist/{playground-xkEke_h0.js.map → playground-DQ633rje.js.map} +1 -1
  56. package/dist/{posthog-9To56cSd.js → posthog-DSn9bIZc.js} +2 -2
  57. package/dist/{posthog-9To56cSd.js.map → posthog-DSn9bIZc.js.map} +1 -1
  58. package/dist/{posthog-integration-CoPvN6YZ.js → posthog-integration-DFfBRGOC.js} +667 -37
  59. package/dist/posthog-integration-DFfBRGOC.js.map +1 -0
  60. package/dist/{provisioning-BYFSHSHY.js → provisioning-Cvy_vQHV.js} +3 -3
  61. package/dist/{provisioning-BYFSHSHY.js.map → provisioning-Cvy_vQHV.js.map} +1 -1
  62. package/dist/{queue-tools-BREbgGSC.js → queue-tools-BC9HxOV6.js} +33 -7
  63. package/dist/queue-tools-BC9HxOV6.js.map +1 -0
  64. package/dist/{registry-DGJQ_8QI.js → registry-DCAElOyj.js} +81 -81
  65. package/dist/{registry-DGJQ_8QI.js.map → registry-DCAElOyj.js.map} +1 -1
  66. package/dist/{security-wc-naGq5.js → security-CuSX3XVo.js} +21 -9
  67. package/dist/security-CuSX3XVo.js.map +1 -0
  68. package/dist/{setup-utils-Cz0wPLsQ.js → setup-utils-D1tv0v_R.js} +13 -13
  69. package/dist/{setup-utils-Cz0wPLsQ.js.map → setup-utils-D1tv0v_R.js.map} +1 -1
  70. package/dist/{start-tui-DDW9uVnD.js → start-tui-B5YfmqNr.js} +57 -25
  71. package/dist/start-tui-B5YfmqNr.js.map +1 -0
  72. package/dist/{steps-CZI0B24_.js → steps-CLaSMwfR.js} +7 -7
  73. package/dist/{steps-CZI0B24_.js.map → steps-CLaSMwfR.js.map} +1 -1
  74. package/dist/{store-xMkU8xAa.js → store-DzEgsAPN.js} +7 -6
  75. package/dist/{store-xMkU8xAa.js.map → store-DzEgsAPN.js.map} +1 -1
  76. package/dist/{subagent-BztacyoV.js → subagent-BUV6aD7p.js} +2 -2
  77. package/dist/{subagent-BztacyoV.js.map → subagent-BUV6aD7p.js.map} +1 -1
  78. package/dist/{task-CJ7x3McC.js → task-GnWId75q.js} +13 -12
  79. package/dist/{task-CJ7x3McC.js.map → task-GnWId75q.js.map} +1 -1
  80. package/dist/{task-stream-BK7JQ27G.js → task-stream-DSzvwJrD.js} +16 -9
  81. package/dist/task-stream-DSzvwJrD.js.map +1 -0
  82. package/dist/{tasks-FGzp_zBd.js → tasks-BO0W8ocx.js} +2 -2
  83. package/dist/{tasks-FGzp_zBd.js.map → tasks-BO0W8ocx.js.map} +1 -1
  84. package/dist/{telemetry-By56gAtF.js → telemetry-Vi9dWddJ.js} +3 -3
  85. package/dist/{telemetry-By56gAtF.js.map → telemetry-Vi9dWddJ.js.map} +1 -1
  86. package/dist/{terminal-C_rmkaku.js → terminal-B5wZK7aS.js} +73 -80
  87. package/dist/terminal-B5wZK7aS.js.map +1 -0
  88. package/dist/{tools-BpCJgMez.js → tools-C9cNluqc.js} +54 -47
  89. package/dist/tools-C9cNluqc.js.map +1 -0
  90. package/dist/{wizard-abort-BlDla_Jd.js → wizard-abort-BsNbguJt.js} +1 -1
  91. package/dist/wizard-abort-CGv3lVxw.js +71 -0
  92. package/dist/wizard-abort-CGv3lVxw.js.map +1 -0
  93. package/dist/{wizard-session-Bn6dO1gE.js → wizard-session-Cex1BiXs.js} +3 -2
  94. package/dist/wizard-session-Cex1BiXs.js.map +1 -0
  95. package/dist/{wizard-session-UxA_A0cA.js → wizard-session-DHbUcjI7.js} +1 -1
  96. package/dist/yara-hooks-C3Vm2Gow.js +2 -0
  97. package/dist/{yara-hooks-BrisBebM.js → yara-hooks-DZIVzhA6.js} +57 -8
  98. package/dist/yara-hooks-DZIVzhA6.js.map +1 -0
  99. package/package.json +2 -1
  100. package/dist/add-mcp-server-to-clients-ArtlMX9-.js.map +0 -1
  101. package/dist/agent-interface-ORzGEFNM.js.map +0 -1
  102. package/dist/agent-runner-Ca-e2TOQ.js.map +0 -1
  103. package/dist/analytics-C4j6grao.js +0 -2
  104. package/dist/ci-install-D1QqmJIc.js.map +0 -1
  105. package/dist/debug-Cm1hvkVy.js.map +0 -1
  106. package/dist/non-interactive-BA2L_jDT.js.map +0 -1
  107. package/dist/package-manager-DgqJdAQk.js.map +0 -1
  108. package/dist/posthog-integration-CoPvN6YZ.js.map +0 -1
  109. package/dist/queue-tools-BREbgGSC.js.map +0 -1
  110. package/dist/security-wc-naGq5.js.map +0 -1
  111. package/dist/start-tui-DDW9uVnD.js.map +0 -1
  112. package/dist/task-stream-BK7JQ27G.js.map +0 -1
  113. package/dist/terminal-C_rmkaku.js.map +0 -1
  114. package/dist/tools-BpCJgMez.js.map +0 -1
  115. package/dist/wizard-abort-CzwID162.js +0 -49
  116. package/dist/wizard-abort-CzwID162.js.map +0 -1
  117. package/dist/wizard-session-Bn6dO1gE.js.map +0 -1
  118. package/dist/yara-hooks-BrisBebM.js.map +0 -1
  119. package/dist/yara-hooks-D2B7Fd9G.js +0 -2
@@ -1,21 +1,22 @@
1
- import { $ as REMOTE_SKILLS_BASE_URL, K as POSTHOG_ORG_AI_SETTINGS_URL, L as Integration, R as OAUTH_PORTS, U as POSTHOG_DOCS_URL, Z as POSTHOG_TERMS_URL, d as relativeToInstallDir, g as SIGNUP_WIZARD_READINESS_CONFIG, l as WIZARD_LOG_FILE, p as setUI, q as POSTHOG_PRIVACY_URL, s as logToFile, v as getBlockingServiceKeys, z as OAUTH_TIMEOUT_MS } from "./debug-Cm1hvkVy.js";
2
- import { n as analytics } from "./analytics-zBrIVjMV.js";
3
- import { i as readProjectFile, t as IGNORED_DIRS } from "./bounded-fs-DqsVmh4r.js";
4
- import { o as extractOAuthCode, t as getOrAskForProjectData } from "./setup-utils-Cz0wPLsQ.js";
5
- import { t as ApiError } from "./api-Wgb7AhrP.js";
6
- import { t as ADDITIONAL_FEATURE_LABELS } from "./wizard-session-Bn6dO1gE.js";
7
- import { i as wizardAbort } from "./wizard-abort-CzwID162.js";
8
- import { a as formatCostUsd, o as formatTokenCount } from "./agent-runner-Ca-e2TOQ.js";
9
- import { E as fetchSkillMenu, w as downloadSkill } from "./agent-interface-ORzGEFNM.js";
10
- import { _ as AUDIT_CHECKS_KEY, b as coerceAuditChecks, g as AUDIT_CHECKS_FILE, x as getAuditChecks, y as AUDIT_SEVERITY_STYLE } from "./yara-hooks-BrisBebM.js";
11
- import { t as FRAMEWORK_REGISTRY } from "./registry-DGJQ_8QI.js";
12
- import { b as getDetectedWarehouseSources, h as Icons, m as Colors, t as SETUP_REPORT_FILE, w as detectProjectsWithAgent } from "./posthog-integration-CoPvN6YZ.js";
1
+ import { l as ErrorCodes } from "./errors-BHervYGs.js";
2
+ import { $ as REMOTE_SKILLS_BASE_URL, K as POSTHOG_ORG_AI_SETTINGS_URL, L as Integration, R as OAUTH_PORTS, U as POSTHOG_DOCS_URL, Z as POSTHOG_TERMS_URL, d as relativeToInstallDir, g as SIGNUP_WIZARD_READINESS_CONFIG, l as WIZARD_LOG_FILE, p as setUI, q as POSTHOG_PRIVACY_URL, s as logToFile, v as getBlockingServiceKeys, z as OAUTH_TIMEOUT_MS } from "./debug-BsHD83Vy.js";
3
+ import { n as analytics } from "./analytics-CtIYzkK4.js";
4
+ import { i as readProjectFile, t as IGNORED_DIRS } from "./bounded-fs-BWqoFQvQ.js";
5
+ import { o as extractOAuthCode, t as getOrAskForProjectData } from "./setup-utils-D1tv0v_R.js";
6
+ import { t as ApiError } from "./api-BJft9v6K.js";
7
+ import { t as ADDITIONAL_FEATURE_LABELS } from "./wizard-session-Cex1BiXs.js";
8
+ import { i as wizardAbort } from "./wizard-abort-CGv3lVxw.js";
9
+ import { a as formatCostUsd, o as formatTokenCount } from "./agent-runner-DD65OMkB.js";
10
+ import { O as downloadSkill, k as fetchSkillMenu } from "./agent-interface-tM_b0l__.js";
11
+ import { _ as AUDIT_CHECKS_KEY, b as coerceAuditChecks, g as AUDIT_CHECKS_FILE, x as getAuditChecks, y as AUDIT_SEVERITY_STYLE } from "./yara-hooks-DZIVzhA6.js";
12
+ import { t as FRAMEWORK_REGISTRY } from "./registry-DCAElOyj.js";
13
+ import { b as getDetectedWarehouseSources, h as Icons, m as Colors, t as SETUP_REPORT_FILE, w as detectProjectsWithAgent } from "./posthog-integration-DFfBRGOC.js";
13
14
  import { A as STRIPE_SDKS, C as MANUAL_SDK_VARIANTS, D as fetchHealthIssues, O as getContentBlocks, S as MANUAL_SDK_INSTALL, T as SOURCE_MAPS_CONTEXT_KEYS, _ as detectSelfDrivingIntegrationProjects, a as useStdoutDimensions, b as DISPLAY_NAME, f as Program, g as PRICING_SHORT, h as PRICING_LONG, k as POSTHOG_SDKS, m as NO_DEFAULT_LIMIT, n as useKeyBindings, p as getProgramConfig, t as PickerMenu, v as SELF_DRIVING_INTEGRATE_PATH_KEY, y as AUTOMATABLE_VARIANTS } from "./bin.js";
14
- import { r as totalTokenCount, t as WizardStore } from "./store-xMkU8xAa.js";
15
- import { A as EventPlanViewer, C as VisualizerTab, D as HNViewer, F as ConfirmationInput, L as ProgressList, M as LinkText, N as extractUrls, O as TabContainer, P as ModalOverlay, R as LoadingBox, S as ServiceHealthList, T as LearnCard, a as useSkillEntry, b as SEVERITY_LABEL, c as SlackConnectScreen, d as AuditChecksViewer, f as seedDemoEvents, g as probeProjectData, i as SkillSourceInfo, j as LogViewer, k as ScreenContainer, l as AUDIT_AREA_SLIDES, m as McpSuggestedPromptsScreen, n as releaseTerminal, o as OutroScreen, r as AiOptInRequiredScreen, s as useDismissOnAnyKey, t as enterDarkTerminal, u as VisualBox, v as McpScreen, w as TipsCard, x as SEVERITY_ORDER, y as IssueTable, z as SplitView } from "./terminal-C_rmkaku.js";
16
- import { c as namesWithStatus, d as toClientResult, l as redactSecrets, t as ALL_FEATURE_VALUES } from "./defaults-BHhXrX9F.js";
17
- import { t as startFileWatcher } from "./file-watcher-Dciz09Rr.js";
18
- import { a as getSupportedClients, c as removeMCPServer, i as getInstalledClients, o as getSupportedPluginClients, s as installPlugins, u as isPluginCapable } from "./add-mcp-server-to-clients-ArtlMX9-.js";
15
+ import { r as totalTokenCount, t as WizardStore } from "./store-DzEgsAPN.js";
16
+ import { A as EventPlanViewer, C as VisualizerTab, D as HNViewer, F as ConfirmationInput, L as ProgressList, M as LinkText, N as extractUrls, O as TabContainer, P as ModalOverlay, R as LoadingBox, S as ServiceHealthList, T as LearnCard, a as useSkillEntry, b as SEVERITY_LABEL, c as SlackConnectScreen, d as AuditChecksViewer, f as seedDemoEvents, g as probeProjectData, i as SkillSourceInfo, j as LogViewer, k as ScreenContainer, l as AUDIT_AREA_SLIDES, m as McpSuggestedPromptsScreen, n as releaseTerminal, o as OutroScreen, r as AiOptInRequiredScreen, s as useDismissOnAnyKey, t as enterDarkTerminal, u as VisualBox, v as McpScreen, w as TipsCard, x as SEVERITY_ORDER, y as IssueTable, z as SplitView } from "./terminal-B5wZK7aS.js";
17
+ import { c as namesWithStatus, d as toClientResult, l as redactSecrets, t as ALL_FEATURE_VALUES } from "./defaults-DI642M3n.js";
18
+ import { t as startFileWatcher } from "./file-watcher-D1bdo9mq.js";
19
+ import { a as getSupportedClients, c as removeMCPServer, i as getInstalledClients, o as getSupportedPluginClients, s as installPlugins, u as isPluginCapable } from "./add-mcp-server-to-clients-DHTRbyJX.js";
19
20
  import { existsSync, readFileSync, readdirSync } from "fs";
20
21
  import path, { join } from "path";
21
22
  import { join as join$1 } from "node:path";
@@ -297,14 +298,23 @@ const HealthCheckScreen = ({ store }) => {
297
298
  message: "",
298
299
  confirmLabel: "",
299
300
  cancelLabel: "Exit [Esc]",
300
- onConfirm: () => void wizardAbort({ message: "Exited due to service outage." }),
301
- onCancel: () => void wizardAbort({ message: "Exited due to service outage." })
301
+ onConfirm: () => void wizardAbort({
302
+ code: ErrorCodes.EnvServiceOutage,
303
+ message: "Exited due to service outage."
304
+ }),
305
+ onCancel: () => void wizardAbort({
306
+ code: ErrorCodes.EnvServiceOutage,
307
+ message: "Exited due to service outage."
308
+ })
302
309
  }) : /* @__PURE__ */ jsx(ConfirmationInput, {
303
310
  message: "Continue anyway?",
304
311
  confirmLabel: "Continue [Enter]",
305
312
  cancelLabel: canDownloadSkills && !isGithubReleasesDown ? downloading ? "Downloading..." : "Download skills & Exit [Esc]" : "Exit [Esc]",
306
313
  onConfirm: () => store.dismissOutage(),
307
- onCancel: canDownloadSkills && !isGithubReleasesDown ? () => void handleDownloadAndExit() : () => void wizardAbort({ message: "Exited due to service outage." })
314
+ onCancel: canDownloadSkills && !isGithubReleasesDown ? () => void handleDownloadAndExit() : () => void wizardAbort({
315
+ code: ErrorCodes.EnvServiceOutage,
316
+ message: "Exited due to service outage."
317
+ })
308
318
  }),
309
319
  children: [
310
320
  /* @__PURE__ */ jsxs(Box, {
@@ -1134,7 +1144,7 @@ const FrameworkPicker = ({ store, onComplete }) => {
1134
1144
  })),
1135
1145
  onSelect: (value) => {
1136
1146
  const integration = Array.isArray(value) ? value[0] : value;
1137
- import("./registry-DGJQ_8QI.js").then((n) => n.n).then(({ FRAMEWORK_REGISTRY }) => {
1147
+ import("./registry-DCAElOyj.js").then((n) => n.n).then(({ FRAMEWORK_REGISTRY }) => {
1138
1148
  const config = FRAMEWORK_REGISTRY[integration];
1139
1149
  store.setFrameworkConfig(integration, config);
1140
1150
  store.setDetectedFramework(config.metadata.name);
@@ -5495,6 +5505,11 @@ const QuestionInput = ({ question, onSubmit }) => {
5495
5505
  }
5496
5506
  };
5497
5507
  //#endregion
5508
+ //#region src/steps/add-mcp-server-to-clients/login-client.ts
5509
+ function isLoginCapable(client) {
5510
+ return typeof client === "object" && client !== null && "loginCommand" in client;
5511
+ }
5512
+ //#endregion
5498
5513
  //#region src/steps/add-mcp-server-to-clients/browser-client.ts
5499
5514
  function isBrowserFinishable(c) {
5500
5515
  return typeof c === "object" && c !== null && "connectorUrl" in c && "finishInstruction" in c;
@@ -5522,10 +5537,13 @@ function createMcpInstaller() {
5522
5537
  return supported.map((c) => ({
5523
5538
  name: c.name,
5524
5539
  supportsPlugin: isPluginCapable(c) && c.supportsPlugin(),
5540
+ pluginBundlesMcp: isPluginCapable(c) && c.pluginBundlesMcpServer(),
5525
5541
  finish: isBrowserFinishable(c) ? {
5526
5542
  url: c.connectorUrl,
5527
5543
  instruction: c.finishInstruction
5528
- } : void 0
5544
+ } : void 0,
5545
+ loginCommand: isLoginCapable(c) && c.loginCommand(false) || void 0,
5546
+ pluginLoginCommand: isLoginCapable(c) && c.pluginLoginCommand?.() || void 0
5529
5547
  }));
5530
5548
  },
5531
5549
  async install(clientNames, features, apiKey) {
@@ -5621,7 +5639,7 @@ function createMcpSuggestedPromptsServices(store) {
5621
5639
  };
5622
5640
  }
5623
5641
  async function* runProductionPromptStreaming(args) {
5624
- const { runMcpPromptViaSdk } = await import("./mcp-prompt-streaming-ro98iUDc.js");
5642
+ const { runMcpPromptViaSdk } = await import("./mcp-prompt-streaming-CHRPxxd0.js");
5625
5643
  yield* runMcpPromptViaSdk(args);
5626
5644
  }
5627
5645
  //#endregion
@@ -5734,10 +5752,21 @@ function tokenCostLine(store) {
5734
5752
  if (totalTokenCount(usage) === 0) return null;
5735
5753
  return `${DIM}${usage.costIsFinal ? "Final cost" : "Cost (estimate)"}: ${formatCostUsd(usage.costUsd)} (in ${formatTokenCount(usage.inputTokens)} · out ${formatTokenCount(usage.outputTokens)} · cache read ${formatTokenCount(usage.cacheReadTokens)} · cache write ${formatTokenCount(usage.cacheCreationTokens)})${RESET_ATTRS}`;
5736
5754
  }
5755
+ /**
5756
+ * The one manual step the wizard can't do itself: the editor's own MCP login.
5757
+ * Echoed into scrollback like the handoff prompt — command on its own plain
5758
+ * line so a terminal can triple-click-select it.
5759
+ */
5760
+ function mcpLoginBlock(store) {
5761
+ const commands = store.session.mcpLoginCommands;
5762
+ if (!commands || commands.length === 0) return null;
5763
+ return `${GREEN}${BOLD}\u2714 Authenticate to finish (opens your browser):${RESET_ATTRS}\n` + commands.join("\n");
5764
+ }
5737
5765
  function getExitLine(store) {
5738
5766
  const outro = store.session.outroData;
5739
5767
  const label = store.session.programLabel ?? "Wizard";
5740
5768
  const costLine = tokenCostLine(store);
5769
+ const loginBlock = mcpLoginBlock(store);
5741
5770
  if (outro?.kind === "success") {
5742
5771
  const message = outro.message ?? `${label} completed successfully.`;
5743
5772
  const parts = [`${GREEN}${BOLD}✔${RESET_ATTRS} ${message}${outro.reportFile && !message.includes(outro.reportFile) ? ` Check ./${outro.reportFile} for details.` : ""}`];
@@ -5747,10 +5776,13 @@ function getExitLine(store) {
5747
5776
  parts.push(`${DIM}${outro.nextSteps.heading}${RESET_ATTRS}\n${bullets}`);
5748
5777
  }
5749
5778
  if (outro.handoffPrompt) parts.push(`${DIM}Hand this to your coding agent to finish up (triple-click to select):${RESET_ATTRS}\n` + outro.handoffPrompt);
5779
+ if (loginBlock) parts.push(loginBlock);
5750
5780
  if (costLine) parts.push(costLine);
5751
5781
  return parts.join("\n\n");
5752
5782
  }
5753
- return costLine ? `${DIM}${label} exited.${RESET_ATTRS}\n\n${costLine}` : `${DIM}${label} exited.${RESET_ATTRS}`;
5783
+ const parts = loginBlock ? [loginBlock] : [`${DIM}${label} exited.${RESET_ATTRS}`];
5784
+ if (costLine) parts.push(costLine);
5785
+ return parts.join("\n\n");
5754
5786
  }
5755
5787
  //#endregion
5756
5788
  //#region src/ui/tui/start-tui.ts
@@ -5800,4 +5832,4 @@ function startTUI(version, program = Program.PostHogIntegration) {
5800
5832
  //#endregion
5801
5833
  export { startTUI };
5802
5834
 
5803
- //# sourceMappingURL=start-tui-DDW9uVnD.js.map
5835
+ //# sourceMappingURL=start-tui-B5YfmqNr.js.map