@hype-stack/cli 0.5.2 → 0.5.4

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.
@@ -1 +1 @@
1
- {"version":3,"file":"compose.d.ts","sourceRoot":"","sources":["../../src/commands/compose.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EACV,cAAc,EAEd,aAAa,EAEb,WAAW,EAEZ,MAAM,mBAAmB,CAAC;AAmB3B,wBAAsB,cAAc,CAAC,OAAO,GAAE,cAAmB,GAAG,OAAO,CAAC,IAAI,CAAC,CA8MhF;AAmFD;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,MAAM,GAAG,aAAa,CAIhE;AAED,6FAA6F;AAC7F,wBAAgB,WAAW,CAAC,SAAS,EAAE,aAAa,EAAE,GAAG,MAAM,EAAE,CAShE;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,aAAa,EAAE,GAAG,WAAW,CAYxE"}
1
+ {"version":3,"file":"compose.d.ts","sourceRoot":"","sources":["../../src/commands/compose.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EACV,cAAc,EAEd,aAAa,EAEb,WAAW,EAEZ,MAAM,mBAAmB,CAAC;AAmB3B,wBAAsB,cAAc,CAAC,OAAO,GAAE,cAAmB,GAAG,OAAO,CAAC,IAAI,CAAC,CAuNhF;AAmFD;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,MAAM,GAAG,aAAa,CAIhE;AAED,6FAA6F;AAC7F,wBAAgB,WAAW,CAAC,SAAS,EAAE,aAAa,EAAE,GAAG,MAAM,EAAE,CAShE;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,aAAa,EAAE,GAAG,WAAW,CAYxE"}
@@ -1 +1 @@
1
- {"version":3,"file":"template.d.ts","sourceRoot":"","sources":["../../src/commands/template.ts"],"names":[],"mappings":"AAmBA,OAAO,KAAK,EAIV,sBAAsB,EAGvB,MAAM,mBAAmB,CAAC;AAiB3B;;;;;;;;;GASG;AACH,wBAAsB,eAAe,CAAC,OAAO,GAAE,sBAA2B,GAAG,OAAO,CAAC,IAAI,CAAC,CAsUzF"}
1
+ {"version":3,"file":"template.d.ts","sourceRoot":"","sources":["../../src/commands/template.ts"],"names":[],"mappings":"AAmBA,OAAO,KAAK,EAIV,sBAAsB,EAGvB,MAAM,mBAAmB,CAAC;AAiB3B;;;;;;;;;GASG;AACH,wBAAsB,eAAe,CAAC,OAAO,GAAE,sBAA2B,GAAG,OAAO,CAAC,IAAI,CAAC,CA+UzF"}
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { t as e } from "../cli-cPE06mGY.js";
2
+ import { t as e } from "../cli-CwXodW3B.js";
3
3
  Object.freeze({ status: "aborted" });
4
4
  function t(e, t, n) {
5
5
  function r(n, r) {
@@ -15,6 +15,10 @@ export declare function promptPackCodegen(options: {
15
15
  projectRoot: string;
16
16
  paths: StackPaths;
17
17
  skipPrompts: boolean;
18
+ /** When false, the database is known to be down, so skip the prompt and print manual steps. */
19
+ dbReady?: boolean;
20
+ /** True when the project was just scaffolded, so the dev DB has no real data and is safe to reset. */
21
+ freshScaffold?: boolean;
18
22
  runCommand?: CodegenCommandRunner;
19
23
  }): Promise<void>;
20
24
  //# sourceMappingURL=codegen.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"codegen.d.ts","sourceRoot":"","sources":["../../src/core/codegen.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAEpD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAInD,MAAM,MAAM,oBAAoB,GAAG,CACjC,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,EAAE;IAAE,GAAG,EAAE,MAAM,CAAA;CAAE,KACrB,OAAO,CAAC,UAAU,CAAC,CAAC;AAczB;;;;;;;GAOG;AACH,wBAAsB,iBAAiB,CAAC,OAAO,EAAE;IAC/C,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,UAAU,CAAC;IAClB,WAAW,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,oBAAoB,CAAC;CACnC,GAAG,OAAO,CAAC,IAAI,CAAC,CAoChB"}
1
+ {"version":3,"file":"codegen.d.ts","sourceRoot":"","sources":["../../src/core/codegen.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAEpD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAInD,MAAM,MAAM,oBAAoB,GAAG,CACjC,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,EAAE;IAAE,GAAG,EAAE,MAAM,CAAA;CAAE,KACrB,OAAO,CAAC,UAAU,CAAC,CAAC;AAczB;;;;;;;GAOG;AACH,wBAAsB,iBAAiB,CAAC,OAAO,EAAE;IAC/C,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,UAAU,CAAC;IAClB,WAAW,EAAE,OAAO,CAAC;IACrB,+FAA+F;IAC/F,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,sGAAsG;IACtG,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,UAAU,CAAC,EAAE,oBAAoB,CAAC;CACnC,GAAG,OAAO,CAAC,IAAI,CAAC,CAwEhB"}
@@ -26,4 +26,14 @@ export declare function startDockerAndWait(targetDir: string, skipPrompts: boole
26
26
  */
27
27
  export declare function runDockerAndMigrations(targetDir: string, skipPrompts: boolean, options?: PostSetupOptions): Promise<void>;
28
28
  export declare function promptDockerAndMigrations(targetDir: string, skipPrompts: boolean, options?: PostSetupOptions): Promise<void>;
29
+ /**
30
+ * Boot Docker and wait for Postgres only. Used by the scaffold flow in
31
+ * `compose`/`template`, where the project ships with no migrations (the
32
+ * template's `prisma/migrations` only contains `migration_lock.toml`). There is
33
+ * nothing for `prisma migrate deploy` to apply, so the initial migration is
34
+ * created and applied by `prisma migrate dev` in the codegen step that follows.
35
+ * Returns true when Postgres is ready, false when the user declined, Docker
36
+ * failed to start, or Postgres never came up.
37
+ */
38
+ export declare function promptDockerAndWait(targetDir: string, skipPrompts: boolean, options?: PostSetupOptions): Promise<boolean>;
29
39
  //# sourceMappingURL=post-setup.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"post-setup.d.ts","sourceRoot":"","sources":["../../src/core/post-setup.ts"],"names":[],"mappings":"AAOA,wBAAsB,eAAe,IAAI,OAAO,CAAC,OAAO,CAAC,CAGxD;AAMD,wBAAsB,mBAAmB,CACvC,SAAS,EAAE,MAAM,EACjB,WAAW,EAAE,OAAO,EACpB,aAAa,EAAE,OAAO,GACrB,OAAO,CAAC,OAAO,CAAC,CA6BlB;AAOD,wBAAsB,eAAe,CAAC,SAAS,EAAE,MAAM,EAAE,WAAW,SAAK,EAAE,UAAU,SAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAc9G;AAED,MAAM,WAAW,gBAAgB;IAC/B,uBAAuB,CAAC,EAAE,MAAM,CAAC;IACjC,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAKD;;;;GAIG;AACH,wBAAsB,oBAAoB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAM9E;AAED,6FAA6F;AAC7F,wBAAsB,aAAa,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAiBvE;AAED;;;;GAIG;AACH,wBAAsB,kBAAkB,CACtC,SAAS,EAAE,MAAM,EACjB,WAAW,EAAE,OAAO,EACpB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,OAAO,CAAC,CAyBlB;AAED;;;;GAIG;AACH,wBAAsB,sBAAsB,CAC1C,SAAS,EAAE,MAAM,EACjB,WAAW,EAAE,OAAO,EACpB,OAAO,GAAE,gBAAqB,GAC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AO,EACpB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,IAAI,CAAC,CAWf;AAED;;;;;;;;GAQG;AACH,wBAAsB,mBAAmB,CACvC,SAAS,EAAE,MAAM,EACjB,WAAW,EAAE,OAAO,EACpB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,OAAO,CAAC,CAWlB"}
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "./cli-cPE06mGY.js";
1
+ import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "./cli-CwXodW3B.js";
2
2
  export { t as composeCommand, a as createCommand, o as createProgram, e as ensureInit, r as initCommand, i as loginCommand, n as logoutCommand };
@@ -7,4 +7,14 @@ export declare function exec(command: string, args: string[], options: {
7
7
  cwd: string;
8
8
  onData?: (line: string) => void;
9
9
  }): Promise<ExecResult>;
10
+ /**
11
+ * Run a command with stdio inherited from the parent terminal. Use this for
12
+ * commands that need a real TTY on stdin, such as `prisma migrate dev`, which
13
+ * aborts with "environment is non-interactive" the moment it finishes loading
14
+ * the schema when stdin is piped/ignored. Output is not captured, it streams
15
+ * straight to the user, so stdout/stderr in the result are empty.
16
+ */
17
+ export declare function execInherit(command: string, args: string[], options: {
18
+ cwd: string;
19
+ }): Promise<ExecResult>;
10
20
  //# sourceMappingURL=exec.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"exec.d.ts","sourceRoot":"","sources":["../../src/utils/exec.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,UAAU;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,wBAAgB,IAAI,CAClB,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,EAAE;IACP,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CACjC,GACA,OAAO,CAAC,UAAU,CAAC,CAsCrB"}
1
+ {"version":3,"file":"exec.d.ts","sourceRoot":"","sources":["../../src/utils/exec.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,UAAU;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,wBAAgB,IAAI,CAClB,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,EAAE;IACP,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CACjC,GACA,OAAO,CAAC,UAAU,CAAC,CAsCrB;AAED;;;;;;GAMG;AACH,wBAAgB,WAAW,CACzB,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,EAAE;IAAE,GAAG,EAAE,MAAM,CAAA;CAAE,GACvB,OAAO,CAAC,UAAU,CAAC,CAarB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hype-stack/cli",
3
- "version": "0.5.2",
3
+ "version": "0.5.4",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",