@m-kopa/launchpad-cli 0.32.2 → 0.34.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 (40) hide show
  1. package/CHANGELOG.md +61 -0
  2. package/dist/cli.js +5612 -4534
  3. package/dist/commands/deploy.d.ts.map +1 -1
  4. package/dist/commands/init.d.ts.map +1 -1
  5. package/dist/commands/redeploy.d.ts +39 -0
  6. package/dist/commands/redeploy.d.ts.map +1 -0
  7. package/dist/commands/status.d.ts +31 -3
  8. package/dist/commands/status.d.ts.map +1 -1
  9. package/dist/commands/watch.d.ts +9 -0
  10. package/dist/commands/watch.d.ts.map +1 -0
  11. package/dist/deploy/served-verify.d.ts +12 -0
  12. package/dist/deploy/served-verify.d.ts.map +1 -1
  13. package/dist/deploy/verify-deploy.d.ts +18 -0
  14. package/dist/deploy/verify-deploy.d.ts.map +1 -1
  15. package/dist/dispatcher.d.ts.map +1 -1
  16. package/dist/secrets/push.d.ts +15 -0
  17. package/dist/secrets/push.d.ts.map +1 -1
  18. package/dist/version.d.ts +1 -1
  19. package/dist/watch/capabilities.d.ts +23 -0
  20. package/dist/watch/capabilities.d.ts.map +1 -0
  21. package/dist/watch/engine.d.ts +35 -0
  22. package/dist/watch/engine.d.ts.map +1 -0
  23. package/dist/watch/index.d.ts +19 -0
  24. package/dist/watch/index.d.ts.map +1 -0
  25. package/dist/watch/model.d.ts +69 -0
  26. package/dist/watch/model.d.ts.map +1 -0
  27. package/dist/watch/phases.d.ts +20 -0
  28. package/dist/watch/phases.d.ts.map +1 -0
  29. package/dist/watch/render.d.ts +55 -0
  30. package/dist/watch/render.d.ts.map +1 -0
  31. package/dist/watch/sanitize.d.ts +14 -0
  32. package/dist/watch/sanitize.d.ts.map +1 -0
  33. package/package.json +2 -1
  34. package/skills/launchpad-content-pr/SKILL.md +1 -1
  35. package/skills/launchpad-deploy/SKILL.md +17 -5
  36. package/skills/launchpad-deploy-status/SKILL.md +33 -4
  37. package/skills/launchpad-destroy/SKILL.md +1 -1
  38. package/skills/launchpad-identity/SKILL.md +1 -1
  39. package/skills/launchpad-onboard/SKILL.md +1 -1
  40. package/skills/launchpad-status/SKILL.md +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"deploy.d.ts","sourceRoot":"","sources":["../../src/commands/deploy.ts"],"names":[],"mappings":"AAyDA,OAAO,EAGL,4BAA4B,EAC7B,MAAM,uBAAuB,CAAC;AAM/B,OAAO,EAAa,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AACnF,OAAO,KAAK,EAAS,OAAO,EAAY,MAAM,kBAAkB,CAAC;AAKjE,OAAO,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,CAAC;AAEjD,eAAO,MAAM,aAAa,EAAE,OAI3B,CAAC;AAEF,UAAU,UAAU;IAClB,6BAA6B;IAC7B,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;CACjC;AAmQD;;;;;;GAMG;AACH,wBAAgB,WAAW,IAAI,MAAM,CAoBpC;AAED;;;GAGG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,GAAG,UAAU,GAAG,IAAI,CAwBpE;AA+KD,2BAA2B;AAC3B,OAAO,EAAE,4BAA4B,EAAE,CAAC"}
1
+ {"version":3,"file":"deploy.d.ts","sourceRoot":"","sources":["../../src/commands/deploy.ts"],"names":[],"mappings":"AA8DA,OAAO,EAGL,4BAA4B,EAC7B,MAAM,uBAAuB,CAAC;AAM/B,OAAO,EAAa,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AACnF,OAAO,KAAK,EAAS,OAAO,EAAY,MAAM,kBAAkB,CAAC;AAKjE,OAAO,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,CAAC;AAEjD,eAAO,MAAM,aAAa,EAAE,OAI3B,CAAC;AAEF,UAA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SAAS,CAAC;CACnC;AAED,MAAM,WAAW,WAAW;IAC1B,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;IACxB,QAAQ,CAAC,cAAc,EAAE,OAAO,CAAC;IACjC,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAC;IAC5B;;;;;OAKG;IACH,QAAQ,CAAC,UAAU,EAAE,OAAO,CAAC;CAC9B;AAED,iEAAiE;AACjE,MAAM,MAAM,QAAQ,GAAG,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,KAAK,OAAO,CAAC,MAAM,CAAC,CAAC;AAEhF,eAAO,MAAM,WAAW,EAAE,OAIzB,CAAC;AAEF,wBAAsB,OAAO,CAC3B,IAAI,EAAE,SAAS,MAAM,EAAE,EACvB,EAAE,EAAE,KAAK,EACT,MAAM,EAAE,QAAQ,GACf,OAAO,CAAC,QAAQ,CAAC,CAuJnB"}
@@ -0,0 +1,39 @@
1
+ import { type CliConfig } from "../config.js";
2
+ import type { CliIo, Command, ExitCode } from "../dispatcher.js";
3
+ import { type VerifyDeployArgs, type VerifyDeployDeps } from "../deploy/verify-deploy.js";
4
+ /** Bot response from `POST /apps/<slug>/redeploy`. */
5
+ export interface RedeployResponse {
6
+ readonly slug: string;
7
+ readonly appType?: string;
8
+ readonly tier?: "pages" | "worker";
9
+ readonly redeployed?: boolean;
10
+ readonly deploymentId?: string;
11
+ readonly previousDeploymentId?: string | null;
12
+ readonly newDeployment?: boolean;
13
+ readonly message?: string;
14
+ }
15
+ export interface RedeployOptions {
16
+ /** Explicit slug (positional / `--slug`). Null → infer from cwd. */
17
+ readonly slug: string | null;
18
+ /** Manifest path override (`--file`). */
19
+ readonly file: string | null;
20
+ /** Run post-redeploy served-verify (default true; `--no-verify` off). */
21
+ readonly verify: boolean;
22
+ readonly verifyTimeoutMs: number;
23
+ }
24
+ export interface RedeployDeps {
25
+ readonly config?: CliConfig;
26
+ readonly fetcher?: typeof fetch;
27
+ readonly cwd?: string;
28
+ /** Override the served-verify step (tests inject a stub). */
29
+ readonly runVerification?: (args: VerifyDeployArgs, io: CliIo, deps: VerifyDeployDeps) => Promise<ExitCode>;
30
+ readonly verifyDeps?: VerifyDeployDeps;
31
+ }
32
+ export declare const redeployCommand: Command;
33
+ /**
34
+ * The reusable redeploy core. `launchpad redeploy` calls it directly;
35
+ * `launchpad secrets push` calls it after an operator opts in to
36
+ * activating a just-pushed Pages secret.
37
+ */
38
+ export declare function runRedeploy(opts: RedeployOptions, io: CliIo, deps?: RedeployDeps): Promise<ExitCode>;
39
+ //# sourceMappingURL=redeploy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"redeploy.d.ts","sourceRoot":"","sources":["../../src/commands/redeploy.ts"],"names":[],"mappings":"AAsCA,OAAO,EAAc,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAS1D,OAAO,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAEjE,OAAO,EAGL,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACtB,MAAM,4BAA4B,CAAC;AAKpC,sDAAsD;AACtD,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,CAAC;IACnC,QAAQ,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;IAC9B,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,oBAAoB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9C,QAAQ,CAAC,aAAa,CAAC,EAAE,OAAO,CAAC;IACjC,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,MAAM,WAAW,eAAe;IAC9B,oEAAoE;IACpE,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,yCAAyC;IACzC,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,yEAAyE;IACzE,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IACzB,QAAQ,CAAC,eAAe,EAAE,MAAM,CAAC;CAClC;AAED,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,CAAC;IAC5B,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,KAAK,CAAC;IAChC,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC;IACtB,6DAA6D;IAC7D,QAAQ,CAAC,eAAe,CAAC,EAAE,CACzB,IAAI,EAAE,gBAAgB,EACtB,EAAE,EAAE,KAAK,EACT,IAAI,EAAE,gBAAgB,KACnB,OAAO,CAAC,QAAQ,CAAC,CAAC;IACvB,QAAQ,CAAC,UAAU,CAAC,EAAE,gBAAgB,CAAC;CACxC;AAID,eAAO,MAAM,eAAe,EAAE,OAI7B,CAAC;AAiBF;;;;GAIG;AACH,wBAAsB,WAAW,CAC/B,IAAI,EAAE,eAAe,EACrB,EAAE,EAAE,KAAK,EACT,IAAI,GAAE,YAAiB,GACtB,OAAO,CAAC,QAAQ,CAAC,CAoFnB"}
@@ -1,3 +1,4 @@
1
+ import { type CliConfig } from "../config.js";
1
2
  import { type DeploymentStatusView, type StandingExceptionView } from "../deploy/deployment-status.js";
2
3
  import { type Manifest } from "@m-kopa/launchpad-engine";
3
4
  import type { Command } from "../dispatcher.js";
@@ -7,6 +8,24 @@ interface StatusArgs {
7
8
  readonly file: string;
8
9
  readonly json: boolean;
9
10
  readonly strict: boolean;
11
+ /** `--watch`: delegate to the live `launchpad watch` renderer (sp-wtch7q). */
12
+ readonly watch: boolean;
13
+ }
14
+ /** The bot's `/apps/<slug>/lifecycle` response (sp-st5hw9) — mirrors the
15
+ * bot-side `LifecycleResponse`. Lets status show provisioning progress + a
16
+ * clear failed state instead of the misleading "no deployed manifest yet". */
17
+ export interface LifecycleView {
18
+ readonly slug: string;
19
+ readonly state: "provisioning" | "live" | "failed" | "destroying" | "destroyed" | "destroy_failed";
20
+ readonly stage?: string;
21
+ readonly submissionId?: string;
22
+ readonly failedAt?: {
23
+ readonly stage: string;
24
+ readonly message: string;
25
+ readonly retryable: boolean;
26
+ };
27
+ readonly liveUrl?: string;
28
+ readonly lifecycleReason?: string;
10
29
  }
11
30
  /** What status reports, in machine-readable form for downstream
12
31
  * consumers (M-1187 destroy, M-1189 update-skill). The lifecycle states
@@ -18,9 +37,13 @@ export interface StatusJsonOutput {
18
37
  * the app deploys via git integration / outside `launchpad deploy`
19
38
  * (sp-devlp1 AC6; the sp-gitst1 misreport fix). */
20
39
  | "live_content_untracked" | "in_sync" | "drift"
21
- /** The app is live and a deployed manifest exists, but there is no
22
- * local launchpad.yaml to compare against status degraded to the
23
- * live-truth-only view (fix/status-slug-inference Fault 2). */
40
+ /** The app is live and platform-tracked, but drift could not be
41
+ * evaluated. Two causes: (1) no local launchpad.yaml to compare
42
+ * against (fix/status-slug-inference Fault 2); (2) sp-stbld1 — a
43
+ * per-app-workspace app whose deployed manifest isn't retrievable
44
+ * via the legacy flat-file state endpoint (its sha lives outside
45
+ * TF). Either way the app is tracked and live — NOT
46
+ * `live_content_untracked`. `drift: null` distinguishes cause (1). */
24
47
  | "live_drift_unknown" | "no_deployed_manifest" | "destroying" | "destroyed" | "destroy_failed";
25
48
  readonly slug: string;
26
49
  /** Drift-evaluation discriminant (fix/status-slug-inference): emitted
@@ -56,6 +79,11 @@ export interface StatusJsonOutput {
56
79
  * Absent when the bot pre-dates the endpoint. */
57
80
  readonly standingExceptions?: readonly StandingExceptionView[];
58
81
  }
82
+ /** Fetch the app's provisioning lifecycle (sp-st5hw9). Returns null when the
83
+ * bot doesn't recognise the slug OR predates the endpoint — BOTH surface as a
84
+ * 404, so the caller degrades to the manifest-diff path (which raises a real
85
+ * not-found itself for a truly-unknown slug). Auth / forbidden propagate. */
86
+ export declare function fetchLifecycle(cfg: CliConfig, slug: string): Promise<LifecycleView | null>;
59
87
  /**
60
88
  * Compute drift over the v1 closed field set (AC5).
61
89
  *
@@ -1 +1 @@
1
- {"version":3,"file":"status.d.ts","sourceRoot":"","sources":["../../src/commands/status.ts"],"names":[],"mappings":"AA6CA,OAAO,EAGL,KAAK,oBAAoB,EACzB,KAAK,qBAAqB,EAC3B,MAAM,gCAAgC,CAAC;AASxC,OAAO,EAAqC,KAAK,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAC5F,OAAO,KAAK,EAAS,OAAO,EAAY,MAAM,kBAAkB,CAAC;AAEjE,eAAO,MAAM,aAAa,EAAE,OAI3B,CAAC;AAEF,UAAU,UAAU;IAClB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IACvB,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;CAC1B;AAuBD;;;uEAGuE;AACvE,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,KAAK,EACV,cAAc,GACd,qBAAqB,GACrB,iBAAiB;IACnB;;wDAEoD;OAClD,wBAAwB,GACxB,SAAS,GACT,OAAO;IACT;;oEAEgE;OAC9D,oBAAoB,GACpB,sBAAsB,GACtB,YAAY,GACZ,WAAW,GACX,gBAAgB,CAAC;IACrB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB;;;sEAGkE;IAClE,QAAQ,CAAC,KAAK,CAAC,EAAE,IAAI,CAAC;IACtB,0EAA0E;IAC1E,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,sDAAsD;IACtD,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtC,6DAA6D;IAC7D,QAAQ,CAAC,YAAY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;;;;;;;;GASG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,QAAQ,EACf,QAAQ,EAAE,QAAQ,GACjB,aAAa,CAAC;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,OAAO,CAAC;IAAC,QAAQ,EAAE,OAAO,CAAA;CAAE,CAAC,CA2DpE;AAuRD;0BAC0B;AAC1B,wBAAgB,SAAS,CACvB,IAAI,EAAE,SAAS,MAAM,EAAE,EACvB,GAAG,GAAE,MAAsB,EAC3B,IAAI,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,GAC5B,UAAU,GAAG,MAAM,CA2ErB"}
@@ -0,0 +1,9 @@
1
+ import type { Command } from "../dispatcher.js";
2
+ /** Resolve the slug from args or the cwd, or return an error string. */
3
+ export declare function resolveWatchSlug(args: readonly string[], cwd: string, warn: (line: string) => void): {
4
+ slug: string;
5
+ } | {
6
+ error: string;
7
+ };
8
+ export declare const watchCommand: Command;
9
+ //# sourceMappingURL=watch.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"watch.d.ts","sourceRoot":"","sources":["../../src/commands/watch.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,OAAO,EAAmB,MAAM,kBAAkB,CAAC;AAWjE,wEAAwE;AACxE,wBAAgB,gBAAgB,CAC9B,IAAI,EAAE,SAAS,MAAM,EAAE,EACvB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,GAC3B;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,GAAG;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,CA2BtC;AAYD,eAAO,MAAM,YAAY,EAAE,OAI1B,CAAC"}
@@ -1,6 +1,18 @@
1
1
  export type VerifyAppType = "static" | "react" | "react+api" | "container";
2
2
  export type VerifyVerdict = {
3
3
  readonly kind: "match";
4
+ }
5
+ /**
6
+ * The served entrypoint responded 200 but its bytes were NOT compared
7
+ * to the shipped source — the honest signal for an app whose build
8
+ * transforms source → output (react / react+api), where byte-equality
9
+ * is meaningless. Distinct from `match` so a caller never claims
10
+ * "serves exactly what you shipped" for content it never verified
11
+ * (sp-rdpl41 blocking finding: a redeploy that re-runs a
12
+ * non-deterministic build could swap served bytes undetectably).
13
+ */
14
+ | {
15
+ readonly kind: "reachable";
4
16
  } | {
5
17
  readonly kind: "mismatch";
6
18
  readonly servedHash: string;
@@ -1 +1 @@
1
- {"version":3,"file":"served-verify.d.ts","sourceRoot":"","sources":["../../src/deploy/served-verify.ts"],"names":[],"mappings":"AAmBA,MAAM,MAAM,aAAa,GAAG,QAAQ,GAAG,OAAO,GAAG,WAAW,GAAG,WAAW,CAAC;AAE3E,MAAM,MAAM,aAAa,GACrB;IAAE,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAA;CAAE,GAC1B;IACE,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;IAC1B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;CAC7B,GACD;IAAE,QAAQ,CAAC,IAAI,EAAE,aAAa,CAAC;IAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAAC;AAExF,MAAM,WAAW,UAAU;IACzB,QAAQ,CAAC,KAAK,EAAE,OAAO,KAAK,CAAC;CAC9B;AAED,MAAM,WAAW,UAAU;IACzB,wEAAwE;IACxE,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,iEAAiE;IACjE,QAAQ,CAAC,iBAAiB,EAAE,UAAU,GAAG,MAAM,CAAC;IAChD,QAAQ,CAAC,OAAO,EAAE,aAAa,CAAC;CACjC;AAUD;;;;GAIG;AACH,wBAAsB,YAAY,CA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ExitCode } from "../dispatcher.js";
2
2
  import { type SettleOutcome, type WaitArgs, type WaitDeps } from "./wait-for-deployment.js";
3
3
  import { type VerifyVerdict, type VerifyArgs, type VerifyDeps, type VerifyAppType } from "./served-verify.js";
4
4
  import type { CliConfig } from "../config.js";
5
+ import { type LifecycleView } from "../commands/status.js";
5
6
  /** EX_DATAERR — the live deployment serves content that doesn't match what shipped. */
6
7
  export declare const VERIFY_MISMATCH_EXIT = 65;
7
8
  export interface VerifyDeployArgs {
@@ -22,4 +23,21 @@ export interface VerifyDeployDeps {
22
23
  export declare function readLocalEntrypoint(cwd: string): Uint8Array | null;
23
24
  export declare function realVerifyDeployDeps(cfg: CliConfig): VerifyDeployDeps;
24
25
  export declare function runDeployVerification(args: VerifyDeployArgs, io: CliIo, deps: VerifyDeployDeps): Promise<ExitCode>;
26
+ export interface FirstDeployVerifyArgs {
27
+ readonly slug: string;
28
+ readonly cwd: string;
29
+ readonly appType: VerifyAppType;
30
+ readonly timeoutMs: number;
31
+ readonly pollIntervalMs?: number;
32
+ }
33
+ export interface FirstDeployVerifyDeps {
34
+ readonly fetchLifecycle: (slug: string) => Promise<LifecycleView | null>;
35
+ readonly verify: (args: VerifyArgs, deps: VerifyDeps) => Promise<VerifyVerdict>;
36
+ readonly readLocalEntrypoint: (cwd: string) => Uint8Array | null;
37
+ readonly verifyDeps: VerifyDeps;
38
+ readonly sleep: (ms: number) => Promise<void>;
39
+ readonly now: () => number;
40
+ }
41
+ export declare function realFirstDeployVerifyDeps(cfg: CliConfig): FirstDeployVerifyDeps;
42
+ export declare function runFirstDeployVerification(args: FirstDeployVerifyArgs, io: CliIo, deps: FirstDeployVerifyDeps): Promise<ExitCode>;
25
43
  //# sourceMappingURL=verify-deploy.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"verify-deploy.d.ts","sourceRoot":"","sources":["../../src/deploy/verify-deploy.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,MAA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AAE,KAAK,EACT,IAAI,EAAE,qBAAqB,GAC1B,OAAO,CAAC,QAAQ,CAAC,CAkDnB"}
@@ -1 +1 @@
1
- {"version":3,"file":"dispatcher.d.ts","sourceRoot":"","sources":["../src/dispatcher.ts"],"names":[],"mappings":"AAmDA,MAAM,WAAW,KAAK;IACpB,sDAAsD;IACtD,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,wCAAwC;IACxC,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CACtC;AAED,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC;AAE9B,MAAM,WAAW,OAAO;IACtB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,EAAE,EAAE,EAAE,KAAK,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAC;IACxE;;;OAGG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED;;;;GAIG;AACH,eAAO,MAAM,QAAQ,EAAE,SAAS,OAAO,EAiCtC,CAAC;AAEF;;;GAGG;AACH,wBAAsB,QAAQ,CAC5B,IAAI,EAAE,SAAS,MAAM,EAAE,EACvB,EAAE,EAAE,KAAK,EACT,QAAQ,GAAE,SAAS,OAAO,EAAa,GACtC,OAAO,CAAC,QAAQ,CAAC,CAmBnB;AAED,wBAAgB,SAAS,CAAC,EAAE,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,OAAO,EAAE,GAAG,IAAI,CAyBvE"}
1
+ {"version":3,"file":"dispatcher.d.ts","sourceRoot":"","sources":["../src/dispatcher.ts"],"names":[],"mappings":"AAqDA,MAAM,WAAW,KAAK;IACpB,sDAAsD;IACtD,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,wCAAwC;IACxC,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CACtC;AAED,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC;AAE9B,MAAM,WAAW,OAAO;IACtB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,EAAE,EAAE,EAAE,KAAK,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAC;IACxE;;;OAGG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED;;;;GAIG;AACH,eAAO,MAAM,QAAQ,EAAE,SAAS,OAAO,EAmCtC,CAAC;AAEF;;;GAGG;AACH,wBAAsB,QAAQ,CAC5B,IAAI,EAAE,SAAS,MAAM,EAAE,EACvB,EAAE,EAAE,KAAK,EACT,QAAQ,GAAE,SAAS,OAAO,EAAa,GACtC,OAAO,CAAC,QAAQ,CAAC,CAmBnB;AAED,wBAAgB,SAAS,CAAC,EAAE,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,OAAO,EAAE,GAAG,IAAI,CAyBvE"}
@@ -1,13 +1,28 @@
1
1
  import { type CliConfig } from "../config.js";
2
+ import { type RedeployOptions, type RedeployDeps } from "../commands/redeploy.js";
2
3
  import type { CliIo, ExitCode } from "../dispatcher.js";
3
4
  export interface PushOptions {
4
5
  readonly file: string | null;
5
6
  readonly env: string | null;
6
7
  readonly dryRun: boolean;
8
+ /**
9
+ * Auto-activate a just-pushed Pages secret by redeploying, without an
10
+ * interactive prompt (`--redeploy` / `--yes`). Default false: an
11
+ * interactive TTY is asked; a non-interactive run prints the hint and
12
+ * does NOT trigger a deploy. Push + deploy stay decoupled by default
13
+ * (no silent prod deploy — sp-rdpl41 AC3).
14
+ */
15
+ readonly redeploy?: boolean;
7
16
  }
8
17
  export interface PushDeps {
9
18
  readonly config?: CliConfig;
10
19
  readonly fetcher?: typeof fetch;
20
+ /** Override TTY detection (tests). Default: `process.stdin.isTTY`. */
21
+ readonly isTty?: () => boolean;
22
+ /** Override the interactive prompt (tests). */
23
+ readonly prompt?: (question: string) => Promise<string>;
24
+ /** Override the redeploy trigger (tests). */
25
+ readonly runRedeploy?: (opts: RedeployOptions, io: CliIo, deps?: RedeployDeps) => Promise<ExitCode>;
11
26
  }
12
27
  export declare function runSecretsPush(opts: PushOptions, io: CliIo, deps?: PushDeps): Promise<ExitCode>;
13
28
  //# sourceMappingURL=push.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"push.d.ts","sourceRoot":"","sources":["../../src/secrets/push.ts"],"names":[],"mappings":"AAiDA,OAAO,EAAc,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAW1D,OAAO,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAExD,MAAM,WAAW,WAAW;IAC1B,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;CAC1B;AAED,MAAM,WAAW,QAAQ;IACvB,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,CAAC;IAC5B,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,KAAK,CAAC;CACjC;AAcD,wBAAsB,cAAc,CAClC,IAAI,EAAE,WAAW,EACjB,EAAE,EAAE,KAAK,EACT,IAAI,GAAE,QAAa,GAClB,OAAO,CAAC,QAAQ,CAAC,CAqLnB"}
1
+ {"version":3,"file":"push.d.ts","sourceRoot":"","sources":["../../src/secrets/push.ts"],"names":[],"mappings":"AAmDA,OAAO,EAAc,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAW1D,OAAO,EAAe,KAAK,eAAe,EAAE,KAAK,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAC/F,OAAO,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAExD,MAAM,WAAW,WAAW;IAC1B,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IACzB;;;;;;OAMG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;CAC7B;AAED,MAAM,WAAW,QAAQ;IACvB,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,CAAC;IAC5B,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,KAAK,CAAC;IAChC,sEAAsE;IACtE,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,OAAO,CAAC;IAC/B,+CAA+C;IAC/C,QAAQ,CAAC,MAAM,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,MAAM,CAAC,CAAC;IACxD,6CAA6C;IAC7C,QAAQ,CAAC,WAAW,CAAC,EAAE,CACrB,IAAI,EAAE,eAAe,EACrB,EAAE,EAAE,KAAK,EACT,IAAI,CAAC,EAAE,YAAY,KAChB,OAAO,CAAC,QAAQ,CAAC,CAAC;CACxB;AAcD,wBAAsB,cAAc,CAClC,IAAI,EAAE,WAAW,EACjB,EAAE,EAAE,KAAK,EACT,IAAI,GAAE,QAAa,GAClB,OAAO,CAAC,QAAQ,CAAC,CA2MnB"}
package/dist/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const CLI_VERSION = "0.32.2";
1
+ export declare const CLI_VERSION = "0.34.0";
2
2
  //# sourceMappingURL=version.d.ts.map
@@ -0,0 +1,23 @@
1
+ export type RenderTier = "inline" | "ascii" | "append" | "plain";
2
+ export interface TerminalCaps {
3
+ readonly isTTY: boolean;
4
+ /** Cursor-control / VT escape sequences are safe to emit. */
5
+ readonly ansi: boolean;
6
+ /** Unicode box/braille glyphs render correctly. */
7
+ readonly unicode: boolean;
8
+ }
9
+ export interface ProbeEnv {
10
+ readonly platform: NodeJS.Platform;
11
+ readonly env: NodeJS.ProcessEnv;
12
+ readonly isTTY: boolean;
13
+ }
14
+ export declare function probeCapabilities(p: ProbeEnv): TerminalCaps;
15
+ export declare function selectTier(caps: TerminalCaps): RenderTier;
16
+ /** Convenience: probe the live process + pick a tier. */
17
+ export declare function detectTier(stream?: {
18
+ isTTY?: boolean;
19
+ }): {
20
+ caps: TerminalCaps;
21
+ tier: RenderTier;
22
+ };
23
+ //# sourceMappingURL=capabilities.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"capabilities.d.ts","sourceRoot":"","sources":["../../src/watch/capabilities.ts"],"names":[],"mappings":"AAaA,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEjE,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;IACxB,6DAA6D;IAC7D,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IACvB,mDAAmD;IACnD,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;CAC3B;AAED,MAAM,WAAW,QAAQ;IACvB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC,QAAQ,CAAC;IACnC,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC,UAAU,CAAC;IAChC,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;CACzB;AAqBD,wBAAgB,iBAAiB,CAAC,CAAC,EAAE,QAAQ,GAAG,YAAY,CAsB3D;AAED,wBAAgB,UAAU,CAAC,IAAI,EAAE,YAAY,GAAG,UAAU,CAIzD;AAED,yDAAyD;AACzD,wBAAgB,UAAU,CAAC,MAAM,GAAE;IAAE,KAAK,CAAC,EAAE,OAAO,CAAA;CAAmB,GAAG;IACxE,IAAI,EAAE,YAAY,CAAC;IACnB,IAAI,EAAE,UAAU,CAAC;CAClB,CAOA"}
@@ -0,0 +1,35 @@
1
+ import { type LifecycleSnapshot, type WatchSnapshot } from "./model.js";
2
+ export type WatchOutcome = "live" | "failed" | "timeout" | "interrupted" | "not_found";
3
+ export interface WatchEngineDeps {
4
+ /** One poll. Resolves to the lifecycle, or null when the slug is
5
+ * unknown to the bot (terminal: nothing to watch). Throws on transient
6
+ * / network / 5xx errors (the loop backs off and retries). */
7
+ readonly fetchLifecycle: () => Promise<LifecycleSnapshot | null>;
8
+ readonly now: () => number;
9
+ /** Resolves after `ms`, or early if `signal` aborts. */
10
+ readonly sleep: (ms: number, signal: AbortSignal) => Promise<void>;
11
+ /** Aborts the watch (wired to SIGINT/SIGTERM by the caller). */
12
+ readonly signal: AbortSignal;
13
+ /** Called every poll with the latest snapshot (the live frame). */
14
+ readonly onTick: (snapshot: WatchSnapshot) => void;
15
+ /** Called once on a terminal state (live/failed) with the final frame. */
16
+ readonly onTerminal: (snapshot: WatchSnapshot) => void;
17
+ /** Non-fatal: a transient poll error the loop is retrying. */
18
+ readonly onPollError?: (error: unknown, nextRetryMs: number) => void;
19
+ }
20
+ export interface WatchEngineOptions {
21
+ readonly pollIntervalMs?: number;
22
+ readonly backoffFactor?: number;
23
+ readonly maxBackoffMs?: number;
24
+ readonly maxDurationMs?: number;
25
+ }
26
+ export interface WatchResult {
27
+ readonly outcome: WatchOutcome;
28
+ /** The last snapshot rendered (null only if the very first poll said
29
+ * the slug is unknown). */
30
+ readonly snapshot: WatchSnapshot | null;
31
+ }
32
+ export declare function runWatchLoop(slug: string, deps: WatchEngineDeps, options?: WatchEngineOptions): Promise<WatchResult>;
33
+ /** Real interruptible sleep (production). */
34
+ export declare function makeRealSleep(): (ms: number, signal: AbortSignal) => Promise<void>;
35
+ //# sourceMappingURL=engine.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"engine.d.ts","sourceRoot":"","sources":["../../src/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;AAED,wBAAsB,YAAY,CAChC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,eAAe,EACrB,OAAO,GAAE,kBAAuB,GAC/B,OAAO,CAAC,WAAW,CAAC,CA2CtB;AAED,6CAA6C;AAC7C,wBAAgB,aAAa,IAAI,CAAC,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,WAAW,KAAK,OAAO,CAAC,IAAI,CAAC,CAclF"}
@@ -0,0 +1,19 @@
1
+ import type { CliIo, ExitCode } from "../dispatcher.js";
2
+ import { type WatchEngineOptions } from "./engine.js";
3
+ export interface RunWatchDeps {
4
+ readonly now?: () => number;
5
+ readonly stdout?: {
6
+ isTTY?: boolean;
7
+ write: (s: string) => void;
8
+ };
9
+ /** Test seam for signal registration; defaults to process. */
10
+ readonly onSignal?: (handler: () => void) => () => void;
11
+ readonly engineOptions?: WatchEngineOptions;
12
+ }
13
+ /**
14
+ * Watch a slug provision to live. Returns an exit code:
15
+ * 0 live (or timed-out-but-still-going); 1 failed / not-found;
16
+ * 2 auth/transport; 130 interrupted (Ctrl-C).
17
+ */
18
+ export declare function runWatch(slug: string, io: CliIo, deps?: RunWatchDeps): Promise<ExitCode>;
19
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/watch/index.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAExD,OAAO,EAA+B,KAAK,kBAAkB,EAAE,MAAM,aAAa,CAAC;AA6CnF,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,MAAM,CAAC;IAC5B,QAAQ,CAAC,MAAM,CAAC,EAAE;QAAE,KAAK,CAAC,EAAE,OAAO,CAAC;QAAC,KAAK,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;KAAE,CAAC;IAClE,8DAA8D;IAC9D,QAAQ,CAAC,QAAQ,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,IAAI,KAAK,MAAM,IAAI,CAAC;IACxD,QAAQ,CAAC,aAAa,CAAC,EAAE,kBAAkB,CAAC;CAC7C;AAWD;;;;GAIG;AACH,wBAAsB,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,KAAK,EAAE,IAAI,GAAE,YAAiB,GAAG,OAAO,CAAC,QAAQ,CAAC,CA2ElG"}
@@ -0,0 +1,69 @@
1
+ import { type PhaseName } from "./phases.js";
2
+ /** The subset of the bot's LifecycleView the watcher consumes. */
3
+ export interface LifecycleSnapshot {
4
+ readonly state: "provisioning" | "live" | "failed" | "destroying" | "destroyed" | "destroy_failed";
5
+ readonly stage?: string;
6
+ readonly failedAt?: {
7
+ readonly stage: string;
8
+ readonly message: string;
9
+ readonly retryable: boolean;
10
+ };
11
+ readonly liveUrl?: string;
12
+ }
13
+ export type PhaseStatus = "pending" | "active" | "done" | "failed";
14
+ export interface PhaseView {
15
+ readonly name: PhaseName;
16
+ readonly status: PhaseStatus;
17
+ /** Observed client-side elapsed for this phase, or null when unknown
18
+ * (the phase completed before the watch attached, or hasn't started). */
19
+ readonly elapsedMs: number | null;
20
+ }
21
+ export type Terminal = "live" | "failed" | null;
22
+ export interface WatchSnapshot {
23
+ readonly slug: string;
24
+ readonly phases: readonly PhaseView[];
25
+ readonly currentStage: string | null;
26
+ /** N in "stage N/15" (15 when live). */
27
+ readonly stageOrdinal: number | null;
28
+ readonly totalStages: number;
29
+ readonly terminal: Terminal;
30
+ readonly failure: {
31
+ readonly stage: string;
32
+ readonly message: string;
33
+ readonly retryable: boolean;
34
+ } | null;
35
+ readonly liveUrl: string | null;
36
+ readonly startedAtMs: number;
37
+ readonly elapsedTotalMs: number;
38
+ }
39
+ /**
40
+ * Accumulates lifecycle observations into a renderable snapshot. One
41
+ * instance per watch session; `ingest` is called once per poll tick.
42
+ */
43
+ export declare class WatchModel {
44
+ private readonly slug;
45
+ private startedAtMs;
46
+ /** First time each stage was observed (client-side). */
47
+ private readonly stageFirstSeen;
48
+ /** Order in which stages were first observed. */
49
+ private readonly observedOrder;
50
+ private currentStage;
51
+ private terminal;
52
+ private failure;
53
+ private liveUrl;
54
+ constructor(slug: string);
55
+ /** Fold one poll result into the model. */
56
+ ingest(view: LifecycleSnapshot, nowMs: number): void;
57
+ /** True once a terminal (live/failed) state has been observed. */
58
+ isTerminal(): boolean;
59
+ /** Render the current snapshot as of `nowMs`. */
60
+ snapshot(nowMs: number): WatchSnapshot;
61
+ /**
62
+ * Observed elapsed for a phase: from the first observed stage in the
63
+ * phase to the first observed stage of a LATER phase (or `nowMs` if the
64
+ * phase is still the active one). null when we never observed the
65
+ * phase's start (it completed before the watch attached).
66
+ */
67
+ private phaseElapsed;
68
+ }
69
+ //# sourceMappingURL=model.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../src/watch/model.ts"],"names":[],"mappings":"AAWA,OAAO,EAEL,KAAK,SAAS,EAKf,MAAM,aAAa,CAAC;AAErB,kEAAkE;AAClE,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,KAAK,EACV,cAAc,GACd,MAAM,GACN,QAAQ,GACR,YAAY,GACZ,WAAW,GACX,gBAAgB,CAAC;IACrB,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,QAAQ,CAAC,EAAE;QAClB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;QACvB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;QACzB,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAC;KAC7B,CAAC;IACF,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,MAAM,MAAM,WAAW,GAAG,SAAS,GAAG,QAAQ,GAAG,MAAM,GAAG,QAAQ,CAAC;AAEnE,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,IAAI,EAAE,S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,IAAI,EAAE,MAAM;IAEzC,2CAA2C;IAC3C,MAAM,CAAC,IAAI,EAAE,iBAAiB,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI;IAmBpD,kEAAkE;IAClE,UAAU,IAAI,OAAO;IAIrB,iDAAiD;IACjD,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,aAAa;IAsDtC;;;;;OAKG;IACH,OAAO,CAAC,YAAY;CA4BrB"}
@@ -0,0 +1,20 @@
1
+ /** The six phases, in display order. */
2
+ export declare const PHASE_NAMES: readonly ["Repo", "Build", "Infra", "Certificate", "Access", "Verify"];
3
+ export type PhaseName = (typeof PHASE_NAMES)[number];
4
+ /**
5
+ * The 15 working stages in happy-path order. `done` is terminal and is
6
+ * NOT a working stage — reaching it means the Verify phase is complete
7
+ * (the app is live). `stage N/15` uses a stage's index in this array.
8
+ */
9
+ export declare const STAGE_ORDER: readonly ["pending", "repo_created", "bootstrap_pr_opened", "bootstrap_pr_merged", "content_seeded", "tf_pr_opened", "tf_pr_merged", "tf_applied", "cert_active", "policy_attached", "tf_env_pr_opened", "tf_env_pr_merged", "tf_env_applied", "ready_for_content", "deployment_verified"];
10
+ export declare const TOTAL_STAGES: 15;
11
+ /** 1-based ordinal of a working stage, or null if not a working stage. */
12
+ export declare function ordinalOfStage(stage: string): number | null;
13
+ /**
14
+ * The phase a stage belongs to. Returns null for an unrecognised stage
15
+ * (the model then keeps the last-known active phase rather than guessing).
16
+ */
17
+ export declare function phaseOfStage(stage: string): PhaseName | null;
18
+ /** Index of a phase in PHASE_NAMES (display/ordering), or -1. */
19
+ export declare function phaseIndex(phase: PhaseName): number;
20
+ //# sourceMappingURL=phases.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"phases.d.ts","sourceRoot":"","sources":["../../src/watch/phases.ts"],"names":[],"mappings":"AAWA,wCAAwC;AACxC,eAAO,MAAM,WAAW,wEAOd,CAAC;AAEX,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,WAAW,CAAC,CAAC,MAAM,CAAC,CAAC;AAErD;;;;GAIG;AACH,eAAO,MAAM,WAAW,4RAgBd,CAAC;AAEX,eAAO,MAAM,YAAY,IAAqB,CAAC;AAmC/C,0EAA0E;AAC1E,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAG3D;AAED;;;GAGG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,GAAG,IAAI,CAE5D;AAED,iEAAiE;AACjE,wBAAgB,UAAU,CAAC,KAAK,EAAE,SAAS,GAAG,MAAM,CAEnD"}
@@ -0,0 +1,55 @@
1
+ import type { RenderTier } from "./capabilities.js";
2
+ import type { WatchSnapshot } from "./model.js";
3
+ type GlyphStyle = "unicode" | "ascii";
4
+ export declare const CURSOR_HIDE = "\u001B[?25l";
5
+ export declare const CURSOR_SHOW = "\u001B[?25h";
6
+ export declare function styleForTier(tier: RenderTier): GlyphStyle;
7
+ export declare function launchpadUrl(slug: string): string;
8
+ /** ms → "M:SS" (or `dash` when unknown/null). */
9
+ export declare function formatDuration(ms: number | null, dash?: string): string;
10
+ /** The live provisioning frame (multi-line) for inline/ascii tiers. */
11
+ export declare function renderProvisioningFrame(s: WatchSnapshot, opts: {
12
+ style: GlyphStyle;
13
+ spinnerFrame: number;
14
+ }): string;
15
+ /** One-line compact update for the append-only tier. */
16
+ export declare function renderAppendLine(s: WatchSnapshot, opts: {
17
+ style: GlyphStyle;
18
+ spinnerFrame: number;
19
+ }): string;
20
+ /**
21
+ * Plain, ASCII-only, escape-free line for the non-TTY tier (pipes / CI).
22
+ * Mirrors the existing `launchpad status` one-liner style so piped output
23
+ * stays familiar and never carries control sequences.
24
+ */
25
+ export declare function renderPlainLine(s: WatchSnapshot): string;
26
+ /** Final LIVE frame. */
27
+ export declare function renderLiveFrame(s: WatchSnapshot, opts: {
28
+ style: GlyphStyle;
29
+ }): string;
30
+ /** Final FAILED frame. */
31
+ export declare function renderFailedFrame(s: WatchSnapshot, opts: {
32
+ style: GlyphStyle;
33
+ }): string;
34
+ /**
35
+ * Owns the cursor mechanics for the redraw tiers. `write` receives raw
36
+ * strings (the renderer's own trusted ANSI + already-sanitised content).
37
+ */
38
+ export declare class Renderer {
39
+ private readonly write;
40
+ private readonly tier;
41
+ private prevLines;
42
+ private spinnerFrame;
43
+ private cursorHidden;
44
+ private readonly style;
45
+ constructor(write: (s: string) => void, tier: RenderTier);
46
+ /** Per-poll live frame. No-op for the plain tier (caller handles it). */
47
+ tick(s: WatchSnapshot): void;
48
+ /** Final frame; settles the view (no spinner) and restores the cursor. */
49
+ terminal(s: WatchSnapshot): void;
50
+ /** Restore the terminal on any exit path (also called from signal handlers). */
51
+ restoreCursor(): void;
52
+ private redraw;
53
+ }
54
+ export {};
55
+ //# sourceMappingURL=render.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"render.d.ts","sourceRoot":"","sources":["../../src/watch/render.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAEpD,OAAO,KAAK,EAAe,aAAa,EAAE,MAAM,YAAY,CAAC;AAE7D,KAAK,UAAU,GAAG,SAAS,GAAG,OAAO,CAAC;AAoCtC,eAAO,MAAM,WAAW,gBAAgB,CAAC;AACzC,eAAO,MAAM,WAAW,gBAAgB,CAAC;AAIzC,wBAAgB,YAAY,CAAC,IAAI,EAAE,UAAU,GAAG,UAAU,CAEzD;AAED,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAEjD;AAED,iDAAiD;AACjD,wBAAgB,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,EAAE,IAAI,SAAM,GAAG,MAAM,CAMpE;AAqBD,uEAAuE;AACvE,wBAAgB,uBAAuB,CACrC,CAAC,EAAE,aAAa,EAChB,IAAI,EAAE;IAAE,KAAK,EAAE,UAAU,CAAC;IAAC,YAAY,EAAE,MAAM,CAAA;CAAE,GAChD,MAAM,CAkBR;AAED,wDAAwD;AACxD,wBAAgB,gBAAgB,CAC9B,CAAC,EAAE,aAAa,EAChB,IAAI,EAAE;IAAE,KAAK,EAAE,UAAU,CAAC;IAAC,YAAY,EAAE,MAAM,CAAA;CAAE,GAChD,MAAM,CAMR;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,CAAC,EAAE,aAAa,GAAG,MAAM,CAaxD;AAED,wBAAwB;AACxB,wBAAgB,eAAe,CAAC,CAAC,EAAE,aAAa,EAAE,IAAI,EAAE;IAAE,KAAK,EAAE,UAAU,CAAA;CAAE,GAAG,MAAM,CAYrF;AAED,0BAA0B;AAC1B,wBAAgB,iBAAiB,CAAC,CAAC,EAAE,aAAa,EAAE,IAAI,EAAE;IAAE,KAAK,EAAE,UAAU,CAAA;CAAE,GAAG,MAAM,CAiBvF;AAED;;;GAGG;AACH,qBAAa,QAAQ;IAOjB,OAAO,CAAC,QAAQ,CAAC,KAAK;IACtB,OAAO,CAAC,QAAQ,CAAC,IAAI;IAPvB,OAAO,CAAC,SAAS,CAAK;IACtB,OAAO,CAAC,YAAY,CAAK;IACzB,OAAO,CAAC,YAAY,CAAS;IAC7B,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAa;gBAGhB,KAAK,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI,EAC1B,IAAI,EAAE,UAAU;IAKnC,yEAAyE;IACzE,IAAI,CAAC,CAAC,EAAE,aAAa,GAAG,IAAI;IAc5B,0EAA0E;IAC1E,QAAQ,CAAC,CAAC,EAAE,aAAa,GAAG,IAAI;IAchC,gFAAgF;IAChF,aAAa,IAAI,IAAI;IAOrB,OAAO,CAAC,MAAM;CAKf"}
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Strip all control characters from an untrusted string so nothing it
3
+ * contains can be interpreted as a terminal control sequence. Printable
4
+ * text (incl. full Unicode) is preserved; an ESC that would introduce a
5
+ * CSI/OSC sequence is removed, so the rest renders as inert literal text.
6
+ */
7
+ export declare function sanitizeForTerminal(input: string): string;
8
+ /**
9
+ * Sanitise + bound a value to a single line of at most `max` glyphs, so a
10
+ * pathologically long bot string can't blow the layout. Adds an ellipsis
11
+ * when truncated.
12
+ */
13
+ export declare function sanitizeField(input: string | null | undefined, max?: number): string;
14
+ //# sourceMappingURL=sanitize.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sanitize.d.ts","sourceRoot":"","sources":["../../src/watch/sanitize.ts"],"names":[],"mappings":"AAkBA;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAOzD;AAED;;;;GAIG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EAAE,GAAG,SAAM,GAAG,MAAM,CAKjF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@m-kopa/launchpad-cli",
3
- "version": "0.32.2",
3
+ "version": "0.34.0",
4
4
  "description": "Launchpad CLI — clone / deploy / review / merge against Launchpad-managed apps. Talks to the portal-bot endpoints (SCOPE-M-760 / T4).",
5
5
  "type": "module",
6
6
  "bin": {
@@ -50,6 +50,7 @@
50
50
  "lint": "eslint src tests",
51
51
  "typecheck": "tsc --noEmit",
52
52
  "check:version-sync": "bash scripts/check-version-sync.sh",
53
+ "check:runtime-deps": "node scripts/check-runtime-deps.mjs",
53
54
  "check:installer-syntax": "bash scripts/check-installer-syntax.sh",
54
55
  "check:skill-contract": "bash scripts/sync-skill-contract.sh --check",
55
56
  "check:skill-bash-dialect": "bash scripts/check-skill-bash-dialect.sh",
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: launchpad-content-pr
3
3
  description: Push a content change to a Launchpad app via `launchpad deploy` and verify it shipped via `launchpad status`. Covers the post-first-deploy iteration loop (edit → deploy → verify) — subsequent deploys commit directly to the app repo's main and the Pages build runs asynchronously, so verification is its own step. Use when someone says "push a content change", "ship an update", "/launchpad-content-pr", "verify my deploy", or after `/launchpad-deploy` reports `done` and they want to follow up with an edit.
4
- version: 0.32.2
4
+ version: 0.34.0
5
5
  ---
6
6
 
7
7
  <!-- BEGIN shell-contract (managed by scripts/sync-skill-contract.sh — edit skills/_partials/shell-contract.md) -->
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: launchpad-deploy
3
3
  description: Walk a Launchpad user through deploying an app from their local working directory (Model A — `launchpad init` + `launchpad deploy`). Wraps the CLI verbs end-to-end: detects the app shape, scaffolds `launchpad.yaml`, resolves the allowed Entra group via `launchpad groups`, bundles the CWD via `launchpad deploy`, and watches the rollout via `launchpad status`. Use when someone says "deploy a new app", "ship my app to Launchpad", "/launchpad-deploy", "I have an app locally — get it on Launchpad", or any variant. Resume/abandon for legacy in-flight provisioning is at the bottom.
4
- version: 0.32.2
4
+ version: 0.34.0
5
5
  ---
6
6
 
7
7
  <!-- BEGIN shell-contract (managed by scripts/sync-skill-contract.sh — edit skills/_partials/shell-contract.md) -->
@@ -271,8 +271,10 @@ fresh slug auto-provisions:
271
271
  5–10 minutes. **Your bundle ships with the provisioning run** — when
272
272
  lifecycle reaches `live`, this deploy's content is what's serving.
273
273
  **No second deploy needed**; re-deploying is only for the rare case
274
- where the app comes up live *without* your content. Watch with
275
- `launchpad status <slug>`.
274
+ where the app comes up live *without* your content. **Watch it go
275
+ live in real time with `launchpad watch <slug>`** (a self-updating
276
+ view of the provisioning pipeline that exits when the app is live or
277
+ failed); `launchpad status <slug>` is the one-shot equivalent.
276
278
  - **Subsequent deploys** (slug already live): the bot extracts the
277
279
  tarball, runs the ingest gates (see below), commits the bundle
278
280
  straight onto `main` of `launchpad-app-<slug>` via the GitHub App
@@ -314,8 +316,9 @@ re-trying.
314
316
 
315
317
  The CLI exits as soon as the bot acknowledges the upload (202). For
316
318
  subsequent deploys it prints the commit short-SHA + repo; for first
317
- deploys it prints provisioning guidance. Use `launchpad status
318
- <slug>` to watch lifecycle progress to its terminal state.
319
+ deploys it prints provisioning guidance. Run `launchpad watch <slug>`
320
+ to watch lifecycle progress live to its terminal state (or
321
+ `launchpad status <slug>` for a one-shot check).
319
322
 
320
323
  Flags — there is nothing useful to pass on the Model A path:
321
324
 
@@ -386,6 +389,15 @@ pushes both with its broker token. Verify with `launchpad secrets status
386
389
  <slug>` (PRESENT on both surfaces). **Never `wrangler secret put`** — the
387
390
  operator has no `wrangler`.
388
391
 
392
+ **Activating a pushed secret on a Pages tier.** Pushing stores the value but does
393
+ **not** make it live on a Pages app — Pages binds env/secrets only on a NEW
394
+ deployment, and `launchpad deploy` idempotently no-ops on unchanged content. So a
395
+ pushed Pages secret is *set but inactive* until a redeploy. `launchpad secrets
396
+ push` says so and offers to activate: on a TTY it prompts `Redeploy … now? [y/N]`;
397
+ `--redeploy` (or `--yes`) activates without a prompt; otherwise it prints
398
+ `launchpad redeploy <slug>` to run when ready. The cron Worker tier needs no
399
+ redeploy (it binds on next invocation). See `/commands/redeploy`.
400
+
389
401
  ## Pages-tier D1 (`d1_binding` on a `pages` target)
390
402
 
391
403
  A pure `react+api` app (no cron Worker) that needs a database declares the