@turbo/codemod 2.0.0-canary.0 → 2.0.0-canary.1

Sign up to get free protection for your applications and to get access to all the features.
package/dist/cli.js CHANGED
@@ -1,27 +1,27 @@
1
1
  #!/usr/bin/env node
2
- "use strict";var Jb=Object.create;var _a=Object.defineProperty;var Xb=Object.getOwnPropertyDescriptor;var Qb=Object.getOwnPropertyNames;var e_=Object.getPrototypeOf,t_=Object.prototype.hasOwnProperty;var $=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),r_=(t,e)=>{for(var r in e)_a(t,r,{get:e[r],enumerable:!0})},i_=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of Qb(e))!t_.call(t,n)&&n!==r&&_a(t,n,{get:()=>e[n],enumerable:!(i=Xb(e,n))||i.enumerable});return t};var J=(t,e,r)=>(r=t!=null?Jb(e_(t)):{},i_(e||!t||!t.__esModule?_a(r,"default",{value:t,enumerable:!0}):r,t));var Zh=$((OL,Pt)=>{function wa(t){return Pt.exports=wa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Pt.exports.__esModule=!0,Pt.exports.default=Pt.exports,wa(t)}Pt.exports=wa,Pt.exports.__esModule=!0,Pt.exports.default=Pt.exports});var Qh=$((kL,It)=>{var Jh=Zh().default;function Xh(){"use strict";It.exports=Xh=function(){return e},It.exports.__esModule=!0,It.exports.default=It.exports;var t,e={},r=Object.prototype,i=r.hasOwnProperty,n=Object.defineProperty||function(C,k,j){C[k]=j.value},s=typeof Symbol=="function"?Symbol:{},o=s.iterator||"@@iterator",a=s.asyncIterator||"@@asyncIterator",u=s.toStringTag||"@@toStringTag";function l(C,k,j){return Object.defineProperty(C,k,{value:j,enumerable:!0,configurable:!0,writable:!0}),C[k]}try{l({},"")}catch{l=function(j,z,P){return j[z]=P}}function c(C,k,j,z){var P=k&&k.prototype instanceof v?k:v,d=Object.create(P.prototype),m=new K(z||[]);return n(d,"_invoke",{value:H(C,j,m)}),d}function f(C,k,j){try{return{type:"normal",arg:C.call(k,j)}}catch(z){return{type:"throw",arg:z}}}e.wrap=c;var h="suspendedStart",p="suspendedYield",g="executing",y="completed",E={};function v(){}function F(){}function O(){}var R={};l(R,o,function(){return this});var x=Object.getPrototypeOf,L=x&&x(x(B([])));L&&L!==r&&i.call(L,o)&&(R=L);var b=O.prototype=v.prototype=Object.create(R);function S(C){["next","throw","return"].forEach(function(k){l(C,k,function(j){return this._invoke(k,j)})})}function N(C,k){function j(P,d,m,D){var A=f(C[P],C,d);if(A.type!=="throw"){var w=A.arg,I=w.value;return I&&Jh(I)=="object"&&i.call(I,"__await")?k.resolve(I.__await).then(function(M){j("next",M,m,D)},function(M){j("throw",M,m,D)}):k.resolve(I).then(function(M){w.value=M,m(w)},function(M){return j("throw",M,m,D)})}D(A.arg)}var z;n(this,"_invoke",{value:function(d,m){function D(){return new k(function(A,w){j(d,m,A,w)})}return z=z?z.then(D,D):D()}})}function H(C,k,j){var z=h;return function(P,d){if(z===g)throw new Error("Generator is already running");if(z===y){if(P==="throw")throw d;return{value:t,done:!0}}for(j.method=P,j.arg=d;;){var m=j.delegate;if(m){var D=T(m,j);if(D){if(D===E)continue;return D}}if(j.method==="next")j.sent=j._sent=j.arg;else if(j.method==="throw"){if(z===h)throw z=y,j.arg;j.dispatchException(j.arg)}else j.method==="return"&&j.abrupt("return",j.arg);z=g;var A=f(C,k,j);if(A.type==="normal"){if(z=j.done?y:p,A.arg===E)continue;return{value:A.arg,done:j.done}}A.type==="throw"&&(z=y,j.method="throw",j.arg=A.arg)}}}function T(C,k){var j=k.method,z=C.iterator[j];if(z===t)return k.delegate=null,j==="throw"&&C.iterator.return&&(k.method="return",k.arg=t,T(C,k),k.method==="throw")||j!=="return"&&(k.method="throw",k.arg=new TypeError("The iterator does not provide a '"+j+"' method")),E;var P=f(z,C.iterator,k.arg);if(P.type==="throw")return k.method="throw",k.arg=P.arg,k.delegate=null,E;var d=P.arg;return d?d.done?(k[C.resultName]=d.value,k.next=C.nextLoc,k.method!=="return"&&(k.method="next",k.arg=t),k.delegate=null,E):d:(k.method="throw",k.arg=new TypeError("iterator result is not an object"),k.delegate=null,E)}function U(C){var k={tryLoc:C[0]};1 in C&&(k.catchLoc=C[1]),2 in C&&(k.finallyLoc=C[2],k.afterLoc=C[3]),this.tryEntries.push(k)}function V(C){var k=C.completion||{};k.type="normal",delete k.arg,C.completion=k}function K(C){this.tryEntries=[{tryLoc:"root"}],C.forEach(U,this),this.reset(!0)}function B(C){if(C||C===""){var k=C[o];if(k)return k.call(C);if(typeof C.next=="function")return C;if(!isNaN(C.length)){var j=-1,z=function P(){for(;++j<C.length;)if(i.call(C,j))return P.value=C[j],P.done=!1,P;return P.value=t,P.done=!0,P};return z.next=z}}throw new TypeError(Jh(C)+" is not iterable")}return F.prototype=O,n(b,"constructor",{value:O,configurable:!0}),n(O,"constructor",{value:F,configurable:!0}),F.displayName=l(O,u,"GeneratorFunction"),e.isGeneratorFunction=function(C){var k=typeof C=="function"&&C.constructor;return!!k&&(k===F||(k.displayName||k.name)==="GeneratorFunction")},e.mark=function(C){return Object.setPrototypeOf?Object.setPrototypeOf(C,O):(C.__proto__=O,l(C,u,"GeneratorFunction")),C.prototype=Object.create(b),C},e.awrap=function(C){return{__await:C}},S(N.prototype),l(N.prototype,a,function(){return this}),e.AsyncIterator=N,e.async=function(C,k,j,z,P){P===void 0&&(P=Promise);var d=new N(c(C,k,j,z),P);return e.isGeneratorFunction(k)?d:d.next().then(function(m){return m.done?m.value:d.next()})},S(b),l(b,u,"Generator"),l(b,o,function(){return this}),l(b,"toString",function(){return"[object Generator]"}),e.keys=function(C){var k=Object(C),j=[];for(var z in k)j.push(z);return j.reverse(),function P(){for(;j.length;){var d=j.pop();if(d in k)return P.value=d,P.done=!1,P}return P.done=!0,P}},e.values=B,K.prototype={constructor:K,reset:function(k){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(V),!k)for(var j in this)j.charAt(0)==="t"&&i.call(this,j)&&!isNaN(+j.slice(1))&&(this[j]=t)},stop:function(){this.done=!0;var k=this.tryEntries[0].completion;if(k.type==="throw")throw k.arg;return this.rval},dispatchException:function(k){if(this.done)throw k;var j=this;function z(w,I){return m.type="throw",m.arg=k,j.next=w,I&&(j.method="next",j.arg=t),!!I}for(var P=this.tryEntries.length-1;P>=0;--P){var d=this.tryEntries[P],m=d.completion;if(d.tryLoc==="root")return z("end");if(d.tryLoc<=this.prev){var D=i.call(d,"catchLoc"),A=i.call(d,"finallyLoc");if(D&&A){if(this.prev<d.catchLoc)return z(d.catchLoc,!0);if(this.prev<d.finallyLoc)return z(d.finallyLoc)}else if(D){if(this.prev<d.catchLoc)return z(d.catchLoc,!0)}else{if(!A)throw new Error("try statement without catch or finally");if(this.prev<d.finallyLoc)return z(d.finallyLoc)}}}},abrupt:function(k,j){for(var z=this.tryEntries.length-1;z>=0;--z){var P=this.tryEntries[z];if(P.tryLoc<=this.prev&&i.call(P,"finallyLoc")&&this.prev<P.finallyLoc){var d=P;break}}d&&(k==="break"||k==="continue")&&d.tryLoc<=j&&j<=d.finallyLoc&&(d=null);var m=d?d.completion:{};return m.type=k,m.arg=j,d?(this.method="next",this.next=d.finallyLoc,E):this.complete(m)},complete:function(k,j){if(k.type==="throw")throw k.arg;return k.type==="break"||k.type==="continue"?this.next=k.arg:k.type==="return"?(this.rval=this.arg=k.arg,this.method="return",this.next="end"):k.type==="normal"&&j&&(this.next=j),E},finish:function(k){for(var j=this.tryEntries.length-1;j>=0;--j){var z=this.tryEntries[j];if(z.finallyLoc===k)return this.complete(z.completion,z.afterLoc),V(z),E}},catch:function(k){for(var j=this.tryEntries.length-1;j>=0;--j){var z=this.tryEntries[j];if(z.tryLoc===k){var P=z.completion;if(P.type==="throw"){var d=P.arg;V(z)}return d}}throw new Error("illegal catch attempt")},delegateYield:function(k,j,z){return this.delegate={iterator:B(k),resultName:j,nextLoc:z},this.method==="next"&&(this.arg=t),E}},e}It.exports=Xh,It.exports.__esModule=!0,It.exports.default=It.exports});var tf=$((TL,ef)=>{var rs=Qh()();ef.exports=rs;try{regeneratorRuntime=rs}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=rs:Function("r","regeneratorRuntime = r")(rs)}});var op=$(fi=>{"use strict";Object.defineProperty(fi,"__esModule",{value:!0});fi.splitWhen=fi.flatten=void 0;function OS(t){return t.reduce((e,r)=>[].concat(e,r),[])}fi.flatten=OS;function kS(t,e){let r=[[]],i=0;for(let n of t)e(n)?(i++,r[i]=[]):r[i].push(n);return r}fi.splitWhen=kS});var ap=$(ls=>{"use strict";Object.defineProperty(ls,"__esModule",{value:!0});ls.isEnoentCodeError=void 0;function TS(t){return t.code==="ENOENT"}ls.isEnoentCodeError=TS});var up=$(cs=>{"use strict";Object.defineProperty(cs,"__esModule",{value:!0});cs.createDirentFromStats=void 0;var Ga=class{constructor(e,r){this.name=e,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function LS(t,e){return new Ga(t,e)}cs.createDirentFromStats=LS});var lp=$(Dt=>{"use strict";Object.defineProperty(Dt,"__esModule",{value:!0});Dt.removeLeadingDotSegment=Dt.escape=Dt.makeAbsolute=Dt.unixify=void 0;var BS=require("path"),PS=2,IS=/(\\?)([()*?[\]{|}]|^!|[!+@](?=\())/g;function NS(t){return t.replace(/\\/g,"/")}Dt.unixify=NS;function MS(t,e){return BS.resolve(t,e)}Dt.makeAbsolute=MS;function jS(t){return t.replace(IS,"\\$2")}Dt.escape=jS;function $S(t){if(t.charAt(0)==="."){let e=t.charAt(1);if(e==="/"||e==="\\")return t.slice(PS)}return t}Dt.removeLeadingDotSegment=$S});var hp=$((_B,cp)=>{cp.exports=function(e){if(typeof e!="string"||e==="")return!1;for(var r;r=/(\\).|([@?!+*]\(.*\))/g.exec(e);){if(r[2])return!0;e=e.slice(r.index+r[0].length)}return!1}});var dp=$((wB,pp)=>{var HS=hp(),fp={"{":"}","(":")","[":"]"},qS=function(t){if(t[0]==="!")return!0;for(var e=0,r=-2,i=-2,n=-2,s=-2,o=-2;e<t.length;){if(t[e]==="*"||t[e+1]==="?"&&/[\].+)]/.test(t[e])||i!==-1&&t[e]==="["&&t[e+1]!=="]"&&(i<e&&(i=t.indexOf("]",e)),i>e&&(o===-1||o>i||(o=t.indexOf("\\",e),o===-1||o>i)))||n!==-1&&t[e]==="{"&&t[e+1]!=="}"&&(n=t.indexOf("}",e),n>e&&(o=t.indexOf("\\",e),o===-1||o>n))||s!==-1&&t[e]==="("&&t[e+1]==="?"&&/[:!=]/.test(t[e+2])&&t[e+3]!==")"&&(s=t.indexOf(")",e),s>e&&(o=t.indexOf("\\",e),o===-1||o>s))||r!==-1&&t[e]==="("&&t[e+1]!=="|"&&(r<e&&(r=t.indexOf("|",e)),r!==-1&&t[r+1]!==")"&&(s=t.indexOf(")",r),s>r&&(o=t.indexOf("\\",r),o===-1||o>s))))return!0;if(t[e]==="\\"){var a=t[e+1];e+=2;var u=fp[a];if(u){var l=t.indexOf(u,e);l!==-1&&(e=l+1)}if(t[e]==="!")return!0}else e++}return!1},US=function(t){if(t[0]==="!")return!0;for(var e=0;e<t.length;){if(/[*?{}()[\]]/.test(t[e]))return!0;if(t[e]==="\\"){var r=t[e+1];e+=2;var i=fp[r];if(i){var n=t.indexOf(i,e);n!==-1&&(e=n+1)}if(t[e]==="!")return!0}else e++}return!1};pp.exports=function(e,r){if(typeof e!="string"||e==="")return!1;if(HS(e))return!0;var i=qS;return r&&r.strict===!1&&(i=US),i(e)}});var gp=$((SB,mp)=>{"use strict";var GS=dp(),zS=require("path").posix.dirname,WS=require("os").platform()==="win32",za="/",YS=/\\/g,VS=/[\{\[].*[\}\]]$/,KS=/(^|[^\\])([\{\[]|\([^\)]+$)/,ZS=/\\([\!\*\?\|\[\]\(\)\{\}])/g;mp.exports=function(e,r){var i=Object.assign({flipBackslashes:!0},r);i.flipBackslashes&&WS&&e.indexOf(za)<0&&(e=e.replace(YS,za)),VS.test(e)&&(e+=za),e+="a";do e=zS(e);while(GS(e)||KS.test(e));return e.replace(ZS,"$1")}});var hs=$(it=>{"use strict";it.isInteger=t=>typeof t=="number"?Number.isInteger(t):typeof t=="string"&&t.trim()!==""?Number.isInteger(Number(t)):!1;it.find=(t,e)=>t.nodes.find(r=>r.type===e);it.exceedsLimit=(t,e,r=1,i)=>i===!1||!it.isInteger(t)||!it.isInteger(e)?!1:(Number(e)-Number(t))/Number(r)>=i;it.escapeNode=(t,e=0,r)=>{let i=t.nodes[e];i&&(r&&i.type===r||i.type==="open"||i.type==="close")&&i.escaped!==!0&&(i.value="\\"+i.value,i.escaped=!0)};it.encloseBrace=t=>t.type!=="brace"||t.commas>>0+t.ranges>>0?!1:(t.invalid=!0,!0);it.isInvalidBrace=t=>t.type!=="brace"?!1:t.invalid===!0||t.dollar?!0:!(t.commas>>0+t.ranges>>0)||t.open!==!0||t.close!==!0?(t.invalid=!0,!0):!1;it.isOpenOrClose=t=>t.type==="open"||t.type==="close"?!0:t.open===!0||t.close===!0;it.reduce=t=>t.reduce((e,r)=>(r.type==="text"&&e.push(r.value),r.type==="range"&&(r.type="text"),e),[]);it.flatten=(...t)=>{let e=[],r=i=>{for(let n=0;n<i.length;n++){let s=i[n];Array.isArray(s)?r(s,e):s!==void 0&&e.push(s)}return e};return r(t),e}});var fs=$((vB,Ep)=>{"use strict";var yp=hs();Ep.exports=(t,e={})=>{let r=(i,n={})=>{let s=e.escapeInvalid&&yp.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a="";if(i.value)return(s||o)&&yp.isOpenOrClose(i)?"\\"+i.value:i.value;if(i.value)return i.value;if(i.nodes)for(let u of i.nodes)a+=r(u);return a};return r(t)}});var bp=$((CB,Dp)=>{"use strict";Dp.exports=function(t){return typeof t=="number"?t-t===0:typeof t=="string"&&t.trim()!==""?Number.isFinite?Number.isFinite(+t):isFinite(+t):!1}});var Fp=$((xB,Rp)=>{"use strict";var _p=bp(),Ir=(t,e,r)=>{if(_p(t)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(e===void 0||t===e)return String(t);if(_p(e)===!1)throw new TypeError("toRegexRange: expected the second argument to be a number.");let i={relaxZeros:!0,...r};typeof i.strictZeros=="boolean"&&(i.relaxZeros=i.strictZeros===!1);let n=String(i.relaxZeros),s=String(i.shorthand),o=String(i.capture),a=String(i.wrap),u=t+":"+e+"="+n+s+o+a;if(Ir.cache.hasOwnProperty(u))return Ir.cache[u].result;let l=Math.min(t,e),c=Math.max(t,e);if(Math.abs(l-c)===1){let y=t+"|"+e;return i.capture?`(${y})`:i.wrap===!1?y:`(?:${y})`}let f=xp(t)||xp(e),h={min:t,max:e,a:l,b:c},p=[],g=[];if(f&&(h.isPadded=f,h.maxLen=String(h.max).length),l<0){let y=c<0?Math.abs(c):1;g=wp(y,Math.abs(l),h,i),l=h.a=0}return c>=0&&(p=wp(l,c,h,i)),h.negatives=g,h.positives=p,h.result=JS(g,p,i),i.capture===!0?h.result=`(${h.result})`:i.wrap!==!1&&p.length+g.length>1&&(h.result=`(?:${h.result})`),Ir.cache[u]=h,h.result};function JS(t,e,r){let i=Wa(t,e,"-",!1,r)||[],n=Wa(e,t,"",!1,r)||[],s=Wa(t,e,"-?",!0,r)||[];return i.concat(s).concat(n).join("|")}function XS(t,e){let r=1,i=1,n=Ap(t,r),s=new Set([e]);for(;t<=n&&n<=e;)s.add(n),r+=1,n=Ap(t,r);for(n=vp(e+1,i)-1;t<n&&n<=e;)s.add(n),i+=1,n=vp(e+1,i)-1;return s=[...s],s.sort(tA),s}function QS(t,e,r){if(t===e)return{pattern:t,count:[],digits:0};let i=eA(t,e),n=i.length,s="",o=0;for(let a=0;a<n;a++){let[u,l]=i[a];u===l?s+=u:u!=="0"||l!=="9"?s+=rA(u,l,r):o++}return o&&(s+=r.shorthand===!0?"\\d":"[0-9]"),{pattern:s,count:[o],digits:n}}function wp(t,e,r,i){let n=XS(t,e),s=[],o=t,a;for(let u=0;u<n.length;u++){let l=n[u],c=QS(String(o),String(l),i),f="";if(!r.isPadded&&a&&a.pattern===c.pattern){a.count.length>1&&a.count.pop(),a.count.push(c.count[0]),a.string=a.pattern+Cp(a.count),o=l+1;continue}r.isPadded&&(f=iA(l,r,i)),c.string=f+c.pattern+Cp(c.count),s.push(c),o=l+1,a=c}return s}function Wa(t,e,r,i,n){let s=[];for(let o of t){let{string:a}=o;!i&&!Sp(e,"string",a)&&s.push(r+a),i&&Sp(e,"string",a)&&s.push(r+a)}return s}function eA(t,e){let r=[];for(let i=0;i<t.length;i++)r.push([t[i],e[i]]);return r}function tA(t,e){return t>e?1:e>t?-1:0}function Sp(t,e,r){return t.some(i=>i[e]===r)}function Ap(t,e){return Number(String(t).slice(0,-e)+"9".repeat(e))}function vp(t,e){return t-t%Math.pow(10,e)}function Cp(t){let[e=0,r=""]=t;return r||e>1?`{${e+(r?","+r:"")}}`:""}function rA(t,e,r){return`[${t}${e-t===1?"":"-"}${e}]`}function xp(t){return/^-?(0+)\d/.test(t)}function iA(t,e,r){if(!e.isPadded)return t;let i=Math.abs(e.maxLen-String(t).length),n=r.relaxZeros!==!1;switch(i){case 0:return"";case 1:return n?"0?":"0";case 2:return n?"0{0,2}":"00";default:return n?`0{0,${i}}`:`0{${i}}`}}Ir.cache={};Ir.clearCache=()=>Ir.cache={};Rp.exports=Ir});var Ka=$((RB,Np)=>{"use strict";var nA=require("util"),Tp=Fp(),Op=t=>t!==null&&typeof t=="object"&&!Array.isArray(t),sA=t=>e=>t===!0?Number(e):String(e),Ya=t=>typeof t=="number"||typeof t=="string"&&t!=="",yn=t=>Number.isInteger(+t),Va=t=>{let e=`${t}`,r=-1;if(e[0]==="-"&&(e=e.slice(1)),e==="0")return!1;for(;e[++r]==="0";);return r>0},oA=(t,e,r)=>typeof t=="string"||typeof e=="string"?!0:r.stringify===!0,aA=(t,e,r)=>{if(e>0){let i=t[0]==="-"?"-":"";i&&(t=t.slice(1)),t=i+t.padStart(i?e-1:e,"0")}return r===!1?String(t):t},kp=(t,e)=>{let r=t[0]==="-"?"-":"";for(r&&(t=t.slice(1),e--);t.length<e;)t="0"+t;return r?"-"+t:t},uA=(t,e)=>{t.negatives.sort((o,a)=>o<a?-1:o>a?1:0),t.positives.sort((o,a)=>o<a?-1:o>a?1:0);let r=e.capture?"":"?:",i="",n="",s;return t.positives.length&&(i=t.positives.join("|")),t.negatives.length&&(n=`-(${r}${t.negatives.join("|")})`),i&&n?s=`${i}|${n}`:s=i||n,e.wrap?`(${r}${s})`:s},Lp=(t,e,r,i)=>{if(r)return Tp(t,e,{wrap:!1,...i});let n=String.fromCharCode(t);if(t===e)return n;let s=String.fromCharCode(e);return`[${n}-${s}]`},Bp=(t,e,r)=>{if(Array.isArray(t)){let i=r.wrap===!0,n=r.capture?"":"?:";return i?`(${n}${t.join("|")})`:t.join("|")}return Tp(t,e,r)},Pp=(...t)=>new RangeError("Invalid range arguments: "+nA.inspect(...t)),Ip=(t,e,r)=>{if(r.strictRanges===!0)throw Pp([t,e]);return[]},lA=(t,e)=>{if(e.strictRanges===!0)throw new TypeError(`Expected step "${t}" to be a number`);return[]},cA=(t,e,r=1,i={})=>{let n=Number(t),s=Number(e);if(!Number.isInteger(n)||!Number.isInteger(s)){if(i.strictRanges===!0)throw Pp([t,e]);return[]}n===0&&(n=0),s===0&&(s=0);let o=n>s,a=String(t),u=String(e),l=String(r);r=Math.max(Math.abs(r),1);let c=Va(a)||Va(u)||Va(l),f=c?Math.max(a.length,u.length,l.length):0,h=c===!1&&oA(t,e,i)===!1,p=i.transform||sA(h);if(i.toRegex&&r===1)return Lp(kp(t,f),kp(e,f),!0,i);let g={negatives:[],positives:[]},y=F=>g[F<0?"negatives":"positives"].push(Math.abs(F)),E=[],v=0;for(;o?n>=s:n<=s;)i.toRegex===!0&&r>1?y(n):E.push(aA(p(n,v),f,h)),n=o?n-r:n+r,v++;return i.toRegex===!0?r>1?uA(g,i):Bp(E,null,{wrap:!1,...i}):E},hA=(t,e,r=1,i={})=>{if(!yn(t)&&t.length>1||!yn(e)&&e.length>1)return Ip(t,e,i);let n=i.transform||(h=>String.fromCharCode(h)),s=`${t}`.charCodeAt(0),o=`${e}`.charCodeAt(0),a=s>o,u=Math.min(s,o),l=Math.max(s,o);if(i.toRegex&&r===1)return Lp(u,l,!1,i);let c=[],f=0;for(;a?s>=o:s<=o;)c.push(n(s,f)),s=a?s-r:s+r,f++;return i.toRegex===!0?Bp(c,null,{wrap:!1,options:i}):c},ps=(t,e,r,i={})=>{if(e==null&&Ya(t))return[t];if(!Ya(t)||!Ya(e))return Ip(t,e,i);if(typeof r=="function")return ps(t,e,1,{transform:r});if(Op(r))return ps(t,e,0,r);let n={...i};return n.capture===!0&&(n.wrap=!0),r=r||n.step||1,yn(r)?yn(t)&&yn(e)?cA(t,e,r,n):hA(t,e,Math.max(Math.abs(r),1),n):r!=null&&!Op(r)?lA(r,n):ps(t,e,1,r)};Np.exports=ps});var $p=$((FB,jp)=>{"use strict";var fA=Ka(),Mp=hs(),pA=(t,e={})=>{let r=(i,n={})=>{let s=Mp.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a=s===!0||o===!0,u=e.escapeInvalid===!0?"\\":"",l="";if(i.isOpen===!0||i.isClose===!0)return u+i.value;if(i.type==="open")return a?u+i.value:"(";if(i.type==="close")return a?u+i.value:")";if(i.type==="comma")return i.prev.type==="comma"?"":a?i.value:"|";if(i.value)return i.value;if(i.nodes&&i.ranges>0){let c=Mp.reduce(i.nodes),f=fA(...c,{...e,wrap:!1,toRegex:!0});if(f.length!==0)return c.length>1&&f.length>1?`(${f})`:f}if(i.nodes)for(let c of i.nodes)l+=r(c,i);return l};return r(t)};jp.exports=pA});var Up=$((OB,qp)=>{"use strict";var dA=Ka(),Hp=fs(),pi=hs(),Nr=(t="",e="",r=!1)=>{let i=[];if(t=[].concat(t),e=[].concat(e),!e.length)return t;if(!t.length)return r?pi.flatten(e).map(n=>`{${n}}`):e;for(let n of t)if(Array.isArray(n))for(let s of n)i.push(Nr(s,e,r));else for(let s of e)r===!0&&typeof s=="string"&&(s=`{${s}}`),i.push(Array.isArray(s)?Nr(n,s,r):n+s);return pi.flatten(i)},mA=(t,e={})=>{let r=e.rangeLimit===void 0?1e3:e.rangeLimit,i=(n,s={})=>{n.queue=[];let o=s,a=s.queue;for(;o.type!=="brace"&&o.type!=="root"&&o.parent;)o=o.parent,a=o.queue;if(n.invalid||n.dollar){a.push(Nr(a.pop(),Hp(n,e)));return}if(n.type==="brace"&&n.invalid!==!0&&n.nodes.length===2){a.push(Nr(a.pop(),["{}"]));return}if(n.nodes&&n.ranges>0){let f=pi.reduce(n.nodes);if(pi.exceedsLimit(...f,e.step,r))throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.");let h=dA(...f,e);h.length===0&&(h=Hp(n,e)),a.push(Nr(a.pop(),h)),n.nodes=[];return}let u=pi.encloseBrace(n),l=n.queue,c=n;for(;c.type!=="brace"&&c.type!=="root"&&c.parent;)c=c.parent,l=c.queue;for(let f=0;f<n.nodes.length;f++){let h=n.nodes[f];if(h.type==="comma"&&n.type==="brace"){f===1&&l.push(""),l.push("");continue}if(h.type==="close"){a.push(Nr(a.pop(),l,u));continue}if(h.value&&h.type!=="open"){l.push(Nr(l.pop(),h.value));continue}h.nodes&&i(h,n)}return l};return pi.flatten(i(t))};qp.exports=mA});var zp=$((kB,Gp)=>{"use strict";Gp.exports={MAX_LENGTH:1024*64,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:`
3
- `,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:" ",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var Zp=$((TB,Kp)=>{"use strict";var gA=fs(),{MAX_LENGTH:Wp,CHAR_BACKSLASH:Za,CHAR_BACKTICK:yA,CHAR_COMMA:EA,CHAR_DOT:DA,CHAR_LEFT_PARENTHESES:bA,CHAR_RIGHT_PARENTHESES:_A,CHAR_LEFT_CURLY_BRACE:wA,CHAR_RIGHT_CURLY_BRACE:SA,CHAR_LEFT_SQUARE_BRACKET:Yp,CHAR_RIGHT_SQUARE_BRACKET:Vp,CHAR_DOUBLE_QUOTE:AA,CHAR_SINGLE_QUOTE:vA,CHAR_NO_BREAK_SPACE:CA,CHAR_ZERO_WIDTH_NOBREAK_SPACE:xA}=zp(),RA=(t,e={})=>{if(typeof t!="string")throw new TypeError("Expected a string");let r=e||{},i=typeof r.maxLength=="number"?Math.min(Wp,r.maxLength):Wp;if(t.length>i)throw new SyntaxError(`Input length (${t.length}), exceeds max characters (${i})`);let n={type:"root",input:t,nodes:[]},s=[n],o=n,a=n,u=0,l=t.length,c=0,f=0,h,p={},g=()=>t[c++],y=E=>{if(E.type==="text"&&a.type==="dot"&&(a.type="text"),a&&a.type==="text"&&E.type==="text"){a.value+=E.value;return}return o.nodes.push(E),E.parent=o,E.prev=a,a=E,E};for(y({type:"bos"});c<l;)if(o=s[s.length-1],h=g(),!(h===xA||h===CA)){if(h===Za){y({type:"text",value:(e.keepEscaping?h:"")+g()});continue}if(h===Vp){y({type:"text",value:"\\"+h});continue}if(h===Yp){u++;let E=!0,v;for(;c<l&&(v=g());){if(h+=v,v===Yp){u++;continue}if(v===Za){h+=g();continue}if(v===Vp&&(u--,u===0))break}y({type:"text",value:h});continue}if(h===bA){o=y({type:"paren",nodes:[]}),s.push(o),y({type:"text",value:h});continue}if(h===_A){if(o.type!=="paren"){y({type:"text",value:h});continue}o=s.pop(),y({type:"text",value:h}),o=s[s.length-1];continue}if(h===AA||h===vA||h===yA){let E=h,v;for(e.keepQuotes!==!0&&(h="");c<l&&(v=g());){if(v===Za){h+=v+g();continue}if(v===E){e.keepQuotes===!0&&(h+=v);break}h+=v}y({type:"text",value:h});continue}if(h===wA){f++;let v={type:"brace",open:!0,close:!1,dollar:a.value&&a.value.slice(-1)==="$"||o.dollar===!0,depth:f,commas:0,ranges:0,nodes:[]};o=y(v),s.push(o),y({type:"open",value:h});continue}if(h===SA){if(o.type!=="brace"){y({type:"text",value:h});continue}let E="close";o=s.pop(),o.close=!0,y({type:E,value:h}),f--,o=s[s.length-1];continue}if(h===EA&&f>0){if(o.ranges>0){o.ranges=0;let E=o.nodes.shift();o.nodes=[E,{type:"text",value:gA(o)}]}y({type:"comma",value:h}),o.commas++;continue}if(h===DA&&f>0&&o.commas===0){let E=o.nodes;if(f===0||E.length===0){y({type:"text",value:h});continue}if(a.type==="dot"){if(o.range=[],a.value+=h,a.type="range",o.nodes.length!==3&&o.nodes.length!==5){o.invalid=!0,o.ranges=0,a.type="text";continue}o.ranges++,o.args=[];continue}if(a.type==="range"){E.pop();let v=E[E.length-1];v.value+=a.value+h,a=v,o.ranges--;continue}y({type:"dot",value:h});continue}y({type:"text",value:h})}do if(o=s.pop(),o.type!=="root"){o.nodes.forEach(F=>{F.nodes||(F.type==="open"&&(F.isOpen=!0),F.type==="close"&&(F.isClose=!0),F.nodes||(F.type="text"),F.invalid=!0)});let E=s[s.length-1],v=E.nodes.indexOf(o);E.nodes.splice(v,1,...o.nodes)}while(s.length>0);return y({type:"eos"}),n};Kp.exports=RA});var Qp=$((LB,Xp)=>{"use strict";var Jp=fs(),FA=$p(),OA=Up(),kA=Zp(),Ze=(t,e={})=>{let r=[];if(Array.isArray(t))for(let i of t){let n=Ze.create(i,e);Array.isArray(n)?r.push(...n):r.push(n)}else r=[].concat(Ze.create(t,e));return e&&e.expand===!0&&e.nodupes===!0&&(r=[...new Set(r)]),r};Ze.parse=(t,e={})=>kA(t,e);Ze.stringify=(t,e={})=>Jp(typeof t=="string"?Ze.parse(t,e):t,e);Ze.compile=(t,e={})=>(typeof t=="string"&&(t=Ze.parse(t,e)),FA(t,e));Ze.expand=(t,e={})=>{typeof t=="string"&&(t=Ze.parse(t,e));let r=OA(t,e);return e.noempty===!0&&(r=r.filter(Boolean)),e.nodupes===!0&&(r=[...new Set(r)]),r};Ze.create=(t,e={})=>t===""||t.length<3?[t]:e.expand!==!0?Ze.compile(t,e):Ze.expand(t,e);Xp.exports=Ze});var En=$((BB,nd)=>{"use strict";var TA=require("path"),bt="\\\\/",ed=`[^${bt}]`,jt="\\.",LA="\\+",BA="\\?",ds="\\/",PA="(?=.)",td="[^/]",Ja=`(?:${ds}|$)`,rd=`(?:^|${ds})`,Xa=`${jt}{1,2}${Ja}`,IA=`(?!${jt})`,NA=`(?!${rd}${Xa})`,MA=`(?!${jt}{0,1}${Ja})`,jA=`(?!${Xa})`,$A=`[^.${ds}]`,HA=`${td}*?`,id={DOT_LITERAL:jt,PLUS_LITERAL:LA,QMARK_LITERAL:BA,SLASH_LITERAL:ds,ONE_CHAR:PA,QMARK:td,END_ANCHOR:Ja,DOTS_SLASH:Xa,NO_DOT:IA,NO_DOTS:NA,NO_DOT_SLASH:MA,NO_DOTS_SLASH:jA,QMARK_NO_DOT:$A,STAR:HA,START_ANCHOR:rd},qA={...id,SLASH_LITERAL:`[${bt}]`,QMARK:ed,STAR:`${ed}*?`,DOTS_SLASH:`${jt}{1,2}(?:[${bt}]|$)`,NO_DOT:`(?!${jt})`,NO_DOTS:`(?!(?:^|[${bt}])${jt}{1,2}(?:[${bt}]|$))`,NO_DOT_SLASH:`(?!${jt}{0,1}(?:[${bt}]|$))`,NO_DOTS_SLASH:`(?!${jt}{1,2}(?:[${bt}]|$))`,QMARK_NO_DOT:`[^.${bt}]`,START_ANCHOR:`(?:^|[${bt}])`,END_ANCHOR:`(?:[${bt}]|$)`},UA={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};nd.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:UA,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:TA.sep,extglobChars(t){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${t.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars(t){return t===!0?qA:id}}});var Dn=$(Ge=>{"use strict";var GA=require("path"),zA=process.platform==="win32",{REGEX_BACKSLASH:WA,REGEX_REMOVE_BACKSLASH:YA,REGEX_SPECIAL_CHARS:VA,REGEX_SPECIAL_CHARS_GLOBAL:KA}=En();Ge.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);Ge.hasRegexChars=t=>VA.test(t);Ge.isRegexChar=t=>t.length===1&&Ge.hasRegexChars(t);Ge.escapeRegex=t=>t.replace(KA,"\\$1");Ge.toPosixSlashes=t=>t.replace(WA,"/");Ge.removeBackslashes=t=>t.replace(YA,e=>e==="\\"?"":e);Ge.supportsLookbehinds=()=>{let t=process.version.slice(1).split(".").map(Number);return t.length===3&&t[0]>=9||t[0]===8&&t[1]>=10};Ge.isWindows=t=>t&&typeof t.windows=="boolean"?t.windows:zA===!0||GA.sep==="\\";Ge.escapeLast=(t,e,r)=>{let i=t.lastIndexOf(e,r);return i===-1?t:t[i-1]==="\\"?Ge.escapeLast(t,e,i-1):`${t.slice(0,i)}\\${t.slice(i)}`};Ge.removePrefix=(t,e={})=>{let r=t;return r.startsWith("./")&&(r=r.slice(2),e.prefix="./"),r};Ge.wrapOutput=(t,e={},r={})=>{let i=r.contains?"":"^",n=r.contains?"":"$",s=`${i}(?:${t})${n}`;return e.negated===!0&&(s=`(?:^(?!${s}).*$)`),s}});var fd=$((IB,hd)=>{"use strict";var sd=Dn(),{CHAR_ASTERISK:Qa,CHAR_AT:ZA,CHAR_BACKWARD_SLASH:bn,CHAR_COMMA:JA,CHAR_DOT:eu,CHAR_EXCLAMATION_MARK:tu,CHAR_FORWARD_SLASH:cd,CHAR_LEFT_CURLY_BRACE:ru,CHAR_LEFT_PARENTHESES:iu,CHAR_LEFT_SQUARE_BRACKET:XA,CHAR_PLUS:QA,CHAR_QUESTION_MARK:od,CHAR_RIGHT_CURLY_BRACE:ev,CHAR_RIGHT_PARENTHESES:ad,CHAR_RIGHT_SQUARE_BRACKET:tv}=En(),ud=t=>t===cd||t===bn,ld=t=>{t.isPrefix!==!0&&(t.depth=t.isGlobstar?1/0:1)},rv=(t,e)=>{let r=e||{},i=t.length-1,n=r.parts===!0||r.scanToEnd===!0,s=[],o=[],a=[],u=t,l=-1,c=0,f=0,h=!1,p=!1,g=!1,y=!1,E=!1,v=!1,F=!1,O=!1,R=!1,x=!1,L=0,b,S,N={value:"",depth:0,isGlob:!1},H=()=>l>=i,T=()=>u.charCodeAt(l+1),U=()=>(b=S,u.charCodeAt(++l));for(;l<i;){S=U();let k;if(S===bn){F=N.backslashes=!0,S=U(),S===ru&&(v=!0);continue}if(v===!0||S===ru){for(L++;H()!==!0&&(S=U());){if(S===bn){F=N.backslashes=!0,U();continue}if(S===ru){L++;continue}if(v!==!0&&S===eu&&(S=U())===eu){if(h=N.isBrace=!0,g=N.isGlob=!0,x=!0,n===!0)continue;break}if(v!==!0&&S===JA){if(h=N.isBrace=!0,g=N.isGlob=!0,x=!0,n===!0)continue;break}if(S===ev&&(L--,L===0)){v=!1,h=N.isBrace=!0,x=!0;break}}if(n===!0)continue;break}if(S===cd){if(s.push(l),o.push(N),N={value:"",depth:0,isGlob:!1},x===!0)continue;if(b===eu&&l===c+1){c+=2;continue}f=l+1;continue}if(r.noext!==!0&&(S===QA||S===ZA||S===Qa||S===od||S===tu)===!0&&T()===iu){if(g=N.isGlob=!0,y=N.isExtglob=!0,x=!0,S===tu&&l===c&&(R=!0),n===!0){for(;H()!==!0&&(S=U());){if(S===bn){F=N.backslashes=!0,S=U();continue}if(S===ad){g=N.isGlob=!0,x=!0;break}}continue}break}if(S===Qa){if(b===Qa&&(E=N.isGlobstar=!0),g=N.isGlob=!0,x=!0,n===!0)continue;break}if(S===od){if(g=N.isGlob=!0,x=!0,n===!0)continue;break}if(S===XA){for(;H()!==!0&&(k=U());){if(k===bn){F=N.backslashes=!0,U();continue}if(k===tv){p=N.isBracket=!0,g=N.isGlob=!0,x=!0;break}}if(n===!0)continue;break}if(r.nonegate!==!0&&S===tu&&l===c){O=N.negated=!0,c++;continue}if(r.noparen!==!0&&S===iu){if(g=N.isGlob=!0,n===!0){for(;H()!==!0&&(S=U());){if(S===iu){F=N.backslashes=!0,S=U();continue}if(S===ad){x=!0;break}}continue}break}if(g===!0){if(x=!0,n===!0)continue;break}}r.noext===!0&&(y=!1,g=!1);let V=u,K="",B="";c>0&&(K=u.slice(0,c),u=u.slice(c),f-=c),V&&g===!0&&f>0?(V=u.slice(0,f),B=u.slice(f)):g===!0?(V="",B=u):V=u,V&&V!==""&&V!=="/"&&V!==u&&ud(V.charCodeAt(V.length-1))&&(V=V.slice(0,-1)),r.unescape===!0&&(B&&(B=sd.removeBackslashes(B)),V&&F===!0&&(V=sd.removeBackslashes(V)));let C={prefix:K,input:t,start:c,base:V,glob:B,isBrace:h,isBracket:p,isGlob:g,isExtglob:y,isGlobstar:E,negated:O,negatedExtglob:R};if(r.tokens===!0&&(C.maxDepth=0,ud(S)||o.push(N),C.tokens=o),r.parts===!0||r.tokens===!0){let k;for(let j=0;j<s.length;j++){let z=k?k+1:c,P=s[j],d=t.slice(z,P);r.tokens&&(j===0&&c!==0?(o[j].isPrefix=!0,o[j].value=K):o[j].value=d,ld(o[j]),C.maxDepth+=o[j].depth),(j!==0||d!=="")&&a.push(d),k=P}if(k&&k+1<t.length){let j=t.slice(k+1);a.push(j),r.tokens&&(o[o.length-1].value=j,ld(o[o.length-1]),C.maxDepth+=o[o.length-1].depth)}C.slashes=s,C.parts=a}return C};hd.exports=rv});var md=$((NB,dd)=>{"use strict";var ms=En(),Je=Dn(),{MAX_LENGTH:gs,POSIX_REGEX_SOURCE:iv,REGEX_NON_SPECIAL_CHARS:nv,REGEX_SPECIAL_CHARS_BACKREF:sv,REPLACEMENTS:pd}=ms,ov=(t,e)=>{if(typeof e.expandRange=="function")return e.expandRange(...t,e);t.sort();let r=`[${t.join("-")}]`;try{new RegExp(r)}catch{return t.map(n=>Je.escapeRegex(n)).join("..")}return r},di=(t,e)=>`Missing ${t}: "${e}" - use "\\\\${e}" to match literal characters`,nu=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");t=pd[t]||t;let r={...e},i=typeof r.maxLength=="number"?Math.min(gs,r.maxLength):gs,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);let s={type:"bos",value:"",output:r.prepend||""},o=[s],a=r.capture?"":"?:",u=Je.isWindows(e),l=ms.globChars(u),c=ms.extglobChars(l),{DOT_LITERAL:f,PLUS_LITERAL:h,SLASH_LITERAL:p,ONE_CHAR:g,DOTS_SLASH:y,NO_DOT:E,NO_DOT_SLASH:v,NO_DOTS_SLASH:F,QMARK:O,QMARK_NO_DOT:R,STAR:x,START_ANCHOR:L}=l,b=q=>`(${a}(?:(?!${L}${q.dot?y:f}).)*?)`,S=r.dot?"":E,N=r.dot?O:R,H=r.bash===!0?b(r):x;r.capture&&(H=`(${H})`),typeof r.noext=="boolean"&&(r.noextglob=r.noext);let T={input:t,index:-1,start:0,dot:r.dot===!0,consumed:"",output:"",prefix:"",backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:o};t=Je.removePrefix(t,T),n=t.length;let U=[],V=[],K=[],B=s,C,k=()=>T.index===n-1,j=T.peek=(q=1)=>t[T.index+q],z=T.advance=()=>t[++T.index]||"",P=()=>t.slice(T.index+1),d=(q="",Q=0)=>{T.consumed+=q,T.index+=Q},m=q=>{T.output+=q.output!=null?q.output:q.value,d(q.value)},D=()=>{let q=1;for(;j()==="!"&&(j(2)!=="("||j(3)==="?");)z(),T.start++,q++;return q%2===0?!1:(T.negated=!0,T.start++,!0)},A=q=>{T[q]++,K.push(q)},w=q=>{T[q]--,K.pop()},I=q=>{if(B.type==="globstar"){let Q=T.braces>0&&(q.type==="comma"||q.type==="brace"),G=q.extglob===!0||U.length&&(q.type==="pipe"||q.type==="paren");q.type!=="slash"&&q.type!=="paren"&&!Q&&!G&&(T.output=T.output.slice(0,-B.output.length),B.type="star",B.value="*",B.output=H,T.output+=B.output)}if(U.length&&q.type!=="paren"&&(U[U.length-1].inner+=q.value),(q.value||q.output)&&m(q),B&&B.type==="text"&&q.type==="text"){B.value+=q.value,B.output=(B.output||"")+q.value;return}q.prev=B,o.push(q),B=q},M=(q,Q)=>{let G={...c[Q],conditions:1,inner:""};G.prev=B,G.parens=T.parens,G.output=T.output;let ie=(r.capture?"(":"")+G.open;A("parens"),I({type:q,value:Q,output:T.output?"":g}),I({type:"paren",extglob:!0,value:z(),output:ie}),U.push(G)},Z=q=>{let Q=q.close+(r.capture?")":""),G;if(q.type==="negate"){let ie=H;if(q.inner&&q.inner.length>1&&q.inner.includes("/")&&(ie=b(r)),(ie!==H||k()||/^\)+$/.test(P()))&&(Q=q.close=`)$))${ie}`),q.inner.includes("*")&&(G=P())&&/^\.[^\\/.]+$/.test(G)){let ce=nu(G,{...e,fastpaths:!1}).output;Q=q.close=`)${ce})${ie})`}q.prev.type==="bos"&&(T.negatedExtglob=!0)}I({type:"paren",extglob:!0,value:C,output:Q}),w("parens")};if(r.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(t)){let q=!1,Q=t.replace(sv,(G,ie,ce,we,De,_)=>we==="\\"?(q=!0,G):we==="?"?ie?ie+we+(De?O.repeat(De.length):""):_===0?N+(De?O.repeat(De.length):""):O.repeat(ce.length):we==="."?f.repeat(ce.length):we==="*"?ie?ie+we+(De?H:""):H:ie?G:`\\${G}`);return q===!0&&(r.unescape===!0?Q=Q.replace(/\\/g,""):Q=Q.replace(/\\+/g,G=>G.length%2===0?"\\\\":G?"\\":"")),Q===t&&r.contains===!0?(T.output=t,T):(T.output=Je.wrapOutput(Q,T,e),T)}for(;!k();){if(C=z(),C==="\0")continue;if(C==="\\"){let G=j();if(G==="/"&&r.bash!==!0||G==="."||G===";")continue;if(!G){C+="\\",I({type:"text",value:C});continue}let ie=/^\\+/.exec(P()),ce=0;if(ie&&ie[0].length>2&&(ce=ie[0].length,T.index+=ce,ce%2!==0&&(C+="\\")),r.unescape===!0?C=z():C+=z(),T.brackets===0){I({type:"text",value:C});continue}}if(T.brackets>0&&(C!=="]"||B.value==="["||B.value==="[^")){if(r.posix!==!1&&C===":"){let G=B.value.slice(1);if(G.includes("[")&&(B.posix=!0,G.includes(":"))){let ie=B.value.lastIndexOf("["),ce=B.value.slice(0,ie),we=B.value.slice(ie+2),De=iv[we];if(De){B.value=ce+De,T.backtrack=!0,z(),!s.output&&o.indexOf(B)===1&&(s.output=g);continue}}}(C==="["&&j()!==":"||C==="-"&&j()==="]")&&(C=`\\${C}`),C==="]"&&(B.value==="["||B.value==="[^")&&(C=`\\${C}`),r.posix===!0&&C==="!"&&B.value==="["&&(C="^"),B.value+=C,m({value:C});continue}if(T.quotes===1&&C!=='"'){C=Je.escapeRegex(C),B.value+=C,m({value:C});continue}if(C==='"'){T.quotes=T.quotes===1?0:1,r.keepQuotes===!0&&I({type:"text",value:C});continue}if(C==="("){A("parens"),I({type:"paren",value:C});continue}if(C===")"){if(T.parens===0&&r.strictBrackets===!0)throw new SyntaxError(di("opening","("));let G=U[U.length-1];if(G&&T.parens===G.parens+1){Z(U.pop());continue}I({type:"paren",value:C,output:T.parens?")":"\\)"}),w("parens");continue}if(C==="["){if(r.nobracket===!0||!P().includes("]")){if(r.nobracket!==!0&&r.strictBrackets===!0)throw new SyntaxError(di("closing","]"));C=`\\${C}`}else A("brackets");I({type:"bracket",value:C});continue}if(C==="]"){if(r.nobracket===!0||B&&B.type==="bracket"&&B.value.length===1){I({type:"text",value:C,output:`\\${C}`});continue}if(T.brackets===0){if(r.strictBrackets===!0)throw new SyntaxError(di("opening","["));I({type:"text",value:C,output:`\\${C}`});continue}w("brackets");let G=B.value.slice(1);if(B.posix!==!0&&G[0]==="^"&&!G.includes("/")&&(C=`/${C}`),B.value+=C,m({value:C}),r.literalBrackets===!1||Je.hasRegexChars(G))continue;let ie=Je.escapeRegex(B.value);if(T.output=T.output.slice(0,-B.value.length),r.literalBrackets===!0){T.output+=ie,B.value=ie;continue}B.value=`(${a}${ie}|${B.value})`,T.output+=B.value;continue}if(C==="{"&&r.nobrace!==!0){A("braces");let G={type:"brace",value:C,output:"(",outputIndex:T.output.length,tokensIndex:T.tokens.length};V.push(G),I(G);continue}if(C==="}"){let G=V[V.length-1];if(r.nobrace===!0||!G){I({type:"text",value:C,output:C});continue}let ie=")";if(G.dots===!0){let ce=o.slice(),we=[];for(let De=ce.length-1;De>=0&&(o.pop(),ce[De].type!=="brace");De--)ce[De].type!=="dots"&&we.unshift(ce[De].value);ie=ov(we,r),T.backtrack=!0}if(G.comma!==!0&&G.dots!==!0){let ce=T.output.slice(0,G.outputIndex),we=T.tokens.slice(G.tokensIndex);G.value=G.output="\\{",C=ie="\\}",T.output=ce;for(let De of we)T.output+=De.output||De.value}I({type:"brace",value:C,output:ie}),w("braces"),V.pop();continue}if(C==="|"){U.length>0&&U[U.length-1].conditions++,I({type:"text",value:C});continue}if(C===","){let G=C,ie=V[V.length-1];ie&&K[K.length-1]==="braces"&&(ie.comma=!0,G="|"),I({type:"comma",value:C,output:G});continue}if(C==="/"){if(B.type==="dot"&&T.index===T.start+1){T.start=T.index+1,T.consumed="",T.output="",o.pop(),B=s;continue}I({type:"slash",value:C,output:p});continue}if(C==="."){if(T.braces>0&&B.type==="dot"){B.value==="."&&(B.output=f);let G=V[V.length-1];B.type="dots",B.output+=C,B.value+=C,G.dots=!0;continue}if(T.braces+T.parens===0&&B.type!=="bos"&&B.type!=="slash"){I({type:"text",value:C,output:f});continue}I({type:"dot",value:C,output:f});continue}if(C==="?"){if(!(B&&B.value==="(")&&r.noextglob!==!0&&j()==="("&&j(2)!=="?"){M("qmark",C);continue}if(B&&B.type==="paren"){let ie=j(),ce=C;if(ie==="<"&&!Je.supportsLookbehinds())throw new Error("Node.js v10 or higher is required for regex lookbehinds");(B.value==="("&&!/[!=<:]/.test(ie)||ie==="<"&&!/<([!=]|\w+>)/.test(P()))&&(ce=`\\${C}`),I({type:"text",value:C,output:ce});continue}if(r.dot!==!0&&(B.type==="slash"||B.type==="bos")){I({type:"qmark",value:C,output:R});continue}I({type:"qmark",value:C,output:O});continue}if(C==="!"){if(r.noextglob!==!0&&j()==="("&&(j(2)!=="?"||!/[!=<:]/.test(j(3)))){M("negate",C);continue}if(r.nonegate!==!0&&T.index===0){D();continue}}if(C==="+"){if(r.noextglob!==!0&&j()==="("&&j(2)!=="?"){M("plus",C);continue}if(B&&B.value==="("||r.regex===!1){I({type:"plus",value:C,output:h});continue}if(B&&(B.type==="bracket"||B.type==="paren"||B.type==="brace")||T.parens>0){I({type:"plus",value:C});continue}I({type:"plus",value:h});continue}if(C==="@"){if(r.noextglob!==!0&&j()==="("&&j(2)!=="?"){I({type:"at",extglob:!0,value:C,output:""});continue}I({type:"text",value:C});continue}if(C!=="*"){(C==="$"||C==="^")&&(C=`\\${C}`);let G=nv.exec(P());G&&(C+=G[0],T.index+=G[0].length),I({type:"text",value:C});continue}if(B&&(B.type==="globstar"||B.star===!0)){B.type="star",B.star=!0,B.value+=C,B.output=H,T.backtrack=!0,T.globstar=!0,d(C);continue}let q=P();if(r.noextglob!==!0&&/^\([^?]/.test(q)){M("star",C);continue}if(B.type==="star"){if(r.noglobstar===!0){d(C);continue}let G=B.prev,ie=G.prev,ce=G.type==="slash"||G.type==="bos",we=ie&&(ie.type==="star"||ie.type==="globstar");if(r.bash===!0&&(!ce||q[0]&&q[0]!=="/")){I({type:"star",value:C,output:""});continue}let De=T.braces>0&&(G.type==="comma"||G.type==="brace"),_=U.length&&(G.type==="pipe"||G.type==="paren");if(!ce&&G.type!=="paren"&&!De&&!_){I({type:"star",value:C,output:""});continue}for(;q.slice(0,3)==="/**";){let Y=t[T.index+4];if(Y&&Y!=="/")break;q=q.slice(3),d("/**",3)}if(G.type==="bos"&&k()){B.type="globstar",B.value+=C,B.output=b(r),T.output=B.output,T.globstar=!0,d(C);continue}if(G.type==="slash"&&G.prev.type!=="bos"&&!we&&k()){T.output=T.output.slice(0,-(G.output+B.output).length),G.output=`(?:${G.output}`,B.type="globstar",B.output=b(r)+(r.strictSlashes?")":"|$)"),B.value+=C,T.globstar=!0,T.output+=G.output+B.output,d(C);continue}if(G.type==="slash"&&G.prev.type!=="bos"&&q[0]==="/"){let Y=q[1]!==void 0?"|$":"";T.output=T.output.slice(0,-(G.output+B.output).length),G.output=`(?:${G.output}`,B.type="globstar",B.output=`${b(r)}${p}|${p}${Y})`,B.value+=C,T.output+=G.output+B.output,T.globstar=!0,d(C+z()),I({type:"slash",value:"/",output:""});continue}if(G.type==="bos"&&q[0]==="/"){B.type="globstar",B.value+=C,B.output=`(?:^|${p}|${b(r)}${p})`,T.output=B.output,T.globstar=!0,d(C+z()),I({type:"slash",value:"/",output:""});continue}T.output=T.output.slice(0,-B.output.length),B.type="globstar",B.output=b(r),B.value+=C,T.output+=B.output,T.globstar=!0,d(C);continue}let Q={type:"star",value:C,output:H};if(r.bash===!0){Q.output=".*?",(B.type==="bos"||B.type==="slash")&&(Q.output=S+Q.output),I(Q);continue}if(B&&(B.type==="bracket"||B.type==="paren")&&r.regex===!0){Q.output=C,I(Q);continue}(T.index===T.start||B.type==="slash"||B.type==="dot")&&(B.type==="dot"?(T.output+=v,B.output+=v):r.dot===!0?(T.output+=F,B.output+=F):(T.output+=S,B.output+=S),j()!=="*"&&(T.output+=g,B.output+=g)),I(Q)}for(;T.brackets>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing","]"));T.output=Je.escapeLast(T.output,"["),w("brackets")}for(;T.parens>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing",")"));T.output=Je.escapeLast(T.output,"("),w("parens")}for(;T.braces>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing","}"));T.output=Je.escapeLast(T.output,"{"),w("braces")}if(r.strictSlashes!==!0&&(B.type==="star"||B.type==="bracket")&&I({type:"maybe_slash",value:"",output:`${p}?`}),T.backtrack===!0){T.output="";for(let q of T.tokens)T.output+=q.output!=null?q.output:q.value,q.suffix&&(T.output+=q.suffix)}return T};nu.fastpaths=(t,e)=>{let r={...e},i=typeof r.maxLength=="number"?Math.min(gs,r.maxLength):gs,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);t=pd[t]||t;let s=Je.isWindows(e),{DOT_LITERAL:o,SLASH_LITERAL:a,ONE_CHAR:u,DOTS_SLASH:l,NO_DOT:c,NO_DOTS:f,NO_DOTS_SLASH:h,STAR:p,START_ANCHOR:g}=ms.globChars(s),y=r.dot?f:c,E=r.dot?h:c,v=r.capture?"":"?:",F={negated:!1,prefix:""},O=r.bash===!0?".*?":p;r.capture&&(O=`(${O})`);let R=S=>S.noglobstar===!0?O:`(${v}(?:(?!${g}${S.dot?l:o}).)*?)`,x=S=>{switch(S){case"*":return`${y}${u}${O}`;case".*":return`${o}${u}${O}`;case"*.*":return`${y}${O}${o}${u}${O}`;case"*/*":return`${y}${O}${a}${u}${E}${O}`;case"**":return y+R(r);case"**/*":return`(?:${y}${R(r)}${a})?${E}${u}${O}`;case"**/*.*":return`(?:${y}${R(r)}${a})?${E}${O}${o}${u}${O}`;case"**/.*":return`(?:${y}${R(r)}${a})?${o}${u}${O}`;default:{let N=/^(.*?)\.(\w+)$/.exec(S);if(!N)return;let H=x(N[1]);return H?H+o+N[2]:void 0}}},L=Je.removePrefix(t,F),b=x(L);return b&&r.strictSlashes!==!0&&(b+=`${a}?`),b};dd.exports=nu});var yd=$((MB,gd)=>{"use strict";var av=require("path"),uv=fd(),su=md(),ou=Dn(),lv=En(),cv=t=>t&&typeof t=="object"&&!Array.isArray(t),be=(t,e,r=!1)=>{if(Array.isArray(t)){let c=t.map(h=>be(h,e,r));return h=>{for(let p of c){let g=p(h);if(g)return g}return!1}}let i=cv(t)&&t.tokens&&t.input;if(t===""||typeof t!="string"&&!i)throw new TypeError("Expected pattern to be a non-empty string");let n=e||{},s=ou.isWindows(e),o=i?be.compileRe(t,e):be.makeRe(t,e,!1,!0),a=o.state;delete o.state;let u=()=>!1;if(n.ignore){let c={...e,ignore:null,onMatch:null,onResult:null};u=be(n.ignore,c,r)}let l=(c,f=!1)=>{let{isMatch:h,match:p,output:g}=be.test(c,o,e,{glob:t,posix:s}),y={glob:t,state:a,regex:o,posix:s,input:c,output:g,match:p,isMatch:h};return typeof n.onResult=="function"&&n.onResult(y),h===!1?(y.isMatch=!1,f?y:!1):u(c)?(typeof n.onIgnore=="function"&&n.onIgnore(y),y.isMatch=!1,f?y:!1):(typeof n.onMatch=="function"&&n.onMatch(y),f?y:!0)};return r&&(l.state=a),l};be.test=(t,e,r,{glob:i,posix:n}={})=>{if(typeof t!="string")throw new TypeError("Expected input to be a string");if(t==="")return{isMatch:!1,output:""};let s=r||{},o=s.format||(n?ou.toPosixSlashes:null),a=t===i,u=a&&o?o(t):t;return a===!1&&(u=o?o(t):t,a=u===i),(a===!1||s.capture===!0)&&(s.matchBase===!0||s.basename===!0?a=be.matchBase(t,e,r,n):a=e.exec(u)),{isMatch:!!a,match:a,output:u}};be.matchBase=(t,e,r,i=ou.isWindows(r))=>(e instanceof RegExp?e:be.makeRe(e,r)).test(av.basename(t));be.isMatch=(t,e,r)=>be(e,r)(t);be.parse=(t,e)=>Array.isArray(t)?t.map(r=>be.parse(r,e)):su(t,{...e,fastpaths:!1});be.scan=(t,e)=>uv(t,e);be.compileRe=(t,e,r=!1,i=!1)=>{if(r===!0)return t.output;let n=e||{},s=n.contains?"":"^",o=n.contains?"":"$",a=`${s}(?:${t.output})${o}`;t&&t.negated===!0&&(a=`^(?!${a}).*$`);let u=be.toRegex(a,e);return i===!0&&(u.state=t),u};be.makeRe=(t,e={},r=!1,i=!1)=>{if(!t||typeof t!="string")throw new TypeError("Expected a non-empty string");let n={negated:!1,fastpaths:!0};return e.fastpaths!==!1&&(t[0]==="."||t[0]==="*")&&(n.output=su.fastpaths(t,e)),n.output||(n=su(t,e)),be.compileRe(n,e,r,i)};be.toRegex=(t,e)=>{try{let r=e||{};return new RegExp(t,r.flags||(r.nocase?"i":""))}catch(r){if(e&&e.debug===!0)throw r;return/$^/}};be.constants=lv;gd.exports=be});var Dd=$((jB,Ed)=>{"use strict";Ed.exports=yd()});var Ad=$(($B,Sd)=>{"use strict";var _d=require("util"),wd=Qp(),_t=Dd(),au=Dn(),bd=t=>t===""||t==="./",ge=(t,e,r)=>{e=[].concat(e),t=[].concat(t);let i=new Set,n=new Set,s=new Set,o=0,a=c=>{s.add(c.output),r&&r.onResult&&r.onResult(c)};for(let c=0;c<e.length;c++){let f=_t(String(e[c]),{...r,onResult:a},!0),h=f.state.negated||f.state.negatedExtglob;h&&o++;for(let p of t){let g=f(p,!0);(h?!g.isMatch:g.isMatch)&&(h?i.add(g.output):(i.delete(g.output),n.add(g.output)))}}let l=(o===e.length?[...s]:[...n]).filter(c=>!i.has(c));if(r&&l.length===0){if(r.failglob===!0)throw new Error(`No matches found for "${e.join(", ")}"`);if(r.nonull===!0||r.nullglob===!0)return r.unescape?e.map(c=>c.replace(/\\/g,"")):e}return l};ge.match=ge;ge.matcher=(t,e)=>_t(t,e);ge.isMatch=(t,e,r)=>_t(e,r)(t);ge.any=ge.isMatch;ge.not=(t,e,r={})=>{e=[].concat(e).map(String);let i=new Set,n=[],s=a=>{r.onResult&&r.onResult(a),n.push(a.output)},o=new Set(ge(t,e,{...r,onResult:s}));for(let a of n)o.has(a)||i.add(a);return[...i]};ge.contains=(t,e,r)=>{if(typeof t!="string")throw new TypeError(`Expected a string: "${_d.inspect(t)}"`);if(Array.isArray(e))return e.some(i=>ge.contains(t,i,r));if(typeof e=="string"){if(bd(t)||bd(e))return!1;if(t.includes(e)||t.startsWith("./")&&t.slice(2).includes(e))return!0}return ge.isMatch(t,e,{...r,contains:!0})};ge.matchKeys=(t,e,r)=>{if(!au.isObject(t))throw new TypeError("Expected the first argument to be an object");let i=ge(Object.keys(t),e,r),n={};for(let s of i)n[s]=t[s];return n};ge.some=(t,e,r)=>{let i=[].concat(t);for(let n of[].concat(e)){let s=_t(String(n),r);if(i.some(o=>s(o)))return!0}return!1};ge.every=(t,e,r)=>{let i=[].concat(t);for(let n of[].concat(e)){let s=_t(String(n),r);if(!i.every(o=>s(o)))return!1}return!0};ge.all=(t,e,r)=>{if(typeof t!="string")throw new TypeError(`Expected a string: "${_d.inspect(t)}"`);return[].concat(e).every(i=>_t(i,r)(t))};ge.capture=(t,e,r)=>{let i=au.isWindows(r),s=_t.makeRe(String(t),{...r,capture:!0}).exec(i?au.toPosixSlashes(e):e);if(s)return s.slice(1).map(o=>o===void 0?"":o)};ge.makeRe=(...t)=>_t.makeRe(...t);ge.scan=(...t)=>_t.scan(...t);ge.parse=(t,e)=>{let r=[];for(let i of[].concat(t||[]))for(let n of wd(String(i),e))r.push(_t.parse(n,e));return r};ge.braces=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return e&&e.nobrace===!0||!/\{.*\}/.test(t)?[t]:wd(t,e)};ge.braceExpand=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return ge.braces(t,{...e,expand:!0})};Sd.exports=ge});var Td=$(se=>{"use strict";Object.defineProperty(se,"__esModule",{value:!0});se.matchAny=se.convertPatternsToRe=se.makeRe=se.getPatternParts=se.expandBraceExpansion=se.expandPatternsWithBraceExpansion=se.isAffectDepthOfReadingPattern=se.endsWithSlashGlobStar=se.hasGlobStar=se.getBaseDirectory=se.isPatternRelatedToParentDirectory=se.getPatternsOutsideCurrentDirectory=se.getPatternsInsideCurrentDirectory=se.getPositivePatterns=se.getNegativePatterns=se.isPositivePattern=se.isNegativePattern=se.convertToNegativePattern=se.convertToPositivePattern=se.isDynamicPattern=se.isStaticPattern=void 0;var hv=require("path"),fv=gp(),uu=Ad(),vd="**",pv="\\",dv=/[*?]|^!/,mv=/\[[^[]*]/,gv=/(?:^|[^!*+?@])\([^(]*\|[^|]*\)/,yv=/[!*+?@]\([^(]*\)/,Ev=/,|\.\./;function Cd(t,e={}){return!xd(t,e)}se.isStaticPattern=Cd;function xd(t,e={}){return t===""?!1:!!(e.caseSensitiveMatch===!1||t.includes(pv)||dv.test(t)||mv.test(t)||gv.test(t)||e.extglob!==!1&&yv.test(t)||e.braceExpansion!==!1&&Dv(t))}se.isDynamicPattern=xd;function Dv(t){let e=t.indexOf("{");if(e===-1)return!1;let r=t.indexOf("}",e+1);if(r===-1)return!1;let i=t.slice(e,r);return Ev.test(i)}function bv(t){return ys(t)?t.slice(1):t}se.convertToPositivePattern=bv;function _v(t){return"!"+t}se.convertToNegativePattern=_v;function ys(t){return t.startsWith("!")&&t[1]!=="("}se.isNegativePattern=ys;function Rd(t){return!ys(t)}se.isPositivePattern=Rd;function wv(t){return t.filter(ys)}se.getNegativePatterns=wv;function Sv(t){return t.filter(Rd)}se.getPositivePatterns=Sv;function Av(t){return t.filter(e=>!lu(e))}se.getPatternsInsideCurrentDirectory=Av;function vv(t){return t.filter(lu)}se.getPatternsOutsideCurrentDirectory=vv;function lu(t){return t.startsWith("..")||t.startsWith("./..")}se.isPatternRelatedToParentDirectory=lu;function Cv(t){return fv(t,{flipBackslashes:!1})}se.getBaseDirectory=Cv;function xv(t){return t.includes(vd)}se.hasGlobStar=xv;function Fd(t){return t.endsWith("/"+vd)}se.endsWithSlashGlobStar=Fd;function Rv(t){let e=hv.basename(t);return Fd(t)||Cd(e)}se.isAffectDepthOfReadingPattern=Rv;function Fv(t){return t.reduce((e,r)=>e.concat(Od(r)),[])}se.expandPatternsWithBraceExpansion=Fv;function Od(t){return uu.braces(t,{expand:!0,nodupes:!0})}se.expandBraceExpansion=Od;function Ov(t,e){let{parts:r}=uu.scan(t,Object.assign(Object.assign({},e),{parts:!0}));return r.length===0&&(r=[t]),r[0].startsWith("/")&&(r[0]=r[0].slice(1),r.unshift("")),r}se.getPatternParts=Ov;function kd(t,e){return uu.makeRe(t,e)}se.makeRe=kd;function kv(t,e){return t.map(r=>kd(r,e))}se.convertPatternsToRe=kv;function Tv(t,e){return e.some(r=>r.test(t))}se.matchAny=Tv});var Id=$((qB,Pd)=>{"use strict";var Lv=require("stream"),Ld=Lv.PassThrough,Bv=Array.prototype.slice;Pd.exports=Pv;function Pv(){let t=[],e=Bv.call(arguments),r=!1,i=e[e.length-1];i&&!Array.isArray(i)&&i.pipe==null?e.pop():i={};let n=i.end!==!1,s=i.pipeError===!0;i.objectMode==null&&(i.objectMode=!0),i.highWaterMark==null&&(i.highWaterMark=64*1024);let o=Ld(i);function a(){for(let c=0,f=arguments.length;c<f;c++)t.push(Bd(arguments[c],i));return u(),this}function u(){if(r)return;r=!0;let c=t.shift();if(!c){process.nextTick(l);return}Array.isArray(c)||(c=[c]);let f=c.length+1;function h(){--f>0||(r=!1,u())}function p(g){function y(){g.removeListener("merge2UnpipeEnd",y),g.removeListener("end",y),s&&g.removeListener("error",E),h()}function E(v){o.emit("error",v)}if(g._readableState.endEmitted)return h();g.on("merge2UnpipeEnd",y),g.on("end",y),s&&g.on("error",E),g.pipe(o,{end:!1}),g.resume()}for(let g=0;g<c.length;g++)p(c[g]);h()}function l(){r=!1,o.emit("queueDrain"),n&&o.end()}return o.setMaxListeners(0),o.add=a,o.on("unpipe",function(c){c.emit("merge2UnpipeEnd")}),e.length&&a.apply(null,e),o}function Bd(t,e){if(Array.isArray(t))for(let r=0,i=t.length;r<i;r++)t[r]=Bd(t[r],e);else{if(!t._readableState&&t.pipe&&(t=t.pipe(Ld(e))),!t._readableState||!t.pause||!t.pipe)throw new Error("Only readable stream can be merged.");t.pause()}return t}});var Md=$(Es=>{"use strict";Object.defineProperty(Es,"__esModule",{value:!0});Es.merge=void 0;var Iv=Id();function Nv(t){let e=Iv(t);return t.forEach(r=>{r.once("error",i=>e.emit("error",i))}),e.once("close",()=>Nd(t)),e.once("end",()=>Nd(t)),e}Es.merge=Nv;function Nd(t){t.forEach(e=>e.emit("close"))}});var jd=$(mi=>{"use strict";Object.defineProperty(mi,"__esModule",{value:!0});mi.isEmpty=mi.isString=void 0;function Mv(t){return typeof t=="string"}mi.isString=Mv;function jv(t){return t===""}mi.isEmpty=jv});var $t=$(Te=>{"use strict";Object.defineProperty(Te,"__esModule",{value:!0});Te.string=Te.stream=Te.pattern=Te.path=Te.fs=Te.errno=Te.array=void 0;var $v=op();Te.array=$v;var Hv=ap();Te.errno=Hv;var qv=up();Te.fs=qv;var Uv=lp();Te.path=Uv;var Gv=Td();Te.pattern=Gv;var zv=Md();Te.stream=zv;var Wv=jd();Te.string=Wv});var qd=$(Le=>{"use strict";Object.defineProperty(Le,"__esModule",{value:!0});Le.convertPatternGroupToTask=Le.convertPatternGroupsToTasks=Le.groupPatternsByBaseDirectory=Le.getNegativePatternsAsPositive=Le.getPositivePatterns=Le.convertPatternsToTasks=Le.generate=void 0;var Ht=$t();function Yv(t,e){let r=$d(t),i=Hd(t,e.ignore),n=r.filter(u=>Ht.pattern.isStaticPattern(u,e)),s=r.filter(u=>Ht.pattern.isDynamicPattern(u,e)),o=cu(n,i,!1),a=cu(s,i,!0);return o.concat(a)}Le.generate=Yv;function cu(t,e,r){let i=[],n=Ht.pattern.getPatternsOutsideCurrentDirectory(t),s=Ht.pattern.getPatternsInsideCurrentDirectory(t),o=hu(n),a=hu(s);return i.push(...fu(o,e,r)),"."in a?i.push(pu(".",s,e,r)):i.push(...fu(a,e,r)),i}Le.convertPatternsToTasks=cu;function $d(t){return Ht.pattern.getPositivePatterns(t)}Le.getPositivePatterns=$d;function Hd(t,e){return Ht.pattern.getNegativePatterns(t).concat(e).map(Ht.pattern.convertToPositivePattern)}Le.getNegativePatternsAsPositive=Hd;function hu(t){let e={};return t.reduce((r,i)=>{let n=Ht.pattern.getBaseDirectory(i);return n in r?r[n].push(i):r[n]=[i],r},e)}Le.groupPatternsByBaseDirectory=hu;function fu(t,e,r){return Object.keys(t).map(i=>pu(i,t[i],e,r))}Le.convertPatternGroupsToTasks=fu;function pu(t,e,r,i){return{dynamic:i,positive:e,negative:r,base:t,patterns:[].concat(e,r.map(Ht.pattern.convertToNegativePattern))}}Le.convertPatternGroupToTask=pu});var Gd=$(gi=>{"use strict";Object.defineProperty(gi,"__esModule",{value:!0});gi.removeDuplicateSlashes=gi.transform=void 0;var Vv=/(?!^)\/{2,}/g;function Kv(t){return t.map(e=>Ud(e))}gi.transform=Kv;function Ud(t){return t.replace(Vv,"/")}gi.removeDuplicateSlashes=Ud});var Wd=$(Ds=>{"use strict";Object.defineProperty(Ds,"__esModule",{value:!0});Ds.read=void 0;function Zv(t,e,r){e.fs.lstat(t,(i,n)=>{if(i!==null){zd(r,i);return}if(!n.isSymbolicLink()||!e.followSymbolicLink){du(r,n);return}e.fs.stat(t,(s,o)=>{if(s!==null){if(e.throwErrorOnBrokenSymbolicLink){zd(r,s);return}du(r,n);return}e.markSymbolicLink&&(o.isSymbolicLink=()=>!0),du(r,o)})})}Ds.read=Zv;function zd(t,e){t(e)}function du(t,e){t(null,e)}});var Yd=$(bs=>{"use strict";Object.defineProperty(bs,"__esModule",{value:!0});bs.read=void 0;function Jv(t,e){let r=e.fs.lstatSync(t);if(!r.isSymbolicLink()||!e.followSymbolicLink)return r;try{let i=e.fs.statSync(t);return e.markSymbolicLink&&(i.isSymbolicLink=()=>!0),i}catch(i){if(!e.throwErrorOnBrokenSymbolicLink)return r;throw i}}bs.read=Jv});var Vd=$(sr=>{"use strict";Object.defineProperty(sr,"__esModule",{value:!0});sr.createFileSystemAdapter=sr.FILE_SYSTEM_ADAPTER=void 0;var _s=require("fs");sr.FILE_SYSTEM_ADAPTER={lstat:_s.lstat,stat:_s.stat,lstatSync:_s.lstatSync,statSync:_s.statSync};function Xv(t){return t===void 0?sr.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},sr.FILE_SYSTEM_ADAPTER),t)}sr.createFileSystemAdapter=Xv});var Kd=$(gu=>{"use strict";Object.defineProperty(gu,"__esModule",{value:!0});var Qv=Vd(),mu=class{constructor(e={}){this._options=e,this.followSymbolicLink=this._getValue(this._options.followSymbolicLink,!0),this.fs=Qv.createFileSystemAdapter(this._options.fs),this.markSymbolicLink=this._getValue(this._options.markSymbolicLink,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0)}_getValue(e,r){return e!=null?e:r}};gu.default=mu});var Mr=$(or=>{"use strict";Object.defineProperty(or,"__esModule",{value:!0});or.statSync=or.stat=or.Settings=void 0;var Zd=Wd(),e1=Yd(),yu=Kd();or.Settings=yu.default;function t1(t,e,r){if(typeof e=="function"){Zd.read(t,Eu(),e);return}Zd.read(t,Eu(e),r)}or.stat=t1;function r1(t,e){let r=Eu(e);return e1.read(t,r)}or.statSync=r1;function Eu(t={}){return t instanceof yu.default?t:new yu.default(t)}});var Qd=$((QB,Xd)=>{var Jd;Xd.exports=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window!="undefined"?window:global):t=>(Jd||(Jd=Promise.resolve())).then(t).catch(e=>setTimeout(()=>{throw e},0))});var tm=$((eP,em)=>{em.exports=n1;var i1=Qd();function n1(t,e){let r,i,n,s=!0;Array.isArray(t)?(r=[],i=t.length):(n=Object.keys(t),r={},i=n.length);function o(u){function l(){e&&e(u,r),e=null}s?i1(l):l()}function a(u,l,c){r[u]=c,(--i===0||l)&&o(l)}i?n?n.forEach(function(u){t[u](function(l,c){a(u,l,c)})}):t.forEach(function(u,l){u(function(c,f){a(l,c,f)})}):o(null),s=!1}});var Du=$(Ss=>{"use strict";Object.defineProperty(Ss,"__esModule",{value:!0});Ss.IS_SUPPORT_READDIR_WITH_FILE_TYPES=void 0;var ws=process.versions.node.split(".");if(ws[0]===void 0||ws[1]===void 0)throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`);var rm=Number.parseInt(ws[0],10),s1=Number.parseInt(ws[1],10),im=10,o1=10,a1=rm>im,u1=rm===im&&s1>=o1;Ss.IS_SUPPORT_READDIR_WITH_FILE_TYPES=a1||u1});var nm=$(As=>{"use strict";Object.defineProperty(As,"__esModule",{value:!0});As.createDirentFromStats=void 0;var bu=class{constructor(e,r){this.name=e,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function l1(t,e){return new bu(t,e)}As.createDirentFromStats=l1});var _u=$(vs=>{"use strict";Object.defineProperty(vs,"__esModule",{value:!0});vs.fs=void 0;var c1=nm();vs.fs=c1});var wu=$(Cs=>{"use strict";Object.defineProperty(Cs,"__esModule",{value:!0});Cs.joinPathSegments=void 0;function h1(t,e,r){return t.endsWith(r)?t+e:t+r+e}Cs.joinPathSegments=h1});var cm=$(ar=>{"use strict";Object.defineProperty(ar,"__esModule",{value:!0});ar.readdir=ar.readdirWithFileTypes=ar.read=void 0;var f1=Mr(),sm=tm(),p1=Du(),om=_u(),am=wu();function d1(t,e,r){if(!e.stats&&p1.IS_SUPPORT_READDIR_WITH_FILE_TYPES){um(t,e,r);return}lm(t,e,r)}ar.read=d1;function um(t,e,r){e.fs.readdir(t,{withFileTypes:!0},(i,n)=>{if(i!==null){xs(r,i);return}let s=n.map(a=>({dirent:a,name:a.name,path:am.joinPathSegments(t,a.name,e.pathSegmentSeparator)}));if(!e.followSymbolicLinks){Su(r,s);return}let o=s.map(a=>m1(a,e));sm(o,(a,u)=>{if(a!==null){xs(r,a);return}Su(r,u)})})}ar.readdirWithFileTypes=um;function m1(t,e){return r=>{if(!t.dirent.isSymbolicLink()){r(null,t);return}e.fs.stat(t.path,(i,n)=>{if(i!==null){if(e.throwErrorOnBrokenSymbolicLink){r(i);return}r(null,t);return}t.dirent=om.fs.createDirentFromStats(t.name,n),r(null,t)})}}function lm(t,e,r){e.fs.readdir(t,(i,n)=>{if(i!==null){xs(r,i);return}let s=n.map(o=>{let a=am.joinPathSegments(t,o,e.pathSegmentSeparator);return u=>{f1.stat(a,e.fsStatSettings,(l,c)=>{if(l!==null){u(l);return}let f={name:o,path:a,dirent:om.fs.createDirentFromStats(o,c)};e.stats&&(f.stats=c),u(null,f)})}});sm(s,(o,a)=>{if(o!==null){xs(r,o);return}Su(r,a)})})}ar.readdir=lm;function xs(t,e){t(e)}function Su(t,e){t(null,e)}});var mm=$(ur=>{"use strict";Object.defineProperty(ur,"__esModule",{value:!0});ur.readdir=ur.readdirWithFileTypes=ur.read=void 0;var g1=Mr(),y1=Du(),hm=_u(),fm=wu();function E1(t,e){return!e.stats&&y1.IS_SUPPORT_READDIR_WITH_FILE_TYPES?pm(t,e):dm(t,e)}ur.read=E1;function pm(t,e){return e.fs.readdirSync(t,{withFileTypes:!0}).map(i=>{let n={dirent:i,name:i.name,path:fm.joinPathSegments(t,i.name,e.pathSegmentSeparator)};if(n.dirent.isSymbolicLink()&&e.followSymbolicLinks)try{let s=e.fs.statSync(n.path);n.dirent=hm.fs.createDirentFromStats(n.name,s)}catch(s){if(e.throwErrorOnBrokenSymbolicLink)throw s}return n})}ur.readdirWithFileTypes=pm;function dm(t,e){return e.fs.readdirSync(t).map(i=>{let n=fm.joinPathSegments(t,i,e.pathSegmentSeparator),s=g1.statSync(n,e.fsStatSettings),o={name:i,path:n,dirent:hm.fs.createDirentFromStats(i,s)};return e.stats&&(o.stats=s),o})}ur.readdir=dm});var gm=$(lr=>{"use strict";Object.defineProperty(lr,"__esModule",{value:!0});lr.createFileSystemAdapter=lr.FILE_SYSTEM_ADAPTER=void 0;var yi=require("fs");lr.FILE_SYSTEM_ADAPTER={lstat:yi.lstat,stat:yi.stat,lstatSync:yi.lstatSync,statSync:yi.statSync,readdir:yi.readdir,readdirSync:yi.readdirSync};function D1(t){return t===void 0?lr.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},lr.FILE_SYSTEM_ADAPTER),t)}lr.createFileSystemAdapter=D1});var ym=$(vu=>{"use strict";Object.defineProperty(vu,"__esModule",{value:!0});var b1=require("path"),_1=Mr(),w1=gm(),Au=class{constructor(e={}){this._options=e,this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!1),this.fs=w1.createFileSystemAdapter(this._options.fs),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,b1.sep),this.stats=this._getValue(this._options.stats,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0),this.fsStatSettings=new _1.Settings({followSymbolicLink:this.followSymbolicLinks,fs:this.fs,throwErrorOnBrokenSymbolicLink:this.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};vu.default=Au});var Rs=$(cr=>{"use strict";Object.defineProperty(cr,"__esModule",{value:!0});cr.Settings=cr.scandirSync=cr.scandir=void 0;var Em=cm(),S1=mm(),Cu=ym();cr.Settings=Cu.default;function A1(t,e,r){if(typeof e=="function"){Em.read(t,xu(),e);return}Em.read(t,xu(e),r)}cr.scandir=A1;function v1(t,e){let r=xu(e);return S1.read(t,r)}cr.scandirSync=v1;function xu(t={}){return t instanceof Cu.default?t:new Cu.default(t)}});var bm=$((cP,Dm)=>{"use strict";function C1(t){var e=new t,r=e;function i(){var s=e;return s.next?e=s.next:(e=new t,r=e),s.next=null,s}function n(s){r.next=s,r=s}return{get:i,release:n}}Dm.exports=C1});var wm=$((hP,Ru)=>{"use strict";var x1=bm();function _m(t,e,r){if(typeof t=="function"&&(r=e,e=t,t=null),r<1)throw new Error("fastqueue concurrency must be greater than 1");var i=x1(R1),n=null,s=null,o=0,a=null,u={push:y,drain:nt,saturated:nt,pause:c,paused:!1,concurrency:r,running:l,resume:p,idle:g,length:f,getQueue:h,unshift:E,empty:nt,kill:F,killAndDrain:O,error:R};return u;function l(){return o}function c(){u.paused=!0}function f(){for(var x=n,L=0;x;)x=x.next,L++;return L}function h(){for(var x=n,L=[];x;)L.push(x.value),x=x.next;return L}function p(){if(u.paused){u.paused=!1;for(var x=0;x<u.concurrency;x++)o++,v()}}function g(){return o===0&&u.length()===0}function y(x,L){var b=i.get();b.context=t,b.release=v,b.value=x,b.callback=L||nt,b.errorHandler=a,o===u.concurrency||u.paused?s?(s.next=b,s=b):(n=b,s=b,u.saturated()):(o++,e.call(t,b.value,b.worked))}function E(x,L){var b=i.get();b.context=t,b.release=v,b.value=x,b.callback=L||nt,o===u.concurrency||u.paused?n?(b.next=n,n=b):(n=b,s=b,u.saturated()):(o++,e.call(t,b.value,b.worked))}function v(x){x&&i.release(x);var L=n;L?u.paused?o--:(s===n&&(s=null),n=L.next,L.next=null,e.call(t,L.value,L.worked),s===null&&u.empty()):--o===0&&u.drain()}function F(){n=null,s=null,u.drain=nt}function O(){n=null,s=null,u.drain(),u.drain=nt}function R(x){a=x}}function nt(){}function R1(){this.value=null,this.callback=nt,this.next=null,this.release=nt,this.context=null,this.errorHandler=null;var t=this;this.worked=function(r,i){var n=t.callback,s=t.errorHandler,o=t.value;t.value=null,t.callback=nt,t.errorHandler&&s(r,o),n.call(t.context,r,i),t.release(t)}}function F1(t,e,r){typeof t=="function"&&(r=e,e=t,t=null);function i(c,f){e.call(this,c).then(function(h){f(null,h)},f)}var n=_m(t,i,r),s=n.push,o=n.unshift;return n.push=a,n.unshift=u,n.drained=l,n;function a(c){var f=new Promise(function(h,p){s(c,function(g,y){if(g){p(g);return}h(y)})});return f.catch(nt),f}function u(c){var f=new Promise(function(h,p){o(c,function(g,y){if(g){p(g);return}h(y)})});return f.catch(nt),f}function l(){var c=n.drain,f=new Promise(function(h){n.drain=function(){c(),h()}});return f}}Ru.exports=_m;Ru.exports.promise=F1});var Fs=$(wt=>{"use strict";Object.defineProperty(wt,"__esModule",{value:!0});wt.joinPathSegments=wt.replacePathSegmentSeparator=wt.isAppliedFilter=wt.isFatalError=void 0;function O1(t,e){return t.errorFilter===null?!0:!t.errorFilter(e)}wt.isFatalError=O1;function k1(t,e){return t===null||t(e)}wt.isAppliedFilter=k1;function T1(t,e){return t.split(/[/\\]/).join(e)}wt.replacePathSegmentSeparator=T1;function L1(t,e,r){return t===""?e:t.endsWith(r)?t+e:t+r+e}wt.joinPathSegments=L1});var ku=$(Ou=>{"use strict";Object.defineProperty(Ou,"__esModule",{value:!0});var B1=Fs(),Fu=class{constructor(e,r){this._root=e,this._settings=r,this._root=B1.replacePathSegmentSeparator(e,r.pathSegmentSeparator)}};Ou.default=Fu});var Bu=$(Lu=>{"use strict";Object.defineProperty(Lu,"__esModule",{value:!0});var P1=require("events"),I1=Rs(),N1=wm(),Os=Fs(),M1=ku(),Tu=class extends M1.default{constructor(e,r){super(e,r),this._settings=r,this._scandir=I1.scandir,this._emitter=new P1.EventEmitter,this._queue=N1(this._worker.bind(this),this._settings.concurrency),this._isFatalError=!1,this._isDestroyed=!1,this._queue.drain=()=>{this._isFatalError||this._emitter.emit("end")}}read(){return this._isFatalError=!1,this._isDestroyed=!1,setImmediate(()=>{this._pushToQueue(this._root,this._settings.basePath)}),this._emitter}get isDestroyed(){return this._isDestroyed}destroy(){if(this._isDestroyed)throw new Error("The reader is already destroyed");this._isDestroyed=!0,this._queue.killAndDrain()}onEntry(e){this._emitter.on("entry",e)}onError(e){this._emitter.once("error",e)}onEnd(e){this._emitter.once("end",e)}_pushToQueue(e,r){let i={directory:e,base:r};this._queue.push(i,n=>{n!==null&&this._handleError(n)})}_worker(e,r){this._scandir(e.directory,this._settings.fsScandirSettings,(i,n)=>{if(i!==null){r(i,void 0);return}for(let s of n)this._handleEntry(s,e.base);r(null,void 0)})}_handleError(e){this._isDestroyed||!Os.isFatalError(this._settings,e)||(this._isFatalError=!0,this._isDestroyed=!0,this._emitter.emit("error",e))}_handleEntry(e,r){if(this._isDestroyed||this._isFatalError)return;let i=e.path;r!==void 0&&(e.path=Os.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),Os.isAppliedFilter(this._settings.entryFilter,e)&&this._emitEntry(e),e.dirent.isDirectory()&&Os.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,r===void 0?void 0:e.path)}_emitEntry(e){this._emitter.emit("entry",e)}};Lu.default=Tu});var Sm=$(Iu=>{"use strict";Object.defineProperty(Iu,"__esModule",{value:!0});var j1=Bu(),Pu=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new j1.default(this._root,this._settings),this._storage=[]}read(e){this._reader.onError(r=>{$1(e,r)}),this._reader.onEntry(r=>{this._storage.push(r)}),this._reader.onEnd(()=>{H1(e,this._storage)}),this._reader.read()}};Iu.default=Pu;function $1(t,e){t(e)}function H1(t,e){t(null,e)}});var Am=$(Mu=>{"use strict";Object.defineProperty(Mu,"__esModule",{value:!0});var q1=require("stream"),U1=Bu(),Nu=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new U1.default(this._root,this._settings),this._stream=new q1.Readable({objectMode:!0,read:()=>{},destroy:()=>{this._reader.isDestroyed||this._reader.destroy()}})}read(){return this._reader.onError(e=>{this._stream.emit("error",e)}),this._reader.onEntry(e=>{this._stream.push(e)}),this._reader.onEnd(()=>{this._stream.push(null)}),this._reader.read(),this._stream}};Mu.default=Nu});var vm=$($u=>{"use strict";Object.defineProperty($u,"__esModule",{value:!0});var G1=Rs(),ks=Fs(),z1=ku(),ju=class extends z1.default{constructor(){super(...arguments),this._scandir=G1.scandirSync,this._storage=[],this._queue=new Set}read(){return this._pushToQueue(this._root,this._settings.basePath),this._handleQueue(),this._storage}_pushToQueue(e,r){this._queue.add({directory:e,base:r})}_handleQueue(){for(let e of this._queue.values())this._handleDirectory(e.directory,e.base)}_handleDirectory(e,r){try{let i=this._scandir(e,this._settings.fsScandirSettings);for(let n of i)this._handleEntry(n,r)}catch(i){this._handleError(i)}}_handleError(e){if(ks.isFatalError(this._settings,e))throw e}_handleEntry(e,r){let i=e.path;r!==void 0&&(e.path=ks.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),ks.isAppliedFilter(this._settings.entryFilter,e)&&this._pushToStorage(e),e.dirent.isDirectory()&&ks.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,r===void 0?void 0:e.path)}_pushToStorage(e){this._storage.push(e)}};$u.default=ju});var Cm=$(qu=>{"use strict";Object.defineProperty(qu,"__esModule",{value:!0});var W1=vm(),Hu=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new W1.default(this._root,this._settings)}read(){return this._reader.read()}};qu.default=Hu});var xm=$(Gu=>{"use strict";Object.defineProperty(Gu,"__esModule",{value:!0});var Y1=require("path"),V1=Rs(),Uu=class{constructor(e={}){this._options=e,this.basePath=this._getValue(this._options.basePath,void 0),this.concurrency=this._getValue(this._options.concurrency,Number.POSITIVE_INFINITY),this.deepFilter=this._getValue(this._options.deepFilter,null),this.entryFilter=this._getValue(this._options.entryFilter,null),this.errorFilter=this._getValue(this._options.errorFilter,null),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,Y1.sep),this.fsScandirSettings=new V1.Settings({followSymbolicLinks:this._options.followSymbolicLinks,fs:this._options.fs,pathSegmentSeparator:this._options.pathSegmentSeparator,stats:this._options.stats,throwErrorOnBrokenSymbolicLink:this._options.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};Gu.default=Uu});var Ls=$(St=>{"use strict";Object.defineProperty(St,"__esModule",{value:!0});St.Settings=St.walkStream=St.walkSync=St.walk=void 0;var Rm=Sm(),K1=Am(),Z1=Cm(),zu=xm();St.Settings=zu.default;function J1(t,e,r){if(typeof e=="function"){new Rm.default(t,Ts()).read(e);return}new Rm.default(t,Ts(e)).read(r)}St.walk=J1;function X1(t,e){let r=Ts(e);return new Z1.default(t,r).read()}St.walkSync=X1;function Q1(t,e){let r=Ts(e);return new K1.default(t,r).read()}St.walkStream=Q1;function Ts(t={}){return t instanceof zu.default?t:new zu.default(t)}});var Bs=$(Yu=>{"use strict";Object.defineProperty(Yu,"__esModule",{value:!0});var eC=require("path"),tC=Mr(),Fm=$t(),Wu=class{constructor(e){this._settings=e,this._fsStatSettings=new tC.Settings({followSymbolicLink:this._settings.followSymbolicLinks,fs:this._settings.fs,throwErrorOnBrokenSymbolicLink:this._settings.followSymbolicLinks})}_getFullEntryPath(e){return eC.resolve(this._settings.cwd,e)}_makeEntry(e,r){let i={name:r,path:r,dirent:Fm.fs.createDirentFromStats(r,e)};return this._settings.stats&&(i.stats=e),i}_isFatalError(e){return!Fm.errno.isEnoentCodeError(e)&&!this._settings.suppressErrors}};Yu.default=Wu});var Zu=$(Ku=>{"use strict";Object.defineProperty(Ku,"__esModule",{value:!0});var rC=require("stream"),iC=Mr(),nC=Ls(),sC=Bs(),Vu=class extends sC.default{constructor(){super(...arguments),this._walkStream=nC.walkStream,this._stat=iC.stat}dynamic(e,r){return this._walkStream(e,r)}static(e,r){let i=e.map(this._getFullEntryPath,this),n=new rC.PassThrough({objectMode:!0});n._write=(s,o,a)=>this._getEntry(i[s],e[s],r).then(u=>{u!==null&&r.entryFilter(u)&&n.push(u),s===i.length-1&&n.end(),a()}).catch(a);for(let s=0;s<i.length;s++)n.write(s);return n}_getEntry(e,r,i){return this._getStat(e).then(n=>this._makeEntry(n,r)).catch(n=>{if(i.errorFilter(n))return null;throw n})}_getStat(e){return new Promise((r,i)=>{this._stat(e,this._fsStatSettings,(n,s)=>n===null?r(s):i(n))})}};Ku.default=Vu});var Om=$(Xu=>{"use strict";Object.defineProperty(Xu,"__esModule",{value:!0});var oC=Ls(),aC=Bs(),uC=Zu(),Ju=class extends aC.default{constructor(){super(...arguments),this._walkAsync=oC.walk,this._readerStream=new uC.default(this._settings)}dynamic(e,r){return new Promise((i,n)=>{this._walkAsync(e,r,(s,o)=>{s===null?i(o):n(s)})})}async static(e,r){let i=[],n=this._readerStream.static(e,r);return new Promise((s,o)=>{n.once("error",o),n.on("data",a=>i.push(a)),n.once("end",()=>s(i))})}};Xu.default=Ju});var km=$(el=>{"use strict";Object.defineProperty(el,"__esModule",{value:!0});var Ei=$t(),Qu=class{constructor(e,r,i){this._patterns=e,this._settings=r,this._micromatchOptions=i,this._storage=[],this._fillStorage()}_fillStorage(){let e=Ei.pattern.expandPatternsWithBraceExpansion(this._patterns);for(let r of e){let i=this._getPatternSegments(r),n=this._splitSegmentsIntoSections(i);this._storage.push({complete:n.length<=1,pattern:r,segments:i,sections:n})}}_getPatternSegments(e){return Ei.pattern.getPatternParts(e,this._micromatchOptions).map(i=>Ei.pattern.isDynamicPattern(i,this._settings)?{dynamic:!0,pattern:i,patternRe:Ei.pattern.makeRe(i,this._micromatchOptions)}:{dynamic:!1,pattern:i})}_splitSegmentsIntoSections(e){return Ei.array.splitWhen(e,r=>r.dynamic&&Ei.pattern.hasGlobStar(r.pattern))}};el.default=Qu});var Tm=$(rl=>{"use strict";Object.defineProperty(rl,"__esModule",{value:!0});var lC=km(),tl=class extends lC.default{match(e){let r=e.split("/"),i=r.length,n=this._storage.filter(s=>!s.complete||s.segments.length>i);for(let s of n){let o=s.sections[0];if(!s.complete&&i>o.length||r.every((u,l)=>{let c=s.segments[l];return!!(c.dynamic&&c.patternRe.test(u)||!c.dynamic&&c.pattern===u)}))return!0}return!1}};rl.default=tl});var Lm=$(nl=>{"use strict";Object.defineProperty(nl,"__esModule",{value:!0});var Ps=$t(),cC=Tm(),il=class{constructor(e,r){this._settings=e,this._micromatchOptions=r}getFilter(e,r,i){let n=this._getMatcher(r),s=this._getNegativePatternsRe(i);return o=>this._filter(e,o,n,s)}_getMatcher(e){return new cC.default(e,this._settings,this._micromatchOptions)}_getNegativePatternsRe(e){let r=e.filter(Ps.pattern.isAffectDepthOfReadingPattern);return Ps.pattern.convertPatternsToRe(r,this._micromatchOptions)}_filter(e,r,i,n){if(this._isSkippedByDeep(e,r.path)||this._isSkippedSymbolicLink(r))return!1;let s=Ps.path.removeLeadingDotSegment(r.path);return this._isSkippedByPositivePatterns(s,i)?!1:this._isSkippedByNegativePatterns(s,n)}_isSkippedByDeep(e,r){return this._settings.deep===1/0?!1:this._getEntryLevel(e,r)>=this._settings.deep}_getEntryLevel(e,r){let i=r.split("/").length;if(e==="")return i;let n=e.split("/").length;return i-n}_isSkippedSymbolicLink(e){return!this._settings.followSymbolicLinks&&e.dirent.isSymbolicLink()}_isSkippedByPositivePatterns(e,r){return!this._settings.baseNameMatch&&!r.match(e)}_isSkippedByNegativePatterns(e,r){return!Ps.pattern.matchAny(e,r)}};nl.default=il});var Bm=$(ol=>{"use strict";Object.defineProperty(ol,"__esModule",{value:!0});var jr=$t(),sl=class{constructor(e,r){this._settings=e,this._micromatchOptions=r,this.index=new Map}getFilter(e,r){let i=jr.pattern.convertPatternsToRe(e,this._micromatchOptions),n=jr.pattern.convertPatternsToRe(r,this._micromatchOptions);return s=>this._filter(s,i,n)}_filter(e,r,i){if(this._settings.unique&&this._isDuplicateEntry(e)||this._onlyFileFilter(e)||this._onlyDirectoryFilter(e)||this._isSkippedByAbsoluteNegativePatterns(e.path,i))return!1;let n=this._settings.baseNameMatch?e.name:e.path,s=e.dirent.isDirectory(),o=this._isMatchToPatterns(n,r,s)&&!this._isMatchToPatterns(e.path,i,s);return this._settings.unique&&o&&this._createIndexRecord(e),o}_isDuplicateEntry(e){return this.index.has(e.path)}_createIndexRecord(e){this.index.set(e.path,void 0)}_onlyFileFilter(e){return this._settings.onlyFiles&&!e.dirent.isFile()}_onlyDirectoryFilter(e){return this._settings.onlyDirectories&&!e.dirent.isDirectory()}_isSkippedByAbsoluteNegativePatterns(e,r){if(!this._settings.absolute)return!1;let i=jr.path.makeAbsolute(this._settings.cwd,e);return jr.pattern.matchAny(i,r)}_isMatchToPatterns(e,r,i){let n=jr.path.removeLeadingDotSegment(e),s=jr.pattern.matchAny(n,r);return!s&&i?jr.pattern.matchAny(n+"/",r):s}};ol.default=sl});var Pm=$(ul=>{"use strict";Object.defineProperty(ul,"__esModule",{value:!0});var hC=$t(),al=class{constructor(e){this._settings=e}getFilter(){return e=>this._isNonFatalError(e)}_isNonFatalError(e){return hC.errno.isEnoentCodeError(e)||this._settings.suppressErrors}};ul.default=al});var Nm=$(cl=>{"use strict";Object.defineProperty(cl,"__esModule",{value:!0});var Im=$t(),ll=class{constructor(e){this._settings=e}getTransformer(){return e=>this._transform(e)}_transform(e){let r=e.path;return this._settings.absolute&&(r=Im.path.makeAbsolute(this._settings.cwd,r),r=Im.path.unixify(r)),this._settings.markDirectories&&e.dirent.isDirectory()&&(r+="/"),this._settings.objectMode?Object.assign(Object.assign({},e),{path:r}):r}};cl.default=ll});var Is=$(fl=>{"use strict";Object.defineProperty(fl,"__esModule",{value:!0});var fC=require("path"),pC=Lm(),dC=Bm(),mC=Pm(),gC=Nm(),hl=class{constructor(e){this._settings=e,this.errorFilter=new mC.default(this._settings),this.entryFilter=new dC.default(this._settings,this._getMicromatchOptions()),this.deepFilter=new pC.default(this._settings,this._getMicromatchOptions()),this.entryTransformer=new gC.default(this._settings)}_getRootDirectory(e){return fC.resolve(this._settings.cwd,e.base)}_getReaderOptions(e){let r=e.base==="."?"":e.base;return{basePath:r,pathSegmentSeparator:"/",concurrency:this._settings.concurrency,deepFilter:this.deepFilter.getFilter(r,e.positive,e.negative),entryFilter:this.entryFilter.getFilter(e.positive,e.negative),errorFilter:this.errorFilter.getFilter(),followSymbolicLinks:this._settings.followSymbolicLinks,fs:this._settings.fs,stats:this._settings.stats,throwErrorOnBrokenSymbolicLink:this._settings.throwErrorOnBrokenSymbolicLink,transform:this.entryTransformer.getTransformer()}}_getMicromatchOptions(){return{dot:this._settings.dot,matchBase:this._settings.baseNameMatch,nobrace:!this._settings.braceExpansion,nocase:!this._settings.caseSensitiveMatch,noext:!this._settings.extglob,noglobstar:!this._settings.globstar,posix:!0,strictSlashes:!1}}};fl.default=hl});var Mm=$(dl=>{"use strict";Object.defineProperty(dl,"__esModule",{value:!0});var yC=Om(),EC=Is(),pl=class extends EC.default{constructor(){super(...arguments),this._reader=new yC.default(this._settings)}async read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e);return(await this.api(r,e,i)).map(s=>i.transform(s))}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};dl.default=pl});var jm=$(gl=>{"use strict";Object.defineProperty(gl,"__esModule",{value:!0});var DC=require("stream"),bC=Zu(),_C=Is(),ml=class extends _C.default{constructor(){super(...arguments),this._reader=new bC.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e),n=this.api(r,e,i),s=new DC.Readable({objectMode:!0,read:()=>{}});return n.once("error",o=>s.emit("error",o)).on("data",o=>s.emit("data",i.transform(o))).once("end",()=>s.emit("end")),s.once("close",()=>n.destroy()),s}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};gl.default=ml});var $m=$(El=>{"use strict";Object.defineProperty(El,"__esModule",{value:!0});var wC=Mr(),SC=Ls(),AC=Bs(),yl=class extends AC.default{constructor(){super(...arguments),this._walkSync=SC.walkSync,this._statSync=wC.statSync}dynamic(e,r){return this._walkSync(e,r)}static(e,r){let i=[];for(let n of e){let s=this._getFullEntryPath(n),o=this._getEntry(s,n,r);o===null||!r.entryFilter(o)||i.push(o)}return i}_getEntry(e,r,i){try{let n=this._getStat(e);return this._makeEntry(n,r)}catch(n){if(i.errorFilter(n))return null;throw n}}_getStat(e){return this._statSync(e,this._fsStatSettings)}};El.default=yl});var Hm=$(bl=>{"use strict";Object.defineProperty(bl,"__esModule",{value:!0});var vC=$m(),CC=Is(),Dl=class extends CC.default{constructor(){super(...arguments),this._reader=new vC.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e);return this.api(r,e,i).map(i.transform)}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};bl.default=Dl});var qm=$(bi=>{"use strict";Object.defineProperty(bi,"__esModule",{value:!0});bi.DEFAULT_FILE_SYSTEM_ADAPTER=void 0;var Di=require("fs"),xC=require("os"),RC=Math.max(xC.cpus().length,1);bi.DEFAULT_FILE_SYSTEM_ADAPTER={lstat:Di.lstat,lstatSync:Di.lstatSync,stat:Di.stat,statSync:Di.statSync,readdir:Di.readdir,readdirSync:Di.readdirSync};var _l=class{constructor(e={}){this._options=e,this.absolute=this._getValue(this._options.absolute,!1),this.baseNameMatch=this._getValue(this._options.baseNameMatch,!1),this.braceExpansion=this._getValue(this._options.braceExpansion,!0),this.caseSensitiveMatch=this._getValue(this._options.caseSensitiveMatch,!0),this.concurrency=this._getValue(this._options.concurrency,RC),this.cwd=this._getValue(this._options.cwd,process.cwd()),this.deep=this._getValue(this._options.deep,1/0),this.dot=this._getValue(this._options.dot,!1),this.extglob=this._getValue(this._options.extglob,!0),this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!0),this.fs=this._getFileSystemMethods(this._options.fs),this.globstar=this._getValue(this._options.globstar,!0),this.ignore=this._getValue(this._options.ignore,[]),this.markDirectories=this._getValue(this._options.markDirectories,!1),this.objectMode=this._getValue(this._options.objectMode,!1),this.onlyDirectories=this._getValue(this._options.onlyDirectories,!1),this.onlyFiles=this._getValue(this._options.onlyFiles,!0),this.stats=this._getValue(this._options.stats,!1),this.suppressErrors=this._getValue(this._options.suppressErrors,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!1),this.unique=this._getValue(this._options.unique,!0),this.onlyDirectories&&(this.onlyFiles=!1),this.stats&&(this.objectMode=!0)}_getValue(e,r){return e===void 0?r:e}_getFileSystemMethods(e={}){return Object.assign(Object.assign({},bi.DEFAULT_FILE_SYSTEM_ADAPTER),e)}};bi.default=_l});var Ns=$((IP,zm)=>{"use strict";var Um=qd(),Gm=Gd(),FC=Mm(),OC=jm(),kC=Hm(),wl=qm(),$r=$t();async function Sl(t,e){_i(t);let r=Al(t,FC.default,e),i=await Promise.all(r);return $r.array.flatten(i)}(function(t){function e(o,a){_i(o);let u=Al(o,kC.default,a);return $r.array.flatten(u)}t.sync=e;function r(o,a){_i(o);let u=Al(o,OC.default,a);return $r.stream.merge(u)}t.stream=r;function i(o,a){_i(o);let u=Gm.transform([].concat(o)),l=new wl.default(a);return Um.generate(u,l)}t.generateTasks=i;function n(o,a){_i(o);let u=new wl.default(a);return $r.pattern.isDynamicPattern(o,u)}t.isDynamicPattern=n;function s(o){return _i(o),$r.path.escape(o)}t.escapePath=s})(Sl||(Sl={}));function Al(t,e,r){let i=Gm.transform([].concat(t)),n=new wl.default(r),s=Um.generate(i,n),o=new e(n);return s.map(o.read,o)}function _i(t){if(![].concat(t).every(i=>$r.string.isString(i)&&!$r.string.isEmpty(i)))throw new TypeError("Patterns must be a string (non empty) or an array of strings")}zm.exports=Sl});var s0=$((HP,n0)=>{n0.exports=i0;i0.sync=zC;var t0=require("fs");function GC(t,e){var r=e.pathExt!==void 0?e.pathExt:process.env.PATHEXT;if(!r||(r=r.split(";"),r.indexOf("")!==-1))return!0;for(var i=0;i<r.length;i++){var n=r[i].toLowerCase();if(n&&t.substr(-n.length).toLowerCase()===n)return!0}return!1}function r0(t,e,r){return!t.isSymbolicLink()&&!t.isFile()?!1:GC(e,r)}function i0(t,e,r){t0.stat(t,function(i,n){r(i,i?!1:r0(n,t,e))})}function zC(t,e){return r0(t0.statSync(t),t,e)}});var c0=$((qP,l0)=>{l0.exports=a0;a0.sync=WC;var o0=require("fs");function a0(t,e,r){o0.stat(t,function(i,n){r(i,i?!1:u0(n,e))})}function WC(t,e){return u0(o0.statSync(t),e)}function u0(t,e){return t.isFile()&&YC(t,e)}function YC(t,e){var r=t.mode,i=t.uid,n=t.gid,s=e.uid!==void 0?e.uid:process.getuid&&process.getuid(),o=e.gid!==void 0?e.gid:process.getgid&&process.getgid(),a=parseInt("100",8),u=parseInt("010",8),l=parseInt("001",8),c=a|u,f=r&l||r&u&&n===o||r&a&&i===s||r&c&&s===0;return f}});var f0=$((GP,h0)=>{var UP=require("fs"),Ms;process.platform==="win32"||global.TESTING_WINDOWS?Ms=s0():Ms=c0();h0.exports=vl;vl.sync=VC;function vl(t,e,r){if(typeof e=="function"&&(r=e,e={}),!r){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(i,n){vl(t,e||{},function(s,o){s?n(s):i(o)})})}Ms(t,e||{},function(i,n){i&&(i.code==="EACCES"||e&&e.ignoreErrors)&&(i=null,n=!1),r(i,n)})}function VC(t,e){try{return Ms.sync(t,e||{})}catch(r){if(e&&e.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var D0=$((zP,E0)=>{var Si=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",p0=require("path"),KC=Si?";":":",d0=f0(),m0=t=>Object.assign(new Error(`not found: ${t}`),{code:"ENOENT"}),g0=(t,e)=>{let r=e.colon||KC,i=t.match(/\//)||Si&&t.match(/\\/)?[""]:[...Si?[process.cwd()]:[],...(e.path||process.env.PATH||"").split(r)],n=Si?e.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",s=Si?n.split(r):[""];return Si&&t.indexOf(".")!==-1&&s[0]!==""&&s.unshift(""),{pathEnv:i,pathExt:s,pathExtExe:n}},y0=(t,e,r)=>{typeof e=="function"&&(r=e,e={}),e||(e={});let{pathEnv:i,pathExt:n,pathExtExe:s}=g0(t,e),o=[],a=l=>new Promise((c,f)=>{if(l===i.length)return e.all&&o.length?c(o):f(m0(t));let h=i[l],p=/^".*"$/.test(h)?h.slice(1,-1):h,g=p0.join(p,t),y=!p&&/^\.[\\\/]/.test(t)?t.slice(0,2)+g:g;c(u(y,l,0))}),u=(l,c,f)=>new Promise((h,p)=>{if(f===n.length)return h(a(c+1));let g=n[f];d0(l+g,{pathExt:s},(y,E)=>{if(!y&&E)if(e.all)o.push(l+g);else return h(l+g);return h(u(l,c,f+1))})});return r?a(0).then(l=>r(null,l),r):a(0)},ZC=(t,e)=>{e=e||{};let{pathEnv:r,pathExt:i,pathExtExe:n}=g0(t,e),s=[];for(let o=0;o<r.length;o++){let a=r[o],u=/^".*"$/.test(a)?a.slice(1,-1):a,l=p0.join(u,t),c=!u&&/^\.[\\\/]/.test(t)?t.slice(0,2)+l:l;for(let f=0;f<i.length;f++){let h=c+i[f];try{if(d0.sync(h,{pathExt:n}))if(e.all)s.push(h);else return h}catch{}}}if(e.all&&s.length)return s;if(e.nothrow)return null;throw m0(t)};E0.exports=y0;y0.sync=ZC});var xl=$((WP,Cl)=>{"use strict";var b0=(t={})=>{let e=t.env||process.env;return(t.platform||process.platform)!=="win32"?"PATH":Object.keys(e).reverse().find(i=>i.toUpperCase()==="PATH")||"Path"};Cl.exports=b0;Cl.exports.default=b0});var A0=$((YP,S0)=>{"use strict";var _0=require("path"),JC=D0(),XC=xl();function w0(t,e){let r=t.options.env||process.env,i=process.cwd(),n=t.options.cwd!=null,s=n&&process.chdir!==void 0&&!process.chdir.disabled;if(s)try{process.chdir(t.options.cwd)}catch{}let o;try{o=JC.sync(t.command,{path:r[XC({env:r})],pathExt:e?_0.delimiter:void 0})}catch{}finally{s&&process.chdir(i)}return o&&(o=_0.resolve(n?t.options.cwd:"",o)),o}function QC(t){return w0(t)||w0(t,!0)}S0.exports=QC});var v0=$((VP,Fl)=>{"use strict";var Rl=/([()\][%!^"`<>&|;, *?])/g;function ex(t){return t=t.replace(Rl,"^$1"),t}function tx(t,e){return t=`${t}`,t=t.replace(/(\\*)"/g,'$1$1\\"'),t=t.replace(/(\\*)$/,"$1$1"),t=`"${t}"`,t=t.replace(Rl,"^$1"),e&&(t=t.replace(Rl,"^$1")),t}Fl.exports.command=ex;Fl.exports.argument=tx});var x0=$((KP,C0)=>{"use strict";C0.exports=/^#!(.*)/});var F0=$((ZP,R0)=>{"use strict";var rx=x0();R0.exports=(t="")=>{let e=t.match(rx);if(!e)return null;let[r,i]=e[0].replace(/#! ?/,"").split(" "),n=r.split("/").pop();return n==="env"?i:i?`${n} ${i}`:n}});var k0=$((JP,O0)=>{"use strict";var Ol=require("fs"),ix=F0();function nx(t){let r=Buffer.alloc(150),i;try{i=Ol.openSync(t,"r"),Ol.readSync(i,r,0,150,0),Ol.closeSync(i)}catch{}return ix(r.toString())}O0.exports=nx});var P0=$((XP,B0)=>{"use strict";var sx=require("path"),T0=A0(),L0=v0(),ox=k0(),ax=process.platform==="win32",ux=/\.(?:com|exe)$/i,lx=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function cx(t){t.file=T0(t);let e=t.file&&ox(t.file);return e?(t.args.unshift(t.file),t.command=e,T0(t)):t.file}function hx(t){if(!ax)return t;let e=cx(t),r=!ux.test(e);if(t.options.forceShell||r){let i=lx.test(e);t.command=sx.normalize(t.command),t.command=L0.command(t.command),t.args=t.args.map(s=>L0.argument(s,i));let n=[t.command].concat(t.args).join(" ");t.args=["/d","/s","/c",`"${n}"`],t.command=process.env.comspec||"cmd.exe",t.options.windowsVerbatimArguments=!0}return t}function fx(t,e,r){e&&!Array.isArray(e)&&(r=e,e=null),e=e?e.slice(0):[],r=Object.assign({},r);let i={command:t,args:e,options:r,file:void 0,original:{command:t,args:e}};return r.shell?i:hx(i)}B0.exports=fx});var M0=$((QP,N0)=>{"use strict";var kl=process.platform==="win32";function Tl(t,e){return Object.assign(new Error(`${e} ${t.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${e} ${t.command}`,path:t.command,spawnargs:t.args})}function px(t,e){if(!kl)return;let r=t.emit;t.emit=function(i,n){if(i==="exit"){let s=I0(n,e,"spawn");if(s)return r.call(t,"error",s)}return r.apply(t,arguments)}}function I0(t,e){return kl&&t===1&&!e.file?Tl(e.original,"spawn"):null}function dx(t,e){return kl&&t===1&&!e.file?Tl(e.original,"spawnSync"):null}N0.exports={hookChildProcess:px,verifyENOENT:I0,verifyENOENTSync:dx,notFoundError:Tl}});var H0=$((e2,Ai)=>{"use strict";var j0=require("child_process"),Ll=P0(),Bl=M0();function $0(t,e,r){let i=Ll(t,e,r),n=j0.spawn(i.command,i.args,i.options);return Bl.hookChildProcess(n,i),n}function mx(t,e,r){let i=Ll(t,e,r),n=j0.spawnSync(i.command,i.args,i.options);return n.error=n.error||Bl.verifyENOENTSync(n.status,i),n}Ai.exports=$0;Ai.exports.spawn=$0;Ai.exports.sync=mx;Ai.exports._parse=Ll;Ai.exports._enoent=Bl});var U0=$((t2,q0)=>{"use strict";q0.exports=t=>{let e=typeof t=="string"?`
2
+ "use strict";var Jb=Object.create;var _a=Object.defineProperty;var Xb=Object.getOwnPropertyDescriptor;var Qb=Object.getOwnPropertyNames;var e_=Object.getPrototypeOf,t_=Object.prototype.hasOwnProperty;var $=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),r_=(t,e)=>{for(var r in e)_a(t,r,{get:e[r],enumerable:!0})},i_=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of Qb(e))!t_.call(t,n)&&n!==r&&_a(t,n,{get:()=>e[n],enumerable:!(i=Xb(e,n))||i.enumerable});return t};var J=(t,e,r)=>(r=t!=null?Jb(e_(t)):{},i_(e||!t||!t.__esModule?_a(r,"default",{value:t,enumerable:!0}):r,t));var Zh=$((OL,Pt)=>{function wa(t){return Pt.exports=wa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Pt.exports.__esModule=!0,Pt.exports.default=Pt.exports,wa(t)}Pt.exports=wa,Pt.exports.__esModule=!0,Pt.exports.default=Pt.exports});var Qh=$((kL,It)=>{var Jh=Zh().default;function Xh(){"use strict";It.exports=Xh=function(){return e},It.exports.__esModule=!0,It.exports.default=It.exports;var t,e={},r=Object.prototype,i=r.hasOwnProperty,n=Object.defineProperty||function(C,k,j){C[k]=j.value},s=typeof Symbol=="function"?Symbol:{},o=s.iterator||"@@iterator",a=s.asyncIterator||"@@asyncIterator",u=s.toStringTag||"@@toStringTag";function l(C,k,j){return Object.defineProperty(C,k,{value:j,enumerable:!0,configurable:!0,writable:!0}),C[k]}try{l({},"")}catch{l=function(j,z,P){return j[z]=P}}function c(C,k,j,z){var P=k&&k.prototype instanceof v?k:v,d=Object.create(P.prototype),m=new K(z||[]);return n(d,"_invoke",{value:H(C,j,m)}),d}function f(C,k,j){try{return{type:"normal",arg:C.call(k,j)}}catch(z){return{type:"throw",arg:z}}}e.wrap=c;var h="suspendedStart",p="suspendedYield",g="executing",y="completed",E={};function v(){}function F(){}function O(){}var R={};l(R,o,function(){return this});var x=Object.getPrototypeOf,L=x&&x(x(B([])));L&&L!==r&&i.call(L,o)&&(R=L);var b=O.prototype=v.prototype=Object.create(R);function S(C){["next","throw","return"].forEach(function(k){l(C,k,function(j){return this._invoke(k,j)})})}function N(C,k){function j(P,d,m,D){var A=f(C[P],C,d);if(A.type!=="throw"){var w=A.arg,I=w.value;return I&&Jh(I)=="object"&&i.call(I,"__await")?k.resolve(I.__await).then(function(M){j("next",M,m,D)},function(M){j("throw",M,m,D)}):k.resolve(I).then(function(M){w.value=M,m(w)},function(M){return j("throw",M,m,D)})}D(A.arg)}var z;n(this,"_invoke",{value:function(d,m){function D(){return new k(function(A,w){j(d,m,A,w)})}return z=z?z.then(D,D):D()}})}function H(C,k,j){var z=h;return function(P,d){if(z===g)throw new Error("Generator is already running");if(z===y){if(P==="throw")throw d;return{value:t,done:!0}}for(j.method=P,j.arg=d;;){var m=j.delegate;if(m){var D=T(m,j);if(D){if(D===E)continue;return D}}if(j.method==="next")j.sent=j._sent=j.arg;else if(j.method==="throw"){if(z===h)throw z=y,j.arg;j.dispatchException(j.arg)}else j.method==="return"&&j.abrupt("return",j.arg);z=g;var A=f(C,k,j);if(A.type==="normal"){if(z=j.done?y:p,A.arg===E)continue;return{value:A.arg,done:j.done}}A.type==="throw"&&(z=y,j.method="throw",j.arg=A.arg)}}}function T(C,k){var j=k.method,z=C.iterator[j];if(z===t)return k.delegate=null,j==="throw"&&C.iterator.return&&(k.method="return",k.arg=t,T(C,k),k.method==="throw")||j!=="return"&&(k.method="throw",k.arg=new TypeError("The iterator does not provide a '"+j+"' method")),E;var P=f(z,C.iterator,k.arg);if(P.type==="throw")return k.method="throw",k.arg=P.arg,k.delegate=null,E;var d=P.arg;return d?d.done?(k[C.resultName]=d.value,k.next=C.nextLoc,k.method!=="return"&&(k.method="next",k.arg=t),k.delegate=null,E):d:(k.method="throw",k.arg=new TypeError("iterator result is not an object"),k.delegate=null,E)}function U(C){var k={tryLoc:C[0]};1 in C&&(k.catchLoc=C[1]),2 in C&&(k.finallyLoc=C[2],k.afterLoc=C[3]),this.tryEntries.push(k)}function V(C){var k=C.completion||{};k.type="normal",delete k.arg,C.completion=k}function K(C){this.tryEntries=[{tryLoc:"root"}],C.forEach(U,this),this.reset(!0)}function B(C){if(C||C===""){var k=C[o];if(k)return k.call(C);if(typeof C.next=="function")return C;if(!isNaN(C.length)){var j=-1,z=function P(){for(;++j<C.length;)if(i.call(C,j))return P.value=C[j],P.done=!1,P;return P.value=t,P.done=!0,P};return z.next=z}}throw new TypeError(Jh(C)+" is not iterable")}return F.prototype=O,n(b,"constructor",{value:O,configurable:!0}),n(O,"constructor",{value:F,configurable:!0}),F.displayName=l(O,u,"GeneratorFunction"),e.isGeneratorFunction=function(C){var k=typeof C=="function"&&C.constructor;return!!k&&(k===F||(k.displayName||k.name)==="GeneratorFunction")},e.mark=function(C){return Object.setPrototypeOf?Object.setPrototypeOf(C,O):(C.__proto__=O,l(C,u,"GeneratorFunction")),C.prototype=Object.create(b),C},e.awrap=function(C){return{__await:C}},S(N.prototype),l(N.prototype,a,function(){return this}),e.AsyncIterator=N,e.async=function(C,k,j,z,P){P===void 0&&(P=Promise);var d=new N(c(C,k,j,z),P);return e.isGeneratorFunction(k)?d:d.next().then(function(m){return m.done?m.value:d.next()})},S(b),l(b,u,"Generator"),l(b,o,function(){return this}),l(b,"toString",function(){return"[object Generator]"}),e.keys=function(C){var k=Object(C),j=[];for(var z in k)j.push(z);return j.reverse(),function P(){for(;j.length;){var d=j.pop();if(d in k)return P.value=d,P.done=!1,P}return P.done=!0,P}},e.values=B,K.prototype={constructor:K,reset:function(k){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(V),!k)for(var j in this)j.charAt(0)==="t"&&i.call(this,j)&&!isNaN(+j.slice(1))&&(this[j]=t)},stop:function(){this.done=!0;var k=this.tryEntries[0].completion;if(k.type==="throw")throw k.arg;return this.rval},dispatchException:function(k){if(this.done)throw k;var j=this;function z(w,I){return m.type="throw",m.arg=k,j.next=w,I&&(j.method="next",j.arg=t),!!I}for(var P=this.tryEntries.length-1;P>=0;--P){var d=this.tryEntries[P],m=d.completion;if(d.tryLoc==="root")return z("end");if(d.tryLoc<=this.prev){var D=i.call(d,"catchLoc"),A=i.call(d,"finallyLoc");if(D&&A){if(this.prev<d.catchLoc)return z(d.catchLoc,!0);if(this.prev<d.finallyLoc)return z(d.finallyLoc)}else if(D){if(this.prev<d.catchLoc)return z(d.catchLoc,!0)}else{if(!A)throw new Error("try statement without catch or finally");if(this.prev<d.finallyLoc)return z(d.finallyLoc)}}}},abrupt:function(k,j){for(var z=this.tryEntries.length-1;z>=0;--z){var P=this.tryEntries[z];if(P.tryLoc<=this.prev&&i.call(P,"finallyLoc")&&this.prev<P.finallyLoc){var d=P;break}}d&&(k==="break"||k==="continue")&&d.tryLoc<=j&&j<=d.finallyLoc&&(d=null);var m=d?d.completion:{};return m.type=k,m.arg=j,d?(this.method="next",this.next=d.finallyLoc,E):this.complete(m)},complete:function(k,j){if(k.type==="throw")throw k.arg;return k.type==="break"||k.type==="continue"?this.next=k.arg:k.type==="return"?(this.rval=this.arg=k.arg,this.method="return",this.next="end"):k.type==="normal"&&j&&(this.next=j),E},finish:function(k){for(var j=this.tryEntries.length-1;j>=0;--j){var z=this.tryEntries[j];if(z.finallyLoc===k)return this.complete(z.completion,z.afterLoc),V(z),E}},catch:function(k){for(var j=this.tryEntries.length-1;j>=0;--j){var z=this.tryEntries[j];if(z.tryLoc===k){var P=z.completion;if(P.type==="throw"){var d=P.arg;V(z)}return d}}throw new Error("illegal catch attempt")},delegateYield:function(k,j,z){return this.delegate={iterator:B(k),resultName:j,nextLoc:z},this.method==="next"&&(this.arg=t),E}},e}It.exports=Xh,It.exports.__esModule=!0,It.exports.default=It.exports});var tf=$((TL,ef)=>{var rs=Qh()();ef.exports=rs;try{regeneratorRuntime=rs}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=rs:Function("r","regeneratorRuntime = r")(rs)}});var op=$(fi=>{"use strict";Object.defineProperty(fi,"__esModule",{value:!0});fi.splitWhen=fi.flatten=void 0;function OS(t){return t.reduce((e,r)=>[].concat(e,r),[])}fi.flatten=OS;function kS(t,e){let r=[[]],i=0;for(let n of t)e(n)?(i++,r[i]=[]):r[i].push(n);return r}fi.splitWhen=kS});var ap=$(ls=>{"use strict";Object.defineProperty(ls,"__esModule",{value:!0});ls.isEnoentCodeError=void 0;function TS(t){return t.code==="ENOENT"}ls.isEnoentCodeError=TS});var up=$(cs=>{"use strict";Object.defineProperty(cs,"__esModule",{value:!0});cs.createDirentFromStats=void 0;var Ga=class{constructor(e,r){this.name=e,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function LS(t,e){return new Ga(t,e)}cs.createDirentFromStats=LS});var lp=$(Dt=>{"use strict";Object.defineProperty(Dt,"__esModule",{value:!0});Dt.removeLeadingDotSegment=Dt.escape=Dt.makeAbsolute=Dt.unixify=void 0;var BS=require("path"),PS=2,IS=/(\\?)([()*?[\]{|}]|^!|[!+@](?=\())/g;function NS(t){return t.replace(/\\/g,"/")}Dt.unixify=NS;function MS(t,e){return BS.resolve(t,e)}Dt.makeAbsolute=MS;function jS(t){return t.replace(IS,"\\$2")}Dt.escape=jS;function $S(t){if(t.charAt(0)==="."){let e=t.charAt(1);if(e==="/"||e==="\\")return t.slice(PS)}return t}Dt.removeLeadingDotSegment=$S});var hp=$((_B,cp)=>{cp.exports=function(e){if(typeof e!="string"||e==="")return!1;for(var r;r=/(\\).|([@?!+*]\(.*\))/g.exec(e);){if(r[2])return!0;e=e.slice(r.index+r[0].length)}return!1}});var dp=$((wB,pp)=>{var HS=hp(),fp={"{":"}","(":")","[":"]"},qS=function(t){if(t[0]==="!")return!0;for(var e=0,r=-2,i=-2,n=-2,s=-2,o=-2;e<t.length;){if(t[e]==="*"||t[e+1]==="?"&&/[\].+)]/.test(t[e])||i!==-1&&t[e]==="["&&t[e+1]!=="]"&&(i<e&&(i=t.indexOf("]",e)),i>e&&(o===-1||o>i||(o=t.indexOf("\\",e),o===-1||o>i)))||n!==-1&&t[e]==="{"&&t[e+1]!=="}"&&(n=t.indexOf("}",e),n>e&&(o=t.indexOf("\\",e),o===-1||o>n))||s!==-1&&t[e]==="("&&t[e+1]==="?"&&/[:!=]/.test(t[e+2])&&t[e+3]!==")"&&(s=t.indexOf(")",e),s>e&&(o=t.indexOf("\\",e),o===-1||o>s))||r!==-1&&t[e]==="("&&t[e+1]!=="|"&&(r<e&&(r=t.indexOf("|",e)),r!==-1&&t[r+1]!==")"&&(s=t.indexOf(")",r),s>r&&(o=t.indexOf("\\",r),o===-1||o>s))))return!0;if(t[e]==="\\"){var a=t[e+1];e+=2;var u=fp[a];if(u){var l=t.indexOf(u,e);l!==-1&&(e=l+1)}if(t[e]==="!")return!0}else e++}return!1},US=function(t){if(t[0]==="!")return!0;for(var e=0;e<t.length;){if(/[*?{}()[\]]/.test(t[e]))return!0;if(t[e]==="\\"){var r=t[e+1];e+=2;var i=fp[r];if(i){var n=t.indexOf(i,e);n!==-1&&(e=n+1)}if(t[e]==="!")return!0}else e++}return!1};pp.exports=function(e,r){if(typeof e!="string"||e==="")return!1;if(HS(e))return!0;var i=qS;return r&&r.strict===!1&&(i=US),i(e)}});var gp=$((SB,mp)=>{"use strict";var GS=dp(),zS=require("path").posix.dirname,WS=require("os").platform()==="win32",za="/",YS=/\\/g,VS=/[\{\[].*[\}\]]$/,KS=/(^|[^\\])([\{\[]|\([^\)]+$)/,ZS=/\\([\!\*\?\|\[\]\(\)\{\}])/g;mp.exports=function(e,r){var i=Object.assign({flipBackslashes:!0},r);i.flipBackslashes&&WS&&e.indexOf(za)<0&&(e=e.replace(YS,za)),VS.test(e)&&(e+=za),e+="a";do e=zS(e);while(GS(e)||KS.test(e));return e.replace(ZS,"$1")}});var hs=$(it=>{"use strict";it.isInteger=t=>typeof t=="number"?Number.isInteger(t):typeof t=="string"&&t.trim()!==""?Number.isInteger(Number(t)):!1;it.find=(t,e)=>t.nodes.find(r=>r.type===e);it.exceedsLimit=(t,e,r=1,i)=>i===!1||!it.isInteger(t)||!it.isInteger(e)?!1:(Number(e)-Number(t))/Number(r)>=i;it.escapeNode=(t,e=0,r)=>{let i=t.nodes[e];i&&(r&&i.type===r||i.type==="open"||i.type==="close")&&i.escaped!==!0&&(i.value="\\"+i.value,i.escaped=!0)};it.encloseBrace=t=>t.type!=="brace"||t.commas>>0+t.ranges>>0?!1:(t.invalid=!0,!0);it.isInvalidBrace=t=>t.type!=="brace"?!1:t.invalid===!0||t.dollar?!0:!(t.commas>>0+t.ranges>>0)||t.open!==!0||t.close!==!0?(t.invalid=!0,!0):!1;it.isOpenOrClose=t=>t.type==="open"||t.type==="close"?!0:t.open===!0||t.close===!0;it.reduce=t=>t.reduce((e,r)=>(r.type==="text"&&e.push(r.value),r.type==="range"&&(r.type="text"),e),[]);it.flatten=(...t)=>{let e=[],r=i=>{for(let n=0;n<i.length;n++){let s=i[n];Array.isArray(s)?r(s,e):s!==void 0&&e.push(s)}return e};return r(t),e}});var fs=$((vB,Ep)=>{"use strict";var yp=hs();Ep.exports=(t,e={})=>{let r=(i,n={})=>{let s=e.escapeInvalid&&yp.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a="";if(i.value)return(s||o)&&yp.isOpenOrClose(i)?"\\"+i.value:i.value;if(i.value)return i.value;if(i.nodes)for(let u of i.nodes)a+=r(u);return a};return r(t)}});var bp=$((CB,Dp)=>{"use strict";Dp.exports=function(t){return typeof t=="number"?t-t===0:typeof t=="string"&&t.trim()!==""?Number.isFinite?Number.isFinite(+t):isFinite(+t):!1}});var Fp=$((xB,Rp)=>{"use strict";var _p=bp(),Nr=(t,e,r)=>{if(_p(t)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(e===void 0||t===e)return String(t);if(_p(e)===!1)throw new TypeError("toRegexRange: expected the second argument to be a number.");let i={relaxZeros:!0,...r};typeof i.strictZeros=="boolean"&&(i.relaxZeros=i.strictZeros===!1);let n=String(i.relaxZeros),s=String(i.shorthand),o=String(i.capture),a=String(i.wrap),u=t+":"+e+"="+n+s+o+a;if(Nr.cache.hasOwnProperty(u))return Nr.cache[u].result;let l=Math.min(t,e),c=Math.max(t,e);if(Math.abs(l-c)===1){let y=t+"|"+e;return i.capture?`(${y})`:i.wrap===!1?y:`(?:${y})`}let f=xp(t)||xp(e),h={min:t,max:e,a:l,b:c},p=[],g=[];if(f&&(h.isPadded=f,h.maxLen=String(h.max).length),l<0){let y=c<0?Math.abs(c):1;g=wp(y,Math.abs(l),h,i),l=h.a=0}return c>=0&&(p=wp(l,c,h,i)),h.negatives=g,h.positives=p,h.result=JS(g,p,i),i.capture===!0?h.result=`(${h.result})`:i.wrap!==!1&&p.length+g.length>1&&(h.result=`(?:${h.result})`),Nr.cache[u]=h,h.result};function JS(t,e,r){let i=Wa(t,e,"-",!1,r)||[],n=Wa(e,t,"",!1,r)||[],s=Wa(t,e,"-?",!0,r)||[];return i.concat(s).concat(n).join("|")}function XS(t,e){let r=1,i=1,n=Ap(t,r),s=new Set([e]);for(;t<=n&&n<=e;)s.add(n),r+=1,n=Ap(t,r);for(n=vp(e+1,i)-1;t<n&&n<=e;)s.add(n),i+=1,n=vp(e+1,i)-1;return s=[...s],s.sort(tA),s}function QS(t,e,r){if(t===e)return{pattern:t,count:[],digits:0};let i=eA(t,e),n=i.length,s="",o=0;for(let a=0;a<n;a++){let[u,l]=i[a];u===l?s+=u:u!=="0"||l!=="9"?s+=rA(u,l,r):o++}return o&&(s+=r.shorthand===!0?"\\d":"[0-9]"),{pattern:s,count:[o],digits:n}}function wp(t,e,r,i){let n=XS(t,e),s=[],o=t,a;for(let u=0;u<n.length;u++){let l=n[u],c=QS(String(o),String(l),i),f="";if(!r.isPadded&&a&&a.pattern===c.pattern){a.count.length>1&&a.count.pop(),a.count.push(c.count[0]),a.string=a.pattern+Cp(a.count),o=l+1;continue}r.isPadded&&(f=iA(l,r,i)),c.string=f+c.pattern+Cp(c.count),s.push(c),o=l+1,a=c}return s}function Wa(t,e,r,i,n){let s=[];for(let o of t){let{string:a}=o;!i&&!Sp(e,"string",a)&&s.push(r+a),i&&Sp(e,"string",a)&&s.push(r+a)}return s}function eA(t,e){let r=[];for(let i=0;i<t.length;i++)r.push([t[i],e[i]]);return r}function tA(t,e){return t>e?1:e>t?-1:0}function Sp(t,e,r){return t.some(i=>i[e]===r)}function Ap(t,e){return Number(String(t).slice(0,-e)+"9".repeat(e))}function vp(t,e){return t-t%Math.pow(10,e)}function Cp(t){let[e=0,r=""]=t;return r||e>1?`{${e+(r?","+r:"")}}`:""}function rA(t,e,r){return`[${t}${e-t===1?"":"-"}${e}]`}function xp(t){return/^-?(0+)\d/.test(t)}function iA(t,e,r){if(!e.isPadded)return t;let i=Math.abs(e.maxLen-String(t).length),n=r.relaxZeros!==!1;switch(i){case 0:return"";case 1:return n?"0?":"0";case 2:return n?"0{0,2}":"00";default:return n?`0{0,${i}}`:`0{${i}}`}}Nr.cache={};Nr.clearCache=()=>Nr.cache={};Rp.exports=Nr});var Ka=$((RB,Np)=>{"use strict";var nA=require("util"),Tp=Fp(),Op=t=>t!==null&&typeof t=="object"&&!Array.isArray(t),sA=t=>e=>t===!0?Number(e):String(e),Ya=t=>typeof t=="number"||typeof t=="string"&&t!=="",yn=t=>Number.isInteger(+t),Va=t=>{let e=`${t}`,r=-1;if(e[0]==="-"&&(e=e.slice(1)),e==="0")return!1;for(;e[++r]==="0";);return r>0},oA=(t,e,r)=>typeof t=="string"||typeof e=="string"?!0:r.stringify===!0,aA=(t,e,r)=>{if(e>0){let i=t[0]==="-"?"-":"";i&&(t=t.slice(1)),t=i+t.padStart(i?e-1:e,"0")}return r===!1?String(t):t},kp=(t,e)=>{let r=t[0]==="-"?"-":"";for(r&&(t=t.slice(1),e--);t.length<e;)t="0"+t;return r?"-"+t:t},uA=(t,e)=>{t.negatives.sort((o,a)=>o<a?-1:o>a?1:0),t.positives.sort((o,a)=>o<a?-1:o>a?1:0);let r=e.capture?"":"?:",i="",n="",s;return t.positives.length&&(i=t.positives.join("|")),t.negatives.length&&(n=`-(${r}${t.negatives.join("|")})`),i&&n?s=`${i}|${n}`:s=i||n,e.wrap?`(${r}${s})`:s},Lp=(t,e,r,i)=>{if(r)return Tp(t,e,{wrap:!1,...i});let n=String.fromCharCode(t);if(t===e)return n;let s=String.fromCharCode(e);return`[${n}-${s}]`},Bp=(t,e,r)=>{if(Array.isArray(t)){let i=r.wrap===!0,n=r.capture?"":"?:";return i?`(${n}${t.join("|")})`:t.join("|")}return Tp(t,e,r)},Pp=(...t)=>new RangeError("Invalid range arguments: "+nA.inspect(...t)),Ip=(t,e,r)=>{if(r.strictRanges===!0)throw Pp([t,e]);return[]},lA=(t,e)=>{if(e.strictRanges===!0)throw new TypeError(`Expected step "${t}" to be a number`);return[]},cA=(t,e,r=1,i={})=>{let n=Number(t),s=Number(e);if(!Number.isInteger(n)||!Number.isInteger(s)){if(i.strictRanges===!0)throw Pp([t,e]);return[]}n===0&&(n=0),s===0&&(s=0);let o=n>s,a=String(t),u=String(e),l=String(r);r=Math.max(Math.abs(r),1);let c=Va(a)||Va(u)||Va(l),f=c?Math.max(a.length,u.length,l.length):0,h=c===!1&&oA(t,e,i)===!1,p=i.transform||sA(h);if(i.toRegex&&r===1)return Lp(kp(t,f),kp(e,f),!0,i);let g={negatives:[],positives:[]},y=F=>g[F<0?"negatives":"positives"].push(Math.abs(F)),E=[],v=0;for(;o?n>=s:n<=s;)i.toRegex===!0&&r>1?y(n):E.push(aA(p(n,v),f,h)),n=o?n-r:n+r,v++;return i.toRegex===!0?r>1?uA(g,i):Bp(E,null,{wrap:!1,...i}):E},hA=(t,e,r=1,i={})=>{if(!yn(t)&&t.length>1||!yn(e)&&e.length>1)return Ip(t,e,i);let n=i.transform||(h=>String.fromCharCode(h)),s=`${t}`.charCodeAt(0),o=`${e}`.charCodeAt(0),a=s>o,u=Math.min(s,o),l=Math.max(s,o);if(i.toRegex&&r===1)return Lp(u,l,!1,i);let c=[],f=0;for(;a?s>=o:s<=o;)c.push(n(s,f)),s=a?s-r:s+r,f++;return i.toRegex===!0?Bp(c,null,{wrap:!1,options:i}):c},ps=(t,e,r,i={})=>{if(e==null&&Ya(t))return[t];if(!Ya(t)||!Ya(e))return Ip(t,e,i);if(typeof r=="function")return ps(t,e,1,{transform:r});if(Op(r))return ps(t,e,0,r);let n={...i};return n.capture===!0&&(n.wrap=!0),r=r||n.step||1,yn(r)?yn(t)&&yn(e)?cA(t,e,r,n):hA(t,e,Math.max(Math.abs(r),1),n):r!=null&&!Op(r)?lA(r,n):ps(t,e,1,r)};Np.exports=ps});var $p=$((FB,jp)=>{"use strict";var fA=Ka(),Mp=hs(),pA=(t,e={})=>{let r=(i,n={})=>{let s=Mp.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a=s===!0||o===!0,u=e.escapeInvalid===!0?"\\":"",l="";if(i.isOpen===!0||i.isClose===!0)return u+i.value;if(i.type==="open")return a?u+i.value:"(";if(i.type==="close")return a?u+i.value:")";if(i.type==="comma")return i.prev.type==="comma"?"":a?i.value:"|";if(i.value)return i.value;if(i.nodes&&i.ranges>0){let c=Mp.reduce(i.nodes),f=fA(...c,{...e,wrap:!1,toRegex:!0});if(f.length!==0)return c.length>1&&f.length>1?`(${f})`:f}if(i.nodes)for(let c of i.nodes)l+=r(c,i);return l};return r(t)};jp.exports=pA});var Up=$((OB,qp)=>{"use strict";var dA=Ka(),Hp=fs(),pi=hs(),Mr=(t="",e="",r=!1)=>{let i=[];if(t=[].concat(t),e=[].concat(e),!e.length)return t;if(!t.length)return r?pi.flatten(e).map(n=>`{${n}}`):e;for(let n of t)if(Array.isArray(n))for(let s of n)i.push(Mr(s,e,r));else for(let s of e)r===!0&&typeof s=="string"&&(s=`{${s}}`),i.push(Array.isArray(s)?Mr(n,s,r):n+s);return pi.flatten(i)},mA=(t,e={})=>{let r=e.rangeLimit===void 0?1e3:e.rangeLimit,i=(n,s={})=>{n.queue=[];let o=s,a=s.queue;for(;o.type!=="brace"&&o.type!=="root"&&o.parent;)o=o.parent,a=o.queue;if(n.invalid||n.dollar){a.push(Mr(a.pop(),Hp(n,e)));return}if(n.type==="brace"&&n.invalid!==!0&&n.nodes.length===2){a.push(Mr(a.pop(),["{}"]));return}if(n.nodes&&n.ranges>0){let f=pi.reduce(n.nodes);if(pi.exceedsLimit(...f,e.step,r))throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.");let h=dA(...f,e);h.length===0&&(h=Hp(n,e)),a.push(Mr(a.pop(),h)),n.nodes=[];return}let u=pi.encloseBrace(n),l=n.queue,c=n;for(;c.type!=="brace"&&c.type!=="root"&&c.parent;)c=c.parent,l=c.queue;for(let f=0;f<n.nodes.length;f++){let h=n.nodes[f];if(h.type==="comma"&&n.type==="brace"){f===1&&l.push(""),l.push("");continue}if(h.type==="close"){a.push(Mr(a.pop(),l,u));continue}if(h.value&&h.type!=="open"){l.push(Mr(l.pop(),h.value));continue}h.nodes&&i(h,n)}return l};return pi.flatten(i(t))};qp.exports=mA});var zp=$((kB,Gp)=>{"use strict";Gp.exports={MAX_LENGTH:1024*64,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:`
3
+ `,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:" ",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var Zp=$((TB,Kp)=>{"use strict";var gA=fs(),{MAX_LENGTH:Wp,CHAR_BACKSLASH:Za,CHAR_BACKTICK:yA,CHAR_COMMA:EA,CHAR_DOT:DA,CHAR_LEFT_PARENTHESES:bA,CHAR_RIGHT_PARENTHESES:_A,CHAR_LEFT_CURLY_BRACE:wA,CHAR_RIGHT_CURLY_BRACE:SA,CHAR_LEFT_SQUARE_BRACKET:Yp,CHAR_RIGHT_SQUARE_BRACKET:Vp,CHAR_DOUBLE_QUOTE:AA,CHAR_SINGLE_QUOTE:vA,CHAR_NO_BREAK_SPACE:CA,CHAR_ZERO_WIDTH_NOBREAK_SPACE:xA}=zp(),RA=(t,e={})=>{if(typeof t!="string")throw new TypeError("Expected a string");let r=e||{},i=typeof r.maxLength=="number"?Math.min(Wp,r.maxLength):Wp;if(t.length>i)throw new SyntaxError(`Input length (${t.length}), exceeds max characters (${i})`);let n={type:"root",input:t,nodes:[]},s=[n],o=n,a=n,u=0,l=t.length,c=0,f=0,h,p={},g=()=>t[c++],y=E=>{if(E.type==="text"&&a.type==="dot"&&(a.type="text"),a&&a.type==="text"&&E.type==="text"){a.value+=E.value;return}return o.nodes.push(E),E.parent=o,E.prev=a,a=E,E};for(y({type:"bos"});c<l;)if(o=s[s.length-1],h=g(),!(h===xA||h===CA)){if(h===Za){y({type:"text",value:(e.keepEscaping?h:"")+g()});continue}if(h===Vp){y({type:"text",value:"\\"+h});continue}if(h===Yp){u++;let E=!0,v;for(;c<l&&(v=g());){if(h+=v,v===Yp){u++;continue}if(v===Za){h+=g();continue}if(v===Vp&&(u--,u===0))break}y({type:"text",value:h});continue}if(h===bA){o=y({type:"paren",nodes:[]}),s.push(o),y({type:"text",value:h});continue}if(h===_A){if(o.type!=="paren"){y({type:"text",value:h});continue}o=s.pop(),y({type:"text",value:h}),o=s[s.length-1];continue}if(h===AA||h===vA||h===yA){let E=h,v;for(e.keepQuotes!==!0&&(h="");c<l&&(v=g());){if(v===Za){h+=v+g();continue}if(v===E){e.keepQuotes===!0&&(h+=v);break}h+=v}y({type:"text",value:h});continue}if(h===wA){f++;let v={type:"brace",open:!0,close:!1,dollar:a.value&&a.value.slice(-1)==="$"||o.dollar===!0,depth:f,commas:0,ranges:0,nodes:[]};o=y(v),s.push(o),y({type:"open",value:h});continue}if(h===SA){if(o.type!=="brace"){y({type:"text",value:h});continue}let E="close";o=s.pop(),o.close=!0,y({type:E,value:h}),f--,o=s[s.length-1];continue}if(h===EA&&f>0){if(o.ranges>0){o.ranges=0;let E=o.nodes.shift();o.nodes=[E,{type:"text",value:gA(o)}]}y({type:"comma",value:h}),o.commas++;continue}if(h===DA&&f>0&&o.commas===0){let E=o.nodes;if(f===0||E.length===0){y({type:"text",value:h});continue}if(a.type==="dot"){if(o.range=[],a.value+=h,a.type="range",o.nodes.length!==3&&o.nodes.length!==5){o.invalid=!0,o.ranges=0,a.type="text";continue}o.ranges++,o.args=[];continue}if(a.type==="range"){E.pop();let v=E[E.length-1];v.value+=a.value+h,a=v,o.ranges--;continue}y({type:"dot",value:h});continue}y({type:"text",value:h})}do if(o=s.pop(),o.type!=="root"){o.nodes.forEach(F=>{F.nodes||(F.type==="open"&&(F.isOpen=!0),F.type==="close"&&(F.isClose=!0),F.nodes||(F.type="text"),F.invalid=!0)});let E=s[s.length-1],v=E.nodes.indexOf(o);E.nodes.splice(v,1,...o.nodes)}while(s.length>0);return y({type:"eos"}),n};Kp.exports=RA});var Qp=$((LB,Xp)=>{"use strict";var Jp=fs(),FA=$p(),OA=Up(),kA=Zp(),Ze=(t,e={})=>{let r=[];if(Array.isArray(t))for(let i of t){let n=Ze.create(i,e);Array.isArray(n)?r.push(...n):r.push(n)}else r=[].concat(Ze.create(t,e));return e&&e.expand===!0&&e.nodupes===!0&&(r=[...new Set(r)]),r};Ze.parse=(t,e={})=>kA(t,e);Ze.stringify=(t,e={})=>Jp(typeof t=="string"?Ze.parse(t,e):t,e);Ze.compile=(t,e={})=>(typeof t=="string"&&(t=Ze.parse(t,e)),FA(t,e));Ze.expand=(t,e={})=>{typeof t=="string"&&(t=Ze.parse(t,e));let r=OA(t,e);return e.noempty===!0&&(r=r.filter(Boolean)),e.nodupes===!0&&(r=[...new Set(r)]),r};Ze.create=(t,e={})=>t===""||t.length<3?[t]:e.expand!==!0?Ze.compile(t,e):Ze.expand(t,e);Xp.exports=Ze});var En=$((BB,nd)=>{"use strict";var TA=require("path"),bt="\\\\/",ed=`[^${bt}]`,jt="\\.",LA="\\+",BA="\\?",ds="\\/",PA="(?=.)",td="[^/]",Ja=`(?:${ds}|$)`,rd=`(?:^|${ds})`,Xa=`${jt}{1,2}${Ja}`,IA=`(?!${jt})`,NA=`(?!${rd}${Xa})`,MA=`(?!${jt}{0,1}${Ja})`,jA=`(?!${Xa})`,$A=`[^.${ds}]`,HA=`${td}*?`,id={DOT_LITERAL:jt,PLUS_LITERAL:LA,QMARK_LITERAL:BA,SLASH_LITERAL:ds,ONE_CHAR:PA,QMARK:td,END_ANCHOR:Ja,DOTS_SLASH:Xa,NO_DOT:IA,NO_DOTS:NA,NO_DOT_SLASH:MA,NO_DOTS_SLASH:jA,QMARK_NO_DOT:$A,STAR:HA,START_ANCHOR:rd},qA={...id,SLASH_LITERAL:`[${bt}]`,QMARK:ed,STAR:`${ed}*?`,DOTS_SLASH:`${jt}{1,2}(?:[${bt}]|$)`,NO_DOT:`(?!${jt})`,NO_DOTS:`(?!(?:^|[${bt}])${jt}{1,2}(?:[${bt}]|$))`,NO_DOT_SLASH:`(?!${jt}{0,1}(?:[${bt}]|$))`,NO_DOTS_SLASH:`(?!${jt}{1,2}(?:[${bt}]|$))`,QMARK_NO_DOT:`[^.${bt}]`,START_ANCHOR:`(?:^|[${bt}])`,END_ANCHOR:`(?:[${bt}]|$)`},UA={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};nd.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:UA,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:TA.sep,extglobChars(t){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${t.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars(t){return t===!0?qA:id}}});var Dn=$(Ge=>{"use strict";var GA=require("path"),zA=process.platform==="win32",{REGEX_BACKSLASH:WA,REGEX_REMOVE_BACKSLASH:YA,REGEX_SPECIAL_CHARS:VA,REGEX_SPECIAL_CHARS_GLOBAL:KA}=En();Ge.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);Ge.hasRegexChars=t=>VA.test(t);Ge.isRegexChar=t=>t.length===1&&Ge.hasRegexChars(t);Ge.escapeRegex=t=>t.replace(KA,"\\$1");Ge.toPosixSlashes=t=>t.replace(WA,"/");Ge.removeBackslashes=t=>t.replace(YA,e=>e==="\\"?"":e);Ge.supportsLookbehinds=()=>{let t=process.version.slice(1).split(".").map(Number);return t.length===3&&t[0]>=9||t[0]===8&&t[1]>=10};Ge.isWindows=t=>t&&typeof t.windows=="boolean"?t.windows:zA===!0||GA.sep==="\\";Ge.escapeLast=(t,e,r)=>{let i=t.lastIndexOf(e,r);return i===-1?t:t[i-1]==="\\"?Ge.escapeLast(t,e,i-1):`${t.slice(0,i)}\\${t.slice(i)}`};Ge.removePrefix=(t,e={})=>{let r=t;return r.startsWith("./")&&(r=r.slice(2),e.prefix="./"),r};Ge.wrapOutput=(t,e={},r={})=>{let i=r.contains?"":"^",n=r.contains?"":"$",s=`${i}(?:${t})${n}`;return e.negated===!0&&(s=`(?:^(?!${s}).*$)`),s}});var fd=$((IB,hd)=>{"use strict";var sd=Dn(),{CHAR_ASTERISK:Qa,CHAR_AT:ZA,CHAR_BACKWARD_SLASH:bn,CHAR_COMMA:JA,CHAR_DOT:eu,CHAR_EXCLAMATION_MARK:tu,CHAR_FORWARD_SLASH:cd,CHAR_LEFT_CURLY_BRACE:ru,CHAR_LEFT_PARENTHESES:iu,CHAR_LEFT_SQUARE_BRACKET:XA,CHAR_PLUS:QA,CHAR_QUESTION_MARK:od,CHAR_RIGHT_CURLY_BRACE:ev,CHAR_RIGHT_PARENTHESES:ad,CHAR_RIGHT_SQUARE_BRACKET:tv}=En(),ud=t=>t===cd||t===bn,ld=t=>{t.isPrefix!==!0&&(t.depth=t.isGlobstar?1/0:1)},rv=(t,e)=>{let r=e||{},i=t.length-1,n=r.parts===!0||r.scanToEnd===!0,s=[],o=[],a=[],u=t,l=-1,c=0,f=0,h=!1,p=!1,g=!1,y=!1,E=!1,v=!1,F=!1,O=!1,R=!1,x=!1,L=0,b,S,N={value:"",depth:0,isGlob:!1},H=()=>l>=i,T=()=>u.charCodeAt(l+1),U=()=>(b=S,u.charCodeAt(++l));for(;l<i;){S=U();let k;if(S===bn){F=N.backslashes=!0,S=U(),S===ru&&(v=!0);continue}if(v===!0||S===ru){for(L++;H()!==!0&&(S=U());){if(S===bn){F=N.backslashes=!0,U();continue}if(S===ru){L++;continue}if(v!==!0&&S===eu&&(S=U())===eu){if(h=N.isBrace=!0,g=N.isGlob=!0,x=!0,n===!0)continue;break}if(v!==!0&&S===JA){if(h=N.isBrace=!0,g=N.isGlob=!0,x=!0,n===!0)continue;break}if(S===ev&&(L--,L===0)){v=!1,h=N.isBrace=!0,x=!0;break}}if(n===!0)continue;break}if(S===cd){if(s.push(l),o.push(N),N={value:"",depth:0,isGlob:!1},x===!0)continue;if(b===eu&&l===c+1){c+=2;continue}f=l+1;continue}if(r.noext!==!0&&(S===QA||S===ZA||S===Qa||S===od||S===tu)===!0&&T()===iu){if(g=N.isGlob=!0,y=N.isExtglob=!0,x=!0,S===tu&&l===c&&(R=!0),n===!0){for(;H()!==!0&&(S=U());){if(S===bn){F=N.backslashes=!0,S=U();continue}if(S===ad){g=N.isGlob=!0,x=!0;break}}continue}break}if(S===Qa){if(b===Qa&&(E=N.isGlobstar=!0),g=N.isGlob=!0,x=!0,n===!0)continue;break}if(S===od){if(g=N.isGlob=!0,x=!0,n===!0)continue;break}if(S===XA){for(;H()!==!0&&(k=U());){if(k===bn){F=N.backslashes=!0,U();continue}if(k===tv){p=N.isBracket=!0,g=N.isGlob=!0,x=!0;break}}if(n===!0)continue;break}if(r.nonegate!==!0&&S===tu&&l===c){O=N.negated=!0,c++;continue}if(r.noparen!==!0&&S===iu){if(g=N.isGlob=!0,n===!0){for(;H()!==!0&&(S=U());){if(S===iu){F=N.backslashes=!0,S=U();continue}if(S===ad){x=!0;break}}continue}break}if(g===!0){if(x=!0,n===!0)continue;break}}r.noext===!0&&(y=!1,g=!1);let V=u,K="",B="";c>0&&(K=u.slice(0,c),u=u.slice(c),f-=c),V&&g===!0&&f>0?(V=u.slice(0,f),B=u.slice(f)):g===!0?(V="",B=u):V=u,V&&V!==""&&V!=="/"&&V!==u&&ud(V.charCodeAt(V.length-1))&&(V=V.slice(0,-1)),r.unescape===!0&&(B&&(B=sd.removeBackslashes(B)),V&&F===!0&&(V=sd.removeBackslashes(V)));let C={prefix:K,input:t,start:c,base:V,glob:B,isBrace:h,isBracket:p,isGlob:g,isExtglob:y,isGlobstar:E,negated:O,negatedExtglob:R};if(r.tokens===!0&&(C.maxDepth=0,ud(S)||o.push(N),C.tokens=o),r.parts===!0||r.tokens===!0){let k;for(let j=0;j<s.length;j++){let z=k?k+1:c,P=s[j],d=t.slice(z,P);r.tokens&&(j===0&&c!==0?(o[j].isPrefix=!0,o[j].value=K):o[j].value=d,ld(o[j]),C.maxDepth+=o[j].depth),(j!==0||d!=="")&&a.push(d),k=P}if(k&&k+1<t.length){let j=t.slice(k+1);a.push(j),r.tokens&&(o[o.length-1].value=j,ld(o[o.length-1]),C.maxDepth+=o[o.length-1].depth)}C.slashes=s,C.parts=a}return C};hd.exports=rv});var md=$((NB,dd)=>{"use strict";var ms=En(),Je=Dn(),{MAX_LENGTH:gs,POSIX_REGEX_SOURCE:iv,REGEX_NON_SPECIAL_CHARS:nv,REGEX_SPECIAL_CHARS_BACKREF:sv,REPLACEMENTS:pd}=ms,ov=(t,e)=>{if(typeof e.expandRange=="function")return e.expandRange(...t,e);t.sort();let r=`[${t.join("-")}]`;try{new RegExp(r)}catch{return t.map(n=>Je.escapeRegex(n)).join("..")}return r},di=(t,e)=>`Missing ${t}: "${e}" - use "\\\\${e}" to match literal characters`,nu=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");t=pd[t]||t;let r={...e},i=typeof r.maxLength=="number"?Math.min(gs,r.maxLength):gs,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);let s={type:"bos",value:"",output:r.prepend||""},o=[s],a=r.capture?"":"?:",u=Je.isWindows(e),l=ms.globChars(u),c=ms.extglobChars(l),{DOT_LITERAL:f,PLUS_LITERAL:h,SLASH_LITERAL:p,ONE_CHAR:g,DOTS_SLASH:y,NO_DOT:E,NO_DOT_SLASH:v,NO_DOTS_SLASH:F,QMARK:O,QMARK_NO_DOT:R,STAR:x,START_ANCHOR:L}=l,b=q=>`(${a}(?:(?!${L}${q.dot?y:f}).)*?)`,S=r.dot?"":E,N=r.dot?O:R,H=r.bash===!0?b(r):x;r.capture&&(H=`(${H})`),typeof r.noext=="boolean"&&(r.noextglob=r.noext);let T={input:t,index:-1,start:0,dot:r.dot===!0,consumed:"",output:"",prefix:"",backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:o};t=Je.removePrefix(t,T),n=t.length;let U=[],V=[],K=[],B=s,C,k=()=>T.index===n-1,j=T.peek=(q=1)=>t[T.index+q],z=T.advance=()=>t[++T.index]||"",P=()=>t.slice(T.index+1),d=(q="",Q=0)=>{T.consumed+=q,T.index+=Q},m=q=>{T.output+=q.output!=null?q.output:q.value,d(q.value)},D=()=>{let q=1;for(;j()==="!"&&(j(2)!=="("||j(3)==="?");)z(),T.start++,q++;return q%2===0?!1:(T.negated=!0,T.start++,!0)},A=q=>{T[q]++,K.push(q)},w=q=>{T[q]--,K.pop()},I=q=>{if(B.type==="globstar"){let Q=T.braces>0&&(q.type==="comma"||q.type==="brace"),G=q.extglob===!0||U.length&&(q.type==="pipe"||q.type==="paren");q.type!=="slash"&&q.type!=="paren"&&!Q&&!G&&(T.output=T.output.slice(0,-B.output.length),B.type="star",B.value="*",B.output=H,T.output+=B.output)}if(U.length&&q.type!=="paren"&&(U[U.length-1].inner+=q.value),(q.value||q.output)&&m(q),B&&B.type==="text"&&q.type==="text"){B.value+=q.value,B.output=(B.output||"")+q.value;return}q.prev=B,o.push(q),B=q},M=(q,Q)=>{let G={...c[Q],conditions:1,inner:""};G.prev=B,G.parens=T.parens,G.output=T.output;let ie=(r.capture?"(":"")+G.open;A("parens"),I({type:q,value:Q,output:T.output?"":g}),I({type:"paren",extglob:!0,value:z(),output:ie}),U.push(G)},Z=q=>{let Q=q.close+(r.capture?")":""),G;if(q.type==="negate"){let ie=H;if(q.inner&&q.inner.length>1&&q.inner.includes("/")&&(ie=b(r)),(ie!==H||k()||/^\)+$/.test(P()))&&(Q=q.close=`)$))${ie}`),q.inner.includes("*")&&(G=P())&&/^\.[^\\/.]+$/.test(G)){let ce=nu(G,{...e,fastpaths:!1}).output;Q=q.close=`)${ce})${ie})`}q.prev.type==="bos"&&(T.negatedExtglob=!0)}I({type:"paren",extglob:!0,value:C,output:Q}),w("parens")};if(r.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(t)){let q=!1,Q=t.replace(sv,(G,ie,ce,we,De,_)=>we==="\\"?(q=!0,G):we==="?"?ie?ie+we+(De?O.repeat(De.length):""):_===0?N+(De?O.repeat(De.length):""):O.repeat(ce.length):we==="."?f.repeat(ce.length):we==="*"?ie?ie+we+(De?H:""):H:ie?G:`\\${G}`);return q===!0&&(r.unescape===!0?Q=Q.replace(/\\/g,""):Q=Q.replace(/\\+/g,G=>G.length%2===0?"\\\\":G?"\\":"")),Q===t&&r.contains===!0?(T.output=t,T):(T.output=Je.wrapOutput(Q,T,e),T)}for(;!k();){if(C=z(),C==="\0")continue;if(C==="\\"){let G=j();if(G==="/"&&r.bash!==!0||G==="."||G===";")continue;if(!G){C+="\\",I({type:"text",value:C});continue}let ie=/^\\+/.exec(P()),ce=0;if(ie&&ie[0].length>2&&(ce=ie[0].length,T.index+=ce,ce%2!==0&&(C+="\\")),r.unescape===!0?C=z():C+=z(),T.brackets===0){I({type:"text",value:C});continue}}if(T.brackets>0&&(C!=="]"||B.value==="["||B.value==="[^")){if(r.posix!==!1&&C===":"){let G=B.value.slice(1);if(G.includes("[")&&(B.posix=!0,G.includes(":"))){let ie=B.value.lastIndexOf("["),ce=B.value.slice(0,ie),we=B.value.slice(ie+2),De=iv[we];if(De){B.value=ce+De,T.backtrack=!0,z(),!s.output&&o.indexOf(B)===1&&(s.output=g);continue}}}(C==="["&&j()!==":"||C==="-"&&j()==="]")&&(C=`\\${C}`),C==="]"&&(B.value==="["||B.value==="[^")&&(C=`\\${C}`),r.posix===!0&&C==="!"&&B.value==="["&&(C="^"),B.value+=C,m({value:C});continue}if(T.quotes===1&&C!=='"'){C=Je.escapeRegex(C),B.value+=C,m({value:C});continue}if(C==='"'){T.quotes=T.quotes===1?0:1,r.keepQuotes===!0&&I({type:"text",value:C});continue}if(C==="("){A("parens"),I({type:"paren",value:C});continue}if(C===")"){if(T.parens===0&&r.strictBrackets===!0)throw new SyntaxError(di("opening","("));let G=U[U.length-1];if(G&&T.parens===G.parens+1){Z(U.pop());continue}I({type:"paren",value:C,output:T.parens?")":"\\)"}),w("parens");continue}if(C==="["){if(r.nobracket===!0||!P().includes("]")){if(r.nobracket!==!0&&r.strictBrackets===!0)throw new SyntaxError(di("closing","]"));C=`\\${C}`}else A("brackets");I({type:"bracket",value:C});continue}if(C==="]"){if(r.nobracket===!0||B&&B.type==="bracket"&&B.value.length===1){I({type:"text",value:C,output:`\\${C}`});continue}if(T.brackets===0){if(r.strictBrackets===!0)throw new SyntaxError(di("opening","["));I({type:"text",value:C,output:`\\${C}`});continue}w("brackets");let G=B.value.slice(1);if(B.posix!==!0&&G[0]==="^"&&!G.includes("/")&&(C=`/${C}`),B.value+=C,m({value:C}),r.literalBrackets===!1||Je.hasRegexChars(G))continue;let ie=Je.escapeRegex(B.value);if(T.output=T.output.slice(0,-B.value.length),r.literalBrackets===!0){T.output+=ie,B.value=ie;continue}B.value=`(${a}${ie}|${B.value})`,T.output+=B.value;continue}if(C==="{"&&r.nobrace!==!0){A("braces");let G={type:"brace",value:C,output:"(",outputIndex:T.output.length,tokensIndex:T.tokens.length};V.push(G),I(G);continue}if(C==="}"){let G=V[V.length-1];if(r.nobrace===!0||!G){I({type:"text",value:C,output:C});continue}let ie=")";if(G.dots===!0){let ce=o.slice(),we=[];for(let De=ce.length-1;De>=0&&(o.pop(),ce[De].type!=="brace");De--)ce[De].type!=="dots"&&we.unshift(ce[De].value);ie=ov(we,r),T.backtrack=!0}if(G.comma!==!0&&G.dots!==!0){let ce=T.output.slice(0,G.outputIndex),we=T.tokens.slice(G.tokensIndex);G.value=G.output="\\{",C=ie="\\}",T.output=ce;for(let De of we)T.output+=De.output||De.value}I({type:"brace",value:C,output:ie}),w("braces"),V.pop();continue}if(C==="|"){U.length>0&&U[U.length-1].conditions++,I({type:"text",value:C});continue}if(C===","){let G=C,ie=V[V.length-1];ie&&K[K.length-1]==="braces"&&(ie.comma=!0,G="|"),I({type:"comma",value:C,output:G});continue}if(C==="/"){if(B.type==="dot"&&T.index===T.start+1){T.start=T.index+1,T.consumed="",T.output="",o.pop(),B=s;continue}I({type:"slash",value:C,output:p});continue}if(C==="."){if(T.braces>0&&B.type==="dot"){B.value==="."&&(B.output=f);let G=V[V.length-1];B.type="dots",B.output+=C,B.value+=C,G.dots=!0;continue}if(T.braces+T.parens===0&&B.type!=="bos"&&B.type!=="slash"){I({type:"text",value:C,output:f});continue}I({type:"dot",value:C,output:f});continue}if(C==="?"){if(!(B&&B.value==="(")&&r.noextglob!==!0&&j()==="("&&j(2)!=="?"){M("qmark",C);continue}if(B&&B.type==="paren"){let ie=j(),ce=C;if(ie==="<"&&!Je.supportsLookbehinds())throw new Error("Node.js v10 or higher is required for regex lookbehinds");(B.value==="("&&!/[!=<:]/.test(ie)||ie==="<"&&!/<([!=]|\w+>)/.test(P()))&&(ce=`\\${C}`),I({type:"text",value:C,output:ce});continue}if(r.dot!==!0&&(B.type==="slash"||B.type==="bos")){I({type:"qmark",value:C,output:R});continue}I({type:"qmark",value:C,output:O});continue}if(C==="!"){if(r.noextglob!==!0&&j()==="("&&(j(2)!=="?"||!/[!=<:]/.test(j(3)))){M("negate",C);continue}if(r.nonegate!==!0&&T.index===0){D();continue}}if(C==="+"){if(r.noextglob!==!0&&j()==="("&&j(2)!=="?"){M("plus",C);continue}if(B&&B.value==="("||r.regex===!1){I({type:"plus",value:C,output:h});continue}if(B&&(B.type==="bracket"||B.type==="paren"||B.type==="brace")||T.parens>0){I({type:"plus",value:C});continue}I({type:"plus",value:h});continue}if(C==="@"){if(r.noextglob!==!0&&j()==="("&&j(2)!=="?"){I({type:"at",extglob:!0,value:C,output:""});continue}I({type:"text",value:C});continue}if(C!=="*"){(C==="$"||C==="^")&&(C=`\\${C}`);let G=nv.exec(P());G&&(C+=G[0],T.index+=G[0].length),I({type:"text",value:C});continue}if(B&&(B.type==="globstar"||B.star===!0)){B.type="star",B.star=!0,B.value+=C,B.output=H,T.backtrack=!0,T.globstar=!0,d(C);continue}let q=P();if(r.noextglob!==!0&&/^\([^?]/.test(q)){M("star",C);continue}if(B.type==="star"){if(r.noglobstar===!0){d(C);continue}let G=B.prev,ie=G.prev,ce=G.type==="slash"||G.type==="bos",we=ie&&(ie.type==="star"||ie.type==="globstar");if(r.bash===!0&&(!ce||q[0]&&q[0]!=="/")){I({type:"star",value:C,output:""});continue}let De=T.braces>0&&(G.type==="comma"||G.type==="brace"),_=U.length&&(G.type==="pipe"||G.type==="paren");if(!ce&&G.type!=="paren"&&!De&&!_){I({type:"star",value:C,output:""});continue}for(;q.slice(0,3)==="/**";){let Y=t[T.index+4];if(Y&&Y!=="/")break;q=q.slice(3),d("/**",3)}if(G.type==="bos"&&k()){B.type="globstar",B.value+=C,B.output=b(r),T.output=B.output,T.globstar=!0,d(C);continue}if(G.type==="slash"&&G.prev.type!=="bos"&&!we&&k()){T.output=T.output.slice(0,-(G.output+B.output).length),G.output=`(?:${G.output}`,B.type="globstar",B.output=b(r)+(r.strictSlashes?")":"|$)"),B.value+=C,T.globstar=!0,T.output+=G.output+B.output,d(C);continue}if(G.type==="slash"&&G.prev.type!=="bos"&&q[0]==="/"){let Y=q[1]!==void 0?"|$":"";T.output=T.output.slice(0,-(G.output+B.output).length),G.output=`(?:${G.output}`,B.type="globstar",B.output=`${b(r)}${p}|${p}${Y})`,B.value+=C,T.output+=G.output+B.output,T.globstar=!0,d(C+z()),I({type:"slash",value:"/",output:""});continue}if(G.type==="bos"&&q[0]==="/"){B.type="globstar",B.value+=C,B.output=`(?:^|${p}|${b(r)}${p})`,T.output=B.output,T.globstar=!0,d(C+z()),I({type:"slash",value:"/",output:""});continue}T.output=T.output.slice(0,-B.output.length),B.type="globstar",B.output=b(r),B.value+=C,T.output+=B.output,T.globstar=!0,d(C);continue}let Q={type:"star",value:C,output:H};if(r.bash===!0){Q.output=".*?",(B.type==="bos"||B.type==="slash")&&(Q.output=S+Q.output),I(Q);continue}if(B&&(B.type==="bracket"||B.type==="paren")&&r.regex===!0){Q.output=C,I(Q);continue}(T.index===T.start||B.type==="slash"||B.type==="dot")&&(B.type==="dot"?(T.output+=v,B.output+=v):r.dot===!0?(T.output+=F,B.output+=F):(T.output+=S,B.output+=S),j()!=="*"&&(T.output+=g,B.output+=g)),I(Q)}for(;T.brackets>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing","]"));T.output=Je.escapeLast(T.output,"["),w("brackets")}for(;T.parens>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing",")"));T.output=Je.escapeLast(T.output,"("),w("parens")}for(;T.braces>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing","}"));T.output=Je.escapeLast(T.output,"{"),w("braces")}if(r.strictSlashes!==!0&&(B.type==="star"||B.type==="bracket")&&I({type:"maybe_slash",value:"",output:`${p}?`}),T.backtrack===!0){T.output="";for(let q of T.tokens)T.output+=q.output!=null?q.output:q.value,q.suffix&&(T.output+=q.suffix)}return T};nu.fastpaths=(t,e)=>{let r={...e},i=typeof r.maxLength=="number"?Math.min(gs,r.maxLength):gs,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);t=pd[t]||t;let s=Je.isWindows(e),{DOT_LITERAL:o,SLASH_LITERAL:a,ONE_CHAR:u,DOTS_SLASH:l,NO_DOT:c,NO_DOTS:f,NO_DOTS_SLASH:h,STAR:p,START_ANCHOR:g}=ms.globChars(s),y=r.dot?f:c,E=r.dot?h:c,v=r.capture?"":"?:",F={negated:!1,prefix:""},O=r.bash===!0?".*?":p;r.capture&&(O=`(${O})`);let R=S=>S.noglobstar===!0?O:`(${v}(?:(?!${g}${S.dot?l:o}).)*?)`,x=S=>{switch(S){case"*":return`${y}${u}${O}`;case".*":return`${o}${u}${O}`;case"*.*":return`${y}${O}${o}${u}${O}`;case"*/*":return`${y}${O}${a}${u}${E}${O}`;case"**":return y+R(r);case"**/*":return`(?:${y}${R(r)}${a})?${E}${u}${O}`;case"**/*.*":return`(?:${y}${R(r)}${a})?${E}${O}${o}${u}${O}`;case"**/.*":return`(?:${y}${R(r)}${a})?${o}${u}${O}`;default:{let N=/^(.*?)\.(\w+)$/.exec(S);if(!N)return;let H=x(N[1]);return H?H+o+N[2]:void 0}}},L=Je.removePrefix(t,F),b=x(L);return b&&r.strictSlashes!==!0&&(b+=`${a}?`),b};dd.exports=nu});var yd=$((MB,gd)=>{"use strict";var av=require("path"),uv=fd(),su=md(),ou=Dn(),lv=En(),cv=t=>t&&typeof t=="object"&&!Array.isArray(t),be=(t,e,r=!1)=>{if(Array.isArray(t)){let c=t.map(h=>be(h,e,r));return h=>{for(let p of c){let g=p(h);if(g)return g}return!1}}let i=cv(t)&&t.tokens&&t.input;if(t===""||typeof t!="string"&&!i)throw new TypeError("Expected pattern to be a non-empty string");let n=e||{},s=ou.isWindows(e),o=i?be.compileRe(t,e):be.makeRe(t,e,!1,!0),a=o.state;delete o.state;let u=()=>!1;if(n.ignore){let c={...e,ignore:null,onMatch:null,onResult:null};u=be(n.ignore,c,r)}let l=(c,f=!1)=>{let{isMatch:h,match:p,output:g}=be.test(c,o,e,{glob:t,posix:s}),y={glob:t,state:a,regex:o,posix:s,input:c,output:g,match:p,isMatch:h};return typeof n.onResult=="function"&&n.onResult(y),h===!1?(y.isMatch=!1,f?y:!1):u(c)?(typeof n.onIgnore=="function"&&n.onIgnore(y),y.isMatch=!1,f?y:!1):(typeof n.onMatch=="function"&&n.onMatch(y),f?y:!0)};return r&&(l.state=a),l};be.test=(t,e,r,{glob:i,posix:n}={})=>{if(typeof t!="string")throw new TypeError("Expected input to be a string");if(t==="")return{isMatch:!1,output:""};let s=r||{},o=s.format||(n?ou.toPosixSlashes:null),a=t===i,u=a&&o?o(t):t;return a===!1&&(u=o?o(t):t,a=u===i),(a===!1||s.capture===!0)&&(s.matchBase===!0||s.basename===!0?a=be.matchBase(t,e,r,n):a=e.exec(u)),{isMatch:!!a,match:a,output:u}};be.matchBase=(t,e,r,i=ou.isWindows(r))=>(e instanceof RegExp?e:be.makeRe(e,r)).test(av.basename(t));be.isMatch=(t,e,r)=>be(e,r)(t);be.parse=(t,e)=>Array.isArray(t)?t.map(r=>be.parse(r,e)):su(t,{...e,fastpaths:!1});be.scan=(t,e)=>uv(t,e);be.compileRe=(t,e,r=!1,i=!1)=>{if(r===!0)return t.output;let n=e||{},s=n.contains?"":"^",o=n.contains?"":"$",a=`${s}(?:${t.output})${o}`;t&&t.negated===!0&&(a=`^(?!${a}).*$`);let u=be.toRegex(a,e);return i===!0&&(u.state=t),u};be.makeRe=(t,e={},r=!1,i=!1)=>{if(!t||typeof t!="string")throw new TypeError("Expected a non-empty string");let n={negated:!1,fastpaths:!0};return e.fastpaths!==!1&&(t[0]==="."||t[0]==="*")&&(n.output=su.fastpaths(t,e)),n.output||(n=su(t,e)),be.compileRe(n,e,r,i)};be.toRegex=(t,e)=>{try{let r=e||{};return new RegExp(t,r.flags||(r.nocase?"i":""))}catch(r){if(e&&e.debug===!0)throw r;return/$^/}};be.constants=lv;gd.exports=be});var Dd=$((jB,Ed)=>{"use strict";Ed.exports=yd()});var Ad=$(($B,Sd)=>{"use strict";var _d=require("util"),wd=Qp(),_t=Dd(),au=Dn(),bd=t=>t===""||t==="./",ge=(t,e,r)=>{e=[].concat(e),t=[].concat(t);let i=new Set,n=new Set,s=new Set,o=0,a=c=>{s.add(c.output),r&&r.onResult&&r.onResult(c)};for(let c=0;c<e.length;c++){let f=_t(String(e[c]),{...r,onResult:a},!0),h=f.state.negated||f.state.negatedExtglob;h&&o++;for(let p of t){let g=f(p,!0);(h?!g.isMatch:g.isMatch)&&(h?i.add(g.output):(i.delete(g.output),n.add(g.output)))}}let l=(o===e.length?[...s]:[...n]).filter(c=>!i.has(c));if(r&&l.length===0){if(r.failglob===!0)throw new Error(`No matches found for "${e.join(", ")}"`);if(r.nonull===!0||r.nullglob===!0)return r.unescape?e.map(c=>c.replace(/\\/g,"")):e}return l};ge.match=ge;ge.matcher=(t,e)=>_t(t,e);ge.isMatch=(t,e,r)=>_t(e,r)(t);ge.any=ge.isMatch;ge.not=(t,e,r={})=>{e=[].concat(e).map(String);let i=new Set,n=[],s=a=>{r.onResult&&r.onResult(a),n.push(a.output)},o=new Set(ge(t,e,{...r,onResult:s}));for(let a of n)o.has(a)||i.add(a);return[...i]};ge.contains=(t,e,r)=>{if(typeof t!="string")throw new TypeError(`Expected a string: "${_d.inspect(t)}"`);if(Array.isArray(e))return e.some(i=>ge.contains(t,i,r));if(typeof e=="string"){if(bd(t)||bd(e))return!1;if(t.includes(e)||t.startsWith("./")&&t.slice(2).includes(e))return!0}return ge.isMatch(t,e,{...r,contains:!0})};ge.matchKeys=(t,e,r)=>{if(!au.isObject(t))throw new TypeError("Expected the first argument to be an object");let i=ge(Object.keys(t),e,r),n={};for(let s of i)n[s]=t[s];return n};ge.some=(t,e,r)=>{let i=[].concat(t);for(let n of[].concat(e)){let s=_t(String(n),r);if(i.some(o=>s(o)))return!0}return!1};ge.every=(t,e,r)=>{let i=[].concat(t);for(let n of[].concat(e)){let s=_t(String(n),r);if(!i.every(o=>s(o)))return!1}return!0};ge.all=(t,e,r)=>{if(typeof t!="string")throw new TypeError(`Expected a string: "${_d.inspect(t)}"`);return[].concat(e).every(i=>_t(i,r)(t))};ge.capture=(t,e,r)=>{let i=au.isWindows(r),s=_t.makeRe(String(t),{...r,capture:!0}).exec(i?au.toPosixSlashes(e):e);if(s)return s.slice(1).map(o=>o===void 0?"":o)};ge.makeRe=(...t)=>_t.makeRe(...t);ge.scan=(...t)=>_t.scan(...t);ge.parse=(t,e)=>{let r=[];for(let i of[].concat(t||[]))for(let n of wd(String(i),e))r.push(_t.parse(n,e));return r};ge.braces=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return e&&e.nobrace===!0||!/\{.*\}/.test(t)?[t]:wd(t,e)};ge.braceExpand=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return ge.braces(t,{...e,expand:!0})};Sd.exports=ge});var Td=$(se=>{"use strict";Object.defineProperty(se,"__esModule",{value:!0});se.matchAny=se.convertPatternsToRe=se.makeRe=se.getPatternParts=se.expandBraceExpansion=se.expandPatternsWithBraceExpansion=se.isAffectDepthOfReadingPattern=se.endsWithSlashGlobStar=se.hasGlobStar=se.getBaseDirectory=se.isPatternRelatedToParentDirectory=se.getPatternsOutsideCurrentDirectory=se.getPatternsInsideCurrentDirectory=se.getPositivePatterns=se.getNegativePatterns=se.isPositivePattern=se.isNegativePattern=se.convertToNegativePattern=se.convertToPositivePattern=se.isDynamicPattern=se.isStaticPattern=void 0;var hv=require("path"),fv=gp(),uu=Ad(),vd="**",pv="\\",dv=/[*?]|^!/,mv=/\[[^[]*]/,gv=/(?:^|[^!*+?@])\([^(]*\|[^|]*\)/,yv=/[!*+?@]\([^(]*\)/,Ev=/,|\.\./;function Cd(t,e={}){return!xd(t,e)}se.isStaticPattern=Cd;function xd(t,e={}){return t===""?!1:!!(e.caseSensitiveMatch===!1||t.includes(pv)||dv.test(t)||mv.test(t)||gv.test(t)||e.extglob!==!1&&yv.test(t)||e.braceExpansion!==!1&&Dv(t))}se.isDynamicPattern=xd;function Dv(t){let e=t.indexOf("{");if(e===-1)return!1;let r=t.indexOf("}",e+1);if(r===-1)return!1;let i=t.slice(e,r);return Ev.test(i)}function bv(t){return ys(t)?t.slice(1):t}se.convertToPositivePattern=bv;function _v(t){return"!"+t}se.convertToNegativePattern=_v;function ys(t){return t.startsWith("!")&&t[1]!=="("}se.isNegativePattern=ys;function Rd(t){return!ys(t)}se.isPositivePattern=Rd;function wv(t){return t.filter(ys)}se.getNegativePatterns=wv;function Sv(t){return t.filter(Rd)}se.getPositivePatterns=Sv;function Av(t){return t.filter(e=>!lu(e))}se.getPatternsInsideCurrentDirectory=Av;function vv(t){return t.filter(lu)}se.getPatternsOutsideCurrentDirectory=vv;function lu(t){return t.startsWith("..")||t.startsWith("./..")}se.isPatternRelatedToParentDirectory=lu;function Cv(t){return fv(t,{flipBackslashes:!1})}se.getBaseDirectory=Cv;function xv(t){return t.includes(vd)}se.hasGlobStar=xv;function Fd(t){return t.endsWith("/"+vd)}se.endsWithSlashGlobStar=Fd;function Rv(t){let e=hv.basename(t);return Fd(t)||Cd(e)}se.isAffectDepthOfReadingPattern=Rv;function Fv(t){return t.reduce((e,r)=>e.concat(Od(r)),[])}se.expandPatternsWithBraceExpansion=Fv;function Od(t){return uu.braces(t,{expand:!0,nodupes:!0})}se.expandBraceExpansion=Od;function Ov(t,e){let{parts:r}=uu.scan(t,Object.assign(Object.assign({},e),{parts:!0}));return r.length===0&&(r=[t]),r[0].startsWith("/")&&(r[0]=r[0].slice(1),r.unshift("")),r}se.getPatternParts=Ov;function kd(t,e){return uu.makeRe(t,e)}se.makeRe=kd;function kv(t,e){return t.map(r=>kd(r,e))}se.convertPatternsToRe=kv;function Tv(t,e){return e.some(r=>r.test(t))}se.matchAny=Tv});var Id=$((qB,Pd)=>{"use strict";var Lv=require("stream"),Ld=Lv.PassThrough,Bv=Array.prototype.slice;Pd.exports=Pv;function Pv(){let t=[],e=Bv.call(arguments),r=!1,i=e[e.length-1];i&&!Array.isArray(i)&&i.pipe==null?e.pop():i={};let n=i.end!==!1,s=i.pipeError===!0;i.objectMode==null&&(i.objectMode=!0),i.highWaterMark==null&&(i.highWaterMark=64*1024);let o=Ld(i);function a(){for(let c=0,f=arguments.length;c<f;c++)t.push(Bd(arguments[c],i));return u(),this}function u(){if(r)return;r=!0;let c=t.shift();if(!c){process.nextTick(l);return}Array.isArray(c)||(c=[c]);let f=c.length+1;function h(){--f>0||(r=!1,u())}function p(g){function y(){g.removeListener("merge2UnpipeEnd",y),g.removeListener("end",y),s&&g.removeListener("error",E),h()}function E(v){o.emit("error",v)}if(g._readableState.endEmitted)return h();g.on("merge2UnpipeEnd",y),g.on("end",y),s&&g.on("error",E),g.pipe(o,{end:!1}),g.resume()}for(let g=0;g<c.length;g++)p(c[g]);h()}function l(){r=!1,o.emit("queueDrain"),n&&o.end()}return o.setMaxListeners(0),o.add=a,o.on("unpipe",function(c){c.emit("merge2UnpipeEnd")}),e.length&&a.apply(null,e),o}function Bd(t,e){if(Array.isArray(t))for(let r=0,i=t.length;r<i;r++)t[r]=Bd(t[r],e);else{if(!t._readableState&&t.pipe&&(t=t.pipe(Ld(e))),!t._readableState||!t.pause||!t.pipe)throw new Error("Only readable stream can be merged.");t.pause()}return t}});var Md=$(Es=>{"use strict";Object.defineProperty(Es,"__esModule",{value:!0});Es.merge=void 0;var Iv=Id();function Nv(t){let e=Iv(t);return t.forEach(r=>{r.once("error",i=>e.emit("error",i))}),e.once("close",()=>Nd(t)),e.once("end",()=>Nd(t)),e}Es.merge=Nv;function Nd(t){t.forEach(e=>e.emit("close"))}});var jd=$(mi=>{"use strict";Object.defineProperty(mi,"__esModule",{value:!0});mi.isEmpty=mi.isString=void 0;function Mv(t){return typeof t=="string"}mi.isString=Mv;function jv(t){return t===""}mi.isEmpty=jv});var $t=$(Te=>{"use strict";Object.defineProperty(Te,"__esModule",{value:!0});Te.string=Te.stream=Te.pattern=Te.path=Te.fs=Te.errno=Te.array=void 0;var $v=op();Te.array=$v;var Hv=ap();Te.errno=Hv;var qv=up();Te.fs=qv;var Uv=lp();Te.path=Uv;var Gv=Td();Te.pattern=Gv;var zv=Md();Te.stream=zv;var Wv=jd();Te.string=Wv});var qd=$(Le=>{"use strict";Object.defineProperty(Le,"__esModule",{value:!0});Le.convertPatternGroupToTask=Le.convertPatternGroupsToTasks=Le.groupPatternsByBaseDirectory=Le.getNegativePatternsAsPositive=Le.getPositivePatterns=Le.convertPatternsToTasks=Le.generate=void 0;var Ht=$t();function Yv(t,e){let r=$d(t),i=Hd(t,e.ignore),n=r.filter(u=>Ht.pattern.isStaticPattern(u,e)),s=r.filter(u=>Ht.pattern.isDynamicPattern(u,e)),o=cu(n,i,!1),a=cu(s,i,!0);return o.concat(a)}Le.generate=Yv;function cu(t,e,r){let i=[],n=Ht.pattern.getPatternsOutsideCurrentDirectory(t),s=Ht.pattern.getPatternsInsideCurrentDirectory(t),o=hu(n),a=hu(s);return i.push(...fu(o,e,r)),"."in a?i.push(pu(".",s,e,r)):i.push(...fu(a,e,r)),i}Le.convertPatternsToTasks=cu;function $d(t){return Ht.pattern.getPositivePatterns(t)}Le.getPositivePatterns=$d;function Hd(t,e){return Ht.pattern.getNegativePatterns(t).concat(e).map(Ht.pattern.convertToPositivePattern)}Le.getNegativePatternsAsPositive=Hd;function hu(t){let e={};return t.reduce((r,i)=>{let n=Ht.pattern.getBaseDirectory(i);return n in r?r[n].push(i):r[n]=[i],r},e)}Le.groupPatternsByBaseDirectory=hu;function fu(t,e,r){return Object.keys(t).map(i=>pu(i,t[i],e,r))}Le.convertPatternGroupsToTasks=fu;function pu(t,e,r,i){return{dynamic:i,positive:e,negative:r,base:t,patterns:[].concat(e,r.map(Ht.pattern.convertToNegativePattern))}}Le.convertPatternGroupToTask=pu});var Gd=$(gi=>{"use strict";Object.defineProperty(gi,"__esModule",{value:!0});gi.removeDuplicateSlashes=gi.transform=void 0;var Vv=/(?!^)\/{2,}/g;function Kv(t){return t.map(e=>Ud(e))}gi.transform=Kv;function Ud(t){return t.replace(Vv,"/")}gi.removeDuplicateSlashes=Ud});var Wd=$(Ds=>{"use strict";Object.defineProperty(Ds,"__esModule",{value:!0});Ds.read=void 0;function Zv(t,e,r){e.fs.lstat(t,(i,n)=>{if(i!==null){zd(r,i);return}if(!n.isSymbolicLink()||!e.followSymbolicLink){du(r,n);return}e.fs.stat(t,(s,o)=>{if(s!==null){if(e.throwErrorOnBrokenSymbolicLink){zd(r,s);return}du(r,n);return}e.markSymbolicLink&&(o.isSymbolicLink=()=>!0),du(r,o)})})}Ds.read=Zv;function zd(t,e){t(e)}function du(t,e){t(null,e)}});var Yd=$(bs=>{"use strict";Object.defineProperty(bs,"__esModule",{value:!0});bs.read=void 0;function Jv(t,e){let r=e.fs.lstatSync(t);if(!r.isSymbolicLink()||!e.followSymbolicLink)return r;try{let i=e.fs.statSync(t);return e.markSymbolicLink&&(i.isSymbolicLink=()=>!0),i}catch(i){if(!e.throwErrorOnBrokenSymbolicLink)return r;throw i}}bs.read=Jv});var Vd=$(or=>{"use strict";Object.defineProperty(or,"__esModule",{value:!0});or.createFileSystemAdapter=or.FILE_SYSTEM_ADAPTER=void 0;var _s=require("fs");or.FILE_SYSTEM_ADAPTER={lstat:_s.lstat,stat:_s.stat,lstatSync:_s.lstatSync,statSync:_s.statSync};function Xv(t){return t===void 0?or.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},or.FILE_SYSTEM_ADAPTER),t)}or.createFileSystemAdapter=Xv});var Kd=$(gu=>{"use strict";Object.defineProperty(gu,"__esModule",{value:!0});var Qv=Vd(),mu=class{constructor(e={}){this._options=e,this.followSymbolicLink=this._getValue(this._options.followSymbolicLink,!0),this.fs=Qv.createFileSystemAdapter(this._options.fs),this.markSymbolicLink=this._getValue(this._options.markSymbolicLink,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0)}_getValue(e,r){return e!=null?e:r}};gu.default=mu});var jr=$(ar=>{"use strict";Object.defineProperty(ar,"__esModule",{value:!0});ar.statSync=ar.stat=ar.Settings=void 0;var Zd=Wd(),e1=Yd(),yu=Kd();ar.Settings=yu.default;function t1(t,e,r){if(typeof e=="function"){Zd.read(t,Eu(),e);return}Zd.read(t,Eu(e),r)}ar.stat=t1;function r1(t,e){let r=Eu(e);return e1.read(t,r)}ar.statSync=r1;function Eu(t={}){return t instanceof yu.default?t:new yu.default(t)}});var Qd=$((QB,Xd)=>{var Jd;Xd.exports=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window!="undefined"?window:global):t=>(Jd||(Jd=Promise.resolve())).then(t).catch(e=>setTimeout(()=>{throw e},0))});var tm=$((eP,em)=>{em.exports=n1;var i1=Qd();function n1(t,e){let r,i,n,s=!0;Array.isArray(t)?(r=[],i=t.length):(n=Object.keys(t),r={},i=n.length);function o(u){function l(){e&&e(u,r),e=null}s?i1(l):l()}function a(u,l,c){r[u]=c,(--i===0||l)&&o(l)}i?n?n.forEach(function(u){t[u](function(l,c){a(u,l,c)})}):t.forEach(function(u,l){u(function(c,f){a(l,c,f)})}):o(null),s=!1}});var Du=$(Ss=>{"use strict";Object.defineProperty(Ss,"__esModule",{value:!0});Ss.IS_SUPPORT_READDIR_WITH_FILE_TYPES=void 0;var ws=process.versions.node.split(".");if(ws[0]===void 0||ws[1]===void 0)throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`);var rm=Number.parseInt(ws[0],10),s1=Number.parseInt(ws[1],10),im=10,o1=10,a1=rm>im,u1=rm===im&&s1>=o1;Ss.IS_SUPPORT_READDIR_WITH_FILE_TYPES=a1||u1});var nm=$(As=>{"use strict";Object.defineProperty(As,"__esModule",{value:!0});As.createDirentFromStats=void 0;var bu=class{constructor(e,r){this.name=e,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function l1(t,e){return new bu(t,e)}As.createDirentFromStats=l1});var _u=$(vs=>{"use strict";Object.defineProperty(vs,"__esModule",{value:!0});vs.fs=void 0;var c1=nm();vs.fs=c1});var wu=$(Cs=>{"use strict";Object.defineProperty(Cs,"__esModule",{value:!0});Cs.joinPathSegments=void 0;function h1(t,e,r){return t.endsWith(r)?t+e:t+r+e}Cs.joinPathSegments=h1});var cm=$(ur=>{"use strict";Object.defineProperty(ur,"__esModule",{value:!0});ur.readdir=ur.readdirWithFileTypes=ur.read=void 0;var f1=jr(),sm=tm(),p1=Du(),om=_u(),am=wu();function d1(t,e,r){if(!e.stats&&p1.IS_SUPPORT_READDIR_WITH_FILE_TYPES){um(t,e,r);return}lm(t,e,r)}ur.read=d1;function um(t,e,r){e.fs.readdir(t,{withFileTypes:!0},(i,n)=>{if(i!==null){xs(r,i);return}let s=n.map(a=>({dirent:a,name:a.name,path:am.joinPathSegments(t,a.name,e.pathSegmentSeparator)}));if(!e.followSymbolicLinks){Su(r,s);return}let o=s.map(a=>m1(a,e));sm(o,(a,u)=>{if(a!==null){xs(r,a);return}Su(r,u)})})}ur.readdirWithFileTypes=um;function m1(t,e){return r=>{if(!t.dirent.isSymbolicLink()){r(null,t);return}e.fs.stat(t.path,(i,n)=>{if(i!==null){if(e.throwErrorOnBrokenSymbolicLink){r(i);return}r(null,t);return}t.dirent=om.fs.createDirentFromStats(t.name,n),r(null,t)})}}function lm(t,e,r){e.fs.readdir(t,(i,n)=>{if(i!==null){xs(r,i);return}let s=n.map(o=>{let a=am.joinPathSegments(t,o,e.pathSegmentSeparator);return u=>{f1.stat(a,e.fsStatSettings,(l,c)=>{if(l!==null){u(l);return}let f={name:o,path:a,dirent:om.fs.createDirentFromStats(o,c)};e.stats&&(f.stats=c),u(null,f)})}});sm(s,(o,a)=>{if(o!==null){xs(r,o);return}Su(r,a)})})}ur.readdir=lm;function xs(t,e){t(e)}function Su(t,e){t(null,e)}});var mm=$(lr=>{"use strict";Object.defineProperty(lr,"__esModule",{value:!0});lr.readdir=lr.readdirWithFileTypes=lr.read=void 0;var g1=jr(),y1=Du(),hm=_u(),fm=wu();function E1(t,e){return!e.stats&&y1.IS_SUPPORT_READDIR_WITH_FILE_TYPES?pm(t,e):dm(t,e)}lr.read=E1;function pm(t,e){return e.fs.readdirSync(t,{withFileTypes:!0}).map(i=>{let n={dirent:i,name:i.name,path:fm.joinPathSegments(t,i.name,e.pathSegmentSeparator)};if(n.dirent.isSymbolicLink()&&e.followSymbolicLinks)try{let s=e.fs.statSync(n.path);n.dirent=hm.fs.createDirentFromStats(n.name,s)}catch(s){if(e.throwErrorOnBrokenSymbolicLink)throw s}return n})}lr.readdirWithFileTypes=pm;function dm(t,e){return e.fs.readdirSync(t).map(i=>{let n=fm.joinPathSegments(t,i,e.pathSegmentSeparator),s=g1.statSync(n,e.fsStatSettings),o={name:i,path:n,dirent:hm.fs.createDirentFromStats(i,s)};return e.stats&&(o.stats=s),o})}lr.readdir=dm});var gm=$(cr=>{"use strict";Object.defineProperty(cr,"__esModule",{value:!0});cr.createFileSystemAdapter=cr.FILE_SYSTEM_ADAPTER=void 0;var yi=require("fs");cr.FILE_SYSTEM_ADAPTER={lstat:yi.lstat,stat:yi.stat,lstatSync:yi.lstatSync,statSync:yi.statSync,readdir:yi.readdir,readdirSync:yi.readdirSync};function D1(t){return t===void 0?cr.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},cr.FILE_SYSTEM_ADAPTER),t)}cr.createFileSystemAdapter=D1});var ym=$(vu=>{"use strict";Object.defineProperty(vu,"__esModule",{value:!0});var b1=require("path"),_1=jr(),w1=gm(),Au=class{constructor(e={}){this._options=e,this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!1),this.fs=w1.createFileSystemAdapter(this._options.fs),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,b1.sep),this.stats=this._getValue(this._options.stats,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0),this.fsStatSettings=new _1.Settings({followSymbolicLink:this.followSymbolicLinks,fs:this.fs,throwErrorOnBrokenSymbolicLink:this.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};vu.default=Au});var Rs=$(hr=>{"use strict";Object.defineProperty(hr,"__esModule",{value:!0});hr.Settings=hr.scandirSync=hr.scandir=void 0;var Em=cm(),S1=mm(),Cu=ym();hr.Settings=Cu.default;function A1(t,e,r){if(typeof e=="function"){Em.read(t,xu(),e);return}Em.read(t,xu(e),r)}hr.scandir=A1;function v1(t,e){let r=xu(e);return S1.read(t,r)}hr.scandirSync=v1;function xu(t={}){return t instanceof Cu.default?t:new Cu.default(t)}});var bm=$((cP,Dm)=>{"use strict";function C1(t){var e=new t,r=e;function i(){var s=e;return s.next?e=s.next:(e=new t,r=e),s.next=null,s}function n(s){r.next=s,r=s}return{get:i,release:n}}Dm.exports=C1});var wm=$((hP,Ru)=>{"use strict";var x1=bm();function _m(t,e,r){if(typeof t=="function"&&(r=e,e=t,t=null),r<1)throw new Error("fastqueue concurrency must be greater than 1");var i=x1(R1),n=null,s=null,o=0,a=null,u={push:y,drain:nt,saturated:nt,pause:c,paused:!1,concurrency:r,running:l,resume:p,idle:g,length:f,getQueue:h,unshift:E,empty:nt,kill:F,killAndDrain:O,error:R};return u;function l(){return o}function c(){u.paused=!0}function f(){for(var x=n,L=0;x;)x=x.next,L++;return L}function h(){for(var x=n,L=[];x;)L.push(x.value),x=x.next;return L}function p(){if(u.paused){u.paused=!1;for(var x=0;x<u.concurrency;x++)o++,v()}}function g(){return o===0&&u.length()===0}function y(x,L){var b=i.get();b.context=t,b.release=v,b.value=x,b.callback=L||nt,b.errorHandler=a,o===u.concurrency||u.paused?s?(s.next=b,s=b):(n=b,s=b,u.saturated()):(o++,e.call(t,b.value,b.worked))}function E(x,L){var b=i.get();b.context=t,b.release=v,b.value=x,b.callback=L||nt,o===u.concurrency||u.paused?n?(b.next=n,n=b):(n=b,s=b,u.saturated()):(o++,e.call(t,b.value,b.worked))}function v(x){x&&i.release(x);var L=n;L?u.paused?o--:(s===n&&(s=null),n=L.next,L.next=null,e.call(t,L.value,L.worked),s===null&&u.empty()):--o===0&&u.drain()}function F(){n=null,s=null,u.drain=nt}function O(){n=null,s=null,u.drain(),u.drain=nt}function R(x){a=x}}function nt(){}function R1(){this.value=null,this.callback=nt,this.next=null,this.release=nt,this.context=null,this.errorHandler=null;var t=this;this.worked=function(r,i){var n=t.callback,s=t.errorHandler,o=t.value;t.value=null,t.callback=nt,t.errorHandler&&s(r,o),n.call(t.context,r,i),t.release(t)}}function F1(t,e,r){typeof t=="function"&&(r=e,e=t,t=null);function i(c,f){e.call(this,c).then(function(h){f(null,h)},f)}var n=_m(t,i,r),s=n.push,o=n.unshift;return n.push=a,n.unshift=u,n.drained=l,n;function a(c){var f=new Promise(function(h,p){s(c,function(g,y){if(g){p(g);return}h(y)})});return f.catch(nt),f}function u(c){var f=new Promise(function(h,p){o(c,function(g,y){if(g){p(g);return}h(y)})});return f.catch(nt),f}function l(){var c=n.drain,f=new Promise(function(h){n.drain=function(){c(),h()}});return f}}Ru.exports=_m;Ru.exports.promise=F1});var Fs=$(wt=>{"use strict";Object.defineProperty(wt,"__esModule",{value:!0});wt.joinPathSegments=wt.replacePathSegmentSeparator=wt.isAppliedFilter=wt.isFatalError=void 0;function O1(t,e){return t.errorFilter===null?!0:!t.errorFilter(e)}wt.isFatalError=O1;function k1(t,e){return t===null||t(e)}wt.isAppliedFilter=k1;function T1(t,e){return t.split(/[/\\]/).join(e)}wt.replacePathSegmentSeparator=T1;function L1(t,e,r){return t===""?e:t.endsWith(r)?t+e:t+r+e}wt.joinPathSegments=L1});var ku=$(Ou=>{"use strict";Object.defineProperty(Ou,"__esModule",{value:!0});var B1=Fs(),Fu=class{constructor(e,r){this._root=e,this._settings=r,this._root=B1.replacePathSegmentSeparator(e,r.pathSegmentSeparator)}};Ou.default=Fu});var Bu=$(Lu=>{"use strict";Object.defineProperty(Lu,"__esModule",{value:!0});var P1=require("events"),I1=Rs(),N1=wm(),Os=Fs(),M1=ku(),Tu=class extends M1.default{constructor(e,r){super(e,r),this._settings=r,this._scandir=I1.scandir,this._emitter=new P1.EventEmitter,this._queue=N1(this._worker.bind(this),this._settings.concurrency),this._isFatalError=!1,this._isDestroyed=!1,this._queue.drain=()=>{this._isFatalError||this._emitter.emit("end")}}read(){return this._isFatalError=!1,this._isDestroyed=!1,setImmediate(()=>{this._pushToQueue(this._root,this._settings.basePath)}),this._emitter}get isDestroyed(){return this._isDestroyed}destroy(){if(this._isDestroyed)throw new Error("The reader is already destroyed");this._isDestroyed=!0,this._queue.killAndDrain()}onEntry(e){this._emitter.on("entry",e)}onError(e){this._emitter.once("error",e)}onEnd(e){this._emitter.once("end",e)}_pushToQueue(e,r){let i={directory:e,base:r};this._queue.push(i,n=>{n!==null&&this._handleError(n)})}_worker(e,r){this._scandir(e.directory,this._settings.fsScandirSettings,(i,n)=>{if(i!==null){r(i,void 0);return}for(let s of n)this._handleEntry(s,e.base);r(null,void 0)})}_handleError(e){this._isDestroyed||!Os.isFatalError(this._settings,e)||(this._isFatalError=!0,this._isDestroyed=!0,this._emitter.emit("error",e))}_handleEntry(e,r){if(this._isDestroyed||this._isFatalError)return;let i=e.path;r!==void 0&&(e.path=Os.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),Os.isAppliedFilter(this._settings.entryFilter,e)&&this._emitEntry(e),e.dirent.isDirectory()&&Os.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,r===void 0?void 0:e.path)}_emitEntry(e){this._emitter.emit("entry",e)}};Lu.default=Tu});var Sm=$(Iu=>{"use strict";Object.defineProperty(Iu,"__esModule",{value:!0});var j1=Bu(),Pu=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new j1.default(this._root,this._settings),this._storage=[]}read(e){this._reader.onError(r=>{$1(e,r)}),this._reader.onEntry(r=>{this._storage.push(r)}),this._reader.onEnd(()=>{H1(e,this._storage)}),this._reader.read()}};Iu.default=Pu;function $1(t,e){t(e)}function H1(t,e){t(null,e)}});var Am=$(Mu=>{"use strict";Object.defineProperty(Mu,"__esModule",{value:!0});var q1=require("stream"),U1=Bu(),Nu=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new U1.default(this._root,this._settings),this._stream=new q1.Readable({objectMode:!0,read:()=>{},destroy:()=>{this._reader.isDestroyed||this._reader.destroy()}})}read(){return this._reader.onError(e=>{this._stream.emit("error",e)}),this._reader.onEntry(e=>{this._stream.push(e)}),this._reader.onEnd(()=>{this._stream.push(null)}),this._reader.read(),this._stream}};Mu.default=Nu});var vm=$($u=>{"use strict";Object.defineProperty($u,"__esModule",{value:!0});var G1=Rs(),ks=Fs(),z1=ku(),ju=class extends z1.default{constructor(){super(...arguments),this._scandir=G1.scandirSync,this._storage=[],this._queue=new Set}read(){return this._pushToQueue(this._root,this._settings.basePath),this._handleQueue(),this._storage}_pushToQueue(e,r){this._queue.add({directory:e,base:r})}_handleQueue(){for(let e of this._queue.values())this._handleDirectory(e.directory,e.base)}_handleDirectory(e,r){try{let i=this._scandir(e,this._settings.fsScandirSettings);for(let n of i)this._handleEntry(n,r)}catch(i){this._handleError(i)}}_handleError(e){if(ks.isFatalError(this._settings,e))throw e}_handleEntry(e,r){let i=e.path;r!==void 0&&(e.path=ks.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),ks.isAppliedFilter(this._settings.entryFilter,e)&&this._pushToStorage(e),e.dirent.isDirectory()&&ks.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,r===void 0?void 0:e.path)}_pushToStorage(e){this._storage.push(e)}};$u.default=ju});var Cm=$(qu=>{"use strict";Object.defineProperty(qu,"__esModule",{value:!0});var W1=vm(),Hu=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new W1.default(this._root,this._settings)}read(){return this._reader.read()}};qu.default=Hu});var xm=$(Gu=>{"use strict";Object.defineProperty(Gu,"__esModule",{value:!0});var Y1=require("path"),V1=Rs(),Uu=class{constructor(e={}){this._options=e,this.basePath=this._getValue(this._options.basePath,void 0),this.concurrency=this._getValue(this._options.concurrency,Number.POSITIVE_INFINITY),this.deepFilter=this._getValue(this._options.deepFilter,null),this.entryFilter=this._getValue(this._options.entryFilter,null),this.errorFilter=this._getValue(this._options.errorFilter,null),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,Y1.sep),this.fsScandirSettings=new V1.Settings({followSymbolicLinks:this._options.followSymbolicLinks,fs:this._options.fs,pathSegmentSeparator:this._options.pathSegmentSeparator,stats:this._options.stats,throwErrorOnBrokenSymbolicLink:this._options.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};Gu.default=Uu});var Ls=$(St=>{"use strict";Object.defineProperty(St,"__esModule",{value:!0});St.Settings=St.walkStream=St.walkSync=St.walk=void 0;var Rm=Sm(),K1=Am(),Z1=Cm(),zu=xm();St.Settings=zu.default;function J1(t,e,r){if(typeof e=="function"){new Rm.default(t,Ts()).read(e);return}new Rm.default(t,Ts(e)).read(r)}St.walk=J1;function X1(t,e){let r=Ts(e);return new Z1.default(t,r).read()}St.walkSync=X1;function Q1(t,e){let r=Ts(e);return new K1.default(t,r).read()}St.walkStream=Q1;function Ts(t={}){return t instanceof zu.default?t:new zu.default(t)}});var Bs=$(Yu=>{"use strict";Object.defineProperty(Yu,"__esModule",{value:!0});var eC=require("path"),tC=jr(),Fm=$t(),Wu=class{constructor(e){this._settings=e,this._fsStatSettings=new tC.Settings({followSymbolicLink:this._settings.followSymbolicLinks,fs:this._settings.fs,throwErrorOnBrokenSymbolicLink:this._settings.followSymbolicLinks})}_getFullEntryPath(e){return eC.resolve(this._settings.cwd,e)}_makeEntry(e,r){let i={name:r,path:r,dirent:Fm.fs.createDirentFromStats(r,e)};return this._settings.stats&&(i.stats=e),i}_isFatalError(e){return!Fm.errno.isEnoentCodeError(e)&&!this._settings.suppressErrors}};Yu.default=Wu});var Zu=$(Ku=>{"use strict";Object.defineProperty(Ku,"__esModule",{value:!0});var rC=require("stream"),iC=jr(),nC=Ls(),sC=Bs(),Vu=class extends sC.default{constructor(){super(...arguments),this._walkStream=nC.walkStream,this._stat=iC.stat}dynamic(e,r){return this._walkStream(e,r)}static(e,r){let i=e.map(this._getFullEntryPath,this),n=new rC.PassThrough({objectMode:!0});n._write=(s,o,a)=>this._getEntry(i[s],e[s],r).then(u=>{u!==null&&r.entryFilter(u)&&n.push(u),s===i.length-1&&n.end(),a()}).catch(a);for(let s=0;s<i.length;s++)n.write(s);return n}_getEntry(e,r,i){return this._getStat(e).then(n=>this._makeEntry(n,r)).catch(n=>{if(i.errorFilter(n))return null;throw n})}_getStat(e){return new Promise((r,i)=>{this._stat(e,this._fsStatSettings,(n,s)=>n===null?r(s):i(n))})}};Ku.default=Vu});var Om=$(Xu=>{"use strict";Object.defineProperty(Xu,"__esModule",{value:!0});var oC=Ls(),aC=Bs(),uC=Zu(),Ju=class extends aC.default{constructor(){super(...arguments),this._walkAsync=oC.walk,this._readerStream=new uC.default(this._settings)}dynamic(e,r){return new Promise((i,n)=>{this._walkAsync(e,r,(s,o)=>{s===null?i(o):n(s)})})}async static(e,r){let i=[],n=this._readerStream.static(e,r);return new Promise((s,o)=>{n.once("error",o),n.on("data",a=>i.push(a)),n.once("end",()=>s(i))})}};Xu.default=Ju});var km=$(el=>{"use strict";Object.defineProperty(el,"__esModule",{value:!0});var Ei=$t(),Qu=class{constructor(e,r,i){this._patterns=e,this._settings=r,this._micromatchOptions=i,this._storage=[],this._fillStorage()}_fillStorage(){let e=Ei.pattern.expandPatternsWithBraceExpansion(this._patterns);for(let r of e){let i=this._getPatternSegments(r),n=this._splitSegmentsIntoSections(i);this._storage.push({complete:n.length<=1,pattern:r,segments:i,sections:n})}}_getPatternSegments(e){return Ei.pattern.getPatternParts(e,this._micromatchOptions).map(i=>Ei.pattern.isDynamicPattern(i,this._settings)?{dynamic:!0,pattern:i,patternRe:Ei.pattern.makeRe(i,this._micromatchOptions)}:{dynamic:!1,pattern:i})}_splitSegmentsIntoSections(e){return Ei.array.splitWhen(e,r=>r.dynamic&&Ei.pattern.hasGlobStar(r.pattern))}};el.default=Qu});var Tm=$(rl=>{"use strict";Object.defineProperty(rl,"__esModule",{value:!0});var lC=km(),tl=class extends lC.default{match(e){let r=e.split("/"),i=r.length,n=this._storage.filter(s=>!s.complete||s.segments.length>i);for(let s of n){let o=s.sections[0];if(!s.complete&&i>o.length||r.every((u,l)=>{let c=s.segments[l];return!!(c.dynamic&&c.patternRe.test(u)||!c.dynamic&&c.pattern===u)}))return!0}return!1}};rl.default=tl});var Lm=$(nl=>{"use strict";Object.defineProperty(nl,"__esModule",{value:!0});var Ps=$t(),cC=Tm(),il=class{constructor(e,r){this._settings=e,this._micromatchOptions=r}getFilter(e,r,i){let n=this._getMatcher(r),s=this._getNegativePatternsRe(i);return o=>this._filter(e,o,n,s)}_getMatcher(e){return new cC.default(e,this._settings,this._micromatchOptions)}_getNegativePatternsRe(e){let r=e.filter(Ps.pattern.isAffectDepthOfReadingPattern);return Ps.pattern.convertPatternsToRe(r,this._micromatchOptions)}_filter(e,r,i,n){if(this._isSkippedByDeep(e,r.path)||this._isSkippedSymbolicLink(r))return!1;let s=Ps.path.removeLeadingDotSegment(r.path);return this._isSkippedByPositivePatterns(s,i)?!1:this._isSkippedByNegativePatterns(s,n)}_isSkippedByDeep(e,r){return this._settings.deep===1/0?!1:this._getEntryLevel(e,r)>=this._settings.deep}_getEntryLevel(e,r){let i=r.split("/").length;if(e==="")return i;let n=e.split("/").length;return i-n}_isSkippedSymbolicLink(e){return!this._settings.followSymbolicLinks&&e.dirent.isSymbolicLink()}_isSkippedByPositivePatterns(e,r){return!this._settings.baseNameMatch&&!r.match(e)}_isSkippedByNegativePatterns(e,r){return!Ps.pattern.matchAny(e,r)}};nl.default=il});var Bm=$(ol=>{"use strict";Object.defineProperty(ol,"__esModule",{value:!0});var $r=$t(),sl=class{constructor(e,r){this._settings=e,this._micromatchOptions=r,this.index=new Map}getFilter(e,r){let i=$r.pattern.convertPatternsToRe(e,this._micromatchOptions),n=$r.pattern.convertPatternsToRe(r,this._micromatchOptions);return s=>this._filter(s,i,n)}_filter(e,r,i){if(this._settings.unique&&this._isDuplicateEntry(e)||this._onlyFileFilter(e)||this._onlyDirectoryFilter(e)||this._isSkippedByAbsoluteNegativePatterns(e.path,i))return!1;let n=this._settings.baseNameMatch?e.name:e.path,s=e.dirent.isDirectory(),o=this._isMatchToPatterns(n,r,s)&&!this._isMatchToPatterns(e.path,i,s);return this._settings.unique&&o&&this._createIndexRecord(e),o}_isDuplicateEntry(e){return this.index.has(e.path)}_createIndexRecord(e){this.index.set(e.path,void 0)}_onlyFileFilter(e){return this._settings.onlyFiles&&!e.dirent.isFile()}_onlyDirectoryFilter(e){return this._settings.onlyDirectories&&!e.dirent.isDirectory()}_isSkippedByAbsoluteNegativePatterns(e,r){if(!this._settings.absolute)return!1;let i=$r.path.makeAbsolute(this._settings.cwd,e);return $r.pattern.matchAny(i,r)}_isMatchToPatterns(e,r,i){let n=$r.path.removeLeadingDotSegment(e),s=$r.pattern.matchAny(n,r);return!s&&i?$r.pattern.matchAny(n+"/",r):s}};ol.default=sl});var Pm=$(ul=>{"use strict";Object.defineProperty(ul,"__esModule",{value:!0});var hC=$t(),al=class{constructor(e){this._settings=e}getFilter(){return e=>this._isNonFatalError(e)}_isNonFatalError(e){return hC.errno.isEnoentCodeError(e)||this._settings.suppressErrors}};ul.default=al});var Nm=$(cl=>{"use strict";Object.defineProperty(cl,"__esModule",{value:!0});var Im=$t(),ll=class{constructor(e){this._settings=e}getTransformer(){return e=>this._transform(e)}_transform(e){let r=e.path;return this._settings.absolute&&(r=Im.path.makeAbsolute(this._settings.cwd,r),r=Im.path.unixify(r)),this._settings.markDirectories&&e.dirent.isDirectory()&&(r+="/"),this._settings.objectMode?Object.assign(Object.assign({},e),{path:r}):r}};cl.default=ll});var Is=$(fl=>{"use strict";Object.defineProperty(fl,"__esModule",{value:!0});var fC=require("path"),pC=Lm(),dC=Bm(),mC=Pm(),gC=Nm(),hl=class{constructor(e){this._settings=e,this.errorFilter=new mC.default(this._settings),this.entryFilter=new dC.default(this._settings,this._getMicromatchOptions()),this.deepFilter=new pC.default(this._settings,this._getMicromatchOptions()),this.entryTransformer=new gC.default(this._settings)}_getRootDirectory(e){return fC.resolve(this._settings.cwd,e.base)}_getReaderOptions(e){let r=e.base==="."?"":e.base;return{basePath:r,pathSegmentSeparator:"/",concurrency:this._settings.concurrency,deepFilter:this.deepFilter.getFilter(r,e.positive,e.negative),entryFilter:this.entryFilter.getFilter(e.positive,e.negative),errorFilter:this.errorFilter.getFilter(),followSymbolicLinks:this._settings.followSymbolicLinks,fs:this._settings.fs,stats:this._settings.stats,throwErrorOnBrokenSymbolicLink:this._settings.throwErrorOnBrokenSymbolicLink,transform:this.entryTransformer.getTransformer()}}_getMicromatchOptions(){return{dot:this._settings.dot,matchBase:this._settings.baseNameMatch,nobrace:!this._settings.braceExpansion,nocase:!this._settings.caseSensitiveMatch,noext:!this._settings.extglob,noglobstar:!this._settings.globstar,posix:!0,strictSlashes:!1}}};fl.default=hl});var Mm=$(dl=>{"use strict";Object.defineProperty(dl,"__esModule",{value:!0});var yC=Om(),EC=Is(),pl=class extends EC.default{constructor(){super(...arguments),this._reader=new yC.default(this._settings)}async read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e);return(await this.api(r,e,i)).map(s=>i.transform(s))}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};dl.default=pl});var jm=$(gl=>{"use strict";Object.defineProperty(gl,"__esModule",{value:!0});var DC=require("stream"),bC=Zu(),_C=Is(),ml=class extends _C.default{constructor(){super(...arguments),this._reader=new bC.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e),n=this.api(r,e,i),s=new DC.Readable({objectMode:!0,read:()=>{}});return n.once("error",o=>s.emit("error",o)).on("data",o=>s.emit("data",i.transform(o))).once("end",()=>s.emit("end")),s.once("close",()=>n.destroy()),s}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};gl.default=ml});var $m=$(El=>{"use strict";Object.defineProperty(El,"__esModule",{value:!0});var wC=jr(),SC=Ls(),AC=Bs(),yl=class extends AC.default{constructor(){super(...arguments),this._walkSync=SC.walkSync,this._statSync=wC.statSync}dynamic(e,r){return this._walkSync(e,r)}static(e,r){let i=[];for(let n of e){let s=this._getFullEntryPath(n),o=this._getEntry(s,n,r);o===null||!r.entryFilter(o)||i.push(o)}return i}_getEntry(e,r,i){try{let n=this._getStat(e);return this._makeEntry(n,r)}catch(n){if(i.errorFilter(n))return null;throw n}}_getStat(e){return this._statSync(e,this._fsStatSettings)}};El.default=yl});var Hm=$(bl=>{"use strict";Object.defineProperty(bl,"__esModule",{value:!0});var vC=$m(),CC=Is(),Dl=class extends CC.default{constructor(){super(...arguments),this._reader=new vC.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e);return this.api(r,e,i).map(i.transform)}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};bl.default=Dl});var qm=$(bi=>{"use strict";Object.defineProperty(bi,"__esModule",{value:!0});bi.DEFAULT_FILE_SYSTEM_ADAPTER=void 0;var Di=require("fs"),xC=require("os"),RC=Math.max(xC.cpus().length,1);bi.DEFAULT_FILE_SYSTEM_ADAPTER={lstat:Di.lstat,lstatSync:Di.lstatSync,stat:Di.stat,statSync:Di.statSync,readdir:Di.readdir,readdirSync:Di.readdirSync};var _l=class{constructor(e={}){this._options=e,this.absolute=this._getValue(this._options.absolute,!1),this.baseNameMatch=this._getValue(this._options.baseNameMatch,!1),this.braceExpansion=this._getValue(this._options.braceExpansion,!0),this.caseSensitiveMatch=this._getValue(this._options.caseSensitiveMatch,!0),this.concurrency=this._getValue(this._options.concurrency,RC),this.cwd=this._getValue(this._options.cwd,process.cwd()),this.deep=this._getValue(this._options.deep,1/0),this.dot=this._getValue(this._options.dot,!1),this.extglob=this._getValue(this._options.extglob,!0),this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!0),this.fs=this._getFileSystemMethods(this._options.fs),this.globstar=this._getValue(this._options.globstar,!0),this.ignore=this._getValue(this._options.ignore,[]),this.markDirectories=this._getValue(this._options.markDirectories,!1),this.objectMode=this._getValue(this._options.objectMode,!1),this.onlyDirectories=this._getValue(this._options.onlyDirectories,!1),this.onlyFiles=this._getValue(this._options.onlyFiles,!0),this.stats=this._getValue(this._options.stats,!1),this.suppressErrors=this._getValue(this._options.suppressErrors,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!1),this.unique=this._getValue(this._options.unique,!0),this.onlyDirectories&&(this.onlyFiles=!1),this.stats&&(this.objectMode=!0)}_getValue(e,r){return e===void 0?r:e}_getFileSystemMethods(e={}){return Object.assign(Object.assign({},bi.DEFAULT_FILE_SYSTEM_ADAPTER),e)}};bi.default=_l});var Ns=$((IP,zm)=>{"use strict";var Um=qd(),Gm=Gd(),FC=Mm(),OC=jm(),kC=Hm(),wl=qm(),Hr=$t();async function Sl(t,e){_i(t);let r=Al(t,FC.default,e),i=await Promise.all(r);return Hr.array.flatten(i)}(function(t){function e(o,a){_i(o);let u=Al(o,kC.default,a);return Hr.array.flatten(u)}t.sync=e;function r(o,a){_i(o);let u=Al(o,OC.default,a);return Hr.stream.merge(u)}t.stream=r;function i(o,a){_i(o);let u=Gm.transform([].concat(o)),l=new wl.default(a);return Um.generate(u,l)}t.generateTasks=i;function n(o,a){_i(o);let u=new wl.default(a);return Hr.pattern.isDynamicPattern(o,u)}t.isDynamicPattern=n;function s(o){return _i(o),Hr.path.escape(o)}t.escapePath=s})(Sl||(Sl={}));function Al(t,e,r){let i=Gm.transform([].concat(t)),n=new wl.default(r),s=Um.generate(i,n),o=new e(n);return s.map(o.read,o)}function _i(t){if(![].concat(t).every(i=>Hr.string.isString(i)&&!Hr.string.isEmpty(i)))throw new TypeError("Patterns must be a string (non empty) or an array of strings")}zm.exports=Sl});var s0=$((HP,n0)=>{n0.exports=i0;i0.sync=zC;var t0=require("fs");function GC(t,e){var r=e.pathExt!==void 0?e.pathExt:process.env.PATHEXT;if(!r||(r=r.split(";"),r.indexOf("")!==-1))return!0;for(var i=0;i<r.length;i++){var n=r[i].toLowerCase();if(n&&t.substr(-n.length).toLowerCase()===n)return!0}return!1}function r0(t,e,r){return!t.isSymbolicLink()&&!t.isFile()?!1:GC(e,r)}function i0(t,e,r){t0.stat(t,function(i,n){r(i,i?!1:r0(n,t,e))})}function zC(t,e){return r0(t0.statSync(t),t,e)}});var c0=$((qP,l0)=>{l0.exports=a0;a0.sync=WC;var o0=require("fs");function a0(t,e,r){o0.stat(t,function(i,n){r(i,i?!1:u0(n,e))})}function WC(t,e){return u0(o0.statSync(t),e)}function u0(t,e){return t.isFile()&&YC(t,e)}function YC(t,e){var r=t.mode,i=t.uid,n=t.gid,s=e.uid!==void 0?e.uid:process.getuid&&process.getuid(),o=e.gid!==void 0?e.gid:process.getgid&&process.getgid(),a=parseInt("100",8),u=parseInt("010",8),l=parseInt("001",8),c=a|u,f=r&l||r&u&&n===o||r&a&&i===s||r&c&&s===0;return f}});var f0=$((GP,h0)=>{var UP=require("fs"),Ms;process.platform==="win32"||global.TESTING_WINDOWS?Ms=s0():Ms=c0();h0.exports=vl;vl.sync=VC;function vl(t,e,r){if(typeof e=="function"&&(r=e,e={}),!r){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(i,n){vl(t,e||{},function(s,o){s?n(s):i(o)})})}Ms(t,e||{},function(i,n){i&&(i.code==="EACCES"||e&&e.ignoreErrors)&&(i=null,n=!1),r(i,n)})}function VC(t,e){try{return Ms.sync(t,e||{})}catch(r){if(e&&e.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var D0=$((zP,E0)=>{var Si=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",p0=require("path"),KC=Si?";":":",d0=f0(),m0=t=>Object.assign(new Error(`not found: ${t}`),{code:"ENOENT"}),g0=(t,e)=>{let r=e.colon||KC,i=t.match(/\//)||Si&&t.match(/\\/)?[""]:[...Si?[process.cwd()]:[],...(e.path||process.env.PATH||"").split(r)],n=Si?e.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",s=Si?n.split(r):[""];return Si&&t.indexOf(".")!==-1&&s[0]!==""&&s.unshift(""),{pathEnv:i,pathExt:s,pathExtExe:n}},y0=(t,e,r)=>{typeof e=="function"&&(r=e,e={}),e||(e={});let{pathEnv:i,pathExt:n,pathExtExe:s}=g0(t,e),o=[],a=l=>new Promise((c,f)=>{if(l===i.length)return e.all&&o.length?c(o):f(m0(t));let h=i[l],p=/^".*"$/.test(h)?h.slice(1,-1):h,g=p0.join(p,t),y=!p&&/^\.[\\\/]/.test(t)?t.slice(0,2)+g:g;c(u(y,l,0))}),u=(l,c,f)=>new Promise((h,p)=>{if(f===n.length)return h(a(c+1));let g=n[f];d0(l+g,{pathExt:s},(y,E)=>{if(!y&&E)if(e.all)o.push(l+g);else return h(l+g);return h(u(l,c,f+1))})});return r?a(0).then(l=>r(null,l),r):a(0)},ZC=(t,e)=>{e=e||{};let{pathEnv:r,pathExt:i,pathExtExe:n}=g0(t,e),s=[];for(let o=0;o<r.length;o++){let a=r[o],u=/^".*"$/.test(a)?a.slice(1,-1):a,l=p0.join(u,t),c=!u&&/^\.[\\\/]/.test(t)?t.slice(0,2)+l:l;for(let f=0;f<i.length;f++){let h=c+i[f];try{if(d0.sync(h,{pathExt:n}))if(e.all)s.push(h);else return h}catch{}}}if(e.all&&s.length)return s;if(e.nothrow)return null;throw m0(t)};E0.exports=y0;y0.sync=ZC});var xl=$((WP,Cl)=>{"use strict";var b0=(t={})=>{let e=t.env||process.env;return(t.platform||process.platform)!=="win32"?"PATH":Object.keys(e).reverse().find(i=>i.toUpperCase()==="PATH")||"Path"};Cl.exports=b0;Cl.exports.default=b0});var A0=$((YP,S0)=>{"use strict";var _0=require("path"),JC=D0(),XC=xl();function w0(t,e){let r=t.options.env||process.env,i=process.cwd(),n=t.options.cwd!=null,s=n&&process.chdir!==void 0&&!process.chdir.disabled;if(s)try{process.chdir(t.options.cwd)}catch{}let o;try{o=JC.sync(t.command,{path:r[XC({env:r})],pathExt:e?_0.delimiter:void 0})}catch{}finally{s&&process.chdir(i)}return o&&(o=_0.resolve(n?t.options.cwd:"",o)),o}function QC(t){return w0(t)||w0(t,!0)}S0.exports=QC});var v0=$((VP,Fl)=>{"use strict";var Rl=/([()\][%!^"`<>&|;, *?])/g;function ex(t){return t=t.replace(Rl,"^$1"),t}function tx(t,e){return t=`${t}`,t=t.replace(/(\\*)"/g,'$1$1\\"'),t=t.replace(/(\\*)$/,"$1$1"),t=`"${t}"`,t=t.replace(Rl,"^$1"),e&&(t=t.replace(Rl,"^$1")),t}Fl.exports.command=ex;Fl.exports.argument=tx});var x0=$((KP,C0)=>{"use strict";C0.exports=/^#!(.*)/});var F0=$((ZP,R0)=>{"use strict";var rx=x0();R0.exports=(t="")=>{let e=t.match(rx);if(!e)return null;let[r,i]=e[0].replace(/#! ?/,"").split(" "),n=r.split("/").pop();return n==="env"?i:i?`${n} ${i}`:n}});var k0=$((JP,O0)=>{"use strict";var Ol=require("fs"),ix=F0();function nx(t){let r=Buffer.alloc(150),i;try{i=Ol.openSync(t,"r"),Ol.readSync(i,r,0,150,0),Ol.closeSync(i)}catch{}return ix(r.toString())}O0.exports=nx});var P0=$((XP,B0)=>{"use strict";var sx=require("path"),T0=A0(),L0=v0(),ox=k0(),ax=process.platform==="win32",ux=/\.(?:com|exe)$/i,lx=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function cx(t){t.file=T0(t);let e=t.file&&ox(t.file);return e?(t.args.unshift(t.file),t.command=e,T0(t)):t.file}function hx(t){if(!ax)return t;let e=cx(t),r=!ux.test(e);if(t.options.forceShell||r){let i=lx.test(e);t.command=sx.normalize(t.command),t.command=L0.command(t.command),t.args=t.args.map(s=>L0.argument(s,i));let n=[t.command].concat(t.args).join(" ");t.args=["/d","/s","/c",`"${n}"`],t.command=process.env.comspec||"cmd.exe",t.options.windowsVerbatimArguments=!0}return t}function fx(t,e,r){e&&!Array.isArray(e)&&(r=e,e=null),e=e?e.slice(0):[],r=Object.assign({},r);let i={command:t,args:e,options:r,file:void 0,original:{command:t,args:e}};return r.shell?i:hx(i)}B0.exports=fx});var M0=$((QP,N0)=>{"use strict";var kl=process.platform==="win32";function Tl(t,e){return Object.assign(new Error(`${e} ${t.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${e} ${t.command}`,path:t.command,spawnargs:t.args})}function px(t,e){if(!kl)return;let r=t.emit;t.emit=function(i,n){if(i==="exit"){let s=I0(n,e,"spawn");if(s)return r.call(t,"error",s)}return r.apply(t,arguments)}}function I0(t,e){return kl&&t===1&&!e.file?Tl(e.original,"spawn"):null}function dx(t,e){return kl&&t===1&&!e.file?Tl(e.original,"spawnSync"):null}N0.exports={hookChildProcess:px,verifyENOENT:I0,verifyENOENTSync:dx,notFoundError:Tl}});var H0=$((e2,Ai)=>{"use strict";var j0=require("child_process"),Ll=P0(),Bl=M0();function $0(t,e,r){let i=Ll(t,e,r),n=j0.spawn(i.command,i.args,i.options);return Bl.hookChildProcess(n,i),n}function mx(t,e,r){let i=Ll(t,e,r),n=j0.spawnSync(i.command,i.args,i.options);return n.error=n.error||Bl.verifyENOENTSync(n.status,i),n}Ai.exports=$0;Ai.exports.spawn=$0;Ai.exports.sync=mx;Ai.exports._parse=Ll;Ai.exports._enoent=Bl});var U0=$((t2,q0)=>{"use strict";q0.exports=t=>{let e=typeof t=="string"?`
4
4
  `:`
5
5
  `.charCodeAt(),r=typeof t=="string"?"\r":"\r".charCodeAt();return t[t.length-1]===e&&(t=t.slice(0,t.length-1)),t[t.length-1]===r&&(t=t.slice(0,t.length-1)),t}});var W0=$((r2,wn)=>{"use strict";var _n=require("path"),G0=xl(),z0=t=>{t={cwd:process.cwd(),path:process.env[G0()],execPath:process.execPath,...t};let e,r=_n.resolve(t.cwd),i=[];for(;e!==r;)i.push(_n.join(r,"node_modules/.bin")),e=r,r=_n.resolve(r,"..");let n=_n.resolve(t.cwd,t.execPath,"..");return i.push(n),i.concat(t.path).join(_n.delimiter)};wn.exports=z0;wn.exports.default=z0;wn.exports.env=t=>{t={env:process.env,...t};let e={...t.env},r=G0({env:e});return t.path=e[r],e[r]=wn.exports(t),e}});var V0=$((i2,Pl)=>{"use strict";var Y0=(t,e)=>{for(let r of Reflect.ownKeys(e))Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r));return t};Pl.exports=Y0;Pl.exports.default=Y0});var Z0=$((n2,$s)=>{"use strict";var gx=V0(),js=new WeakMap,K0=(t,e={})=>{if(typeof t!="function")throw new TypeError("Expected a function");let r,i=0,n=t.displayName||t.name||"<anonymous>",s=function(...o){if(js.set(s,++i),i===1)r=t.apply(this,o),t=null;else if(e.throw===!0)throw new Error(`Function \`${n}\` can only be called once`);return r};return gx(s,t),js.set(s,i),s};$s.exports=K0;$s.exports.default=K0;$s.exports.callCount=t=>{if(!js.has(t))throw new Error(`The given function \`${t.name}\` is not wrapped by the \`onetime\` package`);return js.get(t)}});var J0=$(Hs=>{"use strict";Object.defineProperty(Hs,"__esModule",{value:!0});Hs.SIGNALS=void 0;var yx=[{name:"SIGHUP",number:1,action:"terminate",description:"Terminal closed",standard:"posix"},{name:"SIGINT",number:2,action:"terminate",description:"User interruption with CTRL-C",standard:"ansi"},{name:"SIGQUIT",number:3,action:"core",description:"User interruption with CTRL-\\",standard:"posix"},{name:"SIGILL",number:4,action:"core",description:"Invalid machine instruction",standard:"ansi"},{name:"SIGTRAP",number:5,action:"core",description:"Debugger breakpoint",standard:"posix"},{name:"SIGABRT",number:6,action:"core",description:"Aborted",standard:"ansi"},{name:"SIGIOT",number:6,action:"core",description:"Aborted",standard:"bsd"},{name:"SIGBUS",number:7,action:"core",description:"Bus error due to misaligned, non-existing address or paging error",standard:"bsd"},{name:"SIGEMT",number:7,action:"terminate",description:"Command should be emulated but is not implemented",standard:"other"},{name:"SIGFPE",number:8,action:"core",description:"Floating point arithmetic error",standard:"ansi"},{name:"SIGKILL",number:9,action:"terminate",description:"Forced termination",standard:"posix",forced:!0},{name:"SIGUSR1",number:10,action:"terminate",description:"Application-specific signal",standard:"posix"},{name:"SIGSEGV",number:11,action:"core",description:"Segmentation fault",standard:"ansi"},{name:"SIGUSR2",number:12,action:"terminate",description:"Application-specific signal",standard:"posix"},{name:"SIGPIPE",number:13,action:"terminate",description:"Broken pipe or socket",standard:"posix"},{name:"SIGALRM",number:14,action:"terminate",description:"Timeout or timer",standard:"posix"},{name:"SIGTERM",number:15,action:"terminate",description:"Termination",standard:"ansi"},{name:"SIGSTKFLT",number:16,action:"terminate",description:"Stack is empty or overflowed",standard:"other"},{name:"SIGCHLD",number:17,action:"ignore",description:"Child process terminated, paused or unpaused",standard:"posix"},{name:"SIGCLD",number:17,action:"ignore",description:"Child process terminated, paused or unpaused",standard:"other"},{name:"SIGCONT",number:18,action:"unpause",description:"Unpaused",standard:"posix",forced:!0},{name:"SIGSTOP",number:19,action:"pause",description:"Paused",standard:"posix",forced:!0},{name:"SIGTSTP",number:20,action:"pause",description:'Paused using CTRL-Z or "suspend"',standard:"posix"},{name:"SIGTTIN",number:21,action:"pause",description:"Background process cannot read terminal input",standard:"posix"},{name:"SIGBREAK",number:21,action:"terminate",description:"User interruption with CTRL-BREAK",standard:"other"},{name:"SIGTTOU",number:22,action:"pause",description:"Background process cannot write to terminal output",standard:"posix"},{name:"SIGURG",number:23,action:"ignore",description:"Socket received out-of-band data",standard:"bsd"},{name:"SIGXCPU",number:24,action:"core",description:"Process timed out",standard:"bsd"},{name:"SIGXFSZ",number:25,action:"core",description:"File too big",standard:"bsd"},{name:"SIGVTALRM",number:26,action:"terminate",description:"Timeout or timer",standard:"bsd"},{name:"SIGPROF",number:27,action:"terminate",description:"Timeout or timer",standard:"bsd"},{name:"SIGWINCH",number:28,action:"ignore",description:"Terminal window size changed",standard:"bsd"},{name:"SIGIO",number:29,action:"terminate",description:"I/O is available",standard:"other"},{name:"SIGPOLL",number:29,action:"terminate",description:"Watched event",standard:"other"},{name:"SIGINFO",number:29,action:"ignore",description:"Request for process information",standard:"other"},{name:"SIGPWR",number:30,action:"terminate",description:"Device running out of power",standard:"systemv"},{name:"SIGSYS",number:31,action:"core",description:"Invalid system call",standard:"other"},{name:"SIGUNUSED",number:31,action:"terminate",description:"Invalid system call",standard:"other"}];Hs.SIGNALS=yx});var Il=$(vi=>{"use strict";Object.defineProperty(vi,"__esModule",{value:!0});vi.SIGRTMAX=vi.getRealtimeSignals=void 0;var Ex=function(){let t=Q0-X0+1;return Array.from({length:t},Dx)};vi.getRealtimeSignals=Ex;var Dx=function(t,e){return{name:`SIGRT${e+1}`,number:X0+e,action:"terminate",description:"Application-specific signal (realtime)",standard:"posix"}},X0=34,Q0=64;vi.SIGRTMAX=Q0});var eg=$(qs=>{"use strict";Object.defineProperty(qs,"__esModule",{value:!0});qs.getSignals=void 0;var bx=require("os"),_x=J0(),wx=Il(),Sx=function(){let t=(0,wx.getRealtimeSignals)();return[..._x.SIGNALS,...t].map(Ax)};qs.getSignals=Sx;var Ax=function({name:t,number:e,description:r,action:i,forced:n=!1,standard:s}){let{signals:{[t]:o}}=bx.constants,a=o!==void 0;return{name:t,number:a?o:e,description:r,supported:a,action:i,forced:n,standard:s}}});var rg=$(Ci=>{"use strict";Object.defineProperty(Ci,"__esModule",{value:!0});Ci.signalsByNumber=Ci.signalsByName=void 0;var vx=require("os"),tg=eg(),Cx=Il(),xx=function(){return(0,tg.getSignals)().reduce(Rx,{})},Rx=function(t,{name:e,number:r,description:i,supported:n,action:s,forced:o,standard:a}){return{...t,[e]:{name:e,number:r,description:i,supported:n,action:s,forced:o,standard:a}}},Fx=xx();Ci.signalsByName=Fx;var Ox=function(){let t=(0,tg.getSignals)(),e=Cx.SIGRTMAX+1,r=Array.from({length:e},(i,n)=>kx(n,t));return Object.assign({},...r)},kx=function(t,e){let r=Tx(t,e);if(r===void 0)return{};let{name:i,description:n,supported:s,action:o,forced:a,standard:u}=r;return{[t]:{name:i,number:t,description:n,supported:s,action:o,forced:a,standard:u}}},Tx=function(t,e){let r=e.find(({name:i})=>vx.constants.signals[i]===t);return r!==void 0?r:e.find(i=>i.number===t)},Lx=Ox();Ci.signalsByNumber=Lx});var ng=$((l2,ig)=>{"use strict";var{signalsByName:Bx}=rg(),Px=({timedOut:t,timeout:e,errorCode:r,signal:i,signalDescription:n,exitCode:s,isCanceled:o})=>t?`timed out after ${e} milliseconds`:o?"was canceled":r!==void 0?`failed with ${r}`:i!==void 0?`was killed with ${i} (${n})`:s!==void 0?`failed with exit code ${s}`:"failed",Ix=({stdout:t,stderr:e,all:r,error:i,signal:n,exitCode:s,command:o,escapedCommand:a,timedOut:u,isCanceled:l,killed:c,parsed:{options:{timeout:f}}})=>{s=s===null?void 0:s,n=n===null?void 0:n;let h=n===void 0?void 0:Bx[n].description,p=i&&i.code,y=`Command ${Px({timedOut:u,timeout:f,errorCode:p,signal:n,signalDescription:h,exitCode:s,isCanceled:l})}: ${o}`,E=Object.prototype.toString.call(i)==="[object Error]",v=E?`${y}
6
6
  ${i.message}`:y,F=[v,e,t].filter(Boolean).join(`
7
- `);return E?(i.originalMessage=i.message,i.message=F):i=new Error(F),i.shortMessage=v,i.command=o,i.escapedCommand=a,i.exitCode=s,i.signal=n,i.signalDescription=h,i.stdout=t,i.stderr=e,r!==void 0&&(i.all=r),"bufferedData"in i&&delete i.bufferedData,i.failed=!0,i.timedOut=!!u,i.isCanceled=l,i.killed=c&&!u,i};ig.exports=Ix});var og=$((c2,Nl)=>{"use strict";var Us=["stdin","stdout","stderr"],Nx=t=>Us.some(e=>t[e]!==void 0),sg=t=>{if(!t)return;let{stdio:e}=t;if(e===void 0)return Us.map(i=>t[i]);if(Nx(t))throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${Us.map(i=>`\`${i}\``).join(", ")}`);if(typeof e=="string")return e;if(!Array.isArray(e))throw new TypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeof e}\``);let r=Math.max(e.length,Us.length);return Array.from({length:r},(i,n)=>e[n])};Nl.exports=sg;Nl.exports.node=t=>{let e=sg(t);return e==="ipc"?"ipc":e===void 0||typeof e=="string"?[e,e,e,"ipc"]:e.includes("ipc")?e:[...e,"ipc"]}});var ag=$((h2,Gs)=>{Gs.exports=["SIGABRT","SIGALRM","SIGHUP","SIGINT","SIGTERM"];process.platform!=="win32"&&Gs.exports.push("SIGVTALRM","SIGXCPU","SIGXFSZ","SIGUSR2","SIGTRAP","SIGSYS","SIGQUIT","SIGIOT");process.platform==="linux"&&Gs.exports.push("SIGIO","SIGPOLL","SIGPWR","SIGSTKFLT","SIGUNUSED")});var fg=$((f2,Fi)=>{var ye=global.process,Hr=function(t){return t&&typeof t=="object"&&typeof t.removeListener=="function"&&typeof t.emit=="function"&&typeof t.reallyExit=="function"&&typeof t.listeners=="function"&&typeof t.kill=="function"&&typeof t.pid=="number"&&typeof t.on=="function"};Hr(ye)?(ug=require("assert"),xi=ag(),lg=/^win/i.test(ye.platform),Sn=require("events"),typeof Sn!="function"&&(Sn=Sn.EventEmitter),ye.__signal_exit_emitter__?xe=ye.__signal_exit_emitter__:(xe=ye.__signal_exit_emitter__=new Sn,xe.count=0,xe.emitted={}),xe.infinite||(xe.setMaxListeners(1/0),xe.infinite=!0),Fi.exports=function(t,e){if(!Hr(global.process))return function(){};ug.equal(typeof t,"function","a callback must be provided for exit handler"),Ri===!1&&Ml();var r="exit";e&&e.alwaysLast&&(r="afterexit");var i=function(){xe.removeListener(r,t),xe.listeners("exit").length===0&&xe.listeners("afterexit").length===0&&zs()};return xe.on(r,t),i},zs=function(){!Ri||!Hr(global.process)||(Ri=!1,xi.forEach(function(e){try{ye.removeListener(e,Ws[e])}catch{}}),ye.emit=Ys,ye.reallyExit=jl,xe.count-=1)},Fi.exports.unload=zs,qr=function(e,r,i){xe.emitted[e]||(xe.emitted[e]=!0,xe.emit(e,r,i))},Ws={},xi.forEach(function(t){Ws[t]=function(){if(Hr(global.process)){var r=ye.listeners(t);r.length===xe.count&&(zs(),qr("exit",null,t),qr("afterexit",null,t),lg&&t==="SIGHUP"&&(t="SIGINT"),ye.kill(ye.pid,t))}}}),Fi.exports.signals=function(){return xi},Ri=!1,Ml=function(){Ri||!Hr(global.process)||(Ri=!0,xe.count+=1,xi=xi.filter(function(e){try{return ye.on(e,Ws[e]),!0}catch{return!1}}),ye.emit=hg,ye.reallyExit=cg)},Fi.exports.load=Ml,jl=ye.reallyExit,cg=function(e){Hr(global.process)&&(ye.exitCode=e||0,qr("exit",ye.exitCode,null),qr("afterexit",ye.exitCode,null),jl.call(ye,ye.exitCode))},Ys=ye.emit,hg=function(e,r){if(e==="exit"&&Hr(global.process)){r!==void 0&&(ye.exitCode=r);var i=Ys.apply(this,arguments);return qr("exit",ye.exitCode,null),qr("afterexit",ye.exitCode,null),i}else return Ys.apply(this,arguments)}):Fi.exports=function(){return function(){}};var ug,xi,lg,Sn,xe,zs,qr,Ws,Ri,Ml,jl,cg,Ys,hg});var dg=$((p2,pg)=>{"use strict";var Mx=require("os"),jx=fg(),$x=1e3*5,Hx=(t,e="SIGTERM",r={})=>{let i=t(e);return qx(t,e,r,i),i},qx=(t,e,r,i)=>{if(!Ux(e,r,i))return;let n=zx(r),s=setTimeout(()=>{t("SIGKILL")},n);s.unref&&s.unref()},Ux=(t,{forceKillAfterTimeout:e},r)=>Gx(t)&&e!==!1&&r,Gx=t=>t===Mx.constants.signals.SIGTERM||typeof t=="string"&&t.toUpperCase()==="SIGTERM",zx=({forceKillAfterTimeout:t=!0})=>{if(t===!0)return $x;if(!Number.isFinite(t)||t<0)throw new TypeError(`Expected the \`forceKillAfterTimeout\` option to be a non-negative integer, got \`${t}\` (${typeof t})`);return t},Wx=(t,e)=>{t.kill()&&(e.isCanceled=!0)},Yx=(t,e,r)=>{t.kill(e),r(Object.assign(new Error("Timed out"),{timedOut:!0,signal:e}))},Vx=(t,{timeout:e,killSignal:r="SIGTERM"},i)=>{if(e===0||e===void 0)return i;let n,s=new Promise((a,u)=>{n=setTimeout(()=>{Yx(t,r,u)},e)}),o=i.finally(()=>{clearTimeout(n)});return Promise.race([s,o])},Kx=({timeout:t})=>{if(t!==void 0&&(!Number.isFinite(t)||t<0))throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${t}\` (${typeof t})`)},Zx=async(t,{cleanup:e,detached:r},i)=>{if(!e||r)return i;let n=jx(()=>{t.kill()});return i.finally(()=>{n()})};pg.exports={spawnedKill:Hx,spawnedCancel:Wx,setupTimeout:Vx,validateTimeout:Kx,setExitHandler:Zx}});var gg=$((d2,mg)=>{"use strict";var At=t=>t!==null&&typeof t=="object"&&typeof t.pipe=="function";At.writable=t=>At(t)&&t.writable!==!1&&typeof t._write=="function"&&typeof t._writableState=="object";At.readable=t=>At(t)&&t.readable!==!1&&typeof t._read=="function"&&typeof t._readableState=="object";At.duplex=t=>At.writable(t)&&At.readable(t);At.transform=t=>At.duplex(t)&&typeof t._transform=="function";mg.exports=At});var Eg=$((m2,yg)=>{"use strict";var{PassThrough:Jx}=require("stream");yg.exports=t=>{t={...t};let{array:e}=t,{encoding:r}=t,i=r==="buffer",n=!1;e?n=!(r||i):r=r||"utf8",i&&(r=null);let s=new Jx({objectMode:n});r&&s.setEncoding(r);let o=0,a=[];return s.on("data",u=>{a.push(u),n?o=a.length:o+=u.length}),s.getBufferedValue=()=>e?a:i?Buffer.concat(a,o):a.join(""),s.getBufferedLength=()=>o,s}});var Dg=$((g2,An)=>{"use strict";var{constants:Xx}=require("buffer"),Qx=require("stream"),{promisify:eR}=require("util"),tR=Eg(),rR=eR(Qx.pipeline),Vs=class extends Error{constructor(){super("maxBuffer exceeded"),this.name="MaxBufferError"}};async function $l(t,e){if(!t)throw new Error("Expected a stream");e={maxBuffer:1/0,...e};let{maxBuffer:r}=e,i=tR(e);return await new Promise((n,s)=>{let o=a=>{a&&i.getBufferedLength()<=Xx.MAX_LENGTH&&(a.bufferedData=i.getBufferedValue()),s(a)};(async()=>{try{await rR(t,i),n()}catch(a){o(a)}})(),i.on("data",()=>{i.getBufferedLength()>r&&o(new Vs)})}),i.getBufferedValue()}An.exports=$l;An.exports.buffer=(t,e)=>$l(t,{...e,encoding:"buffer"});An.exports.array=(t,e)=>$l(t,{...e,array:!0});An.exports.MaxBufferError=Vs});var _g=$((y2,bg)=>{"use strict";var{PassThrough:iR}=require("stream");bg.exports=function(){var t=[],e=new iR({objectMode:!0});return e.setMaxListeners(0),e.add=r,e.isEmpty=i,e.on("unpipe",n),Array.prototype.slice.call(arguments).forEach(r),e;function r(s){return Array.isArray(s)?(s.forEach(r),this):(t.push(s),s.once("end",n.bind(null,s)),s.once("error",e.emit.bind(e,"error")),s.pipe(e,{end:!1}),this)}function i(){return t.length==0}function n(s){t=t.filter(function(o){return o!==s}),!t.length&&e.readable&&e.end()}}});var vg=$((E2,Ag)=>{"use strict";var Sg=gg(),wg=Dg(),nR=_g(),sR=(t,e)=>{e===void 0||t.stdin===void 0||(Sg(e)?e.pipe(t.stdin):t.stdin.end(e))},oR=(t,{all:e})=>{if(!e||!t.stdout&&!t.stderr)return;let r=nR();return t.stdout&&r.add(t.stdout),t.stderr&&r.add(t.stderr),r},Hl=async(t,e)=>{if(t){t.destroy();try{return await e}catch(r){return r.bufferedData}}},ql=(t,{encoding:e,buffer:r,maxBuffer:i})=>{if(!(!t||!r))return e?wg(t,{encoding:e,maxBuffer:i}):wg.buffer(t,{maxBuffer:i})},aR=async({stdout:t,stderr:e,all:r},{encoding:i,buffer:n,maxBuffer:s},o)=>{let a=ql(t,{encoding:i,buffer:n,maxBuffer:s}),u=ql(e,{encoding:i,buffer:n,maxBuffer:s}),l=ql(r,{encoding:i,buffer:n,maxBuffer:s*2});try{return await Promise.all([o,a,u,l])}catch(c){return Promise.all([{error:c,signal:c.signal,timedOut:c.timedOut},Hl(t,a),Hl(e,u),Hl(r,l)])}},uR=({input:t})=>{if(Sg(t))throw new TypeError("The `input` option cannot be a stream in sync mode")};Ag.exports={handleInput:sR,makeAllStream:oR,getSpawnedResult:aR,validateInputSync:uR}});var xg=$((D2,Cg)=>{"use strict";var lR=(async()=>{})().constructor.prototype,cR=["then","catch","finally"].map(t=>[t,Reflect.getOwnPropertyDescriptor(lR,t)]),hR=(t,e)=>{for(let[r,i]of cR){let n=typeof e=="function"?(...s)=>Reflect.apply(i.value,e(),s):i.value.bind(e);Reflect.defineProperty(t,r,{...i,value:n})}return t},fR=t=>new Promise((e,r)=>{t.on("exit",(i,n)=>{e({exitCode:i,signal:n})}),t.on("error",i=>{r(i)}),t.stdin&&t.stdin.on("error",i=>{r(i)})});Cg.exports={mergePromise:hR,getSpawnedPromise:fR}});var Og=$((b2,Fg)=>{"use strict";var Rg=(t,e=[])=>Array.isArray(e)?[t,...e]:[t],pR=/^[\w.-]+$/,dR=/"/g,mR=t=>typeof t!="string"||pR.test(t)?t:`"${t.replace(dR,'\\"')}"`,gR=(t,e)=>Rg(t,e).join(" "),yR=(t,e)=>Rg(t,e).map(r=>mR(r)).join(" "),ER=/ +/g,DR=t=>{let e=[];for(let r of t.trim().split(ER)){let i=e[e.length-1];i&&i.endsWith("\\")?e[e.length-1]=`${i.slice(0,-1)} ${r}`:e.push(r)}return e};Fg.exports={joinCommand:gR,getEscapedCommand:yR,parseCommand:DR}});var ki=$((_2,Oi)=>{"use strict";var bR=require("path"),Ul=require("child_process"),_R=H0(),wR=U0(),SR=W0(),AR=Z0(),Ks=ng(),Tg=og(),{spawnedKill:vR,spawnedCancel:CR,setupTimeout:xR,validateTimeout:RR,setExitHandler:FR}=dg(),{handleInput:OR,getSpawnedResult:kR,makeAllStream:TR,validateInputSync:LR}=vg(),{mergePromise:kg,getSpawnedPromise:BR}=xg(),{joinCommand:Lg,parseCommand:Bg,getEscapedCommand:Pg}=Og(),PR=1e3*1e3*100,IR=({env:t,extendEnv:e,preferLocal:r,localDir:i,execPath:n})=>{let s=e?{...process.env,...t}:t;return r?SR.env({env:s,cwd:i,execPath:n}):s},Ig=(t,e,r={})=>{let i=_R._parse(t,e,r);return t=i.command,e=i.args,r=i.options,r={maxBuffer:PR,buffer:!0,stripFinalNewline:!0,extendEnv:!0,preferLocal:!1,localDir:r.cwd||process.cwd(),execPath:process.execPath,encoding:"utf8",reject:!0,cleanup:!0,all:!1,windowsHide:!0,...r},r.env=IR(r),r.stdio=Tg(r),process.platform==="win32"&&bR.basename(t,".exe")==="cmd"&&e.unshift("/q"),{file:t,args:e,options:r,parsed:i}},vn=(t,e,r)=>typeof e!="string"&&!Buffer.isBuffer(e)?r===void 0?void 0:"":t.stripFinalNewline?wR(e):e,Zs=(t,e,r)=>{let i=Ig(t,e,r),n=Lg(t,e),s=Pg(t,e);RR(i.options);let o;try{o=Ul.spawn(i.file,i.args,i.options)}catch(p){let g=new Ul.ChildProcess,y=Promise.reject(Ks({error:p,stdout:"",stderr:"",all:"",command:n,escapedCommand:s,parsed:i,timedOut:!1,isCanceled:!1,killed:!1}));return kg(g,y)}let a=BR(o),u=xR(o,i.options,a),l=FR(o,i.options,u),c={isCanceled:!1};o.kill=vR.bind(null,o.kill.bind(o)),o.cancel=CR.bind(null,o,c);let h=AR(async()=>{let[{error:p,exitCode:g,signal:y,timedOut:E},v,F,O]=await kR(o,i.options,l),R=vn(i.options,v),x=vn(i.options,F),L=vn(i.options,O);if(p||g!==0||y!==null){let b=Ks({error:p,exitCode:g,signal:y,stdout:R,stderr:x,all:L,command:n,escapedCommand:s,parsed:i,timedOut:E,isCanceled:c.isCanceled,killed:o.killed});if(!i.options.reject)return b;throw b}return{command:n,escapedCommand:s,exitCode:0,stdout:R,stderr:x,all:L,failed:!1,timedOut:!1,isCanceled:!1,killed:!1}});return OR(o,i.options.input),o.all=TR(o,i.options),kg(o,h)};Oi.exports=Zs;Oi.exports.sync=(t,e,r)=>{let i=Ig(t,e,r),n=Lg(t,e),s=Pg(t,e);LR(i.options);let o;try{o=Ul.spawnSync(i.file,i.args,i.options)}catch(l){throw Ks({error:l,stdout:"",stderr:"",all:"",command:n,escapedCommand:s,parsed:i,timedOut:!1,isCanceled:!1,killed:!1})}let a=vn(i.options,o.stdout,o.error),u=vn(i.options,o.stderr,o.error);if(o.error||o.status!==0||o.signal!==null){let l=Ks({stdout:a,stderr:u,error:o.error,signal:o.signal,exitCode:o.status,command:n,escapedCommand:s,parsed:i,timedOut:o.error&&o.error.code==="ETIMEDOUT",isCanceled:!1,killed:o.signal!==null});if(!i.options.reject)return l;throw l}return{command:n,escapedCommand:s,exitCode:0,stdout:a,stderr:u,failed:!1,timedOut:!1,isCanceled:!1,killed:!1}};Oi.exports.command=(t,e)=>{let[r,...i]=Bg(t);return Zs(r,i,e)};Oi.exports.commandSync=(t,e)=>{let[r,...i]=Bg(t);return Zs.sync(r,i,e)};Oi.exports.node=(t,e,r={})=>{e&&!Array.isArray(e)&&typeof e=="object"&&(r=e,e=[]);let i=Tg.node(r),n=process.execArgv.filter(a=>!a.startsWith("--inspect")),{nodePath:s=process.execPath,nodeOptions:o=n}=r;return Zs(s,[...o,t,...Array.isArray(e)?e:[]],{...r,stdin:void 0,stdout:void 0,stderr:void 0,stdio:i,shell:!1})}});var Ti=$((C2,Hg)=>{"use strict";var $g=new Map([["C","cwd"],["f","file"],["z","gzip"],["P","preservePaths"],["U","unlink"],["strip-components","strip"],["stripComponents","strip"],["keep-newer","newer"],["keepNewer","newer"],["keep-newer-files","newer"],["keepNewerFiles","newer"],["k","keep"],["keep-existing","keep"],["keepExisting","keep"],["m","noMtime"],["no-mtime","noMtime"],["p","preserveOwner"],["L","follow"],["h","follow"]]);Hg.exports=t=>t?Object.keys(t).map(e=>[$g.has(e)?$g.get(e):e,t[e]]).reduce((e,r)=>(e[r[0]]=r[1],e),Object.create(null)):{}});var ro=$((x2,Zg)=>{"use strict";var qg=typeof process=="object"&&process?process:{stdout:null,stderr:null},HR=require("events"),Ug=require("stream"),Gg=require("string_decoder").StringDecoder,qt=Symbol("EOF"),Ut=Symbol("maybeEmitEnd"),dr=Symbol("emittedEnd"),Js=Symbol("emittingEnd"),Cn=Symbol("emittedError"),Xs=Symbol("closed"),zg=Symbol("read"),Qs=Symbol("flush"),Wg=Symbol("flushChunk"),ze=Symbol("encoding"),Gt=Symbol("decoder"),eo=Symbol("flowing"),xn=Symbol("paused"),Li=Symbol("resume"),_e=Symbol("buffer"),vt=Symbol("pipes"),Re=Symbol("bufferLength"),Wl=Symbol("bufferPush"),Yl=Symbol("bufferShift"),Be=Symbol("objectMode"),Pe=Symbol("destroyed"),Vl=Symbol("emitData"),Yg=Symbol("emitEnd"),Kl=Symbol("emitEnd2"),zt=Symbol("async"),Rn=t=>Promise.resolve().then(t),Vg=global._MP_NO_ITERATOR_SYMBOLS_!=="1",qR=Vg&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),UR=Vg&&Symbol.iterator||Symbol("iterator not implemented"),GR=t=>t==="end"||t==="finish"||t==="prefinish",zR=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,WR=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),to=class{constructor(e,r,i){this.src=e,this.dest=r,this.opts=i,this.ondrain=()=>e[Li](),r.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},Zl=class extends to{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(e,r,i){super(e,r,i),this.proxyErrors=n=>r.emit("error",n),e.on("error",this.proxyErrors)}};Zg.exports=class Kg extends Ug{constructor(e){super(),this[eo]=!1,this[xn]=!1,this[vt]=[],this[_e]=[],this[Be]=e&&e.objectMode||!1,this[Be]?this[ze]=null:this[ze]=e&&e.encoding||null,this[ze]==="buffer"&&(this[ze]=null),this[zt]=e&&!!e.async||!1,this[Gt]=this[ze]?new Gg(this[ze]):null,this[qt]=!1,this[dr]=!1,this[Js]=!1,this[Xs]=!1,this[Cn]=null,this.writable=!0,this.readable=!0,this[Re]=0,this[Pe]=!1,e&&e.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[_e]}),e&&e.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[vt]})}get bufferLength(){return this[Re]}get encoding(){return this[ze]}set encoding(e){if(this[Be])throw new Error("cannot set encoding in objectMode");if(this[ze]&&e!==this[ze]&&(this[Gt]&&this[Gt].lastNeed||this[Re]))throw new Error("cannot change encoding");this[ze]!==e&&(this[Gt]=e?new Gg(e):null,this[_e].length&&(this[_e]=this[_e].map(r=>this[Gt].write(r)))),this[ze]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[Be]}set objectMode(e){this[Be]=this[Be]||!!e}get async(){return this[zt]}set async(e){this[zt]=this[zt]||!!e}write(e,r,i){if(this[qt])throw new Error("write after end");if(this[Pe])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof r=="function"&&(i=r,r="utf8"),r||(r="utf8");let n=this[zt]?Rn:s=>s();return!this[Be]&&!Buffer.isBuffer(e)&&(WR(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):zR(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),this[Be]?(this.flowing&&this[Re]!==0&&this[Qs](!0),this.flowing?this.emit("data",e):this[Wl](e),this[Re]!==0&&this.emit("readable"),i&&n(i),this.flowing):e.length?(typeof e=="string"&&!(r===this[ze]&&!this[Gt].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[ze]&&(e=this[Gt].write(e)),this.flowing&&this[Re]!==0&&this[Qs](!0),this.flowing?this.emit("data",e):this[Wl](e),this[Re]!==0&&this.emit("readable"),i&&n(i),this.flowing):(this[Re]!==0&&this.emit("readable"),i&&n(i),this.flowing)}read(e){if(this[Pe])return null;if(this[Re]===0||e===0||e>this[Re])return this[Ut](),null;this[Be]&&(e=null),this[_e].length>1&&!this[Be]&&(this.encoding?this[_e]=[this[_e].join("")]:this[_e]=[Buffer.concat(this[_e],this[Re])]);let r=this[zg](e||null,this[_e][0]);return this[Ut](),r}[zg](e,r){return e===r.length||e===null?this[Yl]():(this[_e][0]=r.slice(e),r=r.slice(0,e),this[Re]-=e),this.emit("data",r),!this[_e].length&&!this[qt]&&this.emit("drain"),r}end(e,r,i){return typeof e=="function"&&(i=e,e=null),typeof r=="function"&&(i=r,r="utf8"),e&&this.write(e,r),i&&this.once("end",i),this[qt]=!0,this.writable=!1,(this.flowing||!this[xn])&&this[Ut](),this}[Li](){this[Pe]||(this[xn]=!1,this[eo]=!0,this.emit("resume"),this[_e].length?this[Qs]():this[qt]?this[Ut]():this.emit("drain"))}resume(){return this[Li]()}pause(){this[eo]=!1,this[xn]=!0}get destroyed(){return this[Pe]}get flowing(){return this[eo]}get paused(){return this[xn]}[Wl](e){this[Be]?this[Re]+=1:this[Re]+=e.length,this[_e].push(e)}[Yl](){return this[_e].length&&(this[Be]?this[Re]-=1:this[Re]-=this[_e][0].length),this[_e].shift()}[Qs](e){do;while(this[Wg](this[Yl]()));!e&&!this[_e].length&&!this[qt]&&this.emit("drain")}[Wg](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Pe])return;let i=this[dr];return r=r||{},e===qg.stdout||e===qg.stderr?r.end=!1:r.end=r.end!==!1,r.proxyErrors=!!r.proxyErrors,i?r.end&&e.end():(this[vt].push(r.proxyErrors?new Zl(this,e,r):new to(this,e,r)),this[zt]?Rn(()=>this[Li]()):this[Li]()),e}unpipe(e){let r=this[vt].find(i=>i.dest===e);r&&(this[vt].splice(this[vt].indexOf(r),1),r.unpipe())}addListener(e,r){return this.on(e,r)}on(e,r){let i=super.on(e,r);return e==="data"&&!this[vt].length&&!this.flowing?this[Li]():e==="readable"&&this[Re]!==0?super.emit("readable"):GR(e)&&this[dr]?(super.emit(e),this.removeAllListeners(e)):e==="error"&&this[Cn]&&(this[zt]?Rn(()=>r.call(this,this[Cn])):r.call(this,this[Cn])),i}get emittedEnd(){return this[dr]}[Ut](){!this[Js]&&!this[dr]&&!this[Pe]&&this[_e].length===0&&this[qt]&&(this[Js]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[Xs]&&this.emit("close"),this[Js]=!1)}emit(e,r,...i){if(e!=="error"&&e!=="close"&&e!==Pe&&this[Pe])return;if(e==="data")return r?this[zt]?Rn(()=>this[Vl](r)):this[Vl](r):!1;if(e==="end")return this[Yg]();if(e==="close"){if(this[Xs]=!0,!this[dr]&&!this[Pe])return;let s=super.emit("close");return this.removeAllListeners("close"),s}else if(e==="error"){this[Cn]=r;let s=super.emit("error",r);return this[Ut](),s}else if(e==="resume"){let s=super.emit("resume");return this[Ut](),s}else if(e==="finish"||e==="prefinish"){let s=super.emit(e);return this.removeAllListeners(e),s}let n=super.emit(e,r,...i);return this[Ut](),n}[Vl](e){for(let i of this[vt])i.dest.write(e)===!1&&this.pause();let r=super.emit("data",e);return this[Ut](),r}[Yg](){this[dr]||(this[dr]=!0,this.readable=!1,this[zt]?Rn(()=>this[Kl]()):this[Kl]())}[Kl](){if(this[Gt]){let r=this[Gt].end();if(r){for(let i of this[vt])i.dest.write(r);super.emit("data",r)}}for(let r of this[vt])r.end();let e=super.emit("end");return this.removeAllListeners("end"),e}collect(){let e=[];this[Be]||(e.dataLength=0);let r=this.promise();return this.on("data",i=>{e.push(i),this[Be]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[Be]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[Be]?Promise.reject(new Error("cannot concat in objectMode")):this[ze]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Pe,()=>r(new Error("stream destroyed"))),this.on("error",i=>r(i)),this.on("end",()=>e())})}[qR](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[qt])return Promise.resolve({done:!0});let i=null,n=null,s=l=>{this.removeListener("data",o),this.removeListener("end",a),n(l)},o=l=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:l,done:!!this[qt]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},u=()=>s(new Error("stream destroyed"));return new Promise((l,c)=>{n=c,i=l,this.once(Pe,u),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[UR](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Pe]?(e?this.emit("error",e):this.emit(Pe),this):(this[Pe]=!0,this[_e].length=0,this[Re]=0,typeof this.close=="function"&&!this[Xs]&&this.close(),e?this.emit("error",e):this.emit(Pe),this)}static isStream(e){return!!e&&(e instanceof Kg||e instanceof Ug||e instanceof HR&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var Xg=$((R2,Jg)=>{var YR=require("zlib").constants||{ZLIB_VERNUM:4736};Jg.exports=Object.freeze(Object.assign(Object.create(null),{Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_VERSION_ERROR:-6,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,DEFLATE:1,INFLATE:2,GZIP:3,GUNZIP:4,DEFLATERAW:5,INFLATERAW:6,UNZIP:7,BROTLI_DECODE:8,BROTLI_ENCODE:9,Z_MIN_WINDOWBITS:8,Z_MAX_WINDOWBITS:15,Z_DEFAULT_WINDOWBITS:15,Z_MIN_CHUNK:64,Z_MAX_CHUNK:1/0,Z_DEFAULT_CHUNK:16384,Z_MIN_MEMLEVEL:1,Z_MAX_MEMLEVEL:9,Z_DEFAULT_MEMLEVEL:8,Z_MIN_LEVEL:-1,Z_MAX_LEVEL:9,Z_DEFAULT_LEVEL:-1,BROTLI_OPERATION_PROCESS:0,BROTLI_OPERATION_FLUSH:1,BROTLI_OPERATION_FINISH:2,BROTLI_OPERATION_EMIT_METADATA:3,BROTLI_MODE_GENERIC:0,BROTLI_MODE_TEXT:1,BROTLI_MODE_FONT:2,BROTLI_DEFAULT_MODE:0,BROTLI_MIN_QUALITY:0,BROTLI_MAX_QUALITY:11,BROTLI_DEFAULT_QUALITY:11,BROTLI_MIN_WINDOW_BITS:10,BROTLI_MAX_WINDOW_BITS:24,BROTLI_LARGE_MAX_WINDOW_BITS:30,BROTLI_DEFAULT_WINDOW:22,BROTLI_MIN_INPUT_BLOCK_BITS:16,BROTLI_MAX_INPUT_BLOCK_BITS:24,BROTLI_PARAM_MODE:0,BROTLI_PARAM_QUALITY:1,BROTLI_PARAM_LGWIN:2,BROTLI_PARAM_LGBLOCK:3,BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING:4,BROTLI_PARAM_SIZE_HINT:5,BROTLI_PARAM_LARGE_WINDOW:6,BROTLI_PARAM_NPOSTFIX:7,BROTLI_PARAM_NDIRECT:8,BROTLI_DECODER_RESULT_ERROR:0,BROTLI_DECODER_RESULT_SUCCESS:1,BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT:2,BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION:0,BROTLI_DECODER_PARAM_LARGE_WINDOW:1,BROTLI_DECODER_NO_ERROR:0,BROTLI_DECODER_SUCCESS:1,BROTLI_DECODER_NEEDS_MORE_INPUT:2,BROTLI_DECODER_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE:-1,BROTLI_DECODER_ERROR_FORMAT_RESERVED:-2,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE:-3,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET:-4,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME:-5,BROTLI_DECODER_ERROR_FORMAT_CL_SPACE:-6,BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE:-7,BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT:-8,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1:-9,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2:-10,BROTLI_DECODER_ERROR_FORMAT_TRANSFORM:-11,BROTLI_DECODER_ERROR_FORMAT_DICTIONARY:-12,BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS:-13,BROTLI_DECODER_ERROR_FORMAT_PADDING_1:-14,BROTLI_DECODER_ERROR_FORMAT_PADDING_2:-15,BROTLI_DECODER_ERROR_FORMAT_DISTANCE:-16,BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET:-19,BROTLI_DECODER_ERROR_INVALID_ARGUMENTS:-20,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES:-21,BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS:-22,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP:-25,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1:-26,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2:-27,BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES:-30,BROTLI_DECODER_ERROR_UNREACHABLE:-31},YR))});var rc=$((F2,ay)=>{"use strict";var Qg=typeof process=="object"&&process?process:{stdout:null,stderr:null},VR=require("events"),ey=require("stream"),ty=require("string_decoder").StringDecoder,Wt=Symbol("EOF"),Yt=Symbol("maybeEmitEnd"),mr=Symbol("emittedEnd"),io=Symbol("emittingEnd"),Fn=Symbol("emittedError"),no=Symbol("closed"),ry=Symbol("read"),so=Symbol("flush"),iy=Symbol("flushChunk"),We=Symbol("encoding"),Vt=Symbol("decoder"),oo=Symbol("flowing"),On=Symbol("paused"),Bi=Symbol("resume"),Fe=Symbol("bufferLength"),Jl=Symbol("bufferPush"),Xl=Symbol("bufferShift"),Ie=Symbol("objectMode"),Ne=Symbol("destroyed"),Ql=Symbol("emitData"),ny=Symbol("emitEnd"),ec=Symbol("emitEnd2"),Kt=Symbol("async"),kn=t=>Promise.resolve().then(t),sy=global._MP_NO_ITERATOR_SYMBOLS_!=="1",KR=sy&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),ZR=sy&&Symbol.iterator||Symbol("iterator not implemented"),JR=t=>t==="end"||t==="finish"||t==="prefinish",XR=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,QR=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),ao=class{constructor(e,r,i){this.src=e,this.dest=r,this.opts=i,this.ondrain=()=>e[Bi](),r.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},tc=class extends ao{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(e,r,i){super(e,r,i),this.proxyErrors=n=>r.emit("error",n),e.on("error",this.proxyErrors)}};ay.exports=class oy extends ey{constructor(e){super(),this[oo]=!1,this[On]=!1,this.pipes=[],this.buffer=[],this[Ie]=e&&e.objectMode||!1,this[Ie]?this[We]=null:this[We]=e&&e.encoding||null,this[We]==="buffer"&&(this[We]=null),this[Kt]=e&&!!e.async||!1,this[Vt]=this[We]?new ty(this[We]):null,this[Wt]=!1,this[mr]=!1,this[io]=!1,this[no]=!1,this[Fn]=null,this.writable=!0,this.readable=!0,this[Fe]=0,this[Ne]=!1}get bufferLength(){return this[Fe]}get encoding(){return this[We]}set encoding(e){if(this[Ie])throw new Error("cannot set encoding in objectMode");if(this[We]&&e!==this[We]&&(this[Vt]&&this[Vt].lastNeed||this[Fe]))throw new Error("cannot change encoding");this[We]!==e&&(this[Vt]=e?new ty(e):null,this.buffer.length&&(this.buffer=this.buffer.map(r=>this[Vt].write(r)))),this[We]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[Ie]}set objectMode(e){this[Ie]=this[Ie]||!!e}get async(){return this[Kt]}set async(e){this[Kt]=this[Kt]||!!e}write(e,r,i){if(this[Wt])throw new Error("write after end");if(this[Ne])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof r=="function"&&(i=r,r="utf8"),r||(r="utf8");let n=this[Kt]?kn:s=>s();return!this[Ie]&&!Buffer.isBuffer(e)&&(QR(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):XR(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),this[Ie]?(this.flowing&&this[Fe]!==0&&this[so](!0),this.flowing?this.emit("data",e):this[Jl](e),this[Fe]!==0&&this.emit("readable"),i&&n(i),this.flowing):e.length?(typeof e=="string"&&!(r===this[We]&&!this[Vt].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[We]&&(e=this[Vt].write(e)),this.flowing&&this[Fe]!==0&&this[so](!0),this.flowing?this.emit("data",e):this[Jl](e),this[Fe]!==0&&this.emit("readable"),i&&n(i),this.flowing):(this[Fe]!==0&&this.emit("readable"),i&&n(i),this.flowing)}read(e){if(this[Ne])return null;if(this[Fe]===0||e===0||e>this[Fe])return this[Yt](),null;this[Ie]&&(e=null),this.buffer.length>1&&!this[Ie]&&(this.encoding?this.buffer=[this.buffer.join("")]:this.buffer=[Buffer.concat(this.buffer,this[Fe])]);let r=this[ry](e||null,this.buffer[0]);return this[Yt](),r}[ry](e,r){return e===r.length||e===null?this[Xl]():(this.buffer[0]=r.slice(e),r=r.slice(0,e),this[Fe]-=e),this.emit("data",r),!this.buffer.length&&!this[Wt]&&this.emit("drain"),r}end(e,r,i){return typeof e=="function"&&(i=e,e=null),typeof r=="function"&&(i=r,r="utf8"),e&&this.write(e,r),i&&this.once("end",i),this[Wt]=!0,this.writable=!1,(this.flowing||!this[On])&&this[Yt](),this}[Bi](){this[Ne]||(this[On]=!1,this[oo]=!0,this.emit("resume"),this.buffer.length?this[so]():this[Wt]?this[Yt]():this.emit("drain"))}resume(){return this[Bi]()}pause(){this[oo]=!1,this[On]=!0}get destroyed(){return this[Ne]}get flowing(){return this[oo]}get paused(){return this[On]}[Jl](e){this[Ie]?this[Fe]+=1:this[Fe]+=e.length,this.buffer.push(e)}[Xl](){return this.buffer.length&&(this[Ie]?this[Fe]-=1:this[Fe]-=this.buffer[0].length),this.buffer.shift()}[so](e){do;while(this[iy](this[Xl]()));!e&&!this.buffer.length&&!this[Wt]&&this.emit("drain")}[iy](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Ne])return;let i=this[mr];return r=r||{},e===Qg.stdout||e===Qg.stderr?r.end=!1:r.end=r.end!==!1,r.proxyErrors=!!r.proxyErrors,i?r.end&&e.end():(this.pipes.push(r.proxyErrors?new tc(this,e,r):new ao(this,e,r)),this[Kt]?kn(()=>this[Bi]()):this[Bi]()),e}unpipe(e){let r=this.pipes.find(i=>i.dest===e);r&&(this.pipes.splice(this.pipes.indexOf(r),1),r.unpipe())}addListener(e,r){return this.on(e,r)}on(e,r){let i=super.on(e,r);return e==="data"&&!this.pipes.length&&!this.flowing?this[Bi]():e==="readable"&&this[Fe]!==0?super.emit("readable"):JR(e)&&this[mr]?(super.emit(e),this.removeAllListeners(e)):e==="error"&&this[Fn]&&(this[Kt]?kn(()=>r.call(this,this[Fn])):r.call(this,this[Fn])),i}get emittedEnd(){return this[mr]}[Yt](){!this[io]&&!this[mr]&&!this[Ne]&&this.buffer.length===0&&this[Wt]&&(this[io]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[no]&&this.emit("close"),this[io]=!1)}emit(e,r,...i){if(e!=="error"&&e!=="close"&&e!==Ne&&this[Ne])return;if(e==="data")return r?this[Kt]?kn(()=>this[Ql](r)):this[Ql](r):!1;if(e==="end")return this[ny]();if(e==="close"){if(this[no]=!0,!this[mr]&&!this[Ne])return;let s=super.emit("close");return this.removeAllListeners("close"),s}else if(e==="error"){this[Fn]=r;let s=super.emit("error",r);return this[Yt](),s}else if(e==="resume"){let s=super.emit("resume");return this[Yt](),s}else if(e==="finish"||e==="prefinish"){let s=super.emit(e);return this.removeAllListeners(e),s}let n=super.emit(e,r,...i);return this[Yt](),n}[Ql](e){for(let i of this.pipes)i.dest.write(e)===!1&&this.pause();let r=super.emit("data",e);return this[Yt](),r}[ny](){this[mr]||(this[mr]=!0,this.readable=!1,this[Kt]?kn(()=>this[ec]()):this[ec]())}[ec](){if(this[Vt]){let r=this[Vt].end();if(r){for(let i of this.pipes)i.dest.write(r);super.emit("data",r)}}for(let r of this.pipes)r.end();let e=super.emit("end");return this.removeAllListeners("end"),e}collect(){let e=[];this[Ie]||(e.dataLength=0);let r=this.promise();return this.on("data",i=>{e.push(i),this[Ie]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[Ie]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[Ie]?Promise.reject(new Error("cannot concat in objectMode")):this[We]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Ne,()=>r(new Error("stream destroyed"))),this.on("error",i=>r(i)),this.on("end",()=>e())})}[KR](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[Wt])return Promise.resolve({done:!0});let i=null,n=null,s=l=>{this.removeListener("data",o),this.removeListener("end",a),n(l)},o=l=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:l,done:!!this[Wt]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},u=()=>s(new Error("stream destroyed"));return new Promise((l,c)=>{n=c,i=l,this.once(Ne,u),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[ZR](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Ne]?(e?this.emit("error",e):this.emit(Ne),this):(this[Ne]=!0,this.buffer.length=0,this[Fe]=0,typeof this.close=="function"&&!this[no]&&this.close(),e?this.emit("error",e):this.emit(Ne),this)}static isStream(e){return!!e&&(e instanceof oy||e instanceof ey||e instanceof VR&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var Ec=$(Xe=>{"use strict";var ac=require("assert"),gr=require("buffer").Buffer,cy=require("zlib"),Ur=Xe.constants=Xg(),eF=rc(),uy=gr.concat,Gr=Symbol("_superWrite"),Ii=class extends Error{constructor(e){super("zlib: "+e.message),this.code=e.code,this.errno=e.errno,this.code||(this.code="ZLIB_ERROR"),this.message="zlib: "+e.message,Error.captureStackTrace(this,this.constructor)}get name(){return"ZlibError"}},tF=Symbol("opts"),Tn=Symbol("flushFlag"),ly=Symbol("finishFlushFlag"),yc=Symbol("fullFlushFlag"),de=Symbol("handle"),uo=Symbol("onError"),Pi=Symbol("sawError"),ic=Symbol("level"),nc=Symbol("strategy"),sc=Symbol("ended"),O2=Symbol("_defaultFullFlush"),lo=class extends eF{constructor(e,r){if(!e||typeof e!="object")throw new TypeError("invalid options for ZlibBase constructor");super(e),this[Pi]=!1,this[sc]=!1,this[tF]=e,this[Tn]=e.flush,this[ly]=e.finishFlush;try{this[de]=new cy[r](e)}catch(i){throw new Ii(i)}this[uo]=i=>{this[Pi]||(this[Pi]=!0,this.close(),this.emit("error",i))},this[de].on("error",i=>this[uo](new Ii(i))),this.once("end",()=>this.close)}close(){this[de]&&(this[de].close(),this[de]=null,this.emit("close"))}reset(){if(!this[Pi])return ac(this[de],"zlib binding closed"),this[de].reset()}flush(e){this.ended||(typeof e!="number"&&(e=this[yc]),this.write(Object.assign(gr.alloc(0),{[Tn]:e})))}end(e,r,i){return e&&this.write(e,r),this.flush(this[ly]),this[sc]=!0,super.end(null,null,i)}get ended(){return this[sc]}write(e,r,i){if(typeof r=="function"&&(i=r,r="utf8"),typeof e=="string"&&(e=gr.from(e,r)),this[Pi])return;ac(this[de],"zlib binding closed");let n=this[de]._handle,s=n.close;n.close=()=>{};let o=this[de].close;this[de].close=()=>{},gr.concat=l=>l;let a;try{let l=typeof e[Tn]=="number"?e[Tn]:this[Tn];a=this[de]._processChunk(e,l),gr.concat=uy}catch(l){gr.concat=uy,this[uo](new Ii(l))}finally{this[de]&&(this[de]._handle=n,n.close=s,this[de].close=o,this[de].removeAllListeners("error"))}this[de]&&this[de].on("error",l=>this[uo](new Ii(l)));let u;if(a)if(Array.isArray(a)&&a.length>0){u=this[Gr](gr.from(a[0]));for(let l=1;l<a.length;l++)u=this[Gr](a[l])}else u=this[Gr](gr.from(a));return i&&i(),u}[Gr](e){return super.write(e)}},Zt=class extends lo{constructor(e,r){e=e||{},e.flush=e.flush||Ur.Z_NO_FLUSH,e.finishFlush=e.finishFlush||Ur.Z_FINISH,super(e,r),this[yc]=Ur.Z_FULL_FLUSH,this[ic]=e.level,this[nc]=e.strategy}params(e,r){if(!this[Pi]){if(!this[de])throw new Error("cannot switch params when binding is closed");if(!this[de].params)throw new Error("not supported in this implementation");if(this[ic]!==e||this[nc]!==r){this.flush(Ur.Z_SYNC_FLUSH),ac(this[de],"zlib binding closed");let i=this[de].flush;this[de].flush=(n,s)=>{this.flush(n),s()};try{this[de].params(e,r)}finally{this[de].flush=i}this[de]&&(this[ic]=e,this[nc]=r)}}}},uc=class extends Zt{constructor(e){super(e,"Deflate")}},lc=class extends Zt{constructor(e){super(e,"Inflate")}},oc=Symbol("_portable"),cc=class extends Zt{constructor(e){super(e,"Gzip"),this[oc]=e&&!!e.portable}[Gr](e){return this[oc]?(this[oc]=!1,e[9]=255,super[Gr](e)):super[Gr](e)}},hc=class extends Zt{constructor(e){super(e,"Gunzip")}},fc=class extends Zt{constructor(e){super(e,"DeflateRaw")}},pc=class extends Zt{constructor(e){super(e,"InflateRaw")}},dc=class extends Zt{constructor(e){super(e,"Unzip")}},co=class extends lo{constructor(e,r){e=e||{},e.flush=e.flush||Ur.BROTLI_OPERATION_PROCESS,e.finishFlush=e.finishFlush||Ur.BROTLI_OPERATION_FINISH,super(e,r),this[yc]=Ur.BROTLI_OPERATION_FLUSH}},mc=class extends co{constructor(e){super(e,"BrotliCompress")}},gc=class extends co{constructor(e){super(e,"BrotliDecompress")}};Xe.Deflate=uc;Xe.Inflate=lc;Xe.Gzip=cc;Xe.Gunzip=hc;Xe.DeflateRaw=fc;Xe.InflateRaw=pc;Xe.Unzip=dc;typeof cy.BrotliCompress=="function"?(Xe.BrotliCompress=mc,Xe.BrotliDecompress=gc):Xe.BrotliCompress=Xe.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}});var Ni=$((L2,hy)=>{var rF=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform;hy.exports=rF!=="win32"?t=>t:t=>t&&t.replace(/\\/g,"/")});var ho=$((P2,fy)=>{"use strict";var iF=ro(),Dc=Ni(),bc=Symbol("slurp");fy.exports=class extends iF{constructor(e,r,i){switch(super(),this.pause(),this.extended=r,this.globalExtended=i,this.header=e,this.startBlockSize=512*Math.ceil(e.size/512),this.blockRemain=this.startBlockSize,this.remain=e.size,this.type=e.type,this.meta=!1,this.ignore=!1,this.type){case"File":case"OldFile":case"Link":case"SymbolicLink":case"CharacterDevice":case"BlockDevice":case"Directory":case"FIFO":case"ContiguousFile":case"GNUDumpDir":break;case"NextFileHasLongLinkpath":case"NextFileHasLongPath":case"OldGnuLongPath":case"GlobalExtendedHeader":case"ExtendedHeader":case"OldExtendedHeader":this.meta=!0;break;default:this.ignore=!0}this.path=Dc(e.path),this.mode=e.mode,this.mode&&(this.mode=this.mode&4095),this.uid=e.uid,this.gid=e.gid,this.uname=e.uname,this.gname=e.gname,this.size=e.size,this.mtime=e.mtime,this.atime=e.atime,this.ctime=e.ctime,this.linkpath=Dc(e.linkpath),this.uname=e.uname,this.gname=e.gname,r&&this[bc](r),i&&this[bc](i,!0)}write(e){let r=e.length;if(r>this.blockRemain)throw new Error("writing more to entry than is appropriate");let i=this.remain,n=this.blockRemain;return this.remain=Math.max(0,i-r),this.blockRemain=Math.max(0,n-r),this.ignore?!0:i>=r?super.write(e):super.write(e.slice(0,i))}[bc](e,r){for(let i in e)e[i]!==null&&e[i]!==void 0&&!(r&&i==="path")&&(this[i]=i==="path"||i==="linkpath"?Dc(e[i]):e[i])}}});var _c=$(fo=>{"use strict";fo.name=new Map([["0","File"],["","OldFile"],["1","Link"],["2","SymbolicLink"],["3","CharacterDevice"],["4","BlockDevice"],["5","Directory"],["6","FIFO"],["7","ContiguousFile"],["g","GlobalExtendedHeader"],["x","ExtendedHeader"],["A","SolarisACL"],["D","GNUDumpDir"],["I","Inode"],["K","NextFileHasLongLinkpath"],["L","NextFileHasLongPath"],["M","ContinuationFile"],["N","OldGnuLongPath"],["S","SparseFile"],["V","TapeVolumeHeader"],["X","OldExtendedHeader"]]);fo.code=new Map(Array.from(fo.name).map(t=>[t[1],t[0]]))});var gy=$((N2,my)=>{"use strict";var nF=(t,e)=>{if(Number.isSafeInteger(t))t<0?oF(t,e):sF(t,e);else throw Error("cannot encode number outside of javascript safe integer range");return e},sF=(t,e)=>{e[0]=128;for(var r=e.length;r>1;r--)e[r-1]=t&255,t=Math.floor(t/256)},oF=(t,e)=>{e[0]=255;var r=!1;t=t*-1;for(var i=e.length;i>1;i--){var n=t&255;t=Math.floor(t/256),r?e[i-1]=py(n):n===0?e[i-1]=0:(r=!0,e[i-1]=dy(n))}},aF=t=>{let e=t[0],r=e===128?lF(t.slice(1,t.length)):e===255?uF(t):null;if(r===null)throw Error("invalid base256 encoding");if(!Number.isSafeInteger(r))throw Error("parsed number outside of javascript safe integer range");return r},uF=t=>{for(var e=t.length,r=0,i=!1,n=e-1;n>-1;n--){var s=t[n],o;i?o=py(s):s===0?o=s:(i=!0,o=dy(s)),o!==0&&(r-=o*Math.pow(256,e-n-1))}return r},lF=t=>{for(var e=t.length,r=0,i=e-1;i>-1;i--){var n=t[i];n!==0&&(r+=n*Math.pow(256,e-i-1))}return r},py=t=>(255^t)&255,dy=t=>(255^t)+1&255;my.exports={encode:nF,parse:aF}});var ji=$((M2,Ey)=>{"use strict";var wc=_c(),Mi=require("path").posix,yy=gy(),Sc=Symbol("slurp"),Qe=Symbol("type"),Cc=class{constructor(e,r,i,n){this.cksumValid=!1,this.needPax=!1,this.nullBlock=!1,this.block=null,this.path=null,this.mode=null,this.uid=null,this.gid=null,this.size=null,this.mtime=null,this.cksum=null,this[Qe]="0",this.linkpath=null,this.uname=null,this.gname=null,this.devmaj=0,this.devmin=0,this.atime=null,this.ctime=null,Buffer.isBuffer(e)?this.decode(e,r||0,i,n):e&&this.set(e)}decode(e,r,i,n){if(r||(r=0),!e||!(e.length>=r+512))throw new Error("need 512 bytes for header");if(this.path=zr(e,r,100),this.mode=yr(e,r+100,8),this.uid=yr(e,r+108,8),this.gid=yr(e,r+116,8),this.size=yr(e,r+124,12),this.mtime=Ac(e,r+136,12),this.cksum=yr(e,r+148,12),this[Sc](i),this[Sc](n,!0),this[Qe]=zr(e,r+156,1),this[Qe]===""&&(this[Qe]="0"),this[Qe]==="0"&&this.path.slice(-1)==="/"&&(this[Qe]="5"),this[Qe]==="5"&&(this.size=0),this.linkpath=zr(e,r+157,100),e.slice(r+257,r+265).toString()==="ustar\x0000")if(this.uname=zr(e,r+265,32),this.gname=zr(e,r+297,32),this.devmaj=yr(e,r+329,8),this.devmin=yr(e,r+337,8),e[r+475]!==0){let o=zr(e,r+345,155);this.path=o+"/"+this.path}else{let o=zr(e,r+345,130);o&&(this.path=o+"/"+this.path),this.atime=Ac(e,r+476,12),this.ctime=Ac(e,r+488,12)}let s=8*32;for(let o=r;o<r+148;o++)s+=e[o];for(let o=r+156;o<r+512;o++)s+=e[o];this.cksumValid=s===this.cksum,this.cksum===null&&s===8*32&&(this.nullBlock=!0)}[Sc](e,r){for(let i in e)e[i]!==null&&e[i]!==void 0&&!(r&&i==="path")&&(this[i]=e[i])}encode(e,r){if(e||(e=this.block=Buffer.alloc(512),r=0),r||(r=0),!(e.length>=r+512))throw new Error("need 512 bytes for header");let i=this.ctime||this.atime?130:155,n=cF(this.path||"",i),s=n[0],o=n[1];this.needPax=n[2],this.needPax=Wr(e,r,100,s)||this.needPax,this.needPax=Er(e,r+100,8,this.mode)||this.needPax,this.needPax=Er(e,r+108,8,this.uid)||this.needPax,this.needPax=Er(e,r+116,8,this.gid)||this.needPax,this.needPax=Er(e,r+124,12,this.size)||this.needPax,this.needPax=vc(e,r+136,12,this.mtime)||this.needPax,e[r+156]=this[Qe].charCodeAt(0),this.needPax=Wr(e,r+157,100,this.linkpath)||this.needPax,e.write("ustar\x0000",r+257,8),this.needPax=Wr(e,r+265,32,this.uname)||this.needPax,this.needPax=Wr(e,r+297,32,this.gname)||this.needPax,this.needPax=Er(e,r+329,8,this.devmaj)||this.needPax,this.needPax=Er(e,r+337,8,this.devmin)||this.needPax,this.needPax=Wr(e,r+345,i,o)||this.needPax,e[r+475]!==0?this.needPax=Wr(e,r+345,155,o)||this.needPax:(this.needPax=Wr(e,r+345,130,o)||this.needPax,this.needPax=vc(e,r+476,12,this.atime)||this.needPax,this.needPax=vc(e,r+488,12,this.ctime)||this.needPax);let a=8*32;for(let u=r;u<r+148;u++)a+=e[u];for(let u=r+156;u<r+512;u++)a+=e[u];return this.cksum=a,Er(e,r+148,8,this.cksum),this.cksumValid=!0,this.needPax}set(e){for(let r in e)e[r]!==null&&e[r]!==void 0&&(this[r]=e[r])}get type(){return wc.name.get(this[Qe])||this[Qe]}get typeKey(){return this[Qe]}set type(e){wc.code.has(e)?this[Qe]=wc.code.get(e):this[Qe]=e}},cF=(t,e)=>{let i=t,n="",s,o=Mi.parse(t).root||".";if(Buffer.byteLength(i)<100)s=[i,n,!1];else{n=Mi.dirname(i),i=Mi.basename(i);do Buffer.byteLength(i)<=100&&Buffer.byteLength(n)<=e?s=[i,n,!1]:Buffer.byteLength(i)>100&&Buffer.byteLength(n)<=e?s=[i.slice(0,100-1),n,!0]:(i=Mi.join(Mi.basename(n),i),n=Mi.dirname(n));while(n!==o&&!s);s||(s=[t.slice(0,100-1),"",!0])}return s},zr=(t,e,r)=>t.slice(e,e+r).toString("utf8").replace(/\0.*/,""),Ac=(t,e,r)=>hF(yr(t,e,r)),hF=t=>t===null?null:new Date(t*1e3),yr=(t,e,r)=>t[e]&128?yy.parse(t.slice(e,e+r)):pF(t,e,r),fF=t=>isNaN(t)?null:t,pF=(t,e,r)=>fF(parseInt(t.slice(e,e+r).toString("utf8").replace(/\0.*$/,"").trim(),8)),dF={12:8589934591,8:2097151},Er=(t,e,r,i)=>i===null?!1:i>dF[r]||i<0?(yy.encode(i,t.slice(e,e+r)),!0):(mF(t,e,r,i),!1),mF=(t,e,r,i)=>t.write(gF(i,r),e,r,"ascii"),gF=(t,e)=>yF(Math.floor(t).toString(8),e),yF=(t,e)=>(t.length===e-1?t:new Array(e-t.length-1).join("0")+t+" ")+"\0",vc=(t,e,r,i)=>i===null?!1:Er(t,e,r,i.getTime()/1e3),EF=new Array(156).join("\0"),Wr=(t,e,r,i)=>i===null?!1:(t.write(i+EF,e,r,"utf8"),i.length!==Buffer.byteLength(i)||i.length>r);Ey.exports=Cc});var po=$((j2,Dy)=>{"use strict";var DF=ji(),bF=require("path"),Ln=class{constructor(e,r){this.atime=e.atime||null,this.charset=e.charset||null,this.comment=e.comment||null,this.ctime=e.ctime||null,this.gid=e.gid||null,this.gname=e.gname||null,this.linkpath=e.linkpath||null,this.mtime=e.mtime||null,this.path=e.path||null,this.size=e.size||null,this.uid=e.uid||null,this.uname=e.uname||null,this.dev=e.dev||null,this.ino=e.ino||null,this.nlink=e.nlink||null,this.global=r||!1}encode(){let e=this.encodeBody();if(e==="")return null;let r=Buffer.byteLength(e),i=512*Math.ceil(1+r/512),n=Buffer.allocUnsafe(i);for(let s=0;s<512;s++)n[s]=0;new DF({path:("PaxHeader/"+bF.basename(this.path)).slice(0,99),mode:this.mode||420,uid:this.uid||null,gid:this.gid||null,size:r,mtime:this.mtime||null,type:this.global?"GlobalExtendedHeader":"ExtendedHeader",linkpath:"",uname:this.uname||"",gname:this.gname||"",devmaj:0,devmin:0,atime:this.atime||null,ctime:this.ctime||null}).encode(n),n.write(e,512,r,"utf8");for(let s=r+512;s<n.length;s++)n[s]=0;return n}encodeBody(){return this.encodeField("path")+this.encodeField("ctime")+this.encodeField("atime")+this.encodeField("dev")+this.encodeField("ino")+this.encodeField("nlink")+this.encodeField("charset")+this.encodeField("comment")+this.encodeField("gid")+this.encodeField("gname")+this.encodeField("linkpath")+this.encodeField("mtime")+this.encodeField("size")+this.encodeField("uid")+this.encodeField("uname")}encodeField(e){if(this[e]===null||this[e]===void 0)return"";let r=this[e]instanceof Date?this[e].getTime()/1e3:this[e],i=" "+(e==="dev"||e==="ino"||e==="nlink"?"SCHILY.":"")+e+"="+r+`
7
+ `);return E?(i.originalMessage=i.message,i.message=F):i=new Error(F),i.shortMessage=v,i.command=o,i.escapedCommand=a,i.exitCode=s,i.signal=n,i.signalDescription=h,i.stdout=t,i.stderr=e,r!==void 0&&(i.all=r),"bufferedData"in i&&delete i.bufferedData,i.failed=!0,i.timedOut=!!u,i.isCanceled=l,i.killed=c&&!u,i};ig.exports=Ix});var og=$((c2,Nl)=>{"use strict";var Us=["stdin","stdout","stderr"],Nx=t=>Us.some(e=>t[e]!==void 0),sg=t=>{if(!t)return;let{stdio:e}=t;if(e===void 0)return Us.map(i=>t[i]);if(Nx(t))throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${Us.map(i=>`\`${i}\``).join(", ")}`);if(typeof e=="string")return e;if(!Array.isArray(e))throw new TypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeof e}\``);let r=Math.max(e.length,Us.length);return Array.from({length:r},(i,n)=>e[n])};Nl.exports=sg;Nl.exports.node=t=>{let e=sg(t);return e==="ipc"?"ipc":e===void 0||typeof e=="string"?[e,e,e,"ipc"]:e.includes("ipc")?e:[...e,"ipc"]}});var ag=$((h2,Gs)=>{Gs.exports=["SIGABRT","SIGALRM","SIGHUP","SIGINT","SIGTERM"];process.platform!=="win32"&&Gs.exports.push("SIGVTALRM","SIGXCPU","SIGXFSZ","SIGUSR2","SIGTRAP","SIGSYS","SIGQUIT","SIGIOT");process.platform==="linux"&&Gs.exports.push("SIGIO","SIGPOLL","SIGPWR","SIGSTKFLT","SIGUNUSED")});var fg=$((f2,Fi)=>{var ye=global.process,qr=function(t){return t&&typeof t=="object"&&typeof t.removeListener=="function"&&typeof t.emit=="function"&&typeof t.reallyExit=="function"&&typeof t.listeners=="function"&&typeof t.kill=="function"&&typeof t.pid=="number"&&typeof t.on=="function"};qr(ye)?(ug=require("assert"),xi=ag(),lg=/^win/i.test(ye.platform),Sn=require("events"),typeof Sn!="function"&&(Sn=Sn.EventEmitter),ye.__signal_exit_emitter__?xe=ye.__signal_exit_emitter__:(xe=ye.__signal_exit_emitter__=new Sn,xe.count=0,xe.emitted={}),xe.infinite||(xe.setMaxListeners(1/0),xe.infinite=!0),Fi.exports=function(t,e){if(!qr(global.process))return function(){};ug.equal(typeof t,"function","a callback must be provided for exit handler"),Ri===!1&&Ml();var r="exit";e&&e.alwaysLast&&(r="afterexit");var i=function(){xe.removeListener(r,t),xe.listeners("exit").length===0&&xe.listeners("afterexit").length===0&&zs()};return xe.on(r,t),i},zs=function(){!Ri||!qr(global.process)||(Ri=!1,xi.forEach(function(e){try{ye.removeListener(e,Ws[e])}catch{}}),ye.emit=Ys,ye.reallyExit=jl,xe.count-=1)},Fi.exports.unload=zs,Ur=function(e,r,i){xe.emitted[e]||(xe.emitted[e]=!0,xe.emit(e,r,i))},Ws={},xi.forEach(function(t){Ws[t]=function(){if(qr(global.process)){var r=ye.listeners(t);r.length===xe.count&&(zs(),Ur("exit",null,t),Ur("afterexit",null,t),lg&&t==="SIGHUP"&&(t="SIGINT"),ye.kill(ye.pid,t))}}}),Fi.exports.signals=function(){return xi},Ri=!1,Ml=function(){Ri||!qr(global.process)||(Ri=!0,xe.count+=1,xi=xi.filter(function(e){try{return ye.on(e,Ws[e]),!0}catch{return!1}}),ye.emit=hg,ye.reallyExit=cg)},Fi.exports.load=Ml,jl=ye.reallyExit,cg=function(e){qr(global.process)&&(ye.exitCode=e||0,Ur("exit",ye.exitCode,null),Ur("afterexit",ye.exitCode,null),jl.call(ye,ye.exitCode))},Ys=ye.emit,hg=function(e,r){if(e==="exit"&&qr(global.process)){r!==void 0&&(ye.exitCode=r);var i=Ys.apply(this,arguments);return Ur("exit",ye.exitCode,null),Ur("afterexit",ye.exitCode,null),i}else return Ys.apply(this,arguments)}):Fi.exports=function(){return function(){}};var ug,xi,lg,Sn,xe,zs,Ur,Ws,Ri,Ml,jl,cg,Ys,hg});var dg=$((p2,pg)=>{"use strict";var Mx=require("os"),jx=fg(),$x=1e3*5,Hx=(t,e="SIGTERM",r={})=>{let i=t(e);return qx(t,e,r,i),i},qx=(t,e,r,i)=>{if(!Ux(e,r,i))return;let n=zx(r),s=setTimeout(()=>{t("SIGKILL")},n);s.unref&&s.unref()},Ux=(t,{forceKillAfterTimeout:e},r)=>Gx(t)&&e!==!1&&r,Gx=t=>t===Mx.constants.signals.SIGTERM||typeof t=="string"&&t.toUpperCase()==="SIGTERM",zx=({forceKillAfterTimeout:t=!0})=>{if(t===!0)return $x;if(!Number.isFinite(t)||t<0)throw new TypeError(`Expected the \`forceKillAfterTimeout\` option to be a non-negative integer, got \`${t}\` (${typeof t})`);return t},Wx=(t,e)=>{t.kill()&&(e.isCanceled=!0)},Yx=(t,e,r)=>{t.kill(e),r(Object.assign(new Error("Timed out"),{timedOut:!0,signal:e}))},Vx=(t,{timeout:e,killSignal:r="SIGTERM"},i)=>{if(e===0||e===void 0)return i;let n,s=new Promise((a,u)=>{n=setTimeout(()=>{Yx(t,r,u)},e)}),o=i.finally(()=>{clearTimeout(n)});return Promise.race([s,o])},Kx=({timeout:t})=>{if(t!==void 0&&(!Number.isFinite(t)||t<0))throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${t}\` (${typeof t})`)},Zx=async(t,{cleanup:e,detached:r},i)=>{if(!e||r)return i;let n=jx(()=>{t.kill()});return i.finally(()=>{n()})};pg.exports={spawnedKill:Hx,spawnedCancel:Wx,setupTimeout:Vx,validateTimeout:Kx,setExitHandler:Zx}});var gg=$((d2,mg)=>{"use strict";var At=t=>t!==null&&typeof t=="object"&&typeof t.pipe=="function";At.writable=t=>At(t)&&t.writable!==!1&&typeof t._write=="function"&&typeof t._writableState=="object";At.readable=t=>At(t)&&t.readable!==!1&&typeof t._read=="function"&&typeof t._readableState=="object";At.duplex=t=>At.writable(t)&&At.readable(t);At.transform=t=>At.duplex(t)&&typeof t._transform=="function";mg.exports=At});var Eg=$((m2,yg)=>{"use strict";var{PassThrough:Jx}=require("stream");yg.exports=t=>{t={...t};let{array:e}=t,{encoding:r}=t,i=r==="buffer",n=!1;e?n=!(r||i):r=r||"utf8",i&&(r=null);let s=new Jx({objectMode:n});r&&s.setEncoding(r);let o=0,a=[];return s.on("data",u=>{a.push(u),n?o=a.length:o+=u.length}),s.getBufferedValue=()=>e?a:i?Buffer.concat(a,o):a.join(""),s.getBufferedLength=()=>o,s}});var Dg=$((g2,An)=>{"use strict";var{constants:Xx}=require("buffer"),Qx=require("stream"),{promisify:eR}=require("util"),tR=Eg(),rR=eR(Qx.pipeline),Vs=class extends Error{constructor(){super("maxBuffer exceeded"),this.name="MaxBufferError"}};async function $l(t,e){if(!t)throw new Error("Expected a stream");e={maxBuffer:1/0,...e};let{maxBuffer:r}=e,i=tR(e);return await new Promise((n,s)=>{let o=a=>{a&&i.getBufferedLength()<=Xx.MAX_LENGTH&&(a.bufferedData=i.getBufferedValue()),s(a)};(async()=>{try{await rR(t,i),n()}catch(a){o(a)}})(),i.on("data",()=>{i.getBufferedLength()>r&&o(new Vs)})}),i.getBufferedValue()}An.exports=$l;An.exports.buffer=(t,e)=>$l(t,{...e,encoding:"buffer"});An.exports.array=(t,e)=>$l(t,{...e,array:!0});An.exports.MaxBufferError=Vs});var _g=$((y2,bg)=>{"use strict";var{PassThrough:iR}=require("stream");bg.exports=function(){var t=[],e=new iR({objectMode:!0});return e.setMaxListeners(0),e.add=r,e.isEmpty=i,e.on("unpipe",n),Array.prototype.slice.call(arguments).forEach(r),e;function r(s){return Array.isArray(s)?(s.forEach(r),this):(t.push(s),s.once("end",n.bind(null,s)),s.once("error",e.emit.bind(e,"error")),s.pipe(e,{end:!1}),this)}function i(){return t.length==0}function n(s){t=t.filter(function(o){return o!==s}),!t.length&&e.readable&&e.end()}}});var vg=$((E2,Ag)=>{"use strict";var Sg=gg(),wg=Dg(),nR=_g(),sR=(t,e)=>{e===void 0||t.stdin===void 0||(Sg(e)?e.pipe(t.stdin):t.stdin.end(e))},oR=(t,{all:e})=>{if(!e||!t.stdout&&!t.stderr)return;let r=nR();return t.stdout&&r.add(t.stdout),t.stderr&&r.add(t.stderr),r},Hl=async(t,e)=>{if(t){t.destroy();try{return await e}catch(r){return r.bufferedData}}},ql=(t,{encoding:e,buffer:r,maxBuffer:i})=>{if(!(!t||!r))return e?wg(t,{encoding:e,maxBuffer:i}):wg.buffer(t,{maxBuffer:i})},aR=async({stdout:t,stderr:e,all:r},{encoding:i,buffer:n,maxBuffer:s},o)=>{let a=ql(t,{encoding:i,buffer:n,maxBuffer:s}),u=ql(e,{encoding:i,buffer:n,maxBuffer:s}),l=ql(r,{encoding:i,buffer:n,maxBuffer:s*2});try{return await Promise.all([o,a,u,l])}catch(c){return Promise.all([{error:c,signal:c.signal,timedOut:c.timedOut},Hl(t,a),Hl(e,u),Hl(r,l)])}},uR=({input:t})=>{if(Sg(t))throw new TypeError("The `input` option cannot be a stream in sync mode")};Ag.exports={handleInput:sR,makeAllStream:oR,getSpawnedResult:aR,validateInputSync:uR}});var xg=$((D2,Cg)=>{"use strict";var lR=(async()=>{})().constructor.prototype,cR=["then","catch","finally"].map(t=>[t,Reflect.getOwnPropertyDescriptor(lR,t)]),hR=(t,e)=>{for(let[r,i]of cR){let n=typeof e=="function"?(...s)=>Reflect.apply(i.value,e(),s):i.value.bind(e);Reflect.defineProperty(t,r,{...i,value:n})}return t},fR=t=>new Promise((e,r)=>{t.on("exit",(i,n)=>{e({exitCode:i,signal:n})}),t.on("error",i=>{r(i)}),t.stdin&&t.stdin.on("error",i=>{r(i)})});Cg.exports={mergePromise:hR,getSpawnedPromise:fR}});var Og=$((b2,Fg)=>{"use strict";var Rg=(t,e=[])=>Array.isArray(e)?[t,...e]:[t],pR=/^[\w.-]+$/,dR=/"/g,mR=t=>typeof t!="string"||pR.test(t)?t:`"${t.replace(dR,'\\"')}"`,gR=(t,e)=>Rg(t,e).join(" "),yR=(t,e)=>Rg(t,e).map(r=>mR(r)).join(" "),ER=/ +/g,DR=t=>{let e=[];for(let r of t.trim().split(ER)){let i=e[e.length-1];i&&i.endsWith("\\")?e[e.length-1]=`${i.slice(0,-1)} ${r}`:e.push(r)}return e};Fg.exports={joinCommand:gR,getEscapedCommand:yR,parseCommand:DR}});var ki=$((_2,Oi)=>{"use strict";var bR=require("path"),Ul=require("child_process"),_R=H0(),wR=U0(),SR=W0(),AR=Z0(),Ks=ng(),Tg=og(),{spawnedKill:vR,spawnedCancel:CR,setupTimeout:xR,validateTimeout:RR,setExitHandler:FR}=dg(),{handleInput:OR,getSpawnedResult:kR,makeAllStream:TR,validateInputSync:LR}=vg(),{mergePromise:kg,getSpawnedPromise:BR}=xg(),{joinCommand:Lg,parseCommand:Bg,getEscapedCommand:Pg}=Og(),PR=1e3*1e3*100,IR=({env:t,extendEnv:e,preferLocal:r,localDir:i,execPath:n})=>{let s=e?{...process.env,...t}:t;return r?SR.env({env:s,cwd:i,execPath:n}):s},Ig=(t,e,r={})=>{let i=_R._parse(t,e,r);return t=i.command,e=i.args,r=i.options,r={maxBuffer:PR,buffer:!0,stripFinalNewline:!0,extendEnv:!0,preferLocal:!1,localDir:r.cwd||process.cwd(),execPath:process.execPath,encoding:"utf8",reject:!0,cleanup:!0,all:!1,windowsHide:!0,...r},r.env=IR(r),r.stdio=Tg(r),process.platform==="win32"&&bR.basename(t,".exe")==="cmd"&&e.unshift("/q"),{file:t,args:e,options:r,parsed:i}},vn=(t,e,r)=>typeof e!="string"&&!Buffer.isBuffer(e)?r===void 0?void 0:"":t.stripFinalNewline?wR(e):e,Zs=(t,e,r)=>{let i=Ig(t,e,r),n=Lg(t,e),s=Pg(t,e);RR(i.options);let o;try{o=Ul.spawn(i.file,i.args,i.options)}catch(p){let g=new Ul.ChildProcess,y=Promise.reject(Ks({error:p,stdout:"",stderr:"",all:"",command:n,escapedCommand:s,parsed:i,timedOut:!1,isCanceled:!1,killed:!1}));return kg(g,y)}let a=BR(o),u=xR(o,i.options,a),l=FR(o,i.options,u),c={isCanceled:!1};o.kill=vR.bind(null,o.kill.bind(o)),o.cancel=CR.bind(null,o,c);let h=AR(async()=>{let[{error:p,exitCode:g,signal:y,timedOut:E},v,F,O]=await kR(o,i.options,l),R=vn(i.options,v),x=vn(i.options,F),L=vn(i.options,O);if(p||g!==0||y!==null){let b=Ks({error:p,exitCode:g,signal:y,stdout:R,stderr:x,all:L,command:n,escapedCommand:s,parsed:i,timedOut:E,isCanceled:c.isCanceled,killed:o.killed});if(!i.options.reject)return b;throw b}return{command:n,escapedCommand:s,exitCode:0,stdout:R,stderr:x,all:L,failed:!1,timedOut:!1,isCanceled:!1,killed:!1}});return OR(o,i.options.input),o.all=TR(o,i.options),kg(o,h)};Oi.exports=Zs;Oi.exports.sync=(t,e,r)=>{let i=Ig(t,e,r),n=Lg(t,e),s=Pg(t,e);LR(i.options);let o;try{o=Ul.spawnSync(i.file,i.args,i.options)}catch(l){throw Ks({error:l,stdout:"",stderr:"",all:"",command:n,escapedCommand:s,parsed:i,timedOut:!1,isCanceled:!1,killed:!1})}let a=vn(i.options,o.stdout,o.error),u=vn(i.options,o.stderr,o.error);if(o.error||o.status!==0||o.signal!==null){let l=Ks({stdout:a,stderr:u,error:o.error,signal:o.signal,exitCode:o.status,command:n,escapedCommand:s,parsed:i,timedOut:o.error&&o.error.code==="ETIMEDOUT",isCanceled:!1,killed:o.signal!==null});if(!i.options.reject)return l;throw l}return{command:n,escapedCommand:s,exitCode:0,stdout:a,stderr:u,failed:!1,timedOut:!1,isCanceled:!1,killed:!1}};Oi.exports.command=(t,e)=>{let[r,...i]=Bg(t);return Zs(r,i,e)};Oi.exports.commandSync=(t,e)=>{let[r,...i]=Bg(t);return Zs.sync(r,i,e)};Oi.exports.node=(t,e,r={})=>{e&&!Array.isArray(e)&&typeof e=="object"&&(r=e,e=[]);let i=Tg.node(r),n=process.execArgv.filter(a=>!a.startsWith("--inspect")),{nodePath:s=process.execPath,nodeOptions:o=n}=r;return Zs(s,[...o,t,...Array.isArray(e)?e:[]],{...r,stdin:void 0,stdout:void 0,stderr:void 0,stdio:i,shell:!1})}});var Ti=$((C2,Hg)=>{"use strict";var $g=new Map([["C","cwd"],["f","file"],["z","gzip"],["P","preservePaths"],["U","unlink"],["strip-components","strip"],["stripComponents","strip"],["keep-newer","newer"],["keepNewer","newer"],["keep-newer-files","newer"],["keepNewerFiles","newer"],["k","keep"],["keep-existing","keep"],["keepExisting","keep"],["m","noMtime"],["no-mtime","noMtime"],["p","preserveOwner"],["L","follow"],["h","follow"]]);Hg.exports=t=>t?Object.keys(t).map(e=>[$g.has(e)?$g.get(e):e,t[e]]).reduce((e,r)=>(e[r[0]]=r[1],e),Object.create(null)):{}});var ro=$((x2,Zg)=>{"use strict";var qg=typeof process=="object"&&process?process:{stdout:null,stderr:null},HR=require("events"),Ug=require("stream"),Gg=require("string_decoder").StringDecoder,qt=Symbol("EOF"),Ut=Symbol("maybeEmitEnd"),mr=Symbol("emittedEnd"),Js=Symbol("emittingEnd"),Cn=Symbol("emittedError"),Xs=Symbol("closed"),zg=Symbol("read"),Qs=Symbol("flush"),Wg=Symbol("flushChunk"),ze=Symbol("encoding"),Gt=Symbol("decoder"),eo=Symbol("flowing"),xn=Symbol("paused"),Li=Symbol("resume"),_e=Symbol("buffer"),vt=Symbol("pipes"),Re=Symbol("bufferLength"),Wl=Symbol("bufferPush"),Yl=Symbol("bufferShift"),Be=Symbol("objectMode"),Pe=Symbol("destroyed"),Vl=Symbol("emitData"),Yg=Symbol("emitEnd"),Kl=Symbol("emitEnd2"),zt=Symbol("async"),Rn=t=>Promise.resolve().then(t),Vg=global._MP_NO_ITERATOR_SYMBOLS_!=="1",qR=Vg&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),UR=Vg&&Symbol.iterator||Symbol("iterator not implemented"),GR=t=>t==="end"||t==="finish"||t==="prefinish",zR=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,WR=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),to=class{constructor(e,r,i){this.src=e,this.dest=r,this.opts=i,this.ondrain=()=>e[Li](),r.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},Zl=class extends to{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(e,r,i){super(e,r,i),this.proxyErrors=n=>r.emit("error",n),e.on("error",this.proxyErrors)}};Zg.exports=class Kg extends Ug{constructor(e){super(),this[eo]=!1,this[xn]=!1,this[vt]=[],this[_e]=[],this[Be]=e&&e.objectMode||!1,this[Be]?this[ze]=null:this[ze]=e&&e.encoding||null,this[ze]==="buffer"&&(this[ze]=null),this[zt]=e&&!!e.async||!1,this[Gt]=this[ze]?new Gg(this[ze]):null,this[qt]=!1,this[mr]=!1,this[Js]=!1,this[Xs]=!1,this[Cn]=null,this.writable=!0,this.readable=!0,this[Re]=0,this[Pe]=!1,e&&e.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[_e]}),e&&e.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[vt]})}get bufferLength(){return this[Re]}get encoding(){return this[ze]}set encoding(e){if(this[Be])throw new Error("cannot set encoding in objectMode");if(this[ze]&&e!==this[ze]&&(this[Gt]&&this[Gt].lastNeed||this[Re]))throw new Error("cannot change encoding");this[ze]!==e&&(this[Gt]=e?new Gg(e):null,this[_e].length&&(this[_e]=this[_e].map(r=>this[Gt].write(r)))),this[ze]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[Be]}set objectMode(e){this[Be]=this[Be]||!!e}get async(){return this[zt]}set async(e){this[zt]=this[zt]||!!e}write(e,r,i){if(this[qt])throw new Error("write after end");if(this[Pe])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof r=="function"&&(i=r,r="utf8"),r||(r="utf8");let n=this[zt]?Rn:s=>s();return!this[Be]&&!Buffer.isBuffer(e)&&(WR(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):zR(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),this[Be]?(this.flowing&&this[Re]!==0&&this[Qs](!0),this.flowing?this.emit("data",e):this[Wl](e),this[Re]!==0&&this.emit("readable"),i&&n(i),this.flowing):e.length?(typeof e=="string"&&!(r===this[ze]&&!this[Gt].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[ze]&&(e=this[Gt].write(e)),this.flowing&&this[Re]!==0&&this[Qs](!0),this.flowing?this.emit("data",e):this[Wl](e),this[Re]!==0&&this.emit("readable"),i&&n(i),this.flowing):(this[Re]!==0&&this.emit("readable"),i&&n(i),this.flowing)}read(e){if(this[Pe])return null;if(this[Re]===0||e===0||e>this[Re])return this[Ut](),null;this[Be]&&(e=null),this[_e].length>1&&!this[Be]&&(this.encoding?this[_e]=[this[_e].join("")]:this[_e]=[Buffer.concat(this[_e],this[Re])]);let r=this[zg](e||null,this[_e][0]);return this[Ut](),r}[zg](e,r){return e===r.length||e===null?this[Yl]():(this[_e][0]=r.slice(e),r=r.slice(0,e),this[Re]-=e),this.emit("data",r),!this[_e].length&&!this[qt]&&this.emit("drain"),r}end(e,r,i){return typeof e=="function"&&(i=e,e=null),typeof r=="function"&&(i=r,r="utf8"),e&&this.write(e,r),i&&this.once("end",i),this[qt]=!0,this.writable=!1,(this.flowing||!this[xn])&&this[Ut](),this}[Li](){this[Pe]||(this[xn]=!1,this[eo]=!0,this.emit("resume"),this[_e].length?this[Qs]():this[qt]?this[Ut]():this.emit("drain"))}resume(){return this[Li]()}pause(){this[eo]=!1,this[xn]=!0}get destroyed(){return this[Pe]}get flowing(){return this[eo]}get paused(){return this[xn]}[Wl](e){this[Be]?this[Re]+=1:this[Re]+=e.length,this[_e].push(e)}[Yl](){return this[_e].length&&(this[Be]?this[Re]-=1:this[Re]-=this[_e][0].length),this[_e].shift()}[Qs](e){do;while(this[Wg](this[Yl]()));!e&&!this[_e].length&&!this[qt]&&this.emit("drain")}[Wg](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Pe])return;let i=this[mr];return r=r||{},e===qg.stdout||e===qg.stderr?r.end=!1:r.end=r.end!==!1,r.proxyErrors=!!r.proxyErrors,i?r.end&&e.end():(this[vt].push(r.proxyErrors?new Zl(this,e,r):new to(this,e,r)),this[zt]?Rn(()=>this[Li]()):this[Li]()),e}unpipe(e){let r=this[vt].find(i=>i.dest===e);r&&(this[vt].splice(this[vt].indexOf(r),1),r.unpipe())}addListener(e,r){return this.on(e,r)}on(e,r){let i=super.on(e,r);return e==="data"&&!this[vt].length&&!this.flowing?this[Li]():e==="readable"&&this[Re]!==0?super.emit("readable"):GR(e)&&this[mr]?(super.emit(e),this.removeAllListeners(e)):e==="error"&&this[Cn]&&(this[zt]?Rn(()=>r.call(this,this[Cn])):r.call(this,this[Cn])),i}get emittedEnd(){return this[mr]}[Ut](){!this[Js]&&!this[mr]&&!this[Pe]&&this[_e].length===0&&this[qt]&&(this[Js]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[Xs]&&this.emit("close"),this[Js]=!1)}emit(e,r,...i){if(e!=="error"&&e!=="close"&&e!==Pe&&this[Pe])return;if(e==="data")return r?this[zt]?Rn(()=>this[Vl](r)):this[Vl](r):!1;if(e==="end")return this[Yg]();if(e==="close"){if(this[Xs]=!0,!this[mr]&&!this[Pe])return;let s=super.emit("close");return this.removeAllListeners("close"),s}else if(e==="error"){this[Cn]=r;let s=super.emit("error",r);return this[Ut](),s}else if(e==="resume"){let s=super.emit("resume");return this[Ut](),s}else if(e==="finish"||e==="prefinish"){let s=super.emit(e);return this.removeAllListeners(e),s}let n=super.emit(e,r,...i);return this[Ut](),n}[Vl](e){for(let i of this[vt])i.dest.write(e)===!1&&this.pause();let r=super.emit("data",e);return this[Ut](),r}[Yg](){this[mr]||(this[mr]=!0,this.readable=!1,this[zt]?Rn(()=>this[Kl]()):this[Kl]())}[Kl](){if(this[Gt]){let r=this[Gt].end();if(r){for(let i of this[vt])i.dest.write(r);super.emit("data",r)}}for(let r of this[vt])r.end();let e=super.emit("end");return this.removeAllListeners("end"),e}collect(){let e=[];this[Be]||(e.dataLength=0);let r=this.promise();return this.on("data",i=>{e.push(i),this[Be]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[Be]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[Be]?Promise.reject(new Error("cannot concat in objectMode")):this[ze]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Pe,()=>r(new Error("stream destroyed"))),this.on("error",i=>r(i)),this.on("end",()=>e())})}[qR](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[qt])return Promise.resolve({done:!0});let i=null,n=null,s=l=>{this.removeListener("data",o),this.removeListener("end",a),n(l)},o=l=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:l,done:!!this[qt]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},u=()=>s(new Error("stream destroyed"));return new Promise((l,c)=>{n=c,i=l,this.once(Pe,u),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[UR](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Pe]?(e?this.emit("error",e):this.emit(Pe),this):(this[Pe]=!0,this[_e].length=0,this[Re]=0,typeof this.close=="function"&&!this[Xs]&&this.close(),e?this.emit("error",e):this.emit(Pe),this)}static isStream(e){return!!e&&(e instanceof Kg||e instanceof Ug||e instanceof HR&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var Xg=$((R2,Jg)=>{var YR=require("zlib").constants||{ZLIB_VERNUM:4736};Jg.exports=Object.freeze(Object.assign(Object.create(null),{Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_VERSION_ERROR:-6,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,DEFLATE:1,INFLATE:2,GZIP:3,GUNZIP:4,DEFLATERAW:5,INFLATERAW:6,UNZIP:7,BROTLI_DECODE:8,BROTLI_ENCODE:9,Z_MIN_WINDOWBITS:8,Z_MAX_WINDOWBITS:15,Z_DEFAULT_WINDOWBITS:15,Z_MIN_CHUNK:64,Z_MAX_CHUNK:1/0,Z_DEFAULT_CHUNK:16384,Z_MIN_MEMLEVEL:1,Z_MAX_MEMLEVEL:9,Z_DEFAULT_MEMLEVEL:8,Z_MIN_LEVEL:-1,Z_MAX_LEVEL:9,Z_DEFAULT_LEVEL:-1,BROTLI_OPERATION_PROCESS:0,BROTLI_OPERATION_FLUSH:1,BROTLI_OPERATION_FINISH:2,BROTLI_OPERATION_EMIT_METADATA:3,BROTLI_MODE_GENERIC:0,BROTLI_MODE_TEXT:1,BROTLI_MODE_FONT:2,BROTLI_DEFAULT_MODE:0,BROTLI_MIN_QUALITY:0,BROTLI_MAX_QUALITY:11,BROTLI_DEFAULT_QUALITY:11,BROTLI_MIN_WINDOW_BITS:10,BROTLI_MAX_WINDOW_BITS:24,BROTLI_LARGE_MAX_WINDOW_BITS:30,BROTLI_DEFAULT_WINDOW:22,BROTLI_MIN_INPUT_BLOCK_BITS:16,BROTLI_MAX_INPUT_BLOCK_BITS:24,BROTLI_PARAM_MODE:0,BROTLI_PARAM_QUALITY:1,BROTLI_PARAM_LGWIN:2,BROTLI_PARAM_LGBLOCK:3,BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING:4,BROTLI_PARAM_SIZE_HINT:5,BROTLI_PARAM_LARGE_WINDOW:6,BROTLI_PARAM_NPOSTFIX:7,BROTLI_PARAM_NDIRECT:8,BROTLI_DECODER_RESULT_ERROR:0,BROTLI_DECODER_RESULT_SUCCESS:1,BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT:2,BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION:0,BROTLI_DECODER_PARAM_LARGE_WINDOW:1,BROTLI_DECODER_NO_ERROR:0,BROTLI_DECODER_SUCCESS:1,BROTLI_DECODER_NEEDS_MORE_INPUT:2,BROTLI_DECODER_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE:-1,BROTLI_DECODER_ERROR_FORMAT_RESERVED:-2,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE:-3,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET:-4,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME:-5,BROTLI_DECODER_ERROR_FORMAT_CL_SPACE:-6,BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE:-7,BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT:-8,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1:-9,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2:-10,BROTLI_DECODER_ERROR_FORMAT_TRANSFORM:-11,BROTLI_DECODER_ERROR_FORMAT_DICTIONARY:-12,BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS:-13,BROTLI_DECODER_ERROR_FORMAT_PADDING_1:-14,BROTLI_DECODER_ERROR_FORMAT_PADDING_2:-15,BROTLI_DECODER_ERROR_FORMAT_DISTANCE:-16,BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET:-19,BROTLI_DECODER_ERROR_INVALID_ARGUMENTS:-20,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES:-21,BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS:-22,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP:-25,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1:-26,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2:-27,BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES:-30,BROTLI_DECODER_ERROR_UNREACHABLE:-31},YR))});var rc=$((F2,ay)=>{"use strict";var Qg=typeof process=="object"&&process?process:{stdout:null,stderr:null},VR=require("events"),ey=require("stream"),ty=require("string_decoder").StringDecoder,Wt=Symbol("EOF"),Yt=Symbol("maybeEmitEnd"),gr=Symbol("emittedEnd"),io=Symbol("emittingEnd"),Fn=Symbol("emittedError"),no=Symbol("closed"),ry=Symbol("read"),so=Symbol("flush"),iy=Symbol("flushChunk"),We=Symbol("encoding"),Vt=Symbol("decoder"),oo=Symbol("flowing"),On=Symbol("paused"),Bi=Symbol("resume"),Fe=Symbol("bufferLength"),Jl=Symbol("bufferPush"),Xl=Symbol("bufferShift"),Ie=Symbol("objectMode"),Ne=Symbol("destroyed"),Ql=Symbol("emitData"),ny=Symbol("emitEnd"),ec=Symbol("emitEnd2"),Kt=Symbol("async"),kn=t=>Promise.resolve().then(t),sy=global._MP_NO_ITERATOR_SYMBOLS_!=="1",KR=sy&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),ZR=sy&&Symbol.iterator||Symbol("iterator not implemented"),JR=t=>t==="end"||t==="finish"||t==="prefinish",XR=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,QR=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),ao=class{constructor(e,r,i){this.src=e,this.dest=r,this.opts=i,this.ondrain=()=>e[Bi](),r.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},tc=class extends ao{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(e,r,i){super(e,r,i),this.proxyErrors=n=>r.emit("error",n),e.on("error",this.proxyErrors)}};ay.exports=class oy extends ey{constructor(e){super(),this[oo]=!1,this[On]=!1,this.pipes=[],this.buffer=[],this[Ie]=e&&e.objectMode||!1,this[Ie]?this[We]=null:this[We]=e&&e.encoding||null,this[We]==="buffer"&&(this[We]=null),this[Kt]=e&&!!e.async||!1,this[Vt]=this[We]?new ty(this[We]):null,this[Wt]=!1,this[gr]=!1,this[io]=!1,this[no]=!1,this[Fn]=null,this.writable=!0,this.readable=!0,this[Fe]=0,this[Ne]=!1}get bufferLength(){return this[Fe]}get encoding(){return this[We]}set encoding(e){if(this[Ie])throw new Error("cannot set encoding in objectMode");if(this[We]&&e!==this[We]&&(this[Vt]&&this[Vt].lastNeed||this[Fe]))throw new Error("cannot change encoding");this[We]!==e&&(this[Vt]=e?new ty(e):null,this.buffer.length&&(this.buffer=this.buffer.map(r=>this[Vt].write(r)))),this[We]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[Ie]}set objectMode(e){this[Ie]=this[Ie]||!!e}get async(){return this[Kt]}set async(e){this[Kt]=this[Kt]||!!e}write(e,r,i){if(this[Wt])throw new Error("write after end");if(this[Ne])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof r=="function"&&(i=r,r="utf8"),r||(r="utf8");let n=this[Kt]?kn:s=>s();return!this[Ie]&&!Buffer.isBuffer(e)&&(QR(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):XR(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),this[Ie]?(this.flowing&&this[Fe]!==0&&this[so](!0),this.flowing?this.emit("data",e):this[Jl](e),this[Fe]!==0&&this.emit("readable"),i&&n(i),this.flowing):e.length?(typeof e=="string"&&!(r===this[We]&&!this[Vt].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[We]&&(e=this[Vt].write(e)),this.flowing&&this[Fe]!==0&&this[so](!0),this.flowing?this.emit("data",e):this[Jl](e),this[Fe]!==0&&this.emit("readable"),i&&n(i),this.flowing):(this[Fe]!==0&&this.emit("readable"),i&&n(i),this.flowing)}read(e){if(this[Ne])return null;if(this[Fe]===0||e===0||e>this[Fe])return this[Yt](),null;this[Ie]&&(e=null),this.buffer.length>1&&!this[Ie]&&(this.encoding?this.buffer=[this.buffer.join("")]:this.buffer=[Buffer.concat(this.buffer,this[Fe])]);let r=this[ry](e||null,this.buffer[0]);return this[Yt](),r}[ry](e,r){return e===r.length||e===null?this[Xl]():(this.buffer[0]=r.slice(e),r=r.slice(0,e),this[Fe]-=e),this.emit("data",r),!this.buffer.length&&!this[Wt]&&this.emit("drain"),r}end(e,r,i){return typeof e=="function"&&(i=e,e=null),typeof r=="function"&&(i=r,r="utf8"),e&&this.write(e,r),i&&this.once("end",i),this[Wt]=!0,this.writable=!1,(this.flowing||!this[On])&&this[Yt](),this}[Bi](){this[Ne]||(this[On]=!1,this[oo]=!0,this.emit("resume"),this.buffer.length?this[so]():this[Wt]?this[Yt]():this.emit("drain"))}resume(){return this[Bi]()}pause(){this[oo]=!1,this[On]=!0}get destroyed(){return this[Ne]}get flowing(){return this[oo]}get paused(){return this[On]}[Jl](e){this[Ie]?this[Fe]+=1:this[Fe]+=e.length,this.buffer.push(e)}[Xl](){return this.buffer.length&&(this[Ie]?this[Fe]-=1:this[Fe]-=this.buffer[0].length),this.buffer.shift()}[so](e){do;while(this[iy](this[Xl]()));!e&&!this.buffer.length&&!this[Wt]&&this.emit("drain")}[iy](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Ne])return;let i=this[gr];return r=r||{},e===Qg.stdout||e===Qg.stderr?r.end=!1:r.end=r.end!==!1,r.proxyErrors=!!r.proxyErrors,i?r.end&&e.end():(this.pipes.push(r.proxyErrors?new tc(this,e,r):new ao(this,e,r)),this[Kt]?kn(()=>this[Bi]()):this[Bi]()),e}unpipe(e){let r=this.pipes.find(i=>i.dest===e);r&&(this.pipes.splice(this.pipes.indexOf(r),1),r.unpipe())}addListener(e,r){return this.on(e,r)}on(e,r){let i=super.on(e,r);return e==="data"&&!this.pipes.length&&!this.flowing?this[Bi]():e==="readable"&&this[Fe]!==0?super.emit("readable"):JR(e)&&this[gr]?(super.emit(e),this.removeAllListeners(e)):e==="error"&&this[Fn]&&(this[Kt]?kn(()=>r.call(this,this[Fn])):r.call(this,this[Fn])),i}get emittedEnd(){return this[gr]}[Yt](){!this[io]&&!this[gr]&&!this[Ne]&&this.buffer.length===0&&this[Wt]&&(this[io]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[no]&&this.emit("close"),this[io]=!1)}emit(e,r,...i){if(e!=="error"&&e!=="close"&&e!==Ne&&this[Ne])return;if(e==="data")return r?this[Kt]?kn(()=>this[Ql](r)):this[Ql](r):!1;if(e==="end")return this[ny]();if(e==="close"){if(this[no]=!0,!this[gr]&&!this[Ne])return;let s=super.emit("close");return this.removeAllListeners("close"),s}else if(e==="error"){this[Fn]=r;let s=super.emit("error",r);return this[Yt](),s}else if(e==="resume"){let s=super.emit("resume");return this[Yt](),s}else if(e==="finish"||e==="prefinish"){let s=super.emit(e);return this.removeAllListeners(e),s}let n=super.emit(e,r,...i);return this[Yt](),n}[Ql](e){for(let i of this.pipes)i.dest.write(e)===!1&&this.pause();let r=super.emit("data",e);return this[Yt](),r}[ny](){this[gr]||(this[gr]=!0,this.readable=!1,this[Kt]?kn(()=>this[ec]()):this[ec]())}[ec](){if(this[Vt]){let r=this[Vt].end();if(r){for(let i of this.pipes)i.dest.write(r);super.emit("data",r)}}for(let r of this.pipes)r.end();let e=super.emit("end");return this.removeAllListeners("end"),e}collect(){let e=[];this[Ie]||(e.dataLength=0);let r=this.promise();return this.on("data",i=>{e.push(i),this[Ie]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[Ie]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[Ie]?Promise.reject(new Error("cannot concat in objectMode")):this[We]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Ne,()=>r(new Error("stream destroyed"))),this.on("error",i=>r(i)),this.on("end",()=>e())})}[KR](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[Wt])return Promise.resolve({done:!0});let i=null,n=null,s=l=>{this.removeListener("data",o),this.removeListener("end",a),n(l)},o=l=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:l,done:!!this[Wt]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},u=()=>s(new Error("stream destroyed"));return new Promise((l,c)=>{n=c,i=l,this.once(Ne,u),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[ZR](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Ne]?(e?this.emit("error",e):this.emit(Ne),this):(this[Ne]=!0,this.buffer.length=0,this[Fe]=0,typeof this.close=="function"&&!this[no]&&this.close(),e?this.emit("error",e):this.emit(Ne),this)}static isStream(e){return!!e&&(e instanceof oy||e instanceof ey||e instanceof VR&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var Ec=$(Xe=>{"use strict";var ac=require("assert"),yr=require("buffer").Buffer,cy=require("zlib"),Gr=Xe.constants=Xg(),eF=rc(),uy=yr.concat,zr=Symbol("_superWrite"),Ii=class extends Error{constructor(e){super("zlib: "+e.message),this.code=e.code,this.errno=e.errno,this.code||(this.code="ZLIB_ERROR"),this.message="zlib: "+e.message,Error.captureStackTrace(this,this.constructor)}get name(){return"ZlibError"}},tF=Symbol("opts"),Tn=Symbol("flushFlag"),ly=Symbol("finishFlushFlag"),yc=Symbol("fullFlushFlag"),de=Symbol("handle"),uo=Symbol("onError"),Pi=Symbol("sawError"),ic=Symbol("level"),nc=Symbol("strategy"),sc=Symbol("ended"),O2=Symbol("_defaultFullFlush"),lo=class extends eF{constructor(e,r){if(!e||typeof e!="object")throw new TypeError("invalid options for ZlibBase constructor");super(e),this[Pi]=!1,this[sc]=!1,this[tF]=e,this[Tn]=e.flush,this[ly]=e.finishFlush;try{this[de]=new cy[r](e)}catch(i){throw new Ii(i)}this[uo]=i=>{this[Pi]||(this[Pi]=!0,this.close(),this.emit("error",i))},this[de].on("error",i=>this[uo](new Ii(i))),this.once("end",()=>this.close)}close(){this[de]&&(this[de].close(),this[de]=null,this.emit("close"))}reset(){if(!this[Pi])return ac(this[de],"zlib binding closed"),this[de].reset()}flush(e){this.ended||(typeof e!="number"&&(e=this[yc]),this.write(Object.assign(yr.alloc(0),{[Tn]:e})))}end(e,r,i){return e&&this.write(e,r),this.flush(this[ly]),this[sc]=!0,super.end(null,null,i)}get ended(){return this[sc]}write(e,r,i){if(typeof r=="function"&&(i=r,r="utf8"),typeof e=="string"&&(e=yr.from(e,r)),this[Pi])return;ac(this[de],"zlib binding closed");let n=this[de]._handle,s=n.close;n.close=()=>{};let o=this[de].close;this[de].close=()=>{},yr.concat=l=>l;let a;try{let l=typeof e[Tn]=="number"?e[Tn]:this[Tn];a=this[de]._processChunk(e,l),yr.concat=uy}catch(l){yr.concat=uy,this[uo](new Ii(l))}finally{this[de]&&(this[de]._handle=n,n.close=s,this[de].close=o,this[de].removeAllListeners("error"))}this[de]&&this[de].on("error",l=>this[uo](new Ii(l)));let u;if(a)if(Array.isArray(a)&&a.length>0){u=this[zr](yr.from(a[0]));for(let l=1;l<a.length;l++)u=this[zr](a[l])}else u=this[zr](yr.from(a));return i&&i(),u}[zr](e){return super.write(e)}},Zt=class extends lo{constructor(e,r){e=e||{},e.flush=e.flush||Gr.Z_NO_FLUSH,e.finishFlush=e.finishFlush||Gr.Z_FINISH,super(e,r),this[yc]=Gr.Z_FULL_FLUSH,this[ic]=e.level,this[nc]=e.strategy}params(e,r){if(!this[Pi]){if(!this[de])throw new Error("cannot switch params when binding is closed");if(!this[de].params)throw new Error("not supported in this implementation");if(this[ic]!==e||this[nc]!==r){this.flush(Gr.Z_SYNC_FLUSH),ac(this[de],"zlib binding closed");let i=this[de].flush;this[de].flush=(n,s)=>{this.flush(n),s()};try{this[de].params(e,r)}finally{this[de].flush=i}this[de]&&(this[ic]=e,this[nc]=r)}}}},uc=class extends Zt{constructor(e){super(e,"Deflate")}},lc=class extends Zt{constructor(e){super(e,"Inflate")}},oc=Symbol("_portable"),cc=class extends Zt{constructor(e){super(e,"Gzip"),this[oc]=e&&!!e.portable}[zr](e){return this[oc]?(this[oc]=!1,e[9]=255,super[zr](e)):super[zr](e)}},hc=class extends Zt{constructor(e){super(e,"Gunzip")}},fc=class extends Zt{constructor(e){super(e,"DeflateRaw")}},pc=class extends Zt{constructor(e){super(e,"InflateRaw")}},dc=class extends Zt{constructor(e){super(e,"Unzip")}},co=class extends lo{constructor(e,r){e=e||{},e.flush=e.flush||Gr.BROTLI_OPERATION_PROCESS,e.finishFlush=e.finishFlush||Gr.BROTLI_OPERATION_FINISH,super(e,r),this[yc]=Gr.BROTLI_OPERATION_FLUSH}},mc=class extends co{constructor(e){super(e,"BrotliCompress")}},gc=class extends co{constructor(e){super(e,"BrotliDecompress")}};Xe.Deflate=uc;Xe.Inflate=lc;Xe.Gzip=cc;Xe.Gunzip=hc;Xe.DeflateRaw=fc;Xe.InflateRaw=pc;Xe.Unzip=dc;typeof cy.BrotliCompress=="function"?(Xe.BrotliCompress=mc,Xe.BrotliDecompress=gc):Xe.BrotliCompress=Xe.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}});var Ni=$((L2,hy)=>{var rF=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform;hy.exports=rF!=="win32"?t=>t:t=>t&&t.replace(/\\/g,"/")});var ho=$((P2,fy)=>{"use strict";var iF=ro(),Dc=Ni(),bc=Symbol("slurp");fy.exports=class extends iF{constructor(e,r,i){switch(super(),this.pause(),this.extended=r,this.globalExtended=i,this.header=e,this.startBlockSize=512*Math.ceil(e.size/512),this.blockRemain=this.startBlockSize,this.remain=e.size,this.type=e.type,this.meta=!1,this.ignore=!1,this.type){case"File":case"OldFile":case"Link":case"SymbolicLink":case"CharacterDevice":case"BlockDevice":case"Directory":case"FIFO":case"ContiguousFile":case"GNUDumpDir":break;case"NextFileHasLongLinkpath":case"NextFileHasLongPath":case"OldGnuLongPath":case"GlobalExtendedHeader":case"ExtendedHeader":case"OldExtendedHeader":this.meta=!0;break;default:this.ignore=!0}this.path=Dc(e.path),this.mode=e.mode,this.mode&&(this.mode=this.mode&4095),this.uid=e.uid,this.gid=e.gid,this.uname=e.uname,this.gname=e.gname,this.size=e.size,this.mtime=e.mtime,this.atime=e.atime,this.ctime=e.ctime,this.linkpath=Dc(e.linkpath),this.uname=e.uname,this.gname=e.gname,r&&this[bc](r),i&&this[bc](i,!0)}write(e){let r=e.length;if(r>this.blockRemain)throw new Error("writing more to entry than is appropriate");let i=this.remain,n=this.blockRemain;return this.remain=Math.max(0,i-r),this.blockRemain=Math.max(0,n-r),this.ignore?!0:i>=r?super.write(e):super.write(e.slice(0,i))}[bc](e,r){for(let i in e)e[i]!==null&&e[i]!==void 0&&!(r&&i==="path")&&(this[i]=i==="path"||i==="linkpath"?Dc(e[i]):e[i])}}});var _c=$(fo=>{"use strict";fo.name=new Map([["0","File"],["","OldFile"],["1","Link"],["2","SymbolicLink"],["3","CharacterDevice"],["4","BlockDevice"],["5","Directory"],["6","FIFO"],["7","ContiguousFile"],["g","GlobalExtendedHeader"],["x","ExtendedHeader"],["A","SolarisACL"],["D","GNUDumpDir"],["I","Inode"],["K","NextFileHasLongLinkpath"],["L","NextFileHasLongPath"],["M","ContinuationFile"],["N","OldGnuLongPath"],["S","SparseFile"],["V","TapeVolumeHeader"],["X","OldExtendedHeader"]]);fo.code=new Map(Array.from(fo.name).map(t=>[t[1],t[0]]))});var gy=$((N2,my)=>{"use strict";var nF=(t,e)=>{if(Number.isSafeInteger(t))t<0?oF(t,e):sF(t,e);else throw Error("cannot encode number outside of javascript safe integer range");return e},sF=(t,e)=>{e[0]=128;for(var r=e.length;r>1;r--)e[r-1]=t&255,t=Math.floor(t/256)},oF=(t,e)=>{e[0]=255;var r=!1;t=t*-1;for(var i=e.length;i>1;i--){var n=t&255;t=Math.floor(t/256),r?e[i-1]=py(n):n===0?e[i-1]=0:(r=!0,e[i-1]=dy(n))}},aF=t=>{let e=t[0],r=e===128?lF(t.slice(1,t.length)):e===255?uF(t):null;if(r===null)throw Error("invalid base256 encoding");if(!Number.isSafeInteger(r))throw Error("parsed number outside of javascript safe integer range");return r},uF=t=>{for(var e=t.length,r=0,i=!1,n=e-1;n>-1;n--){var s=t[n],o;i?o=py(s):s===0?o=s:(i=!0,o=dy(s)),o!==0&&(r-=o*Math.pow(256,e-n-1))}return r},lF=t=>{for(var e=t.length,r=0,i=e-1;i>-1;i--){var n=t[i];n!==0&&(r+=n*Math.pow(256,e-i-1))}return r},py=t=>(255^t)&255,dy=t=>(255^t)+1&255;my.exports={encode:nF,parse:aF}});var ji=$((M2,Ey)=>{"use strict";var wc=_c(),Mi=require("path").posix,yy=gy(),Sc=Symbol("slurp"),Qe=Symbol("type"),Cc=class{constructor(e,r,i,n){this.cksumValid=!1,this.needPax=!1,this.nullBlock=!1,this.block=null,this.path=null,this.mode=null,this.uid=null,this.gid=null,this.size=null,this.mtime=null,this.cksum=null,this[Qe]="0",this.linkpath=null,this.uname=null,this.gname=null,this.devmaj=0,this.devmin=0,this.atime=null,this.ctime=null,Buffer.isBuffer(e)?this.decode(e,r||0,i,n):e&&this.set(e)}decode(e,r,i,n){if(r||(r=0),!e||!(e.length>=r+512))throw new Error("need 512 bytes for header");if(this.path=Wr(e,r,100),this.mode=Er(e,r+100,8),this.uid=Er(e,r+108,8),this.gid=Er(e,r+116,8),this.size=Er(e,r+124,12),this.mtime=Ac(e,r+136,12),this.cksum=Er(e,r+148,12),this[Sc](i),this[Sc](n,!0),this[Qe]=Wr(e,r+156,1),this[Qe]===""&&(this[Qe]="0"),this[Qe]==="0"&&this.path.slice(-1)==="/"&&(this[Qe]="5"),this[Qe]==="5"&&(this.size=0),this.linkpath=Wr(e,r+157,100),e.slice(r+257,r+265).toString()==="ustar\x0000")if(this.uname=Wr(e,r+265,32),this.gname=Wr(e,r+297,32),this.devmaj=Er(e,r+329,8),this.devmin=Er(e,r+337,8),e[r+475]!==0){let o=Wr(e,r+345,155);this.path=o+"/"+this.path}else{let o=Wr(e,r+345,130);o&&(this.path=o+"/"+this.path),this.atime=Ac(e,r+476,12),this.ctime=Ac(e,r+488,12)}let s=8*32;for(let o=r;o<r+148;o++)s+=e[o];for(let o=r+156;o<r+512;o++)s+=e[o];this.cksumValid=s===this.cksum,this.cksum===null&&s===8*32&&(this.nullBlock=!0)}[Sc](e,r){for(let i in e)e[i]!==null&&e[i]!==void 0&&!(r&&i==="path")&&(this[i]=e[i])}encode(e,r){if(e||(e=this.block=Buffer.alloc(512),r=0),r||(r=0),!(e.length>=r+512))throw new Error("need 512 bytes for header");let i=this.ctime||this.atime?130:155,n=cF(this.path||"",i),s=n[0],o=n[1];this.needPax=n[2],this.needPax=Yr(e,r,100,s)||this.needPax,this.needPax=Dr(e,r+100,8,this.mode)||this.needPax,this.needPax=Dr(e,r+108,8,this.uid)||this.needPax,this.needPax=Dr(e,r+116,8,this.gid)||this.needPax,this.needPax=Dr(e,r+124,12,this.size)||this.needPax,this.needPax=vc(e,r+136,12,this.mtime)||this.needPax,e[r+156]=this[Qe].charCodeAt(0),this.needPax=Yr(e,r+157,100,this.linkpath)||this.needPax,e.write("ustar\x0000",r+257,8),this.needPax=Yr(e,r+265,32,this.uname)||this.needPax,this.needPax=Yr(e,r+297,32,this.gname)||this.needPax,this.needPax=Dr(e,r+329,8,this.devmaj)||this.needPax,this.needPax=Dr(e,r+337,8,this.devmin)||this.needPax,this.needPax=Yr(e,r+345,i,o)||this.needPax,e[r+475]!==0?this.needPax=Yr(e,r+345,155,o)||this.needPax:(this.needPax=Yr(e,r+345,130,o)||this.needPax,this.needPax=vc(e,r+476,12,this.atime)||this.needPax,this.needPax=vc(e,r+488,12,this.ctime)||this.needPax);let a=8*32;for(let u=r;u<r+148;u++)a+=e[u];for(let u=r+156;u<r+512;u++)a+=e[u];return this.cksum=a,Dr(e,r+148,8,this.cksum),this.cksumValid=!0,this.needPax}set(e){for(let r in e)e[r]!==null&&e[r]!==void 0&&(this[r]=e[r])}get type(){return wc.name.get(this[Qe])||this[Qe]}get typeKey(){return this[Qe]}set type(e){wc.code.has(e)?this[Qe]=wc.code.get(e):this[Qe]=e}},cF=(t,e)=>{let i=t,n="",s,o=Mi.parse(t).root||".";if(Buffer.byteLength(i)<100)s=[i,n,!1];else{n=Mi.dirname(i),i=Mi.basename(i);do Buffer.byteLength(i)<=100&&Buffer.byteLength(n)<=e?s=[i,n,!1]:Buffer.byteLength(i)>100&&Buffer.byteLength(n)<=e?s=[i.slice(0,100-1),n,!0]:(i=Mi.join(Mi.basename(n),i),n=Mi.dirname(n));while(n!==o&&!s);s||(s=[t.slice(0,100-1),"",!0])}return s},Wr=(t,e,r)=>t.slice(e,e+r).toString("utf8").replace(/\0.*/,""),Ac=(t,e,r)=>hF(Er(t,e,r)),hF=t=>t===null?null:new Date(t*1e3),Er=(t,e,r)=>t[e]&128?yy.parse(t.slice(e,e+r)):pF(t,e,r),fF=t=>isNaN(t)?null:t,pF=(t,e,r)=>fF(parseInt(t.slice(e,e+r).toString("utf8").replace(/\0.*$/,"").trim(),8)),dF={12:8589934591,8:2097151},Dr=(t,e,r,i)=>i===null?!1:i>dF[r]||i<0?(yy.encode(i,t.slice(e,e+r)),!0):(mF(t,e,r,i),!1),mF=(t,e,r,i)=>t.write(gF(i,r),e,r,"ascii"),gF=(t,e)=>yF(Math.floor(t).toString(8),e),yF=(t,e)=>(t.length===e-1?t:new Array(e-t.length-1).join("0")+t+" ")+"\0",vc=(t,e,r,i)=>i===null?!1:Dr(t,e,r,i.getTime()/1e3),EF=new Array(156).join("\0"),Yr=(t,e,r,i)=>i===null?!1:(t.write(i+EF,e,r,"utf8"),i.length!==Buffer.byteLength(i)||i.length>r);Ey.exports=Cc});var po=$((j2,Dy)=>{"use strict";var DF=ji(),bF=require("path"),Ln=class{constructor(e,r){this.atime=e.atime||null,this.charset=e.charset||null,this.comment=e.comment||null,this.ctime=e.ctime||null,this.gid=e.gid||null,this.gname=e.gname||null,this.linkpath=e.linkpath||null,this.mtime=e.mtime||null,this.path=e.path||null,this.size=e.size||null,this.uid=e.uid||null,this.uname=e.uname||null,this.dev=e.dev||null,this.ino=e.ino||null,this.nlink=e.nlink||null,this.global=r||!1}encode(){let e=this.encodeBody();if(e==="")return null;let r=Buffer.byteLength(e),i=512*Math.ceil(1+r/512),n=Buffer.allocUnsafe(i);for(let s=0;s<512;s++)n[s]=0;new DF({path:("PaxHeader/"+bF.basename(this.path)).slice(0,99),mode:this.mode||420,uid:this.uid||null,gid:this.gid||null,size:r,mtime:this.mtime||null,type:this.global?"GlobalExtendedHeader":"ExtendedHeader",linkpath:"",uname:this.uname||"",gname:this.gname||"",devmaj:0,devmin:0,atime:this.atime||null,ctime:this.ctime||null}).encode(n),n.write(e,512,r,"utf8");for(let s=r+512;s<n.length;s++)n[s]=0;return n}encodeBody(){return this.encodeField("path")+this.encodeField("ctime")+this.encodeField("atime")+this.encodeField("dev")+this.encodeField("ino")+this.encodeField("nlink")+this.encodeField("charset")+this.encodeField("comment")+this.encodeField("gid")+this.encodeField("gname")+this.encodeField("linkpath")+this.encodeField("mtime")+this.encodeField("size")+this.encodeField("uid")+this.encodeField("uname")}encodeField(e){if(this[e]===null||this[e]===void 0)return"";let r=this[e]instanceof Date?this[e].getTime()/1e3:this[e],i=" "+(e==="dev"||e==="ino"||e==="nlink"?"SCHILY.":"")+e+"="+r+`
8
8
  `,n=Buffer.byteLength(i),s=Math.floor(Math.log(n)/Math.log(10))+1;return n+s>=Math.pow(10,s)&&(s+=1),s+n+i}};Ln.parse=(t,e,r)=>new Ln(_F(wF(t),e),r);var _F=(t,e)=>e?Object.keys(t).reduce((r,i)=>(r[i]=t[i],r),e):t,wF=t=>t.replace(/\n$/,"").split(`
9
- `).reduce(SF,Object.create(null)),SF=(t,e)=>{let r=parseInt(e,10);if(r!==Buffer.byteLength(e)+1)return t;e=e.slice((r+" ").length);let i=e.split("="),n=i.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!n)return t;let s=i.join("=");return t[n]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(n)?new Date(s*1e3):/^[0-9]+$/.test(s)?+s:s,t};Dy.exports=Ln});var $i=$(($2,by)=>{by.exports=t=>{let e=t.length-1,r=-1;for(;e>-1&&t.charAt(e)==="/";)r=e,e--;return r===-1?t:t.slice(0,r)}});var mo=$((H2,_y)=>{"use strict";_y.exports=t=>class extends t{warn(e,r,i={}){this.file&&(i.file=this.file),this.cwd&&(i.cwd=this.cwd),i.code=r instanceof Error&&r.code||e,i.tarCode=e,!this.strict&&i.recoverable!==!1?(r instanceof Error&&(i=Object.assign(r,i),r=r.message),this.emit("warn",i.tarCode,r,i)):r instanceof Error?this.emit("error",Object.assign(r,i)):this.emit("error",Object.assign(new Error(`${e}: ${r}`),i))}}});var Rc=$((U2,wy)=>{"use strict";var go=["|","<",">","?",":"],xc=go.map(t=>String.fromCharCode(61440+t.charCodeAt(0))),AF=new Map(go.map((t,e)=>[t,xc[e]])),vF=new Map(xc.map((t,e)=>[t,go[e]]));wy.exports={encode:t=>go.reduce((e,r)=>e.split(r).join(AF.get(r)),t),decode:t=>xc.reduce((e,r)=>e.split(r).join(vF.get(r)),t)}});var Fc=$((G2,Ay)=>{var{isAbsolute:CF,parse:Sy}=require("path").win32;Ay.exports=t=>{let e="",r=Sy(t);for(;CF(t)||r.root;){let i=t.charAt(0)==="/"&&t.slice(0,4)!=="//?/"?"/":r.root;t=t.slice(i.length),e+=i,r=Sy(t)}return[e,t]}});var Cy=$((z2,vy)=>{"use strict";vy.exports=(t,e,r)=>(t&=4095,r&&(t=(t|384)&-19),e&&(t&256&&(t|=64),t&32&&(t|=8),t&4&&(t|=1)),t)});var jc=$((V2,$y)=>{"use strict";var Ly=ro(),By=po(),Py=ji(),xt=require("fs"),xy=require("path"),Ct=Ni(),xF=$i(),Iy=(t,e)=>e?(t=Ct(t).replace(/^\.(\/|$)/,""),xF(e)+"/"+t):Ct(t),RF=16*1024*1024,Ry=Symbol("process"),Fy=Symbol("file"),Oy=Symbol("directory"),kc=Symbol("symlink"),ky=Symbol("hardlink"),Bn=Symbol("header"),yo=Symbol("read"),Tc=Symbol("lstat"),Eo=Symbol("onlstat"),Lc=Symbol("onread"),Bc=Symbol("onreadlink"),Pc=Symbol("openfile"),Ic=Symbol("onopenfile"),Dr=Symbol("close"),Do=Symbol("mode"),Nc=Symbol("awaitDrain"),Oc=Symbol("ondrain"),Rt=Symbol("prefix"),Ty=Symbol("hadError"),Ny=mo(),FF=Rc(),My=Fc(),jy=Cy(),bo=Ny(class extends Ly{constructor(e,r){if(r=r||{},super(r),typeof e!="string")throw new TypeError("path is required");this.path=Ct(e),this.portable=!!r.portable,this.myuid=process.getuid&&process.getuid()||0,this.myuser=process.env.USER||"",this.maxReadSize=r.maxReadSize||RF,this.linkCache=r.linkCache||new Map,this.statCache=r.statCache||new Map,this.preservePaths=!!r.preservePaths,this.cwd=Ct(r.cwd||process.cwd()),this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.mtime=r.mtime||null,this.prefix=r.prefix?Ct(r.prefix):null,this.fd=null,this.blockLen=null,this.blockRemain=null,this.buf=null,this.offset=null,this.length=null,this.pos=null,this.remain=null,typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(!this.preservePaths){let[n,s]=My(this.path);n&&(this.path=s,i=n)}this.win32=!!r.win32||process.platform==="win32",this.win32&&(this.path=FF.decode(this.path.replace(/\\/g,"/")),e=e.replace(/\\/g,"/")),this.absolute=Ct(r.absolute||xy.resolve(this.cwd,e)),this.path===""&&(this.path="./"),i&&this.warn("TAR_ENTRY_INFO",`stripping ${i} from absolute path`,{entry:this,path:i+this.path}),this.statCache.has(this.absolute)?this[Eo](this.statCache.get(this.absolute)):this[Tc]()}emit(e,...r){return e==="error"&&(this[Ty]=!0),super.emit(e,...r)}[Tc](){xt.lstat(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[Eo](r)})}[Eo](e){this.statCache.set(this.absolute,e),this.stat=e,e.isFile()||(e.size=0),this.type=kF(e),this.emit("stat",e),this[Ry]()}[Ry](){switch(this.type){case"File":return this[Fy]();case"Directory":return this[Oy]();case"SymbolicLink":return this[kc]();default:return this.end()}}[Do](e){return jy(e,this.type==="Directory",this.portable)}[Rt](e){return Iy(e,this.prefix)}[Bn](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new Py({path:this[Rt](this.path),linkpath:this.type==="Link"?this[Rt](this.linkpath):this.linkpath,mode:this[Do](this.stat.mode),uid:this.portable?null:this.stat.uid,gid:this.portable?null:this.stat.gid,size:this.stat.size,mtime:this.noMtime?null:this.mtime||this.stat.mtime,type:this.type,uname:this.portable?null:this.stat.uid===this.myuid?this.myuser:"",atime:this.portable?null:this.stat.atime,ctime:this.portable?null:this.stat.ctime}),this.header.encode()&&!this.noPax&&super.write(new By({atime:this.portable?null:this.header.atime,ctime:this.portable?null:this.header.ctime,gid:this.portable?null:this.header.gid,mtime:this.noMtime?null:this.mtime||this.header.mtime,path:this[Rt](this.path),linkpath:this.type==="Link"?this[Rt](this.linkpath):this.linkpath,size:this.header.size,uid:this.portable?null:this.header.uid,uname:this.portable?null:this.header.uname,dev:this.portable?null:this.stat.dev,ino:this.portable?null:this.stat.ino,nlink:this.portable?null:this.stat.nlink}).encode()),super.write(this.header.block)}[Oy](){this.path.slice(-1)!=="/"&&(this.path+="/"),this.stat.size=0,this[Bn](),this.end()}[kc](){xt.readlink(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[Bc](r)})}[Bc](e){this.linkpath=Ct(e),this[Bn](),this.end()}[ky](e){this.type="Link",this.linkpath=Ct(xy.relative(this.cwd,e)),this.stat.size=0,this[Bn](),this.end()}[Fy](){if(this.stat.nlink>1){let e=this.stat.dev+":"+this.stat.ino;if(this.linkCache.has(e)){let r=this.linkCache.get(e);if(r.indexOf(this.cwd)===0)return this[ky](r)}this.linkCache.set(e,this.absolute)}if(this[Bn](),this.stat.size===0)return this.end();this[Pc]()}[Pc](){xt.open(this.absolute,"r",(e,r)=>{if(e)return this.emit("error",e);this[Ic](r)})}[Ic](e){if(this.fd=e,this[Ty])return this[Dr]();this.blockLen=512*Math.ceil(this.stat.size/512),this.blockRemain=this.blockLen;let r=Math.min(this.blockLen,this.maxReadSize);this.buf=Buffer.allocUnsafe(r),this.offset=0,this.pos=0,this.remain=this.stat.size,this.length=this.buf.length,this[yo]()}[yo](){let{fd:e,buf:r,offset:i,length:n,pos:s}=this;xt.read(e,r,i,n,s,(o,a)=>{if(o)return this[Dr](()=>this.emit("error",o));this[Lc](a)})}[Dr](e){xt.close(this.fd,e)}[Lc](e){if(e<=0&&this.remain>0){let n=new Error("encountered unexpected EOF");return n.path=this.absolute,n.syscall="read",n.code="EOF",this[Dr](()=>this.emit("error",n))}if(e>this.remain){let n=new Error("did not encounter expected EOF");return n.path=this.absolute,n.syscall="read",n.code="EOF",this[Dr](()=>this.emit("error",n))}if(e===this.remain)for(let n=e;n<this.length&&e<this.blockRemain;n++)this.buf[n+this.offset]=0,e++,this.remain++;let r=this.offset===0&&e===this.buf.length?this.buf:this.buf.slice(this.offset,this.offset+e);this.write(r)?this[Oc]():this[Nc](()=>this[Oc]())}[Nc](e){this.once("drain",e)}write(e){if(this.blockRemain<e.length){let r=new Error("writing more data than expected");return r.path=this.absolute,this.emit("error",r)}return this.remain-=e.length,this.blockRemain-=e.length,this.pos+=e.length,this.offset+=e.length,super.write(e)}[Oc](){if(!this.remain)return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),this[Dr](e=>e?this.emit("error",e):this.end());this.offset>=this.length&&(this.buf=Buffer.allocUnsafe(Math.min(this.blockRemain,this.buf.length)),this.offset=0),this.length=this.buf.length-this.offset,this[yo]()}}),Mc=class extends bo{[Tc](){this[Eo](xt.lstatSync(this.absolute))}[kc](){this[Bc](xt.readlinkSync(this.absolute))}[Pc](){this[Ic](xt.openSync(this.absolute,"r"))}[yo](){let e=!0;try{let{fd:r,buf:i,offset:n,length:s,pos:o}=this,a=xt.readSync(r,i,n,s,o);this[Lc](a),e=!1}finally{if(e)try{this[Dr](()=>{})}catch{}}}[Nc](e){e()}[Dr](e){xt.closeSync(this.fd),e()}},OF=Ny(class extends Ly{constructor(e,r){r=r||{},super(r),this.preservePaths=!!r.preservePaths,this.portable=!!r.portable,this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.readEntry=e,this.type=e.type,this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.prefix=r.prefix||null,this.path=Ct(e.path),this.mode=this[Do](e.mode),this.uid=this.portable?null:e.uid,this.gid=this.portable?null:e.gid,this.uname=this.portable?null:e.uname,this.gname=this.portable?null:e.gname,this.size=e.size,this.mtime=this.noMtime?null:r.mtime||e.mtime,this.atime=this.portable?null:e.atime,this.ctime=this.portable?null:e.ctime,this.linkpath=Ct(e.linkpath),typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(!this.preservePaths){let[n,s]=My(this.path);n&&(this.path=s,i=n)}this.remain=e.size,this.blockRemain=e.startBlockSize,this.header=new Py({path:this[Rt](this.path),linkpath:this.type==="Link"?this[Rt](this.linkpath):this.linkpath,mode:this.mode,uid:this.portable?null:this.uid,gid:this.portable?null:this.gid,size:this.size,mtime:this.noMtime?null:this.mtime,type:this.type,uname:this.portable?null:this.uname,atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime}),i&&this.warn("TAR_ENTRY_INFO",`stripping ${i} from absolute path`,{entry:this,path:i+this.path}),this.header.encode()&&!this.noPax&&super.write(new By({atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime,gid:this.portable?null:this.gid,mtime:this.noMtime?null:this.mtime,path:this[Rt](this.path),linkpath:this.type==="Link"?this[Rt](this.linkpath):this.linkpath,size:this.size,uid:this.portable?null:this.uid,uname:this.portable?null:this.uname,dev:this.portable?null:this.readEntry.dev,ino:this.portable?null:this.readEntry.ino,nlink:this.portable?null:this.readEntry.nlink}).encode()),super.write(this.header.block),e.pipe(this)}[Rt](e){return Iy(e,this.prefix)}[Do](e){return jy(e,this.type==="Directory",this.portable)}write(e){let r=e.length;if(r>this.blockRemain)throw new Error("writing more to entry than is appropriate");return this.blockRemain-=r,super.write(e)}end(){return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),super.end()}});bo.Sync=Mc;bo.Tar=OF;var kF=t=>t.isFile()?"File":t.isDirectory()?"Directory":t.isSymbolicLink()?"SymbolicLink":"Unsupported";$y.exports=bo});var qy=$((K2,Hy)=>{"use strict";Hy.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var $c=$((Z2,Uy)=>{"use strict";Uy.exports=ae;ae.Node=Yr;ae.create=ae;function ae(t){var e=this;if(e instanceof ae||(e=new ae),e.tail=null,e.head=null,e.length=0,t&&typeof t.forEach=="function")t.forEach(function(n){e.push(n)});else if(arguments.length>0)for(var r=0,i=arguments.length;r<i;r++)e.push(arguments[r]);return e}ae.prototype.removeNode=function(t){if(t.list!==this)throw new Error("removing node which does not belong to this list");var e=t.next,r=t.prev;return e&&(e.prev=r),r&&(r.next=e),t===this.head&&(this.head=e),t===this.tail&&(this.tail=r),t.list.length--,t.next=null,t.prev=null,t.list=null,e};ae.prototype.unshiftNode=function(t){if(t!==this.head){t.list&&t.list.removeNode(t);var e=this.head;t.list=this,t.next=e,e&&(e.prev=t),this.head=t,this.tail||(this.tail=t),this.length++}};ae.prototype.pushNode=function(t){if(t!==this.tail){t.list&&t.list.removeNode(t);var e=this.tail;t.list=this,t.prev=e,e&&(e.next=t),this.tail=t,this.head||(this.head=t),this.length++}};ae.prototype.push=function(){for(var t=0,e=arguments.length;t<e;t++)LF(this,arguments[t]);return this.length};ae.prototype.unshift=function(){for(var t=0,e=arguments.length;t<e;t++)BF(this,arguments[t]);return this.length};ae.prototype.pop=function(){if(this.tail){var t=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,t}};ae.prototype.shift=function(){if(this.head){var t=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,t}};ae.prototype.forEach=function(t,e){e=e||this;for(var r=this.head,i=0;r!==null;i++)t.call(e,r.value,i,this),r=r.next};ae.prototype.forEachReverse=function(t,e){e=e||this;for(var r=this.tail,i=this.length-1;r!==null;i--)t.call(e,r.value,i,this),r=r.prev};ae.prototype.get=function(t){for(var e=0,r=this.head;r!==null&&e<t;e++)r=r.next;if(e===t&&r!==null)return r.value};ae.prototype.getReverse=function(t){for(var e=0,r=this.tail;r!==null&&e<t;e++)r=r.prev;if(e===t&&r!==null)return r.value};ae.prototype.map=function(t,e){e=e||this;for(var r=new ae,i=this.head;i!==null;)r.push(t.call(e,i.value,this)),i=i.next;return r};ae.prototype.mapReverse=function(t,e){e=e||this;for(var r=new ae,i=this.tail;i!==null;)r.push(t.call(e,i.value,this)),i=i.prev;return r};ae.prototype.reduce=function(t,e){var r,i=this.head;if(arguments.length>1)r=e;else if(this.head)i=this.head.next,r=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=0;i!==null;n++)r=t(r,i.value,n),i=i.next;return r};ae.prototype.reduceReverse=function(t,e){var r,i=this.tail;if(arguments.length>1)r=e;else if(this.tail)i=this.tail.prev,r=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=this.length-1;i!==null;n--)r=t(r,i.value,n),i=i.prev;return r};ae.prototype.toArray=function(){for(var t=new Array(this.length),e=0,r=this.head;r!==null;e++)t[e]=r.value,r=r.next;return t};ae.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,r=this.tail;r!==null;e++)t[e]=r.value,r=r.prev;return t};ae.prototype.slice=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new ae;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=0,n=this.head;n!==null&&i<t;i++)n=n.next;for(;n!==null&&i<e;i++,n=n.next)r.push(n.value);return r};ae.prototype.sliceReverse=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new ae;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=this.length,n=this.tail;n!==null&&i>e;i--)n=n.prev;for(;n!==null&&i>t;i--,n=n.prev)r.push(n.value);return r};ae.prototype.splice=function(t,e,...r){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var i=0,n=this.head;n!==null&&i<t;i++)n=n.next;for(var s=[],i=0;n&&i<e;i++)s.push(n.value),n=this.removeNode(n);n===null&&(n=this.tail),n!==this.head&&n!==this.tail&&(n=n.prev);for(var i=0;i<r.length;i++)n=TF(this,n,r[i]);return s};ae.prototype.reverse=function(){for(var t=this.head,e=this.tail,r=t;r!==null;r=r.prev){var i=r.prev;r.prev=r.next,r.next=i}return this.head=e,this.tail=t,this};function TF(t,e,r){var i=e===t.head?new Yr(r,null,e,t):new Yr(r,e,e.next,t);return i.next===null&&(t.tail=i),i.prev===null&&(t.head=i),t.length++,i}function LF(t,e){t.tail=new Yr(e,t.tail,null,t),t.head||(t.head=t.tail),t.length++}function BF(t,e){t.head=new Yr(e,null,t.head,t),t.tail||(t.tail=t.head),t.length++}function Yr(t,e,r,i){if(!(this instanceof Yr))return new Yr(t,e,r,i);this.list=i,this.value=t,e?(e.next=this,this.prev=e):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}try{qy()(ae)}catch{}});var Fo=$((X2,Zy)=>{"use strict";var xo=class{constructor(e,r){this.path=e||"./",this.absolute=r,this.entry=null,this.stat=null,this.readdir=null,this.pending=!1,this.ignore=!1,this.piped=!1}},PF=ro(),IF=Ec(),NF=ho(),Kc=jc(),MF=Kc.Sync,jF=Kc.Tar,$F=$c(),Gy=Buffer.alloc(1024),So=Symbol("onStat"),_o=Symbol("ended"),Ft=Symbol("queue"),Hi=Symbol("current"),Vr=Symbol("process"),wo=Symbol("processing"),zy=Symbol("processJob"),Ot=Symbol("jobs"),Hc=Symbol("jobDone"),Ao=Symbol("addFSEntry"),Wy=Symbol("addTarEntry"),zc=Symbol("stat"),Wc=Symbol("readdir"),vo=Symbol("onreaddir"),Co=Symbol("pipe"),Yy=Symbol("entry"),qc=Symbol("entryOpt"),Yc=Symbol("writeEntryClass"),Ky=Symbol("write"),Uc=Symbol("ondrain"),Ro=require("fs"),Vy=require("path"),HF=mo(),Gc=Ni(),Zc=HF(class extends PF{constructor(e){super(e),e=e||Object.create(null),this.opt=e,this.file=e.file||"",this.cwd=e.cwd||process.cwd(),this.maxReadSize=e.maxReadSize,this.preservePaths=!!e.preservePaths,this.strict=!!e.strict,this.noPax=!!e.noPax,this.prefix=Gc(e.prefix||""),this.linkCache=e.linkCache||new Map,this.statCache=e.statCache||new Map,this.readdirCache=e.readdirCache||new Map,this[Yc]=Kc,typeof e.onwarn=="function"&&this.on("warn",e.onwarn),this.portable=!!e.portable,this.zip=null,e.gzip?(typeof e.gzip!="object"&&(e.gzip={}),this.portable&&(e.gzip.portable=!0),this.zip=new IF.Gzip(e.gzip),this.zip.on("data",r=>super.write(r)),this.zip.on("end",r=>super.end()),this.zip.on("drain",r=>this[Uc]()),this.on("resume",r=>this.zip.resume())):this.on("drain",this[Uc]),this.noDirRecurse=!!e.noDirRecurse,this.follow=!!e.follow,this.noMtime=!!e.noMtime,this.mtime=e.mtime||null,this.filter=typeof e.filter=="function"?e.filter:r=>!0,this[Ft]=new $F,this[Ot]=0,this.jobs=+e.jobs||4,this[wo]=!1,this[_o]=!1}[Ky](e){return super.write(e)}add(e){return this.write(e),this}end(e){return e&&this.write(e),this[_o]=!0,this[Vr](),this}write(e){if(this[_o])throw new Error("write after end");return e instanceof NF?this[Wy](e):this[Ao](e),this.flowing}[Wy](e){let r=Gc(Vy.resolve(this.cwd,e.path));if(!this.filter(e.path,e))e.resume();else{let i=new xo(e.path,r,!1);i.entry=new jF(e,this[qc](i)),i.entry.on("end",n=>this[Hc](i)),this[Ot]+=1,this[Ft].push(i)}this[Vr]()}[Ao](e){let r=Gc(Vy.resolve(this.cwd,e));this[Ft].push(new xo(e,r)),this[Vr]()}[zc](e){e.pending=!0,this[Ot]+=1;let r=this.follow?"stat":"lstat";Ro[r](e.absolute,(i,n)=>{e.pending=!1,this[Ot]-=1,i?this.emit("error",i):this[So](e,n)})}[So](e,r){this.statCache.set(e.absolute,r),e.stat=r,this.filter(e.path,r)||(e.ignore=!0),this[Vr]()}[Wc](e){e.pending=!0,this[Ot]+=1,Ro.readdir(e.absolute,(r,i)=>{if(e.pending=!1,this[Ot]-=1,r)return this.emit("error",r);this[vo](e,i)})}[vo](e,r){this.readdirCache.set(e.absolute,r),e.readdir=r,this[Vr]()}[Vr](){if(!this[wo]){this[wo]=!0;for(let e=this[Ft].head;e!==null&&this[Ot]<this.jobs;e=e.next)if(this[zy](e.value),e.value.ignore){let r=e.next;this[Ft].removeNode(e),e.next=r}this[wo]=!1,this[_o]&&!this[Ft].length&&this[Ot]===0&&(this.zip?this.zip.end(Gy):(super.write(Gy),super.end()))}}get[Hi](){return this[Ft]&&this[Ft].head&&this[Ft].head.value}[Hc](e){this[Ft].shift(),this[Ot]-=1,this[Vr]()}[zy](e){if(!e.pending){if(e.entry){e===this[Hi]&&!e.piped&&this[Co](e);return}if(e.stat||(this.statCache.has(e.absolute)?this[So](e,this.statCache.get(e.absolute)):this[zc](e)),!!e.stat&&!e.ignore&&!(!this.noDirRecurse&&e.stat.isDirectory()&&!e.readdir&&(this.readdirCache.has(e.absolute)?this[vo](e,this.readdirCache.get(e.absolute)):this[Wc](e),!e.readdir))){if(e.entry=this[Yy](e),!e.entry){e.ignore=!0;return}e===this[Hi]&&!e.piped&&this[Co](e)}}}[qc](e){return{onwarn:(r,i,n)=>this.warn(r,i,n),noPax:this.noPax,cwd:this.cwd,absolute:e.absolute,preservePaths:this.preservePaths,maxReadSize:this.maxReadSize,strict:this.strict,portable:this.portable,linkCache:this.linkCache,statCache:this.statCache,noMtime:this.noMtime,mtime:this.mtime,prefix:this.prefix}}[Yy](e){this[Ot]+=1;try{return new this[Yc](e.path,this[qc](e)).on("end",()=>this[Hc](e)).on("error",r=>this.emit("error",r))}catch(r){this.emit("error",r)}}[Uc](){this[Hi]&&this[Hi].entry&&this[Hi].entry.resume()}[Co](e){e.piped=!0,e.readdir&&e.readdir.forEach(n=>{let s=e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[Ao](o+n)});let r=e.entry,i=this.zip;i?r.on("data",n=>{i.write(n)||r.pause()}):r.on("data",n=>{super.write(n)||r.pause()})}pause(){return this.zip&&this.zip.pause(),super.pause()}}),Vc=class extends Zc{constructor(e){super(e),this[Yc]=MF}pause(){}resume(){}[zc](e){let r=this.follow?"statSync":"lstatSync";this[So](e,Ro[r](e.absolute))}[Wc](e,r){this[vo](e,Ro.readdirSync(e.absolute))}[Co](e){let r=e.entry,i=this.zip;e.readdir&&e.readdir.forEach(n=>{let s=e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[Ao](o+n)}),i?r.on("data",n=>{i.write(n)}):r.on("data",n=>{super[Ky](n)})}};Zc.Sync=Vc;Zy.exports=Zc});var Ki=$(In=>{"use strict";var qF=rc(),UF=require("events").EventEmitter,Ye=require("fs"),Qc=Ye.writev;if(!Qc){let t=process.binding("fs"),e=t.FSReqWrap||t.FSReqCallback;Qc=(r,i,n,s)=>{let o=(u,l)=>s(u,l,i),a=new e;a.oncomplete=o,t.writeBuffers(r,i,n,a)}}var Yi=Symbol("_autoClose"),pt=Symbol("_close"),Pn=Symbol("_ended"),fe=Symbol("_fd"),Jy=Symbol("_finished"),_r=Symbol("_flags"),Jc=Symbol("_flush"),eh=Symbol("_handleChunk"),th=Symbol("_makeBuf"),Bo=Symbol("_mode"),Oo=Symbol("_needDrain"),zi=Symbol("_onerror"),Vi=Symbol("_onopen"),Xc=Symbol("_onread"),Ui=Symbol("_onwrite"),wr=Symbol("_open"),Jt=Symbol("_path"),Kr=Symbol("_pos"),kt=Symbol("_queue"),Gi=Symbol("_read"),Xy=Symbol("_readSize"),br=Symbol("_reading"),ko=Symbol("_remain"),Qy=Symbol("_size"),To=Symbol("_write"),qi=Symbol("_writing"),Lo=Symbol("_defaultFlag"),Wi=Symbol("_errored"),Po=class extends qF{constructor(e,r){if(r=r||{},super(r),this.readable=!0,this.writable=!1,typeof e!="string")throw new TypeError("path must be a string");this[Wi]=!1,this[fe]=typeof r.fd=="number"?r.fd:null,this[Jt]=e,this[Xy]=r.readSize||16*1024*1024,this[br]=!1,this[Qy]=typeof r.size=="number"?r.size:1/0,this[ko]=this[Qy],this[Yi]=typeof r.autoClose=="boolean"?r.autoClose:!0,typeof this[fe]=="number"?this[Gi]():this[wr]()}get fd(){return this[fe]}get path(){return this[Jt]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[wr](){Ye.open(this[Jt],"r",(e,r)=>this[Vi](e,r))}[Vi](e,r){e?this[zi](e):(this[fe]=r,this.emit("open",r),this[Gi]())}[th](){return Buffer.allocUnsafe(Math.min(this[Xy],this[ko]))}[Gi](){if(!this[br]){this[br]=!0;let e=this[th]();if(e.length===0)return process.nextTick(()=>this[Xc](null,0,e));Ye.read(this[fe],e,0,e.length,null,(r,i,n)=>this[Xc](r,i,n))}}[Xc](e,r,i){this[br]=!1,e?this[zi](e):this[eh](r,i)&&this[Gi]()}[pt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ye.close(e,r=>r?this.emit("error",r):this.emit("close"))}}[zi](e){this[br]=!0,this[pt](),this.emit("error",e)}[eh](e,r){let i=!1;return this[ko]-=e,e>0&&(i=super.write(e<r.length?r.slice(0,e):r)),(e===0||this[ko]<=0)&&(i=!1,this[pt](),super.end()),i}emit(e,r){switch(e){case"prefinish":case"finish":break;case"drain":typeof this[fe]=="number"&&this[Gi]();break;case"error":return this[Wi]?void 0:(this[Wi]=!0,super.emit(e,r));default:return super.emit(e,r)}}},rh=class extends Po{[wr](){let e=!0;try{this[Vi](null,Ye.openSync(this[Jt],"r")),e=!1}finally{e&&this[pt]()}}[Gi](){let e=!0;try{if(!this[br]){this[br]=!0;do{let r=this[th](),i=r.length===0?0:Ye.readSync(this[fe],r,0,r.length,null);if(!this[eh](i,r))break}while(!0);this[br]=!1}e=!1}finally{e&&this[pt]()}}[pt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ye.closeSync(e),this.emit("close")}}},Io=class extends UF{constructor(e,r){r=r||{},super(r),this.readable=!1,this.writable=!0,this[Wi]=!1,this[qi]=!1,this[Pn]=!1,this[Oo]=!1,this[kt]=[],this[Jt]=e,this[fe]=typeof r.fd=="number"?r.fd:null,this[Bo]=r.mode===void 0?438:r.mode,this[Kr]=typeof r.start=="number"?r.start:null,this[Yi]=typeof r.autoClose=="boolean"?r.autoClose:!0;let i=this[Kr]!==null?"r+":"w";this[Lo]=r.flags===void 0,this[_r]=this[Lo]?i:r.flags,this[fe]===null&&this[wr]()}emit(e,r){if(e==="error"){if(this[Wi])return;this[Wi]=!0}return super.emit(e,r)}get fd(){return this[fe]}get path(){return this[Jt]}[zi](e){this[pt](),this[qi]=!0,this.emit("error",e)}[wr](){Ye.open(this[Jt],this[_r],this[Bo],(e,r)=>this[Vi](e,r))}[Vi](e,r){this[Lo]&&this[_r]==="r+"&&e&&e.code==="ENOENT"?(this[_r]="w",this[wr]()):e?this[zi](e):(this[fe]=r,this.emit("open",r),this[Jc]())}end(e,r){return e&&this.write(e,r),this[Pn]=!0,!this[qi]&&!this[kt].length&&typeof this[fe]=="number"&&this[Ui](null,0),this}write(e,r){return typeof e=="string"&&(e=Buffer.from(e,r)),this[Pn]?(this.emit("error",new Error("write() after end()")),!1):this[fe]===null||this[qi]||this[kt].length?(this[kt].push(e),this[Oo]=!0,!1):(this[qi]=!0,this[To](e),!0)}[To](e){Ye.write(this[fe],e,0,e.length,this[Kr],(r,i)=>this[Ui](r,i))}[Ui](e,r){e?this[zi](e):(this[Kr]!==null&&(this[Kr]+=r),this[kt].length?this[Jc]():(this[qi]=!1,this[Pn]&&!this[Jy]?(this[Jy]=!0,this[pt](),this.emit("finish")):this[Oo]&&(this[Oo]=!1,this.emit("drain"))))}[Jc](){if(this[kt].length===0)this[Pn]&&this[Ui](null,0);else if(this[kt].length===1)this[To](this[kt].pop());else{let e=this[kt];this[kt]=[],Qc(this[fe],e,this[Kr],(r,i)=>this[Ui](r,i))}}[pt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ye.close(e,r=>r?this.emit("error",r):this.emit("close"))}}},ih=class extends Io{[wr](){let e;if(this[Lo]&&this[_r]==="r+")try{e=Ye.openSync(this[Jt],this[_r],this[Bo])}catch(r){if(r.code==="ENOENT")return this[_r]="w",this[wr]();throw r}else e=Ye.openSync(this[Jt],this[_r],this[Bo]);this[Vi](null,e)}[pt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ye.closeSync(e),this.emit("close")}}[To](e){let r=!0;try{this[Ui](null,Ye.writeSync(this[fe],e,0,e.length,this[Kr])),r=!1}finally{if(r)try{this[pt]()}catch{}}}};In.ReadStream=Po;In.ReadStreamSync=rh;In.WriteStream=Io;In.WriteStreamSync=ih});var Uo=$((tI,aE)=>{"use strict";var GF=mo(),zF=ji(),WF=require("events"),YF=$c(),VF=1024*1024,KF=ho(),eE=po(),ZF=Ec(),{nextTick:JF}=require("process"),nh=Buffer.from([31,139]),st=Symbol("state"),Zr=Symbol("writeEntry"),Xt=Symbol("readEntry"),sh=Symbol("nextEntry"),tE=Symbol("processEntry"),ot=Symbol("extendedHeader"),Nn=Symbol("globalExtendedHeader"),Sr=Symbol("meta"),rE=Symbol("emitMeta"),me=Symbol("buffer"),Qt=Symbol("queue"),Jr=Symbol("ended"),iE=Symbol("emittedEnd"),Xr=Symbol("emit"),Ve=Symbol("unzip"),No=Symbol("consumeChunk"),Mo=Symbol("consumeChunkSub"),oh=Symbol("consumeBody"),nE=Symbol("consumeMeta"),sE=Symbol("consumeHeader"),jo=Symbol("consuming"),ah=Symbol("bufferConcat"),uh=Symbol("maybeEnd"),Mn=Symbol("writing"),Ar=Symbol("aborted"),$o=Symbol("onDone"),Qr=Symbol("sawValidEntry"),Ho=Symbol("sawNullBlock"),qo=Symbol("sawEOF"),oE=Symbol("closeStream"),XF=t=>!0;aE.exports=GF(class extends WF{constructor(e){e=e||{},super(e),this.file=e.file||"",this[Qr]=null,this.on($o,r=>{(this[st]==="begin"||this[Qr]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),e.ondone?this.on($o,e.ondone):this.on($o,r=>{this.emit("prefinish"),this.emit("finish"),this.emit("end")}),this.strict=!!e.strict,this.maxMetaEntrySize=e.maxMetaEntrySize||VF,this.filter=typeof e.filter=="function"?e.filter:XF,this.writable=!0,this.readable=!1,this[Qt]=new YF,this[me]=null,this[Xt]=null,this[Zr]=null,this[st]="begin",this[Sr]="",this[ot]=null,this[Nn]=null,this[Jr]=!1,this[Ve]=null,this[Ar]=!1,this[Ho]=!1,this[qo]=!1,this.on("end",()=>this[oE]()),typeof e.onwarn=="function"&&this.on("warn",e.onwarn),typeof e.onentry=="function"&&this.on("entry",e.onentry)}[sE](e,r){this[Qr]===null&&(this[Qr]=!1);let i;try{i=new zF(e,r,this[ot],this[Nn])}catch(n){return this.warn("TAR_ENTRY_INVALID",n)}if(i.nullBlock)this[Ho]?(this[qo]=!0,this[st]==="begin"&&(this[st]="header"),this[Xr]("eof")):(this[Ho]=!0,this[Xr]("nullBlock"));else if(this[Ho]=!1,!i.cksumValid)this.warn("TAR_ENTRY_INVALID","checksum failure",{header:i});else if(!i.path)this.warn("TAR_ENTRY_INVALID","path is required",{header:i});else{let n=i.type;if(/^(Symbolic)?Link$/.test(n)&&!i.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath required",{header:i});else if(!/^(Symbolic)?Link$/.test(n)&&i.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath forbidden",{header:i});else{let s=this[Zr]=new KF(i,this[ot],this[Nn]);if(!this[Qr])if(s.remain){let o=()=>{s.invalid||(this[Qr]=!0)};s.on("end",o)}else this[Qr]=!0;s.meta?s.size>this.maxMetaEntrySize?(s.ignore=!0,this[Xr]("ignoredEntry",s),this[st]="ignore",s.resume()):s.size>0&&(this[Sr]="",s.on("data",o=>this[Sr]+=o),this[st]="meta"):(this[ot]=null,s.ignore=s.ignore||!this.filter(s.path,s),s.ignore?(this[Xr]("ignoredEntry",s),this[st]=s.remain?"ignore":"header",s.resume()):(s.remain?this[st]="body":(this[st]="header",s.end()),this[Xt]?this[Qt].push(s):(this[Qt].push(s),this[sh]())))}}}[oE](){JF(()=>this.emit("close"))}[tE](e){let r=!0;return e?Array.isArray(e)?this.emit.apply(this,e):(this[Xt]=e,this.emit("entry",e),e.emittedEnd||(e.on("end",i=>this[sh]()),r=!1)):(this[Xt]=null,r=!1),r}[sh](){do;while(this[tE](this[Qt].shift()));if(!this[Qt].length){let e=this[Xt];!e||e.flowing||e.size===e.remain?this[Mn]||this.emit("drain"):e.once("drain",i=>this.emit("drain"))}}[oh](e,r){let i=this[Zr],n=i.blockRemain,s=n>=e.length&&r===0?e:e.slice(r,r+n);return i.write(s),i.blockRemain||(this[st]="header",this[Zr]=null,i.end()),s.length}[nE](e,r){let i=this[Zr],n=this[oh](e,r);return this[Zr]||this[rE](i),n}[Xr](e,r,i){!this[Qt].length&&!this[Xt]?this.emit(e,r,i):this[Qt].push([e,r,i])}[rE](e){switch(this[Xr]("meta",this[Sr]),e.type){case"ExtendedHeader":case"OldExtendedHeader":this[ot]=eE.parse(this[Sr],this[ot],!1);break;case"GlobalExtendedHeader":this[Nn]=eE.parse(this[Sr],this[Nn],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[ot]=this[ot]||Object.create(null),this[ot].path=this[Sr].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[ot]=this[ot]||Object.create(null),this[ot].linkpath=this[Sr].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+e.type)}}abort(e){this[Ar]=!0,this.emit("abort",e),this.warn("TAR_ABORT",e,{recoverable:!1})}write(e){if(this[Ar])return;if(this[Ve]===null&&e){if(this[me]&&(e=Buffer.concat([this[me],e]),this[me]=null),e.length<nh.length)return this[me]=e,!0;for(let i=0;this[Ve]===null&&i<nh.length;i++)e[i]!==nh[i]&&(this[Ve]=!1);if(this[Ve]===null){let i=this[Jr];this[Jr]=!1,this[Ve]=new ZF.Unzip,this[Ve].on("data",s=>this[No](s)),this[Ve].on("error",s=>this.abort(s)),this[Ve].on("end",s=>{this[Jr]=!0,this[No]()}),this[Mn]=!0;let n=this[Ve][i?"end":"write"](e);return this[Mn]=!1,n}}this[Mn]=!0,this[Ve]?this[Ve].write(e):this[No](e),this[Mn]=!1;let r=this[Qt].length?!1:this[Xt]?this[Xt].flowing:!0;return!r&&!this[Qt].length&&this[Xt].once("drain",i=>this.emit("drain")),r}[ah](e){e&&!this[Ar]&&(this[me]=this[me]?Buffer.concat([this[me],e]):e)}[uh](){if(this[Jr]&&!this[iE]&&!this[Ar]&&!this[jo]){this[iE]=!0;let e=this[Zr];if(e&&e.blockRemain){let r=this[me]?this[me].length:0;this.warn("TAR_BAD_ARCHIVE",`Truncated input (needed ${e.blockRemain} more bytes, only ${r} available)`,{entry:e}),this[me]&&e.write(this[me]),e.end()}this[Xr]($o)}}[No](e){if(this[jo])this[ah](e);else if(!e&&!this[me])this[uh]();else{if(this[jo]=!0,this[me]){this[ah](e);let r=this[me];this[me]=null,this[Mo](r)}else this[Mo](e);for(;this[me]&&this[me].length>=512&&!this[Ar]&&!this[qo];){let r=this[me];this[me]=null,this[Mo](r)}this[jo]=!1}(!this[me]||this[Jr])&&this[uh]()}[Mo](e){let r=0,i=e.length;for(;r+512<=i&&!this[Ar]&&!this[qo];)switch(this[st]){case"begin":case"header":this[sE](e,r),r+=512;break;case"ignore":case"body":r+=this[oh](e,r);break;case"meta":r+=this[nE](e,r);break;default:throw new Error("invalid state: "+this[st])}r<i&&(this[me]?this[me]=Buffer.concat([e.slice(r),this[me]]):this[me]=e.slice(r))}end(e){this[Ar]||(this[Ve]?this[Ve].end(e):(this[Jr]=!0,this.write(e)))}})});var Go=$((rI,hE)=>{"use strict";var QF=Ti(),lE=Uo(),Zi=require("fs"),eO=Ki(),uE=require("path"),lh=$i();hE.exports=(t,e,r)=>{typeof t=="function"?(r=t,e=null,t={}):Array.isArray(t)&&(e=t,t={}),typeof e=="function"&&(r=e,e=null),e?e=Array.from(e):e=[];let i=QF(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return e.length&&rO(i,e),i.noResume||tO(i),i.file&&i.sync?iO(i):i.file?nO(i,r):cE(i)};var tO=t=>{let e=t.onentry;t.onentry=e?r=>{e(r),r.resume()}:r=>r.resume()},rO=(t,e)=>{let r=new Map(e.map(s=>[lh(s),!0])),i=t.filter,n=(s,o)=>{let a=o||uE.parse(s).root||".",u=s===a?!1:r.has(s)?r.get(s):n(uE.dirname(s),a);return r.set(s,u),u};t.filter=i?(s,o)=>i(s,o)&&n(lh(s)):s=>n(lh(s))},iO=t=>{let e=cE(t),r=t.file,i=!0,n;try{let s=Zi.statSync(r),o=t.maxReadSize||16*1024*1024;if(s.size<o)e.end(Zi.readFileSync(r));else{let a=0,u=Buffer.allocUnsafe(o);for(n=Zi.openSync(r,"r");a<s.size;){let l=Zi.readSync(n,u,0,o,a);a+=l,e.write(u.slice(0,l))}e.end()}i=!1}finally{if(i&&n)try{Zi.closeSync(n)}catch{}}},nO=(t,e)=>{let r=new lE(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("end",o),Zi.stat(n,(u,l)=>{if(u)a(u);else{let c=new eO.ReadStream(n,{readSize:i,size:l.size});c.on("error",a),c.pipe(r)}})});return e?s.then(e,e):s},cE=t=>new lE(t)});var yE=$((iI,gE)=>{"use strict";var sO=Ti(),zo=Fo(),fE=Ki(),pE=Go(),dE=require("path");gE.exports=(t,e,r)=>{if(typeof e=="function"&&(r=e),Array.isArray(t)&&(e=t,t={}),!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");e=Array.from(e);let i=sO(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return i.file&&i.sync?oO(i,e):i.file?aO(i,e,r):i.sync?uO(i,e):lO(i,e)};var oO=(t,e)=>{let r=new zo.Sync(t),i=new fE.WriteStreamSync(t.file,{mode:t.mode||438});r.pipe(i),mE(r,e)},aO=(t,e,r)=>{let i=new zo(t),n=new fE.WriteStream(t.file,{mode:t.mode||438});i.pipe(n);let s=new Promise((o,a)=>{n.on("error",a),n.on("close",o),i.on("error",a)});return ch(i,e),r?s.then(r,r):s},mE=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?pE({file:dE.resolve(t.cwd,r.slice(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},ch=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return pE({file:dE.resolve(t.cwd,r.slice(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>ch(t,e));t.add(r)}t.end()},uO=(t,e)=>{let r=new zo.Sync(t);return mE(r,e),r},lO=(t,e)=>{let r=new zo(t);return ch(r,e),r}});var hh=$((nI,AE)=>{"use strict";var cO=Ti(),EE=Fo(),et=require("fs"),DE=Ki(),bE=Go(),_E=require("path"),wE=ji();AE.exports=(t,e,r)=>{let i=cO(t);if(!i.file)throw new TypeError("file is required");if(i.gzip)throw new TypeError("cannot append to compressed archives");if(!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");return e=Array.from(e),i.sync?hO(i,e):pO(i,e,r)};var hO=(t,e)=>{let r=new EE.Sync(t),i=!0,n,s;try{try{n=et.openSync(t.file,"r+")}catch(u){if(u.code==="ENOENT")n=et.openSync(t.file,"w+");else throw u}let o=et.fstatSync(n),a=Buffer.alloc(512);e:for(s=0;s<o.size;s+=512){for(let c=0,f=0;c<512;c+=f){if(f=et.readSync(n,a,c,a.length-c,s+c),s===0&&a[0]===31&&a[1]===139)throw new Error("cannot append to compressed archives");if(!f)break e}let u=new wE(a);if(!u.cksumValid)break;let l=512*Math.ceil(u.size/512);if(s+l+512>o.size)break;s+=l,t.mtimeCache&&t.mtimeCache.set(u.path,u.mtime)}i=!1,fO(t,r,s,n,e)}finally{if(i)try{et.closeSync(n)}catch{}}},fO=(t,e,r,i,n)=>{let s=new DE.WriteStreamSync(t.file,{fd:i,start:r});e.pipe(s),dO(e,n)},pO=(t,e,r)=>{e=Array.from(e);let i=new EE(t),n=(o,a,u)=>{let l=(g,y)=>{g?et.close(o,E=>u(g)):u(null,y)},c=0;if(a===0)return l(null,0);let f=0,h=Buffer.alloc(512),p=(g,y)=>{if(g)return l(g);if(f+=y,f<512&&y)return et.read(o,h,f,h.length-f,c+f,p);if(c===0&&h[0]===31&&h[1]===139)return l(new Error("cannot append to compressed archives"));if(f<512)return l(null,c);let E=new wE(h);if(!E.cksumValid)return l(null,c);let v=512*Math.ceil(E.size/512);if(c+v+512>a||(c+=v+512,c>=a))return l(null,c);t.mtimeCache&&t.mtimeCache.set(E.path,E.mtime),f=0,et.read(o,h,0,512,c,p)};et.read(o,h,0,512,c,p)},s=new Promise((o,a)=>{i.on("error",a);let u="r+",l=(c,f)=>{if(c&&c.code==="ENOENT"&&u==="r+")return u="w+",et.open(t.file,u,l);if(c)return a(c);et.fstat(f,(h,p)=>{if(h)return et.close(f,()=>a(h));n(f,p.size,(g,y)=>{if(g)return a(g);let E=new DE.WriteStream(t.file,{fd:f,start:y});i.pipe(E),E.on("error",a),E.on("close",o),SE(i,e)})})};et.open(t.file,u,l)});return r?s.then(r,r):s},dO=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?bE({file:_E.resolve(t.cwd,r.slice(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},SE=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return bE({file:_E.resolve(t.cwd,r.slice(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>SE(t,e));t.add(r)}t.end()}});var CE=$((sI,vE)=>{"use strict";var mO=Ti(),gO=hh();vE.exports=(t,e,r)=>{let i=mO(t);if(!i.file)throw new TypeError("file is required");if(i.gzip)throw new TypeError("cannot append to compressed archives");if(!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");return e=Array.from(e),yO(i),gO(i,e,r)};var yO=t=>{let e=t.filter;t.mtimeCache||(t.mtimeCache=new Map),t.filter=e?(r,i)=>e(r,i)&&!(t.mtimeCache.get(r)>i.mtime):(r,i)=>!(t.mtimeCache.get(r)>i.mtime)}});var FE=$((oI,RE)=>{var{promisify:xE}=require("util"),vr=require("fs"),EO=t=>{if(!t)t={mode:511,fs:vr};else if(typeof t=="object")t={mode:511,fs:vr,...t};else if(typeof t=="number")t={mode:t,fs:vr};else if(typeof t=="string")t={mode:parseInt(t,8),fs:vr};else throw new TypeError("invalid options argument");return t.mkdir=t.mkdir||t.fs.mkdir||vr.mkdir,t.mkdirAsync=xE(t.mkdir),t.stat=t.stat||t.fs.stat||vr.stat,t.statAsync=xE(t.stat),t.statSync=t.statSync||t.fs.statSync||vr.statSync,t.mkdirSync=t.mkdirSync||t.fs.mkdirSync||vr.mkdirSync,t};RE.exports=EO});var kE=$((aI,OE)=>{var DO=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:bO,parse:_O}=require("path"),wO=t=>{if(/\0/.test(t))throw Object.assign(new TypeError("path must be a string without null bytes"),{path:t,code:"ERR_INVALID_ARG_VALUE"});if(t=bO(t),DO==="win32"){let e=/[*|"<>?:]/,{root:r}=_O(t);if(e.test(t.substr(r.length)))throw Object.assign(new Error("Illegal characters in path."),{path:t,code:"EINVAL"})}return t};OE.exports=wO});var IE=$((uI,PE)=>{var{dirname:TE}=require("path"),LE=(t,e,r=void 0)=>r===e?Promise.resolve():t.statAsync(e).then(i=>i.isDirectory()?r:void 0,i=>i.code==="ENOENT"?LE(t,TE(e),e):void 0),BE=(t,e,r=void 0)=>{if(r!==e)try{return t.statSync(e).isDirectory()?r:void 0}catch(i){return i.code==="ENOENT"?BE(t,TE(e),e):void 0}};PE.exports={findMade:LE,findMadeSync:BE}});var dh=$((lI,ME)=>{var{dirname:NE}=require("path"),fh=(t,e,r)=>{e.recursive=!1;let i=NE(t);return i===t?e.mkdirAsync(t,e).catch(n=>{if(n.code!=="EISDIR")throw n}):e.mkdirAsync(t,e).then(()=>r||t,n=>{if(n.code==="ENOENT")return fh(i,e).then(s=>fh(t,e,s));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;return e.statAsync(t).then(s=>{if(s.isDirectory())return r;throw n},()=>{throw n})})},ph=(t,e,r)=>{let i=NE(t);if(e.recursive=!1,i===t)try{return e.mkdirSync(t,e)}catch(n){if(n.code!=="EISDIR")throw n;return}try{return e.mkdirSync(t,e),r||t}catch(n){if(n.code==="ENOENT")return ph(t,e,ph(i,e,r));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;try{if(!e.statSync(t).isDirectory())throw n}catch{throw n}}};ME.exports={mkdirpManual:fh,mkdirpManualSync:ph}});var HE=$((cI,$E)=>{var{dirname:jE}=require("path"),{findMade:SO,findMadeSync:AO}=IE(),{mkdirpManual:vO,mkdirpManualSync:CO}=dh(),xO=(t,e)=>(e.recursive=!0,jE(t)===t?e.mkdirAsync(t,e):SO(e,t).then(i=>e.mkdirAsync(t,e).then(()=>i).catch(n=>{if(n.code==="ENOENT")return vO(t,e);throw n}))),RO=(t,e)=>{if(e.recursive=!0,jE(t)===t)return e.mkdirSync(t,e);let i=AO(e,t);try{return e.mkdirSync(t,e),i}catch(n){if(n.code==="ENOENT")return CO(t,e);throw n}};$E.exports={mkdirpNative:xO,mkdirpNativeSync:RO}});var zE=$((hI,GE)=>{var qE=require("fs"),FO=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version,mh=FO.replace(/^v/,"").split("."),UE=+mh[0]>10||+mh[0]==10&&+mh[1]>=12,OO=UE?t=>t.mkdir===qE.mkdir:()=>!1,kO=UE?t=>t.mkdirSync===qE.mkdirSync:()=>!1;GE.exports={useNative:OO,useNativeSync:kO}});var JE=$((fI,ZE)=>{var Ji=FE(),Xi=kE(),{mkdirpNative:WE,mkdirpNativeSync:YE}=HE(),{mkdirpManual:VE,mkdirpManualSync:KE}=dh(),{useNative:TO,useNativeSync:LO}=zE(),Qi=(t,e)=>(t=Xi(t),e=Ji(e),TO(e)?WE(t,e):VE(t,e)),BO=(t,e)=>(t=Xi(t),e=Ji(e),LO(e)?YE(t,e):KE(t,e));Qi.sync=BO;Qi.native=(t,e)=>WE(Xi(t),Ji(e));Qi.manual=(t,e)=>VE(Xi(t),Ji(e));Qi.nativeSync=(t,e)=>YE(Xi(t),Ji(e));Qi.manualSync=(t,e)=>KE(Xi(t),Ji(e));ZE.exports=Qi});var nD=$((pI,iD)=>{"use strict";var at=require("fs"),ei=require("path"),PO=at.lchown?"lchown":"chown",IO=at.lchownSync?"lchownSync":"chownSync",QE=at.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),XE=(t,e,r)=>{try{return at[IO](t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},NO=(t,e,r)=>{try{return at.chownSync(t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},MO=QE?(t,e,r,i)=>n=>{!n||n.code!=="EISDIR"?i(n):at.chown(t,e,r,i)}:(t,e,r,i)=>i,gh=QE?(t,e,r)=>{try{return XE(t,e,r)}catch(i){if(i.code!=="EISDIR")throw i;NO(t,e,r)}}:(t,e,r)=>XE(t,e,r),jO=process.version,eD=(t,e,r)=>at.readdir(t,e,r),$O=(t,e)=>at.readdirSync(t,e);/^v4\./.test(jO)&&(eD=(t,e,r)=>at.readdir(t,r));var Wo=(t,e,r,i)=>{at[PO](t,e,r,MO(t,e,r,n=>{i(n&&n.code!=="ENOENT"?n:null)}))},tD=(t,e,r,i,n)=>{if(typeof e=="string")return at.lstat(ei.resolve(t,e),(s,o)=>{if(s)return n(s.code!=="ENOENT"?s:null);o.name=e,tD(t,o,r,i,n)});if(e.isDirectory())yh(ei.resolve(t,e.name),r,i,s=>{if(s)return n(s);let o=ei.resolve(t,e.name);Wo(o,r,i,n)});else{let s=ei.resolve(t,e.name);Wo(s,r,i,n)}},yh=(t,e,r,i)=>{eD(t,{withFileTypes:!0},(n,s)=>{if(n){if(n.code==="ENOENT")return i();if(n.code!=="ENOTDIR"&&n.code!=="ENOTSUP")return i(n)}if(n||!s.length)return Wo(t,e,r,i);let o=s.length,a=null,u=l=>{if(!a){if(l)return i(a=l);if(--o===0)return Wo(t,e,r,i)}};s.forEach(l=>tD(t,l,e,r,u))})},HO=(t,e,r,i)=>{if(typeof e=="string")try{let n=at.lstatSync(ei.resolve(t,e));n.name=e,e=n}catch(n){if(n.code==="ENOENT")return;throw n}e.isDirectory()&&rD(ei.resolve(t,e.name),r,i),gh(ei.resolve(t,e.name),r,i)},rD=(t,e,r)=>{let i;try{i=$O(t,{withFileTypes:!0})}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR"||n.code==="ENOTSUP")return gh(t,e,r);throw n}return i&&i.length&&i.forEach(n=>HO(t,n,e,r)),gh(t,e,r)};iD.exports=yh;yh.sync=rD});var uD=$((dI,Eh)=>{"use strict";var sD=JE(),ut=require("fs"),Yo=require("path"),oD=nD(),dt=Ni(),Vo=class extends Error{constructor(e,r){super("Cannot extract through symbolic link"),this.path=r,this.symlink=e}get name(){return"SylinkError"}},Ko=class extends Error{constructor(e,r){super(r+": Cannot cd into '"+e+"'"),this.path=e,this.code=r}get name(){return"CwdError"}},Zo=(t,e)=>t.get(dt(e)),jn=(t,e,r)=>t.set(dt(e),r),qO=(t,e)=>{ut.stat(t,(r,i)=>{(r||!i.isDirectory())&&(r=new Ko(t,r&&r.code||"ENOTDIR")),e(r)})};Eh.exports=(t,e,r)=>{t=dt(t);let i=e.umask,n=e.mode|448,s=(n&i)!==0,o=e.uid,a=e.gid,u=typeof o=="number"&&typeof a=="number"&&(o!==e.processUid||a!==e.processGid),l=e.preserve,c=e.unlink,f=e.cache,h=dt(e.cwd),p=(E,v)=>{E?r(E):(jn(f,t,!0),v&&u?oD(v,o,a,F=>p(F)):s?ut.chmod(t,n,r):r())};if(f&&Zo(f,t)===!0)return p();if(t===h)return qO(t,p);if(l)return sD(t,{mode:n}).then(E=>p(null,E),p);let y=dt(Yo.relative(h,t)).split("/");Jo(h,y,n,f,c,h,null,p)};var Jo=(t,e,r,i,n,s,o,a)=>{if(!e.length)return a(null,o);let u=e.shift(),l=dt(Yo.resolve(t+"/"+u));if(Zo(i,l))return Jo(l,e,r,i,n,s,o,a);ut.mkdir(l,r,aD(l,e,r,i,n,s,o,a))},aD=(t,e,r,i,n,s,o,a)=>u=>{u?ut.lstat(t,(l,c)=>{if(l)l.path=l.path&&dt(l.path),a(l);else if(c.isDirectory())Jo(t,e,r,i,n,s,o,a);else if(n)ut.unlink(t,f=>{if(f)return a(f);ut.mkdir(t,r,aD(t,e,r,i,n,s,o,a))});else{if(c.isSymbolicLink())return a(new Vo(t,t+"/"+e.join("/")));a(u)}}):(o=o||t,Jo(t,e,r,i,n,s,o,a))},UO=t=>{let e=!1,r="ENOTDIR";try{e=ut.statSync(t).isDirectory()}catch(i){r=i.code}finally{if(!e)throw new Ko(t,r)}};Eh.exports.sync=(t,e)=>{t=dt(t);let r=e.umask,i=e.mode|448,n=(i&r)!==0,s=e.uid,o=e.gid,a=typeof s=="number"&&typeof o=="number"&&(s!==e.processUid||o!==e.processGid),u=e.preserve,l=e.unlink,c=e.cache,f=dt(e.cwd),h=E=>{jn(c,t,!0),E&&a&&oD.sync(E,s,o),n&&ut.chmodSync(t,i)};if(c&&Zo(c,t)===!0)return h();if(t===f)return UO(f),h();if(u)return h(sD.sync(t,i));let g=dt(Yo.relative(f,t)).split("/"),y=null;for(let E=g.shift(),v=f;E&&(v+="/"+E);E=g.shift())if(v=dt(Yo.resolve(v)),!Zo(c,v))try{ut.mkdirSync(v,i),y=y||v,jn(c,v,!0)}catch{let O=ut.lstatSync(v);if(O.isDirectory()){jn(c,v,!0);continue}else if(l){ut.unlinkSync(v),ut.mkdirSync(v,i),y=y||v,jn(c,v,!0);continue}else if(O.isSymbolicLink())return new Vo(v,v+"/"+g.join("/"))}return h(y)}});var bh=$((mI,lD)=>{var Dh=Object.create(null),{hasOwnProperty:GO}=Object.prototype;lD.exports=t=>(GO.call(Dh,t)||(Dh[t]=t.normalize("NFKD")),Dh[t])});var pD=$((gI,fD)=>{var cD=require("assert"),zO=bh(),WO=$i(),{join:hD}=require("path"),YO=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,VO=YO==="win32";fD.exports=()=>{let t=new Map,e=new Map,r=l=>l.split("/").slice(0,-1).reduce((f,h)=>(f.length&&(h=hD(f[f.length-1],h)),f.push(h||"/"),f),[]),i=new Set,n=l=>{let c=e.get(l);if(!c)throw new Error("function does not have any path reservations");return{paths:c.paths.map(f=>t.get(f)),dirs:[...c.dirs].map(f=>t.get(f))}},s=l=>{let{paths:c,dirs:f}=n(l);return c.every(h=>h[0]===l)&&f.every(h=>h[0]instanceof Set&&h[0].has(l))},o=l=>i.has(l)||!s(l)?!1:(i.add(l),l(()=>a(l)),!0),a=l=>{if(!i.has(l))return!1;let{paths:c,dirs:f}=e.get(l),h=new Set;return c.forEach(p=>{let g=t.get(p);cD.equal(g[0],l),g.length===1?t.delete(p):(g.shift(),typeof g[0]=="function"?h.add(g[0]):g[0].forEach(y=>h.add(y)))}),f.forEach(p=>{let g=t.get(p);cD(g[0]instanceof Set),g[0].size===1&&g.length===1?t.delete(p):g[0].size===1?(g.shift(),h.add(g[0])):g[0].delete(l)}),i.delete(l),h.forEach(p=>o(p)),!0};return{check:s,reserve:(l,c)=>{l=VO?["win32 parallelization disabled"]:l.map(h=>zO(WO(hD(h))).toLowerCase());let f=new Set(l.map(h=>r(h)).reduce((h,p)=>h.concat(p)));return e.set(c,{dirs:f,paths:l}),l.forEach(h=>{let p=t.get(h);p?p.push(c):t.set(h,[c])}),f.forEach(h=>{let p=t.get(h);p?p[p.length-1]instanceof Set?p[p.length-1].add(c):p.push(new Set([c])):t.set(h,[new Set([c])])}),o(c)}}}});var gD=$((yI,mD)=>{var KO=process.env.__FAKE_PLATFORM__||process.platform,ZO=KO==="win32",JO=global.__FAKE_TESTING_FS__||require("fs"),{O_CREAT:XO,O_TRUNC:QO,O_WRONLY:ek,UV_FS_O_FILEMAP:dD=0}=JO.constants,tk=ZO&&!!dD,rk=512*1024,ik=dD|QO|XO|ek;mD.exports=tk?t=>t<rk?ik:"w":()=>"w"});var Fh=$((EI,OD)=>{"use strict";var nk=require("assert"),sk=Uo(),ue=require("fs"),ok=Ki(),er=require("path"),xD=uD(),yD=Rc(),ak=pD(),uk=Fc(),tt=Ni(),lk=$i(),ck=bh(),ED=Symbol("onEntry"),Sh=Symbol("checkFs"),DD=Symbol("checkFs2"),ea=Symbol("pruneCache"),Ah=Symbol("isReusable"),lt=Symbol("makeFs"),vh=Symbol("file"),Ch=Symbol("directory"),ta=Symbol("link"),bD=Symbol("symlink"),_D=Symbol("hardlink"),wD=Symbol("unsupported"),SD=Symbol("checkPath"),Cr=Symbol("mkdir"),Me=Symbol("onError"),Xo=Symbol("pending"),AD=Symbol("pend"),en=Symbol("unpend"),_h=Symbol("ended"),wh=Symbol("maybeClose"),xh=Symbol("skip"),$n=Symbol("doChown"),Hn=Symbol("uid"),qn=Symbol("gid"),Un=Symbol("checkedCwd"),RD=require("crypto"),FD=gD(),hk=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,Gn=hk==="win32",fk=(t,e)=>{if(!Gn)return ue.unlink(t,e);let r=t+".DELETE."+RD.randomBytes(16).toString("hex");ue.rename(t,r,i=>{if(i)return e(i);ue.unlink(r,e)})},pk=t=>{if(!Gn)return ue.unlinkSync(t);let e=t+".DELETE."+RD.randomBytes(16).toString("hex");ue.renameSync(t,e),ue.unlinkSync(e)},vD=(t,e,r)=>t===t>>>0?t:e===e>>>0?e:r,CD=t=>ck(lk(tt(t))).toLowerCase(),dk=(t,e)=>{e=CD(e);for(let r of t.keys()){let i=CD(r);(i===e||i.indexOf(e+"/")===0)&&t.delete(r)}},mk=t=>{for(let e of t.keys())t.delete(e)},zn=class extends sk{constructor(e){if(e||(e={}),e.ondone=r=>{this[_h]=!0,this[wh]()},super(e),this[Un]=!1,this.reservations=ak(),this.transform=typeof e.transform=="function"?e.transform:null,this.writable=!0,this.readable=!1,this[Xo]=0,this[_h]=!1,this.dirCache=e.dirCache||new Map,typeof e.uid=="number"||typeof e.gid=="number"){if(typeof e.uid!="number"||typeof e.gid!="number")throw new TypeError("cannot set owner without number uid and gid");if(e.preserveOwner)throw new TypeError("cannot preserve owner in archive and also set owner explicitly");this.uid=e.uid,this.gid=e.gid,this.setOwner=!0}else this.uid=null,this.gid=null,this.setOwner=!1;e.preserveOwner===void 0&&typeof e.uid!="number"?this.preserveOwner=process.getuid&&process.getuid()===0:this.preserveOwner=!!e.preserveOwner,this.processUid=(this.preserveOwner||this.setOwner)&&process.getuid?process.getuid():null,this.processGid=(this.preserveOwner||this.setOwner)&&process.getgid?process.getgid():null,this.forceChown=e.forceChown===!0,this.win32=!!e.win32||Gn,this.newer=!!e.newer,this.keep=!!e.keep,this.noMtime=!!e.noMtime,this.preservePaths=!!e.preservePaths,this.unlink=!!e.unlink,this.cwd=tt(er.resolve(e.cwd||process.cwd())),this.strip=+e.strip||0,this.processUmask=e.noChmod?0:process.umask(),this.umask=typeof e.umask=="number"?e.umask:this.processUmask,this.dmode=e.dmode||511&~this.umask,this.fmode=e.fmode||438&~this.umask,this.on("entry",r=>this[ED](r))}warn(e,r,i={}){return(e==="TAR_BAD_ARCHIVE"||e==="TAR_ABORT")&&(i.recoverable=!1),super.warn(e,r,i)}[wh](){this[_h]&&this[Xo]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"))}[SD](e){if(this.strip){let r=tt(e.path).split("/");if(r.length<this.strip)return!1;if(e.path=r.slice(this.strip).join("/"),e.type==="Link"){let i=tt(e.linkpath).split("/");if(i.length>=this.strip)e.linkpath=i.slice(this.strip).join("/");else return!1}}if(!this.preservePaths){let r=tt(e.path),i=r.split("/");if(i.includes("..")||Gn&&/^[a-z]:\.\.$/i.test(i[0]))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:e,path:r}),!1;let[n,s]=uk(r);n&&(e.path=s,this.warn("TAR_ENTRY_INFO",`stripping ${n} from absolute path`,{entry:e,path:r}))}if(er.isAbsolute(e.path)?e.absolute=tt(er.resolve(e.path)):e.absolute=tt(er.resolve(this.cwd,e.path)),!this.preservePaths&&e.absolute.indexOf(this.cwd+"/")!==0&&e.absolute!==this.cwd)return this.warn("TAR_ENTRY_ERROR","path escaped extraction target",{entry:e,path:tt(e.path),resolvedPath:e.absolute,cwd:this.cwd}),!1;if(e.absolute===this.cwd&&e.type!=="Directory"&&e.type!=="GNUDumpDir")return!1;if(this.win32){let{root:r}=er.win32.parse(e.absolute);e.absolute=r+yD.encode(e.absolute.slice(r.length));let{root:i}=er.win32.parse(e.path);e.path=i+yD.encode(e.path.slice(i.length))}return!0}[ED](e){if(!this[SD](e))return e.resume();switch(nk.equal(typeof e.absolute,"string"),e.type){case"Directory":case"GNUDumpDir":e.mode&&(e.mode=e.mode|448);case"File":case"OldFile":case"ContiguousFile":case"Link":case"SymbolicLink":return this[Sh](e);case"CharacterDevice":case"BlockDevice":case"FIFO":default:return this[wD](e)}}[Me](e,r){e.name==="CwdError"?this.emit("error",e):(this.warn("TAR_ENTRY_ERROR",e,{entry:r}),this[en](),r.resume())}[Cr](e,r,i){xD(tt(e),{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:r,noChmod:this.noChmod},i)}[$n](e){return this.forceChown||this.preserveOwner&&(typeof e.uid=="number"&&e.uid!==this.processUid||typeof e.gid=="number"&&e.gid!==this.processGid)||typeof this.uid=="number"&&this.uid!==this.processUid||typeof this.gid=="number"&&this.gid!==this.processGid}[Hn](e){return vD(this.uid,e.uid,this.processUid)}[qn](e){return vD(this.gid,e.gid,this.processGid)}[vh](e,r){let i=e.mode&4095||this.fmode,n=new ok.WriteStream(e.absolute,{flags:FD(e.size),mode:i,autoClose:!1});n.on("error",u=>{n.fd&&ue.close(n.fd,()=>{}),n.write=()=>!0,this[Me](u,e),r()});let s=1,o=u=>{if(u){n.fd&&ue.close(n.fd,()=>{}),this[Me](u,e),r();return}--s===0&&ue.close(n.fd,l=>{l?this[Me](l,e):this[en](),r()})};n.on("finish",u=>{let l=e.absolute,c=n.fd;if(e.mtime&&!this.noMtime){s++;let f=e.atime||new Date,h=e.mtime;ue.futimes(c,f,h,p=>p?ue.utimes(l,f,h,g=>o(g&&p)):o())}if(this[$n](e)){s++;let f=this[Hn](e),h=this[qn](e);ue.fchown(c,f,h,p=>p?ue.chown(l,f,h,g=>o(g&&p)):o())}o()});let a=this.transform&&this.transform(e)||e;a!==e&&(a.on("error",u=>{this[Me](u,e),r()}),e.pipe(a)),a.pipe(n)}[Ch](e,r){let i=e.mode&4095||this.dmode;this[Cr](e.absolute,i,n=>{if(n){this[Me](n,e),r();return}let s=1,o=a=>{--s===0&&(r(),this[en](),e.resume())};e.mtime&&!this.noMtime&&(s++,ue.utimes(e.absolute,e.atime||new Date,e.mtime,o)),this[$n](e)&&(s++,ue.chown(e.absolute,this[Hn](e),this[qn](e),o)),o()})}[wD](e){e.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${e.type}`,{entry:e}),e.resume()}[bD](e,r){this[ta](e,e.linkpath,"symlink",r)}[_D](e,r){let i=tt(er.resolve(this.cwd,e.linkpath));this[ta](e,i,"link",r)}[AD](){this[Xo]++}[en](){this[Xo]--,this[wh]()}[xh](e){this[en](),e.resume()}[Ah](e,r){return e.type==="File"&&!this.unlink&&r.isFile()&&r.nlink<=1&&!Gn}[Sh](e){this[AD]();let r=[e.path];e.linkpath&&r.push(e.linkpath),this.reservations.reserve(r,i=>this[DD](e,i))}[ea](e){e.type==="SymbolicLink"?mk(this.dirCache):e.type!=="Directory"&&dk(this.dirCache,e.absolute)}[DD](e,r){this[ea](e);let i=a=>{this[ea](e),r(a)},n=()=>{this[Cr](this.cwd,this.dmode,a=>{if(a){this[Me](a,e),i();return}this[Un]=!0,s()})},s=()=>{if(e.absolute!==this.cwd){let a=tt(er.dirname(e.absolute));if(a!==this.cwd)return this[Cr](a,this.dmode,u=>{if(u){this[Me](u,e),i();return}o()})}o()},o=()=>{ue.lstat(e.absolute,(a,u)=>{if(u&&(this.keep||this.newer&&u.mtime>e.mtime)){this[xh](e),i();return}if(a||this[Ah](e,u))return this[lt](null,e,i);if(u.isDirectory()){if(e.type==="Directory"){let l=!this.noChmod&&e.mode&&(u.mode&4095)!==e.mode,c=f=>this[lt](f,e,i);return l?ue.chmod(e.absolute,e.mode,c):c()}if(e.absolute!==this.cwd)return ue.rmdir(e.absolute,l=>this[lt](l,e,i))}if(e.absolute===this.cwd)return this[lt](null,e,i);fk(e.absolute,l=>this[lt](l,e,i))})};this[Un]?s():n()}[lt](e,r,i){if(e){this[Me](e,r),i();return}switch(r.type){case"File":case"OldFile":case"ContiguousFile":return this[vh](r,i);case"Link":return this[_D](r,i);case"SymbolicLink":return this[bD](r,i);case"Directory":case"GNUDumpDir":return this[Ch](r,i)}}[ta](e,r,i,n){ue[i](r,e.absolute,s=>{s?this[Me](s,e):(this[en](),e.resume()),n()})}},Qo=t=>{try{return[null,t()]}catch(e){return[e,null]}},Rh=class extends zn{[lt](e,r){return super[lt](e,r,()=>{})}[Sh](e){if(this[ea](e),!this[Un]){let s=this[Cr](this.cwd,this.dmode);if(s)return this[Me](s,e);this[Un]=!0}if(e.absolute!==this.cwd){let s=tt(er.dirname(e.absolute));if(s!==this.cwd){let o=this[Cr](s,this.dmode);if(o)return this[Me](o,e)}}let[r,i]=Qo(()=>ue.lstatSync(e.absolute));if(i&&(this.keep||this.newer&&i.mtime>e.mtime))return this[xh](e);if(r||this[Ah](e,i))return this[lt](null,e);if(i.isDirectory()){if(e.type==="Directory"){let o=!this.noChmod&&e.mode&&(i.mode&4095)!==e.mode,[a]=o?Qo(()=>{ue.chmodSync(e.absolute,e.mode)}):[];return this[lt](a,e)}let[s]=Qo(()=>ue.rmdirSync(e.absolute));this[lt](s,e)}let[n]=e.absolute===this.cwd?[]:Qo(()=>pk(e.absolute));this[lt](n,e)}[vh](e,r){let i=e.mode&4095||this.fmode,n=a=>{let u;try{ue.closeSync(s)}catch(l){u=l}(a||u)&&this[Me](a||u,e),r()},s;try{s=ue.openSync(e.absolute,FD(e.size),i)}catch(a){return n(a)}let o=this.transform&&this.transform(e)||e;o!==e&&(o.on("error",a=>this[Me](a,e)),e.pipe(o)),o.on("data",a=>{try{ue.writeSync(s,a,0,a.length)}catch(u){n(u)}}),o.on("end",a=>{let u=null;if(e.mtime&&!this.noMtime){let l=e.atime||new Date,c=e.mtime;try{ue.futimesSync(s,l,c)}catch(f){try{ue.utimesSync(e.absolute,l,c)}catch{u=f}}}if(this[$n](e)){let l=this[Hn](e),c=this[qn](e);try{ue.fchownSync(s,l,c)}catch(f){try{ue.chownSync(e.absolute,l,c)}catch{u=u||f}}}n(u)})}[Ch](e,r){let i=e.mode&4095||this.dmode,n=this[Cr](e.absolute,i);if(n){this[Me](n,e),r();return}if(e.mtime&&!this.noMtime)try{ue.utimesSync(e.absolute,e.atime||new Date,e.mtime)}catch{}if(this[$n](e))try{ue.chownSync(e.absolute,this[Hn](e),this[qn](e))}catch{}r(),e.resume()}[Cr](e,r){try{return xD.sync(tt(e),{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:r})}catch(i){return i}}[ta](e,r,i,n){try{ue[i+"Sync"](r,e.absolute),n(),e.resume()}catch(s){return this[Me](s,e)}}};zn.Sync=Rh;OD.exports=zn});var PD=$((DI,BD)=>{"use strict";var gk=Ti(),ra=Fh(),TD=require("fs"),LD=Ki(),kD=require("path"),Oh=$i();BD.exports=(t,e,r)=>{typeof t=="function"?(r=t,e=null,t={}):Array.isArray(t)&&(e=t,t={}),typeof e=="function"&&(r=e,e=null),e?e=Array.from(e):e=[];let i=gk(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return e.length&&yk(i,e),i.file&&i.sync?Ek(i):i.file?Dk(i,r):i.sync?bk(i):_k(i)};var yk=(t,e)=>{let r=new Map(e.map(s=>[Oh(s),!0])),i=t.filter,n=(s,o)=>{let a=o||kD.parse(s).root||".",u=s===a?!1:r.has(s)?r.get(s):n(kD.dirname(s),a);return r.set(s,u),u};t.filter=i?(s,o)=>i(s,o)&&n(Oh(s)):s=>n(Oh(s))},Ek=t=>{let e=new ra.Sync(t),r=t.file,i=TD.statSync(r),n=t.maxReadSize||16*1024*1024;new LD.ReadStreamSync(r,{readSize:n,size:i.size}).pipe(e)},Dk=(t,e)=>{let r=new ra(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("close",o),TD.stat(n,(u,l)=>{if(u)a(u);else{let c=new LD.ReadStream(n,{readSize:i,size:l.size});c.on("error",a),c.pipe(r)}})});return e?s.then(e,e):s},bk=t=>new ra.Sync(t),_k=t=>new ra(t)});var ID=$(Ce=>{"use strict";Ce.c=Ce.create=yE();Ce.r=Ce.replace=hh();Ce.t=Ce.list=Go();Ce.u=Ce.update=CE();Ce.x=Ce.extract=PD();Ce.Pack=Fo();Ce.Unpack=Fh();Ce.Parse=Uo();Ce.ReadEntry=ho();Ce.WriteEntry=jc();Ce.Header=ji();Ce.Pax=po();Ce.types=_c()});var qD=$((AI,HD)=>{function ct(t,e){typeof e=="boolean"&&(e={forever:e}),this._originalTimeouts=JSON.parse(JSON.stringify(t)),this._timeouts=t,this._options=e||{},this._maxRetryTime=e&&e.maxRetryTime||1/0,this._fn=null,this._errors=[],this._attempts=1,this._operationTimeout=null,this._operationTimeoutCb=null,this._timeout=null,this._operationStart=null,this._timer=null,this._options.forever&&(this._cachedTimeouts=this._timeouts.slice(0))}HD.exports=ct;ct.prototype.reset=function(){this._attempts=1,this._timeouts=this._originalTimeouts.slice(0)};ct.prototype.stop=function(){this._timeout&&clearTimeout(this._timeout),this._timer&&clearTimeout(this._timer),this._timeouts=[],this._cachedTimeouts=null};ct.prototype.retry=function(t){if(this._timeout&&clearTimeout(this._timeout),!t)return!1;var e=new Date().getTime();if(t&&e-this._operationStart>=this._maxRetryTime)return this._errors.push(t),this._errors.unshift(new Error("RetryOperation timeout occurred")),!1;this._errors.push(t);var r=this._timeouts.shift();if(r===void 0)if(this._cachedTimeouts)this._errors.splice(0,this._errors.length-1),r=this._cachedTimeouts.slice(-1);else return!1;var i=this;return this._timer=setTimeout(function(){i._attempts++,i._operationTimeoutCb&&(i._timeout=setTimeout(function(){i._operationTimeoutCb(i._attempts)},i._operationTimeout),i._options.unref&&i._timeout.unref()),i._fn(i._attempts)},r),this._options.unref&&this._timer.unref(),!0};ct.prototype.attempt=function(t,e){this._fn=t,e&&(e.timeout&&(this._operationTimeout=e.timeout),e.cb&&(this._operationTimeoutCb=e.cb));var r=this;this._operationTimeoutCb&&(this._timeout=setTimeout(function(){r._operationTimeoutCb()},r._operationTimeout)),this._operationStart=new Date().getTime(),this._fn(this._attempts)};ct.prototype.try=function(t){console.log("Using RetryOperation.try() is deprecated"),this.attempt(t)};ct.prototype.start=function(t){console.log("Using RetryOperation.start() is deprecated"),this.attempt(t)};ct.prototype.start=ct.prototype.try;ct.prototype.errors=function(){return this._errors};ct.prototype.attempts=function(){return this._attempts};ct.prototype.mainError=function(){if(this._errors.length===0)return null;for(var t={},e=null,r=0,i=0;i<this._errors.length;i++){var n=this._errors[i],s=n.message,o=(t[s]||0)+1;t[s]=o,o>=r&&(e=n,r=o)}return e}});var UD=$(ti=>{var vk=qD();ti.operation=function(t){var e=ti.timeouts(t);return new vk(e,{forever:t&&(t.forever||t.retries===1/0),unref:t&&t.unref,maxRetryTime:t&&t.maxRetryTime})};ti.timeouts=function(t){if(t instanceof Array)return[].concat(t);var e={retries:10,factor:2,minTimeout:1*1e3,maxTimeout:1/0,randomize:!1};for(var r in t)e[r]=t[r];if(e.minTimeout>e.maxTimeout)throw new Error("minTimeout is greater than maxTimeout");for(var i=[],n=0;n<e.retries;n++)i.push(this.createTimeout(n,e));return t&&t.forever&&!i.length&&i.push(this.createTimeout(n,e)),i.sort(function(s,o){return s-o}),i};ti.createTimeout=function(t,e){var r=e.randomize?Math.random()+1:1,i=Math.round(r*Math.max(e.minTimeout,1)*Math.pow(e.factor,t));return i=Math.min(i,e.maxTimeout),i};ti.wrap=function(t,e,r){if(e instanceof Array&&(r=e,e=null),!r){r=[];for(var i in t)typeof t[i]=="function"&&r.push(i)}for(var n=0;n<r.length;n++){var s=r[n],o=t[s];t[s]=function(u){var l=ti.operation(e),c=Array.prototype.slice.call(arguments,1),f=c.pop();c.push(function(h){l.retry(h)||(h&&(arguments[0]=l.mainError()),f.apply(this,arguments))}),l.attempt(function(){u.apply(t,c)})}.bind(t,o),t[s].options=e}}});var zD=$((CI,GD)=>{GD.exports=UD()});var YD=$((xI,WD)=>{var Ck=zD();function xk(t,e){function r(i,n){var s=e||{},o;"randomize"in s||(s.randomize=!0),o=Ck.operation(s);function a(c){n(c||new Error("Aborted"))}function u(c,f){if(c.bail){a(c);return}o.retry(c)?s.onRetry&&s.onRetry(c,f):n(o.mainError())}function l(c){var f;try{f=t(a,c)}catch(h){u(h,c);return}Promise.resolve(f).then(i).catch(function(p){u(p,c)})}o.attempt(l)}return new Promise(r)}WD.exports=xk});var Kb=J(require("chalk"));var n_=J(tf());function Sa(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function cn(t){return cn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},cn(t)}function Aa(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function va(t,e){if(e&&(cn(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Aa(t)}function Lr(t){return Lr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Lr(t)}function Nt(t,e){return Nt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,n){return i.__proto__=n,i},Nt(t,e)}function Ca(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Nt(t,e)}function xa(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function Ra(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ai(t,e,r){return Ra()?ai=Reflect.construct.bind():ai=function(n,s,o){var a=[null];a.push.apply(a,s);var u=Function.bind.apply(n,a),l=new u;return o&&Nt(l,o.prototype),l},ai.apply(null,arguments)}function hn(t){var e=typeof Map=="function"?new Map:void 0;return hn=function(i){if(i===null||!xa(i))return i;if(typeof i!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e!="undefined"){if(e.has(i))return e.get(i);e.set(i,n)}function n(){return ai(i,arguments,Lr(this).constructor)}return n.prototype=Object.create(i.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),Nt(n,i)},hn(t)}var rf=J(require("find-up"));var s_=J(require("fs-extra")),aB=function(t){Ca(e,t);function e(r){var i;return Sa(this,e),i=va(this,Lr(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),i.directory=r,i}return e}(hn(Error));var o_=J(require("fs")),a_=J(require("path"));var HC=J(require("fs")),qC=J(require("path"));function Df(t){return typeof t=="undefined"||t===null}function c_(t){return typeof t=="object"&&t!==null}function h_(t){return Array.isArray(t)?t:Df(t)?[]:[t]}function f_(t,e){var r,i,n,s;if(e)for(s=Object.keys(e),r=0,i=s.length;r<i;r+=1)n=s[r],t[n]=e[n];return t}function p_(t,e){var r="",i;for(i=0;i<e;i+=1)r+=t;return r}function d_(t){return t===0&&Number.NEGATIVE_INFINITY===1/t}var m_=Df,g_=c_,y_=h_,E_=p_,D_=d_,b_=f_,ve={isNothing:m_,isObject:g_,toArray:y_,repeat:E_,isNegativeZero:D_,extend:b_};function bf(t,e){var r="",i=t.reason||"(unknown reason)";return t.mark?(t.mark.name&&(r+='in "'+t.mark.name+'" '),r+="("+(t.mark.line+1)+":"+(t.mark.column+1)+")",!e&&t.mark.snippet&&(r+=`
9
+ `).reduce(SF,Object.create(null)),SF=(t,e)=>{let r=parseInt(e,10);if(r!==Buffer.byteLength(e)+1)return t;e=e.slice((r+" ").length);let i=e.split("="),n=i.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!n)return t;let s=i.join("=");return t[n]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(n)?new Date(s*1e3):/^[0-9]+$/.test(s)?+s:s,t};Dy.exports=Ln});var $i=$(($2,by)=>{by.exports=t=>{let e=t.length-1,r=-1;for(;e>-1&&t.charAt(e)==="/";)r=e,e--;return r===-1?t:t.slice(0,r)}});var mo=$((H2,_y)=>{"use strict";_y.exports=t=>class extends t{warn(e,r,i={}){this.file&&(i.file=this.file),this.cwd&&(i.cwd=this.cwd),i.code=r instanceof Error&&r.code||e,i.tarCode=e,!this.strict&&i.recoverable!==!1?(r instanceof Error&&(i=Object.assign(r,i),r=r.message),this.emit("warn",i.tarCode,r,i)):r instanceof Error?this.emit("error",Object.assign(r,i)):this.emit("error",Object.assign(new Error(`${e}: ${r}`),i))}}});var Rc=$((U2,wy)=>{"use strict";var go=["|","<",">","?",":"],xc=go.map(t=>String.fromCharCode(61440+t.charCodeAt(0))),AF=new Map(go.map((t,e)=>[t,xc[e]])),vF=new Map(xc.map((t,e)=>[t,go[e]]));wy.exports={encode:t=>go.reduce((e,r)=>e.split(r).join(AF.get(r)),t),decode:t=>xc.reduce((e,r)=>e.split(r).join(vF.get(r)),t)}});var Fc=$((G2,Ay)=>{var{isAbsolute:CF,parse:Sy}=require("path").win32;Ay.exports=t=>{let e="",r=Sy(t);for(;CF(t)||r.root;){let i=t.charAt(0)==="/"&&t.slice(0,4)!=="//?/"?"/":r.root;t=t.slice(i.length),e+=i,r=Sy(t)}return[e,t]}});var Cy=$((z2,vy)=>{"use strict";vy.exports=(t,e,r)=>(t&=4095,r&&(t=(t|384)&-19),e&&(t&256&&(t|=64),t&32&&(t|=8),t&4&&(t|=1)),t)});var jc=$((V2,$y)=>{"use strict";var Ly=ro(),By=po(),Py=ji(),xt=require("fs"),xy=require("path"),Ct=Ni(),xF=$i(),Iy=(t,e)=>e?(t=Ct(t).replace(/^\.(\/|$)/,""),xF(e)+"/"+t):Ct(t),RF=16*1024*1024,Ry=Symbol("process"),Fy=Symbol("file"),Oy=Symbol("directory"),kc=Symbol("symlink"),ky=Symbol("hardlink"),Bn=Symbol("header"),yo=Symbol("read"),Tc=Symbol("lstat"),Eo=Symbol("onlstat"),Lc=Symbol("onread"),Bc=Symbol("onreadlink"),Pc=Symbol("openfile"),Ic=Symbol("onopenfile"),br=Symbol("close"),Do=Symbol("mode"),Nc=Symbol("awaitDrain"),Oc=Symbol("ondrain"),Rt=Symbol("prefix"),Ty=Symbol("hadError"),Ny=mo(),FF=Rc(),My=Fc(),jy=Cy(),bo=Ny(class extends Ly{constructor(e,r){if(r=r||{},super(r),typeof e!="string")throw new TypeError("path is required");this.path=Ct(e),this.portable=!!r.portable,this.myuid=process.getuid&&process.getuid()||0,this.myuser=process.env.USER||"",this.maxReadSize=r.maxReadSize||RF,this.linkCache=r.linkCache||new Map,this.statCache=r.statCache||new Map,this.preservePaths=!!r.preservePaths,this.cwd=Ct(r.cwd||process.cwd()),this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.mtime=r.mtime||null,this.prefix=r.prefix?Ct(r.prefix):null,this.fd=null,this.blockLen=null,this.blockRemain=null,this.buf=null,this.offset=null,this.length=null,this.pos=null,this.remain=null,typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(!this.preservePaths){let[n,s]=My(this.path);n&&(this.path=s,i=n)}this.win32=!!r.win32||process.platform==="win32",this.win32&&(this.path=FF.decode(this.path.replace(/\\/g,"/")),e=e.replace(/\\/g,"/")),this.absolute=Ct(r.absolute||xy.resolve(this.cwd,e)),this.path===""&&(this.path="./"),i&&this.warn("TAR_ENTRY_INFO",`stripping ${i} from absolute path`,{entry:this,path:i+this.path}),this.statCache.has(this.absolute)?this[Eo](this.statCache.get(this.absolute)):this[Tc]()}emit(e,...r){return e==="error"&&(this[Ty]=!0),super.emit(e,...r)}[Tc](){xt.lstat(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[Eo](r)})}[Eo](e){this.statCache.set(this.absolute,e),this.stat=e,e.isFile()||(e.size=0),this.type=kF(e),this.emit("stat",e),this[Ry]()}[Ry](){switch(this.type){case"File":return this[Fy]();case"Directory":return this[Oy]();case"SymbolicLink":return this[kc]();default:return this.end()}}[Do](e){return jy(e,this.type==="Directory",this.portable)}[Rt](e){return Iy(e,this.prefix)}[Bn](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new Py({path:this[Rt](this.path),linkpath:this.type==="Link"?this[Rt](this.linkpath):this.linkpath,mode:this[Do](this.stat.mode),uid:this.portable?null:this.stat.uid,gid:this.portable?null:this.stat.gid,size:this.stat.size,mtime:this.noMtime?null:this.mtime||this.stat.mtime,type:this.type,uname:this.portable?null:this.stat.uid===this.myuid?this.myuser:"",atime:this.portable?null:this.stat.atime,ctime:this.portable?null:this.stat.ctime}),this.header.encode()&&!this.noPax&&super.write(new By({atime:this.portable?null:this.header.atime,ctime:this.portable?null:this.header.ctime,gid:this.portable?null:this.header.gid,mtime:this.noMtime?null:this.mtime||this.header.mtime,path:this[Rt](this.path),linkpath:this.type==="Link"?this[Rt](this.linkpath):this.linkpath,size:this.header.size,uid:this.portable?null:this.header.uid,uname:this.portable?null:this.header.uname,dev:this.portable?null:this.stat.dev,ino:this.portable?null:this.stat.ino,nlink:this.portable?null:this.stat.nlink}).encode()),super.write(this.header.block)}[Oy](){this.path.slice(-1)!=="/"&&(this.path+="/"),this.stat.size=0,this[Bn](),this.end()}[kc](){xt.readlink(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[Bc](r)})}[Bc](e){this.linkpath=Ct(e),this[Bn](),this.end()}[ky](e){this.type="Link",this.linkpath=Ct(xy.relative(this.cwd,e)),this.stat.size=0,this[Bn](),this.end()}[Fy](){if(this.stat.nlink>1){let e=this.stat.dev+":"+this.stat.ino;if(this.linkCache.has(e)){let r=this.linkCache.get(e);if(r.indexOf(this.cwd)===0)return this[ky](r)}this.linkCache.set(e,this.absolute)}if(this[Bn](),this.stat.size===0)return this.end();this[Pc]()}[Pc](){xt.open(this.absolute,"r",(e,r)=>{if(e)return this.emit("error",e);this[Ic](r)})}[Ic](e){if(this.fd=e,this[Ty])return this[br]();this.blockLen=512*Math.ceil(this.stat.size/512),this.blockRemain=this.blockLen;let r=Math.min(this.blockLen,this.maxReadSize);this.buf=Buffer.allocUnsafe(r),this.offset=0,this.pos=0,this.remain=this.stat.size,this.length=this.buf.length,this[yo]()}[yo](){let{fd:e,buf:r,offset:i,length:n,pos:s}=this;xt.read(e,r,i,n,s,(o,a)=>{if(o)return this[br](()=>this.emit("error",o));this[Lc](a)})}[br](e){xt.close(this.fd,e)}[Lc](e){if(e<=0&&this.remain>0){let n=new Error("encountered unexpected EOF");return n.path=this.absolute,n.syscall="read",n.code="EOF",this[br](()=>this.emit("error",n))}if(e>this.remain){let n=new Error("did not encounter expected EOF");return n.path=this.absolute,n.syscall="read",n.code="EOF",this[br](()=>this.emit("error",n))}if(e===this.remain)for(let n=e;n<this.length&&e<this.blockRemain;n++)this.buf[n+this.offset]=0,e++,this.remain++;let r=this.offset===0&&e===this.buf.length?this.buf:this.buf.slice(this.offset,this.offset+e);this.write(r)?this[Oc]():this[Nc](()=>this[Oc]())}[Nc](e){this.once("drain",e)}write(e){if(this.blockRemain<e.length){let r=new Error("writing more data than expected");return r.path=this.absolute,this.emit("error",r)}return this.remain-=e.length,this.blockRemain-=e.length,this.pos+=e.length,this.offset+=e.length,super.write(e)}[Oc](){if(!this.remain)return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),this[br](e=>e?this.emit("error",e):this.end());this.offset>=this.length&&(this.buf=Buffer.allocUnsafe(Math.min(this.blockRemain,this.buf.length)),this.offset=0),this.length=this.buf.length-this.offset,this[yo]()}}),Mc=class extends bo{[Tc](){this[Eo](xt.lstatSync(this.absolute))}[kc](){this[Bc](xt.readlinkSync(this.absolute))}[Pc](){this[Ic](xt.openSync(this.absolute,"r"))}[yo](){let e=!0;try{let{fd:r,buf:i,offset:n,length:s,pos:o}=this,a=xt.readSync(r,i,n,s,o);this[Lc](a),e=!1}finally{if(e)try{this[br](()=>{})}catch{}}}[Nc](e){e()}[br](e){xt.closeSync(this.fd),e()}},OF=Ny(class extends Ly{constructor(e,r){r=r||{},super(r),this.preservePaths=!!r.preservePaths,this.portable=!!r.portable,this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.readEntry=e,this.type=e.type,this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.prefix=r.prefix||null,this.path=Ct(e.path),this.mode=this[Do](e.mode),this.uid=this.portable?null:e.uid,this.gid=this.portable?null:e.gid,this.uname=this.portable?null:e.uname,this.gname=this.portable?null:e.gname,this.size=e.size,this.mtime=this.noMtime?null:r.mtime||e.mtime,this.atime=this.portable?null:e.atime,this.ctime=this.portable?null:e.ctime,this.linkpath=Ct(e.linkpath),typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(!this.preservePaths){let[n,s]=My(this.path);n&&(this.path=s,i=n)}this.remain=e.size,this.blockRemain=e.startBlockSize,this.header=new Py({path:this[Rt](this.path),linkpath:this.type==="Link"?this[Rt](this.linkpath):this.linkpath,mode:this.mode,uid:this.portable?null:this.uid,gid:this.portable?null:this.gid,size:this.size,mtime:this.noMtime?null:this.mtime,type:this.type,uname:this.portable?null:this.uname,atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime}),i&&this.warn("TAR_ENTRY_INFO",`stripping ${i} from absolute path`,{entry:this,path:i+this.path}),this.header.encode()&&!this.noPax&&super.write(new By({atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime,gid:this.portable?null:this.gid,mtime:this.noMtime?null:this.mtime,path:this[Rt](this.path),linkpath:this.type==="Link"?this[Rt](this.linkpath):this.linkpath,size:this.size,uid:this.portable?null:this.uid,uname:this.portable?null:this.uname,dev:this.portable?null:this.readEntry.dev,ino:this.portable?null:this.readEntry.ino,nlink:this.portable?null:this.readEntry.nlink}).encode()),super.write(this.header.block),e.pipe(this)}[Rt](e){return Iy(e,this.prefix)}[Do](e){return jy(e,this.type==="Directory",this.portable)}write(e){let r=e.length;if(r>this.blockRemain)throw new Error("writing more to entry than is appropriate");return this.blockRemain-=r,super.write(e)}end(){return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),super.end()}});bo.Sync=Mc;bo.Tar=OF;var kF=t=>t.isFile()?"File":t.isDirectory()?"Directory":t.isSymbolicLink()?"SymbolicLink":"Unsupported";$y.exports=bo});var qy=$((K2,Hy)=>{"use strict";Hy.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var $c=$((Z2,Uy)=>{"use strict";Uy.exports=ae;ae.Node=Vr;ae.create=ae;function ae(t){var e=this;if(e instanceof ae||(e=new ae),e.tail=null,e.head=null,e.length=0,t&&typeof t.forEach=="function")t.forEach(function(n){e.push(n)});else if(arguments.length>0)for(var r=0,i=arguments.length;r<i;r++)e.push(arguments[r]);return e}ae.prototype.removeNode=function(t){if(t.list!==this)throw new Error("removing node which does not belong to this list");var e=t.next,r=t.prev;return e&&(e.prev=r),r&&(r.next=e),t===this.head&&(this.head=e),t===this.tail&&(this.tail=r),t.list.length--,t.next=null,t.prev=null,t.list=null,e};ae.prototype.unshiftNode=function(t){if(t!==this.head){t.list&&t.list.removeNode(t);var e=this.head;t.list=this,t.next=e,e&&(e.prev=t),this.head=t,this.tail||(this.tail=t),this.length++}};ae.prototype.pushNode=function(t){if(t!==this.tail){t.list&&t.list.removeNode(t);var e=this.tail;t.list=this,t.prev=e,e&&(e.next=t),this.tail=t,this.head||(this.head=t),this.length++}};ae.prototype.push=function(){for(var t=0,e=arguments.length;t<e;t++)LF(this,arguments[t]);return this.length};ae.prototype.unshift=function(){for(var t=0,e=arguments.length;t<e;t++)BF(this,arguments[t]);return this.length};ae.prototype.pop=function(){if(this.tail){var t=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,t}};ae.prototype.shift=function(){if(this.head){var t=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,t}};ae.prototype.forEach=function(t,e){e=e||this;for(var r=this.head,i=0;r!==null;i++)t.call(e,r.value,i,this),r=r.next};ae.prototype.forEachReverse=function(t,e){e=e||this;for(var r=this.tail,i=this.length-1;r!==null;i--)t.call(e,r.value,i,this),r=r.prev};ae.prototype.get=function(t){for(var e=0,r=this.head;r!==null&&e<t;e++)r=r.next;if(e===t&&r!==null)return r.value};ae.prototype.getReverse=function(t){for(var e=0,r=this.tail;r!==null&&e<t;e++)r=r.prev;if(e===t&&r!==null)return r.value};ae.prototype.map=function(t,e){e=e||this;for(var r=new ae,i=this.head;i!==null;)r.push(t.call(e,i.value,this)),i=i.next;return r};ae.prototype.mapReverse=function(t,e){e=e||this;for(var r=new ae,i=this.tail;i!==null;)r.push(t.call(e,i.value,this)),i=i.prev;return r};ae.prototype.reduce=function(t,e){var r,i=this.head;if(arguments.length>1)r=e;else if(this.head)i=this.head.next,r=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=0;i!==null;n++)r=t(r,i.value,n),i=i.next;return r};ae.prototype.reduceReverse=function(t,e){var r,i=this.tail;if(arguments.length>1)r=e;else if(this.tail)i=this.tail.prev,r=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=this.length-1;i!==null;n--)r=t(r,i.value,n),i=i.prev;return r};ae.prototype.toArray=function(){for(var t=new Array(this.length),e=0,r=this.head;r!==null;e++)t[e]=r.value,r=r.next;return t};ae.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,r=this.tail;r!==null;e++)t[e]=r.value,r=r.prev;return t};ae.prototype.slice=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new ae;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=0,n=this.head;n!==null&&i<t;i++)n=n.next;for(;n!==null&&i<e;i++,n=n.next)r.push(n.value);return r};ae.prototype.sliceReverse=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new ae;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=this.length,n=this.tail;n!==null&&i>e;i--)n=n.prev;for(;n!==null&&i>t;i--,n=n.prev)r.push(n.value);return r};ae.prototype.splice=function(t,e,...r){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var i=0,n=this.head;n!==null&&i<t;i++)n=n.next;for(var s=[],i=0;n&&i<e;i++)s.push(n.value),n=this.removeNode(n);n===null&&(n=this.tail),n!==this.head&&n!==this.tail&&(n=n.prev);for(var i=0;i<r.length;i++)n=TF(this,n,r[i]);return s};ae.prototype.reverse=function(){for(var t=this.head,e=this.tail,r=t;r!==null;r=r.prev){var i=r.prev;r.prev=r.next,r.next=i}return this.head=e,this.tail=t,this};function TF(t,e,r){var i=e===t.head?new Vr(r,null,e,t):new Vr(r,e,e.next,t);return i.next===null&&(t.tail=i),i.prev===null&&(t.head=i),t.length++,i}function LF(t,e){t.tail=new Vr(e,t.tail,null,t),t.head||(t.head=t.tail),t.length++}function BF(t,e){t.head=new Vr(e,null,t.head,t),t.tail||(t.tail=t.head),t.length++}function Vr(t,e,r,i){if(!(this instanceof Vr))return new Vr(t,e,r,i);this.list=i,this.value=t,e?(e.next=this,this.prev=e):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}try{qy()(ae)}catch{}});var Fo=$((X2,Zy)=>{"use strict";var xo=class{constructor(e,r){this.path=e||"./",this.absolute=r,this.entry=null,this.stat=null,this.readdir=null,this.pending=!1,this.ignore=!1,this.piped=!1}},PF=ro(),IF=Ec(),NF=ho(),Kc=jc(),MF=Kc.Sync,jF=Kc.Tar,$F=$c(),Gy=Buffer.alloc(1024),So=Symbol("onStat"),_o=Symbol("ended"),Ft=Symbol("queue"),Hi=Symbol("current"),Kr=Symbol("process"),wo=Symbol("processing"),zy=Symbol("processJob"),Ot=Symbol("jobs"),Hc=Symbol("jobDone"),Ao=Symbol("addFSEntry"),Wy=Symbol("addTarEntry"),zc=Symbol("stat"),Wc=Symbol("readdir"),vo=Symbol("onreaddir"),Co=Symbol("pipe"),Yy=Symbol("entry"),qc=Symbol("entryOpt"),Yc=Symbol("writeEntryClass"),Ky=Symbol("write"),Uc=Symbol("ondrain"),Ro=require("fs"),Vy=require("path"),HF=mo(),Gc=Ni(),Zc=HF(class extends PF{constructor(e){super(e),e=e||Object.create(null),this.opt=e,this.file=e.file||"",this.cwd=e.cwd||process.cwd(),this.maxReadSize=e.maxReadSize,this.preservePaths=!!e.preservePaths,this.strict=!!e.strict,this.noPax=!!e.noPax,this.prefix=Gc(e.prefix||""),this.linkCache=e.linkCache||new Map,this.statCache=e.statCache||new Map,this.readdirCache=e.readdirCache||new Map,this[Yc]=Kc,typeof e.onwarn=="function"&&this.on("warn",e.onwarn),this.portable=!!e.portable,this.zip=null,e.gzip?(typeof e.gzip!="object"&&(e.gzip={}),this.portable&&(e.gzip.portable=!0),this.zip=new IF.Gzip(e.gzip),this.zip.on("data",r=>super.write(r)),this.zip.on("end",r=>super.end()),this.zip.on("drain",r=>this[Uc]()),this.on("resume",r=>this.zip.resume())):this.on("drain",this[Uc]),this.noDirRecurse=!!e.noDirRecurse,this.follow=!!e.follow,this.noMtime=!!e.noMtime,this.mtime=e.mtime||null,this.filter=typeof e.filter=="function"?e.filter:r=>!0,this[Ft]=new $F,this[Ot]=0,this.jobs=+e.jobs||4,this[wo]=!1,this[_o]=!1}[Ky](e){return super.write(e)}add(e){return this.write(e),this}end(e){return e&&this.write(e),this[_o]=!0,this[Kr](),this}write(e){if(this[_o])throw new Error("write after end");return e instanceof NF?this[Wy](e):this[Ao](e),this.flowing}[Wy](e){let r=Gc(Vy.resolve(this.cwd,e.path));if(!this.filter(e.path,e))e.resume();else{let i=new xo(e.path,r,!1);i.entry=new jF(e,this[qc](i)),i.entry.on("end",n=>this[Hc](i)),this[Ot]+=1,this[Ft].push(i)}this[Kr]()}[Ao](e){let r=Gc(Vy.resolve(this.cwd,e));this[Ft].push(new xo(e,r)),this[Kr]()}[zc](e){e.pending=!0,this[Ot]+=1;let r=this.follow?"stat":"lstat";Ro[r](e.absolute,(i,n)=>{e.pending=!1,this[Ot]-=1,i?this.emit("error",i):this[So](e,n)})}[So](e,r){this.statCache.set(e.absolute,r),e.stat=r,this.filter(e.path,r)||(e.ignore=!0),this[Kr]()}[Wc](e){e.pending=!0,this[Ot]+=1,Ro.readdir(e.absolute,(r,i)=>{if(e.pending=!1,this[Ot]-=1,r)return this.emit("error",r);this[vo](e,i)})}[vo](e,r){this.readdirCache.set(e.absolute,r),e.readdir=r,this[Kr]()}[Kr](){if(!this[wo]){this[wo]=!0;for(let e=this[Ft].head;e!==null&&this[Ot]<this.jobs;e=e.next)if(this[zy](e.value),e.value.ignore){let r=e.next;this[Ft].removeNode(e),e.next=r}this[wo]=!1,this[_o]&&!this[Ft].length&&this[Ot]===0&&(this.zip?this.zip.end(Gy):(super.write(Gy),super.end()))}}get[Hi](){return this[Ft]&&this[Ft].head&&this[Ft].head.value}[Hc](e){this[Ft].shift(),this[Ot]-=1,this[Kr]()}[zy](e){if(!e.pending){if(e.entry){e===this[Hi]&&!e.piped&&this[Co](e);return}if(e.stat||(this.statCache.has(e.absolute)?this[So](e,this.statCache.get(e.absolute)):this[zc](e)),!!e.stat&&!e.ignore&&!(!this.noDirRecurse&&e.stat.isDirectory()&&!e.readdir&&(this.readdirCache.has(e.absolute)?this[vo](e,this.readdirCache.get(e.absolute)):this[Wc](e),!e.readdir))){if(e.entry=this[Yy](e),!e.entry){e.ignore=!0;return}e===this[Hi]&&!e.piped&&this[Co](e)}}}[qc](e){return{onwarn:(r,i,n)=>this.warn(r,i,n),noPax:this.noPax,cwd:this.cwd,absolute:e.absolute,preservePaths:this.preservePaths,maxReadSize:this.maxReadSize,strict:this.strict,portable:this.portable,linkCache:this.linkCache,statCache:this.statCache,noMtime:this.noMtime,mtime:this.mtime,prefix:this.prefix}}[Yy](e){this[Ot]+=1;try{return new this[Yc](e.path,this[qc](e)).on("end",()=>this[Hc](e)).on("error",r=>this.emit("error",r))}catch(r){this.emit("error",r)}}[Uc](){this[Hi]&&this[Hi].entry&&this[Hi].entry.resume()}[Co](e){e.piped=!0,e.readdir&&e.readdir.forEach(n=>{let s=e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[Ao](o+n)});let r=e.entry,i=this.zip;i?r.on("data",n=>{i.write(n)||r.pause()}):r.on("data",n=>{super.write(n)||r.pause()})}pause(){return this.zip&&this.zip.pause(),super.pause()}}),Vc=class extends Zc{constructor(e){super(e),this[Yc]=MF}pause(){}resume(){}[zc](e){let r=this.follow?"statSync":"lstatSync";this[So](e,Ro[r](e.absolute))}[Wc](e,r){this[vo](e,Ro.readdirSync(e.absolute))}[Co](e){let r=e.entry,i=this.zip;e.readdir&&e.readdir.forEach(n=>{let s=e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[Ao](o+n)}),i?r.on("data",n=>{i.write(n)}):r.on("data",n=>{super[Ky](n)})}};Zc.Sync=Vc;Zy.exports=Zc});var Ki=$(In=>{"use strict";var qF=rc(),UF=require("events").EventEmitter,Ye=require("fs"),Qc=Ye.writev;if(!Qc){let t=process.binding("fs"),e=t.FSReqWrap||t.FSReqCallback;Qc=(r,i,n,s)=>{let o=(u,l)=>s(u,l,i),a=new e;a.oncomplete=o,t.writeBuffers(r,i,n,a)}}var Yi=Symbol("_autoClose"),pt=Symbol("_close"),Pn=Symbol("_ended"),fe=Symbol("_fd"),Jy=Symbol("_finished"),wr=Symbol("_flags"),Jc=Symbol("_flush"),eh=Symbol("_handleChunk"),th=Symbol("_makeBuf"),Bo=Symbol("_mode"),Oo=Symbol("_needDrain"),zi=Symbol("_onerror"),Vi=Symbol("_onopen"),Xc=Symbol("_onread"),Ui=Symbol("_onwrite"),Sr=Symbol("_open"),Jt=Symbol("_path"),Zr=Symbol("_pos"),kt=Symbol("_queue"),Gi=Symbol("_read"),Xy=Symbol("_readSize"),_r=Symbol("_reading"),ko=Symbol("_remain"),Qy=Symbol("_size"),To=Symbol("_write"),qi=Symbol("_writing"),Lo=Symbol("_defaultFlag"),Wi=Symbol("_errored"),Po=class extends qF{constructor(e,r){if(r=r||{},super(r),this.readable=!0,this.writable=!1,typeof e!="string")throw new TypeError("path must be a string");this[Wi]=!1,this[fe]=typeof r.fd=="number"?r.fd:null,this[Jt]=e,this[Xy]=r.readSize||16*1024*1024,this[_r]=!1,this[Qy]=typeof r.size=="number"?r.size:1/0,this[ko]=this[Qy],this[Yi]=typeof r.autoClose=="boolean"?r.autoClose:!0,typeof this[fe]=="number"?this[Gi]():this[Sr]()}get fd(){return this[fe]}get path(){return this[Jt]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[Sr](){Ye.open(this[Jt],"r",(e,r)=>this[Vi](e,r))}[Vi](e,r){e?this[zi](e):(this[fe]=r,this.emit("open",r),this[Gi]())}[th](){return Buffer.allocUnsafe(Math.min(this[Xy],this[ko]))}[Gi](){if(!this[_r]){this[_r]=!0;let e=this[th]();if(e.length===0)return process.nextTick(()=>this[Xc](null,0,e));Ye.read(this[fe],e,0,e.length,null,(r,i,n)=>this[Xc](r,i,n))}}[Xc](e,r,i){this[_r]=!1,e?this[zi](e):this[eh](r,i)&&this[Gi]()}[pt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ye.close(e,r=>r?this.emit("error",r):this.emit("close"))}}[zi](e){this[_r]=!0,this[pt](),this.emit("error",e)}[eh](e,r){let i=!1;return this[ko]-=e,e>0&&(i=super.write(e<r.length?r.slice(0,e):r)),(e===0||this[ko]<=0)&&(i=!1,this[pt](),super.end()),i}emit(e,r){switch(e){case"prefinish":case"finish":break;case"drain":typeof this[fe]=="number"&&this[Gi]();break;case"error":return this[Wi]?void 0:(this[Wi]=!0,super.emit(e,r));default:return super.emit(e,r)}}},rh=class extends Po{[Sr](){let e=!0;try{this[Vi](null,Ye.openSync(this[Jt],"r")),e=!1}finally{e&&this[pt]()}}[Gi](){let e=!0;try{if(!this[_r]){this[_r]=!0;do{let r=this[th](),i=r.length===0?0:Ye.readSync(this[fe],r,0,r.length,null);if(!this[eh](i,r))break}while(!0);this[_r]=!1}e=!1}finally{e&&this[pt]()}}[pt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ye.closeSync(e),this.emit("close")}}},Io=class extends UF{constructor(e,r){r=r||{},super(r),this.readable=!1,this.writable=!0,this[Wi]=!1,this[qi]=!1,this[Pn]=!1,this[Oo]=!1,this[kt]=[],this[Jt]=e,this[fe]=typeof r.fd=="number"?r.fd:null,this[Bo]=r.mode===void 0?438:r.mode,this[Zr]=typeof r.start=="number"?r.start:null,this[Yi]=typeof r.autoClose=="boolean"?r.autoClose:!0;let i=this[Zr]!==null?"r+":"w";this[Lo]=r.flags===void 0,this[wr]=this[Lo]?i:r.flags,this[fe]===null&&this[Sr]()}emit(e,r){if(e==="error"){if(this[Wi])return;this[Wi]=!0}return super.emit(e,r)}get fd(){return this[fe]}get path(){return this[Jt]}[zi](e){this[pt](),this[qi]=!0,this.emit("error",e)}[Sr](){Ye.open(this[Jt],this[wr],this[Bo],(e,r)=>this[Vi](e,r))}[Vi](e,r){this[Lo]&&this[wr]==="r+"&&e&&e.code==="ENOENT"?(this[wr]="w",this[Sr]()):e?this[zi](e):(this[fe]=r,this.emit("open",r),this[Jc]())}end(e,r){return e&&this.write(e,r),this[Pn]=!0,!this[qi]&&!this[kt].length&&typeof this[fe]=="number"&&this[Ui](null,0),this}write(e,r){return typeof e=="string"&&(e=Buffer.from(e,r)),this[Pn]?(this.emit("error",new Error("write() after end()")),!1):this[fe]===null||this[qi]||this[kt].length?(this[kt].push(e),this[Oo]=!0,!1):(this[qi]=!0,this[To](e),!0)}[To](e){Ye.write(this[fe],e,0,e.length,this[Zr],(r,i)=>this[Ui](r,i))}[Ui](e,r){e?this[zi](e):(this[Zr]!==null&&(this[Zr]+=r),this[kt].length?this[Jc]():(this[qi]=!1,this[Pn]&&!this[Jy]?(this[Jy]=!0,this[pt](),this.emit("finish")):this[Oo]&&(this[Oo]=!1,this.emit("drain"))))}[Jc](){if(this[kt].length===0)this[Pn]&&this[Ui](null,0);else if(this[kt].length===1)this[To](this[kt].pop());else{let e=this[kt];this[kt]=[],Qc(this[fe],e,this[Zr],(r,i)=>this[Ui](r,i))}}[pt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ye.close(e,r=>r?this.emit("error",r):this.emit("close"))}}},ih=class extends Io{[Sr](){let e;if(this[Lo]&&this[wr]==="r+")try{e=Ye.openSync(this[Jt],this[wr],this[Bo])}catch(r){if(r.code==="ENOENT")return this[wr]="w",this[Sr]();throw r}else e=Ye.openSync(this[Jt],this[wr],this[Bo]);this[Vi](null,e)}[pt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ye.closeSync(e),this.emit("close")}}[To](e){let r=!0;try{this[Ui](null,Ye.writeSync(this[fe],e,0,e.length,this[Zr])),r=!1}finally{if(r)try{this[pt]()}catch{}}}};In.ReadStream=Po;In.ReadStreamSync=rh;In.WriteStream=Io;In.WriteStreamSync=ih});var Uo=$((tI,aE)=>{"use strict";var GF=mo(),zF=ji(),WF=require("events"),YF=$c(),VF=1024*1024,KF=ho(),eE=po(),ZF=Ec(),{nextTick:JF}=require("process"),nh=Buffer.from([31,139]),st=Symbol("state"),Jr=Symbol("writeEntry"),Xt=Symbol("readEntry"),sh=Symbol("nextEntry"),tE=Symbol("processEntry"),ot=Symbol("extendedHeader"),Nn=Symbol("globalExtendedHeader"),Ar=Symbol("meta"),rE=Symbol("emitMeta"),me=Symbol("buffer"),Qt=Symbol("queue"),Xr=Symbol("ended"),iE=Symbol("emittedEnd"),Qr=Symbol("emit"),Ve=Symbol("unzip"),No=Symbol("consumeChunk"),Mo=Symbol("consumeChunkSub"),oh=Symbol("consumeBody"),nE=Symbol("consumeMeta"),sE=Symbol("consumeHeader"),jo=Symbol("consuming"),ah=Symbol("bufferConcat"),uh=Symbol("maybeEnd"),Mn=Symbol("writing"),vr=Symbol("aborted"),$o=Symbol("onDone"),ei=Symbol("sawValidEntry"),Ho=Symbol("sawNullBlock"),qo=Symbol("sawEOF"),oE=Symbol("closeStream"),XF=t=>!0;aE.exports=GF(class extends WF{constructor(e){e=e||{},super(e),this.file=e.file||"",this[ei]=null,this.on($o,r=>{(this[st]==="begin"||this[ei]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),e.ondone?this.on($o,e.ondone):this.on($o,r=>{this.emit("prefinish"),this.emit("finish"),this.emit("end")}),this.strict=!!e.strict,this.maxMetaEntrySize=e.maxMetaEntrySize||VF,this.filter=typeof e.filter=="function"?e.filter:XF,this.writable=!0,this.readable=!1,this[Qt]=new YF,this[me]=null,this[Xt]=null,this[Jr]=null,this[st]="begin",this[Ar]="",this[ot]=null,this[Nn]=null,this[Xr]=!1,this[Ve]=null,this[vr]=!1,this[Ho]=!1,this[qo]=!1,this.on("end",()=>this[oE]()),typeof e.onwarn=="function"&&this.on("warn",e.onwarn),typeof e.onentry=="function"&&this.on("entry",e.onentry)}[sE](e,r){this[ei]===null&&(this[ei]=!1);let i;try{i=new zF(e,r,this[ot],this[Nn])}catch(n){return this.warn("TAR_ENTRY_INVALID",n)}if(i.nullBlock)this[Ho]?(this[qo]=!0,this[st]==="begin"&&(this[st]="header"),this[Qr]("eof")):(this[Ho]=!0,this[Qr]("nullBlock"));else if(this[Ho]=!1,!i.cksumValid)this.warn("TAR_ENTRY_INVALID","checksum failure",{header:i});else if(!i.path)this.warn("TAR_ENTRY_INVALID","path is required",{header:i});else{let n=i.type;if(/^(Symbolic)?Link$/.test(n)&&!i.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath required",{header:i});else if(!/^(Symbolic)?Link$/.test(n)&&i.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath forbidden",{header:i});else{let s=this[Jr]=new KF(i,this[ot],this[Nn]);if(!this[ei])if(s.remain){let o=()=>{s.invalid||(this[ei]=!0)};s.on("end",o)}else this[ei]=!0;s.meta?s.size>this.maxMetaEntrySize?(s.ignore=!0,this[Qr]("ignoredEntry",s),this[st]="ignore",s.resume()):s.size>0&&(this[Ar]="",s.on("data",o=>this[Ar]+=o),this[st]="meta"):(this[ot]=null,s.ignore=s.ignore||!this.filter(s.path,s),s.ignore?(this[Qr]("ignoredEntry",s),this[st]=s.remain?"ignore":"header",s.resume()):(s.remain?this[st]="body":(this[st]="header",s.end()),this[Xt]?this[Qt].push(s):(this[Qt].push(s),this[sh]())))}}}[oE](){JF(()=>this.emit("close"))}[tE](e){let r=!0;return e?Array.isArray(e)?this.emit.apply(this,e):(this[Xt]=e,this.emit("entry",e),e.emittedEnd||(e.on("end",i=>this[sh]()),r=!1)):(this[Xt]=null,r=!1),r}[sh](){do;while(this[tE](this[Qt].shift()));if(!this[Qt].length){let e=this[Xt];!e||e.flowing||e.size===e.remain?this[Mn]||this.emit("drain"):e.once("drain",i=>this.emit("drain"))}}[oh](e,r){let i=this[Jr],n=i.blockRemain,s=n>=e.length&&r===0?e:e.slice(r,r+n);return i.write(s),i.blockRemain||(this[st]="header",this[Jr]=null,i.end()),s.length}[nE](e,r){let i=this[Jr],n=this[oh](e,r);return this[Jr]||this[rE](i),n}[Qr](e,r,i){!this[Qt].length&&!this[Xt]?this.emit(e,r,i):this[Qt].push([e,r,i])}[rE](e){switch(this[Qr]("meta",this[Ar]),e.type){case"ExtendedHeader":case"OldExtendedHeader":this[ot]=eE.parse(this[Ar],this[ot],!1);break;case"GlobalExtendedHeader":this[Nn]=eE.parse(this[Ar],this[Nn],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[ot]=this[ot]||Object.create(null),this[ot].path=this[Ar].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[ot]=this[ot]||Object.create(null),this[ot].linkpath=this[Ar].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+e.type)}}abort(e){this[vr]=!0,this.emit("abort",e),this.warn("TAR_ABORT",e,{recoverable:!1})}write(e){if(this[vr])return;if(this[Ve]===null&&e){if(this[me]&&(e=Buffer.concat([this[me],e]),this[me]=null),e.length<nh.length)return this[me]=e,!0;for(let i=0;this[Ve]===null&&i<nh.length;i++)e[i]!==nh[i]&&(this[Ve]=!1);if(this[Ve]===null){let i=this[Xr];this[Xr]=!1,this[Ve]=new ZF.Unzip,this[Ve].on("data",s=>this[No](s)),this[Ve].on("error",s=>this.abort(s)),this[Ve].on("end",s=>{this[Xr]=!0,this[No]()}),this[Mn]=!0;let n=this[Ve][i?"end":"write"](e);return this[Mn]=!1,n}}this[Mn]=!0,this[Ve]?this[Ve].write(e):this[No](e),this[Mn]=!1;let r=this[Qt].length?!1:this[Xt]?this[Xt].flowing:!0;return!r&&!this[Qt].length&&this[Xt].once("drain",i=>this.emit("drain")),r}[ah](e){e&&!this[vr]&&(this[me]=this[me]?Buffer.concat([this[me],e]):e)}[uh](){if(this[Xr]&&!this[iE]&&!this[vr]&&!this[jo]){this[iE]=!0;let e=this[Jr];if(e&&e.blockRemain){let r=this[me]?this[me].length:0;this.warn("TAR_BAD_ARCHIVE",`Truncated input (needed ${e.blockRemain} more bytes, only ${r} available)`,{entry:e}),this[me]&&e.write(this[me]),e.end()}this[Qr]($o)}}[No](e){if(this[jo])this[ah](e);else if(!e&&!this[me])this[uh]();else{if(this[jo]=!0,this[me]){this[ah](e);let r=this[me];this[me]=null,this[Mo](r)}else this[Mo](e);for(;this[me]&&this[me].length>=512&&!this[vr]&&!this[qo];){let r=this[me];this[me]=null,this[Mo](r)}this[jo]=!1}(!this[me]||this[Xr])&&this[uh]()}[Mo](e){let r=0,i=e.length;for(;r+512<=i&&!this[vr]&&!this[qo];)switch(this[st]){case"begin":case"header":this[sE](e,r),r+=512;break;case"ignore":case"body":r+=this[oh](e,r);break;case"meta":r+=this[nE](e,r);break;default:throw new Error("invalid state: "+this[st])}r<i&&(this[me]?this[me]=Buffer.concat([e.slice(r),this[me]]):this[me]=e.slice(r))}end(e){this[vr]||(this[Ve]?this[Ve].end(e):(this[Xr]=!0,this.write(e)))}})});var Go=$((rI,hE)=>{"use strict";var QF=Ti(),lE=Uo(),Zi=require("fs"),eO=Ki(),uE=require("path"),lh=$i();hE.exports=(t,e,r)=>{typeof t=="function"?(r=t,e=null,t={}):Array.isArray(t)&&(e=t,t={}),typeof e=="function"&&(r=e,e=null),e?e=Array.from(e):e=[];let i=QF(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return e.length&&rO(i,e),i.noResume||tO(i),i.file&&i.sync?iO(i):i.file?nO(i,r):cE(i)};var tO=t=>{let e=t.onentry;t.onentry=e?r=>{e(r),r.resume()}:r=>r.resume()},rO=(t,e)=>{let r=new Map(e.map(s=>[lh(s),!0])),i=t.filter,n=(s,o)=>{let a=o||uE.parse(s).root||".",u=s===a?!1:r.has(s)?r.get(s):n(uE.dirname(s),a);return r.set(s,u),u};t.filter=i?(s,o)=>i(s,o)&&n(lh(s)):s=>n(lh(s))},iO=t=>{let e=cE(t),r=t.file,i=!0,n;try{let s=Zi.statSync(r),o=t.maxReadSize||16*1024*1024;if(s.size<o)e.end(Zi.readFileSync(r));else{let a=0,u=Buffer.allocUnsafe(o);for(n=Zi.openSync(r,"r");a<s.size;){let l=Zi.readSync(n,u,0,o,a);a+=l,e.write(u.slice(0,l))}e.end()}i=!1}finally{if(i&&n)try{Zi.closeSync(n)}catch{}}},nO=(t,e)=>{let r=new lE(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("end",o),Zi.stat(n,(u,l)=>{if(u)a(u);else{let c=new eO.ReadStream(n,{readSize:i,size:l.size});c.on("error",a),c.pipe(r)}})});return e?s.then(e,e):s},cE=t=>new lE(t)});var yE=$((iI,gE)=>{"use strict";var sO=Ti(),zo=Fo(),fE=Ki(),pE=Go(),dE=require("path");gE.exports=(t,e,r)=>{if(typeof e=="function"&&(r=e),Array.isArray(t)&&(e=t,t={}),!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");e=Array.from(e);let i=sO(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return i.file&&i.sync?oO(i,e):i.file?aO(i,e,r):i.sync?uO(i,e):lO(i,e)};var oO=(t,e)=>{let r=new zo.Sync(t),i=new fE.WriteStreamSync(t.file,{mode:t.mode||438});r.pipe(i),mE(r,e)},aO=(t,e,r)=>{let i=new zo(t),n=new fE.WriteStream(t.file,{mode:t.mode||438});i.pipe(n);let s=new Promise((o,a)=>{n.on("error",a),n.on("close",o),i.on("error",a)});return ch(i,e),r?s.then(r,r):s},mE=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?pE({file:dE.resolve(t.cwd,r.slice(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},ch=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return pE({file:dE.resolve(t.cwd,r.slice(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>ch(t,e));t.add(r)}t.end()},uO=(t,e)=>{let r=new zo.Sync(t);return mE(r,e),r},lO=(t,e)=>{let r=new zo(t);return ch(r,e),r}});var hh=$((nI,AE)=>{"use strict";var cO=Ti(),EE=Fo(),et=require("fs"),DE=Ki(),bE=Go(),_E=require("path"),wE=ji();AE.exports=(t,e,r)=>{let i=cO(t);if(!i.file)throw new TypeError("file is required");if(i.gzip)throw new TypeError("cannot append to compressed archives");if(!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");return e=Array.from(e),i.sync?hO(i,e):pO(i,e,r)};var hO=(t,e)=>{let r=new EE.Sync(t),i=!0,n,s;try{try{n=et.openSync(t.file,"r+")}catch(u){if(u.code==="ENOENT")n=et.openSync(t.file,"w+");else throw u}let o=et.fstatSync(n),a=Buffer.alloc(512);e:for(s=0;s<o.size;s+=512){for(let c=0,f=0;c<512;c+=f){if(f=et.readSync(n,a,c,a.length-c,s+c),s===0&&a[0]===31&&a[1]===139)throw new Error("cannot append to compressed archives");if(!f)break e}let u=new wE(a);if(!u.cksumValid)break;let l=512*Math.ceil(u.size/512);if(s+l+512>o.size)break;s+=l,t.mtimeCache&&t.mtimeCache.set(u.path,u.mtime)}i=!1,fO(t,r,s,n,e)}finally{if(i)try{et.closeSync(n)}catch{}}},fO=(t,e,r,i,n)=>{let s=new DE.WriteStreamSync(t.file,{fd:i,start:r});e.pipe(s),dO(e,n)},pO=(t,e,r)=>{e=Array.from(e);let i=new EE(t),n=(o,a,u)=>{let l=(g,y)=>{g?et.close(o,E=>u(g)):u(null,y)},c=0;if(a===0)return l(null,0);let f=0,h=Buffer.alloc(512),p=(g,y)=>{if(g)return l(g);if(f+=y,f<512&&y)return et.read(o,h,f,h.length-f,c+f,p);if(c===0&&h[0]===31&&h[1]===139)return l(new Error("cannot append to compressed archives"));if(f<512)return l(null,c);let E=new wE(h);if(!E.cksumValid)return l(null,c);let v=512*Math.ceil(E.size/512);if(c+v+512>a||(c+=v+512,c>=a))return l(null,c);t.mtimeCache&&t.mtimeCache.set(E.path,E.mtime),f=0,et.read(o,h,0,512,c,p)};et.read(o,h,0,512,c,p)},s=new Promise((o,a)=>{i.on("error",a);let u="r+",l=(c,f)=>{if(c&&c.code==="ENOENT"&&u==="r+")return u="w+",et.open(t.file,u,l);if(c)return a(c);et.fstat(f,(h,p)=>{if(h)return et.close(f,()=>a(h));n(f,p.size,(g,y)=>{if(g)return a(g);let E=new DE.WriteStream(t.file,{fd:f,start:y});i.pipe(E),E.on("error",a),E.on("close",o),SE(i,e)})})};et.open(t.file,u,l)});return r?s.then(r,r):s},dO=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?bE({file:_E.resolve(t.cwd,r.slice(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},SE=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return bE({file:_E.resolve(t.cwd,r.slice(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>SE(t,e));t.add(r)}t.end()}});var CE=$((sI,vE)=>{"use strict";var mO=Ti(),gO=hh();vE.exports=(t,e,r)=>{let i=mO(t);if(!i.file)throw new TypeError("file is required");if(i.gzip)throw new TypeError("cannot append to compressed archives");if(!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");return e=Array.from(e),yO(i),gO(i,e,r)};var yO=t=>{let e=t.filter;t.mtimeCache||(t.mtimeCache=new Map),t.filter=e?(r,i)=>e(r,i)&&!(t.mtimeCache.get(r)>i.mtime):(r,i)=>!(t.mtimeCache.get(r)>i.mtime)}});var FE=$((oI,RE)=>{var{promisify:xE}=require("util"),Cr=require("fs"),EO=t=>{if(!t)t={mode:511,fs:Cr};else if(typeof t=="object")t={mode:511,fs:Cr,...t};else if(typeof t=="number")t={mode:t,fs:Cr};else if(typeof t=="string")t={mode:parseInt(t,8),fs:Cr};else throw new TypeError("invalid options argument");return t.mkdir=t.mkdir||t.fs.mkdir||Cr.mkdir,t.mkdirAsync=xE(t.mkdir),t.stat=t.stat||t.fs.stat||Cr.stat,t.statAsync=xE(t.stat),t.statSync=t.statSync||t.fs.statSync||Cr.statSync,t.mkdirSync=t.mkdirSync||t.fs.mkdirSync||Cr.mkdirSync,t};RE.exports=EO});var kE=$((aI,OE)=>{var DO=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:bO,parse:_O}=require("path"),wO=t=>{if(/\0/.test(t))throw Object.assign(new TypeError("path must be a string without null bytes"),{path:t,code:"ERR_INVALID_ARG_VALUE"});if(t=bO(t),DO==="win32"){let e=/[*|"<>?:]/,{root:r}=_O(t);if(e.test(t.substr(r.length)))throw Object.assign(new Error("Illegal characters in path."),{path:t,code:"EINVAL"})}return t};OE.exports=wO});var IE=$((uI,PE)=>{var{dirname:TE}=require("path"),LE=(t,e,r=void 0)=>r===e?Promise.resolve():t.statAsync(e).then(i=>i.isDirectory()?r:void 0,i=>i.code==="ENOENT"?LE(t,TE(e),e):void 0),BE=(t,e,r=void 0)=>{if(r!==e)try{return t.statSync(e).isDirectory()?r:void 0}catch(i){return i.code==="ENOENT"?BE(t,TE(e),e):void 0}};PE.exports={findMade:LE,findMadeSync:BE}});var dh=$((lI,ME)=>{var{dirname:NE}=require("path"),fh=(t,e,r)=>{e.recursive=!1;let i=NE(t);return i===t?e.mkdirAsync(t,e).catch(n=>{if(n.code!=="EISDIR")throw n}):e.mkdirAsync(t,e).then(()=>r||t,n=>{if(n.code==="ENOENT")return fh(i,e).then(s=>fh(t,e,s));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;return e.statAsync(t).then(s=>{if(s.isDirectory())return r;throw n},()=>{throw n})})},ph=(t,e,r)=>{let i=NE(t);if(e.recursive=!1,i===t)try{return e.mkdirSync(t,e)}catch(n){if(n.code!=="EISDIR")throw n;return}try{return e.mkdirSync(t,e),r||t}catch(n){if(n.code==="ENOENT")return ph(t,e,ph(i,e,r));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;try{if(!e.statSync(t).isDirectory())throw n}catch{throw n}}};ME.exports={mkdirpManual:fh,mkdirpManualSync:ph}});var HE=$((cI,$E)=>{var{dirname:jE}=require("path"),{findMade:SO,findMadeSync:AO}=IE(),{mkdirpManual:vO,mkdirpManualSync:CO}=dh(),xO=(t,e)=>(e.recursive=!0,jE(t)===t?e.mkdirAsync(t,e):SO(e,t).then(i=>e.mkdirAsync(t,e).then(()=>i).catch(n=>{if(n.code==="ENOENT")return vO(t,e);throw n}))),RO=(t,e)=>{if(e.recursive=!0,jE(t)===t)return e.mkdirSync(t,e);let i=AO(e,t);try{return e.mkdirSync(t,e),i}catch(n){if(n.code==="ENOENT")return CO(t,e);throw n}};$E.exports={mkdirpNative:xO,mkdirpNativeSync:RO}});var zE=$((hI,GE)=>{var qE=require("fs"),FO=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version,mh=FO.replace(/^v/,"").split("."),UE=+mh[0]>10||+mh[0]==10&&+mh[1]>=12,OO=UE?t=>t.mkdir===qE.mkdir:()=>!1,kO=UE?t=>t.mkdirSync===qE.mkdirSync:()=>!1;GE.exports={useNative:OO,useNativeSync:kO}});var JE=$((fI,ZE)=>{var Ji=FE(),Xi=kE(),{mkdirpNative:WE,mkdirpNativeSync:YE}=HE(),{mkdirpManual:VE,mkdirpManualSync:KE}=dh(),{useNative:TO,useNativeSync:LO}=zE(),Qi=(t,e)=>(t=Xi(t),e=Ji(e),TO(e)?WE(t,e):VE(t,e)),BO=(t,e)=>(t=Xi(t),e=Ji(e),LO(e)?YE(t,e):KE(t,e));Qi.sync=BO;Qi.native=(t,e)=>WE(Xi(t),Ji(e));Qi.manual=(t,e)=>VE(Xi(t),Ji(e));Qi.nativeSync=(t,e)=>YE(Xi(t),Ji(e));Qi.manualSync=(t,e)=>KE(Xi(t),Ji(e));ZE.exports=Qi});var nD=$((pI,iD)=>{"use strict";var at=require("fs"),ti=require("path"),PO=at.lchown?"lchown":"chown",IO=at.lchownSync?"lchownSync":"chownSync",QE=at.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),XE=(t,e,r)=>{try{return at[IO](t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},NO=(t,e,r)=>{try{return at.chownSync(t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},MO=QE?(t,e,r,i)=>n=>{!n||n.code!=="EISDIR"?i(n):at.chown(t,e,r,i)}:(t,e,r,i)=>i,gh=QE?(t,e,r)=>{try{return XE(t,e,r)}catch(i){if(i.code!=="EISDIR")throw i;NO(t,e,r)}}:(t,e,r)=>XE(t,e,r),jO=process.version,eD=(t,e,r)=>at.readdir(t,e,r),$O=(t,e)=>at.readdirSync(t,e);/^v4\./.test(jO)&&(eD=(t,e,r)=>at.readdir(t,r));var Wo=(t,e,r,i)=>{at[PO](t,e,r,MO(t,e,r,n=>{i(n&&n.code!=="ENOENT"?n:null)}))},tD=(t,e,r,i,n)=>{if(typeof e=="string")return at.lstat(ti.resolve(t,e),(s,o)=>{if(s)return n(s.code!=="ENOENT"?s:null);o.name=e,tD(t,o,r,i,n)});if(e.isDirectory())yh(ti.resolve(t,e.name),r,i,s=>{if(s)return n(s);let o=ti.resolve(t,e.name);Wo(o,r,i,n)});else{let s=ti.resolve(t,e.name);Wo(s,r,i,n)}},yh=(t,e,r,i)=>{eD(t,{withFileTypes:!0},(n,s)=>{if(n){if(n.code==="ENOENT")return i();if(n.code!=="ENOTDIR"&&n.code!=="ENOTSUP")return i(n)}if(n||!s.length)return Wo(t,e,r,i);let o=s.length,a=null,u=l=>{if(!a){if(l)return i(a=l);if(--o===0)return Wo(t,e,r,i)}};s.forEach(l=>tD(t,l,e,r,u))})},HO=(t,e,r,i)=>{if(typeof e=="string")try{let n=at.lstatSync(ti.resolve(t,e));n.name=e,e=n}catch(n){if(n.code==="ENOENT")return;throw n}e.isDirectory()&&rD(ti.resolve(t,e.name),r,i),gh(ti.resolve(t,e.name),r,i)},rD=(t,e,r)=>{let i;try{i=$O(t,{withFileTypes:!0})}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR"||n.code==="ENOTSUP")return gh(t,e,r);throw n}return i&&i.length&&i.forEach(n=>HO(t,n,e,r)),gh(t,e,r)};iD.exports=yh;yh.sync=rD});var uD=$((dI,Eh)=>{"use strict";var sD=JE(),ut=require("fs"),Yo=require("path"),oD=nD(),dt=Ni(),Vo=class extends Error{constructor(e,r){super("Cannot extract through symbolic link"),this.path=r,this.symlink=e}get name(){return"SylinkError"}},Ko=class extends Error{constructor(e,r){super(r+": Cannot cd into '"+e+"'"),this.path=e,this.code=r}get name(){return"CwdError"}},Zo=(t,e)=>t.get(dt(e)),jn=(t,e,r)=>t.set(dt(e),r),qO=(t,e)=>{ut.stat(t,(r,i)=>{(r||!i.isDirectory())&&(r=new Ko(t,r&&r.code||"ENOTDIR")),e(r)})};Eh.exports=(t,e,r)=>{t=dt(t);let i=e.umask,n=e.mode|448,s=(n&i)!==0,o=e.uid,a=e.gid,u=typeof o=="number"&&typeof a=="number"&&(o!==e.processUid||a!==e.processGid),l=e.preserve,c=e.unlink,f=e.cache,h=dt(e.cwd),p=(E,v)=>{E?r(E):(jn(f,t,!0),v&&u?oD(v,o,a,F=>p(F)):s?ut.chmod(t,n,r):r())};if(f&&Zo(f,t)===!0)return p();if(t===h)return qO(t,p);if(l)return sD(t,{mode:n}).then(E=>p(null,E),p);let y=dt(Yo.relative(h,t)).split("/");Jo(h,y,n,f,c,h,null,p)};var Jo=(t,e,r,i,n,s,o,a)=>{if(!e.length)return a(null,o);let u=e.shift(),l=dt(Yo.resolve(t+"/"+u));if(Zo(i,l))return Jo(l,e,r,i,n,s,o,a);ut.mkdir(l,r,aD(l,e,r,i,n,s,o,a))},aD=(t,e,r,i,n,s,o,a)=>u=>{u?ut.lstat(t,(l,c)=>{if(l)l.path=l.path&&dt(l.path),a(l);else if(c.isDirectory())Jo(t,e,r,i,n,s,o,a);else if(n)ut.unlink(t,f=>{if(f)return a(f);ut.mkdir(t,r,aD(t,e,r,i,n,s,o,a))});else{if(c.isSymbolicLink())return a(new Vo(t,t+"/"+e.join("/")));a(u)}}):(o=o||t,Jo(t,e,r,i,n,s,o,a))},UO=t=>{let e=!1,r="ENOTDIR";try{e=ut.statSync(t).isDirectory()}catch(i){r=i.code}finally{if(!e)throw new Ko(t,r)}};Eh.exports.sync=(t,e)=>{t=dt(t);let r=e.umask,i=e.mode|448,n=(i&r)!==0,s=e.uid,o=e.gid,a=typeof s=="number"&&typeof o=="number"&&(s!==e.processUid||o!==e.processGid),u=e.preserve,l=e.unlink,c=e.cache,f=dt(e.cwd),h=E=>{jn(c,t,!0),E&&a&&oD.sync(E,s,o),n&&ut.chmodSync(t,i)};if(c&&Zo(c,t)===!0)return h();if(t===f)return UO(f),h();if(u)return h(sD.sync(t,i));let g=dt(Yo.relative(f,t)).split("/"),y=null;for(let E=g.shift(),v=f;E&&(v+="/"+E);E=g.shift())if(v=dt(Yo.resolve(v)),!Zo(c,v))try{ut.mkdirSync(v,i),y=y||v,jn(c,v,!0)}catch{let O=ut.lstatSync(v);if(O.isDirectory()){jn(c,v,!0);continue}else if(l){ut.unlinkSync(v),ut.mkdirSync(v,i),y=y||v,jn(c,v,!0);continue}else if(O.isSymbolicLink())return new Vo(v,v+"/"+g.join("/"))}return h(y)}});var bh=$((mI,lD)=>{var Dh=Object.create(null),{hasOwnProperty:GO}=Object.prototype;lD.exports=t=>(GO.call(Dh,t)||(Dh[t]=t.normalize("NFKD")),Dh[t])});var pD=$((gI,fD)=>{var cD=require("assert"),zO=bh(),WO=$i(),{join:hD}=require("path"),YO=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,VO=YO==="win32";fD.exports=()=>{let t=new Map,e=new Map,r=l=>l.split("/").slice(0,-1).reduce((f,h)=>(f.length&&(h=hD(f[f.length-1],h)),f.push(h||"/"),f),[]),i=new Set,n=l=>{let c=e.get(l);if(!c)throw new Error("function does not have any path reservations");return{paths:c.paths.map(f=>t.get(f)),dirs:[...c.dirs].map(f=>t.get(f))}},s=l=>{let{paths:c,dirs:f}=n(l);return c.every(h=>h[0]===l)&&f.every(h=>h[0]instanceof Set&&h[0].has(l))},o=l=>i.has(l)||!s(l)?!1:(i.add(l),l(()=>a(l)),!0),a=l=>{if(!i.has(l))return!1;let{paths:c,dirs:f}=e.get(l),h=new Set;return c.forEach(p=>{let g=t.get(p);cD.equal(g[0],l),g.length===1?t.delete(p):(g.shift(),typeof g[0]=="function"?h.add(g[0]):g[0].forEach(y=>h.add(y)))}),f.forEach(p=>{let g=t.get(p);cD(g[0]instanceof Set),g[0].size===1&&g.length===1?t.delete(p):g[0].size===1?(g.shift(),h.add(g[0])):g[0].delete(l)}),i.delete(l),h.forEach(p=>o(p)),!0};return{check:s,reserve:(l,c)=>{l=VO?["win32 parallelization disabled"]:l.map(h=>zO(WO(hD(h))).toLowerCase());let f=new Set(l.map(h=>r(h)).reduce((h,p)=>h.concat(p)));return e.set(c,{dirs:f,paths:l}),l.forEach(h=>{let p=t.get(h);p?p.push(c):t.set(h,[c])}),f.forEach(h=>{let p=t.get(h);p?p[p.length-1]instanceof Set?p[p.length-1].add(c):p.push(new Set([c])):t.set(h,[new Set([c])])}),o(c)}}}});var gD=$((yI,mD)=>{var KO=process.env.__FAKE_PLATFORM__||process.platform,ZO=KO==="win32",JO=global.__FAKE_TESTING_FS__||require("fs"),{O_CREAT:XO,O_TRUNC:QO,O_WRONLY:ek,UV_FS_O_FILEMAP:dD=0}=JO.constants,tk=ZO&&!!dD,rk=512*1024,ik=dD|QO|XO|ek;mD.exports=tk?t=>t<rk?ik:"w":()=>"w"});var Fh=$((EI,OD)=>{"use strict";var nk=require("assert"),sk=Uo(),ue=require("fs"),ok=Ki(),er=require("path"),xD=uD(),yD=Rc(),ak=pD(),uk=Fc(),tt=Ni(),lk=$i(),ck=bh(),ED=Symbol("onEntry"),Sh=Symbol("checkFs"),DD=Symbol("checkFs2"),ea=Symbol("pruneCache"),Ah=Symbol("isReusable"),lt=Symbol("makeFs"),vh=Symbol("file"),Ch=Symbol("directory"),ta=Symbol("link"),bD=Symbol("symlink"),_D=Symbol("hardlink"),wD=Symbol("unsupported"),SD=Symbol("checkPath"),xr=Symbol("mkdir"),Me=Symbol("onError"),Xo=Symbol("pending"),AD=Symbol("pend"),en=Symbol("unpend"),_h=Symbol("ended"),wh=Symbol("maybeClose"),xh=Symbol("skip"),$n=Symbol("doChown"),Hn=Symbol("uid"),qn=Symbol("gid"),Un=Symbol("checkedCwd"),RD=require("crypto"),FD=gD(),hk=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,Gn=hk==="win32",fk=(t,e)=>{if(!Gn)return ue.unlink(t,e);let r=t+".DELETE."+RD.randomBytes(16).toString("hex");ue.rename(t,r,i=>{if(i)return e(i);ue.unlink(r,e)})},pk=t=>{if(!Gn)return ue.unlinkSync(t);let e=t+".DELETE."+RD.randomBytes(16).toString("hex");ue.renameSync(t,e),ue.unlinkSync(e)},vD=(t,e,r)=>t===t>>>0?t:e===e>>>0?e:r,CD=t=>ck(lk(tt(t))).toLowerCase(),dk=(t,e)=>{e=CD(e);for(let r of t.keys()){let i=CD(r);(i===e||i.indexOf(e+"/")===0)&&t.delete(r)}},mk=t=>{for(let e of t.keys())t.delete(e)},zn=class extends sk{constructor(e){if(e||(e={}),e.ondone=r=>{this[_h]=!0,this[wh]()},super(e),this[Un]=!1,this.reservations=ak(),this.transform=typeof e.transform=="function"?e.transform:null,this.writable=!0,this.readable=!1,this[Xo]=0,this[_h]=!1,this.dirCache=e.dirCache||new Map,typeof e.uid=="number"||typeof e.gid=="number"){if(typeof e.uid!="number"||typeof e.gid!="number")throw new TypeError("cannot set owner without number uid and gid");if(e.preserveOwner)throw new TypeError("cannot preserve owner in archive and also set owner explicitly");this.uid=e.uid,this.gid=e.gid,this.setOwner=!0}else this.uid=null,this.gid=null,this.setOwner=!1;e.preserveOwner===void 0&&typeof e.uid!="number"?this.preserveOwner=process.getuid&&process.getuid()===0:this.preserveOwner=!!e.preserveOwner,this.processUid=(this.preserveOwner||this.setOwner)&&process.getuid?process.getuid():null,this.processGid=(this.preserveOwner||this.setOwner)&&process.getgid?process.getgid():null,this.forceChown=e.forceChown===!0,this.win32=!!e.win32||Gn,this.newer=!!e.newer,this.keep=!!e.keep,this.noMtime=!!e.noMtime,this.preservePaths=!!e.preservePaths,this.unlink=!!e.unlink,this.cwd=tt(er.resolve(e.cwd||process.cwd())),this.strip=+e.strip||0,this.processUmask=e.noChmod?0:process.umask(),this.umask=typeof e.umask=="number"?e.umask:this.processUmask,this.dmode=e.dmode||511&~this.umask,this.fmode=e.fmode||438&~this.umask,this.on("entry",r=>this[ED](r))}warn(e,r,i={}){return(e==="TAR_BAD_ARCHIVE"||e==="TAR_ABORT")&&(i.recoverable=!1),super.warn(e,r,i)}[wh](){this[_h]&&this[Xo]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"))}[SD](e){if(this.strip){let r=tt(e.path).split("/");if(r.length<this.strip)return!1;if(e.path=r.slice(this.strip).join("/"),e.type==="Link"){let i=tt(e.linkpath).split("/");if(i.length>=this.strip)e.linkpath=i.slice(this.strip).join("/");else return!1}}if(!this.preservePaths){let r=tt(e.path),i=r.split("/");if(i.includes("..")||Gn&&/^[a-z]:\.\.$/i.test(i[0]))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:e,path:r}),!1;let[n,s]=uk(r);n&&(e.path=s,this.warn("TAR_ENTRY_INFO",`stripping ${n} from absolute path`,{entry:e,path:r}))}if(er.isAbsolute(e.path)?e.absolute=tt(er.resolve(e.path)):e.absolute=tt(er.resolve(this.cwd,e.path)),!this.preservePaths&&e.absolute.indexOf(this.cwd+"/")!==0&&e.absolute!==this.cwd)return this.warn("TAR_ENTRY_ERROR","path escaped extraction target",{entry:e,path:tt(e.path),resolvedPath:e.absolute,cwd:this.cwd}),!1;if(e.absolute===this.cwd&&e.type!=="Directory"&&e.type!=="GNUDumpDir")return!1;if(this.win32){let{root:r}=er.win32.parse(e.absolute);e.absolute=r+yD.encode(e.absolute.slice(r.length));let{root:i}=er.win32.parse(e.path);e.path=i+yD.encode(e.path.slice(i.length))}return!0}[ED](e){if(!this[SD](e))return e.resume();switch(nk.equal(typeof e.absolute,"string"),e.type){case"Directory":case"GNUDumpDir":e.mode&&(e.mode=e.mode|448);case"File":case"OldFile":case"ContiguousFile":case"Link":case"SymbolicLink":return this[Sh](e);case"CharacterDevice":case"BlockDevice":case"FIFO":default:return this[wD](e)}}[Me](e,r){e.name==="CwdError"?this.emit("error",e):(this.warn("TAR_ENTRY_ERROR",e,{entry:r}),this[en](),r.resume())}[xr](e,r,i){xD(tt(e),{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:r,noChmod:this.noChmod},i)}[$n](e){return this.forceChown||this.preserveOwner&&(typeof e.uid=="number"&&e.uid!==this.processUid||typeof e.gid=="number"&&e.gid!==this.processGid)||typeof this.uid=="number"&&this.uid!==this.processUid||typeof this.gid=="number"&&this.gid!==this.processGid}[Hn](e){return vD(this.uid,e.uid,this.processUid)}[qn](e){return vD(this.gid,e.gid,this.processGid)}[vh](e,r){let i=e.mode&4095||this.fmode,n=new ok.WriteStream(e.absolute,{flags:FD(e.size),mode:i,autoClose:!1});n.on("error",u=>{n.fd&&ue.close(n.fd,()=>{}),n.write=()=>!0,this[Me](u,e),r()});let s=1,o=u=>{if(u){n.fd&&ue.close(n.fd,()=>{}),this[Me](u,e),r();return}--s===0&&ue.close(n.fd,l=>{l?this[Me](l,e):this[en](),r()})};n.on("finish",u=>{let l=e.absolute,c=n.fd;if(e.mtime&&!this.noMtime){s++;let f=e.atime||new Date,h=e.mtime;ue.futimes(c,f,h,p=>p?ue.utimes(l,f,h,g=>o(g&&p)):o())}if(this[$n](e)){s++;let f=this[Hn](e),h=this[qn](e);ue.fchown(c,f,h,p=>p?ue.chown(l,f,h,g=>o(g&&p)):o())}o()});let a=this.transform&&this.transform(e)||e;a!==e&&(a.on("error",u=>{this[Me](u,e),r()}),e.pipe(a)),a.pipe(n)}[Ch](e,r){let i=e.mode&4095||this.dmode;this[xr](e.absolute,i,n=>{if(n){this[Me](n,e),r();return}let s=1,o=a=>{--s===0&&(r(),this[en](),e.resume())};e.mtime&&!this.noMtime&&(s++,ue.utimes(e.absolute,e.atime||new Date,e.mtime,o)),this[$n](e)&&(s++,ue.chown(e.absolute,this[Hn](e),this[qn](e),o)),o()})}[wD](e){e.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${e.type}`,{entry:e}),e.resume()}[bD](e,r){this[ta](e,e.linkpath,"symlink",r)}[_D](e,r){let i=tt(er.resolve(this.cwd,e.linkpath));this[ta](e,i,"link",r)}[AD](){this[Xo]++}[en](){this[Xo]--,this[wh]()}[xh](e){this[en](),e.resume()}[Ah](e,r){return e.type==="File"&&!this.unlink&&r.isFile()&&r.nlink<=1&&!Gn}[Sh](e){this[AD]();let r=[e.path];e.linkpath&&r.push(e.linkpath),this.reservations.reserve(r,i=>this[DD](e,i))}[ea](e){e.type==="SymbolicLink"?mk(this.dirCache):e.type!=="Directory"&&dk(this.dirCache,e.absolute)}[DD](e,r){this[ea](e);let i=a=>{this[ea](e),r(a)},n=()=>{this[xr](this.cwd,this.dmode,a=>{if(a){this[Me](a,e),i();return}this[Un]=!0,s()})},s=()=>{if(e.absolute!==this.cwd){let a=tt(er.dirname(e.absolute));if(a!==this.cwd)return this[xr](a,this.dmode,u=>{if(u){this[Me](u,e),i();return}o()})}o()},o=()=>{ue.lstat(e.absolute,(a,u)=>{if(u&&(this.keep||this.newer&&u.mtime>e.mtime)){this[xh](e),i();return}if(a||this[Ah](e,u))return this[lt](null,e,i);if(u.isDirectory()){if(e.type==="Directory"){let l=!this.noChmod&&e.mode&&(u.mode&4095)!==e.mode,c=f=>this[lt](f,e,i);return l?ue.chmod(e.absolute,e.mode,c):c()}if(e.absolute!==this.cwd)return ue.rmdir(e.absolute,l=>this[lt](l,e,i))}if(e.absolute===this.cwd)return this[lt](null,e,i);fk(e.absolute,l=>this[lt](l,e,i))})};this[Un]?s():n()}[lt](e,r,i){if(e){this[Me](e,r),i();return}switch(r.type){case"File":case"OldFile":case"ContiguousFile":return this[vh](r,i);case"Link":return this[_D](r,i);case"SymbolicLink":return this[bD](r,i);case"Directory":case"GNUDumpDir":return this[Ch](r,i)}}[ta](e,r,i,n){ue[i](r,e.absolute,s=>{s?this[Me](s,e):(this[en](),e.resume()),n()})}},Qo=t=>{try{return[null,t()]}catch(e){return[e,null]}},Rh=class extends zn{[lt](e,r){return super[lt](e,r,()=>{})}[Sh](e){if(this[ea](e),!this[Un]){let s=this[xr](this.cwd,this.dmode);if(s)return this[Me](s,e);this[Un]=!0}if(e.absolute!==this.cwd){let s=tt(er.dirname(e.absolute));if(s!==this.cwd){let o=this[xr](s,this.dmode);if(o)return this[Me](o,e)}}let[r,i]=Qo(()=>ue.lstatSync(e.absolute));if(i&&(this.keep||this.newer&&i.mtime>e.mtime))return this[xh](e);if(r||this[Ah](e,i))return this[lt](null,e);if(i.isDirectory()){if(e.type==="Directory"){let o=!this.noChmod&&e.mode&&(i.mode&4095)!==e.mode,[a]=o?Qo(()=>{ue.chmodSync(e.absolute,e.mode)}):[];return this[lt](a,e)}let[s]=Qo(()=>ue.rmdirSync(e.absolute));this[lt](s,e)}let[n]=e.absolute===this.cwd?[]:Qo(()=>pk(e.absolute));this[lt](n,e)}[vh](e,r){let i=e.mode&4095||this.fmode,n=a=>{let u;try{ue.closeSync(s)}catch(l){u=l}(a||u)&&this[Me](a||u,e),r()},s;try{s=ue.openSync(e.absolute,FD(e.size),i)}catch(a){return n(a)}let o=this.transform&&this.transform(e)||e;o!==e&&(o.on("error",a=>this[Me](a,e)),e.pipe(o)),o.on("data",a=>{try{ue.writeSync(s,a,0,a.length)}catch(u){n(u)}}),o.on("end",a=>{let u=null;if(e.mtime&&!this.noMtime){let l=e.atime||new Date,c=e.mtime;try{ue.futimesSync(s,l,c)}catch(f){try{ue.utimesSync(e.absolute,l,c)}catch{u=f}}}if(this[$n](e)){let l=this[Hn](e),c=this[qn](e);try{ue.fchownSync(s,l,c)}catch(f){try{ue.chownSync(e.absolute,l,c)}catch{u=u||f}}}n(u)})}[Ch](e,r){let i=e.mode&4095||this.dmode,n=this[xr](e.absolute,i);if(n){this[Me](n,e),r();return}if(e.mtime&&!this.noMtime)try{ue.utimesSync(e.absolute,e.atime||new Date,e.mtime)}catch{}if(this[$n](e))try{ue.chownSync(e.absolute,this[Hn](e),this[qn](e))}catch{}r(),e.resume()}[xr](e,r){try{return xD.sync(tt(e),{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:r})}catch(i){return i}}[ta](e,r,i,n){try{ue[i+"Sync"](r,e.absolute),n(),e.resume()}catch(s){return this[Me](s,e)}}};zn.Sync=Rh;OD.exports=zn});var PD=$((DI,BD)=>{"use strict";var gk=Ti(),ra=Fh(),TD=require("fs"),LD=Ki(),kD=require("path"),Oh=$i();BD.exports=(t,e,r)=>{typeof t=="function"?(r=t,e=null,t={}):Array.isArray(t)&&(e=t,t={}),typeof e=="function"&&(r=e,e=null),e?e=Array.from(e):e=[];let i=gk(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return e.length&&yk(i,e),i.file&&i.sync?Ek(i):i.file?Dk(i,r):i.sync?bk(i):_k(i)};var yk=(t,e)=>{let r=new Map(e.map(s=>[Oh(s),!0])),i=t.filter,n=(s,o)=>{let a=o||kD.parse(s).root||".",u=s===a?!1:r.has(s)?r.get(s):n(kD.dirname(s),a);return r.set(s,u),u};t.filter=i?(s,o)=>i(s,o)&&n(Oh(s)):s=>n(Oh(s))},Ek=t=>{let e=new ra.Sync(t),r=t.file,i=TD.statSync(r),n=t.maxReadSize||16*1024*1024;new LD.ReadStreamSync(r,{readSize:n,size:i.size}).pipe(e)},Dk=(t,e)=>{let r=new ra(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("close",o),TD.stat(n,(u,l)=>{if(u)a(u);else{let c=new LD.ReadStream(n,{readSize:i,size:l.size});c.on("error",a),c.pipe(r)}})});return e?s.then(e,e):s},bk=t=>new ra.Sync(t),_k=t=>new ra(t)});var ID=$(Ce=>{"use strict";Ce.c=Ce.create=yE();Ce.r=Ce.replace=hh();Ce.t=Ce.list=Go();Ce.u=Ce.update=CE();Ce.x=Ce.extract=PD();Ce.Pack=Fo();Ce.Unpack=Fh();Ce.Parse=Uo();Ce.ReadEntry=ho();Ce.WriteEntry=jc();Ce.Header=ji();Ce.Pax=po();Ce.types=_c()});var qD=$((AI,HD)=>{function ct(t,e){typeof e=="boolean"&&(e={forever:e}),this._originalTimeouts=JSON.parse(JSON.stringify(t)),this._timeouts=t,this._options=e||{},this._maxRetryTime=e&&e.maxRetryTime||1/0,this._fn=null,this._errors=[],this._attempts=1,this._operationTimeout=null,this._operationTimeoutCb=null,this._timeout=null,this._operationStart=null,this._timer=null,this._options.forever&&(this._cachedTimeouts=this._timeouts.slice(0))}HD.exports=ct;ct.prototype.reset=function(){this._attempts=1,this._timeouts=this._originalTimeouts.slice(0)};ct.prototype.stop=function(){this._timeout&&clearTimeout(this._timeout),this._timer&&clearTimeout(this._timer),this._timeouts=[],this._cachedTimeouts=null};ct.prototype.retry=function(t){if(this._timeout&&clearTimeout(this._timeout),!t)return!1;var e=new Date().getTime();if(t&&e-this._operationStart>=this._maxRetryTime)return this._errors.push(t),this._errors.unshift(new Error("RetryOperation timeout occurred")),!1;this._errors.push(t);var r=this._timeouts.shift();if(r===void 0)if(this._cachedTimeouts)this._errors.splice(0,this._errors.length-1),r=this._cachedTimeouts.slice(-1);else return!1;var i=this;return this._timer=setTimeout(function(){i._attempts++,i._operationTimeoutCb&&(i._timeout=setTimeout(function(){i._operationTimeoutCb(i._attempts)},i._operationTimeout),i._options.unref&&i._timeout.unref()),i._fn(i._attempts)},r),this._options.unref&&this._timer.unref(),!0};ct.prototype.attempt=function(t,e){this._fn=t,e&&(e.timeout&&(this._operationTimeout=e.timeout),e.cb&&(this._operationTimeoutCb=e.cb));var r=this;this._operationTimeoutCb&&(this._timeout=setTimeout(function(){r._operationTimeoutCb()},r._operationTimeout)),this._operationStart=new Date().getTime(),this._fn(this._attempts)};ct.prototype.try=function(t){console.log("Using RetryOperation.try() is deprecated"),this.attempt(t)};ct.prototype.start=function(t){console.log("Using RetryOperation.start() is deprecated"),this.attempt(t)};ct.prototype.start=ct.prototype.try;ct.prototype.errors=function(){return this._errors};ct.prototype.attempts=function(){return this._attempts};ct.prototype.mainError=function(){if(this._errors.length===0)return null;for(var t={},e=null,r=0,i=0;i<this._errors.length;i++){var n=this._errors[i],s=n.message,o=(t[s]||0)+1;t[s]=o,o>=r&&(e=n,r=o)}return e}});var UD=$(ri=>{var vk=qD();ri.operation=function(t){var e=ri.timeouts(t);return new vk(e,{forever:t&&(t.forever||t.retries===1/0),unref:t&&t.unref,maxRetryTime:t&&t.maxRetryTime})};ri.timeouts=function(t){if(t instanceof Array)return[].concat(t);var e={retries:10,factor:2,minTimeout:1*1e3,maxTimeout:1/0,randomize:!1};for(var r in t)e[r]=t[r];if(e.minTimeout>e.maxTimeout)throw new Error("minTimeout is greater than maxTimeout");for(var i=[],n=0;n<e.retries;n++)i.push(this.createTimeout(n,e));return t&&t.forever&&!i.length&&i.push(this.createTimeout(n,e)),i.sort(function(s,o){return s-o}),i};ri.createTimeout=function(t,e){var r=e.randomize?Math.random()+1:1,i=Math.round(r*Math.max(e.minTimeout,1)*Math.pow(e.factor,t));return i=Math.min(i,e.maxTimeout),i};ri.wrap=function(t,e,r){if(e instanceof Array&&(r=e,e=null),!r){r=[];for(var i in t)typeof t[i]=="function"&&r.push(i)}for(var n=0;n<r.length;n++){var s=r[n],o=t[s];t[s]=function(u){var l=ri.operation(e),c=Array.prototype.slice.call(arguments,1),f=c.pop();c.push(function(h){l.retry(h)||(h&&(arguments[0]=l.mainError()),f.apply(this,arguments))}),l.attempt(function(){u.apply(t,c)})}.bind(t,o),t[s].options=e}}});var zD=$((CI,GD)=>{GD.exports=UD()});var YD=$((xI,WD)=>{var Ck=zD();function xk(t,e){function r(i,n){var s=e||{},o;"randomize"in s||(s.randomize=!0),o=Ck.operation(s);function a(c){n(c||new Error("Aborted"))}function u(c,f){if(c.bail){a(c);return}o.retry(c)?s.onRetry&&s.onRetry(c,f):n(o.mainError())}function l(c){var f;try{f=t(a,c)}catch(h){u(h,c);return}Promise.resolve(f).then(i).catch(function(p){u(p,c)})}o.attempt(l)}return new Promise(r)}WD.exports=xk});var Kb=J(require("chalk"));var n_=J(tf());function Sa(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function cn(t){return cn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},cn(t)}function Aa(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function va(t,e){if(e&&(cn(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Aa(t)}function Br(t){return Br=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Br(t)}function Nt(t,e){return Nt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,n){return i.__proto__=n,i},Nt(t,e)}function Ca(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Nt(t,e)}function xa(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function Ra(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ai(t,e,r){return Ra()?ai=Reflect.construct.bind():ai=function(n,s,o){var a=[null];a.push.apply(a,s);var u=Function.bind.apply(n,a),l=new u;return o&&Nt(l,o.prototype),l},ai.apply(null,arguments)}function hn(t){var e=typeof Map=="function"?new Map:void 0;return hn=function(i){if(i===null||!xa(i))return i;if(typeof i!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e!="undefined"){if(e.has(i))return e.get(i);e.set(i,n)}function n(){return ai(i,arguments,Br(this).constructor)}return n.prototype=Object.create(i.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),Nt(n,i)},hn(t)}var rf=J(require("find-up"));var s_=J(require("fs-extra")),aB=function(t){Ca(e,t);function e(r){var i;return Sa(this,e),i=va(this,Br(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),i.directory=r,i}return e}(hn(Error));var o_=J(require("fs")),a_=J(require("path"));var HC=J(require("fs")),qC=J(require("path"));function Df(t){return typeof t=="undefined"||t===null}function c_(t){return typeof t=="object"&&t!==null}function h_(t){return Array.isArray(t)?t:Df(t)?[]:[t]}function f_(t,e){var r,i,n,s;if(e)for(s=Object.keys(e),r=0,i=s.length;r<i;r+=1)n=s[r],t[n]=e[n];return t}function p_(t,e){var r="",i;for(i=0;i<e;i+=1)r+=t;return r}function d_(t){return t===0&&Number.NEGATIVE_INFINITY===1/t}var m_=Df,g_=c_,y_=h_,E_=p_,D_=d_,b_=f_,ve={isNothing:m_,isObject:g_,toArray:y_,repeat:E_,isNegativeZero:D_,extend:b_};function bf(t,e){var r="",i=t.reason||"(unknown reason)";return t.mark?(t.mark.name&&(r+='in "'+t.mark.name+'" '),r+="("+(t.mark.line+1)+":"+(t.mark.column+1)+")",!e&&t.mark.snippet&&(r+=`
10
10
 
11
11
  `+t.mark.snippet),i+" "+r):i}function pn(t,e){Error.call(this),this.name="YAMLException",this.reason=t,this.mark=e,this.message=bf(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}pn.prototype=Object.create(Error.prototype);pn.prototype.constructor=pn;pn.prototype.toString=function(e){return this.name+": "+bf(this,e)};var He=pn;function Fa(t,e,r,i,n){var s="",o="",a=Math.floor(n/2)-1;return i-e>a&&(s=" ... ",e=i-a+s.length),r-i>a&&(o=" ...",r=i+a-o.length),{str:s+t.slice(e,r).replace(/\t/g,"\u2192")+o,pos:i-e+s.length}}function Oa(t,e){return ve.repeat(" ",e-t.length)+t}function __(t,e){if(e=Object.create(e||null),!t.buffer)return null;e.maxLength||(e.maxLength=79),typeof e.indent!="number"&&(e.indent=1),typeof e.linesBefore!="number"&&(e.linesBefore=3),typeof e.linesAfter!="number"&&(e.linesAfter=2);for(var r=/\r?\n|\r|\0/g,i=[0],n=[],s,o=-1;s=r.exec(t.buffer);)n.push(s.index),i.push(s.index+s[0].length),t.position<=s.index&&o<0&&(o=i.length-2);o<0&&(o=i.length-1);var a="",u,l,c=Math.min(t.line+e.linesAfter,n.length).toString().length,f=e.maxLength-(e.indent+c+3);for(u=1;u<=e.linesBefore&&!(o-u<0);u++)l=Fa(t.buffer,i[o-u],n[o-u],t.position-(i[o]-i[o-u]),f),a=ve.repeat(" ",e.indent)+Oa((t.line-u+1).toString(),c)+" | "+l.str+`
12
12
  `+a;for(l=Fa(t.buffer,i[o],n[o],t.position,f),a+=ve.repeat(" ",e.indent)+Oa((t.line+1).toString(),c)+" | "+l.str+`
13
13
  `,a+=ve.repeat("-",e.indent+c+3+l.pos)+`^
14
14
  `,u=1;u<=e.linesAfter&&!(o+u>=n.length);u++)l=Fa(t.buffer,i[o+u],n[o+u],t.position-(i[o]-i[o+u]),f),a+=ve.repeat(" ",e.indent)+Oa((t.line+u+1).toString(),c)+" | "+l.str+`
15
15
  `;return a.replace(/\n$/,"")}var w_=__,S_=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],A_=["scalar","sequence","mapping"];function v_(t){var e={};return t!==null&&Object.keys(t).forEach(function(r){t[r].forEach(function(i){e[String(i)]=r})}),e}function C_(t,e){if(e=e||{},Object.keys(e).forEach(function(r){if(S_.indexOf(r)===-1)throw new He('Unknown option "'+r+'" is met in definition of "'+t+'" YAML type.')}),this.options=e,this.tag=t,this.kind=e.kind||null,this.resolve=e.resolve||function(){return!0},this.construct=e.construct||function(r){return r},this.instanceOf=e.instanceOf||null,this.predicate=e.predicate||null,this.represent=e.represent||null,this.representName=e.representName||null,this.defaultStyle=e.defaultStyle||null,this.multi=e.multi||!1,this.styleAliases=v_(e.styleAliases||null),A_.indexOf(this.kind)===-1)throw new He('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}var Oe=C_;function nf(t,e){var r=[];return t[e].forEach(function(i){var n=r.length;r.forEach(function(s,o){s.tag===i.tag&&s.kind===i.kind&&s.multi===i.multi&&(n=o)}),r[n]=i}),r}function x_(){var t={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},e,r;function i(n){n.multi?(t.multi[n.kind].push(n),t.multi.fallback.push(n)):t[n.kind][n.tag]=t.fallback[n.tag]=n}for(e=0,r=arguments.length;e<r;e+=1)arguments[e].forEach(i);return t}function Ta(t){return this.extend(t)}Ta.prototype.extend=function(e){var r=[],i=[];if(e instanceof Oe)i.push(e);else if(Array.isArray(e))i=i.concat(e);else if(e&&(Array.isArray(e.implicit)||Array.isArray(e.explicit)))e.implicit&&(r=r.concat(e.implicit)),e.explicit&&(i=i.concat(e.explicit));else throw new He("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");r.forEach(function(s){if(!(s instanceof Oe))throw new He("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(s.loadKind&&s.loadKind!=="scalar")throw new He("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(s.multi)throw new He("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),i.forEach(function(s){if(!(s instanceof Oe))throw new He("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var n=Object.create(Ta.prototype);return n.implicit=(this.implicit||[]).concat(r),n.explicit=(this.explicit||[]).concat(i),n.compiledImplicit=nf(n,"implicit"),n.compiledExplicit=nf(n,"explicit"),n.compiledTypeMap=x_(n.compiledImplicit,n.compiledExplicit),n};var _f=Ta,wf=new Oe("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}}),Sf=new Oe("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}}),Af=new Oe("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}}),vf=new _f({explicit:[wf,Sf,Af]});function R_(t){if(t===null)return!0;var e=t.length;return e===1&&t==="~"||e===4&&(t==="null"||t==="Null"||t==="NULL")}function F_(){return null}function O_(t){return t===null}var Cf=new Oe("tag:yaml.org,2002:null",{kind:"scalar",resolve:R_,construct:F_,predicate:O_,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});function k_(t){if(t===null)return!1;var e=t.length;return e===4&&(t==="true"||t==="True"||t==="TRUE")||e===5&&(t==="false"||t==="False"||t==="FALSE")}function T_(t){return t==="true"||t==="True"||t==="TRUE"}function L_(t){return Object.prototype.toString.call(t)==="[object Boolean]"}var xf=new Oe("tag:yaml.org,2002:bool",{kind:"scalar",resolve:k_,construct:T_,predicate:L_,represent:{lowercase:function(t){return t?"true":"false"},uppercase:function(t){return t?"TRUE":"FALSE"},camelcase:function(t){return t?"True":"False"}},defaultStyle:"lowercase"});function B_(t){return 48<=t&&t<=57||65<=t&&t<=70||97<=t&&t<=102}function P_(t){return 48<=t&&t<=55}function I_(t){return 48<=t&&t<=57}function N_(t){if(t===null)return!1;var e=t.length,r=0,i=!1,n;if(!e)return!1;if(n=t[r],(n==="-"||n==="+")&&(n=t[++r]),n==="0"){if(r+1===e)return!0;if(n=t[++r],n==="b"){for(r++;r<e;r++)if(n=t[r],n!=="_"){if(n!=="0"&&n!=="1")return!1;i=!0}return i&&n!=="_"}if(n==="x"){for(r++;r<e;r++)if(n=t[r],n!=="_"){if(!B_(t.charCodeAt(r)))return!1;i=!0}return i&&n!=="_"}if(n==="o"){for(r++;r<e;r++)if(n=t[r],n!=="_"){if(!P_(t.charCodeAt(r)))return!1;i=!0}return i&&n!=="_"}}if(n==="_")return!1;for(;r<e;r++)if(n=t[r],n!=="_"){if(!I_(t.charCodeAt(r)))return!1;i=!0}return!(!i||n==="_")}function M_(t){var e=t,r=1,i;if(e.indexOf("_")!==-1&&(e=e.replace(/_/g,"")),i=e[0],(i==="-"||i==="+")&&(i==="-"&&(r=-1),e=e.slice(1),i=e[0]),e==="0")return 0;if(i==="0"){if(e[1]==="b")return r*parseInt(e.slice(2),2);if(e[1]==="x")return r*parseInt(e.slice(2),16);if(e[1]==="o")return r*parseInt(e.slice(2),8)}return r*parseInt(e,10)}function j_(t){return Object.prototype.toString.call(t)==="[object Number]"&&t%1===0&&!ve.isNegativeZero(t)}var Rf=new Oe("tag:yaml.org,2002:int",{kind:"scalar",resolve:N_,construct:M_,predicate:j_,represent:{binary:function(t){return t>=0?"0b"+t.toString(2):"-0b"+t.toString(2).slice(1)},octal:function(t){return t>=0?"0o"+t.toString(8):"-0o"+t.toString(8).slice(1)},decimal:function(t){return t.toString(10)},hexadecimal:function(t){return t>=0?"0x"+t.toString(16).toUpperCase():"-0x"+t.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),$_=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function H_(t){return!(t===null||!$_.test(t)||t[t.length-1]==="_")}function q_(t){var e,r;return e=t.replace(/_/g,"").toLowerCase(),r=e[0]==="-"?-1:1,"+-".indexOf(e[0])>=0&&(e=e.slice(1)),e===".inf"?r===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:e===".nan"?NaN:r*parseFloat(e,10)}var U_=/^[-+]?[0-9]+e/;function G_(t,e){var r;if(isNaN(t))switch(e){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===t)switch(e){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===t)switch(e){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(ve.isNegativeZero(t))return"-0.0";return r=t.toString(10),U_.test(r)?r.replace("e",".e"):r}function z_(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!==0||ve.isNegativeZero(t))}var Ff=new Oe("tag:yaml.org,2002:float",{kind:"scalar",resolve:H_,construct:q_,predicate:z_,represent:G_,defaultStyle:"lowercase"}),Of=vf.extend({implicit:[Cf,xf,Rf,Ff]}),kf=Of,Tf=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Lf=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function W_(t){return t===null?!1:Tf.exec(t)!==null||Lf.exec(t)!==null}function Y_(t){var e,r,i,n,s,o,a,u=0,l=null,c,f,h;if(e=Tf.exec(t),e===null&&(e=Lf.exec(t)),e===null)throw new Error("Date resolve error");if(r=+e[1],i=+e[2]-1,n=+e[3],!e[4])return new Date(Date.UTC(r,i,n));if(s=+e[4],o=+e[5],a=+e[6],e[7]){for(u=e[7].slice(0,3);u.length<3;)u+="0";u=+u}return e[9]&&(c=+e[10],f=+(e[11]||0),l=(c*60+f)*6e4,e[9]==="-"&&(l=-l)),h=new Date(Date.UTC(r,i,n,s,o,a,u)),l&&h.setTime(h.getTime()-l),h}function V_(t){return t.toISOString()}var Bf=new Oe("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:W_,construct:Y_,instanceOf:Date,represent:V_});function K_(t){return t==="<<"||t===null}var Pf=new Oe("tag:yaml.org,2002:merge",{kind:"scalar",resolve:K_}),Na=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
16
- \r`;function Z_(t){if(t===null)return!1;var e,r,i=0,n=t.length,s=Na;for(r=0;r<n;r++)if(e=s.indexOf(t.charAt(r)),!(e>64)){if(e<0)return!1;i+=6}return i%8===0}function J_(t){var e,r,i=t.replace(/[\r\n=]/g,""),n=i.length,s=Na,o=0,a=[];for(e=0;e<n;e++)e%4===0&&e&&(a.push(o>>16&255),a.push(o>>8&255),a.push(o&255)),o=o<<6|s.indexOf(i.charAt(e));return r=n%4*6,r===0?(a.push(o>>16&255),a.push(o>>8&255),a.push(o&255)):r===18?(a.push(o>>10&255),a.push(o>>2&255)):r===12&&a.push(o>>4&255),new Uint8Array(a)}function X_(t){var e="",r=0,i,n,s=t.length,o=Na;for(i=0;i<s;i++)i%3===0&&i&&(e+=o[r>>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]),r=(r<<8)+t[i];return n=s%3,n===0?(e+=o[r>>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]):n===2?(e+=o[r>>10&63],e+=o[r>>4&63],e+=o[r<<2&63],e+=o[64]):n===1&&(e+=o[r>>2&63],e+=o[r<<4&63],e+=o[64],e+=o[64]),e}function Q_(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"}var If=new Oe("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Z_,construct:J_,predicate:Q_,represent:X_}),ew=Object.prototype.hasOwnProperty,tw=Object.prototype.toString;function rw(t){if(t===null)return!0;var e=[],r,i,n,s,o,a=t;for(r=0,i=a.length;r<i;r+=1){if(n=a[r],o=!1,tw.call(n)!=="[object Object]")return!1;for(s in n)if(ew.call(n,s))if(!o)o=!0;else return!1;if(!o)return!1;if(e.indexOf(s)===-1)e.push(s);else return!1}return!0}function iw(t){return t!==null?t:[]}var Nf=new Oe("tag:yaml.org,2002:omap",{kind:"sequence",resolve:rw,construct:iw}),nw=Object.prototype.toString;function sw(t){if(t===null)return!0;var e,r,i,n,s,o=t;for(s=new Array(o.length),e=0,r=o.length;e<r;e+=1){if(i=o[e],nw.call(i)!=="[object Object]"||(n=Object.keys(i),n.length!==1))return!1;s[e]=[n[0],i[n[0]]]}return!0}function ow(t){if(t===null)return[];var e,r,i,n,s,o=t;for(s=new Array(o.length),e=0,r=o.length;e<r;e+=1)i=o[e],n=Object.keys(i),s[e]=[n[0],i[n[0]]];return s}var Mf=new Oe("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:sw,construct:ow}),aw=Object.prototype.hasOwnProperty;function uw(t){if(t===null)return!0;var e,r=t;for(e in r)if(aw.call(r,e)&&r[e]!==null)return!1;return!0}function lw(t){return t!==null?t:{}}var jf=new Oe("tag:yaml.org,2002:set",{kind:"mapping",resolve:uw,construct:lw}),Ma=kf.extend({implicit:[Bf,Pf],explicit:[If,Nf,Mf,jf]}),nr=Object.prototype.hasOwnProperty,is=1,$f=2,Hf=3,ns=4,ka=1,cw=2,sf=3,hw=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,fw=/[\x85\u2028\u2029]/,pw=/[,\[\]\{\}]/,qf=/^(?:!|!!|![a-z\-]+!)$/i,Uf=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function of(t){return Object.prototype.toString.call(t)}function Et(t){return t===10||t===13}function Pr(t){return t===9||t===32}function Ue(t){return t===9||t===32||t===10||t===13}function li(t){return t===44||t===91||t===93||t===123||t===125}function dw(t){var e;return 48<=t&&t<=57?t-48:(e=t|32,97<=e&&e<=102?e-97+10:-1)}function mw(t){return t===120?2:t===117?4:t===85?8:0}function gw(t){return 48<=t&&t<=57?t-48:-1}function af(t){return t===48?"\0":t===97?"\x07":t===98?"\b":t===116||t===9?" ":t===110?`
17
- `:t===118?"\v":t===102?"\f":t===114?"\r":t===101?"\x1B":t===32?" ":t===34?'"':t===47?"/":t===92?"\\":t===78?"\x85":t===95?"\xA0":t===76?"\u2028":t===80?"\u2029":""}function yw(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}var Gf=new Array(256),zf=new Array(256);for(Br=0;Br<256;Br++)Gf[Br]=af(Br)?1:0,zf[Br]=af(Br);var Br;function Ew(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||Ma,this.onWarning=e.onWarning||null,this.legacy=e.legacy||!1,this.json=e.json||!1,this.listener=e.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function Wf(t,e){var r={name:t.filename,buffer:t.input.slice(0,-1),position:t.position,line:t.line,column:t.position-t.lineStart};return r.snippet=w_(r),new He(e,r)}function ee(t,e){throw Wf(t,e)}function ss(t,e){t.onWarning&&t.onWarning.call(null,Wf(t,e))}var uf={YAML:function(e,r,i){var n,s,o;e.version!==null&&ee(e,"duplication of %YAML directive"),i.length!==1&&ee(e,"YAML directive accepts exactly one argument"),n=/^([0-9]+)\.([0-9]+)$/.exec(i[0]),n===null&&ee(e,"ill-formed argument of the YAML directive"),s=parseInt(n[1],10),o=parseInt(n[2],10),s!==1&&ee(e,"unacceptable YAML version of the document"),e.version=i[0],e.checkLineBreaks=o<2,o!==1&&o!==2&&ss(e,"unsupported YAML version of the document")},TAG:function(e,r,i){var n,s;i.length!==2&&ee(e,"TAG directive accepts exactly two arguments"),n=i[0],s=i[1],qf.test(n)||ee(e,"ill-formed tag handle (first argument) of the TAG directive"),nr.call(e.tagMap,n)&&ee(e,'there is a previously declared suffix for "'+n+'" tag handle'),Uf.test(s)||ee(e,"ill-formed tag prefix (second argument) of the TAG directive");try{s=decodeURIComponent(s)}catch{ee(e,"tag prefix is malformed: "+s)}e.tagMap[n]=s}};function ir(t,e,r,i){var n,s,o,a;if(e<r){if(a=t.input.slice(e,r),i)for(n=0,s=a.length;n<s;n+=1)o=a.charCodeAt(n),o===9||32<=o&&o<=1114111||ee(t,"expected valid JSON character");else hw.test(a)&&ee(t,"the stream contains non-printable characters");t.result+=a}}function lf(t,e,r,i){var n,s,o,a;for(ve.isObject(r)||ee(t,"cannot merge mappings; the provided source object is unacceptable"),n=Object.keys(r),o=0,a=n.length;o<a;o+=1)s=n[o],nr.call(e,s)||(e[s]=r[s],i[s]=!0)}function ci(t,e,r,i,n,s,o,a,u){var l,c;if(Array.isArray(n))for(n=Array.prototype.slice.call(n),l=0,c=n.length;l<c;l+=1)Array.isArray(n[l])&&ee(t,"nested arrays are not supported inside keys"),typeof n=="object"&&of(n[l])==="[object Object]"&&(n[l]="[object Object]");if(typeof n=="object"&&of(n)==="[object Object]"&&(n="[object Object]"),n=String(n),e===null&&(e={}),i==="tag:yaml.org,2002:merge")if(Array.isArray(s))for(l=0,c=s.length;l<c;l+=1)lf(t,e,s[l],r);else lf(t,e,s,r);else!t.json&&!nr.call(r,n)&&nr.call(e,n)&&(t.line=o||t.line,t.lineStart=a||t.lineStart,t.position=u||t.position,ee(t,"duplicated mapping key")),n==="__proto__"?Object.defineProperty(e,n,{configurable:!0,enumerable:!0,writable:!0,value:s}):e[n]=s,delete r[n];return e}function ja(t){var e;e=t.input.charCodeAt(t.position),e===10?t.position++:e===13?(t.position++,t.input.charCodeAt(t.position)===10&&t.position++):ee(t,"a line break is expected"),t.line+=1,t.lineStart=t.position,t.firstTabInLine=-1}function Se(t,e,r){for(var i=0,n=t.input.charCodeAt(t.position);n!==0;){for(;Pr(n);)n===9&&t.firstTabInLine===-1&&(t.firstTabInLine=t.position),n=t.input.charCodeAt(++t.position);if(e&&n===35)do n=t.input.charCodeAt(++t.position);while(n!==10&&n!==13&&n!==0);if(Et(n))for(ja(t),n=t.input.charCodeAt(t.position),i++,t.lineIndent=0;n===32;)t.lineIndent++,n=t.input.charCodeAt(++t.position);else break}return r!==-1&&i!==0&&t.lineIndent<r&&ss(t,"deficient indentation"),i}function us(t){var e=t.position,r;return r=t.input.charCodeAt(e),!!((r===45||r===46)&&r===t.input.charCodeAt(e+1)&&r===t.input.charCodeAt(e+2)&&(e+=3,r=t.input.charCodeAt(e),r===0||Ue(r)))}function $a(t,e){e===1?t.result+=" ":e>1&&(t.result+=ve.repeat(`
18
- `,e-1))}function Dw(t,e,r){var i,n,s,o,a,u,l,c,f=t.kind,h=t.result,p;if(p=t.input.charCodeAt(t.position),Ue(p)||li(p)||p===35||p===38||p===42||p===33||p===124||p===62||p===39||p===34||p===37||p===64||p===96||(p===63||p===45)&&(n=t.input.charCodeAt(t.position+1),Ue(n)||r&&li(n)))return!1;for(t.kind="scalar",t.result="",s=o=t.position,a=!1;p!==0;){if(p===58){if(n=t.input.charCodeAt(t.position+1),Ue(n)||r&&li(n))break}else if(p===35){if(i=t.input.charCodeAt(t.position-1),Ue(i))break}else{if(t.position===t.lineStart&&us(t)||r&&li(p))break;if(Et(p))if(u=t.line,l=t.lineStart,c=t.lineIndent,Se(t,!1,-1),t.lineIndent>=e){a=!0,p=t.input.charCodeAt(t.position);continue}else{t.position=o,t.line=u,t.lineStart=l,t.lineIndent=c;break}}a&&(ir(t,s,o,!1),$a(t,t.line-u),s=o=t.position,a=!1),Pr(p)||(o=t.position+1),p=t.input.charCodeAt(++t.position)}return ir(t,s,o,!1),t.result?!0:(t.kind=f,t.result=h,!1)}function bw(t,e){var r,i,n;if(r=t.input.charCodeAt(t.position),r!==39)return!1;for(t.kind="scalar",t.result="",t.position++,i=n=t.position;(r=t.input.charCodeAt(t.position))!==0;)if(r===39)if(ir(t,i,t.position,!0),r=t.input.charCodeAt(++t.position),r===39)i=t.position,t.position++,n=t.position;else return!0;else Et(r)?(ir(t,i,n,!0),$a(t,Se(t,!1,e)),i=n=t.position):t.position===t.lineStart&&us(t)?ee(t,"unexpected end of the document within a single quoted scalar"):(t.position++,n=t.position);ee(t,"unexpected end of the stream within a single quoted scalar")}function _w(t,e){var r,i,n,s,o,a;if(a=t.input.charCodeAt(t.position),a!==34)return!1;for(t.kind="scalar",t.result="",t.position++,r=i=t.position;(a=t.input.charCodeAt(t.position))!==0;){if(a===34)return ir(t,r,t.position,!0),t.position++,!0;if(a===92){if(ir(t,r,t.position,!0),a=t.input.charCodeAt(++t.position),Et(a))Se(t,!1,e);else if(a<256&&Gf[a])t.result+=zf[a],t.position++;else if((o=mw(a))>0){for(n=o,s=0;n>0;n--)a=t.input.charCodeAt(++t.position),(o=dw(a))>=0?s=(s<<4)+o:ee(t,"expected hexadecimal character");t.result+=yw(s),t.position++}else ee(t,"unknown escape sequence");r=i=t.position}else Et(a)?(ir(t,r,i,!0),$a(t,Se(t,!1,e)),r=i=t.position):t.position===t.lineStart&&us(t)?ee(t,"unexpected end of the document within a double quoted scalar"):(t.position++,i=t.position)}ee(t,"unexpected end of the stream within a double quoted scalar")}function ww(t,e){var r=!0,i,n,s,o=t.tag,a,u=t.anchor,l,c,f,h,p,g=Object.create(null),y,E,v,F;if(F=t.input.charCodeAt(t.position),F===91)c=93,p=!1,a=[];else if(F===123)c=125,p=!0,a={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=a),F=t.input.charCodeAt(++t.position);F!==0;){if(Se(t,!0,e),F=t.input.charCodeAt(t.position),F===c)return t.position++,t.tag=o,t.anchor=u,t.kind=p?"mapping":"sequence",t.result=a,!0;r?F===44&&ee(t,"expected the node content, but found ','"):ee(t,"missed comma between flow collection entries"),E=y=v=null,f=h=!1,F===63&&(l=t.input.charCodeAt(t.position+1),Ue(l)&&(f=h=!0,t.position++,Se(t,!0,e))),i=t.line,n=t.lineStart,s=t.position,hi(t,e,is,!1,!0),E=t.tag,y=t.result,Se(t,!0,e),F=t.input.charCodeAt(t.position),(h||t.line===i)&&F===58&&(f=!0,F=t.input.charCodeAt(++t.position),Se(t,!0,e),hi(t,e,is,!1,!0),v=t.result),p?ci(t,a,g,E,y,v,i,n,s):f?a.push(ci(t,null,g,E,y,v,i,n,s)):a.push(y),Se(t,!0,e),F=t.input.charCodeAt(t.position),F===44?(r=!0,F=t.input.charCodeAt(++t.position)):r=!1}ee(t,"unexpected end of the stream within a flow collection")}function Sw(t,e){var r,i,n=ka,s=!1,o=!1,a=e,u=0,l=!1,c,f;if(f=t.input.charCodeAt(t.position),f===124)i=!1;else if(f===62)i=!0;else return!1;for(t.kind="scalar",t.result="";f!==0;)if(f=t.input.charCodeAt(++t.position),f===43||f===45)ka===n?n=f===43?sf:cw:ee(t,"repeat of a chomping mode identifier");else if((c=gw(f))>=0)c===0?ee(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?ee(t,"repeat of an indentation width identifier"):(a=e+c-1,o=!0);else break;if(Pr(f)){do f=t.input.charCodeAt(++t.position);while(Pr(f));if(f===35)do f=t.input.charCodeAt(++t.position);while(!Et(f)&&f!==0)}for(;f!==0;){for(ja(t),t.lineIndent=0,f=t.input.charCodeAt(t.position);(!o||t.lineIndent<a)&&f===32;)t.lineIndent++,f=t.input.charCodeAt(++t.position);if(!o&&t.lineIndent>a&&(a=t.lineIndent),Et(f)){u++;continue}if(t.lineIndent<a){n===sf?t.result+=ve.repeat(`
16
+ \r`;function Z_(t){if(t===null)return!1;var e,r,i=0,n=t.length,s=Na;for(r=0;r<n;r++)if(e=s.indexOf(t.charAt(r)),!(e>64)){if(e<0)return!1;i+=6}return i%8===0}function J_(t){var e,r,i=t.replace(/[\r\n=]/g,""),n=i.length,s=Na,o=0,a=[];for(e=0;e<n;e++)e%4===0&&e&&(a.push(o>>16&255),a.push(o>>8&255),a.push(o&255)),o=o<<6|s.indexOf(i.charAt(e));return r=n%4*6,r===0?(a.push(o>>16&255),a.push(o>>8&255),a.push(o&255)):r===18?(a.push(o>>10&255),a.push(o>>2&255)):r===12&&a.push(o>>4&255),new Uint8Array(a)}function X_(t){var e="",r=0,i,n,s=t.length,o=Na;for(i=0;i<s;i++)i%3===0&&i&&(e+=o[r>>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]),r=(r<<8)+t[i];return n=s%3,n===0?(e+=o[r>>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]):n===2?(e+=o[r>>10&63],e+=o[r>>4&63],e+=o[r<<2&63],e+=o[64]):n===1&&(e+=o[r>>2&63],e+=o[r<<4&63],e+=o[64],e+=o[64]),e}function Q_(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"}var If=new Oe("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Z_,construct:J_,predicate:Q_,represent:X_}),ew=Object.prototype.hasOwnProperty,tw=Object.prototype.toString;function rw(t){if(t===null)return!0;var e=[],r,i,n,s,o,a=t;for(r=0,i=a.length;r<i;r+=1){if(n=a[r],o=!1,tw.call(n)!=="[object Object]")return!1;for(s in n)if(ew.call(n,s))if(!o)o=!0;else return!1;if(!o)return!1;if(e.indexOf(s)===-1)e.push(s);else return!1}return!0}function iw(t){return t!==null?t:[]}var Nf=new Oe("tag:yaml.org,2002:omap",{kind:"sequence",resolve:rw,construct:iw}),nw=Object.prototype.toString;function sw(t){if(t===null)return!0;var e,r,i,n,s,o=t;for(s=new Array(o.length),e=0,r=o.length;e<r;e+=1){if(i=o[e],nw.call(i)!=="[object Object]"||(n=Object.keys(i),n.length!==1))return!1;s[e]=[n[0],i[n[0]]]}return!0}function ow(t){if(t===null)return[];var e,r,i,n,s,o=t;for(s=new Array(o.length),e=0,r=o.length;e<r;e+=1)i=o[e],n=Object.keys(i),s[e]=[n[0],i[n[0]]];return s}var Mf=new Oe("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:sw,construct:ow}),aw=Object.prototype.hasOwnProperty;function uw(t){if(t===null)return!0;var e,r=t;for(e in r)if(aw.call(r,e)&&r[e]!==null)return!1;return!0}function lw(t){return t!==null?t:{}}var jf=new Oe("tag:yaml.org,2002:set",{kind:"mapping",resolve:uw,construct:lw}),Ma=kf.extend({implicit:[Bf,Pf],explicit:[If,Nf,Mf,jf]}),sr=Object.prototype.hasOwnProperty,is=1,$f=2,Hf=3,ns=4,ka=1,cw=2,sf=3,hw=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,fw=/[\x85\u2028\u2029]/,pw=/[,\[\]\{\}]/,qf=/^(?:!|!!|![a-z\-]+!)$/i,Uf=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function of(t){return Object.prototype.toString.call(t)}function Et(t){return t===10||t===13}function Ir(t){return t===9||t===32}function Ue(t){return t===9||t===32||t===10||t===13}function li(t){return t===44||t===91||t===93||t===123||t===125}function dw(t){var e;return 48<=t&&t<=57?t-48:(e=t|32,97<=e&&e<=102?e-97+10:-1)}function mw(t){return t===120?2:t===117?4:t===85?8:0}function gw(t){return 48<=t&&t<=57?t-48:-1}function af(t){return t===48?"\0":t===97?"\x07":t===98?"\b":t===116||t===9?" ":t===110?`
17
+ `:t===118?"\v":t===102?"\f":t===114?"\r":t===101?"\x1B":t===32?" ":t===34?'"':t===47?"/":t===92?"\\":t===78?"\x85":t===95?"\xA0":t===76?"\u2028":t===80?"\u2029":""}function yw(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}var Gf=new Array(256),zf=new Array(256);for(Pr=0;Pr<256;Pr++)Gf[Pr]=af(Pr)?1:0,zf[Pr]=af(Pr);var Pr;function Ew(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||Ma,this.onWarning=e.onWarning||null,this.legacy=e.legacy||!1,this.json=e.json||!1,this.listener=e.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function Wf(t,e){var r={name:t.filename,buffer:t.input.slice(0,-1),position:t.position,line:t.line,column:t.position-t.lineStart};return r.snippet=w_(r),new He(e,r)}function ee(t,e){throw Wf(t,e)}function ss(t,e){t.onWarning&&t.onWarning.call(null,Wf(t,e))}var uf={YAML:function(e,r,i){var n,s,o;e.version!==null&&ee(e,"duplication of %YAML directive"),i.length!==1&&ee(e,"YAML directive accepts exactly one argument"),n=/^([0-9]+)\.([0-9]+)$/.exec(i[0]),n===null&&ee(e,"ill-formed argument of the YAML directive"),s=parseInt(n[1],10),o=parseInt(n[2],10),s!==1&&ee(e,"unacceptable YAML version of the document"),e.version=i[0],e.checkLineBreaks=o<2,o!==1&&o!==2&&ss(e,"unsupported YAML version of the document")},TAG:function(e,r,i){var n,s;i.length!==2&&ee(e,"TAG directive accepts exactly two arguments"),n=i[0],s=i[1],qf.test(n)||ee(e,"ill-formed tag handle (first argument) of the TAG directive"),sr.call(e.tagMap,n)&&ee(e,'there is a previously declared suffix for "'+n+'" tag handle'),Uf.test(s)||ee(e,"ill-formed tag prefix (second argument) of the TAG directive");try{s=decodeURIComponent(s)}catch{ee(e,"tag prefix is malformed: "+s)}e.tagMap[n]=s}};function nr(t,e,r,i){var n,s,o,a;if(e<r){if(a=t.input.slice(e,r),i)for(n=0,s=a.length;n<s;n+=1)o=a.charCodeAt(n),o===9||32<=o&&o<=1114111||ee(t,"expected valid JSON character");else hw.test(a)&&ee(t,"the stream contains non-printable characters");t.result+=a}}function lf(t,e,r,i){var n,s,o,a;for(ve.isObject(r)||ee(t,"cannot merge mappings; the provided source object is unacceptable"),n=Object.keys(r),o=0,a=n.length;o<a;o+=1)s=n[o],sr.call(e,s)||(e[s]=r[s],i[s]=!0)}function ci(t,e,r,i,n,s,o,a,u){var l,c;if(Array.isArray(n))for(n=Array.prototype.slice.call(n),l=0,c=n.length;l<c;l+=1)Array.isArray(n[l])&&ee(t,"nested arrays are not supported inside keys"),typeof n=="object"&&of(n[l])==="[object Object]"&&(n[l]="[object Object]");if(typeof n=="object"&&of(n)==="[object Object]"&&(n="[object Object]"),n=String(n),e===null&&(e={}),i==="tag:yaml.org,2002:merge")if(Array.isArray(s))for(l=0,c=s.length;l<c;l+=1)lf(t,e,s[l],r);else lf(t,e,s,r);else!t.json&&!sr.call(r,n)&&sr.call(e,n)&&(t.line=o||t.line,t.lineStart=a||t.lineStart,t.position=u||t.position,ee(t,"duplicated mapping key")),n==="__proto__"?Object.defineProperty(e,n,{configurable:!0,enumerable:!0,writable:!0,value:s}):e[n]=s,delete r[n];return e}function ja(t){var e;e=t.input.charCodeAt(t.position),e===10?t.position++:e===13?(t.position++,t.input.charCodeAt(t.position)===10&&t.position++):ee(t,"a line break is expected"),t.line+=1,t.lineStart=t.position,t.firstTabInLine=-1}function Se(t,e,r){for(var i=0,n=t.input.charCodeAt(t.position);n!==0;){for(;Ir(n);)n===9&&t.firstTabInLine===-1&&(t.firstTabInLine=t.position),n=t.input.charCodeAt(++t.position);if(e&&n===35)do n=t.input.charCodeAt(++t.position);while(n!==10&&n!==13&&n!==0);if(Et(n))for(ja(t),n=t.input.charCodeAt(t.position),i++,t.lineIndent=0;n===32;)t.lineIndent++,n=t.input.charCodeAt(++t.position);else break}return r!==-1&&i!==0&&t.lineIndent<r&&ss(t,"deficient indentation"),i}function us(t){var e=t.position,r;return r=t.input.charCodeAt(e),!!((r===45||r===46)&&r===t.input.charCodeAt(e+1)&&r===t.input.charCodeAt(e+2)&&(e+=3,r=t.input.charCodeAt(e),r===0||Ue(r)))}function $a(t,e){e===1?t.result+=" ":e>1&&(t.result+=ve.repeat(`
18
+ `,e-1))}function Dw(t,e,r){var i,n,s,o,a,u,l,c,f=t.kind,h=t.result,p;if(p=t.input.charCodeAt(t.position),Ue(p)||li(p)||p===35||p===38||p===42||p===33||p===124||p===62||p===39||p===34||p===37||p===64||p===96||(p===63||p===45)&&(n=t.input.charCodeAt(t.position+1),Ue(n)||r&&li(n)))return!1;for(t.kind="scalar",t.result="",s=o=t.position,a=!1;p!==0;){if(p===58){if(n=t.input.charCodeAt(t.position+1),Ue(n)||r&&li(n))break}else if(p===35){if(i=t.input.charCodeAt(t.position-1),Ue(i))break}else{if(t.position===t.lineStart&&us(t)||r&&li(p))break;if(Et(p))if(u=t.line,l=t.lineStart,c=t.lineIndent,Se(t,!1,-1),t.lineIndent>=e){a=!0,p=t.input.charCodeAt(t.position);continue}else{t.position=o,t.line=u,t.lineStart=l,t.lineIndent=c;break}}a&&(nr(t,s,o,!1),$a(t,t.line-u),s=o=t.position,a=!1),Ir(p)||(o=t.position+1),p=t.input.charCodeAt(++t.position)}return nr(t,s,o,!1),t.result?!0:(t.kind=f,t.result=h,!1)}function bw(t,e){var r,i,n;if(r=t.input.charCodeAt(t.position),r!==39)return!1;for(t.kind="scalar",t.result="",t.position++,i=n=t.position;(r=t.input.charCodeAt(t.position))!==0;)if(r===39)if(nr(t,i,t.position,!0),r=t.input.charCodeAt(++t.position),r===39)i=t.position,t.position++,n=t.position;else return!0;else Et(r)?(nr(t,i,n,!0),$a(t,Se(t,!1,e)),i=n=t.position):t.position===t.lineStart&&us(t)?ee(t,"unexpected end of the document within a single quoted scalar"):(t.position++,n=t.position);ee(t,"unexpected end of the stream within a single quoted scalar")}function _w(t,e){var r,i,n,s,o,a;if(a=t.input.charCodeAt(t.position),a!==34)return!1;for(t.kind="scalar",t.result="",t.position++,r=i=t.position;(a=t.input.charCodeAt(t.position))!==0;){if(a===34)return nr(t,r,t.position,!0),t.position++,!0;if(a===92){if(nr(t,r,t.position,!0),a=t.input.charCodeAt(++t.position),Et(a))Se(t,!1,e);else if(a<256&&Gf[a])t.result+=zf[a],t.position++;else if((o=mw(a))>0){for(n=o,s=0;n>0;n--)a=t.input.charCodeAt(++t.position),(o=dw(a))>=0?s=(s<<4)+o:ee(t,"expected hexadecimal character");t.result+=yw(s),t.position++}else ee(t,"unknown escape sequence");r=i=t.position}else Et(a)?(nr(t,r,i,!0),$a(t,Se(t,!1,e)),r=i=t.position):t.position===t.lineStart&&us(t)?ee(t,"unexpected end of the document within a double quoted scalar"):(t.position++,i=t.position)}ee(t,"unexpected end of the stream within a double quoted scalar")}function ww(t,e){var r=!0,i,n,s,o=t.tag,a,u=t.anchor,l,c,f,h,p,g=Object.create(null),y,E,v,F;if(F=t.input.charCodeAt(t.position),F===91)c=93,p=!1,a=[];else if(F===123)c=125,p=!0,a={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=a),F=t.input.charCodeAt(++t.position);F!==0;){if(Se(t,!0,e),F=t.input.charCodeAt(t.position),F===c)return t.position++,t.tag=o,t.anchor=u,t.kind=p?"mapping":"sequence",t.result=a,!0;r?F===44&&ee(t,"expected the node content, but found ','"):ee(t,"missed comma between flow collection entries"),E=y=v=null,f=h=!1,F===63&&(l=t.input.charCodeAt(t.position+1),Ue(l)&&(f=h=!0,t.position++,Se(t,!0,e))),i=t.line,n=t.lineStart,s=t.position,hi(t,e,is,!1,!0),E=t.tag,y=t.result,Se(t,!0,e),F=t.input.charCodeAt(t.position),(h||t.line===i)&&F===58&&(f=!0,F=t.input.charCodeAt(++t.position),Se(t,!0,e),hi(t,e,is,!1,!0),v=t.result),p?ci(t,a,g,E,y,v,i,n,s):f?a.push(ci(t,null,g,E,y,v,i,n,s)):a.push(y),Se(t,!0,e),F=t.input.charCodeAt(t.position),F===44?(r=!0,F=t.input.charCodeAt(++t.position)):r=!1}ee(t,"unexpected end of the stream within a flow collection")}function Sw(t,e){var r,i,n=ka,s=!1,o=!1,a=e,u=0,l=!1,c,f;if(f=t.input.charCodeAt(t.position),f===124)i=!1;else if(f===62)i=!0;else return!1;for(t.kind="scalar",t.result="";f!==0;)if(f=t.input.charCodeAt(++t.position),f===43||f===45)ka===n?n=f===43?sf:cw:ee(t,"repeat of a chomping mode identifier");else if((c=gw(f))>=0)c===0?ee(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?ee(t,"repeat of an indentation width identifier"):(a=e+c-1,o=!0);else break;if(Ir(f)){do f=t.input.charCodeAt(++t.position);while(Ir(f));if(f===35)do f=t.input.charCodeAt(++t.position);while(!Et(f)&&f!==0)}for(;f!==0;){for(ja(t),t.lineIndent=0,f=t.input.charCodeAt(t.position);(!o||t.lineIndent<a)&&f===32;)t.lineIndent++,f=t.input.charCodeAt(++t.position);if(!o&&t.lineIndent>a&&(a=t.lineIndent),Et(f)){u++;continue}if(t.lineIndent<a){n===sf?t.result+=ve.repeat(`
19
19
  `,s?1+u:u):n===ka&&s&&(t.result+=`
20
- `);break}for(i?Pr(f)?(l=!0,t.result+=ve.repeat(`
20
+ `);break}for(i?Ir(f)?(l=!0,t.result+=ve.repeat(`
21
21
  `,s?1+u:u)):l?(l=!1,t.result+=ve.repeat(`
22
22
  `,u+1)):u===0?s&&(t.result+=" "):t.result+=ve.repeat(`
23
23
  `,u):t.result+=ve.repeat(`
24
- `,s?1+u:u),s=!0,o=!0,u=0,r=t.position;!Et(f)&&f!==0;)f=t.input.charCodeAt(++t.position);ir(t,r,t.position,!1)}return!0}function cf(t,e){var r,i=t.tag,n=t.anchor,s=[],o,a=!1,u;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=s),u=t.input.charCodeAt(t.position);u!==0&&(t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,ee(t,"tab characters must not be used in indentation")),!(u!==45||(o=t.input.charCodeAt(t.position+1),!Ue(o))));){if(a=!0,t.position++,Se(t,!0,-1)&&t.lineIndent<=e){s.push(null),u=t.input.charCodeAt(t.position);continue}if(r=t.line,hi(t,e,Hf,!1,!0),s.push(t.result),Se(t,!0,-1),u=t.input.charCodeAt(t.position),(t.line===r||t.lineIndent>e)&&u!==0)ee(t,"bad indentation of a sequence entry");else if(t.lineIndent<e)break}return a?(t.tag=i,t.anchor=n,t.kind="sequence",t.result=s,!0):!1}function Aw(t,e,r){var i,n,s,o,a,u,l=t.tag,c=t.anchor,f={},h=Object.create(null),p=null,g=null,y=null,E=!1,v=!1,F;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=f),F=t.input.charCodeAt(t.position);F!==0;){if(!E&&t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,ee(t,"tab characters must not be used in indentation")),i=t.input.charCodeAt(t.position+1),s=t.line,(F===63||F===58)&&Ue(i))F===63?(E&&(ci(t,f,h,p,g,null,o,a,u),p=g=y=null),v=!0,E=!0,n=!0):E?(E=!1,n=!0):ee(t,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),t.position+=1,F=i;else{if(o=t.line,a=t.lineStart,u=t.position,!hi(t,r,$f,!1,!0))break;if(t.line===s){for(F=t.input.charCodeAt(t.position);Pr(F);)F=t.input.charCodeAt(++t.position);if(F===58)F=t.input.charCodeAt(++t.position),Ue(F)||ee(t,"a whitespace character is expected after the key-value separator within a block mapping"),E&&(ci(t,f,h,p,g,null,o,a,u),p=g=y=null),v=!0,E=!1,n=!1,p=t.tag,g=t.result;else if(v)ee(t,"can not read an implicit mapping pair; a colon is missed");else return t.tag=l,t.anchor=c,!0}else if(v)ee(t,"can not read a block mapping entry; a multiline key may not be an implicit key");else return t.tag=l,t.anchor=c,!0}if((t.line===s||t.lineIndent>e)&&(E&&(o=t.line,a=t.lineStart,u=t.position),hi(t,e,ns,!0,n)&&(E?g=t.result:y=t.result),E||(ci(t,f,h,p,g,y,o,a,u),p=g=y=null),Se(t,!0,-1),F=t.input.charCodeAt(t.position)),(t.line===s||t.lineIndent>e)&&F!==0)ee(t,"bad indentation of a mapping entry");else if(t.lineIndent<e)break}return E&&ci(t,f,h,p,g,null,o,a,u),v&&(t.tag=l,t.anchor=c,t.kind="mapping",t.result=f),v}function vw(t){var e,r=!1,i=!1,n,s,o;if(o=t.input.charCodeAt(t.position),o!==33)return!1;if(t.tag!==null&&ee(t,"duplication of a tag property"),o=t.input.charCodeAt(++t.position),o===60?(r=!0,o=t.input.charCodeAt(++t.position)):o===33?(i=!0,n="!!",o=t.input.charCodeAt(++t.position)):n="!",e=t.position,r){do o=t.input.charCodeAt(++t.position);while(o!==0&&o!==62);t.position<t.length?(s=t.input.slice(e,t.position),o=t.input.charCodeAt(++t.position)):ee(t,"unexpected end of the stream within a verbatim tag")}else{for(;o!==0&&!Ue(o);)o===33&&(i?ee(t,"tag suffix cannot contain exclamation marks"):(n=t.input.slice(e-1,t.position+1),qf.test(n)||ee(t,"named tag handle cannot contain such characters"),i=!0,e=t.position+1)),o=t.input.charCodeAt(++t.position);s=t.input.slice(e,t.position),pw.test(s)&&ee(t,"tag suffix cannot contain flow indicator characters")}s&&!Uf.test(s)&&ee(t,"tag name cannot contain such characters: "+s);try{s=decodeURIComponent(s)}catch{ee(t,"tag name is malformed: "+s)}return r?t.tag=s:nr.call(t.tagMap,n)?t.tag=t.tagMap[n]+s:n==="!"?t.tag="!"+s:n==="!!"?t.tag="tag:yaml.org,2002:"+s:ee(t,'undeclared tag handle "'+n+'"'),!0}function Cw(t){var e,r;if(r=t.input.charCodeAt(t.position),r!==38)return!1;for(t.anchor!==null&&ee(t,"duplication of an anchor property"),r=t.input.charCodeAt(++t.position),e=t.position;r!==0&&!Ue(r)&&!li(r);)r=t.input.charCodeAt(++t.position);return t.position===e&&ee(t,"name of an anchor node must contain at least one character"),t.anchor=t.input.slice(e,t.position),!0}function xw(t){var e,r,i;if(i=t.input.charCodeAt(t.position),i!==42)return!1;for(i=t.input.charCodeAt(++t.position),e=t.position;i!==0&&!Ue(i)&&!li(i);)i=t.input.charCodeAt(++t.position);return t.position===e&&ee(t,"name of an alias node must contain at least one character"),r=t.input.slice(e,t.position),nr.call(t.anchorMap,r)||ee(t,'unidentified alias "'+r+'"'),t.result=t.anchorMap[r],Se(t,!0,-1),!0}function hi(t,e,r,i,n){var s,o,a,u=1,l=!1,c=!1,f,h,p,g,y,E;if(t.listener!==null&&t.listener("open",t),t.tag=null,t.anchor=null,t.kind=null,t.result=null,s=o=a=ns===r||Hf===r,i&&Se(t,!0,-1)&&(l=!0,t.lineIndent>e?u=1:t.lineIndent===e?u=0:t.lineIndent<e&&(u=-1)),u===1)for(;vw(t)||Cw(t);)Se(t,!0,-1)?(l=!0,a=s,t.lineIndent>e?u=1:t.lineIndent===e?u=0:t.lineIndent<e&&(u=-1)):a=!1;if(a&&(a=l||n),(u===1||ns===r)&&(is===r||$f===r?y=e:y=e+1,E=t.position-t.lineStart,u===1?a&&(cf(t,E)||Aw(t,E,y))||ww(t,y)?c=!0:(o&&Sw(t,y)||bw(t,y)||_w(t,y)?c=!0:xw(t)?(c=!0,(t.tag!==null||t.anchor!==null)&&ee(t,"alias node should not have any properties")):Dw(t,y,is===r)&&(c=!0,t.tag===null&&(t.tag="?")),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):u===0&&(c=a&&cf(t,E))),t.tag===null)t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);else if(t.tag==="?"){for(t.result!==null&&t.kind!=="scalar"&&ee(t,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+t.kind+'"'),f=0,h=t.implicitTypes.length;f<h;f+=1)if(g=t.implicitTypes[f],g.resolve(t.result)){t.result=g.construct(t.result),t.tag=g.tag,t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);break}}else if(t.tag!=="!"){if(nr.call(t.typeMap[t.kind||"fallback"],t.tag))g=t.typeMap[t.kind||"fallback"][t.tag];else for(g=null,p=t.typeMap.multi[t.kind||"fallback"],f=0,h=p.length;f<h;f+=1)if(t.tag.slice(0,p[f].tag.length)===p[f].tag){g=p[f];break}g||ee(t,"unknown tag !<"+t.tag+">"),t.result!==null&&g.kind!==t.kind&&ee(t,"unacceptable node kind for !<"+t.tag+'> tag; it should be "'+g.kind+'", not "'+t.kind+'"'),g.resolve(t.result,t.tag)?(t.result=g.construct(t.result,t.tag),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):ee(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||c}function Rw(t){var e=t.position,r,i,n,s=!1,o;for(t.version=null,t.checkLineBreaks=t.legacy,t.tagMap=Object.create(null),t.anchorMap=Object.create(null);(o=t.input.charCodeAt(t.position))!==0&&(Se(t,!0,-1),o=t.input.charCodeAt(t.position),!(t.lineIndent>0||o!==37));){for(s=!0,o=t.input.charCodeAt(++t.position),r=t.position;o!==0&&!Ue(o);)o=t.input.charCodeAt(++t.position);for(i=t.input.slice(r,t.position),n=[],i.length<1&&ee(t,"directive name must not be less than one character in length");o!==0;){for(;Pr(o);)o=t.input.charCodeAt(++t.position);if(o===35){do o=t.input.charCodeAt(++t.position);while(o!==0&&!Et(o));break}if(Et(o))break;for(r=t.position;o!==0&&!Ue(o);)o=t.input.charCodeAt(++t.position);n.push(t.input.slice(r,t.position))}o!==0&&ja(t),nr.call(uf,i)?uf[i](t,i,n):ss(t,'unknown document directive "'+i+'"')}if(Se(t,!0,-1),t.lineIndent===0&&t.input.charCodeAt(t.position)===45&&t.input.charCodeAt(t.position+1)===45&&t.input.charCodeAt(t.position+2)===45?(t.position+=3,Se(t,!0,-1)):s&&ee(t,"directives end mark is expected"),hi(t,t.lineIndent-1,ns,!1,!0),Se(t,!0,-1),t.checkLineBreaks&&fw.test(t.input.slice(e,t.position))&&ss(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&us(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,Se(t,!0,-1));return}if(t.position<t.length-1)ee(t,"end of the stream or a document separator is expected");else return}function Yf(t,e){t=String(t),e=e||{},t.length!==0&&(t.charCodeAt(t.length-1)!==10&&t.charCodeAt(t.length-1)!==13&&(t+=`
24
+ `,s?1+u:u),s=!0,o=!0,u=0,r=t.position;!Et(f)&&f!==0;)f=t.input.charCodeAt(++t.position);nr(t,r,t.position,!1)}return!0}function cf(t,e){var r,i=t.tag,n=t.anchor,s=[],o,a=!1,u;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=s),u=t.input.charCodeAt(t.position);u!==0&&(t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,ee(t,"tab characters must not be used in indentation")),!(u!==45||(o=t.input.charCodeAt(t.position+1),!Ue(o))));){if(a=!0,t.position++,Se(t,!0,-1)&&t.lineIndent<=e){s.push(null),u=t.input.charCodeAt(t.position);continue}if(r=t.line,hi(t,e,Hf,!1,!0),s.push(t.result),Se(t,!0,-1),u=t.input.charCodeAt(t.position),(t.line===r||t.lineIndent>e)&&u!==0)ee(t,"bad indentation of a sequence entry");else if(t.lineIndent<e)break}return a?(t.tag=i,t.anchor=n,t.kind="sequence",t.result=s,!0):!1}function Aw(t,e,r){var i,n,s,o,a,u,l=t.tag,c=t.anchor,f={},h=Object.create(null),p=null,g=null,y=null,E=!1,v=!1,F;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=f),F=t.input.charCodeAt(t.position);F!==0;){if(!E&&t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,ee(t,"tab characters must not be used in indentation")),i=t.input.charCodeAt(t.position+1),s=t.line,(F===63||F===58)&&Ue(i))F===63?(E&&(ci(t,f,h,p,g,null,o,a,u),p=g=y=null),v=!0,E=!0,n=!0):E?(E=!1,n=!0):ee(t,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),t.position+=1,F=i;else{if(o=t.line,a=t.lineStart,u=t.position,!hi(t,r,$f,!1,!0))break;if(t.line===s){for(F=t.input.charCodeAt(t.position);Ir(F);)F=t.input.charCodeAt(++t.position);if(F===58)F=t.input.charCodeAt(++t.position),Ue(F)||ee(t,"a whitespace character is expected after the key-value separator within a block mapping"),E&&(ci(t,f,h,p,g,null,o,a,u),p=g=y=null),v=!0,E=!1,n=!1,p=t.tag,g=t.result;else if(v)ee(t,"can not read an implicit mapping pair; a colon is missed");else return t.tag=l,t.anchor=c,!0}else if(v)ee(t,"can not read a block mapping entry; a multiline key may not be an implicit key");else return t.tag=l,t.anchor=c,!0}if((t.line===s||t.lineIndent>e)&&(E&&(o=t.line,a=t.lineStart,u=t.position),hi(t,e,ns,!0,n)&&(E?g=t.result:y=t.result),E||(ci(t,f,h,p,g,y,o,a,u),p=g=y=null),Se(t,!0,-1),F=t.input.charCodeAt(t.position)),(t.line===s||t.lineIndent>e)&&F!==0)ee(t,"bad indentation of a mapping entry");else if(t.lineIndent<e)break}return E&&ci(t,f,h,p,g,null,o,a,u),v&&(t.tag=l,t.anchor=c,t.kind="mapping",t.result=f),v}function vw(t){var e,r=!1,i=!1,n,s,o;if(o=t.input.charCodeAt(t.position),o!==33)return!1;if(t.tag!==null&&ee(t,"duplication of a tag property"),o=t.input.charCodeAt(++t.position),o===60?(r=!0,o=t.input.charCodeAt(++t.position)):o===33?(i=!0,n="!!",o=t.input.charCodeAt(++t.position)):n="!",e=t.position,r){do o=t.input.charCodeAt(++t.position);while(o!==0&&o!==62);t.position<t.length?(s=t.input.slice(e,t.position),o=t.input.charCodeAt(++t.position)):ee(t,"unexpected end of the stream within a verbatim tag")}else{for(;o!==0&&!Ue(o);)o===33&&(i?ee(t,"tag suffix cannot contain exclamation marks"):(n=t.input.slice(e-1,t.position+1),qf.test(n)||ee(t,"named tag handle cannot contain such characters"),i=!0,e=t.position+1)),o=t.input.charCodeAt(++t.position);s=t.input.slice(e,t.position),pw.test(s)&&ee(t,"tag suffix cannot contain flow indicator characters")}s&&!Uf.test(s)&&ee(t,"tag name cannot contain such characters: "+s);try{s=decodeURIComponent(s)}catch{ee(t,"tag name is malformed: "+s)}return r?t.tag=s:sr.call(t.tagMap,n)?t.tag=t.tagMap[n]+s:n==="!"?t.tag="!"+s:n==="!!"?t.tag="tag:yaml.org,2002:"+s:ee(t,'undeclared tag handle "'+n+'"'),!0}function Cw(t){var e,r;if(r=t.input.charCodeAt(t.position),r!==38)return!1;for(t.anchor!==null&&ee(t,"duplication of an anchor property"),r=t.input.charCodeAt(++t.position),e=t.position;r!==0&&!Ue(r)&&!li(r);)r=t.input.charCodeAt(++t.position);return t.position===e&&ee(t,"name of an anchor node must contain at least one character"),t.anchor=t.input.slice(e,t.position),!0}function xw(t){var e,r,i;if(i=t.input.charCodeAt(t.position),i!==42)return!1;for(i=t.input.charCodeAt(++t.position),e=t.position;i!==0&&!Ue(i)&&!li(i);)i=t.input.charCodeAt(++t.position);return t.position===e&&ee(t,"name of an alias node must contain at least one character"),r=t.input.slice(e,t.position),sr.call(t.anchorMap,r)||ee(t,'unidentified alias "'+r+'"'),t.result=t.anchorMap[r],Se(t,!0,-1),!0}function hi(t,e,r,i,n){var s,o,a,u=1,l=!1,c=!1,f,h,p,g,y,E;if(t.listener!==null&&t.listener("open",t),t.tag=null,t.anchor=null,t.kind=null,t.result=null,s=o=a=ns===r||Hf===r,i&&Se(t,!0,-1)&&(l=!0,t.lineIndent>e?u=1:t.lineIndent===e?u=0:t.lineIndent<e&&(u=-1)),u===1)for(;vw(t)||Cw(t);)Se(t,!0,-1)?(l=!0,a=s,t.lineIndent>e?u=1:t.lineIndent===e?u=0:t.lineIndent<e&&(u=-1)):a=!1;if(a&&(a=l||n),(u===1||ns===r)&&(is===r||$f===r?y=e:y=e+1,E=t.position-t.lineStart,u===1?a&&(cf(t,E)||Aw(t,E,y))||ww(t,y)?c=!0:(o&&Sw(t,y)||bw(t,y)||_w(t,y)?c=!0:xw(t)?(c=!0,(t.tag!==null||t.anchor!==null)&&ee(t,"alias node should not have any properties")):Dw(t,y,is===r)&&(c=!0,t.tag===null&&(t.tag="?")),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):u===0&&(c=a&&cf(t,E))),t.tag===null)t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);else if(t.tag==="?"){for(t.result!==null&&t.kind!=="scalar"&&ee(t,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+t.kind+'"'),f=0,h=t.implicitTypes.length;f<h;f+=1)if(g=t.implicitTypes[f],g.resolve(t.result)){t.result=g.construct(t.result),t.tag=g.tag,t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);break}}else if(t.tag!=="!"){if(sr.call(t.typeMap[t.kind||"fallback"],t.tag))g=t.typeMap[t.kind||"fallback"][t.tag];else for(g=null,p=t.typeMap.multi[t.kind||"fallback"],f=0,h=p.length;f<h;f+=1)if(t.tag.slice(0,p[f].tag.length)===p[f].tag){g=p[f];break}g||ee(t,"unknown tag !<"+t.tag+">"),t.result!==null&&g.kind!==t.kind&&ee(t,"unacceptable node kind for !<"+t.tag+'> tag; it should be "'+g.kind+'", not "'+t.kind+'"'),g.resolve(t.result,t.tag)?(t.result=g.construct(t.result,t.tag),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):ee(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||c}function Rw(t){var e=t.position,r,i,n,s=!1,o;for(t.version=null,t.checkLineBreaks=t.legacy,t.tagMap=Object.create(null),t.anchorMap=Object.create(null);(o=t.input.charCodeAt(t.position))!==0&&(Se(t,!0,-1),o=t.input.charCodeAt(t.position),!(t.lineIndent>0||o!==37));){for(s=!0,o=t.input.charCodeAt(++t.position),r=t.position;o!==0&&!Ue(o);)o=t.input.charCodeAt(++t.position);for(i=t.input.slice(r,t.position),n=[],i.length<1&&ee(t,"directive name must not be less than one character in length");o!==0;){for(;Ir(o);)o=t.input.charCodeAt(++t.position);if(o===35){do o=t.input.charCodeAt(++t.position);while(o!==0&&!Et(o));break}if(Et(o))break;for(r=t.position;o!==0&&!Ue(o);)o=t.input.charCodeAt(++t.position);n.push(t.input.slice(r,t.position))}o!==0&&ja(t),sr.call(uf,i)?uf[i](t,i,n):ss(t,'unknown document directive "'+i+'"')}if(Se(t,!0,-1),t.lineIndent===0&&t.input.charCodeAt(t.position)===45&&t.input.charCodeAt(t.position+1)===45&&t.input.charCodeAt(t.position+2)===45?(t.position+=3,Se(t,!0,-1)):s&&ee(t,"directives end mark is expected"),hi(t,t.lineIndent-1,ns,!1,!0),Se(t,!0,-1),t.checkLineBreaks&&fw.test(t.input.slice(e,t.position))&&ss(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&us(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,Se(t,!0,-1));return}if(t.position<t.length-1)ee(t,"end of the stream or a document separator is expected");else return}function Yf(t,e){t=String(t),e=e||{},t.length!==0&&(t.charCodeAt(t.length-1)!==10&&t.charCodeAt(t.length-1)!==13&&(t+=`
25
25
  `),t.charCodeAt(0)===65279&&(t=t.slice(1)));var r=new Ew(t,e),i=t.indexOf("\0");for(i!==-1&&(r.position=i,ee(r,"null byte is not allowed in input")),r.input+="\0";r.input.charCodeAt(r.position)===32;)r.lineIndent+=1,r.position+=1;for(;r.position<r.length-1;)Rw(r);return r.documents}function Fw(t,e,r){e!==null&&typeof e=="object"&&typeof r=="undefined"&&(r=e,e=null);var i=Yf(t,r);if(typeof e!="function")return i;for(var n=0,s=i.length;n<s;n+=1)e(i[n])}function Ow(t,e){var r=Yf(t,e);if(r.length!==0){if(r.length===1)return r[0];throw new He("expected a single document in the stream, but found more")}}var kw=Fw,Tw=Ow,Vf={loadAll:kw,load:Tw},Kf=Object.prototype.toString,Zf=Object.prototype.hasOwnProperty,Ha=65279,Lw=9,dn=10,Bw=13,Pw=32,Iw=33,Nw=34,La=35,Mw=37,jw=38,$w=39,Hw=42,Jf=44,qw=45,os=58,Uw=61,Gw=62,zw=63,Ww=64,Xf=91,Qf=93,Yw=96,ep=123,Vw=124,tp=125,ke={};ke[0]="\\0";ke[7]="\\a";ke[8]="\\b";ke[9]="\\t";ke[10]="\\n";ke[11]="\\v";ke[12]="\\f";ke[13]="\\r";ke[27]="\\e";ke[34]='\\"';ke[92]="\\\\";ke[133]="\\N";ke[160]="\\_";ke[8232]="\\L";ke[8233]="\\P";var Kw=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],Zw=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function Jw(t,e){var r,i,n,s,o,a,u;if(e===null)return{};for(r={},i=Object.keys(e),n=0,s=i.length;n<s;n+=1)o=i[n],a=String(e[o]),o.slice(0,2)==="!!"&&(o="tag:yaml.org,2002:"+o.slice(2)),u=t.compiledTypeMap.fallback[o],u&&Zf.call(u.styleAliases,a)&&(a=u.styleAliases[a]),r[o]=a;return r}function Xw(t){var e,r,i;if(e=t.toString(16).toUpperCase(),t<=255)r="x",i=2;else if(t<=65535)r="u",i=4;else if(t<=4294967295)r="U",i=8;else throw new He("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+r+ve.repeat("0",i-e.length)+e}var Qw=1,mn=2;function eS(t){this.schema=t.schema||Ma,this.indent=Math.max(1,t.indent||2),this.noArrayIndent=t.noArrayIndent||!1,this.skipInvalid=t.skipInvalid||!1,this.flowLevel=ve.isNothing(t.flowLevel)?-1:t.flowLevel,this.styleMap=Jw(this.schema,t.styles||null),this.sortKeys=t.sortKeys||!1,this.lineWidth=t.lineWidth||80,this.noRefs=t.noRefs||!1,this.noCompatMode=t.noCompatMode||!1,this.condenseFlow=t.condenseFlow||!1,this.quotingType=t.quotingType==='"'?mn:Qw,this.forceQuotes=t.forceQuotes||!1,this.replacer=typeof t.replacer=="function"?t.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function hf(t,e){for(var r=ve.repeat(" ",e),i=0,n=-1,s="",o,a=t.length;i<a;)n=t.indexOf(`
26
26
  `,i),n===-1?(o=t.slice(i),i=a):(o=t.slice(i,n+1),i=n+1),o.length&&o!==`
27
27
  `&&(s+=r),s+=o;return s}function Ba(t,e){return`
@@ -37,15 +37,15 @@ ${i.message}`:y,F=[v,e,t].filter(Boolean).join(`
37
37
  `+t.slice(n,s),n=s+1),o=a;return u+=`
38
38
  `,t.length-n>e&&o>n?u+=t.slice(n,o)+`
39
39
  `+t.slice(o+1):u+=t.slice(n),u.slice(1)}function aS(t){for(var e="",r=0,i,n=0;n<t.length;r>=65536?n+=2:n++)r=fn(t,n),i=ke[r],!i&&gn(r)?(e+=t[n],r>=65536&&(e+=t[n+1])):e+=i||Xw(r);return e}function uS(t,e,r){var i="",n=t.tag,s,o,a;for(s=0,o=r.length;s<o;s+=1)a=r[s],t.replacer&&(a=t.replacer.call(r,String(s),a)),(Mt(t,e,a,!1,!1)||typeof a=="undefined"&&Mt(t,e,null,!1,!1))&&(i!==""&&(i+=","+(t.condenseFlow?"":" ")),i+=t.dump);t.tag=n,t.dump="["+i+"]"}function yf(t,e,r,i){var n="",s=t.tag,o,a,u;for(o=0,a=r.length;o<a;o+=1)u=r[o],t.replacer&&(u=t.replacer.call(r,String(o),u)),(Mt(t,e+1,u,!0,!0,!1,!0)||typeof u=="undefined"&&Mt(t,e+1,null,!0,!0,!1,!0))&&((!i||n!=="")&&(n+=Ba(t,e)),t.dump&&dn===t.dump.charCodeAt(0)?n+="-":n+="- ",n+=t.dump);t.tag=s,t.dump=n||"[]"}function lS(t,e,r){var i="",n=t.tag,s=Object.keys(r),o,a,u,l,c;for(o=0,a=s.length;o<a;o+=1)c="",i!==""&&(c+=", "),t.condenseFlow&&(c+='"'),u=s[o],l=r[u],t.replacer&&(l=t.replacer.call(r,u,l)),Mt(t,e,u,!1,!1)&&(t.dump.length>1024&&(c+="? "),c+=t.dump+(t.condenseFlow?'"':"")+":"+(t.condenseFlow?"":" "),Mt(t,e,l,!1,!1)&&(c+=t.dump,i+=c));t.tag=n,t.dump="{"+i+"}"}function cS(t,e,r,i){var n="",s=t.tag,o=Object.keys(r),a,u,l,c,f,h;if(t.sortKeys===!0)o.sort();else if(typeof t.sortKeys=="function")o.sort(t.sortKeys);else if(t.sortKeys)throw new He("sortKeys must be a boolean or a function");for(a=0,u=o.length;a<u;a+=1)h="",(!i||n!=="")&&(h+=Ba(t,e)),l=o[a],c=r[l],t.replacer&&(c=t.replacer.call(r,l,c)),Mt(t,e+1,l,!0,!0,!0)&&(f=t.tag!==null&&t.tag!=="?"||t.dump&&t.dump.length>1024,f&&(t.dump&&dn===t.dump.charCodeAt(0)?h+="?":h+="? "),h+=t.dump,f&&(h+=Ba(t,e)),Mt(t,e+1,c,!0,f)&&(t.dump&&dn===t.dump.charCodeAt(0)?h+=":":h+=": ",h+=t.dump,n+=h));t.tag=s,t.dump=n||"{}"}function Ef(t,e,r){var i,n,s,o,a,u;for(n=r?t.explicitTypes:t.implicitTypes,s=0,o=n.length;s<o;s+=1)if(a=n[s],(a.instanceOf||a.predicate)&&(!a.instanceOf||typeof e=="object"&&e instanceof a.instanceOf)&&(!a.predicate||a.predicate(e))){if(r?a.multi&&a.representName?t.tag=a.representName(e):t.tag=a.tag:t.tag="?",a.represent){if(u=t.styleMap[a.tag]||a.defaultStyle,Kf.call(a.represent)==="[object Function]")i=a.represent(e,u);else if(Zf.call(a.represent,u))i=a.represent[u](e,u);else throw new He("!<"+a.tag+'> tag resolver accepts not "'+u+'" style');t.dump=i}return!0}return!1}function Mt(t,e,r,i,n,s,o){t.tag=null,t.dump=r,Ef(t,r,!1)||Ef(t,r,!0);var a=Kf.call(t.dump),u=i,l;i&&(i=t.flowLevel<0||t.flowLevel>e);var c=a==="[object Object]"||a==="[object Array]",f,h;if(c&&(f=t.duplicates.indexOf(r),h=f!==-1),(t.tag!==null&&t.tag!=="?"||h||t.indent!==2&&e>0)&&(n=!1),h&&t.usedDuplicates[f])t.dump="*ref_"+f;else{if(c&&h&&!t.usedDuplicates[f]&&(t.usedDuplicates[f]=!0),a==="[object Object]")i&&Object.keys(t.dump).length!==0?(cS(t,e,t.dump,n),h&&(t.dump="&ref_"+f+t.dump)):(lS(t,e,t.dump),h&&(t.dump="&ref_"+f+" "+t.dump));else if(a==="[object Array]")i&&t.dump.length!==0?(t.noArrayIndent&&!o&&e>0?yf(t,e-1,t.dump,n):yf(t,e,t.dump,n),h&&(t.dump="&ref_"+f+t.dump)):(uS(t,e,t.dump),h&&(t.dump="&ref_"+f+" "+t.dump));else if(a==="[object String]")t.tag!=="?"&&sS(t,t.dump,e,s,u);else{if(a==="[object Undefined]")return!1;if(t.skipInvalid)return!1;throw new He("unacceptable kind of an object to dump "+a)}t.tag!==null&&t.tag!=="?"&&(l=encodeURI(t.tag[0]==="!"?t.tag.slice(1):t.tag).replace(/!/g,"%21"),t.tag[0]==="!"?l="!"+l:l.slice(0,18)==="tag:yaml.org,2002:"?l="!!"+l.slice(18):l="!<"+l+">",t.dump=l+" "+t.dump)}return!0}function hS(t,e){var r=[],i=[],n,s;for(Ia(t,r,i),n=0,s=i.length;n<s;n+=1)e.duplicates.push(r[i[n]]);e.usedDuplicates=new Array(s)}function Ia(t,e,r){var i,n,s;if(t!==null&&typeof t=="object")if(n=e.indexOf(t),n!==-1)r.indexOf(n)===-1&&r.push(n);else if(e.push(t),Array.isArray(t))for(n=0,s=t.length;n<s;n+=1)Ia(t[n],e,r);else for(i=Object.keys(t),n=0,s=i.length;n<s;n+=1)Ia(t[i[n]],e,r)}function fS(t,e){e=e||{};var r=new eS(e);r.noRefs||hS(t,r);var i=t;return r.replacer&&(i=r.replacer.call({"":i},"",i)),Mt(r,0,i,!0,!0)?r.dump+`
40
- `:""}var pS=fS,dS={dump:pS};function qa(t,e){return function(){throw new Error("Function yaml."+t+" is removed in js-yaml 4. Use yaml."+e+" instead, which is now safe by default.")}}var mS=Oe,gS=_f,yS=vf,ES=Of,DS=kf,bS=Ma,_S=Vf.load,wS=Vf.loadAll,SS=dS.dump,AS=He,vS={binary:If,float:Ff,map:Af,null:Cf,pairs:Mf,set:jf,timestamp:Bf,bool:xf,int:Rf,merge:Pf,omap:Nf,seq:Sf,str:wf},CS=qa("safeLoad","load"),xS=qa("safeLoadAll","loadAll"),RS=qa("safeDump","dump"),FS={Type:mS,Schema:gS,FAILSAFE_SCHEMA:yS,JSON_SCHEMA:ES,CORE_SCHEMA:DS,DEFAULT_SCHEMA:bS,load:_S,loadAll:wS,dump:SS,YAMLException:AS,types:vS,safeLoad:CS,safeLoadAll:xS,safeDump:RS},Ua=FS;var UC=J(Ns());var ne={};r_(ne,{bold:()=>PC,dimmed:()=>NC,error:()=>e0,grey:()=>MC,info:()=>BC,item:()=>jC,log:()=>fr,turboBlue:()=>wi,turboGradient:()=>LC,turboLoader:()=>Xm,turboRed:()=>Zm,underline:()=>IC,warn:()=>Qm,yellow:()=>Jm});var hr=J(require("chalk")),Wm=J(require("ora")),Ym=J(require("gradient-string")),Vm="#0099F7",Km="#F11712",TC="#FFFF00",LC=(0,Ym.default)(Vm,Km),wi=hr.default.hex(Vm),Zm=hr.default.hex(Km),Jm=hr.default.hex(TC),Xm=t=>(0,Wm.default)({text:t,spinner:{frames:[" ",wi("> "),wi(">> "),wi(">>>")]}}),BC=(...t)=>{fr(wi.bold(">>>"),...t)},PC=(...t)=>{fr(hr.default.bold(...t))},IC=(...t)=>{fr(hr.default.underline(...t))},NC=(...t)=>{fr(hr.default.dim(...t))},MC=(...t)=>{fr(hr.default.grey(...t))},jC=(...t)=>{fr(wi.bold(" \u2022"),...t)},fr=(...t)=>{console.log(...t)},Qm=(...t)=>{console.error(Jm.bold(">>>"),...t)},e0=(...t)=>{console.error(Zm.bold(">>>"),...t)};var Ng=J(require("os")),Mg=J(ki());async function pr(t,e=[],r){let i={cwd:Ng.default.tmpdir(),env:{COREPACK_ENABLE_STRICT:"0"},...r};try{let{stdout:n}=await(0,Mg.default)(t,e,i);return n.trim()}catch{return}}async function Gl(){let[t,e,r,i]=await Promise.all([pr("yarnpkg",["--version"]),pr("npm",["--version"]),pr("pnpm",["--version"]),pr("bun",["--version"])]);return{yarn:t,pnpm:r,npm:e,bun:i}}async function zl(){let[t,e,r,i]=await Promise.all([pr("yarnpkg",["global","bin"]),pr("npm",["config","get","prefix"]),pr("pnpm",["bin","--global"]),pr("bun",["pm","--g","bin"])]);return{yarn:t,pnpm:r,npm:e,bun:i}}var NR=J(require("fs-extra"));var MR=J(require("path")),jR=J(require("fs-extra")),$R=J(require("chalk"));var ND=require("stream"),MD=require("util"),wk=require("path"),Sk=require("os"),jD=require("fs"),Ak=J(ID());var _I=(0,MD.promisify)(ND.Stream.pipeline);var $D=require("fs-extra");var Bk=J(require("path")),Pk=J(YD()),Ik=J(require("chalk")),kh=require("fs-extra");var Zb=require("commander");var ia={name:"@turbo/codemod",version:"2.0.0-canary.0",description:"Provides Codemod transformations to help upgrade your Turborepo codebase when a feature is deprecated.",homepage:"https://turbo.build/repo",license:"MIT",repository:{type:"git",url:"https://github.com/vercel/turbo",directory:"packages/turbo-codemod"},bugs:{url:"https://github.com/vercel/turbo/issues"},bin:"dist/cli.js",scripts:{build:"tsup",test:"jest",lint:"eslint src/","check-types":"tsc --noEmit","add-transformer":"plop","lint:prettier":"prettier -c . --cache --ignore-path=../../.prettierignore"},dependencies:{axios:"0.27.2",chalk:"2.4.2",commander:"^9.5.0",diff:"^5.1.0","find-up":"4.1.0","fs-extra":"^10.0.0","gradient-string":"^2.0.0",inquirer:"^8.2.4","inquirer-file-tree-selection-prompt":"^1.0.19","is-git-clean":"^1.1.0",ora:"4.1.1",semver:"^7.3.7","update-check":"^1.5.4"},devDependencies:{"@turbo/eslint-config":"workspace:*","@turbo/gen":"workspace:*","@turbo/test-utils":"workspace:*","@turbo/tsconfig":"workspace:*","@turbo/types":"workspace:*","@turbo/utils":"workspace:*","@turbo/workspaces":"workspace:*","@types/chalk-animation":"^1.6.0","@types/diff":"^5.0.2","@types/fs-extra":"^9.0.13","@types/gradient-string":"^1.1.2","@types/inquirer":"^8.2.0","@types/jest":"^27.4.0","@types/node":"^18.17.2","@types/semver":"^7.3.9","@types/uuid":"^9.0.0",deepmerge:"^4.2.2",jest:"^27.4.3",plop:"^3.1.1",semver:"^7.3.5","ts-jest":"^27.1.1",tsup:"^6.7.0",typescript:"5.3.3"},files:["dist"],publishConfig:{access:"public"}};var an=J(require("os")),zb=require("child_process"),$e=J(require("chalk")),Wb=require("inquirer");var Fr=J(require("chalk"),1),ub=J(require("ora"),1),lb=J(require("gradient-string"),1);var PT=J(ki(),1),tN=require("fs-extra");var oN=J(Ns(),1),uN=require("fs-extra"),cN=require("fs-extra"),fN=require("chalk"),db=require("stream"),mb=require("util"),gN=require("fs-extra"),bN=require("chalk"),wN=require("fs-extra"),ri=J(require("path"),1),qe=require("fs-extra"),gb=J(ki(),1),yb=J(require("path"),1),Eb=require("fs-extra"),Db=J(require("chalk"),1),rr=J(require("path"),1),bb=J(ki(),1),rt=require("fs-extra"),_b=J(Ns(),1);var Yn=J(require("path"),1),Tt=require("fs-extra"),nn=J(require("path"),1),Lt=require("fs-extra"),Vn=J(require("path"),1),Bt=require("fs-extra"),gL=J(require("chalk"),1),yL=J(require("gradient-string"),1),EL=J(ki(),1),DL=J(require("ora"),1),bL=require("semver"),_L=J(require("chalk"),1),Mk=Object.create,Bh=Object.defineProperty,jk=Object.getOwnPropertyDescriptor,$k=Object.getOwnPropertyNames,Hk=Object.getPrototypeOf,qk=Object.prototype.hasOwnProperty,re=(t=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(t,{get:(e,r)=>(typeof require!="undefined"?require:e)[r]}):t)(function(t){if(typeof require!="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+t+'" is not supported')}),Uk=(t,e)=>()=>(t&&(e=t(t=0)),e),te=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Gk=(t,e)=>{for(var r in e)Bh(t,r,{get:e[r],enumerable:!0})},zk=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of $k(e))!qk.call(t,n)&&n!==r&&Bh(t,n,{get:()=>e[n],enumerable:!(i=jk(e,n))||i.enumerable});return t},oa=(t,e,r)=>(r=t!=null?Mk(Hk(t)):{},zk(e||!t||!t.__esModule?Bh(r,"default",{value:t,enumerable:!0}):r,t)),W=Uk(()=>{}),Wk=te((t,e)=>{W();function r(i){return e.exports=r=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},e.exports.__esModule=!0,e.exports.default=e.exports,r(i)}e.exports=r,e.exports.__esModule=!0,e.exports.default=e.exports}),Yk=te((t,e)=>{W();var r=Wk().default;function i(){"use strict";e.exports=i=function(){return s},e.exports.__esModule=!0,e.exports.default=e.exports;var n,s={},o=Object.prototype,a=o.hasOwnProperty,u=Object.defineProperty||function(P,d,m){P[d]=m.value},l=typeof Symbol=="function"?Symbol:{},c=l.iterator||"@@iterator",f=l.asyncIterator||"@@asyncIterator",h=l.toStringTag||"@@toStringTag";function p(P,d,m){return Object.defineProperty(P,d,{value:m,enumerable:!0,configurable:!0,writable:!0}),P[d]}try{p({},"")}catch{p=function(P,d,m){return P[d]=m}}function g(P,d,m,D){var A=d&&d.prototype instanceof x?d:x,w=Object.create(A.prototype),I=new j(D||[]);return u(w,"_invoke",{value:K(P,m,I)}),w}function y(P,d,m){try{return{type:"normal",arg:P.call(d,m)}}catch(D){return{type:"throw",arg:D}}}s.wrap=g;var E="suspendedStart",v="suspendedYield",F="executing",O="completed",R={};function x(){}function L(){}function b(){}var S={};p(S,c,function(){return this});var N=Object.getPrototypeOf,H=N&&N(N(z([])));H&&H!==o&&a.call(H,c)&&(S=H);var T=b.prototype=x.prototype=Object.create(S);function U(P){["next","throw","return"].forEach(function(d){p(P,d,function(m){return this._invoke(d,m)})})}function V(P,d){function m(A,w,I,M){var Z=y(P[A],P,w);if(Z.type!=="throw"){var q=Z.arg,Q=q.value;return Q&&r(Q)=="object"&&a.call(Q,"__await")?d.resolve(Q.__await).then(function(G){m("next",G,I,M)},function(G){m("throw",G,I,M)}):d.resolve(Q).then(function(G){q.value=G,I(q)},function(G){return m("throw",G,I,M)})}M(Z.arg)}var D;u(this,"_invoke",{value:function(A,w){function I(){return new d(function(M,Z){m(A,w,M,Z)})}return D=D?D.then(I,I):I()}})}function K(P,d,m){var D=E;return function(A,w){if(D===F)throw new Error("Generator is already running");if(D===O){if(A==="throw")throw w;return{value:n,done:!0}}for(m.method=A,m.arg=w;;){var I=m.delegate;if(I){var M=B(I,m);if(M){if(M===R)continue;return M}}if(m.method==="next")m.sent=m._sent=m.arg;else if(m.method==="throw"){if(D===E)throw D=O,m.arg;m.dispatchException(m.arg)}else m.method==="return"&&m.abrupt("return",m.arg);D=F;var Z=y(P,d,m);if(Z.type==="normal"){if(D=m.done?O:v,Z.arg===R)continue;return{value:Z.arg,done:m.done}}Z.type==="throw"&&(D=O,m.method="throw",m.arg=Z.arg)}}}function B(P,d){var m=d.method,D=P.iterator[m];if(D===n)return d.delegate=null,m==="throw"&&P.iterator.return&&(d.method="return",d.arg=n,B(P,d),d.method==="throw")||m!=="return"&&(d.method="throw",d.arg=new TypeError("The iterator does not provide a '"+m+"' method")),R;var A=y(D,P.iterator,d.arg);if(A.type==="throw")return d.method="throw",d.arg=A.arg,d.delegate=null,R;var w=A.arg;return w?w.done?(d[P.resultName]=w.value,d.next=P.nextLoc,d.method!=="return"&&(d.method="next",d.arg=n),d.delegate=null,R):w:(d.method="throw",d.arg=new TypeError("iterator result is not an object"),d.delegate=null,R)}function C(P){var d={tryLoc:P[0]};1 in P&&(d.catchLoc=P[1]),2 in P&&(d.finallyLoc=P[2],d.afterLoc=P[3]),this.tryEntries.push(d)}function k(P){var d=P.completion||{};d.type="normal",delete d.arg,P.completion=d}function j(P){this.tryEntries=[{tryLoc:"root"}],P.forEach(C,this),this.reset(!0)}function z(P){if(P||P===""){var d=P[c];if(d)return d.call(P);if(typeof P.next=="function")return P;if(!isNaN(P.length)){var m=-1,D=function A(){for(;++m<P.length;)if(a.call(P,m))return A.value=P[m],A.done=!1,A;return A.value=n,A.done=!0,A};return D.next=D}}throw new TypeError(r(P)+" is not iterable")}return L.prototype=b,u(T,"constructor",{value:b,configurable:!0}),u(b,"constructor",{value:L,configurable:!0}),L.displayName=p(b,h,"GeneratorFunction"),s.isGeneratorFunction=function(P){var d=typeof P=="function"&&P.constructor;return!!d&&(d===L||(d.displayName||d.name)==="GeneratorFunction")},s.mark=function(P){return Object.setPrototypeOf?Object.setPrototypeOf(P,b):(P.__proto__=b,p(P,h,"GeneratorFunction")),P.prototype=Object.create(T),P},s.awrap=function(P){return{__await:P}},U(V.prototype),p(V.prototype,f,function(){return this}),s.AsyncIterator=V,s.async=function(P,d,m,D,A){A===void 0&&(A=Promise);var w=new V(g(P,d,m,D),A);return s.isGeneratorFunction(d)?w:w.next().then(function(I){return I.done?I.value:w.next()})},U(T),p(T,h,"Generator"),p(T,c,function(){return this}),p(T,"toString",function(){return"[object Generator]"}),s.keys=function(P){var d=Object(P),m=[];for(var D in d)m.push(D);return m.reverse(),function A(){for(;m.length;){var w=m.pop();if(w in d)return A.value=w,A.done=!1,A}return A.done=!0,A}},s.values=z,j.prototype={constructor:j,reset:function(P){if(this.prev=0,this.next=0,this.sent=this._sent=n,this.done=!1,this.delegate=null,this.method="next",this.arg=n,this.tryEntries.forEach(k),!P)for(var d in this)d.charAt(0)==="t"&&a.call(this,d)&&!isNaN(+d.slice(1))&&(this[d]=n)},stop:function(){this.done=!0;var P=this.tryEntries[0].completion;if(P.type==="throw")throw P.arg;return this.rval},dispatchException:function(P){if(this.done)throw P;var d=this;function m(Z,q){return w.type="throw",w.arg=P,d.next=Z,q&&(d.method="next",d.arg=n),!!q}for(var D=this.tryEntries.length-1;D>=0;--D){var A=this.tryEntries[D],w=A.completion;if(A.tryLoc==="root")return m("end");if(A.tryLoc<=this.prev){var I=a.call(A,"catchLoc"),M=a.call(A,"finallyLoc");if(I&&M){if(this.prev<A.catchLoc)return m(A.catchLoc,!0);if(this.prev<A.finallyLoc)return m(A.finallyLoc)}else if(I){if(this.prev<A.catchLoc)return m(A.catchLoc,!0)}else{if(!M)throw new Error("try statement without catch or finally");if(this.prev<A.finallyLoc)return m(A.finallyLoc)}}}},abrupt:function(P,d){for(var m=this.tryEntries.length-1;m>=0;--m){var D=this.tryEntries[m];if(D.tryLoc<=this.prev&&a.call(D,"finallyLoc")&&this.prev<D.finallyLoc){var A=D;break}}A&&(P==="break"||P==="continue")&&A.tryLoc<=d&&d<=A.finallyLoc&&(A=null);var w=A?A.completion:{};return w.type=P,w.arg=d,A?(this.method="next",this.next=A.finallyLoc,R):this.complete(w)},complete:function(P,d){if(P.type==="throw")throw P.arg;return P.type==="break"||P.type==="continue"?this.next=P.arg:P.type==="return"?(this.rval=this.arg=P.arg,this.method="return",this.next="end"):P.type==="normal"&&d&&(this.next=d),R},finish:function(P){for(var d=this.tryEntries.length-1;d>=0;--d){var m=this.tryEntries[d];if(m.finallyLoc===P)return this.complete(m.completion,m.afterLoc),k(m),R}},catch:function(P){for(var d=this.tryEntries.length-1;d>=0;--d){var m=this.tryEntries[d];if(m.tryLoc===P){var D=m.completion;if(D.type==="throw"){var A=D.arg;k(m)}return A}}throw new Error("illegal catch attempt")},delegateYield:function(P,d,m){return this.delegate={iterator:z(P),resultName:d,nextLoc:m},this.method==="next"&&(this.arg=n),R}},s}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports}),Vk=te((t,e)=>{W();var r=Yk()();e.exports=r;try{regeneratorRuntime=r}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}}),Kk=te((t,e)=>{"use strict";W();var r=(i,...n)=>new Promise(s=>{s(i(...n))});e.exports=r,e.exports.default=r}),Zk=te((t,e)=>{"use strict";W();var r=Kk(),i=n=>{if(!((Number.isInteger(n)||n===1/0)&&n>0))return Promise.reject(new TypeError("Expected `concurrency` to be a number from 1 and up"));let s=[],o=0,a=()=>{o--,s.length>0&&s.shift()()},u=(f,h,...p)=>{o++;let g=r(f,...p);h(g),g.then(a,a)},l=(f,h,...p)=>{o<n?u(f,h,...p):s.push(u.bind(null,f,h,...p))},c=(f,...h)=>new Promise(p=>l(f,p,...h));return Object.defineProperties(c,{activeCount:{get:()=>o},pendingCount:{get:()=>s.length},clearQueue:{value:()=>{s.length=0}}}),c};e.exports=i,e.exports.default=i}),Jk=te((t,e)=>{"use strict";W();var r=Zk(),i=class extends Error{constructor(a){super(),this.value=a}},n=async(a,u)=>u(await a),s=async a=>{let u=await Promise.all(a);if(u[1]===!0)throw new i(u[0]);return!1},o=async(a,u,l)=>{l={concurrency:1/0,preserveOrder:!0,...l};let c=r(l.concurrency),f=[...a].map(p=>[p,c(n,p,u)]),h=r(l.preserveOrder?1:1/0);try{await Promise.all(f.map(p=>h(s,p)))}catch(p){if(p instanceof i)return p.value;throw p}};e.exports=o,e.exports.default=o}),Xk=te((t,e)=>{"use strict";W();var r=re("path"),i=re("fs"),{promisify:n}=re("util"),s=Jk(),o=n(i.stat),a=n(i.lstat),u={directory:"isDirectory",file:"isFile"};function l({type:f}){if(!(f in u))throw new Error(`Invalid type specified: ${f}`)}var c=(f,h)=>f===void 0||h[u[f]]();e.exports=async(f,h)=>{h={cwd:process.cwd(),type:"file",allowSymlinks:!0,...h},l(h);let p=h.allowSymlinks?o:a;return s(f,async g=>{try{let y=await p(r.resolve(h.cwd,g));return c(h.type,y)}catch{return!1}},h)},e.exports.sync=(f,h)=>{h={cwd:process.cwd(),allowSymlinks:!0,type:"file",...h},l(h);let p=h.allowSymlinks?i.statSync:i.lstatSync;for(let g of f)try{let y=p(r.resolve(h.cwd,g));if(c(h.type,y))return g}catch{}}}),Qk=te((t,e)=>{"use strict";W();var r=re("fs"),{promisify:i}=re("util"),n=i(r.access);e.exports=async s=>{try{return await n(s),!0}catch{return!1}},e.exports.sync=s=>{try{return r.accessSync(s),!0}catch{return!1}}}),eT=te((t,e)=>{"use strict";W();var r=re("path"),i=Xk(),n=Qk(),s=Symbol("findUp.stop");e.exports=async(o,a={})=>{let u=r.resolve(a.cwd||""),{root:l}=r.parse(u),c=[].concat(o),f=async h=>{if(typeof o!="function")return i(c,h);let p=await o(h.cwd);return typeof p=="string"?i([p],h):p};for(;;){let h=await f({...a,cwd:u});if(h===s)return;if(h)return r.resolve(u,h);if(u===l)return;u=r.dirname(u)}},e.exports.sync=(o,a={})=>{let u=r.resolve(a.cwd||""),{root:l}=r.parse(u),c=[].concat(o),f=h=>{if(typeof o!="function")return i.sync(c,h);let p=o(h.cwd);return typeof p=="string"?i.sync([p],h):p};for(;;){let h=f({...a,cwd:u});if(h===s)return;if(h)return r.resolve(u,h);if(u===l)return;u=r.dirname(u)}},e.exports.exists=n,e.exports.sync.exists=n.sync,e.exports.stop=s}),Kn=te((t,e)=>{"use strict";W();var r=new Map([["C","cwd"],["f","file"],["z","gzip"],["P","preservePaths"],["U","unlink"],["strip-components","strip"],["stripComponents","strip"],["keep-newer","newer"],["keepNewer","newer"],["keep-newer-files","newer"],["keepNewerFiles","newer"],["k","keep"],["keep-existing","keep"],["keepExisting","keep"],["m","noMtime"],["no-mtime","noMtime"],["p","preserveOwner"],["L","follow"],["h","follow"]]);e.exports=i=>i?Object.keys(i).map(n=>[r.has(n)?r.get(n):n,i[n]]).reduce((n,s)=>(n[s[0]]=s[1],n),Object.create(null)):{}}),Ph=te((t,e)=>{"use strict";W();var r=typeof process=="object"&&process?process:{stdout:null,stderr:null},i=re("events"),n=re("stream"),s=re("string_decoder").StringDecoder,o=Symbol("EOF"),a=Symbol("maybeEmitEnd"),u=Symbol("emittedEnd"),l=Symbol("emittingEnd"),c=Symbol("emittedError"),f=Symbol("closed"),h=Symbol("read"),p=Symbol("flush"),g=Symbol("flushChunk"),y=Symbol("encoding"),E=Symbol("decoder"),v=Symbol("flowing"),F=Symbol("paused"),O=Symbol("resume"),R=Symbol("buffer"),x=Symbol("pipes"),L=Symbol("bufferLength"),b=Symbol("bufferPush"),S=Symbol("bufferShift"),N=Symbol("objectMode"),H=Symbol("destroyed"),T=Symbol("emitData"),U=Symbol("emitEnd"),V=Symbol("emitEnd2"),K=Symbol("async"),B=A=>Promise.resolve().then(A),C=global._MP_NO_ITERATOR_SYMBOLS_!=="1",k=C&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),j=C&&Symbol.iterator||Symbol("iterator not implemented"),z=A=>A==="end"||A==="finish"||A==="prefinish",P=A=>A instanceof ArrayBuffer||typeof A=="object"&&A.constructor&&A.constructor.name==="ArrayBuffer"&&A.byteLength>=0,d=A=>!Buffer.isBuffer(A)&&ArrayBuffer.isView(A),m=class{constructor(A,w,I){this.src=A,this.dest=w,this.opts=I,this.ondrain=()=>A[O](),w.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},D=class extends m{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(A,w,I){super(A,w,I),this.proxyErrors=M=>w.emit("error",M),A.on("error",this.proxyErrors)}};e.exports=class KD extends n{constructor(w){super(),this[v]=!1,this[F]=!1,this[x]=[],this[R]=[],this[N]=w&&w.objectMode||!1,this[N]?this[y]=null:this[y]=w&&w.encoding||null,this[y]==="buffer"&&(this[y]=null),this[K]=w&&!!w.async||!1,this[E]=this[y]?new s(this[y]):null,this[o]=!1,this[u]=!1,this[l]=!1,this[f]=!1,this[c]=null,this.writable=!0,this.readable=!0,this[L]=0,this[H]=!1,w&&w.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[R]}),w&&w.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[x]})}get bufferLength(){return this[L]}get encoding(){return this[y]}set encoding(w){if(this[N])throw new Error("cannot set encoding in objectMode");if(this[y]&&w!==this[y]&&(this[E]&&this[E].lastNeed||this[L]))throw new Error("cannot change encoding");this[y]!==w&&(this[E]=w?new s(w):null,this[R].length&&(this[R]=this[R].map(I=>this[E].write(I)))),this[y]=w}setEncoding(w){this.encoding=w}get objectMode(){return this[N]}set objectMode(w){this[N]=this[N]||!!w}get async(){return this[K]}set async(w){this[K]=this[K]||!!w}write(w,I,M){if(this[o])throw new Error("write after end");if(this[H])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof I=="function"&&(M=I,I="utf8"),I||(I="utf8");let Z=this[K]?B:q=>q();return!this[N]&&!Buffer.isBuffer(w)&&(d(w)?w=Buffer.from(w.buffer,w.byteOffset,w.byteLength):P(w)?w=Buffer.from(w):typeof w!="string"&&(this.objectMode=!0)),this[N]?(this.flowing&&this[L]!==0&&this[p](!0),this.flowing?this.emit("data",w):this[b](w),this[L]!==0&&this.emit("readable"),M&&Z(M),this.flowing):w.length?(typeof w=="string"&&!(I===this[y]&&!this[E].lastNeed)&&(w=Buffer.from(w,I)),Buffer.isBuffer(w)&&this[y]&&(w=this[E].write(w)),this.flowing&&this[L]!==0&&this[p](!0),this.flowing?this.emit("data",w):this[b](w),this[L]!==0&&this.emit("readable"),M&&Z(M),this.flowing):(this[L]!==0&&this.emit("readable"),M&&Z(M),this.flowing)}read(w){if(this[H])return null;if(this[L]===0||w===0||w>this[L])return this[a](),null;this[N]&&(w=null),this[R].length>1&&!this[N]&&(this.encoding?this[R]=[this[R].join("")]:this[R]=[Buffer.concat(this[R],this[L])]);let I=this[h](w||null,this[R][0]);return this[a](),I}[h](w,I){return w===I.length||w===null?this[S]():(this[R][0]=I.slice(w),I=I.slice(0,w),this[L]-=w),this.emit("data",I),!this[R].length&&!this[o]&&this.emit("drain"),I}end(w,I,M){return typeof w=="function"&&(M=w,w=null),typeof I=="function"&&(M=I,I="utf8"),w&&this.write(w,I),M&&this.once("end",M),this[o]=!0,this.writable=!1,(this.flowing||!this[F])&&this[a](),this}[O](){this[H]||(this[F]=!1,this[v]=!0,this.emit("resume"),this[R].length?this[p]():this[o]?this[a]():this.emit("drain"))}resume(){return this[O]()}pause(){this[v]=!1,this[F]=!0}get destroyed(){return this[H]}get flowing(){return this[v]}get paused(){return this[F]}[b](w){this[N]?this[L]+=1:this[L]+=w.length,this[R].push(w)}[S](){return this[R].length&&(this[N]?this[L]-=1:this[L]-=this[R][0].length),this[R].shift()}[p](w){do;while(this[g](this[S]()));!w&&!this[R].length&&!this[o]&&this.emit("drain")}[g](w){return w?(this.emit("data",w),this.flowing):!1}pipe(w,I){if(this[H])return;let M=this[u];return I=I||{},w===r.stdout||w===r.stderr?I.end=!1:I.end=I.end!==!1,I.proxyErrors=!!I.proxyErrors,M?I.end&&w.end():(this[x].push(I.proxyErrors?new D(this,w,I):new m(this,w,I)),this[K]?B(()=>this[O]()):this[O]()),w}unpipe(w){let I=this[x].find(M=>M.dest===w);I&&(this[x].splice(this[x].indexOf(I),1),I.unpipe())}addListener(w,I){return this.on(w,I)}on(w,I){let M=super.on(w,I);return w==="data"&&!this[x].length&&!this.flowing?this[O]():w==="readable"&&this[L]!==0?super.emit("readable"):z(w)&&this[u]?(super.emit(w),this.removeAllListeners(w)):w==="error"&&this[c]&&(this[K]?B(()=>I.call(this,this[c])):I.call(this,this[c])),M}get emittedEnd(){return this[u]}[a](){!this[l]&&!this[u]&&!this[H]&&this[R].length===0&&this[o]&&(this[l]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[f]&&this.emit("close"),this[l]=!1)}emit(w,I,...M){if(w!=="error"&&w!=="close"&&w!==H&&this[H])return;if(w==="data")return I?this[K]?B(()=>this[T](I)):this[T](I):!1;if(w==="end")return this[U]();if(w==="close"){if(this[f]=!0,!this[u]&&!this[H])return;let q=super.emit("close");return this.removeAllListeners("close"),q}else if(w==="error"){this[c]=I;let q=super.emit("error",I);return this[a](),q}else if(w==="resume"){let q=super.emit("resume");return this[a](),q}else if(w==="finish"||w==="prefinish"){let q=super.emit(w);return this.removeAllListeners(w),q}let Z=super.emit(w,I,...M);return this[a](),Z}[T](w){for(let M of this[x])M.dest.write(w)===!1&&this.pause();let I=super.emit("data",w);return this[a](),I}[U](){this[u]||(this[u]=!0,this.readable=!1,this[K]?B(()=>this[V]()):this[V]())}[V](){if(this[E]){let I=this[E].end();if(I){for(let M of this[x])M.dest.write(I);super.emit("data",I)}}for(let I of this[x])I.end();let w=super.emit("end");return this.removeAllListeners("end"),w}collect(){let w=[];this[N]||(w.dataLength=0);let I=this.promise();return this.on("data",M=>{w.push(M),this[N]||(w.dataLength+=M.length)}),I.then(()=>w)}concat(){return this[N]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(w=>this[N]?Promise.reject(new Error("cannot concat in objectMode")):this[y]?w.join(""):Buffer.concat(w,w.dataLength))}promise(){return new Promise((w,I)=>{this.on(H,()=>I(new Error("stream destroyed"))),this.on("error",M=>I(M)),this.on("end",()=>w())})}[k](){return{next:()=>{let w=this.read();if(w!==null)return Promise.resolve({done:!1,value:w});if(this[o])return Promise.resolve({done:!0});let I=null,M=null,Z=ie=>{this.removeListener("data",q),this.removeListener("end",Q),M(ie)},q=ie=>{this.removeListener("error",Z),this.removeListener("end",Q),this.pause(),I({value:ie,done:!!this[o]})},Q=()=>{this.removeListener("error",Z),this.removeListener("data",q),I({done:!0})},G=()=>Z(new Error("stream destroyed"));return new Promise((ie,ce)=>{M=ce,I=ie,this.once(H,G),this.once("error",Z),this.once("end",Q),this.once("data",q)})}}}[j](){return{next:()=>{let w=this.read();return{value:w,done:w===null}}}}destroy(w){return this[H]?(w?this.emit("error",w):this.emit(H),this):(this[H]=!0,this[R].length=0,this[L]=0,typeof this.close=="function"&&!this[f]&&this.close(),w?this.emit("error",w):this.emit(H),this)}static isStream(w){return!!w&&(w instanceof KD||w instanceof n||w instanceof i&&(typeof w.pipe=="function"||typeof w.write=="function"&&typeof w.end=="function"))}}}),tT=te((t,e)=>{W();var r=re("zlib").constants||{ZLIB_VERNUM:4736};e.exports=Object.freeze(Object.assign(Object.create(null),{Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_VERSION_ERROR:-6,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,DEFLATE:1,INFLATE:2,GZIP:3,GUNZIP:4,DEFLATERAW:5,INFLATERAW:6,UNZIP:7,BROTLI_DECODE:8,BROTLI_ENCODE:9,Z_MIN_WINDOWBITS:8,Z_MAX_WINDOWBITS:15,Z_DEFAULT_WINDOWBITS:15,Z_MIN_CHUNK:64,Z_MAX_CHUNK:1/0,Z_DEFAULT_CHUNK:16384,Z_MIN_MEMLEVEL:1,Z_MAX_MEMLEVEL:9,Z_DEFAULT_MEMLEVEL:8,Z_MIN_LEVEL:-1,Z_MAX_LEVEL:9,Z_DEFAULT_LEVEL:-1,BROTLI_OPERATION_PROCESS:0,BROTLI_OPERATION_FLUSH:1,BROTLI_OPERATION_FINISH:2,BROTLI_OPERATION_EMIT_METADATA:3,BROTLI_MODE_GENERIC:0,BROTLI_MODE_TEXT:1,BROTLI_MODE_FONT:2,BROTLI_DEFAULT_MODE:0,BROTLI_MIN_QUALITY:0,BROTLI_MAX_QUALITY:11,BROTLI_DEFAULT_QUALITY:11,BROTLI_MIN_WINDOW_BITS:10,BROTLI_MAX_WINDOW_BITS:24,BROTLI_LARGE_MAX_WINDOW_BITS:30,BROTLI_DEFAULT_WINDOW:22,BROTLI_MIN_INPUT_BLOCK_BITS:16,BROTLI_MAX_INPUT_BLOCK_BITS:24,BROTLI_PARAM_MODE:0,BROTLI_PARAM_QUALITY:1,BROTLI_PARAM_LGWIN:2,BROTLI_PARAM_LGBLOCK:3,BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING:4,BROTLI_PARAM_SIZE_HINT:5,BROTLI_PARAM_LARGE_WINDOW:6,BROTLI_PARAM_NPOSTFIX:7,BROTLI_PARAM_NDIRECT:8,BROTLI_DECODER_RESULT_ERROR:0,BROTLI_DECODER_RESULT_SUCCESS:1,BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT:2,BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION:0,BROTLI_DECODER_PARAM_LARGE_WINDOW:1,BROTLI_DECODER_NO_ERROR:0,BROTLI_DECODER_SUCCESS:1,BROTLI_DECODER_NEEDS_MORE_INPUT:2,BROTLI_DECODER_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE:-1,BROTLI_DECODER_ERROR_FORMAT_RESERVED:-2,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE:-3,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET:-4,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME:-5,BROTLI_DECODER_ERROR_FORMAT_CL_SPACE:-6,BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE:-7,BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT:-8,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1:-9,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2:-10,BROTLI_DECODER_ERROR_FORMAT_TRANSFORM:-11,BROTLI_DECODER_ERROR_FORMAT_DICTIONARY:-12,BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS:-13,BROTLI_DECODER_ERROR_FORMAT_PADDING_1:-14,BROTLI_DECODER_ERROR_FORMAT_PADDING_2:-15,BROTLI_DECODER_ERROR_FORMAT_DISTANCE:-16,BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET:-19,BROTLI_DECODER_ERROR_INVALID_ARGUMENTS:-20,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES:-21,BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS:-22,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP:-25,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1:-26,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2:-27,BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES:-30,BROTLI_DECODER_ERROR_UNREACHABLE:-31},r))}),ZD=te((t,e)=>{"use strict";W();var r=typeof process=="object"&&process?process:{stdout:null,stderr:null},i=re("events"),n=re("stream"),s=re("string_decoder").StringDecoder,o=Symbol("EOF"),a=Symbol("maybeEmitEnd"),u=Symbol("emittedEnd"),l=Symbol("emittingEnd"),c=Symbol("emittedError"),f=Symbol("closed"),h=Symbol("read"),p=Symbol("flush"),g=Symbol("flushChunk"),y=Symbol("encoding"),E=Symbol("decoder"),v=Symbol("flowing"),F=Symbol("paused"),O=Symbol("resume"),R=Symbol("bufferLength"),x=Symbol("bufferPush"),L=Symbol("bufferShift"),b=Symbol("objectMode"),S=Symbol("destroyed"),N=Symbol("emitData"),H=Symbol("emitEnd"),T=Symbol("emitEnd2"),U=Symbol("async"),V=m=>Promise.resolve().then(m),K=global._MP_NO_ITERATOR_SYMBOLS_!=="1",B=K&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),C=K&&Symbol.iterator||Symbol("iterator not implemented"),k=m=>m==="end"||m==="finish"||m==="prefinish",j=m=>m instanceof ArrayBuffer||typeof m=="object"&&m.constructor&&m.constructor.name==="ArrayBuffer"&&m.byteLength>=0,z=m=>!Buffer.isBuffer(m)&&ArrayBuffer.isView(m),P=class{constructor(m,D,A){this.src=m,this.dest=D,this.opts=A,this.ondrain=()=>m[O](),D.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},d=class extends P{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(m,D,A){super(m,D,A),this.proxyErrors=w=>D.emit("error",w),m.on("error",this.proxyErrors)}};e.exports=class JD extends n{constructor(D){super(),this[v]=!1,this[F]=!1,this.pipes=[],this.buffer=[],this[b]=D&&D.objectMode||!1,this[b]?this[y]=null:this[y]=D&&D.encoding||null,this[y]==="buffer"&&(this[y]=null),this[U]=D&&!!D.async||!1,this[E]=this[y]?new s(this[y]):null,this[o]=!1,this[u]=!1,this[l]=!1,this[f]=!1,this[c]=null,this.writable=!0,this.readable=!0,this[R]=0,this[S]=!1}get bufferLength(){return this[R]}get encoding(){return this[y]}set encoding(D){if(this[b])throw new Error("cannot set encoding in objectMode");if(this[y]&&D!==this[y]&&(this[E]&&this[E].lastNeed||this[R]))throw new Error("cannot change encoding");this[y]!==D&&(this[E]=D?new s(D):null,this.buffer.length&&(this.buffer=this.buffer.map(A=>this[E].write(A)))),this[y]=D}setEncoding(D){this.encoding=D}get objectMode(){return this[b]}set objectMode(D){this[b]=this[b]||!!D}get async(){return this[U]}set async(D){this[U]=this[U]||!!D}write(D,A,w){if(this[o])throw new Error("write after end");if(this[S])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof A=="function"&&(w=A,A="utf8"),A||(A="utf8");let I=this[U]?V:M=>M();return!this[b]&&!Buffer.isBuffer(D)&&(z(D)?D=Buffer.from(D.buffer,D.byteOffset,D.byteLength):j(D)?D=Buffer.from(D):typeof D!="string"&&(this.objectMode=!0)),this[b]?(this.flowing&&this[R]!==0&&this[p](!0),this.flowing?this.emit("data",D):this[x](D),this[R]!==0&&this.emit("readable"),w&&I(w),this.flowing):D.length?(typeof D=="string"&&!(A===this[y]&&!this[E].lastNeed)&&(D=Buffer.from(D,A)),Buffer.isBuffer(D)&&this[y]&&(D=this[E].write(D)),this.flowing&&this[R]!==0&&this[p](!0),this.flowing?this.emit("data",D):this[x](D),this[R]!==0&&this.emit("readable"),w&&I(w),this.flowing):(this[R]!==0&&this.emit("readable"),w&&I(w),this.flowing)}read(D){if(this[S])return null;if(this[R]===0||D===0||D>this[R])return this[a](),null;this[b]&&(D=null),this.buffer.length>1&&!this[b]&&(this.encoding?this.buffer=[this.buffer.join("")]:this.buffer=[Buffer.concat(this.buffer,this[R])]);let A=this[h](D||null,this.buffer[0]);return this[a](),A}[h](D,A){return D===A.length||D===null?this[L]():(this.buffer[0]=A.slice(D),A=A.slice(0,D),this[R]-=D),this.emit("data",A),!this.buffer.length&&!this[o]&&this.emit("drain"),A}end(D,A,w){return typeof D=="function"&&(w=D,D=null),typeof A=="function"&&(w=A,A="utf8"),D&&this.write(D,A),w&&this.once("end",w),this[o]=!0,this.writable=!1,(this.flowing||!this[F])&&this[a](),this}[O](){this[S]||(this[F]=!1,this[v]=!0,this.emit("resume"),this.buffer.length?this[p]():this[o]?this[a]():this.emit("drain"))}resume(){return this[O]()}pause(){this[v]=!1,this[F]=!0}get destroyed(){return this[S]}get flowing(){return this[v]}get paused(){return this[F]}[x](D){this[b]?this[R]+=1:this[R]+=D.length,this.buffer.push(D)}[L](){return this.buffer.length&&(this[b]?this[R]-=1:this[R]-=this.buffer[0].length),this.buffer.shift()}[p](D){do;while(this[g](this[L]()));!D&&!this.buffer.length&&!this[o]&&this.emit("drain")}[g](D){return D?(this.emit("data",D),this.flowing):!1}pipe(D,A){if(this[S])return;let w=this[u];return A=A||{},D===r.stdout||D===r.stderr?A.end=!1:A.end=A.end!==!1,A.proxyErrors=!!A.proxyErrors,w?A.end&&D.end():(this.pipes.push(A.proxyErrors?new d(this,D,A):new P(this,D,A)),this[U]?V(()=>this[O]()):this[O]()),D}unpipe(D){let A=this.pipes.find(w=>w.dest===D);A&&(this.pipes.splice(this.pipes.indexOf(A),1),A.unpipe())}addListener(D,A){return this.on(D,A)}on(D,A){let w=super.on(D,A);return D==="data"&&!this.pipes.length&&!this.flowing?this[O]():D==="readable"&&this[R]!==0?super.emit("readable"):k(D)&&this[u]?(super.emit(D),this.removeAllListeners(D)):D==="error"&&this[c]&&(this[U]?V(()=>A.call(this,this[c])):A.call(this,this[c])),w}get emittedEnd(){return this[u]}[a](){!this[l]&&!this[u]&&!this[S]&&this.buffer.length===0&&this[o]&&(this[l]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[f]&&this.emit("close"),this[l]=!1)}emit(D,A,...w){if(D!=="error"&&D!=="close"&&D!==S&&this[S])return;if(D==="data")return A?this[U]?V(()=>this[N](A)):this[N](A):!1;if(D==="end")return this[H]();if(D==="close"){if(this[f]=!0,!this[u]&&!this[S])return;let M=super.emit("close");return this.removeAllListeners("close"),M}else if(D==="error"){this[c]=A;let M=super.emit("error",A);return this[a](),M}else if(D==="resume"){let M=super.emit("resume");return this[a](),M}else if(D==="finish"||D==="prefinish"){let M=super.emit(D);return this.removeAllListeners(D),M}let I=super.emit(D,A,...w);return this[a](),I}[N](D){for(let w of this.pipes)w.dest.write(D)===!1&&this.pause();let A=super.emit("data",D);return this[a](),A}[H](){this[u]||(this[u]=!0,this.readable=!1,this[U]?V(()=>this[T]()):this[T]())}[T](){if(this[E]){let A=this[E].end();if(A){for(let w of this.pipes)w.dest.write(A);super.emit("data",A)}}for(let A of this.pipes)A.end();let D=super.emit("end");return this.removeAllListeners("end"),D}collect(){let D=[];this[b]||(D.dataLength=0);let A=this.promise();return this.on("data",w=>{D.push(w),this[b]||(D.dataLength+=w.length)}),A.then(()=>D)}concat(){return this[b]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(D=>this[b]?Promise.reject(new Error("cannot concat in objectMode")):this[y]?D.join(""):Buffer.concat(D,D.dataLength))}promise(){return new Promise((D,A)=>{this.on(S,()=>A(new Error("stream destroyed"))),this.on("error",w=>A(w)),this.on("end",()=>D())})}[B](){return{next:()=>{let D=this.read();if(D!==null)return Promise.resolve({done:!1,value:D});if(this[o])return Promise.resolve({done:!0});let A=null,w=null,I=Q=>{this.removeListener("data",M),this.removeListener("end",Z),w(Q)},M=Q=>{this.removeListener("error",I),this.removeListener("end",Z),this.pause(),A({value:Q,done:!!this[o]})},Z=()=>{this.removeListener("error",I),this.removeListener("data",M),A({done:!0})},q=()=>I(new Error("stream destroyed"));return new Promise((Q,G)=>{w=G,A=Q,this.once(S,q),this.once("error",I),this.once("end",Z),this.once("data",M)})}}}[C](){return{next:()=>{let D=this.read();return{value:D,done:D===null}}}}destroy(D){return this[S]?(D?this.emit("error",D):this.emit(S),this):(this[S]=!0,this.buffer.length=0,this[R]=0,typeof this.close=="function"&&!this[f]&&this.close(),D?this.emit("error",D):this.emit(S),this)}static isStream(D){return!!D&&(D instanceof JD||D instanceof n||D instanceof i&&(typeof D.pipe=="function"||typeof D.write=="function"&&typeof D.end=="function"))}}}),XD=te(t=>{"use strict";W();var e=re("assert"),r=re("buffer").Buffer,i=re("zlib"),n=t.constants=tT(),s=ZD(),o=r.concat,a=Symbol("_superWrite"),u=class extends Error{constructor(k){super("zlib: "+k.message),this.code=k.code,this.errno=k.errno,this.code||(this.code="ZLIB_ERROR"),this.message="zlib: "+k.message,Error.captureStackTrace(this,this.constructor)}get name(){return"ZlibError"}},l=Symbol("opts"),c=Symbol("flushFlag"),f=Symbol("finishFlushFlag"),h=Symbol("fullFlushFlag"),p=Symbol("handle"),g=Symbol("onError"),y=Symbol("sawError"),E=Symbol("level"),v=Symbol("strategy"),F=Symbol("ended"),O=Symbol("_defaultFullFlush"),R=class extends s{constructor(k,j){if(!k||typeof k!="object")throw new TypeError("invalid options for ZlibBase constructor");super(k),this[y]=!1,this[F]=!1,this[l]=k,this[c]=k.flush,this[f]=k.finishFlush;try{this[p]=new i[j](k)}catch(z){throw new u(z)}this[g]=z=>{this[y]||(this[y]=!0,this.close(),this.emit("error",z))},this[p].on("error",z=>this[g](new u(z))),this.once("end",()=>this.close)}close(){this[p]&&(this[p].close(),this[p]=null,this.emit("close"))}reset(){if(!this[y])return e(this[p],"zlib binding closed"),this[p].reset()}flush(k){this.ended||(typeof k!="number"&&(k=this[h]),this.write(Object.assign(r.alloc(0),{[c]:k})))}end(k,j,z){return k&&this.write(k,j),this.flush(this[f]),this[F]=!0,super.end(null,null,z)}get ended(){return this[F]}write(k,j,z){if(typeof j=="function"&&(z=j,j="utf8"),typeof k=="string"&&(k=r.from(k,j)),this[y])return;e(this[p],"zlib binding closed");let P=this[p]._handle,d=P.close;P.close=()=>{};let m=this[p].close;this[p].close=()=>{},r.concat=w=>w;let D;try{let w=typeof k[c]=="number"?k[c]:this[c];D=this[p]._processChunk(k,w),r.concat=o}catch(w){r.concat=o,this[g](new u(w))}finally{this[p]&&(this[p]._handle=P,P.close=d,this[p].close=m,this[p].removeAllListeners("error"))}this[p]&&this[p].on("error",w=>this[g](new u(w)));let A;if(D)if(Array.isArray(D)&&D.length>0){A=this[a](r.from(D[0]));for(let w=1;w<D.length;w++)A=this[a](D[w])}else A=this[a](r.from(D));return z&&z(),A}[a](k){return super.write(k)}},x=class extends R{constructor(k,j){k=k||{},k.flush=k.flush||n.Z_NO_FLUSH,k.finishFlush=k.finishFlush||n.Z_FINISH,super(k,j),this[h]=n.Z_FULL_FLUSH,this[E]=k.level,this[v]=k.strategy}params(k,j){if(!this[y]){if(!this[p])throw new Error("cannot switch params when binding is closed");if(!this[p].params)throw new Error("not supported in this implementation");if(this[E]!==k||this[v]!==j){this.flush(n.Z_SYNC_FLUSH),e(this[p],"zlib binding closed");let z=this[p].flush;this[p].flush=(P,d)=>{this.flush(P),d()};try{this[p].params(k,j)}finally{this[p].flush=z}this[p]&&(this[E]=k,this[v]=j)}}}},L=class extends x{constructor(k){super(k,"Deflate")}},b=class extends x{constructor(k){super(k,"Inflate")}},S=Symbol("_portable"),N=class extends x{constructor(k){super(k,"Gzip"),this[S]=k&&!!k.portable}[a](k){return this[S]?(this[S]=!1,k[9]=255,super[a](k)):super[a](k)}},H=class extends x{constructor(k){super(k,"Gunzip")}},T=class extends x{constructor(k){super(k,"DeflateRaw")}},U=class extends x{constructor(k){super(k,"InflateRaw")}},V=class extends x{constructor(k){super(k,"Unzip")}},K=class extends R{constructor(k,j){k=k||{},k.flush=k.flush||n.BROTLI_OPERATION_PROCESS,k.finishFlush=k.finishFlush||n.BROTLI_OPERATION_FINISH,super(k,j),this[h]=n.BROTLI_OPERATION_FLUSH}},B=class extends K{constructor(k){super(k,"BrotliCompress")}},C=class extends K{constructor(k){super(k,"BrotliDecompress")}};t.Deflate=L,t.Inflate=b,t.Gzip=N,t.Gunzip=H,t.DeflateRaw=T,t.InflateRaw=U,t.Unzip=V,typeof i.BrotliCompress=="function"?(t.BrotliCompress=B,t.BrotliDecompress=C):t.BrotliCompress=t.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}}),Zn=te((t,e)=>{W();var r=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform;e.exports=r!=="win32"?i=>i:i=>i&&i.replace(/\\/g,"/")}),Ih=te((t,e)=>{"use strict";W();var r=Ph(),i=Zn(),n=Symbol("slurp");e.exports=class extends r{constructor(s,o,a){switch(super(),this.pause(),this.extended=o,this.globalExtended=a,this.header=s,this.startBlockSize=512*Math.ceil(s.size/512),this.blockRemain=this.startBlockSize,this.remain=s.size,this.type=s.type,this.meta=!1,this.ignore=!1,this.type){case"File":case"OldFile":case"Link":case"SymbolicLink":case"CharacterDevice":case"BlockDevice":case"Directory":case"FIFO":case"ContiguousFile":case"GNUDumpDir":break;case"NextFileHasLongLinkpath":case"NextFileHasLongPath":case"OldGnuLongPath":case"GlobalExtendedHeader":case"ExtendedHeader":case"OldExtendedHeader":this.meta=!0;break;default:this.ignore=!0}this.path=i(s.path),this.mode=s.mode,this.mode&&(this.mode=this.mode&4095),this.uid=s.uid,this.gid=s.gid,this.uname=s.uname,this.gname=s.gname,this.size=s.size,this.mtime=s.mtime,this.atime=s.atime,this.ctime=s.ctime,this.linkpath=i(s.linkpath),this.uname=s.uname,this.gname=s.gname,o&&this[n](o),a&&this[n](a,!0)}write(s){let o=s.length;if(o>this.blockRemain)throw new Error("writing more to entry than is appropriate");let a=this.remain,u=this.blockRemain;return this.remain=Math.max(0,a-o),this.blockRemain=Math.max(0,u-o),this.ignore?!0:a>=o?super.write(s):super.write(s.slice(0,a))}[n](s,o){for(let a in s)s[a]!==null&&s[a]!==void 0&&!(o&&a==="path")&&(this[a]=a==="path"||a==="linkpath"?i(s[a]):s[a])}}}),QD=te(t=>{"use strict";W(),t.name=new Map([["0","File"],["","OldFile"],["1","Link"],["2","SymbolicLink"],["3","CharacterDevice"],["4","BlockDevice"],["5","Directory"],["6","FIFO"],["7","ContiguousFile"],["g","GlobalExtendedHeader"],["x","ExtendedHeader"],["A","SolarisACL"],["D","GNUDumpDir"],["I","Inode"],["K","NextFileHasLongLinkpath"],["L","NextFileHasLongPath"],["M","ContinuationFile"],["N","OldGnuLongPath"],["S","SparseFile"],["V","TapeVolumeHeader"],["X","OldExtendedHeader"]]),t.code=new Map(Array.from(t.name).map(e=>[e[1],e[0]]))}),rT=te((t,e)=>{"use strict";W();var r=(c,f)=>{if(Number.isSafeInteger(c))c<0?n(c,f):i(c,f);else throw Error("cannot encode number outside of javascript safe integer range");return f},i=(c,f)=>{f[0]=128;for(var h=f.length;h>1;h--)f[h-1]=c&255,c=Math.floor(c/256)},n=(c,f)=>{f[0]=255;var h=!1;c=c*-1;for(var p=f.length;p>1;p--){var g=c&255;c=Math.floor(c/256),h?f[p-1]=u(g):g===0?f[p-1]=0:(h=!0,f[p-1]=l(g))}},s=c=>{let f=c[0],h=f===128?a(c.slice(1,c.length)):f===255?o(c):null;if(h===null)throw Error("invalid base256 encoding");if(!Number.isSafeInteger(h))throw Error("parsed number outside of javascript safe integer range");return h},o=c=>{for(var f=c.length,h=0,p=!1,g=f-1;g>-1;g--){var y=c[g],E;p?E=u(y):y===0?E=y:(p=!0,E=l(y)),E!==0&&(h-=E*Math.pow(256,f-g-1))}return h},a=c=>{for(var f=c.length,h=0,p=f-1;p>-1;p--){var g=c[p];g!==0&&(h+=g*Math.pow(256,f-p-1))}return h},u=c=>(255^c)&255,l=c=>(255^c)+1&255;e.exports={encode:r,parse:s}}),Jn=te((t,e)=>{"use strict";W();var r=QD(),i=re("path").posix,n=rT(),s=Symbol("slurp"),o=Symbol("type"),a=class{constructor(b,S,N,H){this.cksumValid=!1,this.needPax=!1,this.nullBlock=!1,this.block=null,this.path=null,this.mode=null,this.uid=null,this.gid=null,this.size=null,this.mtime=null,this.cksum=null,this[o]="0",this.linkpath=null,this.uname=null,this.gname=null,this.devmaj=0,this.devmin=0,this.atime=null,this.ctime=null,Buffer.isBuffer(b)?this.decode(b,S||0,N,H):b&&this.set(b)}decode(b,S,N,H){if(S||(S=0),!b||!(b.length>=S+512))throw new Error("need 512 bytes for header");if(this.path=l(b,S,100),this.mode=h(b,S+100,8),this.uid=h(b,S+108,8),this.gid=h(b,S+116,8),this.size=h(b,S+124,12),this.mtime=c(b,S+136,12),this.cksum=h(b,S+148,12),this[s](N),this[s](H,!0),this[o]=l(b,S+156,1),this[o]===""&&(this[o]="0"),this[o]==="0"&&this.path.slice(-1)==="/"&&(this[o]="5"),this[o]==="5"&&(this.size=0),this.linkpath=l(b,S+157,100),b.slice(S+257,S+265).toString()==="ustar\x0000")if(this.uname=l(b,S+265,32),this.gname=l(b,S+297,32),this.devmaj=h(b,S+329,8),this.devmin=h(b,S+337,8),b[S+475]!==0){let U=l(b,S+345,155);this.path=U+"/"+this.path}else{let U=l(b,S+345,130);U&&(this.path=U+"/"+this.path),this.atime=c(b,S+476,12),this.ctime=c(b,S+488,12)}let T=8*32;for(let U=S;U<S+148;U++)T+=b[U];for(let U=S+156;U<S+512;U++)T+=b[U];this.cksumValid=T===this.cksum,this.cksum===null&&T===8*32&&(this.nullBlock=!0)}[s](b,S){for(let N in b)b[N]!==null&&b[N]!==void 0&&!(S&&N==="path")&&(this[N]=b[N])}encode(b,S){if(b||(b=this.block=Buffer.alloc(512),S=0),S||(S=0),!(b.length>=S+512))throw new Error("need 512 bytes for header");let N=this.ctime||this.atime?130:155,H=u(this.path||"",N),T=H[0],U=H[1];this.needPax=H[2],this.needPax=L(b,S,100,T)||this.needPax,this.needPax=E(b,S+100,8,this.mode)||this.needPax,this.needPax=E(b,S+108,8,this.uid)||this.needPax,this.needPax=E(b,S+116,8,this.gid)||this.needPax,this.needPax=E(b,S+124,12,this.size)||this.needPax,this.needPax=R(b,S+136,12,this.mtime)||this.needPax,b[S+156]=this[o].charCodeAt(0),this.needPax=L(b,S+157,100,this.linkpath)||this.needPax,b.write("ustar\x0000",S+257,8),this.needPax=L(b,S+265,32,this.uname)||this.needPax,this.needPax=L(b,S+297,32,this.gname)||this.needPax,this.needPax=E(b,S+329,8,this.devmaj)||this.needPax,this.needPax=E(b,S+337,8,this.devmin)||this.needPax,this.needPax=L(b,S+345,N,U)||this.needPax,b[S+475]!==0?this.needPax=L(b,S+345,155,U)||this.needPax:(this.needPax=L(b,S+345,130,U)||this.needPax,this.needPax=R(b,S+476,12,this.atime)||this.needPax,this.needPax=R(b,S+488,12,this.ctime)||this.needPax);let V=8*32;for(let K=S;K<S+148;K++)V+=b[K];for(let K=S+156;K<S+512;K++)V+=b[K];return this.cksum=V,E(b,S+148,8,this.cksum),this.cksumValid=!0,this.needPax}set(b){for(let S in b)b[S]!==null&&b[S]!==void 0&&(this[S]=b[S])}get type(){return r.name.get(this[o])||this[o]}get typeKey(){return this[o]}set type(b){r.code.has(b)?this[o]=r.code.get(b):this[o]=b}},u=(b,S)=>{let N=b,H="",T,U=i.parse(b).root||".";if(Buffer.byteLength(N)<100)T=[N,H,!1];else{H=i.dirname(N),N=i.basename(N);do Buffer.byteLength(N)<=100&&Buffer.byteLength(H)<=S?T=[N,H,!1]:Buffer.byteLength(N)>100&&Buffer.byteLength(H)<=S?T=[N.slice(0,100-1),H,!0]:(N=i.join(i.basename(H),N),H=i.dirname(H));while(H!==U&&!T);T||(T=[b.slice(0,100-1),"",!0])}return T},l=(b,S,N)=>b.slice(S,S+N).toString("utf8").replace(/\0.*/,""),c=(b,S,N)=>f(h(b,S,N)),f=b=>b===null?null:new Date(b*1e3),h=(b,S,N)=>b[S]&128?n.parse(b.slice(S,S+N)):g(b,S,N),p=b=>isNaN(b)?null:b,g=(b,S,N)=>p(parseInt(b.slice(S,S+N).toString("utf8").replace(/\0.*$/,"").trim(),8)),y={12:8589934591,8:2097151},E=(b,S,N,H)=>H===null?!1:H>y[N]||H<0?(n.encode(H,b.slice(S,S+N)),!0):(v(b,S,N,H),!1),v=(b,S,N,H)=>b.write(F(H,N),S,N,"ascii"),F=(b,S)=>O(Math.floor(b).toString(8),S),O=(b,S)=>(b.length===S-1?b:new Array(S-b.length-1).join("0")+b+" ")+"\0",R=(b,S,N,H)=>H===null?!1:E(b,S,N,H.getTime()/1e3),x=new Array(156).join("\0"),L=(b,S,N,H)=>H===null?!1:(b.write(H+x,S,N,"utf8"),H.length!==Buffer.byteLength(H)||H.length>N);e.exports=a}),Nh=te((t,e)=>{"use strict";W();var r=Jn(),i=re("path"),n=class{constructor(u,l){this.atime=u.atime||null,this.charset=u.charset||null,this.comment=u.comment||null,this.ctime=u.ctime||null,this.gid=u.gid||null,this.gname=u.gname||null,this.linkpath=u.linkpath||null,this.mtime=u.mtime||null,this.path=u.path||null,this.size=u.size||null,this.uid=u.uid||null,this.uname=u.uname||null,this.dev=u.dev||null,this.ino=u.ino||null,this.nlink=u.nlink||null,this.global=l||!1}encode(){let u=this.encodeBody();if(u==="")return null;let l=Buffer.byteLength(u),c=512*Math.ceil(1+l/512),f=Buffer.allocUnsafe(c);for(let h=0;h<512;h++)f[h]=0;new r({path:("PaxHeader/"+i.basename(this.path)).slice(0,99),mode:this.mode||420,uid:this.uid||null,gid:this.gid||null,size:l,mtime:this.mtime||null,type:this.global?"GlobalExtendedHeader":"ExtendedHeader",linkpath:"",uname:this.uname||"",gname:this.gname||"",devmaj:0,devmin:0,atime:this.atime||null,ctime:this.ctime||null}).encode(f),f.write(u,512,l,"utf8");for(let h=l+512;h<f.length;h++)f[h]=0;return f}encodeBody(){return this.encodeField("path")+this.encodeField("ctime")+this.encodeField("atime")+this.encodeField("dev")+this.encodeField("ino")+this.encodeField("nlink")+this.encodeField("charset")+this.encodeField("comment")+this.encodeField("gid")+this.encodeField("gname")+this.encodeField("linkpath")+this.encodeField("mtime")+this.encodeField("size")+this.encodeField("uid")+this.encodeField("uname")}encodeField(u){if(this[u]===null||this[u]===void 0)return"";let l=this[u]instanceof Date?this[u].getTime()/1e3:this[u],c=" "+(u==="dev"||u==="ino"||u==="nlink"?"SCHILY.":"")+u+"="+l+`
40
+ `:""}var pS=fS,dS={dump:pS};function qa(t,e){return function(){throw new Error("Function yaml."+t+" is removed in js-yaml 4. Use yaml."+e+" instead, which is now safe by default.")}}var mS=Oe,gS=_f,yS=vf,ES=Of,DS=kf,bS=Ma,_S=Vf.load,wS=Vf.loadAll,SS=dS.dump,AS=He,vS={binary:If,float:Ff,map:Af,null:Cf,pairs:Mf,set:jf,timestamp:Bf,bool:xf,int:Rf,merge:Pf,omap:Nf,seq:Sf,str:wf},CS=qa("safeLoad","load"),xS=qa("safeLoadAll","loadAll"),RS=qa("safeDump","dump"),FS={Type:mS,Schema:gS,FAILSAFE_SCHEMA:yS,JSON_SCHEMA:ES,CORE_SCHEMA:DS,DEFAULT_SCHEMA:bS,load:_S,loadAll:wS,dump:SS,YAMLException:AS,types:vS,safeLoad:CS,safeLoadAll:xS,safeDump:RS},Ua=FS;var UC=J(Ns());var ne={};r_(ne,{bold:()=>PC,dimmed:()=>NC,error:()=>e0,grey:()=>MC,info:()=>BC,item:()=>jC,log:()=>pr,turboBlue:()=>wi,turboGradient:()=>LC,turboLoader:()=>Xm,turboRed:()=>Zm,underline:()=>IC,warn:()=>Qm,yellow:()=>Jm});var fr=J(require("chalk")),Wm=J(require("ora")),Ym=J(require("gradient-string")),Vm="#0099F7",Km="#F11712",TC="#FFFF00",LC=(0,Ym.default)(Vm,Km),wi=fr.default.hex(Vm),Zm=fr.default.hex(Km),Jm=fr.default.hex(TC),Xm=t=>(0,Wm.default)({text:t,spinner:{frames:[" ",wi("> "),wi(">> "),wi(">>>")]}}),BC=(...t)=>{pr(wi.bold(">>>"),...t)},PC=(...t)=>{pr(fr.default.bold(...t))},IC=(...t)=>{pr(fr.default.underline(...t))},NC=(...t)=>{pr(fr.default.dim(...t))},MC=(...t)=>{pr(fr.default.grey(...t))},jC=(...t)=>{pr(wi.bold(" \u2022"),...t)},pr=(...t)=>{console.log(...t)},Qm=(...t)=>{console.error(Jm.bold(">>>"),...t)},e0=(...t)=>{console.error(Zm.bold(">>>"),...t)};var Ng=J(require("os")),Mg=J(ki());async function dr(t,e=[],r){let i={cwd:Ng.default.tmpdir(),env:{COREPACK_ENABLE_STRICT:"0"},...r};try{let{stdout:n}=await(0,Mg.default)(t,e,i);return n.trim()}catch{return}}async function Gl(){let[t,e,r,i]=await Promise.all([dr("yarnpkg",["--version"]),dr("npm",["--version"]),dr("pnpm",["--version"]),dr("bun",["--version"])]);return{yarn:t,pnpm:r,npm:e,bun:i}}async function zl(){let[t,e,r,i]=await Promise.all([dr("yarnpkg",["global","bin"]),dr("npm",["config","get","prefix"]),dr("pnpm",["bin","--global"]),dr("bun",["pm","--g","bin"])]);return{yarn:t,pnpm:r,npm:e,bun:i}}var NR=J(require("fs-extra"));var MR=J(require("path")),jR=J(require("fs-extra")),$R=J(require("chalk"));var ND=require("stream"),MD=require("util"),wk=require("path"),Sk=require("os"),jD=require("fs"),Ak=J(ID());var _I=(0,MD.promisify)(ND.Stream.pipeline);var $D=require("fs-extra");var Bk=J(require("path")),Pk=J(YD()),Ik=J(require("chalk")),kh=require("fs-extra");var Zb=require("commander");var ia={name:"@turbo/codemod",version:"2.0.0-canary.1",description:"Provides Codemod transformations to help upgrade your Turborepo codebase when a feature is deprecated.",homepage:"https://turbo.build/repo",license:"MIT",repository:{type:"git",url:"https://github.com/vercel/turbo",directory:"packages/turbo-codemod"},bugs:{url:"https://github.com/vercel/turbo/issues"},bin:"dist/cli.js",scripts:{build:"tsup",test:"jest",lint:"eslint src/","check-types":"tsc --noEmit","add-transformer":"plop","lint:prettier":"prettier -c . --cache --ignore-path=../../.prettierignore"},dependencies:{axios:"0.27.2",chalk:"2.4.2",commander:"^9.5.0",diff:"^5.1.0","find-up":"4.1.0","fs-extra":"^10.0.0","gradient-string":"^2.0.0",inquirer:"^8.2.4","inquirer-file-tree-selection-prompt":"^1.0.19","is-git-clean":"^1.1.0",ora:"4.1.1",semver:"^7.3.7","update-check":"^1.5.4"},devDependencies:{"@turbo/eslint-config":"workspace:*","@turbo/gen":"workspace:*","@turbo/test-utils":"workspace:*","@turbo/tsconfig":"workspace:*","@turbo/types":"workspace:*","@turbo/utils":"workspace:*","@turbo/workspaces":"workspace:*","@types/chalk-animation":"^1.6.0","@types/diff":"^5.0.2","@types/fs-extra":"^9.0.13","@types/gradient-string":"^1.1.2","@types/inquirer":"^8.2.0","@types/jest":"^27.4.0","@types/node":"^18.17.2","@types/semver":"^7.3.9","@types/uuid":"^9.0.0",deepmerge:"^4.2.2",jest:"^27.4.3",plop:"^3.1.1",semver:"^7.3.5","ts-jest":"^27.1.1",tsup:"^6.7.0",typescript:"5.3.3"},files:["dist"],publishConfig:{access:"public"}};var an=J(require("os")),zb=require("child_process"),$e=J(require("chalk")),Wb=require("inquirer");var Or=J(require("chalk"),1),ub=J(require("ora"),1),lb=J(require("gradient-string"),1);var PT=J(ki(),1),rN=require("fs-extra");var aN=J(Ns(),1),lN=require("fs-extra"),hN=require("fs-extra"),pN=require("chalk"),db=require("stream"),mb=require("util"),yN=require("fs-extra"),_N=require("chalk"),SN=require("fs-extra"),ii=J(require("path"),1),qe=require("fs-extra"),gb=J(ki(),1),yb=J(require("path"),1),Eb=require("fs-extra"),Db=J(require("chalk"),1),rr=J(require("path"),1),bb=J(ki(),1),rt=require("fs-extra"),_b=J(Ns(),1);var Yn=J(require("path"),1),Tt=require("fs-extra"),nn=J(require("path"),1),Lt=require("fs-extra"),Vn=J(require("path"),1),Bt=require("fs-extra"),gL=J(require("chalk"),1),yL=J(require("gradient-string"),1),EL=J(ki(),1),DL=J(require("ora"),1),bL=require("semver"),_L=J(require("chalk"),1),Mk=Object.create,Bh=Object.defineProperty,jk=Object.getOwnPropertyDescriptor,$k=Object.getOwnPropertyNames,Hk=Object.getPrototypeOf,qk=Object.prototype.hasOwnProperty,re=(t=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(t,{get:(e,r)=>(typeof require!="undefined"?require:e)[r]}):t)(function(t){if(typeof require!="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+t+'" is not supported')}),Uk=(t,e)=>()=>(t&&(e=t(t=0)),e),te=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Gk=(t,e)=>{for(var r in e)Bh(t,r,{get:e[r],enumerable:!0})},zk=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of $k(e))!qk.call(t,n)&&n!==r&&Bh(t,n,{get:()=>e[n],enumerable:!(i=jk(e,n))||i.enumerable});return t},oa=(t,e,r)=>(r=t!=null?Mk(Hk(t)):{},zk(e||!t||!t.__esModule?Bh(r,"default",{value:t,enumerable:!0}):r,t)),W=Uk(()=>{}),Wk=te((t,e)=>{W();function r(i){return e.exports=r=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},e.exports.__esModule=!0,e.exports.default=e.exports,r(i)}e.exports=r,e.exports.__esModule=!0,e.exports.default=e.exports}),Yk=te((t,e)=>{W();var r=Wk().default;function i(){"use strict";e.exports=i=function(){return s},e.exports.__esModule=!0,e.exports.default=e.exports;var n,s={},o=Object.prototype,a=o.hasOwnProperty,u=Object.defineProperty||function(P,d,m){P[d]=m.value},l=typeof Symbol=="function"?Symbol:{},c=l.iterator||"@@iterator",f=l.asyncIterator||"@@asyncIterator",h=l.toStringTag||"@@toStringTag";function p(P,d,m){return Object.defineProperty(P,d,{value:m,enumerable:!0,configurable:!0,writable:!0}),P[d]}try{p({},"")}catch{p=function(P,d,m){return P[d]=m}}function g(P,d,m,D){var A=d&&d.prototype instanceof x?d:x,w=Object.create(A.prototype),I=new j(D||[]);return u(w,"_invoke",{value:K(P,m,I)}),w}function y(P,d,m){try{return{type:"normal",arg:P.call(d,m)}}catch(D){return{type:"throw",arg:D}}}s.wrap=g;var E="suspendedStart",v="suspendedYield",F="executing",O="completed",R={};function x(){}function L(){}function b(){}var S={};p(S,c,function(){return this});var N=Object.getPrototypeOf,H=N&&N(N(z([])));H&&H!==o&&a.call(H,c)&&(S=H);var T=b.prototype=x.prototype=Object.create(S);function U(P){["next","throw","return"].forEach(function(d){p(P,d,function(m){return this._invoke(d,m)})})}function V(P,d){function m(A,w,I,M){var Z=y(P[A],P,w);if(Z.type!=="throw"){var q=Z.arg,Q=q.value;return Q&&r(Q)=="object"&&a.call(Q,"__await")?d.resolve(Q.__await).then(function(G){m("next",G,I,M)},function(G){m("throw",G,I,M)}):d.resolve(Q).then(function(G){q.value=G,I(q)},function(G){return m("throw",G,I,M)})}M(Z.arg)}var D;u(this,"_invoke",{value:function(A,w){function I(){return new d(function(M,Z){m(A,w,M,Z)})}return D=D?D.then(I,I):I()}})}function K(P,d,m){var D=E;return function(A,w){if(D===F)throw new Error("Generator is already running");if(D===O){if(A==="throw")throw w;return{value:n,done:!0}}for(m.method=A,m.arg=w;;){var I=m.delegate;if(I){var M=B(I,m);if(M){if(M===R)continue;return M}}if(m.method==="next")m.sent=m._sent=m.arg;else if(m.method==="throw"){if(D===E)throw D=O,m.arg;m.dispatchException(m.arg)}else m.method==="return"&&m.abrupt("return",m.arg);D=F;var Z=y(P,d,m);if(Z.type==="normal"){if(D=m.done?O:v,Z.arg===R)continue;return{value:Z.arg,done:m.done}}Z.type==="throw"&&(D=O,m.method="throw",m.arg=Z.arg)}}}function B(P,d){var m=d.method,D=P.iterator[m];if(D===n)return d.delegate=null,m==="throw"&&P.iterator.return&&(d.method="return",d.arg=n,B(P,d),d.method==="throw")||m!=="return"&&(d.method="throw",d.arg=new TypeError("The iterator does not provide a '"+m+"' method")),R;var A=y(D,P.iterator,d.arg);if(A.type==="throw")return d.method="throw",d.arg=A.arg,d.delegate=null,R;var w=A.arg;return w?w.done?(d[P.resultName]=w.value,d.next=P.nextLoc,d.method!=="return"&&(d.method="next",d.arg=n),d.delegate=null,R):w:(d.method="throw",d.arg=new TypeError("iterator result is not an object"),d.delegate=null,R)}function C(P){var d={tryLoc:P[0]};1 in P&&(d.catchLoc=P[1]),2 in P&&(d.finallyLoc=P[2],d.afterLoc=P[3]),this.tryEntries.push(d)}function k(P){var d=P.completion||{};d.type="normal",delete d.arg,P.completion=d}function j(P){this.tryEntries=[{tryLoc:"root"}],P.forEach(C,this),this.reset(!0)}function z(P){if(P||P===""){var d=P[c];if(d)return d.call(P);if(typeof P.next=="function")return P;if(!isNaN(P.length)){var m=-1,D=function A(){for(;++m<P.length;)if(a.call(P,m))return A.value=P[m],A.done=!1,A;return A.value=n,A.done=!0,A};return D.next=D}}throw new TypeError(r(P)+" is not iterable")}return L.prototype=b,u(T,"constructor",{value:b,configurable:!0}),u(b,"constructor",{value:L,configurable:!0}),L.displayName=p(b,h,"GeneratorFunction"),s.isGeneratorFunction=function(P){var d=typeof P=="function"&&P.constructor;return!!d&&(d===L||(d.displayName||d.name)==="GeneratorFunction")},s.mark=function(P){return Object.setPrototypeOf?Object.setPrototypeOf(P,b):(P.__proto__=b,p(P,h,"GeneratorFunction")),P.prototype=Object.create(T),P},s.awrap=function(P){return{__await:P}},U(V.prototype),p(V.prototype,f,function(){return this}),s.AsyncIterator=V,s.async=function(P,d,m,D,A){A===void 0&&(A=Promise);var w=new V(g(P,d,m,D),A);return s.isGeneratorFunction(d)?w:w.next().then(function(I){return I.done?I.value:w.next()})},U(T),p(T,h,"Generator"),p(T,c,function(){return this}),p(T,"toString",function(){return"[object Generator]"}),s.keys=function(P){var d=Object(P),m=[];for(var D in d)m.push(D);return m.reverse(),function A(){for(;m.length;){var w=m.pop();if(w in d)return A.value=w,A.done=!1,A}return A.done=!0,A}},s.values=z,j.prototype={constructor:j,reset:function(P){if(this.prev=0,this.next=0,this.sent=this._sent=n,this.done=!1,this.delegate=null,this.method="next",this.arg=n,this.tryEntries.forEach(k),!P)for(var d in this)d.charAt(0)==="t"&&a.call(this,d)&&!isNaN(+d.slice(1))&&(this[d]=n)},stop:function(){this.done=!0;var P=this.tryEntries[0].completion;if(P.type==="throw")throw P.arg;return this.rval},dispatchException:function(P){if(this.done)throw P;var d=this;function m(Z,q){return w.type="throw",w.arg=P,d.next=Z,q&&(d.method="next",d.arg=n),!!q}for(var D=this.tryEntries.length-1;D>=0;--D){var A=this.tryEntries[D],w=A.completion;if(A.tryLoc==="root")return m("end");if(A.tryLoc<=this.prev){var I=a.call(A,"catchLoc"),M=a.call(A,"finallyLoc");if(I&&M){if(this.prev<A.catchLoc)return m(A.catchLoc,!0);if(this.prev<A.finallyLoc)return m(A.finallyLoc)}else if(I){if(this.prev<A.catchLoc)return m(A.catchLoc,!0)}else{if(!M)throw new Error("try statement without catch or finally");if(this.prev<A.finallyLoc)return m(A.finallyLoc)}}}},abrupt:function(P,d){for(var m=this.tryEntries.length-1;m>=0;--m){var D=this.tryEntries[m];if(D.tryLoc<=this.prev&&a.call(D,"finallyLoc")&&this.prev<D.finallyLoc){var A=D;break}}A&&(P==="break"||P==="continue")&&A.tryLoc<=d&&d<=A.finallyLoc&&(A=null);var w=A?A.completion:{};return w.type=P,w.arg=d,A?(this.method="next",this.next=A.finallyLoc,R):this.complete(w)},complete:function(P,d){if(P.type==="throw")throw P.arg;return P.type==="break"||P.type==="continue"?this.next=P.arg:P.type==="return"?(this.rval=this.arg=P.arg,this.method="return",this.next="end"):P.type==="normal"&&d&&(this.next=d),R},finish:function(P){for(var d=this.tryEntries.length-1;d>=0;--d){var m=this.tryEntries[d];if(m.finallyLoc===P)return this.complete(m.completion,m.afterLoc),k(m),R}},catch:function(P){for(var d=this.tryEntries.length-1;d>=0;--d){var m=this.tryEntries[d];if(m.tryLoc===P){var D=m.completion;if(D.type==="throw"){var A=D.arg;k(m)}return A}}throw new Error("illegal catch attempt")},delegateYield:function(P,d,m){return this.delegate={iterator:z(P),resultName:d,nextLoc:m},this.method==="next"&&(this.arg=n),R}},s}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports}),Vk=te((t,e)=>{W();var r=Yk()();e.exports=r;try{regeneratorRuntime=r}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}}),Kk=te((t,e)=>{"use strict";W();var r=(i,...n)=>new Promise(s=>{s(i(...n))});e.exports=r,e.exports.default=r}),Zk=te((t,e)=>{"use strict";W();var r=Kk(),i=n=>{if(!((Number.isInteger(n)||n===1/0)&&n>0))return Promise.reject(new TypeError("Expected `concurrency` to be a number from 1 and up"));let s=[],o=0,a=()=>{o--,s.length>0&&s.shift()()},u=(f,h,...p)=>{o++;let g=r(f,...p);h(g),g.then(a,a)},l=(f,h,...p)=>{o<n?u(f,h,...p):s.push(u.bind(null,f,h,...p))},c=(f,...h)=>new Promise(p=>l(f,p,...h));return Object.defineProperties(c,{activeCount:{get:()=>o},pendingCount:{get:()=>s.length},clearQueue:{value:()=>{s.length=0}}}),c};e.exports=i,e.exports.default=i}),Jk=te((t,e)=>{"use strict";W();var r=Zk(),i=class extends Error{constructor(a){super(),this.value=a}},n=async(a,u)=>u(await a),s=async a=>{let u=await Promise.all(a);if(u[1]===!0)throw new i(u[0]);return!1},o=async(a,u,l)=>{l={concurrency:1/0,preserveOrder:!0,...l};let c=r(l.concurrency),f=[...a].map(p=>[p,c(n,p,u)]),h=r(l.preserveOrder?1:1/0);try{await Promise.all(f.map(p=>h(s,p)))}catch(p){if(p instanceof i)return p.value;throw p}};e.exports=o,e.exports.default=o}),Xk=te((t,e)=>{"use strict";W();var r=re("path"),i=re("fs"),{promisify:n}=re("util"),s=Jk(),o=n(i.stat),a=n(i.lstat),u={directory:"isDirectory",file:"isFile"};function l({type:f}){if(!(f in u))throw new Error(`Invalid type specified: ${f}`)}var c=(f,h)=>f===void 0||h[u[f]]();e.exports=async(f,h)=>{h={cwd:process.cwd(),type:"file",allowSymlinks:!0,...h},l(h);let p=h.allowSymlinks?o:a;return s(f,async g=>{try{let y=await p(r.resolve(h.cwd,g));return c(h.type,y)}catch{return!1}},h)},e.exports.sync=(f,h)=>{h={cwd:process.cwd(),allowSymlinks:!0,type:"file",...h},l(h);let p=h.allowSymlinks?i.statSync:i.lstatSync;for(let g of f)try{let y=p(r.resolve(h.cwd,g));if(c(h.type,y))return g}catch{}}}),Qk=te((t,e)=>{"use strict";W();var r=re("fs"),{promisify:i}=re("util"),n=i(r.access);e.exports=async s=>{try{return await n(s),!0}catch{return!1}},e.exports.sync=s=>{try{return r.accessSync(s),!0}catch{return!1}}}),eT=te((t,e)=>{"use strict";W();var r=re("path"),i=Xk(),n=Qk(),s=Symbol("findUp.stop");e.exports=async(o,a={})=>{let u=r.resolve(a.cwd||""),{root:l}=r.parse(u),c=[].concat(o),f=async h=>{if(typeof o!="function")return i(c,h);let p=await o(h.cwd);return typeof p=="string"?i([p],h):p};for(;;){let h=await f({...a,cwd:u});if(h===s)return;if(h)return r.resolve(u,h);if(u===l)return;u=r.dirname(u)}},e.exports.sync=(o,a={})=>{let u=r.resolve(a.cwd||""),{root:l}=r.parse(u),c=[].concat(o),f=h=>{if(typeof o!="function")return i.sync(c,h);let p=o(h.cwd);return typeof p=="string"?i.sync([p],h):p};for(;;){let h=f({...a,cwd:u});if(h===s)return;if(h)return r.resolve(u,h);if(u===l)return;u=r.dirname(u)}},e.exports.exists=n,e.exports.sync.exists=n.sync,e.exports.stop=s}),Kn=te((t,e)=>{"use strict";W();var r=new Map([["C","cwd"],["f","file"],["z","gzip"],["P","preservePaths"],["U","unlink"],["strip-components","strip"],["stripComponents","strip"],["keep-newer","newer"],["keepNewer","newer"],["keep-newer-files","newer"],["keepNewerFiles","newer"],["k","keep"],["keep-existing","keep"],["keepExisting","keep"],["m","noMtime"],["no-mtime","noMtime"],["p","preserveOwner"],["L","follow"],["h","follow"]]);e.exports=i=>i?Object.keys(i).map(n=>[r.has(n)?r.get(n):n,i[n]]).reduce((n,s)=>(n[s[0]]=s[1],n),Object.create(null)):{}}),Ph=te((t,e)=>{"use strict";W();var r=typeof process=="object"&&process?process:{stdout:null,stderr:null},i=re("events"),n=re("stream"),s=re("string_decoder").StringDecoder,o=Symbol("EOF"),a=Symbol("maybeEmitEnd"),u=Symbol("emittedEnd"),l=Symbol("emittingEnd"),c=Symbol("emittedError"),f=Symbol("closed"),h=Symbol("read"),p=Symbol("flush"),g=Symbol("flushChunk"),y=Symbol("encoding"),E=Symbol("decoder"),v=Symbol("flowing"),F=Symbol("paused"),O=Symbol("resume"),R=Symbol("buffer"),x=Symbol("pipes"),L=Symbol("bufferLength"),b=Symbol("bufferPush"),S=Symbol("bufferShift"),N=Symbol("objectMode"),H=Symbol("destroyed"),T=Symbol("emitData"),U=Symbol("emitEnd"),V=Symbol("emitEnd2"),K=Symbol("async"),B=A=>Promise.resolve().then(A),C=global._MP_NO_ITERATOR_SYMBOLS_!=="1",k=C&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),j=C&&Symbol.iterator||Symbol("iterator not implemented"),z=A=>A==="end"||A==="finish"||A==="prefinish",P=A=>A instanceof ArrayBuffer||typeof A=="object"&&A.constructor&&A.constructor.name==="ArrayBuffer"&&A.byteLength>=0,d=A=>!Buffer.isBuffer(A)&&ArrayBuffer.isView(A),m=class{constructor(A,w,I){this.src=A,this.dest=w,this.opts=I,this.ondrain=()=>A[O](),w.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},D=class extends m{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(A,w,I){super(A,w,I),this.proxyErrors=M=>w.emit("error",M),A.on("error",this.proxyErrors)}};e.exports=class KD extends n{constructor(w){super(),this[v]=!1,this[F]=!1,this[x]=[],this[R]=[],this[N]=w&&w.objectMode||!1,this[N]?this[y]=null:this[y]=w&&w.encoding||null,this[y]==="buffer"&&(this[y]=null),this[K]=w&&!!w.async||!1,this[E]=this[y]?new s(this[y]):null,this[o]=!1,this[u]=!1,this[l]=!1,this[f]=!1,this[c]=null,this.writable=!0,this.readable=!0,this[L]=0,this[H]=!1,w&&w.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[R]}),w&&w.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[x]})}get bufferLength(){return this[L]}get encoding(){return this[y]}set encoding(w){if(this[N])throw new Error("cannot set encoding in objectMode");if(this[y]&&w!==this[y]&&(this[E]&&this[E].lastNeed||this[L]))throw new Error("cannot change encoding");this[y]!==w&&(this[E]=w?new s(w):null,this[R].length&&(this[R]=this[R].map(I=>this[E].write(I)))),this[y]=w}setEncoding(w){this.encoding=w}get objectMode(){return this[N]}set objectMode(w){this[N]=this[N]||!!w}get async(){return this[K]}set async(w){this[K]=this[K]||!!w}write(w,I,M){if(this[o])throw new Error("write after end");if(this[H])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof I=="function"&&(M=I,I="utf8"),I||(I="utf8");let Z=this[K]?B:q=>q();return!this[N]&&!Buffer.isBuffer(w)&&(d(w)?w=Buffer.from(w.buffer,w.byteOffset,w.byteLength):P(w)?w=Buffer.from(w):typeof w!="string"&&(this.objectMode=!0)),this[N]?(this.flowing&&this[L]!==0&&this[p](!0),this.flowing?this.emit("data",w):this[b](w),this[L]!==0&&this.emit("readable"),M&&Z(M),this.flowing):w.length?(typeof w=="string"&&!(I===this[y]&&!this[E].lastNeed)&&(w=Buffer.from(w,I)),Buffer.isBuffer(w)&&this[y]&&(w=this[E].write(w)),this.flowing&&this[L]!==0&&this[p](!0),this.flowing?this.emit("data",w):this[b](w),this[L]!==0&&this.emit("readable"),M&&Z(M),this.flowing):(this[L]!==0&&this.emit("readable"),M&&Z(M),this.flowing)}read(w){if(this[H])return null;if(this[L]===0||w===0||w>this[L])return this[a](),null;this[N]&&(w=null),this[R].length>1&&!this[N]&&(this.encoding?this[R]=[this[R].join("")]:this[R]=[Buffer.concat(this[R],this[L])]);let I=this[h](w||null,this[R][0]);return this[a](),I}[h](w,I){return w===I.length||w===null?this[S]():(this[R][0]=I.slice(w),I=I.slice(0,w),this[L]-=w),this.emit("data",I),!this[R].length&&!this[o]&&this.emit("drain"),I}end(w,I,M){return typeof w=="function"&&(M=w,w=null),typeof I=="function"&&(M=I,I="utf8"),w&&this.write(w,I),M&&this.once("end",M),this[o]=!0,this.writable=!1,(this.flowing||!this[F])&&this[a](),this}[O](){this[H]||(this[F]=!1,this[v]=!0,this.emit("resume"),this[R].length?this[p]():this[o]?this[a]():this.emit("drain"))}resume(){return this[O]()}pause(){this[v]=!1,this[F]=!0}get destroyed(){return this[H]}get flowing(){return this[v]}get paused(){return this[F]}[b](w){this[N]?this[L]+=1:this[L]+=w.length,this[R].push(w)}[S](){return this[R].length&&(this[N]?this[L]-=1:this[L]-=this[R][0].length),this[R].shift()}[p](w){do;while(this[g](this[S]()));!w&&!this[R].length&&!this[o]&&this.emit("drain")}[g](w){return w?(this.emit("data",w),this.flowing):!1}pipe(w,I){if(this[H])return;let M=this[u];return I=I||{},w===r.stdout||w===r.stderr?I.end=!1:I.end=I.end!==!1,I.proxyErrors=!!I.proxyErrors,M?I.end&&w.end():(this[x].push(I.proxyErrors?new D(this,w,I):new m(this,w,I)),this[K]?B(()=>this[O]()):this[O]()),w}unpipe(w){let I=this[x].find(M=>M.dest===w);I&&(this[x].splice(this[x].indexOf(I),1),I.unpipe())}addListener(w,I){return this.on(w,I)}on(w,I){let M=super.on(w,I);return w==="data"&&!this[x].length&&!this.flowing?this[O]():w==="readable"&&this[L]!==0?super.emit("readable"):z(w)&&this[u]?(super.emit(w),this.removeAllListeners(w)):w==="error"&&this[c]&&(this[K]?B(()=>I.call(this,this[c])):I.call(this,this[c])),M}get emittedEnd(){return this[u]}[a](){!this[l]&&!this[u]&&!this[H]&&this[R].length===0&&this[o]&&(this[l]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[f]&&this.emit("close"),this[l]=!1)}emit(w,I,...M){if(w!=="error"&&w!=="close"&&w!==H&&this[H])return;if(w==="data")return I?this[K]?B(()=>this[T](I)):this[T](I):!1;if(w==="end")return this[U]();if(w==="close"){if(this[f]=!0,!this[u]&&!this[H])return;let q=super.emit("close");return this.removeAllListeners("close"),q}else if(w==="error"){this[c]=I;let q=super.emit("error",I);return this[a](),q}else if(w==="resume"){let q=super.emit("resume");return this[a](),q}else if(w==="finish"||w==="prefinish"){let q=super.emit(w);return this.removeAllListeners(w),q}let Z=super.emit(w,I,...M);return this[a](),Z}[T](w){for(let M of this[x])M.dest.write(w)===!1&&this.pause();let I=super.emit("data",w);return this[a](),I}[U](){this[u]||(this[u]=!0,this.readable=!1,this[K]?B(()=>this[V]()):this[V]())}[V](){if(this[E]){let I=this[E].end();if(I){for(let M of this[x])M.dest.write(I);super.emit("data",I)}}for(let I of this[x])I.end();let w=super.emit("end");return this.removeAllListeners("end"),w}collect(){let w=[];this[N]||(w.dataLength=0);let I=this.promise();return this.on("data",M=>{w.push(M),this[N]||(w.dataLength+=M.length)}),I.then(()=>w)}concat(){return this[N]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(w=>this[N]?Promise.reject(new Error("cannot concat in objectMode")):this[y]?w.join(""):Buffer.concat(w,w.dataLength))}promise(){return new Promise((w,I)=>{this.on(H,()=>I(new Error("stream destroyed"))),this.on("error",M=>I(M)),this.on("end",()=>w())})}[k](){return{next:()=>{let w=this.read();if(w!==null)return Promise.resolve({done:!1,value:w});if(this[o])return Promise.resolve({done:!0});let I=null,M=null,Z=ie=>{this.removeListener("data",q),this.removeListener("end",Q),M(ie)},q=ie=>{this.removeListener("error",Z),this.removeListener("end",Q),this.pause(),I({value:ie,done:!!this[o]})},Q=()=>{this.removeListener("error",Z),this.removeListener("data",q),I({done:!0})},G=()=>Z(new Error("stream destroyed"));return new Promise((ie,ce)=>{M=ce,I=ie,this.once(H,G),this.once("error",Z),this.once("end",Q),this.once("data",q)})}}}[j](){return{next:()=>{let w=this.read();return{value:w,done:w===null}}}}destroy(w){return this[H]?(w?this.emit("error",w):this.emit(H),this):(this[H]=!0,this[R].length=0,this[L]=0,typeof this.close=="function"&&!this[f]&&this.close(),w?this.emit("error",w):this.emit(H),this)}static isStream(w){return!!w&&(w instanceof KD||w instanceof n||w instanceof i&&(typeof w.pipe=="function"||typeof w.write=="function"&&typeof w.end=="function"))}}}),tT=te((t,e)=>{W();var r=re("zlib").constants||{ZLIB_VERNUM:4736};e.exports=Object.freeze(Object.assign(Object.create(null),{Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_VERSION_ERROR:-6,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,DEFLATE:1,INFLATE:2,GZIP:3,GUNZIP:4,DEFLATERAW:5,INFLATERAW:6,UNZIP:7,BROTLI_DECODE:8,BROTLI_ENCODE:9,Z_MIN_WINDOWBITS:8,Z_MAX_WINDOWBITS:15,Z_DEFAULT_WINDOWBITS:15,Z_MIN_CHUNK:64,Z_MAX_CHUNK:1/0,Z_DEFAULT_CHUNK:16384,Z_MIN_MEMLEVEL:1,Z_MAX_MEMLEVEL:9,Z_DEFAULT_MEMLEVEL:8,Z_MIN_LEVEL:-1,Z_MAX_LEVEL:9,Z_DEFAULT_LEVEL:-1,BROTLI_OPERATION_PROCESS:0,BROTLI_OPERATION_FLUSH:1,BROTLI_OPERATION_FINISH:2,BROTLI_OPERATION_EMIT_METADATA:3,BROTLI_MODE_GENERIC:0,BROTLI_MODE_TEXT:1,BROTLI_MODE_FONT:2,BROTLI_DEFAULT_MODE:0,BROTLI_MIN_QUALITY:0,BROTLI_MAX_QUALITY:11,BROTLI_DEFAULT_QUALITY:11,BROTLI_MIN_WINDOW_BITS:10,BROTLI_MAX_WINDOW_BITS:24,BROTLI_LARGE_MAX_WINDOW_BITS:30,BROTLI_DEFAULT_WINDOW:22,BROTLI_MIN_INPUT_BLOCK_BITS:16,BROTLI_MAX_INPUT_BLOCK_BITS:24,BROTLI_PARAM_MODE:0,BROTLI_PARAM_QUALITY:1,BROTLI_PARAM_LGWIN:2,BROTLI_PARAM_LGBLOCK:3,BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING:4,BROTLI_PARAM_SIZE_HINT:5,BROTLI_PARAM_LARGE_WINDOW:6,BROTLI_PARAM_NPOSTFIX:7,BROTLI_PARAM_NDIRECT:8,BROTLI_DECODER_RESULT_ERROR:0,BROTLI_DECODER_RESULT_SUCCESS:1,BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT:2,BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION:0,BROTLI_DECODER_PARAM_LARGE_WINDOW:1,BROTLI_DECODER_NO_ERROR:0,BROTLI_DECODER_SUCCESS:1,BROTLI_DECODER_NEEDS_MORE_INPUT:2,BROTLI_DECODER_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE:-1,BROTLI_DECODER_ERROR_FORMAT_RESERVED:-2,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE:-3,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET:-4,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME:-5,BROTLI_DECODER_ERROR_FORMAT_CL_SPACE:-6,BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE:-7,BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT:-8,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1:-9,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2:-10,BROTLI_DECODER_ERROR_FORMAT_TRANSFORM:-11,BROTLI_DECODER_ERROR_FORMAT_DICTIONARY:-12,BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS:-13,BROTLI_DECODER_ERROR_FORMAT_PADDING_1:-14,BROTLI_DECODER_ERROR_FORMAT_PADDING_2:-15,BROTLI_DECODER_ERROR_FORMAT_DISTANCE:-16,BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET:-19,BROTLI_DECODER_ERROR_INVALID_ARGUMENTS:-20,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES:-21,BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS:-22,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP:-25,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1:-26,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2:-27,BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES:-30,BROTLI_DECODER_ERROR_UNREACHABLE:-31},r))}),ZD=te((t,e)=>{"use strict";W();var r=typeof process=="object"&&process?process:{stdout:null,stderr:null},i=re("events"),n=re("stream"),s=re("string_decoder").StringDecoder,o=Symbol("EOF"),a=Symbol("maybeEmitEnd"),u=Symbol("emittedEnd"),l=Symbol("emittingEnd"),c=Symbol("emittedError"),f=Symbol("closed"),h=Symbol("read"),p=Symbol("flush"),g=Symbol("flushChunk"),y=Symbol("encoding"),E=Symbol("decoder"),v=Symbol("flowing"),F=Symbol("paused"),O=Symbol("resume"),R=Symbol("bufferLength"),x=Symbol("bufferPush"),L=Symbol("bufferShift"),b=Symbol("objectMode"),S=Symbol("destroyed"),N=Symbol("emitData"),H=Symbol("emitEnd"),T=Symbol("emitEnd2"),U=Symbol("async"),V=m=>Promise.resolve().then(m),K=global._MP_NO_ITERATOR_SYMBOLS_!=="1",B=K&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),C=K&&Symbol.iterator||Symbol("iterator not implemented"),k=m=>m==="end"||m==="finish"||m==="prefinish",j=m=>m instanceof ArrayBuffer||typeof m=="object"&&m.constructor&&m.constructor.name==="ArrayBuffer"&&m.byteLength>=0,z=m=>!Buffer.isBuffer(m)&&ArrayBuffer.isView(m),P=class{constructor(m,D,A){this.src=m,this.dest=D,this.opts=A,this.ondrain=()=>m[O](),D.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},d=class extends P{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(m,D,A){super(m,D,A),this.proxyErrors=w=>D.emit("error",w),m.on("error",this.proxyErrors)}};e.exports=class JD extends n{constructor(D){super(),this[v]=!1,this[F]=!1,this.pipes=[],this.buffer=[],this[b]=D&&D.objectMode||!1,this[b]?this[y]=null:this[y]=D&&D.encoding||null,this[y]==="buffer"&&(this[y]=null),this[U]=D&&!!D.async||!1,this[E]=this[y]?new s(this[y]):null,this[o]=!1,this[u]=!1,this[l]=!1,this[f]=!1,this[c]=null,this.writable=!0,this.readable=!0,this[R]=0,this[S]=!1}get bufferLength(){return this[R]}get encoding(){return this[y]}set encoding(D){if(this[b])throw new Error("cannot set encoding in objectMode");if(this[y]&&D!==this[y]&&(this[E]&&this[E].lastNeed||this[R]))throw new Error("cannot change encoding");this[y]!==D&&(this[E]=D?new s(D):null,this.buffer.length&&(this.buffer=this.buffer.map(A=>this[E].write(A)))),this[y]=D}setEncoding(D){this.encoding=D}get objectMode(){return this[b]}set objectMode(D){this[b]=this[b]||!!D}get async(){return this[U]}set async(D){this[U]=this[U]||!!D}write(D,A,w){if(this[o])throw new Error("write after end");if(this[S])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof A=="function"&&(w=A,A="utf8"),A||(A="utf8");let I=this[U]?V:M=>M();return!this[b]&&!Buffer.isBuffer(D)&&(z(D)?D=Buffer.from(D.buffer,D.byteOffset,D.byteLength):j(D)?D=Buffer.from(D):typeof D!="string"&&(this.objectMode=!0)),this[b]?(this.flowing&&this[R]!==0&&this[p](!0),this.flowing?this.emit("data",D):this[x](D),this[R]!==0&&this.emit("readable"),w&&I(w),this.flowing):D.length?(typeof D=="string"&&!(A===this[y]&&!this[E].lastNeed)&&(D=Buffer.from(D,A)),Buffer.isBuffer(D)&&this[y]&&(D=this[E].write(D)),this.flowing&&this[R]!==0&&this[p](!0),this.flowing?this.emit("data",D):this[x](D),this[R]!==0&&this.emit("readable"),w&&I(w),this.flowing):(this[R]!==0&&this.emit("readable"),w&&I(w),this.flowing)}read(D){if(this[S])return null;if(this[R]===0||D===0||D>this[R])return this[a](),null;this[b]&&(D=null),this.buffer.length>1&&!this[b]&&(this.encoding?this.buffer=[this.buffer.join("")]:this.buffer=[Buffer.concat(this.buffer,this[R])]);let A=this[h](D||null,this.buffer[0]);return this[a](),A}[h](D,A){return D===A.length||D===null?this[L]():(this.buffer[0]=A.slice(D),A=A.slice(0,D),this[R]-=D),this.emit("data",A),!this.buffer.length&&!this[o]&&this.emit("drain"),A}end(D,A,w){return typeof D=="function"&&(w=D,D=null),typeof A=="function"&&(w=A,A="utf8"),D&&this.write(D,A),w&&this.once("end",w),this[o]=!0,this.writable=!1,(this.flowing||!this[F])&&this[a](),this}[O](){this[S]||(this[F]=!1,this[v]=!0,this.emit("resume"),this.buffer.length?this[p]():this[o]?this[a]():this.emit("drain"))}resume(){return this[O]()}pause(){this[v]=!1,this[F]=!0}get destroyed(){return this[S]}get flowing(){return this[v]}get paused(){return this[F]}[x](D){this[b]?this[R]+=1:this[R]+=D.length,this.buffer.push(D)}[L](){return this.buffer.length&&(this[b]?this[R]-=1:this[R]-=this.buffer[0].length),this.buffer.shift()}[p](D){do;while(this[g](this[L]()));!D&&!this.buffer.length&&!this[o]&&this.emit("drain")}[g](D){return D?(this.emit("data",D),this.flowing):!1}pipe(D,A){if(this[S])return;let w=this[u];return A=A||{},D===r.stdout||D===r.stderr?A.end=!1:A.end=A.end!==!1,A.proxyErrors=!!A.proxyErrors,w?A.end&&D.end():(this.pipes.push(A.proxyErrors?new d(this,D,A):new P(this,D,A)),this[U]?V(()=>this[O]()):this[O]()),D}unpipe(D){let A=this.pipes.find(w=>w.dest===D);A&&(this.pipes.splice(this.pipes.indexOf(A),1),A.unpipe())}addListener(D,A){return this.on(D,A)}on(D,A){let w=super.on(D,A);return D==="data"&&!this.pipes.length&&!this.flowing?this[O]():D==="readable"&&this[R]!==0?super.emit("readable"):k(D)&&this[u]?(super.emit(D),this.removeAllListeners(D)):D==="error"&&this[c]&&(this[U]?V(()=>A.call(this,this[c])):A.call(this,this[c])),w}get emittedEnd(){return this[u]}[a](){!this[l]&&!this[u]&&!this[S]&&this.buffer.length===0&&this[o]&&(this[l]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[f]&&this.emit("close"),this[l]=!1)}emit(D,A,...w){if(D!=="error"&&D!=="close"&&D!==S&&this[S])return;if(D==="data")return A?this[U]?V(()=>this[N](A)):this[N](A):!1;if(D==="end")return this[H]();if(D==="close"){if(this[f]=!0,!this[u]&&!this[S])return;let M=super.emit("close");return this.removeAllListeners("close"),M}else if(D==="error"){this[c]=A;let M=super.emit("error",A);return this[a](),M}else if(D==="resume"){let M=super.emit("resume");return this[a](),M}else if(D==="finish"||D==="prefinish"){let M=super.emit(D);return this.removeAllListeners(D),M}let I=super.emit(D,A,...w);return this[a](),I}[N](D){for(let w of this.pipes)w.dest.write(D)===!1&&this.pause();let A=super.emit("data",D);return this[a](),A}[H](){this[u]||(this[u]=!0,this.readable=!1,this[U]?V(()=>this[T]()):this[T]())}[T](){if(this[E]){let A=this[E].end();if(A){for(let w of this.pipes)w.dest.write(A);super.emit("data",A)}}for(let A of this.pipes)A.end();let D=super.emit("end");return this.removeAllListeners("end"),D}collect(){let D=[];this[b]||(D.dataLength=0);let A=this.promise();return this.on("data",w=>{D.push(w),this[b]||(D.dataLength+=w.length)}),A.then(()=>D)}concat(){return this[b]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(D=>this[b]?Promise.reject(new Error("cannot concat in objectMode")):this[y]?D.join(""):Buffer.concat(D,D.dataLength))}promise(){return new Promise((D,A)=>{this.on(S,()=>A(new Error("stream destroyed"))),this.on("error",w=>A(w)),this.on("end",()=>D())})}[B](){return{next:()=>{let D=this.read();if(D!==null)return Promise.resolve({done:!1,value:D});if(this[o])return Promise.resolve({done:!0});let A=null,w=null,I=Q=>{this.removeListener("data",M),this.removeListener("end",Z),w(Q)},M=Q=>{this.removeListener("error",I),this.removeListener("end",Z),this.pause(),A({value:Q,done:!!this[o]})},Z=()=>{this.removeListener("error",I),this.removeListener("data",M),A({done:!0})},q=()=>I(new Error("stream destroyed"));return new Promise((Q,G)=>{w=G,A=Q,this.once(S,q),this.once("error",I),this.once("end",Z),this.once("data",M)})}}}[C](){return{next:()=>{let D=this.read();return{value:D,done:D===null}}}}destroy(D){return this[S]?(D?this.emit("error",D):this.emit(S),this):(this[S]=!0,this.buffer.length=0,this[R]=0,typeof this.close=="function"&&!this[f]&&this.close(),D?this.emit("error",D):this.emit(S),this)}static isStream(D){return!!D&&(D instanceof JD||D instanceof n||D instanceof i&&(typeof D.pipe=="function"||typeof D.write=="function"&&typeof D.end=="function"))}}}),XD=te(t=>{"use strict";W();var e=re("assert"),r=re("buffer").Buffer,i=re("zlib"),n=t.constants=tT(),s=ZD(),o=r.concat,a=Symbol("_superWrite"),u=class extends Error{constructor(k){super("zlib: "+k.message),this.code=k.code,this.errno=k.errno,this.code||(this.code="ZLIB_ERROR"),this.message="zlib: "+k.message,Error.captureStackTrace(this,this.constructor)}get name(){return"ZlibError"}},l=Symbol("opts"),c=Symbol("flushFlag"),f=Symbol("finishFlushFlag"),h=Symbol("fullFlushFlag"),p=Symbol("handle"),g=Symbol("onError"),y=Symbol("sawError"),E=Symbol("level"),v=Symbol("strategy"),F=Symbol("ended"),O=Symbol("_defaultFullFlush"),R=class extends s{constructor(k,j){if(!k||typeof k!="object")throw new TypeError("invalid options for ZlibBase constructor");super(k),this[y]=!1,this[F]=!1,this[l]=k,this[c]=k.flush,this[f]=k.finishFlush;try{this[p]=new i[j](k)}catch(z){throw new u(z)}this[g]=z=>{this[y]||(this[y]=!0,this.close(),this.emit("error",z))},this[p].on("error",z=>this[g](new u(z))),this.once("end",()=>this.close)}close(){this[p]&&(this[p].close(),this[p]=null,this.emit("close"))}reset(){if(!this[y])return e(this[p],"zlib binding closed"),this[p].reset()}flush(k){this.ended||(typeof k!="number"&&(k=this[h]),this.write(Object.assign(r.alloc(0),{[c]:k})))}end(k,j,z){return k&&this.write(k,j),this.flush(this[f]),this[F]=!0,super.end(null,null,z)}get ended(){return this[F]}write(k,j,z){if(typeof j=="function"&&(z=j,j="utf8"),typeof k=="string"&&(k=r.from(k,j)),this[y])return;e(this[p],"zlib binding closed");let P=this[p]._handle,d=P.close;P.close=()=>{};let m=this[p].close;this[p].close=()=>{},r.concat=w=>w;let D;try{let w=typeof k[c]=="number"?k[c]:this[c];D=this[p]._processChunk(k,w),r.concat=o}catch(w){r.concat=o,this[g](new u(w))}finally{this[p]&&(this[p]._handle=P,P.close=d,this[p].close=m,this[p].removeAllListeners("error"))}this[p]&&this[p].on("error",w=>this[g](new u(w)));let A;if(D)if(Array.isArray(D)&&D.length>0){A=this[a](r.from(D[0]));for(let w=1;w<D.length;w++)A=this[a](D[w])}else A=this[a](r.from(D));return z&&z(),A}[a](k){return super.write(k)}},x=class extends R{constructor(k,j){k=k||{},k.flush=k.flush||n.Z_NO_FLUSH,k.finishFlush=k.finishFlush||n.Z_FINISH,super(k,j),this[h]=n.Z_FULL_FLUSH,this[E]=k.level,this[v]=k.strategy}params(k,j){if(!this[y]){if(!this[p])throw new Error("cannot switch params when binding is closed");if(!this[p].params)throw new Error("not supported in this implementation");if(this[E]!==k||this[v]!==j){this.flush(n.Z_SYNC_FLUSH),e(this[p],"zlib binding closed");let z=this[p].flush;this[p].flush=(P,d)=>{this.flush(P),d()};try{this[p].params(k,j)}finally{this[p].flush=z}this[p]&&(this[E]=k,this[v]=j)}}}},L=class extends x{constructor(k){super(k,"Deflate")}},b=class extends x{constructor(k){super(k,"Inflate")}},S=Symbol("_portable"),N=class extends x{constructor(k){super(k,"Gzip"),this[S]=k&&!!k.portable}[a](k){return this[S]?(this[S]=!1,k[9]=255,super[a](k)):super[a](k)}},H=class extends x{constructor(k){super(k,"Gunzip")}},T=class extends x{constructor(k){super(k,"DeflateRaw")}},U=class extends x{constructor(k){super(k,"InflateRaw")}},V=class extends x{constructor(k){super(k,"Unzip")}},K=class extends R{constructor(k,j){k=k||{},k.flush=k.flush||n.BROTLI_OPERATION_PROCESS,k.finishFlush=k.finishFlush||n.BROTLI_OPERATION_FINISH,super(k,j),this[h]=n.BROTLI_OPERATION_FLUSH}},B=class extends K{constructor(k){super(k,"BrotliCompress")}},C=class extends K{constructor(k){super(k,"BrotliDecompress")}};t.Deflate=L,t.Inflate=b,t.Gzip=N,t.Gunzip=H,t.DeflateRaw=T,t.InflateRaw=U,t.Unzip=V,typeof i.BrotliCompress=="function"?(t.BrotliCompress=B,t.BrotliDecompress=C):t.BrotliCompress=t.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}}),Zn=te((t,e)=>{W();var r=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform;e.exports=r!=="win32"?i=>i:i=>i&&i.replace(/\\/g,"/")}),Ih=te((t,e)=>{"use strict";W();var r=Ph(),i=Zn(),n=Symbol("slurp");e.exports=class extends r{constructor(s,o,a){switch(super(),this.pause(),this.extended=o,this.globalExtended=a,this.header=s,this.startBlockSize=512*Math.ceil(s.size/512),this.blockRemain=this.startBlockSize,this.remain=s.size,this.type=s.type,this.meta=!1,this.ignore=!1,this.type){case"File":case"OldFile":case"Link":case"SymbolicLink":case"CharacterDevice":case"BlockDevice":case"Directory":case"FIFO":case"ContiguousFile":case"GNUDumpDir":break;case"NextFileHasLongLinkpath":case"NextFileHasLongPath":case"OldGnuLongPath":case"GlobalExtendedHeader":case"ExtendedHeader":case"OldExtendedHeader":this.meta=!0;break;default:this.ignore=!0}this.path=i(s.path),this.mode=s.mode,this.mode&&(this.mode=this.mode&4095),this.uid=s.uid,this.gid=s.gid,this.uname=s.uname,this.gname=s.gname,this.size=s.size,this.mtime=s.mtime,this.atime=s.atime,this.ctime=s.ctime,this.linkpath=i(s.linkpath),this.uname=s.uname,this.gname=s.gname,o&&this[n](o),a&&this[n](a,!0)}write(s){let o=s.length;if(o>this.blockRemain)throw new Error("writing more to entry than is appropriate");let a=this.remain,u=this.blockRemain;return this.remain=Math.max(0,a-o),this.blockRemain=Math.max(0,u-o),this.ignore?!0:a>=o?super.write(s):super.write(s.slice(0,a))}[n](s,o){for(let a in s)s[a]!==null&&s[a]!==void 0&&!(o&&a==="path")&&(this[a]=a==="path"||a==="linkpath"?i(s[a]):s[a])}}}),QD=te(t=>{"use strict";W(),t.name=new Map([["0","File"],["","OldFile"],["1","Link"],["2","SymbolicLink"],["3","CharacterDevice"],["4","BlockDevice"],["5","Directory"],["6","FIFO"],["7","ContiguousFile"],["g","GlobalExtendedHeader"],["x","ExtendedHeader"],["A","SolarisACL"],["D","GNUDumpDir"],["I","Inode"],["K","NextFileHasLongLinkpath"],["L","NextFileHasLongPath"],["M","ContinuationFile"],["N","OldGnuLongPath"],["S","SparseFile"],["V","TapeVolumeHeader"],["X","OldExtendedHeader"]]),t.code=new Map(Array.from(t.name).map(e=>[e[1],e[0]]))}),rT=te((t,e)=>{"use strict";W();var r=(c,f)=>{if(Number.isSafeInteger(c))c<0?n(c,f):i(c,f);else throw Error("cannot encode number outside of javascript safe integer range");return f},i=(c,f)=>{f[0]=128;for(var h=f.length;h>1;h--)f[h-1]=c&255,c=Math.floor(c/256)},n=(c,f)=>{f[0]=255;var h=!1;c=c*-1;for(var p=f.length;p>1;p--){var g=c&255;c=Math.floor(c/256),h?f[p-1]=u(g):g===0?f[p-1]=0:(h=!0,f[p-1]=l(g))}},s=c=>{let f=c[0],h=f===128?a(c.slice(1,c.length)):f===255?o(c):null;if(h===null)throw Error("invalid base256 encoding");if(!Number.isSafeInteger(h))throw Error("parsed number outside of javascript safe integer range");return h},o=c=>{for(var f=c.length,h=0,p=!1,g=f-1;g>-1;g--){var y=c[g],E;p?E=u(y):y===0?E=y:(p=!0,E=l(y)),E!==0&&(h-=E*Math.pow(256,f-g-1))}return h},a=c=>{for(var f=c.length,h=0,p=f-1;p>-1;p--){var g=c[p];g!==0&&(h+=g*Math.pow(256,f-p-1))}return h},u=c=>(255^c)&255,l=c=>(255^c)+1&255;e.exports={encode:r,parse:s}}),Jn=te((t,e)=>{"use strict";W();var r=QD(),i=re("path").posix,n=rT(),s=Symbol("slurp"),o=Symbol("type"),a=class{constructor(b,S,N,H){this.cksumValid=!1,this.needPax=!1,this.nullBlock=!1,this.block=null,this.path=null,this.mode=null,this.uid=null,this.gid=null,this.size=null,this.mtime=null,this.cksum=null,this[o]="0",this.linkpath=null,this.uname=null,this.gname=null,this.devmaj=0,this.devmin=0,this.atime=null,this.ctime=null,Buffer.isBuffer(b)?this.decode(b,S||0,N,H):b&&this.set(b)}decode(b,S,N,H){if(S||(S=0),!b||!(b.length>=S+512))throw new Error("need 512 bytes for header");if(this.path=l(b,S,100),this.mode=h(b,S+100,8),this.uid=h(b,S+108,8),this.gid=h(b,S+116,8),this.size=h(b,S+124,12),this.mtime=c(b,S+136,12),this.cksum=h(b,S+148,12),this[s](N),this[s](H,!0),this[o]=l(b,S+156,1),this[o]===""&&(this[o]="0"),this[o]==="0"&&this.path.slice(-1)==="/"&&(this[o]="5"),this[o]==="5"&&(this.size=0),this.linkpath=l(b,S+157,100),b.slice(S+257,S+265).toString()==="ustar\x0000")if(this.uname=l(b,S+265,32),this.gname=l(b,S+297,32),this.devmaj=h(b,S+329,8),this.devmin=h(b,S+337,8),b[S+475]!==0){let U=l(b,S+345,155);this.path=U+"/"+this.path}else{let U=l(b,S+345,130);U&&(this.path=U+"/"+this.path),this.atime=c(b,S+476,12),this.ctime=c(b,S+488,12)}let T=8*32;for(let U=S;U<S+148;U++)T+=b[U];for(let U=S+156;U<S+512;U++)T+=b[U];this.cksumValid=T===this.cksum,this.cksum===null&&T===8*32&&(this.nullBlock=!0)}[s](b,S){for(let N in b)b[N]!==null&&b[N]!==void 0&&!(S&&N==="path")&&(this[N]=b[N])}encode(b,S){if(b||(b=this.block=Buffer.alloc(512),S=0),S||(S=0),!(b.length>=S+512))throw new Error("need 512 bytes for header");let N=this.ctime||this.atime?130:155,H=u(this.path||"",N),T=H[0],U=H[1];this.needPax=H[2],this.needPax=L(b,S,100,T)||this.needPax,this.needPax=E(b,S+100,8,this.mode)||this.needPax,this.needPax=E(b,S+108,8,this.uid)||this.needPax,this.needPax=E(b,S+116,8,this.gid)||this.needPax,this.needPax=E(b,S+124,12,this.size)||this.needPax,this.needPax=R(b,S+136,12,this.mtime)||this.needPax,b[S+156]=this[o].charCodeAt(0),this.needPax=L(b,S+157,100,this.linkpath)||this.needPax,b.write("ustar\x0000",S+257,8),this.needPax=L(b,S+265,32,this.uname)||this.needPax,this.needPax=L(b,S+297,32,this.gname)||this.needPax,this.needPax=E(b,S+329,8,this.devmaj)||this.needPax,this.needPax=E(b,S+337,8,this.devmin)||this.needPax,this.needPax=L(b,S+345,N,U)||this.needPax,b[S+475]!==0?this.needPax=L(b,S+345,155,U)||this.needPax:(this.needPax=L(b,S+345,130,U)||this.needPax,this.needPax=R(b,S+476,12,this.atime)||this.needPax,this.needPax=R(b,S+488,12,this.ctime)||this.needPax);let V=8*32;for(let K=S;K<S+148;K++)V+=b[K];for(let K=S+156;K<S+512;K++)V+=b[K];return this.cksum=V,E(b,S+148,8,this.cksum),this.cksumValid=!0,this.needPax}set(b){for(let S in b)b[S]!==null&&b[S]!==void 0&&(this[S]=b[S])}get type(){return r.name.get(this[o])||this[o]}get typeKey(){return this[o]}set type(b){r.code.has(b)?this[o]=r.code.get(b):this[o]=b}},u=(b,S)=>{let N=b,H="",T,U=i.parse(b).root||".";if(Buffer.byteLength(N)<100)T=[N,H,!1];else{H=i.dirname(N),N=i.basename(N);do Buffer.byteLength(N)<=100&&Buffer.byteLength(H)<=S?T=[N,H,!1]:Buffer.byteLength(N)>100&&Buffer.byteLength(H)<=S?T=[N.slice(0,100-1),H,!0]:(N=i.join(i.basename(H),N),H=i.dirname(H));while(H!==U&&!T);T||(T=[b.slice(0,100-1),"",!0])}return T},l=(b,S,N)=>b.slice(S,S+N).toString("utf8").replace(/\0.*/,""),c=(b,S,N)=>f(h(b,S,N)),f=b=>b===null?null:new Date(b*1e3),h=(b,S,N)=>b[S]&128?n.parse(b.slice(S,S+N)):g(b,S,N),p=b=>isNaN(b)?null:b,g=(b,S,N)=>p(parseInt(b.slice(S,S+N).toString("utf8").replace(/\0.*$/,"").trim(),8)),y={12:8589934591,8:2097151},E=(b,S,N,H)=>H===null?!1:H>y[N]||H<0?(n.encode(H,b.slice(S,S+N)),!0):(v(b,S,N,H),!1),v=(b,S,N,H)=>b.write(F(H,N),S,N,"ascii"),F=(b,S)=>O(Math.floor(b).toString(8),S),O=(b,S)=>(b.length===S-1?b:new Array(S-b.length-1).join("0")+b+" ")+"\0",R=(b,S,N,H)=>H===null?!1:E(b,S,N,H.getTime()/1e3),x=new Array(156).join("\0"),L=(b,S,N,H)=>H===null?!1:(b.write(H+x,S,N,"utf8"),H.length!==Buffer.byteLength(H)||H.length>N);e.exports=a}),Nh=te((t,e)=>{"use strict";W();var r=Jn(),i=re("path"),n=class{constructor(u,l){this.atime=u.atime||null,this.charset=u.charset||null,this.comment=u.comment||null,this.ctime=u.ctime||null,this.gid=u.gid||null,this.gname=u.gname||null,this.linkpath=u.linkpath||null,this.mtime=u.mtime||null,this.path=u.path||null,this.size=u.size||null,this.uid=u.uid||null,this.uname=u.uname||null,this.dev=u.dev||null,this.ino=u.ino||null,this.nlink=u.nlink||null,this.global=l||!1}encode(){let u=this.encodeBody();if(u==="")return null;let l=Buffer.byteLength(u),c=512*Math.ceil(1+l/512),f=Buffer.allocUnsafe(c);for(let h=0;h<512;h++)f[h]=0;new r({path:("PaxHeader/"+i.basename(this.path)).slice(0,99),mode:this.mode||420,uid:this.uid||null,gid:this.gid||null,size:l,mtime:this.mtime||null,type:this.global?"GlobalExtendedHeader":"ExtendedHeader",linkpath:"",uname:this.uname||"",gname:this.gname||"",devmaj:0,devmin:0,atime:this.atime||null,ctime:this.ctime||null}).encode(f),f.write(u,512,l,"utf8");for(let h=l+512;h<f.length;h++)f[h]=0;return f}encodeBody(){return this.encodeField("path")+this.encodeField("ctime")+this.encodeField("atime")+this.encodeField("dev")+this.encodeField("ino")+this.encodeField("nlink")+this.encodeField("charset")+this.encodeField("comment")+this.encodeField("gid")+this.encodeField("gname")+this.encodeField("linkpath")+this.encodeField("mtime")+this.encodeField("size")+this.encodeField("uid")+this.encodeField("uname")}encodeField(u){if(this[u]===null||this[u]===void 0)return"";let l=this[u]instanceof Date?this[u].getTime()/1e3:this[u],c=" "+(u==="dev"||u==="ino"||u==="nlink"?"SCHILY.":"")+u+"="+l+`
41
41
  `,f=Buffer.byteLength(c),h=Math.floor(Math.log(f)/Math.log(10))+1;return f+h>=Math.pow(10,h)&&(h+=1),h+f+c}};n.parse=(u,l,c)=>new n(s(o(u),l),c);var s=(u,l)=>l?Object.keys(u).reduce((c,f)=>(c[f]=u[f],c),l):u,o=u=>u.replace(/\n$/,"").split(`
42
- `).reduce(a,Object.create(null)),a=(u,l)=>{let c=parseInt(l,10);if(c!==Buffer.byteLength(l)+1)return u;l=l.slice((c+" ").length);let f=l.split("="),h=f.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!h)return u;let p=f.join("=");return u[h]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(h)?new Date(p*1e3):/^[0-9]+$/.test(p)?+p:p,u};e.exports=n}),Xn=te((t,e)=>{W(),e.exports=r=>{let i=r.length-1,n=-1;for(;i>-1&&r.charAt(i)==="/";)n=i,i--;return n===-1?r:r.slice(0,n)}}),Mh=te((t,e)=>{"use strict";W(),e.exports=r=>class extends r{warn(i,n,s={}){this.file&&(s.file=this.file),this.cwd&&(s.cwd=this.cwd),s.code=n instanceof Error&&n.code||i,s.tarCode=i,!this.strict&&s.recoverable!==!1?(n instanceof Error&&(s=Object.assign(n,s),n=n.message),this.emit("warn",s.tarCode,n,s)):n instanceof Error?this.emit("error",Object.assign(n,s)):this.emit("error",Object.assign(new Error(`${i}: ${n}`),s))}}}),eb=te((t,e)=>{"use strict";W();var r=["|","<",">","?",":"],i=r.map(o=>String.fromCharCode(61440+o.charCodeAt(0))),n=new Map(r.map((o,a)=>[o,i[a]])),s=new Map(i.map((o,a)=>[o,r[a]]));e.exports={encode:o=>r.reduce((a,u)=>a.split(u).join(n.get(u)),o),decode:o=>i.reduce((a,u)=>a.split(u).join(s.get(u)),o)}}),tb=te((t,e)=>{W();var{isAbsolute:r,parse:i}=re("path").win32;e.exports=n=>{let s="",o=i(n);for(;r(n)||o.root;){let a=n.charAt(0)==="/"&&n.slice(0,4)!=="//?/"?"/":o.root;n=n.slice(a.length),s+=a,o=i(n)}return[s,n]}}),iT=te((t,e)=>{"use strict";W(),e.exports=(r,i,n)=>(r&=4095,n&&(r=(r|384)&-19),i&&(r&256&&(r|=64),r&32&&(r|=8),r&4&&(r|=1)),r)}),rb=te((t,e)=>{"use strict";W();var r=Ph(),i=Nh(),n=Jn(),s=re("fs"),o=re("path"),a=Zn(),u=Xn(),l=(m,D)=>D?(m=a(m).replace(/^\.(\/|$)/,""),u(D)+"/"+m):a(m),c=16*1024*1024,f=Symbol("process"),h=Symbol("file"),p=Symbol("directory"),g=Symbol("symlink"),y=Symbol("hardlink"),E=Symbol("header"),v=Symbol("read"),F=Symbol("lstat"),O=Symbol("onlstat"),R=Symbol("onread"),x=Symbol("onreadlink"),L=Symbol("openfile"),b=Symbol("onopenfile"),S=Symbol("close"),N=Symbol("mode"),H=Symbol("awaitDrain"),T=Symbol("ondrain"),U=Symbol("prefix"),V=Symbol("hadError"),K=Mh(),B=eb(),C=tb(),k=iT(),j=K(class extends r{constructor(m,D){if(D=D||{},super(D),typeof m!="string")throw new TypeError("path is required");this.path=a(m),this.portable=!!D.portable,this.myuid=process.getuid&&process.getuid()||0,this.myuser=process.env.USER||"",this.maxReadSize=D.maxReadSize||c,this.linkCache=D.linkCache||new Map,this.statCache=D.statCache||new Map,this.preservePaths=!!D.preservePaths,this.cwd=a(D.cwd||process.cwd()),this.strict=!!D.strict,this.noPax=!!D.noPax,this.noMtime=!!D.noMtime,this.mtime=D.mtime||null,this.prefix=D.prefix?a(D.prefix):null,this.fd=null,this.blockLen=null,this.blockRemain=null,this.buf=null,this.offset=null,this.length=null,this.pos=null,this.remain=null,typeof D.onwarn=="function"&&this.on("warn",D.onwarn);let A=!1;if(!this.preservePaths){let[w,I]=C(this.path);w&&(this.path=I,A=w)}this.win32=!!D.win32||process.platform==="win32",this.win32&&(this.path=B.decode(this.path.replace(/\\/g,"/")),m=m.replace(/\\/g,"/")),this.absolute=a(D.absolute||o.resolve(this.cwd,m)),this.path===""&&(this.path="./"),A&&this.warn("TAR_ENTRY_INFO",`stripping ${A} from absolute path`,{entry:this,path:A+this.path}),this.statCache.has(this.absolute)?this[O](this.statCache.get(this.absolute)):this[F]()}emit(m,...D){return m==="error"&&(this[V]=!0),super.emit(m,...D)}[F](){s.lstat(this.absolute,(m,D)=>{if(m)return this.emit("error",m);this[O](D)})}[O](m){this.statCache.set(this.absolute,m),this.stat=m,m.isFile()||(m.size=0),this.type=d(m),this.emit("stat",m),this[f]()}[f](){switch(this.type){case"File":return this[h]();case"Directory":return this[p]();case"SymbolicLink":return this[g]();default:return this.end()}}[N](m){return k(m,this.type==="Directory",this.portable)}[U](m){return l(m,this.prefix)}[E](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new n({path:this[U](this.path),linkpath:this.type==="Link"?this[U](this.linkpath):this.linkpath,mode:this[N](this.stat.mode),uid:this.portable?null:this.stat.uid,gid:this.portable?null:this.stat.gid,size:this.stat.size,mtime:this.noMtime?null:this.mtime||this.stat.mtime,type:this.type,uname:this.portable?null:this.stat.uid===this.myuid?this.myuser:"",atime:this.portable?null:this.stat.atime,ctime:this.portable?null:this.stat.ctime}),this.header.encode()&&!this.noPax&&super.write(new i({atime:this.portable?null:this.header.atime,ctime:this.portable?null:this.header.ctime,gid:this.portable?null:this.header.gid,mtime:this.noMtime?null:this.mtime||this.header.mtime,path:this[U](this.path),linkpath:this.type==="Link"?this[U](this.linkpath):this.linkpath,size:this.header.size,uid:this.portable?null:this.header.uid,uname:this.portable?null:this.header.uname,dev:this.portable?null:this.stat.dev,ino:this.portable?null:this.stat.ino,nlink:this.portable?null:this.stat.nlink}).encode()),super.write(this.header.block)}[p](){this.path.slice(-1)!=="/"&&(this.path+="/"),this.stat.size=0,this[E](),this.end()}[g](){s.readlink(this.absolute,(m,D)=>{if(m)return this.emit("error",m);this[x](D)})}[x](m){this.linkpath=a(m),this[E](),this.end()}[y](m){this.type="Link",this.linkpath=a(o.relative(this.cwd,m)),this.stat.size=0,this[E](),this.end()}[h](){if(this.stat.nlink>1){let m=this.stat.dev+":"+this.stat.ino;if(this.linkCache.has(m)){let D=this.linkCache.get(m);if(D.indexOf(this.cwd)===0)return this[y](D)}this.linkCache.set(m,this.absolute)}if(this[E](),this.stat.size===0)return this.end();this[L]()}[L](){s.open(this.absolute,"r",(m,D)=>{if(m)return this.emit("error",m);this[b](D)})}[b](m){if(this.fd=m,this[V])return this[S]();this.blockLen=512*Math.ceil(this.stat.size/512),this.blockRemain=this.blockLen;let D=Math.min(this.blockLen,this.maxReadSize);this.buf=Buffer.allocUnsafe(D),this.offset=0,this.pos=0,this.remain=this.stat.size,this.length=this.buf.length,this[v]()}[v](){let{fd:m,buf:D,offset:A,length:w,pos:I}=this;s.read(m,D,A,w,I,(M,Z)=>{if(M)return this[S](()=>this.emit("error",M));this[R](Z)})}[S](m){s.close(this.fd,m)}[R](m){if(m<=0&&this.remain>0){let A=new Error("encountered unexpected EOF");return A.path=this.absolute,A.syscall="read",A.code="EOF",this[S](()=>this.emit("error",A))}if(m>this.remain){let A=new Error("did not encounter expected EOF");return A.path=this.absolute,A.syscall="read",A.code="EOF",this[S](()=>this.emit("error",A))}if(m===this.remain)for(let A=m;A<this.length&&m<this.blockRemain;A++)this.buf[A+this.offset]=0,m++,this.remain++;let D=this.offset===0&&m===this.buf.length?this.buf:this.buf.slice(this.offset,this.offset+m);this.write(D)?this[T]():this[H](()=>this[T]())}[H](m){this.once("drain",m)}write(m){if(this.blockRemain<m.length){let D=new Error("writing more data than expected");return D.path=this.absolute,this.emit("error",D)}return this.remain-=m.length,this.blockRemain-=m.length,this.pos+=m.length,this.offset+=m.length,super.write(m)}[T](){if(!this.remain)return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),this[S](m=>m?this.emit("error",m):this.end());this.offset>=this.length&&(this.buf=Buffer.allocUnsafe(Math.min(this.blockRemain,this.buf.length)),this.offset=0),this.length=this.buf.length-this.offset,this[v]()}}),z=class extends j{[F](){this[O](s.lstatSync(this.absolute))}[g](){this[x](s.readlinkSync(this.absolute))}[L](){this[b](s.openSync(this.absolute,"r"))}[v](){let m=!0;try{let{fd:D,buf:A,offset:w,length:I,pos:M}=this,Z=s.readSync(D,A,w,I,M);this[R](Z),m=!1}finally{if(m)try{this[S](()=>{})}catch{}}}[H](m){m()}[S](m){s.closeSync(this.fd),m()}},P=K(class extends r{constructor(m,D){D=D||{},super(D),this.preservePaths=!!D.preservePaths,this.portable=!!D.portable,this.strict=!!D.strict,this.noPax=!!D.noPax,this.noMtime=!!D.noMtime,this.readEntry=m,this.type=m.type,this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.prefix=D.prefix||null,this.path=a(m.path),this.mode=this[N](m.mode),this.uid=this.portable?null:m.uid,this.gid=this.portable?null:m.gid,this.uname=this.portable?null:m.uname,this.gname=this.portable?null:m.gname,this.size=m.size,this.mtime=this.noMtime?null:D.mtime||m.mtime,this.atime=this.portable?null:m.atime,this.ctime=this.portable?null:m.ctime,this.linkpath=a(m.linkpath),typeof D.onwarn=="function"&&this.on("warn",D.onwarn);let A=!1;if(!this.preservePaths){let[w,I]=C(this.path);w&&(this.path=I,A=w)}this.remain=m.size,this.blockRemain=m.startBlockSize,this.header=new n({path:this[U](this.path),linkpath:this.type==="Link"?this[U](this.linkpath):this.linkpath,mode:this.mode,uid:this.portable?null:this.uid,gid:this.portable?null:this.gid,size:this.size,mtime:this.noMtime?null:this.mtime,type:this.type,uname:this.portable?null:this.uname,atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime}),A&&this.warn("TAR_ENTRY_INFO",`stripping ${A} from absolute path`,{entry:this,path:A+this.path}),this.header.encode()&&!this.noPax&&super.write(new i({atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime,gid:this.portable?null:this.gid,mtime:this.noMtime?null:this.mtime,path:this[U](this.path),linkpath:this.type==="Link"?this[U](this.linkpath):this.linkpath,size:this.size,uid:this.portable?null:this.uid,uname:this.portable?null:this.uname,dev:this.portable?null:this.readEntry.dev,ino:this.portable?null:this.readEntry.ino,nlink:this.portable?null:this.readEntry.nlink}).encode()),super.write(this.header.block),m.pipe(this)}[U](m){return l(m,this.prefix)}[N](m){return k(m,this.type==="Directory",this.portable)}write(m){let D=m.length;if(D>this.blockRemain)throw new Error("writing more to entry than is appropriate");return this.blockRemain-=D,super.write(m)}end(){return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),super.end()}});j.Sync=z,j.Tar=P;var d=m=>m.isFile()?"File":m.isDirectory()?"Directory":m.isSymbolicLink()?"SymbolicLink":"Unsupported";e.exports=j}),nT=te((t,e)=>{"use strict";W(),e.exports=function(r){r.prototype[Symbol.iterator]=function*(){for(let i=this.head;i;i=i.next)yield i.value}}}),ib=te((t,e)=>{"use strict";W(),e.exports=r,r.Node=o,r.create=r;function r(a){var u=this;if(u instanceof r||(u=new r),u.tail=null,u.head=null,u.length=0,a&&typeof a.forEach=="function")a.forEach(function(f){u.push(f)});else if(arguments.length>0)for(var l=0,c=arguments.length;l<c;l++)u.push(arguments[l]);return u}r.prototype.removeNode=function(a){if(a.list!==this)throw new Error("removing node which does not belong to this list");var u=a.next,l=a.prev;return u&&(u.prev=l),l&&(l.next=u),a===this.head&&(this.head=u),a===this.tail&&(this.tail=l),a.list.length--,a.next=null,a.prev=null,a.list=null,u},r.prototype.unshiftNode=function(a){if(a!==this.head){a.list&&a.list.removeNode(a);var u=this.head;a.list=this,a.next=u,u&&(u.prev=a),this.head=a,this.tail||(this.tail=a),this.length++}},r.prototype.pushNode=function(a){if(a!==this.tail){a.list&&a.list.removeNode(a);var u=this.tail;a.list=this,a.prev=u,u&&(u.next=a),this.tail=a,this.head||(this.head=a),this.length++}},r.prototype.push=function(){for(var a=0,u=arguments.length;a<u;a++)n(this,arguments[a]);return this.length},r.prototype.unshift=function(){for(var a=0,u=arguments.length;a<u;a++)s(this,arguments[a]);return this.length},r.prototype.pop=function(){if(this.tail){var a=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,a}},r.prototype.shift=function(){if(this.head){var a=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,a}},r.prototype.forEach=function(a,u){u=u||this;for(var l=this.head,c=0;l!==null;c++)a.call(u,l.value,c,this),l=l.next},r.prototype.forEachReverse=function(a,u){u=u||this;for(var l=this.tail,c=this.length-1;l!==null;c--)a.call(u,l.value,c,this),l=l.prev},r.prototype.get=function(a){for(var u=0,l=this.head;l!==null&&u<a;u++)l=l.next;if(u===a&&l!==null)return l.value},r.prototype.getReverse=function(a){for(var u=0,l=this.tail;l!==null&&u<a;u++)l=l.prev;if(u===a&&l!==null)return l.value},r.prototype.map=function(a,u){u=u||this;for(var l=new r,c=this.head;c!==null;)l.push(a.call(u,c.value,this)),c=c.next;return l},r.prototype.mapReverse=function(a,u){u=u||this;for(var l=new r,c=this.tail;c!==null;)l.push(a.call(u,c.value,this)),c=c.prev;return l},r.prototype.reduce=function(a,u){var l,c=this.head;if(arguments.length>1)l=u;else if(this.head)c=this.head.next,l=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=0;c!==null;f++)l=a(l,c.value,f),c=c.next;return l},r.prototype.reduceReverse=function(a,u){var l,c=this.tail;if(arguments.length>1)l=u;else if(this.tail)c=this.tail.prev,l=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=this.length-1;c!==null;f--)l=a(l,c.value,f),c=c.prev;return l},r.prototype.toArray=function(){for(var a=new Array(this.length),u=0,l=this.head;l!==null;u++)a[u]=l.value,l=l.next;return a},r.prototype.toArrayReverse=function(){for(var a=new Array(this.length),u=0,l=this.tail;l!==null;u++)a[u]=l.value,l=l.prev;return a},r.prototype.slice=function(a,u){u=u||this.length,u<0&&(u+=this.length),a=a||0,a<0&&(a+=this.length);var l=new r;if(u<a||u<0)return l;a<0&&(a=0),u>this.length&&(u=this.length);for(var c=0,f=this.head;f!==null&&c<a;c++)f=f.next;for(;f!==null&&c<u;c++,f=f.next)l.push(f.value);return l},r.prototype.sliceReverse=function(a,u){u=u||this.length,u<0&&(u+=this.length),a=a||0,a<0&&(a+=this.length);var l=new r;if(u<a||u<0)return l;a<0&&(a=0),u>this.length&&(u=this.length);for(var c=this.length,f=this.tail;f!==null&&c>u;c--)f=f.prev;for(;f!==null&&c>a;c--,f=f.prev)l.push(f.value);return l},r.prototype.splice=function(a,u,...l){a>this.length&&(a=this.length-1),a<0&&(a=this.length+a);for(var c=0,f=this.head;f!==null&&c<a;c++)f=f.next;for(var h=[],c=0;f&&c<u;c++)h.push(f.value),f=this.removeNode(f);f===null&&(f=this.tail),f!==this.head&&f!==this.tail&&(f=f.prev);for(var c=0;c<l.length;c++)f=i(this,f,l[c]);return h},r.prototype.reverse=function(){for(var a=this.head,u=this.tail,l=a;l!==null;l=l.prev){var c=l.prev;l.prev=l.next,l.next=c}return this.head=u,this.tail=a,this};function i(a,u,l){var c=u===a.head?new o(l,null,u,a):new o(l,u,u.next,a);return c.next===null&&(a.tail=c),c.prev===null&&(a.head=c),a.length++,c}function n(a,u){a.tail=new o(u,a.tail,null,a),a.head||(a.head=a.tail),a.length++}function s(a,u){a.head=new o(u,null,a.head,a),a.tail||(a.tail=a.head),a.length++}function o(a,u,l,c){if(!(this instanceof o))return new o(a,u,l,c);this.list=c,this.value=a,u?(u.next=this,this.prev=u):this.prev=null,l?(l.prev=this,this.next=l):this.next=null}try{nT()(r)}catch{}}),jh=te((t,e)=>{"use strict";W();var r=class{constructor(d,m){this.path=d||"./",this.absolute=m,this.entry=null,this.stat=null,this.readdir=null,this.pending=!1,this.ignore=!1,this.piped=!1}},i=Ph(),n=XD(),s=Ih(),o=rb(),a=o.Sync,u=o.Tar,l=ib(),c=Buffer.alloc(1024),f=Symbol("onStat"),h=Symbol("ended"),p=Symbol("queue"),g=Symbol("current"),y=Symbol("process"),E=Symbol("processing"),v=Symbol("processJob"),F=Symbol("jobs"),O=Symbol("jobDone"),R=Symbol("addFSEntry"),x=Symbol("addTarEntry"),L=Symbol("stat"),b=Symbol("readdir"),S=Symbol("onreaddir"),N=Symbol("pipe"),H=Symbol("entry"),T=Symbol("entryOpt"),U=Symbol("writeEntryClass"),V=Symbol("write"),K=Symbol("ondrain"),B=re("fs"),C=re("path"),k=Mh(),j=Zn(),z=k(class extends i{constructor(d){super(d),d=d||Object.create(null),this.opt=d,this.file=d.file||"",this.cwd=d.cwd||process.cwd(),this.maxReadSize=d.maxReadSize,this.preservePaths=!!d.preservePaths,this.strict=!!d.strict,this.noPax=!!d.noPax,this.prefix=j(d.prefix||""),this.linkCache=d.linkCache||new Map,this.statCache=d.statCache||new Map,this.readdirCache=d.readdirCache||new Map,this[U]=o,typeof d.onwarn=="function"&&this.on("warn",d.onwarn),this.portable=!!d.portable,this.zip=null,d.gzip?(typeof d.gzip!="object"&&(d.gzip={}),this.portable&&(d.gzip.portable=!0),this.zip=new n.Gzip(d.gzip),this.zip.on("data",m=>super.write(m)),this.zip.on("end",m=>super.end()),this.zip.on("drain",m=>this[K]()),this.on("resume",m=>this.zip.resume())):this.on("drain",this[K]),this.noDirRecurse=!!d.noDirRecurse,this.follow=!!d.follow,this.noMtime=!!d.noMtime,this.mtime=d.mtime||null,this.filter=typeof d.filter=="function"?d.filter:m=>!0,this[p]=new l,this[F]=0,this.jobs=+d.jobs||4,this[E]=!1,this[h]=!1}[V](d){return super.write(d)}add(d){return this.write(d),this}end(d){return d&&this.write(d),this[h]=!0,this[y](),this}write(d){if(this[h])throw new Error("write after end");return d instanceof s?this[x](d):this[R](d),this.flowing}[x](d){let m=j(C.resolve(this.cwd,d.path));if(!this.filter(d.path,d))d.resume();else{let D=new r(d.path,m,!1);D.entry=new u(d,this[T](D)),D.entry.on("end",A=>this[O](D)),this[F]+=1,this[p].push(D)}this[y]()}[R](d){let m=j(C.resolve(this.cwd,d));this[p].push(new r(d,m)),this[y]()}[L](d){d.pending=!0,this[F]+=1;let m=this.follow?"stat":"lstat";B[m](d.absolute,(D,A)=>{d.pending=!1,this[F]-=1,D?this.emit("error",D):this[f](d,A)})}[f](d,m){this.statCache.set(d.absolute,m),d.stat=m,this.filter(d.path,m)||(d.ignore=!0),this[y]()}[b](d){d.pending=!0,this[F]+=1,B.readdir(d.absolute,(m,D)=>{if(d.pending=!1,this[F]-=1,m)return this.emit("error",m);this[S](d,D)})}[S](d,m){this.readdirCache.set(d.absolute,m),d.readdir=m,this[y]()}[y](){if(!this[E]){this[E]=!0;for(let d=this[p].head;d!==null&&this[F]<this.jobs;d=d.next)if(this[v](d.value),d.value.ignore){let m=d.next;this[p].removeNode(d),d.next=m}this[E]=!1,this[h]&&!this[p].length&&this[F]===0&&(this.zip?this.zip.end(c):(super.write(c),super.end()))}}get[g](){return this[p]&&this[p].head&&this[p].head.value}[O](d){this[p].shift(),this[F]-=1,this[y]()}[v](d){if(!d.pending){if(d.entry){d===this[g]&&!d.piped&&this[N](d);return}if(d.stat||(this.statCache.has(d.absolute)?this[f](d,this.statCache.get(d.absolute)):this[L](d)),!!d.stat&&!d.ignore&&!(!this.noDirRecurse&&d.stat.isDirectory()&&!d.readdir&&(this.readdirCache.has(d.absolute)?this[S](d,this.readdirCache.get(d.absolute)):this[b](d),!d.readdir))){if(d.entry=this[H](d),!d.entry){d.ignore=!0;return}d===this[g]&&!d.piped&&this[N](d)}}}[T](d){return{onwarn:(m,D,A)=>this.warn(m,D,A),noPax:this.noPax,cwd:this.cwd,absolute:d.absolute,preservePaths:this.preservePaths,maxReadSize:this.maxReadSize,strict:this.strict,portable:this.portable,linkCache:this.linkCache,statCache:this.statCache,noMtime:this.noMtime,mtime:this.mtime,prefix:this.prefix}}[H](d){this[F]+=1;try{return new this[U](d.path,this[T](d)).on("end",()=>this[O](d)).on("error",m=>this.emit("error",m))}catch(m){this.emit("error",m)}}[K](){this[g]&&this[g].entry&&this[g].entry.resume()}[N](d){d.piped=!0,d.readdir&&d.readdir.forEach(A=>{let w=d.path,I=w==="./"?"":w.replace(/\/*$/,"/");this[R](I+A)});let m=d.entry,D=this.zip;D?m.on("data",A=>{D.write(A)||m.pause()}):m.on("data",A=>{super.write(A)||m.pause()})}pause(){return this.zip&&this.zip.pause(),super.pause()}}),P=class extends z{constructor(d){super(d),this[U]=a}pause(){}resume(){}[L](d){let m=this.follow?"statSync":"lstatSync";this[f](d,B[m](d.absolute))}[b](d,m){this[S](d,B.readdirSync(d.absolute))}[N](d){let m=d.entry,D=this.zip;d.readdir&&d.readdir.forEach(A=>{let w=d.path,I=w==="./"?"":w.replace(/\/*$/,"/");this[R](I+A)}),D?m.on("data",A=>{D.write(A)}):m.on("data",A=>{super[V](A)})}};z.Sync=P,e.exports=z}),Qn=te(t=>{"use strict";W();var e=ZD(),r=re("events").EventEmitter,i=re("fs"),n=i.writev;if(!n){let d=process.binding("fs"),m=d.FSReqWrap||d.FSReqCallback;n=(D,A,w,I)=>{let M=(q,Q)=>I(q,Q,A),Z=new m;Z.oncomplete=M,d.writeBuffers(D,A,w,Z)}}var s=Symbol("_autoClose"),o=Symbol("_close"),a=Symbol("_ended"),u=Symbol("_fd"),l=Symbol("_finished"),c=Symbol("_flags"),f=Symbol("_flush"),h=Symbol("_handleChunk"),p=Symbol("_makeBuf"),g=Symbol("_mode"),y=Symbol("_needDrain"),E=Symbol("_onerror"),v=Symbol("_onopen"),F=Symbol("_onread"),O=Symbol("_onwrite"),R=Symbol("_open"),x=Symbol("_path"),L=Symbol("_pos"),b=Symbol("_queue"),S=Symbol("_read"),N=Symbol("_readSize"),H=Symbol("_reading"),T=Symbol("_remain"),U=Symbol("_size"),V=Symbol("_write"),K=Symbol("_writing"),B=Symbol("_defaultFlag"),C=Symbol("_errored"),k=class extends e{constructor(d,m){if(m=m||{},super(m),this.readable=!0,this.writable=!1,typeof d!="string")throw new TypeError("path must be a string");this[C]=!1,this[u]=typeof m.fd=="number"?m.fd:null,this[x]=d,this[N]=m.readSize||16*1024*1024,this[H]=!1,this[U]=typeof m.size=="number"?m.size:1/0,this[T]=this[U],this[s]=typeof m.autoClose=="boolean"?m.autoClose:!0,typeof this[u]=="number"?this[S]():this[R]()}get fd(){return this[u]}get path(){return this[x]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[R](){i.open(this[x],"r",(d,m)=>this[v](d,m))}[v](d,m){d?this[E](d):(this[u]=m,this.emit("open",m),this[S]())}[p](){return Buffer.allocUnsafe(Math.min(this[N],this[T]))}[S](){if(!this[H]){this[H]=!0;let d=this[p]();if(d.length===0)return process.nextTick(()=>this[F](null,0,d));i.read(this[u],d,0,d.length,null,(m,D,A)=>this[F](m,D,A))}}[F](d,m,D){this[H]=!1,d?this[E](d):this[h](m,D)&&this[S]()}[o](){if(this[s]&&typeof this[u]=="number"){let d=this[u];this[u]=null,i.close(d,m=>m?this.emit("error",m):this.emit("close"))}}[E](d){this[H]=!0,this[o](),this.emit("error",d)}[h](d,m){let D=!1;return this[T]-=d,d>0&&(D=super.write(d<m.length?m.slice(0,d):m)),(d===0||this[T]<=0)&&(D=!1,this[o](),super.end()),D}emit(d,m){switch(d){case"prefinish":case"finish":break;case"drain":typeof this[u]=="number"&&this[S]();break;case"error":return this[C]?void 0:(this[C]=!0,super.emit(d,m));default:return super.emit(d,m)}}},j=class extends k{[R](){let d=!0;try{this[v](null,i.openSync(this[x],"r")),d=!1}finally{d&&this[o]()}}[S](){let d=!0;try{if(!this[H]){this[H]=!0;do{let m=this[p](),D=m.length===0?0:i.readSync(this[u],m,0,m.length,null);if(!this[h](D,m))break}while(!0);this[H]=!1}d=!1}finally{d&&this[o]()}}[o](){if(this[s]&&typeof this[u]=="number"){let d=this[u];this[u]=null,i.closeSync(d),this.emit("close")}}},z=class extends r{constructor(d,m){m=m||{},super(m),this.readable=!1,this.writable=!0,this[C]=!1,this[K]=!1,this[a]=!1,this[y]=!1,this[b]=[],this[x]=d,this[u]=typeof m.fd=="number"?m.fd:null,this[g]=m.mode===void 0?438:m.mode,this[L]=typeof m.start=="number"?m.start:null,this[s]=typeof m.autoClose=="boolean"?m.autoClose:!0;let D=this[L]!==null?"r+":"w";this[B]=m.flags===void 0,this[c]=this[B]?D:m.flags,this[u]===null&&this[R]()}emit(d,m){if(d==="error"){if(this[C])return;this[C]=!0}return super.emit(d,m)}get fd(){return this[u]}get path(){return this[x]}[E](d){this[o](),this[K]=!0,this.emit("error",d)}[R](){i.open(this[x],this[c],this[g],(d,m)=>this[v](d,m))}[v](d,m){this[B]&&this[c]==="r+"&&d&&d.code==="ENOENT"?(this[c]="w",this[R]()):d?this[E](d):(this[u]=m,this.emit("open",m),this[f]())}end(d,m){return d&&this.write(d,m),this[a]=!0,!this[K]&&!this[b].length&&typeof this[u]=="number"&&this[O](null,0),this}write(d,m){return typeof d=="string"&&(d=Buffer.from(d,m)),this[a]?(this.emit("error",new Error("write() after end()")),!1):this[u]===null||this[K]||this[b].length?(this[b].push(d),this[y]=!0,!1):(this[K]=!0,this[V](d),!0)}[V](d){i.write(this[u],d,0,d.length,this[L],(m,D)=>this[O](m,D))}[O](d,m){d?this[E](d):(this[L]!==null&&(this[L]+=m),this[b].length?this[f]():(this[K]=!1,this[a]&&!this[l]?(this[l]=!0,this[o](),this.emit("finish")):this[y]&&(this[y]=!1,this.emit("drain"))))}[f](){if(this[b].length===0)this[a]&&this[O](null,0);else if(this[b].length===1)this[V](this[b].pop());else{let d=this[b];this[b]=[],n(this[u],d,this[L],(m,D)=>this[O](m,D))}}[o](){if(this[s]&&typeof this[u]=="number"){let d=this[u];this[u]=null,i.close(d,m=>m?this.emit("error",m):this.emit("close"))}}},P=class extends z{[R](){let d;if(this[B]&&this[c]==="r+")try{d=i.openSync(this[x],this[c],this[g])}catch(m){if(m.code==="ENOENT")return this[c]="w",this[R]();throw m}else d=i.openSync(this[x],this[c],this[g]);this[v](null,d)}[o](){if(this[s]&&typeof this[u]=="number"){let d=this[u];this[u]=null,i.closeSync(d),this.emit("close")}}[V](d){let m=!0;try{this[O](null,i.writeSync(this[u],d,0,d.length,this[L])),m=!1}finally{if(m)try{this[o]()}catch{}}}};t.ReadStream=k,t.ReadStreamSync=j,t.WriteStream=z,t.WriteStreamSync=P}),$h=te((t,e)=>{"use strict";W();var r=Mh(),i=Jn(),n=re("events"),s=ib(),o=1024*1024,a=Ih(),u=Nh(),l=XD(),{nextTick:c}=re("process"),f=Buffer.from([31,139]),h=Symbol("state"),p=Symbol("writeEntry"),g=Symbol("readEntry"),y=Symbol("nextEntry"),E=Symbol("processEntry"),v=Symbol("extendedHeader"),F=Symbol("globalExtendedHeader"),O=Symbol("meta"),R=Symbol("emitMeta"),x=Symbol("buffer"),L=Symbol("queue"),b=Symbol("ended"),S=Symbol("emittedEnd"),N=Symbol("emit"),H=Symbol("unzip"),T=Symbol("consumeChunk"),U=Symbol("consumeChunkSub"),V=Symbol("consumeBody"),K=Symbol("consumeMeta"),B=Symbol("consumeHeader"),C=Symbol("consuming"),k=Symbol("bufferConcat"),j=Symbol("maybeEnd"),z=Symbol("writing"),P=Symbol("aborted"),d=Symbol("onDone"),m=Symbol("sawValidEntry"),D=Symbol("sawNullBlock"),A=Symbol("sawEOF"),w=Symbol("closeStream"),I=M=>!0;e.exports=r(class extends n{constructor(M){M=M||{},super(M),this.file=M.file||"",this[m]=null,this.on(d,Z=>{(this[h]==="begin"||this[m]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),M.ondone?this.on(d,M.ondone):this.on(d,Z=>{this.emit("prefinish"),this.emit("finish"),this.emit("end")}),this.strict=!!M.strict,this.maxMetaEntrySize=M.maxMetaEntrySize||o,this.filter=typeof M.filter=="function"?M.filter:I,this.writable=!0,this.readable=!1,this[L]=new s,this[x]=null,this[g]=null,this[p]=null,this[h]="begin",this[O]="",this[v]=null,this[F]=null,this[b]=!1,this[H]=null,this[P]=!1,this[D]=!1,this[A]=!1,this.on("end",()=>this[w]()),typeof M.onwarn=="function"&&this.on("warn",M.onwarn),typeof M.onentry=="function"&&this.on("entry",M.onentry)}[B](M,Z){this[m]===null&&(this[m]=!1);let q;try{q=new i(M,Z,this[v],this[F])}catch(Q){return this.warn("TAR_ENTRY_INVALID",Q)}if(q.nullBlock)this[D]?(this[A]=!0,this[h]==="begin"&&(this[h]="header"),this[N]("eof")):(this[D]=!0,this[N]("nullBlock"));else if(this[D]=!1,!q.cksumValid)this.warn("TAR_ENTRY_INVALID","checksum failure",{header:q});else if(!q.path)this.warn("TAR_ENTRY_INVALID","path is required",{header:q});else{let Q=q.type;if(/^(Symbolic)?Link$/.test(Q)&&!q.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath required",{header:q});else if(!/^(Symbolic)?Link$/.test(Q)&&q.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath forbidden",{header:q});else{let G=this[p]=new a(q,this[v],this[F]);if(!this[m])if(G.remain){let ie=()=>{G.invalid||(this[m]=!0)};G.on("end",ie)}else this[m]=!0;G.meta?G.size>this.maxMetaEntrySize?(G.ignore=!0,this[N]("ignoredEntry",G),this[h]="ignore",G.resume()):G.size>0&&(this[O]="",G.on("data",ie=>this[O]+=ie),this[h]="meta"):(this[v]=null,G.ignore=G.ignore||!this.filter(G.path,G),G.ignore?(this[N]("ignoredEntry",G),this[h]=G.remain?"ignore":"header",G.resume()):(G.remain?this[h]="body":(this[h]="header",G.end()),this[g]?this[L].push(G):(this[L].push(G),this[y]())))}}}[w](){c(()=>this.emit("close"))}[E](M){let Z=!0;return M?Array.isArray(M)?this.emit.apply(this,M):(this[g]=M,this.emit("entry",M),M.emittedEnd||(M.on("end",q=>this[y]()),Z=!1)):(this[g]=null,Z=!1),Z}[y](){do;while(this[E](this[L].shift()));if(!this[L].length){let M=this[g];!M||M.flowing||M.size===M.remain?this[z]||this.emit("drain"):M.once("drain",Z=>this.emit("drain"))}}[V](M,Z){let q=this[p],Q=q.blockRemain,G=Q>=M.length&&Z===0?M:M.slice(Z,Z+Q);return q.write(G),q.blockRemain||(this[h]="header",this[p]=null,q.end()),G.length}[K](M,Z){let q=this[p],Q=this[V](M,Z);return this[p]||this[R](q),Q}[N](M,Z,q){!this[L].length&&!this[g]?this.emit(M,Z,q):this[L].push([M,Z,q])}[R](M){switch(this[N]("meta",this[O]),M.type){case"ExtendedHeader":case"OldExtendedHeader":this[v]=u.parse(this[O],this[v],!1);break;case"GlobalExtendedHeader":this[F]=u.parse(this[O],this[F],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[v]=this[v]||Object.create(null),this[v].path=this[O].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[v]=this[v]||Object.create(null),this[v].linkpath=this[O].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+M.type)}}abort(M){this[P]=!0,this.emit("abort",M),this.warn("TAR_ABORT",M,{recoverable:!1})}write(M){if(this[P])return;if(this[H]===null&&M){if(this[x]&&(M=Buffer.concat([this[x],M]),this[x]=null),M.length<f.length)return this[x]=M,!0;for(let q=0;this[H]===null&&q<f.length;q++)M[q]!==f[q]&&(this[H]=!1);if(this[H]===null){let q=this[b];this[b]=!1,this[H]=new l.Unzip,this[H].on("data",G=>this[T](G)),this[H].on("error",G=>this.abort(G)),this[H].on("end",G=>{this[b]=!0,this[T]()}),this[z]=!0;let Q=this[H][q?"end":"write"](M);return this[z]=!1,Q}}this[z]=!0,this[H]?this[H].write(M):this[T](M),this[z]=!1;let Z=this[L].length?!1:this[g]?this[g].flowing:!0;return!Z&&!this[L].length&&this[g].once("drain",q=>this.emit("drain")),Z}[k](M){M&&!this[P]&&(this[x]=this[x]?Buffer.concat([this[x],M]):M)}[j](){if(this[b]&&!this[S]&&!this[P]&&!this[C]){this[S]=!0;let M=this[p];if(M&&M.blockRemain){let Z=this[x]?this[x].length:0;this.warn("TAR_BAD_ARCHIVE",`Truncated input (needed ${M.blockRemain} more bytes, only ${Z} available)`,{entry:M}),this[x]&&M.write(this[x]),M.end()}this[N](d)}}[T](M){if(this[C])this[k](M);else if(!M&&!this[x])this[j]();else{if(this[C]=!0,this[x]){this[k](M);let Z=this[x];this[x]=null,this[U](Z)}else this[U](M);for(;this[x]&&this[x].length>=512&&!this[P]&&!this[A];){let Z=this[x];this[x]=null,this[U](Z)}this[C]=!1}(!this[x]||this[b])&&this[j]()}[U](M){let Z=0,q=M.length;for(;Z+512<=q&&!this[P]&&!this[A];)switch(this[h]){case"begin":case"header":this[B](M,Z),Z+=512;break;case"ignore":case"body":Z+=this[V](M,Z);break;case"meta":Z+=this[K](M,Z);break;default:throw new Error("invalid state: "+this[h])}Z<q&&(this[x]?this[x]=Buffer.concat([M.slice(Z),this[x]]):this[x]=M.slice(Z))}end(M){this[P]||(this[H]?this[H].end(M):(this[b]=!0,this.write(M)))}})}),Hh=te((t,e)=>{"use strict";W();var r=Kn(),i=$h(),n=re("fs"),s=Qn(),o=re("path"),a=Xn();e.exports=(p,g,y)=>{typeof p=="function"?(y=p,g=null,p={}):Array.isArray(p)&&(g=p,p={}),typeof g=="function"&&(y=g,g=null),g?g=Array.from(g):g=[];let E=r(p);if(E.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!E.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return g.length&&l(E,g),E.noResume||u(E),E.file&&E.sync?c(E):E.file?f(E,y):h(E)};var u=p=>{let g=p.onentry;p.onentry=g?y=>{g(y),y.resume()}:y=>y.resume()},l=(p,g)=>{let y=new Map(g.map(F=>[a(F),!0])),E=p.filter,v=(F,O)=>{let R=O||o.parse(F).root||".",x=F===R?!1:y.has(F)?y.get(F):v(o.dirname(F),R);return y.set(F,x),x};p.filter=E?(F,O)=>E(F,O)&&v(a(F)):F=>v(a(F))},c=p=>{let g=h(p),y=p.file,E=!0,v;try{let F=n.statSync(y),O=p.maxReadSize||16*1024*1024;if(F.size<O)g.end(n.readFileSync(y));else{let R=0,x=Buffer.allocUnsafe(O);for(v=n.openSync(y,"r");R<F.size;){let L=n.readSync(v,x,0,O,R);R+=L,g.write(x.slice(0,L))}g.end()}E=!1}finally{if(E&&v)try{n.closeSync(v)}catch{}}},f=(p,g)=>{let y=new i(p),E=p.maxReadSize||16*1024*1024,v=p.file,F=new Promise((O,R)=>{y.on("error",R),y.on("end",O),n.stat(v,(x,L)=>{if(x)R(x);else{let b=new s.ReadStream(v,{readSize:E,size:L.size});b.on("error",R),b.pipe(y)}})});return g?F.then(g,g):F},h=p=>new i(p)}),sT=te((t,e)=>{"use strict";W();var r=Kn(),i=jh(),n=Qn(),s=Hh(),o=re("path");e.exports=(p,g,y)=>{if(typeof g=="function"&&(y=g),Array.isArray(p)&&(g=p,p={}),!g||!Array.isArray(g)||!g.length)throw new TypeError("no files or directories specified");g=Array.from(g);let E=r(p);if(E.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!E.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return E.file&&E.sync?a(E,g):E.file?u(E,g,y):E.sync?f(E,g):h(E,g)};var a=(p,g)=>{let y=new i.Sync(p),E=new n.WriteStreamSync(p.file,{mode:p.mode||438});y.pipe(E),l(y,g)},u=(p,g,y)=>{let E=new i(p),v=new n.WriteStream(p.file,{mode:p.mode||438});E.pipe(v);let F=new Promise((O,R)=>{v.on("error",R),v.on("close",O),E.on("error",R)});return c(E,g),y?F.then(y,y):F},l=(p,g)=>{g.forEach(y=>{y.charAt(0)==="@"?s({file:o.resolve(p.cwd,y.slice(1)),sync:!0,noResume:!0,onentry:E=>p.add(E)}):p.add(y)}),p.end()},c=(p,g)=>{for(;g.length;){let y=g.shift();if(y.charAt(0)==="@")return s({file:o.resolve(p.cwd,y.slice(1)),noResume:!0,onentry:E=>p.add(E)}).then(E=>c(p,g));p.add(y)}p.end()},f=(p,g)=>{let y=new i.Sync(p);return l(y,g),y},h=(p,g)=>{let y=new i(p);return c(y,g),y}}),nb=te((t,e)=>{"use strict";W();var r=Kn(),i=jh(),n=re("fs"),s=Qn(),o=Hh(),a=re("path"),u=Jn();e.exports=(g,y,E)=>{let v=r(g);if(!v.file)throw new TypeError("file is required");if(v.gzip)throw new TypeError("cannot append to compressed archives");if(!y||!Array.isArray(y)||!y.length)throw new TypeError("no files or directories specified");return y=Array.from(y),v.sync?l(v,y):f(v,y,E)};var l=(g,y)=>{let E=new i.Sync(g),v=!0,F,O;try{try{F=n.openSync(g.file,"r+")}catch(L){if(L.code==="ENOENT")F=n.openSync(g.file,"w+");else throw L}let R=n.fstatSync(F),x=Buffer.alloc(512);e:for(O=0;O<R.size;O+=512){for(let S=0,N=0;S<512;S+=N){if(N=n.readSync(F,x,S,x.length-S,O+S),O===0&&x[0]===31&&x[1]===139)throw new Error("cannot append to compressed archives");if(!N)break e}let L=new u(x);if(!L.cksumValid)break;let b=512*Math.ceil(L.size/512);if(O+b+512>R.size)break;O+=b,g.mtimeCache&&g.mtimeCache.set(L.path,L.mtime)}v=!1,c(g,E,O,F,y)}finally{if(v)try{n.closeSync(F)}catch{}}},c=(g,y,E,v,F)=>{let O=new s.WriteStreamSync(g.file,{fd:v,start:E});y.pipe(O),h(y,F)},f=(g,y,E)=>{y=Array.from(y);let v=new i(g),F=(R,x,L)=>{let b=(U,V)=>{U?n.close(R,K=>L(U)):L(null,V)},S=0;if(x===0)return b(null,0);let N=0,H=Buffer.alloc(512),T=(U,V)=>{if(U)return b(U);if(N+=V,N<512&&V)return n.read(R,H,N,H.length-N,S+N,T);if(S===0&&H[0]===31&&H[1]===139)return b(new Error("cannot append to compressed archives"));if(N<512)return b(null,S);let K=new u(H);if(!K.cksumValid)return b(null,S);let B=512*Math.ceil(K.size/512);if(S+B+512>x||(S+=B+512,S>=x))return b(null,S);g.mtimeCache&&g.mtimeCache.set(K.path,K.mtime),N=0,n.read(R,H,0,512,S,T)};n.read(R,H,0,512,S,T)},O=new Promise((R,x)=>{v.on("error",x);let L="r+",b=(S,N)=>{if(S&&S.code==="ENOENT"&&L==="r+")return L="w+",n.open(g.file,L,b);if(S)return x(S);n.fstat(N,(H,T)=>{if(H)return n.close(N,()=>x(H));F(N,T.size,(U,V)=>{if(U)return x(U);let K=new s.WriteStream(g.file,{fd:N,start:V});v.pipe(K),K.on("error",x),K.on("close",R),p(v,y)})})};n.open(g.file,L,b)});return E?O.then(E,E):O},h=(g,y)=>{y.forEach(E=>{E.charAt(0)==="@"?o({file:a.resolve(g.cwd,E.slice(1)),sync:!0,noResume:!0,onentry:v=>g.add(v)}):g.add(E)}),g.end()},p=(g,y)=>{for(;y.length;){let E=y.shift();if(E.charAt(0)==="@")return o({file:a.resolve(g.cwd,E.slice(1)),noResume:!0,onentry:v=>g.add(v)}).then(v=>p(g,y));g.add(E)}g.end()}}),oT=te((t,e)=>{"use strict";W();var r=Kn(),i=nb();e.exports=(s,o,a)=>{let u=r(s);if(!u.file)throw new TypeError("file is required");if(u.gzip)throw new TypeError("cannot append to compressed archives");if(!o||!Array.isArray(o)||!o.length)throw new TypeError("no files or directories specified");return o=Array.from(o),n(u),i(u,o,a)};var n=s=>{let o=s.filter;s.mtimeCache||(s.mtimeCache=new Map),s.filter=o?(a,u)=>o(a,u)&&!(s.mtimeCache.get(a)>u.mtime):(a,u)=>!(s.mtimeCache.get(a)>u.mtime)}}),aT=te((t,e)=>{W();var{promisify:r}=re("util"),i=re("fs"),n=s=>{if(!s)s={mode:511,fs:i};else if(typeof s=="object")s={mode:511,fs:i,...s};else if(typeof s=="number")s={mode:s,fs:i};else if(typeof s=="string")s={mode:parseInt(s,8),fs:i};else throw new TypeError("invalid options argument");return s.mkdir=s.mkdir||s.fs.mkdir||i.mkdir,s.mkdirAsync=r(s.mkdir),s.stat=s.stat||s.fs.stat||i.stat,s.statAsync=r(s.stat),s.statSync=s.statSync||s.fs.statSync||i.statSync,s.mkdirSync=s.mkdirSync||s.fs.mkdirSync||i.mkdirSync,s};e.exports=n}),uT=te((t,e)=>{W();var r=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:i,parse:n}=re("path"),s=o=>{if(/\0/.test(o))throw Object.assign(new TypeError("path must be a string without null bytes"),{path:o,code:"ERR_INVALID_ARG_VALUE"});if(o=i(o),r==="win32"){let a=/[*|"<>?:]/,{root:u}=n(o);if(a.test(o.substr(u.length)))throw Object.assign(new Error("Illegal characters in path."),{path:o,code:"EINVAL"})}return o};e.exports=s}),lT=te((t,e)=>{W();var{dirname:r}=re("path"),i=(s,o,a=void 0)=>a===o?Promise.resolve():s.statAsync(o).then(u=>u.isDirectory()?a:void 0,u=>u.code==="ENOENT"?i(s,r(o),o):void 0),n=(s,o,a=void 0)=>{if(a!==o)try{return s.statSync(o).isDirectory()?a:void 0}catch(u){return u.code==="ENOENT"?n(s,r(o),o):void 0}};e.exports={findMade:i,findMadeSync:n}}),sb=te((t,e)=>{W();var{dirname:r}=re("path"),i=(s,o,a)=>{o.recursive=!1;let u=r(s);return u===s?o.mkdirAsync(s,o).catch(l=>{if(l.code!=="EISDIR")throw l}):o.mkdirAsync(s,o).then(()=>a||s,l=>{if(l.code==="ENOENT")return i(u,o).then(c=>i(s,o,c));if(l.code!=="EEXIST"&&l.code!=="EROFS")throw l;return o.statAsync(s).then(c=>{if(c.isDirectory())return a;throw l},()=>{throw l})})},n=(s,o,a)=>{let u=r(s);if(o.recursive=!1,u===s)try{return o.mkdirSync(s,o)}catch(l){if(l.code!=="EISDIR")throw l;return}try{return o.mkdirSync(s,o),a||s}catch(l){if(l.code==="ENOENT")return n(s,o,n(u,o,a));if(l.code!=="EEXIST"&&l.code!=="EROFS")throw l;try{if(!o.statSync(s).isDirectory())throw l}catch{throw l}}};e.exports={mkdirpManual:i,mkdirpManualSync:n}}),cT=te((t,e)=>{W();var{dirname:r}=re("path"),{findMade:i,findMadeSync:n}=lT(),{mkdirpManual:s,mkdirpManualSync:o}=sb(),a=(l,c)=>(c.recursive=!0,r(l)===l?c.mkdirAsync(l,c):i(c,l).then(f=>c.mkdirAsync(l,c).then(()=>f).catch(h=>{if(h.code==="ENOENT")return s(l,c);throw h}))),u=(l,c)=>{if(c.recursive=!0,r(l)===l)return c.mkdirSync(l,c);let f=n(c,l);try{return c.mkdirSync(l,c),f}catch(h){if(h.code==="ENOENT")return o(l,c);throw h}};e.exports={mkdirpNative:a,mkdirpNativeSync:u}}),hT=te((t,e)=>{W();var r=re("fs"),i=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version,n=i.replace(/^v/,"").split("."),s=+n[0]>10||+n[0]==10&&+n[1]>=12,o=s?u=>u.mkdir===r.mkdir:()=>!1,a=s?u=>u.mkdirSync===r.mkdirSync:()=>!1;e.exports={useNative:o,useNativeSync:a}}),fT=te((t,e)=>{W();var r=aT(),i=uT(),{mkdirpNative:n,mkdirpNativeSync:s}=cT(),{mkdirpManual:o,mkdirpManualSync:a}=sb(),{useNative:u,useNativeSync:l}=hT(),c=(h,p)=>(h=i(h),p=r(p),u(p)?n(h,p):o(h,p)),f=(h,p)=>(h=i(h),p=r(p),l(p)?s(h,p):a(h,p));c.sync=f,c.native=(h,p)=>n(i(h),r(p)),c.manual=(h,p)=>o(i(h),r(p)),c.nativeSync=(h,p)=>s(i(h),r(p)),c.manualSync=(h,p)=>a(i(h),r(p)),e.exports=c}),pT=te((t,e)=>{"use strict";W();var r=re("fs"),i=re("path"),n=r.lchown?"lchown":"chown",s=r.lchownSync?"lchownSync":"chownSync",o=r.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),a=(O,R,x)=>{try{return r[s](O,R,x)}catch(L){if(L.code!=="ENOENT")throw L}},u=(O,R,x)=>{try{return r.chownSync(O,R,x)}catch(L){if(L.code!=="ENOENT")throw L}},l=o?(O,R,x,L)=>b=>{!b||b.code!=="EISDIR"?L(b):r.chown(O,R,x,L)}:(O,R,x,L)=>L,c=o?(O,R,x)=>{try{return a(O,R,x)}catch(L){if(L.code!=="EISDIR")throw L;u(O,R,x)}}:(O,R,x)=>a(O,R,x),f=process.version,h=(O,R,x)=>r.readdir(O,R,x),p=(O,R)=>r.readdirSync(O,R);/^v4\./.test(f)&&(h=(O,R,x)=>r.readdir(O,x));var g=(O,R,x,L)=>{r[n](O,R,x,l(O,R,x,b=>{L(b&&b.code!=="ENOENT"?b:null)}))},y=(O,R,x,L,b)=>{if(typeof R=="string")return r.lstat(i.resolve(O,R),(S,N)=>{if(S)return b(S.code!=="ENOENT"?S:null);N.name=R,y(O,N,x,L,b)});if(R.isDirectory())E(i.resolve(O,R.name),x,L,S=>{if(S)return b(S);let N=i.resolve(O,R.name);g(N,x,L,b)});else{let S=i.resolve(O,R.name);g(S,x,L,b)}},E=(O,R,x,L)=>{h(O,{withFileTypes:!0},(b,S)=>{if(b){if(b.code==="ENOENT")return L();if(b.code!=="ENOTDIR"&&b.code!=="ENOTSUP")return L(b)}if(b||!S.length)return g(O,R,x,L);let N=S.length,H=null,T=U=>{if(!H){if(U)return L(H=U);if(--N===0)return g(O,R,x,L)}};S.forEach(U=>y(O,U,R,x,T))})},v=(O,R,x,L)=>{if(typeof R=="string")try{let b=r.lstatSync(i.resolve(O,R));b.name=R,R=b}catch(b){if(b.code==="ENOENT")return;throw b}R.isDirectory()&&F(i.resolve(O,R.name),x,L),c(i.resolve(O,R.name),x,L)},F=(O,R,x)=>{let L;try{L=p(O,{withFileTypes:!0})}catch(b){if(b.code==="ENOENT")return;if(b.code==="ENOTDIR"||b.code==="ENOTSUP")return c(O,R,x);throw b}return L&&L.length&&L.forEach(b=>v(O,b,R,x)),c(O,R,x)};e.exports=E,E.sync=F}),dT=te((t,e)=>{"use strict";W();var r=fT(),i=re("fs"),n=re("path"),s=pT(),o=Zn(),a=class extends Error{constructor(y,E){super("Cannot extract through symbolic link"),this.path=E,this.symlink=y}get name(){return"SylinkError"}},u=class extends Error{constructor(y,E){super(E+": Cannot cd into '"+y+"'"),this.path=y,this.code=E}get name(){return"CwdError"}},l=(y,E)=>y.get(o(E)),c=(y,E,v)=>y.set(o(E),v),f=(y,E)=>{i.stat(y,(v,F)=>{(v||!F.isDirectory())&&(v=new u(y,v&&v.code||"ENOTDIR")),E(v)})};e.exports=(y,E,v)=>{y=o(y);let F=E.umask,O=E.mode|448,R=(O&F)!==0,x=E.uid,L=E.gid,b=typeof x=="number"&&typeof L=="number"&&(x!==E.processUid||L!==E.processGid),S=E.preserve,N=E.unlink,H=E.cache,T=o(E.cwd),U=(K,B)=>{K?v(K):(c(H,y,!0),B&&b?s(B,x,L,C=>U(C)):R?i.chmod(y,O,v):v())};if(H&&l(H,y)===!0)return U();if(y===T)return f(y,U);if(S)return r(y,{mode:O}).then(K=>U(null,K),U);let V=o(n.relative(T,y)).split("/");h(T,V,O,H,N,T,null,U)};var h=(y,E,v,F,O,R,x,L)=>{if(!E.length)return L(null,x);let b=E.shift(),S=o(n.resolve(y+"/"+b));if(l(F,S))return h(S,E,v,F,O,R,x,L);i.mkdir(S,v,p(S,E,v,F,O,R,x,L))},p=(y,E,v,F,O,R,x,L)=>b=>{b?i.lstat(y,(S,N)=>{if(S)S.path=S.path&&o(S.path),L(S);else if(N.isDirectory())h(y,E,v,F,O,R,x,L);else if(O)i.unlink(y,H=>{if(H)return L(H);i.mkdir(y,v,p(y,E,v,F,O,R,x,L))});else{if(N.isSymbolicLink())return L(new a(y,y+"/"+E.join("/")));L(b)}}):(x=x||y,h(y,E,v,F,O,R,x,L))},g=y=>{let E=!1,v="ENOTDIR";try{E=i.statSync(y).isDirectory()}catch(F){v=F.code}finally{if(!E)throw new u(y,v)}};e.exports.sync=(y,E)=>{y=o(y);let v=E.umask,F=E.mode|448,O=(F&v)!==0,R=E.uid,x=E.gid,L=typeof R=="number"&&typeof x=="number"&&(R!==E.processUid||x!==E.processGid),b=E.preserve,S=E.unlink,N=E.cache,H=o(E.cwd),T=K=>{c(N,y,!0),K&&L&&s.sync(K,R,x),O&&i.chmodSync(y,F)};if(N&&l(N,y)===!0)return T();if(y===H)return g(H),T();if(b)return T(r.sync(y,F));let U=o(n.relative(H,y)).split("/"),V=null;for(let K=U.shift(),B=H;K&&(B+="/"+K);K=U.shift())if(B=o(n.resolve(B)),!l(N,B))try{i.mkdirSync(B,F),V=V||B,c(N,B,!0)}catch{let C=i.lstatSync(B);if(C.isDirectory()){c(N,B,!0);continue}else if(S){i.unlinkSync(B),i.mkdirSync(B,F),V=V||B,c(N,B,!0);continue}else if(C.isSymbolicLink())return new a(B,B+"/"+U.join("/"))}return T(V)}}),ob=te((t,e)=>{W();var r=Object.create(null),{hasOwnProperty:i}=Object.prototype;e.exports=n=>(i.call(r,n)||(r[n]=n.normalize("NFKD")),r[n])}),mT=te((t,e)=>{W();var r=re("assert"),i=ob(),n=Xn(),{join:s}=re("path"),o=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,a=o==="win32";e.exports=()=>{let u=new Map,l=new Map,c=E=>E.split("/").slice(0,-1).reduce((v,F)=>(v.length&&(F=s(v[v.length-1],F)),v.push(F||"/"),v),[]),f=new Set,h=E=>{let v=l.get(E);if(!v)throw new Error("function does not have any path reservations");return{paths:v.paths.map(F=>u.get(F)),dirs:[...v.dirs].map(F=>u.get(F))}},p=E=>{let{paths:v,dirs:F}=h(E);return v.every(O=>O[0]===E)&&F.every(O=>O[0]instanceof Set&&O[0].has(E))},g=E=>f.has(E)||!p(E)?!1:(f.add(E),E(()=>y(E)),!0),y=E=>{if(!f.has(E))return!1;let{paths:v,dirs:F}=l.get(E),O=new Set;return v.forEach(R=>{let x=u.get(R);r.equal(x[0],E),x.length===1?u.delete(R):(x.shift(),typeof x[0]=="function"?O.add(x[0]):x[0].forEach(L=>O.add(L)))}),F.forEach(R=>{let x=u.get(R);r(x[0]instanceof Set),x[0].size===1&&x.length===1?u.delete(R):x[0].size===1?(x.shift(),O.add(x[0])):x[0].delete(E)}),f.delete(E),O.forEach(R=>g(R)),!0};return{check:p,reserve:(E,v)=>{E=a?["win32 parallelization disabled"]:E.map(O=>i(n(s(O))).toLowerCase());let F=new Set(E.map(O=>c(O)).reduce((O,R)=>O.concat(R)));return l.set(v,{dirs:F,paths:E}),E.forEach(O=>{let R=u.get(O);R?R.push(v):u.set(O,[v])}),F.forEach(O=>{let R=u.get(O);R?R[R.length-1]instanceof Set?R[R.length-1].add(v):R.push(new Set([v])):u.set(O,[new Set([v])])}),g(v)}}}}),gT=te((t,e)=>{W();var r=process.env.__FAKE_PLATFORM__||process.platform,i=r==="win32",n=global.__FAKE_TESTING_FS__||re("fs"),{O_CREAT:s,O_TRUNC:o,O_WRONLY:a,UV_FS_O_FILEMAP:u=0}=n.constants,l=i&&!!u,c=512*1024,f=u|o|s|a;e.exports=l?h=>h<c?f:"w":()=>"w"}),ab=te((t,e)=>{"use strict";W();var r=re("assert"),i=$h(),n=re("fs"),s=Qn(),o=re("path"),a=dT(),u=eb(),l=mT(),c=tb(),f=Zn(),h=Xn(),p=ob(),g=Symbol("onEntry"),y=Symbol("checkFs"),E=Symbol("checkFs2"),v=Symbol("pruneCache"),F=Symbol("isReusable"),O=Symbol("makeFs"),R=Symbol("file"),x=Symbol("directory"),L=Symbol("link"),b=Symbol("symlink"),S=Symbol("hardlink"),N=Symbol("unsupported"),H=Symbol("checkPath"),T=Symbol("mkdir"),U=Symbol("onError"),V=Symbol("pending"),K=Symbol("pend"),B=Symbol("unpend"),C=Symbol("ended"),k=Symbol("maybeClose"),j=Symbol("skip"),z=Symbol("doChown"),P=Symbol("uid"),d=Symbol("gid"),m=Symbol("checkedCwd"),D=re("crypto"),A=gT(),w=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,I=w==="win32",M=(_,Y)=>{if(!I)return n.unlink(_,Y);let X=_+".DELETE."+D.randomBytes(16).toString("hex");n.rename(_,X,oe=>{if(oe)return Y(oe);n.unlink(X,Y)})},Z=_=>{if(!I)return n.unlinkSync(_);let Y=_+".DELETE."+D.randomBytes(16).toString("hex");n.renameSync(_,Y),n.unlinkSync(Y)},q=(_,Y,X)=>_===_>>>0?_:Y===Y>>>0?Y:X,Q=_=>p(h(f(_))).toLowerCase(),G=(_,Y)=>{Y=Q(Y);for(let X of _.keys()){let oe=Q(X);(oe===Y||oe.indexOf(Y+"/")===0)&&_.delete(X)}},ie=_=>{for(let Y of _.keys())_.delete(Y)},ce=class extends i{constructor(_){if(_||(_={}),_.ondone=Y=>{this[C]=!0,this[k]()},super(_),this[m]=!1,this.reservations=l(),this.transform=typeof _.transform=="function"?_.transform:null,this.writable=!0,this.readable=!1,this[V]=0,this[C]=!1,this.dirCache=_.dirCache||new Map,typeof _.uid=="number"||typeof _.gid=="number"){if(typeof _.uid!="number"||typeof _.gid!="number")throw new TypeError("cannot set owner without number uid and gid");if(_.preserveOwner)throw new TypeError("cannot preserve owner in archive and also set owner explicitly");this.uid=_.uid,this.gid=_.gid,this.setOwner=!0}else this.uid=null,this.gid=null,this.setOwner=!1;_.preserveOwner===void 0&&typeof _.uid!="number"?this.preserveOwner=process.getuid&&process.getuid()===0:this.preserveOwner=!!_.preserveOwner,this.processUid=(this.preserveOwner||this.setOwner)&&process.getuid?process.getuid():null,this.processGid=(this.preserveOwner||this.setOwner)&&process.getgid?process.getgid():null,this.forceChown=_.forceChown===!0,this.win32=!!_.win32||I,this.newer=!!_.newer,this.keep=!!_.keep,this.noMtime=!!_.noMtime,this.preservePaths=!!_.preservePaths,this.unlink=!!_.unlink,this.cwd=f(o.resolve(_.cwd||process.cwd())),this.strip=+_.strip||0,this.processUmask=_.noChmod?0:process.umask(),this.umask=typeof _.umask=="number"?_.umask:this.processUmask,this.dmode=_.dmode||511&~this.umask,this.fmode=_.fmode||438&~this.umask,this.on("entry",Y=>this[g](Y))}warn(_,Y,X={}){return(_==="TAR_BAD_ARCHIVE"||_==="TAR_ABORT")&&(X.recoverable=!1),super.warn(_,Y,X)}[k](){this[C]&&this[V]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"))}[H](_){if(this.strip){let Y=f(_.path).split("/");if(Y.length<this.strip)return!1;if(_.path=Y.slice(this.strip).join("/"),_.type==="Link"){let X=f(_.linkpath).split("/");if(X.length>=this.strip)_.linkpath=X.slice(this.strip).join("/");else return!1}}if(!this.preservePaths){let Y=f(_.path),X=Y.split("/");if(X.includes("..")||I&&/^[a-z]:\.\.$/i.test(X[0]))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:_,path:Y}),!1;let[oe,le]=c(Y);oe&&(_.path=le,this.warn("TAR_ENTRY_INFO",`stripping ${oe} from absolute path`,{entry:_,path:Y}))}if(o.isAbsolute(_.path)?_.absolute=f(o.resolve(_.path)):_.absolute=f(o.resolve(this.cwd,_.path)),!this.preservePaths&&_.absolute.indexOf(this.cwd+"/")!==0&&_.absolute!==this.cwd)return this.warn("TAR_ENTRY_ERROR","path escaped extraction target",{entry:_,path:f(_.path),resolvedPath:_.absolute,cwd:this.cwd}),!1;if(_.absolute===this.cwd&&_.type!=="Directory"&&_.type!=="GNUDumpDir")return!1;if(this.win32){let{root:Y}=o.win32.parse(_.absolute);_.absolute=Y+u.encode(_.absolute.slice(Y.length));let{root:X}=o.win32.parse(_.path);_.path=X+u.encode(_.path.slice(X.length))}return!0}[g](_){if(!this[H](_))return _.resume();switch(r.equal(typeof _.absolute,"string"),_.type){case"Directory":case"GNUDumpDir":_.mode&&(_.mode=_.mode|448);case"File":case"OldFile":case"ContiguousFile":case"Link":case"SymbolicLink":return this[y](_);case"CharacterDevice":case"BlockDevice":case"FIFO":default:return this[N](_)}}[U](_,Y){_.name==="CwdError"?this.emit("error",_):(this.warn("TAR_ENTRY_ERROR",_,{entry:Y}),this[B](),Y.resume())}[T](_,Y,X){a(f(_),{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:Y,noChmod:this.noChmod},X)}[z](_){return this.forceChown||this.preserveOwner&&(typeof _.uid=="number"&&_.uid!==this.processUid||typeof _.gid=="number"&&_.gid!==this.processGid)||typeof this.uid=="number"&&this.uid!==this.processUid||typeof this.gid=="number"&&this.gid!==this.processGid}[P](_){return q(this.uid,_.uid,this.processUid)}[d](_){return q(this.gid,_.gid,this.processGid)}[R](_,Y){let X=_.mode&4095||this.fmode,oe=new s.WriteStream(_.absolute,{flags:A(_.size),mode:X,autoClose:!1});oe.on("error",pe=>{oe.fd&&n.close(oe.fd,()=>{}),oe.write=()=>!0,this[U](pe,_),Y()});let le=1,Ee=pe=>{if(pe){oe.fd&&n.close(oe.fd,()=>{}),this[U](pe,_),Y();return}--le===0&&n.close(oe.fd,Ae=>{Ae?this[U](Ae,_):this[B](),Y()})};oe.on("finish",pe=>{let Ae=_.absolute,ht=oe.fd;if(_.mtime&&!this.noMtime){le++;let ft=_.atime||new Date,un=_.mtime;n.futimes(ht,ft,un,ln=>ln?n.utimes(Ae,ft,un,ba=>Ee(ba&&ln)):Ee())}if(this[z](_)){le++;let ft=this[P](_),un=this[d](_);n.fchown(ht,ft,un,ln=>ln?n.chown(Ae,ft,un,ba=>Ee(ba&&ln)):Ee())}Ee()});let he=this.transform&&this.transform(_)||_;he!==_&&(he.on("error",pe=>{this[U](pe,_),Y()}),_.pipe(he)),he.pipe(oe)}[x](_,Y){let X=_.mode&4095||this.dmode;this[T](_.absolute,X,oe=>{if(oe){this[U](oe,_),Y();return}let le=1,Ee=he=>{--le===0&&(Y(),this[B](),_.resume())};_.mtime&&!this.noMtime&&(le++,n.utimes(_.absolute,_.atime||new Date,_.mtime,Ee)),this[z](_)&&(le++,n.chown(_.absolute,this[P](_),this[d](_),Ee)),Ee()})}[N](_){_.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${_.type}`,{entry:_}),_.resume()}[b](_,Y){this[L](_,_.linkpath,"symlink",Y)}[S](_,Y){let X=f(o.resolve(this.cwd,_.linkpath));this[L](_,X,"link",Y)}[K](){this[V]++}[B](){this[V]--,this[k]()}[j](_){this[B](),_.resume()}[F](_,Y){return _.type==="File"&&!this.unlink&&Y.isFile()&&Y.nlink<=1&&!I}[y](_){this[K]();let Y=[_.path];_.linkpath&&Y.push(_.linkpath),this.reservations.reserve(Y,X=>this[E](_,X))}[v](_){_.type==="SymbolicLink"?ie(this.dirCache):_.type!=="Directory"&&G(this.dirCache,_.absolute)}[E](_,Y){this[v](_);let X=he=>{this[v](_),Y(he)},oe=()=>{this[T](this.cwd,this.dmode,he=>{if(he){this[U](he,_),X();return}this[m]=!0,le()})},le=()=>{if(_.absolute!==this.cwd){let he=f(o.dirname(_.absolute));if(he!==this.cwd)return this[T](he,this.dmode,pe=>{if(pe){this[U](pe,_),X();return}Ee()})}Ee()},Ee=()=>{n.lstat(_.absolute,(he,pe)=>{if(pe&&(this.keep||this.newer&&pe.mtime>_.mtime)){this[j](_),X();return}if(he||this[F](_,pe))return this[O](null,_,X);if(pe.isDirectory()){if(_.type==="Directory"){let Ae=!this.noChmod&&_.mode&&(pe.mode&4095)!==_.mode,ht=ft=>this[O](ft,_,X);return Ae?n.chmod(_.absolute,_.mode,ht):ht()}if(_.absolute!==this.cwd)return n.rmdir(_.absolute,Ae=>this[O](Ae,_,X))}if(_.absolute===this.cwd)return this[O](null,_,X);M(_.absolute,Ae=>this[O](Ae,_,X))})};this[m]?le():oe()}[O](_,Y,X){if(_){this[U](_,Y),X();return}switch(Y.type){case"File":case"OldFile":case"ContiguousFile":return this[R](Y,X);case"Link":return this[S](Y,X);case"SymbolicLink":return this[b](Y,X);case"Directory":case"GNUDumpDir":return this[x](Y,X)}}[L](_,Y,X,oe){n[X](Y,_.absolute,le=>{le?this[U](le,_):(this[B](),_.resume()),oe()})}},we=_=>{try{return[null,_()]}catch(Y){return[Y,null]}},De=class extends ce{[O](_,Y){return super[O](_,Y,()=>{})}[y](_){if(this[v](_),!this[m]){let le=this[T](this.cwd,this.dmode);if(le)return this[U](le,_);this[m]=!0}if(_.absolute!==this.cwd){let le=f(o.dirname(_.absolute));if(le!==this.cwd){let Ee=this[T](le,this.dmode);if(Ee)return this[U](Ee,_)}}let[Y,X]=we(()=>n.lstatSync(_.absolute));if(X&&(this.keep||this.newer&&X.mtime>_.mtime))return this[j](_);if(Y||this[F](_,X))return this[O](null,_);if(X.isDirectory()){if(_.type==="Directory"){let Ee=!this.noChmod&&_.mode&&(X.mode&4095)!==_.mode,[he]=Ee?we(()=>{n.chmodSync(_.absolute,_.mode)}):[];return this[O](he,_)}let[le]=we(()=>n.rmdirSync(_.absolute));this[O](le,_)}let[oe]=_.absolute===this.cwd?[]:we(()=>Z(_.absolute));this[O](oe,_)}[R](_,Y){let X=_.mode&4095||this.fmode,oe=he=>{let pe;try{n.closeSync(le)}catch(Ae){pe=Ae}(he||pe)&&this[U](he||pe,_),Y()},le;try{le=n.openSync(_.absolute,A(_.size),X)}catch(he){return oe(he)}let Ee=this.transform&&this.transform(_)||_;Ee!==_&&(Ee.on("error",he=>this[U](he,_)),_.pipe(Ee)),Ee.on("data",he=>{try{n.writeSync(le,he,0,he.length)}catch(pe){oe(pe)}}),Ee.on("end",he=>{let pe=null;if(_.mtime&&!this.noMtime){let Ae=_.atime||new Date,ht=_.mtime;try{n.futimesSync(le,Ae,ht)}catch(ft){try{n.utimesSync(_.absolute,Ae,ht)}catch{pe=ft}}}if(this[z](_)){let Ae=this[P](_),ht=this[d](_);try{n.fchownSync(le,Ae,ht)}catch(ft){try{n.chownSync(_.absolute,Ae,ht)}catch{pe=pe||ft}}}oe(pe)})}[x](_,Y){let X=_.mode&4095||this.dmode,oe=this[T](_.absolute,X);if(oe){this[U](oe,_),Y();return}if(_.mtime&&!this.noMtime)try{n.utimesSync(_.absolute,_.atime||new Date,_.mtime)}catch{}if(this[z](_))try{n.chownSync(_.absolute,this[P](_),this[d](_))}catch{}Y(),_.resume()}[T](_,Y){try{return a.sync(f(_),{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:Y})}catch(X){return X}}[L](_,Y,X,oe){try{n[X+"Sync"](Y,_.absolute),oe(),_.resume()}catch(le){return this[U](le,_)}}};ce.Sync=De,e.exports=ce}),yT=te((t,e)=>{"use strict";W();var r=Kn(),i=ab(),n=re("fs"),s=Qn(),o=re("path"),a=Xn();e.exports=(p,g,y)=>{typeof p=="function"?(y=p,g=null,p={}):Array.isArray(p)&&(g=p,p={}),typeof g=="function"&&(y=g,g=null),g?g=Array.from(g):g=[];let E=r(p);if(E.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!E.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return g.length&&u(E,g),E.file&&E.sync?l(E):E.file?c(E,y):E.sync?f(E):h(E)};var u=(p,g)=>{let y=new Map(g.map(F=>[a(F),!0])),E=p.filter,v=(F,O)=>{let R=O||o.parse(F).root||".",x=F===R?!1:y.has(F)?y.get(F):v(o.dirname(F),R);return y.set(F,x),x};p.filter=E?(F,O)=>E(F,O)&&v(a(F)):F=>v(a(F))},l=p=>{let g=new i.Sync(p),y=p.file,E=n.statSync(y),v=p.maxReadSize||16*1024*1024;new s.ReadStreamSync(y,{readSize:v,size:E.size}).pipe(g)},c=(p,g)=>{let y=new i(p),E=p.maxReadSize||16*1024*1024,v=p.file,F=new Promise((O,R)=>{y.on("error",R),y.on("close",O),n.stat(v,(x,L)=>{if(x)R(x);else{let b=new s.ReadStream(v,{readSize:E,size:L.size});b.on("error",R),b.pipe(y)}})});return g?F.then(g,g):F},f=p=>new i.Sync(p),h=p=>new i(p)}),ET=te(t=>{"use strict";W(),t.c=t.create=sT(),t.r=t.replace=nb(),t.t=t.list=Hh(),t.u=t.update=oT(),t.x=t.extract=yT(),t.Pack=jh(),t.Unpack=ab(),t.Parse=$h(),t.ReadEntry=Ih(),t.WriteEntry=rb(),t.Header=Jn(),t.Pax=Nh(),t.types=QD()}),DT=te((t,e)=>{W();function r(i,n){typeof n=="boolean"&&(n={forever:n}),this._originalTimeouts=JSON.parse(JSON.stringify(i)),this._timeouts=i,this._options=n||{},this._maxRetryTime=n&&n.maxRetryTime||1/0,this._fn=null,this._errors=[],this._attempts=1,this._operationTimeout=null,this._operationTimeoutCb=null,this._timeout=null,this._operationStart=null,this._timer=null,this._options.forever&&(this._cachedTimeouts=this._timeouts.slice(0))}e.exports=r,r.prototype.reset=function(){this._attempts=1,this._timeouts=this._originalTimeouts.slice(0)},r.prototype.stop=function(){this._timeout&&clearTimeout(this._timeout),this._timer&&clearTimeout(this._timer),this._timeouts=[],this._cachedTimeouts=null},r.prototype.retry=function(i){if(this._timeout&&clearTimeout(this._timeout),!i)return!1;var n=new Date().getTime();if(i&&n-this._operationStart>=this._maxRetryTime)return this._errors.push(i),this._errors.unshift(new Error("RetryOperation timeout occurred")),!1;this._errors.push(i);var s=this._timeouts.shift();if(s===void 0)if(this._cachedTimeouts)this._errors.splice(0,this._errors.length-1),s=this._cachedTimeouts.slice(-1);else return!1;var o=this;return this._timer=setTimeout(function(){o._attempts++,o._operationTimeoutCb&&(o._timeout=setTimeout(function(){o._operationTimeoutCb(o._attempts)},o._operationTimeout),o._options.unref&&o._timeout.unref()),o._fn(o._attempts)},s),this._options.unref&&this._timer.unref(),!0},r.prototype.attempt=function(i,n){this._fn=i,n&&(n.timeout&&(this._operationTimeout=n.timeout),n.cb&&(this._operationTimeoutCb=n.cb));var s=this;this._operationTimeoutCb&&(this._timeout=setTimeout(function(){s._operationTimeoutCb()},s._operationTimeout)),this._operationStart=new Date().getTime(),this._fn(this._attempts)},r.prototype.try=function(i){console.log("Using RetryOperation.try() is deprecated"),this.attempt(i)},r.prototype.start=function(i){console.log("Using RetryOperation.start() is deprecated"),this.attempt(i)},r.prototype.start=r.prototype.try,r.prototype.errors=function(){return this._errors},r.prototype.attempts=function(){return this._attempts},r.prototype.mainError=function(){if(this._errors.length===0)return null;for(var i={},n=null,s=0,o=0;o<this._errors.length;o++){var a=this._errors[o],u=a.message,l=(i[u]||0)+1;i[u]=l,l>=s&&(n=a,s=l)}return n}}),bT=te(t=>{W();var e=DT();t.operation=function(r){var i=t.timeouts(r);return new e(i,{forever:r&&(r.forever||r.retries===1/0),unref:r&&r.unref,maxRetryTime:r&&r.maxRetryTime})},t.timeouts=function(r){if(r instanceof Array)return[].concat(r);var i={retries:10,factor:2,minTimeout:1*1e3,maxTimeout:1/0,randomize:!1};for(var n in r)i[n]=r[n];if(i.minTimeout>i.maxTimeout)throw new Error("minTimeout is greater than maxTimeout");for(var s=[],o=0;o<i.retries;o++)s.push(this.createTimeout(o,i));return r&&r.forever&&!s.length&&s.push(this.createTimeout(o,i)),s.sort(function(a,u){return a-u}),s},t.createTimeout=function(r,i){var n=i.randomize?Math.random()+1:1,s=Math.round(n*Math.max(i.minTimeout,1)*Math.pow(i.factor,r));return s=Math.min(s,i.maxTimeout),s},t.wrap=function(r,i,n){if(i instanceof Array&&(n=i,i=null),!n){n=[];for(var s in r)typeof r[s]=="function"&&n.push(s)}for(var o=0;o<n.length;o++){var a=n[o],u=r[a];r[a]=function(l){var c=t.operation(i),f=Array.prototype.slice.call(arguments,1),h=f.pop();f.push(function(p){c.retry(p)||(p&&(arguments[0]=c.mainError()),h.apply(this,arguments))}),c.attempt(function(){l.apply(r,f)})}.bind(r,u),r[a].options=i}}}),_T=te((t,e)=>{W(),e.exports=bT()}),wT=te((t,e)=>{W();var r=_T();function i(n,s){function o(a,u){var l=s||{},c;"randomize"in l||(l.randomize=!0),c=r.operation(l);function f(g){u(g||new Error("Aborted"))}function h(g,y){if(g.bail){f(g);return}c.retry(g)?l.onRetry&&l.onRetry(g,y):u(c.mainError())}function p(g){var y;try{y=n(f,g)}catch(E){h(E,g);return}Promise.resolve(y).then(a).catch(function(E){h(E,g)})}c.attempt(p)}return new Promise(o)}e.exports=i}),ST={};Gk(ST,{bold:()=>RT,dimmed:()=>OT,error:()=>BT,grey:()=>kT,info:()=>xT,item:()=>TT,log:()=>ni,turboBlue:()=>tn,turboGradient:()=>vT,turboLoader:()=>CT,turboRed:()=>fb,underline:()=>FT,warn:()=>LT,yellow:()=>pb});W();var cb="#0099F7",hb="#F11712",AT="#FFFF00",vT=(0,lb.default)(cb,hb),tn=Fr.default.hex(cb),fb=Fr.default.hex(hb),pb=Fr.default.hex(AT),CT=t=>(0,ub.default)({text:t,spinner:{frames:[" ",tn("> "),tn(">> "),tn(">>>")]}}),xT=(...t)=>{ni(tn.bold(">>>"),...t)},RT=(...t)=>{ni(Fr.default.bold(...t))},FT=(...t)=>{ni(Fr.default.underline(...t))},OT=(...t)=>{ni(Fr.default.dim(...t))},kT=(...t)=>{ni(Fr.default.grey(...t))},TT=(...t)=>{ni(tn.bold(" \u2022"),...t)},ni=(...t)=>{console.log(...t)},LT=(...t)=>{console.error(pb.bold(">>>"),...t)},BT=(...t)=>{console.error(fb.bold(">>>"),...t)};W();W();W();W();var QI=oa(Vk());W();W();function IT(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}W();W();function Th(t){return Th=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Th(t)}W();function NT(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function MT(t,e){if(e&&(Th(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return NT(t)}W();function sa(t){return sa=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},sa(t)}W();W();function Wn(t,e){return Wn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Wn(t,e)}function jT(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Wn(t,e)}W();W();function $T(t){return Function.toString.call(t).indexOf("[native code]")!==-1}W();W();function HT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function na(t,e,r){return HT()?na=Reflect.construct.bind():na=function(i,n,s){var o=[null];o.push.apply(o,n);var a=Function.bind.apply(i,o),u=new a;return s&&Wn(u,s.prototype),u},na.apply(null,arguments)}function Lh(t){var e=typeof Map=="function"?new Map:void 0;return Lh=function(r){if(r===null||!$T(r))return r;if(typeof r!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e<"u"){if(e.has(r))return e.get(r);e.set(r,i)}function i(){return na(r,arguments,sa(this).constructor)}return i.prototype=Object.create(r.prototype,{constructor:{value:i,enumerable:!1,writable:!0,configurable:!0}}),Wn(i,r)},Lh(t)}var eN=oa(eT()),iN=function(t){jT(e,t);function e(r){var i;return IT(this,e),i=MT(this,sa(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),i.directory=r,i}return e}(Lh(Error));W();W();W();W();W();W();var dN=oa(ET()),mN=(0,mb.promisify)(db.Stream.pipeline);W();W();var DN=oa(wT());W();W();W();var je=class extends Error{constructor(t,e){var r;super(t),this.name="ConvertError",this.type=(r=e==null?void 0:e.type)!=null?r:"unknown",Error.captureStackTrace(this,je)}};W();W();W();W();var qT=/^(?!_)(?<manager>.+)@(?<version>.+)$/;function Ke({workspaceRoot:t}){let e=rr.default.join(t,"package.json");try{return(0,rt.readJsonSync)(e,"utf8")}catch(r){if(r&&typeof r=="object"&&"code"in r){if(r.code==="ENOENT")throw new je(`no "package.json" found at ${t}`,{type:"package_json-missing"});if(r.code==="EJSONPARSE")throw new je(`failed to parse "package.json" at ${t}`,{type:"package_json-parse_error"})}throw new Error(`unexpected error reading "package.json" at ${t}`)}}function aa({workspaceRoot:t}){let{packageManager:e}=Ke({workspaceRoot:t});if(e)try{let r=qT.exec(e);if(r){let[i,n]=r;return n}}catch{}}function es({workspaceRoot:t}){let e=Ke({workspaceRoot:t}),r=rr.default.basename(t),{name:i=r,description:n}=e;return{name:i,description:n}}function VD({workspaceRoot:t}){let e=rr.default.join(t,"pnpm-workspace.yaml");if((0,rt.existsSync)(e))try{let r=Ua.load((0,rt.readFileSync)(e,"utf8"));if(r instanceof Object&&"packages"in r&&Array.isArray(r.packages))return r.packages}catch{throw new je(`failed to parse ${e}`,{type:"pnpm-workspace_parse_error"})}return[]}function ua({root:t,lockFile:e,workspaceConfig:r}){let i=s=>rr.default.join(t,s),n={root:t,lockfile:i(e),packageJson:i("package.json"),nodeModules:i("node_modules")};return r&&(n.workspaceConfig=i(r)),n}function qh({workspaces:t}){var e;return t?Array.isArray(t)?t:"packages"in t?(e=t.packages)!=null?e:[]:[]:[]}function la({workspaceRoot:t,workspaceGlobs:e}){return e?e.flatMap(r=>{let i=[`${r}/package.json`];return(0,_b.sync)(i,{onlyFiles:!0,absolute:!0,cwd:t,ignore:["**/node_modules/**"]})}).map(r=>{let i=rr.default.dirname(r),{name:n,description:s}=es({workspaceRoot:i});return{name:n,description:s,paths:{root:i,packageJson:r,nodeModules:rr.default.join(i,"node_modules")}}}):[]}function UT({directory:t}){let e=rr.default.resolve(process.cwd(),t);return{exists:(0,rt.existsSync)(e),absolute:e}}function Or({packageManager:t,action:e,project:r}){let i=r.workspaceData.globs.length>0;return`${e==="remove"?"Removing":"Adding"} ${t} ${i?"workspaces":""} ${e==="remove"?"from":"to"} ${r.name}`}function GT({project:t}){let e=r=>!(r.includes("*")&&(r.includes("**")||r.split("/").slice(0,-1).join("/").includes("*"))||["!","[","]","{","}"].some(i=>r.includes(i)));return t.workspaceData.globs.every(e)}function tr({project:t,options:e}){e!=null&&e.dry||(0,rt.rmSync)(t.paths.lockfile,{force:!0})}async function wb({project:t,options:e}){if(!(e!=null&&e.dry)&&(0,rt.existsSync)(t.paths.lockfile))try{let{stdout:r}=await(0,bb.default)("bun",["bun.lockb"],{stdin:"ignore",cwd:t.paths.root});await(0,rt.writeFile)(rr.default.join(t.paths.root,"yarn.lock"),r)}catch{}finally{(0,rt.rmSync)(t.paths.lockfile,{force:!0})}}function zT({dependencyList:t,project:e,to:r}){let i=[];return e.workspaceData.workspaces.forEach(n=>{let{name:s}=n;if(t[s]){let o=t[s],a=o.startsWith("workspace:")?o.slice(10):o;t[s]=r.name==="pnpm"?`workspace:${a}`:a,i.push(s)}}),{dependencyList:t,updated:i}}function xr({project:t,workspace:e,to:r,logger:i,options:n}){if(["yarn","npm","bun"].includes(r.name)&&["yarn","npm","bun"].includes(t.packageManager))return;let s=Ke({workspaceRoot:e.paths.root}),o={dependencies:[],devDependencies:[],peerDependencies:[],optionalDependencies:[]},a=["dependencies","devDependencies","peerDependencies","optionalDependencies"];a.forEach(f=>{let h=s[f];if(h){let{updated:p,dependencyList:g}=zT({dependencyList:h,project:t,to:r});s[f]=g,o[f]=p}});let u=f=>{let h=o[f].length;if(h>0)return`${Db.default.green(h.toString())} ${f}`},l=a.map(u).filter(Boolean),c=`./${yb.default.relative(t.paths.root,e.paths.packageJson)}`;if(l.length>=1){let f="updating";l.forEach((h,p)=>{l.length===1?f+=` ${h} in ${c}`:p===l.length-1?f+=`and ${h} in ${c}`:f+=` ${h}, `}),i.workspaceStep(f)}else i.workspaceStep(`no workspace dependencies found in ${c}`);n!=null&&n.dry||(0,Eb.writeJSONSync)(e.paths.packageJson,s,{spaces:2})}var Rr={name:"pnpm",lock:"pnpm-lock.yaml"};async function Sb(t){let e=ri.default.join(t.workspaceRoot,Rr.lock),r=ri.default.join(t.workspaceRoot,"pnpm-workspace.yaml"),i=aa({workspaceRoot:t.workspaceRoot});return(0,qe.existsSync)(e)||(0,qe.existsSync)(r)||i===Rr.name}async function WT(t){if(!await Sb(t))throw new je("Not a pnpm project",{type:"package_manager-unexpected"});let{name:e,description:r}=es(t);return{name:e,description:r,packageManager:Rr.name,paths:ua({root:t.workspaceRoot,lockFile:Rr.lock,workspaceConfig:"pnpm-workspace.yaml"}),workspaceData:{globs:VD(t),workspaces:la({workspaceGlobs:VD(t),...t})}}}async function YT(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;i.mainStep(Or({action:"create",packageManager:Rr.name,project:e}));let o=Ke({workspaceRoot:e.paths.root});i.rootHeader(),o.packageManager=`${r.name}@${r.version}`,i.rootStep(`adding "packageManager" field to ${e.name} root "package.json"`),n!=null&&n.dry||((0,qe.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),s&&(i.rootStep('adding "pnpm-workspace.yaml"'),(0,qe.writeFileSync)(ri.default.join(e.paths.root,"pnpm-workspace.yaml"),`packages:
42
+ `).reduce(a,Object.create(null)),a=(u,l)=>{let c=parseInt(l,10);if(c!==Buffer.byteLength(l)+1)return u;l=l.slice((c+" ").length);let f=l.split("="),h=f.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!h)return u;let p=f.join("=");return u[h]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(h)?new Date(p*1e3):/^[0-9]+$/.test(p)?+p:p,u};e.exports=n}),Xn=te((t,e)=>{W(),e.exports=r=>{let i=r.length-1,n=-1;for(;i>-1&&r.charAt(i)==="/";)n=i,i--;return n===-1?r:r.slice(0,n)}}),Mh=te((t,e)=>{"use strict";W(),e.exports=r=>class extends r{warn(i,n,s={}){this.file&&(s.file=this.file),this.cwd&&(s.cwd=this.cwd),s.code=n instanceof Error&&n.code||i,s.tarCode=i,!this.strict&&s.recoverable!==!1?(n instanceof Error&&(s=Object.assign(n,s),n=n.message),this.emit("warn",s.tarCode,n,s)):n instanceof Error?this.emit("error",Object.assign(n,s)):this.emit("error",Object.assign(new Error(`${i}: ${n}`),s))}}}),eb=te((t,e)=>{"use strict";W();var r=["|","<",">","?",":"],i=r.map(o=>String.fromCharCode(61440+o.charCodeAt(0))),n=new Map(r.map((o,a)=>[o,i[a]])),s=new Map(i.map((o,a)=>[o,r[a]]));e.exports={encode:o=>r.reduce((a,u)=>a.split(u).join(n.get(u)),o),decode:o=>i.reduce((a,u)=>a.split(u).join(s.get(u)),o)}}),tb=te((t,e)=>{W();var{isAbsolute:r,parse:i}=re("path").win32;e.exports=n=>{let s="",o=i(n);for(;r(n)||o.root;){let a=n.charAt(0)==="/"&&n.slice(0,4)!=="//?/"?"/":o.root;n=n.slice(a.length),s+=a,o=i(n)}return[s,n]}}),iT=te((t,e)=>{"use strict";W(),e.exports=(r,i,n)=>(r&=4095,n&&(r=(r|384)&-19),i&&(r&256&&(r|=64),r&32&&(r|=8),r&4&&(r|=1)),r)}),rb=te((t,e)=>{"use strict";W();var r=Ph(),i=Nh(),n=Jn(),s=re("fs"),o=re("path"),a=Zn(),u=Xn(),l=(m,D)=>D?(m=a(m).replace(/^\.(\/|$)/,""),u(D)+"/"+m):a(m),c=16*1024*1024,f=Symbol("process"),h=Symbol("file"),p=Symbol("directory"),g=Symbol("symlink"),y=Symbol("hardlink"),E=Symbol("header"),v=Symbol("read"),F=Symbol("lstat"),O=Symbol("onlstat"),R=Symbol("onread"),x=Symbol("onreadlink"),L=Symbol("openfile"),b=Symbol("onopenfile"),S=Symbol("close"),N=Symbol("mode"),H=Symbol("awaitDrain"),T=Symbol("ondrain"),U=Symbol("prefix"),V=Symbol("hadError"),K=Mh(),B=eb(),C=tb(),k=iT(),j=K(class extends r{constructor(m,D){if(D=D||{},super(D),typeof m!="string")throw new TypeError("path is required");this.path=a(m),this.portable=!!D.portable,this.myuid=process.getuid&&process.getuid()||0,this.myuser=process.env.USER||"",this.maxReadSize=D.maxReadSize||c,this.linkCache=D.linkCache||new Map,this.statCache=D.statCache||new Map,this.preservePaths=!!D.preservePaths,this.cwd=a(D.cwd||process.cwd()),this.strict=!!D.strict,this.noPax=!!D.noPax,this.noMtime=!!D.noMtime,this.mtime=D.mtime||null,this.prefix=D.prefix?a(D.prefix):null,this.fd=null,this.blockLen=null,this.blockRemain=null,this.buf=null,this.offset=null,this.length=null,this.pos=null,this.remain=null,typeof D.onwarn=="function"&&this.on("warn",D.onwarn);let A=!1;if(!this.preservePaths){let[w,I]=C(this.path);w&&(this.path=I,A=w)}this.win32=!!D.win32||process.platform==="win32",this.win32&&(this.path=B.decode(this.path.replace(/\\/g,"/")),m=m.replace(/\\/g,"/")),this.absolute=a(D.absolute||o.resolve(this.cwd,m)),this.path===""&&(this.path="./"),A&&this.warn("TAR_ENTRY_INFO",`stripping ${A} from absolute path`,{entry:this,path:A+this.path}),this.statCache.has(this.absolute)?this[O](this.statCache.get(this.absolute)):this[F]()}emit(m,...D){return m==="error"&&(this[V]=!0),super.emit(m,...D)}[F](){s.lstat(this.absolute,(m,D)=>{if(m)return this.emit("error",m);this[O](D)})}[O](m){this.statCache.set(this.absolute,m),this.stat=m,m.isFile()||(m.size=0),this.type=d(m),this.emit("stat",m),this[f]()}[f](){switch(this.type){case"File":return this[h]();case"Directory":return this[p]();case"SymbolicLink":return this[g]();default:return this.end()}}[N](m){return k(m,this.type==="Directory",this.portable)}[U](m){return l(m,this.prefix)}[E](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new n({path:this[U](this.path),linkpath:this.type==="Link"?this[U](this.linkpath):this.linkpath,mode:this[N](this.stat.mode),uid:this.portable?null:this.stat.uid,gid:this.portable?null:this.stat.gid,size:this.stat.size,mtime:this.noMtime?null:this.mtime||this.stat.mtime,type:this.type,uname:this.portable?null:this.stat.uid===this.myuid?this.myuser:"",atime:this.portable?null:this.stat.atime,ctime:this.portable?null:this.stat.ctime}),this.header.encode()&&!this.noPax&&super.write(new i({atime:this.portable?null:this.header.atime,ctime:this.portable?null:this.header.ctime,gid:this.portable?null:this.header.gid,mtime:this.noMtime?null:this.mtime||this.header.mtime,path:this[U](this.path),linkpath:this.type==="Link"?this[U](this.linkpath):this.linkpath,size:this.header.size,uid:this.portable?null:this.header.uid,uname:this.portable?null:this.header.uname,dev:this.portable?null:this.stat.dev,ino:this.portable?null:this.stat.ino,nlink:this.portable?null:this.stat.nlink}).encode()),super.write(this.header.block)}[p](){this.path.slice(-1)!=="/"&&(this.path+="/"),this.stat.size=0,this[E](),this.end()}[g](){s.readlink(this.absolute,(m,D)=>{if(m)return this.emit("error",m);this[x](D)})}[x](m){this.linkpath=a(m),this[E](),this.end()}[y](m){this.type="Link",this.linkpath=a(o.relative(this.cwd,m)),this.stat.size=0,this[E](),this.end()}[h](){if(this.stat.nlink>1){let m=this.stat.dev+":"+this.stat.ino;if(this.linkCache.has(m)){let D=this.linkCache.get(m);if(D.indexOf(this.cwd)===0)return this[y](D)}this.linkCache.set(m,this.absolute)}if(this[E](),this.stat.size===0)return this.end();this[L]()}[L](){s.open(this.absolute,"r",(m,D)=>{if(m)return this.emit("error",m);this[b](D)})}[b](m){if(this.fd=m,this[V])return this[S]();this.blockLen=512*Math.ceil(this.stat.size/512),this.blockRemain=this.blockLen;let D=Math.min(this.blockLen,this.maxReadSize);this.buf=Buffer.allocUnsafe(D),this.offset=0,this.pos=0,this.remain=this.stat.size,this.length=this.buf.length,this[v]()}[v](){let{fd:m,buf:D,offset:A,length:w,pos:I}=this;s.read(m,D,A,w,I,(M,Z)=>{if(M)return this[S](()=>this.emit("error",M));this[R](Z)})}[S](m){s.close(this.fd,m)}[R](m){if(m<=0&&this.remain>0){let A=new Error("encountered unexpected EOF");return A.path=this.absolute,A.syscall="read",A.code="EOF",this[S](()=>this.emit("error",A))}if(m>this.remain){let A=new Error("did not encounter expected EOF");return A.path=this.absolute,A.syscall="read",A.code="EOF",this[S](()=>this.emit("error",A))}if(m===this.remain)for(let A=m;A<this.length&&m<this.blockRemain;A++)this.buf[A+this.offset]=0,m++,this.remain++;let D=this.offset===0&&m===this.buf.length?this.buf:this.buf.slice(this.offset,this.offset+m);this.write(D)?this[T]():this[H](()=>this[T]())}[H](m){this.once("drain",m)}write(m){if(this.blockRemain<m.length){let D=new Error("writing more data than expected");return D.path=this.absolute,this.emit("error",D)}return this.remain-=m.length,this.blockRemain-=m.length,this.pos+=m.length,this.offset+=m.length,super.write(m)}[T](){if(!this.remain)return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),this[S](m=>m?this.emit("error",m):this.end());this.offset>=this.length&&(this.buf=Buffer.allocUnsafe(Math.min(this.blockRemain,this.buf.length)),this.offset=0),this.length=this.buf.length-this.offset,this[v]()}}),z=class extends j{[F](){this[O](s.lstatSync(this.absolute))}[g](){this[x](s.readlinkSync(this.absolute))}[L](){this[b](s.openSync(this.absolute,"r"))}[v](){let m=!0;try{let{fd:D,buf:A,offset:w,length:I,pos:M}=this,Z=s.readSync(D,A,w,I,M);this[R](Z),m=!1}finally{if(m)try{this[S](()=>{})}catch{}}}[H](m){m()}[S](m){s.closeSync(this.fd),m()}},P=K(class extends r{constructor(m,D){D=D||{},super(D),this.preservePaths=!!D.preservePaths,this.portable=!!D.portable,this.strict=!!D.strict,this.noPax=!!D.noPax,this.noMtime=!!D.noMtime,this.readEntry=m,this.type=m.type,this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.prefix=D.prefix||null,this.path=a(m.path),this.mode=this[N](m.mode),this.uid=this.portable?null:m.uid,this.gid=this.portable?null:m.gid,this.uname=this.portable?null:m.uname,this.gname=this.portable?null:m.gname,this.size=m.size,this.mtime=this.noMtime?null:D.mtime||m.mtime,this.atime=this.portable?null:m.atime,this.ctime=this.portable?null:m.ctime,this.linkpath=a(m.linkpath),typeof D.onwarn=="function"&&this.on("warn",D.onwarn);let A=!1;if(!this.preservePaths){let[w,I]=C(this.path);w&&(this.path=I,A=w)}this.remain=m.size,this.blockRemain=m.startBlockSize,this.header=new n({path:this[U](this.path),linkpath:this.type==="Link"?this[U](this.linkpath):this.linkpath,mode:this.mode,uid:this.portable?null:this.uid,gid:this.portable?null:this.gid,size:this.size,mtime:this.noMtime?null:this.mtime,type:this.type,uname:this.portable?null:this.uname,atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime}),A&&this.warn("TAR_ENTRY_INFO",`stripping ${A} from absolute path`,{entry:this,path:A+this.path}),this.header.encode()&&!this.noPax&&super.write(new i({atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime,gid:this.portable?null:this.gid,mtime:this.noMtime?null:this.mtime,path:this[U](this.path),linkpath:this.type==="Link"?this[U](this.linkpath):this.linkpath,size:this.size,uid:this.portable?null:this.uid,uname:this.portable?null:this.uname,dev:this.portable?null:this.readEntry.dev,ino:this.portable?null:this.readEntry.ino,nlink:this.portable?null:this.readEntry.nlink}).encode()),super.write(this.header.block),m.pipe(this)}[U](m){return l(m,this.prefix)}[N](m){return k(m,this.type==="Directory",this.portable)}write(m){let D=m.length;if(D>this.blockRemain)throw new Error("writing more to entry than is appropriate");return this.blockRemain-=D,super.write(m)}end(){return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),super.end()}});j.Sync=z,j.Tar=P;var d=m=>m.isFile()?"File":m.isDirectory()?"Directory":m.isSymbolicLink()?"SymbolicLink":"Unsupported";e.exports=j}),nT=te((t,e)=>{"use strict";W(),e.exports=function(r){r.prototype[Symbol.iterator]=function*(){for(let i=this.head;i;i=i.next)yield i.value}}}),ib=te((t,e)=>{"use strict";W(),e.exports=r,r.Node=o,r.create=r;function r(a){var u=this;if(u instanceof r||(u=new r),u.tail=null,u.head=null,u.length=0,a&&typeof a.forEach=="function")a.forEach(function(f){u.push(f)});else if(arguments.length>0)for(var l=0,c=arguments.length;l<c;l++)u.push(arguments[l]);return u}r.prototype.removeNode=function(a){if(a.list!==this)throw new Error("removing node which does not belong to this list");var u=a.next,l=a.prev;return u&&(u.prev=l),l&&(l.next=u),a===this.head&&(this.head=u),a===this.tail&&(this.tail=l),a.list.length--,a.next=null,a.prev=null,a.list=null,u},r.prototype.unshiftNode=function(a){if(a!==this.head){a.list&&a.list.removeNode(a);var u=this.head;a.list=this,a.next=u,u&&(u.prev=a),this.head=a,this.tail||(this.tail=a),this.length++}},r.prototype.pushNode=function(a){if(a!==this.tail){a.list&&a.list.removeNode(a);var u=this.tail;a.list=this,a.prev=u,u&&(u.next=a),this.tail=a,this.head||(this.head=a),this.length++}},r.prototype.push=function(){for(var a=0,u=arguments.length;a<u;a++)n(this,arguments[a]);return this.length},r.prototype.unshift=function(){for(var a=0,u=arguments.length;a<u;a++)s(this,arguments[a]);return this.length},r.prototype.pop=function(){if(this.tail){var a=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,a}},r.prototype.shift=function(){if(this.head){var a=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,a}},r.prototype.forEach=function(a,u){u=u||this;for(var l=this.head,c=0;l!==null;c++)a.call(u,l.value,c,this),l=l.next},r.prototype.forEachReverse=function(a,u){u=u||this;for(var l=this.tail,c=this.length-1;l!==null;c--)a.call(u,l.value,c,this),l=l.prev},r.prototype.get=function(a){for(var u=0,l=this.head;l!==null&&u<a;u++)l=l.next;if(u===a&&l!==null)return l.value},r.prototype.getReverse=function(a){for(var u=0,l=this.tail;l!==null&&u<a;u++)l=l.prev;if(u===a&&l!==null)return l.value},r.prototype.map=function(a,u){u=u||this;for(var l=new r,c=this.head;c!==null;)l.push(a.call(u,c.value,this)),c=c.next;return l},r.prototype.mapReverse=function(a,u){u=u||this;for(var l=new r,c=this.tail;c!==null;)l.push(a.call(u,c.value,this)),c=c.prev;return l},r.prototype.reduce=function(a,u){var l,c=this.head;if(arguments.length>1)l=u;else if(this.head)c=this.head.next,l=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=0;c!==null;f++)l=a(l,c.value,f),c=c.next;return l},r.prototype.reduceReverse=function(a,u){var l,c=this.tail;if(arguments.length>1)l=u;else if(this.tail)c=this.tail.prev,l=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=this.length-1;c!==null;f--)l=a(l,c.value,f),c=c.prev;return l},r.prototype.toArray=function(){for(var a=new Array(this.length),u=0,l=this.head;l!==null;u++)a[u]=l.value,l=l.next;return a},r.prototype.toArrayReverse=function(){for(var a=new Array(this.length),u=0,l=this.tail;l!==null;u++)a[u]=l.value,l=l.prev;return a},r.prototype.slice=function(a,u){u=u||this.length,u<0&&(u+=this.length),a=a||0,a<0&&(a+=this.length);var l=new r;if(u<a||u<0)return l;a<0&&(a=0),u>this.length&&(u=this.length);for(var c=0,f=this.head;f!==null&&c<a;c++)f=f.next;for(;f!==null&&c<u;c++,f=f.next)l.push(f.value);return l},r.prototype.sliceReverse=function(a,u){u=u||this.length,u<0&&(u+=this.length),a=a||0,a<0&&(a+=this.length);var l=new r;if(u<a||u<0)return l;a<0&&(a=0),u>this.length&&(u=this.length);for(var c=this.length,f=this.tail;f!==null&&c>u;c--)f=f.prev;for(;f!==null&&c>a;c--,f=f.prev)l.push(f.value);return l},r.prototype.splice=function(a,u,...l){a>this.length&&(a=this.length-1),a<0&&(a=this.length+a);for(var c=0,f=this.head;f!==null&&c<a;c++)f=f.next;for(var h=[],c=0;f&&c<u;c++)h.push(f.value),f=this.removeNode(f);f===null&&(f=this.tail),f!==this.head&&f!==this.tail&&(f=f.prev);for(var c=0;c<l.length;c++)f=i(this,f,l[c]);return h},r.prototype.reverse=function(){for(var a=this.head,u=this.tail,l=a;l!==null;l=l.prev){var c=l.prev;l.prev=l.next,l.next=c}return this.head=u,this.tail=a,this};function i(a,u,l){var c=u===a.head?new o(l,null,u,a):new o(l,u,u.next,a);return c.next===null&&(a.tail=c),c.prev===null&&(a.head=c),a.length++,c}function n(a,u){a.tail=new o(u,a.tail,null,a),a.head||(a.head=a.tail),a.length++}function s(a,u){a.head=new o(u,null,a.head,a),a.tail||(a.tail=a.head),a.length++}function o(a,u,l,c){if(!(this instanceof o))return new o(a,u,l,c);this.list=c,this.value=a,u?(u.next=this,this.prev=u):this.prev=null,l?(l.prev=this,this.next=l):this.next=null}try{nT()(r)}catch{}}),jh=te((t,e)=>{"use strict";W();var r=class{constructor(d,m){this.path=d||"./",this.absolute=m,this.entry=null,this.stat=null,this.readdir=null,this.pending=!1,this.ignore=!1,this.piped=!1}},i=Ph(),n=XD(),s=Ih(),o=rb(),a=o.Sync,u=o.Tar,l=ib(),c=Buffer.alloc(1024),f=Symbol("onStat"),h=Symbol("ended"),p=Symbol("queue"),g=Symbol("current"),y=Symbol("process"),E=Symbol("processing"),v=Symbol("processJob"),F=Symbol("jobs"),O=Symbol("jobDone"),R=Symbol("addFSEntry"),x=Symbol("addTarEntry"),L=Symbol("stat"),b=Symbol("readdir"),S=Symbol("onreaddir"),N=Symbol("pipe"),H=Symbol("entry"),T=Symbol("entryOpt"),U=Symbol("writeEntryClass"),V=Symbol("write"),K=Symbol("ondrain"),B=re("fs"),C=re("path"),k=Mh(),j=Zn(),z=k(class extends i{constructor(d){super(d),d=d||Object.create(null),this.opt=d,this.file=d.file||"",this.cwd=d.cwd||process.cwd(),this.maxReadSize=d.maxReadSize,this.preservePaths=!!d.preservePaths,this.strict=!!d.strict,this.noPax=!!d.noPax,this.prefix=j(d.prefix||""),this.linkCache=d.linkCache||new Map,this.statCache=d.statCache||new Map,this.readdirCache=d.readdirCache||new Map,this[U]=o,typeof d.onwarn=="function"&&this.on("warn",d.onwarn),this.portable=!!d.portable,this.zip=null,d.gzip?(typeof d.gzip!="object"&&(d.gzip={}),this.portable&&(d.gzip.portable=!0),this.zip=new n.Gzip(d.gzip),this.zip.on("data",m=>super.write(m)),this.zip.on("end",m=>super.end()),this.zip.on("drain",m=>this[K]()),this.on("resume",m=>this.zip.resume())):this.on("drain",this[K]),this.noDirRecurse=!!d.noDirRecurse,this.follow=!!d.follow,this.noMtime=!!d.noMtime,this.mtime=d.mtime||null,this.filter=typeof d.filter=="function"?d.filter:m=>!0,this[p]=new l,this[F]=0,this.jobs=+d.jobs||4,this[E]=!1,this[h]=!1}[V](d){return super.write(d)}add(d){return this.write(d),this}end(d){return d&&this.write(d),this[h]=!0,this[y](),this}write(d){if(this[h])throw new Error("write after end");return d instanceof s?this[x](d):this[R](d),this.flowing}[x](d){let m=j(C.resolve(this.cwd,d.path));if(!this.filter(d.path,d))d.resume();else{let D=new r(d.path,m,!1);D.entry=new u(d,this[T](D)),D.entry.on("end",A=>this[O](D)),this[F]+=1,this[p].push(D)}this[y]()}[R](d){let m=j(C.resolve(this.cwd,d));this[p].push(new r(d,m)),this[y]()}[L](d){d.pending=!0,this[F]+=1;let m=this.follow?"stat":"lstat";B[m](d.absolute,(D,A)=>{d.pending=!1,this[F]-=1,D?this.emit("error",D):this[f](d,A)})}[f](d,m){this.statCache.set(d.absolute,m),d.stat=m,this.filter(d.path,m)||(d.ignore=!0),this[y]()}[b](d){d.pending=!0,this[F]+=1,B.readdir(d.absolute,(m,D)=>{if(d.pending=!1,this[F]-=1,m)return this.emit("error",m);this[S](d,D)})}[S](d,m){this.readdirCache.set(d.absolute,m),d.readdir=m,this[y]()}[y](){if(!this[E]){this[E]=!0;for(let d=this[p].head;d!==null&&this[F]<this.jobs;d=d.next)if(this[v](d.value),d.value.ignore){let m=d.next;this[p].removeNode(d),d.next=m}this[E]=!1,this[h]&&!this[p].length&&this[F]===0&&(this.zip?this.zip.end(c):(super.write(c),super.end()))}}get[g](){return this[p]&&this[p].head&&this[p].head.value}[O](d){this[p].shift(),this[F]-=1,this[y]()}[v](d){if(!d.pending){if(d.entry){d===this[g]&&!d.piped&&this[N](d);return}if(d.stat||(this.statCache.has(d.absolute)?this[f](d,this.statCache.get(d.absolute)):this[L](d)),!!d.stat&&!d.ignore&&!(!this.noDirRecurse&&d.stat.isDirectory()&&!d.readdir&&(this.readdirCache.has(d.absolute)?this[S](d,this.readdirCache.get(d.absolute)):this[b](d),!d.readdir))){if(d.entry=this[H](d),!d.entry){d.ignore=!0;return}d===this[g]&&!d.piped&&this[N](d)}}}[T](d){return{onwarn:(m,D,A)=>this.warn(m,D,A),noPax:this.noPax,cwd:this.cwd,absolute:d.absolute,preservePaths:this.preservePaths,maxReadSize:this.maxReadSize,strict:this.strict,portable:this.portable,linkCache:this.linkCache,statCache:this.statCache,noMtime:this.noMtime,mtime:this.mtime,prefix:this.prefix}}[H](d){this[F]+=1;try{return new this[U](d.path,this[T](d)).on("end",()=>this[O](d)).on("error",m=>this.emit("error",m))}catch(m){this.emit("error",m)}}[K](){this[g]&&this[g].entry&&this[g].entry.resume()}[N](d){d.piped=!0,d.readdir&&d.readdir.forEach(A=>{let w=d.path,I=w==="./"?"":w.replace(/\/*$/,"/");this[R](I+A)});let m=d.entry,D=this.zip;D?m.on("data",A=>{D.write(A)||m.pause()}):m.on("data",A=>{super.write(A)||m.pause()})}pause(){return this.zip&&this.zip.pause(),super.pause()}}),P=class extends z{constructor(d){super(d),this[U]=a}pause(){}resume(){}[L](d){let m=this.follow?"statSync":"lstatSync";this[f](d,B[m](d.absolute))}[b](d,m){this[S](d,B.readdirSync(d.absolute))}[N](d){let m=d.entry,D=this.zip;d.readdir&&d.readdir.forEach(A=>{let w=d.path,I=w==="./"?"":w.replace(/\/*$/,"/");this[R](I+A)}),D?m.on("data",A=>{D.write(A)}):m.on("data",A=>{super[V](A)})}};z.Sync=P,e.exports=z}),Qn=te(t=>{"use strict";W();var e=ZD(),r=re("events").EventEmitter,i=re("fs"),n=i.writev;if(!n){let d=process.binding("fs"),m=d.FSReqWrap||d.FSReqCallback;n=(D,A,w,I)=>{let M=(q,Q)=>I(q,Q,A),Z=new m;Z.oncomplete=M,d.writeBuffers(D,A,w,Z)}}var s=Symbol("_autoClose"),o=Symbol("_close"),a=Symbol("_ended"),u=Symbol("_fd"),l=Symbol("_finished"),c=Symbol("_flags"),f=Symbol("_flush"),h=Symbol("_handleChunk"),p=Symbol("_makeBuf"),g=Symbol("_mode"),y=Symbol("_needDrain"),E=Symbol("_onerror"),v=Symbol("_onopen"),F=Symbol("_onread"),O=Symbol("_onwrite"),R=Symbol("_open"),x=Symbol("_path"),L=Symbol("_pos"),b=Symbol("_queue"),S=Symbol("_read"),N=Symbol("_readSize"),H=Symbol("_reading"),T=Symbol("_remain"),U=Symbol("_size"),V=Symbol("_write"),K=Symbol("_writing"),B=Symbol("_defaultFlag"),C=Symbol("_errored"),k=class extends e{constructor(d,m){if(m=m||{},super(m),this.readable=!0,this.writable=!1,typeof d!="string")throw new TypeError("path must be a string");this[C]=!1,this[u]=typeof m.fd=="number"?m.fd:null,this[x]=d,this[N]=m.readSize||16*1024*1024,this[H]=!1,this[U]=typeof m.size=="number"?m.size:1/0,this[T]=this[U],this[s]=typeof m.autoClose=="boolean"?m.autoClose:!0,typeof this[u]=="number"?this[S]():this[R]()}get fd(){return this[u]}get path(){return this[x]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[R](){i.open(this[x],"r",(d,m)=>this[v](d,m))}[v](d,m){d?this[E](d):(this[u]=m,this.emit("open",m),this[S]())}[p](){return Buffer.allocUnsafe(Math.min(this[N],this[T]))}[S](){if(!this[H]){this[H]=!0;let d=this[p]();if(d.length===0)return process.nextTick(()=>this[F](null,0,d));i.read(this[u],d,0,d.length,null,(m,D,A)=>this[F](m,D,A))}}[F](d,m,D){this[H]=!1,d?this[E](d):this[h](m,D)&&this[S]()}[o](){if(this[s]&&typeof this[u]=="number"){let d=this[u];this[u]=null,i.close(d,m=>m?this.emit("error",m):this.emit("close"))}}[E](d){this[H]=!0,this[o](),this.emit("error",d)}[h](d,m){let D=!1;return this[T]-=d,d>0&&(D=super.write(d<m.length?m.slice(0,d):m)),(d===0||this[T]<=0)&&(D=!1,this[o](),super.end()),D}emit(d,m){switch(d){case"prefinish":case"finish":break;case"drain":typeof this[u]=="number"&&this[S]();break;case"error":return this[C]?void 0:(this[C]=!0,super.emit(d,m));default:return super.emit(d,m)}}},j=class extends k{[R](){let d=!0;try{this[v](null,i.openSync(this[x],"r")),d=!1}finally{d&&this[o]()}}[S](){let d=!0;try{if(!this[H]){this[H]=!0;do{let m=this[p](),D=m.length===0?0:i.readSync(this[u],m,0,m.length,null);if(!this[h](D,m))break}while(!0);this[H]=!1}d=!1}finally{d&&this[o]()}}[o](){if(this[s]&&typeof this[u]=="number"){let d=this[u];this[u]=null,i.closeSync(d),this.emit("close")}}},z=class extends r{constructor(d,m){m=m||{},super(m),this.readable=!1,this.writable=!0,this[C]=!1,this[K]=!1,this[a]=!1,this[y]=!1,this[b]=[],this[x]=d,this[u]=typeof m.fd=="number"?m.fd:null,this[g]=m.mode===void 0?438:m.mode,this[L]=typeof m.start=="number"?m.start:null,this[s]=typeof m.autoClose=="boolean"?m.autoClose:!0;let D=this[L]!==null?"r+":"w";this[B]=m.flags===void 0,this[c]=this[B]?D:m.flags,this[u]===null&&this[R]()}emit(d,m){if(d==="error"){if(this[C])return;this[C]=!0}return super.emit(d,m)}get fd(){return this[u]}get path(){return this[x]}[E](d){this[o](),this[K]=!0,this.emit("error",d)}[R](){i.open(this[x],this[c],this[g],(d,m)=>this[v](d,m))}[v](d,m){this[B]&&this[c]==="r+"&&d&&d.code==="ENOENT"?(this[c]="w",this[R]()):d?this[E](d):(this[u]=m,this.emit("open",m),this[f]())}end(d,m){return d&&this.write(d,m),this[a]=!0,!this[K]&&!this[b].length&&typeof this[u]=="number"&&this[O](null,0),this}write(d,m){return typeof d=="string"&&(d=Buffer.from(d,m)),this[a]?(this.emit("error",new Error("write() after end()")),!1):this[u]===null||this[K]||this[b].length?(this[b].push(d),this[y]=!0,!1):(this[K]=!0,this[V](d),!0)}[V](d){i.write(this[u],d,0,d.length,this[L],(m,D)=>this[O](m,D))}[O](d,m){d?this[E](d):(this[L]!==null&&(this[L]+=m),this[b].length?this[f]():(this[K]=!1,this[a]&&!this[l]?(this[l]=!0,this[o](),this.emit("finish")):this[y]&&(this[y]=!1,this.emit("drain"))))}[f](){if(this[b].length===0)this[a]&&this[O](null,0);else if(this[b].length===1)this[V](this[b].pop());else{let d=this[b];this[b]=[],n(this[u],d,this[L],(m,D)=>this[O](m,D))}}[o](){if(this[s]&&typeof this[u]=="number"){let d=this[u];this[u]=null,i.close(d,m=>m?this.emit("error",m):this.emit("close"))}}},P=class extends z{[R](){let d;if(this[B]&&this[c]==="r+")try{d=i.openSync(this[x],this[c],this[g])}catch(m){if(m.code==="ENOENT")return this[c]="w",this[R]();throw m}else d=i.openSync(this[x],this[c],this[g]);this[v](null,d)}[o](){if(this[s]&&typeof this[u]=="number"){let d=this[u];this[u]=null,i.closeSync(d),this.emit("close")}}[V](d){let m=!0;try{this[O](null,i.writeSync(this[u],d,0,d.length,this[L])),m=!1}finally{if(m)try{this[o]()}catch{}}}};t.ReadStream=k,t.ReadStreamSync=j,t.WriteStream=z,t.WriteStreamSync=P}),$h=te((t,e)=>{"use strict";W();var r=Mh(),i=Jn(),n=re("events"),s=ib(),o=1024*1024,a=Ih(),u=Nh(),l=XD(),{nextTick:c}=re("process"),f=Buffer.from([31,139]),h=Symbol("state"),p=Symbol("writeEntry"),g=Symbol("readEntry"),y=Symbol("nextEntry"),E=Symbol("processEntry"),v=Symbol("extendedHeader"),F=Symbol("globalExtendedHeader"),O=Symbol("meta"),R=Symbol("emitMeta"),x=Symbol("buffer"),L=Symbol("queue"),b=Symbol("ended"),S=Symbol("emittedEnd"),N=Symbol("emit"),H=Symbol("unzip"),T=Symbol("consumeChunk"),U=Symbol("consumeChunkSub"),V=Symbol("consumeBody"),K=Symbol("consumeMeta"),B=Symbol("consumeHeader"),C=Symbol("consuming"),k=Symbol("bufferConcat"),j=Symbol("maybeEnd"),z=Symbol("writing"),P=Symbol("aborted"),d=Symbol("onDone"),m=Symbol("sawValidEntry"),D=Symbol("sawNullBlock"),A=Symbol("sawEOF"),w=Symbol("closeStream"),I=M=>!0;e.exports=r(class extends n{constructor(M){M=M||{},super(M),this.file=M.file||"",this[m]=null,this.on(d,Z=>{(this[h]==="begin"||this[m]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),M.ondone?this.on(d,M.ondone):this.on(d,Z=>{this.emit("prefinish"),this.emit("finish"),this.emit("end")}),this.strict=!!M.strict,this.maxMetaEntrySize=M.maxMetaEntrySize||o,this.filter=typeof M.filter=="function"?M.filter:I,this.writable=!0,this.readable=!1,this[L]=new s,this[x]=null,this[g]=null,this[p]=null,this[h]="begin",this[O]="",this[v]=null,this[F]=null,this[b]=!1,this[H]=null,this[P]=!1,this[D]=!1,this[A]=!1,this.on("end",()=>this[w]()),typeof M.onwarn=="function"&&this.on("warn",M.onwarn),typeof M.onentry=="function"&&this.on("entry",M.onentry)}[B](M,Z){this[m]===null&&(this[m]=!1);let q;try{q=new i(M,Z,this[v],this[F])}catch(Q){return this.warn("TAR_ENTRY_INVALID",Q)}if(q.nullBlock)this[D]?(this[A]=!0,this[h]==="begin"&&(this[h]="header"),this[N]("eof")):(this[D]=!0,this[N]("nullBlock"));else if(this[D]=!1,!q.cksumValid)this.warn("TAR_ENTRY_INVALID","checksum failure",{header:q});else if(!q.path)this.warn("TAR_ENTRY_INVALID","path is required",{header:q});else{let Q=q.type;if(/^(Symbolic)?Link$/.test(Q)&&!q.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath required",{header:q});else if(!/^(Symbolic)?Link$/.test(Q)&&q.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath forbidden",{header:q});else{let G=this[p]=new a(q,this[v],this[F]);if(!this[m])if(G.remain){let ie=()=>{G.invalid||(this[m]=!0)};G.on("end",ie)}else this[m]=!0;G.meta?G.size>this.maxMetaEntrySize?(G.ignore=!0,this[N]("ignoredEntry",G),this[h]="ignore",G.resume()):G.size>0&&(this[O]="",G.on("data",ie=>this[O]+=ie),this[h]="meta"):(this[v]=null,G.ignore=G.ignore||!this.filter(G.path,G),G.ignore?(this[N]("ignoredEntry",G),this[h]=G.remain?"ignore":"header",G.resume()):(G.remain?this[h]="body":(this[h]="header",G.end()),this[g]?this[L].push(G):(this[L].push(G),this[y]())))}}}[w](){c(()=>this.emit("close"))}[E](M){let Z=!0;return M?Array.isArray(M)?this.emit.apply(this,M):(this[g]=M,this.emit("entry",M),M.emittedEnd||(M.on("end",q=>this[y]()),Z=!1)):(this[g]=null,Z=!1),Z}[y](){do;while(this[E](this[L].shift()));if(!this[L].length){let M=this[g];!M||M.flowing||M.size===M.remain?this[z]||this.emit("drain"):M.once("drain",Z=>this.emit("drain"))}}[V](M,Z){let q=this[p],Q=q.blockRemain,G=Q>=M.length&&Z===0?M:M.slice(Z,Z+Q);return q.write(G),q.blockRemain||(this[h]="header",this[p]=null,q.end()),G.length}[K](M,Z){let q=this[p],Q=this[V](M,Z);return this[p]||this[R](q),Q}[N](M,Z,q){!this[L].length&&!this[g]?this.emit(M,Z,q):this[L].push([M,Z,q])}[R](M){switch(this[N]("meta",this[O]),M.type){case"ExtendedHeader":case"OldExtendedHeader":this[v]=u.parse(this[O],this[v],!1);break;case"GlobalExtendedHeader":this[F]=u.parse(this[O],this[F],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[v]=this[v]||Object.create(null),this[v].path=this[O].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[v]=this[v]||Object.create(null),this[v].linkpath=this[O].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+M.type)}}abort(M){this[P]=!0,this.emit("abort",M),this.warn("TAR_ABORT",M,{recoverable:!1})}write(M){if(this[P])return;if(this[H]===null&&M){if(this[x]&&(M=Buffer.concat([this[x],M]),this[x]=null),M.length<f.length)return this[x]=M,!0;for(let q=0;this[H]===null&&q<f.length;q++)M[q]!==f[q]&&(this[H]=!1);if(this[H]===null){let q=this[b];this[b]=!1,this[H]=new l.Unzip,this[H].on("data",G=>this[T](G)),this[H].on("error",G=>this.abort(G)),this[H].on("end",G=>{this[b]=!0,this[T]()}),this[z]=!0;let Q=this[H][q?"end":"write"](M);return this[z]=!1,Q}}this[z]=!0,this[H]?this[H].write(M):this[T](M),this[z]=!1;let Z=this[L].length?!1:this[g]?this[g].flowing:!0;return!Z&&!this[L].length&&this[g].once("drain",q=>this.emit("drain")),Z}[k](M){M&&!this[P]&&(this[x]=this[x]?Buffer.concat([this[x],M]):M)}[j](){if(this[b]&&!this[S]&&!this[P]&&!this[C]){this[S]=!0;let M=this[p];if(M&&M.blockRemain){let Z=this[x]?this[x].length:0;this.warn("TAR_BAD_ARCHIVE",`Truncated input (needed ${M.blockRemain} more bytes, only ${Z} available)`,{entry:M}),this[x]&&M.write(this[x]),M.end()}this[N](d)}}[T](M){if(this[C])this[k](M);else if(!M&&!this[x])this[j]();else{if(this[C]=!0,this[x]){this[k](M);let Z=this[x];this[x]=null,this[U](Z)}else this[U](M);for(;this[x]&&this[x].length>=512&&!this[P]&&!this[A];){let Z=this[x];this[x]=null,this[U](Z)}this[C]=!1}(!this[x]||this[b])&&this[j]()}[U](M){let Z=0,q=M.length;for(;Z+512<=q&&!this[P]&&!this[A];)switch(this[h]){case"begin":case"header":this[B](M,Z),Z+=512;break;case"ignore":case"body":Z+=this[V](M,Z);break;case"meta":Z+=this[K](M,Z);break;default:throw new Error("invalid state: "+this[h])}Z<q&&(this[x]?this[x]=Buffer.concat([M.slice(Z),this[x]]):this[x]=M.slice(Z))}end(M){this[P]||(this[H]?this[H].end(M):(this[b]=!0,this.write(M)))}})}),Hh=te((t,e)=>{"use strict";W();var r=Kn(),i=$h(),n=re("fs"),s=Qn(),o=re("path"),a=Xn();e.exports=(p,g,y)=>{typeof p=="function"?(y=p,g=null,p={}):Array.isArray(p)&&(g=p,p={}),typeof g=="function"&&(y=g,g=null),g?g=Array.from(g):g=[];let E=r(p);if(E.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!E.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return g.length&&l(E,g),E.noResume||u(E),E.file&&E.sync?c(E):E.file?f(E,y):h(E)};var u=p=>{let g=p.onentry;p.onentry=g?y=>{g(y),y.resume()}:y=>y.resume()},l=(p,g)=>{let y=new Map(g.map(F=>[a(F),!0])),E=p.filter,v=(F,O)=>{let R=O||o.parse(F).root||".",x=F===R?!1:y.has(F)?y.get(F):v(o.dirname(F),R);return y.set(F,x),x};p.filter=E?(F,O)=>E(F,O)&&v(a(F)):F=>v(a(F))},c=p=>{let g=h(p),y=p.file,E=!0,v;try{let F=n.statSync(y),O=p.maxReadSize||16*1024*1024;if(F.size<O)g.end(n.readFileSync(y));else{let R=0,x=Buffer.allocUnsafe(O);for(v=n.openSync(y,"r");R<F.size;){let L=n.readSync(v,x,0,O,R);R+=L,g.write(x.slice(0,L))}g.end()}E=!1}finally{if(E&&v)try{n.closeSync(v)}catch{}}},f=(p,g)=>{let y=new i(p),E=p.maxReadSize||16*1024*1024,v=p.file,F=new Promise((O,R)=>{y.on("error",R),y.on("end",O),n.stat(v,(x,L)=>{if(x)R(x);else{let b=new s.ReadStream(v,{readSize:E,size:L.size});b.on("error",R),b.pipe(y)}})});return g?F.then(g,g):F},h=p=>new i(p)}),sT=te((t,e)=>{"use strict";W();var r=Kn(),i=jh(),n=Qn(),s=Hh(),o=re("path");e.exports=(p,g,y)=>{if(typeof g=="function"&&(y=g),Array.isArray(p)&&(g=p,p={}),!g||!Array.isArray(g)||!g.length)throw new TypeError("no files or directories specified");g=Array.from(g);let E=r(p);if(E.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!E.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return E.file&&E.sync?a(E,g):E.file?u(E,g,y):E.sync?f(E,g):h(E,g)};var a=(p,g)=>{let y=new i.Sync(p),E=new n.WriteStreamSync(p.file,{mode:p.mode||438});y.pipe(E),l(y,g)},u=(p,g,y)=>{let E=new i(p),v=new n.WriteStream(p.file,{mode:p.mode||438});E.pipe(v);let F=new Promise((O,R)=>{v.on("error",R),v.on("close",O),E.on("error",R)});return c(E,g),y?F.then(y,y):F},l=(p,g)=>{g.forEach(y=>{y.charAt(0)==="@"?s({file:o.resolve(p.cwd,y.slice(1)),sync:!0,noResume:!0,onentry:E=>p.add(E)}):p.add(y)}),p.end()},c=(p,g)=>{for(;g.length;){let y=g.shift();if(y.charAt(0)==="@")return s({file:o.resolve(p.cwd,y.slice(1)),noResume:!0,onentry:E=>p.add(E)}).then(E=>c(p,g));p.add(y)}p.end()},f=(p,g)=>{let y=new i.Sync(p);return l(y,g),y},h=(p,g)=>{let y=new i(p);return c(y,g),y}}),nb=te((t,e)=>{"use strict";W();var r=Kn(),i=jh(),n=re("fs"),s=Qn(),o=Hh(),a=re("path"),u=Jn();e.exports=(g,y,E)=>{let v=r(g);if(!v.file)throw new TypeError("file is required");if(v.gzip)throw new TypeError("cannot append to compressed archives");if(!y||!Array.isArray(y)||!y.length)throw new TypeError("no files or directories specified");return y=Array.from(y),v.sync?l(v,y):f(v,y,E)};var l=(g,y)=>{let E=new i.Sync(g),v=!0,F,O;try{try{F=n.openSync(g.file,"r+")}catch(L){if(L.code==="ENOENT")F=n.openSync(g.file,"w+");else throw L}let R=n.fstatSync(F),x=Buffer.alloc(512);e:for(O=0;O<R.size;O+=512){for(let S=0,N=0;S<512;S+=N){if(N=n.readSync(F,x,S,x.length-S,O+S),O===0&&x[0]===31&&x[1]===139)throw new Error("cannot append to compressed archives");if(!N)break e}let L=new u(x);if(!L.cksumValid)break;let b=512*Math.ceil(L.size/512);if(O+b+512>R.size)break;O+=b,g.mtimeCache&&g.mtimeCache.set(L.path,L.mtime)}v=!1,c(g,E,O,F,y)}finally{if(v)try{n.closeSync(F)}catch{}}},c=(g,y,E,v,F)=>{let O=new s.WriteStreamSync(g.file,{fd:v,start:E});y.pipe(O),h(y,F)},f=(g,y,E)=>{y=Array.from(y);let v=new i(g),F=(R,x,L)=>{let b=(U,V)=>{U?n.close(R,K=>L(U)):L(null,V)},S=0;if(x===0)return b(null,0);let N=0,H=Buffer.alloc(512),T=(U,V)=>{if(U)return b(U);if(N+=V,N<512&&V)return n.read(R,H,N,H.length-N,S+N,T);if(S===0&&H[0]===31&&H[1]===139)return b(new Error("cannot append to compressed archives"));if(N<512)return b(null,S);let K=new u(H);if(!K.cksumValid)return b(null,S);let B=512*Math.ceil(K.size/512);if(S+B+512>x||(S+=B+512,S>=x))return b(null,S);g.mtimeCache&&g.mtimeCache.set(K.path,K.mtime),N=0,n.read(R,H,0,512,S,T)};n.read(R,H,0,512,S,T)},O=new Promise((R,x)=>{v.on("error",x);let L="r+",b=(S,N)=>{if(S&&S.code==="ENOENT"&&L==="r+")return L="w+",n.open(g.file,L,b);if(S)return x(S);n.fstat(N,(H,T)=>{if(H)return n.close(N,()=>x(H));F(N,T.size,(U,V)=>{if(U)return x(U);let K=new s.WriteStream(g.file,{fd:N,start:V});v.pipe(K),K.on("error",x),K.on("close",R),p(v,y)})})};n.open(g.file,L,b)});return E?O.then(E,E):O},h=(g,y)=>{y.forEach(E=>{E.charAt(0)==="@"?o({file:a.resolve(g.cwd,E.slice(1)),sync:!0,noResume:!0,onentry:v=>g.add(v)}):g.add(E)}),g.end()},p=(g,y)=>{for(;y.length;){let E=y.shift();if(E.charAt(0)==="@")return o({file:a.resolve(g.cwd,E.slice(1)),noResume:!0,onentry:v=>g.add(v)}).then(v=>p(g,y));g.add(E)}g.end()}}),oT=te((t,e)=>{"use strict";W();var r=Kn(),i=nb();e.exports=(s,o,a)=>{let u=r(s);if(!u.file)throw new TypeError("file is required");if(u.gzip)throw new TypeError("cannot append to compressed archives");if(!o||!Array.isArray(o)||!o.length)throw new TypeError("no files or directories specified");return o=Array.from(o),n(u),i(u,o,a)};var n=s=>{let o=s.filter;s.mtimeCache||(s.mtimeCache=new Map),s.filter=o?(a,u)=>o(a,u)&&!(s.mtimeCache.get(a)>u.mtime):(a,u)=>!(s.mtimeCache.get(a)>u.mtime)}}),aT=te((t,e)=>{W();var{promisify:r}=re("util"),i=re("fs"),n=s=>{if(!s)s={mode:511,fs:i};else if(typeof s=="object")s={mode:511,fs:i,...s};else if(typeof s=="number")s={mode:s,fs:i};else if(typeof s=="string")s={mode:parseInt(s,8),fs:i};else throw new TypeError("invalid options argument");return s.mkdir=s.mkdir||s.fs.mkdir||i.mkdir,s.mkdirAsync=r(s.mkdir),s.stat=s.stat||s.fs.stat||i.stat,s.statAsync=r(s.stat),s.statSync=s.statSync||s.fs.statSync||i.statSync,s.mkdirSync=s.mkdirSync||s.fs.mkdirSync||i.mkdirSync,s};e.exports=n}),uT=te((t,e)=>{W();var r=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:i,parse:n}=re("path"),s=o=>{if(/\0/.test(o))throw Object.assign(new TypeError("path must be a string without null bytes"),{path:o,code:"ERR_INVALID_ARG_VALUE"});if(o=i(o),r==="win32"){let a=/[*|"<>?:]/,{root:u}=n(o);if(a.test(o.substr(u.length)))throw Object.assign(new Error("Illegal characters in path."),{path:o,code:"EINVAL"})}return o};e.exports=s}),lT=te((t,e)=>{W();var{dirname:r}=re("path"),i=(s,o,a=void 0)=>a===o?Promise.resolve():s.statAsync(o).then(u=>u.isDirectory()?a:void 0,u=>u.code==="ENOENT"?i(s,r(o),o):void 0),n=(s,o,a=void 0)=>{if(a!==o)try{return s.statSync(o).isDirectory()?a:void 0}catch(u){return u.code==="ENOENT"?n(s,r(o),o):void 0}};e.exports={findMade:i,findMadeSync:n}}),sb=te((t,e)=>{W();var{dirname:r}=re("path"),i=(s,o,a)=>{o.recursive=!1;let u=r(s);return u===s?o.mkdirAsync(s,o).catch(l=>{if(l.code!=="EISDIR")throw l}):o.mkdirAsync(s,o).then(()=>a||s,l=>{if(l.code==="ENOENT")return i(u,o).then(c=>i(s,o,c));if(l.code!=="EEXIST"&&l.code!=="EROFS")throw l;return o.statAsync(s).then(c=>{if(c.isDirectory())return a;throw l},()=>{throw l})})},n=(s,o,a)=>{let u=r(s);if(o.recursive=!1,u===s)try{return o.mkdirSync(s,o)}catch(l){if(l.code!=="EISDIR")throw l;return}try{return o.mkdirSync(s,o),a||s}catch(l){if(l.code==="ENOENT")return n(s,o,n(u,o,a));if(l.code!=="EEXIST"&&l.code!=="EROFS")throw l;try{if(!o.statSync(s).isDirectory())throw l}catch{throw l}}};e.exports={mkdirpManual:i,mkdirpManualSync:n}}),cT=te((t,e)=>{W();var{dirname:r}=re("path"),{findMade:i,findMadeSync:n}=lT(),{mkdirpManual:s,mkdirpManualSync:o}=sb(),a=(l,c)=>(c.recursive=!0,r(l)===l?c.mkdirAsync(l,c):i(c,l).then(f=>c.mkdirAsync(l,c).then(()=>f).catch(h=>{if(h.code==="ENOENT")return s(l,c);throw h}))),u=(l,c)=>{if(c.recursive=!0,r(l)===l)return c.mkdirSync(l,c);let f=n(c,l);try{return c.mkdirSync(l,c),f}catch(h){if(h.code==="ENOENT")return o(l,c);throw h}};e.exports={mkdirpNative:a,mkdirpNativeSync:u}}),hT=te((t,e)=>{W();var r=re("fs"),i=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version,n=i.replace(/^v/,"").split("."),s=+n[0]>10||+n[0]==10&&+n[1]>=12,o=s?u=>u.mkdir===r.mkdir:()=>!1,a=s?u=>u.mkdirSync===r.mkdirSync:()=>!1;e.exports={useNative:o,useNativeSync:a}}),fT=te((t,e)=>{W();var r=aT(),i=uT(),{mkdirpNative:n,mkdirpNativeSync:s}=cT(),{mkdirpManual:o,mkdirpManualSync:a}=sb(),{useNative:u,useNativeSync:l}=hT(),c=(h,p)=>(h=i(h),p=r(p),u(p)?n(h,p):o(h,p)),f=(h,p)=>(h=i(h),p=r(p),l(p)?s(h,p):a(h,p));c.sync=f,c.native=(h,p)=>n(i(h),r(p)),c.manual=(h,p)=>o(i(h),r(p)),c.nativeSync=(h,p)=>s(i(h),r(p)),c.manualSync=(h,p)=>a(i(h),r(p)),e.exports=c}),pT=te((t,e)=>{"use strict";W();var r=re("fs"),i=re("path"),n=r.lchown?"lchown":"chown",s=r.lchownSync?"lchownSync":"chownSync",o=r.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),a=(O,R,x)=>{try{return r[s](O,R,x)}catch(L){if(L.code!=="ENOENT")throw L}},u=(O,R,x)=>{try{return r.chownSync(O,R,x)}catch(L){if(L.code!=="ENOENT")throw L}},l=o?(O,R,x,L)=>b=>{!b||b.code!=="EISDIR"?L(b):r.chown(O,R,x,L)}:(O,R,x,L)=>L,c=o?(O,R,x)=>{try{return a(O,R,x)}catch(L){if(L.code!=="EISDIR")throw L;u(O,R,x)}}:(O,R,x)=>a(O,R,x),f=process.version,h=(O,R,x)=>r.readdir(O,R,x),p=(O,R)=>r.readdirSync(O,R);/^v4\./.test(f)&&(h=(O,R,x)=>r.readdir(O,x));var g=(O,R,x,L)=>{r[n](O,R,x,l(O,R,x,b=>{L(b&&b.code!=="ENOENT"?b:null)}))},y=(O,R,x,L,b)=>{if(typeof R=="string")return r.lstat(i.resolve(O,R),(S,N)=>{if(S)return b(S.code!=="ENOENT"?S:null);N.name=R,y(O,N,x,L,b)});if(R.isDirectory())E(i.resolve(O,R.name),x,L,S=>{if(S)return b(S);let N=i.resolve(O,R.name);g(N,x,L,b)});else{let S=i.resolve(O,R.name);g(S,x,L,b)}},E=(O,R,x,L)=>{h(O,{withFileTypes:!0},(b,S)=>{if(b){if(b.code==="ENOENT")return L();if(b.code!=="ENOTDIR"&&b.code!=="ENOTSUP")return L(b)}if(b||!S.length)return g(O,R,x,L);let N=S.length,H=null,T=U=>{if(!H){if(U)return L(H=U);if(--N===0)return g(O,R,x,L)}};S.forEach(U=>y(O,U,R,x,T))})},v=(O,R,x,L)=>{if(typeof R=="string")try{let b=r.lstatSync(i.resolve(O,R));b.name=R,R=b}catch(b){if(b.code==="ENOENT")return;throw b}R.isDirectory()&&F(i.resolve(O,R.name),x,L),c(i.resolve(O,R.name),x,L)},F=(O,R,x)=>{let L;try{L=p(O,{withFileTypes:!0})}catch(b){if(b.code==="ENOENT")return;if(b.code==="ENOTDIR"||b.code==="ENOTSUP")return c(O,R,x);throw b}return L&&L.length&&L.forEach(b=>v(O,b,R,x)),c(O,R,x)};e.exports=E,E.sync=F}),dT=te((t,e)=>{"use strict";W();var r=fT(),i=re("fs"),n=re("path"),s=pT(),o=Zn(),a=class extends Error{constructor(y,E){super("Cannot extract through symbolic link"),this.path=E,this.symlink=y}get name(){return"SylinkError"}},u=class extends Error{constructor(y,E){super(E+": Cannot cd into '"+y+"'"),this.path=y,this.code=E}get name(){return"CwdError"}},l=(y,E)=>y.get(o(E)),c=(y,E,v)=>y.set(o(E),v),f=(y,E)=>{i.stat(y,(v,F)=>{(v||!F.isDirectory())&&(v=new u(y,v&&v.code||"ENOTDIR")),E(v)})};e.exports=(y,E,v)=>{y=o(y);let F=E.umask,O=E.mode|448,R=(O&F)!==0,x=E.uid,L=E.gid,b=typeof x=="number"&&typeof L=="number"&&(x!==E.processUid||L!==E.processGid),S=E.preserve,N=E.unlink,H=E.cache,T=o(E.cwd),U=(K,B)=>{K?v(K):(c(H,y,!0),B&&b?s(B,x,L,C=>U(C)):R?i.chmod(y,O,v):v())};if(H&&l(H,y)===!0)return U();if(y===T)return f(y,U);if(S)return r(y,{mode:O}).then(K=>U(null,K),U);let V=o(n.relative(T,y)).split("/");h(T,V,O,H,N,T,null,U)};var h=(y,E,v,F,O,R,x,L)=>{if(!E.length)return L(null,x);let b=E.shift(),S=o(n.resolve(y+"/"+b));if(l(F,S))return h(S,E,v,F,O,R,x,L);i.mkdir(S,v,p(S,E,v,F,O,R,x,L))},p=(y,E,v,F,O,R,x,L)=>b=>{b?i.lstat(y,(S,N)=>{if(S)S.path=S.path&&o(S.path),L(S);else if(N.isDirectory())h(y,E,v,F,O,R,x,L);else if(O)i.unlink(y,H=>{if(H)return L(H);i.mkdir(y,v,p(y,E,v,F,O,R,x,L))});else{if(N.isSymbolicLink())return L(new a(y,y+"/"+E.join("/")));L(b)}}):(x=x||y,h(y,E,v,F,O,R,x,L))},g=y=>{let E=!1,v="ENOTDIR";try{E=i.statSync(y).isDirectory()}catch(F){v=F.code}finally{if(!E)throw new u(y,v)}};e.exports.sync=(y,E)=>{y=o(y);let v=E.umask,F=E.mode|448,O=(F&v)!==0,R=E.uid,x=E.gid,L=typeof R=="number"&&typeof x=="number"&&(R!==E.processUid||x!==E.processGid),b=E.preserve,S=E.unlink,N=E.cache,H=o(E.cwd),T=K=>{c(N,y,!0),K&&L&&s.sync(K,R,x),O&&i.chmodSync(y,F)};if(N&&l(N,y)===!0)return T();if(y===H)return g(H),T();if(b)return T(r.sync(y,F));let U=o(n.relative(H,y)).split("/"),V=null;for(let K=U.shift(),B=H;K&&(B+="/"+K);K=U.shift())if(B=o(n.resolve(B)),!l(N,B))try{i.mkdirSync(B,F),V=V||B,c(N,B,!0)}catch{let C=i.lstatSync(B);if(C.isDirectory()){c(N,B,!0);continue}else if(S){i.unlinkSync(B),i.mkdirSync(B,F),V=V||B,c(N,B,!0);continue}else if(C.isSymbolicLink())return new a(B,B+"/"+U.join("/"))}return T(V)}}),ob=te((t,e)=>{W();var r=Object.create(null),{hasOwnProperty:i}=Object.prototype;e.exports=n=>(i.call(r,n)||(r[n]=n.normalize("NFKD")),r[n])}),mT=te((t,e)=>{W();var r=re("assert"),i=ob(),n=Xn(),{join:s}=re("path"),o=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,a=o==="win32";e.exports=()=>{let u=new Map,l=new Map,c=E=>E.split("/").slice(0,-1).reduce((v,F)=>(v.length&&(F=s(v[v.length-1],F)),v.push(F||"/"),v),[]),f=new Set,h=E=>{let v=l.get(E);if(!v)throw new Error("function does not have any path reservations");return{paths:v.paths.map(F=>u.get(F)),dirs:[...v.dirs].map(F=>u.get(F))}},p=E=>{let{paths:v,dirs:F}=h(E);return v.every(O=>O[0]===E)&&F.every(O=>O[0]instanceof Set&&O[0].has(E))},g=E=>f.has(E)||!p(E)?!1:(f.add(E),E(()=>y(E)),!0),y=E=>{if(!f.has(E))return!1;let{paths:v,dirs:F}=l.get(E),O=new Set;return v.forEach(R=>{let x=u.get(R);r.equal(x[0],E),x.length===1?u.delete(R):(x.shift(),typeof x[0]=="function"?O.add(x[0]):x[0].forEach(L=>O.add(L)))}),F.forEach(R=>{let x=u.get(R);r(x[0]instanceof Set),x[0].size===1&&x.length===1?u.delete(R):x[0].size===1?(x.shift(),O.add(x[0])):x[0].delete(E)}),f.delete(E),O.forEach(R=>g(R)),!0};return{check:p,reserve:(E,v)=>{E=a?["win32 parallelization disabled"]:E.map(O=>i(n(s(O))).toLowerCase());let F=new Set(E.map(O=>c(O)).reduce((O,R)=>O.concat(R)));return l.set(v,{dirs:F,paths:E}),E.forEach(O=>{let R=u.get(O);R?R.push(v):u.set(O,[v])}),F.forEach(O=>{let R=u.get(O);R?R[R.length-1]instanceof Set?R[R.length-1].add(v):R.push(new Set([v])):u.set(O,[new Set([v])])}),g(v)}}}}),gT=te((t,e)=>{W();var r=process.env.__FAKE_PLATFORM__||process.platform,i=r==="win32",n=global.__FAKE_TESTING_FS__||re("fs"),{O_CREAT:s,O_TRUNC:o,O_WRONLY:a,UV_FS_O_FILEMAP:u=0}=n.constants,l=i&&!!u,c=512*1024,f=u|o|s|a;e.exports=l?h=>h<c?f:"w":()=>"w"}),ab=te((t,e)=>{"use strict";W();var r=re("assert"),i=$h(),n=re("fs"),s=Qn(),o=re("path"),a=dT(),u=eb(),l=mT(),c=tb(),f=Zn(),h=Xn(),p=ob(),g=Symbol("onEntry"),y=Symbol("checkFs"),E=Symbol("checkFs2"),v=Symbol("pruneCache"),F=Symbol("isReusable"),O=Symbol("makeFs"),R=Symbol("file"),x=Symbol("directory"),L=Symbol("link"),b=Symbol("symlink"),S=Symbol("hardlink"),N=Symbol("unsupported"),H=Symbol("checkPath"),T=Symbol("mkdir"),U=Symbol("onError"),V=Symbol("pending"),K=Symbol("pend"),B=Symbol("unpend"),C=Symbol("ended"),k=Symbol("maybeClose"),j=Symbol("skip"),z=Symbol("doChown"),P=Symbol("uid"),d=Symbol("gid"),m=Symbol("checkedCwd"),D=re("crypto"),A=gT(),w=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,I=w==="win32",M=(_,Y)=>{if(!I)return n.unlink(_,Y);let X=_+".DELETE."+D.randomBytes(16).toString("hex");n.rename(_,X,oe=>{if(oe)return Y(oe);n.unlink(X,Y)})},Z=_=>{if(!I)return n.unlinkSync(_);let Y=_+".DELETE."+D.randomBytes(16).toString("hex");n.renameSync(_,Y),n.unlinkSync(Y)},q=(_,Y,X)=>_===_>>>0?_:Y===Y>>>0?Y:X,Q=_=>p(h(f(_))).toLowerCase(),G=(_,Y)=>{Y=Q(Y);for(let X of _.keys()){let oe=Q(X);(oe===Y||oe.indexOf(Y+"/")===0)&&_.delete(X)}},ie=_=>{for(let Y of _.keys())_.delete(Y)},ce=class extends i{constructor(_){if(_||(_={}),_.ondone=Y=>{this[C]=!0,this[k]()},super(_),this[m]=!1,this.reservations=l(),this.transform=typeof _.transform=="function"?_.transform:null,this.writable=!0,this.readable=!1,this[V]=0,this[C]=!1,this.dirCache=_.dirCache||new Map,typeof _.uid=="number"||typeof _.gid=="number"){if(typeof _.uid!="number"||typeof _.gid!="number")throw new TypeError("cannot set owner without number uid and gid");if(_.preserveOwner)throw new TypeError("cannot preserve owner in archive and also set owner explicitly");this.uid=_.uid,this.gid=_.gid,this.setOwner=!0}else this.uid=null,this.gid=null,this.setOwner=!1;_.preserveOwner===void 0&&typeof _.uid!="number"?this.preserveOwner=process.getuid&&process.getuid()===0:this.preserveOwner=!!_.preserveOwner,this.processUid=(this.preserveOwner||this.setOwner)&&process.getuid?process.getuid():null,this.processGid=(this.preserveOwner||this.setOwner)&&process.getgid?process.getgid():null,this.forceChown=_.forceChown===!0,this.win32=!!_.win32||I,this.newer=!!_.newer,this.keep=!!_.keep,this.noMtime=!!_.noMtime,this.preservePaths=!!_.preservePaths,this.unlink=!!_.unlink,this.cwd=f(o.resolve(_.cwd||process.cwd())),this.strip=+_.strip||0,this.processUmask=_.noChmod?0:process.umask(),this.umask=typeof _.umask=="number"?_.umask:this.processUmask,this.dmode=_.dmode||511&~this.umask,this.fmode=_.fmode||438&~this.umask,this.on("entry",Y=>this[g](Y))}warn(_,Y,X={}){return(_==="TAR_BAD_ARCHIVE"||_==="TAR_ABORT")&&(X.recoverable=!1),super.warn(_,Y,X)}[k](){this[C]&&this[V]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"))}[H](_){if(this.strip){let Y=f(_.path).split("/");if(Y.length<this.strip)return!1;if(_.path=Y.slice(this.strip).join("/"),_.type==="Link"){let X=f(_.linkpath).split("/");if(X.length>=this.strip)_.linkpath=X.slice(this.strip).join("/");else return!1}}if(!this.preservePaths){let Y=f(_.path),X=Y.split("/");if(X.includes("..")||I&&/^[a-z]:\.\.$/i.test(X[0]))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:_,path:Y}),!1;let[oe,le]=c(Y);oe&&(_.path=le,this.warn("TAR_ENTRY_INFO",`stripping ${oe} from absolute path`,{entry:_,path:Y}))}if(o.isAbsolute(_.path)?_.absolute=f(o.resolve(_.path)):_.absolute=f(o.resolve(this.cwd,_.path)),!this.preservePaths&&_.absolute.indexOf(this.cwd+"/")!==0&&_.absolute!==this.cwd)return this.warn("TAR_ENTRY_ERROR","path escaped extraction target",{entry:_,path:f(_.path),resolvedPath:_.absolute,cwd:this.cwd}),!1;if(_.absolute===this.cwd&&_.type!=="Directory"&&_.type!=="GNUDumpDir")return!1;if(this.win32){let{root:Y}=o.win32.parse(_.absolute);_.absolute=Y+u.encode(_.absolute.slice(Y.length));let{root:X}=o.win32.parse(_.path);_.path=X+u.encode(_.path.slice(X.length))}return!0}[g](_){if(!this[H](_))return _.resume();switch(r.equal(typeof _.absolute,"string"),_.type){case"Directory":case"GNUDumpDir":_.mode&&(_.mode=_.mode|448);case"File":case"OldFile":case"ContiguousFile":case"Link":case"SymbolicLink":return this[y](_);case"CharacterDevice":case"BlockDevice":case"FIFO":default:return this[N](_)}}[U](_,Y){_.name==="CwdError"?this.emit("error",_):(this.warn("TAR_ENTRY_ERROR",_,{entry:Y}),this[B](),Y.resume())}[T](_,Y,X){a(f(_),{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:Y,noChmod:this.noChmod},X)}[z](_){return this.forceChown||this.preserveOwner&&(typeof _.uid=="number"&&_.uid!==this.processUid||typeof _.gid=="number"&&_.gid!==this.processGid)||typeof this.uid=="number"&&this.uid!==this.processUid||typeof this.gid=="number"&&this.gid!==this.processGid}[P](_){return q(this.uid,_.uid,this.processUid)}[d](_){return q(this.gid,_.gid,this.processGid)}[R](_,Y){let X=_.mode&4095||this.fmode,oe=new s.WriteStream(_.absolute,{flags:A(_.size),mode:X,autoClose:!1});oe.on("error",pe=>{oe.fd&&n.close(oe.fd,()=>{}),oe.write=()=>!0,this[U](pe,_),Y()});let le=1,Ee=pe=>{if(pe){oe.fd&&n.close(oe.fd,()=>{}),this[U](pe,_),Y();return}--le===0&&n.close(oe.fd,Ae=>{Ae?this[U](Ae,_):this[B](),Y()})};oe.on("finish",pe=>{let Ae=_.absolute,ht=oe.fd;if(_.mtime&&!this.noMtime){le++;let ft=_.atime||new Date,un=_.mtime;n.futimes(ht,ft,un,ln=>ln?n.utimes(Ae,ft,un,ba=>Ee(ba&&ln)):Ee())}if(this[z](_)){le++;let ft=this[P](_),un=this[d](_);n.fchown(ht,ft,un,ln=>ln?n.chown(Ae,ft,un,ba=>Ee(ba&&ln)):Ee())}Ee()});let he=this.transform&&this.transform(_)||_;he!==_&&(he.on("error",pe=>{this[U](pe,_),Y()}),_.pipe(he)),he.pipe(oe)}[x](_,Y){let X=_.mode&4095||this.dmode;this[T](_.absolute,X,oe=>{if(oe){this[U](oe,_),Y();return}let le=1,Ee=he=>{--le===0&&(Y(),this[B](),_.resume())};_.mtime&&!this.noMtime&&(le++,n.utimes(_.absolute,_.atime||new Date,_.mtime,Ee)),this[z](_)&&(le++,n.chown(_.absolute,this[P](_),this[d](_),Ee)),Ee()})}[N](_){_.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${_.type}`,{entry:_}),_.resume()}[b](_,Y){this[L](_,_.linkpath,"symlink",Y)}[S](_,Y){let X=f(o.resolve(this.cwd,_.linkpath));this[L](_,X,"link",Y)}[K](){this[V]++}[B](){this[V]--,this[k]()}[j](_){this[B](),_.resume()}[F](_,Y){return _.type==="File"&&!this.unlink&&Y.isFile()&&Y.nlink<=1&&!I}[y](_){this[K]();let Y=[_.path];_.linkpath&&Y.push(_.linkpath),this.reservations.reserve(Y,X=>this[E](_,X))}[v](_){_.type==="SymbolicLink"?ie(this.dirCache):_.type!=="Directory"&&G(this.dirCache,_.absolute)}[E](_,Y){this[v](_);let X=he=>{this[v](_),Y(he)},oe=()=>{this[T](this.cwd,this.dmode,he=>{if(he){this[U](he,_),X();return}this[m]=!0,le()})},le=()=>{if(_.absolute!==this.cwd){let he=f(o.dirname(_.absolute));if(he!==this.cwd)return this[T](he,this.dmode,pe=>{if(pe){this[U](pe,_),X();return}Ee()})}Ee()},Ee=()=>{n.lstat(_.absolute,(he,pe)=>{if(pe&&(this.keep||this.newer&&pe.mtime>_.mtime)){this[j](_),X();return}if(he||this[F](_,pe))return this[O](null,_,X);if(pe.isDirectory()){if(_.type==="Directory"){let Ae=!this.noChmod&&_.mode&&(pe.mode&4095)!==_.mode,ht=ft=>this[O](ft,_,X);return Ae?n.chmod(_.absolute,_.mode,ht):ht()}if(_.absolute!==this.cwd)return n.rmdir(_.absolute,Ae=>this[O](Ae,_,X))}if(_.absolute===this.cwd)return this[O](null,_,X);M(_.absolute,Ae=>this[O](Ae,_,X))})};this[m]?le():oe()}[O](_,Y,X){if(_){this[U](_,Y),X();return}switch(Y.type){case"File":case"OldFile":case"ContiguousFile":return this[R](Y,X);case"Link":return this[S](Y,X);case"SymbolicLink":return this[b](Y,X);case"Directory":case"GNUDumpDir":return this[x](Y,X)}}[L](_,Y,X,oe){n[X](Y,_.absolute,le=>{le?this[U](le,_):(this[B](),_.resume()),oe()})}},we=_=>{try{return[null,_()]}catch(Y){return[Y,null]}},De=class extends ce{[O](_,Y){return super[O](_,Y,()=>{})}[y](_){if(this[v](_),!this[m]){let le=this[T](this.cwd,this.dmode);if(le)return this[U](le,_);this[m]=!0}if(_.absolute!==this.cwd){let le=f(o.dirname(_.absolute));if(le!==this.cwd){let Ee=this[T](le,this.dmode);if(Ee)return this[U](Ee,_)}}let[Y,X]=we(()=>n.lstatSync(_.absolute));if(X&&(this.keep||this.newer&&X.mtime>_.mtime))return this[j](_);if(Y||this[F](_,X))return this[O](null,_);if(X.isDirectory()){if(_.type==="Directory"){let Ee=!this.noChmod&&_.mode&&(X.mode&4095)!==_.mode,[he]=Ee?we(()=>{n.chmodSync(_.absolute,_.mode)}):[];return this[O](he,_)}let[le]=we(()=>n.rmdirSync(_.absolute));this[O](le,_)}let[oe]=_.absolute===this.cwd?[]:we(()=>Z(_.absolute));this[O](oe,_)}[R](_,Y){let X=_.mode&4095||this.fmode,oe=he=>{let pe;try{n.closeSync(le)}catch(Ae){pe=Ae}(he||pe)&&this[U](he||pe,_),Y()},le;try{le=n.openSync(_.absolute,A(_.size),X)}catch(he){return oe(he)}let Ee=this.transform&&this.transform(_)||_;Ee!==_&&(Ee.on("error",he=>this[U](he,_)),_.pipe(Ee)),Ee.on("data",he=>{try{n.writeSync(le,he,0,he.length)}catch(pe){oe(pe)}}),Ee.on("end",he=>{let pe=null;if(_.mtime&&!this.noMtime){let Ae=_.atime||new Date,ht=_.mtime;try{n.futimesSync(le,Ae,ht)}catch(ft){try{n.utimesSync(_.absolute,Ae,ht)}catch{pe=ft}}}if(this[z](_)){let Ae=this[P](_),ht=this[d](_);try{n.fchownSync(le,Ae,ht)}catch(ft){try{n.chownSync(_.absolute,Ae,ht)}catch{pe=pe||ft}}}oe(pe)})}[x](_,Y){let X=_.mode&4095||this.dmode,oe=this[T](_.absolute,X);if(oe){this[U](oe,_),Y();return}if(_.mtime&&!this.noMtime)try{n.utimesSync(_.absolute,_.atime||new Date,_.mtime)}catch{}if(this[z](_))try{n.chownSync(_.absolute,this[P](_),this[d](_))}catch{}Y(),_.resume()}[T](_,Y){try{return a.sync(f(_),{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:Y})}catch(X){return X}}[L](_,Y,X,oe){try{n[X+"Sync"](Y,_.absolute),oe(),_.resume()}catch(le){return this[U](le,_)}}};ce.Sync=De,e.exports=ce}),yT=te((t,e)=>{"use strict";W();var r=Kn(),i=ab(),n=re("fs"),s=Qn(),o=re("path"),a=Xn();e.exports=(p,g,y)=>{typeof p=="function"?(y=p,g=null,p={}):Array.isArray(p)&&(g=p,p={}),typeof g=="function"&&(y=g,g=null),g?g=Array.from(g):g=[];let E=r(p);if(E.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!E.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return g.length&&u(E,g),E.file&&E.sync?l(E):E.file?c(E,y):E.sync?f(E):h(E)};var u=(p,g)=>{let y=new Map(g.map(F=>[a(F),!0])),E=p.filter,v=(F,O)=>{let R=O||o.parse(F).root||".",x=F===R?!1:y.has(F)?y.get(F):v(o.dirname(F),R);return y.set(F,x),x};p.filter=E?(F,O)=>E(F,O)&&v(a(F)):F=>v(a(F))},l=p=>{let g=new i.Sync(p),y=p.file,E=n.statSync(y),v=p.maxReadSize||16*1024*1024;new s.ReadStreamSync(y,{readSize:v,size:E.size}).pipe(g)},c=(p,g)=>{let y=new i(p),E=p.maxReadSize||16*1024*1024,v=p.file,F=new Promise((O,R)=>{y.on("error",R),y.on("close",O),n.stat(v,(x,L)=>{if(x)R(x);else{let b=new s.ReadStream(v,{readSize:E,size:L.size});b.on("error",R),b.pipe(y)}})});return g?F.then(g,g):F},f=p=>new i.Sync(p),h=p=>new i(p)}),ET=te(t=>{"use strict";W(),t.c=t.create=sT(),t.r=t.replace=nb(),t.t=t.list=Hh(),t.u=t.update=oT(),t.x=t.extract=yT(),t.Pack=jh(),t.Unpack=ab(),t.Parse=$h(),t.ReadEntry=Ih(),t.WriteEntry=rb(),t.Header=Jn(),t.Pax=Nh(),t.types=QD()}),DT=te((t,e)=>{W();function r(i,n){typeof n=="boolean"&&(n={forever:n}),this._originalTimeouts=JSON.parse(JSON.stringify(i)),this._timeouts=i,this._options=n||{},this._maxRetryTime=n&&n.maxRetryTime||1/0,this._fn=null,this._errors=[],this._attempts=1,this._operationTimeout=null,this._operationTimeoutCb=null,this._timeout=null,this._operationStart=null,this._timer=null,this._options.forever&&(this._cachedTimeouts=this._timeouts.slice(0))}e.exports=r,r.prototype.reset=function(){this._attempts=1,this._timeouts=this._originalTimeouts.slice(0)},r.prototype.stop=function(){this._timeout&&clearTimeout(this._timeout),this._timer&&clearTimeout(this._timer),this._timeouts=[],this._cachedTimeouts=null},r.prototype.retry=function(i){if(this._timeout&&clearTimeout(this._timeout),!i)return!1;var n=new Date().getTime();if(i&&n-this._operationStart>=this._maxRetryTime)return this._errors.push(i),this._errors.unshift(new Error("RetryOperation timeout occurred")),!1;this._errors.push(i);var s=this._timeouts.shift();if(s===void 0)if(this._cachedTimeouts)this._errors.splice(0,this._errors.length-1),s=this._cachedTimeouts.slice(-1);else return!1;var o=this;return this._timer=setTimeout(function(){o._attempts++,o._operationTimeoutCb&&(o._timeout=setTimeout(function(){o._operationTimeoutCb(o._attempts)},o._operationTimeout),o._options.unref&&o._timeout.unref()),o._fn(o._attempts)},s),this._options.unref&&this._timer.unref(),!0},r.prototype.attempt=function(i,n){this._fn=i,n&&(n.timeout&&(this._operationTimeout=n.timeout),n.cb&&(this._operationTimeoutCb=n.cb));var s=this;this._operationTimeoutCb&&(this._timeout=setTimeout(function(){s._operationTimeoutCb()},s._operationTimeout)),this._operationStart=new Date().getTime(),this._fn(this._attempts)},r.prototype.try=function(i){console.log("Using RetryOperation.try() is deprecated"),this.attempt(i)},r.prototype.start=function(i){console.log("Using RetryOperation.start() is deprecated"),this.attempt(i)},r.prototype.start=r.prototype.try,r.prototype.errors=function(){return this._errors},r.prototype.attempts=function(){return this._attempts},r.prototype.mainError=function(){if(this._errors.length===0)return null;for(var i={},n=null,s=0,o=0;o<this._errors.length;o++){var a=this._errors[o],u=a.message,l=(i[u]||0)+1;i[u]=l,l>=s&&(n=a,s=l)}return n}}),bT=te(t=>{W();var e=DT();t.operation=function(r){var i=t.timeouts(r);return new e(i,{forever:r&&(r.forever||r.retries===1/0),unref:r&&r.unref,maxRetryTime:r&&r.maxRetryTime})},t.timeouts=function(r){if(r instanceof Array)return[].concat(r);var i={retries:10,factor:2,minTimeout:1*1e3,maxTimeout:1/0,randomize:!1};for(var n in r)i[n]=r[n];if(i.minTimeout>i.maxTimeout)throw new Error("minTimeout is greater than maxTimeout");for(var s=[],o=0;o<i.retries;o++)s.push(this.createTimeout(o,i));return r&&r.forever&&!s.length&&s.push(this.createTimeout(o,i)),s.sort(function(a,u){return a-u}),s},t.createTimeout=function(r,i){var n=i.randomize?Math.random()+1:1,s=Math.round(n*Math.max(i.minTimeout,1)*Math.pow(i.factor,r));return s=Math.min(s,i.maxTimeout),s},t.wrap=function(r,i,n){if(i instanceof Array&&(n=i,i=null),!n){n=[];for(var s in r)typeof r[s]=="function"&&n.push(s)}for(var o=0;o<n.length;o++){var a=n[o],u=r[a];r[a]=function(l){var c=t.operation(i),f=Array.prototype.slice.call(arguments,1),h=f.pop();f.push(function(p){c.retry(p)||(p&&(arguments[0]=c.mainError()),h.apply(this,arguments))}),c.attempt(function(){l.apply(r,f)})}.bind(r,u),r[a].options=i}}}),_T=te((t,e)=>{W(),e.exports=bT()}),wT=te((t,e)=>{W();var r=_T();function i(n,s){function o(a,u){var l=s||{},c;"randomize"in l||(l.randomize=!0),c=r.operation(l);function f(g){u(g||new Error("Aborted"))}function h(g,y){if(g.bail){f(g);return}c.retry(g)?l.onRetry&&l.onRetry(g,y):u(c.mainError())}function p(g){var y;try{y=n(f,g)}catch(E){h(E,g);return}Promise.resolve(y).then(a).catch(function(E){h(E,g)})}c.attempt(p)}return new Promise(o)}e.exports=i}),ST={};Gk(ST,{bold:()=>RT,dimmed:()=>OT,error:()=>BT,grey:()=>kT,info:()=>xT,item:()=>TT,log:()=>si,turboBlue:()=>tn,turboGradient:()=>vT,turboLoader:()=>CT,turboRed:()=>fb,underline:()=>FT,warn:()=>LT,yellow:()=>pb});W();var cb="#0099F7",hb="#F11712",AT="#FFFF00",vT=(0,lb.default)(cb,hb),tn=Or.default.hex(cb),fb=Or.default.hex(hb),pb=Or.default.hex(AT),CT=t=>(0,ub.default)({text:t,spinner:{frames:[" ",tn("> "),tn(">> "),tn(">>>")]}}),xT=(...t)=>{si(tn.bold(">>>"),...t)},RT=(...t)=>{si(Or.default.bold(...t))},FT=(...t)=>{si(Or.default.underline(...t))},OT=(...t)=>{si(Or.default.dim(...t))},kT=(...t)=>{si(Or.default.grey(...t))},TT=(...t)=>{si(tn.bold(" \u2022"),...t)},si=(...t)=>{console.log(...t)},LT=(...t)=>{console.error(pb.bold(">>>"),...t)},BT=(...t)=>{console.error(fb.bold(">>>"),...t)};W();W();W();W();var eN=oa(Vk());W();W();function IT(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}W();W();function Th(t){return Th=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Th(t)}W();function NT(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function MT(t,e){if(e&&(Th(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return NT(t)}W();function sa(t){return sa=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},sa(t)}W();W();function Wn(t,e){return Wn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Wn(t,e)}function jT(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Wn(t,e)}W();W();function $T(t){return Function.toString.call(t).indexOf("[native code]")!==-1}W();W();function HT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function na(t,e,r){return HT()?na=Reflect.construct.bind():na=function(i,n,s){var o=[null];o.push.apply(o,n);var a=Function.bind.apply(i,o),u=new a;return s&&Wn(u,s.prototype),u},na.apply(null,arguments)}function Lh(t){var e=typeof Map=="function"?new Map:void 0;return Lh=function(r){if(r===null||!$T(r))return r;if(typeof r!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e<"u"){if(e.has(r))return e.get(r);e.set(r,i)}function i(){return na(r,arguments,sa(this).constructor)}return i.prototype=Object.create(r.prototype,{constructor:{value:i,enumerable:!1,writable:!0,configurable:!0}}),Wn(i,r)},Lh(t)}var tN=oa(eT()),nN=function(t){jT(e,t);function e(r){var i;return IT(this,e),i=MT(this,sa(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),i.directory=r,i}return e}(Lh(Error));W();W();W();W();W();W();var mN=oa(ET()),gN=(0,mb.promisify)(db.Stream.pipeline);W();W();var bN=oa(wT());W();W();W();var je=class extends Error{constructor(t,e){var r;super(t),this.name="ConvertError",this.type=(r=e==null?void 0:e.type)!=null?r:"unknown",Error.captureStackTrace(this,je)}};W();W();W();W();var qT=/^(?!_)(?<manager>.+)@(?<version>.+)$/;function Ke({workspaceRoot:t}){let e=rr.default.join(t,"package.json");try{return(0,rt.readJsonSync)(e,"utf8")}catch(r){if(r&&typeof r=="object"&&"code"in r){if(r.code==="ENOENT")throw new je(`no "package.json" found at ${t}`,{type:"package_json-missing"});if(r.code==="EJSONPARSE")throw new je(`failed to parse "package.json" at ${t}`,{type:"package_json-parse_error"})}throw new Error(`unexpected error reading "package.json" at ${t}`)}}function aa({workspaceRoot:t}){let{packageManager:e}=Ke({workspaceRoot:t});if(e)try{let r=qT.exec(e);if(r){let[i,n]=r;return n}}catch{}}function es({workspaceRoot:t}){let e=Ke({workspaceRoot:t}),r=rr.default.basename(t),{name:i=r,description:n}=e;return{name:i,description:n}}function VD({workspaceRoot:t}){let e=rr.default.join(t,"pnpm-workspace.yaml");if((0,rt.existsSync)(e))try{let r=Ua.load((0,rt.readFileSync)(e,"utf8"));if(r instanceof Object&&"packages"in r&&Array.isArray(r.packages))return r.packages}catch{throw new je(`failed to parse ${e}`,{type:"pnpm-workspace_parse_error"})}return[]}function ua({root:t,lockFile:e,workspaceConfig:r}){let i=s=>rr.default.join(t,s),n={root:t,lockfile:i(e),packageJson:i("package.json"),nodeModules:i("node_modules")};return r&&(n.workspaceConfig=i(r)),n}function qh({workspaces:t}){var e;return t?Array.isArray(t)?t:"packages"in t?(e=t.packages)!=null?e:[]:[]:[]}function la({workspaceRoot:t,workspaceGlobs:e}){return e?e.flatMap(r=>{let i=[`${r}/package.json`];return(0,_b.sync)(i,{onlyFiles:!0,absolute:!0,cwd:t,ignore:["**/node_modules/**"]})}).map(r=>{let i=rr.default.dirname(r),{name:n,description:s}=es({workspaceRoot:i});return{name:n,description:s,paths:{root:i,packageJson:r,nodeModules:rr.default.join(i,"node_modules")}}}):[]}function UT({directory:t}){let e=rr.default.resolve(process.cwd(),t);return{exists:(0,rt.existsSync)(e),absolute:e}}function kr({packageManager:t,action:e,project:r}){let i=r.workspaceData.globs.length>0;return`${e==="remove"?"Removing":"Adding"} ${t} ${i?"workspaces":""} ${e==="remove"?"from":"to"} ${r.name}`}function GT({project:t}){let e=r=>!(r.includes("*")&&(r.includes("**")||r.split("/").slice(0,-1).join("/").includes("*"))||["!","[","]","{","}"].some(i=>r.includes(i)));return t.workspaceData.globs.every(e)}function tr({project:t,options:e}){e!=null&&e.dry||(0,rt.rmSync)(t.paths.lockfile,{force:!0})}async function wb({project:t,options:e}){if(!(e!=null&&e.dry)&&(0,rt.existsSync)(t.paths.lockfile))try{let{stdout:r}=await(0,bb.default)("bun",["bun.lockb"],{stdin:"ignore",cwd:t.paths.root});await(0,rt.writeFile)(rr.default.join(t.paths.root,"yarn.lock"),r)}catch{}finally{(0,rt.rmSync)(t.paths.lockfile,{force:!0})}}function zT({dependencyList:t,project:e,to:r}){let i=[];return e.workspaceData.workspaces.forEach(n=>{let{name:s}=n;if(t[s]){let o=t[s],a=o.startsWith("workspace:")?o.slice(10):o;t[s]=r.name==="pnpm"?`workspace:${a}`:a,i.push(s)}}),{dependencyList:t,updated:i}}function Rr({project:t,workspace:e,to:r,logger:i,options:n}){if(["yarn","npm","bun"].includes(r.name)&&["yarn","npm","bun"].includes(t.packageManager))return;let s=Ke({workspaceRoot:e.paths.root}),o={dependencies:[],devDependencies:[],peerDependencies:[],optionalDependencies:[]},a=["dependencies","devDependencies","peerDependencies","optionalDependencies"];a.forEach(f=>{let h=s[f];if(h){let{updated:p,dependencyList:g}=zT({dependencyList:h,project:t,to:r});s[f]=g,o[f]=p}});let u=f=>{let h=o[f].length;if(h>0)return`${Db.default.green(h.toString())} ${f}`},l=a.map(u).filter(Boolean),c=`./${yb.default.relative(t.paths.root,e.paths.packageJson)}`;if(l.length>=1){let f="updating";l.forEach((h,p)=>{l.length===1?f+=` ${h} in ${c}`:p===l.length-1?f+=`and ${h} in ${c}`:f+=` ${h}, `}),i.workspaceStep(f)}else i.workspaceStep(`no workspace dependencies found in ${c}`);n!=null&&n.dry||(0,Eb.writeJSONSync)(e.paths.packageJson,s,{spaces:2})}var Fr={name:"pnpm",lock:"pnpm-lock.yaml"};async function Sb(t){let e=ii.default.join(t.workspaceRoot,Fr.lock),r=ii.default.join(t.workspaceRoot,"pnpm-workspace.yaml"),i=aa({workspaceRoot:t.workspaceRoot});return(0,qe.existsSync)(e)||(0,qe.existsSync)(r)||i===Fr.name}async function WT(t){if(!await Sb(t))throw new je("Not a pnpm project",{type:"package_manager-unexpected"});let{name:e,description:r}=es(t);return{name:e,description:r,packageManager:Fr.name,paths:ua({root:t.workspaceRoot,lockFile:Fr.lock,workspaceConfig:"pnpm-workspace.yaml"}),workspaceData:{globs:VD(t),workspaces:la({workspaceGlobs:VD(t),...t})}}}async function YT(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;i.mainStep(kr({action:"create",packageManager:Fr.name,project:e}));let o=Ke({workspaceRoot:e.paths.root});i.rootHeader(),o.packageManager=`${r.name}@${r.version}`,i.rootStep(`adding "packageManager" field to ${e.name} root "package.json"`),n!=null&&n.dry||((0,qe.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),s&&(i.rootStep('adding "pnpm-workspace.yaml"'),(0,qe.writeFileSync)(ii.default.join(e.paths.root,"pnpm-workspace.yaml"),`packages:
43
43
  ${e.workspaceData.globs.map(a=>` - "${a}"`).join(`
44
- `)}`))),s&&(xr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{xr({workspace:a,project:e,to:r,logger:i,options:n})}))}async function VT(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Or({action:"remove",packageManager:Rr.name,project:e}));let s=Ke({workspaceRoot:e.paths.root});if(e.paths.workspaceConfig&&n&&(r.subStep('removing "pnpm-workspace.yaml"'),i!=null&&i.dry||(0,qe.rmSync)(e.paths.workspaceConfig,{force:!0})),r.subStep(`removing "packageManager" field in ${e.name} root "package.json"`),delete s.packageManager,!(i!=null&&i.dry)){(0,qe.writeJSONSync)(e.paths.packageJson,s,{spaces:2});let o=[e.paths.nodeModules,...e.workspaceData.workspaces.map(a=>a.paths.nodeModules)];try{r.subStep('removing "node_modules"'),await Promise.all(o.map(a=>(0,qe.rm)(a,{recursive:!0,force:!0})))}catch{throw new je("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function KT(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${ri.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,qe.rmSync)(e.paths.lockfile,{force:!0})}async function ZT(t){let{project:e,options:r,logger:i}=t,n=()=>{i.subStep(`converting ${ri.default.relative(e.paths.root,e.paths.lockfile)} to ${Rr.lock}`)},s=async()=>{if(!(r!=null&&r.dry)&&(0,qe.existsSync)(e.paths.lockfile))try{await(0,gb.default)(Rr.name,["import"],{stdio:"ignore",cwd:e.paths.root})}catch{}finally{tr({project:e,options:r})}};switch(e.packageManager){case"pnpm":break;case"bun":n(),await wb({project:e,options:r}),await s(),(0,qe.rmSync)(ri.default.join(e.paths.root,"yarn.lock"),{force:!0});break;case"npm":n(),await s();break;case"yarn":n(),await s();break}}var JT={detect:Sb,read:WT,create:YT,remove:VT,clean:KT,convertLock:ZT};W();var rn={name:"npm",lock:"package-lock.json"};async function Ab(t){let e=Yn.default.join(t.workspaceRoot,rn.lock),r=aa({workspaceRoot:t.workspaceRoot});return(0,Tt.existsSync)(e)||r===rn.name}async function XT(t){if(!await Ab(t))throw new je("Not an npm project",{type:"package_manager-unexpected"});let e=Ke(t),{name:r,description:i}=es(t),n=qh({workspaces:e.workspaces});return{name:r,description:i,packageManager:rn.name,paths:ua({root:t.workspaceRoot,lockFile:rn.lock}),workspaceData:{globs:n,workspaces:la({workspaceGlobs:n,...t})}}}async function QT(t){let{project:e,options:r,to:i,logger:n}=t,s=e.workspaceData.globs.length>0;n.mainStep(Or({packageManager:rn.name,action:"create",project:e}));let o=Ke({workspaceRoot:e.paths.root});n.rootHeader(),n.rootStep(`adding "packageManager" field to ${Yn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${i.name}@${i.version}`,s?(n.rootStep(`adding "workspaces" field to ${Yn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,r!=null&&r.dry||(0,Tt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),xr({workspace:{name:"root",paths:e.paths},project:e,to:i,logger:n,options:r}),n.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{xr({workspace:a,project:e,to:i,logger:n,options:r})})):r!=null&&r.dry||(0,Tt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function eL(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Or({packageManager:rn.name,action:"remove",project:e}));let s=Ke({workspaceRoot:e.paths.root});if(n&&(r.subStep(`removing "workspaces" field in ${e.name} root "package.json"`),delete s.workspaces),r.subStep(`removing "packageManager" field in ${e.name} root "package.json"`),delete s.packageManager,!(i!=null&&i.dry)){(0,Tt.writeJSONSync)(e.paths.packageJson,s,{spaces:2});let o=[e.paths.nodeModules,...e.workspaceData.workspaces.map(a=>a.paths.nodeModules)];try{r.subStep('removing "node_modules"'),await Promise.all(o.map(a=>(0,Tt.rm)(a,{recursive:!0,force:!0})))}catch{throw new je("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function tL(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${Yn.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,Tt.rmSync)(e.paths.lockfile,{force:!0})}async function rL(t){let{project:e,options:r}=t;switch(e.packageManager){case"pnpm":tr({project:e,options:r});break;case"bun":tr({project:e,options:r});break;case"npm":break;case"yarn":tr({project:e,options:r});break}}var iL={detect:Ab,read:XT,create:QT,remove:eL,clean:tL,convertLock:rL};W();var ii={name:"yarn",lock:"yarn.lock"};async function vb(t){let e=nn.default.join(t.workspaceRoot,ii.lock),r=aa({workspaceRoot:t.workspaceRoot});return(0,Lt.existsSync)(e)||r===ii.name}async function nL(t){if(!await vb(t))throw new je("Not a yarn project",{type:"package_manager-unexpected"});let e=Ke(t),{name:r,description:i}=es(t),n=qh({workspaces:e.workspaces});return{name:r,description:i,packageManager:ii.name,paths:ua({root:t.workspaceRoot,lockFile:ii.lock}),workspaceData:{globs:n,workspaces:la({workspaceGlobs:n,...t})}}}async function sL(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;i.mainStep(Or({packageManager:ii.name,action:"create",project:e}));let o=Ke({workspaceRoot:e.paths.root});i.rootHeader(),i.rootStep(`adding "packageManager" field to ${nn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${r.name}@${r.version}`,s?(i.rootStep(`adding "workspaces" field to ${nn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,n!=null&&n.dry||(0,Lt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),xr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{xr({workspace:a,project:e,to:r,logger:i,options:n})})):n!=null&&n.dry||(0,Lt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function oL(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Or({packageManager:ii.name,action:"remove",project:e}));let s=Ke({workspaceRoot:e.paths.root});if(n&&(r.subStep(`removing "workspaces" field in ${e.name} root "package.json"`),delete s.workspaces),r.subStep(`removing "packageManager" field in ${e.name} root "package.json"`),delete s.packageManager,!(i!=null&&i.dry)){(0,Lt.writeJSONSync)(e.paths.packageJson,s,{spaces:2});let o=[e.paths.nodeModules,...e.workspaceData.workspaces.map(a=>a.paths.nodeModules)];try{r.subStep('removing "node_modules"'),await Promise.all(o.map(a=>(0,Lt.rm)(a,{recursive:!0,force:!0})))}catch{throw new je("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function aL(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${nn.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,Lt.rmSync)(e.paths.lockfile,{force:!0})}async function uL(t){let{project:e,options:r,logger:i}=t,n=()=>{i.subStep(`converting ${nn.default.relative(e.paths.root,e.paths.lockfile)} to ${ii.lock}`)};switch(e.packageManager){case"pnpm":tr({project:e,options:r});break;case"bun":n(),await wb({project:e,options:r});break;case"npm":tr({project:e,options:r});break;case"yarn":break}}var lL={detect:vb,read:nL,create:sL,remove:oL,clean:aL,convertLock:uL};W();var sn={name:"bun",lock:"bun.lockb"};async function Cb(t){let e=Vn.default.join(t.workspaceRoot,sn.lock),r=aa({workspaceRoot:t.workspaceRoot});return(0,Bt.existsSync)(e)||r===sn.name}async function cL(t){if(!await Cb(t))throw new je("Not a bun project",{type:"package_manager-unexpected"});let e=Ke(t),{name:r,description:i}=es(t),n=qh({workspaces:e.workspaces});return{name:r,description:i,packageManager:sn.name,paths:ua({root:t.workspaceRoot,lockFile:sn.lock}),workspaceData:{globs:n,workspaces:la({workspaceGlobs:n,...t})}}}async function hL(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;if(!GT({project:e}))throw new je("Unable to convert project to bun - workspace globs unsupported",{type:"bun-workspace_glob_error"});i.mainStep(Or({packageManager:sn.name,action:"create",project:e}));let o=Ke({workspaceRoot:e.paths.root});i.rootHeader(),i.rootStep(`adding "packageManager" field to ${Vn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${r.name}@${r.version}`,s?(i.rootStep(`adding "workspaces" field to ${Vn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,n!=null&&n.dry||(0,Bt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),xr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{xr({workspace:a,project:e,to:r,logger:i,options:n})})):n!=null&&n.dry||(0,Bt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function fL(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Or({packageManager:sn.name,action:"remove",project:e}));let s=Ke({workspaceRoot:e.paths.root});if(n&&(r.subStep(`removing "workspaces" field in ${e.name} root "package.json"`),delete s.workspaces),r.subStep(`removing "packageManager" field in ${e.name} root "package.json"`),delete s.packageManager,!(i!=null&&i.dry)){(0,Bt.writeJSONSync)(e.paths.packageJson,s,{spaces:2});let o=[e.paths.nodeModules,...e.workspaceData.workspaces.map(a=>a.paths.nodeModules)];try{r.subStep('removing "node_modules"'),await Promise.all(o.map(a=>(0,Bt.rm)(a,{recursive:!0,force:!0})))}catch{throw new je("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function pL(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${Vn.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,Bt.rmSync)(e.paths.lockfile,{force:!0})}async function dL(t){let{project:e,options:r}=t;switch(e.packageManager){case"pnpm":tr({project:e,options:r});break;case"bun":break;case"npm":tr({project:e,options:r});break;case"yarn":tr({project:e,options:r});break}}var mL={detect:Cb,read:cL,create:hL,remove:fL,clean:pL,convertLock:dL},xb={pnpm:JT,yarn:lL,npm:iL,bun:mL};W();async function ts({root:t}){let{exists:e,absolute:r}=UT({directory:t});if(!e)throw new je(`Could not find directory at ${r}. Ensure the directory exists.`,{type:"invalid_directory"});for(let{detect:i,read:n}of Object.values(xb))if(await i({workspaceRoot:r}))return n({workspaceRoot:r});throw new je("Could not determine package manager. Add `packageManager` to `package.json` or ensure a lockfile is present.",{type:"package_manager-unable_to_detect"})}W();W();W();W();var Uh=J(require("chalk")),Rb=J(require("is-git-clean"));function ca({directory:t,force:e}){var n;let r=!1,i="Unable to determine if git directory is clean";try{r=Rb.default.sync(t||process.cwd()),i="Git directory is not clean"}catch(s){(n=s.stderr)!=null&&n.includes("not a git repository")&&(r=!0)}r||(e?ne.log(`${Uh.default.yellow("WARNING")}: ${i}. Forcibly continuing...`):(ne.log("Thank you for using @turbo/codemod!"),ne.log(Uh.default.yellow(`
44
+ `)}`))),s&&(Rr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Rr({workspace:a,project:e,to:r,logger:i,options:n})}))}async function VT(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(kr({action:"remove",packageManager:Fr.name,project:e}));let s=Ke({workspaceRoot:e.paths.root});if(e.paths.workspaceConfig&&n&&(r.subStep('removing "pnpm-workspace.yaml"'),i!=null&&i.dry||(0,qe.rmSync)(e.paths.workspaceConfig,{force:!0})),r.subStep(`removing "packageManager" field in ${e.name} root "package.json"`),delete s.packageManager,!(i!=null&&i.dry)){(0,qe.writeJSONSync)(e.paths.packageJson,s,{spaces:2});let o=[e.paths.nodeModules,...e.workspaceData.workspaces.map(a=>a.paths.nodeModules)];try{r.subStep('removing "node_modules"'),await Promise.all(o.map(a=>(0,qe.rm)(a,{recursive:!0,force:!0})))}catch{throw new je("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function KT(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${ii.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,qe.rmSync)(e.paths.lockfile,{force:!0})}async function ZT(t){let{project:e,options:r,logger:i}=t,n=()=>{i.subStep(`converting ${ii.default.relative(e.paths.root,e.paths.lockfile)} to ${Fr.lock}`)},s=async()=>{if(!(r!=null&&r.dry)&&(0,qe.existsSync)(e.paths.lockfile))try{await(0,gb.default)(Fr.name,["import"],{stdio:"ignore",cwd:e.paths.root})}catch{}finally{tr({project:e,options:r})}};switch(e.packageManager){case"pnpm":break;case"bun":n(),await wb({project:e,options:r}),await s(),(0,qe.rmSync)(ii.default.join(e.paths.root,"yarn.lock"),{force:!0});break;case"npm":n(),await s();break;case"yarn":n(),await s();break}}var JT={detect:Sb,read:WT,create:YT,remove:VT,clean:KT,convertLock:ZT};W();var rn={name:"npm",lock:"package-lock.json"};async function Ab(t){let e=Yn.default.join(t.workspaceRoot,rn.lock),r=aa({workspaceRoot:t.workspaceRoot});return(0,Tt.existsSync)(e)||r===rn.name}async function XT(t){if(!await Ab(t))throw new je("Not an npm project",{type:"package_manager-unexpected"});let e=Ke(t),{name:r,description:i}=es(t),n=qh({workspaces:e.workspaces});return{name:r,description:i,packageManager:rn.name,paths:ua({root:t.workspaceRoot,lockFile:rn.lock}),workspaceData:{globs:n,workspaces:la({workspaceGlobs:n,...t})}}}async function QT(t){let{project:e,options:r,to:i,logger:n}=t,s=e.workspaceData.globs.length>0;n.mainStep(kr({packageManager:rn.name,action:"create",project:e}));let o=Ke({workspaceRoot:e.paths.root});n.rootHeader(),n.rootStep(`adding "packageManager" field to ${Yn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${i.name}@${i.version}`,s?(n.rootStep(`adding "workspaces" field to ${Yn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,r!=null&&r.dry||(0,Tt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),Rr({workspace:{name:"root",paths:e.paths},project:e,to:i,logger:n,options:r}),n.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Rr({workspace:a,project:e,to:i,logger:n,options:r})})):r!=null&&r.dry||(0,Tt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function eL(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(kr({packageManager:rn.name,action:"remove",project:e}));let s=Ke({workspaceRoot:e.paths.root});if(n&&(r.subStep(`removing "workspaces" field in ${e.name} root "package.json"`),delete s.workspaces),r.subStep(`removing "packageManager" field in ${e.name} root "package.json"`),delete s.packageManager,!(i!=null&&i.dry)){(0,Tt.writeJSONSync)(e.paths.packageJson,s,{spaces:2});let o=[e.paths.nodeModules,...e.workspaceData.workspaces.map(a=>a.paths.nodeModules)];try{r.subStep('removing "node_modules"'),await Promise.all(o.map(a=>(0,Tt.rm)(a,{recursive:!0,force:!0})))}catch{throw new je("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function tL(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${Yn.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,Tt.rmSync)(e.paths.lockfile,{force:!0})}async function rL(t){let{project:e,options:r}=t;switch(e.packageManager){case"pnpm":tr({project:e,options:r});break;case"bun":tr({project:e,options:r});break;case"npm":break;case"yarn":tr({project:e,options:r});break}}var iL={detect:Ab,read:XT,create:QT,remove:eL,clean:tL,convertLock:rL};W();var ni={name:"yarn",lock:"yarn.lock"};async function vb(t){let e=nn.default.join(t.workspaceRoot,ni.lock),r=aa({workspaceRoot:t.workspaceRoot});return(0,Lt.existsSync)(e)||r===ni.name}async function nL(t){if(!await vb(t))throw new je("Not a yarn project",{type:"package_manager-unexpected"});let e=Ke(t),{name:r,description:i}=es(t),n=qh({workspaces:e.workspaces});return{name:r,description:i,packageManager:ni.name,paths:ua({root:t.workspaceRoot,lockFile:ni.lock}),workspaceData:{globs:n,workspaces:la({workspaceGlobs:n,...t})}}}async function sL(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;i.mainStep(kr({packageManager:ni.name,action:"create",project:e}));let o=Ke({workspaceRoot:e.paths.root});i.rootHeader(),i.rootStep(`adding "packageManager" field to ${nn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${r.name}@${r.version}`,s?(i.rootStep(`adding "workspaces" field to ${nn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,n!=null&&n.dry||(0,Lt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),Rr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Rr({workspace:a,project:e,to:r,logger:i,options:n})})):n!=null&&n.dry||(0,Lt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function oL(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(kr({packageManager:ni.name,action:"remove",project:e}));let s=Ke({workspaceRoot:e.paths.root});if(n&&(r.subStep(`removing "workspaces" field in ${e.name} root "package.json"`),delete s.workspaces),r.subStep(`removing "packageManager" field in ${e.name} root "package.json"`),delete s.packageManager,!(i!=null&&i.dry)){(0,Lt.writeJSONSync)(e.paths.packageJson,s,{spaces:2});let o=[e.paths.nodeModules,...e.workspaceData.workspaces.map(a=>a.paths.nodeModules)];try{r.subStep('removing "node_modules"'),await Promise.all(o.map(a=>(0,Lt.rm)(a,{recursive:!0,force:!0})))}catch{throw new je("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function aL(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${nn.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,Lt.rmSync)(e.paths.lockfile,{force:!0})}async function uL(t){let{project:e,options:r,logger:i}=t,n=()=>{i.subStep(`converting ${nn.default.relative(e.paths.root,e.paths.lockfile)} to ${ni.lock}`)};switch(e.packageManager){case"pnpm":tr({project:e,options:r});break;case"bun":n(),await wb({project:e,options:r});break;case"npm":tr({project:e,options:r});break;case"yarn":break}}var lL={detect:vb,read:nL,create:sL,remove:oL,clean:aL,convertLock:uL};W();var sn={name:"bun",lock:"bun.lockb"};async function Cb(t){let e=Vn.default.join(t.workspaceRoot,sn.lock),r=aa({workspaceRoot:t.workspaceRoot});return(0,Bt.existsSync)(e)||r===sn.name}async function cL(t){if(!await Cb(t))throw new je("Not a bun project",{type:"package_manager-unexpected"});let e=Ke(t),{name:r,description:i}=es(t),n=qh({workspaces:e.workspaces});return{name:r,description:i,packageManager:sn.name,paths:ua({root:t.workspaceRoot,lockFile:sn.lock}),workspaceData:{globs:n,workspaces:la({workspaceGlobs:n,...t})}}}async function hL(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;if(!GT({project:e}))throw new je("Unable to convert project to bun - workspace globs unsupported",{type:"bun-workspace_glob_error"});i.mainStep(kr({packageManager:sn.name,action:"create",project:e}));let o=Ke({workspaceRoot:e.paths.root});i.rootHeader(),i.rootStep(`adding "packageManager" field to ${Vn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${r.name}@${r.version}`,s?(i.rootStep(`adding "workspaces" field to ${Vn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,n!=null&&n.dry||(0,Bt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),Rr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Rr({workspace:a,project:e,to:r,logger:i,options:n})})):n!=null&&n.dry||(0,Bt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function fL(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(kr({packageManager:sn.name,action:"remove",project:e}));let s=Ke({workspaceRoot:e.paths.root});if(n&&(r.subStep(`removing "workspaces" field in ${e.name} root "package.json"`),delete s.workspaces),r.subStep(`removing "packageManager" field in ${e.name} root "package.json"`),delete s.packageManager,!(i!=null&&i.dry)){(0,Bt.writeJSONSync)(e.paths.packageJson,s,{spaces:2});let o=[e.paths.nodeModules,...e.workspaceData.workspaces.map(a=>a.paths.nodeModules)];try{r.subStep('removing "node_modules"'),await Promise.all(o.map(a=>(0,Bt.rm)(a,{recursive:!0,force:!0})))}catch{throw new je("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function pL(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${Vn.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,Bt.rmSync)(e.paths.lockfile,{force:!0})}async function dL(t){let{project:e,options:r}=t;switch(e.packageManager){case"pnpm":tr({project:e,options:r});break;case"bun":break;case"npm":tr({project:e,options:r});break;case"yarn":tr({project:e,options:r});break}}var mL={detect:Cb,read:cL,create:hL,remove:fL,clean:pL,convertLock:dL},xb={pnpm:JT,yarn:lL,npm:iL,bun:mL};W();async function ts({root:t}){let{exists:e,absolute:r}=UT({directory:t});if(!e)throw new je(`Could not find directory at ${r}. Ensure the directory exists.`,{type:"invalid_directory"});for(let{detect:i,read:n}of Object.values(xb))if(await i({workspaceRoot:r}))return n({workspaceRoot:r});throw new je("Could not determine package manager. Add `packageManager` to `package.json` or ensure a lockfile is present.",{type:"package_manager-unable_to_detect"})}W();W();W();W();var Uh=J(require("chalk")),Rb=J(require("is-git-clean"));function ca({directory:t,force:e}){var n;let r=!1,i="Unable to determine if git directory is clean";try{r=Rb.default.sync(t||process.cwd()),i="Git directory is not clean"}catch(s){(n=s.stderr)!=null&&n.includes("not a git repository")&&(r=!0)}r||(e?ne.log(`${Uh.default.yellow("WARNING")}: ${i}. Forcibly continuing...`):(ne.log("Thank you for using @turbo/codemod!"),ne.log(Uh.default.yellow(`
45
45
  But before we continue, please stash or commit your git changes.`)),ne.log(`
46
- You may use the --force flag to override this safety check.`),process.exit(1)))}var Gh=J(require("path")),Fb=J(require("fs"));function on({directory:t}){let e=Gh.default.isAbsolute(t)?t:Gh.default.join(process.cwd(),t);return{exists:Fb.default.existsSync(e),absolute:e}}var ma=J(require("chalk"));var mt=J(require("chalk")),ha=class{constructor(e){this.transform=e.transformer,this.dry=e.dry}_log(...e){console.log(...e)}modified(...e){this._log(mt.default.green(" MODIFIED "),...e,this.dry?mt.default.dim("(dry run)"):"")}unchanged(...e){this._log(mt.default.gray(" UNCHANGED "),...e,this.dry?mt.default.dim("(dry run)"):"")}skipped(...e){this._log(mt.default.yellow(" SKIPPED "),...e,this.dry?mt.default.dim("(dry run)"):"")}error(...e){this._log(mt.default.red(" ERROR "),...e,this.dry?mt.default.dim("(dry run)"):"")}info(...e){this._log(mt.default.bold(" INFO "),...e,this.dry?mt.default.dim("(dry run)"):"")}};var Ob=J(require("os")),zh=J(require("path"));var fa=J(require("chalk")),da=require("diff"),kr=require("fs-extra"),pa=class{constructor(e){this.changes=[];if(this.filePath=e.filePath,this.rootPath=e.rootPath,this.after=e.after,this.error=e.error,e.before===void 0)try{zh.default.extname(e.filePath)===".json"?this.before=(0,kr.readJsonSync)(e.filePath):this.before=(0,kr.readFileSync)(e.filePath)}catch{this.before=""}else e.before===null?this.before="":this.before=e.before;e.after?typeof this.before=="object"||typeof e.after=="object"?this.changes=(0,da.diffJson)(this.before,e.after):this.changes=(0,da.diffLines)(this.before,e.after):this.changes=[]}fileName(){return zh.default.relative(this.rootPath,this.filePath)}write(){this.after&&(typeof this.after=="object"?(0,kr.writeJsonSync)(this.filePath,this.after,{spaces:2}):(0,kr.writeFileSync)(this.filePath,this.after))}additions(){return this.changes.filter(e=>e.added).length}deletions(){return this.changes.filter(e=>e.removed).length}hasChanges(){return this.additions()>0||this.deletions()>0}log(e){e.diff?(this.changes.forEach(r=>{r.added?process.stdout.write(fa.default.green(r.value)):r.removed?process.stdout.write(fa.default.red(r.value)):process.stdout.write(fa.default.dim(r.value))}),ne.log(Ob.default.EOL)):ne.log(this.after)}};var si=class{constructor(e){this.modifications={};this.transform=e.transformer,this.rootPath=e.rootPath,this.dry=e.dry,this.print=e.print,this.logger=new ha(e)}abortTransform(e){return this.logger.error(e.reason),{fatalError:new Error(e.reason),changes:e.changes||{}}}modifyFile(e){this.modifications[e.filePath]=new pa({rootPath:this.rootPath,...e})}finish(){let e={changes:{}};return Object.keys(this.modifications).forEach(i=>{let n=this.modifications[i],s={action:"unchanged",additions:n.additions(),deletions:n.deletions()};if(n.hasChanges()){if(this.dry)s.action="skipped",this.logger.skipped(ma.default.dim(n.fileName()));else try{n.write(),s.action="modified",this.logger.modified(ma.default.bold(n.fileName()))}catch(o){let a="Unknown error";o instanceof Error&&(a=o.message),s.error=new Error(a),s.action="error",this.logger.error(n.fileName(),a)}this.print&&n.log({diff:!0})}else this.logger.unchanged(ma.default.dim(n.fileName()));e.changes[n.fileName()]=s}),Object.keys(e.changes).some(i=>e.changes[i].action==="error")?this.abortTransform({reason:"Encountered an error while transforming files",changes:e.changes}):e}static logResults(e){let r=Object.keys(e.changes);if(ne.log(),r.length>0){ne.bold("Results:");let i={};r.forEach(n=>{var o;let s=e.changes[n];i[n]={action:s.action,additions:s.additions,deletions:s.deletions,error:((o=s.error)==null?void 0:o.message)||"None"}}),console.table(i),ne.log()}}};var kb=J(require("path")),Tb=require("fs-extra"),wL=["package.json","turbo.json",".git"];function Lb({directory:t}){return wL.some(e=>(0,Tb.existsSync)(kb.default.join(t,e)))}var Bb=require("child_process");function gt(t,e,r){try{return(0,Bb.execSync)(t,{stdio:"pipe",...e}).toString("utf8").trim()}catch{return r||void 0}}function Pb(t,e){let{from:r}=e;if(r)return r;let i=gt("turbo --version",{cwd:t.paths.root});if(i)return i;let{packageManager:n}=t;return n==="yarn"?gt("yarn turbo --version",{cwd:t.paths.root}):n==="pnpm"?gt("pnpm turbo --version",{cwd:t.paths.root}):gt("npm exec -c 'turbo --version'",{cwd:t.paths.root})}var Ib=J(require("axios")),SL="https://registry.npmjs.org";async function AL({packageName:t}){try{return(await Ib.default.get(`${SL}/${t}`)).data}catch{throw new Error(`Unable to fetch the latest version of ${t}`)}}async function Nb({to:t}){let e=await AL({packageName:"turbo"}),{"dist-tags":r,versions:i}=e;if(t){if(r[t]||t in i)return t;throw new Error(`turbo@${t} does not exist`)}return r.latest}var oi=require("semver");var ga=J(require("path")),jb=J(require("fs-extra")),Mb=process.env.NODE_ENV==="test"?ga.default.join(__dirname,"../transforms"):ga.default.join(__dirname,"./transforms");function ya(){return jb.default.readdirSync(Mb).map(e=>{let r=ga.default.join(Mb,e);try{return require(r).default}catch{return}}).filter(Boolean)}function $b({fromVersion:t,toVersion:e}){let r=ya().filter(i=>(0,oi.gt)(i.introducedIn,t)&&(0,oi.lte)(i.introducedIn,e));return r.sort((i,n)=>(0,oi.gt)(i.introducedIn,n.introducedIn)?1:(0,oi.eq)(i.introducedIn,n.introducedIn)?0:-1),r}var Hb=J(require("path")),Ea=require("fs-extra"),qb=require("semver");function vL(t,e="latest"){switch(t){case"yarn":return`yarn global add turbo@${e}`;case"npm":return`npm install turbo@${e} --global`;case"pnpm":return`pnpm add turbo@${e} --global`;case"bun":return`bun add turbo@${e} --global`}}function CL({packageManager:t,packageManagerVersion:e,installType:r,isUsingWorkspaces:i,to:n="latest"}){let s=o=>o.filter(Boolean).join(" ");switch(t){case"yarn":return(0,qb.gte)(e,"2.0.0")?s(["yarn","add",`turbo@${n}`,r==="devDependencies"&&"--dev"]):s(["yarn","add",`turbo@${n}`,r==="devDependencies"&&"--dev",i&&"-W"]);case"npm":return s(["npm","install",`turbo@${n}`,r==="devDependencies"&&"--save-dev"]);case"pnpm":return s(["pnpm","add",`turbo@${n}`,r==="devDependencies"&&"--save-dev",i&&"-w"]);case"bun":return s(["bun","add",`turbo@${n}`,r==="devDependencies"&&"--dev"])}}function xL({root:t}){let e=Hb.default.join(t,"package.json");if(!(0,Ea.existsSync)(e)){ne.error(`Unable to find package.json at ${e}`);return}let r=(0,Ea.readJsonSync)(e),i=r.devDependencies&&"turbo"in r.devDependencies,n=r.dependencies&&"turbo"in r.dependencies;if(n||i)return n?"dependencies":"devDependencies"}async function Ub({project:t,to:e}){let r=gt("turbo bin",{cwd:t.paths.root,stdio:"pipe"}),i=await zl(),n=Object.keys(i).find(c=>{let f=i[c];return f&&r?r.includes(f):!1});if(r&&n)return vL(n,e);let{packageManager:s}=t,o=t.workspaceData.globs.length>0,a=xL({root:t.paths.root}),l=(await Gl())[s];if(l&&a)return CL({packageManager:s,packageManagerVersion:l,installType:a,isUsingWorkspaces:o,to:e})}function Gb({project:t}){try{let e={cwd:t.paths.root,stdio:"ignore"};if(gt("turbo bin",e))gt("turbo daemon stop",e);else{let i=`${t.packageManager} turbo daemon stop`;t.packageManager==="npm"&&(i="npm exec -c 'turbo daemon stop'"),gt(i,e)}}catch{}}function yt({message:t,success:e}){return e?(ne.bold($e.default.green("Migration completed")),t&&ne.log(t),process.exit(0)):(ne.bold($e.default.red("Migration failed")),t&&ne.log(t),process.exit(1))}async function Wh(t,e){e.dry||ca({directory:t,force:e.force});let r=await(0,Wb.prompt)([{type:"input",name:"directoryInput",message:"Where is the root of the repo to migrate?",when:!t,default:".",validate:p=>{let{exists:g,absolute:y}=on({directory:p});return g?!0:`Directory ${$e.default.dim(`(${y})`)} does not exist`},filter:p=>p.trim()}]),{directoryInput:i=t}=r,{exists:n,absolute:s}=on({directory:i});if(!n)return yt({success:!1,message:`Directory ${$e.default.dim(`(${s})`)} does not exist`});if(!Lb({directory:s}))return yt({success:!1,message:`Directory (${$e.default.dim(s)}) does not appear to be a repository`});let o;try{o=await ts({root:s})}catch{return yt({success:!1,message:`Unable to read determine package manager details from ${$e.default.dim(s)}`})}let a=Pb(o,e);if(!a)return yt({success:!1,message:`Unable to infer the version of turbo being used by ${o.name}`});let u=e.to;try{u=await Nb(e)}catch(p){let g="UNKNOWN_ERROR";return p instanceof Error&&(g=p.message),yt({success:!1,message:g})}if(!u)return yt({success:!1,message:"Unable to fetch the latest version of turbo"});if(a===u)return yt({success:!0,message:`Nothing to do, current version (${$e.default.bold(a)}) is the same as the requested version (${$e.default.bold(u)})`});let l=$b({fromVersion:a,toVersion:u});l.length===0&&ne.log(`No codemods required to migrate from ${a} to ${u}`,an.default.EOL),e.dry||Gb({project:o}),ne.log(`Upgrading turbo from ${$e.default.bold(a)} to ${$e.default.bold(u)} (${l.length===0?"no codemods required":`${l.length} required codemod${l.length===1?"":"s"}`})`,an.default.EOL);let c=[];for(let[p,g]of l.entries()){ne.log(`(${p+1}/${l.length}) ${$e.default.bold(`Running ${g.name}`)}`);let y=await g.transformer({root:o.paths.root,options:e});si.logResults(y),c.push(y)}if(c.some(p=>p.fatalError||Object.keys(p.changes).some(g=>p.changes[g].error)))return yt({success:!1,message:"Could not complete migration due to codemod errors. Please fix the errors and try again."});let h=await Ub({project:o,to:e.to});if(!h)return yt({success:!1,message:"Unable to determine upgrade command"});if(e.install)if(e.dry)ne.log(`Upgrading turbo with ${$e.default.bold(h)} ${$e.default.dim("(dry run)")}`,an.default.EOL);else{ne.log(`Upgrading turbo with ${$e.default.bold(h)}`,an.default.EOL);try{(0,zb.execSync)(h,{stdio:"pipe",cwd:o.paths.root})}catch(p){return yt({success:!1,message:`Unable to upgrade turbo: ${String(p)}`})}}else ne.log(`Upgrade turbo with ${$e.default.bold(h)}`,an.default.EOL);yt({success:!0})}var Tr=J(require("chalk")),Yb=require("inquirer");async function Yh(t,e,r){let i=ya();if(r.list)return ne.log(i.map(h=>`- ${Tr.default.cyan(h.name)}`).join(`
47
- `)),process.exit(0);r.dry||ca({directory:e,force:r.force});let n=await(0,Yb.prompt)([{type:"input",name:"directoryInput",message:"Where is the root of the repo where the transform should run?",when:!e,default:".",validate:h=>{let{exists:p,absolute:g}=on({directory:h});return p?!0:`Directory ${Tr.default.dim(`(${g})`)} does not exist`},filter:h=>h.trim()},{type:"list",name:"transformerInput",message:"Which transform would you like to apply?",when:!t,pageSize:i.length,choices:i.map(h=>({name:`${Tr.default.bold(h.name)} - ${Tr.default.gray(h.description)} ${Tr.default.gray(`(${h.introducedIn})`)}`,value:h.name}))}]),{directoryInput:s=e,transformerInput:o=t}=n,{exists:a,absolute:u}=on({directory:s});if(!a)return ne.error(`Directory ${Tr.default.dim(`(${u})`)} does not exist`),process.exit(1);let l=i.map(h=>h.name),c=i.find(h=>h.name===o);if(!c)return ne.error(`Invalid transform choice ${Tr.default.dim(`(${t})`)}, pick one of:`),ne.error(l.map(h=>`- ${h}`).join(`
48
- `)),process.exit(1);let f=await c.transformer({root:u,options:r});if(f.fatalError)return process.exit(1);si.logResults(f)}var Vh=J(require("chalk")),Vb=J(require("update-check"));var RL=(0,Vb.default)(ia).catch(()=>null);async function Kh(){try{let t=await RL;if(t!=null&&t.latest){let{packageManager:e}=await ts({root:process.cwd()}),r="npm i -g @turbo/codemod";e==="yarn"?r="yarn global add @turbo/codemod":e==="pnpm"&&(r="pnpm i -g @turbo/codemod"),ne.log(),ne.log(Vh.default.yellow.bold("A new version of `@turbo/codemod` is available!")),ne.log(`You can update by running: ${Vh.default.cyan(r)}`),ne.log()}process.exit()}catch{}}var Da=new Zb.Command;Da.name("@turbo/codemod").description("Codemod transformations to help upgrade your Turborepo codebase when a feature is deprecated.").version(ia.version,"-v, --version","output the current version");Da.command("migrate").aliases(["update","upgrade"]).description("Migrate a project to the latest version of Turborepo").argument("[path]","Directory where the transforms should be applied").option("--from <version>","Specify the version to migrate from (default: current version)").option("--to <version>","Specify the version to migrate to (default: latest)").option("--install","Install new version of turbo after migration",!0).option("--force","Bypass Git safety checks and forcibly run codemods",!1).option("--dry, --dry-run, -d","Dry run (no changes are made to files)",!1).option("--print","Print transformed files to your terminal",!1).action(Wh);Da.command("transform",{isDefault:!0}).description("Apply a single code transformation to a project").argument("[transform]","The transformer to run").argument("[path]","Directory where the transforms should be applied").option("--force","Bypass Git safety checks and forcibly run codemods",!1).option("--list","List all available transforms",!1).option("--dry, --dry-run, -d","Dry run (no changes are made to files)",!1).option("--print","Print transformed files to your terminal",!1).action(Yh);Da.parseAsync().then(Kh).catch(async t=>{ne.log(),ne.log(Kb.default.red("Unexpected error. Please report it as a bug:")),ne.log(t),ne.log(),await Kh(),process.exit(1)});
46
+ You may use the --force flag to override this safety check.`),process.exit(1)))}var Gh=J(require("path")),Fb=J(require("fs"));function on({directory:t}){let e=Gh.default.isAbsolute(t)?t:Gh.default.join(process.cwd(),t);return{exists:Fb.default.existsSync(e),absolute:e}}var ma=J(require("chalk"));var mt=J(require("chalk")),ha=class{constructor(e){this.transform=e.transformer,this.dry=e.dry}_log(...e){console.log(...e)}modified(...e){this._log(mt.default.green(" MODIFIED "),...e,this.dry?mt.default.dim("(dry run)"):"")}unchanged(...e){this._log(mt.default.gray(" UNCHANGED "),...e,this.dry?mt.default.dim("(dry run)"):"")}skipped(...e){this._log(mt.default.yellow(" SKIPPED "),...e,this.dry?mt.default.dim("(dry run)"):"")}error(...e){this._log(mt.default.red(" ERROR "),...e,this.dry?mt.default.dim("(dry run)"):"")}info(...e){this._log(mt.default.bold(" INFO "),...e,this.dry?mt.default.dim("(dry run)"):"")}};var Ob=J(require("os")),zh=J(require("path"));var fa=J(require("chalk")),da=require("diff"),Tr=require("fs-extra"),pa=class{constructor(e){this.changes=[];if(this.filePath=e.filePath,this.rootPath=e.rootPath,this.after=e.after,this.error=e.error,e.before===void 0)try{zh.default.extname(e.filePath)===".json"?this.before=(0,Tr.readJsonSync)(e.filePath):this.before=(0,Tr.readFileSync)(e.filePath)}catch{this.before=""}else e.before===null?this.before="":this.before=e.before;e.after?typeof this.before=="object"||typeof e.after=="object"?this.changes=(0,da.diffJson)(this.before,e.after):this.changes=(0,da.diffLines)(this.before,e.after):this.changes=[]}fileName(){return zh.default.relative(this.rootPath,this.filePath)}write(){this.after&&(typeof this.after=="object"?(0,Tr.writeJsonSync)(this.filePath,this.after,{spaces:2}):(0,Tr.writeFileSync)(this.filePath,this.after))}additions(){return this.changes.filter(e=>e.added).length}deletions(){return this.changes.filter(e=>e.removed).length}hasChanges(){return this.additions()>0||this.deletions()>0}log(e){e.diff?(this.changes.forEach(r=>{r.added?process.stdout.write(fa.default.green(r.value)):r.removed?process.stdout.write(fa.default.red(r.value)):process.stdout.write(fa.default.dim(r.value))}),ne.log(Ob.default.EOL)):ne.log(this.after)}};var oi=class{constructor(e){this.modifications={};this.transform=e.transformer,this.rootPath=e.rootPath,this.dry=e.dry,this.print=e.print,this.logger=new ha(e)}abortTransform(e){return this.logger.error(e.reason),{fatalError:new Error(e.reason),changes:e.changes||{}}}modifyFile(e){this.modifications[e.filePath]=new pa({rootPath:this.rootPath,...e})}finish(){let e={changes:{}};return Object.keys(this.modifications).forEach(i=>{let n=this.modifications[i],s={action:"unchanged",additions:n.additions(),deletions:n.deletions()};if(n.hasChanges()){if(this.dry)s.action="skipped",this.logger.skipped(ma.default.dim(n.fileName()));else try{n.write(),s.action="modified",this.logger.modified(ma.default.bold(n.fileName()))}catch(o){let a="Unknown error";o instanceof Error&&(a=o.message),s.error=new Error(a),s.action="error",this.logger.error(n.fileName(),a)}this.print&&n.log({diff:!0})}else this.logger.unchanged(ma.default.dim(n.fileName()));e.changes[n.fileName()]=s}),Object.keys(e.changes).some(i=>e.changes[i].action==="error")?this.abortTransform({reason:"Encountered an error while transforming files",changes:e.changes}):e}static logResults(e){let r=Object.keys(e.changes);if(ne.log(),r.length>0){ne.bold("Results:");let i={};r.forEach(n=>{var o;let s=e.changes[n];i[n]={action:s.action,additions:s.additions,deletions:s.deletions,error:((o=s.error)==null?void 0:o.message)||"None"}}),console.table(i),ne.log()}}};var kb=J(require("path")),Tb=require("fs-extra"),wL=["package.json","turbo.json",".git"];function Lb({directory:t}){return wL.some(e=>(0,Tb.existsSync)(kb.default.join(t,e)))}var Bb=require("child_process");function gt(t,e,r){try{return(0,Bb.execSync)(t,{stdio:"pipe",...e}).toString("utf8").trim()}catch{return r||void 0}}function Pb(t,e){let{from:r}=e;if(r)return r;let i=gt("turbo --version",{cwd:t.paths.root});if(i)return i;let{packageManager:n}=t;return n==="yarn"?gt("yarn turbo --version",{cwd:t.paths.root}):n==="pnpm"?gt("pnpm turbo --version",{cwd:t.paths.root}):gt("npm exec -c 'turbo --version'",{cwd:t.paths.root})}var Ib=J(require("axios")),SL="https://registry.npmjs.org";async function AL({packageName:t}){try{return(await Ib.default.get(`${SL}/${t}`)).data}catch{throw new Error(`Unable to fetch the latest version of ${t}`)}}async function Nb({to:t}){let e=await AL({packageName:"turbo"}),{"dist-tags":r,versions:i}=e;if(t){if(r[t]||t in i)return t;throw new Error(`turbo@${t} does not exist`)}return r.latest}var ir=require("semver");var ga=J(require("path")),jb=J(require("fs-extra")),Mb=process.env.NODE_ENV==="test"?ga.default.join(__dirname,"../transforms"):ga.default.join(__dirname,"./transforms");function ya(){return jb.default.readdirSync(Mb).map(e=>{let r=ga.default.join(Mb,e);try{return require(r).default}catch{return}}).filter(Boolean)}function $b({fromVersion:t,toVersion:e}){let r=t.split(".")[0],n=r!==e.split(".")[0]?`${r}.0.0`:t,s=ya().filter(o=>{var l;let a=(0,ir.gt)(o.introducedIn,t)&&(0,ir.lte)(o.introducedIn,e),u=((l=o.idempotent)!=null?l:!0)&&(0,ir.gt)(o.introducedIn,n)&&(0,ir.lte)(o.introducedIn,e);return a||u});return s.sort((o,a)=>(0,ir.gt)(o.introducedIn,a.introducedIn)?1:(0,ir.eq)(o.introducedIn,a.introducedIn)?0:-1),s}var Hb=J(require("path")),Ea=require("fs-extra"),qb=require("semver");function vL(t,e="latest"){switch(t){case"yarn":return`yarn global add turbo@${e}`;case"npm":return`npm install turbo@${e} --global`;case"pnpm":return`pnpm add turbo@${e} --global`;case"bun":return`bun add turbo@${e} --global`}}function CL({packageManager:t,packageManagerVersion:e,installType:r,isUsingWorkspaces:i,to:n="latest"}){let s=o=>o.filter(Boolean).join(" ");switch(t){case"yarn":return(0,qb.gte)(e,"2.0.0")?s(["yarn","add",`turbo@${n}`,r==="devDependencies"&&"--dev"]):s(["yarn","add",`turbo@${n}`,r==="devDependencies"&&"--dev",i&&"-W"]);case"npm":return s(["npm","install",`turbo@${n}`,r==="devDependencies"&&"--save-dev"]);case"pnpm":return s(["pnpm","add",`turbo@${n}`,r==="devDependencies"&&"--save-dev",i&&"-w"]);case"bun":return s(["bun","add",`turbo@${n}`,r==="devDependencies"&&"--dev"])}}function xL({root:t}){let e=Hb.default.join(t,"package.json");if(!(0,Ea.existsSync)(e)){ne.error(`Unable to find package.json at ${e}`);return}let r=(0,Ea.readJsonSync)(e),i=r.devDependencies&&"turbo"in r.devDependencies,n=r.dependencies&&"turbo"in r.dependencies;if(n||i)return n?"dependencies":"devDependencies"}async function Ub({project:t,to:e}){let r=gt("turbo bin",{cwd:t.paths.root,stdio:"pipe"}),i=await zl(),n=Object.keys(i).find(c=>{let f=i[c];return f&&r?r.includes(f):!1});if(r&&n)return vL(n,e);let{packageManager:s}=t,o=t.workspaceData.globs.length>0,a=xL({root:t.paths.root}),l=(await Gl())[s];if(l&&a)return CL({packageManager:s,packageManagerVersion:l,installType:a,isUsingWorkspaces:o,to:e})}function Gb({project:t}){try{let e={cwd:t.paths.root,stdio:"ignore"};if(gt("turbo bin",e))gt("turbo daemon stop",e);else{let i=`${t.packageManager} turbo daemon stop`;t.packageManager==="npm"&&(i="npm exec -c 'turbo daemon stop'"),gt(i,e)}}catch{}}function yt({message:t,success:e}){return e?(ne.bold($e.default.green("Migration completed")),t&&ne.log(t),process.exit(0)):(ne.bold($e.default.red("Migration failed")),t&&ne.log(t),process.exit(1))}async function Wh(t,e){e.dry||ca({directory:t,force:e.force});let r=await(0,Wb.prompt)([{type:"input",name:"directoryInput",message:"Where is the root of the repo to migrate?",when:!t,default:".",validate:p=>{let{exists:g,absolute:y}=on({directory:p});return g?!0:`Directory ${$e.default.dim(`(${y})`)} does not exist`},filter:p=>p.trim()}]),{directoryInput:i=t}=r,{exists:n,absolute:s}=on({directory:i});if(!n)return yt({success:!1,message:`Directory ${$e.default.dim(`(${s})`)} does not exist`});if(!Lb({directory:s}))return yt({success:!1,message:`Directory (${$e.default.dim(s)}) does not appear to be a repository`});let o;try{o=await ts({root:s})}catch{return yt({success:!1,message:`Unable to read determine package manager details from ${$e.default.dim(s)}`})}let a=Pb(o,e);if(!a)return yt({success:!1,message:`Unable to infer the version of turbo being used by ${o.name}`});let u=e.to;try{u=await Nb(e)}catch(p){let g="UNKNOWN_ERROR";return p instanceof Error&&(g=p.message),yt({success:!1,message:g})}if(!u)return yt({success:!1,message:"Unable to fetch the latest version of turbo"});if(a===u)return yt({success:!0,message:`Nothing to do, current version (${$e.default.bold(a)}) is the same as the requested version (${$e.default.bold(u)})`});let l=$b({fromVersion:a,toVersion:u});l.length===0&&ne.log(`No codemods required to migrate from ${a} to ${u}`,an.default.EOL),e.dry||Gb({project:o}),ne.log(`Upgrading turbo from ${$e.default.bold(a)} to ${$e.default.bold(u)} (${l.length===0?"no codemods required":`${l.length} required codemod${l.length===1?"":"s"}`})`,an.default.EOL);let c=[];for(let[p,g]of l.entries()){ne.log(`(${p+1}/${l.length}) ${$e.default.bold(`Running ${g.name}`)}`);let y=await g.transformer({root:o.paths.root,options:e});oi.logResults(y),c.push(y)}if(c.some(p=>p.fatalError||Object.keys(p.changes).some(g=>p.changes[g].error)))return yt({success:!1,message:"Could not complete migration due to codemod errors. Please fix the errors and try again."});let h=await Ub({project:o,to:e.to});if(!h)return yt({success:!1,message:"Unable to determine upgrade command"});if(e.install)if(e.dry)ne.log(`Upgrading turbo with ${$e.default.bold(h)} ${$e.default.dim("(dry run)")}`,an.default.EOL);else{ne.log(`Upgrading turbo with ${$e.default.bold(h)}`,an.default.EOL);try{(0,zb.execSync)(h,{stdio:"pipe",cwd:o.paths.root})}catch(p){return yt({success:!1,message:`Unable to upgrade turbo: ${String(p)}`})}}else ne.log(`Upgrade turbo with ${$e.default.bold(h)}`,an.default.EOL);yt({success:!0})}var Lr=J(require("chalk")),Yb=require("inquirer");async function Yh(t,e,r){let i=ya();if(r.list)return ne.log(i.map(h=>`- ${Lr.default.cyan(h.name)}`).join(`
47
+ `)),process.exit(0);r.dry||ca({directory:e,force:r.force});let n=await(0,Yb.prompt)([{type:"input",name:"directoryInput",message:"Where is the root of the repo where the transform should run?",when:!e,default:".",validate:h=>{let{exists:p,absolute:g}=on({directory:h});return p?!0:`Directory ${Lr.default.dim(`(${g})`)} does not exist`},filter:h=>h.trim()},{type:"list",name:"transformerInput",message:"Which transform would you like to apply?",when:!t,pageSize:i.length,choices:i.map(h=>({name:`${Lr.default.bold(h.name)} - ${Lr.default.gray(h.description)} ${Lr.default.gray(`(${h.introducedIn})`)}`,value:h.name}))}]),{directoryInput:s=e,transformerInput:o=t}=n,{exists:a,absolute:u}=on({directory:s});if(!a)return ne.error(`Directory ${Lr.default.dim(`(${u})`)} does not exist`),process.exit(1);let l=i.map(h=>h.name),c=i.find(h=>h.name===o);if(!c)return ne.error(`Invalid transform choice ${Lr.default.dim(`(${t})`)}, pick one of:`),ne.error(l.map(h=>`- ${h}`).join(`
48
+ `)),process.exit(1);let f=await c.transformer({root:u,options:r});if(f.fatalError)return process.exit(1);oi.logResults(f)}var Vh=J(require("chalk")),Vb=J(require("update-check"));var RL=(0,Vb.default)(ia).catch(()=>null);async function Kh(){try{let t=await RL;if(t!=null&&t.latest){let{packageManager:e}=await ts({root:process.cwd()}),r="npm i -g @turbo/codemod";e==="yarn"?r="yarn global add @turbo/codemod":e==="pnpm"&&(r="pnpm i -g @turbo/codemod"),ne.log(),ne.log(Vh.default.yellow.bold("A new version of `@turbo/codemod` is available!")),ne.log(`You can update by running: ${Vh.default.cyan(r)}`),ne.log()}process.exit()}catch{}}var Da=new Zb.Command;Da.name("@turbo/codemod").description("Codemod transformations to help upgrade your Turborepo codebase when a feature is deprecated.").version(ia.version,"-v, --version","output the current version");Da.command("migrate").aliases(["update","upgrade"]).description("Migrate a project to the latest version of Turborepo").argument("[path]","Directory where the transforms should be applied").option("--from <version>","Specify the version to migrate from (default: current version)").option("--to <version>","Specify the version to migrate to (default: latest)").option("--install","Install new version of turbo after migration",!0).option("--force","Bypass Git safety checks and forcibly run codemods",!1).option("--dry, --dry-run, -d","Dry run (no changes are made to files)",!1).option("--print","Print transformed files to your terminal",!1).action(Wh);Da.command("transform",{isDefault:!0}).description("Apply a single code transformation to a project").argument("[transform]","The transformer to run").argument("[path]","Directory where the transforms should be applied").option("--force","Bypass Git safety checks and forcibly run codemods",!1).option("--list","List all available transforms",!1).option("--dry, --dry-run, -d","Dry run (no changes are made to files)",!1).option("--print","Print transformed files to your terminal",!1).action(Yh);Da.parseAsync().then(Kh).catch(async t=>{ne.log(),ne.log(Kb.default.red("Unexpected error. Please report it as a bug:")),ne.log(t),ne.log(),await Kh(),process.exit(1)});
49
49
  /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
50
50
  /*! Bundled license information:
51
51