semantic-release-lerna 2.11.1 → 2.12.0
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/index.js +739 -513
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1213,6 +1213,7 @@ var require_nerf_dart = __commonJS({
|
|
|
1213
1213
|
// node_modules/semver/internal/constants.js
|
|
1214
1214
|
var require_constants = __commonJS({
|
|
1215
1215
|
"node_modules/semver/internal/constants.js"(exports, module) {
|
|
1216
|
+
"use strict";
|
|
1216
1217
|
var SEMVER_SPEC_VERSION = "2.0.0";
|
|
1217
1218
|
var MAX_LENGTH = 256;
|
|
1218
1219
|
var MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER || /* istanbul ignore next */
|
|
@@ -1244,6 +1245,7 @@ var require_constants = __commonJS({
|
|
|
1244
1245
|
// node_modules/semver/internal/debug.js
|
|
1245
1246
|
var require_debug = __commonJS({
|
|
1246
1247
|
"node_modules/semver/internal/debug.js"(exports, module) {
|
|
1248
|
+
"use strict";
|
|
1247
1249
|
var debug2 = typeof process === "object" && process.env && process.env.NODE_DEBUG && /\bsemver\b/i.test(process.env.NODE_DEBUG) ? (...args) => console.error("SEMVER", ...args) : () => {
|
|
1248
1250
|
};
|
|
1249
1251
|
module.exports = debug2;
|
|
@@ -1253,6 +1255,7 @@ var require_debug = __commonJS({
|
|
|
1253
1255
|
// node_modules/semver/internal/re.js
|
|
1254
1256
|
var require_re = __commonJS({
|
|
1255
1257
|
"node_modules/semver/internal/re.js"(exports, module) {
|
|
1258
|
+
"use strict";
|
|
1256
1259
|
var {
|
|
1257
1260
|
MAX_SAFE_COMPONENT_LENGTH,
|
|
1258
1261
|
MAX_SAFE_BUILD_LENGTH,
|
|
@@ -1293,8 +1296,8 @@ var require_re = __commonJS({
|
|
|
1293
1296
|
createToken("NONNUMERICIDENTIFIER", `\\d*[a-zA-Z-]${LETTERDASHNUMBER}*`);
|
|
1294
1297
|
createToken("MAINVERSION", `(${src[t.NUMERICIDENTIFIER]})\\.(${src[t.NUMERICIDENTIFIER]})\\.(${src[t.NUMERICIDENTIFIER]})`);
|
|
1295
1298
|
createToken("MAINVERSIONLOOSE", `(${src[t.NUMERICIDENTIFIERLOOSE]})\\.(${src[t.NUMERICIDENTIFIERLOOSE]})\\.(${src[t.NUMERICIDENTIFIERLOOSE]})`);
|
|
1296
|
-
createToken("PRERELEASEIDENTIFIER", `(?:${src[t.
|
|
1297
|
-
createToken("PRERELEASEIDENTIFIERLOOSE", `(?:${src[t.
|
|
1299
|
+
createToken("PRERELEASEIDENTIFIER", `(?:${src[t.NONNUMERICIDENTIFIER]}|${src[t.NUMERICIDENTIFIER]})`);
|
|
1300
|
+
createToken("PRERELEASEIDENTIFIERLOOSE", `(?:${src[t.NONNUMERICIDENTIFIER]}|${src[t.NUMERICIDENTIFIERLOOSE]})`);
|
|
1298
1301
|
createToken("PRERELEASE", `(?:-(${src[t.PRERELEASEIDENTIFIER]}(?:\\.${src[t.PRERELEASEIDENTIFIER]})*))`);
|
|
1299
1302
|
createToken("PRERELEASELOOSE", `(?:-?(${src[t.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${src[t.PRERELEASEIDENTIFIERLOOSE]})*))`);
|
|
1300
1303
|
createToken("BUILDIDENTIFIER", `${LETTERDASHNUMBER}+`);
|
|
@@ -1340,6 +1343,7 @@ var require_re = __commonJS({
|
|
|
1340
1343
|
// node_modules/semver/internal/parse-options.js
|
|
1341
1344
|
var require_parse_options = __commonJS({
|
|
1342
1345
|
"node_modules/semver/internal/parse-options.js"(exports, module) {
|
|
1346
|
+
"use strict";
|
|
1343
1347
|
var looseOption = Object.freeze({ loose: true });
|
|
1344
1348
|
var emptyOpts = Object.freeze({});
|
|
1345
1349
|
var parseOptions = (options) => {
|
|
@@ -1358,10 +1362,11 @@ var require_parse_options = __commonJS({
|
|
|
1358
1362
|
// node_modules/semver/internal/identifiers.js
|
|
1359
1363
|
var require_identifiers = __commonJS({
|
|
1360
1364
|
"node_modules/semver/internal/identifiers.js"(exports, module) {
|
|
1361
|
-
|
|
1365
|
+
"use strict";
|
|
1366
|
+
var numeric2 = /^[0-9]+$/;
|
|
1362
1367
|
var compareIdentifiers = (a2, b) => {
|
|
1363
|
-
const anum =
|
|
1364
|
-
const bnum =
|
|
1368
|
+
const anum = numeric2.test(a2);
|
|
1369
|
+
const bnum = numeric2.test(b);
|
|
1365
1370
|
if (anum && bnum) {
|
|
1366
1371
|
a2 = +a2;
|
|
1367
1372
|
b = +b;
|
|
@@ -1379,9 +1384,10 @@ var require_identifiers = __commonJS({
|
|
|
1379
1384
|
// node_modules/semver/classes/semver.js
|
|
1380
1385
|
var require_semver = __commonJS({
|
|
1381
1386
|
"node_modules/semver/classes/semver.js"(exports, module) {
|
|
1387
|
+
"use strict";
|
|
1382
1388
|
var debug2 = require_debug();
|
|
1383
1389
|
var { MAX_LENGTH, MAX_SAFE_INTEGER } = require_constants();
|
|
1384
|
-
var { safeRe: re,
|
|
1390
|
+
var { safeRe: re, t } = require_re();
|
|
1385
1391
|
var parseOptions = require_parse_options();
|
|
1386
1392
|
var { compareIdentifiers } = require_identifiers();
|
|
1387
1393
|
var SemVer = class _SemVer {
|
|
@@ -1526,8 +1532,7 @@ var require_semver = __commonJS({
|
|
|
1526
1532
|
throw new Error("invalid increment argument: identifier is empty");
|
|
1527
1533
|
}
|
|
1528
1534
|
if (identifier) {
|
|
1529
|
-
const
|
|
1530
|
-
const match2 = `-${identifier}`.match(r);
|
|
1535
|
+
const match2 = `-${identifier}`.match(this.options.loose ? re[t.PRERELEASELOOSE] : re[t.PRERELEASE]);
|
|
1531
1536
|
if (!match2 || match2[1] !== identifier) {
|
|
1532
1537
|
throw new Error(`invalid identifier: ${identifier}`);
|
|
1533
1538
|
}
|
|
@@ -1640,6 +1645,7 @@ var require_semver = __commonJS({
|
|
|
1640
1645
|
// node_modules/semver/functions/parse.js
|
|
1641
1646
|
var require_parse2 = __commonJS({
|
|
1642
1647
|
"node_modules/semver/functions/parse.js"(exports, module) {
|
|
1648
|
+
"use strict";
|
|
1643
1649
|
var SemVer = require_semver();
|
|
1644
1650
|
var parse2 = (version, options, throwErrors = false) => {
|
|
1645
1651
|
if (version instanceof SemVer) {
|
|
@@ -1661,6 +1667,7 @@ var require_parse2 = __commonJS({
|
|
|
1661
1667
|
// node_modules/semver/functions/valid.js
|
|
1662
1668
|
var require_valid = __commonJS({
|
|
1663
1669
|
"node_modules/semver/functions/valid.js"(exports, module) {
|
|
1670
|
+
"use strict";
|
|
1664
1671
|
var parse2 = require_parse2();
|
|
1665
1672
|
var valid = (version, options) => {
|
|
1666
1673
|
const v = parse2(version, options);
|
|
@@ -1673,6 +1680,7 @@ var require_valid = __commonJS({
|
|
|
1673
1680
|
// node_modules/semver/functions/clean.js
|
|
1674
1681
|
var require_clean = __commonJS({
|
|
1675
1682
|
"node_modules/semver/functions/clean.js"(exports, module) {
|
|
1683
|
+
"use strict";
|
|
1676
1684
|
var parse2 = require_parse2();
|
|
1677
1685
|
var clean = (version, options) => {
|
|
1678
1686
|
const s = parse2(version.trim().replace(/^[=v]+/, ""), options);
|
|
@@ -1685,6 +1693,7 @@ var require_clean = __commonJS({
|
|
|
1685
1693
|
// node_modules/semver/functions/inc.js
|
|
1686
1694
|
var require_inc = __commonJS({
|
|
1687
1695
|
"node_modules/semver/functions/inc.js"(exports, module) {
|
|
1696
|
+
"use strict";
|
|
1688
1697
|
var SemVer = require_semver();
|
|
1689
1698
|
var inc = (version, release, options, identifier, identifierBase) => {
|
|
1690
1699
|
if (typeof options === "string") {
|
|
@@ -1708,6 +1717,7 @@ var require_inc = __commonJS({
|
|
|
1708
1717
|
// node_modules/semver/functions/diff.js
|
|
1709
1718
|
var require_diff = __commonJS({
|
|
1710
1719
|
"node_modules/semver/functions/diff.js"(exports, module) {
|
|
1720
|
+
"use strict";
|
|
1711
1721
|
var parse2 = require_parse2();
|
|
1712
1722
|
var diff = (version1, version2) => {
|
|
1713
1723
|
const v1 = parse2(version1, null, true);
|
|
@@ -1751,6 +1761,7 @@ var require_diff = __commonJS({
|
|
|
1751
1761
|
// node_modules/semver/functions/major.js
|
|
1752
1762
|
var require_major = __commonJS({
|
|
1753
1763
|
"node_modules/semver/functions/major.js"(exports, module) {
|
|
1764
|
+
"use strict";
|
|
1754
1765
|
var SemVer = require_semver();
|
|
1755
1766
|
var major = (a2, loose) => new SemVer(a2, loose).major;
|
|
1756
1767
|
module.exports = major;
|
|
@@ -1760,6 +1771,7 @@ var require_major = __commonJS({
|
|
|
1760
1771
|
// node_modules/semver/functions/minor.js
|
|
1761
1772
|
var require_minor = __commonJS({
|
|
1762
1773
|
"node_modules/semver/functions/minor.js"(exports, module) {
|
|
1774
|
+
"use strict";
|
|
1763
1775
|
var SemVer = require_semver();
|
|
1764
1776
|
var minor = (a2, loose) => new SemVer(a2, loose).minor;
|
|
1765
1777
|
module.exports = minor;
|
|
@@ -1769,6 +1781,7 @@ var require_minor = __commonJS({
|
|
|
1769
1781
|
// node_modules/semver/functions/patch.js
|
|
1770
1782
|
var require_patch = __commonJS({
|
|
1771
1783
|
"node_modules/semver/functions/patch.js"(exports, module) {
|
|
1784
|
+
"use strict";
|
|
1772
1785
|
var SemVer = require_semver();
|
|
1773
1786
|
var patch = (a2, loose) => new SemVer(a2, loose).patch;
|
|
1774
1787
|
module.exports = patch;
|
|
@@ -1778,6 +1791,7 @@ var require_patch = __commonJS({
|
|
|
1778
1791
|
// node_modules/semver/functions/prerelease.js
|
|
1779
1792
|
var require_prerelease = __commonJS({
|
|
1780
1793
|
"node_modules/semver/functions/prerelease.js"(exports, module) {
|
|
1794
|
+
"use strict";
|
|
1781
1795
|
var parse2 = require_parse2();
|
|
1782
1796
|
var prerelease = (version, options) => {
|
|
1783
1797
|
const parsed = parse2(version, options);
|
|
@@ -1790,6 +1804,7 @@ var require_prerelease = __commonJS({
|
|
|
1790
1804
|
// node_modules/semver/functions/compare.js
|
|
1791
1805
|
var require_compare = __commonJS({
|
|
1792
1806
|
"node_modules/semver/functions/compare.js"(exports, module) {
|
|
1807
|
+
"use strict";
|
|
1793
1808
|
var SemVer = require_semver();
|
|
1794
1809
|
var compare = (a2, b, loose) => new SemVer(a2, loose).compare(new SemVer(b, loose));
|
|
1795
1810
|
module.exports = compare;
|
|
@@ -1799,6 +1814,7 @@ var require_compare = __commonJS({
|
|
|
1799
1814
|
// node_modules/semver/functions/rcompare.js
|
|
1800
1815
|
var require_rcompare = __commonJS({
|
|
1801
1816
|
"node_modules/semver/functions/rcompare.js"(exports, module) {
|
|
1817
|
+
"use strict";
|
|
1802
1818
|
var compare = require_compare();
|
|
1803
1819
|
var rcompare = (a2, b, loose) => compare(b, a2, loose);
|
|
1804
1820
|
module.exports = rcompare;
|
|
@@ -1808,6 +1824,7 @@ var require_rcompare = __commonJS({
|
|
|
1808
1824
|
// node_modules/semver/functions/compare-loose.js
|
|
1809
1825
|
var require_compare_loose = __commonJS({
|
|
1810
1826
|
"node_modules/semver/functions/compare-loose.js"(exports, module) {
|
|
1827
|
+
"use strict";
|
|
1811
1828
|
var compare = require_compare();
|
|
1812
1829
|
var compareLoose = (a2, b) => compare(a2, b, true);
|
|
1813
1830
|
module.exports = compareLoose;
|
|
@@ -1817,6 +1834,7 @@ var require_compare_loose = __commonJS({
|
|
|
1817
1834
|
// node_modules/semver/functions/compare-build.js
|
|
1818
1835
|
var require_compare_build = __commonJS({
|
|
1819
1836
|
"node_modules/semver/functions/compare-build.js"(exports, module) {
|
|
1837
|
+
"use strict";
|
|
1820
1838
|
var SemVer = require_semver();
|
|
1821
1839
|
var compareBuild = (a2, b, loose) => {
|
|
1822
1840
|
const versionA = new SemVer(a2, loose);
|
|
@@ -1830,6 +1848,7 @@ var require_compare_build = __commonJS({
|
|
|
1830
1848
|
// node_modules/semver/functions/sort.js
|
|
1831
1849
|
var require_sort = __commonJS({
|
|
1832
1850
|
"node_modules/semver/functions/sort.js"(exports, module) {
|
|
1851
|
+
"use strict";
|
|
1833
1852
|
var compareBuild = require_compare_build();
|
|
1834
1853
|
var sort = (list, loose) => list.sort((a2, b) => compareBuild(a2, b, loose));
|
|
1835
1854
|
module.exports = sort;
|
|
@@ -1839,6 +1858,7 @@ var require_sort = __commonJS({
|
|
|
1839
1858
|
// node_modules/semver/functions/rsort.js
|
|
1840
1859
|
var require_rsort = __commonJS({
|
|
1841
1860
|
"node_modules/semver/functions/rsort.js"(exports, module) {
|
|
1861
|
+
"use strict";
|
|
1842
1862
|
var compareBuild = require_compare_build();
|
|
1843
1863
|
var rsort = (list, loose) => list.sort((a2, b) => compareBuild(b, a2, loose));
|
|
1844
1864
|
module.exports = rsort;
|
|
@@ -1848,6 +1868,7 @@ var require_rsort = __commonJS({
|
|
|
1848
1868
|
// node_modules/semver/functions/gt.js
|
|
1849
1869
|
var require_gt = __commonJS({
|
|
1850
1870
|
"node_modules/semver/functions/gt.js"(exports, module) {
|
|
1871
|
+
"use strict";
|
|
1851
1872
|
var compare = require_compare();
|
|
1852
1873
|
var gt = (a2, b, loose) => compare(a2, b, loose) > 0;
|
|
1853
1874
|
module.exports = gt;
|
|
@@ -1857,6 +1878,7 @@ var require_gt = __commonJS({
|
|
|
1857
1878
|
// node_modules/semver/functions/lt.js
|
|
1858
1879
|
var require_lt = __commonJS({
|
|
1859
1880
|
"node_modules/semver/functions/lt.js"(exports, module) {
|
|
1881
|
+
"use strict";
|
|
1860
1882
|
var compare = require_compare();
|
|
1861
1883
|
var lt = (a2, b, loose) => compare(a2, b, loose) < 0;
|
|
1862
1884
|
module.exports = lt;
|
|
@@ -1866,6 +1888,7 @@ var require_lt = __commonJS({
|
|
|
1866
1888
|
// node_modules/semver/functions/eq.js
|
|
1867
1889
|
var require_eq = __commonJS({
|
|
1868
1890
|
"node_modules/semver/functions/eq.js"(exports, module) {
|
|
1891
|
+
"use strict";
|
|
1869
1892
|
var compare = require_compare();
|
|
1870
1893
|
var eq = (a2, b, loose) => compare(a2, b, loose) === 0;
|
|
1871
1894
|
module.exports = eq;
|
|
@@ -1875,6 +1898,7 @@ var require_eq = __commonJS({
|
|
|
1875
1898
|
// node_modules/semver/functions/neq.js
|
|
1876
1899
|
var require_neq = __commonJS({
|
|
1877
1900
|
"node_modules/semver/functions/neq.js"(exports, module) {
|
|
1901
|
+
"use strict";
|
|
1878
1902
|
var compare = require_compare();
|
|
1879
1903
|
var neq = (a2, b, loose) => compare(a2, b, loose) !== 0;
|
|
1880
1904
|
module.exports = neq;
|
|
@@ -1884,30 +1908,33 @@ var require_neq = __commonJS({
|
|
|
1884
1908
|
// node_modules/semver/functions/gte.js
|
|
1885
1909
|
var require_gte = __commonJS({
|
|
1886
1910
|
"node_modules/semver/functions/gte.js"(exports, module) {
|
|
1911
|
+
"use strict";
|
|
1887
1912
|
var compare = require_compare();
|
|
1888
|
-
var
|
|
1889
|
-
module.exports =
|
|
1913
|
+
var gte2 = (a2, b, loose) => compare(a2, b, loose) >= 0;
|
|
1914
|
+
module.exports = gte2;
|
|
1890
1915
|
}
|
|
1891
1916
|
});
|
|
1892
1917
|
|
|
1893
1918
|
// node_modules/semver/functions/lte.js
|
|
1894
1919
|
var require_lte = __commonJS({
|
|
1895
1920
|
"node_modules/semver/functions/lte.js"(exports, module) {
|
|
1921
|
+
"use strict";
|
|
1896
1922
|
var compare = require_compare();
|
|
1897
|
-
var
|
|
1898
|
-
module.exports =
|
|
1923
|
+
var lte2 = (a2, b, loose) => compare(a2, b, loose) <= 0;
|
|
1924
|
+
module.exports = lte2;
|
|
1899
1925
|
}
|
|
1900
1926
|
});
|
|
1901
1927
|
|
|
1902
1928
|
// node_modules/semver/functions/cmp.js
|
|
1903
1929
|
var require_cmp = __commonJS({
|
|
1904
1930
|
"node_modules/semver/functions/cmp.js"(exports, module) {
|
|
1931
|
+
"use strict";
|
|
1905
1932
|
var eq = require_eq();
|
|
1906
1933
|
var neq = require_neq();
|
|
1907
1934
|
var gt = require_gt();
|
|
1908
|
-
var
|
|
1935
|
+
var gte2 = require_gte();
|
|
1909
1936
|
var lt = require_lt();
|
|
1910
|
-
var
|
|
1937
|
+
var lte2 = require_lte();
|
|
1911
1938
|
var cmp = (a2, op, b, loose) => {
|
|
1912
1939
|
switch (op) {
|
|
1913
1940
|
case "===":
|
|
@@ -1935,11 +1962,11 @@ var require_cmp = __commonJS({
|
|
|
1935
1962
|
case ">":
|
|
1936
1963
|
return gt(a2, b, loose);
|
|
1937
1964
|
case ">=":
|
|
1938
|
-
return
|
|
1965
|
+
return gte2(a2, b, loose);
|
|
1939
1966
|
case "<":
|
|
1940
1967
|
return lt(a2, b, loose);
|
|
1941
1968
|
case "<=":
|
|
1942
|
-
return
|
|
1969
|
+
return lte2(a2, b, loose);
|
|
1943
1970
|
default:
|
|
1944
1971
|
throw new TypeError(`Invalid operator: ${op}`);
|
|
1945
1972
|
}
|
|
@@ -1951,6 +1978,7 @@ var require_cmp = __commonJS({
|
|
|
1951
1978
|
// node_modules/semver/functions/coerce.js
|
|
1952
1979
|
var require_coerce = __commonJS({
|
|
1953
1980
|
"node_modules/semver/functions/coerce.js"(exports, module) {
|
|
1981
|
+
"use strict";
|
|
1954
1982
|
var SemVer = require_semver();
|
|
1955
1983
|
var parse2 = require_parse2();
|
|
1956
1984
|
var { safeRe: re, t } = require_re();
|
|
@@ -1996,6 +2024,7 @@ var require_coerce = __commonJS({
|
|
|
1996
2024
|
// node_modules/semver/internal/lrucache.js
|
|
1997
2025
|
var require_lrucache = __commonJS({
|
|
1998
2026
|
"node_modules/semver/internal/lrucache.js"(exports, module) {
|
|
2027
|
+
"use strict";
|
|
1999
2028
|
var LRUCache = class {
|
|
2000
2029
|
constructor() {
|
|
2001
2030
|
this.max = 1e3;
|
|
@@ -2033,27 +2062,28 @@ var require_lrucache = __commonJS({
|
|
|
2033
2062
|
// node_modules/semver/classes/range.js
|
|
2034
2063
|
var require_range = __commonJS({
|
|
2035
2064
|
"node_modules/semver/classes/range.js"(exports, module) {
|
|
2065
|
+
"use strict";
|
|
2036
2066
|
var SPACE_CHARACTERS = /\s+/g;
|
|
2037
2067
|
var Range = class _Range {
|
|
2038
|
-
constructor(
|
|
2068
|
+
constructor(range2, options) {
|
|
2039
2069
|
options = parseOptions(options);
|
|
2040
|
-
if (
|
|
2041
|
-
if (
|
|
2042
|
-
return
|
|
2070
|
+
if (range2 instanceof _Range) {
|
|
2071
|
+
if (range2.loose === !!options.loose && range2.includePrerelease === !!options.includePrerelease) {
|
|
2072
|
+
return range2;
|
|
2043
2073
|
} else {
|
|
2044
|
-
return new _Range(
|
|
2074
|
+
return new _Range(range2.raw, options);
|
|
2045
2075
|
}
|
|
2046
2076
|
}
|
|
2047
|
-
if (
|
|
2048
|
-
this.raw =
|
|
2049
|
-
this.set = [[
|
|
2077
|
+
if (range2 instanceof Comparator) {
|
|
2078
|
+
this.raw = range2.value;
|
|
2079
|
+
this.set = [[range2]];
|
|
2050
2080
|
this.formatted = void 0;
|
|
2051
2081
|
return this;
|
|
2052
2082
|
}
|
|
2053
2083
|
this.options = options;
|
|
2054
2084
|
this.loose = !!options.loose;
|
|
2055
2085
|
this.includePrerelease = !!options.includePrerelease;
|
|
2056
|
-
this.raw =
|
|
2086
|
+
this.raw = range2.trim().replace(SPACE_CHARACTERS, " ");
|
|
2057
2087
|
this.set = this.raw.split("||").map((r) => this.parseRange(r.trim())).filter((c3) => c3.length);
|
|
2058
2088
|
if (!this.set.length) {
|
|
2059
2089
|
throw new TypeError(`Invalid SemVer Range: ${this.raw}`);
|
|
@@ -2098,24 +2128,24 @@ var require_range = __commonJS({
|
|
|
2098
2128
|
toString() {
|
|
2099
2129
|
return this.range;
|
|
2100
2130
|
}
|
|
2101
|
-
parseRange(
|
|
2131
|
+
parseRange(range2) {
|
|
2102
2132
|
const memoOpts = (this.options.includePrerelease && FLAG_INCLUDE_PRERELEASE) | (this.options.loose && FLAG_LOOSE);
|
|
2103
|
-
const memoKey = memoOpts + ":" +
|
|
2133
|
+
const memoKey = memoOpts + ":" + range2;
|
|
2104
2134
|
const cached = cache2.get(memoKey);
|
|
2105
2135
|
if (cached) {
|
|
2106
2136
|
return cached;
|
|
2107
2137
|
}
|
|
2108
2138
|
const loose = this.options.loose;
|
|
2109
2139
|
const hr = loose ? re[t.HYPHENRANGELOOSE] : re[t.HYPHENRANGE];
|
|
2110
|
-
|
|
2111
|
-
debug2("hyphen replace",
|
|
2112
|
-
|
|
2113
|
-
debug2("comparator trim",
|
|
2114
|
-
|
|
2115
|
-
debug2("tilde trim",
|
|
2116
|
-
|
|
2117
|
-
debug2("caret trim",
|
|
2118
|
-
let rangeList =
|
|
2140
|
+
range2 = range2.replace(hr, hyphenReplace(this.options.includePrerelease));
|
|
2141
|
+
debug2("hyphen replace", range2);
|
|
2142
|
+
range2 = range2.replace(re[t.COMPARATORTRIM], comparatorTrimReplace);
|
|
2143
|
+
debug2("comparator trim", range2);
|
|
2144
|
+
range2 = range2.replace(re[t.TILDETRIM], tildeTrimReplace);
|
|
2145
|
+
debug2("tilde trim", range2);
|
|
2146
|
+
range2 = range2.replace(re[t.CARETTRIM], caretTrimReplace);
|
|
2147
|
+
debug2("caret trim", range2);
|
|
2148
|
+
let rangeList = range2.split(" ").map((comp) => parseComparator(comp, this.options)).join(" ").split(/\s+/).map((comp) => replaceGTE0(comp, this.options));
|
|
2119
2149
|
if (loose) {
|
|
2120
2150
|
rangeList = rangeList.filter((comp) => {
|
|
2121
2151
|
debug2("loose invalid filter", comp, this.options);
|
|
@@ -2138,12 +2168,12 @@ var require_range = __commonJS({
|
|
|
2138
2168
|
cache2.set(memoKey, result);
|
|
2139
2169
|
return result;
|
|
2140
2170
|
}
|
|
2141
|
-
intersects(
|
|
2142
|
-
if (!(
|
|
2171
|
+
intersects(range2, options) {
|
|
2172
|
+
if (!(range2 instanceof _Range)) {
|
|
2143
2173
|
throw new TypeError("a Range is required");
|
|
2144
2174
|
}
|
|
2145
2175
|
return this.set.some((thisComparators) => {
|
|
2146
|
-
return isSatisfiable(thisComparators, options) &&
|
|
2176
|
+
return isSatisfiable(thisComparators, options) && range2.set.some((rangeComparators) => {
|
|
2147
2177
|
return isSatisfiable(rangeComparators, options) && thisComparators.every((thisComparator) => {
|
|
2148
2178
|
return rangeComparators.every((rangeComparator) => {
|
|
2149
2179
|
return thisComparator.intersects(rangeComparator, options);
|
|
@@ -2408,6 +2438,7 @@ var require_range = __commonJS({
|
|
|
2408
2438
|
// node_modules/semver/classes/comparator.js
|
|
2409
2439
|
var require_comparator = __commonJS({
|
|
2410
2440
|
"node_modules/semver/classes/comparator.js"(exports, module) {
|
|
2441
|
+
"use strict";
|
|
2411
2442
|
var ANY = Symbol("SemVer ANY");
|
|
2412
2443
|
var Comparator = class _Comparator {
|
|
2413
2444
|
static get ANY() {
|
|
@@ -2520,14 +2551,15 @@ var require_comparator = __commonJS({
|
|
|
2520
2551
|
// node_modules/semver/functions/satisfies.js
|
|
2521
2552
|
var require_satisfies = __commonJS({
|
|
2522
2553
|
"node_modules/semver/functions/satisfies.js"(exports, module) {
|
|
2554
|
+
"use strict";
|
|
2523
2555
|
var Range = require_range();
|
|
2524
|
-
var satisfies2 = (version,
|
|
2556
|
+
var satisfies2 = (version, range2, options) => {
|
|
2525
2557
|
try {
|
|
2526
|
-
|
|
2558
|
+
range2 = new Range(range2, options);
|
|
2527
2559
|
} catch (er) {
|
|
2528
2560
|
return false;
|
|
2529
2561
|
}
|
|
2530
|
-
return
|
|
2562
|
+
return range2.test(version);
|
|
2531
2563
|
};
|
|
2532
2564
|
module.exports = satisfies2;
|
|
2533
2565
|
}
|
|
@@ -2536,8 +2568,9 @@ var require_satisfies = __commonJS({
|
|
|
2536
2568
|
// node_modules/semver/ranges/to-comparators.js
|
|
2537
2569
|
var require_to_comparators = __commonJS({
|
|
2538
2570
|
"node_modules/semver/ranges/to-comparators.js"(exports, module) {
|
|
2571
|
+
"use strict";
|
|
2539
2572
|
var Range = require_range();
|
|
2540
|
-
var toComparators = (
|
|
2573
|
+
var toComparators = (range2, options) => new Range(range2, options).set.map((comp) => comp.map((c3) => c3.value).join(" ").trim().split(" "));
|
|
2541
2574
|
module.exports = toComparators;
|
|
2542
2575
|
}
|
|
2543
2576
|
});
|
|
@@ -2545,14 +2578,15 @@ var require_to_comparators = __commonJS({
|
|
|
2545
2578
|
// node_modules/semver/ranges/max-satisfying.js
|
|
2546
2579
|
var require_max_satisfying = __commonJS({
|
|
2547
2580
|
"node_modules/semver/ranges/max-satisfying.js"(exports, module) {
|
|
2581
|
+
"use strict";
|
|
2548
2582
|
var SemVer = require_semver();
|
|
2549
2583
|
var Range = require_range();
|
|
2550
|
-
var maxSatisfying = (versions,
|
|
2584
|
+
var maxSatisfying = (versions, range2, options) => {
|
|
2551
2585
|
let max = null;
|
|
2552
2586
|
let maxSV = null;
|
|
2553
2587
|
let rangeObj = null;
|
|
2554
2588
|
try {
|
|
2555
|
-
rangeObj = new Range(
|
|
2589
|
+
rangeObj = new Range(range2, options);
|
|
2556
2590
|
} catch (er) {
|
|
2557
2591
|
return null;
|
|
2558
2592
|
}
|
|
@@ -2573,14 +2607,15 @@ var require_max_satisfying = __commonJS({
|
|
|
2573
2607
|
// node_modules/semver/ranges/min-satisfying.js
|
|
2574
2608
|
var require_min_satisfying = __commonJS({
|
|
2575
2609
|
"node_modules/semver/ranges/min-satisfying.js"(exports, module) {
|
|
2610
|
+
"use strict";
|
|
2576
2611
|
var SemVer = require_semver();
|
|
2577
2612
|
var Range = require_range();
|
|
2578
|
-
var minSatisfying = (versions,
|
|
2613
|
+
var minSatisfying = (versions, range2, options) => {
|
|
2579
2614
|
let min = null;
|
|
2580
2615
|
let minSV = null;
|
|
2581
2616
|
let rangeObj = null;
|
|
2582
2617
|
try {
|
|
2583
|
-
rangeObj = new Range(
|
|
2618
|
+
rangeObj = new Range(range2, options);
|
|
2584
2619
|
} catch (er) {
|
|
2585
2620
|
return null;
|
|
2586
2621
|
}
|
|
@@ -2601,22 +2636,23 @@ var require_min_satisfying = __commonJS({
|
|
|
2601
2636
|
// node_modules/semver/ranges/min-version.js
|
|
2602
2637
|
var require_min_version = __commonJS({
|
|
2603
2638
|
"node_modules/semver/ranges/min-version.js"(exports, module) {
|
|
2639
|
+
"use strict";
|
|
2604
2640
|
var SemVer = require_semver();
|
|
2605
2641
|
var Range = require_range();
|
|
2606
2642
|
var gt = require_gt();
|
|
2607
|
-
var minVersion = (
|
|
2608
|
-
|
|
2643
|
+
var minVersion = (range2, loose) => {
|
|
2644
|
+
range2 = new Range(range2, loose);
|
|
2609
2645
|
let minver = new SemVer("0.0.0");
|
|
2610
|
-
if (
|
|
2646
|
+
if (range2.test(minver)) {
|
|
2611
2647
|
return minver;
|
|
2612
2648
|
}
|
|
2613
2649
|
minver = new SemVer("0.0.0-0");
|
|
2614
|
-
if (
|
|
2650
|
+
if (range2.test(minver)) {
|
|
2615
2651
|
return minver;
|
|
2616
2652
|
}
|
|
2617
2653
|
minver = null;
|
|
2618
|
-
for (let i2 = 0; i2 <
|
|
2619
|
-
const comparators =
|
|
2654
|
+
for (let i2 = 0; i2 < range2.set.length; ++i2) {
|
|
2655
|
+
const comparators = range2.set[i2];
|
|
2620
2656
|
let setMin = null;
|
|
2621
2657
|
comparators.forEach((comparator) => {
|
|
2622
2658
|
const compver = new SemVer(comparator.semver.version);
|
|
@@ -2647,7 +2683,7 @@ var require_min_version = __commonJS({
|
|
|
2647
2683
|
minver = setMin;
|
|
2648
2684
|
}
|
|
2649
2685
|
}
|
|
2650
|
-
if (minver &&
|
|
2686
|
+
if (minver && range2.test(minver)) {
|
|
2651
2687
|
return minver;
|
|
2652
2688
|
}
|
|
2653
2689
|
return null;
|
|
@@ -2659,10 +2695,11 @@ var require_min_version = __commonJS({
|
|
|
2659
2695
|
// node_modules/semver/ranges/valid.js
|
|
2660
2696
|
var require_valid2 = __commonJS({
|
|
2661
2697
|
"node_modules/semver/ranges/valid.js"(exports, module) {
|
|
2698
|
+
"use strict";
|
|
2662
2699
|
var Range = require_range();
|
|
2663
|
-
var validRange3 = (
|
|
2700
|
+
var validRange3 = (range2, options) => {
|
|
2664
2701
|
try {
|
|
2665
|
-
return new Range(
|
|
2702
|
+
return new Range(range2, options).range || "*";
|
|
2666
2703
|
} catch (er) {
|
|
2667
2704
|
return null;
|
|
2668
2705
|
}
|
|
@@ -2674,6 +2711,7 @@ var require_valid2 = __commonJS({
|
|
|
2674
2711
|
// node_modules/semver/ranges/outside.js
|
|
2675
2712
|
var require_outside = __commonJS({
|
|
2676
2713
|
"node_modules/semver/ranges/outside.js"(exports, module) {
|
|
2714
|
+
"use strict";
|
|
2677
2715
|
var SemVer = require_semver();
|
|
2678
2716
|
var Comparator = require_comparator();
|
|
2679
2717
|
var { ANY } = Comparator;
|
|
@@ -2681,23 +2719,23 @@ var require_outside = __commonJS({
|
|
|
2681
2719
|
var satisfies2 = require_satisfies();
|
|
2682
2720
|
var gt = require_gt();
|
|
2683
2721
|
var lt = require_lt();
|
|
2684
|
-
var
|
|
2685
|
-
var
|
|
2686
|
-
var outside = (version,
|
|
2722
|
+
var lte2 = require_lte();
|
|
2723
|
+
var gte2 = require_gte();
|
|
2724
|
+
var outside = (version, range2, hilo, options) => {
|
|
2687
2725
|
version = new SemVer(version, options);
|
|
2688
|
-
|
|
2726
|
+
range2 = new Range(range2, options);
|
|
2689
2727
|
let gtfn, ltefn, ltfn, comp, ecomp;
|
|
2690
2728
|
switch (hilo) {
|
|
2691
2729
|
case ">":
|
|
2692
2730
|
gtfn = gt;
|
|
2693
|
-
ltefn =
|
|
2731
|
+
ltefn = lte2;
|
|
2694
2732
|
ltfn = lt;
|
|
2695
2733
|
comp = ">";
|
|
2696
2734
|
ecomp = ">=";
|
|
2697
2735
|
break;
|
|
2698
2736
|
case "<":
|
|
2699
2737
|
gtfn = lt;
|
|
2700
|
-
ltefn =
|
|
2738
|
+
ltefn = gte2;
|
|
2701
2739
|
ltfn = gt;
|
|
2702
2740
|
comp = "<";
|
|
2703
2741
|
ecomp = "<=";
|
|
@@ -2705,11 +2743,11 @@ var require_outside = __commonJS({
|
|
|
2705
2743
|
default:
|
|
2706
2744
|
throw new TypeError('Must provide a hilo val of "<" or ">"');
|
|
2707
2745
|
}
|
|
2708
|
-
if (satisfies2(version,
|
|
2746
|
+
if (satisfies2(version, range2, options)) {
|
|
2709
2747
|
return false;
|
|
2710
2748
|
}
|
|
2711
|
-
for (let i2 = 0; i2 <
|
|
2712
|
-
const comparators =
|
|
2749
|
+
for (let i2 = 0; i2 < range2.set.length; ++i2) {
|
|
2750
|
+
const comparators = range2.set[i2];
|
|
2713
2751
|
let high = null;
|
|
2714
2752
|
let low = null;
|
|
2715
2753
|
comparators.forEach((comparator) => {
|
|
@@ -2742,8 +2780,9 @@ var require_outside = __commonJS({
|
|
|
2742
2780
|
// node_modules/semver/ranges/gtr.js
|
|
2743
2781
|
var require_gtr = __commonJS({
|
|
2744
2782
|
"node_modules/semver/ranges/gtr.js"(exports, module) {
|
|
2783
|
+
"use strict";
|
|
2745
2784
|
var outside = require_outside();
|
|
2746
|
-
var gtr = (version,
|
|
2785
|
+
var gtr = (version, range2, options) => outside(version, range2, ">", options);
|
|
2747
2786
|
module.exports = gtr;
|
|
2748
2787
|
}
|
|
2749
2788
|
});
|
|
@@ -2751,8 +2790,9 @@ var require_gtr = __commonJS({
|
|
|
2751
2790
|
// node_modules/semver/ranges/ltr.js
|
|
2752
2791
|
var require_ltr = __commonJS({
|
|
2753
2792
|
"node_modules/semver/ranges/ltr.js"(exports, module) {
|
|
2793
|
+
"use strict";
|
|
2754
2794
|
var outside = require_outside();
|
|
2755
|
-
var ltr = (version,
|
|
2795
|
+
var ltr = (version, range2, options) => outside(version, range2, "<", options);
|
|
2756
2796
|
module.exports = ltr;
|
|
2757
2797
|
}
|
|
2758
2798
|
});
|
|
@@ -2760,6 +2800,7 @@ var require_ltr = __commonJS({
|
|
|
2760
2800
|
// node_modules/semver/ranges/intersects.js
|
|
2761
2801
|
var require_intersects = __commonJS({
|
|
2762
2802
|
"node_modules/semver/ranges/intersects.js"(exports, module) {
|
|
2803
|
+
"use strict";
|
|
2763
2804
|
var Range = require_range();
|
|
2764
2805
|
var intersects = (r1, r2, options) => {
|
|
2765
2806
|
r1 = new Range(r1, options);
|
|
@@ -2773,15 +2814,16 @@ var require_intersects = __commonJS({
|
|
|
2773
2814
|
// node_modules/semver/ranges/simplify.js
|
|
2774
2815
|
var require_simplify = __commonJS({
|
|
2775
2816
|
"node_modules/semver/ranges/simplify.js"(exports, module) {
|
|
2817
|
+
"use strict";
|
|
2776
2818
|
var satisfies2 = require_satisfies();
|
|
2777
2819
|
var compare = require_compare();
|
|
2778
|
-
module.exports = (versions,
|
|
2820
|
+
module.exports = (versions, range2, options) => {
|
|
2779
2821
|
const set2 = [];
|
|
2780
2822
|
let first = null;
|
|
2781
2823
|
let prev = null;
|
|
2782
2824
|
const v = versions.sort((a2, b) => compare(a2, b, options));
|
|
2783
2825
|
for (const version of v) {
|
|
2784
|
-
const included = satisfies2(version,
|
|
2826
|
+
const included = satisfies2(version, range2, options);
|
|
2785
2827
|
if (included) {
|
|
2786
2828
|
prev = version;
|
|
2787
2829
|
if (!first) {
|
|
@@ -2813,8 +2855,8 @@ var require_simplify = __commonJS({
|
|
|
2813
2855
|
}
|
|
2814
2856
|
}
|
|
2815
2857
|
const simplified = ranges.join(" || ");
|
|
2816
|
-
const original = typeof
|
|
2817
|
-
return simplified.length < original.length ? simplified :
|
|
2858
|
+
const original = typeof range2.raw === "string" ? range2.raw : String(range2);
|
|
2859
|
+
return simplified.length < original.length ? simplified : range2;
|
|
2818
2860
|
};
|
|
2819
2861
|
}
|
|
2820
2862
|
});
|
|
@@ -2822,6 +2864,7 @@ var require_simplify = __commonJS({
|
|
|
2822
2864
|
// node_modules/semver/ranges/subset.js
|
|
2823
2865
|
var require_subset = __commonJS({
|
|
2824
2866
|
"node_modules/semver/ranges/subset.js"(exports, module) {
|
|
2867
|
+
"use strict";
|
|
2825
2868
|
var Range = require_range();
|
|
2826
2869
|
var Comparator = require_comparator();
|
|
2827
2870
|
var { ANY } = Comparator;
|
|
@@ -2983,6 +3026,7 @@ var require_subset = __commonJS({
|
|
|
2983
3026
|
// node_modules/semver/index.js
|
|
2984
3027
|
var require_semver2 = __commonJS({
|
|
2985
3028
|
"node_modules/semver/index.js"(exports, module) {
|
|
3029
|
+
"use strict";
|
|
2986
3030
|
var internalRe = require_re();
|
|
2987
3031
|
var constants4 = require_constants();
|
|
2988
3032
|
var SemVer = require_semver();
|
|
@@ -3006,8 +3050,8 @@ var require_semver2 = __commonJS({
|
|
|
3006
3050
|
var lt = require_lt();
|
|
3007
3051
|
var eq = require_eq();
|
|
3008
3052
|
var neq = require_neq();
|
|
3009
|
-
var
|
|
3010
|
-
var
|
|
3053
|
+
var gte2 = require_gte();
|
|
3054
|
+
var lte2 = require_lte();
|
|
3011
3055
|
var cmp = require_cmp();
|
|
3012
3056
|
var coerce = require_coerce();
|
|
3013
3057
|
var Comparator = require_comparator();
|
|
@@ -3044,8 +3088,8 @@ var require_semver2 = __commonJS({
|
|
|
3044
3088
|
lt,
|
|
3045
3089
|
eq,
|
|
3046
3090
|
neq,
|
|
3047
|
-
gte,
|
|
3048
|
-
lte,
|
|
3091
|
+
gte: gte2,
|
|
3092
|
+
lte: lte2,
|
|
3049
3093
|
cmp,
|
|
3050
3094
|
coerce,
|
|
3051
3095
|
Comparator,
|
|
@@ -3537,12 +3581,12 @@ var require_to_regex_range = __commonJS({
|
|
|
3537
3581
|
}
|
|
3538
3582
|
return `(?:${result})`;
|
|
3539
3583
|
}
|
|
3540
|
-
let
|
|
3584
|
+
let isPadded2 = hasPadding(min) || hasPadding(max);
|
|
3541
3585
|
let state = { min, max, a: a2, b };
|
|
3542
3586
|
let positives = [];
|
|
3543
3587
|
let negatives = [];
|
|
3544
|
-
if (
|
|
3545
|
-
state.isPadded =
|
|
3588
|
+
if (isPadded2) {
|
|
3589
|
+
state.isPadded = isPadded2;
|
|
3546
3590
|
state.maxLen = String(state.max).length;
|
|
3547
3591
|
}
|
|
3548
3592
|
if (a2 < 0) {
|
|
@@ -3833,21 +3877,21 @@ var require_fill_range = __commonJS({
|
|
|
3833
3877
|
}
|
|
3834
3878
|
let parts = { negatives: [], positives: [] };
|
|
3835
3879
|
let push = (num) => parts[num < 0 ? "negatives" : "positives"].push(Math.abs(num));
|
|
3836
|
-
let
|
|
3880
|
+
let range2 = [];
|
|
3837
3881
|
let index = 0;
|
|
3838
3882
|
while (descending ? a2 >= b : a2 <= b) {
|
|
3839
3883
|
if (options.toRegex === true && step > 1) {
|
|
3840
3884
|
push(a2);
|
|
3841
3885
|
} else {
|
|
3842
|
-
|
|
3886
|
+
range2.push(pad(format6(a2, index), maxLen, toNumber));
|
|
3843
3887
|
}
|
|
3844
3888
|
a2 = descending ? a2 - step : a2 + step;
|
|
3845
3889
|
index++;
|
|
3846
3890
|
}
|
|
3847
3891
|
if (options.toRegex === true) {
|
|
3848
|
-
return step > 1 ? toSequence(parts, options, maxLen) : toRegex(
|
|
3892
|
+
return step > 1 ? toSequence(parts, options, maxLen) : toRegex(range2, null, { wrap: false, ...options });
|
|
3849
3893
|
}
|
|
3850
|
-
return
|
|
3894
|
+
return range2;
|
|
3851
3895
|
};
|
|
3852
3896
|
var fillLetters = (start, end, step = 1, options = {}) => {
|
|
3853
3897
|
if (!isNumber(start) && start.length > 1 || !isNumber(end) && end.length > 1) {
|
|
@@ -3862,17 +3906,17 @@ var require_fill_range = __commonJS({
|
|
|
3862
3906
|
if (options.toRegex && step === 1) {
|
|
3863
3907
|
return toRange(min, max, false, options);
|
|
3864
3908
|
}
|
|
3865
|
-
let
|
|
3909
|
+
let range2 = [];
|
|
3866
3910
|
let index = 0;
|
|
3867
3911
|
while (descending ? a2 >= b : a2 <= b) {
|
|
3868
|
-
|
|
3912
|
+
range2.push(format6(a2, index));
|
|
3869
3913
|
a2 = descending ? a2 - step : a2 + step;
|
|
3870
3914
|
index++;
|
|
3871
3915
|
}
|
|
3872
3916
|
if (options.toRegex === true) {
|
|
3873
|
-
return toRegex(
|
|
3917
|
+
return toRegex(range2, null, { wrap: false, options });
|
|
3874
3918
|
}
|
|
3875
|
-
return
|
|
3919
|
+
return range2;
|
|
3876
3920
|
};
|
|
3877
3921
|
var fill = (start, end, step, options = {}) => {
|
|
3878
3922
|
if (end == null && isValidValue(start)) {
|
|
@@ -3937,9 +3981,9 @@ var require_compile = __commonJS({
|
|
|
3937
3981
|
}
|
|
3938
3982
|
if (node.nodes && node.ranges > 0) {
|
|
3939
3983
|
const args = utils.reduce(node.nodes);
|
|
3940
|
-
const
|
|
3941
|
-
if (
|
|
3942
|
-
return args.length > 1 &&
|
|
3984
|
+
const range2 = fill(...args, { ...options, wrap: false, toRegex: true, strictZeros: true });
|
|
3985
|
+
if (range2.length !== 0) {
|
|
3986
|
+
return args.length > 1 && range2.length > 1 ? `(${range2})` : range2;
|
|
3943
3987
|
}
|
|
3944
3988
|
}
|
|
3945
3989
|
if (node.nodes) {
|
|
@@ -4007,11 +4051,11 @@ var require_expand = __commonJS({
|
|
|
4007
4051
|
if (utils.exceedsLimit(...args, options.step, rangeLimit)) {
|
|
4008
4052
|
throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.");
|
|
4009
4053
|
}
|
|
4010
|
-
let
|
|
4011
|
-
if (
|
|
4012
|
-
|
|
4054
|
+
let range2 = fill(...args, options);
|
|
4055
|
+
if (range2.length === 0) {
|
|
4056
|
+
range2 = stringify(node, options);
|
|
4013
4057
|
}
|
|
4014
|
-
q.push(append(q.pop(),
|
|
4058
|
+
q.push(append(q.pop(), range2));
|
|
4015
4059
|
node.nodes = [];
|
|
4016
4060
|
return;
|
|
4017
4061
|
}
|
|
@@ -5440,17 +5484,17 @@ var require_parse4 = __commonJS({
|
|
|
5440
5484
|
let output = ")";
|
|
5441
5485
|
if (brace.dots === true) {
|
|
5442
5486
|
const arr = tokens.slice();
|
|
5443
|
-
const
|
|
5487
|
+
const range2 = [];
|
|
5444
5488
|
for (let i2 = arr.length - 1; i2 >= 0; i2--) {
|
|
5445
5489
|
tokens.pop();
|
|
5446
5490
|
if (arr[i2].type === "brace") {
|
|
5447
5491
|
break;
|
|
5448
5492
|
}
|
|
5449
5493
|
if (arr[i2].type !== "dots") {
|
|
5450
|
-
|
|
5494
|
+
range2.unshift(arr[i2].value);
|
|
5451
5495
|
}
|
|
5452
5496
|
}
|
|
5453
|
-
output = expandRange(
|
|
5497
|
+
output = expandRange(range2, opts);
|
|
5454
5498
|
state.backtrack = true;
|
|
5455
5499
|
}
|
|
5456
5500
|
if (brace.comma !== true && brace.dots !== true) {
|
|
@@ -8578,7 +8622,7 @@ var require_ignore = __commonJS({
|
|
|
8578
8622
|
var REGEX_REPLACE_LEADING_EXCAPED_EXCLAMATION = /^\\!/;
|
|
8579
8623
|
var REGEX_REPLACE_LEADING_EXCAPED_HASH = /^\\#/;
|
|
8580
8624
|
var REGEX_SPLITALL_CRLF = /\r?\n/g;
|
|
8581
|
-
var REGEX_TEST_INVALID_PATH =
|
|
8625
|
+
var REGEX_TEST_INVALID_PATH = /^\.{0,2}\/|^\.{1,2}$/;
|
|
8582
8626
|
var REGEX_TEST_TRAILING_SLASH = /\/$/;
|
|
8583
8627
|
var SLASH = "/";
|
|
8584
8628
|
var TMP_KEY_IGNORE = "node-ignore";
|
|
@@ -8592,7 +8636,7 @@ var require_ignore = __commonJS({
|
|
|
8592
8636
|
};
|
|
8593
8637
|
var REGEX_REGEXP_RANGE = /([0-z])-([0-z])/g;
|
|
8594
8638
|
var RETURN_FALSE = () => false;
|
|
8595
|
-
var sanitizeRange = (
|
|
8639
|
+
var sanitizeRange = (range2) => range2.replace(
|
|
8596
8640
|
REGEX_REGEXP_RANGE,
|
|
8597
8641
|
(match2, from, to) => from.charCodeAt(0) <= to.charCodeAt(0) ? match2 : EMPTY
|
|
8598
8642
|
);
|
|
@@ -8728,7 +8772,7 @@ var require_ignore = __commonJS({
|
|
|
8728
8772
|
// > can be used to match one of the characters in a range.
|
|
8729
8773
|
// `\` is escaped by step 3
|
|
8730
8774
|
/(\\)?\[([^\]/]*?)(\\*)($|\])/g,
|
|
8731
|
-
(match2, leadEscape,
|
|
8775
|
+
(match2, leadEscape, range2, endEscape, close) => leadEscape === ESCAPE ? `\\[${range2}${cleanRangeBackSlash(endEscape)}${close}` : close === "]" ? endEscape.length % 2 === 0 ? `[${sanitizeRange(range2)}${endEscape}]` : "[]" : "[]"
|
|
8732
8776
|
],
|
|
8733
8777
|
// ending
|
|
8734
8778
|
[
|
|
@@ -9001,226 +9045,22 @@ var require_ignore = __commonJS({
|
|
|
9001
9045
|
};
|
|
9002
9046
|
var factory = (options) => new Ignore(options);
|
|
9003
9047
|
var isPathValid = (path22) => checkPath(path22 && checkPath.convert(path22), path22, RETURN_FALSE);
|
|
9004
|
-
|
|
9005
|
-
// Detect `process` so that it can run in browsers.
|
|
9006
|
-
typeof process !== "undefined" && (process.env && process.env.IGNORE_TEST_WIN32 || process.platform === "win32")
|
|
9007
|
-
) {
|
|
9048
|
+
var setupWindows = () => {
|
|
9008
9049
|
const makePosix = (str2) => /^\\\\\?\\/.test(str2) || /["<>|\u0000-\u001F]+/u.test(str2) ? str2 : str2.replace(/\\/g, "/");
|
|
9009
9050
|
checkPath.convert = makePosix;
|
|
9010
9051
|
const REGEX_TEST_WINDOWS_PATH_ABSOLUTE = /^[a-z]:\//i;
|
|
9011
9052
|
checkPath.isNotRelative = (path22) => REGEX_TEST_WINDOWS_PATH_ABSOLUTE.test(path22) || isNotRelative(path22);
|
|
9053
|
+
};
|
|
9054
|
+
if (
|
|
9055
|
+
// Detect `process` so that it can run in browsers.
|
|
9056
|
+
typeof process !== "undefined" && process.platform === "win32"
|
|
9057
|
+
) {
|
|
9058
|
+
setupWindows();
|
|
9012
9059
|
}
|
|
9013
9060
|
module.exports = factory;
|
|
9014
9061
|
factory.default = factory;
|
|
9015
9062
|
module.exports.isPathValid = isPathValid;
|
|
9016
|
-
|
|
9017
|
-
});
|
|
9018
|
-
|
|
9019
|
-
// node_modules/balanced-match/index.js
|
|
9020
|
-
var require_balanced_match = __commonJS({
|
|
9021
|
-
"node_modules/balanced-match/index.js"(exports, module) {
|
|
9022
|
-
"use strict";
|
|
9023
|
-
module.exports = balanced;
|
|
9024
|
-
function balanced(a2, b, str2) {
|
|
9025
|
-
if (a2 instanceof RegExp) a2 = maybeMatch(a2, str2);
|
|
9026
|
-
if (b instanceof RegExp) b = maybeMatch(b, str2);
|
|
9027
|
-
var r = range(a2, b, str2);
|
|
9028
|
-
return r && {
|
|
9029
|
-
start: r[0],
|
|
9030
|
-
end: r[1],
|
|
9031
|
-
pre: str2.slice(0, r[0]),
|
|
9032
|
-
body: str2.slice(r[0] + a2.length, r[1]),
|
|
9033
|
-
post: str2.slice(r[1] + b.length)
|
|
9034
|
-
};
|
|
9035
|
-
}
|
|
9036
|
-
function maybeMatch(reg, str2) {
|
|
9037
|
-
var m = str2.match(reg);
|
|
9038
|
-
return m ? m[0] : null;
|
|
9039
|
-
}
|
|
9040
|
-
balanced.range = range;
|
|
9041
|
-
function range(a2, b, str2) {
|
|
9042
|
-
var begs, beg, left, right, result;
|
|
9043
|
-
var ai = str2.indexOf(a2);
|
|
9044
|
-
var bi = str2.indexOf(b, ai + 1);
|
|
9045
|
-
var i2 = ai;
|
|
9046
|
-
if (ai >= 0 && bi > 0) {
|
|
9047
|
-
if (a2 === b) {
|
|
9048
|
-
return [ai, bi];
|
|
9049
|
-
}
|
|
9050
|
-
begs = [];
|
|
9051
|
-
left = str2.length;
|
|
9052
|
-
while (i2 >= 0 && !result) {
|
|
9053
|
-
if (i2 == ai) {
|
|
9054
|
-
begs.push(i2);
|
|
9055
|
-
ai = str2.indexOf(a2, i2 + 1);
|
|
9056
|
-
} else if (begs.length == 1) {
|
|
9057
|
-
result = [begs.pop(), bi];
|
|
9058
|
-
} else {
|
|
9059
|
-
beg = begs.pop();
|
|
9060
|
-
if (beg < left) {
|
|
9061
|
-
left = beg;
|
|
9062
|
-
right = bi;
|
|
9063
|
-
}
|
|
9064
|
-
bi = str2.indexOf(b, i2 + 1);
|
|
9065
|
-
}
|
|
9066
|
-
i2 = ai < bi && ai >= 0 ? ai : bi;
|
|
9067
|
-
}
|
|
9068
|
-
if (begs.length) {
|
|
9069
|
-
result = [left, right];
|
|
9070
|
-
}
|
|
9071
|
-
}
|
|
9072
|
-
return result;
|
|
9073
|
-
}
|
|
9074
|
-
}
|
|
9075
|
-
});
|
|
9076
|
-
|
|
9077
|
-
// node_modules/brace-expansion/index.js
|
|
9078
|
-
var require_brace_expansion = __commonJS({
|
|
9079
|
-
"node_modules/brace-expansion/index.js"(exports, module) {
|
|
9080
|
-
var balanced = require_balanced_match();
|
|
9081
|
-
module.exports = expandTop;
|
|
9082
|
-
var escSlash = "\0SLASH" + Math.random() + "\0";
|
|
9083
|
-
var escOpen = "\0OPEN" + Math.random() + "\0";
|
|
9084
|
-
var escClose = "\0CLOSE" + Math.random() + "\0";
|
|
9085
|
-
var escComma = "\0COMMA" + Math.random() + "\0";
|
|
9086
|
-
var escPeriod = "\0PERIOD" + Math.random() + "\0";
|
|
9087
|
-
function numeric(str2) {
|
|
9088
|
-
return parseInt(str2, 10) == str2 ? parseInt(str2, 10) : str2.charCodeAt(0);
|
|
9089
|
-
}
|
|
9090
|
-
function escapeBraces(str2) {
|
|
9091
|
-
return str2.split("\\\\").join(escSlash).split("\\{").join(escOpen).split("\\}").join(escClose).split("\\,").join(escComma).split("\\.").join(escPeriod);
|
|
9092
|
-
}
|
|
9093
|
-
function unescapeBraces(str2) {
|
|
9094
|
-
return str2.split(escSlash).join("\\").split(escOpen).join("{").split(escClose).join("}").split(escComma).join(",").split(escPeriod).join(".");
|
|
9095
|
-
}
|
|
9096
|
-
function parseCommaParts(str2) {
|
|
9097
|
-
if (!str2)
|
|
9098
|
-
return [""];
|
|
9099
|
-
var parts = [];
|
|
9100
|
-
var m = balanced("{", "}", str2);
|
|
9101
|
-
if (!m)
|
|
9102
|
-
return str2.split(",");
|
|
9103
|
-
var pre = m.pre;
|
|
9104
|
-
var body = m.body;
|
|
9105
|
-
var post = m.post;
|
|
9106
|
-
var p = pre.split(",");
|
|
9107
|
-
p[p.length - 1] += "{" + body + "}";
|
|
9108
|
-
var postParts = parseCommaParts(post);
|
|
9109
|
-
if (post.length) {
|
|
9110
|
-
p[p.length - 1] += postParts.shift();
|
|
9111
|
-
p.push.apply(p, postParts);
|
|
9112
|
-
}
|
|
9113
|
-
parts.push.apply(parts, p);
|
|
9114
|
-
return parts;
|
|
9115
|
-
}
|
|
9116
|
-
function expandTop(str2) {
|
|
9117
|
-
if (!str2)
|
|
9118
|
-
return [];
|
|
9119
|
-
if (str2.substr(0, 2) === "{}") {
|
|
9120
|
-
str2 = "\\{\\}" + str2.substr(2);
|
|
9121
|
-
}
|
|
9122
|
-
return expand2(escapeBraces(str2), true).map(unescapeBraces);
|
|
9123
|
-
}
|
|
9124
|
-
function embrace(str2) {
|
|
9125
|
-
return "{" + str2 + "}";
|
|
9126
|
-
}
|
|
9127
|
-
function isPadded(el) {
|
|
9128
|
-
return /^-?0\d/.test(el);
|
|
9129
|
-
}
|
|
9130
|
-
function lte(i2, y) {
|
|
9131
|
-
return i2 <= y;
|
|
9132
|
-
}
|
|
9133
|
-
function gte(i2, y) {
|
|
9134
|
-
return i2 >= y;
|
|
9135
|
-
}
|
|
9136
|
-
function expand2(str2, isTop) {
|
|
9137
|
-
var expansions = [];
|
|
9138
|
-
var m = balanced("{", "}", str2);
|
|
9139
|
-
if (!m) return [str2];
|
|
9140
|
-
var pre = m.pre;
|
|
9141
|
-
var post = m.post.length ? expand2(m.post, false) : [""];
|
|
9142
|
-
if (/\$$/.test(m.pre)) {
|
|
9143
|
-
for (var k = 0; k < post.length; k++) {
|
|
9144
|
-
var expansion = pre + "{" + m.body + "}" + post[k];
|
|
9145
|
-
expansions.push(expansion);
|
|
9146
|
-
}
|
|
9147
|
-
} else {
|
|
9148
|
-
var isNumericSequence = /^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(m.body);
|
|
9149
|
-
var isAlphaSequence = /^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(m.body);
|
|
9150
|
-
var isSequence = isNumericSequence || isAlphaSequence;
|
|
9151
|
-
var isOptions = m.body.indexOf(",") >= 0;
|
|
9152
|
-
if (!isSequence && !isOptions) {
|
|
9153
|
-
if (m.post.match(/,.*\}/)) {
|
|
9154
|
-
str2 = m.pre + "{" + m.body + escClose + m.post;
|
|
9155
|
-
return expand2(str2);
|
|
9156
|
-
}
|
|
9157
|
-
return [str2];
|
|
9158
|
-
}
|
|
9159
|
-
var n2;
|
|
9160
|
-
if (isSequence) {
|
|
9161
|
-
n2 = m.body.split(/\.\./);
|
|
9162
|
-
} else {
|
|
9163
|
-
n2 = parseCommaParts(m.body);
|
|
9164
|
-
if (n2.length === 1) {
|
|
9165
|
-
n2 = expand2(n2[0], false).map(embrace);
|
|
9166
|
-
if (n2.length === 1) {
|
|
9167
|
-
return post.map(function(p) {
|
|
9168
|
-
return m.pre + n2[0] + p;
|
|
9169
|
-
});
|
|
9170
|
-
}
|
|
9171
|
-
}
|
|
9172
|
-
}
|
|
9173
|
-
var N;
|
|
9174
|
-
if (isSequence) {
|
|
9175
|
-
var x = numeric(n2[0]);
|
|
9176
|
-
var y = numeric(n2[1]);
|
|
9177
|
-
var width = Math.max(n2[0].length, n2[1].length);
|
|
9178
|
-
var incr = n2.length == 3 ? Math.abs(numeric(n2[2])) : 1;
|
|
9179
|
-
var test = lte;
|
|
9180
|
-
var reverse = y < x;
|
|
9181
|
-
if (reverse) {
|
|
9182
|
-
incr *= -1;
|
|
9183
|
-
test = gte;
|
|
9184
|
-
}
|
|
9185
|
-
var pad = n2.some(isPadded);
|
|
9186
|
-
N = [];
|
|
9187
|
-
for (var i2 = x; test(i2, y); i2 += incr) {
|
|
9188
|
-
var c3;
|
|
9189
|
-
if (isAlphaSequence) {
|
|
9190
|
-
c3 = String.fromCharCode(i2);
|
|
9191
|
-
if (c3 === "\\")
|
|
9192
|
-
c3 = "";
|
|
9193
|
-
} else {
|
|
9194
|
-
c3 = String(i2);
|
|
9195
|
-
if (pad) {
|
|
9196
|
-
var need = width - c3.length;
|
|
9197
|
-
if (need > 0) {
|
|
9198
|
-
var z = new Array(need + 1).join("0");
|
|
9199
|
-
if (i2 < 0)
|
|
9200
|
-
c3 = "-" + z + c3.slice(1);
|
|
9201
|
-
else
|
|
9202
|
-
c3 = z + c3;
|
|
9203
|
-
}
|
|
9204
|
-
}
|
|
9205
|
-
}
|
|
9206
|
-
N.push(c3);
|
|
9207
|
-
}
|
|
9208
|
-
} else {
|
|
9209
|
-
N = [];
|
|
9210
|
-
for (var j = 0; j < n2.length; j++) {
|
|
9211
|
-
N.push.apply(N, expand2(n2[j], false));
|
|
9212
|
-
}
|
|
9213
|
-
}
|
|
9214
|
-
for (var j = 0; j < N.length; j++) {
|
|
9215
|
-
for (var k = 0; k < post.length; k++) {
|
|
9216
|
-
var expansion = pre + N[j] + post[k];
|
|
9217
|
-
if (!isTop || isSequence || expansion)
|
|
9218
|
-
expansions.push(expansion);
|
|
9219
|
-
}
|
|
9220
|
-
}
|
|
9221
|
-
}
|
|
9222
|
-
return expansions;
|
|
9223
|
-
}
|
|
9063
|
+
define(module.exports, Symbol.for("setupWindows"), setupWindows);
|
|
9224
9064
|
}
|
|
9225
9065
|
});
|
|
9226
9066
|
|
|
@@ -9230,7 +9070,7 @@ var require_commonjs = __commonJS({
|
|
|
9230
9070
|
"use strict";
|
|
9231
9071
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9232
9072
|
exports.LRUCache = void 0;
|
|
9233
|
-
var
|
|
9073
|
+
var defaultPerf = typeof performance === "object" && performance && typeof performance.now === "function" ? performance : Date;
|
|
9234
9074
|
var warned = /* @__PURE__ */ new Set();
|
|
9235
9075
|
var PROCESS = typeof process === "object" && !!process ? process : {};
|
|
9236
9076
|
var emitWarning = (msg, type2, code, fn) => {
|
|
@@ -9315,9 +9155,17 @@ var require_commonjs = __commonJS({
|
|
|
9315
9155
|
#max;
|
|
9316
9156
|
#maxSize;
|
|
9317
9157
|
#dispose;
|
|
9158
|
+
#onInsert;
|
|
9318
9159
|
#disposeAfter;
|
|
9319
9160
|
#fetchMethod;
|
|
9320
9161
|
#memoMethod;
|
|
9162
|
+
#perf;
|
|
9163
|
+
/**
|
|
9164
|
+
* {@link LRUCache.OptionsBase.perf}
|
|
9165
|
+
*/
|
|
9166
|
+
get perf() {
|
|
9167
|
+
return this.#perf;
|
|
9168
|
+
}
|
|
9321
9169
|
/**
|
|
9322
9170
|
* {@link LRUCache.OptionsBase.ttl}
|
|
9323
9171
|
*/
|
|
@@ -9396,6 +9244,7 @@ var require_commonjs = __commonJS({
|
|
|
9396
9244
|
#hasDispose;
|
|
9397
9245
|
#hasFetchMethod;
|
|
9398
9246
|
#hasDisposeAfter;
|
|
9247
|
+
#hasOnInsert;
|
|
9399
9248
|
/**
|
|
9400
9249
|
* Do not call this method unless you need to inspect the
|
|
9401
9250
|
* inner workings of the cache. If anything returned by this
|
|
@@ -9472,6 +9321,12 @@ var require_commonjs = __commonJS({
|
|
|
9472
9321
|
get dispose() {
|
|
9473
9322
|
return this.#dispose;
|
|
9474
9323
|
}
|
|
9324
|
+
/**
|
|
9325
|
+
* {@link LRUCache.OptionsBase.onInsert} (read-only)
|
|
9326
|
+
*/
|
|
9327
|
+
get onInsert() {
|
|
9328
|
+
return this.#onInsert;
|
|
9329
|
+
}
|
|
9475
9330
|
/**
|
|
9476
9331
|
* {@link LRUCache.OptionsBase.disposeAfter} (read-only)
|
|
9477
9332
|
*/
|
|
@@ -9479,7 +9334,13 @@ var require_commonjs = __commonJS({
|
|
|
9479
9334
|
return this.#disposeAfter;
|
|
9480
9335
|
}
|
|
9481
9336
|
constructor(options) {
|
|
9482
|
-
const { max = 0, ttl, ttlResolution = 1, ttlAutopurge, updateAgeOnGet, updateAgeOnHas, allowStale, dispose, disposeAfter, noDisposeOnSet, noUpdateTTL, maxSize = 0, maxEntrySize = 0, sizeCalculation, fetchMethod, memoMethod, noDeleteOnFetchRejection, noDeleteOnStaleGet, allowStaleOnFetchRejection, allowStaleOnFetchAbort, ignoreFetchAbort } = options;
|
|
9337
|
+
const { max = 0, ttl, ttlResolution = 1, ttlAutopurge, updateAgeOnGet, updateAgeOnHas, allowStale, dispose, onInsert, disposeAfter, noDisposeOnSet, noUpdateTTL, maxSize = 0, maxEntrySize = 0, sizeCalculation, fetchMethod, memoMethod, noDeleteOnFetchRejection, noDeleteOnStaleGet, allowStaleOnFetchRejection, allowStaleOnFetchAbort, ignoreFetchAbort, perf } = options;
|
|
9338
|
+
if (perf !== void 0) {
|
|
9339
|
+
if (typeof perf?.now !== "function") {
|
|
9340
|
+
throw new TypeError("perf option must have a now() method if specified");
|
|
9341
|
+
}
|
|
9342
|
+
}
|
|
9343
|
+
this.#perf = perf ?? defaultPerf;
|
|
9483
9344
|
if (max !== 0 && !isPosInt(max)) {
|
|
9484
9345
|
throw new TypeError("max option must be a nonnegative integer");
|
|
9485
9346
|
}
|
|
@@ -9521,6 +9382,9 @@ var require_commonjs = __commonJS({
|
|
|
9521
9382
|
if (typeof dispose === "function") {
|
|
9522
9383
|
this.#dispose = dispose;
|
|
9523
9384
|
}
|
|
9385
|
+
if (typeof onInsert === "function") {
|
|
9386
|
+
this.#onInsert = onInsert;
|
|
9387
|
+
}
|
|
9524
9388
|
if (typeof disposeAfter === "function") {
|
|
9525
9389
|
this.#disposeAfter = disposeAfter;
|
|
9526
9390
|
this.#disposed = [];
|
|
@@ -9529,6 +9393,7 @@ var require_commonjs = __commonJS({
|
|
|
9529
9393
|
this.#disposed = void 0;
|
|
9530
9394
|
}
|
|
9531
9395
|
this.#hasDispose = !!this.#dispose;
|
|
9396
|
+
this.#hasOnInsert = !!this.#onInsert;
|
|
9532
9397
|
this.#hasDisposeAfter = !!this.#disposeAfter;
|
|
9533
9398
|
this.noDisposeOnSet = !!noDisposeOnSet;
|
|
9534
9399
|
this.noUpdateTTL = !!noUpdateTTL;
|
|
@@ -9584,7 +9449,7 @@ var require_commonjs = __commonJS({
|
|
|
9584
9449
|
const starts = new ZeroArray(this.#max);
|
|
9585
9450
|
this.#ttls = ttls;
|
|
9586
9451
|
this.#starts = starts;
|
|
9587
|
-
this.#setItemTTL = (index, ttl, start = perf.now()) => {
|
|
9452
|
+
this.#setItemTTL = (index, ttl, start = this.#perf.now()) => {
|
|
9588
9453
|
starts[index] = ttl !== 0 ? start : 0;
|
|
9589
9454
|
ttls[index] = ttl;
|
|
9590
9455
|
if (ttl !== 0 && this.ttlAutopurge) {
|
|
@@ -9599,7 +9464,7 @@ var require_commonjs = __commonJS({
|
|
|
9599
9464
|
}
|
|
9600
9465
|
};
|
|
9601
9466
|
this.#updateItemAge = (index) => {
|
|
9602
|
-
starts[index] = ttls[index] !== 0 ? perf.now() : 0;
|
|
9467
|
+
starts[index] = ttls[index] !== 0 ? this.#perf.now() : 0;
|
|
9603
9468
|
};
|
|
9604
9469
|
this.#statusTTL = (status, index) => {
|
|
9605
9470
|
if (ttls[index]) {
|
|
@@ -9616,7 +9481,7 @@ var require_commonjs = __commonJS({
|
|
|
9616
9481
|
};
|
|
9617
9482
|
let cachedNow = 0;
|
|
9618
9483
|
const getNow = () => {
|
|
9619
|
-
const n2 = perf.now();
|
|
9484
|
+
const n2 = this.#perf.now();
|
|
9620
9485
|
if (this.ttlResolution > 0) {
|
|
9621
9486
|
cachedNow = n2;
|
|
9622
9487
|
const t = setTimeout(() => cachedNow = 0, this.ttlResolution);
|
|
@@ -9919,7 +9784,7 @@ var require_commonjs = __commonJS({
|
|
|
9919
9784
|
const ttl = this.#ttls[i2];
|
|
9920
9785
|
const start = this.#starts[i2];
|
|
9921
9786
|
if (ttl && start) {
|
|
9922
|
-
const remain = ttl - (perf.now() - start);
|
|
9787
|
+
const remain = ttl - (this.#perf.now() - start);
|
|
9923
9788
|
entry.ttl = remain;
|
|
9924
9789
|
entry.start = Date.now();
|
|
9925
9790
|
}
|
|
@@ -9931,7 +9796,7 @@ var require_commonjs = __commonJS({
|
|
|
9931
9796
|
}
|
|
9932
9797
|
/**
|
|
9933
9798
|
* Return an array of [key, {@link LRUCache.Entry}] tuples which can be
|
|
9934
|
-
* passed to {@link
|
|
9799
|
+
* passed to {@link LRUCache#load}.
|
|
9935
9800
|
*
|
|
9936
9801
|
* The `start` fields are calculated relative to a portable `Date.now()`
|
|
9937
9802
|
* timestamp, even if `performance.now()` is available.
|
|
@@ -9953,7 +9818,7 @@ var require_commonjs = __commonJS({
|
|
|
9953
9818
|
const entry = { value };
|
|
9954
9819
|
if (this.#ttls && this.#starts) {
|
|
9955
9820
|
entry.ttl = this.#ttls[i2];
|
|
9956
|
-
const age = perf.now() - this.#starts[i2];
|
|
9821
|
+
const age = this.#perf.now() - this.#starts[i2];
|
|
9957
9822
|
entry.start = Math.floor(Date.now() - age);
|
|
9958
9823
|
}
|
|
9959
9824
|
if (this.#sizes) {
|
|
@@ -9977,7 +9842,7 @@ var require_commonjs = __commonJS({
|
|
|
9977
9842
|
for (const [key, entry] of arr) {
|
|
9978
9843
|
if (entry.start) {
|
|
9979
9844
|
const age = Date.now() - entry.start;
|
|
9980
|
-
entry.start = perf.now() - age;
|
|
9845
|
+
entry.start = this.#perf.now() - age;
|
|
9981
9846
|
}
|
|
9982
9847
|
this.set(key, entry.value, entry);
|
|
9983
9848
|
}
|
|
@@ -10042,6 +9907,9 @@ var require_commonjs = __commonJS({
|
|
|
10042
9907
|
if (status)
|
|
10043
9908
|
status.set = "add";
|
|
10044
9909
|
noUpdateTTL = false;
|
|
9910
|
+
if (this.#hasOnInsert) {
|
|
9911
|
+
this.#onInsert?.(v, k, "add");
|
|
9912
|
+
}
|
|
10045
9913
|
} else {
|
|
10046
9914
|
this.#moveToTail(index);
|
|
10047
9915
|
const oldVal = this.#valList[index];
|
|
@@ -10077,6 +9945,9 @@ var require_commonjs = __commonJS({
|
|
|
10077
9945
|
} else if (status) {
|
|
10078
9946
|
status.set = "update";
|
|
10079
9947
|
}
|
|
9948
|
+
if (this.#hasOnInsert) {
|
|
9949
|
+
this.onInsert?.(v, k, v === oldVal ? "update" : "replace");
|
|
9950
|
+
}
|
|
10080
9951
|
}
|
|
10081
9952
|
if (ttl !== 0 && !this.#ttls) {
|
|
10082
9953
|
this.#initializeTTLTracking();
|
|
@@ -10246,7 +10117,7 @@ var require_commonjs = __commonJS({
|
|
|
10246
10117
|
const bf2 = p;
|
|
10247
10118
|
if (this.#valList[index] === p) {
|
|
10248
10119
|
if (v2 === void 0) {
|
|
10249
|
-
if (bf2.__staleWhileFetching) {
|
|
10120
|
+
if (bf2.__staleWhileFetching !== void 0) {
|
|
10250
10121
|
this.#valList[index] = bf2.__staleWhileFetching;
|
|
10251
10122
|
} else {
|
|
10252
10123
|
this.#delete(k, "fetch");
|
|
@@ -10923,6 +10794,23 @@ var require_lib = __commonJS({
|
|
|
10923
10794
|
var fromUrl = require_from_url();
|
|
10924
10795
|
var parseUrl = require_parse_url();
|
|
10925
10796
|
var cache2 = new LRUCache({ max: 1e3 });
|
|
10797
|
+
function unknownHostedUrl(url) {
|
|
10798
|
+
try {
|
|
10799
|
+
const {
|
|
10800
|
+
protocol,
|
|
10801
|
+
hostname,
|
|
10802
|
+
pathname
|
|
10803
|
+
} = new URL(url);
|
|
10804
|
+
if (!hostname) {
|
|
10805
|
+
return null;
|
|
10806
|
+
}
|
|
10807
|
+
const proto = /(?:git\+)http:$/.test(protocol) ? "http:" : "https:";
|
|
10808
|
+
const path22 = pathname.replace(/\.git$/, "");
|
|
10809
|
+
return `${proto}//${hostname}${path22}`;
|
|
10810
|
+
} catch {
|
|
10811
|
+
return null;
|
|
10812
|
+
}
|
|
10813
|
+
}
|
|
10926
10814
|
var GitHost = class _GitHost {
|
|
10927
10815
|
constructor(type2, user, auth, project, committish, defaultRepresentation, opts = {}) {
|
|
10928
10816
|
Object.assign(this, _GitHost.#gitHosts[type2], {
|
|
@@ -10965,6 +10853,22 @@ var require_lib = __commonJS({
|
|
|
10965
10853
|
}
|
|
10966
10854
|
return cache2.get(key);
|
|
10967
10855
|
}
|
|
10856
|
+
static fromManifest(manifest, opts = {}) {
|
|
10857
|
+
if (!manifest || typeof manifest !== "object") {
|
|
10858
|
+
return;
|
|
10859
|
+
}
|
|
10860
|
+
const r = manifest.repository;
|
|
10861
|
+
const rurl = r && (typeof r === "string" ? r : typeof r === "object" && typeof r.url === "string" ? r.url : null);
|
|
10862
|
+
if (!rurl) {
|
|
10863
|
+
throw new Error("no repository");
|
|
10864
|
+
}
|
|
10865
|
+
const info = rurl && _GitHost.fromUrl(rurl.replace(/^git\+/, ""), opts) || null;
|
|
10866
|
+
if (info) {
|
|
10867
|
+
return info;
|
|
10868
|
+
}
|
|
10869
|
+
const unk = unknownHostedUrl(rurl);
|
|
10870
|
+
return _GitHost.fromUrl(unk, opts) || unk;
|
|
10871
|
+
}
|
|
10968
10872
|
static parseUrl(url) {
|
|
10969
10873
|
return parseUrl(url);
|
|
10970
10874
|
}
|
|
@@ -11058,13 +10962,13 @@ var require_lib = __commonJS({
|
|
|
11058
10962
|
}
|
|
11059
10963
|
});
|
|
11060
10964
|
|
|
11061
|
-
// node_modules/
|
|
10965
|
+
// node_modules/validate-npm-package-name/lib/index.js
|
|
11062
10966
|
var require_lib2 = __commonJS({
|
|
11063
|
-
"node_modules/
|
|
10967
|
+
"node_modules/validate-npm-package-name/lib/index.js"(exports, module) {
|
|
11064
10968
|
"use strict";
|
|
11065
10969
|
var { builtinModules: builtins } = __require("module");
|
|
11066
10970
|
var scopedPackagePattern = new RegExp("^(?:@([^/]+?)[/])?([^/]+?)$");
|
|
11067
|
-
var
|
|
10971
|
+
var exclusionList = [
|
|
11068
10972
|
"node_modules",
|
|
11069
10973
|
"favicon.ico"
|
|
11070
10974
|
];
|
|
@@ -11086,7 +10990,7 @@ var require_lib2 = __commonJS({
|
|
|
11086
10990
|
if (!name.length) {
|
|
11087
10991
|
errors.push("name length must be greater than zero");
|
|
11088
10992
|
}
|
|
11089
|
-
if (name.
|
|
10993
|
+
if (name.startsWith(".")) {
|
|
11090
10994
|
errors.push("name cannot start with a period");
|
|
11091
10995
|
}
|
|
11092
10996
|
if (name.match(/^_/)) {
|
|
@@ -11095,9 +10999,9 @@ var require_lib2 = __commonJS({
|
|
|
11095
10999
|
if (name.trim() !== name) {
|
|
11096
11000
|
errors.push("name cannot contain leading or trailing spaces");
|
|
11097
11001
|
}
|
|
11098
|
-
|
|
11099
|
-
if (name.toLowerCase() ===
|
|
11100
|
-
errors.push(
|
|
11002
|
+
exclusionList.forEach(function(excludedName) {
|
|
11003
|
+
if (name.toLowerCase() === excludedName) {
|
|
11004
|
+
errors.push(excludedName + " is not a valid package name");
|
|
11101
11005
|
}
|
|
11102
11006
|
});
|
|
11103
11007
|
if (builtins.includes(name.toLowerCase())) {
|
|
@@ -11117,6 +11021,9 @@ var require_lib2 = __commonJS({
|
|
|
11117
11021
|
if (nameMatch) {
|
|
11118
11022
|
var user = nameMatch[1];
|
|
11119
11023
|
var pkg = nameMatch[2];
|
|
11024
|
+
if (pkg.startsWith(".")) {
|
|
11025
|
+
errors.push("name cannot start with a period");
|
|
11026
|
+
}
|
|
11120
11027
|
if (encodeURIComponent(user) === user && encodeURIComponent(pkg) === pkg) {
|
|
11121
11028
|
return done(warnings, errors);
|
|
11122
11029
|
}
|
|
@@ -11144,9 +11051,9 @@ var require_lib2 = __commonJS({
|
|
|
11144
11051
|
}
|
|
11145
11052
|
});
|
|
11146
11053
|
|
|
11147
|
-
// node_modules/
|
|
11054
|
+
// node_modules/proc-log/lib/index.js
|
|
11148
11055
|
var require_lib3 = __commonJS({
|
|
11149
|
-
"node_modules/
|
|
11056
|
+
"node_modules/proc-log/lib/index.js"(exports, module) {
|
|
11150
11057
|
var META = Symbol("proc-log.meta");
|
|
11151
11058
|
module.exports = {
|
|
11152
11059
|
META,
|
|
@@ -11308,7 +11215,7 @@ var require_npa = __commonJS({
|
|
|
11308
11215
|
"node_modules/npm-package-arg/lib/npa.js"(exports, module) {
|
|
11309
11216
|
"use strict";
|
|
11310
11217
|
var isWindows = process.platform === "win32";
|
|
11311
|
-
var { URL:
|
|
11218
|
+
var { URL: URL2 } = __require("node:url");
|
|
11312
11219
|
var path22 = isWindows ? __require("node:path/win32") : __require("node:path");
|
|
11313
11220
|
var { homedir } = __require("node:os");
|
|
11314
11221
|
var HostedGit = require_lib();
|
|
@@ -11564,8 +11471,8 @@ var require_npa = __commonJS({
|
|
|
11564
11471
|
let resolvedUrl;
|
|
11565
11472
|
let specUrl;
|
|
11566
11473
|
try {
|
|
11567
|
-
resolvedUrl = new
|
|
11568
|
-
specUrl = new
|
|
11474
|
+
resolvedUrl = new URL2(rawSpec, `${pathToFileURL3(path22.resolve(where))}/`);
|
|
11475
|
+
specUrl = new URL2(rawSpec);
|
|
11569
11476
|
} catch (originalError) {
|
|
11570
11477
|
const er = new Error("Invalid file: URL, must comply with RFC 8089");
|
|
11571
11478
|
throw Object.assign(er, {
|
|
@@ -11623,7 +11530,7 @@ var require_npa = __commonJS({
|
|
|
11623
11530
|
} else if (rawSpec.startsWith("git+file://")) {
|
|
11624
11531
|
rawSpec = rawSpec.replace(/\\/g, "/");
|
|
11625
11532
|
}
|
|
11626
|
-
const parsedUrl = new
|
|
11533
|
+
const parsedUrl = new URL2(rawSpec);
|
|
11627
11534
|
switch (parsedUrl.protocol) {
|
|
11628
11535
|
case "git:":
|
|
11629
11536
|
case "git+http:":
|
|
@@ -11678,10 +11585,10 @@ var require_npa = __commonJS({
|
|
|
11678
11585
|
res.saveSpec = null;
|
|
11679
11586
|
res.fetchSpec = spec;
|
|
11680
11587
|
const version = semver.valid(spec, true);
|
|
11681
|
-
const
|
|
11588
|
+
const range2 = semver.validRange(spec, true);
|
|
11682
11589
|
if (version) {
|
|
11683
11590
|
res.type = "version";
|
|
11684
|
-
} else if (
|
|
11591
|
+
} else if (range2) {
|
|
11685
11592
|
res.type = "range";
|
|
11686
11593
|
} else {
|
|
11687
11594
|
if (encodeURIComponent(spec) !== spec) {
|
|
@@ -11917,7 +11824,7 @@ var require_common3 = __commonJS({
|
|
|
11917
11824
|
createDebug2.namespaces = namespaces;
|
|
11918
11825
|
createDebug2.names = [];
|
|
11919
11826
|
createDebug2.skips = [];
|
|
11920
|
-
const split = (typeof namespaces === "string" ? namespaces : "").trim().replace(
|
|
11827
|
+
const split = (typeof namespaces === "string" ? namespaces : "").trim().replace(/\s+/g, ",").split(",").filter(Boolean);
|
|
11921
11828
|
for (const ns of split) {
|
|
11922
11829
|
if (ns[0] === "-") {
|
|
11923
11830
|
createDebug2.skips.push(ns.slice(1));
|
|
@@ -12135,7 +12042,7 @@ var require_browser = __commonJS({
|
|
|
12135
12042
|
function load3() {
|
|
12136
12043
|
let r;
|
|
12137
12044
|
try {
|
|
12138
|
-
r = exports.storage.getItem("debug");
|
|
12045
|
+
r = exports.storage.getItem("debug") || exports.storage.getItem("DEBUG");
|
|
12139
12046
|
} catch (error) {
|
|
12140
12047
|
}
|
|
12141
12048
|
if (!r && typeof process !== "undefined" && "env" in process) {
|
|
@@ -12990,12 +12897,15 @@ var require_spdx_license_ids = __commonJS({
|
|
|
12990
12897
|
"Artistic-1.0-Perl",
|
|
12991
12898
|
"Artistic-1.0-cl8",
|
|
12992
12899
|
"Artistic-2.0",
|
|
12900
|
+
"Artistic-dist",
|
|
12901
|
+
"Aspell-RU",
|
|
12993
12902
|
"BSD-1-Clause",
|
|
12994
12903
|
"BSD-2-Clause",
|
|
12995
12904
|
"BSD-2-Clause-Darwin",
|
|
12996
12905
|
"BSD-2-Clause-Patent",
|
|
12997
12906
|
"BSD-2-Clause-Views",
|
|
12998
12907
|
"BSD-2-Clause-first-lines",
|
|
12908
|
+
"BSD-2-Clause-pkgconf-disclaimer",
|
|
12999
12909
|
"BSD-3-Clause",
|
|
13000
12910
|
"BSD-3-Clause-Attribution",
|
|
13001
12911
|
"BSD-3-Clause-Clear",
|
|
@@ -13136,6 +13046,7 @@ var require_spdx_license_ids = __commonJS({
|
|
|
13136
13046
|
"Cornell-Lossless-JPEG",
|
|
13137
13047
|
"Cronyx",
|
|
13138
13048
|
"Crossword",
|
|
13049
|
+
"CryptoSwift",
|
|
13139
13050
|
"CrystalStacker",
|
|
13140
13051
|
"Cube",
|
|
13141
13052
|
"D-FSL-1.0",
|
|
@@ -13146,6 +13057,7 @@ var require_spdx_license_ids = __commonJS({
|
|
|
13146
13057
|
"DRL-1.0",
|
|
13147
13058
|
"DRL-1.1",
|
|
13148
13059
|
"DSDP",
|
|
13060
|
+
"DocBook-DTD",
|
|
13149
13061
|
"DocBook-Schema",
|
|
13150
13062
|
"DocBook-Stylesheet",
|
|
13151
13063
|
"DocBook-XML",
|
|
@@ -13171,7 +13083,10 @@ var require_spdx_license_ids = __commonJS({
|
|
|
13171
13083
|
"FSFAP-no-warranty-disclaimer",
|
|
13172
13084
|
"FSFUL",
|
|
13173
13085
|
"FSFULLR",
|
|
13086
|
+
"FSFULLRSD",
|
|
13174
13087
|
"FSFULLRWD",
|
|
13088
|
+
"FSL-1.1-ALv2",
|
|
13089
|
+
"FSL-1.1-MIT",
|
|
13175
13090
|
"FTL",
|
|
13176
13091
|
"Fair",
|
|
13177
13092
|
"Ferguson-Twofish",
|
|
@@ -13207,11 +13122,13 @@ var require_spdx_license_ids = __commonJS({
|
|
|
13207
13122
|
"GPL-2.0-or-later",
|
|
13208
13123
|
"GPL-3.0-only",
|
|
13209
13124
|
"GPL-3.0-or-later",
|
|
13125
|
+
"Game-Programming-Gems",
|
|
13210
13126
|
"Giftware",
|
|
13211
13127
|
"Glide",
|
|
13212
13128
|
"Glulxe",
|
|
13213
13129
|
"Graphics-Gems",
|
|
13214
13130
|
"Gutmann",
|
|
13131
|
+
"HDF5",
|
|
13215
13132
|
"HIDAPI",
|
|
13216
13133
|
"HP-1986",
|
|
13217
13134
|
"HP-1989",
|
|
@@ -13357,6 +13274,7 @@ var require_spdx_license_ids = __commonJS({
|
|
|
13357
13274
|
"NPL-1.1",
|
|
13358
13275
|
"NPOSL-3.0",
|
|
13359
13276
|
"NRL",
|
|
13277
|
+
"NTIA-PD",
|
|
13360
13278
|
"NTP",
|
|
13361
13279
|
"NTP-0",
|
|
13362
13280
|
"Naumen",
|
|
@@ -13459,11 +13377,13 @@ var require_spdx_license_ids = __commonJS({
|
|
|
13459
13377
|
"SMLNJ",
|
|
13460
13378
|
"SMPPL",
|
|
13461
13379
|
"SNIA",
|
|
13380
|
+
"SOFA",
|
|
13462
13381
|
"SPL-1.0",
|
|
13463
13382
|
"SSH-OpenSSH",
|
|
13464
13383
|
"SSH-short",
|
|
13465
13384
|
"SSLeay-standalone",
|
|
13466
13385
|
"SSPL-1.0",
|
|
13386
|
+
"SUL-1.0",
|
|
13467
13387
|
"SWL",
|
|
13468
13388
|
"Saxpath",
|
|
13469
13389
|
"SchemeReport",
|
|
@@ -13509,6 +13429,8 @@ var require_spdx_license_ids = __commonJS({
|
|
|
13509
13429
|
"Unicode-TOU",
|
|
13510
13430
|
"UnixCrypt",
|
|
13511
13431
|
"Unlicense",
|
|
13432
|
+
"Unlicense-libtelnet",
|
|
13433
|
+
"Unlicense-libwhirlpool",
|
|
13512
13434
|
"VOSTROM",
|
|
13513
13435
|
"VSL-1.0",
|
|
13514
13436
|
"Vim",
|
|
@@ -13562,6 +13484,8 @@ var require_spdx_license_ids = __commonJS({
|
|
|
13562
13484
|
"gtkbook",
|
|
13563
13485
|
"hdparm",
|
|
13564
13486
|
"iMatix",
|
|
13487
|
+
"jove",
|
|
13488
|
+
"libpng-1.6.35",
|
|
13565
13489
|
"libpng-2.0",
|
|
13566
13490
|
"libselinux-1.0",
|
|
13567
13491
|
"libtiff",
|
|
@@ -13569,10 +13493,12 @@ var require_spdx_license_ids = __commonJS({
|
|
|
13569
13493
|
"lsof",
|
|
13570
13494
|
"magaz",
|
|
13571
13495
|
"mailprio",
|
|
13496
|
+
"man2html",
|
|
13572
13497
|
"metamail",
|
|
13573
13498
|
"mpi-permissive",
|
|
13574
13499
|
"mpich2",
|
|
13575
13500
|
"mplus",
|
|
13501
|
+
"ngrep",
|
|
13576
13502
|
"pkgconf",
|
|
13577
13503
|
"pnmstitch",
|
|
13578
13504
|
"psfrag",
|
|
@@ -16820,6 +16746,9 @@ function indentString(string, count2 = 1, options = {}) {
|
|
|
16820
16746
|
return string.replace(regex, indent.repeat(count2));
|
|
16821
16747
|
}
|
|
16822
16748
|
|
|
16749
|
+
// node_modules/clean-stack/index.js
|
|
16750
|
+
import { fileURLToPath } from "node:url";
|
|
16751
|
+
|
|
16823
16752
|
// node_modules/escape-string-regexp/index.js
|
|
16824
16753
|
function escapeStringRegexp(string) {
|
|
16825
16754
|
if (typeof string !== "string") {
|
|
@@ -16857,7 +16786,14 @@ function cleanStack(stack, { pretty = false, basePath, pathFilter } = {}) {
|
|
|
16857
16786
|
line = line.replace(basePathRegex, "");
|
|
16858
16787
|
}
|
|
16859
16788
|
if (pretty) {
|
|
16860
|
-
line = line.replace(extractPathRegex, (m, p1) =>
|
|
16789
|
+
line = line.replace(extractPathRegex, (m, p1) => {
|
|
16790
|
+
let filePath = p1;
|
|
16791
|
+
if (filePath.startsWith("file://")) {
|
|
16792
|
+
filePath = fileURLToPath(filePath);
|
|
16793
|
+
}
|
|
16794
|
+
filePath = filePath.replace(homeDirectory, "~");
|
|
16795
|
+
return m.replace(p1, filePath);
|
|
16796
|
+
});
|
|
16861
16797
|
}
|
|
16862
16798
|
return line;
|
|
16863
16799
|
}).join("\n");
|
|
@@ -17047,7 +16983,7 @@ function isPlainObject(value) {
|
|
|
17047
16983
|
}
|
|
17048
16984
|
|
|
17049
16985
|
// node_modules/execa/lib/arguments/file-url.js
|
|
17050
|
-
import { fileURLToPath } from "node:url";
|
|
16986
|
+
import { fileURLToPath as fileURLToPath2 } from "node:url";
|
|
17051
16987
|
var safeNormalizeFileUrl = (file, name) => {
|
|
17052
16988
|
const fileString = normalizeFileUrl(normalizeDenoExecPath(file));
|
|
17053
16989
|
if (typeof fileString !== "string") {
|
|
@@ -17057,7 +16993,7 @@ var safeNormalizeFileUrl = (file, name) => {
|
|
|
17057
16993
|
};
|
|
17058
16994
|
var normalizeDenoExecPath = (file) => isDenoExecPath(file) ? file.toString() : file;
|
|
17059
16995
|
var isDenoExecPath = (file) => typeof file !== "string" && file && Object.getPrototypeOf(file) === String.prototype;
|
|
17060
|
-
var normalizeFileUrl = (file) => file instanceof URL ?
|
|
16996
|
+
var normalizeFileUrl = (file) => file instanceof URL ? fileURLToPath2(file) : file;
|
|
17061
16997
|
|
|
17062
16998
|
// node_modules/execa/lib/methods/parameters.js
|
|
17063
16999
|
var normalizeParameters = (rawFile, rawArguments = [], rawOptions = {}) => {
|
|
@@ -17677,8 +17613,10 @@ var format = (open, close) => {
|
|
|
17677
17613
|
}
|
|
17678
17614
|
let result = openCode;
|
|
17679
17615
|
let lastIndex = 0;
|
|
17616
|
+
const reopenOnNestedClose = close === 22;
|
|
17617
|
+
const replaceCode = (reopenOnNestedClose ? closeCode : "") + openCode;
|
|
17680
17618
|
while (index !== -1) {
|
|
17681
|
-
result += string.slice(lastIndex, index) +
|
|
17619
|
+
result += string.slice(lastIndex, index) + replaceCode;
|
|
17682
17620
|
lastIndex = index + closeCode.length;
|
|
17683
17621
|
index = string.indexOf(closeCode, lastIndex);
|
|
17684
17622
|
}
|
|
@@ -17903,10 +17841,10 @@ function pathKey(options = {}) {
|
|
|
17903
17841
|
import { promisify } from "node:util";
|
|
17904
17842
|
import { execFile as execFileCallback, execFileSync as execFileSyncOriginal } from "node:child_process";
|
|
17905
17843
|
import path2 from "node:path";
|
|
17906
|
-
import { fileURLToPath as
|
|
17844
|
+
import { fileURLToPath as fileURLToPath3 } from "node:url";
|
|
17907
17845
|
var execFileOriginal = promisify(execFileCallback);
|
|
17908
17846
|
function toPath(urlOrPath) {
|
|
17909
|
-
return urlOrPath instanceof URL ?
|
|
17847
|
+
return urlOrPath instanceof URL ? fileURLToPath3(urlOrPath) : urlOrPath;
|
|
17910
17848
|
}
|
|
17911
17849
|
function traversePathUp(startPath) {
|
|
17912
17850
|
return {
|
|
@@ -19330,6 +19268,9 @@ var getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, no
|
|
|
19330
19268
|
return env;
|
|
19331
19269
|
};
|
|
19332
19270
|
|
|
19271
|
+
// node_modules/execa/lib/arguments/shell.js
|
|
19272
|
+
var concatenateShell = (file, commandArguments, options) => options.shell && commandArguments.length > 0 ? [[file, ...commandArguments].join(" "), [], options] : [file, commandArguments, options];
|
|
19273
|
+
|
|
19333
19274
|
// node_modules/execa/lib/return/message.js
|
|
19334
19275
|
import { inspect as inspect2 } from "node:util";
|
|
19335
19276
|
|
|
@@ -20168,7 +20109,7 @@ function prettyMilliseconds(milliseconds, options) {
|
|
|
20168
20109
|
}
|
|
20169
20110
|
add(Number(parsed.minutes), "minute", "m");
|
|
20170
20111
|
if (!options.hideSeconds) {
|
|
20171
|
-
if (options.separateMilliseconds || options.formatSubMilliseconds || !options.colonNotation && milliseconds < 1e3) {
|
|
20112
|
+
if (options.separateMilliseconds || options.formatSubMilliseconds || !options.colonNotation && milliseconds < 1e3 && !options.subSecondsAsDecimals) {
|
|
20172
20113
|
const seconds = Number(parsed.seconds);
|
|
20173
20114
|
const milliseconds2 = Number(parsed.milliseconds);
|
|
20174
20115
|
const microseconds = Number(parsed.microseconds);
|
|
@@ -20717,7 +20658,7 @@ var getDuplicateStream = ({ stdioItem: { type: type2, value, optionName }, direc
|
|
|
20717
20658
|
});
|
|
20718
20659
|
}
|
|
20719
20660
|
};
|
|
20720
|
-
var getOtherStdioItems = (fileDescriptors, type2) => fileDescriptors.flatMap(({ direction, stdioItems }) => stdioItems.filter((stdioItem) => stdioItem.type === type2).map((stdioItem) => ({ ...stdioItem, direction })));
|
|
20661
|
+
var getOtherStdioItems = (fileDescriptors, type2) => fileDescriptors.flatMap(({ direction, stdioItems }) => stdioItems.filter((stdioItem) => stdioItem.type === type2).map(((stdioItem) => ({ ...stdioItem, direction }))));
|
|
20721
20662
|
var validateDuplicateStreamSync = ({ otherStdioItems, type: type2, value, optionName, direction }) => {
|
|
20722
20663
|
if (SPECIAL_DUPLICATE_TYPES_SYNC.has(type2)) {
|
|
20723
20664
|
getDuplicateStreamInstance({
|
|
@@ -21592,7 +21533,7 @@ var runSubprocessSync = ({ file, commandArguments, options, command, escapedComm
|
|
|
21592
21533
|
try {
|
|
21593
21534
|
addInputOptionsSync(fileDescriptors, options);
|
|
21594
21535
|
const normalizedOptions = normalizeSpawnSyncOptions(options);
|
|
21595
|
-
return spawnSync(file, commandArguments, normalizedOptions);
|
|
21536
|
+
return spawnSync(...concatenateShell(file, commandArguments, normalizedOptions));
|
|
21596
21537
|
} catch (error) {
|
|
21597
21538
|
return makeEarlyError({
|
|
21598
21539
|
error,
|
|
@@ -23585,7 +23526,7 @@ var handleAsyncOptions = ({ timeout, signal, ...options }) => {
|
|
|
23585
23526
|
var spawnSubprocessAsync = ({ file, commandArguments, options, startTime, verboseInfo, command, escapedCommand, fileDescriptors }) => {
|
|
23586
23527
|
let subprocess;
|
|
23587
23528
|
try {
|
|
23588
|
-
subprocess = spawn(file, commandArguments, options);
|
|
23529
|
+
subprocess = spawn(...concatenateShell(file, commandArguments, options));
|
|
23589
23530
|
} catch (error) {
|
|
23590
23531
|
return handleEarlyError({
|
|
23591
23532
|
error,
|
|
@@ -26697,7 +26638,7 @@ function chooseScalarStyle(string, singleLineOnly, indentPerLevel, lineWidth, te
|
|
|
26697
26638
|
return quotingType === QUOTING_TYPE_DOUBLE ? STYLE_DOUBLE : STYLE_SINGLE;
|
|
26698
26639
|
}
|
|
26699
26640
|
function writeScalar(state, string, level, iskey, inblock) {
|
|
26700
|
-
state.dump = function() {
|
|
26641
|
+
state.dump = (function() {
|
|
26701
26642
|
if (string.length === 0) {
|
|
26702
26643
|
return state.quotingType === QUOTING_TYPE_DOUBLE ? '""' : "''";
|
|
26703
26644
|
}
|
|
@@ -26735,7 +26676,7 @@ function writeScalar(state, string, level, iskey, inblock) {
|
|
|
26735
26676
|
default:
|
|
26736
26677
|
throw new exception("impossible error: invalid scalar style");
|
|
26737
26678
|
}
|
|
26738
|
-
}();
|
|
26679
|
+
})();
|
|
26739
26680
|
}
|
|
26740
26681
|
function blockHeader(string, indentPerLevel) {
|
|
26741
26682
|
var indentIndicator = needIndentIndicator(string) ? String(indentPerLevel) : "";
|
|
@@ -26749,12 +26690,12 @@ function dropEndingNewline(string) {
|
|
|
26749
26690
|
}
|
|
26750
26691
|
function foldString(string, width) {
|
|
26751
26692
|
var lineRe = /(\n+)([^\n]*)/g;
|
|
26752
|
-
var result = function() {
|
|
26693
|
+
var result = (function() {
|
|
26753
26694
|
var nextLF = string.indexOf("\n");
|
|
26754
26695
|
nextLF = nextLF !== -1 ? nextLF : string.length;
|
|
26755
26696
|
lineRe.lastIndex = nextLF;
|
|
26756
26697
|
return foldLine(string.slice(0, nextLF), width);
|
|
26757
|
-
}();
|
|
26698
|
+
})();
|
|
26758
26699
|
var prevMoreIndented = string[0] === "\n" || string[0] === " ";
|
|
26759
26700
|
var moreIndented;
|
|
26760
26701
|
var match2;
|
|
@@ -27273,8 +27214,216 @@ function hasTags(opts, logger) {
|
|
|
27273
27214
|
// src/utils/make-diff-predicate.js
|
|
27274
27215
|
import path12 from "node:path/posix";
|
|
27275
27216
|
|
|
27276
|
-
// node_modules/
|
|
27277
|
-
var
|
|
27217
|
+
// node_modules/@isaacs/balanced-match/dist/esm/index.js
|
|
27218
|
+
var balanced = (a2, b, str2) => {
|
|
27219
|
+
const ma = a2 instanceof RegExp ? maybeMatch(a2, str2) : a2;
|
|
27220
|
+
const mb = b instanceof RegExp ? maybeMatch(b, str2) : b;
|
|
27221
|
+
const r = ma !== null && mb != null && range(ma, mb, str2);
|
|
27222
|
+
return r && {
|
|
27223
|
+
start: r[0],
|
|
27224
|
+
end: r[1],
|
|
27225
|
+
pre: str2.slice(0, r[0]),
|
|
27226
|
+
body: str2.slice(r[0] + ma.length, r[1]),
|
|
27227
|
+
post: str2.slice(r[1] + mb.length)
|
|
27228
|
+
};
|
|
27229
|
+
};
|
|
27230
|
+
var maybeMatch = (reg, str2) => {
|
|
27231
|
+
const m = str2.match(reg);
|
|
27232
|
+
return m ? m[0] : null;
|
|
27233
|
+
};
|
|
27234
|
+
var range = (a2, b, str2) => {
|
|
27235
|
+
let begs, beg, left, right = void 0, result;
|
|
27236
|
+
let ai = str2.indexOf(a2);
|
|
27237
|
+
let bi = str2.indexOf(b, ai + 1);
|
|
27238
|
+
let i2 = ai;
|
|
27239
|
+
if (ai >= 0 && bi > 0) {
|
|
27240
|
+
if (a2 === b) {
|
|
27241
|
+
return [ai, bi];
|
|
27242
|
+
}
|
|
27243
|
+
begs = [];
|
|
27244
|
+
left = str2.length;
|
|
27245
|
+
while (i2 >= 0 && !result) {
|
|
27246
|
+
if (i2 === ai) {
|
|
27247
|
+
begs.push(i2);
|
|
27248
|
+
ai = str2.indexOf(a2, i2 + 1);
|
|
27249
|
+
} else if (begs.length === 1) {
|
|
27250
|
+
const r = begs.pop();
|
|
27251
|
+
if (r !== void 0)
|
|
27252
|
+
result = [r, bi];
|
|
27253
|
+
} else {
|
|
27254
|
+
beg = begs.pop();
|
|
27255
|
+
if (beg !== void 0 && beg < left) {
|
|
27256
|
+
left = beg;
|
|
27257
|
+
right = bi;
|
|
27258
|
+
}
|
|
27259
|
+
bi = str2.indexOf(b, i2 + 1);
|
|
27260
|
+
}
|
|
27261
|
+
i2 = ai < bi && ai >= 0 ? ai : bi;
|
|
27262
|
+
}
|
|
27263
|
+
if (begs.length && right !== void 0) {
|
|
27264
|
+
result = [left, right];
|
|
27265
|
+
}
|
|
27266
|
+
}
|
|
27267
|
+
return result;
|
|
27268
|
+
};
|
|
27269
|
+
|
|
27270
|
+
// node_modules/@isaacs/brace-expansion/dist/esm/index.js
|
|
27271
|
+
var escSlash = "\0SLASH" + Math.random() + "\0";
|
|
27272
|
+
var escOpen = "\0OPEN" + Math.random() + "\0";
|
|
27273
|
+
var escClose = "\0CLOSE" + Math.random() + "\0";
|
|
27274
|
+
var escComma = "\0COMMA" + Math.random() + "\0";
|
|
27275
|
+
var escPeriod = "\0PERIOD" + Math.random() + "\0";
|
|
27276
|
+
var escSlashPattern = new RegExp(escSlash, "g");
|
|
27277
|
+
var escOpenPattern = new RegExp(escOpen, "g");
|
|
27278
|
+
var escClosePattern = new RegExp(escClose, "g");
|
|
27279
|
+
var escCommaPattern = new RegExp(escComma, "g");
|
|
27280
|
+
var escPeriodPattern = new RegExp(escPeriod, "g");
|
|
27281
|
+
var slashPattern = /\\\\/g;
|
|
27282
|
+
var openPattern = /\\{/g;
|
|
27283
|
+
var closePattern = /\\}/g;
|
|
27284
|
+
var commaPattern = /\\,/g;
|
|
27285
|
+
var periodPattern = /\\./g;
|
|
27286
|
+
function numeric(str2) {
|
|
27287
|
+
return !isNaN(str2) ? parseInt(str2, 10) : str2.charCodeAt(0);
|
|
27288
|
+
}
|
|
27289
|
+
function escapeBraces(str2) {
|
|
27290
|
+
return str2.replace(slashPattern, escSlash).replace(openPattern, escOpen).replace(closePattern, escClose).replace(commaPattern, escComma).replace(periodPattern, escPeriod);
|
|
27291
|
+
}
|
|
27292
|
+
function unescapeBraces(str2) {
|
|
27293
|
+
return str2.replace(escSlashPattern, "\\").replace(escOpenPattern, "{").replace(escClosePattern, "}").replace(escCommaPattern, ",").replace(escPeriodPattern, ".");
|
|
27294
|
+
}
|
|
27295
|
+
function parseCommaParts(str2) {
|
|
27296
|
+
if (!str2) {
|
|
27297
|
+
return [""];
|
|
27298
|
+
}
|
|
27299
|
+
const parts = [];
|
|
27300
|
+
const m = balanced("{", "}", str2);
|
|
27301
|
+
if (!m) {
|
|
27302
|
+
return str2.split(",");
|
|
27303
|
+
}
|
|
27304
|
+
const { pre, body, post } = m;
|
|
27305
|
+
const p = pre.split(",");
|
|
27306
|
+
p[p.length - 1] += "{" + body + "}";
|
|
27307
|
+
const postParts = parseCommaParts(post);
|
|
27308
|
+
if (post.length) {
|
|
27309
|
+
;
|
|
27310
|
+
p[p.length - 1] += postParts.shift();
|
|
27311
|
+
p.push.apply(p, postParts);
|
|
27312
|
+
}
|
|
27313
|
+
parts.push.apply(parts, p);
|
|
27314
|
+
return parts;
|
|
27315
|
+
}
|
|
27316
|
+
function expand(str2) {
|
|
27317
|
+
if (!str2) {
|
|
27318
|
+
return [];
|
|
27319
|
+
}
|
|
27320
|
+
if (str2.slice(0, 2) === "{}") {
|
|
27321
|
+
str2 = "\\{\\}" + str2.slice(2);
|
|
27322
|
+
}
|
|
27323
|
+
return expand_(escapeBraces(str2), true).map(unescapeBraces);
|
|
27324
|
+
}
|
|
27325
|
+
function embrace(str2) {
|
|
27326
|
+
return "{" + str2 + "}";
|
|
27327
|
+
}
|
|
27328
|
+
function isPadded(el) {
|
|
27329
|
+
return /^-?0\d/.test(el);
|
|
27330
|
+
}
|
|
27331
|
+
function lte(i2, y) {
|
|
27332
|
+
return i2 <= y;
|
|
27333
|
+
}
|
|
27334
|
+
function gte(i2, y) {
|
|
27335
|
+
return i2 >= y;
|
|
27336
|
+
}
|
|
27337
|
+
function expand_(str2, isTop) {
|
|
27338
|
+
const expansions = [];
|
|
27339
|
+
const m = balanced("{", "}", str2);
|
|
27340
|
+
if (!m)
|
|
27341
|
+
return [str2];
|
|
27342
|
+
const pre = m.pre;
|
|
27343
|
+
const post = m.post.length ? expand_(m.post, false) : [""];
|
|
27344
|
+
if (/\$$/.test(m.pre)) {
|
|
27345
|
+
for (let k = 0; k < post.length; k++) {
|
|
27346
|
+
const expansion = pre + "{" + m.body + "}" + post[k];
|
|
27347
|
+
expansions.push(expansion);
|
|
27348
|
+
}
|
|
27349
|
+
} else {
|
|
27350
|
+
const isNumericSequence = /^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(m.body);
|
|
27351
|
+
const isAlphaSequence = /^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(m.body);
|
|
27352
|
+
const isSequence = isNumericSequence || isAlphaSequence;
|
|
27353
|
+
const isOptions = m.body.indexOf(",") >= 0;
|
|
27354
|
+
if (!isSequence && !isOptions) {
|
|
27355
|
+
if (m.post.match(/,(?!,).*\}/)) {
|
|
27356
|
+
str2 = m.pre + "{" + m.body + escClose + m.post;
|
|
27357
|
+
return expand_(str2);
|
|
27358
|
+
}
|
|
27359
|
+
return [str2];
|
|
27360
|
+
}
|
|
27361
|
+
let n2;
|
|
27362
|
+
if (isSequence) {
|
|
27363
|
+
n2 = m.body.split(/\.\./);
|
|
27364
|
+
} else {
|
|
27365
|
+
n2 = parseCommaParts(m.body);
|
|
27366
|
+
if (n2.length === 1 && n2[0] !== void 0) {
|
|
27367
|
+
n2 = expand_(n2[0], false).map(embrace);
|
|
27368
|
+
if (n2.length === 1) {
|
|
27369
|
+
return post.map((p) => m.pre + n2[0] + p);
|
|
27370
|
+
}
|
|
27371
|
+
}
|
|
27372
|
+
}
|
|
27373
|
+
let N;
|
|
27374
|
+
if (isSequence && n2[0] !== void 0 && n2[1] !== void 0) {
|
|
27375
|
+
const x = numeric(n2[0]);
|
|
27376
|
+
const y = numeric(n2[1]);
|
|
27377
|
+
const width = Math.max(n2[0].length, n2[1].length);
|
|
27378
|
+
let incr = n2.length === 3 && n2[2] !== void 0 ? Math.abs(numeric(n2[2])) : 1;
|
|
27379
|
+
let test = lte;
|
|
27380
|
+
const reverse = y < x;
|
|
27381
|
+
if (reverse) {
|
|
27382
|
+
incr *= -1;
|
|
27383
|
+
test = gte;
|
|
27384
|
+
}
|
|
27385
|
+
const pad = n2.some(isPadded);
|
|
27386
|
+
N = [];
|
|
27387
|
+
for (let i2 = x; test(i2, y); i2 += incr) {
|
|
27388
|
+
let c3;
|
|
27389
|
+
if (isAlphaSequence) {
|
|
27390
|
+
c3 = String.fromCharCode(i2);
|
|
27391
|
+
if (c3 === "\\") {
|
|
27392
|
+
c3 = "";
|
|
27393
|
+
}
|
|
27394
|
+
} else {
|
|
27395
|
+
c3 = String(i2);
|
|
27396
|
+
if (pad) {
|
|
27397
|
+
const need = width - c3.length;
|
|
27398
|
+
if (need > 0) {
|
|
27399
|
+
const z = new Array(need + 1).join("0");
|
|
27400
|
+
if (i2 < 0) {
|
|
27401
|
+
c3 = "-" + z + c3.slice(1);
|
|
27402
|
+
} else {
|
|
27403
|
+
c3 = z + c3;
|
|
27404
|
+
}
|
|
27405
|
+
}
|
|
27406
|
+
}
|
|
27407
|
+
}
|
|
27408
|
+
N.push(c3);
|
|
27409
|
+
}
|
|
27410
|
+
} else {
|
|
27411
|
+
N = [];
|
|
27412
|
+
for (let j = 0; j < n2.length; j++) {
|
|
27413
|
+
N.push.apply(N, expand_(n2[j], false));
|
|
27414
|
+
}
|
|
27415
|
+
}
|
|
27416
|
+
for (let j = 0; j < N.length; j++) {
|
|
27417
|
+
for (let k = 0; k < post.length; k++) {
|
|
27418
|
+
const expansion = pre + N[j] + post[k];
|
|
27419
|
+
if (!isTop || isSequence || expansion) {
|
|
27420
|
+
expansions.push(expansion);
|
|
27421
|
+
}
|
|
27422
|
+
}
|
|
27423
|
+
}
|
|
27424
|
+
}
|
|
27425
|
+
return expansions;
|
|
27426
|
+
}
|
|
27278
27427
|
|
|
27279
27428
|
// node_modules/minimatch/dist/esm/assert-valid-pattern.js
|
|
27280
27429
|
var MAX_PATTERN_LENGTH = 1024 * 64;
|
|
@@ -28001,7 +28150,7 @@ var braceExpand = (pattern, options = {}) => {
|
|
|
28001
28150
|
if (options.nobrace || !/\{(?:(?!\{).)*\}/.test(pattern)) {
|
|
28002
28151
|
return [pattern];
|
|
28003
28152
|
}
|
|
28004
|
-
return (
|
|
28153
|
+
return expand(pattern);
|
|
28005
28154
|
};
|
|
28006
28155
|
minimatch.braceExpand = braceExpand;
|
|
28007
28156
|
var makeRe = (pattern, options = {}) => new Minimatch(pattern, options).makeRe();
|
|
@@ -28653,6 +28802,9 @@ import fs6 from "node:fs/promises";
|
|
|
28653
28802
|
var INDENT_REGEX = /^(?:( )+|\t+)/;
|
|
28654
28803
|
var INDENT_TYPE_SPACE = "space";
|
|
28655
28804
|
var INDENT_TYPE_TAB = "tab";
|
|
28805
|
+
function shouldIgnoreSingleSpace(ignoreSingleSpaces, indentType, value) {
|
|
28806
|
+
return ignoreSingleSpaces && indentType === INDENT_TYPE_SPACE && value === 1;
|
|
28807
|
+
}
|
|
28656
28808
|
function makeIndentsMap(string, ignoreSingleSpaces) {
|
|
28657
28809
|
const indents = /* @__PURE__ */ new Map();
|
|
28658
28810
|
let previousSize = 0;
|
|
@@ -28662,39 +28814,36 @@ function makeIndentsMap(string, ignoreSingleSpaces) {
|
|
|
28662
28814
|
if (!line) {
|
|
28663
28815
|
continue;
|
|
28664
28816
|
}
|
|
28665
|
-
let indent;
|
|
28666
|
-
let indentType;
|
|
28667
|
-
let use;
|
|
28668
|
-
let weight;
|
|
28669
|
-
let entry;
|
|
28670
28817
|
const matches = line.match(INDENT_REGEX);
|
|
28671
28818
|
if (matches === null) {
|
|
28672
28819
|
previousSize = 0;
|
|
28673
28820
|
previousIndentType = "";
|
|
28674
28821
|
} else {
|
|
28675
|
-
indent = matches[0].length;
|
|
28676
|
-
indentType = matches[1] ? INDENT_TYPE_SPACE : INDENT_TYPE_TAB;
|
|
28677
|
-
if (ignoreSingleSpaces
|
|
28822
|
+
const indent = matches[0].length;
|
|
28823
|
+
const indentType = matches[1] ? INDENT_TYPE_SPACE : INDENT_TYPE_TAB;
|
|
28824
|
+
if (shouldIgnoreSingleSpace(ignoreSingleSpaces, indentType, indent)) {
|
|
28678
28825
|
continue;
|
|
28679
28826
|
}
|
|
28680
28827
|
if (indentType !== previousIndentType) {
|
|
28681
28828
|
previousSize = 0;
|
|
28682
28829
|
}
|
|
28683
28830
|
previousIndentType = indentType;
|
|
28684
|
-
use = 1;
|
|
28685
|
-
weight = 0;
|
|
28831
|
+
let use = 1;
|
|
28832
|
+
let weight = 0;
|
|
28686
28833
|
const indentDifference = indent - previousSize;
|
|
28687
28834
|
previousSize = indent;
|
|
28688
28835
|
if (indentDifference === 0) {
|
|
28689
28836
|
use = 0;
|
|
28690
28837
|
weight = 1;
|
|
28691
28838
|
} else {
|
|
28692
|
-
const absoluteIndentDifference = indentDifference
|
|
28839
|
+
const absoluteIndentDifference = Math.abs(indentDifference);
|
|
28840
|
+
if (shouldIgnoreSingleSpace(ignoreSingleSpaces, indentType, absoluteIndentDifference)) {
|
|
28841
|
+
continue;
|
|
28842
|
+
}
|
|
28693
28843
|
key = encodeIndentsKey(indentType, absoluteIndentDifference);
|
|
28694
28844
|
}
|
|
28695
|
-
entry = indents.get(key);
|
|
28696
|
-
|
|
28697
|
-
indents.set(key, entry);
|
|
28845
|
+
const entry = indents.get(key);
|
|
28846
|
+
indents.set(key, entry === void 0 ? [1, 0] : [entry[0] + use, entry[1] + weight]);
|
|
28698
28847
|
}
|
|
28699
28848
|
}
|
|
28700
28849
|
return indents;
|
|
@@ -29217,7 +29366,7 @@ function bumpDependency(dependencies, newVersion, currentVersions) {
|
|
|
29217
29366
|
if (!newParsed) {
|
|
29218
29367
|
return;
|
|
29219
29368
|
}
|
|
29220
|
-
for (const [dep,
|
|
29369
|
+
for (const [dep, range2] of Object.entries(dependencies)) {
|
|
29221
29370
|
if (!currentVersions[dep]) {
|
|
29222
29371
|
continue;
|
|
29223
29372
|
}
|
|
@@ -29226,27 +29375,27 @@ function bumpDependency(dependencies, newVersion, currentVersions) {
|
|
|
29226
29375
|
if (!parsed) {
|
|
29227
29376
|
continue;
|
|
29228
29377
|
}
|
|
29229
|
-
if (
|
|
29378
|
+
if (range2 === version) {
|
|
29230
29379
|
dependencies[dep] = newVersion;
|
|
29231
29380
|
continue;
|
|
29232
29381
|
}
|
|
29233
|
-
if (
|
|
29382
|
+
if (range2 === `^${version}`) {
|
|
29234
29383
|
dependencies[dep] = `^${newVersion}`;
|
|
29235
29384
|
continue;
|
|
29236
29385
|
}
|
|
29237
|
-
if (
|
|
29386
|
+
if (range2 === `^${parsed.major}.${parsed.minor}`) {
|
|
29238
29387
|
dependencies[dep] = `^${newParsed.major}.${newParsed.minor}`;
|
|
29239
29388
|
continue;
|
|
29240
29389
|
}
|
|
29241
|
-
if (
|
|
29390
|
+
if (range2 === `^${parsed.major}`) {
|
|
29242
29391
|
dependencies[dep] = `^${newParsed.major}`;
|
|
29243
29392
|
continue;
|
|
29244
29393
|
}
|
|
29245
|
-
if ((0, import_semver.validRange)(
|
|
29246
|
-
const isSatisfied = (0, import_semver.satisfies)(newVersion,
|
|
29394
|
+
if ((0, import_semver.validRange)(range2)) {
|
|
29395
|
+
const isSatisfied = (0, import_semver.satisfies)(newVersion, range2);
|
|
29247
29396
|
if (!isSatisfied) {
|
|
29248
|
-
const hat =
|
|
29249
|
-
const numComponents = Array.from(
|
|
29397
|
+
const hat = range2.startsWith("^") ? "^" : "";
|
|
29398
|
+
const numComponents = Array.from(range2).filter((it) => it === ".").length + 1;
|
|
29250
29399
|
const components = [newParsed.major, newParsed.minor, newParsed.patch];
|
|
29251
29400
|
dependencies[dep] = `${hat}${components.slice(0, numComponents).join(".")}`;
|
|
29252
29401
|
}
|
|
@@ -29377,6 +29526,8 @@ function normalizeUrl(urlString, options) {
|
|
|
29377
29526
|
removeDirectoryIndex: false,
|
|
29378
29527
|
removeExplicitPort: false,
|
|
29379
29528
|
sortQueryParameters: true,
|
|
29529
|
+
removePath: false,
|
|
29530
|
+
transformPath: false,
|
|
29380
29531
|
...options
|
|
29381
29532
|
};
|
|
29382
29533
|
if (typeof options.defaultProtocol === "string" && !options.defaultProtocol.endsWith(":")) {
|
|
@@ -29435,7 +29586,7 @@ function normalizeUrl(urlString, options) {
|
|
|
29435
29586
|
}
|
|
29436
29587
|
if (urlObject.pathname) {
|
|
29437
29588
|
try {
|
|
29438
|
-
urlObject.pathname = decodeURI(urlObject.pathname);
|
|
29589
|
+
urlObject.pathname = decodeURI(urlObject.pathname).replace(/\\/g, "%5C");
|
|
29439
29590
|
} catch {
|
|
29440
29591
|
}
|
|
29441
29592
|
}
|
|
@@ -29450,6 +29601,14 @@ function normalizeUrl(urlString, options) {
|
|
|
29450
29601
|
urlObject.pathname = pathComponents.slice(1).join("/") + "/";
|
|
29451
29602
|
}
|
|
29452
29603
|
}
|
|
29604
|
+
if (options.removePath) {
|
|
29605
|
+
urlObject.pathname = "/";
|
|
29606
|
+
}
|
|
29607
|
+
if (options.transformPath && typeof options.transformPath === "function") {
|
|
29608
|
+
const pathComponents = urlObject.pathname.split("/").filter(Boolean);
|
|
29609
|
+
const newComponents = options.transformPath(pathComponents);
|
|
29610
|
+
urlObject.pathname = newComponents?.length > 0 ? `/${newComponents.join("/")}` : "/";
|
|
29611
|
+
}
|
|
29453
29612
|
if (urlObject.hostname) {
|
|
29454
29613
|
urlObject.hostname = urlObject.hostname.replace(/\.$/, "");
|
|
29455
29614
|
if (options.stripWWW && /^www\.(?!www\.)[a-z\-\d]{1,63}\.[a-z.\-\d]{2,63}$/.test(urlObject.hostname)) {
|
|
@@ -29474,11 +29633,17 @@ function normalizeUrl(urlString, options) {
|
|
|
29474
29633
|
}
|
|
29475
29634
|
}
|
|
29476
29635
|
if (options.sortQueryParameters) {
|
|
29636
|
+
const originalSearch = urlObject.search;
|
|
29477
29637
|
urlObject.searchParams.sort();
|
|
29478
29638
|
try {
|
|
29479
29639
|
urlObject.search = decodeURIComponent(urlObject.search);
|
|
29480
29640
|
} catch {
|
|
29481
29641
|
}
|
|
29642
|
+
const partsWithoutEquals = originalSearch.slice(1).split("&").filter((p) => p && !p.includes("="));
|
|
29643
|
+
for (const part of partsWithoutEquals) {
|
|
29644
|
+
const decoded = decodeURIComponent(part);
|
|
29645
|
+
urlObject.search = urlObject.search.replace(`?${decoded}=`, `?${decoded}`).replace(`&${decoded}=`, `&${decoded}`);
|
|
29646
|
+
}
|
|
29482
29647
|
}
|
|
29483
29648
|
if (options.removeTrailingSlash) {
|
|
29484
29649
|
urlObject.pathname = urlObject.pathname.replace(/\/$/, "");
|
|
@@ -29567,30 +29732,30 @@ async function publish_default(npmrc2, config, pkg, context) {
|
|
|
29567
29732
|
|
|
29568
29733
|
// src/generate-notes.js
|
|
29569
29734
|
import { dirname } from "node:path";
|
|
29570
|
-
import { fileURLToPath as
|
|
29735
|
+
import { fileURLToPath as fileURLToPath10, format as format5 } from "node:url";
|
|
29571
29736
|
import conventionalChangelogAngular from "conventional-changelog-angular";
|
|
29572
29737
|
|
|
29573
29738
|
// node_modules/import-from-esm/index.js
|
|
29574
29739
|
var import_debug = __toESM(require_src(), 1);
|
|
29575
29740
|
import { createRequire } from "node:module";
|
|
29576
29741
|
import { extname as extname2, resolve } from "node:path";
|
|
29577
|
-
import { fileURLToPath as
|
|
29742
|
+
import { fileURLToPath as fileURLToPath7, pathToFileURL as pathToFileURL2 } from "node:url";
|
|
29578
29743
|
|
|
29579
29744
|
// node_modules/import-meta-resolve/lib/resolve.js
|
|
29580
29745
|
import assert2 from "node:assert";
|
|
29581
29746
|
import { statSync as statSync2, realpathSync } from "node:fs";
|
|
29582
29747
|
import process12 from "node:process";
|
|
29583
|
-
import {
|
|
29748
|
+
import { fileURLToPath as fileURLToPath6, pathToFileURL } from "node:url";
|
|
29584
29749
|
import path17 from "node:path";
|
|
29585
29750
|
import { builtinModules } from "node:module";
|
|
29586
29751
|
|
|
29587
29752
|
// node_modules/import-meta-resolve/lib/get-format.js
|
|
29588
|
-
import { fileURLToPath as
|
|
29753
|
+
import { fileURLToPath as fileURLToPath5 } from "node:url";
|
|
29589
29754
|
|
|
29590
29755
|
// node_modules/import-meta-resolve/lib/package-json-reader.js
|
|
29591
29756
|
import fs9 from "node:fs";
|
|
29592
29757
|
import path16 from "node:path";
|
|
29593
|
-
import { fileURLToPath as
|
|
29758
|
+
import { fileURLToPath as fileURLToPath4 } from "node:url";
|
|
29594
29759
|
|
|
29595
29760
|
// node_modules/import-meta-resolve/lib/errors.js
|
|
29596
29761
|
import v8 from "node:v8";
|
|
@@ -29625,7 +29790,7 @@ codes.ERR_INVALID_ARG_TYPE = createError(
|
|
|
29625
29790
|
* @param {unknown} actual
|
|
29626
29791
|
*/
|
|
29627
29792
|
(name, expected, actual) => {
|
|
29628
|
-
assert(typeof name === "string", "'name' must be a string");
|
|
29793
|
+
assert.ok(typeof name === "string", "'name' must be a string");
|
|
29629
29794
|
if (!Array.isArray(expected)) {
|
|
29630
29795
|
expected = [expected];
|
|
29631
29796
|
}
|
|
@@ -29641,14 +29806,14 @@ codes.ERR_INVALID_ARG_TYPE = createError(
|
|
|
29641
29806
|
const instances = [];
|
|
29642
29807
|
const other = [];
|
|
29643
29808
|
for (const value of expected) {
|
|
29644
|
-
assert(
|
|
29809
|
+
assert.ok(
|
|
29645
29810
|
typeof value === "string",
|
|
29646
29811
|
"All expected entries have to be of type string"
|
|
29647
29812
|
);
|
|
29648
29813
|
if (kTypes.has(value)) {
|
|
29649
29814
|
types2.push(value.toLowerCase());
|
|
29650
29815
|
} else if (classRegExp.exec(value) === null) {
|
|
29651
|
-
assert(
|
|
29816
|
+
assert.ok(
|
|
29652
29817
|
value !== "object",
|
|
29653
29818
|
'The value "object" should be written as "Object"'
|
|
29654
29819
|
);
|
|
@@ -29724,7 +29889,7 @@ codes.ERR_INVALID_PACKAGE_TARGET = createError(
|
|
|
29724
29889
|
(packagePath, key, target, isImport = false, base = void 0) => {
|
|
29725
29890
|
const relatedError = typeof target === "string" && !isImport && target.length > 0 && !target.startsWith("./");
|
|
29726
29891
|
if (key === ".") {
|
|
29727
|
-
assert(isImport === false);
|
|
29892
|
+
assert.ok(isImport === false);
|
|
29728
29893
|
return `Invalid "exports" main target ${JSON.stringify(target)} defined in the package config ${packagePath}package.json${base ? ` imported from ${base}` : ""}${relatedError ? '; targets must start with "./"' : ""}`;
|
|
29729
29894
|
}
|
|
29730
29895
|
return `Invalid "${isImport ? "imports" : "exports"}" target ${JSON.stringify(
|
|
@@ -29889,9 +30054,9 @@ var captureLargerStackTrace = hideStackFrames(
|
|
|
29889
30054
|
);
|
|
29890
30055
|
function getMessage2(key, parameters, self) {
|
|
29891
30056
|
const message = messages.get(key);
|
|
29892
|
-
assert(message !== void 0, "expected `message` to be found");
|
|
30057
|
+
assert.ok(message !== void 0, "expected `message` to be found");
|
|
29893
30058
|
if (typeof message === "function") {
|
|
29894
|
-
assert(
|
|
30059
|
+
assert.ok(
|
|
29895
30060
|
message.length <= parameters.length,
|
|
29896
30061
|
// Default options do not count.
|
|
29897
30062
|
`Code: ${key}; The provided arguments length (${parameters.length}) does not match the required ones (${message.length}).`
|
|
@@ -29901,7 +30066,7 @@ function getMessage2(key, parameters, self) {
|
|
|
29901
30066
|
const regex = /%[dfijoOs]/g;
|
|
29902
30067
|
let expectedLength = 0;
|
|
29903
30068
|
while (regex.exec(message) !== null) expectedLength++;
|
|
29904
|
-
assert(
|
|
30069
|
+
assert.ok(
|
|
29905
30070
|
expectedLength === parameters.length,
|
|
29906
30071
|
`Code: ${key}; The provided arguments length (${parameters.length}) does not match the required ones (${expectedLength}).`
|
|
29907
30072
|
);
|
|
@@ -29971,7 +30136,7 @@ function read(jsonPath, { base, specifier }) {
|
|
|
29971
30136
|
);
|
|
29972
30137
|
const error = new ERR_INVALID_PACKAGE_CONFIG(
|
|
29973
30138
|
jsonPath,
|
|
29974
|
-
(base ? `"${specifier}" from ` : "") +
|
|
30139
|
+
(base ? `"${specifier}" from ` : "") + fileURLToPath4(base || specifier),
|
|
29975
30140
|
cause.message
|
|
29976
30141
|
);
|
|
29977
30142
|
error.cause = cause;
|
|
@@ -30004,7 +30169,7 @@ function getPackageScopeConfig(resolved) {
|
|
|
30004
30169
|
if (packageJSONPath2.endsWith("node_modules/package.json")) {
|
|
30005
30170
|
break;
|
|
30006
30171
|
}
|
|
30007
|
-
const packageConfig = read(
|
|
30172
|
+
const packageConfig = read(fileURLToPath4(packageJSONUrl), {
|
|
30008
30173
|
specifier: resolved
|
|
30009
30174
|
});
|
|
30010
30175
|
if (packageConfig.exists) {
|
|
@@ -30016,7 +30181,7 @@ function getPackageScopeConfig(resolved) {
|
|
|
30016
30181
|
break;
|
|
30017
30182
|
}
|
|
30018
30183
|
}
|
|
30019
|
-
const packageJSONPath =
|
|
30184
|
+
const packageJSONPath = fileURLToPath4(packageJSONUrl);
|
|
30020
30185
|
return {
|
|
30021
30186
|
pjsonPath: packageJSONPath,
|
|
30022
30187
|
exists: false,
|
|
@@ -30096,7 +30261,7 @@ function getFileProtocolModuleFormat(url, _context, ignoreErrors) {
|
|
|
30096
30261
|
if (ignoreErrors) {
|
|
30097
30262
|
return void 0;
|
|
30098
30263
|
}
|
|
30099
|
-
const filepath =
|
|
30264
|
+
const filepath = fileURLToPath5(url);
|
|
30100
30265
|
throw new ERR_UNKNOWN_FILE_EXTENSION(value, filepath);
|
|
30101
30266
|
}
|
|
30102
30267
|
function getHttpProtocolModuleFormat() {
|
|
@@ -30109,6 +30274,30 @@ function defaultGetFormatWithoutErrors(url, context) {
|
|
|
30109
30274
|
return protocolHandlers[protocol](url, context, true) || null;
|
|
30110
30275
|
}
|
|
30111
30276
|
|
|
30277
|
+
// node_modules/import-meta-resolve/lib/utils.js
|
|
30278
|
+
var { ERR_INVALID_ARG_VALUE } = codes;
|
|
30279
|
+
var DEFAULT_CONDITIONS = Object.freeze(["node", "import"]);
|
|
30280
|
+
var DEFAULT_CONDITIONS_SET = new Set(DEFAULT_CONDITIONS);
|
|
30281
|
+
function getDefaultConditions() {
|
|
30282
|
+
return DEFAULT_CONDITIONS;
|
|
30283
|
+
}
|
|
30284
|
+
function getDefaultConditionsSet() {
|
|
30285
|
+
return DEFAULT_CONDITIONS_SET;
|
|
30286
|
+
}
|
|
30287
|
+
function getConditionsSet(conditions) {
|
|
30288
|
+
if (conditions !== void 0 && conditions !== getDefaultConditions()) {
|
|
30289
|
+
if (!Array.isArray(conditions)) {
|
|
30290
|
+
throw new ERR_INVALID_ARG_VALUE(
|
|
30291
|
+
"conditions",
|
|
30292
|
+
conditions,
|
|
30293
|
+
"expected an array"
|
|
30294
|
+
);
|
|
30295
|
+
}
|
|
30296
|
+
return new Set(conditions);
|
|
30297
|
+
}
|
|
30298
|
+
return getDefaultConditionsSet();
|
|
30299
|
+
}
|
|
30300
|
+
|
|
30112
30301
|
// node_modules/import-meta-resolve/lib/resolve.js
|
|
30113
30302
|
var RegExpPrototypeSymbolReplace = RegExp.prototype[Symbol.replace];
|
|
30114
30303
|
var {
|
|
@@ -30134,10 +30323,10 @@ function emitInvalidSegmentDeprecation(target, request, match2, packageJsonUrl,
|
|
|
30134
30323
|
if (process12.noDeprecation) {
|
|
30135
30324
|
return;
|
|
30136
30325
|
}
|
|
30137
|
-
const pjsonPath =
|
|
30326
|
+
const pjsonPath = fileURLToPath6(packageJsonUrl);
|
|
30138
30327
|
const double = doubleSlashRegEx.exec(isTarget ? target : request) !== null;
|
|
30139
30328
|
process12.emitWarning(
|
|
30140
|
-
`Use of deprecated ${double ? "double slash" : "leading or trailing slash matching"} resolving "${target}" for module request "${request}" ${request === match2 ? "" : `matched to "${match2}" `}in the "${internal ? "imports" : "exports"}" field module resolution of the package at ${pjsonPath}${base ? ` imported from ${
|
|
30329
|
+
`Use of deprecated ${double ? "double slash" : "leading or trailing slash matching"} resolving "${target}" for module request "${request}" ${request === match2 ? "" : `matched to "${match2}" `}in the "${internal ? "imports" : "exports"}" field module resolution of the package at ${pjsonPath}${base ? ` imported from ${fileURLToPath6(base)}` : ""}.`,
|
|
30141
30330
|
"DeprecationWarning",
|
|
30142
30331
|
"DEP0166"
|
|
30143
30332
|
);
|
|
@@ -30148,9 +30337,9 @@ function emitLegacyIndexDeprecation(url, packageJsonUrl, base, main) {
|
|
|
30148
30337
|
}
|
|
30149
30338
|
const format6 = defaultGetFormatWithoutErrors(url, { parentURL: base.href });
|
|
30150
30339
|
if (format6 !== "module") return;
|
|
30151
|
-
const urlPath =
|
|
30152
|
-
const packagePath =
|
|
30153
|
-
const basePath =
|
|
30340
|
+
const urlPath = fileURLToPath6(url.href);
|
|
30341
|
+
const packagePath = fileURLToPath6(new URL(".", packageJsonUrl));
|
|
30342
|
+
const basePath = fileURLToPath6(base);
|
|
30154
30343
|
if (!main) {
|
|
30155
30344
|
process12.emitWarning(
|
|
30156
30345
|
`No "main" or "exports" field defined in the package.json for ${packagePath} resolving the main entry point "${urlPath.slice(
|
|
@@ -30185,7 +30374,7 @@ function fileExists(url) {
|
|
|
30185
30374
|
function legacyMainResolve(packageJsonUrl, packageConfig, base) {
|
|
30186
30375
|
let guess;
|
|
30187
30376
|
if (packageConfig.main !== void 0) {
|
|
30188
|
-
guess = new
|
|
30377
|
+
guess = new URL(packageConfig.main, packageJsonUrl);
|
|
30189
30378
|
if (fileExists(guess)) return guess;
|
|
30190
30379
|
const tries2 = [
|
|
30191
30380
|
`./${packageConfig.main}.js`,
|
|
@@ -30197,7 +30386,7 @@ function legacyMainResolve(packageJsonUrl, packageConfig, base) {
|
|
|
30197
30386
|
];
|
|
30198
30387
|
let i3 = -1;
|
|
30199
30388
|
while (++i3 < tries2.length) {
|
|
30200
|
-
guess = new
|
|
30389
|
+
guess = new URL(tries2[i3], packageJsonUrl);
|
|
30201
30390
|
if (fileExists(guess)) break;
|
|
30202
30391
|
guess = void 0;
|
|
30203
30392
|
}
|
|
@@ -30214,7 +30403,7 @@ function legacyMainResolve(packageJsonUrl, packageConfig, base) {
|
|
|
30214
30403
|
const tries = ["./index.js", "./index.json", "./index.node"];
|
|
30215
30404
|
let i2 = -1;
|
|
30216
30405
|
while (++i2 < tries.length) {
|
|
30217
|
-
guess = new
|
|
30406
|
+
guess = new URL(tries[i2], packageJsonUrl);
|
|
30218
30407
|
if (fileExists(guess)) break;
|
|
30219
30408
|
guess = void 0;
|
|
30220
30409
|
}
|
|
@@ -30223,8 +30412,8 @@ function legacyMainResolve(packageJsonUrl, packageConfig, base) {
|
|
|
30223
30412
|
return guess;
|
|
30224
30413
|
}
|
|
30225
30414
|
throw new ERR_MODULE_NOT_FOUND(
|
|
30226
|
-
|
|
30227
|
-
|
|
30415
|
+
fileURLToPath6(new URL(".", packageJsonUrl)),
|
|
30416
|
+
fileURLToPath6(base)
|
|
30228
30417
|
);
|
|
30229
30418
|
}
|
|
30230
30419
|
function finalizeResolution(resolved, base, preserveSymlinks) {
|
|
@@ -30232,12 +30421,12 @@ function finalizeResolution(resolved, base, preserveSymlinks) {
|
|
|
30232
30421
|
throw new ERR_INVALID_MODULE_SPECIFIER(
|
|
30233
30422
|
resolved.pathname,
|
|
30234
30423
|
'must not include encoded "/" or "\\" characters',
|
|
30235
|
-
|
|
30424
|
+
fileURLToPath6(base)
|
|
30236
30425
|
);
|
|
30237
30426
|
}
|
|
30238
30427
|
let filePath;
|
|
30239
30428
|
try {
|
|
30240
|
-
filePath =
|
|
30429
|
+
filePath = fileURLToPath6(resolved);
|
|
30241
30430
|
} catch (error) {
|
|
30242
30431
|
const cause = (
|
|
30243
30432
|
/** @type {ErrnoException} */
|
|
@@ -30251,14 +30440,14 @@ function finalizeResolution(resolved, base, preserveSymlinks) {
|
|
|
30251
30440
|
filePath.endsWith("/") ? filePath.slice(-1) : filePath
|
|
30252
30441
|
);
|
|
30253
30442
|
if (stats && stats.isDirectory()) {
|
|
30254
|
-
const error = new ERR_UNSUPPORTED_DIR_IMPORT(filePath,
|
|
30443
|
+
const error = new ERR_UNSUPPORTED_DIR_IMPORT(filePath, fileURLToPath6(base));
|
|
30255
30444
|
error.url = String(resolved);
|
|
30256
30445
|
throw error;
|
|
30257
30446
|
}
|
|
30258
30447
|
if (!stats || !stats.isFile()) {
|
|
30259
30448
|
const error = new ERR_MODULE_NOT_FOUND(
|
|
30260
30449
|
filePath || resolved.pathname,
|
|
30261
|
-
base &&
|
|
30450
|
+
base && fileURLToPath6(base),
|
|
30262
30451
|
true
|
|
30263
30452
|
);
|
|
30264
30453
|
error.url = String(resolved);
|
|
@@ -30276,33 +30465,33 @@ function finalizeResolution(resolved, base, preserveSymlinks) {
|
|
|
30276
30465
|
function importNotDefined(specifier, packageJsonUrl, base) {
|
|
30277
30466
|
return new ERR_PACKAGE_IMPORT_NOT_DEFINED(
|
|
30278
30467
|
specifier,
|
|
30279
|
-
packageJsonUrl &&
|
|
30280
|
-
|
|
30468
|
+
packageJsonUrl && fileURLToPath6(new URL(".", packageJsonUrl)),
|
|
30469
|
+
fileURLToPath6(base)
|
|
30281
30470
|
);
|
|
30282
30471
|
}
|
|
30283
30472
|
function exportsNotFound(subpath, packageJsonUrl, base) {
|
|
30284
30473
|
return new ERR_PACKAGE_PATH_NOT_EXPORTED(
|
|
30285
|
-
|
|
30474
|
+
fileURLToPath6(new URL(".", packageJsonUrl)),
|
|
30286
30475
|
subpath,
|
|
30287
|
-
base &&
|
|
30476
|
+
base && fileURLToPath6(base)
|
|
30288
30477
|
);
|
|
30289
30478
|
}
|
|
30290
30479
|
function throwInvalidSubpath(request, match2, packageJsonUrl, internal, base) {
|
|
30291
|
-
const reason = `request is not a valid match in pattern "${match2}" for the "${internal ? "imports" : "exports"}" resolution of ${
|
|
30480
|
+
const reason = `request is not a valid match in pattern "${match2}" for the "${internal ? "imports" : "exports"}" resolution of ${fileURLToPath6(packageJsonUrl)}`;
|
|
30292
30481
|
throw new ERR_INVALID_MODULE_SPECIFIER(
|
|
30293
30482
|
request,
|
|
30294
30483
|
reason,
|
|
30295
|
-
base &&
|
|
30484
|
+
base && fileURLToPath6(base)
|
|
30296
30485
|
);
|
|
30297
30486
|
}
|
|
30298
30487
|
function invalidPackageTarget(subpath, target, packageJsonUrl, internal, base) {
|
|
30299
30488
|
target = typeof target === "object" && target !== null ? JSON.stringify(target, null, "") : `${target}`;
|
|
30300
30489
|
return new ERR_INVALID_PACKAGE_TARGET(
|
|
30301
|
-
|
|
30490
|
+
fileURLToPath6(new URL(".", packageJsonUrl)),
|
|
30302
30491
|
subpath,
|
|
30303
30492
|
target,
|
|
30304
30493
|
internal,
|
|
30305
|
-
base &&
|
|
30494
|
+
base && fileURLToPath6(base)
|
|
30306
30495
|
);
|
|
30307
30496
|
}
|
|
30308
30497
|
function resolvePackageTargetString(target, subpath, match2, packageJsonUrl, base, pattern, internal, isPathMap, conditions) {
|
|
@@ -30312,7 +30501,7 @@ function resolvePackageTargetString(target, subpath, match2, packageJsonUrl, bas
|
|
|
30312
30501
|
if (internal && !target.startsWith("../") && !target.startsWith("/")) {
|
|
30313
30502
|
let isURL = false;
|
|
30314
30503
|
try {
|
|
30315
|
-
new
|
|
30504
|
+
new URL(target);
|
|
30316
30505
|
isURL = true;
|
|
30317
30506
|
} catch {
|
|
30318
30507
|
}
|
|
@@ -30350,9 +30539,9 @@ function resolvePackageTargetString(target, subpath, match2, packageJsonUrl, bas
|
|
|
30350
30539
|
throw invalidPackageTarget(match2, target, packageJsonUrl, internal, base);
|
|
30351
30540
|
}
|
|
30352
30541
|
}
|
|
30353
|
-
const resolved = new
|
|
30542
|
+
const resolved = new URL(target, packageJsonUrl);
|
|
30354
30543
|
const resolvedPath = resolved.pathname;
|
|
30355
|
-
const packagePath = new
|
|
30544
|
+
const packagePath = new URL(".", packageJsonUrl).pathname;
|
|
30356
30545
|
if (!resolvedPath.startsWith(packagePath))
|
|
30357
30546
|
throw invalidPackageTarget(match2, target, packageJsonUrl, internal, base);
|
|
30358
30547
|
if (subpath === "") return resolved;
|
|
@@ -30380,7 +30569,7 @@ function resolvePackageTargetString(target, subpath, match2, packageJsonUrl, bas
|
|
|
30380
30569
|
}
|
|
30381
30570
|
}
|
|
30382
30571
|
if (pattern) {
|
|
30383
|
-
return new
|
|
30572
|
+
return new URL(
|
|
30384
30573
|
RegExpPrototypeSymbolReplace.call(
|
|
30385
30574
|
patternRegEx,
|
|
30386
30575
|
resolved.href,
|
|
@@ -30388,7 +30577,7 @@ function resolvePackageTargetString(target, subpath, match2, packageJsonUrl, bas
|
|
|
30388
30577
|
)
|
|
30389
30578
|
);
|
|
30390
30579
|
}
|
|
30391
|
-
return new
|
|
30580
|
+
return new URL(subpath, resolved);
|
|
30392
30581
|
}
|
|
30393
30582
|
function isArrayIndex(key) {
|
|
30394
30583
|
const keyNumber = Number(key);
|
|
@@ -30457,7 +30646,7 @@ function resolvePackageTarget(packageJsonUrl, target, subpath, packageSubpath, b
|
|
|
30457
30646
|
const key = keys[i2];
|
|
30458
30647
|
if (isArrayIndex(key)) {
|
|
30459
30648
|
throw new ERR_INVALID_PACKAGE_CONFIG2(
|
|
30460
|
-
|
|
30649
|
+
fileURLToPath6(packageJsonUrl),
|
|
30461
30650
|
base,
|
|
30462
30651
|
'"exports" cannot contain numeric property keys.'
|
|
30463
30652
|
);
|
|
@@ -30513,7 +30702,7 @@ function isConditionalExportsMainSugar(exports, packageJsonUrl, base) {
|
|
|
30513
30702
|
isConditionalSugar = currentIsConditionalSugar;
|
|
30514
30703
|
} else if (isConditionalSugar !== currentIsConditionalSugar) {
|
|
30515
30704
|
throw new ERR_INVALID_PACKAGE_CONFIG2(
|
|
30516
|
-
|
|
30705
|
+
fileURLToPath6(packageJsonUrl),
|
|
30517
30706
|
base,
|
|
30518
30707
|
`"exports" cannot contain some keys starting with '.' and some not. The exports object must either be an object of package subpath keys or an object of main entry condition name keys only.`
|
|
30519
30708
|
);
|
|
@@ -30525,11 +30714,11 @@ function emitTrailingSlashPatternDeprecation(match2, pjsonUrl, base) {
|
|
|
30525
30714
|
if (process12.noDeprecation) {
|
|
30526
30715
|
return;
|
|
30527
30716
|
}
|
|
30528
|
-
const pjsonPath =
|
|
30717
|
+
const pjsonPath = fileURLToPath6(pjsonUrl);
|
|
30529
30718
|
if (emittedPackageWarnings.has(pjsonPath + "|" + match2)) return;
|
|
30530
30719
|
emittedPackageWarnings.add(pjsonPath + "|" + match2);
|
|
30531
30720
|
process12.emitWarning(
|
|
30532
|
-
`Use of deprecated trailing slash pattern mapping "${match2}" in the "exports" field module resolution of the package at ${pjsonPath}${base ? ` imported from ${
|
|
30721
|
+
`Use of deprecated trailing slash pattern mapping "${match2}" in the "exports" field module resolution of the package at ${pjsonPath}${base ? ` imported from ${fileURLToPath6(base)}` : ""}. Mapping specifiers ending in "/" is no longer supported.`,
|
|
30533
30722
|
"DeprecationWarning",
|
|
30534
30723
|
"DEP0155"
|
|
30535
30724
|
);
|
|
@@ -30621,7 +30810,7 @@ function patternKeyCompare(a2, b) {
|
|
|
30621
30810
|
function packageImportsResolve(name, base, conditions) {
|
|
30622
30811
|
if (name === "#" || name.startsWith("#/") || name.endsWith("/")) {
|
|
30623
30812
|
const reason = "is not a valid internal imports specifier name";
|
|
30624
|
-
throw new ERR_INVALID_MODULE_SPECIFIER(name, reason,
|
|
30813
|
+
throw new ERR_INVALID_MODULE_SPECIFIER(name, reason, fileURLToPath6(base));
|
|
30625
30814
|
}
|
|
30626
30815
|
let packageJsonUrl;
|
|
30627
30816
|
const packageConfig = getPackageScopeConfig(base);
|
|
@@ -30705,7 +30894,7 @@ function parsePackageName(specifier, base) {
|
|
|
30705
30894
|
throw new ERR_INVALID_MODULE_SPECIFIER(
|
|
30706
30895
|
specifier,
|
|
30707
30896
|
"is not a valid package name",
|
|
30708
|
-
|
|
30897
|
+
fileURLToPath6(base)
|
|
30709
30898
|
);
|
|
30710
30899
|
}
|
|
30711
30900
|
const packageSubpath = "." + (separatorIndex === -1 ? "" : specifier.slice(separatorIndex));
|
|
@@ -30713,7 +30902,7 @@ function parsePackageName(specifier, base) {
|
|
|
30713
30902
|
}
|
|
30714
30903
|
function packageResolve(specifier, base, conditions) {
|
|
30715
30904
|
if (builtinModules.includes(specifier)) {
|
|
30716
|
-
return new
|
|
30905
|
+
return new URL("node:" + specifier);
|
|
30717
30906
|
}
|
|
30718
30907
|
const { packageName, packageSubpath, isScoped } = parsePackageName(
|
|
30719
30908
|
specifier,
|
|
@@ -30732,21 +30921,21 @@ function packageResolve(specifier, base, conditions) {
|
|
|
30732
30921
|
);
|
|
30733
30922
|
}
|
|
30734
30923
|
}
|
|
30735
|
-
let packageJsonUrl = new
|
|
30924
|
+
let packageJsonUrl = new URL(
|
|
30736
30925
|
"./node_modules/" + packageName + "/package.json",
|
|
30737
30926
|
base
|
|
30738
30927
|
);
|
|
30739
|
-
let packageJsonPath =
|
|
30928
|
+
let packageJsonPath = fileURLToPath6(packageJsonUrl);
|
|
30740
30929
|
let lastPath;
|
|
30741
30930
|
do {
|
|
30742
30931
|
const stat = tryStatSync(packageJsonPath.slice(0, -13));
|
|
30743
30932
|
if (!stat || !stat.isDirectory()) {
|
|
30744
30933
|
lastPath = packageJsonPath;
|
|
30745
|
-
packageJsonUrl = new
|
|
30934
|
+
packageJsonUrl = new URL(
|
|
30746
30935
|
(isScoped ? "../../../../node_modules/" : "../../../node_modules/") + packageName + "/package.json",
|
|
30747
30936
|
packageJsonUrl
|
|
30748
30937
|
);
|
|
30749
|
-
packageJsonPath =
|
|
30938
|
+
packageJsonPath = fileURLToPath6(packageJsonUrl);
|
|
30750
30939
|
continue;
|
|
30751
30940
|
}
|
|
30752
30941
|
const packageConfig2 = read(packageJsonPath, { base, specifier });
|
|
@@ -30762,9 +30951,9 @@ function packageResolve(specifier, base, conditions) {
|
|
|
30762
30951
|
if (packageSubpath === ".") {
|
|
30763
30952
|
return legacyMainResolve(packageJsonUrl, packageConfig2, base);
|
|
30764
30953
|
}
|
|
30765
|
-
return new
|
|
30954
|
+
return new URL(packageSubpath, packageJsonUrl);
|
|
30766
30955
|
} while (packageJsonPath.length !== lastPath.length);
|
|
30767
|
-
throw new ERR_MODULE_NOT_FOUND(packageName,
|
|
30956
|
+
throw new ERR_MODULE_NOT_FOUND(packageName, fileURLToPath6(base), false);
|
|
30768
30957
|
}
|
|
30769
30958
|
function isRelativeSpecifier(specifier) {
|
|
30770
30959
|
if (specifier[0] === ".") {
|
|
@@ -30781,13 +30970,16 @@ function shouldBeTreatedAsRelativeOrAbsolutePath(specifier) {
|
|
|
30781
30970
|
return isRelativeSpecifier(specifier);
|
|
30782
30971
|
}
|
|
30783
30972
|
function moduleResolve(specifier, base, conditions, preserveSymlinks) {
|
|
30973
|
+
if (conditions === void 0) {
|
|
30974
|
+
conditions = getConditionsSet();
|
|
30975
|
+
}
|
|
30784
30976
|
const protocol = base.protocol;
|
|
30785
30977
|
const isData = protocol === "data:";
|
|
30786
30978
|
const isRemote = isData || protocol === "http:" || protocol === "https:";
|
|
30787
30979
|
let resolved;
|
|
30788
30980
|
if (shouldBeTreatedAsRelativeOrAbsolutePath(specifier)) {
|
|
30789
30981
|
try {
|
|
30790
|
-
resolved = new
|
|
30982
|
+
resolved = new URL(specifier, base);
|
|
30791
30983
|
} catch (error_) {
|
|
30792
30984
|
const error = new ERR_UNSUPPORTED_RESOLVE_REQUEST(specifier, base);
|
|
30793
30985
|
error.cause = error_;
|
|
@@ -30797,7 +30989,7 @@ function moduleResolve(specifier, base, conditions, preserveSymlinks) {
|
|
|
30797
30989
|
resolved = packageImportsResolve(specifier, base, conditions);
|
|
30798
30990
|
} else {
|
|
30799
30991
|
try {
|
|
30800
|
-
resolved = new
|
|
30992
|
+
resolved = new URL(specifier);
|
|
30801
30993
|
} catch (error_) {
|
|
30802
30994
|
if (isRemote && !builtinModules.includes(specifier)) {
|
|
30803
30995
|
const error = new ERR_UNSUPPORTED_RESOLVE_REQUEST(specifier, base);
|
|
@@ -30807,7 +30999,7 @@ function moduleResolve(specifier, base, conditions, preserveSymlinks) {
|
|
|
30807
30999
|
resolved = packageResolve(specifier, base, conditions);
|
|
30808
31000
|
}
|
|
30809
31001
|
}
|
|
30810
|
-
assert2(resolved !== void 0, "expected to be defined");
|
|
31002
|
+
assert2.ok(resolved !== void 0, "expected to be defined");
|
|
30811
31003
|
if (resolved.protocol !== "file:") {
|
|
30812
31004
|
return resolved;
|
|
30813
31005
|
}
|
|
@@ -30835,7 +31027,7 @@ async function tryImport(fileURL) {
|
|
|
30835
31027
|
}
|
|
30836
31028
|
try {
|
|
30837
31029
|
debug(`Trying to determine file extension for '${fileURL.href}'`);
|
|
30838
|
-
const filePath =
|
|
31030
|
+
const filePath = fileURLToPath7(fileURL);
|
|
30839
31031
|
const asJSON = extname2(filePath) === ".json";
|
|
30840
31032
|
debug(`Trying to import '${fileURL.href}'${asJSON ? " as JSON" : ""}`);
|
|
30841
31033
|
return asJSON ? require2(filePath) : await import(fileURL);
|
|
@@ -30904,7 +31096,6 @@ var import_from_esm_default = importFrom;
|
|
|
30904
31096
|
|
|
30905
31097
|
// node_modules/into-stream/index.js
|
|
30906
31098
|
import { Readable as ReadableStream2 } from "node:stream";
|
|
30907
|
-
import { Buffer as Buffer5 } from "node:buffer";
|
|
30908
31099
|
function baseIntoStream(isObjectMode, input) {
|
|
30909
31100
|
if (input === void 0 || input === null) {
|
|
30910
31101
|
throw new TypeError("Input should not be undefined or null.");
|
|
@@ -30917,18 +31108,30 @@ function baseIntoStream(isObjectMode, input) {
|
|
|
30917
31108
|
if (Array.isArray(value)) {
|
|
30918
31109
|
value = [...value];
|
|
30919
31110
|
}
|
|
30920
|
-
if (!isObjectMode && (value instanceof ArrayBuffer || ArrayBuffer.isView(value)
|
|
30921
|
-
value =
|
|
31111
|
+
if (!isObjectMode && (value instanceof ArrayBuffer || ArrayBuffer.isView(value))) {
|
|
31112
|
+
value = new Uint8Array(value);
|
|
30922
31113
|
}
|
|
30923
|
-
|
|
31114
|
+
const convertElement = (element) => {
|
|
31115
|
+
if (isObjectMode) {
|
|
31116
|
+
return element;
|
|
31117
|
+
}
|
|
31118
|
+
if (ArrayBuffer.isView(element)) {
|
|
31119
|
+
return new Uint8Array(element);
|
|
31120
|
+
}
|
|
31121
|
+
if (typeof element === "number") {
|
|
31122
|
+
return new Uint8Array([element]);
|
|
31123
|
+
}
|
|
31124
|
+
return element;
|
|
31125
|
+
};
|
|
31126
|
+
if (typeof value !== "string" && !ArrayBuffer.isView(value) && value?.[Symbol.iterator]) {
|
|
30924
31127
|
for (const element of value) {
|
|
30925
|
-
yield element;
|
|
31128
|
+
yield convertElement(element);
|
|
30926
31129
|
}
|
|
30927
31130
|
return;
|
|
30928
31131
|
}
|
|
30929
31132
|
if (value?.[Symbol.asyncIterator]) {
|
|
30930
31133
|
for await (const element of value) {
|
|
30931
|
-
yield await element;
|
|
31134
|
+
yield convertElement(await element);
|
|
30932
31135
|
}
|
|
30933
31136
|
return;
|
|
30934
31137
|
}
|
|
@@ -30983,7 +31186,7 @@ function getParserRegexes(options = {}) {
|
|
|
30983
31186
|
}
|
|
30984
31187
|
|
|
30985
31188
|
// node_modules/conventional-commits-parser/dist/utils.js
|
|
30986
|
-
var SCISSOR = "
|
|
31189
|
+
var SCISSOR = "------------------------ >8 ------------------------";
|
|
30987
31190
|
function trimNewLines(input) {
|
|
30988
31191
|
const matches = input.match(/[^\r\n]/);
|
|
30989
31192
|
if (typeof matches?.index !== "number") {
|
|
@@ -31003,8 +31206,8 @@ ${line || ""}` : line || "";
|
|
|
31003
31206
|
function getCommentFilter(char) {
|
|
31004
31207
|
return char ? (line) => !line.startsWith(char) : () => true;
|
|
31005
31208
|
}
|
|
31006
|
-
function truncateToScissor(lines) {
|
|
31007
|
-
const scissorIndex = lines.indexOf(SCISSOR);
|
|
31209
|
+
function truncateToScissor(lines, commentChar) {
|
|
31210
|
+
const scissorIndex = lines.indexOf(`${commentChar} ${SCISSOR}`);
|
|
31008
31211
|
if (scissorIndex === -1) {
|
|
31009
31212
|
return lines;
|
|
31010
31213
|
}
|
|
@@ -31013,6 +31216,14 @@ function truncateToScissor(lines) {
|
|
|
31013
31216
|
function gpgFilter(line) {
|
|
31014
31217
|
return !line.match(/^\s*gpg:/);
|
|
31015
31218
|
}
|
|
31219
|
+
function assignMatchedCorrespondence(target, matches, correspondence) {
|
|
31220
|
+
const { groups } = matches;
|
|
31221
|
+
for (let i2 = 0, len = correspondence.length, key; i2 < len; i2++) {
|
|
31222
|
+
key = correspondence[i2];
|
|
31223
|
+
target[key] = (groups ? groups[key] : matches[i2 + 1]) || null;
|
|
31224
|
+
}
|
|
31225
|
+
return target;
|
|
31226
|
+
}
|
|
31016
31227
|
|
|
31017
31228
|
// node_modules/conventional-commits-parser/dist/options.js
|
|
31018
31229
|
var defaultOptions = {
|
|
@@ -31143,9 +31354,7 @@ var CommitParser = class {
|
|
|
31143
31354
|
if (matches) {
|
|
31144
31355
|
this.nextLine();
|
|
31145
31356
|
commit.merge = matches[0] || null;
|
|
31146
|
-
|
|
31147
|
-
commit[key] = matches[index + 1] || null;
|
|
31148
|
-
});
|
|
31357
|
+
assignMatchedCorrespondence(commit, matches, correspondence);
|
|
31149
31358
|
return true;
|
|
31150
31359
|
}
|
|
31151
31360
|
return false;
|
|
@@ -31170,9 +31379,7 @@ var CommitParser = class {
|
|
|
31170
31379
|
commit.header = header;
|
|
31171
31380
|
}
|
|
31172
31381
|
if (matches) {
|
|
31173
|
-
|
|
31174
|
-
commit[key] = matches[index + 1] || null;
|
|
31175
|
-
});
|
|
31382
|
+
assignMatchedCorrespondence(commit, matches, correspondence);
|
|
31176
31383
|
}
|
|
31177
31384
|
}
|
|
31178
31385
|
parseMeta() {
|
|
@@ -31283,10 +31490,7 @@ var CommitParser = class {
|
|
|
31283
31490
|
const correspondence = options.revertCorrespondence || [];
|
|
31284
31491
|
const matches = options.revertPattern ? input.match(options.revertPattern) : null;
|
|
31285
31492
|
if (matches) {
|
|
31286
|
-
commit.revert =
|
|
31287
|
-
meta[key] = matches[index + 1] || null;
|
|
31288
|
-
return meta;
|
|
31289
|
-
}, {});
|
|
31493
|
+
commit.revert = assignMatchedCorrespondence({}, matches, correspondence);
|
|
31290
31494
|
}
|
|
31291
31495
|
}
|
|
31292
31496
|
cleanupCommit() {
|
|
@@ -31310,9 +31514,10 @@ var CommitParser = class {
|
|
|
31310
31514
|
if (!input.trim()) {
|
|
31311
31515
|
throw new TypeError("Expected a raw commit");
|
|
31312
31516
|
}
|
|
31313
|
-
const
|
|
31517
|
+
const { commentChar } = this.options;
|
|
31518
|
+
const commentFilter = getCommentFilter(commentChar);
|
|
31314
31519
|
const rawLines = trimNewLines(input).split(/\r?\n/);
|
|
31315
|
-
const lines = truncateToScissor(rawLines).filter((line) => commentFilter(line) && gpgFilter(line));
|
|
31520
|
+
const lines = commentChar ? truncateToScissor(rawLines, commentChar).filter((line) => commentFilter(line) && gpgFilter(line)) : rawLines.filter((line) => gpgFilter(line));
|
|
31316
31521
|
const commit = createCommitObject();
|
|
31317
31522
|
this.lines = lines;
|
|
31318
31523
|
this.lineIndex = 0;
|
|
@@ -31435,9 +31640,9 @@ import path20 from "node:path";
|
|
|
31435
31640
|
// node_modules/find-up-simple/index.js
|
|
31436
31641
|
import process13 from "node:process";
|
|
31437
31642
|
import fsPromises3 from "node:fs/promises";
|
|
31438
|
-
import { fileURLToPath as
|
|
31643
|
+
import { fileURLToPath as fileURLToPath8 } from "node:url";
|
|
31439
31644
|
import path18 from "node:path";
|
|
31440
|
-
var toPath2 = (urlOrPath) => urlOrPath instanceof URL ?
|
|
31645
|
+
var toPath2 = (urlOrPath) => urlOrPath instanceof URL ? fileURLToPath8(urlOrPath) : urlOrPath;
|
|
31441
31646
|
async function findUp(name, {
|
|
31442
31647
|
cwd = process13.cwd(),
|
|
31443
31648
|
type: type2 = "file",
|
|
@@ -31446,8 +31651,9 @@ async function findUp(name, {
|
|
|
31446
31651
|
let directory = path18.resolve(toPath2(cwd) ?? "");
|
|
31447
31652
|
const { root } = path18.parse(directory);
|
|
31448
31653
|
stopAt = path18.resolve(directory, toPath2(stopAt ?? root));
|
|
31449
|
-
|
|
31450
|
-
|
|
31654
|
+
const isAbsoluteName = path18.isAbsolute(name);
|
|
31655
|
+
while (directory) {
|
|
31656
|
+
const filePath = isAbsoluteName ? name : path18.join(directory, name);
|
|
31451
31657
|
try {
|
|
31452
31658
|
const stats = await fsPromises3.stat(filePath);
|
|
31453
31659
|
if (type2 === "file" && stats.isFile() || type2 === "directory" && stats.isDirectory()) {
|
|
@@ -31455,6 +31661,9 @@ async function findUp(name, {
|
|
|
31455
31661
|
}
|
|
31456
31662
|
} catch {
|
|
31457
31663
|
}
|
|
31664
|
+
if (directory === stopAt || directory === root) {
|
|
31665
|
+
break;
|
|
31666
|
+
}
|
|
31458
31667
|
directory = path18.dirname(directory);
|
|
31459
31668
|
}
|
|
31460
31669
|
}
|
|
@@ -31467,18 +31676,21 @@ import path19 from "node:path";
|
|
|
31467
31676
|
var import_code_frame = __toESM(require_lib5(), 1);
|
|
31468
31677
|
|
|
31469
31678
|
// node_modules/index-to-position/index.js
|
|
31470
|
-
var safeLastIndexOf = (string, searchString, index) => index < 0 ? -1 : string.lastIndexOf(searchString, index);
|
|
31471
31679
|
function getPosition(text, textIndex) {
|
|
31472
|
-
const lineBreakBefore =
|
|
31473
|
-
|
|
31474
|
-
|
|
31475
|
-
|
|
31476
|
-
|
|
31477
|
-
}
|
|
31478
|
-
return { line, column };
|
|
31680
|
+
const lineBreakBefore = textIndex === 0 ? -1 : text.lastIndexOf("\n", textIndex - 1);
|
|
31681
|
+
return {
|
|
31682
|
+
line: lineBreakBefore === -1 ? 0 : text.slice(0, lineBreakBefore + 1).match(/\n/g).length,
|
|
31683
|
+
column: textIndex - lineBreakBefore - 1
|
|
31684
|
+
};
|
|
31479
31685
|
}
|
|
31480
|
-
function
|
|
31481
|
-
if (
|
|
31686
|
+
function indexToPosition(text, textIndex, { oneBased = false } = {}) {
|
|
31687
|
+
if (typeof text !== "string") {
|
|
31688
|
+
throw new TypeError("Text parameter should be a string");
|
|
31689
|
+
}
|
|
31690
|
+
if (!Number.isInteger(textIndex)) {
|
|
31691
|
+
throw new TypeError("Index parameter should be an integer");
|
|
31692
|
+
}
|
|
31693
|
+
if (textIndex < 0 || textIndex > text.length) {
|
|
31482
31694
|
throw new RangeError("Index out of bounds");
|
|
31483
31695
|
}
|
|
31484
31696
|
const position = getPosition(text, textIndex);
|
|
@@ -31490,17 +31702,28 @@ var getCodePoint = (character) => `\\u{${character.codePointAt(0).toString(16)}}
|
|
|
31490
31702
|
var JSONError = class _JSONError extends Error {
|
|
31491
31703
|
name = "JSONError";
|
|
31492
31704
|
fileName;
|
|
31493
|
-
|
|
31494
|
-
|
|
31705
|
+
#input;
|
|
31706
|
+
#jsonParseError;
|
|
31495
31707
|
#message;
|
|
31496
|
-
|
|
31497
|
-
|
|
31498
|
-
|
|
31708
|
+
#codeFrame;
|
|
31709
|
+
#rawCodeFrame;
|
|
31710
|
+
constructor(messageOrOptions) {
|
|
31711
|
+
if (typeof messageOrOptions === "string") {
|
|
31712
|
+
super();
|
|
31713
|
+
this.#message = messageOrOptions;
|
|
31714
|
+
} else {
|
|
31715
|
+
const { jsonParseError, fileName, input } = messageOrOptions;
|
|
31716
|
+
super(void 0, { cause: jsonParseError });
|
|
31717
|
+
this.#input = input;
|
|
31718
|
+
this.#jsonParseError = jsonParseError;
|
|
31719
|
+
this.fileName = fileName;
|
|
31720
|
+
}
|
|
31499
31721
|
Error.captureStackTrace?.(this, _JSONError);
|
|
31500
31722
|
}
|
|
31501
31723
|
get message() {
|
|
31502
|
-
|
|
31503
|
-
|
|
31724
|
+
this.#message ??= `${addCodePointToUnexpectedToken(this.#jsonParseError.message)}${this.#input === "" ? " while parsing empty string" : ""}`;
|
|
31725
|
+
const { codeFrame } = this;
|
|
31726
|
+
return `${this.#message}${this.fileName ? ` in ${this.fileName}` : ""}${codeFrame ? `
|
|
31504
31727
|
|
|
31505
31728
|
${codeFrame}
|
|
31506
31729
|
` : ""}`;
|
|
@@ -31508,23 +31731,42 @@ ${codeFrame}
|
|
|
31508
31731
|
set message(message) {
|
|
31509
31732
|
this.#message = message;
|
|
31510
31733
|
}
|
|
31734
|
+
#getCodeFrame(highlightCode) {
|
|
31735
|
+
if (!this.#jsonParseError) {
|
|
31736
|
+
return;
|
|
31737
|
+
}
|
|
31738
|
+
const input = this.#input;
|
|
31739
|
+
const location = getErrorLocation(input, this.#jsonParseError.message);
|
|
31740
|
+
if (!location) {
|
|
31741
|
+
return;
|
|
31742
|
+
}
|
|
31743
|
+
return (0, import_code_frame.codeFrameColumns)(input, { start: location }, { highlightCode });
|
|
31744
|
+
}
|
|
31745
|
+
get codeFrame() {
|
|
31746
|
+
this.#codeFrame ??= this.#getCodeFrame(
|
|
31747
|
+
/* highlightCode */
|
|
31748
|
+
true
|
|
31749
|
+
);
|
|
31750
|
+
return this.#codeFrame;
|
|
31751
|
+
}
|
|
31752
|
+
get rawCodeFrame() {
|
|
31753
|
+
this.#rawCodeFrame ??= this.#getCodeFrame(
|
|
31754
|
+
/* highlightCode */
|
|
31755
|
+
false
|
|
31756
|
+
);
|
|
31757
|
+
return this.#rawCodeFrame;
|
|
31758
|
+
}
|
|
31511
31759
|
};
|
|
31512
|
-
var generateCodeFrame = (string, location, highlightCode = true) => (0, import_code_frame.codeFrameColumns)(string, { start: location }, { highlightCode });
|
|
31513
31760
|
var getErrorLocation = (string, message) => {
|
|
31514
31761
|
const match2 = message.match(/in JSON at position (?<index>\d+)(?: \(line (?<line>\d+) column (?<column>\d+)\))?$/);
|
|
31515
31762
|
if (!match2) {
|
|
31516
31763
|
return;
|
|
31517
31764
|
}
|
|
31518
|
-
|
|
31765
|
+
const { index, line, column } = match2.groups;
|
|
31519
31766
|
if (line && column) {
|
|
31520
31767
|
return { line: Number(line), column: Number(column) };
|
|
31521
31768
|
}
|
|
31522
|
-
|
|
31523
|
-
if (index === string.length) {
|
|
31524
|
-
const { line: line2, column: column2 } = indexToLineColumn(string, string.length - 1, { oneBased: true });
|
|
31525
|
-
return { line: line2, column: column2 + 1 };
|
|
31526
|
-
}
|
|
31527
|
-
return indexToLineColumn(string, index, { oneBased: true });
|
|
31769
|
+
return indexToPosition(string, Number(index), { oneBased: true });
|
|
31528
31770
|
};
|
|
31529
31771
|
var addCodePointToUnexpectedToken = (message) => message.replace(
|
|
31530
31772
|
// TODO[engine:node@>=20]: The token always quoted after Node.js 20
|
|
@@ -31536,40 +31778,24 @@ function parseJson(string, reviver, fileName) {
|
|
|
31536
31778
|
fileName = reviver;
|
|
31537
31779
|
reviver = void 0;
|
|
31538
31780
|
}
|
|
31539
|
-
let message;
|
|
31540
31781
|
try {
|
|
31541
31782
|
return JSON.parse(string, reviver);
|
|
31542
31783
|
} catch (error) {
|
|
31543
|
-
|
|
31544
|
-
|
|
31545
|
-
|
|
31546
|
-
|
|
31547
|
-
|
|
31548
|
-
message = addCodePointToUnexpectedToken(message);
|
|
31549
|
-
} else {
|
|
31550
|
-
message += " while parsing empty string";
|
|
31551
|
-
}
|
|
31552
|
-
const jsonError = new JSONError(message);
|
|
31553
|
-
jsonError.fileName = fileName;
|
|
31554
|
-
if (location) {
|
|
31555
|
-
jsonError.codeFrame = generateCodeFrame(string, location);
|
|
31556
|
-
jsonError.rawCodeFrame = generateCodeFrame(
|
|
31557
|
-
string,
|
|
31558
|
-
location,
|
|
31559
|
-
/* highlightCode */
|
|
31560
|
-
false
|
|
31561
|
-
);
|
|
31784
|
+
throw new JSONError({
|
|
31785
|
+
jsonParseError: error,
|
|
31786
|
+
fileName,
|
|
31787
|
+
input: string
|
|
31788
|
+
});
|
|
31562
31789
|
}
|
|
31563
|
-
throw jsonError;
|
|
31564
31790
|
}
|
|
31565
31791
|
|
|
31566
31792
|
// node_modules/read-package-up/node_modules/read-pkg/index.js
|
|
31567
31793
|
var import_normalize_package_data = __toESM(require_normalize(), 1);
|
|
31568
31794
|
|
|
31569
31795
|
// node_modules/read-package-up/node_modules/unicorn-magic/node.js
|
|
31570
|
-
import { fileURLToPath as
|
|
31796
|
+
import { fileURLToPath as fileURLToPath9 } from "node:url";
|
|
31571
31797
|
function toPath3(urlOrPath) {
|
|
31572
|
-
return urlOrPath instanceof URL ?
|
|
31798
|
+
return urlOrPath instanceof URL ? fileURLToPath9(urlOrPath) : urlOrPath;
|
|
31573
31799
|
}
|
|
31574
31800
|
|
|
31575
31801
|
// node_modules/read-package-up/node_modules/read-pkg/index.js
|
|
@@ -31678,7 +31904,7 @@ async function loadChangelogConfig(pluginConfig, context) {
|
|
|
31678
31904
|
const { preset, config, parserOpts, writerOpts, presetConfig } = pluginConfig;
|
|
31679
31905
|
const { cwd } = context;
|
|
31680
31906
|
let loadedConfig;
|
|
31681
|
-
const __dirname = dirname(
|
|
31907
|
+
const __dirname = dirname(fileURLToPath10(import.meta.url));
|
|
31682
31908
|
if (preset) {
|
|
31683
31909
|
const presetPackage = `conventional-changelog-${preset.toLowerCase()}`;
|
|
31684
31910
|
loadedConfig = await (await import_from_esm_default.silent(__dirname, presetPackage) || await import_from_esm_default(cwd, presetPackage))(presetConfig);
|