@ohos-ports/prisma-internals 7.10.0-beta.0
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.
- package/LICENSE +201 -0
- package/dist/Generator.d.ts +42 -0
- package/dist/Generator.js +29 -0
- package/dist/WasmPanicRegistry.d.ts +5 -0
- package/dist/WasmPanicRegistry.js +25 -0
- package/dist/WasmSchemaEngineLoader.d.ts +5 -0
- package/dist/WasmSchemaEngineLoader.js +25 -0
- package/dist/built-in-provider.d.ts +5 -0
- package/dist/built-in-provider.js +25 -0
- package/dist/chunk-2B26F5N3.js +72 -0
- package/dist/chunk-2IOZUH3U.js +26 -0
- package/dist/chunk-2SDPW6AX.js +39 -0
- package/dist/chunk-3IMRWXIL.js +176 -0
- package/dist/chunk-3TYD3ZGQ.js +115 -0
- package/dist/chunk-3U4QB2G3.js +166 -0
- package/dist/chunk-3VD46SL7.js +151 -0
- package/dist/chunk-3YOF262C.js +176 -0
- package/dist/chunk-3ZHE2IX4.js +55 -0
- package/dist/chunk-4VNS5WPM.js +61 -0
- package/dist/chunk-5AI4FIZ3.js +1342 -0
- package/dist/chunk-5BDP445D.js +51 -0
- package/dist/chunk-5DBOS77Y.js +609 -0
- package/dist/chunk-5FJ3MENK.js +30 -0
- package/dist/chunk-5I4ERIIY.js +30 -0
- package/dist/chunk-5PJQQKQI.js +106 -0
- package/dist/chunk-5VQNKCKW.js +38 -0
- package/dist/chunk-5WRIOIZY.js +31 -0
- package/dist/chunk-6JE6QGSJ.js +37 -0
- package/dist/chunk-6PWHYRKR.js +74 -0
- package/dist/chunk-6QMQ2JYG.js +122 -0
- package/dist/chunk-6Z766KGR.js +95 -0
- package/dist/chunk-74RGCSUJ.js +44 -0
- package/dist/chunk-7B5PXS6N.js +29 -0
- package/dist/chunk-ANU3HEGF.js +29 -0
- package/dist/chunk-BERN76ZI.js +347 -0
- package/dist/chunk-BGMZPA2F.js +39 -0
- package/dist/chunk-BPDMLM32.js +105 -0
- package/dist/chunk-C47SCASR.js +37 -0
- package/dist/chunk-CGFNDGGI.js +40 -0
- package/dist/chunk-CTQD6OLG.js +438 -0
- package/dist/chunk-CUD726EK.js +36 -0
- package/dist/chunk-CXEXLFVL.js +166 -0
- package/dist/chunk-CYAS6B5N.js +48 -0
- package/dist/chunk-D4VZUY3O.js +71 -0
- package/dist/chunk-DODIJPCS.js +34 -0
- package/dist/chunk-DTPFRZWV.js +31 -0
- package/dist/chunk-DUDEWDFC.js +101 -0
- package/dist/chunk-DZ4QWHTB.js +127 -0
- package/dist/chunk-E23HYCQJ.js +37 -0
- package/dist/chunk-E476ARWS.js +2091 -0
- package/dist/chunk-EKGEKB22.js +28 -0
- package/dist/chunk-EU6UOKRD.js +26 -0
- package/dist/chunk-EWPXLBGE.js +115 -0
- package/dist/chunk-FCYHZHVW.js +43 -0
- package/dist/chunk-FRVJZOHP.js +1823 -0
- package/dist/chunk-GJSFP4V4.js +30 -0
- package/dist/chunk-GXW4NTU2.js +34 -0
- package/dist/chunk-H4NI2RIK.js +35 -0
- package/dist/chunk-HHG4DGHC.js +496 -0
- package/dist/chunk-HPVMQFIY.js +407 -0
- package/dist/chunk-I2CBQZJY.js +122 -0
- package/dist/chunk-I4K46RGG.js +31 -0
- package/dist/chunk-I6WLABB2.js +429 -0
- package/dist/chunk-ICFLO5JW.js +26 -0
- package/dist/chunk-IL7PSY44.js +26 -0
- package/dist/chunk-IOIAK7V7.js +53 -0
- package/dist/chunk-IYN5VKMD.js +110 -0
- package/dist/chunk-J77ZIDXB.js +69 -0
- package/dist/chunk-J7ZPY2XA.js +47 -0
- package/dist/chunk-JFXHOFJA.js +46 -0
- package/dist/chunk-JOIHHXR6.js +2067 -0
- package/dist/chunk-JPZYSRK3.js +6412 -0
- package/dist/chunk-JTKAT4KZ.js +26 -0
- package/dist/chunk-K2EOOA2X.js +91 -0
- package/dist/chunk-KDP6C3CB.js +56 -0
- package/dist/chunk-L3LDE52J.js +51 -0
- package/dist/chunk-L6V54WGO.js +39 -0
- package/dist/chunk-LMVSIVKQ.js +62 -0
- package/dist/chunk-LPNBWFQ3.js +38 -0
- package/dist/chunk-LRBXMV4B.js +26 -0
- package/dist/chunk-LRU47BGE.js +78 -0
- package/dist/chunk-M3GBKLGE.js +24 -0
- package/dist/chunk-MCS5ZY6Y.js +27 -0
- package/dist/chunk-NBWRGVYR.js +47 -0
- package/dist/chunk-NIWBAJZV.js +36 -0
- package/dist/chunk-NTDBN2N2.js +104 -0
- package/dist/chunk-NVNI2SRU.js +4230 -0
- package/dist/chunk-OIVPX3BR.js +32 -0
- package/dist/chunk-PFYALFCY.js +26 -0
- package/dist/chunk-PG5FDKSF.js +79 -0
- package/dist/chunk-PKF53VLJ.js +26 -0
- package/dist/chunk-PTPRBA7K.js +6675 -0
- package/dist/chunk-QBNYSYZK.js +74 -0
- package/dist/chunk-QMNPESAP.js +124 -0
- package/dist/chunk-QN6PSQY7.js +37 -0
- package/dist/chunk-QVJ2BXKF.js +3997 -0
- package/dist/chunk-R47SFJ5Z.js +104 -0
- package/dist/chunk-R6QH57HZ.js +311 -0
- package/dist/chunk-RBDYOTWB.js +193 -0
- package/dist/chunk-SBUSVJCV.js +62 -0
- package/dist/chunk-SP2ETLT2.js +41 -0
- package/dist/chunk-TPCPXGC5.js +218 -0
- package/dist/chunk-TWSLDIFL.js +48 -0
- package/dist/chunk-UGR6KLZN.js +30 -0
- package/dist/chunk-UMM35VP5.js +1193 -0
- package/dist/chunk-VFNP7Q3Y.js +15529 -0
- package/dist/chunk-VNIE2AZB.js +41 -0
- package/dist/chunk-VUGB2H7M.js +438 -0
- package/dist/chunk-WFMA7DI5.js +92 -0
- package/dist/chunk-WV4QHCSM.js +26 -0
- package/dist/chunk-WXRVYSYN.js +33 -0
- package/dist/chunk-X3P4J7WW.js +28 -0
- package/dist/chunk-X77CS5RK.js +33 -0
- package/dist/chunk-XAAVALN7.js +110 -0
- package/dist/chunk-XXTPN4LB.js +41 -0
- package/dist/chunk-XYCIH36R.js +29 -0
- package/dist/chunk-Y4TOGY6I.js +30 -0
- package/dist/chunk-YNDZCLVL.js +307 -0
- package/dist/chunk-YXB6APHS.js +447 -0
- package/dist/chunk-ZJWZK45Z.js +68 -0
- package/dist/chunk-ZKWDIAVF.js +29 -0
- package/dist/cli/Help.d.ts +11 -0
- package/dist/cli/Help.js +27 -0
- package/dist/cli/checkUnsupportedDataProxy.d.ts +16 -0
- package/dist/cli/checkUnsupportedDataProxy.js +125 -0
- package/dist/cli/completion-values.d.ts +24 -0
- package/dist/cli/completion-values.js +47 -0
- package/dist/cli/directoryConfig.d.ts +11 -0
- package/dist/cli/directoryConfig.js +25 -0
- package/dist/cli/getGeneratorSuccessMessage.d.ts +7 -0
- package/dist/cli/getGeneratorSuccessMessage.js +29 -0
- package/dist/cli/getSchema.d.ts +46 -0
- package/dist/cli/getSchema.js +31 -0
- package/dist/cli/getTypescriptVersion.d.ts +1 -0
- package/dist/cli/getTypescriptVersion.js +25 -0
- package/dist/cli/hashes.d.ts +11 -0
- package/dist/cli/hashes.js +28 -0
- package/dist/cli/schemaContext.d.ts +56 -0
- package/dist/cli/schemaContext.js +126 -0
- package/dist/cli/types.d.ts +63 -0
- package/dist/cli/types.js +1 -0
- package/dist/cli/utils.d.ts +13 -0
- package/dist/cli/utils.js +27 -0
- package/dist/convertCredentials.d.ts +10 -0
- package/dist/convertCredentials.js +28 -0
- package/dist/engine-commands/errorHelpers.d.ts +4 -0
- package/dist/engine-commands/errorHelpers.js +28 -0
- package/dist/engine-commands/formatSchema.d.ts +22 -0
- package/dist/engine-commands/formatSchema.js +124 -0
- package/dist/engine-commands/getConfig.d.ts +27 -0
- package/dist/engine-commands/getConfig.js +39 -0
- package/dist/engine-commands/getDmmf.d.ts +21 -0
- package/dist/engine-commands/getDmmf.js +40 -0
- package/dist/engine-commands/getEngineVersion.d.ts +4 -0
- package/dist/engine-commands/getEngineVersion.js +33 -0
- package/dist/engine-commands/getEnginesInfo.d.ts +20 -0
- package/dist/engine-commands/getEnginesInfo.js +36 -0
- package/dist/engine-commands/index.d.ts +10 -0
- package/dist/engine-commands/index.js +136 -0
- package/dist/engine-commands/lintSchema.d.ts +26 -0
- package/dist/engine-commands/lintSchema.js +34 -0
- package/dist/engine-commands/mergeSchemas.d.ts +12 -0
- package/dist/engine-commands/mergeSchemas.js +39 -0
- package/dist/engine-commands/queryEngineCommons.d.ts +31 -0
- package/dist/engine-commands/queryEngineCommons.js +33 -0
- package/dist/engine-commands/relativizePathInPSLError.d.ts +1 -0
- package/dist/engine-commands/relativizePathInPSLError.js +25 -0
- package/dist/engine-commands/validate.d.ts +12 -0
- package/dist/engine-commands/validate.js +39 -0
- package/dist/errorReporting.d.ts +25 -0
- package/dist/errorReporting.js +29 -0
- package/dist/get-generators/getGenerators.d.ts +71 -0
- package/dist/get-generators/getGenerators.js +127 -0
- package/dist/get-generators/utils/binaryTypeToEngineType.d.ts +3 -0
- package/dist/get-generators/utils/binaryTypeToEngineType.js +25 -0
- package/dist/get-generators/utils/engineTypeToBinaryType.d.ts +3 -0
- package/dist/get-generators/utils/engineTypeToBinaryType.js +25 -0
- package/dist/get-generators/utils/fixBinaryTargets.d.ts +3 -0
- package/dist/get-generators/utils/fixBinaryTargets.js +25 -0
- package/dist/get-generators/utils/getBinaryPathsByVersion.d.ts +7 -0
- package/dist/get-generators/utils/getBinaryPathsByVersion.js +30 -0
- package/dist/get-generators/utils/getEngineVersionForGenerator.d.ts +2 -0
- package/dist/get-generators/utils/getEngineVersionForGenerator.js +25 -0
- package/dist/get-generators/utils/printGeneratorConfig.d.ts +9 -0
- package/dist/get-generators/utils/printGeneratorConfig.js +29 -0
- package/dist/getPackedPackage.d.ts +1 -0
- package/dist/getPackedPackage.js +29 -0
- package/dist/highlight/highlight.d.ts +3 -0
- package/dist/highlight/highlight.js +32 -0
- package/dist/highlight/languages/dml.d.ts +2 -0
- package/dist/highlight/languages/dml.js +25 -0
- package/dist/highlight/languages/sql.d.ts +2 -0
- package/dist/highlight/languages/sql.js +25 -0
- package/dist/highlight/prism.d.ts +6 -0
- package/dist/highlight/prism.js +28 -0
- package/dist/highlight/theme.d.ts +2 -0
- package/dist/highlight/theme.js +26 -0
- package/dist/highlight/types.d.ts +35 -0
- package/dist/highlight/types.js +1 -0
- package/dist/index.d.ts +80 -0
- package/dist/index.js +257 -0
- package/dist/logger.d.ts +14 -0
- package/dist/logger.js +32 -0
- package/dist/magic-string.es-B2CP4FDB.js +1324 -0
- package/dist/migrateTypes.d.ts +99 -0
- package/dist/migrateTypes.js +1 -0
- package/dist/multipart-parser-3AFJFP6K.js +374 -0
- package/dist/panic.d.ts +31 -0
- package/dist/panic.js +29 -0
- package/dist/resolveBinary.d.ts +6 -0
- package/dist/resolveBinary.js +34 -0
- package/dist/resolveOutput.d.ts +5 -0
- package/dist/resolveOutput.js +25 -0
- package/dist/resolvePkg.d.ts +7 -0
- package/dist/resolvePkg.js +25 -0
- package/dist/schemaEngineCommands.d.ts +36 -0
- package/dist/schemaEngineCommands.js +36 -0
- package/dist/sendPanic.d.ts +10 -0
- package/dist/sendPanic.js +29 -0
- package/dist/types.d.ts +34 -0
- package/dist/types.js +1 -0
- package/dist/utils/__tests__/isCi.test.js +58 -0
- package/dist/utils/__tests__/isInteractive.test.js +47 -0
- package/dist/utils/assertAlways.d.ts +14 -0
- package/dist/utils/assertAlways.js +25 -0
- package/dist/utils/assertNever.d.ts +27 -0
- package/dist/utils/assertNever.js +25 -0
- package/dist/utils/binaryTargetRegex.d.ts +8 -0
- package/dist/utils/binaryTargetRegex.js +25 -0
- package/dist/utils/callOnce.d.ts +13 -0
- package/dist/utils/callOnce.js +25 -0
- package/dist/utils/callOnce.test.d.ts +1 -0
- package/dist/utils/callOnce.test.js +36 -0
- package/dist/utils/canPrompt.d.ts +1 -0
- package/dist/utils/canPrompt.js +27 -0
- package/dist/utils/chmodPlusX.d.ts +1 -0
- package/dist/utils/chmodPlusX.js +25 -0
- package/dist/utils/drawBox.d.ts +9 -0
- package/dist/utils/drawBox.js +26 -0
- package/dist/utils/extractPreviewFeatures.d.ts +2 -0
- package/dist/utils/extractPreviewFeatures.js +28 -0
- package/dist/utils/formatTable.d.ts +5 -0
- package/dist/utils/formatTable.js +25 -0
- package/dist/utils/formatms.d.ts +5 -0
- package/dist/utils/formatms.js +25 -0
- package/dist/utils/fs-functional.d.ts +53 -0
- package/dist/utils/fs-functional.js +35 -0
- package/dist/utils/fs-utils.d.ts +30 -0
- package/dist/utils/fs-utils.js +32 -0
- package/dist/utils/getCommandWithExecutor.d.ts +1 -0
- package/dist/utils/getCommandWithExecutor.js +26 -0
- package/dist/utils/getGitHubIssueUrl.d.ts +18 -0
- package/dist/utils/getGitHubIssueUrl.js +27 -0
- package/dist/utils/getVersionFromPackageJson.d.ts +1 -0
- package/dist/utils/getVersionFromPackageJson.js +26 -0
- package/dist/utils/handlePanic.d.ts +11 -0
- package/dist/utils/handlePanic.js +36 -0
- package/dist/utils/hasOwnProperty.d.ts +1 -0
- package/dist/utils/hasOwnProperty.js +25 -0
- package/dist/utils/isCi.d.ts +1 -0
- package/dist/utils/isCi.js +25 -0
- package/dist/utils/isCurrentBinInstalledGlobally.d.ts +1 -0
- package/dist/utils/isCurrentBinInstalledGlobally.js +25 -0
- package/dist/utils/isInContainer.d.ts +5 -0
- package/dist/utils/isInContainer.js +25 -0
- package/dist/utils/isInNpmLifecycleHook.d.ts +4 -0
- package/dist/utils/isInNpmLifecycleHook.js +25 -0
- package/dist/utils/isInteractive.d.ts +6 -0
- package/dist/utils/isInteractive.js +25 -0
- package/dist/utils/isPromiseLike.d.ts +1 -0
- package/dist/utils/isPromiseLike.js +25 -0
- package/dist/utils/isValidJsIdentifier.d.ts +1 -0
- package/dist/utils/isValidJsIdentifier.js +25 -0
- package/dist/utils/keyBy.d.ts +9 -0
- package/dist/utils/keyBy.js +25 -0
- package/dist/utils/link.d.ts +1 -0
- package/dist/utils/link.js +26 -0
- package/dist/utils/mapKeys.d.ts +1 -0
- package/dist/utils/mapKeys.js +25 -0
- package/dist/utils/mapObjectValues.d.ts +1 -0
- package/dist/utils/mapObjectValues.js +25 -0
- package/dist/utils/max.d.ts +11 -0
- package/dist/utils/max.js +26 -0
- package/dist/utils/max.test.d.ts +1 -0
- package/dist/utils/max.test.js +22 -0
- package/dist/utils/maybeInGitHook.d.ts +9 -0
- package/dist/utils/maybeInGitHook.js +25 -0
- package/dist/utils/missingDatasource.d.ts +1 -0
- package/dist/utils/missingDatasource.js +32 -0
- package/dist/utils/missingGeneratorMessage.d.ts +3 -0
- package/dist/utils/missingGeneratorMessage.js +34 -0
- package/dist/utils/now.d.ts +3 -0
- package/dist/utils/now.js +51 -0
- package/dist/utils/omit.d.ts +6 -0
- package/dist/utils/omit.js +30 -0
- package/dist/utils/parseAWSNodejsRuntimeEnvVarVersion.d.ts +1 -0
- package/dist/utils/parseAWSNodejsRuntimeEnvVarVersion.js +25 -0
- package/dist/utils/parseEnvValue.d.ts +17 -0
- package/dist/utils/parseEnvValue.js +27 -0
- package/dist/utils/path.d.ts +14 -0
- package/dist/utils/path.js +26 -0
- package/dist/utils/path.test.d.ts +1 -0
- package/dist/utils/path.test.js +54 -0
- package/dist/utils/pick.d.ts +1 -0
- package/dist/utils/pick.js +25 -0
- package/dist/utils/printConfigWarnings.d.ts +1 -0
- package/dist/utils/printConfigWarnings.js +26 -0
- package/dist/utils/prismaPostgres.d.ts +13 -0
- package/dist/utils/prismaPostgres.js +28 -0
- package/dist/utils/prismaPostgres.test.d.ts +1 -0
- package/dist/utils/prismaPostgres.test.js +33 -0
- package/dist/utils/schemaFileInput.d.ts +2 -0
- package/dist/utils/schemaFileInput.js +25 -0
- package/dist/utils/setClassName.d.ts +9 -0
- package/dist/utils/setClassName.js +25 -0
- package/dist/utils/toSchemasContainer.d.ts +5 -0
- package/dist/utils/toSchemasContainer.js +26 -0
- package/dist/utils/unique.d.ts +5 -0
- package/dist/utils/unique.js +38 -0
- package/dist/utils/validatePrismaConfigWithDatasource.d.ts +17 -0
- package/dist/utils/validatePrismaConfigWithDatasource.js +28 -0
- package/dist/utils/vercelPkgPathRegex.d.ts +1 -0
- package/dist/utils/vercelPkgPathRegex.js +25 -0
- package/dist/warnOnce.d.ts +1 -0
- package/dist/warnOnce.js +27 -0
- package/dist/wasm.d.ts +5 -0
- package/dist/wasm.js +29 -0
- package/package.json +93 -0
|
@@ -0,0 +1,48 @@
|
|
|
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_CYAS6B5N_exports = {};
|
|
20
|
+
__export(chunk_CYAS6B5N_exports, {
|
|
21
|
+
sql: () => sql
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(chunk_CYAS6B5N_exports);
|
|
24
|
+
var sql = {
|
|
25
|
+
comment: {
|
|
26
|
+
pattern: /(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,
|
|
27
|
+
lookbehind: true
|
|
28
|
+
},
|
|
29
|
+
variable: [
|
|
30
|
+
{
|
|
31
|
+
pattern: /@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,
|
|
32
|
+
greedy: true
|
|
33
|
+
},
|
|
34
|
+
/@[\w.$]+/
|
|
35
|
+
],
|
|
36
|
+
string: {
|
|
37
|
+
pattern: /(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,
|
|
38
|
+
greedy: true,
|
|
39
|
+
lookbehind: true
|
|
40
|
+
},
|
|
41
|
+
function: /\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,
|
|
42
|
+
// Should we highlight user defined functions too?
|
|
43
|
+
keyword: /\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:_INSERT|COL)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURNS?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,
|
|
44
|
+
boolean: /\b(?:TRUE|FALSE|NULL)\b/i,
|
|
45
|
+
number: /\b0x[\da-f]+\b|\b\d+\.?\d*|\B\.\d+\b/i,
|
|
46
|
+
operator: /[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|IN|LIKE|NOT|OR|IS|DIV|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,
|
|
47
|
+
punctuation: /[;[\]()`,.]/
|
|
48
|
+
};
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var chunk_D4VZUY3O_exports = {};
|
|
30
|
+
__export(chunk_D4VZUY3O_exports, {
|
|
31
|
+
arg: () => arg,
|
|
32
|
+
format: () => format,
|
|
33
|
+
isError: () => isError
|
|
34
|
+
});
|
|
35
|
+
module.exports = __toCommonJS(chunk_D4VZUY3O_exports);
|
|
36
|
+
var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
|
|
37
|
+
var import_arg = __toESM(require("arg"));
|
|
38
|
+
var require_min_indent = (0, import_chunk_4VNS5WPM.__commonJS)({
|
|
39
|
+
"../../node_modules/.pnpm/min-indent@1.0.1/node_modules/min-indent/index.js"(exports, module2) {
|
|
40
|
+
"use strict";
|
|
41
|
+
module2.exports = (string) => {
|
|
42
|
+
const match = string.match(/^[ \t]*(?=\S)/gm);
|
|
43
|
+
if (!match) {
|
|
44
|
+
return 0;
|
|
45
|
+
}
|
|
46
|
+
return match.reduce((r, a) => Math.min(r, a.length), Infinity);
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
var import_min_indent = (0, import_chunk_4VNS5WPM.__toESM)(require_min_indent(), 1);
|
|
51
|
+
function stripIndent(string) {
|
|
52
|
+
const indent = (0, import_min_indent.default)(string);
|
|
53
|
+
if (indent === 0) {
|
|
54
|
+
return string;
|
|
55
|
+
}
|
|
56
|
+
const regex = new RegExp(`^[ \\t]{${indent}}`, "gm");
|
|
57
|
+
return string.replace(regex, "");
|
|
58
|
+
}
|
|
59
|
+
function format(input = "") {
|
|
60
|
+
return stripIndent(input).trimRight() + "\n";
|
|
61
|
+
}
|
|
62
|
+
function arg(argv, spec, stopAtPositional = true, permissive = false) {
|
|
63
|
+
try {
|
|
64
|
+
return (0, import_arg.default)(spec, { argv, stopAtPositional, permissive });
|
|
65
|
+
} catch (e) {
|
|
66
|
+
return e;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
function isError(result) {
|
|
70
|
+
return result instanceof Error;
|
|
71
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
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_DODIJPCS_exports = {};
|
|
20
|
+
__export(chunk_DODIJPCS_exports, {
|
|
21
|
+
binaryTargetRegex: () => binaryTargetRegex
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(chunk_DODIJPCS_exports);
|
|
24
|
+
var import_get_platform = require("@prisma/get-platform");
|
|
25
|
+
function escapeStringRegexp(string) {
|
|
26
|
+
if (typeof string !== "string") {
|
|
27
|
+
throw new TypeError("Expected a string");
|
|
28
|
+
}
|
|
29
|
+
return string.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
|
|
30
|
+
}
|
|
31
|
+
var binaryTargetRegex = new RegExp(
|
|
32
|
+
"(" + [...import_get_platform.binaryTargets].sort((a, b) => b.length - a.length).map((p) => escapeStringRegexp(p)).join("|") + ")",
|
|
33
|
+
"g"
|
|
34
|
+
);
|
|
@@ -0,0 +1,31 @@
|
|
|
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_DTPFRZWV_exports = {};
|
|
20
|
+
__export(chunk_DTPFRZWV_exports, {
|
|
21
|
+
warnOnce: () => warnOnce
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(chunk_DTPFRZWV_exports);
|
|
24
|
+
var import_chunk_ZJWZK45Z = require("./chunk-ZJWZK45Z.js");
|
|
25
|
+
var alreadyWarned = /* @__PURE__ */ new Set();
|
|
26
|
+
var warnOnce = (key, message, ...args) => {
|
|
27
|
+
if (!alreadyWarned.has(key)) {
|
|
28
|
+
alreadyWarned.add(key);
|
|
29
|
+
(0, import_chunk_ZJWZK45Z.warn)(message, ...args);
|
|
30
|
+
}
|
|
31
|
+
};
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var chunk_DUDEWDFC_exports = {};
|
|
30
|
+
__export(chunk_DUDEWDFC_exports, {
|
|
31
|
+
handlePanic: () => handlePanic
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(chunk_DUDEWDFC_exports);
|
|
34
|
+
var import_chunk_I6WLABB2 = require("./chunk-I6WLABB2.js");
|
|
35
|
+
var import_chunk_YXB6APHS = require("./chunk-YXB6APHS.js");
|
|
36
|
+
var import_chunk_FCYHZHVW = require("./chunk-FCYHZHVW.js");
|
|
37
|
+
var import_chunk_FRVJZOHP = require("./chunk-FRVJZOHP.js");
|
|
38
|
+
var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
|
|
39
|
+
var import_prompts = __toESM(require("prompts"));
|
|
40
|
+
async function handlePanic(args) {
|
|
41
|
+
if (!(0, import_chunk_FCYHZHVW.canPrompt)()) {
|
|
42
|
+
throw args.error;
|
|
43
|
+
}
|
|
44
|
+
await panicDialog(args);
|
|
45
|
+
}
|
|
46
|
+
async function panicDialog({
|
|
47
|
+
error,
|
|
48
|
+
cliVersion,
|
|
49
|
+
enginesVersion,
|
|
50
|
+
command,
|
|
51
|
+
getDatabaseVersionSafe
|
|
52
|
+
}) {
|
|
53
|
+
const errorMessage = error.message.split("\n").slice(0, Math.max(20, process.stdout.rows)).join("\n");
|
|
54
|
+
console.log(`${(0, import_chunk_PG5FDKSF.red)("Oops, an unexpected error occurred!")}
|
|
55
|
+
${(0, import_chunk_PG5FDKSF.red)(errorMessage)}
|
|
56
|
+
|
|
57
|
+
${(0, import_chunk_PG5FDKSF.bold)("Please help us improve Prisma by submitting an error report.")}
|
|
58
|
+
${(0, import_chunk_PG5FDKSF.bold)("Error reports never contain personal or other sensitive information.")}
|
|
59
|
+
${(0, import_chunk_PG5FDKSF.dim)(`Learn more: ${(0, import_chunk_I6WLABB2.link)("https://pris.ly/d/telemetry")}`)}
|
|
60
|
+
`);
|
|
61
|
+
const { value: shouldSubmitReport } = await (0, import_prompts.default)({
|
|
62
|
+
type: "select",
|
|
63
|
+
name: "value",
|
|
64
|
+
message: "Submit error report",
|
|
65
|
+
initial: 0,
|
|
66
|
+
choices: [
|
|
67
|
+
{
|
|
68
|
+
title: "Yes",
|
|
69
|
+
value: true,
|
|
70
|
+
description: `Send error report once`
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
title: "No",
|
|
74
|
+
value: false,
|
|
75
|
+
description: `Don't send error report`
|
|
76
|
+
}
|
|
77
|
+
]
|
|
78
|
+
});
|
|
79
|
+
if (shouldSubmitReport) {
|
|
80
|
+
try {
|
|
81
|
+
console.log("Submitting...");
|
|
82
|
+
const reportId = await (0, import_chunk_FRVJZOHP.sendPanic)({ error, cliVersion, enginesVersion, getDatabaseVersionSafe });
|
|
83
|
+
console.log(`
|
|
84
|
+
${(0, import_chunk_PG5FDKSF.bold)(`We successfully received the error report id: ${reportId}`)}`);
|
|
85
|
+
console.log(`
|
|
86
|
+
${(0, import_chunk_PG5FDKSF.bold)("Thanks a lot for your help! \u{1F64F}")}`);
|
|
87
|
+
} catch (error2) {
|
|
88
|
+
const reportFailedMessage = `${(0, import_chunk_PG5FDKSF.bold)((0, import_chunk_PG5FDKSF.red)("Oops. We could not send the error report."))}`;
|
|
89
|
+
console.log(reportFailedMessage);
|
|
90
|
+
console.error(`${(0, import_chunk_PG5FDKSF.gray)("Error report submission failed due to: ")}`, error2);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
await (0, import_chunk_YXB6APHS.wouldYouLikeToCreateANewIssue)({
|
|
94
|
+
prompt: !shouldSubmitReport,
|
|
95
|
+
error,
|
|
96
|
+
cliVersion,
|
|
97
|
+
enginesVersion,
|
|
98
|
+
command
|
|
99
|
+
});
|
|
100
|
+
process.exit(1);
|
|
101
|
+
}
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var chunk_DZ4QWHTB_exports = {};
|
|
30
|
+
__export(chunk_DZ4QWHTB_exports, {
|
|
31
|
+
getBinaryPathsByVersion: () => getBinaryPathsByVersion
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(chunk_DZ4QWHTB_exports);
|
|
34
|
+
var import_chunk_5I4ERIIY = require("./chunk-5I4ERIIY.js");
|
|
35
|
+
var import_chunk_GJSFP4V4 = require("./chunk-GJSFP4V4.js");
|
|
36
|
+
var import_chunk_2SDPW6AX = require("./chunk-2SDPW6AX.js");
|
|
37
|
+
var import_chunk_7B5PXS6N = require("./chunk-7B5PXS6N.js");
|
|
38
|
+
var import_chunk_E476ARWS = require("./chunk-E476ARWS.js");
|
|
39
|
+
var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
|
|
40
|
+
var import_engines = require("@prisma/engines");
|
|
41
|
+
var import_fetch_engine = require("@prisma/fetch-engine");
|
|
42
|
+
var import_path = __toESM2(require("path"));
|
|
43
|
+
var import_fs_extra = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_E476ARWS.require_lib)());
|
|
44
|
+
async function getBinaryPathsByVersion({
|
|
45
|
+
neededVersions,
|
|
46
|
+
detectBinaryTarget,
|
|
47
|
+
version,
|
|
48
|
+
printDownloadProgress,
|
|
49
|
+
skipDownload,
|
|
50
|
+
binaryPathsOverride
|
|
51
|
+
}) {
|
|
52
|
+
const binaryPathsByVersion = /* @__PURE__ */ Object.create(null);
|
|
53
|
+
if (Object.entries(neededVersions).length === 0) {
|
|
54
|
+
const UNUSED_BINARY_TARGET = "native";
|
|
55
|
+
return { binaryPathsByVersion, binaryTarget: UNUSED_BINARY_TARGET };
|
|
56
|
+
}
|
|
57
|
+
const binaryTarget = await detectBinaryTarget();
|
|
58
|
+
for (const currentVersion in neededVersions) {
|
|
59
|
+
binaryPathsByVersion[currentVersion] = {};
|
|
60
|
+
const neededVersion = neededVersions[currentVersion];
|
|
61
|
+
if (neededVersion.binaryTargets.length === 0) {
|
|
62
|
+
neededVersion.binaryTargets = [{ fromEnvVar: null, value: binaryTarget }];
|
|
63
|
+
}
|
|
64
|
+
if (process.env.NETLIFY) {
|
|
65
|
+
const isNodeMajor20OrUp = parseInt(process.versions.node.split(".")[0]) >= 20;
|
|
66
|
+
const awsRuntimeVersion = (0, import_chunk_2SDPW6AX.parseAWSNodejsRuntimeEnvVarVersion)();
|
|
67
|
+
const isRuntimeEnvVar20OrUp = awsRuntimeVersion && awsRuntimeVersion >= 20;
|
|
68
|
+
const isRuntimeEnvVar18OrDown = awsRuntimeVersion && awsRuntimeVersion <= 18;
|
|
69
|
+
const isRhelBinaryTarget1xInNeededVersions = neededVersion.binaryTargets.find(
|
|
70
|
+
(object) => object.value === "rhel-openssl-1.0.x"
|
|
71
|
+
);
|
|
72
|
+
const isRhelBinaryTarget3xInNeededVersions = neededVersion.binaryTargets.find(
|
|
73
|
+
(object) => object.value === "rhel-openssl-3.0.x"
|
|
74
|
+
);
|
|
75
|
+
if (!isRhelBinaryTarget3xInNeededVersions && (isNodeMajor20OrUp || isRuntimeEnvVar20OrUp) && !isRuntimeEnvVar18OrDown) {
|
|
76
|
+
neededVersion.binaryTargets.push({
|
|
77
|
+
fromEnvVar: null,
|
|
78
|
+
value: "rhel-openssl-3.0.x"
|
|
79
|
+
});
|
|
80
|
+
} else if (!isRhelBinaryTarget1xInNeededVersions) {
|
|
81
|
+
neededVersion.binaryTargets.push({
|
|
82
|
+
fromEnvVar: null,
|
|
83
|
+
value: "rhel-openssl-1.0.x"
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
let binaryTargetBaseDir = eval(`require('path').join(__dirname, '..')`);
|
|
88
|
+
if (version !== currentVersion) {
|
|
89
|
+
binaryTargetBaseDir = import_path.default.join(binaryTargetBaseDir, `./engines/${currentVersion}/`);
|
|
90
|
+
await (0, import_fs_extra.ensureDir)(binaryTargetBaseDir).catch((e) => console.error(e));
|
|
91
|
+
}
|
|
92
|
+
const binariesConfig = neededVersion.engines.reduce((acc, curr) => {
|
|
93
|
+
if (!binaryPathsOverride?.[curr]) {
|
|
94
|
+
acc[(0, import_chunk_GJSFP4V4.engineTypeToBinaryType)(curr)] = binaryTargetBaseDir;
|
|
95
|
+
}
|
|
96
|
+
return acc;
|
|
97
|
+
}, /* @__PURE__ */ Object.create(null));
|
|
98
|
+
if (Object.values(binariesConfig).length > 0) {
|
|
99
|
+
const binaryTargets = neededVersion.binaryTargets.map(
|
|
100
|
+
(binaryTarget2) => binaryTarget2.value
|
|
101
|
+
);
|
|
102
|
+
const downloadParams = {
|
|
103
|
+
binaries: binariesConfig,
|
|
104
|
+
binaryTargets,
|
|
105
|
+
showProgress: typeof printDownloadProgress === "boolean" ? printDownloadProgress : true,
|
|
106
|
+
version: currentVersion && currentVersion !== "latest" ? currentVersion : import_engines.enginesVersion,
|
|
107
|
+
skipDownload
|
|
108
|
+
};
|
|
109
|
+
const binaryPathsWithEngineType = await (0, import_fetch_engine.download)(downloadParams);
|
|
110
|
+
const binaryPaths = (0, import_chunk_7B5PXS6N.mapKeys)(binaryPathsWithEngineType, import_chunk_5I4ERIIY.binaryTypeToEngineType);
|
|
111
|
+
binaryPathsByVersion[currentVersion] = binaryPaths;
|
|
112
|
+
}
|
|
113
|
+
if (binaryPathsOverride) {
|
|
114
|
+
const overrideEngines = Object.keys(binaryPathsOverride);
|
|
115
|
+
const enginesCoveredByOverride = neededVersion.engines.filter((engine) => overrideEngines.includes(engine));
|
|
116
|
+
if (enginesCoveredByOverride.length > 0) {
|
|
117
|
+
for (const engine of enginesCoveredByOverride) {
|
|
118
|
+
const enginePath = binaryPathsOverride[engine];
|
|
119
|
+
binaryPathsByVersion[currentVersion][engine] = {
|
|
120
|
+
[binaryTarget]: enginePath
|
|
121
|
+
};
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
return { binaryPathsByVersion, binaryTarget };
|
|
127
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
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_E23HYCQJ_exports = {};
|
|
20
|
+
__export(chunk_E23HYCQJ_exports, {
|
|
21
|
+
theme: () => theme
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(chunk_E23HYCQJ_exports);
|
|
24
|
+
var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
|
|
25
|
+
var theme = {
|
|
26
|
+
keyword: import_chunk_PG5FDKSF.cyan,
|
|
27
|
+
entity: import_chunk_PG5FDKSF.cyan,
|
|
28
|
+
value: (s) => (0, import_chunk_PG5FDKSF.bold)((0, import_chunk_PG5FDKSF.blue)(s)),
|
|
29
|
+
punctuation: import_chunk_PG5FDKSF.blue,
|
|
30
|
+
directive: import_chunk_PG5FDKSF.cyan,
|
|
31
|
+
function: import_chunk_PG5FDKSF.cyan,
|
|
32
|
+
variable: (s) => (0, import_chunk_PG5FDKSF.bold)((0, import_chunk_PG5FDKSF.blue)(s)),
|
|
33
|
+
string: (s) => (0, import_chunk_PG5FDKSF.bold)((0, import_chunk_PG5FDKSF.green)(s)),
|
|
34
|
+
boolean: import_chunk_PG5FDKSF.yellow,
|
|
35
|
+
number: import_chunk_PG5FDKSF.cyan,
|
|
36
|
+
comment: import_chunk_PG5FDKSF.gray
|
|
37
|
+
};
|