@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.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __commonJS, __require, __toESM } from "./chunk-qJlxXUkR.js";
|
|
2
|
-
import {
|
|
2
|
+
import { Command } from "@h3ravel/musket";
|
|
3
3
|
import { HttpContext, Logger } from "@h3ravel/shared";
|
|
4
4
|
import { fileURLToPath } from "node:url";
|
|
5
5
|
import { ChildProcess, execFile, spawn, spawnSync } from "node:child_process";
|
|
@@ -17,6 +17,7 @@ import { finished } from "node:stream/promises";
|
|
|
17
17
|
import { Duplex, PassThrough, Readable, Transform, Writable, getDefaultHighWaterMark } from "node:stream";
|
|
18
18
|
import { Buffer as Buffer$1 } from "node:buffer";
|
|
19
19
|
import { H3, getQuery, getRouterParams, html, readBody, redirect, serve } from "h3";
|
|
20
|
+
import { ServiceProvider } from "@h3ravel/core";
|
|
20
21
|
import { safeDot } from "@h3ravel/support";
|
|
21
22
|
|
|
22
23
|
//#region ../../node_modules/.pnpm/is-plain-obj@4.1.0/node_modules/is-plain-obj/index.js
|
|
@@ -121,8 +122,7 @@ const parseTemplate = ({ templates, expressions, tokens, index, template }) => {
|
|
|
121
122
|
const newTokens = concatTokens(tokens, nextTokens, leadingWhitespaces);
|
|
122
123
|
if (index === expressions.length) return newTokens;
|
|
123
124
|
const expression = expressions[index];
|
|
124
|
-
|
|
125
|
-
return concatTokens(newTokens, expressionTokens, trailingWhitespaces);
|
|
125
|
+
return concatTokens(newTokens, Array.isArray(expression) ? expression.map((expression$1) => parseExpression(expression$1)) : [parseExpression(expression)], trailingWhitespaces);
|
|
126
126
|
};
|
|
127
127
|
const splitByWhitespaces = (template, rawTemplate) => {
|
|
128
128
|
if (rawTemplate.length === 0) return {
|
|
@@ -209,8 +209,7 @@ const normalizeFdSpecificOptions = (options) => {
|
|
|
209
209
|
};
|
|
210
210
|
const normalizeFdSpecificOption = (options, optionName) => {
|
|
211
211
|
const optionBaseArray = Array.from({ length: getStdioLength(options) + 1 });
|
|
212
|
-
|
|
213
|
-
return addDefaultValue$1(optionArray, optionName);
|
|
212
|
+
return addDefaultValue$1(normalizeFdSpecificValue(options[optionName], optionBaseArray, optionName), optionName);
|
|
214
213
|
};
|
|
215
214
|
const getStdioLength = ({ stdio }) => Array.isArray(stdio) ? Math.max(stdio.length, STANDARD_STREAMS_ALIASES.length) : STANDARD_STREAMS_ALIASES.length;
|
|
216
215
|
const normalizeFdSpecificValue = (optionValue, optionArray, optionName) => isPlainObject(optionValue) ? normalizeOptionObject(optionValue, optionArray, optionName) : optionArray.fill(optionValue);
|
|
@@ -277,11 +276,9 @@ const VERBOSE_VALUES = [
|
|
|
277
276
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/arguments/escape.js
|
|
278
277
|
const joinCommand = (filePath, rawArguments) => {
|
|
279
278
|
const fileAndArguments = [filePath, ...rawArguments];
|
|
280
|
-
const command = fileAndArguments.join(" ");
|
|
281
|
-
const escapedCommand = fileAndArguments.map((fileAndArgument) => quoteString(escapeControlCharacters(fileAndArgument))).join(" ");
|
|
282
279
|
return {
|
|
283
|
-
command,
|
|
284
|
-
escapedCommand
|
|
280
|
+
command: fileAndArguments.join(" "),
|
|
281
|
+
escapedCommand: fileAndArguments.map((fileAndArgument) => quoteString(escapeControlCharacters(fileAndArgument))).join(" ")
|
|
285
282
|
};
|
|
286
283
|
};
|
|
287
284
|
const escapeLines = (lines) => stripVTControlCharacters(lines).split("\n").map((line) => escapeControlCharacters(line)).join("\n");
|
|
@@ -723,13 +720,11 @@ const appendNewline = (printedLine) => printedLine.endsWith("\n") ? printedLine
|
|
|
723
720
|
//#endregion
|
|
724
721
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/verbose/log.js
|
|
725
722
|
const verboseLog = ({ type, verboseMessage, fdNumber, verboseInfo, result }) => {
|
|
726
|
-
const
|
|
723
|
+
const finalLines = applyVerboseOnLines(getPrintedLines(verboseMessage, getVerboseObject({
|
|
727
724
|
type,
|
|
728
725
|
result,
|
|
729
726
|
verboseInfo
|
|
730
|
-
});
|
|
731
|
-
const printedLines = getPrintedLines(verboseMessage, verboseObject);
|
|
732
|
-
const finalLines = applyVerboseOnLines(printedLines, verboseInfo, fdNumber);
|
|
727
|
+
})), verboseInfo, fdNumber);
|
|
733
728
|
if (finalLines !== "") console.warn(finalLines.slice(0, -1));
|
|
734
729
|
};
|
|
735
730
|
const getVerboseObject = ({ type, result, verboseInfo: { escapedCommand, commandId, rawOptions: { piped = false,...options } } }) => ({
|
|
@@ -752,8 +747,7 @@ const getPrintedLine = (verboseObject) => {
|
|
|
752
747
|
};
|
|
753
748
|
};
|
|
754
749
|
const serializeVerboseMessage = (message) => {
|
|
755
|
-
|
|
756
|
-
return escapeLines(messageString).replaceAll(" ", " ".repeat(TAB_SIZE));
|
|
750
|
+
return escapeLines(typeof message === "string" ? message : inspect(message)).replaceAll(" ", " ".repeat(TAB_SIZE));
|
|
757
751
|
};
|
|
758
752
|
const TAB_SIZE = 2;
|
|
759
753
|
|
|
@@ -772,11 +766,10 @@ const logCommand = (escapedCommand, verboseInfo) => {
|
|
|
772
766
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/verbose/info.js
|
|
773
767
|
const getVerboseInfo = (verbose, escapedCommand, rawOptions) => {
|
|
774
768
|
validateVerbose(verbose);
|
|
775
|
-
const commandId = getCommandId(verbose);
|
|
776
769
|
return {
|
|
777
770
|
verbose,
|
|
778
771
|
escapedCommand,
|
|
779
|
-
commandId,
|
|
772
|
+
commandId: getCommandId(verbose),
|
|
780
773
|
rawOptions
|
|
781
774
|
};
|
|
782
775
|
};
|
|
@@ -803,8 +796,7 @@ const getDurationMs = (startTime) => Number(hrtime.bigint() - startTime) / 1e6;
|
|
|
803
796
|
const handleCommand = (filePath, rawArguments, rawOptions) => {
|
|
804
797
|
const startTime = getStartTime();
|
|
805
798
|
const { command, escapedCommand } = joinCommand(filePath, rawArguments);
|
|
806
|
-
const
|
|
807
|
-
const verboseInfo = getVerboseInfo(verbose, escapedCommand, { ...rawOptions });
|
|
799
|
+
const verboseInfo = getVerboseInfo(normalizeFdSpecificOption(rawOptions, "verbose"), escapedCommand, { ...rawOptions });
|
|
808
800
|
logCommand(escapedCommand, verboseInfo);
|
|
809
801
|
return {
|
|
810
802
|
command,
|
|
@@ -954,8 +946,7 @@ var require_which = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/which
|
|
|
954
946
|
const ppRaw = pathEnv[i$2];
|
|
955
947
|
const pathPart = /^".*"$/.test(ppRaw) ? ppRaw.slice(1, -1) : ppRaw;
|
|
956
948
|
const pCmd = path$11.join(pathPart, cmd);
|
|
957
|
-
|
|
958
|
-
resolve(subStep(p, i$2, 0));
|
|
949
|
+
resolve(subStep(!pathPart && /^\.[\\\/]/.test(cmd) ? cmd.slice(0, 2) + pCmd : pCmd, i$2, 0));
|
|
959
950
|
});
|
|
960
951
|
const subStep = (p, i$2, ii) => new Promise((resolve, reject) => {
|
|
961
952
|
if (ii === pathExt.length) return resolve(step(i$2 + 1));
|
|
@@ -1283,9 +1274,7 @@ const npmRunPathEnv = ({ env: env$1 = process$1.env,...options } = {}) => {
|
|
|
1283
1274
|
//#endregion
|
|
1284
1275
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/return/final-error.js
|
|
1285
1276
|
const getFinalError = (originalError, message, isSync) => {
|
|
1286
|
-
|
|
1287
|
-
const options = originalError instanceof DiscardedError ? {} : { cause: originalError };
|
|
1288
|
-
return new ErrorClass(message, options);
|
|
1277
|
+
return new (isSync ? ExecaSyncError : ExecaError)(message, originalError instanceof DiscardedError ? {} : { cause: originalError });
|
|
1289
1278
|
};
|
|
1290
1279
|
var DiscardedError = class extends Error {};
|
|
1291
1280
|
const setErrorName = (ErrorClass, value) => {
|
|
@@ -2023,8 +2012,7 @@ const isConnected = (anyProcess) => {
|
|
|
2023
2012
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/ipc/strict.js
|
|
2024
2013
|
const handleSendStrict = ({ anyProcess, channel, isSubprocess, message, strict }) => {
|
|
2025
2014
|
if (!strict) return message;
|
|
2026
|
-
const
|
|
2027
|
-
const hasListeners = hasMessageListeners(anyProcess, ipcEmitter);
|
|
2015
|
+
const hasListeners = hasMessageListeners(anyProcess, getIpcEmitter(anyProcess, channel, isSubprocess));
|
|
2028
2016
|
return {
|
|
2029
2017
|
id: count++,
|
|
2030
2018
|
type: REQUEST_TYPE,
|
|
@@ -2097,11 +2085,9 @@ const RESPONSE_TYPE = "execa:ipc:response";
|
|
|
2097
2085
|
const startSendMessage = (anyProcess, wrappedMessage, strict) => {
|
|
2098
2086
|
if (!OUTGOING_MESSAGES.has(anyProcess)) OUTGOING_MESSAGES.set(anyProcess, /* @__PURE__ */ new Set());
|
|
2099
2087
|
const outgoingMessages = OUTGOING_MESSAGES.get(anyProcess);
|
|
2100
|
-
const onMessageSent = createDeferred();
|
|
2101
|
-
const id = strict ? wrappedMessage.id : void 0;
|
|
2102
2088
|
const outgoingMessage = {
|
|
2103
|
-
onMessageSent,
|
|
2104
|
-
id
|
|
2089
|
+
onMessageSent: createDeferred(),
|
|
2090
|
+
id: strict ? wrappedMessage.id : void 0
|
|
2105
2091
|
};
|
|
2106
2092
|
outgoingMessages.add(outgoingMessage);
|
|
2107
2093
|
return {
|
|
@@ -2262,8 +2248,7 @@ const throwOnGracefulCancel = ({ subprocess, cancelSignal, gracefulCancel, force
|
|
|
2262
2248
|
})] : [];
|
|
2263
2249
|
const sendOnAbort = async ({ subprocess, cancelSignal, forceKillAfterDelay, context, controller: { signal } }) => {
|
|
2264
2250
|
await onAbortedSignal(cancelSignal, signal);
|
|
2265
|
-
|
|
2266
|
-
await sendAbort(subprocess, reason);
|
|
2251
|
+
await sendAbort(subprocess, getReason(cancelSignal));
|
|
2267
2252
|
killOnTimeout({
|
|
2268
2253
|
kill: subprocess.kill,
|
|
2269
2254
|
forceKillAfterDelay,
|
|
@@ -2437,8 +2422,7 @@ const normalizeOptions = (filePath, rawArguments, rawOptions) => {
|
|
|
2437
2422
|
rawOptions.cwd = normalizeCwd(rawOptions.cwd);
|
|
2438
2423
|
const [processedFile, processedArguments, processedOptions] = handleNodeOption(filePath, rawArguments, rawOptions);
|
|
2439
2424
|
const { command: file, args: commandArguments, options: initialOptions } = import_cross_spawn.default._parse(processedFile, processedArguments, processedOptions);
|
|
2440
|
-
const
|
|
2441
|
-
const options = addDefaultOptions(fdOptions);
|
|
2425
|
+
const options = addDefaultOptions(normalizeFdSpecificOptions(initialOptions));
|
|
2442
2426
|
validateTimeout(options);
|
|
2443
2427
|
validateEncoding(options);
|
|
2444
2428
|
validateIpcInputOption(options);
|
|
@@ -2607,7 +2591,7 @@ const u = Object.create(a, {
|
|
|
2607
2591
|
}
|
|
2608
2592
|
});
|
|
2609
2593
|
function h({ preventCancel: r = !1 } = {}) {
|
|
2610
|
-
const
|
|
2594
|
+
const t = new c(this.getReader(), r), s = Object.create(u);
|
|
2611
2595
|
return s[n] = t, s;
|
|
2612
2596
|
}
|
|
2613
2597
|
|
|
@@ -2656,18 +2640,14 @@ const getStreamContents$1 = async (stream, { init, convertChunk, getSize, trunca
|
|
|
2656
2640
|
const state = init();
|
|
2657
2641
|
state.length = 0;
|
|
2658
2642
|
try {
|
|
2659
|
-
for await (const chunk of asyncIterable) {
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
addChunk,
|
|
2668
|
-
maxBuffer
|
|
2669
|
-
});
|
|
2670
|
-
}
|
|
2643
|
+
for await (const chunk of asyncIterable) appendChunk({
|
|
2644
|
+
convertedChunk: convertChunk[getChunkType(chunk)](chunk, state),
|
|
2645
|
+
state,
|
|
2646
|
+
getSize,
|
|
2647
|
+
truncateChunk,
|
|
2648
|
+
addChunk,
|
|
2649
|
+
maxBuffer
|
|
2650
|
+
});
|
|
2671
2651
|
appendFinalChunk({
|
|
2672
2652
|
state,
|
|
2673
2653
|
convertChunk,
|
|
@@ -2857,10 +2837,9 @@ const stringMethods = {
|
|
|
2857
2837
|
const handleMaxBuffer = ({ error, stream, readableObjectMode, lines, encoding, fdNumber }) => {
|
|
2858
2838
|
if (!(error instanceof MaxBufferError)) throw error;
|
|
2859
2839
|
if (fdNumber === "all") return error;
|
|
2860
|
-
const unit = getMaxBufferUnit(readableObjectMode, lines, encoding);
|
|
2861
2840
|
error.maxBufferInfo = {
|
|
2862
2841
|
fdNumber,
|
|
2863
|
-
unit
|
|
2842
|
+
unit: getMaxBufferUnit(readableObjectMode, lines, encoding)
|
|
2864
2843
|
};
|
|
2865
2844
|
stream.destroy();
|
|
2866
2845
|
throw error;
|
|
@@ -2930,19 +2909,16 @@ const createMessages = ({ stdio, all, ipcOutput, originalError, signal, signalDe
|
|
|
2930
2909
|
killSignal
|
|
2931
2910
|
});
|
|
2932
2911
|
const originalMessage = getOriginalMessage(originalError, cwd$1);
|
|
2933
|
-
const
|
|
2934
|
-
const shortMessage = `${prefix}: ${escapedCommand}${suffix}`;
|
|
2935
|
-
const messageStdio = all === void 0 ? [stdio[2], stdio[1]] : [all];
|
|
2936
|
-
const message = [
|
|
2937
|
-
shortMessage,
|
|
2938
|
-
...messageStdio,
|
|
2939
|
-
...stdio.slice(3),
|
|
2940
|
-
ipcOutput.map((ipcMessage) => serializeIpcMessage(ipcMessage)).join("\n")
|
|
2941
|
-
].map((messagePart) => escapeLines(stripFinalNewline(serializeMessagePart(messagePart)))).filter(Boolean).join("\n\n");
|
|
2912
|
+
const shortMessage = `${prefix}: ${escapedCommand}${originalMessage === void 0 ? "" : `\n${originalMessage}`}`;
|
|
2942
2913
|
return {
|
|
2943
2914
|
originalMessage,
|
|
2944
2915
|
shortMessage,
|
|
2945
|
-
message
|
|
2916
|
+
message: [
|
|
2917
|
+
shortMessage,
|
|
2918
|
+
...all === void 0 ? [stdio[2], stdio[1]] : [all],
|
|
2919
|
+
...stdio.slice(3),
|
|
2920
|
+
ipcOutput.map((ipcMessage) => serializeIpcMessage(ipcMessage)).join("\n")
|
|
2921
|
+
].map((messagePart) => escapeLines(stripFinalNewline(serializeMessagePart(messagePart)))).filter(Boolean).join("\n\n")
|
|
2946
2922
|
};
|
|
2947
2923
|
};
|
|
2948
2924
|
const getErrorPrefix = ({ originalError, timedOut, timeout, isMaxBuffer, maxBuffer, errorCode, signal, signalDescription, exitCode, isCanceled, isGracefullyCanceled, isForcefullyTerminated, forceKillAfterDelay, killSignal }) => {
|
|
@@ -2963,8 +2939,7 @@ const getErrorPrefix = ({ originalError, timedOut, timeout, isMaxBuffer, maxBuff
|
|
|
2963
2939
|
const getForcefulSuffix = (isForcefullyTerminated, forceKillAfterDelay) => isForcefullyTerminated ? ` and was forcefully terminated after ${forceKillAfterDelay} milliseconds` : "";
|
|
2964
2940
|
const getOriginalMessage = (originalError, cwd$1) => {
|
|
2965
2941
|
if (originalError instanceof DiscardedError) return;
|
|
2966
|
-
const
|
|
2967
|
-
const escapedOriginalMessage = escapeLines(fixCwdError(originalMessage, cwd$1));
|
|
2942
|
+
const escapedOriginalMessage = escapeLines(fixCwdError(isExecaError(originalError) ? originalError.originalMessage : String(originalError?.message ?? originalError), cwd$1));
|
|
2968
2943
|
return escapedOriginalMessage === "" ? void 0 : escapedOriginalMessage;
|
|
2969
2944
|
};
|
|
2970
2945
|
const serializeIpcMessage = (ipcMessage) => typeof ipcMessage === "string" ? ipcMessage : inspect(ipcMessage);
|
|
@@ -3086,11 +3061,10 @@ const omitUndefinedProperties = (result) => Object.fromEntries(Object.entries(re
|
|
|
3086
3061
|
const normalizeExitPayload = (rawExitCode, rawSignal) => {
|
|
3087
3062
|
const exitCode = rawExitCode === null ? void 0 : rawExitCode;
|
|
3088
3063
|
const signal = rawSignal === null ? void 0 : rawSignal;
|
|
3089
|
-
const signalDescription = signal === void 0 ? void 0 : getSignalDescription(rawSignal);
|
|
3090
3064
|
return {
|
|
3091
3065
|
exitCode,
|
|
3092
3066
|
signal,
|
|
3093
|
-
signalDescription
|
|
3067
|
+
signalDescription: signal === void 0 ? void 0 : getSignalDescription(rawSignal)
|
|
3094
3068
|
};
|
|
3095
3069
|
};
|
|
3096
3070
|
|
|
@@ -3196,9 +3170,7 @@ function prettyMilliseconds(milliseconds, options) {
|
|
|
3196
3170
|
add(Number.parseFloat(millisecondsString), "millisecond", "ms", millisecondsString);
|
|
3197
3171
|
}
|
|
3198
3172
|
} else {
|
|
3199
|
-
const
|
|
3200
|
-
const secondsDecimalDigits = typeof options.secondsDecimalDigits === "number" ? options.secondsDecimalDigits : 1;
|
|
3201
|
-
const secondsFixed = floorDecimals(seconds, secondsDecimalDigits);
|
|
3173
|
+
const secondsFixed = floorDecimals((isBigInt ? Number(milliseconds % ONE_DAY_IN_MILLISECONDS) : milliseconds) / 1e3 % 60, typeof options.secondsDecimalDigits === "number" ? options.secondsDecimalDigits : 1);
|
|
3202
3174
|
const secondsString = options.keepDecimalsOnWholeSeconds ? secondsFixed : secondsFixed.replace(/\.0+$/, "");
|
|
3203
3175
|
add(Number.parseFloat(secondsString), "second", "s", secondsString);
|
|
3204
3176
|
}
|
|
@@ -3227,10 +3199,9 @@ const logResult = (result, verboseInfo) => {
|
|
|
3227
3199
|
logDuration(result, verboseInfo);
|
|
3228
3200
|
};
|
|
3229
3201
|
const logDuration = (result, verboseInfo) => {
|
|
3230
|
-
const verboseMessage = `(done in ${prettyMilliseconds(result.durationMs)})`;
|
|
3231
3202
|
verboseLog({
|
|
3232
3203
|
type: "duration",
|
|
3233
|
-
verboseMessage
|
|
3204
|
+
verboseMessage: `(done in ${prettyMilliseconds(result.durationMs)})`,
|
|
3234
3205
|
verboseInfo,
|
|
3235
3206
|
result
|
|
3236
3207
|
});
|
|
@@ -3364,10 +3335,9 @@ const getOutputObjectModes = (objectMode, index, newTransforms) => {
|
|
|
3364
3335
|
};
|
|
3365
3336
|
const getInputObjectModes = (objectMode, index, newTransforms) => {
|
|
3366
3337
|
const writableObjectMode = index === 0 ? objectMode === true : newTransforms[index - 1].value.readableObjectMode;
|
|
3367
|
-
const readableObjectMode = index !== newTransforms.length - 1 && (objectMode ?? writableObjectMode);
|
|
3368
3338
|
return {
|
|
3369
3339
|
writableObjectMode,
|
|
3370
|
-
readableObjectMode
|
|
3340
|
+
readableObjectMode: index !== newTransforms.length - 1 && (objectMode ?? writableObjectMode)
|
|
3371
3341
|
};
|
|
3372
3342
|
};
|
|
3373
3343
|
const getFdObjectMode = (stdioItems, direction) => {
|
|
@@ -3676,8 +3646,7 @@ const validateDuplicateStreamSync = ({ otherStdioItems, type, value, optionName,
|
|
|
3676
3646
|
const getDuplicateStreamInstance = ({ otherStdioItems, type, value, optionName, direction }) => {
|
|
3677
3647
|
const duplicateStdioItems = otherStdioItems.filter((stdioItem) => hasSameValue(stdioItem, value));
|
|
3678
3648
|
if (duplicateStdioItems.length === 0) return;
|
|
3679
|
-
|
|
3680
|
-
throwOnDuplicateStream(differentStdioItem, optionName, type);
|
|
3649
|
+
throwOnDuplicateStream(duplicateStdioItems.find((stdioItem) => stdioItem.direction !== direction), optionName, type);
|
|
3681
3650
|
return direction === "output" ? duplicateStdioItems[0].stream : void 0;
|
|
3682
3651
|
};
|
|
3683
3652
|
const hasSameValue = ({ type, value }, secondValue) => {
|
|
@@ -3686,8 +3655,7 @@ const hasSameValue = ({ type, value }, secondValue) => {
|
|
|
3686
3655
|
return value === secondValue;
|
|
3687
3656
|
};
|
|
3688
3657
|
const validateDuplicateTransform = ({ otherStdioItems, type, value, optionName }) => {
|
|
3689
|
-
|
|
3690
|
-
throwOnDuplicateStream(duplicateStdioItem, optionName, type);
|
|
3658
|
+
throwOnDuplicateStream(otherStdioItems.find(({ value: { transform: transform$1 } }) => transform$1 === value.transform), optionName, type);
|
|
3691
3659
|
};
|
|
3692
3660
|
const throwOnDuplicateStream = (stdioItem, optionName, type) => {
|
|
3693
3661
|
if (stdioItem !== void 0) throw new TypeError(`The \`${stdioItem.optionName}\` and \`${optionName}\` options must not target ${TYPE_TO_MESSAGE[type]} that is the same.`);
|
|
@@ -3696,14 +3664,13 @@ const throwOnDuplicateStream = (stdioItem, optionName, type) => {
|
|
|
3696
3664
|
//#endregion
|
|
3697
3665
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/stdio/handle.js
|
|
3698
3666
|
const handleStdio = (addProperties$2, options, verboseInfo, isSync) => {
|
|
3699
|
-
const initialFileDescriptors = normalizeStdioOption(options, verboseInfo, isSync).map((stdioOption, fdNumber) => getFileDescriptor({
|
|
3700
|
-
stdioOption,
|
|
3701
|
-
fdNumber,
|
|
3702
|
-
options,
|
|
3703
|
-
isSync
|
|
3704
|
-
}));
|
|
3705
3667
|
const fileDescriptors = getFinalFileDescriptors({
|
|
3706
|
-
initialFileDescriptors,
|
|
3668
|
+
initialFileDescriptors: normalizeStdioOption(options, verboseInfo, isSync).map((stdioOption, fdNumber) => getFileDescriptor({
|
|
3669
|
+
stdioOption,
|
|
3670
|
+
fdNumber,
|
|
3671
|
+
options,
|
|
3672
|
+
isSync
|
|
3673
|
+
})),
|
|
3707
3674
|
addProperties: addProperties$2,
|
|
3708
3675
|
options,
|
|
3709
3676
|
isSync
|
|
@@ -3720,14 +3687,13 @@ const getFileDescriptor = ({ stdioOption, fdNumber, options, isSync }) => {
|
|
|
3720
3687
|
optionName
|
|
3721
3688
|
});
|
|
3722
3689
|
const direction = getStreamDirection(initialStdioItems, fdNumber, optionName);
|
|
3723
|
-
const
|
|
3690
|
+
const normalizedStdioItems = normalizeTransforms(initialStdioItems.map((stdioItem) => handleNativeStream({
|
|
3724
3691
|
stdioItem,
|
|
3725
3692
|
isStdioArray,
|
|
3726
3693
|
fdNumber,
|
|
3727
3694
|
direction,
|
|
3728
3695
|
isSync
|
|
3729
|
-
}));
|
|
3730
|
-
const normalizedStdioItems = normalizeTransforms(stdioItems, optionName, direction, options);
|
|
3696
|
+
})), optionName, direction, options);
|
|
3731
3697
|
const objectMode = getFdObjectMode(normalizedStdioItems, direction);
|
|
3732
3698
|
validateFileObjectMode(normalizedStdioItems, objectMode);
|
|
3733
3699
|
return {
|
|
@@ -3737,8 +3703,7 @@ const getFileDescriptor = ({ stdioOption, fdNumber, options, isSync }) => {
|
|
|
3737
3703
|
};
|
|
3738
3704
|
};
|
|
3739
3705
|
const initializeStdioItems = ({ stdioOption, fdNumber, options, optionName }) => {
|
|
3740
|
-
const
|
|
3741
|
-
const stdioItems = filterDuplicates(initialStdioItems);
|
|
3706
|
+
const stdioItems = filterDuplicates([...(Array.isArray(stdioOption) ? stdioOption : [stdioOption]).map((value) => initializeStdioItem(value, optionName)), ...handleInputOptions(options, fdNumber)]);
|
|
3742
3707
|
const isStdioArray = stdioItems.length > 1;
|
|
3743
3708
|
validateStdioArray(stdioItems, isStdioArray, optionName);
|
|
3744
3709
|
validateStreams(stdioItems);
|
|
@@ -3788,18 +3753,17 @@ const getFinalFileDescriptors = ({ initialFileDescriptors, addProperties: addPro
|
|
|
3788
3753
|
}
|
|
3789
3754
|
};
|
|
3790
3755
|
const getFinalFileDescriptor = ({ fileDescriptor: { direction, objectMode, stdioItems }, fileDescriptors, addProperties: addProperties$2, options, isSync }) => {
|
|
3791
|
-
const finalStdioItems = stdioItems.map((stdioItem) => addStreamProperties({
|
|
3792
|
-
stdioItem,
|
|
3793
|
-
addProperties: addProperties$2,
|
|
3794
|
-
direction,
|
|
3795
|
-
options,
|
|
3796
|
-
fileDescriptors,
|
|
3797
|
-
isSync
|
|
3798
|
-
}));
|
|
3799
3756
|
return {
|
|
3800
3757
|
direction,
|
|
3801
3758
|
objectMode,
|
|
3802
|
-
stdioItems:
|
|
3759
|
+
stdioItems: stdioItems.map((stdioItem) => addStreamProperties({
|
|
3760
|
+
stdioItem,
|
|
3761
|
+
addProperties: addProperties$2,
|
|
3762
|
+
direction,
|
|
3763
|
+
options,
|
|
3764
|
+
fileDescriptors,
|
|
3765
|
+
isSync
|
|
3766
|
+
}))
|
|
3803
3767
|
};
|
|
3804
3768
|
};
|
|
3805
3769
|
const addStreamProperties = ({ stdioItem, addProperties: addProperties$2, direction, options, fileDescriptors, isSync }) => {
|
|
@@ -4095,10 +4059,7 @@ const generatorToStream = ({ value, value: { transform: transform$1, final, writ
|
|
|
4095
4059
|
const runGeneratorsSync = (chunks, stdioItems, encoding, isInput) => {
|
|
4096
4060
|
const generators = stdioItems.filter(({ type }) => type === "generator");
|
|
4097
4061
|
const reversedGenerators = isInput ? generators.reverse() : generators;
|
|
4098
|
-
for (const { value, optionName } of reversedGenerators)
|
|
4099
|
-
const generators$1 = addInternalGenerators(value, encoding, optionName);
|
|
4100
|
-
chunks = runTransformSync(generators$1, chunks);
|
|
4101
|
-
}
|
|
4062
|
+
for (const { value, optionName } of reversedGenerators) chunks = runTransformSync(addInternalGenerators(value, encoding, optionName), chunks);
|
|
4102
4063
|
return chunks;
|
|
4103
4064
|
};
|
|
4104
4065
|
const addInternalGenerators = ({ transform: transform$1, final, binary, writableObjectMode, readableObjectMode, preserveNewlines }, encoding, optionName) => {
|
|
@@ -4135,8 +4096,7 @@ const addInputOptionSync = (fileDescriptors, fdNumber, options) => {
|
|
|
4135
4096
|
const [{ type, optionName }] = allStdioItems;
|
|
4136
4097
|
throw new TypeError(`Only the \`stdin\` option, not \`${optionName}\`, can be ${TYPE_TO_MESSAGE[type]} with synchronous methods.`);
|
|
4137
4098
|
}
|
|
4138
|
-
|
|
4139
|
-
options.input = joinToUint8Array(transformedContents);
|
|
4099
|
+
options.input = joinToUint8Array(allStdioItems.map(({ contents }) => contents).map((contents) => applySingleInputGeneratorsSync(contents, stdioItems)));
|
|
4140
4100
|
};
|
|
4141
4101
|
const applySingleInputGeneratorsSync = (contents, stdioItems) => {
|
|
4142
4102
|
const newContents = runGeneratorsSync(contents, stdioItems, "utf8", true);
|
|
@@ -4161,10 +4121,9 @@ const logLinesSync = (linesArray, fdNumber, verboseInfo) => {
|
|
|
4161
4121
|
};
|
|
4162
4122
|
const isPipingStream = (stream) => stream._readableState.pipes.length > 0;
|
|
4163
4123
|
const logLine = (line, fdNumber, verboseInfo) => {
|
|
4164
|
-
const verboseMessage = serializeVerboseMessage(line);
|
|
4165
4124
|
verboseLog({
|
|
4166
4125
|
type: "output",
|
|
4167
|
-
verboseMessage,
|
|
4126
|
+
verboseMessage: serializeVerboseMessage(line),
|
|
4168
4127
|
fdNumber,
|
|
4169
4128
|
verboseInfo
|
|
4170
4129
|
});
|
|
@@ -4191,12 +4150,10 @@ const transformOutputSync = ({ fileDescriptors, syncResult: { output }, options,
|
|
|
4191
4150
|
};
|
|
4192
4151
|
const transformOutputResultSync = ({ result, fileDescriptors, fdNumber, state, outputFiles, isMaxBuffer, verboseInfo }, { buffer, encoding, lines, stripFinalNewline: stripFinalNewline$1, maxBuffer }) => {
|
|
4193
4152
|
if (result === null) return;
|
|
4194
|
-
const
|
|
4195
|
-
const uint8ArrayResult = bufferToUint8Array(truncatedResult);
|
|
4153
|
+
const uint8ArrayResult = bufferToUint8Array(truncateMaxBufferSync(result, isMaxBuffer, maxBuffer));
|
|
4196
4154
|
const { stdioItems, objectMode } = fileDescriptors[fdNumber];
|
|
4197
|
-
const chunks = runOutputGeneratorsSync([uint8ArrayResult], stdioItems, encoding, state);
|
|
4198
4155
|
const { serializedResult, finalResult = serializedResult } = serializeChunks({
|
|
4199
|
-
chunks,
|
|
4156
|
+
chunks: runOutputGeneratorsSync([uint8ArrayResult], stdioItems, encoding, state),
|
|
4200
4157
|
objectMode,
|
|
4201
4158
|
encoding,
|
|
4202
4159
|
lines,
|
|
@@ -4307,14 +4264,12 @@ const isFailedExit = (exitCode, signal) => exitCode !== 0 || signal !== null;
|
|
|
4307
4264
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/resolve/exit-sync.js
|
|
4308
4265
|
const getExitResultSync = ({ error, status: exitCode, signal, output }, { maxBuffer }) => {
|
|
4309
4266
|
const resultError = getResultError(error, exitCode, signal);
|
|
4310
|
-
const timedOut = resultError?.code === "ETIMEDOUT";
|
|
4311
|
-
const isMaxBuffer = isMaxBufferSync(resultError, output, maxBuffer);
|
|
4312
4267
|
return {
|
|
4313
4268
|
resultError,
|
|
4314
4269
|
exitCode,
|
|
4315
4270
|
signal,
|
|
4316
|
-
timedOut,
|
|
4317
|
-
isMaxBuffer
|
|
4271
|
+
timedOut: resultError?.code === "ETIMEDOUT",
|
|
4272
|
+
isMaxBuffer: isMaxBufferSync(resultError, output, maxBuffer)
|
|
4318
4273
|
};
|
|
4319
4274
|
};
|
|
4320
4275
|
const getResultError = (error, exitCode, signal) => {
|
|
@@ -4326,7 +4281,7 @@ const getResultError = (error, exitCode, signal) => {
|
|
|
4326
4281
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/methods/main-sync.js
|
|
4327
4282
|
const execaCoreSync = (rawFile, rawArguments, rawOptions) => {
|
|
4328
4283
|
const { file, commandArguments, command, escapedCommand, startTime, verboseInfo, options, fileDescriptors } = handleSyncArguments(rawFile, rawArguments, rawOptions);
|
|
4329
|
-
|
|
4284
|
+
return handleResult(spawnSubprocessSync({
|
|
4330
4285
|
file,
|
|
4331
4286
|
commandArguments,
|
|
4332
4287
|
options,
|
|
@@ -4335,15 +4290,12 @@ const execaCoreSync = (rawFile, rawArguments, rawOptions) => {
|
|
|
4335
4290
|
verboseInfo,
|
|
4336
4291
|
fileDescriptors,
|
|
4337
4292
|
startTime
|
|
4338
|
-
});
|
|
4339
|
-
return handleResult(result, verboseInfo, options);
|
|
4293
|
+
}), verboseInfo, options);
|
|
4340
4294
|
};
|
|
4341
4295
|
const handleSyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
4342
4296
|
const { command, escapedCommand, startTime, verboseInfo } = handleCommand(rawFile, rawArguments, rawOptions);
|
|
4343
|
-
const
|
|
4344
|
-
const { file, commandArguments, options } = normalizeOptions(rawFile, rawArguments, syncOptions);
|
|
4297
|
+
const { file, commandArguments, options } = normalizeOptions(rawFile, rawArguments, normalizeSyncOptions(rawOptions));
|
|
4345
4298
|
validateSyncOptions(options);
|
|
4346
|
-
const fileDescriptors = handleStdioSync(options, verboseInfo);
|
|
4347
4299
|
return {
|
|
4348
4300
|
file,
|
|
4349
4301
|
commandArguments,
|
|
@@ -4352,7 +4304,7 @@ const handleSyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
|
4352
4304
|
startTime,
|
|
4353
4305
|
verboseInfo,
|
|
4354
4306
|
options,
|
|
4355
|
-
fileDescriptors
|
|
4307
|
+
fileDescriptors: handleStdioSync(options, verboseInfo)
|
|
4356
4308
|
};
|
|
4357
4309
|
};
|
|
4358
4310
|
const normalizeSyncOptions = (options) => options.node && !options.ipc ? {
|
|
@@ -4387,16 +4339,14 @@ const spawnSubprocessSync = ({ file, commandArguments, options, command, escaped
|
|
|
4387
4339
|
isMaxBuffer,
|
|
4388
4340
|
verboseInfo
|
|
4389
4341
|
});
|
|
4390
|
-
const stdio = output.map((stdioOutput, fdNumber) => stripNewline(stdioOutput, options, fdNumber));
|
|
4391
|
-
const all = stripNewline(getAllSync(output, options), options, "all");
|
|
4392
4342
|
return getSyncResult({
|
|
4393
4343
|
error,
|
|
4394
4344
|
exitCode,
|
|
4395
4345
|
signal,
|
|
4396
4346
|
timedOut,
|
|
4397
4347
|
isMaxBuffer,
|
|
4398
|
-
stdio,
|
|
4399
|
-
all,
|
|
4348
|
+
stdio: output.map((stdioOutput, fdNumber) => stripNewline(stdioOutput, options, fdNumber)),
|
|
4349
|
+
all: stripNewline(getAllSync(output, options), options, "all"),
|
|
4400
4350
|
options,
|
|
4401
4351
|
command,
|
|
4402
4352
|
escapedCommand,
|
|
@@ -4406,8 +4356,7 @@ const spawnSubprocessSync = ({ file, commandArguments, options, command, escaped
|
|
|
4406
4356
|
const runSubprocessSync = ({ file, commandArguments, options, command, escapedCommand, fileDescriptors, startTime }) => {
|
|
4407
4357
|
try {
|
|
4408
4358
|
addInputOptionsSync(fileDescriptors, options);
|
|
4409
|
-
|
|
4410
|
-
return spawnSync(...concatenateShell(file, commandArguments, normalizedOptions));
|
|
4359
|
+
return spawnSync(...concatenateShell(file, commandArguments, normalizeSpawnSyncOptions(options)));
|
|
4411
4360
|
} catch (error) {
|
|
4412
4361
|
return makeEarlyError({
|
|
4413
4362
|
error,
|
|
@@ -4625,19 +4574,17 @@ const handleEarlyError = ({ error, command, escapedCommand, fileDescriptors, opt
|
|
|
4625
4574
|
writable,
|
|
4626
4575
|
duplex
|
|
4627
4576
|
});
|
|
4628
|
-
const earlyError = makeEarlyError({
|
|
4629
|
-
error,
|
|
4630
|
-
command,
|
|
4631
|
-
escapedCommand,
|
|
4632
|
-
fileDescriptors,
|
|
4633
|
-
options,
|
|
4634
|
-
startTime,
|
|
4635
|
-
isSync: false
|
|
4636
|
-
});
|
|
4637
|
-
const promise = handleDummyPromise(earlyError, verboseInfo, options);
|
|
4638
4577
|
return {
|
|
4639
4578
|
subprocess,
|
|
4640
|
-
promise
|
|
4579
|
+
promise: handleDummyPromise(makeEarlyError({
|
|
4580
|
+
error,
|
|
4581
|
+
command,
|
|
4582
|
+
escapedCommand,
|
|
4583
|
+
fileDescriptors,
|
|
4584
|
+
options,
|
|
4585
|
+
startTime,
|
|
4586
|
+
isSync: false
|
|
4587
|
+
}), verboseInfo, options)
|
|
4641
4588
|
};
|
|
4642
4589
|
};
|
|
4643
4590
|
const createDummyStreams = (subprocess, fileDescriptors) => {
|
|
@@ -4932,10 +4879,7 @@ const pipeOutputAsync = (subprocess, fileDescriptors, controller) => {
|
|
|
4932
4879
|
controller
|
|
4933
4880
|
});
|
|
4934
4881
|
}
|
|
4935
|
-
for (const [outputStream, inputStreams] of pipeGroups.entries())
|
|
4936
|
-
const inputStream = inputStreams.length === 1 ? inputStreams[0] : mergeStreams(inputStreams);
|
|
4937
|
-
pipeStreams(inputStream, outputStream);
|
|
4938
|
-
}
|
|
4882
|
+
for (const [outputStream, inputStreams] of pipeGroups.entries()) pipeStreams(inputStreams.length === 1 ? inputStreams[0] : mergeStreams(inputStreams), outputStream);
|
|
4939
4883
|
};
|
|
4940
4884
|
const pipeTransform = (subprocess, stream, direction, fdNumber) => {
|
|
4941
4885
|
if (direction === "output") pipeStreams(subprocess.stdio[fdNumber], stream);
|
|
@@ -5197,10 +5141,9 @@ const normalizePipeArguments = ({ source, sourcePromise, boundOptions, createNes
|
|
|
5197
5141
|
const getDestinationStream = (boundOptions, createNested, pipeArguments) => {
|
|
5198
5142
|
try {
|
|
5199
5143
|
const { destination, pipeOptions: { from, to, unpipeSignal } = {} } = getDestination(boundOptions, createNested, ...pipeArguments);
|
|
5200
|
-
const destinationStream = getToStream(destination, to);
|
|
5201
5144
|
return {
|
|
5202
5145
|
destination,
|
|
5203
|
-
destinationStream,
|
|
5146
|
+
destinationStream: getToStream(destination, to),
|
|
5204
5147
|
from,
|
|
5205
5148
|
unpipeSignal
|
|
5206
5149
|
};
|
|
@@ -5435,13 +5378,12 @@ const stopReadingOnStreamEnd = async (onStreamEnd, controller, stream) => {
|
|
|
5435
5378
|
}
|
|
5436
5379
|
};
|
|
5437
5380
|
const iterateOnStream = ({ stream, controller, binary, shouldEncode, encoding, shouldSplit, preserveNewlines }) => {
|
|
5438
|
-
const onStdoutChunk = on(stream, "data", {
|
|
5439
|
-
signal: controller.signal,
|
|
5440
|
-
highWaterMark: HIGH_WATER_MARK,
|
|
5441
|
-
highWatermark: HIGH_WATER_MARK
|
|
5442
|
-
});
|
|
5443
5381
|
return iterateOnData({
|
|
5444
|
-
onStdoutChunk,
|
|
5382
|
+
onStdoutChunk: on(stream, "data", {
|
|
5383
|
+
signal: controller.signal,
|
|
5384
|
+
highWaterMark: HIGH_WATER_MARK,
|
|
5385
|
+
highWatermark: HIGH_WATER_MARK
|
|
5386
|
+
}),
|
|
5445
5387
|
controller,
|
|
5446
5388
|
binary,
|
|
5447
5389
|
shouldEncode,
|
|
@@ -5486,13 +5428,12 @@ const getStreamOutput = async ({ stream, onStreamEnd, fdNumber, encoding, buffer
|
|
|
5486
5428
|
await Promise.all([resumeStream(stream), logPromise]);
|
|
5487
5429
|
return;
|
|
5488
5430
|
}
|
|
5489
|
-
const stripFinalNewlineValue = getStripFinalNewline(stripFinalNewline$1, fdNumber);
|
|
5490
5431
|
const iterable = iterateForResult({
|
|
5491
5432
|
stream,
|
|
5492
5433
|
onStreamEnd,
|
|
5493
5434
|
lines,
|
|
5494
5435
|
encoding,
|
|
5495
|
-
stripFinalNewline:
|
|
5436
|
+
stripFinalNewline: getStripFinalNewline(stripFinalNewline$1, fdNumber),
|
|
5496
5437
|
allMixed
|
|
5497
5438
|
});
|
|
5498
5439
|
const [output] = await Promise.all([getStreamContents({
|
|
@@ -5512,15 +5453,14 @@ const logOutputAsync = async ({ stream, onStreamEnd, fdNumber, encoding, allMixe
|
|
|
5512
5453
|
verboseInfo,
|
|
5513
5454
|
fdNumber
|
|
5514
5455
|
})) return;
|
|
5515
|
-
|
|
5456
|
+
await logLines(iterateForResult({
|
|
5516
5457
|
stream,
|
|
5517
5458
|
onStreamEnd,
|
|
5518
5459
|
lines: true,
|
|
5519
5460
|
encoding,
|
|
5520
5461
|
stripFinalNewline: true,
|
|
5521
5462
|
allMixed
|
|
5522
|
-
});
|
|
5523
|
-
await logLines(linesIterable, stream, fdNumber, verboseInfo);
|
|
5463
|
+
}), stream, fdNumber, verboseInfo);
|
|
5524
5464
|
};
|
|
5525
5465
|
const resumeStream = async (stream) => {
|
|
5526
5466
|
await setImmediate$1();
|
|
@@ -5670,10 +5610,9 @@ const getAllMixed = ({ all, stdout, stderr }) => all && stdout && stderr && stdo
|
|
|
5670
5610
|
//#region ../../node_modules/.pnpm/execa@9.6.0/node_modules/execa/lib/verbose/ipc.js
|
|
5671
5611
|
const shouldLogIpc = (verboseInfo) => isFullVerbose(verboseInfo, "ipc");
|
|
5672
5612
|
const logIpcOutput = (message, verboseInfo) => {
|
|
5673
|
-
const verboseMessage = serializeVerboseMessage(message);
|
|
5674
5613
|
verboseLog({
|
|
5675
5614
|
type: "ipc",
|
|
5676
|
-
verboseMessage,
|
|
5615
|
+
verboseMessage: serializeVerboseMessage(message),
|
|
5677
5616
|
fdNumber: "ipc",
|
|
5678
5617
|
verboseInfo
|
|
5679
5618
|
});
|
|
@@ -5898,10 +5837,9 @@ const createReadable = ({ subprocess, concurrentStreams, encoding }, { from, bin
|
|
|
5898
5837
|
};
|
|
5899
5838
|
const getSubprocessStdout = (subprocess, from, concurrentStreams) => {
|
|
5900
5839
|
const subprocessStdout = getFromStream(subprocess, from);
|
|
5901
|
-
const waitReadableDestroy = addConcurrentStream(concurrentStreams, subprocessStdout, "readableDestroy");
|
|
5902
5840
|
return {
|
|
5903
5841
|
subprocessStdout,
|
|
5904
|
-
waitReadableDestroy
|
|
5842
|
+
waitReadableDestroy: addConcurrentStream(concurrentStreams, subprocessStdout, "readableDestroy")
|
|
5905
5843
|
};
|
|
5906
5844
|
};
|
|
5907
5845
|
const getReadableOptions = ({ readableEncoding, readableObjectMode, readableHighWaterMark }, binary) => binary ? {
|
|
@@ -5979,12 +5917,10 @@ const createWritable = ({ subprocess, concurrentStreams }, { to } = {}) => {
|
|
|
5979
5917
|
};
|
|
5980
5918
|
const getSubprocessStdin = (subprocess, to, concurrentStreams) => {
|
|
5981
5919
|
const subprocessStdin = getToStream(subprocess, to);
|
|
5982
|
-
const waitWritableFinal = addConcurrentStream(concurrentStreams, subprocessStdin, "writableFinal");
|
|
5983
|
-
const waitWritableDestroy = addConcurrentStream(concurrentStreams, subprocessStdin, "writableDestroy");
|
|
5984
5920
|
return {
|
|
5985
5921
|
subprocessStdin,
|
|
5986
|
-
waitWritableFinal,
|
|
5987
|
-
waitWritableDestroy
|
|
5922
|
+
waitWritableFinal: addConcurrentStream(concurrentStreams, subprocessStdin, "writableFinal"),
|
|
5923
|
+
waitWritableDestroy: addConcurrentStream(concurrentStreams, subprocessStdin, "writableDestroy")
|
|
5988
5924
|
};
|
|
5989
5925
|
};
|
|
5990
5926
|
const getWritableMethods = (subprocessStdin, subprocess, waitWritableFinal) => ({
|
|
@@ -6080,15 +6016,14 @@ const onDuplexDestroy = async ({ subprocessStdout, subprocessStdin, subprocess,
|
|
|
6080
6016
|
const createIterable = (subprocess, encoding, { from, binary: binaryOption = false, preserveNewlines = false } = {}) => {
|
|
6081
6017
|
const binary = binaryOption || BINARY_ENCODINGS.has(encoding);
|
|
6082
6018
|
const subprocessStdout = getFromStream(subprocess, from);
|
|
6083
|
-
|
|
6019
|
+
return iterateOnStdoutData(iterateOnSubprocessStream({
|
|
6084
6020
|
subprocessStdout,
|
|
6085
6021
|
subprocess,
|
|
6086
6022
|
binary,
|
|
6087
6023
|
shouldEncode: true,
|
|
6088
6024
|
encoding,
|
|
6089
6025
|
preserveNewlines
|
|
6090
|
-
});
|
|
6091
|
-
return iterateOnStdoutData(onStdoutData, subprocessStdout, subprocess);
|
|
6026
|
+
}), subprocessStdout, subprocess);
|
|
6092
6027
|
};
|
|
6093
6028
|
const iterateOnStdoutData = async function* (onStdoutData, subprocessStdout, subprocess) {
|
|
6094
6029
|
try {
|
|
@@ -6170,7 +6105,6 @@ const handleAsyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
|
6170
6105
|
const { command, escapedCommand, startTime, verboseInfo } = handleCommand(rawFile, rawArguments, rawOptions);
|
|
6171
6106
|
const { file, commandArguments, options: normalizedOptions } = normalizeOptions(rawFile, rawArguments, rawOptions);
|
|
6172
6107
|
const options = handleAsyncOptions(normalizedOptions);
|
|
6173
|
-
const fileDescriptors = handleStdioAsync(options, verboseInfo);
|
|
6174
6108
|
return {
|
|
6175
6109
|
file,
|
|
6176
6110
|
commandArguments,
|
|
@@ -6179,7 +6113,7 @@ const handleAsyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
|
6179
6113
|
startTime,
|
|
6180
6114
|
verboseInfo,
|
|
6181
6115
|
options,
|
|
6182
|
-
fileDescriptors
|
|
6116
|
+
fileDescriptors: handleStdioAsync(options, verboseInfo)
|
|
6183
6117
|
};
|
|
6184
6118
|
};
|
|
6185
6119
|
const handleAsyncOptions = ({ timeout, signal,...options }) => {
|
|
@@ -6252,22 +6186,19 @@ const handlePromise = async ({ subprocess, options, startTime, verboseInfo, file
|
|
|
6252
6186
|
});
|
|
6253
6187
|
controller.abort();
|
|
6254
6188
|
onInternalError.resolve();
|
|
6255
|
-
|
|
6256
|
-
const all = stripNewline(allResult, options, "all");
|
|
6257
|
-
const result = getAsyncResult({
|
|
6189
|
+
return handleResult(getAsyncResult({
|
|
6258
6190
|
errorInfo,
|
|
6259
6191
|
exitCode,
|
|
6260
6192
|
signal,
|
|
6261
|
-
stdio,
|
|
6262
|
-
all,
|
|
6193
|
+
stdio: stdioResults.map((stdioResult, fdNumber) => stripNewline(stdioResult, options, fdNumber)),
|
|
6194
|
+
all: stripNewline(allResult, options, "all"),
|
|
6263
6195
|
ipcOutput,
|
|
6264
6196
|
context,
|
|
6265
6197
|
options,
|
|
6266
6198
|
command,
|
|
6267
6199
|
escapedCommand,
|
|
6268
6200
|
startTime
|
|
6269
|
-
});
|
|
6270
|
-
return handleResult(result, verboseInfo, options);
|
|
6201
|
+
}), verboseInfo, options);
|
|
6271
6202
|
};
|
|
6272
6203
|
const getAsyncResult = ({ errorInfo, exitCode, signal, stdio, all, ipcOutput, context, options, command, escapedCommand, startTime }) => "error" in errorInfo ? makeError({
|
|
6273
6204
|
error: errorInfo.error,
|
|
@@ -6340,8 +6271,7 @@ const callBoundExeca = ({ mapArguments, deepOptions = {}, boundOptions = {}, set
|
|
|
6340
6271
|
return isSync ? execaCoreSync(file, commandArguments, options) : execaCoreAsync(file, commandArguments, options, createNested);
|
|
6341
6272
|
};
|
|
6342
6273
|
const parseArguments = ({ mapArguments, firstArgument, nextArguments, deepOptions, boundOptions }) => {
|
|
6343
|
-
const
|
|
6344
|
-
const [initialFile, initialArguments, initialOptions] = normalizeParameters(...callArguments);
|
|
6274
|
+
const [initialFile, initialArguments, initialOptions] = normalizeParameters(...isTemplateString(firstArgument) ? parseTemplates(firstArgument, nextArguments) : [firstArgument, ...nextArguments]);
|
|
6345
6275
|
const mergedOptions = mergeOptions(mergeOptions(deepOptions, boundOptions), initialOptions);
|
|
6346
6276
|
const { file = initialFile, commandArguments = initialArguments, options = mergedOptions, isSync = false } = mapArguments({
|
|
6347
6277
|
file: initialFile,
|
|
@@ -6429,11 +6359,11 @@ var require_p_limit = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/p-l
|
|
|
6429
6359
|
const pTry = require_p_try();
|
|
6430
6360
|
const pLimit$1 = (concurrency) => {
|
|
6431
6361
|
if (!((Number.isInteger(concurrency) || concurrency === Infinity) && concurrency > 0)) return Promise.reject(/* @__PURE__ */ new TypeError("Expected `concurrency` to be a number from 1 and up"));
|
|
6432
|
-
const queue
|
|
6362
|
+
const queue = [];
|
|
6433
6363
|
let activeCount = 0;
|
|
6434
6364
|
const next = () => {
|
|
6435
6365
|
activeCount--;
|
|
6436
|
-
if (queue
|
|
6366
|
+
if (queue.length > 0) queue.shift()();
|
|
6437
6367
|
};
|
|
6438
6368
|
const run = (fn, resolve, ...args) => {
|
|
6439
6369
|
activeCount++;
|
|
@@ -6443,14 +6373,14 @@ var require_p_limit = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/p-l
|
|
|
6443
6373
|
};
|
|
6444
6374
|
const enqueue$1 = (fn, resolve, ...args) => {
|
|
6445
6375
|
if (activeCount < concurrency) run(fn, resolve, ...args);
|
|
6446
|
-
else queue
|
|
6376
|
+
else queue.push(run.bind(null, fn, resolve, ...args));
|
|
6447
6377
|
};
|
|
6448
6378
|
const generator = (fn, ...args) => new Promise((resolve) => enqueue$1(fn, resolve, ...args));
|
|
6449
6379
|
Object.defineProperties(generator, {
|
|
6450
6380
|
activeCount: { get: () => activeCount },
|
|
6451
|
-
pendingCount: { get: () => queue
|
|
6381
|
+
pendingCount: { get: () => queue.length },
|
|
6452
6382
|
clearQueue: { value: () => {
|
|
6453
|
-
queue
|
|
6383
|
+
queue.length = 0;
|
|
6454
6384
|
} }
|
|
6455
6385
|
});
|
|
6456
6386
|
return generator;
|
|
@@ -7171,13 +7101,13 @@ var require_expand = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/brac
|
|
|
7171
7101
|
const fill = require_fill_range();
|
|
7172
7102
|
const stringify$2 = require_stringify();
|
|
7173
7103
|
const utils$4 = require_utils$1();
|
|
7174
|
-
const append = (queue
|
|
7104
|
+
const append = (queue = "", stash = "", enclose = false) => {
|
|
7175
7105
|
const result = [];
|
|
7176
|
-
queue
|
|
7106
|
+
queue = [].concat(queue);
|
|
7177
7107
|
stash = [].concat(stash);
|
|
7178
|
-
if (!stash.length) return queue
|
|
7179
|
-
if (!queue
|
|
7180
|
-
for (const item of queue
|
|
7108
|
+
if (!stash.length) return queue;
|
|
7109
|
+
if (!queue.length) return enclose ? utils$4.flatten(stash).map((ele) => `{${ele}}`) : stash;
|
|
7110
|
+
for (const item of queue) if (Array.isArray(item)) for (const value of item) result.push(append(value, stash, enclose));
|
|
7181
7111
|
else for (let ele of stash) {
|
|
7182
7112
|
if (enclose === true && typeof ele === "string") ele = `{${ele}}`;
|
|
7183
7113
|
result.push(Array.isArray(ele) ? append(item, ele, enclose) : item + ele);
|
|
@@ -7212,30 +7142,30 @@ var require_expand = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/brac
|
|
|
7212
7142
|
return;
|
|
7213
7143
|
}
|
|
7214
7144
|
const enclose = utils$4.encloseBrace(node);
|
|
7215
|
-
let queue
|
|
7145
|
+
let queue = node.queue;
|
|
7216
7146
|
let block = node;
|
|
7217
7147
|
while (block.type !== "brace" && block.type !== "root" && block.parent) {
|
|
7218
7148
|
block = block.parent;
|
|
7219
|
-
queue
|
|
7149
|
+
queue = block.queue;
|
|
7220
7150
|
}
|
|
7221
7151
|
for (let i$2 = 0; i$2 < node.nodes.length; i$2++) {
|
|
7222
7152
|
const child = node.nodes[i$2];
|
|
7223
7153
|
if (child.type === "comma" && node.type === "brace") {
|
|
7224
|
-
if (i$2 === 1) queue
|
|
7225
|
-
queue
|
|
7154
|
+
if (i$2 === 1) queue.push("");
|
|
7155
|
+
queue.push("");
|
|
7226
7156
|
continue;
|
|
7227
7157
|
}
|
|
7228
7158
|
if (child.type === "close") {
|
|
7229
|
-
q.push(append(q.pop(), queue
|
|
7159
|
+
q.push(append(q.pop(), queue, enclose));
|
|
7230
7160
|
continue;
|
|
7231
7161
|
}
|
|
7232
7162
|
if (child.value && child.type !== "open") {
|
|
7233
|
-
queue
|
|
7163
|
+
queue.push(append(queue.pop(), child.value));
|
|
7234
7164
|
continue;
|
|
7235
7165
|
}
|
|
7236
7166
|
if (child.nodes) walk(child, node);
|
|
7237
7167
|
}
|
|
7238
|
-
return queue
|
|
7168
|
+
return queue;
|
|
7239
7169
|
};
|
|
7240
7170
|
return utils$4.flatten(walk(ast));
|
|
7241
7171
|
};
|
|
@@ -7454,7 +7384,7 @@ var require_parse$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/bra
|
|
|
7454
7384
|
*/
|
|
7455
7385
|
if (value === CHAR_LEFT_CURLY_BRACE$1) {
|
|
7456
7386
|
depth$1++;
|
|
7457
|
-
|
|
7387
|
+
block = push({
|
|
7458
7388
|
type: "brace",
|
|
7459
7389
|
open: true,
|
|
7460
7390
|
close: false,
|
|
@@ -7463,8 +7393,7 @@ var require_parse$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/bra
|
|
|
7463
7393
|
commas: 0,
|
|
7464
7394
|
ranges: 0,
|
|
7465
7395
|
nodes: []
|
|
7466
|
-
};
|
|
7467
|
-
block = push(brace);
|
|
7396
|
+
});
|
|
7468
7397
|
stack.push(block);
|
|
7469
7398
|
push({
|
|
7470
7399
|
type: "open",
|
|
@@ -7728,12 +7657,6 @@ var require_constants = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/p
|
|
|
7728
7657
|
const END_ANCHOR = `(?:${SLASH_LITERAL}|$)`;
|
|
7729
7658
|
const START_ANCHOR = `(?:^|${SLASH_LITERAL})`;
|
|
7730
7659
|
const DOTS_SLASH = `${DOT_LITERAL}{1,2}${END_ANCHOR}`;
|
|
7731
|
-
const NO_DOT = `(?!${DOT_LITERAL})`;
|
|
7732
|
-
const NO_DOTS = `(?!${START_ANCHOR}${DOTS_SLASH})`;
|
|
7733
|
-
const NO_DOT_SLASH = `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`;
|
|
7734
|
-
const NO_DOTS_SLASH = `(?!${DOTS_SLASH})`;
|
|
7735
|
-
const QMARK_NO_DOT = `[^.${SLASH_LITERAL}]`;
|
|
7736
|
-
const STAR = `${QMARK}*?`;
|
|
7737
7660
|
const POSIX_CHARS = {
|
|
7738
7661
|
DOT_LITERAL,
|
|
7739
7662
|
PLUS_LITERAL,
|
|
@@ -7743,12 +7666,12 @@ var require_constants = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/p
|
|
|
7743
7666
|
QMARK,
|
|
7744
7667
|
END_ANCHOR,
|
|
7745
7668
|
DOTS_SLASH,
|
|
7746
|
-
NO_DOT
|
|
7747
|
-
NO_DOTS
|
|
7748
|
-
NO_DOT_SLASH,
|
|
7749
|
-
NO_DOTS_SLASH
|
|
7750
|
-
QMARK_NO_DOT
|
|
7751
|
-
STAR
|
|
7669
|
+
NO_DOT: `(?!${DOT_LITERAL})`,
|
|
7670
|
+
NO_DOTS: `(?!${START_ANCHOR}${DOTS_SLASH})`,
|
|
7671
|
+
NO_DOT_SLASH: `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`,
|
|
7672
|
+
NO_DOTS_SLASH: `(?!${DOTS_SLASH})`,
|
|
7673
|
+
QMARK_NO_DOT: `[^.${SLASH_LITERAL}]`,
|
|
7674
|
+
STAR: `${QMARK}*?`,
|
|
7752
7675
|
START_ANCHOR
|
|
7753
7676
|
};
|
|
7754
7677
|
/**
|
|
@@ -7920,9 +7843,7 @@ var require_utils = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/picom
|
|
|
7920
7843
|
return output;
|
|
7921
7844
|
};
|
|
7922
7845
|
exports.wrapOutput = (input, state = {}, options = {}) => {
|
|
7923
|
-
|
|
7924
|
-
const append$1 = options.contains ? "" : "$";
|
|
7925
|
-
let output = `${prepend}(?:${input})${append$1}`;
|
|
7846
|
+
let output = `${options.contains ? "" : "^"}(?:${input})${options.contains ? "" : "$"}`;
|
|
7926
7847
|
if (state.negated === true) output = `(?:^(?!${output}).*$)`;
|
|
7927
7848
|
return output;
|
|
7928
7849
|
};
|
|
@@ -8268,13 +8189,13 @@ var require_parse = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/picom
|
|
|
8268
8189
|
const win32$1 = utils$2.isWindows(options);
|
|
8269
8190
|
const PLATFORM_CHARS = constants$3.globChars(win32$1);
|
|
8270
8191
|
const EXTGLOB_CHARS = constants$3.extglobChars(PLATFORM_CHARS);
|
|
8271
|
-
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
|
|
8192
|
+
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;
|
|
8272
8193
|
const globstar = (opts$1) => {
|
|
8273
8194
|
return `(${capture}(?:(?!${START_ANCHOR$1}${opts$1.dot ? DOTS_SLASH$1 : DOT_LITERAL$1}).)*?)`;
|
|
8274
8195
|
};
|
|
8275
|
-
const nodot = opts.dot ? "" : NO_DOT
|
|
8276
|
-
const qmarkNoDot = opts.dot ? QMARK$1 : QMARK_NO_DOT
|
|
8277
|
-
let star = opts.bash === true ? globstar(opts) : STAR
|
|
8196
|
+
const nodot = opts.dot ? "" : NO_DOT;
|
|
8197
|
+
const qmarkNoDot = opts.dot ? QMARK$1 : QMARK_NO_DOT;
|
|
8198
|
+
let star = opts.bash === true ? globstar(opts) : STAR;
|
|
8278
8199
|
if (opts.capture) star = `(${star})`;
|
|
8279
8200
|
if (typeof opts.noext === "boolean") opts.noextglob = opts.noext;
|
|
8280
8201
|
const state = {
|
|
@@ -8494,8 +8415,7 @@ var require_parse = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/picom
|
|
|
8494
8415
|
if (inner.includes(":")) {
|
|
8495
8416
|
const idx = prev.value.lastIndexOf("[");
|
|
8496
8417
|
const pre = prev.value.slice(0, idx);
|
|
8497
|
-
const
|
|
8498
|
-
const posix = POSIX_REGEX_SOURCE[rest$1];
|
|
8418
|
+
const posix = POSIX_REGEX_SOURCE[prev.value.slice(idx + 2)];
|
|
8499
8419
|
if (posix) {
|
|
8500
8420
|
prev.value = pre + posix;
|
|
8501
8421
|
state.backtrack = true;
|
|
@@ -8763,7 +8683,7 @@ var require_parse = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/picom
|
|
|
8763
8683
|
push({
|
|
8764
8684
|
type: "qmark",
|
|
8765
8685
|
value,
|
|
8766
|
-
output: QMARK_NO_DOT
|
|
8686
|
+
output: QMARK_NO_DOT
|
|
8767
8687
|
});
|
|
8768
8688
|
continue;
|
|
8769
8689
|
}
|
|
@@ -8982,11 +8902,11 @@ var require_parse = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/picom
|
|
|
8982
8902
|
}
|
|
8983
8903
|
if (state.index === state.start || prev.type === "slash" || prev.type === "dot") {
|
|
8984
8904
|
if (prev.type === "dot") {
|
|
8985
|
-
state.output += NO_DOT_SLASH
|
|
8986
|
-
prev.output += NO_DOT_SLASH
|
|
8905
|
+
state.output += NO_DOT_SLASH;
|
|
8906
|
+
prev.output += NO_DOT_SLASH;
|
|
8987
8907
|
} else if (opts.dot === true) {
|
|
8988
|
-
state.output += NO_DOTS_SLASH
|
|
8989
|
-
prev.output += NO_DOTS_SLASH
|
|
8908
|
+
state.output += NO_DOTS_SLASH;
|
|
8909
|
+
prev.output += NO_DOTS_SLASH;
|
|
8990
8910
|
} else {
|
|
8991
8911
|
state.output += nodot;
|
|
8992
8912
|
prev.output += nodot;
|
|
@@ -9039,15 +8959,15 @@ var require_parse = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/picom
|
|
|
9039
8959
|
if (len > max) throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`);
|
|
9040
8960
|
input = REPLACEMENTS[input] || input;
|
|
9041
8961
|
const win32$1 = utils$2.isWindows(options);
|
|
9042
|
-
const { DOT_LITERAL: DOT_LITERAL$1, SLASH_LITERAL: SLASH_LITERAL$1, ONE_CHAR: ONE_CHAR$1, DOTS_SLASH: DOTS_SLASH$1, NO_DOT
|
|
9043
|
-
const nodot = opts.dot ? NO_DOTS
|
|
9044
|
-
const slashDot = opts.dot ? NO_DOTS_SLASH
|
|
8962
|
+
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$3.globChars(win32$1);
|
|
8963
|
+
const nodot = opts.dot ? NO_DOTS : NO_DOT;
|
|
8964
|
+
const slashDot = opts.dot ? NO_DOTS_SLASH : NO_DOT;
|
|
9045
8965
|
const capture = opts.capture ? "" : "?:";
|
|
9046
8966
|
const state = {
|
|
9047
8967
|
negated: false,
|
|
9048
8968
|
prefix: ""
|
|
9049
8969
|
};
|
|
9050
|
-
let star = opts.bash === true ? ".*?" : STAR
|
|
8970
|
+
let star = opts.bash === true ? ".*?" : STAR;
|
|
9051
8971
|
if (opts.capture) star = `(${star})`;
|
|
9052
8972
|
const globstar = (opts$1) => {
|
|
9053
8973
|
if (opts$1.noglobstar === true) return star;
|
|
@@ -9072,8 +8992,7 @@ var require_parse = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/picom
|
|
|
9072
8992
|
}
|
|
9073
8993
|
}
|
|
9074
8994
|
};
|
|
9075
|
-
|
|
9076
|
-
let source = create(output);
|
|
8995
|
+
let source = create(utils$2.removePrefix(input, state));
|
|
9077
8996
|
if (source && opts.strictSlashes !== true) source += `${SLASH_LITERAL$1}?`;
|
|
9078
8997
|
return source;
|
|
9079
8998
|
};
|
|
@@ -9800,8 +9719,7 @@ var require_core$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/find
|
|
|
9800
9719
|
let previous = null;
|
|
9801
9720
|
let current = initial;
|
|
9802
9721
|
do {
|
|
9803
|
-
|
|
9804
|
-
extractWorkspaces(manifest);
|
|
9722
|
+
extractWorkspaces(readPackageJSON(current));
|
|
9805
9723
|
let { done, found } = checkWorkspaces(current, initial);
|
|
9806
9724
|
if (done) return found;
|
|
9807
9725
|
previous = current;
|
|
@@ -9811,8 +9729,7 @@ var require_core$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/find
|
|
|
9811
9729
|
}
|
|
9812
9730
|
exports.findWorkspaceRoot = findWorkspaceRoot;
|
|
9813
9731
|
function checkWorkspaces(current, initial) {
|
|
9814
|
-
const
|
|
9815
|
-
const workspaces = extractWorkspaces(manifest);
|
|
9732
|
+
const workspaces = extractWorkspaces(readPackageJSON(current));
|
|
9816
9733
|
let done = false;
|
|
9817
9734
|
let found;
|
|
9818
9735
|
let relativePath;
|
|
@@ -10240,9 +10157,9 @@ var require_graceful_fs = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm
|
|
|
10240
10157
|
previousSymbol = "___graceful-fs.previous";
|
|
10241
10158
|
}
|
|
10242
10159
|
function noop() {}
|
|
10243
|
-
function publishQueue(context, queue
|
|
10160
|
+
function publishQueue(context, queue) {
|
|
10244
10161
|
Object.defineProperty(context, gracefulQueue, { get: function() {
|
|
10245
|
-
return queue
|
|
10162
|
+
return queue;
|
|
10246
10163
|
} });
|
|
10247
10164
|
}
|
|
10248
10165
|
var debug = noop;
|
|
@@ -10253,8 +10170,7 @@ var require_graceful_fs = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm
|
|
|
10253
10170
|
console.error(m);
|
|
10254
10171
|
};
|
|
10255
10172
|
if (!fs$3[gracefulQueue]) {
|
|
10256
|
-
|
|
10257
|
-
publishQueue(fs$3, queue);
|
|
10173
|
+
publishQueue(fs$3, global[gracefulQueue] || []);
|
|
10258
10174
|
fs$3.close = (function(fs$close) {
|
|
10259
10175
|
function close(fd, cb) {
|
|
10260
10176
|
return fs$close.call(fs$3, fd, function(err) {
|
|
@@ -10569,8 +10485,7 @@ var require_graceful_fs = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm
|
|
|
10569
10485
|
} else {
|
|
10570
10486
|
var sinceAttempt = Date.now() - lastTime;
|
|
10571
10487
|
var sinceStart = Math.max(lastTime - startTime, 1);
|
|
10572
|
-
|
|
10573
|
-
if (sinceAttempt >= desiredDelay) {
|
|
10488
|
+
if (sinceAttempt >= Math.min(sinceStart * 1.2, 100)) {
|
|
10574
10489
|
debug("RETRY", fn.name, args);
|
|
10575
10490
|
fn.apply(null, args.concat([startTime]));
|
|
10576
10491
|
} else fs$3[gracefulQueue].push(elem);
|
|
@@ -12234,8 +12149,7 @@ var require_esprima = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/esp
|
|
|
12234
12149
|
if (element.type === jsx_syntax_1.JSXSyntax.JSXClosingElement) {
|
|
12235
12150
|
el.closing = element;
|
|
12236
12151
|
var open_1 = getQualifiedElementName(el.opening.name);
|
|
12237
|
-
|
|
12238
|
-
if (open_1 !== close_1) this.tolerateError("Expected corresponding JSX closing tag for %0", open_1);
|
|
12152
|
+
if (open_1 !== getQualifiedElementName(el.closing.name)) this.tolerateError("Expected corresponding JSX closing tag for %0", open_1);
|
|
12239
12153
|
if (stack.length > 0) {
|
|
12240
12154
|
var child = this.finalize(el.node, new JSXNode.JSXElement(el.opening, el.children, el.closing));
|
|
12241
12155
|
el = stack[stack.length - 1];
|
|
@@ -13238,14 +13152,10 @@ var require_esprima = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/esp
|
|
|
13238
13152
|
column: this.scanner.index - this.scanner.lineStart
|
|
13239
13153
|
}
|
|
13240
13154
|
};
|
|
13241
|
-
if (token.type === 9) {
|
|
13242
|
-
|
|
13243
|
-
|
|
13244
|
-
|
|
13245
|
-
pattern,
|
|
13246
|
-
flags
|
|
13247
|
-
};
|
|
13248
|
-
}
|
|
13155
|
+
if (token.type === 9) t.regex = {
|
|
13156
|
+
pattern: token.pattern,
|
|
13157
|
+
flags: token.flags
|
|
13158
|
+
};
|
|
13249
13159
|
return t;
|
|
13250
13160
|
};
|
|
13251
13161
|
Parser.prototype.nextToken = function() {
|
|
@@ -13787,10 +13697,9 @@ var require_esprima = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/esp
|
|
|
13787
13697
|
if (!this.context.isBindingElement) this.throwUnexpectedToken(this.lookahead);
|
|
13788
13698
|
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]);
|
|
13789
13699
|
else this.reinterpretExpressionAsPattern(expr);
|
|
13790
|
-
var parameters = expr.type === syntax_1.Syntax.SequenceExpression ? expr.expressions : [expr];
|
|
13791
13700
|
expr = {
|
|
13792
13701
|
type: ArrowParameterPlaceHolder,
|
|
13793
|
-
params:
|
|
13702
|
+
params: expr.type === syntax_1.Syntax.SequenceExpression ? expr.expressions : [expr],
|
|
13794
13703
|
async: false
|
|
13795
13704
|
};
|
|
13796
13705
|
}
|
|
@@ -16372,13 +16281,12 @@ var require_esprima = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/esp
|
|
|
16372
16281
|
var start = this.index;
|
|
16373
16282
|
var pattern = this.scanRegExpBody();
|
|
16374
16283
|
var flags = this.scanRegExpFlags();
|
|
16375
|
-
var value = this.testRegExp(pattern, flags);
|
|
16376
16284
|
return {
|
|
16377
16285
|
type: 9,
|
|
16378
16286
|
value: "",
|
|
16379
16287
|
pattern,
|
|
16380
16288
|
flags,
|
|
16381
|
-
regex:
|
|
16289
|
+
regex: this.testRegExp(pattern, flags),
|
|
16382
16290
|
lineNumber: this.lineNumber,
|
|
16383
16291
|
lineStart: this.lineStart,
|
|
16384
16292
|
start,
|
|
@@ -16837,14 +16745,10 @@ var require_esprima = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/esp
|
|
|
16837
16745
|
};
|
|
16838
16746
|
entry.loc = loc;
|
|
16839
16747
|
}
|
|
16840
|
-
if (token.type === 9) {
|
|
16841
|
-
|
|
16842
|
-
|
|
16843
|
-
|
|
16844
|
-
pattern,
|
|
16845
|
-
flags
|
|
16846
|
-
};
|
|
16847
|
-
}
|
|
16748
|
+
if (token.type === 9) entry.regex = {
|
|
16749
|
+
pattern: token.pattern,
|
|
16750
|
+
flags: token.flags
|
|
16751
|
+
};
|
|
16848
16752
|
this.buffer.push(entry);
|
|
16849
16753
|
}
|
|
16850
16754
|
}
|
|
@@ -17929,8 +17833,7 @@ var require_dumper = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/js-y
|
|
|
17929
17833
|
function blockHeader(string, indentPerLevel) {
|
|
17930
17834
|
var indentIndicator = needIndentIndicator(string) ? String(indentPerLevel) : "";
|
|
17931
17835
|
var clip = string[string.length - 1] === "\n";
|
|
17932
|
-
|
|
17933
|
-
return indentIndicator + chomp + "\n";
|
|
17836
|
+
return indentIndicator + (clip && (string[string.length - 2] === "\n" || string === "\n") ? "+" : clip ? "" : "-") + "\n";
|
|
17934
17837
|
}
|
|
17935
17838
|
function dropEndingNewline(string) {
|
|
17936
17839
|
return string[string.length - 1] === "\n" ? string.slice(0, -1) : string;
|
|
@@ -18213,8 +18116,7 @@ var require_which_pm = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/wh
|
|
|
18213
18116
|
const modulesPath = path$2.join(pkgPath, "node_modules");
|
|
18214
18117
|
if (fs$1.existsSync(path$2.join(modulesPath, ".yarn-integrity"))) return { name: "yarn" };
|
|
18215
18118
|
try {
|
|
18216
|
-
|
|
18217
|
-
return toNameAndVersion(modules.packageManager);
|
|
18119
|
+
return toNameAndVersion((await loadYamlFile(path$2.join(modulesPath, ".modules.yaml"))).packageManager);
|
|
18218
18120
|
} catch (err) {
|
|
18219
18121
|
if (err.code !== "ENOENT") throw err;
|
|
18220
18122
|
}
|
|
@@ -18295,7 +18197,7 @@ var require_preferred_pm = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnp
|
|
|
18295
18197
|
//#endregion
|
|
18296
18198
|
//#region src/Commands/FireCommand.ts
|
|
18297
18199
|
var import_preferred_pm = /* @__PURE__ */ __toESM(require_preferred_pm(), 1);
|
|
18298
|
-
var FireCommand = class extends
|
|
18200
|
+
var FireCommand = class extends Command {
|
|
18299
18201
|
/**
|
|
18300
18202
|
* The name and signature of the console command.
|
|
18301
18203
|
*
|
|
@@ -18341,10 +18243,9 @@ var FireCommand = class extends ConsoleCommand {
|
|
|
18341
18243
|
"error"
|
|
18342
18244
|
][Number(this.option("verbose", 0))]
|
|
18343
18245
|
};
|
|
18344
|
-
const silent = ENV_VARS.LOG_LEVEL === "silent" ? "--silent" : null;
|
|
18345
18246
|
await execa(pm, [
|
|
18346
18247
|
"tsdown",
|
|
18347
|
-
silent,
|
|
18248
|
+
ENV_VARS.LOG_LEVEL === "silent" ? "--silent" : null,
|
|
18348
18249
|
"--config-loader",
|
|
18349
18250
|
"unconfig",
|
|
18350
18251
|
"-c",
|
|
@@ -18393,8 +18294,9 @@ var HttpServiceProvider = class extends ServiceProvider {
|
|
|
18393
18294
|
/** Bind the HTTP server to the service container */
|
|
18394
18295
|
this.app.singleton("http.serve", () => serve);
|
|
18395
18296
|
/** Register Musket Commands */
|
|
18396
|
-
this.
|
|
18297
|
+
this.registerCommands([FireCommand]);
|
|
18397
18298
|
}
|
|
18299
|
+
boot() {}
|
|
18398
18300
|
};
|
|
18399
18301
|
|
|
18400
18302
|
//#endregion
|
|
@@ -18666,5 +18568,4 @@ var Response = class {
|
|
|
18666
18568
|
};
|
|
18667
18569
|
|
|
18668
18570
|
//#endregion
|
|
18669
|
-
export { ApiResource, FireCommand, HttpContext, HttpServiceProvider, JsonResource, LogRequests, Middleware, Request, Response };
|
|
18670
|
-
//# sourceMappingURL=index.js.map
|
|
18571
|
+
export { ApiResource, FireCommand, HttpContext, HttpServiceProvider, JsonResource, LogRequests, Middleware, Request, Response };
|