@usecontextlayer/ctxb 0.5.26 → 0.5.29
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/cli.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
3
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="3d9a9038-da39-5c09-a71e-36219d48dd38")}catch(e){}}();
|
|
4
4
|
import { createRequire } from "node:module";
|
|
5
5
|
import * as Sentry from "@sentry/node";
|
|
6
6
|
import { mkdir, writeFile } from "node:fs/promises";
|
|
@@ -8,11 +8,11 @@ import path, { sep } from "node:path";
|
|
|
8
8
|
import { EventEmitter, addAbortListener, on, once, setMaxListeners } from "node:events";
|
|
9
9
|
import childProcess, { ChildProcess, execFile, spawn, spawnSync } from "node:child_process";
|
|
10
10
|
import fs, { appendFileSync, closeSync, createReadStream, createWriteStream, existsSync, openSync, readFileSync, readSync, statSync, writeFileSync } from "node:fs";
|
|
11
|
-
import
|
|
11
|
+
import process$1, { execArgv, execPath, hrtime, platform, stdin, stdout } from "node:process";
|
|
12
12
|
import { aborted, callbackify, debuglog, formatWithOptions, inspect, promisify, stripVTControlCharacters, styleText } from "node:util";
|
|
13
13
|
import * as tty$1 from "node:tty";
|
|
14
14
|
import tty from "node:tty";
|
|
15
|
-
import
|
|
15
|
+
import l__default from "node:readline";
|
|
16
16
|
import { createServer } from "node:http";
|
|
17
17
|
import { fileURLToPath } from "node:url";
|
|
18
18
|
import { StringDecoder } from "node:string_decoder";
|
|
@@ -20,8 +20,8 @@ import { scheduler, setImmediate as setImmediate$1, setTimeout as setTimeout$1 }
|
|
|
20
20
|
import { constants } from "node:os";
|
|
21
21
|
import { serialize } from "node:v8";
|
|
22
22
|
import { Buffer as Buffer$1 } from "node:buffer";
|
|
23
|
-
import { Duplex, PassThrough, Readable, Transform, Writable, getDefaultHighWaterMark } from "node:stream";
|
|
24
23
|
import { finished } from "node:stream/promises";
|
|
24
|
+
import { Duplex, PassThrough, Readable, Transform, Writable, getDefaultHighWaterMark } from "node:stream";
|
|
25
25
|
import path$1 from "node:path/win32";
|
|
26
26
|
import fs$1 from "fs";
|
|
27
27
|
import os from "os";
|
|
@@ -53,11 +53,11 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
53
53
|
}
|
|
54
54
|
return to;
|
|
55
55
|
};
|
|
56
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
56
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule || !__hasOwnProp.call(mod, "default") ? __defProp(target, "default", {
|
|
57
57
|
value: mod,
|
|
58
58
|
enumerable: true
|
|
59
59
|
}) : target, mod));
|
|
60
|
-
var __require = /*
|
|
60
|
+
var __require = /* #__PURE__ */ (() => createRequire(import.meta.url))();
|
|
61
61
|
|
|
62
62
|
//#endregion
|
|
63
63
|
//#region ../../node_modules/.pnpm/zod@4.4.3/node_modules/zod/v4/core/core.js
|
|
@@ -136,7 +136,6 @@ function cached(getter) {
|
|
|
136
136
|
Object.defineProperty(this, "value", { value });
|
|
137
137
|
return value;
|
|
138
138
|
}
|
|
139
|
-
throw new Error("cached value already set");
|
|
140
139
|
} };
|
|
141
140
|
}
|
|
142
141
|
function nullish(input) {
|
|
@@ -182,7 +181,10 @@ function assignProp(target, prop, value) {
|
|
|
182
181
|
}
|
|
183
182
|
function mergeDefs(...defs) {
|
|
184
183
|
const mergedDescriptors = {};
|
|
185
|
-
for (const def of defs)
|
|
184
|
+
for (const def of defs) {
|
|
185
|
+
const descriptors = Object.getOwnPropertyDescriptors(def);
|
|
186
|
+
Object.assign(mergedDescriptors, descriptors);
|
|
187
|
+
}
|
|
186
188
|
return Object.defineProperties({}, mergedDescriptors);
|
|
187
189
|
}
|
|
188
190
|
function esc(str) {
|
|
@@ -506,7 +508,7 @@ const _parse = (_Err) => (schema, value, _ctx, _params) => {
|
|
|
506
508
|
}, ctx);
|
|
507
509
|
if (result instanceof Promise) throw new $ZodAsyncError();
|
|
508
510
|
if (result.issues.length) {
|
|
509
|
-
const e = new (_params?.Err ?? _Err)(result.issues.map((iss) => finalizeIssue(iss, ctx, config())));
|
|
511
|
+
const e = new ((_params?.Err) ?? _Err)(result.issues.map((iss) => finalizeIssue(iss, ctx, config())));
|
|
510
512
|
captureStackTrace(e, _params?.callee);
|
|
511
513
|
throw e;
|
|
512
514
|
}
|
|
@@ -523,7 +525,7 @@ const _parseAsync = (_Err) => async (schema, value, _ctx, params) => {
|
|
|
523
525
|
}, ctx);
|
|
524
526
|
if (result instanceof Promise) result = await result;
|
|
525
527
|
if (result.issues.length) {
|
|
526
|
-
const e = new (params?.Err ?? _Err)(result.issues.map((iss) => finalizeIssue(iss, ctx, config())));
|
|
528
|
+
const e = new ((params?.Err) ?? _Err)(result.issues.map((iss) => finalizeIssue(iss, ctx, config())));
|
|
527
529
|
captureStackTrace(e, params?.callee);
|
|
528
530
|
throw e;
|
|
529
531
|
}
|
|
@@ -693,8 +695,10 @@ const $ZodCheckLessThan = /*@__PURE__*/ $constructor("$ZodCheckLessThan", (inst,
|
|
|
693
695
|
inst._zod.onattach.push((inst) => {
|
|
694
696
|
const bag = inst._zod.bag;
|
|
695
697
|
const curr = (def.inclusive ? bag.maximum : bag.exclusiveMaximum) ?? Number.POSITIVE_INFINITY;
|
|
696
|
-
if (def.value < curr)
|
|
697
|
-
|
|
698
|
+
if (def.value < curr) {
|
|
699
|
+
if (def.inclusive) bag.maximum = def.value;
|
|
700
|
+
else bag.exclusiveMaximum = def.value;
|
|
701
|
+
}
|
|
698
702
|
});
|
|
699
703
|
inst._zod.check = (payload) => {
|
|
700
704
|
if (def.inclusive ? payload.value <= def.value : payload.value < def.value) return;
|
|
@@ -715,8 +719,10 @@ const $ZodCheckGreaterThan = /*@__PURE__*/ $constructor("$ZodCheckGreaterThan",
|
|
|
715
719
|
inst._zod.onattach.push((inst) => {
|
|
716
720
|
const bag = inst._zod.bag;
|
|
717
721
|
const curr = (def.inclusive ? bag.minimum : bag.exclusiveMinimum) ?? Number.NEGATIVE_INFINITY;
|
|
718
|
-
if (def.value > curr)
|
|
719
|
-
|
|
722
|
+
if (def.value > curr) {
|
|
723
|
+
if (def.inclusive) bag.minimum = def.value;
|
|
724
|
+
else bag.exclusiveMinimum = def.value;
|
|
725
|
+
}
|
|
720
726
|
});
|
|
721
727
|
inst._zod.check = (payload) => {
|
|
722
728
|
if (def.inclusive ? payload.value >= def.value : payload.value > def.value) return;
|
|
@@ -1490,7 +1496,7 @@ const $ZodBoolean = /*@__PURE__*/ $constructor("$ZodBoolean", (inst, def) => {
|
|
|
1490
1496
|
const $ZodNull = /*@__PURE__*/ $constructor("$ZodNull", (inst, def) => {
|
|
1491
1497
|
$ZodType.init(inst, def);
|
|
1492
1498
|
inst._zod.pattern = _null$2;
|
|
1493
|
-
inst._zod.values = new Set([null]);
|
|
1499
|
+
inst._zod.values = /* @__PURE__ */ new Set([null]);
|
|
1494
1500
|
inst._zod.parse = (payload, _ctx) => {
|
|
1495
1501
|
const input = payload.value;
|
|
1496
1502
|
if (input === null) return payload;
|
|
@@ -2177,7 +2183,7 @@ const $ZodOptional = /*@__PURE__*/ $constructor("$ZodOptional", (inst, def) => {
|
|
|
2177
2183
|
inst._zod.optin = "optional";
|
|
2178
2184
|
inst._zod.optout = "optional";
|
|
2179
2185
|
defineLazy(inst._zod, "values", () => {
|
|
2180
|
-
return def.innerType._zod.values ? new Set([...def.innerType._zod.values, void 0]) : void 0;
|
|
2186
|
+
return def.innerType._zod.values ? /* @__PURE__ */ new Set([...def.innerType._zod.values, void 0]) : void 0;
|
|
2181
2187
|
});
|
|
2182
2188
|
defineLazy(inst._zod, "pattern", () => {
|
|
2183
2189
|
const pattern = def.innerType._zod.pattern;
|
|
@@ -2211,7 +2217,7 @@ const $ZodNullable = /*@__PURE__*/ $constructor("$ZodNullable", (inst, def) => {
|
|
|
2211
2217
|
return pattern ? new RegExp(`^(${cleanRegex(pattern.source)}|null)$`) : void 0;
|
|
2212
2218
|
});
|
|
2213
2219
|
defineLazy(inst._zod, "values", () => {
|
|
2214
|
-
return def.innerType._zod.values ? new Set([...def.innerType._zod.values, null]) : void 0;
|
|
2220
|
+
return def.innerType._zod.values ? /* @__PURE__ */ new Set([...def.innerType._zod.values, null]) : void 0;
|
|
2215
2221
|
});
|
|
2216
2222
|
inst._zod.parse = (payload, ctx) => {
|
|
2217
2223
|
if (payload.value === null) return payload;
|
|
@@ -2967,7 +2973,7 @@ function initializeContext(params) {
|
|
|
2967
2973
|
external: params?.external ?? void 0
|
|
2968
2974
|
};
|
|
2969
2975
|
}
|
|
2970
|
-
function process$
|
|
2976
|
+
function process$3(schema, ctx, _params = {
|
|
2971
2977
|
path: [],
|
|
2972
2978
|
schemaPath: []
|
|
2973
2979
|
}) {
|
|
@@ -3004,7 +3010,7 @@ function process$2(schema, ctx, _params = {
|
|
|
3004
3010
|
const parent = schema._zod.parent;
|
|
3005
3011
|
if (parent) {
|
|
3006
3012
|
if (!result.ref) result.ref = parent;
|
|
3007
|
-
process$
|
|
3013
|
+
process$3(parent, ctx, params);
|
|
3008
3014
|
ctx.seen.get(parent).isParent = true;
|
|
3009
3015
|
}
|
|
3010
3016
|
}
|
|
@@ -3164,8 +3170,10 @@ function finalize(ctx, schema) {
|
|
|
3164
3170
|
defs[seen.defId] = seen.def;
|
|
3165
3171
|
}
|
|
3166
3172
|
}
|
|
3167
|
-
if (ctx.external) {} else if (Object.keys(defs).length > 0)
|
|
3168
|
-
|
|
3173
|
+
if (ctx.external) {} else if (Object.keys(defs).length > 0) {
|
|
3174
|
+
if (ctx.target === "draft-2020-12") result.$defs = defs;
|
|
3175
|
+
else result.definitions = defs;
|
|
3176
|
+
}
|
|
3169
3177
|
try {
|
|
3170
3178
|
const finalized = JSON.parse(JSON.stringify(result));
|
|
3171
3179
|
Object.defineProperty(finalized, "~standard", {
|
|
@@ -3224,7 +3232,7 @@ const createToJSONSchemaMethod = (schema, processors = {}) => (params) => {
|
|
|
3224
3232
|
...params,
|
|
3225
3233
|
processors
|
|
3226
3234
|
});
|
|
3227
|
-
process$
|
|
3235
|
+
process$3(schema, ctx);
|
|
3228
3236
|
extractDefs(ctx, schema);
|
|
3229
3237
|
return finalize(ctx, schema);
|
|
3230
3238
|
};
|
|
@@ -3236,7 +3244,7 @@ const createStandardJSONSchemaMethod = (schema, io, processors = {}) => (params)
|
|
|
3236
3244
|
io,
|
|
3237
3245
|
processors
|
|
3238
3246
|
});
|
|
3239
|
-
process$
|
|
3247
|
+
process$3(schema, ctx);
|
|
3240
3248
|
extractDefs(ctx, schema);
|
|
3241
3249
|
return finalize(ctx, schema);
|
|
3242
3250
|
};
|
|
@@ -3279,16 +3287,18 @@ const numberProcessor = (schema, ctx, _json, _params) => {
|
|
|
3279
3287
|
const exMin = typeof exclusiveMinimum === "number" && exclusiveMinimum >= (minimum ?? Number.NEGATIVE_INFINITY);
|
|
3280
3288
|
const exMax = typeof exclusiveMaximum === "number" && exclusiveMaximum <= (maximum ?? Number.POSITIVE_INFINITY);
|
|
3281
3289
|
const legacy = ctx.target === "draft-04" || ctx.target === "openapi-3.0";
|
|
3282
|
-
if (exMin)
|
|
3283
|
-
|
|
3284
|
-
|
|
3285
|
-
|
|
3286
|
-
|
|
3287
|
-
if (
|
|
3288
|
-
|
|
3289
|
-
|
|
3290
|
-
|
|
3291
|
-
|
|
3290
|
+
if (exMin) {
|
|
3291
|
+
if (legacy) {
|
|
3292
|
+
json.minimum = exclusiveMinimum;
|
|
3293
|
+
json.exclusiveMinimum = true;
|
|
3294
|
+
} else json.exclusiveMinimum = exclusiveMinimum;
|
|
3295
|
+
} else if (typeof minimum === "number") json.minimum = minimum;
|
|
3296
|
+
if (exMax) {
|
|
3297
|
+
if (legacy) {
|
|
3298
|
+
json.maximum = exclusiveMaximum;
|
|
3299
|
+
json.exclusiveMaximum = true;
|
|
3300
|
+
} else json.exclusiveMaximum = exclusiveMaximum;
|
|
3301
|
+
} else if (typeof maximum === "number") json.maximum = maximum;
|
|
3292
3302
|
if (typeof multipleOf === "number") json.multipleOf = multipleOf;
|
|
3293
3303
|
};
|
|
3294
3304
|
const booleanProcessor = (_schema, _ctx, json, _params) => {
|
|
@@ -3317,9 +3327,10 @@ const literalProcessor = (schema, ctx, json, _params) => {
|
|
|
3317
3327
|
const vals = [];
|
|
3318
3328
|
for (const val of def.values) if (val === void 0) {
|
|
3319
3329
|
if (ctx.unrepresentable === "throw") throw new Error("Literal `undefined` cannot be represented in JSON Schema");
|
|
3320
|
-
} else if (typeof val === "bigint")
|
|
3321
|
-
|
|
3322
|
-
|
|
3330
|
+
} else if (typeof val === "bigint") {
|
|
3331
|
+
if (ctx.unrepresentable === "throw") throw new Error("BigInt literals cannot be represented in JSON Schema");
|
|
3332
|
+
else vals.push(Number(val));
|
|
3333
|
+
} else vals.push(val);
|
|
3323
3334
|
if (vals.length === 0) {} else if (vals.length === 1) {
|
|
3324
3335
|
const val = vals[0];
|
|
3325
3336
|
json.type = val === null ? "null" : typeof val;
|
|
@@ -3346,7 +3357,7 @@ const arrayProcessor = (schema, ctx, _json, params) => {
|
|
|
3346
3357
|
if (typeof minimum === "number") json.minItems = minimum;
|
|
3347
3358
|
if (typeof maximum === "number") json.maxItems = maximum;
|
|
3348
3359
|
json.type = "array";
|
|
3349
|
-
json.items = process$
|
|
3360
|
+
json.items = process$3(def.element, ctx, {
|
|
3350
3361
|
...params,
|
|
3351
3362
|
path: [...params.path, "items"]
|
|
3352
3363
|
});
|
|
@@ -3357,7 +3368,7 @@ const objectProcessor = (schema, ctx, _json, params) => {
|
|
|
3357
3368
|
json.type = "object";
|
|
3358
3369
|
json.properties = {};
|
|
3359
3370
|
const shape = def.shape;
|
|
3360
|
-
for (const key in shape) json.properties[key] = process$
|
|
3371
|
+
for (const key in shape) json.properties[key] = process$3(shape[key], ctx, {
|
|
3361
3372
|
...params,
|
|
3362
3373
|
path: [
|
|
3363
3374
|
...params.path,
|
|
@@ -3375,7 +3386,7 @@ const objectProcessor = (schema, ctx, _json, params) => {
|
|
|
3375
3386
|
if (def.catchall?._zod.def.type === "never") json.additionalProperties = false;
|
|
3376
3387
|
else if (!def.catchall) {
|
|
3377
3388
|
if (ctx.io === "output") json.additionalProperties = false;
|
|
3378
|
-
} else if (def.catchall) json.additionalProperties = process$
|
|
3389
|
+
} else if (def.catchall) json.additionalProperties = process$3(def.catchall, ctx, {
|
|
3379
3390
|
...params,
|
|
3380
3391
|
path: [...params.path, "additionalProperties"]
|
|
3381
3392
|
});
|
|
@@ -3383,7 +3394,7 @@ const objectProcessor = (schema, ctx, _json, params) => {
|
|
|
3383
3394
|
const unionProcessor = (schema, ctx, json, params) => {
|
|
3384
3395
|
const def = schema._zod.def;
|
|
3385
3396
|
const isExclusive = def.inclusive === false;
|
|
3386
|
-
const options = def.options.map((x, i) => process$
|
|
3397
|
+
const options = def.options.map((x, i) => process$3(x, ctx, {
|
|
3387
3398
|
...params,
|
|
3388
3399
|
path: [
|
|
3389
3400
|
...params.path,
|
|
@@ -3396,7 +3407,7 @@ const unionProcessor = (schema, ctx, json, params) => {
|
|
|
3396
3407
|
};
|
|
3397
3408
|
const intersectionProcessor = (schema, ctx, json, params) => {
|
|
3398
3409
|
const def = schema._zod.def;
|
|
3399
|
-
const a = process$
|
|
3410
|
+
const a = process$3(def.left, ctx, {
|
|
3400
3411
|
...params,
|
|
3401
3412
|
path: [
|
|
3402
3413
|
...params.path,
|
|
@@ -3404,7 +3415,7 @@ const intersectionProcessor = (schema, ctx, json, params) => {
|
|
|
3404
3415
|
0
|
|
3405
3416
|
]
|
|
3406
3417
|
});
|
|
3407
|
-
const b = process$
|
|
3418
|
+
const b = process$3(def.right, ctx, {
|
|
3408
3419
|
...params,
|
|
3409
3420
|
path: [
|
|
3410
3421
|
...params.path,
|
|
@@ -3422,7 +3433,7 @@ const recordProcessor = (schema, ctx, _json, params) => {
|
|
|
3422
3433
|
const keyType = def.keyType;
|
|
3423
3434
|
const patterns = keyType._zod.bag?.patterns;
|
|
3424
3435
|
if (def.mode === "loose" && patterns && patterns.size > 0) {
|
|
3425
|
-
const valueSchema = process$
|
|
3436
|
+
const valueSchema = process$3(def.valueType, ctx, {
|
|
3426
3437
|
...params,
|
|
3427
3438
|
path: [
|
|
3428
3439
|
...params.path,
|
|
@@ -3433,11 +3444,11 @@ const recordProcessor = (schema, ctx, _json, params) => {
|
|
|
3433
3444
|
json.patternProperties = {};
|
|
3434
3445
|
for (const pattern of patterns) json.patternProperties[pattern.source] = valueSchema;
|
|
3435
3446
|
} else {
|
|
3436
|
-
if (ctx.target === "draft-07" || ctx.target === "draft-2020-12") json.propertyNames = process$
|
|
3447
|
+
if (ctx.target === "draft-07" || ctx.target === "draft-2020-12") json.propertyNames = process$3(def.keyType, ctx, {
|
|
3437
3448
|
...params,
|
|
3438
3449
|
path: [...params.path, "propertyNames"]
|
|
3439
3450
|
});
|
|
3440
|
-
json.additionalProperties = process$
|
|
3451
|
+
json.additionalProperties = process$3(def.valueType, ctx, {
|
|
3441
3452
|
...params,
|
|
3442
3453
|
path: [...params.path, "additionalProperties"]
|
|
3443
3454
|
});
|
|
@@ -3450,7 +3461,7 @@ const recordProcessor = (schema, ctx, _json, params) => {
|
|
|
3450
3461
|
};
|
|
3451
3462
|
const nullableProcessor = (schema, ctx, json, params) => {
|
|
3452
3463
|
const def = schema._zod.def;
|
|
3453
|
-
const inner = process$
|
|
3464
|
+
const inner = process$3(def.innerType, ctx, params);
|
|
3454
3465
|
const seen = ctx.seen.get(schema);
|
|
3455
3466
|
if (ctx.target === "openapi-3.0") {
|
|
3456
3467
|
seen.ref = def.innerType;
|
|
@@ -3459,27 +3470,27 @@ const nullableProcessor = (schema, ctx, json, params) => {
|
|
|
3459
3470
|
};
|
|
3460
3471
|
const nonoptionalProcessor = (schema, ctx, _json, params) => {
|
|
3461
3472
|
const def = schema._zod.def;
|
|
3462
|
-
process$
|
|
3473
|
+
process$3(def.innerType, ctx, params);
|
|
3463
3474
|
const seen = ctx.seen.get(schema);
|
|
3464
3475
|
seen.ref = def.innerType;
|
|
3465
3476
|
};
|
|
3466
3477
|
const defaultProcessor = (schema, ctx, json, params) => {
|
|
3467
3478
|
const def = schema._zod.def;
|
|
3468
|
-
process$
|
|
3479
|
+
process$3(def.innerType, ctx, params);
|
|
3469
3480
|
const seen = ctx.seen.get(schema);
|
|
3470
3481
|
seen.ref = def.innerType;
|
|
3471
3482
|
json.default = JSON.parse(JSON.stringify(def.defaultValue));
|
|
3472
3483
|
};
|
|
3473
3484
|
const prefaultProcessor = (schema, ctx, json, params) => {
|
|
3474
3485
|
const def = schema._zod.def;
|
|
3475
|
-
process$
|
|
3486
|
+
process$3(def.innerType, ctx, params);
|
|
3476
3487
|
const seen = ctx.seen.get(schema);
|
|
3477
3488
|
seen.ref = def.innerType;
|
|
3478
3489
|
if (ctx.io === "input") json._prefault = JSON.parse(JSON.stringify(def.defaultValue));
|
|
3479
3490
|
};
|
|
3480
3491
|
const catchProcessor = (schema, ctx, json, params) => {
|
|
3481
3492
|
const def = schema._zod.def;
|
|
3482
|
-
process$
|
|
3493
|
+
process$3(def.innerType, ctx, params);
|
|
3483
3494
|
const seen = ctx.seen.get(schema);
|
|
3484
3495
|
seen.ref = def.innerType;
|
|
3485
3496
|
let catchValue;
|
|
@@ -3494,20 +3505,20 @@ const pipeProcessor = (schema, ctx, _json, params) => {
|
|
|
3494
3505
|
const def = schema._zod.def;
|
|
3495
3506
|
const inIsTransform = def.in._zod.traits.has("$ZodTransform");
|
|
3496
3507
|
const innerType = ctx.io === "input" ? inIsTransform ? def.out : def.in : def.out;
|
|
3497
|
-
process$
|
|
3508
|
+
process$3(innerType, ctx, params);
|
|
3498
3509
|
const seen = ctx.seen.get(schema);
|
|
3499
3510
|
seen.ref = innerType;
|
|
3500
3511
|
};
|
|
3501
3512
|
const readonlyProcessor = (schema, ctx, json, params) => {
|
|
3502
3513
|
const def = schema._zod.def;
|
|
3503
|
-
process$
|
|
3514
|
+
process$3(def.innerType, ctx, params);
|
|
3504
3515
|
const seen = ctx.seen.get(schema);
|
|
3505
3516
|
seen.ref = def.innerType;
|
|
3506
3517
|
json.readOnly = true;
|
|
3507
3518
|
};
|
|
3508
3519
|
const optionalProcessor = (schema, ctx, _json, params) => {
|
|
3509
3520
|
const def = schema._zod.def;
|
|
3510
|
-
process$
|
|
3521
|
+
process$3(def.innerType, ctx, params);
|
|
3511
3522
|
const seen = ctx.seen.get(schema);
|
|
3512
3523
|
seen.ref = def.innerType;
|
|
3513
3524
|
};
|
|
@@ -4114,11 +4125,12 @@ const ZodObject = /*@__PURE__*/ $constructor("ZodObject", (inst, def) => {
|
|
|
4114
4125
|
});
|
|
4115
4126
|
});
|
|
4116
4127
|
function object$1(shape, params) {
|
|
4117
|
-
|
|
4128
|
+
const def = {
|
|
4118
4129
|
type: "object",
|
|
4119
4130
|
shape: shape ?? {},
|
|
4120
4131
|
...normalizeParams(params)
|
|
4121
|
-
}
|
|
4132
|
+
};
|
|
4133
|
+
return new ZodObject(def);
|
|
4122
4134
|
}
|
|
4123
4135
|
function strictObject(shape, params) {
|
|
4124
4136
|
return new ZodObject({
|
|
@@ -4217,9 +4229,10 @@ const ZodEnum = /*@__PURE__*/ $constructor("ZodEnum", (inst, def) => {
|
|
|
4217
4229
|
};
|
|
4218
4230
|
});
|
|
4219
4231
|
function _enum(values, params) {
|
|
4232
|
+
const entries = Array.isArray(values) ? Object.fromEntries(values.map((v) => [v, v])) : values;
|
|
4220
4233
|
return new ZodEnum({
|
|
4221
4234
|
type: "enum",
|
|
4222
|
-
entries
|
|
4235
|
+
entries,
|
|
4223
4236
|
...normalizeParams(params)
|
|
4224
4237
|
});
|
|
4225
4238
|
}
|
|
@@ -4456,7 +4469,7 @@ function normalizedKey(event) {
|
|
|
4456
4469
|
|
|
4457
4470
|
//#endregion
|
|
4458
4471
|
//#region package.json
|
|
4459
|
-
var version = "0.5.
|
|
4472
|
+
var version = "0.5.29";
|
|
4460
4473
|
|
|
4461
4474
|
//#endregion
|
|
4462
4475
|
//#region sentry.ts
|
|
@@ -4564,7 +4577,6 @@ var Argument = class {
|
|
|
4564
4577
|
default:
|
|
4565
4578
|
this.required = true;
|
|
4566
4579
|
this._name = name;
|
|
4567
|
-
break;
|
|
4568
4580
|
}
|
|
4569
4581
|
if (this._name.endsWith("...")) {
|
|
4570
4582
|
this.variadic = true;
|
|
@@ -5531,13 +5543,13 @@ var Command = class Command extends EventEmitter {
|
|
|
5531
5543
|
this._showSuggestionAfterError = true;
|
|
5532
5544
|
this._savedState = null;
|
|
5533
5545
|
this._outputConfiguration = {
|
|
5534
|
-
writeOut: (str) =>
|
|
5535
|
-
writeErr: (str) =>
|
|
5546
|
+
writeOut: (str) => process$1.stdout.write(str),
|
|
5547
|
+
writeErr: (str) => process$1.stderr.write(str),
|
|
5536
5548
|
outputError: (str, write) => write(str),
|
|
5537
|
-
getOutHelpWidth: () =>
|
|
5538
|
-
getErrHelpWidth: () =>
|
|
5539
|
-
getOutHasColors: () => useColor() ?? (
|
|
5540
|
-
getErrHasColors: () => useColor() ?? (
|
|
5549
|
+
getOutHelpWidth: () => process$1.stdout.isTTY ? process$1.stdout.columns : void 0,
|
|
5550
|
+
getErrHelpWidth: () => process$1.stderr.isTTY ? process$1.stderr.columns : void 0,
|
|
5551
|
+
getOutHasColors: () => useColor() ?? (process$1.stdout.isTTY && process$1.stdout.hasColors?.()),
|
|
5552
|
+
getErrHasColors: () => useColor() ?? (process$1.stderr.isTTY && process$1.stderr.hasColors?.()),
|
|
5541
5553
|
stripColor: (str) => stripVTControlCharacters(str)
|
|
5542
5554
|
};
|
|
5543
5555
|
this._hidden = false;
|
|
@@ -5906,7 +5918,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
5906
5918
|
*/
|
|
5907
5919
|
_exit(exitCode, code, message) {
|
|
5908
5920
|
if (this._exitCallback) this._exitCallback(new CommanderError(exitCode, code, message));
|
|
5909
|
-
|
|
5921
|
+
process$1.exit(exitCode);
|
|
5910
5922
|
}
|
|
5911
5923
|
/**
|
|
5912
5924
|
* Register callback `fn` for the command.
|
|
@@ -6023,16 +6035,20 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
6023
6035
|
const oldValue = this.getOptionValue(name);
|
|
6024
6036
|
if (val !== null && option.parseArg) val = this._callParseArg(option, val, oldValue, invalidValueMessage);
|
|
6025
6037
|
else if (val !== null && option.variadic) val = option._collectValue(val, oldValue);
|
|
6026
|
-
if (val == null)
|
|
6027
|
-
|
|
6028
|
-
|
|
6038
|
+
if (val == null) {
|
|
6039
|
+
if (option.negate) val = false;
|
|
6040
|
+
else if (option.isBoolean() || option.optional) val = true;
|
|
6041
|
+
else val = "";
|
|
6042
|
+
}
|
|
6029
6043
|
this.setOptionValueWithSource(name, val, valueSource);
|
|
6030
6044
|
};
|
|
6031
6045
|
this.on("option:" + oname, (val) => {
|
|
6032
|
-
|
|
6046
|
+
const invalidValueMessage = `error: option '${option.flags}' argument '${val}' is invalid.`;
|
|
6047
|
+
handleOptionValue(val, invalidValueMessage, "cli");
|
|
6033
6048
|
});
|
|
6034
6049
|
if (option.envVar) this.on("optionEnv:" + oname, (val) => {
|
|
6035
|
-
|
|
6050
|
+
const invalidValueMessage = `error: option '${option.flags}' value '${val}' from env '${option.envVar}' is invalid.`;
|
|
6051
|
+
handleOptionValue(val, invalidValueMessage, "env");
|
|
6036
6052
|
});
|
|
6037
6053
|
return this;
|
|
6038
6054
|
}
|
|
@@ -6244,11 +6260,11 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
6244
6260
|
if (argv !== void 0 && !Array.isArray(argv)) throw new Error("first parameter to parse must be array or undefined");
|
|
6245
6261
|
parseOptions = parseOptions || {};
|
|
6246
6262
|
if (argv === void 0 && parseOptions.from === void 0) {
|
|
6247
|
-
if (
|
|
6248
|
-
const execArgv =
|
|
6263
|
+
if (process$1.versions?.electron) parseOptions.from = "electron";
|
|
6264
|
+
const execArgv = process$1.execArgv ?? [];
|
|
6249
6265
|
if (execArgv.includes("-e") || execArgv.includes("--eval") || execArgv.includes("-p") || execArgv.includes("--print")) parseOptions.from = "eval";
|
|
6250
6266
|
}
|
|
6251
|
-
if (argv === void 0) argv =
|
|
6267
|
+
if (argv === void 0) argv = process$1.argv;
|
|
6252
6268
|
this.rawArgs = argv.slice();
|
|
6253
6269
|
let userArgs;
|
|
6254
6270
|
switch (parseOptions.from) {
|
|
@@ -6258,7 +6274,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
6258
6274
|
userArgs = argv.slice(2);
|
|
6259
6275
|
break;
|
|
6260
6276
|
case "electron":
|
|
6261
|
-
if (
|
|
6277
|
+
if (process$1.defaultApp) {
|
|
6262
6278
|
this._scriptPath = argv[1];
|
|
6263
6279
|
userArgs = argv.slice(2);
|
|
6264
6280
|
} else userArgs = argv.slice(1);
|
|
@@ -6427,16 +6443,17 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
6427
6443
|
}
|
|
6428
6444
|
const launchWithNode = sourceExt.includes(path.extname(executableFile));
|
|
6429
6445
|
let proc;
|
|
6430
|
-
if (
|
|
6431
|
-
|
|
6432
|
-
|
|
6433
|
-
|
|
6434
|
-
|
|
6435
|
-
|
|
6446
|
+
if (process$1.platform !== "win32") {
|
|
6447
|
+
if (launchWithNode) {
|
|
6448
|
+
args.unshift(executableFile);
|
|
6449
|
+
args = incrementNodeInspectorPort(process$1.execArgv).concat(args);
|
|
6450
|
+
proc = childProcess.spawn(process$1.argv[0], args, { stdio: "inherit" });
|
|
6451
|
+
} else proc = childProcess.spawn(executableFile, args, { stdio: "inherit" });
|
|
6452
|
+
} else {
|
|
6436
6453
|
this._checkForMissingExecutable(executableFile, executableDir, subcommand._name);
|
|
6437
6454
|
args.unshift(executableFile);
|
|
6438
|
-
args = incrementNodeInspectorPort(
|
|
6439
|
-
proc = childProcess.spawn(
|
|
6455
|
+
args = incrementNodeInspectorPort(process$1.execArgv).concat(args);
|
|
6456
|
+
proc = childProcess.spawn(process$1.execPath, args, { stdio: "inherit" });
|
|
6440
6457
|
}
|
|
6441
6458
|
if (!proc.killed) [
|
|
6442
6459
|
"SIGUSR1",
|
|
@@ -6445,20 +6462,20 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
6445
6462
|
"SIGINT",
|
|
6446
6463
|
"SIGHUP"
|
|
6447
6464
|
].forEach((signal) => {
|
|
6448
|
-
|
|
6465
|
+
process$1.on(signal, () => {
|
|
6449
6466
|
if (proc.killed === false && proc.exitCode === null) proc.kill(signal);
|
|
6450
6467
|
});
|
|
6451
6468
|
});
|
|
6452
6469
|
const exitCallback = this._exitCallback;
|
|
6453
6470
|
proc.on("close", (code) => {
|
|
6454
6471
|
code = code ?? 1;
|
|
6455
|
-
if (!exitCallback)
|
|
6472
|
+
if (!exitCallback) process$1.exit(code);
|
|
6456
6473
|
else exitCallback(new CommanderError(code, "commander.executeSubCommandAsync", "(close)"));
|
|
6457
6474
|
});
|
|
6458
6475
|
proc.on("error", (err) => {
|
|
6459
6476
|
if (err.code === "ENOENT") this._checkForMissingExecutable(executableFile, executableDir, subcommand._name);
|
|
6460
6477
|
else if (err.code === "EACCES") throw new Error(`'${executableFile}' not executable`);
|
|
6461
|
-
if (!exitCallback)
|
|
6478
|
+
if (!exitCallback) process$1.exit(1);
|
|
6462
6479
|
else {
|
|
6463
6480
|
const wrappedError = new CommanderError(1, "commander.executeSubCommandAsync", "(error)");
|
|
6464
6481
|
wrappedError.nestedError = err;
|
|
@@ -6870,14 +6887,16 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
6870
6887
|
*/
|
|
6871
6888
|
_parseOptionsEnv() {
|
|
6872
6889
|
this.options.forEach((option) => {
|
|
6873
|
-
if (option.envVar && option.envVar in
|
|
6890
|
+
if (option.envVar && option.envVar in process$1.env) {
|
|
6874
6891
|
const optionKey = option.attributeName();
|
|
6875
6892
|
if (this.getOptionValue(optionKey) === void 0 || [
|
|
6876
6893
|
"default",
|
|
6877
6894
|
"config",
|
|
6878
6895
|
"env"
|
|
6879
|
-
].includes(this.getOptionValueSource(optionKey)))
|
|
6880
|
-
|
|
6896
|
+
].includes(this.getOptionValueSource(optionKey))) {
|
|
6897
|
+
if (option.required || option.optional) this.emit(`optionEnv:${option.name()}`, process$1.env[option.envVar]);
|
|
6898
|
+
else this.emit(`optionEnv:${option.name()}`);
|
|
6899
|
+
}
|
|
6881
6900
|
}
|
|
6882
6901
|
});
|
|
6883
6902
|
}
|
|
@@ -7356,7 +7375,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
7356
7375
|
*/
|
|
7357
7376
|
help(contextOptions) {
|
|
7358
7377
|
this.outputHelp(contextOptions);
|
|
7359
|
-
let exitCode = Number(
|
|
7378
|
+
let exitCode = Number(process$1.exitCode ?? 0);
|
|
7360
7379
|
if (exitCode === 0 && contextOptions && typeof contextOptions !== "function" && contextOptions.error) exitCode = 1;
|
|
7361
7380
|
this._exit(exitCode, "commander.help", "(outputHelp)");
|
|
7362
7381
|
}
|
|
@@ -7448,8 +7467,8 @@ function incrementNodeInspectorPort(args) {
|
|
|
7448
7467
|
* @package
|
|
7449
7468
|
*/
|
|
7450
7469
|
function useColor() {
|
|
7451
|
-
if (
|
|
7452
|
-
if (
|
|
7470
|
+
if (process$1.env.NO_COLOR || process$1.env.FORCE_COLOR === "0" || process$1.env.FORCE_COLOR === "false") return false;
|
|
7471
|
+
if (process$1.env.FORCE_COLOR || process$1.env.CLICOLOR_FORCE !== void 0) return true;
|
|
7453
7472
|
}
|
|
7454
7473
|
|
|
7455
7474
|
//#endregion
|
|
@@ -7870,10 +7889,11 @@ ${indent}`);
|
|
|
7870
7889
|
return causedPrefix + message + "\n" + stack + causedError;
|
|
7871
7890
|
}
|
|
7872
7891
|
formatArgs(args, opts) {
|
|
7873
|
-
|
|
7892
|
+
const _args = args.map((arg) => {
|
|
7874
7893
|
if (arg && typeof arg.stack === "string") return this.formatError(arg, opts);
|
|
7875
7894
|
return arg;
|
|
7876
|
-
})
|
|
7895
|
+
});
|
|
7896
|
+
return formatWithOptions(opts, ..._args);
|
|
7877
7897
|
}
|
|
7878
7898
|
formatDate(date, opts) {
|
|
7879
7899
|
return opts.date ? date.toLocaleTimeString() : "";
|
|
@@ -7910,8 +7930,8 @@ const isForced = "FORCE_COLOR" in env$1 || argv.includes("--color");
|
|
|
7910
7930
|
const isWindows$2 = platform$1 === "win32";
|
|
7911
7931
|
const isDumbTerminal = env$1.TERM === "dumb";
|
|
7912
7932
|
const isCompatibleTerminal = tty$1 && tty$1.isatty && tty$1.isatty(1) && env$1.TERM && !isDumbTerminal;
|
|
7913
|
-
const isCI
|
|
7914
|
-
const isColorSupported = !isDisabled && (isForced || isWindows$2 && !isDumbTerminal || isCompatibleTerminal || isCI
|
|
7933
|
+
const isCI = "CI" in env$1 && ("GITHUB_ACTIONS" in env$1 || "GITLAB_CI" in env$1 || "CIRCLECI" in env$1);
|
|
7934
|
+
const isColorSupported = !isDisabled && (isForced || isWindows$2 && !isDumbTerminal || isCompatibleTerminal || isCI);
|
|
7915
7935
|
function replaceClose(index, string, close, replace, head = string.slice(0, Math.max(0, index)) + replace, tail = string.slice(Math.max(0, index + close.length)), next = tail.indexOf(close)) {
|
|
7916
7936
|
return head + (next < 0 ? tail : replaceClose(next, tail, close, replace));
|
|
7917
7937
|
}
|
|
@@ -8093,7 +8113,9 @@ function box(text, _opts = {}) {
|
|
|
8093
8113
|
|
|
8094
8114
|
//#endregion
|
|
8095
8115
|
//#region ../../node_modules/.pnpm/consola@3.4.2/node_modules/consola/dist/index.mjs
|
|
8096
|
-
const r = Object.create(null)
|
|
8116
|
+
const r = Object.create(null);
|
|
8117
|
+
const i$2 = (e) => globalThis.process?.env || import.meta.env || globalThis.Deno?.env.toObject() || globalThis.__env__ || (e ? r : globalThis);
|
|
8118
|
+
const o$1 = new Proxy(r, {
|
|
8097
8119
|
get(e, s) {
|
|
8098
8120
|
return i$2()[s] ?? r[s];
|
|
8099
8121
|
},
|
|
@@ -8113,7 +8135,9 @@ const r = Object.create(null), i$2 = (e) => globalThis.process?.env || import.me
|
|
|
8113
8135
|
const e = i$2(true);
|
|
8114
8136
|
return Object.keys(e);
|
|
8115
8137
|
}
|
|
8116
|
-
})
|
|
8138
|
+
});
|
|
8139
|
+
const t = typeof process < "u" && process.env && process.env.NODE_ENV || "";
|
|
8140
|
+
const f = [
|
|
8117
8141
|
["APPVEYOR"],
|
|
8118
8142
|
[
|
|
8119
8143
|
"AWS_AMPLIFY",
|
|
@@ -8205,7 +8229,7 @@ const r = Object.create(null), i$2 = (e) => globalThis.process?.env || import.me
|
|
|
8205
8229
|
]
|
|
8206
8230
|
];
|
|
8207
8231
|
function b$1() {
|
|
8208
|
-
if (globalThis.process?.env) for (const e of f
|
|
8232
|
+
if (globalThis.process?.env) for (const e of f) {
|
|
8209
8233
|
const s = e[1] || e[0];
|
|
8210
8234
|
if (globalThis.process?.env[s]) return {
|
|
8211
8235
|
name: e[0].toLowerCase(),
|
|
@@ -8225,19 +8249,31 @@ l.name;
|
|
|
8225
8249
|
function n$1(e) {
|
|
8226
8250
|
return e ? e !== "false" : false;
|
|
8227
8251
|
}
|
|
8228
|
-
const I = globalThis.process?.platform || ""
|
|
8252
|
+
const I = globalThis.process?.platform || "";
|
|
8253
|
+
const T = n$1(o$1.CI) || l.ci !== false;
|
|
8254
|
+
const a$1 = n$1(globalThis.process?.stdout && globalThis.process?.stdout.isTTY);
|
|
8255
|
+
const g = n$1(o$1.DEBUG);
|
|
8256
|
+
const R$1 = t === "test" || n$1(o$1.TEST);
|
|
8229
8257
|
o$1.MINIMAL;
|
|
8230
8258
|
const A = /^win/i.test(I);
|
|
8231
8259
|
!n$1(o$1.NO_COLOR) && (n$1(o$1.FORCE_COLOR) || (a$1 || A) && o$1.TERM);
|
|
8232
8260
|
const C = (globalThis.process?.versions?.node || "").replace(/^v/, "") || null;
|
|
8233
8261
|
Number(C?.split(".")[0]);
|
|
8234
|
-
const y = globalThis.process || Object.create(null)
|
|
8262
|
+
const y = globalThis.process || Object.create(null);
|
|
8263
|
+
const _ = { versions: {} };
|
|
8235
8264
|
new Proxy(y, { get(e, s) {
|
|
8236
8265
|
if (s === "env") return o$1;
|
|
8237
8266
|
if (s in e) return e[s];
|
|
8238
8267
|
if (s in _) return _[s];
|
|
8239
8268
|
} });
|
|
8240
|
-
const c$1 = globalThis.process?.release?.name === "node"
|
|
8269
|
+
const c$1 = globalThis.process?.release?.name === "node";
|
|
8270
|
+
const O = !!globalThis.Bun || !!globalThis.process?.versions?.bun;
|
|
8271
|
+
const D = !!globalThis.Deno;
|
|
8272
|
+
const L = !!globalThis.fastly;
|
|
8273
|
+
const S = !!globalThis.Netlify;
|
|
8274
|
+
const u$2 = !!globalThis.EdgeRuntime;
|
|
8275
|
+
const N = globalThis.navigator?.userAgent === "Cloudflare-Workers";
|
|
8276
|
+
const F = [
|
|
8241
8277
|
[S, "netlify"],
|
|
8242
8278
|
[u$2, "edge-light"],
|
|
8243
8279
|
[N, "workerd"],
|
|
@@ -8306,9 +8342,9 @@ function stringWidth$1(string, options = {}) {
|
|
|
8306
8342
|
return width;
|
|
8307
8343
|
}
|
|
8308
8344
|
function isUnicodeSupported$2() {
|
|
8309
|
-
const { env } =
|
|
8345
|
+
const { env } = process$1;
|
|
8310
8346
|
const { TERM, TERM_PROGRAM } = env;
|
|
8311
|
-
if (
|
|
8347
|
+
if (process$1.platform !== "win32") return TERM !== "linux";
|
|
8312
8348
|
return Boolean(env.WT_SESSION) || Boolean(env.TERMINUS_SUBLIME) || env.ConEmuTask === "{cmd::Cmder}" || TERM_PROGRAM === "Terminus-Sublime" || TERM_PROGRAM === "vscode" || TERM === "xterm-256color" || TERM === "alacritty" || TERM === "rxvt-unicode" || TERM === "rxvt-unicode-256color" || env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
8313
8349
|
}
|
|
8314
8350
|
const TYPE_COLOR_MAP = {
|
|
@@ -8395,7 +8431,7 @@ function createConsola(options = {}) {
|
|
|
8395
8431
|
defaults: { level },
|
|
8396
8432
|
stdout: process.stdout,
|
|
8397
8433
|
stderr: process.stderr,
|
|
8398
|
-
prompt: (...args) => import("./prompt-
|
|
8434
|
+
prompt: (...args) => import("./prompt-BWUCluoW.mjs").then((m) => m.prompt(...args)),
|
|
8399
8435
|
reporters: options.reporters || [options.fancy ?? !(T || R$1) ? new FancyReporter() : new BasicReporter()],
|
|
8400
8436
|
...options
|
|
8401
8437
|
});
|
|
@@ -8754,7 +8790,7 @@ var require_src = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
8754
8790
|
//#region ../../node_modules/.pnpm/@clack+core@1.4.3/node_modules/@clack/core/dist/index.mjs
|
|
8755
8791
|
var import_src = require_src();
|
|
8756
8792
|
const settings = {
|
|
8757
|
-
actions: new Set([
|
|
8793
|
+
actions: /* @__PURE__ */ new Set([
|
|
8758
8794
|
"up",
|
|
8759
8795
|
"down",
|
|
8760
8796
|
"left",
|
|
@@ -8827,7 +8863,7 @@ function setRawMode(e, r) {
|
|
|
8827
8863
|
const o = e;
|
|
8828
8864
|
o.isTTY && o.setRawMode(r);
|
|
8829
8865
|
}
|
|
8830
|
-
const
|
|
8866
|
+
const getRows = (e) => "rows" in e && typeof e.rows == "number" ? e.rows : 20;
|
|
8831
8867
|
function runValidation(e, n) {
|
|
8832
8868
|
if ("~standard" in e) {
|
|
8833
8869
|
const a = e["~standard"].validate(n);
|
|
@@ -8906,7 +8942,7 @@ var V = class {
|
|
|
8906
8942
|
this.state = "cancel", this.close();
|
|
8907
8943
|
}, { once: true });
|
|
8908
8944
|
}
|
|
8909
|
-
this.rl =
|
|
8945
|
+
this.rl = l__default.createInterface({
|
|
8910
8946
|
input: this.input,
|
|
8911
8947
|
tabSize: 2,
|
|
8912
8948
|
prompt: "",
|
|
@@ -9038,10 +9074,37 @@ let u$1$1 = class u extends V {
|
|
|
9038
9074
|
//#endregion
|
|
9039
9075
|
//#region ../../node_modules/.pnpm/@clack+prompts@1.7.0/node_modules/@clack/prompts/dist/index.mjs
|
|
9040
9076
|
function isUnicodeSupported$1() {
|
|
9041
|
-
if (
|
|
9042
|
-
return Boolean(
|
|
9043
|
-
}
|
|
9044
|
-
const unicode = isUnicodeSupported$1()
|
|
9077
|
+
if (process$1.platform !== "win32") return process$1.env.TERM !== "linux";
|
|
9078
|
+
return Boolean(process$1.env.CI) || Boolean(process$1.env.WT_SESSION) || Boolean(process$1.env.TERMINUS_SUBLIME) || process$1.env.ConEmuTask === "{cmd::Cmder}" || process$1.env.TERM_PROGRAM === "Terminus-Sublime" || process$1.env.TERM_PROGRAM === "vscode" || process$1.env.TERM === "xterm-256color" || process$1.env.TERM === "alacritty" || process$1.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
9079
|
+
}
|
|
9080
|
+
const unicode = isUnicodeSupported$1();
|
|
9081
|
+
const unicodeOr = (o, e) => unicode ? o : e;
|
|
9082
|
+
const S_STEP_ACTIVE = unicodeOr("◆", "*");
|
|
9083
|
+
const S_STEP_CANCEL = unicodeOr("■", "x");
|
|
9084
|
+
const S_STEP_ERROR = unicodeOr("▲", "x");
|
|
9085
|
+
const S_STEP_SUBMIT = unicodeOr("◇", "o");
|
|
9086
|
+
const S_BAR_START = unicodeOr("┌", "T");
|
|
9087
|
+
const S_BAR = unicodeOr("│", "|");
|
|
9088
|
+
const S_BAR_END = unicodeOr("└", "—");
|
|
9089
|
+
const S_BAR_START_RIGHT = unicodeOr("┐", "T");
|
|
9090
|
+
const S_BAR_END_RIGHT = unicodeOr("┘", "—");
|
|
9091
|
+
const S_RADIO_ACTIVE = unicodeOr("●", ">");
|
|
9092
|
+
const S_RADIO_INACTIVE = unicodeOr("○", " ");
|
|
9093
|
+
const S_CHECKBOX_ACTIVE = unicodeOr("◻", "[•]");
|
|
9094
|
+
const S_CHECKBOX_SELECTED = unicodeOr("◼", "[+]");
|
|
9095
|
+
const S_CHECKBOX_INACTIVE = unicodeOr("◻", "[ ]");
|
|
9096
|
+
const S_PASSWORD_MASK = unicodeOr("▪", "•");
|
|
9097
|
+
const S_BAR_H = unicodeOr("─", "-");
|
|
9098
|
+
const S_CORNER_TOP_RIGHT = unicodeOr("╮", "+");
|
|
9099
|
+
const S_CONNECT_LEFT = unicodeOr("├", "+");
|
|
9100
|
+
const S_CORNER_BOTTOM_RIGHT = unicodeOr("╯", "+");
|
|
9101
|
+
const S_CORNER_BOTTOM_LEFT = unicodeOr("╰", "+");
|
|
9102
|
+
const S_CORNER_TOP_LEFT = unicodeOr("╭", "+");
|
|
9103
|
+
const S_INFO = unicodeOr("●", "•");
|
|
9104
|
+
const S_SUCCESS = unicodeOr("◆", "*");
|
|
9105
|
+
const S_WARN = unicodeOr("▲", "!");
|
|
9106
|
+
const S_ERROR = unicodeOr("■", "x");
|
|
9107
|
+
const symbol = (o) => {
|
|
9045
9108
|
switch (o) {
|
|
9046
9109
|
case "initial":
|
|
9047
9110
|
case "active": return styleText("cyan", S_STEP_ACTIVE);
|
|
@@ -9049,14 +9112,6 @@ const unicode = isUnicodeSupported$1(), isCI = () => process.env.CI === "true",
|
|
|
9049
9112
|
case "error": return styleText("yellow", S_STEP_ERROR);
|
|
9050
9113
|
case "submit": return styleText("green", S_STEP_SUBMIT);
|
|
9051
9114
|
}
|
|
9052
|
-
}, symbolBar = (o) => {
|
|
9053
|
-
switch (o) {
|
|
9054
|
-
case "initial":
|
|
9055
|
-
case "active": return styleText("cyan", S_BAR);
|
|
9056
|
-
case "cancel": return styleText("red", S_BAR);
|
|
9057
|
-
case "error": return styleText("yellow", S_BAR);
|
|
9058
|
-
case "submit": return styleText("green", S_BAR);
|
|
9059
|
-
}
|
|
9060
9115
|
};
|
|
9061
9116
|
const MULTISELECT_INSTRUCTIONS = [
|
|
9062
9117
|
`${styleText("dim", "↑/↓")} to navigate`,
|
|
@@ -9491,11 +9546,13 @@ else Headers$1 = class Headers {
|
|
|
9491
9546
|
headers;
|
|
9492
9547
|
constructor(init) {
|
|
9493
9548
|
this.headers = /* @__PURE__ */ new Map();
|
|
9494
|
-
if (init)
|
|
9495
|
-
|
|
9496
|
-
|
|
9497
|
-
|
|
9498
|
-
|
|
9549
|
+
if (init) {
|
|
9550
|
+
if (init instanceof Headers) init.forEach((value, key) => this.append(key, value));
|
|
9551
|
+
else if (Array.isArray(init)) for (const [key, value] of init) if (typeof key === "string" && typeof value === "string") this.append(key, value);
|
|
9552
|
+
else throw new TypeError("Each header entry must be a [string, string] tuple");
|
|
9553
|
+
else for (const [key, value] of Object.entries(init)) if (typeof value === "string") this.append(key, value);
|
|
9554
|
+
else throw new TypeError("Header values must be strings");
|
|
9555
|
+
}
|
|
9499
9556
|
}
|
|
9500
9557
|
append(name, value) {
|
|
9501
9558
|
const key = name.toLowerCase();
|
|
@@ -9683,7 +9740,7 @@ async function requestWithRetries(requestFn, maxRetries = DEFAULT_MAX_RETRIES) {
|
|
|
9683
9740
|
} else break;
|
|
9684
9741
|
return response;
|
|
9685
9742
|
}
|
|
9686
|
-
const SENSITIVE_HEADERS = new Set([
|
|
9743
|
+
const SENSITIVE_HEADERS = /* @__PURE__ */ new Set([
|
|
9687
9744
|
"authorization",
|
|
9688
9745
|
"www-authenticate",
|
|
9689
9746
|
"x-api-key",
|
|
@@ -9707,7 +9764,7 @@ function redactHeaders(headers) {
|
|
|
9707
9764
|
else filtered[key] = value;
|
|
9708
9765
|
return filtered;
|
|
9709
9766
|
}
|
|
9710
|
-
const SENSITIVE_QUERY_PARAMS = new Set([
|
|
9767
|
+
const SENSITIVE_QUERY_PARAMS = /* @__PURE__ */ new Set([
|
|
9711
9768
|
"api_key",
|
|
9712
9769
|
"api-key",
|
|
9713
9770
|
"apikey",
|
|
@@ -9968,7 +10025,8 @@ var HttpResponsePromise = class HttpResponsePromise extends Promise {
|
|
|
9968
10025
|
* @returns An `HttpResponsePromise` instance.
|
|
9969
10026
|
*/
|
|
9970
10027
|
static fromExecutor(executor) {
|
|
9971
|
-
|
|
10028
|
+
const promise = new Promise(executor);
|
|
10029
|
+
return new HttpResponsePromise(promise);
|
|
9972
10030
|
}
|
|
9973
10031
|
/**
|
|
9974
10032
|
* Creates an `HttpResponsePromise` from a resolved result.
|
|
@@ -9977,7 +10035,8 @@ var HttpResponsePromise = class HttpResponsePromise extends Promise {
|
|
|
9977
10035
|
* @returns An `HttpResponsePromise` instance.
|
|
9978
10036
|
*/
|
|
9979
10037
|
static fromResult(result) {
|
|
9980
|
-
|
|
10038
|
+
const promise = Promise.resolve(result);
|
|
10039
|
+
return new HttpResponsePromise(promise);
|
|
9981
10040
|
}
|
|
9982
10041
|
unwrap() {
|
|
9983
10042
|
if (!this.unwrappedPromise) this.unwrappedPromise = this.innerPromise.then(({ data }) => data);
|
|
@@ -10672,9 +10731,7 @@ function validateAndTransformObject({ value, requiredKeys, requiredKeysSet, getP
|
|
|
10672
10731
|
});
|
|
10673
10732
|
break;
|
|
10674
10733
|
case "strip": break;
|
|
10675
|
-
case "passthrough":
|
|
10676
|
-
transformed[preTransformedKey] = preTransformedItemValue;
|
|
10677
|
-
break;
|
|
10734
|
+
case "passthrough": transformed[preTransformedKey] = preTransformedItemValue;
|
|
10678
10735
|
}
|
|
10679
10736
|
}
|
|
10680
10737
|
if (missingRequiredCount > 0) {
|
|
@@ -11044,20 +11101,22 @@ function transformAndValidateUnion({ value, discriminant, transformedDiscriminan
|
|
|
11044
11101
|
errors: transformedDiscriminantValue.errors
|
|
11045
11102
|
};
|
|
11046
11103
|
const additionalPropertiesSchema = getAdditionalPropertiesSchema(transformedDiscriminantValue.value);
|
|
11047
|
-
if (additionalPropertiesSchema == null)
|
|
11048
|
-
|
|
11049
|
-
|
|
11050
|
-
|
|
11051
|
-
|
|
11052
|
-
|
|
11053
|
-
|
|
11054
|
-
|
|
11055
|
-
|
|
11056
|
-
|
|
11057
|
-
|
|
11058
|
-
|
|
11059
|
-
|
|
11060
|
-
|
|
11104
|
+
if (additionalPropertiesSchema == null) {
|
|
11105
|
+
if (allowUnrecognizedUnionMembers) return {
|
|
11106
|
+
ok: true,
|
|
11107
|
+
value: {
|
|
11108
|
+
[transformedDiscriminant]: transformedDiscriminantValue.value,
|
|
11109
|
+
...additionalProperties
|
|
11110
|
+
}
|
|
11111
|
+
};
|
|
11112
|
+
else return {
|
|
11113
|
+
ok: false,
|
|
11114
|
+
errors: [{
|
|
11115
|
+
path: [...breadcrumbsPrefix, discriminant],
|
|
11116
|
+
message: "Unexpected discriminant value"
|
|
11117
|
+
}]
|
|
11118
|
+
};
|
|
11119
|
+
}
|
|
11061
11120
|
const transformedAdditionalProperties = transformAdditionalProperties(additionalProperties, additionalPropertiesSchema);
|
|
11062
11121
|
if (!transformedAdditionalProperties.ok) return transformedAdditionalProperties;
|
|
11063
11122
|
return {
|
|
@@ -11075,9 +11134,7 @@ function encodePathParam(param) {
|
|
|
11075
11134
|
case "string":
|
|
11076
11135
|
case "number":
|
|
11077
11136
|
case "boolean": break;
|
|
11078
|
-
default:
|
|
11079
|
-
param = String(param);
|
|
11080
|
-
break;
|
|
11137
|
+
default: param = String(param);
|
|
11081
11138
|
}
|
|
11082
11139
|
return encodeURIComponent(param);
|
|
11083
11140
|
}
|
|
@@ -11227,8 +11284,24 @@ const UpdateBindingInput = object({
|
|
|
11227
11284
|
enabled: boolean().optional(),
|
|
11228
11285
|
models: BindingModels.optionalNullable()
|
|
11229
11286
|
});
|
|
11287
|
+
const BindingAuthResourceApiKey = object({});
|
|
11288
|
+
const BindingAuthResourceAuthenticatedAccount = object({
|
|
11289
|
+
accountId: property("account_id", string()),
|
|
11290
|
+
providerId: property("provider_id", string())
|
|
11291
|
+
});
|
|
11292
|
+
const BindingAuthResourceClientCredentials = object({ clientId: property("client_id", string()) });
|
|
11293
|
+
const BindingAuthResourceNone = object({});
|
|
11294
|
+
const BindingAuthResource = union("type", {
|
|
11295
|
+
api_key: BindingAuthResourceApiKey,
|
|
11296
|
+
authenticated_account: BindingAuthResourceAuthenticatedAccount,
|
|
11297
|
+
client_credentials: BindingAuthResourceClientCredentials,
|
|
11298
|
+
none: BindingAuthResourceNone
|
|
11299
|
+
}).transform({
|
|
11300
|
+
transform: (value) => value,
|
|
11301
|
+
untransform: (value) => value
|
|
11302
|
+
});
|
|
11230
11303
|
const Binding = object({
|
|
11231
|
-
auth:
|
|
11304
|
+
auth: BindingAuthResource,
|
|
11232
11305
|
authType: property("auth_type", string()),
|
|
11233
11306
|
baseId: property("base_id", string()),
|
|
11234
11307
|
bindingId: property("binding_id", string()),
|
|
@@ -12532,7 +12605,7 @@ const providerTokenLeaseSchema = object$1({
|
|
|
12532
12605
|
//#endregion
|
|
12533
12606
|
//#region bindings/new.ts
|
|
12534
12607
|
const CALLBACK_PATH = "/callback";
|
|
12535
|
-
const CALLBACK_TIMEOUT_MS =
|
|
12608
|
+
const CALLBACK_TIMEOUT_MS = 3e5;
|
|
12536
12609
|
const pluginIdSchema = string$1().trim().min(1, "plugin_id cannot be empty.");
|
|
12537
12610
|
const requiredAuthValueSchema = string$1().trim().min(1);
|
|
12538
12611
|
async function promptSecret(message) {
|
|
@@ -12686,7 +12759,7 @@ function isPlainObject(value) {
|
|
|
12686
12759
|
}
|
|
12687
12760
|
|
|
12688
12761
|
//#endregion
|
|
12689
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
12762
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/file-url.js
|
|
12690
12763
|
const safeNormalizeFileUrl = (file, name) => {
|
|
12691
12764
|
const fileString = normalizeFileUrl(normalizeDenoExecPath(file));
|
|
12692
12765
|
if (typeof fileString !== "string") throw new TypeError(`${name} must be a string or a file URL: ${fileString}.`);
|
|
@@ -12697,7 +12770,7 @@ const isDenoExecPath = (file) => typeof file !== "string" && file && Object.getP
|
|
|
12697
12770
|
const normalizeFileUrl = (file) => file instanceof URL ? fileURLToPath(file) : file;
|
|
12698
12771
|
|
|
12699
12772
|
//#endregion
|
|
12700
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
12773
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/methods/parameters.js
|
|
12701
12774
|
const normalizeParameters = (rawFile, rawArguments = [], rawOptions = {}) => {
|
|
12702
12775
|
const filePath = safeNormalizeFileUrl(rawFile, "First argument");
|
|
12703
12776
|
const [commandArguments, options] = isPlainObject(rawArguments) ? [[], rawArguments] : [rawArguments, rawOptions];
|
|
@@ -12718,7 +12791,7 @@ const normalizeParameters = (rawFile, rawArguments = [], rawOptions = {}) => {
|
|
|
12718
12791
|
};
|
|
12719
12792
|
|
|
12720
12793
|
//#endregion
|
|
12721
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
12794
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/utils/uint-array.js
|
|
12722
12795
|
const { toString: objectToString$1 } = Object.prototype;
|
|
12723
12796
|
const isArrayBuffer = (value) => objectToString$1.call(value) === "[object ArrayBuffer]";
|
|
12724
12797
|
const isUint8Array = (value) => objectToString$1.call(value) === "[object Uint8Array]";
|
|
@@ -12758,7 +12831,7 @@ const getJoinLength = (uint8Arrays) => {
|
|
|
12758
12831
|
};
|
|
12759
12832
|
|
|
12760
12833
|
//#endregion
|
|
12761
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
12834
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/methods/template.js
|
|
12762
12835
|
const isTemplateString = (templates) => Array.isArray(templates) && Array.isArray(templates.raw);
|
|
12763
12836
|
const parseTemplates = (templates, expressions) => {
|
|
12764
12837
|
let tokens = [];
|
|
@@ -12783,7 +12856,8 @@ const parseTemplate = ({ templates, expressions, tokens, index, template }) => {
|
|
|
12783
12856
|
const newTokens = concatTokens(tokens, nextTokens, leadingWhitespaces);
|
|
12784
12857
|
if (index === expressions.length) return newTokens;
|
|
12785
12858
|
const expression = expressions[index];
|
|
12786
|
-
|
|
12859
|
+
const expressionTokens = Array.isArray(expression) ? expression.map((expression) => parseExpression(expression)) : [parseExpression(expression)];
|
|
12860
|
+
return concatTokens(newTokens, expressionTokens, trailingWhitespaces);
|
|
12787
12861
|
};
|
|
12788
12862
|
const splitByWhitespaces = (template, rawTemplate) => {
|
|
12789
12863
|
if (rawTemplate.length === 0) return {
|
|
@@ -12816,7 +12890,7 @@ const splitByWhitespaces = (template, rawTemplate) => {
|
|
|
12816
12890
|
trailingWhitespaces: isTrailingWhitespaces
|
|
12817
12891
|
};
|
|
12818
12892
|
};
|
|
12819
|
-
const DELIMITERS = new Set([
|
|
12893
|
+
const DELIMITERS = /* @__PURE__ */ new Set([
|
|
12820
12894
|
" ",
|
|
12821
12895
|
" ",
|
|
12822
12896
|
"\r",
|
|
@@ -12847,12 +12921,12 @@ const getSubprocessResult = ({ stdout }) => {
|
|
|
12847
12921
|
};
|
|
12848
12922
|
|
|
12849
12923
|
//#endregion
|
|
12850
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
12924
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/utils/standard-stream.js
|
|
12851
12925
|
const isStandardStream = (stream) => STANDARD_STREAMS.includes(stream);
|
|
12852
12926
|
const STANDARD_STREAMS = [
|
|
12853
|
-
|
|
12854
|
-
|
|
12855
|
-
|
|
12927
|
+
process$1.stdin,
|
|
12928
|
+
process$1.stdout,
|
|
12929
|
+
process$1.stderr
|
|
12856
12930
|
];
|
|
12857
12931
|
const STANDARD_STREAMS_ALIASES = [
|
|
12858
12932
|
"stdin",
|
|
@@ -12862,7 +12936,7 @@ const STANDARD_STREAMS_ALIASES = [
|
|
|
12862
12936
|
const getStreamName = (fdNumber) => STANDARD_STREAMS_ALIASES[fdNumber] ?? `stdio[${fdNumber}]`;
|
|
12863
12937
|
|
|
12864
12938
|
//#endregion
|
|
12865
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
12939
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/specific.js
|
|
12866
12940
|
const normalizeFdSpecificOptions = (options) => {
|
|
12867
12941
|
const optionsCopy = { ...options };
|
|
12868
12942
|
for (const optionName of FD_SPECIFIC_OPTIONS) optionsCopy[optionName] = normalizeFdSpecificOption(options, optionName);
|
|
@@ -12871,7 +12945,8 @@ const normalizeFdSpecificOptions = (options) => {
|
|
|
12871
12945
|
const normalizeFdSpecificOption = (options, optionName) => {
|
|
12872
12946
|
const stdioLength = getStdioLength(options);
|
|
12873
12947
|
const optionBaseArray = Array.from({ length: stdioLength + 1 });
|
|
12874
|
-
|
|
12948
|
+
const optionArray = normalizeFdSpecificValue(options[optionName], optionBaseArray, optionName, stdioLength);
|
|
12949
|
+
return addDefaultValue$1(optionArray, optionName);
|
|
12875
12950
|
};
|
|
12876
12951
|
const getStdioLength = ({ stdio }) => Array.isArray(stdio) ? Math.max(stdio.length, STANDARD_STREAMS_ALIASES.length) : STANDARD_STREAMS_ALIASES.length;
|
|
12877
12952
|
const normalizeFdSpecificValue = (optionValue, optionArray, optionName, stdioLength) => isPlainObject(optionValue) ? normalizeOptionObject(optionValue, optionArray, optionName, stdioLength) : optionArray.fill(optionValue);
|
|
@@ -12904,7 +12979,7 @@ const addDefaultValue$1 = (optionArray, optionName) => optionArray.map((optionVa
|
|
|
12904
12979
|
const DEFAULT_OPTIONS = {
|
|
12905
12980
|
lines: false,
|
|
12906
12981
|
buffer: true,
|
|
12907
|
-
maxBuffer:
|
|
12982
|
+
maxBuffer: 1e8,
|
|
12908
12983
|
verbose: debuglog("execa").enabled ? "full" : "none",
|
|
12909
12984
|
stripFinalNewline: true
|
|
12910
12985
|
};
|
|
@@ -12918,7 +12993,7 @@ const FD_SPECIFIC_OPTIONS = [
|
|
|
12918
12993
|
const getFdSpecificValue = (optionArray, fdNumber) => fdNumber === "ipc" ? optionArray.at(-1) : optionArray[fdNumber];
|
|
12919
12994
|
|
|
12920
12995
|
//#endregion
|
|
12921
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
12996
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/values.js
|
|
12922
12997
|
const isVerbose = ({ verbose }, fdNumber) => getFdVerbose(verbose, fdNumber) !== "none";
|
|
12923
12998
|
const isFullVerbose = ({ verbose }, fdNumber) => !["none", "short"].includes(getFdVerbose(verbose, fdNumber));
|
|
12924
12999
|
const getVerboseFunction = ({ verbose }, fdNumber) => {
|
|
@@ -12935,7 +13010,7 @@ const VERBOSE_VALUES = [
|
|
|
12935
13010
|
];
|
|
12936
13011
|
|
|
12937
13012
|
//#endregion
|
|
12938
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13013
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/escape.js
|
|
12939
13014
|
const joinCommand = (filePath, rawArguments) => {
|
|
12940
13015
|
const fileAndArguments = [filePath, ...rawArguments];
|
|
12941
13016
|
return {
|
|
@@ -12978,9 +13053,9 @@ const NO_ESCAPE_REGEXP = /^[\w\-./]+$/;
|
|
|
12978
13053
|
//#endregion
|
|
12979
13054
|
//#region ../../node_modules/.pnpm/is-unicode-supported@2.1.0/node_modules/is-unicode-supported/index.js
|
|
12980
13055
|
function isUnicodeSupported() {
|
|
12981
|
-
const { env } =
|
|
13056
|
+
const { env } = process$1;
|
|
12982
13057
|
const { TERM, TERM_PROGRAM } = env;
|
|
12983
|
-
if (
|
|
13058
|
+
if (process$1.platform !== "win32") return TERM !== "linux";
|
|
12984
13059
|
return Boolean(env.WT_SESSION) || Boolean(env.TERMINUS_SUBLIME) || env.ConEmuTask === "{cmd::Cmder}" || TERM_PROGRAM === "Terminus-Sublime" || TERM_PROGRAM === "vscode" || TERM === "xterm-256color" || TERM === "alacritty" || TERM === "rxvt-unicode" || TERM === "rxvt-unicode-256color" || env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
12985
13060
|
}
|
|
12986
13061
|
|
|
@@ -13332,7 +13407,7 @@ const bgCyanBright = format(106, 49);
|
|
|
13332
13407
|
const bgWhiteBright = format(107, 49);
|
|
13333
13408
|
|
|
13334
13409
|
//#endregion
|
|
13335
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13410
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/default.js
|
|
13336
13411
|
const defaultVerboseFunction = ({ type, message, timestamp, piped, commandId, result: { failed = false } = {}, options: { reject = true } }) => {
|
|
13337
13412
|
const timestampString = serializeTimestamp(timestamp);
|
|
13338
13413
|
const icon = ICONS[type]({
|
|
@@ -13366,7 +13441,7 @@ const COLORS = {
|
|
|
13366
13441
|
};
|
|
13367
13442
|
|
|
13368
13443
|
//#endregion
|
|
13369
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13444
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/custom.js
|
|
13370
13445
|
const applyVerboseOnLines = (printedLines, verboseInfo, fdNumber) => {
|
|
13371
13446
|
const verboseFunction = getVerboseFunction(verboseInfo, fdNumber);
|
|
13372
13447
|
return printedLines.map(({ verboseLine, verboseObject }) => applyVerboseFunction(verboseLine, verboseObject, verboseFunction)).filter((printedLine) => printedLine !== void 0).map((printedLine) => appendNewline(printedLine)).join("");
|
|
@@ -13379,13 +13454,15 @@ const applyVerboseFunction = (verboseLine, verboseObject, verboseFunction) => {
|
|
|
13379
13454
|
const appendNewline = (printedLine) => printedLine.endsWith("\n") ? printedLine : `${printedLine}\n`;
|
|
13380
13455
|
|
|
13381
13456
|
//#endregion
|
|
13382
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13457
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/log.js
|
|
13383
13458
|
const verboseLog = ({ type, verboseMessage, fdNumber, verboseInfo, result }) => {
|
|
13384
|
-
const
|
|
13459
|
+
const verboseObject = getVerboseObject({
|
|
13385
13460
|
type,
|
|
13386
13461
|
result,
|
|
13387
13462
|
verboseInfo
|
|
13388
|
-
})
|
|
13463
|
+
});
|
|
13464
|
+
const printedLines = getPrintedLines(verboseMessage, verboseObject);
|
|
13465
|
+
const finalLines = applyVerboseOnLines(printedLines, verboseInfo, fdNumber);
|
|
13389
13466
|
if (finalLines !== "") console.warn(finalLines.slice(0, -1));
|
|
13390
13467
|
};
|
|
13391
13468
|
const getVerboseObject = ({ type, result, verboseInfo }) => {
|
|
@@ -13412,12 +13489,13 @@ const getPrintedLine = (verboseObject) => {
|
|
|
13412
13489
|
};
|
|
13413
13490
|
};
|
|
13414
13491
|
const serializeVerboseMessage = (message) => {
|
|
13415
|
-
|
|
13492
|
+
const messageString = typeof message === "string" ? message : inspect(message);
|
|
13493
|
+
return escapeLines(messageString).replaceAll(" ", () => " ".repeat(TAB_SIZE));
|
|
13416
13494
|
};
|
|
13417
13495
|
const TAB_SIZE = 2;
|
|
13418
13496
|
|
|
13419
13497
|
//#endregion
|
|
13420
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13498
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/start.js
|
|
13421
13499
|
const logCommand = (escapedCommand, verboseInfo) => {
|
|
13422
13500
|
if (!isVerbose(verboseInfo)) return;
|
|
13423
13501
|
verboseLog({
|
|
@@ -13428,7 +13506,7 @@ const logCommand = (escapedCommand, verboseInfo) => {
|
|
|
13428
13506
|
};
|
|
13429
13507
|
|
|
13430
13508
|
//#endregion
|
|
13431
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13509
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/info.js
|
|
13432
13510
|
const getVerboseInfo = (verbose, escapedCommand, rawOptions) => {
|
|
13433
13511
|
validateVerbose(verbose);
|
|
13434
13512
|
return {
|
|
@@ -13452,16 +13530,17 @@ const validateVerbose = (verbose) => {
|
|
|
13452
13530
|
};
|
|
13453
13531
|
|
|
13454
13532
|
//#endregion
|
|
13455
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13533
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/return/duration.js
|
|
13456
13534
|
const getStartTime = () => hrtime.bigint();
|
|
13457
13535
|
const getDurationMs = (startTime) => Number(hrtime.bigint() - startTime) / 1e6;
|
|
13458
13536
|
|
|
13459
13537
|
//#endregion
|
|
13460
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13538
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/command.js
|
|
13461
13539
|
const handleCommand = (filePath, rawArguments, rawOptions) => {
|
|
13462
13540
|
const startTime = getStartTime();
|
|
13463
13541
|
const { command, escapedCommand } = joinCommand(filePath, rawArguments);
|
|
13464
|
-
const
|
|
13542
|
+
const verbose = normalizeFdSpecificOption(rawOptions, "verbose");
|
|
13543
|
+
const verboseInfo = getVerboseInfo(verbose, escapedCommand, { ...rawOptions });
|
|
13465
13544
|
logCommand(escapedCommand, verboseInfo);
|
|
13466
13545
|
return {
|
|
13467
13546
|
command,
|
|
@@ -13499,7 +13578,7 @@ function traversePathUp(startPath) {
|
|
|
13499
13578
|
|
|
13500
13579
|
//#endregion
|
|
13501
13580
|
//#region ../../node_modules/.pnpm/npm-run-path@6.0.0/node_modules/npm-run-path/index.js
|
|
13502
|
-
const npmRunPath = ({ cwd =
|
|
13581
|
+
const npmRunPath = ({ cwd = process$1.cwd(), path: pathOption = process$1.env[pathKey()], preferLocal = true, execPath = process$1.execPath, addExecPath = true } = {}) => {
|
|
13503
13582
|
const cwdPath = path.resolve(toPath(cwd));
|
|
13504
13583
|
const result = [];
|
|
13505
13584
|
const pathParts = pathOption.split(path.delimiter);
|
|
@@ -13517,7 +13596,7 @@ const applyExecPath = (result, pathParts, execPath, cwdPath) => {
|
|
|
13517
13596
|
const pathPart = path.resolve(cwdPath, toPath(execPath), "..");
|
|
13518
13597
|
if (!pathParts.includes(pathPart)) result.push(pathPart);
|
|
13519
13598
|
};
|
|
13520
|
-
const npmRunPathEnv = ({ env =
|
|
13599
|
+
const npmRunPathEnv = ({ env = process$1.env, ...options } = {}) => {
|
|
13521
13600
|
env = { ...env };
|
|
13522
13601
|
const pathName = pathKey({ env });
|
|
13523
13602
|
options.path = env[pathName];
|
|
@@ -13526,7 +13605,7 @@ const npmRunPathEnv = ({ env = g$1.env, ...options } = {}) => {
|
|
|
13526
13605
|
};
|
|
13527
13606
|
|
|
13528
13607
|
//#endregion
|
|
13529
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13608
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/return/final-error.js
|
|
13530
13609
|
const getFinalError = (originalError, message, isSync) => {
|
|
13531
13610
|
return new (isSync ? ExecaSyncError : ExecaError)(message, originalError instanceof DiscardedError ? {} : { cause: originalError });
|
|
13532
13611
|
};
|
|
@@ -13909,7 +13988,7 @@ const findSignalByNumber = (number, signals) => {
|
|
|
13909
13988
|
const signalsByNumber = getSignalsByNumber();
|
|
13910
13989
|
|
|
13911
13990
|
//#endregion
|
|
13912
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
13991
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/terminate/signal.js
|
|
13913
13992
|
const normalizeKillSignal = (killSignal) => {
|
|
13914
13993
|
const optionName = "option `killSignal`";
|
|
13915
13994
|
if (killSignal === 0) throw new TypeError(`Invalid ${optionName}: 0 cannot be used.`);
|
|
@@ -13939,14 +14018,14 @@ const getAvailableSignalIntegers = () => [...new Set(Object.values(constants.sig
|
|
|
13939
14018
|
const getSignalDescription = (signal) => signalsByName[signal].description;
|
|
13940
14019
|
|
|
13941
14020
|
//#endregion
|
|
13942
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14021
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/terminate/kill.js
|
|
13943
14022
|
const normalizeForceKillAfterDelay = (forceKillAfterDelay) => {
|
|
13944
14023
|
if (forceKillAfterDelay === false) return forceKillAfterDelay;
|
|
13945
14024
|
if (forceKillAfterDelay === true) return DEFAULT_FORCE_KILL_TIMEOUT;
|
|
13946
14025
|
if (!Number.isFinite(forceKillAfterDelay) || forceKillAfterDelay < 0) throw new TypeError(`Expected the \`forceKillAfterDelay\` option to be a non-negative integer, got \`${forceKillAfterDelay}\` (${typeof forceKillAfterDelay})`);
|
|
13947
14026
|
return forceKillAfterDelay;
|
|
13948
14027
|
};
|
|
13949
|
-
const DEFAULT_FORCE_KILL_TIMEOUT =
|
|
14028
|
+
const DEFAULT_FORCE_KILL_TIMEOUT = 5e3;
|
|
13950
14029
|
const subprocessKill = ({ kill, options: { forceKillAfterDelay, killSignal }, onInternalError, context, controller }, signalOrError, errorArgument) => {
|
|
13951
14030
|
const { signal, error } = parseKillArguments(signalOrError, errorArgument, killSignal);
|
|
13952
14031
|
emitKillError(error, onInternalError);
|
|
@@ -13991,13 +14070,13 @@ const killOnTimeout = async ({ kill, forceKillAfterDelay, context, controllerSig
|
|
|
13991
14070
|
};
|
|
13992
14071
|
|
|
13993
14072
|
//#endregion
|
|
13994
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14073
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/utils/abort-signal.js
|
|
13995
14074
|
const onAbortedSignal = async (mainSignal, stopSignal) => {
|
|
13996
14075
|
if (!mainSignal.aborted) await once(mainSignal, "abort", { signal: stopSignal });
|
|
13997
14076
|
};
|
|
13998
14077
|
|
|
13999
14078
|
//#endregion
|
|
14000
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14079
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/terminate/cancel.js
|
|
14001
14080
|
const validateCancelSignal = ({ cancelSignal }) => {
|
|
14002
14081
|
if (cancelSignal !== void 0 && Object.prototype.toString.call(cancelSignal) !== "[object AbortSignal]") throw new Error(`The \`cancelSignal\` option must be an AbortSignal: ${String(cancelSignal)}`);
|
|
14003
14082
|
};
|
|
@@ -14010,7 +14089,7 @@ const terminateOnCancel = async (kill, cancelSignal, context, { signal }) => {
|
|
|
14010
14089
|
};
|
|
14011
14090
|
|
|
14012
14091
|
//#endregion
|
|
14013
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14092
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/validation.js
|
|
14014
14093
|
const validateIpcMethod = ({ methodName, isSubprocess, ipc, isConnected }) => {
|
|
14015
14094
|
validateIpcOption(methodName, isSubprocess, ipc);
|
|
14016
14095
|
validateConnection(methodName, isSubprocess, isConnected);
|
|
@@ -14051,7 +14130,7 @@ const handleSerializationError = ({ error, methodName, isSubprocess, message })
|
|
|
14051
14130
|
if (isSerializationError(error)) throw new Error(`${getMethodName(methodName, isSubprocess)}'s argument type is invalid: the message cannot be serialized: ${String(message)}.`, { cause: error });
|
|
14052
14131
|
};
|
|
14053
14132
|
const isSerializationError = ({ code, message }) => SERIALIZATION_ERROR_CODES.has(code) || SERIALIZATION_ERROR_MESSAGES.some((serializationErrorMessage) => message.includes(serializationErrorMessage));
|
|
14054
|
-
const SERIALIZATION_ERROR_CODES = new Set(["ERR_MISSING_ARGS", "ERR_INVALID_ARG_TYPE"]);
|
|
14133
|
+
const SERIALIZATION_ERROR_CODES = /* @__PURE__ */ new Set(["ERR_MISSING_ARGS", "ERR_INVALID_ARG_TYPE"]);
|
|
14055
14134
|
const SERIALIZATION_ERROR_MESSAGES = [
|
|
14056
14135
|
"could not be cloned",
|
|
14057
14136
|
"circular structure",
|
|
@@ -14065,7 +14144,7 @@ const disconnect = (anyProcess) => {
|
|
|
14065
14144
|
};
|
|
14066
14145
|
|
|
14067
14146
|
//#endregion
|
|
14068
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14147
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/utils/deferred.js
|
|
14069
14148
|
const createDeferred = () => {
|
|
14070
14149
|
const methods = {};
|
|
14071
14150
|
const promise = new Promise((resolve, reject) => {
|
|
@@ -14078,7 +14157,7 @@ const createDeferred = () => {
|
|
|
14078
14157
|
};
|
|
14079
14158
|
|
|
14080
14159
|
//#endregion
|
|
14081
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14160
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/utils/max-listeners.js
|
|
14082
14161
|
const incrementMaxListeners = (eventEmitter, maxListenersIncrement, signal) => {
|
|
14083
14162
|
const maxListeners = eventEmitter.getMaxListeners();
|
|
14084
14163
|
if (maxListeners === 0 || maxListeners === Infinity) return;
|
|
@@ -14089,7 +14168,7 @@ const incrementMaxListeners = (eventEmitter, maxListenersIncrement, signal) => {
|
|
|
14089
14168
|
};
|
|
14090
14169
|
|
|
14091
14170
|
//#endregion
|
|
14092
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14171
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/reference.js
|
|
14093
14172
|
const addReference = (channel, reference) => {
|
|
14094
14173
|
if (reference) addReferenceCount(channel);
|
|
14095
14174
|
};
|
|
@@ -14114,7 +14193,7 @@ const redoAddedReferences = (channel, isSubprocess) => {
|
|
|
14114
14193
|
};
|
|
14115
14194
|
|
|
14116
14195
|
//#endregion
|
|
14117
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14196
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/incoming.js
|
|
14118
14197
|
const onMessage = async ({ anyProcess, channel, isSubprocess, ipcEmitter }, wrappedMessage) => {
|
|
14119
14198
|
if (handleStrictResponse(wrappedMessage) || handleAbort(wrappedMessage)) return;
|
|
14120
14199
|
if (!INCOMING_MESSAGES.has(anyProcess)) INCOMING_MESSAGES.set(anyProcess, []);
|
|
@@ -14148,7 +14227,7 @@ const onDisconnect = async ({ anyProcess, channel, isSubprocess, ipcEmitter, bou
|
|
|
14148
14227
|
const INCOMING_MESSAGES = /* @__PURE__ */ new WeakMap();
|
|
14149
14228
|
|
|
14150
14229
|
//#endregion
|
|
14151
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14230
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/forward.js
|
|
14152
14231
|
const getIpcEmitter = (anyProcess, channel, isSubprocess) => {
|
|
14153
14232
|
if (IPC_EMITTERS.has(anyProcess)) return IPC_EMITTERS.get(anyProcess);
|
|
14154
14233
|
const ipcEmitter = new EventEmitter();
|
|
@@ -14186,10 +14265,11 @@ const isConnected = (anyProcess) => {
|
|
|
14186
14265
|
};
|
|
14187
14266
|
|
|
14188
14267
|
//#endregion
|
|
14189
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14268
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/strict.js
|
|
14190
14269
|
const handleSendStrict = ({ anyProcess, channel, isSubprocess, message, strict }) => {
|
|
14191
14270
|
if (!strict) return message;
|
|
14192
|
-
const
|
|
14271
|
+
const ipcEmitter = getIpcEmitter(anyProcess, channel, isSubprocess);
|
|
14272
|
+
const hasListeners = hasMessageListeners(anyProcess, ipcEmitter);
|
|
14193
14273
|
return {
|
|
14194
14274
|
id: count++,
|
|
14195
14275
|
type: REQUEST_TYPE,
|
|
@@ -14258,7 +14338,7 @@ const REQUEST_TYPE = "execa:ipc:request";
|
|
|
14258
14338
|
const RESPONSE_TYPE = "execa:ipc:response";
|
|
14259
14339
|
|
|
14260
14340
|
//#endregion
|
|
14261
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14341
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/outgoing.js
|
|
14262
14342
|
const startSendMessage = (anyProcess, wrappedMessage, strict) => {
|
|
14263
14343
|
if (!OUTGOING_MESSAGES.has(anyProcess)) OUTGOING_MESSAGES.set(anyProcess, /* @__PURE__ */ new Set());
|
|
14264
14344
|
const outgoingMessages = OUTGOING_MESSAGES.get(anyProcess);
|
|
@@ -14293,7 +14373,7 @@ const getMinListenerCount = (anyProcess) => getOptions(anyProcess) !== void 0 &&
|
|
|
14293
14373
|
const getOptions = (anyProcess) => IPC_SUBPROCESS_OPTIONS.get(anyProcess);
|
|
14294
14374
|
|
|
14295
14375
|
//#endregion
|
|
14296
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14376
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/send.js
|
|
14297
14377
|
const sendMessage$1 = ({ anyProcess, channel, isSubprocess, ipc }, message, { strict = false } = {}) => {
|
|
14298
14378
|
const methodName = "sendMessage";
|
|
14299
14379
|
validateIpcMethod({
|
|
@@ -14363,7 +14443,7 @@ const getSendMethod = (anyProcess) => {
|
|
|
14363
14443
|
const PROCESS_SEND_METHODS = /* @__PURE__ */ new WeakMap();
|
|
14364
14444
|
|
|
14365
14445
|
//#endregion
|
|
14366
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14446
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/graceful.js
|
|
14367
14447
|
const sendAbort = (subprocess, message) => {
|
|
14368
14448
|
const methodName = "cancelSignal";
|
|
14369
14449
|
validateConnection(methodName, false, subprocess.connected);
|
|
@@ -14414,7 +14494,7 @@ const abortOnDisconnect = () => {
|
|
|
14414
14494
|
const cancelController = new AbortController();
|
|
14415
14495
|
|
|
14416
14496
|
//#endregion
|
|
14417
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14497
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/terminate/graceful.js
|
|
14418
14498
|
const validateGracefulCancel = ({ gracefulCancel, cancelSignal, ipc, serialization }) => {
|
|
14419
14499
|
if (!gracefulCancel) return;
|
|
14420
14500
|
if (cancelSignal === void 0) throw new Error("The `cancelSignal` option must be defined when setting the `gracefulCancel` option.");
|
|
@@ -14431,7 +14511,8 @@ const throwOnGracefulCancel = ({ subprocess, kill, cancelSignal, gracefulCancel,
|
|
|
14431
14511
|
})] : [];
|
|
14432
14512
|
const sendOnAbort = async ({ subprocess, kill, cancelSignal, forceKillAfterDelay, context, controller: { signal } }) => {
|
|
14433
14513
|
await onAbortedSignal(cancelSignal, signal);
|
|
14434
|
-
|
|
14514
|
+
const reason = getReason(cancelSignal);
|
|
14515
|
+
await sendAbort(subprocess, reason);
|
|
14435
14516
|
killOnTimeout({
|
|
14436
14517
|
kill,
|
|
14437
14518
|
forceKillAfterDelay,
|
|
@@ -14454,7 +14535,7 @@ const getReason = ({ reason }) => {
|
|
|
14454
14535
|
};
|
|
14455
14536
|
|
|
14456
14537
|
//#endregion
|
|
14457
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14538
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/terminate/timeout.js
|
|
14458
14539
|
const validateTimeout = ({ timeout }) => {
|
|
14459
14540
|
if (timeout !== void 0 && (!Number.isFinite(timeout) || timeout < 0)) throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${timeout}\` (${typeof timeout})`);
|
|
14460
14541
|
};
|
|
@@ -14467,7 +14548,7 @@ const killAfterTimeout = async (kill, timeout, context, { signal }) => {
|
|
|
14467
14548
|
};
|
|
14468
14549
|
|
|
14469
14550
|
//#endregion
|
|
14470
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14551
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/methods/node.js
|
|
14471
14552
|
const mapNode = ({ options }) => {
|
|
14472
14553
|
if (options.node === false) throw new TypeError("The \"node\" option cannot be false with `execaNode()`.");
|
|
14473
14554
|
return { options: {
|
|
@@ -14510,7 +14591,7 @@ const handleNodeOption = (file, commandArguments, { node: shouldHandleNode = fal
|
|
|
14510
14591
|
};
|
|
14511
14592
|
|
|
14512
14593
|
//#endregion
|
|
14513
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14594
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/ipc-input.js
|
|
14514
14595
|
const validateIpcInputOption = ({ ipcInput, ipc, serialization }) => {
|
|
14515
14596
|
if (ipcInput === void 0) return;
|
|
14516
14597
|
if (!ipc) throw new Error("The `ipcInput` option cannot be set unless the `ipc` option is `true`.");
|
|
@@ -14545,7 +14626,7 @@ const sendIpcInput = async (subprocess, ipcInput, ipc) => {
|
|
|
14545
14626
|
};
|
|
14546
14627
|
|
|
14547
14628
|
//#endregion
|
|
14548
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14629
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/encoding-option.js
|
|
14549
14630
|
const validateEncoding = ({ encoding }) => {
|
|
14550
14631
|
if (ENCODINGS.has(encoding)) return;
|
|
14551
14632
|
const correctEncoding = getCorrectEncoding(encoding);
|
|
@@ -14555,8 +14636,8 @@ Please rename it to ${serializeEncoding(correctEncoding)}.`);
|
|
|
14555
14636
|
throw new TypeError(`Invalid option \`encoding: ${serializeEncoding(encoding)}\`.
|
|
14556
14637
|
Please rename it to one of: ${correctEncodings}.`);
|
|
14557
14638
|
};
|
|
14558
|
-
const TEXT_ENCODINGS = new Set(["utf8", "utf16le"]);
|
|
14559
|
-
const BINARY_ENCODINGS = new Set([
|
|
14639
|
+
const TEXT_ENCODINGS = /* @__PURE__ */ new Set(["utf8", "utf16le"]);
|
|
14640
|
+
const BINARY_ENCODINGS = /* @__PURE__ */ new Set([
|
|
14560
14641
|
"buffer",
|
|
14561
14642
|
"hex",
|
|
14562
14643
|
"base64",
|
|
@@ -14583,12 +14664,12 @@ const serializeEncoding = (encoding) => typeof encoding === "string" ? `"${encod
|
|
|
14583
14664
|
|
|
14584
14665
|
//#endregion
|
|
14585
14666
|
//#region ../../node_modules/.pnpm/which-command@0.1.0/node_modules/which-command/index.js
|
|
14586
|
-
const isWindows$1 =
|
|
14667
|
+
const isWindows$1 = process$1.platform === "win32";
|
|
14587
14668
|
const separatorPattern = isWindows$1 ? /[\/\\]/v : /\//v;
|
|
14588
14669
|
const defaultPathExt = ".COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC";
|
|
14589
14670
|
function resolveOptions(command, options) {
|
|
14590
14671
|
if (typeof command !== "string" || command.length === 0) throw new TypeError("Expected a non-empty string.");
|
|
14591
|
-
const { cwd =
|
|
14672
|
+
const { cwd = process$1.cwd(), path: searchPath = process$1.env.PATH ?? (isWindows$1 ? process$1.env.Path : void 0) ?? "", pathExt = process$1.env.PATHEXT || defaultPathExt } = options;
|
|
14592
14673
|
return {
|
|
14593
14674
|
cwd,
|
|
14594
14675
|
searchPath,
|
|
@@ -14638,27 +14719,31 @@ function whichCommandSync(command, options = {}) {
|
|
|
14638
14719
|
}
|
|
14639
14720
|
|
|
14640
14721
|
//#endregion
|
|
14641
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14722
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/command-file.js
|
|
14642
14723
|
const parseCommandFile = (file, commandArguments, options) => {
|
|
14643
14724
|
const parsed = {
|
|
14644
14725
|
file,
|
|
14645
14726
|
commandArguments: [...commandArguments],
|
|
14646
14727
|
options
|
|
14647
14728
|
};
|
|
14648
|
-
if (options.shell ||
|
|
14729
|
+
if (options.shell || process$1.platform !== "win32") return parsed;
|
|
14649
14730
|
return escapeWindowsCommand(parsed);
|
|
14650
14731
|
};
|
|
14651
14732
|
const directlyExecutableRegExp = /\.(?:com|exe)$/i;
|
|
14652
14733
|
const batchFileRegExp = /\.(?:bat|cmd)$/i;
|
|
14653
14734
|
const escapeWindowsCommand = (parsed) => {
|
|
14654
14735
|
const resolvedFile = resolveWithShebang(parsed);
|
|
14655
|
-
if (resolvedFile !== void 0 && directlyExecutableRegExp.test(resolvedFile))
|
|
14736
|
+
if (resolvedFile !== void 0 && directlyExecutableRegExp.test(resolvedFile)) {
|
|
14737
|
+
if (parsed.options.argv0 === void 0) parsed.options.argv0 = parsed.file;
|
|
14738
|
+
parsed.file = resolvedFile;
|
|
14739
|
+
return parsed;
|
|
14740
|
+
}
|
|
14656
14741
|
for (const value of [parsed.file, ...parsed.commandArguments]) assertNoLineBreak(value);
|
|
14657
14742
|
const isDoubleEscape = resolvedFile !== void 0 && batchFileRegExp.test(resolvedFile);
|
|
14658
|
-
const commandLine = `"${[escapeMetaChars(path.normalize(parsed.file)), ...parsed.commandArguments.map((argument) => escapeArgument(argument, isDoubleEscape))].join(" ")}"`;
|
|
14743
|
+
const commandLine = `"${[escapeMetaChars(path.normalize(resolvedFile ?? parsed.file)), ...parsed.commandArguments.map((argument) => escapeArgument(argument, isDoubleEscape))].join(" ")}"`;
|
|
14659
14744
|
parsed.options.windowsVerbatimArguments = true;
|
|
14660
14745
|
return {
|
|
14661
|
-
file:
|
|
14746
|
+
file: process$1.env.comspec || "cmd.exe",
|
|
14662
14747
|
commandArguments: [
|
|
14663
14748
|
"/d",
|
|
14664
14749
|
"/s",
|
|
@@ -14677,11 +14762,38 @@ const resolveWithShebang = (parsed) => {
|
|
|
14677
14762
|
return resolvePath(parsed);
|
|
14678
14763
|
};
|
|
14679
14764
|
const resolvePath = (parsed) => {
|
|
14680
|
-
const environment = parsed.options.env ||
|
|
14681
|
-
|
|
14682
|
-
|
|
14683
|
-
|
|
14765
|
+
const environment = parsed.options.env || process$1.env;
|
|
14766
|
+
const cwd = parsed.options.cwd ?? process$1.cwd();
|
|
14767
|
+
const environmentPathExt = getWindowsEnvironmentValue(environment, "PATHEXT");
|
|
14768
|
+
const commandExtension = path.extname(parsed.file);
|
|
14769
|
+
const pathExt = commandExtension === "" ? environmentPathExt : `${commandExtension}${path.delimiter}${environmentPathExt ?? ""}`;
|
|
14770
|
+
if (hasWindowsPathSeparator(parsed.file)) return whichCommandSync(path.resolve(cwd, parsed.file), {
|
|
14771
|
+
cwd,
|
|
14772
|
+
pathExt
|
|
14684
14773
|
});
|
|
14774
|
+
const resolveOptions = {
|
|
14775
|
+
cwd,
|
|
14776
|
+
path: getWindowsEnvironmentValue(environment, "PATH") ?? getWindowsEnvironmentValue(process$1.env, "PATH") ?? "",
|
|
14777
|
+
pathExt
|
|
14778
|
+
};
|
|
14779
|
+
return shouldSearchCurrentDirectory(environment) ? whichCommandSync(parsed.file, resolveOptions) : resolvePathDirectories(parsed.file, resolveOptions);
|
|
14780
|
+
};
|
|
14781
|
+
const hasWindowsPathSeparator = (file) => file.includes("/") || file.includes("\\") || file.includes(":");
|
|
14782
|
+
const shouldSearchCurrentDirectory = (environment) => getWindowsEnvironmentValue(process$1.env, "NODEFAULTCURRENTDIRECTORYINEXEPATH") === void 0 && getWindowsEnvironmentValue(environment, "NODEFAULTCURRENTDIRECTORYINEXEPATH") === void 0;
|
|
14783
|
+
const resolvePathDirectories = (file, { cwd, path: searchPath, pathExt }) => {
|
|
14784
|
+
for (const directory of searchPath.split(path.delimiter)) {
|
|
14785
|
+
const unquotedDirectory = directory.length > 1 && directory.startsWith("\"") && directory.endsWith("\"") ? directory.slice(1, -1) : directory;
|
|
14786
|
+
if (unquotedDirectory === "") continue;
|
|
14787
|
+
const resolvedFile = whichCommandSync(path.resolve(cwd, unquotedDirectory, file), {
|
|
14788
|
+
cwd,
|
|
14789
|
+
pathExt
|
|
14790
|
+
});
|
|
14791
|
+
if (resolvedFile !== void 0) return resolvedFile;
|
|
14792
|
+
}
|
|
14793
|
+
};
|
|
14794
|
+
const getWindowsEnvironmentValue = (environment, name) => {
|
|
14795
|
+
const environmentKey = Object.keys(environment).sort().find((key) => key.toUpperCase() === name);
|
|
14796
|
+
return environmentKey === void 0 ? void 0 : environment[environmentKey];
|
|
14685
14797
|
};
|
|
14686
14798
|
const SHEBANG_BYTE_LENGTH = 150;
|
|
14687
14799
|
const readShebang = (file) => {
|
|
@@ -14715,22 +14827,23 @@ const metaCharsRegExp = /[()\][%!^"`<>&|;, *?]/g;
|
|
|
14715
14827
|
const escapeMetaChars = (value) => value.replaceAll(metaCharsRegExp, "^$&");
|
|
14716
14828
|
const backslashRunRegExp = /\\+/g;
|
|
14717
14829
|
const escapeArgument = (rawArgument, doubleEscape) => {
|
|
14718
|
-
const
|
|
14830
|
+
const argument = `${rawArgument}`.replaceAll(backslashRunRegExp, (backslashes, offset, string) => {
|
|
14719
14831
|
const nextCharacter = string[offset + backslashes.length];
|
|
14720
14832
|
return nextCharacter === "\"" || nextCharacter === void 0 ? backslashes.repeat(2) : backslashes;
|
|
14721
|
-
}).replaceAll("\"", "\\\"")
|
|
14833
|
+
}).replaceAll("\"", "\\\"");
|
|
14834
|
+
const escapedArgument = escapeMetaChars(`"${argument}"`);
|
|
14722
14835
|
return doubleEscape ? escapeMetaChars(escapedArgument) : escapedArgument;
|
|
14723
14836
|
};
|
|
14724
14837
|
|
|
14725
14838
|
//#endregion
|
|
14726
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14839
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/cwd.js
|
|
14727
14840
|
const normalizeCwd = (cwd = getDefaultCwd()) => {
|
|
14728
14841
|
const cwdString = safeNormalizeFileUrl(cwd, "The \"cwd\" option");
|
|
14729
14842
|
return path.resolve(cwdString);
|
|
14730
14843
|
};
|
|
14731
14844
|
const getDefaultCwd = () => {
|
|
14732
14845
|
try {
|
|
14733
|
-
return
|
|
14846
|
+
return process$1.cwd();
|
|
14734
14847
|
} catch (error) {
|
|
14735
14848
|
error.message = `The current directory does not exist.\n${error.message}`;
|
|
14736
14849
|
throw error;
|
|
@@ -14749,7 +14862,8 @@ const fixCwdError = (originalMessage, cwd) => {
|
|
|
14749
14862
|
};
|
|
14750
14863
|
|
|
14751
14864
|
//#endregion
|
|
14752
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14865
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/options.js
|
|
14866
|
+
const cmdExeRegExp = /^cmd(?:\.exe)?$/i;
|
|
14753
14867
|
const normalizeOptions = (filePath, rawArguments, rawOptions) => {
|
|
14754
14868
|
const sanitizedOptions = {
|
|
14755
14869
|
__proto__: null,
|
|
@@ -14757,19 +14871,20 @@ const normalizeOptions = (filePath, rawArguments, rawOptions) => {
|
|
|
14757
14871
|
};
|
|
14758
14872
|
sanitizedOptions.cwd = normalizeCwd(sanitizedOptions.cwd);
|
|
14759
14873
|
const [processedFile, processedArguments, processedOptions] = handleNodeOption(filePath, rawArguments, sanitizedOptions);
|
|
14760
|
-
const
|
|
14761
|
-
const options = addDefaultOptions(
|
|
14874
|
+
const fdOptions = normalizeFdSpecificOptions(processedOptions);
|
|
14875
|
+
const options = addDefaultOptions(fdOptions);
|
|
14876
|
+
options.env = getEnv(options);
|
|
14877
|
+
const { file, commandArguments } = parseCommandFile(processedFile, processedArguments, options);
|
|
14762
14878
|
validateTimeout(options);
|
|
14763
14879
|
validateEncoding(options);
|
|
14764
14880
|
validateIpcInputOption(options);
|
|
14765
14881
|
validateCancelSignal(options);
|
|
14766
14882
|
validateGracefulCancel(options);
|
|
14767
14883
|
options.shell = normalizeFileUrl(options.shell);
|
|
14768
|
-
options.env = getEnv(options);
|
|
14769
14884
|
options.killSignal = normalizeKillSignal(options.killSignal);
|
|
14770
14885
|
options.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);
|
|
14771
14886
|
options.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);
|
|
14772
|
-
if (
|
|
14887
|
+
if (process$1.platform === "win32" && cmdExeRegExp.test(path.basename(file))) commandArguments.unshift("/q");
|
|
14773
14888
|
return {
|
|
14774
14889
|
file,
|
|
14775
14890
|
commandArguments,
|
|
@@ -14798,7 +14913,7 @@ const addDefaultOptions = ({ extendEnv = true, preferLocal = false, cwd, localDi
|
|
|
14798
14913
|
});
|
|
14799
14914
|
const getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath }) => {
|
|
14800
14915
|
const env = extendEnv ? {
|
|
14801
|
-
...
|
|
14916
|
+
...process$1.env,
|
|
14802
14917
|
...envOption
|
|
14803
14918
|
} : envOption;
|
|
14804
14919
|
if (preferLocal || node) return npmRunPathEnv({
|
|
@@ -14812,7 +14927,7 @@ const getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory,
|
|
|
14812
14927
|
};
|
|
14813
14928
|
|
|
14814
14929
|
//#endregion
|
|
14815
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
14930
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/shell.js
|
|
14816
14931
|
const concatenateShell = (file, commandArguments, options) => options.shell && commandArguments.length > 0 ? [
|
|
14817
14932
|
[file, ...commandArguments].join(" "),
|
|
14818
14933
|
[],
|
|
@@ -14929,7 +15044,7 @@ const u = Object.create(a, {
|
|
|
14929
15044
|
}
|
|
14930
15045
|
});
|
|
14931
15046
|
function h({ preventCancel: r = !1 } = {}) {
|
|
14932
|
-
const
|
|
15047
|
+
const e = this.getReader(), t = new c(e, r), s = Object.create(u);
|
|
14933
15048
|
return s[n] = t, s;
|
|
14934
15049
|
}
|
|
14935
15050
|
|
|
@@ -14978,14 +15093,17 @@ const getStreamContents$1 = async (stream, { init, convertChunk, getSize, trunca
|
|
|
14978
15093
|
const state = init();
|
|
14979
15094
|
state.length = 0;
|
|
14980
15095
|
try {
|
|
14981
|
-
for await (const chunk of asyncIterable)
|
|
14982
|
-
convertedChunk
|
|
14983
|
-
|
|
14984
|
-
|
|
14985
|
-
|
|
14986
|
-
|
|
14987
|
-
|
|
14988
|
-
|
|
15096
|
+
for await (const chunk of asyncIterable) {
|
|
15097
|
+
const convertedChunk = convertChunk[getChunkType(chunk)](chunk, state);
|
|
15098
|
+
appendChunk({
|
|
15099
|
+
convertedChunk,
|
|
15100
|
+
state,
|
|
15101
|
+
getSize,
|
|
15102
|
+
truncateChunk,
|
|
15103
|
+
addChunk,
|
|
15104
|
+
maxBuffer
|
|
15105
|
+
});
|
|
15106
|
+
}
|
|
14989
15107
|
appendFinalChunk({
|
|
14990
15108
|
state,
|
|
14991
15109
|
convertChunk,
|
|
@@ -15171,7 +15289,7 @@ const stringMethods = {
|
|
|
15171
15289
|
};
|
|
15172
15290
|
|
|
15173
15291
|
//#endregion
|
|
15174
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15292
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/io/max-buffer.js
|
|
15175
15293
|
const handleMaxBuffer = ({ error, stream, readableObjectMode, lines, encoding, fdNumber }) => {
|
|
15176
15294
|
if (!(error instanceof MaxBufferError)) throw error;
|
|
15177
15295
|
if (fdNumber === "all") return error;
|
|
@@ -15227,7 +15345,7 @@ const truncateMaxBufferSync = (result, isMaxBuffer, maxBuffer) => {
|
|
|
15227
15345
|
const getMaxBufferSync = ([, stdoutMaxBuffer]) => stdoutMaxBuffer;
|
|
15228
15346
|
|
|
15229
15347
|
//#endregion
|
|
15230
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15348
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/return/message.js
|
|
15231
15349
|
const createMessages = ({ stdio, all, ipcOutput, originalError, signal, signalDescription, exitCode, escapedCommand, timedOut, isCanceled, isGracefullyCanceled, isMaxBuffer, isForcefullyTerminated, forceKillAfterDelay, killSignal, maxBuffer, timeout, cwd }) => {
|
|
15232
15350
|
const errorCode = originalError?.code;
|
|
15233
15351
|
const prefix = getErrorPrefix({
|
|
@@ -15277,7 +15395,8 @@ const getErrorPrefix = ({ originalError, timedOut, timeout, isMaxBuffer, maxBuff
|
|
|
15277
15395
|
const getForcefulSuffix = (isForcefullyTerminated, forceKillAfterDelay) => isForcefullyTerminated ? ` and was forcefully terminated after ${forceKillAfterDelay} milliseconds` : "";
|
|
15278
15396
|
const getOriginalMessage = (originalError, cwd) => {
|
|
15279
15397
|
if (originalError instanceof DiscardedError) return;
|
|
15280
|
-
const
|
|
15398
|
+
const originalMessage = isExecaError(originalError) ? originalError.originalMessage : String(originalError?.message ?? originalError);
|
|
15399
|
+
const escapedOriginalMessage = escapeLines(fixCwdError(originalMessage, cwd));
|
|
15281
15400
|
return escapedOriginalMessage === "" ? void 0 : escapedOriginalMessage;
|
|
15282
15401
|
};
|
|
15283
15402
|
const serializeIpcMessage = (ipcMessage) => typeof ipcMessage === "string" ? ipcMessage : inspect(ipcMessage);
|
|
@@ -15289,7 +15408,7 @@ const serializeMessageItem = (messageItem) => {
|
|
|
15289
15408
|
};
|
|
15290
15409
|
|
|
15291
15410
|
//#endregion
|
|
15292
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15411
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/return/result.js
|
|
15293
15412
|
const makeSuccessResult = ({ command, escapedCommand, stdio, all, ipcOutput, options: { cwd }, startTime }) => omitUndefinedProperties({
|
|
15294
15413
|
command,
|
|
15295
15414
|
escapedCommand,
|
|
@@ -15491,26 +15610,28 @@ function prettyMilliseconds(milliseconds, options) {
|
|
|
15491
15610
|
add(Number(parsed.hours), "hour", "h");
|
|
15492
15611
|
}
|
|
15493
15612
|
add(Number(parsed.minutes), "minute", "m");
|
|
15494
|
-
if (!options.hideSeconds)
|
|
15495
|
-
|
|
15496
|
-
|
|
15497
|
-
|
|
15498
|
-
|
|
15499
|
-
|
|
15500
|
-
|
|
15501
|
-
|
|
15502
|
-
|
|
15503
|
-
|
|
15613
|
+
if (!options.hideSeconds) {
|
|
15614
|
+
if (options.separateMilliseconds || options.formatSubMilliseconds || !options.colonNotation && milliseconds < 1e3 && !options.subSecondsAsDecimals) {
|
|
15615
|
+
const seconds = Number(parsed.seconds);
|
|
15616
|
+
const milliseconds = Number(parsed.milliseconds);
|
|
15617
|
+
const microseconds = Number(parsed.microseconds);
|
|
15618
|
+
const nanoseconds = Number(parsed.nanoseconds);
|
|
15619
|
+
add(seconds, "second", "s");
|
|
15620
|
+
if (options.formatSubMilliseconds) {
|
|
15621
|
+
add(milliseconds, "millisecond", "ms");
|
|
15622
|
+
add(microseconds, "microsecond", "µs");
|
|
15623
|
+
add(nanoseconds, "nanosecond", "ns");
|
|
15624
|
+
} else {
|
|
15625
|
+
const millisecondsAndBelow = milliseconds + microseconds / 1e3 + nanoseconds / 1e6;
|
|
15626
|
+
const millisecondsDecimalDigits = typeof options.millisecondsDecimalDigits === "number" ? options.millisecondsDecimalDigits : 0;
|
|
15627
|
+
const millisecondsString = millisecondsDecimalDigits ? millisecondsAndBelow.toFixed(millisecondsDecimalDigits) : millisecondsAndBelow >= 1 ? Math.round(millisecondsAndBelow) : Math.ceil(millisecondsAndBelow);
|
|
15628
|
+
add(Number.parseFloat(millisecondsString), "millisecond", "ms", millisecondsString);
|
|
15629
|
+
}
|
|
15504
15630
|
} else {
|
|
15505
|
-
const
|
|
15506
|
-
const
|
|
15507
|
-
|
|
15508
|
-
add(Number.parseFloat(millisecondsString), "millisecond", "ms", millisecondsString);
|
|
15631
|
+
const secondsFixed = floorDecimals((isBigInt ? Number(milliseconds % ONE_DAY_IN_MILLISECONDS) : milliseconds) / 1e3 % 60, typeof options.secondsDecimalDigits === "number" ? options.secondsDecimalDigits : 1);
|
|
15632
|
+
const secondsString = options.keepDecimalsOnWholeSeconds ? secondsFixed : secondsFixed.replace(/\.0+$/, "");
|
|
15633
|
+
add(Number.parseFloat(secondsString), "second", "s", secondsString);
|
|
15509
15634
|
}
|
|
15510
|
-
} else {
|
|
15511
|
-
const secondsFixed = floorDecimals((isBigInt ? Number(milliseconds % ONE_DAY_IN_MILLISECONDS) : milliseconds) / 1e3 % 60, typeof options.secondsDecimalDigits === "number" ? options.secondsDecimalDigits : 1);
|
|
15512
|
-
const secondsString = options.keepDecimalsOnWholeSeconds ? secondsFixed : secondsFixed.replace(/\.0+$/, "");
|
|
15513
|
-
add(Number.parseFloat(secondsString), "second", "s", secondsString);
|
|
15514
15635
|
}
|
|
15515
15636
|
if (result.length === 0) return sign + "0" + (options.verbose ? " milliseconds" : "ms");
|
|
15516
15637
|
const separator = options.colonNotation ? ":" : " ";
|
|
@@ -15519,7 +15640,7 @@ function prettyMilliseconds(milliseconds, options) {
|
|
|
15519
15640
|
}
|
|
15520
15641
|
|
|
15521
15642
|
//#endregion
|
|
15522
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15643
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/error.js
|
|
15523
15644
|
const logError = (result, verboseInfo) => {
|
|
15524
15645
|
if (result.failed) verboseLog({
|
|
15525
15646
|
type: "error",
|
|
@@ -15530,23 +15651,24 @@ const logError = (result, verboseInfo) => {
|
|
|
15530
15651
|
};
|
|
15531
15652
|
|
|
15532
15653
|
//#endregion
|
|
15533
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15654
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/complete.js
|
|
15534
15655
|
const logResult = (result, verboseInfo) => {
|
|
15535
15656
|
if (!isVerbose(verboseInfo)) return;
|
|
15536
15657
|
logError(result, verboseInfo);
|
|
15537
15658
|
logDuration(result, verboseInfo);
|
|
15538
15659
|
};
|
|
15539
15660
|
const logDuration = (result, verboseInfo) => {
|
|
15661
|
+
const verboseMessage = `(done in ${prettyMilliseconds(result.durationMs)})`;
|
|
15540
15662
|
verboseLog({
|
|
15541
15663
|
type: "duration",
|
|
15542
|
-
verboseMessage
|
|
15664
|
+
verboseMessage,
|
|
15543
15665
|
verboseInfo,
|
|
15544
15666
|
result
|
|
15545
15667
|
});
|
|
15546
15668
|
};
|
|
15547
15669
|
|
|
15548
15670
|
//#endregion
|
|
15549
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15671
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/return/reject.js
|
|
15550
15672
|
const handleResult = (result, verboseInfo, { reject }) => {
|
|
15551
15673
|
logResult(result, verboseInfo);
|
|
15552
15674
|
if (result.failed && reject) throw result;
|
|
@@ -15554,7 +15676,7 @@ const handleResult = (result, verboseInfo, { reject }) => {
|
|
|
15554
15676
|
};
|
|
15555
15677
|
|
|
15556
15678
|
//#endregion
|
|
15557
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15679
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/stdio/type.js
|
|
15558
15680
|
const getStdioItemType = (value, optionName) => {
|
|
15559
15681
|
if (isAsyncGenerator(value)) return "asyncGenerator";
|
|
15560
15682
|
if (isSyncGenerator(value)) return "generator";
|
|
@@ -15609,12 +15731,12 @@ const isTransformOptions = (value) => isPlainObject(value) && (value.transform !
|
|
|
15609
15731
|
const isUrl = (value) => Object.prototype.toString.call(value) === "[object URL]";
|
|
15610
15732
|
const isRegularUrl = (value) => isUrl(value) && value.protocol !== "file:";
|
|
15611
15733
|
const isFilePathObject = (value) => isPlainObject(value) && Object.keys(value).length > 0 && Object.keys(value).every((key) => FILE_PATH_KEYS.has(key)) && isFilePathString(value.file);
|
|
15612
|
-
const FILE_PATH_KEYS = new Set(["file", "append"]);
|
|
15734
|
+
const FILE_PATH_KEYS = /* @__PURE__ */ new Set(["file", "append"]);
|
|
15613
15735
|
const isFilePathString = (file) => typeof file === "string";
|
|
15614
15736
|
const isStdioValueObject = (value) => isPlainObject(value) && Object.keys(value).length > 0 && Object.keys(value).every((key) => STDIO_VALUE_KEYS.has(key)) && "value" in value;
|
|
15615
|
-
const STDIO_VALUE_KEYS = new Set(["value", "input"]);
|
|
15737
|
+
const STDIO_VALUE_KEYS = /* @__PURE__ */ new Set(["value", "input"]);
|
|
15616
15738
|
const isUnknownStdioString = (type, value) => type === "native" && typeof value === "string" && !KNOWN_STDIO_STRINGS.has(value);
|
|
15617
|
-
const KNOWN_STDIO_STRINGS = new Set([
|
|
15739
|
+
const KNOWN_STDIO_STRINGS = /* @__PURE__ */ new Set([
|
|
15618
15740
|
"ipc",
|
|
15619
15741
|
"ignore",
|
|
15620
15742
|
"inherit",
|
|
@@ -15628,24 +15750,24 @@ const isTransformStream = (value) => isReadableStream(value?.readable) && isWrit
|
|
|
15628
15750
|
const isAsyncIterableObject = (value) => isObject(value) && typeof value[Symbol.asyncIterator] === "function";
|
|
15629
15751
|
const isIterableObject = (value) => isObject(value) && typeof value[Symbol.iterator] === "function";
|
|
15630
15752
|
const isObject = (value) => typeof value === "object" && value !== null;
|
|
15631
|
-
const TRANSFORM_TYPES = new Set([
|
|
15753
|
+
const TRANSFORM_TYPES = /* @__PURE__ */ new Set([
|
|
15632
15754
|
"generator",
|
|
15633
15755
|
"asyncGenerator",
|
|
15634
15756
|
"duplex",
|
|
15635
15757
|
"webTransform"
|
|
15636
15758
|
]);
|
|
15637
|
-
const FILE_TYPES = new Set([
|
|
15759
|
+
const FILE_TYPES = /* @__PURE__ */ new Set([
|
|
15638
15760
|
"fileUrl",
|
|
15639
15761
|
"filePath",
|
|
15640
15762
|
"fileNumber"
|
|
15641
15763
|
]);
|
|
15642
|
-
const SPECIAL_DUPLICATE_TYPES_SYNC = new Set(["fileUrl", "filePath"]);
|
|
15643
|
-
const SPECIAL_DUPLICATE_TYPES = new Set([
|
|
15764
|
+
const SPECIAL_DUPLICATE_TYPES_SYNC = /* @__PURE__ */ new Set(["fileUrl", "filePath"]);
|
|
15765
|
+
const SPECIAL_DUPLICATE_TYPES = /* @__PURE__ */ new Set([
|
|
15644
15766
|
...SPECIAL_DUPLICATE_TYPES_SYNC,
|
|
15645
15767
|
"webStream",
|
|
15646
15768
|
"nodeStream"
|
|
15647
15769
|
]);
|
|
15648
|
-
const FORBID_DUPLICATE_TYPES = new Set(["webTransform", "duplex"]);
|
|
15770
|
+
const FORBID_DUPLICATE_TYPES = /* @__PURE__ */ new Set(["webTransform", "duplex"]);
|
|
15649
15771
|
const TYPE_TO_MESSAGE = {
|
|
15650
15772
|
generator: "a generator",
|
|
15651
15773
|
asyncGenerator: "an async generator",
|
|
@@ -15664,7 +15786,7 @@ const TYPE_TO_MESSAGE = {
|
|
|
15664
15786
|
};
|
|
15665
15787
|
|
|
15666
15788
|
//#endregion
|
|
15667
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15789
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/transform/object-mode.js
|
|
15668
15790
|
const getTransformObjectModes = (objectMode, index, newTransforms, direction) => direction === "output" ? getOutputObjectModes(objectMode, index, newTransforms) : getInputObjectModes(objectMode, index, newTransforms);
|
|
15669
15791
|
const getOutputObjectModes = (objectMode, index, newTransforms) => {
|
|
15670
15792
|
const writableObjectMode = index !== 0 && newTransforms[index - 1].value.readableObjectMode;
|
|
@@ -15687,7 +15809,7 @@ const getFdObjectMode = (stdioItems, direction) => {
|
|
|
15687
15809
|
};
|
|
15688
15810
|
|
|
15689
15811
|
//#endregion
|
|
15690
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15812
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/transform/normalize.js
|
|
15691
15813
|
const normalizeTransforms = (stdioItems, optionName, direction, options) => [...stdioItems.filter(({ type }) => !TRANSFORM_TYPES.has(type)), ...getTransforms(stdioItems, optionName, direction, options)];
|
|
15692
15814
|
const getTransforms = (stdioItems, optionName, direction, { encoding }) => {
|
|
15693
15815
|
const transforms = stdioItems.filter(({ type }) => TRANSFORM_TYPES.has(type));
|
|
@@ -15768,7 +15890,7 @@ const normalizeGenerator = ({ stdioItem, stdioItem: { value }, index, newTransfo
|
|
|
15768
15890
|
const sortTransforms = (newTransforms, direction) => direction === "input" ? newTransforms.reverse() : newTransforms;
|
|
15769
15891
|
|
|
15770
15892
|
//#endregion
|
|
15771
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15893
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/stdio/direction.js
|
|
15772
15894
|
const getStreamDirection = (stdioItems, fdNumber, optionName) => {
|
|
15773
15895
|
const directions = stdioItems.map((stdioItem) => getStdioItemDirection(stdioItem, fdNumber));
|
|
15774
15896
|
if (directions.includes("input") && directions.includes("output")) throw new TypeError(`The \`${optionName}\` option must not be an array of both readable and writable values.`);
|
|
@@ -15809,22 +15931,22 @@ const guessStreamDirection = {
|
|
|
15809
15931
|
}
|
|
15810
15932
|
};
|
|
15811
15933
|
const getStandardStreamDirection = (value) => {
|
|
15812
|
-
if ([0,
|
|
15934
|
+
if ([0, process$1.stdin].includes(value)) return "input";
|
|
15813
15935
|
if ([
|
|
15814
15936
|
1,
|
|
15815
15937
|
2,
|
|
15816
|
-
|
|
15817
|
-
|
|
15938
|
+
process$1.stdout,
|
|
15939
|
+
process$1.stderr
|
|
15818
15940
|
].includes(value)) return "output";
|
|
15819
15941
|
};
|
|
15820
15942
|
const DEFAULT_DIRECTION = "output";
|
|
15821
15943
|
|
|
15822
15944
|
//#endregion
|
|
15823
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15945
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/array.js
|
|
15824
15946
|
const normalizeIpcStdioArray = (stdioArray, ipc) => ipc ? [...stdioArray, "ipc"] : stdioArray;
|
|
15825
15947
|
|
|
15826
15948
|
//#endregion
|
|
15827
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15949
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/stdio/stdio-option.js
|
|
15828
15950
|
const normalizeStdioOption = ({ stdio, ipc, buffer, ...options }, verboseInfo, isSync) => {
|
|
15829
15951
|
const stdioArray = getStdioArray(stdio, options).map((stdioOption, fdNumber) => addDefaultValue(stdioOption, fdNumber));
|
|
15830
15952
|
validateIpcStdioOption(stdioArray);
|
|
@@ -15866,7 +15988,7 @@ const isOutputPipeObject = (stdioOption, fdNumber) => isStdioValueObject(stdioOp
|
|
|
15866
15988
|
const isFixedOutputPipe = (fdNumber, input) => input === true && (fdNumber === 1 || fdNumber === 2);
|
|
15867
15989
|
|
|
15868
15990
|
//#endregion
|
|
15869
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
15991
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/arguments/fd-options.js
|
|
15870
15992
|
const getToStream = (destination, to = "stdin") => {
|
|
15871
15993
|
const isWritable = true;
|
|
15872
15994
|
const { options, fileDescriptors } = SUBPROCESS_OPTIONS.get(destination);
|
|
@@ -15944,7 +16066,7 @@ const serializeOptionValue = (value) => {
|
|
|
15944
16066
|
};
|
|
15945
16067
|
|
|
15946
16068
|
//#endregion
|
|
15947
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16069
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/stdio/native.js
|
|
15948
16070
|
const handleNativeStream = ({ stdioItem, stdioItem: { type }, isStdioArray, fdNumber, direction, isSync }) => {
|
|
15949
16071
|
if (!isStdioArray || type !== "native") return stdioItem;
|
|
15950
16072
|
return isSync ? handleNativeStreamSync({
|
|
@@ -16013,7 +16135,7 @@ const getStandardStream = (fdNumber, value, optionName) => {
|
|
|
16013
16135
|
};
|
|
16014
16136
|
|
|
16015
16137
|
//#endregion
|
|
16016
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16138
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/stdio/input-option.js
|
|
16017
16139
|
const handleInputOptions = ({ input, inputFile }, fdNumber) => fdNumber === 0 ? [...handleInputOption(input), ...handleInputFileOption(inputFile)] : [];
|
|
16018
16140
|
const handleInputOption = (input) => input === void 0 ? [] : [{
|
|
16019
16141
|
type: getInputType(input),
|
|
@@ -16043,7 +16165,7 @@ const getInputFileType = (inputFile) => {
|
|
|
16043
16165
|
};
|
|
16044
16166
|
|
|
16045
16167
|
//#endregion
|
|
16046
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16168
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/stdio/duplicate.js
|
|
16047
16169
|
const filterDuplicates = (stdioItems) => stdioItems.filter((stdioItemOne, indexOne) => stdioItems.every((stdioItemTwo, indexTwo) => !hasSameValueAndDirection(stdioItemOne, stdioItemTwo) || indexOne >= indexTwo || stdioItemOne.type === "generator" || stdioItemOne.type === "asyncGenerator"));
|
|
16048
16170
|
const hasSameValueAndDirection = (stdioItemOne, stdioItemTwo) => stdioItemOne.value === stdioItemTwo.value && stdioItemOne.direction === stdioItemTwo.direction;
|
|
16049
16171
|
const getDuplicateStream = ({ stdioItem: { type, value, optionName }, direction, fileDescriptors, isSync }) => {
|
|
@@ -16089,7 +16211,8 @@ const validateDuplicateStreamSync = ({ otherStdioItems, type, value, optionName,
|
|
|
16089
16211
|
const getDuplicateStreamInstance = ({ otherStdioItems, type, value, optionName, direction }) => {
|
|
16090
16212
|
const duplicateStdioItems = otherStdioItems.filter((stdioItem) => hasSameValue(stdioItem, value));
|
|
16091
16213
|
if (duplicateStdioItems.length === 0) return;
|
|
16092
|
-
|
|
16214
|
+
const differentStdioItem = duplicateStdioItems.find((stdioItem) => stdioItem.direction !== direction);
|
|
16215
|
+
throwOnDuplicateStream(differentStdioItem, optionName, type);
|
|
16093
16216
|
return direction === "output" ? duplicateStdioItems[0].stream : void 0;
|
|
16094
16217
|
};
|
|
16095
16218
|
const hasSameValue = ({ type, value }, secondValue) => {
|
|
@@ -16098,22 +16221,24 @@ const hasSameValue = ({ type, value }, secondValue) => {
|
|
|
16098
16221
|
return value === secondValue;
|
|
16099
16222
|
};
|
|
16100
16223
|
const validateDuplicateTransform = ({ otherStdioItems, type, value, optionName }) => {
|
|
16101
|
-
|
|
16224
|
+
const duplicateStdioItem = otherStdioItems.find(({ value: { transform } }) => transform === value.transform);
|
|
16225
|
+
throwOnDuplicateStream(duplicateStdioItem, optionName, type);
|
|
16102
16226
|
};
|
|
16103
16227
|
const throwOnDuplicateStream = (stdioItem, optionName, type) => {
|
|
16104
16228
|
if (stdioItem !== void 0) throw new TypeError(`The \`${stdioItem.optionName}\` and \`${optionName}\` options must not target ${TYPE_TO_MESSAGE[type]} that is the same.`);
|
|
16105
16229
|
};
|
|
16106
16230
|
|
|
16107
16231
|
//#endregion
|
|
16108
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16232
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/stdio/handle.js
|
|
16109
16233
|
const handleStdio = (addProperties, options, verboseInfo, isSync) => {
|
|
16234
|
+
const initialFileDescriptors = normalizeStdioOption(options, verboseInfo, isSync).map((stdioOption, fdNumber) => getFileDescriptor({
|
|
16235
|
+
stdioOption,
|
|
16236
|
+
fdNumber,
|
|
16237
|
+
options,
|
|
16238
|
+
isSync
|
|
16239
|
+
}));
|
|
16110
16240
|
const fileDescriptors = getFinalFileDescriptors({
|
|
16111
|
-
initialFileDescriptors
|
|
16112
|
-
stdioOption,
|
|
16113
|
-
fdNumber,
|
|
16114
|
-
options,
|
|
16115
|
-
isSync
|
|
16116
|
-
})),
|
|
16241
|
+
initialFileDescriptors,
|
|
16117
16242
|
addProperties,
|
|
16118
16243
|
options,
|
|
16119
16244
|
isSync
|
|
@@ -16130,13 +16255,14 @@ const getFileDescriptor = ({ stdioOption, fdNumber, options, isSync }) => {
|
|
|
16130
16255
|
optionName
|
|
16131
16256
|
});
|
|
16132
16257
|
const direction = getStreamDirection(initialStdioItems, fdNumber, optionName);
|
|
16133
|
-
const
|
|
16258
|
+
const stdioItems = initialStdioItems.map((stdioItem) => handleNativeStream({
|
|
16134
16259
|
stdioItem,
|
|
16135
16260
|
isStdioArray,
|
|
16136
16261
|
fdNumber,
|
|
16137
16262
|
direction,
|
|
16138
16263
|
isSync
|
|
16139
|
-
}))
|
|
16264
|
+
}));
|
|
16265
|
+
const normalizedStdioItems = normalizeTransforms(stdioItems, optionName, direction, options);
|
|
16140
16266
|
const objectMode = getFdObjectMode(normalizedStdioItems, direction);
|
|
16141
16267
|
validateFileObjectMode(normalizedStdioItems, objectMode);
|
|
16142
16268
|
return {
|
|
@@ -16148,7 +16274,8 @@ const getFileDescriptor = ({ stdioOption, fdNumber, options, isSync }) => {
|
|
|
16148
16274
|
const initializeStdioItems = ({ stdioOption, fdNumber, options, optionName }) => {
|
|
16149
16275
|
const values = Array.isArray(stdioOption) ? stdioOption : [stdioOption];
|
|
16150
16276
|
const inputStdioItems = handleInputOptions(options, fdNumber);
|
|
16151
|
-
const
|
|
16277
|
+
const initialStdioItems = [...omitInheritedStdin(values.map((value) => initializeStdioItem(value, optionName)), inputStdioItems), ...inputStdioItems];
|
|
16278
|
+
const stdioItems = filterDuplicates(initialStdioItems);
|
|
16152
16279
|
const isStdioArray = stdioItems.length > 1;
|
|
16153
16280
|
validateStdioArray(stdioItems, isStdioArray, optionName);
|
|
16154
16281
|
validateStreams(stdioItems);
|
|
@@ -16181,7 +16308,7 @@ const validateStdioArray = (stdioItems, isStdioArray, optionName) => {
|
|
|
16181
16308
|
if (!isStdioArray) return;
|
|
16182
16309
|
for (const { value, optionName } of stdioItems) if (INVALID_STDIO_ARRAY_OPTIONS.has(value)) throw new Error(`The \`${optionName}\` option must not include \`${value}\`.`);
|
|
16183
16310
|
};
|
|
16184
|
-
const INVALID_STDIO_ARRAY_OPTIONS = new Set(["ignore"]);
|
|
16311
|
+
const INVALID_STDIO_ARRAY_OPTIONS = /* @__PURE__ */ new Set(["ignore"]);
|
|
16185
16312
|
const validateStreams = (stdioItems) => {
|
|
16186
16313
|
for (const stdioItem of stdioItems) validateFileStdio(stdioItem);
|
|
16187
16314
|
};
|
|
@@ -16251,7 +16378,7 @@ const forwardStdio = (stdioItems) => {
|
|
|
16251
16378
|
};
|
|
16252
16379
|
|
|
16253
16380
|
//#endregion
|
|
16254
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16381
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/stdio/handle-sync.js
|
|
16255
16382
|
const handleStdioSync = (options, verboseInfo) => handleStdio(addPropertiesSync, options, verboseInfo, true);
|
|
16256
16383
|
const forbiddenIfSync = ({ type, optionName }) => {
|
|
16257
16384
|
throwInvalidSyncValue(optionName, TYPE_TO_MESSAGE[type]);
|
|
@@ -16304,12 +16431,12 @@ const addPropertiesSync = {
|
|
|
16304
16431
|
};
|
|
16305
16432
|
|
|
16306
16433
|
//#endregion
|
|
16307
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16434
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/io/strip-newline.js
|
|
16308
16435
|
const stripNewline = (value, { stripFinalNewline: stripFinalNewline$1 }, fdNumber) => getStripFinalNewline(stripFinalNewline$1, fdNumber) && value !== void 0 && !Array.isArray(value) ? stripFinalNewline(value) : value;
|
|
16309
16436
|
const getStripFinalNewline = (stripFinalNewline, fdNumber) => fdNumber === "all" ? stripFinalNewline[1] || stripFinalNewline[2] : stripFinalNewline[fdNumber];
|
|
16310
16437
|
|
|
16311
16438
|
//#endregion
|
|
16312
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16439
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/transform/split.js
|
|
16313
16440
|
const getSplitLinesGenerator = (binary, preserveNewlines, skipped, state) => binary || skipped ? void 0 : initializeSplitLines(preserveNewlines, state);
|
|
16314
16441
|
const splitLinesSync = (chunk, preserveNewlines, objectMode) => objectMode ? chunk.flatMap((item) => splitLinesItemSync(item, preserveNewlines)) : splitLinesItemSync(chunk, preserveNewlines);
|
|
16315
16442
|
const splitLinesItemSync = (chunk, preserveNewlines) => {
|
|
@@ -16382,7 +16509,7 @@ const linesUint8ArrayInfo = {
|
|
|
16382
16509
|
};
|
|
16383
16510
|
|
|
16384
16511
|
//#endregion
|
|
16385
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16512
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/transform/validate.js
|
|
16386
16513
|
const getValidateTransformInput = (writableObjectMode, optionName) => writableObjectMode ? void 0 : validateStringTransformInput.bind(void 0, optionName);
|
|
16387
16514
|
const validateStringTransformInput = function* (optionName, chunk) {
|
|
16388
16515
|
if (typeof chunk !== "string" && !isUint8Array(chunk) && !Buffer$1.isBuffer(chunk)) throw new TypeError(`The \`${optionName}\` option's transform must use "objectMode: true" to receive as input: ${typeof chunk}.`);
|
|
@@ -16405,7 +16532,7 @@ Instead, \`yield\` should either be called with a value, or not be called at all
|
|
|
16405
16532
|
};
|
|
16406
16533
|
|
|
16407
16534
|
//#endregion
|
|
16408
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16535
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/transform/encoding-transform.js
|
|
16409
16536
|
const getEncodingTransformGenerator = (binary, encoding, skipped) => {
|
|
16410
16537
|
if (skipped) return;
|
|
16411
16538
|
if (binary) return { transform: encodingUint8ArrayGenerator.bind(void 0, new TextEncoder()) };
|
|
@@ -16429,7 +16556,7 @@ const encodingStringFinal = function* (stringDecoder) {
|
|
|
16429
16556
|
};
|
|
16430
16557
|
|
|
16431
16558
|
//#endregion
|
|
16432
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16559
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/transform/run-async.js
|
|
16433
16560
|
const pushChunks = callbackify(async (getChunks, state, getChunksArguments, transformStream) => {
|
|
16434
16561
|
state.currentIterable = getChunks(...getChunksArguments);
|
|
16435
16562
|
try {
|
|
@@ -16465,7 +16592,7 @@ const identityGenerator$1 = function* (chunk) {
|
|
|
16465
16592
|
};
|
|
16466
16593
|
|
|
16467
16594
|
//#endregion
|
|
16468
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16595
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/transform/run-sync.js
|
|
16469
16596
|
const pushChunksSync = (getChunksSync, getChunksArguments, transformStream, done) => {
|
|
16470
16597
|
try {
|
|
16471
16598
|
for (const chunk of getChunksSync(...getChunksArguments)) transformStream.push(chunk);
|
|
@@ -16495,7 +16622,7 @@ const identityGenerator = function* (chunk) {
|
|
|
16495
16622
|
};
|
|
16496
16623
|
|
|
16497
16624
|
//#endregion
|
|
16498
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16625
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/transform/generator.js
|
|
16499
16626
|
const generatorToStream = ({ value, value: { transform, final, writableObjectMode, readableObjectMode }, optionName }, { encoding }) => {
|
|
16500
16627
|
const state = {};
|
|
16501
16628
|
const generators = addInternalGenerators(value, encoding, optionName);
|
|
@@ -16525,7 +16652,10 @@ const generatorToStream = ({ value, value: { transform, final, writableObjectMod
|
|
|
16525
16652
|
const runGeneratorsSync = (chunks, stdioItems, encoding, isInput) => {
|
|
16526
16653
|
const generators = stdioItems.filter(({ type }) => type === "generator");
|
|
16527
16654
|
const reversedGenerators = isInput ? generators.reverse() : generators;
|
|
16528
|
-
for (const { value, optionName } of reversedGenerators)
|
|
16655
|
+
for (const { value, optionName } of reversedGenerators) {
|
|
16656
|
+
const generators = addInternalGenerators(value, encoding, optionName);
|
|
16657
|
+
chunks = runTransformSync(generators, chunks);
|
|
16658
|
+
}
|
|
16529
16659
|
return chunks;
|
|
16530
16660
|
};
|
|
16531
16661
|
const addInternalGenerators = ({ transform, final, binary, writableObjectMode, readableObjectMode, preserveNewlines }, encoding, optionName) => {
|
|
@@ -16549,7 +16679,7 @@ const addInternalGenerators = ({ transform, final, binary, writableObjectMode, r
|
|
|
16549
16679
|
};
|
|
16550
16680
|
|
|
16551
16681
|
//#endregion
|
|
16552
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16682
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/io/input-sync.js
|
|
16553
16683
|
const addInputOptionsSync = (fileDescriptors, options) => {
|
|
16554
16684
|
for (const fdNumber of getInputFdNumbers(fileDescriptors)) addInputOptionSync(fileDescriptors, fdNumber, options);
|
|
16555
16685
|
};
|
|
@@ -16562,7 +16692,8 @@ const addInputOptionSync = (fileDescriptors, fdNumber, options) => {
|
|
|
16562
16692
|
const [{ type, optionName }] = allStdioItems;
|
|
16563
16693
|
throw new TypeError(`Only the \`stdin\` option, not \`${optionName}\`, can be ${TYPE_TO_MESSAGE[type]} with synchronous methods.`);
|
|
16564
16694
|
}
|
|
16565
|
-
|
|
16695
|
+
const transformedContents = allStdioItems.map(({ contents }) => contents).map((contents) => applySingleInputGeneratorsSync(contents, stdioItems));
|
|
16696
|
+
options.input = joinToUint8Array(transformedContents);
|
|
16566
16697
|
};
|
|
16567
16698
|
const applySingleInputGeneratorsSync = (contents, stdioItems) => {
|
|
16568
16699
|
const newContents = runGeneratorsSync(contents, stdioItems, "utf8", true);
|
|
@@ -16575,10 +16706,10 @@ const validateSerializable = (newContents) => {
|
|
|
16575
16706
|
};
|
|
16576
16707
|
|
|
16577
16708
|
//#endregion
|
|
16578
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16709
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/output.js
|
|
16579
16710
|
const shouldLogOutput = ({ stdioItems, encoding, verboseInfo, fdNumber }) => fdNumber !== "all" && isFullVerbose(verboseInfo, fdNumber) && !BINARY_ENCODINGS.has(encoding) && isFdVerbose(fdNumber) && (stdioItems.some(({ type, value }) => type === "native" && PIPED_STDIO_VALUES.has(value)) || stdioItems.every(({ type }) => TRANSFORM_TYPES.has(type)));
|
|
16580
16711
|
const isFdVerbose = (fdNumber) => fdNumber === 1 || fdNumber === 2;
|
|
16581
|
-
const PIPED_STDIO_VALUES = new Set(["pipe", "overlapped"]);
|
|
16712
|
+
const PIPED_STDIO_VALUES = /* @__PURE__ */ new Set(["pipe", "overlapped"]);
|
|
16582
16713
|
const logLines = async (linesIterable, stream, fdNumber, verboseInfo) => {
|
|
16583
16714
|
for await (const line of linesIterable) if (!isPipingStream(stream)) logLine(line, fdNumber, verboseInfo);
|
|
16584
16715
|
};
|
|
@@ -16587,16 +16718,17 @@ const logLinesSync = (linesArray, fdNumber, verboseInfo) => {
|
|
|
16587
16718
|
};
|
|
16588
16719
|
const isPipingStream = (stream) => stream._readableState.pipes.length > 0;
|
|
16589
16720
|
const logLine = (line, fdNumber, verboseInfo) => {
|
|
16721
|
+
const verboseMessage = serializeVerboseMessage(line);
|
|
16590
16722
|
verboseLog({
|
|
16591
16723
|
type: "output",
|
|
16592
|
-
verboseMessage
|
|
16724
|
+
verboseMessage,
|
|
16593
16725
|
fdNumber,
|
|
16594
16726
|
verboseInfo
|
|
16595
16727
|
});
|
|
16596
16728
|
};
|
|
16597
16729
|
|
|
16598
16730
|
//#endregion
|
|
16599
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16731
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/io/output-sync.js
|
|
16600
16732
|
const transformOutputSync = ({ fileDescriptors, syncResult: { output }, options, isMaxBuffer, verboseInfo }) => {
|
|
16601
16733
|
if (output === null) return { output: Array.from({ length: 3 }) };
|
|
16602
16734
|
const state = {};
|
|
@@ -16616,10 +16748,12 @@ const transformOutputSync = ({ fileDescriptors, syncResult: { output }, options,
|
|
|
16616
16748
|
};
|
|
16617
16749
|
const transformOutputResultSync = ({ result, fileDescriptors, fdNumber, state, outputFiles, isMaxBuffer, verboseInfo }, { buffer, encoding, lines, stripFinalNewline, maxBuffer }) => {
|
|
16618
16750
|
if (result === null) return;
|
|
16619
|
-
const
|
|
16751
|
+
const truncatedResult = truncateMaxBufferSync(result, isMaxBuffer, maxBuffer);
|
|
16752
|
+
const uint8ArrayResult = bufferToUint8Array(truncatedResult);
|
|
16620
16753
|
const { stdioItems, objectMode } = fileDescriptors[fdNumber];
|
|
16754
|
+
const chunks = runOutputGeneratorsSync([uint8ArrayResult], stdioItems, encoding, state);
|
|
16621
16755
|
const { serializedResult, finalResult = serializedResult } = serializeChunks({
|
|
16622
|
-
chunks
|
|
16756
|
+
chunks,
|
|
16623
16757
|
objectMode,
|
|
16624
16758
|
encoding,
|
|
16625
16759
|
lines,
|
|
@@ -16689,7 +16823,7 @@ const writeToFiles = (serializedResult, stdioItems, outputFiles) => {
|
|
|
16689
16823
|
};
|
|
16690
16824
|
|
|
16691
16825
|
//#endregion
|
|
16692
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16826
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/resolve/all-sync.js
|
|
16693
16827
|
const getAllSync = ([, stdout, stderr], options) => {
|
|
16694
16828
|
if (!options.all) return;
|
|
16695
16829
|
if (stdout === void 0) return stderr;
|
|
@@ -16701,7 +16835,7 @@ const getAllSync = ([, stdout, stderr], options) => {
|
|
|
16701
16835
|
};
|
|
16702
16836
|
|
|
16703
16837
|
//#endregion
|
|
16704
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16838
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/resolve/exit-async.js
|
|
16705
16839
|
const waitForExit = async (subprocess, context) => {
|
|
16706
16840
|
const [exitCode, signal] = await waitForExitOrError(subprocess);
|
|
16707
16841
|
context.isForcefullyTerminated ??= false;
|
|
@@ -16728,7 +16862,7 @@ const isSubprocessErrorExit = (exitCode, signal) => exitCode === void 0 && signa
|
|
|
16728
16862
|
const isFailedExit = (exitCode, signal) => exitCode !== 0 || signal !== null;
|
|
16729
16863
|
|
|
16730
16864
|
//#endregion
|
|
16731
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16865
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/resolve/exit-sync.js
|
|
16732
16866
|
const getExitResultSync = ({ error, status: exitCode, signal, output }, { maxBuffer }) => {
|
|
16733
16867
|
const resultError = getResultError(error, exitCode, signal);
|
|
16734
16868
|
return {
|
|
@@ -16745,10 +16879,10 @@ const getResultError = (error, exitCode, signal) => {
|
|
|
16745
16879
|
};
|
|
16746
16880
|
|
|
16747
16881
|
//#endregion
|
|
16748
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
16882
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/methods/main-sync.js
|
|
16749
16883
|
const execaCoreSync = (rawFile, rawArguments, rawOptions) => {
|
|
16750
16884
|
const { file, commandArguments, command, escapedCommand, startTime, verboseInfo, options, fileDescriptors } = handleSyncArguments(rawFile, rawArguments, rawOptions);
|
|
16751
|
-
|
|
16885
|
+
const result = spawnSubprocessSync({
|
|
16752
16886
|
file,
|
|
16753
16887
|
commandArguments,
|
|
16754
16888
|
options,
|
|
@@ -16757,11 +16891,13 @@ const execaCoreSync = (rawFile, rawArguments, rawOptions) => {
|
|
|
16757
16891
|
verboseInfo,
|
|
16758
16892
|
fileDescriptors,
|
|
16759
16893
|
startTime
|
|
16760
|
-
})
|
|
16894
|
+
});
|
|
16895
|
+
return handleResult(result, verboseInfo, options);
|
|
16761
16896
|
};
|
|
16762
16897
|
const handleSyncArguments = (rawFile, rawArguments, rawOptions) => {
|
|
16763
16898
|
const { command, escapedCommand, startTime, verboseInfo } = handleCommand(rawFile, rawArguments, rawOptions);
|
|
16764
|
-
const
|
|
16899
|
+
const syncOptions = normalizeSyncOptions(rawOptions);
|
|
16900
|
+
const { file, commandArguments, options } = normalizeOptions(rawFile, rawArguments, syncOptions);
|
|
16765
16901
|
validateSyncOptions(options);
|
|
16766
16902
|
return {
|
|
16767
16903
|
file,
|
|
@@ -16807,14 +16943,16 @@ const spawnSubprocessSync = ({ file, commandArguments, options, command, escaped
|
|
|
16807
16943
|
isMaxBuffer,
|
|
16808
16944
|
verboseInfo
|
|
16809
16945
|
});
|
|
16946
|
+
const stdio = output.map((stdioOutput, fdNumber) => stripNewline(stdioOutput, options, fdNumber));
|
|
16947
|
+
const all = stripNewline(getAllSync(output, options), options, "all");
|
|
16810
16948
|
return getSyncResult({
|
|
16811
16949
|
error,
|
|
16812
16950
|
exitCode,
|
|
16813
16951
|
signal,
|
|
16814
16952
|
timedOut,
|
|
16815
16953
|
isMaxBuffer,
|
|
16816
|
-
stdio
|
|
16817
|
-
all
|
|
16954
|
+
stdio,
|
|
16955
|
+
all,
|
|
16818
16956
|
options,
|
|
16819
16957
|
command,
|
|
16820
16958
|
escapedCommand,
|
|
@@ -16824,7 +16962,8 @@ const spawnSubprocessSync = ({ file, commandArguments, options, command, escaped
|
|
|
16824
16962
|
const runSubprocessSync = ({ file, commandArguments, options, command, escapedCommand, fileDescriptors, startTime }) => {
|
|
16825
16963
|
try {
|
|
16826
16964
|
addInputOptionsSync(fileDescriptors, options);
|
|
16827
|
-
|
|
16965
|
+
const normalizedOptions = normalizeSpawnSyncOptions(options);
|
|
16966
|
+
return spawnSync(...concatenateShell(file, commandArguments, normalizedOptions));
|
|
16828
16967
|
} catch (error) {
|
|
16829
16968
|
return makeEarlyError({
|
|
16830
16969
|
error,
|
|
@@ -16870,7 +17009,7 @@ const getSyncResult = ({ error, exitCode, signal, timedOut, isMaxBuffer, stdio,
|
|
|
16870
17009
|
});
|
|
16871
17010
|
|
|
16872
17011
|
//#endregion
|
|
16873
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17012
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/get-one.js
|
|
16874
17013
|
const internalGetOneMessageOptions = Symbol("internalGetOneMessageOptions");
|
|
16875
17014
|
const getOneMessage$1 = ({ anyProcess, channel, isSubprocess, ipc }, options = {}) => {
|
|
16876
17015
|
const { reference = true, filter } = options;
|
|
@@ -16939,7 +17078,7 @@ const throwOnStrictError = async (ipcEmitter, isSubprocess, { signal }) => {
|
|
|
16939
17078
|
};
|
|
16940
17079
|
|
|
16941
17080
|
//#endregion
|
|
16942
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17081
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/get-each.js
|
|
16943
17082
|
const internalGetEachMessageOptions = Symbol("internalGetEachMessageOptions");
|
|
16944
17083
|
const getEachMessage$1 = (subprocessInfo, options = {}) => {
|
|
16945
17084
|
const { reference = true } = options;
|
|
@@ -17028,14 +17167,14 @@ const throwIfStrictError = ({ error }) => {
|
|
|
17028
17167
|
};
|
|
17029
17168
|
|
|
17030
17169
|
//#endregion
|
|
17031
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17170
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/methods.js
|
|
17032
17171
|
const addIpcMethods = (target, subprocess, { ipc }) => {
|
|
17033
17172
|
Object.assign(target, getIpcMethods(subprocess, false, ipc, target));
|
|
17034
17173
|
};
|
|
17035
17174
|
const getIpcExport = () => {
|
|
17036
|
-
const anyProcess =
|
|
17175
|
+
const anyProcess = process$1;
|
|
17037
17176
|
const isSubprocess = true;
|
|
17038
|
-
const isIpc =
|
|
17177
|
+
const isIpc = process$1.channel !== void 0;
|
|
17039
17178
|
return {
|
|
17040
17179
|
...getIpcMethods(anyProcess, isSubprocess, isIpc),
|
|
17041
17180
|
getCancelSignal: getCancelSignal$1.bind(void 0, {
|
|
@@ -17069,22 +17208,23 @@ const getIpcMethods = (anyProcess, isSubprocess, ipc, waitProcess = anyProcess)
|
|
|
17069
17208
|
});
|
|
17070
17209
|
|
|
17071
17210
|
//#endregion
|
|
17072
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17211
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/return/early-error.js
|
|
17073
17212
|
const handleEarlyError = ({ error, command, escapedCommand, fileDescriptors, options, startTime, verboseInfo }) => {
|
|
17074
17213
|
cleanupCustomStreams(fileDescriptors);
|
|
17075
17214
|
const subprocess = new ChildProcess();
|
|
17076
17215
|
const all = createDummyStreams(subprocess, fileDescriptors);
|
|
17216
|
+
const earlyError = makeEarlyError({
|
|
17217
|
+
error,
|
|
17218
|
+
command,
|
|
17219
|
+
escapedCommand,
|
|
17220
|
+
fileDescriptors,
|
|
17221
|
+
options,
|
|
17222
|
+
startTime,
|
|
17223
|
+
isSync: false
|
|
17224
|
+
});
|
|
17077
17225
|
return {
|
|
17078
17226
|
subprocess,
|
|
17079
|
-
promise: handleDummyPromise(
|
|
17080
|
-
error,
|
|
17081
|
-
command,
|
|
17082
|
-
escapedCommand,
|
|
17083
|
-
fileDescriptors,
|
|
17084
|
-
options,
|
|
17085
|
-
startTime,
|
|
17086
|
-
isSync: false
|
|
17087
|
-
}), verboseInfo, options),
|
|
17227
|
+
promise: handleDummyPromise(earlyError, verboseInfo, options),
|
|
17088
17228
|
all: options.all ? all : void 0,
|
|
17089
17229
|
convertedStreams: {
|
|
17090
17230
|
readable,
|
|
@@ -17136,7 +17276,7 @@ const iterable = async function* () {};
|
|
|
17136
17276
|
const handleDummyPromise = async (error, verboseInfo, options) => handleResult(error, verboseInfo, options);
|
|
17137
17277
|
|
|
17138
17278
|
//#endregion
|
|
17139
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17279
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/stdio/handle-async.js
|
|
17140
17280
|
const handleStdioAsync = (options, verboseInfo) => handleStdio(addPropertiesAsync, options, verboseInfo, false);
|
|
17141
17281
|
const forbiddenIfAsync = ({ type, optionName }) => {
|
|
17142
17282
|
throw new TypeError(`The \`${optionName}\` option cannot be ${TYPE_TO_MESSAGE[type]}.`);
|
|
@@ -17285,8 +17425,10 @@ const endWhenStreamsDone = async ({ passThroughStream, stream, streams, ended, a
|
|
|
17285
17425
|
controller.abort();
|
|
17286
17426
|
updateMaxListeners(passThroughStream, -PASSTHROUGH_LISTENERS_PER_STREAM);
|
|
17287
17427
|
}
|
|
17288
|
-
if (streams.size > 0 && streams.size === ended.size + aborted.size)
|
|
17289
|
-
|
|
17428
|
+
if (streams.size > 0 && streams.size === ended.size + aborted.size) {
|
|
17429
|
+
if (ended.size === 0 && aborted.size > 0) abortStream(passThroughStream);
|
|
17430
|
+
else endStream(passThroughStream);
|
|
17431
|
+
}
|
|
17290
17432
|
};
|
|
17291
17433
|
const afterMergedStreamFinished = async (onFinished, stream, { signal }) => {
|
|
17292
17434
|
try {
|
|
@@ -17344,7 +17486,7 @@ const PASSTHROUGH_LISTENERS_COUNT = 2;
|
|
|
17344
17486
|
const PASSTHROUGH_LISTENERS_PER_STREAM = 1;
|
|
17345
17487
|
|
|
17346
17488
|
//#endregion
|
|
17347
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17489
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/io/pipeline.js
|
|
17348
17490
|
const pipeStreams = (source, destination) => {
|
|
17349
17491
|
source.pipe(destination);
|
|
17350
17492
|
onSourceFinish(source, destination);
|
|
@@ -17380,7 +17522,7 @@ const abortSourceStream = (source) => {
|
|
|
17380
17522
|
};
|
|
17381
17523
|
|
|
17382
17524
|
//#endregion
|
|
17383
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17525
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/io/output-async.js
|
|
17384
17526
|
const pipeOutputAsync = (subprocess, fileDescriptors, controller) => {
|
|
17385
17527
|
const pipeGroups = /* @__PURE__ */ new Map();
|
|
17386
17528
|
for (const [fdNumber, { stdioItems, direction }] of Object.entries(fileDescriptors)) {
|
|
@@ -17396,7 +17538,10 @@ const pipeOutputAsync = (subprocess, fileDescriptors, controller) => {
|
|
|
17396
17538
|
controller
|
|
17397
17539
|
});
|
|
17398
17540
|
}
|
|
17399
|
-
for (const [outputStream, inputStreams] of pipeGroups)
|
|
17541
|
+
for (const [outputStream, inputStreams] of pipeGroups) {
|
|
17542
|
+
const inputStream = inputStreams.length === 1 ? inputStreams[0] : mergeStreams(inputStreams);
|
|
17543
|
+
pipeStreams(inputStream, outputStream);
|
|
17544
|
+
}
|
|
17400
17545
|
};
|
|
17401
17546
|
const pipeTransform = (subprocess, stream, direction, fdNumber) => {
|
|
17402
17547
|
if (direction === "output") pipeStreams(subprocess.stdio[fdNumber], stream);
|
|
@@ -17423,8 +17568,8 @@ const setStandardStreamMaxListeners = (stream, { signal }) => {
|
|
|
17423
17568
|
const MAX_LISTENERS_INCREMENT = 2;
|
|
17424
17569
|
|
|
17425
17570
|
//#endregion
|
|
17426
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17427
|
-
const isWindows =
|
|
17571
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/terminate/kill-descendants.js
|
|
17572
|
+
const isWindows = process$1.platform === "win32";
|
|
17428
17573
|
const getSpawnOptions = (options) => options.killDescendants && !isWindows ? {
|
|
17429
17574
|
...options,
|
|
17430
17575
|
detached: true
|
|
@@ -17436,7 +17581,7 @@ const getKillFunction = (subprocess, { killDescendants }) => {
|
|
|
17436
17581
|
const killDescendantsUnix = (subprocess, signal) => {
|
|
17437
17582
|
if (subprocess.pid === void 0) return false;
|
|
17438
17583
|
try {
|
|
17439
|
-
return
|
|
17584
|
+
return process$1.kill(-subprocess.pid, signal);
|
|
17440
17585
|
} catch {
|
|
17441
17586
|
return subprocess.kill(signal);
|
|
17442
17587
|
}
|
|
@@ -17456,7 +17601,7 @@ const killDescendantsWindows = (subprocess, signal) => {
|
|
|
17456
17601
|
return true;
|
|
17457
17602
|
};
|
|
17458
17603
|
const getTaskkillFile = () => {
|
|
17459
|
-
const windowsDirectory = [
|
|
17604
|
+
const windowsDirectory = [process$1.env.SystemRoot, process$1.env.windir].find((directory) => directory && isWindowsDriveAbsolutePath(directory));
|
|
17460
17605
|
return windowsDirectory === void 0 ? void 0 : path$1.join(windowsDirectory, "System32", "taskkill.exe");
|
|
17461
17606
|
};
|
|
17462
17607
|
const isWindowsDriveAbsolutePath = (directory) => {
|
|
@@ -17567,7 +17712,7 @@ var SignalExitFallback = class extends SignalExitBase {
|
|
|
17567
17712
|
};
|
|
17568
17713
|
var SignalExit = class extends SignalExitBase {
|
|
17569
17714
|
/* c8 ignore start */
|
|
17570
|
-
#hupSig = process$
|
|
17715
|
+
#hupSig = process$2.platform === "win32" ? "SIGINT" : "SIGHUP";
|
|
17571
17716
|
/* c8 ignore stop */
|
|
17572
17717
|
#emitter = new Emitter();
|
|
17573
17718
|
#process;
|
|
@@ -17662,11 +17807,11 @@ var SignalExit = class extends SignalExitBase {
|
|
|
17662
17807
|
} else return og.call(this.#process, ev, ...args);
|
|
17663
17808
|
}
|
|
17664
17809
|
};
|
|
17665
|
-
const process$
|
|
17666
|
-
const { onExit, load, unload } = signalExitWrap(processOk(process$
|
|
17810
|
+
const process$2 = globalThis.process;
|
|
17811
|
+
const { onExit, load, unload } = signalExitWrap(processOk(process$2) ? new SignalExit(process$2) : new SignalExitFallback());
|
|
17667
17812
|
|
|
17668
17813
|
//#endregion
|
|
17669
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17814
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/terminate/cleanup.js
|
|
17670
17815
|
const cleanupOnExit = (kill, { cleanup, detached }, { signal }) => {
|
|
17671
17816
|
if (!cleanup || detached) return;
|
|
17672
17817
|
const removeExitHandler = onExit(() => {
|
|
@@ -17678,7 +17823,7 @@ const cleanupOnExit = (kill, { cleanup, detached }, { signal }) => {
|
|
|
17678
17823
|
};
|
|
17679
17824
|
|
|
17680
17825
|
//#endregion
|
|
17681
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17826
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/convert/concurrent.js
|
|
17682
17827
|
const initializeConcurrentStreams = () => ({
|
|
17683
17828
|
readableDestroy: /* @__PURE__ */ new WeakMap(),
|
|
17684
17829
|
writableFinal: /* @__PURE__ */ new WeakMap(),
|
|
@@ -17702,7 +17847,7 @@ const waitForConcurrentStreams = async ({ resolve, promises }, subprocess) => {
|
|
|
17702
17847
|
};
|
|
17703
17848
|
|
|
17704
17849
|
//#endregion
|
|
17705
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17850
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/io/iterate.js
|
|
17706
17851
|
const iterateOnSubprocessStream = ({ subprocessStdout, subprocess, binary, shouldEncode, encoding, preserveNewlines }) => {
|
|
17707
17852
|
const controller = new AbortController();
|
|
17708
17853
|
stopReadingOnExit(subprocess, controller);
|
|
@@ -17747,12 +17892,13 @@ const stopReadingOnStreamEnd = async (onStreamEnd, controller, stream) => {
|
|
|
17747
17892
|
}
|
|
17748
17893
|
};
|
|
17749
17894
|
const iterateOnStream = ({ stream, controller, binary, shouldEncode, encoding, shouldSplit, preserveNewlines }) => {
|
|
17895
|
+
const onStdoutChunk = on(stream, "data", {
|
|
17896
|
+
signal: controller.signal,
|
|
17897
|
+
highWaterMark: HIGH_WATER_MARK,
|
|
17898
|
+
highWatermark: HIGH_WATER_MARK
|
|
17899
|
+
});
|
|
17750
17900
|
return iterateOnData({
|
|
17751
|
-
onStdoutChunk
|
|
17752
|
-
signal: controller.signal,
|
|
17753
|
-
highWaterMark: HIGH_WATER_MARK,
|
|
17754
|
-
highWatermark: HIGH_WATER_MARK
|
|
17755
|
-
}),
|
|
17901
|
+
onStdoutChunk,
|
|
17756
17902
|
controller,
|
|
17757
17903
|
binary,
|
|
17758
17904
|
shouldEncode,
|
|
@@ -17782,18 +17928,19 @@ const iterateOnData = async function* ({ onStdoutChunk, controller, binary, shou
|
|
|
17782
17928
|
const getGenerators = ({ binary, shouldEncode, encoding, shouldSplit, preserveNewlines }) => [getEncodingTransformGenerator(binary, encoding, !shouldEncode), getSplitLinesGenerator(binary, preserveNewlines, !shouldSplit, {})].filter(Boolean);
|
|
17783
17929
|
|
|
17784
17930
|
//#endregion
|
|
17785
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17931
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/convert/iterable.js
|
|
17786
17932
|
const createIterable = (subprocess, encoding, { from, binary: binaryOption = false, preserveNewlines = false } = {}) => {
|
|
17787
17933
|
const binary = binaryOption || BINARY_ENCODINGS.has(encoding);
|
|
17788
17934
|
const subprocessStdout = getFromStream(subprocess, from);
|
|
17789
|
-
|
|
17935
|
+
const onStdoutData = iterateOnSubprocessStream({
|
|
17790
17936
|
subprocessStdout,
|
|
17791
17937
|
subprocess,
|
|
17792
17938
|
binary,
|
|
17793
17939
|
shouldEncode: true,
|
|
17794
17940
|
encoding,
|
|
17795
17941
|
preserveNewlines
|
|
17796
|
-
})
|
|
17942
|
+
});
|
|
17943
|
+
return iterateOnStdoutData(onStdoutData, subprocessStdout, subprocess);
|
|
17797
17944
|
};
|
|
17798
17945
|
const iterateOnStdoutData = async function* (onStdoutData, subprocessStdout, subprocess) {
|
|
17799
17946
|
try {
|
|
@@ -17805,7 +17952,7 @@ const iterateOnStdoutData = async function* (onStdoutData, subprocessStdout, sub
|
|
|
17805
17952
|
};
|
|
17806
17953
|
|
|
17807
17954
|
//#endregion
|
|
17808
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17955
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/resolve/wait-stream.js
|
|
17809
17956
|
const waitForStream = async (stream, fdNumber, streamInfo, { isSameDirection, stopOnExit = false } = {}) => {
|
|
17810
17957
|
const state = handleStdinDestroy(stream, streamInfo);
|
|
17811
17958
|
const abortController = new AbortController();
|
|
@@ -17849,7 +17996,7 @@ const isStreamAbort = (error) => error?.code === "ERR_STREAM_PREMATURE_CLOSE";
|
|
|
17849
17996
|
const isStreamEpipe = (error) => error?.code === "EPIPE";
|
|
17850
17997
|
|
|
17851
17998
|
//#endregion
|
|
17852
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
17999
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/convert/shared.js
|
|
17853
18000
|
const safeWaitForSubprocessStdin = async (subprocessStdin) => {
|
|
17854
18001
|
if (subprocessStdin === void 0) return;
|
|
17855
18002
|
try {
|
|
@@ -17886,7 +18033,7 @@ const destroyOtherStream = (stream, isOpen, error) => {
|
|
|
17886
18033
|
};
|
|
17887
18034
|
|
|
17888
18035
|
//#endregion
|
|
17889
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18036
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/convert/readable.js
|
|
17890
18037
|
const createReadable = ({ subprocess, concurrentStreams, encoding }, { from, binary: binaryOption = true, preserveNewlines = true } = {}) => {
|
|
17891
18038
|
const binary = binaryOption || BINARY_ENCODINGS.has(encoding);
|
|
17892
18039
|
const { subprocessStdout, waitReadableDestroy } = getSubprocessStdout(subprocess, from, concurrentStreams);
|
|
@@ -17988,13 +18135,13 @@ const destroyOtherReadable = (stream, error) => {
|
|
|
17988
18135
|
};
|
|
17989
18136
|
|
|
17990
18137
|
//#endregion
|
|
17991
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18138
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/convert/web.js
|
|
17992
18139
|
const createReadableStream = (subprocess, readableOptions) => Readable.toWeb(subprocess.readable(readableOptions));
|
|
17993
18140
|
const createWritableStream = (subprocess, writableOptions) => Writable.toWeb(subprocess.writable(writableOptions));
|
|
17994
18141
|
const createTransformStream = (subprocess, duplexOptions) => Duplex.toWeb(subprocess.duplex(duplexOptions));
|
|
17995
18142
|
|
|
17996
18143
|
//#endregion
|
|
17997
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18144
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/pipe/pipe-arguments.js
|
|
17998
18145
|
const normalizePipeArguments = ({ source, sourcePromise, boundOptions, createNested }, ...pipeArguments) => {
|
|
17999
18146
|
const startTime = getStartTime();
|
|
18000
18147
|
const { destination, destinationStream, destinationError, from, unpipeSignal } = getDestinationStream(boundOptions, createNested, pipeArguments);
|
|
@@ -18062,7 +18209,7 @@ const getSourceStream = (source, from) => {
|
|
|
18062
18209
|
};
|
|
18063
18210
|
|
|
18064
18211
|
//#endregion
|
|
18065
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18212
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/pipe/throw.js
|
|
18066
18213
|
const handlePipeArgumentsError = ({ sourceStream, sourceError, destinationStream, destinationError, fileDescriptors, sourceOptions, startTime }) => {
|
|
18067
18214
|
const error = getPipeArgumentsError({
|
|
18068
18215
|
sourceStream,
|
|
@@ -18100,7 +18247,7 @@ const createNonCommandError = ({ error, fileDescriptors, sourceOptions, startTim
|
|
|
18100
18247
|
const PIPE_COMMAND_MESSAGE = "source.pipe(destination)";
|
|
18101
18248
|
|
|
18102
18249
|
//#endregion
|
|
18103
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18250
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/pipe/sequence.js
|
|
18104
18251
|
const waitForBothSubprocesses = async (subprocessPromises) => {
|
|
18105
18252
|
const [{ status: sourceStatus, reason: sourceReason, value: sourceResult = sourceReason }, { status: destinationStatus, reason: destinationReason, value: destinationResult = destinationReason }] = await subprocessPromises;
|
|
18106
18253
|
if (!destinationResult.pipedFrom.includes(sourceResult)) destinationResult.pipedFrom.push(sourceResult);
|
|
@@ -18110,7 +18257,7 @@ const waitForBothSubprocesses = async (subprocessPromises) => {
|
|
|
18110
18257
|
};
|
|
18111
18258
|
|
|
18112
18259
|
//#endregion
|
|
18113
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18260
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/pipe/streaming.js
|
|
18114
18261
|
const pipeSubprocessStream = (sourceStream, destinationStream, maxListenersController) => {
|
|
18115
18262
|
const mergedStream = MERGED_STREAMS.has(destinationStream) ? pipeMoreSubprocessStream(sourceStream, destinationStream) : pipeFirstSubprocessStream(sourceStream, destinationStream);
|
|
18116
18263
|
incrementMaxListeners(sourceStream, SOURCE_LISTENERS_PER_PIPE, maxListenersController.signal);
|
|
@@ -18144,7 +18291,7 @@ const SOURCE_LISTENERS_PER_PIPE = 2;
|
|
|
18144
18291
|
const DESTINATION_LISTENERS_PER_PIPE = 1;
|
|
18145
18292
|
|
|
18146
18293
|
//#endregion
|
|
18147
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18294
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/pipe/abort.js
|
|
18148
18295
|
const unpipeOnAbort = (unpipeSignal, unpipeContext) => unpipeSignal === void 0 ? [] : [unpipeOnSignalAbort(unpipeSignal, unpipeContext)];
|
|
18149
18296
|
const unpipeOnSignalAbort = async (unpipeSignal, { sourceStream, mergedStream, fileDescriptors, sourceOptions, startTime }) => {
|
|
18150
18297
|
await aborted(unpipeSignal, sourceStream);
|
|
@@ -18158,7 +18305,7 @@ const unpipeOnSignalAbort = async (unpipeSignal, { sourceStream, mergedStream, f
|
|
|
18158
18305
|
};
|
|
18159
18306
|
|
|
18160
18307
|
//#endregion
|
|
18161
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18308
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/pipe/setup.js
|
|
18162
18309
|
const pipeToSubprocess = (sourceInfo, ...pipeArguments) => {
|
|
18163
18310
|
if (isPlainObject(pipeArguments[0])) return pipeToSubprocess.bind(void 0, {
|
|
18164
18311
|
...sourceInfo,
|
|
@@ -18248,7 +18395,8 @@ const forwardIpcMethods = (promise, destination, pipeFailureSignal) => {
|
|
|
18248
18395
|
};
|
|
18249
18396
|
const getOnePipeMessage = (destination, pipeFailureSignal, ...arguments_) => {
|
|
18250
18397
|
const controller = new AbortController();
|
|
18251
|
-
|
|
18398
|
+
const messagePromise = destination.getOneMessage(...addPipeOptions(arguments_, controller.signal, internalGetOneMessageOptions));
|
|
18399
|
+
return waitForOnePipeMessage(pipeFailureSignal, messagePromise, controller);
|
|
18252
18400
|
};
|
|
18253
18401
|
const waitForOnePipeMessage = async (pipeFailureSignal, messagePromise, controller) => {
|
|
18254
18402
|
try {
|
|
@@ -18337,7 +18485,7 @@ const handlePipePromise = async ({ sourcePromise, sourceStream, sourceOptions, s
|
|
|
18337
18485
|
const getSubprocessPromises = (sourcePromise, destination) => Promise.allSettled([sourcePromise, destination]);
|
|
18338
18486
|
|
|
18339
18487
|
//#endregion
|
|
18340
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18488
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/io/contents.js
|
|
18341
18489
|
const getStreamOutput = async ({ stream, onStreamEnd, fdNumber, encoding, buffer, maxBuffer, lines, allMixed, stripFinalNewline, verboseInfo, streamInfo }) => {
|
|
18342
18490
|
const logPromise = logOutputAsync({
|
|
18343
18491
|
stream,
|
|
@@ -18352,12 +18500,13 @@ const getStreamOutput = async ({ stream, onStreamEnd, fdNumber, encoding, buffer
|
|
|
18352
18500
|
await Promise.all([resumeStream(stream), logPromise]);
|
|
18353
18501
|
return;
|
|
18354
18502
|
}
|
|
18503
|
+
const stripFinalNewlineValue = getStripFinalNewline(stripFinalNewline, fdNumber);
|
|
18355
18504
|
const iterable = iterateForResult({
|
|
18356
18505
|
stream,
|
|
18357
18506
|
onStreamEnd,
|
|
18358
18507
|
lines,
|
|
18359
18508
|
encoding,
|
|
18360
|
-
stripFinalNewline:
|
|
18509
|
+
stripFinalNewline: stripFinalNewlineValue,
|
|
18361
18510
|
allMixed
|
|
18362
18511
|
});
|
|
18363
18512
|
const [output] = await Promise.all([getStreamContents({
|
|
@@ -18377,14 +18526,15 @@ const logOutputAsync = async ({ stream, onStreamEnd, fdNumber, encoding, allMixe
|
|
|
18377
18526
|
verboseInfo,
|
|
18378
18527
|
fdNumber
|
|
18379
18528
|
})) return;
|
|
18380
|
-
|
|
18529
|
+
const linesIterable = iterateForResult({
|
|
18381
18530
|
stream,
|
|
18382
18531
|
onStreamEnd,
|
|
18383
18532
|
lines: true,
|
|
18384
18533
|
encoding,
|
|
18385
18534
|
stripFinalNewline: true,
|
|
18386
18535
|
allMixed
|
|
18387
|
-
})
|
|
18536
|
+
});
|
|
18537
|
+
await logLines(linesIterable, stream, fdNumber, verboseInfo);
|
|
18388
18538
|
};
|
|
18389
18539
|
const resumeStream = async (stream) => {
|
|
18390
18540
|
await setImmediate$1();
|
|
@@ -18416,7 +18566,7 @@ const getBufferedData = async (streamPromise) => {
|
|
|
18416
18566
|
const handleBufferedData = ({ bufferedData }) => isArrayBuffer(bufferedData) ? new Uint8Array(bufferedData) : bufferedData;
|
|
18417
18567
|
|
|
18418
18568
|
//#endregion
|
|
18419
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18569
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/resolve/stdio.js
|
|
18420
18570
|
const waitForStdioStreams = ({ subprocess, encoding, buffer, maxBuffer, lines, stripFinalNewline, verboseInfo, streamInfo }) => subprocess.stdio.map((stream, fdNumber) => waitForSubprocessStream({
|
|
18421
18571
|
stream,
|
|
18422
18572
|
fdNumber,
|
|
@@ -18453,7 +18603,7 @@ const waitForSubprocessStream = async ({ stream, fdNumber, encoding, buffer, max
|
|
|
18453
18603
|
};
|
|
18454
18604
|
|
|
18455
18605
|
//#endregion
|
|
18456
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18606
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/resolve/all-async.js
|
|
18457
18607
|
const makeAllStream = ({ stdout, stderr }, { all }) => all && (stdout || stderr) ? mergeStreams([stdout, stderr].filter(Boolean)) : void 0;
|
|
18458
18608
|
const waitForAllStream = ({ subprocess, all, encoding, buffer, maxBuffer, lines, stripFinalNewline, verboseInfo, streamInfo }) => waitForSubprocessStream({
|
|
18459
18609
|
...getAllStream(subprocess, all, buffer),
|
|
@@ -18488,19 +18638,20 @@ const getAllStream = ({ stdout, stderr }, all, [, bufferStdout, bufferStderr]) =
|
|
|
18488
18638
|
const getAllMixed = ({ stdout, stderr }, all) => all && stdout && stderr && stdout.readableObjectMode !== stderr.readableObjectMode;
|
|
18489
18639
|
|
|
18490
18640
|
//#endregion
|
|
18491
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18641
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/verbose/ipc.js
|
|
18492
18642
|
const shouldLogIpc = (verboseInfo) => isFullVerbose(verboseInfo, "ipc");
|
|
18493
18643
|
const logIpcOutput = (message, verboseInfo) => {
|
|
18644
|
+
const verboseMessage = serializeVerboseMessage(message);
|
|
18494
18645
|
verboseLog({
|
|
18495
18646
|
type: "ipc",
|
|
18496
|
-
verboseMessage
|
|
18647
|
+
verboseMessage,
|
|
18497
18648
|
fdNumber: "ipc",
|
|
18498
18649
|
verboseInfo
|
|
18499
18650
|
});
|
|
18500
18651
|
};
|
|
18501
18652
|
|
|
18502
18653
|
//#endregion
|
|
18503
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18654
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/ipc/buffer-messages.js
|
|
18504
18655
|
const waitForIpcOutput = async ({ subprocess, buffer: bufferArray, maxBuffer: maxBufferArray, ipc, ipcOutput, verboseInfo }) => {
|
|
18505
18656
|
if (!ipc) return ipcOutput;
|
|
18506
18657
|
const isVerbose = shouldLogIpc(verboseInfo);
|
|
@@ -18528,7 +18679,7 @@ const getBufferedIpcOutput = async (ipcOutputPromise, ipcOutput) => {
|
|
|
18528
18679
|
};
|
|
18529
18680
|
|
|
18530
18681
|
//#endregion
|
|
18531
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18682
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/resolve/wait-subprocess.js
|
|
18532
18683
|
const waitForSubprocessResult = async ({ subprocess, kill, all, options: { encoding, buffer, maxBuffer, lines, timeoutDuration: timeout, cancelSignal, gracefulCancel, forceKillAfterDelay, stripFinalNewline, ipc, ipcInput }, context, verboseInfo, fileDescriptors, originalStreams, onInternalError, controller }) => {
|
|
18533
18684
|
const exitPromise = waitForExit(subprocess, context);
|
|
18534
18685
|
const streamInfo = {
|
|
@@ -18626,7 +18777,7 @@ const throwOnSubprocessError = async (subprocess, { signal }) => {
|
|
|
18626
18777
|
};
|
|
18627
18778
|
|
|
18628
18779
|
//#endregion
|
|
18629
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18780
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/convert/writable.js
|
|
18630
18781
|
const createWritable = ({ subprocess, concurrentStreams }, { to } = {}) => {
|
|
18631
18782
|
const { subprocessStdin, waitWritableFinal, waitWritableDestroy } = getSubprocessStdin(subprocess, to, concurrentStreams);
|
|
18632
18783
|
const writable = new Writable({
|
|
@@ -18696,7 +18847,7 @@ const destroyOtherWritable = (stream, error) => {
|
|
|
18696
18847
|
};
|
|
18697
18848
|
|
|
18698
18849
|
//#endregion
|
|
18699
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18850
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/convert/duplex.js
|
|
18700
18851
|
const createDuplex = ({ subprocess, concurrentStreams, encoding }, { from, to, binary: binaryOption = true, preserveNewlines = true } = {}) => {
|
|
18701
18852
|
const binary = binaryOption || BINARY_ENCODINGS.has(encoding);
|
|
18702
18853
|
const { subprocessStdout, waitReadableDestroy } = getSubprocessStdout(subprocess, from, concurrentStreams);
|
|
@@ -18750,7 +18901,7 @@ const onDuplexDestroy = async ({ subprocessStdout, subprocessStdin, subprocess,
|
|
|
18750
18901
|
};
|
|
18751
18902
|
|
|
18752
18903
|
//#endregion
|
|
18753
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18904
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/convert/add.js
|
|
18754
18905
|
const addConvertedStreams = (subprocess, { encoding }) => {
|
|
18755
18906
|
const concurrentStreams = initializeConcurrentStreams();
|
|
18756
18907
|
subprocess.readable = createReadable.bind(void 0, {
|
|
@@ -18775,11 +18926,11 @@ const addConvertedStreams = (subprocess, { encoding }) => {
|
|
|
18775
18926
|
};
|
|
18776
18927
|
|
|
18777
18928
|
//#endregion
|
|
18778
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18929
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/methods/promise.js
|
|
18779
18930
|
const mergePromise = (promise, properties) => Object.assign(promise, properties);
|
|
18780
18931
|
|
|
18781
18932
|
//#endregion
|
|
18782
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
18933
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/methods/main-async.js
|
|
18783
18934
|
const execaCoreAsync = (rawFile, rawArguments, rawOptions, createNested) => {
|
|
18784
18935
|
const { file, commandArguments, command, escapedCommand, startTime, verboseInfo, options, fileDescriptors } = handleAsyncArguments(rawFile, rawArguments, rawOptions);
|
|
18785
18936
|
const { subprocess: nodeChildProcess, promise, kill, all, convertedStreams } = spawnSubprocessAsync({
|
|
@@ -18920,19 +19071,22 @@ const handlePromise = async ({ subprocess, kill, all: allStream, options, startT
|
|
|
18920
19071
|
});
|
|
18921
19072
|
controller.abort();
|
|
18922
19073
|
onInternalError.resolve();
|
|
18923
|
-
|
|
19074
|
+
const stdio = stdioResults.map((stdioResult, fdNumber) => stripNewline(stdioResult, options, fdNumber));
|
|
19075
|
+
const all = stripNewline(allResult, options, "all");
|
|
19076
|
+
const result = getAsyncResult({
|
|
18924
19077
|
errorInfo,
|
|
18925
19078
|
exitCode,
|
|
18926
19079
|
signal,
|
|
18927
|
-
stdio
|
|
18928
|
-
all
|
|
19080
|
+
stdio,
|
|
19081
|
+
all,
|
|
18929
19082
|
ipcOutput,
|
|
18930
19083
|
context,
|
|
18931
19084
|
options,
|
|
18932
19085
|
command,
|
|
18933
19086
|
escapedCommand,
|
|
18934
19087
|
startTime
|
|
18935
|
-
})
|
|
19088
|
+
});
|
|
19089
|
+
return handleResult(result, verboseInfo, options);
|
|
18936
19090
|
};
|
|
18937
19091
|
const getAsyncResult = ({ errorInfo, exitCode, signal, stdio, all, ipcOutput, context, options, command, escapedCommand, startTime }) => "error" in errorInfo ? makeError({
|
|
18938
19092
|
error: errorInfo.error,
|
|
@@ -18962,7 +19116,7 @@ const getAsyncResult = ({ errorInfo, exitCode, signal, stdio, all, ipcOutput, co
|
|
|
18962
19116
|
});
|
|
18963
19117
|
|
|
18964
19118
|
//#endregion
|
|
18965
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
19119
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/methods/bind.js
|
|
18966
19120
|
const mergeOptions = (boundOptions, options) => {
|
|
18967
19121
|
const safeBoundOptions = {
|
|
18968
19122
|
__proto__: null,
|
|
@@ -18981,10 +19135,10 @@ const mergeOption = (optionName, boundOptionValue, optionValue) => {
|
|
|
18981
19135
|
};
|
|
18982
19136
|
return optionValue;
|
|
18983
19137
|
};
|
|
18984
|
-
const DEEP_OPTIONS = new Set(["env", ...FD_SPECIFIC_OPTIONS]);
|
|
19138
|
+
const DEEP_OPTIONS = /* @__PURE__ */ new Set(["env", ...FD_SPECIFIC_OPTIONS]);
|
|
18985
19139
|
|
|
18986
19140
|
//#endregion
|
|
18987
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
19141
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/methods/create.js
|
|
18988
19142
|
const createExeca = (mapArguments, boundOptions, deepOptions, setBoundExeca) => {
|
|
18989
19143
|
const createNested = (mapArguments, boundOptions, setBoundExeca) => createExeca(mapArguments, boundOptions, deepOptions, setBoundExeca);
|
|
18990
19144
|
const boundExeca = (...execaArguments) => callBoundExeca({
|
|
@@ -19009,7 +19163,8 @@ const callBoundExeca = ({ mapArguments, deepOptions = {}, boundOptions = {}, set
|
|
|
19009
19163
|
return isSync ? execaCoreSync(file, commandArguments, options) : execaCoreAsync(file, commandArguments, options, createNested);
|
|
19010
19164
|
};
|
|
19011
19165
|
const parseArguments = ({ mapArguments, firstArgument, nextArguments, deepOptions, boundOptions }) => {
|
|
19012
|
-
const
|
|
19166
|
+
const callArguments = isTemplateString(firstArgument) ? parseTemplates(firstArgument, nextArguments) : [firstArgument, ...nextArguments];
|
|
19167
|
+
const [initialFile, initialArguments, initialOptions] = normalizeParameters(...callArguments);
|
|
19013
19168
|
const mergedOptions = mergeOptions(mergeOptions(deepOptions, boundOptions), initialOptions);
|
|
19014
19169
|
const { options = mergedOptions, isSync = false } = mapArguments({ options: mergedOptions });
|
|
19015
19170
|
return {
|
|
@@ -19021,7 +19176,7 @@ const parseArguments = ({ mapArguments, firstArgument, nextArguments, deepOption
|
|
|
19021
19176
|
};
|
|
19022
19177
|
|
|
19023
19178
|
//#endregion
|
|
19024
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
19179
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/lib/methods/script.js
|
|
19025
19180
|
const setScriptSync = (boundExeca, createNested, boundOptions) => {
|
|
19026
19181
|
boundExeca.sync = createNested(mapScriptSync, boundOptions);
|
|
19027
19182
|
boundExeca.s = boundExeca.sync;
|
|
@@ -19039,7 +19194,7 @@ const getScriptStdinOption = ({ input, inputFile, stdio }) => input === void 0 &
|
|
|
19039
19194
|
const deepScriptOptions = { preferLocal: true };
|
|
19040
19195
|
|
|
19041
19196
|
//#endregion
|
|
19042
|
-
//#region ../../node_modules/.pnpm/execa@10.0.
|
|
19197
|
+
//#region ../../node_modules/.pnpm/execa@10.0.1/node_modules/execa/index.js
|
|
19043
19198
|
const execa = createExeca(() => ({}));
|
|
19044
19199
|
const execaSync = createExeca(() => ({ isSync: true }));
|
|
19045
19200
|
const execaNode = createExeca(mapNode);
|
|
@@ -19110,8 +19265,6 @@ var require_pg_connection_string = /* @__PURE__ */ __commonJSMin(((exports, modu
|
|
|
19110
19265
|
case "verify-ca":
|
|
19111
19266
|
if (!config.ssl.ca) throw new Error("SECURITY WARNING: Using sslmode=verify-ca requires specifying a CA with sslrootcert. If a public CA is used, verify-ca allows connections to a server that somebody else may have registered with the CA, making you vulnerable to Man-in-the-Middle attacks. Either specify a custom CA certificate with sslrootcert parameter or use sslmode=verify-full for proper security.");
|
|
19112
19267
|
config.ssl.checkServerIdentity = function() {};
|
|
19113
|
-
break;
|
|
19114
|
-
case "verify-full": break;
|
|
19115
19268
|
}
|
|
19116
19269
|
else switch (config.sslmode) {
|
|
19117
19270
|
case "disable":
|
|
@@ -19123,9 +19276,7 @@ var require_pg_connection_string = /* @__PURE__ */ __commonJSMin(((exports, modu
|
|
|
19123
19276
|
case "verify-full":
|
|
19124
19277
|
if (config.sslmode !== "verify-full") deprecatedSslModeWarning(config.sslmode);
|
|
19125
19278
|
break;
|
|
19126
|
-
case "no-verify":
|
|
19127
|
-
config.ssl.rejectUnauthorized = false;
|
|
19128
|
-
break;
|
|
19279
|
+
case "no-verify": config.ssl.rejectUnauthorized = false;
|
|
19129
19280
|
}
|
|
19130
19281
|
return config;
|
|
19131
19282
|
}
|
|
@@ -19141,13 +19292,15 @@ var require_pg_connection_string = /* @__PURE__ */ __commonJSMin(((exports, modu
|
|
|
19141
19292
|
const sslConfig = value;
|
|
19142
19293
|
if (typeof sslConfig === "boolean") c[key] = sslConfig;
|
|
19143
19294
|
if (typeof sslConfig === "object") c[key] = toConnectionOptions(sslConfig);
|
|
19144
|
-
} else if (value !== void 0 && value !== null)
|
|
19145
|
-
if (
|
|
19146
|
-
|
|
19147
|
-
|
|
19148
|
-
|
|
19149
|
-
|
|
19150
|
-
|
|
19295
|
+
} else if (value !== void 0 && value !== null) {
|
|
19296
|
+
if (key === "port") {
|
|
19297
|
+
if (value !== "") {
|
|
19298
|
+
const v = parseInt(value, 10);
|
|
19299
|
+
if (isNaN(v)) throw new Error(`Invalid ${key}: ${value}`);
|
|
19300
|
+
c[key] = v;
|
|
19301
|
+
}
|
|
19302
|
+
} else c[key] = value;
|
|
19303
|
+
}
|
|
19151
19304
|
return c;
|
|
19152
19305
|
}, Object.create(null));
|
|
19153
19306
|
}
|
|
@@ -19218,7 +19371,8 @@ async function resolveBaseDsn(env, deps = {}) {
|
|
|
19218
19371
|
throw new Error("Unable to resolve the base DSN. Set CTX_PLATFORM_URL and CTXB_BASE_ID to fetch it from base-platform, or set CTXB_DATABASE_URL to a postgres:// URL.");
|
|
19219
19372
|
}
|
|
19220
19373
|
async function resolveBaseDsnObj(env, deps = {}) {
|
|
19221
|
-
const
|
|
19374
|
+
const resolvedDatabaseUrl = await resolveBaseDsn(env, deps);
|
|
19375
|
+
const parsedConnectionOptions = parse$1(resolvedDatabaseUrl);
|
|
19222
19376
|
return resolvedDatabaseUrlConnectionOptionsSchema.parse({
|
|
19223
19377
|
database: normalizeStringWithDefault(parsedConnectionOptions.database, "postgres"),
|
|
19224
19378
|
host: normalizeStringWithDefault(parsedConnectionOptions.host, "localhost"),
|
|
@@ -19262,7 +19416,7 @@ const DAGSTER_DEFAULT_LOAD_ARGS = [
|
|
|
19262
19416
|
"-a",
|
|
19263
19417
|
"defs"
|
|
19264
19418
|
];
|
|
19265
|
-
const DAGSTER_BASE_LOCATION_FLAGS = new Set([
|
|
19419
|
+
const DAGSTER_BASE_LOCATION_FLAGS = /* @__PURE__ */ new Set([
|
|
19266
19420
|
"-m",
|
|
19267
19421
|
"-f",
|
|
19268
19422
|
"-w",
|
|
@@ -19270,13 +19424,13 @@ const DAGSTER_BASE_LOCATION_FLAGS = new Set([
|
|
|
19270
19424
|
"--grpc-port",
|
|
19271
19425
|
"--grpc-socket"
|
|
19272
19426
|
]);
|
|
19273
|
-
const DAGSTER_GRAPHQL_LOCATION_FLAGS = new Set([...DAGSTER_BASE_LOCATION_FLAGS, "--remote"]);
|
|
19427
|
+
const DAGSTER_GRAPHQL_LOCATION_FLAGS = /* @__PURE__ */ new Set([...DAGSTER_BASE_LOCATION_FLAGS, "--remote"]);
|
|
19274
19428
|
const DG_TARGET_PATH_FLAG = "--target-path";
|
|
19275
19429
|
const CORE_PACKAGE_FALLBACK_REF = `contextbase-core==${version}`;
|
|
19276
19430
|
const REPO_ROOT_TO_CORE_PROJECT_RELATIVE_PATH = path.join("projects", "core");
|
|
19277
19431
|
const DG_PYTHON_PURELIB_SNIPPET = "import sysconfig; print(sysconfig.get_path('purelib'))";
|
|
19278
19432
|
const CONTEXTBASE_CORE_PYTHON_VERSION = "3.12";
|
|
19279
|
-
const DAGSTER_TOOLS_WITHOUT_DATABASE_URL = new Set([
|
|
19433
|
+
const DAGSTER_TOOLS_WITHOUT_DATABASE_URL = /* @__PURE__ */ new Set([
|
|
19280
19434
|
"dagster",
|
|
19281
19435
|
"dagster-graphql",
|
|
19282
19436
|
"dagster-webserver"
|
|
@@ -19444,12 +19598,11 @@ async function buildDagsterToolInvocation(tool, passthroughArgs, paths) {
|
|
|
19444
19598
|
}
|
|
19445
19599
|
}
|
|
19446
19600
|
}
|
|
19447
|
-
async function runDagsterTool(tool, passthroughArgs, paths
|
|
19601
|
+
async function runDagsterTool(tool, passthroughArgs, paths) {
|
|
19448
19602
|
const invocation = await buildDagsterToolInvocation(tool, passthroughArgs, paths);
|
|
19449
|
-
const stdio = options?.stdio ?? "inherit";
|
|
19450
19603
|
const dagsterEnv = await buildDagsterEnv(paths, { requireDatabaseUrl: !DAGSTER_TOOLS_WITHOUT_DATABASE_URL.has(tool) });
|
|
19451
19604
|
const cwd = invocation.cwd ?? void 0;
|
|
19452
|
-
|
|
19605
|
+
return { exitCode: (invocation.localCoreProjectPath ? await execa("uv", [
|
|
19453
19606
|
"run",
|
|
19454
19607
|
"--project",
|
|
19455
19608
|
invocation.localCoreProjectPath,
|
|
@@ -19461,7 +19614,7 @@ async function runDagsterTool(tool, passthroughArgs, paths, options) {
|
|
|
19461
19614
|
cwd,
|
|
19462
19615
|
env: dagsterEnv,
|
|
19463
19616
|
reject: false,
|
|
19464
|
-
stdio
|
|
19617
|
+
stdio: "inherit"
|
|
19465
19618
|
}) : await execa("uvx", [
|
|
19466
19619
|
"--python",
|
|
19467
19620
|
CONTEXTBASE_CORE_PYTHON_VERSION,
|
|
@@ -19475,13 +19628,8 @@ async function runDagsterTool(tool, passthroughArgs, paths, options) {
|
|
|
19475
19628
|
cwd,
|
|
19476
19629
|
env: dagsterEnv,
|
|
19477
19630
|
reject: false,
|
|
19478
|
-
stdio
|
|
19479
|
-
});
|
|
19480
|
-
return {
|
|
19481
|
-
exitCode: dagsterResult.exitCode ?? 1,
|
|
19482
|
-
stderr: dagsterResult.stderr ?? "",
|
|
19483
|
-
stdout: dagsterResult.stdout ?? ""
|
|
19484
|
-
};
|
|
19631
|
+
stdio: "inherit"
|
|
19632
|
+
})).exitCode ?? 1 };
|
|
19485
19633
|
}
|
|
19486
19634
|
async function runDagsterCommand(tool, passthroughArgsInput, paths) {
|
|
19487
19635
|
const dagsterInvocationResult = await runDagsterTool(tool, passthroughArgsInput ?? [], paths);
|
|
@@ -19490,7 +19638,9 @@ async function runDagsterCommand(tool, passthroughArgsInput, paths) {
|
|
|
19490
19638
|
|
|
19491
19639
|
//#endregion
|
|
19492
19640
|
//#region ../../node_modules/.pnpm/postgres@3.4.9/node_modules/postgres/src/query.js
|
|
19493
|
-
const originCache = /* @__PURE__ */ new Map()
|
|
19641
|
+
const originCache = /* @__PURE__ */ new Map();
|
|
19642
|
+
const originStackCache = /* @__PURE__ */ new Map();
|
|
19643
|
+
const originError = Symbol("OriginError");
|
|
19494
19644
|
const CLOSE = {};
|
|
19495
19645
|
var Query = class extends Promise {
|
|
19496
19646
|
constructor(strings, args, handler, canceller, options = {}) {
|
|
@@ -19886,14 +20036,15 @@ function arrayParserLoop(s, x, parser, typarray) {
|
|
|
19886
20036
|
const delimiter = typarray === 1020 ? ";" : ",";
|
|
19887
20037
|
for (; s.i < x.length; s.i++) {
|
|
19888
20038
|
s.char = x[s.i];
|
|
19889
|
-
if (s.quoted)
|
|
19890
|
-
|
|
19891
|
-
|
|
19892
|
-
|
|
19893
|
-
|
|
19894
|
-
|
|
19895
|
-
|
|
19896
|
-
|
|
20039
|
+
if (s.quoted) {
|
|
20040
|
+
if (s.char === "\\") s.str += x[++s.i];
|
|
20041
|
+
else if (s.char === "\"") {
|
|
20042
|
+
xs.push(parser ? parser(s.str) : s.str);
|
|
20043
|
+
s.str = "";
|
|
20044
|
+
s.quoted = x[s.i + 1] === "\"";
|
|
20045
|
+
s.last = s.i + 2;
|
|
20046
|
+
} else s.str += s.char;
|
|
20047
|
+
} else if (s.char === "\"") s.quoted = true;
|
|
19897
20048
|
else if (s.char === "{") {
|
|
19898
20049
|
s.last = ++s.i;
|
|
19899
20050
|
xs.push(arrayParserLoop(s, x, parser, typarray));
|
|
@@ -20082,8 +20233,13 @@ function reset() {
|
|
|
20082
20233
|
//#region ../../node_modules/.pnpm/postgres@3.4.9/node_modules/postgres/src/connection.js
|
|
20083
20234
|
var connection_default = Connection;
|
|
20084
20235
|
let uid = 1;
|
|
20085
|
-
const Sync = b().S().end()
|
|
20086
|
-
const
|
|
20236
|
+
const Sync = b().S().end();
|
|
20237
|
+
const Flush = b().H().end();
|
|
20238
|
+
const SSLRequest = b().i32(8).i32(80877103).end(8);
|
|
20239
|
+
const ExecuteUnnamed = Buffer.concat([b().E().str(b.N).i32(0).end(), Sync]);
|
|
20240
|
+
const DescribeUnnamed = b().D().str("S").str(b.N).end();
|
|
20241
|
+
const noop$1 = () => {};
|
|
20242
|
+
const retryRoutines = /* @__PURE__ */ new Set([
|
|
20087
20243
|
"FetchPreparedStatement",
|
|
20088
20244
|
"RevalidateCachedQuery",
|
|
20089
20245
|
"transformAssignedExpr"
|
|
@@ -20373,7 +20529,7 @@ function Connection(options, queues = {}, { onopen = noop$1, onend = noop$1, onc
|
|
|
20373
20529
|
function handle(xs, x = xs[0]) {
|
|
20374
20530
|
(x === 68 ? DataRow : x === 100 ? CopyData : x === 65 ? NotificationResponse : x === 83 ? ParameterStatus : x === 90 ? ReadyForQuery : x === 67 ? CommandComplete : x === 50 ? BindComplete : x === 49 ? ParseComplete : x === 116 ? ParameterDescription : x === 84 ? RowDescription : x === 82 ? Authentication : x === 110 ? NoData : x === 75 ? BackendKeyData : x === 69 ? ErrorResponse : x === 115 ? PortalSuspended : x === 51 ? CloseComplete : x === 71 ? CopyInResponse : x === 78 ? NoticeResponse : x === 72 ? CopyOutResponse : x === 99 ? CopyDone : x === 73 ? EmptyQueryResponse : x === 86 ? FunctionCallResponse : x === 118 ? NegotiateProtocolVersion : x === 87 ? CopyBothResponse :
|
|
20375
20531
|
/* c8 ignore next */
|
|
20376
|
-
UnknownMessage)(xs);
|
|
20532
|
+
UnknownMessage)(xs);
|
|
20377
20533
|
}
|
|
20378
20534
|
function DataRow(x) {
|
|
20379
20535
|
let index = 7;
|
|
@@ -20399,9 +20555,10 @@ UnknownMessage)(xs);
|
|
|
20399
20555
|
}
|
|
20400
20556
|
}
|
|
20401
20557
|
function ReadyForQuery(x) {
|
|
20402
|
-
if (query)
|
|
20403
|
-
|
|
20404
|
-
|
|
20558
|
+
if (query) {
|
|
20559
|
+
if (errorResponse) query.retried ? errored(query.retried) : query.prepared && retryRoutines.has(errorResponse.routine) ? retry(query, errorResponse) : errored(errorResponse);
|
|
20560
|
+
else query.resolve(results || result);
|
|
20561
|
+
} else if (errorResponse) errored(errorResponse);
|
|
20405
20562
|
query = results = errorResponse = null;
|
|
20406
20563
|
result = new Result();
|
|
20407
20564
|
connectTimer.cancel();
|
|
@@ -20797,7 +20954,7 @@ function Subscribe(postgres, options) {
|
|
|
20797
20954
|
fn,
|
|
20798
20955
|
onsubscribe
|
|
20799
20956
|
};
|
|
20800
|
-
const fns = subscribers.has(event) ? subscribers.get(event).add(subscriber) : subscribers.set(event, new Set([subscriber])).get(event);
|
|
20957
|
+
const fns = subscribers.has(event) ? subscribers.get(event).add(subscriber) : subscribers.set(event, /* @__PURE__ */ new Set([subscriber])).get(event);
|
|
20801
20958
|
const unsubscribe = () => {
|
|
20802
20959
|
fns.delete(subscriber);
|
|
20803
20960
|
fns.size === 0 && subscribers.delete(event);
|
|
@@ -20987,7 +21144,7 @@ function largeObject(sql, oid, mode = 393216) {
|
|
|
20987
21144
|
};
|
|
20988
21145
|
resolve(lo);
|
|
20989
21146
|
return new Promise(async (r) => finish = r);
|
|
20990
|
-
async function readable({ highWaterMark =
|
|
21147
|
+
async function readable({ highWaterMark = 16384, start = 0, end = Infinity } = {}) {
|
|
20991
21148
|
let max = end - start;
|
|
20992
21149
|
start && await lo.seek(start);
|
|
20993
21150
|
return new Stream.Readable({
|
|
@@ -21001,7 +21158,7 @@ function largeObject(sql, oid, mode = 393216) {
|
|
|
21001
21158
|
}
|
|
21002
21159
|
});
|
|
21003
21160
|
}
|
|
21004
|
-
async function writable({ highWaterMark =
|
|
21161
|
+
async function writable({ highWaterMark = 16384, start = 0 } = {}) {
|
|
21005
21162
|
start && await lo.seek(start);
|
|
21006
21163
|
return new Stream.Writable({
|
|
21007
21164
|
highWaterMark,
|
|
@@ -21440,7 +21597,8 @@ const CONSTRAINT_TYPE_LABELS = {
|
|
|
21440
21597
|
x: "EXCLUSION"
|
|
21441
21598
|
};
|
|
21442
21599
|
async function fetchSchemaInfo(schemaName) {
|
|
21443
|
-
const
|
|
21600
|
+
const databaseUrl = await resolveBaseDsn(env);
|
|
21601
|
+
const sql = src_default(databaseUrl);
|
|
21444
21602
|
try {
|
|
21445
21603
|
return await sql.begin("read only", async (tx) => {
|
|
21446
21604
|
const tables = await tx`
|
|
@@ -21616,7 +21774,7 @@ async function runEncodeUriCommand(value) {
|
|
|
21616
21774
|
}
|
|
21617
21775
|
|
|
21618
21776
|
//#endregion
|
|
21619
|
-
//#region ../../node_modules/.pnpm/smol-toml@1.
|
|
21777
|
+
//#region ../../node_modules/.pnpm/smol-toml@1.8.0/node_modules/smol-toml/dist/stringify.js
|
|
21620
21778
|
/*!
|
|
21621
21779
|
* Copyright (c) Squirrel Chat et al., All rights reserved.
|
|
21622
21780
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -21649,7 +21807,8 @@ function extendedTypeOf(obj) {
|
|
|
21649
21807
|
let type = typeof obj;
|
|
21650
21808
|
if (type === "object") {
|
|
21651
21809
|
if (Array.isArray(obj)) return "array";
|
|
21652
|
-
if (obj instanceof Date) return "date";
|
|
21810
|
+
if (typeof obj?.getUTCDate === "function" && obj instanceof Date) return "date";
|
|
21811
|
+
if (globalThis.Temporal && typeof obj?.since === "function" && (obj instanceof Temporal.Instant || obj instanceof Temporal.PlainDate || obj instanceof Temporal.PlainDateTime || obj instanceof Temporal.PlainTime || obj instanceof Temporal.ZonedDateTime)) return "temporal";
|
|
21653
21812
|
}
|
|
21654
21813
|
return type;
|
|
21655
21814
|
}
|
|
@@ -21660,23 +21819,30 @@ function isArrayOfTables(obj) {
|
|
|
21660
21819
|
function formatString(s) {
|
|
21661
21820
|
return JSON.stringify(s).replace(/\x7f/g, "\\u007f");
|
|
21662
21821
|
}
|
|
21822
|
+
function stringifyTemporal(temporal) {
|
|
21823
|
+
return temporal.toString({
|
|
21824
|
+
calendarName: "never",
|
|
21825
|
+
timeZoneName: "never"
|
|
21826
|
+
});
|
|
21827
|
+
}
|
|
21663
21828
|
function stringifyValue(val, type, depth, numberAsFloat) {
|
|
21664
21829
|
if (depth === 0) throw new Error("Could not stringify the object: maximum object depth exceeded");
|
|
21665
|
-
|
|
21666
|
-
|
|
21667
|
-
|
|
21668
|
-
|
|
21669
|
-
|
|
21670
|
-
|
|
21671
|
-
|
|
21672
|
-
|
|
21673
|
-
|
|
21674
|
-
|
|
21675
|
-
|
|
21676
|
-
|
|
21677
|
-
|
|
21678
|
-
|
|
21679
|
-
|
|
21830
|
+
switch (type) {
|
|
21831
|
+
case "number":
|
|
21832
|
+
if (isNaN(val)) return "nan";
|
|
21833
|
+
if (val === Infinity) return "inf";
|
|
21834
|
+
if (val === -Infinity) return "-inf";
|
|
21835
|
+
if (Number.isInteger(val) && (numberAsFloat || !Number.isSafeInteger(val))) return val.toFixed(1);
|
|
21836
|
+
case "bigint":
|
|
21837
|
+
case "boolean": return val.toString();
|
|
21838
|
+
case "string": return formatString(val);
|
|
21839
|
+
case "date":
|
|
21840
|
+
if (isNaN(val.getTime())) throw new TypeError("cannot serialize invalid date");
|
|
21841
|
+
return val.toISOString();
|
|
21842
|
+
case "object": return stringifyInlineTable(val, depth, numberAsFloat);
|
|
21843
|
+
case "array": return stringifyArray(val, depth, numberAsFloat);
|
|
21844
|
+
case "temporal": return stringifyTemporal(val);
|
|
21845
|
+
}
|
|
21680
21846
|
}
|
|
21681
21847
|
function stringifyInlineTable(obj, depth, numberAsFloat) {
|
|
21682
21848
|
let keys = Object.keys(obj);
|
|
@@ -21998,9 +22164,10 @@ var require_visit = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
21998
22164
|
function replaceNode(key, path, node) {
|
|
21999
22165
|
const parent = path[path.length - 1];
|
|
22000
22166
|
if (identity.isCollection(parent)) parent.items[key] = node;
|
|
22001
|
-
else if (identity.isPair(parent))
|
|
22002
|
-
|
|
22003
|
-
|
|
22167
|
+
else if (identity.isPair(parent)) {
|
|
22168
|
+
if (key === "key") parent.key = node;
|
|
22169
|
+
else parent.value = node;
|
|
22170
|
+
} else if (identity.isDocument(parent)) parent.contents = node;
|
|
22004
22171
|
else {
|
|
22005
22172
|
const pt = identity.isAlias(parent) ? "alias" : "scalar";
|
|
22006
22173
|
throw new Error(`Cannot replace node with ${pt} parent`);
|
|
@@ -22058,7 +22225,6 @@ var require_directives = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
22058
22225
|
version: "1.2"
|
|
22059
22226
|
};
|
|
22060
22227
|
this.tags = Object.assign({}, Directives.defaultTags);
|
|
22061
|
-
break;
|
|
22062
22228
|
}
|
|
22063
22229
|
return res;
|
|
22064
22230
|
}
|
|
@@ -22255,30 +22421,32 @@ var require_applyReviver = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
22255
22421
|
* Includes extensions for handling Map and Set objects.
|
|
22256
22422
|
*/
|
|
22257
22423
|
function applyReviver(reviver, obj, key, val) {
|
|
22258
|
-
if (val && typeof val === "object")
|
|
22259
|
-
|
|
22260
|
-
|
|
22261
|
-
|
|
22262
|
-
|
|
22263
|
-
|
|
22264
|
-
|
|
22265
|
-
const
|
|
22266
|
-
|
|
22267
|
-
|
|
22268
|
-
|
|
22269
|
-
|
|
22270
|
-
|
|
22271
|
-
|
|
22272
|
-
|
|
22273
|
-
|
|
22274
|
-
|
|
22275
|
-
|
|
22424
|
+
if (val && typeof val === "object") {
|
|
22425
|
+
if (Array.isArray(val)) for (let i = 0, len = val.length; i < len; ++i) {
|
|
22426
|
+
const v0 = val[i];
|
|
22427
|
+
const v1 = applyReviver(reviver, val, String(i), v0);
|
|
22428
|
+
if (v1 === void 0) delete val[i];
|
|
22429
|
+
else if (v1 !== v0) val[i] = v1;
|
|
22430
|
+
}
|
|
22431
|
+
else if (val instanceof Map) for (const k of Array.from(val.keys())) {
|
|
22432
|
+
const v0 = val.get(k);
|
|
22433
|
+
const v1 = applyReviver(reviver, val, k, v0);
|
|
22434
|
+
if (v1 === void 0) val.delete(k);
|
|
22435
|
+
else if (v1 !== v0) val.set(k, v1);
|
|
22436
|
+
}
|
|
22437
|
+
else if (val instanceof Set) for (const v0 of Array.from(val)) {
|
|
22438
|
+
const v1 = applyReviver(reviver, val, v0, v0);
|
|
22439
|
+
if (v1 === void 0) val.delete(v0);
|
|
22440
|
+
else if (v1 !== v0) {
|
|
22441
|
+
val.delete(v0);
|
|
22442
|
+
val.add(v1);
|
|
22443
|
+
}
|
|
22444
|
+
}
|
|
22445
|
+
else for (const [k, v0] of Object.entries(val)) {
|
|
22446
|
+
const v1 = applyReviver(reviver, val, k, v0);
|
|
22447
|
+
if (v1 === void 0) delete val[k];
|
|
22448
|
+
else if (v1 !== v0) val[k] = v1;
|
|
22276
22449
|
}
|
|
22277
|
-
}
|
|
22278
|
-
else for (const [k, v0] of Object.entries(val)) {
|
|
22279
|
-
const v1 = applyReviver(reviver, val, k, v0);
|
|
22280
|
-
if (v1 === void 0) delete val[k];
|
|
22281
|
-
else if (v1 !== v0) val[k] = v1;
|
|
22282
22450
|
}
|
|
22283
22451
|
return reviver.call(obj, key, val);
|
|
22284
22452
|
}
|
|
@@ -22559,7 +22727,7 @@ var require_Collection = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
22559
22727
|
const a = [];
|
|
22560
22728
|
a[k] = v;
|
|
22561
22729
|
v = a;
|
|
22562
|
-
} else v = new Map([[k, v]]);
|
|
22730
|
+
} else v = /* @__PURE__ */ new Map([[k, v]]);
|
|
22563
22731
|
}
|
|
22564
22732
|
return createNode.createNode(v, void 0, {
|
|
22565
22733
|
aliasDuplicateObjects: false,
|
|
@@ -22707,8 +22875,10 @@ var require_foldFlowLines = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
22707
22875
|
const folds = [];
|
|
22708
22876
|
const escapedFolds = {};
|
|
22709
22877
|
let end = lineWidth - indent.length;
|
|
22710
|
-
if (typeof indentAtStart === "number")
|
|
22711
|
-
|
|
22878
|
+
if (typeof indentAtStart === "number") {
|
|
22879
|
+
if (indentAtStart > lineWidth - Math.max(2, minContentWidth)) folds.push(0);
|
|
22880
|
+
else end = lineWidth - indentAtStart;
|
|
22881
|
+
}
|
|
22712
22882
|
let split = void 0;
|
|
22713
22883
|
let prev = void 0;
|
|
22714
22884
|
let overflow = false;
|
|
@@ -22745,23 +22915,25 @@ var require_foldFlowLines = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
22745
22915
|
const next = text[i + 1];
|
|
22746
22916
|
if (next && next !== " " && next !== "\n" && next !== " ") split = i;
|
|
22747
22917
|
}
|
|
22748
|
-
if (i >= end)
|
|
22749
|
-
|
|
22750
|
-
|
|
22751
|
-
|
|
22752
|
-
|
|
22753
|
-
|
|
22754
|
-
prev
|
|
22755
|
-
|
|
22756
|
-
|
|
22757
|
-
|
|
22758
|
-
|
|
22759
|
-
|
|
22760
|
-
|
|
22761
|
-
|
|
22762
|
-
|
|
22763
|
-
|
|
22764
|
-
|
|
22918
|
+
if (i >= end) {
|
|
22919
|
+
if (split) {
|
|
22920
|
+
folds.push(split);
|
|
22921
|
+
end = split + endStep;
|
|
22922
|
+
split = void 0;
|
|
22923
|
+
} else if (mode === FOLD_QUOTED) {
|
|
22924
|
+
while (prev === " " || prev === " ") {
|
|
22925
|
+
prev = ch;
|
|
22926
|
+
ch = text[i += 1];
|
|
22927
|
+
overflow = true;
|
|
22928
|
+
}
|
|
22929
|
+
const j = i > escEnd + 1 ? i - 2 : escStart - 1;
|
|
22930
|
+
if (escapedFolds[j]) return text;
|
|
22931
|
+
folds.push(j);
|
|
22932
|
+
escapedFolds[j] = true;
|
|
22933
|
+
end = j + endStep;
|
|
22934
|
+
split = void 0;
|
|
22935
|
+
} else overflow = true;
|
|
22936
|
+
}
|
|
22765
22937
|
}
|
|
22766
22938
|
prev = ch;
|
|
22767
22939
|
}
|
|
@@ -23122,7 +23294,7 @@ var require_stringify = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
23122
23294
|
if (ctx.resolvedAliases?.has(item)) throw new TypeError(`Cannot stringify circular structure without alias nodes`);
|
|
23123
23295
|
else {
|
|
23124
23296
|
if (ctx.resolvedAliases) ctx.resolvedAliases.add(item);
|
|
23125
|
-
else ctx.resolvedAliases = new Set([item]);
|
|
23297
|
+
else ctx.resolvedAliases = /* @__PURE__ */ new Set([item]);
|
|
23126
23298
|
item = item.resolve(ctx.doc);
|
|
23127
23299
|
}
|
|
23128
23300
|
}
|
|
@@ -23245,8 +23417,10 @@ var require_log = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
23245
23417
|
if (logLevel === "debug") console.log(...messages);
|
|
23246
23418
|
}
|
|
23247
23419
|
function warn(logLevel, warning) {
|
|
23248
|
-
if (logLevel === "debug" || logLevel === "warn")
|
|
23249
|
-
|
|
23420
|
+
if (logLevel === "debug" || logLevel === "warn") {
|
|
23421
|
+
if (typeof node_process$2.emitWarning === "function") node_process$2.emitWarning(warning);
|
|
23422
|
+
else console.warn(warning);
|
|
23423
|
+
}
|
|
23250
23424
|
}
|
|
23251
23425
|
exports.debug = debug;
|
|
23252
23426
|
exports.warn = warn;
|
|
@@ -23356,7 +23530,9 @@ var require_Pair = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
23356
23530
|
var addPairToJSMap = require_addPairToJSMap();
|
|
23357
23531
|
var identity = require_identity();
|
|
23358
23532
|
function createPair(key, value, ctx) {
|
|
23359
|
-
|
|
23533
|
+
const k = createNode.createNode(key, void 0, ctx);
|
|
23534
|
+
const v = createNode.createNode(value, void 0, ctx);
|
|
23535
|
+
return new Pair(k, v);
|
|
23360
23536
|
}
|
|
23361
23537
|
var Pair = class Pair {
|
|
23362
23538
|
constructor(key, value = null) {
|
|
@@ -24098,11 +24274,12 @@ var require_pairs = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
24098
24274
|
if (iterable && Symbol.iterator in Object(iterable)) for (let it of iterable) {
|
|
24099
24275
|
if (typeof replacer === "function") it = replacer.call(iterable, String(i++), it);
|
|
24100
24276
|
let key, value;
|
|
24101
|
-
if (Array.isArray(it))
|
|
24102
|
-
|
|
24103
|
-
|
|
24104
|
-
|
|
24105
|
-
|
|
24277
|
+
if (Array.isArray(it)) {
|
|
24278
|
+
if (it.length === 2) {
|
|
24279
|
+
key = it[0];
|
|
24280
|
+
value = it[1];
|
|
24281
|
+
} else throw new TypeError(`Expected [key, value] tuple: ${it}`);
|
|
24282
|
+
} else if (it && it instanceof Object) {
|
|
24106
24283
|
const keys = Object.keys(it);
|
|
24107
24284
|
if (keys.length === 1) {
|
|
24108
24285
|
key = keys[0];
|
|
@@ -24179,8 +24356,10 @@ var require_omap = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
24179
24356
|
resolve(seq, onError) {
|
|
24180
24357
|
const pairs$1 = pairs.resolvePairs(seq, onError);
|
|
24181
24358
|
const seenKeys = [];
|
|
24182
|
-
for (const { key } of pairs$1.items) if (identity.isScalar(key))
|
|
24183
|
-
|
|
24359
|
+
for (const { key } of pairs$1.items) if (identity.isScalar(key)) {
|
|
24360
|
+
if (seenKeys.includes(key.value)) onError(`Ordered maps must not include duplicate keys: ${key.value}`);
|
|
24361
|
+
else seenKeys.push(key.value);
|
|
24362
|
+
}
|
|
24184
24363
|
return Object.assign(new YAMLOMap(), pairs$1);
|
|
24185
24364
|
},
|
|
24186
24365
|
createNode: (schema, iterable, ctx) => YAMLOMap.from(schema, iterable, ctx)
|
|
@@ -24280,9 +24459,7 @@ var require_int = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
24280
24459
|
case 8:
|
|
24281
24460
|
str = `0o${str}`;
|
|
24282
24461
|
break;
|
|
24283
|
-
case 16:
|
|
24284
|
-
str = `0x${str}`;
|
|
24285
|
-
break;
|
|
24462
|
+
case 16: str = `0x${str}`;
|
|
24286
24463
|
}
|
|
24287
24464
|
const n = BigInt(str);
|
|
24288
24465
|
return sign === "-" ? BigInt(-1) * n : n;
|
|
@@ -24398,9 +24575,10 @@ var require_set = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
24398
24575
|
tag: "tag:yaml.org,2002:set",
|
|
24399
24576
|
createNode: (schema, iterable, ctx) => YAMLSet.from(schema, iterable, ctx),
|
|
24400
24577
|
resolve(map, onError) {
|
|
24401
|
-
if (identity.isMap(map))
|
|
24402
|
-
|
|
24403
|
-
|
|
24578
|
+
if (identity.isMap(map)) {
|
|
24579
|
+
if (map.hasAllNullValues(true)) return Object.assign(new YAMLSet(), map);
|
|
24580
|
+
else onError("Set items must all have null values");
|
|
24581
|
+
} else onError("Expected a mapping for this tag");
|
|
24404
24582
|
return map;
|
|
24405
24583
|
}
|
|
24406
24584
|
};
|
|
@@ -24553,7 +24731,7 @@ var require_tags = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
24553
24731
|
var schema$2 = require_schema();
|
|
24554
24732
|
var set = require_set();
|
|
24555
24733
|
var timestamp = require_timestamp();
|
|
24556
|
-
const schemas = new Map([
|
|
24734
|
+
const schemas = /* @__PURE__ */ new Map([
|
|
24557
24735
|
["core", schema.schema],
|
|
24558
24736
|
["failsafe", [
|
|
24559
24737
|
map.map,
|
|
@@ -24596,10 +24774,12 @@ var require_tags = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
24596
24774
|
const schemaTags = schemas.get(schemaName);
|
|
24597
24775
|
if (schemaTags && !customTags) return addMergeTag && !schemaTags.includes(merge.merge) ? schemaTags.concat(merge.merge) : schemaTags.slice();
|
|
24598
24776
|
let tags = schemaTags;
|
|
24599
|
-
if (!tags)
|
|
24600
|
-
|
|
24601
|
-
|
|
24602
|
-
|
|
24777
|
+
if (!tags) {
|
|
24778
|
+
if (Array.isArray(customTags)) tags = [];
|
|
24779
|
+
else {
|
|
24780
|
+
const keys = Array.from(schemas.keys()).filter((key) => key !== "yaml11").map((key) => JSON.stringify(key)).join(", ");
|
|
24781
|
+
throw new Error(`Unknown schema "${schemaName}"; use one of ${keys} or define customTags array`);
|
|
24782
|
+
}
|
|
24603
24783
|
}
|
|
24604
24784
|
if (Array.isArray(customTags)) for (const tag of customTags) tags = tags.concat(tag);
|
|
24605
24785
|
else if (typeof customTags === "function") tags = customTags(tags.slice());
|
|
@@ -24691,14 +24871,15 @@ var require_stringifyDocument = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
24691
24871
|
if ((body[0] === "|" || body[0] === ">") && lines[lines.length - 1] === "---") lines[lines.length - 1] = `--- ${body}`;
|
|
24692
24872
|
else lines.push(body);
|
|
24693
24873
|
} else lines.push(stringify.stringify(doc.contents, ctx));
|
|
24694
|
-
if (doc.directives?.docEnd)
|
|
24695
|
-
|
|
24696
|
-
|
|
24697
|
-
|
|
24698
|
-
|
|
24699
|
-
|
|
24700
|
-
|
|
24701
|
-
|
|
24874
|
+
if (doc.directives?.docEnd) {
|
|
24875
|
+
if (doc.comment) {
|
|
24876
|
+
const cs = commentString(doc.comment);
|
|
24877
|
+
if (cs.includes("\n")) {
|
|
24878
|
+
lines.push("...");
|
|
24879
|
+
lines.push(stringifyComment.indentComment(cs, ""));
|
|
24880
|
+
} else lines.push(`... ${cs}`);
|
|
24881
|
+
} else lines.push("...");
|
|
24882
|
+
} else {
|
|
24702
24883
|
let dc = doc.comment;
|
|
24703
24884
|
if (dc && chompKeep) dc = dc.replace(/^\n+/, "");
|
|
24704
24885
|
if (dc) {
|
|
@@ -25222,7 +25403,7 @@ var require_resolve_block_map = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
25222
25403
|
var utilMapIncludes = require_util_map_includes();
|
|
25223
25404
|
const startColMsg = "All mapping items must start at the same column";
|
|
25224
25405
|
function resolveBlockMap({ composeNode, composeEmptyNode }, ctx, bm, onError, tag) {
|
|
25225
|
-
const map = new (tag?.nodeClass ?? YAMLMap.YAMLMap)(ctx.schema);
|
|
25406
|
+
const map = new ((tag?.nodeClass) ?? YAMLMap.YAMLMap)(ctx.schema);
|
|
25226
25407
|
if (ctx.atRoot) ctx.atRoot = false;
|
|
25227
25408
|
let offset = bm.offset;
|
|
25228
25409
|
let commentEnd = null;
|
|
@@ -25244,8 +25425,10 @@ var require_resolve_block_map = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
25244
25425
|
}
|
|
25245
25426
|
if (!keyProps.anchor && !keyProps.tag && !sep) {
|
|
25246
25427
|
commentEnd = keyProps.end;
|
|
25247
|
-
if (keyProps.comment)
|
|
25248
|
-
|
|
25428
|
+
if (keyProps.comment) {
|
|
25429
|
+
if (map.comment) map.comment += "\n" + keyProps.comment;
|
|
25430
|
+
else map.comment = keyProps.comment;
|
|
25431
|
+
}
|
|
25249
25432
|
continue;
|
|
25250
25433
|
}
|
|
25251
25434
|
if (keyProps.newlineAfterProp || utilContainsNewline.containsNewline(key)) onError(key ?? start[start.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line");
|
|
@@ -25278,8 +25461,10 @@ var require_resolve_block_map = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
25278
25461
|
map.items.push(pair);
|
|
25279
25462
|
} else {
|
|
25280
25463
|
if (implicitKey) onError(keyNode.range, "MISSING_CHAR", "Implicit map keys need to be followed by map values");
|
|
25281
|
-
if (valueProps.comment)
|
|
25282
|
-
|
|
25464
|
+
if (valueProps.comment) {
|
|
25465
|
+
if (keyNode.comment) keyNode.comment += "\n" + valueProps.comment;
|
|
25466
|
+
else keyNode.comment = valueProps.comment;
|
|
25467
|
+
}
|
|
25283
25468
|
const pair = new Pair.Pair(keyNode);
|
|
25284
25469
|
if (ctx.options.keepSourceTokens) pair.srcToken = collItem;
|
|
25285
25470
|
map.items.push(pair);
|
|
@@ -25303,7 +25488,7 @@ var require_resolve_block_seq = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
25303
25488
|
var resolveProps = require_resolve_props();
|
|
25304
25489
|
var utilFlowIndentCheck = require_util_flow_indent_check();
|
|
25305
25490
|
function resolveBlockSeq({ composeNode, composeEmptyNode }, ctx, bs, onError, tag) {
|
|
25306
|
-
const seq = new (tag?.nodeClass ?? YAMLSeq.YAMLSeq)(ctx.schema);
|
|
25491
|
+
const seq = new ((tag?.nodeClass) ?? YAMLSeq.YAMLSeq)(ctx.schema);
|
|
25307
25492
|
if (ctx.atRoot) ctx.atRoot = false;
|
|
25308
25493
|
if (ctx.atKey) ctx.atKey = false;
|
|
25309
25494
|
let offset = bs.offset;
|
|
@@ -25317,12 +25502,15 @@ var require_resolve_block_seq = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
25317
25502
|
parentIndent: bs.indent,
|
|
25318
25503
|
startOnNewline: true
|
|
25319
25504
|
});
|
|
25320
|
-
if (!props.found)
|
|
25321
|
-
|
|
25322
|
-
|
|
25323
|
-
|
|
25324
|
-
|
|
25325
|
-
|
|
25505
|
+
if (!props.found) {
|
|
25506
|
+
if (props.anchor || props.tag || value) {
|
|
25507
|
+
if (value?.type === "block-seq") onError(props.end, "BAD_INDENT", "All sequence items must start at the same column");
|
|
25508
|
+
else onError(offset, "MISSING_CHAR", "Sequence item without - indicator");
|
|
25509
|
+
} else {
|
|
25510
|
+
commentEnd = props.end;
|
|
25511
|
+
if (props.comment) seq.comment = props.comment;
|
|
25512
|
+
continue;
|
|
25513
|
+
}
|
|
25326
25514
|
}
|
|
25327
25515
|
const node = value ? composeNode(ctx, value, props, onError) : composeEmptyNode(ctx, props.end, start, null, props, onError);
|
|
25328
25516
|
if (ctx.schema.compat) utilFlowIndentCheck.flowIndentCheck(bs.indent, value, onError);
|
|
@@ -25394,7 +25582,7 @@ var require_resolve_flow_collection = /* @__PURE__ */ __commonJSMin(((exports) =
|
|
|
25394
25582
|
function resolveFlowCollection({ composeNode, composeEmptyNode }, ctx, fc, onError, tag) {
|
|
25395
25583
|
const isMap = fc.start.source === "{";
|
|
25396
25584
|
const fcName = isMap ? "flow map" : "flow sequence";
|
|
25397
|
-
const coll = new (tag?.nodeClass ?? (isMap ? YAMLMap.YAMLMap : YAMLSeq.YAMLSeq))(ctx.schema);
|
|
25585
|
+
const coll = new ((tag?.nodeClass) ?? (isMap ? YAMLMap.YAMLMap : YAMLSeq.YAMLSeq))(ctx.schema);
|
|
25398
25586
|
coll.flow = true;
|
|
25399
25587
|
const atRoot = ctx.atRoot;
|
|
25400
25588
|
if (atRoot) ctx.atRoot = false;
|
|
@@ -25416,8 +25604,10 @@ var require_resolve_flow_collection = /* @__PURE__ */ __commonJSMin(((exports) =
|
|
|
25416
25604
|
if (!props.anchor && !props.tag && !sep && !value) {
|
|
25417
25605
|
if (i === 0 && props.comma) onError(props.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${fcName}`);
|
|
25418
25606
|
else if (i < fc.items.length - 1) onError(props.start, "UNEXPECTED_TOKEN", `Unexpected empty item in ${fcName}`);
|
|
25419
|
-
if (props.comment)
|
|
25420
|
-
|
|
25607
|
+
if (props.comment) {
|
|
25608
|
+
if (coll.comment) coll.comment += "\n" + props.comment;
|
|
25609
|
+
else coll.comment = props.comment;
|
|
25610
|
+
}
|
|
25421
25611
|
offset = props.end;
|
|
25422
25612
|
continue;
|
|
25423
25613
|
}
|
|
@@ -25477,13 +25667,17 @@ var require_resolve_flow_collection = /* @__PURE__ */ __commonJSMin(((exports) =
|
|
|
25477
25667
|
}
|
|
25478
25668
|
if (props.start < valueProps.found.offset - 1024) onError(valueProps.found, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit flow sequence key");
|
|
25479
25669
|
}
|
|
25480
|
-
} else if (value)
|
|
25481
|
-
|
|
25670
|
+
} else if (value) {
|
|
25671
|
+
if ("source" in value && value.source?.[0] === ":") onError(value, "MISSING_CHAR", `Missing space after : in ${fcName}`);
|
|
25672
|
+
else onError(valueProps.start, "MISSING_CHAR", `Missing , or : between ${fcName} items`);
|
|
25673
|
+
}
|
|
25482
25674
|
const valueNode = value ? composeNode(ctx, value, valueProps, onError) : valueProps.found ? composeEmptyNode(ctx, valueProps.end, sep, null, valueProps, onError) : null;
|
|
25483
25675
|
if (valueNode) {
|
|
25484
25676
|
if (isBlock(value)) onError(valueNode.range, "BLOCK_IN_FLOW", blockMsg);
|
|
25485
|
-
} else if (valueProps.comment)
|
|
25486
|
-
|
|
25677
|
+
} else if (valueProps.comment) {
|
|
25678
|
+
if (keyNode.comment) keyNode.comment += "\n" + valueProps.comment;
|
|
25679
|
+
else keyNode.comment = valueProps.comment;
|
|
25680
|
+
}
|
|
25487
25681
|
const pair = new Pair.Pair(keyNode, valueNode);
|
|
25488
25682
|
if (ctx.options.keepSourceTokens) pair.srcToken = collItem;
|
|
25489
25683
|
if (isMap) {
|
|
@@ -25517,8 +25711,10 @@ var require_resolve_flow_collection = /* @__PURE__ */ __commonJSMin(((exports) =
|
|
|
25517
25711
|
}
|
|
25518
25712
|
if (ee.length > 0) {
|
|
25519
25713
|
const end = resolveEnd.resolveEnd(ee, cePos, ctx.options.strict, onError);
|
|
25520
|
-
if (end.comment)
|
|
25521
|
-
|
|
25714
|
+
if (end.comment) {
|
|
25715
|
+
if (coll.comment) coll.comment += "\n" + end.comment;
|
|
25716
|
+
else coll.comment = end.comment;
|
|
25717
|
+
}
|
|
25522
25718
|
coll.range = [
|
|
25523
25719
|
fc.offset,
|
|
25524
25720
|
cePos,
|
|
@@ -25668,9 +25864,10 @@ var require_resolve_block_scalar = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
25668
25864
|
value += sep + indent.slice(trimIndent) + content;
|
|
25669
25865
|
sep = "\n";
|
|
25670
25866
|
prevMoreIndented = true;
|
|
25671
|
-
} else if (content === "")
|
|
25672
|
-
|
|
25673
|
-
|
|
25867
|
+
} else if (content === "") {
|
|
25868
|
+
if (sep === "\n") value += "\n";
|
|
25869
|
+
else sep = "\n";
|
|
25870
|
+
} else {
|
|
25674
25871
|
value += sep + content;
|
|
25675
25872
|
sep = " ";
|
|
25676
25873
|
prevMoreIndented = false;
|
|
@@ -25832,9 +26029,7 @@ var require_resolve_flow_scalar = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
25832
26029
|
badChar = `block scalar indicator ${source[0]}`;
|
|
25833
26030
|
break;
|
|
25834
26031
|
case "@":
|
|
25835
|
-
case "`":
|
|
25836
|
-
badChar = `reserved character ${source[0]}`;
|
|
25837
|
-
break;
|
|
26032
|
+
case "`": badChar = `reserved character ${source[0]}`;
|
|
25838
26033
|
}
|
|
25839
26034
|
if (badChar) onError(0, "BAD_SCALAR_START", `Plain value cannot start with ${badChar}`);
|
|
25840
26035
|
return foldLines(source);
|
|
@@ -25866,9 +26061,10 @@ var require_resolve_flow_scalar = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
25866
26061
|
let pos = first.lastIndex;
|
|
25867
26062
|
line.lastIndex = pos;
|
|
25868
26063
|
while (match = line.exec(source)) {
|
|
25869
|
-
if (match[1] === "")
|
|
25870
|
-
|
|
25871
|
-
|
|
26064
|
+
if (match[1] === "") {
|
|
26065
|
+
if (sep === "\n") res += sep;
|
|
26066
|
+
else sep = "\n";
|
|
26067
|
+
} else {
|
|
25872
26068
|
res += sep + match[1];
|
|
25873
26069
|
sep = " ";
|
|
25874
26070
|
}
|
|
@@ -26005,8 +26201,10 @@ var require_compose_scalar = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
26005
26201
|
function findScalarTagByName(schema, value, tagName, tagToken, onError) {
|
|
26006
26202
|
if (tagName === "!") return schema[identity.SCALAR];
|
|
26007
26203
|
const matchWithTest = [];
|
|
26008
|
-
for (const tag of schema.tags) if (!tag.collection && tag.tag === tagName)
|
|
26009
|
-
|
|
26204
|
+
for (const tag of schema.tags) if (!tag.collection && tag.tag === tagName) {
|
|
26205
|
+
if (tag.default && tag.test) matchWithTest.push(tag);
|
|
26206
|
+
else return tag;
|
|
26207
|
+
}
|
|
26010
26208
|
for (const tag of matchWithTest) if (tag.test?.test(value)) return tag;
|
|
26011
26209
|
const kt = schema.knownTags[tagName];
|
|
26012
26210
|
if (kt && !kt.collection) {
|
|
@@ -26106,8 +26304,10 @@ var require_compose_node = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
26106
26304
|
if (anchor && node.anchor === "") onError(anchor, "BAD_ALIAS", "Anchor cannot be an empty string");
|
|
26107
26305
|
if (atKey && ctx.options.stringKeys && (!identity.isScalar(node) || typeof node.value !== "string" || node.tag && node.tag !== "tag:yaml.org,2002:str")) onError(tag ?? token, "NON_STRING_KEY", "With stringKeys, all keys must be strings");
|
|
26108
26306
|
if (spaceBefore) node.spaceBefore = true;
|
|
26109
|
-
if (comment)
|
|
26110
|
-
|
|
26307
|
+
if (comment) {
|
|
26308
|
+
if (token.type === "scalar" && token.source === "") node.comment = comment;
|
|
26309
|
+
else node.commentBefore = comment;
|
|
26310
|
+
}
|
|
26111
26311
|
if (ctx.options.keepSourceTokens && isSrcToken) node.srcToken = token;
|
|
26112
26312
|
return node;
|
|
26113
26313
|
}
|
|
@@ -27303,11 +27503,13 @@ var require_lexer = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
27303
27503
|
end = i;
|
|
27304
27504
|
} else if (isEmpty(ch)) {
|
|
27305
27505
|
let next = this.buffer[i + 1];
|
|
27306
|
-
if (ch === "\r")
|
|
27307
|
-
|
|
27308
|
-
|
|
27309
|
-
|
|
27310
|
-
|
|
27506
|
+
if (ch === "\r") {
|
|
27507
|
+
if (next === "\n") {
|
|
27508
|
+
i += 1;
|
|
27509
|
+
ch = "\n";
|
|
27510
|
+
next = this.buffer[i + 1];
|
|
27511
|
+
} else end = i;
|
|
27512
|
+
}
|
|
27311
27513
|
if (next === "#" || inFlow && flowIndicatorChars.has(next)) break;
|
|
27312
27514
|
if (ch === "\n") {
|
|
27313
27515
|
const cs = this.continueScalar(i + 1);
|
|
@@ -27526,9 +27728,10 @@ var require_parser = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
27526
27728
|
for (const it of fc.items) if (it.sep && !it.value && !includesToken(it.start, "explicit-key-ind") && !includesToken(it.sep, "map-value-ind")) {
|
|
27527
27729
|
if (it.key) it.value = it.key;
|
|
27528
27730
|
delete it.key;
|
|
27529
|
-
if (isFlowToken(it.value))
|
|
27530
|
-
|
|
27531
|
-
|
|
27731
|
+
if (isFlowToken(it.value)) {
|
|
27732
|
+
if (it.value.end) arrayPushArray(it.value.end, it.sep);
|
|
27733
|
+
else it.value.end = it.sep;
|
|
27734
|
+
} else arrayPushArray(it.start, it.sep);
|
|
27532
27735
|
delete it.sep;
|
|
27533
27736
|
}
|
|
27534
27737
|
}
|
|
@@ -27963,58 +28166,60 @@ var require_parser = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
27963
28166
|
this.onKeyLine = true;
|
|
27964
28167
|
return;
|
|
27965
28168
|
case "map-value-ind":
|
|
27966
|
-
if (it.explicitKey)
|
|
27967
|
-
|
|
27968
|
-
|
|
27969
|
-
});
|
|
27970
|
-
else {
|
|
27971
|
-
const start = getFirstKeyStartProps(it.start);
|
|
27972
|
-
this.stack.push({
|
|
27973
|
-
type: "block-map",
|
|
27974
|
-
offset: this.offset,
|
|
27975
|
-
indent: this.indent,
|
|
27976
|
-
items: [{
|
|
27977
|
-
start,
|
|
28169
|
+
if (it.explicitKey) {
|
|
28170
|
+
if (!it.sep) {
|
|
28171
|
+
if (includesToken(it.start, "newline")) Object.assign(it, {
|
|
27978
28172
|
key: null,
|
|
27979
28173
|
sep: [this.sourceToken]
|
|
27980
|
-
}
|
|
27981
|
-
|
|
27982
|
-
|
|
27983
|
-
|
|
27984
|
-
|
|
27985
|
-
|
|
27986
|
-
|
|
27987
|
-
|
|
27988
|
-
|
|
27989
|
-
|
|
27990
|
-
|
|
27991
|
-
|
|
27992
|
-
|
|
27993
|
-
|
|
28174
|
+
});
|
|
28175
|
+
else {
|
|
28176
|
+
const start = getFirstKeyStartProps(it.start);
|
|
28177
|
+
this.stack.push({
|
|
28178
|
+
type: "block-map",
|
|
28179
|
+
offset: this.offset,
|
|
28180
|
+
indent: this.indent,
|
|
28181
|
+
items: [{
|
|
28182
|
+
start,
|
|
28183
|
+
key: null,
|
|
28184
|
+
sep: [this.sourceToken]
|
|
28185
|
+
}]
|
|
28186
|
+
});
|
|
28187
|
+
}
|
|
28188
|
+
} else if (it.value) map.items.push({
|
|
28189
|
+
start: [],
|
|
27994
28190
|
key: null,
|
|
27995
28191
|
sep: [this.sourceToken]
|
|
27996
|
-
}
|
|
27997
|
-
|
|
27998
|
-
else if (isFlowToken(it.key) && !includesToken(it.sep, "newline")) {
|
|
27999
|
-
const start = getFirstKeyStartProps(it.start);
|
|
28000
|
-
const key = it.key;
|
|
28001
|
-
const sep = it.sep;
|
|
28002
|
-
sep.push(this.sourceToken);
|
|
28003
|
-
delete it.key;
|
|
28004
|
-
delete it.sep;
|
|
28005
|
-
this.stack.push({
|
|
28192
|
+
});
|
|
28193
|
+
else if (includesToken(it.sep, "map-value-ind")) this.stack.push({
|
|
28006
28194
|
type: "block-map",
|
|
28007
28195
|
offset: this.offset,
|
|
28008
28196
|
indent: this.indent,
|
|
28009
28197
|
items: [{
|
|
28010
28198
|
start,
|
|
28011
|
-
key,
|
|
28012
|
-
sep
|
|
28199
|
+
key: null,
|
|
28200
|
+
sep: [this.sourceToken]
|
|
28013
28201
|
}]
|
|
28014
28202
|
});
|
|
28015
|
-
|
|
28016
|
-
|
|
28017
|
-
|
|
28203
|
+
else if (isFlowToken(it.key) && !includesToken(it.sep, "newline")) {
|
|
28204
|
+
const start = getFirstKeyStartProps(it.start);
|
|
28205
|
+
const key = it.key;
|
|
28206
|
+
const sep = it.sep;
|
|
28207
|
+
sep.push(this.sourceToken);
|
|
28208
|
+
delete it.key;
|
|
28209
|
+
delete it.sep;
|
|
28210
|
+
this.stack.push({
|
|
28211
|
+
type: "block-map",
|
|
28212
|
+
offset: this.offset,
|
|
28213
|
+
indent: this.indent,
|
|
28214
|
+
items: [{
|
|
28215
|
+
start,
|
|
28216
|
+
key,
|
|
28217
|
+
sep
|
|
28218
|
+
}]
|
|
28219
|
+
});
|
|
28220
|
+
} else if (start.length > 0) it.sep = it.sep.concat(start, this.sourceToken);
|
|
28221
|
+
else it.sep.push(this.sourceToken);
|
|
28222
|
+
} else if (!it.sep) Object.assign(it, {
|
|
28018
28223
|
key: null,
|
|
28019
28224
|
sep: [this.sourceToken]
|
|
28020
28225
|
});
|
|
@@ -28388,8 +28593,10 @@ var require_public_api = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
28388
28593
|
const doc = parseDocument(src, options);
|
|
28389
28594
|
if (!doc) return null;
|
|
28390
28595
|
doc.warnings.forEach((warning) => log.warn(doc.options.logLevel, warning));
|
|
28391
|
-
if (doc.errors.length > 0)
|
|
28392
|
-
|
|
28596
|
+
if (doc.errors.length > 0) {
|
|
28597
|
+
if (doc.options.logLevel !== "silent") throw doc.errors[0];
|
|
28598
|
+
else doc.errors = [];
|
|
28599
|
+
}
|
|
28393
28600
|
return doc.toJS(Object.assign({ reviver: _reviver }, options));
|
|
28394
28601
|
}
|
|
28395
28602
|
function stringify(value, replacer, options) {
|
|
@@ -28503,8 +28710,9 @@ async function writeDagsterArtifacts(dagsterArtifacts, paths) {
|
|
|
28503
28710
|
//#region gen/command.ts
|
|
28504
28711
|
async function planGeneratedArtifacts() {
|
|
28505
28712
|
const dltSecretsToml = generateSecretsToml(await resolveBaseDsnObj(env));
|
|
28713
|
+
const manifests = await listPluginManifests();
|
|
28506
28714
|
return {
|
|
28507
|
-
dagsterYaml: generateDagsterYaml(
|
|
28715
|
+
dagsterYaml: generateDagsterYaml(manifests),
|
|
28508
28716
|
dltConfigToml: generateConfigToml(),
|
|
28509
28717
|
dltSecretsToml
|
|
28510
28718
|
};
|
|
@@ -28528,7 +28736,8 @@ async function runGen(paths) {
|
|
|
28528
28736
|
//#endregion
|
|
28529
28737
|
//#region query/runtime.ts
|
|
28530
28738
|
async function executeQuery(queryText) {
|
|
28531
|
-
const
|
|
28739
|
+
const databaseUrl = await resolveBaseDsn(env);
|
|
28740
|
+
const sql = src_default(databaseUrl);
|
|
28532
28741
|
try {
|
|
28533
28742
|
return await sql.begin("read only", async (transactionSql) => {
|
|
28534
28743
|
const result = await transactionSql.unsafe(queryText).values();
|
|
@@ -28571,11 +28780,13 @@ async function runQueryCommand(sql) {
|
|
|
28571
28780
|
//#endregion
|
|
28572
28781
|
//#region cli.ts
|
|
28573
28782
|
async function resolveRuntimePaths(command) {
|
|
28574
|
-
const
|
|
28575
|
-
|
|
28783
|
+
const options = command.optsWithGlobals();
|
|
28784
|
+
const rootDir = resolveContextBaseRootDir({
|
|
28785
|
+
cliRootDir: options.rootDir,
|
|
28576
28786
|
cwd: process.cwd(),
|
|
28577
28787
|
envRootDir: env.CTXB_ROOT_DIR
|
|
28578
|
-
})
|
|
28788
|
+
});
|
|
28789
|
+
const paths = deriveContextBasePaths(rootDir);
|
|
28579
28790
|
await ensureCtxbDir(paths.ctxbDir);
|
|
28580
28791
|
return paths;
|
|
28581
28792
|
}
|
|
@@ -28643,4 +28854,4 @@ runCli().catch((error) => {
|
|
|
28643
28854
|
//#endregion
|
|
28644
28855
|
export { createProgram, runCli };
|
|
28645
28856
|
//# sourceMappingURL=cli.mjs.map
|
|
28646
|
-
//# debugId=
|
|
28857
|
+
//# debugId=3d9a9038-da39-5c09-a71e-36219d48dd38
|