@prisma/orm-toolchain 0.16.0 → 0.17.0-dev.10

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 (94) hide show
  1. package/dist/bin__prisma-next.mjs +21 -21
  2. package/dist/bin__prisma-next.mjs.map +1 -1
  3. package/dist/cli.mjs +2 -2
  4. package/dist/cli__commands__contract-emit.mjs +1 -1
  5. package/dist/cli__commands__contract-infer.mjs +1 -1
  6. package/dist/cli__commands__db-init.mjs +1 -1
  7. package/dist/cli__commands__db-schema.mjs +1 -1
  8. package/dist/cli__commands__db-sign.mjs +1 -1
  9. package/dist/cli__commands__db-update.mjs +1 -1
  10. package/dist/cli__commands__db-verify.mjs +1 -1
  11. package/dist/cli__commands__migrate.mjs +1 -1
  12. package/dist/cli__commands__migration-check.d.mts +1 -1
  13. package/dist/cli__commands__migration-check.mjs +1 -1
  14. package/dist/cli__commands__migration-graph.d.mts +1 -1
  15. package/dist/cli__commands__migration-graph.mjs +1 -1
  16. package/dist/cli__commands__migration-list.d.mts +1 -1
  17. package/dist/cli__commands__migration-list.mjs +1 -1
  18. package/dist/cli__commands__migration-log.d.mts +1 -1
  19. package/dist/cli__commands__migration-log.mjs +1 -1
  20. package/dist/cli__commands__migration-new.mjs +1 -1
  21. package/dist/cli__commands__migration-plan.mjs +1 -1
  22. package/dist/cli__commands__migration-show.d.mts +1 -1
  23. package/dist/cli__commands__migration-show.mjs +1 -1
  24. package/dist/cli__commands__migration-status.d.mts +1 -1
  25. package/dist/cli__commands__migration-status.mjs +1 -1
  26. package/dist/cli__commands__ref.mjs +1 -1
  27. package/dist/cli__control-api.mjs +2 -2
  28. package/dist/cli__migration-cli.mjs +1 -1
  29. package/dist/{client-75qrAPqf-DZAVUxFa.mjs → client-75qrAPqf-7l0C0H_b.mjs} +2 -2
  30. package/dist/{client-75qrAPqf-DZAVUxFa.mjs.map → client-75qrAPqf-7l0C0H_b.mjs.map} +1 -1
  31. package/dist/config-loader.mjs +1 -1
  32. package/dist/{contract-emit-0hSjbuxp-BBOKldTZ.mjs → contract-emit-0hSjbuxp-BJLC-VgC.mjs} +4 -4
  33. package/dist/{contract-emit-0hSjbuxp-BBOKldTZ.mjs.map → contract-emit-0hSjbuxp-BJLC-VgC.mjs.map} +1 -1
  34. package/dist/{contract-emit-B6odMoem-CK3diBPk.mjs → contract-emit-B6odMoem-C87PBvmo.mjs} +3 -3
  35. package/dist/{contract-emit-B6odMoem-CK3diBPk.mjs.map → contract-emit-B6odMoem-C87PBvmo.mjs.map} +1 -1
  36. package/dist/{contract-infer-BnkqpftN-DVM2eKJ3.mjs → contract-infer-BnkqpftN-DwBzasOu.mjs} +2 -2
  37. package/dist/{contract-infer-BnkqpftN-DVM2eKJ3.mjs.map → contract-infer-BnkqpftN-DwBzasOu.mjs.map} +1 -1
  38. package/dist/{db-init-Vbkb_TKZ.mjs → db-init-bd0_x2Q8.mjs} +2 -2
  39. package/dist/{db-init-Vbkb_TKZ.mjs.map → db-init-bd0_x2Q8.mjs.map} +1 -1
  40. package/dist/{db-schema-ClQCu3xY.mjs → db-schema-CwgAWTqG.mjs} +2 -2
  41. package/dist/{db-schema-ClQCu3xY.mjs.map → db-schema-CwgAWTqG.mjs.map} +1 -1
  42. package/dist/{db-sign-jjXDgQ1u.mjs → db-sign-vqiYfpjI.mjs} +3 -3
  43. package/dist/{db-sign-jjXDgQ1u.mjs.map → db-sign-vqiYfpjI.mjs.map} +1 -1
  44. package/dist/{db-update-BQlrqtDD.mjs → db-update-Br0diOCo.mjs} +2 -2
  45. package/dist/{db-update-BQlrqtDD.mjs.map → db-update-Br0diOCo.mjs.map} +1 -1
  46. package/dist/{db-verify-CKPsRFrj-3udprZQD.mjs → db-verify-CKPsRFrj-T7nSt7yT.mjs} +3 -3
  47. package/dist/{db-verify-CKPsRFrj-3udprZQD.mjs.map → db-verify-CKPsRFrj-T7nSt7yT.mjs.map} +1 -1
  48. package/dist/{domain-type-generation-DAn9y5d2-BgoT5uKI.mjs → domain-type-generation-bpSO3Y0L-Cdauqrnc.mjs} +16 -16
  49. package/dist/domain-type-generation-bpSO3Y0L-Cdauqrnc.mjs.map +1 -0
  50. package/dist/emitter.d.mts +5 -2
  51. package/dist/emitter.d.mts.map +1 -1
  52. package/dist/emitter.mjs +2 -2
  53. package/dist/emitter__domain-type-generation.mjs +1 -1
  54. package/dist/{exports-D3-NwrMA-CadaBGQ3.mjs → exports-BCLg4CiV-okAfZydo.mjs} +12 -6
  55. package/dist/exports-BCLg4CiV-okAfZydo.mjs.map +1 -0
  56. package/dist/{exports-B_xhKZmC.mjs → exports-BnihzVhw.mjs} +2 -2
  57. package/dist/{exports-B_xhKZmC.mjs.map → exports-BnihzVhw.mjs.map} +1 -1
  58. package/dist/{exports-Dl2aGAk7.mjs → exports-CDX9kZuw.mjs} +2 -2
  59. package/dist/{exports-Dl2aGAk7.mjs.map → exports-CDX9kZuw.mjs.map} +1 -1
  60. package/dist/{format-ByDm2goZ-DKLyhNHo.mjs → format-ByDm2goZ-BIRlFoo6.mjs} +2 -2
  61. package/dist/{format-ByDm2goZ-DKLyhNHo.mjs.map → format-ByDm2goZ-BIRlFoo6.mjs.map} +1 -1
  62. package/dist/{init-DHctXAI9-DSlaaYXN.mjs → init-BGm77aWc-jHVUn63W.mjs} +69 -18
  63. package/dist/init-BGm77aWc-jHVUn63W.mjs.map +1 -0
  64. package/dist/{inspect-live-schema-CnwYTRZ0-BErPHMni.mjs → inspect-live-schema-CnwYTRZ0-P-6asJFl.mjs} +3 -3
  65. package/dist/{inspect-live-schema-CnwYTRZ0-BErPHMni.mjs.map → inspect-live-schema-CnwYTRZ0-P-6asJFl.mjs.map} +1 -1
  66. package/dist/{migrate-Cb_iv264.mjs → migrate-BdVFDKF2.mjs} +4 -4
  67. package/dist/{migrate-Cb_iv264.mjs.map → migrate-BdVFDKF2.mjs.map} +1 -1
  68. package/dist/{migration-check-DcwUnadt-B6Qoh0ot.mjs → migration-check-DcwUnadt-jamDqOmM.mjs} +2 -2
  69. package/dist/{migration-check-DcwUnadt-B6Qoh0ot.mjs.map → migration-check-DcwUnadt-jamDqOmM.mjs.map} +1 -1
  70. package/dist/{migration-command-scaffold-BCuoeAki-B1pVGX8d.mjs → migration-command-scaffold-BCuoeAki-DMy_5ztW.mjs} +3 -3
  71. package/dist/{migration-command-scaffold-BCuoeAki-B1pVGX8d.mjs.map → migration-command-scaffold-BCuoeAki-DMy_5ztW.mjs.map} +1 -1
  72. package/dist/{migration-graph-DkoCC0Qy.mjs → migration-graph-vmgkL3k4.mjs} +3 -3
  73. package/dist/{migration-graph-DkoCC0Qy.mjs.map → migration-graph-vmgkL3k4.mjs.map} +1 -1
  74. package/dist/{migration-list-BFBeo1_X-c0kqYokL.mjs → migration-list-BFBeo1_X-ckYMhETH.mjs} +2 -2
  75. package/dist/{migration-list-BFBeo1_X-c0kqYokL.mjs.map → migration-list-BFBeo1_X-ckYMhETH.mjs.map} +1 -1
  76. package/dist/{migration-log-CS5IWcNq-BQ-32Low.mjs → migration-log-CS5IWcNq-DI7FTHCA.mjs} +3 -3
  77. package/dist/{migration-log-CS5IWcNq-BQ-32Low.mjs.map → migration-log-CS5IWcNq-DI7FTHCA.mjs.map} +1 -1
  78. package/dist/{migration-new-BurCjyaQ.mjs → migration-new-GmW2anVb.mjs} +3 -3
  79. package/dist/{migration-new-BurCjyaQ.mjs.map → migration-new-GmW2anVb.mjs.map} +1 -1
  80. package/dist/{migration-plan-q_L84PN1-BWE0LTH6.mjs → migration-plan-q_L84PN1-ClkGgtVz.mjs} +3 -3
  81. package/dist/{migration-plan-q_L84PN1-BWE0LTH6.mjs.map → migration-plan-q_L84PN1-ClkGgtVz.mjs.map} +1 -1
  82. package/dist/{migration-show-Bx5I5aW9.mjs → migration-show--pW4XhKs.mjs} +3 -3
  83. package/dist/{migration-show-Bx5I5aW9.mjs.map → migration-show--pW4XhKs.mjs.map} +1 -1
  84. package/dist/{migration-status-CE7cQLDq-B1jDVmqG.mjs → migration-status-CE7cQLDq-P1x1-BsZ.mjs} +4 -4
  85. package/dist/{migration-status-CE7cQLDq-B1jDVmqG.mjs.map → migration-status-CE7cQLDq-P1x1-BsZ.mjs.map} +1 -1
  86. package/dist/{ref-B6cTthTi.mjs → ref-sHE8zOcm.mjs} +2 -2
  87. package/dist/{ref-B6cTthTi.mjs.map → ref-sHE8zOcm.mjs.map} +1 -1
  88. package/dist/{schemas-CfGSxH5b-BSjB3nZS.d.mts → schemas-CeGMYFYX-h3OcU__O.d.mts} +5 -5
  89. package/dist/{schemas-CfGSxH5b-BSjB3nZS.d.mts.map → schemas-CeGMYFYX-h3OcU__O.d.mts.map} +1 -1
  90. package/dist/vite-plugin-contract-emit.mjs +3 -3
  91. package/package.json +17 -12
  92. package/dist/domain-type-generation-DAn9y5d2-BgoT5uKI.mjs.map +0 -1
  93. package/dist/exports-D3-NwrMA-CadaBGQ3.mjs.map +0 -1
  94. package/dist/init-DHctXAI9-DSlaaYXN.mjs.map +0 -1
@@ -1,24 +1,24 @@
1
1
  #!/usr/bin/env node
2
2
  import { J as installShutdownHandlers, P as formatCommandHelp, U as formatRootHelp, Y as isCI$1, ct as setCommandExamples, et as parseGlobalFlags, r as addGlobalOptions, s as deriveCanPrompt, st as setCommandDescriptions, tt as parseGlobalFlagsOrExit } from "./command-helpers-CAoXqAY9-DWUBcTXM.mjs";
3
3
  import { i as createScaffoldSpecifierResolver } from "./import-roots-NDOIEDVj.mjs";
4
- import { t as createContractEmitCommand } from "./contract-emit-0hSjbuxp-BBOKldTZ.mjs";
5
- import { t as createFormatCommand } from "./format-ByDm2goZ-DKLyhNHo.mjs";
6
- import { t as createDbInitCommand } from "./db-init-Vbkb_TKZ.mjs";
7
- import { t as createDbUpdateCommand } from "./db-update-BQlrqtDD.mjs";
8
- import { t as createDbSchemaCommand } from "./db-schema-ClQCu3xY.mjs";
9
- import { t as createDbSignCommand } from "./db-sign-jjXDgQ1u.mjs";
10
- import { t as createDbVerifyCommand } from "./db-verify-CKPsRFrj-3udprZQD.mjs";
11
- import { t as createContractInferCommand } from "./contract-infer-BnkqpftN-DVM2eKJ3.mjs";
12
- import { t as createMigrationNewCommand } from "./migration-new-BurCjyaQ.mjs";
13
- import { t as createMigrationPlanCommand } from "./migration-plan-q_L84PN1-BWE0LTH6.mjs";
14
- import { t as createMigrationShowCommand } from "./migration-show-Bx5I5aW9.mjs";
15
- import { t as createMigrationListCommand } from "./migration-list-BFBeo1_X-c0kqYokL.mjs";
16
- import { r as createMigrationStatusCommand } from "./migration-status-CE7cQLDq-B1jDVmqG.mjs";
17
- import { t as createMigrationLogCommand } from "./migration-log-CS5IWcNq-BQ-32Low.mjs";
18
- import { t as createMigrationGraphCommand } from "./migration-graph-DkoCC0Qy.mjs";
19
- import { t as createMigrationCheckCommand } from "./migration-check-DcwUnadt-B6Qoh0ot.mjs";
20
- import { t as createMigrateCommand } from "./migrate-Cb_iv264.mjs";
21
- import { t as createRefCommand } from "./ref-B6cTthTi.mjs";
4
+ import { t as createContractEmitCommand } from "./contract-emit-0hSjbuxp-BJLC-VgC.mjs";
5
+ import { t as createFormatCommand } from "./format-ByDm2goZ-BIRlFoo6.mjs";
6
+ import { t as createDbInitCommand } from "./db-init-bd0_x2Q8.mjs";
7
+ import { t as createDbUpdateCommand } from "./db-update-Br0diOCo.mjs";
8
+ import { t as createDbSchemaCommand } from "./db-schema-CwgAWTqG.mjs";
9
+ import { t as createDbSignCommand } from "./db-sign-vqiYfpjI.mjs";
10
+ import { t as createDbVerifyCommand } from "./db-verify-CKPsRFrj-T7nSt7yT.mjs";
11
+ import { t as createContractInferCommand } from "./contract-infer-BnkqpftN-DwBzasOu.mjs";
12
+ import { t as createMigrationNewCommand } from "./migration-new-GmW2anVb.mjs";
13
+ import { t as createMigrationPlanCommand } from "./migration-plan-q_L84PN1-ClkGgtVz.mjs";
14
+ import { t as createMigrationShowCommand } from "./migration-show--pW4XhKs.mjs";
15
+ import { t as createMigrationListCommand } from "./migration-list-BFBeo1_X-ckYMhETH.mjs";
16
+ import { r as createMigrationStatusCommand } from "./migration-status-CE7cQLDq-P1x1-BsZ.mjs";
17
+ import { t as createMigrationLogCommand } from "./migration-log-CS5IWcNq-DI7FTHCA.mjs";
18
+ import { t as createMigrationGraphCommand } from "./migration-graph-vmgkL3k4.mjs";
19
+ import { t as createMigrationCheckCommand } from "./migration-check-DcwUnadt-jamDqOmM.mjs";
20
+ import { t as createMigrateCommand } from "./migrate-BdVFDKF2.mjs";
21
+ import { t as createRefCommand } from "./ref-sHE8zOcm.mjs";
22
22
  import { a as resolveGating, i as readUserConfig, r as ensureInstallationId, s as runTelemetry, u as userConfigPath } from "./exports-BN0vFTxG.mjs";
23
23
  import { t as createTelemetryCommand } from "./telemetry-CmbCa3Ld-CmE5zcIG.mjs";
24
24
  import { DEFAULT_CONTRACT_SOURCE_DIR } from "@prisma/orm-framework/config/config-types";
@@ -27,7 +27,7 @@ import { Command } from "commander";
27
27
  import { fileURLToPath } from "node:url";
28
28
  import { distance } from "closest-match";
29
29
  //#region ../../../1-framework/3-tooling/cli/dist/cli.mjs
30
- var version = "0.16.0";
30
+ var version = "0.17.0-dev.10";
31
31
  /**
32
32
  * The resolver a scaffold for `target` is written against.
33
33
  *
@@ -333,7 +333,7 @@ Exit codes (see CLI Style Guide § Exit Codes):
333
333
  "prisma-next init --no-skill # skip the skills install (air-gapped / restricted env)"
334
334
  ]);
335
335
  return addGlobalOptions(command).option("--target <db>", "Database target: postgres or mongodb").option("--authoring <style>", "Schema authoring style: psl or typescript").option("--schema-path <path>", `Where to write the starter schema (default: ${defaultSchemaPath("psl")})`).option("--force", "Overwrite an existing scaffold without prompting").option("--write-env", "Write a .env file from .env.example (gitignored; default: only .env.example)").option("--probe-db", "Connect to DATABASE_URL once and check the server version against the target minimum (opt-in; off by default)").option("--strict-probe", "Treat a failed --probe-db as fatal (no-op without --probe-db; init is offline-by-default)").option("--no-install", "Skip dependency installation and contract emission").option("--no-skill", "Skip Prisma Next skills install (air-gapped CI, restricted registries, etc.)").action(async (options) => {
336
- const { runInit } = await import("./init-DHctXAI9-DSlaaYXN.mjs");
336
+ const { runInit } = await import("./init-BGm77aWc-jHVUn63W.mjs");
337
337
  const flags = parseGlobalFlagsOrExit(options);
338
338
  const canPrompt = deriveCanPrompt({
339
339
  flagsInteractive: flags.interactive,
@@ -353,7 +353,7 @@ function createLspCommand() {
353
353
  setCommandDescriptions(command, "Start the Prisma Next language server", "Launches a Language Server Protocol server that publishes PSL parse diagnostics\nand handles whole-document PSL formatting for the schema inputs declared in\nyour config (contract.source.inputs). Formatting uses the Prisma Next PSL\nformatter and the formatter block from the project config.\nCommunicates over stdio; intended to be spawned by an\neditor, not run interactively. The server keeps running until the editor client\ndisconnects.");
354
354
  setCommandExamples(command, ["prisma-next lsp --stdio"]);
355
355
  addGlobalOptions(command).option("--stdio", "Communicate with the editor over stdio (the default and only transport)").action(async () => {
356
- const { startServer } = await import("./exports-B_xhKZmC.mjs");
356
+ const { startServer } = await import("./exports-BnihzVhw.mjs");
357
357
  startServer();
358
358
  });
359
359
  return command;
@@ -1 +1 @@
1
- {"version":3,"file":"bin__prisma-next.mjs","names":["isCI"],"sources":["../../../../1-framework/3-tooling/cli/dist/cli.mjs"],"sourcesContent":["#!/usr/bin/env node\nimport { D as isCI, O as formatCommandHelp, g as parseGlobalFlagsOrExit, h as parseGlobalFlags, k as formatRootHelp, l as setCommandDescriptions, m as deriveCanPrompt, t as addGlobalOptions, u as setCommandExamples, v as installShutdownHandlers } from \"./command-helpers-CAoXqAY9.mjs\";\nimport { t as createContractEmitCommand } from \"./contract-emit-0hSjbuxp.mjs\";\nimport { t as createContractInferCommand } from \"./contract-infer-BnkqpftN.mjs\";\nimport { createDbInitCommand } from \"./commands/db-init.mjs\";\nimport { createDbSchemaCommand } from \"./commands/db-schema.mjs\";\nimport { createDbSignCommand } from \"./commands/db-sign.mjs\";\nimport { createDbUpdateCommand } from \"./commands/db-update.mjs\";\nimport { t as createDbVerifyCommand } from \"./db-verify-CKPsRFrj.mjs\";\nimport { t as createFormatCommand } from \"./format-ByDm2goZ.mjs\";\nimport { t as createMigrationListCommand } from \"./migration-list-BFBeo1_X.mjs\";\nimport { createMigrateCommand } from \"./commands/migrate.mjs\";\nimport { t as createMigrationCheckCommand } from \"./migration-check-DcwUnadt.mjs\";\nimport { createMigrationGraphCommand } from \"./commands/migration-graph.mjs\";\nimport { t as createMigrationLogCommand } from \"./migration-log-CS5IWcNq.mjs\";\nimport { createMigrationNewCommand } from \"./commands/migration-new.mjs\";\nimport { t as createMigrationPlanCommand } from \"./migration-plan-q_L84PN1.mjs\";\nimport { createMigrationShowCommand } from \"./commands/migration-show.mjs\";\nimport { r as createMigrationStatusCommand } from \"./migration-status-CE7cQLDq.mjs\";\nimport { createRefCommand } from \"./commands/ref.mjs\";\nimport { t as createTelemetryCommand } from \"./telemetry-CmbCa3Ld.mjs\";\nimport { Command } from \"commander\";\nimport { createScaffoldSpecifierResolver } from \"@internal/publish-surface/import-roots\";\nimport { DEFAULT_CONTRACT_SOURCE_DIR } from \"@internal/config/config-types\";\nimport { keepInternalSpecifiers } from \"@internal/framework-components/emission\";\nimport { ensureInstallationId, readUserConfig, resolveGating, runTelemetry, userConfigPath } from \"@internal/cli-telemetry\";\nimport { distance } from \"closest-match\";\nimport { fileURLToPath } from \"node:url\";\n//#region package.json\nvar version = \"0.16.0\";\n//#endregion\n//#region src/commands/init/templates/code-templates.ts\n/**\n* The resolver a scaffold for `target` is written against.\n*\n* A scaffold is always on the facade root: `init` writes an application around\n* one database package, and the workspace names are not published, so a project\n* scaffolded against them could not install (ADR 242). Both the files `init`\n* writes and the dependency it adds go through this, so they cannot disagree.\n*/\nfunction scaffoldSpecifierResolverFor(target) {\n\treturn createScaffoldSpecifierResolver({\n\t\tmode: \"facade\",\n\t\tfacade: target === \"postgres\" ? \"@prisma/orm-postgres\" : \"@prisma/orm-mongo\"\n\t});\n}\n/**\n* The package name a scaffolded project depends on and imports from, for the\n* import root it is being scaffolded against.\n*\n* Every specifier the scaffold writes derives from this one, and `init` builds\n* a single resolver and hands it to both the file templates and the dependency\n* it installs — so the two cannot disagree. The one caller that deliberately\n* does not thread a resolver is the re-init cleanup in `inputs.ts`, which\n* inspects a manifest an earlier run wrote rather than writing one.\n*\n* Resolvers for scaffolding should come from `createScaffoldSpecifierResolver`\n* in the publish-surface package, which rejects the roots a facade-shaped\n* scaffold cannot express. (Named without its scope on purpose: JSDoc survives\n* into the published bundle, where an internal package name would trip the\n* shell tarball checks.)\n*/\nfunction targetPackageName(target, resolveImportSpecifier = keepInternalSpecifiers) {\n\treturn resolveImportSpecifier(target === \"postgres\" ? \"@internal/postgres\" : \"@internal/mongo\");\n}\n/** One entrypoint of the scaffolded project's target package. */\nfunction targetEntrypoint(target, subpath, resolveImportSpecifier = keepInternalSpecifiers) {\n\treturn resolveImportSpecifier(`${target === \"postgres\" ? \"@internal/postgres\" : \"@internal/mongo\"}/${subpath}`);\n}\nfunction targetLabel(target) {\n\treturn target === \"postgres\" ? \"PostgreSQL\" : \"MongoDB\";\n}\nfunction defaultSchemaPath(authoring) {\n\tif (authoring === \"typescript\") return `${DEFAULT_CONTRACT_SOURCE_DIR}/contract.ts`;\n\treturn `${DEFAULT_CONTRACT_SOURCE_DIR}/contract.prisma`;\n}\nfunction starterSchema(target, authoring, resolveImportSpecifier = keepInternalSpecifiers) {\n\tif (authoring === \"typescript\") {\n\t\tconst builder = targetEntrypoint(target, \"contract-builder\", resolveImportSpecifier);\n\t\treturn target === \"mongo\" ? starterSchemaTsMongo(builder) : starterSchemaTsPostgres(builder);\n\t}\n\treturn target === \"mongo\" ? starterSchemaPslMongo() : starterSchemaPslPostgres();\n}\n/**\n* Renders a short authoring-appropriate schema sample (FR5.1) for embedding\n* in `prisma-next.md`. Returns a complete fenced markdown code block.\n*\n* The sample intentionally shows just one model: it's illustrative, not\n* a substitute for the full scaffolded contract file. The TS samples use\n* the same outer shape as `starterSchemaTs*` (FR5.3) so a user reading\n* the doc and the file side-by-side sees the same structure.\n*/\nfunction schemaSample(target, authoring, resolveImportSpecifier = keepInternalSpecifiers) {\n\tif (authoring === \"typescript\") {\n\t\tconst builder = targetEntrypoint(target, \"contract-builder\", resolveImportSpecifier);\n\t\treturn target === \"mongo\" ? schemaSampleTsMongo(builder) : schemaSampleTsPostgres(builder);\n\t}\n\treturn target === \"mongo\" ? schemaSamplePslMongo() : schemaSamplePslPostgres();\n}\nfunction schemaSamplePslPostgres() {\n\treturn `\\`\\`\\`prisma\nmodel User {\n id Int @id @default(autoincrement())\n email String @unique\n username String?\n name String?\n}\n\\`\\`\\``;\n}\nfunction schemaSamplePslMongo() {\n\treturn `\\`\\`\\`prisma\nmodel User {\n id ObjectId @id @map(\"_id\")\n email String @unique\n username String?\n name String?\n @@map(\"users\")\n}\n\\`\\`\\``;\n}\nfunction schemaSampleTsPostgres(builder) {\n\treturn `\\`\\`\\`typescript\nimport { defineContract } from '${builder}';\n\nexport const contract = defineContract(\n {},\n ({ field, model }) => ({\n models: {\n User: model('User', {\n fields: {\n id: field.id.uuidv7String(),\n email: field.text().unique(),\n username: field.text().optional(),\n name: field.text().optional(),\n },\n }),\n },\n }),\n);\n\\`\\`\\``;\n}\nfunction schemaSampleTsMongo(builder) {\n\treturn `\\`\\`\\`typescript\nimport { defineContract } from '${builder}';\n\nexport const contract = defineContract(\n {},\n ({ field, model }) => ({\n models: {\n User: model('User', {\n collection: 'users',\n fields: {\n _id: field.objectId(),\n email: field.string(),\n username: field.string().optional(),\n name: field.string().optional(),\n },\n }),\n },\n }),\n);\n\\`\\`\\``;\n}\nfunction starterSchemaPslPostgres() {\n\treturn `// use prisma-next\n\nmodel User {\n id Int @id @default(autoincrement())\n email String @unique\n username String?\n name String?\n posts Post[]\n createdAt DateTime @default(now())\n updatedAt temporal.updatedAt()\n}\n\nmodel Post {\n id Int @id @default(autoincrement())\n title String\n content String?\n author User @relation(fields: [authorId], references: [id])\n authorId Int\n createdAt DateTime @default(now())\n updatedAt temporal.updatedAt()\n}\n`;\n}\nfunction starterSchemaPslMongo() {\n\treturn `// use prisma-next\n\nmodel User {\n id ObjectId @id @map(\"_id\")\n email String @unique\n username String?\n name String?\n posts Post[]\n @@map(\"users\")\n}\n\nmodel Post {\n id ObjectId @id @map(\"_id\")\n title String\n content String?\n author User @relation(fields: [authorId], references: [id])\n authorId ObjectId\n @@map(\"posts\")\n}\n`;\n}\nfunction starterSchemaTsPostgres(builder) {\n\treturn `import { defineContract } from '${builder}';\n\nexport const contract = defineContract(\n {},\n ({ field, model, rel }) => ({\n models: {\n User: model('User', {\n fields: {\n id: field.id.uuidv7String(),\n email: field.text().unique(),\n username: field.text().optional(),\n name: field.text().optional(),\n createdAt: field.temporal.createdAt(),\n updatedAt: field.temporal.updatedAt(),\n },\n relations: {\n posts: rel.hasMany('Post', { by: 'authorId' }),\n },\n }),\n\n Post: model('Post', {\n fields: {\n id: field.id.uuidv7String(),\n title: field.text(),\n content: field.text().optional(),\n authorId: field.uuidString(),\n createdAt: field.temporal.createdAt(),\n updatedAt: field.temporal.updatedAt(),\n },\n relations: {\n author: rel.belongsTo('User', { from: 'authorId', to: 'id' }),\n },\n }),\n },\n }),\n);\n`;\n}\nfunction starterSchemaTsMongo(builder) {\n\treturn `import { defineContract } from '${builder}';\n\nexport const contract = defineContract(\n {},\n ({ field, model, rel }) => ({\n models: {\n User: model('User', {\n collection: 'users',\n fields: {\n _id: field.objectId(),\n email: field.string(),\n username: field.string().optional(),\n name: field.string().optional(),\n },\n relations: {\n posts: rel.hasMany('Post', { from: '_id', to: 'authorId' }),\n },\n }),\n\n Post: model('Post', {\n collection: 'posts',\n fields: {\n _id: field.objectId(),\n title: field.string(),\n content: field.string().optional(),\n authorId: field.objectId(),\n },\n relations: {\n author: rel.belongsTo('User', { from: 'authorId', to: '_id' }),\n },\n }),\n },\n }),\n);\n`;\n}\nfunction configFile(target, contractPath, resolveImportSpecifier = keepInternalSpecifiers) {\n\treturn `import 'dotenv/config';\nimport { defineConfig } from '${targetEntrypoint(target, \"config\", resolveImportSpecifier)}';\n\nexport default defineConfig({\n contract: ${JSON.stringify(contractPath)},\n db: {\n connection: process.env['DATABASE_URL']!,\n },\n});\n`;\n}\nfunction dbFile(target, resolveImportSpecifier = keepInternalSpecifiers) {\n\tconst runtime = targetEntrypoint(target, \"runtime\", resolveImportSpecifier);\n\tif (target === \"postgres\") return `import postgres from '${runtime}';\nimport type { Contract } from './contract.d';\nimport contractJson from './contract.json' with { type: 'json' };\n\nexport const db = postgres<Contract>({\n contractJson,\n url: process.env['DATABASE_URL']!,\n});\n`;\n\treturn `import mongo from '${runtime}';\nimport type { Contract } from './contract.d';\nimport contractJson from './contract.json' with { type: 'json' };\n\nexport const db = mongo<Contract>({\n contractJson,\n url: process.env['DATABASE_URL']!,\n});\n`;\n}\n//#endregion\n//#region src/commands/init/index.ts\nfunction createInitCommand() {\n\tconst command = new Command(\"init\");\n\tsetCommandDescriptions(command, \"Initialize a new Prisma Next project\", `Scaffolds config, schema, and runtime files, installs dependencies,\nand emits the contract. Gets you from zero to typed queries in one step.\n\nRun interactively for a guided experience, or supply --target / --authoring\nand --yes for a fully scriptable run (CI, AI coding agents, automation).\n\nExit codes (see CLI Style Guide § Exit Codes):\n 0 OK Init succeeded.\\n 1 INTERNAL_ERROR Unexpected bug in prisma-next (please report).\\n 2 PRECONDITION Bad flags / missing prerequisite (e.g. no package.json).\\n 3 USER_ABORTED User cancelled an interactive prompt.\\n 4 INSTALL_FAILED Dependency installation failed (init-specific).\\n 5 EMIT_FAILED \\`contract emit\\` failed after install (init-specific).\\n 6 SKILL_INSTALL_FAILED Agent-skill install failed (re-run with --no-skill to skip).`);\n\tsetCommandExamples(command, [\n\t\t\"prisma-next init\",\n\t\t\"prisma-next init --yes --target postgres --authoring psl\",\n\t\t\"prisma-next init --yes --target mongodb --authoring typescript --json\",\n\t\t\"prisma-next init --yes --force --target postgres --authoring psl # overwrite an existing scaffold\",\n\t\t\"prisma-next init --no-install # skip pnpm/npm install + emit\",\n\t\t\"prisma-next init --no-skill # skip the skills install (air-gapped / restricted env)\"\n\t]);\n\treturn addGlobalOptions(command).option(\"--target <db>\", \"Database target: postgres or mongodb\").option(\"--authoring <style>\", \"Schema authoring style: psl or typescript\").option(\"--schema-path <path>\", `Where to write the starter schema (default: ${defaultSchemaPath(\"psl\")})`).option(\"--force\", \"Overwrite an existing scaffold without prompting\").option(\"--write-env\", \"Write a .env file from .env.example (gitignored; default: only .env.example)\").option(\"--probe-db\", \"Connect to DATABASE_URL once and check the server version against the target minimum (opt-in; off by default)\").option(\"--strict-probe\", \"Treat a failed --probe-db as fatal (no-op without --probe-db; init is offline-by-default)\").option(\"--no-install\", \"Skip dependency installation and contract emission\").option(\"--no-skill\", \"Skip Prisma Next skills install (air-gapped CI, restricted registries, etc.)\").action(async (options) => {\n\t\tconst { runInit } = await import(\"./init-DHctXAI9.mjs\");\n\t\tconst flags = parseGlobalFlagsOrExit(options);\n\t\tconst canPrompt = deriveCanPrompt({\n\t\t\tflagsInteractive: flags.interactive,\n\t\t\toptionInteractive: options.interactive,\n\t\t\tstdinIsTTY: Boolean(process.stdin.isTTY)\n\t\t});\n\t\tconst exitCode = await runInit(process.cwd(), {\n\t\t\toptions,\n\t\t\tflags,\n\t\t\tcanPrompt\n\t\t});\n\t\tprocess.exit(exitCode);\n\t});\n}\n//#endregion\n//#region src/commands/lsp.ts\nfunction createLspCommand() {\n\tconst command = new Command(\"lsp\");\n\tsetCommandDescriptions(command, \"Start the Prisma Next language server\", \"Launches a Language Server Protocol server that publishes PSL parse diagnostics\\nand handles whole-document PSL formatting for the schema inputs declared in\\nyour config (contract.source.inputs). Formatting uses the Prisma Next PSL\\nformatter and the formatter block from the project config.\\nCommunicates over stdio; intended to be spawned by an\\neditor, not run interactively. The server keeps running until the editor client\\ndisconnects.\");\n\tsetCommandExamples(command, [\"prisma-next lsp --stdio\"]);\n\taddGlobalOptions(command).option(\"--stdio\", \"Communicate with the editor over stdio (the default and only transport)\").action(async () => {\n\t\tconst { startServer } = await import(\"@internal/language-server\");\n\t\tstartServer();\n\t});\n\treturn command;\n}\n//#endregion\n//#region src/utils/suggest-command.ts\n/**\n* Suggests similar command names for a mistyped input.\n*\n* Uses Levenshtein distance to find close matches. Only suggests commands\n* within a reasonable distance threshold (40% of the input length, minimum 2).\n* Returns up to 3 suggestions in case of ties.\n*\n* @returns Array of suggested command names (empty if nothing is close enough).\n*/\nfunction suggestCommands(input, candidates) {\n\tif (candidates.length === 0) return [];\n\tconst maxDistance = Math.max(2, Math.ceil(input.length * .4));\n\tconst scored = candidates.map((name) => ({\n\t\tname,\n\t\tdist: distance(input, name)\n\t})).filter((entry) => entry.dist <= maxDistance).sort((a, b) => a.dist - b.dist);\n\tif (scored.length === 0) return [];\n\tconst bestDist = scored[0].dist;\n\treturn scored.filter((entry) => entry.dist === bestDist).slice(0, 3).map((entry) => entry.name);\n}\n//#endregion\n//#region src/utils/telemetry.ts\n/**\n* Resolve the commander command path from a leaf `Command`, walking up\n* the parent chain. Result is rooted at the program name and ends at\n* the leaf — `['prisma-next', 'migration', 'new']` for\n* `prisma-next migration new …`.\n*/\nfunction commandPathFor(actionCommand) {\n\tconst path = [];\n\tlet cursor = actionCommand;\n\twhile (cursor !== null) {\n\t\tpath.unshift(cursor.name());\n\t\tcursor = cursor.parent;\n\t}\n\treturn path;\n}\nfunction commanderOptionSnapshots(actionCommand) {\n\treturn actionCommand.options.map((option) => {\n\t\tconst attributeName = option.attributeName();\n\t\treturn {\n\t\t\tattributeName,\n\t\t\tlongName: option.long ?? null,\n\t\t\tsource: actionCommand.getOptionValueSource(attributeName) ?? null\n\t\t};\n\t});\n}\n/**\n* Project commander's leaf `Command` into the wire-shape snapshot the\n* telemetry sanitiser consumes. Pure projection — no env, no I/O.\n*/\nfunction commanderSnapshotForTelemetry(actionCommand) {\n\treturn {\n\t\tcommandPath: commandPathFor(actionCommand),\n\t\tpositionalArgs: actionCommand.args,\n\t\toptions: commanderOptionSnapshots(actionCommand)\n\t};\n}\nfunction resolveTelemetryGate() {\n\tif (isCI()) return {\n\t\tenabled: false,\n\t\toutcome: {\n\t\t\tspawned: false,\n\t\t\treason: \"ci\"\n\t\t}\n\t};\n\tconst userConfig = readUserConfig();\n\tif (!resolveGating({\n\t\tenv: process.env,\n\t\tconfig: userConfig\n\t}).enabled) return {\n\t\tenabled: false,\n\t\toutcome: {\n\t\t\tspawned: false,\n\t\t\treason: \"gated-off\"\n\t\t}\n\t};\n\treturn {\n\t\tenabled: true,\n\t\tuserConfig\n\t};\n}\n/**\n* Path to the compiled sender script inside `@internal/cli-telemetry`'s\n* `dist/`. Resolved off this module's `import.meta.url` via the package\n* specifier `@internal/cli-telemetry/sender`, so the consumer pays\n* no attention to internal package layout.\n*/\nfunction senderPath() {\n\treturn fileURLToPath(new URL(import.meta.resolve(\"@internal/cli-telemetry/sender\")));\n}\nfunction fireTelemetry(actionCommand, userConfig) {\n\treturn runTelemetry({\n\t\tcommand: commanderSnapshotForTelemetry(actionCommand),\n\t\tversion,\n\t\tprojectRoot: process.cwd(),\n\t\tsenderPath: senderPath(),\n\t\tisCI: isCI(),\n\t\tenv: process.env,\n\t\tuserConfig\n\t});\n}\n/**\n* preAction-stage entry point. Synchronous by construction: resolve\n* env/CI/user-consent gates (cheap, all in-memory and a single tiny\n* user-config read), then — only when enabled — `fork()` the detached\n* sender script. The forked child loads `prisma-next.config.*` via\n* c12 on its own (see `loadProjectConfig` in cli-telemetry); the\n* parent does no project-config I/O on the command's hot path.\n*\n* Privacy invariant: gate resolution always happens before any project\n* config touches disk. The child loading user TS code is acceptable\n* only because it's gated behind the same resolved-enabled signal.\n*/\n/**\n* Builds the one-time first-run disclosure. The resolved absolute path to\n* the user-level config file is substituted in so the user can see exactly\n* which file to edit (it must not be confused with `prisma-next.config.ts`).\n* `prisma-next telemetry disable` is named as the primary, friendliest\n* opt-out, alongside the env vars and the config edit.\n*/\nfunction firstRunNotice(configPath) {\n\treturn [\n\t\t\"Prisma Next collects anonymous CLI usage data, enabled by default.\",\n\t\t\"What's collected and why: https://prisma-next.dev/docs/cli/telemetry.\",\n\t\t\"Opt out: run \\\"prisma-next telemetry disable\\\", set DO_NOT_TRACK=1 or\",\n\t\t`PRISMA_NEXT_DISABLE_TELEMETRY=1, or set \"enableTelemetry\": false in ${configPath}.`\n\t].join(\" \");\n}\n/**\n* Best-effort first-run disclosure + installationId mint. Runs only on the\n* gating-enabled path. Prints the notice to stderr (never stdout) and mints\n* a persistent id without touching `enableTelemetry`, so the opt-out default\n* stays intact and no unasked-for consent is recorded.\n*\n* Every step is wrapped so an un-writable config dir (or any other failure)\n* never throws and never blocks the command. Returns the minted (or\n* pre-existing) id so the caller can forward it to `runTelemetry` without a\n* redundant disk read. On mint failure it returns `undefined`: the notice may\n* reprint next run, and `runTelemetry` no-ops on the missing id.\n*/\nfunction discloseAndMintOnFirstRun() {\n\ttry {\n\t\tprocess.stderr.write(`${firstRunNotice(userConfigPath())}\\n`);\n\t} catch {}\n\ttry {\n\t\treturn ensureInstallationId();\n\t} catch {}\n}\n/**\n* True when the run is the `telemetry` command (or one of its\n* subcommands). The usage-telemetry preAction fire is exempted for it:\n* it would be absurd for `telemetry disable` to send a usage event before\n* disabling, or for `telemetry status` to mint an id + send while merely\n* reporting state. This is the only command-specific exemption.\n*\n* The check is rooted at the program: the path must be\n* `['prisma-next', 'telemetry', …]`, so it matches the top-level\n* `telemetry` command and its subcommands without matching a hypothetical\n* nested `… telemetry` elsewhere.\n*/\nfunction isTelemetryCommand(actionCommand) {\n\treturn commandPathFor(actionCommand)[1] === \"telemetry\";\n}\nfunction fireTelemetryFromPreAction(actionCommand) {\n\tif (isTelemetryCommand(actionCommand)) return {\n\t\tspawned: false,\n\t\treason: \"gated-off\"\n\t};\n\tconst gate = resolveTelemetryGate();\n\tif (!gate.enabled) return gate.outcome;\n\tconst storedId = gate.userConfig.installationId;\n\tif (typeof storedId !== \"string\" || storedId.length === 0) {\n\t\tconst installationId = discloseAndMintOnFirstRun();\n\t\treturn fireTelemetry(actionCommand, installationId === void 0 ? gate.userConfig : {\n\t\t\t...gate.userConfig,\n\t\t\tinstallationId\n\t\t});\n\t}\n\treturn fireTelemetry(actionCommand, gate.userConfig);\n}\n//#endregion\n//#region src/cli.ts\ninstallShutdownHandlers();\n/**\n* Lookup table mapping removed subcommands to their replacement verbs.\n* Keyed by `<parent>:<subcommand>` (e.g. `migration:apply`).\n* The handler consults this before falling back to the fuzzy suggest engine.\n*/\nconst removedVerbRedirects = {\n\t\"migration:apply\": \"Use `prisma-next migrate --to <contract>` instead.\",\n\t\"migration:ref\": \"Use `prisma-next ref set|list|delete` instead.\"\n};\n/**\n* Removed flags on specific subcommands. Keyed by `<parent>:<sub>:<flag>`.\n* Checked during the pre-parse argv scan before commander sees the flags.\n*/\nconst removedFlagRedirects = {\n\t\"migration:status:graph\": \"Use `prisma-next migration graph` to view the migration graph.\",\n\t\"migration:status:all\": \"Use `prisma-next migration log --db <url>` to view the full execution history.\",\n\t\"migration:status:limit\": \"Use `prisma-next migration log --db <url>` to view the full execution history.\",\n\t\"migration:status:ref\": \"Use `--to <contract>` instead of `--ref`.\"\n};\n/**\n* Formats the \"Did you mean ...?\" hint for an unknown command.\n*/\nfunction formatSuggestion(input, candidates) {\n\tconst suggestions = suggestCommands(input, candidates.map((c) => c));\n\tif (suggestions.length === 0) return \"\";\n\tif (suggestions.length === 1) return `\\nDid you mean ${suggestions[0]}?\\n`;\n\treturn `\\nDid you mean one of these?\\n${suggestions.map((s) => ` ${s}`).join(\"\\n\")}\\n`;\n}\nconst program = new Command();\nprogram.name(\"prisma-next\").description(\"Prisma Next CLI\").version(version);\nprogram.hook(\"preAction\", (_thisCommand, actionCommand) => {\n\ttry {\n\t\tfireTelemetryFromPreAction(actionCommand);\n\t} catch {}\n});\nconst versionOption = program.options.find((opt) => opt.flags.includes(\"--version\"));\nif (versionOption) versionOption.description = \"Output the version number\";\nprogram.configureOutput({\n\twriteErr: () => {},\n\twriteOut: (str) => {\n\t\tprocess.stdout.write(str);\n\t}\n});\nconst rootHelpFormatter = (cmd) => {\n\treturn formatRootHelp({\n\t\tprogram: cmd,\n\t\tflags: parseGlobalFlags({})\n\t});\n};\nprogram.configureHelp({\n\tformatHelp: rootHelpFormatter,\n\tsubcommandDescription: () => \"\"\n});\nprogram.exitOverride((err) => {\n\tif (err) {\n\t\tconst errorCode = err.code;\n\t\tconst errorMessage = String(err.message ?? \"\");\n\t\tconst errorName = err.name ?? \"\";\n\t\tif (errorCode === \"commander.unknownCommand\" || errorCode === \"commander.unknownArgument\" || errorName === \"CommanderError\" && (errorMessage.includes(\"unknown command\") || errorMessage.includes(\"unknown argument\"))) {\n\t\t\tconst flags = parseGlobalFlags({});\n\t\t\tconst match = errorMessage.match(/unknown command ['\"]([^'\"]+)['\"]/);\n\t\t\tconst commandName = match ? match[1] : process.argv[3] || process.argv[2] || \"unknown\";\n\t\t\tconst firstArg = process.argv[2];\n\t\t\tconst parentCommand = firstArg ? program.commands.find((cmd) => cmd.name() === firstArg) : void 0;\n\t\t\tif (parentCommand && commandName !== firstArg) {\n\t\t\t\tconst subNames = parentCommand.commands.map((c) => c.name());\n\t\t\t\tprocess.stderr.write(`Unknown command: ${commandName}${formatSuggestion(commandName, subNames)}\\n`);\n\t\t\t\tconst helpText = formatCommandHelp({\n\t\t\t\t\tcommand: parentCommand,\n\t\t\t\t\tflags\n\t\t\t\t});\n\t\t\t\tprocess.stderr.write(`${helpText}\\n`);\n\t\t\t} else {\n\t\t\t\tconst topNames = program.commands.map((c) => c.name());\n\t\t\t\tprocess.stderr.write(`Unknown command: ${commandName}${formatSuggestion(commandName, topNames)}\\n`);\n\t\t\t\tconst helpText = formatRootHelp({\n\t\t\t\t\tprogram,\n\t\t\t\t\tflags\n\t\t\t\t});\n\t\t\t\tprocess.stderr.write(`${helpText}\\n`);\n\t\t\t}\n\t\t\tprocess.exit(2);\n\t\t\treturn;\n\t\t}\n\t\tif (errorCode === \"commander.help\" || errorCode === \"commander.helpDisplayed\" || errorCode === \"outputHelp\" || errorMessage === \"(outputHelp)\" || errorMessage.includes(\"outputHelp\") || errorName === \"CommanderError\" && errorMessage.includes(\"outputHelp\")) {\n\t\t\tprocess.exit(0);\n\t\t\treturn;\n\t\t}\n\t\tif (errorCode === \"commander.missingArgument\" || errorCode === \"commander.missingMandatoryOptionValue\" || errorName === \"CommanderError\" && (errorMessage.includes(\"missing\") || errorMessage.includes(\"required\"))) {\n\t\t\tprocess.exit(2);\n\t\t\treturn;\n\t\t}\n\t\tprocess.stderr.write(`Unhandled error: ${err.message}\\n`);\n\t\tif (err.stack) process.stderr.write(`${err.stack}\\n`);\n\t\tprocess.exit(1);\n\t}\n\tprocess.exit(0);\n});\nconst contractCommand = new Command(\"contract\");\nsetCommandDescriptions(contractCommand, \"Contract management commands\", \"Define and emit your application data contract. The contract describes your schema as a\\ndeclarative data structure that can be signed and verified against your database.\");\ncontractCommand.configureHelp({\n\tformatHelp: (cmd) => {\n\t\treturn formatCommandHelp({\n\t\t\tcommand: cmd,\n\t\t\tflags: parseGlobalFlags({})\n\t\t});\n\t},\n\tsubcommandDescription: () => \"\"\n});\nconst contractEmitCommand = createContractEmitCommand();\ncontractCommand.addCommand(contractEmitCommand);\nconst contractInferCommand = createContractInferCommand();\ncontractCommand.addCommand(contractInferCommand);\nconst dbCommand = new Command(\"db\");\nsetCommandDescriptions(dbCommand, \"Database management commands\", \"Verify and sign your database with your contract. Ensure your database schema matches\\nyour contract, and sign it to record the contract hash for future verification.\");\ndbCommand.configureHelp({\n\tformatHelp: (cmd) => {\n\t\treturn formatCommandHelp({\n\t\t\tcommand: cmd,\n\t\t\tflags: parseGlobalFlags({})\n\t\t});\n\t},\n\tsubcommandDescription: () => \"\"\n});\nconst dbVerifyCommand = createDbVerifyCommand();\ndbCommand.addCommand(dbVerifyCommand);\nconst dbInitCommand = createDbInitCommand();\ndbCommand.addCommand(dbInitCommand);\nconst dbUpdateCommand = createDbUpdateCommand();\ndbCommand.addCommand(dbUpdateCommand);\nconst dbSchemaCommand = createDbSchemaCommand();\ndbCommand.addCommand(dbSchemaCommand);\nconst dbSignCommand = createDbSignCommand();\ndbCommand.addCommand(dbSignCommand);\nconst migrationCommand = new Command(\"migration\");\nsetCommandDescriptions(migrationCommand, \"On-disk migration management commands\", \"Plan, apply, and scaffold on-disk migration packages. Migrations are\\ncontract-to-contract edges stored as versioned directories under migrations/.\");\nmigrationCommand.configureHelp({\n\tformatHelp: (cmd) => {\n\t\treturn formatCommandHelp({\n\t\t\tcommand: cmd,\n\t\t\tflags: parseGlobalFlags({})\n\t\t});\n\t},\n\tsubcommandDescription: () => \"\"\n});\nconst migrationPlanCommand = createMigrationPlanCommand();\nmigrationCommand.addCommand(migrationPlanCommand);\nconst migrationNewCommand = createMigrationNewCommand();\nmigrationCommand.addCommand(migrationNewCommand);\nconst migrationShowCommand = createMigrationShowCommand();\nmigrationCommand.addCommand(migrationShowCommand);\nconst migrationStatusCommand = createMigrationStatusCommand();\nmigrationCommand.addCommand(migrationStatusCommand);\nconst migrationLogCommand = createMigrationLogCommand();\nmigrationCommand.addCommand(migrationLogCommand);\nconst migrationListCommand = createMigrationListCommand();\nmigrationCommand.addCommand(migrationListCommand);\nconst migrationGraphCommand = createMigrationGraphCommand();\nmigrationCommand.addCommand(migrationGraphCommand);\nconst migrationCheckCommand = createMigrationCheckCommand();\nmigrationCommand.addCommand(migrationCheckCommand);\nconst migrateCommand = createMigrateCommand();\nconst refCommand = createRefCommand();\nconst telemetryCommand = createTelemetryCommand();\nconst initCommand = createInitCommand();\nconst formatCommand = createFormatCommand();\nconst lspCommand = createLspCommand();\nprogram.addCommand(initCommand);\nprogram.addCommand(migrateCommand);\nprogram.addCommand(formatCommand);\nprogram.addCommand(lspCommand);\nprogram.addCommand(contractCommand);\nprogram.addCommand(dbCommand);\nprogram.addCommand(migrationCommand);\nprogram.addCommand(refCommand);\nprogram.addCommand(telemetryCommand);\nconst TELEMETRY_CRASH_TEST_SLEEP_MS = 200;\nif (process.env[\"PRISMA_NEXT_ENABLE_TEST_COMMANDS\"] === \"1\") {\n\tconst telemetryCrashTestCommand = new Command(\"__telemetry-crash-test\").description(\"Internal: deliberately throw for the telemetry e2e suite.\").action(async () => {\n\t\tawait new Promise((settle) => setTimeout(settle, TELEMETRY_CRASH_TEST_SLEEP_MS));\n\t\tthrow new Error(\"__telemetry-crash-test: intentional crash for e2e coverage\");\n\t});\n\ttelemetryCrashTestCommand.configureHelp({ visibleCommands: () => [] });\n\tprogram.addCommand(telemetryCrashTestCommand, { hidden: true });\n}\nconst helpCommand = new Command(\"help\").description(\"Show usage instructions\").configureHelp({ formatHelp: (cmd) => {\n\treturn formatCommandHelp({\n\t\tcommand: cmd,\n\t\tflags: parseGlobalFlags({})\n\t});\n} }).action(() => {\n\tconst flags = parseGlobalFlags({});\n\tconst helpText = formatRootHelp({\n\t\tprogram,\n\t\tflags\n\t});\n\tprocess.stdout.write(`${helpText}\\n`);\n\tprocess.exit(0);\n});\nprogram.addCommand(helpCommand);\nprogram.action(() => {\n\tconst flags = parseGlobalFlags({});\n\tconst helpText = formatRootHelp({\n\t\tprogram,\n\t\tflags\n\t});\n\tprocess.stderr.write(`${helpText}\\n`);\n\tprocess.exit(0);\n});\nconst args = process.argv.slice(2);\nif (args.length > 0) {\n\tconst commandName = args[0];\n\tif (commandName === \"--version\" || commandName === \"-V\") {\n\t\tprocess.stdout.write(`${program.version()}\\n`);\n\t\tprocess.exit(0);\n\t}\n\tif (!(commandName === \"--help\" || commandName === \"-h\")) {\n\t\tconst command = program.commands.find((cmd) => cmd.name() === commandName);\n\t\tif (!command) {\n\t\t\tconst flags = parseGlobalFlags({});\n\t\t\tconst topNames = program.commands.map((c) => c.name());\n\t\t\tprocess.stderr.write(`Unknown command: ${commandName}${formatSuggestion(commandName, topNames)}\\n`);\n\t\t\tconst helpText = formatRootHelp({\n\t\t\t\tprogram,\n\t\t\t\tflags\n\t\t\t});\n\t\t\tprocess.stderr.write(`${helpText}\\n`);\n\t\t\tprocess.exit(2);\n\t\t} else if (command.commands.length > 0 && args.length >= 2) {\n\t\t\tconst subcommandName = args[1];\n\t\t\tconst redirect = removedVerbRedirects[`${commandName}:${subcommandName}`];\n\t\t\tif (redirect) {\n\t\t\t\tprocess.stderr.write(`Unknown command: ${subcommandName}\\n${redirect}\\n`);\n\t\t\t\tprocess.exit(2);\n\t\t\t}\n\t\t\tfor (let i = 2; i < args.length; i++) {\n\t\t\t\tconst arg = args[i];\n\t\t\t\tif (!arg.startsWith(\"--\")) continue;\n\t\t\t\tconst flagRedirect = removedFlagRedirects[`${commandName}:${subcommandName}:${arg.slice(2)}`];\n\t\t\t\tif (flagRedirect) {\n\t\t\t\t\tprocess.stderr.write(`Unknown option: ${arg}\\n${flagRedirect}\\n`);\n\t\t\t\t\tprocess.exit(2);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (command.commands.length > 0 && args.length === 1) {\n\t\t\tconst helpText = formatCommandHelp({\n\t\t\t\tcommand,\n\t\t\t\tflags: parseGlobalFlags({})\n\t\t\t});\n\t\t\tprocess.stderr.write(`${helpText}\\n`);\n\t\t\tprocess.exit(0);\n\t\t}\n\t}\n}\nprogram.parse();\n//#endregion\nexport { schemaSample as a, targetLabel as c, scaffoldSpecifierResolverFor as i, targetPackageName as l, dbFile as n, starterSchema as o, defaultSchemaPath as r, targetEntrypoint as s, configFile as t, version as u };\n\n//# sourceMappingURL=cli.mjs.map"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6BA,IAAI,UAAU;;;;;;;;;AAWd,SAAS,6BAA6B,QAAQ;CAC7C,OAAO,gCAAgC;EACtC,MAAM;EACN,QAAQ,WAAW,aAAa,yBAAyB;CAC1D,CAAC;AACF;;;;;;;;;;;;;;;;;AAiBA,SAAS,kBAAkB,QAAQ,yBAAyB,wBAAwB;CACnF,OAAO,uBAAuB,WAAW,aAAa,uBAAuB,iBAAiB;AAC/F;;AAEA,SAAS,iBAAiB,QAAQ,SAAS,yBAAyB,wBAAwB;CAC3F,OAAO,uBAAuB,GAAG,WAAW,a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I,CAAC,SAAS;GACb,MAAM,QAAQ,iBAAiB,CAAC,CAAC;GACjC,MAAM,WAAW,QAAQ,SAAS,KAAK,MAAM,EAAE,KAAK,CAAC;GACrD,QAAQ,OAAO,MAAM,oBAAoB,cAAc,iBAAiB,aAAa,QAAQ,EAAE,GAAG;GAClG,MAAM,WAAW,eAAe;IAC/B;IACA;GACD,CAAC;GACD,QAAQ,OAAO,MAAM,GAAG,SAAS,GAAG;GACpC,QAAQ,KAAK,CAAC;EACf,OAAO,IAAI,QAAQ,SAAS,SAAS,KAAK,KAAK,UAAU,GAAG;GAC3D,MAAM,iBAAiB,KAAK;GAC5B,MAAM,WAAW,qBAAqB,GAAG,YAAY,GAAG;GACxD,IAAI,UAAU;IACb,QAAQ,OAAO,MAAM,oBAAoB,eAAe,IAAI,SAAS,GAAG;IACxE,QAAQ,KAAK,CAAC;GACf;GACA,KAAK,IAAI,IAAI,GAAG,IAAI,KAAK,QAAQ,KAAK;IACrC,MAAM,MAAM,KAAK;IACjB,IAAI,CAAC,IAAI,WAAW,IAAI,GAAG;IAC3B,MAAM,eAAe,qBAAqB,GAAG,YAAY,GAAG,eAAe,GAAG,IAAI,MAAM,CAAC;IACzF,IAAI,cAAc;KACjB,QAAQ,OAAO,MAAM,mBAAmB,IAAI,IAAI,aAAa,GAAG;KAChE,QAAQ,KAAK,CAAC;IACf;GACD;EACD;EACA,IAAI,QAAQ,SAAS,SAAS,KAAK,KAAK,WAAW,GAAG;GACrD,MAAM,WAAW,kBAAkB;IAClC;IACA,OAAO,iBAAiB,CAAC,CAAC;GAC3B,CAAC;GACD,QAAQ,OAAO,MAAM,GAAG,SAAS,GAAG;GACpC,QAAQ,KAAK,CAAC;EACf;CACD;AACD;AACA,QAAQ,MAAM"}
1
+ {"version":3,"file":"bin__prisma-next.mjs","names":["isCI"],"sources":["../../../../1-framework/3-tooling/cli/dist/cli.mjs"],"sourcesContent":["#!/usr/bin/env node\nimport { D as isCI, O as formatCommandHelp, g as parseGlobalFlagsOrExit, h as parseGlobalFlags, k as formatRootHelp, l as setCommandDescriptions, m as deriveCanPrompt, t as addGlobalOptions, u as setCommandExamples, v as installShutdownHandlers } from \"./command-helpers-CAoXqAY9.mjs\";\nimport { t as createContractEmitCommand } from \"./contract-emit-0hSjbuxp.mjs\";\nimport { t as createContractInferCommand } from \"./contract-infer-BnkqpftN.mjs\";\nimport { createDbInitCommand } from \"./commands/db-init.mjs\";\nimport { createDbSchemaCommand } from \"./commands/db-schema.mjs\";\nimport { createDbSignCommand } from \"./commands/db-sign.mjs\";\nimport { createDbUpdateCommand } from \"./commands/db-update.mjs\";\nimport { t as createDbVerifyCommand } from \"./db-verify-CKPsRFrj.mjs\";\nimport { t as createFormatCommand } from \"./format-ByDm2goZ.mjs\";\nimport { t as createMigrationListCommand } from \"./migration-list-BFBeo1_X.mjs\";\nimport { createMigrateCommand } from \"./commands/migrate.mjs\";\nimport { t as createMigrationCheckCommand } from \"./migration-check-DcwUnadt.mjs\";\nimport { createMigrationGraphCommand } from \"./commands/migration-graph.mjs\";\nimport { t as createMigrationLogCommand } from \"./migration-log-CS5IWcNq.mjs\";\nimport { createMigrationNewCommand } from \"./commands/migration-new.mjs\";\nimport { t as createMigrationPlanCommand } from \"./migration-plan-q_L84PN1.mjs\";\nimport { createMigrationShowCommand } from \"./commands/migration-show.mjs\";\nimport { r as createMigrationStatusCommand } from \"./migration-status-CE7cQLDq.mjs\";\nimport { createRefCommand } from \"./commands/ref.mjs\";\nimport { t as createTelemetryCommand } from \"./telemetry-CmbCa3Ld.mjs\";\nimport { Command } from \"commander\";\nimport { createScaffoldSpecifierResolver } from \"@internal/publish-surface/import-roots\";\nimport { DEFAULT_CONTRACT_SOURCE_DIR } from \"@internal/config/config-types\";\nimport { keepInternalSpecifiers } from \"@internal/framework-components/emission\";\nimport { ensureInstallationId, readUserConfig, resolveGating, runTelemetry, userConfigPath } from \"@internal/cli-telemetry\";\nimport { distance } from \"closest-match\";\nimport { fileURLToPath } from \"node:url\";\n//#region package.json\nvar version = \"0.17.0-dev.10\";\n//#endregion\n//#region src/commands/init/templates/code-templates.ts\n/**\n* The resolver a scaffold for `target` is written against.\n*\n* A scaffold is always on the facade root: `init` writes an application around\n* one database package, and the workspace names are not published, so a project\n* scaffolded against them could not install (ADR 242). Both the files `init`\n* writes and the dependency it adds go through this, so they cannot disagree.\n*/\nfunction scaffoldSpecifierResolverFor(target) {\n\treturn createScaffoldSpecifierResolver({\n\t\tmode: \"facade\",\n\t\tfacade: target === \"postgres\" ? \"@prisma/orm-postgres\" : \"@prisma/orm-mongo\"\n\t});\n}\n/**\n* The package name a scaffolded project depends on and imports from, for the\n* import root it is being scaffolded against.\n*\n* Every specifier the scaffold writes derives from this one, and `init` builds\n* a single resolver and hands it to both the file templates and the dependency\n* it installs — so the two cannot disagree. The one caller that deliberately\n* does not thread a resolver is the re-init cleanup in `inputs.ts`, which\n* inspects a manifest an earlier run wrote rather than writing one.\n*\n* Resolvers for scaffolding should come from `createScaffoldSpecifierResolver`\n* in the publish-surface package, which rejects the roots a facade-shaped\n* scaffold cannot express. (Named without its scope on purpose: JSDoc survives\n* into the published bundle, where an internal package name would trip the\n* shell tarball checks.)\n*/\nfunction targetPackageName(target, resolveImportSpecifier = keepInternalSpecifiers) {\n\treturn resolveImportSpecifier(target === \"postgres\" ? \"@internal/postgres\" : \"@internal/mongo\");\n}\n/** One entrypoint of the scaffolded project's target package. */\nfunction targetEntrypoint(target, subpath, resolveImportSpecifier = keepInternalSpecifiers) {\n\treturn resolveImportSpecifier(`${target === \"postgres\" ? \"@internal/postgres\" : \"@internal/mongo\"}/${subpath}`);\n}\nfunction targetLabel(target) {\n\treturn target === \"postgres\" ? \"PostgreSQL\" : \"MongoDB\";\n}\nfunction defaultSchemaPath(authoring) {\n\tif (authoring === \"typescript\") return `${DEFAULT_CONTRACT_SOURCE_DIR}/contract.ts`;\n\treturn `${DEFAULT_CONTRACT_SOURCE_DIR}/contract.prisma`;\n}\nfunction starterSchema(target, authoring, resolveImportSpecifier = keepInternalSpecifiers) {\n\tif (authoring === \"typescript\") {\n\t\tconst builder = targetEntrypoint(target, \"contract-builder\", resolveImportSpecifier);\n\t\treturn target === \"mongo\" ? starterSchemaTsMongo(builder) : starterSchemaTsPostgres(builder);\n\t}\n\treturn target === \"mongo\" ? starterSchemaPslMongo() : starterSchemaPslPostgres();\n}\n/**\n* Renders a short authoring-appropriate schema sample (FR5.1) for embedding\n* in `prisma-next.md`. Returns a complete fenced markdown code block.\n*\n* The sample intentionally shows just one model: it's illustrative, not\n* a substitute for the full scaffolded contract file. The TS samples use\n* the same outer shape as `starterSchemaTs*` (FR5.3) so a user reading\n* the doc and the file side-by-side sees the same structure.\n*/\nfunction schemaSample(target, authoring, resolveImportSpecifier = keepInternalSpecifiers) {\n\tif (authoring === \"typescript\") {\n\t\tconst builder = targetEntrypoint(target, \"contract-builder\", resolveImportSpecifier);\n\t\treturn target === \"mongo\" ? schemaSampleTsMongo(builder) : schemaSampleTsPostgres(builder);\n\t}\n\treturn target === \"mongo\" ? schemaSamplePslMongo() : schemaSamplePslPostgres();\n}\nfunction schemaSamplePslPostgres() {\n\treturn `\\`\\`\\`prisma\nmodel User {\n id Int @id @default(autoincrement())\n email String @unique\n username String?\n name String?\n}\n\\`\\`\\``;\n}\nfunction schemaSamplePslMongo() {\n\treturn `\\`\\`\\`prisma\nmodel User {\n id ObjectId @id @map(\"_id\")\n email String @unique\n username String?\n name String?\n @@map(\"users\")\n}\n\\`\\`\\``;\n}\nfunction schemaSampleTsPostgres(builder) {\n\treturn `\\`\\`\\`typescript\nimport { defineContract } from '${builder}';\n\nexport const contract = defineContract(\n {},\n ({ field, model }) => ({\n models: {\n User: model('User', {\n fields: {\n id: field.id.uuidv7String(),\n email: field.text().unique(),\n username: field.text().optional(),\n name: field.text().optional(),\n },\n }),\n },\n }),\n);\n\\`\\`\\``;\n}\nfunction schemaSampleTsMongo(builder) {\n\treturn `\\`\\`\\`typescript\nimport { defineContract } from '${builder}';\n\nexport const contract = defineContract(\n {},\n ({ field, model }) => ({\n models: {\n User: model('User', {\n collection: 'users',\n fields: {\n _id: field.objectId(),\n email: field.string(),\n username: field.string().optional(),\n name: field.string().optional(),\n },\n }),\n },\n }),\n);\n\\`\\`\\``;\n}\nfunction starterSchemaPslPostgres() {\n\treturn `// use prisma-next\n\nmodel User {\n id Int @id @default(autoincrement())\n email String @unique\n username String?\n name String?\n posts Post[]\n createdAt DateTime @default(now())\n updatedAt temporal.updatedAt()\n}\n\nmodel Post {\n id Int @id @default(autoincrement())\n title String\n content String?\n author User @relation(fields: [authorId], references: [id])\n authorId Int\n createdAt DateTime @default(now())\n updatedAt temporal.updatedAt()\n}\n`;\n}\nfunction starterSchemaPslMongo() {\n\treturn `// use prisma-next\n\nmodel User {\n id ObjectId @id @map(\"_id\")\n email String @unique\n username String?\n name String?\n posts Post[]\n @@map(\"users\")\n}\n\nmodel Post {\n id ObjectId @id @map(\"_id\")\n title String\n content String?\n author User @relation(fields: [authorId], references: [id])\n authorId ObjectId\n @@map(\"posts\")\n}\n`;\n}\nfunction starterSchemaTsPostgres(builder) {\n\treturn `import { defineContract } from '${builder}';\n\nexport const contract = defineContract(\n {},\n ({ field, model, rel }) => ({\n models: {\n User: model('User', {\n fields: {\n id: field.id.uuidv7String(),\n email: field.text().unique(),\n username: field.text().optional(),\n name: field.text().optional(),\n createdAt: field.temporal.createdAt(),\n updatedAt: field.temporal.updatedAt(),\n },\n relations: {\n posts: rel.hasMany('Post', { by: 'authorId' }),\n },\n }),\n\n Post: model('Post', {\n fields: {\n id: field.id.uuidv7String(),\n title: field.text(),\n content: field.text().optional(),\n authorId: field.uuidString(),\n createdAt: field.temporal.createdAt(),\n updatedAt: field.temporal.updatedAt(),\n },\n relations: {\n author: rel.belongsTo('User', { from: 'authorId', to: 'id' }),\n },\n }),\n },\n }),\n);\n`;\n}\nfunction starterSchemaTsMongo(builder) {\n\treturn `import { defineContract } from '${builder}';\n\nexport const contract = defineContract(\n {},\n ({ field, model, rel }) => ({\n models: {\n User: model('User', {\n collection: 'users',\n fields: {\n _id: field.objectId(),\n email: field.string(),\n username: field.string().optional(),\n name: field.string().optional(),\n },\n relations: {\n posts: rel.hasMany('Post', { from: '_id', to: 'authorId' }),\n },\n }),\n\n Post: model('Post', {\n collection: 'posts',\n fields: {\n _id: field.objectId(),\n title: field.string(),\n content: field.string().optional(),\n authorId: field.objectId(),\n },\n relations: {\n author: rel.belongsTo('User', { from: 'authorId', to: '_id' }),\n },\n }),\n },\n }),\n);\n`;\n}\nfunction configFile(target, contractPath, resolveImportSpecifier = keepInternalSpecifiers) {\n\treturn `import 'dotenv/config';\nimport { defineConfig } from '${targetEntrypoint(target, \"config\", resolveImportSpecifier)}';\n\nexport default defineConfig({\n contract: ${JSON.stringify(contractPath)},\n db: {\n connection: process.env['DATABASE_URL']!,\n },\n});\n`;\n}\nfunction dbFile(target, resolveImportSpecifier = keepInternalSpecifiers) {\n\tconst runtime = targetEntrypoint(target, \"runtime\", resolveImportSpecifier);\n\tif (target === \"postgres\") return `import postgres from '${runtime}';\nimport type { Contract } from './contract.d';\nimport contractJson from './contract.json' with { type: 'json' };\n\nexport const db = postgres<Contract>({\n contractJson,\n url: process.env['DATABASE_URL']!,\n});\n`;\n\treturn `import mongo from '${runtime}';\nimport type { Contract } from './contract.d';\nimport contractJson from './contract.json' with { type: 'json' };\n\nexport const db = mongo<Contract>({\n contractJson,\n url: process.env['DATABASE_URL']!,\n});\n`;\n}\n//#endregion\n//#region src/commands/init/index.ts\nfunction createInitCommand() {\n\tconst command = new Command(\"init\");\n\tsetCommandDescriptions(command, \"Initialize a new Prisma Next project\", `Scaffolds config, schema, and runtime files, installs dependencies,\nand emits the contract. Gets you from zero to typed queries in one step.\n\nRun interactively for a guided experience, or supply --target / --authoring\nand --yes for a fully scriptable run (CI, AI coding agents, automation).\n\nExit codes (see CLI Style Guide § Exit Codes):\n 0 OK Init succeeded.\\n 1 INTERNAL_ERROR Unexpected bug in prisma-next (please report).\\n 2 PRECONDITION Bad flags / missing prerequisite (e.g. no package.json).\\n 3 USER_ABORTED User cancelled an interactive prompt.\\n 4 INSTALL_FAILED Dependency installation failed (init-specific).\\n 5 EMIT_FAILED \\`contract emit\\` failed after install (init-specific).\\n 6 SKILL_INSTALL_FAILED Agent-skill install failed (re-run with --no-skill to skip).`);\n\tsetCommandExamples(command, [\n\t\t\"prisma-next init\",\n\t\t\"prisma-next init --yes --target postgres --authoring psl\",\n\t\t\"prisma-next init --yes --target mongodb --authoring typescript --json\",\n\t\t\"prisma-next init --yes --force --target postgres --authoring psl # overwrite an existing scaffold\",\n\t\t\"prisma-next init --no-install # skip pnpm/npm install + emit\",\n\t\t\"prisma-next init --no-skill # skip the skills install (air-gapped / restricted env)\"\n\t]);\n\treturn addGlobalOptions(command).option(\"--target <db>\", \"Database target: postgres or mongodb\").option(\"--authoring <style>\", \"Schema authoring style: psl or typescript\").option(\"--schema-path <path>\", `Where to write the starter schema (default: ${defaultSchemaPath(\"psl\")})`).option(\"--force\", \"Overwrite an existing scaffold without prompting\").option(\"--write-env\", \"Write a .env file from .env.example (gitignored; default: only .env.example)\").option(\"--probe-db\", \"Connect to DATABASE_URL once and check the server version against the target minimum (opt-in; off by default)\").option(\"--strict-probe\", \"Treat a failed --probe-db as fatal (no-op without --probe-db; init is offline-by-default)\").option(\"--no-install\", \"Skip dependency installation and contract emission\").option(\"--no-skill\", \"Skip Prisma Next skills install (air-gapped CI, restricted registries, etc.)\").action(async (options) => {\n\t\tconst { runInit } = await import(\"./init-BGm77aWc.mjs\");\n\t\tconst flags = parseGlobalFlagsOrExit(options);\n\t\tconst canPrompt = deriveCanPrompt({\n\t\t\tflagsInteractive: flags.interactive,\n\t\t\toptionInteractive: options.interactive,\n\t\t\tstdinIsTTY: Boolean(process.stdin.isTTY)\n\t\t});\n\t\tconst exitCode = await runInit(process.cwd(), {\n\t\t\toptions,\n\t\t\tflags,\n\t\t\tcanPrompt\n\t\t});\n\t\tprocess.exit(exitCode);\n\t});\n}\n//#endregion\n//#region src/commands/lsp.ts\nfunction createLspCommand() {\n\tconst command = new Command(\"lsp\");\n\tsetCommandDescriptions(command, \"Start the Prisma Next language server\", \"Launches a Language Server Protocol server that publishes PSL parse diagnostics\\nand handles whole-document PSL formatting for the schema inputs declared in\\nyour config (contract.source.inputs). Formatting uses the Prisma Next PSL\\nformatter and the formatter block from the project config.\\nCommunicates over stdio; intended to be spawned by an\\neditor, not run interactively. The server keeps running until the editor client\\ndisconnects.\");\n\tsetCommandExamples(command, [\"prisma-next lsp --stdio\"]);\n\taddGlobalOptions(command).option(\"--stdio\", \"Communicate with the editor over stdio (the default and only transport)\").action(async () => {\n\t\tconst { startServer } = await import(\"@internal/language-server\");\n\t\tstartServer();\n\t});\n\treturn command;\n}\n//#endregion\n//#region src/utils/suggest-command.ts\n/**\n* Suggests similar command names for a mistyped input.\n*\n* Uses Levenshtein distance to find close matches. Only suggests commands\n* within a reasonable distance threshold (40% of the input length, minimum 2).\n* Returns up to 3 suggestions in case of ties.\n*\n* @returns Array of suggested command names (empty if nothing is close enough).\n*/\nfunction suggestCommands(input, candidates) {\n\tif (candidates.length === 0) return [];\n\tconst maxDistance = Math.max(2, Math.ceil(input.length * .4));\n\tconst scored = candidates.map((name) => ({\n\t\tname,\n\t\tdist: distance(input, name)\n\t})).filter((entry) => entry.dist <= maxDistance).sort((a, b) => a.dist - b.dist);\n\tif (scored.length === 0) return [];\n\tconst bestDist = scored[0].dist;\n\treturn scored.filter((entry) => entry.dist === bestDist).slice(0, 3).map((entry) => entry.name);\n}\n//#endregion\n//#region src/utils/telemetry.ts\n/**\n* Resolve the commander command path from a leaf `Command`, walking up\n* the parent chain. Result is rooted at the program name and ends at\n* the leaf — `['prisma-next', 'migration', 'new']` for\n* `prisma-next migration new …`.\n*/\nfunction commandPathFor(actionCommand) {\n\tconst path = [];\n\tlet cursor = actionCommand;\n\twhile (cursor !== null) {\n\t\tpath.unshift(cursor.name());\n\t\tcursor = cursor.parent;\n\t}\n\treturn path;\n}\nfunction commanderOptionSnapshots(actionCommand) {\n\treturn actionCommand.options.map((option) => {\n\t\tconst attributeName = option.attributeName();\n\t\treturn {\n\t\t\tattributeName,\n\t\t\tlongName: option.long ?? null,\n\t\t\tsource: actionCommand.getOptionValueSource(attributeName) ?? null\n\t\t};\n\t});\n}\n/**\n* Project commander's leaf `Command` into the wire-shape snapshot the\n* telemetry sanitiser consumes. Pure projection — no env, no I/O.\n*/\nfunction commanderSnapshotForTelemetry(actionCommand) {\n\treturn {\n\t\tcommandPath: commandPathFor(actionCommand),\n\t\tpositionalArgs: actionCommand.args,\n\t\toptions: commanderOptionSnapshots(actionCommand)\n\t};\n}\nfunction resolveTelemetryGate() {\n\tif (isCI()) return {\n\t\tenabled: false,\n\t\toutcome: {\n\t\t\tspawned: false,\n\t\t\treason: \"ci\"\n\t\t}\n\t};\n\tconst userConfig = readUserConfig();\n\tif (!resolveGating({\n\t\tenv: process.env,\n\t\tconfig: userConfig\n\t}).enabled) return {\n\t\tenabled: false,\n\t\toutcome: {\n\t\t\tspawned: false,\n\t\t\treason: \"gated-off\"\n\t\t}\n\t};\n\treturn {\n\t\tenabled: true,\n\t\tuserConfig\n\t};\n}\n/**\n* Path to the compiled sender script inside `@internal/cli-telemetry`'s\n* `dist/`. Resolved off this module's `import.meta.url` via the package\n* specifier `@internal/cli-telemetry/sender`, so the consumer pays\n* no attention to internal package layout.\n*/\nfunction senderPath() {\n\treturn fileURLToPath(new URL(import.meta.resolve(\"@internal/cli-telemetry/sender\")));\n}\nfunction fireTelemetry(actionCommand, userConfig) {\n\treturn runTelemetry({\n\t\tcommand: commanderSnapshotForTelemetry(actionCommand),\n\t\tversion,\n\t\tprojectRoot: process.cwd(),\n\t\tsenderPath: senderPath(),\n\t\tisCI: isCI(),\n\t\tenv: process.env,\n\t\tuserConfig\n\t});\n}\n/**\n* preAction-stage entry point. Synchronous by construction: resolve\n* env/CI/user-consent gates (cheap, all in-memory and a single tiny\n* user-config read), then — only when enabled — `fork()` the detached\n* sender script. The forked child loads `prisma-next.config.*` via\n* c12 on its own (see `loadProjectConfig` in cli-telemetry); the\n* parent does no project-config I/O on the command's hot path.\n*\n* Privacy invariant: gate resolution always happens before any project\n* config touches disk. The child loading user TS code is acceptable\n* only because it's gated behind the same resolved-enabled signal.\n*/\n/**\n* Builds the one-time first-run disclosure. The resolved absolute path to\n* the user-level config file is substituted in so the user can see exactly\n* which file to edit (it must not be confused with `prisma-next.config.ts`).\n* `prisma-next telemetry disable` is named as the primary, friendliest\n* opt-out, alongside the env vars and the config edit.\n*/\nfunction firstRunNotice(configPath) {\n\treturn [\n\t\t\"Prisma Next collects anonymous CLI usage data, enabled by default.\",\n\t\t\"What's collected and why: https://prisma-next.dev/docs/cli/telemetry.\",\n\t\t\"Opt out: run \\\"prisma-next telemetry disable\\\", set DO_NOT_TRACK=1 or\",\n\t\t`PRISMA_NEXT_DISABLE_TELEMETRY=1, or set \"enableTelemetry\": false in ${configPath}.`\n\t].join(\" \");\n}\n/**\n* Best-effort first-run disclosure + installationId mint. Runs only on the\n* gating-enabled path. Prints the notice to stderr (never stdout) and mints\n* a persistent id without touching `enableTelemetry`, so the opt-out default\n* stays intact and no unasked-for consent is recorded.\n*\n* Every step is wrapped so an un-writable config dir (or any other failure)\n* never throws and never blocks the command. Returns the minted (or\n* pre-existing) id so the caller can forward it to `runTelemetry` without a\n* redundant disk read. On mint failure it returns `undefined`: the notice may\n* reprint next run, and `runTelemetry` no-ops on the missing id.\n*/\nfunction discloseAndMintOnFirstRun() {\n\ttry {\n\t\tprocess.stderr.write(`${firstRunNotice(userConfigPath())}\\n`);\n\t} catch {}\n\ttry {\n\t\treturn ensureInstallationId();\n\t} catch {}\n}\n/**\n* True when the run is the `telemetry` command (or one of its\n* subcommands). The usage-telemetry preAction fire is exempted for it:\n* it would be absurd for `telemetry disable` to send a usage event before\n* disabling, or for `telemetry status` to mint an id + send while merely\n* reporting state. This is the only command-specific exemption.\n*\n* The check is rooted at the program: the path must be\n* `['prisma-next', 'telemetry', …]`, so it matches the top-level\n* `telemetry` command and its subcommands without matching a hypothetical\n* nested `… telemetry` elsewhere.\n*/\nfunction isTelemetryCommand(actionCommand) {\n\treturn commandPathFor(actionCommand)[1] === \"telemetry\";\n}\nfunction fireTelemetryFromPreAction(actionCommand) {\n\tif (isTelemetryCommand(actionCommand)) return {\n\t\tspawned: false,\n\t\treason: \"gated-off\"\n\t};\n\tconst gate = resolveTelemetryGate();\n\tif (!gate.enabled) return gate.outcome;\n\tconst storedId = gate.userConfig.installationId;\n\tif (typeof storedId !== \"string\" || storedId.length === 0) {\n\t\tconst installationId = discloseAndMintOnFirstRun();\n\t\treturn fireTelemetry(actionCommand, installationId === void 0 ? gate.userConfig : {\n\t\t\t...gate.userConfig,\n\t\t\tinstallationId\n\t\t});\n\t}\n\treturn fireTelemetry(actionCommand, gate.userConfig);\n}\n//#endregion\n//#region src/cli.ts\ninstallShutdownHandlers();\n/**\n* Lookup table mapping removed subcommands to their replacement verbs.\n* Keyed by `<parent>:<subcommand>` (e.g. `migration:apply`).\n* The handler consults this before falling back to the fuzzy suggest engine.\n*/\nconst removedVerbRedirects = {\n\t\"migration:apply\": \"Use `prisma-next migrate --to <contract>` instead.\",\n\t\"migration:ref\": \"Use `prisma-next ref set|list|delete` instead.\"\n};\n/**\n* Removed flags on specific subcommands. Keyed by `<parent>:<sub>:<flag>`.\n* Checked during the pre-parse argv scan before commander sees the flags.\n*/\nconst removedFlagRedirects = {\n\t\"migration:status:graph\": \"Use `prisma-next migration graph` to view the migration graph.\",\n\t\"migration:status:all\": \"Use `prisma-next migration log --db <url>` to view the full execution history.\",\n\t\"migration:status:limit\": \"Use `prisma-next migration log --db <url>` to view the full execution history.\",\n\t\"migration:status:ref\": \"Use `--to <contract>` instead of `--ref`.\"\n};\n/**\n* Formats the \"Did you mean ...?\" hint for an unknown command.\n*/\nfunction formatSuggestion(input, candidates) {\n\tconst suggestions = suggestCommands(input, candidates.map((c) => c));\n\tif (suggestions.length === 0) return \"\";\n\tif (suggestions.length === 1) return `\\nDid you mean ${suggestions[0]}?\\n`;\n\treturn `\\nDid you mean one of these?\\n${suggestions.map((s) => ` ${s}`).join(\"\\n\")}\\n`;\n}\nconst program = new Command();\nprogram.name(\"prisma-next\").description(\"Prisma Next CLI\").version(version);\nprogram.hook(\"preAction\", (_thisCommand, actionCommand) => {\n\ttry {\n\t\tfireTelemetryFromPreAction(actionCommand);\n\t} catch {}\n});\nconst versionOption = program.options.find((opt) => opt.flags.includes(\"--version\"));\nif (versionOption) versionOption.description = \"Output the version number\";\nprogram.configureOutput({\n\twriteErr: () => {},\n\twriteOut: (str) => {\n\t\tprocess.stdout.write(str);\n\t}\n});\nconst rootHelpFormatter = (cmd) => {\n\treturn formatRootHelp({\n\t\tprogram: cmd,\n\t\tflags: parseGlobalFlags({})\n\t});\n};\nprogram.configureHelp({\n\tformatHelp: rootHelpFormatter,\n\tsubcommandDescription: () => \"\"\n});\nprogram.exitOverride((err) => {\n\tif (err) {\n\t\tconst errorCode = err.code;\n\t\tconst errorMessage = String(err.message ?? \"\");\n\t\tconst errorName = err.name ?? \"\";\n\t\tif (errorCode === \"commander.unknownCommand\" || errorCode === \"commander.unknownArgument\" || errorName === \"CommanderError\" && (errorMessage.includes(\"unknown command\") || errorMessage.includes(\"unknown argument\"))) {\n\t\t\tconst flags = parseGlobalFlags({});\n\t\t\tconst match = errorMessage.match(/unknown command ['\"]([^'\"]+)['\"]/);\n\t\t\tconst commandName = match ? match[1] : process.argv[3] || process.argv[2] || \"unknown\";\n\t\t\tconst firstArg = process.argv[2];\n\t\t\tconst parentCommand = firstArg ? program.commands.find((cmd) => cmd.name() === firstArg) : void 0;\n\t\t\tif (parentCommand && commandName !== firstArg) {\n\t\t\t\tconst subNames = parentCommand.commands.map((c) => c.name());\n\t\t\t\tprocess.stderr.write(`Unknown command: ${commandName}${formatSuggestion(commandName, subNames)}\\n`);\n\t\t\t\tconst helpText = formatCommandHelp({\n\t\t\t\t\tcommand: parentCommand,\n\t\t\t\t\tflags\n\t\t\t\t});\n\t\t\t\tprocess.stderr.write(`${helpText}\\n`);\n\t\t\t} else {\n\t\t\t\tconst topNames = program.commands.map((c) => c.name());\n\t\t\t\tprocess.stderr.write(`Unknown command: ${commandName}${formatSuggestion(commandName, topNames)}\\n`);\n\t\t\t\tconst helpText = formatRootHelp({\n\t\t\t\t\tprogram,\n\t\t\t\t\tflags\n\t\t\t\t});\n\t\t\t\tprocess.stderr.write(`${helpText}\\n`);\n\t\t\t}\n\t\t\tprocess.exit(2);\n\t\t\treturn;\n\t\t}\n\t\tif (errorCode === \"commander.help\" || errorCode === \"commander.helpDisplayed\" || errorCode === \"outputHelp\" || errorMessage === \"(outputHelp)\" || errorMessage.includes(\"outputHelp\") || errorName === \"CommanderError\" && errorMessage.includes(\"outputHelp\")) {\n\t\t\tprocess.exit(0);\n\t\t\treturn;\n\t\t}\n\t\tif (errorCode === \"commander.missingArgument\" || errorCode === \"commander.missingMandatoryOptionValue\" || errorName === \"CommanderError\" && (errorMessage.includes(\"missing\") || errorMessage.includes(\"required\"))) {\n\t\t\tprocess.exit(2);\n\t\t\treturn;\n\t\t}\n\t\tprocess.stderr.write(`Unhandled error: ${err.message}\\n`);\n\t\tif (err.stack) process.stderr.write(`${err.stack}\\n`);\n\t\tprocess.exit(1);\n\t}\n\tprocess.exit(0);\n});\nconst contractCommand = new Command(\"contract\");\nsetCommandDescriptions(contractCommand, \"Contract management commands\", \"Define and emit your application data contract. The contract describes your schema as a\\ndeclarative data structure that can be signed and verified against your database.\");\ncontractCommand.configureHelp({\n\tformatHelp: (cmd) => {\n\t\treturn formatCommandHelp({\n\t\t\tcommand: cmd,\n\t\t\tflags: parseGlobalFlags({})\n\t\t});\n\t},\n\tsubcommandDescription: () => \"\"\n});\nconst contractEmitCommand = createContractEmitCommand();\ncontractCommand.addCommand(contractEmitCommand);\nconst contractInferCommand = createContractInferCommand();\ncontractCommand.addCommand(contractInferCommand);\nconst dbCommand = new Command(\"db\");\nsetCommandDescriptions(dbCommand, \"Database management commands\", \"Verify and sign your database with your contract. Ensure your database schema matches\\nyour contract, and sign it to record the contract hash for future verification.\");\ndbCommand.configureHelp({\n\tformatHelp: (cmd) => {\n\t\treturn formatCommandHelp({\n\t\t\tcommand: cmd,\n\t\t\tflags: parseGlobalFlags({})\n\t\t});\n\t},\n\tsubcommandDescription: () => \"\"\n});\nconst dbVerifyCommand = createDbVerifyCommand();\ndbCommand.addCommand(dbVerifyCommand);\nconst dbInitCommand = createDbInitCommand();\ndbCommand.addCommand(dbInitCommand);\nconst dbUpdateCommand = createDbUpdateCommand();\ndbCommand.addCommand(dbUpdateCommand);\nconst dbSchemaCommand = createDbSchemaCommand();\ndbCommand.addCommand(dbSchemaCommand);\nconst dbSignCommand = createDbSignCommand();\ndbCommand.addCommand(dbSignCommand);\nconst migrationCommand = new Command(\"migration\");\nsetCommandDescriptions(migrationCommand, \"On-disk migration management commands\", \"Plan, apply, and scaffold on-disk migration packages. Migrations are\\ncontract-to-contract edges stored as versioned directories under migrations/.\");\nmigrationCommand.configureHelp({\n\tformatHelp: (cmd) => {\n\t\treturn formatCommandHelp({\n\t\t\tcommand: cmd,\n\t\t\tflags: parseGlobalFlags({})\n\t\t});\n\t},\n\tsubcommandDescription: () => \"\"\n});\nconst migrationPlanCommand = createMigrationPlanCommand();\nmigrationCommand.addCommand(migrationPlanCommand);\nconst migrationNewCommand = createMigrationNewCommand();\nmigrationCommand.addCommand(migrationNewCommand);\nconst migrationShowCommand = createMigrationShowCommand();\nmigrationCommand.addCommand(migrationShowCommand);\nconst migrationStatusCommand = createMigrationStatusCommand();\nmigrationCommand.addCommand(migrationStatusCommand);\nconst migrationLogCommand = createMigrationLogCommand();\nmigrationCommand.addCommand(migrationLogCommand);\nconst migrationListCommand = createMigrationListCommand();\nmigrationCommand.addCommand(migrationListCommand);\nconst migrationGraphCommand = createMigrationGraphCommand();\nmigrationCommand.addCommand(migrationGraphCommand);\nconst migrationCheckCommand = createMigrationCheckCommand();\nmigrationCommand.addCommand(migrationCheckCommand);\nconst migrateCommand = createMigrateCommand();\nconst refCommand = createRefCommand();\nconst telemetryCommand = createTelemetryCommand();\nconst initCommand = createInitCommand();\nconst formatCommand = createFormatCommand();\nconst lspCommand = createLspCommand();\nprogram.addCommand(initCommand);\nprogram.addCommand(migrateCommand);\nprogram.addCommand(formatCommand);\nprogram.addCommand(lspCommand);\nprogram.addCommand(contractCommand);\nprogram.addCommand(dbCommand);\nprogram.addCommand(migrationCommand);\nprogram.addCommand(refCommand);\nprogram.addCommand(telemetryCommand);\nconst TELEMETRY_CRASH_TEST_SLEEP_MS = 200;\nif (process.env[\"PRISMA_NEXT_ENABLE_TEST_COMMANDS\"] === \"1\") {\n\tconst telemetryCrashTestCommand = new Command(\"__telemetry-crash-test\").description(\"Internal: deliberately throw for the telemetry e2e suite.\").action(async () => {\n\t\tawait new Promise((settle) => setTimeout(settle, TELEMETRY_CRASH_TEST_SLEEP_MS));\n\t\tthrow new Error(\"__telemetry-crash-test: intentional crash for e2e coverage\");\n\t});\n\ttelemetryCrashTestCommand.configureHelp({ visibleCommands: () => [] });\n\tprogram.addCommand(telemetryCrashTestCommand, { hidden: true });\n}\nconst helpCommand = new Command(\"help\").description(\"Show usage instructions\").configureHelp({ formatHelp: (cmd) => {\n\treturn formatCommandHelp({\n\t\tcommand: cmd,\n\t\tflags: parseGlobalFlags({})\n\t});\n} }).action(() => {\n\tconst flags = parseGlobalFlags({});\n\tconst helpText = formatRootHelp({\n\t\tprogram,\n\t\tflags\n\t});\n\tprocess.stdout.write(`${helpText}\\n`);\n\tprocess.exit(0);\n});\nprogram.addCommand(helpCommand);\nprogram.action(() => {\n\tconst flags = parseGlobalFlags({});\n\tconst helpText = formatRootHelp({\n\t\tprogram,\n\t\tflags\n\t});\n\tprocess.stderr.write(`${helpText}\\n`);\n\tprocess.exit(0);\n});\nconst args = process.argv.slice(2);\nif (args.length > 0) {\n\tconst commandName = args[0];\n\tif (commandName === \"--version\" || commandName === \"-V\") {\n\t\tprocess.stdout.write(`${program.version()}\\n`);\n\t\tprocess.exit(0);\n\t}\n\tif (!(commandName === \"--help\" || commandName === \"-h\")) {\n\t\tconst command = program.commands.find((cmd) => cmd.name() === commandName);\n\t\tif (!command) {\n\t\t\tconst flags = parseGlobalFlags({});\n\t\t\tconst topNames = program.commands.map((c) => c.name());\n\t\t\tprocess.stderr.write(`Unknown command: ${commandName}${formatSuggestion(commandName, topNames)}\\n`);\n\t\t\tconst helpText = formatRootHelp({\n\t\t\t\tprogram,\n\t\t\t\tflags\n\t\t\t});\n\t\t\tprocess.stderr.write(`${helpText}\\n`);\n\t\t\tprocess.exit(2);\n\t\t} else if (command.commands.length > 0 && args.length >= 2) {\n\t\t\tconst subcommandName = args[1];\n\t\t\tconst redirect = removedVerbRedirects[`${commandName}:${subcommandName}`];\n\t\t\tif (redirect) {\n\t\t\t\tprocess.stderr.write(`Unknown command: ${subcommandName}\\n${redirect}\\n`);\n\t\t\t\tprocess.exit(2);\n\t\t\t}\n\t\t\tfor (let i = 2; i < args.length; i++) {\n\t\t\t\tconst arg = args[i];\n\t\t\t\tif (!arg.startsWith(\"--\")) continue;\n\t\t\t\tconst flagRedirect = removedFlagRedirects[`${commandName}:${subcommandName}:${arg.slice(2)}`];\n\t\t\t\tif (flagRedirect) {\n\t\t\t\t\tprocess.stderr.write(`Unknown option: ${arg}\\n${flagRedirect}\\n`);\n\t\t\t\t\tprocess.exit(2);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (command.commands.length > 0 && args.length === 1) {\n\t\t\tconst helpText = formatCommandHelp({\n\t\t\t\tcommand,\n\t\t\t\tflags: parseGlobalFlags({})\n\t\t\t});\n\t\t\tprocess.stderr.write(`${helpText}\\n`);\n\t\t\tprocess.exit(0);\n\t\t}\n\t}\n}\nprogram.parse();\n//#endregion\nexport { schemaSample as a, targetLabel as c, scaffoldSpecifierResolverFor as i, targetPackageName as l, dbFile as n, starterSchema as o, defaultSchemaPath as r, targetEntrypoint as s,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aAAa,GAAG;KAChE,QAAQ,KAAK,CAAC;IACf;GACD;EACD;EACA,IAAI,QAAQ,SAAS,SAAS,KAAK,KAAK,WAAW,GAAG;GACrD,MAAM,WAAW,kBAAkB;IAClC;IACA,OAAO,iBAAiB,CAAC,CAAC;GAC3B,CAAC;GACD,QAAQ,OAAO,MAAM,GAAG,SAAS,GAAG;GACpC,QAAQ,KAAK,CAAC;EACf;CACD;AACD;AACA,QAAQ,MAAM"}
package/dist/cli.mjs CHANGED
@@ -1,5 +1,5 @@
1
- import { t as createContractEmitCommand } from "./contract-emit-0hSjbuxp-BBOKldTZ.mjs";
2
- import { t as createFormatCommand } from "./format-ByDm2goZ-DKLyhNHo.mjs";
1
+ import { t as createContractEmitCommand } from "./contract-emit-0hSjbuxp-BJLC-VgC.mjs";
2
+ import { t as createFormatCommand } from "./format-ByDm2goZ-BIRlFoo6.mjs";
3
3
  import { CliStructuredError } from "@prisma/orm-framework/errors/control";
4
4
  import { join, resolve } from "pathe";
5
5
  import { InternalError } from "@prisma/orm-framework/utils/internal-error";
@@ -1,2 +1,2 @@
1
- import { t as createContractEmitCommand } from "./contract-emit-0hSjbuxp-BBOKldTZ.mjs";
1
+ import { t as createContractEmitCommand } from "./contract-emit-0hSjbuxp-BJLC-VgC.mjs";
2
2
  export { createContractEmitCommand };
@@ -1,2 +1,2 @@
1
- import { t as createContractInferCommand } from "./contract-infer-BnkqpftN-DVM2eKJ3.mjs";
1
+ import { t as createContractInferCommand } from "./contract-infer-BnkqpftN-DwBzasOu.mjs";
2
2
  export { createContractInferCommand };
@@ -1,2 +1,2 @@
1
- import { t as createDbInitCommand } from "./db-init-Vbkb_TKZ.mjs";
1
+ import { t as createDbInitCommand } from "./db-init-bd0_x2Q8.mjs";
2
2
  export { createDbInitCommand };
@@ -1,2 +1,2 @@
1
- import { t as createDbSchemaCommand } from "./db-schema-ClQCu3xY.mjs";
1
+ import { t as createDbSchemaCommand } from "./db-schema-CwgAWTqG.mjs";
2
2
  export { createDbSchemaCommand };
@@ -1,2 +1,2 @@
1
- import { t as createDbSignCommand } from "./db-sign-jjXDgQ1u.mjs";
1
+ import { t as createDbSignCommand } from "./db-sign-vqiYfpjI.mjs";
2
2
  export { createDbSignCommand };
@@ -1,2 +1,2 @@
1
- import { t as createDbUpdateCommand } from "./db-update-BQlrqtDD.mjs";
1
+ import { t as createDbUpdateCommand } from "./db-update-Br0diOCo.mjs";
2
2
  export { createDbUpdateCommand };
@@ -1,2 +1,2 @@
1
- import { t as createDbVerifyCommand } from "./db-verify-CKPsRFrj-3udprZQD.mjs";
1
+ import { t as createDbVerifyCommand } from "./db-verify-CKPsRFrj-T7nSt7yT.mjs";
2
2
  export { createDbVerifyCommand };
@@ -1,2 +1,2 @@
1
- import { t as createMigrateCommand } from "./migrate-Cb_iv264.mjs";
1
+ import { t as createMigrateCommand } from "./migrate-BdVFDKF2.mjs";
2
2
  export { createMigrateCommand };
@@ -1,7 +1,7 @@
1
1
  import { i as Refs } from "./refs-BNCUu58Y-BIso5Jfg.mjs";
2
2
  import { n as MigrationGraph } from "./graph-bDjJ4GL9-BhFevsJS.mjs";
3
3
  import { t as CliStructuredError$1 } from "./types-DZWEs4si-D8UlyJI0.mjs";
4
- import { f as migrationCheckResultSchema, n as MigrationCheckResult, t as CheckFailure } from "./schemas-CfGSxH5b-BSjB3nZS.mjs";
4
+ import { f as migrationCheckResultSchema, n as MigrationCheckResult, t as CheckFailure } from "./schemas-CeGMYFYX-h3OcU__O.mjs";
5
5
  import { n as OnDiskMigrationPackage } from "./package-CfWiDNrr-ZR4HM_Iz.mjs";
6
6
  import { c as ContractSpaceAggregate } from "./aggregate-BflrjWPO.mjs";
7
7
  import "./package-N9PPdFV_.mjs";
@@ -1,3 +1,3 @@
1
1
  import { t as migrationCheckResultSchema } from "./schemas-KhXMzNA_-CzZ7GFX_.mjs";
2
- import { n as enumerateCheckSpaces, r as runMigrationCheck, t as createMigrationCheckCommand } from "./migration-check-DcwUnadt-B6Qoh0ot.mjs";
2
+ import { n as enumerateCheckSpaces, r as runMigrationCheck, t as createMigrationCheckCommand } from "./migration-check-DcwUnadt-jamDqOmM.mjs";
3
3
  export { createMigrationCheckCommand, enumerateCheckSpaces, migrationCheckResultSchema, runMigrationCheck };
@@ -1,6 +1,6 @@
1
1
  import { n as MigrationGraph } from "./graph-bDjJ4GL9-BhFevsJS.mjs";
2
2
  import { t as CliStructuredError$1 } from "./types-DZWEs4si-D8UlyJI0.mjs";
3
- import { o as MigrationSpaceGraphEntry } from "./schemas-CfGSxH5b-BSjB3nZS.mjs";
3
+ import { o as MigrationSpaceGraphEntry } from "./schemas-CeGMYFYX-h3OcU__O.mjs";
4
4
  import { n as GlobalFlags, t as CommonCommandOptions } from "./global-flags-BpoOYtNZ-CHZD3fud.mjs";
5
5
  import { n as TerminalUI } from "./terminal-ui-BN4QOsm5-Bf3pim46.mjs";
6
6
  import { Result } from "@prisma/orm-framework/utils/result";
@@ -1,2 +1,2 @@
1
- import { n as executeMigrationGraphCommand, r as formatMigrationGraphHumanOutput, t as createMigrationGraphCommand } from "./migration-graph-DkoCC0Qy.mjs";
1
+ import { n as executeMigrationGraphCommand, r as formatMigrationGraphHumanOutput, t as createMigrationGraphCommand } from "./migration-graph-vmgkL3k4.mjs";
2
2
  export { createMigrationGraphCommand, executeMigrationGraphCommand, formatMigrationGraphHumanOutput };
@@ -1,6 +1,6 @@
1
1
  import { n as MigrationGraph } from "./graph-bDjJ4GL9-BhFevsJS.mjs";
2
2
  import { t as CliStructuredError$1 } from "./types-DZWEs4si-D8UlyJI0.mjs";
3
- import { r as MigrationListResult, s as MigrationSpaceListEntry } from "./schemas-CfGSxH5b-BSjB3nZS.mjs";
3
+ import { r as MigrationListResult, s as MigrationSpaceListEntry } from "./schemas-CeGMYFYX-h3OcU__O.mjs";
4
4
  import { c as ContractSpaceAggregate, t as AggregateContractSpace } from "./aggregate-BflrjWPO.mjs";
5
5
  import { n as GlobalFlags, t as CommonCommandOptions } from "./global-flags-BpoOYtNZ-CHZD3fud.mjs";
6
6
  import { n as TerminalUI, t as GlyphMode } from "./terminal-ui-BN4QOsm5-Bf3pim46.mjs";
@@ -1,2 +1,2 @@
1
- import { a as renderMigrationListHumanOutput, i as migrationSpaceListEntriesFromAggregate, n as executeMigrationListCommand, o as runMigrationList, r as listRefsByContractHash, t as createMigrationListCommand } from "./migration-list-BFBeo1_X-c0kqYokL.mjs";
1
+ import { a as renderMigrationListHumanOutput, i as migrationSpaceListEntriesFromAggregate, n as executeMigrationListCommand, o as runMigrationList, r as listRefsByContractHash, t as createMigrationListCommand } from "./migration-list-BFBeo1_X-ckYMhETH.mjs";
2
2
  export { createMigrationListCommand, executeMigrationListCommand, listRefsByContractHash, migrationSpaceListEntriesFromAggregate, renderMigrationListHumanOutput, runMigrationList };
@@ -1,5 +1,5 @@
1
1
  import { t as CliStructuredError$1 } from "./types-DZWEs4si-D8UlyJI0.mjs";
2
- import { i as MigrationLogResult } from "./schemas-CfGSxH5b-BSjB3nZS.mjs";
2
+ import { i as MigrationLogResult } from "./schemas-CeGMYFYX-h3OcU__O.mjs";
3
3
  import { n as GlobalFlags, t as CommonCommandOptions } from "./global-flags-BpoOYtNZ-CHZD3fud.mjs";
4
4
  import { n as TerminalUI } from "./terminal-ui-BN4QOsm5-Bf3pim46.mjs";
5
5
  import { Result } from "@prisma/orm-framework/utils/result";
@@ -1,2 +1,2 @@
1
- import { n as executeMigrationLogCommand, t as createMigrationLogCommand } from "./migration-log-CS5IWcNq-BQ-32Low.mjs";
1
+ import { n as executeMigrationLogCommand, t as createMigrationLogCommand } from "./migration-log-CS5IWcNq-DI7FTHCA.mjs";
2
2
  export { createMigrationLogCommand, executeMigrationLogCommand };
@@ -1,2 +1,2 @@
1
- import { t as createMigrationNewCommand } from "./migration-new-BurCjyaQ.mjs";
1
+ import { t as createMigrationNewCommand } from "./migration-new-GmW2anVb.mjs";
2
2
  export { createMigrationNewCommand };
@@ -1,2 +1,2 @@
1
- import { n as formatMigrationPlanOutput, r as resolveBundleByPrefix, t as createMigrationPlanCommand } from "./migration-plan-q_L84PN1-BWE0LTH6.mjs";
1
+ import { n as formatMigrationPlanOutput, r as resolveBundleByPrefix, t as createMigrationPlanCommand } from "./migration-plan-q_L84PN1-ClkGgtVz.mjs";
2
2
  export { createMigrationPlanCommand, formatMigrationPlanOutput, resolveBundleByPrefix };
@@ -1,4 +1,4 @@
1
- import { a as MigrationShowResult } from "./schemas-CfGSxH5b-BSjB3nZS.mjs";
1
+ import { a as MigrationShowResult } from "./schemas-CeGMYFYX-h3OcU__O.mjs";
2
2
  import { Command } from "commander";
3
3
  //#region ../../../1-framework/3-tooling/cli/dist/commands/migration-show.d.mts
4
4
  //#region src/commands/migration-show.d.ts
@@ -1,2 +1,2 @@
1
- import { t as createMigrationShowCommand } from "./migration-show-Bx5I5aW9.mjs";
1
+ import { t as createMigrationShowCommand } from "./migration-show--pW4XhKs.mjs";
2
2
  export { createMigrationShowCommand };
@@ -1,5 +1,5 @@
1
1
  import { t as CliStructuredError$1 } from "./types-DZWEs4si-D8UlyJI0.mjs";
2
- import { c as MigrationStatusEntry, d as StatusDiagnosticJson, l as MigrationStatusResult, p as migrationStatusJsonResultSchema, u as MigrationStatusSpace } from "./schemas-CfGSxH5b-BSjB3nZS.mjs";
2
+ import { c as MigrationStatusEntry, d as StatusDiagnosticJson, l as MigrationStatusResult, p as migrationStatusJsonResultSchema, u as MigrationStatusSpace } from "./schemas-CeGMYFYX-h3OcU__O.mjs";
3
3
  import { n as GlobalFlags, t as CommonCommandOptions } from "./global-flags-BpoOYtNZ-CHZD3fud.mjs";
4
4
  import { n as TerminalUI } from "./terminal-ui-BN4QOsm5-Bf3pim46.mjs";
5
5
  import { Result } from "@prisma/orm-framework/utils/result";
@@ -1,3 +1,3 @@
1
1
  import { n as migrationStatusJsonResultSchema } from "./schemas-KhXMzNA_-CzZ7GFX_.mjs";
2
- import { a as formatStatusHumanOutput, i as executeMigrationStatusCommand, n as buildStatusHeadline, o as formatStatusSummary, r as createMigrationStatusCommand, t as buildNoPathSummary } from "./migration-status-CE7cQLDq-B1jDVmqG.mjs";
2
+ import { a as formatStatusHumanOutput, i as executeMigrationStatusCommand, n as buildStatusHeadline, o as formatStatusSummary, r as createMigrationStatusCommand, t as buildNoPathSummary } from "./migration-status-CE7cQLDq-P1x1-BsZ.mjs";
3
3
  export { buildNoPathSummary, buildStatusHeadline, createMigrationStatusCommand, executeMigrationStatusCommand, formatStatusHumanOutput, formatStatusSummary, migrationStatusJsonResultSchema };
@@ -1,2 +1,2 @@
1
- import { i as executeRefSetCommand, n as executeRefDeleteCommand, r as executeRefListCommand, t as createRefCommand } from "./ref-B6cTthTi.mjs";
1
+ import { i as executeRefSetCommand, n as executeRefDeleteCommand, r as executeRefListCommand, t as createRefCommand } from "./ref-sHE8zOcm.mjs";
2
2
  export { createRefCommand, executeRefDeleteCommand, executeRefListCommand, executeRefSetCommand };
@@ -1,4 +1,4 @@
1
- import { n as disposeEmitQueue, r as executeContractEmit } from "./contract-emit-B6odMoem-CK3diBPk.mjs";
1
+ import { n as disposeEmitQueue, r as executeContractEmit } from "./contract-emit-B6odMoem-C87PBvmo.mjs";
2
2
  import { t as enrichContract } from "./contract-enrichment-DrMvvY2A-DxNGeF4d.mjs";
3
- import { i as executeDbVerify, n as executeDbInit, r as executeDbUpdate, t as createControlClient } from "./client-75qrAPqf-DZAVUxFa.mjs";
3
+ import { i as executeDbVerify, n as executeDbInit, r as executeDbUpdate, t as createControlClient } from "./client-75qrAPqf-7l0C0H_b.mjs";
4
4
  export { createControlClient, disposeEmitQueue, enrichContract, executeContractEmit, executeDbInit, executeDbUpdate, executeDbVerify };
@@ -1,5 +1,5 @@
1
1
  import { g as errorInvalidJson, t as MigrationToolsError } from "./errors-IpZm1Skp-BH495dRd.mjs";
2
- import { r as loadConfig } from "./exports-Dl2aGAk7.mjs";
2
+ import { r as loadConfig } from "./exports-CDX9kZuw.mjs";
3
3
  import { r as buildMigrationArtifacts } from "./migration-BuUmO7It.mjs";
4
4
  import { CliStructuredError, errorMigrationCliInvalidConfigArg, errorMigrationCliUnknownFlag } from "@prisma/orm-framework/errors/control";
5
5
  import { dirname, join } from "pathe";
@@ -4,7 +4,7 @@ import { o as findPathWithDecision } from "./migration-graph-CBf9ORe7-B4xAF8GN.m
4
4
  import { t as CliStructuredError$1 } from "./command-helpers-CAoXqAY9-DWUBcTXM.mjs";
5
5
  import { t as assertFrameworkComponentsCompatible } from "./framework-components-CjshQKHA-Dlp6Leo5.mjs";
6
6
  import { t as enrichContract } from "./contract-enrichment-DrMvvY2A-DxNGeF4d.mjs";
7
- import { t as emit } from "./exports-D3-NwrMA-CadaBGQ3.mjs";
7
+ import { t as emit } from "./exports-BCLg4CiV-okAfZydo.mjs";
8
8
  import { d as resolveRecordedPath, f as verifyMigration, l as planMigration, n as buildFabricatedMigrationEdge, r as collectAggregateNamespaces, t as allStorageElementsExternal, u as requireHeadRef } from "./aggregate-B4mhR4Sk.mjs";
9
9
  import { t as buildContractSpaceAggregate } from "./contract-space-aggregate-loader-CFH-336b-BhAyRQEL.mjs";
10
10
  import { CliStructuredError } from "@prisma/orm-framework/errors/control";
@@ -1603,4 +1603,4 @@ var ControlClientImpl = class {
1603
1603
  //#endregion
1604
1604
  export { planSpacePath as a, executeDbVerify as i, executeDbInit as n, executeDbUpdate as r, createControlClient as t };
1605
1605
 
1606
- //# sourceMappingURL=client-75qrAPqf-DZAVUxFa.mjs.map
1606
+ //# sourceMappingURL=client-75qrAPqf-7l0C0H_b.mjs.map