updates 13.2.3 → 13.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/bin/updates.js +2 -2
  2. package/package.json +6 -16
package/bin/updates.js CHANGED
@@ -63,7 +63,7 @@ Content-Type: ${n.type||"application/octet-stream"}\r
63
63
  `}):c&&typeof c=="object"?t.push(n):r+=ki(n)+i+ki(c)+Pl}),A.section&&r.length&&(r="["+ki(A.section)+"]"+Pl+r),t.forEach(function(n,o,g){var c=vf(n).join("\\."),E=(A.section?A.section+".":"")+c,C=Kf(e[n],{section:E,whitespace:A.whitespace});r.length&&C.length&&(r+=Pl),r+=C}),r}function vf(e){return e.replace(/\1/g,"LITERAL\\1LITERAL").replace(/\\\./g,"").split(/\./).map(function(A){return A.replace(/\1/g,"\\.").replace(/\2LITERAL\\1LITERAL\2/g,"")})}function kL(e){var A={},t=A,r=null,i=/^\[([^\]]*)\]$|^([^=]+)(=(.*))?$/i,n=e.split(/[\r\n]+/g);return n.forEach(function(o,g,c){if(!(!o||o.match(/^\s*[;#]/))){var E=o.match(i);if(!!E){if(E[1]!==void 0){if(r=fa(E[1]),r==="__proto__"){t={};return}t=A[r]=A[r]||{};return}var C=fa(E[2]);if(C!=="__proto__"){var I=E[3]?fa(E[4]):!0;switch(I){case"true":case"false":case"null":I=JSON.parse(I)}if(C.length>2&&C.slice(-2)==="[]"){if(C=C.substring(0,C.length-2),C==="__proto__")return;t[C]?Array.isArray(t[C])||(t[C]=[t[C]]):t[C]=[]}Array.isArray(t[C])?t[C].push(I):t[C]=I}}}}),Object.keys(A).filter(function(o,g,c){if(!A[o]||typeof A[o]!="object"||Array.isArray(A[o]))return!1;var E=vf(o),C=A,I=E.pop(),Q=I.replace(/\\\./g,".");return E.forEach(function(B,u,w){B!=="__proto__"&&((!C[B]||typeof C[B]!="object")&&(C[B]={}),C=C[B])}),C===A&&Q===I?!1:(C[Q]=A[o],!0)}).forEach(function(o,g,c){delete A[o]}),A}function Vf(e){return e.charAt(0)==='"'&&e.slice(-1)==='"'||e.charAt(0)==="'"&&e.slice(-1)==="'"}function ki(e){return typeof e!="string"||e.match(/[=\r\n]/)||e.match(/^\[/)||e.length>1&&Vf(e)||e!==e.trim()?JSON.stringify(e):e.replace(/;/g,"\\;").replace(/#/g,"\\#")}function fa(e,A){if(e=(e||"").trim(),Vf(e)){e.charAt(0)==="'"&&(e=e.substr(1,e.length-2));try{e=JSON.parse(e)}catch{}}else{for(var t=!1,r="",i=0,n=e.length;i<n;i++){var o=e.charAt(i);if(t)"\\;#".indexOf(o)!==-1?r+=o:r+="\\"+o,t=!1;else{if(";#".indexOf(o)!==-1)break;o==="\\"?t=!0:r+=o}}return t&&(r+="\\"),r.trim()}return e}});var Of=p((NJ,Wf)=>{"use strict";var zl=1,_f=2;function RL(){return""}function NL(e,A,t){return e.slice(A,t).replace(/\S/g," ")}Wf.exports=function(e,A){A=A||{};for(var t,r,i=!1,n=!1,o=0,g="",c=A.whitespace===!1?RL:NL,E=0;E<e.length;E++){if(t=e[E],r=e[E+1],!n&&t==='"'){var C=e[E-1]==="\\"&&e[E-2]!=="\\";C||(i=!i)}if(!i){if(!n&&t+r==="//")g+=e.slice(o,E),o=E,n=zl,E++;else if(n===zl&&t+r===`\r
64
64
  `){E++,n=!1,g+=c(e,o,E),o=E;continue}else if(n===zl&&t===`
65
65
  `)n=!1,g+=c(e,o,E),o=E;else if(!n&&t+r==="/*"){g+=e.slice(o,E),o=E,n=_f,E++;continue}else if(n===_f&&t+r==="*/"){E++,n=!1,g+=c(e,o,E+1),o=E+1;continue}}}return g+(n?c(e.substr(o)):e.substr(o))}});var zf=p(Ri=>{"use strict";var Pf=k("fs"),FL=xf(),as=k("path"),LL=Of(),UL=Ri.parse=function(e){return/^\s*{/.test(e)?JSON.parse(LL(e)):FL.parse(e)},ML=Ri.file=function(){var e=[].slice.call(arguments).filter(function(i){return i!=null});for(var A in e)if(typeof e[A]!="string")return;var t=as.join.apply(null,e),r;try{return Pf.readFileSync(t,"utf-8")}catch{return}},FJ=Ri.json=function(){var e=ML.apply(null,arguments);return e?UL(e):null},LJ=Ri.env=function(e,A){A=A||process.env;var t={},r=e.length;for(var i in A)if(i.toLowerCase().indexOf(e.toLowerCase())===0){for(var n=i.substring(r).split("__"),o;(o=n.indexOf(""))>-1;)n.splice(o,1);var g=t;n.forEach(function(E,C){!E||typeof g!="object"||(C===n.length-1&&(g[E]=A[i]),g[E]===void 0&&(g[E]={}),g=g[E])})}return t},UJ=Ri.find=function(){var e=as.join.apply(null,[].slice.call(arguments));function A(t,r){var i=as.join(t,r);try{return Pf.statSync(i),i}catch{if(as.dirname(t)!==t)return A(as.dirname(t),r)}}return A(process.cwd(),e)}});var ed=p((qJ,Ad)=>{"use strict";function Xf(e){return e instanceof Buffer||e instanceof Date||e instanceof RegExp}function jf(e){if(e instanceof Buffer){var A=Buffer.alloc?Buffer.alloc(e.length):new Buffer(e.length);return e.copy(A),A}else{if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp)return new RegExp(e);throw new Error("Unexpected situation")}}function $f(e){var A=[];return e.forEach(function(t,r){typeof t=="object"&&t!==null?Array.isArray(t)?A[r]=$f(t):Xf(t)?A[r]=jf(t):A[r]=Zl({},t):A[r]=t}),A}function Zf(e,A){return A==="__proto__"?void 0:e[A]}var Zl=Ad.exports=function(){if(arguments.length<1||typeof arguments[0]!="object")return!1;if(arguments.length<2)return arguments[0];var e=arguments[0],A=Array.prototype.slice.call(arguments,1),t,r,i;return A.forEach(function(n){typeof n!="object"||n===null||Array.isArray(n)||Object.keys(n).forEach(function(o){if(r=Zf(e,o),t=Zf(n,o),t!==e)if(typeof t!="object"||t===null){e[o]=t;return}else if(Array.isArray(t)){e[o]=$f(t);return}else if(Xf(t)){e[o]=jf(t);return}else if(typeof r!="object"||r===null||Array.isArray(r)){e[o]=Zl({},t);return}else{e[o]=Zl(r,t);return}})}),e}});var da=p((TJ,id)=>{var gs=zf(),Ni=k("path").join,qL=ed(),td="/etc",rd=process.platform==="win32",cs=rd?process.env.USERPROFILE:process.env.HOME;id.exports=function(e,A,t,r){if(typeof e!="string")throw new Error("rc(name): name *must* be string");t||(t=Yl()(process.argv.slice(2))),A=(typeof A=="string"?gs.json(A):A)||{},r=r||gs.parse;var i=gs.env(e+"_"),n=[A],o=[];function g(c){if(!(o.indexOf(c)>=0)){var E=gs.file(c);E&&(n.push(r(E)),o.push(c))}}return rd||[Ni(td,e,"config"),Ni(td,e+"rc")].forEach(g),cs&&[Ni(cs,".config",e,"config"),Ni(cs,".config",e),Ni(cs,"."+e,"config"),Ni(cs,"."+e+"rc")].forEach(g),g(gs.find("."+e+"rc")),i.config&&g(i.config),t.config&&g(t.config),qL.apply(null,n.concat([i,t,o.length?{configs:o,config:o[o.length-1]}:void 0]))}});var Ed=p((YJ,ld)=>{var Xl=k("url"),gd=Hf(),TL=gd.decodeBase64,YL=gd.encodeBase64,nd=":_authToken",sd=":_auth",od=":username",ad=":_password";ld.exports=function(){var e,A;return arguments.length>=2?(e=arguments[0],A=arguments[1]):typeof arguments[0]=="string"?e=arguments[0]:A=arguments[0],A=A||{},A.npmrc=A.npmrc||da()("npm",{registry:"https://registry.npmjs.org/"},{config:process.env.npm_config_userconfig||process.env.NPM_CONFIG_USERCONFIG}),e=e||A.npmrc.registry,cd(e,A)||JL(A.npmrc)};function cd(e,A){for(var t=Xl.parse(e,!1,!0),r;r!=="/"&&t.pathname!==r;){r=t.pathname||"/";var i="//"+t.host+r.replace(/\/$/,""),n=HL(i,A.npmrc);if(n)return n;if(!A.recursive)return/\/$/.test(e)?void 0:cd(Xl.resolve(e,"."),A);t.pathname=Xl.resolve(GL(r),"..")||"/"}}function JL(e){if(!!e._auth){var A=ya(e._auth);return{token:A,type:"Basic"}}}function GL(e){return e[e.length-1]==="/"?e:e+"/"}function HL(e,A){var t=KL(A[e+nd]||A[e+"/"+nd]);if(t)return t;var r=A[e+od]||A[e+"/"+od],i=A[e+ad]||A[e+"/"+ad],n=vL(r,i);if(n)return n;var o=VL(A[e+sd]||A[e+"/"+sd]);if(o)return o}function ya(e){return e.replace(/^\$\{?([^}]*)\}?$/,function(A,t){return process.env[t]})}function KL(e){if(!!e){var A=ya(e);return{token:A,type:"Bearer"}}}function vL(e,A){if(!(!e||!A)){var t=TL(ya(A)),r=YL(e+":"+t);return{token:r,type:"Basic",password:t,username:e}}}function VL(e){if(!!e){var A=ya(e);return{token:A,type:"Basic"}}}});var Id=p((JJ,Cd)=>{Cd.exports=function(e,A){var t=A||da()("npm",{registry:"https://registry.npmjs.org/"}),r=t[e+":registry"]||t.registry;return r.slice(-1)==="/"?r:r+"/"}});var ls=p((GJ,Qd)=>{var xL="2.0.0",_L=Number.MAX_SAFE_INTEGER||9007199254740991,WL=16;Qd.exports={SEMVER_SPEC_VERSION:xL,MAX_LENGTH:256,MAX_SAFE_INTEGER:_L,MAX_SAFE_COMPONENT_LENGTH:WL}});var Es=p((HJ,Bd)=>{var OL=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};Bd.exports=OL});var Fr=p((Xt,hd)=>{var{MAX_SAFE_COMPONENT_LENGTH:jl}=ls(),PL=Es();Xt=hd.exports={};var zL=Xt.re=[],M=Xt.src=[],q=Xt.t={},ZL=0,W=(e,A,t)=>{let r=ZL++;PL(e,r,A),q[e]=r,M[r]=A,zL[r]=new RegExp(A,t?"g":void 0)};W("NUMERICIDENTIFIER","0|[1-9]\\d*");W("NUMERICIDENTIFIERLOOSE","[0-9]+");W("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");W("MAINVERSION",`(${M[q.NUMERICIDENTIFIER]})\\.(${M[q.NUMERICIDENTIFIER]})\\.(${M[q.NUMERICIDENTIFIER]})`);W("MAINVERSIONLOOSE",`(${M[q.NUMERICIDENTIFIERLOOSE]})\\.(${M[q.NUMERICIDENTIFIERLOOSE]})\\.(${M[q.NUMERICIDENTIFIERLOOSE]})`);W("PRERELEASEIDENTIFIER",`(?:${M[q.NUMERICIDENTIFIER]}|${M[q.NONNUMERICIDENTIFIER]})`);W("PRERELEASEIDENTIFIERLOOSE",`(?:${M[q.NUMERICIDENTIFIERLOOSE]}|${M[q.NONNUMERICIDENTIFIER]})`);W("PRERELEASE",`(?:-(${M[q.PRERELEASEIDENTIFIER]}(?:\\.${M[q.PRERELEASEIDENTIFIER]})*))`);W("PRERELEASELOOSE",`(?:-?(${M[q.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${M[q.PRERELEASEIDENTIFIERLOOSE]})*))`);W("BUILDIDENTIFIER","[0-9A-Za-z-]+");W("BUILD",`(?:\\+(${M[q.BUILDIDENTIFIER]}(?:\\.${M[q.BUILDIDENTIFIER]})*))`);W("FULLPLAIN",`v?${M[q.MAINVERSION]}${M[q.PRERELEASE]}?${M[q.BUILD]}?`);W("FULL",`^${M[q.FULLPLAIN]}$`);W("LOOSEPLAIN",`[v=\\s]*${M[q.MAINVERSIONLOOSE]}${M[q.PRERELEASELOOSE]}?${M[q.BUILD]}?`);W("LOOSE",`^${M[q.LOOSEPLAIN]}$`);W("GTLT","((?:<|>)?=?)");W("XRANGEIDENTIFIERLOOSE",`${M[q.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);W("XRANGEIDENTIFIER",`${M[q.NUMERICIDENTIFIER]}|x|X|\\*`);W("XRANGEPLAIN",`[v=\\s]*(${M[q.XRANGEIDENTIFIER]})(?:\\.(${M[q.XRANGEIDENTIFIER]})(?:\\.(${M[q.XRANGEIDENTIFIER]})(?:${M[q.PRERELEASE]})?${M[q.BUILD]}?)?)?`);W("XRANGEPLAINLOOSE",`[v=\\s]*(${M[q.XRANGEIDENTIFIERLOOSE]})(?:\\.(${M[q.XRANGEIDENTIFIERLOOSE]})(?:\\.(${M[q.XRANGEIDENTIFIERLOOSE]})(?:${M[q.PRERELEASELOOSE]})?${M[q.BUILD]}?)?)?`);W("XRANGE",`^${M[q.GTLT]}\\s*${M[q.XRANGEPLAIN]}$`);W("XRANGELOOSE",`^${M[q.GTLT]}\\s*${M[q.XRANGEPLAINLOOSE]}$`);W("COERCE",`(^|[^\\d])(\\d{1,${jl}})(?:\\.(\\d{1,${jl}}))?(?:\\.(\\d{1,${jl}}))?(?:$|[^\\d])`);W("COERCERTL",M[q.COERCE],!0);W("LONETILDE","(?:~>?)");W("TILDETRIM",`(\\s*)${M[q.LONETILDE]}\\s+`,!0);Xt.tildeTrimReplace="$1~";W("TILDE",`^${M[q.LONETILDE]}${M[q.XRANGEPLAIN]}$`);W("TILDELOOSE",`^${M[q.LONETILDE]}${M[q.XRANGEPLAINLOOSE]}$`);W("LONECARET","(?:\\^)");W("CARETTRIM",`(\\s*)${M[q.LONECARET]}\\s+`,!0);Xt.caretTrimReplace="$1^";W("CARET",`^${M[q.LONECARET]}${M[q.XRANGEPLAIN]}$`);W("CARETLOOSE",`^${M[q.LONECARET]}${M[q.XRANGEPLAINLOOSE]}$`);W("COMPARATORLOOSE",`^${M[q.GTLT]}\\s*(${M[q.LOOSEPLAIN]})$|^$`);W("COMPARATOR",`^${M[q.GTLT]}\\s*(${M[q.FULLPLAIN]})$|^$`);W("COMPARATORTRIM",`(\\s*)${M[q.GTLT]}\\s*(${M[q.LOOSEPLAIN]}|${M[q.XRANGEPLAIN]})`,!0);Xt.comparatorTrimReplace="$1$2$3";W("HYPHENRANGE",`^\\s*(${M[q.XRANGEPLAIN]})\\s+-\\s+(${M[q.XRANGEPLAIN]})\\s*$`);W("HYPHENRANGELOOSE",`^\\s*(${M[q.XRANGEPLAINLOOSE]})\\s+-\\s+(${M[q.XRANGEPLAINLOOSE]})\\s*$`);W("STAR","(<|>)?=?\\s*\\*");W("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");W("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var Cs=p((KJ,ud)=>{var XL=["includePrerelease","loose","rtl"],jL=e=>e?typeof e!="object"?{loose:!0}:XL.filter(A=>e[A]).reduce((A,t)=>(A[t]=!0,A),{}):{};ud.exports=jL});var $l=p((vJ,yd)=>{var fd=/^[0-9]+$/,dd=(e,A)=>{let t=fd.test(e),r=fd.test(A);return t&&r&&(e=+e,A=+A),e===A?0:t&&!r?-1:r&&!t?1:e<A?-1:1},$L=(e,A)=>dd(A,e);yd.exports={compareIdentifiers:dd,rcompareIdentifiers:$L}});var ee=p((VJ,md)=>{var pa=Es(),{MAX_LENGTH:pd,MAX_SAFE_INTEGER:wa}=ls(),{re:wd,t:Sd}=Fr(),A1=Cs(),{compareIdentifiers:Fi}=$l(),De=class{constructor(A,t){if(t=A1(t),A instanceof De){if(A.loose===!!t.loose&&A.includePrerelease===!!t.includePrerelease)return A;A=A.version}else if(typeof A!="string")throw new TypeError(`Invalid Version: ${A}`);if(A.length>pd)throw new TypeError(`version is longer than ${pd} characters`);pa("SemVer",A,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;let r=A.trim().match(t.loose?wd[Sd.LOOSE]:wd[Sd.FULL]);if(!r)throw new TypeError(`Invalid Version: ${A}`);if(this.raw=A,this.major=+r[1],this.minor=+r[2],this.patch=+r[3],this.major>wa||this.major<0)throw new TypeError("Invalid major version");if(this.minor>wa||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>wa||this.patch<0)throw new TypeError("Invalid patch version");r[4]?this.prerelease=r[4].split(".").map(i=>{if(/^[0-9]+$/.test(i)){let n=+i;if(n>=0&&n<wa)return n}return i}):this.prerelease=[],this.build=r[5]?r[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(A){if(pa("SemVer.compare",this.version,this.options,A),!(A instanceof De)){if(typeof A=="string"&&A===this.version)return 0;A=new De(A,this.options)}return A.version===this.version?0:this.compareMain(A)||this.comparePre(A)}compareMain(A){return A instanceof De||(A=new De(A,this.options)),Fi(this.major,A.major)||Fi(this.minor,A.minor)||Fi(this.patch,A.patch)}comparePre(A){if(A instanceof De||(A=new De(A,this.options)),this.prerelease.length&&!A.prerelease.length)return-1;if(!this.prerelease.length&&A.prerelease.length)return 1;if(!this.prerelease.length&&!A.prerelease.length)return 0;let t=0;do{let r=this.prerelease[t],i=A.prerelease[t];if(pa("prerelease compare",t,r,i),r===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(r===void 0)return-1;if(r===i)continue;return Fi(r,i)}while(++t)}compareBuild(A){A instanceof De||(A=new De(A,this.options));let t=0;do{let r=this.build[t],i=A.build[t];if(pa("prerelease compare",t,r,i),r===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(r===void 0)return-1;if(r===i)continue;return Fi(r,i)}while(++t)}inc(A,t){switch(A){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t),this.inc("pre",t);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",t),this.inc("pre",t);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let r=this.prerelease.length;for(;--r>=0;)typeof this.prerelease[r]=="number"&&(this.prerelease[r]++,r=-2);r===-1&&this.prerelease.push(0)}t&&(Fi(this.prerelease[0],t)===0?isNaN(this.prerelease[1])&&(this.prerelease=[t,0]):this.prerelease=[t,0]);break;default:throw new Error(`invalid increment argument: ${A}`)}return this.format(),this.raw=this.version,this}};md.exports=De});var Lr=p((xJ,Rd)=>{var{MAX_LENGTH:e1}=ls(),{re:Dd,t:bd}=Fr(),kd=ee(),t1=Cs(),r1=(e,A)=>{if(A=t1(A),e instanceof kd)return e;if(typeof e!="string"||e.length>e1||!(A.loose?Dd[bd.LOOSE]:Dd[bd.FULL]).test(e))return null;try{return new kd(e,A)}catch{return null}};Rd.exports=r1});var Fd=p((_J,Nd)=>{var i1=Lr(),n1=(e,A)=>{let t=i1(e,A);return t?t.version:null};Nd.exports=n1});var Ud=p((WJ,Ld)=>{var s1=Lr(),o1=(e,A)=>{let t=s1(e.trim().replace(/^[=v]+/,""),A);return t?t.version:null};Ld.exports=o1});var Td=p((OJ,qd)=>{var Md=ee(),a1=(e,A,t,r)=>{typeof t=="string"&&(r=t,t=void 0);try{return new Md(e instanceof Md?e.version:e,t).inc(A,r).version}catch{return null}};qd.exports=a1});var ve=p((PJ,Jd)=>{var Yd=ee(),g1=(e,A,t)=>new Yd(e,t).compare(new Yd(A,t));Jd.exports=g1});var Sa=p((zJ,Gd)=>{var c1=ve(),l1=(e,A,t)=>c1(e,A,t)===0;Gd.exports=l1});var vd=p((ZJ,Kd)=>{var Hd=Lr(),E1=Sa(),C1=(e,A)=>{if(E1(e,A))return null;{let t=Hd(e),r=Hd(A),i=t.prerelease.length||r.prerelease.length,n=i?"pre":"",o=i?"prerelease":"";for(let g in t)if((g==="major"||g==="minor"||g==="patch")&&t[g]!==r[g])return n+g;return o}};Kd.exports=C1});var xd=p((XJ,Vd)=>{var I1=ee(),Q1=(e,A)=>new I1(e,A).major;Vd.exports=Q1});var Wd=p((jJ,_d)=>{var B1=ee(),h1=(e,A)=>new B1(e,A).minor;_d.exports=h1});var Pd=p(($J,Od)=>{var u1=ee(),f1=(e,A)=>new u1(e,A).patch;Od.exports=f1});var Zd=p((A2,zd)=>{var d1=Lr(),y1=(e,A)=>{let t=d1(e,A);return t&&t.prerelease.length?t.prerelease:null};zd.exports=y1});var jd=p((e2,Xd)=>{var p1=ve(),w1=(e,A,t)=>p1(A,e,t);Xd.exports=w1});var Ay=p((t2,$d)=>{var S1=ve(),m1=(e,A)=>S1(e,A,!0);$d.exports=m1});var ma=p((r2,ty)=>{var ey=ee(),D1=(e,A,t)=>{let r=new ey(e,t),i=new ey(A,t);return r.compare(i)||r.compareBuild(i)};ty.exports=D1});var iy=p((i2,ry)=>{var b1=ma(),k1=(e,A)=>e.sort((t,r)=>b1(t,r,A));ry.exports=k1});var sy=p((n2,ny)=>{var R1=ma(),N1=(e,A)=>e.sort((t,r)=>R1(r,t,A));ny.exports=N1});var Is=p((s2,oy)=>{var F1=ve(),L1=(e,A,t)=>F1(e,A,t)>0;oy.exports=L1});var Da=p((o2,ay)=>{var U1=ve(),M1=(e,A,t)=>U1(e,A,t)<0;ay.exports=M1});var AE=p((a2,gy)=>{var q1=ve(),T1=(e,A,t)=>q1(e,A,t)!==0;gy.exports=T1});var ba=p((g2,cy)=>{var Y1=ve(),J1=(e,A,t)=>Y1(e,A,t)>=0;cy.exports=J1});var ka=p((c2,ly)=>{var G1=ve(),H1=(e,A,t)=>G1(e,A,t)<=0;ly.exports=H1});var eE=p((l2,Ey)=>{var K1=Sa(),v1=AE(),V1=Is(),x1=ba(),_1=Da(),W1=ka(),O1=(e,A,t,r)=>{switch(A){case"===":return typeof e=="object"&&(e=e.version),typeof t=="object"&&(t=t.version),e===t;case"!==":return typeof e=="object"&&(e=e.version),typeof t=="object"&&(t=t.version),e!==t;case"":case"=":case"==":return K1(e,t,r);case"!=":return v1(e,t,r);case">":return V1(e,t,r);case">=":return x1(e,t,r);case"<":return _1(e,t,r);case"<=":return W1(e,t,r);default:throw new TypeError(`Invalid operator: ${A}`)}};Ey.exports=O1});var Iy=p((E2,Cy)=>{var P1=ee(),z1=Lr(),{re:Ra,t:Na}=Fr(),Z1=(e,A)=>{if(e instanceof P1)return e;if(typeof e=="number"&&(e=String(e)),typeof e!="string")return null;A=A||{};let t=null;if(!A.rtl)t=e.match(Ra[Na.COERCE]);else{let r;for(;(r=Ra[Na.COERCERTL].exec(e))&&(!t||t.index+t[0].length!==e.length);)(!t||r.index+r[0].length!==t.index+t[0].length)&&(t=r),Ra[Na.COERCERTL].lastIndex=r.index+r[1].length+r[2].length;Ra[Na.COERCERTL].lastIndex=-1}return t===null?null:z1(`${t[2]}.${t[3]||"0"}.${t[4]||"0"}`,A)};Cy.exports=Z1});var By=p((C2,Qy)=>{"use strict";Qy.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let A=this.head;A;A=A.next)yield A.value}}});var uy=p((I2,hy)=>{"use strict";hy.exports=AA;AA.Node=Ur;AA.create=AA;function AA(e){var A=this;if(A instanceof AA||(A=new AA),A.tail=null,A.head=null,A.length=0,e&&typeof e.forEach=="function")e.forEach(function(i){A.push(i)});else if(arguments.length>0)for(var t=0,r=arguments.length;t<r;t++)A.push(arguments[t]);return A}AA.prototype.removeNode=function(e){if(e.list!==this)throw new Error("removing node which does not belong to this list");var A=e.next,t=e.prev;return A&&(A.prev=t),t&&(t.next=A),e===this.head&&(this.head=A),e===this.tail&&(this.tail=t),e.list.length--,e.next=null,e.prev=null,e.list=null,A};AA.prototype.unshiftNode=function(e){if(e!==this.head){e.list&&e.list.removeNode(e);var A=this.head;e.list=this,e.next=A,A&&(A.prev=e),this.head=e,this.tail||(this.tail=e),this.length++}};AA.prototype.pushNode=function(e){if(e!==this.tail){e.list&&e.list.removeNode(e);var A=this.tail;e.list=this,e.prev=A,A&&(A.next=e),this.tail=e,this.head||(this.head=e),this.length++}};AA.prototype.push=function(){for(var e=0,A=arguments.length;e<A;e++)j1(this,arguments[e]);return this.length};AA.prototype.unshift=function(){for(var e=0,A=arguments.length;e<A;e++)$1(this,arguments[e]);return this.length};AA.prototype.pop=function(){if(!!this.tail){var e=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,e}};AA.prototype.shift=function(){if(!!this.head){var e=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,e}};AA.prototype.forEach=function(e,A){A=A||this;for(var t=this.head,r=0;t!==null;r++)e.call(A,t.value,r,this),t=t.next};AA.prototype.forEachReverse=function(e,A){A=A||this;for(var t=this.tail,r=this.length-1;t!==null;r--)e.call(A,t.value,r,this),t=t.prev};AA.prototype.get=function(e){for(var A=0,t=this.head;t!==null&&A<e;A++)t=t.next;if(A===e&&t!==null)return t.value};AA.prototype.getReverse=function(e){for(var A=0,t=this.tail;t!==null&&A<e;A++)t=t.prev;if(A===e&&t!==null)return t.value};AA.prototype.map=function(e,A){A=A||this;for(var t=new AA,r=this.head;r!==null;)t.push(e.call(A,r.value,this)),r=r.next;return t};AA.prototype.mapReverse=function(e,A){A=A||this;for(var t=new AA,r=this.tail;r!==null;)t.push(e.call(A,r.value,this)),r=r.prev;return t};AA.prototype.reduce=function(e,A){var t,r=this.head;if(arguments.length>1)t=A;else if(this.head)r=this.head.next,t=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var i=0;r!==null;i++)t=e(t,r.value,i),r=r.next;return t};AA.prototype.reduceReverse=function(e,A){var t,r=this.tail;if(arguments.length>1)t=A;else if(this.tail)r=this.tail.prev,t=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var i=this.length-1;r!==null;i--)t=e(t,r.value,i),r=r.prev;return t};AA.prototype.toArray=function(){for(var e=new Array(this.length),A=0,t=this.head;t!==null;A++)e[A]=t.value,t=t.next;return e};AA.prototype.toArrayReverse=function(){for(var e=new Array(this.length),A=0,t=this.tail;t!==null;A++)e[A]=t.value,t=t.prev;return e};AA.prototype.slice=function(e,A){A=A||this.length,A<0&&(A+=this.length),e=e||0,e<0&&(e+=this.length);var t=new AA;if(A<e||A<0)return t;e<0&&(e=0),A>this.length&&(A=this.length);for(var r=0,i=this.head;i!==null&&r<e;r++)i=i.next;for(;i!==null&&r<A;r++,i=i.next)t.push(i.value);return t};AA.prototype.sliceReverse=function(e,A){A=A||this.length,A<0&&(A+=this.length),e=e||0,e<0&&(e+=this.length);var t=new AA;if(A<e||A<0)return t;e<0&&(e=0),A>this.length&&(A=this.length);for(var r=this.length,i=this.tail;i!==null&&r>A;r--)i=i.prev;for(;i!==null&&r>e;r--,i=i.prev)t.push(i.value);return t};AA.prototype.splice=function(e,A,...t){e>this.length&&(e=this.length-1),e<0&&(e=this.length+e);for(var r=0,i=this.head;i!==null&&r<e;r++)i=i.next;for(var n=[],r=0;i&&r<A;r++)n.push(i.value),i=this.removeNode(i);i===null&&(i=this.tail),i!==this.head&&i!==this.tail&&(i=i.prev);for(var r=0;r<t.length;r++)i=X1(this,i,t[r]);return n};AA.prototype.reverse=function(){for(var e=this.head,A=this.tail,t=e;t!==null;t=t.prev){var r=t.prev;t.prev=t.next,t.next=r}return this.head=A,this.tail=e,this};function X1(e,A,t){var r=A===e.head?new Ur(t,null,A,e):new Ur(t,A,A.next,e);return r.next===null&&(e.tail=r),r.prev===null&&(e.head=r),e.length++,r}function j1(e,A){e.tail=new Ur(A,e.tail,null,e),e.head||(e.head=e.tail),e.length++}function $1(e,A){e.head=new Ur(A,null,e.head,e),e.tail||(e.tail=e.head),e.length++}function Ur(e,A,t,r){if(!(this instanceof Ur))return new Ur(e,A,t,r);this.list=r,this.value=e,A?(A.next=this,this.prev=A):this.prev=null,t?(t.prev=this,this.next=t):this.next=null}try{By()(AA)}catch{}});var wy=p((Q2,py)=>{"use strict";var AU=uy(),Mr=Symbol("max"),Ft=Symbol("length"),Li=Symbol("lengthCalculator"),Bs=Symbol("allowStale"),qr=Symbol("maxAge"),Nt=Symbol("dispose"),fy=Symbol("noDisposeOnSet"),VA=Symbol("lruList"),Xe=Symbol("cache"),yy=Symbol("updateAgeOnGet"),tE=()=>1,iE=class{constructor(A){if(typeof A=="number"&&(A={max:A}),A||(A={}),A.max&&(typeof A.max!="number"||A.max<0))throw new TypeError("max must be a non-negative number");let t=this[Mr]=A.max||1/0,r=A.length||tE;if(this[Li]=typeof r!="function"?tE:r,this[Bs]=A.stale||!1,A.maxAge&&typeof A.maxAge!="number")throw new TypeError("maxAge must be a number");this[qr]=A.maxAge||0,this[Nt]=A.dispose,this[fy]=A.noDisposeOnSet||!1,this[yy]=A.updateAgeOnGet||!1,this.reset()}set max(A){if(typeof A!="number"||A<0)throw new TypeError("max must be a non-negative number");this[Mr]=A||1/0,Qs(this)}get max(){return this[Mr]}set allowStale(A){this[Bs]=!!A}get allowStale(){return this[Bs]}set maxAge(A){if(typeof A!="number")throw new TypeError("maxAge must be a non-negative number");this[qr]=A,Qs(this)}get maxAge(){return this[qr]}set lengthCalculator(A){typeof A!="function"&&(A=tE),A!==this[Li]&&(this[Li]=A,this[Ft]=0,this[VA].forEach(t=>{t.length=this[Li](t.value,t.key),this[Ft]+=t.length})),Qs(this)}get lengthCalculator(){return this[Li]}get length(){return this[Ft]}get itemCount(){return this[VA].length}rforEach(A,t){t=t||this;for(let r=this[VA].tail;r!==null;){let i=r.prev;dy(this,A,r,t),r=i}}forEach(A,t){t=t||this;for(let r=this[VA].head;r!==null;){let i=r.next;dy(this,A,r,t),r=i}}keys(){return this[VA].toArray().map(A=>A.key)}values(){return this[VA].toArray().map(A=>A.value)}reset(){this[Nt]&&this[VA]&&this[VA].length&&this[VA].forEach(A=>this[Nt](A.key,A.value)),this[Xe]=new Map,this[VA]=new AU,this[Ft]=0}dump(){return this[VA].map(A=>Fa(this,A)?!1:{k:A.key,v:A.value,e:A.now+(A.maxAge||0)}).toArray().filter(A=>A)}dumpLru(){return this[VA]}set(A,t,r){if(r=r||this[qr],r&&typeof r!="number")throw new TypeError("maxAge must be a number");let i=r?Date.now():0,n=this[Li](t,A);if(this[Xe].has(A)){if(n>this[Mr])return Ui(this,this[Xe].get(A)),!1;let c=this[Xe].get(A).value;return this[Nt]&&(this[fy]||this[Nt](A,c.value)),c.now=i,c.maxAge=r,c.value=t,this[Ft]+=n-c.length,c.length=n,this.get(A),Qs(this),!0}let o=new nE(A,t,n,i,r);return o.length>this[Mr]?(this[Nt]&&this[Nt](A,t),!1):(this[Ft]+=o.length,this[VA].unshift(o),this[Xe].set(A,this[VA].head),Qs(this),!0)}has(A){if(!this[Xe].has(A))return!1;let t=this[Xe].get(A).value;return!Fa(this,t)}get(A){return rE(this,A,!0)}peek(A){return rE(this,A,!1)}pop(){let A=this[VA].tail;return A?(Ui(this,A),A.value):null}del(A){Ui(this,this[Xe].get(A))}load(A){this.reset();let t=Date.now();for(let r=A.length-1;r>=0;r--){let i=A[r],n=i.e||0;if(n===0)this.set(i.k,i.v);else{let o=n-t;o>0&&this.set(i.k,i.v,o)}}}prune(){this[Xe].forEach((A,t)=>rE(this,t,!1))}},rE=(e,A,t)=>{let r=e[Xe].get(A);if(r){let i=r.value;if(Fa(e,i)){if(Ui(e,r),!e[Bs])return}else t&&(e[yy]&&(r.value.now=Date.now()),e[VA].unshiftNode(r));return i.value}},Fa=(e,A)=>{if(!A||!A.maxAge&&!e[qr])return!1;let t=Date.now()-A.now;return A.maxAge?t>A.maxAge:e[qr]&&t>e[qr]},Qs=e=>{if(e[Ft]>e[Mr])for(let A=e[VA].tail;e[Ft]>e[Mr]&&A!==null;){let t=A.prev;Ui(e,A),A=t}},Ui=(e,A)=>{if(A){let t=A.value;e[Nt]&&e[Nt](t.key,t.value),e[Ft]-=t.length,e[Xe].delete(t.key),e[VA].removeNode(A)}},nE=class{constructor(A,t,r,i,n){this.key=A,this.value=t,this.length=r,this.now=i,this.maxAge=n||0}},dy=(e,A,t,r)=>{let i=t.value;Fa(e,i)&&(Ui(e,t),e[Bs]||(i=void 0)),i&&A.call(r,i.value,i.key,e)};py.exports=iE});var Ve=p((B2,by)=>{var Tr=class{constructor(A,t){if(t=tU(t),A instanceof Tr)return A.loose===!!t.loose&&A.includePrerelease===!!t.includePrerelease?A:new Tr(A.raw,t);if(A instanceof sE)return this.raw=A.value,this.set=[[A]],this.format(),this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=A,this.set=A.split("||").map(r=>this.parseRange(r.trim())).filter(r=>r.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${A}`);if(this.set.length>1){let r=this.set[0];if(this.set=this.set.filter(i=>!my(i[0])),this.set.length===0)this.set=[r];else if(this.set.length>1){for(let i of this.set)if(i.length===1&&oU(i[0])){this.set=[i];break}}}this.format()}format(){return this.range=this.set.map(A=>A.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(A){A=A.trim();let r=`parseRange:${Object.keys(this.options).join(",")}:${A}`,i=Sy.get(r);if(i)return i;let n=this.options.loose,o=n?Be[se.HYPHENRANGELOOSE]:Be[se.HYPHENRANGE];A=A.replace(o,hU(this.options.includePrerelease)),dA("hyphen replace",A),A=A.replace(Be[se.COMPARATORTRIM],iU),dA("comparator trim",A),A=A.replace(Be[se.TILDETRIM],nU),A=A.replace(Be[se.CARETTRIM],sU),A=A.split(/\s+/).join(" ");let g=A.split(" ").map(I=>aU(I,this.options)).join(" ").split(/\s+/).map(I=>BU(I,this.options));n&&(g=g.filter(I=>(dA("loose invalid filter",I,this.options),!!I.match(Be[se.COMPARATORLOOSE])))),dA("range list",g);let c=new Map,E=g.map(I=>new sE(I,this.options));for(let I of E){if(my(I))return[I];c.set(I.value,I)}c.size>1&&c.has("")&&c.delete("");let C=[...c.values()];return Sy.set(r,C),C}intersects(A,t){if(!(A instanceof Tr))throw new TypeError("a Range is required");return this.set.some(r=>Dy(r,t)&&A.set.some(i=>Dy(i,t)&&r.every(n=>i.every(o=>n.intersects(o,t)))))}test(A){if(!A)return!1;if(typeof A=="string")try{A=new rU(A,this.options)}catch{return!1}for(let t=0;t<this.set.length;t++)if(uU(this.set[t],A,this.options))return!0;return!1}};by.exports=Tr;var eU=wy(),Sy=new eU({max:1e3}),tU=Cs(),sE=hs(),dA=Es(),rU=ee(),{re:Be,t:se,comparatorTrimReplace:iU,tildeTrimReplace:nU,caretTrimReplace:sU}=Fr(),my=e=>e.value==="<0.0.0-0",oU=e=>e.value==="",Dy=(e,A)=>{let t=!0,r=e.slice(),i=r.pop();for(;t&&r.length;)t=r.every(n=>i.intersects(n,A)),i=r.pop();return t},aU=(e,A)=>(dA("comp",e,A),e=lU(e,A),dA("caret",e),e=gU(e,A),dA("tildes",e),e=CU(e,A),dA("xrange",e),e=QU(e,A),dA("stars",e),e),oe=e=>!e||e.toLowerCase()==="x"||e==="*",gU=(e,A)=>e.trim().split(/\s+/).map(t=>cU(t,A)).join(" "),cU=(e,A)=>{let t=A.loose?Be[se.TILDELOOSE]:Be[se.TILDE];return e.replace(t,(r,i,n,o,g)=>{dA("tilde",e,r,i,n,o,g);let c;return oe(i)?c="":oe(n)?c=`>=${i}.0.0 <${+i+1}.0.0-0`:oe(o)?c=`>=${i}.${n}.0 <${i}.${+n+1}.0-0`:g?(dA("replaceTilde pr",g),c=`>=${i}.${n}.${o}-${g} <${i}.${+n+1}.0-0`):c=`>=${i}.${n}.${o} <${i}.${+n+1}.0-0`,dA("tilde return",c),c})},lU=(e,A)=>e.trim().split(/\s+/).map(t=>EU(t,A)).join(" "),EU=(e,A)=>{dA("caret",e,A);let t=A.loose?Be[se.CARETLOOSE]:Be[se.CARET],r=A.includePrerelease?"-0":"";return e.replace(t,(i,n,o,g,c)=>{dA("caret",e,i,n,o,g,c);let E;return oe(n)?E="":oe(o)?E=`>=${n}.0.0${r} <${+n+1}.0.0-0`:oe(g)?n==="0"?E=`>=${n}.${o}.0${r} <${n}.${+o+1}.0-0`:E=`>=${n}.${o}.0${r} <${+n+1}.0.0-0`:c?(dA("replaceCaret pr",c),n==="0"?o==="0"?E=`>=${n}.${o}.${g}-${c} <${n}.${o}.${+g+1}-0`:E=`>=${n}.${o}.${g}-${c} <${n}.${+o+1}.0-0`:E=`>=${n}.${o}.${g}-${c} <${+n+1}.0.0-0`):(dA("no pr"),n==="0"?o==="0"?E=`>=${n}.${o}.${g}${r} <${n}.${o}.${+g+1}-0`:E=`>=${n}.${o}.${g}${r} <${n}.${+o+1}.0-0`:E=`>=${n}.${o}.${g} <${+n+1}.0.0-0`),dA("caret return",E),E})},CU=(e,A)=>(dA("replaceXRanges",e,A),e.split(/\s+/).map(t=>IU(t,A)).join(" ")),IU=(e,A)=>{e=e.trim();let t=A.loose?Be[se.XRANGELOOSE]:Be[se.XRANGE];return e.replace(t,(r,i,n,o,g,c)=>{dA("xRange",e,r,i,n,o,g,c);let E=oe(n),C=E||oe(o),I=C||oe(g),Q=I;return i==="="&&Q&&(i=""),c=A.includePrerelease?"-0":"",E?i===">"||i==="<"?r="<0.0.0-0":r="*":i&&Q?(C&&(o=0),g=0,i===">"?(i=">=",C?(n=+n+1,o=0,g=0):(o=+o+1,g=0)):i==="<="&&(i="<",C?n=+n+1:o=+o+1),i==="<"&&(c="-0"),r=`${i+n}.${o}.${g}${c}`):C?r=`>=${n}.0.0${c} <${+n+1}.0.0-0`:I&&(r=`>=${n}.${o}.0${c} <${n}.${+o+1}.0-0`),dA("xRange return",r),r})},QU=(e,A)=>(dA("replaceStars",e,A),e.trim().replace(Be[se.STAR],"")),BU=(e,A)=>(dA("replaceGTE0",e,A),e.trim().replace(Be[A.includePrerelease?se.GTE0PRE:se.GTE0],"")),hU=e=>(A,t,r,i,n,o,g,c,E,C,I,Q,B)=>(oe(r)?t="":oe(i)?t=`>=${r}.0.0${e?"-0":""}`:oe(n)?t=`>=${r}.${i}.0${e?"-0":""}`:o?t=`>=${t}`:t=`>=${t}${e?"-0":""}`,oe(E)?c="":oe(C)?c=`<${+E+1}.0.0-0`:oe(I)?c=`<${E}.${+C+1}.0-0`:Q?c=`<=${E}.${C}.${I}-${Q}`:e?c=`<${E}.${C}.${+I+1}-0`:c=`<=${c}`,`${t} ${c}`.trim()),uU=(e,A,t)=>{for(let r=0;r<e.length;r++)if(!e[r].test(A))return!1;if(A.prerelease.length&&!t.includePrerelease){for(let r=0;r<e.length;r++)if(dA(e[r].semver),e[r].semver!==sE.ANY&&e[r].semver.prerelease.length>0){let i=e[r].semver;if(i.major===A.major&&i.minor===A.minor&&i.patch===A.patch)return!0}return!1}return!0}});var hs=p((h2,Ly)=>{var us=Symbol("SemVer ANY"),Mi=class{static get ANY(){return us}constructor(A,t){if(t=fU(t),A instanceof Mi){if(A.loose===!!t.loose)return A;A=A.value}aE("comparator",A,t),this.options=t,this.loose=!!t.loose,this.parse(A),this.semver===us?this.value="":this.value=this.operator+this.semver.version,aE("comp",this)}parse(A){let t=this.options.loose?ky[Ry.COMPARATORLOOSE]:ky[Ry.COMPARATOR],r=A.match(t);if(!r)throw new TypeError(`Invalid comparator: ${A}`);this.operator=r[1]!==void 0?r[1]:"",this.operator==="="&&(this.operator=""),r[2]?this.semver=new Ny(r[2],this.options.loose):this.semver=us}toString(){return this.value}test(A){if(aE("Comparator.test",A,this.options.loose),this.semver===us||A===us)return!0;if(typeof A=="string")try{A=new Ny(A,this.options)}catch{return!1}return oE(A,this.operator,this.semver,this.options)}intersects(A,t){if(!(A instanceof Mi))throw new TypeError("a Comparator is required");if((!t||typeof t!="object")&&(t={loose:!!t,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new Fy(A.value,t).test(this.value);if(A.operator==="")return A.value===""?!0:new Fy(this.value,t).test(A.semver);let r=(this.operator===">="||this.operator===">")&&(A.operator===">="||A.operator===">"),i=(this.operator==="<="||this.operator==="<")&&(A.operator==="<="||A.operator==="<"),n=this.semver.version===A.semver.version,o=(this.operator===">="||this.operator==="<=")&&(A.operator===">="||A.operator==="<="),g=oE(this.semver,"<",A.semver,t)&&(this.operator===">="||this.operator===">")&&(A.operator==="<="||A.operator==="<"),c=oE(this.semver,">",A.semver,t)&&(this.operator==="<="||this.operator==="<")&&(A.operator===">="||A.operator===">");return r||i||n&&o||g||c}};Ly.exports=Mi;var fU=Cs(),{re:ky,t:Ry}=Fr(),oE=eE(),aE=Es(),Ny=ee(),Fy=Ve()});var fs=p((u2,Uy)=>{var dU=Ve(),yU=(e,A,t)=>{try{A=new dU(A,t)}catch{return!1}return A.test(e)};Uy.exports=yU});var qy=p((f2,My)=>{var pU=Ve(),wU=(e,A)=>new pU(e,A).set.map(t=>t.map(r=>r.value).join(" ").trim().split(" "));My.exports=wU});var Yy=p((d2,Ty)=>{var SU=ee(),mU=Ve(),DU=(e,A,t)=>{let r=null,i=null,n=null;try{n=new mU(A,t)}catch{return null}return e.forEach(o=>{n.test(o)&&(!r||i.compare(o)===-1)&&(r=o,i=new SU(r,t))}),r};Ty.exports=DU});var Gy=p((y2,Jy)=>{var bU=ee(),kU=Ve(),RU=(e,A,t)=>{let r=null,i=null,n=null;try{n=new kU(A,t)}catch{return null}return e.forEach(o=>{n.test(o)&&(!r||i.compare(o)===1)&&(r=o,i=new bU(r,t))}),r};Jy.exports=RU});var vy=p((p2,Ky)=>{var gE=ee(),NU=Ve(),Hy=Is(),FU=(e,A)=>{e=new NU(e,A);let t=new gE("0.0.0");if(e.test(t)||(t=new gE("0.0.0-0"),e.test(t)))return t;t=null;for(let r=0;r<e.set.length;++r){let i=e.set[r],n=null;i.forEach(o=>{let g=new gE(o.semver.version);switch(o.operator){case">":g.prerelease.length===0?g.patch++:g.prerelease.push(0),g.raw=g.format();case"":case">=":(!n||Hy(g,n))&&(n=g);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),n&&(!t||Hy(t,n))&&(t=n)}return t&&e.test(t)?t:null};Ky.exports=FU});var xy=p((w2,Vy)=>{var LU=Ve(),UU=(e,A)=>{try{return new LU(e,A).range||"*"}catch{return null}};Vy.exports=UU});var La=p((S2,Py)=>{var MU=ee(),Oy=hs(),{ANY:qU}=Oy,TU=Ve(),YU=fs(),_y=Is(),Wy=Da(),JU=ka(),GU=ba(),HU=(e,A,t,r)=>{e=new MU(e,r),A=new TU(A,r);let i,n,o,g,c;switch(t){case">":i=_y,n=JU,o=Wy,g=">",c=">=";break;case"<":i=Wy,n=GU,o=_y,g="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(YU(e,A,r))return!1;for(let E=0;E<A.set.length;++E){let C=A.set[E],I=null,Q=null;if(C.forEach(B=>{B.semver===qU&&(B=new Oy(">=0.0.0")),I=I||B,Q=Q||B,i(B.semver,I.semver,r)?I=B:o(B.semver,Q.semver,r)&&(Q=B)}),I.operator===g||I.operator===c||(!Q.operator||Q.operator===g)&&n(e,Q.semver))return!1;if(Q.operator===c&&o(e,Q.semver))return!1}return!0};Py.exports=HU});var Zy=p((m2,zy)=>{var KU=La(),vU=(e,A,t)=>KU(e,A,">",t);zy.exports=vU});var jy=p((D2,Xy)=>{var VU=La(),xU=(e,A,t)=>VU(e,A,"<",t);Xy.exports=xU});var ep=p((b2,Ap)=>{var $y=Ve(),_U=(e,A,t)=>(e=new $y(e,t),A=new $y(A,t),e.intersects(A));Ap.exports=_U});var rp=p((k2,tp)=>{var WU=fs(),OU=ve();tp.exports=(e,A,t)=>{let r=[],i=null,n=null,o=e.sort((C,I)=>OU(C,I,t));for(let C of o)WU(C,A,t)?(n=C,i||(i=C)):(n&&r.push([i,n]),n=null,i=null);i&&r.push([i,null]);let g=[];for(let[C,I]of r)C===I?g.push(C):!I&&C===o[0]?g.push("*"):I?C===o[0]?g.push(`<=${I}`):g.push(`${C} - ${I}`):g.push(`>=${C}`);let c=g.join(" || "),E=typeof A.raw=="string"?A.raw:String(A);return c.length<E.length?c:A}});var ap=p((R2,op)=>{var ip=Ve(),Ua=hs(),{ANY:cE}=Ua,ds=fs(),lE=ve(),PU=(e,A,t={})=>{if(e===A)return!0;e=new ip(e,t),A=new ip(A,t);let r=!1;A:for(let i of e.set){for(let n of A.set){let o=zU(i,n,t);if(r=r||o!==null,o)continue A}if(r)return!1}return!0},zU=(e,A,t)=>{if(e===A)return!0;if(e.length===1&&e[0].semver===cE){if(A.length===1&&A[0].semver===cE)return!0;t.includePrerelease?e=[new Ua(">=0.0.0-0")]:e=[new Ua(">=0.0.0")]}if(A.length===1&&A[0].semver===cE){if(t.includePrerelease)return!0;A=[new Ua(">=0.0.0")]}let r=new Set,i,n;for(let B of e)B.operator===">"||B.operator===">="?i=np(i,B,t):B.operator==="<"||B.operator==="<="?n=sp(n,B,t):r.add(B.semver);if(r.size>1)return null;let o;if(i&&n){if(o=lE(i.semver,n.semver,t),o>0)return null;if(o===0&&(i.operator!==">="||n.operator!=="<="))return null}for(let B of r){if(i&&!ds(B,String(i),t)||n&&!ds(B,String(n),t))return null;for(let u of A)if(!ds(B,String(u),t))return!1;return!0}let g,c,E,C,I=n&&!t.includePrerelease&&n.semver.prerelease.length?n.semver:!1,Q=i&&!t.includePrerelease&&i.semver.prerelease.length?i.semver:!1;I&&I.prerelease.length===1&&n.operator==="<"&&I.prerelease[0]===0&&(I=!1);for(let B of A){if(C=C||B.operator===">"||B.operator===">=",E=E||B.operator==="<"||B.operator==="<=",i){if(Q&&B.semver.prerelease&&B.semver.prerelease.length&&B.semver.major===Q.major&&B.semver.minor===Q.minor&&B.semver.patch===Q.patch&&(Q=!1),B.operator===">"||B.operator===">="){if(g=np(i,B,t),g===B&&g!==i)return!1}else if(i.operator===">="&&!ds(i.semver,String(B),t))return!1}if(n){if(I&&B.semver.prerelease&&B.semver.prerelease.length&&B.semver.major===I.major&&B.semver.minor===I.minor&&B.semver.patch===I.patch&&(I=!1),B.operator==="<"||B.operator==="<="){if(c=sp(n,B,t),c===B&&c!==n)return!1}else if(n.operator==="<="&&!ds(n.semver,String(B),t))return!1}if(!B.operator&&(n||i)&&o!==0)return!1}return!(i&&E&&!n&&o!==0||n&&C&&!i&&o!==0||Q||I)},np=(e,A,t)=>{if(!e)return A;let r=lE(e.semver,A.semver,t);return r>0?e:r<0||A.operator===">"&&e.operator===">="?A:e},sp=(e,A,t)=>{if(!e)return A;let r=lE(e.semver,A.semver,t);return r<0?e:r>0||A.operator==="<"&&e.operator==="<="?A:e};op.exports=PU});var lp=p((N2,cp)=>{var EE=Fr(),ZU=ls(),XU=ee(),gp=$l(),jU=Lr(),$U=Fd(),AM=Ud(),eM=Td(),tM=vd(),rM=xd(),iM=Wd(),nM=Pd(),sM=Zd(),oM=ve(),aM=jd(),gM=Ay(),cM=ma(),lM=iy(),EM=sy(),CM=Is(),IM=Da(),QM=Sa(),BM=AE(),hM=ba(),uM=ka(),fM=eE(),dM=Iy(),yM=hs(),pM=Ve(),wM=fs(),SM=qy(),mM=Yy(),DM=Gy(),bM=vy(),kM=xy(),RM=La(),NM=Zy(),FM=jy(),LM=ep(),UM=rp(),MM=ap();cp.exports={parse:jU,valid:$U,clean:AM,inc:eM,diff:tM,major:rM,minor:iM,patch:nM,prerelease:sM,compare:oM,rcompare:aM,compareLoose:gM,compareBuild:cM,sort:lM,rsort:EM,gt:CM,lt:IM,eq:QM,neq:BM,gte:hM,lte:uM,cmp:fM,coerce:dM,Comparator:yM,Range:pM,satisfies:wM,toComparators:SM,maxSatisfying:mM,minSatisfying:DM,minVersion:bM,validRange:kM,outside:RM,gtr:NM,ltr:FM,intersects:LM,simplifyRange:UM,subset:MM,SemVer:XU,re:EE.re,src:EE.src,tokens:EE.t,SEMVER_SPEC_VERSION:ZU.SEMVER_SPEC_VERSION,compareIdentifiers:gp.compareIdentifiers,rcompareIdentifiers:gp.rcompareIdentifiers}});var Bp=p((F2,Qp)=>{Qp.exports=function(e,A){A||(A={});var t=A.hsep===void 0?" ":A.hsep,r=A.align||[],i=A.stringLength||function(c){return String(c).length},n=Cp(e,function(c,E){return Ip(E,function(C,I){var Q=Ep(C);(!c[I]||Q>c[I])&&(c[I]=Q)}),c},[]),o=Ma(e,function(c){return Ma(c,function(E,C){var I=String(E);if(r[C]==="."){var Q=Ep(I),B=n[C]+(/\./.test(I)?1:2)-(i(I)-Q);return I+Array(B).join(" ")}else return I})}),g=Cp(o,function(c,E){return Ip(E,function(C,I){var Q=i(C);(!c[I]||Q>c[I])&&(c[I]=Q)}),c},[]);return Ma(o,function(c){return Ma(c,function(E,C){var I=g[C]-i(E)||0,Q=Array(Math.max(I+1,1)).join(" ");return r[C]==="r"||r[C]==="."?Q+E:r[C]==="c"?Array(Math.ceil(I/2+1)).join(" ")+E+Array(Math.floor(I/2+1)).join(" "):E+Q}).join(t).replace(/\s+$/,"")}).join(`
66
- `)};function Ep(e){var A=/\.[^.]*$/.exec(e);return A?A.index+1:e.length}function Cp(e,A,t){if(e.reduce)return e.reduce(A,t);for(var r=0,i=arguments.length>=3?t:e[r++];r<e.length;r++)A(i,e[r],r);return i}function Ip(e,A){if(e.forEach)return e.forEach(A);for(var t=0;t<e.length;t++)A.call(e,e[t],t)}function Ma(e,A){if(e.map)return e.map(A);for(var t=[],r=0;r<e.length;r++)t.push(A.call(e,e[r],r));return t}});var dp=p((M2,fp)=>{var CE=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,qM=typeof AbortController<"u",hp=qM?AbortController:Object.assign(class{constructor(){this.signal=new hp.AbortSignal}abort(){this.signal.aborted=!0}},{AbortSignal:class{constructor(){this.aborted=!1}}}),hE=new Set,IE=(e,A)=>{let t=`LRU_CACHE_OPTION_${e}`;qa(t)&&uE(t,`${e} option`,`options.${A}`,lt)},QE=(e,A)=>{let t=`LRU_CACHE_METHOD_${e}`;if(qa(t)){let{prototype:r}=lt,{get:i}=Object.getOwnPropertyDescriptor(r,e);uE(t,`${e} method`,`cache.${A}()`,i)}},TM=(e,A)=>{let t=`LRU_CACHE_PROPERTY_${e}`;if(qa(t)){let{prototype:r}=lt,{get:i}=Object.getOwnPropertyDescriptor(r,e);uE(t,`${e} property`,`cache.${A}`,i)}},qa=e=>typeof process=="object"&&process&&!hE.has(e),uE=(e,A,t,r)=>{hE.add(e);let i=`The ${A} is deprecated. Please use ${t} instead.`;process.emitWarning(i,"DeprecationWarning",e,r)},Yr=e=>e&&e===Math.floor(e)&&e>0&&isFinite(e),up=e=>Yr(e)?e<=Math.pow(2,8)?Uint8Array:e<=Math.pow(2,16)?Uint16Array:e<=Math.pow(2,32)?Uint32Array:e<=Number.MAX_SAFE_INTEGER?qi:null:null,qi=class extends Array{constructor(A){super(A),this.fill(0)}},BE=class{constructor(A){let t=A?up(A):Array;this.heap=new t(A),this.length=0}push(A){this.heap[this.length++]=A}pop(){return this.heap[--this.length]}},lt=class{constructor(A={}){let{max:t=0,ttl:r,ttlResolution:i=1,ttlAutopurge:n,updateAgeOnGet:o,allowStale:g,dispose:c,disposeAfter:E,noDisposeOnSet:C,noUpdateTTL:I,maxSize:Q=0,sizeCalculation:B,fetchMethod:u}=A,{length:w,maxAge:y,stale:d}=A instanceof lt?{}:A;if(t!==0&&!Yr(t))throw new TypeError("max option must be a nonnegative integer");let m=t?up(t):Array;if(!m)throw new Error("invalid max value: "+t);if(this.max=t,this.maxSize=Q,this.sizeCalculation=B||w,this.sizeCalculation){if(!this.maxSize)throw new TypeError("cannot set sizeCalculation without setting maxSize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(this.fetchMethod=u||null,this.fetchMethod&&typeof this.fetchMethod!="function")throw new TypeError("fetchMethod must be a function if specified");if(this.keyMap=new Map,this.keyList=new Array(t).fill(null),this.valList=new Array(t).fill(null),this.next=new m(t),this.prev=new m(t),this.head=0,this.tail=0,this.free=new BE(t),this.initialFill=1,this.size=0,typeof c=="function"&&(this.dispose=c),typeof E=="function"?(this.disposeAfter=E,this.disposed=[]):(this.disposeAfter=null,this.disposed=null),this.noDisposeOnSet=!!C,this.noUpdateTTL=!!I,this.maxSize!==0){if(!Yr(this.maxSize))throw new TypeError("maxSize must be a positive integer if specified");this.initializeSizeTracking()}if(this.allowStale=!!g||!!d,this.updateAgeOnGet=!!o,this.ttlResolution=Yr(i)||i===0?i:1,this.ttlAutopurge=!!n,this.ttl=r||y||0,this.ttl){if(!Yr(this.ttl))throw new TypeError("ttl must be a positive integer if specified");this.initializeTTLTracking()}if(this.max===0&&this.ttl===0&&this.maxSize===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!this.max&&!this.maxSize){let N="LRU_CACHE_UNBOUNDED";if(qa(N)){hE.add(N);let D="TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.";process.emitWarning(D,"UnboundedCacheWarning",N,lt)}}d&&IE("stale","allowStale"),y&&IE("maxAge","ttl"),w&&IE("length","sizeCalculation")}getRemainingTTL(A){return this.has(A)?1/0:0}initializeTTLTracking(){this.ttls=new qi(this.max),this.starts=new qi(this.max),this.setItemTTL=(r,i)=>{if(this.starts[r]=i!==0?CE.now():0,this.ttls[r]=i,i!==0&&this.ttlAutopurge){let n=setTimeout(()=>{this.isStale(r)&&this.delete(this.keyList[r])},i+1);n.unref&&n.unref()}},this.updateItemAge=r=>{this.starts[r]=this.ttls[r]!==0?CE.now():0};let A=0,t=()=>{let r=CE.now();if(this.ttlResolution>0){A=r;let i=setTimeout(()=>A=0,this.ttlResolution);i.unref&&i.unref()}return r};this.getRemainingTTL=r=>{let i=this.keyMap.get(r);return i===void 0?0:this.ttls[i]===0||this.starts[i]===0?1/0:this.starts[i]+this.ttls[i]-(A||t())},this.isStale=r=>this.ttls[r]!==0&&this.starts[r]!==0&&(A||t())-this.starts[r]>this.ttls[r]}updateItemAge(A){}setItemTTL(A,t){}isStale(A){return!1}initializeSizeTracking(){this.calculatedSize=0,this.sizes=new qi(this.max),this.removeItemSize=A=>this.calculatedSize-=this.sizes[A],this.requireSize=(A,t,r,i)=>{if(!Yr(r))if(i){if(typeof i!="function")throw new TypeError("sizeCalculation must be a function");if(r=i(t,A),!Yr(r))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer)");return r},this.addItemSize=(A,t,r,i)=>{this.sizes[A]=i;let n=this.maxSize-this.sizes[A];for(;this.calculatedSize>n;)this.evict();this.calculatedSize+=this.sizes[A]},this.delete=A=>{if(this.size!==0){let t=this.keyMap.get(A);t!==void 0&&(this.calculatedSize-=this.sizes[t])}return lt.prototype.delete.call(this,A)}}removeItemSize(A){}addItemSize(A,t,r,i){}requireSize(A,t,r,i){if(r||i)throw new TypeError("cannot set size without setting maxSize on cache")}*indexes({allowStale:A=this.allowStale}={}){if(this.size)for(let t=this.tail;!(!this.isValidIndex(t)||((A||!this.isStale(t))&&(yield t),t===this.head));)t=this.prev[t]}*rindexes({allowStale:A=this.allowStale}={}){if(this.size)for(let t=this.head;!(!this.isValidIndex(t)||((A||!this.isStale(t))&&(yield t),t===this.tail));)t=this.next[t]}isValidIndex(A){return this.keyMap.get(this.keyList[A])===A}*entries(){for(let A of this.indexes())yield[this.keyList[A],this.valList[A]]}*rentries(){for(let A of this.rindexes())yield[this.keyList[A],this.valList[A]]}*keys(){for(let A of this.indexes())yield this.keyList[A]}*rkeys(){for(let A of this.rindexes())yield this.keyList[A]}*values(){for(let A of this.indexes())yield this.valList[A]}*rvalues(){for(let A of this.rindexes())yield this.valList[A]}[Symbol.iterator](){return this.entries()}find(A,t={}){for(let r of this.indexes())if(A(this.valList[r],this.keyList[r],this))return this.get(this.keyList[r],t)}forEach(A,t=this){for(let r of this.indexes())A.call(t,this.valList[r],this.keyList[r],this)}rforEach(A,t=this){for(let r of this.rindexes())A.call(t,this.valList[r],this.keyList[r],this)}get prune(){return QE("prune","purgeStale"),this.purgeStale}purgeStale(){let A=!1;for(let t of this.rindexes({allowStale:!0}))this.isStale(t)&&(this.delete(this.keyList[t]),A=!0);return A}dump(){let A=[];for(let t of this.indexes()){let r=this.keyList[t],n={value:this.valList[t]};this.ttls&&(n.ttl=this.ttls[t]),this.sizes&&(n.size=this.sizes[t]),A.unshift([r,n])}return A}load(A){this.clear();for(let[t,r]of A)this.set(t,r.value,r)}dispose(A,t,r){}set(A,t,{ttl:r=this.ttl,noDisposeOnSet:i=this.noDisposeOnSet,size:n=0,sizeCalculation:o=this.sizeCalculation,noUpdateTTL:g=this.noUpdateTTL}={}){n=this.requireSize(A,t,n,o);let c=this.size===0?void 0:this.keyMap.get(A);if(c===void 0)c=this.newIndex(),this.keyList[c]=A,this.valList[c]=t,this.keyMap.set(A,c),this.next[this.tail]=c,this.prev[c]=this.tail,this.tail=c,this.size++,this.addItemSize(c,t,A,n),g=!1;else{let E=this.valList[c];t!==E&&(this.isBackgroundFetch(E)?E.__abortController.abort():i||(this.dispose(E,A,"set"),this.disposeAfter&&this.disposed.push([E,A,"set"])),this.removeItemSize(c),this.valList[c]=t,this.addItemSize(c,t,A,n)),this.moveToTail(c)}if(r!==0&&this.ttl===0&&!this.ttls&&this.initializeTTLTracking(),g||this.setItemTTL(c,r),this.disposeAfter)for(;this.disposed.length;)this.disposeAfter(...this.disposed.shift());return this}newIndex(){return this.size===0?this.tail:this.size===this.max?this.evict():this.free.length!==0?this.free.pop():this.initialFill++}pop(){if(this.size){let A=this.valList[this.head];return this.evict(),A}}evict(){let A=this.head,t=this.keyList[A],r=this.valList[A];return this.isBackgroundFetch(r)?r.__abortController.abort():(this.dispose(r,t,"evict"),this.disposeAfter&&this.disposed.push([r,t,"evict"])),this.removeItemSize(A),this.head=this.next[A],this.keyMap.delete(t),this.size--,A}has(A){return this.keyMap.has(A)&&!this.isStale(this.keyMap.get(A))}peek(A,{allowStale:t=this.allowStale}={}){let r=this.keyMap.get(A);if(r!==void 0&&(t||!this.isStale(r)))return this.valList[r]}backgroundFetch(A,t,r){let i=t===void 0?void 0:this.valList[t];if(this.isBackgroundFetch(i))return i;let n=new hp,o={signal:n.signal,options:r},g=Promise.resolve(this.fetchMethod(A,i,o)).then(c=>(n.signal.aborted||this.set(A,c,o.options),c));return g.__abortController=n,g.__staleWhileFetching=i,t===void 0?(this.set(A,g,o.options),t=this.keyMap.get(A)):this.valList[t]=g,g}isBackgroundFetch(A){return A&&typeof A=="object"&&typeof A.then=="function"&&Object.prototype.hasOwnProperty.call(A,"__staleWhileFetching")}async fetch(A,{allowStale:t=this.allowStale,updateAgeOnGet:r=this.updateAgeOnGet,ttl:i=this.ttl,noDisposeOnSet:n=this.noDisposeOnSet,size:o=0,sizeCalculation:g=this.sizeCalculation,noUpdateTTL:c=this.noUpdateTTL}={}){if(!this.fetchMethod)return this.get(A,{allowStale:t,updateAgeOnGet:r});let E={allowStale:t,updateAgeOnGet:r,ttl:i,noDisposeOnSet:n,size:o,sizeCalculation:g,noUpdateTTL:c},C=this.keyMap.get(A);if(C===void 0)return this.backgroundFetch(A,C,E);{let I=this.valList[C];if(this.isBackgroundFetch(I))return t&&I.__staleWhileFetching!==void 0?I.__staleWhileFetching:I;if(!this.isStale(C))return this.moveToTail(C),r&&this.updateItemAge(C),I;let Q=this.backgroundFetch(A,C,E);return t&&Q.__staleWhileFetching!==void 0?Q.__staleWhileFetching:Q}}get(A,{allowStale:t=this.allowStale,updateAgeOnGet:r=this.updateAgeOnGet}={}){let i=this.keyMap.get(A);if(i!==void 0){let n=this.valList[i],o=this.isBackgroundFetch(n);return this.isStale(i)?o?t?n.__staleWhileFetching:void 0:(this.delete(A),t?n:void 0):o?void 0:(this.moveToTail(i),r&&this.updateItemAge(i),n)}}connect(A,t){this.prev[t]=A,this.next[A]=t}moveToTail(A){A!==this.tail&&(A===this.head?this.head=this.next[A]:this.connect(this.prev[A],this.next[A]),this.connect(this.tail,A),this.tail=A)}get del(){return QE("del","delete"),this.delete}delete(A){let t=!1;if(this.size!==0){let r=this.keyMap.get(A);if(r!==void 0)if(t=!0,this.size===1)this.clear();else{this.removeItemSize(r);let i=this.valList[r];this.isBackgroundFetch(i)?i.__abortController.abort():(this.dispose(i,A,"delete"),this.disposeAfter&&this.disposed.push([i,A,"delete"])),this.keyMap.delete(A),this.keyList[r]=null,this.valList[r]=null,r===this.tail?this.tail=this.prev[r]:r===this.head?this.head=this.next[r]:(this.next[this.prev[r]]=this.next[r],this.prev[this.next[r]]=this.prev[r]),this.size--,this.free.push(r)}}if(this.disposed)for(;this.disposed.length;)this.disposeAfter(...this.disposed.shift());return t}clear(){for(let A of this.rindexes({allowStale:!0})){let t=this.valList[A];if(this.isBackgroundFetch(t))t.__abortController.abort();else{let r=this.keyList[A];this.dispose(t,r,"delete"),this.disposeAfter&&this.disposed.push([t,r,"delete"])}}if(this.keyMap.clear(),this.valList.fill(null),this.keyList.fill(null),this.ttls&&(this.ttls.fill(0),this.starts.fill(0)),this.sizes&&this.sizes.fill(0),this.head=0,this.tail=0,this.initialFill=1,this.free.length=0,this.calculatedSize=0,this.size=0,this.disposed)for(;this.disposed.length;)this.disposeAfter(...this.disposed.shift())}get reset(){return QE("reset","clear"),this.clear}get length(){return TM("length","size"),this.size}};fp.exports=lt});var wp=p((q2,pp)=>{"use strict";var eA=(...e)=>e.every(A=>A)?e.join(""):"",UA=e=>e?encodeURIComponent(e):"",yp=e=>e.toLowerCase().replace(/^\W+|\/|\W+$/g,"").replace(/\W+/g,"-"),YM={sshtemplate:({domain:e,user:A,project:t,committish:r})=>`git@${e}:${A}/${t}.git${eA("#",r)}`,sshurltemplate:({domain:e,user:A,project:t,committish:r})=>`git+ssh://git@${e}/${A}/${t}.git${eA("#",r)}`,edittemplate:({domain:e,user:A,project:t,committish:r,editpath:i,path:n})=>`https://${e}/${A}/${t}${eA("/",i,"/",UA(r||"HEAD"),"/",n)}`,browsetemplate:({domain:e,user:A,project:t,committish:r,treepath:i})=>`https://${e}/${A}/${t}${eA("/",i,"/",UA(r))}`,browsetreetemplate:({domain:e,user:A,project:t,committish:r,treepath:i,path:n,fragment:o,hashformat:g})=>`https://${e}/${A}/${t}/${i}/${UA(r||"HEAD")}/${n}${eA("#",g(o||""))}`,browseblobtemplate:({domain:e,user:A,project:t,committish:r,blobpath:i,path:n,fragment:o,hashformat:g})=>`https://${e}/${A}/${t}/${i}/${UA(r||"HEAD")}/${n}${eA("#",g(o||""))}`,docstemplate:({domain:e,user:A,project:t,treepath:r,committish:i})=>`https://${e}/${A}/${t}${eA("/",r,"/",UA(i))}#readme`,httpstemplate:({auth:e,domain:A,user:t,project:r,committish:i})=>`git+https://${eA(e,"@")}${A}/${t}/${r}.git${eA("#",i)}`,filetemplate:({domain:e,user:A,project:t,committish:r,path:i})=>`https://${e}/${A}/${t}/raw/${UA(r||"HEAD")}/${i}`,shortcuttemplate:({type:e,user:A,project:t,committish:r})=>`${e}:${A}/${t}${eA("#",r)}`,pathtemplate:({user:e,project:A,committish:t})=>`${e}/${A}${eA("#",t)}`,bugstemplate:({domain:e,user:A,project:t})=>`https://${e}/${A}/${t}/issues`,hashformat:yp},jt={};jt.github={protocols:["git:","http:","git+ssh:","git+https:","ssh:","https:"],domain:"github.com",treepath:"tree",blobpath:"blob",editpath:"edit",filetemplate:({auth:e,user:A,project:t,committish:r,path:i})=>`https://${eA(e,"@")}raw.githubusercontent.com/${A}/${t}/${UA(r||"HEAD")}/${i}`,gittemplate:({auth:e,domain:A,user:t,project:r,committish:i})=>`git://${eA(e,"@")}${A}/${t}/${r}.git${eA("#",i)}`,tarballtemplate:({domain:e,user:A,project:t,committish:r})=>`https://codeload.${e}/${A}/${t}/tar.gz/${UA(r||"HEAD")}`,extract:e=>{let[,A,t,r,i]=e.pathname.split("/",5);if(!(r&&r!=="tree")&&(r||(i=e.hash.slice(1)),t&&t.endsWith(".git")&&(t=t.slice(0,-4)),!(!A||!t)))return{user:A,project:t,committish:i}}};jt.bitbucket={protocols:["git+ssh:","git+https:","ssh:","https:"],domain:"bitbucket.org",treepath:"src",blobpath:"src",editpath:"?mode=edit",edittemplate:({domain:e,user:A,project:t,committish:r,treepath:i,path:n,editpath:o})=>`https://${e}/${A}/${t}${eA("/",i,"/",UA(r||"HEAD"),"/",n,o)}`,tarballtemplate:({domain:e,user:A,project:t,committish:r})=>`https://${e}/${A}/${t}/get/${UA(r||"HEAD")}.tar.gz`,extract:e=>{let[,A,t,r]=e.pathname.split("/",4);if(!["get"].includes(r)&&(t&&t.endsWith(".git")&&(t=t.slice(0,-4)),!(!A||!t)))return{user:A,project:t,committish:e.hash.slice(1)}}};jt.gitlab={protocols:["git+ssh:","git+https:","ssh:","https:"],domain:"gitlab.com",treepath:"tree",blobpath:"tree",editpath:"-/edit",httpstemplate:({auth:e,domain:A,user:t,project:r,committish:i})=>`git+https://${eA(e,"@")}${A}/${t}/${r}.git${eA("#",i)}`,tarballtemplate:({domain:e,user:A,project:t,committish:r})=>`https://${e}/${A}/${t}/repository/archive.tar.gz?ref=${UA(r||"HEAD")}`,extract:e=>{let A=e.pathname.slice(1);if(A.includes("/-/")||A.includes("/archive.tar.gz"))return;let t=A.split("/"),r=t.pop();r.endsWith(".git")&&(r=r.slice(0,-4));let i=t.join("/");if(!(!i||!r))return{user:i,project:r,committish:e.hash.slice(1)}}};jt.gist={protocols:["git:","git+ssh:","git+https:","ssh:","https:"],domain:"gist.github.com",editpath:"edit",sshtemplate:({domain:e,project:A,committish:t})=>`git@${e}:${A}.git${eA("#",t)}`,sshurltemplate:({domain:e,project:A,committish:t})=>`git+ssh://git@${e}/${A}.git${eA("#",t)}`,edittemplate:({domain:e,user:A,project:t,committish:r,editpath:i})=>`https://${e}/${A}/${t}${eA("/",UA(r))}/${i}`,browsetemplate:({domain:e,project:A,committish:t})=>`https://${e}/${A}${eA("/",UA(t))}`,browsetreetemplate:({domain:e,project:A,committish:t,path:r,hashformat:i})=>`https://${e}/${A}${eA("/",UA(t))}${eA("#",i(r))}`,browseblobtemplate:({domain:e,project:A,committish:t,path:r,hashformat:i})=>`https://${e}/${A}${eA("/",UA(t))}${eA("#",i(r))}`,docstemplate:({domain:e,project:A,committish:t})=>`https://${e}/${A}${eA("/",UA(t))}`,httpstemplate:({domain:e,project:A,committish:t})=>`git+https://${e}/${A}.git${eA("#",t)}`,filetemplate:({user:e,project:A,committish:t,path:r})=>`https://gist.githubusercontent.com/${e}/${A}/raw${eA("/",UA(t))}/${r}`,shortcuttemplate:({type:e,project:A,committish:t})=>`${e}:${A}${eA("#",t)}`,pathtemplate:({project:e,committish:A})=>`${e}${eA("#",A)}`,bugstemplate:({domain:e,project:A})=>`https://${e}/${A}`,gittemplate:({domain:e,project:A,committish:t})=>`git://${e}/${A}.git${eA("#",t)}`,tarballtemplate:({project:e,committish:A})=>`https://codeload.github.com/gist/${e}/tar.gz/${UA(A||"HEAD")}`,extract:e=>{let[,A,t,r]=e.pathname.split("/",4);if(r!=="raw"){if(!t){if(!A)return;t=A,A=null}return t.endsWith(".git")&&(t=t.slice(0,-4)),{user:A,project:t,committish:e.hash.slice(1)}}},hashformat:function(e){return e&&"file-"+yp(e)}};jt.sourcehut={protocols:["git+ssh:","https:"],domain:"git.sr.ht",treepath:"tree",blobpath:"tree",filetemplate:({domain:e,user:A,project:t,committish:r,path:i})=>`https://${e}/${A}/${t}/blob/${UA(r)||"HEAD"}/${i}`,httpstemplate:({domain:e,user:A,project:t,committish:r})=>`https://${e}/${A}/${t}.git${eA("#",r)}`,tarballtemplate:({domain:e,user:A,project:t,committish:r})=>`https://${e}/${A}/${t}/archive/${UA(r)||"HEAD"}.tar.gz`,bugstemplate:({user:e,project:A})=>`https://todo.sr.ht/${e}/${A}`,extract:e=>{let[,A,t,r]=e.pathname.split("/",4);if(!["archive"].includes(r)&&(t&&t.endsWith(".git")&&(t=t.slice(0,-4)),!(!A||!t)))return{user:A,project:t,committish:e.hash.slice(1)}}};for(let[e,A]of Object.entries(jt))jt[e]=Object.assign({},YM,A);pp.exports=jt});var dE=p((T2,mp)=>{var JM=k("url"),fE=(e,A,t)=>{let r=e.indexOf(t);return e.lastIndexOf(A,r>-1?r:1/0)},Sp=e=>{try{return new JM.URL(e)}catch{}},GM=(e,A)=>{let t=e.indexOf(":"),r=e.slice(0,t+1);if(Object.prototype.hasOwnProperty.call(A,r))return e;let i=e.indexOf("@");return i>-1?i>t?`git+ssh://${e}`:e:e.indexOf("//")===t+1?e:`${e.slice(0,t+1)}//${e.slice(t+1)}`},HM=e=>{let A=fE(e,"@","#"),t=fE(e,":","#");return t>A&&(e=e.slice(0,t)+"/"+e.slice(t+1)),fE(e,":","#")===-1&&e.indexOf("//")===-1&&(e=`git+ssh://${e}`),e};mp.exports=(e,A)=>{let t=A?GM(e,A):e;return Sp(t)||Sp(HM(t))}});var bp=p((Y2,Dp)=>{"use strict";var KM=dE(),vM=e=>{let A=e.indexOf("#"),t=e.indexOf("/"),r=e.indexOf("/",t+1),i=e.indexOf(":"),n=/\s/.exec(e),o=e.indexOf("@"),g=!n||A>-1&&n.index>A,c=o===-1||A>-1&&o>A,E=i===-1||A>-1&&i>A,C=r===-1||A>-1&&r>A,I=t>0,Q=A>-1?e[A-1]!=="/":!e.endsWith("/"),B=!e.startsWith(".");return g&&I&&Q&&B&&c&&E&&C};Dp.exports=(e,A,{gitHosts:t,protocols:r})=>{var w,y;if(!e)return;let i=vM(e)?`github:${e}`:e,n=KM(i,r);if(!n)return;let o=t.byShortcut[n.protocol],g=t.byDomain[n.hostname.startsWith("www.")?n.hostname.slice(4):n.hostname],c=o||g;if(!c)return;let E=t[o||g],C=null;((w=r[n.protocol])==null?void 0:w.auth)&&(n.username||n.password)&&(C=`${n.username}${n.password?":"+n.password:""}`);let I=null,Q=null,B=null,u=null;try{if(o){let d=n.pathname.startsWith("/")?n.pathname.slice(1):n.pathname,m=d.indexOf("@");m>-1&&(d=d.slice(m+1));let N=d.lastIndexOf("/");N>-1?(Q=decodeURIComponent(d.slice(0,N)),Q||(Q=null),B=decodeURIComponent(d.slice(N+1))):B=decodeURIComponent(d),B.endsWith(".git")&&(B=B.slice(0,-4)),n.hash&&(I=decodeURIComponent(n.hash.slice(1))),u="shortcut"}else{if(!E.protocols.includes(n.protocol))return;let d=E.extract(n);if(!d)return;Q=d.user&&decodeURIComponent(d.user),B=decodeURIComponent(d.project),I=decodeURIComponent(d.committish),u=((y=r[n.protocol])==null?void 0:y.name)||n.protocol.slice(0,-1)}}catch(d){if(d instanceof URIError)return;throw d}return[c,Q,C,B,I,u,A]}});var Rp=p((J2,kp)=>{"use strict";var VM=dp(),xM=wp(),_M=bp(),WM=dE(),yE=new VM({max:1e3}),$t,ys,JA,ZA,Et=class{constructor(A,t,r,i,n,o,g={}){xA(this,JA);Object.assign(this,Z(Et,$t)[A],{type:A,user:t,auth:r,project:i,committish:n,default:o,opts:g})}static addHost(A,t){Z(Et,$t)[A]=t,Z(Et,$t).byDomain[t.domain]=A,Z(Et,$t).byShortcut[`${A}:`]=A,Z(Et,ys)[`${A}:`]={name:A}}static fromUrl(A,t){if(typeof A!="string")return;let r=A+JSON.stringify(t||{});if(!yE.has(r)){let i=_M(A,t,{gitHosts:Z(Et,$t),protocols:Z(Et,ys)});yE.set(r,i?new Et(...i):void 0)}return yE.get(r)}static parseUrl(A){return WM(A)}hash(){return this.committish?`#${this.committish}`:""}ssh(A){return _A(this,JA,ZA).call(this,this.sshtemplate,A)}sshurl(A){return _A(this,JA,ZA).call(this,this.sshurltemplate,A)}browse(A,...t){return typeof A!="string"?_A(this,JA,ZA).call(this,this.browsetemplate,A):typeof t[0]!="string"?_A(this,JA,ZA).call(this,this.browsetreetemplate,{...t[0],path:A}):_A(this,JA,ZA).call(this,this.browsetreetemplate,{...t[1],fragment:t[0],path:A})}browseFile(A,...t){return typeof t[0]!="string"?_A(this,JA,ZA).call(this,this.browseblobtemplate,{...t[0],path:A}):_A(this,JA,ZA).call(this,this.browseblobtemplate,{...t[1],fragment:t[0],path:A})}docs(A){return _A(this,JA,ZA).call(this,this.docstemplate,A)}bugs(A){return _A(this,JA,ZA).call(this,this.bugstemplate,A)}https(A){return _A(this,JA,ZA).call(this,this.httpstemplate,A)}git(A){return _A(this,JA,ZA).call(this,this.gittemplate,A)}shortcut(A){return _A(this,JA,ZA).call(this,this.shortcuttemplate,A)}path(A){return _A(this,JA,ZA).call(this,this.pathtemplate,A)}tarball(A){return _A(this,JA,ZA).call(this,this.tarballtemplate,{...A,noCommittish:!1})}file(A,t){return _A(this,JA,ZA).call(this,this.filetemplate,{...t,path:A})}edit(A,t){return _A(this,JA,ZA).call(this,this.edittemplate,{...t,path:A})}getDefaultRepresentation(){return this.default}toString(A){return this.default&&typeof this[this.default]=="function"?this[this.default](A):this.sshurl(A)}},Ti=Et;$t=new WeakMap,ys=new WeakMap,JA=new WeakSet,ZA=function(A,t){if(typeof A!="function")return null;let r={...this,...this.opts,...t};r.path||(r.path=""),r.path.startsWith("/")&&(r.path=r.path.slice(1)),r.noCommittish&&(r.committish=null);let i=A(r);return r.noGitPlus&&i.startsWith("git+")?i.slice(4):i},xA(Ti,$t,{byShortcut:{},byDomain:{}}),xA(Ti,ys,{"git+ssh:":{name:"sshurl"},"ssh:":{name:"sshurl"},"git+https:":{name:"https",auth:!0},"git:":{auth:!0},"http:":{auth:!0},"https:":{auth:!0},"git+http:":{auth:!0}});for(let[e,A]of Object.entries(xM))Ti.addHost(e,A);kp.exports=Ti});function hg({onlyFirst:e=!1}={}){let A=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(A,e?void 0:"g")}var na=ke(bl(),1);var ql=ke(_u(),1);var Wu=ql.default.HttpProxyAgent,Ou=ql.default.HttpsProxyAgent;var jn=class extends Map{constructor(A={}){if(super(),!(A.maxSize&&A.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");if(typeof A.maxAge=="number"&&A.maxAge===0)throw new TypeError("`maxAge` must be a number greater than 0");this.maxSize=A.maxSize,this.maxAge=A.maxAge||Number.POSITIVE_INFINITY,this.onEviction=A.onEviction,this.cache=new Map,this.oldCache=new Map,this._size=0}_emitEvictions(A){if(typeof this.onEviction=="function")for(let[t,r]of A)this.onEviction(t,r.value)}_deleteIfExpired(A,t){return typeof t.expiry=="number"&&t.expiry<=Date.now()?(typeof this.onEviction=="function"&&this.onEviction(A,t.value),this.delete(A)):!1}_getOrDeleteIfExpired(A,t){if(this._deleteIfExpired(A,t)===!1)return t.value}_getItemValue(A,t){return t.expiry?this._getOrDeleteIfExpired(A,t):t.value}_peek(A,t){let r=t.get(A);return this._getItemValue(A,r)}_set(A,t){this.cache.set(A,t),this._size++,this._size>=this.maxSize&&(this._size=0,this._emitEvictions(this.oldCache),this.oldCache=this.cache,this.cache=new Map)}_moveToRecent(A,t){this.oldCache.delete(A),this._set(A,t)}*_entriesAscending(){for(let A of this.oldCache){let[t,r]=A;this.cache.has(t)||this._deleteIfExpired(t,r)===!1&&(yield A)}for(let A of this.cache){let[t,r]=A;this._deleteIfExpired(t,r)===!1&&(yield A)}}get(A){if(this.cache.has(A)){let t=this.cache.get(A);return this._getItemValue(A,t)}if(this.oldCache.has(A)){let t=this.oldCache.get(A);if(this._deleteIfExpired(A,t)===!1)return this._moveToRecent(A,t),t.value}}set(A,t,{maxAge:r=this.maxAge}={}){let i=typeof r=="number"&&r!==Number.POSITIVE_INFINITY?Date.now()+r:void 0;this.cache.has(A)?this.cache.set(A,{value:t,expiry:i}):this._set(A,{value:t,expiry:i})}has(A){return this.cache.has(A)?!this._deleteIfExpired(A,this.cache.get(A)):this.oldCache.has(A)?!this._deleteIfExpired(A,this.oldCache.get(A)):!1}peek(A){if(this.cache.has(A))return this._peek(A,this.cache);if(this.oldCache.has(A))return this._peek(A,this.oldCache)}delete(A){let t=this.cache.delete(A);return t&&this._size--,this.oldCache.delete(A)||t}clear(){this.cache.clear(),this.oldCache.clear(),this._size=0}resize(A){if(!(A&&A>0))throw new TypeError("`maxSize` must be a number greater than 0");let t=[...this._entriesAscending()],r=t.length-A;r<0?(this.cache=new Map(t),this.oldCache=new Map,this._size=t.length):(r>0&&this._emitEvictions(t.slice(0,r)),this.oldCache=new Map(t.slice(r)),this.cache=new Map,this._size=0),this.maxSize=A}*keys(){for(let[A]of this)yield A}*values(){for(let[,A]of this)yield A}*[Symbol.iterator](){for(let A of this.cache){let[t,r]=A;this._deleteIfExpired(t,r)===!1&&(yield[t,r.value])}for(let A of this.oldCache){let[t,r]=A;this.cache.has(t)||this._deleteIfExpired(t,r)===!1&&(yield[t,r.value])}}*entriesDescending(){let A=[...this.cache];for(let t=A.length-1;t>=0;--t){let r=A[t],[i,n]=r;this._deleteIfExpired(i,n)===!1&&(yield[i,n.value])}A=[...this.oldCache];for(let t=A.length-1;t>=0;--t){let r=A[t],[i,n]=r;this.cache.has(i)||this._deleteIfExpired(i,n)===!1&&(yield[i,n.value])}}*entriesAscending(){for(let[A,t]of this._entriesAscending())yield[A,t.value]}get size(){if(!this._size)return this.oldCache.size;let A=0;for(let t of this.oldCache.keys())this.cache.has(t)||A++;return Math.min(this._size+A,this.maxSize)}entries(){return this.entriesAscending()}forEach(A,t=this){for(let[r,i]of this.entriesAscending())A.call(t,i,r,this)}get[Symbol.toStringTag](){return JSON.stringify([...this.entriesAscending()])}};var Xu=ke(zu(),1);import{Agent as WF}from"http";import{Agent as OF}from"https";var PF={agentCacheSize:512},Zu={maxSockets:64,keepAlive:!1},$n=class extends Error{constructor(A){super(A),this.name="TimeoutError",Error.captureStackTrace(this,$n)}};function Tl(e,A={}){if(!("undici"in A))throw new Error("The 'undici' option is required");let t={...PF,...A},r=new jn({maxSize:t.agentCacheSize});function i(o,g={}){let{origin:c,protocol:E}=new URL(o),C=g!=null&&g.noProxy?null:(0,Xu.getProxyForUrl)(o),I=JSON.stringify({proxyUrl:C,origin:c,...g});if(r.has(I))return r.get(I);let Q,B=E==="https:";if("noProxy"in g&&delete g.noProxy,A.undici){let u={...g};"keepAlive"in u&&(u.pipelining=u.keepAlive?1:0,delete u.keepAlive),"maxSockets"in u&&(u.connections=u.maxSockets,delete u.maxSockets),C?Q=new na.ProxyAgent({...u,uri:C}):Q=new na.Agent(u)}else C?Q=new(B?Ou:Wu)({...g,proxy:C}):Q=new(B?OF:WF)(g);return r.set(I,Q),Q}let n=(o,{timeout:g=0,agentOpts:c={},...E}={})=>new Promise((C,I)=>{var u;if(!A.undici&&!("agent"in E)){let w=i(o,{...Zu,...c});w&&(E.agent=w)}else if(A.undici&&!("dispatcher"in E)){let w=i(o,{...Zu,...c});w&&(E.dispatcher=w)}let Q,B;g&&(!("signal"in E)&&globalThis.AbortController&&(B=new AbortController,E.signal=B.signal),Q=setTimeout(()=>{var y;(y=B==null?void 0:B.abort)==null||y.call(B);let w=new $n(`${E.method||"GET"} ${o} timed out after ${g}ms`);I(w)},g),(u=Q==null?void 0:Q.unref)==null||u.call(Q)),e(o,E).then(w=>{Q&&clearTimeout(Q),C(w)}).catch(w=>{if(Q&&clearTimeout(Q),w.name==="AbortError")return C(null);I(w)})});return n.clearCache=()=>{for(let o of r.values())"destroy"in o&&o.destroy();r.clear()},n}var Yp=ke(Yl(),1);import pL from"http";import wL from"https";import Di from"zlib";import Yf,{PassThrough as Jf,pipeline as bi}from"stream";import{Buffer as ha}from"buffer";function ZF(e){if(!/^data:/i.test(e))throw new TypeError('`uri` does not appear to be a Data URI (must begin with "data:")');e=e.replace(/\r?\n/g,"");let A=e.indexOf(",");if(A===-1||A<=4)throw new TypeError("malformed data: URI");let t=e.substring(5,A).split(";"),r="",i=!1,n=t[0]||"text/plain",o=n;for(let C=1;C<t.length;C++)t[C]==="base64"?i=!0:(o+=`;${t[C]}`,t[C].indexOf("charset=")===0&&(r=t[C].substring(8)));!t[0]&&!r.length&&(o+=";charset=US-ASCII",r="US-ASCII");let g=i?"base64":"ascii",c=unescape(e.substring(A+1)),E=Buffer.from(c,g);return E.type=n,E.typeFull=o,E.charset=r,E}var ef=ZF;es();aa();import Zt,{PassThrough as wf}from"stream";import{types as Sf,deprecate as Wl,promisify as CL}from"util";import{Buffer as Ke}from"buffer";var kt=class extends Error{constructor(A,t){super(A),Error.captureStackTrace(this,this.constructor),this.type=t}get name(){return this.constructor.name}get[Symbol.toStringTag](){return this.constructor.name}};var Ie=class extends kt{constructor(A,t,r){super(A,t),r&&(this.code=this.errno=r.code,this.erroredSysCall=r.syscall)}};var ga=Symbol.toStringTag,Kl=e=>typeof e=="object"&&typeof e.append=="function"&&typeof e.delete=="function"&&typeof e.get=="function"&&typeof e.getAll=="function"&&typeof e.has=="function"&&typeof e.set=="function"&&typeof e.sort=="function"&&e[ga]==="URLSearchParams",ns=e=>e&&typeof e=="object"&&typeof e.arrayBuffer=="function"&&typeof e.type=="string"&&typeof e.stream=="function"&&typeof e.constructor=="function"&&/^(Blob|File)$/.test(e[ga]),Cf=e=>typeof e=="object"&&(e[ga]==="AbortSignal"||e[ga]==="EventTarget"),If=(e,A)=>{let t=new URL(A).hostname,r=new URL(e).hostname;return t===r||t.endsWith(`.${r}`)},Qf=(e,A)=>{let t=new URL(A).protocol,r=new URL(e).protocol;return t===r};var IL=CL(Zt.pipeline),Qe=Symbol("Body internals"),ct=class{constructor(A,{size:t=0}={}){let r=null;A===null?A=null:Kl(A)?A=Ke.from(A.toString()):ns(A)||Ke.isBuffer(A)||(Sf.isAnyArrayBuffer(A)?A=Ke.from(A):ArrayBuffer.isView(A)?A=Ke.from(A.buffer,A.byteOffset,A.byteLength):A instanceof Zt||(A instanceof Dr?(A=Ef(A),r=A.type.split("=")[1]):A=Ke.from(String(A))));let i=A;Ke.isBuffer(A)?i=Zt.Readable.from(A):ns(A)&&(i=Zt.Readable.from(A.stream())),this[Qe]={body:A,stream:i,boundary:r,disturbed:!1,error:null},this.size=t,A instanceof Zt&&A.on("error",n=>{let o=n instanceof kt?n:new Ie(`Invalid response body while trying to fetch ${this.url}: ${n.message}`,"system",n);this[Qe].error=o})}get body(){return this[Qe].stream}get bodyUsed(){return this[Qe].disturbed}async arrayBuffer(){let{buffer:A,byteOffset:t,byteLength:r}=await _l(this);return A.slice(t,t+r)}async formData(){let A=this.headers.get("content-type");if(A.startsWith("application/x-www-form-urlencoded")){let r=new Dr,i=new URLSearchParams(await this.text());for(let[n,o]of i)r.append(n,o);return r}let{toFormData:t}=await Promise.resolve().then(()=>(pf(),yf));return t(this.body,A)}async blob(){let A=this.headers&&this.headers.get("content-type")||this[Qe].body&&this[Qe].body.type||"",t=await this.arrayBuffer();return new bt([t],{type:A})}async json(){let A=await this.text();return JSON.parse(A)}async text(){let A=await _l(this);return new TextDecoder().decode(A)}buffer(){return _l(this)}};ct.prototype.buffer=Wl(ct.prototype.buffer,"Please use 'response.arrayBuffer()' instead of 'response.buffer()'","node-fetch#buffer");Object.defineProperties(ct.prototype,{body:{enumerable:!0},bodyUsed:{enumerable:!0},arrayBuffer:{enumerable:!0},blob:{enumerable:!0},json:{enumerable:!0},text:{enumerable:!0},data:{get:Wl(()=>{},"data doesn't exist, use json(), text(), arrayBuffer(), or body instead","https://github.com/node-fetch/node-fetch/issues/1000 (response)")}});async function _l(e){if(e[Qe].disturbed)throw new TypeError(`body used already for: ${e.url}`);if(e[Qe].disturbed=!0,e[Qe].error)throw e[Qe].error;let{body:A}=e;if(A===null)return Ke.alloc(0);if(!(A instanceof Zt))return Ke.alloc(0);let t=[],r=0;try{for await(let i of A){if(e.size>0&&r+i.length>e.size){let n=new Ie(`content size at ${e.url} over limit: ${e.size}`,"max-size");throw A.destroy(n),n}r+=i.length,t.push(i)}}catch(i){throw i instanceof kt?i:new Ie(`Invalid response body while trying to fetch ${e.url}: ${i.message}`,"system",i)}if(A.readableEnded===!0||A._readableState.ended===!0)try{return t.every(i=>typeof i=="string")?Ke.from(t.join("")):Ke.concat(t,r)}catch(i){throw new Ie(`Could not create Buffer from response body for ${e.url}: ${i.message}`,"system",i)}else throw new Ie(`Premature close of server response while trying to fetch ${e.url}`)}var Si=(e,A)=>{let t,r,{body:i}=e[Qe];if(e.bodyUsed)throw new Error("cannot clone body after it is used");return i instanceof Zt&&typeof i.getBoundary!="function"&&(t=new wf({highWaterMark:A}),r=new wf({highWaterMark:A}),i.pipe(t),i.pipe(r),e[Qe].stream=t,i=r),i},QL=Wl(e=>e.getBoundary(),"form-data doesn't follow the spec and requires special treatment. Use alternative package","https://github.com/node-fetch/node-fetch/issues/1167"),Ea=(e,A)=>e===null?null:typeof e=="string"?"text/plain;charset=UTF-8":Kl(e)?"application/x-www-form-urlencoded;charset=UTF-8":ns(e)?e.type||null:Ke.isBuffer(e)||Sf.isAnyArrayBuffer(e)||ArrayBuffer.isView(e)?null:e instanceof Dr?`multipart/form-data; boundary=${A[Qe].boundary}`:e&&typeof e.getBoundary=="function"?`multipart/form-data;boundary=${QL(e)}`:e instanceof Zt?null:"text/plain;charset=UTF-8",mf=e=>{let{body:A}=e[Qe];return A===null?0:ns(A)?A.size:Ke.isBuffer(A)?A.length:A&&typeof A.getLengthSync=="function"&&A.hasKnownLength&&A.hasKnownLength()?A.getLengthSync():null},Df=async(e,{body:A})=>{A===null?e.end():await IL(A,e)};import{types as bf}from"util";import Ia from"http";var Ca=typeof Ia.validateHeaderName=="function"?Ia.validateHeaderName:e=>{if(!/^[\^`\-\w!#$%&'*+.|~]+$/.test(e)){let A=new TypeError(`Header name must be a valid HTTP token [${e}]`);throw Object.defineProperty(A,"code",{value:"ERR_INVALID_HTTP_TOKEN"}),A}},Ol=typeof Ia.validateHeaderValue=="function"?Ia.validateHeaderValue:(e,A)=>{if(/[^\t\u0020-\u007E\u0080-\u00FF]/.test(A)){let t=new TypeError(`Invalid character in header content ["${e}"]`);throw Object.defineProperty(t,"code",{value:"ERR_INVALID_CHAR"}),t}},ne=class extends URLSearchParams{constructor(A){let t=[];if(A instanceof ne){let r=A.raw();for(let[i,n]of Object.entries(r))t.push(...n.map(o=>[i,o]))}else if(A!=null)if(typeof A=="object"&&!bf.isBoxedPrimitive(A)){let r=A[Symbol.iterator];if(r==null)t.push(...Object.entries(A));else{if(typeof r!="function")throw new TypeError("Header pairs must be iterable");t=[...A].map(i=>{if(typeof i!="object"||bf.isBoxedPrimitive(i))throw new TypeError("Each header pair must be an iterable object");return[...i]}).map(i=>{if(i.length!==2)throw new TypeError("Each header pair must be a name/value tuple");return[...i]})}}else throw new TypeError("Failed to construct 'Headers': The provided value is not of type '(sequence<sequence<ByteString>> or record<ByteString, ByteString>)");return t=t.length>0?t.map(([r,i])=>(Ca(r),Ol(r,String(i)),[String(r).toLowerCase(),String(i)])):void 0,super(t),new Proxy(this,{get(r,i,n){switch(i){case"append":case"set":return(o,g)=>(Ca(o),Ol(o,String(g)),URLSearchParams.prototype[i].call(r,String(o).toLowerCase(),String(g)));case"delete":case"has":case"getAll":return o=>(Ca(o),URLSearchParams.prototype[i].call(r,String(o).toLowerCase()));case"keys":return()=>(r.sort(),new Set(URLSearchParams.prototype.keys.call(r)).keys());default:return Reflect.get(r,i,n)}}})}get[Symbol.toStringTag](){return this.constructor.name}toString(){return Object.prototype.toString.call(this)}get(A){let t=this.getAll(A);if(t.length===0)return null;let r=t.join(", ");return/^content-encoding$/i.test(A)&&(r=r.toLowerCase()),r}forEach(A,t=void 0){for(let r of this.keys())Reflect.apply(A,t,[this.get(r),r,this])}*values(){for(let A of this.keys())yield this.get(A)}*entries(){for(let A of this.keys())yield[A,this.get(A)]}[Symbol.iterator](){return this.entries()}raw(){return[...this.keys()].reduce((A,t)=>(A[t]=this.getAll(t),A),{})}[Symbol.for("nodejs.util.inspect.custom")](){return[...this.keys()].reduce((A,t)=>{let r=this.getAll(t);return t==="host"?A[t]=r[0]:A[t]=r.length>1?r:r[0],A},{})}};Object.defineProperties(ne.prototype,["get","entries","forEach","values"].reduce((e,A)=>(e[A]={enumerable:!0},e),{}));function kf(e=[]){return new ne(e.reduce((A,t,r,i)=>(r%2===0&&A.push(i.slice(r,r+2)),A),[]).filter(([A,t])=>{try{return Ca(A),Ol(A,String(t)),!0}catch{return!1}}))}var BL=new Set([301,302,303,307,308]),Qa=e=>BL.has(e);var Ze=Symbol("Response internals"),zA=class extends ct{constructor(A=null,t={}){super(A,t);let r=t.status!=null?t.status:200,i=new ne(t.headers);if(A!==null&&!i.has("Content-Type")){let n=Ea(A,this);n&&i.append("Content-Type",n)}this[Ze]={type:"default",url:t.url,status:r,statusText:t.statusText||"",headers:i,counter:t.counter,highWaterMark:t.highWaterMark}}get type(){return this[Ze].type}get url(){return this[Ze].url||""}get status(){return this[Ze].status}get ok(){return this[Ze].status>=200&&this[Ze].status<300}get redirected(){return this[Ze].counter>0}get statusText(){return this[Ze].statusText}get headers(){return this[Ze].headers}get highWaterMark(){return this[Ze].highWaterMark}clone(){return new zA(Si(this,this.highWaterMark),{type:this.type,url:this.url,status:this.status,statusText:this.statusText,headers:this.headers,ok:this.ok,redirected:this.redirected,size:this.size,highWaterMark:this.highWaterMark})}static redirect(A,t=302){if(!Qa(t))throw new RangeError('Failed to execute "redirect" on "response": Invalid status code');return new zA(null,{headers:{location:new URL(A).toString()},status:t})}static error(){let A=new zA(null,{status:0,statusText:""});return A[Ze].type="error",A}static json(A=void 0,t={}){let r=JSON.stringify(A);if(r===void 0)throw new TypeError("data is not JSON serializable");let i=new ne(t&&t.headers);return i.has("content-type")||i.set("content-type","application/json"),new zA(r,{...t,headers:i})}get[Symbol.toStringTag](){return"Response"}};Object.defineProperties(zA.prototype,{type:{enumerable:!0},url:{enumerable:!0},status:{enumerable:!0},ok:{enumerable:!0},redirected:{enumerable:!0},statusText:{enumerable:!0},headers:{enumerable:!0},clone:{enumerable:!0}});import{format as fL}from"url";import{deprecate as dL}from"util";var Rf=e=>{if(e.search)return e.search;let A=e.href.length-1,t=e.hash||(e.href[A]==="#"?"#":"");return e.href[A-t.length]==="?"?"?":""};import{isIP as hL}from"net";function Nf(e,A=!1){return e==null||(e=new URL(e),/^(about|blob|data):$/.test(e.protocol))?"no-referrer":(e.username="",e.password="",e.hash="",A&&(e.pathname="",e.search=""),e)}var Ff=new Set(["","no-referrer","no-referrer-when-downgrade","same-origin","origin","strict-origin","origin-when-cross-origin","strict-origin-when-cross-origin","unsafe-url"]),Lf="strict-origin-when-cross-origin";function Uf(e){if(!Ff.has(e))throw new TypeError(`Invalid referrerPolicy: ${e}`);return e}function uL(e){if(/^(http|ws)s:$/.test(e.protocol))return!0;let A=e.host.replace(/(^\[)|(]$)/g,""),t=hL(A);return t===4&&/^127\./.test(A)||t===6&&/^(((0+:){7})|(::(0+:){0,6}))0*1$/.test(A)?!0:e.host==="localhost"||e.host.endsWith(".localhost")?!1:e.protocol==="file:"}function mi(e){return/^about:(blank|srcdoc)$/.test(e)||e.protocol==="data:"||/^(blob|filesystem):$/.test(e.protocol)?!0:uL(e)}function Mf(e,{referrerURLCallback:A,referrerOriginCallback:t}={}){if(e.referrer==="no-referrer"||e.referrerPolicy==="")return null;let r=e.referrerPolicy;if(e.referrer==="about:client")return"no-referrer";let i=e.referrer,n=Nf(i),o=Nf(i,!0);n.toString().length>4096&&(n=o),A&&(n=A(n)),t&&(o=t(o));let g=new URL(e.url);switch(r){case"no-referrer":return"no-referrer";case"origin":return o;case"unsafe-url":return n;case"strict-origin":return mi(n)&&!mi(g)?"no-referrer":o.toString();case"strict-origin-when-cross-origin":return n.origin===g.origin?n:mi(n)&&!mi(g)?"no-referrer":o;case"same-origin":return n.origin===g.origin?n:"no-referrer";case"origin-when-cross-origin":return n.origin===g.origin?n:o;case"no-referrer-when-downgrade":return mi(n)&&!mi(g)?"no-referrer":n;default:throw new TypeError(`Invalid referrerPolicy: ${r}`)}}function qf(e){let A=(e.get("referrer-policy")||"").split(/[,\s]+/),t="";for(let r of A)r&&Ff.has(r)&&(t=r);return t}var vA=Symbol("Request internals"),os=e=>typeof e=="object"&&typeof e[vA]=="object",yL=dL(()=>{},".data is not a valid RequestInit property, use .body instead","https://github.com/node-fetch/node-fetch/issues/1000 (request)"),Rt=class extends ct{constructor(A,t={}){let r;if(os(A)?r=new URL(A.url):(r=new URL(A),A={}),r.username!==""||r.password!=="")throw new TypeError(`${r} is an url with embedded credentials.`);let i=t.method||A.method||"GET";if(/^(delete|get|head|options|post|put)$/i.test(i)&&(i=i.toUpperCase()),!os(t)&&"data"in t&&yL(),(t.body!=null||os(A)&&A.body!==null)&&(i==="GET"||i==="HEAD"))throw new TypeError("Request with GET/HEAD method cannot have body");let n=t.body?t.body:os(A)&&A.body!==null?Si(A):null;super(n,{size:t.size||A.size||0});let o=new ne(t.headers||A.headers||{});if(n!==null&&!o.has("Content-Type")){let E=Ea(n,this);E&&o.set("Content-Type",E)}let g=os(A)?A.signal:null;if("signal"in t&&(g=t.signal),g!=null&&!Cf(g))throw new TypeError("Expected signal to be an instanceof AbortSignal or EventTarget");let c=t.referrer==null?A.referrer:t.referrer;if(c==="")c="no-referrer";else if(c){let E=new URL(c);c=/^about:(\/\/)?client$/.test(E)?"client":E}else c=void 0;this[vA]={method:i,redirect:t.redirect||A.redirect||"follow",headers:o,parsedURL:r,signal:g,referrer:c},this.follow=t.follow===void 0?A.follow===void 0?20:A.follow:t.follow,this.compress=t.compress===void 0?A.compress===void 0?!0:A.compress:t.compress,this.counter=t.counter||A.counter||0,this.agent=t.agent||A.agent,this.highWaterMark=t.highWaterMark||A.highWaterMark||16384,this.insecureHTTPParser=t.insecureHTTPParser||A.insecureHTTPParser||!1,this.referrerPolicy=t.referrerPolicy||A.referrerPolicy||""}get method(){return this[vA].method}get url(){return fL(this[vA].parsedURL)}get headers(){return this[vA].headers}get redirect(){return this[vA].redirect}get signal(){return this[vA].signal}get referrer(){if(this[vA].referrer==="no-referrer")return"";if(this[vA].referrer==="client")return"about:client";if(this[vA].referrer)return this[vA].referrer.toString()}get referrerPolicy(){return this[vA].referrerPolicy}set referrerPolicy(A){this[vA].referrerPolicy=Uf(A)}clone(){return new Rt(this)}get[Symbol.toStringTag](){return"Request"}};Object.defineProperties(Rt.prototype,{method:{enumerable:!0},url:{enumerable:!0},headers:{enumerable:!0},redirect:{enumerable:!0},clone:{enumerable:!0},signal:{enumerable:!0},referrer:{enumerable:!0},referrerPolicy:{enumerable:!0}});var Tf=e=>{let{parsedURL:A}=e[vA],t=new ne(e[vA].headers);t.has("Accept")||t.set("Accept","*/*");let r=null;if(e.body===null&&/^(post|put)$/i.test(e.method)&&(r="0"),e.body!==null){let g=mf(e);typeof g=="number"&&!Number.isNaN(g)&&(r=String(g))}r&&t.set("Content-Length",r),e.referrerPolicy===""&&(e.referrerPolicy=Lf),e.referrer&&e.referrer!=="no-referrer"?e[vA].referrer=Mf(e):e[vA].referrer="no-referrer",e[vA].referrer instanceof URL&&t.set("Referer",e.referrer),t.has("User-Agent")||t.set("User-Agent","node-fetch"),e.compress&&!t.has("Accept-Encoding")&&t.set("Accept-Encoding","gzip, deflate, br");let{agent:i}=e;typeof i=="function"&&(i=i(A)),!t.has("Connection")&&!i&&t.set("Connection","close");let n=Rf(A),o={path:A.pathname+n,method:e.method,headers:t[Symbol.for("nodejs.util.inspect.custom")](),insecureHTTPParser:e.insecureHTTPParser,agent:i};return{parsedURL:A,options:o}};var Ba=class extends kt{constructor(A,t="aborted"){super(A,t)}};aa();Vl();var SL=new Set(["data:","http:","https:"]);async function ua(e,A){return new Promise((t,r)=>{let i=new Rt(e,A),{parsedURL:n,options:o}=Tf(i);if(!SL.has(n.protocol))throw new TypeError(`node-fetch cannot load ${e}. URL scheme "${n.protocol.replace(/:$/,"")}" is not supported.`);if(n.protocol==="data:"){let u=ef(i.url),w=new zA(u,{headers:{"Content-Type":u.typeFull}});t(w);return}let g=(n.protocol==="https:"?wL:pL).request,{signal:c}=i,E=null,C=()=>{let u=new Ba("The operation was aborted.");r(u),i.body&&i.body instanceof Yf.Readable&&i.body.destroy(u),!(!E||!E.body)&&E.body.emit("error",u)};if(c&&c.aborted){C();return}let I=()=>{C(),B()},Q=g(n.toString(),o);c&&c.addEventListener("abort",I);let B=()=>{Q.abort(),c&&c.removeEventListener("abort",I)};Q.on("error",u=>{r(new Ie(`request to ${i.url} failed, reason: ${u.message}`,"system",u)),B()}),mL(Q,u=>{E&&E.body&&E.body.destroy(u)}),process.version<"v14"&&Q.on("socket",u=>{let w;u.prependListener("end",()=>{w=u._eventsCount}),u.prependListener("close",y=>{if(E&&w<u._eventsCount&&!y){let d=new Error("Premature close");d.code="ERR_STREAM_PREMATURE_CLOSE",E.body.emit("error",d)}})}),Q.on("response",u=>{Q.setTimeout(0);let w=kf(u.rawHeaders);if(Qa(u.statusCode)){let D=w.get("Location"),Y=null;try{Y=D===null?null:new URL(D,i.url)}catch{if(i.redirect!=="manual"){r(new Ie(`uri requested responds with an invalid redirect URL: ${D}`,"invalid-redirect")),B();return}}switch(i.redirect){case"error":r(new Ie(`uri requested responds with a redirect, redirect mode is set to error: ${i.url}`,"no-redirect")),B();return;case"manual":break;case"follow":{if(Y===null)break;if(i.counter>=i.follow){r(new Ie(`maximum redirect reached at: ${i.url}`,"max-redirect")),B();return}let J={headers:new ne(i.headers),follow:i.follow,counter:i.counter+1,agent:i.agent,compress:i.compress,method:i.method,body:Si(i),signal:i.signal,size:i.size,referrer:i.referrer,referrerPolicy:i.referrerPolicy};if(!If(i.url,Y)||!Qf(i.url,Y))for(let V of["authorization","www-authenticate","cookie","cookie2"])J.headers.delete(V);if(u.statusCode!==303&&i.body&&A.body instanceof Yf.Readable){r(new Ie("Cannot follow redirect with body being a readable stream","unsupported-redirect")),B();return}(u.statusCode===303||(u.statusCode===301||u.statusCode===302)&&i.method==="POST")&&(J.method="GET",J.body=void 0,J.headers.delete("content-length"));let T=qf(w);T&&(J.referrerPolicy=T),t(ua(new Rt(Y,J))),B();return}default:return r(new TypeError(`Redirect option '${i.redirect}' is not a valid value of RequestRedirect`))}}c&&u.once("end",()=>{c.removeEventListener("abort",I)});let y=bi(u,new Jf,D=>{D&&r(D)});process.version<"v12.10"&&u.on("aborted",I);let d={url:i.url,status:u.statusCode,statusText:u.statusMessage,headers:w,size:i.size,counter:i.counter,highWaterMark:i.highWaterMark},m=w.get("Content-Encoding");if(!i.compress||i.method==="HEAD"||m===null||u.statusCode===204||u.statusCode===304){E=new zA(y,d),t(E);return}let N={flush:Di.Z_SYNC_FLUSH,finishFlush:Di.Z_SYNC_FLUSH};if(m==="gzip"||m==="x-gzip"){y=bi(y,Di.createGunzip(N),D=>{D&&r(D)}),E=new zA(y,d),t(E);return}if(m==="deflate"||m==="x-deflate"){let D=bi(u,new Jf,Y=>{Y&&r(Y)});D.once("data",Y=>{(Y[0]&15)===8?y=bi(y,Di.createInflate(),J=>{J&&r(J)}):y=bi(y,Di.createInflateRaw(),J=>{J&&r(J)}),E=new zA(y,d),t(E)}),D.once("end",()=>{E||(E=new zA(y,d),t(E))});return}if(m==="br"){y=bi(y,Di.createBrotliDecompress(),D=>{D&&r(D)}),E=new zA(y,d),t(E);return}E=new zA(y,d),t(E)}),Df(Q,i).catch(r)})}function mL(e,A){let t=ha.from(`0\r
66
+ `)};function Ep(e){var A=/\.[^.]*$/.exec(e);return A?A.index+1:e.length}function Cp(e,A,t){if(e.reduce)return e.reduce(A,t);for(var r=0,i=arguments.length>=3?t:e[r++];r<e.length;r++)A(i,e[r],r);return i}function Ip(e,A){if(e.forEach)return e.forEach(A);for(var t=0;t<e.length;t++)A.call(e,e[t],t)}function Ma(e,A){if(e.map)return e.map(A);for(var t=[],r=0;r<e.length;r++)t.push(A.call(e,e[r],r));return t}});var dp=p((M2,fp)=>{var CE=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,qM=typeof AbortController<"u",hp=qM?AbortController:Object.assign(class{constructor(){this.signal=new hp.AbortSignal}abort(){this.signal.aborted=!0}},{AbortSignal:class{constructor(){this.aborted=!1}}}),hE=new Set,IE=(e,A)=>{let t=`LRU_CACHE_OPTION_${e}`;qa(t)&&uE(t,`${e} option`,`options.${A}`,lt)},QE=(e,A)=>{let t=`LRU_CACHE_METHOD_${e}`;if(qa(t)){let{prototype:r}=lt,{get:i}=Object.getOwnPropertyDescriptor(r,e);uE(t,`${e} method`,`cache.${A}()`,i)}},TM=(e,A)=>{let t=`LRU_CACHE_PROPERTY_${e}`;if(qa(t)){let{prototype:r}=lt,{get:i}=Object.getOwnPropertyDescriptor(r,e);uE(t,`${e} property`,`cache.${A}`,i)}},qa=e=>typeof process=="object"&&process&&!hE.has(e),uE=(e,A,t,r)=>{hE.add(e);let i=`The ${A} is deprecated. Please use ${t} instead.`;process.emitWarning(i,"DeprecationWarning",e,r)},Yr=e=>e&&e===Math.floor(e)&&e>0&&isFinite(e),up=e=>Yr(e)?e<=Math.pow(2,8)?Uint8Array:e<=Math.pow(2,16)?Uint16Array:e<=Math.pow(2,32)?Uint32Array:e<=Number.MAX_SAFE_INTEGER?qi:null:null,qi=class extends Array{constructor(A){super(A),this.fill(0)}},BE=class{constructor(A){let t=A?up(A):Array;this.heap=new t(A),this.length=0}push(A){this.heap[this.length++]=A}pop(){return this.heap[--this.length]}},lt=class{constructor(A={}){let{max:t=0,ttl:r,ttlResolution:i=1,ttlAutopurge:n,updateAgeOnGet:o,allowStale:g,dispose:c,disposeAfter:E,noDisposeOnSet:C,noUpdateTTL:I,maxSize:Q=0,sizeCalculation:B,fetchMethod:u}=A,{length:w,maxAge:y,stale:d}=A instanceof lt?{}:A;if(t!==0&&!Yr(t))throw new TypeError("max option must be a nonnegative integer");let m=t?up(t):Array;if(!m)throw new Error("invalid max value: "+t);if(this.max=t,this.maxSize=Q,this.sizeCalculation=B||w,this.sizeCalculation){if(!this.maxSize)throw new TypeError("cannot set sizeCalculation without setting maxSize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(this.fetchMethod=u||null,this.fetchMethod&&typeof this.fetchMethod!="function")throw new TypeError("fetchMethod must be a function if specified");if(this.keyMap=new Map,this.keyList=new Array(t).fill(null),this.valList=new Array(t).fill(null),this.next=new m(t),this.prev=new m(t),this.head=0,this.tail=0,this.free=new BE(t),this.initialFill=1,this.size=0,typeof c=="function"&&(this.dispose=c),typeof E=="function"?(this.disposeAfter=E,this.disposed=[]):(this.disposeAfter=null,this.disposed=null),this.noDisposeOnSet=!!C,this.noUpdateTTL=!!I,this.maxSize!==0){if(!Yr(this.maxSize))throw new TypeError("maxSize must be a positive integer if specified");this.initializeSizeTracking()}if(this.allowStale=!!g||!!d,this.updateAgeOnGet=!!o,this.ttlResolution=Yr(i)||i===0?i:1,this.ttlAutopurge=!!n,this.ttl=r||y||0,this.ttl){if(!Yr(this.ttl))throw new TypeError("ttl must be a positive integer if specified");this.initializeTTLTracking()}if(this.max===0&&this.ttl===0&&this.maxSize===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!this.max&&!this.maxSize){let N="LRU_CACHE_UNBOUNDED";if(qa(N)){hE.add(N);let D="TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.";process.emitWarning(D,"UnboundedCacheWarning",N,lt)}}d&&IE("stale","allowStale"),y&&IE("maxAge","ttl"),w&&IE("length","sizeCalculation")}getRemainingTTL(A){return this.has(A)?1/0:0}initializeTTLTracking(){this.ttls=new qi(this.max),this.starts=new qi(this.max),this.setItemTTL=(r,i)=>{if(this.starts[r]=i!==0?CE.now():0,this.ttls[r]=i,i!==0&&this.ttlAutopurge){let n=setTimeout(()=>{this.isStale(r)&&this.delete(this.keyList[r])},i+1);n.unref&&n.unref()}},this.updateItemAge=r=>{this.starts[r]=this.ttls[r]!==0?CE.now():0};let A=0,t=()=>{let r=CE.now();if(this.ttlResolution>0){A=r;let i=setTimeout(()=>A=0,this.ttlResolution);i.unref&&i.unref()}return r};this.getRemainingTTL=r=>{let i=this.keyMap.get(r);return i===void 0?0:this.ttls[i]===0||this.starts[i]===0?1/0:this.starts[i]+this.ttls[i]-(A||t())},this.isStale=r=>this.ttls[r]!==0&&this.starts[r]!==0&&(A||t())-this.starts[r]>this.ttls[r]}updateItemAge(A){}setItemTTL(A,t){}isStale(A){return!1}initializeSizeTracking(){this.calculatedSize=0,this.sizes=new qi(this.max),this.removeItemSize=A=>this.calculatedSize-=this.sizes[A],this.requireSize=(A,t,r,i)=>{if(!Yr(r))if(i){if(typeof i!="function")throw new TypeError("sizeCalculation must be a function");if(r=i(t,A),!Yr(r))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer)");return r},this.addItemSize=(A,t,r,i)=>{this.sizes[A]=i;let n=this.maxSize-this.sizes[A];for(;this.calculatedSize>n;)this.evict();this.calculatedSize+=this.sizes[A]},this.delete=A=>{if(this.size!==0){let t=this.keyMap.get(A);t!==void 0&&(this.calculatedSize-=this.sizes[t])}return lt.prototype.delete.call(this,A)}}removeItemSize(A){}addItemSize(A,t,r,i){}requireSize(A,t,r,i){if(r||i)throw new TypeError("cannot set size without setting maxSize on cache")}*indexes({allowStale:A=this.allowStale}={}){if(this.size)for(let t=this.tail;!(!this.isValidIndex(t)||((A||!this.isStale(t))&&(yield t),t===this.head));)t=this.prev[t]}*rindexes({allowStale:A=this.allowStale}={}){if(this.size)for(let t=this.head;!(!this.isValidIndex(t)||((A||!this.isStale(t))&&(yield t),t===this.tail));)t=this.next[t]}isValidIndex(A){return this.keyMap.get(this.keyList[A])===A}*entries(){for(let A of this.indexes())yield[this.keyList[A],this.valList[A]]}*rentries(){for(let A of this.rindexes())yield[this.keyList[A],this.valList[A]]}*keys(){for(let A of this.indexes())yield this.keyList[A]}*rkeys(){for(let A of this.rindexes())yield this.keyList[A]}*values(){for(let A of this.indexes())yield this.valList[A]}*rvalues(){for(let A of this.rindexes())yield this.valList[A]}[Symbol.iterator](){return this.entries()}find(A,t={}){for(let r of this.indexes())if(A(this.valList[r],this.keyList[r],this))return this.get(this.keyList[r],t)}forEach(A,t=this){for(let r of this.indexes())A.call(t,this.valList[r],this.keyList[r],this)}rforEach(A,t=this){for(let r of this.rindexes())A.call(t,this.valList[r],this.keyList[r],this)}get prune(){return QE("prune","purgeStale"),this.purgeStale}purgeStale(){let A=!1;for(let t of this.rindexes({allowStale:!0}))this.isStale(t)&&(this.delete(this.keyList[t]),A=!0);return A}dump(){let A=[];for(let t of this.indexes()){let r=this.keyList[t],n={value:this.valList[t]};this.ttls&&(n.ttl=this.ttls[t]),this.sizes&&(n.size=this.sizes[t]),A.unshift([r,n])}return A}load(A){this.clear();for(let[t,r]of A)this.set(t,r.value,r)}dispose(A,t,r){}set(A,t,{ttl:r=this.ttl,noDisposeOnSet:i=this.noDisposeOnSet,size:n=0,sizeCalculation:o=this.sizeCalculation,noUpdateTTL:g=this.noUpdateTTL}={}){n=this.requireSize(A,t,n,o);let c=this.size===0?void 0:this.keyMap.get(A);if(c===void 0)c=this.newIndex(),this.keyList[c]=A,this.valList[c]=t,this.keyMap.set(A,c),this.next[this.tail]=c,this.prev[c]=this.tail,this.tail=c,this.size++,this.addItemSize(c,t,A,n),g=!1;else{let E=this.valList[c];t!==E&&(this.isBackgroundFetch(E)?E.__abortController.abort():i||(this.dispose(E,A,"set"),this.disposeAfter&&this.disposed.push([E,A,"set"])),this.removeItemSize(c),this.valList[c]=t,this.addItemSize(c,t,A,n)),this.moveToTail(c)}if(r!==0&&this.ttl===0&&!this.ttls&&this.initializeTTLTracking(),g||this.setItemTTL(c,r),this.disposeAfter)for(;this.disposed.length;)this.disposeAfter(...this.disposed.shift());return this}newIndex(){return this.size===0?this.tail:this.size===this.max?this.evict():this.free.length!==0?this.free.pop():this.initialFill++}pop(){if(this.size){let A=this.valList[this.head];return this.evict(),A}}evict(){let A=this.head,t=this.keyList[A],r=this.valList[A];return this.isBackgroundFetch(r)?r.__abortController.abort():(this.dispose(r,t,"evict"),this.disposeAfter&&this.disposed.push([r,t,"evict"])),this.removeItemSize(A),this.head=this.next[A],this.keyMap.delete(t),this.size--,A}has(A){return this.keyMap.has(A)&&!this.isStale(this.keyMap.get(A))}peek(A,{allowStale:t=this.allowStale}={}){let r=this.keyMap.get(A);if(r!==void 0&&(t||!this.isStale(r)))return this.valList[r]}backgroundFetch(A,t,r){let i=t===void 0?void 0:this.valList[t];if(this.isBackgroundFetch(i))return i;let n=new hp,o={signal:n.signal,options:r},g=Promise.resolve(this.fetchMethod(A,i,o)).then(c=>(n.signal.aborted||this.set(A,c,o.options),c));return g.__abortController=n,g.__staleWhileFetching=i,t===void 0?(this.set(A,g,o.options),t=this.keyMap.get(A)):this.valList[t]=g,g}isBackgroundFetch(A){return A&&typeof A=="object"&&typeof A.then=="function"&&Object.prototype.hasOwnProperty.call(A,"__staleWhileFetching")}async fetch(A,{allowStale:t=this.allowStale,updateAgeOnGet:r=this.updateAgeOnGet,ttl:i=this.ttl,noDisposeOnSet:n=this.noDisposeOnSet,size:o=0,sizeCalculation:g=this.sizeCalculation,noUpdateTTL:c=this.noUpdateTTL}={}){if(!this.fetchMethod)return this.get(A,{allowStale:t,updateAgeOnGet:r});let E={allowStale:t,updateAgeOnGet:r,ttl:i,noDisposeOnSet:n,size:o,sizeCalculation:g,noUpdateTTL:c},C=this.keyMap.get(A);if(C===void 0)return this.backgroundFetch(A,C,E);{let I=this.valList[C];if(this.isBackgroundFetch(I))return t&&I.__staleWhileFetching!==void 0?I.__staleWhileFetching:I;if(!this.isStale(C))return this.moveToTail(C),r&&this.updateItemAge(C),I;let Q=this.backgroundFetch(A,C,E);return t&&Q.__staleWhileFetching!==void 0?Q.__staleWhileFetching:Q}}get(A,{allowStale:t=this.allowStale,updateAgeOnGet:r=this.updateAgeOnGet}={}){let i=this.keyMap.get(A);if(i!==void 0){let n=this.valList[i],o=this.isBackgroundFetch(n);return this.isStale(i)?o?t?n.__staleWhileFetching:void 0:(this.delete(A),t?n:void 0):o?void 0:(this.moveToTail(i),r&&this.updateItemAge(i),n)}}connect(A,t){this.prev[t]=A,this.next[A]=t}moveToTail(A){A!==this.tail&&(A===this.head?this.head=this.next[A]:this.connect(this.prev[A],this.next[A]),this.connect(this.tail,A),this.tail=A)}get del(){return QE("del","delete"),this.delete}delete(A){let t=!1;if(this.size!==0){let r=this.keyMap.get(A);if(r!==void 0)if(t=!0,this.size===1)this.clear();else{this.removeItemSize(r);let i=this.valList[r];this.isBackgroundFetch(i)?i.__abortController.abort():(this.dispose(i,A,"delete"),this.disposeAfter&&this.disposed.push([i,A,"delete"])),this.keyMap.delete(A),this.keyList[r]=null,this.valList[r]=null,r===this.tail?this.tail=this.prev[r]:r===this.head?this.head=this.next[r]:(this.next[this.prev[r]]=this.next[r],this.prev[this.next[r]]=this.prev[r]),this.size--,this.free.push(r)}}if(this.disposed)for(;this.disposed.length;)this.disposeAfter(...this.disposed.shift());return t}clear(){for(let A of this.rindexes({allowStale:!0})){let t=this.valList[A];if(this.isBackgroundFetch(t))t.__abortController.abort();else{let r=this.keyList[A];this.dispose(t,r,"delete"),this.disposeAfter&&this.disposed.push([t,r,"delete"])}}if(this.keyMap.clear(),this.valList.fill(null),this.keyList.fill(null),this.ttls&&(this.ttls.fill(0),this.starts.fill(0)),this.sizes&&this.sizes.fill(0),this.head=0,this.tail=0,this.initialFill=1,this.free.length=0,this.calculatedSize=0,this.size=0,this.disposed)for(;this.disposed.length;)this.disposeAfter(...this.disposed.shift())}get reset(){return QE("reset","clear"),this.clear}get length(){return TM("length","size"),this.size}};fp.exports=lt});var wp=p((q2,pp)=>{"use strict";var eA=(...e)=>e.every(A=>A)?e.join(""):"",UA=e=>e?encodeURIComponent(e):"",yp=e=>e.toLowerCase().replace(/^\W+|\/|\W+$/g,"").replace(/\W+/g,"-"),YM={sshtemplate:({domain:e,user:A,project:t,committish:r})=>`git@${e}:${A}/${t}.git${eA("#",r)}`,sshurltemplate:({domain:e,user:A,project:t,committish:r})=>`git+ssh://git@${e}/${A}/${t}.git${eA("#",r)}`,edittemplate:({domain:e,user:A,project:t,committish:r,editpath:i,path:n})=>`https://${e}/${A}/${t}${eA("/",i,"/",UA(r||"HEAD"),"/",n)}`,browsetemplate:({domain:e,user:A,project:t,committish:r,treepath:i})=>`https://${e}/${A}/${t}${eA("/",i,"/",UA(r))}`,browsetreetemplate:({domain:e,user:A,project:t,committish:r,treepath:i,path:n,fragment:o,hashformat:g})=>`https://${e}/${A}/${t}/${i}/${UA(r||"HEAD")}/${n}${eA("#",g(o||""))}`,browseblobtemplate:({domain:e,user:A,project:t,committish:r,blobpath:i,path:n,fragment:o,hashformat:g})=>`https://${e}/${A}/${t}/${i}/${UA(r||"HEAD")}/${n}${eA("#",g(o||""))}`,docstemplate:({domain:e,user:A,project:t,treepath:r,committish:i})=>`https://${e}/${A}/${t}${eA("/",r,"/",UA(i))}#readme`,httpstemplate:({auth:e,domain:A,user:t,project:r,committish:i})=>`git+https://${eA(e,"@")}${A}/${t}/${r}.git${eA("#",i)}`,filetemplate:({domain:e,user:A,project:t,committish:r,path:i})=>`https://${e}/${A}/${t}/raw/${UA(r||"HEAD")}/${i}`,shortcuttemplate:({type:e,user:A,project:t,committish:r})=>`${e}:${A}/${t}${eA("#",r)}`,pathtemplate:({user:e,project:A,committish:t})=>`${e}/${A}${eA("#",t)}`,bugstemplate:({domain:e,user:A,project:t})=>`https://${e}/${A}/${t}/issues`,hashformat:yp},jt={};jt.github={protocols:["git:","http:","git+ssh:","git+https:","ssh:","https:"],domain:"github.com",treepath:"tree",blobpath:"blob",editpath:"edit",filetemplate:({auth:e,user:A,project:t,committish:r,path:i})=>`https://${eA(e,"@")}raw.githubusercontent.com/${A}/${t}/${UA(r||"HEAD")}/${i}`,gittemplate:({auth:e,domain:A,user:t,project:r,committish:i})=>`git://${eA(e,"@")}${A}/${t}/${r}.git${eA("#",i)}`,tarballtemplate:({domain:e,user:A,project:t,committish:r})=>`https://codeload.${e}/${A}/${t}/tar.gz/${UA(r||"HEAD")}`,extract:e=>{let[,A,t,r,i]=e.pathname.split("/",5);if(!(r&&r!=="tree")&&(r||(i=e.hash.slice(1)),t&&t.endsWith(".git")&&(t=t.slice(0,-4)),!(!A||!t)))return{user:A,project:t,committish:i}}};jt.bitbucket={protocols:["git+ssh:","git+https:","ssh:","https:"],domain:"bitbucket.org",treepath:"src",blobpath:"src",editpath:"?mode=edit",edittemplate:({domain:e,user:A,project:t,committish:r,treepath:i,path:n,editpath:o})=>`https://${e}/${A}/${t}${eA("/",i,"/",UA(r||"HEAD"),"/",n,o)}`,tarballtemplate:({domain:e,user:A,project:t,committish:r})=>`https://${e}/${A}/${t}/get/${UA(r||"HEAD")}.tar.gz`,extract:e=>{let[,A,t,r]=e.pathname.split("/",4);if(!["get"].includes(r)&&(t&&t.endsWith(".git")&&(t=t.slice(0,-4)),!(!A||!t)))return{user:A,project:t,committish:e.hash.slice(1)}}};jt.gitlab={protocols:["git+ssh:","git+https:","ssh:","https:"],domain:"gitlab.com",treepath:"tree",blobpath:"tree",editpath:"-/edit",httpstemplate:({auth:e,domain:A,user:t,project:r,committish:i})=>`git+https://${eA(e,"@")}${A}/${t}/${r}.git${eA("#",i)}`,tarballtemplate:({domain:e,user:A,project:t,committish:r})=>`https://${e}/${A}/${t}/repository/archive.tar.gz?ref=${UA(r||"HEAD")}`,extract:e=>{let A=e.pathname.slice(1);if(A.includes("/-/")||A.includes("/archive.tar.gz"))return;let t=A.split("/"),r=t.pop();r.endsWith(".git")&&(r=r.slice(0,-4));let i=t.join("/");if(!(!i||!r))return{user:i,project:r,committish:e.hash.slice(1)}}};jt.gist={protocols:["git:","git+ssh:","git+https:","ssh:","https:"],domain:"gist.github.com",editpath:"edit",sshtemplate:({domain:e,project:A,committish:t})=>`git@${e}:${A}.git${eA("#",t)}`,sshurltemplate:({domain:e,project:A,committish:t})=>`git+ssh://git@${e}/${A}.git${eA("#",t)}`,edittemplate:({domain:e,user:A,project:t,committish:r,editpath:i})=>`https://${e}/${A}/${t}${eA("/",UA(r))}/${i}`,browsetemplate:({domain:e,project:A,committish:t})=>`https://${e}/${A}${eA("/",UA(t))}`,browsetreetemplate:({domain:e,project:A,committish:t,path:r,hashformat:i})=>`https://${e}/${A}${eA("/",UA(t))}${eA("#",i(r))}`,browseblobtemplate:({domain:e,project:A,committish:t,path:r,hashformat:i})=>`https://${e}/${A}${eA("/",UA(t))}${eA("#",i(r))}`,docstemplate:({domain:e,project:A,committish:t})=>`https://${e}/${A}${eA("/",UA(t))}`,httpstemplate:({domain:e,project:A,committish:t})=>`git+https://${e}/${A}.git${eA("#",t)}`,filetemplate:({user:e,project:A,committish:t,path:r})=>`https://gist.githubusercontent.com/${e}/${A}/raw${eA("/",UA(t))}/${r}`,shortcuttemplate:({type:e,project:A,committish:t})=>`${e}:${A}${eA("#",t)}`,pathtemplate:({project:e,committish:A})=>`${e}${eA("#",A)}`,bugstemplate:({domain:e,project:A})=>`https://${e}/${A}`,gittemplate:({domain:e,project:A,committish:t})=>`git://${e}/${A}.git${eA("#",t)}`,tarballtemplate:({project:e,committish:A})=>`https://codeload.github.com/gist/${e}/tar.gz/${UA(A||"HEAD")}`,extract:e=>{let[,A,t,r]=e.pathname.split("/",4);if(r!=="raw"){if(!t){if(!A)return;t=A,A=null}return t.endsWith(".git")&&(t=t.slice(0,-4)),{user:A,project:t,committish:e.hash.slice(1)}}},hashformat:function(e){return e&&"file-"+yp(e)}};jt.sourcehut={protocols:["git+ssh:","https:"],domain:"git.sr.ht",treepath:"tree",blobpath:"tree",filetemplate:({domain:e,user:A,project:t,committish:r,path:i})=>`https://${e}/${A}/${t}/blob/${UA(r)||"HEAD"}/${i}`,httpstemplate:({domain:e,user:A,project:t,committish:r})=>`https://${e}/${A}/${t}.git${eA("#",r)}`,tarballtemplate:({domain:e,user:A,project:t,committish:r})=>`https://${e}/${A}/${t}/archive/${UA(r)||"HEAD"}.tar.gz`,bugstemplate:({user:e,project:A})=>`https://todo.sr.ht/${e}/${A}`,extract:e=>{let[,A,t,r]=e.pathname.split("/",4);if(!["archive"].includes(r)&&(t&&t.endsWith(".git")&&(t=t.slice(0,-4)),!(!A||!t)))return{user:A,project:t,committish:e.hash.slice(1)}}};for(let[e,A]of Object.entries(jt))jt[e]=Object.assign({},YM,A);pp.exports=jt});var dE=p((T2,mp)=>{var JM=k("url"),fE=(e,A,t)=>{let r=e.indexOf(t);return e.lastIndexOf(A,r>-1?r:1/0)},Sp=e=>{try{return new JM.URL(e)}catch{}},GM=(e,A)=>{let t=e.indexOf(":"),r=e.slice(0,t+1);if(Object.prototype.hasOwnProperty.call(A,r))return e;let i=e.indexOf("@");return i>-1?i>t?`git+ssh://${e}`:e:e.indexOf("//")===t+1?e:`${e.slice(0,t+1)}//${e.slice(t+1)}`},HM=e=>{let A=fE(e,"@","#"),t=fE(e,":","#");return t>A&&(e=e.slice(0,t)+"/"+e.slice(t+1)),fE(e,":","#")===-1&&e.indexOf("//")===-1&&(e=`git+ssh://${e}`),e};mp.exports=(e,A)=>{let t=A?GM(e,A):e;return Sp(t)||Sp(HM(t))}});var bp=p((Y2,Dp)=>{"use strict";var KM=dE(),vM=e=>{let A=e.indexOf("#"),t=e.indexOf("/"),r=e.indexOf("/",t+1),i=e.indexOf(":"),n=/\s/.exec(e),o=e.indexOf("@"),g=!n||A>-1&&n.index>A,c=o===-1||A>-1&&o>A,E=i===-1||A>-1&&i>A,C=r===-1||A>-1&&r>A,I=t>0,Q=A>-1?e[A-1]!=="/":!e.endsWith("/"),B=!e.startsWith(".");return g&&I&&Q&&B&&c&&E&&C};Dp.exports=(e,A,{gitHosts:t,protocols:r})=>{var w,y;if(!e)return;let i=vM(e)?`github:${e}`:e,n=KM(i,r);if(!n)return;let o=t.byShortcut[n.protocol],g=t.byDomain[n.hostname.startsWith("www.")?n.hostname.slice(4):n.hostname],c=o||g;if(!c)return;let E=t[o||g],C=null;((w=r[n.protocol])==null?void 0:w.auth)&&(n.username||n.password)&&(C=`${n.username}${n.password?":"+n.password:""}`);let I=null,Q=null,B=null,u=null;try{if(o){let d=n.pathname.startsWith("/")?n.pathname.slice(1):n.pathname,m=d.indexOf("@");m>-1&&(d=d.slice(m+1));let N=d.lastIndexOf("/");N>-1?(Q=decodeURIComponent(d.slice(0,N)),Q||(Q=null),B=decodeURIComponent(d.slice(N+1))):B=decodeURIComponent(d),B.endsWith(".git")&&(B=B.slice(0,-4)),n.hash&&(I=decodeURIComponent(n.hash.slice(1))),u="shortcut"}else{if(!E.protocols.includes(n.protocol))return;let d=E.extract(n);if(!d)return;Q=d.user&&decodeURIComponent(d.user),B=decodeURIComponent(d.project),I=decodeURIComponent(d.committish),u=((y=r[n.protocol])==null?void 0:y.name)||n.protocol.slice(0,-1)}}catch(d){if(d instanceof URIError)return;throw d}return[c,Q,C,B,I,u,A]}});var Rp=p((J2,kp)=>{"use strict";var VM=dp(),xM=wp(),_M=bp(),WM=dE(),yE=new VM({max:1e3}),$t,ys,JA,ZA,Et=class{constructor(A,t,r,i,n,o,g={}){xA(this,JA);Object.assign(this,Z(Et,$t)[A],{type:A,user:t,auth:r,project:i,committish:n,default:o,opts:g})}static addHost(A,t){Z(Et,$t)[A]=t,Z(Et,$t).byDomain[t.domain]=A,Z(Et,$t).byShortcut[`${A}:`]=A,Z(Et,ys)[`${A}:`]={name:A}}static fromUrl(A,t){if(typeof A!="string")return;let r=A+JSON.stringify(t||{});if(!yE.has(r)){let i=_M(A,t,{gitHosts:Z(Et,$t),protocols:Z(Et,ys)});yE.set(r,i?new Et(...i):void 0)}return yE.get(r)}static parseUrl(A){return WM(A)}hash(){return this.committish?`#${this.committish}`:""}ssh(A){return _A(this,JA,ZA).call(this,this.sshtemplate,A)}sshurl(A){return _A(this,JA,ZA).call(this,this.sshurltemplate,A)}browse(A,...t){return typeof A!="string"?_A(this,JA,ZA).call(this,this.browsetemplate,A):typeof t[0]!="string"?_A(this,JA,ZA).call(this,this.browsetreetemplate,{...t[0],path:A}):_A(this,JA,ZA).call(this,this.browsetreetemplate,{...t[1],fragment:t[0],path:A})}browseFile(A,...t){return typeof t[0]!="string"?_A(this,JA,ZA).call(this,this.browseblobtemplate,{...t[0],path:A}):_A(this,JA,ZA).call(this,this.browseblobtemplate,{...t[1],fragment:t[0],path:A})}docs(A){return _A(this,JA,ZA).call(this,this.docstemplate,A)}bugs(A){return _A(this,JA,ZA).call(this,this.bugstemplate,A)}https(A){return _A(this,JA,ZA).call(this,this.httpstemplate,A)}git(A){return _A(this,JA,ZA).call(this,this.gittemplate,A)}shortcut(A){return _A(this,JA,ZA).call(this,this.shortcuttemplate,A)}path(A){return _A(this,JA,ZA).call(this,this.pathtemplate,A)}tarball(A){return _A(this,JA,ZA).call(this,this.tarballtemplate,{...A,noCommittish:!1})}file(A,t){return _A(this,JA,ZA).call(this,this.filetemplate,{...t,path:A})}edit(A,t){return _A(this,JA,ZA).call(this,this.edittemplate,{...t,path:A})}getDefaultRepresentation(){return this.default}toString(A){return this.default&&typeof this[this.default]=="function"?this[this.default](A):this.sshurl(A)}},Ti=Et;$t=new WeakMap,ys=new WeakMap,JA=new WeakSet,ZA=function(A,t){if(typeof A!="function")return null;let r={...this,...this.opts,...t};r.path||(r.path=""),r.path.startsWith("/")&&(r.path=r.path.slice(1)),r.noCommittish&&(r.committish=null);let i=A(r);return r.noGitPlus&&i.startsWith("git+")?i.slice(4):i},xA(Ti,$t,{byShortcut:{},byDomain:{}}),xA(Ti,ys,{"git+ssh:":{name:"sshurl"},"ssh:":{name:"sshurl"},"git+https:":{name:"https",auth:!0},"git:":{auth:!0},"http:":{auth:!0},"https:":{auth:!0},"git+http:":{auth:!0}});for(let[e,A]of Object.entries(xM))Ti.addHost(e,A);kp.exports=Ti});function hg({onlyFirst:e=!1}={}){let A=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(A,e?void 0:"g")}var na=ke(bl(),1);var ql=ke(_u(),1);var Wu=ql.default.HttpProxyAgent,Ou=ql.default.HttpsProxyAgent;var jn=class extends Map{constructor(A={}){if(super(),!(A.maxSize&&A.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");if(typeof A.maxAge=="number"&&A.maxAge===0)throw new TypeError("`maxAge` must be a number greater than 0");this.maxSize=A.maxSize,this.maxAge=A.maxAge||Number.POSITIVE_INFINITY,this.onEviction=A.onEviction,this.cache=new Map,this.oldCache=new Map,this._size=0}_emitEvictions(A){if(typeof this.onEviction=="function")for(let[t,r]of A)this.onEviction(t,r.value)}_deleteIfExpired(A,t){return typeof t.expiry=="number"&&t.expiry<=Date.now()?(typeof this.onEviction=="function"&&this.onEviction(A,t.value),this.delete(A)):!1}_getOrDeleteIfExpired(A,t){if(this._deleteIfExpired(A,t)===!1)return t.value}_getItemValue(A,t){return t.expiry?this._getOrDeleteIfExpired(A,t):t.value}_peek(A,t){let r=t.get(A);return this._getItemValue(A,r)}_set(A,t){this.cache.set(A,t),this._size++,this._size>=this.maxSize&&(this._size=0,this._emitEvictions(this.oldCache),this.oldCache=this.cache,this.cache=new Map)}_moveToRecent(A,t){this.oldCache.delete(A),this._set(A,t)}*_entriesAscending(){for(let A of this.oldCache){let[t,r]=A;this.cache.has(t)||this._deleteIfExpired(t,r)===!1&&(yield A)}for(let A of this.cache){let[t,r]=A;this._deleteIfExpired(t,r)===!1&&(yield A)}}get(A){if(this.cache.has(A)){let t=this.cache.get(A);return this._getItemValue(A,t)}if(this.oldCache.has(A)){let t=this.oldCache.get(A);if(this._deleteIfExpired(A,t)===!1)return this._moveToRecent(A,t),t.value}}set(A,t,{maxAge:r=this.maxAge}={}){let i=typeof r=="number"&&r!==Number.POSITIVE_INFINITY?Date.now()+r:void 0;this.cache.has(A)?this.cache.set(A,{value:t,expiry:i}):this._set(A,{value:t,expiry:i})}has(A){return this.cache.has(A)?!this._deleteIfExpired(A,this.cache.get(A)):this.oldCache.has(A)?!this._deleteIfExpired(A,this.oldCache.get(A)):!1}peek(A){if(this.cache.has(A))return this._peek(A,this.cache);if(this.oldCache.has(A))return this._peek(A,this.oldCache)}delete(A){let t=this.cache.delete(A);return t&&this._size--,this.oldCache.delete(A)||t}clear(){this.cache.clear(),this.oldCache.clear(),this._size=0}resize(A){if(!(A&&A>0))throw new TypeError("`maxSize` must be a number greater than 0");let t=[...this._entriesAscending()],r=t.length-A;r<0?(this.cache=new Map(t),this.oldCache=new Map,this._size=t.length):(r>0&&this._emitEvictions(t.slice(0,r)),this.oldCache=new Map(t.slice(r)),this.cache=new Map,this._size=0),this.maxSize=A}*keys(){for(let[A]of this)yield A}*values(){for(let[,A]of this)yield A}*[Symbol.iterator](){for(let A of this.cache){let[t,r]=A;this._deleteIfExpired(t,r)===!1&&(yield[t,r.value])}for(let A of this.oldCache){let[t,r]=A;this.cache.has(t)||this._deleteIfExpired(t,r)===!1&&(yield[t,r.value])}}*entriesDescending(){let A=[...this.cache];for(let t=A.length-1;t>=0;--t){let r=A[t],[i,n]=r;this._deleteIfExpired(i,n)===!1&&(yield[i,n.value])}A=[...this.oldCache];for(let t=A.length-1;t>=0;--t){let r=A[t],[i,n]=r;this.cache.has(i)||this._deleteIfExpired(i,n)===!1&&(yield[i,n.value])}}*entriesAscending(){for(let[A,t]of this._entriesAscending())yield[A,t.value]}get size(){if(!this._size)return this.oldCache.size;let A=0;for(let t of this.oldCache.keys())this.cache.has(t)||A++;return Math.min(this._size+A,this.maxSize)}entries(){return this.entriesAscending()}forEach(A,t=this){for(let[r,i]of this.entriesAscending())A.call(t,i,r,this)}get[Symbol.toStringTag](){return JSON.stringify([...this.entriesAscending()])}};var Xu=ke(zu(),1);import{Agent as WF}from"http";import{Agent as OF}from"https";var PF={agentCacheSize:512},Zu={maxSockets:64,keepAlive:!1},$n=class extends Error{constructor(A){super(A),this.name="TimeoutError",Error.captureStackTrace(this,$n)}};function Tl(e,A={}){if(!("undici"in A))throw new Error("The 'undici' option is required");let t={...PF,...A},r=new jn({maxSize:t.agentCacheSize});function i(o,g={}){let{origin:c,protocol:E}=new URL(o),C=g!=null&&g.noProxy?null:(0,Xu.getProxyForUrl)(o),I=JSON.stringify({proxyUrl:C,origin:c,...g});if(r.has(I))return r.get(I);let Q,B=E==="https:";if("noProxy"in g&&delete g.noProxy,A.undici){let u={...g};"keepAlive"in u&&!("pipelining"in u)&&(u.pipelining=u.keepAlive?1:0),"keepAlive"in u&&delete u.keepAlive,"maxSockets"in u&&(u.connections=u.maxSockets,delete u.maxSockets),C?Q=new na.ProxyAgent({...u,uri:C}):Q=new na.Agent(u)}else C?Q=new(B?Ou:Wu)({...g,proxy:C}):Q=new(B?OF:WF)(g);return r.set(I,Q),Q}let n=(o,{timeout:g=0,agentOpts:c={},...E}={})=>new Promise((C,I)=>{var u;if(!A.undici&&!("agent"in E)){let w=i(o,{...Zu,...c});w&&(E.agent=w)}else if(A.undici&&!("dispatcher"in E)){let w=i(o,{...Zu,...c});w&&(E.dispatcher=w)}let Q,B;g&&(!("signal"in E)&&globalThis.AbortController&&(B=new AbortController,E.signal=B.signal),Q=setTimeout(()=>{var y;(y=B==null?void 0:B.abort)==null||y.call(B);let w=new $n(`${E.method||"GET"} ${o} timed out after ${g}ms`);I(w)},g),(u=Q==null?void 0:Q.unref)==null||u.call(Q)),e(o,E).then(w=>{Q&&clearTimeout(Q),C(w)}).catch(w=>{if(Q&&clearTimeout(Q),w.name==="AbortError")return C(null);I(w)})});return n.clearCache=()=>{for(let o of r.values())"destroy"in o&&o.destroy();r.clear()},n}var Yp=ke(Yl(),1);import pL from"http";import wL from"https";import Di from"zlib";import Yf,{PassThrough as Jf,pipeline as bi}from"stream";import{Buffer as ha}from"buffer";function ZF(e){if(!/^data:/i.test(e))throw new TypeError('`uri` does not appear to be a Data URI (must begin with "data:")');e=e.replace(/\r?\n/g,"");let A=e.indexOf(",");if(A===-1||A<=4)throw new TypeError("malformed data: URI");let t=e.substring(5,A).split(";"),r="",i=!1,n=t[0]||"text/plain",o=n;for(let C=1;C<t.length;C++)t[C]==="base64"?i=!0:(o+=`;${t[C]}`,t[C].indexOf("charset=")===0&&(r=t[C].substring(8)));!t[0]&&!r.length&&(o+=";charset=US-ASCII",r="US-ASCII");let g=i?"base64":"ascii",c=unescape(e.substring(A+1)),E=Buffer.from(c,g);return E.type=n,E.typeFull=o,E.charset=r,E}var ef=ZF;es();aa();import Zt,{PassThrough as wf}from"stream";import{types as Sf,deprecate as Wl,promisify as CL}from"util";import{Buffer as Ke}from"buffer";var kt=class extends Error{constructor(A,t){super(A),Error.captureStackTrace(this,this.constructor),this.type=t}get name(){return this.constructor.name}get[Symbol.toStringTag](){return this.constructor.name}};var Ie=class extends kt{constructor(A,t,r){super(A,t),r&&(this.code=this.errno=r.code,this.erroredSysCall=r.syscall)}};var ga=Symbol.toStringTag,Kl=e=>typeof e=="object"&&typeof e.append=="function"&&typeof e.delete=="function"&&typeof e.get=="function"&&typeof e.getAll=="function"&&typeof e.has=="function"&&typeof e.set=="function"&&typeof e.sort=="function"&&e[ga]==="URLSearchParams",ns=e=>e&&typeof e=="object"&&typeof e.arrayBuffer=="function"&&typeof e.type=="string"&&typeof e.stream=="function"&&typeof e.constructor=="function"&&/^(Blob|File)$/.test(e[ga]),Cf=e=>typeof e=="object"&&(e[ga]==="AbortSignal"||e[ga]==="EventTarget"),If=(e,A)=>{let t=new URL(A).hostname,r=new URL(e).hostname;return t===r||t.endsWith(`.${r}`)},Qf=(e,A)=>{let t=new URL(A).protocol,r=new URL(e).protocol;return t===r};var IL=CL(Zt.pipeline),Qe=Symbol("Body internals"),ct=class{constructor(A,{size:t=0}={}){let r=null;A===null?A=null:Kl(A)?A=Ke.from(A.toString()):ns(A)||Ke.isBuffer(A)||(Sf.isAnyArrayBuffer(A)?A=Ke.from(A):ArrayBuffer.isView(A)?A=Ke.from(A.buffer,A.byteOffset,A.byteLength):A instanceof Zt||(A instanceof Dr?(A=Ef(A),r=A.type.split("=")[1]):A=Ke.from(String(A))));let i=A;Ke.isBuffer(A)?i=Zt.Readable.from(A):ns(A)&&(i=Zt.Readable.from(A.stream())),this[Qe]={body:A,stream:i,boundary:r,disturbed:!1,error:null},this.size=t,A instanceof Zt&&A.on("error",n=>{let o=n instanceof kt?n:new Ie(`Invalid response body while trying to fetch ${this.url}: ${n.message}`,"system",n);this[Qe].error=o})}get body(){return this[Qe].stream}get bodyUsed(){return this[Qe].disturbed}async arrayBuffer(){let{buffer:A,byteOffset:t,byteLength:r}=await _l(this);return A.slice(t,t+r)}async formData(){let A=this.headers.get("content-type");if(A.startsWith("application/x-www-form-urlencoded")){let r=new Dr,i=new URLSearchParams(await this.text());for(let[n,o]of i)r.append(n,o);return r}let{toFormData:t}=await Promise.resolve().then(()=>(pf(),yf));return t(this.body,A)}async blob(){let A=this.headers&&this.headers.get("content-type")||this[Qe].body&&this[Qe].body.type||"",t=await this.arrayBuffer();return new bt([t],{type:A})}async json(){let A=await this.text();return JSON.parse(A)}async text(){let A=await _l(this);return new TextDecoder().decode(A)}buffer(){return _l(this)}};ct.prototype.buffer=Wl(ct.prototype.buffer,"Please use 'response.arrayBuffer()' instead of 'response.buffer()'","node-fetch#buffer");Object.defineProperties(ct.prototype,{body:{enumerable:!0},bodyUsed:{enumerable:!0},arrayBuffer:{enumerable:!0},blob:{enumerable:!0},json:{enumerable:!0},text:{enumerable:!0},data:{get:Wl(()=>{},"data doesn't exist, use json(), text(), arrayBuffer(), or body instead","https://github.com/node-fetch/node-fetch/issues/1000 (response)")}});async function _l(e){if(e[Qe].disturbed)throw new TypeError(`body used already for: ${e.url}`);if(e[Qe].disturbed=!0,e[Qe].error)throw e[Qe].error;let{body:A}=e;if(A===null)return Ke.alloc(0);if(!(A instanceof Zt))return Ke.alloc(0);let t=[],r=0;try{for await(let i of A){if(e.size>0&&r+i.length>e.size){let n=new Ie(`content size at ${e.url} over limit: ${e.size}`,"max-size");throw A.destroy(n),n}r+=i.length,t.push(i)}}catch(i){throw i instanceof kt?i:new Ie(`Invalid response body while trying to fetch ${e.url}: ${i.message}`,"system",i)}if(A.readableEnded===!0||A._readableState.ended===!0)try{return t.every(i=>typeof i=="string")?Ke.from(t.join("")):Ke.concat(t,r)}catch(i){throw new Ie(`Could not create Buffer from response body for ${e.url}: ${i.message}`,"system",i)}else throw new Ie(`Premature close of server response while trying to fetch ${e.url}`)}var Si=(e,A)=>{let t,r,{body:i}=e[Qe];if(e.bodyUsed)throw new Error("cannot clone body after it is used");return i instanceof Zt&&typeof i.getBoundary!="function"&&(t=new wf({highWaterMark:A}),r=new wf({highWaterMark:A}),i.pipe(t),i.pipe(r),e[Qe].stream=t,i=r),i},QL=Wl(e=>e.getBoundary(),"form-data doesn't follow the spec and requires special treatment. Use alternative package","https://github.com/node-fetch/node-fetch/issues/1167"),Ea=(e,A)=>e===null?null:typeof e=="string"?"text/plain;charset=UTF-8":Kl(e)?"application/x-www-form-urlencoded;charset=UTF-8":ns(e)?e.type||null:Ke.isBuffer(e)||Sf.isAnyArrayBuffer(e)||ArrayBuffer.isView(e)?null:e instanceof Dr?`multipart/form-data; boundary=${A[Qe].boundary}`:e&&typeof e.getBoundary=="function"?`multipart/form-data;boundary=${QL(e)}`:e instanceof Zt?null:"text/plain;charset=UTF-8",mf=e=>{let{body:A}=e[Qe];return A===null?0:ns(A)?A.size:Ke.isBuffer(A)?A.length:A&&typeof A.getLengthSync=="function"&&A.hasKnownLength&&A.hasKnownLength()?A.getLengthSync():null},Df=async(e,{body:A})=>{A===null?e.end():await IL(A,e)};import{types as bf}from"util";import Ia from"http";var Ca=typeof Ia.validateHeaderName=="function"?Ia.validateHeaderName:e=>{if(!/^[\^`\-\w!#$%&'*+.|~]+$/.test(e)){let A=new TypeError(`Header name must be a valid HTTP token [${e}]`);throw Object.defineProperty(A,"code",{value:"ERR_INVALID_HTTP_TOKEN"}),A}},Ol=typeof Ia.validateHeaderValue=="function"?Ia.validateHeaderValue:(e,A)=>{if(/[^\t\u0020-\u007E\u0080-\u00FF]/.test(A)){let t=new TypeError(`Invalid character in header content ["${e}"]`);throw Object.defineProperty(t,"code",{value:"ERR_INVALID_CHAR"}),t}},ne=class extends URLSearchParams{constructor(A){let t=[];if(A instanceof ne){let r=A.raw();for(let[i,n]of Object.entries(r))t.push(...n.map(o=>[i,o]))}else if(A!=null)if(typeof A=="object"&&!bf.isBoxedPrimitive(A)){let r=A[Symbol.iterator];if(r==null)t.push(...Object.entries(A));else{if(typeof r!="function")throw new TypeError("Header pairs must be iterable");t=[...A].map(i=>{if(typeof i!="object"||bf.isBoxedPrimitive(i))throw new TypeError("Each header pair must be an iterable object");return[...i]}).map(i=>{if(i.length!==2)throw new TypeError("Each header pair must be a name/value tuple");return[...i]})}}else throw new TypeError("Failed to construct 'Headers': The provided value is not of type '(sequence<sequence<ByteString>> or record<ByteString, ByteString>)");return t=t.length>0?t.map(([r,i])=>(Ca(r),Ol(r,String(i)),[String(r).toLowerCase(),String(i)])):void 0,super(t),new Proxy(this,{get(r,i,n){switch(i){case"append":case"set":return(o,g)=>(Ca(o),Ol(o,String(g)),URLSearchParams.prototype[i].call(r,String(o).toLowerCase(),String(g)));case"delete":case"has":case"getAll":return o=>(Ca(o),URLSearchParams.prototype[i].call(r,String(o).toLowerCase()));case"keys":return()=>(r.sort(),new Set(URLSearchParams.prototype.keys.call(r)).keys());default:return Reflect.get(r,i,n)}}})}get[Symbol.toStringTag](){return this.constructor.name}toString(){return Object.prototype.toString.call(this)}get(A){let t=this.getAll(A);if(t.length===0)return null;let r=t.join(", ");return/^content-encoding$/i.test(A)&&(r=r.toLowerCase()),r}forEach(A,t=void 0){for(let r of this.keys())Reflect.apply(A,t,[this.get(r),r,this])}*values(){for(let A of this.keys())yield this.get(A)}*entries(){for(let A of this.keys())yield[A,this.get(A)]}[Symbol.iterator](){return this.entries()}raw(){return[...this.keys()].reduce((A,t)=>(A[t]=this.getAll(t),A),{})}[Symbol.for("nodejs.util.inspect.custom")](){return[...this.keys()].reduce((A,t)=>{let r=this.getAll(t);return t==="host"?A[t]=r[0]:A[t]=r.length>1?r:r[0],A},{})}};Object.defineProperties(ne.prototype,["get","entries","forEach","values"].reduce((e,A)=>(e[A]={enumerable:!0},e),{}));function kf(e=[]){return new ne(e.reduce((A,t,r,i)=>(r%2===0&&A.push(i.slice(r,r+2)),A),[]).filter(([A,t])=>{try{return Ca(A),Ol(A,String(t)),!0}catch{return!1}}))}var BL=new Set([301,302,303,307,308]),Qa=e=>BL.has(e);var Ze=Symbol("Response internals"),zA=class extends ct{constructor(A=null,t={}){super(A,t);let r=t.status!=null?t.status:200,i=new ne(t.headers);if(A!==null&&!i.has("Content-Type")){let n=Ea(A,this);n&&i.append("Content-Type",n)}this[Ze]={type:"default",url:t.url,status:r,statusText:t.statusText||"",headers:i,counter:t.counter,highWaterMark:t.highWaterMark}}get type(){return this[Ze].type}get url(){return this[Ze].url||""}get status(){return this[Ze].status}get ok(){return this[Ze].status>=200&&this[Ze].status<300}get redirected(){return this[Ze].counter>0}get statusText(){return this[Ze].statusText}get headers(){return this[Ze].headers}get highWaterMark(){return this[Ze].highWaterMark}clone(){return new zA(Si(this,this.highWaterMark),{type:this.type,url:this.url,status:this.status,statusText:this.statusText,headers:this.headers,ok:this.ok,redirected:this.redirected,size:this.size,highWaterMark:this.highWaterMark})}static redirect(A,t=302){if(!Qa(t))throw new RangeError('Failed to execute "redirect" on "response": Invalid status code');return new zA(null,{headers:{location:new URL(A).toString()},status:t})}static error(){let A=new zA(null,{status:0,statusText:""});return A[Ze].type="error",A}static json(A=void 0,t={}){let r=JSON.stringify(A);if(r===void 0)throw new TypeError("data is not JSON serializable");let i=new ne(t&&t.headers);return i.has("content-type")||i.set("content-type","application/json"),new zA(r,{...t,headers:i})}get[Symbol.toStringTag](){return"Response"}};Object.defineProperties(zA.prototype,{type:{enumerable:!0},url:{enumerable:!0},status:{enumerable:!0},ok:{enumerable:!0},redirected:{enumerable:!0},statusText:{enumerable:!0},headers:{enumerable:!0},clone:{enumerable:!0}});import{format as fL}from"url";import{deprecate as dL}from"util";var Rf=e=>{if(e.search)return e.search;let A=e.href.length-1,t=e.hash||(e.href[A]==="#"?"#":"");return e.href[A-t.length]==="?"?"?":""};import{isIP as hL}from"net";function Nf(e,A=!1){return e==null||(e=new URL(e),/^(about|blob|data):$/.test(e.protocol))?"no-referrer":(e.username="",e.password="",e.hash="",A&&(e.pathname="",e.search=""),e)}var Ff=new Set(["","no-referrer","no-referrer-when-downgrade","same-origin","origin","strict-origin","origin-when-cross-origin","strict-origin-when-cross-origin","unsafe-url"]),Lf="strict-origin-when-cross-origin";function Uf(e){if(!Ff.has(e))throw new TypeError(`Invalid referrerPolicy: ${e}`);return e}function uL(e){if(/^(http|ws)s:$/.test(e.protocol))return!0;let A=e.host.replace(/(^\[)|(]$)/g,""),t=hL(A);return t===4&&/^127\./.test(A)||t===6&&/^(((0+:){7})|(::(0+:){0,6}))0*1$/.test(A)?!0:e.host==="localhost"||e.host.endsWith(".localhost")?!1:e.protocol==="file:"}function mi(e){return/^about:(blank|srcdoc)$/.test(e)||e.protocol==="data:"||/^(blob|filesystem):$/.test(e.protocol)?!0:uL(e)}function Mf(e,{referrerURLCallback:A,referrerOriginCallback:t}={}){if(e.referrer==="no-referrer"||e.referrerPolicy==="")return null;let r=e.referrerPolicy;if(e.referrer==="about:client")return"no-referrer";let i=e.referrer,n=Nf(i),o=Nf(i,!0);n.toString().length>4096&&(n=o),A&&(n=A(n)),t&&(o=t(o));let g=new URL(e.url);switch(r){case"no-referrer":return"no-referrer";case"origin":return o;case"unsafe-url":return n;case"strict-origin":return mi(n)&&!mi(g)?"no-referrer":o.toString();case"strict-origin-when-cross-origin":return n.origin===g.origin?n:mi(n)&&!mi(g)?"no-referrer":o;case"same-origin":return n.origin===g.origin?n:"no-referrer";case"origin-when-cross-origin":return n.origin===g.origin?n:o;case"no-referrer-when-downgrade":return mi(n)&&!mi(g)?"no-referrer":n;default:throw new TypeError(`Invalid referrerPolicy: ${r}`)}}function qf(e){let A=(e.get("referrer-policy")||"").split(/[,\s]+/),t="";for(let r of A)r&&Ff.has(r)&&(t=r);return t}var vA=Symbol("Request internals"),os=e=>typeof e=="object"&&typeof e[vA]=="object",yL=dL(()=>{},".data is not a valid RequestInit property, use .body instead","https://github.com/node-fetch/node-fetch/issues/1000 (request)"),Rt=class extends ct{constructor(A,t={}){let r;if(os(A)?r=new URL(A.url):(r=new URL(A),A={}),r.username!==""||r.password!=="")throw new TypeError(`${r} is an url with embedded credentials.`);let i=t.method||A.method||"GET";if(/^(delete|get|head|options|post|put)$/i.test(i)&&(i=i.toUpperCase()),!os(t)&&"data"in t&&yL(),(t.body!=null||os(A)&&A.body!==null)&&(i==="GET"||i==="HEAD"))throw new TypeError("Request with GET/HEAD method cannot have body");let n=t.body?t.body:os(A)&&A.body!==null?Si(A):null;super(n,{size:t.size||A.size||0});let o=new ne(t.headers||A.headers||{});if(n!==null&&!o.has("Content-Type")){let E=Ea(n,this);E&&o.set("Content-Type",E)}let g=os(A)?A.signal:null;if("signal"in t&&(g=t.signal),g!=null&&!Cf(g))throw new TypeError("Expected signal to be an instanceof AbortSignal or EventTarget");let c=t.referrer==null?A.referrer:t.referrer;if(c==="")c="no-referrer";else if(c){let E=new URL(c);c=/^about:(\/\/)?client$/.test(E)?"client":E}else c=void 0;this[vA]={method:i,redirect:t.redirect||A.redirect||"follow",headers:o,parsedURL:r,signal:g,referrer:c},this.follow=t.follow===void 0?A.follow===void 0?20:A.follow:t.follow,this.compress=t.compress===void 0?A.compress===void 0?!0:A.compress:t.compress,this.counter=t.counter||A.counter||0,this.agent=t.agent||A.agent,this.highWaterMark=t.highWaterMark||A.highWaterMark||16384,this.insecureHTTPParser=t.insecureHTTPParser||A.insecureHTTPParser||!1,this.referrerPolicy=t.referrerPolicy||A.referrerPolicy||""}get method(){return this[vA].method}get url(){return fL(this[vA].parsedURL)}get headers(){return this[vA].headers}get redirect(){return this[vA].redirect}get signal(){return this[vA].signal}get referrer(){if(this[vA].referrer==="no-referrer")return"";if(this[vA].referrer==="client")return"about:client";if(this[vA].referrer)return this[vA].referrer.toString()}get referrerPolicy(){return this[vA].referrerPolicy}set referrerPolicy(A){this[vA].referrerPolicy=Uf(A)}clone(){return new Rt(this)}get[Symbol.toStringTag](){return"Request"}};Object.defineProperties(Rt.prototype,{method:{enumerable:!0},url:{enumerable:!0},headers:{enumerable:!0},redirect:{enumerable:!0},clone:{enumerable:!0},signal:{enumerable:!0},referrer:{enumerable:!0},referrerPolicy:{enumerable:!0}});var Tf=e=>{let{parsedURL:A}=e[vA],t=new ne(e[vA].headers);t.has("Accept")||t.set("Accept","*/*");let r=null;if(e.body===null&&/^(post|put)$/i.test(e.method)&&(r="0"),e.body!==null){let g=mf(e);typeof g=="number"&&!Number.isNaN(g)&&(r=String(g))}r&&t.set("Content-Length",r),e.referrerPolicy===""&&(e.referrerPolicy=Lf),e.referrer&&e.referrer!=="no-referrer"?e[vA].referrer=Mf(e):e[vA].referrer="no-referrer",e[vA].referrer instanceof URL&&t.set("Referer",e.referrer),t.has("User-Agent")||t.set("User-Agent","node-fetch"),e.compress&&!t.has("Accept-Encoding")&&t.set("Accept-Encoding","gzip, deflate, br");let{agent:i}=e;typeof i=="function"&&(i=i(A)),!t.has("Connection")&&!i&&t.set("Connection","close");let n=Rf(A),o={path:A.pathname+n,method:e.method,headers:t[Symbol.for("nodejs.util.inspect.custom")](),insecureHTTPParser:e.insecureHTTPParser,agent:i};return{parsedURL:A,options:o}};var Ba=class extends kt{constructor(A,t="aborted"){super(A,t)}};aa();Vl();var SL=new Set(["data:","http:","https:"]);async function ua(e,A){return new Promise((t,r)=>{let i=new Rt(e,A),{parsedURL:n,options:o}=Tf(i);if(!SL.has(n.protocol))throw new TypeError(`node-fetch cannot load ${e}. URL scheme "${n.protocol.replace(/:$/,"")}" is not supported.`);if(n.protocol==="data:"){let u=ef(i.url),w=new zA(u,{headers:{"Content-Type":u.typeFull}});t(w);return}let g=(n.protocol==="https:"?wL:pL).request,{signal:c}=i,E=null,C=()=>{let u=new Ba("The operation was aborted.");r(u),i.body&&i.body instanceof Yf.Readable&&i.body.destroy(u),!(!E||!E.body)&&E.body.emit("error",u)};if(c&&c.aborted){C();return}let I=()=>{C(),B()},Q=g(n.toString(),o);c&&c.addEventListener("abort",I);let B=()=>{Q.abort(),c&&c.removeEventListener("abort",I)};Q.on("error",u=>{r(new Ie(`request to ${i.url} failed, reason: ${u.message}`,"system",u)),B()}),mL(Q,u=>{E&&E.body&&E.body.destroy(u)}),process.version<"v14"&&Q.on("socket",u=>{let w;u.prependListener("end",()=>{w=u._eventsCount}),u.prependListener("close",y=>{if(E&&w<u._eventsCount&&!y){let d=new Error("Premature close");d.code="ERR_STREAM_PREMATURE_CLOSE",E.body.emit("error",d)}})}),Q.on("response",u=>{Q.setTimeout(0);let w=kf(u.rawHeaders);if(Qa(u.statusCode)){let D=w.get("Location"),Y=null;try{Y=D===null?null:new URL(D,i.url)}catch{if(i.redirect!=="manual"){r(new Ie(`uri requested responds with an invalid redirect URL: ${D}`,"invalid-redirect")),B();return}}switch(i.redirect){case"error":r(new Ie(`uri requested responds with a redirect, redirect mode is set to error: ${i.url}`,"no-redirect")),B();return;case"manual":break;case"follow":{if(Y===null)break;if(i.counter>=i.follow){r(new Ie(`maximum redirect reached at: ${i.url}`,"max-redirect")),B();return}let J={headers:new ne(i.headers),follow:i.follow,counter:i.counter+1,agent:i.agent,compress:i.compress,method:i.method,body:Si(i),signal:i.signal,size:i.size,referrer:i.referrer,referrerPolicy:i.referrerPolicy};if(!If(i.url,Y)||!Qf(i.url,Y))for(let V of["authorization","www-authenticate","cookie","cookie2"])J.headers.delete(V);if(u.statusCode!==303&&i.body&&A.body instanceof Yf.Readable){r(new Ie("Cannot follow redirect with body being a readable stream","unsupported-redirect")),B();return}(u.statusCode===303||(u.statusCode===301||u.statusCode===302)&&i.method==="POST")&&(J.method="GET",J.body=void 0,J.headers.delete("content-length"));let T=qf(w);T&&(J.referrerPolicy=T),t(ua(new Rt(Y,J))),B();return}default:return r(new TypeError(`Redirect option '${i.redirect}' is not a valid value of RequestRedirect`))}}c&&u.once("end",()=>{c.removeEventListener("abort",I)});let y=bi(u,new Jf,D=>{D&&r(D)});process.version<"v12.10"&&u.on("aborted",I);let d={url:i.url,status:u.statusCode,statusText:u.statusMessage,headers:w,size:i.size,counter:i.counter,highWaterMark:i.highWaterMark},m=w.get("Content-Encoding");if(!i.compress||i.method==="HEAD"||m===null||u.statusCode===204||u.statusCode===304){E=new zA(y,d),t(E);return}let N={flush:Di.Z_SYNC_FLUSH,finishFlush:Di.Z_SYNC_FLUSH};if(m==="gzip"||m==="x-gzip"){y=bi(y,Di.createGunzip(N),D=>{D&&r(D)}),E=new zA(y,d),t(E);return}if(m==="deflate"||m==="x-deflate"){let D=bi(u,new Jf,Y=>{Y&&r(Y)});D.once("data",Y=>{(Y[0]&15)===8?y=bi(y,Di.createInflate(),J=>{J&&r(J)}):y=bi(y,Di.createInflateRaw(),J=>{J&&r(J)}),E=new zA(y,d),t(E)}),D.once("end",()=>{E||(E=new zA(y,d),t(E))});return}if(m==="br"){y=bi(y,Di.createBrotliDecompress(),D=>{D&&r(D)}),E=new zA(y,d),t(E);return}E=new zA(y,d),t(E)}),Df(Q,i).catch(r)})}function mL(e,A){let t=ha.from(`0\r
67
67
  \r
68
68
  `),r=!1,i=!1,n;e.on("response",o=>{let{headers:g}=o;r=g["transfer-encoding"]==="chunked"&&!g["content-length"]}),e.on("socket",o=>{let g=()=>{if(r&&!i){let E=new Error("Premature close");E.code="ERR_STREAM_PREMATURE_CLOSE",A(E)}},c=E=>{i=ha.compare(E.slice(-5),t)===0,!i&&n&&(i=ha.compare(n.slice(-3),t.slice(0,3))===0&&ha.compare(E.slice(-2),t.slice(3))===0),n=E};o.prependListener("close",g),o.on("data",c),e.on("close",()=>{o.removeListener("close",g),o.removeListener("data",c)})})}var Jp=ke(Ed(),1),Gp=ke(da(),1),Hp=ke(Id(),1),MA=ke(lp(),1),Kp=ke(Bp(),1),vp=ke(Rp(),1);import{cwd as PM,stdout as zM,argv as ZM,env as XM,exit as ps}from"process";import{join as Vp,dirname as jM}from"path";import{lstatSync as $M,readFileSync as Np,truncateSync as Aq,writeFileSync as eq,accessSync as tq}from"fs";import{platform as rq}from"os";import{rootCertificates as Fp}from"tls";var OM=[[1e3,6e4,"sec"],[6e4,36e5,"min"],[36e5,864e5,"hour"],[864e5,6048e5,"day"],[6048e5,2628e6,"week"],[2628e6,31536e6,"month"],[31536e6,1/0,"year"]];function pE(e,{noAffix:A=!1,times:t=OM,nowThreshold:r=1e4,nowString:i="now"}={}){let n=Date.now();if(e=typeof e=="number"?e:Date.parse(e),Number.isNaN(e))return"unknown";let o=!1,g=n-e;if(g<0&&(o=!0,g=Math.abs(g)),g<r)return i;let c,E;for(let C=0,I=t.length;C<I;C++){let Q=t[C];if(!(g>=Q[1])){c=Math.floor(g/Q[0]),E=Q[2]+(c>1?"s":"");break}}return`${o&&!A?"in ":""}${c} ${E}${!o&&!A?" ago":""}`}var{fromUrl:iq}=vp.default,DE=Tl(ua,{undici:!1}),xp=96,Ar="\0",nq=/^.*?:\/\/(.*?@)?(github\.com[:/])/i,sq=/^([^/]+)\/([^/#]+)?.*?\/([0-9a-f]+|v?[0-9]+\.[0-9]+\.[0-9]+)$/i,bE=/^[0-9a-f]{7,}$/i,Lp=/[0-9]+(\.[0-9]+)?(\.[0-9]+)?/g,Up=e=>e.replace(/[|\\{}()[\]^$+*?.-]/g,"\\$&"),oq=Ga(iq),Ta=Ga(Jp.default),aq=Ga(Hp.default),RE=Ga(e=>e.endsWith("/")?e.substring(0,e.length-1):e),gq=new Set(["patch"]),cq=new Set(["patch","minor"]),lq=new Set(["patch","minor","major"]),O=(0,Yp.default)(ZM.slice(2),{boolean:["E","error-on-outdated","U","error-on-unchanged","h","help","j","json","n","no-color","u","update","v","version","V","verbose"],string:["d","allow-downgrade","f","file","g","greatest","G","githubapi","m","minor","P","patch","p","prerelease","R","release","r","registry","t","types"],alias:{d:"allow-downgrade",E:"error-on-outdated",U:"error-on-unchanged",e:"exclude",f:"file",g:"greatest",G:"githubapi",h:"help",i:"include",j:"json",m:"minor",n:"no-color",P:"patch",p:"prerelease",r:"registry",R:"release",s:"semver",S:"sockets",t:"types",u:"update",v:"version",V:"verbose"}}),kE,Ja,ws;O.color===!1||XM.TERM==="dumb"?kE=Ja=ws=e=>e:(kE=e=>`\x1B[35m${e}\x1B[0m`,Ja=e=>`\x1B[31m${e}\x1B[0m`,ws=e=>`\x1B[32m${e}\x1B[0m`);var Yi=Ki(O.greatest),wE=Ki(O.prerelease),SE=Ki(O.release),Ji=Ki(O.patch),Gi=Ki(O.minor),Hi=Ki(O["allow-downgrade"]),Ct=(0,Gp.default)("npm",{registry:"https://registry.npmjs.org"}),Ya={npmrc:Ct,recursive:!0},Eq=RE(O.registry||Ct.registry),Mp=O.githubapi?RE(O.githubapi):"https://api.github.com",Cq=typeof O.sockets=="number"?parseInt(O.sockets):xp,qp=e=>Array.from(e.matchAll(/(----BEGIN CERT[^]+?IFICATE----)/g)).map(A=>A[0]);function Ga(e){let A=Object.create(null);return(t,r)=>t in A?A[t]:A[t]=e(t,r)}function _p(e,A,t){let r=Vp(A,e);try{return tq(r),r}catch{}let i=jM(A);return t&&r===t||i===A?null:_p(e,i,t)}function Iq(e,A){if(e.startsWith("@")){let t=(/@[a-z0-9][\w-.]+/.exec(e)||[])[0],r=RE(aq(t,Ct));if(r!==A)try{let i=Ta(r,Ya);if(i!=null&&i.token)return[i,r]}catch{return[Ta(A,Ya),A]}else return[Ta(A,Ya),A]}else return[Ta(A,Ya),A]}async function Qq(e,A,t,r){let[i,n]=Iq(e,t),o={maxSockets:Cq};Object.keys(r).length&&(o.agentOpts=r),i!=null&&i.token&&(o.headers={Authorization:`${i.type} ${i.token}`});let c=(A==="resolutions"?mq(e):e).replace(/\//g,"%2f"),E=`${n}/${c}`;O.verbose&&console.error(`${kE("fetch")} ${E}`);let C=await DE(E,o);if(C!=null&&C.ok)return O.verbose&&console.error(`${ws("done")} ${E}`),[await C.json(),A,n,e];throw(C==null?void 0:C.status)&&(C==null?void 0:C.statusText)?new Error(`Received ${C.status} ${C.statusText} for ${e} from ${n}`):new Error(`Unable to fetch ${e} from ${n}`)}function Bq({repository:e,homepage:A},t,r){let i;if(t==="https://npm.pkg.github.com")return`https://github.com/${r.replace(/^@/,"")}`;if(e){let o=typeof e=="string"?e:e.url,g=oq(o);g!=null&&g.browse&&(i=g.browse()),i&&e.directory&&g.treepath&&(i=`${i}/${g.treepath}/HEAD/${e.directory}`),!i&&(e==null?void 0:e.url)&&/^https?:/.test(e.url)&&(i=e.url)}let n=i||A||"";if(n){let o=new URL(n);o.protocol==="http:"&&o.hostname==="github.com"&&(o.protocol="https:",n=String(o))}return n}function xe(e,A={}){let t={},r=e instanceof Error;typeof e=="string"?t.message=e:r&&(t.error=e.message);for(let i of Object.values(A))"oldPrint"in i&&(i.old=i.oldPrint,delete i.oldPrint),"newPrint"in i&&(i.new=i.newPrint,delete i.newPrint),"oldOriginal"in i&&(i.old=i.oldOriginal,delete i.oldOriginal);if(O.json){if(!r){t.results={};for(let[i,n]of Object.entries(A)){let[o,g]=i.split(Ar);t.results[o]||(t.results[o]={}),t.results[o][g]=n}}console.info(JSON.stringify(t))}else Object.keys(A).length&&!r&&console.info(uq(A)),(t.message||t.error)&&(t.message?console.info(t.message):t.error&&console.info(Ja(t.error)));O["error-on-outdated"]?ps(Object.keys(A).length?2:0):O["error-on-unchanged"]?ps(Object.keys(A).length?0:2):ps(t.error?1:0)}function hq(e,A){let t=rq()==="win32";t&&Aq(e,0),eq(e,A,t?{flag:"r+"}:void 0)}function Tp(e,A,t){let r=e.split(/\./),i=A.split(/\./),n=t?ws:Ja,o=/^[0-9a-zA-Z-.]+$/,g="";for(let c=0;c<r.length;c++)if(r[c]!==i[c]){o.test(r[c])?g+=n(r.slice(c).join(".")):g+=r[c].split("").map(E=>o.test(E)?n(E):E).join("")+n(`.${r.slice(c+1).join(".")}`);break}else g+=`${r[c]}.`;return g}function uq(e){let A=[["NAME","OLD","NEW","AGE","INFO"]];for(let[t,r]of Object.entries(e)){let[i,n]=t.split(Ar);A.push([n,Tp(r.old,r.new,!1),Tp(r.new,r.old,!0),r.age||"",r.info])}return(0,Kp.default)(A,{hsep:" ",stringLength:t=>t.replace(hg(),"").length})}function fq(e,A){let t=e;for(let r of Object.keys(A)){let i=r.split(Ar)[1],n=A[r].oldOriginal||A[r].old,o=new RegExp(`"${Up(i)}": +"${Up(n)}"`,"g");t=t.replace(o,`"${i}": "${A[r].new}"`)}return t}function dq(e,A){return e.replace(/[0-9]+\.[0-9]+\.[0-9]+(-.+)?/g,A)}function mE(e){let A=MA.default.parse(e);return A?Boolean(A.prerelease.length):!1}function Wp(e){return/[0-9]+\.[0-9]+\.[0-9]+-.+/.test(e)}function yq(e){try{return MA.default.coerce(e).version}catch{return null}}function pq(e,A,{range:t,semvers:r,usePre:i,useRel:n,useGreatest:o}={}){let g=yq(t),c=0;r=new Set(r),i=Wp(t)||i,i&&(r.add("prerelease"),r.has("patch")&&r.add("prepatch"),r.has("minor")&&r.add("preminor"),r.has("major")&&r.add("premajor"));for(let E of A){let C=MA.default.parse(E);if(C.prerelease.length&&(!i||n))continue;let I=MA.default.diff(g,C.version);if(!(!I||!r.has(I)))if(o||!("time"in e))MA.default.gte(MA.default.coerce(C.version).version,g)&&(g=C.version);else{let Q=new Date(e.time[E]).getTime();Q>=0&&Q>c&&(g=C.version,c=Q)}}return g||null}function wq(e,A){var i;if(A.range==="*"||A.range.includes("||"))return null;let t=Object.keys(e.versions).filter(n=>MA.default.valid(n)),r=pq(e,t,A);if(A.useGreatest)return r;{let n=e["dist-tags"].latest,o=MA.default.coerce(A.range).version,g=Wp(A.range),c=mE(r),E=mE(n),C=MA.default.gt(r,o);if(!A.useRel&&A.usePre||g&&c||A.useRel&&!C&&g&&!c||g&&!c&&C)return r;if(g&&!c&&!C)return null;let I=MA.default.diff(o,n);return I&&I!=="prerelease"&&!A.semvers.has(I.replace(/^pre/,""))||A.useRel&&mE(n)?r:MA.default.lt(n,o)&&!E?Hi===!0||((i=Hi==null?void 0:Hi.has)==null?void 0:i.call(Hi,e.name))?n:null:n}}async function Sq([e,A],{useGreatest:t}={}){var c,E;let r=A.old.replace(nq,""),[i,n,o,g]=sq.exec(r)||[];if(!(!n||!o||!g))if(bE.test(g)){let C=await DE(`${Mp}/repos/${n}/${o}/commits`);if(!C||!C.ok)return;let I=await C.json(),{sha:Q,commit:B}=I[0];if(!Q||!Q.length)return;let u=((c=B==null?void 0:B.committer)==null?void 0:c.date)??((E=B==null?void 0:B.author)==null?void 0:E.date);if(Q=Q.substring(0,g.length),g!==Q){let w=A.old.replace(g,Q);return{key:e,newRange:w,user:n,repo:o,oldRef:g,newRef:Q,newDate:u}}}else{let C=await DE(`${Mp}/repos/${n}/${o}/git/refs/tags`);if(!C||!C.ok)return;let Q=(await C.json()).map(u=>u.ref.replace(/^refs\/tags\//,"")),B=g.replace(/^v/,"");if(!MA.default.valid(B))return;if(t){let u=g,w=g.replace(/^v/,"");for(let y of Q){let d=y.replace(/^v/,"");!MA.default.valid(d)||(!u||MA.default.gt(d,w))&&(u=y,w=d)}if(MA.default.neq(B,w))return{key:e,newRange:u,user:n,repo:o,oldRef:g,newRef:u}}else{let u=Q[Q.length-1],w=u.replace(/^v/,"");if(!MA.default.valid(w))return;if(MA.default.neq(B,w))return{key:e,newRange:u,user:n,repo:o,oldRef:g,newRef:u}}}}function mq(e){let A=e.match(/(@[^/]+\/)?([^/]+)/g)||[];return A[A.length-1]}function Dq(e){let A=e.match(Lp);return A.length!==1?e:e.replace(Lp,MA.default.coerce(A[0]))}function Ki(e){return e===void 0?!1:e===""?!0:typeof e=="string"?e.includes(",")?new Set(e.split(",")):new Set([e]):Array.isArray(e)?new Set(e):!1}async function bq(){var I,Q,B,u,w;for(let y of[process.stdout,process.stderr])(Q=(I=y==null?void 0:y._handle)==null?void 0:I.setBlocking)==null||Q.call(I,!0);O.help&&(zM.write(`usage: updates [options]
69
69
 
@@ -95,4 +95,4 @@ Content-Type: ${n.type||"application/octet-stream"}\r
95
95
  $ updates -u
96
96
  $ updates -u -m -e eslint
97
97
  $ updates -u -U && rm -rf node_modules && npm i
98
- `),ps(0)),O.version&&(console.info("13.2.3"),ps(0));let e={};if(Ct["strict-ssl"]===!1)e.rejectUnauthorized=!1;else if("cafile"in Ct&&(e.ca=Fp.concat(qp(Np(Ct.cafile,"utf8")))),"ca"in Ct){let y=Array.isArray(Ct.ca)?Ct.ca:[Ct.ca];e.ca=Fp.concat(y.map(d=>qp(d)))}let A;if(O.file){let y;try{y=$M(O.file)}catch(d){xe(new Error(`Unable to open ${O.file}: ${d.message}`))}y!=null&&y.isFile()?A=O.file:y!=null&&y.isDirectory()?A=Vp(O.file,"package.json"):xe(new Error(`${O.file} is neither a file nor directory`))}else{let y=PM();A=_p("package.json",y),A||xe(new Error(`Unable to find package.json in ${y} or any of its parents`))}let t;O.types?t=Array.isArray(O.types)?O.types:O.types.split(","):t=["dependencies","devDependencies","optionalDependencies","peerDependencies","resolutions"];let r,i;try{i=Np(A,"utf8")}catch(y){xe(new Error(`Unable to open ${A}: ${y.message}`))}try{r=JSON.parse(i)}catch(y){xe(new Error(`Error parsing ${A}: ${y.message}`))}let n,o;O.include&&O.include!==!0&&(n=new Set((Array.isArray(O.include)?O.include:[O.include]).flatMap(y=>y.split(",")))),O.exclude&&O.exclude!==!0&&(o=new Set((Array.isArray(O.exclude)?O.exclude:[O.exclude]).flatMap(y=>y.split(","))));function g(y){var d,m;return!(((d=o==null?void 0:o.has)==null?void 0:d.call(o,y))===!0||((m=n==null?void 0:n.has)==null?void 0:m.call(n,y))===!1)}let c={},E={};for(let y of t)for(let[d,m]of Object.entries(r[y]||{}))MA.default.validRange(m)&&g(d)?c[`${y}${Ar}${d}`]={old:Dq(m),oldOriginal:m}:g(d)&&(E[`${y}${Ar}${d}`]={old:m});!Object.keys(c).length&&!Object.keys(E).length&&xe(n||o?new Error("No dependencies match the given include/exclude filters"):"No dependencies present, nothing to do");let C=await Promise.all(Object.keys(c).map(y=>{let[d,m]=y.split(Ar);return Qq(m,d,Eq,e)}));for(let[y,d,m,N]of C){if(y!=null&&y.error)throw new Error(y.error);let D=typeof Yi=="boolean"?Yi:Yi.has(y.name),Y=typeof wE=="boolean"?wE:wE.has(y.name),J=typeof SE=="boolean"?SE:SE.has(y.name),T;Ji===!0||((B=Ji==null?void 0:Ji.has)==null?void 0:B.call(Ji,y.name))?T=gq:Gi===!0||((u=Gi==null?void 0:Gi.has)==null?void 0:u.call(Gi,y.name))?T=cq:T=lq;let V=`${d}${Ar}${N}`,P=c[V].old,ae=wq(y,{usePre:Y,useRel:J,useGreatest:D,semvers:T,range:P}),QA=dq(P,ae);!ae||P===QA?delete c[V]:(c[V].new=QA,c[V].info=Bq(y.versions[ae]||y,m,y.name),(w=y.time)!=null&&w[ae]&&(c[V].age=pE(y.time[ae],{noAffix:!0})))}if(Object.keys(E).length){let y=await Promise.all(Object.entries(E).map(([d,m])=>{let N=d.split(Ar)[1],D=typeof Yi=="boolean"?Yi:Yi.has(N);return Sq([d,m],{useGreatest:D})}));y=y.filter(Boolean);for(let d of y||[]){let{key:m,newRange:N,user:D,repo:Y,oldRef:J,newRef:T,newDate:V}=d;c[m]={old:E[m].old,new:N,oldPrint:bE.test(J)?J.substring(0,7):J,newPrint:bE.test(T)?T.substring(0,7):T,info:`https://github.com/${D}/${Y}`,...V?{age:pE(V,{noAffix:!0})}:{}}}}Object.keys(c).length||xe("All dependencies are up to date."),O.update||xe(void 0,c);try{hq(A,fq(i,c))}catch(y){xe(new Error(`Error writing ${A}: ${y.message}`))}xe(ws("\u2728 package.json updated"),c)}bq().catch(xe);
98
+ `),ps(0)),O.version&&(console.info("13.2.4"),ps(0));let e={};if(Ct["strict-ssl"]===!1)e.rejectUnauthorized=!1;else if("cafile"in Ct&&(e.ca=Fp.concat(qp(Np(Ct.cafile,"utf8")))),"ca"in Ct){let y=Array.isArray(Ct.ca)?Ct.ca:[Ct.ca];e.ca=Fp.concat(y.map(d=>qp(d)))}let A;if(O.file){let y;try{y=$M(O.file)}catch(d){xe(new Error(`Unable to open ${O.file}: ${d.message}`))}y!=null&&y.isFile()?A=O.file:y!=null&&y.isDirectory()?A=Vp(O.file,"package.json"):xe(new Error(`${O.file} is neither a file nor directory`))}else{let y=PM();A=_p("package.json",y),A||xe(new Error(`Unable to find package.json in ${y} or any of its parents`))}let t;O.types?t=Array.isArray(O.types)?O.types:O.types.split(","):t=["dependencies","devDependencies","optionalDependencies","peerDependencies","resolutions"];let r,i;try{i=Np(A,"utf8")}catch(y){xe(new Error(`Unable to open ${A}: ${y.message}`))}try{r=JSON.parse(i)}catch(y){xe(new Error(`Error parsing ${A}: ${y.message}`))}let n,o;O.include&&O.include!==!0&&(n=new Set((Array.isArray(O.include)?O.include:[O.include]).flatMap(y=>y.split(",")))),O.exclude&&O.exclude!==!0&&(o=new Set((Array.isArray(O.exclude)?O.exclude:[O.exclude]).flatMap(y=>y.split(","))));function g(y){var d,m;return!(((d=o==null?void 0:o.has)==null?void 0:d.call(o,y))===!0||((m=n==null?void 0:n.has)==null?void 0:m.call(n,y))===!1)}let c={},E={};for(let y of t)for(let[d,m]of Object.entries(r[y]||{}))MA.default.validRange(m)&&g(d)?c[`${y}${Ar}${d}`]={old:Dq(m),oldOriginal:m}:g(d)&&(E[`${y}${Ar}${d}`]={old:m});!Object.keys(c).length&&!Object.keys(E).length&&xe(n||o?new Error("No dependencies match the given include/exclude filters"):"No dependencies present, nothing to do");let C=await Promise.all(Object.keys(c).map(y=>{let[d,m]=y.split(Ar);return Qq(m,d,Eq,e)}));for(let[y,d,m,N]of C){if(y!=null&&y.error)throw new Error(y.error);let D=typeof Yi=="boolean"?Yi:Yi.has(y.name),Y=typeof wE=="boolean"?wE:wE.has(y.name),J=typeof SE=="boolean"?SE:SE.has(y.name),T;Ji===!0||((B=Ji==null?void 0:Ji.has)==null?void 0:B.call(Ji,y.name))?T=gq:Gi===!0||((u=Gi==null?void 0:Gi.has)==null?void 0:u.call(Gi,y.name))?T=cq:T=lq;let V=`${d}${Ar}${N}`,P=c[V].old,ae=wq(y,{usePre:Y,useRel:J,useGreatest:D,semvers:T,range:P}),QA=dq(P,ae);!ae||P===QA?delete c[V]:(c[V].new=QA,c[V].info=Bq(y.versions[ae]||y,m,y.name),(w=y.time)!=null&&w[ae]&&(c[V].age=pE(y.time[ae],{noAffix:!0})))}if(Object.keys(E).length){let y=await Promise.all(Object.entries(E).map(([d,m])=>{let N=d.split(Ar)[1],D=typeof Yi=="boolean"?Yi:Yi.has(N);return Sq([d,m],{useGreatest:D})}));y=y.filter(Boolean);for(let d of y||[]){let{key:m,newRange:N,user:D,repo:Y,oldRef:J,newRef:T,newDate:V}=d;c[m]={old:E[m].old,new:N,oldPrint:bE.test(J)?J.substring(0,7):J,newPrint:bE.test(T)?T.substring(0,7):T,info:`https://github.com/${D}/${Y}`,...V?{age:pE(V,{noAffix:!0})}:{}}}}Object.keys(c).length||xe("All dependencies are up to date."),O.update||xe(void 0,c);try{hq(A,fq(i,c))}catch(y){xe(new Error(`Error writing ${A}: ${y.message}`))}xe(ws("\u2728 package.json updated"),c)}bq().catch(xe);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "updates",
3
- "version": "13.2.3",
3
+ "version": "13.2.4",
4
4
  "description": "Flexible npm dependency update tool",
5
5
  "author": "silverwind",
6
6
  "repository": "silverwind/updates",
@@ -10,26 +10,16 @@
10
10
  "engines": {
11
11
  "node": ">= 14"
12
12
  },
13
- "keywords": [
14
- "dependencies",
15
- "update",
16
- "updates",
17
- "check",
18
- "checker",
19
- "npm",
20
- "yarn",
21
- "packages"
22
- ],
23
13
  "files": [
24
14
  "./bin/updates.js"
25
15
  ],
26
16
  "devDependencies": {
27
17
  "ansi-regex": "6.0.1",
28
- "esbuild": "0.15.16",
29
- "eslint": "8.28.0",
30
- "eslint-config-silverwind": "64.0.1",
18
+ "esbuild": "0.16.3",
19
+ "eslint": "8.29.0",
20
+ "eslint-config-silverwind": "64.0.2",
31
21
  "execa": "6.1.0",
32
- "fetch-enhanced": "11.0.0",
22
+ "fetch-enhanced": "11.0.3",
33
23
  "hosted-git-info": "6.1.1",
34
24
  "minimist": "1.2.7",
35
25
  "node-fetch": "3.3.0",
@@ -40,6 +30,6 @@
40
30
  "text-table": "0.2.0",
41
31
  "timerel": "5.3.0",
42
32
  "versions": "10.4.0",
43
- "vitest": "0.25.3"
33
+ "vitest": "0.25.6"
44
34
  }
45
35
  }