@h3ravel/http 11.3.2 → 11.3.4
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/find-up-simple-CPevfdC2.cjs +1 -2
- package/dist/find-up-simple-DLa63O5_.js +1 -2
- package/dist/index.cjs +171 -269
- package/dist/index.d.cts +5 -4
- package/dist/index.d.ts +5 -4
- package/dist/index.js +169 -268
- package/package.json +10 -4
- package/dist/find-up-simple-CPevfdC2.cjs.map +0 -1
- package/dist/find-up-simple-DLa63O5_.js.map +0 -1
- package/dist/index.cjs.map +0 -1
- package/dist/index.js.map +0 -1
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const require_chunk = require('./chunk-BncF-t-1.cjs');
|
|
2
|
-
let
|
|
3
|
-
|
|
2
|
+
let __h3ravel_musket = require("@h3ravel/musket");
|
|
3
|
+
__h3ravel_musket = require_chunk.__toESM(__h3ravel_musket);
|
|
4
4
|
let __h3ravel_shared = require("@h3ravel/shared");
|
|
5
5
|
__h3ravel_shared = require_chunk.__toESM(__h3ravel_shared);
|
|
6
6
|
let node_url = require("node:url");
|
|
@@ -35,6 +35,8 @@ let node_buffer = require("node:buffer");
|
|
|
35
35
|
node_buffer = require_chunk.__toESM(node_buffer);
|
|
36
36
|
let h3 = require("h3");
|
|
37
37
|
h3 = require_chunk.__toESM(h3);
|
|
38
|
+
let __h3ravel_core = require("@h3ravel/core");
|
|
39
|
+
__h3ravel_core = require_chunk.__toESM(__h3ravel_core);
|
|
38
40
|
let __h3ravel_support = require("@h3ravel/support");
|
|
39
41
|
__h3ravel_support = require_chunk.__toESM(__h3ravel_support);
|
|
40
42
|
|
|
@@ -140,8 +142,7 @@ const parseTemplate = ({ templates, expressions, tokens, index, template }) => {
|
|
|
140
142
|
const newTokens = concatTokens(tokens, nextTokens, leadingWhitespaces);
|
|
141
143
|
if (index === expressions.length) return newTokens;
|
|
142
144
|
const expression = expressions[index];
|
|
143
|
-
|
|
144
|
-
return concatTokens(newTokens, expressionTokens, trailingWhitespaces);
|
|
145
|
+
return concatTokens(newTokens, Array.isArray(expression) ? expression.map((expression$1) => parseExpression(expression$1)) : [parseExpression(expression)], trailingWhitespaces);
|
|
145
146
|
};
|
|
146
147
|
const splitByWhitespaces = (template, rawTemplate) => {
|
|
147
148
|
if (rawTemplate.length === 0) return {
|
|
@@ -228,8 +229,7 @@ const normalizeFdSpecificOptions = (options) => {
|
|
|
228
229
|
};
|
|
229
230
|
const normalizeFdSpecificOption = (options, optionName) => {
|
|
230
231
|
const optionBaseArray = Array.from({ length: getStdioLength(options) + 1 });
|
|
231
|
-
|
|
232
|
-
return addDefaultValue$1(optionArray, optionName);
|
|
232
|
+
return addDefaultValue$1(normalizeFdSpecificValue(options[optionName], optionBaseArray, optionName), optionName);
|
|
233
233
|
};
|
|
234
234
|
const getStdioLength = ({ stdio }) => Array.isArray(stdio) ? Math.max(stdio.length, STANDARD_STREAMS_ALIASES.length) : STANDARD_STREAMS_ALIASES.length;
|
|
235
235
|
const normalizeFdSpecificValue = (optionValue, optionArray, optionName) => isPlainObject(optionValue) ? normalizeOptionObject(optionValue, optionArray, optionName) : optionArray.fill(optionValue);
|
|
@@ -296,11 +296,9 @@ const VERBOSE_VALUES = [
|
|
|
296
296
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/arguments/escape.js
|
|
297
297
|
const joinCommand = (filePath, rawArguments) => {
|
|
298
298
|
const fileAndArguments = [filePath, ...rawArguments];
|
|
299
|
-
const command = fileAndArguments.join(" ");
|
|
300
|
-
const escapedCommand = fileAndArguments.map((fileAndArgument) => quoteString(escapeControlCharacters(fileAndArgument))).join(" ");
|
|
301
299
|
return {
|
|
302
|
-
command,
|
|
303
|
-
escapedCommand
|
|
300
|
+
command: fileAndArguments.join(" "),
|
|
301
|
+
escapedCommand: fileAndArguments.map((fileAndArgument) => quoteString(escapeControlCharacters(fileAndArgument))).join(" ")
|
|
304
302
|
};
|
|
305
303
|
};
|
|
306
304
|
const escapeLines = (lines) => (0, node_util.stripVTControlCharacters)(lines).split("\n").map((line) => escapeControlCharacters(line)).join("\n");
|
|
@@ -742,13 +740,11 @@ const appendNewline = (printedLine) => printedLine.endsWith("\n") ? printedLine
|
|
|
742
740
|
//#endregion
|
|
743
741
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/verbose/log.js
|
|
744
742
|
const verboseLog = ({ type, verboseMessage, fdNumber, verboseInfo, result }) => {
|
|
745
|
-
const
|
|
743
|
+
const finalLines = applyVerboseOnLines(getPrintedLines(verboseMessage, getVerboseObject({
|
|
746
744
|
type,
|
|
747
745
|
result,
|
|
748
746
|
verboseInfo
|
|
749
|
-
});
|
|
750
|
-
const printedLines = getPrintedLines(verboseMessage, verboseObject);
|
|
751
|
-
const finalLines = applyVerboseOnLines(printedLines, verboseInfo, fdNumber);
|
|
747
|
+
})), verboseInfo, fdNumber);
|
|
752
748
|
if (finalLines !== "") console.warn(finalLines.slice(0, -1));
|
|
753
749
|
};
|
|
754
750
|
const getVerboseObject = ({ type, result, verboseInfo: { escapedCommand, commandId, rawOptions: { piped = false,...options } } }) => ({
|
|
@@ -771,8 +767,7 @@ const getPrintedLine = (verboseObject) => {
|
|
|
771
767
|
};
|
|
772
768
|
};
|
|
773
769
|
const serializeVerboseMessage = (message) => {
|
|
774
|
-
|
|
775
|
-
return escapeLines(messageString).replaceAll(" ", " ".repeat(TAB_SIZE));
|
|
770
|
+
return escapeLines(typeof message === "string" ? message : (0, node_util.inspect)(message)).replaceAll(" ", " ".repeat(TAB_SIZE));
|
|
776
771
|
};
|
|
777
772
|
const TAB_SIZE = 2;
|
|
778
773
|
|
|
@@ -791,11 +786,10 @@ const logCommand = (escapedCommand, verboseInfo) => {
|
|
|
791
786
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/verbose/info.js
|
|
792
787
|
const getVerboseInfo = (verbose, escapedCommand, rawOptions) => {
|
|
793
788
|
validateVerbose(verbose);
|
|
794
|
-
const commandId = getCommandId(verbose);
|
|
795
789
|
return {
|
|
796
790
|
verbose,
|
|
797
791
|
escapedCommand,
|
|
798
|
-
commandId,
|
|
792
|
+
commandId: getCommandId(verbose),
|
|
799
793
|
rawOptions
|
|
800
794
|
};
|
|
801
795
|
};
|
|
@@ -822,8 +816,7 @@ const getDurationMs = (startTime) => Number(node_process.hrtime.bigint() - start
|
|
|
822
816
|
const handleCommand = (filePath, rawArguments, rawOptions) => {
|
|
823
817
|
const startTime = getStartTime();
|
|
824
818
|
const { command, escapedCommand } = joinCommand(filePath, rawArguments);
|
|
825
|
-
const
|
|
826
|
-
const verboseInfo = getVerboseInfo(verbose, escapedCommand, { ...rawOptions });
|
|
819
|
+
const verboseInfo = getVerboseInfo(normalizeFdSpecificOption(rawOptions, "verbose"), escapedCommand, { ...rawOptions });
|
|
827
820
|
logCommand(escapedCommand, verboseInfo);
|
|
828
821
|
return {
|
|
829
822
|
command,
|
|
@@ -973,8 +966,7 @@ var require_which = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modul
|
|
|
973
966
|
const ppRaw = pathEnv[i$2];
|
|
974
967
|
const pathPart = /^".*"$/.test(ppRaw) ? ppRaw.slice(1, -1) : ppRaw;
|
|
975
968
|
const pCmd = path$15.join(pathPart, cmd);
|
|
976
|
-
|
|
977
|
-
resolve(subStep(p, i$2, 0));
|
|
969
|
+
resolve(subStep(!pathPart && /^\.[\\\/]/.test(cmd) ? cmd.slice(0, 2) + pCmd : pCmd, i$2, 0));
|
|
978
970
|
});
|
|
979
971
|
const subStep = (p, i$2, ii) => new Promise((resolve, reject) => {
|
|
980
972
|
if (ii === pathExt.length) return resolve(step(i$2 + 1));
|
|
@@ -1302,9 +1294,7 @@ const npmRunPathEnv = ({ env: env$1 = node_process.default.env,...options } = {}
|
|
|
1302
1294
|
//#endregion
|
|
1303
1295
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/return/final-error.js
|
|
1304
1296
|
const getFinalError = (originalError, message, isSync) => {
|
|
1305
|
-
|
|
1306
|
-
const options = originalError instanceof DiscardedError ? {} : { cause: originalError };
|
|
1307
|
-
return new ErrorClass(message, options);
|
|
1297
|
+
return new (isSync ? ExecaSyncError : ExecaError)(message, originalError instanceof DiscardedError ? {} : { cause: originalError });
|
|
1308
1298
|
};
|
|
1309
1299
|
var DiscardedError = class extends Error {};
|
|
1310
1300
|
const setErrorName = (ErrorClass, value) => {
|
|
@@ -2042,8 +2032,7 @@ const isConnected = (anyProcess) => {
|
|
|
2042
2032
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/ipc/strict.js
|
|
2043
2033
|
const handleSendStrict = ({ anyProcess, channel, isSubprocess, message, strict }) => {
|
|
2044
2034
|
if (!strict) return message;
|
|
2045
|
-
const
|
|
2046
|
-
const hasListeners = hasMessageListeners(anyProcess, ipcEmitter);
|
|
2035
|
+
const hasListeners = hasMessageListeners(anyProcess, getIpcEmitter(anyProcess, channel, isSubprocess));
|
|
2047
2036
|
return {
|
|
2048
2037
|
id: count++,
|
|
2049
2038
|
type: REQUEST_TYPE,
|
|
@@ -2116,11 +2105,9 @@ const RESPONSE_TYPE = "execa:ipc:response";
|
|
|
2116
2105
|
const startSendMessage = (anyProcess, wrappedMessage, strict) => {
|
|
2117
2106
|
if (!OUTGOING_MESSAGES.has(anyProcess)) OUTGOING_MESSAGES.set(anyProcess, /* @__PURE__ */ new Set());
|
|
2118
2107
|
const outgoingMessages = OUTGOING_MESSAGES.get(anyProcess);
|
|
2119
|
-
const onMessageSent = createDeferred();
|
|
2120
|
-
const id = strict ? wrappedMessage.id : void 0;
|
|
2121
2108
|
const outgoingMessage = {
|
|
2122
|
-
onMessageSent,
|
|
2123
|
-
id
|
|
2109
|
+
onMessageSent: createDeferred(),
|
|
2110
|
+
id: strict ? wrappedMessage.id : void 0
|
|
2124
2111
|
};
|
|
2125
2112
|
outgoingMessages.add(outgoingMessage);
|
|
2126
2113
|
return {
|
|
@@ -2281,8 +2268,7 @@ const throwOnGracefulCancel = ({ subprocess, cancelSignal, gracefulCancel, force
|
|
|
2281
2268
|
})] : [];
|
|
2282
2269
|
const sendOnAbort = async ({ subprocess, cancelSignal, forceKillAfterDelay, context, controller: { signal } }) => {
|
|
2283
2270
|
await onAbortedSignal(cancelSignal, signal);
|
|
2284
|
-
|
|
2285
|
-
await sendAbort(subprocess, reason);
|
|
2271
|
+
await sendAbort(subprocess, getReason(cancelSignal));
|
|
2286
2272
|
killOnTimeout({
|
|
2287
2273
|
kill: subprocess.kill,
|
|
2288
2274
|
forceKillAfterDelay,
|
|
@@ -2456,8 +2442,7 @@ const normalizeOptions = (filePath, rawArguments, rawOptions) => {
|
|
|
2456
2442
|
rawOptions.cwd = normalizeCwd(rawOptions.cwd);
|
|
2457
2443
|
const [processedFile, processedArguments, processedOptions] = handleNodeOption(filePath, rawArguments, rawOptions);
|
|
2458
2444
|
const { command: file, args: commandArguments, options: initialOptions } = import_cross_spawn.default._parse(processedFile, processedArguments, processedOptions);
|
|
2459
|
-
const
|
|
2460
|
-
const options = addDefaultOptions(fdOptions);
|
|
2445
|
+
const options = addDefaultOptions(normalizeFdSpecificOptions(initialOptions));
|
|
2461
2446
|
validateTimeout(options);
|
|
2462
2447
|
validateEncoding(options);
|
|
2463
2448
|
validateIpcInputOption(options);
|
|
@@ -2626,7 +2611,7 @@ const u = Object.create(a, {
|
|
|
2626
2611
|
}
|
|
2627
2612
|
});
|
|
2628
2613
|
function h({ preventCancel: r = !1 } = {}) {
|
|
2629
|
-
const
|
|
2614
|
+
const t = new c(this.getReader(), r), s = Object.create(u);
|
|
2630
2615
|
return s[n] = t, s;
|
|
2631
2616
|
}
|
|
2632
2617
|
|
|
@@ -2675,18 +2660,14 @@ const getStreamContents$1 = async (stream, { init, convertChunk, getSize, trunca
|
|
|
2675
2660
|
const state = init();
|
|
2676
2661
|
state.length = 0;
|
|
2677
2662
|
try {
|
|
2678
|
-
for await (const chunk of asyncIterable) {
|
|
2679
|
-
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2683
|
-
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
addChunk,
|
|
2687
|
-
maxBuffer
|
|
2688
|
-
});
|
|
2689
|
-
}
|
|
2663
|
+
for await (const chunk of asyncIterable) appendChunk({
|
|
2664
|
+
convertedChunk: convertChunk[getChunkType(chunk)](chunk, state),
|
|
2665
|
+
state,
|
|
2666
|
+
getSize,
|
|
2667
|
+
truncateChunk,
|
|
2668
|
+
addChunk,
|
|
2669
|
+
maxBuffer
|
|
2670
|
+
});
|
|
2690
2671
|
appendFinalChunk({
|
|
2691
2672
|
state,
|
|
2692
2673
|
convertChunk,
|
|
@@ -2876,10 +2857,9 @@ const stringMethods = {
|
|
|
2876
2857
|
const handleMaxBuffer = ({ error, stream, readableObjectMode, lines, encoding, fdNumber }) => {
|
|
2877
2858
|
if (!(error instanceof MaxBufferError)) throw error;
|
|
2878
2859
|
if (fdNumber === "all") return error;
|
|
2879
|
-
const unit = getMaxBufferUnit(readableObjectMode, lines, encoding);
|
|
2880
2860
|
error.maxBufferInfo = {
|
|
2881
2861
|
fdNumber,
|
|
2882
|
-
unit
|
|
2862
|
+
unit: getMaxBufferUnit(readableObjectMode, lines, encoding)
|
|
2883
2863
|
};
|
|
2884
2864
|
stream.destroy();
|
|
2885
2865
|
throw error;
|
|
@@ -2949,19 +2929,16 @@ const createMessages = ({ stdio, all, ipcOutput, originalError, signal, signalDe
|
|
|
2949
2929
|
killSignal
|
|
2950
2930
|
});
|
|
2951
2931
|
const originalMessage = getOriginalMessage(originalError, cwd$1);
|
|
2952
|
-
const
|
|
2953
|
-
const shortMessage = `${prefix}: ${escapedCommand}${suffix}`;
|
|
2954
|
-
const messageStdio = all === void 0 ? [stdio[2], stdio[1]] : [all];
|
|
2955
|
-
const message = [
|
|
2956
|
-
shortMessage,
|
|
2957
|
-
...messageStdio,
|
|
2958
|
-
...stdio.slice(3),
|
|
2959
|
-
ipcOutput.map((ipcMessage) => serializeIpcMessage(ipcMessage)).join("\n")
|
|
2960
|
-
].map((messagePart) => escapeLines(stripFinalNewline(serializeMessagePart(messagePart)))).filter(Boolean).join("\n\n");
|
|
2932
|
+
const shortMessage = `${prefix}: ${escapedCommand}${originalMessage === void 0 ? "" : `\n${originalMessage}`}`;
|
|
2961
2933
|
return {
|
|
2962
2934
|
originalMessage,
|
|
2963
2935
|
shortMessage,
|
|
2964
|
-
message
|
|
2936
|
+
message: [
|
|
2937
|
+
shortMessage,
|
|
2938
|
+
...all === void 0 ? [stdio[2], stdio[1]] : [all],
|
|
2939
|
+
...stdio.slice(3),
|
|
2940
|
+
ipcOutput.map((ipcMessage) => serializeIpcMessage(ipcMessage)).join("\n")
|
|
2941
|
+
].map((messagePart) => escapeLines(stripFinalNewline(serializeMessagePart(messagePart)))).filter(Boolean).join("\n\n")
|
|
2965
2942
|
};
|
|
2966
2943
|
};
|
|
2967
2944
|
const getErrorPrefix = ({ originalError, timedOut, timeout, isMaxBuffer, maxBuffer, errorCode, signal, signalDescription, exitCode, isCanceled, isGracefullyCanceled, isForcefullyTerminated, forceKillAfterDelay, killSignal }) => {
|
|
@@ -2982,8 +2959,7 @@ const getErrorPrefix = ({ originalError, timedOut, timeout, isMaxBuffer, maxBuff
|
|
|
2982
2959
|
const getForcefulSuffix = (isForcefullyTerminated, forceKillAfterDelay) => isForcefullyTerminated ? ` and was forcefully terminated after ${forceKillAfterDelay} milliseconds` : "";
|
|
2983
2960
|
const getOriginalMessage = (originalError, cwd$1) => {
|
|
2984
2961
|
if (originalError instanceof DiscardedError) return;
|
|
2985
|
-
const
|
|
2986
|
-
const escapedOriginalMessage = escapeLines(fixCwdError(originalMessage, cwd$1));
|
|
2962
|
+
const escapedOriginalMessage = escapeLines(fixCwdError(isExecaError(originalError) ? originalError.originalMessage : String(originalError?.message ?? originalError), cwd$1));
|
|
2987
2963
|
return escapedOriginalMessage === "" ? void 0 : escapedOriginalMessage;
|
|
2988
2964
|
};
|
|
2989
2965
|
const serializeIpcMessage = (ipcMessage) => typeof ipcMessage === "string" ? ipcMessage : (0, node_util.inspect)(ipcMessage);
|
|
@@ -3105,11 +3081,10 @@ const omitUndefinedProperties = (result) => Object.fromEntries(Object.entries(re
|
|
|
3105
3081
|
const normalizeExitPayload = (rawExitCode, rawSignal) => {
|
|
3106
3082
|
const exitCode = rawExitCode === null ? void 0 : rawExitCode;
|
|
3107
3083
|
const signal = rawSignal === null ? void 0 : rawSignal;
|
|
3108
|
-
const signalDescription = signal === void 0 ? void 0 : getSignalDescription(rawSignal);
|
|
3109
3084
|
return {
|
|
3110
3085
|
exitCode,
|
|
3111
3086
|
signal,
|
|
3112
|
-
signalDescription
|
|
3087
|
+
signalDescription: signal === void 0 ? void 0 : getSignalDescription(rawSignal)
|
|
3113
3088
|
};
|
|
3114
3089
|
};
|
|
3115
3090
|
|
|
@@ -3215,9 +3190,7 @@ function prettyMilliseconds(milliseconds, options) {
|
|
|
3215
3190
|
add(Number.parseFloat(millisecondsString), "millisecond", "ms", millisecondsString);
|
|
3216
3191
|
}
|
|
3217
3192
|
} else {
|
|
3218
|
-
const
|
|
3219
|
-
const secondsDecimalDigits = typeof options.secondsDecimalDigits === "number" ? options.secondsDecimalDigits : 1;
|
|
3220
|
-
const secondsFixed = floorDecimals(seconds, secondsDecimalDigits);
|
|
3193
|
+
const secondsFixed = floorDecimals((isBigInt ? Number(milliseconds % ONE_DAY_IN_MILLISECONDS) : milliseconds) / 1e3 % 60, typeof options.secondsDecimalDigits === "number" ? options.secondsDecimalDigits : 1);
|
|
3221
3194
|
const secondsString = options.keepDecimalsOnWholeSeconds ? secondsFixed : secondsFixed.replace(/\.0+$/, "");
|
|
3222
3195
|
add(Number.parseFloat(secondsString), "second", "s", secondsString);
|
|
3223
3196
|
}
|
|
@@ -3246,10 +3219,9 @@ const logResult = (result, verboseInfo) => {
|
|
|
3246
3219
|
logDuration(result, verboseInfo);
|
|
3247
3220
|
};
|
|
3248
3221
|
const logDuration = (result, verboseInfo) => {
|
|
3249
|
-
const verboseMessage = `(done in ${prettyMilliseconds(result.durationMs)})`;
|
|
3250
3222
|
verboseLog({
|
|
3251
3223
|
type: "duration",
|
|
3252
|
-
verboseMessage
|
|
3224
|
+
verboseMessage: `(done in ${prettyMilliseconds(result.durationMs)})`,
|
|
3253
3225
|
verboseInfo,
|
|
3254
3226
|
result
|
|
3255
3227
|
});
|
|
@@ -3383,10 +3355,9 @@ const getOutputObjectModes = (objectMode, index, newTransforms) => {
|
|
|
3383
3355
|
};
|
|
3384
3356
|
const getInputObjectModes = (objectMode, index, newTransforms) => {
|
|
3385
3357
|
const writableObjectMode = index === 0 ? objectMode === true : newTransforms[index - 1].value.readableObjectMode;
|
|
3386
|
-
const readableObjectMode = index !== newTransforms.length - 1 && (objectMode ?? writableObjectMode);
|
|
3387
3358
|
return {
|
|
3388
3359
|
writableObjectMode,
|
|
3389
|
-
readableObjectMode
|
|
3360
|
+
readableObjectMode: index !== newTransforms.length - 1 && (objectMode ?? writableObjectMode)
|
|
3390
3361
|
};
|
|
3391
3362
|
};
|
|
3392
3363
|
const getFdObjectMode = (stdioItems, direction) => {
|
|
@@ -3695,8 +3666,7 @@ const validateDuplicateStreamSync = ({ otherStdioItems, type, value, optionName,
|
|
|
3695
3666
|
const getDuplicateStreamInstance = ({ otherStdioItems, type, value, optionName, direction }) => {
|
|
3696
3667
|
const duplicateStdioItems = otherStdioItems.filter((stdioItem) => hasSameValue(stdioItem, value));
|
|
3697
3668
|
if (duplicateStdioItems.length === 0) return;
|
|
3698
|
-
|
|
3699
|
-
throwOnDuplicateStream(differentStdioItem, optionName, type);
|
|
3669
|
+
throwOnDuplicateStream(duplicateStdioItems.find((stdioItem) => stdioItem.direction !== direction), optionName, type);
|
|
3700
3670
|
return direction === "output" ? duplicateStdioItems[0].stream : void 0;
|
|
3701
3671
|
};
|
|
3702
3672
|
const hasSameValue = ({ type, value }, secondValue) => {
|
|
@@ -3705,8 +3675,7 @@ const hasSameValue = ({ type, value }, secondValue) => {
|
|
|
3705
3675
|
return value === secondValue;
|
|
3706
3676
|
};
|
|
3707
3677
|
const validateDuplicateTransform = ({ otherStdioItems, type, value, optionName }) => {
|
|
3708
|
-
|
|
3709
|
-
throwOnDuplicateStream(duplicateStdioItem, optionName, type);
|
|
3678
|
+
throwOnDuplicateStream(otherStdioItems.find(({ value: { transform: transform$1 } }) => transform$1 === value.transform), optionName, type);
|
|
3710
3679
|
};
|
|
3711
3680
|
const throwOnDuplicateStream = (stdioItem, optionName, type) => {
|
|
3712
3681
|
if (stdioItem !== void 0) throw new TypeError(`The \`${stdioItem.optionName}\` and \`${optionName}\` options must not target ${TYPE_TO_MESSAGE[type]} that is the same.`);
|
|
@@ -3715,14 +3684,13 @@ const throwOnDuplicateStream = (stdioItem, optionName, type) => {
|
|
|
3715
3684
|
//#endregion
|
|
3716
3685
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/stdio/handle.js
|
|
3717
3686
|
const handleStdio = (addProperties$2, options, verboseInfo, isSync) => {
|
|
3718
|
-
const initialFileDescriptors = normalizeStdioOption(options, verboseInfo, isSync).map((stdioOption, fdNumber) => getFileDescriptor({
|
|
3719
|
-
stdioOption,
|
|
3720
|
-
fdNumber,
|
|
3721
|
-
options,
|
|
3722
|
-
isSync
|
|
3723
|
-
}));
|
|
3724
3687
|
const fileDescriptors = getFinalFileDescriptors({
|
|
3725
|
-
initialFileDescriptors,
|
|
3688
|
+
initialFileDescriptors: normalizeStdioOption(options, verboseInfo, isSync).map((stdioOption, fdNumber) => getFileDescriptor({
|
|
3689
|
+
stdioOption,
|
|
3690
|
+
fdNumber,
|
|
3691
|
+
options,
|
|
3692
|
+
isSync
|
|
3693
|
+
})),
|
|
3726
3694
|
addProperties: addProperties$2,
|
|
3727
3695
|
options,
|
|
3728
3696
|
isSync
|
|
@@ -3739,14 +3707,13 @@ const getFileDescriptor = ({ stdioOption, fdNumber, options, isSync }) => {
|
|
|
3739
3707
|
optionName
|
|
3740
3708
|
});
|
|
3741
3709
|
const direction = getStreamDirection(initialStdioItems, fdNumber, optionName);
|
|
3742
|
-
const
|
|
3710
|
+
const normalizedStdioItems = normalizeTransforms(initialStdioItems.map((stdioItem) => handleNativeStream({
|
|
3743
3711
|
stdioItem,
|
|
3744
3712
|
isStdioArray,
|
|
3745
3713
|
fdNumber,
|
|
3746
3714
|
direction,
|
|
3747
3715
|
isSync
|
|
3748
|
-
}));
|
|
3749
|
-
const normalizedStdioItems = normalizeTransforms(stdioItems, optionName, direction, options);
|
|
3716
|
+
})), optionName, direction, options);
|
|
3750
3717
|
const objectMode = getFdObjectMode(normalizedStdioItems, direction);
|
|
3751
3718
|
validateFileObjectMode(normalizedStdioItems, objectMode);
|
|
3752
3719
|
return {
|
|
@@ -3756,8 +3723,7 @@ const getFileDescriptor = ({ stdioOption, fdNumber, options, isSync }) => {
|
|
|
3756
3723
|
};
|
|
3757
3724
|
};
|
|
3758
3725
|
const initializeStdioItems = ({ stdioOption, fdNumber, options, optionName }) => {
|
|
3759
|
-
const
|
|
3760
|
-
const stdioItems = filterDuplicates(initialStdioItems);
|
|
3726
|
+
const stdioItems = filterDuplicates([...(Array.isArray(stdioOption) ? stdioOption : [stdioOption]).map((value) => initializeStdioItem(value, optionName)), ...handleInputOptions(options, fdNumber)]);
|
|
3761
3727
|
const isStdioArray = stdioItems.length > 1;
|
|
3762
3728
|
validateStdioArray(stdioItems, isStdioArray, optionName);
|
|
3763
3729
|
validateStreams(stdioItems);
|
|
@@ -3807,18 +3773,17 @@ const getFinalFileDescriptors = ({ initialFileDescriptors, addProperties: addPro
|
|
|
3807
3773
|
}
|
|
3808
3774
|
};
|
|
3809
3775
|
const getFinalFileDescriptor = ({ fileDescriptor: { direction, objectMode, stdioItems }, fileDescriptors, addProperties: addProperties$2, options, isSync }) => {
|
|
3810
|
-
const finalStdioItems = stdioItems.map((stdioItem) => addStreamProperties({
|
|
3811
|
-
stdioItem,
|
|
3812
|
-
addProperties: addProperties$2,
|
|
3813
|
-
direction,
|
|
3814
|
-
options,
|
|
3815
|
-
fileDescriptors,
|
|
3816
|
-
isSync
|
|
3817
|
-
}));
|
|
3818
3776
|
return {
|
|
3819
3777
|
direction,
|
|
3820
3778
|
objectMode,
|
|
3821
|
-
stdioItems:
|
|
3779
|
+
stdioItems: stdioItems.map((stdioItem) => addStreamProperties({
|
|
3780
|
+
stdioItem,
|
|
3781
|
+
addProperties: addProperties$2,
|
|
3782
|
+
direction,
|
|
3783
|
+
options,
|
|
3784
|
+
fileDescriptors,
|
|
3785
|
+
isSync
|
|
3786
|
+
}))
|
|
3822
3787
|
};
|
|
3823
3788
|
};
|
|
3824
3789
|
const addStreamProperties = ({ stdioItem, addProperties: addProperties$2, direction, options, fileDescriptors, isSync }) => {
|
|
@@ -4114,10 +4079,7 @@ const generatorToStream = ({ value, value: { transform: transform$1, final, writ
|
|
|
4114
4079
|
const runGeneratorsSync = (chunks, stdioItems, encoding, isInput) => {
|
|
4115
4080
|
const generators = stdioItems.filter(({ type }) => type === "generator");
|
|
4116
4081
|
const reversedGenerators = isInput ? generators.reverse() : generators;
|
|
4117
|
-
for (const { value, optionName } of reversedGenerators)
|
|
4118
|
-
const generators$1 = addInternalGenerators(value, encoding, optionName);
|
|
4119
|
-
chunks = runTransformSync(generators$1, chunks);
|
|
4120
|
-
}
|
|
4082
|
+
for (const { value, optionName } of reversedGenerators) chunks = runTransformSync(addInternalGenerators(value, encoding, optionName), chunks);
|
|
4121
4083
|
return chunks;
|
|
4122
4084
|
};
|
|
4123
4085
|
const addInternalGenerators = ({ transform: transform$1, final, binary, writableObjectMode, readableObjectMode, preserveNewlines }, encoding, optionName) => {
|
|
@@ -4154,8 +4116,7 @@ const addInputOptionSync = (fileDescriptors, fdNumber, options) => {
|
|
|
4154
4116
|
const [{ type, optionName }] = allStdioItems;
|
|
4155
4117
|
throw new TypeError(`Only the \`stdin\` option, not \`${optionName}\`, can be ${TYPE_TO_MESSAGE[type]} with synchronous methods.`);
|
|
4156
4118
|
}
|
|
4157
|
-
|
|
4158
|
-
options.input = joinToUint8Array(transformedContents);
|
|
4119
|
+
options.input = joinToUint8Array(allStdioItems.map(({ contents }) => contents).map((contents) => applySingleInputGeneratorsSync(contents, stdioItems)));
|
|
4159
4120
|
};
|
|
4160
4121
|
const applySingleInputGeneratorsSync = (contents, stdioItems) => {
|
|
4161
4122
|
const newContents = runGeneratorsSync(contents, stdioItems, "utf8", true);
|
|
@@ -4180,10 +4141,9 @@ const logLinesSync = (linesArray, fdNumber, verboseInfo) => {
|
|
|
4180
4141
|
};
|
|
4181
4142
|
const isPipingStream = (stream) => stream._readableState.pipes.length > 0;
|
|
4182
4143
|
const logLine = (line, fdNumber, verboseInfo) => {
|
|
4183
|
-
const verboseMessage = serializeVerboseMessage(line);
|
|
4184
4144
|
verboseLog({
|
|
4185
4145
|
type: "output",
|
|
4186
|
-
verboseMessage,
|
|
4146
|
+
verboseMessage: serializeVerboseMessage(line),
|
|
4187
4147
|
fdNumber,
|
|
4188
4148
|
verboseInfo
|
|
4189
4149
|
});
|
|
@@ -4210,12 +4170,10 @@ const transformOutputSync = ({ fileDescriptors, syncResult: { output }, options,
|
|
|
4210
4170
|
};
|
|
4211
4171
|
const transformOutputResultSync = ({ result, fileDescriptors, fdNumber, state, outputFiles, isMaxBuffer, verboseInfo }, { buffer, encoding, lines, stripFinalNewline: stripFinalNewline$1, maxBuffer }) => {
|
|
4212
4172
|
if (result === null) return;
|
|
4213
|
-
const
|
|
4214
|
-
const uint8ArrayResult = bufferToUint8Array(truncatedResult);
|
|
4173
|
+
const uint8ArrayResult = bufferToUint8Array(truncateMaxBufferSync(result, isMaxBuffer, maxBuffer));
|
|
4215
4174
|
const { stdioItems, objectMode } = fileDescriptors[fdNumber];
|
|
4216
|
-
const chunks = runOutputGeneratorsSync([uint8ArrayResult], stdioItems, encoding, state);
|
|
4217
4175
|
const { serializedResult, finalResult = serializedResult } = serializeChunks({
|
|
4218
|
-
chunks,
|
|
4176
|
+
chunks: runOutputGeneratorsSync([uint8ArrayResult], stdioItems, encoding, state),
|
|
4219
4177
|
objectMode,
|
|
4220
4178
|
encoding,
|
|
4221
4179
|
lines,
|
|
@@ -4326,14 +4284,12 @@ const isFailedExit = (exitCode, signal) => exitCode !== 0 || signal !== null;
|
|
|
4326
4284
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/resolve/exit-sync.js
|
|
4327
4285
|
const getExitResultSync = ({ error, status: exitCode, signal, output }, { maxBuffer }) => {
|
|
4328
4286
|
const resultError = getResultError(error, exitCode, signal);
|
|
4329
|
-
const timedOut = resultError?.code === "ETIMEDOUT";
|
|
4330
|
-
const isMaxBuffer = isMaxBufferSync(resultError, output, maxBuffer);
|
|
4331
4287
|
return {
|
|
4332
4288
|
resultError,
|
|
4333
4289
|
exitCode,
|
|
4334
4290
|
signal,
|
|
4335
|
-
timedOut,
|
|
4336
|
-
isMaxBuffer
|
|
4291
|
+
timedOut: resultError?.code === "ETIMEDOUT",
|
|
4292
|
+
isMaxBuffer: isMaxBufferSync(resultError, output, maxBuffer)
|
|
4337
4293
|
};
|
|
4338
4294
|
};
|
|
4339
4295
|
const getResultError = (error, exitCode, signal) => {
|
|
@@ -4345,7 +4301,7 @@ const getResultError = (error, exitCode, signal) => {
|
|
|
4345
4301
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/methods/main-sync.js
|
|
4346
4302
|
const execaCoreSync = (rawFile, rawArguments, rawOptions) => {
|
|
4347
4303
|
const { file, commandArguments, command, escapedCommand, startTime, verboseInfo, options, fileDescriptors } = handleSyncArguments(rawFile, rawArguments, rawOptions);
|
|
4348
|
-
|
|
4304
|
+
return handleResult(spawnSubprocessSync({
|
|
4349
4305
|
file,
|
|
4350
4306
|
commandArguments,
|
|
4351
4307
|
options,
|
|
@@ -4354,15 +4310,12 @@ const execaCoreSync = (rawFile, rawArguments, rawOptions) => {
|
|
|
4354
4310
|
verboseInfo,
|
|
4355
4311
|
fileDescriptors,
|
|
4356
4312
|
startTime
|
|
4357
|
-
});
|
|
4358
|
-
return handleResult(result, verboseInfo, options);
|
|
4313
|
+
}), verboseInfo, options);
|
|
4359
4314
|
};
|
|
4360
4315
|
const handleSyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
4361
4316
|
const { command, escapedCommand, startTime, verboseInfo } = handleCommand(rawFile, rawArguments, rawOptions);
|
|
4362
|
-
const
|
|
4363
|
-
const { file, commandArguments, options } = normalizeOptions(rawFile, rawArguments, syncOptions);
|
|
4317
|
+
const { file, commandArguments, options } = normalizeOptions(rawFile, rawArguments, normalizeSyncOptions(rawOptions));
|
|
4364
4318
|
validateSyncOptions(options);
|
|
4365
|
-
const fileDescriptors = handleStdioSync(options, verboseInfo);
|
|
4366
4319
|
return {
|
|
4367
4320
|
file,
|
|
4368
4321
|
commandArguments,
|
|
@@ -4371,7 +4324,7 @@ const handleSyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
|
4371
4324
|
startTime,
|
|
4372
4325
|
verboseInfo,
|
|
4373
4326
|
options,
|
|
4374
|
-
fileDescriptors
|
|
4327
|
+
fileDescriptors: handleStdioSync(options, verboseInfo)
|
|
4375
4328
|
};
|
|
4376
4329
|
};
|
|
4377
4330
|
const normalizeSyncOptions = (options) => options.node && !options.ipc ? {
|
|
@@ -4406,16 +4359,14 @@ const spawnSubprocessSync = ({ file, commandArguments, options, command, escaped
|
|
|
4406
4359
|
isMaxBuffer,
|
|
4407
4360
|
verboseInfo
|
|
4408
4361
|
});
|
|
4409
|
-
const stdio = output.map((stdioOutput, fdNumber) => stripNewline(stdioOutput, options, fdNumber));
|
|
4410
|
-
const all = stripNewline(getAllSync(output, options), options, "all");
|
|
4411
4362
|
return getSyncResult({
|
|
4412
4363
|
error,
|
|
4413
4364
|
exitCode,
|
|
4414
4365
|
signal,
|
|
4415
4366
|
timedOut,
|
|
4416
4367
|
isMaxBuffer,
|
|
4417
|
-
stdio,
|
|
4418
|
-
all,
|
|
4368
|
+
stdio: output.map((stdioOutput, fdNumber) => stripNewline(stdioOutput, options, fdNumber)),
|
|
4369
|
+
all: stripNewline(getAllSync(output, options), options, "all"),
|
|
4419
4370
|
options,
|
|
4420
4371
|
command,
|
|
4421
4372
|
escapedCommand,
|
|
@@ -4425,8 +4376,7 @@ const spawnSubprocessSync = ({ file, commandArguments, options, command, escaped
|
|
|
4425
4376
|
const runSubprocessSync = ({ file, commandArguments, options, command, escapedCommand, fileDescriptors, startTime }) => {
|
|
4426
4377
|
try {
|
|
4427
4378
|
addInputOptionsSync(fileDescriptors, options);
|
|
4428
|
-
|
|
4429
|
-
return (0, node_child_process.spawnSync)(...concatenateShell(file, commandArguments, normalizedOptions));
|
|
4379
|
+
return (0, node_child_process.spawnSync)(...concatenateShell(file, commandArguments, normalizeSpawnSyncOptions(options)));
|
|
4430
4380
|
} catch (error) {
|
|
4431
4381
|
return makeEarlyError({
|
|
4432
4382
|
error,
|
|
@@ -4644,19 +4594,17 @@ const handleEarlyError = ({ error, command, escapedCommand, fileDescriptors, opt
|
|
|
4644
4594
|
writable,
|
|
4645
4595
|
duplex
|
|
4646
4596
|
});
|
|
4647
|
-
const earlyError = makeEarlyError({
|
|
4648
|
-
error,
|
|
4649
|
-
command,
|
|
4650
|
-
escapedCommand,
|
|
4651
|
-
fileDescriptors,
|
|
4652
|
-
options,
|
|
4653
|
-
startTime,
|
|
4654
|
-
isSync: false
|
|
4655
|
-
});
|
|
4656
|
-
const promise = handleDummyPromise(earlyError, verboseInfo, options);
|
|
4657
4597
|
return {
|
|
4658
4598
|
subprocess,
|
|
4659
|
-
promise
|
|
4599
|
+
promise: handleDummyPromise(makeEarlyError({
|
|
4600
|
+
error,
|
|
4601
|
+
command,
|
|
4602
|
+
escapedCommand,
|
|
4603
|
+
fileDescriptors,
|
|
4604
|
+
options,
|
|
4605
|
+
startTime,
|
|
4606
|
+
isSync: false
|
|
4607
|
+
}), verboseInfo, options)
|
|
4660
4608
|
};
|
|
4661
4609
|
};
|
|
4662
4610
|
const createDummyStreams = (subprocess, fileDescriptors) => {
|
|
@@ -4951,10 +4899,7 @@ const pipeOutputAsync = (subprocess, fileDescriptors, controller) => {
|
|
|
4951
4899
|
controller
|
|
4952
4900
|
});
|
|
4953
4901
|
}
|
|
4954
|
-
for (const [outputStream, inputStreams] of pipeGroups.entries())
|
|
4955
|
-
const inputStream = inputStreams.length === 1 ? inputStreams[0] : mergeStreams(inputStreams);
|
|
4956
|
-
pipeStreams(inputStream, outputStream);
|
|
4957
|
-
}
|
|
4902
|
+
for (const [outputStream, inputStreams] of pipeGroups.entries()) pipeStreams(inputStreams.length === 1 ? inputStreams[0] : mergeStreams(inputStreams), outputStream);
|
|
4958
4903
|
};
|
|
4959
4904
|
const pipeTransform = (subprocess, stream, direction, fdNumber) => {
|
|
4960
4905
|
if (direction === "output") pipeStreams(subprocess.stdio[fdNumber], stream);
|
|
@@ -5216,10 +5161,9 @@ const normalizePipeArguments = ({ source, sourcePromise, boundOptions, createNes
|
|
|
5216
5161
|
const getDestinationStream = (boundOptions, createNested, pipeArguments) => {
|
|
5217
5162
|
try {
|
|
5218
5163
|
const { destination, pipeOptions: { from, to, unpipeSignal } = {} } = getDestination(boundOptions, createNested, ...pipeArguments);
|
|
5219
|
-
const destinationStream = getToStream(destination, to);
|
|
5220
5164
|
return {
|
|
5221
5165
|
destination,
|
|
5222
|
-
destinationStream,
|
|
5166
|
+
destinationStream: getToStream(destination, to),
|
|
5223
5167
|
from,
|
|
5224
5168
|
unpipeSignal
|
|
5225
5169
|
};
|
|
@@ -5454,13 +5398,12 @@ const stopReadingOnStreamEnd = async (onStreamEnd, controller, stream) => {
|
|
|
5454
5398
|
}
|
|
5455
5399
|
};
|
|
5456
5400
|
const iterateOnStream = ({ stream, controller, binary, shouldEncode, encoding, shouldSplit, preserveNewlines }) => {
|
|
5457
|
-
const onStdoutChunk = (0, node_events.on)(stream, "data", {
|
|
5458
|
-
signal: controller.signal,
|
|
5459
|
-
highWaterMark: HIGH_WATER_MARK,
|
|
5460
|
-
highWatermark: HIGH_WATER_MARK
|
|
5461
|
-
});
|
|
5462
5401
|
return iterateOnData({
|
|
5463
|
-
onStdoutChunk,
|
|
5402
|
+
onStdoutChunk: (0, node_events.on)(stream, "data", {
|
|
5403
|
+
signal: controller.signal,
|
|
5404
|
+
highWaterMark: HIGH_WATER_MARK,
|
|
5405
|
+
highWatermark: HIGH_WATER_MARK
|
|
5406
|
+
}),
|
|
5464
5407
|
controller,
|
|
5465
5408
|
binary,
|
|
5466
5409
|
shouldEncode,
|
|
@@ -5505,13 +5448,12 @@ const getStreamOutput = async ({ stream, onStreamEnd, fdNumber, encoding, buffer
|
|
|
5505
5448
|
await Promise.all([resumeStream(stream), logPromise]);
|
|
5506
5449
|
return;
|
|
5507
5450
|
}
|
|
5508
|
-
const stripFinalNewlineValue = getStripFinalNewline(stripFinalNewline$1, fdNumber);
|
|
5509
5451
|
const iterable = iterateForResult({
|
|
5510
5452
|
stream,
|
|
5511
5453
|
onStreamEnd,
|
|
5512
5454
|
lines,
|
|
5513
5455
|
encoding,
|
|
5514
|
-
stripFinalNewline:
|
|
5456
|
+
stripFinalNewline: getStripFinalNewline(stripFinalNewline$1, fdNumber),
|
|
5515
5457
|
allMixed
|
|
5516
5458
|
});
|
|
5517
5459
|
const [output] = await Promise.all([getStreamContents({
|
|
@@ -5531,15 +5473,14 @@ const logOutputAsync = async ({ stream, onStreamEnd, fdNumber, encoding, allMixe
|
|
|
5531
5473
|
verboseInfo,
|
|
5532
5474
|
fdNumber
|
|
5533
5475
|
})) return;
|
|
5534
|
-
|
|
5476
|
+
await logLines(iterateForResult({
|
|
5535
5477
|
stream,
|
|
5536
5478
|
onStreamEnd,
|
|
5537
5479
|
lines: true,
|
|
5538
5480
|
encoding,
|
|
5539
5481
|
stripFinalNewline: true,
|
|
5540
5482
|
allMixed
|
|
5541
|
-
});
|
|
5542
|
-
await logLines(linesIterable, stream, fdNumber, verboseInfo);
|
|
5483
|
+
}), stream, fdNumber, verboseInfo);
|
|
5543
5484
|
};
|
|
5544
5485
|
const resumeStream = async (stream) => {
|
|
5545
5486
|
await (0, node_timers_promises.setImmediate)();
|
|
@@ -5689,10 +5630,9 @@ const getAllMixed = ({ all, stdout, stderr }) => all && stdout && stderr && stdo
|
|
|
5689
5630
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/verbose/ipc.js
|
|
5690
5631
|
const shouldLogIpc = (verboseInfo) => isFullVerbose(verboseInfo, "ipc");
|
|
5691
5632
|
const logIpcOutput = (message, verboseInfo) => {
|
|
5692
|
-
const verboseMessage = serializeVerboseMessage(message);
|
|
5693
5633
|
verboseLog({
|
|
5694
5634
|
type: "ipc",
|
|
5695
|
-
verboseMessage,
|
|
5635
|
+
verboseMessage: serializeVerboseMessage(message),
|
|
5696
5636
|
fdNumber: "ipc",
|
|
5697
5637
|
verboseInfo
|
|
5698
5638
|
});
|
|
@@ -5917,10 +5857,9 @@ const createReadable = ({ subprocess, concurrentStreams, encoding }, { from, bin
|
|
|
5917
5857
|
};
|
|
5918
5858
|
const getSubprocessStdout = (subprocess, from, concurrentStreams) => {
|
|
5919
5859
|
const subprocessStdout = getFromStream(subprocess, from);
|
|
5920
|
-
const waitReadableDestroy = addConcurrentStream(concurrentStreams, subprocessStdout, "readableDestroy");
|
|
5921
5860
|
return {
|
|
5922
5861
|
subprocessStdout,
|
|
5923
|
-
waitReadableDestroy
|
|
5862
|
+
waitReadableDestroy: addConcurrentStream(concurrentStreams, subprocessStdout, "readableDestroy")
|
|
5924
5863
|
};
|
|
5925
5864
|
};
|
|
5926
5865
|
const getReadableOptions = ({ readableEncoding, readableObjectMode, readableHighWaterMark }, binary) => binary ? {
|
|
@@ -5998,12 +5937,10 @@ const createWritable = ({ subprocess, concurrentStreams }, { to } = {}) => {
|
|
|
5998
5937
|
};
|
|
5999
5938
|
const getSubprocessStdin = (subprocess, to, concurrentStreams) => {
|
|
6000
5939
|
const subprocessStdin = getToStream(subprocess, to);
|
|
6001
|
-
const waitWritableFinal = addConcurrentStream(concurrentStreams, subprocessStdin, "writableFinal");
|
|
6002
|
-
const waitWritableDestroy = addConcurrentStream(concurrentStreams, subprocessStdin, "writableDestroy");
|
|
6003
5940
|
return {
|
|
6004
5941
|
subprocessStdin,
|
|
6005
|
-
waitWritableFinal,
|
|
6006
|
-
waitWritableDestroy
|
|
5942
|
+
waitWritableFinal: addConcurrentStream(concurrentStreams, subprocessStdin, "writableFinal"),
|
|
5943
|
+
waitWritableDestroy: addConcurrentStream(concurrentStreams, subprocessStdin, "writableDestroy")
|
|
6007
5944
|
};
|
|
6008
5945
|
};
|
|
6009
5946
|
const getWritableMethods = (subprocessStdin, subprocess, waitWritableFinal) => ({
|
|
@@ -6099,15 +6036,14 @@ const onDuplexDestroy = async ({ subprocessStdout, subprocessStdin, subprocess,
|
|
|
6099
6036
|
const createIterable = (subprocess, encoding, { from, binary: binaryOption = false, preserveNewlines = false } = {}) => {
|
|
6100
6037
|
const binary = binaryOption || BINARY_ENCODINGS.has(encoding);
|
|
6101
6038
|
const subprocessStdout = getFromStream(subprocess, from);
|
|
6102
|
-
|
|
6039
|
+
return iterateOnStdoutData(iterateOnSubprocessStream({
|
|
6103
6040
|
subprocessStdout,
|
|
6104
6041
|
subprocess,
|
|
6105
6042
|
binary,
|
|
6106
6043
|
shouldEncode: true,
|
|
6107
6044
|
encoding,
|
|
6108
6045
|
preserveNewlines
|
|
6109
|
-
});
|
|
6110
|
-
return iterateOnStdoutData(onStdoutData, subprocessStdout, subprocess);
|
|
6046
|
+
}), subprocessStdout, subprocess);
|
|
6111
6047
|
};
|
|
6112
6048
|
const iterateOnStdoutData = async function* (onStdoutData, subprocessStdout, subprocess) {
|
|
6113
6049
|
try {
|
|
@@ -6189,7 +6125,6 @@ const handleAsyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
|
6189
6125
|
const { command, escapedCommand, startTime, verboseInfo } = handleCommand(rawFile, rawArguments, rawOptions);
|
|
6190
6126
|
const { file, commandArguments, options: normalizedOptions } = normalizeOptions(rawFile, rawArguments, rawOptions);
|
|
6191
6127
|
const options = handleAsyncOptions(normalizedOptions);
|
|
6192
|
-
const fileDescriptors = handleStdioAsync(options, verboseInfo);
|
|
6193
6128
|
return {
|
|
6194
6129
|
file,
|
|
6195
6130
|
commandArguments,
|
|
@@ -6198,7 +6133,7 @@ const handleAsyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
|
6198
6133
|
startTime,
|
|
6199
6134
|
verboseInfo,
|
|
6200
6135
|
options,
|
|
6201
|
-
fileDescriptors
|
|
6136
|
+
fileDescriptors: handleStdioAsync(options, verboseInfo)
|
|
6202
6137
|
};
|
|
6203
6138
|
};
|
|
6204
6139
|
const handleAsyncOptions = ({ timeout, signal,...options }) => {
|
|
@@ -6271,22 +6206,19 @@ const handlePromise = async ({ subprocess, options, startTime, verboseInfo, file
|
|
|
6271
6206
|
});
|
|
6272
6207
|
controller.abort();
|
|
6273
6208
|
onInternalError.resolve();
|
|
6274
|
-
|
|
6275
|
-
const all = stripNewline(allResult, options, "all");
|
|
6276
|
-
const result = getAsyncResult({
|
|
6209
|
+
return handleResult(getAsyncResult({
|
|
6277
6210
|
errorInfo,
|
|
6278
6211
|
exitCode,
|
|
6279
6212
|
signal,
|
|
6280
|
-
stdio,
|
|
6281
|
-
all,
|
|
6213
|
+
stdio: stdioResults.map((stdioResult, fdNumber) => stripNewline(stdioResult, options, fdNumber)),
|
|
6214
|
+
all: stripNewline(allResult, options, "all"),
|
|
6282
6215
|
ipcOutput,
|
|
6283
6216
|
context,
|
|
6284
6217
|
options,
|
|
6285
6218
|
command,
|
|
6286
6219
|
escapedCommand,
|
|
6287
6220
|
startTime
|
|
6288
|
-
});
|
|
6289
|
-
return handleResult(result, verboseInfo, options);
|
|
6221
|
+
}), verboseInfo, options);
|
|
6290
6222
|
};
|
|
6291
6223
|
const getAsyncResult = ({ errorInfo, exitCode, signal, stdio, all, ipcOutput, context, options, command, escapedCommand, startTime }) => "error" in errorInfo ? makeError({
|
|
6292
6224
|
error: errorInfo.error,
|
|
@@ -6359,8 +6291,7 @@ const callBoundExeca = ({ mapArguments, deepOptions = {}, boundOptions = {}, set
|
|
|
6359
6291
|
return isSync ? execaCoreSync(file, commandArguments, options) : execaCoreAsync(file, commandArguments, options, createNested);
|
|
6360
6292
|
};
|
|
6361
6293
|
const parseArguments = ({ mapArguments, firstArgument, nextArguments, deepOptions, boundOptions }) => {
|
|
6362
|
-
const
|
|
6363
|
-
const [initialFile, initialArguments, initialOptions] = normalizeParameters(...callArguments);
|
|
6294
|
+
const [initialFile, initialArguments, initialOptions] = normalizeParameters(...isTemplateString(firstArgument) ? parseTemplates(firstArgument, nextArguments) : [firstArgument, ...nextArguments]);
|
|
6364
6295
|
const mergedOptions = mergeOptions(mergeOptions(deepOptions, boundOptions), initialOptions);
|
|
6365
6296
|
const { file = initialFile, commandArguments = initialArguments, options = mergedOptions, isSync = false } = mapArguments({
|
|
6366
6297
|
file: initialFile,
|
|
@@ -6448,11 +6379,11 @@ var require_p_limit = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mod
|
|
|
6448
6379
|
const pTry = require_p_try();
|
|
6449
6380
|
const pLimit$1 = (concurrency) => {
|
|
6450
6381
|
if (!((Number.isInteger(concurrency) || concurrency === Infinity) && concurrency > 0)) return Promise.reject(/* @__PURE__ */ new TypeError("Expected `concurrency` to be a number from 1 and up"));
|
|
6451
|
-
const queue
|
|
6382
|
+
const queue = [];
|
|
6452
6383
|
let activeCount = 0;
|
|
6453
6384
|
const next = () => {
|
|
6454
6385
|
activeCount--;
|
|
6455
|
-
if (queue
|
|
6386
|
+
if (queue.length > 0) queue.shift()();
|
|
6456
6387
|
};
|
|
6457
6388
|
const run = (fn, resolve, ...args) => {
|
|
6458
6389
|
activeCount++;
|
|
@@ -6462,14 +6393,14 @@ var require_p_limit = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mod
|
|
|
6462
6393
|
};
|
|
6463
6394
|
const enqueue$1 = (fn, resolve, ...args) => {
|
|
6464
6395
|
if (activeCount < concurrency) run(fn, resolve, ...args);
|
|
6465
|
-
else queue
|
|
6396
|
+
else queue.push(run.bind(null, fn, resolve, ...args));
|
|
6466
6397
|
};
|
|
6467
6398
|
const generator = (fn, ...args) => new Promise((resolve) => enqueue$1(fn, resolve, ...args));
|
|
6468
6399
|
Object.defineProperties(generator, {
|
|
6469
6400
|
activeCount: { get: () => activeCount },
|
|
6470
|
-
pendingCount: { get: () => queue
|
|
6401
|
+
pendingCount: { get: () => queue.length },
|
|
6471
6402
|
clearQueue: { value: () => {
|
|
6472
|
-
queue
|
|
6403
|
+
queue.length = 0;
|
|
6473
6404
|
} }
|
|
6474
6405
|
});
|
|
6475
6406
|
return generator;
|
|
@@ -7190,13 +7121,13 @@ var require_expand = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modu
|
|
|
7190
7121
|
const fill = require_fill_range();
|
|
7191
7122
|
const stringify$2 = require_stringify();
|
|
7192
7123
|
const utils$4 = require_utils$1();
|
|
7193
|
-
const append = (queue
|
|
7124
|
+
const append = (queue = "", stash = "", enclose = false) => {
|
|
7194
7125
|
const result = [];
|
|
7195
|
-
queue
|
|
7126
|
+
queue = [].concat(queue);
|
|
7196
7127
|
stash = [].concat(stash);
|
|
7197
|
-
if (!stash.length) return queue
|
|
7198
|
-
if (!queue
|
|
7199
|
-
for (const item of queue
|
|
7128
|
+
if (!stash.length) return queue;
|
|
7129
|
+
if (!queue.length) return enclose ? utils$4.flatten(stash).map((ele) => `{${ele}}`) : stash;
|
|
7130
|
+
for (const item of queue) if (Array.isArray(item)) for (const value of item) result.push(append(value, stash, enclose));
|
|
7200
7131
|
else for (let ele of stash) {
|
|
7201
7132
|
if (enclose === true && typeof ele === "string") ele = `{${ele}}`;
|
|
7202
7133
|
result.push(Array.isArray(ele) ? append(item, ele, enclose) : item + ele);
|
|
@@ -7231,30 +7162,30 @@ var require_expand = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modu
|
|
|
7231
7162
|
return;
|
|
7232
7163
|
}
|
|
7233
7164
|
const enclose = utils$4.encloseBrace(node);
|
|
7234
|
-
let queue
|
|
7165
|
+
let queue = node.queue;
|
|
7235
7166
|
let block = node;
|
|
7236
7167
|
while (block.type !== "brace" && block.type !== "root" && block.parent) {
|
|
7237
7168
|
block = block.parent;
|
|
7238
|
-
queue
|
|
7169
|
+
queue = block.queue;
|
|
7239
7170
|
}
|
|
7240
7171
|
for (let i$2 = 0; i$2 < node.nodes.length; i$2++) {
|
|
7241
7172
|
const child = node.nodes[i$2];
|
|
7242
7173
|
if (child.type === "comma" && node.type === "brace") {
|
|
7243
|
-
if (i$2 === 1) queue
|
|
7244
|
-
queue
|
|
7174
|
+
if (i$2 === 1) queue.push("");
|
|
7175
|
+
queue.push("");
|
|
7245
7176
|
continue;
|
|
7246
7177
|
}
|
|
7247
7178
|
if (child.type === "close") {
|
|
7248
|
-
q.push(append(q.pop(), queue
|
|
7179
|
+
q.push(append(q.pop(), queue, enclose));
|
|
7249
7180
|
continue;
|
|
7250
7181
|
}
|
|
7251
7182
|
if (child.value && child.type !== "open") {
|
|
7252
|
-
queue
|
|
7183
|
+
queue.push(append(queue.pop(), child.value));
|
|
7253
7184
|
continue;
|
|
7254
7185
|
}
|
|
7255
7186
|
if (child.nodes) walk(child, node);
|
|
7256
7187
|
}
|
|
7257
|
-
return queue
|
|
7188
|
+
return queue;
|
|
7258
7189
|
};
|
|
7259
7190
|
return utils$4.flatten(walk(ast));
|
|
7260
7191
|
};
|
|
@@ -7473,7 +7404,7 @@ var require_parse$1 = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mod
|
|
|
7473
7404
|
*/
|
|
7474
7405
|
if (value === CHAR_LEFT_CURLY_BRACE$1) {
|
|
7475
7406
|
depth$1++;
|
|
7476
|
-
|
|
7407
|
+
block = push({
|
|
7477
7408
|
type: "brace",
|
|
7478
7409
|
open: true,
|
|
7479
7410
|
close: false,
|
|
@@ -7482,8 +7413,7 @@ var require_parse$1 = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mod
|
|
|
7482
7413
|
commas: 0,
|
|
7483
7414
|
ranges: 0,
|
|
7484
7415
|
nodes: []
|
|
7485
|
-
};
|
|
7486
|
-
block = push(brace);
|
|
7416
|
+
});
|
|
7487
7417
|
stack.push(block);
|
|
7488
7418
|
push({
|
|
7489
7419
|
type: "open",
|
|
@@ -7747,12 +7677,6 @@ var require_constants = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_m
|
|
|
7747
7677
|
const END_ANCHOR = `(?:${SLASH_LITERAL}|$)`;
|
|
7748
7678
|
const START_ANCHOR = `(?:^|${SLASH_LITERAL})`;
|
|
7749
7679
|
const DOTS_SLASH = `${DOT_LITERAL}{1,2}${END_ANCHOR}`;
|
|
7750
|
-
const NO_DOT = `(?!${DOT_LITERAL})`;
|
|
7751
|
-
const NO_DOTS = `(?!${START_ANCHOR}${DOTS_SLASH})`;
|
|
7752
|
-
const NO_DOT_SLASH = `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`;
|
|
7753
|
-
const NO_DOTS_SLASH = `(?!${DOTS_SLASH})`;
|
|
7754
|
-
const QMARK_NO_DOT = `[^.${SLASH_LITERAL}]`;
|
|
7755
|
-
const STAR = `${QMARK}*?`;
|
|
7756
7680
|
const POSIX_CHARS = {
|
|
7757
7681
|
DOT_LITERAL,
|
|
7758
7682
|
PLUS_LITERAL,
|
|
@@ -7762,12 +7686,12 @@ var require_constants = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_m
|
|
|
7762
7686
|
QMARK,
|
|
7763
7687
|
END_ANCHOR,
|
|
7764
7688
|
DOTS_SLASH,
|
|
7765
|
-
NO_DOT
|
|
7766
|
-
NO_DOTS
|
|
7767
|
-
NO_DOT_SLASH,
|
|
7768
|
-
NO_DOTS_SLASH
|
|
7769
|
-
QMARK_NO_DOT
|
|
7770
|
-
STAR
|
|
7689
|
+
NO_DOT: `(?!${DOT_LITERAL})`,
|
|
7690
|
+
NO_DOTS: `(?!${START_ANCHOR}${DOTS_SLASH})`,
|
|
7691
|
+
NO_DOT_SLASH: `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`,
|
|
7692
|
+
NO_DOTS_SLASH: `(?!${DOTS_SLASH})`,
|
|
7693
|
+
QMARK_NO_DOT: `[^.${SLASH_LITERAL}]`,
|
|
7694
|
+
STAR: `${QMARK}*?`,
|
|
7771
7695
|
START_ANCHOR
|
|
7772
7696
|
};
|
|
7773
7697
|
/**
|
|
@@ -7939,9 +7863,7 @@ var require_utils = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modul
|
|
|
7939
7863
|
return output;
|
|
7940
7864
|
};
|
|
7941
7865
|
exports.wrapOutput = (input, state = {}, options = {}) => {
|
|
7942
|
-
|
|
7943
|
-
const append$1 = options.contains ? "" : "$";
|
|
7944
|
-
let output = `${prepend}(?:${input})${append$1}`;
|
|
7866
|
+
let output = `${options.contains ? "" : "^"}(?:${input})${options.contains ? "" : "$"}`;
|
|
7945
7867
|
if (state.negated === true) output = `(?:^(?!${output}).*$)`;
|
|
7946
7868
|
return output;
|
|
7947
7869
|
};
|
|
@@ -8287,13 +8209,13 @@ var require_parse = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modul
|
|
|
8287
8209
|
const win32$1 = utils$2.isWindows(options);
|
|
8288
8210
|
const PLATFORM_CHARS = constants$2.globChars(win32$1);
|
|
8289
8211
|
const EXTGLOB_CHARS = constants$2.extglobChars(PLATFORM_CHARS);
|
|
8290
|
-
const { DOT_LITERAL: DOT_LITERAL$1, PLUS_LITERAL: PLUS_LITERAL$1, SLASH_LITERAL: SLASH_LITERAL$1, ONE_CHAR: ONE_CHAR$1, DOTS_SLASH: DOTS_SLASH$1, NO_DOT
|
|
8212
|
+
const { DOT_LITERAL: DOT_LITERAL$1, PLUS_LITERAL: PLUS_LITERAL$1, SLASH_LITERAL: SLASH_LITERAL$1, ONE_CHAR: ONE_CHAR$1, DOTS_SLASH: DOTS_SLASH$1, NO_DOT, NO_DOT_SLASH, NO_DOTS_SLASH, QMARK: QMARK$1, QMARK_NO_DOT, STAR, START_ANCHOR: START_ANCHOR$1 } = PLATFORM_CHARS;
|
|
8291
8213
|
const globstar = (opts$1) => {
|
|
8292
8214
|
return `(${capture}(?:(?!${START_ANCHOR$1}${opts$1.dot ? DOTS_SLASH$1 : DOT_LITERAL$1}).)*?)`;
|
|
8293
8215
|
};
|
|
8294
|
-
const nodot = opts.dot ? "" : NO_DOT
|
|
8295
|
-
const qmarkNoDot = opts.dot ? QMARK$1 : QMARK_NO_DOT
|
|
8296
|
-
let star = opts.bash === true ? globstar(opts) : STAR
|
|
8216
|
+
const nodot = opts.dot ? "" : NO_DOT;
|
|
8217
|
+
const qmarkNoDot = opts.dot ? QMARK$1 : QMARK_NO_DOT;
|
|
8218
|
+
let star = opts.bash === true ? globstar(opts) : STAR;
|
|
8297
8219
|
if (opts.capture) star = `(${star})`;
|
|
8298
8220
|
if (typeof opts.noext === "boolean") opts.noextglob = opts.noext;
|
|
8299
8221
|
const state = {
|
|
@@ -8513,8 +8435,7 @@ var require_parse = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modul
|
|
|
8513
8435
|
if (inner.includes(":")) {
|
|
8514
8436
|
const idx = prev.value.lastIndexOf("[");
|
|
8515
8437
|
const pre = prev.value.slice(0, idx);
|
|
8516
|
-
const
|
|
8517
|
-
const posix = POSIX_REGEX_SOURCE[rest$1];
|
|
8438
|
+
const posix = POSIX_REGEX_SOURCE[prev.value.slice(idx + 2)];
|
|
8518
8439
|
if (posix) {
|
|
8519
8440
|
prev.value = pre + posix;
|
|
8520
8441
|
state.backtrack = true;
|
|
@@ -8782,7 +8703,7 @@ var require_parse = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modul
|
|
|
8782
8703
|
push({
|
|
8783
8704
|
type: "qmark",
|
|
8784
8705
|
value,
|
|
8785
|
-
output: QMARK_NO_DOT
|
|
8706
|
+
output: QMARK_NO_DOT
|
|
8786
8707
|
});
|
|
8787
8708
|
continue;
|
|
8788
8709
|
}
|
|
@@ -9001,11 +8922,11 @@ var require_parse = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modul
|
|
|
9001
8922
|
}
|
|
9002
8923
|
if (state.index === state.start || prev.type === "slash" || prev.type === "dot") {
|
|
9003
8924
|
if (prev.type === "dot") {
|
|
9004
|
-
state.output += NO_DOT_SLASH
|
|
9005
|
-
prev.output += NO_DOT_SLASH
|
|
8925
|
+
state.output += NO_DOT_SLASH;
|
|
8926
|
+
prev.output += NO_DOT_SLASH;
|
|
9006
8927
|
} else if (opts.dot === true) {
|
|
9007
|
-
state.output += NO_DOTS_SLASH
|
|
9008
|
-
prev.output += NO_DOTS_SLASH
|
|
8928
|
+
state.output += NO_DOTS_SLASH;
|
|
8929
|
+
prev.output += NO_DOTS_SLASH;
|
|
9009
8930
|
} else {
|
|
9010
8931
|
state.output += nodot;
|
|
9011
8932
|
prev.output += nodot;
|
|
@@ -9058,15 +8979,15 @@ var require_parse = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modul
|
|
|
9058
8979
|
if (len > max) throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`);
|
|
9059
8980
|
input = REPLACEMENTS[input] || input;
|
|
9060
8981
|
const win32$1 = utils$2.isWindows(options);
|
|
9061
|
-
const { DOT_LITERAL: DOT_LITERAL$1, SLASH_LITERAL: SLASH_LITERAL$1, ONE_CHAR: ONE_CHAR$1, DOTS_SLASH: DOTS_SLASH$1, NO_DOT
|
|
9062
|
-
const nodot = opts.dot ? NO_DOTS
|
|
9063
|
-
const slashDot = opts.dot ? NO_DOTS_SLASH
|
|
8982
|
+
const { DOT_LITERAL: DOT_LITERAL$1, SLASH_LITERAL: SLASH_LITERAL$1, ONE_CHAR: ONE_CHAR$1, DOTS_SLASH: DOTS_SLASH$1, NO_DOT, NO_DOTS, NO_DOTS_SLASH, STAR, START_ANCHOR: START_ANCHOR$1 } = constants$2.globChars(win32$1);
|
|
8983
|
+
const nodot = opts.dot ? NO_DOTS : NO_DOT;
|
|
8984
|
+
const slashDot = opts.dot ? NO_DOTS_SLASH : NO_DOT;
|
|
9064
8985
|
const capture = opts.capture ? "" : "?:";
|
|
9065
8986
|
const state = {
|
|
9066
8987
|
negated: false,
|
|
9067
8988
|
prefix: ""
|
|
9068
8989
|
};
|
|
9069
|
-
let star = opts.bash === true ? ".*?" : STAR
|
|
8990
|
+
let star = opts.bash === true ? ".*?" : STAR;
|
|
9070
8991
|
if (opts.capture) star = `(${star})`;
|
|
9071
8992
|
const globstar = (opts$1) => {
|
|
9072
8993
|
if (opts$1.noglobstar === true) return star;
|
|
@@ -9091,8 +9012,7 @@ var require_parse = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modul
|
|
|
9091
9012
|
}
|
|
9092
9013
|
}
|
|
9093
9014
|
};
|
|
9094
|
-
|
|
9095
|
-
let source = create(output);
|
|
9015
|
+
let source = create(utils$2.removePrefix(input, state));
|
|
9096
9016
|
if (source && opts.strictSlashes !== true) source += `${SLASH_LITERAL$1}?`;
|
|
9097
9017
|
return source;
|
|
9098
9018
|
};
|
|
@@ -9819,8 +9739,7 @@ var require_core$1 = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modu
|
|
|
9819
9739
|
let previous = null;
|
|
9820
9740
|
let current = initial;
|
|
9821
9741
|
do {
|
|
9822
|
-
|
|
9823
|
-
extractWorkspaces(manifest);
|
|
9742
|
+
extractWorkspaces(readPackageJSON(current));
|
|
9824
9743
|
let { done, found } = checkWorkspaces(current, initial);
|
|
9825
9744
|
if (done) return found;
|
|
9826
9745
|
previous = current;
|
|
@@ -9830,8 +9749,7 @@ var require_core$1 = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modu
|
|
|
9830
9749
|
}
|
|
9831
9750
|
exports.findWorkspaceRoot = findWorkspaceRoot;
|
|
9832
9751
|
function checkWorkspaces(current, initial) {
|
|
9833
|
-
const
|
|
9834
|
-
const workspaces = extractWorkspaces(manifest);
|
|
9752
|
+
const workspaces = extractWorkspaces(readPackageJSON(current));
|
|
9835
9753
|
let done = false;
|
|
9836
9754
|
let found;
|
|
9837
9755
|
let relativePath;
|
|
@@ -10259,9 +10177,9 @@ var require_graceful_fs = /* @__PURE__ */ require_chunk.__commonJS({ "../../node
|
|
|
10259
10177
|
previousSymbol = "___graceful-fs.previous";
|
|
10260
10178
|
}
|
|
10261
10179
|
function noop() {}
|
|
10262
|
-
function publishQueue(context, queue
|
|
10180
|
+
function publishQueue(context, queue) {
|
|
10263
10181
|
Object.defineProperty(context, gracefulQueue, { get: function() {
|
|
10264
|
-
return queue
|
|
10182
|
+
return queue;
|
|
10265
10183
|
} });
|
|
10266
10184
|
}
|
|
10267
10185
|
var debug = noop;
|
|
@@ -10272,8 +10190,7 @@ var require_graceful_fs = /* @__PURE__ */ require_chunk.__commonJS({ "../../node
|
|
|
10272
10190
|
console.error(m);
|
|
10273
10191
|
};
|
|
10274
10192
|
if (!fs$3[gracefulQueue]) {
|
|
10275
|
-
|
|
10276
|
-
publishQueue(fs$3, queue);
|
|
10193
|
+
publishQueue(fs$3, global[gracefulQueue] || []);
|
|
10277
10194
|
fs$3.close = (function(fs$close) {
|
|
10278
10195
|
function close(fd, cb) {
|
|
10279
10196
|
return fs$close.call(fs$3, fd, function(err) {
|
|
@@ -10588,8 +10505,7 @@ var require_graceful_fs = /* @__PURE__ */ require_chunk.__commonJS({ "../../node
|
|
|
10588
10505
|
} else {
|
|
10589
10506
|
var sinceAttempt = Date.now() - lastTime;
|
|
10590
10507
|
var sinceStart = Math.max(lastTime - startTime, 1);
|
|
10591
|
-
|
|
10592
|
-
if (sinceAttempt >= desiredDelay) {
|
|
10508
|
+
if (sinceAttempt >= Math.min(sinceStart * 1.2, 100)) {
|
|
10593
10509
|
debug("RETRY", fn.name, args);
|
|
10594
10510
|
fn.apply(null, args.concat([startTime]));
|
|
10595
10511
|
} else fs$3[gracefulQueue].push(elem);
|
|
@@ -12253,8 +12169,7 @@ var require_esprima = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mod
|
|
|
12253
12169
|
if (element.type === jsx_syntax_1.JSXSyntax.JSXClosingElement) {
|
|
12254
12170
|
el.closing = element;
|
|
12255
12171
|
var open_1 = getQualifiedElementName(el.opening.name);
|
|
12256
|
-
|
|
12257
|
-
if (open_1 !== close_1) this.tolerateError("Expected corresponding JSX closing tag for %0", open_1);
|
|
12172
|
+
if (open_1 !== getQualifiedElementName(el.closing.name)) this.tolerateError("Expected corresponding JSX closing tag for %0", open_1);
|
|
12258
12173
|
if (stack.length > 0) {
|
|
12259
12174
|
var child = this.finalize(el.node, new JSXNode.JSXElement(el.opening, el.children, el.closing));
|
|
12260
12175
|
el = stack[stack.length - 1];
|
|
@@ -13257,14 +13172,10 @@ var require_esprima = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mod
|
|
|
13257
13172
|
column: this.scanner.index - this.scanner.lineStart
|
|
13258
13173
|
}
|
|
13259
13174
|
};
|
|
13260
|
-
if (token.type === 9) {
|
|
13261
|
-
|
|
13262
|
-
|
|
13263
|
-
|
|
13264
|
-
pattern,
|
|
13265
|
-
flags
|
|
13266
|
-
};
|
|
13267
|
-
}
|
|
13175
|
+
if (token.type === 9) t.regex = {
|
|
13176
|
+
pattern: token.pattern,
|
|
13177
|
+
flags: token.flags
|
|
13178
|
+
};
|
|
13268
13179
|
return t;
|
|
13269
13180
|
};
|
|
13270
13181
|
Parser.prototype.nextToken = function() {
|
|
@@ -13806,10 +13717,9 @@ var require_esprima = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mod
|
|
|
13806
13717
|
if (!this.context.isBindingElement) this.throwUnexpectedToken(this.lookahead);
|
|
13807
13718
|
if (expr.type === syntax_1.Syntax.SequenceExpression) for (var i$2 = 0; i$2 < expr.expressions.length; i$2++) this.reinterpretExpressionAsPattern(expr.expressions[i$2]);
|
|
13808
13719
|
else this.reinterpretExpressionAsPattern(expr);
|
|
13809
|
-
var parameters = expr.type === syntax_1.Syntax.SequenceExpression ? expr.expressions : [expr];
|
|
13810
13720
|
expr = {
|
|
13811
13721
|
type: ArrowParameterPlaceHolder,
|
|
13812
|
-
params:
|
|
13722
|
+
params: expr.type === syntax_1.Syntax.SequenceExpression ? expr.expressions : [expr],
|
|
13813
13723
|
async: false
|
|
13814
13724
|
};
|
|
13815
13725
|
}
|
|
@@ -16391,13 +16301,12 @@ var require_esprima = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mod
|
|
|
16391
16301
|
var start = this.index;
|
|
16392
16302
|
var pattern = this.scanRegExpBody();
|
|
16393
16303
|
var flags = this.scanRegExpFlags();
|
|
16394
|
-
var value = this.testRegExp(pattern, flags);
|
|
16395
16304
|
return {
|
|
16396
16305
|
type: 9,
|
|
16397
16306
|
value: "",
|
|
16398
16307
|
pattern,
|
|
16399
16308
|
flags,
|
|
16400
|
-
regex:
|
|
16309
|
+
regex: this.testRegExp(pattern, flags),
|
|
16401
16310
|
lineNumber: this.lineNumber,
|
|
16402
16311
|
lineStart: this.lineStart,
|
|
16403
16312
|
start,
|
|
@@ -16856,14 +16765,10 @@ var require_esprima = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mod
|
|
|
16856
16765
|
};
|
|
16857
16766
|
entry.loc = loc;
|
|
16858
16767
|
}
|
|
16859
|
-
if (token.type === 9) {
|
|
16860
|
-
|
|
16861
|
-
|
|
16862
|
-
|
|
16863
|
-
pattern,
|
|
16864
|
-
flags
|
|
16865
|
-
};
|
|
16866
|
-
}
|
|
16768
|
+
if (token.type === 9) entry.regex = {
|
|
16769
|
+
pattern: token.pattern,
|
|
16770
|
+
flags: token.flags
|
|
16771
|
+
};
|
|
16867
16772
|
this.buffer.push(entry);
|
|
16868
16773
|
}
|
|
16869
16774
|
}
|
|
@@ -17948,8 +17853,7 @@ var require_dumper = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_modu
|
|
|
17948
17853
|
function blockHeader(string, indentPerLevel) {
|
|
17949
17854
|
var indentIndicator = needIndentIndicator(string) ? String(indentPerLevel) : "";
|
|
17950
17855
|
var clip = string[string.length - 1] === "\n";
|
|
17951
|
-
|
|
17952
|
-
return indentIndicator + chomp + "\n";
|
|
17856
|
+
return indentIndicator + (clip && (string[string.length - 2] === "\n" || string === "\n") ? "+" : clip ? "" : "-") + "\n";
|
|
17953
17857
|
}
|
|
17954
17858
|
function dropEndingNewline(string) {
|
|
17955
17859
|
return string[string.length - 1] === "\n" ? string.slice(0, -1) : string;
|
|
@@ -18232,8 +18136,7 @@ var require_which_pm = /* @__PURE__ */ require_chunk.__commonJS({ "../../node_mo
|
|
|
18232
18136
|
const modulesPath = path$1.join(pkgPath, "node_modules");
|
|
18233
18137
|
if (fs$1.existsSync(path$1.join(modulesPath, ".yarn-integrity"))) return { name: "yarn" };
|
|
18234
18138
|
try {
|
|
18235
|
-
|
|
18236
|
-
return toNameAndVersion(modules.packageManager);
|
|
18139
|
+
return toNameAndVersion((await loadYamlFile(path$1.join(modulesPath, ".modules.yaml"))).packageManager);
|
|
18237
18140
|
} catch (err) {
|
|
18238
18141
|
if (err.code !== "ENOENT") throw err;
|
|
18239
18142
|
}
|
|
@@ -18314,7 +18217,7 @@ var require_preferred_pm = /* @__PURE__ */ require_chunk.__commonJS({ "../../nod
|
|
|
18314
18217
|
//#endregion
|
|
18315
18218
|
//#region src/Commands/FireCommand.ts
|
|
18316
18219
|
var import_preferred_pm = /* @__PURE__ */ require_chunk.__toESM(require_preferred_pm(), 1);
|
|
18317
|
-
var FireCommand = class extends
|
|
18220
|
+
var FireCommand = class extends __h3ravel_musket.Command {
|
|
18318
18221
|
/**
|
|
18319
18222
|
* The name and signature of the console command.
|
|
18320
18223
|
*
|
|
@@ -18360,10 +18263,9 @@ var FireCommand = class extends __h3ravel_core.ConsoleCommand {
|
|
|
18360
18263
|
"error"
|
|
18361
18264
|
][Number(this.option("verbose", 0))]
|
|
18362
18265
|
};
|
|
18363
|
-
const silent = ENV_VARS.LOG_LEVEL === "silent" ? "--silent" : null;
|
|
18364
18266
|
await execa(pm, [
|
|
18365
18267
|
"tsdown",
|
|
18366
|
-
silent,
|
|
18268
|
+
ENV_VARS.LOG_LEVEL === "silent" ? "--silent" : null,
|
|
18367
18269
|
"--config-loader",
|
|
18368
18270
|
"unconfig",
|
|
18369
18271
|
"-c",
|
|
@@ -18412,8 +18314,9 @@ var HttpServiceProvider = class extends __h3ravel_core.ServiceProvider {
|
|
|
18412
18314
|
/** Bind the HTTP server to the service container */
|
|
18413
18315
|
this.app.singleton("http.serve", () => h3.serve);
|
|
18414
18316
|
/** Register Musket Commands */
|
|
18415
|
-
this.
|
|
18317
|
+
this.registerCommands([FireCommand]);
|
|
18416
18318
|
}
|
|
18319
|
+
boot() {}
|
|
18417
18320
|
};
|
|
18418
18321
|
|
|
18419
18322
|
//#endregion
|
|
@@ -18698,5 +18601,4 @@ exports.JsonResource = JsonResource;
|
|
|
18698
18601
|
exports.LogRequests = LogRequests;
|
|
18699
18602
|
exports.Middleware = Middleware;
|
|
18700
18603
|
exports.Request = Request;
|
|
18701
|
-
exports.Response = Response;
|
|
18702
|
-
//# sourceMappingURL=index.cjs.map
|
|
18604
|
+
exports.Response = Response;
|