@settlemint/sdk-cli 1.1.1-prb50403bc → 1.1.1-prc7f21dc7
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.js +299 -1950
- package/dist/cli.js.map +4 -47
- package/package.json +6 -6
package/dist/cli.js
CHANGED
|
@@ -233728,8 +233728,8 @@ var require_mkdir = __commonJS((exports, module) => {
|
|
|
233728
233728
|
return "CwdError";
|
|
233729
233729
|
}
|
|
233730
233730
|
}
|
|
233731
|
-
var cGet = (cache,
|
|
233732
|
-
var cSet = (cache,
|
|
233731
|
+
var cGet = (cache, key2) => cache.get(normPath(key2));
|
|
233732
|
+
var cSet = (cache, key2, val) => cache.set(normPath(key2), val);
|
|
233733
233733
|
var checkCwd = (dir, cb) => {
|
|
233734
233734
|
fs3.stat(dir, (er2, st2) => {
|
|
233735
233735
|
if (er2 || !st2.isDirectory()) {
|
|
@@ -234100,8 +234100,8 @@ var require_unpack = __commonJS((exports, module) => {
|
|
|
234100
234100
|
}
|
|
234101
234101
|
};
|
|
234102
234102
|
var dropCache = (cache) => {
|
|
234103
|
-
for (const
|
|
234104
|
-
cache.delete(
|
|
234103
|
+
for (const key2 of cache.keys()) {
|
|
234104
|
+
cache.delete(key2);
|
|
234105
234105
|
}
|
|
234106
234106
|
};
|
|
234107
234107
|
|
|
@@ -238898,8 +238898,8 @@ var require_lib13 = __commonJS((exports, module) => {
|
|
|
238898
238898
|
function fetch2(input, options) {
|
|
238899
238899
|
return nodeFetch.fetch(input, options);
|
|
238900
238900
|
}
|
|
238901
|
-
for (const
|
|
238902
|
-
fetch2[
|
|
238901
|
+
for (const key2 in nodeFetch) {
|
|
238902
|
+
fetch2[key2] = nodeFetch[key2];
|
|
238903
238903
|
}
|
|
238904
238904
|
module.exports = fetch2;
|
|
238905
238905
|
});
|
|
@@ -238992,11 +238992,11 @@ var require_proxy = __commonJS((exports) => {
|
|
|
238992
238992
|
return hasRequiredSymbols$4 || (hasRequiredSymbols$4 = 1, symbols$4 = { kClose: Symbol("close"), kDestroy: Symbol("destroy"), kDispatch: Symbol("dispatch"), kUrl: Symbol("url"), kWriting: Symbol("writing"), kResuming: Symbol("resuming"), kQueue: Symbol("queue"), kConnect: Symbol("connect"), kConnecting: Symbol("connecting"), kKeepAliveDefaultTimeout: Symbol("default keep alive timeout"), kKeepAliveMaxTimeout: Symbol("max keep alive timeout"), kKeepAliveTimeoutThreshold: Symbol("keep alive timeout threshold"), kKeepAliveTimeoutValue: Symbol("keep alive timeout"), kKeepAlive: Symbol("keep alive"), kHeadersTimeout: Symbol("headers timeout"), kBodyTimeout: Symbol("body timeout"), kServerName: Symbol("server name"), kLocalAddress: Symbol("local address"), kHost: Symbol("host"), kNoRef: Symbol("no ref"), kBodyUsed: Symbol("used"), kBody: Symbol("abstracted request body"), kRunning: Symbol("running"), kBlocking: Symbol("blocking"), kPending: Symbol("pending"), kSize: Symbol("size"), kBusy: Symbol("busy"), kQueued: Symbol("queued"), kFree: Symbol("free"), kConnected: Symbol("connected"), kClosed: Symbol("closed"), kNeedDrain: Symbol("need drain"), kReset: Symbol("reset"), kDestroyed: Symbol.for("nodejs.stream.destroyed"), kResume: Symbol("resume"), kOnError: Symbol("on error"), kMaxHeadersSize: Symbol("max headers size"), kRunningIdx: Symbol("running index"), kPendingIdx: Symbol("pending index"), kError: Symbol("error"), kClients: Symbol("clients"), kClient: Symbol("client"), kParser: Symbol("parser"), kOnDestroyed: Symbol("destroy callbacks"), kPipelining: Symbol("pipelining"), kSocket: Symbol("socket"), kHostHeader: Symbol("host header"), kConnector: Symbol("connector"), kStrictContentLength: Symbol("strict content length"), kMaxRedirections: Symbol("maxRedirections"), kMaxRequests: Symbol("maxRequestsPerClient"), kProxy: Symbol("proxy agent options"), kCounter: Symbol("socket request counter"), kInterceptors: Symbol("dispatch interceptors"), kMaxResponseSize: Symbol("max response size"), kHTTP2Session: Symbol("http2Session"), kHTTP2SessionState: Symbol("http2Session state"), kRetryHandlerDefaultRetry: Symbol("retry agent default retry"), kConstruct: Symbol("constructable"), kListeners: Symbol("listeners"), kHTTPContext: Symbol("http context"), kMaxConcurrentStreams: Symbol("max concurrent streams"), kNoProxyAgent: Symbol("no proxy agent"), kHttpProxyAgent: Symbol("http proxy agent"), kHttpsProxyAgent: Symbol("https proxy agent") }), symbols$4;
|
|
238993
238993
|
}
|
|
238994
238994
|
e10(requireSymbols$4, "requireSymbols$4");
|
|
238995
|
-
var
|
|
238995
|
+
var errors2;
|
|
238996
238996
|
var hasRequiredErrors;
|
|
238997
238997
|
function requireErrors() {
|
|
238998
238998
|
if (hasRequiredErrors)
|
|
238999
|
-
return
|
|
238999
|
+
return errors2;
|
|
239000
239000
|
hasRequiredErrors = 1;
|
|
239001
239001
|
|
|
239002
239002
|
class A5 extends Error {
|
|
@@ -239205,7 +239205,7 @@ var require_proxy = __commonJS((exports) => {
|
|
|
239205
239205
|
super(i6, { cause: k5, ...F3 ?? {} }), this.name = "SecureProxyConnectionError", this.message = i6 || "Secure Proxy Connection failed", this.code = "UND_ERR_PRX_TLS", this.cause = k5;
|
|
239206
239206
|
}
|
|
239207
239207
|
}
|
|
239208
|
-
return
|
|
239208
|
+
return errors2 = { AbortError: Q4, HTTPParserError: Y4, UndiciError: A5, HeadersTimeoutError: c3, HeadersOverflowError: E6, BodyTimeoutError: t8, RequestContentLengthMismatchError: r6, ConnectTimeoutError: p6, ResponseStatusCodeError: B4, InvalidArgumentError: f6, InvalidReturnValueError: l3, RequestAbortedError: u6, ClientDestroyedError: a7, ClientClosedError: g6, InformationalError: n6, SocketError: d6, NotSupportedError: N6, ResponseContentLengthMismatchError: o8, BalancedPoolMissingUpstreamError: M5, ResponseExceededMaxSizeError: J4, RequestRetryError: V5, ResponseError: H4, SecureProxyConnectionError: h7 }, errors2;
|
|
239209
239209
|
}
|
|
239210
239210
|
e10(requireErrors, "requireErrors");
|
|
239211
239211
|
var constants$4;
|
|
@@ -248494,11 +248494,11 @@ ${g6}`;
|
|
|
248494
248494
|
return e10(u6, "plural"), ms;
|
|
248495
248495
|
}
|
|
248496
248496
|
e10(requireMs, "requireMs");
|
|
248497
|
-
var
|
|
248497
|
+
var common2;
|
|
248498
248498
|
var hasRequiredCommon;
|
|
248499
248499
|
function requireCommon() {
|
|
248500
248500
|
if (hasRequiredCommon)
|
|
248501
|
-
return
|
|
248501
|
+
return common2;
|
|
248502
248502
|
hasRequiredCommon = 1;
|
|
248503
248503
|
function A5(p6) {
|
|
248504
248504
|
E6.debug = E6, E6.default = E6, E6.coerce = u6, E6.disable = l3, E6.enable = B4, E6.enabled = Q4, E6.humanize = requireMs(), E6.destroy = n6, Object.keys(p6).forEach((r6) => {
|
|
@@ -248586,7 +248586,7 @@ ${g6}`;
|
|
|
248586
248586
|
}
|
|
248587
248587
|
return e10(n6, "destroy"), E6.enable(E6.load()), E6;
|
|
248588
248588
|
}
|
|
248589
|
-
return e10(A5, "setup"),
|
|
248589
|
+
return e10(A5, "setup"), common2 = A5, common2;
|
|
248590
248590
|
}
|
|
248591
248591
|
e10(requireCommon, "requireCommon");
|
|
248592
248592
|
var hasRequiredBrowser;
|
|
@@ -249178,11 +249178,11 @@ var require_visit = __commonJS((exports) => {
|
|
|
249178
249178
|
visit2.BREAK = BREAK;
|
|
249179
249179
|
visit2.SKIP = SKIP;
|
|
249180
249180
|
visit2.REMOVE = REMOVE;
|
|
249181
|
-
function visit_(
|
|
249182
|
-
const ctrl = callVisitor(
|
|
249181
|
+
function visit_(key2, node, visitor, path5) {
|
|
249182
|
+
const ctrl = callVisitor(key2, node, visitor, path5);
|
|
249183
249183
|
if (identity2.isNode(ctrl) || identity2.isPair(ctrl)) {
|
|
249184
|
-
replaceNode(
|
|
249185
|
-
return visit_(
|
|
249184
|
+
replaceNode(key2, path5, ctrl);
|
|
249185
|
+
return visit_(key2, ctrl, visitor, path5);
|
|
249186
249186
|
}
|
|
249187
249187
|
if (typeof ctrl !== "symbol") {
|
|
249188
249188
|
if (identity2.isCollection(node)) {
|
|
@@ -249226,11 +249226,11 @@ var require_visit = __commonJS((exports) => {
|
|
|
249226
249226
|
visitAsync.BREAK = BREAK;
|
|
249227
249227
|
visitAsync.SKIP = SKIP;
|
|
249228
249228
|
visitAsync.REMOVE = REMOVE;
|
|
249229
|
-
async function visitAsync_(
|
|
249230
|
-
const ctrl = await callVisitor(
|
|
249229
|
+
async function visitAsync_(key2, node, visitor, path5) {
|
|
249230
|
+
const ctrl = await callVisitor(key2, node, visitor, path5);
|
|
249231
249231
|
if (identity2.isNode(ctrl) || identity2.isPair(ctrl)) {
|
|
249232
|
-
replaceNode(
|
|
249233
|
-
return visitAsync_(
|
|
249232
|
+
replaceNode(key2, path5, ctrl);
|
|
249233
|
+
return visitAsync_(key2, ctrl, visitor, path5);
|
|
249234
249234
|
}
|
|
249235
249235
|
if (typeof ctrl !== "symbol") {
|
|
249236
249236
|
if (identity2.isCollection(node)) {
|
|
@@ -249280,27 +249280,27 @@ var require_visit = __commonJS((exports) => {
|
|
|
249280
249280
|
}
|
|
249281
249281
|
return visitor;
|
|
249282
249282
|
}
|
|
249283
|
-
function callVisitor(
|
|
249283
|
+
function callVisitor(key2, node, visitor, path5) {
|
|
249284
249284
|
if (typeof visitor === "function")
|
|
249285
|
-
return visitor(
|
|
249285
|
+
return visitor(key2, node, path5);
|
|
249286
249286
|
if (identity2.isMap(node))
|
|
249287
|
-
return visitor.Map?.(
|
|
249287
|
+
return visitor.Map?.(key2, node, path5);
|
|
249288
249288
|
if (identity2.isSeq(node))
|
|
249289
|
-
return visitor.Seq?.(
|
|
249289
|
+
return visitor.Seq?.(key2, node, path5);
|
|
249290
249290
|
if (identity2.isPair(node))
|
|
249291
|
-
return visitor.Pair?.(
|
|
249291
|
+
return visitor.Pair?.(key2, node, path5);
|
|
249292
249292
|
if (identity2.isScalar(node))
|
|
249293
|
-
return visitor.Scalar?.(
|
|
249293
|
+
return visitor.Scalar?.(key2, node, path5);
|
|
249294
249294
|
if (identity2.isAlias(node))
|
|
249295
|
-
return visitor.Alias?.(
|
|
249295
|
+
return visitor.Alias?.(key2, node, path5);
|
|
249296
249296
|
return;
|
|
249297
249297
|
}
|
|
249298
|
-
function replaceNode(
|
|
249298
|
+
function replaceNode(key2, path5, node) {
|
|
249299
249299
|
const parent = path5[path5.length - 1];
|
|
249300
249300
|
if (identity2.isCollection(parent)) {
|
|
249301
|
-
parent.items[
|
|
249301
|
+
parent.items[key2] = node;
|
|
249302
249302
|
} else if (identity2.isPair(parent)) {
|
|
249303
|
-
if (
|
|
249303
|
+
if (key2 === "key")
|
|
249304
249304
|
parent.key = node;
|
|
249305
249305
|
else
|
|
249306
249306
|
parent.value = node;
|
|
@@ -249532,7 +249532,7 @@ var require_anchors = __commonJS((exports) => {
|
|
|
249532
249532
|
|
|
249533
249533
|
// ../../node_modules/yaml/dist/doc/applyReviver.js
|
|
249534
249534
|
var require_applyReviver = __commonJS((exports) => {
|
|
249535
|
-
function applyReviver(reviver, obj,
|
|
249535
|
+
function applyReviver(reviver, obj, key2, val) {
|
|
249536
249536
|
if (val && typeof val === "object") {
|
|
249537
249537
|
if (Array.isArray(val)) {
|
|
249538
249538
|
for (let i6 = 0, len = val.length;i6 < len; ++i6) {
|
|
@@ -249572,7 +249572,7 @@ var require_applyReviver = __commonJS((exports) => {
|
|
|
249572
249572
|
}
|
|
249573
249573
|
}
|
|
249574
249574
|
}
|
|
249575
|
-
return reviver.call(obj,
|
|
249575
|
+
return reviver.call(obj, key2, val);
|
|
249576
249576
|
}
|
|
249577
249577
|
exports.applyReviver = applyReviver;
|
|
249578
249578
|
});
|
|
@@ -249890,29 +249890,29 @@ var require_Collection = __commonJS((exports) => {
|
|
|
249890
249890
|
if (isEmptyPath(path5))
|
|
249891
249891
|
this.add(value4);
|
|
249892
249892
|
else {
|
|
249893
|
-
const [
|
|
249894
|
-
const node = this.get(
|
|
249893
|
+
const [key2, ...rest] = path5;
|
|
249894
|
+
const node = this.get(key2, true);
|
|
249895
249895
|
if (identity2.isCollection(node))
|
|
249896
249896
|
node.addIn(rest, value4);
|
|
249897
249897
|
else if (node === undefined && this.schema)
|
|
249898
|
-
this.set(
|
|
249898
|
+
this.set(key2, collectionFromPath(this.schema, rest, value4));
|
|
249899
249899
|
else
|
|
249900
|
-
throw new Error(`Expected YAML collection at ${
|
|
249900
|
+
throw new Error(`Expected YAML collection at ${key2}. Remaining path: ${rest}`);
|
|
249901
249901
|
}
|
|
249902
249902
|
}
|
|
249903
249903
|
deleteIn(path5) {
|
|
249904
|
-
const [
|
|
249904
|
+
const [key2, ...rest] = path5;
|
|
249905
249905
|
if (rest.length === 0)
|
|
249906
|
-
return this.delete(
|
|
249907
|
-
const node = this.get(
|
|
249906
|
+
return this.delete(key2);
|
|
249907
|
+
const node = this.get(key2, true);
|
|
249908
249908
|
if (identity2.isCollection(node))
|
|
249909
249909
|
return node.deleteIn(rest);
|
|
249910
249910
|
else
|
|
249911
|
-
throw new Error(`Expected YAML collection at ${
|
|
249911
|
+
throw new Error(`Expected YAML collection at ${key2}. Remaining path: ${rest}`);
|
|
249912
249912
|
}
|
|
249913
249913
|
getIn(path5, keepScalar) {
|
|
249914
|
-
const [
|
|
249915
|
-
const node = this.get(
|
|
249914
|
+
const [key2, ...rest] = path5;
|
|
249915
|
+
const node = this.get(key2, true);
|
|
249916
249916
|
if (rest.length === 0)
|
|
249917
249917
|
return !keepScalar && identity2.isScalar(node) ? node.value : node;
|
|
249918
249918
|
else
|
|
@@ -249927,24 +249927,24 @@ var require_Collection = __commonJS((exports) => {
|
|
|
249927
249927
|
});
|
|
249928
249928
|
}
|
|
249929
249929
|
hasIn(path5) {
|
|
249930
|
-
const [
|
|
249930
|
+
const [key2, ...rest] = path5;
|
|
249931
249931
|
if (rest.length === 0)
|
|
249932
|
-
return this.has(
|
|
249933
|
-
const node = this.get(
|
|
249932
|
+
return this.has(key2);
|
|
249933
|
+
const node = this.get(key2, true);
|
|
249934
249934
|
return identity2.isCollection(node) ? node.hasIn(rest) : false;
|
|
249935
249935
|
}
|
|
249936
249936
|
setIn(path5, value4) {
|
|
249937
|
-
const [
|
|
249937
|
+
const [key2, ...rest] = path5;
|
|
249938
249938
|
if (rest.length === 0) {
|
|
249939
|
-
this.set(
|
|
249939
|
+
this.set(key2, value4);
|
|
249940
249940
|
} else {
|
|
249941
|
-
const node = this.get(
|
|
249941
|
+
const node = this.get(key2, true);
|
|
249942
249942
|
if (identity2.isCollection(node))
|
|
249943
249943
|
node.setIn(rest, value4);
|
|
249944
249944
|
else if (node === undefined && this.schema)
|
|
249945
|
-
this.set(
|
|
249945
|
+
this.set(key2, collectionFromPath(this.schema, rest, value4));
|
|
249946
249946
|
else
|
|
249947
|
-
throw new Error(`Expected YAML collection at ${
|
|
249947
|
+
throw new Error(`Expected YAML collection at ${key2}. Remaining path: ${rest}`);
|
|
249948
249948
|
}
|
|
249949
249949
|
}
|
|
249950
249950
|
}
|
|
@@ -250532,19 +250532,19 @@ var require_stringifyPair = __commonJS((exports) => {
|
|
|
250532
250532
|
var Scalar = require_Scalar();
|
|
250533
250533
|
var stringify3 = require_stringify();
|
|
250534
250534
|
var stringifyComment = require_stringifyComment();
|
|
250535
|
-
function stringifyPair2({ key:
|
|
250535
|
+
function stringifyPair2({ key: key2, value: value4 }, ctx, onComment, onChompKeep) {
|
|
250536
250536
|
const { allNullValues, doc, indent: indent2, indentStep, options: { commentString, indentSeq, simpleKeys } } = ctx;
|
|
250537
|
-
let keyComment = identity2.isNode(
|
|
250537
|
+
let keyComment = identity2.isNode(key2) && key2.comment || null;
|
|
250538
250538
|
if (simpleKeys) {
|
|
250539
250539
|
if (keyComment) {
|
|
250540
250540
|
throw new Error("With simple keys, key nodes cannot have comments");
|
|
250541
250541
|
}
|
|
250542
|
-
if (identity2.isCollection(
|
|
250542
|
+
if (identity2.isCollection(key2) || !identity2.isNode(key2) && typeof key2 === "object") {
|
|
250543
250543
|
const msg = "With simple keys, collection cannot be used as a key value";
|
|
250544
250544
|
throw new Error(msg);
|
|
250545
250545
|
}
|
|
250546
250546
|
}
|
|
250547
|
-
let explicitKey = !simpleKeys && (!
|
|
250547
|
+
let explicitKey = !simpleKeys && (!key2 || keyComment && value4 == null && !ctx.inFlow || identity2.isCollection(key2) || (identity2.isScalar(key2) ? key2.type === Scalar.Scalar.BLOCK_FOLDED || key2.type === Scalar.Scalar.BLOCK_LITERAL : typeof key2 === "object"));
|
|
250548
250548
|
ctx = Object.assign({}, ctx, {
|
|
250549
250549
|
allNullValues: false,
|
|
250550
250550
|
implicitKey: !explicitKey && (simpleKeys || !allNullValues),
|
|
@@ -250552,7 +250552,7 @@ var require_stringifyPair = __commonJS((exports) => {
|
|
|
250552
250552
|
});
|
|
250553
250553
|
let keyCommentDone = false;
|
|
250554
250554
|
let chompKeep = false;
|
|
250555
|
-
let str = stringify3.stringify(
|
|
250555
|
+
let str = stringify3.stringify(key2, ctx, () => keyCommentDone = true, () => chompKeep = true);
|
|
250556
250556
|
if (!explicitKey && !ctx.inFlow && str.length > 1024) {
|
|
250557
250557
|
if (simpleKeys)
|
|
250558
250558
|
throw new Error("With simple keys, single line scalar must not span more than 1024 characters");
|
|
@@ -250696,7 +250696,7 @@ var require_merge = __commonJS((exports) => {
|
|
|
250696
250696
|
}),
|
|
250697
250697
|
stringify: () => MERGE_KEY
|
|
250698
250698
|
};
|
|
250699
|
-
var isMergeKey = (ctx,
|
|
250699
|
+
var isMergeKey = (ctx, key2) => (merge3.identify(key2) || identity2.isScalar(key2) && (!key2.type || key2.type === Scalar.Scalar.PLAIN) && merge3.identify(key2.value)) && ctx?.doc.schema.tags.some((tag) => tag.tag === merge3.tag && tag.default);
|
|
250700
250700
|
function addMergeToJSMap(ctx, map3, value4) {
|
|
250701
250701
|
value4 = ctx && identity2.isAlias(value4) ? value4.resolve(ctx.doc) : value4;
|
|
250702
250702
|
if (identity2.isSeq(value4))
|
|
@@ -250713,14 +250713,14 @@ var require_merge = __commonJS((exports) => {
|
|
|
250713
250713
|
if (!identity2.isMap(source))
|
|
250714
250714
|
throw new Error("Merge sources must be maps or map aliases");
|
|
250715
250715
|
const srcMap = source.toJSON(null, ctx, Map);
|
|
250716
|
-
for (const [
|
|
250716
|
+
for (const [key2, value5] of srcMap) {
|
|
250717
250717
|
if (map3 instanceof Map) {
|
|
250718
|
-
if (!map3.has(
|
|
250719
|
-
map3.set(
|
|
250718
|
+
if (!map3.has(key2))
|
|
250719
|
+
map3.set(key2, value5);
|
|
250720
250720
|
} else if (map3 instanceof Set) {
|
|
250721
|
-
map3.add(
|
|
250722
|
-
} else if (!Object.prototype.hasOwnProperty.call(map3,
|
|
250723
|
-
Object.defineProperty(map3,
|
|
250721
|
+
map3.add(key2);
|
|
250722
|
+
} else if (!Object.prototype.hasOwnProperty.call(map3, key2)) {
|
|
250723
|
+
Object.defineProperty(map3, key2, {
|
|
250724
250724
|
value: value5,
|
|
250725
250725
|
writable: true,
|
|
250726
250726
|
enumerable: true,
|
|
@@ -250742,19 +250742,19 @@ var require_addPairToJSMap = __commonJS((exports) => {
|
|
|
250742
250742
|
var stringify3 = require_stringify();
|
|
250743
250743
|
var identity2 = require_identity();
|
|
250744
250744
|
var toJS = require_toJS();
|
|
250745
|
-
function addPairToJSMap(ctx, map3, { key:
|
|
250746
|
-
if (identity2.isNode(
|
|
250747
|
-
|
|
250748
|
-
else if (merge3.isMergeKey(ctx,
|
|
250745
|
+
function addPairToJSMap(ctx, map3, { key: key2, value: value4 }) {
|
|
250746
|
+
if (identity2.isNode(key2) && key2.addToJSMap)
|
|
250747
|
+
key2.addToJSMap(ctx, map3, value4);
|
|
250748
|
+
else if (merge3.isMergeKey(ctx, key2))
|
|
250749
250749
|
merge3.addMergeToJSMap(ctx, map3, value4);
|
|
250750
250750
|
else {
|
|
250751
|
-
const jsKey = toJS.toJS(
|
|
250751
|
+
const jsKey = toJS.toJS(key2, "", ctx);
|
|
250752
250752
|
if (map3 instanceof Map) {
|
|
250753
250753
|
map3.set(jsKey, toJS.toJS(value4, jsKey, ctx));
|
|
250754
250754
|
} else if (map3 instanceof Set) {
|
|
250755
250755
|
map3.add(jsKey);
|
|
250756
250756
|
} else {
|
|
250757
|
-
const stringKey = stringifyKey(
|
|
250757
|
+
const stringKey = stringifyKey(key2, jsKey, ctx);
|
|
250758
250758
|
const jsValue = toJS.toJS(value4, stringKey, ctx);
|
|
250759
250759
|
if (stringKey in map3)
|
|
250760
250760
|
Object.defineProperty(map3, stringKey, {
|
|
@@ -250769,19 +250769,19 @@ var require_addPairToJSMap = __commonJS((exports) => {
|
|
|
250769
250769
|
}
|
|
250770
250770
|
return map3;
|
|
250771
250771
|
}
|
|
250772
|
-
function stringifyKey(
|
|
250772
|
+
function stringifyKey(key2, jsKey, ctx) {
|
|
250773
250773
|
if (jsKey === null)
|
|
250774
250774
|
return "";
|
|
250775
250775
|
if (typeof jsKey !== "object")
|
|
250776
250776
|
return String(jsKey);
|
|
250777
|
-
if (identity2.isNode(
|
|
250777
|
+
if (identity2.isNode(key2) && ctx?.doc) {
|
|
250778
250778
|
const strCtx = stringify3.createStringifyContext(ctx.doc, {});
|
|
250779
250779
|
strCtx.anchors = new Set;
|
|
250780
250780
|
for (const node of ctx.anchors.keys())
|
|
250781
250781
|
strCtx.anchors.add(node.anchor);
|
|
250782
250782
|
strCtx.inFlow = true;
|
|
250783
250783
|
strCtx.inStringifyKey = true;
|
|
250784
|
-
const strKey =
|
|
250784
|
+
const strKey = key2.toString(strCtx);
|
|
250785
250785
|
if (!ctx.mapKeyWarned) {
|
|
250786
250786
|
let jsonStr = JSON.stringify(strKey);
|
|
250787
250787
|
if (jsonStr.length > 40)
|
|
@@ -250802,25 +250802,25 @@ var require_Pair = __commonJS((exports) => {
|
|
|
250802
250802
|
var stringifyPair2 = require_stringifyPair();
|
|
250803
250803
|
var addPairToJSMap = require_addPairToJSMap();
|
|
250804
250804
|
var identity2 = require_identity();
|
|
250805
|
-
function createPair(
|
|
250806
|
-
const k5 = createNode.createNode(
|
|
250805
|
+
function createPair(key2, value4, ctx) {
|
|
250806
|
+
const k5 = createNode.createNode(key2, undefined, ctx);
|
|
250807
250807
|
const v7 = createNode.createNode(value4, undefined, ctx);
|
|
250808
250808
|
return new Pair(k5, v7);
|
|
250809
250809
|
}
|
|
250810
250810
|
|
|
250811
250811
|
class Pair {
|
|
250812
|
-
constructor(
|
|
250812
|
+
constructor(key2, value4 = null) {
|
|
250813
250813
|
Object.defineProperty(this, identity2.NODE_TYPE, { value: identity2.PAIR });
|
|
250814
|
-
this.key =
|
|
250814
|
+
this.key = key2;
|
|
250815
250815
|
this.value = value4;
|
|
250816
250816
|
}
|
|
250817
250817
|
clone(schema) {
|
|
250818
|
-
let { key:
|
|
250819
|
-
if (identity2.isNode(
|
|
250820
|
-
|
|
250818
|
+
let { key: key2, value: value4 } = this;
|
|
250819
|
+
if (identity2.isNode(key2))
|
|
250820
|
+
key2 = key2.clone(schema);
|
|
250821
250821
|
if (identity2.isNode(value4))
|
|
250822
250822
|
value4 = value4.clone(schema);
|
|
250823
|
-
return new Pair(
|
|
250823
|
+
return new Pair(key2, value4);
|
|
250824
250824
|
}
|
|
250825
250825
|
toJSON(_5, ctx) {
|
|
250826
250826
|
const pair = ctx?.mapAsMap ? new Map : {};
|
|
@@ -250987,11 +250987,11 @@ var require_YAMLMap = __commonJS((exports) => {
|
|
|
250987
250987
|
var identity2 = require_identity();
|
|
250988
250988
|
var Pair = require_Pair();
|
|
250989
250989
|
var Scalar = require_Scalar();
|
|
250990
|
-
function findPair(items,
|
|
250991
|
-
const k5 = identity2.isScalar(
|
|
250990
|
+
function findPair(items, key2) {
|
|
250991
|
+
const k5 = identity2.isScalar(key2) ? key2.value : key2;
|
|
250992
250992
|
for (const it2 of items) {
|
|
250993
250993
|
if (identity2.isPair(it2)) {
|
|
250994
|
-
if (it2.key ===
|
|
250994
|
+
if (it2.key === key2 || it2.key === k5)
|
|
250995
250995
|
return it2;
|
|
250996
250996
|
if (identity2.isScalar(it2.key) && it2.key.value === k5)
|
|
250997
250997
|
return it2;
|
|
@@ -251011,20 +251011,20 @@ var require_YAMLMap = __commonJS((exports) => {
|
|
|
251011
251011
|
static from(schema, obj, ctx) {
|
|
251012
251012
|
const { keepUndefined, replacer } = ctx;
|
|
251013
251013
|
const map3 = new this(schema);
|
|
251014
|
-
const add = (
|
|
251014
|
+
const add = (key2, value4) => {
|
|
251015
251015
|
if (typeof replacer === "function")
|
|
251016
|
-
value4 = replacer.call(obj,
|
|
251017
|
-
else if (Array.isArray(replacer) && !replacer.includes(
|
|
251016
|
+
value4 = replacer.call(obj, key2, value4);
|
|
251017
|
+
else if (Array.isArray(replacer) && !replacer.includes(key2))
|
|
251018
251018
|
return;
|
|
251019
251019
|
if (value4 !== undefined || keepUndefined)
|
|
251020
|
-
map3.items.push(Pair.createPair(
|
|
251020
|
+
map3.items.push(Pair.createPair(key2, value4, ctx));
|
|
251021
251021
|
};
|
|
251022
251022
|
if (obj instanceof Map) {
|
|
251023
|
-
for (const [
|
|
251024
|
-
add(
|
|
251023
|
+
for (const [key2, value4] of obj)
|
|
251024
|
+
add(key2, value4);
|
|
251025
251025
|
} else if (obj && typeof obj === "object") {
|
|
251026
|
-
for (const
|
|
251027
|
-
add(
|
|
251026
|
+
for (const key2 of Object.keys(obj))
|
|
251027
|
+
add(key2, obj[key2]);
|
|
251028
251028
|
}
|
|
251029
251029
|
if (typeof schema.sortMapEntries === "function") {
|
|
251030
251030
|
map3.items.sort(schema.sortMapEntries);
|
|
@@ -251058,23 +251058,23 @@ var require_YAMLMap = __commonJS((exports) => {
|
|
|
251058
251058
|
this.items.push(_pair);
|
|
251059
251059
|
}
|
|
251060
251060
|
}
|
|
251061
|
-
delete(
|
|
251062
|
-
const it2 = findPair(this.items,
|
|
251061
|
+
delete(key2) {
|
|
251062
|
+
const it2 = findPair(this.items, key2);
|
|
251063
251063
|
if (!it2)
|
|
251064
251064
|
return false;
|
|
251065
251065
|
const del = this.items.splice(this.items.indexOf(it2), 1);
|
|
251066
251066
|
return del.length > 0;
|
|
251067
251067
|
}
|
|
251068
|
-
get(
|
|
251069
|
-
const it2 = findPair(this.items,
|
|
251068
|
+
get(key2, keepScalar) {
|
|
251069
|
+
const it2 = findPair(this.items, key2);
|
|
251070
251070
|
const node = it2?.value;
|
|
251071
251071
|
return (!keepScalar && identity2.isScalar(node) ? node.value : node) ?? undefined;
|
|
251072
251072
|
}
|
|
251073
|
-
has(
|
|
251074
|
-
return !!findPair(this.items,
|
|
251073
|
+
has(key2) {
|
|
251074
|
+
return !!findPair(this.items, key2);
|
|
251075
251075
|
}
|
|
251076
|
-
set(
|
|
251077
|
-
this.add(new Pair.Pair(
|
|
251076
|
+
set(key2, value4) {
|
|
251077
|
+
this.add(new Pair.Pair(key2, value4), true);
|
|
251078
251078
|
}
|
|
251079
251079
|
toJSON(_5, ctx, Type) {
|
|
251080
251080
|
const map3 = Type ? new Type : ctx?.mapAsMap ? new Map : {};
|
|
@@ -251145,28 +251145,28 @@ var require_YAMLSeq = __commonJS((exports) => {
|
|
|
251145
251145
|
add(value4) {
|
|
251146
251146
|
this.items.push(value4);
|
|
251147
251147
|
}
|
|
251148
|
-
delete(
|
|
251149
|
-
const idx = asItemIndex(
|
|
251148
|
+
delete(key2) {
|
|
251149
|
+
const idx = asItemIndex(key2);
|
|
251150
251150
|
if (typeof idx !== "number")
|
|
251151
251151
|
return false;
|
|
251152
251152
|
const del = this.items.splice(idx, 1);
|
|
251153
251153
|
return del.length > 0;
|
|
251154
251154
|
}
|
|
251155
|
-
get(
|
|
251156
|
-
const idx = asItemIndex(
|
|
251155
|
+
get(key2, keepScalar) {
|
|
251156
|
+
const idx = asItemIndex(key2);
|
|
251157
251157
|
if (typeof idx !== "number")
|
|
251158
251158
|
return;
|
|
251159
251159
|
const it2 = this.items[idx];
|
|
251160
251160
|
return !keepScalar && identity2.isScalar(it2) ? it2.value : it2;
|
|
251161
251161
|
}
|
|
251162
|
-
has(
|
|
251163
|
-
const idx = asItemIndex(
|
|
251162
|
+
has(key2) {
|
|
251163
|
+
const idx = asItemIndex(key2);
|
|
251164
251164
|
return typeof idx === "number" && idx < this.items.length;
|
|
251165
251165
|
}
|
|
251166
|
-
set(
|
|
251167
|
-
const idx = asItemIndex(
|
|
251166
|
+
set(key2, value4) {
|
|
251167
|
+
const idx = asItemIndex(key2);
|
|
251168
251168
|
if (typeof idx !== "number")
|
|
251169
|
-
throw new Error(`Expected a valid index, not ${
|
|
251169
|
+
throw new Error(`Expected a valid index, not ${key2}.`);
|
|
251170
251170
|
const prev = this.items[idx];
|
|
251171
251171
|
if (identity2.isScalar(prev) && Scalar.isScalarValue(value4))
|
|
251172
251172
|
prev.value = value4;
|
|
@@ -251200,8 +251200,8 @@ var require_YAMLSeq = __commonJS((exports) => {
|
|
|
251200
251200
|
let i6 = 0;
|
|
251201
251201
|
for (let it2 of obj) {
|
|
251202
251202
|
if (typeof replacer === "function") {
|
|
251203
|
-
const
|
|
251204
|
-
it2 = replacer.call(obj,
|
|
251203
|
+
const key2 = obj instanceof Set ? it2 : String(i6++);
|
|
251204
|
+
it2 = replacer.call(obj, key2, it2);
|
|
251205
251205
|
}
|
|
251206
251206
|
seq.items.push(createNode.createNode(it2, undefined, ctx));
|
|
251207
251207
|
}
|
|
@@ -251209,8 +251209,8 @@ var require_YAMLSeq = __commonJS((exports) => {
|
|
|
251209
251209
|
return seq;
|
|
251210
251210
|
}
|
|
251211
251211
|
}
|
|
251212
|
-
function asItemIndex(
|
|
251213
|
-
let idx = identity2.isScalar(
|
|
251212
|
+
function asItemIndex(key2) {
|
|
251213
|
+
let idx = identity2.isScalar(key2) ? key2.value : key2;
|
|
251214
251214
|
if (idx && typeof idx === "string")
|
|
251215
251215
|
idx = Number(idx);
|
|
251216
251216
|
return typeof idx === "number" && Number.isInteger(idx) && idx >= 0 ? idx : null;
|
|
@@ -251582,25 +251582,25 @@ ${cn.comment}` : item.comment;
|
|
|
251582
251582
|
for (let it2 of iterable) {
|
|
251583
251583
|
if (typeof replacer === "function")
|
|
251584
251584
|
it2 = replacer.call(iterable, String(i6++), it2);
|
|
251585
|
-
let
|
|
251585
|
+
let key2, value4;
|
|
251586
251586
|
if (Array.isArray(it2)) {
|
|
251587
251587
|
if (it2.length === 2) {
|
|
251588
|
-
|
|
251588
|
+
key2 = it2[0];
|
|
251589
251589
|
value4 = it2[1];
|
|
251590
251590
|
} else
|
|
251591
251591
|
throw new TypeError(`Expected [key, value] tuple: ${it2}`);
|
|
251592
251592
|
} else if (it2 && it2 instanceof Object) {
|
|
251593
251593
|
const keys = Object.keys(it2);
|
|
251594
251594
|
if (keys.length === 1) {
|
|
251595
|
-
|
|
251596
|
-
value4 = it2[
|
|
251595
|
+
key2 = keys[0];
|
|
251596
|
+
value4 = it2[key2];
|
|
251597
251597
|
} else {
|
|
251598
251598
|
throw new TypeError(`Expected tuple with one key, not ${keys.length} keys`);
|
|
251599
251599
|
}
|
|
251600
251600
|
} else {
|
|
251601
|
-
|
|
251601
|
+
key2 = it2;
|
|
251602
251602
|
}
|
|
251603
|
-
pairs2.items.push(Pair.createPair(
|
|
251603
|
+
pairs2.items.push(Pair.createPair(key2, value4, ctx));
|
|
251604
251604
|
}
|
|
251605
251605
|
return pairs2;
|
|
251606
251606
|
}
|
|
@@ -251641,16 +251641,16 @@ var require_omap = __commonJS((exports) => {
|
|
|
251641
251641
|
if (ctx?.onCreate)
|
|
251642
251642
|
ctx.onCreate(map3);
|
|
251643
251643
|
for (const pair of this.items) {
|
|
251644
|
-
let
|
|
251644
|
+
let key2, value4;
|
|
251645
251645
|
if (identity2.isPair(pair)) {
|
|
251646
|
-
|
|
251647
|
-
value4 = toJS.toJS(pair.value,
|
|
251646
|
+
key2 = toJS.toJS(pair.key, "", ctx);
|
|
251647
|
+
value4 = toJS.toJS(pair.value, key2, ctx);
|
|
251648
251648
|
} else {
|
|
251649
|
-
|
|
251649
|
+
key2 = toJS.toJS(pair, "", ctx);
|
|
251650
251650
|
}
|
|
251651
|
-
if (map3.has(
|
|
251651
|
+
if (map3.has(key2))
|
|
251652
251652
|
throw new Error("Ordered maps must not include duplicate keys");
|
|
251653
|
-
map3.set(
|
|
251653
|
+
map3.set(key2, value4);
|
|
251654
251654
|
}
|
|
251655
251655
|
return map3;
|
|
251656
251656
|
}
|
|
@@ -251671,12 +251671,12 @@ var require_omap = __commonJS((exports) => {
|
|
|
251671
251671
|
resolve(seq, onError) {
|
|
251672
251672
|
const pairs$1 = pairs.resolvePairs(seq, onError);
|
|
251673
251673
|
const seenKeys = [];
|
|
251674
|
-
for (const { key:
|
|
251675
|
-
if (identity2.isScalar(
|
|
251676
|
-
if (seenKeys.includes(
|
|
251677
|
-
onError(`Ordered maps must not include duplicate keys: ${
|
|
251674
|
+
for (const { key: key2 } of pairs$1.items) {
|
|
251675
|
+
if (identity2.isScalar(key2)) {
|
|
251676
|
+
if (seenKeys.includes(key2.value)) {
|
|
251677
|
+
onError(`Ordered maps must not include duplicate keys: ${key2.value}`);
|
|
251678
251678
|
} else {
|
|
251679
|
-
seenKeys.push(
|
|
251679
|
+
seenKeys.push(key2.value);
|
|
251680
251680
|
}
|
|
251681
251681
|
}
|
|
251682
251682
|
}
|
|
@@ -251850,30 +251850,30 @@ var require_set = __commonJS((exports) => {
|
|
|
251850
251850
|
super(schema);
|
|
251851
251851
|
this.tag = YAMLSet.tag;
|
|
251852
251852
|
}
|
|
251853
|
-
add(
|
|
251853
|
+
add(key2) {
|
|
251854
251854
|
let pair;
|
|
251855
|
-
if (identity2.isPair(
|
|
251856
|
-
pair =
|
|
251857
|
-
else if (
|
|
251858
|
-
pair = new Pair.Pair(
|
|
251855
|
+
if (identity2.isPair(key2))
|
|
251856
|
+
pair = key2;
|
|
251857
|
+
else if (key2 && typeof key2 === "object" && "key" in key2 && "value" in key2 && key2.value === null)
|
|
251858
|
+
pair = new Pair.Pair(key2.key, null);
|
|
251859
251859
|
else
|
|
251860
|
-
pair = new Pair.Pair(
|
|
251860
|
+
pair = new Pair.Pair(key2, null);
|
|
251861
251861
|
const prev = YAMLMap.findPair(this.items, pair.key);
|
|
251862
251862
|
if (!prev)
|
|
251863
251863
|
this.items.push(pair);
|
|
251864
251864
|
}
|
|
251865
|
-
get(
|
|
251866
|
-
const pair = YAMLMap.findPair(this.items,
|
|
251865
|
+
get(key2, keepPair) {
|
|
251866
|
+
const pair = YAMLMap.findPair(this.items, key2);
|
|
251867
251867
|
return !keepPair && identity2.isPair(pair) ? identity2.isScalar(pair.key) ? pair.key.value : pair.key : pair;
|
|
251868
251868
|
}
|
|
251869
|
-
set(
|
|
251869
|
+
set(key2, value4) {
|
|
251870
251870
|
if (typeof value4 !== "boolean")
|
|
251871
251871
|
throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof value4}`);
|
|
251872
|
-
const prev = YAMLMap.findPair(this.items,
|
|
251872
|
+
const prev = YAMLMap.findPair(this.items, key2);
|
|
251873
251873
|
if (prev && !value4) {
|
|
251874
251874
|
this.items.splice(this.items.indexOf(prev), 1);
|
|
251875
251875
|
} else if (!prev && value4) {
|
|
251876
|
-
this.items.push(new Pair.Pair(
|
|
251876
|
+
this.items.push(new Pair.Pair(key2));
|
|
251877
251877
|
}
|
|
251878
251878
|
}
|
|
251879
251879
|
toJSON(_5, ctx) {
|
|
@@ -252108,7 +252108,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
252108
252108
|
if (Array.isArray(customTags))
|
|
252109
252109
|
tags = [];
|
|
252110
252110
|
else {
|
|
252111
|
-
const keys = Array.from(schemas.keys()).filter((
|
|
252111
|
+
const keys = Array.from(schemas.keys()).filter((key2) => key2 !== "yaml11").map((key2) => JSON.stringify(key2)).join(", ");
|
|
252112
252112
|
throw new Error(`Unknown schema "${schemaName}"; use one of ${keys} or define customTags array`);
|
|
252113
252113
|
}
|
|
252114
252114
|
}
|
|
@@ -252124,7 +252124,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
252124
252124
|
const tagObj = typeof tag === "string" ? tagsByName[tag] : tag;
|
|
252125
252125
|
if (!tagObj) {
|
|
252126
252126
|
const tagName = JSON.stringify(tag);
|
|
252127
|
-
const keys = Object.keys(tagsByName).map((
|
|
252127
|
+
const keys = Object.keys(tagsByName).map((key2) => JSON.stringify(key2)).join(", ");
|
|
252128
252128
|
throw new Error(`Unknown custom tag ${tagName}; use one of ${keys}`);
|
|
252129
252129
|
}
|
|
252130
252130
|
if (!tags2.includes(tagObj))
|
|
@@ -252359,13 +252359,13 @@ var require_Document = __commonJS((exports) => {
|
|
|
252359
252359
|
setAnchors();
|
|
252360
252360
|
return node;
|
|
252361
252361
|
}
|
|
252362
|
-
createPair(
|
|
252363
|
-
const k5 = this.createNode(
|
|
252362
|
+
createPair(key2, value4, options = {}) {
|
|
252363
|
+
const k5 = this.createNode(key2, null, options);
|
|
252364
252364
|
const v7 = this.createNode(value4, null, options);
|
|
252365
252365
|
return new Pair.Pair(k5, v7);
|
|
252366
252366
|
}
|
|
252367
|
-
delete(
|
|
252368
|
-
return assertCollection(this.contents) ? this.contents.delete(
|
|
252367
|
+
delete(key2) {
|
|
252368
|
+
return assertCollection(this.contents) ? this.contents.delete(key2) : false;
|
|
252369
252369
|
}
|
|
252370
252370
|
deleteIn(path5) {
|
|
252371
252371
|
if (Collection.isEmptyPath(path5)) {
|
|
@@ -252376,27 +252376,27 @@ var require_Document = __commonJS((exports) => {
|
|
|
252376
252376
|
}
|
|
252377
252377
|
return assertCollection(this.contents) ? this.contents.deleteIn(path5) : false;
|
|
252378
252378
|
}
|
|
252379
|
-
get(
|
|
252380
|
-
return identity2.isCollection(this.contents) ? this.contents.get(
|
|
252379
|
+
get(key2, keepScalar) {
|
|
252380
|
+
return identity2.isCollection(this.contents) ? this.contents.get(key2, keepScalar) : undefined;
|
|
252381
252381
|
}
|
|
252382
252382
|
getIn(path5, keepScalar) {
|
|
252383
252383
|
if (Collection.isEmptyPath(path5))
|
|
252384
252384
|
return !keepScalar && identity2.isScalar(this.contents) ? this.contents.value : this.contents;
|
|
252385
252385
|
return identity2.isCollection(this.contents) ? this.contents.getIn(path5, keepScalar) : undefined;
|
|
252386
252386
|
}
|
|
252387
|
-
has(
|
|
252388
|
-
return identity2.isCollection(this.contents) ? this.contents.has(
|
|
252387
|
+
has(key2) {
|
|
252388
|
+
return identity2.isCollection(this.contents) ? this.contents.has(key2) : false;
|
|
252389
252389
|
}
|
|
252390
252390
|
hasIn(path5) {
|
|
252391
252391
|
if (Collection.isEmptyPath(path5))
|
|
252392
252392
|
return this.contents !== undefined;
|
|
252393
252393
|
return identity2.isCollection(this.contents) ? this.contents.hasIn(path5) : false;
|
|
252394
252394
|
}
|
|
252395
|
-
set(
|
|
252395
|
+
set(key2, value4) {
|
|
252396
252396
|
if (this.contents == null) {
|
|
252397
|
-
this.contents = Collection.collectionFromPath(this.schema, [
|
|
252397
|
+
this.contents = Collection.collectionFromPath(this.schema, [key2], value4);
|
|
252398
252398
|
} else if (assertCollection(this.contents)) {
|
|
252399
|
-
this.contents.set(
|
|
252399
|
+
this.contents.set(key2, value4);
|
|
252400
252400
|
}
|
|
252401
252401
|
}
|
|
252402
252402
|
setIn(path5, value4) {
|
|
@@ -252680,25 +252680,25 @@ var require_resolve_props = __commonJS((exports) => {
|
|
|
252680
252680
|
|
|
252681
252681
|
// ../../node_modules/yaml/dist/compose/util-contains-newline.js
|
|
252682
252682
|
var require_util_contains_newline = __commonJS((exports) => {
|
|
252683
|
-
function containsNewline(
|
|
252684
|
-
if (!
|
|
252683
|
+
function containsNewline(key2) {
|
|
252684
|
+
if (!key2)
|
|
252685
252685
|
return null;
|
|
252686
|
-
switch (
|
|
252686
|
+
switch (key2.type) {
|
|
252687
252687
|
case "alias":
|
|
252688
252688
|
case "scalar":
|
|
252689
252689
|
case "double-quoted-scalar":
|
|
252690
252690
|
case "single-quoted-scalar":
|
|
252691
|
-
if (
|
|
252691
|
+
if (key2.source.includes(`
|
|
252692
252692
|
`))
|
|
252693
252693
|
return true;
|
|
252694
|
-
if (
|
|
252695
|
-
for (const st2 of
|
|
252694
|
+
if (key2.end) {
|
|
252695
|
+
for (const st2 of key2.end)
|
|
252696
252696
|
if (st2.type === "newline")
|
|
252697
252697
|
return true;
|
|
252698
252698
|
}
|
|
252699
252699
|
return false;
|
|
252700
252700
|
case "flow-collection":
|
|
252701
|
-
for (const it2 of
|
|
252701
|
+
for (const it2 of key2.items) {
|
|
252702
252702
|
for (const st2 of it2.start)
|
|
252703
252703
|
if (st2.type === "newline")
|
|
252704
252704
|
return true;
|
|
@@ -252763,10 +252763,10 @@ var require_resolve_block_map = __commonJS((exports) => {
|
|
|
252763
252763
|
let offset = bm.offset;
|
|
252764
252764
|
let commentEnd = null;
|
|
252765
252765
|
for (const collItem of bm.items) {
|
|
252766
|
-
const { start: start3, key:
|
|
252766
|
+
const { start: start3, key: key2, sep: sep3, value: value4 } = collItem;
|
|
252767
252767
|
const keyProps = resolveProps.resolveProps(start3, {
|
|
252768
252768
|
indicator: "explicit-key-ind",
|
|
252769
|
-
next:
|
|
252769
|
+
next: key2 ?? sep3?.[0],
|
|
252770
252770
|
offset,
|
|
252771
252771
|
onError,
|
|
252772
252772
|
parentIndent: bm.indent,
|
|
@@ -252774,10 +252774,10 @@ var require_resolve_block_map = __commonJS((exports) => {
|
|
|
252774
252774
|
});
|
|
252775
252775
|
const implicitKey = !keyProps.found;
|
|
252776
252776
|
if (implicitKey) {
|
|
252777
|
-
if (
|
|
252778
|
-
if (
|
|
252777
|
+
if (key2) {
|
|
252778
|
+
if (key2.type === "block-seq")
|
|
252779
252779
|
onError(offset, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key");
|
|
252780
|
-
else if ("indent" in
|
|
252780
|
+
else if ("indent" in key2 && key2.indent !== bm.indent)
|
|
252781
252781
|
onError(offset, "BAD_INDENT", startColMsg);
|
|
252782
252782
|
}
|
|
252783
252783
|
if (!keyProps.anchor && !keyProps.tag && !sep3) {
|
|
@@ -252791,17 +252791,17 @@ var require_resolve_block_map = __commonJS((exports) => {
|
|
|
252791
252791
|
}
|
|
252792
252792
|
continue;
|
|
252793
252793
|
}
|
|
252794
|
-
if (keyProps.newlineAfterProp || utilContainsNewline.containsNewline(
|
|
252795
|
-
onError(
|
|
252794
|
+
if (keyProps.newlineAfterProp || utilContainsNewline.containsNewline(key2)) {
|
|
252795
|
+
onError(key2 ?? start3[start3.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line");
|
|
252796
252796
|
}
|
|
252797
252797
|
} else if (keyProps.found?.indent !== bm.indent) {
|
|
252798
252798
|
onError(offset, "BAD_INDENT", startColMsg);
|
|
252799
252799
|
}
|
|
252800
252800
|
ctx.atKey = true;
|
|
252801
252801
|
const keyStart = keyProps.end;
|
|
252802
|
-
const keyNode =
|
|
252802
|
+
const keyNode = key2 ? composeNode(ctx, key2, keyProps, onError) : composeEmptyNode(ctx, keyStart, start3, null, keyProps, onError);
|
|
252803
252803
|
if (ctx.schema.compat)
|
|
252804
|
-
utilFlowIndentCheck.flowIndentCheck(bm.indent,
|
|
252804
|
+
utilFlowIndentCheck.flowIndentCheck(bm.indent, key2, onError);
|
|
252805
252805
|
ctx.atKey = false;
|
|
252806
252806
|
if (utilMapIncludes.mapIncludes(ctx, map3.items, keyNode))
|
|
252807
252807
|
onError(keyStart, "DUPLICATE_KEY", "Map keys must be unique");
|
|
@@ -252811,7 +252811,7 @@ var require_resolve_block_map = __commonJS((exports) => {
|
|
|
252811
252811
|
offset: keyNode.range[2],
|
|
252812
252812
|
onError,
|
|
252813
252813
|
parentIndent: bm.indent,
|
|
252814
|
-
startOnNewline: !
|
|
252814
|
+
startOnNewline: !key2 || key2.type === "block-scalar"
|
|
252815
252815
|
});
|
|
252816
252816
|
offset = valueProps.end;
|
|
252817
252817
|
if (valueProps.found) {
|
|
@@ -252967,11 +252967,11 @@ var require_resolve_flow_collection = __commonJS((exports) => {
|
|
|
252967
252967
|
let offset = fc.offset + fc.start.source.length;
|
|
252968
252968
|
for (let i6 = 0;i6 < fc.items.length; ++i6) {
|
|
252969
252969
|
const collItem = fc.items[i6];
|
|
252970
|
-
const { start: start3, key:
|
|
252970
|
+
const { start: start3, key: key2, sep: sep3, value: value4 } = collItem;
|
|
252971
252971
|
const props = resolveProps.resolveProps(start3, {
|
|
252972
252972
|
flow: fcName,
|
|
252973
252973
|
indicator: "explicit-key-ind",
|
|
252974
|
-
next:
|
|
252974
|
+
next: key2 ?? sep3?.[0],
|
|
252975
252975
|
offset,
|
|
252976
252976
|
onError,
|
|
252977
252977
|
parentIndent: fc.indent,
|
|
@@ -252993,8 +252993,8 @@ var require_resolve_flow_collection = __commonJS((exports) => {
|
|
|
252993
252993
|
offset = props.end;
|
|
252994
252994
|
continue;
|
|
252995
252995
|
}
|
|
252996
|
-
if (!isMap && ctx.options.strict && utilContainsNewline.containsNewline(
|
|
252997
|
-
onError(
|
|
252996
|
+
if (!isMap && ctx.options.strict && utilContainsNewline.containsNewline(key2))
|
|
252997
|
+
onError(key2, "MULTILINE_IMPLICIT_KEY", "Implicit keys of flow sequence pairs need to be on a single line");
|
|
252998
252998
|
}
|
|
252999
252999
|
if (i6 === 0) {
|
|
253000
253000
|
if (props.comma)
|
|
@@ -253039,8 +253039,8 @@ var require_resolve_flow_collection = __commonJS((exports) => {
|
|
|
253039
253039
|
} else {
|
|
253040
253040
|
ctx.atKey = true;
|
|
253041
253041
|
const keyStart = props.end;
|
|
253042
|
-
const keyNode =
|
|
253043
|
-
if (isBlock(
|
|
253042
|
+
const keyNode = key2 ? composeNode(ctx, key2, props, onError) : composeEmptyNode(ctx, keyStart, start3, null, props, onError);
|
|
253043
|
+
if (isBlock(key2))
|
|
253044
253044
|
onError(keyNode.range, "BLOCK_IN_FLOW", blockMsg);
|
|
253045
253045
|
ctx.atKey = false;
|
|
253046
253046
|
const valueProps = resolveProps.resolveProps(sep3 ?? [], {
|
|
@@ -253852,7 +253852,7 @@ var require_composer = __commonJS((exports) => {
|
|
|
253852
253852
|
var node_process = __require("node:process");
|
|
253853
253853
|
var directives4 = require_directives2();
|
|
253854
253854
|
var Document = require_Document();
|
|
253855
|
-
var
|
|
253855
|
+
var errors2 = require_errors3();
|
|
253856
253856
|
var identity2 = require_identity();
|
|
253857
253857
|
var composeDoc = require_compose_doc();
|
|
253858
253858
|
var resolveEnd = require_resolve_end();
|
|
@@ -253903,9 +253903,9 @@ var require_composer = __commonJS((exports) => {
|
|
|
253903
253903
|
this.onError = (source, code2, message, warning) => {
|
|
253904
253904
|
const pos = getErrorPos(source);
|
|
253905
253905
|
if (warning)
|
|
253906
|
-
this.warnings.push(new
|
|
253906
|
+
this.warnings.push(new errors2.YAMLWarning(pos, code2, message));
|
|
253907
253907
|
else
|
|
253908
|
-
this.errors.push(new
|
|
253908
|
+
this.errors.push(new errors2.YAMLParseError(pos, code2, message));
|
|
253909
253909
|
};
|
|
253910
253910
|
this.directives = new directives4.Directives({ version: options.version || "1.2" });
|
|
253911
253911
|
this.options = options;
|
|
@@ -253989,7 +253989,7 @@ ${cb}` : comment;
|
|
|
253989
253989
|
break;
|
|
253990
253990
|
case "error": {
|
|
253991
253991
|
const msg = token.source ? `${token.message}: ${JSON.stringify(token.source)}` : token.message;
|
|
253992
|
-
const error5 = new
|
|
253992
|
+
const error5 = new errors2.YAMLParseError(getErrorPos(token), "UNEXPECTED_TOKEN", msg);
|
|
253993
253993
|
if (this.atDirectives || !this.doc)
|
|
253994
253994
|
this.errors.push(error5);
|
|
253995
253995
|
else
|
|
@@ -253999,7 +253999,7 @@ ${cb}` : comment;
|
|
|
253999
253999
|
case "doc-end": {
|
|
254000
254000
|
if (!this.doc) {
|
|
254001
254001
|
const msg = "Unexpected doc-end without preceding document";
|
|
254002
|
-
this.errors.push(new
|
|
254002
|
+
this.errors.push(new errors2.YAMLParseError(getErrorPos(token), "UNEXPECTED_TOKEN", msg));
|
|
254003
254003
|
break;
|
|
254004
254004
|
}
|
|
254005
254005
|
this.doc.directives.docEnd = true;
|
|
@@ -254014,7 +254014,7 @@ ${end.comment}` : end.comment;
|
|
|
254014
254014
|
break;
|
|
254015
254015
|
}
|
|
254016
254016
|
default:
|
|
254017
|
-
this.errors.push(new
|
|
254017
|
+
this.errors.push(new errors2.YAMLParseError(getErrorPos(token), "UNEXPECTED_TOKEN", `Unsupported token ${token.type}`));
|
|
254018
254018
|
}
|
|
254019
254019
|
}
|
|
254020
254020
|
*end(forceDoc = false, endOffset = -1) {
|
|
@@ -254040,7 +254040,7 @@ ${end.comment}` : end.comment;
|
|
|
254040
254040
|
var require_cst_scalar = __commonJS((exports) => {
|
|
254041
254041
|
var resolveBlockScalar = require_resolve_block_scalar();
|
|
254042
254042
|
var resolveFlowScalar = require_resolve_flow_scalar();
|
|
254043
|
-
var
|
|
254043
|
+
var errors2 = require_errors3();
|
|
254044
254044
|
var stringifyString = require_stringifyString();
|
|
254045
254045
|
function resolveAsScalar(token, strict = true, onError) {
|
|
254046
254046
|
if (token) {
|
|
@@ -254049,7 +254049,7 @@ var require_cst_scalar = __commonJS((exports) => {
|
|
|
254049
254049
|
if (onError)
|
|
254050
254050
|
onError(offset, code2, message);
|
|
254051
254051
|
else
|
|
254052
|
-
throw new
|
|
254052
|
+
throw new errors2.YAMLParseError([offset, offset + 1], code2, message);
|
|
254053
254053
|
};
|
|
254054
254054
|
switch (token.type) {
|
|
254055
254055
|
case "scalar":
|
|
@@ -254163,9 +254163,9 @@ var require_cst_scalar = __commonJS((exports) => {
|
|
|
254163
254163
|
if (!addEndtoBlockProps(props, "end" in token ? token.end : undefined))
|
|
254164
254164
|
props.push({ type: "newline", offset: -1, indent: indent2, source: `
|
|
254165
254165
|
` });
|
|
254166
|
-
for (const
|
|
254167
|
-
if (
|
|
254168
|
-
delete token[
|
|
254166
|
+
for (const key2 of Object.keys(token))
|
|
254167
|
+
if (key2 !== "type" && key2 !== "offset")
|
|
254168
|
+
delete token[key2];
|
|
254169
254169
|
Object.assign(token, { type: "block-scalar", indent: indent2, props, source: body });
|
|
254170
254170
|
}
|
|
254171
254171
|
}
|
|
@@ -254214,9 +254214,9 @@ var require_cst_scalar = __commonJS((exports) => {
|
|
|
254214
254214
|
default: {
|
|
254215
254215
|
const indent2 = "indent" in token ? token.indent : -1;
|
|
254216
254216
|
const end = "end" in token && Array.isArray(token.end) ? token.end.filter((st2) => st2.type === "space" || st2.type === "comment" || st2.type === "newline") : [];
|
|
254217
|
-
for (const
|
|
254218
|
-
if (
|
|
254219
|
-
delete token[
|
|
254217
|
+
for (const key2 of Object.keys(token))
|
|
254218
|
+
if (key2 !== "type" && key2 !== "offset")
|
|
254219
|
+
delete token[key2];
|
|
254220
254220
|
Object.assign(token, { type: type4, indent: indent2, source, end });
|
|
254221
254221
|
}
|
|
254222
254222
|
}
|
|
@@ -254268,12 +254268,12 @@ var require_cst_stringify = __commonJS((exports) => {
|
|
|
254268
254268
|
}
|
|
254269
254269
|
}
|
|
254270
254270
|
}
|
|
254271
|
-
function stringifyItem({ start: start3, key:
|
|
254271
|
+
function stringifyItem({ start: start3, key: key2, sep: sep3, value: value4 }) {
|
|
254272
254272
|
let res = "";
|
|
254273
254273
|
for (const st2 of start3)
|
|
254274
254274
|
res += st2.source;
|
|
254275
|
-
if (
|
|
254276
|
-
res += stringifyToken(
|
|
254275
|
+
if (key2)
|
|
254276
|
+
res += stringifyToken(key2);
|
|
254277
254277
|
if (sep3)
|
|
254278
254278
|
for (const st2 of sep3)
|
|
254279
254279
|
res += st2.source;
|
|
@@ -255570,7 +255570,7 @@ var require_parser2 = __commonJS((exports) => {
|
|
|
255570
255570
|
});
|
|
255571
255571
|
} else if (isFlowToken(it2.key) && !includesToken(it2.sep, "newline")) {
|
|
255572
255572
|
const start4 = getFirstKeyStartProps(it2.start);
|
|
255573
|
-
const
|
|
255573
|
+
const key2 = it2.key;
|
|
255574
255574
|
const sep3 = it2.sep;
|
|
255575
255575
|
sep3.push(this.sourceToken);
|
|
255576
255576
|
delete it2.key;
|
|
@@ -255579,7 +255579,7 @@ var require_parser2 = __commonJS((exports) => {
|
|
|
255579
255579
|
type: "block-map",
|
|
255580
255580
|
offset: this.offset,
|
|
255581
255581
|
indent: this.indent,
|
|
255582
|
-
items: [{ start: start4, key:
|
|
255582
|
+
items: [{ start: start4, key: key2, sep: sep3 }]
|
|
255583
255583
|
});
|
|
255584
255584
|
} else if (start3.length > 0) {
|
|
255585
255585
|
it2.sep = it2.sep.concat(start3, this.sourceToken);
|
|
@@ -255902,7 +255902,7 @@ var require_parser2 = __commonJS((exports) => {
|
|
|
255902
255902
|
var require_public_api = __commonJS((exports) => {
|
|
255903
255903
|
var composer = require_composer();
|
|
255904
255904
|
var Document = require_Document();
|
|
255905
|
-
var
|
|
255905
|
+
var errors2 = require_errors3();
|
|
255906
255906
|
var log = require_log();
|
|
255907
255907
|
var identity2 = require_identity();
|
|
255908
255908
|
var lineCounter = require_line_counter();
|
|
@@ -255919,8 +255919,8 @@ var require_public_api = __commonJS((exports) => {
|
|
|
255919
255919
|
const docs = Array.from(composer$1.compose(parser$1.parse(source)));
|
|
255920
255920
|
if (prettyErrors && lineCounter2)
|
|
255921
255921
|
for (const doc of docs) {
|
|
255922
|
-
doc.errors.forEach(
|
|
255923
|
-
doc.warnings.forEach(
|
|
255922
|
+
doc.errors.forEach(errors2.prettifyError(source, lineCounter2));
|
|
255923
|
+
doc.warnings.forEach(errors2.prettifyError(source, lineCounter2));
|
|
255924
255924
|
}
|
|
255925
255925
|
if (docs.length > 0)
|
|
255926
255926
|
return docs;
|
|
@@ -255935,13 +255935,13 @@ var require_public_api = __commonJS((exports) => {
|
|
|
255935
255935
|
if (!doc)
|
|
255936
255936
|
doc = _doc;
|
|
255937
255937
|
else if (doc.options.logLevel !== "silent") {
|
|
255938
|
-
doc.errors.push(new
|
|
255938
|
+
doc.errors.push(new errors2.YAMLParseError(_doc.range.slice(0, 2), "MULTIPLE_DOCS", "Source contains multiple documents; please use YAML.parseAllDocuments()"));
|
|
255939
255939
|
break;
|
|
255940
255940
|
}
|
|
255941
255941
|
}
|
|
255942
255942
|
if (prettyErrors && lineCounter2) {
|
|
255943
|
-
doc.errors.forEach(
|
|
255944
|
-
doc.warnings.forEach(
|
|
255943
|
+
doc.errors.forEach(errors2.prettifyError(source, lineCounter2));
|
|
255944
|
+
doc.warnings.forEach(errors2.prettifyError(source, lineCounter2));
|
|
255945
255945
|
}
|
|
255946
255946
|
return doc;
|
|
255947
255947
|
}
|
|
@@ -267029,7 +267029,7 @@ function pruneCurrentEnv(currentEnv, env2) {
|
|
|
267029
267029
|
var package_default = {
|
|
267030
267030
|
name: "@settlemint/sdk-cli",
|
|
267031
267031
|
description: "Command-line interface for SettleMint SDK, providing development tools and project management capabilities",
|
|
267032
|
-
version: "1.1.1-
|
|
267032
|
+
version: "1.1.1-prc7f21dc7",
|
|
267033
267033
|
type: "module",
|
|
267034
267034
|
private: false,
|
|
267035
267035
|
license: "FSL-1.1-MIT",
|
|
@@ -267074,11 +267074,11 @@ var package_default = {
|
|
|
267074
267074
|
devDependencies: {
|
|
267075
267075
|
"@commander-js/extra-typings": "13.1.0",
|
|
267076
267076
|
"@inquirer/confirm": "5.1.4",
|
|
267077
|
-
"@inquirer/input": "4.1.
|
|
267078
|
-
"@inquirer/password": "4.0.
|
|
267079
|
-
"@inquirer/select": "4.0.
|
|
267080
|
-
"@settlemint/sdk-js": "1.1.1-
|
|
267081
|
-
"@settlemint/sdk-utils": "1.1.1-
|
|
267077
|
+
"@inquirer/input": "4.1.4",
|
|
267078
|
+
"@inquirer/password": "4.0.7",
|
|
267079
|
+
"@inquirer/select": "4.0.7",
|
|
267080
|
+
"@settlemint/sdk-js": "1.1.1-prc7f21dc7",
|
|
267081
|
+
"@settlemint/sdk-utils": "1.1.1-prc7f21dc7",
|
|
267082
267082
|
"@types/node": "22.12.0",
|
|
267083
267083
|
"@types/semver": "7.5.8",
|
|
267084
267084
|
"@types/which": "3.0.4",
|
|
@@ -271172,13 +271172,13 @@ async function codegenTsconfig(env2, thegraphSubgraphNames) {
|
|
|
271172
271172
|
};
|
|
271173
271173
|
}
|
|
271174
271174
|
|
|
271175
|
-
// ../../node_modules/@inquirer/
|
|
271175
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/key.js
|
|
271176
271176
|
var isUpKey = (key) => key.name === "up" || key.name === "k" || key.ctrl && key.name === "p";
|
|
271177
271177
|
var isDownKey = (key) => key.name === "down" || key.name === "j" || key.ctrl && key.name === "n";
|
|
271178
271178
|
var isBackspaceKey = (key) => key.name === "backspace";
|
|
271179
271179
|
var isNumberKey = (key) => "123456789".includes(key.name);
|
|
271180
271180
|
var isEnterKey = (key) => key.name === "enter" || key.name === "return";
|
|
271181
|
-
// ../../node_modules/@inquirer/
|
|
271181
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/errors.js
|
|
271182
271182
|
class AbortPromptError extends Error {
|
|
271183
271183
|
name = "AbortPromptError";
|
|
271184
271184
|
message = "Prompt was aborted";
|
|
@@ -271204,10 +271204,10 @@ class HookError extends Error {
|
|
|
271204
271204
|
class ValidationError extends Error {
|
|
271205
271205
|
name = "ValidationError";
|
|
271206
271206
|
}
|
|
271207
|
-
// ../../node_modules/@inquirer/
|
|
271207
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/use-prefix.js
|
|
271208
271208
|
import { AsyncResource as AsyncResource2 } from "node:async_hooks";
|
|
271209
271209
|
|
|
271210
|
-
// ../../node_modules/@inquirer/
|
|
271210
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/hook-engine.js
|
|
271211
271211
|
import { AsyncLocalStorage, AsyncResource } from "node:async_hooks";
|
|
271212
271212
|
var hookStorage = new AsyncLocalStorage;
|
|
271213
271213
|
function createStore(rl) {
|
|
@@ -271313,7 +271313,7 @@ var effectScheduler = {
|
|
|
271313
271313
|
}
|
|
271314
271314
|
};
|
|
271315
271315
|
|
|
271316
|
-
// ../../node_modules/@inquirer/
|
|
271316
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/use-state.js
|
|
271317
271317
|
function useState(defaultValue) {
|
|
271318
271318
|
return withPointer((pointer) => {
|
|
271319
271319
|
const setFn = (newValue) => {
|
|
@@ -271331,7 +271331,7 @@ function useState(defaultValue) {
|
|
|
271331
271331
|
});
|
|
271332
271332
|
}
|
|
271333
271333
|
|
|
271334
|
-
// ../../node_modules/@inquirer/
|
|
271334
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/use-effect.js
|
|
271335
271335
|
function useEffect(cb, depArray) {
|
|
271336
271336
|
withPointer((pointer) => {
|
|
271337
271337
|
const oldDeps = pointer.get();
|
|
@@ -271343,7 +271343,7 @@ function useEffect(cb, depArray) {
|
|
|
271343
271343
|
});
|
|
271344
271344
|
}
|
|
271345
271345
|
|
|
271346
|
-
// ../../node_modules/@inquirer/
|
|
271346
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/theme.js
|
|
271347
271347
|
var import_yoctocolors_cjs = __toESM(require_yoctocolors_cjs(), 1);
|
|
271348
271348
|
|
|
271349
271349
|
// ../../node_modules/@inquirer/figures/dist/esm/index.js
|
|
@@ -271632,7 +271632,7 @@ var figures = shouldUseMain ? mainSymbols : fallbackSymbols;
|
|
|
271632
271632
|
var esm_default = figures;
|
|
271633
271633
|
var replacements = Object.entries(specialMainSymbols);
|
|
271634
271634
|
|
|
271635
|
-
// ../../node_modules/@inquirer/
|
|
271635
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/theme.js
|
|
271636
271636
|
var defaultTheme = {
|
|
271637
271637
|
prefix: {
|
|
271638
271638
|
idle: import_yoctocolors_cjs.default.blue("?"),
|
|
@@ -271653,7 +271653,7 @@ var defaultTheme = {
|
|
|
271653
271653
|
}
|
|
271654
271654
|
};
|
|
271655
271655
|
|
|
271656
|
-
// ../../node_modules/@inquirer/
|
|
271656
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/make-theme.js
|
|
271657
271657
|
function isPlainObject2(value4) {
|
|
271658
271658
|
if (typeof value4 !== "object" || value4 === null)
|
|
271659
271659
|
return false;
|
|
@@ -271681,7 +271681,7 @@ function makeTheme(...themes) {
|
|
|
271681
271681
|
return deepMerge2(...themesToMerge);
|
|
271682
271682
|
}
|
|
271683
271683
|
|
|
271684
|
-
// ../../node_modules/@inquirer/
|
|
271684
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/use-prefix.js
|
|
271685
271685
|
function usePrefix({ status = "idle", theme }) {
|
|
271686
271686
|
const [showLoader, setShowLoader] = useState(false);
|
|
271687
271687
|
const [tick, setTick] = useState(0);
|
|
@@ -271711,7 +271711,7 @@ function usePrefix({ status = "idle", theme }) {
|
|
|
271711
271711
|
const iconName = status === "loading" ? "idle" : status;
|
|
271712
271712
|
return typeof prefix === "string" ? prefix : prefix[iconName] ?? prefix["idle"];
|
|
271713
271713
|
}
|
|
271714
|
-
// ../../node_modules/@inquirer/
|
|
271714
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/use-memo.js
|
|
271715
271715
|
function useMemo(fn, dependencies) {
|
|
271716
271716
|
return withPointer((pointer) => {
|
|
271717
271717
|
const prev = pointer.get();
|
|
@@ -271723,11 +271723,11 @@ function useMemo(fn, dependencies) {
|
|
|
271723
271723
|
return prev.value;
|
|
271724
271724
|
});
|
|
271725
271725
|
}
|
|
271726
|
-
// ../../node_modules/@inquirer/
|
|
271726
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/use-ref.js
|
|
271727
271727
|
function useRef(val) {
|
|
271728
271728
|
return useState({ current: val })[0];
|
|
271729
271729
|
}
|
|
271730
|
-
// ../../node_modules/@inquirer/
|
|
271730
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/use-keypress.js
|
|
271731
271731
|
function useKeypress(userHandler) {
|
|
271732
271732
|
const signal = useRef(userHandler);
|
|
271733
271733
|
signal.current = userHandler;
|
|
@@ -271745,7 +271745,7 @@ function useKeypress(userHandler) {
|
|
|
271745
271745
|
};
|
|
271746
271746
|
}, []);
|
|
271747
271747
|
}
|
|
271748
|
-
// ../../node_modules/@inquirer/
|
|
271748
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/utils.js
|
|
271749
271749
|
var import_cli_width = __toESM(require_cli_width(), 1);
|
|
271750
271750
|
var import_wrap_ansi = __toESM(require_wrap_ansi(), 1);
|
|
271751
271751
|
function breakLines(content, width) {
|
|
@@ -271758,7 +271758,7 @@ function readlineWidth() {
|
|
|
271758
271758
|
return import_cli_width.default({ defaultWidth: 80, output: readline().output });
|
|
271759
271759
|
}
|
|
271760
271760
|
|
|
271761
|
-
// ../../node_modules/@inquirer/
|
|
271761
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/pagination/lines.js
|
|
271762
271762
|
function split2(content, width) {
|
|
271763
271763
|
return breakLines(content, width).split(`
|
|
271764
271764
|
`);
|
|
@@ -271803,7 +271803,7 @@ function lines({ items, width, renderItem, active, position: requested, pageSize
|
|
|
271803
271803
|
return pageBuffer.filter((line) => typeof line === "string");
|
|
271804
271804
|
}
|
|
271805
271805
|
|
|
271806
|
-
// ../../node_modules/@inquirer/
|
|
271806
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/pagination/position.js
|
|
271807
271807
|
function finite({ active, pageSize, total }) {
|
|
271808
271808
|
const middle = Math.floor(pageSize / 2);
|
|
271809
271809
|
if (total <= pageSize || active < middle)
|
|
@@ -271821,7 +271821,7 @@ function infinite({ active, lastActive, total, pageSize, pointer }) {
|
|
|
271821
271821
|
return pointer;
|
|
271822
271822
|
}
|
|
271823
271823
|
|
|
271824
|
-
// ../../node_modules/@inquirer/
|
|
271824
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/pagination/use-pagination.js
|
|
271825
271825
|
function usePagination({ items, active, renderItem, pageSize, loop = true }) {
|
|
271826
271826
|
const state = useRef({ position: 0, lastActive: 0 });
|
|
271827
271827
|
const position = loop ? infinite({
|
|
@@ -271847,7 +271847,7 @@ function usePagination({ items, active, renderItem, pageSize, loop = true }) {
|
|
|
271847
271847
|
}).join(`
|
|
271848
271848
|
`);
|
|
271849
271849
|
}
|
|
271850
|
-
// ../../node_modules/@inquirer/
|
|
271850
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/create-prompt.js
|
|
271851
271851
|
var import_mute_stream = __toESM(require_lib12(), 1);
|
|
271852
271852
|
import * as readline2 from "node:readline";
|
|
271853
271853
|
import { AsyncResource as AsyncResource3 } from "node:async_hooks";
|
|
@@ -272066,9 +272066,9 @@ var {
|
|
|
272066
272066
|
unload
|
|
272067
272067
|
} = signalExitWrap(processOk2(process7) ? new SignalExit2(process7) : new SignalExitFallback2);
|
|
272068
272068
|
|
|
272069
|
-
// ../../node_modules/@inquirer/
|
|
272070
|
-
var import_strip_ansi = __toESM(require_strip_ansi(), 1);
|
|
272069
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/screen-manager.js
|
|
272071
272070
|
var import_ansi_escapes = __toESM(require_ansi_escapes(), 1);
|
|
272071
|
+
import { stripVTControlCharacters as stripVTControlCharacters2 } from "node:util";
|
|
272072
272072
|
var height = (content) => content.split(`
|
|
272073
272073
|
`).length;
|
|
272074
272074
|
var lastLine = (content) => content.split(`
|
|
@@ -272094,7 +272094,7 @@ class ScreenManager {
|
|
|
272094
272094
|
}
|
|
272095
272095
|
render(content, bottomContent = "") {
|
|
272096
272096
|
const promptLine = lastLine(content);
|
|
272097
|
-
const rawPromptLine =
|
|
272097
|
+
const rawPromptLine = stripVTControlCharacters2(promptLine);
|
|
272098
272098
|
let prompt = rawPromptLine;
|
|
272099
272099
|
if (this.rl.line.length > 0) {
|
|
272100
272100
|
prompt = prompt.slice(0, -this.rl.line.length);
|
|
@@ -272137,7 +272137,7 @@ class ScreenManager {
|
|
|
272137
272137
|
}
|
|
272138
272138
|
}
|
|
272139
272139
|
|
|
272140
|
-
// ../../node_modules/@inquirer/
|
|
272140
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/promise-polyfill.js
|
|
272141
272141
|
class PromisePolyfill extends Promise {
|
|
272142
272142
|
static withResolver() {
|
|
272143
272143
|
let resolve5;
|
|
@@ -272150,7 +272150,7 @@ class PromisePolyfill extends Promise {
|
|
|
272150
272150
|
}
|
|
272151
272151
|
}
|
|
272152
272152
|
|
|
272153
|
-
// ../../node_modules/@inquirer/
|
|
272153
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/create-prompt.js
|
|
272154
272154
|
function getCallSites() {
|
|
272155
272155
|
const _prepareStackTrace = Error.prepareStackTrace;
|
|
272156
272156
|
try {
|
|
@@ -272232,7 +272232,7 @@ function createPrompt(view) {
|
|
|
272232
272232
|
};
|
|
272233
272233
|
return prompt;
|
|
272234
272234
|
}
|
|
272235
|
-
// ../../node_modules/@inquirer/
|
|
272235
|
+
// ../../node_modules/@inquirer/core/dist/esm/lib/Separator.js
|
|
272236
272236
|
var import_yoctocolors_cjs2 = __toESM(require_yoctocolors_cjs(), 1);
|
|
272237
272237
|
class Separator {
|
|
272238
272238
|
separator = import_yoctocolors_cjs2.default.dim(Array.from({ length: 15 }).join(esm_default.line));
|
|
@@ -272705,748 +272705,6 @@ function codegenCommand() {
|
|
|
272705
272705
|
});
|
|
272706
272706
|
}
|
|
272707
272707
|
|
|
272708
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/key.js
|
|
272709
|
-
var isEnterKey2 = (key2) => key2.name === "enter" || key2.name === "return";
|
|
272710
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/errors.js
|
|
272711
|
-
class AbortPromptError2 extends Error {
|
|
272712
|
-
name = "AbortPromptError";
|
|
272713
|
-
message = "Prompt was aborted";
|
|
272714
|
-
constructor(options) {
|
|
272715
|
-
super();
|
|
272716
|
-
this.cause = options?.cause;
|
|
272717
|
-
}
|
|
272718
|
-
}
|
|
272719
|
-
|
|
272720
|
-
class CancelPromptError2 extends Error {
|
|
272721
|
-
name = "CancelPromptError";
|
|
272722
|
-
message = "Prompt was canceled";
|
|
272723
|
-
}
|
|
272724
|
-
|
|
272725
|
-
class ExitPromptError2 extends Error {
|
|
272726
|
-
name = "ExitPromptError";
|
|
272727
|
-
}
|
|
272728
|
-
|
|
272729
|
-
class HookError2 extends Error {
|
|
272730
|
-
name = "HookError";
|
|
272731
|
-
}
|
|
272732
|
-
|
|
272733
|
-
class ValidationError2 extends Error {
|
|
272734
|
-
name = "ValidationError";
|
|
272735
|
-
}
|
|
272736
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/use-prefix.js
|
|
272737
|
-
import { AsyncResource as AsyncResource5 } from "node:async_hooks";
|
|
272738
|
-
|
|
272739
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/hook-engine.js
|
|
272740
|
-
import { AsyncLocalStorage as AsyncLocalStorage2, AsyncResource as AsyncResource4 } from "node:async_hooks";
|
|
272741
|
-
var hookStorage2 = new AsyncLocalStorage2;
|
|
272742
|
-
function createStore2(rl) {
|
|
272743
|
-
const store = {
|
|
272744
|
-
rl,
|
|
272745
|
-
hooks: [],
|
|
272746
|
-
hooksCleanup: [],
|
|
272747
|
-
hooksEffect: [],
|
|
272748
|
-
index: 0,
|
|
272749
|
-
handleChange() {
|
|
272750
|
-
}
|
|
272751
|
-
};
|
|
272752
|
-
return store;
|
|
272753
|
-
}
|
|
272754
|
-
function withHooks2(rl, cb) {
|
|
272755
|
-
const store = createStore2(rl);
|
|
272756
|
-
return hookStorage2.run(store, () => {
|
|
272757
|
-
function cycle(render) {
|
|
272758
|
-
store.handleChange = () => {
|
|
272759
|
-
store.index = 0;
|
|
272760
|
-
render();
|
|
272761
|
-
};
|
|
272762
|
-
store.handleChange();
|
|
272763
|
-
}
|
|
272764
|
-
return cb(cycle);
|
|
272765
|
-
});
|
|
272766
|
-
}
|
|
272767
|
-
function getStore2() {
|
|
272768
|
-
const store = hookStorage2.getStore();
|
|
272769
|
-
if (!store) {
|
|
272770
|
-
throw new HookError2("[Inquirer] Hook functions can only be called from within a prompt");
|
|
272771
|
-
}
|
|
272772
|
-
return store;
|
|
272773
|
-
}
|
|
272774
|
-
function readline3() {
|
|
272775
|
-
return getStore2().rl;
|
|
272776
|
-
}
|
|
272777
|
-
function withUpdates2(fn) {
|
|
272778
|
-
const wrapped = (...args) => {
|
|
272779
|
-
const store = getStore2();
|
|
272780
|
-
let shouldUpdate = false;
|
|
272781
|
-
const oldHandleChange = store.handleChange;
|
|
272782
|
-
store.handleChange = () => {
|
|
272783
|
-
shouldUpdate = true;
|
|
272784
|
-
};
|
|
272785
|
-
const returnValue = fn(...args);
|
|
272786
|
-
if (shouldUpdate) {
|
|
272787
|
-
oldHandleChange();
|
|
272788
|
-
}
|
|
272789
|
-
store.handleChange = oldHandleChange;
|
|
272790
|
-
return returnValue;
|
|
272791
|
-
};
|
|
272792
|
-
return AsyncResource4.bind(wrapped);
|
|
272793
|
-
}
|
|
272794
|
-
function withPointer2(cb) {
|
|
272795
|
-
const store = getStore2();
|
|
272796
|
-
const { index } = store;
|
|
272797
|
-
const pointer = {
|
|
272798
|
-
get() {
|
|
272799
|
-
return store.hooks[index];
|
|
272800
|
-
},
|
|
272801
|
-
set(value4) {
|
|
272802
|
-
store.hooks[index] = value4;
|
|
272803
|
-
},
|
|
272804
|
-
initialized: index in store.hooks
|
|
272805
|
-
};
|
|
272806
|
-
const returnValue = cb(pointer);
|
|
272807
|
-
store.index++;
|
|
272808
|
-
return returnValue;
|
|
272809
|
-
}
|
|
272810
|
-
function handleChange2() {
|
|
272811
|
-
getStore2().handleChange();
|
|
272812
|
-
}
|
|
272813
|
-
var effectScheduler2 = {
|
|
272814
|
-
queue(cb) {
|
|
272815
|
-
const store = getStore2();
|
|
272816
|
-
const { index } = store;
|
|
272817
|
-
store.hooksEffect.push(() => {
|
|
272818
|
-
store.hooksCleanup[index]?.();
|
|
272819
|
-
const cleanFn = cb(readline3());
|
|
272820
|
-
if (cleanFn != null && typeof cleanFn !== "function") {
|
|
272821
|
-
throw new ValidationError2("useEffect return value must be a cleanup function or nothing.");
|
|
272822
|
-
}
|
|
272823
|
-
store.hooksCleanup[index] = cleanFn;
|
|
272824
|
-
});
|
|
272825
|
-
},
|
|
272826
|
-
run() {
|
|
272827
|
-
const store = getStore2();
|
|
272828
|
-
withUpdates2(() => {
|
|
272829
|
-
store.hooksEffect.forEach((effect) => {
|
|
272830
|
-
effect();
|
|
272831
|
-
});
|
|
272832
|
-
store.hooksEffect.length = 0;
|
|
272833
|
-
})();
|
|
272834
|
-
},
|
|
272835
|
-
clearAll() {
|
|
272836
|
-
const store = getStore2();
|
|
272837
|
-
store.hooksCleanup.forEach((cleanFn) => {
|
|
272838
|
-
cleanFn?.();
|
|
272839
|
-
});
|
|
272840
|
-
store.hooksEffect.length = 0;
|
|
272841
|
-
store.hooksCleanup.length = 0;
|
|
272842
|
-
}
|
|
272843
|
-
};
|
|
272844
|
-
|
|
272845
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/use-state.js
|
|
272846
|
-
function useState2(defaultValue) {
|
|
272847
|
-
return withPointer2((pointer) => {
|
|
272848
|
-
const setFn = (newValue) => {
|
|
272849
|
-
if (pointer.get() !== newValue) {
|
|
272850
|
-
pointer.set(newValue);
|
|
272851
|
-
handleChange2();
|
|
272852
|
-
}
|
|
272853
|
-
};
|
|
272854
|
-
if (pointer.initialized) {
|
|
272855
|
-
return [pointer.get(), setFn];
|
|
272856
|
-
}
|
|
272857
|
-
const value4 = typeof defaultValue === "function" ? defaultValue() : defaultValue;
|
|
272858
|
-
pointer.set(value4);
|
|
272859
|
-
return [value4, setFn];
|
|
272860
|
-
});
|
|
272861
|
-
}
|
|
272862
|
-
|
|
272863
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/use-effect.js
|
|
272864
|
-
function useEffect2(cb, depArray) {
|
|
272865
|
-
withPointer2((pointer) => {
|
|
272866
|
-
const oldDeps = pointer.get();
|
|
272867
|
-
const hasChanged = !Array.isArray(oldDeps) || depArray.some((dep, i6) => !Object.is(dep, oldDeps[i6]));
|
|
272868
|
-
if (hasChanged) {
|
|
272869
|
-
effectScheduler2.queue(cb);
|
|
272870
|
-
}
|
|
272871
|
-
pointer.set(depArray);
|
|
272872
|
-
});
|
|
272873
|
-
}
|
|
272874
|
-
|
|
272875
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/theme.js
|
|
272876
|
-
var import_yoctocolors_cjs4 = __toESM(require_yoctocolors_cjs(), 1);
|
|
272877
|
-
|
|
272878
|
-
// ../../node_modules/@inquirer/core/node_modules/@inquirer/figures/dist/esm/index.js
|
|
272879
|
-
import process8 from "node:process";
|
|
272880
|
-
function isUnicodeSupported3() {
|
|
272881
|
-
if (process8.platform !== "win32") {
|
|
272882
|
-
return process8.env["TERM"] !== "linux";
|
|
272883
|
-
}
|
|
272884
|
-
return Boolean(process8.env["WT_SESSION"]) || Boolean(process8.env["TERMINUS_SUBLIME"]) || process8.env["ConEmuTask"] === "{cmd::Cmder}" || process8.env["TERM_PROGRAM"] === "Terminus-Sublime" || process8.env["TERM_PROGRAM"] === "vscode" || process8.env["TERM"] === "xterm-256color" || process8.env["TERM"] === "alacritty" || process8.env["TERMINAL_EMULATOR"] === "JetBrains-JediTerm";
|
|
272885
|
-
}
|
|
272886
|
-
var common2 = {
|
|
272887
|
-
circleQuestionMark: "(?)",
|
|
272888
|
-
questionMarkPrefix: "(?)",
|
|
272889
|
-
square: "█",
|
|
272890
|
-
squareDarkShade: "▓",
|
|
272891
|
-
squareMediumShade: "▒",
|
|
272892
|
-
squareLightShade: "░",
|
|
272893
|
-
squareTop: "▀",
|
|
272894
|
-
squareBottom: "▄",
|
|
272895
|
-
squareLeft: "▌",
|
|
272896
|
-
squareRight: "▐",
|
|
272897
|
-
squareCenter: "■",
|
|
272898
|
-
bullet: "●",
|
|
272899
|
-
dot: "․",
|
|
272900
|
-
ellipsis: "…",
|
|
272901
|
-
pointerSmall: "›",
|
|
272902
|
-
triangleUp: "▲",
|
|
272903
|
-
triangleUpSmall: "▴",
|
|
272904
|
-
triangleDown: "▼",
|
|
272905
|
-
triangleDownSmall: "▾",
|
|
272906
|
-
triangleLeftSmall: "◂",
|
|
272907
|
-
triangleRightSmall: "▸",
|
|
272908
|
-
home: "⌂",
|
|
272909
|
-
heart: "♥",
|
|
272910
|
-
musicNote: "♪",
|
|
272911
|
-
musicNoteBeamed: "♫",
|
|
272912
|
-
arrowUp: "↑",
|
|
272913
|
-
arrowDown: "↓",
|
|
272914
|
-
arrowLeft: "←",
|
|
272915
|
-
arrowRight: "→",
|
|
272916
|
-
arrowLeftRight: "↔",
|
|
272917
|
-
arrowUpDown: "↕",
|
|
272918
|
-
almostEqual: "≈",
|
|
272919
|
-
notEqual: "≠",
|
|
272920
|
-
lessOrEqual: "≤",
|
|
272921
|
-
greaterOrEqual: "≥",
|
|
272922
|
-
identical: "≡",
|
|
272923
|
-
infinity: "∞",
|
|
272924
|
-
subscriptZero: "₀",
|
|
272925
|
-
subscriptOne: "₁",
|
|
272926
|
-
subscriptTwo: "₂",
|
|
272927
|
-
subscriptThree: "₃",
|
|
272928
|
-
subscriptFour: "₄",
|
|
272929
|
-
subscriptFive: "₅",
|
|
272930
|
-
subscriptSix: "₆",
|
|
272931
|
-
subscriptSeven: "₇",
|
|
272932
|
-
subscriptEight: "₈",
|
|
272933
|
-
subscriptNine: "₉",
|
|
272934
|
-
oneHalf: "½",
|
|
272935
|
-
oneThird: "⅓",
|
|
272936
|
-
oneQuarter: "¼",
|
|
272937
|
-
oneFifth: "⅕",
|
|
272938
|
-
oneSixth: "⅙",
|
|
272939
|
-
oneEighth: "⅛",
|
|
272940
|
-
twoThirds: "⅔",
|
|
272941
|
-
twoFifths: "⅖",
|
|
272942
|
-
threeQuarters: "¾",
|
|
272943
|
-
threeFifths: "⅗",
|
|
272944
|
-
threeEighths: "⅜",
|
|
272945
|
-
fourFifths: "⅘",
|
|
272946
|
-
fiveSixths: "⅚",
|
|
272947
|
-
fiveEighths: "⅝",
|
|
272948
|
-
sevenEighths: "⅞",
|
|
272949
|
-
line: "─",
|
|
272950
|
-
lineBold: "━",
|
|
272951
|
-
lineDouble: "═",
|
|
272952
|
-
lineDashed0: "┄",
|
|
272953
|
-
lineDashed1: "┅",
|
|
272954
|
-
lineDashed2: "┈",
|
|
272955
|
-
lineDashed3: "┉",
|
|
272956
|
-
lineDashed4: "╌",
|
|
272957
|
-
lineDashed5: "╍",
|
|
272958
|
-
lineDashed6: "╴",
|
|
272959
|
-
lineDashed7: "╶",
|
|
272960
|
-
lineDashed8: "╸",
|
|
272961
|
-
lineDashed9: "╺",
|
|
272962
|
-
lineDashed10: "╼",
|
|
272963
|
-
lineDashed11: "╾",
|
|
272964
|
-
lineDashed12: "−",
|
|
272965
|
-
lineDashed13: "–",
|
|
272966
|
-
lineDashed14: "‐",
|
|
272967
|
-
lineDashed15: "⁃",
|
|
272968
|
-
lineVertical: "│",
|
|
272969
|
-
lineVerticalBold: "┃",
|
|
272970
|
-
lineVerticalDouble: "║",
|
|
272971
|
-
lineVerticalDashed0: "┆",
|
|
272972
|
-
lineVerticalDashed1: "┇",
|
|
272973
|
-
lineVerticalDashed2: "┊",
|
|
272974
|
-
lineVerticalDashed3: "┋",
|
|
272975
|
-
lineVerticalDashed4: "╎",
|
|
272976
|
-
lineVerticalDashed5: "╏",
|
|
272977
|
-
lineVerticalDashed6: "╵",
|
|
272978
|
-
lineVerticalDashed7: "╷",
|
|
272979
|
-
lineVerticalDashed8: "╹",
|
|
272980
|
-
lineVerticalDashed9: "╻",
|
|
272981
|
-
lineVerticalDashed10: "╽",
|
|
272982
|
-
lineVerticalDashed11: "╿",
|
|
272983
|
-
lineDownLeft: "┐",
|
|
272984
|
-
lineDownLeftArc: "╮",
|
|
272985
|
-
lineDownBoldLeftBold: "┓",
|
|
272986
|
-
lineDownBoldLeft: "┒",
|
|
272987
|
-
lineDownLeftBold: "┑",
|
|
272988
|
-
lineDownDoubleLeftDouble: "╗",
|
|
272989
|
-
lineDownDoubleLeft: "╖",
|
|
272990
|
-
lineDownLeftDouble: "╕",
|
|
272991
|
-
lineDownRight: "┌",
|
|
272992
|
-
lineDownRightArc: "╭",
|
|
272993
|
-
lineDownBoldRightBold: "┏",
|
|
272994
|
-
lineDownBoldRight: "┎",
|
|
272995
|
-
lineDownRightBold: "┍",
|
|
272996
|
-
lineDownDoubleRightDouble: "╔",
|
|
272997
|
-
lineDownDoubleRight: "╓",
|
|
272998
|
-
lineDownRightDouble: "╒",
|
|
272999
|
-
lineUpLeft: "┘",
|
|
273000
|
-
lineUpLeftArc: "╯",
|
|
273001
|
-
lineUpBoldLeftBold: "┛",
|
|
273002
|
-
lineUpBoldLeft: "┚",
|
|
273003
|
-
lineUpLeftBold: "┙",
|
|
273004
|
-
lineUpDoubleLeftDouble: "╝",
|
|
273005
|
-
lineUpDoubleLeft: "╜",
|
|
273006
|
-
lineUpLeftDouble: "╛",
|
|
273007
|
-
lineUpRight: "└",
|
|
273008
|
-
lineUpRightArc: "╰",
|
|
273009
|
-
lineUpBoldRightBold: "┗",
|
|
273010
|
-
lineUpBoldRight: "┖",
|
|
273011
|
-
lineUpRightBold: "┕",
|
|
273012
|
-
lineUpDoubleRightDouble: "╚",
|
|
273013
|
-
lineUpDoubleRight: "╙",
|
|
273014
|
-
lineUpRightDouble: "╘",
|
|
273015
|
-
lineUpDownLeft: "┤",
|
|
273016
|
-
lineUpBoldDownBoldLeftBold: "┫",
|
|
273017
|
-
lineUpBoldDownBoldLeft: "┨",
|
|
273018
|
-
lineUpDownLeftBold: "┥",
|
|
273019
|
-
lineUpBoldDownLeftBold: "┩",
|
|
273020
|
-
lineUpDownBoldLeftBold: "┪",
|
|
273021
|
-
lineUpDownBoldLeft: "┧",
|
|
273022
|
-
lineUpBoldDownLeft: "┦",
|
|
273023
|
-
lineUpDoubleDownDoubleLeftDouble: "╣",
|
|
273024
|
-
lineUpDoubleDownDoubleLeft: "╢",
|
|
273025
|
-
lineUpDownLeftDouble: "╡",
|
|
273026
|
-
lineUpDownRight: "├",
|
|
273027
|
-
lineUpBoldDownBoldRightBold: "┣",
|
|
273028
|
-
lineUpBoldDownBoldRight: "┠",
|
|
273029
|
-
lineUpDownRightBold: "┝",
|
|
273030
|
-
lineUpBoldDownRightBold: "┡",
|
|
273031
|
-
lineUpDownBoldRightBold: "┢",
|
|
273032
|
-
lineUpDownBoldRight: "┟",
|
|
273033
|
-
lineUpBoldDownRight: "┞",
|
|
273034
|
-
lineUpDoubleDownDoubleRightDouble: "╠",
|
|
273035
|
-
lineUpDoubleDownDoubleRight: "╟",
|
|
273036
|
-
lineUpDownRightDouble: "╞",
|
|
273037
|
-
lineDownLeftRight: "┬",
|
|
273038
|
-
lineDownBoldLeftBoldRightBold: "┳",
|
|
273039
|
-
lineDownLeftBoldRightBold: "┯",
|
|
273040
|
-
lineDownBoldLeftRight: "┰",
|
|
273041
|
-
lineDownBoldLeftBoldRight: "┱",
|
|
273042
|
-
lineDownBoldLeftRightBold: "┲",
|
|
273043
|
-
lineDownLeftRightBold: "┮",
|
|
273044
|
-
lineDownLeftBoldRight: "┭",
|
|
273045
|
-
lineDownDoubleLeftDoubleRightDouble: "╦",
|
|
273046
|
-
lineDownDoubleLeftRight: "╥",
|
|
273047
|
-
lineDownLeftDoubleRightDouble: "╤",
|
|
273048
|
-
lineUpLeftRight: "┴",
|
|
273049
|
-
lineUpBoldLeftBoldRightBold: "┻",
|
|
273050
|
-
lineUpLeftBoldRightBold: "┷",
|
|
273051
|
-
lineUpBoldLeftRight: "┸",
|
|
273052
|
-
lineUpBoldLeftBoldRight: "┹",
|
|
273053
|
-
lineUpBoldLeftRightBold: "┺",
|
|
273054
|
-
lineUpLeftRightBold: "┶",
|
|
273055
|
-
lineUpLeftBoldRight: "┵",
|
|
273056
|
-
lineUpDoubleLeftDoubleRightDouble: "╩",
|
|
273057
|
-
lineUpDoubleLeftRight: "╨",
|
|
273058
|
-
lineUpLeftDoubleRightDouble: "╧",
|
|
273059
|
-
lineUpDownLeftRight: "┼",
|
|
273060
|
-
lineUpBoldDownBoldLeftBoldRightBold: "╋",
|
|
273061
|
-
lineUpDownBoldLeftBoldRightBold: "╈",
|
|
273062
|
-
lineUpBoldDownLeftBoldRightBold: "╇",
|
|
273063
|
-
lineUpBoldDownBoldLeftRightBold: "╊",
|
|
273064
|
-
lineUpBoldDownBoldLeftBoldRight: "╉",
|
|
273065
|
-
lineUpBoldDownLeftRight: "╀",
|
|
273066
|
-
lineUpDownBoldLeftRight: "╁",
|
|
273067
|
-
lineUpDownLeftBoldRight: "┽",
|
|
273068
|
-
lineUpDownLeftRightBold: "┾",
|
|
273069
|
-
lineUpBoldDownBoldLeftRight: "╂",
|
|
273070
|
-
lineUpDownLeftBoldRightBold: "┿",
|
|
273071
|
-
lineUpBoldDownLeftBoldRight: "╃",
|
|
273072
|
-
lineUpBoldDownLeftRightBold: "╄",
|
|
273073
|
-
lineUpDownBoldLeftBoldRight: "╅",
|
|
273074
|
-
lineUpDownBoldLeftRightBold: "╆",
|
|
273075
|
-
lineUpDoubleDownDoubleLeftDoubleRightDouble: "╬",
|
|
273076
|
-
lineUpDoubleDownDoubleLeftRight: "╫",
|
|
273077
|
-
lineUpDownLeftDoubleRightDouble: "╪",
|
|
273078
|
-
lineCross: "╳",
|
|
273079
|
-
lineBackslash: "╲",
|
|
273080
|
-
lineSlash: "╱"
|
|
273081
|
-
};
|
|
273082
|
-
var specialMainSymbols2 = {
|
|
273083
|
-
tick: "✔",
|
|
273084
|
-
info: "ℹ",
|
|
273085
|
-
warning: "⚠",
|
|
273086
|
-
cross: "✘",
|
|
273087
|
-
squareSmall: "◻",
|
|
273088
|
-
squareSmallFilled: "◼",
|
|
273089
|
-
circle: "◯",
|
|
273090
|
-
circleFilled: "◉",
|
|
273091
|
-
circleDotted: "◌",
|
|
273092
|
-
circleDouble: "◎",
|
|
273093
|
-
circleCircle: "ⓞ",
|
|
273094
|
-
circleCross: "ⓧ",
|
|
273095
|
-
circlePipe: "Ⓘ",
|
|
273096
|
-
radioOn: "◉",
|
|
273097
|
-
radioOff: "◯",
|
|
273098
|
-
checkboxOn: "☒",
|
|
273099
|
-
checkboxOff: "☐",
|
|
273100
|
-
checkboxCircleOn: "ⓧ",
|
|
273101
|
-
checkboxCircleOff: "Ⓘ",
|
|
273102
|
-
pointer: "❯",
|
|
273103
|
-
triangleUpOutline: "△",
|
|
273104
|
-
triangleLeft: "◀",
|
|
273105
|
-
triangleRight: "▶",
|
|
273106
|
-
lozenge: "◆",
|
|
273107
|
-
lozengeOutline: "◇",
|
|
273108
|
-
hamburger: "☰",
|
|
273109
|
-
smiley: "㋡",
|
|
273110
|
-
mustache: "෴",
|
|
273111
|
-
star: "★",
|
|
273112
|
-
play: "▶",
|
|
273113
|
-
nodejs: "⬢",
|
|
273114
|
-
oneSeventh: "⅐",
|
|
273115
|
-
oneNinth: "⅑",
|
|
273116
|
-
oneTenth: "⅒"
|
|
273117
|
-
};
|
|
273118
|
-
var specialFallbackSymbols2 = {
|
|
273119
|
-
tick: "√",
|
|
273120
|
-
info: "i",
|
|
273121
|
-
warning: "‼",
|
|
273122
|
-
cross: "×",
|
|
273123
|
-
squareSmall: "□",
|
|
273124
|
-
squareSmallFilled: "■",
|
|
273125
|
-
circle: "( )",
|
|
273126
|
-
circleFilled: "(*)",
|
|
273127
|
-
circleDotted: "( )",
|
|
273128
|
-
circleDouble: "( )",
|
|
273129
|
-
circleCircle: "(○)",
|
|
273130
|
-
circleCross: "(×)",
|
|
273131
|
-
circlePipe: "(│)",
|
|
273132
|
-
radioOn: "(*)",
|
|
273133
|
-
radioOff: "( )",
|
|
273134
|
-
checkboxOn: "[×]",
|
|
273135
|
-
checkboxOff: "[ ]",
|
|
273136
|
-
checkboxCircleOn: "(×)",
|
|
273137
|
-
checkboxCircleOff: "( )",
|
|
273138
|
-
pointer: ">",
|
|
273139
|
-
triangleUpOutline: "∆",
|
|
273140
|
-
triangleLeft: "◄",
|
|
273141
|
-
triangleRight: "►",
|
|
273142
|
-
lozenge: "♦",
|
|
273143
|
-
lozengeOutline: "◊",
|
|
273144
|
-
hamburger: "≡",
|
|
273145
|
-
smiley: "☺",
|
|
273146
|
-
mustache: "┌─┐",
|
|
273147
|
-
star: "✶",
|
|
273148
|
-
play: "►",
|
|
273149
|
-
nodejs: "♦",
|
|
273150
|
-
oneSeventh: "1/7",
|
|
273151
|
-
oneNinth: "1/9",
|
|
273152
|
-
oneTenth: "1/10"
|
|
273153
|
-
};
|
|
273154
|
-
var mainSymbols2 = { ...common2, ...specialMainSymbols2 };
|
|
273155
|
-
var fallbackSymbols2 = {
|
|
273156
|
-
...common2,
|
|
273157
|
-
...specialFallbackSymbols2
|
|
273158
|
-
};
|
|
273159
|
-
var shouldUseMain2 = isUnicodeSupported3();
|
|
273160
|
-
var figures2 = shouldUseMain2 ? mainSymbols2 : fallbackSymbols2;
|
|
273161
|
-
var esm_default3 = figures2;
|
|
273162
|
-
var replacements2 = Object.entries(specialMainSymbols2);
|
|
273163
|
-
|
|
273164
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/theme.js
|
|
273165
|
-
var defaultTheme2 = {
|
|
273166
|
-
prefix: {
|
|
273167
|
-
idle: import_yoctocolors_cjs4.default.blue("?"),
|
|
273168
|
-
done: import_yoctocolors_cjs4.default.green(esm_default3.tick)
|
|
273169
|
-
},
|
|
273170
|
-
spinner: {
|
|
273171
|
-
interval: 80,
|
|
273172
|
-
frames: ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"].map((frame) => import_yoctocolors_cjs4.default.yellow(frame))
|
|
273173
|
-
},
|
|
273174
|
-
style: {
|
|
273175
|
-
answer: import_yoctocolors_cjs4.default.cyan,
|
|
273176
|
-
message: import_yoctocolors_cjs4.default.bold,
|
|
273177
|
-
error: (text2) => import_yoctocolors_cjs4.default.red(`> ${text2}`),
|
|
273178
|
-
defaultAnswer: (text2) => import_yoctocolors_cjs4.default.dim(`(${text2})`),
|
|
273179
|
-
help: import_yoctocolors_cjs4.default.dim,
|
|
273180
|
-
highlight: import_yoctocolors_cjs4.default.cyan,
|
|
273181
|
-
key: (text2) => import_yoctocolors_cjs4.default.cyan(import_yoctocolors_cjs4.default.bold(`<${text2}>`))
|
|
273182
|
-
}
|
|
273183
|
-
};
|
|
273184
|
-
|
|
273185
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/make-theme.js
|
|
273186
|
-
function isPlainObject3(value4) {
|
|
273187
|
-
if (typeof value4 !== "object" || value4 === null)
|
|
273188
|
-
return false;
|
|
273189
|
-
let proto = value4;
|
|
273190
|
-
while (Object.getPrototypeOf(proto) !== null) {
|
|
273191
|
-
proto = Object.getPrototypeOf(proto);
|
|
273192
|
-
}
|
|
273193
|
-
return Object.getPrototypeOf(value4) === proto;
|
|
273194
|
-
}
|
|
273195
|
-
function deepMerge3(...objects) {
|
|
273196
|
-
const output = {};
|
|
273197
|
-
for (const obj of objects) {
|
|
273198
|
-
for (const [key2, value4] of Object.entries(obj)) {
|
|
273199
|
-
const prevValue = output[key2];
|
|
273200
|
-
output[key2] = isPlainObject3(prevValue) && isPlainObject3(value4) ? deepMerge3(prevValue, value4) : value4;
|
|
273201
|
-
}
|
|
273202
|
-
}
|
|
273203
|
-
return output;
|
|
273204
|
-
}
|
|
273205
|
-
function makeTheme2(...themes) {
|
|
273206
|
-
const themesToMerge = [
|
|
273207
|
-
defaultTheme2,
|
|
273208
|
-
...themes.filter((theme) => theme != null)
|
|
273209
|
-
];
|
|
273210
|
-
return deepMerge3(...themesToMerge);
|
|
273211
|
-
}
|
|
273212
|
-
|
|
273213
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/use-prefix.js
|
|
273214
|
-
function usePrefix2({ status = "idle", theme }) {
|
|
273215
|
-
const [showLoader, setShowLoader] = useState2(false);
|
|
273216
|
-
const [tick, setTick] = useState2(0);
|
|
273217
|
-
const { prefix, spinner: spinner2 } = makeTheme2(theme);
|
|
273218
|
-
useEffect2(() => {
|
|
273219
|
-
if (status === "loading") {
|
|
273220
|
-
let tickInterval;
|
|
273221
|
-
let inc = -1;
|
|
273222
|
-
const delayTimeout = setTimeout(AsyncResource5.bind(() => {
|
|
273223
|
-
setShowLoader(true);
|
|
273224
|
-
tickInterval = setInterval(AsyncResource5.bind(() => {
|
|
273225
|
-
inc = inc + 1;
|
|
273226
|
-
setTick(inc % spinner2.frames.length);
|
|
273227
|
-
}), spinner2.interval);
|
|
273228
|
-
}), 300);
|
|
273229
|
-
return () => {
|
|
273230
|
-
clearTimeout(delayTimeout);
|
|
273231
|
-
clearInterval(tickInterval);
|
|
273232
|
-
};
|
|
273233
|
-
} else {
|
|
273234
|
-
setShowLoader(false);
|
|
273235
|
-
}
|
|
273236
|
-
}, [status]);
|
|
273237
|
-
if (showLoader) {
|
|
273238
|
-
return spinner2.frames[tick];
|
|
273239
|
-
}
|
|
273240
|
-
const iconName = status === "loading" ? "idle" : status;
|
|
273241
|
-
return typeof prefix === "string" ? prefix : prefix[iconName] ?? prefix["idle"];
|
|
273242
|
-
}
|
|
273243
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/use-ref.js
|
|
273244
|
-
function useRef2(val) {
|
|
273245
|
-
return useState2({ current: val })[0];
|
|
273246
|
-
}
|
|
273247
|
-
|
|
273248
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/use-keypress.js
|
|
273249
|
-
function useKeypress2(userHandler) {
|
|
273250
|
-
const signal = useRef2(userHandler);
|
|
273251
|
-
signal.current = userHandler;
|
|
273252
|
-
useEffect2((rl) => {
|
|
273253
|
-
let ignore = false;
|
|
273254
|
-
const handler = withUpdates2((_input, event) => {
|
|
273255
|
-
if (ignore)
|
|
273256
|
-
return;
|
|
273257
|
-
signal.current(event, rl);
|
|
273258
|
-
});
|
|
273259
|
-
rl.input.on("keypress", handler);
|
|
273260
|
-
return () => {
|
|
273261
|
-
ignore = true;
|
|
273262
|
-
rl.input.removeListener("keypress", handler);
|
|
273263
|
-
};
|
|
273264
|
-
}, []);
|
|
273265
|
-
}
|
|
273266
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/utils.js
|
|
273267
|
-
var import_cli_width2 = __toESM(require_cli_width(), 1);
|
|
273268
|
-
var import_wrap_ansi2 = __toESM(require_wrap_ansi(), 1);
|
|
273269
|
-
function breakLines2(content, width) {
|
|
273270
|
-
return content.split(`
|
|
273271
|
-
`).flatMap((line) => import_wrap_ansi2.default(line, width, { trim: false, hard: true }).split(`
|
|
273272
|
-
`).map((str) => str.trimEnd())).join(`
|
|
273273
|
-
`);
|
|
273274
|
-
}
|
|
273275
|
-
function readlineWidth2() {
|
|
273276
|
-
return import_cli_width2.default({ defaultWidth: 80, output: readline3().output });
|
|
273277
|
-
}
|
|
273278
|
-
|
|
273279
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/create-prompt.js
|
|
273280
|
-
var import_mute_stream2 = __toESM(require_lib12(), 1);
|
|
273281
|
-
import * as readline4 from "node:readline";
|
|
273282
|
-
import { AsyncResource as AsyncResource6 } from "node:async_hooks";
|
|
273283
|
-
|
|
273284
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/screen-manager.js
|
|
273285
|
-
var import_ansi_escapes3 = __toESM(require_ansi_escapes(), 1);
|
|
273286
|
-
import { stripVTControlCharacters as stripVTControlCharacters2 } from "node:util";
|
|
273287
|
-
var height2 = (content) => content.split(`
|
|
273288
|
-
`).length;
|
|
273289
|
-
var lastLine2 = (content) => content.split(`
|
|
273290
|
-
`).pop() ?? "";
|
|
273291
|
-
function cursorDown2(n6) {
|
|
273292
|
-
return n6 > 0 ? import_ansi_escapes3.default.cursorDown(n6) : "";
|
|
273293
|
-
}
|
|
273294
|
-
|
|
273295
|
-
class ScreenManager2 {
|
|
273296
|
-
rl;
|
|
273297
|
-
height = 0;
|
|
273298
|
-
extraLinesUnderPrompt = 0;
|
|
273299
|
-
cursorPos;
|
|
273300
|
-
constructor(rl) {
|
|
273301
|
-
this.rl = rl;
|
|
273302
|
-
this.rl = rl;
|
|
273303
|
-
this.cursorPos = rl.getCursorPos();
|
|
273304
|
-
}
|
|
273305
|
-
write(content) {
|
|
273306
|
-
this.rl.output.unmute();
|
|
273307
|
-
this.rl.output.write(content);
|
|
273308
|
-
this.rl.output.mute();
|
|
273309
|
-
}
|
|
273310
|
-
render(content, bottomContent = "") {
|
|
273311
|
-
const promptLine = lastLine2(content);
|
|
273312
|
-
const rawPromptLine = stripVTControlCharacters2(promptLine);
|
|
273313
|
-
let prompt = rawPromptLine;
|
|
273314
|
-
if (this.rl.line.length > 0) {
|
|
273315
|
-
prompt = prompt.slice(0, -this.rl.line.length);
|
|
273316
|
-
}
|
|
273317
|
-
this.rl.setPrompt(prompt);
|
|
273318
|
-
this.cursorPos = this.rl.getCursorPos();
|
|
273319
|
-
const width = readlineWidth2();
|
|
273320
|
-
content = breakLines2(content, width);
|
|
273321
|
-
bottomContent = breakLines2(bottomContent, width);
|
|
273322
|
-
if (rawPromptLine.length % width === 0) {
|
|
273323
|
-
content += `
|
|
273324
|
-
`;
|
|
273325
|
-
}
|
|
273326
|
-
let output = content + (bottomContent ? `
|
|
273327
|
-
` + bottomContent : "");
|
|
273328
|
-
const promptLineUpDiff = Math.floor(rawPromptLine.length / width) - this.cursorPos.rows;
|
|
273329
|
-
const bottomContentHeight = promptLineUpDiff + (bottomContent ? height2(bottomContent) : 0);
|
|
273330
|
-
if (bottomContentHeight > 0)
|
|
273331
|
-
output += import_ansi_escapes3.default.cursorUp(bottomContentHeight);
|
|
273332
|
-
output += import_ansi_escapes3.default.cursorTo(this.cursorPos.cols);
|
|
273333
|
-
this.write(cursorDown2(this.extraLinesUnderPrompt) + import_ansi_escapes3.default.eraseLines(this.height) + output);
|
|
273334
|
-
this.extraLinesUnderPrompt = bottomContentHeight;
|
|
273335
|
-
this.height = height2(output);
|
|
273336
|
-
}
|
|
273337
|
-
checkCursorPos() {
|
|
273338
|
-
const cursorPos = this.rl.getCursorPos();
|
|
273339
|
-
if (cursorPos.cols !== this.cursorPos.cols) {
|
|
273340
|
-
this.write(import_ansi_escapes3.default.cursorTo(cursorPos.cols));
|
|
273341
|
-
this.cursorPos = cursorPos;
|
|
273342
|
-
}
|
|
273343
|
-
}
|
|
273344
|
-
done({ clearContent }) {
|
|
273345
|
-
this.rl.setPrompt("");
|
|
273346
|
-
let output = cursorDown2(this.extraLinesUnderPrompt);
|
|
273347
|
-
output += clearContent ? import_ansi_escapes3.default.eraseLines(this.height) : `
|
|
273348
|
-
`;
|
|
273349
|
-
output += import_ansi_escapes3.default.cursorShow;
|
|
273350
|
-
this.write(output);
|
|
273351
|
-
this.rl.close();
|
|
273352
|
-
}
|
|
273353
|
-
}
|
|
273354
|
-
|
|
273355
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/promise-polyfill.js
|
|
273356
|
-
class PromisePolyfill2 extends Promise {
|
|
273357
|
-
static withResolver() {
|
|
273358
|
-
let resolve6;
|
|
273359
|
-
let reject;
|
|
273360
|
-
const promise = new Promise((res, rej) => {
|
|
273361
|
-
resolve6 = res;
|
|
273362
|
-
reject = rej;
|
|
273363
|
-
});
|
|
273364
|
-
return { promise, resolve: resolve6, reject };
|
|
273365
|
-
}
|
|
273366
|
-
}
|
|
273367
|
-
|
|
273368
|
-
// ../../node_modules/@inquirer/core/dist/esm/lib/create-prompt.js
|
|
273369
|
-
function getCallSites2() {
|
|
273370
|
-
const _prepareStackTrace = Error.prepareStackTrace;
|
|
273371
|
-
try {
|
|
273372
|
-
let result = [];
|
|
273373
|
-
Error.prepareStackTrace = (_5, callSites) => {
|
|
273374
|
-
const callSitesWithoutCurrent = callSites.slice(1);
|
|
273375
|
-
result = callSitesWithoutCurrent;
|
|
273376
|
-
return callSitesWithoutCurrent;
|
|
273377
|
-
};
|
|
273378
|
-
new Error().stack;
|
|
273379
|
-
return result;
|
|
273380
|
-
} finally {
|
|
273381
|
-
Error.prepareStackTrace = _prepareStackTrace;
|
|
273382
|
-
}
|
|
273383
|
-
}
|
|
273384
|
-
function createPrompt2(view) {
|
|
273385
|
-
const callSites = getCallSites2();
|
|
273386
|
-
const callerFilename = callSites[1]?.getFileName?.();
|
|
273387
|
-
const prompt = (config3, context = {}) => {
|
|
273388
|
-
const { input = process.stdin, signal } = context;
|
|
273389
|
-
const cleanups = new Set;
|
|
273390
|
-
const output = new import_mute_stream2.default;
|
|
273391
|
-
output.pipe(context.output ?? process.stdout);
|
|
273392
|
-
const rl = readline4.createInterface({
|
|
273393
|
-
terminal: true,
|
|
273394
|
-
input,
|
|
273395
|
-
output
|
|
273396
|
-
});
|
|
273397
|
-
const screen = new ScreenManager2(rl);
|
|
273398
|
-
const { promise, resolve: resolve6, reject } = PromisePolyfill2.withResolver();
|
|
273399
|
-
const cancel3 = () => reject(new CancelPromptError2);
|
|
273400
|
-
if (signal) {
|
|
273401
|
-
const abort = () => reject(new AbortPromptError2({ cause: signal.reason }));
|
|
273402
|
-
if (signal.aborted) {
|
|
273403
|
-
abort();
|
|
273404
|
-
return Object.assign(promise, { cancel: cancel3 });
|
|
273405
|
-
}
|
|
273406
|
-
signal.addEventListener("abort", abort);
|
|
273407
|
-
cleanups.add(() => signal.removeEventListener("abort", abort));
|
|
273408
|
-
}
|
|
273409
|
-
cleanups.add(onExit((code2, signal2) => {
|
|
273410
|
-
reject(new ExitPromptError2(`User force closed the prompt with ${code2} ${signal2}`));
|
|
273411
|
-
}));
|
|
273412
|
-
const checkCursorPos = () => screen.checkCursorPos();
|
|
273413
|
-
rl.input.on("keypress", checkCursorPos);
|
|
273414
|
-
cleanups.add(() => rl.input.removeListener("keypress", checkCursorPos));
|
|
273415
|
-
return withHooks2(rl, (cycle) => {
|
|
273416
|
-
const hooksCleanup = AsyncResource6.bind(() => effectScheduler2.clearAll());
|
|
273417
|
-
rl.on("close", hooksCleanup);
|
|
273418
|
-
cleanups.add(() => rl.removeListener("close", hooksCleanup));
|
|
273419
|
-
cycle(() => {
|
|
273420
|
-
try {
|
|
273421
|
-
const nextView = view(config3, (value4) => {
|
|
273422
|
-
setImmediate(() => resolve6(value4));
|
|
273423
|
-
});
|
|
273424
|
-
if (nextView === undefined) {
|
|
273425
|
-
throw new Error(`Prompt functions must return a string.
|
|
273426
|
-
at ${callerFilename}`);
|
|
273427
|
-
}
|
|
273428
|
-
const [content, bottomContent] = typeof nextView === "string" ? [nextView] : nextView;
|
|
273429
|
-
screen.render(content, bottomContent);
|
|
273430
|
-
effectScheduler2.run();
|
|
273431
|
-
} catch (error5) {
|
|
273432
|
-
reject(error5);
|
|
273433
|
-
}
|
|
273434
|
-
});
|
|
273435
|
-
return Object.assign(promise.then((answer) => {
|
|
273436
|
-
effectScheduler2.clearAll();
|
|
273437
|
-
return answer;
|
|
273438
|
-
}, (error5) => {
|
|
273439
|
-
effectScheduler2.clearAll();
|
|
273440
|
-
throw error5;
|
|
273441
|
-
}).finally(() => {
|
|
273442
|
-
cleanups.forEach((cleanup) => cleanup());
|
|
273443
|
-
screen.done({ clearContent: Boolean(context.clearPromptOnDone) });
|
|
273444
|
-
output.end();
|
|
273445
|
-
}).then(() => promise), { cancel: cancel3 });
|
|
273446
|
-
});
|
|
273447
|
-
};
|
|
273448
|
-
return prompt;
|
|
273449
|
-
}
|
|
273450
272708
|
// ../../node_modules/@inquirer/confirm/dist/esm/index.js
|
|
273451
272709
|
function getBooleanValue(value4, defaultValue) {
|
|
273452
272710
|
let answer = defaultValue !== false;
|
|
@@ -273459,19 +272717,19 @@ function getBooleanValue(value4, defaultValue) {
|
|
|
273459
272717
|
function boolToString(value4) {
|
|
273460
272718
|
return value4 ? "Yes" : "No";
|
|
273461
272719
|
}
|
|
273462
|
-
var
|
|
272720
|
+
var esm_default3 = createPrompt((config3, done) => {
|
|
273463
272721
|
const { transformer = boolToString } = config3;
|
|
273464
|
-
const [status, setStatus] =
|
|
273465
|
-
const [value4, setValue] =
|
|
273466
|
-
const theme =
|
|
273467
|
-
const prefix =
|
|
273468
|
-
|
|
273469
|
-
if (
|
|
272722
|
+
const [status, setStatus] = useState("idle");
|
|
272723
|
+
const [value4, setValue] = useState("");
|
|
272724
|
+
const theme = makeTheme(config3.theme);
|
|
272725
|
+
const prefix = usePrefix({ status, theme });
|
|
272726
|
+
useKeypress((key2, rl) => {
|
|
272727
|
+
if (isEnterKey(key2)) {
|
|
273470
272728
|
const answer = getBooleanValue(value4, config3.default);
|
|
273471
272729
|
setValue(transformer(answer));
|
|
273472
272730
|
setStatus("done");
|
|
273473
272731
|
done(answer);
|
|
273474
|
-
} else if (
|
|
272732
|
+
} else if (key2.name === "tab") {
|
|
273475
272733
|
const answer = boolToString(!getBooleanValue(value4, config3.default));
|
|
273476
272734
|
rl.clearLine(0);
|
|
273477
272735
|
rl.write(answer);
|
|
@@ -273491,478 +272749,23 @@ var esm_default4 = createPrompt2((config3, done) => {
|
|
|
273491
272749
|
return `${prefix} ${message}${defaultValue} ${formattedValue}`;
|
|
273492
272750
|
});
|
|
273493
272751
|
|
|
273494
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/key.js
|
|
273495
|
-
var isBackspaceKey2 = (key3) => key3.name === "backspace";
|
|
273496
|
-
var isEnterKey3 = (key3) => key3.name === "enter" || key3.name === "return";
|
|
273497
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/errors.js
|
|
273498
|
-
class AbortPromptError3 extends Error {
|
|
273499
|
-
name = "AbortPromptError";
|
|
273500
|
-
message = "Prompt was aborted";
|
|
273501
|
-
constructor(options) {
|
|
273502
|
-
super();
|
|
273503
|
-
this.cause = options?.cause;
|
|
273504
|
-
}
|
|
273505
|
-
}
|
|
273506
|
-
|
|
273507
|
-
class CancelPromptError3 extends Error {
|
|
273508
|
-
name = "CancelPromptError";
|
|
273509
|
-
message = "Prompt was canceled";
|
|
273510
|
-
}
|
|
273511
|
-
|
|
273512
|
-
class ExitPromptError3 extends Error {
|
|
273513
|
-
name = "ExitPromptError";
|
|
273514
|
-
}
|
|
273515
|
-
|
|
273516
|
-
class HookError3 extends Error {
|
|
273517
|
-
name = "HookError";
|
|
273518
|
-
}
|
|
273519
|
-
|
|
273520
|
-
class ValidationError3 extends Error {
|
|
273521
|
-
name = "ValidationError";
|
|
273522
|
-
}
|
|
273523
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/use-prefix.js
|
|
273524
|
-
import { AsyncResource as AsyncResource8 } from "node:async_hooks";
|
|
273525
|
-
|
|
273526
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/hook-engine.js
|
|
273527
|
-
import { AsyncLocalStorage as AsyncLocalStorage3, AsyncResource as AsyncResource7 } from "node:async_hooks";
|
|
273528
|
-
var hookStorage3 = new AsyncLocalStorage3;
|
|
273529
|
-
function createStore3(rl) {
|
|
273530
|
-
const store = {
|
|
273531
|
-
rl,
|
|
273532
|
-
hooks: [],
|
|
273533
|
-
hooksCleanup: [],
|
|
273534
|
-
hooksEffect: [],
|
|
273535
|
-
index: 0,
|
|
273536
|
-
handleChange() {
|
|
273537
|
-
}
|
|
273538
|
-
};
|
|
273539
|
-
return store;
|
|
273540
|
-
}
|
|
273541
|
-
function withHooks3(rl, cb) {
|
|
273542
|
-
const store = createStore3(rl);
|
|
273543
|
-
return hookStorage3.run(store, () => {
|
|
273544
|
-
function cycle(render) {
|
|
273545
|
-
store.handleChange = () => {
|
|
273546
|
-
store.index = 0;
|
|
273547
|
-
render();
|
|
273548
|
-
};
|
|
273549
|
-
store.handleChange();
|
|
273550
|
-
}
|
|
273551
|
-
return cb(cycle);
|
|
273552
|
-
});
|
|
273553
|
-
}
|
|
273554
|
-
function getStore3() {
|
|
273555
|
-
const store = hookStorage3.getStore();
|
|
273556
|
-
if (!store) {
|
|
273557
|
-
throw new HookError3("[Inquirer] Hook functions can only be called from within a prompt");
|
|
273558
|
-
}
|
|
273559
|
-
return store;
|
|
273560
|
-
}
|
|
273561
|
-
function readline5() {
|
|
273562
|
-
return getStore3().rl;
|
|
273563
|
-
}
|
|
273564
|
-
function withUpdates3(fn) {
|
|
273565
|
-
const wrapped = (...args) => {
|
|
273566
|
-
const store = getStore3();
|
|
273567
|
-
let shouldUpdate = false;
|
|
273568
|
-
const oldHandleChange = store.handleChange;
|
|
273569
|
-
store.handleChange = () => {
|
|
273570
|
-
shouldUpdate = true;
|
|
273571
|
-
};
|
|
273572
|
-
const returnValue = fn(...args);
|
|
273573
|
-
if (shouldUpdate) {
|
|
273574
|
-
oldHandleChange();
|
|
273575
|
-
}
|
|
273576
|
-
store.handleChange = oldHandleChange;
|
|
273577
|
-
return returnValue;
|
|
273578
|
-
};
|
|
273579
|
-
return AsyncResource7.bind(wrapped);
|
|
273580
|
-
}
|
|
273581
|
-
function withPointer3(cb) {
|
|
273582
|
-
const store = getStore3();
|
|
273583
|
-
const { index } = store;
|
|
273584
|
-
const pointer = {
|
|
273585
|
-
get() {
|
|
273586
|
-
return store.hooks[index];
|
|
273587
|
-
},
|
|
273588
|
-
set(value4) {
|
|
273589
|
-
store.hooks[index] = value4;
|
|
273590
|
-
},
|
|
273591
|
-
initialized: index in store.hooks
|
|
273592
|
-
};
|
|
273593
|
-
const returnValue = cb(pointer);
|
|
273594
|
-
store.index++;
|
|
273595
|
-
return returnValue;
|
|
273596
|
-
}
|
|
273597
|
-
function handleChange3() {
|
|
273598
|
-
getStore3().handleChange();
|
|
273599
|
-
}
|
|
273600
|
-
var effectScheduler3 = {
|
|
273601
|
-
queue(cb) {
|
|
273602
|
-
const store = getStore3();
|
|
273603
|
-
const { index } = store;
|
|
273604
|
-
store.hooksEffect.push(() => {
|
|
273605
|
-
store.hooksCleanup[index]?.();
|
|
273606
|
-
const cleanFn = cb(readline5());
|
|
273607
|
-
if (cleanFn != null && typeof cleanFn !== "function") {
|
|
273608
|
-
throw new ValidationError3("useEffect return value must be a cleanup function or nothing.");
|
|
273609
|
-
}
|
|
273610
|
-
store.hooksCleanup[index] = cleanFn;
|
|
273611
|
-
});
|
|
273612
|
-
},
|
|
273613
|
-
run() {
|
|
273614
|
-
const store = getStore3();
|
|
273615
|
-
withUpdates3(() => {
|
|
273616
|
-
store.hooksEffect.forEach((effect) => {
|
|
273617
|
-
effect();
|
|
273618
|
-
});
|
|
273619
|
-
store.hooksEffect.length = 0;
|
|
273620
|
-
})();
|
|
273621
|
-
},
|
|
273622
|
-
clearAll() {
|
|
273623
|
-
const store = getStore3();
|
|
273624
|
-
store.hooksCleanup.forEach((cleanFn) => {
|
|
273625
|
-
cleanFn?.();
|
|
273626
|
-
});
|
|
273627
|
-
store.hooksEffect.length = 0;
|
|
273628
|
-
store.hooksCleanup.length = 0;
|
|
273629
|
-
}
|
|
273630
|
-
};
|
|
273631
|
-
|
|
273632
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/use-state.js
|
|
273633
|
-
function useState3(defaultValue) {
|
|
273634
|
-
return withPointer3((pointer) => {
|
|
273635
|
-
const setFn = (newValue) => {
|
|
273636
|
-
if (pointer.get() !== newValue) {
|
|
273637
|
-
pointer.set(newValue);
|
|
273638
|
-
handleChange3();
|
|
273639
|
-
}
|
|
273640
|
-
};
|
|
273641
|
-
if (pointer.initialized) {
|
|
273642
|
-
return [pointer.get(), setFn];
|
|
273643
|
-
}
|
|
273644
|
-
const value4 = typeof defaultValue === "function" ? defaultValue() : defaultValue;
|
|
273645
|
-
pointer.set(value4);
|
|
273646
|
-
return [value4, setFn];
|
|
273647
|
-
});
|
|
273648
|
-
}
|
|
273649
|
-
|
|
273650
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/use-effect.js
|
|
273651
|
-
function useEffect3(cb, depArray) {
|
|
273652
|
-
withPointer3((pointer) => {
|
|
273653
|
-
const oldDeps = pointer.get();
|
|
273654
|
-
const hasChanged = !Array.isArray(oldDeps) || depArray.some((dep, i6) => !Object.is(dep, oldDeps[i6]));
|
|
273655
|
-
if (hasChanged) {
|
|
273656
|
-
effectScheduler3.queue(cb);
|
|
273657
|
-
}
|
|
273658
|
-
pointer.set(depArray);
|
|
273659
|
-
});
|
|
273660
|
-
}
|
|
273661
|
-
|
|
273662
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/theme.js
|
|
273663
|
-
var import_yoctocolors_cjs5 = __toESM(require_yoctocolors_cjs(), 1);
|
|
273664
|
-
var defaultTheme3 = {
|
|
273665
|
-
prefix: {
|
|
273666
|
-
idle: import_yoctocolors_cjs5.default.blue("?"),
|
|
273667
|
-
done: import_yoctocolors_cjs5.default.green(esm_default.tick)
|
|
273668
|
-
},
|
|
273669
|
-
spinner: {
|
|
273670
|
-
interval: 80,
|
|
273671
|
-
frames: ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"].map((frame) => import_yoctocolors_cjs5.default.yellow(frame))
|
|
273672
|
-
},
|
|
273673
|
-
style: {
|
|
273674
|
-
answer: import_yoctocolors_cjs5.default.cyan,
|
|
273675
|
-
message: import_yoctocolors_cjs5.default.bold,
|
|
273676
|
-
error: (text2) => import_yoctocolors_cjs5.default.red(`> ${text2}`),
|
|
273677
|
-
defaultAnswer: (text2) => import_yoctocolors_cjs5.default.dim(`(${text2})`),
|
|
273678
|
-
help: import_yoctocolors_cjs5.default.dim,
|
|
273679
|
-
highlight: import_yoctocolors_cjs5.default.cyan,
|
|
273680
|
-
key: (text2) => import_yoctocolors_cjs5.default.cyan(import_yoctocolors_cjs5.default.bold(`<${text2}>`))
|
|
273681
|
-
}
|
|
273682
|
-
};
|
|
273683
|
-
|
|
273684
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/make-theme.js
|
|
273685
|
-
function isPlainObject4(value4) {
|
|
273686
|
-
if (typeof value4 !== "object" || value4 === null)
|
|
273687
|
-
return false;
|
|
273688
|
-
let proto = value4;
|
|
273689
|
-
while (Object.getPrototypeOf(proto) !== null) {
|
|
273690
|
-
proto = Object.getPrototypeOf(proto);
|
|
273691
|
-
}
|
|
273692
|
-
return Object.getPrototypeOf(value4) === proto;
|
|
273693
|
-
}
|
|
273694
|
-
function deepMerge4(...objects) {
|
|
273695
|
-
const output = {};
|
|
273696
|
-
for (const obj of objects) {
|
|
273697
|
-
for (const [key3, value4] of Object.entries(obj)) {
|
|
273698
|
-
const prevValue = output[key3];
|
|
273699
|
-
output[key3] = isPlainObject4(prevValue) && isPlainObject4(value4) ? deepMerge4(prevValue, value4) : value4;
|
|
273700
|
-
}
|
|
273701
|
-
}
|
|
273702
|
-
return output;
|
|
273703
|
-
}
|
|
273704
|
-
function makeTheme3(...themes) {
|
|
273705
|
-
const themesToMerge = [
|
|
273706
|
-
defaultTheme3,
|
|
273707
|
-
...themes.filter((theme) => theme != null)
|
|
273708
|
-
];
|
|
273709
|
-
return deepMerge4(...themesToMerge);
|
|
273710
|
-
}
|
|
273711
|
-
|
|
273712
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/use-prefix.js
|
|
273713
|
-
function usePrefix3({ status = "idle", theme }) {
|
|
273714
|
-
const [showLoader, setShowLoader] = useState3(false);
|
|
273715
|
-
const [tick, setTick] = useState3(0);
|
|
273716
|
-
const { prefix, spinner: spinner2 } = makeTheme3(theme);
|
|
273717
|
-
useEffect3(() => {
|
|
273718
|
-
if (status === "loading") {
|
|
273719
|
-
let tickInterval;
|
|
273720
|
-
let inc = -1;
|
|
273721
|
-
const delayTimeout = setTimeout(AsyncResource8.bind(() => {
|
|
273722
|
-
setShowLoader(true);
|
|
273723
|
-
tickInterval = setInterval(AsyncResource8.bind(() => {
|
|
273724
|
-
inc = inc + 1;
|
|
273725
|
-
setTick(inc % spinner2.frames.length);
|
|
273726
|
-
}), spinner2.interval);
|
|
273727
|
-
}), 300);
|
|
273728
|
-
return () => {
|
|
273729
|
-
clearTimeout(delayTimeout);
|
|
273730
|
-
clearInterval(tickInterval);
|
|
273731
|
-
};
|
|
273732
|
-
} else {
|
|
273733
|
-
setShowLoader(false);
|
|
273734
|
-
}
|
|
273735
|
-
}, [status]);
|
|
273736
|
-
if (showLoader) {
|
|
273737
|
-
return spinner2.frames[tick];
|
|
273738
|
-
}
|
|
273739
|
-
const iconName = status === "loading" ? "idle" : status;
|
|
273740
|
-
return typeof prefix === "string" ? prefix : prefix[iconName] ?? prefix["idle"];
|
|
273741
|
-
}
|
|
273742
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/use-ref.js
|
|
273743
|
-
function useRef3(val) {
|
|
273744
|
-
return useState3({ current: val })[0];
|
|
273745
|
-
}
|
|
273746
|
-
|
|
273747
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/use-keypress.js
|
|
273748
|
-
function useKeypress3(userHandler) {
|
|
273749
|
-
const signal = useRef3(userHandler);
|
|
273750
|
-
signal.current = userHandler;
|
|
273751
|
-
useEffect3((rl) => {
|
|
273752
|
-
let ignore = false;
|
|
273753
|
-
const handler = withUpdates3((_input, event) => {
|
|
273754
|
-
if (ignore)
|
|
273755
|
-
return;
|
|
273756
|
-
signal.current(event, rl);
|
|
273757
|
-
});
|
|
273758
|
-
rl.input.on("keypress", handler);
|
|
273759
|
-
return () => {
|
|
273760
|
-
ignore = true;
|
|
273761
|
-
rl.input.removeListener("keypress", handler);
|
|
273762
|
-
};
|
|
273763
|
-
}, []);
|
|
273764
|
-
}
|
|
273765
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/utils.js
|
|
273766
|
-
var import_cli_width3 = __toESM(require_cli_width(), 1);
|
|
273767
|
-
var import_wrap_ansi3 = __toESM(require_wrap_ansi(), 1);
|
|
273768
|
-
function breakLines3(content, width) {
|
|
273769
|
-
return content.split(`
|
|
273770
|
-
`).flatMap((line) => import_wrap_ansi3.default(line, width, { trim: false, hard: true }).split(`
|
|
273771
|
-
`).map((str) => str.trimEnd())).join(`
|
|
273772
|
-
`);
|
|
273773
|
-
}
|
|
273774
|
-
function readlineWidth3() {
|
|
273775
|
-
return import_cli_width3.default({ defaultWidth: 80, output: readline5().output });
|
|
273776
|
-
}
|
|
273777
|
-
|
|
273778
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/create-prompt.js
|
|
273779
|
-
var import_mute_stream3 = __toESM(require_lib12(), 1);
|
|
273780
|
-
import * as readline6 from "node:readline";
|
|
273781
|
-
import { AsyncResource as AsyncResource9 } from "node:async_hooks";
|
|
273782
|
-
|
|
273783
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/screen-manager.js
|
|
273784
|
-
var import_strip_ansi2 = __toESM(require_strip_ansi(), 1);
|
|
273785
|
-
var import_ansi_escapes4 = __toESM(require_ansi_escapes(), 1);
|
|
273786
|
-
var height3 = (content) => content.split(`
|
|
273787
|
-
`).length;
|
|
273788
|
-
var lastLine3 = (content) => content.split(`
|
|
273789
|
-
`).pop() ?? "";
|
|
273790
|
-
function cursorDown3(n6) {
|
|
273791
|
-
return n6 > 0 ? import_ansi_escapes4.default.cursorDown(n6) : "";
|
|
273792
|
-
}
|
|
273793
|
-
|
|
273794
|
-
class ScreenManager3 {
|
|
273795
|
-
rl;
|
|
273796
|
-
height = 0;
|
|
273797
|
-
extraLinesUnderPrompt = 0;
|
|
273798
|
-
cursorPos;
|
|
273799
|
-
constructor(rl) {
|
|
273800
|
-
this.rl = rl;
|
|
273801
|
-
this.rl = rl;
|
|
273802
|
-
this.cursorPos = rl.getCursorPos();
|
|
273803
|
-
}
|
|
273804
|
-
write(content) {
|
|
273805
|
-
this.rl.output.unmute();
|
|
273806
|
-
this.rl.output.write(content);
|
|
273807
|
-
this.rl.output.mute();
|
|
273808
|
-
}
|
|
273809
|
-
render(content, bottomContent = "") {
|
|
273810
|
-
const promptLine = lastLine3(content);
|
|
273811
|
-
const rawPromptLine = import_strip_ansi2.default(promptLine);
|
|
273812
|
-
let prompt = rawPromptLine;
|
|
273813
|
-
if (this.rl.line.length > 0) {
|
|
273814
|
-
prompt = prompt.slice(0, -this.rl.line.length);
|
|
273815
|
-
}
|
|
273816
|
-
this.rl.setPrompt(prompt);
|
|
273817
|
-
this.cursorPos = this.rl.getCursorPos();
|
|
273818
|
-
const width = readlineWidth3();
|
|
273819
|
-
content = breakLines3(content, width);
|
|
273820
|
-
bottomContent = breakLines3(bottomContent, width);
|
|
273821
|
-
if (rawPromptLine.length % width === 0) {
|
|
273822
|
-
content += `
|
|
273823
|
-
`;
|
|
273824
|
-
}
|
|
273825
|
-
let output = content + (bottomContent ? `
|
|
273826
|
-
` + bottomContent : "");
|
|
273827
|
-
const promptLineUpDiff = Math.floor(rawPromptLine.length / width) - this.cursorPos.rows;
|
|
273828
|
-
const bottomContentHeight = promptLineUpDiff + (bottomContent ? height3(bottomContent) : 0);
|
|
273829
|
-
if (bottomContentHeight > 0)
|
|
273830
|
-
output += import_ansi_escapes4.default.cursorUp(bottomContentHeight);
|
|
273831
|
-
output += import_ansi_escapes4.default.cursorTo(this.cursorPos.cols);
|
|
273832
|
-
this.write(cursorDown3(this.extraLinesUnderPrompt) + import_ansi_escapes4.default.eraseLines(this.height) + output);
|
|
273833
|
-
this.extraLinesUnderPrompt = bottomContentHeight;
|
|
273834
|
-
this.height = height3(output);
|
|
273835
|
-
}
|
|
273836
|
-
checkCursorPos() {
|
|
273837
|
-
const cursorPos = this.rl.getCursorPos();
|
|
273838
|
-
if (cursorPos.cols !== this.cursorPos.cols) {
|
|
273839
|
-
this.write(import_ansi_escapes4.default.cursorTo(cursorPos.cols));
|
|
273840
|
-
this.cursorPos = cursorPos;
|
|
273841
|
-
}
|
|
273842
|
-
}
|
|
273843
|
-
done({ clearContent }) {
|
|
273844
|
-
this.rl.setPrompt("");
|
|
273845
|
-
let output = cursorDown3(this.extraLinesUnderPrompt);
|
|
273846
|
-
output += clearContent ? import_ansi_escapes4.default.eraseLines(this.height) : `
|
|
273847
|
-
`;
|
|
273848
|
-
output += import_ansi_escapes4.default.cursorShow;
|
|
273849
|
-
this.write(output);
|
|
273850
|
-
this.rl.close();
|
|
273851
|
-
}
|
|
273852
|
-
}
|
|
273853
|
-
|
|
273854
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/promise-polyfill.js
|
|
273855
|
-
class PromisePolyfill3 extends Promise {
|
|
273856
|
-
static withResolver() {
|
|
273857
|
-
let resolve6;
|
|
273858
|
-
let reject;
|
|
273859
|
-
const promise = new Promise((res, rej) => {
|
|
273860
|
-
resolve6 = res;
|
|
273861
|
-
reject = rej;
|
|
273862
|
-
});
|
|
273863
|
-
return { promise, resolve: resolve6, reject };
|
|
273864
|
-
}
|
|
273865
|
-
}
|
|
273866
|
-
|
|
273867
|
-
// ../../node_modules/@inquirer/input/node_modules/@inquirer/core/dist/esm/lib/create-prompt.js
|
|
273868
|
-
function getCallSites3() {
|
|
273869
|
-
const _prepareStackTrace = Error.prepareStackTrace;
|
|
273870
|
-
try {
|
|
273871
|
-
let result = [];
|
|
273872
|
-
Error.prepareStackTrace = (_5, callSites) => {
|
|
273873
|
-
const callSitesWithoutCurrent = callSites.slice(1);
|
|
273874
|
-
result = callSitesWithoutCurrent;
|
|
273875
|
-
return callSitesWithoutCurrent;
|
|
273876
|
-
};
|
|
273877
|
-
new Error().stack;
|
|
273878
|
-
return result;
|
|
273879
|
-
} finally {
|
|
273880
|
-
Error.prepareStackTrace = _prepareStackTrace;
|
|
273881
|
-
}
|
|
273882
|
-
}
|
|
273883
|
-
function createPrompt3(view) {
|
|
273884
|
-
const callSites = getCallSites3();
|
|
273885
|
-
const callerFilename = callSites[1]?.getFileName?.();
|
|
273886
|
-
const prompt = (config3, context = {}) => {
|
|
273887
|
-
const { input = process.stdin, signal } = context;
|
|
273888
|
-
const cleanups = new Set;
|
|
273889
|
-
const output = new import_mute_stream3.default;
|
|
273890
|
-
output.pipe(context.output ?? process.stdout);
|
|
273891
|
-
const rl = readline6.createInterface({
|
|
273892
|
-
terminal: true,
|
|
273893
|
-
input,
|
|
273894
|
-
output
|
|
273895
|
-
});
|
|
273896
|
-
const screen = new ScreenManager3(rl);
|
|
273897
|
-
const { promise, resolve: resolve6, reject } = PromisePolyfill3.withResolver();
|
|
273898
|
-
const cancel3 = () => reject(new CancelPromptError3);
|
|
273899
|
-
if (signal) {
|
|
273900
|
-
const abort = () => reject(new AbortPromptError3({ cause: signal.reason }));
|
|
273901
|
-
if (signal.aborted) {
|
|
273902
|
-
abort();
|
|
273903
|
-
return Object.assign(promise, { cancel: cancel3 });
|
|
273904
|
-
}
|
|
273905
|
-
signal.addEventListener("abort", abort);
|
|
273906
|
-
cleanups.add(() => signal.removeEventListener("abort", abort));
|
|
273907
|
-
}
|
|
273908
|
-
cleanups.add(onExit((code2, signal2) => {
|
|
273909
|
-
reject(new ExitPromptError3(`User force closed the prompt with ${code2} ${signal2}`));
|
|
273910
|
-
}));
|
|
273911
|
-
const checkCursorPos = () => screen.checkCursorPos();
|
|
273912
|
-
rl.input.on("keypress", checkCursorPos);
|
|
273913
|
-
cleanups.add(() => rl.input.removeListener("keypress", checkCursorPos));
|
|
273914
|
-
return withHooks3(rl, (cycle) => {
|
|
273915
|
-
const hooksCleanup = AsyncResource9.bind(() => effectScheduler3.clearAll());
|
|
273916
|
-
rl.on("close", hooksCleanup);
|
|
273917
|
-
cleanups.add(() => rl.removeListener("close", hooksCleanup));
|
|
273918
|
-
cycle(() => {
|
|
273919
|
-
try {
|
|
273920
|
-
const nextView = view(config3, (value4) => {
|
|
273921
|
-
setImmediate(() => resolve6(value4));
|
|
273922
|
-
});
|
|
273923
|
-
if (nextView === undefined) {
|
|
273924
|
-
throw new Error(`Prompt functions must return a string.
|
|
273925
|
-
at ${callerFilename}`);
|
|
273926
|
-
}
|
|
273927
|
-
const [content, bottomContent] = typeof nextView === "string" ? [nextView] : nextView;
|
|
273928
|
-
screen.render(content, bottomContent);
|
|
273929
|
-
effectScheduler3.run();
|
|
273930
|
-
} catch (error5) {
|
|
273931
|
-
reject(error5);
|
|
273932
|
-
}
|
|
273933
|
-
});
|
|
273934
|
-
return Object.assign(promise.then((answer) => {
|
|
273935
|
-
effectScheduler3.clearAll();
|
|
273936
|
-
return answer;
|
|
273937
|
-
}, (error5) => {
|
|
273938
|
-
effectScheduler3.clearAll();
|
|
273939
|
-
throw error5;
|
|
273940
|
-
}).finally(() => {
|
|
273941
|
-
cleanups.forEach((cleanup) => cleanup());
|
|
273942
|
-
screen.done({ clearContent: Boolean(context.clearPromptOnDone) });
|
|
273943
|
-
output.end();
|
|
273944
|
-
}).then(() => promise), { cancel: cancel3 });
|
|
273945
|
-
});
|
|
273946
|
-
};
|
|
273947
|
-
return prompt;
|
|
273948
|
-
}
|
|
273949
272752
|
// ../../node_modules/@inquirer/input/dist/esm/index.js
|
|
273950
272753
|
var inputTheme = {
|
|
273951
272754
|
validationFailureMode: "keep"
|
|
273952
272755
|
};
|
|
273953
|
-
var
|
|
272756
|
+
var esm_default4 = createPrompt((config3, done) => {
|
|
273954
272757
|
const { required, validate: validate3 = () => true } = config3;
|
|
273955
|
-
const theme =
|
|
273956
|
-
const [status, setStatus] =
|
|
273957
|
-
const [defaultValue = "", setDefaultValue] =
|
|
273958
|
-
const [errorMsg, setError] =
|
|
273959
|
-
const [value4, setValue] =
|
|
273960
|
-
const prefix =
|
|
273961
|
-
|
|
272758
|
+
const theme = makeTheme(inputTheme, config3.theme);
|
|
272759
|
+
const [status, setStatus] = useState("idle");
|
|
272760
|
+
const [defaultValue = "", setDefaultValue] = useState(config3.default);
|
|
272761
|
+
const [errorMsg, setError] = useState();
|
|
272762
|
+
const [value4, setValue] = useState("");
|
|
272763
|
+
const prefix = usePrefix({ status, theme });
|
|
272764
|
+
useKeypress(async (key2, rl) => {
|
|
273962
272765
|
if (status !== "idle") {
|
|
273963
272766
|
return;
|
|
273964
272767
|
}
|
|
273965
|
-
if (
|
|
272768
|
+
if (isEnterKey(key2)) {
|
|
273966
272769
|
const answer = value4 || defaultValue;
|
|
273967
272770
|
setStatus("loading");
|
|
273968
272771
|
const isValid2 = required && !answer ? "You must provide a value" : await validate3(answer);
|
|
@@ -273979,9 +272782,9 @@ var esm_default5 = createPrompt3((config3, done) => {
|
|
|
273979
272782
|
setError(isValid2 || "You must provide a valid value");
|
|
273980
272783
|
setStatus("idle");
|
|
273981
272784
|
}
|
|
273982
|
-
} else if (
|
|
272785
|
+
} else if (isBackspaceKey(key2) && !value4) {
|
|
273983
272786
|
setDefaultValue(undefined);
|
|
273984
|
-
} else if (
|
|
272787
|
+
} else if (key2.name === "tab" && !value4) {
|
|
273985
272788
|
setDefaultValue(undefined);
|
|
273986
272789
|
rl.clearLine(0);
|
|
273987
272790
|
rl.write(defaultValue);
|
|
@@ -274012,474 +272815,20 @@ var esm_default5 = createPrompt3((config3, done) => {
|
|
|
274012
272815
|
];
|
|
274013
272816
|
});
|
|
274014
272817
|
|
|
274015
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/key.js
|
|
274016
|
-
var isEnterKey4 = (key4) => key4.name === "enter" || key4.name === "return";
|
|
274017
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/errors.js
|
|
274018
|
-
class AbortPromptError4 extends Error {
|
|
274019
|
-
name = "AbortPromptError";
|
|
274020
|
-
message = "Prompt was aborted";
|
|
274021
|
-
constructor(options) {
|
|
274022
|
-
super();
|
|
274023
|
-
this.cause = options?.cause;
|
|
274024
|
-
}
|
|
274025
|
-
}
|
|
274026
|
-
|
|
274027
|
-
class CancelPromptError4 extends Error {
|
|
274028
|
-
name = "CancelPromptError";
|
|
274029
|
-
message = "Prompt was canceled";
|
|
274030
|
-
}
|
|
274031
|
-
|
|
274032
|
-
class ExitPromptError4 extends Error {
|
|
274033
|
-
name = "ExitPromptError";
|
|
274034
|
-
}
|
|
274035
|
-
|
|
274036
|
-
class HookError4 extends Error {
|
|
274037
|
-
name = "HookError";
|
|
274038
|
-
}
|
|
274039
|
-
|
|
274040
|
-
class ValidationError4 extends Error {
|
|
274041
|
-
name = "ValidationError";
|
|
274042
|
-
}
|
|
274043
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/use-prefix.js
|
|
274044
|
-
import { AsyncResource as AsyncResource11 } from "node:async_hooks";
|
|
274045
|
-
|
|
274046
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/hook-engine.js
|
|
274047
|
-
import { AsyncLocalStorage as AsyncLocalStorage4, AsyncResource as AsyncResource10 } from "node:async_hooks";
|
|
274048
|
-
var hookStorage4 = new AsyncLocalStorage4;
|
|
274049
|
-
function createStore4(rl) {
|
|
274050
|
-
const store = {
|
|
274051
|
-
rl,
|
|
274052
|
-
hooks: [],
|
|
274053
|
-
hooksCleanup: [],
|
|
274054
|
-
hooksEffect: [],
|
|
274055
|
-
index: 0,
|
|
274056
|
-
handleChange() {
|
|
274057
|
-
}
|
|
274058
|
-
};
|
|
274059
|
-
return store;
|
|
274060
|
-
}
|
|
274061
|
-
function withHooks4(rl, cb) {
|
|
274062
|
-
const store = createStore4(rl);
|
|
274063
|
-
return hookStorage4.run(store, () => {
|
|
274064
|
-
function cycle(render) {
|
|
274065
|
-
store.handleChange = () => {
|
|
274066
|
-
store.index = 0;
|
|
274067
|
-
render();
|
|
274068
|
-
};
|
|
274069
|
-
store.handleChange();
|
|
274070
|
-
}
|
|
274071
|
-
return cb(cycle);
|
|
274072
|
-
});
|
|
274073
|
-
}
|
|
274074
|
-
function getStore4() {
|
|
274075
|
-
const store = hookStorage4.getStore();
|
|
274076
|
-
if (!store) {
|
|
274077
|
-
throw new HookError4("[Inquirer] Hook functions can only be called from within a prompt");
|
|
274078
|
-
}
|
|
274079
|
-
return store;
|
|
274080
|
-
}
|
|
274081
|
-
function readline7() {
|
|
274082
|
-
return getStore4().rl;
|
|
274083
|
-
}
|
|
274084
|
-
function withUpdates4(fn) {
|
|
274085
|
-
const wrapped = (...args) => {
|
|
274086
|
-
const store = getStore4();
|
|
274087
|
-
let shouldUpdate = false;
|
|
274088
|
-
const oldHandleChange = store.handleChange;
|
|
274089
|
-
store.handleChange = () => {
|
|
274090
|
-
shouldUpdate = true;
|
|
274091
|
-
};
|
|
274092
|
-
const returnValue = fn(...args);
|
|
274093
|
-
if (shouldUpdate) {
|
|
274094
|
-
oldHandleChange();
|
|
274095
|
-
}
|
|
274096
|
-
store.handleChange = oldHandleChange;
|
|
274097
|
-
return returnValue;
|
|
274098
|
-
};
|
|
274099
|
-
return AsyncResource10.bind(wrapped);
|
|
274100
|
-
}
|
|
274101
|
-
function withPointer4(cb) {
|
|
274102
|
-
const store = getStore4();
|
|
274103
|
-
const { index } = store;
|
|
274104
|
-
const pointer = {
|
|
274105
|
-
get() {
|
|
274106
|
-
return store.hooks[index];
|
|
274107
|
-
},
|
|
274108
|
-
set(value4) {
|
|
274109
|
-
store.hooks[index] = value4;
|
|
274110
|
-
},
|
|
274111
|
-
initialized: index in store.hooks
|
|
274112
|
-
};
|
|
274113
|
-
const returnValue = cb(pointer);
|
|
274114
|
-
store.index++;
|
|
274115
|
-
return returnValue;
|
|
274116
|
-
}
|
|
274117
|
-
function handleChange4() {
|
|
274118
|
-
getStore4().handleChange();
|
|
274119
|
-
}
|
|
274120
|
-
var effectScheduler4 = {
|
|
274121
|
-
queue(cb) {
|
|
274122
|
-
const store = getStore4();
|
|
274123
|
-
const { index } = store;
|
|
274124
|
-
store.hooksEffect.push(() => {
|
|
274125
|
-
store.hooksCleanup[index]?.();
|
|
274126
|
-
const cleanFn = cb(readline7());
|
|
274127
|
-
if (cleanFn != null && typeof cleanFn !== "function") {
|
|
274128
|
-
throw new ValidationError4("useEffect return value must be a cleanup function or nothing.");
|
|
274129
|
-
}
|
|
274130
|
-
store.hooksCleanup[index] = cleanFn;
|
|
274131
|
-
});
|
|
274132
|
-
},
|
|
274133
|
-
run() {
|
|
274134
|
-
const store = getStore4();
|
|
274135
|
-
withUpdates4(() => {
|
|
274136
|
-
store.hooksEffect.forEach((effect) => {
|
|
274137
|
-
effect();
|
|
274138
|
-
});
|
|
274139
|
-
store.hooksEffect.length = 0;
|
|
274140
|
-
})();
|
|
274141
|
-
},
|
|
274142
|
-
clearAll() {
|
|
274143
|
-
const store = getStore4();
|
|
274144
|
-
store.hooksCleanup.forEach((cleanFn) => {
|
|
274145
|
-
cleanFn?.();
|
|
274146
|
-
});
|
|
274147
|
-
store.hooksEffect.length = 0;
|
|
274148
|
-
store.hooksCleanup.length = 0;
|
|
274149
|
-
}
|
|
274150
|
-
};
|
|
274151
|
-
|
|
274152
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/use-state.js
|
|
274153
|
-
function useState4(defaultValue) {
|
|
274154
|
-
return withPointer4((pointer) => {
|
|
274155
|
-
const setFn = (newValue) => {
|
|
274156
|
-
if (pointer.get() !== newValue) {
|
|
274157
|
-
pointer.set(newValue);
|
|
274158
|
-
handleChange4();
|
|
274159
|
-
}
|
|
274160
|
-
};
|
|
274161
|
-
if (pointer.initialized) {
|
|
274162
|
-
return [pointer.get(), setFn];
|
|
274163
|
-
}
|
|
274164
|
-
const value4 = typeof defaultValue === "function" ? defaultValue() : defaultValue;
|
|
274165
|
-
pointer.set(value4);
|
|
274166
|
-
return [value4, setFn];
|
|
274167
|
-
});
|
|
274168
|
-
}
|
|
274169
|
-
|
|
274170
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/use-effect.js
|
|
274171
|
-
function useEffect4(cb, depArray) {
|
|
274172
|
-
withPointer4((pointer) => {
|
|
274173
|
-
const oldDeps = pointer.get();
|
|
274174
|
-
const hasChanged = !Array.isArray(oldDeps) || depArray.some((dep, i6) => !Object.is(dep, oldDeps[i6]));
|
|
274175
|
-
if (hasChanged) {
|
|
274176
|
-
effectScheduler4.queue(cb);
|
|
274177
|
-
}
|
|
274178
|
-
pointer.set(depArray);
|
|
274179
|
-
});
|
|
274180
|
-
}
|
|
274181
|
-
|
|
274182
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/theme.js
|
|
274183
|
-
var import_yoctocolors_cjs6 = __toESM(require_yoctocolors_cjs(), 1);
|
|
274184
|
-
var defaultTheme4 = {
|
|
274185
|
-
prefix: {
|
|
274186
|
-
idle: import_yoctocolors_cjs6.default.blue("?"),
|
|
274187
|
-
done: import_yoctocolors_cjs6.default.green(esm_default.tick)
|
|
274188
|
-
},
|
|
274189
|
-
spinner: {
|
|
274190
|
-
interval: 80,
|
|
274191
|
-
frames: ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"].map((frame) => import_yoctocolors_cjs6.default.yellow(frame))
|
|
274192
|
-
},
|
|
274193
|
-
style: {
|
|
274194
|
-
answer: import_yoctocolors_cjs6.default.cyan,
|
|
274195
|
-
message: import_yoctocolors_cjs6.default.bold,
|
|
274196
|
-
error: (text2) => import_yoctocolors_cjs6.default.red(`> ${text2}`),
|
|
274197
|
-
defaultAnswer: (text2) => import_yoctocolors_cjs6.default.dim(`(${text2})`),
|
|
274198
|
-
help: import_yoctocolors_cjs6.default.dim,
|
|
274199
|
-
highlight: import_yoctocolors_cjs6.default.cyan,
|
|
274200
|
-
key: (text2) => import_yoctocolors_cjs6.default.cyan(import_yoctocolors_cjs6.default.bold(`<${text2}>`))
|
|
274201
|
-
}
|
|
274202
|
-
};
|
|
274203
|
-
|
|
274204
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/make-theme.js
|
|
274205
|
-
function isPlainObject5(value4) {
|
|
274206
|
-
if (typeof value4 !== "object" || value4 === null)
|
|
274207
|
-
return false;
|
|
274208
|
-
let proto = value4;
|
|
274209
|
-
while (Object.getPrototypeOf(proto) !== null) {
|
|
274210
|
-
proto = Object.getPrototypeOf(proto);
|
|
274211
|
-
}
|
|
274212
|
-
return Object.getPrototypeOf(value4) === proto;
|
|
274213
|
-
}
|
|
274214
|
-
function deepMerge5(...objects) {
|
|
274215
|
-
const output = {};
|
|
274216
|
-
for (const obj of objects) {
|
|
274217
|
-
for (const [key4, value4] of Object.entries(obj)) {
|
|
274218
|
-
const prevValue = output[key4];
|
|
274219
|
-
output[key4] = isPlainObject5(prevValue) && isPlainObject5(value4) ? deepMerge5(prevValue, value4) : value4;
|
|
274220
|
-
}
|
|
274221
|
-
}
|
|
274222
|
-
return output;
|
|
274223
|
-
}
|
|
274224
|
-
function makeTheme4(...themes) {
|
|
274225
|
-
const themesToMerge = [
|
|
274226
|
-
defaultTheme4,
|
|
274227
|
-
...themes.filter((theme) => theme != null)
|
|
274228
|
-
];
|
|
274229
|
-
return deepMerge5(...themesToMerge);
|
|
274230
|
-
}
|
|
274231
|
-
|
|
274232
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/use-prefix.js
|
|
274233
|
-
function usePrefix4({ status = "idle", theme }) {
|
|
274234
|
-
const [showLoader, setShowLoader] = useState4(false);
|
|
274235
|
-
const [tick, setTick] = useState4(0);
|
|
274236
|
-
const { prefix, spinner: spinner2 } = makeTheme4(theme);
|
|
274237
|
-
useEffect4(() => {
|
|
274238
|
-
if (status === "loading") {
|
|
274239
|
-
let tickInterval;
|
|
274240
|
-
let inc = -1;
|
|
274241
|
-
const delayTimeout = setTimeout(AsyncResource11.bind(() => {
|
|
274242
|
-
setShowLoader(true);
|
|
274243
|
-
tickInterval = setInterval(AsyncResource11.bind(() => {
|
|
274244
|
-
inc = inc + 1;
|
|
274245
|
-
setTick(inc % spinner2.frames.length);
|
|
274246
|
-
}), spinner2.interval);
|
|
274247
|
-
}), 300);
|
|
274248
|
-
return () => {
|
|
274249
|
-
clearTimeout(delayTimeout);
|
|
274250
|
-
clearInterval(tickInterval);
|
|
274251
|
-
};
|
|
274252
|
-
} else {
|
|
274253
|
-
setShowLoader(false);
|
|
274254
|
-
}
|
|
274255
|
-
}, [status]);
|
|
274256
|
-
if (showLoader) {
|
|
274257
|
-
return spinner2.frames[tick];
|
|
274258
|
-
}
|
|
274259
|
-
const iconName = status === "loading" ? "idle" : status;
|
|
274260
|
-
return typeof prefix === "string" ? prefix : prefix[iconName] ?? prefix["idle"];
|
|
274261
|
-
}
|
|
274262
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/use-ref.js
|
|
274263
|
-
function useRef4(val) {
|
|
274264
|
-
return useState4({ current: val })[0];
|
|
274265
|
-
}
|
|
274266
|
-
|
|
274267
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/use-keypress.js
|
|
274268
|
-
function useKeypress4(userHandler) {
|
|
274269
|
-
const signal = useRef4(userHandler);
|
|
274270
|
-
signal.current = userHandler;
|
|
274271
|
-
useEffect4((rl) => {
|
|
274272
|
-
let ignore = false;
|
|
274273
|
-
const handler = withUpdates4((_input, event) => {
|
|
274274
|
-
if (ignore)
|
|
274275
|
-
return;
|
|
274276
|
-
signal.current(event, rl);
|
|
274277
|
-
});
|
|
274278
|
-
rl.input.on("keypress", handler);
|
|
274279
|
-
return () => {
|
|
274280
|
-
ignore = true;
|
|
274281
|
-
rl.input.removeListener("keypress", handler);
|
|
274282
|
-
};
|
|
274283
|
-
}, []);
|
|
274284
|
-
}
|
|
274285
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/utils.js
|
|
274286
|
-
var import_cli_width4 = __toESM(require_cli_width(), 1);
|
|
274287
|
-
var import_wrap_ansi4 = __toESM(require_wrap_ansi(), 1);
|
|
274288
|
-
function breakLines4(content, width) {
|
|
274289
|
-
return content.split(`
|
|
274290
|
-
`).flatMap((line) => import_wrap_ansi4.default(line, width, { trim: false, hard: true }).split(`
|
|
274291
|
-
`).map((str) => str.trimEnd())).join(`
|
|
274292
|
-
`);
|
|
274293
|
-
}
|
|
274294
|
-
function readlineWidth4() {
|
|
274295
|
-
return import_cli_width4.default({ defaultWidth: 80, output: readline7().output });
|
|
274296
|
-
}
|
|
274297
|
-
|
|
274298
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/create-prompt.js
|
|
274299
|
-
var import_mute_stream4 = __toESM(require_lib12(), 1);
|
|
274300
|
-
import * as readline8 from "node:readline";
|
|
274301
|
-
import { AsyncResource as AsyncResource12 } from "node:async_hooks";
|
|
274302
|
-
|
|
274303
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/screen-manager.js
|
|
274304
|
-
var import_strip_ansi3 = __toESM(require_strip_ansi(), 1);
|
|
274305
|
-
var import_ansi_escapes5 = __toESM(require_ansi_escapes(), 1);
|
|
274306
|
-
var height4 = (content) => content.split(`
|
|
274307
|
-
`).length;
|
|
274308
|
-
var lastLine4 = (content) => content.split(`
|
|
274309
|
-
`).pop() ?? "";
|
|
274310
|
-
function cursorDown4(n6) {
|
|
274311
|
-
return n6 > 0 ? import_ansi_escapes5.default.cursorDown(n6) : "";
|
|
274312
|
-
}
|
|
274313
|
-
|
|
274314
|
-
class ScreenManager4 {
|
|
274315
|
-
rl;
|
|
274316
|
-
height = 0;
|
|
274317
|
-
extraLinesUnderPrompt = 0;
|
|
274318
|
-
cursorPos;
|
|
274319
|
-
constructor(rl) {
|
|
274320
|
-
this.rl = rl;
|
|
274321
|
-
this.rl = rl;
|
|
274322
|
-
this.cursorPos = rl.getCursorPos();
|
|
274323
|
-
}
|
|
274324
|
-
write(content) {
|
|
274325
|
-
this.rl.output.unmute();
|
|
274326
|
-
this.rl.output.write(content);
|
|
274327
|
-
this.rl.output.mute();
|
|
274328
|
-
}
|
|
274329
|
-
render(content, bottomContent = "") {
|
|
274330
|
-
const promptLine = lastLine4(content);
|
|
274331
|
-
const rawPromptLine = import_strip_ansi3.default(promptLine);
|
|
274332
|
-
let prompt = rawPromptLine;
|
|
274333
|
-
if (this.rl.line.length > 0) {
|
|
274334
|
-
prompt = prompt.slice(0, -this.rl.line.length);
|
|
274335
|
-
}
|
|
274336
|
-
this.rl.setPrompt(prompt);
|
|
274337
|
-
this.cursorPos = this.rl.getCursorPos();
|
|
274338
|
-
const width = readlineWidth4();
|
|
274339
|
-
content = breakLines4(content, width);
|
|
274340
|
-
bottomContent = breakLines4(bottomContent, width);
|
|
274341
|
-
if (rawPromptLine.length % width === 0) {
|
|
274342
|
-
content += `
|
|
274343
|
-
`;
|
|
274344
|
-
}
|
|
274345
|
-
let output = content + (bottomContent ? `
|
|
274346
|
-
` + bottomContent : "");
|
|
274347
|
-
const promptLineUpDiff = Math.floor(rawPromptLine.length / width) - this.cursorPos.rows;
|
|
274348
|
-
const bottomContentHeight = promptLineUpDiff + (bottomContent ? height4(bottomContent) : 0);
|
|
274349
|
-
if (bottomContentHeight > 0)
|
|
274350
|
-
output += import_ansi_escapes5.default.cursorUp(bottomContentHeight);
|
|
274351
|
-
output += import_ansi_escapes5.default.cursorTo(this.cursorPos.cols);
|
|
274352
|
-
this.write(cursorDown4(this.extraLinesUnderPrompt) + import_ansi_escapes5.default.eraseLines(this.height) + output);
|
|
274353
|
-
this.extraLinesUnderPrompt = bottomContentHeight;
|
|
274354
|
-
this.height = height4(output);
|
|
274355
|
-
}
|
|
274356
|
-
checkCursorPos() {
|
|
274357
|
-
const cursorPos = this.rl.getCursorPos();
|
|
274358
|
-
if (cursorPos.cols !== this.cursorPos.cols) {
|
|
274359
|
-
this.write(import_ansi_escapes5.default.cursorTo(cursorPos.cols));
|
|
274360
|
-
this.cursorPos = cursorPos;
|
|
274361
|
-
}
|
|
274362
|
-
}
|
|
274363
|
-
done({ clearContent }) {
|
|
274364
|
-
this.rl.setPrompt("");
|
|
274365
|
-
let output = cursorDown4(this.extraLinesUnderPrompt);
|
|
274366
|
-
output += clearContent ? import_ansi_escapes5.default.eraseLines(this.height) : `
|
|
274367
|
-
`;
|
|
274368
|
-
output += import_ansi_escapes5.default.cursorShow;
|
|
274369
|
-
this.write(output);
|
|
274370
|
-
this.rl.close();
|
|
274371
|
-
}
|
|
274372
|
-
}
|
|
274373
|
-
|
|
274374
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/promise-polyfill.js
|
|
274375
|
-
class PromisePolyfill4 extends Promise {
|
|
274376
|
-
static withResolver() {
|
|
274377
|
-
let resolve6;
|
|
274378
|
-
let reject;
|
|
274379
|
-
const promise = new Promise((res, rej) => {
|
|
274380
|
-
resolve6 = res;
|
|
274381
|
-
reject = rej;
|
|
274382
|
-
});
|
|
274383
|
-
return { promise, resolve: resolve6, reject };
|
|
274384
|
-
}
|
|
274385
|
-
}
|
|
274386
|
-
|
|
274387
|
-
// ../../node_modules/@inquirer/password/node_modules/@inquirer/core/dist/esm/lib/create-prompt.js
|
|
274388
|
-
function getCallSites4() {
|
|
274389
|
-
const _prepareStackTrace = Error.prepareStackTrace;
|
|
274390
|
-
try {
|
|
274391
|
-
let result = [];
|
|
274392
|
-
Error.prepareStackTrace = (_5, callSites) => {
|
|
274393
|
-
const callSitesWithoutCurrent = callSites.slice(1);
|
|
274394
|
-
result = callSitesWithoutCurrent;
|
|
274395
|
-
return callSitesWithoutCurrent;
|
|
274396
|
-
};
|
|
274397
|
-
new Error().stack;
|
|
274398
|
-
return result;
|
|
274399
|
-
} finally {
|
|
274400
|
-
Error.prepareStackTrace = _prepareStackTrace;
|
|
274401
|
-
}
|
|
274402
|
-
}
|
|
274403
|
-
function createPrompt4(view) {
|
|
274404
|
-
const callSites = getCallSites4();
|
|
274405
|
-
const callerFilename = callSites[1]?.getFileName?.();
|
|
274406
|
-
const prompt = (config3, context = {}) => {
|
|
274407
|
-
const { input = process.stdin, signal } = context;
|
|
274408
|
-
const cleanups = new Set;
|
|
274409
|
-
const output = new import_mute_stream4.default;
|
|
274410
|
-
output.pipe(context.output ?? process.stdout);
|
|
274411
|
-
const rl = readline8.createInterface({
|
|
274412
|
-
terminal: true,
|
|
274413
|
-
input,
|
|
274414
|
-
output
|
|
274415
|
-
});
|
|
274416
|
-
const screen = new ScreenManager4(rl);
|
|
274417
|
-
const { promise, resolve: resolve6, reject } = PromisePolyfill4.withResolver();
|
|
274418
|
-
const cancel3 = () => reject(new CancelPromptError4);
|
|
274419
|
-
if (signal) {
|
|
274420
|
-
const abort = () => reject(new AbortPromptError4({ cause: signal.reason }));
|
|
274421
|
-
if (signal.aborted) {
|
|
274422
|
-
abort();
|
|
274423
|
-
return Object.assign(promise, { cancel: cancel3 });
|
|
274424
|
-
}
|
|
274425
|
-
signal.addEventListener("abort", abort);
|
|
274426
|
-
cleanups.add(() => signal.removeEventListener("abort", abort));
|
|
274427
|
-
}
|
|
274428
|
-
cleanups.add(onExit((code2, signal2) => {
|
|
274429
|
-
reject(new ExitPromptError4(`User force closed the prompt with ${code2} ${signal2}`));
|
|
274430
|
-
}));
|
|
274431
|
-
const checkCursorPos = () => screen.checkCursorPos();
|
|
274432
|
-
rl.input.on("keypress", checkCursorPos);
|
|
274433
|
-
cleanups.add(() => rl.input.removeListener("keypress", checkCursorPos));
|
|
274434
|
-
return withHooks4(rl, (cycle) => {
|
|
274435
|
-
const hooksCleanup = AsyncResource12.bind(() => effectScheduler4.clearAll());
|
|
274436
|
-
rl.on("close", hooksCleanup);
|
|
274437
|
-
cleanups.add(() => rl.removeListener("close", hooksCleanup));
|
|
274438
|
-
cycle(() => {
|
|
274439
|
-
try {
|
|
274440
|
-
const nextView = view(config3, (value4) => {
|
|
274441
|
-
setImmediate(() => resolve6(value4));
|
|
274442
|
-
});
|
|
274443
|
-
if (nextView === undefined) {
|
|
274444
|
-
throw new Error(`Prompt functions must return a string.
|
|
274445
|
-
at ${callerFilename}`);
|
|
274446
|
-
}
|
|
274447
|
-
const [content, bottomContent] = typeof nextView === "string" ? [nextView] : nextView;
|
|
274448
|
-
screen.render(content, bottomContent);
|
|
274449
|
-
effectScheduler4.run();
|
|
274450
|
-
} catch (error5) {
|
|
274451
|
-
reject(error5);
|
|
274452
|
-
}
|
|
274453
|
-
});
|
|
274454
|
-
return Object.assign(promise.then((answer) => {
|
|
274455
|
-
effectScheduler4.clearAll();
|
|
274456
|
-
return answer;
|
|
274457
|
-
}, (error5) => {
|
|
274458
|
-
effectScheduler4.clearAll();
|
|
274459
|
-
throw error5;
|
|
274460
|
-
}).finally(() => {
|
|
274461
|
-
cleanups.forEach((cleanup) => cleanup());
|
|
274462
|
-
screen.done({ clearContent: Boolean(context.clearPromptOnDone) });
|
|
274463
|
-
output.end();
|
|
274464
|
-
}).then(() => promise), { cancel: cancel3 });
|
|
274465
|
-
});
|
|
274466
|
-
};
|
|
274467
|
-
return prompt;
|
|
274468
|
-
}
|
|
274469
272818
|
// ../../node_modules/@inquirer/password/dist/esm/index.js
|
|
274470
|
-
var
|
|
274471
|
-
var
|
|
272819
|
+
var import_ansi_escapes3 = __toESM(require_ansi_escapes(), 1);
|
|
272820
|
+
var esm_default5 = createPrompt((config3, done) => {
|
|
274472
272821
|
const { validate: validate3 = () => true } = config3;
|
|
274473
|
-
const theme =
|
|
274474
|
-
const [status, setStatus] =
|
|
274475
|
-
const [errorMsg, setError] =
|
|
274476
|
-
const [value4, setValue] =
|
|
274477
|
-
const prefix =
|
|
274478
|
-
|
|
272822
|
+
const theme = makeTheme(config3.theme);
|
|
272823
|
+
const [status, setStatus] = useState("idle");
|
|
272824
|
+
const [errorMsg, setError] = useState();
|
|
272825
|
+
const [value4, setValue] = useState("");
|
|
272826
|
+
const prefix = usePrefix({ status, theme });
|
|
272827
|
+
useKeypress(async (key2, rl) => {
|
|
274479
272828
|
if (status !== "idle") {
|
|
274480
272829
|
return;
|
|
274481
272830
|
}
|
|
274482
|
-
if (
|
|
272831
|
+
if (isEnterKey(key2)) {
|
|
274483
272832
|
const answer = value4;
|
|
274484
272833
|
setStatus("loading");
|
|
274485
272834
|
const isValid2 = await validate3(answer);
|
|
@@ -274504,7 +272853,7 @@ var esm_default6 = createPrompt4((config3, done) => {
|
|
|
274504
272853
|
const maskChar = typeof config3.mask === "string" ? config3.mask : "*";
|
|
274505
272854
|
formattedValue = maskChar.repeat(value4.length);
|
|
274506
272855
|
} else if (status !== "done") {
|
|
274507
|
-
helpTip = `${theme.style.help("[input is masked]")}${
|
|
272856
|
+
helpTip = `${theme.style.help("[input is masked]")}${import_ansi_escapes3.default.cursorHide}`;
|
|
274508
272857
|
}
|
|
274509
272858
|
if (status === "done") {
|
|
274510
272859
|
formattedValue = theme.style.answer(formattedValue);
|
|
@@ -274526,7 +272875,7 @@ async function applicationAccessTokenPrompt(env2, application, settlemint, accep
|
|
|
274526
272875
|
return defaultAccessToken;
|
|
274527
272876
|
}
|
|
274528
272877
|
if (defaultAccessToken) {
|
|
274529
|
-
const keep = await
|
|
272878
|
+
const keep = await esm_default3({
|
|
274530
272879
|
message: "Do you want to use the existing application access token?",
|
|
274531
272880
|
default: true
|
|
274532
272881
|
});
|
|
@@ -274534,12 +272883,12 @@ async function applicationAccessTokenPrompt(env2, application, settlemint, accep
|
|
|
274534
272883
|
return defaultAccessToken;
|
|
274535
272884
|
}
|
|
274536
272885
|
}
|
|
274537
|
-
const create2 = await
|
|
272886
|
+
const create2 = await esm_default3({
|
|
274538
272887
|
message: "Do you want to create a new application access token?",
|
|
274539
272888
|
default: false
|
|
274540
272889
|
});
|
|
274541
272890
|
if (create2) {
|
|
274542
|
-
const name2 = await
|
|
272891
|
+
const name2 = await esm_default4({
|
|
274543
272892
|
message: "How would you like to name this application access token?",
|
|
274544
272893
|
default: `SettleMint CLI (${Date.now()}${process.env.USER ? ` ${process.env.USER}` : ""})`,
|
|
274545
272894
|
required: true,
|
|
@@ -274603,7 +272952,7 @@ async function applicationAccessTokenPrompt(env2, application, settlemint, accep
|
|
|
274603
272952
|
} catch (error5) {
|
|
274604
272953
|
}
|
|
274605
272954
|
}
|
|
274606
|
-
return
|
|
272955
|
+
return esm_default5({
|
|
274607
272956
|
message: "What is the application access token for your application in SettleMint? (format: sm_aat_...)",
|
|
274608
272957
|
validate(value4) {
|
|
274609
272958
|
try {
|
|
@@ -274939,7 +273288,7 @@ async function instancePrompt(env2, accept, freeTextInput = false, isCi = is_in_
|
|
|
274939
273288
|
return sanitizeInstanceUrl(defaultPromptInstance);
|
|
274940
273289
|
}
|
|
274941
273290
|
if (freeTextInput) {
|
|
274942
|
-
const instance = await
|
|
273291
|
+
const instance = await esm_default4({
|
|
274943
273292
|
message: "What is the URL of your SettleMint instance?",
|
|
274944
273293
|
default: defaultPromptInstance,
|
|
274945
273294
|
required: true,
|
|
@@ -275350,7 +273699,7 @@ async function projectNamePrompt(env2, argument) {
|
|
|
275350
273699
|
if (defaultInstance) {
|
|
275351
273700
|
return defaultInstance;
|
|
275352
273701
|
}
|
|
275353
|
-
return
|
|
273702
|
+
return esm_default4({
|
|
275354
273703
|
message: "What is the name of your new SettleMint project?",
|
|
275355
273704
|
default: defaultInstance,
|
|
275356
273705
|
required: true,
|
|
@@ -275576,7 +273925,7 @@ var basename2 = function(p6, extension) {
|
|
|
275576
273925
|
return extension && lastSegment.endsWith(extension) ? lastSegment.slice(0, -extension.length) : lastSegment;
|
|
275577
273926
|
};
|
|
275578
273927
|
// ../../node_modules/defu/dist/defu.mjs
|
|
275579
|
-
function
|
|
273928
|
+
function isPlainObject3(value4) {
|
|
275580
273929
|
if (value4 === null || typeof value4 !== "object") {
|
|
275581
273930
|
return false;
|
|
275582
273931
|
}
|
|
@@ -275593,27 +273942,27 @@ function isPlainObject6(value4) {
|
|
|
275593
273942
|
return true;
|
|
275594
273943
|
}
|
|
275595
273944
|
function _defu(baseObject, defaults2, namespace = ".", merger) {
|
|
275596
|
-
if (!
|
|
273945
|
+
if (!isPlainObject3(defaults2)) {
|
|
275597
273946
|
return _defu(baseObject, {}, namespace, merger);
|
|
275598
273947
|
}
|
|
275599
273948
|
const object = Object.assign({}, defaults2);
|
|
275600
|
-
for (const
|
|
275601
|
-
if (
|
|
273949
|
+
for (const key2 in baseObject) {
|
|
273950
|
+
if (key2 === "__proto__" || key2 === "constructor") {
|
|
275602
273951
|
continue;
|
|
275603
273952
|
}
|
|
275604
|
-
const value4 = baseObject[
|
|
273953
|
+
const value4 = baseObject[key2];
|
|
275605
273954
|
if (value4 === null || value4 === undefined) {
|
|
275606
273955
|
continue;
|
|
275607
273956
|
}
|
|
275608
|
-
if (merger && merger(object,
|
|
273957
|
+
if (merger && merger(object, key2, value4, namespace)) {
|
|
275609
273958
|
continue;
|
|
275610
273959
|
}
|
|
275611
|
-
if (Array.isArray(value4) && Array.isArray(object[
|
|
275612
|
-
object[
|
|
275613
|
-
} else if (
|
|
275614
|
-
object[
|
|
273960
|
+
if (Array.isArray(value4) && Array.isArray(object[key2])) {
|
|
273961
|
+
object[key2] = [...value4, ...object[key2]];
|
|
273962
|
+
} else if (isPlainObject3(value4) && isPlainObject3(object[key2])) {
|
|
273963
|
+
object[key2] = _defu(value4, object[key2], (namespace ? `${namespace}.` : "") + key2.toString(), merger);
|
|
275615
273964
|
} else {
|
|
275616
|
-
object[
|
|
273965
|
+
object[key2] = value4;
|
|
275617
273966
|
}
|
|
275618
273967
|
}
|
|
275619
273968
|
return object;
|
|
@@ -275622,15 +273971,15 @@ function createDefu(merger) {
|
|
|
275622
273971
|
return (...arguments_4) => arguments_4.reduce((p6, c3) => _defu(p6, c3, "", merger), {});
|
|
275623
273972
|
}
|
|
275624
273973
|
var defu = createDefu();
|
|
275625
|
-
var defuFn = createDefu((object,
|
|
275626
|
-
if (object[
|
|
275627
|
-
object[
|
|
273974
|
+
var defuFn = createDefu((object, key2, currentValue) => {
|
|
273975
|
+
if (object[key2] !== undefined && typeof currentValue === "function") {
|
|
273976
|
+
object[key2] = currentValue(object[key2]);
|
|
275628
273977
|
return true;
|
|
275629
273978
|
}
|
|
275630
273979
|
});
|
|
275631
|
-
var defuArrayFn = createDefu((object,
|
|
275632
|
-
if (Array.isArray(object[
|
|
275633
|
-
object[
|
|
273980
|
+
var defuArrayFn = createDefu((object, key2, currentValue) => {
|
|
273981
|
+
if (Array.isArray(object[key2]) && typeof currentValue === "function") {
|
|
273982
|
+
object[key2] = currentValue(object[key2]);
|
|
275634
273983
|
return true;
|
|
275635
273984
|
}
|
|
275636
273985
|
});
|
|
@@ -275892,11 +274241,11 @@ function cacheDirectory() {
|
|
|
275892
274241
|
}
|
|
275893
274242
|
function normalizeHeaders(headers = {}) {
|
|
275894
274243
|
const normalized = {};
|
|
275895
|
-
for (const [
|
|
274244
|
+
for (const [key2, value4] of Object.entries(headers)) {
|
|
275896
274245
|
if (!value4) {
|
|
275897
274246
|
continue;
|
|
275898
274247
|
}
|
|
275899
|
-
normalized[
|
|
274248
|
+
normalized[key2.toLowerCase()] = value4;
|
|
275900
274249
|
}
|
|
275901
274250
|
return normalized;
|
|
275902
274251
|
}
|
|
@@ -276172,7 +274521,7 @@ function createCommand2() {
|
|
|
276172
274521
|
await mkdir6(projectDir, { recursive: true });
|
|
276173
274522
|
}
|
|
276174
274523
|
if (!await isEmpty(projectDir)) {
|
|
276175
|
-
const confirmEmpty = await
|
|
274524
|
+
const confirmEmpty = await esm_default3({
|
|
276176
274525
|
message: `The folder ${projectDir} already exists. Do you want to empty it?`,
|
|
276177
274526
|
default: false
|
|
276178
274527
|
});
|
|
@@ -276202,7 +274551,7 @@ async function personalAccessTokenPrompt(env2, instance, accept) {
|
|
|
276202
274551
|
return defaultPersonalAccessToken;
|
|
276203
274552
|
}
|
|
276204
274553
|
if (existingConfig && defaultPersonalAccessToken) {
|
|
276205
|
-
const useExisting = await
|
|
274554
|
+
const useExisting = await esm_default3({
|
|
276206
274555
|
message: `Do you want to use your existing personal access token for ${instance}?`,
|
|
276207
274556
|
default: true
|
|
276208
274557
|
});
|
|
@@ -276210,7 +274559,7 @@ async function personalAccessTokenPrompt(env2, instance, accept) {
|
|
|
276210
274559
|
return defaultPersonalAccessToken;
|
|
276211
274560
|
}
|
|
276212
274561
|
}
|
|
276213
|
-
return
|
|
274562
|
+
return esm_default5({
|
|
276214
274563
|
message: "What is your personal access token in SettleMint? (format: sm_pat_...)",
|
|
276215
274564
|
validate(value4) {
|
|
276216
274565
|
try {
|
|
@@ -277721,7 +276070,7 @@ function createCommand3() {
|
|
|
277721
276070
|
|
|
277722
276071
|
// src/prompts/delete-confirmation.prompt.ts
|
|
277723
276072
|
async function deleteConfirmationPrompt(itemDescription) {
|
|
277724
|
-
const confirmation = await
|
|
276073
|
+
const confirmation = await esm_default4({
|
|
277725
276074
|
message: `Are you sure you want to delete ${itemDescription}? (yes/no)`,
|
|
277726
276075
|
required: true,
|
|
277727
276076
|
validate(value4) {
|
|
@@ -278078,7 +276427,7 @@ function jsonOutput(data) {
|
|
|
278078
276427
|
var composer = require_composer();
|
|
278079
276428
|
var Document = require_Document();
|
|
278080
276429
|
var Schema = require_Schema();
|
|
278081
|
-
var
|
|
276430
|
+
var errors2 = require_errors3();
|
|
278082
276431
|
var Alias = require_Alias();
|
|
278083
276432
|
var identity2 = require_identity();
|
|
278084
276433
|
var Pair = require_Pair();
|
|
@@ -278094,9 +276443,9 @@ var visit2 = require_visit();
|
|
|
278094
276443
|
var $Composer = composer.Composer;
|
|
278095
276444
|
var $Document = Document.Document;
|
|
278096
276445
|
var $Schema = Schema.Schema;
|
|
278097
|
-
var $YAMLError =
|
|
278098
|
-
var $YAMLParseError =
|
|
278099
|
-
var $YAMLWarning =
|
|
276446
|
+
var $YAMLError = errors2.YAMLError;
|
|
276447
|
+
var $YAMLParseError = errors2.YAMLParseError;
|
|
276448
|
+
var $YAMLWarning = errors2.YAMLWarning;
|
|
278100
276449
|
var $Alias = Alias.Alias;
|
|
278101
276450
|
var $isAlias = identity2.isAlias;
|
|
278102
276451
|
var $isCollection = identity2.isCollection;
|
|
@@ -278442,7 +276791,7 @@ async function getServicesAndMapResults({
|
|
|
278442
276791
|
const application = await settlemint.application.read(applicationUniqueName);
|
|
278443
276792
|
const services = await servicesSpinner(settlemint, applicationUniqueName, types2);
|
|
278444
276793
|
const results = (types2 ?? SERVICE_TYPES).filter((serviceType) => !types2 || types2.includes(serviceType)).map((serviceType) => {
|
|
278445
|
-
const [_5, labels] = Object.entries(LABELS_MAP).find(([
|
|
276794
|
+
const [_5, labels] = Object.entries(LABELS_MAP).find(([key2, value4]) => value4.command === serviceType) ?? [
|
|
278446
276795
|
null,
|
|
278447
276796
|
{ plural: serviceType }
|
|
278448
276797
|
];
|
|
@@ -278640,7 +276989,7 @@ function createCommand4() {
|
|
|
278640
276989
|
const targetDir = formatTargetDir(name2);
|
|
278641
276990
|
const projectDir = join10(process.cwd(), targetDir);
|
|
278642
276991
|
if (await exists3(projectDir) && !await isEmpty(projectDir)) {
|
|
278643
|
-
const confirmEmpty = await
|
|
276992
|
+
const confirmEmpty = await esm_default3({
|
|
278644
276993
|
message: `The folder ${projectDir} already exists. Do you want to delete it?`,
|
|
278645
276994
|
default: false
|
|
278646
276995
|
});
|
|
@@ -278670,11 +277019,11 @@ function createCommand4() {
|
|
|
278670
277019
|
|
|
278671
277020
|
// src/utils/commands/passthrough-options.ts
|
|
278672
277021
|
function mapPassthroughOptions(options, command) {
|
|
278673
|
-
const optionArgs = Object.entries(options).map(([
|
|
277022
|
+
const optionArgs = Object.entries(options).map(([key2, value4]) => {
|
|
278674
277023
|
if (value4 === true) {
|
|
278675
|
-
return `--${
|
|
277024
|
+
return `--${key2}`;
|
|
278676
277025
|
}
|
|
278677
|
-
return `--${
|
|
277026
|
+
return `--${key2}=${value4}`;
|
|
278678
277027
|
});
|
|
278679
277028
|
return [...optionArgs, ...command.args];
|
|
278680
277029
|
}
|
|
@@ -279365,7 +277714,7 @@ async function subgraphNamePrompt({
|
|
|
279365
277714
|
}
|
|
279366
277715
|
return defaultSubgraphName ?? env2.SETTLEMINT_THEGRAPH_SUBGRAPH_NAME;
|
|
279367
277716
|
}
|
|
279368
|
-
const subgraphName = await
|
|
277717
|
+
const subgraphName = await esm_default4({
|
|
279369
277718
|
message: "What is the name of your subgraph?",
|
|
279370
277719
|
default: defaultSubgraphName,
|
|
279371
277720
|
required: true
|
|
@@ -279591,4 +277940,4 @@ ${error5.stack}`));
|
|
|
279591
277940
|
// src/cli.ts
|
|
279592
277941
|
sdkCliCommand();
|
|
279593
277942
|
|
|
279594
|
-
//# debugId=
|
|
277943
|
+
//# debugId=DF1BDC962B3ED18364756E2164756E21
|