@prisma/migrate 6.19.0-integration-release-tags.4 → 6.19.0-integration-next.20

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 (52) hide show
  1. package/dist/Migrate.js +3 -3
  2. package/dist/bin.js +27 -28
  3. package/dist/{chunk-TW22Y3AA.js → chunk-5VRSNV7F.js} +6 -7
  4. package/dist/{chunk-OP2BDF75.js → chunk-FRY7T46S.js} +10 -11
  5. package/dist/{chunk-ZTIS675B.js → chunk-FWKRNLVM.js} +68 -82
  6. package/dist/{chunk-Z27SI4AV.js → chunk-GY34KW2I.js} +6 -4
  7. package/dist/{chunk-VV4M6AN7.js → chunk-JX2HIV7V.js} +10 -10
  8. package/dist/{chunk-3AKRTEIK.js → chunk-KWS3KTC2.js} +10 -11
  9. package/dist/{chunk-PHXLQVPT.js → chunk-L7EZFBB4.js} +40 -68
  10. package/dist/{chunk-NB4FRYRQ.js → chunk-LNQIFWXN.js} +5 -5
  11. package/dist/{chunk-O35BTK6Y.js → chunk-PYQR4PVV.js} +9 -13
  12. package/dist/{chunk-6ORQRJLP.js → chunk-QXGJ64OM.js} +18 -53
  13. package/dist/{chunk-R4IWP35Z.js → chunk-SJKDB5VT.js} +8 -9
  14. package/dist/{chunk-F2XCBEZ4.js → chunk-SWKWTYSR.js} +10 -13
  15. package/dist/{chunk-VU5BLQUI.js → chunk-T2ACIU5M.js} +14 -8
  16. package/dist/{chunk-7TVX3D4W.js → chunk-TCBZUTEL.js} +27 -65
  17. package/dist/{chunk-BHJMJSM4.js → chunk-UBJBWA5R.js} +6 -7
  18. package/dist/{chunk-D6LYHB65.js → chunk-V5D5NSLS.js} +33 -25
  19. package/dist/{chunk-D4TRX77Y.js → chunk-WF7UXKO5.js} +6 -9
  20. package/dist/{chunk-QVMYNWAN.js → chunk-XA2JOJS2.js} +157 -70
  21. package/dist/{chunk-J33EXHZB.js → chunk-Y66LIIF7.js} +9 -12
  22. package/dist/commands/DbDrop.js +2 -2
  23. package/dist/commands/DbExecute.js +4 -4
  24. package/dist/commands/DbPull.js +5 -6
  25. package/dist/commands/DbPush.js +4 -4
  26. package/dist/commands/DbSeed.js +3 -3
  27. package/dist/commands/MigrateDeploy.js +4 -4
  28. package/dist/commands/MigrateDev.js +5 -5
  29. package/dist/commands/MigrateDiff.js +4 -4
  30. package/dist/commands/MigrateReset.js +5 -5
  31. package/dist/commands/MigrateResolve.js +4 -4
  32. package/dist/commands/MigrateStatus.js +4 -4
  33. package/dist/index.js +31 -32
  34. package/dist/internals/src/cli/getSchema.d.ts +1 -15
  35. package/dist/migrate/src/Migrate.d.ts +1 -2
  36. package/dist/migrate/src/utils/introspectSql.d.ts +2 -1
  37. package/dist/migrate/src/utils/seed.d.ts +0 -6
  38. package/dist/open-GFNXULGD.js +593 -0
  39. package/dist/utils/getDatabaseVersionSafe.js +4 -4
  40. package/dist/utils/introspectSql.js +4 -4
  41. package/dist/utils/seed.js +2 -3
  42. package/dist/utils/setupCockroach.js +2 -2
  43. package/dist/utils/setupMSSQL.js +30734 -30124
  44. package/dist/utils/setupMongo.js +2048 -768
  45. package/dist/utils/setupPostgres.js +2 -2
  46. package/dist/utils/spinner.js +3 -3
  47. package/package.json +11 -11
  48. package/dist/chunk-RR6BKMNO.js +0 -80
  49. package/dist/migrate/src/utils/replaceOrAddDatasource.d.ts +0 -2
  50. package/dist/migrate/src/utils/replaceOrAddDatasource.test.d.ts +0 -1
  51. package/dist/utils/replaceOrAddDatasource.js +0 -25
  52. package/dist/utils/replaceOrAddDatasource.test.js +0 -207
package/dist/Migrate.js CHANGED
@@ -18,12 +18,12 @@ var __copyProps = (to, from, except, desc) => {
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
19
  var Migrate_exports = {};
20
20
  __export(Migrate_exports, {
21
- Migrate: () => import_chunk_D6LYHB65.Migrate
21
+ Migrate: () => import_chunk_V5D5NSLS.Migrate
22
22
  });
23
23
  module.exports = __toCommonJS(Migrate_exports);
24
- var import_chunk_D6LYHB65 = require("./chunk-D6LYHB65.js");
24
+ var import_chunk_V5D5NSLS = require("./chunk-V5D5NSLS.js");
25
+ var import_chunk_JX2HIV7V = require("./chunk-JX2HIV7V.js");
25
26
  var import_chunk_T64SUJ5L = require("./chunk-T64SUJ5L.js");
26
- var import_chunk_VV4M6AN7 = require("./chunk-VV4M6AN7.js");
27
27
  var import_chunk_GGA2F64G = require("./chunk-GGA2F64G.js");
28
28
  var import_chunk_23DZXSTI = require("./chunk-23DZXSTI.js");
29
29
  var import_chunk_3WDCTXHL = require("./chunk-3WDCTXHL.js");
package/dist/bin.js CHANGED
@@ -23,42 +23,41 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
23
23
  mod
24
24
  ));
25
25
  var import_chunk_NGQA5JTN = require("./chunk-NGQA5JTN.js");
26
- var import_chunk_NB4FRYRQ = require("./chunk-NB4FRYRQ.js");
27
- var import_chunk_BHJMJSM4 = require("./chunk-BHJMJSM4.js");
28
- var import_chunk_F2XCBEZ4 = require("./chunk-F2XCBEZ4.js");
26
+ var import_chunk_LNQIFWXN = require("./chunk-LNQIFWXN.js");
27
+ var import_chunk_UBJBWA5R = require("./chunk-UBJBWA5R.js");
28
+ var import_chunk_SWKWTYSR = require("./chunk-SWKWTYSR.js");
29
29
  var import_chunk_C3722PDA = require("./chunk-C3722PDA.js");
30
30
  var import_chunk_7CQBDP4H = require("./chunk-7CQBDP4H.js");
31
- var import_chunk_ZTIS675B = require("./chunk-ZTIS675B.js");
31
+ var import_chunk_FWKRNLVM = require("./chunk-FWKRNLVM.js");
32
32
  var import_chunk_VAJ4VX67 = require("./chunk-VAJ4VX67.js");
33
- var import_chunk_J33EXHZB = require("./chunk-J33EXHZB.js");
33
+ var import_chunk_Y66LIIF7 = require("./chunk-Y66LIIF7.js");
34
34
  var import_chunk_KRQEFTDT = require("./chunk-KRQEFTDT.js");
35
35
  var import_chunk_UP6FVCDK = require("./chunk-UP6FVCDK.js");
36
- var import_chunk_3AKRTEIK = require("./chunk-3AKRTEIK.js");
37
- var import_chunk_R4IWP35Z = require("./chunk-R4IWP35Z.js");
36
+ var import_chunk_KWS3KTC2 = require("./chunk-KWS3KTC2.js");
37
+ var import_chunk_SJKDB5VT = require("./chunk-SJKDB5VT.js");
38
38
  var import_chunk_EJG7GKM7 = require("./chunk-EJG7GKM7.js");
39
- var import_chunk_7TVX3D4W = require("./chunk-7TVX3D4W.js");
40
- var import_chunk_6ORQRJLP = require("./chunk-6ORQRJLP.js");
41
- var import_chunk_VU5BLQUI = require("./chunk-VU5BLQUI.js");
39
+ var import_chunk_TCBZUTEL = require("./chunk-TCBZUTEL.js");
40
+ var import_chunk_QXGJ64OM = require("./chunk-QXGJ64OM.js");
41
+ var import_chunk_T2ACIU5M = require("./chunk-T2ACIU5M.js");
42
42
  var import_chunk_AHJ2N6BJ = require("./chunk-AHJ2N6BJ.js");
43
43
  var import_chunk_JZ75RIMZ = require("./chunk-JZ75RIMZ.js");
44
- var import_chunk_RR6BKMNO = require("./chunk-RR6BKMNO.js");
45
44
  var import_chunk_RTGQXNX6 = require("./chunk-RTGQXNX6.js");
46
45
  var import_chunk_JFKDSUIE = require("./chunk-JFKDSUIE.js");
47
46
  var import_chunk_AI6DH66U = require("./chunk-AI6DH66U.js");
48
47
  var import_chunk_LGYRZ6CV = require("./chunk-LGYRZ6CV.js");
49
48
  var import_chunk_2R6DII47 = require("./chunk-2R6DII47.js");
50
- var import_chunk_TW22Y3AA = require("./chunk-TW22Y3AA.js");
49
+ var import_chunk_5VRSNV7F = require("./chunk-5VRSNV7F.js");
51
50
  var import_chunk_FBDQVK4W = require("./chunk-FBDQVK4W.js");
52
51
  var import_chunk_3WC4XD74 = require("./chunk-3WC4XD74.js");
53
52
  var import_chunk_2FXU5NZQ = require("./chunk-2FXU5NZQ.js");
54
53
  var import_chunk_74LUB4XX = require("./chunk-74LUB4XX.js");
55
54
  var import_chunk_TWPTG4XS = require("./chunk-TWPTG4XS.js");
56
- var import_chunk_D4TRX77Y = require("./chunk-D4TRX77Y.js");
57
- var import_chunk_PHXLQVPT = require("./chunk-PHXLQVPT.js");
55
+ var import_chunk_WF7UXKO5 = require("./chunk-WF7UXKO5.js");
56
+ var import_chunk_L7EZFBB4 = require("./chunk-L7EZFBB4.js");
58
57
  var import_chunk_LLO7YF56 = require("./chunk-LLO7YF56.js");
59
- var import_chunk_D6LYHB65 = require("./chunk-D6LYHB65.js");
58
+ var import_chunk_V5D5NSLS = require("./chunk-V5D5NSLS.js");
59
+ var import_chunk_JX2HIV7V = require("./chunk-JX2HIV7V.js");
60
60
  var import_chunk_T64SUJ5L = require("./chunk-T64SUJ5L.js");
61
- var import_chunk_VV4M6AN7 = require("./chunk-VV4M6AN7.js");
62
61
  var import_chunk_GGA2F64G = require("./chunk-GGA2F64G.js");
63
62
  var import_chunk_23DZXSTI = require("./chunk-23DZXSTI.js");
64
63
  var import_chunk_3WDCTXHL = require("./chunk-3WDCTXHL.js");
@@ -72,7 +71,7 @@ var import_config = require("@prisma/config");
72
71
  var import_debug = __toESM(require("@prisma/debug"));
73
72
  var import_engines_version = require("@prisma/engines-version");
74
73
  var import_internals = require("@prisma/internals");
75
- var version = "6.19.0-integration-release-tags.4";
74
+ var version = "6.19.0-integration-next.20";
76
75
  process.on("uncaughtException", (e) => {
77
76
  console.log(e);
78
77
  });
@@ -94,19 +93,19 @@ var args = (0, import_internals.arg)(
94
93
  async function main() {
95
94
  const cli = import_chunk_NGQA5JTN.CLI.new({
96
95
  migrate: import_chunk_LLO7YF56.MigrateCommand.new({
97
- dev: import_chunk_F2XCBEZ4.MigrateDev.new(),
98
- status: import_chunk_R4IWP35Z.MigrateStatus.new(),
99
- resolve: import_chunk_3AKRTEIK.MigrateResolve.new(),
100
- reset: import_chunk_J33EXHZB.MigrateReset.new(),
101
- deploy: import_chunk_BHJMJSM4.MigrateDeploy.new(),
102
- diff: import_chunk_ZTIS675B.MigrateDiff.new()
96
+ dev: import_chunk_SWKWTYSR.MigrateDev.new(),
97
+ status: import_chunk_SJKDB5VT.MigrateStatus.new(),
98
+ resolve: import_chunk_KWS3KTC2.MigrateResolve.new(),
99
+ reset: import_chunk_Y66LIIF7.MigrateReset.new(),
100
+ deploy: import_chunk_UBJBWA5R.MigrateDeploy.new(),
101
+ diff: import_chunk_FWKRNLVM.MigrateDiff.new()
103
102
  }),
104
103
  db: import_chunk_EJG7GKM7.DbCommand.new({
105
- execute: import_chunk_7TVX3D4W.DbExecute.new(),
106
- pull: import_chunk_6ORQRJLP.DbPull.new(),
107
- push: import_chunk_TW22Y3AA.DbPush.new(),
104
+ execute: import_chunk_TCBZUTEL.DbExecute.new(),
105
+ pull: import_chunk_QXGJ64OM.DbPull.new(),
106
+ push: import_chunk_5VRSNV7F.DbPush.new(),
108
107
  // drop: DbDrop.new(),
109
- seed: import_chunk_D4TRX77Y.DbSeed.new()
108
+ seed: import_chunk_WF7UXKO5.DbSeed.new()
110
109
  })
111
110
  });
112
111
  const { config, error } = await (0, import_config.loadConfigFromFile)({ configFile: args["--config"] });
@@ -136,7 +135,7 @@ main().then((code) => {
136
135
  cliVersion: version,
137
136
  enginesVersion: import_engines_version.enginesVersion,
138
137
  command: commandArray.join(" "),
139
- getDatabaseVersionSafe: import_chunk_NB4FRYRQ.getDatabaseVersionSafe
138
+ getDatabaseVersionSafe: import_chunk_LNQIFWXN.getDatabaseVersionSafe
140
139
  }).catch((e) => {
141
140
  if (import_debug.default.enabled("migrate")) {
142
141
  console.error((0, import_chunk_SKRR5WT4.red)((0, import_chunk_SKRR5WT4.bold)("Error: ")) + e.stack);
@@ -26,16 +26,16 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_TW22Y3AA_exports = {};
30
- __export(chunk_TW22Y3AA_exports, {
29
+ var chunk_5VRSNV7F_exports = {};
30
+ __export(chunk_5VRSNV7F_exports, {
31
31
  DbPush: () => DbPush
32
32
  });
33
- module.exports = __toCommonJS(chunk_TW22Y3AA_exports);
33
+ module.exports = __toCommonJS(chunk_5VRSNV7F_exports);
34
34
  var import_chunk_FBDQVK4W = require("./chunk-FBDQVK4W.js");
35
35
  var import_chunk_3WC4XD74 = require("./chunk-3WC4XD74.js");
36
36
  var import_chunk_2FXU5NZQ = require("./chunk-2FXU5NZQ.js");
37
37
  var import_chunk_74LUB4XX = require("./chunk-74LUB4XX.js");
38
- var import_chunk_D6LYHB65 = require("./chunk-D6LYHB65.js");
38
+ var import_chunk_V5D5NSLS = require("./chunk-V5D5NSLS.js");
39
39
  var import_chunk_SKRR5WT4 = require("./chunk-SKRR5WT4.js");
40
40
  var import_internals = require("@prisma/internals");
41
41
  var import_prompts = __toESM(require("prompts"));
@@ -91,7 +91,6 @@ ${(0, import_chunk_SKRR5WT4.bold)("Examples")}
91
91
  if (args["--help"]) {
92
92
  return this.help();
93
93
  }
94
- await (0, import_internals.loadEnvFile)({ schemaPath: args["--schema"], printMessage: true, config });
95
94
  const schemaContext = await (0, import_internals.loadSchemaContext)({
96
95
  schemaPathFromArg: args["--schema"],
97
96
  schemaPathFromConfig: config.schema,
@@ -106,7 +105,7 @@ ${(0, import_chunk_SKRR5WT4.bold)("Examples")}
106
105
  externalTables: config.tables?.external ?? [],
107
106
  externalEnums: config.enums?.external ?? []
108
107
  };
109
- const migrate = await import_chunk_D6LYHB65.Migrate.setup({
108
+ const migrate = await import_chunk_V5D5NSLS.Migrate.setup({
110
109
  schemaEngineConfig: config,
111
110
  migrationsDirPath,
112
111
  schemaContext,
@@ -233,7 +232,7 @@ ${rocketEmoji}${provider === "mongodb" ? migrationSuccessMongoMessage : migratio
233
232
  );
234
233
  }
235
234
  if (!process.env.PRISMA_MIGRATE_SKIP_GENERATE && !args["--skip-generate"]) {
236
- await migrate.tryToRunGenerate(datasourceInfo);
235
+ await migrate.tryToRunGenerate();
237
236
  }
238
237
  return ``;
239
238
  }
@@ -16,13 +16,12 @@ var __copyProps = (to, from, except, desc) => {
16
16
  return to;
17
17
  };
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var chunk_OP2BDF75_exports = {};
20
- __export(chunk_OP2BDF75_exports, {
19
+ var chunk_FRY7T46S_exports = {};
20
+ __export(chunk_FRY7T46S_exports, {
21
21
  require_ms: () => require_ms,
22
- require_src: () => require_src,
23
- require_supports_color: () => require_supports_color
22
+ require_src: () => require_src
24
23
  });
25
- module.exports = __toCommonJS(chunk_OP2BDF75_exports);
24
+ module.exports = __toCommonJS(chunk_FRY7T46S_exports);
26
25
  var import_chunk_2ESYSVXG = require("./chunk-2ESYSVXG.js");
27
26
  var require_ms = (0, import_chunk_2ESYSVXG.__commonJS)({
28
27
  "../../node_modules/.pnpm/ms@2.1.3/node_modules/ms/index.js"(exports, module2) {
@@ -140,7 +139,7 @@ var require_ms = (0, import_chunk_2ESYSVXG.__commonJS)({
140
139
  }
141
140
  });
142
141
  var require_common = (0, import_chunk_2ESYSVXG.__commonJS)({
143
- "../../node_modules/.pnpm/debug@4.4.0/node_modules/debug/src/common.js"(exports, module2) {
142
+ "../../node_modules/.pnpm/debug@4.4.3/node_modules/debug/src/common.js"(exports, module2) {
144
143
  "use strict";
145
144
  function setup(env) {
146
145
  createDebug.debug = createDebug;
@@ -242,7 +241,7 @@ var require_common = (0, import_chunk_2ESYSVXG.__commonJS)({
242
241
  createDebug.namespaces = namespaces;
243
242
  createDebug.names = [];
244
243
  createDebug.skips = [];
245
- const split = (typeof namespaces === "string" ? namespaces : "").trim().replace(" ", ",").split(",").filter(Boolean);
244
+ const split = (typeof namespaces === "string" ? namespaces : "").trim().replace(/\s+/g, ",").split(",").filter(Boolean);
246
245
  for (const ns of split) {
247
246
  if (ns[0] === "-") {
248
247
  createDebug.skips.push(ns.slice(1));
@@ -316,7 +315,7 @@ var require_common = (0, import_chunk_2ESYSVXG.__commonJS)({
316
315
  }
317
316
  });
318
317
  var require_browser = (0, import_chunk_2ESYSVXG.__commonJS)({
319
- "../../node_modules/.pnpm/debug@4.4.0/node_modules/debug/src/browser.js"(exports, module2) {
318
+ "../../node_modules/.pnpm/debug@4.4.3/node_modules/debug/src/browser.js"(exports, module2) {
320
319
  "use strict";
321
320
  exports.formatArgs = formatArgs;
322
321
  exports.save = save;
@@ -459,7 +458,7 @@ var require_browser = (0, import_chunk_2ESYSVXG.__commonJS)({
459
458
  function load() {
460
459
  let r;
461
460
  try {
462
- r = exports.storage.getItem("debug");
461
+ r = exports.storage.getItem("debug") || exports.storage.getItem("DEBUG");
463
462
  } catch (error) {
464
463
  }
465
464
  if (!r && typeof process !== "undefined" && "env" in process) {
@@ -608,7 +607,7 @@ var require_supports_color = (0, import_chunk_2ESYSVXG.__commonJS)({
608
607
  }
609
608
  });
610
609
  var require_node = (0, import_chunk_2ESYSVXG.__commonJS)({
611
- "../../node_modules/.pnpm/debug@4.4.0/node_modules/debug/src/node.js"(exports, module2) {
610
+ "../../node_modules/.pnpm/debug@4.4.3/node_modules/debug/src/node.js"(exports, module2) {
612
611
  "use strict";
613
612
  var tty = (0, import_chunk_2ESYSVXG.__require)("tty");
614
613
  var util = (0, import_chunk_2ESYSVXG.__require)("util");
@@ -781,7 +780,7 @@ var require_node = (0, import_chunk_2ESYSVXG.__commonJS)({
781
780
  }
782
781
  });
783
782
  var require_src = (0, import_chunk_2ESYSVXG.__commonJS)({
784
- "../../node_modules/.pnpm/debug@4.4.0/node_modules/debug/src/index.js"(exports, module2) {
783
+ "../../node_modules/.pnpm/debug@4.4.3/node_modules/debug/src/index.js"(exports, module2) {
785
784
  "use strict";
786
785
  if (typeof process === "undefined" || process.type === "renderer" || process.browser === true || process.__nwjs) {
787
786
  module2.exports = require_browser();
@@ -26,20 +26,19 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_ZTIS675B_exports = {};
30
- __export(chunk_ZTIS675B_exports, {
29
+ var chunk_FWKRNLVM_exports = {};
30
+ __export(chunk_FWKRNLVM_exports, {
31
31
  MigrateDiff: () => MigrateDiff
32
32
  });
33
- module.exports = __toCommonJS(chunk_ZTIS675B_exports);
33
+ module.exports = __toCommonJS(chunk_FWKRNLVM_exports);
34
34
  var import_chunk_VAJ4VX67 = require("./chunk-VAJ4VX67.js");
35
- var import_chunk_D6LYHB65 = require("./chunk-D6LYHB65.js");
35
+ var import_chunk_V5D5NSLS = require("./chunk-V5D5NSLS.js");
36
36
  var import_chunk_GGA2F64G = require("./chunk-GGA2F64G.js");
37
37
  var import_chunk_SKRR5WT4 = require("./chunk-SKRR5WT4.js");
38
38
  var import_chunk_2ESYSVXG = require("./chunk-2ESYSVXG.js");
39
39
  var import_debug = __toESM(require("@prisma/debug"));
40
40
  var import_internals = require("@prisma/internals");
41
41
  var import_path = __toESM(require("path"));
42
- var import_config = require("@prisma/config");
43
42
  var import_debug2 = require("@prisma/debug");
44
43
  var import_fs = __toESM(require("fs"));
45
44
  var import_path2 = __toESM(require("path"));
@@ -1117,7 +1116,7 @@ var require_tree_walker = (0, import_chunk_2ESYSVXG.__commonJS)({
1117
1116
  }
1118
1117
  });
1119
1118
  var require_path = (0, import_chunk_2ESYSVXG.__commonJS)({
1120
- "../../node_modules/.pnpm/minimatch@5.1.0/node_modules/minimatch/lib/path.js"(exports, module2) {
1119
+ "../../node_modules/.pnpm/minimatch@5.1.6/node_modules/minimatch/lib/path.js"(exports, module2) {
1121
1120
  "use strict";
1122
1121
  var isWindows = typeof process === "object" && process && process.platform === "win32";
1123
1122
  module2.exports = isWindows ? { sep: "\\" } : { sep: "/" };
@@ -1180,7 +1179,7 @@ var require_balanced_match = (0, import_chunk_2ESYSVXG.__commonJS)({
1180
1179
  }
1181
1180
  });
1182
1181
  var require_brace_expansion = (0, import_chunk_2ESYSVXG.__commonJS)({
1183
- "../../node_modules/.pnpm/brace-expansion@2.0.1/node_modules/brace-expansion/index.js"(exports, module2) {
1182
+ "../../node_modules/.pnpm/brace-expansion@2.0.2/node_modules/brace-expansion/index.js"(exports, module2) {
1184
1183
  "use strict";
1185
1184
  var balanced = require_balanced_match();
1186
1185
  module2.exports = expandTop;
@@ -1255,7 +1254,7 @@ var require_brace_expansion = (0, import_chunk_2ESYSVXG.__commonJS)({
1255
1254
  var isSequence = isNumericSequence || isAlphaSequence;
1256
1255
  var isOptions = m.body.indexOf(",") >= 0;
1257
1256
  if (!isSequence && !isOptions) {
1258
- if (m.post.match(/,.*\}/)) {
1257
+ if (m.post.match(/,(?!,).*\}/)) {
1259
1258
  str = m.pre + "{" + m.body + escClose + m.post;
1260
1259
  return expand(str);
1261
1260
  }
@@ -1329,7 +1328,7 @@ var require_brace_expansion = (0, import_chunk_2ESYSVXG.__commonJS)({
1329
1328
  }
1330
1329
  });
1331
1330
  var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1332
- "../../node_modules/.pnpm/minimatch@5.1.0/node_modules/minimatch/minimatch.js"(exports, module2) {
1331
+ "../../node_modules/.pnpm/minimatch@5.1.6/node_modules/minimatch/minimatch.js"(exports, module2) {
1333
1332
  "use strict";
1334
1333
  var minimatch = module2.exports = (p, pattern, options = {}) => {
1335
1334
  assertValidPattern(pattern);
@@ -1416,7 +1415,9 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1416
1415
  return list;
1417
1416
  };
1418
1417
  var globUnescape = (s) => s.replace(/\\(.)/g, "$1");
1418
+ var charUnescape = (s) => s.replace(/\\([^-\]])/g, "$1");
1419
1419
  var regExpEscape = (s) => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
1420
+ var braExpEscape = (s) => s.replace(/[[\]\\]/g, "\\$&");
1420
1421
  var Minimatch = class {
1421
1422
  constructor(pattern, options) {
1422
1423
  assertValidPattern(pattern);
@@ -1469,7 +1470,7 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1469
1470
  negate = !negate;
1470
1471
  negateOffset++;
1471
1472
  }
1472
- if (negateOffset) this.pattern = pattern.substr(negateOffset);
1473
+ if (negateOffset) this.pattern = pattern.slice(negateOffset);
1473
1474
  this.negate = negate;
1474
1475
  }
1475
1476
  // set partial to true to test if, for example,
@@ -1555,7 +1556,7 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1555
1556
  }
1556
1557
  if (pattern === "") return "";
1557
1558
  let re = "";
1558
- let hasMagic = !!options.nocase;
1559
+ let hasMagic = false;
1559
1560
  let escaping = false;
1560
1561
  const patternListStack = [];
1561
1562
  const negativeLists = [];
@@ -1566,7 +1567,10 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1566
1567
  let cs;
1567
1568
  let pl;
1568
1569
  let sp;
1569
- const patternStart = pattern.charAt(0) === "." ? "" : options.dot ? "(?!(?:^|\\/)\\.{1,2}(?:$|\\/))" : "(?!\\.)";
1570
+ let dotTravAllowed = pattern.charAt(0) === ".";
1571
+ let dotFileAllowed = options.dot || dotTravAllowed;
1572
+ const patternStart = () => dotTravAllowed ? "" : dotFileAllowed ? "(?!(?:^|\\/)\\.{1,2}(?:$|\\/))" : "(?!\\.)";
1573
+ const subPatternStart = (p) => p.charAt(0) === "." ? "" : options.dot ? "(?!(?:^|\\/)\\.{1,2}(?:$|\\/))" : "(?!\\.)";
1570
1574
  const clearStateChar = () => {
1571
1575
  if (stateChar) {
1572
1576
  switch (stateChar) {
@@ -1605,6 +1609,10 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1605
1609
  return false;
1606
1610
  }
1607
1611
  case "\\":
1612
+ if (inClass && pattern.charAt(i + 1) === "-") {
1613
+ re += c;
1614
+ continue;
1615
+ }
1608
1616
  clearStateChar();
1609
1617
  escaping = true;
1610
1618
  continue;
@@ -1627,7 +1635,7 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1627
1635
  stateChar = c;
1628
1636
  if (options.noext) clearStateChar();
1629
1637
  continue;
1630
- case "(":
1638
+ case "(": {
1631
1639
  if (inClass) {
1632
1640
  re += "(";
1633
1641
  continue;
@@ -1636,39 +1644,54 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1636
1644
  re += "\\(";
1637
1645
  continue;
1638
1646
  }
1639
- patternListStack.push({
1647
+ const plEntry = {
1640
1648
  type: stateChar,
1641
1649
  start: i - 1,
1642
1650
  reStart: re.length,
1643
1651
  open: plTypes[stateChar].open,
1644
1652
  close: plTypes[stateChar].close
1645
- });
1646
- re += stateChar === "!" ? "(?:(?!(?:" : "(?:";
1653
+ };
1654
+ this.debug(this.pattern, " ", plEntry);
1655
+ patternListStack.push(plEntry);
1656
+ re += plEntry.open;
1657
+ if (plEntry.start === 0 && plEntry.type !== "!") {
1658
+ dotTravAllowed = true;
1659
+ re += subPatternStart(pattern.slice(i + 1));
1660
+ }
1647
1661
  this.debug("plType %j %j", stateChar, re);
1648
1662
  stateChar = false;
1649
1663
  continue;
1650
- case ")":
1651
- if (inClass || !patternListStack.length) {
1664
+ }
1665
+ case ")": {
1666
+ const plEntry = patternListStack[patternListStack.length - 1];
1667
+ if (inClass || !plEntry) {
1652
1668
  re += "\\)";
1653
1669
  continue;
1654
1670
  }
1671
+ patternListStack.pop();
1655
1672
  clearStateChar();
1656
1673
  hasMagic = true;
1657
- pl = patternListStack.pop();
1674
+ pl = plEntry;
1658
1675
  re += pl.close;
1659
1676
  if (pl.type === "!") {
1660
- negativeLists.push(pl);
1677
+ negativeLists.push(Object.assign(pl, { reEnd: re.length }));
1661
1678
  }
1662
- pl.reEnd = re.length;
1663
1679
  continue;
1664
- case "|":
1665
- if (inClass || !patternListStack.length) {
1680
+ }
1681
+ case "|": {
1682
+ const plEntry = patternListStack[patternListStack.length - 1];
1683
+ if (inClass || !plEntry) {
1666
1684
  re += "\\|";
1667
1685
  continue;
1668
1686
  }
1669
1687
  clearStateChar();
1670
1688
  re += "|";
1689
+ if (plEntry.start === 0 && plEntry.type !== "!") {
1690
+ dotTravAllowed = true;
1691
+ re += subPatternStart(pattern.slice(i + 1));
1692
+ }
1671
1693
  continue;
1694
+ }
1672
1695
  // these are mostly the same in regexp and glob
1673
1696
  case "[":
1674
1697
  clearStateChar();
@@ -1688,17 +1711,13 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1688
1711
  }
1689
1712
  cs = pattern.substring(classStart + 1, i);
1690
1713
  try {
1691
- RegExp("[" + cs + "]");
1714
+ RegExp("[" + braExpEscape(charUnescape(cs)) + "]");
1715
+ re += c;
1692
1716
  } catch (er) {
1693
- sp = this.parse(cs, SUBPARSE);
1694
- re = re.substr(0, reClassStart) + "\\[" + sp[0] + "\\]";
1695
- hasMagic = hasMagic || sp[1];
1696
- inClass = false;
1697
- continue;
1717
+ re = re.substring(0, reClassStart) + "(?:$.)";
1698
1718
  }
1699
1719
  hasMagic = true;
1700
1720
  inClass = false;
1701
- re += c;
1702
1721
  continue;
1703
1722
  default:
1704
1723
  clearStateChar();
@@ -1710,9 +1729,9 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1710
1729
  }
1711
1730
  }
1712
1731
  if (inClass) {
1713
- cs = pattern.substr(classStart + 1);
1732
+ cs = pattern.slice(classStart + 1);
1714
1733
  sp = this.parse(cs, SUBPARSE);
1715
- re = re.substr(0, reClassStart) + "\\[" + sp[0];
1734
+ re = re.substring(0, reClassStart) + "\\[" + sp[0];
1716
1735
  hasMagic = hasMagic || sp[1];
1717
1736
  }
1718
1737
  for (pl = patternListStack.pop(); pl; pl = patternListStack.pop()) {
@@ -1741,24 +1760,28 @@ var require_minimatch = (0, import_chunk_2ESYSVXG.__commonJS)({
1741
1760
  const nlFirst = re.slice(nl.reStart, nl.reEnd - 8);
1742
1761
  let nlAfter = re.slice(nl.reEnd);
1743
1762
  const nlLast = re.slice(nl.reEnd - 8, nl.reEnd) + nlAfter;
1744
- const openParensBefore = nlBefore.split("(").length - 1;
1763
+ const closeParensBefore = nlBefore.split(")").length;
1764
+ const openParensBefore = nlBefore.split("(").length - closeParensBefore;
1745
1765
  let cleanAfter = nlAfter;
1746
1766
  for (let i = 0; i < openParensBefore; i++) {
1747
1767
  cleanAfter = cleanAfter.replace(/\)[+*?]?/, "");
1748
1768
  }
1749
1769
  nlAfter = cleanAfter;
1750
- const dollar = nlAfter === "" && isSub !== SUBPARSE ? "$" : "";
1770
+ const dollar = nlAfter === "" && isSub !== SUBPARSE ? "(?:$|\\/)" : "";
1751
1771
  re = nlBefore + nlFirst + nlAfter + dollar + nlLast;
1752
1772
  }
1753
1773
  if (re !== "" && hasMagic) {
1754
1774
  re = "(?=.)" + re;
1755
1775
  }
1756
1776
  if (addPatternStart) {
1757
- re = patternStart + re;
1777
+ re = patternStart() + re;
1758
1778
  }
1759
1779
  if (isSub === SUBPARSE) {
1760
1780
  return [re, hasMagic];
1761
1781
  }
1782
+ if (options.nocase && !hasMagic) {
1783
+ hasMagic = pattern.toUpperCase() !== pattern.toLowerCase();
1784
+ }
1762
1785
  if (!hasMagic) {
1763
1786
  return globUnescape(pattern);
1764
1787
  }
@@ -4939,7 +4962,7 @@ var require_ensure = (0, import_chunk_2ESYSVXG.__commonJS)({
4939
4962
  }
4940
4963
  });
4941
4964
  var require_utils2 = (0, import_chunk_2ESYSVXG.__commonJS)({
4942
- "../../node_modules/.pnpm/jsonfile@6.1.0/node_modules/jsonfile/utils.js"(exports, module2) {
4965
+ "../../node_modules/.pnpm/jsonfile@6.2.0/node_modules/jsonfile/utils.js"(exports, module2) {
4943
4966
  "use strict";
4944
4967
  function stringify(obj, { EOL = "\n", finalEOL = true, replacer = null, spaces } = {}) {
4945
4968
  const EOF = finalEOL ? EOL : "";
@@ -4954,7 +4977,7 @@ var require_utils2 = (0, import_chunk_2ESYSVXG.__commonJS)({
4954
4977
  }
4955
4978
  });
4956
4979
  var require_jsonfile = (0, import_chunk_2ESYSVXG.__commonJS)({
4957
- "../../node_modules/.pnpm/jsonfile@6.1.0/node_modules/jsonfile/index.js"(exports, module2) {
4980
+ "../../node_modules/.pnpm/jsonfile@6.2.0/node_modules/jsonfile/index.js"(exports, module2) {
4958
4981
  "use strict";
4959
4982
  var _fs;
4960
4983
  try {
@@ -5016,13 +5039,12 @@ var require_jsonfile = (0, import_chunk_2ESYSVXG.__commonJS)({
5016
5039
  const str = stringify(obj, options);
5017
5040
  return fs3.writeFileSync(file, str, options);
5018
5041
  }
5019
- var jsonfile = {
5042
+ module2.exports = {
5020
5043
  readFile: readFile2,
5021
5044
  readFileSync,
5022
5045
  writeFile,
5023
5046
  writeFileSync
5024
5047
  };
5025
- module2.exports = jsonfile;
5026
5048
  }
5027
5049
  });
5028
5050
  var require_jsonfile2 = (0, import_chunk_2ESYSVXG.__commonJS)({
@@ -5569,10 +5591,6 @@ async function getSchemaWithPathInternal(schemaPathFromArgs, schemaPathFromConfi
5569
5591
  if (prismaConfigResult.ok) {
5570
5592
  return prismaConfigResult;
5571
5593
  }
5572
- const pkgJsonResult = await getSchemaFromPackageJson(cwd);
5573
- if (pkgJsonResult.ok) {
5574
- return pkgJsonResult;
5575
- }
5576
5594
  const defaultResult = await getDefaultSchema(cwd);
5577
5595
  if (defaultResult.ok) {
5578
5596
  return defaultResult;
@@ -5629,36 +5647,6 @@ async function readSchemaFromPrismaConfigBasedLocation(schemaPathFromConfig) {
5629
5647
  }
5630
5648
  return schemaResult;
5631
5649
  }
5632
- async function getSchemaFromPackageJson(cwd) {
5633
- const prismaConfig = await (0, import_config.loadConfigFromPackageJson)(cwd);
5634
- debug("prismaConfig", prismaConfig);
5635
- if (!prismaConfig || !prismaConfig.config?.schema) {
5636
- return { ok: false, error: { kind: "PackageJsonNotConfigured" } };
5637
- }
5638
- const schemaPathFromPkgJson = prismaConfig.config.schema;
5639
- if (typeof schemaPathFromPkgJson !== "string") {
5640
- throw new Error(
5641
- `Provided schema path \`${schemaPathFromPkgJson}\` from \`${import_path2.default.relative(
5642
- cwd,
5643
- prismaConfig.loadedFromFile
5644
- )}\` must be of type string`
5645
- );
5646
- }
5647
- const absoluteSchemaPath = import_path2.default.isAbsolute(schemaPathFromPkgJson) ? schemaPathFromPkgJson : import_path2.default.resolve(import_path2.default.dirname(prismaConfig.loadedFromFile), schemaPathFromPkgJson);
5648
- const lookupResult = await readSchemaFromFileOrDirectory(absoluteSchemaPath);
5649
- if (!lookupResult.ok) {
5650
- throw new Error(
5651
- `Could not load schema from \`${import_path2.default.relative(
5652
- cwd,
5653
- absoluteSchemaPath
5654
- )}\` provided by "prisma.schema" config of \`${import_path2.default.relative(
5655
- cwd,
5656
- prismaConfig.loadedFromFile
5657
- )}\`: ${renderLookupError(lookupResult.error)}`
5658
- );
5659
- }
5660
- return lookupResult;
5661
- }
5662
5650
  async function getDefaultSchema(cwd, failures = []) {
5663
5651
  const lookupPaths = [import_path2.default.join(cwd, "schema.prisma"), import_path2.default.join(cwd, "prisma", "schema.prisma")];
5664
5652
  for (const path3 of lookupPaths) {
@@ -5731,7 +5719,7 @@ The command takes a source ${(0, import_chunk_SKRR5WT4.green)(`--from-...`)} and
5731
5719
  The source and destination must use the same provider,
5732
5720
  e.g. a diff using 2 different providers like PostgreSQL and SQLite is not supported.
5733
5721
 
5734
- It compares the source with the destination to generate a diff.
5722
+ It compares the source with the destination to generate a diff.
5735
5723
  The diff can be interpreted as generating a migration that brings the source schema (from) to the shape of the destination schema (to).
5736
5724
  The default output is a human readable diff, it can be rendered as SQL using \`--script\` on SQL databases.
5737
5725
 
@@ -5739,13 +5727,13 @@ See the documentation for more information ${(0, import_internals.link)("https:/
5739
5727
 
5740
5728
  ${helpOptions}
5741
5729
  ${(0, import_chunk_SKRR5WT4.bold)("Examples")}
5742
-
5730
+
5743
5731
  From database to database as summary
5744
5732
  e.g. compare two live databases
5745
5733
  ${(0, import_chunk_SKRR5WT4.dim)("$")} prisma migrate diff \\
5746
5734
  --from-url "$DATABASE_URL" \\
5747
5735
  --to-url "postgresql://login:password@localhost:5432/db2"
5748
-
5736
+
5749
5737
  From a live database to a Prisma datamodel
5750
5738
  e.g. roll forward after a migration failed in the middle
5751
5739
  ${(0, import_chunk_SKRR5WT4.dim)("$")} prisma migrate diff \\
@@ -5753,8 +5741,8 @@ ${(0, import_chunk_SKRR5WT4.bold)("Examples")}
5753
5741
  --from-url "$PROD_DB" \\
5754
5742
  --to-schema-datamodel=next_datamodel.prisma \\
5755
5743
  --script
5756
-
5757
- From a live database to a datamodel
5744
+
5745
+ From a live database to a datamodel
5758
5746
  e.g. roll backward after a migration failed in the middle
5759
5747
  ${(0, import_chunk_SKRR5WT4.dim)("$")} prisma migrate diff \\
5760
5748
  --shadow-database-url "$SHADOW_DB" \\
@@ -5773,7 +5761,7 @@ ${(0, import_chunk_SKRR5WT4.bold)("Examples")}
5773
5761
  --from-schema-datamodel=./prisma/schema.prisma \\
5774
5762
  --to-local-d1 \\
5775
5763
  --script
5776
-
5764
+
5777
5765
  From a Prisma Migrate \`migrations\` directory to another database
5778
5766
  e.g. generate a migration for a hotfix already applied on production
5779
5767
  ${(0, import_chunk_SKRR5WT4.dim)("$")} prisma migrate diff \\
@@ -5873,7 +5861,6 @@ ${(0, import_chunk_SKRR5WT4.bold)("Examples")}
5873
5861
  tag: "empty"
5874
5862
  };
5875
5863
  } else if (args["--from-schema-datasource"]) {
5876
- await (0, import_internals.loadEnvFile)({ schemaPath: args["--from-schema-datasource"], printMessage: false, config });
5877
5864
  const schemaContext = await (0, import_internals.loadSchemaContext)({
5878
5865
  schemaPathFromArg: args["--from-schema-datasource"],
5879
5866
  schemaPathArgumentName: "--from-schema-datasource",
@@ -5916,7 +5903,6 @@ ${(0, import_chunk_SKRR5WT4.bold)("Examples")}
5916
5903
  tag: "empty"
5917
5904
  };
5918
5905
  } else if (args["--to-schema-datasource"]) {
5919
- await (0, import_internals.loadEnvFile)({ schemaPath: args["--to-schema-datasource"], printMessage: false, config });
5920
5906
  const schemaContext = await (0, import_internals.loadSchemaContext)({
5921
5907
  schemaPathFromArg: args["--to-schema-datasource"],
5922
5908
  schemaPathArgumentName: "--to-schema-datasource",
@@ -5956,7 +5942,7 @@ ${(0, import_chunk_SKRR5WT4.bold)("Examples")}
5956
5942
  externalTables: config.tables?.external ?? [],
5957
5943
  externalEnums: config.enums?.external ?? []
5958
5944
  };
5959
- const migrate = await import_chunk_D6LYHB65.Migrate.setup({
5945
+ const migrate = await import_chunk_V5D5NSLS.Migrate.setup({
5960
5946
  schemaEngineConfig: config,
5961
5947
  schemaFilter,
5962
5948
  extensions: config["extensions"]