From bc506fbfd176290c36bb9db83381578764b21786 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9e?= Date: Sun, 25 Jun 2023 17:44:29 +0200 Subject: [PATCH] Use github cache (#53) * Cache the zig compiler locally * logging * npm update * verboser * os.arch * debug * log signal * address https://github.com/actions/toolkit/issues/687 * correct path * add a cache: false option * share size * zigpath * path.join skull --- README.md | 12 + action.yml | 4 + dist/index.js | 59671 ++++++++++++++++++++++++++++++++++++++++++++++-- index.js | 39 +- package.json | 5 +- 5 files changed, 57880 insertions(+), 1851 deletions(-) diff --git a/README.md b/README.md index 5d7067c..8a898b0 100644 --- a/README.md +++ b/README.md @@ -48,6 +48,18 @@ If you are running Zig on Windows machines, you need to make sure that your .zig *.zig text eol=lf ``` +This action caches the downloaded compilers in your repository's Actions cache by default, +to reduce the load on the Zig Foundation's servers. Cached compilers are only about 60MB +each per version/OS/architecture. + +If this is really bad for you for some reason you can disable the caching. + +```yaml +- uses: goto-bus-stop/setup-zig@v2 + with: + cache: false +``` + ## License [Apache-2.0](LICENSE.md) diff --git a/action.yml b/action.yml index 0fa2e9e..d499841 100644 --- a/action.yml +++ b/action.yml @@ -9,6 +9,10 @@ inputs: description: 'Version of the zig compiler to use (must be 0.3.0 or up)' required: true default: 'master' + cache: + description: 'Cache downloaded compilers for faster action runs. Strongly recommended.' + required: false + default: 'true' runs: using: 'node16' main: 'dist/index.js' diff --git a/dist/index.js b/dist/index.js index 880c242..fc4ce60 100644 --- a/dist/index.js +++ b/dist/index.js @@ -5,6 +5,7 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor; var __getOwnPropNames = Object.getOwnPropertyNames; var __getProtoOf = Object.getPrototypeOf; var __hasOwnProp = Object.prototype.hasOwnProperty; +var __name = (target, value) => __defProp(target, "name", { value, configurable: true }); var __esm = (fn, res) => function __init() { return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res; }; @@ -41,6 +42,7 @@ var require_constants = __commonJS({ var MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER || /* istanbul ignore next */ 9007199254740991; var MAX_SAFE_COMPONENT_LENGTH = 16; + var MAX_SAFE_BUILD_LENGTH = MAX_LENGTH - 6; var RELEASE_TYPES = [ "major", "premajor", @@ -53,6 +55,7 @@ var require_constants = __commonJS({ module2.exports = { MAX_LENGTH, MAX_SAFE_COMPONENT_LENGTH, + MAX_SAFE_BUILD_LENGTH, MAX_SAFE_INTEGER, RELEASE_TYPES, SEMVER_SPEC_VERSION, @@ -74,30 +77,45 @@ var require_debug = __commonJS({ // node_modules/semver/internal/re.js var require_re = __commonJS({ "node_modules/semver/internal/re.js"(exports, module2) { - var { MAX_SAFE_COMPONENT_LENGTH } = require_constants(); + var { MAX_SAFE_COMPONENT_LENGTH, MAX_SAFE_BUILD_LENGTH } = require_constants(); var debug = require_debug(); exports = module2.exports = {}; var re = exports.re = []; + var safeRe = exports.safeRe = []; var src = exports.src = []; var t = exports.t = {}; var R = 0; - var createToken = (name, value, isGlobal) => { + var LETTERDASHNUMBER = "[a-zA-Z0-9-]"; + var safeRegexReplacements = [ + ["\\s", 1], + ["\\d", MAX_SAFE_COMPONENT_LENGTH], + [LETTERDASHNUMBER, MAX_SAFE_BUILD_LENGTH] + ]; + var makeSafeRegex = /* @__PURE__ */ __name((value) => { + for (const [token, max] of safeRegexReplacements) { + value = value.split(`${token}*`).join(`${token}{0,${max}}`).split(`${token}+`).join(`${token}{1,${max}}`); + } + return value; + }, "makeSafeRegex"); + var createToken = /* @__PURE__ */ __name((name, value, isGlobal) => { + const safe = makeSafeRegex(value); const index = R++; debug(name, index, value); t[name] = index; src[index] = value; re[index] = new RegExp(value, isGlobal ? "g" : void 0); - }; + safeRe[index] = new RegExp(safe, isGlobal ? "g" : void 0); + }, "createToken"); createToken("NUMERICIDENTIFIER", "0|[1-9]\\d*"); - createToken("NUMERICIDENTIFIERLOOSE", "[0-9]+"); - createToken("NONNUMERICIDENTIFIER", "\\d*[a-zA-Z-][a-zA-Z0-9-]*"); + createToken("NUMERICIDENTIFIERLOOSE", "\\d+"); + createToken("NONNUMERICIDENTIFIER", `\\d*[a-zA-Z-]${LETTERDASHNUMBER}*`); createToken("MAINVERSION", `(${src[t.NUMERICIDENTIFIER]})\\.(${src[t.NUMERICIDENTIFIER]})\\.(${src[t.NUMERICIDENTIFIER]})`); createToken("MAINVERSIONLOOSE", `(${src[t.NUMERICIDENTIFIERLOOSE]})\\.(${src[t.NUMERICIDENTIFIERLOOSE]})\\.(${src[t.NUMERICIDENTIFIERLOOSE]})`); createToken("PRERELEASEIDENTIFIER", `(?:${src[t.NUMERICIDENTIFIER]}|${src[t.NONNUMERICIDENTIFIER]})`); createToken("PRERELEASEIDENTIFIERLOOSE", `(?:${src[t.NUMERICIDENTIFIERLOOSE]}|${src[t.NONNUMERICIDENTIFIER]})`); createToken("PRERELEASE", `(?:-(${src[t.PRERELEASEIDENTIFIER]}(?:\\.${src[t.PRERELEASEIDENTIFIER]})*))`); createToken("PRERELEASELOOSE", `(?:-?(${src[t.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${src[t.PRERELEASEIDENTIFIERLOOSE]})*))`); - createToken("BUILDIDENTIFIER", "[0-9A-Za-z-]+"); + createToken("BUILDIDENTIFIER", `${LETTERDASHNUMBER}+`); createToken("BUILD", `(?:\\+(${src[t.BUILDIDENTIFIER]}(?:\\.${src[t.BUILDIDENTIFIER]})*))`); createToken("FULLPLAIN", `v?${src[t.MAINVERSION]}${src[t.PRERELEASE]}?${src[t.BUILD]}?`); createToken("FULL", `^${src[t.FULLPLAIN]}$`); @@ -139,7 +157,7 @@ var require_parse_options = __commonJS({ "node_modules/semver/internal/parse-options.js"(exports, module2) { var looseOption = Object.freeze({ loose: true }); var emptyOpts = Object.freeze({}); - var parseOptions = (options) => { + var parseOptions = /* @__PURE__ */ __name((options) => { if (!options) { return emptyOpts; } @@ -147,7 +165,7 @@ var require_parse_options = __commonJS({ return looseOption; } return options; - }; + }, "parseOptions"); module2.exports = parseOptions; } }); @@ -156,7 +174,7 @@ var require_parse_options = __commonJS({ var require_identifiers = __commonJS({ "node_modules/semver/internal/identifiers.js"(exports, module2) { var numeric = /^[0-9]+$/; - var compareIdentifiers = (a, b) => { + var compareIdentifiers = /* @__PURE__ */ __name((a, b) => { const anum = numeric.test(a); const bnum = numeric.test(b); if (anum && bnum) { @@ -164,8 +182,8 @@ var require_identifiers = __commonJS({ b = +b; } return a === b ? 0 : anum && !bnum ? -1 : bnum && !anum ? 1 : a < b ? -1 : 1; - }; - var rcompareIdentifiers = (a, b) => compareIdentifiers(b, a); + }, "compareIdentifiers"); + var rcompareIdentifiers = /* @__PURE__ */ __name((a, b) => compareIdentifiers(b, a), "rcompareIdentifiers"); module2.exports = { compareIdentifiers, rcompareIdentifiers @@ -178,35 +196,35 @@ var require_semver = __commonJS({ "node_modules/semver/classes/semver.js"(exports, module2) { var debug = require_debug(); var { MAX_LENGTH, MAX_SAFE_INTEGER } = require_constants(); - var { re, t } = require_re(); + var { safeRe: re, t } = require_re(); var parseOptions = require_parse_options(); var { compareIdentifiers } = require_identifiers(); - var SemVer = class { - constructor(version2, options) { + var _SemVer = class _SemVer { + constructor(version3, options) { options = parseOptions(options); - if (version2 instanceof SemVer) { - if (version2.loose === !!options.loose && version2.includePrerelease === !!options.includePrerelease) { - return version2; + if (version3 instanceof _SemVer) { + if (version3.loose === !!options.loose && version3.includePrerelease === !!options.includePrerelease) { + return version3; } else { - version2 = version2.version; + version3 = version3.version; } - } else if (typeof version2 !== "string") { - throw new TypeError(`Invalid version. Must be a string. Got type "${typeof version2}".`); + } else if (typeof version3 !== "string") { + throw new TypeError(`Invalid version. Must be a string. Got type "${typeof version3}".`); } - if (version2.length > MAX_LENGTH) { + if (version3.length > MAX_LENGTH) { throw new TypeError( `version is longer than ${MAX_LENGTH} characters` ); } - debug("SemVer", version2, options); + debug("SemVer", version3, options); this.options = options; this.loose = !!options.loose; this.includePrerelease = !!options.includePrerelease; - const m = version2.trim().match(options.loose ? re[t.LOOSE] : re[t.FULL]); + const m = version3.trim().match(options.loose ? re[t.LOOSE] : re[t.FULL]); if (!m) { - throw new TypeError(`Invalid Version: ${version2}`); + throw new TypeError(`Invalid Version: ${version3}`); } - this.raw = version2; + this.raw = version3; this.major = +m[1]; this.minor = +m[2]; this.patch = +m[3]; @@ -247,11 +265,11 @@ var require_semver = __commonJS({ } compare(other) { debug("SemVer.compare", this.version, this.options, other); - if (!(other instanceof SemVer)) { + if (!(other instanceof _SemVer)) { if (typeof other === "string" && other === this.version) { return 0; } - other = new SemVer(other, this.options); + other = new _SemVer(other, this.options); } if (other.version === this.version) { return 0; @@ -259,14 +277,14 @@ var require_semver = __commonJS({ return this.compareMain(other) || this.comparePre(other); } compareMain(other) { - if (!(other instanceof SemVer)) { - other = new SemVer(other, this.options); + if (!(other instanceof _SemVer)) { + other = new _SemVer(other, this.options); } return compareIdentifiers(this.major, other.major) || compareIdentifiers(this.minor, other.minor) || compareIdentifiers(this.patch, other.patch); } comparePre(other) { - if (!(other instanceof SemVer)) { - other = new SemVer(other, this.options); + if (!(other instanceof _SemVer)) { + other = new _SemVer(other, this.options); } if (this.prerelease.length && !other.prerelease.length) { return -1; @@ -294,8 +312,8 @@ var require_semver = __commonJS({ } while (++i); } compareBuild(other) { - if (!(other instanceof SemVer)) { - other = new SemVer(other, this.options); + if (!(other instanceof _SemVer)) { + other = new _SemVer(other, this.options); } let i = 0; do { @@ -404,11 +422,15 @@ var require_semver = __commonJS({ default: throw new Error(`invalid increment argument: ${release}`); } - this.format(); - this.raw = this.version; + this.raw = this.format(); + if (this.build.length) { + this.raw += `+${this.build.join(".")}`; + } return this; } }; + __name(_SemVer, "SemVer"); + var SemVer = _SemVer; module2.exports = SemVer; } }); @@ -417,31 +439,31 @@ var require_semver = __commonJS({ var require_parse = __commonJS({ "node_modules/semver/functions/parse.js"(exports, module2) { var SemVer = require_semver(); - var parse2 = (version2, options, throwErrors = false) => { - if (version2 instanceof SemVer) { - return version2; + var parse3 = /* @__PURE__ */ __name((version3, options, throwErrors = false) => { + if (version3 instanceof SemVer) { + return version3; } try { - return new SemVer(version2, options); + return new SemVer(version3, options); } catch (er) { if (!throwErrors) { return null; } throw er; } - }; - module2.exports = parse2; + }, "parse"); + module2.exports = parse3; } }); // node_modules/semver/functions/valid.js var require_valid = __commonJS({ "node_modules/semver/functions/valid.js"(exports, module2) { - var parse2 = require_parse(); - var valid = (version2, options) => { - const v = parse2(version2, options); + var parse3 = require_parse(); + var valid = /* @__PURE__ */ __name((version3, options) => { + const v = parse3(version3, options); return v ? v.version : null; - }; + }, "valid"); module2.exports = valid; } }); @@ -449,11 +471,11 @@ var require_valid = __commonJS({ // node_modules/semver/functions/clean.js var require_clean = __commonJS({ "node_modules/semver/functions/clean.js"(exports, module2) { - var parse2 = require_parse(); - var clean = (version2, options) => { - const s = parse2(version2.trim().replace(/^[=v]+/, ""), options); + var parse3 = require_parse(); + var clean = /* @__PURE__ */ __name((version3, options) => { + const s = parse3(version3.trim().replace(/^[=v]+/, ""), options); return s ? s.version : null; - }; + }, "clean"); module2.exports = clean; } }); @@ -462,7 +484,7 @@ var require_clean = __commonJS({ var require_inc = __commonJS({ "node_modules/semver/functions/inc.js"(exports, module2) { var SemVer = require_semver(); - var inc = (version2, release, options, identifier, identifierBase) => { + var inc = /* @__PURE__ */ __name((version3, release, options, identifier, identifierBase) => { if (typeof options === "string") { identifierBase = identifier; identifier = options; @@ -470,13 +492,13 @@ var require_inc = __commonJS({ } try { return new SemVer( - version2 instanceof SemVer ? version2.version : version2, + version3 instanceof SemVer ? version3.version : version3, options ).inc(release, identifier, identifierBase).version; } catch (er) { return null; } - }; + }, "inc"); module2.exports = inc; } }); @@ -484,39 +506,43 @@ var require_inc = __commonJS({ // node_modules/semver/functions/diff.js var require_diff = __commonJS({ "node_modules/semver/functions/diff.js"(exports, module2) { - var parse2 = require_parse(); - var diff = (version1, version2) => { - const v12 = parse2(version1, null, true); - const v2 = parse2(version2, null, true); - const comparison = v12.compare(v2); + var parse3 = require_parse(); + var diff = /* @__PURE__ */ __name((version1, version22) => { + const v13 = parse3(version1, null, true); + const v2 = parse3(version22, null, true); + const comparison = v13.compare(v2); if (comparison === 0) { return null; } const v1Higher = comparison > 0; - const highVersion = v1Higher ? v12 : v2; - const lowVersion = v1Higher ? v2 : v12; + const highVersion = v1Higher ? v13 : v2; + const lowVersion = v1Higher ? v2 : v13; const highHasPre = !!highVersion.prerelease.length; + const lowHasPre = !!lowVersion.prerelease.length; + if (lowHasPre && !highHasPre) { + if (!lowVersion.patch && !lowVersion.minor) { + return "major"; + } + if (highVersion.patch) { + return "patch"; + } + if (highVersion.minor) { + return "minor"; + } + return "major"; + } const prefix = highHasPre ? "pre" : ""; - if (v12.major !== v2.major) { + if (v13.major !== v2.major) { return prefix + "major"; } - if (v12.minor !== v2.minor) { + if (v13.minor !== v2.minor) { return prefix + "minor"; } - if (v12.patch !== v2.patch) { + if (v13.patch !== v2.patch) { return prefix + "patch"; } - if (highHasPre) { - return "prerelease"; - } - if (lowVersion.patch) { - return "patch"; - } - if (lowVersion.minor) { - return "minor"; - } - return "major"; - }; + return "prerelease"; + }, "diff"); module2.exports = diff; } }); @@ -525,7 +551,7 @@ var require_diff = __commonJS({ var require_major = __commonJS({ "node_modules/semver/functions/major.js"(exports, module2) { var SemVer = require_semver(); - var major = (a, loose) => new SemVer(a, loose).major; + var major = /* @__PURE__ */ __name((a, loose) => new SemVer(a, loose).major, "major"); module2.exports = major; } }); @@ -534,7 +560,7 @@ var require_major = __commonJS({ var require_minor = __commonJS({ "node_modules/semver/functions/minor.js"(exports, module2) { var SemVer = require_semver(); - var minor = (a, loose) => new SemVer(a, loose).minor; + var minor = /* @__PURE__ */ __name((a, loose) => new SemVer(a, loose).minor, "minor"); module2.exports = minor; } }); @@ -543,7 +569,7 @@ var require_minor = __commonJS({ var require_patch = __commonJS({ "node_modules/semver/functions/patch.js"(exports, module2) { var SemVer = require_semver(); - var patch = (a, loose) => new SemVer(a, loose).patch; + var patch = /* @__PURE__ */ __name((a, loose) => new SemVer(a, loose).patch, "patch"); module2.exports = patch; } }); @@ -551,11 +577,11 @@ var require_patch = __commonJS({ // node_modules/semver/functions/prerelease.js var require_prerelease = __commonJS({ "node_modules/semver/functions/prerelease.js"(exports, module2) { - var parse2 = require_parse(); - var prerelease = (version2, options) => { - const parsed = parse2(version2, options); + var parse3 = require_parse(); + var prerelease = /* @__PURE__ */ __name((version3, options) => { + const parsed = parse3(version3, options); return parsed && parsed.prerelease.length ? parsed.prerelease : null; - }; + }, "prerelease"); module2.exports = prerelease; } }); @@ -564,7 +590,7 @@ var require_prerelease = __commonJS({ var require_compare = __commonJS({ "node_modules/semver/functions/compare.js"(exports, module2) { var SemVer = require_semver(); - var compare = (a, b, loose) => new SemVer(a, loose).compare(new SemVer(b, loose)); + var compare = /* @__PURE__ */ __name((a, b, loose) => new SemVer(a, loose).compare(new SemVer(b, loose)), "compare"); module2.exports = compare; } }); @@ -573,7 +599,7 @@ var require_compare = __commonJS({ var require_rcompare = __commonJS({ "node_modules/semver/functions/rcompare.js"(exports, module2) { var compare = require_compare(); - var rcompare = (a, b, loose) => compare(b, a, loose); + var rcompare = /* @__PURE__ */ __name((a, b, loose) => compare(b, a, loose), "rcompare"); module2.exports = rcompare; } }); @@ -582,7 +608,7 @@ var require_rcompare = __commonJS({ var require_compare_loose = __commonJS({ "node_modules/semver/functions/compare-loose.js"(exports, module2) { var compare = require_compare(); - var compareLoose = (a, b) => compare(a, b, true); + var compareLoose = /* @__PURE__ */ __name((a, b) => compare(a, b, true), "compareLoose"); module2.exports = compareLoose; } }); @@ -591,11 +617,11 @@ var require_compare_loose = __commonJS({ var require_compare_build = __commonJS({ "node_modules/semver/functions/compare-build.js"(exports, module2) { var SemVer = require_semver(); - var compareBuild = (a, b, loose) => { + var compareBuild = /* @__PURE__ */ __name((a, b, loose) => { const versionA = new SemVer(a, loose); const versionB = new SemVer(b, loose); return versionA.compare(versionB) || versionA.compareBuild(versionB); - }; + }, "compareBuild"); module2.exports = compareBuild; } }); @@ -604,7 +630,7 @@ var require_compare_build = __commonJS({ var require_sort = __commonJS({ "node_modules/semver/functions/sort.js"(exports, module2) { var compareBuild = require_compare_build(); - var sort = (list, loose) => list.sort((a, b) => compareBuild(a, b, loose)); + var sort = /* @__PURE__ */ __name((list, loose) => list.sort((a, b) => compareBuild(a, b, loose)), "sort"); module2.exports = sort; } }); @@ -613,7 +639,7 @@ var require_sort = __commonJS({ var require_rsort = __commonJS({ "node_modules/semver/functions/rsort.js"(exports, module2) { var compareBuild = require_compare_build(); - var rsort = (list, loose) => list.sort((a, b) => compareBuild(b, a, loose)); + var rsort = /* @__PURE__ */ __name((list, loose) => list.sort((a, b) => compareBuild(b, a, loose)), "rsort"); module2.exports = rsort; } }); @@ -622,7 +648,7 @@ var require_rsort = __commonJS({ var require_gt = __commonJS({ "node_modules/semver/functions/gt.js"(exports, module2) { var compare = require_compare(); - var gt = (a, b, loose) => compare(a, b, loose) > 0; + var gt = /* @__PURE__ */ __name((a, b, loose) => compare(a, b, loose) > 0, "gt"); module2.exports = gt; } }); @@ -631,7 +657,7 @@ var require_gt = __commonJS({ var require_lt = __commonJS({ "node_modules/semver/functions/lt.js"(exports, module2) { var compare = require_compare(); - var lt = (a, b, loose) => compare(a, b, loose) < 0; + var lt = /* @__PURE__ */ __name((a, b, loose) => compare(a, b, loose) < 0, "lt"); module2.exports = lt; } }); @@ -640,7 +666,7 @@ var require_lt = __commonJS({ var require_eq = __commonJS({ "node_modules/semver/functions/eq.js"(exports, module2) { var compare = require_compare(); - var eq = (a, b, loose) => compare(a, b, loose) === 0; + var eq = /* @__PURE__ */ __name((a, b, loose) => compare(a, b, loose) === 0, "eq"); module2.exports = eq; } }); @@ -649,7 +675,7 @@ var require_eq = __commonJS({ var require_neq = __commonJS({ "node_modules/semver/functions/neq.js"(exports, module2) { var compare = require_compare(); - var neq = (a, b, loose) => compare(a, b, loose) !== 0; + var neq = /* @__PURE__ */ __name((a, b, loose) => compare(a, b, loose) !== 0, "neq"); module2.exports = neq; } }); @@ -658,7 +684,7 @@ var require_neq = __commonJS({ var require_gte = __commonJS({ "node_modules/semver/functions/gte.js"(exports, module2) { var compare = require_compare(); - var gte = (a, b, loose) => compare(a, b, loose) >= 0; + var gte = /* @__PURE__ */ __name((a, b, loose) => compare(a, b, loose) >= 0, "gte"); module2.exports = gte; } }); @@ -667,7 +693,7 @@ var require_gte = __commonJS({ var require_lte = __commonJS({ "node_modules/semver/functions/lte.js"(exports, module2) { var compare = require_compare(); - var lte = (a, b, loose) => compare(a, b, loose) <= 0; + var lte = /* @__PURE__ */ __name((a, b, loose) => compare(a, b, loose) <= 0, "lte"); module2.exports = lte; } }); @@ -681,7 +707,7 @@ var require_cmp = __commonJS({ var gte = require_gte(); var lt = require_lt(); var lte = require_lte(); - var cmp = (a, op, b, loose) => { + var cmp = /* @__PURE__ */ __name((a, op, b, loose) => { switch (op) { case "===": if (typeof a === "object") { @@ -716,7 +742,7 @@ var require_cmp = __commonJS({ default: throw new TypeError(`Invalid operator: ${op}`); } - }; + }, "cmp"); module2.exports = cmp; } }); @@ -725,25 +751,25 @@ var require_cmp = __commonJS({ var require_coerce = __commonJS({ "node_modules/semver/functions/coerce.js"(exports, module2) { var SemVer = require_semver(); - var parse2 = require_parse(); - var { re, t } = require_re(); - var coerce = (version2, options) => { - if (version2 instanceof SemVer) { - return version2; + var parse3 = require_parse(); + var { safeRe: re, t } = require_re(); + var coerce = /* @__PURE__ */ __name((version3, options) => { + if (version3 instanceof SemVer) { + return version3; } - if (typeof version2 === "number") { - version2 = String(version2); + if (typeof version3 === "number") { + version3 = String(version3); } - if (typeof version2 !== "string") { + if (typeof version3 !== "string") { return null; } options = options || {}; let match = null; if (!options.rtl) { - match = version2.match(re[t.COERCE]); + match = version3.match(re[t.COERCE]); } else { let next; - while ((next = re[t.COERCERTL].exec(version2)) && (!match || match.index + match[0].length !== version2.length)) { + while ((next = re[t.COERCERTL].exec(version3)) && (!match || match.index + match[0].length !== version3.length)) { if (!match || next.index + next[0].length !== match.index + match[0].length) { match = next; } @@ -754,8 +780,8 @@ var require_coerce = __commonJS({ if (match === null) { return null; } - return parse2(`${match[2]}.${match[3] || "0"}.${match[4] || "0"}`, options); - }; + return parse3(`${match[2]}.${match[3] || "0"}.${match[4] || "0"}`, options); + }, "coerce"); module2.exports = coerce; } }); @@ -800,6 +826,7 @@ var require_yallist = __commonJS({ } return self; } + __name(Yallist, "Yallist"); Yallist.prototype.removeNode = function(node) { if (node.list !== this) { throw new Error("removing node which does not belong to this list"); @@ -1103,6 +1130,7 @@ var require_yallist = __commonJS({ self.length++; return inserted; } + __name(insert, "insert"); function push(self, item) { self.tail = new Node(item, self.tail, null, self); if (!self.head) { @@ -1110,6 +1138,7 @@ var require_yallist = __commonJS({ } self.length++; } + __name(push, "push"); function unshift(self, item) { self.head = new Node(item, null, self.head, self); if (!self.tail) { @@ -1117,6 +1146,7 @@ var require_yallist = __commonJS({ } self.length++; } + __name(unshift, "unshift"); function Node(value, prev, next, list) { if (!(this instanceof Node)) { return new Node(value, prev, next, list); @@ -1136,6 +1166,7 @@ var require_yallist = __commonJS({ this.next = null; } } + __name(Node, "Node"); try { require_iterator()(Yallist); } catch (er) { @@ -1158,8 +1189,8 @@ var require_lru_cache = __commonJS({ var LRU_LIST = Symbol("lruList"); var CACHE = Symbol("cache"); var UPDATE_AGE_ON_GET = Symbol("updateAgeOnGet"); - var naiveLength = () => 1; - var LRUCache = class { + var naiveLength = /* @__PURE__ */ __name(() => 1, "naiveLength"); + var _LRUCache = class _LRUCache { constructor(options) { if (typeof options === "number") options = { max: options }; @@ -1347,7 +1378,9 @@ var require_lru_cache = __commonJS({ this[CACHE].forEach((value, key) => get(this, key, false)); } }; - var get = (self, key, doUse) => { + __name(_LRUCache, "LRUCache"); + var LRUCache = _LRUCache; + var get = /* @__PURE__ */ __name((self, key, doUse) => { const node = self[CACHE].get(key); if (node) { const hit = node.value; @@ -1364,14 +1397,14 @@ var require_lru_cache = __commonJS({ } return hit.value; } - }; - var isStale = (self, hit) => { + }, "get"); + var isStale = /* @__PURE__ */ __name((self, hit) => { if (!hit || !hit.maxAge && !self[MAX_AGE]) return false; const diff = Date.now() - hit.now; return hit.maxAge ? diff > hit.maxAge : self[MAX_AGE] && diff > self[MAX_AGE]; - }; - var trim = (self) => { + }, "isStale"); + var trim = /* @__PURE__ */ __name((self) => { if (self[LENGTH] > self[MAX]) { for (let walker = self[LRU_LIST].tail; self[LENGTH] > self[MAX] && walker !== null; ) { const prev = walker.prev; @@ -1379,8 +1412,8 @@ var require_lru_cache = __commonJS({ walker = prev; } } - }; - var del = (self, node) => { + }, "trim"); + var del = /* @__PURE__ */ __name((self, node) => { if (node) { const hit = node.value; if (self[DISPOSE]) @@ -1389,8 +1422,8 @@ var require_lru_cache = __commonJS({ self[CACHE].delete(hit.key); self[LRU_LIST].removeNode(node); } - }; - var Entry = class { + }, "del"); + var _Entry = class _Entry { constructor(key, value, length, now, maxAge) { this.key = key; this.value = value; @@ -1399,7 +1432,9 @@ var require_lru_cache = __commonJS({ this.maxAge = maxAge || 0; } }; - var forEachStep = (self, fn, node, thisp) => { + __name(_Entry, "Entry"); + var Entry = _Entry; + var forEachStep = /* @__PURE__ */ __name((self, fn, node, thisp) => { let hit = node.value; if (isStale(self, hit)) { del(self, node); @@ -1408,7 +1443,7 @@ var require_lru_cache = __commonJS({ } if (hit) fn.call(thisp, hit.value, hit.key, self); - }; + }, "forEachStep"); module2.exports = LRUCache; } }); @@ -1416,14 +1451,14 @@ var require_lru_cache = __commonJS({ // node_modules/semver/classes/range.js var require_range = __commonJS({ "node_modules/semver/classes/range.js"(exports, module2) { - var Range = class { + var _Range = class _Range { constructor(range, options) { options = parseOptions(options); - if (range instanceof Range) { + if (range instanceof _Range) { if (range.loose === !!options.loose && range.includePrerelease === !!options.includePrerelease) { return range; } else { - return new Range(range.raw, options); + return new _Range(range.raw, options); } } if (range instanceof Comparator) { @@ -1435,10 +1470,10 @@ var require_range = __commonJS({ this.options = options; this.loose = !!options.loose; this.includePrerelease = !!options.includePrerelease; - this.raw = range; - this.set = range.split("||").map((r) => this.parseRange(r.trim())).filter((c) => c.length); + this.raw = range.trim().split(/\s+/).join(" "); + this.set = this.raw.split("||").map((r) => this.parseRange(r)).filter((c) => c.length); if (!this.set.length) { - throw new TypeError(`Invalid SemVer Range: ${range}`); + throw new TypeError(`Invalid SemVer Range: ${this.raw}`); } if (this.set.length > 1) { const first = this.set[0]; @@ -1457,16 +1492,13 @@ var require_range = __commonJS({ this.format(); } format() { - this.range = this.set.map((comps) => { - return comps.join(" ").trim(); - }).join("||").trim(); + this.range = this.set.map((comps) => comps.join(" ").trim()).join("||").trim(); return this.range; } toString() { return this.range; } parseRange(range) { - range = range.trim(); const memoOpts = (this.options.includePrerelease && FLAG_INCLUDE_PRERELEASE) | (this.options.loose && FLAG_LOOSE); const memoKey = memoOpts + ":" + range; const cached = cache2.get(memoKey); @@ -1480,8 +1512,9 @@ var require_range = __commonJS({ range = range.replace(re[t.COMPARATORTRIM], comparatorTrimReplace); debug("comparator trim", range); range = range.replace(re[t.TILDETRIM], tildeTrimReplace); + debug("tilde trim", range); range = range.replace(re[t.CARETTRIM], caretTrimReplace); - range = range.split(/\s+/).join(" "); + debug("caret trim", range); let rangeList = range.split(" ").map((comp) => parseComparator(comp, this.options)).join(" ").split(/\s+/).map((comp) => replaceGTE0(comp, this.options)); if (loose) { rangeList = rangeList.filter((comp) => { @@ -1506,7 +1539,7 @@ var require_range = __commonJS({ return result; } intersects(range, options) { - if (!(range instanceof Range)) { + if (!(range instanceof _Range)) { throw new TypeError("a Range is required"); } return this.set.some((thisComparators) => { @@ -1520,25 +1553,27 @@ var require_range = __commonJS({ }); } // if ANY of the sets match ALL of its comparators, then pass - test(version2) { - if (!version2) { + test(version3) { + if (!version3) { return false; } - if (typeof version2 === "string") { + if (typeof version3 === "string") { try { - version2 = new SemVer(version2, this.options); + version3 = new SemVer(version3, this.options); } catch (er) { return false; } } for (let i = 0; i < this.set.length; i++) { - if (testSet(this.set[i], version2, this.options)) { + if (testSet(this.set[i], version3, this.options)) { return true; } } return false; } }; + __name(_Range, "Range"); + var Range = _Range; module2.exports = Range; var LRU = require_lru_cache(); var cache2 = new LRU({ max: 1e3 }); @@ -1547,16 +1582,16 @@ var require_range = __commonJS({ var debug = require_debug(); var SemVer = require_semver(); var { - re, + safeRe: re, t, comparatorTrimReplace, tildeTrimReplace, caretTrimReplace } = require_re(); var { FLAG_INCLUDE_PRERELEASE, FLAG_LOOSE } = require_constants(); - var isNullSet = (c) => c.value === "<0.0.0-0"; - var isAny = (c) => c.value === ""; - var isSatisfiable = (comparators, options) => { + var isNullSet = /* @__PURE__ */ __name((c) => c.value === "<0.0.0-0", "isNullSet"); + var isAny = /* @__PURE__ */ __name((c) => c.value === "", "isAny"); + var isSatisfiable = /* @__PURE__ */ __name((comparators, options) => { let result = true; const remainingComparators = comparators.slice(); let testComparator = remainingComparators.pop(); @@ -1567,8 +1602,8 @@ var require_range = __commonJS({ testComparator = remainingComparators.pop(); } return result; - }; - var parseComparator = (comp, options) => { + }, "isSatisfiable"); + var parseComparator = /* @__PURE__ */ __name((comp, options) => { debug("comp", comp, options); comp = replaceCarets(comp, options); debug("caret", comp); @@ -1579,12 +1614,12 @@ var require_range = __commonJS({ comp = replaceStars(comp, options); debug("stars", comp); return comp; - }; - var isX = (id) => !id || id.toLowerCase() === "x" || id === "*"; - var replaceTildes = (comp, options) => comp.trim().split(/\s+/).map((c) => { - return replaceTilde(c, options); - }).join(" "); - var replaceTilde = (comp, options) => { + }, "parseComparator"); + var isX = /* @__PURE__ */ __name((id) => !id || id.toLowerCase() === "x" || id === "*", "isX"); + var replaceTildes = /* @__PURE__ */ __name((comp, options) => { + return comp.trim().split(/\s+/).map((c) => replaceTilde(c, options)).join(" "); + }, "replaceTildes"); + var replaceTilde = /* @__PURE__ */ __name((comp, options) => { const r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE]; return comp.replace(r, (_, M, m, p, pr) => { debug("tilde", comp, _, M, m, p, pr); @@ -1604,11 +1639,11 @@ var require_range = __commonJS({ debug("tilde return", ret); return ret; }); - }; - var replaceCarets = (comp, options) => comp.trim().split(/\s+/).map((c) => { - return replaceCaret(c, options); - }).join(" "); - var replaceCaret = (comp, options) => { + }, "replaceTilde"); + var replaceCarets = /* @__PURE__ */ __name((comp, options) => { + return comp.trim().split(/\s+/).map((c) => replaceCaret(c, options)).join(" "); + }, "replaceCarets"); + var replaceCaret = /* @__PURE__ */ __name((comp, options) => { debug("caret", comp, options); const r = options.loose ? re[t.CARETLOOSE] : re[t.CARET]; const z = options.includePrerelease ? "-0" : ""; @@ -1651,14 +1686,12 @@ var require_range = __commonJS({ debug("caret return", ret); return ret; }); - }; - var replaceXRanges = (comp, options) => { + }, "replaceCaret"); + var replaceXRanges = /* @__PURE__ */ __name((comp, options) => { debug("replaceXRanges", comp, options); - return comp.split(/\s+/).map((c) => { - return replaceXRange(c, options); - }).join(" "); - }; - var replaceXRange = (comp, options) => { + return comp.split(/\s+/).map((c) => replaceXRange(c, options)).join(" "); + }, "replaceXRanges"); + var replaceXRange = /* @__PURE__ */ __name((comp, options) => { comp = comp.trim(); const r = options.loose ? re[t.XRANGELOOSE] : re[t.XRANGE]; return comp.replace(r, (ret, gtlt, M, m, p, pr) => { @@ -1712,16 +1745,16 @@ var require_range = __commonJS({ debug("xRange return", ret); return ret; }); - }; - var replaceStars = (comp, options) => { + }, "replaceXRange"); + var replaceStars = /* @__PURE__ */ __name((comp, options) => { debug("replaceStars", comp, options); return comp.trim().replace(re[t.STAR], ""); - }; - var replaceGTE0 = (comp, options) => { + }, "replaceStars"); + var replaceGTE0 = /* @__PURE__ */ __name((comp, options) => { debug("replaceGTE0", comp, options); return comp.trim().replace(re[options.includePrerelease ? t.GTE0PRE : t.GTE0], ""); - }; - var hyphenReplace = (incPr) => ($0, from, fM, fm, fp, fpr, fb, to, tM, tm, tp, tpr, tb) => { + }, "replaceGTE0"); + var hyphenReplace = /* @__PURE__ */ __name((incPr) => ($0, from, fM, fm, fp, fpr, fb, to, tM, tm, tp, tpr, tb) => { if (isX(fM)) { from = ""; } else if (isX(fm)) { @@ -1747,14 +1780,14 @@ var require_range = __commonJS({ to = `<=${to}`; } return `${from} ${to}`.trim(); - }; - var testSet = (set, version2, options) => { + }, "hyphenReplace"); + var testSet = /* @__PURE__ */ __name((set, version3, options) => { for (let i = 0; i < set.length; i++) { - if (!set[i].test(version2)) { + if (!set[i].test(version3)) { return false; } } - if (version2.prerelease.length && !options.includePrerelease) { + if (version3.prerelease.length && !options.includePrerelease) { for (let i = 0; i < set.length; i++) { debug(set[i].semver); if (set[i].semver === Comparator.ANY) { @@ -1762,7 +1795,7 @@ var require_range = __commonJS({ } if (set[i].semver.prerelease.length > 0) { const allowed = set[i].semver; - if (allowed.major === version2.major && allowed.minor === version2.minor && allowed.patch === version2.patch) { + if (allowed.major === version3.major && allowed.minor === version3.minor && allowed.patch === version3.patch) { return true; } } @@ -1770,7 +1803,7 @@ var require_range = __commonJS({ return false; } return true; - }; + }, "testSet"); } }); @@ -1778,19 +1811,20 @@ var require_range = __commonJS({ var require_comparator = __commonJS({ "node_modules/semver/classes/comparator.js"(exports, module2) { var ANY = Symbol("SemVer ANY"); - var Comparator = class { + var _Comparator = class _Comparator { static get ANY() { return ANY; } constructor(comp, options) { options = parseOptions(options); - if (comp instanceof Comparator) { + if (comp instanceof _Comparator) { if (comp.loose === !!options.loose) { return comp; } else { comp = comp.value; } } + comp = comp.trim().split(/\s+/).join(" "); debug("comparator", comp, options); this.options = options; this.loose = !!options.loose; @@ -1821,22 +1855,22 @@ var require_comparator = __commonJS({ toString() { return this.value; } - test(version2) { - debug("Comparator.test", version2, this.options.loose); - if (this.semver === ANY || version2 === ANY) { + test(version3) { + debug("Comparator.test", version3, this.options.loose); + if (this.semver === ANY || version3 === ANY) { return true; } - if (typeof version2 === "string") { + if (typeof version3 === "string") { try { - version2 = new SemVer(version2, this.options); + version3 = new SemVer(version3, this.options); } catch (er) { return false; } } - return cmp(version2, this.operator, this.semver, this.options); + return cmp(version3, this.operator, this.semver, this.options); } intersects(comp, options) { - if (!(comp instanceof Comparator)) { + if (!(comp instanceof _Comparator)) { throw new TypeError("a Comparator is required"); } if (this.operator === "") { @@ -1875,9 +1909,11 @@ var require_comparator = __commonJS({ return false; } }; + __name(_Comparator, "Comparator"); + var Comparator = _Comparator; module2.exports = Comparator; var parseOptions = require_parse_options(); - var { re, t } = require_re(); + var { safeRe: re, t } = require_re(); var cmp = require_cmp(); var debug = require_debug(); var SemVer = require_semver(); @@ -1889,14 +1925,14 @@ var require_comparator = __commonJS({ var require_satisfies = __commonJS({ "node_modules/semver/functions/satisfies.js"(exports, module2) { var Range = require_range(); - var satisfies = (version2, range, options) => { + var satisfies = /* @__PURE__ */ __name((version3, range, options) => { try { range = new Range(range, options); } catch (er) { return false; } - return range.test(version2); - }; + return range.test(version3); + }, "satisfies"); module2.exports = satisfies; } }); @@ -1905,7 +1941,7 @@ var require_satisfies = __commonJS({ var require_to_comparators = __commonJS({ "node_modules/semver/ranges/to-comparators.js"(exports, module2) { var Range = require_range(); - var toComparators = (range, options) => new Range(range, options).set.map((comp) => comp.map((c) => c.value).join(" ").trim().split(" ")); + var toComparators = /* @__PURE__ */ __name((range, options) => new Range(range, options).set.map((comp) => comp.map((c) => c.value).join(" ").trim().split(" ")), "toComparators"); module2.exports = toComparators; } }); @@ -1915,7 +1951,7 @@ var require_max_satisfying = __commonJS({ "node_modules/semver/ranges/max-satisfying.js"(exports, module2) { var SemVer = require_semver(); var Range = require_range(); - var maxSatisfying = (versions, range, options) => { + var maxSatisfying = /* @__PURE__ */ __name((versions, range, options) => { let max = null; let maxSV = null; let rangeObj = null; @@ -1933,7 +1969,7 @@ var require_max_satisfying = __commonJS({ } }); return max; - }; + }, "maxSatisfying"); module2.exports = maxSatisfying; } }); @@ -1943,7 +1979,7 @@ var require_min_satisfying = __commonJS({ "node_modules/semver/ranges/min-satisfying.js"(exports, module2) { var SemVer = require_semver(); var Range = require_range(); - var minSatisfying = (versions, range, options) => { + var minSatisfying = /* @__PURE__ */ __name((versions, range, options) => { let min = null; let minSV = null; let rangeObj = null; @@ -1961,7 +1997,7 @@ var require_min_satisfying = __commonJS({ } }); return min; - }; + }, "minSatisfying"); module2.exports = minSatisfying; } }); @@ -1972,7 +2008,7 @@ var require_min_version = __commonJS({ var SemVer = require_semver(); var Range = require_range(); var gt = require_gt(); - var minVersion = (range, loose) => { + var minVersion = /* @__PURE__ */ __name((range, loose) => { range = new Range(range, loose); let minver = new SemVer("0.0.0"); if (range.test(minver)) { @@ -2017,7 +2053,7 @@ var require_min_version = __commonJS({ return minver; } return null; - }; + }, "minVersion"); module2.exports = minVersion; } }); @@ -2026,13 +2062,13 @@ var require_min_version = __commonJS({ var require_valid2 = __commonJS({ "node_modules/semver/ranges/valid.js"(exports, module2) { var Range = require_range(); - var validRange = (range, options) => { + var validRange = /* @__PURE__ */ __name((range, options) => { try { return new Range(range, options).range || "*"; } catch (er) { return null; } - }; + }, "validRange"); module2.exports = validRange; } }); @@ -2049,8 +2085,8 @@ var require_outside = __commonJS({ var lt = require_lt(); var lte = require_lte(); var gte = require_gte(); - var outside = (version2, range, hilo, options) => { - version2 = new SemVer(version2, options); + var outside = /* @__PURE__ */ __name((version3, range, hilo, options) => { + version3 = new SemVer(version3, options); range = new Range(range, options); let gtfn, ltefn, ltfn, comp, ecomp; switch (hilo) { @@ -2071,7 +2107,7 @@ var require_outside = __commonJS({ default: throw new TypeError('Must provide a hilo val of "<" or ">"'); } - if (satisfies(version2, range, options)) { + if (satisfies(version3, range, options)) { return false; } for (let i = 0; i < range.set.length; ++i) { @@ -2093,14 +2129,14 @@ var require_outside = __commonJS({ if (high.operator === comp || high.operator === ecomp) { return false; } - if ((!low.operator || low.operator === comp) && ltefn(version2, low.semver)) { + if ((!low.operator || low.operator === comp) && ltefn(version3, low.semver)) { return false; - } else if (low.operator === ecomp && ltfn(version2, low.semver)) { + } else if (low.operator === ecomp && ltfn(version3, low.semver)) { return false; } } return true; - }; + }, "outside"); module2.exports = outside; } }); @@ -2109,7 +2145,7 @@ var require_outside = __commonJS({ var require_gtr = __commonJS({ "node_modules/semver/ranges/gtr.js"(exports, module2) { var outside = require_outside(); - var gtr = (version2, range, options) => outside(version2, range, ">", options); + var gtr = /* @__PURE__ */ __name((version3, range, options) => outside(version3, range, ">", options), "gtr"); module2.exports = gtr; } }); @@ -2118,7 +2154,7 @@ var require_gtr = __commonJS({ var require_ltr = __commonJS({ "node_modules/semver/ranges/ltr.js"(exports, module2) { var outside = require_outside(); - var ltr = (version2, range, options) => outside(version2, range, "<", options); + var ltr = /* @__PURE__ */ __name((version3, range, options) => outside(version3, range, "<", options), "ltr"); module2.exports = ltr; } }); @@ -2127,11 +2163,11 @@ var require_ltr = __commonJS({ var require_intersects = __commonJS({ "node_modules/semver/ranges/intersects.js"(exports, module2) { var Range = require_range(); - var intersects = (r1, r2, options) => { + var intersects = /* @__PURE__ */ __name((r1, r2, options) => { r1 = new Range(r1, options); r2 = new Range(r2, options); return r1.intersects(r2, options); - }; + }, "intersects"); module2.exports = intersects; } }); @@ -2146,12 +2182,12 @@ var require_simplify = __commonJS({ let first = null; let prev = null; const v = versions.sort((a, b) => compare(a, b, options)); - for (const version2 of v) { - const included = satisfies(version2, range, options); + for (const version3 of v) { + const included = satisfies(version3, range, options); if (included) { - prev = version2; + prev = version3; if (!first) { - first = version2; + first = version3; } } else { if (prev) { @@ -2193,7 +2229,7 @@ var require_subset = __commonJS({ var { ANY } = Comparator; var satisfies = require_satisfies(); var compare = require_compare(); - var subset = (sub, dom, options = {}) => { + var subset = /* @__PURE__ */ __name((sub, dom, options = {}) => { if (sub === dom) { return true; } @@ -2214,10 +2250,10 @@ var require_subset = __commonJS({ } } return true; - }; + }, "subset"); var minimumVersionWithPreRelease = [new Comparator(">=0.0.0-0")]; var minimumVersion = [new Comparator(">=0.0.0")]; - var simpleSubset = (sub, dom, options) => { + var simpleSubset = /* @__PURE__ */ __name((sub, dom, options) => { if (sub === dom) { return true; } @@ -2328,21 +2364,21 @@ var require_subset = __commonJS({ return false; } return true; - }; - var higherGT = (a, b, options) => { + }, "simpleSubset"); + var higherGT = /* @__PURE__ */ __name((a, b, options) => { if (!a) { return b; } const comp = compare(a.semver, b.semver, options); return comp > 0 ? a : comp < 0 ? b : b.operator === ">" && a.operator === ">=" ? b : a; - }; - var lowerLT = (a, b, options) => { + }, "higherGT"); + var lowerLT = /* @__PURE__ */ __name((a, b, options) => { if (!a) { return b; } const comp = compare(a.semver, b.semver, options); return comp < 0 ? a : comp > 0 ? b : b.operator === "<" && a.operator === "<=" ? b : a; - }; + }, "lowerLT"); module2.exports = subset; } }); @@ -2354,7 +2390,7 @@ var require_semver2 = __commonJS({ var constants = require_constants(); var SemVer = require_semver(); var identifiers = require_identifiers(); - var parse2 = require_parse(); + var parse3 = require_parse(); var valid = require_valid(); var clean = require_clean(); var inc = require_inc(); @@ -2392,7 +2428,7 @@ var require_semver2 = __commonJS({ var simplifyRange = require_simplify(); var subset = require_subset(); module2.exports = { - parse: parse2, + parse: parse3, valid, clean, inc, @@ -2455,6 +2491,7 @@ var require_utils = __commonJS({ } return JSON.stringify(input); } + __name(toCommandValue, "toCommandValue"); exports.toCommandValue = toCommandValue; function toCommandProperties(annotationProperties) { if (!Object.keys(annotationProperties).length) { @@ -2469,6 +2506,7 @@ var require_utils = __commonJS({ endColumn: annotationProperties.endColumn }; } + __name(toCommandProperties, "toCommandProperties"); exports.toCommandProperties = toCommandProperties; } }); @@ -2477,7 +2515,7 @@ var require_utils = __commonJS({ var require_command = __commonJS({ "node_modules/@actions/core/lib/command.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -2488,38 +2526,40 @@ var require_command = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; Object.defineProperty(exports, "__esModule", { value: true }); exports.issue = exports.issueCommand = void 0; - var os2 = __importStar(require("os")); + var os2 = __importStar2(require("os")); var utils_1 = require_utils(); function issueCommand(command, properties, message) { const cmd = new Command(command, properties, message); process.stdout.write(cmd.toString() + os2.EOL); } + __name(issueCommand, "issueCommand"); exports.issueCommand = issueCommand; function issue(name, message = "") { issueCommand(name, {}, message); } + __name(issue, "issue"); exports.issue = issue; var CMD_STRING = "::"; - var Command = class { + var _Command = class _Command { constructor(command, properties, message) { if (!command) { command = "missing.command"; @@ -2551,16 +2591,20 @@ var require_command = __commonJS({ return cmdStr; } }; + __name(_Command, "Command"); + var Command = _Command; function escapeData(s) { return utils_1.toCommandValue(s).replace(/%/g, "%25").replace(/\r/g, "%0D").replace(/\n/g, "%0A"); } + __name(escapeData, "escapeData"); function escapeProperty(s) { return utils_1.toCommandValue(s).replace(/%/g, "%25").replace(/\r/g, "%0D").replace(/\n/g, "%0A").replace(/:/g, "%3A").replace(/,/g, "%2C"); } + __name(escapeProperty, "escapeProperty"); } }); -// node_modules/uuid/dist/esm-node/rng.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/rng.js function rng() { if (poolPtr > rnds8Pool.length - 16) { import_crypto.default.randomFillSync(rnds8Pool); @@ -2570,34 +2614,36 @@ function rng() { } var import_crypto, rnds8Pool, poolPtr; var init_rng = __esm({ - "node_modules/uuid/dist/esm-node/rng.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/rng.js"() { import_crypto = __toESM(require("crypto")); rnds8Pool = new Uint8Array(256); poolPtr = rnds8Pool.length; + __name(rng, "rng"); } }); -// node_modules/uuid/dist/esm-node/regex.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/regex.js var regex_default; var init_regex = __esm({ - "node_modules/uuid/dist/esm-node/regex.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/regex.js"() { regex_default = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i; } }); -// node_modules/uuid/dist/esm-node/validate.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/validate.js function validate(uuid) { return typeof uuid === "string" && regex_default.test(uuid); } var validate_default; var init_validate = __esm({ - "node_modules/uuid/dist/esm-node/validate.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/validate.js"() { init_regex(); + __name(validate, "validate"); validate_default = validate; } }); -// node_modules/uuid/dist/esm-node/stringify.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/stringify.js function stringify(arr, offset = 0) { const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + "-" + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + "-" + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + "-" + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + "-" + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); if (!validate_default(uuid)) { @@ -2607,17 +2653,18 @@ function stringify(arr, offset = 0) { } var byteToHex, stringify_default; var init_stringify = __esm({ - "node_modules/uuid/dist/esm-node/stringify.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/stringify.js"() { init_validate(); byteToHex = []; for (let i = 0; i < 256; ++i) { byteToHex.push((i + 256).toString(16).substr(1)); } + __name(stringify, "stringify"); stringify_default = stringify; } }); -// node_modules/uuid/dist/esm-node/v1.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/v1.js function v1(options, buf, offset) { let i = buf && offset || 0; const b = buf || new Array(16); @@ -2668,16 +2715,17 @@ function v1(options, buf, offset) { } var _nodeId, _clockseq, _lastMSecs, _lastNSecs, v1_default; var init_v1 = __esm({ - "node_modules/uuid/dist/esm-node/v1.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/v1.js"() { init_rng(); init_stringify(); _lastMSecs = 0; _lastNSecs = 0; + __name(v1, "v1"); v1_default = v1; } }); -// node_modules/uuid/dist/esm-node/parse.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/parse.js function parse(uuid) { if (!validate_default(uuid)) { throw TypeError("Invalid UUID"); @@ -2704,13 +2752,14 @@ function parse(uuid) { } var parse_default; var init_parse = __esm({ - "node_modules/uuid/dist/esm-node/parse.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/parse.js"() { init_validate(); + __name(parse, "parse"); parse_default = parse; } }); -// node_modules/uuid/dist/esm-node/v35.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/v35.js function stringToBytes(str) { str = unescape(encodeURIComponent(str)); const bytes = []; @@ -2719,7 +2768,7 @@ function stringToBytes(str) { } return bytes; } -function v35_default(name, version2, hashfunc) { +function v35_default(name, version3, hashfunc) { function generateUUID(value, namespace, buf, offset) { if (typeof value === "string") { value = stringToBytes(value); @@ -2734,7 +2783,7 @@ function v35_default(name, version2, hashfunc) { bytes.set(namespace); bytes.set(value, namespace.length); bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 15 | version2; + bytes[6] = bytes[6] & 15 | version3; bytes[8] = bytes[8] & 63 | 128; if (buf) { offset = offset || 0; @@ -2745,6 +2794,7 @@ function v35_default(name, version2, hashfunc) { } return stringify_default(bytes); } + __name(generateUUID, "generateUUID"); try { generateUUID.name = name; } catch (err) { @@ -2755,15 +2805,17 @@ function v35_default(name, version2, hashfunc) { } var DNS, URL2; var init_v35 = __esm({ - "node_modules/uuid/dist/esm-node/v35.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/v35.js"() { init_stringify(); init_parse(); + __name(stringToBytes, "stringToBytes"); DNS = "6ba7b810-9dad-11d1-80b4-00c04fd430c8"; URL2 = "6ba7b811-9dad-11d1-80b4-00c04fd430c8"; + __name(v35_default, "default"); } }); -// node_modules/uuid/dist/esm-node/md5.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/md5.js function md5(bytes) { if (Array.isArray(bytes)) { bytes = Buffer.from(bytes); @@ -2774,16 +2826,17 @@ function md5(bytes) { } var import_crypto2, md5_default; var init_md5 = __esm({ - "node_modules/uuid/dist/esm-node/md5.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/md5.js"() { import_crypto2 = __toESM(require("crypto")); + __name(md5, "md5"); md5_default = md5; } }); -// node_modules/uuid/dist/esm-node/v3.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/v3.js var v3, v3_default; var init_v3 = __esm({ - "node_modules/uuid/dist/esm-node/v3.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/v3.js"() { init_v35(); init_md5(); v3 = v35_default("v3", 48, md5_default); @@ -2791,7 +2844,7 @@ var init_v3 = __esm({ } }); -// node_modules/uuid/dist/esm-node/v4.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/v4.js function v4(options, buf, offset) { options = options || {}; const rnds = options.random || (options.rng || rng)(); @@ -2808,14 +2861,15 @@ function v4(options, buf, offset) { } var v4_default; var init_v4 = __esm({ - "node_modules/uuid/dist/esm-node/v4.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/v4.js"() { init_rng(); init_stringify(); + __name(v4, "v4"); v4_default = v4; } }); -// node_modules/uuid/dist/esm-node/sha1.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/sha1.js function sha1(bytes) { if (Array.isArray(bytes)) { bytes = Buffer.from(bytes); @@ -2826,16 +2880,17 @@ function sha1(bytes) { } var import_crypto3, sha1_default; var init_sha1 = __esm({ - "node_modules/uuid/dist/esm-node/sha1.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/sha1.js"() { import_crypto3 = __toESM(require("crypto")); + __name(sha1, "sha1"); sha1_default = sha1; } }); -// node_modules/uuid/dist/esm-node/v5.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/v5.js var v5, v5_default; var init_v5 = __esm({ - "node_modules/uuid/dist/esm-node/v5.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/v5.js"() { init_v35(); init_sha1(); v5 = v35_default("v5", 80, sha1_default); @@ -2843,15 +2898,15 @@ var init_v5 = __esm({ } }); -// node_modules/uuid/dist/esm-node/nil.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/nil.js var nil_default; var init_nil = __esm({ - "node_modules/uuid/dist/esm-node/nil.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/nil.js"() { nil_default = "00000000-0000-0000-0000-000000000000"; } }); -// node_modules/uuid/dist/esm-node/version.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/version.js function version(uuid) { if (!validate_default(uuid)) { throw TypeError("Invalid UUID"); @@ -2860,13 +2915,14 @@ function version(uuid) { } var version_default; var init_version = __esm({ - "node_modules/uuid/dist/esm-node/version.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/version.js"() { init_validate(); + __name(version, "version"); version_default = version; } }); -// node_modules/uuid/dist/esm-node/index.js +// node_modules/@actions/core/node_modules/uuid/dist/esm-node/index.js var esm_node_exports = {}; __export(esm_node_exports, { NIL: () => nil_default, @@ -2880,7 +2936,7 @@ __export(esm_node_exports, { version: () => version_default }); var init_esm_node = __esm({ - "node_modules/uuid/dist/esm-node/index.js"() { + "node_modules/@actions/core/node_modules/uuid/dist/esm-node/index.js"() { init_v1(); init_v3(); init_v4(); @@ -2897,7 +2953,7 @@ var init_esm_node = __esm({ var require_file_command = __commonJS({ "node_modules/@actions/core/lib/file-command.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -2908,27 +2964,27 @@ var require_file_command = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; Object.defineProperty(exports, "__esModule", { value: true }); exports.prepareKeyValueMessage = exports.issueFileCommand = void 0; - var fs = __importStar(require("fs")); - var os2 = __importStar(require("os")); + var fs = __importStar2(require("fs")); + var os2 = __importStar2(require("os")); var uuid_1 = (init_esm_node(), __toCommonJS(esm_node_exports)); var utils_1 = require_utils(); function issueFileCommand(command, message) { @@ -2943,6 +2999,7 @@ var require_file_command = __commonJS({ encoding: "utf8" }); } + __name(issueFileCommand, "issueFileCommand"); exports.issueFileCommand = issueFileCommand; function prepareKeyValueMessage(key, value) { const delimiter = `ghadelimiter_${uuid_1.v4()}`; @@ -2955,6 +3012,7 @@ var require_file_command = __commonJS({ } return `${key}<<${delimiter}${os2.EOL}${convertedValue}${os2.EOL}${delimiter}`; } + __name(prepareKeyValueMessage, "prepareKeyValueMessage"); exports.prepareKeyValueMessage = prepareKeyValueMessage; } }); @@ -2983,6 +3041,7 @@ var require_proxy = __commonJS({ return void 0; } } + __name(getProxyUrl, "getProxyUrl"); exports.getProxyUrl = getProxyUrl; function checkBypass(reqUrl) { if (!reqUrl.hostname) { @@ -3015,11 +3074,13 @@ var require_proxy = __commonJS({ } return false; } + __name(checkBypass, "checkBypass"); exports.checkBypass = checkBypass; function isLoopbackAddress(host) { const hostLower = host.toLowerCase(); return hostLower === "localhost" || hostLower.startsWith("127.") || hostLower.startsWith("[::1]") || hostLower.startsWith("[0:0:0:0:0:0:0:1]"); } + __name(isLoopbackAddress, "isLoopbackAddress"); } }); @@ -3043,6 +3104,7 @@ var require_tunnel = __commonJS({ agent.request = http.request; return agent; } + __name(httpOverHttp, "httpOverHttp"); function httpsOverHttp(options) { var agent = new TunnelingAgent(options); agent.request = http.request; @@ -3050,11 +3112,13 @@ var require_tunnel = __commonJS({ agent.defaultPort = 443; return agent; } + __name(httpsOverHttp, "httpsOverHttp"); function httpOverHttps(options) { var agent = new TunnelingAgent(options); agent.request = https.request; return agent; } + __name(httpOverHttps, "httpOverHttps"); function httpsOverHttps(options) { var agent = new TunnelingAgent(options); agent.request = https.request; @@ -3062,6 +3126,7 @@ var require_tunnel = __commonJS({ agent.defaultPort = 443; return agent; } + __name(httpsOverHttps, "httpsOverHttps"); function TunnelingAgent(options) { var self = this; self.options = options || {}; @@ -3069,7 +3134,7 @@ var require_tunnel = __commonJS({ self.maxSockets = self.options.maxSockets || http.Agent.defaultMaxSockets; self.requests = []; self.sockets = []; - self.on("free", function onFree(socket, host, port, localAddress) { + self.on("free", /* @__PURE__ */ __name(function onFree(socket, host, port, localAddress) { var options2 = toOptions(host, port, localAddress); for (var i = 0, len = self.requests.length; i < len; ++i) { var pending = self.requests[i]; @@ -3081,10 +3146,11 @@ var require_tunnel = __commonJS({ } socket.destroy(); self.removeSocket(socket); - }); + }, "onFree")); } + __name(TunnelingAgent, "TunnelingAgent"); util.inherits(TunnelingAgent, events.EventEmitter); - TunnelingAgent.prototype.addRequest = function addRequest(req, host, port, localAddress) { + TunnelingAgent.prototype.addRequest = /* @__PURE__ */ __name(function addRequest(req, host, port, localAddress) { var self = this; var options = mergeOptions({ request: req }, self.options, toOptions(host, port, localAddress)); if (self.sockets.length >= this.maxSockets) { @@ -3099,15 +3165,17 @@ var require_tunnel = __commonJS({ function onFree() { self.emit("free", socket, options); } + __name(onFree, "onFree"); function onCloseOrRemove(err) { self.removeSocket(socket); socket.removeListener("free", onFree); socket.removeListener("close", onCloseOrRemove); socket.removeListener("agentRemove", onCloseOrRemove); } + __name(onCloseOrRemove, "onCloseOrRemove"); }); - }; - TunnelingAgent.prototype.createSocket = function createSocket(options, cb) { + }, "addRequest"); + TunnelingAgent.prototype.createSocket = /* @__PURE__ */ __name(function createSocket(options, cb) { var self = this; var placeholder = {}; self.sockets.push(placeholder); @@ -3137,11 +3205,13 @@ var require_tunnel = __commonJS({ function onResponse(res) { res.upgrade = true; } + __name(onResponse, "onResponse"); function onUpgrade(res, socket, head) { process.nextTick(function() { onConnect(res, socket, head); }); } + __name(onUpgrade, "onUpgrade"); function onConnect(res, socket, head) { connectReq.removeAllListeners(); socket.removeAllListeners(); @@ -3170,6 +3240,7 @@ var require_tunnel = __commonJS({ self.sockets[self.sockets.indexOf(placeholder)] = socket; return cb(socket); } + __name(onConnect, "onConnect"); function onError(cause) { connectReq.removeAllListeners(); debug( @@ -3182,8 +3253,9 @@ var require_tunnel = __commonJS({ options.request.emit("error", error); self.removeSocket(placeholder); } - }; - TunnelingAgent.prototype.removeSocket = function removeSocket(socket) { + __name(onError, "onError"); + }, "createSocket"); + TunnelingAgent.prototype.removeSocket = /* @__PURE__ */ __name(function removeSocket(socket) { var pos = this.sockets.indexOf(socket); if (pos === -1) { return; @@ -3195,7 +3267,7 @@ var require_tunnel = __commonJS({ pending.request.onSocket(socket2); }); } - }; + }, "removeSocket"); function createSecureSocket(options, cb) { var self = this; TunnelingAgent.prototype.createSocket.call(self, options, function(socket) { @@ -3209,6 +3281,7 @@ var require_tunnel = __commonJS({ cb(secureSocket); }); } + __name(createSecureSocket, "createSecureSocket"); function toOptions(host, port, localAddress) { if (typeof host === "string") { return { @@ -3219,6 +3292,7 @@ var require_tunnel = __commonJS({ } return host; } + __name(toOptions, "toOptions"); function mergeOptions(target) { for (var i = 1, len = arguments.length; i < len; ++i) { var overrides = arguments[i]; @@ -3234,9 +3308,10 @@ var require_tunnel = __commonJS({ } return target; } + __name(mergeOptions, "mergeOptions"); var debug; if (process.env.NODE_DEBUG && /\btunnel\b/.test(process.env.NODE_DEBUG)) { - debug = function() { + debug = /* @__PURE__ */ __name(function() { var args = Array.prototype.slice.call(arguments); if (typeof args[0] === "string") { args[0] = "TUNNEL: " + args[0]; @@ -3244,10 +3319,10 @@ var require_tunnel = __commonJS({ args.unshift("TUNNEL:"); } console.error.apply(console, args); - }; + }, "debug"); } else { - debug = function() { - }; + debug = /* @__PURE__ */ __name(function() { + }, "debug"); } exports.debug = debug; } @@ -3264,7 +3339,7 @@ var require_tunnel2 = __commonJS({ var require_lib = __commonJS({ "node_modules/@actions/http-client/lib/index.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -3275,29 +3350,30 @@ var require_lib = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -3306,6 +3382,7 @@ var require_lib = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -3313,18 +3390,20 @@ var require_lib = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.HttpClient = exports.isHttps = exports.HttpClientResponse = exports.HttpClientError = exports.getProxyUrl = exports.MediaTypes = exports.Headers = exports.HttpCodes = void 0; - var http = __importStar(require("http")); - var https = __importStar(require("https")); - var pm = __importStar(require_proxy()); - var tunnel = __importStar(require_tunnel2()); + var http = __importStar2(require("http")); + var https = __importStar2(require("https")); + var pm = __importStar2(require_proxy()); + var tunnel = __importStar2(require_tunnel2()); var HttpCodes; (function(HttpCodes2) { HttpCodes2[HttpCodes2["OK"] = 200] = "OK"; @@ -3368,6 +3447,7 @@ var require_lib = __commonJS({ const proxyUrl = pm.getProxyUrl(new URL(serverUrl)); return proxyUrl ? proxyUrl.href : ""; } + __name(getProxyUrl, "getProxyUrl"); exports.getProxyUrl = getProxyUrl; var HttpRedirectCodes = [ HttpCodes.MovedPermanently, @@ -3384,22 +3464,24 @@ var require_lib = __commonJS({ var RetryableHttpVerbs = ["OPTIONS", "GET", "DELETE", "HEAD"]; var ExponentialBackoffCeiling = 10; var ExponentialBackoffTimeSlice = 5; - var HttpClientError = class extends Error { + var _HttpClientError = class _HttpClientError extends Error { constructor(message, statusCode) { super(message); this.name = "HttpClientError"; this.statusCode = statusCode; - Object.setPrototypeOf(this, HttpClientError.prototype); + Object.setPrototypeOf(this, _HttpClientError.prototype); } }; + __name(_HttpClientError, "HttpClientError"); + var HttpClientError = _HttpClientError; exports.HttpClientError = HttpClientError; - var HttpClientResponse = class { + var _HttpClientResponse = class _HttpClientResponse { constructor(message) { this.message = message; } readBody() { - return __awaiter(this, void 0, void 0, function* () { - return new Promise((resolve) => __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { + return new Promise((resolve) => __awaiter2(this, void 0, void 0, function* () { let output = Buffer.alloc(0); this.message.on("data", (chunk) => { output = Buffer.concat([output, chunk]); @@ -3411,13 +3493,16 @@ var require_lib = __commonJS({ }); } }; + __name(_HttpClientResponse, "HttpClientResponse"); + var HttpClientResponse = _HttpClientResponse; exports.HttpClientResponse = HttpClientResponse; function isHttps(requestUrl) { const parsedUrl = new URL(requestUrl); return parsedUrl.protocol === "https:"; } + __name(isHttps, "isHttps"); exports.isHttps = isHttps; - var HttpClient = class { + var _HttpClient = class _HttpClient { constructor(userAgent, handlers, requestOptions) { this._ignoreSslError = false; this._allowRedirects = true; @@ -3456,42 +3541,42 @@ var require_lib = __commonJS({ } } options(requestUrl, additionalHeaders) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return this.request("OPTIONS", requestUrl, null, additionalHeaders || {}); }); } get(requestUrl, additionalHeaders) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return this.request("GET", requestUrl, null, additionalHeaders || {}); }); } del(requestUrl, additionalHeaders) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return this.request("DELETE", requestUrl, null, additionalHeaders || {}); }); } post(requestUrl, data, additionalHeaders) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return this.request("POST", requestUrl, data, additionalHeaders || {}); }); } patch(requestUrl, data, additionalHeaders) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return this.request("PATCH", requestUrl, data, additionalHeaders || {}); }); } put(requestUrl, data, additionalHeaders) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return this.request("PUT", requestUrl, data, additionalHeaders || {}); }); } head(requestUrl, additionalHeaders) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return this.request("HEAD", requestUrl, null, additionalHeaders || {}); }); } sendStream(verb, requestUrl, stream, additionalHeaders) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return this.request(verb, requestUrl, stream, additionalHeaders); }); } @@ -3500,14 +3585,14 @@ var require_lib = __commonJS({ * Be aware that not found returns a null. Other errors (4xx, 5xx) reject the promise */ getJson(requestUrl, additionalHeaders = {}) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson); const res = yield this.get(requestUrl, additionalHeaders); return this._processResponse(res, this.requestOptions); }); } postJson(requestUrl, obj, additionalHeaders = {}) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { const data = JSON.stringify(obj, null, 2); additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson); additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson); @@ -3516,7 +3601,7 @@ var require_lib = __commonJS({ }); } putJson(requestUrl, obj, additionalHeaders = {}) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { const data = JSON.stringify(obj, null, 2); additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson); additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson); @@ -3525,7 +3610,7 @@ var require_lib = __commonJS({ }); } patchJson(requestUrl, obj, additionalHeaders = {}) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { const data = JSON.stringify(obj, null, 2); additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson); additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson); @@ -3539,7 +3624,7 @@ var require_lib = __commonJS({ * Prefer get, del, post and patch */ request(verb, requestUrl, data, headers) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { if (this._disposed) { throw new Error("Client has already been disposed."); } @@ -3613,7 +3698,7 @@ var require_lib = __commonJS({ * @param data */ requestRaw(info, data) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return new Promise((resolve, reject) => { function callbackForResult(err, res) { if (err) { @@ -3624,6 +3709,7 @@ var require_lib = __commonJS({ resolve(res); } } + __name(callbackForResult, "callbackForResult"); this.requestRawWithCallback(info, data, callbackForResult); }); }); @@ -3648,6 +3734,7 @@ var require_lib = __commonJS({ onResult(err, res); } } + __name(handleResult, "handleResult"); const req = info.httpModule.request(info.options, (msg) => { const res = new HttpClientResponse(msg); handleResult(void 0, res); @@ -3774,15 +3861,15 @@ var require_lib = __commonJS({ return agent; } _performExponentialBackoff(retryNumber) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { retryNumber = Math.min(ExponentialBackoffCeiling, retryNumber); const ms = ExponentialBackoffTimeSlice * Math.pow(2, retryNumber); return new Promise((resolve) => setTimeout(() => resolve(), ms)); }); } _processResponse(res, options) { - return __awaiter(this, void 0, void 0, function* () { - return new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { + return new Promise((resolve, reject) => __awaiter2(this, void 0, void 0, function* () { const statusCode = res.message.statusCode || 0; const response = { statusCode, @@ -3801,6 +3888,7 @@ var require_lib = __commonJS({ } return value; } + __name(dateTimeDeserializer, "dateTimeDeserializer"); let obj; let contents; try { @@ -3835,8 +3923,10 @@ var require_lib = __commonJS({ }); } }; + __name(_HttpClient, "HttpClient"); + var HttpClient = _HttpClient; exports.HttpClient = HttpClient; - var lowercaseKeys = (obj) => Object.keys(obj).reduce((c, k) => (c[k.toLowerCase()] = obj[k], c), {}); + var lowercaseKeys = /* @__PURE__ */ __name((obj) => Object.keys(obj).reduce((c, k) => (c[k.toLowerCase()] = obj[k], c), {}), "lowercaseKeys"); } }); @@ -3844,12 +3934,13 @@ var require_lib = __commonJS({ var require_auth = __commonJS({ "node_modules/@actions/http-client/lib/auth.js"(exports) { "use strict"; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -3858,6 +3949,7 @@ var require_auth = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -3865,15 +3957,17 @@ var require_auth = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.PersonalAccessTokenCredentialHandler = exports.BearerCredentialHandler = exports.BasicCredentialHandler = void 0; - var BasicCredentialHandler = class { + var _BasicCredentialHandler = class _BasicCredentialHandler { constructor(username, password) { this.username = username; this.password = password; @@ -3889,13 +3983,15 @@ var require_auth = __commonJS({ return false; } handleAuthentication() { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { throw new Error("not implemented"); }); } }; + __name(_BasicCredentialHandler, "BasicCredentialHandler"); + var BasicCredentialHandler = _BasicCredentialHandler; exports.BasicCredentialHandler = BasicCredentialHandler; - var BearerCredentialHandler = class { + var _BearerCredentialHandler = class _BearerCredentialHandler { constructor(token) { this.token = token; } @@ -3912,13 +4008,15 @@ var require_auth = __commonJS({ return false; } handleAuthentication() { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { throw new Error("not implemented"); }); } }; + __name(_BearerCredentialHandler, "BearerCredentialHandler"); + var BearerCredentialHandler = _BearerCredentialHandler; exports.BearerCredentialHandler = BearerCredentialHandler; - var PersonalAccessTokenCredentialHandler = class { + var _PersonalAccessTokenCredentialHandler = class _PersonalAccessTokenCredentialHandler { constructor(token) { this.token = token; } @@ -3935,11 +4033,13 @@ var require_auth = __commonJS({ return false; } handleAuthentication() { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { throw new Error("not implemented"); }); } }; + __name(_PersonalAccessTokenCredentialHandler, "PersonalAccessTokenCredentialHandler"); + var PersonalAccessTokenCredentialHandler = _PersonalAccessTokenCredentialHandler; exports.PersonalAccessTokenCredentialHandler = PersonalAccessTokenCredentialHandler; } }); @@ -3948,12 +4048,13 @@ var require_auth = __commonJS({ var require_oidc_utils = __commonJS({ "node_modules/@actions/core/lib/oidc-utils.js"(exports) { "use strict"; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -3962,6 +4063,7 @@ var require_oidc_utils = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -3969,9 +4071,11 @@ var require_oidc_utils = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; @@ -3980,13 +4084,13 @@ var require_oidc_utils = __commonJS({ var http_client_1 = require_lib(); var auth_1 = require_auth(); var core_1 = require_core(); - var OidcClient = class { + var _OidcClient = class _OidcClient { static createHttpClient(allowRetry = true, maxRetry = 10) { const requestOptions = { allowRetries: allowRetry, maxRetries: maxRetry }; - return new http_client_1.HttpClient("actions/oidc-client", [new auth_1.BearerCredentialHandler(OidcClient.getRequestToken())], requestOptions); + return new http_client_1.HttpClient("actions/oidc-client", [new auth_1.BearerCredentialHandler(_OidcClient.getRequestToken())], requestOptions); } static getRequestToken() { const token = process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"]; @@ -4004,8 +4108,8 @@ var require_oidc_utils = __commonJS({ } static getCall(id_token_url) { var _a; - return __awaiter(this, void 0, void 0, function* () { - const httpclient = OidcClient.createHttpClient(); + return __awaiter2(this, void 0, void 0, function* () { + const httpclient = _OidcClient.createHttpClient(); const res = yield httpclient.getJson(id_token_url).catch((error) => { throw new Error(`Failed to get ID Token. @@ -4021,15 +4125,15 @@ var require_oidc_utils = __commonJS({ }); } static getIDToken(audience) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { try { - let id_token_url = OidcClient.getIDTokenUrl(); + let id_token_url = _OidcClient.getIDTokenUrl(); if (audience) { const encodedAudience = encodeURIComponent(audience); id_token_url = `${id_token_url}&audience=${encodedAudience}`; } core_1.debug(`ID token url is ${id_token_url}`); - const id_token = yield OidcClient.getCall(id_token_url); + const id_token = yield _OidcClient.getCall(id_token_url); core_1.setSecret(id_token); return id_token; } catch (error) { @@ -4038,6 +4142,8 @@ var require_oidc_utils = __commonJS({ }); } }; + __name(_OidcClient, "OidcClient"); + var OidcClient = _OidcClient; exports.OidcClient = OidcClient; } }); @@ -4046,12 +4152,13 @@ var require_oidc_utils = __commonJS({ var require_summary = __commonJS({ "node_modules/@actions/core/lib/summary.js"(exports) { "use strict"; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -4060,6 +4167,7 @@ var require_summary = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -4067,9 +4175,11 @@ var require_summary = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; @@ -4080,7 +4190,7 @@ var require_summary = __commonJS({ var { access, appendFile, writeFile } = fs_1.promises; exports.SUMMARY_ENV_VAR = "GITHUB_STEP_SUMMARY"; exports.SUMMARY_DOCS_URL = "https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary"; - var Summary = class { + var _Summary = class _Summary { constructor() { this._buffer = ""; } @@ -4091,7 +4201,7 @@ var require_summary = __commonJS({ * @returns step summary file path */ filePath() { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { if (this._filePath) { return this._filePath; } @@ -4132,7 +4242,7 @@ var require_summary = __commonJS({ * @returns {Promise} summary instance */ write(options) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { const overwrite = !!(options === null || options === void 0 ? void 0 : options.overwrite); const filePath = yield this.filePath(); const writeFunc = overwrite ? writeFile : appendFile; @@ -4146,7 +4256,7 @@ var require_summary = __commonJS({ * @returns {Summary} summary instance */ clear() { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return this.emptyBuffer().write({ overwrite: true }); }); } @@ -4330,6 +4440,8 @@ var require_summary = __commonJS({ return this.addRaw(element).addEOL(); } }; + __name(_Summary, "Summary"); + var Summary = _Summary; var _summary = new Summary(); exports.markdownSummary = _summary; exports.summary = _summary; @@ -4340,7 +4452,7 @@ var require_summary = __commonJS({ var require_path_utils = __commonJS({ "node_modules/@actions/core/lib/path-utils.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -4351,37 +4463,40 @@ var require_path_utils = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; Object.defineProperty(exports, "__esModule", { value: true }); exports.toPlatformPath = exports.toWin32Path = exports.toPosixPath = void 0; - var path2 = __importStar(require("path")); + var path2 = __importStar2(require("path")); function toPosixPath(pth) { return pth.replace(/[\\]/g, "/"); } + __name(toPosixPath, "toPosixPath"); exports.toPosixPath = toPosixPath; function toWin32Path(pth) { return pth.replace(/[/]/g, "\\"); } + __name(toWin32Path, "toWin32Path"); exports.toWin32Path = toWin32Path; function toPlatformPath(pth) { return pth.replace(/[/\\]/g, path2.sep); } + __name(toPlatformPath, "toPlatformPath"); exports.toPlatformPath = toPlatformPath; } }); @@ -4390,7 +4505,7 @@ var require_path_utils = __commonJS({ var require_core = __commonJS({ "node_modules/@actions/core/lib/core.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -4401,29 +4516,30 @@ var require_core = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -4432,6 +4548,7 @@ var require_core = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -4439,9 +4556,11 @@ var require_core = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; @@ -4450,8 +4569,8 @@ var require_core = __commonJS({ var command_1 = require_command(); var file_command_1 = require_file_command(); var utils_1 = require_utils(); - var os2 = __importStar(require("os")); - var path2 = __importStar(require("path")); + var os2 = __importStar2(require("os")); + var path2 = __importStar2(require("path")); var oidc_utils_1 = require_oidc_utils(); var ExitCode; (function(ExitCode2) { @@ -4467,10 +4586,12 @@ var require_core = __commonJS({ } command_1.issueCommand("set-env", { name }, convertedVal); } + __name(exportVariable, "exportVariable"); exports.exportVariable = exportVariable; function setSecret(secret) { command_1.issueCommand("add-mask", {}, secret); } + __name(setSecret, "setSecret"); exports.setSecret = setSecret; function addPath(inputPath) { const filePath = process.env["GITHUB_PATH"] || ""; @@ -4481,6 +4602,7 @@ var require_core = __commonJS({ } process.env["PATH"] = `${inputPath}${path2.delimiter}${process.env["PATH"]}`; } + __name(addPath, "addPath"); exports.addPath = addPath; function getInput(name, options) { const val = process.env[`INPUT_${name.replace(/ /g, "_").toUpperCase()}`] || ""; @@ -4492,6 +4614,7 @@ var require_core = __commonJS({ } return val.trim(); } + __name(getInput, "getInput"); exports.getInput = getInput; function getMultilineInput(name, options) { const inputs = getInput(name, options).split("\n").filter((x) => x !== ""); @@ -4500,6 +4623,7 @@ var require_core = __commonJS({ } return inputs.map((input) => input.trim()); } + __name(getMultilineInput, "getMultilineInput"); exports.getMultilineInput = getMultilineInput; function getBooleanInput(name, options) { const trueValue = ["true", "True", "TRUE"]; @@ -4512,6 +4636,7 @@ var require_core = __commonJS({ throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${name} Support boolean input list: \`true | True | TRUE | false | False | FALSE\``); } + __name(getBooleanInput, "getBooleanInput"); exports.getBooleanInput = getBooleanInput; function setOutput(name, value) { const filePath = process.env["GITHUB_OUTPUT"] || ""; @@ -4521,50 +4646,61 @@ Support boolean input list: \`true | True | TRUE | false | False | FALSE\``); process.stdout.write(os2.EOL); command_1.issueCommand("set-output", { name }, utils_1.toCommandValue(value)); } + __name(setOutput, "setOutput"); exports.setOutput = setOutput; function setCommandEcho(enabled) { command_1.issue("echo", enabled ? "on" : "off"); } + __name(setCommandEcho, "setCommandEcho"); exports.setCommandEcho = setCommandEcho; function setFailed(message) { process.exitCode = ExitCode.Failure; error(message); } + __name(setFailed, "setFailed"); exports.setFailed = setFailed; function isDebug() { return process.env["RUNNER_DEBUG"] === "1"; } + __name(isDebug, "isDebug"); exports.isDebug = isDebug; function debug(message) { command_1.issueCommand("debug", {}, message); } + __name(debug, "debug"); exports.debug = debug; function error(message, properties = {}) { command_1.issueCommand("error", utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message); } + __name(error, "error"); exports.error = error; function warning(message, properties = {}) { command_1.issueCommand("warning", utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message); } + __name(warning, "warning"); exports.warning = warning; function notice(message, properties = {}) { command_1.issueCommand("notice", utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message); } + __name(notice, "notice"); exports.notice = notice; function info(message) { process.stdout.write(message + os2.EOL); } + __name(info, "info"); exports.info = info; function startGroup(name) { command_1.issue("group", name); } + __name(startGroup, "startGroup"); exports.startGroup = startGroup; function endGroup() { command_1.issue("endgroup"); } + __name(endGroup, "endGroup"); exports.endGroup = endGroup; function group(name, fn) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { startGroup(name); let result; try { @@ -4575,6 +4711,7 @@ Support boolean input list: \`true | True | TRUE | false | False | FALSE\``); return result; }); } + __name(group, "group"); exports.group = group; function saveState(name, value) { const filePath = process.env["GITHUB_STATE"] || ""; @@ -4583,16 +4720,19 @@ Support boolean input list: \`true | True | TRUE | false | False | FALSE\``); } command_1.issueCommand("save-state", { name }, utils_1.toCommandValue(value)); } + __name(saveState, "saveState"); exports.saveState = saveState; function getState(name) { return process.env[`STATE_${name}`] || ""; } + __name(getState, "getState"); exports.getState = getState; function getIDToken(aud) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { return yield oidc_utils_1.OidcClient.getIDToken(aud); }); } + __name(getIDToken, "getIDToken"); exports.getIDToken = getIDToken; var summary_1 = require_summary(); Object.defineProperty(exports, "summary", { enumerable: true, get: function() { @@ -4619,7 +4759,7 @@ Support boolean input list: \`true | True | TRUE | false | False | FALSE\``); var require_io_util = __commonJS({ "node_modules/@actions/io/lib/io-util.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -4630,29 +4770,30 @@ var require_io_util = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -4661,6 +4802,7 @@ var require_io_util = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -4668,23 +4810,25 @@ var require_io_util = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; var _a; Object.defineProperty(exports, "__esModule", { value: true }); exports.getCmdPath = exports.tryGetExecutablePath = exports.isRooted = exports.isDirectory = exports.exists = exports.READONLY = exports.UV_FS_O_EXLOCK = exports.IS_WINDOWS = exports.unlink = exports.symlink = exports.stat = exports.rmdir = exports.rm = exports.rename = exports.readlink = exports.readdir = exports.open = exports.mkdir = exports.lstat = exports.copyFile = exports.chmod = void 0; - var fs = __importStar(require("fs")); - var path2 = __importStar(require("path")); + var fs = __importStar2(require("fs")); + var path2 = __importStar2(require("path")); _a = fs.promises, exports.chmod = _a.chmod, exports.copyFile = _a.copyFile, exports.lstat = _a.lstat, exports.mkdir = _a.mkdir, exports.open = _a.open, exports.readdir = _a.readdir, exports.readlink = _a.readlink, exports.rename = _a.rename, exports.rm = _a.rm, exports.rmdir = _a.rmdir, exports.stat = _a.stat, exports.symlink = _a.symlink, exports.unlink = _a.unlink; exports.IS_WINDOWS = process.platform === "win32"; exports.UV_FS_O_EXLOCK = 268435456; exports.READONLY = fs.constants.O_RDONLY; function exists(fsPath) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { try { yield exports.stat(fsPath); } catch (err) { @@ -4696,13 +4840,15 @@ var require_io_util = __commonJS({ return true; }); } + __name(exists, "exists"); exports.exists = exists; function isDirectory(fsPath, useStat = false) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { const stats = useStat ? yield exports.stat(fsPath) : yield exports.lstat(fsPath); return stats.isDirectory(); }); } + __name(isDirectory, "isDirectory"); exports.isDirectory = isDirectory; function isRooted(p) { p = normalizeSeparators(p); @@ -4714,9 +4860,10 @@ var require_io_util = __commonJS({ } return p.startsWith("/"); } + __name(isRooted, "isRooted"); exports.isRooted = isRooted; function tryGetExecutablePath(filePath, extensions) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { let stats = void 0; try { stats = yield exports.stat(filePath); @@ -4773,6 +4920,7 @@ var require_io_util = __commonJS({ return ""; }); } + __name(tryGetExecutablePath, "tryGetExecutablePath"); exports.tryGetExecutablePath = tryGetExecutablePath; function normalizeSeparators(p) { p = p || ""; @@ -4782,13 +4930,16 @@ var require_io_util = __commonJS({ } return p.replace(/\/\/+/g, "/"); } + __name(normalizeSeparators, "normalizeSeparators"); function isUnixExecutable(stats) { return (stats.mode & 1) > 0 || (stats.mode & 8) > 0 && stats.gid === process.getgid() || (stats.mode & 64) > 0 && stats.uid === process.getuid(); } + __name(isUnixExecutable, "isUnixExecutable"); function getCmdPath() { var _a2; return (_a2 = process.env["COMSPEC"]) !== null && _a2 !== void 0 ? _a2 : `cmd.exe`; } + __name(getCmdPath, "getCmdPath"); exports.getCmdPath = getCmdPath; } }); @@ -4797,7 +4948,7 @@ var require_io_util = __commonJS({ var require_io = __commonJS({ "node_modules/@actions/io/lib/io.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -4808,29 +4959,30 @@ var require_io = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -4839,6 +4991,7 @@ var require_io = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -4846,19 +4999,21 @@ var require_io = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.findInPath = exports.which = exports.mkdirP = exports.rmRF = exports.mv = exports.cp = void 0; var assert_1 = require("assert"); - var path2 = __importStar(require("path")); - var ioUtil = __importStar(require_io_util()); + var path2 = __importStar2(require("path")); + var ioUtil = __importStar2(require_io_util()); function cp(source, dest, options = {}) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { const { force, recursive, copySourceDirectory } = readCopyOptions(options); const destStat = (yield ioUtil.exists(dest)) ? yield ioUtil.stat(dest) : null; if (destStat && destStat.isFile() && !force) { @@ -4883,9 +5038,10 @@ var require_io = __commonJS({ } }); } + __name(cp, "cp"); exports.cp = cp; function mv(source, dest, options = {}) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { if (yield ioUtil.exists(dest)) { let destExists = true; if (yield ioUtil.isDirectory(dest)) { @@ -4904,9 +5060,10 @@ var require_io = __commonJS({ yield ioUtil.rename(source, dest); }); } + __name(mv, "mv"); exports.mv = mv; function rmRF(inputPath) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { if (ioUtil.IS_WINDOWS) { if (/[*"<>|]/.test(inputPath)) { throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows'); @@ -4924,16 +5081,18 @@ var require_io = __commonJS({ } }); } + __name(rmRF, "rmRF"); exports.rmRF = rmRF; function mkdirP(fsPath) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { assert_1.ok(fsPath, "a path argument must be provided"); yield ioUtil.mkdir(fsPath, { recursive: true }); }); } + __name(mkdirP, "mkdirP"); exports.mkdirP = mkdirP; function which(tool, check) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { if (!tool) { throw new Error("parameter 'tool' is required"); } @@ -4955,9 +5114,10 @@ var require_io = __commonJS({ return ""; }); } + __name(which, "which"); exports.which = which; function findInPath(tool) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { if (!tool) { throw new Error("parameter 'tool' is required"); } @@ -4997,6 +5157,7 @@ var require_io = __commonJS({ return matches; }); } + __name(findInPath, "findInPath"); exports.findInPath = findInPath; function readCopyOptions(options) { const force = options.force == null ? true : options.force; @@ -5004,8 +5165,9 @@ var require_io = __commonJS({ const copySourceDirectory = options.copySourceDirectory == null ? true : Boolean(options.copySourceDirectory); return { force, recursive, copySourceDirectory }; } + __name(readCopyOptions, "readCopyOptions"); function cpDirRecursive(sourceDir, destDir, currentDepth, force) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { if (currentDepth >= 255) return; currentDepth++; @@ -5024,8 +5186,9 @@ var require_io = __commonJS({ yield ioUtil.chmod(destDir, (yield ioUtil.stat(sourceDir)).mode); }); } + __name(cpDirRecursive, "cpDirRecursive"); function copyFile(srcFile, destFile, force) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { if ((yield ioUtil.lstat(srcFile)).isSymbolicLink()) { try { yield ioUtil.lstat(destFile); @@ -5043,1349 +5206,7 @@ var require_io = __commonJS({ } }); } - } -}); - -// node_modules/@actions/tool-cache/node_modules/semver/semver.js -var require_semver3 = __commonJS({ - "node_modules/@actions/tool-cache/node_modules/semver/semver.js"(exports, module2) { - exports = module2.exports = SemVer; - var debug; - if (typeof process === "object" && process.env && process.env.NODE_DEBUG && /\bsemver\b/i.test(process.env.NODE_DEBUG)) { - debug = function() { - var args = Array.prototype.slice.call(arguments, 0); - args.unshift("SEMVER"); - console.log.apply(console, args); - }; - } else { - debug = function() { - }; - } - exports.SEMVER_SPEC_VERSION = "2.0.0"; - var MAX_LENGTH = 256; - var MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER || /* istanbul ignore next */ - 9007199254740991; - var MAX_SAFE_COMPONENT_LENGTH = 16; - var re = exports.re = []; - var src = exports.src = []; - var t = exports.tokens = {}; - var R = 0; - function tok(n) { - t[n] = R++; - } - tok("NUMERICIDENTIFIER"); - src[t.NUMERICIDENTIFIER] = "0|[1-9]\\d*"; - tok("NUMERICIDENTIFIERLOOSE"); - src[t.NUMERICIDENTIFIERLOOSE] = "[0-9]+"; - tok("NONNUMERICIDENTIFIER"); - src[t.NONNUMERICIDENTIFIER] = "\\d*[a-zA-Z-][a-zA-Z0-9-]*"; - tok("MAINVERSION"); - src[t.MAINVERSION] = "(" + src[t.NUMERICIDENTIFIER] + ")\\.(" + src[t.NUMERICIDENTIFIER] + ")\\.(" + src[t.NUMERICIDENTIFIER] + ")"; - tok("MAINVERSIONLOOSE"); - src[t.MAINVERSIONLOOSE] = "(" + src[t.NUMERICIDENTIFIERLOOSE] + ")\\.(" + src[t.NUMERICIDENTIFIERLOOSE] + ")\\.(" + src[t.NUMERICIDENTIFIERLOOSE] + ")"; - tok("PRERELEASEIDENTIFIER"); - src[t.PRERELEASEIDENTIFIER] = "(?:" + src[t.NUMERICIDENTIFIER] + "|" + src[t.NONNUMERICIDENTIFIER] + ")"; - tok("PRERELEASEIDENTIFIERLOOSE"); - src[t.PRERELEASEIDENTIFIERLOOSE] = "(?:" + src[t.NUMERICIDENTIFIERLOOSE] + "|" + src[t.NONNUMERICIDENTIFIER] + ")"; - tok("PRERELEASE"); - src[t.PRERELEASE] = "(?:-(" + src[t.PRERELEASEIDENTIFIER] + "(?:\\." + src[t.PRERELEASEIDENTIFIER] + ")*))"; - tok("PRERELEASELOOSE"); - src[t.PRERELEASELOOSE] = "(?:-?(" + src[t.PRERELEASEIDENTIFIERLOOSE] + "(?:\\." + src[t.PRERELEASEIDENTIFIERLOOSE] + ")*))"; - tok("BUILDIDENTIFIER"); - src[t.BUILDIDENTIFIER] = "[0-9A-Za-z-]+"; - tok("BUILD"); - src[t.BUILD] = "(?:\\+(" + src[t.BUILDIDENTIFIER] + "(?:\\." + src[t.BUILDIDENTIFIER] + ")*))"; - tok("FULL"); - tok("FULLPLAIN"); - src[t.FULLPLAIN] = "v?" + src[t.MAINVERSION] + src[t.PRERELEASE] + "?" + src[t.BUILD] + "?"; - src[t.FULL] = "^" + src[t.FULLPLAIN] + "$"; - tok("LOOSEPLAIN"); - src[t.LOOSEPLAIN] = "[v=\\s]*" + src[t.MAINVERSIONLOOSE] + src[t.PRERELEASELOOSE] + "?" + src[t.BUILD] + "?"; - tok("LOOSE"); - src[t.LOOSE] = "^" + src[t.LOOSEPLAIN] + "$"; - tok("GTLT"); - src[t.GTLT] = "((?:<|>)?=?)"; - tok("XRANGEIDENTIFIERLOOSE"); - src[t.XRANGEIDENTIFIERLOOSE] = src[t.NUMERICIDENTIFIERLOOSE] + "|x|X|\\*"; - tok("XRANGEIDENTIFIER"); - src[t.XRANGEIDENTIFIER] = src[t.NUMERICIDENTIFIER] + "|x|X|\\*"; - tok("XRANGEPLAIN"); - src[t.XRANGEPLAIN] = "[v=\\s]*(" + src[t.XRANGEIDENTIFIER] + ")(?:\\.(" + src[t.XRANGEIDENTIFIER] + ")(?:\\.(" + src[t.XRANGEIDENTIFIER] + ")(?:" + src[t.PRERELEASE] + ")?" + src[t.BUILD] + "?)?)?"; - tok("XRANGEPLAINLOOSE"); - src[t.XRANGEPLAINLOOSE] = "[v=\\s]*(" + src[t.XRANGEIDENTIFIERLOOSE] + ")(?:\\.(" + src[t.XRANGEIDENTIFIERLOOSE] + ")(?:\\.(" + src[t.XRANGEIDENTIFIERLOOSE] + ")(?:" + src[t.PRERELEASELOOSE] + ")?" + src[t.BUILD] + "?)?)?"; - tok("XRANGE"); - src[t.XRANGE] = "^" + src[t.GTLT] + "\\s*" + src[t.XRANGEPLAIN] + "$"; - tok("XRANGELOOSE"); - src[t.XRANGELOOSE] = "^" + src[t.GTLT] + "\\s*" + src[t.XRANGEPLAINLOOSE] + "$"; - tok("COERCE"); - src[t.COERCE] = "(^|[^\\d])(\\d{1," + MAX_SAFE_COMPONENT_LENGTH + "})(?:\\.(\\d{1," + MAX_SAFE_COMPONENT_LENGTH + "}))?(?:\\.(\\d{1," + MAX_SAFE_COMPONENT_LENGTH + "}))?(?:$|[^\\d])"; - tok("COERCERTL"); - re[t.COERCERTL] = new RegExp(src[t.COERCE], "g"); - tok("LONETILDE"); - src[t.LONETILDE] = "(?:~>?)"; - tok("TILDETRIM"); - src[t.TILDETRIM] = "(\\s*)" + src[t.LONETILDE] + "\\s+"; - re[t.TILDETRIM] = new RegExp(src[t.TILDETRIM], "g"); - var tildeTrimReplace = "$1~"; - tok("TILDE"); - src[t.TILDE] = "^" + src[t.LONETILDE] + src[t.XRANGEPLAIN] + "$"; - tok("TILDELOOSE"); - src[t.TILDELOOSE] = "^" + src[t.LONETILDE] + src[t.XRANGEPLAINLOOSE] + "$"; - tok("LONECARET"); - src[t.LONECARET] = "(?:\\^)"; - tok("CARETTRIM"); - src[t.CARETTRIM] = "(\\s*)" + src[t.LONECARET] + "\\s+"; - re[t.CARETTRIM] = new RegExp(src[t.CARETTRIM], "g"); - var caretTrimReplace = "$1^"; - tok("CARET"); - src[t.CARET] = "^" + src[t.LONECARET] + src[t.XRANGEPLAIN] + "$"; - tok("CARETLOOSE"); - src[t.CARETLOOSE] = "^" + src[t.LONECARET] + src[t.XRANGEPLAINLOOSE] + "$"; - tok("COMPARATORLOOSE"); - src[t.COMPARATORLOOSE] = "^" + src[t.GTLT] + "\\s*(" + src[t.LOOSEPLAIN] + ")$|^$"; - tok("COMPARATOR"); - src[t.COMPARATOR] = "^" + src[t.GTLT] + "\\s*(" + src[t.FULLPLAIN] + ")$|^$"; - tok("COMPARATORTRIM"); - src[t.COMPARATORTRIM] = "(\\s*)" + src[t.GTLT] + "\\s*(" + src[t.LOOSEPLAIN] + "|" + src[t.XRANGEPLAIN] + ")"; - re[t.COMPARATORTRIM] = new RegExp(src[t.COMPARATORTRIM], "g"); - var comparatorTrimReplace = "$1$2$3"; - tok("HYPHENRANGE"); - src[t.HYPHENRANGE] = "^\\s*(" + src[t.XRANGEPLAIN] + ")\\s+-\\s+(" + src[t.XRANGEPLAIN] + ")\\s*$"; - tok("HYPHENRANGELOOSE"); - src[t.HYPHENRANGELOOSE] = "^\\s*(" + src[t.XRANGEPLAINLOOSE] + ")\\s+-\\s+(" + src[t.XRANGEPLAINLOOSE] + ")\\s*$"; - tok("STAR"); - src[t.STAR] = "(<|>)?=?\\s*\\*"; - for (i = 0; i < R; i++) { - debug(i, src[i]); - if (!re[i]) { - re[i] = new RegExp(src[i]); - } - } - var i; - exports.parse = parse2; - function parse2(version2, options) { - if (!options || typeof options !== "object") { - options = { - loose: !!options, - includePrerelease: false - }; - } - if (version2 instanceof SemVer) { - return version2; - } - if (typeof version2 !== "string") { - return null; - } - if (version2.length > MAX_LENGTH) { - return null; - } - var r = options.loose ? re[t.LOOSE] : re[t.FULL]; - if (!r.test(version2)) { - return null; - } - try { - return new SemVer(version2, options); - } catch (er) { - return null; - } - } - exports.valid = valid; - function valid(version2, options) { - var v = parse2(version2, options); - return v ? v.version : null; - } - exports.clean = clean; - function clean(version2, options) { - var s = parse2(version2.trim().replace(/^[=v]+/, ""), options); - return s ? s.version : null; - } - exports.SemVer = SemVer; - function SemVer(version2, options) { - if (!options || typeof options !== "object") { - options = { - loose: !!options, - includePrerelease: false - }; - } - if (version2 instanceof SemVer) { - if (version2.loose === options.loose) { - return version2; - } else { - version2 = version2.version; - } - } else if (typeof version2 !== "string") { - throw new TypeError("Invalid Version: " + version2); - } - if (version2.length > MAX_LENGTH) { - throw new TypeError("version is longer than " + MAX_LENGTH + " characters"); - } - if (!(this instanceof SemVer)) { - return new SemVer(version2, options); - } - debug("SemVer", version2, options); - this.options = options; - this.loose = !!options.loose; - var m = version2.trim().match(options.loose ? re[t.LOOSE] : re[t.FULL]); - if (!m) { - throw new TypeError("Invalid Version: " + version2); - } - this.raw = version2; - this.major = +m[1]; - this.minor = +m[2]; - this.patch = +m[3]; - if (this.major > MAX_SAFE_INTEGER || this.major < 0) { - throw new TypeError("Invalid major version"); - } - if (this.minor > MAX_SAFE_INTEGER || this.minor < 0) { - throw new TypeError("Invalid minor version"); - } - if (this.patch > MAX_SAFE_INTEGER || this.patch < 0) { - throw new TypeError("Invalid patch version"); - } - if (!m[4]) { - this.prerelease = []; - } else { - this.prerelease = m[4].split(".").map(function(id) { - if (/^[0-9]+$/.test(id)) { - var num = +id; - if (num >= 0 && num < MAX_SAFE_INTEGER) { - return num; - } - } - return id; - }); - } - this.build = m[5] ? m[5].split(".") : []; - this.format(); - } - SemVer.prototype.format = function() { - this.version = this.major + "." + this.minor + "." + this.patch; - if (this.prerelease.length) { - this.version += "-" + this.prerelease.join("."); - } - return this.version; - }; - SemVer.prototype.toString = function() { - return this.version; - }; - SemVer.prototype.compare = function(other) { - debug("SemVer.compare", this.version, this.options, other); - if (!(other instanceof SemVer)) { - other = new SemVer(other, this.options); - } - return this.compareMain(other) || this.comparePre(other); - }; - SemVer.prototype.compareMain = function(other) { - if (!(other instanceof SemVer)) { - other = new SemVer(other, this.options); - } - return compareIdentifiers(this.major, other.major) || compareIdentifiers(this.minor, other.minor) || compareIdentifiers(this.patch, other.patch); - }; - SemVer.prototype.comparePre = function(other) { - if (!(other instanceof SemVer)) { - other = new SemVer(other, this.options); - } - if (this.prerelease.length && !other.prerelease.length) { - return -1; - } else if (!this.prerelease.length && other.prerelease.length) { - return 1; - } else if (!this.prerelease.length && !other.prerelease.length) { - return 0; - } - var i2 = 0; - do { - var a = this.prerelease[i2]; - var b = other.prerelease[i2]; - debug("prerelease compare", i2, a, b); - if (a === void 0 && b === void 0) { - return 0; - } else if (b === void 0) { - return 1; - } else if (a === void 0) { - return -1; - } else if (a === b) { - continue; - } else { - return compareIdentifiers(a, b); - } - } while (++i2); - }; - SemVer.prototype.compareBuild = function(other) { - if (!(other instanceof SemVer)) { - other = new SemVer(other, this.options); - } - var i2 = 0; - do { - var a = this.build[i2]; - var b = other.build[i2]; - debug("prerelease compare", i2, a, b); - if (a === void 0 && b === void 0) { - return 0; - } else if (b === void 0) { - return 1; - } else if (a === void 0) { - return -1; - } else if (a === b) { - continue; - } else { - return compareIdentifiers(a, b); - } - } while (++i2); - }; - SemVer.prototype.inc = function(release, identifier) { - switch (release) { - case "premajor": - this.prerelease.length = 0; - this.patch = 0; - this.minor = 0; - this.major++; - this.inc("pre", identifier); - break; - case "preminor": - this.prerelease.length = 0; - this.patch = 0; - this.minor++; - this.inc("pre", identifier); - break; - case "prepatch": - this.prerelease.length = 0; - this.inc("patch", identifier); - this.inc("pre", identifier); - break; - case "prerelease": - if (this.prerelease.length === 0) { - this.inc("patch", identifier); - } - this.inc("pre", identifier); - break; - case "major": - if (this.minor !== 0 || this.patch !== 0 || this.prerelease.length === 0) { - this.major++; - } - this.minor = 0; - this.patch = 0; - this.prerelease = []; - break; - case "minor": - if (this.patch !== 0 || this.prerelease.length === 0) { - this.minor++; - } - this.patch = 0; - this.prerelease = []; - break; - case "patch": - if (this.prerelease.length === 0) { - this.patch++; - } - this.prerelease = []; - break; - case "pre": - if (this.prerelease.length === 0) { - this.prerelease = [0]; - } else { - var i2 = this.prerelease.length; - while (--i2 >= 0) { - if (typeof this.prerelease[i2] === "number") { - this.prerelease[i2]++; - i2 = -2; - } - } - if (i2 === -1) { - this.prerelease.push(0); - } - } - if (identifier) { - if (this.prerelease[0] === identifier) { - if (isNaN(this.prerelease[1])) { - this.prerelease = [identifier, 0]; - } - } else { - this.prerelease = [identifier, 0]; - } - } - break; - default: - throw new Error("invalid increment argument: " + release); - } - this.format(); - this.raw = this.version; - return this; - }; - exports.inc = inc; - function inc(version2, release, loose, identifier) { - if (typeof loose === "string") { - identifier = loose; - loose = void 0; - } - try { - return new SemVer(version2, loose).inc(release, identifier).version; - } catch (er) { - return null; - } - } - exports.diff = diff; - function diff(version1, version2) { - if (eq(version1, version2)) { - return null; - } else { - var v12 = parse2(version1); - var v2 = parse2(version2); - var prefix = ""; - if (v12.prerelease.length || v2.prerelease.length) { - prefix = "pre"; - var defaultResult = "prerelease"; - } - for (var key in v12) { - if (key === "major" || key === "minor" || key === "patch") { - if (v12[key] !== v2[key]) { - return prefix + key; - } - } - } - return defaultResult; - } - } - exports.compareIdentifiers = compareIdentifiers; - var numeric = /^[0-9]+$/; - function compareIdentifiers(a, b) { - var anum = numeric.test(a); - var bnum = numeric.test(b); - if (anum && bnum) { - a = +a; - b = +b; - } - return a === b ? 0 : anum && !bnum ? -1 : bnum && !anum ? 1 : a < b ? -1 : 1; - } - exports.rcompareIdentifiers = rcompareIdentifiers; - function rcompareIdentifiers(a, b) { - return compareIdentifiers(b, a); - } - exports.major = major; - function major(a, loose) { - return new SemVer(a, loose).major; - } - exports.minor = minor; - function minor(a, loose) { - return new SemVer(a, loose).minor; - } - exports.patch = patch; - function patch(a, loose) { - return new SemVer(a, loose).patch; - } - exports.compare = compare; - function compare(a, b, loose) { - return new SemVer(a, loose).compare(new SemVer(b, loose)); - } - exports.compareLoose = compareLoose; - function compareLoose(a, b) { - return compare(a, b, true); - } - exports.compareBuild = compareBuild; - function compareBuild(a, b, loose) { - var versionA = new SemVer(a, loose); - var versionB = new SemVer(b, loose); - return versionA.compare(versionB) || versionA.compareBuild(versionB); - } - exports.rcompare = rcompare; - function rcompare(a, b, loose) { - return compare(b, a, loose); - } - exports.sort = sort; - function sort(list, loose) { - return list.sort(function(a, b) { - return exports.compareBuild(a, b, loose); - }); - } - exports.rsort = rsort; - function rsort(list, loose) { - return list.sort(function(a, b) { - return exports.compareBuild(b, a, loose); - }); - } - exports.gt = gt; - function gt(a, b, loose) { - return compare(a, b, loose) > 0; - } - exports.lt = lt; - function lt(a, b, loose) { - return compare(a, b, loose) < 0; - } - exports.eq = eq; - function eq(a, b, loose) { - return compare(a, b, loose) === 0; - } - exports.neq = neq; - function neq(a, b, loose) { - return compare(a, b, loose) !== 0; - } - exports.gte = gte; - function gte(a, b, loose) { - return compare(a, b, loose) >= 0; - } - exports.lte = lte; - function lte(a, b, loose) { - return compare(a, b, loose) <= 0; - } - exports.cmp = cmp; - function cmp(a, op, b, loose) { - switch (op) { - case "===": - if (typeof a === "object") - a = a.version; - if (typeof b === "object") - b = b.version; - return a === b; - case "!==": - if (typeof a === "object") - a = a.version; - if (typeof b === "object") - b = b.version; - return a !== b; - case "": - case "=": - case "==": - return eq(a, b, loose); - case "!=": - return neq(a, b, loose); - case ">": - return gt(a, b, loose); - case ">=": - return gte(a, b, loose); - case "<": - return lt(a, b, loose); - case "<=": - return lte(a, b, loose); - default: - throw new TypeError("Invalid operator: " + op); - } - } - exports.Comparator = Comparator; - function Comparator(comp, options) { - if (!options || typeof options !== "object") { - options = { - loose: !!options, - includePrerelease: false - }; - } - if (comp instanceof Comparator) { - if (comp.loose === !!options.loose) { - return comp; - } else { - comp = comp.value; - } - } - if (!(this instanceof Comparator)) { - return new Comparator(comp, options); - } - debug("comparator", comp, options); - this.options = options; - this.loose = !!options.loose; - this.parse(comp); - if (this.semver === ANY) { - this.value = ""; - } else { - this.value = this.operator + this.semver.version; - } - debug("comp", this); - } - var ANY = {}; - Comparator.prototype.parse = function(comp) { - var r = this.options.loose ? re[t.COMPARATORLOOSE] : re[t.COMPARATOR]; - var m = comp.match(r); - if (!m) { - throw new TypeError("Invalid comparator: " + comp); - } - this.operator = m[1] !== void 0 ? m[1] : ""; - if (this.operator === "=") { - this.operator = ""; - } - if (!m[2]) { - this.semver = ANY; - } else { - this.semver = new SemVer(m[2], this.options.loose); - } - }; - Comparator.prototype.toString = function() { - return this.value; - }; - Comparator.prototype.test = function(version2) { - debug("Comparator.test", version2, this.options.loose); - if (this.semver === ANY || version2 === ANY) { - return true; - } - if (typeof version2 === "string") { - try { - version2 = new SemVer(version2, this.options); - } catch (er) { - return false; - } - } - return cmp(version2, this.operator, this.semver, this.options); - }; - Comparator.prototype.intersects = function(comp, options) { - if (!(comp instanceof Comparator)) { - throw new TypeError("a Comparator is required"); - } - if (!options || typeof options !== "object") { - options = { - loose: !!options, - includePrerelease: false - }; - } - var rangeTmp; - if (this.operator === "") { - if (this.value === "") { - return true; - } - rangeTmp = new Range(comp.value, options); - return satisfies(this.value, rangeTmp, options); - } else if (comp.operator === "") { - if (comp.value === "") { - return true; - } - rangeTmp = new Range(this.value, options); - return satisfies(comp.semver, rangeTmp, options); - } - var sameDirectionIncreasing = (this.operator === ">=" || this.operator === ">") && (comp.operator === ">=" || comp.operator === ">"); - var sameDirectionDecreasing = (this.operator === "<=" || this.operator === "<") && (comp.operator === "<=" || comp.operator === "<"); - var sameSemVer = this.semver.version === comp.semver.version; - var differentDirectionsInclusive = (this.operator === ">=" || this.operator === "<=") && (comp.operator === ">=" || comp.operator === "<="); - var oppositeDirectionsLessThan = cmp(this.semver, "<", comp.semver, options) && ((this.operator === ">=" || this.operator === ">") && (comp.operator === "<=" || comp.operator === "<")); - var oppositeDirectionsGreaterThan = cmp(this.semver, ">", comp.semver, options) && ((this.operator === "<=" || this.operator === "<") && (comp.operator === ">=" || comp.operator === ">")); - return sameDirectionIncreasing || sameDirectionDecreasing || sameSemVer && differentDirectionsInclusive || oppositeDirectionsLessThan || oppositeDirectionsGreaterThan; - }; - exports.Range = Range; - function Range(range, options) { - if (!options || typeof options !== "object") { - options = { - loose: !!options, - includePrerelease: false - }; - } - if (range instanceof Range) { - if (range.loose === !!options.loose && range.includePrerelease === !!options.includePrerelease) { - return range; - } else { - return new Range(range.raw, options); - } - } - if (range instanceof Comparator) { - return new Range(range.value, options); - } - if (!(this instanceof Range)) { - return new Range(range, options); - } - this.options = options; - this.loose = !!options.loose; - this.includePrerelease = !!options.includePrerelease; - this.raw = range; - this.set = range.split(/\s*\|\|\s*/).map(function(range2) { - return this.parseRange(range2.trim()); - }, this).filter(function(c) { - return c.length; - }); - if (!this.set.length) { - throw new TypeError("Invalid SemVer Range: " + range); - } - this.format(); - } - Range.prototype.format = function() { - this.range = this.set.map(function(comps) { - return comps.join(" ").trim(); - }).join("||").trim(); - return this.range; - }; - Range.prototype.toString = function() { - return this.range; - }; - Range.prototype.parseRange = function(range) { - var loose = this.options.loose; - range = range.trim(); - var hr = loose ? re[t.HYPHENRANGELOOSE] : re[t.HYPHENRANGE]; - range = range.replace(hr, hyphenReplace); - debug("hyphen replace", range); - range = range.replace(re[t.COMPARATORTRIM], comparatorTrimReplace); - debug("comparator trim", range, re[t.COMPARATORTRIM]); - range = range.replace(re[t.TILDETRIM], tildeTrimReplace); - range = range.replace(re[t.CARETTRIM], caretTrimReplace); - range = range.split(/\s+/).join(" "); - var compRe = loose ? re[t.COMPARATORLOOSE] : re[t.COMPARATOR]; - var set = range.split(" ").map(function(comp) { - return parseComparator(comp, this.options); - }, this).join(" ").split(/\s+/); - if (this.options.loose) { - set = set.filter(function(comp) { - return !!comp.match(compRe); - }); - } - set = set.map(function(comp) { - return new Comparator(comp, this.options); - }, this); - return set; - }; - Range.prototype.intersects = function(range, options) { - if (!(range instanceof Range)) { - throw new TypeError("a Range is required"); - } - return this.set.some(function(thisComparators) { - return isSatisfiable(thisComparators, options) && range.set.some(function(rangeComparators) { - return isSatisfiable(rangeComparators, options) && thisComparators.every(function(thisComparator) { - return rangeComparators.every(function(rangeComparator) { - return thisComparator.intersects(rangeComparator, options); - }); - }); - }); - }); - }; - function isSatisfiable(comparators, options) { - var result = true; - var remainingComparators = comparators.slice(); - var testComparator = remainingComparators.pop(); - while (result && remainingComparators.length) { - result = remainingComparators.every(function(otherComparator) { - return testComparator.intersects(otherComparator, options); - }); - testComparator = remainingComparators.pop(); - } - return result; - } - exports.toComparators = toComparators; - function toComparators(range, options) { - return new Range(range, options).set.map(function(comp) { - return comp.map(function(c) { - return c.value; - }).join(" ").trim().split(" "); - }); - } - function parseComparator(comp, options) { - debug("comp", comp, options); - comp = replaceCarets(comp, options); - debug("caret", comp); - comp = replaceTildes(comp, options); - debug("tildes", comp); - comp = replaceXRanges(comp, options); - debug("xrange", comp); - comp = replaceStars(comp, options); - debug("stars", comp); - return comp; - } - function isX(id) { - return !id || id.toLowerCase() === "x" || id === "*"; - } - function replaceTildes(comp, options) { - return comp.trim().split(/\s+/).map(function(comp2) { - return replaceTilde(comp2, options); - }).join(" "); - } - function replaceTilde(comp, options) { - var r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE]; - return comp.replace(r, function(_, M, m, p, pr) { - debug("tilde", comp, _, M, m, p, pr); - var ret; - if (isX(M)) { - ret = ""; - } else if (isX(m)) { - ret = ">=" + M + ".0.0 <" + (+M + 1) + ".0.0"; - } else if (isX(p)) { - ret = ">=" + M + "." + m + ".0 <" + M + "." + (+m + 1) + ".0"; - } else if (pr) { - debug("replaceTilde pr", pr); - ret = ">=" + M + "." + m + "." + p + "-" + pr + " <" + M + "." + (+m + 1) + ".0"; - } else { - ret = ">=" + M + "." + m + "." + p + " <" + M + "." + (+m + 1) + ".0"; - } - debug("tilde return", ret); - return ret; - }); - } - function replaceCarets(comp, options) { - return comp.trim().split(/\s+/).map(function(comp2) { - return replaceCaret(comp2, options); - }).join(" "); - } - function replaceCaret(comp, options) { - debug("caret", comp, options); - var r = options.loose ? re[t.CARETLOOSE] : re[t.CARET]; - return comp.replace(r, function(_, M, m, p, pr) { - debug("caret", comp, _, M, m, p, pr); - var ret; - if (isX(M)) { - ret = ""; - } else if (isX(m)) { - ret = ">=" + M + ".0.0 <" + (+M + 1) + ".0.0"; - } else if (isX(p)) { - if (M === "0") { - ret = ">=" + M + "." + m + ".0 <" + M + "." + (+m + 1) + ".0"; - } else { - ret = ">=" + M + "." + m + ".0 <" + (+M + 1) + ".0.0"; - } - } else if (pr) { - debug("replaceCaret pr", pr); - if (M === "0") { - if (m === "0") { - ret = ">=" + M + "." + m + "." + p + "-" + pr + " <" + M + "." + m + "." + (+p + 1); - } else { - ret = ">=" + M + "." + m + "." + p + "-" + pr + " <" + M + "." + (+m + 1) + ".0"; - } - } else { - ret = ">=" + M + "." + m + "." + p + "-" + pr + " <" + (+M + 1) + ".0.0"; - } - } else { - debug("no pr"); - if (M === "0") { - if (m === "0") { - ret = ">=" + M + "." + m + "." + p + " <" + M + "." + m + "." + (+p + 1); - } else { - ret = ">=" + M + "." + m + "." + p + " <" + M + "." + (+m + 1) + ".0"; - } - } else { - ret = ">=" + M + "." + m + "." + p + " <" + (+M + 1) + ".0.0"; - } - } - debug("caret return", ret); - return ret; - }); - } - function replaceXRanges(comp, options) { - debug("replaceXRanges", comp, options); - return comp.split(/\s+/).map(function(comp2) { - return replaceXRange(comp2, options); - }).join(" "); - } - function replaceXRange(comp, options) { - comp = comp.trim(); - var r = options.loose ? re[t.XRANGELOOSE] : re[t.XRANGE]; - return comp.replace(r, function(ret, gtlt, M, m, p, pr) { - debug("xRange", comp, ret, gtlt, M, m, p, pr); - var xM = isX(M); - var xm = xM || isX(m); - var xp = xm || isX(p); - var anyX = xp; - if (gtlt === "=" && anyX) { - gtlt = ""; - } - pr = options.includePrerelease ? "-0" : ""; - if (xM) { - if (gtlt === ">" || gtlt === "<") { - ret = "<0.0.0-0"; - } else { - ret = "*"; - } - } else if (gtlt && anyX) { - if (xm) { - m = 0; - } - p = 0; - if (gtlt === ">") { - gtlt = ">="; - if (xm) { - M = +M + 1; - m = 0; - p = 0; - } else { - m = +m + 1; - p = 0; - } - } else if (gtlt === "<=") { - gtlt = "<"; - if (xm) { - M = +M + 1; - } else { - m = +m + 1; - } - } - ret = gtlt + M + "." + m + "." + p + pr; - } else if (xm) { - ret = ">=" + M + ".0.0" + pr + " <" + (+M + 1) + ".0.0" + pr; - } else if (xp) { - ret = ">=" + M + "." + m + ".0" + pr + " <" + M + "." + (+m + 1) + ".0" + pr; - } - debug("xRange return", ret); - return ret; - }); - } - function replaceStars(comp, options) { - debug("replaceStars", comp, options); - return comp.trim().replace(re[t.STAR], ""); - } - function hyphenReplace($0, from, fM, fm, fp, fpr, fb, to, tM, tm, tp, tpr, tb) { - if (isX(fM)) { - from = ""; - } else if (isX(fm)) { - from = ">=" + fM + ".0.0"; - } else if (isX(fp)) { - from = ">=" + fM + "." + fm + ".0"; - } else { - from = ">=" + from; - } - if (isX(tM)) { - to = ""; - } else if (isX(tm)) { - to = "<" + (+tM + 1) + ".0.0"; - } else if (isX(tp)) { - to = "<" + tM + "." + (+tm + 1) + ".0"; - } else if (tpr) { - to = "<=" + tM + "." + tm + "." + tp + "-" + tpr; - } else { - to = "<=" + to; - } - return (from + " " + to).trim(); - } - Range.prototype.test = function(version2) { - if (!version2) { - return false; - } - if (typeof version2 === "string") { - try { - version2 = new SemVer(version2, this.options); - } catch (er) { - return false; - } - } - for (var i2 = 0; i2 < this.set.length; i2++) { - if (testSet(this.set[i2], version2, this.options)) { - return true; - } - } - return false; - }; - function testSet(set, version2, options) { - for (var i2 = 0; i2 < set.length; i2++) { - if (!set[i2].test(version2)) { - return false; - } - } - if (version2.prerelease.length && !options.includePrerelease) { - for (i2 = 0; i2 < set.length; i2++) { - debug(set[i2].semver); - if (set[i2].semver === ANY) { - continue; - } - if (set[i2].semver.prerelease.length > 0) { - var allowed = set[i2].semver; - if (allowed.major === version2.major && allowed.minor === version2.minor && allowed.patch === version2.patch) { - return true; - } - } - } - return false; - } - return true; - } - exports.satisfies = satisfies; - function satisfies(version2, range, options) { - try { - range = new Range(range, options); - } catch (er) { - return false; - } - return range.test(version2); - } - exports.maxSatisfying = maxSatisfying; - function maxSatisfying(versions, range, options) { - var max = null; - var maxSV = null; - try { - var rangeObj = new Range(range, options); - } catch (er) { - return null; - } - versions.forEach(function(v) { - if (rangeObj.test(v)) { - if (!max || maxSV.compare(v) === -1) { - max = v; - maxSV = new SemVer(max, options); - } - } - }); - return max; - } - exports.minSatisfying = minSatisfying; - function minSatisfying(versions, range, options) { - var min = null; - var minSV = null; - try { - var rangeObj = new Range(range, options); - } catch (er) { - return null; - } - versions.forEach(function(v) { - if (rangeObj.test(v)) { - if (!min || minSV.compare(v) === 1) { - min = v; - minSV = new SemVer(min, options); - } - } - }); - return min; - } - exports.minVersion = minVersion; - function minVersion(range, loose) { - range = new Range(range, loose); - var minver = new SemVer("0.0.0"); - if (range.test(minver)) { - return minver; - } - minver = new SemVer("0.0.0-0"); - if (range.test(minver)) { - return minver; - } - minver = null; - for (var i2 = 0; i2 < range.set.length; ++i2) { - var comparators = range.set[i2]; - comparators.forEach(function(comparator) { - var compver = new SemVer(comparator.semver.version); - switch (comparator.operator) { - case ">": - if (compver.prerelease.length === 0) { - compver.patch++; - } else { - compver.prerelease.push(0); - } - compver.raw = compver.format(); - case "": - case ">=": - if (!minver || gt(minver, compver)) { - minver = compver; - } - break; - case "<": - case "<=": - break; - default: - throw new Error("Unexpected operation: " + comparator.operator); - } - }); - } - if (minver && range.test(minver)) { - return minver; - } - return null; - } - exports.validRange = validRange; - function validRange(range, options) { - try { - return new Range(range, options).range || "*"; - } catch (er) { - return null; - } - } - exports.ltr = ltr; - function ltr(version2, range, options) { - return outside(version2, range, "<", options); - } - exports.gtr = gtr; - function gtr(version2, range, options) { - return outside(version2, range, ">", options); - } - exports.outside = outside; - function outside(version2, range, hilo, options) { - version2 = new SemVer(version2, options); - range = new Range(range, options); - var gtfn, ltefn, ltfn, comp, ecomp; - switch (hilo) { - case ">": - gtfn = gt; - ltefn = lte; - ltfn = lt; - comp = ">"; - ecomp = ">="; - break; - case "<": - gtfn = lt; - ltefn = gte; - ltfn = gt; - comp = "<"; - ecomp = "<="; - break; - default: - throw new TypeError('Must provide a hilo val of "<" or ">"'); - } - if (satisfies(version2, range, options)) { - return false; - } - for (var i2 = 0; i2 < range.set.length; ++i2) { - var comparators = range.set[i2]; - var high = null; - var low = null; - comparators.forEach(function(comparator) { - if (comparator.semver === ANY) { - comparator = new Comparator(">=0.0.0"); - } - high = high || comparator; - low = low || comparator; - if (gtfn(comparator.semver, high.semver, options)) { - high = comparator; - } else if (ltfn(comparator.semver, low.semver, options)) { - low = comparator; - } - }); - if (high.operator === comp || high.operator === ecomp) { - return false; - } - if ((!low.operator || low.operator === comp) && ltefn(version2, low.semver)) { - return false; - } else if (low.operator === ecomp && ltfn(version2, low.semver)) { - return false; - } - } - return true; - } - exports.prerelease = prerelease; - function prerelease(version2, options) { - var parsed = parse2(version2, options); - return parsed && parsed.prerelease.length ? parsed.prerelease : null; - } - exports.intersects = intersects; - function intersects(r1, r2, options) { - r1 = new Range(r1, options); - r2 = new Range(r2, options); - return r1.intersects(r2); - } - exports.coerce = coerce; - function coerce(version2, options) { - if (version2 instanceof SemVer) { - return version2; - } - if (typeof version2 === "number") { - version2 = String(version2); - } - if (typeof version2 !== "string") { - return null; - } - options = options || {}; - var match = null; - if (!options.rtl) { - match = version2.match(re[t.COERCE]); - } else { - var next; - while ((next = re[t.COERCERTL].exec(version2)) && (!match || match.index + match[0].length !== version2.length)) { - if (!match || next.index + next[0].length !== match.index + match[0].length) { - match = next; - } - re[t.COERCERTL].lastIndex = next.index + next[1].length + next[2].length; - } - re[t.COERCERTL].lastIndex = -1; - } - if (match === null) { - return null; - } - return parse2(match[2] + "." + (match[3] || "0") + "." + (match[4] || "0"), options); - } - } -}); - -// node_modules/@actions/tool-cache/lib/manifest.js -var require_manifest = __commonJS({ - "node_modules/@actions/tool-cache/lib/manifest.js"(exports, module2) { - "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { - if (k2 === void 0) - k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { - return m[k]; - } }); - } : function(o, m, k, k2) { - if (k2 === void 0) - k2 = k; - o[k2] = m[k]; - }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { - Object.defineProperty(o, "default", { enumerable: true, value: v }); - } : function(o, v) { - o["default"] = v; - }); - var __importStar = exports && exports.__importStar || function(mod) { - if (mod && mod.__esModule) - return mod; - var result = {}; - if (mod != null) { - for (var k in mod) - if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); - } - __setModuleDefault(result, mod); - return result; - }; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { - function adopt(value) { - return value instanceof P ? value : new P(function(resolve) { - resolve(value); - }); - } - return new (P || (P = Promise))(function(resolve, reject) { - function fulfilled(value) { - try { - step(generator.next(value)); - } catch (e) { - reject(e); - } - } - function rejected(value) { - try { - step(generator["throw"](value)); - } catch (e) { - reject(e); - } - } - function step(result) { - result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); - } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); - }; - Object.defineProperty(exports, "__esModule", { value: true }); - exports._readLinuxVersionFile = exports._getOsVersion = exports._findMatch = void 0; - var semver2 = __importStar(require_semver3()); - var core_1 = require_core(); - var os2 = require("os"); - var cp = require("child_process"); - var fs = require("fs"); - function _findMatch(versionSpec, stable, candidates, archFilter) { - return __awaiter(this, void 0, void 0, function* () { - const platFilter = os2.platform(); - let result; - let match; - let file; - for (const candidate of candidates) { - const version2 = candidate.version; - core_1.debug(`check ${version2} satisfies ${versionSpec}`); - if (semver2.satisfies(version2, versionSpec) && (!stable || candidate.stable === stable)) { - file = candidate.files.find((item) => { - core_1.debug(`${item.arch}===${archFilter} && ${item.platform}===${platFilter}`); - let chk = item.arch === archFilter && item.platform === platFilter; - if (chk && item.platform_version) { - const osVersion = module2.exports._getOsVersion(); - if (osVersion === item.platform_version) { - chk = true; - } else { - chk = semver2.satisfies(osVersion, item.platform_version); - } - } - return chk; - }); - if (file) { - core_1.debug(`matched ${candidate.version}`); - match = candidate; - break; - } - } - } - if (match && file) { - result = Object.assign({}, match); - result.files = [file]; - } - return result; - }); - } - exports._findMatch = _findMatch; - function _getOsVersion() { - const plat = os2.platform(); - let version2 = ""; - if (plat === "darwin") { - version2 = cp.execSync("sw_vers -productVersion").toString(); - } else if (plat === "linux") { - const lsbContents = module2.exports._readLinuxVersionFile(); - if (lsbContents) { - const lines = lsbContents.split("\n"); - for (const line of lines) { - const parts = line.split("="); - if (parts.length === 2 && (parts[0].trim() === "VERSION_ID" || parts[0].trim() === "DISTRIB_RELEASE")) { - version2 = parts[1].trim().replace(/^"/, "").replace(/"$/, ""); - break; - } - } - } - } - return version2; - } - exports._getOsVersion = _getOsVersion; - function _readLinuxVersionFile() { - const lsbReleaseFile = "/etc/lsb-release"; - const osReleaseFile = "/etc/os-release"; - let contents = ""; - if (fs.existsSync(lsbReleaseFile)) { - contents = fs.readFileSync(lsbReleaseFile).toString(); - } else if (fs.existsSync(osReleaseFile)) { - contents = fs.readFileSync(osReleaseFile).toString(); - } - return contents; - } - exports._readLinuxVersionFile = _readLinuxVersionFile; - } -}); - -// node_modules/@actions/tool-cache/node_modules/uuid/lib/rng.js -var require_rng = __commonJS({ - "node_modules/@actions/tool-cache/node_modules/uuid/lib/rng.js"(exports, module2) { - var crypto4 = require("crypto"); - module2.exports = function nodeRNG() { - return crypto4.randomBytes(16); - }; - } -}); - -// node_modules/@actions/tool-cache/node_modules/uuid/lib/bytesToUuid.js -var require_bytesToUuid = __commonJS({ - "node_modules/@actions/tool-cache/node_modules/uuid/lib/bytesToUuid.js"(exports, module2) { - var byteToHex2 = []; - for (i = 0; i < 256; ++i) { - byteToHex2[i] = (i + 256).toString(16).substr(1); - } - var i; - function bytesToUuid(buf, offset) { - var i2 = offset || 0; - var bth = byteToHex2; - return [ - bth[buf[i2++]], - bth[buf[i2++]], - bth[buf[i2++]], - bth[buf[i2++]], - "-", - bth[buf[i2++]], - bth[buf[i2++]], - "-", - bth[buf[i2++]], - bth[buf[i2++]], - "-", - bth[buf[i2++]], - bth[buf[i2++]], - "-", - bth[buf[i2++]], - bth[buf[i2++]], - bth[buf[i2++]], - bth[buf[i2++]], - bth[buf[i2++]], - bth[buf[i2++]] - ].join(""); - } - module2.exports = bytesToUuid; - } -}); - -// node_modules/@actions/tool-cache/node_modules/uuid/v4.js -var require_v4 = __commonJS({ - "node_modules/@actions/tool-cache/node_modules/uuid/v4.js"(exports, module2) { - var rng2 = require_rng(); - var bytesToUuid = require_bytesToUuid(); - function v42(options, buf, offset) { - var i = buf && offset || 0; - if (typeof options == "string") { - buf = options === "binary" ? new Array(16) : null; - options = null; - } - options = options || {}; - var rnds = options.random || (options.rng || rng2)(); - rnds[6] = rnds[6] & 15 | 64; - rnds[8] = rnds[8] & 63 | 128; - if (buf) { - for (var ii = 0; ii < 16; ++ii) { - buf[i + ii] = rnds[ii]; - } - } - return buf || bytesToUuid(rnds); - } - module2.exports = v42; + __name(copyFile, "copyFile"); } }); @@ -6393,7 +5214,7 @@ var require_v4 = __commonJS({ var require_toolrunner = __commonJS({ "node_modules/@actions/exec/lib/toolrunner.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -6404,29 +5225,30 @@ var require_toolrunner = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -6435,6 +5257,7 @@ var require_toolrunner = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -6442,23 +5265,25 @@ var require_toolrunner = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.argStringToArray = exports.ToolRunner = void 0; - var os2 = __importStar(require("os")); - var events = __importStar(require("events")); - var child = __importStar(require("child_process")); - var path2 = __importStar(require("path")); - var io = __importStar(require_io()); - var ioUtil = __importStar(require_io_util()); + var os2 = __importStar2(require("os")); + var events = __importStar2(require("events")); + var child = __importStar2(require("child_process")); + var path2 = __importStar2(require("path")); + var io = __importStar2(require_io()); + var ioUtil = __importStar2(require_io_util()); var timers_1 = require("timers"); var IS_WINDOWS = process.platform === "win32"; - var ToolRunner = class extends events.EventEmitter { + var _ToolRunner = class _ToolRunner extends events.EventEmitter { constructor(toolPath, args, options) { super(); if (!toolPath) { @@ -6666,12 +5491,12 @@ var require_toolrunner = __commonJS({ * @returns number */ exec() { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { if (!ioUtil.isRooted(this.toolPath) && (this.toolPath.includes("/") || IS_WINDOWS && this.toolPath.includes("\\"))) { this.toolPath = path2.resolve(process.cwd(), this.options.cwd || process.cwd(), this.toolPath); } this.toolPath = yield io.which(this.toolPath, true); - return new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () { + return new Promise((resolve, reject) => __awaiter2(this, void 0, void 0, function* () { this._debug(`exec tool: ${this.toolPath}`); this._debug("arguments:"); for (const arg of this.args) { @@ -6767,6 +5592,8 @@ var require_toolrunner = __commonJS({ }); } }; + __name(_ToolRunner, "ToolRunner"); + var ToolRunner = _ToolRunner; exports.ToolRunner = ToolRunner; function argStringToArray(argString) { const args = []; @@ -6780,6 +5607,7 @@ var require_toolrunner = __commonJS({ arg += c; escaped = false; } + __name(append, "append"); for (let i = 0; i < argString.length; i++) { const c = argString.charAt(i); if (c === '"') { @@ -6812,8 +5640,9 @@ var require_toolrunner = __commonJS({ } return args; } + __name(argStringToArray, "argStringToArray"); exports.argStringToArray = argStringToArray; - var ExecState = class extends events.EventEmitter { + var _ExecState = class _ExecState extends events.EventEmitter { constructor(options, toolPath) { super(); this.processClosed = false; @@ -6840,7 +5669,7 @@ var require_toolrunner = __commonJS({ if (this.processClosed) { this._setResult(); } else if (this.processExited) { - this.timeout = timers_1.setTimeout(ExecState.HandleTimeout, this.delay, this); + this.timeout = timers_1.setTimeout(_ExecState.HandleTimeout, this.delay, this); } } _debug(message) { @@ -6875,6 +5704,8 @@ var require_toolrunner = __commonJS({ state._setResult(); } }; + __name(_ExecState, "ExecState"); + var ExecState = _ExecState; } }); @@ -6882,7 +5713,7 @@ var require_toolrunner = __commonJS({ var require_exec = __commonJS({ "node_modules/@actions/exec/lib/exec.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -6893,29 +5724,30 @@ var require_exec = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -6924,6 +5756,7 @@ var require_exec = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -6931,18 +5764,20 @@ var require_exec = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.getExecOutput = exports.exec = void 0; var string_decoder_1 = require("string_decoder"); - var tr = __importStar(require_toolrunner()); + var tr = __importStar2(require_toolrunner()); function exec(commandLine, args, options) { - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { const commandArgs = tr.argStringToArray(commandLine); if (commandArgs.length === 0) { throw new Error(`Parameter 'commandLine' cannot be null or empty.`); @@ -6953,28 +5788,29 @@ var require_exec = __commonJS({ return runner.exec(); }); } + __name(exec, "exec"); exports.exec = exec; function getExecOutput(commandLine, args, options) { var _a, _b; - return __awaiter(this, void 0, void 0, function* () { + return __awaiter2(this, void 0, void 0, function* () { let stdout = ""; let stderr = ""; const stdoutDecoder = new string_decoder_1.StringDecoder("utf8"); const stderrDecoder = new string_decoder_1.StringDecoder("utf8"); const originalStdoutListener = (_a = options === null || options === void 0 ? void 0 : options.listeners) === null || _a === void 0 ? void 0 : _a.stdout; const originalStdErrListener = (_b = options === null || options === void 0 ? void 0 : options.listeners) === null || _b === void 0 ? void 0 : _b.stderr; - const stdErrListener = (data) => { + const stdErrListener = /* @__PURE__ */ __name((data) => { stderr += stderrDecoder.write(data); if (originalStdErrListener) { originalStdErrListener(data); } - }; - const stdOutListener = (data) => { + }, "stdErrListener"); + const stdOutListener = /* @__PURE__ */ __name((data) => { stdout += stdoutDecoder.write(data); if (originalStdoutListener) { originalStdoutListener(data); } - }; + }, "stdOutListener"); const listeners = Object.assign(Object.assign({}, options === null || options === void 0 ? void 0 : options.listeners), { stdout: stdOutListener, stderr: stdErrListener }); const exitCode = yield exec(commandLine, args, Object.assign(Object.assign({}, options), { listeners })); stdout += stdoutDecoder.end(); @@ -6986,15 +5822,16 @@ var require_exec = __commonJS({ }; }); } + __name(getExecOutput, "getExecOutput"); exports.getExecOutput = getExecOutput; } }); -// node_modules/@actions/tool-cache/lib/retry-helper.js -var require_retry_helper = __commonJS({ - "node_modules/@actions/tool-cache/lib/retry-helper.js"(exports) { +// node_modules/@actions/glob/lib/internal-glob-options-helper.js +var require_internal_glob_options_helper = __commonJS({ + "node_modules/@actions/glob/lib/internal-glob-options-helper.js"(exports) { "use strict"; - var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { if (k2 === void 0) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { @@ -7005,29 +5842,1512 @@ var require_retry_helper = __commonJS({ k2 = k; o[k2] = m[k]; }); - var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); } : function(o, v) { o["default"] = v; }); - var __importStar = exports && exports.__importStar || function(mod) { + var __importStar2 = exports && exports.__importStar || function(mod) { if (mod && mod.__esModule) return mod; var result = {}; if (mod != null) { for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) - __createBinding(result, mod, k); + __createBinding2(result, mod, k); } - __setModuleDefault(result, mod); + __setModuleDefault2(result, mod); return result; }; - var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + Object.defineProperty(exports, "__esModule", { value: true }); + exports.getOptions = void 0; + var core = __importStar2(require_core()); + function getOptions(copy) { + const result = { + followSymbolicLinks: true, + implicitDescendants: true, + omitBrokenSymbolicLinks: true + }; + if (copy) { + if (typeof copy.followSymbolicLinks === "boolean") { + result.followSymbolicLinks = copy.followSymbolicLinks; + core.debug(`followSymbolicLinks '${result.followSymbolicLinks}'`); + } + if (typeof copy.implicitDescendants === "boolean") { + result.implicitDescendants = copy.implicitDescendants; + core.debug(`implicitDescendants '${result.implicitDescendants}'`); + } + if (typeof copy.omitBrokenSymbolicLinks === "boolean") { + result.omitBrokenSymbolicLinks = copy.omitBrokenSymbolicLinks; + core.debug(`omitBrokenSymbolicLinks '${result.omitBrokenSymbolicLinks}'`); + } + } + return result; + } + __name(getOptions, "getOptions"); + exports.getOptions = getOptions; + } +}); + +// node_modules/@actions/glob/lib/internal-path-helper.js +var require_internal_path_helper = __commonJS({ + "node_modules/@actions/glob/lib/internal-path-helper.js"(exports) { + "use strict"; + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { + return m[k]; + } }); + } : function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + o[k2] = m[k]; + }); + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); + } : function(o, v) { + o["default"] = v; + }); + var __importStar2 = exports && exports.__importStar || function(mod) { + if (mod && mod.__esModule) + return mod; + var result = {}; + if (mod != null) { + for (var k in mod) + if (k !== "default" && Object.hasOwnProperty.call(mod, k)) + __createBinding2(result, mod, k); + } + __setModuleDefault2(result, mod); + return result; + }; + var __importDefault2 = exports && exports.__importDefault || function(mod) { + return mod && mod.__esModule ? mod : { "default": mod }; + }; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.safeTrimTrailingSeparator = exports.normalizeSeparators = exports.hasRoot = exports.hasAbsoluteRoot = exports.ensureAbsoluteRoot = exports.dirname = void 0; + var path2 = __importStar2(require("path")); + var assert_1 = __importDefault2(require("assert")); + var IS_WINDOWS = process.platform === "win32"; + function dirname(p) { + p = safeTrimTrailingSeparator(p); + if (IS_WINDOWS && /^\\\\[^\\]+(\\[^\\]+)?$/.test(p)) { + return p; + } + let result = path2.dirname(p); + if (IS_WINDOWS && /^\\\\[^\\]+\\[^\\]+\\$/.test(result)) { + result = safeTrimTrailingSeparator(result); + } + return result; + } + __name(dirname, "dirname"); + exports.dirname = dirname; + function ensureAbsoluteRoot(root, itemPath) { + assert_1.default(root, `ensureAbsoluteRoot parameter 'root' must not be empty`); + assert_1.default(itemPath, `ensureAbsoluteRoot parameter 'itemPath' must not be empty`); + if (hasAbsoluteRoot(itemPath)) { + return itemPath; + } + if (IS_WINDOWS) { + if (itemPath.match(/^[A-Z]:[^\\/]|^[A-Z]:$/i)) { + let cwd = process.cwd(); + assert_1.default(cwd.match(/^[A-Z]:\\/i), `Expected current directory to start with an absolute drive root. Actual '${cwd}'`); + if (itemPath[0].toUpperCase() === cwd[0].toUpperCase()) { + if (itemPath.length === 2) { + return `${itemPath[0]}:\\${cwd.substr(3)}`; + } else { + if (!cwd.endsWith("\\")) { + cwd += "\\"; + } + return `${itemPath[0]}:\\${cwd.substr(3)}${itemPath.substr(2)}`; + } + } else { + return `${itemPath[0]}:\\${itemPath.substr(2)}`; + } + } else if (normalizeSeparators(itemPath).match(/^\\$|^\\[^\\]/)) { + const cwd = process.cwd(); + assert_1.default(cwd.match(/^[A-Z]:\\/i), `Expected current directory to start with an absolute drive root. Actual '${cwd}'`); + return `${cwd[0]}:\\${itemPath.substr(1)}`; + } + } + assert_1.default(hasAbsoluteRoot(root), `ensureAbsoluteRoot parameter 'root' must have an absolute root`); + if (root.endsWith("/") || IS_WINDOWS && root.endsWith("\\")) { + } else { + root += path2.sep; + } + return root + itemPath; + } + __name(ensureAbsoluteRoot, "ensureAbsoluteRoot"); + exports.ensureAbsoluteRoot = ensureAbsoluteRoot; + function hasAbsoluteRoot(itemPath) { + assert_1.default(itemPath, `hasAbsoluteRoot parameter 'itemPath' must not be empty`); + itemPath = normalizeSeparators(itemPath); + if (IS_WINDOWS) { + return itemPath.startsWith("\\\\") || /^[A-Z]:\\/i.test(itemPath); + } + return itemPath.startsWith("/"); + } + __name(hasAbsoluteRoot, "hasAbsoluteRoot"); + exports.hasAbsoluteRoot = hasAbsoluteRoot; + function hasRoot(itemPath) { + assert_1.default(itemPath, `isRooted parameter 'itemPath' must not be empty`); + itemPath = normalizeSeparators(itemPath); + if (IS_WINDOWS) { + return itemPath.startsWith("\\") || /^[A-Z]:/i.test(itemPath); + } + return itemPath.startsWith("/"); + } + __name(hasRoot, "hasRoot"); + exports.hasRoot = hasRoot; + function normalizeSeparators(p) { + p = p || ""; + if (IS_WINDOWS) { + p = p.replace(/\//g, "\\"); + const isUnc = /^\\\\+[^\\]/.test(p); + return (isUnc ? "\\" : "") + p.replace(/\\\\+/g, "\\"); + } + return p.replace(/\/\/+/g, "/"); + } + __name(normalizeSeparators, "normalizeSeparators"); + exports.normalizeSeparators = normalizeSeparators; + function safeTrimTrailingSeparator(p) { + if (!p) { + return ""; + } + p = normalizeSeparators(p); + if (!p.endsWith(path2.sep)) { + return p; + } + if (p === path2.sep) { + return p; + } + if (IS_WINDOWS && /^[A-Z]:\\$/i.test(p)) { + return p; + } + return p.substr(0, p.length - 1); + } + __name(safeTrimTrailingSeparator, "safeTrimTrailingSeparator"); + exports.safeTrimTrailingSeparator = safeTrimTrailingSeparator; + } +}); + +// node_modules/@actions/glob/lib/internal-match-kind.js +var require_internal_match_kind = __commonJS({ + "node_modules/@actions/glob/lib/internal-match-kind.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.MatchKind = void 0; + var MatchKind; + (function(MatchKind2) { + MatchKind2[MatchKind2["None"] = 0] = "None"; + MatchKind2[MatchKind2["Directory"] = 1] = "Directory"; + MatchKind2[MatchKind2["File"] = 2] = "File"; + MatchKind2[MatchKind2["All"] = 3] = "All"; + })(MatchKind = exports.MatchKind || (exports.MatchKind = {})); + } +}); + +// node_modules/@actions/glob/lib/internal-pattern-helper.js +var require_internal_pattern_helper = __commonJS({ + "node_modules/@actions/glob/lib/internal-pattern-helper.js"(exports) { + "use strict"; + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { + return m[k]; + } }); + } : function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + o[k2] = m[k]; + }); + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); + } : function(o, v) { + o["default"] = v; + }); + var __importStar2 = exports && exports.__importStar || function(mod) { + if (mod && mod.__esModule) + return mod; + var result = {}; + if (mod != null) { + for (var k in mod) + if (k !== "default" && Object.hasOwnProperty.call(mod, k)) + __createBinding2(result, mod, k); + } + __setModuleDefault2(result, mod); + return result; + }; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.partialMatch = exports.match = exports.getSearchPaths = void 0; + var pathHelper = __importStar2(require_internal_path_helper()); + var internal_match_kind_1 = require_internal_match_kind(); + var IS_WINDOWS = process.platform === "win32"; + function getSearchPaths(patterns) { + patterns = patterns.filter((x) => !x.negate); + const searchPathMap = {}; + for (const pattern of patterns) { + const key = IS_WINDOWS ? pattern.searchPath.toUpperCase() : pattern.searchPath; + searchPathMap[key] = "candidate"; + } + const result = []; + for (const pattern of patterns) { + const key = IS_WINDOWS ? pattern.searchPath.toUpperCase() : pattern.searchPath; + if (searchPathMap[key] === "included") { + continue; + } + let foundAncestor = false; + let tempKey = key; + let parent = pathHelper.dirname(tempKey); + while (parent !== tempKey) { + if (searchPathMap[parent]) { + foundAncestor = true; + break; + } + tempKey = parent; + parent = pathHelper.dirname(tempKey); + } + if (!foundAncestor) { + result.push(pattern.searchPath); + searchPathMap[key] = "included"; + } + } + return result; + } + __name(getSearchPaths, "getSearchPaths"); + exports.getSearchPaths = getSearchPaths; + function match(patterns, itemPath) { + let result = internal_match_kind_1.MatchKind.None; + for (const pattern of patterns) { + if (pattern.negate) { + result &= ~pattern.match(itemPath); + } else { + result |= pattern.match(itemPath); + } + } + return result; + } + __name(match, "match"); + exports.match = match; + function partialMatch(patterns, itemPath) { + return patterns.some((x) => !x.negate && x.partialMatch(itemPath)); + } + __name(partialMatch, "partialMatch"); + exports.partialMatch = partialMatch; + } +}); + +// node_modules/concat-map/index.js +var require_concat_map = __commonJS({ + "node_modules/concat-map/index.js"(exports, module2) { + module2.exports = function(xs, fn) { + var res = []; + for (var i = 0; i < xs.length; i++) { + var x = fn(xs[i], i); + if (isArray(x)) + res.push.apply(res, x); + else + res.push(x); + } + return res; + }; + var isArray = Array.isArray || function(xs) { + return Object.prototype.toString.call(xs) === "[object Array]"; + }; + } +}); + +// node_modules/balanced-match/index.js +var require_balanced_match = __commonJS({ + "node_modules/balanced-match/index.js"(exports, module2) { + "use strict"; + module2.exports = balanced; + function balanced(a, b, str) { + if (a instanceof RegExp) + a = maybeMatch(a, str); + if (b instanceof RegExp) + b = maybeMatch(b, str); + var r = range(a, b, str); + return r && { + start: r[0], + end: r[1], + pre: str.slice(0, r[0]), + body: str.slice(r[0] + a.length, r[1]), + post: str.slice(r[1] + b.length) + }; + } + __name(balanced, "balanced"); + function maybeMatch(reg, str) { + var m = str.match(reg); + return m ? m[0] : null; + } + __name(maybeMatch, "maybeMatch"); + balanced.range = range; + function range(a, b, str) { + var begs, beg, left, right, result; + var ai = str.indexOf(a); + var bi = str.indexOf(b, ai + 1); + var i = ai; + if (ai >= 0 && bi > 0) { + if (a === b) { + return [ai, bi]; + } + begs = []; + left = str.length; + while (i >= 0 && !result) { + if (i == ai) { + begs.push(i); + ai = str.indexOf(a, i + 1); + } else if (begs.length == 1) { + result = [begs.pop(), bi]; + } else { + beg = begs.pop(); + if (beg < left) { + left = beg; + right = bi; + } + bi = str.indexOf(b, i + 1); + } + i = ai < bi && ai >= 0 ? ai : bi; + } + if (begs.length) { + result = [left, right]; + } + } + return result; + } + __name(range, "range"); + } +}); + +// node_modules/brace-expansion/index.js +var require_brace_expansion = __commonJS({ + "node_modules/brace-expansion/index.js"(exports, module2) { + var concatMap = require_concat_map(); + var balanced = require_balanced_match(); + module2.exports = expandTop; + var escSlash = "\0SLASH" + Math.random() + "\0"; + var escOpen = "\0OPEN" + Math.random() + "\0"; + var escClose = "\0CLOSE" + Math.random() + "\0"; + var escComma = "\0COMMA" + Math.random() + "\0"; + var escPeriod = "\0PERIOD" + Math.random() + "\0"; + function numeric(str) { + return parseInt(str, 10) == str ? parseInt(str, 10) : str.charCodeAt(0); + } + __name(numeric, "numeric"); + function escapeBraces(str) { + return str.split("\\\\").join(escSlash).split("\\{").join(escOpen).split("\\}").join(escClose).split("\\,").join(escComma).split("\\.").join(escPeriod); + } + __name(escapeBraces, "escapeBraces"); + function unescapeBraces(str) { + return str.split(escSlash).join("\\").split(escOpen).join("{").split(escClose).join("}").split(escComma).join(",").split(escPeriod).join("."); + } + __name(unescapeBraces, "unescapeBraces"); + function parseCommaParts(str) { + if (!str) + return [""]; + var parts = []; + var m = balanced("{", "}", str); + if (!m) + return str.split(","); + var pre = m.pre; + var body = m.body; + var post = m.post; + var p = pre.split(","); + p[p.length - 1] += "{" + body + "}"; + var postParts = parseCommaParts(post); + if (post.length) { + p[p.length - 1] += postParts.shift(); + p.push.apply(p, postParts); + } + parts.push.apply(parts, p); + return parts; + } + __name(parseCommaParts, "parseCommaParts"); + function expandTop(str) { + if (!str) + return []; + if (str.substr(0, 2) === "{}") { + str = "\\{\\}" + str.substr(2); + } + return expand(escapeBraces(str), true).map(unescapeBraces); + } + __name(expandTop, "expandTop"); + function embrace(str) { + return "{" + str + "}"; + } + __name(embrace, "embrace"); + function isPadded(el) { + return /^-?0\d/.test(el); + } + __name(isPadded, "isPadded"); + function lte(i, y) { + return i <= y; + } + __name(lte, "lte"); + function gte(i, y) { + return i >= y; + } + __name(gte, "gte"); + function expand(str, isTop) { + var expansions = []; + var m = balanced("{", "}", str); + if (!m || /\$$/.test(m.pre)) + return [str]; + var isNumericSequence = /^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(m.body); + var isAlphaSequence = /^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(m.body); + var isSequence = isNumericSequence || isAlphaSequence; + var isOptions = m.body.indexOf(",") >= 0; + if (!isSequence && !isOptions) { + if (m.post.match(/,.*\}/)) { + str = m.pre + "{" + m.body + escClose + m.post; + return expand(str); + } + return [str]; + } + var n; + if (isSequence) { + n = m.body.split(/\.\./); + } else { + n = parseCommaParts(m.body); + if (n.length === 1) { + n = expand(n[0], false).map(embrace); + if (n.length === 1) { + var post = m.post.length ? expand(m.post, false) : [""]; + return post.map(function(p) { + return m.pre + n[0] + p; + }); + } + } + } + var pre = m.pre; + var post = m.post.length ? expand(m.post, false) : [""]; + var N; + if (isSequence) { + var x = numeric(n[0]); + var y = numeric(n[1]); + var width = Math.max(n[0].length, n[1].length); + var incr = n.length == 3 ? Math.abs(numeric(n[2])) : 1; + var test = lte; + var reverse = y < x; + if (reverse) { + incr *= -1; + test = gte; + } + var pad = n.some(isPadded); + N = []; + for (var i = x; test(i, y); i += incr) { + var c; + if (isAlphaSequence) { + c = String.fromCharCode(i); + if (c === "\\") + c = ""; + } else { + c = String(i); + if (pad) { + var need = width - c.length; + if (need > 0) { + var z = new Array(need + 1).join("0"); + if (i < 0) + c = "-" + z + c.slice(1); + else + c = z + c; + } + } + } + N.push(c); + } + } else { + N = concatMap(n, function(el) { + return expand(el, false); + }); + } + for (var j = 0; j < N.length; j++) { + for (var k = 0; k < post.length; k++) { + var expansion = pre + N[j] + post[k]; + if (!isTop || isSequence || expansion) + expansions.push(expansion); + } + } + return expansions; + } + __name(expand, "expand"); + } +}); + +// node_modules/minimatch/minimatch.js +var require_minimatch = __commonJS({ + "node_modules/minimatch/minimatch.js"(exports, module2) { + module2.exports = minimatch; + minimatch.Minimatch = Minimatch; + var path2 = function() { + try { + return require("path"); + } catch (e) { + } + }() || { + sep: "/" + }; + minimatch.sep = path2.sep; + var GLOBSTAR = minimatch.GLOBSTAR = Minimatch.GLOBSTAR = {}; + var expand = require_brace_expansion(); + var plTypes = { + "!": { open: "(?:(?!(?:", close: "))[^/]*?)" }, + "?": { open: "(?:", close: ")?" }, + "+": { open: "(?:", close: ")+" }, + "*": { open: "(?:", close: ")*" }, + "@": { open: "(?:", close: ")" } + }; + var qmark = "[^/]"; + var star = qmark + "*?"; + var twoStarDot = "(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?"; + var twoStarNoDot = "(?:(?!(?:\\/|^)\\.).)*?"; + var reSpecials = charSet("().*{}+?[]^$\\!"); + function charSet(s) { + return s.split("").reduce(function(set, c) { + set[c] = true; + return set; + }, {}); + } + __name(charSet, "charSet"); + var slashSplit = /\/+/; + minimatch.filter = filter; + function filter(pattern, options) { + options = options || {}; + return function(p, i, list) { + return minimatch(p, pattern, options); + }; + } + __name(filter, "filter"); + function ext(a, b) { + b = b || {}; + var t = {}; + Object.keys(a).forEach(function(k) { + t[k] = a[k]; + }); + Object.keys(b).forEach(function(k) { + t[k] = b[k]; + }); + return t; + } + __name(ext, "ext"); + minimatch.defaults = function(def) { + if (!def || typeof def !== "object" || !Object.keys(def).length) { + return minimatch; + } + var orig = minimatch; + var m = /* @__PURE__ */ __name(function minimatch2(p, pattern, options) { + return orig(p, pattern, ext(def, options)); + }, "minimatch"); + m.Minimatch = /* @__PURE__ */ __name(function Minimatch2(pattern, options) { + return new orig.Minimatch(pattern, ext(def, options)); + }, "Minimatch"); + m.Minimatch.defaults = /* @__PURE__ */ __name(function defaults(options) { + return orig.defaults(ext(def, options)).Minimatch; + }, "defaults"); + m.filter = /* @__PURE__ */ __name(function filter2(pattern, options) { + return orig.filter(pattern, ext(def, options)); + }, "filter"); + m.defaults = /* @__PURE__ */ __name(function defaults(options) { + return orig.defaults(ext(def, options)); + }, "defaults"); + m.makeRe = /* @__PURE__ */ __name(function makeRe2(pattern, options) { + return orig.makeRe(pattern, ext(def, options)); + }, "makeRe"); + m.braceExpand = /* @__PURE__ */ __name(function braceExpand2(pattern, options) { + return orig.braceExpand(pattern, ext(def, options)); + }, "braceExpand"); + m.match = function(list, pattern, options) { + return orig.match(list, pattern, ext(def, options)); + }; + return m; + }; + Minimatch.defaults = function(def) { + return minimatch.defaults(def).Minimatch; + }; + function minimatch(p, pattern, options) { + assertValidPattern(pattern); + if (!options) + options = {}; + if (!options.nocomment && pattern.charAt(0) === "#") { + return false; + } + return new Minimatch(pattern, options).match(p); + } + __name(minimatch, "minimatch"); + function Minimatch(pattern, options) { + if (!(this instanceof Minimatch)) { + return new Minimatch(pattern, options); + } + assertValidPattern(pattern); + if (!options) + options = {}; + pattern = pattern.trim(); + if (!options.allowWindowsEscape && path2.sep !== "/") { + pattern = pattern.split(path2.sep).join("/"); + } + this.options = options; + this.set = []; + this.pattern = pattern; + this.regexp = null; + this.negate = false; + this.comment = false; + this.empty = false; + this.partial = !!options.partial; + this.make(); + } + __name(Minimatch, "Minimatch"); + Minimatch.prototype.debug = function() { + }; + Minimatch.prototype.make = make; + function make() { + var pattern = this.pattern; + var options = this.options; + if (!options.nocomment && pattern.charAt(0) === "#") { + this.comment = true; + return; + } + if (!pattern) { + this.empty = true; + return; + } + this.parseNegate(); + var set = this.globSet = this.braceExpand(); + if (options.debug) + this.debug = /* @__PURE__ */ __name(function debug() { + console.error.apply(console, arguments); + }, "debug"); + this.debug(this.pattern, set); + set = this.globParts = set.map(function(s) { + return s.split(slashSplit); + }); + this.debug(this.pattern, set); + set = set.map(function(s, si, set2) { + return s.map(this.parse, this); + }, this); + this.debug(this.pattern, set); + set = set.filter(function(s) { + return s.indexOf(false) === -1; + }); + this.debug(this.pattern, set); + this.set = set; + } + __name(make, "make"); + Minimatch.prototype.parseNegate = parseNegate; + function parseNegate() { + var pattern = this.pattern; + var negate = false; + var options = this.options; + var negateOffset = 0; + if (options.nonegate) + return; + for (var i = 0, l = pattern.length; i < l && pattern.charAt(i) === "!"; i++) { + negate = !negate; + negateOffset++; + } + if (negateOffset) + this.pattern = pattern.substr(negateOffset); + this.negate = negate; + } + __name(parseNegate, "parseNegate"); + minimatch.braceExpand = function(pattern, options) { + return braceExpand(pattern, options); + }; + Minimatch.prototype.braceExpand = braceExpand; + function braceExpand(pattern, options) { + if (!options) { + if (this instanceof Minimatch) { + options = this.options; + } else { + options = {}; + } + } + pattern = typeof pattern === "undefined" ? this.pattern : pattern; + assertValidPattern(pattern); + if (options.nobrace || !/\{(?:(?!\{).)*\}/.test(pattern)) { + return [pattern]; + } + return expand(pattern); + } + __name(braceExpand, "braceExpand"); + var MAX_PATTERN_LENGTH = 1024 * 64; + var assertValidPattern = /* @__PURE__ */ __name(function(pattern) { + if (typeof pattern !== "string") { + throw new TypeError("invalid pattern"); + } + if (pattern.length > MAX_PATTERN_LENGTH) { + throw new TypeError("pattern is too long"); + } + }, "assertValidPattern"); + Minimatch.prototype.parse = parse3; + var SUBPARSE = {}; + function parse3(pattern, isSub) { + assertValidPattern(pattern); + var options = this.options; + if (pattern === "**") { + if (!options.noglobstar) + return GLOBSTAR; + else + pattern = "*"; + } + if (pattern === "") + return ""; + var re = ""; + var hasMagic = !!options.nocase; + var escaping = false; + var patternListStack = []; + var negativeLists = []; + var stateChar; + var inClass = false; + var reClassStart = -1; + var classStart = -1; + var patternStart = pattern.charAt(0) === "." ? "" : options.dot ? "(?!(?:^|\\/)\\.{1,2}(?:$|\\/))" : "(?!\\.)"; + var self = this; + function clearStateChar() { + if (stateChar) { + switch (stateChar) { + case "*": + re += star; + hasMagic = true; + break; + case "?": + re += qmark; + hasMagic = true; + break; + default: + re += "\\" + stateChar; + break; + } + self.debug("clearStateChar %j %j", stateChar, re); + stateChar = false; + } + } + __name(clearStateChar, "clearStateChar"); + for (var i = 0, len = pattern.length, c; i < len && (c = pattern.charAt(i)); i++) { + this.debug("%s %s %s %j", pattern, i, re, c); + if (escaping && reSpecials[c]) { + re += "\\" + c; + escaping = false; + continue; + } + switch (c) { + case "/": { + return false; + } + case "\\": + clearStateChar(); + escaping = true; + continue; + case "?": + case "*": + case "+": + case "@": + case "!": + this.debug("%s %s %s %j <-- stateChar", pattern, i, re, c); + if (inClass) { + this.debug(" in class"); + if (c === "!" && i === classStart + 1) + c = "^"; + re += c; + continue; + } + self.debug("call clearStateChar %j", stateChar); + clearStateChar(); + stateChar = c; + if (options.noext) + clearStateChar(); + continue; + case "(": + if (inClass) { + re += "("; + continue; + } + if (!stateChar) { + re += "\\("; + continue; + } + patternListStack.push({ + type: stateChar, + start: i - 1, + reStart: re.length, + open: plTypes[stateChar].open, + close: plTypes[stateChar].close + }); + re += stateChar === "!" ? "(?:(?!(?:" : "(?:"; + this.debug("plType %j %j", stateChar, re); + stateChar = false; + continue; + case ")": + if (inClass || !patternListStack.length) { + re += "\\)"; + continue; + } + clearStateChar(); + hasMagic = true; + var pl = patternListStack.pop(); + re += pl.close; + if (pl.type === "!") { + negativeLists.push(pl); + } + pl.reEnd = re.length; + continue; + case "|": + if (inClass || !patternListStack.length || escaping) { + re += "\\|"; + escaping = false; + continue; + } + clearStateChar(); + re += "|"; + continue; + case "[": + clearStateChar(); + if (inClass) { + re += "\\" + c; + continue; + } + inClass = true; + classStart = i; + reClassStart = re.length; + re += c; + continue; + case "]": + if (i === classStart + 1 || !inClass) { + re += "\\" + c; + escaping = false; + continue; + } + var cs = pattern.substring(classStart + 1, i); + try { + RegExp("[" + cs + "]"); + } catch (er) { + var sp = this.parse(cs, SUBPARSE); + re = re.substr(0, reClassStart) + "\\[" + sp[0] + "\\]"; + hasMagic = hasMagic || sp[1]; + inClass = false; + continue; + } + hasMagic = true; + inClass = false; + re += c; + continue; + default: + clearStateChar(); + if (escaping) { + escaping = false; + } else if (reSpecials[c] && !(c === "^" && inClass)) { + re += "\\"; + } + re += c; + } + } + if (inClass) { + cs = pattern.substr(classStart + 1); + sp = this.parse(cs, SUBPARSE); + re = re.substr(0, reClassStart) + "\\[" + sp[0]; + hasMagic = hasMagic || sp[1]; + } + for (pl = patternListStack.pop(); pl; pl = patternListStack.pop()) { + var tail = re.slice(pl.reStart + pl.open.length); + this.debug("setting tail", re, pl); + tail = tail.replace(/((?:\\{2}){0,64})(\\?)\|/g, function(_, $1, $2) { + if (!$2) { + $2 = "\\"; + } + return $1 + $1 + $2 + "|"; + }); + this.debug("tail=%j\n %s", tail, tail, pl, re); + var t = pl.type === "*" ? star : pl.type === "?" ? qmark : "\\" + pl.type; + hasMagic = true; + re = re.slice(0, pl.reStart) + t + "\\(" + tail; + } + clearStateChar(); + if (escaping) { + re += "\\\\"; + } + var addPatternStart = false; + switch (re.charAt(0)) { + case "[": + case ".": + case "(": + addPatternStart = true; + } + for (var n = negativeLists.length - 1; n > -1; n--) { + var nl = negativeLists[n]; + var nlBefore = re.slice(0, nl.reStart); + var nlFirst = re.slice(nl.reStart, nl.reEnd - 8); + var nlLast = re.slice(nl.reEnd - 8, nl.reEnd); + var nlAfter = re.slice(nl.reEnd); + nlLast += nlAfter; + var openParensBefore = nlBefore.split("(").length - 1; + var cleanAfter = nlAfter; + for (i = 0; i < openParensBefore; i++) { + cleanAfter = cleanAfter.replace(/\)[+*?]?/, ""); + } + nlAfter = cleanAfter; + var dollar = ""; + if (nlAfter === "" && isSub !== SUBPARSE) { + dollar = "$"; + } + var newRe = nlBefore + nlFirst + nlAfter + dollar + nlLast; + re = newRe; + } + if (re !== "" && hasMagic) { + re = "(?=.)" + re; + } + if (addPatternStart) { + re = patternStart + re; + } + if (isSub === SUBPARSE) { + return [re, hasMagic]; + } + if (!hasMagic) { + return globUnescape(pattern); + } + var flags = options.nocase ? "i" : ""; + try { + var regExp = new RegExp("^" + re + "$", flags); + } catch (er) { + return new RegExp("$."); + } + regExp._glob = pattern; + regExp._src = re; + return regExp; + } + __name(parse3, "parse"); + minimatch.makeRe = function(pattern, options) { + return new Minimatch(pattern, options || {}).makeRe(); + }; + Minimatch.prototype.makeRe = makeRe; + function makeRe() { + if (this.regexp || this.regexp === false) + return this.regexp; + var set = this.set; + if (!set.length) { + this.regexp = false; + return this.regexp; + } + var options = this.options; + var twoStar = options.noglobstar ? star : options.dot ? twoStarDot : twoStarNoDot; + var flags = options.nocase ? "i" : ""; + var re = set.map(function(pattern) { + return pattern.map(function(p) { + return p === GLOBSTAR ? twoStar : typeof p === "string" ? regExpEscape(p) : p._src; + }).join("\\/"); + }).join("|"); + re = "^(?:" + re + ")$"; + if (this.negate) + re = "^(?!" + re + ").*$"; + try { + this.regexp = new RegExp(re, flags); + } catch (ex) { + this.regexp = false; + } + return this.regexp; + } + __name(makeRe, "makeRe"); + minimatch.match = function(list, pattern, options) { + options = options || {}; + var mm = new Minimatch(pattern, options); + list = list.filter(function(f) { + return mm.match(f); + }); + if (mm.options.nonull && !list.length) { + list.push(pattern); + } + return list; + }; + Minimatch.prototype.match = /* @__PURE__ */ __name(function match(f, partial) { + if (typeof partial === "undefined") + partial = this.partial; + this.debug("match", f, this.pattern); + if (this.comment) + return false; + if (this.empty) + return f === ""; + if (f === "/" && partial) + return true; + var options = this.options; + if (path2.sep !== "/") { + f = f.split(path2.sep).join("/"); + } + f = f.split(slashSplit); + this.debug(this.pattern, "split", f); + var set = this.set; + this.debug(this.pattern, "set", set); + var filename; + var i; + for (i = f.length - 1; i >= 0; i--) { + filename = f[i]; + if (filename) + break; + } + for (i = 0; i < set.length; i++) { + var pattern = set[i]; + var file = f; + if (options.matchBase && pattern.length === 1) { + file = [filename]; + } + var hit = this.matchOne(file, pattern, partial); + if (hit) { + if (options.flipNegate) + return true; + return !this.negate; + } + } + if (options.flipNegate) + return false; + return this.negate; + }, "match"); + Minimatch.prototype.matchOne = function(file, pattern, partial) { + var options = this.options; + this.debug( + "matchOne", + { "this": this, file, pattern } + ); + this.debug("matchOne", file.length, pattern.length); + for (var fi = 0, pi = 0, fl = file.length, pl = pattern.length; fi < fl && pi < pl; fi++, pi++) { + this.debug("matchOne loop"); + var p = pattern[pi]; + var f = file[fi]; + this.debug(pattern, p, f); + if (p === false) + return false; + if (p === GLOBSTAR) { + this.debug("GLOBSTAR", [pattern, p, f]); + var fr = fi; + var pr = pi + 1; + if (pr === pl) { + this.debug("** at the end"); + for (; fi < fl; fi++) { + if (file[fi] === "." || file[fi] === ".." || !options.dot && file[fi].charAt(0) === ".") + return false; + } + return true; + } + while (fr < fl) { + var swallowee = file[fr]; + this.debug("\nglobstar while", file, fr, pattern, pr, swallowee); + if (this.matchOne(file.slice(fr), pattern.slice(pr), partial)) { + this.debug("globstar found match!", fr, fl, swallowee); + return true; + } else { + if (swallowee === "." || swallowee === ".." || !options.dot && swallowee.charAt(0) === ".") { + this.debug("dot detected!", file, fr, pattern, pr); + break; + } + this.debug("globstar swallow a segment, and continue"); + fr++; + } + } + if (partial) { + this.debug("\n>>> no match, partial?", file, fr, pattern, pr); + if (fr === fl) + return true; + } + return false; + } + var hit; + if (typeof p === "string") { + hit = f === p; + this.debug("string match", p, f, hit); + } else { + hit = f.match(p); + this.debug("pattern match", p, f, hit); + } + if (!hit) + return false; + } + if (fi === fl && pi === pl) { + return true; + } else if (fi === fl) { + return partial; + } else if (pi === pl) { + return fi === fl - 1 && file[fi] === ""; + } + throw new Error("wtf?"); + }; + function globUnescape(s) { + return s.replace(/\\(.)/g, "$1"); + } + __name(globUnescape, "globUnescape"); + function regExpEscape(s) { + return s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&"); + } + __name(regExpEscape, "regExpEscape"); + } +}); + +// node_modules/@actions/glob/lib/internal-path.js +var require_internal_path = __commonJS({ + "node_modules/@actions/glob/lib/internal-path.js"(exports) { + "use strict"; + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { + return m[k]; + } }); + } : function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + o[k2] = m[k]; + }); + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); + } : function(o, v) { + o["default"] = v; + }); + var __importStar2 = exports && exports.__importStar || function(mod) { + if (mod && mod.__esModule) + return mod; + var result = {}; + if (mod != null) { + for (var k in mod) + if (k !== "default" && Object.hasOwnProperty.call(mod, k)) + __createBinding2(result, mod, k); + } + __setModuleDefault2(result, mod); + return result; + }; + var __importDefault2 = exports && exports.__importDefault || function(mod) { + return mod && mod.__esModule ? mod : { "default": mod }; + }; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.Path = void 0; + var path2 = __importStar2(require("path")); + var pathHelper = __importStar2(require_internal_path_helper()); + var assert_1 = __importDefault2(require("assert")); + var IS_WINDOWS = process.platform === "win32"; + var _Path = class _Path { + /** + * Constructs a Path + * @param itemPath Path or array of segments + */ + constructor(itemPath) { + this.segments = []; + if (typeof itemPath === "string") { + assert_1.default(itemPath, `Parameter 'itemPath' must not be empty`); + itemPath = pathHelper.safeTrimTrailingSeparator(itemPath); + if (!pathHelper.hasRoot(itemPath)) { + this.segments = itemPath.split(path2.sep); + } else { + let remaining = itemPath; + let dir = pathHelper.dirname(remaining); + while (dir !== remaining) { + const basename = path2.basename(remaining); + this.segments.unshift(basename); + remaining = dir; + dir = pathHelper.dirname(remaining); + } + this.segments.unshift(remaining); + } + } else { + assert_1.default(itemPath.length > 0, `Parameter 'itemPath' must not be an empty array`); + for (let i = 0; i < itemPath.length; i++) { + let segment = itemPath[i]; + assert_1.default(segment, `Parameter 'itemPath' must not contain any empty segments`); + segment = pathHelper.normalizeSeparators(itemPath[i]); + if (i === 0 && pathHelper.hasRoot(segment)) { + segment = pathHelper.safeTrimTrailingSeparator(segment); + assert_1.default(segment === pathHelper.dirname(segment), `Parameter 'itemPath' root segment contains information for multiple segments`); + this.segments.push(segment); + } else { + assert_1.default(!segment.includes(path2.sep), `Parameter 'itemPath' contains unexpected path separators`); + this.segments.push(segment); + } + } + } + } + /** + * Converts the path to it's string representation + */ + toString() { + let result = this.segments[0]; + let skipSlash = result.endsWith(path2.sep) || IS_WINDOWS && /^[A-Z]:$/i.test(result); + for (let i = 1; i < this.segments.length; i++) { + if (skipSlash) { + skipSlash = false; + } else { + result += path2.sep; + } + result += this.segments[i]; + } + return result; + } + }; + __name(_Path, "Path"); + var Path = _Path; + exports.Path = Path; + } +}); + +// node_modules/@actions/glob/lib/internal-pattern.js +var require_internal_pattern = __commonJS({ + "node_modules/@actions/glob/lib/internal-pattern.js"(exports) { + "use strict"; + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { + return m[k]; + } }); + } : function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + o[k2] = m[k]; + }); + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); + } : function(o, v) { + o["default"] = v; + }); + var __importStar2 = exports && exports.__importStar || function(mod) { + if (mod && mod.__esModule) + return mod; + var result = {}; + if (mod != null) { + for (var k in mod) + if (k !== "default" && Object.hasOwnProperty.call(mod, k)) + __createBinding2(result, mod, k); + } + __setModuleDefault2(result, mod); + return result; + }; + var __importDefault2 = exports && exports.__importDefault || function(mod) { + return mod && mod.__esModule ? mod : { "default": mod }; + }; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.Pattern = void 0; + var os2 = __importStar2(require("os")); + var path2 = __importStar2(require("path")); + var pathHelper = __importStar2(require_internal_path_helper()); + var assert_1 = __importDefault2(require("assert")); + var minimatch_1 = require_minimatch(); + var internal_match_kind_1 = require_internal_match_kind(); + var internal_path_1 = require_internal_path(); + var IS_WINDOWS = process.platform === "win32"; + var _Pattern = class _Pattern { + constructor(patternOrNegate, isImplicitPattern = false, segments, homedir) { + this.negate = false; + let pattern; + if (typeof patternOrNegate === "string") { + pattern = patternOrNegate.trim(); + } else { + segments = segments || []; + assert_1.default(segments.length, `Parameter 'segments' must not empty`); + const root = _Pattern.getLiteral(segments[0]); + assert_1.default(root && pathHelper.hasAbsoluteRoot(root), `Parameter 'segments' first element must be a root path`); + pattern = new internal_path_1.Path(segments).toString().trim(); + if (patternOrNegate) { + pattern = `!${pattern}`; + } + } + while (pattern.startsWith("!")) { + this.negate = !this.negate; + pattern = pattern.substr(1).trim(); + } + pattern = _Pattern.fixupPattern(pattern, homedir); + this.segments = new internal_path_1.Path(pattern).segments; + this.trailingSeparator = pathHelper.normalizeSeparators(pattern).endsWith(path2.sep); + pattern = pathHelper.safeTrimTrailingSeparator(pattern); + let foundGlob = false; + const searchSegments = this.segments.map((x) => _Pattern.getLiteral(x)).filter((x) => !foundGlob && !(foundGlob = x === "")); + this.searchPath = new internal_path_1.Path(searchSegments).toString(); + this.rootRegExp = new RegExp(_Pattern.regExpEscape(searchSegments[0]), IS_WINDOWS ? "i" : ""); + this.isImplicitPattern = isImplicitPattern; + const minimatchOptions = { + dot: true, + nobrace: true, + nocase: IS_WINDOWS, + nocomment: true, + noext: true, + nonegate: true + }; + pattern = IS_WINDOWS ? pattern.replace(/\\/g, "/") : pattern; + this.minimatch = new minimatch_1.Minimatch(pattern, minimatchOptions); + } + /** + * Matches the pattern against the specified path + */ + match(itemPath) { + if (this.segments[this.segments.length - 1] === "**") { + itemPath = pathHelper.normalizeSeparators(itemPath); + if (!itemPath.endsWith(path2.sep) && this.isImplicitPattern === false) { + itemPath = `${itemPath}${path2.sep}`; + } + } else { + itemPath = pathHelper.safeTrimTrailingSeparator(itemPath); + } + if (this.minimatch.match(itemPath)) { + return this.trailingSeparator ? internal_match_kind_1.MatchKind.Directory : internal_match_kind_1.MatchKind.All; + } + return internal_match_kind_1.MatchKind.None; + } + /** + * Indicates whether the pattern may match descendants of the specified path + */ + partialMatch(itemPath) { + itemPath = pathHelper.safeTrimTrailingSeparator(itemPath); + if (pathHelper.dirname(itemPath) === itemPath) { + return this.rootRegExp.test(itemPath); + } + return this.minimatch.matchOne(itemPath.split(IS_WINDOWS ? /\\+/ : /\/+/), this.minimatch.set[0], true); + } + /** + * Escapes glob patterns within a path + */ + static globEscape(s) { + return (IS_WINDOWS ? s : s.replace(/\\/g, "\\\\")).replace(/(\[)(?=[^/]+\])/g, "[[]").replace(/\?/g, "[?]").replace(/\*/g, "[*]"); + } + /** + * Normalizes slashes and ensures absolute root + */ + static fixupPattern(pattern, homedir) { + assert_1.default(pattern, "pattern cannot be empty"); + const literalSegments = new internal_path_1.Path(pattern).segments.map((x) => _Pattern.getLiteral(x)); + assert_1.default(literalSegments.every((x, i) => (x !== "." || i === 0) && x !== ".."), `Invalid pattern '${pattern}'. Relative pathing '.' and '..' is not allowed.`); + assert_1.default(!pathHelper.hasRoot(pattern) || literalSegments[0], `Invalid pattern '${pattern}'. Root segment must not contain globs.`); + pattern = pathHelper.normalizeSeparators(pattern); + if (pattern === "." || pattern.startsWith(`.${path2.sep}`)) { + pattern = _Pattern.globEscape(process.cwd()) + pattern.substr(1); + } else if (pattern === "~" || pattern.startsWith(`~${path2.sep}`)) { + homedir = homedir || os2.homedir(); + assert_1.default(homedir, "Unable to determine HOME directory"); + assert_1.default(pathHelper.hasAbsoluteRoot(homedir), `Expected HOME directory to be a rooted path. Actual '${homedir}'`); + pattern = _Pattern.globEscape(homedir) + pattern.substr(1); + } else if (IS_WINDOWS && (pattern.match(/^[A-Z]:$/i) || pattern.match(/^[A-Z]:[^\\]/i))) { + let root = pathHelper.ensureAbsoluteRoot("C:\\dummy-root", pattern.substr(0, 2)); + if (pattern.length > 2 && !root.endsWith("\\")) { + root += "\\"; + } + pattern = _Pattern.globEscape(root) + pattern.substr(2); + } else if (IS_WINDOWS && (pattern === "\\" || pattern.match(/^\\[^\\]/))) { + let root = pathHelper.ensureAbsoluteRoot("C:\\dummy-root", "\\"); + if (!root.endsWith("\\")) { + root += "\\"; + } + pattern = _Pattern.globEscape(root) + pattern.substr(1); + } else { + pattern = pathHelper.ensureAbsoluteRoot(_Pattern.globEscape(process.cwd()), pattern); + } + return pathHelper.normalizeSeparators(pattern); + } + /** + * Attempts to unescape a pattern segment to create a literal path segment. + * Otherwise returns empty string. + */ + static getLiteral(segment) { + let literal = ""; + for (let i = 0; i < segment.length; i++) { + const c = segment[i]; + if (c === "\\" && !IS_WINDOWS && i + 1 < segment.length) { + literal += segment[++i]; + continue; + } else if (c === "*" || c === "?") { + return ""; + } else if (c === "[" && i + 1 < segment.length) { + let set = ""; + let closed = -1; + for (let i2 = i + 1; i2 < segment.length; i2++) { + const c2 = segment[i2]; + if (c2 === "\\" && !IS_WINDOWS && i2 + 1 < segment.length) { + set += segment[++i2]; + continue; + } else if (c2 === "]") { + closed = i2; + break; + } else { + set += c2; + } + } + if (closed >= 0) { + if (set.length > 1) { + return ""; + } + if (set) { + literal += set; + i = closed; + continue; + } + } + } + literal += c; + } + return literal; + } + /** + * Escapes regexp special characters + * https://javascript.info/regexp-escaping + */ + static regExpEscape(s) { + return s.replace(/[[\\^$.|?*+()]/g, "\\$&"); + } + }; + __name(_Pattern, "Pattern"); + var Pattern = _Pattern; + exports.Pattern = Pattern; + } +}); + +// node_modules/@actions/glob/lib/internal-search-state.js +var require_internal_search_state = __commonJS({ + "node_modules/@actions/glob/lib/internal-search-state.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.SearchState = void 0; + var _SearchState = class _SearchState { + constructor(path2, level) { + this.path = path2; + this.level = level; + } + }; + __name(_SearchState, "SearchState"); + var SearchState = _SearchState; + exports.SearchState = SearchState; + } +}); + +// node_modules/@actions/glob/lib/internal-globber.js +var require_internal_globber = __commonJS({ + "node_modules/@actions/glob/lib/internal-globber.js"(exports) { + "use strict"; + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { + return m[k]; + } }); + } : function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + o[k2] = m[k]; + }); + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); + } : function(o, v) { + o["default"] = v; + }); + var __importStar2 = exports && exports.__importStar || function(mod) { + if (mod && mod.__esModule) + return mod; + var result = {}; + if (mod != null) { + for (var k in mod) + if (k !== "default" && Object.hasOwnProperty.call(mod, k)) + __createBinding2(result, mod, k); + } + __setModuleDefault2(result, mod); + return result; + }; + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function(resolve) { resolve(value); }); } + __name(adopt, "adopt"); return new (P || (P = Promise))(function(resolve, reject) { function fulfilled(value) { try { @@ -7036,6 +7356,7 @@ var require_retry_helper = __commonJS({ reject(e); } } + __name(fulfilled, "fulfilled"); function rejected(value) { try { step(generator["throw"](value)); @@ -7043,16 +7364,55606 @@ var require_retry_helper = __commonJS({ reject(e); } } + __name(rejected, "rejected"); function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + __name(step, "step"); + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); + }; + var __asyncValues2 = exports && exports.__asyncValues || function(o) { + if (!Symbol.asyncIterator) + throw new TypeError("Symbol.asyncIterator is not defined."); + var m = o[Symbol.asyncIterator], i; + return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() { + return this; + }, i); + function verb(n) { + i[n] = o[n] && function(v) { + return new Promise(function(resolve, reject) { + v = o[n](v), settle(resolve, reject, v.done, v.value); + }); + }; + } + __name(verb, "verb"); + function settle(resolve, reject, d, v) { + Promise.resolve(v).then(function(v2) { + resolve({ value: v2, done: d }); + }, reject); + } + __name(settle, "settle"); + }; + var __await2 = exports && exports.__await || function(v) { + return this instanceof __await2 ? (this.v = v, this) : new __await2(v); + }; + var __asyncGenerator2 = exports && exports.__asyncGenerator || function(thisArg, _arguments, generator) { + if (!Symbol.asyncIterator) + throw new TypeError("Symbol.asyncIterator is not defined."); + var g = generator.apply(thisArg, _arguments || []), i, q = []; + return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() { + return this; + }, i; + function verb(n) { + if (g[n]) + i[n] = function(v) { + return new Promise(function(a, b) { + q.push([n, v, a, b]) > 1 || resume(n, v); + }); + }; + } + __name(verb, "verb"); + function resume(n, v) { + try { + step(g[n](v)); + } catch (e) { + settle(q[0][3], e); + } + } + __name(resume, "resume"); + function step(r) { + r.value instanceof __await2 ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); + } + __name(step, "step"); + function fulfill(value) { + resume("next", value); + } + __name(fulfill, "fulfill"); + function reject(value) { + resume("throw", value); + } + __name(reject, "reject"); + function settle(f, v) { + if (f(v), q.shift(), q.length) + resume(q[0][0], q[0][1]); + } + __name(settle, "settle"); + }; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.DefaultGlobber = void 0; + var core = __importStar2(require_core()); + var fs = __importStar2(require("fs")); + var globOptionsHelper = __importStar2(require_internal_glob_options_helper()); + var path2 = __importStar2(require("path")); + var patternHelper = __importStar2(require_internal_pattern_helper()); + var internal_match_kind_1 = require_internal_match_kind(); + var internal_pattern_1 = require_internal_pattern(); + var internal_search_state_1 = require_internal_search_state(); + var IS_WINDOWS = process.platform === "win32"; + var _DefaultGlobber = class _DefaultGlobber { + constructor(options) { + this.patterns = []; + this.searchPaths = []; + this.options = globOptionsHelper.getOptions(options); + } + getSearchPaths() { + return this.searchPaths.slice(); + } + glob() { + var e_1, _a; + return __awaiter2(this, void 0, void 0, function* () { + const result = []; + try { + for (var _b = __asyncValues2(this.globGenerator()), _c; _c = yield _b.next(), !_c.done; ) { + const itemPath = _c.value; + result.push(itemPath); + } + } catch (e_1_1) { + e_1 = { error: e_1_1 }; + } finally { + try { + if (_c && !_c.done && (_a = _b.return)) + yield _a.call(_b); + } finally { + if (e_1) + throw e_1.error; + } + } + return result; + }); + } + globGenerator() { + return __asyncGenerator2(this, arguments, /* @__PURE__ */ __name(function* globGenerator_1() { + const options = globOptionsHelper.getOptions(this.options); + const patterns = []; + for (const pattern of this.patterns) { + patterns.push(pattern); + if (options.implicitDescendants && (pattern.trailingSeparator || pattern.segments[pattern.segments.length - 1] !== "**")) { + patterns.push(new internal_pattern_1.Pattern(pattern.negate, true, pattern.segments.concat("**"))); + } + } + const stack = []; + for (const searchPath of patternHelper.getSearchPaths(patterns)) { + core.debug(`Search path '${searchPath}'`); + try { + yield __await2(fs.promises.lstat(searchPath)); + } catch (err) { + if (err.code === "ENOENT") { + continue; + } + throw err; + } + stack.unshift(new internal_search_state_1.SearchState(searchPath, 1)); + } + const traversalChain = []; + while (stack.length) { + const item = stack.pop(); + const match = patternHelper.match(patterns, item.path); + const partialMatch = !!match || patternHelper.partialMatch(patterns, item.path); + if (!match && !partialMatch) { + continue; + } + const stats = yield __await2( + _DefaultGlobber.stat(item, options, traversalChain) + // Broken symlink, or symlink cycle detected, or no longer exists + ); + if (!stats) { + continue; + } + if (stats.isDirectory()) { + if (match & internal_match_kind_1.MatchKind.Directory) { + yield yield __await2(item.path); + } else if (!partialMatch) { + continue; + } + const childLevel = item.level + 1; + const childItems = (yield __await2(fs.promises.readdir(item.path))).map((x) => new internal_search_state_1.SearchState(path2.join(item.path, x), childLevel)); + stack.push(...childItems.reverse()); + } else if (match & internal_match_kind_1.MatchKind.File) { + yield yield __await2(item.path); + } + } + }, "globGenerator_1")); + } + /** + * Constructs a DefaultGlobber + */ + static create(patterns, options) { + return __awaiter2(this, void 0, void 0, function* () { + const result = new _DefaultGlobber(options); + if (IS_WINDOWS) { + patterns = patterns.replace(/\r\n/g, "\n"); + patterns = patterns.replace(/\r/g, "\n"); + } + const lines = patterns.split("\n").map((x) => x.trim()); + for (const line of lines) { + if (!line || line.startsWith("#")) { + continue; + } else { + result.patterns.push(new internal_pattern_1.Pattern(line)); + } + } + result.searchPaths.push(...patternHelper.getSearchPaths(result.patterns)); + return result; + }); + } + static stat(item, options, traversalChain) { + return __awaiter2(this, void 0, void 0, function* () { + let stats; + if (options.followSymbolicLinks) { + try { + stats = yield fs.promises.stat(item.path); + } catch (err) { + if (err.code === "ENOENT") { + if (options.omitBrokenSymbolicLinks) { + core.debug(`Broken symlink '${item.path}'`); + return void 0; + } + throw new Error(`No information found for the path '${item.path}'. This may indicate a broken symbolic link.`); + } + throw err; + } + } else { + stats = yield fs.promises.lstat(item.path); + } + if (stats.isDirectory() && options.followSymbolicLinks) { + const realPath = yield fs.promises.realpath(item.path); + while (traversalChain.length >= item.level) { + traversalChain.pop(); + } + if (traversalChain.some((x) => x === realPath)) { + core.debug(`Symlink cycle detected for path '${item.path}' and realpath '${realPath}'`); + return void 0; + } + traversalChain.push(realPath); + } + return stats; + }); + } + }; + __name(_DefaultGlobber, "DefaultGlobber"); + var DefaultGlobber = _DefaultGlobber; + exports.DefaultGlobber = DefaultGlobber; + } +}); + +// node_modules/@actions/glob/lib/glob.js +var require_glob = __commonJS({ + "node_modules/@actions/glob/lib/glob.js"(exports) { + "use strict"; + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + function adopt(value) { + return value instanceof P ? value : new P(function(resolve) { + resolve(value); + }); + } + __name(adopt, "adopt"); + return new (P || (P = Promise))(function(resolve, reject) { + function fulfilled(value) { + try { + step(generator.next(value)); + } catch (e) { + reject(e); + } + } + __name(fulfilled, "fulfilled"); + function rejected(value) { + try { + step(generator["throw"](value)); + } catch (e) { + reject(e); + } + } + __name(rejected, "rejected"); + function step(result) { + result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); + } + __name(step, "step"); + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); + }; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.create = void 0; + var internal_globber_1 = require_internal_globber(); + function create(patterns, options) { + return __awaiter2(this, void 0, void 0, function* () { + return yield internal_globber_1.DefaultGlobber.create(patterns, options); + }); + } + __name(create, "create"); + exports.create = create; + } +}); + +// node_modules/@actions/cache/node_modules/semver/semver.js +var require_semver3 = __commonJS({ + "node_modules/@actions/cache/node_modules/semver/semver.js"(exports, module2) { + exports = module2.exports = SemVer; + var debug; + if (typeof process === "object" && process.env && process.env.NODE_DEBUG && /\bsemver\b/i.test(process.env.NODE_DEBUG)) { + debug = /* @__PURE__ */ __name(function() { + var args = Array.prototype.slice.call(arguments, 0); + args.unshift("SEMVER"); + console.log.apply(console, args); + }, "debug"); + } else { + debug = /* @__PURE__ */ __name(function() { + }, "debug"); + } + exports.SEMVER_SPEC_VERSION = "2.0.0"; + var MAX_LENGTH = 256; + var MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER || /* istanbul ignore next */ + 9007199254740991; + var MAX_SAFE_COMPONENT_LENGTH = 16; + var re = exports.re = []; + var src = exports.src = []; + var t = exports.tokens = {}; + var R = 0; + function tok(n) { + t[n] = R++; + } + __name(tok, "tok"); + tok("NUMERICIDENTIFIER"); + src[t.NUMERICIDENTIFIER] = "0|[1-9]\\d*"; + tok("NUMERICIDENTIFIERLOOSE"); + src[t.NUMERICIDENTIFIERLOOSE] = "[0-9]+"; + tok("NONNUMERICIDENTIFIER"); + src[t.NONNUMERICIDENTIFIER] = "\\d*[a-zA-Z-][a-zA-Z0-9-]*"; + tok("MAINVERSION"); + src[t.MAINVERSION] = "(" + src[t.NUMERICIDENTIFIER] + ")\\.(" + src[t.NUMERICIDENTIFIER] + ")\\.(" + src[t.NUMERICIDENTIFIER] + ")"; + tok("MAINVERSIONLOOSE"); + src[t.MAINVERSIONLOOSE] = "(" + src[t.NUMERICIDENTIFIERLOOSE] + ")\\.(" + src[t.NUMERICIDENTIFIERLOOSE] + ")\\.(" + src[t.NUMERICIDENTIFIERLOOSE] + ")"; + tok("PRERELEASEIDENTIFIER"); + src[t.PRERELEASEIDENTIFIER] = "(?:" + src[t.NUMERICIDENTIFIER] + "|" + src[t.NONNUMERICIDENTIFIER] + ")"; + tok("PRERELEASEIDENTIFIERLOOSE"); + src[t.PRERELEASEIDENTIFIERLOOSE] = "(?:" + src[t.NUMERICIDENTIFIERLOOSE] + "|" + src[t.NONNUMERICIDENTIFIER] + ")"; + tok("PRERELEASE"); + src[t.PRERELEASE] = "(?:-(" + src[t.PRERELEASEIDENTIFIER] + "(?:\\." + src[t.PRERELEASEIDENTIFIER] + ")*))"; + tok("PRERELEASELOOSE"); + src[t.PRERELEASELOOSE] = "(?:-?(" + src[t.PRERELEASEIDENTIFIERLOOSE] + "(?:\\." + src[t.PRERELEASEIDENTIFIERLOOSE] + ")*))"; + tok("BUILDIDENTIFIER"); + src[t.BUILDIDENTIFIER] = "[0-9A-Za-z-]+"; + tok("BUILD"); + src[t.BUILD] = "(?:\\+(" + src[t.BUILDIDENTIFIER] + "(?:\\." + src[t.BUILDIDENTIFIER] + ")*))"; + tok("FULL"); + tok("FULLPLAIN"); + src[t.FULLPLAIN] = "v?" + src[t.MAINVERSION] + src[t.PRERELEASE] + "?" + src[t.BUILD] + "?"; + src[t.FULL] = "^" + src[t.FULLPLAIN] + "$"; + tok("LOOSEPLAIN"); + src[t.LOOSEPLAIN] = "[v=\\s]*" + src[t.MAINVERSIONLOOSE] + src[t.PRERELEASELOOSE] + "?" + src[t.BUILD] + "?"; + tok("LOOSE"); + src[t.LOOSE] = "^" + src[t.LOOSEPLAIN] + "$"; + tok("GTLT"); + src[t.GTLT] = "((?:<|>)?=?)"; + tok("XRANGEIDENTIFIERLOOSE"); + src[t.XRANGEIDENTIFIERLOOSE] = src[t.NUMERICIDENTIFIERLOOSE] + "|x|X|\\*"; + tok("XRANGEIDENTIFIER"); + src[t.XRANGEIDENTIFIER] = src[t.NUMERICIDENTIFIER] + "|x|X|\\*"; + tok("XRANGEPLAIN"); + src[t.XRANGEPLAIN] = "[v=\\s]*(" + src[t.XRANGEIDENTIFIER] + ")(?:\\.(" + src[t.XRANGEIDENTIFIER] + ")(?:\\.(" + src[t.XRANGEIDENTIFIER] + ")(?:" + src[t.PRERELEASE] + ")?" + src[t.BUILD] + "?)?)?"; + tok("XRANGEPLAINLOOSE"); + src[t.XRANGEPLAINLOOSE] = "[v=\\s]*(" + src[t.XRANGEIDENTIFIERLOOSE] + ")(?:\\.(" + src[t.XRANGEIDENTIFIERLOOSE] + ")(?:\\.(" + src[t.XRANGEIDENTIFIERLOOSE] + ")(?:" + src[t.PRERELEASELOOSE] + ")?" + src[t.BUILD] + "?)?)?"; + tok("XRANGE"); + src[t.XRANGE] = "^" + src[t.GTLT] + "\\s*" + src[t.XRANGEPLAIN] + "$"; + tok("XRANGELOOSE"); + src[t.XRANGELOOSE] = "^" + src[t.GTLT] + "\\s*" + src[t.XRANGEPLAINLOOSE] + "$"; + tok("COERCE"); + src[t.COERCE] = "(^|[^\\d])(\\d{1," + MAX_SAFE_COMPONENT_LENGTH + "})(?:\\.(\\d{1," + MAX_SAFE_COMPONENT_LENGTH + "}))?(?:\\.(\\d{1," + MAX_SAFE_COMPONENT_LENGTH + "}))?(?:$|[^\\d])"; + tok("COERCERTL"); + re[t.COERCERTL] = new RegExp(src[t.COERCE], "g"); + tok("LONETILDE"); + src[t.LONETILDE] = "(?:~>?)"; + tok("TILDETRIM"); + src[t.TILDETRIM] = "(\\s*)" + src[t.LONETILDE] + "\\s+"; + re[t.TILDETRIM] = new RegExp(src[t.TILDETRIM], "g"); + var tildeTrimReplace = "$1~"; + tok("TILDE"); + src[t.TILDE] = "^" + src[t.LONETILDE] + src[t.XRANGEPLAIN] + "$"; + tok("TILDELOOSE"); + src[t.TILDELOOSE] = "^" + src[t.LONETILDE] + src[t.XRANGEPLAINLOOSE] + "$"; + tok("LONECARET"); + src[t.LONECARET] = "(?:\\^)"; + tok("CARETTRIM"); + src[t.CARETTRIM] = "(\\s*)" + src[t.LONECARET] + "\\s+"; + re[t.CARETTRIM] = new RegExp(src[t.CARETTRIM], "g"); + var caretTrimReplace = "$1^"; + tok("CARET"); + src[t.CARET] = "^" + src[t.LONECARET] + src[t.XRANGEPLAIN] + "$"; + tok("CARETLOOSE"); + src[t.CARETLOOSE] = "^" + src[t.LONECARET] + src[t.XRANGEPLAINLOOSE] + "$"; + tok("COMPARATORLOOSE"); + src[t.COMPARATORLOOSE] = "^" + src[t.GTLT] + "\\s*(" + src[t.LOOSEPLAIN] + ")$|^$"; + tok("COMPARATOR"); + src[t.COMPARATOR] = "^" + src[t.GTLT] + "\\s*(" + src[t.FULLPLAIN] + ")$|^$"; + tok("COMPARATORTRIM"); + src[t.COMPARATORTRIM] = "(\\s*)" + src[t.GTLT] + "\\s*(" + src[t.LOOSEPLAIN] + "|" + src[t.XRANGEPLAIN] + ")"; + re[t.COMPARATORTRIM] = new RegExp(src[t.COMPARATORTRIM], "g"); + var comparatorTrimReplace = "$1$2$3"; + tok("HYPHENRANGE"); + src[t.HYPHENRANGE] = "^\\s*(" + src[t.XRANGEPLAIN] + ")\\s+-\\s+(" + src[t.XRANGEPLAIN] + ")\\s*$"; + tok("HYPHENRANGELOOSE"); + src[t.HYPHENRANGELOOSE] = "^\\s*(" + src[t.XRANGEPLAINLOOSE] + ")\\s+-\\s+(" + src[t.XRANGEPLAINLOOSE] + ")\\s*$"; + tok("STAR"); + src[t.STAR] = "(<|>)?=?\\s*\\*"; + for (i = 0; i < R; i++) { + debug(i, src[i]); + if (!re[i]) { + re[i] = new RegExp(src[i]); + } + } + var i; + exports.parse = parse3; + function parse3(version3, options) { + if (!options || typeof options !== "object") { + options = { + loose: !!options, + includePrerelease: false + }; + } + if (version3 instanceof SemVer) { + return version3; + } + if (typeof version3 !== "string") { + return null; + } + if (version3.length > MAX_LENGTH) { + return null; + } + var r = options.loose ? re[t.LOOSE] : re[t.FULL]; + if (!r.test(version3)) { + return null; + } + try { + return new SemVer(version3, options); + } catch (er) { + return null; + } + } + __name(parse3, "parse"); + exports.valid = valid; + function valid(version3, options) { + var v = parse3(version3, options); + return v ? v.version : null; + } + __name(valid, "valid"); + exports.clean = clean; + function clean(version3, options) { + var s = parse3(version3.trim().replace(/^[=v]+/, ""), options); + return s ? s.version : null; + } + __name(clean, "clean"); + exports.SemVer = SemVer; + function SemVer(version3, options) { + if (!options || typeof options !== "object") { + options = { + loose: !!options, + includePrerelease: false + }; + } + if (version3 instanceof SemVer) { + if (version3.loose === options.loose) { + return version3; + } else { + version3 = version3.version; + } + } else if (typeof version3 !== "string") { + throw new TypeError("Invalid Version: " + version3); + } + if (version3.length > MAX_LENGTH) { + throw new TypeError("version is longer than " + MAX_LENGTH + " characters"); + } + if (!(this instanceof SemVer)) { + return new SemVer(version3, options); + } + debug("SemVer", version3, options); + this.options = options; + this.loose = !!options.loose; + var m = version3.trim().match(options.loose ? re[t.LOOSE] : re[t.FULL]); + if (!m) { + throw new TypeError("Invalid Version: " + version3); + } + this.raw = version3; + this.major = +m[1]; + this.minor = +m[2]; + this.patch = +m[3]; + if (this.major > MAX_SAFE_INTEGER || this.major < 0) { + throw new TypeError("Invalid major version"); + } + if (this.minor > MAX_SAFE_INTEGER || this.minor < 0) { + throw new TypeError("Invalid minor version"); + } + if (this.patch > MAX_SAFE_INTEGER || this.patch < 0) { + throw new TypeError("Invalid patch version"); + } + if (!m[4]) { + this.prerelease = []; + } else { + this.prerelease = m[4].split(".").map(function(id) { + if (/^[0-9]+$/.test(id)) { + var num = +id; + if (num >= 0 && num < MAX_SAFE_INTEGER) { + return num; + } + } + return id; + }); + } + this.build = m[5] ? m[5].split(".") : []; + this.format(); + } + __name(SemVer, "SemVer"); + SemVer.prototype.format = function() { + this.version = this.major + "." + this.minor + "." + this.patch; + if (this.prerelease.length) { + this.version += "-" + this.prerelease.join("."); + } + return this.version; + }; + SemVer.prototype.toString = function() { + return this.version; + }; + SemVer.prototype.compare = function(other) { + debug("SemVer.compare", this.version, this.options, other); + if (!(other instanceof SemVer)) { + other = new SemVer(other, this.options); + } + return this.compareMain(other) || this.comparePre(other); + }; + SemVer.prototype.compareMain = function(other) { + if (!(other instanceof SemVer)) { + other = new SemVer(other, this.options); + } + return compareIdentifiers(this.major, other.major) || compareIdentifiers(this.minor, other.minor) || compareIdentifiers(this.patch, other.patch); + }; + SemVer.prototype.comparePre = function(other) { + if (!(other instanceof SemVer)) { + other = new SemVer(other, this.options); + } + if (this.prerelease.length && !other.prerelease.length) { + return -1; + } else if (!this.prerelease.length && other.prerelease.length) { + return 1; + } else if (!this.prerelease.length && !other.prerelease.length) { + return 0; + } + var i2 = 0; + do { + var a = this.prerelease[i2]; + var b = other.prerelease[i2]; + debug("prerelease compare", i2, a, b); + if (a === void 0 && b === void 0) { + return 0; + } else if (b === void 0) { + return 1; + } else if (a === void 0) { + return -1; + } else if (a === b) { + continue; + } else { + return compareIdentifiers(a, b); + } + } while (++i2); + }; + SemVer.prototype.compareBuild = function(other) { + if (!(other instanceof SemVer)) { + other = new SemVer(other, this.options); + } + var i2 = 0; + do { + var a = this.build[i2]; + var b = other.build[i2]; + debug("prerelease compare", i2, a, b); + if (a === void 0 && b === void 0) { + return 0; + } else if (b === void 0) { + return 1; + } else if (a === void 0) { + return -1; + } else if (a === b) { + continue; + } else { + return compareIdentifiers(a, b); + } + } while (++i2); + }; + SemVer.prototype.inc = function(release, identifier) { + switch (release) { + case "premajor": + this.prerelease.length = 0; + this.patch = 0; + this.minor = 0; + this.major++; + this.inc("pre", identifier); + break; + case "preminor": + this.prerelease.length = 0; + this.patch = 0; + this.minor++; + this.inc("pre", identifier); + break; + case "prepatch": + this.prerelease.length = 0; + this.inc("patch", identifier); + this.inc("pre", identifier); + break; + case "prerelease": + if (this.prerelease.length === 0) { + this.inc("patch", identifier); + } + this.inc("pre", identifier); + break; + case "major": + if (this.minor !== 0 || this.patch !== 0 || this.prerelease.length === 0) { + this.major++; + } + this.minor = 0; + this.patch = 0; + this.prerelease = []; + break; + case "minor": + if (this.patch !== 0 || this.prerelease.length === 0) { + this.minor++; + } + this.patch = 0; + this.prerelease = []; + break; + case "patch": + if (this.prerelease.length === 0) { + this.patch++; + } + this.prerelease = []; + break; + case "pre": + if (this.prerelease.length === 0) { + this.prerelease = [0]; + } else { + var i2 = this.prerelease.length; + while (--i2 >= 0) { + if (typeof this.prerelease[i2] === "number") { + this.prerelease[i2]++; + i2 = -2; + } + } + if (i2 === -1) { + this.prerelease.push(0); + } + } + if (identifier) { + if (this.prerelease[0] === identifier) { + if (isNaN(this.prerelease[1])) { + this.prerelease = [identifier, 0]; + } + } else { + this.prerelease = [identifier, 0]; + } + } + break; + default: + throw new Error("invalid increment argument: " + release); + } + this.format(); + this.raw = this.version; + return this; + }; + exports.inc = inc; + function inc(version3, release, loose, identifier) { + if (typeof loose === "string") { + identifier = loose; + loose = void 0; + } + try { + return new SemVer(version3, loose).inc(release, identifier).version; + } catch (er) { + return null; + } + } + __name(inc, "inc"); + exports.diff = diff; + function diff(version1, version22) { + if (eq(version1, version22)) { + return null; + } else { + var v13 = parse3(version1); + var v2 = parse3(version22); + var prefix = ""; + if (v13.prerelease.length || v2.prerelease.length) { + prefix = "pre"; + var defaultResult = "prerelease"; + } + for (var key in v13) { + if (key === "major" || key === "minor" || key === "patch") { + if (v13[key] !== v2[key]) { + return prefix + key; + } + } + } + return defaultResult; + } + } + __name(diff, "diff"); + exports.compareIdentifiers = compareIdentifiers; + var numeric = /^[0-9]+$/; + function compareIdentifiers(a, b) { + var anum = numeric.test(a); + var bnum = numeric.test(b); + if (anum && bnum) { + a = +a; + b = +b; + } + return a === b ? 0 : anum && !bnum ? -1 : bnum && !anum ? 1 : a < b ? -1 : 1; + } + __name(compareIdentifiers, "compareIdentifiers"); + exports.rcompareIdentifiers = rcompareIdentifiers; + function rcompareIdentifiers(a, b) { + return compareIdentifiers(b, a); + } + __name(rcompareIdentifiers, "rcompareIdentifiers"); + exports.major = major; + function major(a, loose) { + return new SemVer(a, loose).major; + } + __name(major, "major"); + exports.minor = minor; + function minor(a, loose) { + return new SemVer(a, loose).minor; + } + __name(minor, "minor"); + exports.patch = patch; + function patch(a, loose) { + return new SemVer(a, loose).patch; + } + __name(patch, "patch"); + exports.compare = compare; + function compare(a, b, loose) { + return new SemVer(a, loose).compare(new SemVer(b, loose)); + } + __name(compare, "compare"); + exports.compareLoose = compareLoose; + function compareLoose(a, b) { + return compare(a, b, true); + } + __name(compareLoose, "compareLoose"); + exports.compareBuild = compareBuild; + function compareBuild(a, b, loose) { + var versionA = new SemVer(a, loose); + var versionB = new SemVer(b, loose); + return versionA.compare(versionB) || versionA.compareBuild(versionB); + } + __name(compareBuild, "compareBuild"); + exports.rcompare = rcompare; + function rcompare(a, b, loose) { + return compare(b, a, loose); + } + __name(rcompare, "rcompare"); + exports.sort = sort; + function sort(list, loose) { + return list.sort(function(a, b) { + return exports.compareBuild(a, b, loose); + }); + } + __name(sort, "sort"); + exports.rsort = rsort; + function rsort(list, loose) { + return list.sort(function(a, b) { + return exports.compareBuild(b, a, loose); + }); + } + __name(rsort, "rsort"); + exports.gt = gt; + function gt(a, b, loose) { + return compare(a, b, loose) > 0; + } + __name(gt, "gt"); + exports.lt = lt; + function lt(a, b, loose) { + return compare(a, b, loose) < 0; + } + __name(lt, "lt"); + exports.eq = eq; + function eq(a, b, loose) { + return compare(a, b, loose) === 0; + } + __name(eq, "eq"); + exports.neq = neq; + function neq(a, b, loose) { + return compare(a, b, loose) !== 0; + } + __name(neq, "neq"); + exports.gte = gte; + function gte(a, b, loose) { + return compare(a, b, loose) >= 0; + } + __name(gte, "gte"); + exports.lte = lte; + function lte(a, b, loose) { + return compare(a, b, loose) <= 0; + } + __name(lte, "lte"); + exports.cmp = cmp; + function cmp(a, op, b, loose) { + switch (op) { + case "===": + if (typeof a === "object") + a = a.version; + if (typeof b === "object") + b = b.version; + return a === b; + case "!==": + if (typeof a === "object") + a = a.version; + if (typeof b === "object") + b = b.version; + return a !== b; + case "": + case "=": + case "==": + return eq(a, b, loose); + case "!=": + return neq(a, b, loose); + case ">": + return gt(a, b, loose); + case ">=": + return gte(a, b, loose); + case "<": + return lt(a, b, loose); + case "<=": + return lte(a, b, loose); + default: + throw new TypeError("Invalid operator: " + op); + } + } + __name(cmp, "cmp"); + exports.Comparator = Comparator; + function Comparator(comp, options) { + if (!options || typeof options !== "object") { + options = { + loose: !!options, + includePrerelease: false + }; + } + if (comp instanceof Comparator) { + if (comp.loose === !!options.loose) { + return comp; + } else { + comp = comp.value; + } + } + if (!(this instanceof Comparator)) { + return new Comparator(comp, options); + } + debug("comparator", comp, options); + this.options = options; + this.loose = !!options.loose; + this.parse(comp); + if (this.semver === ANY) { + this.value = ""; + } else { + this.value = this.operator + this.semver.version; + } + debug("comp", this); + } + __name(Comparator, "Comparator"); + var ANY = {}; + Comparator.prototype.parse = function(comp) { + var r = this.options.loose ? re[t.COMPARATORLOOSE] : re[t.COMPARATOR]; + var m = comp.match(r); + if (!m) { + throw new TypeError("Invalid comparator: " + comp); + } + this.operator = m[1] !== void 0 ? m[1] : ""; + if (this.operator === "=") { + this.operator = ""; + } + if (!m[2]) { + this.semver = ANY; + } else { + this.semver = new SemVer(m[2], this.options.loose); + } + }; + Comparator.prototype.toString = function() { + return this.value; + }; + Comparator.prototype.test = function(version3) { + debug("Comparator.test", version3, this.options.loose); + if (this.semver === ANY || version3 === ANY) { + return true; + } + if (typeof version3 === "string") { + try { + version3 = new SemVer(version3, this.options); + } catch (er) { + return false; + } + } + return cmp(version3, this.operator, this.semver, this.options); + }; + Comparator.prototype.intersects = function(comp, options) { + if (!(comp instanceof Comparator)) { + throw new TypeError("a Comparator is required"); + } + if (!options || typeof options !== "object") { + options = { + loose: !!options, + includePrerelease: false + }; + } + var rangeTmp; + if (this.operator === "") { + if (this.value === "") { + return true; + } + rangeTmp = new Range(comp.value, options); + return satisfies(this.value, rangeTmp, options); + } else if (comp.operator === "") { + if (comp.value === "") { + return true; + } + rangeTmp = new Range(this.value, options); + return satisfies(comp.semver, rangeTmp, options); + } + var sameDirectionIncreasing = (this.operator === ">=" || this.operator === ">") && (comp.operator === ">=" || comp.operator === ">"); + var sameDirectionDecreasing = (this.operator === "<=" || this.operator === "<") && (comp.operator === "<=" || comp.operator === "<"); + var sameSemVer = this.semver.version === comp.semver.version; + var differentDirectionsInclusive = (this.operator === ">=" || this.operator === "<=") && (comp.operator === ">=" || comp.operator === "<="); + var oppositeDirectionsLessThan = cmp(this.semver, "<", comp.semver, options) && ((this.operator === ">=" || this.operator === ">") && (comp.operator === "<=" || comp.operator === "<")); + var oppositeDirectionsGreaterThan = cmp(this.semver, ">", comp.semver, options) && ((this.operator === "<=" || this.operator === "<") && (comp.operator === ">=" || comp.operator === ">")); + return sameDirectionIncreasing || sameDirectionDecreasing || sameSemVer && differentDirectionsInclusive || oppositeDirectionsLessThan || oppositeDirectionsGreaterThan; + }; + exports.Range = Range; + function Range(range, options) { + if (!options || typeof options !== "object") { + options = { + loose: !!options, + includePrerelease: false + }; + } + if (range instanceof Range) { + if (range.loose === !!options.loose && range.includePrerelease === !!options.includePrerelease) { + return range; + } else { + return new Range(range.raw, options); + } + } + if (range instanceof Comparator) { + return new Range(range.value, options); + } + if (!(this instanceof Range)) { + return new Range(range, options); + } + this.options = options; + this.loose = !!options.loose; + this.includePrerelease = !!options.includePrerelease; + this.raw = range; + this.set = range.split(/\s*\|\|\s*/).map(function(range2) { + return this.parseRange(range2.trim()); + }, this).filter(function(c) { + return c.length; + }); + if (!this.set.length) { + throw new TypeError("Invalid SemVer Range: " + range); + } + this.format(); + } + __name(Range, "Range"); + Range.prototype.format = function() { + this.range = this.set.map(function(comps) { + return comps.join(" ").trim(); + }).join("||").trim(); + return this.range; + }; + Range.prototype.toString = function() { + return this.range; + }; + Range.prototype.parseRange = function(range) { + var loose = this.options.loose; + range = range.trim(); + var hr = loose ? re[t.HYPHENRANGELOOSE] : re[t.HYPHENRANGE]; + range = range.replace(hr, hyphenReplace); + debug("hyphen replace", range); + range = range.replace(re[t.COMPARATORTRIM], comparatorTrimReplace); + debug("comparator trim", range, re[t.COMPARATORTRIM]); + range = range.replace(re[t.TILDETRIM], tildeTrimReplace); + range = range.replace(re[t.CARETTRIM], caretTrimReplace); + range = range.split(/\s+/).join(" "); + var compRe = loose ? re[t.COMPARATORLOOSE] : re[t.COMPARATOR]; + var set = range.split(" ").map(function(comp) { + return parseComparator(comp, this.options); + }, this).join(" ").split(/\s+/); + if (this.options.loose) { + set = set.filter(function(comp) { + return !!comp.match(compRe); + }); + } + set = set.map(function(comp) { + return new Comparator(comp, this.options); + }, this); + return set; + }; + Range.prototype.intersects = function(range, options) { + if (!(range instanceof Range)) { + throw new TypeError("a Range is required"); + } + return this.set.some(function(thisComparators) { + return isSatisfiable(thisComparators, options) && range.set.some(function(rangeComparators) { + return isSatisfiable(rangeComparators, options) && thisComparators.every(function(thisComparator) { + return rangeComparators.every(function(rangeComparator) { + return thisComparator.intersects(rangeComparator, options); + }); + }); + }); + }); + }; + function isSatisfiable(comparators, options) { + var result = true; + var remainingComparators = comparators.slice(); + var testComparator = remainingComparators.pop(); + while (result && remainingComparators.length) { + result = remainingComparators.every(function(otherComparator) { + return testComparator.intersects(otherComparator, options); + }); + testComparator = remainingComparators.pop(); + } + return result; + } + __name(isSatisfiable, "isSatisfiable"); + exports.toComparators = toComparators; + function toComparators(range, options) { + return new Range(range, options).set.map(function(comp) { + return comp.map(function(c) { + return c.value; + }).join(" ").trim().split(" "); + }); + } + __name(toComparators, "toComparators"); + function parseComparator(comp, options) { + debug("comp", comp, options); + comp = replaceCarets(comp, options); + debug("caret", comp); + comp = replaceTildes(comp, options); + debug("tildes", comp); + comp = replaceXRanges(comp, options); + debug("xrange", comp); + comp = replaceStars(comp, options); + debug("stars", comp); + return comp; + } + __name(parseComparator, "parseComparator"); + function isX(id) { + return !id || id.toLowerCase() === "x" || id === "*"; + } + __name(isX, "isX"); + function replaceTildes(comp, options) { + return comp.trim().split(/\s+/).map(function(comp2) { + return replaceTilde(comp2, options); + }).join(" "); + } + __name(replaceTildes, "replaceTildes"); + function replaceTilde(comp, options) { + var r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE]; + return comp.replace(r, function(_, M, m, p, pr) { + debug("tilde", comp, _, M, m, p, pr); + var ret; + if (isX(M)) { + ret = ""; + } else if (isX(m)) { + ret = ">=" + M + ".0.0 <" + (+M + 1) + ".0.0"; + } else if (isX(p)) { + ret = ">=" + M + "." + m + ".0 <" + M + "." + (+m + 1) + ".0"; + } else if (pr) { + debug("replaceTilde pr", pr); + ret = ">=" + M + "." + m + "." + p + "-" + pr + " <" + M + "." + (+m + 1) + ".0"; + } else { + ret = ">=" + M + "." + m + "." + p + " <" + M + "." + (+m + 1) + ".0"; + } + debug("tilde return", ret); + return ret; + }); + } + __name(replaceTilde, "replaceTilde"); + function replaceCarets(comp, options) { + return comp.trim().split(/\s+/).map(function(comp2) { + return replaceCaret(comp2, options); + }).join(" "); + } + __name(replaceCarets, "replaceCarets"); + function replaceCaret(comp, options) { + debug("caret", comp, options); + var r = options.loose ? re[t.CARETLOOSE] : re[t.CARET]; + return comp.replace(r, function(_, M, m, p, pr) { + debug("caret", comp, _, M, m, p, pr); + var ret; + if (isX(M)) { + ret = ""; + } else if (isX(m)) { + ret = ">=" + M + ".0.0 <" + (+M + 1) + ".0.0"; + } else if (isX(p)) { + if (M === "0") { + ret = ">=" + M + "." + m + ".0 <" + M + "." + (+m + 1) + ".0"; + } else { + ret = ">=" + M + "." + m + ".0 <" + (+M + 1) + ".0.0"; + } + } else if (pr) { + debug("replaceCaret pr", pr); + if (M === "0") { + if (m === "0") { + ret = ">=" + M + "." + m + "." + p + "-" + pr + " <" + M + "." + m + "." + (+p + 1); + } else { + ret = ">=" + M + "." + m + "." + p + "-" + pr + " <" + M + "." + (+m + 1) + ".0"; + } + } else { + ret = ">=" + M + "." + m + "." + p + "-" + pr + " <" + (+M + 1) + ".0.0"; + } + } else { + debug("no pr"); + if (M === "0") { + if (m === "0") { + ret = ">=" + M + "." + m + "." + p + " <" + M + "." + m + "." + (+p + 1); + } else { + ret = ">=" + M + "." + m + "." + p + " <" + M + "." + (+m + 1) + ".0"; + } + } else { + ret = ">=" + M + "." + m + "." + p + " <" + (+M + 1) + ".0.0"; + } + } + debug("caret return", ret); + return ret; + }); + } + __name(replaceCaret, "replaceCaret"); + function replaceXRanges(comp, options) { + debug("replaceXRanges", comp, options); + return comp.split(/\s+/).map(function(comp2) { + return replaceXRange(comp2, options); + }).join(" "); + } + __name(replaceXRanges, "replaceXRanges"); + function replaceXRange(comp, options) { + comp = comp.trim(); + var r = options.loose ? re[t.XRANGELOOSE] : re[t.XRANGE]; + return comp.replace(r, function(ret, gtlt, M, m, p, pr) { + debug("xRange", comp, ret, gtlt, M, m, p, pr); + var xM = isX(M); + var xm = xM || isX(m); + var xp = xm || isX(p); + var anyX = xp; + if (gtlt === "=" && anyX) { + gtlt = ""; + } + pr = options.includePrerelease ? "-0" : ""; + if (xM) { + if (gtlt === ">" || gtlt === "<") { + ret = "<0.0.0-0"; + } else { + ret = "*"; + } + } else if (gtlt && anyX) { + if (xm) { + m = 0; + } + p = 0; + if (gtlt === ">") { + gtlt = ">="; + if (xm) { + M = +M + 1; + m = 0; + p = 0; + } else { + m = +m + 1; + p = 0; + } + } else if (gtlt === "<=") { + gtlt = "<"; + if (xm) { + M = +M + 1; + } else { + m = +m + 1; + } + } + ret = gtlt + M + "." + m + "." + p + pr; + } else if (xm) { + ret = ">=" + M + ".0.0" + pr + " <" + (+M + 1) + ".0.0" + pr; + } else if (xp) { + ret = ">=" + M + "." + m + ".0" + pr + " <" + M + "." + (+m + 1) + ".0" + pr; + } + debug("xRange return", ret); + return ret; + }); + } + __name(replaceXRange, "replaceXRange"); + function replaceStars(comp, options) { + debug("replaceStars", comp, options); + return comp.trim().replace(re[t.STAR], ""); + } + __name(replaceStars, "replaceStars"); + function hyphenReplace($0, from, fM, fm, fp, fpr, fb, to, tM, tm, tp, tpr, tb) { + if (isX(fM)) { + from = ""; + } else if (isX(fm)) { + from = ">=" + fM + ".0.0"; + } else if (isX(fp)) { + from = ">=" + fM + "." + fm + ".0"; + } else { + from = ">=" + from; + } + if (isX(tM)) { + to = ""; + } else if (isX(tm)) { + to = "<" + (+tM + 1) + ".0.0"; + } else if (isX(tp)) { + to = "<" + tM + "." + (+tm + 1) + ".0"; + } else if (tpr) { + to = "<=" + tM + "." + tm + "." + tp + "-" + tpr; + } else { + to = "<=" + to; + } + return (from + " " + to).trim(); + } + __name(hyphenReplace, "hyphenReplace"); + Range.prototype.test = function(version3) { + if (!version3) { + return false; + } + if (typeof version3 === "string") { + try { + version3 = new SemVer(version3, this.options); + } catch (er) { + return false; + } + } + for (var i2 = 0; i2 < this.set.length; i2++) { + if (testSet(this.set[i2], version3, this.options)) { + return true; + } + } + return false; + }; + function testSet(set, version3, options) { + for (var i2 = 0; i2 < set.length; i2++) { + if (!set[i2].test(version3)) { + return false; + } + } + if (version3.prerelease.length && !options.includePrerelease) { + for (i2 = 0; i2 < set.length; i2++) { + debug(set[i2].semver); + if (set[i2].semver === ANY) { + continue; + } + if (set[i2].semver.prerelease.length > 0) { + var allowed = set[i2].semver; + if (allowed.major === version3.major && allowed.minor === version3.minor && allowed.patch === version3.patch) { + return true; + } + } + } + return false; + } + return true; + } + __name(testSet, "testSet"); + exports.satisfies = satisfies; + function satisfies(version3, range, options) { + try { + range = new Range(range, options); + } catch (er) { + return false; + } + return range.test(version3); + } + __name(satisfies, "satisfies"); + exports.maxSatisfying = maxSatisfying; + function maxSatisfying(versions, range, options) { + var max = null; + var maxSV = null; + try { + var rangeObj = new Range(range, options); + } catch (er) { + return null; + } + versions.forEach(function(v) { + if (rangeObj.test(v)) { + if (!max || maxSV.compare(v) === -1) { + max = v; + maxSV = new SemVer(max, options); + } + } + }); + return max; + } + __name(maxSatisfying, "maxSatisfying"); + exports.minSatisfying = minSatisfying; + function minSatisfying(versions, range, options) { + var min = null; + var minSV = null; + try { + var rangeObj = new Range(range, options); + } catch (er) { + return null; + } + versions.forEach(function(v) { + if (rangeObj.test(v)) { + if (!min || minSV.compare(v) === 1) { + min = v; + minSV = new SemVer(min, options); + } + } + }); + return min; + } + __name(minSatisfying, "minSatisfying"); + exports.minVersion = minVersion; + function minVersion(range, loose) { + range = new Range(range, loose); + var minver = new SemVer("0.0.0"); + if (range.test(minver)) { + return minver; + } + minver = new SemVer("0.0.0-0"); + if (range.test(minver)) { + return minver; + } + minver = null; + for (var i2 = 0; i2 < range.set.length; ++i2) { + var comparators = range.set[i2]; + comparators.forEach(function(comparator) { + var compver = new SemVer(comparator.semver.version); + switch (comparator.operator) { + case ">": + if (compver.prerelease.length === 0) { + compver.patch++; + } else { + compver.prerelease.push(0); + } + compver.raw = compver.format(); + case "": + case ">=": + if (!minver || gt(minver, compver)) { + minver = compver; + } + break; + case "<": + case "<=": + break; + default: + throw new Error("Unexpected operation: " + comparator.operator); + } + }); + } + if (minver && range.test(minver)) { + return minver; + } + return null; + } + __name(minVersion, "minVersion"); + exports.validRange = validRange; + function validRange(range, options) { + try { + return new Range(range, options).range || "*"; + } catch (er) { + return null; + } + } + __name(validRange, "validRange"); + exports.ltr = ltr; + function ltr(version3, range, options) { + return outside(version3, range, "<", options); + } + __name(ltr, "ltr"); + exports.gtr = gtr; + function gtr(version3, range, options) { + return outside(version3, range, ">", options); + } + __name(gtr, "gtr"); + exports.outside = outside; + function outside(version3, range, hilo, options) { + version3 = new SemVer(version3, options); + range = new Range(range, options); + var gtfn, ltefn, ltfn, comp, ecomp; + switch (hilo) { + case ">": + gtfn = gt; + ltefn = lte; + ltfn = lt; + comp = ">"; + ecomp = ">="; + break; + case "<": + gtfn = lt; + ltefn = gte; + ltfn = gt; + comp = "<"; + ecomp = "<="; + break; + default: + throw new TypeError('Must provide a hilo val of "<" or ">"'); + } + if (satisfies(version3, range, options)) { + return false; + } + for (var i2 = 0; i2 < range.set.length; ++i2) { + var comparators = range.set[i2]; + var high = null; + var low = null; + comparators.forEach(function(comparator) { + if (comparator.semver === ANY) { + comparator = new Comparator(">=0.0.0"); + } + high = high || comparator; + low = low || comparator; + if (gtfn(comparator.semver, high.semver, options)) { + high = comparator; + } else if (ltfn(comparator.semver, low.semver, options)) { + low = comparator; + } + }); + if (high.operator === comp || high.operator === ecomp) { + return false; + } + if ((!low.operator || low.operator === comp) && ltefn(version3, low.semver)) { + return false; + } else if (low.operator === ecomp && ltfn(version3, low.semver)) { + return false; + } + } + return true; + } + __name(outside, "outside"); + exports.prerelease = prerelease; + function prerelease(version3, options) { + var parsed = parse3(version3, options); + return parsed && parsed.prerelease.length ? parsed.prerelease : null; + } + __name(prerelease, "prerelease"); + exports.intersects = intersects; + function intersects(r1, r2, options) { + r1 = new Range(r1, options); + r2 = new Range(r2, options); + return r1.intersects(r2); + } + __name(intersects, "intersects"); + exports.coerce = coerce; + function coerce(version3, options) { + if (version3 instanceof SemVer) { + return version3; + } + if (typeof version3 === "number") { + version3 = String(version3); + } + if (typeof version3 !== "string") { + return null; + } + options = options || {}; + var match = null; + if (!options.rtl) { + match = version3.match(re[t.COERCE]); + } else { + var next; + while ((next = re[t.COERCERTL].exec(version3)) && (!match || match.index + match[0].length !== version3.length)) { + if (!match || next.index + next[0].length !== match.index + match[0].length) { + match = next; + } + re[t.COERCERTL].lastIndex = next.index + next[1].length + next[2].length; + } + re[t.COERCERTL].lastIndex = -1; + } + if (match === null) { + return null; + } + return parse3(match[2] + "." + (match[3] || "0") + "." + (match[4] || "0"), options); + } + __name(coerce, "coerce"); + } +}); + +// node_modules/uuid/lib/rng.js +var require_rng = __commonJS({ + "node_modules/uuid/lib/rng.js"(exports, module2) { + var crypto7 = require("crypto"); + module2.exports = /* @__PURE__ */ __name(function nodeRNG() { + return crypto7.randomBytes(16); + }, "nodeRNG"); + } +}); + +// node_modules/uuid/lib/bytesToUuid.js +var require_bytesToUuid = __commonJS({ + "node_modules/uuid/lib/bytesToUuid.js"(exports, module2) { + var byteToHex3 = []; + for (i = 0; i < 256; ++i) { + byteToHex3[i] = (i + 256).toString(16).substr(1); + } + var i; + function bytesToUuid(buf, offset) { + var i2 = offset || 0; + var bth = byteToHex3; + return [ + bth[buf[i2++]], + bth[buf[i2++]], + bth[buf[i2++]], + bth[buf[i2++]], + "-", + bth[buf[i2++]], + bth[buf[i2++]], + "-", + bth[buf[i2++]], + bth[buf[i2++]], + "-", + bth[buf[i2++]], + bth[buf[i2++]], + "-", + bth[buf[i2++]], + bth[buf[i2++]], + bth[buf[i2++]], + bth[buf[i2++]], + bth[buf[i2++]], + bth[buf[i2++]] + ].join(""); + } + __name(bytesToUuid, "bytesToUuid"); + module2.exports = bytesToUuid; + } +}); + +// node_modules/uuid/v1.js +var require_v1 = __commonJS({ + "node_modules/uuid/v1.js"(exports, module2) { + var rng3 = require_rng(); + var bytesToUuid = require_bytesToUuid(); + var _nodeId3; + var _clockseq3; + var _lastMSecs3 = 0; + var _lastNSecs3 = 0; + function v13(options, buf, offset) { + var i = buf && offset || 0; + var b = buf || []; + options = options || {}; + var node = options.node || _nodeId3; + var clockseq = options.clockseq !== void 0 ? options.clockseq : _clockseq3; + if (node == null || clockseq == null) { + var seedBytes = rng3(); + if (node == null) { + node = _nodeId3 = [ + seedBytes[0] | 1, + seedBytes[1], + seedBytes[2], + seedBytes[3], + seedBytes[4], + seedBytes[5] + ]; + } + if (clockseq == null) { + clockseq = _clockseq3 = (seedBytes[6] << 8 | seedBytes[7]) & 16383; + } + } + var msecs = options.msecs !== void 0 ? options.msecs : (/* @__PURE__ */ new Date()).getTime(); + var nsecs = options.nsecs !== void 0 ? options.nsecs : _lastNSecs3 + 1; + var dt = msecs - _lastMSecs3 + (nsecs - _lastNSecs3) / 1e4; + if (dt < 0 && options.clockseq === void 0) { + clockseq = clockseq + 1 & 16383; + } + if ((dt < 0 || msecs > _lastMSecs3) && options.nsecs === void 0) { + nsecs = 0; + } + if (nsecs >= 1e4) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + _lastMSecs3 = msecs; + _lastNSecs3 = nsecs; + _clockseq3 = clockseq; + msecs += 122192928e5; + var tl = ((msecs & 268435455) * 1e4 + nsecs) % 4294967296; + b[i++] = tl >>> 24 & 255; + b[i++] = tl >>> 16 & 255; + b[i++] = tl >>> 8 & 255; + b[i++] = tl & 255; + var tmh = msecs / 4294967296 * 1e4 & 268435455; + b[i++] = tmh >>> 8 & 255; + b[i++] = tmh & 255; + b[i++] = tmh >>> 24 & 15 | 16; + b[i++] = tmh >>> 16 & 255; + b[i++] = clockseq >>> 8 | 128; + b[i++] = clockseq & 255; + for (var n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + return buf ? buf : bytesToUuid(b); + } + __name(v13, "v1"); + module2.exports = v13; + } +}); + +// node_modules/uuid/v4.js +var require_v4 = __commonJS({ + "node_modules/uuid/v4.js"(exports, module2) { + var rng3 = require_rng(); + var bytesToUuid = require_bytesToUuid(); + function v43(options, buf, offset) { + var i = buf && offset || 0; + if (typeof options == "string") { + buf = options === "binary" ? new Array(16) : null; + options = null; + } + options = options || {}; + var rnds = options.random || (options.rng || rng3)(); + rnds[6] = rnds[6] & 15 | 64; + rnds[8] = rnds[8] & 63 | 128; + if (buf) { + for (var ii = 0; ii < 16; ++ii) { + buf[i + ii] = rnds[ii]; + } + } + return buf || bytesToUuid(rnds); + } + __name(v43, "v4"); + module2.exports = v43; + } +}); + +// node_modules/uuid/index.js +var require_uuid = __commonJS({ + "node_modules/uuid/index.js"(exports, module2) { + var v13 = require_v1(); + var v43 = require_v4(); + var uuid = v43; + uuid.v1 = v13; + uuid.v4 = v43; + module2.exports = uuid; + } +}); + +// node_modules/@actions/cache/lib/internal/constants.js +var require_constants2 = __commonJS({ + "node_modules/@actions/cache/lib/internal/constants.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.ManifestFilename = exports.TarFilename = exports.SystemTarPathOnWindows = exports.GnuTarPathOnWindows = exports.SocketTimeout = exports.DefaultRetryDelay = exports.DefaultRetryAttempts = exports.ArchiveToolType = exports.CompressionMethod = exports.CacheFilename = void 0; + var CacheFilename; + (function(CacheFilename2) { + CacheFilename2["Gzip"] = "cache.tgz"; + CacheFilename2["Zstd"] = "cache.tzst"; + })(CacheFilename = exports.CacheFilename || (exports.CacheFilename = {})); + var CompressionMethod; + (function(CompressionMethod2) { + CompressionMethod2["Gzip"] = "gzip"; + CompressionMethod2["ZstdWithoutLong"] = "zstd-without-long"; + CompressionMethod2["Zstd"] = "zstd"; + })(CompressionMethod = exports.CompressionMethod || (exports.CompressionMethod = {})); + var ArchiveToolType; + (function(ArchiveToolType2) { + ArchiveToolType2["GNU"] = "gnu"; + ArchiveToolType2["BSD"] = "bsd"; + })(ArchiveToolType = exports.ArchiveToolType || (exports.ArchiveToolType = {})); + exports.DefaultRetryAttempts = 2; + exports.DefaultRetryDelay = 5e3; + exports.SocketTimeout = 5e3; + exports.GnuTarPathOnWindows = `${process.env["PROGRAMFILES"]}\\Git\\usr\\bin\\tar.exe`; + exports.SystemTarPathOnWindows = `${process.env["SYSTEMDRIVE"]}\\Windows\\System32\\tar.exe`; + exports.TarFilename = "cache.tar"; + exports.ManifestFilename = "manifest.txt"; + } +}); + +// node_modules/@actions/cache/lib/internal/cacheUtils.js +var require_cacheUtils = __commonJS({ + "node_modules/@actions/cache/lib/internal/cacheUtils.js"(exports) { + "use strict"; + var __createBinding2 = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { + return m[k]; + } }; + } + Object.defineProperty(o, k2, desc); + } : function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + o[k2] = m[k]; + }); + var __setModuleDefault2 = exports && exports.__setModuleDefault || (Object.create ? function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); + } : function(o, v) { + o["default"] = v; + }); + var __importStar2 = exports && exports.__importStar || function(mod) { + if (mod && mod.__esModule) + return mod; + var result = {}; + if (mod != null) { + for (var k in mod) + if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) + __createBinding2(result, mod, k); + } + __setModuleDefault2(result, mod); + return result; + }; + var __awaiter2 = exports && exports.__awaiter || function(thisArg, _arguments, P, generator) { + function adopt(value) { + return value instanceof P ? value : new P(function(resolve) { + resolve(value); + }); + } + __name(adopt, "adopt"); + return new (P || (P = Promise))(function(resolve, reject) { + function fulfilled(value) { + try { + step(generator.next(value)); + } catch (e) { + reject(e); + } + } + __name(fulfilled, "fulfilled"); + function rejected(value) { + try { + step(generator["throw"](value)); + } catch (e) { + reject(e); + } + } + __name(rejected, "rejected"); + function step(result) { + result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); + } + __name(step, "step"); + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); + }; + var __asyncValues2 = exports && exports.__asyncValues || function(o) { + if (!Symbol.asyncIterator) + throw new TypeError("Symbol.asyncIterator is not defined."); + var m = o[Symbol.asyncIterator], i; + return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() { + return this; + }, i); + function verb(n) { + i[n] = o[n] && function(v) { + return new Promise(function(resolve, reject) { + v = o[n](v), settle(resolve, reject, v.done, v.value); + }); + }; + } + __name(verb, "verb"); + function settle(resolve, reject, d, v) { + Promise.resolve(v).then(function(v2) { + resolve({ value: v2, done: d }); + }, reject); + } + __name(settle, "settle"); + }; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.isGhes = exports.assertDefined = exports.getGnuTarPathOnWindows = exports.getCacheFileName = exports.getCompressionMethod = exports.unlinkFile = exports.resolvePaths = exports.getArchiveFileSizeInBytes = exports.createTempDirectory = void 0; + var core = __importStar2(require_core()); + var exec = __importStar2(require_exec()); + var glob = __importStar2(require_glob()); + var io = __importStar2(require_io()); + var fs = __importStar2(require("fs")); + var path2 = __importStar2(require("path")); + var semver2 = __importStar2(require_semver3()); + var util = __importStar2(require("util")); + var uuid_1 = require_uuid(); + var constants_1 = require_constants2(); + function createTempDirectory() { + return __awaiter2(this, void 0, void 0, function* () { + const IS_WINDOWS = process.platform === "win32"; + let tempDirectory = process.env["RUNNER_TEMP"] || ""; + if (!tempDirectory) { + let baseLocation; + if (IS_WINDOWS) { + baseLocation = process.env["USERPROFILE"] || "C:\\"; + } else { + if (process.platform === "darwin") { + baseLocation = "/Users"; + } else { + baseLocation = "/home"; + } + } + tempDirectory = path2.join(baseLocation, "actions", "temp"); + } + const dest = path2.join(tempDirectory, (0, uuid_1.v4)()); + yield io.mkdirP(dest); + return dest; + }); + } + __name(createTempDirectory, "createTempDirectory"); + exports.createTempDirectory = createTempDirectory; + function getArchiveFileSizeInBytes(filePath) { + return fs.statSync(filePath).size; + } + __name(getArchiveFileSizeInBytes, "getArchiveFileSizeInBytes"); + exports.getArchiveFileSizeInBytes = getArchiveFileSizeInBytes; + function resolvePaths(patterns) { + var e_1, _a; + var _b; + return __awaiter2(this, void 0, void 0, function* () { + const paths = []; + const workspace = (_b = process.env["GITHUB_WORKSPACE"]) !== null && _b !== void 0 ? _b : process.cwd(); + const globber = yield glob.create(patterns.join("\n"), { + implicitDescendants: false + }); + try { + for (var _c = __asyncValues2(globber.globGenerator()), _d; _d = yield _c.next(), !_d.done; ) { + const file = _d.value; + const relativeFile = path2.relative(workspace, file).replace(new RegExp(`\\${path2.sep}`, "g"), "/"); + core.debug(`Matched: ${relativeFile}`); + if (relativeFile === "") { + paths.push("."); + } else { + paths.push(`${relativeFile}`); + } + } + } catch (e_1_1) { + e_1 = { error: e_1_1 }; + } finally { + try { + if (_d && !_d.done && (_a = _c.return)) + yield _a.call(_c); + } finally { + if (e_1) + throw e_1.error; + } + } + return paths; + }); + } + __name(resolvePaths, "resolvePaths"); + exports.resolvePaths = resolvePaths; + function unlinkFile(filePath) { + return __awaiter2(this, void 0, void 0, function* () { + return util.promisify(fs.unlink)(filePath); + }); + } + __name(unlinkFile, "unlinkFile"); + exports.unlinkFile = unlinkFile; + function getVersion(app, additionalArgs = []) { + return __awaiter2(this, void 0, void 0, function* () { + let versionOutput = ""; + additionalArgs.push("--version"); + core.debug(`Checking ${app} ${additionalArgs.join(" ")}`); + try { + yield exec.exec(`${app}`, additionalArgs, { + ignoreReturnCode: true, + silent: true, + listeners: { + stdout: (data) => versionOutput += data.toString(), + stderr: (data) => versionOutput += data.toString() + } + }); + } catch (err) { + core.debug(err.message); + } + versionOutput = versionOutput.trim(); + core.debug(versionOutput); + return versionOutput; + }); + } + __name(getVersion, "getVersion"); + function getCompressionMethod() { + return __awaiter2(this, void 0, void 0, function* () { + const versionOutput = yield getVersion("zstd", ["--quiet"]); + const version3 = semver2.clean(versionOutput); + core.debug(`zstd version: ${version3}`); + if (versionOutput === "") { + return constants_1.CompressionMethod.Gzip; + } else { + return constants_1.CompressionMethod.ZstdWithoutLong; + } + }); + } + __name(getCompressionMethod, "getCompressionMethod"); + exports.getCompressionMethod = getCompressionMethod; + function getCacheFileName(compressionMethod) { + return compressionMethod === constants_1.CompressionMethod.Gzip ? constants_1.CacheFilename.Gzip : constants_1.CacheFilename.Zstd; + } + __name(getCacheFileName, "getCacheFileName"); + exports.getCacheFileName = getCacheFileName; + function getGnuTarPathOnWindows() { + return __awaiter2(this, void 0, void 0, function* () { + if (fs.existsSync(constants_1.GnuTarPathOnWindows)) { + return constants_1.GnuTarPathOnWindows; + } + const versionOutput = yield getVersion("tar"); + return versionOutput.toLowerCase().includes("gnu tar") ? io.which("tar") : ""; + }); + } + __name(getGnuTarPathOnWindows, "getGnuTarPathOnWindows"); + exports.getGnuTarPathOnWindows = getGnuTarPathOnWindows; + function assertDefined(name, value) { + if (value === void 0) { + throw Error(`Expected ${name} but value was undefiend`); + } + return value; + } + __name(assertDefined, "assertDefined"); + exports.assertDefined = assertDefined; + function isGhes() { + const ghUrl = new URL(process.env["GITHUB_SERVER_URL"] || "https://github.com"); + return ghUrl.hostname.toUpperCase() !== "GITHUB.COM"; + } + __name(isGhes, "isGhes"); + exports.isGhes = isGhes; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/rng.js +function rng2() { + if (poolPtr2 > rnds8Pool2.length - 16) { + import_crypto4.default.randomFillSync(rnds8Pool2); + poolPtr2 = 0; + } + return rnds8Pool2.slice(poolPtr2, poolPtr2 += 16); +} +var import_crypto4, rnds8Pool2, poolPtr2; +var init_rng2 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/rng.js"() { + import_crypto4 = __toESM(require("crypto")); + rnds8Pool2 = new Uint8Array(256); + poolPtr2 = rnds8Pool2.length; + __name(rng2, "rng"); + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/regex.js +var regex_default2; +var init_regex2 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/regex.js"() { + regex_default2 = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/validate.js +function validate2(uuid) { + return typeof uuid === "string" && regex_default2.test(uuid); +} +var validate_default2; +var init_validate2 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/validate.js"() { + init_regex2(); + __name(validate2, "validate"); + validate_default2 = validate2; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/stringify.js +function stringify2(arr, offset = 0) { + const uuid = (byteToHex2[arr[offset + 0]] + byteToHex2[arr[offset + 1]] + byteToHex2[arr[offset + 2]] + byteToHex2[arr[offset + 3]] + "-" + byteToHex2[arr[offset + 4]] + byteToHex2[arr[offset + 5]] + "-" + byteToHex2[arr[offset + 6]] + byteToHex2[arr[offset + 7]] + "-" + byteToHex2[arr[offset + 8]] + byteToHex2[arr[offset + 9]] + "-" + byteToHex2[arr[offset + 10]] + byteToHex2[arr[offset + 11]] + byteToHex2[arr[offset + 12]] + byteToHex2[arr[offset + 13]] + byteToHex2[arr[offset + 14]] + byteToHex2[arr[offset + 15]]).toLowerCase(); + if (!validate_default2(uuid)) { + throw TypeError("Stringified UUID is invalid"); + } + return uuid; +} +var byteToHex2, stringify_default2; +var init_stringify2 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/stringify.js"() { + init_validate2(); + byteToHex2 = []; + for (let i = 0; i < 256; ++i) { + byteToHex2.push((i + 256).toString(16).substr(1)); + } + __name(stringify2, "stringify"); + stringify_default2 = stringify2; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v1.js +function v12(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId2; + let clockseq = options.clockseq !== void 0 ? options.clockseq : _clockseq2; + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng2)(); + if (node == null) { + node = _nodeId2 = [seedBytes[0] | 1, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + if (clockseq == null) { + clockseq = _clockseq2 = (seedBytes[6] << 8 | seedBytes[7]) & 16383; + } + } + let msecs = options.msecs !== void 0 ? options.msecs : Date.now(); + let nsecs = options.nsecs !== void 0 ? options.nsecs : _lastNSecs2 + 1; + const dt = msecs - _lastMSecs2 + (nsecs - _lastNSecs2) / 1e4; + if (dt < 0 && options.clockseq === void 0) { + clockseq = clockseq + 1 & 16383; + } + if ((dt < 0 || msecs > _lastMSecs2) && options.nsecs === void 0) { + nsecs = 0; + } + if (nsecs >= 1e4) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + _lastMSecs2 = msecs; + _lastNSecs2 = nsecs; + _clockseq2 = clockseq; + msecs += 122192928e5; + const tl = ((msecs & 268435455) * 1e4 + nsecs) % 4294967296; + b[i++] = tl >>> 24 & 255; + b[i++] = tl >>> 16 & 255; + b[i++] = tl >>> 8 & 255; + b[i++] = tl & 255; + const tmh = msecs / 4294967296 * 1e4 & 268435455; + b[i++] = tmh >>> 8 & 255; + b[i++] = tmh & 255; + b[i++] = tmh >>> 24 & 15 | 16; + b[i++] = tmh >>> 16 & 255; + b[i++] = clockseq >>> 8 | 128; + b[i++] = clockseq & 255; + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + return buf || stringify_default2(b); +} +var _nodeId2, _clockseq2, _lastMSecs2, _lastNSecs2, v1_default2; +var init_v12 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v1.js"() { + init_rng2(); + init_stringify2(); + _lastMSecs2 = 0; + _lastNSecs2 = 0; + __name(v12, "v1"); + v1_default2 = v12; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/parse.js +function parse2(uuid) { + if (!validate_default2(uuid)) { + throw TypeError("Invalid UUID"); + } + let v; + const arr = new Uint8Array(16); + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 255; + arr[2] = v >>> 8 & 255; + arr[3] = v & 255; + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 255; + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 255; + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 255; + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 1099511627776 & 255; + arr[11] = v / 4294967296 & 255; + arr[12] = v >>> 24 & 255; + arr[13] = v >>> 16 & 255; + arr[14] = v >>> 8 & 255; + arr[15] = v & 255; + return arr; +} +var parse_default2; +var init_parse2 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/parse.js"() { + init_validate2(); + __name(parse2, "parse"); + parse_default2 = parse2; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v35.js +function stringToBytes2(str) { + str = unescape(encodeURIComponent(str)); + const bytes = []; + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + return bytes; +} +function v35_default2(name, version3, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === "string") { + value = stringToBytes2(value); + } + if (typeof namespace === "string") { + namespace = parse_default2(namespace); + } + if (namespace.length !== 16) { + throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)"); + } + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 15 | version3; + bytes[8] = bytes[8] & 63 | 128; + if (buf) { + offset = offset || 0; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + return buf; + } + return stringify_default2(bytes); + } + __name(generateUUID, "generateUUID"); + try { + generateUUID.name = name; + } catch (err) { + } + generateUUID.DNS = DNS2; + generateUUID.URL = URL3; + return generateUUID; +} +var DNS2, URL3; +var init_v352 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v35.js"() { + init_stringify2(); + init_parse2(); + __name(stringToBytes2, "stringToBytes"); + DNS2 = "6ba7b810-9dad-11d1-80b4-00c04fd430c8"; + URL3 = "6ba7b811-9dad-11d1-80b4-00c04fd430c8"; + __name(v35_default2, "default"); + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/md5.js +function md52(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === "string") { + bytes = Buffer.from(bytes, "utf8"); + } + return import_crypto5.default.createHash("md5").update(bytes).digest(); +} +var import_crypto5, md5_default2; +var init_md52 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/md5.js"() { + import_crypto5 = __toESM(require("crypto")); + __name(md52, "md5"); + md5_default2 = md52; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v3.js +var v32, v3_default2; +var init_v32 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v3.js"() { + init_v352(); + init_md52(); + v32 = v35_default2("v3", 48, md5_default2); + v3_default2 = v32; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v4.js +function v42(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng2)(); + rnds[6] = rnds[6] & 15 | 64; + rnds[8] = rnds[8] & 63 | 128; + if (buf) { + offset = offset || 0; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; + } + return buf; + } + return stringify_default2(rnds); +} +var v4_default2; +var init_v42 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v4.js"() { + init_rng2(); + init_stringify2(); + __name(v42, "v4"); + v4_default2 = v42; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/sha1.js +function sha12(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === "string") { + bytes = Buffer.from(bytes, "utf8"); + } + return import_crypto6.default.createHash("sha1").update(bytes).digest(); +} +var import_crypto6, sha1_default2; +var init_sha12 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/sha1.js"() { + import_crypto6 = __toESM(require("crypto")); + __name(sha12, "sha1"); + sha1_default2 = sha12; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v5.js +var v52, v5_default2; +var init_v52 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/v5.js"() { + init_v352(); + init_sha12(); + v52 = v35_default2("v5", 80, sha1_default2); + v5_default2 = v52; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/nil.js +var nil_default2; +var init_nil2 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/nil.js"() { + nil_default2 = "00000000-0000-0000-0000-000000000000"; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/version.js +function version2(uuid) { + if (!validate_default2(uuid)) { + throw TypeError("Invalid UUID"); + } + return parseInt(uuid.substr(14, 1), 16); +} +var version_default2; +var init_version2 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/version.js"() { + init_validate2(); + __name(version2, "version"); + version_default2 = version2; + } +}); + +// node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/index.js +var esm_node_exports2 = {}; +__export(esm_node_exports2, { + NIL: () => nil_default2, + parse: () => parse_default2, + stringify: () => stringify_default2, + v1: () => v1_default2, + v3: () => v3_default2, + v4: () => v4_default2, + v5: () => v5_default2, + validate: () => validate_default2, + version: () => version_default2 +}); +var init_esm_node2 = __esm({ + "node_modules/@azure/core-http/node_modules/uuid/dist/esm-node/index.js"() { + init_v12(); + init_v32(); + init_v42(); + init_v52(); + init_nil2(); + init_version2(); + init_validate2(); + init_stringify2(); + init_parse2(); + } +}); + +// node_modules/tslib/tslib.es6.mjs +var tslib_es6_exports = {}; +__export(tslib_es6_exports, { + __assign: () => __assign, + __asyncDelegator: () => __asyncDelegator, + __asyncGenerator: () => __asyncGenerator, + __asyncValues: () => __asyncValues, + __await: () => __await, + __awaiter: () => __awaiter, + __classPrivateFieldGet: () => __classPrivateFieldGet, + __classPrivateFieldIn: () => __classPrivateFieldIn, + __classPrivateFieldSet: () => __classPrivateFieldSet, + __createBinding: () => __createBinding, + __decorate: () => __decorate, + __esDecorate: () => __esDecorate, + __exportStar: () => __exportStar, + __extends: () => __extends, + __generator: () => __generator, + __importDefault: () => __importDefault, + __importStar: () => __importStar, + __makeTemplateObject: () => __makeTemplateObject, + __metadata: () => __metadata, + __param: () => __param, + __propKey: () => __propKey, + __read: () => __read, + __rest: () => __rest, + __runInitializers: () => __runInitializers, + __setFunctionName: () => __setFunctionName, + __spread: () => __spread, + __spreadArray: () => __spreadArray, + __spreadArrays: () => __spreadArrays, + __values: () => __values2, + default: () => tslib_es6_default +}); +function __extends(d, b) { + if (typeof b !== "function" && b !== null) + throw new TypeError("Class extends value " + String(b) + " is not a constructor or null"); + extendStatics(d, b); + function __() { + this.constructor = d; + } + __name(__, "__"); + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +} +function __rest(s, e) { + var t = {}; + for (var p in s) + if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) + t[p] = s[p]; + if (s != null && typeof Object.getOwnPropertySymbols === "function") + for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { + if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) + t[p[i]] = s[p[i]]; + } + return t; +} +function __decorate(decorators, target, key, desc) { + var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; + if (typeof Reflect === "object" && typeof Reflect.decorate === "function") + r = Reflect.decorate(decorators, target, key, desc); + else + for (var i = decorators.length - 1; i >= 0; i--) + if (d = decorators[i]) + r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; + return c > 3 && r && Object.defineProperty(target, key, r), r; +} +function __param(paramIndex, decorator) { + return function(target, key) { + decorator(target, key, paramIndex); + }; +} +function __esDecorate(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) { + function accept(f) { + if (f !== void 0 && typeof f !== "function") + throw new TypeError("Function expected"); + return f; + } + __name(accept, "accept"); + var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value"; + var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null; + var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {}); + var _, done = false; + for (var i = decorators.length - 1; i >= 0; i--) { + var context = {}; + for (var p in contextIn) + context[p] = p === "access" ? {} : contextIn[p]; + for (var p in contextIn.access) + context.access[p] = contextIn.access[p]; + context.addInitializer = function(f) { + if (done) + throw new TypeError("Cannot add initializers after decoration has completed"); + extraInitializers.push(accept(f || null)); + }; + var result = (0, decorators[i])(kind === "accessor" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context); + if (kind === "accessor") { + if (result === void 0) + continue; + if (result === null || typeof result !== "object") + throw new TypeError("Object expected"); + if (_ = accept(result.get)) + descriptor.get = _; + if (_ = accept(result.set)) + descriptor.set = _; + if (_ = accept(result.init)) + initializers.unshift(_); + } else if (_ = accept(result)) { + if (kind === "field") + initializers.unshift(_); + else + descriptor[key] = _; + } + } + if (target) + Object.defineProperty(target, contextIn.name, descriptor); + done = true; +} +function __runInitializers(thisArg, initializers, value) { + var useValue = arguments.length > 2; + for (var i = 0; i < initializers.length; i++) { + value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg); + } + return useValue ? value : void 0; +} +function __propKey(x) { + return typeof x === "symbol" ? x : "".concat(x); +} +function __setFunctionName(f, name, prefix) { + if (typeof name === "symbol") + name = name.description ? "[".concat(name.description, "]") : ""; + return Object.defineProperty(f, "name", { configurable: true, value: prefix ? "".concat(prefix, " ", name) : name }); +} +function __metadata(metadataKey, metadataValue) { + if (typeof Reflect === "object" && typeof Reflect.metadata === "function") + return Reflect.metadata(metadataKey, metadataValue); +} +function __awaiter(thisArg, _arguments, P, generator) { + function adopt(value) { + return value instanceof P ? value : new P(function(resolve) { + resolve(value); + }); + } + __name(adopt, "adopt"); + return new (P || (P = Promise))(function(resolve, reject) { + function fulfilled(value) { + try { + step(generator.next(value)); + } catch (e) { + reject(e); + } + } + __name(fulfilled, "fulfilled"); + function rejected(value) { + try { + step(generator["throw"](value)); + } catch (e) { + reject(e); + } + } + __name(rejected, "rejected"); + function step(result) { + result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); + } + __name(step, "step"); + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); +} +function __generator(thisArg, body) { + var _ = { label: 0, sent: function() { + if (t[0] & 1) + throw t[1]; + return t[1]; + }, trys: [], ops: [] }, f, y, t, g; + return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { + return this; + }), g; + function verb(n) { + return function(v) { + return step([n, v]); + }; + } + __name(verb, "verb"); + function step(op) { + if (f) + throw new TypeError("Generator is already executing."); + while (g && (g = 0, op[0] && (_ = 0)), _) + try { + if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) + return t; + if (y = 0, t) + op = [op[0] & 2, t.value]; + switch (op[0]) { + case 0: + case 1: + t = op; + break; + case 4: + _.label++; + return { value: op[1], done: false }; + case 5: + _.label++; + y = op[1]; + op = [0]; + continue; + case 7: + op = _.ops.pop(); + _.trys.pop(); + continue; + default: + if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { + _ = 0; + continue; + } + if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) { + _.label = op[1]; + break; + } + if (op[0] === 6 && _.label < t[1]) { + _.label = t[1]; + t = op; + break; + } + if (t && _.label < t[2]) { + _.label = t[2]; + _.ops.push(op); + break; + } + if (t[2]) + _.ops.pop(); + _.trys.pop(); + continue; + } + op = body.call(thisArg, _); + } catch (e) { + op = [6, e]; + y = 0; + } finally { + f = t = 0; + } + if (op[0] & 5) + throw op[1]; + return { value: op[0] ? op[1] : void 0, done: true }; + } + __name(step, "step"); +} +function __exportStar(m, o) { + for (var p in m) + if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) + __createBinding(o, m, p); +} +function __values2(o) { + var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0; + if (m) + return m.call(o); + if (o && typeof o.length === "number") + return { + next: function() { + if (o && i >= o.length) + o = void 0; + return { value: o && o[i++], done: !o }; + } + }; + throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined."); +} +function __read(o, n) { + var m = typeof Symbol === "function" && o[Symbol.iterator]; + if (!m) + return o; + var i = m.call(o), r, ar = [], e; + try { + while ((n === void 0 || n-- > 0) && !(r = i.next()).done) + ar.push(r.value); + } catch (error) { + e = { error }; + } finally { + try { + if (r && !r.done && (m = i["return"])) + m.call(i); + } finally { + if (e) + throw e.error; + } + } + return ar; +} +function __spread() { + for (var ar = [], i = 0; i < arguments.length; i++) + ar = ar.concat(__read(arguments[i])); + return ar; +} +function __spreadArrays() { + for (var s = 0, i = 0, il = arguments.length; i < il; i++) + s += arguments[i].length; + for (var r = Array(s), k = 0, i = 0; i < il; i++) + for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++) + r[k] = a[j]; + return r; +} +function __spreadArray(to, from, pack) { + if (pack || arguments.length === 2) + for (var i = 0, l = from.length, ar; i < l; i++) { + if (ar || !(i in from)) { + if (!ar) + ar = Array.prototype.slice.call(from, 0, i); + ar[i] = from[i]; + } + } + return to.concat(ar || Array.prototype.slice.call(from)); +} +function __await(v) { + return this instanceof __await ? (this.v = v, this) : new __await(v); +} +function __asyncGenerator(thisArg, _arguments, generator) { + if (!Symbol.asyncIterator) + throw new TypeError("Symbol.asyncIterator is not defined."); + var g = generator.apply(thisArg, _arguments || []), i, q = []; + return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() { + return this; + }, i; + function verb(n) { + if (g[n]) + i[n] = function(v) { + return new Promise(function(a, b) { + q.push([n, v, a, b]) > 1 || resume(n, v); + }); + }; + } + __name(verb, "verb"); + function resume(n, v) { + try { + step(g[n](v)); + } catch (e) { + settle(q[0][3], e); + } + } + __name(resume, "resume"); + function step(r) { + r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); + } + __name(step, "step"); + function fulfill(value) { + resume("next", value); + } + __name(fulfill, "fulfill"); + function reject(value) { + resume("throw", value); + } + __name(reject, "reject"); + function settle(f, v) { + if (f(v), q.shift(), q.length) + resume(q[0][0], q[0][1]); + } + __name(settle, "settle"); +} +function __asyncDelegator(o) { + var i, p; + return i = {}, verb("next"), verb("throw", function(e) { + throw e; + }), verb("return"), i[Symbol.iterator] = function() { + return this; + }, i; + function verb(n, f) { + i[n] = o[n] ? function(v) { + return (p = !p) ? { value: __await(o[n](v)), done: false } : f ? f(v) : v; + } : f; + } + __name(verb, "verb"); +} +function __asyncValues(o) { + if (!Symbol.asyncIterator) + throw new TypeError("Symbol.asyncIterator is not defined."); + var m = o[Symbol.asyncIterator], i; + return m ? m.call(o) : (o = typeof __values2 === "function" ? __values2(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() { + return this; + }, i); + function verb(n) { + i[n] = o[n] && function(v) { + return new Promise(function(resolve, reject) { + v = o[n](v), settle(resolve, reject, v.done, v.value); + }); + }; + } + __name(verb, "verb"); + function settle(resolve, reject, d, v) { + Promise.resolve(v).then(function(v2) { + resolve({ value: v2, done: d }); + }, reject); + } + __name(settle, "settle"); +} +function __makeTemplateObject(cooked, raw) { + if (Object.defineProperty) { + Object.defineProperty(cooked, "raw", { value: raw }); + } else { + cooked.raw = raw; + } + return cooked; +} +function __importStar(mod) { + if (mod && mod.__esModule) + return mod; + var result = {}; + if (mod != null) { + for (var k in mod) + if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) + __createBinding(result, mod, k); + } + __setModuleDefault(result, mod); + return result; +} +function __importDefault(mod) { + return mod && mod.__esModule ? mod : { default: mod }; +} +function __classPrivateFieldGet(receiver, state, kind, f) { + if (kind === "a" && !f) + throw new TypeError("Private accessor was defined without a getter"); + if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) + throw new TypeError("Cannot read private member from an object whose class did not declare it"); + return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver); +} +function __classPrivateFieldSet(receiver, state, value, kind, f) { + if (kind === "m") + throw new TypeError("Private method is not writable"); + if (kind === "a" && !f) + throw new TypeError("Private accessor was defined without a setter"); + if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) + throw new TypeError("Cannot write private member to an object whose class did not declare it"); + return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value; +} +function __classPrivateFieldIn(state, receiver) { + if (receiver === null || typeof receiver !== "object" && typeof receiver !== "function") + throw new TypeError("Cannot use 'in' operator on non-object"); + return typeof state === "function" ? receiver === state : state.has(receiver); +} +var extendStatics, __assign, __createBinding, __setModuleDefault, tslib_es6_default; +var init_tslib_es6 = __esm({ + "node_modules/tslib/tslib.es6.mjs"() { + extendStatics = /* @__PURE__ */ __name(function(d, b) { + extendStatics = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d2, b2) { + d2.__proto__ = b2; + } || function(d2, b2) { + for (var p in b2) + if (Object.prototype.hasOwnProperty.call(b2, p)) + d2[p] = b2[p]; + }; + return extendStatics(d, b); + }, "extendStatics"); + __name(__extends, "__extends"); + __assign = /* @__PURE__ */ __name(function() { + __assign = Object.assign || /* @__PURE__ */ __name(function __assign2(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) + if (Object.prototype.hasOwnProperty.call(s, p)) + t[p] = s[p]; + } + return t; + }, "__assign"); + return __assign.apply(this, arguments); + }, "__assign"); + __name(__rest, "__rest"); + __name(__decorate, "__decorate"); + __name(__param, "__param"); + __name(__esDecorate, "__esDecorate"); + __name(__runInitializers, "__runInitializers"); + __name(__propKey, "__propKey"); + __name(__setFunctionName, "__setFunctionName"); + __name(__metadata, "__metadata"); + __name(__awaiter, "__awaiter"); + __name(__generator, "__generator"); + __createBinding = Object.create ? function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { + return m[k]; + } }; + } + Object.defineProperty(o, k2, desc); + } : function(o, m, k, k2) { + if (k2 === void 0) + k2 = k; + o[k2] = m[k]; + }; + __name(__exportStar, "__exportStar"); + __name(__values2, "__values"); + __name(__read, "__read"); + __name(__spread, "__spread"); + __name(__spreadArrays, "__spreadArrays"); + __name(__spreadArray, "__spreadArray"); + __name(__await, "__await"); + __name(__asyncGenerator, "__asyncGenerator"); + __name(__asyncDelegator, "__asyncDelegator"); + __name(__asyncValues, "__asyncValues"); + __name(__makeTemplateObject, "__makeTemplateObject"); + __setModuleDefault = Object.create ? function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); + } : function(o, v) { + o["default"] = v; + }; + __name(__importStar, "__importStar"); + __name(__importDefault, "__importDefault"); + __name(__classPrivateFieldGet, "__classPrivateFieldGet"); + __name(__classPrivateFieldSet, "__classPrivateFieldSet"); + __name(__classPrivateFieldIn, "__classPrivateFieldIn"); + tslib_es6_default = { + __extends, + __assign, + __rest, + __decorate, + __param, + __metadata, + __awaiter, + __generator, + __createBinding, + __exportStar, + __values: __values2, + __read, + __spread, + __spreadArrays, + __spreadArray, + __await, + __asyncGenerator, + __asyncDelegator, + __asyncValues, + __makeTemplateObject, + __importStar, + __importDefault, + __classPrivateFieldGet, + __classPrivateFieldSet, + __classPrivateFieldIn + }; + } +}); + +// node_modules/xml2js/lib/defaults.js +var require_defaults = __commonJS({ + "node_modules/xml2js/lib/defaults.js"(exports) { + (function() { + exports.defaults = { + "0.1": { + explicitCharkey: false, + trim: true, + normalize: true, + normalizeTags: false, + attrkey: "@", + charkey: "#", + explicitArray: false, + ignoreAttrs: false, + mergeAttrs: false, + explicitRoot: false, + validator: null, + xmlns: false, + explicitChildren: false, + childkey: "@@", + charsAsChildren: false, + includeWhiteChars: false, + async: false, + strict: true, + attrNameProcessors: null, + attrValueProcessors: null, + tagNameProcessors: null, + valueProcessors: null, + emptyTag: "" + }, + "0.2": { + explicitCharkey: false, + trim: false, + normalize: false, + normalizeTags: false, + attrkey: "$", + charkey: "_", + explicitArray: true, + ignoreAttrs: false, + mergeAttrs: false, + explicitRoot: true, + validator: null, + xmlns: false, + explicitChildren: false, + preserveChildrenOrder: false, + childkey: "$$", + charsAsChildren: false, + includeWhiteChars: false, + async: false, + strict: true, + attrNameProcessors: null, + attrValueProcessors: null, + tagNameProcessors: null, + valueProcessors: null, + rootName: "root", + xmldec: { + "version": "1.0", + "encoding": "UTF-8", + "standalone": true + }, + doctype: null, + renderOpts: { + "pretty": true, + "indent": " ", + "newline": "\n" + }, + headless: false, + chunkSize: 1e4, + emptyTag: "", + cdata: false + } + }; + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/Utility.js +var require_Utility = __commonJS({ + "node_modules/xmlbuilder/lib/Utility.js"(exports, module2) { + (function() { + var assign, getValue, isArray, isEmpty, isFunction, isObject, isPlainObject, slice = [].slice, hasProp = {}.hasOwnProperty; + assign = /* @__PURE__ */ __name(function() { + var i, key, len, source, sources, target; + target = arguments[0], sources = 2 <= arguments.length ? slice.call(arguments, 1) : []; + if (isFunction(Object.assign)) { + Object.assign.apply(null, arguments); + } else { + for (i = 0, len = sources.length; i < len; i++) { + source = sources[i]; + if (source != null) { + for (key in source) { + if (!hasProp.call(source, key)) + continue; + target[key] = source[key]; + } + } + } + } + return target; + }, "assign"); + isFunction = /* @__PURE__ */ __name(function(val) { + return !!val && Object.prototype.toString.call(val) === "[object Function]"; + }, "isFunction"); + isObject = /* @__PURE__ */ __name(function(val) { + var ref; + return !!val && ((ref = typeof val) === "function" || ref === "object"); + }, "isObject"); + isArray = /* @__PURE__ */ __name(function(val) { + if (isFunction(Array.isArray)) { + return Array.isArray(val); + } else { + return Object.prototype.toString.call(val) === "[object Array]"; + } + }, "isArray"); + isEmpty = /* @__PURE__ */ __name(function(val) { + var key; + if (isArray(val)) { + return !val.length; + } else { + for (key in val) { + if (!hasProp.call(val, key)) + continue; + return false; + } + return true; + } + }, "isEmpty"); + isPlainObject = /* @__PURE__ */ __name(function(val) { + var ctor, proto; + return isObject(val) && (proto = Object.getPrototypeOf(val)) && (ctor = proto.constructor) && typeof ctor === "function" && ctor instanceof ctor && Function.prototype.toString.call(ctor) === Function.prototype.toString.call(Object); + }, "isPlainObject"); + getValue = /* @__PURE__ */ __name(function(obj) { + if (isFunction(obj.valueOf)) { + return obj.valueOf(); + } else { + return obj; + } + }, "getValue"); + module2.exports.assign = assign; + module2.exports.isFunction = isFunction; + module2.exports.isObject = isObject; + module2.exports.isArray = isArray; + module2.exports.isEmpty = isEmpty; + module2.exports.isPlainObject = isPlainObject; + module2.exports.getValue = getValue; + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDOMImplementation.js +var require_XMLDOMImplementation = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDOMImplementation.js"(exports, module2) { + (function() { + var XMLDOMImplementation; + module2.exports = XMLDOMImplementation = /* @__PURE__ */ function() { + function XMLDOMImplementation2() { + } + __name(XMLDOMImplementation2, "XMLDOMImplementation"); + XMLDOMImplementation2.prototype.hasFeature = function(feature, version3) { + return true; + }; + XMLDOMImplementation2.prototype.createDocumentType = function(qualifiedName, publicId, systemId) { + throw new Error("This DOM method is not implemented."); + }; + XMLDOMImplementation2.prototype.createDocument = function(namespaceURI, qualifiedName, doctype) { + throw new Error("This DOM method is not implemented."); + }; + XMLDOMImplementation2.prototype.createHTMLDocument = function(title) { + throw new Error("This DOM method is not implemented."); + }; + XMLDOMImplementation2.prototype.getFeature = function(feature, version3) { + throw new Error("This DOM method is not implemented."); + }; + return XMLDOMImplementation2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDOMErrorHandler.js +var require_XMLDOMErrorHandler = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDOMErrorHandler.js"(exports, module2) { + (function() { + var XMLDOMErrorHandler; + module2.exports = XMLDOMErrorHandler = /* @__PURE__ */ function() { + function XMLDOMErrorHandler2() { + } + __name(XMLDOMErrorHandler2, "XMLDOMErrorHandler"); + XMLDOMErrorHandler2.prototype.handleError = function(error) { + throw new Error(error); + }; + return XMLDOMErrorHandler2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDOMStringList.js +var require_XMLDOMStringList = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDOMStringList.js"(exports, module2) { + (function() { + var XMLDOMStringList; + module2.exports = XMLDOMStringList = /* @__PURE__ */ function() { + function XMLDOMStringList2(arr) { + this.arr = arr || []; + } + __name(XMLDOMStringList2, "XMLDOMStringList"); + Object.defineProperty(XMLDOMStringList2.prototype, "length", { + get: function() { + return this.arr.length; + } + }); + XMLDOMStringList2.prototype.item = function(index) { + return this.arr[index] || null; + }; + XMLDOMStringList2.prototype.contains = function(str) { + return this.arr.indexOf(str) !== -1; + }; + return XMLDOMStringList2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDOMConfiguration.js +var require_XMLDOMConfiguration = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDOMConfiguration.js"(exports, module2) { + (function() { + var XMLDOMConfiguration, XMLDOMErrorHandler, XMLDOMStringList; + XMLDOMErrorHandler = require_XMLDOMErrorHandler(); + XMLDOMStringList = require_XMLDOMStringList(); + module2.exports = XMLDOMConfiguration = /* @__PURE__ */ function() { + function XMLDOMConfiguration2() { + var clonedSelf; + this.defaultParams = { + "canonical-form": false, + "cdata-sections": false, + "comments": false, + "datatype-normalization": false, + "element-content-whitespace": true, + "entities": true, + "error-handler": new XMLDOMErrorHandler(), + "infoset": true, + "validate-if-schema": false, + "namespaces": true, + "namespace-declarations": true, + "normalize-characters": false, + "schema-location": "", + "schema-type": "", + "split-cdata-sections": true, + "validate": false, + "well-formed": true + }; + this.params = clonedSelf = Object.create(this.defaultParams); + } + __name(XMLDOMConfiguration2, "XMLDOMConfiguration"); + Object.defineProperty(XMLDOMConfiguration2.prototype, "parameterNames", { + get: function() { + return new XMLDOMStringList(Object.keys(this.defaultParams)); + } + }); + XMLDOMConfiguration2.prototype.getParameter = function(name) { + if (this.params.hasOwnProperty(name)) { + return this.params[name]; + } else { + return null; + } + }; + XMLDOMConfiguration2.prototype.canSetParameter = function(name, value) { + return true; + }; + XMLDOMConfiguration2.prototype.setParameter = function(name, value) { + if (value != null) { + return this.params[name] = value; + } else { + return delete this.params[name]; + } + }; + return XMLDOMConfiguration2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/NodeType.js +var require_NodeType = __commonJS({ + "node_modules/xmlbuilder/lib/NodeType.js"(exports, module2) { + (function() { + module2.exports = { + Element: 1, + Attribute: 2, + Text: 3, + CData: 4, + EntityReference: 5, + EntityDeclaration: 6, + ProcessingInstruction: 7, + Comment: 8, + Document: 9, + DocType: 10, + DocumentFragment: 11, + NotationDeclaration: 12, + Declaration: 201, + Raw: 202, + AttributeDeclaration: 203, + ElementDeclaration: 204, + Dummy: 205 + }; + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLAttribute.js +var require_XMLAttribute = __commonJS({ + "node_modules/xmlbuilder/lib/XMLAttribute.js"(exports, module2) { + (function() { + var NodeType, XMLAttribute, XMLNode; + NodeType = require_NodeType(); + XMLNode = require_XMLNode(); + module2.exports = XMLAttribute = /* @__PURE__ */ function() { + function XMLAttribute2(parent, name, value) { + this.parent = parent; + if (this.parent) { + this.options = this.parent.options; + this.stringify = this.parent.stringify; + } + if (name == null) { + throw new Error("Missing attribute name. " + this.debugInfo(name)); + } + this.name = this.stringify.name(name); + this.value = this.stringify.attValue(value); + this.type = NodeType.Attribute; + this.isId = false; + this.schemaTypeInfo = null; + } + __name(XMLAttribute2, "XMLAttribute"); + Object.defineProperty(XMLAttribute2.prototype, "nodeType", { + get: function() { + return this.type; + } + }); + Object.defineProperty(XMLAttribute2.prototype, "ownerElement", { + get: function() { + return this.parent; + } + }); + Object.defineProperty(XMLAttribute2.prototype, "textContent", { + get: function() { + return this.value; + }, + set: function(value) { + return this.value = value || ""; + } + }); + Object.defineProperty(XMLAttribute2.prototype, "namespaceURI", { + get: function() { + return ""; + } + }); + Object.defineProperty(XMLAttribute2.prototype, "prefix", { + get: function() { + return ""; + } + }); + Object.defineProperty(XMLAttribute2.prototype, "localName", { + get: function() { + return this.name; + } + }); + Object.defineProperty(XMLAttribute2.prototype, "specified", { + get: function() { + return true; + } + }); + XMLAttribute2.prototype.clone = function() { + return Object.create(this); + }; + XMLAttribute2.prototype.toString = function(options) { + return this.options.writer.attribute(this, this.options.writer.filterOptions(options)); + }; + XMLAttribute2.prototype.debugInfo = function(name) { + name = name || this.name; + if (name == null) { + return "parent: <" + this.parent.name + ">"; + } else { + return "attribute: {" + name + "}, parent: <" + this.parent.name + ">"; + } + }; + XMLAttribute2.prototype.isEqualNode = function(node) { + if (node.namespaceURI !== this.namespaceURI) { + return false; + } + if (node.prefix !== this.prefix) { + return false; + } + if (node.localName !== this.localName) { + return false; + } + if (node.value !== this.value) { + return false; + } + return true; + }; + return XMLAttribute2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLNamedNodeMap.js +var require_XMLNamedNodeMap = __commonJS({ + "node_modules/xmlbuilder/lib/XMLNamedNodeMap.js"(exports, module2) { + (function() { + var XMLNamedNodeMap; + module2.exports = XMLNamedNodeMap = /* @__PURE__ */ function() { + function XMLNamedNodeMap2(nodes) { + this.nodes = nodes; + } + __name(XMLNamedNodeMap2, "XMLNamedNodeMap"); + Object.defineProperty(XMLNamedNodeMap2.prototype, "length", { + get: function() { + return Object.keys(this.nodes).length || 0; + } + }); + XMLNamedNodeMap2.prototype.clone = function() { + return this.nodes = null; + }; + XMLNamedNodeMap2.prototype.getNamedItem = function(name) { + return this.nodes[name]; + }; + XMLNamedNodeMap2.prototype.setNamedItem = function(node) { + var oldNode; + oldNode = this.nodes[node.nodeName]; + this.nodes[node.nodeName] = node; + return oldNode || null; + }; + XMLNamedNodeMap2.prototype.removeNamedItem = function(name) { + var oldNode; + oldNode = this.nodes[name]; + delete this.nodes[name]; + return oldNode || null; + }; + XMLNamedNodeMap2.prototype.item = function(index) { + return this.nodes[Object.keys(this.nodes)[index]] || null; + }; + XMLNamedNodeMap2.prototype.getNamedItemNS = function(namespaceURI, localName) { + throw new Error("This DOM method is not implemented."); + }; + XMLNamedNodeMap2.prototype.setNamedItemNS = function(node) { + throw new Error("This DOM method is not implemented."); + }; + XMLNamedNodeMap2.prototype.removeNamedItemNS = function(namespaceURI, localName) { + throw new Error("This DOM method is not implemented."); + }; + return XMLNamedNodeMap2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLElement.js +var require_XMLElement = __commonJS({ + "node_modules/xmlbuilder/lib/XMLElement.js"(exports, module2) { + (function() { + var NodeType, XMLAttribute, XMLElement, XMLNamedNodeMap, XMLNode, getValue, isFunction, isObject, ref, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + ref = require_Utility(), isObject = ref.isObject, isFunction = ref.isFunction, getValue = ref.getValue; + XMLNode = require_XMLNode(); + NodeType = require_NodeType(); + XMLAttribute = require_XMLAttribute(); + XMLNamedNodeMap = require_XMLNamedNodeMap(); + module2.exports = XMLElement = function(superClass) { + extend(XMLElement2, superClass); + function XMLElement2(parent, name, attributes) { + var child, j, len, ref1; + XMLElement2.__super__.constructor.call(this, parent); + if (name == null) { + throw new Error("Missing element name. " + this.debugInfo()); + } + this.name = this.stringify.name(name); + this.type = NodeType.Element; + this.attribs = {}; + this.schemaTypeInfo = null; + if (attributes != null) { + this.attribute(attributes); + } + if (parent.type === NodeType.Document) { + this.isRoot = true; + this.documentObject = parent; + parent.rootObject = this; + if (parent.children) { + ref1 = parent.children; + for (j = 0, len = ref1.length; j < len; j++) { + child = ref1[j]; + if (child.type === NodeType.DocType) { + child.name = this.name; + break; + } + } + } + } + } + __name(XMLElement2, "XMLElement"); + Object.defineProperty(XMLElement2.prototype, "tagName", { + get: function() { + return this.name; + } + }); + Object.defineProperty(XMLElement2.prototype, "namespaceURI", { + get: function() { + return ""; + } + }); + Object.defineProperty(XMLElement2.prototype, "prefix", { + get: function() { + return ""; + } + }); + Object.defineProperty(XMLElement2.prototype, "localName", { + get: function() { + return this.name; + } + }); + Object.defineProperty(XMLElement2.prototype, "id", { + get: function() { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + } + }); + Object.defineProperty(XMLElement2.prototype, "className", { + get: function() { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + } + }); + Object.defineProperty(XMLElement2.prototype, "classList", { + get: function() { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + } + }); + Object.defineProperty(XMLElement2.prototype, "attributes", { + get: function() { + if (!this.attributeMap || !this.attributeMap.nodes) { + this.attributeMap = new XMLNamedNodeMap(this.attribs); + } + return this.attributeMap; + } + }); + XMLElement2.prototype.clone = function() { + var att, attName, clonedSelf, ref1; + clonedSelf = Object.create(this); + if (clonedSelf.isRoot) { + clonedSelf.documentObject = null; + } + clonedSelf.attribs = {}; + ref1 = this.attribs; + for (attName in ref1) { + if (!hasProp.call(ref1, attName)) + continue; + att = ref1[attName]; + clonedSelf.attribs[attName] = att.clone(); + } + clonedSelf.children = []; + this.children.forEach(function(child) { + var clonedChild; + clonedChild = child.clone(); + clonedChild.parent = clonedSelf; + return clonedSelf.children.push(clonedChild); + }); + return clonedSelf; + }; + XMLElement2.prototype.attribute = function(name, value) { + var attName, attValue; + if (name != null) { + name = getValue(name); + } + if (isObject(name)) { + for (attName in name) { + if (!hasProp.call(name, attName)) + continue; + attValue = name[attName]; + this.attribute(attName, attValue); + } + } else { + if (isFunction(value)) { + value = value.apply(); + } + if (this.options.keepNullAttributes && value == null) { + this.attribs[name] = new XMLAttribute(this, name, ""); + } else if (value != null) { + this.attribs[name] = new XMLAttribute(this, name, value); + } + } + return this; + }; + XMLElement2.prototype.removeAttribute = function(name) { + var attName, j, len; + if (name == null) { + throw new Error("Missing attribute name. " + this.debugInfo()); + } + name = getValue(name); + if (Array.isArray(name)) { + for (j = 0, len = name.length; j < len; j++) { + attName = name[j]; + delete this.attribs[attName]; + } + } else { + delete this.attribs[name]; + } + return this; + }; + XMLElement2.prototype.toString = function(options) { + return this.options.writer.element(this, this.options.writer.filterOptions(options)); + }; + XMLElement2.prototype.att = function(name, value) { + return this.attribute(name, value); + }; + XMLElement2.prototype.a = function(name, value) { + return this.attribute(name, value); + }; + XMLElement2.prototype.getAttribute = function(name) { + if (this.attribs.hasOwnProperty(name)) { + return this.attribs[name].value; + } else { + return null; + } + }; + XMLElement2.prototype.setAttribute = function(name, value) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.getAttributeNode = function(name) { + if (this.attribs.hasOwnProperty(name)) { + return this.attribs[name]; + } else { + return null; + } + }; + XMLElement2.prototype.setAttributeNode = function(newAttr) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.removeAttributeNode = function(oldAttr) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.getElementsByTagName = function(name) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.getAttributeNS = function(namespaceURI, localName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.setAttributeNS = function(namespaceURI, qualifiedName, value) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.removeAttributeNS = function(namespaceURI, localName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.getAttributeNodeNS = function(namespaceURI, localName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.setAttributeNodeNS = function(newAttr) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.getElementsByTagNameNS = function(namespaceURI, localName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.hasAttribute = function(name) { + return this.attribs.hasOwnProperty(name); + }; + XMLElement2.prototype.hasAttributeNS = function(namespaceURI, localName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.setIdAttribute = function(name, isId) { + if (this.attribs.hasOwnProperty(name)) { + return this.attribs[name].isId; + } else { + return isId; + } + }; + XMLElement2.prototype.setIdAttributeNS = function(namespaceURI, localName, isId) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.setIdAttributeNode = function(idAttr, isId) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.getElementsByTagName = function(tagname) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.getElementsByTagNameNS = function(namespaceURI, localName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.getElementsByClassName = function(classNames) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLElement2.prototype.isEqualNode = function(node) { + var i, j, ref1; + if (!XMLElement2.__super__.isEqualNode.apply(this, arguments).isEqualNode(node)) { + return false; + } + if (node.namespaceURI !== this.namespaceURI) { + return false; + } + if (node.prefix !== this.prefix) { + return false; + } + if (node.localName !== this.localName) { + return false; + } + if (node.attribs.length !== this.attribs.length) { + return false; + } + for (i = j = 0, ref1 = this.attribs.length - 1; 0 <= ref1 ? j <= ref1 : j >= ref1; i = 0 <= ref1 ? ++j : --j) { + if (!this.attribs[i].isEqualNode(node.attribs[i])) { + return false; + } + } + return true; + }; + return XMLElement2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLCharacterData.js +var require_XMLCharacterData = __commonJS({ + "node_modules/xmlbuilder/lib/XMLCharacterData.js"(exports, module2) { + (function() { + var XMLCharacterData, XMLNode, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + XMLNode = require_XMLNode(); + module2.exports = XMLCharacterData = function(superClass) { + extend(XMLCharacterData2, superClass); + function XMLCharacterData2(parent) { + XMLCharacterData2.__super__.constructor.call(this, parent); + this.value = ""; + } + __name(XMLCharacterData2, "XMLCharacterData"); + Object.defineProperty(XMLCharacterData2.prototype, "data", { + get: function() { + return this.value; + }, + set: function(value) { + return this.value = value || ""; + } + }); + Object.defineProperty(XMLCharacterData2.prototype, "length", { + get: function() { + return this.value.length; + } + }); + Object.defineProperty(XMLCharacterData2.prototype, "textContent", { + get: function() { + return this.value; + }, + set: function(value) { + return this.value = value || ""; + } + }); + XMLCharacterData2.prototype.clone = function() { + return Object.create(this); + }; + XMLCharacterData2.prototype.substringData = function(offset, count) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLCharacterData2.prototype.appendData = function(arg) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLCharacterData2.prototype.insertData = function(offset, arg) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLCharacterData2.prototype.deleteData = function(offset, count) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLCharacterData2.prototype.replaceData = function(offset, count, arg) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLCharacterData2.prototype.isEqualNode = function(node) { + if (!XMLCharacterData2.__super__.isEqualNode.apply(this, arguments).isEqualNode(node)) { + return false; + } + if (node.data !== this.data) { + return false; + } + return true; + }; + return XMLCharacterData2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLCData.js +var require_XMLCData = __commonJS({ + "node_modules/xmlbuilder/lib/XMLCData.js"(exports, module2) { + (function() { + var NodeType, XMLCData, XMLCharacterData, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + NodeType = require_NodeType(); + XMLCharacterData = require_XMLCharacterData(); + module2.exports = XMLCData = function(superClass) { + extend(XMLCData2, superClass); + function XMLCData2(parent, text) { + XMLCData2.__super__.constructor.call(this, parent); + if (text == null) { + throw new Error("Missing CDATA text. " + this.debugInfo()); + } + this.name = "#cdata-section"; + this.type = NodeType.CData; + this.value = this.stringify.cdata(text); + } + __name(XMLCData2, "XMLCData"); + XMLCData2.prototype.clone = function() { + return Object.create(this); + }; + XMLCData2.prototype.toString = function(options) { + return this.options.writer.cdata(this, this.options.writer.filterOptions(options)); + }; + return XMLCData2; + }(XMLCharacterData); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLComment.js +var require_XMLComment = __commonJS({ + "node_modules/xmlbuilder/lib/XMLComment.js"(exports, module2) { + (function() { + var NodeType, XMLCharacterData, XMLComment, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + NodeType = require_NodeType(); + XMLCharacterData = require_XMLCharacterData(); + module2.exports = XMLComment = function(superClass) { + extend(XMLComment2, superClass); + function XMLComment2(parent, text) { + XMLComment2.__super__.constructor.call(this, parent); + if (text == null) { + throw new Error("Missing comment text. " + this.debugInfo()); + } + this.name = "#comment"; + this.type = NodeType.Comment; + this.value = this.stringify.comment(text); + } + __name(XMLComment2, "XMLComment"); + XMLComment2.prototype.clone = function() { + return Object.create(this); + }; + XMLComment2.prototype.toString = function(options) { + return this.options.writer.comment(this, this.options.writer.filterOptions(options)); + }; + return XMLComment2; + }(XMLCharacterData); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDeclaration.js +var require_XMLDeclaration = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDeclaration.js"(exports, module2) { + (function() { + var NodeType, XMLDeclaration, XMLNode, isObject, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + isObject = require_Utility().isObject; + XMLNode = require_XMLNode(); + NodeType = require_NodeType(); + module2.exports = XMLDeclaration = function(superClass) { + extend(XMLDeclaration2, superClass); + function XMLDeclaration2(parent, version3, encoding, standalone) { + var ref; + XMLDeclaration2.__super__.constructor.call(this, parent); + if (isObject(version3)) { + ref = version3, version3 = ref.version, encoding = ref.encoding, standalone = ref.standalone; + } + if (!version3) { + version3 = "1.0"; + } + this.type = NodeType.Declaration; + this.version = this.stringify.xmlVersion(version3); + if (encoding != null) { + this.encoding = this.stringify.xmlEncoding(encoding); + } + if (standalone != null) { + this.standalone = this.stringify.xmlStandalone(standalone); + } + } + __name(XMLDeclaration2, "XMLDeclaration"); + XMLDeclaration2.prototype.toString = function(options) { + return this.options.writer.declaration(this, this.options.writer.filterOptions(options)); + }; + return XMLDeclaration2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDTDAttList.js +var require_XMLDTDAttList = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDTDAttList.js"(exports, module2) { + (function() { + var NodeType, XMLDTDAttList, XMLNode, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + XMLNode = require_XMLNode(); + NodeType = require_NodeType(); + module2.exports = XMLDTDAttList = function(superClass) { + extend(XMLDTDAttList2, superClass); + function XMLDTDAttList2(parent, elementName, attributeName, attributeType, defaultValueType, defaultValue) { + XMLDTDAttList2.__super__.constructor.call(this, parent); + if (elementName == null) { + throw new Error("Missing DTD element name. " + this.debugInfo()); + } + if (attributeName == null) { + throw new Error("Missing DTD attribute name. " + this.debugInfo(elementName)); + } + if (!attributeType) { + throw new Error("Missing DTD attribute type. " + this.debugInfo(elementName)); + } + if (!defaultValueType) { + throw new Error("Missing DTD attribute default. " + this.debugInfo(elementName)); + } + if (defaultValueType.indexOf("#") !== 0) { + defaultValueType = "#" + defaultValueType; + } + if (!defaultValueType.match(/^(#REQUIRED|#IMPLIED|#FIXED|#DEFAULT)$/)) { + throw new Error("Invalid default value type; expected: #REQUIRED, #IMPLIED, #FIXED or #DEFAULT. " + this.debugInfo(elementName)); + } + if (defaultValue && !defaultValueType.match(/^(#FIXED|#DEFAULT)$/)) { + throw new Error("Default value only applies to #FIXED or #DEFAULT. " + this.debugInfo(elementName)); + } + this.elementName = this.stringify.name(elementName); + this.type = NodeType.AttributeDeclaration; + this.attributeName = this.stringify.name(attributeName); + this.attributeType = this.stringify.dtdAttType(attributeType); + if (defaultValue) { + this.defaultValue = this.stringify.dtdAttDefault(defaultValue); + } + this.defaultValueType = defaultValueType; + } + __name(XMLDTDAttList2, "XMLDTDAttList"); + XMLDTDAttList2.prototype.toString = function(options) { + return this.options.writer.dtdAttList(this, this.options.writer.filterOptions(options)); + }; + return XMLDTDAttList2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDTDEntity.js +var require_XMLDTDEntity = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDTDEntity.js"(exports, module2) { + (function() { + var NodeType, XMLDTDEntity, XMLNode, isObject, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + isObject = require_Utility().isObject; + XMLNode = require_XMLNode(); + NodeType = require_NodeType(); + module2.exports = XMLDTDEntity = function(superClass) { + extend(XMLDTDEntity2, superClass); + function XMLDTDEntity2(parent, pe, name, value) { + XMLDTDEntity2.__super__.constructor.call(this, parent); + if (name == null) { + throw new Error("Missing DTD entity name. " + this.debugInfo(name)); + } + if (value == null) { + throw new Error("Missing DTD entity value. " + this.debugInfo(name)); + } + this.pe = !!pe; + this.name = this.stringify.name(name); + this.type = NodeType.EntityDeclaration; + if (!isObject(value)) { + this.value = this.stringify.dtdEntityValue(value); + this.internal = true; + } else { + if (!value.pubID && !value.sysID) { + throw new Error("Public and/or system identifiers are required for an external entity. " + this.debugInfo(name)); + } + if (value.pubID && !value.sysID) { + throw new Error("System identifier is required for a public external entity. " + this.debugInfo(name)); + } + this.internal = false; + if (value.pubID != null) { + this.pubID = this.stringify.dtdPubID(value.pubID); + } + if (value.sysID != null) { + this.sysID = this.stringify.dtdSysID(value.sysID); + } + if (value.nData != null) { + this.nData = this.stringify.dtdNData(value.nData); + } + if (this.pe && this.nData) { + throw new Error("Notation declaration is not allowed in a parameter entity. " + this.debugInfo(name)); + } + } + } + __name(XMLDTDEntity2, "XMLDTDEntity"); + Object.defineProperty(XMLDTDEntity2.prototype, "publicId", { + get: function() { + return this.pubID; + } + }); + Object.defineProperty(XMLDTDEntity2.prototype, "systemId", { + get: function() { + return this.sysID; + } + }); + Object.defineProperty(XMLDTDEntity2.prototype, "notationName", { + get: function() { + return this.nData || null; + } + }); + Object.defineProperty(XMLDTDEntity2.prototype, "inputEncoding", { + get: function() { + return null; + } + }); + Object.defineProperty(XMLDTDEntity2.prototype, "xmlEncoding", { + get: function() { + return null; + } + }); + Object.defineProperty(XMLDTDEntity2.prototype, "xmlVersion", { + get: function() { + return null; + } + }); + XMLDTDEntity2.prototype.toString = function(options) { + return this.options.writer.dtdEntity(this, this.options.writer.filterOptions(options)); + }; + return XMLDTDEntity2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDTDElement.js +var require_XMLDTDElement = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDTDElement.js"(exports, module2) { + (function() { + var NodeType, XMLDTDElement, XMLNode, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + XMLNode = require_XMLNode(); + NodeType = require_NodeType(); + module2.exports = XMLDTDElement = function(superClass) { + extend(XMLDTDElement2, superClass); + function XMLDTDElement2(parent, name, value) { + XMLDTDElement2.__super__.constructor.call(this, parent); + if (name == null) { + throw new Error("Missing DTD element name. " + this.debugInfo()); + } + if (!value) { + value = "(#PCDATA)"; + } + if (Array.isArray(value)) { + value = "(" + value.join(",") + ")"; + } + this.name = this.stringify.name(name); + this.type = NodeType.ElementDeclaration; + this.value = this.stringify.dtdElementValue(value); + } + __name(XMLDTDElement2, "XMLDTDElement"); + XMLDTDElement2.prototype.toString = function(options) { + return this.options.writer.dtdElement(this, this.options.writer.filterOptions(options)); + }; + return XMLDTDElement2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDTDNotation.js +var require_XMLDTDNotation = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDTDNotation.js"(exports, module2) { + (function() { + var NodeType, XMLDTDNotation, XMLNode, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + XMLNode = require_XMLNode(); + NodeType = require_NodeType(); + module2.exports = XMLDTDNotation = function(superClass) { + extend(XMLDTDNotation2, superClass); + function XMLDTDNotation2(parent, name, value) { + XMLDTDNotation2.__super__.constructor.call(this, parent); + if (name == null) { + throw new Error("Missing DTD notation name. " + this.debugInfo(name)); + } + if (!value.pubID && !value.sysID) { + throw new Error("Public or system identifiers are required for an external entity. " + this.debugInfo(name)); + } + this.name = this.stringify.name(name); + this.type = NodeType.NotationDeclaration; + if (value.pubID != null) { + this.pubID = this.stringify.dtdPubID(value.pubID); + } + if (value.sysID != null) { + this.sysID = this.stringify.dtdSysID(value.sysID); + } + } + __name(XMLDTDNotation2, "XMLDTDNotation"); + Object.defineProperty(XMLDTDNotation2.prototype, "publicId", { + get: function() { + return this.pubID; + } + }); + Object.defineProperty(XMLDTDNotation2.prototype, "systemId", { + get: function() { + return this.sysID; + } + }); + XMLDTDNotation2.prototype.toString = function(options) { + return this.options.writer.dtdNotation(this, this.options.writer.filterOptions(options)); + }; + return XMLDTDNotation2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDocType.js +var require_XMLDocType = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDocType.js"(exports, module2) { + (function() { + var NodeType, XMLDTDAttList, XMLDTDElement, XMLDTDEntity, XMLDTDNotation, XMLDocType, XMLNamedNodeMap, XMLNode, isObject, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + isObject = require_Utility().isObject; + XMLNode = require_XMLNode(); + NodeType = require_NodeType(); + XMLDTDAttList = require_XMLDTDAttList(); + XMLDTDEntity = require_XMLDTDEntity(); + XMLDTDElement = require_XMLDTDElement(); + XMLDTDNotation = require_XMLDTDNotation(); + XMLNamedNodeMap = require_XMLNamedNodeMap(); + module2.exports = XMLDocType = function(superClass) { + extend(XMLDocType2, superClass); + function XMLDocType2(parent, pubID, sysID) { + var child, i, len, ref, ref1, ref2; + XMLDocType2.__super__.constructor.call(this, parent); + this.type = NodeType.DocType; + if (parent.children) { + ref = parent.children; + for (i = 0, len = ref.length; i < len; i++) { + child = ref[i]; + if (child.type === NodeType.Element) { + this.name = child.name; + break; + } + } + } + this.documentObject = parent; + if (isObject(pubID)) { + ref1 = pubID, pubID = ref1.pubID, sysID = ref1.sysID; + } + if (sysID == null) { + ref2 = [pubID, sysID], sysID = ref2[0], pubID = ref2[1]; + } + if (pubID != null) { + this.pubID = this.stringify.dtdPubID(pubID); + } + if (sysID != null) { + this.sysID = this.stringify.dtdSysID(sysID); + } + } + __name(XMLDocType2, "XMLDocType"); + Object.defineProperty(XMLDocType2.prototype, "entities", { + get: function() { + var child, i, len, nodes, ref; + nodes = {}; + ref = this.children; + for (i = 0, len = ref.length; i < len; i++) { + child = ref[i]; + if (child.type === NodeType.EntityDeclaration && !child.pe) { + nodes[child.name] = child; + } + } + return new XMLNamedNodeMap(nodes); + } + }); + Object.defineProperty(XMLDocType2.prototype, "notations", { + get: function() { + var child, i, len, nodes, ref; + nodes = {}; + ref = this.children; + for (i = 0, len = ref.length; i < len; i++) { + child = ref[i]; + if (child.type === NodeType.NotationDeclaration) { + nodes[child.name] = child; + } + } + return new XMLNamedNodeMap(nodes); + } + }); + Object.defineProperty(XMLDocType2.prototype, "publicId", { + get: function() { + return this.pubID; + } + }); + Object.defineProperty(XMLDocType2.prototype, "systemId", { + get: function() { + return this.sysID; + } + }); + Object.defineProperty(XMLDocType2.prototype, "internalSubset", { + get: function() { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + } + }); + XMLDocType2.prototype.element = function(name, value) { + var child; + child = new XMLDTDElement(this, name, value); + this.children.push(child); + return this; + }; + XMLDocType2.prototype.attList = function(elementName, attributeName, attributeType, defaultValueType, defaultValue) { + var child; + child = new XMLDTDAttList(this, elementName, attributeName, attributeType, defaultValueType, defaultValue); + this.children.push(child); + return this; + }; + XMLDocType2.prototype.entity = function(name, value) { + var child; + child = new XMLDTDEntity(this, false, name, value); + this.children.push(child); + return this; + }; + XMLDocType2.prototype.pEntity = function(name, value) { + var child; + child = new XMLDTDEntity(this, true, name, value); + this.children.push(child); + return this; + }; + XMLDocType2.prototype.notation = function(name, value) { + var child; + child = new XMLDTDNotation(this, name, value); + this.children.push(child); + return this; + }; + XMLDocType2.prototype.toString = function(options) { + return this.options.writer.docType(this, this.options.writer.filterOptions(options)); + }; + XMLDocType2.prototype.ele = function(name, value) { + return this.element(name, value); + }; + XMLDocType2.prototype.att = function(elementName, attributeName, attributeType, defaultValueType, defaultValue) { + return this.attList(elementName, attributeName, attributeType, defaultValueType, defaultValue); + }; + XMLDocType2.prototype.ent = function(name, value) { + return this.entity(name, value); + }; + XMLDocType2.prototype.pent = function(name, value) { + return this.pEntity(name, value); + }; + XMLDocType2.prototype.not = function(name, value) { + return this.notation(name, value); + }; + XMLDocType2.prototype.up = function() { + return this.root() || this.documentObject; + }; + XMLDocType2.prototype.isEqualNode = function(node) { + if (!XMLDocType2.__super__.isEqualNode.apply(this, arguments).isEqualNode(node)) { + return false; + } + if (node.name !== this.name) { + return false; + } + if (node.publicId !== this.publicId) { + return false; + } + if (node.systemId !== this.systemId) { + return false; + } + return true; + }; + return XMLDocType2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLRaw.js +var require_XMLRaw = __commonJS({ + "node_modules/xmlbuilder/lib/XMLRaw.js"(exports, module2) { + (function() { + var NodeType, XMLNode, XMLRaw, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + NodeType = require_NodeType(); + XMLNode = require_XMLNode(); + module2.exports = XMLRaw = function(superClass) { + extend(XMLRaw2, superClass); + function XMLRaw2(parent, text) { + XMLRaw2.__super__.constructor.call(this, parent); + if (text == null) { + throw new Error("Missing raw text. " + this.debugInfo()); + } + this.type = NodeType.Raw; + this.value = this.stringify.raw(text); + } + __name(XMLRaw2, "XMLRaw"); + XMLRaw2.prototype.clone = function() { + return Object.create(this); + }; + XMLRaw2.prototype.toString = function(options) { + return this.options.writer.raw(this, this.options.writer.filterOptions(options)); + }; + return XMLRaw2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLText.js +var require_XMLText = __commonJS({ + "node_modules/xmlbuilder/lib/XMLText.js"(exports, module2) { + (function() { + var NodeType, XMLCharacterData, XMLText, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + NodeType = require_NodeType(); + XMLCharacterData = require_XMLCharacterData(); + module2.exports = XMLText = function(superClass) { + extend(XMLText2, superClass); + function XMLText2(parent, text) { + XMLText2.__super__.constructor.call(this, parent); + if (text == null) { + throw new Error("Missing element text. " + this.debugInfo()); + } + this.name = "#text"; + this.type = NodeType.Text; + this.value = this.stringify.text(text); + } + __name(XMLText2, "XMLText"); + Object.defineProperty(XMLText2.prototype, "isElementContentWhitespace", { + get: function() { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + } + }); + Object.defineProperty(XMLText2.prototype, "wholeText", { + get: function() { + var next, prev, str; + str = ""; + prev = this.previousSibling; + while (prev) { + str = prev.data + str; + prev = prev.previousSibling; + } + str += this.data; + next = this.nextSibling; + while (next) { + str = str + next.data; + next = next.nextSibling; + } + return str; + } + }); + XMLText2.prototype.clone = function() { + return Object.create(this); + }; + XMLText2.prototype.toString = function(options) { + return this.options.writer.text(this, this.options.writer.filterOptions(options)); + }; + XMLText2.prototype.splitText = function(offset) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLText2.prototype.replaceWholeText = function(content) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + return XMLText2; + }(XMLCharacterData); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLProcessingInstruction.js +var require_XMLProcessingInstruction = __commonJS({ + "node_modules/xmlbuilder/lib/XMLProcessingInstruction.js"(exports, module2) { + (function() { + var NodeType, XMLCharacterData, XMLProcessingInstruction, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + NodeType = require_NodeType(); + XMLCharacterData = require_XMLCharacterData(); + module2.exports = XMLProcessingInstruction = function(superClass) { + extend(XMLProcessingInstruction2, superClass); + function XMLProcessingInstruction2(parent, target, value) { + XMLProcessingInstruction2.__super__.constructor.call(this, parent); + if (target == null) { + throw new Error("Missing instruction target. " + this.debugInfo()); + } + this.type = NodeType.ProcessingInstruction; + this.target = this.stringify.insTarget(target); + this.name = this.target; + if (value) { + this.value = this.stringify.insValue(value); + } + } + __name(XMLProcessingInstruction2, "XMLProcessingInstruction"); + XMLProcessingInstruction2.prototype.clone = function() { + return Object.create(this); + }; + XMLProcessingInstruction2.prototype.toString = function(options) { + return this.options.writer.processingInstruction(this, this.options.writer.filterOptions(options)); + }; + XMLProcessingInstruction2.prototype.isEqualNode = function(node) { + if (!XMLProcessingInstruction2.__super__.isEqualNode.apply(this, arguments).isEqualNode(node)) { + return false; + } + if (node.target !== this.target) { + return false; + } + return true; + }; + return XMLProcessingInstruction2; + }(XMLCharacterData); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDummy.js +var require_XMLDummy = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDummy.js"(exports, module2) { + (function() { + var NodeType, XMLDummy, XMLNode, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + XMLNode = require_XMLNode(); + NodeType = require_NodeType(); + module2.exports = XMLDummy = function(superClass) { + extend(XMLDummy2, superClass); + function XMLDummy2(parent) { + XMLDummy2.__super__.constructor.call(this, parent); + this.type = NodeType.Dummy; + } + __name(XMLDummy2, "XMLDummy"); + XMLDummy2.prototype.clone = function() { + return Object.create(this); + }; + XMLDummy2.prototype.toString = function(options) { + return ""; + }; + return XMLDummy2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLNodeList.js +var require_XMLNodeList = __commonJS({ + "node_modules/xmlbuilder/lib/XMLNodeList.js"(exports, module2) { + (function() { + var XMLNodeList; + module2.exports = XMLNodeList = /* @__PURE__ */ function() { + function XMLNodeList2(nodes) { + this.nodes = nodes; + } + __name(XMLNodeList2, "XMLNodeList"); + Object.defineProperty(XMLNodeList2.prototype, "length", { + get: function() { + return this.nodes.length || 0; + } + }); + XMLNodeList2.prototype.clone = function() { + return this.nodes = null; + }; + XMLNodeList2.prototype.item = function(index) { + return this.nodes[index] || null; + }; + return XMLNodeList2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/DocumentPosition.js +var require_DocumentPosition = __commonJS({ + "node_modules/xmlbuilder/lib/DocumentPosition.js"(exports, module2) { + (function() { + module2.exports = { + Disconnected: 1, + Preceding: 2, + Following: 4, + Contains: 8, + ContainedBy: 16, + ImplementationSpecific: 32 + }; + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLNode.js +var require_XMLNode = __commonJS({ + "node_modules/xmlbuilder/lib/XMLNode.js"(exports, module2) { + (function() { + var DocumentPosition, NodeType, XMLCData, XMLComment, XMLDeclaration, XMLDocType, XMLDummy, XMLElement, XMLNamedNodeMap, XMLNode, XMLNodeList, XMLProcessingInstruction, XMLRaw, XMLText, getValue, isEmpty, isFunction, isObject, ref1, hasProp = {}.hasOwnProperty; + ref1 = require_Utility(), isObject = ref1.isObject, isFunction = ref1.isFunction, isEmpty = ref1.isEmpty, getValue = ref1.getValue; + XMLElement = null; + XMLCData = null; + XMLComment = null; + XMLDeclaration = null; + XMLDocType = null; + XMLRaw = null; + XMLText = null; + XMLProcessingInstruction = null; + XMLDummy = null; + NodeType = null; + XMLNodeList = null; + XMLNamedNodeMap = null; + DocumentPosition = null; + module2.exports = XMLNode = /* @__PURE__ */ function() { + function XMLNode2(parent1) { + this.parent = parent1; + if (this.parent) { + this.options = this.parent.options; + this.stringify = this.parent.stringify; + } + this.value = null; + this.children = []; + this.baseURI = null; + if (!XMLElement) { + XMLElement = require_XMLElement(); + XMLCData = require_XMLCData(); + XMLComment = require_XMLComment(); + XMLDeclaration = require_XMLDeclaration(); + XMLDocType = require_XMLDocType(); + XMLRaw = require_XMLRaw(); + XMLText = require_XMLText(); + XMLProcessingInstruction = require_XMLProcessingInstruction(); + XMLDummy = require_XMLDummy(); + NodeType = require_NodeType(); + XMLNodeList = require_XMLNodeList(); + XMLNamedNodeMap = require_XMLNamedNodeMap(); + DocumentPosition = require_DocumentPosition(); + } + } + __name(XMLNode2, "XMLNode"); + Object.defineProperty(XMLNode2.prototype, "nodeName", { + get: function() { + return this.name; + } + }); + Object.defineProperty(XMLNode2.prototype, "nodeType", { + get: function() { + return this.type; + } + }); + Object.defineProperty(XMLNode2.prototype, "nodeValue", { + get: function() { + return this.value; + } + }); + Object.defineProperty(XMLNode2.prototype, "parentNode", { + get: function() { + return this.parent; + } + }); + Object.defineProperty(XMLNode2.prototype, "childNodes", { + get: function() { + if (!this.childNodeList || !this.childNodeList.nodes) { + this.childNodeList = new XMLNodeList(this.children); + } + return this.childNodeList; + } + }); + Object.defineProperty(XMLNode2.prototype, "firstChild", { + get: function() { + return this.children[0] || null; + } + }); + Object.defineProperty(XMLNode2.prototype, "lastChild", { + get: function() { + return this.children[this.children.length - 1] || null; + } + }); + Object.defineProperty(XMLNode2.prototype, "previousSibling", { + get: function() { + var i; + i = this.parent.children.indexOf(this); + return this.parent.children[i - 1] || null; + } + }); + Object.defineProperty(XMLNode2.prototype, "nextSibling", { + get: function() { + var i; + i = this.parent.children.indexOf(this); + return this.parent.children[i + 1] || null; + } + }); + Object.defineProperty(XMLNode2.prototype, "ownerDocument", { + get: function() { + return this.document() || null; + } + }); + Object.defineProperty(XMLNode2.prototype, "textContent", { + get: function() { + var child, j, len, ref2, str; + if (this.nodeType === NodeType.Element || this.nodeType === NodeType.DocumentFragment) { + str = ""; + ref2 = this.children; + for (j = 0, len = ref2.length; j < len; j++) { + child = ref2[j]; + if (child.textContent) { + str += child.textContent; + } + } + return str; + } else { + return null; + } + }, + set: function(value) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + } + }); + XMLNode2.prototype.setParent = function(parent) { + var child, j, len, ref2, results; + this.parent = parent; + if (parent) { + this.options = parent.options; + this.stringify = parent.stringify; + } + ref2 = this.children; + results = []; + for (j = 0, len = ref2.length; j < len; j++) { + child = ref2[j]; + results.push(child.setParent(this)); + } + return results; + }; + XMLNode2.prototype.element = function(name, attributes, text) { + var childNode, item, j, k, key, lastChild, len, len1, ref2, ref3, val; + lastChild = null; + if (attributes === null && text == null) { + ref2 = [{}, null], attributes = ref2[0], text = ref2[1]; + } + if (attributes == null) { + attributes = {}; + } + attributes = getValue(attributes); + if (!isObject(attributes)) { + ref3 = [attributes, text], text = ref3[0], attributes = ref3[1]; + } + if (name != null) { + name = getValue(name); + } + if (Array.isArray(name)) { + for (j = 0, len = name.length; j < len; j++) { + item = name[j]; + lastChild = this.element(item); + } + } else if (isFunction(name)) { + lastChild = this.element(name.apply()); + } else if (isObject(name)) { + for (key in name) { + if (!hasProp.call(name, key)) + continue; + val = name[key]; + if (isFunction(val)) { + val = val.apply(); + } + if (!this.options.ignoreDecorators && this.stringify.convertAttKey && key.indexOf(this.stringify.convertAttKey) === 0) { + lastChild = this.attribute(key.substr(this.stringify.convertAttKey.length), val); + } else if (!this.options.separateArrayItems && Array.isArray(val) && isEmpty(val)) { + lastChild = this.dummy(); + } else if (isObject(val) && isEmpty(val)) { + lastChild = this.element(key); + } else if (!this.options.keepNullNodes && val == null) { + lastChild = this.dummy(); + } else if (!this.options.separateArrayItems && Array.isArray(val)) { + for (k = 0, len1 = val.length; k < len1; k++) { + item = val[k]; + childNode = {}; + childNode[key] = item; + lastChild = this.element(childNode); + } + } else if (isObject(val)) { + if (!this.options.ignoreDecorators && this.stringify.convertTextKey && key.indexOf(this.stringify.convertTextKey) === 0) { + lastChild = this.element(val); + } else { + lastChild = this.element(key); + lastChild.element(val); + } + } else { + lastChild = this.element(key, val); + } + } + } else if (!this.options.keepNullNodes && text === null) { + lastChild = this.dummy(); + } else { + if (!this.options.ignoreDecorators && this.stringify.convertTextKey && name.indexOf(this.stringify.convertTextKey) === 0) { + lastChild = this.text(text); + } else if (!this.options.ignoreDecorators && this.stringify.convertCDataKey && name.indexOf(this.stringify.convertCDataKey) === 0) { + lastChild = this.cdata(text); + } else if (!this.options.ignoreDecorators && this.stringify.convertCommentKey && name.indexOf(this.stringify.convertCommentKey) === 0) { + lastChild = this.comment(text); + } else if (!this.options.ignoreDecorators && this.stringify.convertRawKey && name.indexOf(this.stringify.convertRawKey) === 0) { + lastChild = this.raw(text); + } else if (!this.options.ignoreDecorators && this.stringify.convertPIKey && name.indexOf(this.stringify.convertPIKey) === 0) { + lastChild = this.instruction(name.substr(this.stringify.convertPIKey.length), text); + } else { + lastChild = this.node(name, attributes, text); + } + } + if (lastChild == null) { + throw new Error("Could not create any elements with: " + name + ". " + this.debugInfo()); + } + return lastChild; + }; + XMLNode2.prototype.insertBefore = function(name, attributes, text) { + var child, i, newChild, refChild, removed; + if (name != null ? name.type : void 0) { + newChild = name; + refChild = attributes; + newChild.setParent(this); + if (refChild) { + i = children.indexOf(refChild); + removed = children.splice(i); + children.push(newChild); + Array.prototype.push.apply(children, removed); + } else { + children.push(newChild); + } + return newChild; + } else { + if (this.isRoot) { + throw new Error("Cannot insert elements at root level. " + this.debugInfo(name)); + } + i = this.parent.children.indexOf(this); + removed = this.parent.children.splice(i); + child = this.parent.element(name, attributes, text); + Array.prototype.push.apply(this.parent.children, removed); + return child; + } + }; + XMLNode2.prototype.insertAfter = function(name, attributes, text) { + var child, i, removed; + if (this.isRoot) { + throw new Error("Cannot insert elements at root level. " + this.debugInfo(name)); + } + i = this.parent.children.indexOf(this); + removed = this.parent.children.splice(i + 1); + child = this.parent.element(name, attributes, text); + Array.prototype.push.apply(this.parent.children, removed); + return child; + }; + XMLNode2.prototype.remove = function() { + var i, ref2; + if (this.isRoot) { + throw new Error("Cannot remove the root element. " + this.debugInfo()); + } + i = this.parent.children.indexOf(this); + [].splice.apply(this.parent.children, [i, i - i + 1].concat(ref2 = [])), ref2; + return this.parent; + }; + XMLNode2.prototype.node = function(name, attributes, text) { + var child, ref2; + if (name != null) { + name = getValue(name); + } + attributes || (attributes = {}); + attributes = getValue(attributes); + if (!isObject(attributes)) { + ref2 = [attributes, text], text = ref2[0], attributes = ref2[1]; + } + child = new XMLElement(this, name, attributes); + if (text != null) { + child.text(text); + } + this.children.push(child); + return child; + }; + XMLNode2.prototype.text = function(value) { + var child; + if (isObject(value)) { + this.element(value); + } + child = new XMLText(this, value); + this.children.push(child); + return this; + }; + XMLNode2.prototype.cdata = function(value) { + var child; + child = new XMLCData(this, value); + this.children.push(child); + return this; + }; + XMLNode2.prototype.comment = function(value) { + var child; + child = new XMLComment(this, value); + this.children.push(child); + return this; + }; + XMLNode2.prototype.commentBefore = function(value) { + var child, i, removed; + i = this.parent.children.indexOf(this); + removed = this.parent.children.splice(i); + child = this.parent.comment(value); + Array.prototype.push.apply(this.parent.children, removed); + return this; + }; + XMLNode2.prototype.commentAfter = function(value) { + var child, i, removed; + i = this.parent.children.indexOf(this); + removed = this.parent.children.splice(i + 1); + child = this.parent.comment(value); + Array.prototype.push.apply(this.parent.children, removed); + return this; + }; + XMLNode2.prototype.raw = function(value) { + var child; + child = new XMLRaw(this, value); + this.children.push(child); + return this; + }; + XMLNode2.prototype.dummy = function() { + var child; + child = new XMLDummy(this); + return child; + }; + XMLNode2.prototype.instruction = function(target, value) { + var insTarget, insValue, instruction, j, len; + if (target != null) { + target = getValue(target); + } + if (value != null) { + value = getValue(value); + } + if (Array.isArray(target)) { + for (j = 0, len = target.length; j < len; j++) { + insTarget = target[j]; + this.instruction(insTarget); + } + } else if (isObject(target)) { + for (insTarget in target) { + if (!hasProp.call(target, insTarget)) + continue; + insValue = target[insTarget]; + this.instruction(insTarget, insValue); + } + } else { + if (isFunction(value)) { + value = value.apply(); + } + instruction = new XMLProcessingInstruction(this, target, value); + this.children.push(instruction); + } + return this; + }; + XMLNode2.prototype.instructionBefore = function(target, value) { + var child, i, removed; + i = this.parent.children.indexOf(this); + removed = this.parent.children.splice(i); + child = this.parent.instruction(target, value); + Array.prototype.push.apply(this.parent.children, removed); + return this; + }; + XMLNode2.prototype.instructionAfter = function(target, value) { + var child, i, removed; + i = this.parent.children.indexOf(this); + removed = this.parent.children.splice(i + 1); + child = this.parent.instruction(target, value); + Array.prototype.push.apply(this.parent.children, removed); + return this; + }; + XMLNode2.prototype.declaration = function(version3, encoding, standalone) { + var doc, xmldec; + doc = this.document(); + xmldec = new XMLDeclaration(doc, version3, encoding, standalone); + if (doc.children.length === 0) { + doc.children.unshift(xmldec); + } else if (doc.children[0].type === NodeType.Declaration) { + doc.children[0] = xmldec; + } else { + doc.children.unshift(xmldec); + } + return doc.root() || doc; + }; + XMLNode2.prototype.dtd = function(pubID, sysID) { + var child, doc, doctype, i, j, k, len, len1, ref2, ref3; + doc = this.document(); + doctype = new XMLDocType(doc, pubID, sysID); + ref2 = doc.children; + for (i = j = 0, len = ref2.length; j < len; i = ++j) { + child = ref2[i]; + if (child.type === NodeType.DocType) { + doc.children[i] = doctype; + return doctype; + } + } + ref3 = doc.children; + for (i = k = 0, len1 = ref3.length; k < len1; i = ++k) { + child = ref3[i]; + if (child.isRoot) { + doc.children.splice(i, 0, doctype); + return doctype; + } + } + doc.children.push(doctype); + return doctype; + }; + XMLNode2.prototype.up = function() { + if (this.isRoot) { + throw new Error("The root node has no parent. Use doc() if you need to get the document object."); + } + return this.parent; + }; + XMLNode2.prototype.root = function() { + var node; + node = this; + while (node) { + if (node.type === NodeType.Document) { + return node.rootObject; + } else if (node.isRoot) { + return node; + } else { + node = node.parent; + } + } + }; + XMLNode2.prototype.document = function() { + var node; + node = this; + while (node) { + if (node.type === NodeType.Document) { + return node; + } else { + node = node.parent; + } + } + }; + XMLNode2.prototype.end = function(options) { + return this.document().end(options); + }; + XMLNode2.prototype.prev = function() { + var i; + i = this.parent.children.indexOf(this); + if (i < 1) { + throw new Error("Already at the first node. " + this.debugInfo()); + } + return this.parent.children[i - 1]; + }; + XMLNode2.prototype.next = function() { + var i; + i = this.parent.children.indexOf(this); + if (i === -1 || i === this.parent.children.length - 1) { + throw new Error("Already at the last node. " + this.debugInfo()); + } + return this.parent.children[i + 1]; + }; + XMLNode2.prototype.importDocument = function(doc) { + var clonedRoot; + clonedRoot = doc.root().clone(); + clonedRoot.parent = this; + clonedRoot.isRoot = false; + this.children.push(clonedRoot); + return this; + }; + XMLNode2.prototype.debugInfo = function(name) { + var ref2, ref3; + name = name || this.name; + if (name == null && !((ref2 = this.parent) != null ? ref2.name : void 0)) { + return ""; + } else if (name == null) { + return "parent: <" + this.parent.name + ">"; + } else if (!((ref3 = this.parent) != null ? ref3.name : void 0)) { + return "node: <" + name + ">"; + } else { + return "node: <" + name + ">, parent: <" + this.parent.name + ">"; + } + }; + XMLNode2.prototype.ele = function(name, attributes, text) { + return this.element(name, attributes, text); + }; + XMLNode2.prototype.nod = function(name, attributes, text) { + return this.node(name, attributes, text); + }; + XMLNode2.prototype.txt = function(value) { + return this.text(value); + }; + XMLNode2.prototype.dat = function(value) { + return this.cdata(value); + }; + XMLNode2.prototype.com = function(value) { + return this.comment(value); + }; + XMLNode2.prototype.ins = function(target, value) { + return this.instruction(target, value); + }; + XMLNode2.prototype.doc = function() { + return this.document(); + }; + XMLNode2.prototype.dec = function(version3, encoding, standalone) { + return this.declaration(version3, encoding, standalone); + }; + XMLNode2.prototype.e = function(name, attributes, text) { + return this.element(name, attributes, text); + }; + XMLNode2.prototype.n = function(name, attributes, text) { + return this.node(name, attributes, text); + }; + XMLNode2.prototype.t = function(value) { + return this.text(value); + }; + XMLNode2.prototype.d = function(value) { + return this.cdata(value); + }; + XMLNode2.prototype.c = function(value) { + return this.comment(value); + }; + XMLNode2.prototype.r = function(value) { + return this.raw(value); + }; + XMLNode2.prototype.i = function(target, value) { + return this.instruction(target, value); + }; + XMLNode2.prototype.u = function() { + return this.up(); + }; + XMLNode2.prototype.importXMLBuilder = function(doc) { + return this.importDocument(doc); + }; + XMLNode2.prototype.replaceChild = function(newChild, oldChild) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.removeChild = function(oldChild) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.appendChild = function(newChild) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.hasChildNodes = function() { + return this.children.length !== 0; + }; + XMLNode2.prototype.cloneNode = function(deep) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.normalize = function() { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.isSupported = function(feature, version3) { + return true; + }; + XMLNode2.prototype.hasAttributes = function() { + return this.attribs.length !== 0; + }; + XMLNode2.prototype.compareDocumentPosition = function(other) { + var ref, res; + ref = this; + if (ref === other) { + return 0; + } else if (this.document() !== other.document()) { + res = DocumentPosition.Disconnected | DocumentPosition.ImplementationSpecific; + if (Math.random() < 0.5) { + res |= DocumentPosition.Preceding; + } else { + res |= DocumentPosition.Following; + } + return res; + } else if (ref.isAncestor(other)) { + return DocumentPosition.Contains | DocumentPosition.Preceding; + } else if (ref.isDescendant(other)) { + return DocumentPosition.Contains | DocumentPosition.Following; + } else if (ref.isPreceding(other)) { + return DocumentPosition.Preceding; + } else { + return DocumentPosition.Following; + } + }; + XMLNode2.prototype.isSameNode = function(other) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.lookupPrefix = function(namespaceURI) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.isDefaultNamespace = function(namespaceURI) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.lookupNamespaceURI = function(prefix) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.isEqualNode = function(node) { + var i, j, ref2; + if (node.nodeType !== this.nodeType) { + return false; + } + if (node.children.length !== this.children.length) { + return false; + } + for (i = j = 0, ref2 = this.children.length - 1; 0 <= ref2 ? j <= ref2 : j >= ref2; i = 0 <= ref2 ? ++j : --j) { + if (!this.children[i].isEqualNode(node.children[i])) { + return false; + } + } + return true; + }; + XMLNode2.prototype.getFeature = function(feature, version3) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.setUserData = function(key, data, handler) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.getUserData = function(key) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLNode2.prototype.contains = function(other) { + if (!other) { + return false; + } + return other === this || this.isDescendant(other); + }; + XMLNode2.prototype.isDescendant = function(node) { + var child, isDescendantChild, j, len, ref2; + ref2 = this.children; + for (j = 0, len = ref2.length; j < len; j++) { + child = ref2[j]; + if (node === child) { + return true; + } + isDescendantChild = child.isDescendant(node); + if (isDescendantChild) { + return true; + } + } + return false; + }; + XMLNode2.prototype.isAncestor = function(node) { + return node.isDescendant(this); + }; + XMLNode2.prototype.isPreceding = function(node) { + var nodePos, thisPos; + nodePos = this.treePosition(node); + thisPos = this.treePosition(this); + if (nodePos === -1 || thisPos === -1) { + return false; + } else { + return nodePos < thisPos; + } + }; + XMLNode2.prototype.isFollowing = function(node) { + var nodePos, thisPos; + nodePos = this.treePosition(node); + thisPos = this.treePosition(this); + if (nodePos === -1 || thisPos === -1) { + return false; + } else { + return nodePos > thisPos; + } + }; + XMLNode2.prototype.treePosition = function(node) { + var found, pos; + pos = 0; + found = false; + this.foreachTreeNode(this.document(), function(childNode) { + pos++; + if (!found && childNode === node) { + return found = true; + } + }); + if (found) { + return pos; + } else { + return -1; + } + }; + XMLNode2.prototype.foreachTreeNode = function(node, func) { + var child, j, len, ref2, res; + node || (node = this.document()); + ref2 = node.children; + for (j = 0, len = ref2.length; j < len; j++) { + child = ref2[j]; + if (res = func(child)) { + return res; + } else { + res = this.foreachTreeNode(child, func); + if (res) { + return res; + } + } + } + }; + return XMLNode2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLStringifier.js +var require_XMLStringifier = __commonJS({ + "node_modules/xmlbuilder/lib/XMLStringifier.js"(exports, module2) { + (function() { + var XMLStringifier, bind = /* @__PURE__ */ __name(function(fn, me) { + return function() { + return fn.apply(me, arguments); + }; + }, "bind"), hasProp = {}.hasOwnProperty; + module2.exports = XMLStringifier = /* @__PURE__ */ function() { + function XMLStringifier2(options) { + this.assertLegalName = bind(this.assertLegalName, this); + this.assertLegalChar = bind(this.assertLegalChar, this); + var key, ref, value; + options || (options = {}); + this.options = options; + if (!this.options.version) { + this.options.version = "1.0"; + } + ref = options.stringify || {}; + for (key in ref) { + if (!hasProp.call(ref, key)) + continue; + value = ref[key]; + this[key] = value; + } + } + __name(XMLStringifier2, "XMLStringifier"); + XMLStringifier2.prototype.name = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalName("" + val || ""); + }; + XMLStringifier2.prototype.text = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar(this.textEscape("" + val || "")); + }; + XMLStringifier2.prototype.cdata = function(val) { + if (this.options.noValidation) { + return val; + } + val = "" + val || ""; + val = val.replace("]]>", "]]]]>"); + return this.assertLegalChar(val); + }; + XMLStringifier2.prototype.comment = function(val) { + if (this.options.noValidation) { + return val; + } + val = "" + val || ""; + if (val.match(/--/)) { + throw new Error("Comment text cannot contain double-hypen: " + val); + } + return this.assertLegalChar(val); + }; + XMLStringifier2.prototype.raw = function(val) { + if (this.options.noValidation) { + return val; + } + return "" + val || ""; + }; + XMLStringifier2.prototype.attValue = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar(this.attEscape(val = "" + val || "")); + }; + XMLStringifier2.prototype.insTarget = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar("" + val || ""); + }; + XMLStringifier2.prototype.insValue = function(val) { + if (this.options.noValidation) { + return val; + } + val = "" + val || ""; + if (val.match(/\?>/)) { + throw new Error("Invalid processing instruction value: " + val); + } + return this.assertLegalChar(val); + }; + XMLStringifier2.prototype.xmlVersion = function(val) { + if (this.options.noValidation) { + return val; + } + val = "" + val || ""; + if (!val.match(/1\.[0-9]+/)) { + throw new Error("Invalid version number: " + val); + } + return val; + }; + XMLStringifier2.prototype.xmlEncoding = function(val) { + if (this.options.noValidation) { + return val; + } + val = "" + val || ""; + if (!val.match(/^[A-Za-z](?:[A-Za-z0-9._-])*$/)) { + throw new Error("Invalid encoding: " + val); + } + return this.assertLegalChar(val); + }; + XMLStringifier2.prototype.xmlStandalone = function(val) { + if (this.options.noValidation) { + return val; + } + if (val) { + return "yes"; + } else { + return "no"; + } + }; + XMLStringifier2.prototype.dtdPubID = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar("" + val || ""); + }; + XMLStringifier2.prototype.dtdSysID = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar("" + val || ""); + }; + XMLStringifier2.prototype.dtdElementValue = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar("" + val || ""); + }; + XMLStringifier2.prototype.dtdAttType = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar("" + val || ""); + }; + XMLStringifier2.prototype.dtdAttDefault = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar("" + val || ""); + }; + XMLStringifier2.prototype.dtdEntityValue = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar("" + val || ""); + }; + XMLStringifier2.prototype.dtdNData = function(val) { + if (this.options.noValidation) { + return val; + } + return this.assertLegalChar("" + val || ""); + }; + XMLStringifier2.prototype.convertAttKey = "@"; + XMLStringifier2.prototype.convertPIKey = "?"; + XMLStringifier2.prototype.convertTextKey = "#text"; + XMLStringifier2.prototype.convertCDataKey = "#cdata"; + XMLStringifier2.prototype.convertCommentKey = "#comment"; + XMLStringifier2.prototype.convertRawKey = "#raw"; + XMLStringifier2.prototype.assertLegalChar = function(str) { + var regex, res; + if (this.options.noValidation) { + return str; + } + regex = ""; + if (this.options.version === "1.0") { + regex = /[\0-\x08\x0B\f\x0E-\x1F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/; + if (res = str.match(regex)) { + throw new Error("Invalid character in string: " + str + " at index " + res.index); + } + } else if (this.options.version === "1.1") { + regex = /[\0\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/; + if (res = str.match(regex)) { + throw new Error("Invalid character in string: " + str + " at index " + res.index); + } + } + return str; + }; + XMLStringifier2.prototype.assertLegalName = function(str) { + var regex; + if (this.options.noValidation) { + return str; + } + this.assertLegalChar(str); + regex = /^([:A-Z_a-z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])([\x2D\.0-:A-Z_a-z\xB7\xC0-\xD6\xD8-\xF6\xF8-\u037D\u037F-\u1FFF\u200C\u200D\u203F\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])*$/; + if (!str.match(regex)) { + throw new Error("Invalid character in name"); + } + return str; + }; + XMLStringifier2.prototype.textEscape = function(str) { + var ampregex; + if (this.options.noValidation) { + return str; + } + ampregex = this.options.noDoubleEncoding ? /(?!&\S+;)&/g : /&/g; + return str.replace(ampregex, "&").replace(//g, ">").replace(/\r/g, " "); + }; + XMLStringifier2.prototype.attEscape = function(str) { + var ampregex; + if (this.options.noValidation) { + return str; + } + ampregex = this.options.noDoubleEncoding ? /(?!&\S+;)&/g : /&/g; + return str.replace(ampregex, "&").replace(/ 0) { + return new Array(indentLevel).join(options.indent); + } + } + return ""; + }; + XMLWriterBase2.prototype.endline = function(node, options, level) { + if (!options.pretty || options.suppressPrettyCount) { + return ""; + } else { + return options.newline; + } + }; + XMLWriterBase2.prototype.attribute = function(att, options, level) { + var r; + this.openAttribute(att, options, level); + r = " " + att.name + '="' + att.value + '"'; + this.closeAttribute(att, options, level); + return r; + }; + XMLWriterBase2.prototype.cdata = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level) + "" + this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.comment = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level) + "" + this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.declaration = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level) + ""; + r += this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.docType = function(node, options, level) { + var child, i, len, r, ref; + level || (level = 0); + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level); + r += " 0) { + r += " ["; + r += this.endline(node, options, level); + options.state = WriterState.InsideTag; + ref = node.children; + for (i = 0, len = ref.length; i < len; i++) { + child = ref[i]; + r += this.writeChildNode(child, options, level + 1); + } + options.state = WriterState.CloseTag; + r += "]"; + } + options.state = WriterState.CloseTag; + r += options.spaceBeforeSlash + ">"; + r += this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.element = function(node, options, level) { + var att, child, childNodeCount, firstChildNode, i, j, len, len1, name, prettySuppressed, r, ref, ref1, ref2; + level || (level = 0); + prettySuppressed = false; + r = ""; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r += this.indent(node, options, level) + "<" + node.name; + ref = node.attribs; + for (name in ref) { + if (!hasProp.call(ref, name)) + continue; + att = ref[name]; + r += this.attribute(att, options, level); + } + childNodeCount = node.children.length; + firstChildNode = childNodeCount === 0 ? null : node.children[0]; + if (childNodeCount === 0 || node.children.every(function(e) { + return (e.type === NodeType.Text || e.type === NodeType.Raw) && e.value === ""; + })) { + if (options.allowEmpty) { + r += ">"; + options.state = WriterState.CloseTag; + r += "" + this.endline(node, options, level); + } else { + options.state = WriterState.CloseTag; + r += options.spaceBeforeSlash + "/>" + this.endline(node, options, level); + } + } else if (options.pretty && childNodeCount === 1 && (firstChildNode.type === NodeType.Text || firstChildNode.type === NodeType.Raw) && firstChildNode.value != null) { + r += ">"; + options.state = WriterState.InsideTag; + options.suppressPrettyCount++; + prettySuppressed = true; + r += this.writeChildNode(firstChildNode, options, level + 1); + options.suppressPrettyCount--; + prettySuppressed = false; + options.state = WriterState.CloseTag; + r += "" + this.endline(node, options, level); + } else { + if (options.dontPrettyTextNodes) { + ref1 = node.children; + for (i = 0, len = ref1.length; i < len; i++) { + child = ref1[i]; + if ((child.type === NodeType.Text || child.type === NodeType.Raw) && child.value != null) { + options.suppressPrettyCount++; + prettySuppressed = true; + break; + } + } + } + r += ">" + this.endline(node, options, level); + options.state = WriterState.InsideTag; + ref2 = node.children; + for (j = 0, len1 = ref2.length; j < len1; j++) { + child = ref2[j]; + r += this.writeChildNode(child, options, level + 1); + } + options.state = WriterState.CloseTag; + r += this.indent(node, options, level) + ""; + if (prettySuppressed) { + options.suppressPrettyCount--; + } + r += this.endline(node, options, level); + options.state = WriterState.None; + } + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.writeChildNode = function(node, options, level) { + switch (node.type) { + case NodeType.CData: + return this.cdata(node, options, level); + case NodeType.Comment: + return this.comment(node, options, level); + case NodeType.Element: + return this.element(node, options, level); + case NodeType.Raw: + return this.raw(node, options, level); + case NodeType.Text: + return this.text(node, options, level); + case NodeType.ProcessingInstruction: + return this.processingInstruction(node, options, level); + case NodeType.Dummy: + return ""; + case NodeType.Declaration: + return this.declaration(node, options, level); + case NodeType.DocType: + return this.docType(node, options, level); + case NodeType.AttributeDeclaration: + return this.dtdAttList(node, options, level); + case NodeType.ElementDeclaration: + return this.dtdElement(node, options, level); + case NodeType.EntityDeclaration: + return this.dtdEntity(node, options, level); + case NodeType.NotationDeclaration: + return this.dtdNotation(node, options, level); + default: + throw new Error("Unknown XML node type: " + node.constructor.name); + } + }; + XMLWriterBase2.prototype.processingInstruction = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level) + ""; + r += this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.raw = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level); + options.state = WriterState.InsideTag; + r += node.value; + options.state = WriterState.CloseTag; + r += this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.text = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level); + options.state = WriterState.InsideTag; + r += node.value; + options.state = WriterState.CloseTag; + r += this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.dtdAttList = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level) + "" + this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.dtdElement = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level) + "" + this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.dtdEntity = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level) + "" + this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.dtdNotation = function(node, options, level) { + var r; + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + r = this.indent(node, options, level) + "" + this.endline(node, options, level); + options.state = WriterState.None; + this.closeNode(node, options, level); + return r; + }; + XMLWriterBase2.prototype.openNode = function(node, options, level) { + }; + XMLWriterBase2.prototype.closeNode = function(node, options, level) { + }; + XMLWriterBase2.prototype.openAttribute = function(att, options, level) { + }; + XMLWriterBase2.prototype.closeAttribute = function(att, options, level) { + }; + return XMLWriterBase2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLStringWriter.js +var require_XMLStringWriter = __commonJS({ + "node_modules/xmlbuilder/lib/XMLStringWriter.js"(exports, module2) { + (function() { + var XMLStringWriter, XMLWriterBase, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + XMLWriterBase = require_XMLWriterBase(); + module2.exports = XMLStringWriter = function(superClass) { + extend(XMLStringWriter2, superClass); + function XMLStringWriter2(options) { + XMLStringWriter2.__super__.constructor.call(this, options); + } + __name(XMLStringWriter2, "XMLStringWriter"); + XMLStringWriter2.prototype.document = function(doc, options) { + var child, i, len, r, ref; + options = this.filterOptions(options); + r = ""; + ref = doc.children; + for (i = 0, len = ref.length; i < len; i++) { + child = ref[i]; + r += this.writeChildNode(child, options, 0); + } + if (options.pretty && r.slice(-options.newline.length) === options.newline) { + r = r.slice(0, -options.newline.length); + } + return r; + }; + return XMLStringWriter2; + }(XMLWriterBase); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDocument.js +var require_XMLDocument = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDocument.js"(exports, module2) { + (function() { + var NodeType, XMLDOMConfiguration, XMLDOMImplementation, XMLDocument, XMLNode, XMLStringWriter, XMLStringifier, isPlainObject, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + isPlainObject = require_Utility().isPlainObject; + XMLDOMImplementation = require_XMLDOMImplementation(); + XMLDOMConfiguration = require_XMLDOMConfiguration(); + XMLNode = require_XMLNode(); + NodeType = require_NodeType(); + XMLStringifier = require_XMLStringifier(); + XMLStringWriter = require_XMLStringWriter(); + module2.exports = XMLDocument = function(superClass) { + extend(XMLDocument2, superClass); + function XMLDocument2(options) { + XMLDocument2.__super__.constructor.call(this, null); + this.name = "#document"; + this.type = NodeType.Document; + this.documentURI = null; + this.domConfig = new XMLDOMConfiguration(); + options || (options = {}); + if (!options.writer) { + options.writer = new XMLStringWriter(); + } + this.options = options; + this.stringify = new XMLStringifier(options); + } + __name(XMLDocument2, "XMLDocument"); + Object.defineProperty(XMLDocument2.prototype, "implementation", { + value: new XMLDOMImplementation() + }); + Object.defineProperty(XMLDocument2.prototype, "doctype", { + get: function() { + var child, i, len, ref; + ref = this.children; + for (i = 0, len = ref.length; i < len; i++) { + child = ref[i]; + if (child.type === NodeType.DocType) { + return child; + } + } + return null; + } + }); + Object.defineProperty(XMLDocument2.prototype, "documentElement", { + get: function() { + return this.rootObject || null; + } + }); + Object.defineProperty(XMLDocument2.prototype, "inputEncoding", { + get: function() { + return null; + } + }); + Object.defineProperty(XMLDocument2.prototype, "strictErrorChecking", { + get: function() { + return false; + } + }); + Object.defineProperty(XMLDocument2.prototype, "xmlEncoding", { + get: function() { + if (this.children.length !== 0 && this.children[0].type === NodeType.Declaration) { + return this.children[0].encoding; + } else { + return null; + } + } + }); + Object.defineProperty(XMLDocument2.prototype, "xmlStandalone", { + get: function() { + if (this.children.length !== 0 && this.children[0].type === NodeType.Declaration) { + return this.children[0].standalone === "yes"; + } else { + return false; + } + } + }); + Object.defineProperty(XMLDocument2.prototype, "xmlVersion", { + get: function() { + if (this.children.length !== 0 && this.children[0].type === NodeType.Declaration) { + return this.children[0].version; + } else { + return "1.0"; + } + } + }); + Object.defineProperty(XMLDocument2.prototype, "URL", { + get: function() { + return this.documentURI; + } + }); + Object.defineProperty(XMLDocument2.prototype, "origin", { + get: function() { + return null; + } + }); + Object.defineProperty(XMLDocument2.prototype, "compatMode", { + get: function() { + return null; + } + }); + Object.defineProperty(XMLDocument2.prototype, "characterSet", { + get: function() { + return null; + } + }); + Object.defineProperty(XMLDocument2.prototype, "contentType", { + get: function() { + return null; + } + }); + XMLDocument2.prototype.end = function(writer) { + var writerOptions; + writerOptions = {}; + if (!writer) { + writer = this.options.writer; + } else if (isPlainObject(writer)) { + writerOptions = writer; + writer = this.options.writer; + } + return writer.document(this, writer.filterOptions(writerOptions)); + }; + XMLDocument2.prototype.toString = function(options) { + return this.options.writer.document(this, this.options.writer.filterOptions(options)); + }; + XMLDocument2.prototype.createElement = function(tagName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createDocumentFragment = function() { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createTextNode = function(data) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createComment = function(data) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createCDATASection = function(data) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createProcessingInstruction = function(target, data) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createAttribute = function(name) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createEntityReference = function(name) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.getElementsByTagName = function(tagname) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.importNode = function(importedNode, deep) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createElementNS = function(namespaceURI, qualifiedName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createAttributeNS = function(namespaceURI, qualifiedName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.getElementsByTagNameNS = function(namespaceURI, localName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.getElementById = function(elementId) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.adoptNode = function(source) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.normalizeDocument = function() { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.renameNode = function(node, namespaceURI, qualifiedName) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.getElementsByClassName = function(classNames) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createEvent = function(eventInterface) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createRange = function() { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createNodeIterator = function(root, whatToShow, filter) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + XMLDocument2.prototype.createTreeWalker = function(root, whatToShow, filter) { + throw new Error("This DOM method is not implemented." + this.debugInfo()); + }; + return XMLDocument2; + }(XMLNode); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLDocumentCB.js +var require_XMLDocumentCB = __commonJS({ + "node_modules/xmlbuilder/lib/XMLDocumentCB.js"(exports, module2) { + (function() { + var NodeType, WriterState, XMLAttribute, XMLCData, XMLComment, XMLDTDAttList, XMLDTDElement, XMLDTDEntity, XMLDTDNotation, XMLDeclaration, XMLDocType, XMLDocument, XMLDocumentCB, XMLElement, XMLProcessingInstruction, XMLRaw, XMLStringWriter, XMLStringifier, XMLText, getValue, isFunction, isObject, isPlainObject, ref, hasProp = {}.hasOwnProperty; + ref = require_Utility(), isObject = ref.isObject, isFunction = ref.isFunction, isPlainObject = ref.isPlainObject, getValue = ref.getValue; + NodeType = require_NodeType(); + XMLDocument = require_XMLDocument(); + XMLElement = require_XMLElement(); + XMLCData = require_XMLCData(); + XMLComment = require_XMLComment(); + XMLRaw = require_XMLRaw(); + XMLText = require_XMLText(); + XMLProcessingInstruction = require_XMLProcessingInstruction(); + XMLDeclaration = require_XMLDeclaration(); + XMLDocType = require_XMLDocType(); + XMLDTDAttList = require_XMLDTDAttList(); + XMLDTDEntity = require_XMLDTDEntity(); + XMLDTDElement = require_XMLDTDElement(); + XMLDTDNotation = require_XMLDTDNotation(); + XMLAttribute = require_XMLAttribute(); + XMLStringifier = require_XMLStringifier(); + XMLStringWriter = require_XMLStringWriter(); + WriterState = require_WriterState(); + module2.exports = XMLDocumentCB = /* @__PURE__ */ function() { + function XMLDocumentCB2(options, onData, onEnd) { + var writerOptions; + this.name = "?xml"; + this.type = NodeType.Document; + options || (options = {}); + writerOptions = {}; + if (!options.writer) { + options.writer = new XMLStringWriter(); + } else if (isPlainObject(options.writer)) { + writerOptions = options.writer; + options.writer = new XMLStringWriter(); + } + this.options = options; + this.writer = options.writer; + this.writerOptions = this.writer.filterOptions(writerOptions); + this.stringify = new XMLStringifier(options); + this.onDataCallback = onData || function() { + }; + this.onEndCallback = onEnd || function() { + }; + this.currentNode = null; + this.currentLevel = -1; + this.openTags = {}; + this.documentStarted = false; + this.documentCompleted = false; + this.root = null; + } + __name(XMLDocumentCB2, "XMLDocumentCB"); + XMLDocumentCB2.prototype.createChildNode = function(node) { + var att, attName, attributes, child, i, len, ref1, ref2; + switch (node.type) { + case NodeType.CData: + this.cdata(node.value); + break; + case NodeType.Comment: + this.comment(node.value); + break; + case NodeType.Element: + attributes = {}; + ref1 = node.attribs; + for (attName in ref1) { + if (!hasProp.call(ref1, attName)) + continue; + att = ref1[attName]; + attributes[attName] = att.value; + } + this.node(node.name, attributes); + break; + case NodeType.Dummy: + this.dummy(); + break; + case NodeType.Raw: + this.raw(node.value); + break; + case NodeType.Text: + this.text(node.value); + break; + case NodeType.ProcessingInstruction: + this.instruction(node.target, node.value); + break; + default: + throw new Error("This XML node type is not supported in a JS object: " + node.constructor.name); + } + ref2 = node.children; + for (i = 0, len = ref2.length; i < len; i++) { + child = ref2[i]; + this.createChildNode(child); + if (child.type === NodeType.Element) { + this.up(); + } + } + return this; + }; + XMLDocumentCB2.prototype.dummy = function() { + return this; + }; + XMLDocumentCB2.prototype.node = function(name, attributes, text) { + var ref1; + if (name == null) { + throw new Error("Missing node name."); + } + if (this.root && this.currentLevel === -1) { + throw new Error("Document can only have one root node. " + this.debugInfo(name)); + } + this.openCurrent(); + name = getValue(name); + if (attributes == null) { + attributes = {}; + } + attributes = getValue(attributes); + if (!isObject(attributes)) { + ref1 = [attributes, text], text = ref1[0], attributes = ref1[1]; + } + this.currentNode = new XMLElement(this, name, attributes); + this.currentNode.children = false; + this.currentLevel++; + this.openTags[this.currentLevel] = this.currentNode; + if (text != null) { + this.text(text); + } + return this; + }; + XMLDocumentCB2.prototype.element = function(name, attributes, text) { + var child, i, len, oldValidationFlag, ref1, root; + if (this.currentNode && this.currentNode.type === NodeType.DocType) { + this.dtdElement.apply(this, arguments); + } else { + if (Array.isArray(name) || isObject(name) || isFunction(name)) { + oldValidationFlag = this.options.noValidation; + this.options.noValidation = true; + root = new XMLDocument(this.options).element("TEMP_ROOT"); + root.element(name); + this.options.noValidation = oldValidationFlag; + ref1 = root.children; + for (i = 0, len = ref1.length; i < len; i++) { + child = ref1[i]; + this.createChildNode(child); + if (child.type === NodeType.Element) { + this.up(); + } + } + } else { + this.node(name, attributes, text); + } + } + return this; + }; + XMLDocumentCB2.prototype.attribute = function(name, value) { + var attName, attValue; + if (!this.currentNode || this.currentNode.children) { + throw new Error("att() can only be used immediately after an ele() call in callback mode. " + this.debugInfo(name)); + } + if (name != null) { + name = getValue(name); + } + if (isObject(name)) { + for (attName in name) { + if (!hasProp.call(name, attName)) + continue; + attValue = name[attName]; + this.attribute(attName, attValue); + } + } else { + if (isFunction(value)) { + value = value.apply(); + } + if (this.options.keepNullAttributes && value == null) { + this.currentNode.attribs[name] = new XMLAttribute(this, name, ""); + } else if (value != null) { + this.currentNode.attribs[name] = new XMLAttribute(this, name, value); + } + } + return this; + }; + XMLDocumentCB2.prototype.text = function(value) { + var node; + this.openCurrent(); + node = new XMLText(this, value); + this.onData(this.writer.text(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.cdata = function(value) { + var node; + this.openCurrent(); + node = new XMLCData(this, value); + this.onData(this.writer.cdata(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.comment = function(value) { + var node; + this.openCurrent(); + node = new XMLComment(this, value); + this.onData(this.writer.comment(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.raw = function(value) { + var node; + this.openCurrent(); + node = new XMLRaw(this, value); + this.onData(this.writer.raw(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.instruction = function(target, value) { + var i, insTarget, insValue, len, node; + this.openCurrent(); + if (target != null) { + target = getValue(target); + } + if (value != null) { + value = getValue(value); + } + if (Array.isArray(target)) { + for (i = 0, len = target.length; i < len; i++) { + insTarget = target[i]; + this.instruction(insTarget); + } + } else if (isObject(target)) { + for (insTarget in target) { + if (!hasProp.call(target, insTarget)) + continue; + insValue = target[insTarget]; + this.instruction(insTarget, insValue); + } + } else { + if (isFunction(value)) { + value = value.apply(); + } + node = new XMLProcessingInstruction(this, target, value); + this.onData(this.writer.processingInstruction(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + } + return this; + }; + XMLDocumentCB2.prototype.declaration = function(version3, encoding, standalone) { + var node; + this.openCurrent(); + if (this.documentStarted) { + throw new Error("declaration() must be the first node."); + } + node = new XMLDeclaration(this, version3, encoding, standalone); + this.onData(this.writer.declaration(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.doctype = function(root, pubID, sysID) { + this.openCurrent(); + if (root == null) { + throw new Error("Missing root node name."); + } + if (this.root) { + throw new Error("dtd() must come before the root node."); + } + this.currentNode = new XMLDocType(this, pubID, sysID); + this.currentNode.rootNodeName = root; + this.currentNode.children = false; + this.currentLevel++; + this.openTags[this.currentLevel] = this.currentNode; + return this; + }; + XMLDocumentCB2.prototype.dtdElement = function(name, value) { + var node; + this.openCurrent(); + node = new XMLDTDElement(this, name, value); + this.onData(this.writer.dtdElement(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.attList = function(elementName, attributeName, attributeType, defaultValueType, defaultValue) { + var node; + this.openCurrent(); + node = new XMLDTDAttList(this, elementName, attributeName, attributeType, defaultValueType, defaultValue); + this.onData(this.writer.dtdAttList(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.entity = function(name, value) { + var node; + this.openCurrent(); + node = new XMLDTDEntity(this, false, name, value); + this.onData(this.writer.dtdEntity(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.pEntity = function(name, value) { + var node; + this.openCurrent(); + node = new XMLDTDEntity(this, true, name, value); + this.onData(this.writer.dtdEntity(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.notation = function(name, value) { + var node; + this.openCurrent(); + node = new XMLDTDNotation(this, name, value); + this.onData(this.writer.dtdNotation(node, this.writerOptions, this.currentLevel + 1), this.currentLevel + 1); + return this; + }; + XMLDocumentCB2.prototype.up = function() { + if (this.currentLevel < 0) { + throw new Error("The document node has no parent."); + } + if (this.currentNode) { + if (this.currentNode.children) { + this.closeNode(this.currentNode); + } else { + this.openNode(this.currentNode); + } + this.currentNode = null; + } else { + this.closeNode(this.openTags[this.currentLevel]); + } + delete this.openTags[this.currentLevel]; + this.currentLevel--; + return this; + }; + XMLDocumentCB2.prototype.end = function() { + while (this.currentLevel >= 0) { + this.up(); + } + return this.onEnd(); + }; + XMLDocumentCB2.prototype.openCurrent = function() { + if (this.currentNode) { + this.currentNode.children = true; + return this.openNode(this.currentNode); + } + }; + XMLDocumentCB2.prototype.openNode = function(node) { + var att, chunk, name, ref1; + if (!node.isOpen) { + if (!this.root && this.currentLevel === 0 && node.type === NodeType.Element) { + this.root = node; + } + chunk = ""; + if (node.type === NodeType.Element) { + this.writerOptions.state = WriterState.OpenTag; + chunk = this.writer.indent(node, this.writerOptions, this.currentLevel) + "<" + node.name; + ref1 = node.attribs; + for (name in ref1) { + if (!hasProp.call(ref1, name)) + continue; + att = ref1[name]; + chunk += this.writer.attribute(att, this.writerOptions, this.currentLevel); + } + chunk += (node.children ? ">" : "/>") + this.writer.endline(node, this.writerOptions, this.currentLevel); + this.writerOptions.state = WriterState.InsideTag; + } else { + this.writerOptions.state = WriterState.OpenTag; + chunk = this.writer.indent(node, this.writerOptions, this.currentLevel) + ""; + } + chunk += this.writer.endline(node, this.writerOptions, this.currentLevel); + } + this.onData(chunk, this.currentLevel); + return node.isOpen = true; + } + }; + XMLDocumentCB2.prototype.closeNode = function(node) { + var chunk; + if (!node.isClosed) { + chunk = ""; + this.writerOptions.state = WriterState.CloseTag; + if (node.type === NodeType.Element) { + chunk = this.writer.indent(node, this.writerOptions, this.currentLevel) + "" + this.writer.endline(node, this.writerOptions, this.currentLevel); + } else { + chunk = this.writer.indent(node, this.writerOptions, this.currentLevel) + "]>" + this.writer.endline(node, this.writerOptions, this.currentLevel); + } + this.writerOptions.state = WriterState.None; + this.onData(chunk, this.currentLevel); + return node.isClosed = true; + } + }; + XMLDocumentCB2.prototype.onData = function(chunk, level) { + this.documentStarted = true; + return this.onDataCallback(chunk, level + 1); + }; + XMLDocumentCB2.prototype.onEnd = function() { + this.documentCompleted = true; + return this.onEndCallback(); + }; + XMLDocumentCB2.prototype.debugInfo = function(name) { + if (name == null) { + return ""; + } else { + return "node: <" + name + ">"; + } + }; + XMLDocumentCB2.prototype.ele = function() { + return this.element.apply(this, arguments); + }; + XMLDocumentCB2.prototype.nod = function(name, attributes, text) { + return this.node(name, attributes, text); + }; + XMLDocumentCB2.prototype.txt = function(value) { + return this.text(value); + }; + XMLDocumentCB2.prototype.dat = function(value) { + return this.cdata(value); + }; + XMLDocumentCB2.prototype.com = function(value) { + return this.comment(value); + }; + XMLDocumentCB2.prototype.ins = function(target, value) { + return this.instruction(target, value); + }; + XMLDocumentCB2.prototype.dec = function(version3, encoding, standalone) { + return this.declaration(version3, encoding, standalone); + }; + XMLDocumentCB2.prototype.dtd = function(root, pubID, sysID) { + return this.doctype(root, pubID, sysID); + }; + XMLDocumentCB2.prototype.e = function(name, attributes, text) { + return this.element(name, attributes, text); + }; + XMLDocumentCB2.prototype.n = function(name, attributes, text) { + return this.node(name, attributes, text); + }; + XMLDocumentCB2.prototype.t = function(value) { + return this.text(value); + }; + XMLDocumentCB2.prototype.d = function(value) { + return this.cdata(value); + }; + XMLDocumentCB2.prototype.c = function(value) { + return this.comment(value); + }; + XMLDocumentCB2.prototype.r = function(value) { + return this.raw(value); + }; + XMLDocumentCB2.prototype.i = function(target, value) { + return this.instruction(target, value); + }; + XMLDocumentCB2.prototype.att = function() { + if (this.currentNode && this.currentNode.type === NodeType.DocType) { + return this.attList.apply(this, arguments); + } else { + return this.attribute.apply(this, arguments); + } + }; + XMLDocumentCB2.prototype.a = function() { + if (this.currentNode && this.currentNode.type === NodeType.DocType) { + return this.attList.apply(this, arguments); + } else { + return this.attribute.apply(this, arguments); + } + }; + XMLDocumentCB2.prototype.ent = function(name, value) { + return this.entity(name, value); + }; + XMLDocumentCB2.prototype.pent = function(name, value) { + return this.pEntity(name, value); + }; + XMLDocumentCB2.prototype.not = function(name, value) { + return this.notation(name, value); + }; + return XMLDocumentCB2; + }(); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/XMLStreamWriter.js +var require_XMLStreamWriter = __commonJS({ + "node_modules/xmlbuilder/lib/XMLStreamWriter.js"(exports, module2) { + (function() { + var NodeType, WriterState, XMLStreamWriter, XMLWriterBase, extend = /* @__PURE__ */ __name(function(child, parent) { + for (var key in parent) { + if (hasProp.call(parent, key)) + child[key] = parent[key]; + } + function ctor() { + this.constructor = child; + } + __name(ctor, "ctor"); + ctor.prototype = parent.prototype; + child.prototype = new ctor(); + child.__super__ = parent.prototype; + return child; + }, "extend"), hasProp = {}.hasOwnProperty; + NodeType = require_NodeType(); + XMLWriterBase = require_XMLWriterBase(); + WriterState = require_WriterState(); + module2.exports = XMLStreamWriter = function(superClass) { + extend(XMLStreamWriter2, superClass); + function XMLStreamWriter2(stream, options) { + this.stream = stream; + XMLStreamWriter2.__super__.constructor.call(this, options); + } + __name(XMLStreamWriter2, "XMLStreamWriter"); + XMLStreamWriter2.prototype.endline = function(node, options, level) { + if (node.isLastRootNode && options.state === WriterState.CloseTag) { + return ""; + } else { + return XMLStreamWriter2.__super__.endline.call(this, node, options, level); + } + }; + XMLStreamWriter2.prototype.document = function(doc, options) { + var child, i, j, k, len, len1, ref, ref1, results; + ref = doc.children; + for (i = j = 0, len = ref.length; j < len; i = ++j) { + child = ref[i]; + child.isLastRootNode = i === doc.children.length - 1; + } + options = this.filterOptions(options); + ref1 = doc.children; + results = []; + for (k = 0, len1 = ref1.length; k < len1; k++) { + child = ref1[k]; + results.push(this.writeChildNode(child, options, 0)); + } + return results; + }; + XMLStreamWriter2.prototype.attribute = function(att, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.attribute.call(this, att, options, level)); + }; + XMLStreamWriter2.prototype.cdata = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.cdata.call(this, node, options, level)); + }; + XMLStreamWriter2.prototype.comment = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.comment.call(this, node, options, level)); + }; + XMLStreamWriter2.prototype.declaration = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.declaration.call(this, node, options, level)); + }; + XMLStreamWriter2.prototype.docType = function(node, options, level) { + var child, j, len, ref; + level || (level = 0); + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + this.stream.write(this.indent(node, options, level)); + this.stream.write(" 0) { + this.stream.write(" ["); + this.stream.write(this.endline(node, options, level)); + options.state = WriterState.InsideTag; + ref = node.children; + for (j = 0, len = ref.length; j < len; j++) { + child = ref[j]; + this.writeChildNode(child, options, level + 1); + } + options.state = WriterState.CloseTag; + this.stream.write("]"); + } + options.state = WriterState.CloseTag; + this.stream.write(options.spaceBeforeSlash + ">"); + this.stream.write(this.endline(node, options, level)); + options.state = WriterState.None; + return this.closeNode(node, options, level); + }; + XMLStreamWriter2.prototype.element = function(node, options, level) { + var att, child, childNodeCount, firstChildNode, j, len, name, prettySuppressed, ref, ref1; + level || (level = 0); + this.openNode(node, options, level); + options.state = WriterState.OpenTag; + this.stream.write(this.indent(node, options, level) + "<" + node.name); + ref = node.attribs; + for (name in ref) { + if (!hasProp.call(ref, name)) + continue; + att = ref[name]; + this.attribute(att, options, level); + } + childNodeCount = node.children.length; + firstChildNode = childNodeCount === 0 ? null : node.children[0]; + if (childNodeCount === 0 || node.children.every(function(e) { + return (e.type === NodeType.Text || e.type === NodeType.Raw) && e.value === ""; + })) { + if (options.allowEmpty) { + this.stream.write(">"); + options.state = WriterState.CloseTag; + this.stream.write(""); + } else { + options.state = WriterState.CloseTag; + this.stream.write(options.spaceBeforeSlash + "/>"); + } + } else if (options.pretty && childNodeCount === 1 && (firstChildNode.type === NodeType.Text || firstChildNode.type === NodeType.Raw) && firstChildNode.value != null) { + this.stream.write(">"); + options.state = WriterState.InsideTag; + options.suppressPrettyCount++; + prettySuppressed = true; + this.writeChildNode(firstChildNode, options, level + 1); + options.suppressPrettyCount--; + prettySuppressed = false; + options.state = WriterState.CloseTag; + this.stream.write(""); + } else { + this.stream.write(">" + this.endline(node, options, level)); + options.state = WriterState.InsideTag; + ref1 = node.children; + for (j = 0, len = ref1.length; j < len; j++) { + child = ref1[j]; + this.writeChildNode(child, options, level + 1); + } + options.state = WriterState.CloseTag; + this.stream.write(this.indent(node, options, level) + ""); + } + this.stream.write(this.endline(node, options, level)); + options.state = WriterState.None; + return this.closeNode(node, options, level); + }; + XMLStreamWriter2.prototype.processingInstruction = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.processingInstruction.call(this, node, options, level)); + }; + XMLStreamWriter2.prototype.raw = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.raw.call(this, node, options, level)); + }; + XMLStreamWriter2.prototype.text = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.text.call(this, node, options, level)); + }; + XMLStreamWriter2.prototype.dtdAttList = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.dtdAttList.call(this, node, options, level)); + }; + XMLStreamWriter2.prototype.dtdElement = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.dtdElement.call(this, node, options, level)); + }; + XMLStreamWriter2.prototype.dtdEntity = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.dtdEntity.call(this, node, options, level)); + }; + XMLStreamWriter2.prototype.dtdNotation = function(node, options, level) { + return this.stream.write(XMLStreamWriter2.__super__.dtdNotation.call(this, node, options, level)); + }; + return XMLStreamWriter2; + }(XMLWriterBase); + }).call(exports); + } +}); + +// node_modules/xmlbuilder/lib/index.js +var require_lib2 = __commonJS({ + "node_modules/xmlbuilder/lib/index.js"(exports, module2) { + (function() { + var NodeType, WriterState, XMLDOMImplementation, XMLDocument, XMLDocumentCB, XMLStreamWriter, XMLStringWriter, assign, isFunction, ref; + ref = require_Utility(), assign = ref.assign, isFunction = ref.isFunction; + XMLDOMImplementation = require_XMLDOMImplementation(); + XMLDocument = require_XMLDocument(); + XMLDocumentCB = require_XMLDocumentCB(); + XMLStringWriter = require_XMLStringWriter(); + XMLStreamWriter = require_XMLStreamWriter(); + NodeType = require_NodeType(); + WriterState = require_WriterState(); + module2.exports.create = function(name, xmldec, doctype, options) { + var doc, root; + if (name == null) { + throw new Error("Root element needs a name."); + } + options = assign({}, xmldec, doctype, options); + doc = new XMLDocument(options); + root = doc.element(name); + if (!options.headless) { + doc.declaration(options); + if (options.pubID != null || options.sysID != null) { + doc.dtd(options); + } + } + return root; + }; + module2.exports.begin = function(options, onData, onEnd) { + var ref1; + if (isFunction(options)) { + ref1 = [options, onData], onData = ref1[0], onEnd = ref1[1]; + options = {}; + } + if (onData) { + return new XMLDocumentCB(options, onData, onEnd); + } else { + return new XMLDocument(options); + } + }; + module2.exports.stringWriter = function(options) { + return new XMLStringWriter(options); + }; + module2.exports.streamWriter = function(stream, options) { + return new XMLStreamWriter(stream, options); + }; + module2.exports.implementation = new XMLDOMImplementation(); + module2.exports.nodeType = NodeType; + module2.exports.writerState = WriterState; + }).call(exports); + } +}); + +// node_modules/xml2js/lib/builder.js +var require_builder = __commonJS({ + "node_modules/xml2js/lib/builder.js"(exports) { + (function() { + "use strict"; + var builder, defaults, escapeCDATA, requiresCDATA, wrapCDATA, hasProp = {}.hasOwnProperty; + builder = require_lib2(); + defaults = require_defaults().defaults; + requiresCDATA = /* @__PURE__ */ __name(function(entry) { + return typeof entry === "string" && (entry.indexOf("&") >= 0 || entry.indexOf(">") >= 0 || entry.indexOf("<") >= 0); + }, "requiresCDATA"); + wrapCDATA = /* @__PURE__ */ __name(function(entry) { + return ""; + }, "wrapCDATA"); + escapeCDATA = /* @__PURE__ */ __name(function(entry) { + return entry.replace("]]>", "]]]]>"); + }, "escapeCDATA"); + exports.Builder = /* @__PURE__ */ function() { + function Builder(opts) { + var key, ref, value; + this.options = {}; + ref = defaults["0.2"]; + for (key in ref) { + if (!hasProp.call(ref, key)) + continue; + value = ref[key]; + this.options[key] = value; + } + for (key in opts) { + if (!hasProp.call(opts, key)) + continue; + value = opts[key]; + this.options[key] = value; + } + } + __name(Builder, "Builder"); + Builder.prototype.buildObject = function(rootObj) { + var attrkey, charkey, render, rootElement, rootName; + attrkey = this.options.attrkey; + charkey = this.options.charkey; + if (Object.keys(rootObj).length === 1 && this.options.rootName === defaults["0.2"].rootName) { + rootName = Object.keys(rootObj)[0]; + rootObj = rootObj[rootName]; + } else { + rootName = this.options.rootName; + } + render = function(_this) { + return function(element, obj) { + var attr, child, entry, index, key, value; + if (typeof obj !== "object") { + if (_this.options.cdata && requiresCDATA(obj)) { + element.raw(wrapCDATA(obj)); + } else { + element.txt(obj); + } + } else if (Array.isArray(obj)) { + for (index in obj) { + if (!hasProp.call(obj, index)) + continue; + child = obj[index]; + for (key in child) { + entry = child[key]; + element = render(element.ele(key), entry).up(); + } + } + } else { + for (key in obj) { + if (!hasProp.call(obj, key)) + continue; + child = obj[key]; + if (key === attrkey) { + if (typeof child === "object") { + for (attr in child) { + value = child[attr]; + element = element.att(attr, value); + } + } + } else if (key === charkey) { + if (_this.options.cdata && requiresCDATA(child)) { + element = element.raw(wrapCDATA(child)); + } else { + element = element.txt(child); + } + } else if (Array.isArray(child)) { + for (index in child) { + if (!hasProp.call(child, index)) + continue; + entry = child[index]; + if (typeof entry === "string") { + if (_this.options.cdata && requiresCDATA(entry)) { + element = element.ele(key).raw(wrapCDATA(entry)).up(); + } else { + element = element.ele(key, entry).up(); + } + } else { + element = render(element.ele(key), entry).up(); + } + } + } else if (typeof child === "object") { + element = render(element.ele(key), child).up(); + } else { + if (typeof child === "string" && _this.options.cdata && requiresCDATA(child)) { + element = element.ele(key).raw(wrapCDATA(child)).up(); + } else { + if (child == null) { + child = ""; + } + element = element.ele(key, child.toString()).up(); + } + } + } + } + return element; + }; + }(this); + rootElement = builder.create(rootName, this.options.xmldec, this.options.doctype, { + headless: this.options.headless, + allowSurrogateChars: this.options.allowSurrogateChars + }); + return render(rootElement, rootObj).end(this.options.renderOpts); + }; + return Builder; + }(); + }).call(exports); + } +}); + +// node_modules/sax/lib/sax.js +var require_sax = __commonJS({ + "node_modules/sax/lib/sax.js"(exports) { + (function(sax) { + sax.parser = function(strict, opt) { + return new SAXParser(strict, opt); + }; + sax.SAXParser = SAXParser; + sax.SAXStream = SAXStream; + sax.createStream = createStream; + sax.MAX_BUFFER_LENGTH = 64 * 1024; + var buffers = [ + "comment", + "sgmlDecl", + "textNode", + "tagName", + "doctype", + "procInstName", + "procInstBody", + "entity", + "attribName", + "attribValue", + "cdata", + "script" + ]; + sax.EVENTS = [ + "text", + "processinginstruction", + "sgmldeclaration", + "doctype", + "comment", + "opentagstart", + "attribute", + "opentag", + "closetag", + "opencdata", + "cdata", + "closecdata", + "error", + "end", + "ready", + "script", + "opennamespace", + "closenamespace" + ]; + function SAXParser(strict, opt) { + if (!(this instanceof SAXParser)) { + return new SAXParser(strict, opt); + } + var parser = this; + clearBuffers(parser); + parser.q = parser.c = ""; + parser.bufferCheckPosition = sax.MAX_BUFFER_LENGTH; + parser.opt = opt || {}; + parser.opt.lowercase = parser.opt.lowercase || parser.opt.lowercasetags; + parser.looseCase = parser.opt.lowercase ? "toLowerCase" : "toUpperCase"; + parser.tags = []; + parser.closed = parser.closedRoot = parser.sawRoot = false; + parser.tag = parser.error = null; + parser.strict = !!strict; + parser.noscript = !!(strict || parser.opt.noscript); + parser.state = S.BEGIN; + parser.strictEntities = parser.opt.strictEntities; + parser.ENTITIES = parser.strictEntities ? Object.create(sax.XML_ENTITIES) : Object.create(sax.ENTITIES); + parser.attribList = []; + if (parser.opt.xmlns) { + parser.ns = Object.create(rootNS); + } + parser.trackPosition = parser.opt.position !== false; + if (parser.trackPosition) { + parser.position = parser.line = parser.column = 0; + } + emit(parser, "onready"); + } + __name(SAXParser, "SAXParser"); + if (!Object.create) { + Object.create = function(o) { + function F() { + } + __name(F, "F"); + F.prototype = o; + var newf = new F(); + return newf; + }; + } + if (!Object.keys) { + Object.keys = function(o) { + var a = []; + for (var i in o) + if (o.hasOwnProperty(i)) + a.push(i); + return a; + }; + } + function checkBufferLength(parser) { + var maxAllowed = Math.max(sax.MAX_BUFFER_LENGTH, 10); + var maxActual = 0; + for (var i = 0, l = buffers.length; i < l; i++) { + var len = parser[buffers[i]].length; + if (len > maxAllowed) { + switch (buffers[i]) { + case "textNode": + closeText(parser); + break; + case "cdata": + emitNode(parser, "oncdata", parser.cdata); + parser.cdata = ""; + break; + case "script": + emitNode(parser, "onscript", parser.script); + parser.script = ""; + break; + default: + error(parser, "Max buffer length exceeded: " + buffers[i]); + } + } + maxActual = Math.max(maxActual, len); + } + var m = sax.MAX_BUFFER_LENGTH - maxActual; + parser.bufferCheckPosition = m + parser.position; + } + __name(checkBufferLength, "checkBufferLength"); + function clearBuffers(parser) { + for (var i = 0, l = buffers.length; i < l; i++) { + parser[buffers[i]] = ""; + } + } + __name(clearBuffers, "clearBuffers"); + function flushBuffers(parser) { + closeText(parser); + if (parser.cdata !== "") { + emitNode(parser, "oncdata", parser.cdata); + parser.cdata = ""; + } + if (parser.script !== "") { + emitNode(parser, "onscript", parser.script); + parser.script = ""; + } + } + __name(flushBuffers, "flushBuffers"); + SAXParser.prototype = { + end: function() { + end(this); + }, + write, + resume: function() { + this.error = null; + return this; + }, + close: function() { + return this.write(null); + }, + flush: function() { + flushBuffers(this); + } + }; + var Stream; + try { + Stream = require("stream").Stream; + } catch (ex) { + Stream = /* @__PURE__ */ __name(function() { + }, "Stream"); + } + var streamWraps = sax.EVENTS.filter(function(ev) { + return ev !== "error" && ev !== "end"; + }); + function createStream(strict, opt) { + return new SAXStream(strict, opt); + } + __name(createStream, "createStream"); + function SAXStream(strict, opt) { + if (!(this instanceof SAXStream)) { + return new SAXStream(strict, opt); + } + Stream.apply(this); + this._parser = new SAXParser(strict, opt); + this.writable = true; + this.readable = true; + var me = this; + this._parser.onend = function() { + me.emit("end"); + }; + this._parser.onerror = function(er) { + me.emit("error", er); + me._parser.error = null; + }; + this._decoder = null; + streamWraps.forEach(function(ev) { + Object.defineProperty(me, "on" + ev, { + get: function() { + return me._parser["on" + ev]; + }, + set: function(h) { + if (!h) { + me.removeAllListeners(ev); + me._parser["on" + ev] = h; + return h; + } + me.on(ev, h); + }, + enumerable: true, + configurable: false + }); + }); + } + __name(SAXStream, "SAXStream"); + SAXStream.prototype = Object.create(Stream.prototype, { + constructor: { + value: SAXStream + } + }); + SAXStream.prototype.write = function(data) { + if (typeof Buffer === "function" && typeof Buffer.isBuffer === "function" && Buffer.isBuffer(data)) { + if (!this._decoder) { + var SD = require("string_decoder").StringDecoder; + this._decoder = new SD("utf8"); + } + data = this._decoder.write(data); + } + this._parser.write(data.toString()); + this.emit("data", data); + return true; + }; + SAXStream.prototype.end = function(chunk) { + if (chunk && chunk.length) { + this.write(chunk); + } + this._parser.end(); + return true; + }; + SAXStream.prototype.on = function(ev, handler) { + var me = this; + if (!me._parser["on" + ev] && streamWraps.indexOf(ev) !== -1) { + me._parser["on" + ev] = function() { + var args = arguments.length === 1 ? [arguments[0]] : Array.apply(null, arguments); + args.splice(0, 0, ev); + me.emit.apply(me, args); + }; + } + return Stream.prototype.on.call(me, ev, handler); + }; + var CDATA = "[CDATA["; + var DOCTYPE = "DOCTYPE"; + var XML_NAMESPACE = "http://www.w3.org/XML/1998/namespace"; + var XMLNS_NAMESPACE = "http://www.w3.org/2000/xmlns/"; + var rootNS = { xml: XML_NAMESPACE, xmlns: XMLNS_NAMESPACE }; + var nameStart = /[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/; + var nameBody = /[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/; + var entityStart = /[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/; + var entityBody = /[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/; + function isWhitespace(c) { + return c === " " || c === "\n" || c === "\r" || c === " "; + } + __name(isWhitespace, "isWhitespace"); + function isQuote(c) { + return c === '"' || c === "'"; + } + __name(isQuote, "isQuote"); + function isAttribEnd(c) { + return c === ">" || isWhitespace(c); + } + __name(isAttribEnd, "isAttribEnd"); + function isMatch(regex, c) { + return regex.test(c); + } + __name(isMatch, "isMatch"); + function notMatch(regex, c) { + return !isMatch(regex, c); + } + __name(notMatch, "notMatch"); + var S = 0; + sax.STATE = { + BEGIN: S++, + // leading byte order mark or whitespace + BEGIN_WHITESPACE: S++, + // leading whitespace + TEXT: S++, + // general stuff + TEXT_ENTITY: S++, + // & and such. + OPEN_WAKA: S++, + // < + SGML_DECL: S++, + // + SCRIPT: S++, + //