@posthog/wizard 2.38.2 → 2.40.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +70 -13
- package/dist/{add-mcp-server-to-clients-CHSzsAG8.js → add-mcp-server-to-clients-Dtvqw5DO.js} +5 -5
- package/dist/{add-mcp-server-to-clients-CHSzsAG8.js.map → add-mcp-server-to-clients-Dtvqw5DO.js.map} +1 -1
- package/dist/{agent-interface-DExARWay.js → agent-interface-BTVAlvLW.js} +46 -623
- package/dist/agent-interface-BTVAlvLW.js.map +1 -0
- package/dist/{agent-runner-CMfTmM3B.js → agent-runner-CqNL9x2D.js} +36 -19
- package/dist/agent-runner-CqNL9x2D.js.map +1 -0
- package/dist/analytics-D6RSYOPO.js +2 -0
- package/dist/{analytics-Ciob-x8a.js → analytics-__4kRqZr.js} +3 -2
- package/dist/analytics-__4kRqZr.js.map +1 -0
- package/dist/{api-T_WHs3qZ.js → api-D0RqJPWO.js} +3 -3
- package/dist/{api-T_WHs3qZ.js.map → api-D0RqJPWO.js.map} +1 -1
- package/dist/bin.js +387 -105
- package/dist/bin.js.map +1 -1
- package/dist/{ci-install-DJN5aT7W.js → ci-install-SXJrlScZ.js} +4 -4
- package/dist/{ci-install-DJN5aT7W.js.map → ci-install-SXJrlScZ.js.map} +1 -1
- package/dist/{debug-D1lORUFs.js → debug-D_mboDpg.js} +38 -11
- package/dist/debug-D_mboDpg.js.map +1 -0
- package/dist/{debug-Cne-cLxd.js → debug-dh-I1XvJ.js} +1 -1
- package/dist/{defaults-a0e6IRjP.js → defaults-BxiMLkQY.js} +1 -1
- package/dist/{defaults-a0e6IRjP.js.map → defaults-BxiMLkQY.js.map} +1 -1
- package/dist/{env-api-key-DEl3LJBv.js → env-api-key-DDVkPQmo.js} +1 -1
- package/dist/{env-api-key-DEl3LJBv.js.map → env-api-key-DDVkPQmo.js.map} +1 -1
- package/dist/{environment-BEsDCA2q.js → environment-4zKc7kWr.js} +3 -3
- package/dist/{environment-BEsDCA2q.js.map → environment-4zKc7kWr.js.map} +1 -1
- package/dist/{file-utils-Cn3dzlo-.js → file-utils-Cb6HLPhu.js} +2 -2
- package/dist/{file-utils-Cn3dzlo-.js.map → file-utils-Cb6HLPhu.js.map} +1 -1
- package/dist/{headless-ui-DGunpK-s.js → headless-ui-CjdRKkTG.js} +2 -2
- package/dist/{headless-ui-DGunpK-s.js.map → headless-ui-CjdRKkTG.js.map} +1 -1
- package/dist/{host-resolution-BnUJZKId.js → host-resolution-Czw5O33G.js} +6 -6
- package/dist/{host-resolution-BnUJZKId.js.map → host-resolution-Czw5O33G.js.map} +1 -1
- package/dist/{interactive-BB2IDSWP.js → interactive-C3Ty8H5M.js} +2 -2
- package/dist/{interactive-BB2IDSWP.js.map → interactive-C3Ty8H5M.js.map} +1 -1
- package/dist/{mcp-CgA5vyiS.js → mcp-B_utnKAq.js} +2 -2
- package/dist/{mcp-CgA5vyiS.js.map → mcp-B_utnKAq.js.map} +1 -1
- package/dist/{mcp-prompt-streaming-CGAkq9qR.js → mcp-prompt-streaming-BzFu8dP6.js} +5 -5
- package/dist/mcp-prompt-streaming-BzFu8dP6.js.map +1 -0
- package/dist/{non-interactive-Dko5F3vh.js → non-interactive-B2a00UId.js} +2 -2
- package/dist/{non-interactive-Dko5F3vh.js.map → non-interactive-B2a00UId.js.map} +1 -1
- package/dist/{package-manager-WKKQADHM.js → package-manager-CRYusNaP.js} +2 -2
- package/dist/{package-manager-WKKQADHM.js.map → package-manager-CRYusNaP.js.map} +1 -1
- package/dist/{playground-UtT6zbjE.js → playground-CVIGzLGh.js} +5 -5
- package/dist/{playground-UtT6zbjE.js.map → playground-CVIGzLGh.js.map} +1 -1
- package/dist/{posthog-BESrI6-T.js → posthog-BHbtnNQE.js} +1 -1
- package/dist/{posthog-BESrI6-T.js.map → posthog-BHbtnNQE.js.map} +1 -1
- package/dist/{posthog-integration-CWXSng0W.js → posthog-integration-D2S9mCAv.js} +16 -15
- package/dist/{posthog-integration-CWXSng0W.js.map → posthog-integration-D2S9mCAv.js.map} +1 -1
- package/dist/{provisioning-CgomM26T.js → provisioning-B1KoQFFK.js} +4 -4
- package/dist/{provisioning-CgomM26T.js.map → provisioning-B1KoQFFK.js.map} +1 -1
- package/dist/{registry-BQIX-25O.js → registry-CgrvMaYt.js} +5 -4
- package/dist/{registry-BQIX-25O.js.map → registry-CgrvMaYt.js.map} +1 -1
- package/dist/security-DX5ey9g8.js +204 -0
- package/dist/security-DX5ey9g8.js.map +1 -0
- package/dist/{setup-utils-DLGNk8T6.js → setup-utils-CUeGnxBk.js} +9 -9
- package/dist/{setup-utils-DLGNk8T6.js.map → setup-utils-CUeGnxBk.js.map} +1 -1
- package/dist/{start-tui-BjCKghQq.js → start-tui-BC3yp_wW.js} +29 -27
- package/dist/start-tui-BC3yp_wW.js.map +1 -0
- package/dist/{steps-XjV9CiqH.js → steps-5YGQK7la.js} +7 -7
- package/dist/{steps-XjV9CiqH.js.map → steps-5YGQK7la.js.map} +1 -1
- package/dist/{store-CDIxU0rr.js → store-DQ0-oE_Y.js} +4 -4
- package/dist/{store-CDIxU0rr.js.map → store-DQ0-oE_Y.js.map} +1 -1
- package/dist/{subagent-S5Yh16IJ.js → subagent-DkTSX2ew.js} +2 -2
- package/dist/{subagent-S5Yh16IJ.js.map → subagent-DkTSX2ew.js.map} +1 -1
- package/dist/{task-stream-rC4IEUHC.js → task-stream-d-R9J0g4.js} +2 -2
- package/dist/{task-stream-rC4IEUHC.js.map → task-stream-d-R9J0g4.js.map} +1 -1
- package/dist/{tasks-wbjOdifO.js → tasks-SbUmyQPS.js} +2 -2
- package/dist/{tasks-wbjOdifO.js.map → tasks-SbUmyQPS.js.map} +1 -1
- package/dist/{telemetry-BfnR7gtf.js → telemetry-_7NXwx7o.js} +3 -3
- package/dist/{telemetry-BfnR7gtf.js.map → telemetry-_7NXwx7o.js.map} +1 -1
- package/dist/{terminal-BvRwVeQp.js → terminal-NhR2Seu_.js} +13 -12
- package/dist/{terminal-BvRwVeQp.js.map → terminal-NhR2Seu_.js.map} +1 -1
- package/dist/{tools-CbtYlZV4.js → tools-WDPzlrXc.js} +4 -4
- package/dist/{tools-CbtYlZV4.js.map → tools-WDPzlrXc.js.map} +1 -1
- package/dist/types-evL_rPob.js +46 -0
- package/dist/types-evL_rPob.js.map +1 -0
- package/dist/{urls-CilgPbS-.js → urls-DYIMfv29.js} +2 -2
- package/dist/{urls-CilgPbS-.js.map → urls-DYIMfv29.js.map} +1 -1
- package/dist/warlock-smoke-test.ts +165 -0
- package/dist/{wizard-abort-Cp5Y7f8C.js → wizard-abort-CWaKUNMI.js} +3 -3
- package/dist/{wizard-abort-Cp5Y7f8C.js.map → wizard-abort-CWaKUNMI.js.map} +1 -1
- package/dist/{wizard-abort-DHrEGqaC.js → wizard-abort-DGM_sAA9.js} +1 -1
- package/dist/{wizard-tools-DQTfAzSV.js → wizard-tools-CrpRaYkE.js} +26 -50
- package/dist/wizard-tools-CrpRaYkE.js.map +1 -0
- package/dist/yara-hooks-BPQ3VE-l.js +635 -0
- package/dist/yara-hooks-BPQ3VE-l.js.map +1 -0
- package/dist/yara-hooks-yy8OLJ43.js +2 -0
- package/package.json +4 -3
- package/dist/agent-interface-DExARWay.js.map +0 -1
- package/dist/agent-runner-CMfTmM3B.js.map +0 -1
- package/dist/analytics-Ciob-x8a.js.map +0 -1
- package/dist/analytics-DbfiRvPS.js +0 -2
- package/dist/debug-D1lORUFs.js.map +0 -1
- package/dist/mcp-prompt-streaming-CGAkq9qR.js.map +0 -1
- package/dist/security-pJOYY5LO.js +0 -431
- package/dist/security-pJOYY5LO.js.map +0 -1
- package/dist/start-tui-BjCKghQq.js.map +0 -1
- package/dist/wizard-tools-DQTfAzSV.js.map +0 -1
package/dist/bin.js
CHANGED
|
@@ -1,21 +1,23 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { B as POSTHOG_DOCS_URL, P as Integration, a as getLogFilePath,
|
|
3
|
-
import { n as analytics } from "./analytics-
|
|
4
|
-
import { r as setEntryCommand } from "./telemetry-
|
|
5
|
-
import { n as isUsingTypeScript } from "./setup-utils-
|
|
6
|
-
import { o as getUiHostFromHost } from "./urls-
|
|
7
|
-
import { t as HostResolution } from "./host-resolution-
|
|
8
|
-
import { o as handleApiError } from "./api-
|
|
2
|
+
import { B as POSTHOG_DOCS_URL, P as Integration, a as getLogFilePath, f as getUI, ht as isHeadless, lt as getSkillsBaseUrl, m as LoggingUI, mt as HEADLESS_FLAG, p as setUI, r as debug, s as logToFile, st as WIZARD_USER_AGENT, ut as VERSION } from "./debug-D_mboDpg.js";
|
|
3
|
+
import { n as analytics } from "./analytics-__4kRqZr.js";
|
|
4
|
+
import { r as setEntryCommand } from "./telemetry-_7NXwx7o.js";
|
|
5
|
+
import { n as isUsingTypeScript } from "./setup-utils-CUeGnxBk.js";
|
|
6
|
+
import { o as getUiHostFromHost } from "./urls-DYIMfv29.js";
|
|
7
|
+
import { t as HostResolution } from "./host-resolution-Czw5O33G.js";
|
|
8
|
+
import { o as handleApiError } from "./api-D0RqJPWO.js";
|
|
9
9
|
import "./wizard-session-BoXAZEOf.js";
|
|
10
|
-
import { r as runCleanups } from "./wizard-abort-
|
|
11
|
-
import { n as isNonInteractiveEnvironment } from "./environment-
|
|
12
|
-
import { n as runAgent, o as authenticate } from "./agent-runner-
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import { n as
|
|
10
|
+
import { r as runCleanups } from "./wizard-abort-CWaKUNMI.js";
|
|
11
|
+
import { n as isNonInteractiveEnvironment } from "./environment-4zKc7kWr.js";
|
|
12
|
+
import { n as runAgent, o as authenticate } from "./agent-runner-CqNL9x2D.js";
|
|
13
|
+
import { l as recoverOrphanedSettingsBackups, p as AgentSignals } from "./agent-interface-BTVAlvLW.js";
|
|
14
|
+
import { i as fetchSkillMenu, t as WIZARD_TOOL_NAMES } from "./wizard-tools-CrpRaYkE.js";
|
|
15
|
+
import { n as AUDIT_CHECKS_KEY, r as AUDIT_REPORT_FILE, t as AUDIT_CHECKS_FILE } from "./types-evL_rPob.js";
|
|
16
|
+
import { h as SETUP_REPORT_FILE } from "./yara-hooks-BPQ3VE-l.js";
|
|
17
|
+
import { i as SPINNER_MESSAGE, t as FRAMEWORK_REGISTRY } from "./registry-CgrvMaYt.js";
|
|
18
|
+
import { _ as gatherFrameworkContext, a as LINE_CHART_BLOCK, b as parseRequirementsTxt, g as detectProjectsWithAgent, h as HEALTH_CHECK_STEP, i as FUNNEL_BLOCK, m as Icons, n as integrationRunStep, o as PRODUCT_SUITE_BLOCK, p as Colors, r as posthogIntegrationConfig, s as StatusPeekTrigger, u as isClearBlock, v as parsePipfile, y as parsePyprojectToml } from "./posthog-integration-D2S9mCAv.js";
|
|
19
|
+
import { n as safeReadFile, r as walkProjectFiles, t as IGNORED_DIRS } from "./file-utils-Cb6HLPhu.js";
|
|
20
|
+
import { n as readApiKeyFromEnv } from "./env-api-key-DDVkPQmo.js";
|
|
19
21
|
import { satisfies } from "semver";
|
|
20
22
|
import yargs from "yargs";
|
|
21
23
|
import { hideBin } from "yargs/helpers";
|
|
@@ -32,37 +34,6 @@ import { createContext, createElement, useCallback, useContext, useEffect, useRe
|
|
|
32
34
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
33
35
|
import { access, rm } from "node:fs/promises";
|
|
34
36
|
import * as readline from "node:readline/promises";
|
|
35
|
-
//#region src/lib/headless-mode.ts
|
|
36
|
-
/**
|
|
37
|
-
* Headless mode — the published-build, non-interactive run path.
|
|
38
|
-
*
|
|
39
|
-
* The headless flag and `--ci` both drive a non-interactive install
|
|
40
|
-
* (session.ci === true), but through dedicated entry points so they can
|
|
41
|
-
* diverge: runHeadlessInstall → runWizardHeadless for headless,
|
|
42
|
-
* runCIInstall → runWizardCI for `--ci`. Both delegate to one shared pipeline
|
|
43
|
-
* (runNonInteractive) today; the only forks are the api-key prefixes accepted
|
|
44
|
-
* (ci-install) and the analytics build tag (the mode passed to the runner).
|
|
45
|
-
*
|
|
46
|
-
* The flag is deliberately named `--headless-DONOTUSE-EXPERIMENTAL` and hidden
|
|
47
|
-
* from `--help`: the contract is still unstable and subject to breaking
|
|
48
|
-
* changes, so it must not be advertised or relied on by external callers. This
|
|
49
|
-
* module is the single source of truth for the flag's name and detection — keep
|
|
50
|
-
* the scary name out of every other file so a future rename is one edit here.
|
|
51
|
-
*/
|
|
52
|
-
/**
|
|
53
|
-
* The on-CLI flag name. Intentionally ugly + undocumented; do not surface it in
|
|
54
|
-
* `--help`, the README, or user-facing error messages.
|
|
55
|
-
*/
|
|
56
|
-
const HEADLESS_FLAG = "headless-DONOTUSE-EXPERIMENTAL";
|
|
57
|
-
/**
|
|
58
|
-
* Read the headless signal off a parsed argv / options bag. yargs always sets
|
|
59
|
-
* the value under the declared key (`HEADLESS_FLAG`), so reading that key is
|
|
60
|
-
* reliable regardless of camel-case expansion.
|
|
61
|
-
*/
|
|
62
|
-
function isHeadless(options) {
|
|
63
|
-
return options[HEADLESS_FLAG] === true;
|
|
64
|
-
}
|
|
65
|
-
//#endregion
|
|
66
37
|
//#region src/commands/command.ts
|
|
67
38
|
/** Extract the bare command word(s) from a yargs name spec, dropping positionals and aliases' arg syntax. */
|
|
68
39
|
function commandKeys(name) {
|
|
@@ -243,7 +214,7 @@ function runProvision(argv) {
|
|
|
243
214
|
}
|
|
244
215
|
async function provision({ email, region, name, baseUrl, jsonMode }) {
|
|
245
216
|
try {
|
|
246
|
-
const { provisionNewAccount } = await import("./provisioning-
|
|
217
|
+
const { provisionNewAccount } = await import("./provisioning-B1KoQFFK.js").then((n) => n.n);
|
|
247
218
|
if (!jsonMode) getUI().log.info(`Provisioning account for ${email} in ${region}...`);
|
|
248
219
|
emitResult(await provisionNewAccount(email, name, region, { baseUrl }), jsonMode);
|
|
249
220
|
process.exit(0);
|
|
@@ -308,22 +279,22 @@ const basicIntegrationCommand = {
|
|
|
308
279
|
setEntryCommand("integrate");
|
|
309
280
|
(async () => {
|
|
310
281
|
if (isHeadless(argv)) {
|
|
311
|
-
const { runHeadlessInstall } = await import("./ci-install-
|
|
282
|
+
const { runHeadlessInstall } = await import("./ci-install-SXJrlScZ.js");
|
|
312
283
|
return runHeadlessInstall(argv);
|
|
313
284
|
}
|
|
314
285
|
if (argv.ci) {
|
|
315
|
-
const { runCIInstall } = await import("./ci-install-
|
|
286
|
+
const { runCIInstall } = await import("./ci-install-SXJrlScZ.js");
|
|
316
287
|
return runCIInstall(argv);
|
|
317
288
|
}
|
|
318
289
|
if (isNonInteractiveEnvironment()) {
|
|
319
|
-
const { failNonInteractive } = await import("./non-interactive-
|
|
290
|
+
const { failNonInteractive } = await import("./non-interactive-B2a00UId.js");
|
|
320
291
|
return failNonInteractive();
|
|
321
292
|
}
|
|
322
293
|
if (argv.playground) {
|
|
323
|
-
const { runPlayground } = await import("./playground-
|
|
294
|
+
const { runPlayground } = await import("./playground-CVIGzLGh.js");
|
|
324
295
|
return runPlayground();
|
|
325
296
|
}
|
|
326
|
-
const { runInteractive } = await import("./interactive-
|
|
297
|
+
const { runInteractive } = await import("./interactive-C3Ty8H5M.js");
|
|
327
298
|
runInteractive(argv);
|
|
328
299
|
})();
|
|
329
300
|
}
|
|
@@ -516,7 +487,7 @@ const REVENUE_ANALYTICS_PROGRAM = [
|
|
|
516
487
|
* skill-based program (audit, revenue-analytics, agent-skill, etc.)
|
|
517
488
|
* runs. Skill programs don't need the full PostHog onboarding narrative.
|
|
518
489
|
*/
|
|
519
|
-
const getContentBlocks$
|
|
490
|
+
const getContentBlocks$3 = (store) => {
|
|
520
491
|
return [
|
|
521
492
|
{
|
|
522
493
|
content: "Welcome.",
|
|
@@ -549,7 +520,7 @@ const revenueAnalyticsConfig = {
|
|
|
549
520
|
id: "revenue-analytics-setup",
|
|
550
521
|
skillId: "revenue-analytics-setup",
|
|
551
522
|
steps: REVENUE_ANALYTICS_PROGRAM,
|
|
552
|
-
getContentBlocks: getContentBlocks$
|
|
523
|
+
getContentBlocks: getContentBlocks$3,
|
|
553
524
|
allowedTools: ["Agent"],
|
|
554
525
|
disallowedTools: [WIZARD_TOOL_NAMES.wizardAsk],
|
|
555
526
|
run: {
|
|
@@ -1426,7 +1397,7 @@ const warehouseSourceConfig = {
|
|
|
1426
1397
|
id: "warehouse-source",
|
|
1427
1398
|
skillId: "data-warehouse-source-setup",
|
|
1428
1399
|
steps: WAREHOUSE_SOURCE_PROGRAM,
|
|
1429
|
-
getContentBlocks: getContentBlocks$
|
|
1400
|
+
getContentBlocks: getContentBlocks$3,
|
|
1430
1401
|
reportFile: "posthog-warehouse-report.md",
|
|
1431
1402
|
allowedTools: ["Agent"],
|
|
1432
1403
|
run: (session) => Promise.resolve({
|
|
@@ -1486,7 +1457,7 @@ function createSkillProgram(opts) {
|
|
|
1486
1457
|
skillId: opts.skillId,
|
|
1487
1458
|
steps: AGENT_SKILL_STEPS,
|
|
1488
1459
|
reportFile: opts.reportFile,
|
|
1489
|
-
getContentBlocks: getContentBlocks$
|
|
1460
|
+
getContentBlocks: getContentBlocks$3,
|
|
1490
1461
|
run: {
|
|
1491
1462
|
skillId: opts.skillId,
|
|
1492
1463
|
integrationLabel: opts.integrationLabel,
|
|
@@ -2354,7 +2325,7 @@ const PRICING_STRUCTURE_BLOCK = {
|
|
|
2354
2325
|
* - posthog.com/docs/feature-flags/common-questions
|
|
2355
2326
|
* - posthog.com/docs/experiments/best-practices
|
|
2356
2327
|
*/
|
|
2357
|
-
const getContentBlocks$
|
|
2328
|
+
const getContentBlocks$2 = (store) => [
|
|
2358
2329
|
{
|
|
2359
2330
|
content: "Hello.",
|
|
2360
2331
|
pause: 3e3,
|
|
@@ -2600,7 +2571,7 @@ const migrationConfig = {
|
|
|
2600
2571
|
skillId: DEFAULT_MIGRATE_SKILL_ID,
|
|
2601
2572
|
steps: MIGRATION_PROGRAM,
|
|
2602
2573
|
reportFile: MIGRATION_REPORT_FILE,
|
|
2603
|
-
getContentBlocks: getContentBlocks$
|
|
2574
|
+
getContentBlocks: getContentBlocks$2,
|
|
2604
2575
|
allowedTools: ["Agent"],
|
|
2605
2576
|
disallowedTools: [WIZARD_TOOL_NAMES.wizardAsk],
|
|
2606
2577
|
run: {
|
|
@@ -3054,7 +3025,7 @@ const GROUPING = {
|
|
|
3054
3025
|
})
|
|
3055
3026
|
]
|
|
3056
3027
|
};
|
|
3057
|
-
const getContentBlocks = (store) => pace([
|
|
3028
|
+
const getContentBlocks$1 = (store) => pace([
|
|
3058
3029
|
{
|
|
3059
3030
|
content: "Welcome.",
|
|
3060
3031
|
pause: 3e3,
|
|
@@ -3212,7 +3183,7 @@ const errorTrackingUploadSourceMapsConfig = {
|
|
|
3212
3183
|
requiresAi: true,
|
|
3213
3184
|
steps: ERROR_TRACKING_UPLOAD_SOURCE_MAPS_PROGRAM,
|
|
3214
3185
|
reportFile: REPORT_FILE$1,
|
|
3215
|
-
getContentBlocks,
|
|
3186
|
+
getContentBlocks: getContentBlocks$1,
|
|
3216
3187
|
requires: ["posthog-integration"],
|
|
3217
3188
|
run: (_session) => {
|
|
3218
3189
|
const readSelection = () => {
|
|
@@ -3805,28 +3776,344 @@ STEP 7 — Write the report and hand off. (skill: "Report")
|
|
|
3805
3776
|
//#region src/lib/programs/self-driving/content/tips.ts
|
|
3806
3777
|
const SELF_DRIVING_TIPS = [
|
|
3807
3778
|
{
|
|
3808
|
-
id: "
|
|
3809
|
-
title: "
|
|
3810
|
-
description: "A
|
|
3779
|
+
id: "signal-source",
|
|
3780
|
+
title: "Signal source",
|
|
3781
|
+
description: "A stream PostHog watches: errors, replays, support, GitHub or Linear issues."
|
|
3811
3782
|
},
|
|
3812
3783
|
{
|
|
3813
|
-
id: "
|
|
3814
|
-
title: "
|
|
3815
|
-
description: "
|
|
3784
|
+
id: "scout",
|
|
3785
|
+
title: "Scout",
|
|
3786
|
+
description: "An agent on a schedule, watching your sources for anomalies and patterns."
|
|
3816
3787
|
},
|
|
3817
3788
|
{
|
|
3818
|
-
id: "
|
|
3819
|
-
title: "
|
|
3820
|
-
description: "
|
|
3789
|
+
id: "signal-report",
|
|
3790
|
+
title: "Signal → report",
|
|
3791
|
+
description: "One finding with evidence and a suggested action. Signals group into prioritized reports in your inbox."
|
|
3792
|
+
},
|
|
3793
|
+
{
|
|
3794
|
+
id: "the-loop",
|
|
3795
|
+
title: "The loop",
|
|
3796
|
+
description: "After a fix ships, PostHog measures the result. If the pattern persists, a new signal reopens the work."
|
|
3797
|
+
},
|
|
3798
|
+
{
|
|
3799
|
+
id: "work-anywhere",
|
|
3800
|
+
title: "Work anywhere",
|
|
3801
|
+
description: "Your inbox is in the PostHog app, Slack (tag @PostHog), and MCP. You can work from anywhere."
|
|
3821
3802
|
}
|
|
3822
3803
|
];
|
|
3823
3804
|
const getTips = () => SELF_DRIVING_TIPS;
|
|
3824
3805
|
//#endregion
|
|
3806
|
+
//#region src/lib/programs/self-driving/content/pipeline-diagram.tsx
|
|
3807
|
+
/**
|
|
3808
|
+
* PIPELINE_BLOCK — ASCII diagram of the Self-driving loop: sources feed
|
|
3809
|
+
* scouts, scouts raise signals, signals group into reports, reports land
|
|
3810
|
+
* in the inbox, shipped fixes get measured, and misses loop back as new
|
|
3811
|
+
* signals. Kept under ~38 chars wide so it fits the LearnCard pane at an
|
|
3812
|
+
* 80-column terminal.
|
|
3813
|
+
*/
|
|
3814
|
+
const PIPELINE_BLOCK = {
|
|
3815
|
+
type: "lines",
|
|
3816
|
+
interval: 300,
|
|
3817
|
+
pause: 8e3,
|
|
3818
|
+
lines: [
|
|
3819
|
+
/* @__PURE__ */ jsxs(Text, { children: [" ", /* @__PURE__ */ jsx(Text, {
|
|
3820
|
+
bold: true,
|
|
3821
|
+
color: "cyan",
|
|
3822
|
+
children: "signal sources"
|
|
3823
|
+
})] }),
|
|
3824
|
+
/* @__PURE__ */ jsx(Text, {
|
|
3825
|
+
dimColor: true,
|
|
3826
|
+
children: " errors · replays · support"
|
|
3827
|
+
}),
|
|
3828
|
+
/* @__PURE__ */ jsxs(Text, { children: [/* @__PURE__ */ jsx(Text, {
|
|
3829
|
+
color: "gray",
|
|
3830
|
+
children: " ↓ "
|
|
3831
|
+
}), /* @__PURE__ */ jsx(Text, {
|
|
3832
|
+
bold: true,
|
|
3833
|
+
color: Colors.accent,
|
|
3834
|
+
children: "scouts"
|
|
3835
|
+
})] }),
|
|
3836
|
+
/* @__PURE__ */ jsx(Text, {
|
|
3837
|
+
dimColor: true,
|
|
3838
|
+
children: " watching on a schedule"
|
|
3839
|
+
}),
|
|
3840
|
+
/* @__PURE__ */ jsxs(Text, { children: [/* @__PURE__ */ jsx(Text, {
|
|
3841
|
+
color: "gray",
|
|
3842
|
+
children: " ↓ "
|
|
3843
|
+
}), /* @__PURE__ */ jsx(Text, {
|
|
3844
|
+
bold: true,
|
|
3845
|
+
color: Colors.accent,
|
|
3846
|
+
children: "signals"
|
|
3847
|
+
})] }),
|
|
3848
|
+
/* @__PURE__ */ jsx(Text, {
|
|
3849
|
+
dimColor: true,
|
|
3850
|
+
children: " finding + evidence + action"
|
|
3851
|
+
}),
|
|
3852
|
+
/* @__PURE__ */ jsxs(Text, { children: [/* @__PURE__ */ jsx(Text, {
|
|
3853
|
+
color: "gray",
|
|
3854
|
+
children: " ↓ "
|
|
3855
|
+
}), /* @__PURE__ */ jsx(Text, {
|
|
3856
|
+
bold: true,
|
|
3857
|
+
color: Colors.accent,
|
|
3858
|
+
children: "reports"
|
|
3859
|
+
})] }),
|
|
3860
|
+
/* @__PURE__ */ jsx(Text, {
|
|
3861
|
+
dimColor: true,
|
|
3862
|
+
children: " grouped and prioritized"
|
|
3863
|
+
}),
|
|
3864
|
+
/* @__PURE__ */ jsxs(Text, { children: [/* @__PURE__ */ jsx(Text, {
|
|
3865
|
+
color: "gray",
|
|
3866
|
+
children: " ↓ "
|
|
3867
|
+
}), /* @__PURE__ */ jsx(Text, {
|
|
3868
|
+
bold: true,
|
|
3869
|
+
color: "green",
|
|
3870
|
+
children: "your inbox"
|
|
3871
|
+
})] }),
|
|
3872
|
+
/* @__PURE__ */ jsx(Text, {
|
|
3873
|
+
dimColor: true,
|
|
3874
|
+
children: " investigate · tag · ship a PR"
|
|
3875
|
+
}),
|
|
3876
|
+
/* @__PURE__ */ jsxs(Text, { children: [/* @__PURE__ */ jsx(Text, {
|
|
3877
|
+
color: "gray",
|
|
3878
|
+
children: " ↓ "
|
|
3879
|
+
}), /* @__PURE__ */ jsx(Text, {
|
|
3880
|
+
bold: true,
|
|
3881
|
+
color: Colors.accent,
|
|
3882
|
+
children: "measured"
|
|
3883
|
+
})] }),
|
|
3884
|
+
/* @__PURE__ */ jsxs(Text, { children: [/* @__PURE__ */ jsx(Text, {
|
|
3885
|
+
color: "cyan",
|
|
3886
|
+
children: " ↺ "
|
|
3887
|
+
}), /* @__PURE__ */ jsx(Text, {
|
|
3888
|
+
dimColor: true,
|
|
3889
|
+
children: "didn't fix it? a new signal"
|
|
3890
|
+
})] })
|
|
3891
|
+
]
|
|
3892
|
+
};
|
|
3893
|
+
//#endregion
|
|
3894
|
+
//#region src/lib/programs/self-driving/content/index.tsx
|
|
3895
|
+
/**
|
|
3896
|
+
* Self-driving learn-deck — the narrative script played while the agent
|
|
3897
|
+
* sets up Self-driving. Teaches the vocabulary ladder (signal source →
|
|
3898
|
+
* scout → signal → report → action → measured loop) before the agent's
|
|
3899
|
+
* questions use those nouns, and explains why GitHub is required before
|
|
3900
|
+
* the connect ask lands.
|
|
3901
|
+
*
|
|
3902
|
+
* One deck for every self-driving run. On the integrate path it plays
|
|
3903
|
+
* during the install run (the pane belongs to whichever run screen shows
|
|
3904
|
+
* first), so it doubles as the wait-time read.
|
|
3905
|
+
*/
|
|
3906
|
+
const CLEAR = {
|
|
3907
|
+
type: "clear",
|
|
3908
|
+
pause: 2e3
|
|
3909
|
+
};
|
|
3910
|
+
const getContentBlocks = (store) => {
|
|
3911
|
+
return [
|
|
3912
|
+
{
|
|
3913
|
+
content: "Welcome.",
|
|
3914
|
+
pause: 3e3,
|
|
3915
|
+
mode: 0,
|
|
3916
|
+
animationInterval: 160
|
|
3917
|
+
},
|
|
3918
|
+
{
|
|
3919
|
+
content: "The Wizard is an agent.",
|
|
3920
|
+
pause: 4e3
|
|
3921
|
+
},
|
|
3922
|
+
{
|
|
3923
|
+
content: "It's setting up PostHog Self-driving for this project.",
|
|
3924
|
+
pause: 5e3
|
|
3925
|
+
},
|
|
3926
|
+
{
|
|
3927
|
+
content: "We'll occasionally need your input. Stick around.",
|
|
3928
|
+
pause: 6e3
|
|
3929
|
+
},
|
|
3930
|
+
CLEAR,
|
|
3931
|
+
{
|
|
3932
|
+
pause: 5e3,
|
|
3933
|
+
persist: true,
|
|
3934
|
+
content: /* @__PURE__ */ jsx(StatusPeekTrigger, { store })
|
|
3935
|
+
},
|
|
3936
|
+
{
|
|
3937
|
+
pause: 6e3,
|
|
3938
|
+
content: /* @__PURE__ */ jsxs(Text, { children: [
|
|
3939
|
+
"Press",
|
|
3940
|
+
" ",
|
|
3941
|
+
/* @__PURE__ */ jsx(Text, {
|
|
3942
|
+
color: Colors.accent,
|
|
3943
|
+
bold: true,
|
|
3944
|
+
children: "S"
|
|
3945
|
+
}),
|
|
3946
|
+
" ",
|
|
3947
|
+
"to expand or collapse the status."
|
|
3948
|
+
] })
|
|
3949
|
+
},
|
|
3950
|
+
CLEAR,
|
|
3951
|
+
{
|
|
3952
|
+
content: "Your PostHog tools all share one data layer.",
|
|
3953
|
+
pause: 4e3
|
|
3954
|
+
},
|
|
3955
|
+
{
|
|
3956
|
+
content: "Analytics, replays, errors, flags: they all share the same users, mapped across every tool.",
|
|
3957
|
+
pause: 6e3
|
|
3958
|
+
},
|
|
3959
|
+
{
|
|
3960
|
+
content: "Together, they show how people really use your product.",
|
|
3961
|
+
pause: 5e3
|
|
3962
|
+
},
|
|
3963
|
+
{
|
|
3964
|
+
content: "Piecing that together used to be manual work. That's what Self-driving automates.",
|
|
3965
|
+
pause: 6e3
|
|
3966
|
+
},
|
|
3967
|
+
CLEAR,
|
|
3968
|
+
{
|
|
3969
|
+
content: "A coding agent sees your code, but not how your product is used.",
|
|
3970
|
+
pause: 5e3
|
|
3971
|
+
},
|
|
3972
|
+
{
|
|
3973
|
+
content: "PostHog knows what your users actually do.",
|
|
3974
|
+
pause: 4e3
|
|
3975
|
+
},
|
|
3976
|
+
{
|
|
3977
|
+
content: "Self-driving puts an agent in the loop.",
|
|
3978
|
+
pause: 5e3
|
|
3979
|
+
},
|
|
3980
|
+
{
|
|
3981
|
+
content: "That's why setup will ask to connect GitHub: so Self-driving can access your code and your context, together.",
|
|
3982
|
+
pause: 6e3
|
|
3983
|
+
},
|
|
3984
|
+
CLEAR,
|
|
3985
|
+
{
|
|
3986
|
+
content: "Each PostHog tool you enable is a signal source.",
|
|
3987
|
+
pause: 4e3
|
|
3988
|
+
},
|
|
3989
|
+
{
|
|
3990
|
+
content: "Errors, replays, support tickets, GitHub or Linear issues: they're all streams of product usage.",
|
|
3991
|
+
pause: 6e3
|
|
3992
|
+
},
|
|
3993
|
+
CLEAR,
|
|
3994
|
+
{
|
|
3995
|
+
content: "Scouts are agents that watch those sources on a schedule.",
|
|
3996
|
+
pause: 5e3
|
|
3997
|
+
},
|
|
3998
|
+
{
|
|
3999
|
+
content: "They look for anomalies and patterns: a spike in errors or a funnel quietly dropping.",
|
|
4000
|
+
pause: 6e3
|
|
4001
|
+
},
|
|
4002
|
+
{
|
|
4003
|
+
content: "Setup tunes your scouts to fit your product.",
|
|
4004
|
+
pause: 4e3
|
|
4005
|
+
},
|
|
4006
|
+
CLEAR,
|
|
4007
|
+
{
|
|
4008
|
+
content: "When a scout finds something worth your attention, that's a signal.",
|
|
4009
|
+
pause: 5e3
|
|
4010
|
+
},
|
|
4011
|
+
{
|
|
4012
|
+
content: "Each signal carries the finding, the evidence, and a suggested action.",
|
|
4013
|
+
pause: 5e3
|
|
4014
|
+
},
|
|
4015
|
+
{
|
|
4016
|
+
content: "Related signals group into reports, sorted by priority.",
|
|
4017
|
+
pause: 4e3
|
|
4018
|
+
},
|
|
4019
|
+
CLEAR,
|
|
4020
|
+
{
|
|
4021
|
+
content: "Here's the whole loop.",
|
|
4022
|
+
pause: 1e3
|
|
4023
|
+
},
|
|
4024
|
+
PIPELINE_BLOCK,
|
|
4025
|
+
CLEAR,
|
|
4026
|
+
{
|
|
4027
|
+
content: "Reports land in your Self-driving inbox.",
|
|
4028
|
+
pause: 4e3
|
|
4029
|
+
},
|
|
4030
|
+
{
|
|
4031
|
+
content: "Investigate with the agent, tag teammates, or kick off a PR.",
|
|
4032
|
+
pause: 6e3
|
|
4033
|
+
},
|
|
4034
|
+
CLEAR,
|
|
4035
|
+
{
|
|
4036
|
+
content: "And after the PR ships, PostHog measures the result.",
|
|
4037
|
+
pause: 5e3
|
|
4038
|
+
},
|
|
4039
|
+
{
|
|
4040
|
+
content: "Did the fix actually address the pattern?",
|
|
4041
|
+
pause: 4e3
|
|
4042
|
+
},
|
|
4043
|
+
{
|
|
4044
|
+
content: "If not, a new signal surfaces, and the loop keeps working.",
|
|
4045
|
+
pause: 6e3
|
|
4046
|
+
},
|
|
4047
|
+
CLEAR,
|
|
4048
|
+
{
|
|
4049
|
+
content: "Work with Self-driving wherever you already are:",
|
|
4050
|
+
pause: 2e3
|
|
4051
|
+
},
|
|
4052
|
+
{
|
|
4053
|
+
type: "lines",
|
|
4054
|
+
interval: 800,
|
|
4055
|
+
pause: 6e3,
|
|
4056
|
+
lines: [
|
|
4057
|
+
/* @__PURE__ */ jsxs(Text, { children: [
|
|
4058
|
+
/* @__PURE__ */ jsx(Text, {
|
|
4059
|
+
color: "cyan",
|
|
4060
|
+
children: " ◆ "
|
|
4061
|
+
}),
|
|
4062
|
+
/* @__PURE__ */ jsx(Text, {
|
|
4063
|
+
bold: true,
|
|
4064
|
+
children: "Inbox"
|
|
4065
|
+
}),
|
|
4066
|
+
/* @__PURE__ */ jsx(Text, {
|
|
4067
|
+
dimColor: true,
|
|
4068
|
+
children: " the PostHog web app"
|
|
4069
|
+
})
|
|
4070
|
+
] }),
|
|
4071
|
+
/* @__PURE__ */ jsxs(Text, { children: [
|
|
4072
|
+
/* @__PURE__ */ jsx(Text, {
|
|
4073
|
+
color: "cyan",
|
|
4074
|
+
children: " ◆ "
|
|
4075
|
+
}),
|
|
4076
|
+
/* @__PURE__ */ jsx(Text, {
|
|
4077
|
+
bold: true,
|
|
4078
|
+
children: "Slack"
|
|
4079
|
+
}),
|
|
4080
|
+
/* @__PURE__ */ jsx(Text, {
|
|
4081
|
+
dimColor: true,
|
|
4082
|
+
children: " tag @PostHog"
|
|
4083
|
+
})
|
|
4084
|
+
] }),
|
|
4085
|
+
/* @__PURE__ */ jsxs(Text, { children: [
|
|
4086
|
+
/* @__PURE__ */ jsx(Text, {
|
|
4087
|
+
color: "cyan",
|
|
4088
|
+
children: " ◆ "
|
|
4089
|
+
}),
|
|
4090
|
+
/* @__PURE__ */ jsx(Text, {
|
|
4091
|
+
bold: true,
|
|
4092
|
+
children: "MCP"
|
|
4093
|
+
}),
|
|
4094
|
+
/* @__PURE__ */ jsx(Text, {
|
|
4095
|
+
dimColor: true,
|
|
4096
|
+
children: " your agents and editors"
|
|
4097
|
+
})
|
|
4098
|
+
] })
|
|
4099
|
+
]
|
|
4100
|
+
},
|
|
4101
|
+
{
|
|
4102
|
+
content: "Product usage data becomes real, shippable change.",
|
|
4103
|
+
pause: 5e3
|
|
4104
|
+
},
|
|
4105
|
+
{
|
|
4106
|
+
content: "Your product drives itself.",
|
|
4107
|
+
pause: 1e4
|
|
4108
|
+
}
|
|
4109
|
+
];
|
|
4110
|
+
};
|
|
4111
|
+
//#endregion
|
|
3825
4112
|
//#region src/lib/programs/self-driving/index.ts
|
|
3826
4113
|
const SELF_DRIVING_SKILL_ID = "self-driving-setup";
|
|
3827
4114
|
const REPORT_FILE = "posthog-self-driving-report.md";
|
|
3828
4115
|
const DOCS_URL = "https://posthog.com/docs";
|
|
3829
|
-
const SUCCESS_MESSAGE = "Self-driving is on
|
|
4116
|
+
const SUCCESS_MESSAGE = "Self-driving is on. PostHog is scanning your project; first findings hit your inbox within ~30 minutes.";
|
|
3830
4117
|
const WIZARD_MARKER = ".posthog-wizard";
|
|
3831
4118
|
/**
|
|
3832
4119
|
* Remove the installed setup skill. It is transient orchestration
|
|
@@ -3867,7 +4154,7 @@ const run = {
|
|
|
3867
4154
|
buildOutroData: (_session, credentials) => {
|
|
3868
4155
|
return {
|
|
3869
4156
|
kind: "success",
|
|
3870
|
-
message:
|
|
4157
|
+
message: SUCCESS_MESSAGE,
|
|
3871
4158
|
primaryLink: {
|
|
3872
4159
|
label: "Your Self-driving inbox",
|
|
3873
4160
|
url: `${getUiHostFromHost(credentials.host).replace(/\/$/, "")}/project/${credentials.projectId}/inbox`
|
|
@@ -3875,9 +4162,10 @@ const run = {
|
|
|
3875
4162
|
nextSteps: {
|
|
3876
4163
|
heading: "In your inbox you can:",
|
|
3877
4164
|
items: [
|
|
3878
|
-
"
|
|
3879
|
-
"
|
|
3880
|
-
"Kick off
|
|
4165
|
+
"Investigate reports with the agent",
|
|
4166
|
+
"Tag teammates to loop them in",
|
|
4167
|
+
"Kick off a PR when you like the proposed fix",
|
|
4168
|
+
"Or work from Slack (tag @PostHog) and MCP"
|
|
3881
4169
|
]
|
|
3882
4170
|
},
|
|
3883
4171
|
reportFile: REPORT_FILE
|
|
@@ -3902,13 +4190,7 @@ const selfDrivingConfig = {
|
|
|
3902
4190
|
steps: SELF_DRIVING_PROGRAM,
|
|
3903
4191
|
run,
|
|
3904
4192
|
getTips,
|
|
3905
|
-
getContentBlocks
|
|
3906
|
-
const blocks = getContentBlocks$2(store);
|
|
3907
|
-
return blocks.map((b, i) => i === blocks.length - 1 && typeof b === "object" ? {
|
|
3908
|
-
...b,
|
|
3909
|
-
pause: 5e3
|
|
3910
|
-
} : b);
|
|
3911
|
-
}
|
|
4193
|
+
getContentBlocks
|
|
3912
4194
|
};
|
|
3913
4195
|
//#endregion
|
|
3914
4196
|
//#region src/lib/programs/mcp/index.ts
|
|
@@ -4047,7 +4329,7 @@ const agentSkillConfig = {
|
|
|
4047
4329
|
id: "agent-skill",
|
|
4048
4330
|
description: "Run an arbitrary context-mill skill",
|
|
4049
4331
|
steps: AGENT_SKILL_STEPS,
|
|
4050
|
-
getContentBlocks: getContentBlocks$
|
|
4332
|
+
getContentBlocks: getContentBlocks$3,
|
|
4051
4333
|
allowedTools: ["Agent"],
|
|
4052
4334
|
run: (session) => {
|
|
4053
4335
|
const skillId = session.skillId ?? "agent-skill";
|
|
@@ -4136,12 +4418,12 @@ const mcpAddCommand = {
|
|
|
4136
4418
|
function runMcpAdd(argv) {
|
|
4137
4419
|
const features = parseFeatures(argv.features);
|
|
4138
4420
|
(async () => {
|
|
4139
|
-
const { readApiKeyFromEnv } = await import("./env-api-key-
|
|
4421
|
+
const { readApiKeyFromEnv } = await import("./env-api-key-DDVkPQmo.js").then((n) => n.t);
|
|
4140
4422
|
const apiKey = argv.apiKey || readApiKeyFromEnv();
|
|
4141
4423
|
const debug = argv.debug;
|
|
4142
4424
|
const localMcp = argv.local;
|
|
4143
4425
|
try {
|
|
4144
|
-
const { startTUI } = await import("./start-tui-
|
|
4426
|
+
const { startTUI } = await import("./start-tui-BC3yp_wW.js");
|
|
4145
4427
|
const { buildSession } = await import("./wizard-session-C8W_6X0j.js");
|
|
4146
4428
|
const tui = startTUI(VERSION, Program.McpAdd);
|
|
4147
4429
|
tui.store.session = buildSession({
|
|
@@ -4154,7 +4436,7 @@ function runMcpAdd(argv) {
|
|
|
4154
4436
|
} catch (error) {
|
|
4155
4437
|
if (!isTUIUnavailable(error)) throw error;
|
|
4156
4438
|
setUI(new LoggingUI());
|
|
4157
|
-
const { addMCPServerToClientsStep } = await import("./add-mcp-server-to-clients-
|
|
4439
|
+
const { addMCPServerToClientsStep } = await import("./add-mcp-server-to-clients-Dtvqw5DO.js").then((n) => n.r);
|
|
4158
4440
|
await addMCPServerToClientsStep({
|
|
4159
4441
|
local: localMcp,
|
|
4160
4442
|
features,
|
|
@@ -4193,7 +4475,7 @@ function runMcpRemove(argv) {
|
|
|
4193
4475
|
const debug = argv.debug;
|
|
4194
4476
|
const localMcp = argv.local;
|
|
4195
4477
|
try {
|
|
4196
|
-
const { startTUI } = await import("./start-tui-
|
|
4478
|
+
const { startTUI } = await import("./start-tui-BC3yp_wW.js");
|
|
4197
4479
|
const { buildSession } = await import("./wizard-session-C8W_6X0j.js");
|
|
4198
4480
|
const tui = startTUI(VERSION, Program.McpRemove);
|
|
4199
4481
|
tui.store.session = buildSession({
|
|
@@ -4203,7 +4485,7 @@ function runMcpRemove(argv) {
|
|
|
4203
4485
|
});
|
|
4204
4486
|
} catch {
|
|
4205
4487
|
setUI(new LoggingUI());
|
|
4206
|
-
const { removeMCPServerFromClientsStep } = await import("./add-mcp-server-to-clients-
|
|
4488
|
+
const { removeMCPServerFromClientsStep } = await import("./add-mcp-server-to-clients-Dtvqw5DO.js").then((n) => n.r);
|
|
4207
4489
|
await removeMCPServerFromClientsStep({ local: localMcp });
|
|
4208
4490
|
}
|
|
4209
4491
|
})();
|
|
@@ -4225,7 +4507,7 @@ function runMcpTutorial(argv) {
|
|
|
4225
4507
|
const debug = argv.debug;
|
|
4226
4508
|
const localMcp = argv.local;
|
|
4227
4509
|
try {
|
|
4228
|
-
const { startTUI } = await import("./start-tui-
|
|
4510
|
+
const { startTUI } = await import("./start-tui-BC3yp_wW.js");
|
|
4229
4511
|
const { buildSession } = await import("./wizard-session-C8W_6X0j.js");
|
|
4230
4512
|
const tui = startTUI(VERSION, Program.McpTutorial);
|
|
4231
4513
|
tui.store.session = buildSession({
|
|
@@ -4306,10 +4588,10 @@ function runWizard(config, options) {
|
|
|
4306
4588
|
(async () => {
|
|
4307
4589
|
try {
|
|
4308
4590
|
const installDir = options.installDir || process.cwd();
|
|
4309
|
-
const { startTUI } = await import("./start-tui-
|
|
4591
|
+
const { startTUI } = await import("./start-tui-BC3yp_wW.js");
|
|
4310
4592
|
const { buildSession, RunPhase } = await import("./wizard-session-C8W_6X0j.js");
|
|
4311
|
-
const { TaskStreamPush } = await import("./task-stream-
|
|
4312
|
-
const { PostHogDestination } = await import("./posthog-
|
|
4593
|
+
const { TaskStreamPush } = await import("./task-stream-d-R9J0g4.js");
|
|
4594
|
+
const { PostHogDestination } = await import("./posthog-BHbtnNQE.js");
|
|
4313
4595
|
tui = startTUI(WIZARD_VERSION, config.id);
|
|
4314
4596
|
const activeTui = tui;
|
|
4315
4597
|
const session = buildSession({
|
|
@@ -4373,7 +4655,7 @@ function runWizard(config, options) {
|
|
|
4373
4655
|
if (shown(step)) await advanceStep(step, activeTui.store, config);
|
|
4374
4656
|
}
|
|
4375
4657
|
else if (skipAgent) {
|
|
4376
|
-
const { getOrAskForProjectData } = await import("./setup-utils-
|
|
4658
|
+
const { getOrAskForProjectData } = await import("./setup-utils-CUeGnxBk.js").then((n) => n.r);
|
|
4377
4659
|
const { projectApiKey, host, accessToken, projectId } = await getOrAskForProjectData({
|
|
4378
4660
|
signup: session.signup,
|
|
4379
4661
|
ci: session.ci,
|
|
@@ -4476,10 +4758,10 @@ function runNonInteractive(config, options, mode) {
|
|
|
4476
4758
|
(async () => {
|
|
4477
4759
|
const path = await import("path");
|
|
4478
4760
|
const { buildSession, RunPhase, OutroKind } = await import("./wizard-session-C8W_6X0j.js");
|
|
4479
|
-
const { readEnvironment } = await import("./environment-
|
|
4480
|
-
const { readApiKeyFromEnv } = await import("./env-api-key-
|
|
4481
|
-
const { configureLogFileFromEnvironment, logToFile } = await import("./debug-
|
|
4482
|
-
const { wizardAbort, WizardError } = await import("./wizard-abort-
|
|
4761
|
+
const { readEnvironment } = await import("./environment-4zKc7kWr.js").then((n) => n.t);
|
|
4762
|
+
const { readApiKeyFromEnv } = await import("./env-api-key-DDVkPQmo.js").then((n) => n.t);
|
|
4763
|
+
const { configureLogFileFromEnvironment, logToFile } = await import("./debug-dh-I1XvJ.js");
|
|
4764
|
+
const { wizardAbort, WizardError } = await import("./wizard-abort-DGM_sAA9.js");
|
|
4483
4765
|
configureLogFileFromEnvironment();
|
|
4484
4766
|
const env = readEnvironment();
|
|
4485
4767
|
const apiKey = options.apiKey ?? readApiKeyFromEnv() ?? void 0;
|
|
@@ -4510,9 +4792,9 @@ function runNonInteractive(config, options, mode) {
|
|
|
4510
4792
|
let store = null;
|
|
4511
4793
|
let taskStream = null;
|
|
4512
4794
|
if (mode === "headless") {
|
|
4513
|
-
const { WizardStore } = await import("./store-
|
|
4514
|
-
const { HeadlessUI } = await import("./headless-ui-
|
|
4515
|
-
const { TaskStreamPush, PostHogDestination } = await import("./task-stream-
|
|
4795
|
+
const { WizardStore } = await import("./store-DQ0-oE_Y.js").then((n) => n.n);
|
|
4796
|
+
const { HeadlessUI } = await import("./headless-ui-CjdRKkTG.js");
|
|
4797
|
+
const { TaskStreamPush, PostHogDestination } = await import("./task-stream-d-R9J0g4.js");
|
|
4516
4798
|
store = new WizardStore(config.id);
|
|
4517
4799
|
store.session = session;
|
|
4518
4800
|
setUI(new HeadlessUI(store));
|
|
@@ -4567,7 +4849,7 @@ function runNonInteractive(config, options, mode) {
|
|
|
4567
4849
|
});
|
|
4568
4850
|
}
|
|
4569
4851
|
}
|
|
4570
|
-
const { runAgent } = await import("./agent-runner-
|
|
4852
|
+
const { runAgent } = await import("./agent-runner-CqNL9x2D.js").then((n) => n.t);
|
|
4571
4853
|
await runAgent(config, session);
|
|
4572
4854
|
await settleStream(RunPhase.Completed);
|
|
4573
4855
|
} catch (error) {
|
|
@@ -5495,7 +5777,7 @@ async function runDoctorCI(options) {
|
|
|
5495
5777
|
getUI().intro("Welcome to the PostHog setup wizard");
|
|
5496
5778
|
getUI().log.info("Running posthog-doctor in CI mode");
|
|
5497
5779
|
try {
|
|
5498
|
-
const { getOrAskForProjectData } = await import("./setup-utils-
|
|
5780
|
+
const { getOrAskForProjectData } = await import("./setup-utils-CUeGnxBk.js").then((n) => n.r);
|
|
5499
5781
|
const { host, accessToken, projectId } = await getOrAskForProjectData({
|
|
5500
5782
|
signup: false,
|
|
5501
5783
|
ci: true,
|
|
@@ -5513,7 +5795,7 @@ async function runDoctorCI(options) {
|
|
|
5513
5795
|
for (const issue of sorted) getUI().log.info(` • [${issue.severity}] ${getKindMeta(issue.kind).title}`);
|
|
5514
5796
|
process.exit(1);
|
|
5515
5797
|
} catch (error) {
|
|
5516
|
-
const { ApiError } = await import("./api-
|
|
5798
|
+
const { ApiError } = await import("./api-D0RqJPWO.js").then((n) => n.n);
|
|
5517
5799
|
const message = error instanceof ApiError && error.statusCode === 401 ? "Your PostHog API key is invalid or expired." : error instanceof Error ? error.message : String(error);
|
|
5518
5800
|
getUI().log.error(`Doctor failed: ${message}`);
|
|
5519
5801
|
process.exit(1);
|
|
@@ -5595,7 +5877,7 @@ function runSlackConnect(argv) {
|
|
|
5595
5877
|
(async () => {
|
|
5596
5878
|
const debug = argv.debug;
|
|
5597
5879
|
try {
|
|
5598
|
-
const { startTUI } = await import("./start-tui-
|
|
5880
|
+
const { startTUI } = await import("./start-tui-BC3yp_wW.js");
|
|
5599
5881
|
const { buildSession } = await import("./wizard-session-C8W_6X0j.js");
|
|
5600
5882
|
const tui = startTUI(VERSION, Program.SlackConnect);
|
|
5601
5883
|
tui.store.session = buildSession({
|
|
@@ -5977,6 +6259,6 @@ function resolveInstallDir() {
|
|
|
5977
6259
|
}
|
|
5978
6260
|
Wizard.use(basicIntegrationCommand).use(mcpCommand).use(mcpAnalyticsCommand).use(cliCommand).use(auditCommand).use(doctorCommand).use(migrateCommand).use(revenueCommand).use(warehouseCommand).use(selfDrivingCommand).use(slackCommand).use(uploadSourcemapsCommand).use(skillCommand).init();
|
|
5979
6261
|
//#endregion
|
|
5980
|
-
export { STRIPE_SDKS as C, POSTHOG_SDKS as S, SOURCE_MAPS_CONTEXT_KEYS as _, ConfirmButton as a, getDetectedWarehouseSources as b, runWizardCI as c, Program as d, getProgramConfig as f, DISPLAY_NAME as g, AUTOMATABLE_VARIANTS as h, useKeyboardHintsContext as i, runWizard as l, SELF_DRIVING_INTEGRATE_PATH_KEY as m, useKeyBindings as n, PromptLabel as o, detectSelfDrivingIntegrationProjects as p, KeyboardHintsProvider as r, runWizardHeadless as s, PickerMenu as t, PROGRAM_REGISTRY as u, getKindMeta as v, getContentBlocks$
|
|
6262
|
+
export { STRIPE_SDKS as C, POSTHOG_SDKS as S, SOURCE_MAPS_CONTEXT_KEYS as _, ConfirmButton as a, getDetectedWarehouseSources as b, runWizardCI as c, Program as d, getProgramConfig as f, DISPLAY_NAME as g, AUTOMATABLE_VARIANTS as h, useKeyboardHintsContext as i, runWizard as l, SELF_DRIVING_INTEGRATE_PATH_KEY as m, useKeyBindings as n, PromptLabel as o, detectSelfDrivingIntegrationProjects as p, KeyboardHintsProvider as r, runWizardHeadless as s, PickerMenu as t, PROGRAM_REGISTRY as u, getKindMeta as v, getContentBlocks$3 as x, fetchHealthIssues as y };
|
|
5981
6263
|
|
|
5982
6264
|
//# sourceMappingURL=bin.js.map
|