@prisma/migrate 6.3.0-integration-simpler-typeinfo-query.1 → 6.3.0-integration-studio-ux-refinements.1

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 (61) hide show
  1. package/dist/Migrate.js +5 -5
  2. package/dist/SchemaEngine.js +5 -5
  3. package/dist/bin.js +41 -42
  4. package/dist/{chunk-LLGEQ76N.js → chunk-33HVTIBE.js} +15 -15
  5. package/dist/{chunk-BAVMZZAR.js → chunk-4BFDHH3U.js} +12 -12
  6. package/dist/{chunk-XLLUFIQK.js → chunk-7MUF3HLX.js} +9 -8
  7. package/dist/{chunk-SV5GANSI.js → chunk-7TICHBC5.js} +10 -10
  8. package/dist/{chunk-GJN3CSXW.js → chunk-AOCCG7RR.js} +6 -6
  9. package/dist/{chunk-ZLGLVUFD.js → chunk-E2XKFV2C.js} +8 -8
  10. package/dist/{chunk-LVFPGUOH.js → chunk-E3UZYEGF.js} +92 -87
  11. package/dist/{chunk-BAFPAACN.js → chunk-ILJRJJ3S.js} +4 -4
  12. package/dist/{chunk-E3KHFUFQ.js → chunk-J77IRNPE.js} +9 -124
  13. package/dist/{chunk-RYWEOVLN.js → chunk-KHICE54Q.js} +6 -6
  14. package/dist/{chunk-5VYRCIVT.js → chunk-MQQLTARC.js} +100 -182
  15. package/dist/{chunk-MWEO3VUS.js → chunk-NCDRH4BH.js} +7 -7
  16. package/dist/{chunk-VWV2NY26.js → chunk-NKQGJ3AE.js} +7 -3
  17. package/dist/{chunk-XVL5RF2T.js → chunk-OANG4W7W.js} +15 -15
  18. package/dist/{chunk-55NRLWME.js → chunk-PSSOKBLN.js} +1029 -339
  19. package/dist/{chunk-EXUBPCXZ.js → chunk-TFIFMCN4.js} +18 -18
  20. package/dist/{chunk-76XWADEV.js → chunk-TJZ4FW7K.js} +10 -10
  21. package/dist/{chunk-ZBOJAYON.js → chunk-UI76O6B2.js} +6 -6
  22. package/dist/{chunk-KEBB7UIB.js → chunk-UQQQ6HXZ.js} +5 -3
  23. package/dist/{chunk-W3ROQKBN.js → chunk-V7DE6JTG.js} +4 -4
  24. package/dist/{chunk-UJWMQPUH.js → chunk-XQEPG5ZX.js} +10 -10
  25. package/dist/{chunk-YOW3VBYS.js → chunk-XQJTDY7A.js} +6 -6
  26. package/dist/{chunk-WIZM7TFT.js → chunk-YKUZUAXA.js} +443 -55
  27. package/dist/commands/DbDrop.js +3 -3
  28. package/dist/commands/DbExecute.js +6 -6
  29. package/dist/commands/DbPull.js +8 -8
  30. package/dist/commands/DbPush.js +7 -7
  31. package/dist/commands/DbSeed.js +4 -5
  32. package/dist/commands/MigrateDeploy.js +7 -7
  33. package/dist/commands/MigrateDev.js +8 -9
  34. package/dist/commands/MigrateDiff.js +7 -8
  35. package/dist/commands/MigrateReset.js +8 -9
  36. package/dist/commands/MigrateResolve.js +7 -7
  37. package/dist/commands/MigrateStatus.js +7 -7
  38. package/dist/index.js +52 -53
  39. package/dist/internals/src/cli/getTypescriptVersion.d.ts +1 -0
  40. package/dist/internals/src/index.d.ts +1 -0
  41. package/dist/internals/src/tracing/types.d.ts +26 -16
  42. package/dist/internals/src/utils/isCurrentBinInstalledGlobally.d.ts +1 -1
  43. package/dist/migrate/src/utils/ensureDatabaseExists.d.ts +1 -1
  44. package/dist/migrate/src/utils/printDatasources.d.ts +2 -1
  45. package/dist/{multipart-parser-KKECAI5D.js → multipart-parser-73VM3J4A.js} +10 -7
  46. package/dist/{multipart-parser-47FFAP42-P3F6TPHJ.js → multipart-parser-ITART6UP-FFJAMHWE.js} +25 -22
  47. package/dist/typescript-AILDXN3I.js +205230 -0
  48. package/dist/typescript-WN4QH2CP.js +205192 -0
  49. package/dist/utils/ensureDatabaseExists.js +7 -7
  50. package/dist/utils/getDatabaseVersionSafe.js +5 -5
  51. package/dist/utils/introspectSql.js +4 -4
  52. package/dist/utils/removeSchemaFiles.js +3 -3
  53. package/dist/utils/saveSchemaFiles.js +3 -3
  54. package/dist/utils/seed.js +6 -7
  55. package/dist/utils/setupMSSQL.js +62 -59
  56. package/dist/utils/setupMongo.js +17608 -14119
  57. package/dist/utils/setupMysql.js +45 -0
  58. package/dist/views/handleViewsIO.js +3 -3
  59. package/package.json +14 -15
  60. package/dist/chunk-EFPE3Q7J.js +0 -424
  61. package/dist/internals/src/get-generators/generatorResolvers/prisma-client-js/check-dependencies/checkYarnVersion.d.ts +0 -9
@@ -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_LVFPGUOH_exports = {};
30
- __export(chunk_LVFPGUOH_exports, {
31
- $: () => $,
29
+ var chunk_E3UZYEGF_exports = {};
30
+ __export(chunk_E3UZYEGF_exports, {
32
31
  N: () => N,
33
32
  handleViewsIO: () => handleViewsIO,
34
33
  init_dist: () => init_dist,
35
34
  init_handleViewsIO: () => init_handleViewsIO,
36
- require_function: () => require_function
35
+ require_function: () => require_function,
36
+ z: () => z
37
37
  });
38
- module.exports = __toCommonJS(chunk_LVFPGUOH_exports);
38
+ module.exports = __toCommonJS(chunk_E3UZYEGF_exports);
39
39
  var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
40
40
  var import_internals = require("@prisma/internals");
41
41
  var import_path = __toESM(require("path"));
@@ -4256,20 +4256,20 @@ var require_TaskEither = (0, import_chunk_WWAWV7DQ.__commonJS)({
4256
4256
  function a(...t2) {
4257
4257
  if (1 === t2.length) {
4258
4258
  const [e2] = t2;
4259
- return (t3) => o(e2, t3, () => {
4259
+ return (t3) => s(e2, t3, () => {
4260
4260
  });
4261
4261
  }
4262
4262
  if (2 === t2.length) {
4263
4263
  const [e2, n2] = t2;
4264
- return o(e2, n2, () => {
4264
+ return s(e2, n2, () => {
4265
4265
  });
4266
4266
  }
4267
4267
  throw new Error(`isMatching wasn't given the right number of arguments: expected 1 or 2, received ${t2.length}.`);
4268
4268
  }
4269
4269
  function u(t2) {
4270
- return Object.assign(t2, { optional: () => l(t2), and: (e2) => m(t2, e2), or: (e2) => d(t2, e2), select: (e2) => void 0 === e2 ? p(t2) : p(e2, t2) });
4270
+ return Object.assign(t2, { optional: () => h(t2), and: (e2) => m(t2, e2), or: (e2) => d(t2, e2), select: (e2) => void 0 === e2 ? y(t2) : y(e2, t2) });
4271
4271
  }
4272
- function h(t2) {
4272
+ function l(t2) {
4273
4273
  return Object.assign(((t3) => Object.assign(t3, { [Symbol.iterator]() {
4274
4274
  let n2 = 0;
4275
4275
  const r2 = [{ value: Object.assign(t3, { [e]: true }), done: false }, { done: true, value: void 0 }];
@@ -4277,16 +4277,16 @@ function h(t2) {
4277
4277
  var t4;
4278
4278
  return null != (t4 = r2[n2++]) ? t4 : r2.at(-1);
4279
4279
  } };
4280
- } }))(t2), { optional: () => h(l(t2)), select: (e2) => h(void 0 === e2 ? p(t2) : p(e2, t2)) });
4280
+ } }))(t2), { optional: () => l(h(t2)), select: (e2) => l(void 0 === e2 ? y(t2) : y(e2, t2)) });
4281
4281
  }
4282
- function l(e2) {
4282
+ function h(e2) {
4283
4283
  return u({ [t]: () => ({ match: (t2) => {
4284
4284
  let n2 = {};
4285
4285
  const r2 = (t3, e3) => {
4286
4286
  n2[t3] = e3;
4287
4287
  };
4288
- return void 0 === t2 ? (s(e2).forEach((t3) => r2(t3, void 0)), { matched: true, selections: n2 }) : { matched: o(e2, t2, r2), selections: n2 };
4289
- }, getSelectionKeys: () => s(e2), matcherType: "optional" }) });
4288
+ return void 0 === t2 ? (o(e2).forEach((t3) => r2(t3, void 0)), { matched: true, selections: n2 }) : { matched: s(e2, t2, r2), selections: n2 };
4289
+ }, getSelectionKeys: () => o(e2), matcherType: "optional" }) });
4290
4290
  }
4291
4291
  function m(...e2) {
4292
4292
  return u({ [t]: () => ({ match: (t2) => {
@@ -4294,8 +4294,8 @@ function m(...e2) {
4294
4294
  const r2 = (t3, e3) => {
4295
4295
  n2[t3] = e3;
4296
4296
  };
4297
- return { matched: e2.every((e3) => o(e3, t2, r2)), selections: n2 };
4298
- }, getSelectionKeys: () => c(e2, s), matcherType: "and" }) });
4297
+ return { matched: e2.every((e3) => s(e3, t2, r2)), selections: n2 };
4298
+ }, getSelectionKeys: () => c(e2, o), matcherType: "and" }) });
4299
4299
  }
4300
4300
  function d(...e2) {
4301
4301
  return u({ [t]: () => ({ match: (t2) => {
@@ -4303,20 +4303,20 @@ function d(...e2) {
4303
4303
  const r2 = (t3, e3) => {
4304
4304
  n2[t3] = e3;
4305
4305
  };
4306
- return c(e2, s).forEach((t3) => r2(t3, void 0)), { matched: e2.some((e3) => o(e3, t2, r2)), selections: n2 };
4307
- }, getSelectionKeys: () => c(e2, s), matcherType: "or" }) });
4306
+ return c(e2, o).forEach((t3) => r2(t3, void 0)), { matched: e2.some((e3) => s(e3, t2, r2)), selections: n2 };
4307
+ }, getSelectionKeys: () => c(e2, o), matcherType: "or" }) });
4308
4308
  }
4309
- function y(e2) {
4309
+ function p(e2) {
4310
4310
  return { [t]: () => ({ match: (t2) => ({ matched: Boolean(e2(t2)) }) }) };
4311
4311
  }
4312
- function p(...e2) {
4312
+ function y(...e2) {
4313
4313
  const r2 = "string" == typeof e2[0] ? e2[0] : void 0, i2 = 2 === e2.length ? e2[1] : "string" == typeof e2[0] ? void 0 : e2[0];
4314
4314
  return u({ [t]: () => ({ match: (t2) => {
4315
4315
  let e3 = { [null != r2 ? r2 : n]: t2 };
4316
- return { matched: void 0 === i2 || o(i2, t2, (t3, n2) => {
4316
+ return { matched: void 0 === i2 || s(i2, t2, (t3, n2) => {
4317
4317
  e3[t3] = n2;
4318
4318
  }), selections: e3 };
4319
- }, getSelectionKeys: () => [null != r2 ? r2 : n].concat(void 0 === i2 ? [] : s(i2)) }) });
4319
+ }, getSelectionKeys: () => [null != r2 ? r2 : n].concat(void 0 === i2 ? [] : o(i2)) }) });
4320
4320
  }
4321
4321
  function v(t2) {
4322
4322
  return "number" == typeof t2;
@@ -4327,51 +4327,51 @@ function b(t2) {
4327
4327
  function w(t2) {
4328
4328
  return "bigint" == typeof t2;
4329
4329
  }
4330
- function $(t2) {
4331
- return new z(t2, W);
4330
+ function z(t2) {
4331
+ return new I(t2, $);
4332
4332
  }
4333
- var t, e, n, r, i, o, s, c, f, g, S, O, j, E, K, x, A, P, T, k, B, _, N, W, z;
4333
+ var t, e, n, r, i, s, o, c, f, g, S, O, j, K, x, E, A, P, T, B, _, k, N, W, $, I;
4334
4334
  var init_dist = (0, import_chunk_WWAWV7DQ.__esm)({
4335
- "../../node_modules/.pnpm/ts-pattern@5.2.0/node_modules/ts-pattern/dist/index.js"() {
4335
+ "../../node_modules/.pnpm/ts-pattern@5.6.0/node_modules/ts-pattern/dist/index.js"() {
4336
4336
  "use strict";
4337
4337
  t = Symbol.for("@ts-pattern/matcher");
4338
4338
  e = Symbol.for("@ts-pattern/isVariadic");
4339
4339
  n = "@ts-pattern/anonymous-select-key";
4340
4340
  r = (t2) => Boolean(t2 && "object" == typeof t2);
4341
4341
  i = (e2) => e2 && !!e2[t];
4342
- o = (n2, s2, c2) => {
4342
+ s = (n2, o2, c2) => {
4343
4343
  if (i(n2)) {
4344
- const e2 = n2[t](), { matched: r2, selections: i2 } = e2.match(s2);
4344
+ const e2 = n2[t](), { matched: r2, selections: i2 } = e2.match(o2);
4345
4345
  return r2 && i2 && Object.keys(i2).forEach((t2) => c2(t2, i2[t2])), r2;
4346
4346
  }
4347
4347
  if (r(n2)) {
4348
- if (!r(s2)) return false;
4348
+ if (!r(o2)) return false;
4349
4349
  if (Array.isArray(n2)) {
4350
- if (!Array.isArray(s2)) return false;
4350
+ if (!Array.isArray(o2)) return false;
4351
4351
  let t2 = [], r2 = [], a2 = [];
4352
- for (const o2 of n2.keys()) {
4353
- const s3 = n2[o2];
4354
- i(s3) && s3[e] ? a2.push(s3) : a2.length ? r2.push(s3) : t2.push(s3);
4352
+ for (const s2 of n2.keys()) {
4353
+ const o3 = n2[s2];
4354
+ i(o3) && o3[e] ? a2.push(o3) : a2.length ? r2.push(o3) : t2.push(o3);
4355
4355
  }
4356
4356
  if (a2.length) {
4357
4357
  if (a2.length > 1) throw new Error("Pattern error: Using `...P.array(...)` several times in a single pattern is not allowed.");
4358
- if (s2.length < t2.length + r2.length) return false;
4359
- const e2 = s2.slice(0, t2.length), n3 = 0 === r2.length ? [] : s2.slice(-r2.length), i2 = s2.slice(t2.length, 0 === r2.length ? Infinity : -r2.length);
4360
- return t2.every((t3, n4) => o(t3, e2[n4], c2)) && r2.every((t3, e3) => o(t3, n3[e3], c2)) && (0 === a2.length || o(a2[0], i2, c2));
4358
+ if (o2.length < t2.length + r2.length) return false;
4359
+ const e2 = o2.slice(0, t2.length), n3 = 0 === r2.length ? [] : o2.slice(-r2.length), i2 = o2.slice(t2.length, 0 === r2.length ? Infinity : -r2.length);
4360
+ return t2.every((t3, n4) => s(t3, e2[n4], c2)) && r2.every((t3, e3) => s(t3, n3[e3], c2)) && (0 === a2.length || s(a2[0], i2, c2));
4361
4361
  }
4362
- return n2.length === s2.length && n2.every((t3, e2) => o(t3, s2[e2], c2));
4362
+ return n2.length === o2.length && n2.every((t3, e2) => s(t3, o2[e2], c2));
4363
4363
  }
4364
- return Object.keys(n2).every((e2) => {
4364
+ return Reflect.ownKeys(n2).every((e2) => {
4365
4365
  const r2 = n2[e2];
4366
- return (e2 in s2 || i(a2 = r2) && "optional" === a2[t]().matcherType) && o(r2, s2[e2], c2);
4366
+ return (e2 in o2 || i(a2 = r2) && "optional" === a2[t]().matcherType) && s(r2, o2[e2], c2);
4367
4367
  var a2;
4368
4368
  });
4369
4369
  }
4370
- return Object.is(s2, n2);
4370
+ return Object.is(o2, n2);
4371
4371
  };
4372
- s = (e2) => {
4373
- var n2, o2, a2;
4374
- return r(e2) ? i(e2) ? null != (n2 = null == (o2 = (a2 = e2[t]()).getSelectionKeys) ? void 0 : o2.call(a2)) ? n2 : [] : Array.isArray(e2) ? c(e2, s) : c(Object.values(e2), s) : [];
4372
+ o = (e2) => {
4373
+ var n2, s2, a2;
4374
+ return r(e2) ? i(e2) ? null != (n2 = null == (s2 = (a2 = e2[t]()).getSelectionKeys) ? void 0 : s2.call(a2)) ? n2 : [] : Array.isArray(e2) ? c(e2, o) : c(Object.values(e2), o) : [];
4375
4375
  };
4376
4376
  c = (t2, e2) => t2.reduce((t3, n2) => t3.concat(e2(n2)), []);
4377
4377
  f = (t2, e2) => {
@@ -4382,54 +4382,54 @@ var init_dist = (0, import_chunk_WWAWV7DQ.__esm)({
4382
4382
  for (const [n2, r2] of t2.entries()) if (!e2(r2, n2)) return false;
4383
4383
  return true;
4384
4384
  };
4385
- S = u(y(function(t2) {
4385
+ S = u(p(function(t2) {
4386
4386
  return true;
4387
4387
  }));
4388
4388
  O = S;
4389
4389
  j = (t2) => Object.assign(u(t2), { startsWith: (e2) => {
4390
- return j(m(t2, (n2 = e2, y((t3) => b(t3) && t3.startsWith(n2)))));
4390
+ return j(m(t2, (n2 = e2, p((t3) => b(t3) && t3.startsWith(n2)))));
4391
4391
  var n2;
4392
4392
  }, endsWith: (e2) => {
4393
- return j(m(t2, (n2 = e2, y((t3) => b(t3) && t3.endsWith(n2)))));
4393
+ return j(m(t2, (n2 = e2, p((t3) => b(t3) && t3.endsWith(n2)))));
4394
4394
  var n2;
4395
- }, minLength: (e2) => j(m(t2, ((t3) => y((e3) => b(e3) && e3.length >= t3))(e2))), length: (e2) => j(m(t2, ((t3) => y((e3) => b(e3) && e3.length === t3))(e2))), maxLength: (e2) => j(m(t2, ((t3) => y((e3) => b(e3) && e3.length <= t3))(e2))), includes: (e2) => {
4396
- return j(m(t2, (n2 = e2, y((t3) => b(t3) && t3.includes(n2)))));
4395
+ }, minLength: (e2) => j(m(t2, ((t3) => p((e3) => b(e3) && e3.length >= t3))(e2))), length: (e2) => j(m(t2, ((t3) => p((e3) => b(e3) && e3.length === t3))(e2))), maxLength: (e2) => j(m(t2, ((t3) => p((e3) => b(e3) && e3.length <= t3))(e2))), includes: (e2) => {
4396
+ return j(m(t2, (n2 = e2, p((t3) => b(t3) && t3.includes(n2)))));
4397
4397
  var n2;
4398
4398
  }, regex: (e2) => {
4399
- return j(m(t2, (n2 = e2, y((t3) => b(t3) && Boolean(t3.match(n2))))));
4399
+ return j(m(t2, (n2 = e2, p((t3) => b(t3) && Boolean(t3.match(n2))))));
4400
4400
  var n2;
4401
4401
  } });
4402
- E = j(y(b));
4403
- K = (t2) => Object.assign(u(t2), { between: (e2, n2) => K(m(t2, ((t3, e3) => y((n3) => v(n3) && t3 <= n3 && e3 >= n3))(e2, n2))), lt: (e2) => K(m(t2, ((t3) => y((e3) => v(e3) && e3 < t3))(e2))), gt: (e2) => K(m(t2, ((t3) => y((e3) => v(e3) && e3 > t3))(e2))), lte: (e2) => K(m(t2, ((t3) => y((e3) => v(e3) && e3 <= t3))(e2))), gte: (e2) => K(m(t2, ((t3) => y((e3) => v(e3) && e3 >= t3))(e2))), int: () => K(m(t2, y((t3) => v(t3) && Number.isInteger(t3)))), finite: () => K(m(t2, y((t3) => v(t3) && Number.isFinite(t3)))), positive: () => K(m(t2, y((t3) => v(t3) && t3 > 0))), negative: () => K(m(t2, y((t3) => v(t3) && t3 < 0))) });
4404
- x = K(y(v));
4405
- A = (t2) => Object.assign(u(t2), { between: (e2, n2) => A(m(t2, ((t3, e3) => y((n3) => w(n3) && t3 <= n3 && e3 >= n3))(e2, n2))), lt: (e2) => A(m(t2, ((t3) => y((e3) => w(e3) && e3 < t3))(e2))), gt: (e2) => A(m(t2, ((t3) => y((e3) => w(e3) && e3 > t3))(e2))), lte: (e2) => A(m(t2, ((t3) => y((e3) => w(e3) && e3 <= t3))(e2))), gte: (e2) => A(m(t2, ((t3) => y((e3) => w(e3) && e3 >= t3))(e2))), positive: () => A(m(t2, y((t3) => w(t3) && t3 > 0))), negative: () => A(m(t2, y((t3) => w(t3) && t3 < 0))) });
4406
- P = A(y(w));
4407
- T = u(y(function(t2) {
4402
+ K = j(p(b));
4403
+ x = (t2) => Object.assign(u(t2), { between: (e2, n2) => x(m(t2, ((t3, e3) => p((n3) => v(n3) && t3 <= n3 && e3 >= n3))(e2, n2))), lt: (e2) => x(m(t2, ((t3) => p((e3) => v(e3) && e3 < t3))(e2))), gt: (e2) => x(m(t2, ((t3) => p((e3) => v(e3) && e3 > t3))(e2))), lte: (e2) => x(m(t2, ((t3) => p((e3) => v(e3) && e3 <= t3))(e2))), gte: (e2) => x(m(t2, ((t3) => p((e3) => v(e3) && e3 >= t3))(e2))), int: () => x(m(t2, p((t3) => v(t3) && Number.isInteger(t3)))), finite: () => x(m(t2, p((t3) => v(t3) && Number.isFinite(t3)))), positive: () => x(m(t2, p((t3) => v(t3) && t3 > 0))), negative: () => x(m(t2, p((t3) => v(t3) && t3 < 0))) });
4404
+ E = x(p(v));
4405
+ A = (t2) => Object.assign(u(t2), { between: (e2, n2) => A(m(t2, ((t3, e3) => p((n3) => w(n3) && t3 <= n3 && e3 >= n3))(e2, n2))), lt: (e2) => A(m(t2, ((t3) => p((e3) => w(e3) && e3 < t3))(e2))), gt: (e2) => A(m(t2, ((t3) => p((e3) => w(e3) && e3 > t3))(e2))), lte: (e2) => A(m(t2, ((t3) => p((e3) => w(e3) && e3 <= t3))(e2))), gte: (e2) => A(m(t2, ((t3) => p((e3) => w(e3) && e3 >= t3))(e2))), positive: () => A(m(t2, p((t3) => w(t3) && t3 > 0))), negative: () => A(m(t2, p((t3) => w(t3) && t3 < 0))) });
4406
+ P = A(p(w));
4407
+ T = u(p(function(t2) {
4408
4408
  return "boolean" == typeof t2;
4409
4409
  }));
4410
- k = u(y(function(t2) {
4410
+ B = u(p(function(t2) {
4411
4411
  return "symbol" == typeof t2;
4412
4412
  }));
4413
- B = u(y(function(t2) {
4413
+ _ = u(p(function(t2) {
4414
4414
  return null == t2;
4415
4415
  }));
4416
- _ = u(y(function(t2) {
4416
+ k = u(p(function(t2) {
4417
4417
  return null != t2;
4418
4418
  }));
4419
- N = { __proto__: null, matcher: t, optional: l, array: function(...e2) {
4420
- return h({ [t]: () => ({ match: (t2) => {
4419
+ N = { __proto__: null, matcher: t, optional: h, array: function(...e2) {
4420
+ return l({ [t]: () => ({ match: (t2) => {
4421
4421
  if (!Array.isArray(t2)) return { matched: false };
4422
4422
  if (0 === e2.length) return { matched: true };
4423
4423
  const n2 = e2[0];
4424
4424
  let r2 = {};
4425
- if (0 === t2.length) return s(n2).forEach((t3) => {
4425
+ if (0 === t2.length) return o(n2).forEach((t3) => {
4426
4426
  r2[t3] = [];
4427
4427
  }), { matched: true, selections: r2 };
4428
4428
  const i2 = (t3, e3) => {
4429
4429
  r2[t3] = (r2[t3] || []).concat([e3]);
4430
4430
  };
4431
- return { matched: t2.every((t3) => o(n2, t3, i2)), selections: r2 };
4432
- }, getSelectionKeys: () => 0 === e2.length ? [] : s(e2[0]) }) });
4431
+ return { matched: t2.every((t3) => s(n2, t3, i2)), selections: r2 };
4432
+ }, getSelectionKeys: () => 0 === e2.length ? [] : o(e2[0]) }) });
4433
4433
  }, set: function(...e2) {
4434
4434
  return u({ [t]: () => ({ match: (t2) => {
4435
4435
  if (!(t2 instanceof Set)) return { matched: false };
@@ -4439,8 +4439,8 @@ var init_dist = (0, import_chunk_WWAWV7DQ.__esm)({
4439
4439
  const r2 = (t3, e3) => {
4440
4440
  n2[t3] = (n2[t3] || []).concat([e3]);
4441
4441
  }, i2 = e2[0];
4442
- return { matched: f(t2, (t3) => o(i2, t3, r2)), selections: n2 };
4443
- }, getSelectionKeys: () => 0 === e2.length ? [] : s(e2[0]) }) });
4442
+ return { matched: f(t2, (t3) => s(i2, t3, r2)), selections: n2 };
4443
+ }, getSelectionKeys: () => 0 === e2.length ? [] : o(e2[0]) }) });
4444
4444
  }, map: function(...e2) {
4445
4445
  return u({ [t]: () => ({ match: (t2) => {
4446
4446
  if (!(t2 instanceof Map)) return { matched: false };
@@ -4452,24 +4452,35 @@ var init_dist = (0, import_chunk_WWAWV7DQ.__esm)({
4452
4452
  if (0 === e2.length) return { matched: true };
4453
4453
  var i2;
4454
4454
  if (1 === e2.length) throw new Error(`\`P.map\` wasn't given enough arguments. Expected (key, value), received ${null == (i2 = e2[0]) ? void 0 : i2.toString()}`);
4455
- const [s2, c2] = e2;
4455
+ const [o2, c2] = e2;
4456
4456
  return { matched: g(t2, (t3, e3) => {
4457
- const n3 = o(s2, e3, r2), i3 = o(c2, t3, r2);
4457
+ const n3 = s(o2, e3, r2), i3 = s(c2, t3, r2);
4458
4458
  return n3 && i3;
4459
4459
  }), selections: n2 };
4460
- }, getSelectionKeys: () => 0 === e2.length ? [] : [...s(e2[0]), ...s(e2[1])] }) });
4460
+ }, getSelectionKeys: () => 0 === e2.length ? [] : [...o(e2[0]), ...o(e2[1])] }) });
4461
4461
  }, intersection: m, union: d, not: function(e2) {
4462
- return u({ [t]: () => ({ match: (t2) => ({ matched: !o(e2, t2, () => {
4462
+ return u({ [t]: () => ({ match: (t2) => ({ matched: !s(e2, t2, () => {
4463
4463
  }) }), getSelectionKeys: () => [], matcherType: "not" }) });
4464
- }, when: y, select: p, any: S, _: O, string: E, number: x, bigint: P, boolean: T, symbol: k, nullish: B, nonNullable: _, instanceOf: function(t2) {
4465
- return u(y(/* @__PURE__ */ function(t3) {
4464
+ }, when: p, select: y, any: S, _: O, string: K, number: E, bigint: P, boolean: T, symbol: B, nullish: _, nonNullable: k, instanceOf: function(t2) {
4465
+ return u(p(/* @__PURE__ */ function(t3) {
4466
4466
  return (e2) => e2 instanceof t3;
4467
4467
  }(t2)));
4468
4468
  }, shape: function(t2) {
4469
- return u(y(a(t2)));
4469
+ return u(p(a(t2)));
4470
4470
  } };
4471
- W = { matched: false, value: void 0 };
4472
- z = class _z {
4471
+ W = class extends Error {
4472
+ constructor(t2) {
4473
+ let e2;
4474
+ try {
4475
+ e2 = JSON.stringify(t2);
4476
+ } catch (n2) {
4477
+ e2 = t2;
4478
+ }
4479
+ super(`Pattern matching error: no pattern matches value ${e2}`), this.input = void 0, this.input = t2;
4480
+ }
4481
+ };
4482
+ $ = { matched: false, value: void 0 };
4483
+ I = class _I {
4473
4484
  constructor(t2, e2) {
4474
4485
  this.input = void 0, this.state = void 0, this.input = t2, this.state = e2;
4475
4486
  }
@@ -4478,29 +4489,23 @@ var init_dist = (0, import_chunk_WWAWV7DQ.__esm)({
4478
4489
  const e2 = t2[t2.length - 1], r2 = [t2[0]];
4479
4490
  let i2;
4480
4491
  3 === t2.length && "function" == typeof t2[1] ? i2 = t2[1] : t2.length > 2 && r2.push(...t2.slice(1, t2.length - 1));
4481
- let s2 = false, c2 = {};
4492
+ let o2 = false, c2 = {};
4482
4493
  const a2 = (t3, e3) => {
4483
- s2 = true, c2[t3] = e3;
4484
- }, u2 = !r2.some((t3) => o(t3, this.input, a2)) || i2 && !Boolean(i2(this.input)) ? W : { matched: true, value: e2(s2 ? n in c2 ? c2[n] : c2 : this.input, this.input) };
4485
- return new _z(this.input, u2);
4494
+ o2 = true, c2[t3] = e3;
4495
+ }, u2 = !r2.some((t3) => s(t3, this.input, a2)) || i2 && !Boolean(i2(this.input)) ? $ : { matched: true, value: e2(o2 ? n in c2 ? c2[n] : c2 : this.input, this.input) };
4496
+ return new _I(this.input, u2);
4486
4497
  }
4487
4498
  when(t2, e2) {
4488
4499
  if (this.state.matched) return this;
4489
4500
  const n2 = Boolean(t2(this.input));
4490
- return new _z(this.input, n2 ? { matched: true, value: e2(this.input, this.input) } : W);
4501
+ return new _I(this.input, n2 ? { matched: true, value: e2(this.input, this.input) } : $);
4491
4502
  }
4492
4503
  otherwise(t2) {
4493
4504
  return this.state.matched ? this.state.value : t2(this.input);
4494
4505
  }
4495
4506
  exhaustive() {
4496
4507
  if (this.state.matched) return this.state.value;
4497
- let t2;
4498
- try {
4499
- t2 = JSON.stringify(this.input);
4500
- } catch (e2) {
4501
- t2 = this.input;
4502
- }
4503
- throw new Error(`Pattern matching error: no pattern matches value ${t2}`);
4508
+ throw new W(this.input);
4504
4509
  }
4505
4510
  run() {
4506
4511
  return this.exhaustive();
@@ -4544,7 +4549,7 @@ async function createViewsIO(viewsDir, views) {
4544
4549
  if (E2.isRight(either)) {
4545
4550
  return { viewFilesToKeep };
4546
4551
  }
4547
- const error = $(either.left).with({ type: "fs-create-dir" }, (e2) => {
4552
+ const error = z(either.left).with({ type: "fs-create-dir" }, (e2) => {
4548
4553
  throw new Error(`Error creating the directory: ${e2.meta.dir}.
4549
4554
  ${e2.error}.`);
4550
4555
  }).with({ type: "fs-write-file" }, (e2) => {
@@ -4570,7 +4575,7 @@ async function cleanLeftoversIO(viewsDir, viewFilesToKeep = []) {
4570
4575
  if (E2.isRight(either)) {
4571
4576
  return;
4572
4577
  }
4573
- const error = $(either.left).with({ type: "fs-remove-empty-dirs" }, (e2) => {
4578
+ const error = z(either.left).with({ type: "fs-remove-empty-dirs" }, (e2) => {
4574
4579
  throw new Error(`Error removing empty directories in: ${e2.meta.dir}.
4575
4580
  ${e2.error}.`);
4576
4581
  }).with({ type: "fs-remove-file" }, (e2) => {
@@ -26,14 +26,14 @@ 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_BAFPAACN_exports = {};
30
- __export(chunk_BAFPAACN_exports, {
29
+ var chunk_ILJRJJ3S_exports = {};
30
+ __export(chunk_ILJRJJ3S_exports, {
31
31
  init_saveSchemaFiles: () => init_saveSchemaFiles,
32
32
  saveSchemaFiles: () => saveSchemaFiles
33
33
  });
34
- module.exports = __toCommonJS(chunk_BAFPAACN_exports);
34
+ module.exports = __toCommonJS(chunk_ILJRJJ3S_exports);
35
35
  var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
36
- var import_promises = __toESM(require("fs/promises"));
36
+ var import_promises = __toESM(require("node:fs/promises"));
37
37
  async function saveSchemaFiles(schemas) {
38
38
  await Promise.all(schemas.files.map((file) => import_promises.default.writeFile(file.path, file.content, "utf8")));
39
39
  }
@@ -16,16 +16,16 @@ 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_E3KHFUFQ_exports = {};
20
- __export(chunk_E3KHFUFQ_exports, {
21
- require_ms: () => require_ms2,
19
+ var chunk_J77IRNPE_exports = {};
20
+ __export(chunk_J77IRNPE_exports, {
21
+ require_ms: () => require_ms,
22
22
  require_src: () => require_src
23
23
  });
24
- module.exports = __toCommonJS(chunk_E3KHFUFQ_exports);
24
+ module.exports = __toCommonJS(chunk_J77IRNPE_exports);
25
25
  var import_chunk_RM5LJIEV = require("./chunk-RM5LJIEV.js");
26
26
  var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
27
27
  var require_ms = (0, import_chunk_WWAWV7DQ.__commonJS)({
28
- "../../node_modules/.pnpm/ms@2.1.2/node_modules/ms/index.js"(exports, module2) {
28
+ "../../node_modules/.pnpm/ms@2.1.3/node_modules/ms/index.js"(exports, module2) {
29
29
  "use strict";
30
30
  var s = 1e3;
31
31
  var m = s * 60;
@@ -140,7 +140,7 @@ var require_ms = (0, import_chunk_WWAWV7DQ.__commonJS)({
140
140
  }
141
141
  });
142
142
  var require_common = (0, import_chunk_WWAWV7DQ.__commonJS)({
143
- "../../node_modules/.pnpm/debug@4.3.6/node_modules/debug/src/common.js"(exports, module2) {
143
+ "../../node_modules/.pnpm/debug@4.3.7/node_modules/debug/src/common.js"(exports, module2) {
144
144
  "use strict";
145
145
  function setup(env) {
146
146
  createDebug.debug = createDebug;
@@ -302,7 +302,7 @@ var require_common = (0, import_chunk_WWAWV7DQ.__commonJS)({
302
302
  }
303
303
  });
304
304
  var require_browser = (0, import_chunk_WWAWV7DQ.__commonJS)({
305
- "../../node_modules/.pnpm/debug@4.3.6/node_modules/debug/src/browser.js"(exports, module2) {
305
+ "../../node_modules/.pnpm/debug@4.3.7/node_modules/debug/src/browser.js"(exports, module2) {
306
306
  "use strict";
307
307
  exports.formatArgs = formatArgs;
308
308
  exports.save = save;
@@ -583,7 +583,7 @@ var require_supports_color = (0, import_chunk_WWAWV7DQ.__commonJS)({
583
583
  }
584
584
  });
585
585
  var require_node = (0, import_chunk_WWAWV7DQ.__commonJS)({
586
- "../../node_modules/.pnpm/debug@4.3.6/node_modules/debug/src/node.js"(exports, module2) {
586
+ "../../node_modules/.pnpm/debug@4.3.7/node_modules/debug/src/node.js"(exports, module2) {
587
587
  "use strict";
588
588
  var tty = (0, import_chunk_WWAWV7DQ.__require)("tty");
589
589
  var util = (0, import_chunk_WWAWV7DQ.__require)("util");
@@ -756,7 +756,7 @@ var require_node = (0, import_chunk_WWAWV7DQ.__commonJS)({
756
756
  }
757
757
  });
758
758
  var require_src = (0, import_chunk_WWAWV7DQ.__commonJS)({
759
- "../../node_modules/.pnpm/debug@4.3.6/node_modules/debug/src/index.js"(exports, module2) {
759
+ "../../node_modules/.pnpm/debug@4.3.7/node_modules/debug/src/index.js"(exports, module2) {
760
760
  "use strict";
761
761
  if (typeof process === "undefined" || process.type === "renderer" || process.browser === true || process.__nwjs) {
762
762
  module2.exports = require_browser();
@@ -765,118 +765,3 @@ var require_src = (0, import_chunk_WWAWV7DQ.__commonJS)({
765
765
  }
766
766
  }
767
767
  });
768
- var require_ms2 = (0, import_chunk_WWAWV7DQ.__commonJS)({
769
- "../../node_modules/.pnpm/ms@2.1.3/node_modules/ms/index.js"(exports, module2) {
770
- "use strict";
771
- var s = 1e3;
772
- var m = s * 60;
773
- var h = m * 60;
774
- var d = h * 24;
775
- var w = d * 7;
776
- var y = d * 365.25;
777
- module2.exports = function(val, options) {
778
- options = options || {};
779
- var type = typeof val;
780
- if (type === "string" && val.length > 0) {
781
- return parse(val);
782
- } else if (type === "number" && isFinite(val)) {
783
- return options.long ? fmtLong(val) : fmtShort(val);
784
- }
785
- throw new Error(
786
- "val is not a non-empty string or a valid number. val=" + JSON.stringify(val)
787
- );
788
- };
789
- function parse(str) {
790
- str = String(str);
791
- if (str.length > 100) {
792
- return;
793
- }
794
- var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(
795
- str
796
- );
797
- if (!match) {
798
- return;
799
- }
800
- var n = parseFloat(match[1]);
801
- var type = (match[2] || "ms").toLowerCase();
802
- switch (type) {
803
- case "years":
804
- case "year":
805
- case "yrs":
806
- case "yr":
807
- case "y":
808
- return n * y;
809
- case "weeks":
810
- case "week":
811
- case "w":
812
- return n * w;
813
- case "days":
814
- case "day":
815
- case "d":
816
- return n * d;
817
- case "hours":
818
- case "hour":
819
- case "hrs":
820
- case "hr":
821
- case "h":
822
- return n * h;
823
- case "minutes":
824
- case "minute":
825
- case "mins":
826
- case "min":
827
- case "m":
828
- return n * m;
829
- case "seconds":
830
- case "second":
831
- case "secs":
832
- case "sec":
833
- case "s":
834
- return n * s;
835
- case "milliseconds":
836
- case "millisecond":
837
- case "msecs":
838
- case "msec":
839
- case "ms":
840
- return n;
841
- default:
842
- return void 0;
843
- }
844
- }
845
- function fmtShort(ms) {
846
- var msAbs = Math.abs(ms);
847
- if (msAbs >= d) {
848
- return Math.round(ms / d) + "d";
849
- }
850
- if (msAbs >= h) {
851
- return Math.round(ms / h) + "h";
852
- }
853
- if (msAbs >= m) {
854
- return Math.round(ms / m) + "m";
855
- }
856
- if (msAbs >= s) {
857
- return Math.round(ms / s) + "s";
858
- }
859
- return ms + "ms";
860
- }
861
- function fmtLong(ms) {
862
- var msAbs = Math.abs(ms);
863
- if (msAbs >= d) {
864
- return plural(ms, msAbs, d, "day");
865
- }
866
- if (msAbs >= h) {
867
- return plural(ms, msAbs, h, "hour");
868
- }
869
- if (msAbs >= m) {
870
- return plural(ms, msAbs, m, "minute");
871
- }
872
- if (msAbs >= s) {
873
- return plural(ms, msAbs, s, "second");
874
- }
875
- return ms + " ms";
876
- }
877
- function plural(ms, msAbs, n, name) {
878
- var isPlural = msAbs >= n * 1.5;
879
- return Math.round(ms / n) + " " + name + (isPlural ? "s" : "");
880
- }
881
- }
882
- });
@@ -26,21 +26,21 @@ 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_RYWEOVLN_exports = {};
30
- __export(chunk_RYWEOVLN_exports, {
29
+ var chunk_KHICE54Q_exports = {};
30
+ __export(chunk_KHICE54Q_exports, {
31
31
  DbDrop: () => DbDrop
32
32
  });
33
- module.exports = __toCommonJS(chunk_RYWEOVLN_exports);
33
+ module.exports = __toCommonJS(chunk_KHICE54Q_exports);
34
34
  var import_chunk_WLJHGKMK = require("./chunk-WLJHGKMK.js");
35
35
  var import_chunk_U374EXYQ = require("./chunk-U374EXYQ.js");
36
36
  var import_chunk_EYA6AFSF = require("./chunk-EYA6AFSF.js");
37
37
  var import_chunk_Q7ACZDDT = require("./chunk-Q7ACZDDT.js");
38
- var import_chunk_KEBB7UIB = require("./chunk-KEBB7UIB.js");
38
+ var import_chunk_UQQQ6HXZ = require("./chunk-UQQQ6HXZ.js");
39
39
  var import_chunk_6TE2RIPN = require("./chunk-6TE2RIPN.js");
40
40
  var import_internals = require("@prisma/internals");
41
41
  var import_prompts = __toESM(require("prompts"));
42
42
  (0, import_chunk_6TE2RIPN.init_colors)();
43
- (0, import_chunk_KEBB7UIB.init_ensureDatabaseExists)();
43
+ (0, import_chunk_UQQQ6HXZ.init_ensureDatabaseExists)();
44
44
  (0, import_chunk_U374EXYQ.init_errors)();
45
45
  (0, import_chunk_EYA6AFSF.init_getSchemaPathAndPrint)();
46
46
  (0, import_chunk_Q7ACZDDT.init_printDatasource)();
@@ -70,7 +70,7 @@ var _DbDrop = class _DbDrop2 {
70
70
  }
71
71
  await (0, import_internals.loadEnvFile)({ schemaPath: args["--schema"], printMessage: true });
72
72
  const { schemaPath } = await (0, import_chunk_EYA6AFSF.getSchemaPathAndPrint)(args["--schema"]);
73
- const datasourceInfo = await (0, import_chunk_KEBB7UIB.getDatasourceInfo)({ schemaPath, throwIfEnvError: true });
73
+ const datasourceInfo = await (0, import_chunk_UQQQ6HXZ.getDatasourceInfo)({ schemaPath, throwIfEnvError: true });
74
74
  (0, import_chunk_Q7ACZDDT.printDatasource)({ datasourceInfo });
75
75
  process.stdout.write("\n");
76
76
  if (!args["--force"]) {