@ariestools/toolchain 8.6.12 → 8.7.1
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/actions/api-exposure/config.d.ts.map +1 -1
- package/dist/actions/deplint/packageJsonEditor.d.ts +1 -1
- package/dist/actions/deplint/ruleConfig.d.ts.map +1 -1
- package/dist/actions/deplint/types.d.ts +1 -1
- package/dist/actions/gitlint.d.ts +2 -0
- package/dist/actions/gitlint.d.ts.map +1 -1
- package/dist/actions/license.d.ts +4 -0
- package/dist/actions/license.d.ts.map +1 -1
- package/dist/actions/lint.d.ts +11 -2
- package/dist/actions/lint.d.ts.map +1 -1
- package/dist/actions/lintNext.d.ts +22 -1
- package/dist/actions/lintNext.d.ts.map +1 -1
- package/dist/actions/lintNextRun.d.ts +36 -0
- package/dist/actions/lintNextRun.d.ts.map +1 -0
- package/dist/actions/lintNextWorker.d.ts +70 -3
- package/dist/actions/lintNextWorker.d.ts.map +1 -1
- package/dist/actions/lintPackageFilter.d.ts +44 -0
- package/dist/actions/lintPackageFilter.d.ts.map +1 -0
- package/dist/actions/lintlint.d.ts +31 -0
- package/dist/actions/lintlint.d.ts.map +1 -1
- package/dist/actions/node-lint.d.ts +7 -0
- package/dist/actions/node-lint.d.ts.map +1 -1
- package/dist/actions/package/compile/MonolithConfig.d.ts +23 -4
- package/dist/actions/package/compile/MonolithConfig.d.ts.map +1 -1
- package/dist/actions/package/compile/PublintConfig.d.ts +4 -2
- package/dist/actions/package/compile/PublintConfig.d.ts.map +1 -1
- package/dist/actions/package/compile/XyConfig.d.ts +18 -6
- package/dist/actions/package/compile/XyConfig.d.ts.map +1 -1
- package/dist/actions/package/compile/index.d.ts +1 -0
- package/dist/actions/package/compile/index.d.ts.map +1 -1
- package/dist/actions/package/compile/monolithCompileEntries.d.ts +8 -6
- package/dist/actions/package/compile/monolithCompileEntries.d.ts.map +1 -1
- package/dist/actions/package/compile/monolithCompileLayout.d.ts +2 -0
- package/dist/actions/package/compile/monolithCompileLayout.d.ts.map +1 -1
- package/dist/actions/package/compile/monolithReexport.d.ts +45 -0
- package/dist/actions/package/compile/monolithReexport.d.ts.map +1 -0
- package/dist/actions/package/compile/packageCompileMonolith.d.ts.map +1 -1
- package/dist/actions/package/publintRules.d.ts +4 -1
- package/dist/actions/package/publintRules.d.ts.map +1 -1
- package/dist/actions/package-lint.d.ts.map +1 -1
- package/dist/actions/packman/lint.d.ts +14 -0
- package/dist/actions/packman/lint.d.ts.map +1 -1
- package/dist/actions/ruleCatalog.d.ts +4 -2
- package/dist/actions/ruleCatalog.d.ts.map +1 -1
- package/dist/actions/ruleRunner.d.ts +4 -1
- package/dist/actions/ruleRunner.d.ts.map +1 -1
- package/dist/actions/skills/lint.d.ts +13 -0
- package/dist/actions/skills/lint.d.ts.map +1 -1
- package/dist/bin/package/build.mjs +708 -138
- package/dist/bin/package/build.mjs.map +1 -1
- package/dist/bin/package/clean.mjs +214 -47
- package/dist/bin/package/clean.mjs.map +1 -1
- package/dist/bin/package/compile.mjs +545 -104
- package/dist/bin/package/compile.mjs.map +1 -1
- package/dist/bin/package/copy-assets-cjs.mjs +214 -47
- package/dist/bin/package/copy-assets-cjs.mjs.map +1 -1
- package/dist/bin/package/copy-assets-esm.mjs +214 -47
- package/dist/bin/package/copy-assets-esm.mjs.map +1 -1
- package/dist/bin/package/publint.mjs +387 -84
- package/dist/bin/package/publint.mjs.map +1 -1
- package/dist/bin/package/recompile.mjs +545 -104
- package/dist/bin/package/recompile.mjs.map +1 -1
- package/dist/bin/package/sync-layout.mjs +57 -10
- package/dist/bin/package/sync-layout.mjs.map +1 -1
- package/dist/bin/skills.mjs +135 -91
- package/dist/bin/skills.mjs.map +1 -1
- package/dist/bin/source-map-explorer.mjs +7 -2
- package/dist/bin/source-map-explorer.mjs.map +1 -1
- package/dist/bin/xy.mjs +8001 -893
- package/dist/bin/xy.mjs.map +1 -1
- package/dist/lib/index.d.ts +2 -0
- package/dist/lib/index.d.ts.map +1 -1
- package/dist/lib/licenseCheck/checkLicenses.d.ts +23 -0
- package/dist/lib/licenseCheck/checkLicenses.d.ts.map +1 -0
- package/dist/lib/licenseCheck/collectProductionLicenses.d.ts +21 -0
- package/dist/lib/licenseCheck/collectProductionLicenses.d.ts.map +1 -0
- package/dist/lib/licenseCheck/index.d.ts +4 -0
- package/dist/lib/licenseCheck/index.d.ts.map +1 -0
- package/dist/lib/licenseCheck/readPackageLicense.d.ts +25 -0
- package/dist/lib/licenseCheck/readPackageLicense.d.ts.map +1 -0
- package/dist/lib/loadConfig.d.ts +1 -0
- package/dist/lib/loadConfig.d.ts.map +1 -1
- package/dist/lib/ruleCommandRegistry.d.ts +100 -0
- package/dist/lib/ruleCommandRegistry.d.ts.map +1 -0
- package/dist/xy/common/gitCommand.d.ts +3 -0
- package/dist/xy/common/gitCommand.d.ts.map +1 -0
- package/dist/xy/common/gitlintCommand.d.ts +2 -0
- package/dist/xy/common/gitlintCommand.d.ts.map +1 -1
- package/dist/xy/common/index.d.ts.map +1 -1
- package/dist/xy/common/licenseCommand.d.ts.map +1 -1
- package/dist/xy/deprecatedCommand.d.ts +2 -0
- package/dist/xy/deprecatedCommand.d.ts.map +1 -0
- package/dist/xy/lint/cycleCommand.d.ts.map +1 -1
- package/dist/xy/lint/index.d.ts.map +1 -1
- package/dist/xy/lint/lint/index.d.ts.map +1 -1
- package/dist/xy/lint/lint/runCommand.d.ts.map +1 -1
- package/dist/xy/lint/lintlintCommand.d.ts +2 -0
- package/dist/xy/lint/lintlintCommand.d.ts.map +1 -1
- package/dist/xy/lint/nodeCommand.d.ts +3 -0
- package/dist/xy/lint/nodeCommand.d.ts.map +1 -0
- package/dist/xy/lint/nodeLintCommand.d.ts +2 -0
- package/dist/xy/lint/nodeLintCommand.d.ts.map +1 -1
- package/dist/xy/lint/publintCommand.d.ts.map +1 -1
- package/dist/xy/lint/relintCommand.d.ts.map +1 -1
- package/dist/xy/lint/republintCommand.d.ts.map +1 -1
- package/package.json +8 -8
|
@@ -568,10 +568,12 @@ var init_index_min = __esmMin((() => {
|
|
|
568
568
|
body: e.slice(r[0] + s.length, r[1]),
|
|
569
569
|
post: e.slice(r[1] + i.length)
|
|
570
570
|
};
|
|
571
|
-
}
|
|
571
|
+
};
|
|
572
|
+
ce = (n, t) => {
|
|
572
573
|
let e = t.match(n);
|
|
573
574
|
return e ? e[0] : null;
|
|
574
|
-
}
|
|
575
|
+
};
|
|
576
|
+
ss = (n, t, e) => {
|
|
575
577
|
let s, i, r, o, h, a = e.indexOf(n), l = e.indexOf(t, a + 1), u = a;
|
|
576
578
|
if (a >= 0 && l > 0) {
|
|
577
579
|
if (n === t) return [a, l];
|
|
@@ -587,7 +589,22 @@ var init_index_min = __esmMin((() => {
|
|
|
587
589
|
}
|
|
588
590
|
return h;
|
|
589
591
|
};
|
|
590
|
-
fe = "\0SLASH" + Math.random() + "\0"
|
|
592
|
+
fe = "\0SLASH" + Math.random() + "\0";
|
|
593
|
+
ue = "\0OPEN" + Math.random() + "\0";
|
|
594
|
+
qt = "\0CLOSE" + Math.random() + "\0";
|
|
595
|
+
de = "\0COMMA" + Math.random() + "\0";
|
|
596
|
+
pe = "\0PERIOD" + Math.random() + "\0";
|
|
597
|
+
is = new RegExp(fe, "g");
|
|
598
|
+
rs = new RegExp(ue, "g");
|
|
599
|
+
ns = new RegExp(qt, "g");
|
|
600
|
+
os$2 = new RegExp(de, "g");
|
|
601
|
+
hs = new RegExp(pe, "g");
|
|
602
|
+
as = /\\\\/g;
|
|
603
|
+
ls = /\\{/g;
|
|
604
|
+
cs = /\\}/g;
|
|
605
|
+
fs$3 = /\\,/g;
|
|
606
|
+
us = /\\./g;
|
|
607
|
+
ds = 1e5;
|
|
591
608
|
at = (n) => {
|
|
592
609
|
if (typeof n != "string") throw new TypeError("invalid pattern");
|
|
593
610
|
if (n.length > 65536) throw new TypeError("pattern is too long");
|
|
@@ -611,7 +628,11 @@ var init_index_min = __esmMin((() => {
|
|
|
611
628
|
"[:upper:]": ["\\p{Lu}", !0],
|
|
612
629
|
"[:word:]": ["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}", !0],
|
|
613
630
|
"[:xdigit:]": ["A-Fa-f0-9", !1]
|
|
614
|
-
}
|
|
631
|
+
};
|
|
632
|
+
lt = (n) => n.replace(/[[\]\\-]/g, "\\$&");
|
|
633
|
+
Es = (n) => n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
|
|
634
|
+
we = (n) => n.join("");
|
|
635
|
+
ye = (n, t) => {
|
|
615
636
|
let e = t;
|
|
616
637
|
if (n.charAt(e) !== "[") throw new Error("not in a brace expression");
|
|
617
638
|
let s = [], i = [], r = e + 1, o = !1, h = !1, a = !1, l = !1, u = e, c = "";
|
|
@@ -688,7 +709,18 @@ var init_index_min = __esmMin((() => {
|
|
|
688
709
|
"+",
|
|
689
710
|
"*",
|
|
690
711
|
"@"
|
|
691
|
-
])
|
|
712
|
+
]);
|
|
713
|
+
be = (n) => xs.has(n);
|
|
714
|
+
vs = "(?!(?:^|/)\\.\\.?(?:$|/))";
|
|
715
|
+
Ct = "(?!\\.)";
|
|
716
|
+
Cs = /* @__PURE__ */ new Set(["[", "."]);
|
|
717
|
+
Ts = /* @__PURE__ */ new Set(["..", "."]);
|
|
718
|
+
As = /* @__PURE__ */ new Set("().*{}+?[]^$\\!");
|
|
719
|
+
ks = (n) => n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
|
|
720
|
+
Kt = "[^/]";
|
|
721
|
+
Se = Kt + "*?";
|
|
722
|
+
Ee = Kt + "+?";
|
|
723
|
+
Q = class n {
|
|
692
724
|
type;
|
|
693
725
|
#t;
|
|
694
726
|
#s;
|
|
@@ -929,34 +961,60 @@ var init_index_min = __esmMin((() => {
|
|
|
929
961
|
}
|
|
930
962
|
};
|
|
931
963
|
tt = (n, { windowsPathsNoEscape: t = !1, magicalBraces: e = !1 } = {}) => e ? t ? n.replace(/[?*()[\]{}]/g, "[$&]") : n.replace(/[?*()[\]\\{}]/g, "\\$&") : t ? n.replace(/[?*()[\]]/g, "[$&]") : n.replace(/[?*()[\]\\]/g, "\\$&");
|
|
932
|
-
O = (n, t, e = {}) => (at(t), !e.nocomment && t.charAt(0) === "#" ? !1 : new D(t, e).match(n))
|
|
964
|
+
O = (n, t, e = {}) => (at(t), !e.nocomment && t.charAt(0) === "#" ? !1 : new D(t, e).match(n));
|
|
965
|
+
Rs = /^\*+([^+@!?\*\[\(]*)$/;
|
|
966
|
+
Os = (n) => (t) => !t.startsWith(".") && t.endsWith(n);
|
|
967
|
+
Fs = (n) => (t) => t.endsWith(n);
|
|
968
|
+
Ds = (n) => (n = n.toLowerCase(), (t) => !t.startsWith(".") && t.toLowerCase().endsWith(n));
|
|
969
|
+
Ms = (n) => (n = n.toLowerCase(), (t) => t.toLowerCase().endsWith(n));
|
|
970
|
+
Ns = /^\*+\.\*+$/;
|
|
971
|
+
_s = (n) => !n.startsWith(".") && n.includes(".");
|
|
972
|
+
Ls = (n) => n !== "." && n !== ".." && n.includes(".");
|
|
973
|
+
Ws = /^\.\*+$/;
|
|
974
|
+
Ps = (n) => n !== "." && n !== ".." && n.startsWith(".");
|
|
975
|
+
js = /^\*+$/;
|
|
976
|
+
Is = (n) => n.length !== 0 && !n.startsWith(".");
|
|
977
|
+
zs = (n) => n.length !== 0 && n !== "." && n !== "..";
|
|
978
|
+
Bs = /^\?+([^+@!?\*\[\(]*)?$/;
|
|
979
|
+
Us = ([n, t = ""]) => {
|
|
933
980
|
let e = Ce([n]);
|
|
934
981
|
return t ? (t = t.toLowerCase(), (s) => e(s) && s.toLowerCase().endsWith(t)) : e;
|
|
935
|
-
}
|
|
982
|
+
};
|
|
983
|
+
$s = ([n, t = ""]) => {
|
|
936
984
|
let e = Te([n]);
|
|
937
985
|
return t ? (t = t.toLowerCase(), (s) => e(s) && s.toLowerCase().endsWith(t)) : e;
|
|
938
|
-
}
|
|
986
|
+
};
|
|
987
|
+
Gs = ([n, t = ""]) => {
|
|
939
988
|
let e = Te([n]);
|
|
940
989
|
return t ? (s) => e(s) && s.endsWith(t) : e;
|
|
941
|
-
}
|
|
990
|
+
};
|
|
991
|
+
Hs = ([n, t = ""]) => {
|
|
942
992
|
let e = Ce([n]);
|
|
943
993
|
return t ? (s) => e(s) && s.endsWith(t) : e;
|
|
944
|
-
}
|
|
994
|
+
};
|
|
995
|
+
Ce = ([n]) => {
|
|
945
996
|
let t = n.length;
|
|
946
997
|
return (e) => e.length === t && !e.startsWith(".");
|
|
947
|
-
}
|
|
998
|
+
};
|
|
999
|
+
Te = ([n]) => {
|
|
948
1000
|
let t = n.length;
|
|
949
1001
|
return (e) => e.length === t && e !== "." && e !== "..";
|
|
950
|
-
}
|
|
1002
|
+
};
|
|
1003
|
+
Ae = typeof process == "object" && process ? typeof process.env == "object" && process.env && process.env.__MINIMATCH_TESTING_PLATFORM__ || process.platform : "posix";
|
|
1004
|
+
xe = {
|
|
951
1005
|
win32: { sep: "\\" },
|
|
952
1006
|
posix: { sep: "/" }
|
|
953
1007
|
};
|
|
954
1008
|
O.sep = Ae === "win32" ? xe.win32.sep : xe.posix.sep;
|
|
955
1009
|
A = Symbol("globstar **");
|
|
956
1010
|
O.GLOBSTAR = A;
|
|
957
|
-
Vs = "[^/]*?"
|
|
1011
|
+
Vs = "[^/]*?";
|
|
1012
|
+
Ys = "(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?";
|
|
1013
|
+
Xs = "(?:(?!(?:\\/|^)\\.).)*?";
|
|
1014
|
+
Js = (n, t = {}) => (e) => O(e, n, t);
|
|
958
1015
|
O.filter = Js;
|
|
959
|
-
N = (n, t = {}) => Object.assign({}, n, t)
|
|
1016
|
+
N = (n, t = {}) => Object.assign({}, n, t);
|
|
1017
|
+
Zs = (n) => {
|
|
960
1018
|
if (!n || typeof n != "object" || !Object.keys(n).length) return O;
|
|
961
1019
|
let t = O;
|
|
962
1020
|
return Object.assign((s, i, r = {}) => t(s, i, N(n, r)), {
|
|
@@ -997,7 +1055,9 @@ var init_index_min = __esmMin((() => {
|
|
|
997
1055
|
return n = n.filter((i) => s.match(i)), s.options.nonull && !n.length && n.push(t), n;
|
|
998
1056
|
};
|
|
999
1057
|
O.match = ti;
|
|
1000
|
-
ve = /[?*]|[+@!]\(.*?\)|\[|\]
|
|
1058
|
+
ve = /[?*]|[+@!]\(.*?\)|\[|\]/;
|
|
1059
|
+
ei = (n) => n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
|
|
1060
|
+
D = class {
|
|
1001
1061
|
options;
|
|
1002
1062
|
set;
|
|
1003
1063
|
pattern;
|
|
@@ -1281,9 +1341,14 @@ globstar while`, t, d, e, f, m), this.matchOne(t.slice(d), e.slice(f), s)) retur
|
|
|
1281
1341
|
O.Minimatch = D;
|
|
1282
1342
|
O.escape = tt;
|
|
1283
1343
|
O.unescape = W;
|
|
1284
|
-
si = typeof performance == "object" && performance && typeof performance.now == "function" ? performance : Date
|
|
1344
|
+
si = typeof performance == "object" && performance && typeof performance.now == "function" ? performance : Date;
|
|
1345
|
+
Oe = /* @__PURE__ */ new Set();
|
|
1346
|
+
Vt = typeof process == "object" && process ? process : {};
|
|
1347
|
+
Fe = (n, t, e, s) => {
|
|
1285
1348
|
typeof Vt.emitWarning == "function" ? Vt.emitWarning(n, t, e, s) : console.error(`[${e}] ${t}: ${n}`);
|
|
1286
|
-
}
|
|
1349
|
+
};
|
|
1350
|
+
At = globalThis.AbortController;
|
|
1351
|
+
Re = globalThis.AbortSignal;
|
|
1287
1352
|
if (typeof At > "u") {
|
|
1288
1353
|
Re = class {
|
|
1289
1354
|
onabort;
|
|
@@ -1311,11 +1376,14 @@ globstar while`, t, d, e, f, m), this.matchOne(t.slice(d), e.slice(f), s)) retur
|
|
|
1311
1376
|
};
|
|
1312
1377
|
}
|
|
1313
1378
|
ii = (n) => !Oe.has(n);
|
|
1314
|
-
q = (n) => n && n === Math.floor(n) && n > 0 && isFinite(n)
|
|
1379
|
+
q = (n) => n && n === Math.floor(n) && n > 0 && isFinite(n);
|
|
1380
|
+
De = (n) => q(n) ? n <= Math.pow(2, 8) ? Uint8Array : n <= Math.pow(2, 16) ? Uint16Array : n <= Math.pow(2, 32) ? Uint32Array : n <= Number.MAX_SAFE_INTEGER ? Tt : null : null;
|
|
1381
|
+
Tt = class extends Array {
|
|
1315
1382
|
constructor(n) {
|
|
1316
1383
|
super(n), this.fill(0);
|
|
1317
1384
|
}
|
|
1318
|
-
}
|
|
1385
|
+
};
|
|
1386
|
+
ri = class ct {
|
|
1319
1387
|
heap;
|
|
1320
1388
|
length;
|
|
1321
1389
|
static #t = !1;
|
|
@@ -1336,7 +1404,8 @@ globstar while`, t, d, e, f, m), this.matchOne(t.slice(d), e.slice(f), s)) retur
|
|
|
1336
1404
|
pop() {
|
|
1337
1405
|
return this.heap[--this.length];
|
|
1338
1406
|
}
|
|
1339
|
-
}
|
|
1407
|
+
};
|
|
1408
|
+
ft = class Me {
|
|
1340
1409
|
#t;
|
|
1341
1410
|
#s;
|
|
1342
1411
|
#n;
|
|
@@ -1879,7 +1948,47 @@ globstar while`, t, d, e, f, m), this.matchOne(t.slice(d), e.slice(f), s)) retur
|
|
|
1879
1948
|
Ne = typeof process == "object" && process ? process : {
|
|
1880
1949
|
stdout: null,
|
|
1881
1950
|
stderr: null
|
|
1882
|
-
}
|
|
1951
|
+
};
|
|
1952
|
+
oi = (n) => !!n && typeof n == "object" && (n instanceof V || n instanceof Pe || hi(n) || ai(n));
|
|
1953
|
+
hi = (n) => !!n && typeof n == "object" && n instanceof EventEmitter && typeof n.pipe == "function" && n.pipe !== Pe.Writable.prototype.pipe;
|
|
1954
|
+
ai = (n) => !!n && typeof n == "object" && n instanceof EventEmitter && typeof n.write == "function" && typeof n.end == "function";
|
|
1955
|
+
G = Symbol("EOF");
|
|
1956
|
+
H = Symbol("maybeEmitEnd");
|
|
1957
|
+
K = Symbol("emittedEnd");
|
|
1958
|
+
kt = Symbol("emittingEnd");
|
|
1959
|
+
ut = Symbol("emittedError");
|
|
1960
|
+
Rt = Symbol("closed");
|
|
1961
|
+
_e = Symbol("read");
|
|
1962
|
+
Ot = Symbol("flush");
|
|
1963
|
+
Le = Symbol("flushChunk");
|
|
1964
|
+
P = Symbol("encoding");
|
|
1965
|
+
et = Symbol("decoder");
|
|
1966
|
+
v = Symbol("flowing");
|
|
1967
|
+
dt = Symbol("paused");
|
|
1968
|
+
st = Symbol("resume");
|
|
1969
|
+
C = Symbol("buffer");
|
|
1970
|
+
F = Symbol("pipes");
|
|
1971
|
+
T = Symbol("bufferLength");
|
|
1972
|
+
Yt = Symbol("bufferPush");
|
|
1973
|
+
Ft = Symbol("bufferShift");
|
|
1974
|
+
k = Symbol("objectMode");
|
|
1975
|
+
x = Symbol("destroyed");
|
|
1976
|
+
Xt = Symbol("error");
|
|
1977
|
+
Jt = Symbol("emitData");
|
|
1978
|
+
We = Symbol("emitEnd");
|
|
1979
|
+
Zt = Symbol("emitEnd2");
|
|
1980
|
+
B = Symbol("async");
|
|
1981
|
+
Qt = Symbol("abort");
|
|
1982
|
+
Dt = Symbol("aborted");
|
|
1983
|
+
pt = Symbol("signal");
|
|
1984
|
+
Y = Symbol("dataListeners");
|
|
1985
|
+
M = Symbol("discarded");
|
|
1986
|
+
mt = (n) => Promise.resolve().then(n);
|
|
1987
|
+
li = (n) => n();
|
|
1988
|
+
ci = (n) => n === "end" || n === "finish" || n === "prefinish";
|
|
1989
|
+
fi = (n) => n instanceof ArrayBuffer || !!n && typeof n == "object" && n.constructor && n.constructor.name === "ArrayBuffer" && n.byteLength >= 0;
|
|
1990
|
+
ui = (n) => !Buffer.isBuffer(n) && ArrayBuffer.isView(n);
|
|
1991
|
+
Mt = class {
|
|
1883
1992
|
src;
|
|
1884
1993
|
dest;
|
|
1885
1994
|
opts;
|
|
@@ -1894,14 +2003,18 @@ globstar while`, t, d, e, f, m), this.matchOne(t.slice(d), e.slice(f), s)) retur
|
|
|
1894
2003
|
end() {
|
|
1895
2004
|
this.unpipe(), this.opts.end && this.dest.end();
|
|
1896
2005
|
}
|
|
1897
|
-
}
|
|
2006
|
+
};
|
|
2007
|
+
te = class extends Mt {
|
|
1898
2008
|
unpipe() {
|
|
1899
2009
|
this.src.removeListener("error", this.proxyErrors), super.unpipe();
|
|
1900
2010
|
}
|
|
1901
2011
|
constructor(t, e, s) {
|
|
1902
2012
|
super(t, e, s), this.proxyErrors = (i) => this.dest.emit("error", i), t.on("error", this.proxyErrors);
|
|
1903
2013
|
}
|
|
1904
|
-
}
|
|
2014
|
+
};
|
|
2015
|
+
di = (n) => !!n.objectMode;
|
|
2016
|
+
pi = (n) => !n.objectMode && !!n.encoding && n.encoding !== "buffer";
|
|
2017
|
+
V = class extends EventEmitter {
|
|
1905
2018
|
[v] = !1;
|
|
1906
2019
|
[dt] = !1;
|
|
1907
2020
|
[F] = [];
|
|
@@ -2198,7 +2311,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
2198
2311
|
static get isStream() {
|
|
2199
2312
|
return oi;
|
|
2200
2313
|
}
|
|
2201
|
-
}
|
|
2314
|
+
};
|
|
2315
|
+
wt = {
|
|
2202
2316
|
lstatSync,
|
|
2203
2317
|
readdir,
|
|
2204
2318
|
readdirSync,
|
|
@@ -2210,35 +2324,66 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
2210
2324
|
readlink,
|
|
2211
2325
|
realpath
|
|
2212
2326
|
}
|
|
2213
|
-
}
|
|
2327
|
+
};
|
|
2328
|
+
Ue = (n) => !n || n === wt || n === xi ? wt : {
|
|
2214
2329
|
...wt,
|
|
2215
2330
|
...n,
|
|
2216
2331
|
promises: {
|
|
2217
2332
|
...wt.promises,
|
|
2218
2333
|
...n.promises || {}
|
|
2219
2334
|
}
|
|
2220
|
-
}
|
|
2335
|
+
};
|
|
2336
|
+
$e = /^\\\\\?\\([a-z]:)\\?$/i;
|
|
2337
|
+
Ri = (n) => n.replace(/\//g, "\\").replace($e, "$1\\");
|
|
2338
|
+
Oi = /[\\\/]/;
|
|
2339
|
+
L = 0;
|
|
2340
|
+
Ge = 1;
|
|
2341
|
+
He = 2;
|
|
2342
|
+
U = 4;
|
|
2343
|
+
qe = 6;
|
|
2344
|
+
Ke = 8;
|
|
2345
|
+
X = 10;
|
|
2346
|
+
Ve = 12;
|
|
2347
|
+
_ = 15;
|
|
2348
|
+
gt = ~_;
|
|
2349
|
+
se = 16;
|
|
2350
|
+
je = 32;
|
|
2351
|
+
yt = 64;
|
|
2352
|
+
j = 128;
|
|
2353
|
+
Nt = 256;
|
|
2354
|
+
Lt = 512;
|
|
2355
|
+
Ie = yt | j | Lt;
|
|
2356
|
+
Fi = 1023;
|
|
2357
|
+
ie = (n) => n.isFile() ? Ke : n.isDirectory() ? U : n.isSymbolicLink() ? X : n.isCharacterDevice() ? He : n.isBlockDevice() ? qe : n.isSocket() ? Ve : n.isFIFO() ? Ge : L;
|
|
2358
|
+
ze = new ft({ max: 2 ** 12 });
|
|
2359
|
+
bt = (n) => {
|
|
2221
2360
|
let t = ze.get(n);
|
|
2222
2361
|
if (t) return t;
|
|
2223
2362
|
let e = n.normalize("NFKD");
|
|
2224
2363
|
return ze.set(n, e), e;
|
|
2225
|
-
}
|
|
2364
|
+
};
|
|
2365
|
+
Be = new ft({ max: 2 ** 12 });
|
|
2366
|
+
_t = (n) => {
|
|
2226
2367
|
let t = Be.get(n);
|
|
2227
2368
|
if (t) return t;
|
|
2228
2369
|
let e = bt(n.toLowerCase());
|
|
2229
2370
|
return Be.set(n, e), e;
|
|
2230
|
-
}
|
|
2371
|
+
};
|
|
2372
|
+
Wt = class extends ft {
|
|
2231
2373
|
constructor() {
|
|
2232
2374
|
super({ max: 256 });
|
|
2233
2375
|
}
|
|
2234
|
-
}
|
|
2376
|
+
};
|
|
2377
|
+
ne = class extends ft {
|
|
2235
2378
|
constructor(t = 16 * 1024) {
|
|
2236
2379
|
super({
|
|
2237
2380
|
maxSize: t,
|
|
2238
2381
|
sizeCalculation: (e) => e.length + 1
|
|
2239
2382
|
});
|
|
2240
2383
|
}
|
|
2241
|
-
}
|
|
2384
|
+
};
|
|
2385
|
+
Ye = Symbol("PathScurry setAsCwd");
|
|
2386
|
+
R = class {
|
|
2242
2387
|
name;
|
|
2243
2388
|
root;
|
|
2244
2389
|
roots;
|
|
@@ -2651,7 +2796,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
2651
2796
|
for (; i && i.parent;) e.add(i), i.#x = s.join(this.sep), i.#A = s.join("/"), i = i.parent, s.push("..");
|
|
2652
2797
|
for (i = t; i && i.parent && !e.has(i);) i.#x = void 0, i.#A = void 0, i = i.parent;
|
|
2653
2798
|
}
|
|
2654
|
-
}
|
|
2799
|
+
};
|
|
2800
|
+
Pt = class n extends R {
|
|
2655
2801
|
sep = "\\";
|
|
2656
2802
|
splitSep = Oi;
|
|
2657
2803
|
constructor(t, e = L, s, i, r, o, h) {
|
|
@@ -2671,7 +2817,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
2671
2817
|
sameRoot(t, e = this.root.name) {
|
|
2672
2818
|
return t = t.toUpperCase().replace(/\//g, "\\").replace($e, "$1\\"), t === e;
|
|
2673
2819
|
}
|
|
2674
|
-
}
|
|
2820
|
+
};
|
|
2821
|
+
jt = class n extends R {
|
|
2675
2822
|
splitSep = "/";
|
|
2676
2823
|
sep = "/";
|
|
2677
2824
|
constructor(t, e = L, s, i, r, o, h) {
|
|
@@ -2686,7 +2833,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
2686
2833
|
newChild(t, e = L, s = {}) {
|
|
2687
2834
|
return new n(t, e, this.root, this.roots, this.nocase, this.childrenCache(), s);
|
|
2688
2835
|
}
|
|
2689
|
-
}
|
|
2836
|
+
};
|
|
2837
|
+
It = class {
|
|
2690
2838
|
root;
|
|
2691
2839
|
rootPath;
|
|
2692
2840
|
roots;
|
|
@@ -2930,7 +3078,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
2930
3078
|
let e = this.cwd;
|
|
2931
3079
|
this.cwd = typeof t == "string" ? this.cwd.resolve(t) : t, this.cwd[Ye](e);
|
|
2932
3080
|
}
|
|
2933
|
-
}
|
|
3081
|
+
};
|
|
3082
|
+
it = class extends It {
|
|
2934
3083
|
sep = "\\";
|
|
2935
3084
|
constructor(t = process.cwd(), e = {}) {
|
|
2936
3085
|
let { nocase: s = !0 } = e;
|
|
@@ -2949,7 +3098,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
2949
3098
|
isAbsolute(t) {
|
|
2950
3099
|
return t.startsWith("/") || t.startsWith("\\") || /^[a-z]:(\/|\\)/i.test(t);
|
|
2951
3100
|
}
|
|
2952
|
-
}
|
|
3101
|
+
};
|
|
3102
|
+
rt = class extends It {
|
|
2953
3103
|
sep = "/";
|
|
2954
3104
|
constructor(t = process.cwd(), e = {}) {
|
|
2955
3105
|
let { nocase: s = !1 } = e;
|
|
@@ -2967,7 +3117,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
2967
3117
|
isAbsolute(t) {
|
|
2968
3118
|
return t.startsWith("/");
|
|
2969
3119
|
}
|
|
2970
|
-
}
|
|
3120
|
+
};
|
|
3121
|
+
St = class extends rt {
|
|
2971
3122
|
constructor(t = process.cwd(), e = {}) {
|
|
2972
3123
|
let { nocase: s = !0 } = e;
|
|
2973
3124
|
super(t, {
|
|
@@ -2978,7 +3129,10 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
2978
3129
|
};
|
|
2979
3130
|
process.platform;
|
|
2980
3131
|
Xe = process.platform === "win32" ? it : process.platform === "darwin" ? St : rt;
|
|
2981
|
-
Di = (n) => n.length >= 1
|
|
3132
|
+
Di = (n) => n.length >= 1;
|
|
3133
|
+
Mi = (n) => n.length >= 1;
|
|
3134
|
+
Ni = Symbol.for("nodejs.util.inspect.custom");
|
|
3135
|
+
nt = class n {
|
|
2982
3136
|
#t;
|
|
2983
3137
|
#s;
|
|
2984
3138
|
#n;
|
|
@@ -3068,7 +3222,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
3068
3222
|
return this.#n === 0 || !this.isGlobstar() || !this.#u ? !1 : (this.#u = !1, !0);
|
|
3069
3223
|
}
|
|
3070
3224
|
};
|
|
3071
|
-
_i = typeof process == "object" && process && typeof process.platform == "string" ? process.platform : "linux"
|
|
3225
|
+
_i = typeof process == "object" && process && typeof process.platform == "string" ? process.platform : "linux";
|
|
3226
|
+
ot = class {
|
|
3072
3227
|
relative;
|
|
3073
3228
|
relativeChildren;
|
|
3074
3229
|
absolute;
|
|
@@ -3127,7 +3282,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
3127
3282
|
let s = t.fullpath(), i = this.store.get(s);
|
|
3128
3283
|
i ? i.add(e.globString()) : this.store.set(s, /* @__PURE__ */ new Set([e.globString()]));
|
|
3129
3284
|
}
|
|
3130
|
-
}
|
|
3285
|
+
};
|
|
3286
|
+
he = class {
|
|
3131
3287
|
store = /* @__PURE__ */ new Map();
|
|
3132
3288
|
add(t, e, s) {
|
|
3133
3289
|
let i = (e ? 2 : 0) | (s ? 1 : 0), r = this.store.get(t);
|
|
@@ -3140,7 +3296,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
3140
3296
|
!!(e & 1)
|
|
3141
3297
|
]);
|
|
3142
3298
|
}
|
|
3143
|
-
}
|
|
3299
|
+
};
|
|
3300
|
+
ae = class {
|
|
3144
3301
|
store = /* @__PURE__ */ new Map();
|
|
3145
3302
|
add(t, e) {
|
|
3146
3303
|
if (!t.canReaddir()) return;
|
|
@@ -3158,7 +3315,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
3158
3315
|
keys() {
|
|
3159
3316
|
return [...this.store.keys()].filter((t) => t.canReaddir());
|
|
3160
3317
|
}
|
|
3161
|
-
}
|
|
3318
|
+
};
|
|
3319
|
+
Et = class n {
|
|
3162
3320
|
hasWalkedCache;
|
|
3163
3321
|
matches = new he();
|
|
3164
3322
|
subwalks = new ae();
|
|
@@ -3238,7 +3396,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
3238
3396
|
t.isNamed(e) && (s ? this.subwalks.add(t, s) : this.matches.add(t, i, !1));
|
|
3239
3397
|
}
|
|
3240
3398
|
};
|
|
3241
|
-
Li = (n, t) => typeof n == "string" ? new ot([n], t) : Array.isArray(n) ? new ot(n, t) : n
|
|
3399
|
+
Li = (n, t) => typeof n == "string" ? new ot([n], t) : Array.isArray(n) ? new ot(n, t) : n;
|
|
3400
|
+
zt = class {
|
|
3242
3401
|
path;
|
|
3243
3402
|
patterns;
|
|
3244
3403
|
opts;
|
|
@@ -3394,7 +3553,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
3394
3553
|
for (let [h, a] of s.subwalks.entries()) r++, this.walkCB2Sync(h, a, s.child(), o);
|
|
3395
3554
|
o();
|
|
3396
3555
|
}
|
|
3397
|
-
}
|
|
3556
|
+
};
|
|
3557
|
+
xt = class extends zt {
|
|
3398
3558
|
matches = /* @__PURE__ */ new Set();
|
|
3399
3559
|
constructor(t, e, s) {
|
|
3400
3560
|
super(t, e, s);
|
|
@@ -3416,7 +3576,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
3416
3576
|
if (this.signal?.aborted) throw this.signal.reason;
|
|
3417
3577
|
}), this.matches;
|
|
3418
3578
|
}
|
|
3419
|
-
}
|
|
3579
|
+
};
|
|
3580
|
+
vt = class extends zt {
|
|
3420
3581
|
results;
|
|
3421
3582
|
constructor(t, e, s) {
|
|
3422
3583
|
super(t, e, s), this.results = new V({
|
|
@@ -3437,7 +3598,8 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
3437
3598
|
return this.path.isUnknown() && this.path.lstatSync(), this.walkCBSync(this.path, this.patterns, () => this.results.end()), this.results;
|
|
3438
3599
|
}
|
|
3439
3600
|
};
|
|
3440
|
-
Pi = typeof process == "object" && process && typeof process.platform == "string" ? process.platform : "linux"
|
|
3601
|
+
Pi = typeof process == "object" && process && typeof process.platform == "string" ? process.platform : "linux";
|
|
3602
|
+
I = class {
|
|
3441
3603
|
absolute;
|
|
3442
3604
|
cwd;
|
|
3443
3605
|
root;
|
|
@@ -3561,10 +3723,15 @@ while (this[Le](this[Ft]()) && this[C].length);
|
|
|
3561
3723
|
for (let e of n) if (new D(e, t).hasMagic()) return !0;
|
|
3562
3724
|
return !1;
|
|
3563
3725
|
};
|
|
3564
|
-
ji = Bt
|
|
3726
|
+
ji = Bt;
|
|
3727
|
+
Ii = Object.assign(Qe, { sync: Bt });
|
|
3728
|
+
zi = Ut;
|
|
3729
|
+
Bi = Object.assign(es, { sync: Ut });
|
|
3730
|
+
Ui = Object.assign(ts$1, {
|
|
3565
3731
|
stream: Bt,
|
|
3566
3732
|
iterate: Ut
|
|
3567
|
-
})
|
|
3733
|
+
});
|
|
3734
|
+
Ze = Object.assign(Je, {
|
|
3568
3735
|
glob: Je,
|
|
3569
3736
|
globSync: ts$1,
|
|
3570
3737
|
sync: Ui,
|
|
@@ -4780,7 +4947,9 @@ var require_build = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
4780
4947
|
//#endregion
|
|
4781
4948
|
//#region ../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js
|
|
4782
4949
|
var require_picocolors = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
4783
|
-
let p = process || {}
|
|
4950
|
+
let p = process || {};
|
|
4951
|
+
let argv = p.argv || [];
|
|
4952
|
+
let env = p.env || {};
|
|
4784
4953
|
let isColorSupported = !(!!env.NO_COLOR || argv.includes("--no-color")) && (!!env.FORCE_COLOR || argv.includes("--color") || p.platform === "win32" || (p.stdout || {}).isTTY && env.TERM !== "dumb" || !!env.CI);
|
|
4785
4954
|
let formatter = (open, close, replace = open) => (input) => {
|
|
4786
4955
|
let string = "" + input, index = string.indexOf(close, open.length);
|
|
@@ -7950,7 +8119,8 @@ var require_dumper = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
7950
8119
|
} else throw new YAMLException("code point within a string may not be greater than 0xFFFFFFFF");
|
|
7951
8120
|
return "\\" + handle + common.repeat("0", length - string.length) + string;
|
|
7952
8121
|
}
|
|
7953
|
-
var QUOTING_TYPE_SINGLE = 1
|
|
8122
|
+
var QUOTING_TYPE_SINGLE = 1;
|
|
8123
|
+
var QUOTING_TYPE_DOUBLE = 2;
|
|
7954
8124
|
function State(options) {
|
|
7955
8125
|
this.schema = options["schema"] || DEFAULT_SCHEMA;
|
|
7956
8126
|
this.indent = Math.max(1, options["indent"] || 2);
|
|
@@ -8031,7 +8201,11 @@ var require_dumper = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
8031
8201
|
function needIndentIndicator(string) {
|
|
8032
8202
|
return /^\n* /.test(string);
|
|
8033
8203
|
}
|
|
8034
|
-
var STYLE_PLAIN = 1
|
|
8204
|
+
var STYLE_PLAIN = 1;
|
|
8205
|
+
var STYLE_SINGLE = 2;
|
|
8206
|
+
var STYLE_LITERAL = 3;
|
|
8207
|
+
var STYLE_FOLDED = 4;
|
|
8208
|
+
var STYLE_DOUBLE = 5;
|
|
8035
8209
|
function chooseScalarStyle(string, singleLineOnly, indentPerLevel, lineWidth, testAmbiguousType, quotingType, forceQuotes, inblock) {
|
|
8036
8210
|
var i;
|
|
8037
8211
|
var char = 0;
|
|
@@ -9174,8 +9348,8 @@ var require_ExplorerSync = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
9174
9348
|
exports.ExplorerSync = ExplorerSync;
|
|
9175
9349
|
}));
|
|
9176
9350
|
//#endregion
|
|
9177
|
-
//#region
|
|
9178
|
-
var
|
|
9351
|
+
//#region ../../node_modules/.pnpm/cosmiconfig@9.0.2_typescript@6.0.3/node_modules/cosmiconfig/dist/index.js
|
|
9352
|
+
var require_dist = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
9179
9353
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9180
9354
|
exports.defaultLoadersSync = exports.defaultLoaders = exports.globalConfigSearchPlacesSync = exports.globalConfigSearchPlaces = exports.getDefaultSearchPlacesSync = exports.getDefaultSearchPlaces = void 0;
|
|
9181
9355
|
exports.cosmiconfig = cosmiconfig;
|
|
@@ -9307,7 +9481,111 @@ var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
9307
9481
|
clearCaches: explorer.clearCaches.bind(explorer)
|
|
9308
9482
|
};
|
|
9309
9483
|
}
|
|
9310
|
-
}))
|
|
9484
|
+
}));
|
|
9485
|
+
//#endregion
|
|
9486
|
+
//#region src/lib/ruleCommandRegistry.ts
|
|
9487
|
+
const RULE_COMMANDS = {
|
|
9488
|
+
apiExposure: {
|
|
9489
|
+
command: "api-exposure",
|
|
9490
|
+
configKey: "apiExposure",
|
|
9491
|
+
includeInRoot: true,
|
|
9492
|
+
title: "API Exposure Rules"
|
|
9493
|
+
},
|
|
9494
|
+
check: {
|
|
9495
|
+
command: "check",
|
|
9496
|
+
includeInRoot: true,
|
|
9497
|
+
title: "Check Rules"
|
|
9498
|
+
},
|
|
9499
|
+
cycle: {
|
|
9500
|
+
command: "cycle",
|
|
9501
|
+
includeInRoot: true,
|
|
9502
|
+
title: "Cycle Rules"
|
|
9503
|
+
},
|
|
9504
|
+
dead: {
|
|
9505
|
+
command: "dead",
|
|
9506
|
+
configKey: "dead",
|
|
9507
|
+
includeInRoot: true,
|
|
9508
|
+
title: "Dead Rules"
|
|
9509
|
+
},
|
|
9510
|
+
deplint: {
|
|
9511
|
+
command: "deplint",
|
|
9512
|
+
configKey: "deplint",
|
|
9513
|
+
includeInRoot: true,
|
|
9514
|
+
title: "Deplint Rules"
|
|
9515
|
+
},
|
|
9516
|
+
fix: {
|
|
9517
|
+
command: "fix",
|
|
9518
|
+
includeInRoot: false,
|
|
9519
|
+
title: "Fix Rules"
|
|
9520
|
+
},
|
|
9521
|
+
gitLint: {
|
|
9522
|
+
aliases: ["gitlint"],
|
|
9523
|
+
command: "git lint",
|
|
9524
|
+
configKey: "gitLint",
|
|
9525
|
+
includeInRoot: true,
|
|
9526
|
+
title: "Git Lint Rules"
|
|
9527
|
+
},
|
|
9528
|
+
lint: {
|
|
9529
|
+
aliases: ["relint"],
|
|
9530
|
+
command: "lint",
|
|
9531
|
+
includeInRoot: true,
|
|
9532
|
+
title: "Lint Rules"
|
|
9533
|
+
},
|
|
9534
|
+
lintLint: {
|
|
9535
|
+
aliases: ["lintlint"],
|
|
9536
|
+
command: "lint lint",
|
|
9537
|
+
configKey: "lintLint",
|
|
9538
|
+
includeInRoot: true,
|
|
9539
|
+
title: "Lint Lint Rules"
|
|
9540
|
+
},
|
|
9541
|
+
nodeLint: {
|
|
9542
|
+
aliases: ["node-lint"],
|
|
9543
|
+
command: "node lint",
|
|
9544
|
+
configKey: "nodeLint",
|
|
9545
|
+
includeInRoot: true,
|
|
9546
|
+
title: "Node Lint Rules"
|
|
9547
|
+
},
|
|
9548
|
+
packman: {
|
|
9549
|
+
command: "packman lint",
|
|
9550
|
+
configKey: "packman",
|
|
9551
|
+
includeInRoot: true,
|
|
9552
|
+
title: "Packman Lint Rules"
|
|
9553
|
+
},
|
|
9554
|
+
publint: {
|
|
9555
|
+
aliases: ["republint"],
|
|
9556
|
+
command: "publint",
|
|
9557
|
+
configKey: "publint",
|
|
9558
|
+
includeInRoot: true,
|
|
9559
|
+
title: "Publint Rules"
|
|
9560
|
+
},
|
|
9561
|
+
repoLint: {
|
|
9562
|
+
command: "repo lint",
|
|
9563
|
+
configKey: "repoLint",
|
|
9564
|
+
includeInRoot: true,
|
|
9565
|
+
title: "Repo Lint Rules"
|
|
9566
|
+
},
|
|
9567
|
+
skillsLint: {
|
|
9568
|
+
command: "skills lint",
|
|
9569
|
+
configKey: "skillsLint",
|
|
9570
|
+
includeInRoot: true,
|
|
9571
|
+
title: "Skills Lint Rules"
|
|
9572
|
+
}
|
|
9573
|
+
};
|
|
9574
|
+
const DEPRECATED_CONFIG_KEY_ALIASES = {
|
|
9575
|
+
gitLint: ["gitlint"],
|
|
9576
|
+
lintLint: ["lintlint"]
|
|
9577
|
+
};
|
|
9578
|
+
const CONFIG_ALIAS_TO_CANONICAL = new Map(Object.entries(DEPRECATED_CONFIG_KEY_ALIASES).flatMap(([canonical, aliases]) => aliases.map((alias) => [alias, canonical])));
|
|
9579
|
+
const RULE_CONFIG_COMMAND_KEYS = new Set(Object.values(RULE_COMMANDS).flatMap((command) => "configKey" in command ? [command.configKey] : []));
|
|
9580
|
+
function canonicalRuleConfigKey(commandName) {
|
|
9581
|
+
return CONFIG_ALIAS_TO_CANONICAL.get(commandName) ?? commandName;
|
|
9582
|
+
}
|
|
9583
|
+
function deprecatedRuleConfigAliases(configKey) {
|
|
9584
|
+
return Object.entries(DEPRECATED_CONFIG_KEY_ALIASES).find(([canonical]) => canonical === configKey)?.[1] ?? [];
|
|
9585
|
+
}
|
|
9586
|
+
//#endregion
|
|
9587
|
+
//#region src/lib/loadConfig.ts
|
|
9588
|
+
var import_dist = require_dist();
|
|
9311
9589
|
const configState = {
|
|
9312
9590
|
config: void 0,
|
|
9313
9591
|
rootConfigPath: void 0
|
|
@@ -9355,21 +9633,30 @@ async function loadWorkspaceConfig(workspaceDir) {
|
|
|
9355
9633
|
}
|
|
9356
9634
|
/** Deprecated top-level fields that should be under `commands`. */
|
|
9357
9635
|
const DEPRECATED_COMMAND_FIELDS = /* @__PURE__ */ new Set(["deplint", "publint"]);
|
|
9636
|
+
function warnOnce(key, message) {
|
|
9637
|
+
if (deprecationWarned.has(key)) return;
|
|
9638
|
+
deprecationWarned.add(key);
|
|
9639
|
+
console.warn(chalk.yellow(message));
|
|
9640
|
+
}
|
|
9358
9641
|
/**
|
|
9359
9642
|
* Resolves a command's config field from a config object.
|
|
9360
9643
|
* Prefers `commands.[name]` over top-level `[name]`.
|
|
9361
9644
|
* Warns once per config file when a deprecated top-level field is used.
|
|
9362
9645
|
*/
|
|
9363
9646
|
function resolveCommandField(cfg, commandName, configPath) {
|
|
9364
|
-
const
|
|
9365
|
-
|
|
9366
|
-
const
|
|
9367
|
-
if (
|
|
9368
|
-
|
|
9369
|
-
|
|
9370
|
-
|
|
9371
|
-
|
|
9372
|
-
|
|
9647
|
+
const configKey = canonicalRuleConfigKey(commandName);
|
|
9648
|
+
const commands = isRecord$1(cfg.commands) ? cfg.commands : void 0;
|
|
9649
|
+
const fromCommands = commands?.[configKey];
|
|
9650
|
+
if (isRecord$1(fromCommands)) return fromCommands;
|
|
9651
|
+
for (const alias of deprecatedRuleConfigAliases(configKey)) {
|
|
9652
|
+
const fromAlias = commands?.[alias];
|
|
9653
|
+
if (!isRecord$1(fromAlias)) continue;
|
|
9654
|
+
warnOnce(`${configPath ?? "unknown"}:commands.${alias}`, `[xy] Deprecated: "commands.${alias}" in ${configPath ?? "xy.config"} — use "commands.${configKey}"`);
|
|
9655
|
+
return fromAlias;
|
|
9656
|
+
}
|
|
9657
|
+
const fromTopLevel = cfg[configKey];
|
|
9658
|
+
if (fromTopLevel !== void 0 && typeof fromTopLevel === "object" && DEPRECATED_COMMAND_FIELDS.has(configKey)) {
|
|
9659
|
+
warnOnce(`${configPath ?? "unknown"}:${configKey}`, `[xy] Deprecated: top-level "${configKey}" in ${configPath ?? "xy.config"} — move to "commands.${configKey}"`);
|
|
9373
9660
|
return fromTopLevel;
|
|
9374
9661
|
}
|
|
9375
9662
|
return {};
|
|
@@ -9381,20 +9668,9 @@ function mergeRuleConfigs(target, source) {
|
|
|
9381
9668
|
};
|
|
9382
9669
|
return source;
|
|
9383
9670
|
}
|
|
9384
|
-
const RULE_CONFIG_COMMANDS = /* @__PURE__ */ new Set([
|
|
9385
|
-
"apiExposure",
|
|
9386
|
-
"dead",
|
|
9387
|
-
"deplint",
|
|
9388
|
-
"gitlint",
|
|
9389
|
-
"lintlint",
|
|
9390
|
-
"nodeLint",
|
|
9391
|
-
"packman",
|
|
9392
|
-
"publint",
|
|
9393
|
-
"repoLint",
|
|
9394
|
-
"skillsLint"
|
|
9395
|
-
]);
|
|
9396
9671
|
function mergeCommandConfig(rootCmd, workspaceCmd, commandName) {
|
|
9397
|
-
|
|
9672
|
+
const configKey = canonicalRuleConfigKey(commandName);
|
|
9673
|
+
return deepMerge(rootCmd, workspaceCmd, { customMerge: (key) => RULE_CONFIG_COMMAND_KEYS.has(configKey) && key === "rules" ? mergeRuleConfigs : void 0 });
|
|
9398
9674
|
}
|
|
9399
9675
|
/**
|
|
9400
9676
|
* Loads a command-specific config merged from root and workspace levels.
|
|
@@ -9417,8 +9693,9 @@ function isWorkspaceUnderRootConfig(workspaceDir) {
|
|
|
9417
9693
|
return relative === "" || !relative.startsWith("..") && !PATH.isAbsolute(relative);
|
|
9418
9694
|
}
|
|
9419
9695
|
async function loadWorkspaceCommandConfig(workspaceDir, commandName) {
|
|
9696
|
+
const configKey = canonicalRuleConfigKey(commandName);
|
|
9420
9697
|
const root = await loadConfig();
|
|
9421
|
-
return mergeCommandConfig(isWorkspaceUnderRootConfig(workspaceDir) ? resolveCommandField(root,
|
|
9698
|
+
return mergeCommandConfig(isWorkspaceUnderRootConfig(workspaceDir) ? resolveCommandField(root, configKey, configState.rootConfigPath) : {}, resolveCommandField(await loadWorkspaceConfig(workspaceDir), configKey, workspaceConfigCache.has(workspaceDir) ? workspaceDir : void 0), configKey);
|
|
9422
9699
|
}
|
|
9423
9700
|
//#endregion
|
|
9424
9701
|
//#region src/lib/reporting/xyReporter.ts
|
|
@@ -10322,6 +10599,10 @@ const ALL_PUBLINT_CHECKS = [
|
|
|
10322
10599
|
"source",
|
|
10323
10600
|
"types"
|
|
10324
10601
|
];
|
|
10602
|
+
function publintRuleId$1(check) {
|
|
10603
|
+
return `pub.${check}`;
|
|
10604
|
+
}
|
|
10605
|
+
ALL_PUBLINT_CHECKS.map(publintRuleId$1);
|
|
10325
10606
|
/** Checks that only apply to published (non-private) packages */
|
|
10326
10607
|
const PUBLISH_ONLY_CHECKS = [
|
|
10327
10608
|
"defaultExportOrder",
|
|
@@ -11212,9 +11493,19 @@ const PUBLINT_RULE_LEVELS = /* @__PURE__ */ new Set([
|
|
|
11212
11493
|
"off",
|
|
11213
11494
|
"warn"
|
|
11214
11495
|
]);
|
|
11496
|
+
const PUBLINT_RULE_PREFIX = "pub.";
|
|
11497
|
+
const deprecatedPublintRuleWarnings = /* @__PURE__ */ new Set();
|
|
11215
11498
|
function defaultPublintLevel(check) {
|
|
11216
11499
|
return check === "platform" || check === "publint" ? "error" : "warn";
|
|
11217
11500
|
}
|
|
11501
|
+
function publintRuleId(check) {
|
|
11502
|
+
return `${PUBLINT_RULE_PREFIX}${check}`;
|
|
11503
|
+
}
|
|
11504
|
+
function warnDeprecatedPublintRuleName(ruleName) {
|
|
11505
|
+
if (deprecatedPublintRuleWarnings.has(ruleName)) return;
|
|
11506
|
+
deprecatedPublintRuleWarnings.add(ruleName);
|
|
11507
|
+
console.warn(`Deprecated: commands.publint.rules["${ruleName}"] is deprecated; use commands.publint.rules["${publintRuleId(ruleName)}"] instead.`);
|
|
11508
|
+
}
|
|
11218
11509
|
function normalizePublintConfig$2(value) {
|
|
11219
11510
|
if (typeof value === "object") return value;
|
|
11220
11511
|
return {};
|
|
@@ -11222,6 +11513,11 @@ function normalizePublintConfig$2(value) {
|
|
|
11222
11513
|
function isPublintCheckName(value) {
|
|
11223
11514
|
return ALL_PUBLINT_CHECKS.includes(value);
|
|
11224
11515
|
}
|
|
11516
|
+
function normalizePublintRuleName(location, value) {
|
|
11517
|
+
const bareName = value.startsWith(PUBLINT_RULE_PREFIX) ? value.slice(4) : value;
|
|
11518
|
+
if (!isPublintCheckName(bareName)) throw new TypeError(`Unknown publint rule "${value}" in ${location}`);
|
|
11519
|
+
return bareName;
|
|
11520
|
+
}
|
|
11225
11521
|
function isRuleLevel(value) {
|
|
11226
11522
|
return typeof value === "string" && PUBLINT_RULE_LEVELS.has(value);
|
|
11227
11523
|
}
|
|
@@ -11241,10 +11537,7 @@ function parseRuleLevel(location, value) {
|
|
|
11241
11537
|
throw new TypeError(`${location} must be "error", "warn", "off", boolean, [level, options], or { level?, enabled? }`);
|
|
11242
11538
|
}
|
|
11243
11539
|
function normalizePublintRuleNames(location, values) {
|
|
11244
|
-
return (values ?? []).map((value) =>
|
|
11245
|
-
if (!isPublintCheckName(value)) throw new TypeError(`Unknown publint check "${value}" in ${location}`);
|
|
11246
|
-
return value;
|
|
11247
|
-
});
|
|
11540
|
+
return (values ?? []).map((value) => normalizePublintRuleName(location, value));
|
|
11248
11541
|
}
|
|
11249
11542
|
function defaultLevels() {
|
|
11250
11543
|
return new Map(ALL_PUBLINT_CHECKS.map((check) => [check, defaultPublintLevel(check)]));
|
|
@@ -11265,9 +11558,19 @@ function applyExcluded(levels, explicit, exclude) {
|
|
|
11265
11558
|
for (const check of exclude) setRuleLevel(levels, explicit, check, "off");
|
|
11266
11559
|
}
|
|
11267
11560
|
function applyConfiguredRules(levels, explicit, rules) {
|
|
11268
|
-
|
|
11269
|
-
|
|
11270
|
-
|
|
11561
|
+
const configuredRules = Object.entries(rules ?? {});
|
|
11562
|
+
const canonicalRuleIds = new Set(configuredRules.map(([ruleId]) => ruleId).filter((ruleId) => ruleId.startsWith(PUBLINT_RULE_PREFIX)));
|
|
11563
|
+
for (const [check, setting] of configuredRules) {
|
|
11564
|
+
if (check.startsWith(PUBLINT_RULE_PREFIX)) continue;
|
|
11565
|
+
const ruleName = normalizePublintRuleName("commands.publint.rules", check);
|
|
11566
|
+
if (canonicalRuleIds.has(publintRuleId(ruleName))) continue;
|
|
11567
|
+
warnDeprecatedPublintRuleName(ruleName);
|
|
11568
|
+
setRuleLevel(levels, explicit, ruleName, parseRuleLevel(`commands.publint.rules["${publintRuleId(ruleName)}"]`, setting));
|
|
11569
|
+
}
|
|
11570
|
+
for (const [ruleId, setting] of configuredRules) {
|
|
11571
|
+
if (!ruleId.startsWith(PUBLINT_RULE_PREFIX)) continue;
|
|
11572
|
+
const check = normalizePublintRuleName("commands.publint.rules", ruleId);
|
|
11573
|
+
setRuleLevel(levels, explicit, check, parseRuleLevel(`commands.publint.rules["${publintRuleId(check)}"]`, setting));
|
|
11271
11574
|
}
|
|
11272
11575
|
}
|
|
11273
11576
|
function resolvePublintRules(value, cliExclude, cliInclude) {
|
|
@@ -11276,9 +11579,9 @@ function resolvePublintRules(value, cliExclude, cliInclude) {
|
|
|
11276
11579
|
const configInclude = normalizePublintRuleNames("commands.publint.include", config.include);
|
|
11277
11580
|
const normalizedCliExclude = normalizePublintRuleNames("--exclude", cliExclude);
|
|
11278
11581
|
const normalizedCliInclude = normalizePublintRuleNames("--include", cliInclude);
|
|
11582
|
+
if ((configExclude.length > 0 || normalizedCliExclude.length > 0) && (configInclude.length > 0 || normalizedCliInclude.length > 0)) throw new TypeError("Publint: --include and --exclude cannot be used together");
|
|
11279
11583
|
const levels = defaultLevels();
|
|
11280
11584
|
const explicit = /* @__PURE__ */ new Set();
|
|
11281
|
-
if ((configExclude.length > 0 || normalizedCliExclude.length > 0) && (configInclude.length > 0 || normalizedCliInclude.length > 0)) throw new TypeError("Publint: --include and --exclude cannot be used together");
|
|
11282
11585
|
applyIncludedOnly(levels, explicit, configInclude);
|
|
11283
11586
|
applyExcluded(levels, explicit, configExclude);
|
|
11284
11587
|
applyConfiguredRules(levels, explicit, config.rules);
|