@prisma/internals 6.6.0-integration-push-xmzqvqxpztks.11 → 6.6.0-integration-mcp.2

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 (102) hide show
  1. package/dist/Generator.d.ts +5 -23
  2. package/dist/Generator.js +2 -4
  3. package/dist/{chunk-EPXBOIA5.js → chunk-2I3VYCA7.js} +5 -5
  4. package/dist/{chunk-2QTAK7KO.js → chunk-2LDG4PID.js} +5 -5
  5. package/dist/{chunk-JOIIWB3U.js → chunk-2LOGW45F.js} +68 -33
  6. package/dist/{chunk-KB5DKCI4.js → chunk-3GYXMWBM.js} +7 -7
  7. package/dist/{chunk-C36XBSRA.js → chunk-4KCLNFE4.js} +5 -5
  8. package/dist/{chunk-Y4ZCEXKJ.js → chunk-5CBAXTAF.js} +5 -5
  9. package/dist/chunk-72UZXEBG.js +28 -0
  10. package/dist/{chunk-2HN7FYKA.js → chunk-AP52B62F.js} +5 -5
  11. package/dist/{chunk-HG3YOAAE.js → chunk-AXD7KB4D.js} +5 -5
  12. package/dist/chunk-BWGDP6B5.js +4948 -0
  13. package/dist/chunk-DYV47NUW.js +796 -0
  14. package/dist/{chunk-BPDMLM32.js → chunk-DYVL6P7F.js} +13 -46
  15. package/dist/{chunk-DKSUHQGA.js → chunk-EKESIUIK.js} +7 -7
  16. package/dist/chunk-EUTJYQDW.js +46 -0
  17. package/dist/{chunk-3EGV6JCZ.js → chunk-FAPPXX7W.js} +8 -8
  18. package/dist/chunk-GHHABGYW.js +28 -0
  19. package/dist/{chunk-FJR5JRC2.js → chunk-GV244NDE.js} +7 -7
  20. package/dist/{chunk-D4VDA2TZ.js → chunk-IRWX4FCC.js} +6 -6
  21. package/dist/{chunk-IDINCQMN.js → chunk-IWTEX7EE.js} +9 -780
  22. package/dist/{chunk-NVNI2SRU.js → chunk-KNNTV7IN.js} +687 -213
  23. package/dist/{chunk-AO5ASZAS.js → chunk-LWBLVV7Y.js} +8 -8
  24. package/dist/{chunk-5AI4FIZ3.js → chunk-MEOOYUIZ.js} +10 -10
  25. package/dist/{chunk-TQFONRJP.js → chunk-MXAUURHG.js} +5 -5
  26. package/dist/chunk-OQ2NRV2Y.js +35 -0
  27. package/dist/{chunk-YNDF56XR.js → chunk-ORPBIAE5.js} +8 -8
  28. package/dist/{chunk-SHHALVIQ.js → chunk-OUQPIJFQ.js} +5 -5
  29. package/dist/chunk-PE6DXWOX.js +52 -0
  30. package/dist/{chunk-3BVB3DTJ.js → chunk-PING5S2U.js} +8 -8
  31. package/dist/{chunk-2R7JBGUP.js → chunk-PWGQKUJW.js} +200 -85
  32. package/dist/{chunk-CTAL72US.js → chunk-Q2IBLC6D.js} +5 -5
  33. package/dist/{chunk-XG33Y5QX.js → chunk-R45GQNKO.js} +200 -85
  34. package/dist/{chunk-MJIP3FY5.js → chunk-R4ZFFYJA.js} +238 -2502
  35. package/dist/{chunk-7UNYBZSU.js → chunk-RABVZXRU.js} +7 -7
  36. package/dist/{chunk-3DQANJMY.js → chunk-SAAMENIS.js} +7 -7
  37. package/dist/{chunk-57VS7LXW.js → chunk-SNSJWJTA.js} +5 -5
  38. package/dist/{chunk-YR5KNFKN.js → chunk-SUOMIRLO.js} +6 -6
  39. package/dist/{chunk-75BIJ5PX.js → chunk-UB2X7DGZ.js} +9 -9
  40. package/dist/{chunk-BWYO73FG.js → chunk-UFYFNNCN.js} +8 -8
  41. package/dist/{chunk-67I7CEQJ.js → chunk-URRVX2VQ.js} +6 -6
  42. package/dist/{chunk-FUC2LI24.js → chunk-VTJOX6HO.js} +5 -5
  43. package/dist/{chunk-EFNTOXMV.js → chunk-VYJSNZF3.js} +4 -3
  44. package/dist/{chunk-ETYWYJBX.js → chunk-WF5LZFJS.js} +12 -12
  45. package/dist/{chunk-7U7QD73Y.js → chunk-WOIJKMTZ.js} +8 -8
  46. package/dist/{chunk-D6EDE5WT.js → chunk-XMVJRTN5.js} +5 -5
  47. package/dist/{chunk-RSLFYIHN.js → chunk-XRBOJLES.js} +5 -4
  48. package/dist/cli/checkUnsupportedDataProxy.js +44 -37
  49. package/dist/cli/getSchema.js +47 -40
  50. package/dist/cli/hashes.js +44 -37
  51. package/dist/cli/schemaContext.js +44 -37
  52. package/dist/engine-commands/errorHelpers.js +4 -4
  53. package/dist/engine-commands/formatSchema.js +43 -36
  54. package/dist/engine-commands/getConfig.js +10 -10
  55. package/dist/engine-commands/getDmmf.js +7 -7
  56. package/dist/engine-commands/getEngineVersion.js +7 -6
  57. package/dist/engine-commands/getEnginesMetaInfo.js +9 -8
  58. package/dist/engine-commands/index.js +54 -47
  59. package/dist/engine-commands/lintSchema.js +8 -8
  60. package/dist/engine-commands/mergeSchemas.js +7 -7
  61. package/dist/engine-commands/validate.js +7 -7
  62. package/dist/errorReporting.js +6 -6
  63. package/dist/get-generators/generatorResolvers/generatorResolvers.d.ts +15 -0
  64. package/dist/get-generators/generatorResolvers/generatorResolvers.js +139 -0
  65. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/findPrismaClientDir.d.ts +6 -0
  66. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/findPrismaClientDir.js +26 -0
  67. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/getPackageCmd.d.ts +9 -0
  68. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/getPackageCmd.js +26 -0
  69. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/runPackageCmd.d.ts +8 -0
  70. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/runPackageCmd.js +29 -0
  71. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/checkTypeScriptVersion.d.ts +6 -0
  72. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/checkTypeScriptVersion.js +139 -0
  73. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/isYarnUsed.d.ts +1 -0
  74. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/isYarnUsed.js +26 -0
  75. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/resolve.d.ts +20 -0
  76. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/resolve.js +26 -0
  77. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/semverLt.d.ts +7 -0
  78. package/dist/{resolvePkg.js → get-generators/generatorResolvers/prisma-client-js/check-dependencies/semverLt.js} +6 -6
  79. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/semverLt.test.d.ts +1 -0
  80. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/semverLt.test.js +17 -0
  81. package/dist/get-generators/generatorResolvers/prisma-client-js/prismaClientResolver.d.ts +20 -0
  82. package/dist/get-generators/generatorResolvers/prisma-client-js/prismaClientResolver.js +140 -0
  83. package/dist/get-generators/getGenerators.d.ts +9 -18
  84. package/dist/get-generators/getGenerators.js +46 -39
  85. package/dist/get-generators/utils/getBinaryPathsByVersion.js +4 -3
  86. package/dist/getPackedPackage.js +5 -4
  87. package/dist/index.d.ts +4 -2
  88. package/dist/index.js +87 -80
  89. package/dist/{multipart-parser-3AFJFP6K.js → multipart-parser-UV3WZSWW.js} +6 -6
  90. package/dist/resolveBinary.js +8 -7
  91. package/dist/schemaEngineCommands.js +10 -9
  92. package/dist/sendPanic.js +4 -4
  93. package/dist/utils/cloudflareD1.js +3 -3
  94. package/dist/utils/fs-functional.js +10 -10
  95. package/dist/utils/fs-utils.js +8 -8
  96. package/dist/utils/getEnvPaths.js +43 -36
  97. package/dist/utils/getVersionFromPackageJson.js +3 -3
  98. package/dist/utils/handlePanic.js +5 -5
  99. package/dist/utils/loadEnvFile.js +43 -36
  100. package/dist/wasm.js +4 -4
  101. package/package.json +11 -10
  102. package/dist/resolvePkg.d.ts +0 -7
@@ -1,15 +1,13 @@
1
- import type { BinaryPaths, Generator as IGenerator, GeneratorConfig, GeneratorManifest, GeneratorOptions } from '@prisma/generator';
2
- export declare abstract class Generator {
1
+ import type { BinaryPaths, GeneratorConfig, GeneratorManifest, GeneratorOptions } from '@prisma/generator';
2
+ export declare class Generator {
3
+ private generatorProcess;
3
4
  manifest: GeneratorManifest | null;
4
5
  config: GeneratorConfig;
5
6
  options?: GeneratorOptions;
6
- constructor(config: GeneratorConfig);
7
+ constructor(executablePath: string, config: GeneratorConfig, isNode?: boolean);
7
8
  init(): Promise<void>;
8
- protected abstract initImpl(): Promise<void>;
9
- protected abstract getManifest(): Promise<GeneratorManifest | null>;
10
- abstract stop(): void;
9
+ stop(): void;
11
10
  generate(): Promise<void>;
12
- protected abstract generateImpl(options: GeneratorOptions): Promise<void>;
13
11
  setOptions(options: GeneratorOptions): void;
14
12
  setBinaryPaths(binaryPaths: BinaryPaths): void;
15
13
  /**
@@ -24,19 +22,3 @@ export declare abstract class Generator {
24
22
  */
25
23
  getProvider(): string;
26
24
  }
27
- export declare class JsonRpcGenerator extends Generator {
28
- #private;
29
- constructor(executablePath: string, config: GeneratorConfig, isNode?: boolean);
30
- protected initImpl(): Promise<void>;
31
- protected getManifest(): Promise<GeneratorManifest | null>;
32
- protected generateImpl(options: GeneratorOptions): Promise<void>;
33
- stop(): void;
34
- }
35
- export declare class InProcessGenerator extends Generator {
36
- #private;
37
- constructor(config: GeneratorConfig, generator: IGenerator);
38
- protected initImpl(): Promise<void>;
39
- protected getManifest(): Promise<GeneratorManifest | null>;
40
- protected generateImpl(options: GeneratorOptions): Promise<void>;
41
- stop(): void;
42
- }
package/dist/Generator.js CHANGED
@@ -18,12 +18,10 @@ var __copyProps = (to, from, except, desc) => {
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
19
  var Generator_exports = {};
20
20
  __export(Generator_exports, {
21
- Generator: () => import_chunk_BPDMLM32.Generator,
22
- InProcessGenerator: () => import_chunk_BPDMLM32.InProcessGenerator,
23
- JsonRpcGenerator: () => import_chunk_BPDMLM32.JsonRpcGenerator
21
+ Generator: () => import_chunk_DYVL6P7F.Generator
24
22
  });
25
23
  module.exports = __toCommonJS(Generator_exports);
26
- var import_chunk_BPDMLM32 = require("./chunk-BPDMLM32.js");
24
+ var import_chunk_DYVL6P7F = require("./chunk-DYVL6P7F.js");
27
25
  var import_chunk_IOIAK7V7 = require("./chunk-IOIAK7V7.js");
28
26
  var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
29
27
  var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
@@ -26,21 +26,21 @@ var __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create(__g
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_EPXBOIA5_exports = {};
30
- __export(chunk_EPXBOIA5_exports, {
29
+ var chunk_2I3VYCA7_exports = {};
30
+ __export(chunk_2I3VYCA7_exports, {
31
31
  getBinaryPathsByVersion: () => getBinaryPathsByVersion
32
32
  });
33
- module.exports = __toCommonJS(chunk_EPXBOIA5_exports);
33
+ module.exports = __toCommonJS(chunk_2I3VYCA7_exports);
34
34
  var import_chunk_RS2R7COT = require("./chunk-RS2R7COT.js");
35
35
  var import_chunk_4CGPN5SR = require("./chunk-4CGPN5SR.js");
36
36
  var import_chunk_2SDPW6AX = require("./chunk-2SDPW6AX.js");
37
37
  var import_chunk_7B5PXS6N = require("./chunk-7B5PXS6N.js");
38
- var import_chunk_IDINCQMN = require("./chunk-IDINCQMN.js");
38
+ var import_chunk_IWTEX7EE = require("./chunk-IWTEX7EE.js");
39
39
  var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
40
40
  var import_engines = require("@prisma/engines");
41
41
  var import_fetch_engine = require("@prisma/fetch-engine");
42
42
  var import_path = __toESM2(require("path"));
43
- var import_fs_extra = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_IDINCQMN.require_lib)());
43
+ var import_fs_extra = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_IWTEX7EE.require_lib)());
44
44
  async function getBinaryPathsByVersion({
45
45
  neededVersions,
46
46
  binaryTarget,
@@ -26,15 +26,15 @@ 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_2QTAK7KO_exports = {};
30
- __export(chunk_2QTAK7KO_exports, {
29
+ var chunk_2LDG4PID_exports = {};
30
+ __export(chunk_2LDG4PID_exports, {
31
31
  handlePanic: () => handlePanic
32
32
  });
33
- module.exports = __toCommonJS(chunk_2QTAK7KO_exports);
33
+ module.exports = __toCommonJS(chunk_2LDG4PID_exports);
34
34
  var import_chunk_HAGJ64PM = require("./chunk-HAGJ64PM.js");
35
35
  var import_chunk_FXMGS3L5 = require("./chunk-FXMGS3L5.js");
36
36
  var import_chunk_R3J2O23S = require("./chunk-R3J2O23S.js");
37
- var import_chunk_YR5KNFKN = require("./chunk-YR5KNFKN.js");
37
+ var import_chunk_SUOMIRLO = require("./chunk-SUOMIRLO.js");
38
38
  var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
39
39
  var import_prompts = __toESM(require("prompts"));
40
40
  async function handlePanic(args) {
@@ -79,7 +79,7 @@ ${(0, import_chunk_PG5FDKSF.dim)(`Learn more: ${(0, import_chunk_HAGJ64PM.link)(
79
79
  if (shouldSubmitReport) {
80
80
  try {
81
81
  console.log("Submitting...");
82
- const reportId = await (0, import_chunk_YR5KNFKN.sendPanic)({ error, cliVersion, enginesVersion, getDatabaseVersionSafe });
82
+ const reportId = await (0, import_chunk_SUOMIRLO.sendPanic)({ error, cliVersion, enginesVersion, getDatabaseVersionSafe });
83
83
  console.log(`
84
84
  ${(0, import_chunk_PG5FDKSF.bold)(`We successfully received the error report id: ${reportId}`)}`);
85
85
  console.log(`
@@ -16,14 +16,14 @@ 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_JOIIWB3U_exports = {};
20
- __export(chunk_JOIIWB3U_exports, {
19
+ var chunk_2LOGW45F_exports = {};
20
+ __export(chunk_2LOGW45F_exports, {
21
21
  require_globby: () => require_globby,
22
22
  require_is_glob: () => require_is_glob,
23
23
  require_out: () => require_out4,
24
24
  require_slash: () => require_slash
25
25
  });
26
- module.exports = __toCommonJS(chunk_JOIIWB3U_exports);
26
+ module.exports = __toCommonJS(chunk_2LOGW45F_exports);
27
27
  var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
28
28
  var require_array = (0, import_chunk_4VNS5WPM.__commonJS)({
29
29
  "../../node_modules/.pnpm/fast-glob@3.3.3/node_modules/fast-glob/out/utils/array.js"(exports) {
@@ -3964,7 +3964,7 @@ var require_out2 = (0, import_chunk_4VNS5WPM.__commonJS)({
3964
3964
  }
3965
3965
  });
3966
3966
  var require_reusify = (0, import_chunk_4VNS5WPM.__commonJS)({
3967
- "../../node_modules/.pnpm/reusify@1.0.4/node_modules/reusify/reusify.js"(exports, module2) {
3967
+ "../../node_modules/.pnpm/reusify@1.1.0/node_modules/reusify/reusify.js"(exports, module2) {
3968
3968
  "use strict";
3969
3969
  function reusify(Constructor) {
3970
3970
  var head = new Constructor();
@@ -3993,17 +3993,17 @@ var require_reusify = (0, import_chunk_4VNS5WPM.__commonJS)({
3993
3993
  }
3994
3994
  });
3995
3995
  var require_queue = (0, import_chunk_4VNS5WPM.__commonJS)({
3996
- "../../node_modules/.pnpm/fastq@1.15.0/node_modules/fastq/queue.js"(exports, module2) {
3996
+ "../../node_modules/.pnpm/fastq@1.19.1/node_modules/fastq/queue.js"(exports, module2) {
3997
3997
  "use strict";
3998
3998
  var reusify = require_reusify();
3999
- function fastqueue(context, worker, concurrency) {
3999
+ function fastqueue(context, worker, _concurrency) {
4000
4000
  if (typeof context === "function") {
4001
- concurrency = worker;
4001
+ _concurrency = worker;
4002
4002
  worker = context;
4003
4003
  context = null;
4004
4004
  }
4005
- if (concurrency < 1) {
4006
- throw new Error("fastqueue concurrency must be greater than 1");
4005
+ if (!(_concurrency >= 1)) {
4006
+ throw new Error("fastqueue concurrency must be equal to or greater than 1");
4007
4007
  }
4008
4008
  var cache = reusify(Task);
4009
4009
  var queueHead = null;
@@ -4016,7 +4016,20 @@ var require_queue = (0, import_chunk_4VNS5WPM.__commonJS)({
4016
4016
  saturated: noop,
4017
4017
  pause,
4018
4018
  paused: false,
4019
- concurrency,
4019
+ get concurrency() {
4020
+ return _concurrency;
4021
+ },
4022
+ set concurrency(value) {
4023
+ if (!(value >= 1)) {
4024
+ throw new Error("fastqueue concurrency must be equal to or greater than 1");
4025
+ }
4026
+ _concurrency = value;
4027
+ if (self.paused) return;
4028
+ for (; queueHead && _running < _concurrency; ) {
4029
+ _running++;
4030
+ release();
4031
+ }
4032
+ },
4020
4033
  running,
4021
4034
  resume,
4022
4035
  idle,
@@ -4056,7 +4069,12 @@ var require_queue = (0, import_chunk_4VNS5WPM.__commonJS)({
4056
4069
  function resume() {
4057
4070
  if (!self.paused) return;
4058
4071
  self.paused = false;
4059
- for (var i = 0; i < self.concurrency; i++) {
4072
+ if (queueHead === null) {
4073
+ _running++;
4074
+ release();
4075
+ return;
4076
+ }
4077
+ for (; queueHead && _running < _concurrency; ) {
4060
4078
  _running++;
4061
4079
  release();
4062
4080
  }
@@ -4071,7 +4089,7 @@ var require_queue = (0, import_chunk_4VNS5WPM.__commonJS)({
4071
4089
  current.value = value;
4072
4090
  current.callback = done || noop;
4073
4091
  current.errorHandler = errorHandler;
4074
- if (_running === self.concurrency || self.paused) {
4092
+ if (_running >= _concurrency || self.paused) {
4075
4093
  if (queueTail) {
4076
4094
  queueTail.next = current;
4077
4095
  queueTail = current;
@@ -4091,7 +4109,8 @@ var require_queue = (0, import_chunk_4VNS5WPM.__commonJS)({
4091
4109
  current.release = release;
4092
4110
  current.value = value;
4093
4111
  current.callback = done || noop;
4094
- if (_running === self.concurrency || self.paused) {
4112
+ current.errorHandler = errorHandler;
4113
+ if (_running >= _concurrency || self.paused) {
4095
4114
  if (queueHead) {
4096
4115
  current.next = queueHead;
4097
4116
  queueHead = current;
@@ -4110,7 +4129,7 @@ var require_queue = (0, import_chunk_4VNS5WPM.__commonJS)({
4110
4129
  cache.release(holder);
4111
4130
  }
4112
4131
  var next = queueHead;
4113
- if (next) {
4132
+ if (next && _running <= _concurrency) {
4114
4133
  if (!self.paused) {
4115
4134
  if (queueTail === queueHead) {
4116
4135
  queueTail = null;
@@ -4166,9 +4185,9 @@ var require_queue = (0, import_chunk_4VNS5WPM.__commonJS)({
4166
4185
  self.release(self);
4167
4186
  };
4168
4187
  }
4169
- function queueAsPromised(context, worker, concurrency) {
4188
+ function queueAsPromised(context, worker, _concurrency) {
4170
4189
  if (typeof context === "function") {
4171
- concurrency = worker;
4190
+ _concurrency = worker;
4172
4191
  worker = context;
4173
4192
  context = null;
4174
4193
  }
@@ -4177,7 +4196,7 @@ var require_queue = (0, import_chunk_4VNS5WPM.__commonJS)({
4177
4196
  cb(null, res);
4178
4197
  }, cb);
4179
4198
  }
4180
- var queue = fastqueue(context, asyncWrapper, concurrency);
4199
+ var queue = fastqueue(context, asyncWrapper, _concurrency);
4181
4200
  var pushCb = queue.push;
4182
4201
  var unshiftCb = queue.unshift;
4183
4202
  queue.push = push;
@@ -4211,17 +4230,19 @@ var require_queue = (0, import_chunk_4VNS5WPM.__commonJS)({
4211
4230
  return p;
4212
4231
  }
4213
4232
  function drained() {
4214
- if (queue.idle()) {
4215
- return new Promise(function(resolve) {
4216
- resolve();
4217
- });
4218
- }
4219
- var previousDrain = queue.drain;
4220
4233
  var p = new Promise(function(resolve) {
4221
- queue.drain = function() {
4222
- previousDrain();
4223
- resolve();
4224
- };
4234
+ process.nextTick(function() {
4235
+ if (queue.idle()) {
4236
+ resolve();
4237
+ } else {
4238
+ var previousDrain = queue.drain;
4239
+ queue.drain = function() {
4240
+ if (typeof previousDrain === "function") previousDrain();
4241
+ resolve();
4242
+ queue.drain = previousDrain;
4243
+ };
4244
+ }
4245
+ });
4225
4246
  });
4226
4247
  return p;
4227
4248
  }
@@ -5461,7 +5482,7 @@ var require_dir_glob = (0, import_chunk_4VNS5WPM.__commonJS)({
5461
5482
  }
5462
5483
  });
5463
5484
  var require_ignore = (0, import_chunk_4VNS5WPM.__commonJS)({
5464
- "../../node_modules/.pnpm/ignore@5.2.4/node_modules/ignore/index.js"(exports, module2) {
5485
+ "../../node_modules/.pnpm/ignore@5.3.2/node_modules/ignore/index.js"(exports, module2) {
5465
5486
  "use strict";
5466
5487
  function makeArray(subject) {
5467
5488
  return Array.isArray(subject) ? subject : [subject];
@@ -5493,18 +5514,32 @@ var require_ignore = (0, import_chunk_4VNS5WPM.__commonJS)({
5493
5514
  return slashes.slice(0, length - length % 2);
5494
5515
  };
5495
5516
  var REPLACERS = [
5517
+ [
5518
+ // remove BOM
5519
+ // TODO:
5520
+ // Other similar zero-width characters?
5521
+ /^\uFEFF/,
5522
+ () => EMPTY
5523
+ ],
5496
5524
  // > Trailing spaces are ignored unless they are quoted with backslash ("\")
5497
5525
  [
5498
5526
  // (a\ ) -> (a )
5499
5527
  // (a ) -> (a)
5528
+ // (a ) -> (a)
5500
5529
  // (a \ ) -> (a )
5501
- /\\?\s+$/,
5502
- (match) => match.indexOf("\\") === 0 ? SPACE : EMPTY
5530
+ /((?:\\\\)*?)(\\?\s+)$/,
5531
+ (_, m1, m2) => m1 + (m2.indexOf("\\") === 0 ? SPACE : EMPTY)
5503
5532
  ],
5504
5533
  // replace (\ ) with ' '
5534
+ // (\ ) -> ' '
5535
+ // (\\ ) -> '\\ '
5536
+ // (\\\ ) -> '\\ '
5505
5537
  [
5506
- /\\\s/g,
5507
- () => SPACE
5538
+ /(\\+?)\s/g,
5539
+ (_, m1) => {
5540
+ const { length } = m1;
5541
+ return m1.slice(0, length - length % 2) + SPACE;
5542
+ }
5508
5543
  ],
5509
5544
  // Escape metacharacters
5510
5545
  // which is written down by users but means special for regular expressions.
@@ -5639,7 +5674,7 @@ var require_ignore = (0, import_chunk_4VNS5WPM.__commonJS)({
5639
5674
  let source = regexCache[pattern];
5640
5675
  if (!source) {
5641
5676
  source = REPLACERS.reduce(
5642
- (prev, current) => prev.replace(current[0], current[1].bind(pattern)),
5677
+ (prev, [matcher, replacer]) => prev.replace(matcher, replacer.bind(pattern)),
5643
5678
  pattern
5644
5679
  );
5645
5680
  regexCache[pattern] = source;
@@ -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_KB5DKCI4_exports = {};
30
- __export(chunk_KB5DKCI4_exports, {
29
+ var chunk_3GYXMWBM_exports = {};
30
+ __export(chunk_3GYXMWBM_exports, {
31
31
  getEnginesInfo: () => getEnginesInfo,
32
32
  getEnginesMetaInfo: () => getEnginesMetaInfo,
33
33
  resolveEngine: () => resolveEngine
34
34
  });
35
- module.exports = __toCommonJS(chunk_KB5DKCI4_exports);
36
- var import_chunk_3DQANJMY = require("./chunk-3DQANJMY.js");
35
+ module.exports = __toCommonJS(chunk_3GYXMWBM_exports);
36
+ var import_chunk_SAAMENIS = require("./chunk-SAAMENIS.js");
37
37
  var import_chunk_R6QH57HZ = require("./chunk-R6QH57HZ.js");
38
- var import_chunk_HG3YOAAE = require("./chunk-HG3YOAAE.js");
38
+ var import_chunk_AXD7KB4D = require("./chunk-AXD7KB4D.js");
39
39
  var import_chunk_5DBOS77Y = require("./chunk-5DBOS77Y.js");
40
40
  var import_chunk_XKZ6CBLA = require("./chunk-XKZ6CBLA.js");
41
41
  var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
@@ -157,7 +157,7 @@ async function resolveEngine(binaryName) {
157
157
  const enginePathEither = await (0, import_function2.pipe)(
158
158
  pathFromEnvOption,
159
159
  fold(
160
- () => (0, import_chunk_HG3YOAAE.safeResolveBinary)(binaryName),
160
+ () => (0, import_chunk_AXD7KB4D.safeResolveBinary)(binaryName),
161
161
  (pathFromEnv) => (0, import_chunk_5DBOS77Y.right2)(pathFromEnv.path)
162
162
  )
163
163
  )();
@@ -165,7 +165,7 @@ async function resolveEngine(binaryName) {
165
165
  enginePathEither,
166
166
  import_chunk_5DBOS77Y.fromEither,
167
167
  (0, import_chunk_5DBOS77Y.chain)((enginePath) => {
168
- return (0, import_chunk_3DQANJMY.safeGetEngineVersion)(enginePath, binaryName);
168
+ return (0, import_chunk_SAAMENIS.safeGetEngineVersion)(enginePath, binaryName);
169
169
  })
170
170
  )();
171
171
  const engineInfo = {
@@ -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_C36XBSRA_exports = {};
30
- __export(chunk_C36XBSRA_exports, {
29
+ var chunk_4KCLNFE4_exports = {};
30
+ __export(chunk_4KCLNFE4_exports, {
31
31
  prismaSchemaWasm: () => import_prisma_schema_wasm.default,
32
32
  prismaSchemaWasmVersion: () => prismaSchemaWasmVersion,
33
33
  wasm_exports: () => wasm_exports
34
34
  });
35
- module.exports = __toCommonJS(chunk_C36XBSRA_exports);
36
- var import_chunk_RSLFYIHN = require("./chunk-RSLFYIHN.js");
35
+ module.exports = __toCommonJS(chunk_4KCLNFE4_exports);
36
+ var import_chunk_XRBOJLES = require("./chunk-XRBOJLES.js");
37
37
  var import_chunk_WXRVYSYN = require("./chunk-WXRVYSYN.js");
38
38
  var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
39
39
  var import_prisma_schema_wasm = __toESM(require("@prisma/prisma-schema-wasm"));
@@ -42,6 +42,6 @@ var wasm_exports = {};
42
42
  prismaSchemaWasm: () => import_prisma_schema_wasm.default,
43
43
  prismaSchemaWasmVersion: () => prismaSchemaWasmVersion
44
44
  });
45
- var { dependencies } = (0, import_chunk_RSLFYIHN.require_package)();
45
+ var { dependencies } = (0, import_chunk_XRBOJLES.require_package)();
46
46
  var prismaSchemaWasmVersion = dependencies["@prisma/prisma-schema-wasm"];
47
47
  globalThis.PRISMA_WASM_PANIC_REGISTRY = new import_chunk_WXRVYSYN.WasmPanicRegistry();
@@ -16,20 +16,20 @@ 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_Y4ZCEXKJ_exports = {};
20
- __export(chunk_Y4ZCEXKJ_exports, {
19
+ var chunk_5CBAXTAF_exports = {};
20
+ __export(chunk_5CBAXTAF_exports, {
21
21
  getLintWarnings: () => getLintWarnings,
22
22
  getLintWarningsAsText: () => getLintWarningsAsText,
23
23
  handleLintPanic: () => handleLintPanic,
24
24
  lintSchema: () => lintSchema,
25
25
  warningToString: () => warningToString
26
26
  });
27
- module.exports = __toCommonJS(chunk_Y4ZCEXKJ_exports);
28
- var import_chunk_57VS7LXW = require("./chunk-57VS7LXW.js");
27
+ module.exports = __toCommonJS(chunk_5CBAXTAF_exports);
28
+ var import_chunk_4KCLNFE4 = require("./chunk-4KCLNFE4.js");
29
29
  var import_chunk_LMVSIVKQ = require("./chunk-LMVSIVKQ.js");
30
30
  var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
31
31
  function lintSchema({ schemas }) {
32
- const lintResult = import_chunk_57VS7LXW.prismaSchemaWasm.lint(JSON.stringify(schemas));
32
+ const lintResult = import_chunk_4KCLNFE4.prismaSchemaWasm.lint(JSON.stringify(schemas));
33
33
  const lintDiagnostics = JSON.parse(lintResult);
34
34
  return lintDiagnostics;
35
35
  }
@@ -0,0 +1,28 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+ var chunk_72UZXEBG_exports = {};
20
+ __export(chunk_72UZXEBG_exports, {
21
+ getPackageCmd: () => getPackageCmd
22
+ });
23
+ module.exports = __toCommonJS(chunk_72UZXEBG_exports);
24
+ var import_chunk_BWGDP6B5 = require("./chunk-BWGDP6B5.js");
25
+ async function getPackageCmd(cwd, cmd, ...args) {
26
+ const agent = await (0, import_chunk_BWGDP6B5.detect)({ autoInstall: false, cwd, programmatic: true });
27
+ return (0, import_chunk_BWGDP6B5.getCommand)(agent ?? "npm", cmd, args);
28
+ }
@@ -16,15 +16,15 @@ 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_2HN7FYKA_exports = {};
20
- __export(chunk_2HN7FYKA_exports, {
19
+ var chunk_AP52B62F_exports = {};
20
+ __export(chunk_AP52B62F_exports, {
21
21
  addVersionDetailsToErrorMessage: () => addVersionDetailsToErrorMessage
22
22
  });
23
- module.exports = __toCommonJS(chunk_2HN7FYKA_exports);
24
- var import_chunk_FUC2LI24 = require("./chunk-FUC2LI24.js");
23
+ module.exports = __toCommonJS(chunk_AP52B62F_exports);
24
+ var import_chunk_VTJOX6HO = require("./chunk-VTJOX6HO.js");
25
25
  var import_chunk_QN6PSQY7 = require("./chunk-QN6PSQY7.js");
26
26
  function addVersionDetailsToErrorMessage(message) {
27
- const rows = [["Prisma CLI Version", import_chunk_FUC2LI24.version]];
27
+ const rows = [["Prisma CLI Version", import_chunk_VTJOX6HO.version]];
28
28
  return `${message}
29
29
 
30
30
  ${(0, import_chunk_QN6PSQY7.formatTable)(rows)}`;
@@ -26,17 +26,17 @@ var __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create(__g
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_HG3YOAAE_exports = {};
30
- __export(chunk_HG3YOAAE_exports, {
29
+ var chunk_AXD7KB4D_exports = {};
30
+ __export(chunk_AXD7KB4D_exports, {
31
31
  BinaryType: () => import_fetch_engine.BinaryType,
32
32
  engineEnvVarMap: () => import_fetch_engine.engineEnvVarMap,
33
33
  maybeCopyToTmp: () => maybeCopyToTmp,
34
34
  resolveBinary: () => resolveBinary,
35
35
  safeResolveBinary: () => safeResolveBinary
36
36
  });
37
- module.exports = __toCommonJS(chunk_HG3YOAAE_exports);
37
+ module.exports = __toCommonJS(chunk_AXD7KB4D_exports);
38
38
  var import_chunk_M3GBKLGE = require("./chunk-M3GBKLGE.js");
39
- var import_chunk_IDINCQMN = require("./chunk-IDINCQMN.js");
39
+ var import_chunk_IWTEX7EE = require("./chunk-IWTEX7EE.js");
40
40
  var import_chunk_TWSLDIFL = require("./chunk-TWSLDIFL.js");
41
41
  var import_chunk_5DBOS77Y = require("./chunk-5DBOS77Y.js");
42
42
  var import_chunk_5VQNKCKW = require("./chunk-5VQNKCKW.js");
@@ -46,7 +46,7 @@ var import_fetch_engine = require("@prisma/fetch-engine");
46
46
  var import_get_platform = require("@prisma/get-platform");
47
47
  var import_fs = __toESM2(require("fs"));
48
48
  var import_path = __toESM2(require("path"));
49
- var import_fs_extra = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_IDINCQMN.require_lib)());
49
+ var import_fs_extra = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_IWTEX7EE.require_lib)());
50
50
  var import_temp_dir = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_5VQNKCKW.require_temp_dir)());
51
51
  async function getBinaryName(name) {
52
52
  const binaryTarget = await (0, import_get_platform.getBinaryTargetForCurrentPlatform)();