wxt 0.18.6 → 0.18.8
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/dist/{chunk-5X3S6AWF.js → chunk-BERPNPEZ.js} +2 -4
- package/dist/{chunk-ZZCTFNQ5.js → chunk-BM6QYGAW.js} +1 -1
- package/dist/{chunk-NAMV4VWQ.js → chunk-KPD5J7PZ.js} +1 -1
- package/dist/{chunk-VBXJIVYU.js → chunk-QGM4M3NI.js} +1 -2
- package/dist/{chunk-73I7FAJU.js → chunk-SGKCDMVR.js} +1 -2
- package/dist/{chunk-QOYT5J6A.js → chunk-Z3C7S5VV.js} +117 -182
- package/dist/cli.js +139 -220
- package/dist/client.js +12 -24
- package/dist/{execa-QQUOQNS3.js → execa-ATHZH2Y4.js} +1576 -610
- package/dist/{execa-5TSWMF32.js → execa-D7CMCKO2.js} +1576 -610
- package/dist/index.cjs +2182 -1180
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +24 -38
- package/dist/modules.cjs +8 -12
- package/dist/modules.js +9 -13
- package/dist/{prompt-Y7B5HSD5.js → prompt-25QIVJDC.js} +28 -55
- package/dist/{prompt-TFJ7OLL7.js → prompt-7BMKNSWS.js} +28 -55
- package/dist/sandbox.js +2 -4
- package/dist/storage.cjs +4 -8
- package/dist/storage.js +6 -10
- package/dist/testing.cjs +35 -69
- package/dist/testing.js +4 -4
- package/dist/virtual/background-entrypoint.js +46 -36
- package/dist/virtual/content-script-isolated-world-entrypoint.js +1 -2
- package/dist/virtual/content-script-main-world-entrypoint.js +1 -2
- package/dist/virtual/reload-html.js +38 -31
- package/dist/virtual/unlisted-script-entrypoint.js +1 -2
- package/package.json +33 -32
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
__commonJS,
|
|
4
4
|
__require,
|
|
5
5
|
__toESM
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-SGKCDMVR.js";
|
|
7
7
|
|
|
8
8
|
// ../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js
|
|
9
9
|
var require_windows = __commonJS({
|
|
@@ -515,7 +515,7 @@ function isPlainObject(value) {
|
|
|
515
515
|
return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in value) && !(Symbol.iterator in value);
|
|
516
516
|
}
|
|
517
517
|
|
|
518
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
518
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/arguments/file-url.js
|
|
519
519
|
import { fileURLToPath } from "node:url";
|
|
520
520
|
var safeNormalizeFileUrl = (file, name) => {
|
|
521
521
|
const fileString = normalizeFileUrl(file);
|
|
@@ -526,7 +526,7 @@ var safeNormalizeFileUrl = (file, name) => {
|
|
|
526
526
|
};
|
|
527
527
|
var normalizeFileUrl = (file) => file instanceof URL ? fileURLToPath(file) : file;
|
|
528
528
|
|
|
529
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
529
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/parameters.js
|
|
530
530
|
var normalizeParameters = (rawFile, rawArguments = [], rawOptions = {}) => {
|
|
531
531
|
const filePath = safeNormalizeFileUrl(rawFile, "First argument");
|
|
532
532
|
const [commandArguments, options] = isPlainObject(rawArguments) ? [[], rawArguments] : [rawArguments, rawOptions];
|
|
@@ -547,10 +547,10 @@ var normalizeParameters = (rawFile, rawArguments = [], rawOptions = {}) => {
|
|
|
547
547
|
return [filePath, normalizedArguments, options];
|
|
548
548
|
};
|
|
549
549
|
|
|
550
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
550
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/template.js
|
|
551
551
|
import { ChildProcess } from "node:child_process";
|
|
552
552
|
|
|
553
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
553
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/utils/uint-array.js
|
|
554
554
|
import { StringDecoder } from "node:string_decoder";
|
|
555
555
|
var { toString: objectToString } = Object.prototype;
|
|
556
556
|
var isArrayBuffer = (value) => objectToString.call(value) === "[object ArrayBuffer]";
|
|
@@ -597,7 +597,7 @@ var getJoinLength = (uint8Arrays) => {
|
|
|
597
597
|
return joinLength;
|
|
598
598
|
};
|
|
599
599
|
|
|
600
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
600
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/template.js
|
|
601
601
|
var isTemplateString = (templates) => Array.isArray(templates) && Array.isArray(templates.raw);
|
|
602
602
|
var parseTemplates = (templates, expressions) => {
|
|
603
603
|
let tokens = [];
|
|
@@ -694,7 +694,7 @@ var getSubprocessResult = ({ stdout }) => {
|
|
|
694
694
|
throw new TypeError(`Unexpected "${typeof stdout}" stdout in template expression`);
|
|
695
695
|
};
|
|
696
696
|
|
|
697
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
697
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/main-sync.js
|
|
698
698
|
import { spawnSync } from "node:child_process";
|
|
699
699
|
|
|
700
700
|
// ../../node_modules/.pnpm/yoctocolors@2.0.2/node_modules/yoctocolors/index.js
|
|
@@ -765,7 +765,7 @@ var bgMagentaBright = format(105, 49);
|
|
|
765
765
|
var bgCyanBright = format(106, 49);
|
|
766
766
|
var bgWhiteBright = format(107, 49);
|
|
767
767
|
|
|
768
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
768
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/verbose/info.js
|
|
769
769
|
import { debuglog } from "node:util";
|
|
770
770
|
var verboseDefault = debuglog("execa").enabled ? "full" : "none";
|
|
771
771
|
var getVerboseInfo = (verbose) => {
|
|
@@ -791,8 +791,9 @@ var validateVerbose = (verbose) => {
|
|
|
791
791
|
};
|
|
792
792
|
var VERBOSE_VALUES = /* @__PURE__ */ new Set(["none", "short", "full"]);
|
|
793
793
|
|
|
794
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
794
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/verbose/log.js
|
|
795
795
|
import { writeFileSync } from "node:fs";
|
|
796
|
+
import { inspect } from "node:util";
|
|
796
797
|
|
|
797
798
|
// ../../node_modules/.pnpm/is-unicode-supported@2.0.0/node_modules/is-unicode-supported/index.js
|
|
798
799
|
import process2 from "node:process";
|
|
@@ -1079,7 +1080,45 @@ var figures = shouldUseMain ? mainSymbols : fallbackSymbols;
|
|
|
1079
1080
|
var figures_default = figures;
|
|
1080
1081
|
var replacements = Object.entries(specialMainSymbols);
|
|
1081
1082
|
|
|
1082
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1083
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/arguments/escape.js
|
|
1084
|
+
import { platform } from "node:process";
|
|
1085
|
+
import { stripVTControlCharacters } from "node:util";
|
|
1086
|
+
var joinCommand = (filePath, rawArguments) => {
|
|
1087
|
+
const fileAndArguments = [filePath, ...rawArguments];
|
|
1088
|
+
const command = fileAndArguments.join(" ");
|
|
1089
|
+
const escapedCommand = fileAndArguments.map((fileAndArgument) => quoteString(escapeControlCharacters(fileAndArgument))).join(" ");
|
|
1090
|
+
return { command, escapedCommand };
|
|
1091
|
+
};
|
|
1092
|
+
var escapeLines = (lines) => stripVTControlCharacters(lines).split("\n").map((line) => escapeControlCharacters(line)).join("\n");
|
|
1093
|
+
var escapeControlCharacters = (line) => line.replaceAll(SPECIAL_CHAR_REGEXP, (character) => escapeControlCharacter(character));
|
|
1094
|
+
var escapeControlCharacter = (character) => {
|
|
1095
|
+
const commonEscape = COMMON_ESCAPES[character];
|
|
1096
|
+
if (commonEscape !== void 0) {
|
|
1097
|
+
return commonEscape;
|
|
1098
|
+
}
|
|
1099
|
+
const codepoint = character.codePointAt(0);
|
|
1100
|
+
const codepointHex = codepoint.toString(16);
|
|
1101
|
+
return codepoint <= ASTRAL_START ? `\\u${codepointHex.padStart(4, "0")}` : `\\U${codepointHex}`;
|
|
1102
|
+
};
|
|
1103
|
+
var SPECIAL_CHAR_REGEXP = /\p{Separator}|\p{Other}/gu;
|
|
1104
|
+
var COMMON_ESCAPES = {
|
|
1105
|
+
" ": " ",
|
|
1106
|
+
"\b": "\\b",
|
|
1107
|
+
"\f": "\\f",
|
|
1108
|
+
"\n": "\\n",
|
|
1109
|
+
"\r": "\\r",
|
|
1110
|
+
" ": "\\t"
|
|
1111
|
+
};
|
|
1112
|
+
var ASTRAL_START = 65535;
|
|
1113
|
+
var quoteString = (escapedArgument) => {
|
|
1114
|
+
if (NO_ESCAPE_REGEXP.test(escapedArgument)) {
|
|
1115
|
+
return escapedArgument;
|
|
1116
|
+
}
|
|
1117
|
+
return platform === "win32" ? `"${escapedArgument.replaceAll('"', '""')}"` : `'${escapedArgument.replaceAll("'", "'\\''")}'`;
|
|
1118
|
+
};
|
|
1119
|
+
var NO_ESCAPE_REGEXP = /^[\w./-]+$/;
|
|
1120
|
+
|
|
1121
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/verbose/log.js
|
|
1083
1122
|
var verboseLog = (string, verboseId, icon, color) => {
|
|
1084
1123
|
const prefixedLines = addPrefix(string, verboseId, icon, color);
|
|
1085
1124
|
writeFileSync(STDERR_FD, `${prefixedLines}
|
|
@@ -1103,12 +1142,19 @@ var ICONS = {
|
|
|
1103
1142
|
command: "$",
|
|
1104
1143
|
pipedCommand: "|",
|
|
1105
1144
|
output: " ",
|
|
1145
|
+
ipc: "*",
|
|
1106
1146
|
error: figures_default.cross,
|
|
1107
1147
|
warning: figures_default.warning,
|
|
1108
1148
|
success: figures_default.tick
|
|
1109
1149
|
};
|
|
1150
|
+
var serializeLogMessage = (message) => {
|
|
1151
|
+
const messageString = typeof message === "string" ? message : inspect(message);
|
|
1152
|
+
const escapedMessage = escapeLines(messageString);
|
|
1153
|
+
return escapedMessage.replaceAll(" ", " ".repeat(TAB_SIZE));
|
|
1154
|
+
};
|
|
1155
|
+
var TAB_SIZE = 2;
|
|
1110
1156
|
|
|
1111
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1157
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/verbose/start.js
|
|
1112
1158
|
var logCommand = (escapedCommand, { verbose, verboseId }, { piped = false }) => {
|
|
1113
1159
|
if (!isVerbose(verbose)) {
|
|
1114
1160
|
return;
|
|
@@ -1117,57 +1163,19 @@ var logCommand = (escapedCommand, { verbose, verboseId }, { piped = false }) =>
|
|
|
1117
1163
|
verboseLog(escapedCommand, verboseId, icon, bold);
|
|
1118
1164
|
};
|
|
1119
1165
|
|
|
1120
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1166
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/return/duration.js
|
|
1121
1167
|
import { hrtime } from "node:process";
|
|
1122
1168
|
var getStartTime = () => hrtime.bigint();
|
|
1123
1169
|
var getDurationMs = (startTime) => Number(hrtime.bigint() - startTime) / 1e6;
|
|
1124
1170
|
|
|
1125
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1126
|
-
import { platform } from "node:process";
|
|
1127
|
-
import { stripVTControlCharacters } from "node:util";
|
|
1128
|
-
var joinCommand = (filePath, rawArguments) => {
|
|
1129
|
-
const fileAndArguments = [filePath, ...rawArguments];
|
|
1130
|
-
const command = fileAndArguments.join(" ");
|
|
1131
|
-
const escapedCommand = fileAndArguments.map((fileAndArgument) => quoteString(escapeControlCharacters(fileAndArgument))).join(" ");
|
|
1132
|
-
return { command, escapedCommand };
|
|
1133
|
-
};
|
|
1134
|
-
var escapeLines = (lines) => stripVTControlCharacters(lines).split("\n").map((line) => escapeControlCharacters(line)).join("\n");
|
|
1135
|
-
var escapeControlCharacters = (line) => line.replaceAll(SPECIAL_CHAR_REGEXP, (character) => escapeControlCharacter(character));
|
|
1136
|
-
var escapeControlCharacter = (character) => {
|
|
1137
|
-
const commonEscape = COMMON_ESCAPES[character];
|
|
1138
|
-
if (commonEscape !== void 0) {
|
|
1139
|
-
return commonEscape;
|
|
1140
|
-
}
|
|
1141
|
-
const codepoint = character.codePointAt(0);
|
|
1142
|
-
const codepointHex = codepoint.toString(16);
|
|
1143
|
-
return codepoint <= ASTRAL_START ? `\\u${codepointHex.padStart(4, "0")}` : `\\U${codepointHex}`;
|
|
1144
|
-
};
|
|
1145
|
-
var SPECIAL_CHAR_REGEXP = /\p{Separator}|\p{Other}/gu;
|
|
1146
|
-
var COMMON_ESCAPES = {
|
|
1147
|
-
" ": " ",
|
|
1148
|
-
"\b": "\\b",
|
|
1149
|
-
"\f": "\\f",
|
|
1150
|
-
"\n": "\\n",
|
|
1151
|
-
"\r": "\\r",
|
|
1152
|
-
" ": "\\t"
|
|
1153
|
-
};
|
|
1154
|
-
var ASTRAL_START = 65535;
|
|
1155
|
-
var quoteString = (escapedArgument) => {
|
|
1156
|
-
if (NO_ESCAPE_REGEXP.test(escapedArgument)) {
|
|
1157
|
-
return escapedArgument;
|
|
1158
|
-
}
|
|
1159
|
-
return platform === "win32" ? `"${escapedArgument.replaceAll('"', '""')}"` : `'${escapedArgument.replaceAll("'", "'\\''")}'`;
|
|
1160
|
-
};
|
|
1161
|
-
var NO_ESCAPE_REGEXP = /^[\w./-]+$/;
|
|
1162
|
-
|
|
1163
|
-
// ../../node_modules/.pnpm/execa@9.1.0/node_modules/execa/lib/utils/standard-stream.js
|
|
1171
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/utils/standard-stream.js
|
|
1164
1172
|
import process3 from "node:process";
|
|
1165
1173
|
var isStandardStream = (stream) => STANDARD_STREAMS.includes(stream);
|
|
1166
1174
|
var STANDARD_STREAMS = [process3.stdin, process3.stdout, process3.stderr];
|
|
1167
1175
|
var STANDARD_STREAMS_ALIASES = ["stdin", "stdout", "stderr"];
|
|
1168
1176
|
var getStreamName = (fdNumber) => STANDARD_STREAMS_ALIASES[fdNumber] ?? `stdio[${fdNumber}]`;
|
|
1169
1177
|
|
|
1170
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1178
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/arguments/specific.js
|
|
1171
1179
|
var normalizeFdSpecificOptions = (options) => {
|
|
1172
1180
|
const optionsCopy = { ...options };
|
|
1173
1181
|
for (const optionName of FD_SPECIFIC_OPTIONS) {
|
|
@@ -1176,7 +1184,7 @@ var normalizeFdSpecificOptions = (options) => {
|
|
|
1176
1184
|
return optionsCopy;
|
|
1177
1185
|
};
|
|
1178
1186
|
var normalizeFdSpecificOption = (options, optionName) => {
|
|
1179
|
-
const optionBaseArray = Array.from({ length: getStdioLength(options) });
|
|
1187
|
+
const optionBaseArray = Array.from({ length: getStdioLength(options) + 1 });
|
|
1180
1188
|
const optionArray = normalizeFdSpecificValue(options[optionName], optionBaseArray, optionName);
|
|
1181
1189
|
return addDefaultValue(optionArray, optionName);
|
|
1182
1190
|
};
|
|
@@ -1198,10 +1206,13 @@ var getFdNameOrder = (fdName) => {
|
|
|
1198
1206
|
return fdName === "all" ? 2 : 1;
|
|
1199
1207
|
};
|
|
1200
1208
|
var parseFdName = (fdName, optionName, optionArray) => {
|
|
1209
|
+
if (fdName === "ipc") {
|
|
1210
|
+
return [optionArray.length - 1];
|
|
1211
|
+
}
|
|
1201
1212
|
const fdNumber = parseFd(fdName);
|
|
1202
1213
|
if (fdNumber === void 0 || fdNumber === 0) {
|
|
1203
1214
|
throw new TypeError(`"${optionName}.${fdName}" is invalid.
|
|
1204
|
-
It must be "${optionName}.stdout", "${optionName}.stderr", "${optionName}.all", or "${optionName}.fd3", "${optionName}.fd4" (and so on).`);
|
|
1215
|
+
It must be "${optionName}.stdout", "${optionName}.stderr", "${optionName}.all", "${optionName}.ipc", or "${optionName}.fd3", "${optionName}.fd4" (and so on).`);
|
|
1205
1216
|
}
|
|
1206
1217
|
if (fdNumber >= optionArray.length) {
|
|
1207
1218
|
throw new TypeError(`"${optionName}.${fdName}" is invalid: that file descriptor does not exist.
|
|
@@ -1232,7 +1243,7 @@ var DEFAULT_OPTIONS = {
|
|
|
1232
1243
|
};
|
|
1233
1244
|
var FD_SPECIFIC_OPTIONS = ["lines", "buffer", "maxBuffer", "verbose", "stripFinalNewline"];
|
|
1234
1245
|
|
|
1235
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1246
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/arguments/command.js
|
|
1236
1247
|
var handleCommand = (filePath, rawArguments, rawOptions) => {
|
|
1237
1248
|
const startTime = getStartTime();
|
|
1238
1249
|
const { command, escapedCommand } = joinCommand(filePath, rawArguments);
|
|
@@ -1246,7 +1257,7 @@ var handleCommand = (filePath, rawArguments, rawOptions) => {
|
|
|
1246
1257
|
};
|
|
1247
1258
|
};
|
|
1248
1259
|
|
|
1249
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1260
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/arguments/options.js
|
|
1250
1261
|
var import_cross_spawn = __toESM(require_cross_spawn(), 1);
|
|
1251
1262
|
import { basename as basename2 } from "node:path";
|
|
1252
1263
|
import process6 from "node:process";
|
|
@@ -1307,10 +1318,10 @@ var npmRunPathEnv = ({ env = process4.env, ...options } = {}) => {
|
|
|
1307
1318
|
return env;
|
|
1308
1319
|
};
|
|
1309
1320
|
|
|
1310
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1321
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/terminate/kill.js
|
|
1311
1322
|
import { setTimeout } from "node:timers/promises";
|
|
1312
1323
|
|
|
1313
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1324
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/return/final-error.js
|
|
1314
1325
|
var getFinalError = (originalError, message, isSync) => {
|
|
1315
1326
|
const ErrorClass = isSync ? ExecaSyncError : ExecaError;
|
|
1316
1327
|
const options = originalError instanceof DiscardedError ? {} : { cause: originalError };
|
|
@@ -1342,323 +1353,29 @@ var ExecaSyncError = class extends Error {
|
|
|
1342
1353
|
};
|
|
1343
1354
|
setErrorName(ExecaSyncError, ExecaSyncError.name);
|
|
1344
1355
|
|
|
1345
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
1346
|
-
import { constants } from "node:os";
|
|
1347
|
-
var normalizeKillSignal = (killSignal) => {
|
|
1348
|
-
const optionName = "option `killSignal`";
|
|
1349
|
-
if (killSignal === 0) {
|
|
1350
|
-
throw new TypeError(`Invalid ${optionName}: 0 cannot be used.`);
|
|
1351
|
-
}
|
|
1352
|
-
return normalizeSignal(killSignal, optionName);
|
|
1353
|
-
};
|
|
1354
|
-
var normalizeSignalArgument = (signal) => signal === 0 ? signal : normalizeSignal(signal, "`subprocess.kill()`'s argument");
|
|
1355
|
-
var normalizeSignal = (signalNameOrInteger, optionName) => {
|
|
1356
|
-
if (Number.isInteger(signalNameOrInteger)) {
|
|
1357
|
-
return normalizeSignalInteger(signalNameOrInteger, optionName);
|
|
1358
|
-
}
|
|
1359
|
-
if (typeof signalNameOrInteger === "string") {
|
|
1360
|
-
return normalizeSignalName(signalNameOrInteger, optionName);
|
|
1361
|
-
}
|
|
1362
|
-
throw new TypeError(`Invalid ${optionName} ${String(signalNameOrInteger)}: it must be a string or an integer.
|
|
1363
|
-
${getAvailableSignals()}`);
|
|
1364
|
-
};
|
|
1365
|
-
var normalizeSignalInteger = (signalInteger, optionName) => {
|
|
1366
|
-
if (signalsIntegerToName.has(signalInteger)) {
|
|
1367
|
-
return signalsIntegerToName.get(signalInteger);
|
|
1368
|
-
}
|
|
1369
|
-
throw new TypeError(`Invalid ${optionName} ${signalInteger}: this signal integer does not exist.
|
|
1370
|
-
${getAvailableSignals()}`);
|
|
1371
|
-
};
|
|
1372
|
-
var getSignalsIntegerToName = () => new Map(Object.entries(constants.signals).reverse().map(([signalName, signalInteger]) => [signalInteger, signalName]));
|
|
1373
|
-
var signalsIntegerToName = getSignalsIntegerToName();
|
|
1374
|
-
var normalizeSignalName = (signalName, optionName) => {
|
|
1375
|
-
if (signalName in constants.signals) {
|
|
1376
|
-
return signalName;
|
|
1377
|
-
}
|
|
1378
|
-
if (signalName.toUpperCase() in constants.signals) {
|
|
1379
|
-
throw new TypeError(`Invalid ${optionName} '${signalName}': please rename it to '${signalName.toUpperCase()}'.`);
|
|
1380
|
-
}
|
|
1381
|
-
throw new TypeError(`Invalid ${optionName} '${signalName}': this signal name does not exist.
|
|
1382
|
-
${getAvailableSignals()}`);
|
|
1383
|
-
};
|
|
1384
|
-
var getAvailableSignals = () => `Available signal names: ${getAvailableSignalNames()}.
|
|
1385
|
-
Available signal numbers: ${getAvailableSignalIntegers()}.`;
|
|
1386
|
-
var getAvailableSignalNames = () => Object.keys(constants.signals).sort().map((signalName) => `'${signalName}'`).join(", ");
|
|
1387
|
-
var getAvailableSignalIntegers = () => [...new Set(Object.values(constants.signals).sort((signalInteger, signalIntegerTwo) => signalInteger - signalIntegerTwo))].join(", ");
|
|
1356
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/terminate/signal.js
|
|
1357
|
+
import { constants as constants3 } from "node:os";
|
|
1388
1358
|
|
|
1389
|
-
// ../../node_modules/.pnpm/
|
|
1390
|
-
|
|
1391
|
-
if (forceKillAfterDelay === false) {
|
|
1392
|
-
return forceKillAfterDelay;
|
|
1393
|
-
}
|
|
1394
|
-
if (forceKillAfterDelay === true) {
|
|
1395
|
-
return DEFAULT_FORCE_KILL_TIMEOUT;
|
|
1396
|
-
}
|
|
1397
|
-
if (!Number.isFinite(forceKillAfterDelay) || forceKillAfterDelay < 0) {
|
|
1398
|
-
throw new TypeError(`Expected the \`forceKillAfterDelay\` option to be a non-negative integer, got \`${forceKillAfterDelay}\` (${typeof forceKillAfterDelay})`);
|
|
1399
|
-
}
|
|
1400
|
-
return forceKillAfterDelay;
|
|
1401
|
-
};
|
|
1402
|
-
var DEFAULT_FORCE_KILL_TIMEOUT = 1e3 * 5;
|
|
1403
|
-
var subprocessKill = ({ kill, options: { forceKillAfterDelay, killSignal }, onInternalError, controller }, signalOrError, errorArgument) => {
|
|
1404
|
-
const { signal, error } = parseKillArguments(signalOrError, errorArgument, killSignal);
|
|
1405
|
-
emitKillError(error, onInternalError);
|
|
1406
|
-
const killResult = kill(signal);
|
|
1407
|
-
setKillTimeout({
|
|
1408
|
-
kill,
|
|
1409
|
-
signal,
|
|
1410
|
-
forceKillAfterDelay,
|
|
1411
|
-
killSignal,
|
|
1412
|
-
killResult,
|
|
1413
|
-
controller
|
|
1414
|
-
});
|
|
1415
|
-
return killResult;
|
|
1416
|
-
};
|
|
1417
|
-
var parseKillArguments = (signalOrError, errorArgument, killSignal) => {
|
|
1418
|
-
const [signal = killSignal, error] = isErrorInstance(signalOrError) ? [void 0, signalOrError] : [signalOrError, errorArgument];
|
|
1419
|
-
if (typeof signal !== "string" && !Number.isInteger(signal)) {
|
|
1420
|
-
throw new TypeError(`The first argument must be an error instance or a signal name string/integer: ${String(signal)}`);
|
|
1421
|
-
}
|
|
1422
|
-
if (error !== void 0 && !isErrorInstance(error)) {
|
|
1423
|
-
throw new TypeError(`The second argument is optional. If specified, it must be an error instance: ${error}`);
|
|
1424
|
-
}
|
|
1425
|
-
return { signal: normalizeSignalArgument(signal), error };
|
|
1426
|
-
};
|
|
1427
|
-
var emitKillError = (error, onInternalError) => {
|
|
1428
|
-
if (error !== void 0) {
|
|
1429
|
-
onInternalError.reject(error);
|
|
1430
|
-
}
|
|
1431
|
-
};
|
|
1432
|
-
var setKillTimeout = async ({ kill, signal, forceKillAfterDelay, killSignal, killResult, controller }) => {
|
|
1433
|
-
if (!shouldForceKill(signal, forceKillAfterDelay, killSignal, killResult)) {
|
|
1434
|
-
return;
|
|
1435
|
-
}
|
|
1436
|
-
try {
|
|
1437
|
-
await setTimeout(forceKillAfterDelay, void 0, { signal: controller.signal });
|
|
1438
|
-
kill("SIGKILL");
|
|
1439
|
-
} catch {
|
|
1440
|
-
}
|
|
1441
|
-
};
|
|
1442
|
-
var shouldForceKill = (signal, forceKillAfterDelay, killSignal, killResult) => signal === killSignal && forceKillAfterDelay !== false && killResult;
|
|
1359
|
+
// ../../node_modules/.pnpm/human-signals@7.0.0/node_modules/human-signals/build/src/main.js
|
|
1360
|
+
import { constants as constants2 } from "node:os";
|
|
1443
1361
|
|
|
1444
|
-
// ../../node_modules/.pnpm/
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${timeout}\` (${typeof timeout})`);
|
|
1449
|
-
}
|
|
1450
|
-
};
|
|
1451
|
-
var throwOnTimeout = (subprocess, timeout, context, controller) => timeout === 0 || timeout === void 0 ? [] : [killAfterTimeout(subprocess, timeout, context, controller)];
|
|
1452
|
-
var killAfterTimeout = async (subprocess, timeout, context, { signal }) => {
|
|
1453
|
-
await setTimeout2(timeout, void 0, { signal });
|
|
1454
|
-
context.timedOut = true;
|
|
1455
|
-
subprocess.kill();
|
|
1456
|
-
throw new DiscardedError();
|
|
1362
|
+
// ../../node_modules/.pnpm/human-signals@7.0.0/node_modules/human-signals/build/src/realtime.js
|
|
1363
|
+
var getRealtimeSignals = () => {
|
|
1364
|
+
const length = SIGRTMAX - SIGRTMIN + 1;
|
|
1365
|
+
return Array.from({ length }, getRealtimeSignal);
|
|
1457
1366
|
};
|
|
1367
|
+
var getRealtimeSignal = (value, index) => ({
|
|
1368
|
+
name: `SIGRT${index + 1}`,
|
|
1369
|
+
number: SIGRTMIN + index,
|
|
1370
|
+
action: "terminate",
|
|
1371
|
+
description: "Application-specific signal (realtime)",
|
|
1372
|
+
standard: "posix"
|
|
1373
|
+
});
|
|
1374
|
+
var SIGRTMIN = 34;
|
|
1375
|
+
var SIGRTMAX = 64;
|
|
1458
1376
|
|
|
1459
|
-
// ../../node_modules/.pnpm/
|
|
1460
|
-
import {
|
|
1461
|
-
import { basename, resolve } from "node:path";
|
|
1462
|
-
var mapNode = ({ options }) => {
|
|
1463
|
-
if (options.node === false) {
|
|
1464
|
-
throw new TypeError('The "node" option cannot be false with `execaNode()`.');
|
|
1465
|
-
}
|
|
1466
|
-
return { options: { ...options, node: true } };
|
|
1467
|
-
};
|
|
1468
|
-
var handleNodeOption = (file, commandArguments, {
|
|
1469
|
-
node: shouldHandleNode = false,
|
|
1470
|
-
nodePath = execPath,
|
|
1471
|
-
nodeOptions = execArgv.filter((nodeOption) => !nodeOption.startsWith("--inspect")),
|
|
1472
|
-
cwd,
|
|
1473
|
-
execPath: formerNodePath,
|
|
1474
|
-
...options
|
|
1475
|
-
}) => {
|
|
1476
|
-
if (formerNodePath !== void 0) {
|
|
1477
|
-
throw new TypeError('The "execPath" option has been removed. Please use the "nodePath" option instead.');
|
|
1478
|
-
}
|
|
1479
|
-
const normalizedNodePath = safeNormalizeFileUrl(nodePath, 'The "nodePath" option');
|
|
1480
|
-
const resolvedNodePath = resolve(cwd, normalizedNodePath);
|
|
1481
|
-
const newOptions = {
|
|
1482
|
-
...options,
|
|
1483
|
-
nodePath: resolvedNodePath,
|
|
1484
|
-
node: shouldHandleNode,
|
|
1485
|
-
cwd
|
|
1486
|
-
};
|
|
1487
|
-
if (!shouldHandleNode) {
|
|
1488
|
-
return [file, commandArguments, newOptions];
|
|
1489
|
-
}
|
|
1490
|
-
if (basename(file, ".exe") === "node") {
|
|
1491
|
-
throw new TypeError('When the "node" option is true, the first argument does not need to be "node".');
|
|
1492
|
-
}
|
|
1493
|
-
return [
|
|
1494
|
-
resolvedNodePath,
|
|
1495
|
-
[...nodeOptions, file, ...commandArguments],
|
|
1496
|
-
{ ipc: true, ...newOptions, shell: false }
|
|
1497
|
-
];
|
|
1498
|
-
};
|
|
1499
|
-
|
|
1500
|
-
// ../../node_modules/.pnpm/execa@9.1.0/node_modules/execa/lib/arguments/encoding-option.js
|
|
1501
|
-
var validateEncoding = ({ encoding }) => {
|
|
1502
|
-
if (ENCODINGS.has(encoding)) {
|
|
1503
|
-
return;
|
|
1504
|
-
}
|
|
1505
|
-
const correctEncoding = getCorrectEncoding(encoding);
|
|
1506
|
-
if (correctEncoding !== void 0) {
|
|
1507
|
-
throw new TypeError(`Invalid option \`encoding: ${serializeEncoding(encoding)}\`.
|
|
1508
|
-
Please rename it to ${serializeEncoding(correctEncoding)}.`);
|
|
1509
|
-
}
|
|
1510
|
-
const correctEncodings = [...ENCODINGS].map((correctEncoding2) => serializeEncoding(correctEncoding2)).join(", ");
|
|
1511
|
-
throw new TypeError(`Invalid option \`encoding: ${serializeEncoding(encoding)}\`.
|
|
1512
|
-
Please rename it to one of: ${correctEncodings}.`);
|
|
1513
|
-
};
|
|
1514
|
-
var TEXT_ENCODINGS = /* @__PURE__ */ new Set(["utf8", "utf16le"]);
|
|
1515
|
-
var BINARY_ENCODINGS = /* @__PURE__ */ new Set(["buffer", "hex", "base64", "base64url", "latin1", "ascii"]);
|
|
1516
|
-
var ENCODINGS = /* @__PURE__ */ new Set([...TEXT_ENCODINGS, ...BINARY_ENCODINGS]);
|
|
1517
|
-
var getCorrectEncoding = (encoding) => {
|
|
1518
|
-
if (encoding === null) {
|
|
1519
|
-
return "buffer";
|
|
1520
|
-
}
|
|
1521
|
-
if (typeof encoding !== "string") {
|
|
1522
|
-
return;
|
|
1523
|
-
}
|
|
1524
|
-
const lowerEncoding = encoding.toLowerCase();
|
|
1525
|
-
if (lowerEncoding in ENCODING_ALIASES) {
|
|
1526
|
-
return ENCODING_ALIASES[lowerEncoding];
|
|
1527
|
-
}
|
|
1528
|
-
if (ENCODINGS.has(lowerEncoding)) {
|
|
1529
|
-
return lowerEncoding;
|
|
1530
|
-
}
|
|
1531
|
-
};
|
|
1532
|
-
var ENCODING_ALIASES = {
|
|
1533
|
-
// eslint-disable-next-line unicorn/text-encoding-identifier-case
|
|
1534
|
-
"utf-8": "utf8",
|
|
1535
|
-
"utf-16le": "utf16le",
|
|
1536
|
-
"ucs-2": "utf16le",
|
|
1537
|
-
ucs2: "utf16le",
|
|
1538
|
-
binary: "latin1"
|
|
1539
|
-
};
|
|
1540
|
-
var serializeEncoding = (encoding) => typeof encoding === "string" ? `"${encoding}"` : String(encoding);
|
|
1541
|
-
|
|
1542
|
-
// ../../node_modules/.pnpm/execa@9.1.0/node_modules/execa/lib/arguments/cwd.js
|
|
1543
|
-
import { statSync } from "node:fs";
|
|
1544
|
-
import { resolve as resolve2 } from "node:path";
|
|
1545
|
-
import process5 from "node:process";
|
|
1546
|
-
var normalizeCwd = (cwd = getDefaultCwd()) => {
|
|
1547
|
-
const cwdString = safeNormalizeFileUrl(cwd, 'The "cwd" option');
|
|
1548
|
-
return resolve2(cwdString);
|
|
1549
|
-
};
|
|
1550
|
-
var getDefaultCwd = () => {
|
|
1551
|
-
try {
|
|
1552
|
-
return process5.cwd();
|
|
1553
|
-
} catch (error) {
|
|
1554
|
-
error.message = `The current directory does not exist.
|
|
1555
|
-
${error.message}`;
|
|
1556
|
-
throw error;
|
|
1557
|
-
}
|
|
1558
|
-
};
|
|
1559
|
-
var fixCwdError = (originalMessage, cwd) => {
|
|
1560
|
-
if (cwd === getDefaultCwd()) {
|
|
1561
|
-
return originalMessage;
|
|
1562
|
-
}
|
|
1563
|
-
let cwdStat;
|
|
1564
|
-
try {
|
|
1565
|
-
cwdStat = statSync(cwd);
|
|
1566
|
-
} catch (error) {
|
|
1567
|
-
return `The "cwd" option is invalid: ${cwd}.
|
|
1568
|
-
${error.message}
|
|
1569
|
-
${originalMessage}`;
|
|
1570
|
-
}
|
|
1571
|
-
if (!cwdStat.isDirectory()) {
|
|
1572
|
-
return `The "cwd" option is not a directory: ${cwd}.
|
|
1573
|
-
${originalMessage}`;
|
|
1574
|
-
}
|
|
1575
|
-
return originalMessage;
|
|
1576
|
-
};
|
|
1577
|
-
|
|
1578
|
-
// ../../node_modules/.pnpm/execa@9.1.0/node_modules/execa/lib/arguments/options.js
|
|
1579
|
-
var normalizeOptions = (filePath, rawArguments, rawOptions) => {
|
|
1580
|
-
rawOptions.cwd = normalizeCwd(rawOptions.cwd);
|
|
1581
|
-
const [processedFile, processedArguments, processedOptions] = handleNodeOption(filePath, rawArguments, rawOptions);
|
|
1582
|
-
const { command: file, args: commandArguments, options: initialOptions } = import_cross_spawn.default._parse(processedFile, processedArguments, processedOptions);
|
|
1583
|
-
const fdOptions = normalizeFdSpecificOptions(initialOptions);
|
|
1584
|
-
const options = addDefaultOptions(fdOptions);
|
|
1585
|
-
validateTimeout(options);
|
|
1586
|
-
validateEncoding(options);
|
|
1587
|
-
options.shell = normalizeFileUrl(options.shell);
|
|
1588
|
-
options.env = getEnv(options);
|
|
1589
|
-
options.killSignal = normalizeKillSignal(options.killSignal);
|
|
1590
|
-
options.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);
|
|
1591
|
-
options.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);
|
|
1592
|
-
if (process6.platform === "win32" && basename2(file, ".exe") === "cmd") {
|
|
1593
|
-
commandArguments.unshift("/q");
|
|
1594
|
-
}
|
|
1595
|
-
return { file, commandArguments, options };
|
|
1596
|
-
};
|
|
1597
|
-
var addDefaultOptions = ({
|
|
1598
|
-
extendEnv = true,
|
|
1599
|
-
preferLocal = false,
|
|
1600
|
-
cwd,
|
|
1601
|
-
localDir: localDirectory = cwd,
|
|
1602
|
-
encoding = "utf8",
|
|
1603
|
-
reject = true,
|
|
1604
|
-
cleanup = true,
|
|
1605
|
-
all = false,
|
|
1606
|
-
windowsHide = true,
|
|
1607
|
-
killSignal = "SIGTERM",
|
|
1608
|
-
forceKillAfterDelay = true,
|
|
1609
|
-
ipc = false,
|
|
1610
|
-
serialization = "advanced",
|
|
1611
|
-
...options
|
|
1612
|
-
}) => ({
|
|
1613
|
-
...options,
|
|
1614
|
-
extendEnv,
|
|
1615
|
-
preferLocal,
|
|
1616
|
-
cwd,
|
|
1617
|
-
localDirectory,
|
|
1618
|
-
encoding,
|
|
1619
|
-
reject,
|
|
1620
|
-
cleanup,
|
|
1621
|
-
all,
|
|
1622
|
-
windowsHide,
|
|
1623
|
-
killSignal,
|
|
1624
|
-
forceKillAfterDelay,
|
|
1625
|
-
ipc,
|
|
1626
|
-
serialization
|
|
1627
|
-
});
|
|
1628
|
-
var getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath }) => {
|
|
1629
|
-
const env = extendEnv ? { ...process6.env, ...envOption } : envOption;
|
|
1630
|
-
if (preferLocal || node) {
|
|
1631
|
-
return npmRunPathEnv({
|
|
1632
|
-
env,
|
|
1633
|
-
cwd: localDirectory,
|
|
1634
|
-
execPath: nodePath,
|
|
1635
|
-
preferLocal,
|
|
1636
|
-
addExecPath: node
|
|
1637
|
-
});
|
|
1638
|
-
}
|
|
1639
|
-
return env;
|
|
1640
|
-
};
|
|
1641
|
-
|
|
1642
|
-
// ../../node_modules/.pnpm/human-signals@7.0.0/node_modules/human-signals/build/src/main.js
|
|
1643
|
-
import { constants as constants3 } from "node:os";
|
|
1644
|
-
|
|
1645
|
-
// ../../node_modules/.pnpm/human-signals@7.0.0/node_modules/human-signals/build/src/realtime.js
|
|
1646
|
-
var getRealtimeSignals = () => {
|
|
1647
|
-
const length = SIGRTMAX - SIGRTMIN + 1;
|
|
1648
|
-
return Array.from({ length }, getRealtimeSignal);
|
|
1649
|
-
};
|
|
1650
|
-
var getRealtimeSignal = (value, index) => ({
|
|
1651
|
-
name: `SIGRT${index + 1}`,
|
|
1652
|
-
number: SIGRTMIN + index,
|
|
1653
|
-
action: "terminate",
|
|
1654
|
-
description: "Application-specific signal (realtime)",
|
|
1655
|
-
standard: "posix"
|
|
1656
|
-
});
|
|
1657
|
-
var SIGRTMIN = 34;
|
|
1658
|
-
var SIGRTMAX = 64;
|
|
1659
|
-
|
|
1660
|
-
// ../../node_modules/.pnpm/human-signals@7.0.0/node_modules/human-signals/build/src/signals.js
|
|
1661
|
-
import { constants as constants2 } from "node:os";
|
|
1377
|
+
// ../../node_modules/.pnpm/human-signals@7.0.0/node_modules/human-signals/build/src/signals.js
|
|
1378
|
+
import { constants } from "node:os";
|
|
1662
1379
|
|
|
1663
1380
|
// ../../node_modules/.pnpm/human-signals@7.0.0/node_modules/human-signals/build/src/core.js
|
|
1664
1381
|
var SIGNALS = [
|
|
@@ -1936,10 +1653,10 @@ var SIGNALS = [
|
|
|
1936
1653
|
// ../../node_modules/.pnpm/human-signals@7.0.0/node_modules/human-signals/build/src/signals.js
|
|
1937
1654
|
var getSignals = () => {
|
|
1938
1655
|
const realtimeSignals = getRealtimeSignals();
|
|
1939
|
-
const signals2 = [...SIGNALS, ...realtimeSignals].map(
|
|
1656
|
+
const signals2 = [...SIGNALS, ...realtimeSignals].map(normalizeSignal);
|
|
1940
1657
|
return signals2;
|
|
1941
1658
|
};
|
|
1942
|
-
var
|
|
1659
|
+
var normalizeSignal = ({
|
|
1943
1660
|
name,
|
|
1944
1661
|
number: defaultNumber,
|
|
1945
1662
|
description,
|
|
@@ -1949,7 +1666,7 @@ var normalizeSignal2 = ({
|
|
|
1949
1666
|
}) => {
|
|
1950
1667
|
const {
|
|
1951
1668
|
signals: { [name]: constantSignal }
|
|
1952
|
-
} =
|
|
1669
|
+
} = constants;
|
|
1953
1670
|
const supported = constantSignal !== void 0;
|
|
1954
1671
|
const number = supported ? constantSignal : defaultNumber;
|
|
1955
1672
|
return { name, number, description, supported, action, forced, standard };
|
|
@@ -1998,13 +1715,977 @@ var getSignalByNumber = (number, signals2) => {
|
|
|
1998
1715
|
};
|
|
1999
1716
|
};
|
|
2000
1717
|
var findSignalByNumber = (number, signals2) => {
|
|
2001
|
-
const signal = signals2.find(({ name }) =>
|
|
1718
|
+
const signal = signals2.find(({ name }) => constants2.signals[name] === number);
|
|
2002
1719
|
if (signal !== void 0) {
|
|
2003
1720
|
return signal;
|
|
2004
1721
|
}
|
|
2005
|
-
return signals2.find((signalA) => signalA.number === number);
|
|
1722
|
+
return signals2.find((signalA) => signalA.number === number);
|
|
1723
|
+
};
|
|
1724
|
+
var signalsByNumber = getSignalsByNumber();
|
|
1725
|
+
|
|
1726
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/terminate/signal.js
|
|
1727
|
+
var normalizeKillSignal = (killSignal) => {
|
|
1728
|
+
const optionName = "option `killSignal`";
|
|
1729
|
+
if (killSignal === 0) {
|
|
1730
|
+
throw new TypeError(`Invalid ${optionName}: 0 cannot be used.`);
|
|
1731
|
+
}
|
|
1732
|
+
return normalizeSignal2(killSignal, optionName);
|
|
1733
|
+
};
|
|
1734
|
+
var normalizeSignalArgument = (signal) => signal === 0 ? signal : normalizeSignal2(signal, "`subprocess.kill()`'s argument");
|
|
1735
|
+
var normalizeSignal2 = (signalNameOrInteger, optionName) => {
|
|
1736
|
+
if (Number.isInteger(signalNameOrInteger)) {
|
|
1737
|
+
return normalizeSignalInteger(signalNameOrInteger, optionName);
|
|
1738
|
+
}
|
|
1739
|
+
if (typeof signalNameOrInteger === "string") {
|
|
1740
|
+
return normalizeSignalName(signalNameOrInteger, optionName);
|
|
1741
|
+
}
|
|
1742
|
+
throw new TypeError(`Invalid ${optionName} ${String(signalNameOrInteger)}: it must be a string or an integer.
|
|
1743
|
+
${getAvailableSignals()}`);
|
|
1744
|
+
};
|
|
1745
|
+
var normalizeSignalInteger = (signalInteger, optionName) => {
|
|
1746
|
+
if (signalsIntegerToName.has(signalInteger)) {
|
|
1747
|
+
return signalsIntegerToName.get(signalInteger);
|
|
1748
|
+
}
|
|
1749
|
+
throw new TypeError(`Invalid ${optionName} ${signalInteger}: this signal integer does not exist.
|
|
1750
|
+
${getAvailableSignals()}`);
|
|
1751
|
+
};
|
|
1752
|
+
var getSignalsIntegerToName = () => new Map(Object.entries(constants3.signals).reverse().map(([signalName, signalInteger]) => [signalInteger, signalName]));
|
|
1753
|
+
var signalsIntegerToName = getSignalsIntegerToName();
|
|
1754
|
+
var normalizeSignalName = (signalName, optionName) => {
|
|
1755
|
+
if (signalName in constants3.signals) {
|
|
1756
|
+
return signalName;
|
|
1757
|
+
}
|
|
1758
|
+
if (signalName.toUpperCase() in constants3.signals) {
|
|
1759
|
+
throw new TypeError(`Invalid ${optionName} '${signalName}': please rename it to '${signalName.toUpperCase()}'.`);
|
|
1760
|
+
}
|
|
1761
|
+
throw new TypeError(`Invalid ${optionName} '${signalName}': this signal name does not exist.
|
|
1762
|
+
${getAvailableSignals()}`);
|
|
1763
|
+
};
|
|
1764
|
+
var getAvailableSignals = () => `Available signal names: ${getAvailableSignalNames()}.
|
|
1765
|
+
Available signal numbers: ${getAvailableSignalIntegers()}.`;
|
|
1766
|
+
var getAvailableSignalNames = () => Object.keys(constants3.signals).sort().map((signalName) => `'${signalName}'`).join(", ");
|
|
1767
|
+
var getAvailableSignalIntegers = () => [...new Set(Object.values(constants3.signals).sort((signalInteger, signalIntegerTwo) => signalInteger - signalIntegerTwo))].join(", ");
|
|
1768
|
+
var getSignalDescription = (signal) => signalsByName[signal].description;
|
|
1769
|
+
|
|
1770
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/terminate/kill.js
|
|
1771
|
+
var normalizeForceKillAfterDelay = (forceKillAfterDelay) => {
|
|
1772
|
+
if (forceKillAfterDelay === false) {
|
|
1773
|
+
return forceKillAfterDelay;
|
|
1774
|
+
}
|
|
1775
|
+
if (forceKillAfterDelay === true) {
|
|
1776
|
+
return DEFAULT_FORCE_KILL_TIMEOUT;
|
|
1777
|
+
}
|
|
1778
|
+
if (!Number.isFinite(forceKillAfterDelay) || forceKillAfterDelay < 0) {
|
|
1779
|
+
throw new TypeError(`Expected the \`forceKillAfterDelay\` option to be a non-negative integer, got \`${forceKillAfterDelay}\` (${typeof forceKillAfterDelay})`);
|
|
1780
|
+
}
|
|
1781
|
+
return forceKillAfterDelay;
|
|
1782
|
+
};
|
|
1783
|
+
var DEFAULT_FORCE_KILL_TIMEOUT = 1e3 * 5;
|
|
1784
|
+
var subprocessKill = ({ kill, options: { forceKillAfterDelay, killSignal }, onInternalError, context, controller }, signalOrError, errorArgument) => {
|
|
1785
|
+
const { signal, error } = parseKillArguments(signalOrError, errorArgument, killSignal);
|
|
1786
|
+
emitKillError(error, onInternalError);
|
|
1787
|
+
const killResult = kill(signal);
|
|
1788
|
+
setKillTimeout({
|
|
1789
|
+
kill,
|
|
1790
|
+
signal,
|
|
1791
|
+
forceKillAfterDelay,
|
|
1792
|
+
killSignal,
|
|
1793
|
+
killResult,
|
|
1794
|
+
context,
|
|
1795
|
+
controller
|
|
1796
|
+
});
|
|
1797
|
+
return killResult;
|
|
1798
|
+
};
|
|
1799
|
+
var parseKillArguments = (signalOrError, errorArgument, killSignal) => {
|
|
1800
|
+
const [signal = killSignal, error] = isErrorInstance(signalOrError) ? [void 0, signalOrError] : [signalOrError, errorArgument];
|
|
1801
|
+
if (typeof signal !== "string" && !Number.isInteger(signal)) {
|
|
1802
|
+
throw new TypeError(`The first argument must be an error instance or a signal name string/integer: ${String(signal)}`);
|
|
1803
|
+
}
|
|
1804
|
+
if (error !== void 0 && !isErrorInstance(error)) {
|
|
1805
|
+
throw new TypeError(`The second argument is optional. If specified, it must be an error instance: ${error}`);
|
|
1806
|
+
}
|
|
1807
|
+
return { signal: normalizeSignalArgument(signal), error };
|
|
1808
|
+
};
|
|
1809
|
+
var emitKillError = (error, onInternalError) => {
|
|
1810
|
+
if (error !== void 0) {
|
|
1811
|
+
onInternalError.reject(error);
|
|
1812
|
+
}
|
|
1813
|
+
};
|
|
1814
|
+
var setKillTimeout = async ({ kill, signal, forceKillAfterDelay, killSignal, killResult, context, controller }) => {
|
|
1815
|
+
if (signal === killSignal && killResult) {
|
|
1816
|
+
killOnTimeout({
|
|
1817
|
+
kill,
|
|
1818
|
+
forceKillAfterDelay,
|
|
1819
|
+
context,
|
|
1820
|
+
controllerSignal: controller.signal
|
|
1821
|
+
});
|
|
1822
|
+
}
|
|
1823
|
+
};
|
|
1824
|
+
var killOnTimeout = async ({ kill, forceKillAfterDelay, context, controllerSignal }) => {
|
|
1825
|
+
if (forceKillAfterDelay === false) {
|
|
1826
|
+
return;
|
|
1827
|
+
}
|
|
1828
|
+
try {
|
|
1829
|
+
await setTimeout(forceKillAfterDelay, void 0, { signal: controllerSignal });
|
|
1830
|
+
if (kill("SIGKILL")) {
|
|
1831
|
+
context.isForcefullyTerminated ??= true;
|
|
1832
|
+
}
|
|
1833
|
+
} catch {
|
|
1834
|
+
}
|
|
1835
|
+
};
|
|
1836
|
+
|
|
1837
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/utils/abort-signal.js
|
|
1838
|
+
import { once } from "node:events";
|
|
1839
|
+
var onAbortedSignal = async (mainSignal, stopSignal) => {
|
|
1840
|
+
if (!mainSignal.aborted) {
|
|
1841
|
+
await once(mainSignal, "abort", { signal: stopSignal });
|
|
1842
|
+
}
|
|
1843
|
+
};
|
|
1844
|
+
|
|
1845
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/terminate/cancel.js
|
|
1846
|
+
var validateCancelSignal = ({ cancelSignal }) => {
|
|
1847
|
+
if (cancelSignal !== void 0 && Object.prototype.toString.call(cancelSignal) !== "[object AbortSignal]") {
|
|
1848
|
+
throw new Error(`The \`cancelSignal\` option must be an AbortSignal: ${String(cancelSignal)}`);
|
|
1849
|
+
}
|
|
1850
|
+
};
|
|
1851
|
+
var throwOnCancel = ({ subprocess, cancelSignal, gracefulCancel, context, controller }) => cancelSignal === void 0 || gracefulCancel ? [] : [terminateOnCancel(subprocess, cancelSignal, context, controller)];
|
|
1852
|
+
var terminateOnCancel = async (subprocess, cancelSignal, context, { signal }) => {
|
|
1853
|
+
await onAbortedSignal(cancelSignal, signal);
|
|
1854
|
+
context.terminationReason ??= "cancel";
|
|
1855
|
+
subprocess.kill();
|
|
1856
|
+
throw cancelSignal.reason;
|
|
1857
|
+
};
|
|
1858
|
+
|
|
1859
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/graceful.js
|
|
1860
|
+
import { scheduler as scheduler2 } from "node:timers/promises";
|
|
1861
|
+
|
|
1862
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/send.js
|
|
1863
|
+
import { promisify } from "node:util";
|
|
1864
|
+
|
|
1865
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/validation.js
|
|
1866
|
+
var validateIpcMethod = ({ methodName, isSubprocess, ipc, isConnected: isConnected2 }) => {
|
|
1867
|
+
validateIpcOption(methodName, isSubprocess, ipc);
|
|
1868
|
+
validateConnection(methodName, isSubprocess, isConnected2);
|
|
1869
|
+
};
|
|
1870
|
+
var validateIpcOption = (methodName, isSubprocess, ipc) => {
|
|
1871
|
+
if (!ipc) {
|
|
1872
|
+
throw new Error(`${getMethodName(methodName, isSubprocess)} can only be used if the \`ipc\` option is \`true\`.`);
|
|
1873
|
+
}
|
|
1874
|
+
};
|
|
1875
|
+
var validateConnection = (methodName, isSubprocess, isConnected2) => {
|
|
1876
|
+
if (!isConnected2) {
|
|
1877
|
+
throw new Error(`${getMethodName(methodName, isSubprocess)} cannot be used: the ${getOtherProcessName(isSubprocess)} has already exited or disconnected.`);
|
|
1878
|
+
}
|
|
1879
|
+
};
|
|
1880
|
+
var throwOnEarlyDisconnect = (isSubprocess) => {
|
|
1881
|
+
throw new Error(`${getMethodName("getOneMessage", isSubprocess)} could not complete: the ${getOtherProcessName(isSubprocess)} exited or disconnected.`);
|
|
1882
|
+
};
|
|
1883
|
+
var throwOnStrictDeadlockError = (isSubprocess) => {
|
|
1884
|
+
throw new Error(`${getMethodName("sendMessage", isSubprocess)} failed: the ${getOtherProcessName(isSubprocess)} is sending a message too, instead of listening to incoming messages.
|
|
1885
|
+
This can be fixed by both sending a message and listening to incoming messages at the same time:
|
|
1886
|
+
|
|
1887
|
+
const [receivedMessage] = await Promise.all([
|
|
1888
|
+
${getMethodName("getOneMessage", isSubprocess)},
|
|
1889
|
+
${getMethodName("sendMessage", isSubprocess, "message, {strict: true}")},
|
|
1890
|
+
]);`);
|
|
1891
|
+
};
|
|
1892
|
+
var getStrictResponseError = (error, isSubprocess) => new Error(`${getMethodName("sendMessage", isSubprocess)} failed when sending an acknowledgment response to the ${getOtherProcessName(isSubprocess)}.`, { cause: error });
|
|
1893
|
+
var throwOnMissingStrict = (isSubprocess) => {
|
|
1894
|
+
throw new Error(`${getMethodName("sendMessage", isSubprocess)} failed: the ${getOtherProcessName(isSubprocess)} is not listening to incoming messages.`);
|
|
1895
|
+
};
|
|
1896
|
+
var throwOnStrictDisconnect = (isSubprocess) => {
|
|
1897
|
+
throw new Error(`${getMethodName("sendMessage", isSubprocess)} failed: the ${getOtherProcessName(isSubprocess)} exited without listening to incoming messages.`);
|
|
1898
|
+
};
|
|
1899
|
+
var getAbortDisconnectError = () => new Error(`\`cancelSignal\` aborted: the ${getOtherProcessName(true)} disconnected.`);
|
|
1900
|
+
var throwOnMissingParent = () => {
|
|
1901
|
+
throw new Error("`getCancelSignal()` cannot be used without setting the `cancelSignal` subprocess option.");
|
|
1902
|
+
};
|
|
1903
|
+
var handleEpipeError = ({ error, methodName, isSubprocess }) => {
|
|
1904
|
+
if (error.code === "EPIPE") {
|
|
1905
|
+
throw new Error(`${getMethodName(methodName, isSubprocess)} cannot be used: the ${getOtherProcessName(isSubprocess)} is disconnecting.`, { cause: error });
|
|
1906
|
+
}
|
|
1907
|
+
};
|
|
1908
|
+
var handleSerializationError = ({ error, methodName, isSubprocess, message }) => {
|
|
1909
|
+
if (isSerializationError(error)) {
|
|
1910
|
+
throw new Error(`${getMethodName(methodName, isSubprocess)}'s argument type is invalid: the message cannot be serialized: ${String(message)}.`, { cause: error });
|
|
1911
|
+
}
|
|
1912
|
+
};
|
|
1913
|
+
var isSerializationError = ({ code, message }) => SERIALIZATION_ERROR_CODES.has(code) || SERIALIZATION_ERROR_MESSAGES.some((serializationErrorMessage) => message.includes(serializationErrorMessage));
|
|
1914
|
+
var SERIALIZATION_ERROR_CODES = /* @__PURE__ */ new Set([
|
|
1915
|
+
// Message is `undefined`
|
|
1916
|
+
"ERR_MISSING_ARGS",
|
|
1917
|
+
// Message is a function, a bigint, a symbol
|
|
1918
|
+
"ERR_INVALID_ARG_TYPE"
|
|
1919
|
+
]);
|
|
1920
|
+
var SERIALIZATION_ERROR_MESSAGES = [
|
|
1921
|
+
// Message is a promise or a proxy, with `serialization: 'advanced'`
|
|
1922
|
+
"could not be cloned",
|
|
1923
|
+
// Message has cycles, with `serialization: 'json'`
|
|
1924
|
+
"circular structure",
|
|
1925
|
+
// Message has cycles inside toJSON(), with `serialization: 'json'`
|
|
1926
|
+
"call stack size exceeded"
|
|
1927
|
+
];
|
|
1928
|
+
var getMethodName = (methodName, isSubprocess, parameters = "") => methodName === "cancelSignal" ? "`cancelSignal`'s `controller.abort()`" : `${getNamespaceName(isSubprocess)}${methodName}(${parameters})`;
|
|
1929
|
+
var getNamespaceName = (isSubprocess) => isSubprocess ? "" : "subprocess.";
|
|
1930
|
+
var getOtherProcessName = (isSubprocess) => isSubprocess ? "parent process" : "subprocess";
|
|
1931
|
+
var disconnect = (anyProcess) => {
|
|
1932
|
+
if (anyProcess.connected) {
|
|
1933
|
+
anyProcess.disconnect();
|
|
1934
|
+
}
|
|
1935
|
+
};
|
|
1936
|
+
|
|
1937
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/utils/deferred.js
|
|
1938
|
+
var createDeferred = () => {
|
|
1939
|
+
const methods = {};
|
|
1940
|
+
const promise = new Promise((resolve3, reject) => {
|
|
1941
|
+
Object.assign(methods, { resolve: resolve3, reject });
|
|
1942
|
+
});
|
|
1943
|
+
return Object.assign(promise, methods);
|
|
1944
|
+
};
|
|
1945
|
+
|
|
1946
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/arguments/fd-options.js
|
|
1947
|
+
var getToStream = (destination, to = "stdin") => {
|
|
1948
|
+
const isWritable = true;
|
|
1949
|
+
const { options, fileDescriptors } = SUBPROCESS_OPTIONS.get(destination);
|
|
1950
|
+
const fdNumber = getFdNumber(fileDescriptors, to, isWritable);
|
|
1951
|
+
const destinationStream = destination.stdio[fdNumber];
|
|
1952
|
+
if (destinationStream === null) {
|
|
1953
|
+
throw new TypeError(getInvalidStdioOptionMessage(fdNumber, to, options, isWritable));
|
|
1954
|
+
}
|
|
1955
|
+
return destinationStream;
|
|
1956
|
+
};
|
|
1957
|
+
var getFromStream = (source, from = "stdout") => {
|
|
1958
|
+
const isWritable = false;
|
|
1959
|
+
const { options, fileDescriptors } = SUBPROCESS_OPTIONS.get(source);
|
|
1960
|
+
const fdNumber = getFdNumber(fileDescriptors, from, isWritable);
|
|
1961
|
+
const sourceStream = fdNumber === "all" ? source.all : source.stdio[fdNumber];
|
|
1962
|
+
if (sourceStream === null || sourceStream === void 0) {
|
|
1963
|
+
throw new TypeError(getInvalidStdioOptionMessage(fdNumber, from, options, isWritable));
|
|
1964
|
+
}
|
|
1965
|
+
return sourceStream;
|
|
1966
|
+
};
|
|
1967
|
+
var SUBPROCESS_OPTIONS = /* @__PURE__ */ new WeakMap();
|
|
1968
|
+
var getFdNumber = (fileDescriptors, fdName, isWritable) => {
|
|
1969
|
+
const fdNumber = parseFdNumber(fdName, isWritable);
|
|
1970
|
+
validateFdNumber(fdNumber, fdName, isWritable, fileDescriptors);
|
|
1971
|
+
return fdNumber;
|
|
1972
|
+
};
|
|
1973
|
+
var parseFdNumber = (fdName, isWritable) => {
|
|
1974
|
+
const fdNumber = parseFd(fdName);
|
|
1975
|
+
if (fdNumber !== void 0) {
|
|
1976
|
+
return fdNumber;
|
|
1977
|
+
}
|
|
1978
|
+
const { validOptions, defaultValue } = isWritable ? { validOptions: '"stdin"', defaultValue: "stdin" } : { validOptions: '"stdout", "stderr", "all"', defaultValue: "stdout" };
|
|
1979
|
+
throw new TypeError(`"${getOptionName(isWritable)}" must not be "${fdName}".
|
|
1980
|
+
It must be ${validOptions} or "fd3", "fd4" (and so on).
|
|
1981
|
+
It is optional and defaults to "${defaultValue}".`);
|
|
1982
|
+
};
|
|
1983
|
+
var validateFdNumber = (fdNumber, fdName, isWritable, fileDescriptors) => {
|
|
1984
|
+
const fileDescriptor = fileDescriptors[getUsedDescriptor(fdNumber)];
|
|
1985
|
+
if (fileDescriptor === void 0) {
|
|
1986
|
+
throw new TypeError(`"${getOptionName(isWritable)}" must not be ${fdName}. That file descriptor does not exist.
|
|
1987
|
+
Please set the "stdio" option to ensure that file descriptor exists.`);
|
|
1988
|
+
}
|
|
1989
|
+
if (fileDescriptor.direction === "input" && !isWritable) {
|
|
1990
|
+
throw new TypeError(`"${getOptionName(isWritable)}" must not be ${fdName}. It must be a readable stream, not writable.`);
|
|
1991
|
+
}
|
|
1992
|
+
if (fileDescriptor.direction !== "input" && isWritable) {
|
|
1993
|
+
throw new TypeError(`"${getOptionName(isWritable)}" must not be ${fdName}. It must be a writable stream, not readable.`);
|
|
1994
|
+
}
|
|
1995
|
+
};
|
|
1996
|
+
var getInvalidStdioOptionMessage = (fdNumber, fdName, options, isWritable) => {
|
|
1997
|
+
if (fdNumber === "all" && !options.all) {
|
|
1998
|
+
return `The "all" option must be true to use "from: 'all'".`;
|
|
1999
|
+
}
|
|
2000
|
+
const { optionName, optionValue } = getInvalidStdioOption(fdNumber, options);
|
|
2001
|
+
return `The "${optionName}: ${serializeOptionValue(optionValue)}" option is incompatible with using "${getOptionName(isWritable)}: ${serializeOptionValue(fdName)}".
|
|
2002
|
+
Please set this option with "pipe" instead.`;
|
|
2003
|
+
};
|
|
2004
|
+
var getInvalidStdioOption = (fdNumber, { stdin, stdout, stderr, stdio }) => {
|
|
2005
|
+
const usedDescriptor = getUsedDescriptor(fdNumber);
|
|
2006
|
+
if (usedDescriptor === 0 && stdin !== void 0) {
|
|
2007
|
+
return { optionName: "stdin", optionValue: stdin };
|
|
2008
|
+
}
|
|
2009
|
+
if (usedDescriptor === 1 && stdout !== void 0) {
|
|
2010
|
+
return { optionName: "stdout", optionValue: stdout };
|
|
2011
|
+
}
|
|
2012
|
+
if (usedDescriptor === 2 && stderr !== void 0) {
|
|
2013
|
+
return { optionName: "stderr", optionValue: stderr };
|
|
2014
|
+
}
|
|
2015
|
+
return { optionName: `stdio[${usedDescriptor}]`, optionValue: stdio[usedDescriptor] };
|
|
2016
|
+
};
|
|
2017
|
+
var getUsedDescriptor = (fdNumber) => fdNumber === "all" ? 1 : fdNumber;
|
|
2018
|
+
var getOptionName = (isWritable) => isWritable ? "to" : "from";
|
|
2019
|
+
var serializeOptionValue = (value) => {
|
|
2020
|
+
if (typeof value === "string") {
|
|
2021
|
+
return `'${value}'`;
|
|
2022
|
+
}
|
|
2023
|
+
return typeof value === "number" ? `${value}` : "Stream";
|
|
2024
|
+
};
|
|
2025
|
+
|
|
2026
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/strict.js
|
|
2027
|
+
import { once as once3 } from "node:events";
|
|
2028
|
+
|
|
2029
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/utils/max-listeners.js
|
|
2030
|
+
import { addAbortListener } from "node:events";
|
|
2031
|
+
var incrementMaxListeners = (eventEmitter, maxListenersIncrement, signal) => {
|
|
2032
|
+
const maxListeners = eventEmitter.getMaxListeners();
|
|
2033
|
+
if (maxListeners === 0 || maxListeners === Number.POSITIVE_INFINITY) {
|
|
2034
|
+
return;
|
|
2035
|
+
}
|
|
2036
|
+
eventEmitter.setMaxListeners(maxListeners + maxListenersIncrement);
|
|
2037
|
+
addAbortListener(signal, () => {
|
|
2038
|
+
eventEmitter.setMaxListeners(eventEmitter.getMaxListeners() - maxListenersIncrement);
|
|
2039
|
+
});
|
|
2040
|
+
};
|
|
2041
|
+
|
|
2042
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/forward.js
|
|
2043
|
+
import { EventEmitter } from "node:events";
|
|
2044
|
+
|
|
2045
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/incoming.js
|
|
2046
|
+
import { once as once2 } from "node:events";
|
|
2047
|
+
import { scheduler } from "node:timers/promises";
|
|
2048
|
+
|
|
2049
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/reference.js
|
|
2050
|
+
var addReference = (channel, reference) => {
|
|
2051
|
+
if (reference) {
|
|
2052
|
+
addReferenceCount(channel);
|
|
2053
|
+
}
|
|
2054
|
+
};
|
|
2055
|
+
var addReferenceCount = (channel) => {
|
|
2056
|
+
channel.refCounted();
|
|
2057
|
+
};
|
|
2058
|
+
var removeReference = (channel, reference) => {
|
|
2059
|
+
if (reference) {
|
|
2060
|
+
removeReferenceCount(channel);
|
|
2061
|
+
}
|
|
2062
|
+
};
|
|
2063
|
+
var removeReferenceCount = (channel) => {
|
|
2064
|
+
channel.unrefCounted();
|
|
2065
|
+
};
|
|
2066
|
+
var undoAddedReferences = (channel, isSubprocess) => {
|
|
2067
|
+
if (isSubprocess) {
|
|
2068
|
+
removeReferenceCount(channel);
|
|
2069
|
+
removeReferenceCount(channel);
|
|
2070
|
+
}
|
|
2071
|
+
};
|
|
2072
|
+
var redoAddedReferences = (channel, isSubprocess) => {
|
|
2073
|
+
if (isSubprocess) {
|
|
2074
|
+
addReferenceCount(channel);
|
|
2075
|
+
addReferenceCount(channel);
|
|
2076
|
+
}
|
|
2077
|
+
};
|
|
2078
|
+
|
|
2079
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/incoming.js
|
|
2080
|
+
var onMessage = async ({ anyProcess, channel, isSubprocess, ipcEmitter }, wrappedMessage) => {
|
|
2081
|
+
if (handleStrictResponse(wrappedMessage) || handleAbort(wrappedMessage)) {
|
|
2082
|
+
return;
|
|
2083
|
+
}
|
|
2084
|
+
if (!INCOMING_MESSAGES.has(anyProcess)) {
|
|
2085
|
+
INCOMING_MESSAGES.set(anyProcess, []);
|
|
2086
|
+
}
|
|
2087
|
+
const incomingMessages = INCOMING_MESSAGES.get(anyProcess);
|
|
2088
|
+
incomingMessages.push(wrappedMessage);
|
|
2089
|
+
if (incomingMessages.length > 1) {
|
|
2090
|
+
return;
|
|
2091
|
+
}
|
|
2092
|
+
while (incomingMessages.length > 0) {
|
|
2093
|
+
await waitForOutgoingMessages(anyProcess, ipcEmitter, wrappedMessage);
|
|
2094
|
+
await scheduler.yield();
|
|
2095
|
+
const message = await handleStrictRequest({
|
|
2096
|
+
wrappedMessage: incomingMessages[0],
|
|
2097
|
+
anyProcess,
|
|
2098
|
+
channel,
|
|
2099
|
+
isSubprocess,
|
|
2100
|
+
ipcEmitter
|
|
2101
|
+
});
|
|
2102
|
+
incomingMessages.shift();
|
|
2103
|
+
ipcEmitter.emit("message", message);
|
|
2104
|
+
ipcEmitter.emit("message:done");
|
|
2105
|
+
}
|
|
2106
|
+
};
|
|
2107
|
+
var onDisconnect = async ({ anyProcess, channel, isSubprocess, ipcEmitter, boundOnMessage }) => {
|
|
2108
|
+
abortOnDisconnect();
|
|
2109
|
+
const incomingMessages = INCOMING_MESSAGES.get(anyProcess);
|
|
2110
|
+
while (incomingMessages?.length > 0) {
|
|
2111
|
+
await once2(ipcEmitter, "message:done");
|
|
2112
|
+
}
|
|
2113
|
+
anyProcess.removeListener("message", boundOnMessage);
|
|
2114
|
+
redoAddedReferences(channel, isSubprocess);
|
|
2115
|
+
ipcEmitter.connected = false;
|
|
2116
|
+
ipcEmitter.emit("disconnect");
|
|
2117
|
+
};
|
|
2118
|
+
var INCOMING_MESSAGES = /* @__PURE__ */ new WeakMap();
|
|
2119
|
+
|
|
2120
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/forward.js
|
|
2121
|
+
var getIpcEmitter = (anyProcess, channel, isSubprocess) => {
|
|
2122
|
+
if (IPC_EMITTERS.has(anyProcess)) {
|
|
2123
|
+
return IPC_EMITTERS.get(anyProcess);
|
|
2124
|
+
}
|
|
2125
|
+
const ipcEmitter = new EventEmitter();
|
|
2126
|
+
ipcEmitter.connected = true;
|
|
2127
|
+
IPC_EMITTERS.set(anyProcess, ipcEmitter);
|
|
2128
|
+
forwardEvents({
|
|
2129
|
+
ipcEmitter,
|
|
2130
|
+
anyProcess,
|
|
2131
|
+
channel,
|
|
2132
|
+
isSubprocess
|
|
2133
|
+
});
|
|
2134
|
+
return ipcEmitter;
|
|
2135
|
+
};
|
|
2136
|
+
var IPC_EMITTERS = /* @__PURE__ */ new WeakMap();
|
|
2137
|
+
var forwardEvents = ({ ipcEmitter, anyProcess, channel, isSubprocess }) => {
|
|
2138
|
+
const boundOnMessage = onMessage.bind(void 0, {
|
|
2139
|
+
anyProcess,
|
|
2140
|
+
channel,
|
|
2141
|
+
isSubprocess,
|
|
2142
|
+
ipcEmitter
|
|
2143
|
+
});
|
|
2144
|
+
anyProcess.on("message", boundOnMessage);
|
|
2145
|
+
anyProcess.once("disconnect", onDisconnect.bind(void 0, {
|
|
2146
|
+
anyProcess,
|
|
2147
|
+
channel,
|
|
2148
|
+
isSubprocess,
|
|
2149
|
+
ipcEmitter,
|
|
2150
|
+
boundOnMessage
|
|
2151
|
+
}));
|
|
2152
|
+
undoAddedReferences(channel, isSubprocess);
|
|
2153
|
+
};
|
|
2154
|
+
var isConnected = (anyProcess) => {
|
|
2155
|
+
const ipcEmitter = IPC_EMITTERS.get(anyProcess);
|
|
2156
|
+
return ipcEmitter === void 0 ? anyProcess.channel !== null : ipcEmitter.connected;
|
|
2157
|
+
};
|
|
2158
|
+
|
|
2159
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/strict.js
|
|
2160
|
+
var handleSendStrict = ({ anyProcess, channel, isSubprocess, message, strict }) => {
|
|
2161
|
+
if (!strict) {
|
|
2162
|
+
return message;
|
|
2163
|
+
}
|
|
2164
|
+
const ipcEmitter = getIpcEmitter(anyProcess, channel, isSubprocess);
|
|
2165
|
+
const hasListeners = hasMessageListeners(anyProcess, ipcEmitter);
|
|
2166
|
+
return {
|
|
2167
|
+
id: count++,
|
|
2168
|
+
type: REQUEST_TYPE,
|
|
2169
|
+
message,
|
|
2170
|
+
hasListeners
|
|
2171
|
+
};
|
|
2172
|
+
};
|
|
2173
|
+
var count = 0n;
|
|
2174
|
+
var validateStrictDeadlock = (outgoingMessages, wrappedMessage) => {
|
|
2175
|
+
if (wrappedMessage?.type !== REQUEST_TYPE || wrappedMessage.hasListeners) {
|
|
2176
|
+
return;
|
|
2177
|
+
}
|
|
2178
|
+
for (const { id } of outgoingMessages) {
|
|
2179
|
+
if (id !== void 0) {
|
|
2180
|
+
STRICT_RESPONSES[id].resolve({ isDeadlock: true, hasListeners: false });
|
|
2181
|
+
}
|
|
2182
|
+
}
|
|
2183
|
+
};
|
|
2184
|
+
var handleStrictRequest = async ({ wrappedMessage, anyProcess, channel, isSubprocess, ipcEmitter }) => {
|
|
2185
|
+
if (wrappedMessage?.type !== REQUEST_TYPE || !anyProcess.connected) {
|
|
2186
|
+
return wrappedMessage;
|
|
2187
|
+
}
|
|
2188
|
+
const { id, message } = wrappedMessage;
|
|
2189
|
+
const response = { id, type: RESPONSE_TYPE, message: hasMessageListeners(anyProcess, ipcEmitter) };
|
|
2190
|
+
try {
|
|
2191
|
+
await sendMessage({
|
|
2192
|
+
anyProcess,
|
|
2193
|
+
channel,
|
|
2194
|
+
isSubprocess,
|
|
2195
|
+
ipc: true
|
|
2196
|
+
}, response);
|
|
2197
|
+
} catch (error) {
|
|
2198
|
+
ipcEmitter.emit("strict:error", error);
|
|
2199
|
+
}
|
|
2200
|
+
return message;
|
|
2201
|
+
};
|
|
2202
|
+
var handleStrictResponse = (wrappedMessage) => {
|
|
2203
|
+
if (wrappedMessage?.type !== RESPONSE_TYPE) {
|
|
2204
|
+
return false;
|
|
2205
|
+
}
|
|
2206
|
+
const { id, message: hasListeners } = wrappedMessage;
|
|
2207
|
+
STRICT_RESPONSES[id]?.resolve({ isDeadlock: false, hasListeners });
|
|
2208
|
+
return true;
|
|
2209
|
+
};
|
|
2210
|
+
var waitForStrictResponse = async (wrappedMessage, anyProcess, isSubprocess) => {
|
|
2211
|
+
if (wrappedMessage?.type !== REQUEST_TYPE) {
|
|
2212
|
+
return;
|
|
2213
|
+
}
|
|
2214
|
+
const deferred = createDeferred();
|
|
2215
|
+
STRICT_RESPONSES[wrappedMessage.id] = deferred;
|
|
2216
|
+
const controller = new AbortController();
|
|
2217
|
+
try {
|
|
2218
|
+
const { isDeadlock, hasListeners } = await Promise.race([
|
|
2219
|
+
deferred,
|
|
2220
|
+
throwOnDisconnect(anyProcess, isSubprocess, controller)
|
|
2221
|
+
]);
|
|
2222
|
+
if (isDeadlock) {
|
|
2223
|
+
throwOnStrictDeadlockError(isSubprocess);
|
|
2224
|
+
}
|
|
2225
|
+
if (!hasListeners) {
|
|
2226
|
+
throwOnMissingStrict(isSubprocess);
|
|
2227
|
+
}
|
|
2228
|
+
} finally {
|
|
2229
|
+
controller.abort();
|
|
2230
|
+
delete STRICT_RESPONSES[wrappedMessage.id];
|
|
2231
|
+
}
|
|
2232
|
+
};
|
|
2233
|
+
var STRICT_RESPONSES = {};
|
|
2234
|
+
var throwOnDisconnect = async (anyProcess, isSubprocess, { signal }) => {
|
|
2235
|
+
incrementMaxListeners(anyProcess, 1, signal);
|
|
2236
|
+
await once3(anyProcess, "disconnect", { signal });
|
|
2237
|
+
throwOnStrictDisconnect(isSubprocess);
|
|
2238
|
+
};
|
|
2239
|
+
var REQUEST_TYPE = "execa:ipc:request";
|
|
2240
|
+
var RESPONSE_TYPE = "execa:ipc:response";
|
|
2241
|
+
|
|
2242
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/outgoing.js
|
|
2243
|
+
var startSendMessage = (anyProcess, wrappedMessage, strict) => {
|
|
2244
|
+
if (!OUTGOING_MESSAGES.has(anyProcess)) {
|
|
2245
|
+
OUTGOING_MESSAGES.set(anyProcess, /* @__PURE__ */ new Set());
|
|
2246
|
+
}
|
|
2247
|
+
const outgoingMessages = OUTGOING_MESSAGES.get(anyProcess);
|
|
2248
|
+
const onMessageSent = createDeferred();
|
|
2249
|
+
const id = strict ? wrappedMessage.id : void 0;
|
|
2250
|
+
const outgoingMessage = { onMessageSent, id };
|
|
2251
|
+
outgoingMessages.add(outgoingMessage);
|
|
2252
|
+
return { outgoingMessages, outgoingMessage };
|
|
2253
|
+
};
|
|
2254
|
+
var endSendMessage = ({ outgoingMessages, outgoingMessage }) => {
|
|
2255
|
+
outgoingMessages.delete(outgoingMessage);
|
|
2256
|
+
outgoingMessage.onMessageSent.resolve();
|
|
2257
|
+
};
|
|
2258
|
+
var waitForOutgoingMessages = async (anyProcess, ipcEmitter, wrappedMessage) => {
|
|
2259
|
+
while (!hasMessageListeners(anyProcess, ipcEmitter) && OUTGOING_MESSAGES.get(anyProcess)?.size > 0) {
|
|
2260
|
+
const outgoingMessages = [...OUTGOING_MESSAGES.get(anyProcess)];
|
|
2261
|
+
validateStrictDeadlock(outgoingMessages, wrappedMessage);
|
|
2262
|
+
await Promise.all(outgoingMessages.map(({ onMessageSent }) => onMessageSent));
|
|
2263
|
+
}
|
|
2264
|
+
};
|
|
2265
|
+
var OUTGOING_MESSAGES = /* @__PURE__ */ new WeakMap();
|
|
2266
|
+
var hasMessageListeners = (anyProcess, ipcEmitter) => ipcEmitter.listenerCount("message") > getMinListenerCount(anyProcess);
|
|
2267
|
+
var getMinListenerCount = (anyProcess) => SUBPROCESS_OPTIONS.has(anyProcess) && !SUBPROCESS_OPTIONS.get(anyProcess).options.buffer.at(-1) ? 1 : 0;
|
|
2268
|
+
|
|
2269
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/send.js
|
|
2270
|
+
var sendMessage = ({ anyProcess, channel, isSubprocess, ipc }, message, { strict = false } = {}) => {
|
|
2271
|
+
const methodName = "sendMessage";
|
|
2272
|
+
validateIpcMethod({
|
|
2273
|
+
methodName,
|
|
2274
|
+
isSubprocess,
|
|
2275
|
+
ipc,
|
|
2276
|
+
isConnected: anyProcess.connected
|
|
2277
|
+
});
|
|
2278
|
+
return sendMessageAsync({
|
|
2279
|
+
anyProcess,
|
|
2280
|
+
channel,
|
|
2281
|
+
methodName,
|
|
2282
|
+
isSubprocess,
|
|
2283
|
+
message,
|
|
2284
|
+
strict
|
|
2285
|
+
});
|
|
2286
|
+
};
|
|
2287
|
+
var sendMessageAsync = async ({ anyProcess, channel, methodName, isSubprocess, message, strict }) => {
|
|
2288
|
+
const wrappedMessage = handleSendStrict({
|
|
2289
|
+
anyProcess,
|
|
2290
|
+
channel,
|
|
2291
|
+
isSubprocess,
|
|
2292
|
+
message,
|
|
2293
|
+
strict
|
|
2294
|
+
});
|
|
2295
|
+
const outgoingMessagesState = startSendMessage(anyProcess, wrappedMessage, strict);
|
|
2296
|
+
try {
|
|
2297
|
+
await sendOneMessage({
|
|
2298
|
+
anyProcess,
|
|
2299
|
+
methodName,
|
|
2300
|
+
isSubprocess,
|
|
2301
|
+
wrappedMessage,
|
|
2302
|
+
message
|
|
2303
|
+
});
|
|
2304
|
+
} catch (error) {
|
|
2305
|
+
disconnect(anyProcess);
|
|
2306
|
+
throw error;
|
|
2307
|
+
} finally {
|
|
2308
|
+
endSendMessage(outgoingMessagesState);
|
|
2309
|
+
}
|
|
2310
|
+
};
|
|
2311
|
+
var sendOneMessage = async ({ anyProcess, methodName, isSubprocess, wrappedMessage, message }) => {
|
|
2312
|
+
const sendMethod = getSendMethod(anyProcess);
|
|
2313
|
+
try {
|
|
2314
|
+
await Promise.all([
|
|
2315
|
+
waitForStrictResponse(wrappedMessage, anyProcess, isSubprocess),
|
|
2316
|
+
sendMethod(wrappedMessage)
|
|
2317
|
+
]);
|
|
2318
|
+
} catch (error) {
|
|
2319
|
+
handleEpipeError({ error, methodName, isSubprocess });
|
|
2320
|
+
handleSerializationError({
|
|
2321
|
+
error,
|
|
2322
|
+
methodName,
|
|
2323
|
+
isSubprocess,
|
|
2324
|
+
message
|
|
2325
|
+
});
|
|
2326
|
+
throw error;
|
|
2327
|
+
}
|
|
2328
|
+
};
|
|
2329
|
+
var getSendMethod = (anyProcess) => {
|
|
2330
|
+
if (PROCESS_SEND_METHODS.has(anyProcess)) {
|
|
2331
|
+
return PROCESS_SEND_METHODS.get(anyProcess);
|
|
2332
|
+
}
|
|
2333
|
+
const sendMethod = promisify(anyProcess.send.bind(anyProcess));
|
|
2334
|
+
PROCESS_SEND_METHODS.set(anyProcess, sendMethod);
|
|
2335
|
+
return sendMethod;
|
|
2336
|
+
};
|
|
2337
|
+
var PROCESS_SEND_METHODS = /* @__PURE__ */ new WeakMap();
|
|
2338
|
+
|
|
2339
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/graceful.js
|
|
2340
|
+
var sendAbort = (subprocess, message) => {
|
|
2341
|
+
const methodName = "cancelSignal";
|
|
2342
|
+
validateConnection(methodName, false, subprocess.connected);
|
|
2343
|
+
return sendOneMessage({
|
|
2344
|
+
anyProcess: subprocess,
|
|
2345
|
+
methodName,
|
|
2346
|
+
isSubprocess: false,
|
|
2347
|
+
wrappedMessage: { type: GRACEFUL_CANCEL_TYPE, message },
|
|
2348
|
+
message
|
|
2349
|
+
});
|
|
2350
|
+
};
|
|
2351
|
+
var getCancelSignal = async ({ anyProcess, channel, isSubprocess, ipc }) => {
|
|
2352
|
+
await startIpc({
|
|
2353
|
+
anyProcess,
|
|
2354
|
+
channel,
|
|
2355
|
+
isSubprocess,
|
|
2356
|
+
ipc
|
|
2357
|
+
});
|
|
2358
|
+
return cancelController.signal;
|
|
2359
|
+
};
|
|
2360
|
+
var startIpc = async ({ anyProcess, channel, isSubprocess, ipc }) => {
|
|
2361
|
+
if (cancelListening) {
|
|
2362
|
+
return;
|
|
2363
|
+
}
|
|
2364
|
+
cancelListening = true;
|
|
2365
|
+
if (!ipc) {
|
|
2366
|
+
throwOnMissingParent();
|
|
2367
|
+
return;
|
|
2368
|
+
}
|
|
2369
|
+
if (channel === null) {
|
|
2370
|
+
abortOnDisconnect();
|
|
2371
|
+
return;
|
|
2372
|
+
}
|
|
2373
|
+
getIpcEmitter(anyProcess, channel, isSubprocess);
|
|
2374
|
+
await scheduler2.yield();
|
|
2375
|
+
};
|
|
2376
|
+
var cancelListening = false;
|
|
2377
|
+
var handleAbort = (wrappedMessage) => {
|
|
2378
|
+
if (wrappedMessage?.type !== GRACEFUL_CANCEL_TYPE) {
|
|
2379
|
+
return false;
|
|
2380
|
+
}
|
|
2381
|
+
cancelController.abort(wrappedMessage.message);
|
|
2382
|
+
return true;
|
|
2383
|
+
};
|
|
2384
|
+
var GRACEFUL_CANCEL_TYPE = "execa:ipc:cancel";
|
|
2385
|
+
var abortOnDisconnect = () => {
|
|
2386
|
+
cancelController.abort(getAbortDisconnectError());
|
|
2387
|
+
};
|
|
2388
|
+
var cancelController = new AbortController();
|
|
2389
|
+
|
|
2390
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/terminate/graceful.js
|
|
2391
|
+
var validateGracefulCancel = ({ gracefulCancel, cancelSignal, ipc, serialization }) => {
|
|
2392
|
+
if (!gracefulCancel) {
|
|
2393
|
+
return;
|
|
2394
|
+
}
|
|
2395
|
+
if (cancelSignal === void 0) {
|
|
2396
|
+
throw new Error("The `cancelSignal` option must be defined when setting the `gracefulCancel` option.");
|
|
2397
|
+
}
|
|
2398
|
+
if (!ipc) {
|
|
2399
|
+
throw new Error("The `ipc` option cannot be false when setting the `gracefulCancel` option.");
|
|
2400
|
+
}
|
|
2401
|
+
if (serialization === "json") {
|
|
2402
|
+
throw new Error("The `serialization` option cannot be 'json' when setting the `gracefulCancel` option.");
|
|
2403
|
+
}
|
|
2404
|
+
};
|
|
2405
|
+
var throwOnGracefulCancel = ({
|
|
2406
|
+
subprocess,
|
|
2407
|
+
cancelSignal,
|
|
2408
|
+
gracefulCancel,
|
|
2409
|
+
forceKillAfterDelay,
|
|
2410
|
+
context,
|
|
2411
|
+
controller
|
|
2412
|
+
}) => gracefulCancel ? [sendOnAbort({
|
|
2413
|
+
subprocess,
|
|
2414
|
+
cancelSignal,
|
|
2415
|
+
forceKillAfterDelay,
|
|
2416
|
+
context,
|
|
2417
|
+
controller
|
|
2418
|
+
})] : [];
|
|
2419
|
+
var sendOnAbort = async ({ subprocess, cancelSignal, forceKillAfterDelay, context, controller: { signal } }) => {
|
|
2420
|
+
await onAbortedSignal(cancelSignal, signal);
|
|
2421
|
+
const reason = getReason(cancelSignal);
|
|
2422
|
+
await sendAbort(subprocess, reason);
|
|
2423
|
+
killOnTimeout({
|
|
2424
|
+
kill: subprocess.kill,
|
|
2425
|
+
forceKillAfterDelay,
|
|
2426
|
+
context,
|
|
2427
|
+
controllerSignal: signal
|
|
2428
|
+
});
|
|
2429
|
+
context.terminationReason ??= "gracefulCancel";
|
|
2430
|
+
throw cancelSignal.reason;
|
|
2431
|
+
};
|
|
2432
|
+
var getReason = ({ reason }) => {
|
|
2433
|
+
if (!(reason instanceof DOMException)) {
|
|
2434
|
+
return reason;
|
|
2435
|
+
}
|
|
2436
|
+
const error = new Error(reason.message);
|
|
2437
|
+
Object.defineProperty(error, "stack", {
|
|
2438
|
+
value: reason.stack,
|
|
2439
|
+
enumerable: false,
|
|
2440
|
+
configurable: true,
|
|
2441
|
+
writable: true
|
|
2442
|
+
});
|
|
2443
|
+
return error;
|
|
2444
|
+
};
|
|
2445
|
+
|
|
2446
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/terminate/timeout.js
|
|
2447
|
+
import { setTimeout as setTimeout2 } from "node:timers/promises";
|
|
2448
|
+
var validateTimeout = ({ timeout }) => {
|
|
2449
|
+
if (timeout !== void 0 && (!Number.isFinite(timeout) || timeout < 0)) {
|
|
2450
|
+
throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${timeout}\` (${typeof timeout})`);
|
|
2451
|
+
}
|
|
2452
|
+
};
|
|
2453
|
+
var throwOnTimeout = (subprocess, timeout, context, controller) => timeout === 0 || timeout === void 0 ? [] : [killAfterTimeout(subprocess, timeout, context, controller)];
|
|
2454
|
+
var killAfterTimeout = async (subprocess, timeout, context, { signal }) => {
|
|
2455
|
+
await setTimeout2(timeout, void 0, { signal });
|
|
2456
|
+
context.terminationReason ??= "timeout";
|
|
2457
|
+
subprocess.kill();
|
|
2458
|
+
throw new DiscardedError();
|
|
2459
|
+
};
|
|
2460
|
+
|
|
2461
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/node.js
|
|
2462
|
+
import { execPath, execArgv } from "node:process";
|
|
2463
|
+
import { basename, resolve } from "node:path";
|
|
2464
|
+
var mapNode = ({ options }) => {
|
|
2465
|
+
if (options.node === false) {
|
|
2466
|
+
throw new TypeError('The "node" option cannot be false with `execaNode()`.');
|
|
2467
|
+
}
|
|
2468
|
+
return { options: { ...options, node: true } };
|
|
2469
|
+
};
|
|
2470
|
+
var handleNodeOption = (file, commandArguments, {
|
|
2471
|
+
node: shouldHandleNode = false,
|
|
2472
|
+
nodePath = execPath,
|
|
2473
|
+
nodeOptions = execArgv.filter((nodeOption) => !nodeOption.startsWith("--inspect")),
|
|
2474
|
+
cwd,
|
|
2475
|
+
execPath: formerNodePath,
|
|
2476
|
+
...options
|
|
2477
|
+
}) => {
|
|
2478
|
+
if (formerNodePath !== void 0) {
|
|
2479
|
+
throw new TypeError('The "execPath" option has been removed. Please use the "nodePath" option instead.');
|
|
2480
|
+
}
|
|
2481
|
+
const normalizedNodePath = safeNormalizeFileUrl(nodePath, 'The "nodePath" option');
|
|
2482
|
+
const resolvedNodePath = resolve(cwd, normalizedNodePath);
|
|
2483
|
+
const newOptions = {
|
|
2484
|
+
...options,
|
|
2485
|
+
nodePath: resolvedNodePath,
|
|
2486
|
+
node: shouldHandleNode,
|
|
2487
|
+
cwd
|
|
2488
|
+
};
|
|
2489
|
+
if (!shouldHandleNode) {
|
|
2490
|
+
return [file, commandArguments, newOptions];
|
|
2491
|
+
}
|
|
2492
|
+
if (basename(file, ".exe") === "node") {
|
|
2493
|
+
throw new TypeError('When the "node" option is true, the first argument does not need to be "node".');
|
|
2494
|
+
}
|
|
2495
|
+
return [
|
|
2496
|
+
resolvedNodePath,
|
|
2497
|
+
[...nodeOptions, file, ...commandArguments],
|
|
2498
|
+
{ ipc: true, ...newOptions, shell: false }
|
|
2499
|
+
];
|
|
2500
|
+
};
|
|
2501
|
+
|
|
2502
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/ipc-input.js
|
|
2503
|
+
import { serialize } from "node:v8";
|
|
2504
|
+
var validateIpcInputOption = ({ ipcInput, ipc, serialization }) => {
|
|
2505
|
+
if (ipcInput === void 0) {
|
|
2506
|
+
return;
|
|
2507
|
+
}
|
|
2508
|
+
if (!ipc) {
|
|
2509
|
+
throw new Error("The `ipcInput` option cannot be set unless the `ipc` option is `true`.");
|
|
2510
|
+
}
|
|
2511
|
+
validateIpcInput[serialization](ipcInput);
|
|
2512
|
+
};
|
|
2513
|
+
var validateAdvancedInput = (ipcInput) => {
|
|
2514
|
+
try {
|
|
2515
|
+
serialize(ipcInput);
|
|
2516
|
+
} catch (error) {
|
|
2517
|
+
throw new Error("The `ipcInput` option is not serializable with a structured clone.", { cause: error });
|
|
2518
|
+
}
|
|
2519
|
+
};
|
|
2520
|
+
var validateJsonInput = (ipcInput) => {
|
|
2521
|
+
try {
|
|
2522
|
+
JSON.stringify(ipcInput);
|
|
2523
|
+
} catch (error) {
|
|
2524
|
+
throw new Error("The `ipcInput` option is not serializable with JSON.", { cause: error });
|
|
2525
|
+
}
|
|
2526
|
+
};
|
|
2527
|
+
var validateIpcInput = {
|
|
2528
|
+
advanced: validateAdvancedInput,
|
|
2529
|
+
json: validateJsonInput
|
|
2530
|
+
};
|
|
2531
|
+
var sendIpcInput = async (subprocess, ipcInput) => {
|
|
2532
|
+
if (ipcInput === void 0) {
|
|
2533
|
+
return;
|
|
2534
|
+
}
|
|
2535
|
+
await subprocess.sendMessage(ipcInput);
|
|
2536
|
+
};
|
|
2537
|
+
|
|
2538
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/arguments/encoding-option.js
|
|
2539
|
+
var validateEncoding = ({ encoding }) => {
|
|
2540
|
+
if (ENCODINGS.has(encoding)) {
|
|
2541
|
+
return;
|
|
2542
|
+
}
|
|
2543
|
+
const correctEncoding = getCorrectEncoding(encoding);
|
|
2544
|
+
if (correctEncoding !== void 0) {
|
|
2545
|
+
throw new TypeError(`Invalid option \`encoding: ${serializeEncoding(encoding)}\`.
|
|
2546
|
+
Please rename it to ${serializeEncoding(correctEncoding)}.`);
|
|
2547
|
+
}
|
|
2548
|
+
const correctEncodings = [...ENCODINGS].map((correctEncoding2) => serializeEncoding(correctEncoding2)).join(", ");
|
|
2549
|
+
throw new TypeError(`Invalid option \`encoding: ${serializeEncoding(encoding)}\`.
|
|
2550
|
+
Please rename it to one of: ${correctEncodings}.`);
|
|
2551
|
+
};
|
|
2552
|
+
var TEXT_ENCODINGS = /* @__PURE__ */ new Set(["utf8", "utf16le"]);
|
|
2553
|
+
var BINARY_ENCODINGS = /* @__PURE__ */ new Set(["buffer", "hex", "base64", "base64url", "latin1", "ascii"]);
|
|
2554
|
+
var ENCODINGS = /* @__PURE__ */ new Set([...TEXT_ENCODINGS, ...BINARY_ENCODINGS]);
|
|
2555
|
+
var getCorrectEncoding = (encoding) => {
|
|
2556
|
+
if (encoding === null) {
|
|
2557
|
+
return "buffer";
|
|
2558
|
+
}
|
|
2559
|
+
if (typeof encoding !== "string") {
|
|
2560
|
+
return;
|
|
2561
|
+
}
|
|
2562
|
+
const lowerEncoding = encoding.toLowerCase();
|
|
2563
|
+
if (lowerEncoding in ENCODING_ALIASES) {
|
|
2564
|
+
return ENCODING_ALIASES[lowerEncoding];
|
|
2565
|
+
}
|
|
2566
|
+
if (ENCODINGS.has(lowerEncoding)) {
|
|
2567
|
+
return lowerEncoding;
|
|
2568
|
+
}
|
|
2569
|
+
};
|
|
2570
|
+
var ENCODING_ALIASES = {
|
|
2571
|
+
// eslint-disable-next-line unicorn/text-encoding-identifier-case
|
|
2572
|
+
"utf-8": "utf8",
|
|
2573
|
+
"utf-16le": "utf16le",
|
|
2574
|
+
"ucs-2": "utf16le",
|
|
2575
|
+
ucs2: "utf16le",
|
|
2576
|
+
binary: "latin1"
|
|
2577
|
+
};
|
|
2578
|
+
var serializeEncoding = (encoding) => typeof encoding === "string" ? `"${encoding}"` : String(encoding);
|
|
2579
|
+
|
|
2580
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/arguments/cwd.js
|
|
2581
|
+
import { statSync } from "node:fs";
|
|
2582
|
+
import { resolve as resolve2 } from "node:path";
|
|
2583
|
+
import process5 from "node:process";
|
|
2584
|
+
var normalizeCwd = (cwd = getDefaultCwd()) => {
|
|
2585
|
+
const cwdString = safeNormalizeFileUrl(cwd, 'The "cwd" option');
|
|
2586
|
+
return resolve2(cwdString);
|
|
2587
|
+
};
|
|
2588
|
+
var getDefaultCwd = () => {
|
|
2589
|
+
try {
|
|
2590
|
+
return process5.cwd();
|
|
2591
|
+
} catch (error) {
|
|
2592
|
+
error.message = `The current directory does not exist.
|
|
2593
|
+
${error.message}`;
|
|
2594
|
+
throw error;
|
|
2595
|
+
}
|
|
2596
|
+
};
|
|
2597
|
+
var fixCwdError = (originalMessage, cwd) => {
|
|
2598
|
+
if (cwd === getDefaultCwd()) {
|
|
2599
|
+
return originalMessage;
|
|
2600
|
+
}
|
|
2601
|
+
let cwdStat;
|
|
2602
|
+
try {
|
|
2603
|
+
cwdStat = statSync(cwd);
|
|
2604
|
+
} catch (error) {
|
|
2605
|
+
return `The "cwd" option is invalid: ${cwd}.
|
|
2606
|
+
${error.message}
|
|
2607
|
+
${originalMessage}`;
|
|
2608
|
+
}
|
|
2609
|
+
if (!cwdStat.isDirectory()) {
|
|
2610
|
+
return `The "cwd" option is not a directory: ${cwd}.
|
|
2611
|
+
${originalMessage}`;
|
|
2612
|
+
}
|
|
2613
|
+
return originalMessage;
|
|
2614
|
+
};
|
|
2615
|
+
|
|
2616
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/arguments/options.js
|
|
2617
|
+
var normalizeOptions = (filePath, rawArguments, rawOptions) => {
|
|
2618
|
+
rawOptions.cwd = normalizeCwd(rawOptions.cwd);
|
|
2619
|
+
const [processedFile, processedArguments, processedOptions] = handleNodeOption(filePath, rawArguments, rawOptions);
|
|
2620
|
+
const { command: file, args: commandArguments, options: initialOptions } = import_cross_spawn.default._parse(processedFile, processedArguments, processedOptions);
|
|
2621
|
+
const fdOptions = normalizeFdSpecificOptions(initialOptions);
|
|
2622
|
+
const options = addDefaultOptions(fdOptions);
|
|
2623
|
+
validateTimeout(options);
|
|
2624
|
+
validateEncoding(options);
|
|
2625
|
+
validateIpcInputOption(options);
|
|
2626
|
+
validateCancelSignal(options);
|
|
2627
|
+
validateGracefulCancel(options);
|
|
2628
|
+
options.shell = normalizeFileUrl(options.shell);
|
|
2629
|
+
options.env = getEnv(options);
|
|
2630
|
+
options.killSignal = normalizeKillSignal(options.killSignal);
|
|
2631
|
+
options.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);
|
|
2632
|
+
options.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);
|
|
2633
|
+
if (process6.platform === "win32" && basename2(file, ".exe") === "cmd") {
|
|
2634
|
+
commandArguments.unshift("/q");
|
|
2635
|
+
}
|
|
2636
|
+
return { file, commandArguments, options };
|
|
2637
|
+
};
|
|
2638
|
+
var addDefaultOptions = ({
|
|
2639
|
+
extendEnv = true,
|
|
2640
|
+
preferLocal = false,
|
|
2641
|
+
cwd,
|
|
2642
|
+
localDir: localDirectory = cwd,
|
|
2643
|
+
encoding = "utf8",
|
|
2644
|
+
reject = true,
|
|
2645
|
+
cleanup = true,
|
|
2646
|
+
all = false,
|
|
2647
|
+
windowsHide = true,
|
|
2648
|
+
killSignal = "SIGTERM",
|
|
2649
|
+
forceKillAfterDelay = true,
|
|
2650
|
+
gracefulCancel = false,
|
|
2651
|
+
ipcInput,
|
|
2652
|
+
ipc = ipcInput !== void 0 || gracefulCancel,
|
|
2653
|
+
serialization = "advanced",
|
|
2654
|
+
...options
|
|
2655
|
+
}) => ({
|
|
2656
|
+
...options,
|
|
2657
|
+
extendEnv,
|
|
2658
|
+
preferLocal,
|
|
2659
|
+
cwd,
|
|
2660
|
+
localDirectory,
|
|
2661
|
+
encoding,
|
|
2662
|
+
reject,
|
|
2663
|
+
cleanup,
|
|
2664
|
+
all,
|
|
2665
|
+
windowsHide,
|
|
2666
|
+
killSignal,
|
|
2667
|
+
forceKillAfterDelay,
|
|
2668
|
+
gracefulCancel,
|
|
2669
|
+
ipcInput,
|
|
2670
|
+
ipc,
|
|
2671
|
+
serialization
|
|
2672
|
+
});
|
|
2673
|
+
var getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath }) => {
|
|
2674
|
+
const env = extendEnv ? { ...process6.env, ...envOption } : envOption;
|
|
2675
|
+
if (preferLocal || node) {
|
|
2676
|
+
return npmRunPathEnv({
|
|
2677
|
+
env,
|
|
2678
|
+
cwd: localDirectory,
|
|
2679
|
+
execPath: nodePath,
|
|
2680
|
+
preferLocal,
|
|
2681
|
+
addExecPath: node
|
|
2682
|
+
});
|
|
2683
|
+
}
|
|
2684
|
+
return env;
|
|
2006
2685
|
};
|
|
2007
|
-
|
|
2686
|
+
|
|
2687
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/return/message.js
|
|
2688
|
+
import { inspect as inspect2 } from "node:util";
|
|
2008
2689
|
|
|
2009
2690
|
// ../../node_modules/.pnpm/strip-final-newline@4.0.0/node_modules/strip-final-newline/index.js
|
|
2010
2691
|
function stripFinalNewline(input) {
|
|
@@ -2393,7 +3074,7 @@ var stringMethods = {
|
|
|
2393
3074
|
// ../../node_modules/.pnpm/get-stream@9.0.1/node_modules/get-stream/source/index.js
|
|
2394
3075
|
Object.assign(nodeImports, { on, finished });
|
|
2395
3076
|
|
|
2396
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3077
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/max-buffer.js
|
|
2397
3078
|
var handleMaxBuffer = ({ error, stream, readableObjectMode, lines, encoding, fdNumber }) => {
|
|
2398
3079
|
if (!(error instanceof MaxBufferError)) {
|
|
2399
3080
|
throw error;
|
|
@@ -2418,6 +3099,14 @@ var getMaxBufferUnit = (readableObjectMode, lines, encoding) => {
|
|
|
2418
3099
|
}
|
|
2419
3100
|
return "characters";
|
|
2420
3101
|
};
|
|
3102
|
+
var checkIpcMaxBuffer = (subprocess, ipcOutput, maxBuffer) => {
|
|
3103
|
+
if (ipcOutput.length !== maxBuffer) {
|
|
3104
|
+
return;
|
|
3105
|
+
}
|
|
3106
|
+
const error = new MaxBufferError();
|
|
3107
|
+
error.maxBufferInfo = { fdNumber: "ipc" };
|
|
3108
|
+
throw error;
|
|
3109
|
+
};
|
|
2421
3110
|
var getMaxBufferMessage = (error, maxBuffer) => {
|
|
2422
3111
|
const { streamName, threshold, unit } = getMaxBufferInfo(error, maxBuffer);
|
|
2423
3112
|
return `Command's ${streamName} was larger than ${threshold} ${unit}`;
|
|
@@ -2428,6 +3117,9 @@ var getMaxBufferInfo = (error, maxBuffer) => {
|
|
|
2428
3117
|
}
|
|
2429
3118
|
const { maxBufferInfo: { fdNumber, unit } } = error;
|
|
2430
3119
|
delete error.maxBufferInfo;
|
|
3120
|
+
if (fdNumber === "ipc") {
|
|
3121
|
+
return { streamName: "IPC output", threshold: maxBuffer.at(-1), unit: "messages" };
|
|
3122
|
+
}
|
|
2431
3123
|
return { streamName: getStreamName(fdNumber), threshold: maxBuffer[fdNumber], unit };
|
|
2432
3124
|
};
|
|
2433
3125
|
var isMaxBufferSync = (resultError, output, maxBuffer) => resultError?.code === "ENOBUFS" && output !== null && output.some((result) => result !== null && result.length > getMaxBufferSync(maxBuffer));
|
|
@@ -2440,10 +3132,11 @@ var truncateMaxBufferSync = (result, isMaxBuffer, maxBuffer) => {
|
|
|
2440
3132
|
};
|
|
2441
3133
|
var getMaxBufferSync = ([, stdoutMaxBuffer]) => stdoutMaxBuffer;
|
|
2442
3134
|
|
|
2443
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3135
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/return/message.js
|
|
2444
3136
|
var createMessages = ({
|
|
2445
3137
|
stdio,
|
|
2446
3138
|
all,
|
|
3139
|
+
ipcOutput,
|
|
2447
3140
|
originalError,
|
|
2448
3141
|
signal,
|
|
2449
3142
|
signalDescription,
|
|
@@ -2451,7 +3144,11 @@ var createMessages = ({
|
|
|
2451
3144
|
escapedCommand,
|
|
2452
3145
|
timedOut,
|
|
2453
3146
|
isCanceled,
|
|
3147
|
+
isGracefullyCanceled,
|
|
2454
3148
|
isMaxBuffer,
|
|
3149
|
+
isForcefullyTerminated,
|
|
3150
|
+
forceKillAfterDelay,
|
|
3151
|
+
killSignal,
|
|
2455
3152
|
maxBuffer,
|
|
2456
3153
|
timeout,
|
|
2457
3154
|
cwd
|
|
@@ -2467,28 +3164,62 @@ var createMessages = ({
|
|
|
2467
3164
|
signal,
|
|
2468
3165
|
signalDescription,
|
|
2469
3166
|
exitCode,
|
|
2470
|
-
isCanceled
|
|
3167
|
+
isCanceled,
|
|
3168
|
+
isGracefullyCanceled,
|
|
3169
|
+
isForcefullyTerminated,
|
|
3170
|
+
forceKillAfterDelay,
|
|
3171
|
+
killSignal
|
|
2471
3172
|
});
|
|
2472
3173
|
const originalMessage = getOriginalMessage(originalError, cwd);
|
|
2473
3174
|
const suffix = originalMessage === void 0 ? "" : `
|
|
2474
3175
|
${originalMessage}`;
|
|
2475
3176
|
const shortMessage = `${prefix}: ${escapedCommand}${suffix}`;
|
|
2476
3177
|
const messageStdio = all === void 0 ? [stdio[2], stdio[1]] : [all];
|
|
2477
|
-
const message = [
|
|
3178
|
+
const message = [
|
|
3179
|
+
shortMessage,
|
|
3180
|
+
...messageStdio,
|
|
3181
|
+
...stdio.slice(3),
|
|
3182
|
+
ipcOutput.map((ipcMessage) => serializeIpcMessage(ipcMessage)).join("\n")
|
|
3183
|
+
].map((messagePart) => escapeLines(stripFinalNewline(serializeMessagePart(messagePart)))).filter(Boolean).join("\n\n");
|
|
2478
3184
|
return { originalMessage, shortMessage, message };
|
|
2479
3185
|
};
|
|
2480
|
-
var getErrorPrefix = ({
|
|
3186
|
+
var getErrorPrefix = ({
|
|
3187
|
+
originalError,
|
|
3188
|
+
timedOut,
|
|
3189
|
+
timeout,
|
|
3190
|
+
isMaxBuffer,
|
|
3191
|
+
maxBuffer,
|
|
3192
|
+
errorCode,
|
|
3193
|
+
signal,
|
|
3194
|
+
signalDescription,
|
|
3195
|
+
exitCode,
|
|
3196
|
+
isCanceled,
|
|
3197
|
+
isGracefullyCanceled,
|
|
3198
|
+
isForcefullyTerminated,
|
|
3199
|
+
forceKillAfterDelay,
|
|
3200
|
+
killSignal
|
|
3201
|
+
}) => {
|
|
3202
|
+
const forcefulSuffix = getForcefulSuffix(isForcefullyTerminated, forceKillAfterDelay);
|
|
2481
3203
|
if (timedOut) {
|
|
2482
|
-
return `Command timed out after ${timeout} milliseconds`;
|
|
3204
|
+
return `Command timed out after ${timeout} milliseconds${forcefulSuffix}`;
|
|
3205
|
+
}
|
|
3206
|
+
if (isGracefullyCanceled) {
|
|
3207
|
+
if (signal === void 0) {
|
|
3208
|
+
return `Command was gracefully canceled with exit code ${exitCode}`;
|
|
3209
|
+
}
|
|
3210
|
+
return isForcefullyTerminated ? `Command was gracefully canceled${forcefulSuffix}` : `Command was gracefully canceled with ${signal} (${signalDescription})`;
|
|
2483
3211
|
}
|
|
2484
3212
|
if (isCanceled) {
|
|
2485
|
-
return
|
|
3213
|
+
return `Command was canceled${forcefulSuffix}`;
|
|
2486
3214
|
}
|
|
2487
3215
|
if (isMaxBuffer) {
|
|
2488
|
-
return getMaxBufferMessage(originalError, maxBuffer)
|
|
3216
|
+
return `${getMaxBufferMessage(originalError, maxBuffer)}${forcefulSuffix}`;
|
|
2489
3217
|
}
|
|
2490
3218
|
if (errorCode !== void 0) {
|
|
2491
|
-
return `Command failed with ${errorCode}`;
|
|
3219
|
+
return `Command failed with ${errorCode}${forcefulSuffix}`;
|
|
3220
|
+
}
|
|
3221
|
+
if (isForcefullyTerminated) {
|
|
3222
|
+
return `Command was killed with ${killSignal} (${getSignalDescription(killSignal)})${forcefulSuffix}`;
|
|
2492
3223
|
}
|
|
2493
3224
|
if (signal !== void 0) {
|
|
2494
3225
|
return `Command was killed with ${signal} (${signalDescription})`;
|
|
@@ -2498,6 +3229,7 @@ var getErrorPrefix = ({ originalError, timedOut, timeout, isMaxBuffer, maxBuffer
|
|
|
2498
3229
|
}
|
|
2499
3230
|
return "Command failed";
|
|
2500
3231
|
};
|
|
3232
|
+
var getForcefulSuffix = (isForcefullyTerminated, forceKillAfterDelay) => isForcefullyTerminated ? ` and was forcefully terminated after ${forceKillAfterDelay} milliseconds` : "";
|
|
2501
3233
|
var getOriginalMessage = (originalError, cwd) => {
|
|
2502
3234
|
if (originalError instanceof DiscardedError) {
|
|
2503
3235
|
return;
|
|
@@ -2506,6 +3238,7 @@ var getOriginalMessage = (originalError, cwd) => {
|
|
|
2506
3238
|
const escapedOriginalMessage = escapeLines(fixCwdError(originalMessage, cwd));
|
|
2507
3239
|
return escapedOriginalMessage === "" ? void 0 : escapedOriginalMessage;
|
|
2508
3240
|
};
|
|
3241
|
+
var serializeIpcMessage = (ipcMessage) => typeof ipcMessage === "string" ? ipcMessage : inspect2(ipcMessage);
|
|
2509
3242
|
var serializeMessagePart = (messagePart) => Array.isArray(messagePart) ? messagePart.map((messageItem) => stripFinalNewline(serializeMessageItem(messageItem))).filter(Boolean).join("\n") : serializeMessageItem(messagePart);
|
|
2510
3243
|
var serializeMessageItem = (messageItem) => {
|
|
2511
3244
|
if (typeof messageItem === "string") {
|
|
@@ -2517,12 +3250,13 @@ var serializeMessageItem = (messageItem) => {
|
|
|
2517
3250
|
return "";
|
|
2518
3251
|
};
|
|
2519
3252
|
|
|
2520
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3253
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/return/result.js
|
|
2521
3254
|
var makeSuccessResult = ({
|
|
2522
3255
|
command,
|
|
2523
3256
|
escapedCommand,
|
|
2524
3257
|
stdio,
|
|
2525
3258
|
all,
|
|
3259
|
+
ipcOutput,
|
|
2526
3260
|
options: { cwd },
|
|
2527
3261
|
startTime
|
|
2528
3262
|
}) => omitUndefinedProperties({
|
|
@@ -2533,13 +3267,16 @@ var makeSuccessResult = ({
|
|
|
2533
3267
|
failed: false,
|
|
2534
3268
|
timedOut: false,
|
|
2535
3269
|
isCanceled: false,
|
|
3270
|
+
isGracefullyCanceled: false,
|
|
2536
3271
|
isTerminated: false,
|
|
2537
3272
|
isMaxBuffer: false,
|
|
3273
|
+
isForcefullyTerminated: false,
|
|
2538
3274
|
exitCode: 0,
|
|
2539
3275
|
stdout: stdio[1],
|
|
2540
3276
|
stderr: stdio[2],
|
|
2541
3277
|
all,
|
|
2542
3278
|
stdio,
|
|
3279
|
+
ipcOutput,
|
|
2543
3280
|
pipedFrom: []
|
|
2544
3281
|
});
|
|
2545
3282
|
var makeEarlyError = ({
|
|
@@ -2557,8 +3294,11 @@ var makeEarlyError = ({
|
|
|
2557
3294
|
startTime,
|
|
2558
3295
|
timedOut: false,
|
|
2559
3296
|
isCanceled: false,
|
|
3297
|
+
isGracefullyCanceled: false,
|
|
2560
3298
|
isMaxBuffer: false,
|
|
3299
|
+
isForcefullyTerminated: false,
|
|
2561
3300
|
stdio: Array.from({ length: fileDescriptors.length }),
|
|
3301
|
+
ipcOutput: [],
|
|
2562
3302
|
options,
|
|
2563
3303
|
isSync
|
|
2564
3304
|
});
|
|
@@ -2569,18 +3309,29 @@ var makeError = ({
|
|
|
2569
3309
|
startTime,
|
|
2570
3310
|
timedOut,
|
|
2571
3311
|
isCanceled,
|
|
3312
|
+
isGracefullyCanceled,
|
|
2572
3313
|
isMaxBuffer,
|
|
3314
|
+
isForcefullyTerminated,
|
|
2573
3315
|
exitCode: rawExitCode,
|
|
2574
3316
|
signal: rawSignal,
|
|
2575
3317
|
stdio,
|
|
2576
3318
|
all,
|
|
2577
|
-
|
|
3319
|
+
ipcOutput,
|
|
3320
|
+
options: {
|
|
3321
|
+
timeoutDuration,
|
|
3322
|
+
timeout = timeoutDuration,
|
|
3323
|
+
forceKillAfterDelay,
|
|
3324
|
+
killSignal,
|
|
3325
|
+
cwd,
|
|
3326
|
+
maxBuffer
|
|
3327
|
+
},
|
|
2578
3328
|
isSync
|
|
2579
3329
|
}) => {
|
|
2580
3330
|
const { exitCode, signal, signalDescription } = normalizeExitPayload(rawExitCode, rawSignal);
|
|
2581
3331
|
const { originalMessage, shortMessage, message } = createMessages({
|
|
2582
3332
|
stdio,
|
|
2583
3333
|
all,
|
|
3334
|
+
ipcOutput,
|
|
2584
3335
|
originalError,
|
|
2585
3336
|
signal,
|
|
2586
3337
|
signalDescription,
|
|
@@ -2588,7 +3339,11 @@ var makeError = ({
|
|
|
2588
3339
|
escapedCommand,
|
|
2589
3340
|
timedOut,
|
|
2590
3341
|
isCanceled,
|
|
3342
|
+
isGracefullyCanceled,
|
|
2591
3343
|
isMaxBuffer,
|
|
3344
|
+
isForcefullyTerminated,
|
|
3345
|
+
forceKillAfterDelay,
|
|
3346
|
+
killSignal,
|
|
2592
3347
|
maxBuffer,
|
|
2593
3348
|
timeout,
|
|
2594
3349
|
cwd
|
|
@@ -2601,12 +3356,15 @@ var makeError = ({
|
|
|
2601
3356
|
startTime,
|
|
2602
3357
|
timedOut,
|
|
2603
3358
|
isCanceled,
|
|
3359
|
+
isGracefullyCanceled,
|
|
2604
3360
|
isMaxBuffer,
|
|
3361
|
+
isForcefullyTerminated,
|
|
2605
3362
|
exitCode,
|
|
2606
3363
|
signal,
|
|
2607
3364
|
signalDescription,
|
|
2608
3365
|
stdio,
|
|
2609
3366
|
all,
|
|
3367
|
+
ipcOutput,
|
|
2610
3368
|
cwd,
|
|
2611
3369
|
originalMessage,
|
|
2612
3370
|
shortMessage
|
|
@@ -2620,12 +3378,15 @@ var getErrorProperties = ({
|
|
|
2620
3378
|
startTime,
|
|
2621
3379
|
timedOut,
|
|
2622
3380
|
isCanceled,
|
|
3381
|
+
isGracefullyCanceled,
|
|
2623
3382
|
isMaxBuffer,
|
|
3383
|
+
isForcefullyTerminated,
|
|
2624
3384
|
exitCode,
|
|
2625
3385
|
signal,
|
|
2626
3386
|
signalDescription,
|
|
2627
3387
|
stdio,
|
|
2628
3388
|
all,
|
|
3389
|
+
ipcOutput,
|
|
2629
3390
|
cwd,
|
|
2630
3391
|
originalMessage,
|
|
2631
3392
|
shortMessage
|
|
@@ -2639,8 +3400,10 @@ var getErrorProperties = ({
|
|
|
2639
3400
|
failed: true,
|
|
2640
3401
|
timedOut,
|
|
2641
3402
|
isCanceled,
|
|
3403
|
+
isGracefullyCanceled,
|
|
2642
3404
|
isTerminated: signal !== void 0,
|
|
2643
3405
|
isMaxBuffer,
|
|
3406
|
+
isForcefullyTerminated,
|
|
2644
3407
|
exitCode,
|
|
2645
3408
|
signal,
|
|
2646
3409
|
signalDescription,
|
|
@@ -2649,13 +3412,14 @@ var getErrorProperties = ({
|
|
|
2649
3412
|
stderr: stdio[2],
|
|
2650
3413
|
all,
|
|
2651
3414
|
stdio,
|
|
3415
|
+
ipcOutput,
|
|
2652
3416
|
pipedFrom: []
|
|
2653
3417
|
});
|
|
2654
3418
|
var omitUndefinedProperties = (result) => Object.fromEntries(Object.entries(result).filter(([, value]) => value !== void 0));
|
|
2655
3419
|
var normalizeExitPayload = (rawExitCode, rawSignal) => {
|
|
2656
3420
|
const exitCode = rawExitCode === null ? void 0 : rawExitCode;
|
|
2657
3421
|
const signal = rawSignal === null ? void 0 : rawSignal;
|
|
2658
|
-
const signalDescription = signal === void 0 ? void 0 :
|
|
3422
|
+
const signalDescription = signal === void 0 ? void 0 : getSignalDescription(rawSignal);
|
|
2659
3423
|
return { exitCode, signal, signalDescription };
|
|
2660
3424
|
};
|
|
2661
3425
|
|
|
@@ -2700,7 +3464,7 @@ function parseMilliseconds(milliseconds) {
|
|
|
2700
3464
|
|
|
2701
3465
|
// ../../node_modules/.pnpm/pretty-ms@9.0.0/node_modules/pretty-ms/index.js
|
|
2702
3466
|
var isZero = (value) => value === 0 || value === 0n;
|
|
2703
|
-
var pluralize = (word,
|
|
3467
|
+
var pluralize = (word, count2) => count2 === 1 || count2 === 1n ? word : `${word}s`;
|
|
2704
3468
|
var SECOND_ROUNDING_EPSILON = 1e-7;
|
|
2705
3469
|
var ONE_DAY_IN_MILLISECONDS = 24n * 60n * 60n * 1000n;
|
|
2706
3470
|
function prettyMilliseconds(milliseconds, options) {
|
|
@@ -2785,7 +3549,7 @@ function prettyMilliseconds(milliseconds, options) {
|
|
|
2785
3549
|
return result.join(separator);
|
|
2786
3550
|
}
|
|
2787
3551
|
|
|
2788
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3552
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/verbose/error.js
|
|
2789
3553
|
var logError = ({ message, failed, reject, verboseId, icon }) => {
|
|
2790
3554
|
if (!failed) {
|
|
2791
3555
|
return;
|
|
@@ -2794,7 +3558,7 @@ var logError = ({ message, failed, reject, verboseId, icon }) => {
|
|
|
2794
3558
|
verboseLog(message, verboseId, icon, color);
|
|
2795
3559
|
};
|
|
2796
3560
|
|
|
2797
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3561
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/verbose/complete.js
|
|
2798
3562
|
var logFinalResult = ({ shortMessage, failed, durationMs }, reject, verboseInfo) => {
|
|
2799
3563
|
logResult({
|
|
2800
3564
|
message: shortMessage,
|
|
@@ -2838,7 +3602,7 @@ var getIcon = (failed, reject) => {
|
|
|
2838
3602
|
return reject ? "error" : "warning";
|
|
2839
3603
|
};
|
|
2840
3604
|
|
|
2841
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3605
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/return/reject.js
|
|
2842
3606
|
var handleResult = (result, verboseInfo, { reject }) => {
|
|
2843
3607
|
logFinalResult(result, reject, verboseInfo);
|
|
2844
3608
|
if (result.failed && reject) {
|
|
@@ -2847,10 +3611,10 @@ var handleResult = (result, verboseInfo, { reject }) => {
|
|
|
2847
3611
|
return result;
|
|
2848
3612
|
};
|
|
2849
3613
|
|
|
2850
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3614
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/handle-sync.js
|
|
2851
3615
|
import { readFileSync as readFileSync2 } from "node:fs";
|
|
2852
3616
|
|
|
2853
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3617
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/type.js
|
|
2854
3618
|
var getStdioItemType = (value, optionName) => {
|
|
2855
3619
|
if (isAsyncGenerator(value)) {
|
|
2856
3620
|
return "asyncGenerator";
|
|
@@ -2975,7 +3739,7 @@ var TYPE_TO_MESSAGE = {
|
|
|
2975
3739
|
uint8Array: "a Uint8Array"
|
|
2976
3740
|
};
|
|
2977
3741
|
|
|
2978
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3742
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/transform/object-mode.js
|
|
2979
3743
|
var getTransformObjectModes = (objectMode, index, newTransforms, direction) => direction === "output" ? getOutputObjectModes(objectMode, index, newTransforms) : getInputObjectModes(objectMode, index, newTransforms);
|
|
2980
3744
|
var getOutputObjectModes = (objectMode, index, newTransforms) => {
|
|
2981
3745
|
const writableObjectMode = index !== 0 && newTransforms[index - 1].value.readableObjectMode;
|
|
@@ -2995,7 +3759,7 @@ var getFdObjectMode = (stdioItems, direction) => {
|
|
|
2995
3759
|
return direction === "input" ? lastTransform.value.writableObjectMode : lastTransform.value.readableObjectMode;
|
|
2996
3760
|
};
|
|
2997
3761
|
|
|
2998
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3762
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/transform/normalize.js
|
|
2999
3763
|
var normalizeTransforms = (stdioItems, optionName, direction, options) => [
|
|
3000
3764
|
...stdioItems.filter(({ type }) => !TRANSFORM_TYPES.has(type)),
|
|
3001
3765
|
...getTransforms(stdioItems, optionName, direction, options)
|
|
@@ -3089,7 +3853,7 @@ var normalizeGenerator = ({ stdioItem, stdioItem: { value }, index, newTransform
|
|
|
3089
3853
|
};
|
|
3090
3854
|
var sortTransforms = (newTransforms, direction) => direction === "input" ? newTransforms.reverse() : newTransforms;
|
|
3091
3855
|
|
|
3092
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3856
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/direction.js
|
|
3093
3857
|
import process7 from "node:process";
|
|
3094
3858
|
var getStreamDirection = (stdioItems, fdNumber, optionName) => {
|
|
3095
3859
|
const directions = stdioItems.map((stdioItem) => getStdioItemDirection(stdioItem, fdNumber));
|
|
@@ -3139,10 +3903,13 @@ var getStandardStreamDirection = (value) => {
|
|
|
3139
3903
|
};
|
|
3140
3904
|
var DEFAULT_DIRECTION = "output";
|
|
3141
3905
|
|
|
3142
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3906
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/array.js
|
|
3907
|
+
var normalizeIpcStdioArray = (stdioArray, ipc) => ipc && !stdioArray.includes("ipc") ? [...stdioArray, "ipc"] : stdioArray;
|
|
3908
|
+
|
|
3909
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/stdio-option.js
|
|
3143
3910
|
var normalizeStdioOption = ({ stdio, ipc, buffer, verbose, ...options }, isSync) => {
|
|
3144
3911
|
const stdioArray = getStdioArray(stdio, options).map((stdioOption, fdNumber) => addDefaultValue2(stdioOption, fdNumber));
|
|
3145
|
-
return isSync ? normalizeStdioSync(stdioArray, buffer, verbose) :
|
|
3912
|
+
return isSync ? normalizeStdioSync(stdioArray, buffer, verbose) : normalizeIpcStdioArray(stdioArray, ipc);
|
|
3146
3913
|
};
|
|
3147
3914
|
var getStdioArray = (stdio, options) => {
|
|
3148
3915
|
if (stdio === void 0) {
|
|
@@ -3172,93 +3939,10 @@ var addDefaultValue2 = (stdioOption, fdNumber) => {
|
|
|
3172
3939
|
};
|
|
3173
3940
|
var normalizeStdioSync = (stdioArray, buffer, verbose) => stdioArray.map((stdioOption, fdNumber) => !buffer[fdNumber] && fdNumber !== 0 && verbose[fdNumber] !== "full" && isOutputPipeOnly(stdioOption) ? "ignore" : stdioOption);
|
|
3174
3941
|
var isOutputPipeOnly = (stdioOption) => stdioOption === "pipe" || Array.isArray(stdioOption) && stdioOption.every((item) => item === "pipe");
|
|
3175
|
-
var normalizeStdioAsync = (stdioArray, ipc) => ipc && !stdioArray.includes("ipc") ? [...stdioArray, "ipc"] : stdioArray;
|
|
3176
3942
|
|
|
3177
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3943
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/native.js
|
|
3178
3944
|
import { readFileSync } from "node:fs";
|
|
3179
3945
|
import tty2 from "node:tty";
|
|
3180
|
-
|
|
3181
|
-
// ../../node_modules/.pnpm/execa@9.1.0/node_modules/execa/lib/arguments/fd-options.js
|
|
3182
|
-
var getToStream = (destination, to = "stdin") => {
|
|
3183
|
-
const isWritable = true;
|
|
3184
|
-
const { options, fileDescriptors } = SUBPROCESS_OPTIONS.get(destination);
|
|
3185
|
-
const fdNumber = getFdNumber(fileDescriptors, to, isWritable);
|
|
3186
|
-
const destinationStream = destination.stdio[fdNumber];
|
|
3187
|
-
if (destinationStream === null) {
|
|
3188
|
-
throw new TypeError(getInvalidStdioOptionMessage(fdNumber, to, options, isWritable));
|
|
3189
|
-
}
|
|
3190
|
-
return destinationStream;
|
|
3191
|
-
};
|
|
3192
|
-
var getFromStream = (source, from = "stdout") => {
|
|
3193
|
-
const isWritable = false;
|
|
3194
|
-
const { options, fileDescriptors } = SUBPROCESS_OPTIONS.get(source);
|
|
3195
|
-
const fdNumber = getFdNumber(fileDescriptors, from, isWritable);
|
|
3196
|
-
const sourceStream = fdNumber === "all" ? source.all : source.stdio[fdNumber];
|
|
3197
|
-
if (sourceStream === null || sourceStream === void 0) {
|
|
3198
|
-
throw new TypeError(getInvalidStdioOptionMessage(fdNumber, from, options, isWritable));
|
|
3199
|
-
}
|
|
3200
|
-
return sourceStream;
|
|
3201
|
-
};
|
|
3202
|
-
var SUBPROCESS_OPTIONS = /* @__PURE__ */ new WeakMap();
|
|
3203
|
-
var getFdNumber = (fileDescriptors, fdName, isWritable) => {
|
|
3204
|
-
const fdNumber = parseFdNumber(fdName, isWritable);
|
|
3205
|
-
validateFdNumber(fdNumber, fdName, isWritable, fileDescriptors);
|
|
3206
|
-
return fdNumber;
|
|
3207
|
-
};
|
|
3208
|
-
var parseFdNumber = (fdName, isWritable) => {
|
|
3209
|
-
const fdNumber = parseFd(fdName);
|
|
3210
|
-
if (fdNumber !== void 0) {
|
|
3211
|
-
return fdNumber;
|
|
3212
|
-
}
|
|
3213
|
-
const { validOptions, defaultValue } = isWritable ? { validOptions: '"stdin"', defaultValue: "stdin" } : { validOptions: '"stdout", "stderr", "all"', defaultValue: "stdout" };
|
|
3214
|
-
throw new TypeError(`"${getOptionName(isWritable)}" must not be "${fdName}".
|
|
3215
|
-
It must be ${validOptions} or "fd3", "fd4" (and so on).
|
|
3216
|
-
It is optional and defaults to "${defaultValue}".`);
|
|
3217
|
-
};
|
|
3218
|
-
var validateFdNumber = (fdNumber, fdName, isWritable, fileDescriptors) => {
|
|
3219
|
-
const fileDescriptor = fileDescriptors[getUsedDescriptor(fdNumber)];
|
|
3220
|
-
if (fileDescriptor === void 0) {
|
|
3221
|
-
throw new TypeError(`"${getOptionName(isWritable)}" must not be ${fdName}. That file descriptor does not exist.
|
|
3222
|
-
Please set the "stdio" option to ensure that file descriptor exists.`);
|
|
3223
|
-
}
|
|
3224
|
-
if (fileDescriptor.direction === "input" && !isWritable) {
|
|
3225
|
-
throw new TypeError(`"${getOptionName(isWritable)}" must not be ${fdName}. It must be a readable stream, not writable.`);
|
|
3226
|
-
}
|
|
3227
|
-
if (fileDescriptor.direction !== "input" && isWritable) {
|
|
3228
|
-
throw new TypeError(`"${getOptionName(isWritable)}" must not be ${fdName}. It must be a writable stream, not readable.`);
|
|
3229
|
-
}
|
|
3230
|
-
};
|
|
3231
|
-
var getInvalidStdioOptionMessage = (fdNumber, fdName, options, isWritable) => {
|
|
3232
|
-
if (fdNumber === "all" && !options.all) {
|
|
3233
|
-
return `The "all" option must be true to use "from: 'all'".`;
|
|
3234
|
-
}
|
|
3235
|
-
const { optionName, optionValue } = getInvalidStdioOption(fdNumber, options);
|
|
3236
|
-
return `The "${optionName}: ${serializeOptionValue(optionValue)}" option is incompatible with using "${getOptionName(isWritable)}: ${serializeOptionValue(fdName)}".
|
|
3237
|
-
Please set this option with "pipe" instead.`;
|
|
3238
|
-
};
|
|
3239
|
-
var getInvalidStdioOption = (fdNumber, { stdin, stdout, stderr, stdio }) => {
|
|
3240
|
-
const usedDescriptor = getUsedDescriptor(fdNumber);
|
|
3241
|
-
if (usedDescriptor === 0 && stdin !== void 0) {
|
|
3242
|
-
return { optionName: "stdin", optionValue: stdin };
|
|
3243
|
-
}
|
|
3244
|
-
if (usedDescriptor === 1 && stdout !== void 0) {
|
|
3245
|
-
return { optionName: "stdout", optionValue: stdout };
|
|
3246
|
-
}
|
|
3247
|
-
if (usedDescriptor === 2 && stderr !== void 0) {
|
|
3248
|
-
return { optionName: "stderr", optionValue: stderr };
|
|
3249
|
-
}
|
|
3250
|
-
return { optionName: `stdio[${usedDescriptor}]`, optionValue: stdio[usedDescriptor] };
|
|
3251
|
-
};
|
|
3252
|
-
var getUsedDescriptor = (fdNumber) => fdNumber === "all" ? 1 : fdNumber;
|
|
3253
|
-
var getOptionName = (isWritable) => isWritable ? "to" : "from";
|
|
3254
|
-
var serializeOptionValue = (value) => {
|
|
3255
|
-
if (typeof value === "string") {
|
|
3256
|
-
return `'${value}'`;
|
|
3257
|
-
}
|
|
3258
|
-
return typeof value === "number" ? `${value}` : "Stream";
|
|
3259
|
-
};
|
|
3260
|
-
|
|
3261
|
-
// ../../node_modules/.pnpm/execa@9.1.0/node_modules/execa/lib/stdio/native.js
|
|
3262
3946
|
var handleNativeStream = ({ stdioItem, stdioItem: { type }, isStdioArray, fdNumber, direction, isSync }) => {
|
|
3263
3947
|
if (!isStdioArray || type !== "native") {
|
|
3264
3948
|
return stdioItem;
|
|
@@ -3325,7 +4009,7 @@ var getStandardStream = (fdNumber, value, optionName) => {
|
|
|
3325
4009
|
return standardStream;
|
|
3326
4010
|
};
|
|
3327
4011
|
|
|
3328
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4012
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/input-option.js
|
|
3329
4013
|
var handleInputOptions = ({ input, inputFile }, fdNumber) => fdNumber === 0 ? [
|
|
3330
4014
|
...handleInputOption(input),
|
|
3331
4015
|
...handleInputFileOption(inputFile)
|
|
@@ -3361,7 +4045,7 @@ var getInputFileType = (inputFile) => {
|
|
|
3361
4045
|
throw new Error("The `inputFile` option must be a file path string or a file URL.");
|
|
3362
4046
|
};
|
|
3363
4047
|
|
|
3364
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4048
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/duplicate.js
|
|
3365
4049
|
var filterDuplicates = (stdioItems) => stdioItems.filter((stdioItemOne, indexOne) => stdioItems.every((stdioItemTwo, indexTwo) => stdioItemOne.value !== stdioItemTwo.value || indexOne >= indexTwo || stdioItemOne.type === "generator" || stdioItemOne.type === "asyncGenerator"));
|
|
3366
4050
|
var getDuplicateStream = ({ stdioItem: { type, value, optionName }, direction, fileDescriptors, isSync }) => {
|
|
3367
4051
|
const otherStdioItems = getOtherStdioItems(fileDescriptors, type);
|
|
@@ -3419,7 +4103,7 @@ var getDuplicateStreamInstance = ({ otherStdioItems, type, value, optionName, di
|
|
|
3419
4103
|
};
|
|
3420
4104
|
var hasSameValue = ({ type, value }, secondValue) => {
|
|
3421
4105
|
if (type === "filePath") {
|
|
3422
|
-
return value.
|
|
4106
|
+
return value.file === secondValue.file;
|
|
3423
4107
|
}
|
|
3424
4108
|
if (type === "fileUrl") {
|
|
3425
4109
|
return value.href === secondValue.href;
|
|
@@ -3436,7 +4120,7 @@ var throwOnDuplicateStream = (stdioItem, optionName, type) => {
|
|
|
3436
4120
|
}
|
|
3437
4121
|
};
|
|
3438
4122
|
|
|
3439
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4123
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/handle.js
|
|
3440
4124
|
var handleStdio = (addProperties3, options, verboseInfo, isSync) => {
|
|
3441
4125
|
const stdio = normalizeStdioOption(options, isSync);
|
|
3442
4126
|
const initialFileDescriptors = stdio.map((stdioOption, fdNumber) => getFileDescriptor({
|
|
@@ -3596,7 +4280,7 @@ var forwardStdio = (stdioItems) => {
|
|
|
3596
4280
|
return type === "native" ? value : "pipe";
|
|
3597
4281
|
};
|
|
3598
4282
|
|
|
3599
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4283
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/handle-sync.js
|
|
3600
4284
|
var handleStdioSync = (options, verboseInfo) => handleStdio(addPropertiesSync, options, verboseInfo, true);
|
|
3601
4285
|
var forbiddenIfSync = ({ type, optionName }) => {
|
|
3602
4286
|
throwInvalidSyncValue(optionName, TYPE_TO_MESSAGE[type]);
|
|
@@ -3642,14 +4326,14 @@ var addPropertiesSync = {
|
|
|
3642
4326
|
}
|
|
3643
4327
|
};
|
|
3644
4328
|
|
|
3645
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4329
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/strip-newline.js
|
|
3646
4330
|
var stripNewline = (value, { stripFinalNewline: stripFinalNewline2 }, fdNumber) => getStripFinalNewline(stripFinalNewline2, fdNumber) && value !== void 0 && !Array.isArray(value) ? stripFinalNewline(value) : value;
|
|
3647
4331
|
var getStripFinalNewline = (stripFinalNewline2, fdNumber) => fdNumber === "all" ? stripFinalNewline2[1] || stripFinalNewline2[2] : stripFinalNewline2[fdNumber];
|
|
3648
4332
|
|
|
3649
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4333
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/transform/generator.js
|
|
3650
4334
|
import { Transform, getDefaultHighWaterMark } from "node:stream";
|
|
3651
4335
|
|
|
3652
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4336
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/transform/split.js
|
|
3653
4337
|
var getSplitLinesGenerator = (binary, preserveNewlines, skipped, state) => binary || skipped ? void 0 : initializeSplitLines(preserveNewlines, state);
|
|
3654
4338
|
var splitLinesSync = (chunk, preserveNewlines, objectMode) => objectMode ? chunk.flatMap((item) => splitLinesItemSync(item, preserveNewlines)) : splitLinesItemSync(chunk, preserveNewlines);
|
|
3655
4339
|
var splitLinesItemSync = (chunk, preserveNewlines) => {
|
|
@@ -3729,7 +4413,7 @@ var linesUint8ArrayInfo = {
|
|
|
3729
4413
|
concatBytes: concatUint8Array
|
|
3730
4414
|
};
|
|
3731
4415
|
|
|
3732
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4416
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/transform/validate.js
|
|
3733
4417
|
import { Buffer as Buffer2 } from "node:buffer";
|
|
3734
4418
|
var getValidateTransformInput = (writableObjectMode, optionName) => writableObjectMode ? void 0 : validateStringTransformInput.bind(void 0, optionName);
|
|
3735
4419
|
var validateStringTransformInput = function* (optionName, chunk) {
|
|
@@ -3758,7 +4442,7 @@ Instead, \`yield\` should either be called with a value, or not be called at all
|
|
|
3758
4442
|
}
|
|
3759
4443
|
};
|
|
3760
4444
|
|
|
3761
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4445
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/transform/encoding-transform.js
|
|
3762
4446
|
import { Buffer as Buffer3 } from "node:buffer";
|
|
3763
4447
|
import { StringDecoder as StringDecoder2 } from "node:string_decoder";
|
|
3764
4448
|
var getEncodingTransformGenerator = (binary, encoding, skipped) => {
|
|
@@ -3793,7 +4477,7 @@ var encodingStringFinal = function* (stringDecoder) {
|
|
|
3793
4477
|
}
|
|
3794
4478
|
};
|
|
3795
4479
|
|
|
3796
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4480
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/transform/run-async.js
|
|
3797
4481
|
import { callbackify } from "node:util";
|
|
3798
4482
|
var pushChunks = callbackify(async (getChunks, state, getChunksArguments, transformStream) => {
|
|
3799
4483
|
state.currentIterable = getChunks(...getChunksArguments);
|
|
@@ -3841,7 +4525,7 @@ var identityGenerator = function* (chunk) {
|
|
|
3841
4525
|
yield chunk;
|
|
3842
4526
|
};
|
|
3843
4527
|
|
|
3844
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4528
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/transform/run-sync.js
|
|
3845
4529
|
var pushChunksSync = (getChunksSync, getChunksArguments, transformStream, done) => {
|
|
3846
4530
|
try {
|
|
3847
4531
|
for (const chunk of getChunksSync(...getChunksArguments)) {
|
|
@@ -3883,7 +4567,7 @@ var identityGenerator2 = function* (chunk) {
|
|
|
3883
4567
|
yield chunk;
|
|
3884
4568
|
};
|
|
3885
4569
|
|
|
3886
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4570
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/transform/generator.js
|
|
3887
4571
|
var generatorToStream = ({
|
|
3888
4572
|
value,
|
|
3889
4573
|
value: { transform, final, writableObjectMode, readableObjectMode },
|
|
@@ -3937,7 +4621,7 @@ var addInternalGenerators = ({ transform, final, binary, writableObjectMode, rea
|
|
|
3937
4621
|
].filter(Boolean);
|
|
3938
4622
|
};
|
|
3939
4623
|
|
|
3940
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4624
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/input-sync.js
|
|
3941
4625
|
var addInputOptionsSync = (fileDescriptors, options) => {
|
|
3942
4626
|
for (const fdNumber of getInputFdNumbers(fileDescriptors)) {
|
|
3943
4627
|
addInputOptionSync(fileDescriptors, fdNumber, options);
|
|
@@ -3970,11 +4654,10 @@ var validateSerializable = (newContents) => {
|
|
|
3970
4654
|
}
|
|
3971
4655
|
};
|
|
3972
4656
|
|
|
3973
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4657
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/output-sync.js
|
|
3974
4658
|
import { writeFileSync as writeFileSync2, appendFileSync } from "node:fs";
|
|
3975
4659
|
|
|
3976
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
3977
|
-
import { inspect } from "node:util";
|
|
4660
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/verbose/output.js
|
|
3978
4661
|
var shouldLogOutput = ({ stdioItems, encoding, verboseInfo: { verbose }, fdNumber }) => fdNumber !== "all" && verbose[fdNumber] === "full" && !BINARY_ENCODINGS.has(encoding) && fdUsesVerbose(fdNumber) && (stdioItems.some(({ type, value }) => type === "native" && PIPED_STDIO_VALUES.has(value)) || stdioItems.every(({ type }) => TRANSFORM_TYPES.has(type)));
|
|
3979
4662
|
var fdUsesVerbose = (fdNumber) => fdNumber === 1 || fdNumber === 2;
|
|
3980
4663
|
var PIPED_STDIO_VALUES = /* @__PURE__ */ new Set(["pipe", "overlapped"]);
|
|
@@ -3992,14 +4675,10 @@ var logLinesSync = (linesArray, verboseInfo) => {
|
|
|
3992
4675
|
};
|
|
3993
4676
|
var isPipingStream = (stream) => stream._readableState.pipes.length > 0;
|
|
3994
4677
|
var logLine = (line, { verboseId }) => {
|
|
3995
|
-
|
|
3996
|
-
const escapedLines = escapeLines(lines);
|
|
3997
|
-
const spacedLines = escapedLines.replaceAll(" ", " ".repeat(TAB_SIZE));
|
|
3998
|
-
verboseLog(spacedLines, verboseId, "output");
|
|
4678
|
+
verboseLog(serializeLogMessage(line), verboseId, "output");
|
|
3999
4679
|
};
|
|
4000
|
-
var TAB_SIZE = 2;
|
|
4001
4680
|
|
|
4002
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4681
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/output-sync.js
|
|
4003
4682
|
var transformOutputSync = ({ fileDescriptors, syncResult: { output }, options, isMaxBuffer, verboseInfo }) => {
|
|
4004
4683
|
if (output === null) {
|
|
4005
4684
|
return { output: Array.from({ length: 3 }) };
|
|
@@ -4086,7 +4765,7 @@ var writeToFiles = (serializedResult, stdioItems, outputFiles) => {
|
|
|
4086
4765
|
}
|
|
4087
4766
|
};
|
|
4088
4767
|
|
|
4089
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4768
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/resolve/all-sync.js
|
|
4090
4769
|
var getAllSync = ([, stdout, stderr], options) => {
|
|
4091
4770
|
if (!options.all) {
|
|
4092
4771
|
return;
|
|
@@ -4109,12 +4788,17 @@ var getAllSync = ([, stdout, stderr], options) => {
|
|
|
4109
4788
|
return `${stdout}${stderr}`;
|
|
4110
4789
|
};
|
|
4111
4790
|
|
|
4112
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4113
|
-
import { once } from "node:events";
|
|
4114
|
-
var waitForExit = async (subprocess) => {
|
|
4791
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/resolve/exit-async.js
|
|
4792
|
+
import { once as once4 } from "node:events";
|
|
4793
|
+
var waitForExit = async (subprocess, context) => {
|
|
4794
|
+
const [exitCode, signal] = await waitForExitOrError(subprocess);
|
|
4795
|
+
context.isForcefullyTerminated ??= false;
|
|
4796
|
+
return [exitCode, signal];
|
|
4797
|
+
};
|
|
4798
|
+
var waitForExitOrError = async (subprocess) => {
|
|
4115
4799
|
const [spawnPayload, exitPayload] = await Promise.allSettled([
|
|
4116
|
-
|
|
4117
|
-
|
|
4800
|
+
once4(subprocess, "spawn"),
|
|
4801
|
+
once4(subprocess, "exit")
|
|
4118
4802
|
]);
|
|
4119
4803
|
if (spawnPayload.status === "rejected") {
|
|
4120
4804
|
return [];
|
|
@@ -4123,7 +4807,7 @@ var waitForExit = async (subprocess) => {
|
|
|
4123
4807
|
};
|
|
4124
4808
|
var waitForSubprocessExit = async (subprocess) => {
|
|
4125
4809
|
try {
|
|
4126
|
-
return await
|
|
4810
|
+
return await once4(subprocess, "exit");
|
|
4127
4811
|
} catch {
|
|
4128
4812
|
return waitForSubprocessExit(subprocess);
|
|
4129
4813
|
}
|
|
@@ -4138,7 +4822,7 @@ var waitForSuccessfulExit = async (exitPromise) => {
|
|
|
4138
4822
|
var isSubprocessErrorExit = (exitCode, signal) => exitCode === void 0 && signal === void 0;
|
|
4139
4823
|
var isFailedExit = (exitCode, signal) => exitCode !== 0 || signal !== null;
|
|
4140
4824
|
|
|
4141
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4825
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/resolve/exit-sync.js
|
|
4142
4826
|
var getExitResultSync = ({ error, status: exitCode, signal, output }, { maxBuffer }) => {
|
|
4143
4827
|
const resultError = getResultError(error, exitCode, signal);
|
|
4144
4828
|
const timedOut = resultError?.code === "ETIMEDOUT";
|
|
@@ -4158,7 +4842,7 @@ var getResultError = (error, exitCode, signal) => {
|
|
|
4158
4842
|
return isFailedExit(exitCode, signal) ? new DiscardedError() : void 0;
|
|
4159
4843
|
};
|
|
4160
4844
|
|
|
4161
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4845
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/main-sync.js
|
|
4162
4846
|
var execaCoreSync = (rawFile, rawArguments, rawOptions) => {
|
|
4163
4847
|
const { file, commandArguments, command, escapedCommand, startTime, verboseInfo, options, fileDescriptors } = handleSyncArguments(rawFile, rawArguments, rawOptions);
|
|
4164
4848
|
const result = spawnSubprocessSync({
|
|
@@ -4196,7 +4880,10 @@ var handleSyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
|
4196
4880
|
}
|
|
4197
4881
|
};
|
|
4198
4882
|
var normalizeSyncOptions = (options) => options.node && !options.ipc ? { ...options, ipc: false } : options;
|
|
4199
|
-
var validateSyncOptions = ({ ipc, detached, cancelSignal }) => {
|
|
4883
|
+
var validateSyncOptions = ({ ipc, ipcInput, detached, cancelSignal }) => {
|
|
4884
|
+
if (ipcInput) {
|
|
4885
|
+
throwInvalidSyncOption("ipcInput");
|
|
4886
|
+
}
|
|
4200
4887
|
if (ipc) {
|
|
4201
4888
|
throwInvalidSyncOption("ipc: true");
|
|
4202
4889
|
}
|
|
@@ -4270,6 +4957,7 @@ var getSyncResult = ({ error, exitCode, signal, timedOut, isMaxBuffer, stdio, al
|
|
|
4270
4957
|
escapedCommand,
|
|
4271
4958
|
stdio,
|
|
4272
4959
|
all,
|
|
4960
|
+
ipcOutput: [],
|
|
4273
4961
|
options,
|
|
4274
4962
|
startTime
|
|
4275
4963
|
}) : makeError({
|
|
@@ -4278,21 +4966,200 @@ var getSyncResult = ({ error, exitCode, signal, timedOut, isMaxBuffer, stdio, al
|
|
|
4278
4966
|
escapedCommand,
|
|
4279
4967
|
timedOut,
|
|
4280
4968
|
isCanceled: false,
|
|
4969
|
+
isGracefullyCanceled: false,
|
|
4281
4970
|
isMaxBuffer,
|
|
4971
|
+
isForcefullyTerminated: false,
|
|
4282
4972
|
exitCode,
|
|
4283
4973
|
signal,
|
|
4284
4974
|
stdio,
|
|
4285
4975
|
all,
|
|
4976
|
+
ipcOutput: [],
|
|
4286
4977
|
options,
|
|
4287
4978
|
startTime,
|
|
4288
4979
|
isSync: true
|
|
4289
4980
|
});
|
|
4290
4981
|
|
|
4291
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4982
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/main-async.js
|
|
4292
4983
|
import { setMaxListeners } from "node:events";
|
|
4293
4984
|
import { spawn } from "node:child_process";
|
|
4294
4985
|
|
|
4295
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4986
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/methods.js
|
|
4987
|
+
import process8 from "node:process";
|
|
4988
|
+
|
|
4989
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/get-one.js
|
|
4990
|
+
import { once as once5, on as on2 } from "node:events";
|
|
4991
|
+
var getOneMessage = ({ anyProcess, channel, isSubprocess, ipc }, { reference = true, filter } = {}) => {
|
|
4992
|
+
validateIpcMethod({
|
|
4993
|
+
methodName: "getOneMessage",
|
|
4994
|
+
isSubprocess,
|
|
4995
|
+
ipc,
|
|
4996
|
+
isConnected: isConnected(anyProcess)
|
|
4997
|
+
});
|
|
4998
|
+
return getOneMessageAsync({
|
|
4999
|
+
anyProcess,
|
|
5000
|
+
channel,
|
|
5001
|
+
isSubprocess,
|
|
5002
|
+
filter,
|
|
5003
|
+
reference
|
|
5004
|
+
});
|
|
5005
|
+
};
|
|
5006
|
+
var getOneMessageAsync = async ({ anyProcess, channel, isSubprocess, filter, reference }) => {
|
|
5007
|
+
addReference(channel, reference);
|
|
5008
|
+
const ipcEmitter = getIpcEmitter(anyProcess, channel, isSubprocess);
|
|
5009
|
+
const controller = new AbortController();
|
|
5010
|
+
try {
|
|
5011
|
+
return await Promise.race([
|
|
5012
|
+
getMessage(ipcEmitter, filter, controller),
|
|
5013
|
+
throwOnDisconnect2(ipcEmitter, isSubprocess, controller),
|
|
5014
|
+
throwOnStrictError(ipcEmitter, isSubprocess, controller)
|
|
5015
|
+
]);
|
|
5016
|
+
} catch (error) {
|
|
5017
|
+
disconnect(anyProcess);
|
|
5018
|
+
throw error;
|
|
5019
|
+
} finally {
|
|
5020
|
+
controller.abort();
|
|
5021
|
+
removeReference(channel, reference);
|
|
5022
|
+
}
|
|
5023
|
+
};
|
|
5024
|
+
var getMessage = async (ipcEmitter, filter, { signal }) => {
|
|
5025
|
+
if (filter === void 0) {
|
|
5026
|
+
const [message] = await once5(ipcEmitter, "message", { signal });
|
|
5027
|
+
return message;
|
|
5028
|
+
}
|
|
5029
|
+
for await (const [message] of on2(ipcEmitter, "message", { signal })) {
|
|
5030
|
+
if (filter(message)) {
|
|
5031
|
+
return message;
|
|
5032
|
+
}
|
|
5033
|
+
}
|
|
5034
|
+
};
|
|
5035
|
+
var throwOnDisconnect2 = async (ipcEmitter, isSubprocess, { signal }) => {
|
|
5036
|
+
await once5(ipcEmitter, "disconnect", { signal });
|
|
5037
|
+
throwOnEarlyDisconnect(isSubprocess);
|
|
5038
|
+
};
|
|
5039
|
+
var throwOnStrictError = async (ipcEmitter, isSubprocess, { signal }) => {
|
|
5040
|
+
const [error] = await once5(ipcEmitter, "strict:error", { signal });
|
|
5041
|
+
throw getStrictResponseError(error, isSubprocess);
|
|
5042
|
+
};
|
|
5043
|
+
|
|
5044
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/get-each.js
|
|
5045
|
+
import { once as once6, on as on3 } from "node:events";
|
|
5046
|
+
var getEachMessage = ({ anyProcess, channel, isSubprocess, ipc }, { reference = true } = {}) => loopOnMessages({
|
|
5047
|
+
anyProcess,
|
|
5048
|
+
channel,
|
|
5049
|
+
isSubprocess,
|
|
5050
|
+
ipc,
|
|
5051
|
+
shouldAwait: !isSubprocess,
|
|
5052
|
+
reference
|
|
5053
|
+
});
|
|
5054
|
+
var loopOnMessages = ({ anyProcess, channel, isSubprocess, ipc, shouldAwait, reference }) => {
|
|
5055
|
+
validateIpcMethod({
|
|
5056
|
+
methodName: "getEachMessage",
|
|
5057
|
+
isSubprocess,
|
|
5058
|
+
ipc,
|
|
5059
|
+
isConnected: isConnected(anyProcess)
|
|
5060
|
+
});
|
|
5061
|
+
addReference(channel, reference);
|
|
5062
|
+
const ipcEmitter = getIpcEmitter(anyProcess, channel, isSubprocess);
|
|
5063
|
+
const controller = new AbortController();
|
|
5064
|
+
const state = {};
|
|
5065
|
+
stopOnDisconnect(anyProcess, ipcEmitter, controller);
|
|
5066
|
+
abortOnStrictError({
|
|
5067
|
+
ipcEmitter,
|
|
5068
|
+
isSubprocess,
|
|
5069
|
+
controller,
|
|
5070
|
+
state
|
|
5071
|
+
});
|
|
5072
|
+
return iterateOnMessages({
|
|
5073
|
+
anyProcess,
|
|
5074
|
+
channel,
|
|
5075
|
+
ipcEmitter,
|
|
5076
|
+
isSubprocess,
|
|
5077
|
+
shouldAwait,
|
|
5078
|
+
controller,
|
|
5079
|
+
state,
|
|
5080
|
+
reference
|
|
5081
|
+
});
|
|
5082
|
+
};
|
|
5083
|
+
var stopOnDisconnect = async (anyProcess, ipcEmitter, controller) => {
|
|
5084
|
+
try {
|
|
5085
|
+
await once6(ipcEmitter, "disconnect", { signal: controller.signal });
|
|
5086
|
+
controller.abort();
|
|
5087
|
+
} catch {
|
|
5088
|
+
}
|
|
5089
|
+
};
|
|
5090
|
+
var abortOnStrictError = async ({ ipcEmitter, isSubprocess, controller, state }) => {
|
|
5091
|
+
try {
|
|
5092
|
+
const [error] = await once6(ipcEmitter, "strict:error", { signal: controller.signal });
|
|
5093
|
+
state.error = getStrictResponseError(error, isSubprocess);
|
|
5094
|
+
controller.abort();
|
|
5095
|
+
} catch {
|
|
5096
|
+
}
|
|
5097
|
+
};
|
|
5098
|
+
var iterateOnMessages = async function* ({ anyProcess, channel, ipcEmitter, isSubprocess, shouldAwait, controller, state, reference }) {
|
|
5099
|
+
try {
|
|
5100
|
+
for await (const [message] of on3(ipcEmitter, "message", { signal: controller.signal })) {
|
|
5101
|
+
throwIfStrictError(state);
|
|
5102
|
+
yield message;
|
|
5103
|
+
}
|
|
5104
|
+
} catch {
|
|
5105
|
+
throwIfStrictError(state);
|
|
5106
|
+
} finally {
|
|
5107
|
+
controller.abort();
|
|
5108
|
+
removeReference(channel, reference);
|
|
5109
|
+
if (!isSubprocess) {
|
|
5110
|
+
disconnect(anyProcess);
|
|
5111
|
+
}
|
|
5112
|
+
if (shouldAwait) {
|
|
5113
|
+
await anyProcess;
|
|
5114
|
+
}
|
|
5115
|
+
}
|
|
5116
|
+
};
|
|
5117
|
+
var throwIfStrictError = ({ error }) => {
|
|
5118
|
+
if (error) {
|
|
5119
|
+
throw error;
|
|
5120
|
+
}
|
|
5121
|
+
};
|
|
5122
|
+
|
|
5123
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/methods.js
|
|
5124
|
+
var addIpcMethods = (subprocess, { ipc }) => {
|
|
5125
|
+
Object.assign(subprocess, getIpcMethods(subprocess, false, ipc));
|
|
5126
|
+
};
|
|
5127
|
+
var getIpcExport = () => {
|
|
5128
|
+
const anyProcess = process8;
|
|
5129
|
+
const isSubprocess = true;
|
|
5130
|
+
const ipc = process8.channel !== void 0;
|
|
5131
|
+
return {
|
|
5132
|
+
...getIpcMethods(anyProcess, isSubprocess, ipc),
|
|
5133
|
+
getCancelSignal: getCancelSignal.bind(void 0, {
|
|
5134
|
+
anyProcess,
|
|
5135
|
+
channel: anyProcess.channel,
|
|
5136
|
+
isSubprocess,
|
|
5137
|
+
ipc
|
|
5138
|
+
})
|
|
5139
|
+
};
|
|
5140
|
+
};
|
|
5141
|
+
var getIpcMethods = (anyProcess, isSubprocess, ipc) => ({
|
|
5142
|
+
sendMessage: sendMessage.bind(void 0, {
|
|
5143
|
+
anyProcess,
|
|
5144
|
+
channel: anyProcess.channel,
|
|
5145
|
+
isSubprocess,
|
|
5146
|
+
ipc
|
|
5147
|
+
}),
|
|
5148
|
+
getOneMessage: getOneMessage.bind(void 0, {
|
|
5149
|
+
anyProcess,
|
|
5150
|
+
channel: anyProcess.channel,
|
|
5151
|
+
isSubprocess,
|
|
5152
|
+
ipc
|
|
5153
|
+
}),
|
|
5154
|
+
getEachMessage: getEachMessage.bind(void 0, {
|
|
5155
|
+
anyProcess,
|
|
5156
|
+
channel: anyProcess.channel,
|
|
5157
|
+
isSubprocess,
|
|
5158
|
+
ipc
|
|
5159
|
+
})
|
|
5160
|
+
});
|
|
5161
|
+
|
|
5162
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/return/early-error.js
|
|
4296
5163
|
import { ChildProcess as ChildProcess2 } from "node:child_process";
|
|
4297
5164
|
import {
|
|
4298
5165
|
PassThrough,
|
|
@@ -4346,7 +5213,7 @@ var duplex = () => new Duplex({ read() {
|
|
|
4346
5213
|
} });
|
|
4347
5214
|
var handleDummyPromise = async (error, verboseInfo, options) => handleResult(error, verboseInfo, options);
|
|
4348
5215
|
|
|
4349
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5216
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/stdio/handle-async.js
|
|
4350
5217
|
import { createReadStream, createWriteStream } from "node:fs";
|
|
4351
5218
|
import { Buffer as Buffer4 } from "node:buffer";
|
|
4352
5219
|
import { Readable as Readable2, Writable as Writable2, Duplex as Duplex2 } from "node:stream";
|
|
@@ -4392,7 +5259,7 @@ var addPropertiesAsync = {
|
|
|
4392
5259
|
};
|
|
4393
5260
|
|
|
4394
5261
|
// ../../node_modules/.pnpm/@sindresorhus+merge-streams@4.0.0/node_modules/@sindresorhus/merge-streams/index.js
|
|
4395
|
-
import { on as
|
|
5262
|
+
import { on as on4, once as once7 } from "node:events";
|
|
4396
5263
|
import { PassThrough as PassThroughStream, getDefaultHighWaterMark as getDefaultHighWaterMark2 } from "node:stream";
|
|
4397
5264
|
import { finished as finished2 } from "node:stream/promises";
|
|
4398
5265
|
function mergeStreams(streams) {
|
|
@@ -4484,7 +5351,7 @@ var onMergedStreamEnd = async (passThroughStream, { signal }) => {
|
|
|
4484
5351
|
}
|
|
4485
5352
|
};
|
|
4486
5353
|
var onInputStreamsUnpipe = async (passThroughStream, streams, unpipeEvent, { signal }) => {
|
|
4487
|
-
for await (const [unpipedStream] of
|
|
5354
|
+
for await (const [unpipedStream] of on4(passThroughStream, "unpipe", { signal })) {
|
|
4488
5355
|
if (streams.has(unpipedStream)) {
|
|
4489
5356
|
unpipedStream.emit(unpipeEvent);
|
|
4490
5357
|
}
|
|
@@ -4565,9 +5432,9 @@ var onInputStreamEnd = async ({ passThroughStream, stream, streams, ended, abort
|
|
|
4565
5432
|
}
|
|
4566
5433
|
};
|
|
4567
5434
|
var onInputStreamUnpipe = async ({ stream, streams, ended, aborted: aborted2, unpipeEvent, controller: { signal } }) => {
|
|
4568
|
-
await
|
|
5435
|
+
await once7(stream, unpipeEvent, { signal });
|
|
4569
5436
|
if (!stream.readable) {
|
|
4570
|
-
return
|
|
5437
|
+
return once7(signal, "abort", { signal });
|
|
4571
5438
|
}
|
|
4572
5439
|
streams.delete(stream);
|
|
4573
5440
|
ended.delete(stream);
|
|
@@ -4608,20 +5475,7 @@ var updateMaxListeners = (passThroughStream, increment2) => {
|
|
|
4608
5475
|
var PASSTHROUGH_LISTENERS_COUNT = 2;
|
|
4609
5476
|
var PASSTHROUGH_LISTENERS_PER_STREAM = 1;
|
|
4610
5477
|
|
|
4611
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
4612
|
-
import { addAbortListener } from "node:events";
|
|
4613
|
-
var incrementMaxListeners = (eventEmitter, maxListenersIncrement, signal) => {
|
|
4614
|
-
const maxListeners = eventEmitter.getMaxListeners();
|
|
4615
|
-
if (maxListeners === 0 || maxListeners === Number.POSITIVE_INFINITY) {
|
|
4616
|
-
return;
|
|
4617
|
-
}
|
|
4618
|
-
eventEmitter.setMaxListeners(maxListeners + maxListenersIncrement);
|
|
4619
|
-
addAbortListener(signal, () => {
|
|
4620
|
-
eventEmitter.setMaxListeners(eventEmitter.getMaxListeners() - maxListenersIncrement);
|
|
4621
|
-
});
|
|
4622
|
-
};
|
|
4623
|
-
|
|
4624
|
-
// ../../node_modules/.pnpm/execa@9.1.0/node_modules/execa/lib/io/pipeline.js
|
|
5478
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/pipeline.js
|
|
4625
5479
|
import { finished as finished3 } from "node:stream/promises";
|
|
4626
5480
|
var pipeStreams = (source, destination) => {
|
|
4627
5481
|
source.pipe(destination);
|
|
@@ -4659,7 +5513,7 @@ var abortSourceStream = (source) => {
|
|
|
4659
5513
|
}
|
|
4660
5514
|
};
|
|
4661
5515
|
|
|
4662
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5516
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/output-async.js
|
|
4663
5517
|
var pipeOutputAsync = (subprocess, fileDescriptors, controller) => {
|
|
4664
5518
|
const pipeGroups = /* @__PURE__ */ new Map();
|
|
4665
5519
|
for (const [fdNumber, { stdioItems, direction }] of Object.entries(fileDescriptors)) {
|
|
@@ -4711,7 +5565,7 @@ var setStandardStreamMaxListeners = (stream, { signal }) => {
|
|
|
4711
5565
|
};
|
|
4712
5566
|
var MAX_LISTENERS_INCREMENT = 2;
|
|
4713
5567
|
|
|
4714
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5568
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/terminate/cleanup.js
|
|
4715
5569
|
import { addAbortListener as addAbortListener2 } from "node:events";
|
|
4716
5570
|
|
|
4717
5571
|
// ../../node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/mjs/signals.js
|
|
@@ -4739,7 +5593,7 @@ if (process.platform === "linux") {
|
|
|
4739
5593
|
}
|
|
4740
5594
|
|
|
4741
5595
|
// ../../node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/mjs/index.js
|
|
4742
|
-
var processOk = (
|
|
5596
|
+
var processOk = (process10) => !!process10 && typeof process10 === "object" && typeof process10.removeListener === "function" && typeof process10.emit === "function" && typeof process10.reallyExit === "function" && typeof process10.listeners === "function" && typeof process10.kill === "function" && typeof process10.pid === "number" && typeof process10.on === "function";
|
|
4743
5597
|
var kExitEmitter = Symbol.for("signal-exit emitter");
|
|
4744
5598
|
var global2 = globalThis;
|
|
4745
5599
|
var ObjectDefineProperty = Object.defineProperty.bind(Object);
|
|
@@ -4824,7 +5678,7 @@ var SignalExit = class extends SignalExitBase {
|
|
|
4824
5678
|
// "SIGHUP" throws an `ENOSYS` error on Windows,
|
|
4825
5679
|
// so use a supported signal instead
|
|
4826
5680
|
/* c8 ignore start */
|
|
4827
|
-
#hupSig =
|
|
5681
|
+
#hupSig = process9.platform === "win32" ? "SIGINT" : "SIGHUP";
|
|
4828
5682
|
/* c8 ignore stop */
|
|
4829
5683
|
#emitter = new Emitter();
|
|
4830
5684
|
#process;
|
|
@@ -4832,29 +5686,29 @@ var SignalExit = class extends SignalExitBase {
|
|
|
4832
5686
|
#originalProcessReallyExit;
|
|
4833
5687
|
#sigListeners = {};
|
|
4834
5688
|
#loaded = false;
|
|
4835
|
-
constructor(
|
|
5689
|
+
constructor(process10) {
|
|
4836
5690
|
super();
|
|
4837
|
-
this.#process =
|
|
5691
|
+
this.#process = process10;
|
|
4838
5692
|
this.#sigListeners = {};
|
|
4839
5693
|
for (const sig of signals) {
|
|
4840
5694
|
this.#sigListeners[sig] = () => {
|
|
4841
5695
|
const listeners = this.#process.listeners(sig);
|
|
4842
|
-
let { count } = this.#emitter;
|
|
4843
|
-
const p =
|
|
5696
|
+
let { count: count2 } = this.#emitter;
|
|
5697
|
+
const p = process10;
|
|
4844
5698
|
if (typeof p.__signal_exit_emitter__ === "object" && typeof p.__signal_exit_emitter__.count === "number") {
|
|
4845
|
-
|
|
5699
|
+
count2 += p.__signal_exit_emitter__.count;
|
|
4846
5700
|
}
|
|
4847
|
-
if (listeners.length ===
|
|
5701
|
+
if (listeners.length === count2) {
|
|
4848
5702
|
this.unload();
|
|
4849
5703
|
const ret = this.#emitter.emit("exit", null, sig);
|
|
4850
5704
|
const s = sig === "SIGHUP" ? this.#hupSig : sig;
|
|
4851
5705
|
if (!ret)
|
|
4852
|
-
|
|
5706
|
+
process10.kill(process10.pid, s);
|
|
4853
5707
|
}
|
|
4854
5708
|
};
|
|
4855
5709
|
}
|
|
4856
|
-
this.#originalProcessReallyExit =
|
|
4857
|
-
this.#originalProcessEmit =
|
|
5710
|
+
this.#originalProcessReallyExit = process10.reallyExit;
|
|
5711
|
+
this.#originalProcessEmit = process10.emit;
|
|
4858
5712
|
}
|
|
4859
5713
|
onExit(cb, opts) {
|
|
4860
5714
|
if (!processOk(this.#process)) {
|
|
@@ -4935,7 +5789,7 @@ var SignalExit = class extends SignalExitBase {
|
|
|
4935
5789
|
}
|
|
4936
5790
|
}
|
|
4937
5791
|
};
|
|
4938
|
-
var
|
|
5792
|
+
var process9 = globalThis.process;
|
|
4939
5793
|
var {
|
|
4940
5794
|
/**
|
|
4941
5795
|
* Called when the process is exiting, whether via signal, explicit
|
|
@@ -4963,9 +5817,9 @@ var {
|
|
|
4963
5817
|
* @internal
|
|
4964
5818
|
*/
|
|
4965
5819
|
unload
|
|
4966
|
-
} = signalExitWrap(processOk(
|
|
5820
|
+
} = signalExitWrap(processOk(process9) ? new SignalExit(process9) : new SignalExitFallback());
|
|
4967
5821
|
|
|
4968
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5822
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/terminate/cleanup.js
|
|
4969
5823
|
var cleanupOnExit = (subprocess, { cleanup, detached }, { signal }) => {
|
|
4970
5824
|
if (!cleanup || detached) {
|
|
4971
5825
|
return;
|
|
@@ -4978,7 +5832,7 @@ var cleanupOnExit = (subprocess, { cleanup, detached }, { signal }) => {
|
|
|
4978
5832
|
});
|
|
4979
5833
|
};
|
|
4980
5834
|
|
|
4981
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5835
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/pipe/pipe-arguments.js
|
|
4982
5836
|
var normalizePipeArguments = ({ source, sourcePromise, boundOptions, createNested }, ...pipeArguments) => {
|
|
4983
5837
|
const startTime = getStartTime();
|
|
4984
5838
|
const {
|
|
@@ -5051,7 +5905,7 @@ var getSourceStream = (source, from) => {
|
|
|
5051
5905
|
}
|
|
5052
5906
|
};
|
|
5053
5907
|
|
|
5054
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5908
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/pipe/throw.js
|
|
5055
5909
|
var handlePipeArgumentsError = ({
|
|
5056
5910
|
sourceStream,
|
|
5057
5911
|
sourceError,
|
|
@@ -5100,7 +5954,7 @@ var createNonCommandError = ({ error, fileDescriptors, sourceOptions, startTime
|
|
|
5100
5954
|
});
|
|
5101
5955
|
var PIPE_COMMAND_MESSAGE = "source.pipe(destination)";
|
|
5102
5956
|
|
|
5103
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5957
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/pipe/sequence.js
|
|
5104
5958
|
var waitForBothSubprocesses = async (subprocessPromises) => {
|
|
5105
5959
|
const [
|
|
5106
5960
|
{ status: sourceStatus, reason: sourceReason, value: sourceResult = sourceReason },
|
|
@@ -5118,7 +5972,7 @@ var waitForBothSubprocesses = async (subprocessPromises) => {
|
|
|
5118
5972
|
return destinationResult;
|
|
5119
5973
|
};
|
|
5120
5974
|
|
|
5121
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5975
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/pipe/streaming.js
|
|
5122
5976
|
import { finished as finished4 } from "node:stream/promises";
|
|
5123
5977
|
var pipeSubprocessStream = (sourceStream, destinationStream, maxListenersController) => {
|
|
5124
5978
|
const mergedStream = MERGED_STREAMS.has(destinationStream) ? pipeMoreSubprocessStream(sourceStream, destinationStream) : pipeFirstSubprocessStream(sourceStream, destinationStream);
|
|
@@ -5149,7 +6003,7 @@ var MERGED_STREAMS = /* @__PURE__ */ new WeakMap();
|
|
|
5149
6003
|
var SOURCE_LISTENERS_PER_PIPE = 2;
|
|
5150
6004
|
var DESTINATION_LISTENERS_PER_PIPE = 1;
|
|
5151
6005
|
|
|
5152
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6006
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/pipe/abort.js
|
|
5153
6007
|
import { aborted } from "node:util";
|
|
5154
6008
|
var unpipeOnAbort = (unpipeSignal, unpipeContext) => unpipeSignal === void 0 ? [] : [unpipeOnSignalAbort(unpipeSignal, unpipeContext)];
|
|
5155
6009
|
var unpipeOnSignalAbort = async (unpipeSignal, { sourceStream, mergedStream, fileDescriptors, sourceOptions, startTime }) => {
|
|
@@ -5164,7 +6018,7 @@ var unpipeOnSignalAbort = async (unpipeSignal, { sourceStream, mergedStream, fil
|
|
|
5164
6018
|
});
|
|
5165
6019
|
};
|
|
5166
6020
|
|
|
5167
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6021
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/pipe/setup.js
|
|
5168
6022
|
var pipeToSubprocess = (sourceInfo, ...pipeArguments) => {
|
|
5169
6023
|
if (isPlainObject(pipeArguments[0])) {
|
|
5170
6024
|
return pipeToSubprocess.bind(void 0, {
|
|
@@ -5223,11 +6077,11 @@ var handlePipePromise = async ({
|
|
|
5223
6077
|
};
|
|
5224
6078
|
var getSubprocessPromises = (sourcePromise, destination) => Promise.allSettled([sourcePromise, destination]);
|
|
5225
6079
|
|
|
5226
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6080
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/contents.js
|
|
5227
6081
|
import { setImmediate } from "node:timers/promises";
|
|
5228
6082
|
|
|
5229
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5230
|
-
import { on as
|
|
6083
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/iterate.js
|
|
6084
|
+
import { on as on5 } from "node:events";
|
|
5231
6085
|
import { getDefaultHighWaterMark as getDefaultHighWaterMark3 } from "node:stream";
|
|
5232
6086
|
var iterateOnSubprocessStream = ({ subprocessStdout, subprocess, binary, shouldEncode, encoding, preserveNewlines }) => {
|
|
5233
6087
|
const controller = new AbortController();
|
|
@@ -5274,7 +6128,7 @@ var stopReadingOnStreamEnd = async (onStreamEnd, controller, stream) => {
|
|
|
5274
6128
|
}
|
|
5275
6129
|
};
|
|
5276
6130
|
var iterateOnStream = ({ stream, controller, binary, shouldEncode, encoding, shouldSplit, preserveNewlines }) => {
|
|
5277
|
-
const onStdoutChunk =
|
|
6131
|
+
const onStdoutChunk = on5(stream, "data", {
|
|
5278
6132
|
signal: controller.signal,
|
|
5279
6133
|
highWaterMark: HIGH_WATER_MARK,
|
|
5280
6134
|
// Backward compatibility with older name for this option
|
|
@@ -5319,7 +6173,7 @@ var getGenerators = ({ binary, shouldEncode, encoding, shouldSplit, preserveNewl
|
|
|
5319
6173
|
getSplitLinesGenerator(binary, preserveNewlines, !shouldSplit, {})
|
|
5320
6174
|
].filter(Boolean);
|
|
5321
6175
|
|
|
5322
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6176
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/io/contents.js
|
|
5323
6177
|
var getStreamOutput = async ({ stream, onStreamEnd, fdNumber, encoding, buffer, maxBuffer, lines, allMixed, stripFinalNewline: stripFinalNewline2, verboseInfo, streamInfo: { fileDescriptors } }) => {
|
|
5324
6178
|
if (shouldLogOutput({
|
|
5325
6179
|
stdioItems: fileDescriptors[fdNumber]?.stdioItems,
|
|
@@ -5394,7 +6248,7 @@ var getBufferedData = async (streamPromise) => {
|
|
|
5394
6248
|
};
|
|
5395
6249
|
var handleBufferedData = ({ bufferedData }) => isArrayBuffer(bufferedData) ? new Uint8Array(bufferedData) : bufferedData;
|
|
5396
6250
|
|
|
5397
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6251
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/resolve/wait-stream.js
|
|
5398
6252
|
import { finished as finished5 } from "node:stream/promises";
|
|
5399
6253
|
var waitForStream = async (stream, fdNumber, streamInfo, { isSameDirection, stopOnExit = false } = {}) => {
|
|
5400
6254
|
const state = handleStdinDestroy(stream, streamInfo);
|
|
@@ -5447,7 +6301,7 @@ var isInputFileDescriptor = ({ fileDescriptors }, fdNumber) => fdNumber !== "all
|
|
|
5447
6301
|
var isStreamAbort = (error) => error?.code === "ERR_STREAM_PREMATURE_CLOSE";
|
|
5448
6302
|
var isStreamEpipe = (error) => error?.code === "EPIPE";
|
|
5449
6303
|
|
|
5450
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6304
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/resolve/stdio.js
|
|
5451
6305
|
var waitForStdioStreams = ({ subprocess, encoding, buffer, maxBuffer, lines, stripFinalNewline: stripFinalNewline2, verboseInfo, streamInfo }) => subprocess.stdio.map((stream, fdNumber) => waitForSubprocessStream({
|
|
5452
6306
|
stream,
|
|
5453
6307
|
fdNumber,
|
|
@@ -5488,7 +6342,7 @@ var waitForSubprocessStream = async ({ stream, fdNumber, encoding, buffer, maxBu
|
|
|
5488
6342
|
return output;
|
|
5489
6343
|
};
|
|
5490
6344
|
|
|
5491
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6345
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/resolve/all-async.js
|
|
5492
6346
|
var makeAllStream = ({ stdout, stderr }, { all }) => all && (stdout || stderr) ? mergeStreams([stdout, stderr].filter(Boolean)) : void 0;
|
|
5493
6347
|
var waitForAllStream = ({ subprocess, encoding, buffer, maxBuffer, lines, stripFinalNewline: stripFinalNewline2, verboseInfo, streamInfo }) => waitForSubprocessStream({
|
|
5494
6348
|
...getAllStream(subprocess, buffer),
|
|
@@ -5516,11 +6370,69 @@ var getAllStream = ({ stdout, stderr, all }, [, bufferStdout, bufferStderr]) =>
|
|
|
5516
6370
|
};
|
|
5517
6371
|
var getAllMixed = ({ all, stdout, stderr }) => all && stdout && stderr && stdout.readableObjectMode !== stderr.readableObjectMode;
|
|
5518
6372
|
|
|
5519
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5520
|
-
import { once as
|
|
6373
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/resolve/wait-subprocess.js
|
|
6374
|
+
import { once as once8 } from "node:events";
|
|
6375
|
+
|
|
6376
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/verbose/ipc.js
|
|
6377
|
+
var shouldLogIpc = ({ verbose }) => verbose.at(-1) === "full";
|
|
6378
|
+
var logIpcOutput = (message, { verboseId }) => {
|
|
6379
|
+
verboseLog(serializeLogMessage(message), verboseId, "ipc");
|
|
6380
|
+
};
|
|
6381
|
+
|
|
6382
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/ipc/buffer-messages.js
|
|
6383
|
+
var waitForIpcOutput = async ({
|
|
6384
|
+
subprocess,
|
|
6385
|
+
buffer: bufferArray,
|
|
6386
|
+
maxBuffer: maxBufferArray,
|
|
6387
|
+
ipc,
|
|
6388
|
+
ipcOutput,
|
|
6389
|
+
verboseInfo
|
|
6390
|
+
}) => {
|
|
6391
|
+
if (!ipc) {
|
|
6392
|
+
return ipcOutput;
|
|
6393
|
+
}
|
|
6394
|
+
const isVerbose2 = shouldLogIpc(verboseInfo);
|
|
6395
|
+
const buffer = bufferArray.at(-1);
|
|
6396
|
+
const maxBuffer = maxBufferArray.at(-1);
|
|
6397
|
+
for await (const message of loopOnMessages({
|
|
6398
|
+
anyProcess: subprocess,
|
|
6399
|
+
channel: subprocess.channel,
|
|
6400
|
+
isSubprocess: false,
|
|
6401
|
+
ipc,
|
|
6402
|
+
shouldAwait: false,
|
|
6403
|
+
reference: true
|
|
6404
|
+
})) {
|
|
6405
|
+
if (buffer) {
|
|
6406
|
+
checkIpcMaxBuffer(subprocess, ipcOutput, maxBuffer);
|
|
6407
|
+
ipcOutput.push(message);
|
|
6408
|
+
}
|
|
6409
|
+
if (isVerbose2) {
|
|
6410
|
+
logIpcOutput(message, verboseInfo);
|
|
6411
|
+
}
|
|
6412
|
+
}
|
|
6413
|
+
return ipcOutput;
|
|
6414
|
+
};
|
|
6415
|
+
var getBufferedIpcOutput = async (ipcOutputPromise, ipcOutput) => {
|
|
6416
|
+
await Promise.allSettled([ipcOutputPromise]);
|
|
6417
|
+
return ipcOutput;
|
|
6418
|
+
};
|
|
6419
|
+
|
|
6420
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/resolve/wait-subprocess.js
|
|
5521
6421
|
var waitForSubprocessResult = async ({
|
|
5522
6422
|
subprocess,
|
|
5523
|
-
options: {
|
|
6423
|
+
options: {
|
|
6424
|
+
encoding,
|
|
6425
|
+
buffer,
|
|
6426
|
+
maxBuffer,
|
|
6427
|
+
lines,
|
|
6428
|
+
timeoutDuration: timeout,
|
|
6429
|
+
cancelSignal,
|
|
6430
|
+
gracefulCancel,
|
|
6431
|
+
forceKillAfterDelay,
|
|
6432
|
+
stripFinalNewline: stripFinalNewline2,
|
|
6433
|
+
ipc,
|
|
6434
|
+
ipcInput
|
|
6435
|
+
},
|
|
5524
6436
|
context,
|
|
5525
6437
|
verboseInfo,
|
|
5526
6438
|
fileDescriptors,
|
|
@@ -5528,7 +6440,7 @@ var waitForSubprocessResult = async ({
|
|
|
5528
6440
|
onInternalError,
|
|
5529
6441
|
controller
|
|
5530
6442
|
}) => {
|
|
5531
|
-
const exitPromise = waitForExit(subprocess);
|
|
6443
|
+
const exitPromise = waitForExit(subprocess, context);
|
|
5532
6444
|
const streamInfo = {
|
|
5533
6445
|
originalStreams,
|
|
5534
6446
|
fileDescriptors,
|
|
@@ -5556,6 +6468,15 @@ var waitForSubprocessResult = async ({
|
|
|
5556
6468
|
verboseInfo,
|
|
5557
6469
|
streamInfo
|
|
5558
6470
|
});
|
|
6471
|
+
const ipcOutput = [];
|
|
6472
|
+
const ipcOutputPromise = waitForIpcOutput({
|
|
6473
|
+
subprocess,
|
|
6474
|
+
buffer,
|
|
6475
|
+
maxBuffer,
|
|
6476
|
+
ipc,
|
|
6477
|
+
ipcOutput,
|
|
6478
|
+
verboseInfo
|
|
6479
|
+
});
|
|
5559
6480
|
const originalPromises = waitForOriginalStreams(originalStreams, subprocess, streamInfo);
|
|
5560
6481
|
const customStreamsEndPromises = waitForCustomStreamsEnd(fileDescriptors, streamInfo);
|
|
5561
6482
|
try {
|
|
@@ -5565,19 +6486,38 @@ var waitForSubprocessResult = async ({
|
|
|
5565
6486
|
waitForSuccessfulExit(exitPromise),
|
|
5566
6487
|
Promise.all(stdioPromises),
|
|
5567
6488
|
allPromise,
|
|
6489
|
+
ipcOutputPromise,
|
|
6490
|
+
sendIpcInput(subprocess, ipcInput),
|
|
5568
6491
|
...originalPromises,
|
|
5569
6492
|
...customStreamsEndPromises
|
|
5570
6493
|
]),
|
|
5571
6494
|
onInternalError,
|
|
5572
6495
|
throwOnSubprocessError(subprocess, controller),
|
|
5573
|
-
...throwOnTimeout(subprocess, timeout, context, controller)
|
|
6496
|
+
...throwOnTimeout(subprocess, timeout, context, controller),
|
|
6497
|
+
...throwOnCancel({
|
|
6498
|
+
subprocess,
|
|
6499
|
+
cancelSignal,
|
|
6500
|
+
gracefulCancel,
|
|
6501
|
+
context,
|
|
6502
|
+
controller
|
|
6503
|
+
}),
|
|
6504
|
+
...throwOnGracefulCancel({
|
|
6505
|
+
subprocess,
|
|
6506
|
+
cancelSignal,
|
|
6507
|
+
gracefulCancel,
|
|
6508
|
+
forceKillAfterDelay,
|
|
6509
|
+
context,
|
|
6510
|
+
controller
|
|
6511
|
+
})
|
|
5574
6512
|
]);
|
|
5575
6513
|
} catch (error) {
|
|
6514
|
+
context.terminationReason ??= "other";
|
|
5576
6515
|
return Promise.all([
|
|
5577
6516
|
{ error },
|
|
5578
6517
|
exitPromise,
|
|
5579
6518
|
Promise.all(stdioPromises.map((stdioPromise) => getBufferedData(stdioPromise))),
|
|
5580
6519
|
getBufferedData(allPromise),
|
|
6520
|
+
getBufferedIpcOutput(ipcOutputPromise, ipcOutput),
|
|
5581
6521
|
Promise.allSettled(originalPromises),
|
|
5582
6522
|
Promise.allSettled(customStreamsEndPromises)
|
|
5583
6523
|
]);
|
|
@@ -5589,20 +6529,11 @@ var waitForCustomStreamsEnd = (fileDescriptors, streamInfo) => fileDescriptors.f
|
|
|
5589
6529
|
stopOnExit: type === "native"
|
|
5590
6530
|
})));
|
|
5591
6531
|
var throwOnSubprocessError = async (subprocess, { signal }) => {
|
|
5592
|
-
const [error] = await
|
|
6532
|
+
const [error] = await once8(subprocess, "error", { signal });
|
|
5593
6533
|
throw error;
|
|
5594
6534
|
};
|
|
5595
6535
|
|
|
5596
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
5597
|
-
var createDeferred = () => {
|
|
5598
|
-
const methods = {};
|
|
5599
|
-
const promise = new Promise((resolve3, reject) => {
|
|
5600
|
-
Object.assign(methods, { resolve: resolve3, reject });
|
|
5601
|
-
});
|
|
5602
|
-
return Object.assign(promise, methods);
|
|
5603
|
-
};
|
|
5604
|
-
|
|
5605
|
-
// ../../node_modules/.pnpm/execa@9.1.0/node_modules/execa/lib/convert/concurrent.js
|
|
6536
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/convert/concurrent.js
|
|
5606
6537
|
var initializeConcurrentStreams = () => ({
|
|
5607
6538
|
readableDestroy: /* @__PURE__ */ new WeakMap(),
|
|
5608
6539
|
writableFinal: /* @__PURE__ */ new WeakMap(),
|
|
@@ -5628,11 +6559,11 @@ var waitForConcurrentStreams = async ({ resolve: resolve3, promises }, subproces
|
|
|
5628
6559
|
return !isSubprocessExit;
|
|
5629
6560
|
};
|
|
5630
6561
|
|
|
5631
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6562
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/convert/readable.js
|
|
5632
6563
|
import { Readable as Readable3 } from "node:stream";
|
|
5633
6564
|
import { callbackify as callbackify2 } from "node:util";
|
|
5634
6565
|
|
|
5635
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6566
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/convert/shared.js
|
|
5636
6567
|
import { finished as finished6 } from "node:stream/promises";
|
|
5637
6568
|
var safeWaitForSubprocessStdin = async (subprocessStdin) => {
|
|
5638
6569
|
if (subprocessStdin === void 0) {
|
|
@@ -5672,7 +6603,7 @@ var destroyOtherStream = (stream, isOpen, error) => {
|
|
|
5672
6603
|
}
|
|
5673
6604
|
};
|
|
5674
6605
|
|
|
5675
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6606
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/convert/readable.js
|
|
5676
6607
|
var createReadable = ({ subprocess, concurrentStreams, encoding }, { from, binary: binaryOption = true, preserveNewlines = true } = {}) => {
|
|
5677
6608
|
const binary = binaryOption || BINARY_ENCODINGS.has(encoding);
|
|
5678
6609
|
const { subprocessStdout, waitReadableDestroy } = getSubprocessStdout(subprocess, from, concurrentStreams);
|
|
@@ -5757,7 +6688,7 @@ var destroyOtherReadable = (stream, error) => {
|
|
|
5757
6688
|
destroyOtherStream(stream, stream.readable, error);
|
|
5758
6689
|
};
|
|
5759
6690
|
|
|
5760
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6691
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/convert/writable.js
|
|
5761
6692
|
import { Writable as Writable3 } from "node:stream";
|
|
5762
6693
|
import { callbackify as callbackify3 } from "node:util";
|
|
5763
6694
|
var createWritable = ({ subprocess, concurrentStreams }, { to } = {}) => {
|
|
@@ -5823,7 +6754,7 @@ var destroyOtherWritable = (stream, error) => {
|
|
|
5823
6754
|
destroyOtherStream(stream, stream.writable, error);
|
|
5824
6755
|
};
|
|
5825
6756
|
|
|
5826
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6757
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/convert/duplex.js
|
|
5827
6758
|
import { Duplex as Duplex3 } from "node:stream";
|
|
5828
6759
|
import { callbackify as callbackify4 } from "node:util";
|
|
5829
6760
|
var createDuplex = ({ subprocess, concurrentStreams, encoding }, { from, to, binary: binaryOption = true, preserveNewlines = true } = {}) => {
|
|
@@ -5877,7 +6808,7 @@ var onDuplexDestroy = async ({ subprocessStdout, subprocessStdin, subprocess, wa
|
|
|
5877
6808
|
]);
|
|
5878
6809
|
};
|
|
5879
6810
|
|
|
5880
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6811
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/convert/iterable.js
|
|
5881
6812
|
var createIterable = (subprocess, encoding, {
|
|
5882
6813
|
from,
|
|
5883
6814
|
binary: binaryOption = false,
|
|
@@ -5906,7 +6837,7 @@ var iterateOnStdoutData = async function* (onStdoutData, subprocessStdout, subpr
|
|
|
5906
6837
|
}
|
|
5907
6838
|
};
|
|
5908
6839
|
|
|
5909
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6840
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/convert/add.js
|
|
5910
6841
|
var addConvertedStreams = (subprocess, { encoding }) => {
|
|
5911
6842
|
const concurrentStreams = initializeConcurrentStreams();
|
|
5912
6843
|
subprocess.readable = createReadable.bind(void 0, { subprocess, concurrentStreams, encoding });
|
|
@@ -5916,7 +6847,7 @@ var addConvertedStreams = (subprocess, { encoding }) => {
|
|
|
5916
6847
|
subprocess[Symbol.asyncIterator] = createIterable.bind(void 0, subprocess, encoding, {});
|
|
5917
6848
|
};
|
|
5918
6849
|
|
|
5919
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6850
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/promise.js
|
|
5920
6851
|
var mergePromise = (subprocess, promise) => {
|
|
5921
6852
|
for (const [property, descriptor] of descriptors) {
|
|
5922
6853
|
const value = descriptor.value.bind(promise);
|
|
@@ -5930,7 +6861,7 @@ var descriptors = ["then", "catch", "finally"].map((property) => [
|
|
|
5930
6861
|
Reflect.getOwnPropertyDescriptor(nativePromisePrototype, property)
|
|
5931
6862
|
]);
|
|
5932
6863
|
|
|
5933
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
6864
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/main-async.js
|
|
5934
6865
|
var execaCoreAsync = (rawFile, rawArguments, rawOptions, createNested) => {
|
|
5935
6866
|
const { file, commandArguments, command, escapedCommand, startTime, verboseInfo, options, fileDescriptors } = handleAsyncArguments(rawFile, rawArguments, rawOptions);
|
|
5936
6867
|
const { subprocess, promise } = spawnSubprocessAsync({
|
|
@@ -5974,11 +6905,11 @@ var handleAsyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
|
5974
6905
|
throw error;
|
|
5975
6906
|
}
|
|
5976
6907
|
};
|
|
5977
|
-
var handleAsyncOptions = ({ timeout, signal,
|
|
6908
|
+
var handleAsyncOptions = ({ timeout, signal, ...options }) => {
|
|
5978
6909
|
if (signal !== void 0) {
|
|
5979
6910
|
throw new TypeError('The "signal" option has been renamed to "cancelSignal" instead.');
|
|
5980
6911
|
}
|
|
5981
|
-
return { ...options, timeoutDuration: timeout
|
|
6912
|
+
return { ...options, timeoutDuration: timeout };
|
|
5982
6913
|
};
|
|
5983
6914
|
var spawnSubprocessAsync = ({ file, commandArguments, options, startTime, verboseInfo, command, escapedCommand, fileDescriptors }) => {
|
|
5984
6915
|
let subprocess;
|
|
@@ -6000,15 +6931,18 @@ var spawnSubprocessAsync = ({ file, commandArguments, options, startTime, verbos
|
|
|
6000
6931
|
const originalStreams = [...subprocess.stdio];
|
|
6001
6932
|
pipeOutputAsync(subprocess, fileDescriptors, controller);
|
|
6002
6933
|
cleanupOnExit(subprocess, options, controller);
|
|
6934
|
+
const context = {};
|
|
6003
6935
|
const onInternalError = createDeferred();
|
|
6004
6936
|
subprocess.kill = subprocessKill.bind(void 0, {
|
|
6005
6937
|
kill: subprocess.kill.bind(subprocess),
|
|
6006
6938
|
options,
|
|
6007
6939
|
onInternalError,
|
|
6940
|
+
context,
|
|
6008
6941
|
controller
|
|
6009
6942
|
});
|
|
6010
6943
|
subprocess.all = makeAllStream(subprocess, options);
|
|
6011
6944
|
addConvertedStreams(subprocess, options);
|
|
6945
|
+
addIpcMethods(subprocess, options);
|
|
6012
6946
|
const promise = handlePromise({
|
|
6013
6947
|
subprocess,
|
|
6014
6948
|
options,
|
|
@@ -6018,14 +6952,20 @@ var spawnSubprocessAsync = ({ file, commandArguments, options, startTime, verbos
|
|
|
6018
6952
|
originalStreams,
|
|
6019
6953
|
command,
|
|
6020
6954
|
escapedCommand,
|
|
6955
|
+
context,
|
|
6021
6956
|
onInternalError,
|
|
6022
6957
|
controller
|
|
6023
6958
|
});
|
|
6024
6959
|
return { subprocess, promise };
|
|
6025
6960
|
};
|
|
6026
|
-
var handlePromise = async ({ subprocess, options, startTime, verboseInfo, fileDescriptors, originalStreams, command, escapedCommand, onInternalError, controller }) => {
|
|
6027
|
-
const
|
|
6028
|
-
|
|
6961
|
+
var handlePromise = async ({ subprocess, options, startTime, verboseInfo, fileDescriptors, originalStreams, command, escapedCommand, context, onInternalError, controller }) => {
|
|
6962
|
+
const [
|
|
6963
|
+
errorInfo,
|
|
6964
|
+
[exitCode, signal],
|
|
6965
|
+
stdioResults,
|
|
6966
|
+
allResult,
|
|
6967
|
+
ipcOutput
|
|
6968
|
+
] = await waitForSubprocessResult({
|
|
6029
6969
|
subprocess,
|
|
6030
6970
|
options,
|
|
6031
6971
|
context,
|
|
@@ -6045,6 +6985,7 @@ var handlePromise = async ({ subprocess, options, startTime, verboseInfo, fileDe
|
|
|
6045
6985
|
signal,
|
|
6046
6986
|
stdio,
|
|
6047
6987
|
all,
|
|
6988
|
+
ipcOutput,
|
|
6048
6989
|
context,
|
|
6049
6990
|
options,
|
|
6050
6991
|
command,
|
|
@@ -6053,17 +6994,20 @@ var handlePromise = async ({ subprocess, options, startTime, verboseInfo, fileDe
|
|
|
6053
6994
|
});
|
|
6054
6995
|
return handleResult(result, verboseInfo, options);
|
|
6055
6996
|
};
|
|
6056
|
-
var getAsyncResult = ({ errorInfo, exitCode, signal, stdio, all, context, options, command, escapedCommand, startTime }) => "error" in errorInfo ? makeError({
|
|
6997
|
+
var getAsyncResult = ({ errorInfo, exitCode, signal, stdio, all, ipcOutput, context, options, command, escapedCommand, startTime }) => "error" in errorInfo ? makeError({
|
|
6057
6998
|
error: errorInfo.error,
|
|
6058
6999
|
command,
|
|
6059
7000
|
escapedCommand,
|
|
6060
|
-
timedOut: context.
|
|
6061
|
-
isCanceled:
|
|
7001
|
+
timedOut: context.terminationReason === "timeout",
|
|
7002
|
+
isCanceled: context.terminationReason === "cancel" || context.terminationReason === "gracefulCancel",
|
|
7003
|
+
isGracefullyCanceled: context.terminationReason === "gracefulCancel",
|
|
6062
7004
|
isMaxBuffer: errorInfo.error instanceof MaxBufferError,
|
|
7005
|
+
isForcefullyTerminated: context.isForcefullyTerminated,
|
|
6063
7006
|
exitCode,
|
|
6064
7007
|
signal,
|
|
6065
7008
|
stdio,
|
|
6066
7009
|
all,
|
|
7010
|
+
ipcOutput,
|
|
6067
7011
|
options,
|
|
6068
7012
|
startTime,
|
|
6069
7013
|
isSync: false
|
|
@@ -6072,11 +7016,12 @@ var getAsyncResult = ({ errorInfo, exitCode, signal, stdio, all, context, option
|
|
|
6072
7016
|
escapedCommand,
|
|
6073
7017
|
stdio,
|
|
6074
7018
|
all,
|
|
7019
|
+
ipcOutput,
|
|
6075
7020
|
options,
|
|
6076
7021
|
startTime
|
|
6077
7022
|
});
|
|
6078
7023
|
|
|
6079
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
7024
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/bind.js
|
|
6080
7025
|
var mergeOptions = (boundOptions, options) => {
|
|
6081
7026
|
const newOptions = Object.fromEntries(
|
|
6082
7027
|
Object.entries(options).map(([optionName, optionValue]) => [
|
|
@@ -6094,7 +7039,7 @@ var mergeOption = (optionName, boundOptionValue, optionValue) => {
|
|
|
6094
7039
|
};
|
|
6095
7040
|
var DEEP_OPTIONS = /* @__PURE__ */ new Set(["env", ...FD_SPECIFIC_OPTIONS]);
|
|
6096
7041
|
|
|
6097
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
7042
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/create.js
|
|
6098
7043
|
var createExeca = (mapArguments, boundOptions, deepOptions, setBoundExeca) => {
|
|
6099
7044
|
const createNested = (mapArguments2, boundOptions2, setBoundExeca2) => createExeca(mapArguments2, boundOptions2, deepOptions, setBoundExeca2);
|
|
6100
7045
|
const boundExeca = (...execaArguments) => callBoundExeca({
|
|
@@ -6140,15 +7085,26 @@ var parseArguments = ({ mapArguments, firstArgument, nextArguments, deepOptions,
|
|
|
6140
7085
|
};
|
|
6141
7086
|
};
|
|
6142
7087
|
|
|
6143
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
7088
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/command.js
|
|
6144
7089
|
var mapCommandAsync = ({ file, commandArguments }) => parseCommand(file, commandArguments);
|
|
6145
7090
|
var mapCommandSync = ({ file, commandArguments }) => ({ ...parseCommand(file, commandArguments), isSync: true });
|
|
6146
7091
|
var parseCommand = (command, unusedArguments) => {
|
|
6147
7092
|
if (unusedArguments.length > 0) {
|
|
6148
7093
|
throw new TypeError(`The command and its arguments must be passed as a single string: ${command} ${unusedArguments}.`);
|
|
6149
7094
|
}
|
|
7095
|
+
const [file, ...commandArguments] = parseCommandString(command);
|
|
7096
|
+
return { file, commandArguments };
|
|
7097
|
+
};
|
|
7098
|
+
var parseCommandString = (command) => {
|
|
7099
|
+
if (typeof command !== "string") {
|
|
7100
|
+
throw new TypeError(`The command must be a string: ${String(command)}.`);
|
|
7101
|
+
}
|
|
7102
|
+
const trimmedCommand = command.trim();
|
|
7103
|
+
if (trimmedCommand === "") {
|
|
7104
|
+
return [];
|
|
7105
|
+
}
|
|
6150
7106
|
const tokens = [];
|
|
6151
|
-
for (const token of
|
|
7107
|
+
for (const token of trimmedCommand.split(SPACES_REGEXP)) {
|
|
6152
7108
|
const previousToken = tokens.at(-1);
|
|
6153
7109
|
if (previousToken && previousToken.endsWith("\\")) {
|
|
6154
7110
|
tokens[tokens.length - 1] = `${previousToken.slice(0, -1)} ${token}`;
|
|
@@ -6156,12 +7112,11 @@ var parseCommand = (command, unusedArguments) => {
|
|
|
6156
7112
|
tokens.push(token);
|
|
6157
7113
|
}
|
|
6158
7114
|
}
|
|
6159
|
-
|
|
6160
|
-
return { file, commandArguments };
|
|
7115
|
+
return tokens;
|
|
6161
7116
|
};
|
|
6162
7117
|
var SPACES_REGEXP = / +/g;
|
|
6163
7118
|
|
|
6164
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
7119
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/lib/methods/script.js
|
|
6165
7120
|
var setScriptSync = (boundExeca, createNested, boundOptions) => {
|
|
6166
7121
|
boundExeca.sync = createNested(mapScriptSync, boundOptions);
|
|
6167
7122
|
boundExeca.s = boundExeca.sync;
|
|
@@ -6172,13 +7127,19 @@ var getScriptOptions = (options) => ({ options: { ...getScriptStdinOption(option
|
|
|
6172
7127
|
var getScriptStdinOption = ({ input, inputFile, stdio }) => input === void 0 && inputFile === void 0 && stdio === void 0 ? { stdin: "inherit" } : {};
|
|
6173
7128
|
var deepScriptOptions = { preferLocal: true };
|
|
6174
7129
|
|
|
6175
|
-
// ../../node_modules/.pnpm/execa@9.
|
|
7130
|
+
// ../../node_modules/.pnpm/execa@9.2.0/node_modules/execa/index.js
|
|
6176
7131
|
var execa = createExeca(() => ({}));
|
|
6177
7132
|
var execaSync = createExeca(() => ({ isSync: true }));
|
|
6178
7133
|
var execaCommand = createExeca(mapCommandAsync);
|
|
6179
7134
|
var execaCommandSync = createExeca(mapCommandSync);
|
|
6180
7135
|
var execaNode = createExeca(mapNode);
|
|
6181
7136
|
var $ = createExeca(mapScriptAsync, {}, deepScriptOptions, setScriptSync);
|
|
7137
|
+
var {
|
|
7138
|
+
sendMessage: sendMessage2,
|
|
7139
|
+
getOneMessage: getOneMessage2,
|
|
7140
|
+
getEachMessage: getEachMessage2,
|
|
7141
|
+
getCancelSignal: getCancelSignal2
|
|
7142
|
+
} = getIpcExport();
|
|
6182
7143
|
export {
|
|
6183
7144
|
$,
|
|
6184
7145
|
ExecaError,
|
|
@@ -6187,5 +7148,10 @@ export {
|
|
|
6187
7148
|
execaCommand,
|
|
6188
7149
|
execaCommandSync,
|
|
6189
7150
|
execaNode,
|
|
6190
|
-
execaSync
|
|
7151
|
+
execaSync,
|
|
7152
|
+
getCancelSignal2 as getCancelSignal,
|
|
7153
|
+
getEachMessage2 as getEachMessage,
|
|
7154
|
+
getOneMessage2 as getOneMessage,
|
|
7155
|
+
parseCommandString,
|
|
7156
|
+
sendMessage2 as sendMessage
|
|
6191
7157
|
};
|