@vercel/build-utils 14.13.1 → 14.13.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @vercel/build-utils
2
2
 
3
+ ## 14.13.2
4
+
5
+ ### Patch Changes
6
+
7
+ - ff3d2f7: Allow projects to temporarily extend Node.js 20 support through November 1, 2026.
8
+
3
9
  ## 14.13.1
4
10
 
5
11
  ### Patch Changes
@@ -115,6 +115,14 @@ function getNodeVersionByMajor(major) {
115
115
  return getOptions().find((v) => v.major === major);
116
116
  }
117
117
  function getOptions() {
118
+ if (process.env.VERCEL_ALLOW_DISCONTINUED_NODEJS20 === "1") {
119
+ return NODE_VERSIONS.map(
120
+ (version) => version.major === 20 ? new import_types.NodeVersion({
121
+ ...version,
122
+ discontinueDate: /* @__PURE__ */ new Date("2026-11-01")
123
+ }) : version
124
+ );
125
+ }
118
126
  return NODE_VERSIONS;
119
127
  }
120
128
  function isNodeVersionAvailable(version) {
package/dist/index.js CHANGED
@@ -12,7 +12,7 @@ globstar while`,file,fr,pattern,pr,swallowee),this.matchOne(file.slice(fr),patte
12
12
  >>> no match, partial?`,file,fr,pattern,pr),fr===fl))}var hit;if(typeof p=="string"?(hit=f===p,this.debug("string match",p,f,hit)):(hit=f.match(p),this.debug("pattern match",p,f,hit)),!hit)return!1}if(fi===fl&&pi===pl)return!0;if(fi===fl)return partial;if(pi===pl)return fi===fl-1&&file[fi]==="";throw new Error("wtf?")}braceExpand(){return braceExpand(this.pattern,this.options)}parse(pattern,isSub){assertValidPattern(pattern);let options=this.options;if(pattern==="**")if(options.noglobstar)pattern="*";else return GLOBSTAR;if(pattern==="")return"";let re="",hasMagic=!!options.nocase,escaping=!1,patternListStack=[],negativeLists=[],stateChar,inClass=!1,reClassStart=-1,classStart=-1,cs,pl,sp,patternStart=pattern.charAt(0)==="."?"":options.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",clearStateChar=()=>{if(stateChar){switch(stateChar){case"*":re+=star,hasMagic=!0;break;case"?":re+=qmark,hasMagic=!0;break;default:re+="\\"+stateChar;break}this.debug("clearStateChar %j %j",stateChar,re),stateChar=!1}};for(let i=0,c;i<pattern.length&&(c=pattern.charAt(i));i++){if(this.debug("%s %s %s %j",pattern,i,re,c),escaping){if(c==="/")return!1;reSpecials[c]&&(re+="\\"),re+=c,escaping=!1;continue}switch(c){case"/":return!1;case"\\":clearStateChar(),escaping=!0;continue;case"?":case"*":case"+":case"@":case"!":if(this.debug("%s %s %s %j <-- stateChar",pattern,i,re,c),inClass){this.debug(" in class"),c==="!"&&i===classStart+1&&(c="^"),re+=c;continue}this.debug("call clearStateChar %j",stateChar),clearStateChar(),stateChar=c,options.noext&&clearStateChar();continue;case"(":if(inClass){re+="(";continue}if(!stateChar){re+="\\(";continue}patternListStack.push({type:stateChar,start:i-1,reStart:re.length,open:plTypes[stateChar].open,close:plTypes[stateChar].close}),re+=stateChar==="!"?"(?:(?!(?:":"(?:",this.debug("plType %j %j",stateChar,re),stateChar=!1;continue;case")":if(inClass||!patternListStack.length){re+="\\)";continue}clearStateChar(),hasMagic=!0,pl=patternListStack.pop(),re+=pl.close,pl.type==="!"&&negativeLists.push(pl),pl.reEnd=re.length;continue;case"|":if(inClass||!patternListStack.length){re+="\\|";continue}clearStateChar(),re+="|";continue;case"[":if(clearStateChar(),inClass){re+="\\"+c;continue}inClass=!0,classStart=i,reClassStart=re.length,re+=c;continue;case"]":if(i===classStart+1||!inClass){re+="\\"+c;continue}cs=pattern.substring(classStart+1,i);try{RegExp("["+cs+"]")}catch{sp=this.parse(cs,SUBPARSE),re=re.substr(0,reClassStart)+"\\["+sp[0]+"\\]",hasMagic=hasMagic||sp[1],inClass=!1;continue}hasMagic=!0,inClass=!1,re+=c;continue;default:clearStateChar(),reSpecials[c]&&!(c==="^"&&inClass)&&(re+="\\"),re+=c;break}}for(inClass&&(cs=pattern.substr(classStart+1),sp=this.parse(cs,SUBPARSE),re=re.substr(0,reClassStart)+"\\["+sp[0],hasMagic=hasMagic||sp[1]),pl=patternListStack.pop();pl;pl=patternListStack.pop()){let tail;tail=re.slice(pl.reStart+pl.open.length),this.debug("setting tail",re,pl),tail=tail.replace(/((?:\\{2}){0,64})(\\?)\|/g,(_,$1,$2)=>($2||($2="\\"),$1+$1+$2+"|")),this.debug(`tail=%j
13
13
  %s`,tail,tail,pl,re);let t=pl.type==="*"?star:pl.type==="?"?qmark:"\\"+pl.type;hasMagic=!0,re=re.slice(0,pl.reStart)+t+"\\("+tail}clearStateChar(),escaping&&(re+="\\\\");let addPatternStart=addPatternStartSet[re.charAt(0)];for(let n=negativeLists.length-1;n>-1;n--){let nl=negativeLists[n],nlBefore=re.slice(0,nl.reStart),nlFirst=re.slice(nl.reStart,nl.reEnd-8),nlAfter=re.slice(nl.reEnd),nlLast=re.slice(nl.reEnd-8,nl.reEnd)+nlAfter,openParensBefore=nlBefore.split("(").length-1,cleanAfter=nlAfter;for(let i=0;i<openParensBefore;i++)cleanAfter=cleanAfter.replace(/\)[+*?]?/,"");nlAfter=cleanAfter;let dollar=nlAfter===""&&isSub!==SUBPARSE?"$":"";re=nlBefore+nlFirst+nlAfter+dollar+nlLast}if(re!==""&&hasMagic&&(re="(?=.)"+re),addPatternStart&&(re=patternStart+re),isSub===SUBPARSE)return[re,hasMagic];if(!hasMagic)return globUnescape(pattern);let flags=options.nocase?"i":"";try{return Object.assign(new RegExp("^"+re+"$",flags),{_glob:pattern,_src:re})}catch{return new RegExp("$.")}}makeRe(){if(this.regexp||this.regexp===!1)return this.regexp;let set=this.set;if(!set.length)return this.regexp=!1,this.regexp;let options=this.options,twoStar=options.noglobstar?star:options.dot?twoStarDot:twoStarNoDot,flags=options.nocase?"i":"",re=set.map(pattern=>(pattern=pattern.map(p=>typeof p=="string"?regExpEscape(p):p===GLOBSTAR?GLOBSTAR:p._src).reduce((set2,p)=>(set2[set2.length-1]===GLOBSTAR&&p===GLOBSTAR||set2.push(p),set2),[]),pattern.forEach((p,i)=>{p!==GLOBSTAR||pattern[i-1]===GLOBSTAR||(i===0?pattern.length>1?pattern[i+1]="(?:\\/|"+twoStar+"\\/)?"+pattern[i+1]:pattern[i]=twoStar:i===pattern.length-1?pattern[i-1]+="(?:\\/|"+twoStar+")?":(pattern[i-1]+="(?:\\/|\\/"+twoStar+"\\/)"+pattern[i+1],pattern[i+1]=GLOBSTAR))}),pattern.filter(p=>p!==GLOBSTAR).join("/"))).join("|");re="^(?:"+re+")$",this.negate&&(re="^(?!"+re+").*$");try{this.regexp=new RegExp(re,flags)}catch{this.regexp=!1}return this.regexp}match(f,partial=this.partial){if(this.debug("match",f,this.pattern),this.comment)return!1;if(this.empty)return f==="";if(f==="/"&&partial)return!0;let options=this.options;path9.sep!=="/"&&(f=f.split(path9.sep).join("/")),f=f.split(slashSplit),this.debug(this.pattern,"split",f);let set=this.set;this.debug(this.pattern,"set",set);let filename;for(let i=f.length-1;i>=0&&(filename=f[i],!filename);i--);for(let i=0;i<set.length;i++){let pattern=set[i],file=f;if(options.matchBase&&pattern.length===1&&(file=[filename]),this.matchOne(file,pattern,partial))return options.flipNegate?!0:!this.negate}return options.flipNegate?!1:this.negate}static defaults(def){return minimatch3.defaults(def).Minimatch}};minimatch3.Minimatch=Minimatch}});var require_common=__commonJS({"../../node_modules/.pnpm/glob@8.0.3/node_modules/glob/common.js"(exports2){exports2.setopts=setopts;exports2.ownProp=ownProp;exports2.makeAbs=makeAbs;exports2.finish=finish;exports2.mark=mark;exports2.isIgnored=isIgnored;exports2.childrenIgnored=childrenIgnored;function ownProp(obj,field){return Object.prototype.hasOwnProperty.call(obj,field)}var fs12=require("fs"),path9=require("path"),minimatch3=require_minimatch2(),isAbsolute=require("path").isAbsolute,Minimatch=minimatch3.Minimatch;function alphasort(a,b){return a.localeCompare(b,"en")}function setupIgnores(self2,options){self2.ignore=options.ignore||[],Array.isArray(self2.ignore)||(self2.ignore=[self2.ignore]),self2.ignore.length&&(self2.ignore=self2.ignore.map(ignoreMap))}function ignoreMap(pattern){var gmatcher=null;if(pattern.slice(-3)==="/**"){var gpattern=pattern.replace(/(\/\*\*)+$/,"");gmatcher=new Minimatch(gpattern,{dot:!0})}return{matcher:new Minimatch(pattern,{dot:!0}),gmatcher}}function setopts(self2,pattern,options){if(options||(options={}),options.matchBase&&pattern.indexOf("/")===-1){if(options.noglobstar)throw new Error("base matching requires globstar");pattern="**/"+pattern}self2.silent=!!options.silent,self2.pattern=pattern,self2.strict=options.strict!==!1,self2.realpath=!!options.realpath,self2.realpathCache=options.realpathCache||Object.create(null),self2.follow=!!options.follow,self2.dot=!!options.dot,self2.mark=!!options.mark,self2.nodir=!!options.nodir,self2.nodir&&(self2.mark=!0),self2.sync=!!options.sync,self2.nounique=!!options.nounique,self2.nonull=!!options.nonull,self2.nosort=!!options.nosort,self2.nocase=!!options.nocase,self2.stat=!!options.stat,self2.noprocess=!!options.noprocess,self2.absolute=!!options.absolute,self2.fs=options.fs||fs12,self2.maxLength=options.maxLength||1/0,self2.cache=options.cache||Object.create(null),self2.statCache=options.statCache||Object.create(null),self2.symlinks=options.symlinks||Object.create(null),setupIgnores(self2,options),self2.changedCwd=!1;var cwd=process.cwd();ownProp(options,"cwd")?(self2.cwd=path9.resolve(options.cwd),self2.changedCwd=self2.cwd!==cwd):self2.cwd=path9.resolve(cwd),self2.root=options.root||path9.resolve(self2.cwd,"/"),self2.root=path9.resolve(self2.root),self2.cwdAbs=isAbsolute(self2.cwd)?self2.cwd:makeAbs(self2,self2.cwd),self2.nomount=!!options.nomount,process.platform==="win32"&&(self2.root=self2.root.replace(/\\/g,"/"),self2.cwd=self2.cwd.replace(/\\/g,"/"),self2.cwdAbs=self2.cwdAbs.replace(/\\/g,"/")),options.nonegate=!0,options.nocomment=!0,options.allowWindowsEscape=!0,self2.minimatch=new Minimatch(pattern,options),self2.options=self2.minimatch.options}function finish(self2){for(var nou=self2.nounique,all=nou?[]:Object.create(null),i=0,l=self2.matches.length;i<l;i++){var matches=self2.matches[i];if(!matches||Object.keys(matches).length===0){if(self2.nonull){var literal=self2.minimatch.globSet[i];nou?all.push(literal):all[literal]=!0}}else{var m=Object.keys(matches);nou?all.push.apply(all,m):m.forEach(function(m2){all[m2]=!0})}}if(nou||(all=Object.keys(all)),self2.nosort||(all=all.sort(alphasort)),self2.mark){for(var i=0;i<all.length;i++)all[i]=self2._mark(all[i]);self2.nodir&&(all=all.filter(function(e){var notDir=!/\/$/.test(e),c=self2.cache[e]||self2.cache[makeAbs(self2,e)];return notDir&&c&&(notDir=c!=="DIR"&&!Array.isArray(c)),notDir}))}self2.ignore.length&&(all=all.filter(function(m2){return!isIgnored(self2,m2)})),self2.found=all}function mark(self2,p){var abs=makeAbs(self2,p),c=self2.cache[abs],m=p;if(c){var isDir=c==="DIR"||Array.isArray(c),slash=p.slice(-1)==="/";if(isDir&&!slash?m+="/":!isDir&&slash&&(m=m.slice(0,-1)),m!==p){var mabs=makeAbs(self2,m);self2.statCache[mabs]=self2.statCache[abs],self2.cache[mabs]=self2.cache[abs]}}return m}function makeAbs(self2,f){var abs=f;return f.charAt(0)==="/"?abs=path9.join(self2.root,f):isAbsolute(f)||f===""?abs=f:self2.changedCwd?abs=path9.resolve(self2.cwd,f):abs=path9.resolve(f),process.platform==="win32"&&(abs=abs.replace(/\\/g,"/")),abs}function isIgnored(self2,path10){return self2.ignore.length?self2.ignore.some(function(item){return item.matcher.match(path10)||!!(item.gmatcher&&item.gmatcher.match(path10))}):!1}function childrenIgnored(self2,path10){return self2.ignore.length?self2.ignore.some(function(item){return!!(item.gmatcher&&item.gmatcher.match(path10))}):!1}}});var require_sync=__commonJS({"../../node_modules/.pnpm/glob@8.0.3/node_modules/glob/sync.js"(exports2,module2){module2.exports=globSync;globSync.GlobSync=GlobSync;var rp=require_fs2(),minimatch3=require_minimatch2(),Minimatch=minimatch3.Minimatch,Glob=require_glob().Glob,util=require("util"),path9=require("path"),assert9=require("assert"),isAbsolute=require("path").isAbsolute,common=require_common(),setopts=common.setopts,ownProp=common.ownProp,childrenIgnored=common.childrenIgnored,isIgnored=common.isIgnored;function globSync(pattern,options){if(typeof options=="function"||arguments.length===3)throw new TypeError(`callback provided to sync glob
14
14
  See: https://github.com/isaacs/node-glob/issues/167`);return new GlobSync(pattern,options).found}function GlobSync(pattern,options){if(!pattern)throw new Error("must provide pattern");if(typeof options=="function"||arguments.length===3)throw new TypeError(`callback provided to sync glob
15
- See: https://github.com/isaacs/node-glob/issues/167`);if(!(this instanceof GlobSync))return new GlobSync(pattern,options);if(setopts(this,pattern,options),this.noprocess)return this;var n=this.minimatch.set.length;this.matches=new Array(n);for(var i=0;i<n;i++)this._process(this.minimatch.set[i],i,!1);this._finish()}GlobSync.prototype._finish=function(){if(assert9.ok(this instanceof GlobSync),this.realpath){var self2=this;this.matches.forEach(function(matchset,index){var set=self2.matches[index]=Object.create(null);for(var p in matchset)try{p=self2._makeAbs(p);var real=rp.realpathSync(p,self2.realpathCache);set[real]=!0}catch(er){if(er.syscall==="stat")set[self2._makeAbs(p)]=!0;else throw er}})}common.finish(this)};GlobSync.prototype._process=function(pattern,index,inGlobStar){assert9.ok(this instanceof GlobSync);for(var n=0;typeof pattern[n]=="string";)n++;var prefix;switch(n){case pattern.length:this._processSimple(pattern.join("/"),index);return;case 0:prefix=null;break;default:prefix=pattern.slice(0,n).join("/");break}var remain=pattern.slice(n),read;prefix===null?read=".":((isAbsolute(prefix)||isAbsolute(pattern.map(function(p){return typeof p=="string"?p:"[*]"}).join("/")))&&(!prefix||!isAbsolute(prefix))&&(prefix="/"+prefix),read=prefix);var abs=this._makeAbs(read);if(!childrenIgnored(this,read)){var isGlobStar=remain[0]===minimatch3.GLOBSTAR;isGlobStar?this._processGlobStar(prefix,read,abs,remain,index,inGlobStar):this._processReaddir(prefix,read,abs,remain,index,inGlobStar)}};GlobSync.prototype._processReaddir=function(prefix,read,abs,remain,index,inGlobStar){var entries=this._readdir(abs,inGlobStar);if(entries){for(var pn=remain[0],negate=!!this.minimatch.negate,rawGlob=pn._glob,dotOk=this.dot||rawGlob.charAt(0)===".",matchedEntries=[],i=0;i<entries.length;i++){var e=entries[i];if(e.charAt(0)!=="."||dotOk){var m;negate&&!prefix?m=!e.match(pn):m=e.match(pn),m&&matchedEntries.push(e)}}var len=matchedEntries.length;if(len!==0){if(remain.length===1&&!this.mark&&!this.stat){this.matches[index]||(this.matches[index]=Object.create(null));for(var i=0;i<len;i++){var e=matchedEntries[i];prefix&&(prefix.slice(-1)!=="/"?e=prefix+"/"+e:e=prefix+e),e.charAt(0)==="/"&&!this.nomount&&(e=path9.join(this.root,e)),this._emitMatch(index,e)}return}remain.shift();for(var i=0;i<len;i++){var e=matchedEntries[i],newPattern;prefix?newPattern=[prefix,e]:newPattern=[e],this._process(newPattern.concat(remain),index,inGlobStar)}}}};GlobSync.prototype._emitMatch=function(index,e){if(!isIgnored(this,e)){var abs=this._makeAbs(e);if(this.mark&&(e=this._mark(e)),this.absolute&&(e=abs),!this.matches[index][e]){if(this.nodir){var c=this.cache[abs];if(c==="DIR"||Array.isArray(c))return}this.matches[index][e]=!0,this.stat&&this._stat(e)}}};GlobSync.prototype._readdirInGlobStar=function(abs){if(this.follow)return this._readdir(abs,!1);var entries,lstat4,stat2;try{lstat4=this.fs.lstatSync(abs)}catch(er){if(er.code==="ENOENT")return null}var isSym=lstat4&&lstat4.isSymbolicLink();return this.symlinks[abs]=isSym,!isSym&&lstat4&&!lstat4.isDirectory()?this.cache[abs]="FILE":entries=this._readdir(abs,!1),entries};GlobSync.prototype._readdir=function(abs,inGlobStar){var entries;if(inGlobStar&&!ownProp(this.symlinks,abs))return this._readdirInGlobStar(abs);if(ownProp(this.cache,abs)){var c=this.cache[abs];if(!c||c==="FILE")return null;if(Array.isArray(c))return c}try{return this._readdirEntries(abs,this.fs.readdirSync(abs))}catch(er){return this._readdirError(abs,er),null}};GlobSync.prototype._readdirEntries=function(abs,entries){if(!this.mark&&!this.stat)for(var i=0;i<entries.length;i++){var e=entries[i];abs==="/"?e=abs+e:e=abs+"/"+e,this.cache[e]=!0}return this.cache[abs]=entries,entries};GlobSync.prototype._readdirError=function(f,er){switch(er.code){case"ENOTSUP":case"ENOTDIR":var abs=this._makeAbs(f);if(this.cache[abs]="FILE",abs===this.cwdAbs){var error=new Error(er.code+" invalid cwd "+this.cwd);throw error.path=this.cwd,error.code=er.code,error}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(f)]=!1;break;default:if(this.cache[this._makeAbs(f)]=!1,this.strict)throw er;this.silent||console.error("glob error",er);break}};GlobSync.prototype._processGlobStar=function(prefix,read,abs,remain,index,inGlobStar){var entries=this._readdir(abs,inGlobStar);if(entries){var remainWithoutGlobStar=remain.slice(1),gspref=prefix?[prefix]:[],noGlobStar=gspref.concat(remainWithoutGlobStar);this._process(noGlobStar,index,!1);var len=entries.length,isSym=this.symlinks[abs];if(!(isSym&&inGlobStar))for(var i=0;i<len;i++){var e=entries[i];if(!(e.charAt(0)==="."&&!this.dot)){var instead=gspref.concat(entries[i],remainWithoutGlobStar);this._process(instead,index,!0);var below=gspref.concat(entries[i],remain);this._process(below,index,!0)}}}};GlobSync.prototype._processSimple=function(prefix,index){var exists=this._stat(prefix);if(this.matches[index]||(this.matches[index]=Object.create(null)),!!exists){if(prefix&&isAbsolute(prefix)&&!this.nomount){var trail=/[\/\\]$/.test(prefix);prefix.charAt(0)==="/"?prefix=path9.join(this.root,prefix):(prefix=path9.resolve(this.root,prefix),trail&&(prefix+="/"))}process.platform==="win32"&&(prefix=prefix.replace(/\\/g,"/")),this._emitMatch(index,prefix)}};GlobSync.prototype._stat=function(f){var abs=this._makeAbs(f),needDir=f.slice(-1)==="/";if(f.length>this.maxLength)return!1;if(!this.stat&&ownProp(this.cache,abs)){var c=this.cache[abs];if(Array.isArray(c)&&(c="DIR"),!needDir||c==="DIR")return c;if(needDir&&c==="FILE")return!1}var exists,stat2=this.statCache[abs];if(!stat2){var lstat4;try{lstat4=this.fs.lstatSync(abs)}catch(er){if(er&&(er.code==="ENOENT"||er.code==="ENOTDIR"))return this.statCache[abs]=!1,!1}if(lstat4&&lstat4.isSymbolicLink())try{stat2=this.fs.statSync(abs)}catch{stat2=lstat4}else stat2=lstat4}this.statCache[abs]=stat2;var c=!0;return stat2&&(c=stat2.isDirectory()?"DIR":"FILE"),this.cache[abs]=this.cache[abs]||c,needDir&&c==="FILE"?!1:c};GlobSync.prototype._mark=function(p){return common.mark(this,p)};GlobSync.prototype._makeAbs=function(f){return common.makeAbs(this,f)}}});var require_inflight=__commonJS({"../../node_modules/.pnpm/inflight@1.0.6/node_modules/inflight/inflight.js"(exports2,module2){var wrappy=require_wrappy(),reqs=Object.create(null),once=require_once();module2.exports=wrappy(inflight);function inflight(key,cb){return reqs[key]?(reqs[key].push(cb),null):(reqs[key]=[cb],makeres(key))}function makeres(key){return once(function RES(){var cbs=reqs[key],len=cbs.length,args=slice(arguments);try{for(var i=0;i<len;i++)cbs[i].apply(null,args)}finally{cbs.length>len?(cbs.splice(0,len),process.nextTick(function(){RES.apply(null,args)})):delete reqs[key]}})}function slice(args){for(var length=args.length,array=[],i=0;i<length;i++)array[i]=args[i];return array}}});var require_glob=__commonJS({"../../node_modules/.pnpm/glob@8.0.3/node_modules/glob/glob.js"(exports2,module2){module2.exports=glob2;var rp=require_fs2(),minimatch3=require_minimatch2(),Minimatch=minimatch3.Minimatch,inherits=require_inherits(),EE=require("events").EventEmitter,path9=require("path"),assert9=require("assert"),isAbsolute=require("path").isAbsolute,globSync=require_sync(),common=require_common(),setopts=common.setopts,ownProp=common.ownProp,inflight=require_inflight(),util=require("util"),childrenIgnored=common.childrenIgnored,isIgnored=common.isIgnored,once=require_once();function glob2(pattern,options,cb){if(typeof options=="function"&&(cb=options,options={}),options||(options={}),options.sync){if(cb)throw new TypeError("callback provided to sync glob");return globSync(pattern,options)}return new Glob(pattern,options,cb)}glob2.sync=globSync;var GlobSync=glob2.GlobSync=globSync.GlobSync;glob2.glob=glob2;function extend(origin,add){if(add===null||typeof add!="object")return origin;for(var keys=Object.keys(add),i=keys.length;i--;)origin[keys[i]]=add[keys[i]];return origin}glob2.hasMagic=function(pattern,options_){var options=extend({},options_);options.noprocess=!0;var g2=new Glob(pattern,options),set=g2.minimatch.set;if(!pattern)return!1;if(set.length>1)return!0;for(var j=0;j<set[0].length;j++)if(typeof set[0][j]!="string")return!0;return!1};glob2.Glob=Glob;inherits(Glob,EE);function Glob(pattern,options,cb){if(typeof options=="function"&&(cb=options,options=null),options&&options.sync){if(cb)throw new TypeError("callback provided to sync glob");return new GlobSync(pattern,options)}if(!(this instanceof Glob))return new Glob(pattern,options,cb);setopts(this,pattern,options),this._didRealPath=!1;var n=this.minimatch.set.length;this.matches=new Array(n),typeof cb=="function"&&(cb=once(cb),this.on("error",cb),this.on("end",function(matches){cb(null,matches)}));var self2=this;if(this._processing=0,this._emitQueue=[],this._processQueue=[],this.paused=!1,this.noprocess)return this;if(n===0)return done();for(var sync=!0,i=0;i<n;i++)this._process(this.minimatch.set[i],i,!1,done);sync=!1;function done(){--self2._processing,self2._processing<=0&&(sync?process.nextTick(function(){self2._finish()}):self2._finish())}}Glob.prototype._finish=function(){if(assert9(this instanceof Glob),!this.aborted){if(this.realpath&&!this._didRealpath)return this._realpath();common.finish(this),this.emit("end",this.found)}};Glob.prototype._realpath=function(){if(this._didRealpath)return;this._didRealpath=!0;var n=this.matches.length;if(n===0)return this._finish();for(var self2=this,i=0;i<this.matches.length;i++)this._realpathSet(i,next);function next(){--n===0&&self2._finish()}};Glob.prototype._realpathSet=function(index,cb){var matchset=this.matches[index];if(!matchset)return cb();var found=Object.keys(matchset),self2=this,n=found.length;if(n===0)return cb();var set=this.matches[index]=Object.create(null);found.forEach(function(p,i){p=self2._makeAbs(p),rp.realpath(p,self2.realpathCache,function(er,real){er?er.syscall==="stat"?set[p]=!0:self2.emit("error",er):set[real]=!0,--n===0&&(self2.matches[index]=set,cb())})})};Glob.prototype._mark=function(p){return common.mark(this,p)};Glob.prototype._makeAbs=function(f){return common.makeAbs(this,f)};Glob.prototype.abort=function(){this.aborted=!0,this.emit("abort")};Glob.prototype.pause=function(){this.paused||(this.paused=!0,this.emit("pause"))};Glob.prototype.resume=function(){if(this.paused){if(this.emit("resume"),this.paused=!1,this._emitQueue.length){var eq=this._emitQueue.slice(0);this._emitQueue.length=0;for(var i=0;i<eq.length;i++){var e=eq[i];this._emitMatch(e[0],e[1])}}if(this._processQueue.length){var pq=this._processQueue.slice(0);this._processQueue.length=0;for(var i=0;i<pq.length;i++){var p=pq[i];this._processing--,this._process(p[0],p[1],p[2],p[3])}}}};Glob.prototype._process=function(pattern,index,inGlobStar,cb){if(assert9(this instanceof Glob),assert9(typeof cb=="function"),!this.aborted){if(this._processing++,this.paused){this._processQueue.push([pattern,index,inGlobStar,cb]);return}for(var n=0;typeof pattern[n]=="string";)n++;var prefix;switch(n){case pattern.length:this._processSimple(pattern.join("/"),index,cb);return;case 0:prefix=null;break;default:prefix=pattern.slice(0,n).join("/");break}var remain=pattern.slice(n),read;prefix===null?read=".":((isAbsolute(prefix)||isAbsolute(pattern.map(function(p){return typeof p=="string"?p:"[*]"}).join("/")))&&(!prefix||!isAbsolute(prefix))&&(prefix="/"+prefix),read=prefix);var abs=this._makeAbs(read);if(childrenIgnored(this,read))return cb();var isGlobStar=remain[0]===minimatch3.GLOBSTAR;isGlobStar?this._processGlobStar(prefix,read,abs,remain,index,inGlobStar,cb):this._processReaddir(prefix,read,abs,remain,index,inGlobStar,cb)}};Glob.prototype._processReaddir=function(prefix,read,abs,remain,index,inGlobStar,cb){var self2=this;this._readdir(abs,inGlobStar,function(er,entries){return self2._processReaddir2(prefix,read,abs,remain,index,inGlobStar,entries,cb)})};Glob.prototype._processReaddir2=function(prefix,read,abs,remain,index,inGlobStar,entries,cb){if(!entries)return cb();for(var pn=remain[0],negate=!!this.minimatch.negate,rawGlob=pn._glob,dotOk=this.dot||rawGlob.charAt(0)===".",matchedEntries=[],i=0;i<entries.length;i++){var e=entries[i];if(e.charAt(0)!=="."||dotOk){var m;negate&&!prefix?m=!e.match(pn):m=e.match(pn),m&&matchedEntries.push(e)}}var len=matchedEntries.length;if(len===0)return cb();if(remain.length===1&&!this.mark&&!this.stat){this.matches[index]||(this.matches[index]=Object.create(null));for(var i=0;i<len;i++){var e=matchedEntries[i];prefix&&(prefix!=="/"?e=prefix+"/"+e:e=prefix+e),e.charAt(0)==="/"&&!this.nomount&&(e=path9.join(this.root,e)),this._emitMatch(index,e)}return cb()}remain.shift();for(var i=0;i<len;i++){var e=matchedEntries[i],newPattern;prefix&&(prefix!=="/"?e=prefix+"/"+e:e=prefix+e),this._process([e].concat(remain),index,inGlobStar,cb)}cb()};Glob.prototype._emitMatch=function(index,e){if(!this.aborted&&!isIgnored(this,e)){if(this.paused){this._emitQueue.push([index,e]);return}var abs=isAbsolute(e)?e:this._makeAbs(e);if(this.mark&&(e=this._mark(e)),this.absolute&&(e=abs),!this.matches[index][e]){if(this.nodir){var c=this.cache[abs];if(c==="DIR"||Array.isArray(c))return}this.matches[index][e]=!0;var st=this.statCache[abs];st&&this.emit("stat",e,st),this.emit("match",e)}}};Glob.prototype._readdirInGlobStar=function(abs,cb){if(this.aborted)return;if(this.follow)return this._readdir(abs,!1,cb);var lstatkey="lstat\0"+abs,self2=this,lstatcb=inflight(lstatkey,lstatcb_);lstatcb&&self2.fs.lstat(abs,lstatcb);function lstatcb_(er,lstat4){if(er&&er.code==="ENOENT")return cb();var isSym=lstat4&&lstat4.isSymbolicLink();self2.symlinks[abs]=isSym,!isSym&&lstat4&&!lstat4.isDirectory()?(self2.cache[abs]="FILE",cb()):self2._readdir(abs,!1,cb)}};Glob.prototype._readdir=function(abs,inGlobStar,cb){if(!this.aborted&&(cb=inflight("readdir\0"+abs+"\0"+inGlobStar,cb),!!cb)){if(inGlobStar&&!ownProp(this.symlinks,abs))return this._readdirInGlobStar(abs,cb);if(ownProp(this.cache,abs)){var c=this.cache[abs];if(!c||c==="FILE")return cb();if(Array.isArray(c))return cb(null,c)}var self2=this;self2.fs.readdir(abs,readdirCb(this,abs,cb))}};function readdirCb(self2,abs,cb){return function(er,entries){er?self2._readdirError(abs,er,cb):self2._readdirEntries(abs,entries,cb)}}Glob.prototype._readdirEntries=function(abs,entries,cb){if(!this.aborted){if(!this.mark&&!this.stat)for(var i=0;i<entries.length;i++){var e=entries[i];abs==="/"?e=abs+e:e=abs+"/"+e,this.cache[e]=!0}return this.cache[abs]=entries,cb(null,entries)}};Glob.prototype._readdirError=function(f,er,cb){if(!this.aborted){switch(er.code){case"ENOTSUP":case"ENOTDIR":var abs=this._makeAbs(f);if(this.cache[abs]="FILE",abs===this.cwdAbs){var error=new Error(er.code+" invalid cwd "+this.cwd);error.path=this.cwd,error.code=er.code,this.emit("error",error),this.abort()}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(f)]=!1;break;default:this.cache[this._makeAbs(f)]=!1,this.strict&&(this.emit("error",er),this.abort()),this.silent||console.error("glob error",er);break}return cb()}};Glob.prototype._processGlobStar=function(prefix,read,abs,remain,index,inGlobStar,cb){var self2=this;this._readdir(abs,inGlobStar,function(er,entries){self2._processGlobStar2(prefix,read,abs,remain,index,inGlobStar,entries,cb)})};Glob.prototype._processGlobStar2=function(prefix,read,abs,remain,index,inGlobStar,entries,cb){if(!entries)return cb();var remainWithoutGlobStar=remain.slice(1),gspref=prefix?[prefix]:[],noGlobStar=gspref.concat(remainWithoutGlobStar);this._process(noGlobStar,index,!1,cb);var isSym=this.symlinks[abs],len=entries.length;if(isSym&&inGlobStar)return cb();for(var i=0;i<len;i++){var e=entries[i];if(!(e.charAt(0)==="."&&!this.dot)){var instead=gspref.concat(entries[i],remainWithoutGlobStar);this._process(instead,index,!0,cb);var below=gspref.concat(entries[i],remain);this._process(below,index,!0,cb)}}cb()};Glob.prototype._processSimple=function(prefix,index,cb){var self2=this;this._stat(prefix,function(er,exists){self2._processSimple2(prefix,index,er,exists,cb)})};Glob.prototype._processSimple2=function(prefix,index,er,exists,cb){if(this.matches[index]||(this.matches[index]=Object.create(null)),!exists)return cb();if(prefix&&isAbsolute(prefix)&&!this.nomount){var trail=/[\/\\]$/.test(prefix);prefix.charAt(0)==="/"?prefix=path9.join(this.root,prefix):(prefix=path9.resolve(this.root,prefix),trail&&(prefix+="/"))}process.platform==="win32"&&(prefix=prefix.replace(/\\/g,"/")),this._emitMatch(index,prefix),cb()};Glob.prototype._stat=function(f,cb){var abs=this._makeAbs(f),needDir=f.slice(-1)==="/";if(f.length>this.maxLength)return cb();if(!this.stat&&ownProp(this.cache,abs)){var c=this.cache[abs];if(Array.isArray(c)&&(c="DIR"),!needDir||c==="DIR")return cb(null,c);if(needDir&&c==="FILE")return cb()}var exists,stat2=this.statCache[abs];if(stat2!==void 0){if(stat2===!1)return cb(null,stat2);var type=stat2.isDirectory()?"DIR":"FILE";return needDir&&type==="FILE"?cb():cb(null,type,stat2)}var self2=this,statcb=inflight("stat\0"+abs,lstatcb_);statcb&&self2.fs.lstat(abs,statcb);function lstatcb_(er,lstat4){if(lstat4&&lstat4.isSymbolicLink())return self2.fs.stat(abs,function(er2,stat3){er2?self2._stat2(f,abs,null,lstat4,cb):self2._stat2(f,abs,er2,stat3,cb)});self2._stat2(f,abs,er,lstat4,cb)}};Glob.prototype._stat2=function(f,abs,er,stat2,cb){if(er&&(er.code==="ENOENT"||er.code==="ENOTDIR"))return this.statCache[abs]=!1,cb();var needDir=f.slice(-1)==="/";if(this.statCache[abs]=stat2,abs.slice(-1)==="/"&&stat2&&!stat2.isDirectory())return cb(null,!1,stat2);var c=!0;return stat2&&(c=stat2.isDirectory()?"DIR":"FILE"),this.cache[abs]=this.cache[abs]||c,needDir&&c==="FILE"?cb():cb(null,c,stat2)}}});var normalize_path_exports={};__export(normalize_path_exports,{normalizePath:()=>normalizePath});function normalizePath(p){return isWin?p.replace(/\\/g,"/"):p}var isWin,init_normalize_path=__esm({"src/fs/normalize-path.ts"(){"use strict";isWin=process.platform==="win32"}});var glob_exports={};__export(glob_exports,{default:()=>glob});async function glob(pattern,opts,mountpoint){let options=typeof opts=="string"?{cwd:opts}:opts;if(!options.cwd)throw new Error("Second argument (basePath) must be specified for names of resulting files");if(!import_path4.default.isAbsolute(options.cwd))throw new Error(`basePath/cwd must be an absolute path (${options.cwd})`);let results={},statCache={},symlinks={},files=await vanillaGlob(pattern,{...options,symlinks,statCache,stat:!0,dot:!0}),dirs=new Set,dirsWithEntries=new Set;for(let relativePath of files){let absPath=import_path4.default.join(options.cwd,relativePath),fsPath=normalizePath(absPath),stat2=statCache[fsPath];(0,import_assert6.default)(stat2,`statCache does not contain value for ${relativePath} (resolved to ${fsPath})`);let isSymlink=symlinks[fsPath];if(options.follow&&(isSymlink||(await(0,import_fs_extra5.lstat)(fsPath)).isSymbolicLink())){let target=await(0,import_fs_extra5.readlink)(absPath),absTarget=import_path4.default.resolve(import_path4.default.dirname(absPath),target);if(import_path4.default.relative(options.cwd,absTarget).startsWith(`..${import_path4.default.sep}`))continue}if(isSymlink||stat2.isFile()||stat2.isDirectory()){isSymlink&&(stat2=await(0,import_fs_extra5.lstat)(absPath));let dirname3=import_path4.default.dirname(relativePath);if(dirsWithEntries.add(dirname3),stat2.isDirectory()){dirs.add(relativePath);continue}let finalPath=relativePath;mountpoint&&(finalPath=import_path4.default.join(mountpoint,finalPath)),results[finalPath]=new file_fs_ref_default({mode:stat2.mode,fsPath})}}if(options.includeDirectories)for(let relativePath of dirs){if(dirsWithEntries.has(relativePath))continue;let finalPath=relativePath;mountpoint&&(finalPath=import_path4.default.join(mountpoint,finalPath));let fsPath=normalizePath(import_path4.default.join(options.cwd,relativePath)),stat2=statCache[fsPath];results[finalPath]=new file_fs_ref_default({mode:stat2.mode,fsPath})}return results}var import_path4,import_assert6,import_glob,import_util,import_fs_extra5,vanillaGlob,init_glob=__esm({"src/fs/glob.ts"(){"use strict";import_path4=__toESM(require("path")),import_assert6=__toESM(require("assert")),import_glob=__toESM(require_glob()),import_util=require("util"),import_fs_extra5=__toESM(require_lib());init_normalize_path();init_file_fs_ref();vanillaGlob=(0,import_util.promisify)(import_glob.default)}});var rename_exports={};__export(rename_exports,{default:()=>rename});function rename(files,delegate){let result={};for(let[name,file]of Object.entries(files))result[delegate(name)]=file;return result}var init_rename=__esm({"src/fs/rename.ts"(){"use strict"}});var find_package_json_exports={};__export(find_package_json_exports,{findPackageJson:()=>findPackageJson,traverseUpDirectories:()=>traverseUpDirectories,walkParentDirs:()=>walkParentDirs});function*traverseUpDirectories({start,base}){let current=import_path5.default.normalize(start),normalizedRoot=base?import_path5.default.normalize(base):void 0;for(;current&&(yield current,current!==normalizedRoot);){let next=import_path5.default.join(current,"..");current=next===current?void 0:next}}async function findPackageJson(destPath,readPackageJson2=!1,base="/"){(0,import_assert7.default)(import_path5.default.isAbsolute(destPath));let pkgJsonPath=await walkParentDirs({base,start:destPath,filename:"package.json"}),packageJson;if(readPackageJson2&&pkgJsonPath)try{packageJson=JSON.parse(await import_fs_extra6.default.readFile(pkgJsonPath,"utf8"))}catch(err){throw new Error(`Could not read ${pkgJsonPath}: ${err.message}.`)}return{packageJsonPath:pkgJsonPath||void 0,packageJson}}async function walkParentDirs({base,start,filename}){(0,import_assert7.default)(import_path5.default.isAbsolute(base),'Expected "base" to be absolute path'),(0,import_assert7.default)(import_path5.default.isAbsolute(start),'Expected "start" to be absolute path');for(let dir of traverseUpDirectories({start,base})){let fullPath=import_path5.default.join(dir,filename);if(await import_fs_extra6.default.pathExists(fullPath))return fullPath}return null}var import_assert7,import_fs_extra6,import_path5,init_find_package_json=__esm({"src/fs/find-package-json.ts"(){"use strict";import_assert7=__toESM(require("assert")),import_fs_extra6=__toESM(require_lib()),import_path5=__toESM(require("path"))}});var require_src=__commonJS({"../../node_modules/.pnpm/nice-try@1.0.5/node_modules/nice-try/src/index.js"(exports2,module2){"use strict";module2.exports=function(fn){try{return fn()}catch{}}}});var require_windows=__commonJS({"../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js"(exports2,module2){module2.exports=isexe;isexe.sync=sync;var fs12=require("fs");function checkPathExt(path9,options){var pathext=options.pathExt!==void 0?options.pathExt:process.env.PATHEXT;if(!pathext||(pathext=pathext.split(";"),pathext.indexOf("")!==-1))return!0;for(var i=0;i<pathext.length;i++){var p=pathext[i].toLowerCase();if(p&&path9.substr(-p.length).toLowerCase()===p)return!0}return!1}function checkStat(stat2,path9,options){return!stat2.isSymbolicLink()&&!stat2.isFile()?!1:checkPathExt(path9,options)}function isexe(path9,options,cb){fs12.stat(path9,function(er,stat2){cb(er,er?!1:checkStat(stat2,path9,options))})}function sync(path9,options){return checkStat(fs12.statSync(path9),path9,options)}}});var require_mode=__commonJS({"../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/mode.js"(exports2,module2){module2.exports=isexe;isexe.sync=sync;var fs12=require("fs");function isexe(path9,options,cb){fs12.stat(path9,function(er,stat2){cb(er,er?!1:checkStat(stat2,options))})}function sync(path9,options){return checkStat(fs12.statSync(path9),options)}function checkStat(stat2,options){return stat2.isFile()&&checkMode(stat2,options)}function checkMode(stat2,options){var mod=stat2.mode,uid=stat2.uid,gid=stat2.gid,myUid=options.uid!==void 0?options.uid:process.getuid&&process.getuid(),myGid=options.gid!==void 0?options.gid:process.getgid&&process.getgid(),u=parseInt("100",8),g2=parseInt("010",8),o=parseInt("001",8),ug=u|g2,ret=mod&o||mod&g2&&gid===myGid||mod&u&&uid===myUid||mod&ug&&myUid===0;return ret}}});var require_isexe=__commonJS({"../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/index.js"(exports2,module2){var fs12=require("fs"),core;process.platform==="win32"||global.TESTING_WINDOWS?core=require_windows():core=require_mode();module2.exports=isexe;isexe.sync=sync;function isexe(path9,options,cb){if(typeof options=="function"&&(cb=options,options={}),!cb){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(resolve3,reject){isexe(path9,options||{},function(er,is){er?reject(er):resolve3(is)})})}core(path9,options||{},function(er,is){er&&(er.code==="EACCES"||options&&options.ignoreErrors)&&(er=null,is=!1),cb(er,is)})}function sync(path9,options){try{return core.sync(path9,options||{})}catch(er){if(options&&options.ignoreErrors||er.code==="EACCES")return!1;throw er}}}});var require_which=__commonJS({"../../node_modules/.pnpm/which@1.3.1/node_modules/which/which.js"(exports2,module2){module2.exports=which;which.sync=whichSync;var isWindows=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",path9=require("path"),COLON=isWindows?";":":",isexe=require_isexe();function getNotFoundError(cmd){var er=new Error("not found: "+cmd);return er.code="ENOENT",er}function getPathInfo(cmd,opt){var colon=opt.colon||COLON,pathEnv=opt.path||process.env.PATH||"",pathExt=[""];pathEnv=pathEnv.split(colon);var pathExtExe="";return isWindows&&(pathEnv.unshift(process.cwd()),pathExtExe=opt.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM",pathExt=pathExtExe.split(colon),cmd.indexOf(".")!==-1&&pathExt[0]!==""&&pathExt.unshift("")),(cmd.match(/\//)||isWindows&&cmd.match(/\\/))&&(pathEnv=[""]),{env:pathEnv,ext:pathExt,extExe:pathExtExe}}function which(cmd,opt,cb){typeof opt=="function"&&(cb=opt,opt={});var info=getPathInfo(cmd,opt),pathEnv=info.env,pathExt=info.ext,pathExtExe=info.extExe,found=[];(function F(i,l){if(i===l)return opt.all&&found.length?cb(null,found):cb(getNotFoundError(cmd));var pathPart=pathEnv[i];pathPart.charAt(0)==='"'&&pathPart.slice(-1)==='"'&&(pathPart=pathPart.slice(1,-1));var p=path9.join(pathPart,cmd);!pathPart&&/^\.[\\\/]/.test(cmd)&&(p=cmd.slice(0,2)+p),function E3(ii,ll){if(ii===ll)return F(i+1,l);var ext=pathExt[ii];isexe(p+ext,{pathExt:pathExtExe},function(er,is){if(!er&&is)if(opt.all)found.push(p+ext);else return cb(null,p+ext);return E3(ii+1,ll)})}(0,pathExt.length)})(0,pathEnv.length)}function whichSync(cmd,opt){opt=opt||{};for(var info=getPathInfo(cmd,opt),pathEnv=info.env,pathExt=info.ext,pathExtExe=info.extExe,found=[],i=0,l=pathEnv.length;i<l;i++){var pathPart=pathEnv[i];pathPart.charAt(0)==='"'&&pathPart.slice(-1)==='"'&&(pathPart=pathPart.slice(1,-1));var p=path9.join(pathPart,cmd);!pathPart&&/^\.[\\\/]/.test(cmd)&&(p=cmd.slice(0,2)+p);for(var j=0,ll=pathExt.length;j<ll;j++){var cur=p+pathExt[j],is;try{if(is=isexe.sync(cur,{pathExt:pathExtExe}),is)if(opt.all)found.push(cur);else return cur}catch{}}}if(opt.all&&found.length)return found;if(opt.nothrow)return null;throw getNotFoundError(cmd)}}});var require_path_key=__commonJS({"../../node_modules/.pnpm/path-key@2.0.1/node_modules/path-key/index.js"(exports2,module2){"use strict";module2.exports=opts=>{opts=opts||{};let env=opts.env||process.env;return(opts.platform||process.platform)!=="win32"?"PATH":Object.keys(env).find(x=>x.toUpperCase()==="PATH")||"Path"}}});var require_resolveCommand=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/util/resolveCommand.js"(exports2,module2){"use strict";var path9=require("path"),which=require_which(),pathKey=require_path_key()();function resolveCommandAttempt(parsed,withoutPathExt){let cwd=process.cwd(),hasCustomCwd=parsed.options.cwd!=null;if(hasCustomCwd)try{process.chdir(parsed.options.cwd)}catch{}let resolved;try{resolved=which.sync(parsed.command,{path:(parsed.options.env||process.env)[pathKey],pathExt:withoutPathExt?path9.delimiter:void 0})}catch{}finally{process.chdir(cwd)}return resolved&&(resolved=path9.resolve(hasCustomCwd?parsed.options.cwd:"",resolved)),resolved}function resolveCommand(parsed){return resolveCommandAttempt(parsed)||resolveCommandAttempt(parsed,!0)}module2.exports=resolveCommand}});var require_escape=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/util/escape.js"(exports2,module2){"use strict";var metaCharsRegExp=/([()\][%!^"`<>&|;, *?])/g;function escapeCommand(arg){return arg=arg.replace(metaCharsRegExp,"^$1"),arg}function escapeArgument(arg,doubleEscapeMetaChars){return arg=`${arg}`,arg=arg.replace(/(\\*)"/g,'$1$1\\"'),arg=arg.replace(/(\\*)$/,"$1$1"),arg=`"${arg}"`,arg=arg.replace(metaCharsRegExp,"^$1"),doubleEscapeMetaChars&&(arg=arg.replace(metaCharsRegExp,"^$1")),arg}module2.exports.command=escapeCommand;module2.exports.argument=escapeArgument}});var require_shebang_regex=__commonJS({"../../node_modules/.pnpm/shebang-regex@1.0.0/node_modules/shebang-regex/index.js"(exports2,module2){"use strict";module2.exports=/^#!.*/}});var require_shebang_command=__commonJS({"../../node_modules/.pnpm/shebang-command@1.2.0/node_modules/shebang-command/index.js"(exports2,module2){"use strict";var shebangRegex=require_shebang_regex();module2.exports=function(str){var match=str.match(shebangRegex);if(!match)return null;var arr=match[0].replace(/#! ?/,"").split(" "),bin=arr[0].split("/").pop(),arg=arr[1];return bin==="env"?arg:bin+(arg?" "+arg:"")}}});var require_readShebang=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/util/readShebang.js"(exports2,module2){"use strict";var fs12=require("fs"),shebangCommand=require_shebang_command();function readShebang(command){let buffer;Buffer.alloc?buffer=Buffer.alloc(150):(buffer=new Buffer(150),buffer.fill(0));let fd;try{fd=fs12.openSync(command,"r"),fs12.readSync(fd,buffer,0,150,0),fs12.closeSync(fd)}catch{}return shebangCommand(buffer.toString())}module2.exports=readShebang}});var require_semver=__commonJS({"../../node_modules/.pnpm/semver@5.7.2/node_modules/semver/semver.js"(exports2,module2){exports2=module2.exports=SemVer2;var debug2;typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?debug2=function(){var args=Array.prototype.slice.call(arguments,0);args.unshift("SEMVER"),console.log.apply(console,args)}:debug2=function(){};exports2.SEMVER_SPEC_VERSION="2.0.0";var MAX_LENGTH=256,MAX_SAFE_INTEGER=Number.MAX_SAFE_INTEGER||9007199254740991,MAX_SAFE_COMPONENT_LENGTH=16,MAX_SAFE_BUILD_LENGTH=MAX_LENGTH-6,re=exports2.re=[],safeRe=exports2.safeRe=[],src=exports2.src=[],R=0,LETTERDASHNUMBER="[a-zA-Z0-9-]",safeRegexReplacements=[["\\s",1],["\\d",MAX_LENGTH],[LETTERDASHNUMBER,MAX_SAFE_BUILD_LENGTH]];function makeSafeRe(value){for(var i2=0;i2<safeRegexReplacements.length;i2++){var token=safeRegexReplacements[i2][0],max=safeRegexReplacements[i2][1];value=value.split(token+"*").join(token+"{0,"+max+"}").split(token+"+").join(token+"{1,"+max+"}")}return value}var NUMERICIDENTIFIER=R++;src[NUMERICIDENTIFIER]="0|[1-9]\\d*";var NUMERICIDENTIFIERLOOSE=R++;src[NUMERICIDENTIFIERLOOSE]="\\d+";var NONNUMERICIDENTIFIER=R++;src[NONNUMERICIDENTIFIER]="\\d*[a-zA-Z-]"+LETTERDASHNUMBER+"*";var MAINVERSION=R++;src[MAINVERSION]="("+src[NUMERICIDENTIFIER]+")\\.("+src[NUMERICIDENTIFIER]+")\\.("+src[NUMERICIDENTIFIER]+")";var MAINVERSIONLOOSE=R++;src[MAINVERSIONLOOSE]="("+src[NUMERICIDENTIFIERLOOSE]+")\\.("+src[NUMERICIDENTIFIERLOOSE]+")\\.("+src[NUMERICIDENTIFIERLOOSE]+")";var PRERELEASEIDENTIFIER=R++;src[PRERELEASEIDENTIFIER]="(?:"+src[NUMERICIDENTIFIER]+"|"+src[NONNUMERICIDENTIFIER]+")";var PRERELEASEIDENTIFIERLOOSE=R++;src[PRERELEASEIDENTIFIERLOOSE]="(?:"+src[NUMERICIDENTIFIERLOOSE]+"|"+src[NONNUMERICIDENTIFIER]+")";var PRERELEASE=R++;src[PRERELEASE]="(?:-("+src[PRERELEASEIDENTIFIER]+"(?:\\."+src[PRERELEASEIDENTIFIER]+")*))";var PRERELEASELOOSE=R++;src[PRERELEASELOOSE]="(?:-?("+src[PRERELEASEIDENTIFIERLOOSE]+"(?:\\."+src[PRERELEASEIDENTIFIERLOOSE]+")*))";var BUILDIDENTIFIER=R++;src[BUILDIDENTIFIER]=LETTERDASHNUMBER+"+";var BUILD=R++;src[BUILD]="(?:\\+("+src[BUILDIDENTIFIER]+"(?:\\."+src[BUILDIDENTIFIER]+")*))";var FULL=R++,FULLPLAIN="v?"+src[MAINVERSION]+src[PRERELEASE]+"?"+src[BUILD]+"?";src[FULL]="^"+FULLPLAIN+"$";var LOOSEPLAIN="[v=\\s]*"+src[MAINVERSIONLOOSE]+src[PRERELEASELOOSE]+"?"+src[BUILD]+"?",LOOSE=R++;src[LOOSE]="^"+LOOSEPLAIN+"$";var GTLT=R++;src[GTLT]="((?:<|>)?=?)";var XRANGEIDENTIFIERLOOSE=R++;src[XRANGEIDENTIFIERLOOSE]=src[NUMERICIDENTIFIERLOOSE]+"|x|X|\\*";var XRANGEIDENTIFIER=R++;src[XRANGEIDENTIFIER]=src[NUMERICIDENTIFIER]+"|x|X|\\*";var XRANGEPLAIN=R++;src[XRANGEPLAIN]="[v=\\s]*("+src[XRANGEIDENTIFIER]+")(?:\\.("+src[XRANGEIDENTIFIER]+")(?:\\.("+src[XRANGEIDENTIFIER]+")(?:"+src[PRERELEASE]+")?"+src[BUILD]+"?)?)?";var XRANGEPLAINLOOSE=R++;src[XRANGEPLAINLOOSE]="[v=\\s]*("+src[XRANGEIDENTIFIERLOOSE]+")(?:\\.("+src[XRANGEIDENTIFIERLOOSE]+")(?:\\.("+src[XRANGEIDENTIFIERLOOSE]+")(?:"+src[PRERELEASELOOSE]+")?"+src[BUILD]+"?)?)?";var XRANGE=R++;src[XRANGE]="^"+src[GTLT]+"\\s*"+src[XRANGEPLAIN]+"$";var XRANGELOOSE=R++;src[XRANGELOOSE]="^"+src[GTLT]+"\\s*"+src[XRANGEPLAINLOOSE]+"$";var COERCE=R++;src[COERCE]="(?:^|[^\\d])(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"})(?:\\.(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"}))?(?:\\.(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"}))?(?:$|[^\\d])";var LONETILDE=R++;src[LONETILDE]="(?:~>?)";var TILDETRIM=R++;src[TILDETRIM]="(\\s*)"+src[LONETILDE]+"\\s+";re[TILDETRIM]=new RegExp(src[TILDETRIM],"g");safeRe[TILDETRIM]=new RegExp(makeSafeRe(src[TILDETRIM]),"g");var tildeTrimReplace="$1~",TILDE=R++;src[TILDE]="^"+src[LONETILDE]+src[XRANGEPLAIN]+"$";var TILDELOOSE=R++;src[TILDELOOSE]="^"+src[LONETILDE]+src[XRANGEPLAINLOOSE]+"$";var LONECARET=R++;src[LONECARET]="(?:\\^)";var CARETTRIM=R++;src[CARETTRIM]="(\\s*)"+src[LONECARET]+"\\s+";re[CARETTRIM]=new RegExp(src[CARETTRIM],"g");safeRe[CARETTRIM]=new RegExp(makeSafeRe(src[CARETTRIM]),"g");var caretTrimReplace="$1^",CARET=R++;src[CARET]="^"+src[LONECARET]+src[XRANGEPLAIN]+"$";var CARETLOOSE=R++;src[CARETLOOSE]="^"+src[LONECARET]+src[XRANGEPLAINLOOSE]+"$";var COMPARATORLOOSE=R++;src[COMPARATORLOOSE]="^"+src[GTLT]+"\\s*("+LOOSEPLAIN+")$|^$";var COMPARATOR=R++;src[COMPARATOR]="^"+src[GTLT]+"\\s*("+FULLPLAIN+")$|^$";var COMPARATORTRIM=R++;src[COMPARATORTRIM]="(\\s*)"+src[GTLT]+"\\s*("+LOOSEPLAIN+"|"+src[XRANGEPLAIN]+")";re[COMPARATORTRIM]=new RegExp(src[COMPARATORTRIM],"g");safeRe[COMPARATORTRIM]=new RegExp(makeSafeRe(src[COMPARATORTRIM]),"g");var comparatorTrimReplace="$1$2$3",HYPHENRANGE=R++;src[HYPHENRANGE]="^\\s*("+src[XRANGEPLAIN]+")\\s+-\\s+("+src[XRANGEPLAIN]+")\\s*$";var HYPHENRANGELOOSE=R++;src[HYPHENRANGELOOSE]="^\\s*("+src[XRANGEPLAINLOOSE]+")\\s+-\\s+("+src[XRANGEPLAINLOOSE]+")\\s*$";var STAR=R++;src[STAR]="(<|>)?=?\\s*\\*";for(i=0;i<R;i++)debug2(i,src[i]),re[i]||(re[i]=new RegExp(src[i]),safeRe[i]=new RegExp(makeSafeRe(src[i])));var i;exports2.parse=parse6;function parse6(version,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),version instanceof SemVer2)return version;if(typeof version!="string"||version.length>MAX_LENGTH)return null;var r=options.loose?safeRe[LOOSE]:safeRe[FULL];if(!r.test(version))return null;try{return new SemVer2(version,options)}catch{return null}}exports2.valid=valid;function valid(version,options){var v=parse6(version,options);return v?v.version:null}exports2.clean=clean;function clean(version,options){var s=parse6(version.trim().replace(/^[=v]+/,""),options);return s?s.version:null}exports2.SemVer=SemVer2;function SemVer2(version,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),version instanceof SemVer2){if(version.loose===options.loose)return version;version=version.version}else if(typeof version!="string")throw new TypeError("Invalid Version: "+version);if(version.length>MAX_LENGTH)throw new TypeError("version is longer than "+MAX_LENGTH+" characters");if(!(this instanceof SemVer2))return new SemVer2(version,options);debug2("SemVer",version,options),this.options=options,this.loose=!!options.loose;var m=version.trim().match(options.loose?safeRe[LOOSE]:safeRe[FULL]);if(!m)throw new TypeError("Invalid Version: "+version);if(this.raw=version,this.major=+m[1],this.minor=+m[2],this.patch=+m[3],this.major>MAX_SAFE_INTEGER||this.major<0)throw new TypeError("Invalid major version");if(this.minor>MAX_SAFE_INTEGER||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>MAX_SAFE_INTEGER||this.patch<0)throw new TypeError("Invalid patch version");m[4]?this.prerelease=m[4].split(".").map(function(id){if(/^[0-9]+$/.test(id)){var num=+id;if(num>=0&&num<MAX_SAFE_INTEGER)return num}return id}):this.prerelease=[],this.build=m[5]?m[5].split("."):[],this.format()}SemVer2.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version};SemVer2.prototype.toString=function(){return this.version};SemVer2.prototype.compare=function(other){return debug2("SemVer.compare",this.version,this.options,other),other instanceof SemVer2||(other=new SemVer2(other,this.options)),this.compareMain(other)||this.comparePre(other)};SemVer2.prototype.compareMain=function(other){return other instanceof SemVer2||(other=new SemVer2(other,this.options)),compareIdentifiers(this.major,other.major)||compareIdentifiers(this.minor,other.minor)||compareIdentifiers(this.patch,other.patch)};SemVer2.prototype.comparePre=function(other){if(other instanceof SemVer2||(other=new SemVer2(other,this.options)),this.prerelease.length&&!other.prerelease.length)return-1;if(!this.prerelease.length&&other.prerelease.length)return 1;if(!this.prerelease.length&&!other.prerelease.length)return 0;var i2=0;do{var a=this.prerelease[i2],b=other.prerelease[i2];if(debug2("prerelease compare",i2,a,b),a===void 0&&b===void 0)return 0;if(b===void 0)return 1;if(a===void 0)return-1;if(a===b)continue;return compareIdentifiers(a,b)}while(++i2)};SemVer2.prototype.inc=function(release,identifier){switch(release){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",identifier);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",identifier);break;case"prepatch":this.prerelease.length=0,this.inc("patch",identifier),this.inc("pre",identifier);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",identifier),this.inc("pre",identifier);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{for(var i2=this.prerelease.length;--i2>=0;)typeof this.prerelease[i2]=="number"&&(this.prerelease[i2]++,i2=-2);i2===-1&&this.prerelease.push(0)}identifier&&(this.prerelease[0]===identifier?isNaN(this.prerelease[1])&&(this.prerelease=[identifier,0]):this.prerelease=[identifier,0]);break;default:throw new Error("invalid increment argument: "+release)}return this.format(),this.raw=this.version,this};exports2.inc=inc;function inc(version,release,loose,identifier){typeof loose=="string"&&(identifier=loose,loose=void 0);try{return new SemVer2(version,loose).inc(release,identifier).version}catch{return null}}exports2.diff=diff;function diff(version1,version2){if(eq(version1,version2))return null;var v1=parse6(version1),v2=parse6(version2),prefix="";if(v1.prerelease.length||v2.prerelease.length){prefix="pre";var defaultResult="prerelease"}for(var key in v1)if((key==="major"||key==="minor"||key==="patch")&&v1[key]!==v2[key])return prefix+key;return defaultResult}exports2.compareIdentifiers=compareIdentifiers;var numeric=/^[0-9]+$/;function compareIdentifiers(a,b){var anum=numeric.test(a),bnum=numeric.test(b);return anum&&bnum&&(a=+a,b=+b),a===b?0:anum&&!bnum?-1:bnum&&!anum?1:a<b?-1:1}exports2.rcompareIdentifiers=rcompareIdentifiers;function rcompareIdentifiers(a,b){return compareIdentifiers(b,a)}exports2.major=major;function major(a,loose){return new SemVer2(a,loose).major}exports2.minor=minor;function minor(a,loose){return new SemVer2(a,loose).minor}exports2.patch=patch;function patch(a,loose){return new SemVer2(a,loose).patch}exports2.compare=compare;function compare(a,b,loose){return new SemVer2(a,loose).compare(new SemVer2(b,loose))}exports2.compareLoose=compareLoose;function compareLoose(a,b){return compare(a,b,!0)}exports2.rcompare=rcompare;function rcompare(a,b,loose){return compare(b,a,loose)}exports2.sort=sort;function sort(list,loose){return list.sort(function(a,b){return exports2.compare(a,b,loose)})}exports2.rsort=rsort;function rsort(list,loose){return list.sort(function(a,b){return exports2.rcompare(a,b,loose)})}exports2.gt=gt;function gt(a,b,loose){return compare(a,b,loose)>0}exports2.lt=lt;function lt(a,b,loose){return compare(a,b,loose)<0}exports2.eq=eq;function eq(a,b,loose){return compare(a,b,loose)===0}exports2.neq=neq;function neq(a,b,loose){return compare(a,b,loose)!==0}exports2.gte=gte2;function gte2(a,b,loose){return compare(a,b,loose)>=0}exports2.lte=lte;function lte(a,b,loose){return compare(a,b,loose)<=0}exports2.cmp=cmp;function cmp(a,op,b,loose){switch(op){case"===":return typeof a=="object"&&(a=a.version),typeof b=="object"&&(b=b.version),a===b;case"!==":return typeof a=="object"&&(a=a.version),typeof b=="object"&&(b=b.version),a!==b;case"":case"=":case"==":return eq(a,b,loose);case"!=":return neq(a,b,loose);case">":return gt(a,b,loose);case">=":return gte2(a,b,loose);case"<":return lt(a,b,loose);case"<=":return lte(a,b,loose);default:throw new TypeError("Invalid operator: "+op)}}exports2.Comparator=Comparator;function Comparator(comp,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),comp instanceof Comparator){if(comp.loose===!!options.loose)return comp;comp=comp.value}if(!(this instanceof Comparator))return new Comparator(comp,options);comp=comp.trim().split(/\s+/).join(" "),debug2("comparator",comp,options),this.options=options,this.loose=!!options.loose,this.parse(comp),this.semver===ANY?this.value="":this.value=this.operator+this.semver.version,debug2("comp",this)}var ANY={};Comparator.prototype.parse=function(comp){var r=this.options.loose?safeRe[COMPARATORLOOSE]:safeRe[COMPARATOR],m=comp.match(r);if(!m)throw new TypeError("Invalid comparator: "+comp);this.operator=m[1],this.operator==="="&&(this.operator=""),m[2]?this.semver=new SemVer2(m[2],this.options.loose):this.semver=ANY};Comparator.prototype.toString=function(){return this.value};Comparator.prototype.test=function(version){return debug2("Comparator.test",version,this.options.loose),this.semver===ANY?!0:(typeof version=="string"&&(version=new SemVer2(version,this.options)),cmp(version,this.operator,this.semver,this.options))};Comparator.prototype.intersects=function(comp,options){if(!(comp instanceof Comparator))throw new TypeError("a Comparator is required");(!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1});var rangeTmp;if(this.operator==="")return rangeTmp=new Range(comp.value,options),satisfies2(this.value,rangeTmp,options);if(comp.operator==="")return rangeTmp=new Range(this.value,options),satisfies2(comp.semver,rangeTmp,options);var sameDirectionIncreasing=(this.operator===">="||this.operator===">")&&(comp.operator===">="||comp.operator===">"),sameDirectionDecreasing=(this.operator==="<="||this.operator==="<")&&(comp.operator==="<="||comp.operator==="<"),sameSemVer=this.semver.version===comp.semver.version,differentDirectionsInclusive=(this.operator===">="||this.operator==="<=")&&(comp.operator===">="||comp.operator==="<="),oppositeDirectionsLessThan=cmp(this.semver,"<",comp.semver,options)&&(this.operator===">="||this.operator===">")&&(comp.operator==="<="||comp.operator==="<"),oppositeDirectionsGreaterThan=cmp(this.semver,">",comp.semver,options)&&(this.operator==="<="||this.operator==="<")&&(comp.operator===">="||comp.operator===">");return sameDirectionIncreasing||sameDirectionDecreasing||sameSemVer&&differentDirectionsInclusive||oppositeDirectionsLessThan||oppositeDirectionsGreaterThan};exports2.Range=Range;function Range(range,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),range instanceof Range)return range.loose===!!options.loose&&range.includePrerelease===!!options.includePrerelease?range:new Range(range.raw,options);if(range instanceof Comparator)return new Range(range.value,options);if(!(this instanceof Range))return new Range(range,options);if(this.options=options,this.loose=!!options.loose,this.includePrerelease=!!options.includePrerelease,this.raw=range.trim().split(/\s+/).join(" "),this.set=this.raw.split("||").map(function(range2){return this.parseRange(range2.trim())},this).filter(function(c){return c.length}),!this.set.length)throw new TypeError("Invalid SemVer Range: "+this.raw);this.format()}Range.prototype.format=function(){return this.range=this.set.map(function(comps){return comps.join(" ").trim()}).join("||").trim(),this.range};Range.prototype.toString=function(){return this.range};Range.prototype.parseRange=function(range){var loose=this.options.loose,hr=loose?safeRe[HYPHENRANGELOOSE]:safeRe[HYPHENRANGE];range=range.replace(hr,hyphenReplace),debug2("hyphen replace",range),range=range.replace(safeRe[COMPARATORTRIM],comparatorTrimReplace),debug2("comparator trim",range,safeRe[COMPARATORTRIM]),range=range.replace(safeRe[TILDETRIM],tildeTrimReplace),range=range.replace(safeRe[CARETTRIM],caretTrimReplace);var compRe=loose?safeRe[COMPARATORLOOSE]:safeRe[COMPARATOR],set=range.split(" ").map(function(comp){return parseComparator(comp,this.options)},this).join(" ").split(/\s+/);return this.options.loose&&(set=set.filter(function(comp){return!!comp.match(compRe)})),set=set.map(function(comp){return new Comparator(comp,this.options)},this),set};Range.prototype.intersects=function(range,options){if(!(range instanceof Range))throw new TypeError("a Range is required");return this.set.some(function(thisComparators){return thisComparators.every(function(thisComparator){return range.set.some(function(rangeComparators){return rangeComparators.every(function(rangeComparator){return thisComparator.intersects(rangeComparator,options)})})})})};exports2.toComparators=toComparators;function toComparators(range,options){return new Range(range,options).set.map(function(comp){return comp.map(function(c){return c.value}).join(" ").trim().split(" ")})}function parseComparator(comp,options){return debug2("comp",comp,options),comp=replaceCarets(comp,options),debug2("caret",comp),comp=replaceTildes(comp,options),debug2("tildes",comp),comp=replaceXRanges(comp,options),debug2("xrange",comp),comp=replaceStars(comp,options),debug2("stars",comp),comp}function isX(id){return!id||id.toLowerCase()==="x"||id==="*"}function replaceTildes(comp,options){return comp.trim().split(/\s+/).map(function(comp2){return replaceTilde(comp2,options)}).join(" ")}function replaceTilde(comp,options){var r=options.loose?safeRe[TILDELOOSE]:safeRe[TILDE];return comp.replace(r,function(_,M,m,p,pr){debug2("tilde",comp,_,M,m,p,pr);var ret;return isX(M)?ret="":isX(m)?ret=">="+M+".0.0 <"+(+M+1)+".0.0":isX(p)?ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0":pr?(debug2("replaceTilde pr",pr),ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+(+m+1)+".0"):ret=">="+M+"."+m+"."+p+" <"+M+"."+(+m+1)+".0",debug2("tilde return",ret),ret})}function replaceCarets(comp,options){return comp.trim().split(/\s+/).map(function(comp2){return replaceCaret(comp2,options)}).join(" ")}function replaceCaret(comp,options){debug2("caret",comp,options);var r=options.loose?safeRe[CARETLOOSE]:safeRe[CARET];return comp.replace(r,function(_,M,m,p,pr){debug2("caret",comp,_,M,m,p,pr);var ret;return isX(M)?ret="":isX(m)?ret=">="+M+".0.0 <"+(+M+1)+".0.0":isX(p)?M==="0"?ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+".0 <"+(+M+1)+".0.0":pr?(debug2("replaceCaret pr",pr),M==="0"?m==="0"?ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+m+"."+(+p+1):ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+"."+p+"-"+pr+" <"+(+M+1)+".0.0"):(debug2("no pr"),M==="0"?m==="0"?ret=">="+M+"."+m+"."+p+" <"+M+"."+m+"."+(+p+1):ret=">="+M+"."+m+"."+p+" <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+"."+p+" <"+(+M+1)+".0.0"),debug2("caret return",ret),ret})}function replaceXRanges(comp,options){return debug2("replaceXRanges",comp,options),comp.split(/\s+/).map(function(comp2){return replaceXRange(comp2,options)}).join(" ")}function replaceXRange(comp,options){comp=comp.trim();var r=options.loose?safeRe[XRANGELOOSE]:safeRe[XRANGE];return comp.replace(r,function(ret,gtlt,M,m,p,pr){debug2("xRange",comp,ret,gtlt,M,m,p,pr);var xM=isX(M),xm=xM||isX(m),xp=xm||isX(p),anyX=xp;return gtlt==="="&&anyX&&(gtlt=""),xM?gtlt===">"||gtlt==="<"?ret="<0.0.0":ret="*":gtlt&&anyX?(xm&&(m=0),p=0,gtlt===">"?(gtlt=">=",xm?(M=+M+1,m=0,p=0):(m=+m+1,p=0)):gtlt==="<="&&(gtlt="<",xm?M=+M+1:m=+m+1),ret=gtlt+M+"."+m+"."+p):xm?ret=">="+M+".0.0 <"+(+M+1)+".0.0":xp&&(ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0"),debug2("xRange return",ret),ret})}function replaceStars(comp,options){return debug2("replaceStars",comp,options),comp.trim().replace(safeRe[STAR],"")}function hyphenReplace($0,from,fM,fm,fp,fpr,fb,to,tM,tm,tp,tpr,tb){return isX(fM)?from="":isX(fm)?from=">="+fM+".0.0":isX(fp)?from=">="+fM+"."+fm+".0":from=">="+from,isX(tM)?to="":isX(tm)?to="<"+(+tM+1)+".0.0":isX(tp)?to="<"+tM+"."+(+tm+1)+".0":tpr?to="<="+tM+"."+tm+"."+tp+"-"+tpr:to="<="+to,(from+" "+to).trim()}Range.prototype.test=function(version){if(!version)return!1;typeof version=="string"&&(version=new SemVer2(version,this.options));for(var i2=0;i2<this.set.length;i2++)if(testSet(this.set[i2],version,this.options))return!0;return!1};function testSet(set,version,options){for(var i2=0;i2<set.length;i2++)if(!set[i2].test(version))return!1;if(version.prerelease.length&&!options.includePrerelease){for(i2=0;i2<set.length;i2++)if(debug2(set[i2].semver),set[i2].semver!==ANY&&set[i2].semver.prerelease.length>0){var allowed=set[i2].semver;if(allowed.major===version.major&&allowed.minor===version.minor&&allowed.patch===version.patch)return!0}return!1}return!0}exports2.satisfies=satisfies2;function satisfies2(version,range,options){try{range=new Range(range,options)}catch{return!1}return range.test(version)}exports2.maxSatisfying=maxSatisfying;function maxSatisfying(versions,range,options){var max=null,maxSV=null;try{var rangeObj=new Range(range,options)}catch{return null}return versions.forEach(function(v){rangeObj.test(v)&&(!max||maxSV.compare(v)===-1)&&(max=v,maxSV=new SemVer2(max,options))}),max}exports2.minSatisfying=minSatisfying;function minSatisfying(versions,range,options){var min=null,minSV=null;try{var rangeObj=new Range(range,options)}catch{return null}return versions.forEach(function(v){rangeObj.test(v)&&(!min||minSV.compare(v)===1)&&(min=v,minSV=new SemVer2(min,options))}),min}exports2.minVersion=minVersion2;function minVersion2(range,loose){range=new Range(range,loose);var minver=new SemVer2("0.0.0");if(range.test(minver)||(minver=new SemVer2("0.0.0-0"),range.test(minver)))return minver;minver=null;for(var i2=0;i2<range.set.length;++i2){var comparators=range.set[i2];comparators.forEach(function(comparator){var compver=new SemVer2(comparator.semver.version);switch(comparator.operator){case">":compver.prerelease.length===0?compver.patch++:compver.prerelease.push(0),compver.raw=compver.format();case"":case">=":(!minver||gt(minver,compver))&&(minver=compver);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+comparator.operator)}})}return minver&&range.test(minver)?minver:null}exports2.validRange=validRange3;function validRange3(range,options){try{return new Range(range,options).range||"*"}catch{return null}}exports2.ltr=ltr;function ltr(version,range,options){return outside(version,range,"<",options)}exports2.gtr=gtr;function gtr(version,range,options){return outside(version,range,">",options)}exports2.outside=outside;function outside(version,range,hilo,options){version=new SemVer2(version,options),range=new Range(range,options);var gtfn,ltefn,ltfn,comp,ecomp;switch(hilo){case">":gtfn=gt,ltefn=lte,ltfn=lt,comp=">",ecomp=">=";break;case"<":gtfn=lt,ltefn=gte2,ltfn=gt,comp="<",ecomp="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(satisfies2(version,range,options))return!1;for(var i2=0;i2<range.set.length;++i2){var comparators=range.set[i2],high=null,low=null;if(comparators.forEach(function(comparator){comparator.semver===ANY&&(comparator=new Comparator(">=0.0.0")),high=high||comparator,low=low||comparator,gtfn(comparator.semver,high.semver,options)?high=comparator:ltfn(comparator.semver,low.semver,options)&&(low=comparator)}),high.operator===comp||high.operator===ecomp||(!low.operator||low.operator===comp)&&ltefn(version,low.semver))return!1;if(low.operator===ecomp&&ltfn(version,low.semver))return!1}return!0}exports2.prerelease=prerelease;function prerelease(version,options){var parsed=parse6(version,options);return parsed&&parsed.prerelease.length?parsed.prerelease:null}exports2.intersects=intersects3;function intersects3(r1,r2,options){return r1=new Range(r1,options),r2=new Range(r2,options),r1.intersects(r2)}exports2.coerce=coerce2;function coerce2(version){if(version instanceof SemVer2)return version;if(typeof version!="string")return null;var match=version.match(safeRe[COERCE]);return match==null?null:parse6(match[1]+"."+(match[2]||"0")+"."+(match[3]||"0"))}}});var require_parse=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/parse.js"(exports2,module2){"use strict";var path9=require("path"),niceTry=require_src(),resolveCommand=require_resolveCommand(),escape=require_escape(),readShebang=require_readShebang(),semver=require_semver(),isWin2=process.platform==="win32",isExecutableRegExp=/\.(?:com|exe)$/i,isCmdShimRegExp=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i,supportsShellOption=niceTry(()=>semver.satisfies(process.version,"^4.8.0 || ^5.7.0 || >= 6.0.0",!0))||!1;function detectShebang(parsed){parsed.file=resolveCommand(parsed);let shebang=parsed.file&&readShebang(parsed.file);return shebang?(parsed.args.unshift(parsed.file),parsed.command=shebang,resolveCommand(parsed)):parsed.file}function parseNonShell(parsed){if(!isWin2)return parsed;let commandFile=detectShebang(parsed),needsShell=!isExecutableRegExp.test(commandFile);if(parsed.options.forceShell||needsShell){let needsDoubleEscapeMetaChars=isCmdShimRegExp.test(commandFile);parsed.command=path9.normalize(parsed.command),parsed.command=escape.command(parsed.command),parsed.args=parsed.args.map(arg=>escape.argument(arg,needsDoubleEscapeMetaChars));let shellCommand=[parsed.command].concat(parsed.args).join(" ");parsed.args=["/d","/s","/c",`"${shellCommand}"`],parsed.command=process.env.comspec||"cmd.exe",parsed.options.windowsVerbatimArguments=!0}return parsed}function parseShell(parsed){if(supportsShellOption)return parsed;let shellCommand=[parsed.command].concat(parsed.args).join(" ");return isWin2?(parsed.command=typeof parsed.options.shell=="string"?parsed.options.shell:process.env.comspec||"cmd.exe",parsed.args=["/d","/s","/c",`"${shellCommand}"`],parsed.options.windowsVerbatimArguments=!0):(typeof parsed.options.shell=="string"?parsed.command=parsed.options.shell:process.platform==="android"?parsed.command="/system/bin/sh":parsed.command="/bin/sh",parsed.args=["-c",shellCommand]),parsed}function parse6(command,args,options){args&&!Array.isArray(args)&&(options=args,args=null),args=args?args.slice(0):[],options=Object.assign({},options);let parsed={command,args,options,file:void 0,original:{command,args}};return options.shell?parseShell(parsed):parseNonShell(parsed)}module2.exports=parse6}});var require_enoent=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/enoent.js"(exports2,module2){"use strict";var isWin2=process.platform==="win32";function notFoundError(original,syscall){return Object.assign(new Error(`${syscall} ${original.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${syscall} ${original.command}`,path:original.command,spawnargs:original.args})}function hookChildProcess(cp,parsed){if(!isWin2)return;let originalEmit=cp.emit;cp.emit=function(name,arg1){if(name==="exit"){let err=verifyENOENT(arg1,parsed,"spawn");if(err)return originalEmit.call(cp,"error",err)}return originalEmit.apply(cp,arguments)}}function verifyENOENT(status,parsed){return isWin2&&status===1&&!parsed.file?notFoundError(parsed.original,"spawn"):null}function verifyENOENTSync(status,parsed){return isWin2&&status===1&&!parsed.file?notFoundError(parsed.original,"spawnSync"):null}module2.exports={hookChildProcess,verifyENOENT,verifyENOENTSync,notFoundError}}});var require_cross_spawn=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/index.js"(exports2,module2){"use strict";var cp=require("child_process"),parse6=require_parse(),enoent=require_enoent();function spawn3(command,args,options){let parsed=parse6(command,args,options),spawned=cp.spawn(parsed.command,parsed.args,parsed.options);return enoent.hookChildProcess(spawned,parsed),spawned}function spawnSync(command,args,options){let parsed=parse6(command,args,options),result=cp.spawnSync(parsed.command,parsed.args,parsed.options);return result.error=result.error||enoent.verifyENOENTSync(result.status,parsed),result}module2.exports=spawn3;module2.exports.spawn=spawn3;module2.exports.sync=spawnSync;module2.exports._parse=parse6;module2.exports._enoent=enoent}});var require_semver2=__commonJS({"../../node_modules/.pnpm/semver@6.3.1/node_modules/semver/semver.js"(exports2,module2){exports2=module2.exports=SemVer2;var debug2;typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?debug2=function(){var args=Array.prototype.slice.call(arguments,0);args.unshift("SEMVER"),console.log.apply(console,args)}:debug2=function(){};exports2.SEMVER_SPEC_VERSION="2.0.0";var MAX_LENGTH=256,MAX_SAFE_INTEGER=Number.MAX_SAFE_INTEGER||9007199254740991,MAX_SAFE_COMPONENT_LENGTH=16,MAX_SAFE_BUILD_LENGTH=MAX_LENGTH-6,re=exports2.re=[],safeRe=exports2.safeRe=[],src=exports2.src=[],t=exports2.tokens={},R=0;function tok(n){t[n]=R++}var LETTERDASHNUMBER="[a-zA-Z0-9-]",safeRegexReplacements=[["\\s",1],["\\d",MAX_LENGTH],[LETTERDASHNUMBER,MAX_SAFE_BUILD_LENGTH]];function makeSafeRe(value){for(var i2=0;i2<safeRegexReplacements.length;i2++){var token=safeRegexReplacements[i2][0],max=safeRegexReplacements[i2][1];value=value.split(token+"*").join(token+"{0,"+max+"}").split(token+"+").join(token+"{1,"+max+"}")}return value}tok("NUMERICIDENTIFIER");src[t.NUMERICIDENTIFIER]="0|[1-9]\\d*";tok("NUMERICIDENTIFIERLOOSE");src[t.NUMERICIDENTIFIERLOOSE]="\\d+";tok("NONNUMERICIDENTIFIER");src[t.NONNUMERICIDENTIFIER]="\\d*[a-zA-Z-]"+LETTERDASHNUMBER+"*";tok("MAINVERSION");src[t.MAINVERSION]="("+src[t.NUMERICIDENTIFIER]+")\\.("+src[t.NUMERICIDENTIFIER]+")\\.("+src[t.NUMERICIDENTIFIER]+")";tok("MAINVERSIONLOOSE");src[t.MAINVERSIONLOOSE]="("+src[t.NUMERICIDENTIFIERLOOSE]+")\\.("+src[t.NUMERICIDENTIFIERLOOSE]+")\\.("+src[t.NUMERICIDENTIFIERLOOSE]+")";tok("PRERELEASEIDENTIFIER");src[t.PRERELEASEIDENTIFIER]="(?:"+src[t.NUMERICIDENTIFIER]+"|"+src[t.NONNUMERICIDENTIFIER]+")";tok("PRERELEASEIDENTIFIERLOOSE");src[t.PRERELEASEIDENTIFIERLOOSE]="(?:"+src[t.NUMERICIDENTIFIERLOOSE]+"|"+src[t.NONNUMERICIDENTIFIER]+")";tok("PRERELEASE");src[t.PRERELEASE]="(?:-("+src[t.PRERELEASEIDENTIFIER]+"(?:\\."+src[t.PRERELEASEIDENTIFIER]+")*))";tok("PRERELEASELOOSE");src[t.PRERELEASELOOSE]="(?:-?("+src[t.PRERELEASEIDENTIFIERLOOSE]+"(?:\\."+src[t.PRERELEASEIDENTIFIERLOOSE]+")*))";tok("BUILDIDENTIFIER");src[t.BUILDIDENTIFIER]=LETTERDASHNUMBER+"+";tok("BUILD");src[t.BUILD]="(?:\\+("+src[t.BUILDIDENTIFIER]+"(?:\\."+src[t.BUILDIDENTIFIER]+")*))";tok("FULL");tok("FULLPLAIN");src[t.FULLPLAIN]="v?"+src[t.MAINVERSION]+src[t.PRERELEASE]+"?"+src[t.BUILD]+"?";src[t.FULL]="^"+src[t.FULLPLAIN]+"$";tok("LOOSEPLAIN");src[t.LOOSEPLAIN]="[v=\\s]*"+src[t.MAINVERSIONLOOSE]+src[t.PRERELEASELOOSE]+"?"+src[t.BUILD]+"?";tok("LOOSE");src[t.LOOSE]="^"+src[t.LOOSEPLAIN]+"$";tok("GTLT");src[t.GTLT]="((?:<|>)?=?)";tok("XRANGEIDENTIFIERLOOSE");src[t.XRANGEIDENTIFIERLOOSE]=src[t.NUMERICIDENTIFIERLOOSE]+"|x|X|\\*";tok("XRANGEIDENTIFIER");src[t.XRANGEIDENTIFIER]=src[t.NUMERICIDENTIFIER]+"|x|X|\\*";tok("XRANGEPLAIN");src[t.XRANGEPLAIN]="[v=\\s]*("+src[t.XRANGEIDENTIFIER]+")(?:\\.("+src[t.XRANGEIDENTIFIER]+")(?:\\.("+src[t.XRANGEIDENTIFIER]+")(?:"+src[t.PRERELEASE]+")?"+src[t.BUILD]+"?)?)?";tok("XRANGEPLAINLOOSE");src[t.XRANGEPLAINLOOSE]="[v=\\s]*("+src[t.XRANGEIDENTIFIERLOOSE]+")(?:\\.("+src[t.XRANGEIDENTIFIERLOOSE]+")(?:\\.("+src[t.XRANGEIDENTIFIERLOOSE]+")(?:"+src[t.PRERELEASELOOSE]+")?"+src[t.BUILD]+"?)?)?";tok("XRANGE");src[t.XRANGE]="^"+src[t.GTLT]+"\\s*"+src[t.XRANGEPLAIN]+"$";tok("XRANGELOOSE");src[t.XRANGELOOSE]="^"+src[t.GTLT]+"\\s*"+src[t.XRANGEPLAINLOOSE]+"$";tok("COERCE");src[t.COERCE]="(^|[^\\d])(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"})(?:\\.(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"}))?(?:\\.(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"}))?(?:$|[^\\d])";tok("COERCERTL");re[t.COERCERTL]=new RegExp(src[t.COERCE],"g");safeRe[t.COERCERTL]=new RegExp(makeSafeRe(src[t.COERCE]),"g");tok("LONETILDE");src[t.LONETILDE]="(?:~>?)";tok("TILDETRIM");src[t.TILDETRIM]="(\\s*)"+src[t.LONETILDE]+"\\s+";re[t.TILDETRIM]=new RegExp(src[t.TILDETRIM],"g");safeRe[t.TILDETRIM]=new RegExp(makeSafeRe(src[t.TILDETRIM]),"g");var tildeTrimReplace="$1~";tok("TILDE");src[t.TILDE]="^"+src[t.LONETILDE]+src[t.XRANGEPLAIN]+"$";tok("TILDELOOSE");src[t.TILDELOOSE]="^"+src[t.LONETILDE]+src[t.XRANGEPLAINLOOSE]+"$";tok("LONECARET");src[t.LONECARET]="(?:\\^)";tok("CARETTRIM");src[t.CARETTRIM]="(\\s*)"+src[t.LONECARET]+"\\s+";re[t.CARETTRIM]=new RegExp(src[t.CARETTRIM],"g");safeRe[t.CARETTRIM]=new RegExp(makeSafeRe(src[t.CARETTRIM]),"g");var caretTrimReplace="$1^";tok("CARET");src[t.CARET]="^"+src[t.LONECARET]+src[t.XRANGEPLAIN]+"$";tok("CARETLOOSE");src[t.CARETLOOSE]="^"+src[t.LONECARET]+src[t.XRANGEPLAINLOOSE]+"$";tok("COMPARATORLOOSE");src[t.COMPARATORLOOSE]="^"+src[t.GTLT]+"\\s*("+src[t.LOOSEPLAIN]+")$|^$";tok("COMPARATOR");src[t.COMPARATOR]="^"+src[t.GTLT]+"\\s*("+src[t.FULLPLAIN]+")$|^$";tok("COMPARATORTRIM");src[t.COMPARATORTRIM]="(\\s*)"+src[t.GTLT]+"\\s*("+src[t.LOOSEPLAIN]+"|"+src[t.XRANGEPLAIN]+")";re[t.COMPARATORTRIM]=new RegExp(src[t.COMPARATORTRIM],"g");safeRe[t.COMPARATORTRIM]=new RegExp(makeSafeRe(src[t.COMPARATORTRIM]),"g");var comparatorTrimReplace="$1$2$3";tok("HYPHENRANGE");src[t.HYPHENRANGE]="^\\s*("+src[t.XRANGEPLAIN]+")\\s+-\\s+("+src[t.XRANGEPLAIN]+")\\s*$";tok("HYPHENRANGELOOSE");src[t.HYPHENRANGELOOSE]="^\\s*("+src[t.XRANGEPLAINLOOSE]+")\\s+-\\s+("+src[t.XRANGEPLAINLOOSE]+")\\s*$";tok("STAR");src[t.STAR]="(<|>)?=?\\s*\\*";for(i=0;i<R;i++)debug2(i,src[i]),re[i]||(re[i]=new RegExp(src[i]),safeRe[i]=new RegExp(makeSafeRe(src[i])));var i;exports2.parse=parse6;function parse6(version,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),version instanceof SemVer2)return version;if(typeof version!="string"||version.length>MAX_LENGTH)return null;var r=options.loose?safeRe[t.LOOSE]:safeRe[t.FULL];if(!r.test(version))return null;try{return new SemVer2(version,options)}catch{return null}}exports2.valid=valid;function valid(version,options){var v=parse6(version,options);return v?v.version:null}exports2.clean=clean;function clean(version,options){var s=parse6(version.trim().replace(/^[=v]+/,""),options);return s?s.version:null}exports2.SemVer=SemVer2;function SemVer2(version,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),version instanceof SemVer2){if(version.loose===options.loose)return version;version=version.version}else if(typeof version!="string")throw new TypeError("Invalid Version: "+version);if(version.length>MAX_LENGTH)throw new TypeError("version is longer than "+MAX_LENGTH+" characters");if(!(this instanceof SemVer2))return new SemVer2(version,options);debug2("SemVer",version,options),this.options=options,this.loose=!!options.loose;var m=version.trim().match(options.loose?safeRe[t.LOOSE]:safeRe[t.FULL]);if(!m)throw new TypeError("Invalid Version: "+version);if(this.raw=version,this.major=+m[1],this.minor=+m[2],this.patch=+m[3],this.major>MAX_SAFE_INTEGER||this.major<0)throw new TypeError("Invalid major version");if(this.minor>MAX_SAFE_INTEGER||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>MAX_SAFE_INTEGER||this.patch<0)throw new TypeError("Invalid patch version");m[4]?this.prerelease=m[4].split(".").map(function(id){if(/^[0-9]+$/.test(id)){var num=+id;if(num>=0&&num<MAX_SAFE_INTEGER)return num}return id}):this.prerelease=[],this.build=m[5]?m[5].split("."):[],this.format()}SemVer2.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version};SemVer2.prototype.toString=function(){return this.version};SemVer2.prototype.compare=function(other){return debug2("SemVer.compare",this.version,this.options,other),other instanceof SemVer2||(other=new SemVer2(other,this.options)),this.compareMain(other)||this.comparePre(other)};SemVer2.prototype.compareMain=function(other){return other instanceof SemVer2||(other=new SemVer2(other,this.options)),compareIdentifiers(this.major,other.major)||compareIdentifiers(this.minor,other.minor)||compareIdentifiers(this.patch,other.patch)};SemVer2.prototype.comparePre=function(other){if(other instanceof SemVer2||(other=new SemVer2(other,this.options)),this.prerelease.length&&!other.prerelease.length)return-1;if(!this.prerelease.length&&other.prerelease.length)return 1;if(!this.prerelease.length&&!other.prerelease.length)return 0;var i2=0;do{var a=this.prerelease[i2],b=other.prerelease[i2];if(debug2("prerelease compare",i2,a,b),a===void 0&&b===void 0)return 0;if(b===void 0)return 1;if(a===void 0)return-1;if(a===b)continue;return compareIdentifiers(a,b)}while(++i2)};SemVer2.prototype.compareBuild=function(other){other instanceof SemVer2||(other=new SemVer2(other,this.options));var i2=0;do{var a=this.build[i2],b=other.build[i2];if(debug2("prerelease compare",i2,a,b),a===void 0&&b===void 0)return 0;if(b===void 0)return 1;if(a===void 0)return-1;if(a===b)continue;return compareIdentifiers(a,b)}while(++i2)};SemVer2.prototype.inc=function(release,identifier){switch(release){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",identifier);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",identifier);break;case"prepatch":this.prerelease.length=0,this.inc("patch",identifier),this.inc("pre",identifier);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",identifier),this.inc("pre",identifier);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{for(var i2=this.prerelease.length;--i2>=0;)typeof this.prerelease[i2]=="number"&&(this.prerelease[i2]++,i2=-2);i2===-1&&this.prerelease.push(0)}identifier&&(this.prerelease[0]===identifier?isNaN(this.prerelease[1])&&(this.prerelease=[identifier,0]):this.prerelease=[identifier,0]);break;default:throw new Error("invalid increment argument: "+release)}return this.format(),this.raw=this.version,this};exports2.inc=inc;function inc(version,release,loose,identifier){typeof loose=="string"&&(identifier=loose,loose=void 0);try{return new SemVer2(version,loose).inc(release,identifier).version}catch{return null}}exports2.diff=diff;function diff(version1,version2){if(eq(version1,version2))return null;var v1=parse6(version1),v2=parse6(version2),prefix="";if(v1.prerelease.length||v2.prerelease.length){prefix="pre";var defaultResult="prerelease"}for(var key in v1)if((key==="major"||key==="minor"||key==="patch")&&v1[key]!==v2[key])return prefix+key;return defaultResult}exports2.compareIdentifiers=compareIdentifiers;var numeric=/^[0-9]+$/;function compareIdentifiers(a,b){var anum=numeric.test(a),bnum=numeric.test(b);return anum&&bnum&&(a=+a,b=+b),a===b?0:anum&&!bnum?-1:bnum&&!anum?1:a<b?-1:1}exports2.rcompareIdentifiers=rcompareIdentifiers;function rcompareIdentifiers(a,b){return compareIdentifiers(b,a)}exports2.major=major;function major(a,loose){return new SemVer2(a,loose).major}exports2.minor=minor;function minor(a,loose){return new SemVer2(a,loose).minor}exports2.patch=patch;function patch(a,loose){return new SemVer2(a,loose).patch}exports2.compare=compare;function compare(a,b,loose){return new SemVer2(a,loose).compare(new SemVer2(b,loose))}exports2.compareLoose=compareLoose;function compareLoose(a,b){return compare(a,b,!0)}exports2.compareBuild=compareBuild;function compareBuild(a,b,loose){var versionA=new SemVer2(a,loose),versionB=new SemVer2(b,loose);return versionA.compare(versionB)||versionA.compareBuild(versionB)}exports2.rcompare=rcompare;function rcompare(a,b,loose){return compare(b,a,loose)}exports2.sort=sort;function sort(list,loose){return list.sort(function(a,b){return exports2.compareBuild(a,b,loose)})}exports2.rsort=rsort;function rsort(list,loose){return list.sort(function(a,b){return exports2.compareBuild(b,a,loose)})}exports2.gt=gt;function gt(a,b,loose){return compare(a,b,loose)>0}exports2.lt=lt;function lt(a,b,loose){return compare(a,b,loose)<0}exports2.eq=eq;function eq(a,b,loose){return compare(a,b,loose)===0}exports2.neq=neq;function neq(a,b,loose){return compare(a,b,loose)!==0}exports2.gte=gte2;function gte2(a,b,loose){return compare(a,b,loose)>=0}exports2.lte=lte;function lte(a,b,loose){return compare(a,b,loose)<=0}exports2.cmp=cmp;function cmp(a,op,b,loose){switch(op){case"===":return typeof a=="object"&&(a=a.version),typeof b=="object"&&(b=b.version),a===b;case"!==":return typeof a=="object"&&(a=a.version),typeof b=="object"&&(b=b.version),a!==b;case"":case"=":case"==":return eq(a,b,loose);case"!=":return neq(a,b,loose);case">":return gt(a,b,loose);case">=":return gte2(a,b,loose);case"<":return lt(a,b,loose);case"<=":return lte(a,b,loose);default:throw new TypeError("Invalid operator: "+op)}}exports2.Comparator=Comparator;function Comparator(comp,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),comp instanceof Comparator){if(comp.loose===!!options.loose)return comp;comp=comp.value}if(!(this instanceof Comparator))return new Comparator(comp,options);comp=comp.trim().split(/\s+/).join(" "),debug2("comparator",comp,options),this.options=options,this.loose=!!options.loose,this.parse(comp),this.semver===ANY?this.value="":this.value=this.operator+this.semver.version,debug2("comp",this)}var ANY={};Comparator.prototype.parse=function(comp){var r=this.options.loose?safeRe[t.COMPARATORLOOSE]:safeRe[t.COMPARATOR],m=comp.match(r);if(!m)throw new TypeError("Invalid comparator: "+comp);this.operator=m[1]!==void 0?m[1]:"",this.operator==="="&&(this.operator=""),m[2]?this.semver=new SemVer2(m[2],this.options.loose):this.semver=ANY};Comparator.prototype.toString=function(){return this.value};Comparator.prototype.test=function(version){if(debug2("Comparator.test",version,this.options.loose),this.semver===ANY||version===ANY)return!0;if(typeof version=="string")try{version=new SemVer2(version,this.options)}catch{return!1}return cmp(version,this.operator,this.semver,this.options)};Comparator.prototype.intersects=function(comp,options){if(!(comp instanceof Comparator))throw new TypeError("a Comparator is required");(!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1});var rangeTmp;if(this.operator==="")return this.value===""?!0:(rangeTmp=new Range(comp.value,options),satisfies2(this.value,rangeTmp,options));if(comp.operator==="")return comp.value===""?!0:(rangeTmp=new Range(this.value,options),satisfies2(comp.semver,rangeTmp,options));var sameDirectionIncreasing=(this.operator===">="||this.operator===">")&&(comp.operator===">="||comp.operator===">"),sameDirectionDecreasing=(this.operator==="<="||this.operator==="<")&&(comp.operator==="<="||comp.operator==="<"),sameSemVer=this.semver.version===comp.semver.version,differentDirectionsInclusive=(this.operator===">="||this.operator==="<=")&&(comp.operator===">="||comp.operator==="<="),oppositeDirectionsLessThan=cmp(this.semver,"<",comp.semver,options)&&(this.operator===">="||this.operator===">")&&(comp.operator==="<="||comp.operator==="<"),oppositeDirectionsGreaterThan=cmp(this.semver,">",comp.semver,options)&&(this.operator==="<="||this.operator==="<")&&(comp.operator===">="||comp.operator===">");return sameDirectionIncreasing||sameDirectionDecreasing||sameSemVer&&differentDirectionsInclusive||oppositeDirectionsLessThan||oppositeDirectionsGreaterThan};exports2.Range=Range;function Range(range,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),range instanceof Range)return range.loose===!!options.loose&&range.includePrerelease===!!options.includePrerelease?range:new Range(range.raw,options);if(range instanceof Comparator)return new Range(range.value,options);if(!(this instanceof Range))return new Range(range,options);if(this.options=options,this.loose=!!options.loose,this.includePrerelease=!!options.includePrerelease,this.raw=range.trim().split(/\s+/).join(" "),this.set=this.raw.split("||").map(function(range2){return this.parseRange(range2.trim())},this).filter(function(c){return c.length}),!this.set.length)throw new TypeError("Invalid SemVer Range: "+this.raw);this.format()}Range.prototype.format=function(){return this.range=this.set.map(function(comps){return comps.join(" ").trim()}).join("||").trim(),this.range};Range.prototype.toString=function(){return this.range};Range.prototype.parseRange=function(range){var loose=this.options.loose,hr=loose?safeRe[t.HYPHENRANGELOOSE]:safeRe[t.HYPHENRANGE];range=range.replace(hr,hyphenReplace),debug2("hyphen replace",range),range=range.replace(safeRe[t.COMPARATORTRIM],comparatorTrimReplace),debug2("comparator trim",range,safeRe[t.COMPARATORTRIM]),range=range.replace(safeRe[t.TILDETRIM],tildeTrimReplace),range=range.replace(safeRe[t.CARETTRIM],caretTrimReplace),range=range.split(/\s+/).join(" ");var compRe=loose?safeRe[t.COMPARATORLOOSE]:safeRe[t.COMPARATOR],set=range.split(" ").map(function(comp){return parseComparator(comp,this.options)},this).join(" ").split(/\s+/);return this.options.loose&&(set=set.filter(function(comp){return!!comp.match(compRe)})),set=set.map(function(comp){return new Comparator(comp,this.options)},this),set};Range.prototype.intersects=function(range,options){if(!(range instanceof Range))throw new TypeError("a Range is required");return this.set.some(function(thisComparators){return isSatisfiable(thisComparators,options)&&range.set.some(function(rangeComparators){return isSatisfiable(rangeComparators,options)&&thisComparators.every(function(thisComparator){return rangeComparators.every(function(rangeComparator){return thisComparator.intersects(rangeComparator,options)})})})})};function isSatisfiable(comparators,options){for(var result=!0,remainingComparators=comparators.slice(),testComparator=remainingComparators.pop();result&&remainingComparators.length;)result=remainingComparators.every(function(otherComparator){return testComparator.intersects(otherComparator,options)}),testComparator=remainingComparators.pop();return result}exports2.toComparators=toComparators;function toComparators(range,options){return new Range(range,options).set.map(function(comp){return comp.map(function(c){return c.value}).join(" ").trim().split(" ")})}function parseComparator(comp,options){return debug2("comp",comp,options),comp=replaceCarets(comp,options),debug2("caret",comp),comp=replaceTildes(comp,options),debug2("tildes",comp),comp=replaceXRanges(comp,options),debug2("xrange",comp),comp=replaceStars(comp,options),debug2("stars",comp),comp}function isX(id){return!id||id.toLowerCase()==="x"||id==="*"}function replaceTildes(comp,options){return comp.trim().split(/\s+/).map(function(comp2){return replaceTilde(comp2,options)}).join(" ")}function replaceTilde(comp,options){var r=options.loose?safeRe[t.TILDELOOSE]:safeRe[t.TILDE];return comp.replace(r,function(_,M,m,p,pr){debug2("tilde",comp,_,M,m,p,pr);var ret;return isX(M)?ret="":isX(m)?ret=">="+M+".0.0 <"+(+M+1)+".0.0":isX(p)?ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0":pr?(debug2("replaceTilde pr",pr),ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+(+m+1)+".0"):ret=">="+M+"."+m+"."+p+" <"+M+"."+(+m+1)+".0",debug2("tilde return",ret),ret})}function replaceCarets(comp,options){return comp.trim().split(/\s+/).map(function(comp2){return replaceCaret(comp2,options)}).join(" ")}function replaceCaret(comp,options){debug2("caret",comp,options);var r=options.loose?safeRe[t.CARETLOOSE]:safeRe[t.CARET];return comp.replace(r,function(_,M,m,p,pr){debug2("caret",comp,_,M,m,p,pr);var ret;return isX(M)?ret="":isX(m)?ret=">="+M+".0.0 <"+(+M+1)+".0.0":isX(p)?M==="0"?ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+".0 <"+(+M+1)+".0.0":pr?(debug2("replaceCaret pr",pr),M==="0"?m==="0"?ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+m+"."+(+p+1):ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+"."+p+"-"+pr+" <"+(+M+1)+".0.0"):(debug2("no pr"),M==="0"?m==="0"?ret=">="+M+"."+m+"."+p+" <"+M+"."+m+"."+(+p+1):ret=">="+M+"."+m+"."+p+" <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+"."+p+" <"+(+M+1)+".0.0"),debug2("caret return",ret),ret})}function replaceXRanges(comp,options){return debug2("replaceXRanges",comp,options),comp.split(/\s+/).map(function(comp2){return replaceXRange(comp2,options)}).join(" ")}function replaceXRange(comp,options){comp=comp.trim();var r=options.loose?safeRe[t.XRANGELOOSE]:safeRe[t.XRANGE];return comp.replace(r,function(ret,gtlt,M,m,p,pr){debug2("xRange",comp,ret,gtlt,M,m,p,pr);var xM=isX(M),xm=xM||isX(m),xp=xm||isX(p),anyX=xp;return gtlt==="="&&anyX&&(gtlt=""),pr=options.includePrerelease?"-0":"",xM?gtlt===">"||gtlt==="<"?ret="<0.0.0-0":ret="*":gtlt&&anyX?(xm&&(m=0),p=0,gtlt===">"?(gtlt=">=",xm?(M=+M+1,m=0,p=0):(m=+m+1,p=0)):gtlt==="<="&&(gtlt="<",xm?M=+M+1:m=+m+1),ret=gtlt+M+"."+m+"."+p+pr):xm?ret=">="+M+".0.0"+pr+" <"+(+M+1)+".0.0"+pr:xp&&(ret=">="+M+"."+m+".0"+pr+" <"+M+"."+(+m+1)+".0"+pr),debug2("xRange return",ret),ret})}function replaceStars(comp,options){return debug2("replaceStars",comp,options),comp.trim().replace(safeRe[t.STAR],"")}function hyphenReplace($0,from,fM,fm,fp,fpr,fb,to,tM,tm,tp,tpr,tb){return isX(fM)?from="":isX(fm)?from=">="+fM+".0.0":isX(fp)?from=">="+fM+"."+fm+".0":from=">="+from,isX(tM)?to="":isX(tm)?to="<"+(+tM+1)+".0.0":isX(tp)?to="<"+tM+"."+(+tm+1)+".0":tpr?to="<="+tM+"."+tm+"."+tp+"-"+tpr:to="<="+to,(from+" "+to).trim()}Range.prototype.test=function(version){if(!version)return!1;if(typeof version=="string")try{version=new SemVer2(version,this.options)}catch{return!1}for(var i2=0;i2<this.set.length;i2++)if(testSet(this.set[i2],version,this.options))return!0;return!1};function testSet(set,version,options){for(var i2=0;i2<set.length;i2++)if(!set[i2].test(version))return!1;if(version.prerelease.length&&!options.includePrerelease){for(i2=0;i2<set.length;i2++)if(debug2(set[i2].semver),set[i2].semver!==ANY&&set[i2].semver.prerelease.length>0){var allowed=set[i2].semver;if(allowed.major===version.major&&allowed.minor===version.minor&&allowed.patch===version.patch)return!0}return!1}return!0}exports2.satisfies=satisfies2;function satisfies2(version,range,options){try{range=new Range(range,options)}catch{return!1}return range.test(version)}exports2.maxSatisfying=maxSatisfying;function maxSatisfying(versions,range,options){var max=null,maxSV=null;try{var rangeObj=new Range(range,options)}catch{return null}return versions.forEach(function(v){rangeObj.test(v)&&(!max||maxSV.compare(v)===-1)&&(max=v,maxSV=new SemVer2(max,options))}),max}exports2.minSatisfying=minSatisfying;function minSatisfying(versions,range,options){var min=null,minSV=null;try{var rangeObj=new Range(range,options)}catch{return null}return versions.forEach(function(v){rangeObj.test(v)&&(!min||minSV.compare(v)===1)&&(min=v,minSV=new SemVer2(min,options))}),min}exports2.minVersion=minVersion2;function minVersion2(range,loose){range=new Range(range,loose);var minver=new SemVer2("0.0.0");if(range.test(minver)||(minver=new SemVer2("0.0.0-0"),range.test(minver)))return minver;minver=null;for(var i2=0;i2<range.set.length;++i2){var comparators=range.set[i2];comparators.forEach(function(comparator){var compver=new SemVer2(comparator.semver.version);switch(comparator.operator){case">":compver.prerelease.length===0?compver.patch++:compver.prerelease.push(0),compver.raw=compver.format();case"":case">=":(!minver||gt(minver,compver))&&(minver=compver);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+comparator.operator)}})}return minver&&range.test(minver)?minver:null}exports2.validRange=validRange3;function validRange3(range,options){try{return new Range(range,options).range||"*"}catch{return null}}exports2.ltr=ltr;function ltr(version,range,options){return outside(version,range,"<",options)}exports2.gtr=gtr;function gtr(version,range,options){return outside(version,range,">",options)}exports2.outside=outside;function outside(version,range,hilo,options){version=new SemVer2(version,options),range=new Range(range,options);var gtfn,ltefn,ltfn,comp,ecomp;switch(hilo){case">":gtfn=gt,ltefn=lte,ltfn=lt,comp=">",ecomp=">=";break;case"<":gtfn=lt,ltefn=gte2,ltfn=gt,comp="<",ecomp="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(satisfies2(version,range,options))return!1;for(var i2=0;i2<range.set.length;++i2){var comparators=range.set[i2],high=null,low=null;if(comparators.forEach(function(comparator){comparator.semver===ANY&&(comparator=new Comparator(">=0.0.0")),high=high||comparator,low=low||comparator,gtfn(comparator.semver,high.semver,options)?high=comparator:ltfn(comparator.semver,low.semver,options)&&(low=comparator)}),high.operator===comp||high.operator===ecomp||(!low.operator||low.operator===comp)&&ltefn(version,low.semver))return!1;if(low.operator===ecomp&&ltfn(version,low.semver))return!1}return!0}exports2.prerelease=prerelease;function prerelease(version,options){var parsed=parse6(version,options);return parsed&&parsed.prerelease.length?parsed.prerelease:null}exports2.intersects=intersects3;function intersects3(r1,r2,options){return r1=new Range(r1,options),r2=new Range(r2,options),r1.intersects(r2)}exports2.coerce=coerce2;function coerce2(version,options){if(version instanceof SemVer2)return version;if(typeof version=="number"&&(version=String(version)),typeof version!="string")return null;options=options||{};var match=null;if(!options.rtl)match=version.match(safeRe[t.COERCE]);else{for(var next;(next=safeRe[t.COERCERTL].exec(version))&&(!match||match.index+match[0].length!==version.length);)(!match||next.index+next[0].length!==match.index+match[0].length)&&(match=next),safeRe[t.COERCERTL].lastIndex=next.index+next[1].length+next[2].length;safeRe[t.COERCERTL].lastIndex=-1}return match===null?null:parse6(match[2]+"."+(match[3]||"0")+"."+(match[4]||"0"),options)}}});var types_exports={};__export(types_exports,{BunVersion:()=>BunVersion,JOB_TRIGGERS:()=>JOB_TRIGGERS,NodeVersion:()=>NodeVersion,Version:()=>Version,getReportedServiceType:()=>getReportedServiceType,getServiceQueueTopicConfigs:()=>getServiceQueueTopicConfigs,getServiceQueueTopics:()=>getServiceQueueTopics,isExperimentalService:()=>isExperimentalService,isExperimentalServiceV2:()=>isExperimentalServiceV2,isQueueBackedService:()=>isQueueBackedService,isQueueTriggeredService:()=>isQueueTriggeredService,isScheduleTriggeredService:()=>isScheduleTriggeredService,isWorkflowTriggeredService:()=>isWorkflowTriggeredService});function isExperimentalService(service){return service.schema==="experimentalServices"}function isExperimentalServiceV2(service){return service.schema==="experimentalServicesV2"}function getServiceQueueTopicConfigs(config){return Array.isArray(config.topics)&&config.topics.length>0?typeof config.topics[0]=="string"?config.topics.map(topic=>({topic})):config.topics:config.type==="worker"?[{topic:"default"}]:[]}function getServiceQueueTopics(config){return getServiceQueueTopicConfigs(config).map(topic=>topic.topic)}function isQueueTriggeredService(service){return service.type==="worker"||service.type==="job"&&service.trigger==="queue"}function isScheduleTriggeredService(service){return service.type==="cron"||service.type==="job"&&service.trigger==="schedule"}function isWorkflowTriggeredService(service){return service.type==="job"&&service.trigger==="workflow"}function isQueueBackedService(service){return isQueueTriggeredService(service)||isWorkflowTriggeredService(service)}function getReportedServiceType(service){switch(service.type){case"web":return"web";case"cron":return"schedule";case"worker":return"queue";case"job":return service.trigger==="schedule"?"schedule":service.trigger==="queue"?"queue":service.trigger==="workflow"?"workflow":void 0;default:return}}var Version,NodeVersion,BunVersion,JOB_TRIGGERS,init_types=__esm({"src/types.ts"(){"use strict";Version=class{constructor(version){this.major=version.major,this.minor=version.minor,this.range=version.range,this.runtime=version.runtime,this.discontinueDate=version.discontinueDate}get state(){return this.discontinueDate&&this.discontinueDate.getTime()<=Date.now()?"discontinued":this.discontinueDate?"deprecated":"active"}get formattedDate(){return this.discontinueDate&&this.discontinueDate.toISOString().split("T")[0]}},NodeVersion=class extends Version{},BunVersion=class extends Version{},JOB_TRIGGERS=["queue","schedule","workflow"]}});var node_version_exports={};__export(node_version_exports,{BUN_VERSIONS:()=>BUN_VERSIONS,NODE_VERSIONS:()=>NODE_VERSIONS,getAvailableNodeVersions:()=>getAvailableNodeVersions,getDiscontinuedNodeVersions:()=>getDiscontinuedNodeVersions,getLatestNodeVersion:()=>getLatestNodeVersion,getNodeVersionByMajor:()=>getNodeVersionByMajor,getSupportedBunVersion:()=>getSupportedBunVersion,getSupportedNodeVersion:()=>getSupportedNodeVersion,isBunVersion:()=>isBunVersion});function getNodeVersionByMajor(major){return getOptions().find(v=>v.major===major)}function getOptions(){return NODE_VERSIONS}function isNodeVersionAvailable(version){return(0,import_fs.statSync)(`/node${version.major}`,{throwIfNoEntry:!1})?.isDirectory()??!1}function getAvailableNodeVersions(){return getOptions().filter(v=>v.major>=18).filter(isNodeVersionAvailable).map(n=>n.major)}function getHint(isAuto=!1,availableVersions){let{major,range}=getLatestNodeVersion(availableVersions);return isAuto?`Please set Node.js Version to ${range} in your Project Settings to use Node.js ${major}.`:`Please set "engines": { "node": "${range}" } in your \`package.json\` file to use Node.js ${major}.`}function getLatestNodeVersion(availableVersions){let all=getOptions();if(availableVersions){for(let version of all)for(let major of availableVersions)if(version.major===major)return version}return all[0]}function getDiscontinuedNodeVersions(){return getOptions().filter(version=>version.state==="discontinued")}async function getSupportedNodeVersion(engineRange,isAuto=!1,availableVersions){let selection;if(engineRange&&!((0,import_semver.validRange)(engineRange)&&getOptions().some(o=>(selection=o,(0,import_semver.intersects)(o.range,engineRange)&&(availableVersions?.length?availableVersions.includes(o.major):!0)))))throw new NowBuildError({code:"BUILD_UTILS_NODE_VERSION_INVALID",link:"https://vercel.link/node-version",message:`Found invalid or discontinued Node.js Version: "${engineRange}". ${getHint(isAuto,availableVersions)}`});if(selection||(selection=getLatestNodeVersion(availableVersions)),selection.state==="discontinued"){let intro=`Node.js Version "${selection.range}" is discontinued and must be upgraded.`;throw new NowBuildError({code:"BUILD_UTILS_NODE_VERSION_DISCONTINUED",link:"https://vercel.link/node-version",message:`${intro} ${getHint(isAuto)}`})}if(debug(`Selected Node.js ${selection.range}`),selection.state==="deprecated"){let d=selection.formattedDate;console.warn(d?`Error: Node.js version ${selection.range} is deprecated. Deployments created on or after ${d} will fail to build. ${getHint(isAuto)}`:`Error: Node.js version ${selection.range} is deprecated. ${getHint(isAuto)}`)}return selection}function getSupportedBunVersion(engineRange){if((0,import_semver.validRange)(engineRange)){let selected=BUN_VERSIONS.find(version=>(0,import_semver.intersects)(version.range,engineRange)?version.minor===void 0?!0:!(0,import_semver.intersects)(`<${version.major}.${version.minor}.0`,engineRange):!1);if(selected)return new BunVersion({major:selected.major,minor:selected.minor,range:selected.range,runtime:selected.runtime})}throw new NowBuildError({message:`Found invalid Bun Version: "${engineRange}".`,code:"BUILD_UTILS_BUN_VERSION_INVALID"})}function isBunVersion(version){return version.runtime.startsWith("bun")}var import_fs,import_semver,NODE_VERSIONS,BUN_VERSIONS,init_node_version=__esm({"src/fs/node-version.ts"(){"use strict";import_fs=require("fs"),import_semver=__toESM(require_semver2());init_types();init_errors();init_debug();NODE_VERSIONS=[new NodeVersion({major:24,range:"24.x",runtime:"nodejs24.x"}),new NodeVersion({major:22,range:"22.x",runtime:"nodejs22.x"}),new NodeVersion({major:20,range:"20.x",runtime:"nodejs20.x",discontinueDate:new Date("2026-10-01")}),new NodeVersion({major:18,range:"18.x",runtime:"nodejs18.x",discontinueDate:new Date("2025-09-01")}),new NodeVersion({major:16,range:"16.x",runtime:"nodejs16.x",discontinueDate:new Date("2025-02-03")}),new NodeVersion({major:14,range:"14.x",runtime:"nodejs14.x",discontinueDate:new Date("2023-08-15")}),new NodeVersion({major:12,range:"12.x",runtime:"nodejs12.x",discontinueDate:new Date("2022-10-03")}),new NodeVersion({major:10,range:"10.x",runtime:"nodejs10.x",discontinueDate:new Date("2021-04-20")}),new NodeVersion({major:8,range:"8.10.x",runtime:"nodejs8.10",discontinueDate:new Date("2020-01-06")})],BUN_VERSIONS=[new BunVersion({major:1,minor:4,range:"1.4.x",runtime:"bun1.4.x"}),new BunVersion({major:1,range:"1.x",runtime:"bun1.x"})]}});var require_common2=__commonJS({"../../node_modules/.pnpm/js-yaml@3.13.1/node_modules/js-yaml/lib/js-yaml/common.js"(exports2,module2){"use strict";function isNothing(subject){return typeof subject>"u"||subject===null}function isObject(subject){return typeof subject=="object"&&subject!==null}function toArray(sequence){return Array.isArray(sequence)?sequence:isNothing(sequence)?[]:[sequence]}function extend(target,source){var index,length,key,sourceKeys;if(source)for(sourceKeys=Object.keys(source),index=0,length=sourceKeys.length;index<length;index+=1)key=sourceKeys[index],target[key]=source[key];return target}function repeat(string,count){var result="",cycle;for(cycle=0;cycle<count;cycle+=1)result+=string;return result}function isNegativeZero(number){return number===0&&Number.NEGATIVE_INFINITY===1/number}module2.exports.isNothing=isNothing;module2.exports.isObject=isObject;module2.exports.toArray=toArray;module2.exports.repeat=repeat;module2.exports.isNegativeZero=isNegativeZero;module2.exports.extend=extend}});var require_exception=__commonJS({"../../node_modules/.pnpm/js-yaml@3.13.1/node_modules/js-yaml/lib/js-yaml/exception.js"(exports2,module2){"use strict";function YAMLException(reason,mark){Error.call(this),this.name="YAMLException",this.reason=reason,this.mark=mark,this.message=(this.reason||"(unknown reason)")+(this.mark?" "+this.mark.toString():""),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}YAMLException.prototype=Object.create(Error.prototype);YAMLException.prototype.constructor=YAMLException;YAMLException.prototype.toString=function(compact){var result=this.name+": ";return result+=this.reason||"(unknown reason)",!compact&&this.mark&&(result+=" "+this.mark.toString()),result};module2.exports=YAMLException}});var require_mark=__commonJS({"../../node_modules/.pnpm/js-yaml@3.13.1/node_modules/js-yaml/lib/js-yaml/mark.js"(exports2,module2){"use strict";var common=require_common2();function Mark(name,buffer,position,line,column){this.name=name,this.buffer=buffer,this.position=position,this.line=line,this.column=column}Mark.prototype.getSnippet=function(indent,maxLength){var head,start,tail,end,snippet;if(!this.buffer)return null;for(indent=indent||4,maxLength=maxLength||75,head="",start=this.position;start>0&&`\0\r
15
+ See: https://github.com/isaacs/node-glob/issues/167`);if(!(this instanceof GlobSync))return new GlobSync(pattern,options);if(setopts(this,pattern,options),this.noprocess)return this;var n=this.minimatch.set.length;this.matches=new Array(n);for(var i=0;i<n;i++)this._process(this.minimatch.set[i],i,!1);this._finish()}GlobSync.prototype._finish=function(){if(assert9.ok(this instanceof GlobSync),this.realpath){var self2=this;this.matches.forEach(function(matchset,index){var set=self2.matches[index]=Object.create(null);for(var p in matchset)try{p=self2._makeAbs(p);var real=rp.realpathSync(p,self2.realpathCache);set[real]=!0}catch(er){if(er.syscall==="stat")set[self2._makeAbs(p)]=!0;else throw er}})}common.finish(this)};GlobSync.prototype._process=function(pattern,index,inGlobStar){assert9.ok(this instanceof GlobSync);for(var n=0;typeof pattern[n]=="string";)n++;var prefix;switch(n){case pattern.length:this._processSimple(pattern.join("/"),index);return;case 0:prefix=null;break;default:prefix=pattern.slice(0,n).join("/");break}var remain=pattern.slice(n),read;prefix===null?read=".":((isAbsolute(prefix)||isAbsolute(pattern.map(function(p){return typeof p=="string"?p:"[*]"}).join("/")))&&(!prefix||!isAbsolute(prefix))&&(prefix="/"+prefix),read=prefix);var abs=this._makeAbs(read);if(!childrenIgnored(this,read)){var isGlobStar=remain[0]===minimatch3.GLOBSTAR;isGlobStar?this._processGlobStar(prefix,read,abs,remain,index,inGlobStar):this._processReaddir(prefix,read,abs,remain,index,inGlobStar)}};GlobSync.prototype._processReaddir=function(prefix,read,abs,remain,index,inGlobStar){var entries=this._readdir(abs,inGlobStar);if(entries){for(var pn=remain[0],negate=!!this.minimatch.negate,rawGlob=pn._glob,dotOk=this.dot||rawGlob.charAt(0)===".",matchedEntries=[],i=0;i<entries.length;i++){var e=entries[i];if(e.charAt(0)!=="."||dotOk){var m;negate&&!prefix?m=!e.match(pn):m=e.match(pn),m&&matchedEntries.push(e)}}var len=matchedEntries.length;if(len!==0){if(remain.length===1&&!this.mark&&!this.stat){this.matches[index]||(this.matches[index]=Object.create(null));for(var i=0;i<len;i++){var e=matchedEntries[i];prefix&&(prefix.slice(-1)!=="/"?e=prefix+"/"+e:e=prefix+e),e.charAt(0)==="/"&&!this.nomount&&(e=path9.join(this.root,e)),this._emitMatch(index,e)}return}remain.shift();for(var i=0;i<len;i++){var e=matchedEntries[i],newPattern;prefix?newPattern=[prefix,e]:newPattern=[e],this._process(newPattern.concat(remain),index,inGlobStar)}}}};GlobSync.prototype._emitMatch=function(index,e){if(!isIgnored(this,e)){var abs=this._makeAbs(e);if(this.mark&&(e=this._mark(e)),this.absolute&&(e=abs),!this.matches[index][e]){if(this.nodir){var c=this.cache[abs];if(c==="DIR"||Array.isArray(c))return}this.matches[index][e]=!0,this.stat&&this._stat(e)}}};GlobSync.prototype._readdirInGlobStar=function(abs){if(this.follow)return this._readdir(abs,!1);var entries,lstat4,stat2;try{lstat4=this.fs.lstatSync(abs)}catch(er){if(er.code==="ENOENT")return null}var isSym=lstat4&&lstat4.isSymbolicLink();return this.symlinks[abs]=isSym,!isSym&&lstat4&&!lstat4.isDirectory()?this.cache[abs]="FILE":entries=this._readdir(abs,!1),entries};GlobSync.prototype._readdir=function(abs,inGlobStar){var entries;if(inGlobStar&&!ownProp(this.symlinks,abs))return this._readdirInGlobStar(abs);if(ownProp(this.cache,abs)){var c=this.cache[abs];if(!c||c==="FILE")return null;if(Array.isArray(c))return c}try{return this._readdirEntries(abs,this.fs.readdirSync(abs))}catch(er){return this._readdirError(abs,er),null}};GlobSync.prototype._readdirEntries=function(abs,entries){if(!this.mark&&!this.stat)for(var i=0;i<entries.length;i++){var e=entries[i];abs==="/"?e=abs+e:e=abs+"/"+e,this.cache[e]=!0}return this.cache[abs]=entries,entries};GlobSync.prototype._readdirError=function(f,er){switch(er.code){case"ENOTSUP":case"ENOTDIR":var abs=this._makeAbs(f);if(this.cache[abs]="FILE",abs===this.cwdAbs){var error=new Error(er.code+" invalid cwd "+this.cwd);throw error.path=this.cwd,error.code=er.code,error}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(f)]=!1;break;default:if(this.cache[this._makeAbs(f)]=!1,this.strict)throw er;this.silent||console.error("glob error",er);break}};GlobSync.prototype._processGlobStar=function(prefix,read,abs,remain,index,inGlobStar){var entries=this._readdir(abs,inGlobStar);if(entries){var remainWithoutGlobStar=remain.slice(1),gspref=prefix?[prefix]:[],noGlobStar=gspref.concat(remainWithoutGlobStar);this._process(noGlobStar,index,!1);var len=entries.length,isSym=this.symlinks[abs];if(!(isSym&&inGlobStar))for(var i=0;i<len;i++){var e=entries[i];if(!(e.charAt(0)==="."&&!this.dot)){var instead=gspref.concat(entries[i],remainWithoutGlobStar);this._process(instead,index,!0);var below=gspref.concat(entries[i],remain);this._process(below,index,!0)}}}};GlobSync.prototype._processSimple=function(prefix,index){var exists=this._stat(prefix);if(this.matches[index]||(this.matches[index]=Object.create(null)),!!exists){if(prefix&&isAbsolute(prefix)&&!this.nomount){var trail=/[\/\\]$/.test(prefix);prefix.charAt(0)==="/"?prefix=path9.join(this.root,prefix):(prefix=path9.resolve(this.root,prefix),trail&&(prefix+="/"))}process.platform==="win32"&&(prefix=prefix.replace(/\\/g,"/")),this._emitMatch(index,prefix)}};GlobSync.prototype._stat=function(f){var abs=this._makeAbs(f),needDir=f.slice(-1)==="/";if(f.length>this.maxLength)return!1;if(!this.stat&&ownProp(this.cache,abs)){var c=this.cache[abs];if(Array.isArray(c)&&(c="DIR"),!needDir||c==="DIR")return c;if(needDir&&c==="FILE")return!1}var exists,stat2=this.statCache[abs];if(!stat2){var lstat4;try{lstat4=this.fs.lstatSync(abs)}catch(er){if(er&&(er.code==="ENOENT"||er.code==="ENOTDIR"))return this.statCache[abs]=!1,!1}if(lstat4&&lstat4.isSymbolicLink())try{stat2=this.fs.statSync(abs)}catch{stat2=lstat4}else stat2=lstat4}this.statCache[abs]=stat2;var c=!0;return stat2&&(c=stat2.isDirectory()?"DIR":"FILE"),this.cache[abs]=this.cache[abs]||c,needDir&&c==="FILE"?!1:c};GlobSync.prototype._mark=function(p){return common.mark(this,p)};GlobSync.prototype._makeAbs=function(f){return common.makeAbs(this,f)}}});var require_inflight=__commonJS({"../../node_modules/.pnpm/inflight@1.0.6/node_modules/inflight/inflight.js"(exports2,module2){var wrappy=require_wrappy(),reqs=Object.create(null),once=require_once();module2.exports=wrappy(inflight);function inflight(key,cb){return reqs[key]?(reqs[key].push(cb),null):(reqs[key]=[cb],makeres(key))}function makeres(key){return once(function RES(){var cbs=reqs[key],len=cbs.length,args=slice(arguments);try{for(var i=0;i<len;i++)cbs[i].apply(null,args)}finally{cbs.length>len?(cbs.splice(0,len),process.nextTick(function(){RES.apply(null,args)})):delete reqs[key]}})}function slice(args){for(var length=args.length,array=[],i=0;i<length;i++)array[i]=args[i];return array}}});var require_glob=__commonJS({"../../node_modules/.pnpm/glob@8.0.3/node_modules/glob/glob.js"(exports2,module2){module2.exports=glob2;var rp=require_fs2(),minimatch3=require_minimatch2(),Minimatch=minimatch3.Minimatch,inherits=require_inherits(),EE=require("events").EventEmitter,path9=require("path"),assert9=require("assert"),isAbsolute=require("path").isAbsolute,globSync=require_sync(),common=require_common(),setopts=common.setopts,ownProp=common.ownProp,inflight=require_inflight(),util=require("util"),childrenIgnored=common.childrenIgnored,isIgnored=common.isIgnored,once=require_once();function glob2(pattern,options,cb){if(typeof options=="function"&&(cb=options,options={}),options||(options={}),options.sync){if(cb)throw new TypeError("callback provided to sync glob");return globSync(pattern,options)}return new Glob(pattern,options,cb)}glob2.sync=globSync;var GlobSync=glob2.GlobSync=globSync.GlobSync;glob2.glob=glob2;function extend(origin,add){if(add===null||typeof add!="object")return origin;for(var keys=Object.keys(add),i=keys.length;i--;)origin[keys[i]]=add[keys[i]];return origin}glob2.hasMagic=function(pattern,options_){var options=extend({},options_);options.noprocess=!0;var g2=new Glob(pattern,options),set=g2.minimatch.set;if(!pattern)return!1;if(set.length>1)return!0;for(var j=0;j<set[0].length;j++)if(typeof set[0][j]!="string")return!0;return!1};glob2.Glob=Glob;inherits(Glob,EE);function Glob(pattern,options,cb){if(typeof options=="function"&&(cb=options,options=null),options&&options.sync){if(cb)throw new TypeError("callback provided to sync glob");return new GlobSync(pattern,options)}if(!(this instanceof Glob))return new Glob(pattern,options,cb);setopts(this,pattern,options),this._didRealPath=!1;var n=this.minimatch.set.length;this.matches=new Array(n),typeof cb=="function"&&(cb=once(cb),this.on("error",cb),this.on("end",function(matches){cb(null,matches)}));var self2=this;if(this._processing=0,this._emitQueue=[],this._processQueue=[],this.paused=!1,this.noprocess)return this;if(n===0)return done();for(var sync=!0,i=0;i<n;i++)this._process(this.minimatch.set[i],i,!1,done);sync=!1;function done(){--self2._processing,self2._processing<=0&&(sync?process.nextTick(function(){self2._finish()}):self2._finish())}}Glob.prototype._finish=function(){if(assert9(this instanceof Glob),!this.aborted){if(this.realpath&&!this._didRealpath)return this._realpath();common.finish(this),this.emit("end",this.found)}};Glob.prototype._realpath=function(){if(this._didRealpath)return;this._didRealpath=!0;var n=this.matches.length;if(n===0)return this._finish();for(var self2=this,i=0;i<this.matches.length;i++)this._realpathSet(i,next);function next(){--n===0&&self2._finish()}};Glob.prototype._realpathSet=function(index,cb){var matchset=this.matches[index];if(!matchset)return cb();var found=Object.keys(matchset),self2=this,n=found.length;if(n===0)return cb();var set=this.matches[index]=Object.create(null);found.forEach(function(p,i){p=self2._makeAbs(p),rp.realpath(p,self2.realpathCache,function(er,real){er?er.syscall==="stat"?set[p]=!0:self2.emit("error",er):set[real]=!0,--n===0&&(self2.matches[index]=set,cb())})})};Glob.prototype._mark=function(p){return common.mark(this,p)};Glob.prototype._makeAbs=function(f){return common.makeAbs(this,f)};Glob.prototype.abort=function(){this.aborted=!0,this.emit("abort")};Glob.prototype.pause=function(){this.paused||(this.paused=!0,this.emit("pause"))};Glob.prototype.resume=function(){if(this.paused){if(this.emit("resume"),this.paused=!1,this._emitQueue.length){var eq=this._emitQueue.slice(0);this._emitQueue.length=0;for(var i=0;i<eq.length;i++){var e=eq[i];this._emitMatch(e[0],e[1])}}if(this._processQueue.length){var pq=this._processQueue.slice(0);this._processQueue.length=0;for(var i=0;i<pq.length;i++){var p=pq[i];this._processing--,this._process(p[0],p[1],p[2],p[3])}}}};Glob.prototype._process=function(pattern,index,inGlobStar,cb){if(assert9(this instanceof Glob),assert9(typeof cb=="function"),!this.aborted){if(this._processing++,this.paused){this._processQueue.push([pattern,index,inGlobStar,cb]);return}for(var n=0;typeof pattern[n]=="string";)n++;var prefix;switch(n){case pattern.length:this._processSimple(pattern.join("/"),index,cb);return;case 0:prefix=null;break;default:prefix=pattern.slice(0,n).join("/");break}var remain=pattern.slice(n),read;prefix===null?read=".":((isAbsolute(prefix)||isAbsolute(pattern.map(function(p){return typeof p=="string"?p:"[*]"}).join("/")))&&(!prefix||!isAbsolute(prefix))&&(prefix="/"+prefix),read=prefix);var abs=this._makeAbs(read);if(childrenIgnored(this,read))return cb();var isGlobStar=remain[0]===minimatch3.GLOBSTAR;isGlobStar?this._processGlobStar(prefix,read,abs,remain,index,inGlobStar,cb):this._processReaddir(prefix,read,abs,remain,index,inGlobStar,cb)}};Glob.prototype._processReaddir=function(prefix,read,abs,remain,index,inGlobStar,cb){var self2=this;this._readdir(abs,inGlobStar,function(er,entries){return self2._processReaddir2(prefix,read,abs,remain,index,inGlobStar,entries,cb)})};Glob.prototype._processReaddir2=function(prefix,read,abs,remain,index,inGlobStar,entries,cb){if(!entries)return cb();for(var pn=remain[0],negate=!!this.minimatch.negate,rawGlob=pn._glob,dotOk=this.dot||rawGlob.charAt(0)===".",matchedEntries=[],i=0;i<entries.length;i++){var e=entries[i];if(e.charAt(0)!=="."||dotOk){var m;negate&&!prefix?m=!e.match(pn):m=e.match(pn),m&&matchedEntries.push(e)}}var len=matchedEntries.length;if(len===0)return cb();if(remain.length===1&&!this.mark&&!this.stat){this.matches[index]||(this.matches[index]=Object.create(null));for(var i=0;i<len;i++){var e=matchedEntries[i];prefix&&(prefix!=="/"?e=prefix+"/"+e:e=prefix+e),e.charAt(0)==="/"&&!this.nomount&&(e=path9.join(this.root,e)),this._emitMatch(index,e)}return cb()}remain.shift();for(var i=0;i<len;i++){var e=matchedEntries[i],newPattern;prefix&&(prefix!=="/"?e=prefix+"/"+e:e=prefix+e),this._process([e].concat(remain),index,inGlobStar,cb)}cb()};Glob.prototype._emitMatch=function(index,e){if(!this.aborted&&!isIgnored(this,e)){if(this.paused){this._emitQueue.push([index,e]);return}var abs=isAbsolute(e)?e:this._makeAbs(e);if(this.mark&&(e=this._mark(e)),this.absolute&&(e=abs),!this.matches[index][e]){if(this.nodir){var c=this.cache[abs];if(c==="DIR"||Array.isArray(c))return}this.matches[index][e]=!0;var st=this.statCache[abs];st&&this.emit("stat",e,st),this.emit("match",e)}}};Glob.prototype._readdirInGlobStar=function(abs,cb){if(this.aborted)return;if(this.follow)return this._readdir(abs,!1,cb);var lstatkey="lstat\0"+abs,self2=this,lstatcb=inflight(lstatkey,lstatcb_);lstatcb&&self2.fs.lstat(abs,lstatcb);function lstatcb_(er,lstat4){if(er&&er.code==="ENOENT")return cb();var isSym=lstat4&&lstat4.isSymbolicLink();self2.symlinks[abs]=isSym,!isSym&&lstat4&&!lstat4.isDirectory()?(self2.cache[abs]="FILE",cb()):self2._readdir(abs,!1,cb)}};Glob.prototype._readdir=function(abs,inGlobStar,cb){if(!this.aborted&&(cb=inflight("readdir\0"+abs+"\0"+inGlobStar,cb),!!cb)){if(inGlobStar&&!ownProp(this.symlinks,abs))return this._readdirInGlobStar(abs,cb);if(ownProp(this.cache,abs)){var c=this.cache[abs];if(!c||c==="FILE")return cb();if(Array.isArray(c))return cb(null,c)}var self2=this;self2.fs.readdir(abs,readdirCb(this,abs,cb))}};function readdirCb(self2,abs,cb){return function(er,entries){er?self2._readdirError(abs,er,cb):self2._readdirEntries(abs,entries,cb)}}Glob.prototype._readdirEntries=function(abs,entries,cb){if(!this.aborted){if(!this.mark&&!this.stat)for(var i=0;i<entries.length;i++){var e=entries[i];abs==="/"?e=abs+e:e=abs+"/"+e,this.cache[e]=!0}return this.cache[abs]=entries,cb(null,entries)}};Glob.prototype._readdirError=function(f,er,cb){if(!this.aborted){switch(er.code){case"ENOTSUP":case"ENOTDIR":var abs=this._makeAbs(f);if(this.cache[abs]="FILE",abs===this.cwdAbs){var error=new Error(er.code+" invalid cwd "+this.cwd);error.path=this.cwd,error.code=er.code,this.emit("error",error),this.abort()}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(f)]=!1;break;default:this.cache[this._makeAbs(f)]=!1,this.strict&&(this.emit("error",er),this.abort()),this.silent||console.error("glob error",er);break}return cb()}};Glob.prototype._processGlobStar=function(prefix,read,abs,remain,index,inGlobStar,cb){var self2=this;this._readdir(abs,inGlobStar,function(er,entries){self2._processGlobStar2(prefix,read,abs,remain,index,inGlobStar,entries,cb)})};Glob.prototype._processGlobStar2=function(prefix,read,abs,remain,index,inGlobStar,entries,cb){if(!entries)return cb();var remainWithoutGlobStar=remain.slice(1),gspref=prefix?[prefix]:[],noGlobStar=gspref.concat(remainWithoutGlobStar);this._process(noGlobStar,index,!1,cb);var isSym=this.symlinks[abs],len=entries.length;if(isSym&&inGlobStar)return cb();for(var i=0;i<len;i++){var e=entries[i];if(!(e.charAt(0)==="."&&!this.dot)){var instead=gspref.concat(entries[i],remainWithoutGlobStar);this._process(instead,index,!0,cb);var below=gspref.concat(entries[i],remain);this._process(below,index,!0,cb)}}cb()};Glob.prototype._processSimple=function(prefix,index,cb){var self2=this;this._stat(prefix,function(er,exists){self2._processSimple2(prefix,index,er,exists,cb)})};Glob.prototype._processSimple2=function(prefix,index,er,exists,cb){if(this.matches[index]||(this.matches[index]=Object.create(null)),!exists)return cb();if(prefix&&isAbsolute(prefix)&&!this.nomount){var trail=/[\/\\]$/.test(prefix);prefix.charAt(0)==="/"?prefix=path9.join(this.root,prefix):(prefix=path9.resolve(this.root,prefix),trail&&(prefix+="/"))}process.platform==="win32"&&(prefix=prefix.replace(/\\/g,"/")),this._emitMatch(index,prefix),cb()};Glob.prototype._stat=function(f,cb){var abs=this._makeAbs(f),needDir=f.slice(-1)==="/";if(f.length>this.maxLength)return cb();if(!this.stat&&ownProp(this.cache,abs)){var c=this.cache[abs];if(Array.isArray(c)&&(c="DIR"),!needDir||c==="DIR")return cb(null,c);if(needDir&&c==="FILE")return cb()}var exists,stat2=this.statCache[abs];if(stat2!==void 0){if(stat2===!1)return cb(null,stat2);var type=stat2.isDirectory()?"DIR":"FILE";return needDir&&type==="FILE"?cb():cb(null,type,stat2)}var self2=this,statcb=inflight("stat\0"+abs,lstatcb_);statcb&&self2.fs.lstat(abs,statcb);function lstatcb_(er,lstat4){if(lstat4&&lstat4.isSymbolicLink())return self2.fs.stat(abs,function(er2,stat3){er2?self2._stat2(f,abs,null,lstat4,cb):self2._stat2(f,abs,er2,stat3,cb)});self2._stat2(f,abs,er,lstat4,cb)}};Glob.prototype._stat2=function(f,abs,er,stat2,cb){if(er&&(er.code==="ENOENT"||er.code==="ENOTDIR"))return this.statCache[abs]=!1,cb();var needDir=f.slice(-1)==="/";if(this.statCache[abs]=stat2,abs.slice(-1)==="/"&&stat2&&!stat2.isDirectory())return cb(null,!1,stat2);var c=!0;return stat2&&(c=stat2.isDirectory()?"DIR":"FILE"),this.cache[abs]=this.cache[abs]||c,needDir&&c==="FILE"?cb():cb(null,c,stat2)}}});var normalize_path_exports={};__export(normalize_path_exports,{normalizePath:()=>normalizePath});function normalizePath(p){return isWin?p.replace(/\\/g,"/"):p}var isWin,init_normalize_path=__esm({"src/fs/normalize-path.ts"(){"use strict";isWin=process.platform==="win32"}});var glob_exports={};__export(glob_exports,{default:()=>glob});async function glob(pattern,opts,mountpoint){let options=typeof opts=="string"?{cwd:opts}:opts;if(!options.cwd)throw new Error("Second argument (basePath) must be specified for names of resulting files");if(!import_path4.default.isAbsolute(options.cwd))throw new Error(`basePath/cwd must be an absolute path (${options.cwd})`);let results={},statCache={},symlinks={},files=await vanillaGlob(pattern,{...options,symlinks,statCache,stat:!0,dot:!0}),dirs=new Set,dirsWithEntries=new Set;for(let relativePath of files){let absPath=import_path4.default.join(options.cwd,relativePath),fsPath=normalizePath(absPath),stat2=statCache[fsPath];(0,import_assert6.default)(stat2,`statCache does not contain value for ${relativePath} (resolved to ${fsPath})`);let isSymlink=symlinks[fsPath];if(options.follow&&(isSymlink||(await(0,import_fs_extra5.lstat)(fsPath)).isSymbolicLink())){let target=await(0,import_fs_extra5.readlink)(absPath),absTarget=import_path4.default.resolve(import_path4.default.dirname(absPath),target);if(import_path4.default.relative(options.cwd,absTarget).startsWith(`..${import_path4.default.sep}`))continue}if(isSymlink||stat2.isFile()||stat2.isDirectory()){isSymlink&&(stat2=await(0,import_fs_extra5.lstat)(absPath));let dirname3=import_path4.default.dirname(relativePath);if(dirsWithEntries.add(dirname3),stat2.isDirectory()){dirs.add(relativePath);continue}let finalPath=relativePath;mountpoint&&(finalPath=import_path4.default.join(mountpoint,finalPath)),results[finalPath]=new file_fs_ref_default({mode:stat2.mode,fsPath})}}if(options.includeDirectories)for(let relativePath of dirs){if(dirsWithEntries.has(relativePath))continue;let finalPath=relativePath;mountpoint&&(finalPath=import_path4.default.join(mountpoint,finalPath));let fsPath=normalizePath(import_path4.default.join(options.cwd,relativePath)),stat2=statCache[fsPath];results[finalPath]=new file_fs_ref_default({mode:stat2.mode,fsPath})}return results}var import_path4,import_assert6,import_glob,import_util,import_fs_extra5,vanillaGlob,init_glob=__esm({"src/fs/glob.ts"(){"use strict";import_path4=__toESM(require("path")),import_assert6=__toESM(require("assert")),import_glob=__toESM(require_glob()),import_util=require("util"),import_fs_extra5=__toESM(require_lib());init_normalize_path();init_file_fs_ref();vanillaGlob=(0,import_util.promisify)(import_glob.default)}});var rename_exports={};__export(rename_exports,{default:()=>rename});function rename(files,delegate){let result={};for(let[name,file]of Object.entries(files))result[delegate(name)]=file;return result}var init_rename=__esm({"src/fs/rename.ts"(){"use strict"}});var find_package_json_exports={};__export(find_package_json_exports,{findPackageJson:()=>findPackageJson,traverseUpDirectories:()=>traverseUpDirectories,walkParentDirs:()=>walkParentDirs});function*traverseUpDirectories({start,base}){let current=import_path5.default.normalize(start),normalizedRoot=base?import_path5.default.normalize(base):void 0;for(;current&&(yield current,current!==normalizedRoot);){let next=import_path5.default.join(current,"..");current=next===current?void 0:next}}async function findPackageJson(destPath,readPackageJson2=!1,base="/"){(0,import_assert7.default)(import_path5.default.isAbsolute(destPath));let pkgJsonPath=await walkParentDirs({base,start:destPath,filename:"package.json"}),packageJson;if(readPackageJson2&&pkgJsonPath)try{packageJson=JSON.parse(await import_fs_extra6.default.readFile(pkgJsonPath,"utf8"))}catch(err){throw new Error(`Could not read ${pkgJsonPath}: ${err.message}.`)}return{packageJsonPath:pkgJsonPath||void 0,packageJson}}async function walkParentDirs({base,start,filename}){(0,import_assert7.default)(import_path5.default.isAbsolute(base),'Expected "base" to be absolute path'),(0,import_assert7.default)(import_path5.default.isAbsolute(start),'Expected "start" to be absolute path');for(let dir of traverseUpDirectories({start,base})){let fullPath=import_path5.default.join(dir,filename);if(await import_fs_extra6.default.pathExists(fullPath))return fullPath}return null}var import_assert7,import_fs_extra6,import_path5,init_find_package_json=__esm({"src/fs/find-package-json.ts"(){"use strict";import_assert7=__toESM(require("assert")),import_fs_extra6=__toESM(require_lib()),import_path5=__toESM(require("path"))}});var require_src=__commonJS({"../../node_modules/.pnpm/nice-try@1.0.5/node_modules/nice-try/src/index.js"(exports2,module2){"use strict";module2.exports=function(fn){try{return fn()}catch{}}}});var require_windows=__commonJS({"../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js"(exports2,module2){module2.exports=isexe;isexe.sync=sync;var fs12=require("fs");function checkPathExt(path9,options){var pathext=options.pathExt!==void 0?options.pathExt:process.env.PATHEXT;if(!pathext||(pathext=pathext.split(";"),pathext.indexOf("")!==-1))return!0;for(var i=0;i<pathext.length;i++){var p=pathext[i].toLowerCase();if(p&&path9.substr(-p.length).toLowerCase()===p)return!0}return!1}function checkStat(stat2,path9,options){return!stat2.isSymbolicLink()&&!stat2.isFile()?!1:checkPathExt(path9,options)}function isexe(path9,options,cb){fs12.stat(path9,function(er,stat2){cb(er,er?!1:checkStat(stat2,path9,options))})}function sync(path9,options){return checkStat(fs12.statSync(path9),path9,options)}}});var require_mode=__commonJS({"../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/mode.js"(exports2,module2){module2.exports=isexe;isexe.sync=sync;var fs12=require("fs");function isexe(path9,options,cb){fs12.stat(path9,function(er,stat2){cb(er,er?!1:checkStat(stat2,options))})}function sync(path9,options){return checkStat(fs12.statSync(path9),options)}function checkStat(stat2,options){return stat2.isFile()&&checkMode(stat2,options)}function checkMode(stat2,options){var mod=stat2.mode,uid=stat2.uid,gid=stat2.gid,myUid=options.uid!==void 0?options.uid:process.getuid&&process.getuid(),myGid=options.gid!==void 0?options.gid:process.getgid&&process.getgid(),u=parseInt("100",8),g2=parseInt("010",8),o=parseInt("001",8),ug=u|g2,ret=mod&o||mod&g2&&gid===myGid||mod&u&&uid===myUid||mod&ug&&myUid===0;return ret}}});var require_isexe=__commonJS({"../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/index.js"(exports2,module2){var fs12=require("fs"),core;process.platform==="win32"||global.TESTING_WINDOWS?core=require_windows():core=require_mode();module2.exports=isexe;isexe.sync=sync;function isexe(path9,options,cb){if(typeof options=="function"&&(cb=options,options={}),!cb){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(resolve3,reject){isexe(path9,options||{},function(er,is){er?reject(er):resolve3(is)})})}core(path9,options||{},function(er,is){er&&(er.code==="EACCES"||options&&options.ignoreErrors)&&(er=null,is=!1),cb(er,is)})}function sync(path9,options){try{return core.sync(path9,options||{})}catch(er){if(options&&options.ignoreErrors||er.code==="EACCES")return!1;throw er}}}});var require_which=__commonJS({"../../node_modules/.pnpm/which@1.3.1/node_modules/which/which.js"(exports2,module2){module2.exports=which;which.sync=whichSync;var isWindows=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",path9=require("path"),COLON=isWindows?";":":",isexe=require_isexe();function getNotFoundError(cmd){var er=new Error("not found: "+cmd);return er.code="ENOENT",er}function getPathInfo(cmd,opt){var colon=opt.colon||COLON,pathEnv=opt.path||process.env.PATH||"",pathExt=[""];pathEnv=pathEnv.split(colon);var pathExtExe="";return isWindows&&(pathEnv.unshift(process.cwd()),pathExtExe=opt.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM",pathExt=pathExtExe.split(colon),cmd.indexOf(".")!==-1&&pathExt[0]!==""&&pathExt.unshift("")),(cmd.match(/\//)||isWindows&&cmd.match(/\\/))&&(pathEnv=[""]),{env:pathEnv,ext:pathExt,extExe:pathExtExe}}function which(cmd,opt,cb){typeof opt=="function"&&(cb=opt,opt={});var info=getPathInfo(cmd,opt),pathEnv=info.env,pathExt=info.ext,pathExtExe=info.extExe,found=[];(function F(i,l){if(i===l)return opt.all&&found.length?cb(null,found):cb(getNotFoundError(cmd));var pathPart=pathEnv[i];pathPart.charAt(0)==='"'&&pathPart.slice(-1)==='"'&&(pathPart=pathPart.slice(1,-1));var p=path9.join(pathPart,cmd);!pathPart&&/^\.[\\\/]/.test(cmd)&&(p=cmd.slice(0,2)+p),function E3(ii,ll){if(ii===ll)return F(i+1,l);var ext=pathExt[ii];isexe(p+ext,{pathExt:pathExtExe},function(er,is){if(!er&&is)if(opt.all)found.push(p+ext);else return cb(null,p+ext);return E3(ii+1,ll)})}(0,pathExt.length)})(0,pathEnv.length)}function whichSync(cmd,opt){opt=opt||{};for(var info=getPathInfo(cmd,opt),pathEnv=info.env,pathExt=info.ext,pathExtExe=info.extExe,found=[],i=0,l=pathEnv.length;i<l;i++){var pathPart=pathEnv[i];pathPart.charAt(0)==='"'&&pathPart.slice(-1)==='"'&&(pathPart=pathPart.slice(1,-1));var p=path9.join(pathPart,cmd);!pathPart&&/^\.[\\\/]/.test(cmd)&&(p=cmd.slice(0,2)+p);for(var j=0,ll=pathExt.length;j<ll;j++){var cur=p+pathExt[j],is;try{if(is=isexe.sync(cur,{pathExt:pathExtExe}),is)if(opt.all)found.push(cur);else return cur}catch{}}}if(opt.all&&found.length)return found;if(opt.nothrow)return null;throw getNotFoundError(cmd)}}});var require_path_key=__commonJS({"../../node_modules/.pnpm/path-key@2.0.1/node_modules/path-key/index.js"(exports2,module2){"use strict";module2.exports=opts=>{opts=opts||{};let env=opts.env||process.env;return(opts.platform||process.platform)!=="win32"?"PATH":Object.keys(env).find(x=>x.toUpperCase()==="PATH")||"Path"}}});var require_resolveCommand=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/util/resolveCommand.js"(exports2,module2){"use strict";var path9=require("path"),which=require_which(),pathKey=require_path_key()();function resolveCommandAttempt(parsed,withoutPathExt){let cwd=process.cwd(),hasCustomCwd=parsed.options.cwd!=null;if(hasCustomCwd)try{process.chdir(parsed.options.cwd)}catch{}let resolved;try{resolved=which.sync(parsed.command,{path:(parsed.options.env||process.env)[pathKey],pathExt:withoutPathExt?path9.delimiter:void 0})}catch{}finally{process.chdir(cwd)}return resolved&&(resolved=path9.resolve(hasCustomCwd?parsed.options.cwd:"",resolved)),resolved}function resolveCommand(parsed){return resolveCommandAttempt(parsed)||resolveCommandAttempt(parsed,!0)}module2.exports=resolveCommand}});var require_escape=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/util/escape.js"(exports2,module2){"use strict";var metaCharsRegExp=/([()\][%!^"`<>&|;, *?])/g;function escapeCommand(arg){return arg=arg.replace(metaCharsRegExp,"^$1"),arg}function escapeArgument(arg,doubleEscapeMetaChars){return arg=`${arg}`,arg=arg.replace(/(\\*)"/g,'$1$1\\"'),arg=arg.replace(/(\\*)$/,"$1$1"),arg=`"${arg}"`,arg=arg.replace(metaCharsRegExp,"^$1"),doubleEscapeMetaChars&&(arg=arg.replace(metaCharsRegExp,"^$1")),arg}module2.exports.command=escapeCommand;module2.exports.argument=escapeArgument}});var require_shebang_regex=__commonJS({"../../node_modules/.pnpm/shebang-regex@1.0.0/node_modules/shebang-regex/index.js"(exports2,module2){"use strict";module2.exports=/^#!.*/}});var require_shebang_command=__commonJS({"../../node_modules/.pnpm/shebang-command@1.2.0/node_modules/shebang-command/index.js"(exports2,module2){"use strict";var shebangRegex=require_shebang_regex();module2.exports=function(str){var match=str.match(shebangRegex);if(!match)return null;var arr=match[0].replace(/#! ?/,"").split(" "),bin=arr[0].split("/").pop(),arg=arr[1];return bin==="env"?arg:bin+(arg?" "+arg:"")}}});var require_readShebang=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/util/readShebang.js"(exports2,module2){"use strict";var fs12=require("fs"),shebangCommand=require_shebang_command();function readShebang(command){let buffer;Buffer.alloc?buffer=Buffer.alloc(150):(buffer=new Buffer(150),buffer.fill(0));let fd;try{fd=fs12.openSync(command,"r"),fs12.readSync(fd,buffer,0,150,0),fs12.closeSync(fd)}catch{}return shebangCommand(buffer.toString())}module2.exports=readShebang}});var require_semver=__commonJS({"../../node_modules/.pnpm/semver@5.7.2/node_modules/semver/semver.js"(exports2,module2){exports2=module2.exports=SemVer2;var debug2;typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?debug2=function(){var args=Array.prototype.slice.call(arguments,0);args.unshift("SEMVER"),console.log.apply(console,args)}:debug2=function(){};exports2.SEMVER_SPEC_VERSION="2.0.0";var MAX_LENGTH=256,MAX_SAFE_INTEGER=Number.MAX_SAFE_INTEGER||9007199254740991,MAX_SAFE_COMPONENT_LENGTH=16,MAX_SAFE_BUILD_LENGTH=MAX_LENGTH-6,re=exports2.re=[],safeRe=exports2.safeRe=[],src=exports2.src=[],R=0,LETTERDASHNUMBER="[a-zA-Z0-9-]",safeRegexReplacements=[["\\s",1],["\\d",MAX_LENGTH],[LETTERDASHNUMBER,MAX_SAFE_BUILD_LENGTH]];function makeSafeRe(value){for(var i2=0;i2<safeRegexReplacements.length;i2++){var token=safeRegexReplacements[i2][0],max=safeRegexReplacements[i2][1];value=value.split(token+"*").join(token+"{0,"+max+"}").split(token+"+").join(token+"{1,"+max+"}")}return value}var NUMERICIDENTIFIER=R++;src[NUMERICIDENTIFIER]="0|[1-9]\\d*";var NUMERICIDENTIFIERLOOSE=R++;src[NUMERICIDENTIFIERLOOSE]="\\d+";var NONNUMERICIDENTIFIER=R++;src[NONNUMERICIDENTIFIER]="\\d*[a-zA-Z-]"+LETTERDASHNUMBER+"*";var MAINVERSION=R++;src[MAINVERSION]="("+src[NUMERICIDENTIFIER]+")\\.("+src[NUMERICIDENTIFIER]+")\\.("+src[NUMERICIDENTIFIER]+")";var MAINVERSIONLOOSE=R++;src[MAINVERSIONLOOSE]="("+src[NUMERICIDENTIFIERLOOSE]+")\\.("+src[NUMERICIDENTIFIERLOOSE]+")\\.("+src[NUMERICIDENTIFIERLOOSE]+")";var PRERELEASEIDENTIFIER=R++;src[PRERELEASEIDENTIFIER]="(?:"+src[NUMERICIDENTIFIER]+"|"+src[NONNUMERICIDENTIFIER]+")";var PRERELEASEIDENTIFIERLOOSE=R++;src[PRERELEASEIDENTIFIERLOOSE]="(?:"+src[NUMERICIDENTIFIERLOOSE]+"|"+src[NONNUMERICIDENTIFIER]+")";var PRERELEASE=R++;src[PRERELEASE]="(?:-("+src[PRERELEASEIDENTIFIER]+"(?:\\."+src[PRERELEASEIDENTIFIER]+")*))";var PRERELEASELOOSE=R++;src[PRERELEASELOOSE]="(?:-?("+src[PRERELEASEIDENTIFIERLOOSE]+"(?:\\."+src[PRERELEASEIDENTIFIERLOOSE]+")*))";var BUILDIDENTIFIER=R++;src[BUILDIDENTIFIER]=LETTERDASHNUMBER+"+";var BUILD=R++;src[BUILD]="(?:\\+("+src[BUILDIDENTIFIER]+"(?:\\."+src[BUILDIDENTIFIER]+")*))";var FULL=R++,FULLPLAIN="v?"+src[MAINVERSION]+src[PRERELEASE]+"?"+src[BUILD]+"?";src[FULL]="^"+FULLPLAIN+"$";var LOOSEPLAIN="[v=\\s]*"+src[MAINVERSIONLOOSE]+src[PRERELEASELOOSE]+"?"+src[BUILD]+"?",LOOSE=R++;src[LOOSE]="^"+LOOSEPLAIN+"$";var GTLT=R++;src[GTLT]="((?:<|>)?=?)";var XRANGEIDENTIFIERLOOSE=R++;src[XRANGEIDENTIFIERLOOSE]=src[NUMERICIDENTIFIERLOOSE]+"|x|X|\\*";var XRANGEIDENTIFIER=R++;src[XRANGEIDENTIFIER]=src[NUMERICIDENTIFIER]+"|x|X|\\*";var XRANGEPLAIN=R++;src[XRANGEPLAIN]="[v=\\s]*("+src[XRANGEIDENTIFIER]+")(?:\\.("+src[XRANGEIDENTIFIER]+")(?:\\.("+src[XRANGEIDENTIFIER]+")(?:"+src[PRERELEASE]+")?"+src[BUILD]+"?)?)?";var XRANGEPLAINLOOSE=R++;src[XRANGEPLAINLOOSE]="[v=\\s]*("+src[XRANGEIDENTIFIERLOOSE]+")(?:\\.("+src[XRANGEIDENTIFIERLOOSE]+")(?:\\.("+src[XRANGEIDENTIFIERLOOSE]+")(?:"+src[PRERELEASELOOSE]+")?"+src[BUILD]+"?)?)?";var XRANGE=R++;src[XRANGE]="^"+src[GTLT]+"\\s*"+src[XRANGEPLAIN]+"$";var XRANGELOOSE=R++;src[XRANGELOOSE]="^"+src[GTLT]+"\\s*"+src[XRANGEPLAINLOOSE]+"$";var COERCE=R++;src[COERCE]="(?:^|[^\\d])(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"})(?:\\.(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"}))?(?:\\.(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"}))?(?:$|[^\\d])";var LONETILDE=R++;src[LONETILDE]="(?:~>?)";var TILDETRIM=R++;src[TILDETRIM]="(\\s*)"+src[LONETILDE]+"\\s+";re[TILDETRIM]=new RegExp(src[TILDETRIM],"g");safeRe[TILDETRIM]=new RegExp(makeSafeRe(src[TILDETRIM]),"g");var tildeTrimReplace="$1~",TILDE=R++;src[TILDE]="^"+src[LONETILDE]+src[XRANGEPLAIN]+"$";var TILDELOOSE=R++;src[TILDELOOSE]="^"+src[LONETILDE]+src[XRANGEPLAINLOOSE]+"$";var LONECARET=R++;src[LONECARET]="(?:\\^)";var CARETTRIM=R++;src[CARETTRIM]="(\\s*)"+src[LONECARET]+"\\s+";re[CARETTRIM]=new RegExp(src[CARETTRIM],"g");safeRe[CARETTRIM]=new RegExp(makeSafeRe(src[CARETTRIM]),"g");var caretTrimReplace="$1^",CARET=R++;src[CARET]="^"+src[LONECARET]+src[XRANGEPLAIN]+"$";var CARETLOOSE=R++;src[CARETLOOSE]="^"+src[LONECARET]+src[XRANGEPLAINLOOSE]+"$";var COMPARATORLOOSE=R++;src[COMPARATORLOOSE]="^"+src[GTLT]+"\\s*("+LOOSEPLAIN+")$|^$";var COMPARATOR=R++;src[COMPARATOR]="^"+src[GTLT]+"\\s*("+FULLPLAIN+")$|^$";var COMPARATORTRIM=R++;src[COMPARATORTRIM]="(\\s*)"+src[GTLT]+"\\s*("+LOOSEPLAIN+"|"+src[XRANGEPLAIN]+")";re[COMPARATORTRIM]=new RegExp(src[COMPARATORTRIM],"g");safeRe[COMPARATORTRIM]=new RegExp(makeSafeRe(src[COMPARATORTRIM]),"g");var comparatorTrimReplace="$1$2$3",HYPHENRANGE=R++;src[HYPHENRANGE]="^\\s*("+src[XRANGEPLAIN]+")\\s+-\\s+("+src[XRANGEPLAIN]+")\\s*$";var HYPHENRANGELOOSE=R++;src[HYPHENRANGELOOSE]="^\\s*("+src[XRANGEPLAINLOOSE]+")\\s+-\\s+("+src[XRANGEPLAINLOOSE]+")\\s*$";var STAR=R++;src[STAR]="(<|>)?=?\\s*\\*";for(i=0;i<R;i++)debug2(i,src[i]),re[i]||(re[i]=new RegExp(src[i]),safeRe[i]=new RegExp(makeSafeRe(src[i])));var i;exports2.parse=parse6;function parse6(version,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),version instanceof SemVer2)return version;if(typeof version!="string"||version.length>MAX_LENGTH)return null;var r=options.loose?safeRe[LOOSE]:safeRe[FULL];if(!r.test(version))return null;try{return new SemVer2(version,options)}catch{return null}}exports2.valid=valid;function valid(version,options){var v=parse6(version,options);return v?v.version:null}exports2.clean=clean;function clean(version,options){var s=parse6(version.trim().replace(/^[=v]+/,""),options);return s?s.version:null}exports2.SemVer=SemVer2;function SemVer2(version,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),version instanceof SemVer2){if(version.loose===options.loose)return version;version=version.version}else if(typeof version!="string")throw new TypeError("Invalid Version: "+version);if(version.length>MAX_LENGTH)throw new TypeError("version is longer than "+MAX_LENGTH+" characters");if(!(this instanceof SemVer2))return new SemVer2(version,options);debug2("SemVer",version,options),this.options=options,this.loose=!!options.loose;var m=version.trim().match(options.loose?safeRe[LOOSE]:safeRe[FULL]);if(!m)throw new TypeError("Invalid Version: "+version);if(this.raw=version,this.major=+m[1],this.minor=+m[2],this.patch=+m[3],this.major>MAX_SAFE_INTEGER||this.major<0)throw new TypeError("Invalid major version");if(this.minor>MAX_SAFE_INTEGER||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>MAX_SAFE_INTEGER||this.patch<0)throw new TypeError("Invalid patch version");m[4]?this.prerelease=m[4].split(".").map(function(id){if(/^[0-9]+$/.test(id)){var num=+id;if(num>=0&&num<MAX_SAFE_INTEGER)return num}return id}):this.prerelease=[],this.build=m[5]?m[5].split("."):[],this.format()}SemVer2.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version};SemVer2.prototype.toString=function(){return this.version};SemVer2.prototype.compare=function(other){return debug2("SemVer.compare",this.version,this.options,other),other instanceof SemVer2||(other=new SemVer2(other,this.options)),this.compareMain(other)||this.comparePre(other)};SemVer2.prototype.compareMain=function(other){return other instanceof SemVer2||(other=new SemVer2(other,this.options)),compareIdentifiers(this.major,other.major)||compareIdentifiers(this.minor,other.minor)||compareIdentifiers(this.patch,other.patch)};SemVer2.prototype.comparePre=function(other){if(other instanceof SemVer2||(other=new SemVer2(other,this.options)),this.prerelease.length&&!other.prerelease.length)return-1;if(!this.prerelease.length&&other.prerelease.length)return 1;if(!this.prerelease.length&&!other.prerelease.length)return 0;var i2=0;do{var a=this.prerelease[i2],b=other.prerelease[i2];if(debug2("prerelease compare",i2,a,b),a===void 0&&b===void 0)return 0;if(b===void 0)return 1;if(a===void 0)return-1;if(a===b)continue;return compareIdentifiers(a,b)}while(++i2)};SemVer2.prototype.inc=function(release,identifier){switch(release){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",identifier);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",identifier);break;case"prepatch":this.prerelease.length=0,this.inc("patch",identifier),this.inc("pre",identifier);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",identifier),this.inc("pre",identifier);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{for(var i2=this.prerelease.length;--i2>=0;)typeof this.prerelease[i2]=="number"&&(this.prerelease[i2]++,i2=-2);i2===-1&&this.prerelease.push(0)}identifier&&(this.prerelease[0]===identifier?isNaN(this.prerelease[1])&&(this.prerelease=[identifier,0]):this.prerelease=[identifier,0]);break;default:throw new Error("invalid increment argument: "+release)}return this.format(),this.raw=this.version,this};exports2.inc=inc;function inc(version,release,loose,identifier){typeof loose=="string"&&(identifier=loose,loose=void 0);try{return new SemVer2(version,loose).inc(release,identifier).version}catch{return null}}exports2.diff=diff;function diff(version1,version2){if(eq(version1,version2))return null;var v1=parse6(version1),v2=parse6(version2),prefix="";if(v1.prerelease.length||v2.prerelease.length){prefix="pre";var defaultResult="prerelease"}for(var key in v1)if((key==="major"||key==="minor"||key==="patch")&&v1[key]!==v2[key])return prefix+key;return defaultResult}exports2.compareIdentifiers=compareIdentifiers;var numeric=/^[0-9]+$/;function compareIdentifiers(a,b){var anum=numeric.test(a),bnum=numeric.test(b);return anum&&bnum&&(a=+a,b=+b),a===b?0:anum&&!bnum?-1:bnum&&!anum?1:a<b?-1:1}exports2.rcompareIdentifiers=rcompareIdentifiers;function rcompareIdentifiers(a,b){return compareIdentifiers(b,a)}exports2.major=major;function major(a,loose){return new SemVer2(a,loose).major}exports2.minor=minor;function minor(a,loose){return new SemVer2(a,loose).minor}exports2.patch=patch;function patch(a,loose){return new SemVer2(a,loose).patch}exports2.compare=compare;function compare(a,b,loose){return new SemVer2(a,loose).compare(new SemVer2(b,loose))}exports2.compareLoose=compareLoose;function compareLoose(a,b){return compare(a,b,!0)}exports2.rcompare=rcompare;function rcompare(a,b,loose){return compare(b,a,loose)}exports2.sort=sort;function sort(list,loose){return list.sort(function(a,b){return exports2.compare(a,b,loose)})}exports2.rsort=rsort;function rsort(list,loose){return list.sort(function(a,b){return exports2.rcompare(a,b,loose)})}exports2.gt=gt;function gt(a,b,loose){return compare(a,b,loose)>0}exports2.lt=lt;function lt(a,b,loose){return compare(a,b,loose)<0}exports2.eq=eq;function eq(a,b,loose){return compare(a,b,loose)===0}exports2.neq=neq;function neq(a,b,loose){return compare(a,b,loose)!==0}exports2.gte=gte2;function gte2(a,b,loose){return compare(a,b,loose)>=0}exports2.lte=lte;function lte(a,b,loose){return compare(a,b,loose)<=0}exports2.cmp=cmp;function cmp(a,op,b,loose){switch(op){case"===":return typeof a=="object"&&(a=a.version),typeof b=="object"&&(b=b.version),a===b;case"!==":return typeof a=="object"&&(a=a.version),typeof b=="object"&&(b=b.version),a!==b;case"":case"=":case"==":return eq(a,b,loose);case"!=":return neq(a,b,loose);case">":return gt(a,b,loose);case">=":return gte2(a,b,loose);case"<":return lt(a,b,loose);case"<=":return lte(a,b,loose);default:throw new TypeError("Invalid operator: "+op)}}exports2.Comparator=Comparator;function Comparator(comp,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),comp instanceof Comparator){if(comp.loose===!!options.loose)return comp;comp=comp.value}if(!(this instanceof Comparator))return new Comparator(comp,options);comp=comp.trim().split(/\s+/).join(" "),debug2("comparator",comp,options),this.options=options,this.loose=!!options.loose,this.parse(comp),this.semver===ANY?this.value="":this.value=this.operator+this.semver.version,debug2("comp",this)}var ANY={};Comparator.prototype.parse=function(comp){var r=this.options.loose?safeRe[COMPARATORLOOSE]:safeRe[COMPARATOR],m=comp.match(r);if(!m)throw new TypeError("Invalid comparator: "+comp);this.operator=m[1],this.operator==="="&&(this.operator=""),m[2]?this.semver=new SemVer2(m[2],this.options.loose):this.semver=ANY};Comparator.prototype.toString=function(){return this.value};Comparator.prototype.test=function(version){return debug2("Comparator.test",version,this.options.loose),this.semver===ANY?!0:(typeof version=="string"&&(version=new SemVer2(version,this.options)),cmp(version,this.operator,this.semver,this.options))};Comparator.prototype.intersects=function(comp,options){if(!(comp instanceof Comparator))throw new TypeError("a Comparator is required");(!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1});var rangeTmp;if(this.operator==="")return rangeTmp=new Range(comp.value,options),satisfies2(this.value,rangeTmp,options);if(comp.operator==="")return rangeTmp=new Range(this.value,options),satisfies2(comp.semver,rangeTmp,options);var sameDirectionIncreasing=(this.operator===">="||this.operator===">")&&(comp.operator===">="||comp.operator===">"),sameDirectionDecreasing=(this.operator==="<="||this.operator==="<")&&(comp.operator==="<="||comp.operator==="<"),sameSemVer=this.semver.version===comp.semver.version,differentDirectionsInclusive=(this.operator===">="||this.operator==="<=")&&(comp.operator===">="||comp.operator==="<="),oppositeDirectionsLessThan=cmp(this.semver,"<",comp.semver,options)&&(this.operator===">="||this.operator===">")&&(comp.operator==="<="||comp.operator==="<"),oppositeDirectionsGreaterThan=cmp(this.semver,">",comp.semver,options)&&(this.operator==="<="||this.operator==="<")&&(comp.operator===">="||comp.operator===">");return sameDirectionIncreasing||sameDirectionDecreasing||sameSemVer&&differentDirectionsInclusive||oppositeDirectionsLessThan||oppositeDirectionsGreaterThan};exports2.Range=Range;function Range(range,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),range instanceof Range)return range.loose===!!options.loose&&range.includePrerelease===!!options.includePrerelease?range:new Range(range.raw,options);if(range instanceof Comparator)return new Range(range.value,options);if(!(this instanceof Range))return new Range(range,options);if(this.options=options,this.loose=!!options.loose,this.includePrerelease=!!options.includePrerelease,this.raw=range.trim().split(/\s+/).join(" "),this.set=this.raw.split("||").map(function(range2){return this.parseRange(range2.trim())},this).filter(function(c){return c.length}),!this.set.length)throw new TypeError("Invalid SemVer Range: "+this.raw);this.format()}Range.prototype.format=function(){return this.range=this.set.map(function(comps){return comps.join(" ").trim()}).join("||").trim(),this.range};Range.prototype.toString=function(){return this.range};Range.prototype.parseRange=function(range){var loose=this.options.loose,hr=loose?safeRe[HYPHENRANGELOOSE]:safeRe[HYPHENRANGE];range=range.replace(hr,hyphenReplace),debug2("hyphen replace",range),range=range.replace(safeRe[COMPARATORTRIM],comparatorTrimReplace),debug2("comparator trim",range,safeRe[COMPARATORTRIM]),range=range.replace(safeRe[TILDETRIM],tildeTrimReplace),range=range.replace(safeRe[CARETTRIM],caretTrimReplace);var compRe=loose?safeRe[COMPARATORLOOSE]:safeRe[COMPARATOR],set=range.split(" ").map(function(comp){return parseComparator(comp,this.options)},this).join(" ").split(/\s+/);return this.options.loose&&(set=set.filter(function(comp){return!!comp.match(compRe)})),set=set.map(function(comp){return new Comparator(comp,this.options)},this),set};Range.prototype.intersects=function(range,options){if(!(range instanceof Range))throw new TypeError("a Range is required");return this.set.some(function(thisComparators){return thisComparators.every(function(thisComparator){return range.set.some(function(rangeComparators){return rangeComparators.every(function(rangeComparator){return thisComparator.intersects(rangeComparator,options)})})})})};exports2.toComparators=toComparators;function toComparators(range,options){return new Range(range,options).set.map(function(comp){return comp.map(function(c){return c.value}).join(" ").trim().split(" ")})}function parseComparator(comp,options){return debug2("comp",comp,options),comp=replaceCarets(comp,options),debug2("caret",comp),comp=replaceTildes(comp,options),debug2("tildes",comp),comp=replaceXRanges(comp,options),debug2("xrange",comp),comp=replaceStars(comp,options),debug2("stars",comp),comp}function isX(id){return!id||id.toLowerCase()==="x"||id==="*"}function replaceTildes(comp,options){return comp.trim().split(/\s+/).map(function(comp2){return replaceTilde(comp2,options)}).join(" ")}function replaceTilde(comp,options){var r=options.loose?safeRe[TILDELOOSE]:safeRe[TILDE];return comp.replace(r,function(_,M,m,p,pr){debug2("tilde",comp,_,M,m,p,pr);var ret;return isX(M)?ret="":isX(m)?ret=">="+M+".0.0 <"+(+M+1)+".0.0":isX(p)?ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0":pr?(debug2("replaceTilde pr",pr),ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+(+m+1)+".0"):ret=">="+M+"."+m+"."+p+" <"+M+"."+(+m+1)+".0",debug2("tilde return",ret),ret})}function replaceCarets(comp,options){return comp.trim().split(/\s+/).map(function(comp2){return replaceCaret(comp2,options)}).join(" ")}function replaceCaret(comp,options){debug2("caret",comp,options);var r=options.loose?safeRe[CARETLOOSE]:safeRe[CARET];return comp.replace(r,function(_,M,m,p,pr){debug2("caret",comp,_,M,m,p,pr);var ret;return isX(M)?ret="":isX(m)?ret=">="+M+".0.0 <"+(+M+1)+".0.0":isX(p)?M==="0"?ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+".0 <"+(+M+1)+".0.0":pr?(debug2("replaceCaret pr",pr),M==="0"?m==="0"?ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+m+"."+(+p+1):ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+"."+p+"-"+pr+" <"+(+M+1)+".0.0"):(debug2("no pr"),M==="0"?m==="0"?ret=">="+M+"."+m+"."+p+" <"+M+"."+m+"."+(+p+1):ret=">="+M+"."+m+"."+p+" <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+"."+p+" <"+(+M+1)+".0.0"),debug2("caret return",ret),ret})}function replaceXRanges(comp,options){return debug2("replaceXRanges",comp,options),comp.split(/\s+/).map(function(comp2){return replaceXRange(comp2,options)}).join(" ")}function replaceXRange(comp,options){comp=comp.trim();var r=options.loose?safeRe[XRANGELOOSE]:safeRe[XRANGE];return comp.replace(r,function(ret,gtlt,M,m,p,pr){debug2("xRange",comp,ret,gtlt,M,m,p,pr);var xM=isX(M),xm=xM||isX(m),xp=xm||isX(p),anyX=xp;return gtlt==="="&&anyX&&(gtlt=""),xM?gtlt===">"||gtlt==="<"?ret="<0.0.0":ret="*":gtlt&&anyX?(xm&&(m=0),p=0,gtlt===">"?(gtlt=">=",xm?(M=+M+1,m=0,p=0):(m=+m+1,p=0)):gtlt==="<="&&(gtlt="<",xm?M=+M+1:m=+m+1),ret=gtlt+M+"."+m+"."+p):xm?ret=">="+M+".0.0 <"+(+M+1)+".0.0":xp&&(ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0"),debug2("xRange return",ret),ret})}function replaceStars(comp,options){return debug2("replaceStars",comp,options),comp.trim().replace(safeRe[STAR],"")}function hyphenReplace($0,from,fM,fm,fp,fpr,fb,to,tM,tm,tp,tpr,tb){return isX(fM)?from="":isX(fm)?from=">="+fM+".0.0":isX(fp)?from=">="+fM+"."+fm+".0":from=">="+from,isX(tM)?to="":isX(tm)?to="<"+(+tM+1)+".0.0":isX(tp)?to="<"+tM+"."+(+tm+1)+".0":tpr?to="<="+tM+"."+tm+"."+tp+"-"+tpr:to="<="+to,(from+" "+to).trim()}Range.prototype.test=function(version){if(!version)return!1;typeof version=="string"&&(version=new SemVer2(version,this.options));for(var i2=0;i2<this.set.length;i2++)if(testSet(this.set[i2],version,this.options))return!0;return!1};function testSet(set,version,options){for(var i2=0;i2<set.length;i2++)if(!set[i2].test(version))return!1;if(version.prerelease.length&&!options.includePrerelease){for(i2=0;i2<set.length;i2++)if(debug2(set[i2].semver),set[i2].semver!==ANY&&set[i2].semver.prerelease.length>0){var allowed=set[i2].semver;if(allowed.major===version.major&&allowed.minor===version.minor&&allowed.patch===version.patch)return!0}return!1}return!0}exports2.satisfies=satisfies2;function satisfies2(version,range,options){try{range=new Range(range,options)}catch{return!1}return range.test(version)}exports2.maxSatisfying=maxSatisfying;function maxSatisfying(versions,range,options){var max=null,maxSV=null;try{var rangeObj=new Range(range,options)}catch{return null}return versions.forEach(function(v){rangeObj.test(v)&&(!max||maxSV.compare(v)===-1)&&(max=v,maxSV=new SemVer2(max,options))}),max}exports2.minSatisfying=minSatisfying;function minSatisfying(versions,range,options){var min=null,minSV=null;try{var rangeObj=new Range(range,options)}catch{return null}return versions.forEach(function(v){rangeObj.test(v)&&(!min||minSV.compare(v)===1)&&(min=v,minSV=new SemVer2(min,options))}),min}exports2.minVersion=minVersion2;function minVersion2(range,loose){range=new Range(range,loose);var minver=new SemVer2("0.0.0");if(range.test(minver)||(minver=new SemVer2("0.0.0-0"),range.test(minver)))return minver;minver=null;for(var i2=0;i2<range.set.length;++i2){var comparators=range.set[i2];comparators.forEach(function(comparator){var compver=new SemVer2(comparator.semver.version);switch(comparator.operator){case">":compver.prerelease.length===0?compver.patch++:compver.prerelease.push(0),compver.raw=compver.format();case"":case">=":(!minver||gt(minver,compver))&&(minver=compver);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+comparator.operator)}})}return minver&&range.test(minver)?minver:null}exports2.validRange=validRange3;function validRange3(range,options){try{return new Range(range,options).range||"*"}catch{return null}}exports2.ltr=ltr;function ltr(version,range,options){return outside(version,range,"<",options)}exports2.gtr=gtr;function gtr(version,range,options){return outside(version,range,">",options)}exports2.outside=outside;function outside(version,range,hilo,options){version=new SemVer2(version,options),range=new Range(range,options);var gtfn,ltefn,ltfn,comp,ecomp;switch(hilo){case">":gtfn=gt,ltefn=lte,ltfn=lt,comp=">",ecomp=">=";break;case"<":gtfn=lt,ltefn=gte2,ltfn=gt,comp="<",ecomp="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(satisfies2(version,range,options))return!1;for(var i2=0;i2<range.set.length;++i2){var comparators=range.set[i2],high=null,low=null;if(comparators.forEach(function(comparator){comparator.semver===ANY&&(comparator=new Comparator(">=0.0.0")),high=high||comparator,low=low||comparator,gtfn(comparator.semver,high.semver,options)?high=comparator:ltfn(comparator.semver,low.semver,options)&&(low=comparator)}),high.operator===comp||high.operator===ecomp||(!low.operator||low.operator===comp)&&ltefn(version,low.semver))return!1;if(low.operator===ecomp&&ltfn(version,low.semver))return!1}return!0}exports2.prerelease=prerelease;function prerelease(version,options){var parsed=parse6(version,options);return parsed&&parsed.prerelease.length?parsed.prerelease:null}exports2.intersects=intersects3;function intersects3(r1,r2,options){return r1=new Range(r1,options),r2=new Range(r2,options),r1.intersects(r2)}exports2.coerce=coerce2;function coerce2(version){if(version instanceof SemVer2)return version;if(typeof version!="string")return null;var match=version.match(safeRe[COERCE]);return match==null?null:parse6(match[1]+"."+(match[2]||"0")+"."+(match[3]||"0"))}}});var require_parse=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/parse.js"(exports2,module2){"use strict";var path9=require("path"),niceTry=require_src(),resolveCommand=require_resolveCommand(),escape=require_escape(),readShebang=require_readShebang(),semver=require_semver(),isWin2=process.platform==="win32",isExecutableRegExp=/\.(?:com|exe)$/i,isCmdShimRegExp=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i,supportsShellOption=niceTry(()=>semver.satisfies(process.version,"^4.8.0 || ^5.7.0 || >= 6.0.0",!0))||!1;function detectShebang(parsed){parsed.file=resolveCommand(parsed);let shebang=parsed.file&&readShebang(parsed.file);return shebang?(parsed.args.unshift(parsed.file),parsed.command=shebang,resolveCommand(parsed)):parsed.file}function parseNonShell(parsed){if(!isWin2)return parsed;let commandFile=detectShebang(parsed),needsShell=!isExecutableRegExp.test(commandFile);if(parsed.options.forceShell||needsShell){let needsDoubleEscapeMetaChars=isCmdShimRegExp.test(commandFile);parsed.command=path9.normalize(parsed.command),parsed.command=escape.command(parsed.command),parsed.args=parsed.args.map(arg=>escape.argument(arg,needsDoubleEscapeMetaChars));let shellCommand=[parsed.command].concat(parsed.args).join(" ");parsed.args=["/d","/s","/c",`"${shellCommand}"`],parsed.command=process.env.comspec||"cmd.exe",parsed.options.windowsVerbatimArguments=!0}return parsed}function parseShell(parsed){if(supportsShellOption)return parsed;let shellCommand=[parsed.command].concat(parsed.args).join(" ");return isWin2?(parsed.command=typeof parsed.options.shell=="string"?parsed.options.shell:process.env.comspec||"cmd.exe",parsed.args=["/d","/s","/c",`"${shellCommand}"`],parsed.options.windowsVerbatimArguments=!0):(typeof parsed.options.shell=="string"?parsed.command=parsed.options.shell:process.platform==="android"?parsed.command="/system/bin/sh":parsed.command="/bin/sh",parsed.args=["-c",shellCommand]),parsed}function parse6(command,args,options){args&&!Array.isArray(args)&&(options=args,args=null),args=args?args.slice(0):[],options=Object.assign({},options);let parsed={command,args,options,file:void 0,original:{command,args}};return options.shell?parseShell(parsed):parseNonShell(parsed)}module2.exports=parse6}});var require_enoent=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/lib/enoent.js"(exports2,module2){"use strict";var isWin2=process.platform==="win32";function notFoundError(original,syscall){return Object.assign(new Error(`${syscall} ${original.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${syscall} ${original.command}`,path:original.command,spawnargs:original.args})}function hookChildProcess(cp,parsed){if(!isWin2)return;let originalEmit=cp.emit;cp.emit=function(name,arg1){if(name==="exit"){let err=verifyENOENT(arg1,parsed,"spawn");if(err)return originalEmit.call(cp,"error",err)}return originalEmit.apply(cp,arguments)}}function verifyENOENT(status,parsed){return isWin2&&status===1&&!parsed.file?notFoundError(parsed.original,"spawn"):null}function verifyENOENTSync(status,parsed){return isWin2&&status===1&&!parsed.file?notFoundError(parsed.original,"spawnSync"):null}module2.exports={hookChildProcess,verifyENOENT,verifyENOENTSync,notFoundError}}});var require_cross_spawn=__commonJS({"../../node_modules/.pnpm/cross-spawn@6.0.5/node_modules/cross-spawn/index.js"(exports2,module2){"use strict";var cp=require("child_process"),parse6=require_parse(),enoent=require_enoent();function spawn3(command,args,options){let parsed=parse6(command,args,options),spawned=cp.spawn(parsed.command,parsed.args,parsed.options);return enoent.hookChildProcess(spawned,parsed),spawned}function spawnSync(command,args,options){let parsed=parse6(command,args,options),result=cp.spawnSync(parsed.command,parsed.args,parsed.options);return result.error=result.error||enoent.verifyENOENTSync(result.status,parsed),result}module2.exports=spawn3;module2.exports.spawn=spawn3;module2.exports.sync=spawnSync;module2.exports._parse=parse6;module2.exports._enoent=enoent}});var require_semver2=__commonJS({"../../node_modules/.pnpm/semver@6.3.1/node_modules/semver/semver.js"(exports2,module2){exports2=module2.exports=SemVer2;var debug2;typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?debug2=function(){var args=Array.prototype.slice.call(arguments,0);args.unshift("SEMVER"),console.log.apply(console,args)}:debug2=function(){};exports2.SEMVER_SPEC_VERSION="2.0.0";var MAX_LENGTH=256,MAX_SAFE_INTEGER=Number.MAX_SAFE_INTEGER||9007199254740991,MAX_SAFE_COMPONENT_LENGTH=16,MAX_SAFE_BUILD_LENGTH=MAX_LENGTH-6,re=exports2.re=[],safeRe=exports2.safeRe=[],src=exports2.src=[],t=exports2.tokens={},R=0;function tok(n){t[n]=R++}var LETTERDASHNUMBER="[a-zA-Z0-9-]",safeRegexReplacements=[["\\s",1],["\\d",MAX_LENGTH],[LETTERDASHNUMBER,MAX_SAFE_BUILD_LENGTH]];function makeSafeRe(value){for(var i2=0;i2<safeRegexReplacements.length;i2++){var token=safeRegexReplacements[i2][0],max=safeRegexReplacements[i2][1];value=value.split(token+"*").join(token+"{0,"+max+"}").split(token+"+").join(token+"{1,"+max+"}")}return value}tok("NUMERICIDENTIFIER");src[t.NUMERICIDENTIFIER]="0|[1-9]\\d*";tok("NUMERICIDENTIFIERLOOSE");src[t.NUMERICIDENTIFIERLOOSE]="\\d+";tok("NONNUMERICIDENTIFIER");src[t.NONNUMERICIDENTIFIER]="\\d*[a-zA-Z-]"+LETTERDASHNUMBER+"*";tok("MAINVERSION");src[t.MAINVERSION]="("+src[t.NUMERICIDENTIFIER]+")\\.("+src[t.NUMERICIDENTIFIER]+")\\.("+src[t.NUMERICIDENTIFIER]+")";tok("MAINVERSIONLOOSE");src[t.MAINVERSIONLOOSE]="("+src[t.NUMERICIDENTIFIERLOOSE]+")\\.("+src[t.NUMERICIDENTIFIERLOOSE]+")\\.("+src[t.NUMERICIDENTIFIERLOOSE]+")";tok("PRERELEASEIDENTIFIER");src[t.PRERELEASEIDENTIFIER]="(?:"+src[t.NUMERICIDENTIFIER]+"|"+src[t.NONNUMERICIDENTIFIER]+")";tok("PRERELEASEIDENTIFIERLOOSE");src[t.PRERELEASEIDENTIFIERLOOSE]="(?:"+src[t.NUMERICIDENTIFIERLOOSE]+"|"+src[t.NONNUMERICIDENTIFIER]+")";tok("PRERELEASE");src[t.PRERELEASE]="(?:-("+src[t.PRERELEASEIDENTIFIER]+"(?:\\."+src[t.PRERELEASEIDENTIFIER]+")*))";tok("PRERELEASELOOSE");src[t.PRERELEASELOOSE]="(?:-?("+src[t.PRERELEASEIDENTIFIERLOOSE]+"(?:\\."+src[t.PRERELEASEIDENTIFIERLOOSE]+")*))";tok("BUILDIDENTIFIER");src[t.BUILDIDENTIFIER]=LETTERDASHNUMBER+"+";tok("BUILD");src[t.BUILD]="(?:\\+("+src[t.BUILDIDENTIFIER]+"(?:\\."+src[t.BUILDIDENTIFIER]+")*))";tok("FULL");tok("FULLPLAIN");src[t.FULLPLAIN]="v?"+src[t.MAINVERSION]+src[t.PRERELEASE]+"?"+src[t.BUILD]+"?";src[t.FULL]="^"+src[t.FULLPLAIN]+"$";tok("LOOSEPLAIN");src[t.LOOSEPLAIN]="[v=\\s]*"+src[t.MAINVERSIONLOOSE]+src[t.PRERELEASELOOSE]+"?"+src[t.BUILD]+"?";tok("LOOSE");src[t.LOOSE]="^"+src[t.LOOSEPLAIN]+"$";tok("GTLT");src[t.GTLT]="((?:<|>)?=?)";tok("XRANGEIDENTIFIERLOOSE");src[t.XRANGEIDENTIFIERLOOSE]=src[t.NUMERICIDENTIFIERLOOSE]+"|x|X|\\*";tok("XRANGEIDENTIFIER");src[t.XRANGEIDENTIFIER]=src[t.NUMERICIDENTIFIER]+"|x|X|\\*";tok("XRANGEPLAIN");src[t.XRANGEPLAIN]="[v=\\s]*("+src[t.XRANGEIDENTIFIER]+")(?:\\.("+src[t.XRANGEIDENTIFIER]+")(?:\\.("+src[t.XRANGEIDENTIFIER]+")(?:"+src[t.PRERELEASE]+")?"+src[t.BUILD]+"?)?)?";tok("XRANGEPLAINLOOSE");src[t.XRANGEPLAINLOOSE]="[v=\\s]*("+src[t.XRANGEIDENTIFIERLOOSE]+")(?:\\.("+src[t.XRANGEIDENTIFIERLOOSE]+")(?:\\.("+src[t.XRANGEIDENTIFIERLOOSE]+")(?:"+src[t.PRERELEASELOOSE]+")?"+src[t.BUILD]+"?)?)?";tok("XRANGE");src[t.XRANGE]="^"+src[t.GTLT]+"\\s*"+src[t.XRANGEPLAIN]+"$";tok("XRANGELOOSE");src[t.XRANGELOOSE]="^"+src[t.GTLT]+"\\s*"+src[t.XRANGEPLAINLOOSE]+"$";tok("COERCE");src[t.COERCE]="(^|[^\\d])(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"})(?:\\.(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"}))?(?:\\.(\\d{1,"+MAX_SAFE_COMPONENT_LENGTH+"}))?(?:$|[^\\d])";tok("COERCERTL");re[t.COERCERTL]=new RegExp(src[t.COERCE],"g");safeRe[t.COERCERTL]=new RegExp(makeSafeRe(src[t.COERCE]),"g");tok("LONETILDE");src[t.LONETILDE]="(?:~>?)";tok("TILDETRIM");src[t.TILDETRIM]="(\\s*)"+src[t.LONETILDE]+"\\s+";re[t.TILDETRIM]=new RegExp(src[t.TILDETRIM],"g");safeRe[t.TILDETRIM]=new RegExp(makeSafeRe(src[t.TILDETRIM]),"g");var tildeTrimReplace="$1~";tok("TILDE");src[t.TILDE]="^"+src[t.LONETILDE]+src[t.XRANGEPLAIN]+"$";tok("TILDELOOSE");src[t.TILDELOOSE]="^"+src[t.LONETILDE]+src[t.XRANGEPLAINLOOSE]+"$";tok("LONECARET");src[t.LONECARET]="(?:\\^)";tok("CARETTRIM");src[t.CARETTRIM]="(\\s*)"+src[t.LONECARET]+"\\s+";re[t.CARETTRIM]=new RegExp(src[t.CARETTRIM],"g");safeRe[t.CARETTRIM]=new RegExp(makeSafeRe(src[t.CARETTRIM]),"g");var caretTrimReplace="$1^";tok("CARET");src[t.CARET]="^"+src[t.LONECARET]+src[t.XRANGEPLAIN]+"$";tok("CARETLOOSE");src[t.CARETLOOSE]="^"+src[t.LONECARET]+src[t.XRANGEPLAINLOOSE]+"$";tok("COMPARATORLOOSE");src[t.COMPARATORLOOSE]="^"+src[t.GTLT]+"\\s*("+src[t.LOOSEPLAIN]+")$|^$";tok("COMPARATOR");src[t.COMPARATOR]="^"+src[t.GTLT]+"\\s*("+src[t.FULLPLAIN]+")$|^$";tok("COMPARATORTRIM");src[t.COMPARATORTRIM]="(\\s*)"+src[t.GTLT]+"\\s*("+src[t.LOOSEPLAIN]+"|"+src[t.XRANGEPLAIN]+")";re[t.COMPARATORTRIM]=new RegExp(src[t.COMPARATORTRIM],"g");safeRe[t.COMPARATORTRIM]=new RegExp(makeSafeRe(src[t.COMPARATORTRIM]),"g");var comparatorTrimReplace="$1$2$3";tok("HYPHENRANGE");src[t.HYPHENRANGE]="^\\s*("+src[t.XRANGEPLAIN]+")\\s+-\\s+("+src[t.XRANGEPLAIN]+")\\s*$";tok("HYPHENRANGELOOSE");src[t.HYPHENRANGELOOSE]="^\\s*("+src[t.XRANGEPLAINLOOSE]+")\\s+-\\s+("+src[t.XRANGEPLAINLOOSE]+")\\s*$";tok("STAR");src[t.STAR]="(<|>)?=?\\s*\\*";for(i=0;i<R;i++)debug2(i,src[i]),re[i]||(re[i]=new RegExp(src[i]),safeRe[i]=new RegExp(makeSafeRe(src[i])));var i;exports2.parse=parse6;function parse6(version,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),version instanceof SemVer2)return version;if(typeof version!="string"||version.length>MAX_LENGTH)return null;var r=options.loose?safeRe[t.LOOSE]:safeRe[t.FULL];if(!r.test(version))return null;try{return new SemVer2(version,options)}catch{return null}}exports2.valid=valid;function valid(version,options){var v=parse6(version,options);return v?v.version:null}exports2.clean=clean;function clean(version,options){var s=parse6(version.trim().replace(/^[=v]+/,""),options);return s?s.version:null}exports2.SemVer=SemVer2;function SemVer2(version,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),version instanceof SemVer2){if(version.loose===options.loose)return version;version=version.version}else if(typeof version!="string")throw new TypeError("Invalid Version: "+version);if(version.length>MAX_LENGTH)throw new TypeError("version is longer than "+MAX_LENGTH+" characters");if(!(this instanceof SemVer2))return new SemVer2(version,options);debug2("SemVer",version,options),this.options=options,this.loose=!!options.loose;var m=version.trim().match(options.loose?safeRe[t.LOOSE]:safeRe[t.FULL]);if(!m)throw new TypeError("Invalid Version: "+version);if(this.raw=version,this.major=+m[1],this.minor=+m[2],this.patch=+m[3],this.major>MAX_SAFE_INTEGER||this.major<0)throw new TypeError("Invalid major version");if(this.minor>MAX_SAFE_INTEGER||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>MAX_SAFE_INTEGER||this.patch<0)throw new TypeError("Invalid patch version");m[4]?this.prerelease=m[4].split(".").map(function(id){if(/^[0-9]+$/.test(id)){var num=+id;if(num>=0&&num<MAX_SAFE_INTEGER)return num}return id}):this.prerelease=[],this.build=m[5]?m[5].split("."):[],this.format()}SemVer2.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version};SemVer2.prototype.toString=function(){return this.version};SemVer2.prototype.compare=function(other){return debug2("SemVer.compare",this.version,this.options,other),other instanceof SemVer2||(other=new SemVer2(other,this.options)),this.compareMain(other)||this.comparePre(other)};SemVer2.prototype.compareMain=function(other){return other instanceof SemVer2||(other=new SemVer2(other,this.options)),compareIdentifiers(this.major,other.major)||compareIdentifiers(this.minor,other.minor)||compareIdentifiers(this.patch,other.patch)};SemVer2.prototype.comparePre=function(other){if(other instanceof SemVer2||(other=new SemVer2(other,this.options)),this.prerelease.length&&!other.prerelease.length)return-1;if(!this.prerelease.length&&other.prerelease.length)return 1;if(!this.prerelease.length&&!other.prerelease.length)return 0;var i2=0;do{var a=this.prerelease[i2],b=other.prerelease[i2];if(debug2("prerelease compare",i2,a,b),a===void 0&&b===void 0)return 0;if(b===void 0)return 1;if(a===void 0)return-1;if(a===b)continue;return compareIdentifiers(a,b)}while(++i2)};SemVer2.prototype.compareBuild=function(other){other instanceof SemVer2||(other=new SemVer2(other,this.options));var i2=0;do{var a=this.build[i2],b=other.build[i2];if(debug2("prerelease compare",i2,a,b),a===void 0&&b===void 0)return 0;if(b===void 0)return 1;if(a===void 0)return-1;if(a===b)continue;return compareIdentifiers(a,b)}while(++i2)};SemVer2.prototype.inc=function(release,identifier){switch(release){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",identifier);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",identifier);break;case"prepatch":this.prerelease.length=0,this.inc("patch",identifier),this.inc("pre",identifier);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",identifier),this.inc("pre",identifier);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{for(var i2=this.prerelease.length;--i2>=0;)typeof this.prerelease[i2]=="number"&&(this.prerelease[i2]++,i2=-2);i2===-1&&this.prerelease.push(0)}identifier&&(this.prerelease[0]===identifier?isNaN(this.prerelease[1])&&(this.prerelease=[identifier,0]):this.prerelease=[identifier,0]);break;default:throw new Error("invalid increment argument: "+release)}return this.format(),this.raw=this.version,this};exports2.inc=inc;function inc(version,release,loose,identifier){typeof loose=="string"&&(identifier=loose,loose=void 0);try{return new SemVer2(version,loose).inc(release,identifier).version}catch{return null}}exports2.diff=diff;function diff(version1,version2){if(eq(version1,version2))return null;var v1=parse6(version1),v2=parse6(version2),prefix="";if(v1.prerelease.length||v2.prerelease.length){prefix="pre";var defaultResult="prerelease"}for(var key in v1)if((key==="major"||key==="minor"||key==="patch")&&v1[key]!==v2[key])return prefix+key;return defaultResult}exports2.compareIdentifiers=compareIdentifiers;var numeric=/^[0-9]+$/;function compareIdentifiers(a,b){var anum=numeric.test(a),bnum=numeric.test(b);return anum&&bnum&&(a=+a,b=+b),a===b?0:anum&&!bnum?-1:bnum&&!anum?1:a<b?-1:1}exports2.rcompareIdentifiers=rcompareIdentifiers;function rcompareIdentifiers(a,b){return compareIdentifiers(b,a)}exports2.major=major;function major(a,loose){return new SemVer2(a,loose).major}exports2.minor=minor;function minor(a,loose){return new SemVer2(a,loose).minor}exports2.patch=patch;function patch(a,loose){return new SemVer2(a,loose).patch}exports2.compare=compare;function compare(a,b,loose){return new SemVer2(a,loose).compare(new SemVer2(b,loose))}exports2.compareLoose=compareLoose;function compareLoose(a,b){return compare(a,b,!0)}exports2.compareBuild=compareBuild;function compareBuild(a,b,loose){var versionA=new SemVer2(a,loose),versionB=new SemVer2(b,loose);return versionA.compare(versionB)||versionA.compareBuild(versionB)}exports2.rcompare=rcompare;function rcompare(a,b,loose){return compare(b,a,loose)}exports2.sort=sort;function sort(list,loose){return list.sort(function(a,b){return exports2.compareBuild(a,b,loose)})}exports2.rsort=rsort;function rsort(list,loose){return list.sort(function(a,b){return exports2.compareBuild(b,a,loose)})}exports2.gt=gt;function gt(a,b,loose){return compare(a,b,loose)>0}exports2.lt=lt;function lt(a,b,loose){return compare(a,b,loose)<0}exports2.eq=eq;function eq(a,b,loose){return compare(a,b,loose)===0}exports2.neq=neq;function neq(a,b,loose){return compare(a,b,loose)!==0}exports2.gte=gte2;function gte2(a,b,loose){return compare(a,b,loose)>=0}exports2.lte=lte;function lte(a,b,loose){return compare(a,b,loose)<=0}exports2.cmp=cmp;function cmp(a,op,b,loose){switch(op){case"===":return typeof a=="object"&&(a=a.version),typeof b=="object"&&(b=b.version),a===b;case"!==":return typeof a=="object"&&(a=a.version),typeof b=="object"&&(b=b.version),a!==b;case"":case"=":case"==":return eq(a,b,loose);case"!=":return neq(a,b,loose);case">":return gt(a,b,loose);case">=":return gte2(a,b,loose);case"<":return lt(a,b,loose);case"<=":return lte(a,b,loose);default:throw new TypeError("Invalid operator: "+op)}}exports2.Comparator=Comparator;function Comparator(comp,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),comp instanceof Comparator){if(comp.loose===!!options.loose)return comp;comp=comp.value}if(!(this instanceof Comparator))return new Comparator(comp,options);comp=comp.trim().split(/\s+/).join(" "),debug2("comparator",comp,options),this.options=options,this.loose=!!options.loose,this.parse(comp),this.semver===ANY?this.value="":this.value=this.operator+this.semver.version,debug2("comp",this)}var ANY={};Comparator.prototype.parse=function(comp){var r=this.options.loose?safeRe[t.COMPARATORLOOSE]:safeRe[t.COMPARATOR],m=comp.match(r);if(!m)throw new TypeError("Invalid comparator: "+comp);this.operator=m[1]!==void 0?m[1]:"",this.operator==="="&&(this.operator=""),m[2]?this.semver=new SemVer2(m[2],this.options.loose):this.semver=ANY};Comparator.prototype.toString=function(){return this.value};Comparator.prototype.test=function(version){if(debug2("Comparator.test",version,this.options.loose),this.semver===ANY||version===ANY)return!0;if(typeof version=="string")try{version=new SemVer2(version,this.options)}catch{return!1}return cmp(version,this.operator,this.semver,this.options)};Comparator.prototype.intersects=function(comp,options){if(!(comp instanceof Comparator))throw new TypeError("a Comparator is required");(!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1});var rangeTmp;if(this.operator==="")return this.value===""?!0:(rangeTmp=new Range(comp.value,options),satisfies2(this.value,rangeTmp,options));if(comp.operator==="")return comp.value===""?!0:(rangeTmp=new Range(this.value,options),satisfies2(comp.semver,rangeTmp,options));var sameDirectionIncreasing=(this.operator===">="||this.operator===">")&&(comp.operator===">="||comp.operator===">"),sameDirectionDecreasing=(this.operator==="<="||this.operator==="<")&&(comp.operator==="<="||comp.operator==="<"),sameSemVer=this.semver.version===comp.semver.version,differentDirectionsInclusive=(this.operator===">="||this.operator==="<=")&&(comp.operator===">="||comp.operator==="<="),oppositeDirectionsLessThan=cmp(this.semver,"<",comp.semver,options)&&(this.operator===">="||this.operator===">")&&(comp.operator==="<="||comp.operator==="<"),oppositeDirectionsGreaterThan=cmp(this.semver,">",comp.semver,options)&&(this.operator==="<="||this.operator==="<")&&(comp.operator===">="||comp.operator===">");return sameDirectionIncreasing||sameDirectionDecreasing||sameSemVer&&differentDirectionsInclusive||oppositeDirectionsLessThan||oppositeDirectionsGreaterThan};exports2.Range=Range;function Range(range,options){if((!options||typeof options!="object")&&(options={loose:!!options,includePrerelease:!1}),range instanceof Range)return range.loose===!!options.loose&&range.includePrerelease===!!options.includePrerelease?range:new Range(range.raw,options);if(range instanceof Comparator)return new Range(range.value,options);if(!(this instanceof Range))return new Range(range,options);if(this.options=options,this.loose=!!options.loose,this.includePrerelease=!!options.includePrerelease,this.raw=range.trim().split(/\s+/).join(" "),this.set=this.raw.split("||").map(function(range2){return this.parseRange(range2.trim())},this).filter(function(c){return c.length}),!this.set.length)throw new TypeError("Invalid SemVer Range: "+this.raw);this.format()}Range.prototype.format=function(){return this.range=this.set.map(function(comps){return comps.join(" ").trim()}).join("||").trim(),this.range};Range.prototype.toString=function(){return this.range};Range.prototype.parseRange=function(range){var loose=this.options.loose,hr=loose?safeRe[t.HYPHENRANGELOOSE]:safeRe[t.HYPHENRANGE];range=range.replace(hr,hyphenReplace),debug2("hyphen replace",range),range=range.replace(safeRe[t.COMPARATORTRIM],comparatorTrimReplace),debug2("comparator trim",range,safeRe[t.COMPARATORTRIM]),range=range.replace(safeRe[t.TILDETRIM],tildeTrimReplace),range=range.replace(safeRe[t.CARETTRIM],caretTrimReplace),range=range.split(/\s+/).join(" ");var compRe=loose?safeRe[t.COMPARATORLOOSE]:safeRe[t.COMPARATOR],set=range.split(" ").map(function(comp){return parseComparator(comp,this.options)},this).join(" ").split(/\s+/);return this.options.loose&&(set=set.filter(function(comp){return!!comp.match(compRe)})),set=set.map(function(comp){return new Comparator(comp,this.options)},this),set};Range.prototype.intersects=function(range,options){if(!(range instanceof Range))throw new TypeError("a Range is required");return this.set.some(function(thisComparators){return isSatisfiable(thisComparators,options)&&range.set.some(function(rangeComparators){return isSatisfiable(rangeComparators,options)&&thisComparators.every(function(thisComparator){return rangeComparators.every(function(rangeComparator){return thisComparator.intersects(rangeComparator,options)})})})})};function isSatisfiable(comparators,options){for(var result=!0,remainingComparators=comparators.slice(),testComparator=remainingComparators.pop();result&&remainingComparators.length;)result=remainingComparators.every(function(otherComparator){return testComparator.intersects(otherComparator,options)}),testComparator=remainingComparators.pop();return result}exports2.toComparators=toComparators;function toComparators(range,options){return new Range(range,options).set.map(function(comp){return comp.map(function(c){return c.value}).join(" ").trim().split(" ")})}function parseComparator(comp,options){return debug2("comp",comp,options),comp=replaceCarets(comp,options),debug2("caret",comp),comp=replaceTildes(comp,options),debug2("tildes",comp),comp=replaceXRanges(comp,options),debug2("xrange",comp),comp=replaceStars(comp,options),debug2("stars",comp),comp}function isX(id){return!id||id.toLowerCase()==="x"||id==="*"}function replaceTildes(comp,options){return comp.trim().split(/\s+/).map(function(comp2){return replaceTilde(comp2,options)}).join(" ")}function replaceTilde(comp,options){var r=options.loose?safeRe[t.TILDELOOSE]:safeRe[t.TILDE];return comp.replace(r,function(_,M,m,p,pr){debug2("tilde",comp,_,M,m,p,pr);var ret;return isX(M)?ret="":isX(m)?ret=">="+M+".0.0 <"+(+M+1)+".0.0":isX(p)?ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0":pr?(debug2("replaceTilde pr",pr),ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+(+m+1)+".0"):ret=">="+M+"."+m+"."+p+" <"+M+"."+(+m+1)+".0",debug2("tilde return",ret),ret})}function replaceCarets(comp,options){return comp.trim().split(/\s+/).map(function(comp2){return replaceCaret(comp2,options)}).join(" ")}function replaceCaret(comp,options){debug2("caret",comp,options);var r=options.loose?safeRe[t.CARETLOOSE]:safeRe[t.CARET];return comp.replace(r,function(_,M,m,p,pr){debug2("caret",comp,_,M,m,p,pr);var ret;return isX(M)?ret="":isX(m)?ret=">="+M+".0.0 <"+(+M+1)+".0.0":isX(p)?M==="0"?ret=">="+M+"."+m+".0 <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+".0 <"+(+M+1)+".0.0":pr?(debug2("replaceCaret pr",pr),M==="0"?m==="0"?ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+m+"."+(+p+1):ret=">="+M+"."+m+"."+p+"-"+pr+" <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+"."+p+"-"+pr+" <"+(+M+1)+".0.0"):(debug2("no pr"),M==="0"?m==="0"?ret=">="+M+"."+m+"."+p+" <"+M+"."+m+"."+(+p+1):ret=">="+M+"."+m+"."+p+" <"+M+"."+(+m+1)+".0":ret=">="+M+"."+m+"."+p+" <"+(+M+1)+".0.0"),debug2("caret return",ret),ret})}function replaceXRanges(comp,options){return debug2("replaceXRanges",comp,options),comp.split(/\s+/).map(function(comp2){return replaceXRange(comp2,options)}).join(" ")}function replaceXRange(comp,options){comp=comp.trim();var r=options.loose?safeRe[t.XRANGELOOSE]:safeRe[t.XRANGE];return comp.replace(r,function(ret,gtlt,M,m,p,pr){debug2("xRange",comp,ret,gtlt,M,m,p,pr);var xM=isX(M),xm=xM||isX(m),xp=xm||isX(p),anyX=xp;return gtlt==="="&&anyX&&(gtlt=""),pr=options.includePrerelease?"-0":"",xM?gtlt===">"||gtlt==="<"?ret="<0.0.0-0":ret="*":gtlt&&anyX?(xm&&(m=0),p=0,gtlt===">"?(gtlt=">=",xm?(M=+M+1,m=0,p=0):(m=+m+1,p=0)):gtlt==="<="&&(gtlt="<",xm?M=+M+1:m=+m+1),ret=gtlt+M+"."+m+"."+p+pr):xm?ret=">="+M+".0.0"+pr+" <"+(+M+1)+".0.0"+pr:xp&&(ret=">="+M+"."+m+".0"+pr+" <"+M+"."+(+m+1)+".0"+pr),debug2("xRange return",ret),ret})}function replaceStars(comp,options){return debug2("replaceStars",comp,options),comp.trim().replace(safeRe[t.STAR],"")}function hyphenReplace($0,from,fM,fm,fp,fpr,fb,to,tM,tm,tp,tpr,tb){return isX(fM)?from="":isX(fm)?from=">="+fM+".0.0":isX(fp)?from=">="+fM+"."+fm+".0":from=">="+from,isX(tM)?to="":isX(tm)?to="<"+(+tM+1)+".0.0":isX(tp)?to="<"+tM+"."+(+tm+1)+".0":tpr?to="<="+tM+"."+tm+"."+tp+"-"+tpr:to="<="+to,(from+" "+to).trim()}Range.prototype.test=function(version){if(!version)return!1;if(typeof version=="string")try{version=new SemVer2(version,this.options)}catch{return!1}for(var i2=0;i2<this.set.length;i2++)if(testSet(this.set[i2],version,this.options))return!0;return!1};function testSet(set,version,options){for(var i2=0;i2<set.length;i2++)if(!set[i2].test(version))return!1;if(version.prerelease.length&&!options.includePrerelease){for(i2=0;i2<set.length;i2++)if(debug2(set[i2].semver),set[i2].semver!==ANY&&set[i2].semver.prerelease.length>0){var allowed=set[i2].semver;if(allowed.major===version.major&&allowed.minor===version.minor&&allowed.patch===version.patch)return!0}return!1}return!0}exports2.satisfies=satisfies2;function satisfies2(version,range,options){try{range=new Range(range,options)}catch{return!1}return range.test(version)}exports2.maxSatisfying=maxSatisfying;function maxSatisfying(versions,range,options){var max=null,maxSV=null;try{var rangeObj=new Range(range,options)}catch{return null}return versions.forEach(function(v){rangeObj.test(v)&&(!max||maxSV.compare(v)===-1)&&(max=v,maxSV=new SemVer2(max,options))}),max}exports2.minSatisfying=minSatisfying;function minSatisfying(versions,range,options){var min=null,minSV=null;try{var rangeObj=new Range(range,options)}catch{return null}return versions.forEach(function(v){rangeObj.test(v)&&(!min||minSV.compare(v)===1)&&(min=v,minSV=new SemVer2(min,options))}),min}exports2.minVersion=minVersion2;function minVersion2(range,loose){range=new Range(range,loose);var minver=new SemVer2("0.0.0");if(range.test(minver)||(minver=new SemVer2("0.0.0-0"),range.test(minver)))return minver;minver=null;for(var i2=0;i2<range.set.length;++i2){var comparators=range.set[i2];comparators.forEach(function(comparator){var compver=new SemVer2(comparator.semver.version);switch(comparator.operator){case">":compver.prerelease.length===0?compver.patch++:compver.prerelease.push(0),compver.raw=compver.format();case"":case">=":(!minver||gt(minver,compver))&&(minver=compver);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+comparator.operator)}})}return minver&&range.test(minver)?minver:null}exports2.validRange=validRange3;function validRange3(range,options){try{return new Range(range,options).range||"*"}catch{return null}}exports2.ltr=ltr;function ltr(version,range,options){return outside(version,range,"<",options)}exports2.gtr=gtr;function gtr(version,range,options){return outside(version,range,">",options)}exports2.outside=outside;function outside(version,range,hilo,options){version=new SemVer2(version,options),range=new Range(range,options);var gtfn,ltefn,ltfn,comp,ecomp;switch(hilo){case">":gtfn=gt,ltefn=lte,ltfn=lt,comp=">",ecomp=">=";break;case"<":gtfn=lt,ltefn=gte2,ltfn=gt,comp="<",ecomp="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(satisfies2(version,range,options))return!1;for(var i2=0;i2<range.set.length;++i2){var comparators=range.set[i2],high=null,low=null;if(comparators.forEach(function(comparator){comparator.semver===ANY&&(comparator=new Comparator(">=0.0.0")),high=high||comparator,low=low||comparator,gtfn(comparator.semver,high.semver,options)?high=comparator:ltfn(comparator.semver,low.semver,options)&&(low=comparator)}),high.operator===comp||high.operator===ecomp||(!low.operator||low.operator===comp)&&ltefn(version,low.semver))return!1;if(low.operator===ecomp&&ltfn(version,low.semver))return!1}return!0}exports2.prerelease=prerelease;function prerelease(version,options){var parsed=parse6(version,options);return parsed&&parsed.prerelease.length?parsed.prerelease:null}exports2.intersects=intersects3;function intersects3(r1,r2,options){return r1=new Range(r1,options),r2=new Range(r2,options),r1.intersects(r2)}exports2.coerce=coerce2;function coerce2(version,options){if(version instanceof SemVer2)return version;if(typeof version=="number"&&(version=String(version)),typeof version!="string")return null;options=options||{};var match=null;if(!options.rtl)match=version.match(safeRe[t.COERCE]);else{for(var next;(next=safeRe[t.COERCERTL].exec(version))&&(!match||match.index+match[0].length!==version.length);)(!match||next.index+next[0].length!==match.index+match[0].length)&&(match=next),safeRe[t.COERCERTL].lastIndex=next.index+next[1].length+next[2].length;safeRe[t.COERCERTL].lastIndex=-1}return match===null?null:parse6(match[2]+"."+(match[3]||"0")+"."+(match[4]||"0"),options)}}});var types_exports={};__export(types_exports,{BunVersion:()=>BunVersion,JOB_TRIGGERS:()=>JOB_TRIGGERS,NodeVersion:()=>NodeVersion,Version:()=>Version,getReportedServiceType:()=>getReportedServiceType,getServiceQueueTopicConfigs:()=>getServiceQueueTopicConfigs,getServiceQueueTopics:()=>getServiceQueueTopics,isExperimentalService:()=>isExperimentalService,isExperimentalServiceV2:()=>isExperimentalServiceV2,isQueueBackedService:()=>isQueueBackedService,isQueueTriggeredService:()=>isQueueTriggeredService,isScheduleTriggeredService:()=>isScheduleTriggeredService,isWorkflowTriggeredService:()=>isWorkflowTriggeredService});function isExperimentalService(service){return service.schema==="experimentalServices"}function isExperimentalServiceV2(service){return service.schema==="experimentalServicesV2"}function getServiceQueueTopicConfigs(config){return Array.isArray(config.topics)&&config.topics.length>0?typeof config.topics[0]=="string"?config.topics.map(topic=>({topic})):config.topics:config.type==="worker"?[{topic:"default"}]:[]}function getServiceQueueTopics(config){return getServiceQueueTopicConfigs(config).map(topic=>topic.topic)}function isQueueTriggeredService(service){return service.type==="worker"||service.type==="job"&&service.trigger==="queue"}function isScheduleTriggeredService(service){return service.type==="cron"||service.type==="job"&&service.trigger==="schedule"}function isWorkflowTriggeredService(service){return service.type==="job"&&service.trigger==="workflow"}function isQueueBackedService(service){return isQueueTriggeredService(service)||isWorkflowTriggeredService(service)}function getReportedServiceType(service){switch(service.type){case"web":return"web";case"cron":return"schedule";case"worker":return"queue";case"job":return service.trigger==="schedule"?"schedule":service.trigger==="queue"?"queue":service.trigger==="workflow"?"workflow":void 0;default:return}}var Version,NodeVersion,BunVersion,JOB_TRIGGERS,init_types=__esm({"src/types.ts"(){"use strict";Version=class{constructor(version){this.major=version.major,this.minor=version.minor,this.range=version.range,this.runtime=version.runtime,this.discontinueDate=version.discontinueDate}get state(){return this.discontinueDate&&this.discontinueDate.getTime()<=Date.now()?"discontinued":this.discontinueDate?"deprecated":"active"}get formattedDate(){return this.discontinueDate&&this.discontinueDate.toISOString().split("T")[0]}},NodeVersion=class extends Version{},BunVersion=class extends Version{},JOB_TRIGGERS=["queue","schedule","workflow"]}});var node_version_exports={};__export(node_version_exports,{BUN_VERSIONS:()=>BUN_VERSIONS,NODE_VERSIONS:()=>NODE_VERSIONS,getAvailableNodeVersions:()=>getAvailableNodeVersions,getDiscontinuedNodeVersions:()=>getDiscontinuedNodeVersions,getLatestNodeVersion:()=>getLatestNodeVersion,getNodeVersionByMajor:()=>getNodeVersionByMajor,getSupportedBunVersion:()=>getSupportedBunVersion,getSupportedNodeVersion:()=>getSupportedNodeVersion,isBunVersion:()=>isBunVersion});function getNodeVersionByMajor(major){return getOptions().find(v=>v.major===major)}function getOptions(){return process.env.VERCEL_ALLOW_DISCONTINUED_NODEJS20==="1"?NODE_VERSIONS.map(version=>version.major===20?new NodeVersion({...version,discontinueDate:new Date("2026-11-01")}):version):NODE_VERSIONS}function isNodeVersionAvailable(version){return(0,import_fs.statSync)(`/node${version.major}`,{throwIfNoEntry:!1})?.isDirectory()??!1}function getAvailableNodeVersions(){return getOptions().filter(v=>v.major>=18).filter(isNodeVersionAvailable).map(n=>n.major)}function getHint(isAuto=!1,availableVersions){let{major,range}=getLatestNodeVersion(availableVersions);return isAuto?`Please set Node.js Version to ${range} in your Project Settings to use Node.js ${major}.`:`Please set "engines": { "node": "${range}" } in your \`package.json\` file to use Node.js ${major}.`}function getLatestNodeVersion(availableVersions){let all=getOptions();if(availableVersions){for(let version of all)for(let major of availableVersions)if(version.major===major)return version}return all[0]}function getDiscontinuedNodeVersions(){return getOptions().filter(version=>version.state==="discontinued")}async function getSupportedNodeVersion(engineRange,isAuto=!1,availableVersions){let selection;if(engineRange&&!((0,import_semver.validRange)(engineRange)&&getOptions().some(o=>(selection=o,(0,import_semver.intersects)(o.range,engineRange)&&(availableVersions?.length?availableVersions.includes(o.major):!0)))))throw new NowBuildError({code:"BUILD_UTILS_NODE_VERSION_INVALID",link:"https://vercel.link/node-version",message:`Found invalid or discontinued Node.js Version: "${engineRange}". ${getHint(isAuto,availableVersions)}`});if(selection||(selection=getLatestNodeVersion(availableVersions)),selection.state==="discontinued"){let intro=`Node.js Version "${selection.range}" is discontinued and must be upgraded.`;throw new NowBuildError({code:"BUILD_UTILS_NODE_VERSION_DISCONTINUED",link:"https://vercel.link/node-version",message:`${intro} ${getHint(isAuto)}`})}if(debug(`Selected Node.js ${selection.range}`),selection.state==="deprecated"){let d=selection.formattedDate;console.warn(d?`Error: Node.js version ${selection.range} is deprecated. Deployments created on or after ${d} will fail to build. ${getHint(isAuto)}`:`Error: Node.js version ${selection.range} is deprecated. ${getHint(isAuto)}`)}return selection}function getSupportedBunVersion(engineRange){if((0,import_semver.validRange)(engineRange)){let selected=BUN_VERSIONS.find(version=>(0,import_semver.intersects)(version.range,engineRange)?version.minor===void 0?!0:!(0,import_semver.intersects)(`<${version.major}.${version.minor}.0`,engineRange):!1);if(selected)return new BunVersion({major:selected.major,minor:selected.minor,range:selected.range,runtime:selected.runtime})}throw new NowBuildError({message:`Found invalid Bun Version: "${engineRange}".`,code:"BUILD_UTILS_BUN_VERSION_INVALID"})}function isBunVersion(version){return version.runtime.startsWith("bun")}var import_fs,import_semver,NODE_VERSIONS,BUN_VERSIONS,init_node_version=__esm({"src/fs/node-version.ts"(){"use strict";import_fs=require("fs"),import_semver=__toESM(require_semver2());init_types();init_errors();init_debug();NODE_VERSIONS=[new NodeVersion({major:24,range:"24.x",runtime:"nodejs24.x"}),new NodeVersion({major:22,range:"22.x",runtime:"nodejs22.x"}),new NodeVersion({major:20,range:"20.x",runtime:"nodejs20.x",discontinueDate:new Date("2026-10-01")}),new NodeVersion({major:18,range:"18.x",runtime:"nodejs18.x",discontinueDate:new Date("2025-09-01")}),new NodeVersion({major:16,range:"16.x",runtime:"nodejs16.x",discontinueDate:new Date("2025-02-03")}),new NodeVersion({major:14,range:"14.x",runtime:"nodejs14.x",discontinueDate:new Date("2023-08-15")}),new NodeVersion({major:12,range:"12.x",runtime:"nodejs12.x",discontinueDate:new Date("2022-10-03")}),new NodeVersion({major:10,range:"10.x",runtime:"nodejs10.x",discontinueDate:new Date("2021-04-20")}),new NodeVersion({major:8,range:"8.10.x",runtime:"nodejs8.10",discontinueDate:new Date("2020-01-06")})],BUN_VERSIONS=[new BunVersion({major:1,minor:4,range:"1.4.x",runtime:"bun1.4.x"}),new BunVersion({major:1,range:"1.x",runtime:"bun1.x"})]}});var require_common2=__commonJS({"../../node_modules/.pnpm/js-yaml@3.13.1/node_modules/js-yaml/lib/js-yaml/common.js"(exports2,module2){"use strict";function isNothing(subject){return typeof subject>"u"||subject===null}function isObject(subject){return typeof subject=="object"&&subject!==null}function toArray(sequence){return Array.isArray(sequence)?sequence:isNothing(sequence)?[]:[sequence]}function extend(target,source){var index,length,key,sourceKeys;if(source)for(sourceKeys=Object.keys(source),index=0,length=sourceKeys.length;index<length;index+=1)key=sourceKeys[index],target[key]=source[key];return target}function repeat(string,count){var result="",cycle;for(cycle=0;cycle<count;cycle+=1)result+=string;return result}function isNegativeZero(number){return number===0&&Number.NEGATIVE_INFINITY===1/number}module2.exports.isNothing=isNothing;module2.exports.isObject=isObject;module2.exports.toArray=toArray;module2.exports.repeat=repeat;module2.exports.isNegativeZero=isNegativeZero;module2.exports.extend=extend}});var require_exception=__commonJS({"../../node_modules/.pnpm/js-yaml@3.13.1/node_modules/js-yaml/lib/js-yaml/exception.js"(exports2,module2){"use strict";function YAMLException(reason,mark){Error.call(this),this.name="YAMLException",this.reason=reason,this.mark=mark,this.message=(this.reason||"(unknown reason)")+(this.mark?" "+this.mark.toString():""),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}YAMLException.prototype=Object.create(Error.prototype);YAMLException.prototype.constructor=YAMLException;YAMLException.prototype.toString=function(compact){var result=this.name+": ";return result+=this.reason||"(unknown reason)",!compact&&this.mark&&(result+=" "+this.mark.toString()),result};module2.exports=YAMLException}});var require_mark=__commonJS({"../../node_modules/.pnpm/js-yaml@3.13.1/node_modules/js-yaml/lib/js-yaml/mark.js"(exports2,module2){"use strict";var common=require_common2();function Mark(name,buffer,position,line,column){this.name=name,this.buffer=buffer,this.position=position,this.line=line,this.column=column}Mark.prototype.getSnippet=function(indent,maxLength){var head,start,tail,end,snippet;if(!this.buffer)return null;for(indent=indent||4,maxLength=maxLength||75,head="",start=this.position;start>0&&`\0\r
16
16
  \x85\u2028\u2029`.indexOf(this.buffer.charAt(start-1))===-1;)if(start-=1,this.position-start>maxLength/2-1){head=" ... ",start+=5;break}for(tail="",end=this.position;end<this.buffer.length&&`\0\r
17
17
  \x85\u2028\u2029`.indexOf(this.buffer.charAt(end))===-1;)if(end+=1,end-this.position>maxLength/2-1){tail=" ... ",end-=5;break}return snippet=this.buffer.slice(start,end),common.repeat(" ",indent)+head+snippet+tail+`
18
18
  `+common.repeat(" ",indent+this.position-start+head.length)+"^"};Mark.prototype.toString=function(compact){var snippet,where="";return this.name&&(where+='in "'+this.name+'" '),where+="at line "+(this.line+1)+", column "+(this.column+1),compact||(snippet=this.getSnippet(),snippet&&(where+=`:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vercel/build-utils",
3
- "version": "14.13.1",
3
+ "version": "14.13.2",
4
4
  "license": "Apache-2.0",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.js",