@turbo/codemod 2.0.15-canary.1 → 2.0.15-canary.2
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cli.js +14 -14
- package/dist/transforms/add-package-manager.js +15 -15
- package/dist/transforms/add-package-names.js +11 -11
- package/dist/transforms/clean-globs.js +16 -16
- package/dist/transforms/create-turbo-config.js +16 -16
- package/dist/transforms/migrate-dot-env.js +17 -17
- package/dist/transforms/migrate-env-var-dependencies.js +17 -17
- package/dist/transforms/rename-output-mode.js +13 -13
- package/dist/transforms/rename-pipeline.js +17 -17
- package/dist/transforms/set-default-outputs.js +16 -16
- package/dist/transforms/stabilize-env-mode.js +4 -4
- package/dist/transforms/transform-env-literals-to-wildcards.js +14 -14
- package/package.json +5 -5
package/dist/cli.js
CHANGED
@@ -1,31 +1,31 @@
|
|
1
1
|
#!/usr/bin/env node
|
2
|
-
"use strict";var tE=Object.create;var va=Object.defineProperty;var rE=Object.getOwnPropertyDescriptor;var iE=Object.getOwnPropertyNames;var nE=Object.getPrototypeOf,sE=Object.prototype.hasOwnProperty;var $=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),oE=(t,e)=>{for(var r in e)va(t,r,{get:e[r],enumerable:!0})},aE=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of iE(e))!sE.call(t,n)&&n!==r&&va(t,n,{get:()=>e[n],enumerable:!(i=rE(e,n))||i.enumerable});return t};var ie=(t,e,r)=>(r=t!=null?tE(nE(t)):{},aE(e||!t||!t.__esModule?va(r,"default",{value:t,enumerable:!0}):r,t));var Qh=$((DI,Bt)=>{function Ra(t){return Bt.exports=Ra=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},Bt.exports.__esModule=!0,Bt.exports.default=Bt.exports,Ra(t)}Bt.exports=Ra,Bt.exports.__esModule=!0,Bt.exports.default=Bt.exports});var rf=$((MI,jt)=>{var ef=Qh().default;function tf(){"use strict";jt.exports=tf=function(){return e},jt.exports.__esModule=!0,jt.exports.default=jt.exports;var t,e={},r=Object.prototype,i=r.hasOwnProperty,n=Object.defineProperty||function(A,L,j){A[L]=j.value},s=typeof Symbol=="function"?Symbol:{},o=s.iterator||"@@iterator",a=s.asyncIterator||"@@asyncIterator",l=s.toStringTag||"@@toStringTag";function c(A,L,j){return Object.defineProperty(A,L,{value:j,enumerable:!0,configurable:!0,writable:!0}),A[L]}try{c({},"")}catch{c=function(j,z,D){return j[z]=D}}function u(A,L,j,z){var D=L&&L.prototype instanceof x?L:x,d=Object.create(D.prototype),m=new V(z||[]);return n(d,"_invoke",{value:q(A,j,m)}),d}function f(A,L,j){try{return{type:"normal",arg:A.call(L,j)}}catch(z){return{type:"throw",arg:z}}}e.wrap=u;var h="suspendedStart",p="suspendedYield",g="executing",y="completed",b={};function x(){}function k(){}function C(){}var T={};c(T,o,function(){return this});var O=Object.getPrototypeOf,I=O&&O(O(N([])));I&&I!==r&&i.call(I,o)&&(T=I);var w=C.prototype=x.prototype=Object.create(T);function v(A){["next","throw","return"].forEach(function(L){c(A,L,function(j){return this._invoke(L,j)})})}function F(A,L){function j(D,d,m,_){var R=f(A[D],A,d);if(R.type!=="throw"){var E=R.arg,M=E.value;return M&&ef(M)=="object"&&i.call(M,"__await")?L.resolve(M.__await).then(function(B){j("next",B,m,_)},function(B){j("throw",B,m,_)}):L.resolve(M).then(function(B){E.value=B,m(E)},function(B){return j("throw",B,m,_)})}_(R.arg)}var z;n(this,"_invoke",{value:function(d,m){function _(){return new L(function(R,E){j(d,m,R,E)})}return z=z?z.then(_,_):_()}})}function q(A,L,j){var z=h;return function(D,d){if(z===g)throw new Error("Generator is already running");if(z===y){if(D==="throw")throw d;return{value:t,done:!0}}for(j.method=D,j.arg=d;;){var m=j.delegate;if(m){var _=P(m,j);if(_){if(_===b)continue;return _}}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 R=f(A,L,j);if(R.type==="normal"){if(z=j.done?y:p,R.arg===b)continue;return{value:R.arg,done:j.done}}R.type==="throw"&&(z=y,j.method="throw",j.arg=R.arg)}}}function P(A,L){var j=L.method,z=A.iterator[j];if(z===t)return L.delegate=null,j==="throw"&&A.iterator.return&&(L.method="return",L.arg=t,P(A,L),L.method==="throw")||j!=="return"&&(L.method="throw",L.arg=new TypeError("The iterator does not provide a '"+j+"' method")),b;var D=f(z,A.iterator,L.arg);if(D.type==="throw")return L.method="throw",L.arg=D.arg,L.delegate=null,b;var d=D.arg;return d?d.done?(L[A.resultName]=d.value,L.next=A.nextLoc,L.method!=="return"&&(L.method="next",L.arg=t),L.delegate=null,b):d:(L.method="throw",L.arg=new TypeError("iterator result is not an object"),L.delegate=null,b)}function U(A){var L={tryLoc:A[0]};1 in A&&(L.catchLoc=A[1]),2 in A&&(L.finallyLoc=A[2],L.afterLoc=A[3]),this.tryEntries.push(L)}function K(A){var L=A.completion||{};L.type="normal",delete L.arg,A.completion=L}function V(A){this.tryEntries=[{tryLoc:"root"}],A.forEach(U,this),this.reset(!0)}function N(A){if(A||A===""){var L=A[o];if(L)return L.call(A);if(typeof A.next=="function")return A;if(!isNaN(A.length)){var j=-1,z=function D(){for(;++j<A.length;)if(i.call(A,j))return D.value=A[j],D.done=!1,D;return D.value=t,D.done=!0,D};return z.next=z}}throw new TypeError(ef(A)+" is not iterable")}return k.prototype=C,n(w,"constructor",{value:C,configurable:!0}),n(C,"constructor",{value:k,configurable:!0}),k.displayName=c(C,l,"GeneratorFunction"),e.isGeneratorFunction=function(A){var L=typeof A=="function"&&A.constructor;return!!L&&(L===k||(L.displayName||L.name)==="GeneratorFunction")},e.mark=function(A){return Object.setPrototypeOf?Object.setPrototypeOf(A,C):(A.__proto__=C,c(A,l,"GeneratorFunction")),A.prototype=Object.create(w),A},e.awrap=function(A){return{__await:A}},v(F.prototype),c(F.prototype,a,function(){return this}),e.AsyncIterator=F,e.async=function(A,L,j,z,D){D===void 0&&(D=Promise);var d=new F(u(A,L,j,z),D);return e.isGeneratorFunction(L)?d:d.next().then(function(m){return m.done?m.value:d.next()})},v(w),c(w,l,"Generator"),c(w,o,function(){return this}),c(w,"toString",function(){return"[object Generator]"}),e.keys=function(A){var L=Object(A),j=[];for(var z in L)j.push(z);return j.reverse(),function D(){for(;j.length;){var d=j.pop();if(d in L)return D.value=d,D.done=!1,D}return D.done=!0,D}},e.values=N,V.prototype={constructor:V,reset:function(L){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(K),!L)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 L=this.tryEntries[0].completion;if(L.type==="throw")throw L.arg;return this.rval},dispatchException:function(L){if(this.done)throw L;var j=this;function z(E,M){return m.type="throw",m.arg=L,j.next=E,M&&(j.method="next",j.arg=t),!!M}for(var D=this.tryEntries.length-1;D>=0;--D){var d=this.tryEntries[D],m=d.completion;if(d.tryLoc==="root")return z("end");if(d.tryLoc<=this.prev){var _=i.call(d,"catchLoc"),R=i.call(d,"finallyLoc");if(_&&R){if(this.prev<d.catchLoc)return z(d.catchLoc,!0);if(this.prev<d.finallyLoc)return z(d.finallyLoc)}else if(_){if(this.prev<d.catchLoc)return z(d.catchLoc,!0)}else{if(!R)throw new Error("try statement without catch or finally");if(this.prev<d.finallyLoc)return z(d.finallyLoc)}}}},abrupt:function(L,j){for(var z=this.tryEntries.length-1;z>=0;--z){var D=this.tryEntries[z];if(D.tryLoc<=this.prev&&i.call(D,"finallyLoc")&&this.prev<D.finallyLoc){var d=D;break}}d&&(L==="break"||L==="continue")&&d.tryLoc<=j&&j<=d.finallyLoc&&(d=null);var m=d?d.completion:{};return m.type=L,m.arg=j,d?(this.method="next",this.next=d.finallyLoc,b):this.complete(m)},complete:function(L,j){if(L.type==="throw")throw L.arg;return L.type==="break"||L.type==="continue"?this.next=L.arg:L.type==="return"?(this.rval=this.arg=L.arg,this.method="return",this.next="end"):L.type==="normal"&&j&&(this.next=j),b},finish:function(L){for(var j=this.tryEntries.length-1;j>=0;--j){var z=this.tryEntries[j];if(z.finallyLoc===L)return this.complete(z.completion,z.afterLoc),K(z),b}},catch:function(L){for(var j=this.tryEntries.length-1;j>=0;--j){var z=this.tryEntries[j];if(z.tryLoc===L){var D=z.completion;if(D.type==="throw"){var d=D.arg;K(z)}return d}}throw new Error("illegal catch attempt")},delegateYield:function(L,j,z){return this.delegate={iterator:N(L),resultName:j,nextLoc:z},this.method==="next"&&(this.arg=t),b}},e}jt.exports=tf,jt.exports.__esModule=!0,jt.exports.default=jt.exports});var sf=$((FI,nf)=>{var os=rf()();nf.exports=os;try{regeneratorRuntime=os}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=os:Function("r","regeneratorRuntime = r")(os)}});var cp=$(fi=>{"use strict";Object.defineProperty(fi,"__esModule",{value:!0});fi.splitWhen=fi.flatten=void 0;function N0(t){return t.reduce((e,r)=>[].concat(e,r),[])}fi.flatten=N0;function D0(t,e){let r=[[]],i=0;for(let n of t)e(n)?(i++,r[i]=[]):r[i].push(n);return r}fi.splitWhen=D0});var up=$(ps=>{"use strict";Object.defineProperty(ps,"__esModule",{value:!0});ps.isEnoentCodeError=void 0;function M0(t){return t.code==="ENOENT"}ps.isEnoentCodeError=M0});var hp=$(ds=>{"use strict";Object.defineProperty(ds,"__esModule",{value:!0});ds.createDirentFromStats=void 0;var Wa=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 F0(t,e){return new Wa(t,e)}ds.createDirentFromStats=F0});var fp=$(Et=>{"use strict";Object.defineProperty(Et,"__esModule",{value:!0});Et.removeLeadingDotSegment=Et.escape=Et.makeAbsolute=Et.unixify=void 0;var B0=require("path"),j0=2,$0=/(\\?)([()*?[\]{|}]|^!|[!+@](?=\())/g;function q0(t){return t.replace(/\\/g,"/")}Et.unixify=q0;function H0(t,e){return B0.resolve(t,e)}Et.makeAbsolute=H0;function U0(t){return t.replace($0,"\\$2")}Et.escape=U0;function G0(t){if(t.charAt(0)==="."){let e=t.charAt(1);if(e==="/"||e==="\\")return t.slice(j0)}return t}Et.removeLeadingDotSegment=G0});var dp=$((RN,pp)=>{pp.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 yp=$((xN,gp)=>{var z0=dp(),mp={"{":"}","(":")","[":"]"},W0=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 l=mp[a];if(l){var c=t.indexOf(l,e);c!==-1&&(e=c+1)}if(t[e]==="!")return!0}else e++}return!1},Y0=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=mp[r];if(i){var n=t.indexOf(i,e);n!==-1&&(e=n+1)}if(t[e]==="!")return!0}else e++}return!1};gp.exports=function(e,r){if(typeof e!="string"||e==="")return!1;if(z0(e))return!0;var i=W0;return r&&r.strict===!1&&(i=Y0),i(e)}});var _p=$((AN,bp)=>{"use strict";var K0=yp(),V0=require("path").posix.dirname,Z0=require("os").platform()==="win32",Ya="/",X0=/\\/g,J0=/[\{\[].*[\}\]]$/,Q0=/(^|[^\\])([\{\[]|\([^\)]+$)/,eR=/\\([\!\*\?\|\[\]\(\)\{\}])/g;bp.exports=function(e,r){var i=Object.assign({flipBackslashes:!0},r);i.flipBackslashes&&Z0&&e.indexOf(Ya)<0&&(e=e.replace(X0,Ya)),J0.test(e)&&(e+=Ya),e+="a";do e=V0(e);while(K0(e)||Q0.test(e));return e.replace(eR,"$1")}});var ms=$(ot=>{"use strict";ot.isInteger=t=>typeof t=="number"?Number.isInteger(t):typeof t=="string"&&t.trim()!==""?Number.isInteger(Number(t)):!1;ot.find=(t,e)=>t.nodes.find(r=>r.type===e);ot.exceedsLimit=(t,e,r=1,i)=>i===!1||!ot.isInteger(t)||!ot.isInteger(e)?!1:(Number(e)-Number(t))/Number(r)>=i;ot.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)};ot.encloseBrace=t=>t.type!=="brace"||t.commas>>0+t.ranges>>0?!1:(t.invalid=!0,!0);ot.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;ot.isOpenOrClose=t=>t.type==="open"||t.type==="close"?!0:t.open===!0||t.close===!0;ot.reduce=t=>t.reduce((e,r)=>(r.type==="text"&&e.push(r.value),r.type==="range"&&(r.type="text"),e),[]);ot.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 gs=$((TN,Sp)=>{"use strict";var wp=ms();Sp.exports=(t,e={})=>{let r=(i,n={})=>{let s=e.escapeInvalid&&wp.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a="";if(i.value)return(s||o)&&wp.isOpenOrClose(i)?"\\"+i.value:i.value;if(i.value)return i.value;if(i.nodes)for(let l of i.nodes)a+=r(l);return a};return r(t)}});var vp=$((kN,Ep)=>{"use strict";Ep.exports=function(t){return typeof t=="number"?t-t===0:typeof t=="string"&&t.trim()!==""?Number.isFinite?Number.isFinite(+t):isFinite(+t):!1}});var Pp=$((CN,Lp)=>{"use strict";var Rp=vp(),Fr=(t,e,r)=>{if(Rp(t)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(e===void 0||t===e)return String(t);if(Rp(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),l=t+":"+e+"="+n+s+o+a;if(Fr.cache.hasOwnProperty(l))return Fr.cache[l].result;let c=Math.min(t,e),u=Math.max(t,e);if(Math.abs(c-u)===1){let y=t+"|"+e;return i.capture?`(${y})`:i.wrap===!1?y:`(?:${y})`}let f=Cp(t)||Cp(e),h={min:t,max:e,a:c,b:u},p=[],g=[];if(f&&(h.isPadded=f,h.maxLen=String(h.max).length),c<0){let y=u<0?Math.abs(u):1;g=xp(y,Math.abs(c),h,i),c=h.a=0}return u>=0&&(p=xp(c,u,h,i)),h.negatives=g,h.positives=p,h.result=tR(g,p,i),i.capture===!0?h.result=`(${h.result})`:i.wrap!==!1&&p.length+g.length>1&&(h.result=`(?:${h.result})`),Fr.cache[l]=h,h.result};function tR(t,e,r){let i=Ka(t,e,"-",!1,r)||[],n=Ka(e,t,"",!1,r)||[],s=Ka(t,e,"-?",!0,r)||[];return i.concat(s).concat(n).join("|")}function rR(t,e){let r=1,i=1,n=Op(t,r),s=new Set([e]);for(;t<=n&&n<=e;)s.add(n),r+=1,n=Op(t,r);for(n=Tp(e+1,i)-1;t<n&&n<=e;)s.add(n),i+=1,n=Tp(e+1,i)-1;return s=[...s],s.sort(sR),s}function iR(t,e,r){if(t===e)return{pattern:t,count:[],digits:0};let i=nR(t,e),n=i.length,s="",o=0;for(let a=0;a<n;a++){let[l,c]=i[a];l===c?s+=l:l!=="0"||c!=="9"?s+=oR(l,c,r):o++}return o&&(s+=r.shorthand===!0?"\\d":"[0-9]"),{pattern:s,count:[o],digits:n}}function xp(t,e,r,i){let n=rR(t,e),s=[],o=t,a;for(let l=0;l<n.length;l++){let c=n[l],u=iR(String(o),String(c),i),f="";if(!r.isPadded&&a&&a.pattern===u.pattern){a.count.length>1&&a.count.pop(),a.count.push(u.count[0]),a.string=a.pattern+kp(a.count),o=c+1;continue}r.isPadded&&(f=aR(c,r,i)),u.string=f+u.pattern+kp(u.count),s.push(u),o=c+1,a=u}return s}function Ka(t,e,r,i,n){let s=[];for(let o of t){let{string:a}=o;!i&&!Ap(e,"string",a)&&s.push(r+a),i&&Ap(e,"string",a)&&s.push(r+a)}return s}function nR(t,e){let r=[];for(let i=0;i<t.length;i++)r.push([t[i],e[i]]);return r}function sR(t,e){return t>e?1:e>t?-1:0}function Ap(t,e,r){return t.some(i=>i[e]===r)}function Op(t,e){return Number(String(t).slice(0,-e)+"9".repeat(e))}function Tp(t,e){return t-t%Math.pow(10,e)}function kp(t){let[e=0,r=""]=t;return r||e>1?`{${e+(r?","+r:"")}}`:""}function oR(t,e,r){return`[${t}${e-t===1?"":"-"}${e}]`}function Cp(t){return/^-?(0+)\d/.test(t)}function aR(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}}`}}Fr.cache={};Fr.clearCache=()=>Fr.cache={};Lp.exports=Fr});var Xa=$((LN,$p)=>{"use strict";var lR=require("util"),Dp=Pp(),Ip=t=>t!==null&&typeof t=="object"&&!Array.isArray(t),cR=t=>e=>t===!0?Number(e):String(e),Va=t=>typeof t=="number"||typeof t=="string"&&t!=="",_n=t=>Number.isInteger(+t),Za=t=>{let e=`${t}`,r=-1;if(e[0]==="-"&&(e=e.slice(1)),e==="0")return!1;for(;e[++r]==="0";);return r>0},uR=(t,e,r)=>typeof t=="string"||typeof e=="string"?!0:r.stringify===!0,hR=(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},Np=(t,e)=>{let r=t[0]==="-"?"-":"";for(r&&(t=t.slice(1),e--);t.length<e;)t="0"+t;return r?"-"+t:t},fR=(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},Mp=(t,e,r,i)=>{if(r)return Dp(t,e,{wrap:!1,...i});let n=String.fromCharCode(t);if(t===e)return n;let s=String.fromCharCode(e);return`[${n}-${s}]`},Fp=(t,e,r)=>{if(Array.isArray(t)){let i=r.wrap===!0,n=r.capture?"":"?:";return i?`(${n}${t.join("|")})`:t.join("|")}return Dp(t,e,r)},Bp=(...t)=>new RangeError("Invalid range arguments: "+lR.inspect(...t)),jp=(t,e,r)=>{if(r.strictRanges===!0)throw Bp([t,e]);return[]},pR=(t,e)=>{if(e.strictRanges===!0)throw new TypeError(`Expected step "${t}" to be a number`);return[]},dR=(t,e,r=1,i={})=>{let n=Number(t),s=Number(e);if(!Number.isInteger(n)||!Number.isInteger(s)){if(i.strictRanges===!0)throw Bp([t,e]);return[]}n===0&&(n=0),s===0&&(s=0);let o=n>s,a=String(t),l=String(e),c=String(r);r=Math.max(Math.abs(r),1);let u=Za(a)||Za(l)||Za(c),f=u?Math.max(a.length,l.length,c.length):0,h=u===!1&&uR(t,e,i)===!1,p=i.transform||cR(h);if(i.toRegex&&r===1)return Mp(Np(t,f),Np(e,f),!0,i);let g={negatives:[],positives:[]},y=k=>g[k<0?"negatives":"positives"].push(Math.abs(k)),b=[],x=0;for(;o?n>=s:n<=s;)i.toRegex===!0&&r>1?y(n):b.push(hR(p(n,x),f,h)),n=o?n-r:n+r,x++;return i.toRegex===!0?r>1?fR(g,i):Fp(b,null,{wrap:!1,...i}):b},mR=(t,e,r=1,i={})=>{if(!_n(t)&&t.length>1||!_n(e)&&e.length>1)return jp(t,e,i);let n=i.transform||(h=>String.fromCharCode(h)),s=`${t}`.charCodeAt(0),o=`${e}`.charCodeAt(0),a=s>o,l=Math.min(s,o),c=Math.max(s,o);if(i.toRegex&&r===1)return Mp(l,c,!1,i);let u=[],f=0;for(;a?s>=o:s<=o;)u.push(n(s,f)),s=a?s-r:s+r,f++;return i.toRegex===!0?Fp(u,null,{wrap:!1,options:i}):u},ys=(t,e,r,i={})=>{if(e==null&&Va(t))return[t];if(!Va(t)||!Va(e))return jp(t,e,i);if(typeof r=="function")return ys(t,e,1,{transform:r});if(Ip(r))return ys(t,e,0,r);let n={...i};return n.capture===!0&&(n.wrap=!0),r=r||n.step||1,_n(r)?_n(t)&&_n(e)?dR(t,e,r,n):mR(t,e,Math.max(Math.abs(r),1),n):r!=null&&!Ip(r)?pR(r,n):ys(t,e,1,r)};$p.exports=ys});var Up=$((PN,Hp)=>{"use strict";var gR=Xa(),qp=ms(),yR=(t,e={})=>{let r=(i,n={})=>{let s=qp.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a=s===!0||o===!0,l=e.escapeInvalid===!0?"\\":"",c="";if(i.isOpen===!0||i.isClose===!0)return l+i.value;if(i.type==="open")return a?l+i.value:"(";if(i.type==="close")return a?l+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 u=qp.reduce(i.nodes),f=gR(...u,{...e,wrap:!1,toRegex:!0});if(f.length!==0)return u.length>1&&f.length>1?`(${f})`:f}if(i.nodes)for(let u of i.nodes)c+=r(u,i);return c};return r(t)};Hp.exports=yR});var Wp=$((IN,zp)=>{"use strict";var bR=Xa(),Gp=gs(),pi=ms(),Br=(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(Br(s,e,r));else for(let s of e)r===!0&&typeof s=="string"&&(s=`{${s}}`),i.push(Array.isArray(s)?Br(n,s,r):n+s);return pi.flatten(i)},_R=(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(Br(a.pop(),Gp(n,e)));return}if(n.type==="brace"&&n.invalid!==!0&&n.nodes.length===2){a.push(Br(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=bR(...f,e);h.length===0&&(h=Gp(n,e)),a.push(Br(a.pop(),h)),n.nodes=[];return}let l=pi.encloseBrace(n),c=n.queue,u=n;for(;u.type!=="brace"&&u.type!=="root"&&u.parent;)u=u.parent,c=u.queue;for(let f=0;f<n.nodes.length;f++){let h=n.nodes[f];if(h.type==="comma"&&n.type==="brace"){f===1&&c.push(""),c.push("");continue}if(h.type==="close"){a.push(Br(a.pop(),c,l));continue}if(h.value&&h.type!=="open"){c.push(Br(c.pop(),h.value));continue}h.nodes&&i(h,n)}return c};return pi.flatten(i(t))};zp.exports=_R});var Kp=$((NN,Yp)=>{"use strict";Yp.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 Qp=$((DN,Jp)=>{"use strict";var wR=gs(),{MAX_LENGTH:Vp,CHAR_BACKSLASH:Ja,CHAR_BACKTICK:SR,CHAR_COMMA:ER,CHAR_DOT:vR,CHAR_LEFT_PARENTHESES:RR,CHAR_RIGHT_PARENTHESES:xR,CHAR_LEFT_CURLY_BRACE:AR,CHAR_RIGHT_CURLY_BRACE:OR,CHAR_LEFT_SQUARE_BRACKET:Zp,CHAR_RIGHT_SQUARE_BRACKET:Xp,CHAR_DOUBLE_QUOTE:TR,CHAR_SINGLE_QUOTE:kR,CHAR_NO_BREAK_SPACE:CR,CHAR_ZERO_WIDTH_NOBREAK_SPACE:LR}=Kp(),PR=(t,e={})=>{if(typeof t!="string")throw new TypeError("Expected a string");let r=e||{},i=typeof r.maxLength=="number"?Math.min(Vp,r.maxLength):Vp;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,l=0,c=t.length,u=0,f=0,h,p={},g=()=>t[u++],y=b=>{if(b.type==="text"&&a.type==="dot"&&(a.type="text"),a&&a.type==="text"&&b.type==="text"){a.value+=b.value;return}return o.nodes.push(b),b.parent=o,b.prev=a,a=b,b};for(y({type:"bos"});u<c;)if(o=s[s.length-1],h=g(),!(h===LR||h===CR)){if(h===Ja){y({type:"text",value:(e.keepEscaping?h:"")+g()});continue}if(h===Xp){y({type:"text",value:"\\"+h});continue}if(h===Zp){l++;let b=!0,x;for(;u<c&&(x=g());){if(h+=x,x===Zp){l++;continue}if(x===Ja){h+=g();continue}if(x===Xp&&(l--,l===0))break}y({type:"text",value:h});continue}if(h===RR){o=y({type:"paren",nodes:[]}),s.push(o),y({type:"text",value:h});continue}if(h===xR){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===TR||h===kR||h===SR){let b=h,x;for(e.keepQuotes!==!0&&(h="");u<c&&(x=g());){if(x===Ja){h+=x+g();continue}if(x===b){e.keepQuotes===!0&&(h+=x);break}h+=x}y({type:"text",value:h});continue}if(h===AR){f++;let x={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(x),s.push(o),y({type:"open",value:h});continue}if(h===OR){if(o.type!=="brace"){y({type:"text",value:h});continue}let b="close";o=s.pop(),o.close=!0,y({type:b,value:h}),f--,o=s[s.length-1];continue}if(h===ER&&f>0){if(o.ranges>0){o.ranges=0;let b=o.nodes.shift();o.nodes=[b,{type:"text",value:wR(o)}]}y({type:"comma",value:h}),o.commas++;continue}if(h===vR&&f>0&&o.commas===0){let b=o.nodes;if(f===0||b.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"){b.pop();let x=b[b.length-1];x.value+=a.value+h,a=x,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(k=>{k.nodes||(k.type==="open"&&(k.isOpen=!0),k.type==="close"&&(k.isClose=!0),k.nodes||(k.type="text"),k.invalid=!0)});let b=s[s.length-1],x=b.nodes.indexOf(o);b.nodes.splice(x,1,...o.nodes)}while(s.length>0);return y({type:"eos"}),n};Jp.exports=PR});var rd=$((MN,td)=>{"use strict";var ed=gs(),IR=Up(),NR=Wp(),DR=Qp(),Qe=(t,e={})=>{let r=[];if(Array.isArray(t))for(let i of t){let n=Qe.create(i,e);Array.isArray(n)?r.push(...n):r.push(n)}else r=[].concat(Qe.create(t,e));return e&&e.expand===!0&&e.nodupes===!0&&(r=[...new Set(r)]),r};Qe.parse=(t,e={})=>DR(t,e);Qe.stringify=(t,e={})=>ed(typeof t=="string"?Qe.parse(t,e):t,e);Qe.compile=(t,e={})=>(typeof t=="string"&&(t=Qe.parse(t,e)),IR(t,e));Qe.expand=(t,e={})=>{typeof t=="string"&&(t=Qe.parse(t,e));let r=NR(t,e);return e.noempty===!0&&(r=r.filter(Boolean)),e.nodupes===!0&&(r=[...new Set(r)]),r};Qe.create=(t,e={})=>t===""||t.length<3?[t]:e.expand!==!0?Qe.compile(t,e):Qe.expand(t,e);td.exports=Qe});var wn=$((FN,ad)=>{"use strict";var MR=require("path"),vt="\\\\/",id=`[^${vt}]`,Ht="\\.",FR="\\+",BR="\\?",bs="\\/",jR="(?=.)",nd="[^/]",Qa=`(?:${bs}|$)`,sd=`(?:^|${bs})`,el=`${Ht}{1,2}${Qa}`,$R=`(?!${Ht})`,qR=`(?!${sd}${el})`,HR=`(?!${Ht}{0,1}${Qa})`,UR=`(?!${el})`,GR=`[^.${bs}]`,zR=`${nd}*?`,od={DOT_LITERAL:Ht,PLUS_LITERAL:FR,QMARK_LITERAL:BR,SLASH_LITERAL:bs,ONE_CHAR:jR,QMARK:nd,END_ANCHOR:Qa,DOTS_SLASH:el,NO_DOT:$R,NO_DOTS:qR,NO_DOT_SLASH:HR,NO_DOTS_SLASH:UR,QMARK_NO_DOT:GR,STAR:zR,START_ANCHOR:sd},WR={...od,SLASH_LITERAL:`[${vt}]`,QMARK:id,STAR:`${id}*?`,DOTS_SLASH:`${Ht}{1,2}(?:[${vt}]|$)`,NO_DOT:`(?!${Ht})`,NO_DOTS:`(?!(?:^|[${vt}])${Ht}{1,2}(?:[${vt}]|$))`,NO_DOT_SLASH:`(?!${Ht}{0,1}(?:[${vt}]|$))`,NO_DOTS_SLASH:`(?!${Ht}{1,2}(?:[${vt}]|$))`,QMARK_NO_DOT:`[^.${vt}]`,START_ANCHOR:`(?:^|[${vt}])`,END_ANCHOR:`(?:[${vt}]|$)`},YR={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"};ad.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:YR,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:MR.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?WR:od}}});var Sn=$(ze=>{"use strict";var KR=require("path"),VR=process.platform==="win32",{REGEX_BACKSLASH:ZR,REGEX_REMOVE_BACKSLASH:XR,REGEX_SPECIAL_CHARS:JR,REGEX_SPECIAL_CHARS_GLOBAL:QR}=wn();ze.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);ze.hasRegexChars=t=>JR.test(t);ze.isRegexChar=t=>t.length===1&&ze.hasRegexChars(t);ze.escapeRegex=t=>t.replace(QR,"\\$1");ze.toPosixSlashes=t=>t.replace(ZR,"/");ze.removeBackslashes=t=>t.replace(XR,e=>e==="\\"?"":e);ze.supportsLookbehinds=()=>{let t=process.version.slice(1).split(".").map(Number);return t.length===3&&t[0]>=9||t[0]===8&&t[1]>=10};ze.isWindows=t=>t&&typeof t.windows=="boolean"?t.windows:VR===!0||KR.sep==="\\";ze.escapeLast=(t,e,r)=>{let i=t.lastIndexOf(e,r);return i===-1?t:t[i-1]==="\\"?ze.escapeLast(t,e,i-1):`${t.slice(0,i)}\\${t.slice(i)}`};ze.removePrefix=(t,e={})=>{let r=t;return r.startsWith("./")&&(r=r.slice(2),e.prefix="./"),r};ze.wrapOutput=(t,e={},r={})=>{let i=r.contains?"":"^",n=r.contains?"":"$",s=`${i}(?:${t})${n}`;return e.negated===!0&&(s=`(?:^(?!${s}).*$)`),s}});var md=$((jN,dd)=>{"use strict";var ld=Sn(),{CHAR_ASTERISK:tl,CHAR_AT:ex,CHAR_BACKWARD_SLASH:En,CHAR_COMMA:tx,CHAR_DOT:rl,CHAR_EXCLAMATION_MARK:il,CHAR_FORWARD_SLASH:pd,CHAR_LEFT_CURLY_BRACE:nl,CHAR_LEFT_PARENTHESES:sl,CHAR_LEFT_SQUARE_BRACKET:rx,CHAR_PLUS:ix,CHAR_QUESTION_MARK:cd,CHAR_RIGHT_CURLY_BRACE:nx,CHAR_RIGHT_PARENTHESES:ud,CHAR_RIGHT_SQUARE_BRACKET:sx}=wn(),hd=t=>t===pd||t===En,fd=t=>{t.isPrefix!==!0&&(t.depth=t.isGlobstar?1/0:1)},ox=(t,e)=>{let r=e||{},i=t.length-1,n=r.parts===!0||r.scanToEnd===!0,s=[],o=[],a=[],l=t,c=-1,u=0,f=0,h=!1,p=!1,g=!1,y=!1,b=!1,x=!1,k=!1,C=!1,T=!1,O=!1,I=0,w,v,F={value:"",depth:0,isGlob:!1},q=()=>c>=i,P=()=>l.charCodeAt(c+1),U=()=>(w=v,l.charCodeAt(++c));for(;c<i;){v=U();let L;if(v===En){k=F.backslashes=!0,v=U(),v===nl&&(x=!0);continue}if(x===!0||v===nl){for(I++;q()!==!0&&(v=U());){if(v===En){k=F.backslashes=!0,U();continue}if(v===nl){I++;continue}if(x!==!0&&v===rl&&(v=U())===rl){if(h=F.isBrace=!0,g=F.isGlob=!0,O=!0,n===!0)continue;break}if(x!==!0&&v===tx){if(h=F.isBrace=!0,g=F.isGlob=!0,O=!0,n===!0)continue;break}if(v===nx&&(I--,I===0)){x=!1,h=F.isBrace=!0,O=!0;break}}if(n===!0)continue;break}if(v===pd){if(s.push(c),o.push(F),F={value:"",depth:0,isGlob:!1},O===!0)continue;if(w===rl&&c===u+1){u+=2;continue}f=c+1;continue}if(r.noext!==!0&&(v===ix||v===ex||v===tl||v===cd||v===il)===!0&&P()===sl){if(g=F.isGlob=!0,y=F.isExtglob=!0,O=!0,v===il&&c===u&&(T=!0),n===!0){for(;q()!==!0&&(v=U());){if(v===En){k=F.backslashes=!0,v=U();continue}if(v===ud){g=F.isGlob=!0,O=!0;break}}continue}break}if(v===tl){if(w===tl&&(b=F.isGlobstar=!0),g=F.isGlob=!0,O=!0,n===!0)continue;break}if(v===cd){if(g=F.isGlob=!0,O=!0,n===!0)continue;break}if(v===rx){for(;q()!==!0&&(L=U());){if(L===En){k=F.backslashes=!0,U();continue}if(L===sx){p=F.isBracket=!0,g=F.isGlob=!0,O=!0;break}}if(n===!0)continue;break}if(r.nonegate!==!0&&v===il&&c===u){C=F.negated=!0,u++;continue}if(r.noparen!==!0&&v===sl){if(g=F.isGlob=!0,n===!0){for(;q()!==!0&&(v=U());){if(v===sl){k=F.backslashes=!0,v=U();continue}if(v===ud){O=!0;break}}continue}break}if(g===!0){if(O=!0,n===!0)continue;break}}r.noext===!0&&(y=!1,g=!1);let K=l,V="",N="";u>0&&(V=l.slice(0,u),l=l.slice(u),f-=u),K&&g===!0&&f>0?(K=l.slice(0,f),N=l.slice(f)):g===!0?(K="",N=l):K=l,K&&K!==""&&K!=="/"&&K!==l&&hd(K.charCodeAt(K.length-1))&&(K=K.slice(0,-1)),r.unescape===!0&&(N&&(N=ld.removeBackslashes(N)),K&&k===!0&&(K=ld.removeBackslashes(K)));let A={prefix:V,input:t,start:u,base:K,glob:N,isBrace:h,isBracket:p,isGlob:g,isExtglob:y,isGlobstar:b,negated:C,negatedExtglob:T};if(r.tokens===!0&&(A.maxDepth=0,hd(v)||o.push(F),A.tokens=o),r.parts===!0||r.tokens===!0){let L;for(let j=0;j<s.length;j++){let z=L?L+1:u,D=s[j],d=t.slice(z,D);r.tokens&&(j===0&&u!==0?(o[j].isPrefix=!0,o[j].value=V):o[j].value=d,fd(o[j]),A.maxDepth+=o[j].depth),(j!==0||d!=="")&&a.push(d),L=D}if(L&&L+1<t.length){let j=t.slice(L+1);a.push(j),r.tokens&&(o[o.length-1].value=j,fd(o[o.length-1]),A.maxDepth+=o[o.length-1].depth)}A.slashes=s,A.parts=a}return A};dd.exports=ox});var bd=$(($N,yd)=>{"use strict";var _s=wn(),et=Sn(),{MAX_LENGTH:ws,POSIX_REGEX_SOURCE:ax,REGEX_NON_SPECIAL_CHARS:lx,REGEX_SPECIAL_CHARS_BACKREF:cx,REPLACEMENTS:gd}=_s,ux=(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=>et.escapeRegex(n)).join("..")}return r},di=(t,e)=>`Missing ${t}: "${e}" - use "\\\\${e}" to match literal characters`,ol=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");t=gd[t]||t;let r={...e},i=typeof r.maxLength=="number"?Math.min(ws,r.maxLength):ws,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?"":"?:",l=et.isWindows(e),c=_s.globChars(l),u=_s.extglobChars(c),{DOT_LITERAL:f,PLUS_LITERAL:h,SLASH_LITERAL:p,ONE_CHAR:g,DOTS_SLASH:y,NO_DOT:b,NO_DOT_SLASH:x,NO_DOTS_SLASH:k,QMARK:C,QMARK_NO_DOT:T,STAR:O,START_ANCHOR:I}=c,w=H=>`(${a}(?:(?!${I}${H.dot?y:f}).)*?)`,v=r.dot?"":b,F=r.dot?C:T,q=r.bash===!0?w(r):O;r.capture&&(q=`(${q})`),typeof r.noext=="boolean"&&(r.noextglob=r.noext);let P={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=et.removePrefix(t,P),n=t.length;let U=[],K=[],V=[],N=s,A,L=()=>P.index===n-1,j=P.peek=(H=1)=>t[P.index+H],z=P.advance=()=>t[++P.index]||"",D=()=>t.slice(P.index+1),d=(H="",J=0)=>{P.consumed+=H,P.index+=J},m=H=>{P.output+=H.output!=null?H.output:H.value,d(H.value)},_=()=>{let H=1;for(;j()==="!"&&(j(2)!=="("||j(3)==="?");)z(),P.start++,H++;return H%2===0?!1:(P.negated=!0,P.start++,!0)},R=H=>{P[H]++,V.push(H)},E=H=>{P[H]--,V.pop()},M=H=>{if(N.type==="globstar"){let J=P.braces>0&&(H.type==="comma"||H.type==="brace"),G=H.extglob===!0||U.length&&(H.type==="pipe"||H.type==="paren");H.type!=="slash"&&H.type!=="paren"&&!J&&!G&&(P.output=P.output.slice(0,-N.output.length),N.type="star",N.value="*",N.output=q,P.output+=N.output)}if(U.length&&H.type!=="paren"&&(U[U.length-1].inner+=H.value),(H.value||H.output)&&m(H),N&&N.type==="text"&&H.type==="text"){N.value+=H.value,N.output=(N.output||"")+H.value;return}H.prev=N,o.push(H),N=H},B=(H,J)=>{let G={...u[J],conditions:1,inner:""};G.prev=N,G.parens=P.parens,G.output=P.output;let re=(r.capture?"(":"")+G.open;R("parens"),M({type:H,value:J,output:P.output?"":g}),M({type:"paren",extglob:!0,value:z(),output:re}),U.push(G)},Z=H=>{let J=H.close+(r.capture?")":""),G;if(H.type==="negate"){let re=q;if(H.inner&&H.inner.length>1&&H.inner.includes("/")&&(re=w(r)),(re!==q||L()||/^\)+$/.test(D()))&&(J=H.close=`)$))${re}`),H.inner.includes("*")&&(G=D())&&/^\.[^\\/.]+$/.test(G)){let ue=ol(G,{...e,fastpaths:!1}).output;J=H.close=`)${ue})${re})`}H.prev.type==="bos"&&(P.negatedExtglob=!0)}M({type:"paren",extglob:!0,value:A,output:J}),E("parens")};if(r.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(t)){let H=!1,J=t.replace(cx,(G,re,ue,Ee,_e,S)=>Ee==="\\"?(H=!0,G):Ee==="?"?re?re+Ee+(_e?C.repeat(_e.length):""):S===0?F+(_e?C.repeat(_e.length):""):C.repeat(ue.length):Ee==="."?f.repeat(ue.length):Ee==="*"?re?re+Ee+(_e?q:""):q:re?G:`\\${G}`);return H===!0&&(r.unescape===!0?J=J.replace(/\\/g,""):J=J.replace(/\\+/g,G=>G.length%2===0?"\\\\":G?"\\":"")),J===t&&r.contains===!0?(P.output=t,P):(P.output=et.wrapOutput(J,P,e),P)}for(;!L();){if(A=z(),A==="\0")continue;if(A==="\\"){let G=j();if(G==="/"&&r.bash!==!0||G==="."||G===";")continue;if(!G){A+="\\",M({type:"text",value:A});continue}let re=/^\\+/.exec(D()),ue=0;if(re&&re[0].length>2&&(ue=re[0].length,P.index+=ue,ue%2!==0&&(A+="\\")),r.unescape===!0?A=z():A+=z(),P.brackets===0){M({type:"text",value:A});continue}}if(P.brackets>0&&(A!=="]"||N.value==="["||N.value==="[^")){if(r.posix!==!1&&A===":"){let G=N.value.slice(1);if(G.includes("[")&&(N.posix=!0,G.includes(":"))){let re=N.value.lastIndexOf("["),ue=N.value.slice(0,re),Ee=N.value.slice(re+2),_e=ax[Ee];if(_e){N.value=ue+_e,P.backtrack=!0,z(),!s.output&&o.indexOf(N)===1&&(s.output=g);continue}}}(A==="["&&j()!==":"||A==="-"&&j()==="]")&&(A=`\\${A}`),A==="]"&&(N.value==="["||N.value==="[^")&&(A=`\\${A}`),r.posix===!0&&A==="!"&&N.value==="["&&(A="^"),N.value+=A,m({value:A});continue}if(P.quotes===1&&A!=='"'){A=et.escapeRegex(A),N.value+=A,m({value:A});continue}if(A==='"'){P.quotes=P.quotes===1?0:1,r.keepQuotes===!0&&M({type:"text",value:A});continue}if(A==="("){R("parens"),M({type:"paren",value:A});continue}if(A===")"){if(P.parens===0&&r.strictBrackets===!0)throw new SyntaxError(di("opening","("));let G=U[U.length-1];if(G&&P.parens===G.parens+1){Z(U.pop());continue}M({type:"paren",value:A,output:P.parens?")":"\\)"}),E("parens");continue}if(A==="["){if(r.nobracket===!0||!D().includes("]")){if(r.nobracket!==!0&&r.strictBrackets===!0)throw new SyntaxError(di("closing","]"));A=`\\${A}`}else R("brackets");M({type:"bracket",value:A});continue}if(A==="]"){if(r.nobracket===!0||N&&N.type==="bracket"&&N.value.length===1){M({type:"text",value:A,output:`\\${A}`});continue}if(P.brackets===0){if(r.strictBrackets===!0)throw new SyntaxError(di("opening","["));M({type:"text",value:A,output:`\\${A}`});continue}E("brackets");let G=N.value.slice(1);if(N.posix!==!0&&G[0]==="^"&&!G.includes("/")&&(A=`/${A}`),N.value+=A,m({value:A}),r.literalBrackets===!1||et.hasRegexChars(G))continue;let re=et.escapeRegex(N.value);if(P.output=P.output.slice(0,-N.value.length),r.literalBrackets===!0){P.output+=re,N.value=re;continue}N.value=`(${a}${re}|${N.value})`,P.output+=N.value;continue}if(A==="{"&&r.nobrace!==!0){R("braces");let G={type:"brace",value:A,output:"(",outputIndex:P.output.length,tokensIndex:P.tokens.length};K.push(G),M(G);continue}if(A==="}"){let G=K[K.length-1];if(r.nobrace===!0||!G){M({type:"text",value:A,output:A});continue}let re=")";if(G.dots===!0){let ue=o.slice(),Ee=[];for(let _e=ue.length-1;_e>=0&&(o.pop(),ue[_e].type!=="brace");_e--)ue[_e].type!=="dots"&&Ee.unshift(ue[_e].value);re=ux(Ee,r),P.backtrack=!0}if(G.comma!==!0&&G.dots!==!0){let ue=P.output.slice(0,G.outputIndex),Ee=P.tokens.slice(G.tokensIndex);G.value=G.output="\\{",A=re="\\}",P.output=ue;for(let _e of Ee)P.output+=_e.output||_e.value}M({type:"brace",value:A,output:re}),E("braces"),K.pop();continue}if(A==="|"){U.length>0&&U[U.length-1].conditions++,M({type:"text",value:A});continue}if(A===","){let G=A,re=K[K.length-1];re&&V[V.length-1]==="braces"&&(re.comma=!0,G="|"),M({type:"comma",value:A,output:G});continue}if(A==="/"){if(N.type==="dot"&&P.index===P.start+1){P.start=P.index+1,P.consumed="",P.output="",o.pop(),N=s;continue}M({type:"slash",value:A,output:p});continue}if(A==="."){if(P.braces>0&&N.type==="dot"){N.value==="."&&(N.output=f);let G=K[K.length-1];N.type="dots",N.output+=A,N.value+=A,G.dots=!0;continue}if(P.braces+P.parens===0&&N.type!=="bos"&&N.type!=="slash"){M({type:"text",value:A,output:f});continue}M({type:"dot",value:A,output:f});continue}if(A==="?"){if(!(N&&N.value==="(")&&r.noextglob!==!0&&j()==="("&&j(2)!=="?"){B("qmark",A);continue}if(N&&N.type==="paren"){let re=j(),ue=A;if(re==="<"&&!et.supportsLookbehinds())throw new Error("Node.js v10 or higher is required for regex lookbehinds");(N.value==="("&&!/[!=<:]/.test(re)||re==="<"&&!/<([!=]|\w+>)/.test(D()))&&(ue=`\\${A}`),M({type:"text",value:A,output:ue});continue}if(r.dot!==!0&&(N.type==="slash"||N.type==="bos")){M({type:"qmark",value:A,output:T});continue}M({type:"qmark",value:A,output:C});continue}if(A==="!"){if(r.noextglob!==!0&&j()==="("&&(j(2)!=="?"||!/[!=<:]/.test(j(3)))){B("negate",A);continue}if(r.nonegate!==!0&&P.index===0){_();continue}}if(A==="+"){if(r.noextglob!==!0&&j()==="("&&j(2)!=="?"){B("plus",A);continue}if(N&&N.value==="("||r.regex===!1){M({type:"plus",value:A,output:h});continue}if(N&&(N.type==="bracket"||N.type==="paren"||N.type==="brace")||P.parens>0){M({type:"plus",value:A});continue}M({type:"plus",value:h});continue}if(A==="@"){if(r.noextglob!==!0&&j()==="("&&j(2)!=="?"){M({type:"at",extglob:!0,value:A,output:""});continue}M({type:"text",value:A});continue}if(A!=="*"){(A==="$"||A==="^")&&(A=`\\${A}`);let G=lx.exec(D());G&&(A+=G[0],P.index+=G[0].length),M({type:"text",value:A});continue}if(N&&(N.type==="globstar"||N.star===!0)){N.type="star",N.star=!0,N.value+=A,N.output=q,P.backtrack=!0,P.globstar=!0,d(A);continue}let H=D();if(r.noextglob!==!0&&/^\([^?]/.test(H)){B("star",A);continue}if(N.type==="star"){if(r.noglobstar===!0){d(A);continue}let G=N.prev,re=G.prev,ue=G.type==="slash"||G.type==="bos",Ee=re&&(re.type==="star"||re.type==="globstar");if(r.bash===!0&&(!ue||H[0]&&H[0]!=="/")){M({type:"star",value:A,output:""});continue}let _e=P.braces>0&&(G.type==="comma"||G.type==="brace"),S=U.length&&(G.type==="pipe"||G.type==="paren");if(!ue&&G.type!=="paren"&&!_e&&!S){M({type:"star",value:A,output:""});continue}for(;H.slice(0,3)==="/**";){let Y=t[P.index+4];if(Y&&Y!=="/")break;H=H.slice(3),d("/**",3)}if(G.type==="bos"&&L()){N.type="globstar",N.value+=A,N.output=w(r),P.output=N.output,P.globstar=!0,d(A);continue}if(G.type==="slash"&&G.prev.type!=="bos"&&!Ee&&L()){P.output=P.output.slice(0,-(G.output+N.output).length),G.output=`(?:${G.output}`,N.type="globstar",N.output=w(r)+(r.strictSlashes?")":"|$)"),N.value+=A,P.globstar=!0,P.output+=G.output+N.output,d(A);continue}if(G.type==="slash"&&G.prev.type!=="bos"&&H[0]==="/"){let Y=H[1]!==void 0?"|$":"";P.output=P.output.slice(0,-(G.output+N.output).length),G.output=`(?:${G.output}`,N.type="globstar",N.output=`${w(r)}${p}|${p}${Y})`,N.value+=A,P.output+=G.output+N.output,P.globstar=!0,d(A+z()),M({type:"slash",value:"/",output:""});continue}if(G.type==="bos"&&H[0]==="/"){N.type="globstar",N.value+=A,N.output=`(?:^|${p}|${w(r)}${p})`,P.output=N.output,P.globstar=!0,d(A+z()),M({type:"slash",value:"/",output:""});continue}P.output=P.output.slice(0,-N.output.length),N.type="globstar",N.output=w(r),N.value+=A,P.output+=N.output,P.globstar=!0,d(A);continue}let J={type:"star",value:A,output:q};if(r.bash===!0){J.output=".*?",(N.type==="bos"||N.type==="slash")&&(J.output=v+J.output),M(J);continue}if(N&&(N.type==="bracket"||N.type==="paren")&&r.regex===!0){J.output=A,M(J);continue}(P.index===P.start||N.type==="slash"||N.type==="dot")&&(N.type==="dot"?(P.output+=x,N.output+=x):r.dot===!0?(P.output+=k,N.output+=k):(P.output+=v,N.output+=v),j()!=="*"&&(P.output+=g,N.output+=g)),M(J)}for(;P.brackets>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing","]"));P.output=et.escapeLast(P.output,"["),E("brackets")}for(;P.parens>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing",")"));P.output=et.escapeLast(P.output,"("),E("parens")}for(;P.braces>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing","}"));P.output=et.escapeLast(P.output,"{"),E("braces")}if(r.strictSlashes!==!0&&(N.type==="star"||N.type==="bracket")&&M({type:"maybe_slash",value:"",output:`${p}?`}),P.backtrack===!0){P.output="";for(let H of P.tokens)P.output+=H.output!=null?H.output:H.value,H.suffix&&(P.output+=H.suffix)}return P};ol.fastpaths=(t,e)=>{let r={...e},i=typeof r.maxLength=="number"?Math.min(ws,r.maxLength):ws,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);t=gd[t]||t;let s=et.isWindows(e),{DOT_LITERAL:o,SLASH_LITERAL:a,ONE_CHAR:l,DOTS_SLASH:c,NO_DOT:u,NO_DOTS:f,NO_DOTS_SLASH:h,STAR:p,START_ANCHOR:g}=_s.globChars(s),y=r.dot?f:u,b=r.dot?h:u,x=r.capture?"":"?:",k={negated:!1,prefix:""},C=r.bash===!0?".*?":p;r.capture&&(C=`(${C})`);let T=v=>v.noglobstar===!0?C:`(${x}(?:(?!${g}${v.dot?c:o}).)*?)`,O=v=>{switch(v){case"*":return`${y}${l}${C}`;case".*":return`${o}${l}${C}`;case"*.*":return`${y}${C}${o}${l}${C}`;case"*/*":return`${y}${C}${a}${l}${b}${C}`;case"**":return y+T(r);case"**/*":return`(?:${y}${T(r)}${a})?${b}${l}${C}`;case"**/*.*":return`(?:${y}${T(r)}${a})?${b}${C}${o}${l}${C}`;case"**/.*":return`(?:${y}${T(r)}${a})?${o}${l}${C}`;default:{let F=/^(.*?)\.(\w+)$/.exec(v);if(!F)return;let q=O(F[1]);return q?q+o+F[2]:void 0}}},I=et.removePrefix(t,k),w=O(I);return w&&r.strictSlashes!==!0&&(w+=`${a}?`),w};yd.exports=ol});var wd=$((qN,_d)=>{"use strict";var hx=require("path"),fx=md(),al=bd(),ll=Sn(),px=wn(),dx=t=>t&&typeof t=="object"&&!Array.isArray(t),we=(t,e,r=!1)=>{if(Array.isArray(t)){let u=t.map(h=>we(h,e,r));return h=>{for(let p of u){let g=p(h);if(g)return g}return!1}}let i=dx(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=ll.isWindows(e),o=i?we.compileRe(t,e):we.makeRe(t,e,!1,!0),a=o.state;delete o.state;let l=()=>!1;if(n.ignore){let u={...e,ignore:null,onMatch:null,onResult:null};l=we(n.ignore,u,r)}let c=(u,f=!1)=>{let{isMatch:h,match:p,output:g}=we.test(u,o,e,{glob:t,posix:s}),y={glob:t,state:a,regex:o,posix:s,input:u,output:g,match:p,isMatch:h};return typeof n.onResult=="function"&&n.onResult(y),h===!1?(y.isMatch=!1,f?y:!1):l(u)?(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&&(c.state=a),c};we.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?ll.toPosixSlashes:null),a=t===i,l=a&&o?o(t):t;return a===!1&&(l=o?o(t):t,a=l===i),(a===!1||s.capture===!0)&&(s.matchBase===!0||s.basename===!0?a=we.matchBase(t,e,r,n):a=e.exec(l)),{isMatch:!!a,match:a,output:l}};we.matchBase=(t,e,r,i=ll.isWindows(r))=>(e instanceof RegExp?e:we.makeRe(e,r)).test(hx.basename(t));we.isMatch=(t,e,r)=>we(e,r)(t);we.parse=(t,e)=>Array.isArray(t)?t.map(r=>we.parse(r,e)):al(t,{...e,fastpaths:!1});we.scan=(t,e)=>fx(t,e);we.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 l=we.toRegex(a,e);return i===!0&&(l.state=t),l};we.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=al.fastpaths(t,e)),n.output||(n=al(t,e)),we.compileRe(n,e,r,i)};we.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/$^/}};we.constants=px;_d.exports=we});var Ed=$((HN,Sd)=>{"use strict";Sd.exports=wd()});var Od=$((UN,Ad)=>{"use strict";var Rd=require("util"),xd=rd(),Rt=Ed(),cl=Sn(),vd=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=u=>{s.add(u.output),r&&r.onResult&&r.onResult(u)};for(let u=0;u<e.length;u++){let f=Rt(String(e[u]),{...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 c=(o===e.length?[...s]:[...n]).filter(u=>!i.has(u));if(r&&c.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(u=>u.replace(/\\/g,"")):e}return c};ge.match=ge;ge.matcher=(t,e)=>Rt(t,e);ge.isMatch=(t,e,r)=>Rt(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: "${Rd.inspect(t)}"`);if(Array.isArray(e))return e.some(i=>ge.contains(t,i,r));if(typeof e=="string"){if(vd(t)||vd(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(!cl.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=Rt(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=Rt(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: "${Rd.inspect(t)}"`);return[].concat(e).every(i=>Rt(i,r)(t))};ge.capture=(t,e,r)=>{let i=cl.isWindows(r),s=Rt.makeRe(String(t),{...r,capture:!0}).exec(i?cl.toPosixSlashes(e):e);if(s)return s.slice(1).map(o=>o===void 0?"":o)};ge.makeRe=(...t)=>Rt.makeRe(...t);ge.scan=(...t)=>Rt.scan(...t);ge.parse=(t,e)=>{let r=[];for(let i of[].concat(t||[]))for(let n of xd(String(i),e))r.push(Rt.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]:xd(t,e)};ge.braceExpand=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return ge.braces(t,{...e,expand:!0})};Ad.exports=ge});var Dd=$(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 mx=require("path"),gx=_p(),ul=Od(),Td="**",yx="\\",bx=/[*?]|^!/,_x=/\[[^[]*]/,wx=/(?:^|[^!*+?@])\([^(]*\|[^|]*\)/,Sx=/[!*+?@]\([^(]*\)/,Ex=/,|\.\./;function kd(t,e={}){return!Cd(t,e)}se.isStaticPattern=kd;function Cd(t,e={}){return t===""?!1:!!(e.caseSensitiveMatch===!1||t.includes(yx)||bx.test(t)||_x.test(t)||wx.test(t)||e.extglob!==!1&&Sx.test(t)||e.braceExpansion!==!1&&vx(t))}se.isDynamicPattern=Cd;function vx(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 Ex.test(i)}function Rx(t){return Ss(t)?t.slice(1):t}se.convertToPositivePattern=Rx;function xx(t){return"!"+t}se.convertToNegativePattern=xx;function Ss(t){return t.startsWith("!")&&t[1]!=="("}se.isNegativePattern=Ss;function Ld(t){return!Ss(t)}se.isPositivePattern=Ld;function Ax(t){return t.filter(Ss)}se.getNegativePatterns=Ax;function Ox(t){return t.filter(Ld)}se.getPositivePatterns=Ox;function Tx(t){return t.filter(e=>!hl(e))}se.getPatternsInsideCurrentDirectory=Tx;function kx(t){return t.filter(hl)}se.getPatternsOutsideCurrentDirectory=kx;function hl(t){return t.startsWith("..")||t.startsWith("./..")}se.isPatternRelatedToParentDirectory=hl;function Cx(t){return gx(t,{flipBackslashes:!1})}se.getBaseDirectory=Cx;function Lx(t){return t.includes(Td)}se.hasGlobStar=Lx;function Pd(t){return t.endsWith("/"+Td)}se.endsWithSlashGlobStar=Pd;function Px(t){let e=mx.basename(t);return Pd(t)||kd(e)}se.isAffectDepthOfReadingPattern=Px;function Ix(t){return t.reduce((e,r)=>e.concat(Id(r)),[])}se.expandPatternsWithBraceExpansion=Ix;function Id(t){return ul.braces(t,{expand:!0,nodupes:!0})}se.expandBraceExpansion=Id;function Nx(t,e){let{parts:r}=ul.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=Nx;function Nd(t,e){return ul.makeRe(t,e)}se.makeRe=Nd;function Dx(t,e){return t.map(r=>Nd(r,e))}se.convertPatternsToRe=Dx;function Mx(t,e){return e.some(r=>r.test(t))}se.matchAny=Mx});var jd=$((zN,Bd)=>{"use strict";var Fx=require("stream"),Md=Fx.PassThrough,Bx=Array.prototype.slice;Bd.exports=jx;function jx(){let t=[],e=Bx.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=Md(i);function a(){for(let u=0,f=arguments.length;u<f;u++)t.push(Fd(arguments[u],i));return l(),this}function l(){if(r)return;r=!0;let u=t.shift();if(!u){process.nextTick(c);return}Array.isArray(u)||(u=[u]);let f=u.length+1;function h(){--f>0||(r=!1,l())}function p(g){function y(){g.removeListener("merge2UnpipeEnd",y),g.removeListener("end",y),s&&g.removeListener("error",b),h()}function b(x){o.emit("error",x)}if(g._readableState.endEmitted)return h();g.on("merge2UnpipeEnd",y),g.on("end",y),s&&g.on("error",b),g.pipe(o,{end:!1}),g.resume()}for(let g=0;g<u.length;g++)p(u[g]);h()}function c(){r=!1,o.emit("queueDrain"),n&&o.end()}return o.setMaxListeners(0),o.add=a,o.on("unpipe",function(u){u.emit("merge2UnpipeEnd")}),e.length&&a.apply(null,e),o}function Fd(t,e){if(Array.isArray(t))for(let r=0,i=t.length;r<i;r++)t[r]=Fd(t[r],e);else{if(!t._readableState&&t.pipe&&(t=t.pipe(Md(e))),!t._readableState||!t.pause||!t.pipe)throw new Error("Only readable stream can be merged.");t.pause()}return t}});var qd=$(Es=>{"use strict";Object.defineProperty(Es,"__esModule",{value:!0});Es.merge=void 0;var $x=jd();function qx(t){let e=$x(t);return t.forEach(r=>{r.once("error",i=>e.emit("error",i))}),e.once("close",()=>$d(t)),e.once("end",()=>$d(t)),e}Es.merge=qx;function $d(t){t.forEach(e=>e.emit("close"))}});var Hd=$(mi=>{"use strict";Object.defineProperty(mi,"__esModule",{value:!0});mi.isEmpty=mi.isString=void 0;function Hx(t){return typeof t=="string"}mi.isString=Hx;function Ux(t){return t===""}mi.isEmpty=Ux});var Ut=$(Ie=>{"use strict";Object.defineProperty(Ie,"__esModule",{value:!0});Ie.string=Ie.stream=Ie.pattern=Ie.path=Ie.fs=Ie.errno=Ie.array=void 0;var Gx=cp();Ie.array=Gx;var zx=up();Ie.errno=zx;var Wx=hp();Ie.fs=Wx;var Yx=fp();Ie.path=Yx;var Kx=Dd();Ie.pattern=Kx;var Vx=qd();Ie.stream=Vx;var Zx=Hd();Ie.string=Zx});var zd=$(Ne=>{"use strict";Object.defineProperty(Ne,"__esModule",{value:!0});Ne.convertPatternGroupToTask=Ne.convertPatternGroupsToTasks=Ne.groupPatternsByBaseDirectory=Ne.getNegativePatternsAsPositive=Ne.getPositivePatterns=Ne.convertPatternsToTasks=Ne.generate=void 0;var Gt=Ut();function Xx(t,e){let r=Ud(t),i=Gd(t,e.ignore),n=r.filter(l=>Gt.pattern.isStaticPattern(l,e)),s=r.filter(l=>Gt.pattern.isDynamicPattern(l,e)),o=fl(n,i,!1),a=fl(s,i,!0);return o.concat(a)}Ne.generate=Xx;function fl(t,e,r){let i=[],n=Gt.pattern.getPatternsOutsideCurrentDirectory(t),s=Gt.pattern.getPatternsInsideCurrentDirectory(t),o=pl(n),a=pl(s);return i.push(...dl(o,e,r)),"."in a?i.push(ml(".",s,e,r)):i.push(...dl(a,e,r)),i}Ne.convertPatternsToTasks=fl;function Ud(t){return Gt.pattern.getPositivePatterns(t)}Ne.getPositivePatterns=Ud;function Gd(t,e){return Gt.pattern.getNegativePatterns(t).concat(e).map(Gt.pattern.convertToPositivePattern)}Ne.getNegativePatternsAsPositive=Gd;function pl(t){let e={};return t.reduce((r,i)=>{let n=Gt.pattern.getBaseDirectory(i);return n in r?r[n].push(i):r[n]=[i],r},e)}Ne.groupPatternsByBaseDirectory=pl;function dl(t,e,r){return Object.keys(t).map(i=>ml(i,t[i],e,r))}Ne.convertPatternGroupsToTasks=dl;function ml(t,e,r,i){return{dynamic:i,positive:e,negative:r,base:t,patterns:[].concat(e,r.map(Gt.pattern.convertToNegativePattern))}}Ne.convertPatternGroupToTask=ml});var Yd=$(gi=>{"use strict";Object.defineProperty(gi,"__esModule",{value:!0});gi.removeDuplicateSlashes=gi.transform=void 0;var Jx=/(?!^)\/{2,}/g;function Qx(t){return t.map(e=>Wd(e))}gi.transform=Qx;function Wd(t){return t.replace(Jx,"/")}gi.removeDuplicateSlashes=Wd});var Vd=$(vs=>{"use strict";Object.defineProperty(vs,"__esModule",{value:!0});vs.read=void 0;function eA(t,e,r){e.fs.lstat(t,(i,n)=>{if(i!==null){Kd(r,i);return}if(!n.isSymbolicLink()||!e.followSymbolicLink){gl(r,n);return}e.fs.stat(t,(s,o)=>{if(s!==null){if(e.throwErrorOnBrokenSymbolicLink){Kd(r,s);return}gl(r,n);return}e.markSymbolicLink&&(o.isSymbolicLink=()=>!0),gl(r,o)})})}vs.read=eA;function Kd(t,e){t(e)}function gl(t,e){t(null,e)}});var Zd=$(Rs=>{"use strict";Object.defineProperty(Rs,"__esModule",{value:!0});Rs.read=void 0;function tA(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}}Rs.read=tA});var Xd=$(cr=>{"use strict";Object.defineProperty(cr,"__esModule",{value:!0});cr.createFileSystemAdapter=cr.FILE_SYSTEM_ADAPTER=void 0;var xs=require("fs");cr.FILE_SYSTEM_ADAPTER={lstat:xs.lstat,stat:xs.stat,lstatSync:xs.lstatSync,statSync:xs.statSync};function rA(t){return t===void 0?cr.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},cr.FILE_SYSTEM_ADAPTER),t)}cr.createFileSystemAdapter=rA});var Jd=$(bl=>{"use strict";Object.defineProperty(bl,"__esModule",{value:!0});var iA=Xd(),yl=class{constructor(e={}){this._options=e,this.followSymbolicLink=this._getValue(this._options.followSymbolicLink,!0),this.fs=iA.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}};bl.default=yl});var jr=$(ur=>{"use strict";Object.defineProperty(ur,"__esModule",{value:!0});ur.statSync=ur.stat=ur.Settings=void 0;var Qd=Vd(),nA=Zd(),_l=Jd();ur.Settings=_l.default;function sA(t,e,r){if(typeof e=="function"){Qd.read(t,wl(),e);return}Qd.read(t,wl(e),r)}ur.stat=sA;function oA(t,e){let r=wl(e);return nA.read(t,r)}ur.statSync=oA;function wl(t={}){return t instanceof _l.default?t:new _l.default(t)}});var rm=$((rD,tm)=>{var em;tm.exports=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window!="undefined"?window:global):t=>(em||(em=Promise.resolve())).then(t).catch(e=>setTimeout(()=>{throw e},0))});var nm=$((iD,im)=>{im.exports=lA;var aA=rm();function lA(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(l){function c(){e&&e(l,r),e=null}s?aA(c):c()}function a(l,c,u){r[l]=u,(--i===0||c)&&o(c)}i?n?n.forEach(function(l){t[l](function(c,u){a(l,c,u)})}):t.forEach(function(l,c){l(function(u,f){a(c,u,f)})}):o(null),s=!1}});var Sl=$(Os=>{"use strict";Object.defineProperty(Os,"__esModule",{value:!0});Os.IS_SUPPORT_READDIR_WITH_FILE_TYPES=void 0;var As=process.versions.node.split(".");if(As[0]===void 0||As[1]===void 0)throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`);var sm=Number.parseInt(As[0],10),cA=Number.parseInt(As[1],10),om=10,uA=10,hA=sm>om,fA=sm===om&&cA>=uA;Os.IS_SUPPORT_READDIR_WITH_FILE_TYPES=hA||fA});var am=$(Ts=>{"use strict";Object.defineProperty(Ts,"__esModule",{value:!0});Ts.createDirentFromStats=void 0;var El=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 pA(t,e){return new El(t,e)}Ts.createDirentFromStats=pA});var vl=$(ks=>{"use strict";Object.defineProperty(ks,"__esModule",{value:!0});ks.fs=void 0;var dA=am();ks.fs=dA});var Rl=$(Cs=>{"use strict";Object.defineProperty(Cs,"__esModule",{value:!0});Cs.joinPathSegments=void 0;function mA(t,e,r){return t.endsWith(r)?t+e:t+r+e}Cs.joinPathSegments=mA});var pm=$(hr=>{"use strict";Object.defineProperty(hr,"__esModule",{value:!0});hr.readdir=hr.readdirWithFileTypes=hr.read=void 0;var gA=jr(),lm=nm(),yA=Sl(),cm=vl(),um=Rl();function bA(t,e,r){if(!e.stats&&yA.IS_SUPPORT_READDIR_WITH_FILE_TYPES){hm(t,e,r);return}fm(t,e,r)}hr.read=bA;function hm(t,e,r){e.fs.readdir(t,{withFileTypes:!0},(i,n)=>{if(i!==null){Ls(r,i);return}let s=n.map(a=>({dirent:a,name:a.name,path:um.joinPathSegments(t,a.name,e.pathSegmentSeparator)}));if(!e.followSymbolicLinks){xl(r,s);return}let o=s.map(a=>_A(a,e));lm(o,(a,l)=>{if(a!==null){Ls(r,a);return}xl(r,l)})})}hr.readdirWithFileTypes=hm;function _A(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=cm.fs.createDirentFromStats(t.name,n),r(null,t)})}}function fm(t,e,r){e.fs.readdir(t,(i,n)=>{if(i!==null){Ls(r,i);return}let s=n.map(o=>{let a=um.joinPathSegments(t,o,e.pathSegmentSeparator);return l=>{gA.stat(a,e.fsStatSettings,(c,u)=>{if(c!==null){l(c);return}let f={name:o,path:a,dirent:cm.fs.createDirentFromStats(o,u)};e.stats&&(f.stats=u),l(null,f)})}});lm(s,(o,a)=>{if(o!==null){Ls(r,o);return}xl(r,a)})})}hr.readdir=fm;function Ls(t,e){t(e)}function xl(t,e){t(null,e)}});var bm=$(fr=>{"use strict";Object.defineProperty(fr,"__esModule",{value:!0});fr.readdir=fr.readdirWithFileTypes=fr.read=void 0;var wA=jr(),SA=Sl(),dm=vl(),mm=Rl();function EA(t,e){return!e.stats&&SA.IS_SUPPORT_READDIR_WITH_FILE_TYPES?gm(t,e):ym(t,e)}fr.read=EA;function gm(t,e){return e.fs.readdirSync(t,{withFileTypes:!0}).map(i=>{let n={dirent:i,name:i.name,path:mm.joinPathSegments(t,i.name,e.pathSegmentSeparator)};if(n.dirent.isSymbolicLink()&&e.followSymbolicLinks)try{let s=e.fs.statSync(n.path);n.dirent=dm.fs.createDirentFromStats(n.name,s)}catch(s){if(e.throwErrorOnBrokenSymbolicLink)throw s}return n})}fr.readdirWithFileTypes=gm;function ym(t,e){return e.fs.readdirSync(t).map(i=>{let n=mm.joinPathSegments(t,i,e.pathSegmentSeparator),s=wA.statSync(n,e.fsStatSettings),o={name:i,path:n,dirent:dm.fs.createDirentFromStats(i,s)};return e.stats&&(o.stats=s),o})}fr.readdir=ym});var _m=$(pr=>{"use strict";Object.defineProperty(pr,"__esModule",{value:!0});pr.createFileSystemAdapter=pr.FILE_SYSTEM_ADAPTER=void 0;var yi=require("fs");pr.FILE_SYSTEM_ADAPTER={lstat:yi.lstat,stat:yi.stat,lstatSync:yi.lstatSync,statSync:yi.statSync,readdir:yi.readdir,readdirSync:yi.readdirSync};function vA(t){return t===void 0?pr.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},pr.FILE_SYSTEM_ADAPTER),t)}pr.createFileSystemAdapter=vA});var wm=$(Ol=>{"use strict";Object.defineProperty(Ol,"__esModule",{value:!0});var RA=require("path"),xA=jr(),AA=_m(),Al=class{constructor(e={}){this._options=e,this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!1),this.fs=AA.createFileSystemAdapter(this._options.fs),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,RA.sep),this.stats=this._getValue(this._options.stats,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0),this.fsStatSettings=new xA.Settings({followSymbolicLink:this.followSymbolicLinks,fs:this.fs,throwErrorOnBrokenSymbolicLink:this.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};Ol.default=Al});var Ps=$(dr=>{"use strict";Object.defineProperty(dr,"__esModule",{value:!0});dr.Settings=dr.scandirSync=dr.scandir=void 0;var Sm=pm(),OA=bm(),Tl=wm();dr.Settings=Tl.default;function TA(t,e,r){if(typeof e=="function"){Sm.read(t,kl(),e);return}Sm.read(t,kl(e),r)}dr.scandir=TA;function kA(t,e){let r=kl(e);return OA.read(t,r)}dr.scandirSync=kA;function kl(t={}){return t instanceof Tl.default?t:new Tl.default(t)}});var vm=$((pD,Em)=>{"use strict";function CA(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}}Em.exports=CA});var xm=$((dD,Cl)=>{"use strict";var LA=vm();function Rm(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=LA(PA),n=null,s=null,o=0,a=null,l={push:y,drain:at,saturated:at,pause:u,paused:!1,concurrency:r,running:c,resume:p,idle:g,length:f,getQueue:h,unshift:b,empty:at,kill:k,killAndDrain:C,error:T};return l;function c(){return o}function u(){l.paused=!0}function f(){for(var O=n,I=0;O;)O=O.next,I++;return I}function h(){for(var O=n,I=[];O;)I.push(O.value),O=O.next;return I}function p(){if(l.paused){l.paused=!1;for(var O=0;O<l.concurrency;O++)o++,x()}}function g(){return o===0&&l.length()===0}function y(O,I){var w=i.get();w.context=t,w.release=x,w.value=O,w.callback=I||at,w.errorHandler=a,o===l.concurrency||l.paused?s?(s.next=w,s=w):(n=w,s=w,l.saturated()):(o++,e.call(t,w.value,w.worked))}function b(O,I){var w=i.get();w.context=t,w.release=x,w.value=O,w.callback=I||at,o===l.concurrency||l.paused?n?(w.next=n,n=w):(n=w,s=w,l.saturated()):(o++,e.call(t,w.value,w.worked))}function x(O){O&&i.release(O);var I=n;I?l.paused?o--:(s===n&&(s=null),n=I.next,I.next=null,e.call(t,I.value,I.worked),s===null&&l.empty()):--o===0&&l.drain()}function k(){n=null,s=null,l.drain=at}function C(){n=null,s=null,l.drain(),l.drain=at}function T(O){a=O}}function at(){}function PA(){this.value=null,this.callback=at,this.next=null,this.release=at,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=at,t.errorHandler&&s(r,o),n.call(t.context,r,i),t.release(t)}}function IA(t,e,r){typeof t=="function"&&(r=e,e=t,t=null);function i(u,f){e.call(this,u).then(function(h){f(null,h)},f)}var n=Rm(t,i,r),s=n.push,o=n.unshift;return n.push=a,n.unshift=l,n.drained=c,n;function a(u){var f=new Promise(function(h,p){s(u,function(g,y){if(g){p(g);return}h(y)})});return f.catch(at),f}function l(u){var f=new Promise(function(h,p){o(u,function(g,y){if(g){p(g);return}h(y)})});return f.catch(at),f}function c(){var u=n.drain,f=new Promise(function(h){n.drain=function(){u(),h()}});return f}}Cl.exports=Rm;Cl.exports.promise=IA});var Is=$(xt=>{"use strict";Object.defineProperty(xt,"__esModule",{value:!0});xt.joinPathSegments=xt.replacePathSegmentSeparator=xt.isAppliedFilter=xt.isFatalError=void 0;function NA(t,e){return t.errorFilter===null?!0:!t.errorFilter(e)}xt.isFatalError=NA;function DA(t,e){return t===null||t(e)}xt.isAppliedFilter=DA;function MA(t,e){return t.split(/[/\\]/).join(e)}xt.replacePathSegmentSeparator=MA;function FA(t,e,r){return t===""?e:t.endsWith(r)?t+e:t+r+e}xt.joinPathSegments=FA});var Il=$(Pl=>{"use strict";Object.defineProperty(Pl,"__esModule",{value:!0});var BA=Is(),Ll=class{constructor(e,r){this._root=e,this._settings=r,this._root=BA.replacePathSegmentSeparator(e,r.pathSegmentSeparator)}};Pl.default=Ll});var Ml=$(Dl=>{"use strict";Object.defineProperty(Dl,"__esModule",{value:!0});var jA=require("events"),$A=Ps(),qA=xm(),Ns=Is(),HA=Il(),Nl=class extends HA.default{constructor(e,r){super(e,r),this._settings=r,this._scandir=$A.scandir,this._emitter=new jA.EventEmitter,this._queue=qA(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||!Ns.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=Ns.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),Ns.isAppliedFilter(this._settings.entryFilter,e)&&this._emitEntry(e),e.dirent.isDirectory()&&Ns.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,r===void 0?void 0:e.path)}_emitEntry(e){this._emitter.emit("entry",e)}};Dl.default=Nl});var Am=$(Bl=>{"use strict";Object.defineProperty(Bl,"__esModule",{value:!0});var UA=Ml(),Fl=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new UA.default(this._root,this._settings),this._storage=[]}read(e){this._reader.onError(r=>{GA(e,r)}),this._reader.onEntry(r=>{this._storage.push(r)}),this._reader.onEnd(()=>{zA(e,this._storage)}),this._reader.read()}};Bl.default=Fl;function GA(t,e){t(e)}function zA(t,e){t(null,e)}});var Om=$($l=>{"use strict";Object.defineProperty($l,"__esModule",{value:!0});var WA=require("stream"),YA=Ml(),jl=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new YA.default(this._root,this._settings),this._stream=new WA.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}};$l.default=jl});var Tm=$(Hl=>{"use strict";Object.defineProperty(Hl,"__esModule",{value:!0});var KA=Ps(),Ds=Is(),VA=Il(),ql=class extends VA.default{constructor(){super(...arguments),this._scandir=KA.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(Ds.isFatalError(this._settings,e))throw e}_handleEntry(e,r){let i=e.path;r!==void 0&&(e.path=Ds.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),Ds.isAppliedFilter(this._settings.entryFilter,e)&&this._pushToStorage(e),e.dirent.isDirectory()&&Ds.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,r===void 0?void 0:e.path)}_pushToStorage(e){this._storage.push(e)}};Hl.default=ql});var km=$(Gl=>{"use strict";Object.defineProperty(Gl,"__esModule",{value:!0});var ZA=Tm(),Ul=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new ZA.default(this._root,this._settings)}read(){return this._reader.read()}};Gl.default=Ul});var Cm=$(Wl=>{"use strict";Object.defineProperty(Wl,"__esModule",{value:!0});var XA=require("path"),JA=Ps(),zl=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,XA.sep),this.fsScandirSettings=new JA.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}};Wl.default=zl});var Fs=$(At=>{"use strict";Object.defineProperty(At,"__esModule",{value:!0});At.Settings=At.walkStream=At.walkSync=At.walk=void 0;var Lm=Am(),QA=Om(),eO=km(),Yl=Cm();At.Settings=Yl.default;function tO(t,e,r){if(typeof e=="function"){new Lm.default(t,Ms()).read(e);return}new Lm.default(t,Ms(e)).read(r)}At.walk=tO;function rO(t,e){let r=Ms(e);return new eO.default(t,r).read()}At.walkSync=rO;function iO(t,e){let r=Ms(e);return new QA.default(t,r).read()}At.walkStream=iO;function Ms(t={}){return t instanceof Yl.default?t:new Yl.default(t)}});var Bs=$(Vl=>{"use strict";Object.defineProperty(Vl,"__esModule",{value:!0});var nO=require("path"),sO=jr(),Pm=Ut(),Kl=class{constructor(e){this._settings=e,this._fsStatSettings=new sO.Settings({followSymbolicLink:this._settings.followSymbolicLinks,fs:this._settings.fs,throwErrorOnBrokenSymbolicLink:this._settings.followSymbolicLinks})}_getFullEntryPath(e){return nO.resolve(this._settings.cwd,e)}_makeEntry(e,r){let i={name:r,path:r,dirent:Pm.fs.createDirentFromStats(r,e)};return this._settings.stats&&(i.stats=e),i}_isFatalError(e){return!Pm.errno.isEnoentCodeError(e)&&!this._settings.suppressErrors}};Vl.default=Kl});var Jl=$(Xl=>{"use strict";Object.defineProperty(Xl,"__esModule",{value:!0});var oO=require("stream"),aO=jr(),lO=Fs(),cO=Bs(),Zl=class extends cO.default{constructor(){super(...arguments),this._walkStream=lO.walkStream,this._stat=aO.stat}dynamic(e,r){return this._walkStream(e,r)}static(e,r){let i=e.map(this._getFullEntryPath,this),n=new oO.PassThrough({objectMode:!0});n._write=(s,o,a)=>this._getEntry(i[s],e[s],r).then(l=>{l!==null&&r.entryFilter(l)&&n.push(l),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))})}};Xl.default=Zl});var Im=$(ec=>{"use strict";Object.defineProperty(ec,"__esModule",{value:!0});var uO=Fs(),hO=Bs(),fO=Jl(),Ql=class extends hO.default{constructor(){super(...arguments),this._walkAsync=uO.walk,this._readerStream=new fO.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))})}};ec.default=Ql});var Nm=$(rc=>{"use strict";Object.defineProperty(rc,"__esModule",{value:!0});var bi=Ut(),tc=class{constructor(e,r,i){this._patterns=e,this._settings=r,this._micromatchOptions=i,this._storage=[],this._fillStorage()}_fillStorage(){let e=bi.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 bi.pattern.getPatternParts(e,this._micromatchOptions).map(i=>bi.pattern.isDynamicPattern(i,this._settings)?{dynamic:!0,pattern:i,patternRe:bi.pattern.makeRe(i,this._micromatchOptions)}:{dynamic:!1,pattern:i})}_splitSegmentsIntoSections(e){return bi.array.splitWhen(e,r=>r.dynamic&&bi.pattern.hasGlobStar(r.pattern))}};rc.default=tc});var Dm=$(nc=>{"use strict";Object.defineProperty(nc,"__esModule",{value:!0});var pO=Nm(),ic=class extends pO.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((l,c)=>{let u=s.segments[c];return!!(u.dynamic&&u.patternRe.test(l)||!u.dynamic&&u.pattern===l)}))return!0}return!1}};nc.default=ic});var Mm=$(oc=>{"use strict";Object.defineProperty(oc,"__esModule",{value:!0});var js=Ut(),dO=Dm(),sc=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 dO.default(e,this._settings,this._micromatchOptions)}_getNegativePatternsRe(e){let r=e.filter(js.pattern.isAffectDepthOfReadingPattern);return js.pattern.convertPatternsToRe(r,this._micromatchOptions)}_filter(e,r,i,n){if(this._isSkippedByDeep(e,r.path)||this._isSkippedSymbolicLink(r))return!1;let s=js.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!js.pattern.matchAny(e,r)}};oc.default=sc});var Fm=$(lc=>{"use strict";Object.defineProperty(lc,"__esModule",{value:!0});var $r=Ut(),ac=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}};lc.default=ac});var Bm=$(uc=>{"use strict";Object.defineProperty(uc,"__esModule",{value:!0});var mO=Ut(),cc=class{constructor(e){this._settings=e}getFilter(){return e=>this._isNonFatalError(e)}_isNonFatalError(e){return mO.errno.isEnoentCodeError(e)||this._settings.suppressErrors}};uc.default=cc});var $m=$(fc=>{"use strict";Object.defineProperty(fc,"__esModule",{value:!0});var jm=Ut(),hc=class{constructor(e){this._settings=e}getTransformer(){return e=>this._transform(e)}_transform(e){let r=e.path;return this._settings.absolute&&(r=jm.path.makeAbsolute(this._settings.cwd,r),r=jm.path.unixify(r)),this._settings.markDirectories&&e.dirent.isDirectory()&&(r+="/"),this._settings.objectMode?Object.assign(Object.assign({},e),{path:r}):r}};fc.default=hc});var $s=$(dc=>{"use strict";Object.defineProperty(dc,"__esModule",{value:!0});var gO=require("path"),yO=Mm(),bO=Fm(),_O=Bm(),wO=$m(),pc=class{constructor(e){this._settings=e,this.errorFilter=new _O.default(this._settings),this.entryFilter=new bO.default(this._settings,this._getMicromatchOptions()),this.deepFilter=new yO.default(this._settings,this._getMicromatchOptions()),this.entryTransformer=new wO.default(this._settings)}_getRootDirectory(e){return gO.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}}};dc.default=pc});var qm=$(gc=>{"use strict";Object.defineProperty(gc,"__esModule",{value:!0});var SO=Im(),EO=$s(),mc=class extends EO.default{constructor(){super(...arguments),this._reader=new SO.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)}};gc.default=mc});var Hm=$(bc=>{"use strict";Object.defineProperty(bc,"__esModule",{value:!0});var vO=require("stream"),RO=Jl(),xO=$s(),yc=class extends xO.default{constructor(){super(...arguments),this._reader=new RO.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e),n=this.api(r,e,i),s=new vO.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)}};bc.default=yc});var Um=$(wc=>{"use strict";Object.defineProperty(wc,"__esModule",{value:!0});var AO=jr(),OO=Fs(),TO=Bs(),_c=class extends TO.default{constructor(){super(...arguments),this._walkSync=OO.walkSync,this._statSync=AO.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)}};wc.default=_c});var Gm=$(Ec=>{"use strict";Object.defineProperty(Ec,"__esModule",{value:!0});var kO=Um(),CO=$s(),Sc=class extends CO.default{constructor(){super(...arguments),this._reader=new kO.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)}};Ec.default=Sc});var zm=$(wi=>{"use strict";Object.defineProperty(wi,"__esModule",{value:!0});wi.DEFAULT_FILE_SYSTEM_ADAPTER=void 0;var _i=require("fs"),LO=require("os"),PO=Math.max(LO.cpus().length,1);wi.DEFAULT_FILE_SYSTEM_ADAPTER={lstat:_i.lstat,lstatSync:_i.lstatSync,stat:_i.stat,statSync:_i.statSync,readdir:_i.readdir,readdirSync:_i.readdirSync};var vc=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,PO),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({},wi.DEFAULT_FILE_SYSTEM_ADAPTER),e)}};wi.default=vc});var qs=$((jD,Km)=>{"use strict";var Wm=zd(),Ym=Yd(),IO=qm(),NO=Hm(),DO=Gm(),Rc=zm(),qr=Ut();async function xc(t,e){Si(t);let r=Ac(t,IO.default,e),i=await Promise.all(r);return qr.array.flatten(i)}(function(t){function e(o,a){Si(o);let l=Ac(o,DO.default,a);return qr.array.flatten(l)}t.sync=e;function r(o,a){Si(o);let l=Ac(o,NO.default,a);return qr.stream.merge(l)}t.stream=r;function i(o,a){Si(o);let l=Ym.transform([].concat(o)),c=new Rc.default(a);return Wm.generate(l,c)}t.generateTasks=i;function n(o,a){Si(o);let l=new Rc.default(a);return qr.pattern.isDynamicPattern(o,l)}t.isDynamicPattern=n;function s(o){return Si(o),qr.path.escape(o)}t.escapePath=s})(xc||(xc={}));function Ac(t,e,r){let i=Ym.transform([].concat(t)),n=new Rc.default(r),s=Wm.generate(i,n),o=new e(n);return s.map(o.read,o)}function Si(t){if(![].concat(t).every(i=>qr.string.isString(i)&&!qr.string.isEmpty(i)))throw new TypeError("Patterns must be a string (non empty) or an array of strings")}Km.exports=xc});var lg=$((UD,ag)=>{ag.exports=og;og.sync=XO;var ng=require("fs");function ZO(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 sg(t,e,r){return!t.isSymbolicLink()&&!t.isFile()?!1:ZO(e,r)}function og(t,e,r){ng.stat(t,function(i,n){r(i,i?!1:sg(n,t,e))})}function XO(t,e){return sg(ng.statSync(t),t,e)}});var pg=$((GD,fg)=>{fg.exports=ug;ug.sync=JO;var cg=require("fs");function ug(t,e,r){cg.stat(t,function(i,n){r(i,i?!1:hg(n,e))})}function JO(t,e){return hg(cg.statSync(t),e)}function hg(t,e){return t.isFile()&&QO(t,e)}function QO(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),l=parseInt("010",8),c=parseInt("001",8),u=a|l,f=r&c||r&l&&n===o||r&a&&i===s||r&u&&s===0;return f}});var mg=$((WD,dg)=>{var zD=require("fs"),Hs;process.platform==="win32"||global.TESTING_WINDOWS?Hs=lg():Hs=pg();dg.exports=Tc;Tc.sync=eT;function Tc(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){Tc(t,e||{},function(s,o){s?n(s):i(o)})})}Hs(t,e||{},function(i,n){i&&(i.code==="EACCES"||e&&e.ignoreErrors)&&(i=null,n=!1),r(i,n)})}function eT(t,e){try{return Hs.sync(t,e||{})}catch(r){if(e&&e.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var Eg=$((YD,Sg)=>{var vi=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",gg=require("path"),tT=vi?";":":",yg=mg(),bg=t=>Object.assign(new Error(`not found: ${t}`),{code:"ENOENT"}),_g=(t,e)=>{let r=e.colon||tT,i=t.match(/\//)||vi&&t.match(/\\/)?[""]:[...vi?[process.cwd()]:[],...(e.path||process.env.PATH||"").split(r)],n=vi?e.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",s=vi?n.split(r):[""];return vi&&t.indexOf(".")!==-1&&s[0]!==""&&s.unshift(""),{pathEnv:i,pathExt:s,pathExtExe:n}},wg=(t,e,r)=>{typeof e=="function"&&(r=e,e={}),e||(e={});let{pathEnv:i,pathExt:n,pathExtExe:s}=_g(t,e),o=[],a=c=>new Promise((u,f)=>{if(c===i.length)return e.all&&o.length?u(o):f(bg(t));let h=i[c],p=/^".*"$/.test(h)?h.slice(1,-1):h,g=gg.join(p,t),y=!p&&/^\.[\\\/]/.test(t)?t.slice(0,2)+g:g;u(l(y,c,0))}),l=(c,u,f)=>new Promise((h,p)=>{if(f===n.length)return h(a(u+1));let g=n[f];yg(c+g,{pathExt:s},(y,b)=>{if(!y&&b)if(e.all)o.push(c+g);else return h(c+g);return h(l(c,u,f+1))})});return r?a(0).then(c=>r(null,c),r):a(0)},rT=(t,e)=>{e=e||{};let{pathEnv:r,pathExt:i,pathExtExe:n}=_g(t,e),s=[];for(let o=0;o<r.length;o++){let a=r[o],l=/^".*"$/.test(a)?a.slice(1,-1):a,c=gg.join(l,t),u=!l&&/^\.[\\\/]/.test(t)?t.slice(0,2)+c:c;for(let f=0;f<i.length;f++){let h=u+i[f];try{if(yg.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 bg(t)};Sg.exports=wg;wg.sync=rT});var Cc=$((KD,kc)=>{"use strict";var vg=(t={})=>{let e=t.env||process.env;return(t.platform||process.platform)!=="win32"?"PATH":Object.keys(e).reverse().find(i=>i.toUpperCase()==="PATH")||"Path"};kc.exports=vg;kc.exports.default=vg});var Og=$((VD,Ag)=>{"use strict";var Rg=require("path"),iT=Eg(),nT=Cc();function xg(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=iT.sync(t.command,{path:r[nT({env:r})],pathExt:e?Rg.delimiter:void 0})}catch{}finally{s&&process.chdir(i)}return o&&(o=Rg.resolve(n?t.options.cwd:"",o)),o}function sT(t){return xg(t)||xg(t,!0)}Ag.exports=sT});var Tg=$((ZD,Pc)=>{"use strict";var Lc=/([()\][%!^"`<>&|;, *?])/g;function oT(t){return t=t.replace(Lc,"^$1"),t}function aT(t,e){return t=`${t}`,t=t.replace(/(\\*)"/g,'$1$1\\"'),t=t.replace(/(\\*)$/,"$1$1"),t=`"${t}"`,t=t.replace(Lc,"^$1"),e&&(t=t.replace(Lc,"^$1")),t}Pc.exports.command=oT;Pc.exports.argument=aT});var Cg=$((XD,kg)=>{"use strict";kg.exports=/^#!(.*)/});var Pg=$((JD,Lg)=>{"use strict";var lT=Cg();Lg.exports=(t="")=>{let e=t.match(lT);if(!e)return null;let[r,i]=e[0].replace(/#! ?/,"").split(" "),n=r.split("/").pop();return n==="env"?i:i?`${n} ${i}`:n}});var Ng=$((QD,Ig)=>{"use strict";var Ic=require("fs"),cT=Pg();function uT(t){let r=Buffer.alloc(150),i;try{i=Ic.openSync(t,"r"),Ic.readSync(i,r,0,150,0),Ic.closeSync(i)}catch{}return cT(r.toString())}Ig.exports=uT});var Bg=$((eM,Fg)=>{"use strict";var hT=require("path"),Dg=Og(),Mg=Tg(),fT=Ng(),pT=process.platform==="win32",dT=/\.(?:com|exe)$/i,mT=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function gT(t){t.file=Dg(t);let e=t.file&&fT(t.file);return e?(t.args.unshift(t.file),t.command=e,Dg(t)):t.file}function yT(t){if(!pT)return t;let e=gT(t),r=!dT.test(e);if(t.options.forceShell||r){let i=mT.test(e);t.command=hT.normalize(t.command),t.command=Mg.command(t.command),t.args=t.args.map(s=>Mg.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 bT(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:yT(i)}Fg.exports=bT});var qg=$((tM,$g)=>{"use strict";var Nc=process.platform==="win32";function Dc(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 _T(t,e){if(!Nc)return;let r=t.emit;t.emit=function(i,n){if(i==="exit"){let s=jg(n,e,"spawn");if(s)return r.call(t,"error",s)}return r.apply(t,arguments)}}function jg(t,e){return Nc&&t===1&&!e.file?Dc(e.original,"spawn"):null}function wT(t,e){return Nc&&t===1&&!e.file?Dc(e.original,"spawnSync"):null}$g.exports={hookChildProcess:_T,verifyENOENT:jg,verifyENOENTSync:wT,notFoundError:Dc}});var Gg=$((rM,Ri)=>{"use strict";var Hg=require("child_process"),Mc=Bg(),Fc=qg();function Ug(t,e,r){let i=Mc(t,e,r),n=Hg.spawn(i.command,i.args,i.options);return Fc.hookChildProcess(n,i),n}function ST(t,e,r){let i=Mc(t,e,r),n=Hg.spawnSync(i.command,i.args,i.options);return n.error=n.error||Fc.verifyENOENTSync(n.status,i),n}Ri.exports=Ug;Ri.exports.spawn=Ug;Ri.exports.sync=ST;Ri.exports._parse=Mc;Ri.exports._enoent=Fc});var Wg=$((iM,zg)=>{"use strict";zg.exports=t=>{let e=typeof t=="string"?`
|
2
|
+
"use strict";var tE=Object.create;var va=Object.defineProperty;var rE=Object.getOwnPropertyDescriptor;var iE=Object.getOwnPropertyNames;var nE=Object.getPrototypeOf,sE=Object.prototype.hasOwnProperty;var $=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),oE=(t,e)=>{for(var r in e)va(t,r,{get:e[r],enumerable:!0})},aE=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of iE(e))!sE.call(t,n)&&n!==r&&va(t,n,{get:()=>e[n],enumerable:!(i=rE(e,n))||i.enumerable});return t};var ie=(t,e,r)=>(r=t!=null?tE(nE(t)):{},aE(e||!t||!t.__esModule?va(r,"default",{value:t,enumerable:!0}):r,t));var Qh=$((DI,Bt)=>{function Ra(t){return Bt.exports=Ra=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},Bt.exports.__esModule=!0,Bt.exports.default=Bt.exports,Ra(t)}Bt.exports=Ra,Bt.exports.__esModule=!0,Bt.exports.default=Bt.exports});var rf=$((MI,jt)=>{var ef=Qh().default;function tf(){"use strict";jt.exports=tf=function(){return e},jt.exports.__esModule=!0,jt.exports.default=jt.exports;var t,e={},r=Object.prototype,i=r.hasOwnProperty,n=Object.defineProperty||function(A,L,j){A[L]=j.value},s=typeof Symbol=="function"?Symbol:{},o=s.iterator||"@@iterator",a=s.asyncIterator||"@@asyncIterator",l=s.toStringTag||"@@toStringTag";function c(A,L,j){return Object.defineProperty(A,L,{value:j,enumerable:!0,configurable:!0,writable:!0}),A[L]}try{c({},"")}catch{c=function(j,z,D){return j[z]=D}}function u(A,L,j,z){var D=L&&L.prototype instanceof x?L:x,d=Object.create(D.prototype),m=new K(z||[]);return n(d,"_invoke",{value:q(A,j,m)}),d}function f(A,L,j){try{return{type:"normal",arg:A.call(L,j)}}catch(z){return{type:"throw",arg:z}}}e.wrap=u;var h="suspendedStart",p="suspendedYield",g="executing",y="completed",b={};function x(){}function k(){}function C(){}var T={};c(T,o,function(){return this});var O=Object.getPrototypeOf,I=O&&O(O(N([])));I&&I!==r&&i.call(I,o)&&(T=I);var w=C.prototype=x.prototype=Object.create(T);function v(A){["next","throw","return"].forEach(function(L){c(A,L,function(j){return this._invoke(L,j)})})}function F(A,L){function j(D,d,m,_){var R=f(A[D],A,d);if(R.type!=="throw"){var E=R.arg,M=E.value;return M&&ef(M)=="object"&&i.call(M,"__await")?L.resolve(M.__await).then(function(B){j("next",B,m,_)},function(B){j("throw",B,m,_)}):L.resolve(M).then(function(B){E.value=B,m(E)},function(B){return j("throw",B,m,_)})}_(R.arg)}var z;n(this,"_invoke",{value:function(d,m){function _(){return new L(function(R,E){j(d,m,R,E)})}return z=z?z.then(_,_):_()}})}function q(A,L,j){var z=h;return function(D,d){if(z===g)throw new Error("Generator is already running");if(z===y){if(D==="throw")throw d;return{value:t,done:!0}}for(j.method=D,j.arg=d;;){var m=j.delegate;if(m){var _=P(m,j);if(_){if(_===b)continue;return _}}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 R=f(A,L,j);if(R.type==="normal"){if(z=j.done?y:p,R.arg===b)continue;return{value:R.arg,done:j.done}}R.type==="throw"&&(z=y,j.method="throw",j.arg=R.arg)}}}function P(A,L){var j=L.method,z=A.iterator[j];if(z===t)return L.delegate=null,j==="throw"&&A.iterator.return&&(L.method="return",L.arg=t,P(A,L),L.method==="throw")||j!=="return"&&(L.method="throw",L.arg=new TypeError("The iterator does not provide a '"+j+"' method")),b;var D=f(z,A.iterator,L.arg);if(D.type==="throw")return L.method="throw",L.arg=D.arg,L.delegate=null,b;var d=D.arg;return d?d.done?(L[A.resultName]=d.value,L.next=A.nextLoc,L.method!=="return"&&(L.method="next",L.arg=t),L.delegate=null,b):d:(L.method="throw",L.arg=new TypeError("iterator result is not an object"),L.delegate=null,b)}function U(A){var L={tryLoc:A[0]};1 in A&&(L.catchLoc=A[1]),2 in A&&(L.finallyLoc=A[2],L.afterLoc=A[3]),this.tryEntries.push(L)}function V(A){var L=A.completion||{};L.type="normal",delete L.arg,A.completion=L}function K(A){this.tryEntries=[{tryLoc:"root"}],A.forEach(U,this),this.reset(!0)}function N(A){if(A||A===""){var L=A[o];if(L)return L.call(A);if(typeof A.next=="function")return A;if(!isNaN(A.length)){var j=-1,z=function D(){for(;++j<A.length;)if(i.call(A,j))return D.value=A[j],D.done=!1,D;return D.value=t,D.done=!0,D};return z.next=z}}throw new TypeError(ef(A)+" is not iterable")}return k.prototype=C,n(w,"constructor",{value:C,configurable:!0}),n(C,"constructor",{value:k,configurable:!0}),k.displayName=c(C,l,"GeneratorFunction"),e.isGeneratorFunction=function(A){var L=typeof A=="function"&&A.constructor;return!!L&&(L===k||(L.displayName||L.name)==="GeneratorFunction")},e.mark=function(A){return Object.setPrototypeOf?Object.setPrototypeOf(A,C):(A.__proto__=C,c(A,l,"GeneratorFunction")),A.prototype=Object.create(w),A},e.awrap=function(A){return{__await:A}},v(F.prototype),c(F.prototype,a,function(){return this}),e.AsyncIterator=F,e.async=function(A,L,j,z,D){D===void 0&&(D=Promise);var d=new F(u(A,L,j,z),D);return e.isGeneratorFunction(L)?d:d.next().then(function(m){return m.done?m.value:d.next()})},v(w),c(w,l,"Generator"),c(w,o,function(){return this}),c(w,"toString",function(){return"[object Generator]"}),e.keys=function(A){var L=Object(A),j=[];for(var z in L)j.push(z);return j.reverse(),function D(){for(;j.length;){var d=j.pop();if(d in L)return D.value=d,D.done=!1,D}return D.done=!0,D}},e.values=N,K.prototype={constructor:K,reset:function(L){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),!L)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 L=this.tryEntries[0].completion;if(L.type==="throw")throw L.arg;return this.rval},dispatchException:function(L){if(this.done)throw L;var j=this;function z(E,M){return m.type="throw",m.arg=L,j.next=E,M&&(j.method="next",j.arg=t),!!M}for(var D=this.tryEntries.length-1;D>=0;--D){var d=this.tryEntries[D],m=d.completion;if(d.tryLoc==="root")return z("end");if(d.tryLoc<=this.prev){var _=i.call(d,"catchLoc"),R=i.call(d,"finallyLoc");if(_&&R){if(this.prev<d.catchLoc)return z(d.catchLoc,!0);if(this.prev<d.finallyLoc)return z(d.finallyLoc)}else if(_){if(this.prev<d.catchLoc)return z(d.catchLoc,!0)}else{if(!R)throw new Error("try statement without catch or finally");if(this.prev<d.finallyLoc)return z(d.finallyLoc)}}}},abrupt:function(L,j){for(var z=this.tryEntries.length-1;z>=0;--z){var D=this.tryEntries[z];if(D.tryLoc<=this.prev&&i.call(D,"finallyLoc")&&this.prev<D.finallyLoc){var d=D;break}}d&&(L==="break"||L==="continue")&&d.tryLoc<=j&&j<=d.finallyLoc&&(d=null);var m=d?d.completion:{};return m.type=L,m.arg=j,d?(this.method="next",this.next=d.finallyLoc,b):this.complete(m)},complete:function(L,j){if(L.type==="throw")throw L.arg;return L.type==="break"||L.type==="continue"?this.next=L.arg:L.type==="return"?(this.rval=this.arg=L.arg,this.method="return",this.next="end"):L.type==="normal"&&j&&(this.next=j),b},finish:function(L){for(var j=this.tryEntries.length-1;j>=0;--j){var z=this.tryEntries[j];if(z.finallyLoc===L)return this.complete(z.completion,z.afterLoc),V(z),b}},catch:function(L){for(var j=this.tryEntries.length-1;j>=0;--j){var z=this.tryEntries[j];if(z.tryLoc===L){var D=z.completion;if(D.type==="throw"){var d=D.arg;V(z)}return d}}throw new Error("illegal catch attempt")},delegateYield:function(L,j,z){return this.delegate={iterator:N(L),resultName:j,nextLoc:z},this.method==="next"&&(this.arg=t),b}},e}jt.exports=tf,jt.exports.__esModule=!0,jt.exports.default=jt.exports});var sf=$((FI,nf)=>{var os=rf()();nf.exports=os;try{regeneratorRuntime=os}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=os:Function("r","regeneratorRuntime = r")(os)}});var cp=$(fi=>{"use strict";Object.defineProperty(fi,"__esModule",{value:!0});fi.splitWhen=fi.flatten=void 0;function N0(t){return t.reduce((e,r)=>[].concat(e,r),[])}fi.flatten=N0;function D0(t,e){let r=[[]],i=0;for(let n of t)e(n)?(i++,r[i]=[]):r[i].push(n);return r}fi.splitWhen=D0});var up=$(ps=>{"use strict";Object.defineProperty(ps,"__esModule",{value:!0});ps.isEnoentCodeError=void 0;function M0(t){return t.code==="ENOENT"}ps.isEnoentCodeError=M0});var hp=$(ds=>{"use strict";Object.defineProperty(ds,"__esModule",{value:!0});ds.createDirentFromStats=void 0;var Wa=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 F0(t,e){return new Wa(t,e)}ds.createDirentFromStats=F0});var fp=$(Et=>{"use strict";Object.defineProperty(Et,"__esModule",{value:!0});Et.removeLeadingDotSegment=Et.escape=Et.makeAbsolute=Et.unixify=void 0;var B0=require("path"),j0=2,$0=/(\\?)([()*?[\]{|}]|^!|[!+@](?=\())/g;function q0(t){return t.replace(/\\/g,"/")}Et.unixify=q0;function H0(t,e){return B0.resolve(t,e)}Et.makeAbsolute=H0;function U0(t){return t.replace($0,"\\$2")}Et.escape=U0;function G0(t){if(t.charAt(0)==="."){let e=t.charAt(1);if(e==="/"||e==="\\")return t.slice(j0)}return t}Et.removeLeadingDotSegment=G0});var dp=$((RN,pp)=>{pp.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 yp=$((xN,gp)=>{var z0=dp(),mp={"{":"}","(":")","[":"]"},W0=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 l=mp[a];if(l){var c=t.indexOf(l,e);c!==-1&&(e=c+1)}if(t[e]==="!")return!0}else e++}return!1},Y0=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=mp[r];if(i){var n=t.indexOf(i,e);n!==-1&&(e=n+1)}if(t[e]==="!")return!0}else e++}return!1};gp.exports=function(e,r){if(typeof e!="string"||e==="")return!1;if(z0(e))return!0;var i=W0;return r&&r.strict===!1&&(i=Y0),i(e)}});var _p=$((AN,bp)=>{"use strict";var V0=yp(),K0=require("path").posix.dirname,Z0=require("os").platform()==="win32",Ya="/",X0=/\\/g,J0=/[\{\[].*[\}\]]$/,Q0=/(^|[^\\])([\{\[]|\([^\)]+$)/,eR=/\\([\!\*\?\|\[\]\(\)\{\}])/g;bp.exports=function(e,r){var i=Object.assign({flipBackslashes:!0},r);i.flipBackslashes&&Z0&&e.indexOf(Ya)<0&&(e=e.replace(X0,Ya)),J0.test(e)&&(e+=Ya),e+="a";do e=K0(e);while(V0(e)||Q0.test(e));return e.replace(eR,"$1")}});var ms=$(ot=>{"use strict";ot.isInteger=t=>typeof t=="number"?Number.isInteger(t):typeof t=="string"&&t.trim()!==""?Number.isInteger(Number(t)):!1;ot.find=(t,e)=>t.nodes.find(r=>r.type===e);ot.exceedsLimit=(t,e,r=1,i)=>i===!1||!ot.isInteger(t)||!ot.isInteger(e)?!1:(Number(e)-Number(t))/Number(r)>=i;ot.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)};ot.encloseBrace=t=>t.type!=="brace"||t.commas>>0+t.ranges>>0?!1:(t.invalid=!0,!0);ot.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;ot.isOpenOrClose=t=>t.type==="open"||t.type==="close"?!0:t.open===!0||t.close===!0;ot.reduce=t=>t.reduce((e,r)=>(r.type==="text"&&e.push(r.value),r.type==="range"&&(r.type="text"),e),[]);ot.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 gs=$((TN,Sp)=>{"use strict";var wp=ms();Sp.exports=(t,e={})=>{let r=(i,n={})=>{let s=e.escapeInvalid&&wp.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a="";if(i.value)return(s||o)&&wp.isOpenOrClose(i)?"\\"+i.value:i.value;if(i.value)return i.value;if(i.nodes)for(let l of i.nodes)a+=r(l);return a};return r(t)}});var vp=$((kN,Ep)=>{"use strict";Ep.exports=function(t){return typeof t=="number"?t-t===0:typeof t=="string"&&t.trim()!==""?Number.isFinite?Number.isFinite(+t):isFinite(+t):!1}});var Pp=$((CN,Lp)=>{"use strict";var Rp=vp(),Fr=(t,e,r)=>{if(Rp(t)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(e===void 0||t===e)return String(t);if(Rp(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),l=t+":"+e+"="+n+s+o+a;if(Fr.cache.hasOwnProperty(l))return Fr.cache[l].result;let c=Math.min(t,e),u=Math.max(t,e);if(Math.abs(c-u)===1){let y=t+"|"+e;return i.capture?`(${y})`:i.wrap===!1?y:`(?:${y})`}let f=Cp(t)||Cp(e),h={min:t,max:e,a:c,b:u},p=[],g=[];if(f&&(h.isPadded=f,h.maxLen=String(h.max).length),c<0){let y=u<0?Math.abs(u):1;g=xp(y,Math.abs(c),h,i),c=h.a=0}return u>=0&&(p=xp(c,u,h,i)),h.negatives=g,h.positives=p,h.result=tR(g,p,i),i.capture===!0?h.result=`(${h.result})`:i.wrap!==!1&&p.length+g.length>1&&(h.result=`(?:${h.result})`),Fr.cache[l]=h,h.result};function tR(t,e,r){let i=Va(t,e,"-",!1,r)||[],n=Va(e,t,"",!1,r)||[],s=Va(t,e,"-?",!0,r)||[];return i.concat(s).concat(n).join("|")}function rR(t,e){let r=1,i=1,n=Op(t,r),s=new Set([e]);for(;t<=n&&n<=e;)s.add(n),r+=1,n=Op(t,r);for(n=Tp(e+1,i)-1;t<n&&n<=e;)s.add(n),i+=1,n=Tp(e+1,i)-1;return s=[...s],s.sort(sR),s}function iR(t,e,r){if(t===e)return{pattern:t,count:[],digits:0};let i=nR(t,e),n=i.length,s="",o=0;for(let a=0;a<n;a++){let[l,c]=i[a];l===c?s+=l:l!=="0"||c!=="9"?s+=oR(l,c,r):o++}return o&&(s+=r.shorthand===!0?"\\d":"[0-9]"),{pattern:s,count:[o],digits:n}}function xp(t,e,r,i){let n=rR(t,e),s=[],o=t,a;for(let l=0;l<n.length;l++){let c=n[l],u=iR(String(o),String(c),i),f="";if(!r.isPadded&&a&&a.pattern===u.pattern){a.count.length>1&&a.count.pop(),a.count.push(u.count[0]),a.string=a.pattern+kp(a.count),o=c+1;continue}r.isPadded&&(f=aR(c,r,i)),u.string=f+u.pattern+kp(u.count),s.push(u),o=c+1,a=u}return s}function Va(t,e,r,i,n){let s=[];for(let o of t){let{string:a}=o;!i&&!Ap(e,"string",a)&&s.push(r+a),i&&Ap(e,"string",a)&&s.push(r+a)}return s}function nR(t,e){let r=[];for(let i=0;i<t.length;i++)r.push([t[i],e[i]]);return r}function sR(t,e){return t>e?1:e>t?-1:0}function Ap(t,e,r){return t.some(i=>i[e]===r)}function Op(t,e){return Number(String(t).slice(0,-e)+"9".repeat(e))}function Tp(t,e){return t-t%Math.pow(10,e)}function kp(t){let[e=0,r=""]=t;return r||e>1?`{${e+(r?","+r:"")}}`:""}function oR(t,e,r){return`[${t}${e-t===1?"":"-"}${e}]`}function Cp(t){return/^-?(0+)\d/.test(t)}function aR(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}}`}}Fr.cache={};Fr.clearCache=()=>Fr.cache={};Lp.exports=Fr});var Xa=$((LN,$p)=>{"use strict";var lR=require("util"),Dp=Pp(),Ip=t=>t!==null&&typeof t=="object"&&!Array.isArray(t),cR=t=>e=>t===!0?Number(e):String(e),Ka=t=>typeof t=="number"||typeof t=="string"&&t!=="",_n=t=>Number.isInteger(+t),Za=t=>{let e=`${t}`,r=-1;if(e[0]==="-"&&(e=e.slice(1)),e==="0")return!1;for(;e[++r]==="0";);return r>0},uR=(t,e,r)=>typeof t=="string"||typeof e=="string"?!0:r.stringify===!0,hR=(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},Np=(t,e)=>{let r=t[0]==="-"?"-":"";for(r&&(t=t.slice(1),e--);t.length<e;)t="0"+t;return r?"-"+t:t},fR=(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},Mp=(t,e,r,i)=>{if(r)return Dp(t,e,{wrap:!1,...i});let n=String.fromCharCode(t);if(t===e)return n;let s=String.fromCharCode(e);return`[${n}-${s}]`},Fp=(t,e,r)=>{if(Array.isArray(t)){let i=r.wrap===!0,n=r.capture?"":"?:";return i?`(${n}${t.join("|")})`:t.join("|")}return Dp(t,e,r)},Bp=(...t)=>new RangeError("Invalid range arguments: "+lR.inspect(...t)),jp=(t,e,r)=>{if(r.strictRanges===!0)throw Bp([t,e]);return[]},pR=(t,e)=>{if(e.strictRanges===!0)throw new TypeError(`Expected step "${t}" to be a number`);return[]},dR=(t,e,r=1,i={})=>{let n=Number(t),s=Number(e);if(!Number.isInteger(n)||!Number.isInteger(s)){if(i.strictRanges===!0)throw Bp([t,e]);return[]}n===0&&(n=0),s===0&&(s=0);let o=n>s,a=String(t),l=String(e),c=String(r);r=Math.max(Math.abs(r),1);let u=Za(a)||Za(l)||Za(c),f=u?Math.max(a.length,l.length,c.length):0,h=u===!1&&uR(t,e,i)===!1,p=i.transform||cR(h);if(i.toRegex&&r===1)return Mp(Np(t,f),Np(e,f),!0,i);let g={negatives:[],positives:[]},y=k=>g[k<0?"negatives":"positives"].push(Math.abs(k)),b=[],x=0;for(;o?n>=s:n<=s;)i.toRegex===!0&&r>1?y(n):b.push(hR(p(n,x),f,h)),n=o?n-r:n+r,x++;return i.toRegex===!0?r>1?fR(g,i):Fp(b,null,{wrap:!1,...i}):b},mR=(t,e,r=1,i={})=>{if(!_n(t)&&t.length>1||!_n(e)&&e.length>1)return jp(t,e,i);let n=i.transform||(h=>String.fromCharCode(h)),s=`${t}`.charCodeAt(0),o=`${e}`.charCodeAt(0),a=s>o,l=Math.min(s,o),c=Math.max(s,o);if(i.toRegex&&r===1)return Mp(l,c,!1,i);let u=[],f=0;for(;a?s>=o:s<=o;)u.push(n(s,f)),s=a?s-r:s+r,f++;return i.toRegex===!0?Fp(u,null,{wrap:!1,options:i}):u},ys=(t,e,r,i={})=>{if(e==null&&Ka(t))return[t];if(!Ka(t)||!Ka(e))return jp(t,e,i);if(typeof r=="function")return ys(t,e,1,{transform:r});if(Ip(r))return ys(t,e,0,r);let n={...i};return n.capture===!0&&(n.wrap=!0),r=r||n.step||1,_n(r)?_n(t)&&_n(e)?dR(t,e,r,n):mR(t,e,Math.max(Math.abs(r),1),n):r!=null&&!Ip(r)?pR(r,n):ys(t,e,1,r)};$p.exports=ys});var Up=$((PN,Hp)=>{"use strict";var gR=Xa(),qp=ms(),yR=(t,e={})=>{let r=(i,n={})=>{let s=qp.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a=s===!0||o===!0,l=e.escapeInvalid===!0?"\\":"",c="";if(i.isOpen===!0||i.isClose===!0)return l+i.value;if(i.type==="open")return a?l+i.value:"(";if(i.type==="close")return a?l+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 u=qp.reduce(i.nodes),f=gR(...u,{...e,wrap:!1,toRegex:!0});if(f.length!==0)return u.length>1&&f.length>1?`(${f})`:f}if(i.nodes)for(let u of i.nodes)c+=r(u,i);return c};return r(t)};Hp.exports=yR});var Wp=$((IN,zp)=>{"use strict";var bR=Xa(),Gp=gs(),pi=ms(),Br=(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(Br(s,e,r));else for(let s of e)r===!0&&typeof s=="string"&&(s=`{${s}}`),i.push(Array.isArray(s)?Br(n,s,r):n+s);return pi.flatten(i)},_R=(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(Br(a.pop(),Gp(n,e)));return}if(n.type==="brace"&&n.invalid!==!0&&n.nodes.length===2){a.push(Br(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=bR(...f,e);h.length===0&&(h=Gp(n,e)),a.push(Br(a.pop(),h)),n.nodes=[];return}let l=pi.encloseBrace(n),c=n.queue,u=n;for(;u.type!=="brace"&&u.type!=="root"&&u.parent;)u=u.parent,c=u.queue;for(let f=0;f<n.nodes.length;f++){let h=n.nodes[f];if(h.type==="comma"&&n.type==="brace"){f===1&&c.push(""),c.push("");continue}if(h.type==="close"){a.push(Br(a.pop(),c,l));continue}if(h.value&&h.type!=="open"){c.push(Br(c.pop(),h.value));continue}h.nodes&&i(h,n)}return c};return pi.flatten(i(t))};zp.exports=_R});var Vp=$((NN,Yp)=>{"use strict";Yp.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 Qp=$((DN,Jp)=>{"use strict";var wR=gs(),{MAX_LENGTH:Kp,CHAR_BACKSLASH:Ja,CHAR_BACKTICK:SR,CHAR_COMMA:ER,CHAR_DOT:vR,CHAR_LEFT_PARENTHESES:RR,CHAR_RIGHT_PARENTHESES:xR,CHAR_LEFT_CURLY_BRACE:AR,CHAR_RIGHT_CURLY_BRACE:OR,CHAR_LEFT_SQUARE_BRACKET:Zp,CHAR_RIGHT_SQUARE_BRACKET:Xp,CHAR_DOUBLE_QUOTE:TR,CHAR_SINGLE_QUOTE:kR,CHAR_NO_BREAK_SPACE:CR,CHAR_ZERO_WIDTH_NOBREAK_SPACE:LR}=Vp(),PR=(t,e={})=>{if(typeof t!="string")throw new TypeError("Expected a string");let r=e||{},i=typeof r.maxLength=="number"?Math.min(Kp,r.maxLength):Kp;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,l=0,c=t.length,u=0,f=0,h,p={},g=()=>t[u++],y=b=>{if(b.type==="text"&&a.type==="dot"&&(a.type="text"),a&&a.type==="text"&&b.type==="text"){a.value+=b.value;return}return o.nodes.push(b),b.parent=o,b.prev=a,a=b,b};for(y({type:"bos"});u<c;)if(o=s[s.length-1],h=g(),!(h===LR||h===CR)){if(h===Ja){y({type:"text",value:(e.keepEscaping?h:"")+g()});continue}if(h===Xp){y({type:"text",value:"\\"+h});continue}if(h===Zp){l++;let b=!0,x;for(;u<c&&(x=g());){if(h+=x,x===Zp){l++;continue}if(x===Ja){h+=g();continue}if(x===Xp&&(l--,l===0))break}y({type:"text",value:h});continue}if(h===RR){o=y({type:"paren",nodes:[]}),s.push(o),y({type:"text",value:h});continue}if(h===xR){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===TR||h===kR||h===SR){let b=h,x;for(e.keepQuotes!==!0&&(h="");u<c&&(x=g());){if(x===Ja){h+=x+g();continue}if(x===b){e.keepQuotes===!0&&(h+=x);break}h+=x}y({type:"text",value:h});continue}if(h===AR){f++;let x={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(x),s.push(o),y({type:"open",value:h});continue}if(h===OR){if(o.type!=="brace"){y({type:"text",value:h});continue}let b="close";o=s.pop(),o.close=!0,y({type:b,value:h}),f--,o=s[s.length-1];continue}if(h===ER&&f>0){if(o.ranges>0){o.ranges=0;let b=o.nodes.shift();o.nodes=[b,{type:"text",value:wR(o)}]}y({type:"comma",value:h}),o.commas++;continue}if(h===vR&&f>0&&o.commas===0){let b=o.nodes;if(f===0||b.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"){b.pop();let x=b[b.length-1];x.value+=a.value+h,a=x,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(k=>{k.nodes||(k.type==="open"&&(k.isOpen=!0),k.type==="close"&&(k.isClose=!0),k.nodes||(k.type="text"),k.invalid=!0)});let b=s[s.length-1],x=b.nodes.indexOf(o);b.nodes.splice(x,1,...o.nodes)}while(s.length>0);return y({type:"eos"}),n};Jp.exports=PR});var rd=$((MN,td)=>{"use strict";var ed=gs(),IR=Up(),NR=Wp(),DR=Qp(),Qe=(t,e={})=>{let r=[];if(Array.isArray(t))for(let i of t){let n=Qe.create(i,e);Array.isArray(n)?r.push(...n):r.push(n)}else r=[].concat(Qe.create(t,e));return e&&e.expand===!0&&e.nodupes===!0&&(r=[...new Set(r)]),r};Qe.parse=(t,e={})=>DR(t,e);Qe.stringify=(t,e={})=>ed(typeof t=="string"?Qe.parse(t,e):t,e);Qe.compile=(t,e={})=>(typeof t=="string"&&(t=Qe.parse(t,e)),IR(t,e));Qe.expand=(t,e={})=>{typeof t=="string"&&(t=Qe.parse(t,e));let r=NR(t,e);return e.noempty===!0&&(r=r.filter(Boolean)),e.nodupes===!0&&(r=[...new Set(r)]),r};Qe.create=(t,e={})=>t===""||t.length<3?[t]:e.expand!==!0?Qe.compile(t,e):Qe.expand(t,e);td.exports=Qe});var wn=$((FN,ad)=>{"use strict";var MR=require("path"),vt="\\\\/",id=`[^${vt}]`,Ht="\\.",FR="\\+",BR="\\?",bs="\\/",jR="(?=.)",nd="[^/]",Qa=`(?:${bs}|$)`,sd=`(?:^|${bs})`,el=`${Ht}{1,2}${Qa}`,$R=`(?!${Ht})`,qR=`(?!${sd}${el})`,HR=`(?!${Ht}{0,1}${Qa})`,UR=`(?!${el})`,GR=`[^.${bs}]`,zR=`${nd}*?`,od={DOT_LITERAL:Ht,PLUS_LITERAL:FR,QMARK_LITERAL:BR,SLASH_LITERAL:bs,ONE_CHAR:jR,QMARK:nd,END_ANCHOR:Qa,DOTS_SLASH:el,NO_DOT:$R,NO_DOTS:qR,NO_DOT_SLASH:HR,NO_DOTS_SLASH:UR,QMARK_NO_DOT:GR,STAR:zR,START_ANCHOR:sd},WR={...od,SLASH_LITERAL:`[${vt}]`,QMARK:id,STAR:`${id}*?`,DOTS_SLASH:`${Ht}{1,2}(?:[${vt}]|$)`,NO_DOT:`(?!${Ht})`,NO_DOTS:`(?!(?:^|[${vt}])${Ht}{1,2}(?:[${vt}]|$))`,NO_DOT_SLASH:`(?!${Ht}{0,1}(?:[${vt}]|$))`,NO_DOTS_SLASH:`(?!${Ht}{1,2}(?:[${vt}]|$))`,QMARK_NO_DOT:`[^.${vt}]`,START_ANCHOR:`(?:^|[${vt}])`,END_ANCHOR:`(?:[${vt}]|$)`},YR={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"};ad.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:YR,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:MR.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?WR:od}}});var Sn=$(ze=>{"use strict";var VR=require("path"),KR=process.platform==="win32",{REGEX_BACKSLASH:ZR,REGEX_REMOVE_BACKSLASH:XR,REGEX_SPECIAL_CHARS:JR,REGEX_SPECIAL_CHARS_GLOBAL:QR}=wn();ze.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);ze.hasRegexChars=t=>JR.test(t);ze.isRegexChar=t=>t.length===1&&ze.hasRegexChars(t);ze.escapeRegex=t=>t.replace(QR,"\\$1");ze.toPosixSlashes=t=>t.replace(ZR,"/");ze.removeBackslashes=t=>t.replace(XR,e=>e==="\\"?"":e);ze.supportsLookbehinds=()=>{let t=process.version.slice(1).split(".").map(Number);return t.length===3&&t[0]>=9||t[0]===8&&t[1]>=10};ze.isWindows=t=>t&&typeof t.windows=="boolean"?t.windows:KR===!0||VR.sep==="\\";ze.escapeLast=(t,e,r)=>{let i=t.lastIndexOf(e,r);return i===-1?t:t[i-1]==="\\"?ze.escapeLast(t,e,i-1):`${t.slice(0,i)}\\${t.slice(i)}`};ze.removePrefix=(t,e={})=>{let r=t;return r.startsWith("./")&&(r=r.slice(2),e.prefix="./"),r};ze.wrapOutput=(t,e={},r={})=>{let i=r.contains?"":"^",n=r.contains?"":"$",s=`${i}(?:${t})${n}`;return e.negated===!0&&(s=`(?:^(?!${s}).*$)`),s}});var md=$((jN,dd)=>{"use strict";var ld=Sn(),{CHAR_ASTERISK:tl,CHAR_AT:ex,CHAR_BACKWARD_SLASH:En,CHAR_COMMA:tx,CHAR_DOT:rl,CHAR_EXCLAMATION_MARK:il,CHAR_FORWARD_SLASH:pd,CHAR_LEFT_CURLY_BRACE:nl,CHAR_LEFT_PARENTHESES:sl,CHAR_LEFT_SQUARE_BRACKET:rx,CHAR_PLUS:ix,CHAR_QUESTION_MARK:cd,CHAR_RIGHT_CURLY_BRACE:nx,CHAR_RIGHT_PARENTHESES:ud,CHAR_RIGHT_SQUARE_BRACKET:sx}=wn(),hd=t=>t===pd||t===En,fd=t=>{t.isPrefix!==!0&&(t.depth=t.isGlobstar?1/0:1)},ox=(t,e)=>{let r=e||{},i=t.length-1,n=r.parts===!0||r.scanToEnd===!0,s=[],o=[],a=[],l=t,c=-1,u=0,f=0,h=!1,p=!1,g=!1,y=!1,b=!1,x=!1,k=!1,C=!1,T=!1,O=!1,I=0,w,v,F={value:"",depth:0,isGlob:!1},q=()=>c>=i,P=()=>l.charCodeAt(c+1),U=()=>(w=v,l.charCodeAt(++c));for(;c<i;){v=U();let L;if(v===En){k=F.backslashes=!0,v=U(),v===nl&&(x=!0);continue}if(x===!0||v===nl){for(I++;q()!==!0&&(v=U());){if(v===En){k=F.backslashes=!0,U();continue}if(v===nl){I++;continue}if(x!==!0&&v===rl&&(v=U())===rl){if(h=F.isBrace=!0,g=F.isGlob=!0,O=!0,n===!0)continue;break}if(x!==!0&&v===tx){if(h=F.isBrace=!0,g=F.isGlob=!0,O=!0,n===!0)continue;break}if(v===nx&&(I--,I===0)){x=!1,h=F.isBrace=!0,O=!0;break}}if(n===!0)continue;break}if(v===pd){if(s.push(c),o.push(F),F={value:"",depth:0,isGlob:!1},O===!0)continue;if(w===rl&&c===u+1){u+=2;continue}f=c+1;continue}if(r.noext!==!0&&(v===ix||v===ex||v===tl||v===cd||v===il)===!0&&P()===sl){if(g=F.isGlob=!0,y=F.isExtglob=!0,O=!0,v===il&&c===u&&(T=!0),n===!0){for(;q()!==!0&&(v=U());){if(v===En){k=F.backslashes=!0,v=U();continue}if(v===ud){g=F.isGlob=!0,O=!0;break}}continue}break}if(v===tl){if(w===tl&&(b=F.isGlobstar=!0),g=F.isGlob=!0,O=!0,n===!0)continue;break}if(v===cd){if(g=F.isGlob=!0,O=!0,n===!0)continue;break}if(v===rx){for(;q()!==!0&&(L=U());){if(L===En){k=F.backslashes=!0,U();continue}if(L===sx){p=F.isBracket=!0,g=F.isGlob=!0,O=!0;break}}if(n===!0)continue;break}if(r.nonegate!==!0&&v===il&&c===u){C=F.negated=!0,u++;continue}if(r.noparen!==!0&&v===sl){if(g=F.isGlob=!0,n===!0){for(;q()!==!0&&(v=U());){if(v===sl){k=F.backslashes=!0,v=U();continue}if(v===ud){O=!0;break}}continue}break}if(g===!0){if(O=!0,n===!0)continue;break}}r.noext===!0&&(y=!1,g=!1);let V=l,K="",N="";u>0&&(K=l.slice(0,u),l=l.slice(u),f-=u),V&&g===!0&&f>0?(V=l.slice(0,f),N=l.slice(f)):g===!0?(V="",N=l):V=l,V&&V!==""&&V!=="/"&&V!==l&&hd(V.charCodeAt(V.length-1))&&(V=V.slice(0,-1)),r.unescape===!0&&(N&&(N=ld.removeBackslashes(N)),V&&k===!0&&(V=ld.removeBackslashes(V)));let A={prefix:K,input:t,start:u,base:V,glob:N,isBrace:h,isBracket:p,isGlob:g,isExtglob:y,isGlobstar:b,negated:C,negatedExtglob:T};if(r.tokens===!0&&(A.maxDepth=0,hd(v)||o.push(F),A.tokens=o),r.parts===!0||r.tokens===!0){let L;for(let j=0;j<s.length;j++){let z=L?L+1:u,D=s[j],d=t.slice(z,D);r.tokens&&(j===0&&u!==0?(o[j].isPrefix=!0,o[j].value=K):o[j].value=d,fd(o[j]),A.maxDepth+=o[j].depth),(j!==0||d!=="")&&a.push(d),L=D}if(L&&L+1<t.length){let j=t.slice(L+1);a.push(j),r.tokens&&(o[o.length-1].value=j,fd(o[o.length-1]),A.maxDepth+=o[o.length-1].depth)}A.slashes=s,A.parts=a}return A};dd.exports=ox});var bd=$(($N,yd)=>{"use strict";var _s=wn(),et=Sn(),{MAX_LENGTH:ws,POSIX_REGEX_SOURCE:ax,REGEX_NON_SPECIAL_CHARS:lx,REGEX_SPECIAL_CHARS_BACKREF:cx,REPLACEMENTS:gd}=_s,ux=(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=>et.escapeRegex(n)).join("..")}return r},di=(t,e)=>`Missing ${t}: "${e}" - use "\\\\${e}" to match literal characters`,ol=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");t=gd[t]||t;let r={...e},i=typeof r.maxLength=="number"?Math.min(ws,r.maxLength):ws,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?"":"?:",l=et.isWindows(e),c=_s.globChars(l),u=_s.extglobChars(c),{DOT_LITERAL:f,PLUS_LITERAL:h,SLASH_LITERAL:p,ONE_CHAR:g,DOTS_SLASH:y,NO_DOT:b,NO_DOT_SLASH:x,NO_DOTS_SLASH:k,QMARK:C,QMARK_NO_DOT:T,STAR:O,START_ANCHOR:I}=c,w=H=>`(${a}(?:(?!${I}${H.dot?y:f}).)*?)`,v=r.dot?"":b,F=r.dot?C:T,q=r.bash===!0?w(r):O;r.capture&&(q=`(${q})`),typeof r.noext=="boolean"&&(r.noextglob=r.noext);let P={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=et.removePrefix(t,P),n=t.length;let U=[],V=[],K=[],N=s,A,L=()=>P.index===n-1,j=P.peek=(H=1)=>t[P.index+H],z=P.advance=()=>t[++P.index]||"",D=()=>t.slice(P.index+1),d=(H="",J=0)=>{P.consumed+=H,P.index+=J},m=H=>{P.output+=H.output!=null?H.output:H.value,d(H.value)},_=()=>{let H=1;for(;j()==="!"&&(j(2)!=="("||j(3)==="?");)z(),P.start++,H++;return H%2===0?!1:(P.negated=!0,P.start++,!0)},R=H=>{P[H]++,K.push(H)},E=H=>{P[H]--,K.pop()},M=H=>{if(N.type==="globstar"){let J=P.braces>0&&(H.type==="comma"||H.type==="brace"),G=H.extglob===!0||U.length&&(H.type==="pipe"||H.type==="paren");H.type!=="slash"&&H.type!=="paren"&&!J&&!G&&(P.output=P.output.slice(0,-N.output.length),N.type="star",N.value="*",N.output=q,P.output+=N.output)}if(U.length&&H.type!=="paren"&&(U[U.length-1].inner+=H.value),(H.value||H.output)&&m(H),N&&N.type==="text"&&H.type==="text"){N.value+=H.value,N.output=(N.output||"")+H.value;return}H.prev=N,o.push(H),N=H},B=(H,J)=>{let G={...u[J],conditions:1,inner:""};G.prev=N,G.parens=P.parens,G.output=P.output;let re=(r.capture?"(":"")+G.open;R("parens"),M({type:H,value:J,output:P.output?"":g}),M({type:"paren",extglob:!0,value:z(),output:re}),U.push(G)},Z=H=>{let J=H.close+(r.capture?")":""),G;if(H.type==="negate"){let re=q;if(H.inner&&H.inner.length>1&&H.inner.includes("/")&&(re=w(r)),(re!==q||L()||/^\)+$/.test(D()))&&(J=H.close=`)$))${re}`),H.inner.includes("*")&&(G=D())&&/^\.[^\\/.]+$/.test(G)){let ue=ol(G,{...e,fastpaths:!1}).output;J=H.close=`)${ue})${re})`}H.prev.type==="bos"&&(P.negatedExtglob=!0)}M({type:"paren",extglob:!0,value:A,output:J}),E("parens")};if(r.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(t)){let H=!1,J=t.replace(cx,(G,re,ue,Ee,_e,S)=>Ee==="\\"?(H=!0,G):Ee==="?"?re?re+Ee+(_e?C.repeat(_e.length):""):S===0?F+(_e?C.repeat(_e.length):""):C.repeat(ue.length):Ee==="."?f.repeat(ue.length):Ee==="*"?re?re+Ee+(_e?q:""):q:re?G:`\\${G}`);return H===!0&&(r.unescape===!0?J=J.replace(/\\/g,""):J=J.replace(/\\+/g,G=>G.length%2===0?"\\\\":G?"\\":"")),J===t&&r.contains===!0?(P.output=t,P):(P.output=et.wrapOutput(J,P,e),P)}for(;!L();){if(A=z(),A==="\0")continue;if(A==="\\"){let G=j();if(G==="/"&&r.bash!==!0||G==="."||G===";")continue;if(!G){A+="\\",M({type:"text",value:A});continue}let re=/^\\+/.exec(D()),ue=0;if(re&&re[0].length>2&&(ue=re[0].length,P.index+=ue,ue%2!==0&&(A+="\\")),r.unescape===!0?A=z():A+=z(),P.brackets===0){M({type:"text",value:A});continue}}if(P.brackets>0&&(A!=="]"||N.value==="["||N.value==="[^")){if(r.posix!==!1&&A===":"){let G=N.value.slice(1);if(G.includes("[")&&(N.posix=!0,G.includes(":"))){let re=N.value.lastIndexOf("["),ue=N.value.slice(0,re),Ee=N.value.slice(re+2),_e=ax[Ee];if(_e){N.value=ue+_e,P.backtrack=!0,z(),!s.output&&o.indexOf(N)===1&&(s.output=g);continue}}}(A==="["&&j()!==":"||A==="-"&&j()==="]")&&(A=`\\${A}`),A==="]"&&(N.value==="["||N.value==="[^")&&(A=`\\${A}`),r.posix===!0&&A==="!"&&N.value==="["&&(A="^"),N.value+=A,m({value:A});continue}if(P.quotes===1&&A!=='"'){A=et.escapeRegex(A),N.value+=A,m({value:A});continue}if(A==='"'){P.quotes=P.quotes===1?0:1,r.keepQuotes===!0&&M({type:"text",value:A});continue}if(A==="("){R("parens"),M({type:"paren",value:A});continue}if(A===")"){if(P.parens===0&&r.strictBrackets===!0)throw new SyntaxError(di("opening","("));let G=U[U.length-1];if(G&&P.parens===G.parens+1){Z(U.pop());continue}M({type:"paren",value:A,output:P.parens?")":"\\)"}),E("parens");continue}if(A==="["){if(r.nobracket===!0||!D().includes("]")){if(r.nobracket!==!0&&r.strictBrackets===!0)throw new SyntaxError(di("closing","]"));A=`\\${A}`}else R("brackets");M({type:"bracket",value:A});continue}if(A==="]"){if(r.nobracket===!0||N&&N.type==="bracket"&&N.value.length===1){M({type:"text",value:A,output:`\\${A}`});continue}if(P.brackets===0){if(r.strictBrackets===!0)throw new SyntaxError(di("opening","["));M({type:"text",value:A,output:`\\${A}`});continue}E("brackets");let G=N.value.slice(1);if(N.posix!==!0&&G[0]==="^"&&!G.includes("/")&&(A=`/${A}`),N.value+=A,m({value:A}),r.literalBrackets===!1||et.hasRegexChars(G))continue;let re=et.escapeRegex(N.value);if(P.output=P.output.slice(0,-N.value.length),r.literalBrackets===!0){P.output+=re,N.value=re;continue}N.value=`(${a}${re}|${N.value})`,P.output+=N.value;continue}if(A==="{"&&r.nobrace!==!0){R("braces");let G={type:"brace",value:A,output:"(",outputIndex:P.output.length,tokensIndex:P.tokens.length};V.push(G),M(G);continue}if(A==="}"){let G=V[V.length-1];if(r.nobrace===!0||!G){M({type:"text",value:A,output:A});continue}let re=")";if(G.dots===!0){let ue=o.slice(),Ee=[];for(let _e=ue.length-1;_e>=0&&(o.pop(),ue[_e].type!=="brace");_e--)ue[_e].type!=="dots"&&Ee.unshift(ue[_e].value);re=ux(Ee,r),P.backtrack=!0}if(G.comma!==!0&&G.dots!==!0){let ue=P.output.slice(0,G.outputIndex),Ee=P.tokens.slice(G.tokensIndex);G.value=G.output="\\{",A=re="\\}",P.output=ue;for(let _e of Ee)P.output+=_e.output||_e.value}M({type:"brace",value:A,output:re}),E("braces"),V.pop();continue}if(A==="|"){U.length>0&&U[U.length-1].conditions++,M({type:"text",value:A});continue}if(A===","){let G=A,re=V[V.length-1];re&&K[K.length-1]==="braces"&&(re.comma=!0,G="|"),M({type:"comma",value:A,output:G});continue}if(A==="/"){if(N.type==="dot"&&P.index===P.start+1){P.start=P.index+1,P.consumed="",P.output="",o.pop(),N=s;continue}M({type:"slash",value:A,output:p});continue}if(A==="."){if(P.braces>0&&N.type==="dot"){N.value==="."&&(N.output=f);let G=V[V.length-1];N.type="dots",N.output+=A,N.value+=A,G.dots=!0;continue}if(P.braces+P.parens===0&&N.type!=="bos"&&N.type!=="slash"){M({type:"text",value:A,output:f});continue}M({type:"dot",value:A,output:f});continue}if(A==="?"){if(!(N&&N.value==="(")&&r.noextglob!==!0&&j()==="("&&j(2)!=="?"){B("qmark",A);continue}if(N&&N.type==="paren"){let re=j(),ue=A;if(re==="<"&&!et.supportsLookbehinds())throw new Error("Node.js v10 or higher is required for regex lookbehinds");(N.value==="("&&!/[!=<:]/.test(re)||re==="<"&&!/<([!=]|\w+>)/.test(D()))&&(ue=`\\${A}`),M({type:"text",value:A,output:ue});continue}if(r.dot!==!0&&(N.type==="slash"||N.type==="bos")){M({type:"qmark",value:A,output:T});continue}M({type:"qmark",value:A,output:C});continue}if(A==="!"){if(r.noextglob!==!0&&j()==="("&&(j(2)!=="?"||!/[!=<:]/.test(j(3)))){B("negate",A);continue}if(r.nonegate!==!0&&P.index===0){_();continue}}if(A==="+"){if(r.noextglob!==!0&&j()==="("&&j(2)!=="?"){B("plus",A);continue}if(N&&N.value==="("||r.regex===!1){M({type:"plus",value:A,output:h});continue}if(N&&(N.type==="bracket"||N.type==="paren"||N.type==="brace")||P.parens>0){M({type:"plus",value:A});continue}M({type:"plus",value:h});continue}if(A==="@"){if(r.noextglob!==!0&&j()==="("&&j(2)!=="?"){M({type:"at",extglob:!0,value:A,output:""});continue}M({type:"text",value:A});continue}if(A!=="*"){(A==="$"||A==="^")&&(A=`\\${A}`);let G=lx.exec(D());G&&(A+=G[0],P.index+=G[0].length),M({type:"text",value:A});continue}if(N&&(N.type==="globstar"||N.star===!0)){N.type="star",N.star=!0,N.value+=A,N.output=q,P.backtrack=!0,P.globstar=!0,d(A);continue}let H=D();if(r.noextglob!==!0&&/^\([^?]/.test(H)){B("star",A);continue}if(N.type==="star"){if(r.noglobstar===!0){d(A);continue}let G=N.prev,re=G.prev,ue=G.type==="slash"||G.type==="bos",Ee=re&&(re.type==="star"||re.type==="globstar");if(r.bash===!0&&(!ue||H[0]&&H[0]!=="/")){M({type:"star",value:A,output:""});continue}let _e=P.braces>0&&(G.type==="comma"||G.type==="brace"),S=U.length&&(G.type==="pipe"||G.type==="paren");if(!ue&&G.type!=="paren"&&!_e&&!S){M({type:"star",value:A,output:""});continue}for(;H.slice(0,3)==="/**";){let Y=t[P.index+4];if(Y&&Y!=="/")break;H=H.slice(3),d("/**",3)}if(G.type==="bos"&&L()){N.type="globstar",N.value+=A,N.output=w(r),P.output=N.output,P.globstar=!0,d(A);continue}if(G.type==="slash"&&G.prev.type!=="bos"&&!Ee&&L()){P.output=P.output.slice(0,-(G.output+N.output).length),G.output=`(?:${G.output}`,N.type="globstar",N.output=w(r)+(r.strictSlashes?")":"|$)"),N.value+=A,P.globstar=!0,P.output+=G.output+N.output,d(A);continue}if(G.type==="slash"&&G.prev.type!=="bos"&&H[0]==="/"){let Y=H[1]!==void 0?"|$":"";P.output=P.output.slice(0,-(G.output+N.output).length),G.output=`(?:${G.output}`,N.type="globstar",N.output=`${w(r)}${p}|${p}${Y})`,N.value+=A,P.output+=G.output+N.output,P.globstar=!0,d(A+z()),M({type:"slash",value:"/",output:""});continue}if(G.type==="bos"&&H[0]==="/"){N.type="globstar",N.value+=A,N.output=`(?:^|${p}|${w(r)}${p})`,P.output=N.output,P.globstar=!0,d(A+z()),M({type:"slash",value:"/",output:""});continue}P.output=P.output.slice(0,-N.output.length),N.type="globstar",N.output=w(r),N.value+=A,P.output+=N.output,P.globstar=!0,d(A);continue}let J={type:"star",value:A,output:q};if(r.bash===!0){J.output=".*?",(N.type==="bos"||N.type==="slash")&&(J.output=v+J.output),M(J);continue}if(N&&(N.type==="bracket"||N.type==="paren")&&r.regex===!0){J.output=A,M(J);continue}(P.index===P.start||N.type==="slash"||N.type==="dot")&&(N.type==="dot"?(P.output+=x,N.output+=x):r.dot===!0?(P.output+=k,N.output+=k):(P.output+=v,N.output+=v),j()!=="*"&&(P.output+=g,N.output+=g)),M(J)}for(;P.brackets>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing","]"));P.output=et.escapeLast(P.output,"["),E("brackets")}for(;P.parens>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing",")"));P.output=et.escapeLast(P.output,"("),E("parens")}for(;P.braces>0;){if(r.strictBrackets===!0)throw new SyntaxError(di("closing","}"));P.output=et.escapeLast(P.output,"{"),E("braces")}if(r.strictSlashes!==!0&&(N.type==="star"||N.type==="bracket")&&M({type:"maybe_slash",value:"",output:`${p}?`}),P.backtrack===!0){P.output="";for(let H of P.tokens)P.output+=H.output!=null?H.output:H.value,H.suffix&&(P.output+=H.suffix)}return P};ol.fastpaths=(t,e)=>{let r={...e},i=typeof r.maxLength=="number"?Math.min(ws,r.maxLength):ws,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);t=gd[t]||t;let s=et.isWindows(e),{DOT_LITERAL:o,SLASH_LITERAL:a,ONE_CHAR:l,DOTS_SLASH:c,NO_DOT:u,NO_DOTS:f,NO_DOTS_SLASH:h,STAR:p,START_ANCHOR:g}=_s.globChars(s),y=r.dot?f:u,b=r.dot?h:u,x=r.capture?"":"?:",k={negated:!1,prefix:""},C=r.bash===!0?".*?":p;r.capture&&(C=`(${C})`);let T=v=>v.noglobstar===!0?C:`(${x}(?:(?!${g}${v.dot?c:o}).)*?)`,O=v=>{switch(v){case"*":return`${y}${l}${C}`;case".*":return`${o}${l}${C}`;case"*.*":return`${y}${C}${o}${l}${C}`;case"*/*":return`${y}${C}${a}${l}${b}${C}`;case"**":return y+T(r);case"**/*":return`(?:${y}${T(r)}${a})?${b}${l}${C}`;case"**/*.*":return`(?:${y}${T(r)}${a})?${b}${C}${o}${l}${C}`;case"**/.*":return`(?:${y}${T(r)}${a})?${o}${l}${C}`;default:{let F=/^(.*?)\.(\w+)$/.exec(v);if(!F)return;let q=O(F[1]);return q?q+o+F[2]:void 0}}},I=et.removePrefix(t,k),w=O(I);return w&&r.strictSlashes!==!0&&(w+=`${a}?`),w};yd.exports=ol});var wd=$((qN,_d)=>{"use strict";var hx=require("path"),fx=md(),al=bd(),ll=Sn(),px=wn(),dx=t=>t&&typeof t=="object"&&!Array.isArray(t),we=(t,e,r=!1)=>{if(Array.isArray(t)){let u=t.map(h=>we(h,e,r));return h=>{for(let p of u){let g=p(h);if(g)return g}return!1}}let i=dx(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=ll.isWindows(e),o=i?we.compileRe(t,e):we.makeRe(t,e,!1,!0),a=o.state;delete o.state;let l=()=>!1;if(n.ignore){let u={...e,ignore:null,onMatch:null,onResult:null};l=we(n.ignore,u,r)}let c=(u,f=!1)=>{let{isMatch:h,match:p,output:g}=we.test(u,o,e,{glob:t,posix:s}),y={glob:t,state:a,regex:o,posix:s,input:u,output:g,match:p,isMatch:h};return typeof n.onResult=="function"&&n.onResult(y),h===!1?(y.isMatch=!1,f?y:!1):l(u)?(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&&(c.state=a),c};we.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?ll.toPosixSlashes:null),a=t===i,l=a&&o?o(t):t;return a===!1&&(l=o?o(t):t,a=l===i),(a===!1||s.capture===!0)&&(s.matchBase===!0||s.basename===!0?a=we.matchBase(t,e,r,n):a=e.exec(l)),{isMatch:!!a,match:a,output:l}};we.matchBase=(t,e,r,i=ll.isWindows(r))=>(e instanceof RegExp?e:we.makeRe(e,r)).test(hx.basename(t));we.isMatch=(t,e,r)=>we(e,r)(t);we.parse=(t,e)=>Array.isArray(t)?t.map(r=>we.parse(r,e)):al(t,{...e,fastpaths:!1});we.scan=(t,e)=>fx(t,e);we.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 l=we.toRegex(a,e);return i===!0&&(l.state=t),l};we.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=al.fastpaths(t,e)),n.output||(n=al(t,e)),we.compileRe(n,e,r,i)};we.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/$^/}};we.constants=px;_d.exports=we});var Ed=$((HN,Sd)=>{"use strict";Sd.exports=wd()});var Od=$((UN,Ad)=>{"use strict";var Rd=require("util"),xd=rd(),Rt=Ed(),cl=Sn(),vd=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=u=>{s.add(u.output),r&&r.onResult&&r.onResult(u)};for(let u=0;u<e.length;u++){let f=Rt(String(e[u]),{...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 c=(o===e.length?[...s]:[...n]).filter(u=>!i.has(u));if(r&&c.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(u=>u.replace(/\\/g,"")):e}return c};ge.match=ge;ge.matcher=(t,e)=>Rt(t,e);ge.isMatch=(t,e,r)=>Rt(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: "${Rd.inspect(t)}"`);if(Array.isArray(e))return e.some(i=>ge.contains(t,i,r));if(typeof e=="string"){if(vd(t)||vd(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(!cl.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=Rt(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=Rt(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: "${Rd.inspect(t)}"`);return[].concat(e).every(i=>Rt(i,r)(t))};ge.capture=(t,e,r)=>{let i=cl.isWindows(r),s=Rt.makeRe(String(t),{...r,capture:!0}).exec(i?cl.toPosixSlashes(e):e);if(s)return s.slice(1).map(o=>o===void 0?"":o)};ge.makeRe=(...t)=>Rt.makeRe(...t);ge.scan=(...t)=>Rt.scan(...t);ge.parse=(t,e)=>{let r=[];for(let i of[].concat(t||[]))for(let n of xd(String(i),e))r.push(Rt.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]:xd(t,e)};ge.braceExpand=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return ge.braces(t,{...e,expand:!0})};Ad.exports=ge});var Dd=$(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 mx=require("path"),gx=_p(),ul=Od(),Td="**",yx="\\",bx=/[*?]|^!/,_x=/\[[^[]*]/,wx=/(?:^|[^!*+?@])\([^(]*\|[^|]*\)/,Sx=/[!*+?@]\([^(]*\)/,Ex=/,|\.\./;function kd(t,e={}){return!Cd(t,e)}se.isStaticPattern=kd;function Cd(t,e={}){return t===""?!1:!!(e.caseSensitiveMatch===!1||t.includes(yx)||bx.test(t)||_x.test(t)||wx.test(t)||e.extglob!==!1&&Sx.test(t)||e.braceExpansion!==!1&&vx(t))}se.isDynamicPattern=Cd;function vx(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 Ex.test(i)}function Rx(t){return Ss(t)?t.slice(1):t}se.convertToPositivePattern=Rx;function xx(t){return"!"+t}se.convertToNegativePattern=xx;function Ss(t){return t.startsWith("!")&&t[1]!=="("}se.isNegativePattern=Ss;function Ld(t){return!Ss(t)}se.isPositivePattern=Ld;function Ax(t){return t.filter(Ss)}se.getNegativePatterns=Ax;function Ox(t){return t.filter(Ld)}se.getPositivePatterns=Ox;function Tx(t){return t.filter(e=>!hl(e))}se.getPatternsInsideCurrentDirectory=Tx;function kx(t){return t.filter(hl)}se.getPatternsOutsideCurrentDirectory=kx;function hl(t){return t.startsWith("..")||t.startsWith("./..")}se.isPatternRelatedToParentDirectory=hl;function Cx(t){return gx(t,{flipBackslashes:!1})}se.getBaseDirectory=Cx;function Lx(t){return t.includes(Td)}se.hasGlobStar=Lx;function Pd(t){return t.endsWith("/"+Td)}se.endsWithSlashGlobStar=Pd;function Px(t){let e=mx.basename(t);return Pd(t)||kd(e)}se.isAffectDepthOfReadingPattern=Px;function Ix(t){return t.reduce((e,r)=>e.concat(Id(r)),[])}se.expandPatternsWithBraceExpansion=Ix;function Id(t){return ul.braces(t,{expand:!0,nodupes:!0})}se.expandBraceExpansion=Id;function Nx(t,e){let{parts:r}=ul.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=Nx;function Nd(t,e){return ul.makeRe(t,e)}se.makeRe=Nd;function Dx(t,e){return t.map(r=>Nd(r,e))}se.convertPatternsToRe=Dx;function Mx(t,e){return e.some(r=>r.test(t))}se.matchAny=Mx});var jd=$((zN,Bd)=>{"use strict";var Fx=require("stream"),Md=Fx.PassThrough,Bx=Array.prototype.slice;Bd.exports=jx;function jx(){let t=[],e=Bx.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=Md(i);function a(){for(let u=0,f=arguments.length;u<f;u++)t.push(Fd(arguments[u],i));return l(),this}function l(){if(r)return;r=!0;let u=t.shift();if(!u){process.nextTick(c);return}Array.isArray(u)||(u=[u]);let f=u.length+1;function h(){--f>0||(r=!1,l())}function p(g){function y(){g.removeListener("merge2UnpipeEnd",y),g.removeListener("end",y),s&&g.removeListener("error",b),h()}function b(x){o.emit("error",x)}if(g._readableState.endEmitted)return h();g.on("merge2UnpipeEnd",y),g.on("end",y),s&&g.on("error",b),g.pipe(o,{end:!1}),g.resume()}for(let g=0;g<u.length;g++)p(u[g]);h()}function c(){r=!1,o.emit("queueDrain"),n&&o.end()}return o.setMaxListeners(0),o.add=a,o.on("unpipe",function(u){u.emit("merge2UnpipeEnd")}),e.length&&a.apply(null,e),o}function Fd(t,e){if(Array.isArray(t))for(let r=0,i=t.length;r<i;r++)t[r]=Fd(t[r],e);else{if(!t._readableState&&t.pipe&&(t=t.pipe(Md(e))),!t._readableState||!t.pause||!t.pipe)throw new Error("Only readable stream can be merged.");t.pause()}return t}});var qd=$(Es=>{"use strict";Object.defineProperty(Es,"__esModule",{value:!0});Es.merge=void 0;var $x=jd();function qx(t){let e=$x(t);return t.forEach(r=>{r.once("error",i=>e.emit("error",i))}),e.once("close",()=>$d(t)),e.once("end",()=>$d(t)),e}Es.merge=qx;function $d(t){t.forEach(e=>e.emit("close"))}});var Hd=$(mi=>{"use strict";Object.defineProperty(mi,"__esModule",{value:!0});mi.isEmpty=mi.isString=void 0;function Hx(t){return typeof t=="string"}mi.isString=Hx;function Ux(t){return t===""}mi.isEmpty=Ux});var Ut=$(Ie=>{"use strict";Object.defineProperty(Ie,"__esModule",{value:!0});Ie.string=Ie.stream=Ie.pattern=Ie.path=Ie.fs=Ie.errno=Ie.array=void 0;var Gx=cp();Ie.array=Gx;var zx=up();Ie.errno=zx;var Wx=hp();Ie.fs=Wx;var Yx=fp();Ie.path=Yx;var Vx=Dd();Ie.pattern=Vx;var Kx=qd();Ie.stream=Kx;var Zx=Hd();Ie.string=Zx});var zd=$(Ne=>{"use strict";Object.defineProperty(Ne,"__esModule",{value:!0});Ne.convertPatternGroupToTask=Ne.convertPatternGroupsToTasks=Ne.groupPatternsByBaseDirectory=Ne.getNegativePatternsAsPositive=Ne.getPositivePatterns=Ne.convertPatternsToTasks=Ne.generate=void 0;var Gt=Ut();function Xx(t,e){let r=Ud(t),i=Gd(t,e.ignore),n=r.filter(l=>Gt.pattern.isStaticPattern(l,e)),s=r.filter(l=>Gt.pattern.isDynamicPattern(l,e)),o=fl(n,i,!1),a=fl(s,i,!0);return o.concat(a)}Ne.generate=Xx;function fl(t,e,r){let i=[],n=Gt.pattern.getPatternsOutsideCurrentDirectory(t),s=Gt.pattern.getPatternsInsideCurrentDirectory(t),o=pl(n),a=pl(s);return i.push(...dl(o,e,r)),"."in a?i.push(ml(".",s,e,r)):i.push(...dl(a,e,r)),i}Ne.convertPatternsToTasks=fl;function Ud(t){return Gt.pattern.getPositivePatterns(t)}Ne.getPositivePatterns=Ud;function Gd(t,e){return Gt.pattern.getNegativePatterns(t).concat(e).map(Gt.pattern.convertToPositivePattern)}Ne.getNegativePatternsAsPositive=Gd;function pl(t){let e={};return t.reduce((r,i)=>{let n=Gt.pattern.getBaseDirectory(i);return n in r?r[n].push(i):r[n]=[i],r},e)}Ne.groupPatternsByBaseDirectory=pl;function dl(t,e,r){return Object.keys(t).map(i=>ml(i,t[i],e,r))}Ne.convertPatternGroupsToTasks=dl;function ml(t,e,r,i){return{dynamic:i,positive:e,negative:r,base:t,patterns:[].concat(e,r.map(Gt.pattern.convertToNegativePattern))}}Ne.convertPatternGroupToTask=ml});var Yd=$(gi=>{"use strict";Object.defineProperty(gi,"__esModule",{value:!0});gi.removeDuplicateSlashes=gi.transform=void 0;var Jx=/(?!^)\/{2,}/g;function Qx(t){return t.map(e=>Wd(e))}gi.transform=Qx;function Wd(t){return t.replace(Jx,"/")}gi.removeDuplicateSlashes=Wd});var Kd=$(vs=>{"use strict";Object.defineProperty(vs,"__esModule",{value:!0});vs.read=void 0;function eA(t,e,r){e.fs.lstat(t,(i,n)=>{if(i!==null){Vd(r,i);return}if(!n.isSymbolicLink()||!e.followSymbolicLink){gl(r,n);return}e.fs.stat(t,(s,o)=>{if(s!==null){if(e.throwErrorOnBrokenSymbolicLink){Vd(r,s);return}gl(r,n);return}e.markSymbolicLink&&(o.isSymbolicLink=()=>!0),gl(r,o)})})}vs.read=eA;function Vd(t,e){t(e)}function gl(t,e){t(null,e)}});var Zd=$(Rs=>{"use strict";Object.defineProperty(Rs,"__esModule",{value:!0});Rs.read=void 0;function tA(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}}Rs.read=tA});var Xd=$(cr=>{"use strict";Object.defineProperty(cr,"__esModule",{value:!0});cr.createFileSystemAdapter=cr.FILE_SYSTEM_ADAPTER=void 0;var xs=require("fs");cr.FILE_SYSTEM_ADAPTER={lstat:xs.lstat,stat:xs.stat,lstatSync:xs.lstatSync,statSync:xs.statSync};function rA(t){return t===void 0?cr.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},cr.FILE_SYSTEM_ADAPTER),t)}cr.createFileSystemAdapter=rA});var Jd=$(bl=>{"use strict";Object.defineProperty(bl,"__esModule",{value:!0});var iA=Xd(),yl=class{constructor(e={}){this._options=e,this.followSymbolicLink=this._getValue(this._options.followSymbolicLink,!0),this.fs=iA.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}};bl.default=yl});var jr=$(ur=>{"use strict";Object.defineProperty(ur,"__esModule",{value:!0});ur.statSync=ur.stat=ur.Settings=void 0;var Qd=Kd(),nA=Zd(),_l=Jd();ur.Settings=_l.default;function sA(t,e,r){if(typeof e=="function"){Qd.read(t,wl(),e);return}Qd.read(t,wl(e),r)}ur.stat=sA;function oA(t,e){let r=wl(e);return nA.read(t,r)}ur.statSync=oA;function wl(t={}){return t instanceof _l.default?t:new _l.default(t)}});var rm=$((rD,tm)=>{var em;tm.exports=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window!="undefined"?window:global):t=>(em||(em=Promise.resolve())).then(t).catch(e=>setTimeout(()=>{throw e},0))});var nm=$((iD,im)=>{im.exports=lA;var aA=rm();function lA(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(l){function c(){e&&e(l,r),e=null}s?aA(c):c()}function a(l,c,u){r[l]=u,(--i===0||c)&&o(c)}i?n?n.forEach(function(l){t[l](function(c,u){a(l,c,u)})}):t.forEach(function(l,c){l(function(u,f){a(c,u,f)})}):o(null),s=!1}});var Sl=$(Os=>{"use strict";Object.defineProperty(Os,"__esModule",{value:!0});Os.IS_SUPPORT_READDIR_WITH_FILE_TYPES=void 0;var As=process.versions.node.split(".");if(As[0]===void 0||As[1]===void 0)throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`);var sm=Number.parseInt(As[0],10),cA=Number.parseInt(As[1],10),om=10,uA=10,hA=sm>om,fA=sm===om&&cA>=uA;Os.IS_SUPPORT_READDIR_WITH_FILE_TYPES=hA||fA});var am=$(Ts=>{"use strict";Object.defineProperty(Ts,"__esModule",{value:!0});Ts.createDirentFromStats=void 0;var El=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 pA(t,e){return new El(t,e)}Ts.createDirentFromStats=pA});var vl=$(ks=>{"use strict";Object.defineProperty(ks,"__esModule",{value:!0});ks.fs=void 0;var dA=am();ks.fs=dA});var Rl=$(Cs=>{"use strict";Object.defineProperty(Cs,"__esModule",{value:!0});Cs.joinPathSegments=void 0;function mA(t,e,r){return t.endsWith(r)?t+e:t+r+e}Cs.joinPathSegments=mA});var pm=$(hr=>{"use strict";Object.defineProperty(hr,"__esModule",{value:!0});hr.readdir=hr.readdirWithFileTypes=hr.read=void 0;var gA=jr(),lm=nm(),yA=Sl(),cm=vl(),um=Rl();function bA(t,e,r){if(!e.stats&&yA.IS_SUPPORT_READDIR_WITH_FILE_TYPES){hm(t,e,r);return}fm(t,e,r)}hr.read=bA;function hm(t,e,r){e.fs.readdir(t,{withFileTypes:!0},(i,n)=>{if(i!==null){Ls(r,i);return}let s=n.map(a=>({dirent:a,name:a.name,path:um.joinPathSegments(t,a.name,e.pathSegmentSeparator)}));if(!e.followSymbolicLinks){xl(r,s);return}let o=s.map(a=>_A(a,e));lm(o,(a,l)=>{if(a!==null){Ls(r,a);return}xl(r,l)})})}hr.readdirWithFileTypes=hm;function _A(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=cm.fs.createDirentFromStats(t.name,n),r(null,t)})}}function fm(t,e,r){e.fs.readdir(t,(i,n)=>{if(i!==null){Ls(r,i);return}let s=n.map(o=>{let a=um.joinPathSegments(t,o,e.pathSegmentSeparator);return l=>{gA.stat(a,e.fsStatSettings,(c,u)=>{if(c!==null){l(c);return}let f={name:o,path:a,dirent:cm.fs.createDirentFromStats(o,u)};e.stats&&(f.stats=u),l(null,f)})}});lm(s,(o,a)=>{if(o!==null){Ls(r,o);return}xl(r,a)})})}hr.readdir=fm;function Ls(t,e){t(e)}function xl(t,e){t(null,e)}});var bm=$(fr=>{"use strict";Object.defineProperty(fr,"__esModule",{value:!0});fr.readdir=fr.readdirWithFileTypes=fr.read=void 0;var wA=jr(),SA=Sl(),dm=vl(),mm=Rl();function EA(t,e){return!e.stats&&SA.IS_SUPPORT_READDIR_WITH_FILE_TYPES?gm(t,e):ym(t,e)}fr.read=EA;function gm(t,e){return e.fs.readdirSync(t,{withFileTypes:!0}).map(i=>{let n={dirent:i,name:i.name,path:mm.joinPathSegments(t,i.name,e.pathSegmentSeparator)};if(n.dirent.isSymbolicLink()&&e.followSymbolicLinks)try{let s=e.fs.statSync(n.path);n.dirent=dm.fs.createDirentFromStats(n.name,s)}catch(s){if(e.throwErrorOnBrokenSymbolicLink)throw s}return n})}fr.readdirWithFileTypes=gm;function ym(t,e){return e.fs.readdirSync(t).map(i=>{let n=mm.joinPathSegments(t,i,e.pathSegmentSeparator),s=wA.statSync(n,e.fsStatSettings),o={name:i,path:n,dirent:dm.fs.createDirentFromStats(i,s)};return e.stats&&(o.stats=s),o})}fr.readdir=ym});var _m=$(pr=>{"use strict";Object.defineProperty(pr,"__esModule",{value:!0});pr.createFileSystemAdapter=pr.FILE_SYSTEM_ADAPTER=void 0;var yi=require("fs");pr.FILE_SYSTEM_ADAPTER={lstat:yi.lstat,stat:yi.stat,lstatSync:yi.lstatSync,statSync:yi.statSync,readdir:yi.readdir,readdirSync:yi.readdirSync};function vA(t){return t===void 0?pr.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},pr.FILE_SYSTEM_ADAPTER),t)}pr.createFileSystemAdapter=vA});var wm=$(Ol=>{"use strict";Object.defineProperty(Ol,"__esModule",{value:!0});var RA=require("path"),xA=jr(),AA=_m(),Al=class{constructor(e={}){this._options=e,this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!1),this.fs=AA.createFileSystemAdapter(this._options.fs),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,RA.sep),this.stats=this._getValue(this._options.stats,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0),this.fsStatSettings=new xA.Settings({followSymbolicLink:this.followSymbolicLinks,fs:this.fs,throwErrorOnBrokenSymbolicLink:this.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};Ol.default=Al});var Ps=$(dr=>{"use strict";Object.defineProperty(dr,"__esModule",{value:!0});dr.Settings=dr.scandirSync=dr.scandir=void 0;var Sm=pm(),OA=bm(),Tl=wm();dr.Settings=Tl.default;function TA(t,e,r){if(typeof e=="function"){Sm.read(t,kl(),e);return}Sm.read(t,kl(e),r)}dr.scandir=TA;function kA(t,e){let r=kl(e);return OA.read(t,r)}dr.scandirSync=kA;function kl(t={}){return t instanceof Tl.default?t:new Tl.default(t)}});var vm=$((pD,Em)=>{"use strict";function CA(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}}Em.exports=CA});var xm=$((dD,Cl)=>{"use strict";var LA=vm();function Rm(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=LA(PA),n=null,s=null,o=0,a=null,l={push:y,drain:at,saturated:at,pause:u,paused:!1,concurrency:r,running:c,resume:p,idle:g,length:f,getQueue:h,unshift:b,empty:at,kill:k,killAndDrain:C,error:T};return l;function c(){return o}function u(){l.paused=!0}function f(){for(var O=n,I=0;O;)O=O.next,I++;return I}function h(){for(var O=n,I=[];O;)I.push(O.value),O=O.next;return I}function p(){if(l.paused){l.paused=!1;for(var O=0;O<l.concurrency;O++)o++,x()}}function g(){return o===0&&l.length()===0}function y(O,I){var w=i.get();w.context=t,w.release=x,w.value=O,w.callback=I||at,w.errorHandler=a,o===l.concurrency||l.paused?s?(s.next=w,s=w):(n=w,s=w,l.saturated()):(o++,e.call(t,w.value,w.worked))}function b(O,I){var w=i.get();w.context=t,w.release=x,w.value=O,w.callback=I||at,o===l.concurrency||l.paused?n?(w.next=n,n=w):(n=w,s=w,l.saturated()):(o++,e.call(t,w.value,w.worked))}function x(O){O&&i.release(O);var I=n;I?l.paused?o--:(s===n&&(s=null),n=I.next,I.next=null,e.call(t,I.value,I.worked),s===null&&l.empty()):--o===0&&l.drain()}function k(){n=null,s=null,l.drain=at}function C(){n=null,s=null,l.drain(),l.drain=at}function T(O){a=O}}function at(){}function PA(){this.value=null,this.callback=at,this.next=null,this.release=at,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=at,t.errorHandler&&s(r,o),n.call(t.context,r,i),t.release(t)}}function IA(t,e,r){typeof t=="function"&&(r=e,e=t,t=null);function i(u,f){e.call(this,u).then(function(h){f(null,h)},f)}var n=Rm(t,i,r),s=n.push,o=n.unshift;return n.push=a,n.unshift=l,n.drained=c,n;function a(u){var f=new Promise(function(h,p){s(u,function(g,y){if(g){p(g);return}h(y)})});return f.catch(at),f}function l(u){var f=new Promise(function(h,p){o(u,function(g,y){if(g){p(g);return}h(y)})});return f.catch(at),f}function c(){var u=n.drain,f=new Promise(function(h){n.drain=function(){u(),h()}});return f}}Cl.exports=Rm;Cl.exports.promise=IA});var Is=$(xt=>{"use strict";Object.defineProperty(xt,"__esModule",{value:!0});xt.joinPathSegments=xt.replacePathSegmentSeparator=xt.isAppliedFilter=xt.isFatalError=void 0;function NA(t,e){return t.errorFilter===null?!0:!t.errorFilter(e)}xt.isFatalError=NA;function DA(t,e){return t===null||t(e)}xt.isAppliedFilter=DA;function MA(t,e){return t.split(/[/\\]/).join(e)}xt.replacePathSegmentSeparator=MA;function FA(t,e,r){return t===""?e:t.endsWith(r)?t+e:t+r+e}xt.joinPathSegments=FA});var Il=$(Pl=>{"use strict";Object.defineProperty(Pl,"__esModule",{value:!0});var BA=Is(),Ll=class{constructor(e,r){this._root=e,this._settings=r,this._root=BA.replacePathSegmentSeparator(e,r.pathSegmentSeparator)}};Pl.default=Ll});var Ml=$(Dl=>{"use strict";Object.defineProperty(Dl,"__esModule",{value:!0});var jA=require("events"),$A=Ps(),qA=xm(),Ns=Is(),HA=Il(),Nl=class extends HA.default{constructor(e,r){super(e,r),this._settings=r,this._scandir=$A.scandir,this._emitter=new jA.EventEmitter,this._queue=qA(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||!Ns.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=Ns.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),Ns.isAppliedFilter(this._settings.entryFilter,e)&&this._emitEntry(e),e.dirent.isDirectory()&&Ns.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,r===void 0?void 0:e.path)}_emitEntry(e){this._emitter.emit("entry",e)}};Dl.default=Nl});var Am=$(Bl=>{"use strict";Object.defineProperty(Bl,"__esModule",{value:!0});var UA=Ml(),Fl=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new UA.default(this._root,this._settings),this._storage=[]}read(e){this._reader.onError(r=>{GA(e,r)}),this._reader.onEntry(r=>{this._storage.push(r)}),this._reader.onEnd(()=>{zA(e,this._storage)}),this._reader.read()}};Bl.default=Fl;function GA(t,e){t(e)}function zA(t,e){t(null,e)}});var Om=$($l=>{"use strict";Object.defineProperty($l,"__esModule",{value:!0});var WA=require("stream"),YA=Ml(),jl=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new YA.default(this._root,this._settings),this._stream=new WA.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}};$l.default=jl});var Tm=$(Hl=>{"use strict";Object.defineProperty(Hl,"__esModule",{value:!0});var VA=Ps(),Ds=Is(),KA=Il(),ql=class extends KA.default{constructor(){super(...arguments),this._scandir=VA.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(Ds.isFatalError(this._settings,e))throw e}_handleEntry(e,r){let i=e.path;r!==void 0&&(e.path=Ds.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),Ds.isAppliedFilter(this._settings.entryFilter,e)&&this._pushToStorage(e),e.dirent.isDirectory()&&Ds.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,r===void 0?void 0:e.path)}_pushToStorage(e){this._storage.push(e)}};Hl.default=ql});var km=$(Gl=>{"use strict";Object.defineProperty(Gl,"__esModule",{value:!0});var ZA=Tm(),Ul=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new ZA.default(this._root,this._settings)}read(){return this._reader.read()}};Gl.default=Ul});var Cm=$(Wl=>{"use strict";Object.defineProperty(Wl,"__esModule",{value:!0});var XA=require("path"),JA=Ps(),zl=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,XA.sep),this.fsScandirSettings=new JA.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}};Wl.default=zl});var Fs=$(At=>{"use strict";Object.defineProperty(At,"__esModule",{value:!0});At.Settings=At.walkStream=At.walkSync=At.walk=void 0;var Lm=Am(),QA=Om(),eO=km(),Yl=Cm();At.Settings=Yl.default;function tO(t,e,r){if(typeof e=="function"){new Lm.default(t,Ms()).read(e);return}new Lm.default(t,Ms(e)).read(r)}At.walk=tO;function rO(t,e){let r=Ms(e);return new eO.default(t,r).read()}At.walkSync=rO;function iO(t,e){let r=Ms(e);return new QA.default(t,r).read()}At.walkStream=iO;function Ms(t={}){return t instanceof Yl.default?t:new Yl.default(t)}});var Bs=$(Kl=>{"use strict";Object.defineProperty(Kl,"__esModule",{value:!0});var nO=require("path"),sO=jr(),Pm=Ut(),Vl=class{constructor(e){this._settings=e,this._fsStatSettings=new sO.Settings({followSymbolicLink:this._settings.followSymbolicLinks,fs:this._settings.fs,throwErrorOnBrokenSymbolicLink:this._settings.followSymbolicLinks})}_getFullEntryPath(e){return nO.resolve(this._settings.cwd,e)}_makeEntry(e,r){let i={name:r,path:r,dirent:Pm.fs.createDirentFromStats(r,e)};return this._settings.stats&&(i.stats=e),i}_isFatalError(e){return!Pm.errno.isEnoentCodeError(e)&&!this._settings.suppressErrors}};Kl.default=Vl});var Jl=$(Xl=>{"use strict";Object.defineProperty(Xl,"__esModule",{value:!0});var oO=require("stream"),aO=jr(),lO=Fs(),cO=Bs(),Zl=class extends cO.default{constructor(){super(...arguments),this._walkStream=lO.walkStream,this._stat=aO.stat}dynamic(e,r){return this._walkStream(e,r)}static(e,r){let i=e.map(this._getFullEntryPath,this),n=new oO.PassThrough({objectMode:!0});n._write=(s,o,a)=>this._getEntry(i[s],e[s],r).then(l=>{l!==null&&r.entryFilter(l)&&n.push(l),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))})}};Xl.default=Zl});var Im=$(ec=>{"use strict";Object.defineProperty(ec,"__esModule",{value:!0});var uO=Fs(),hO=Bs(),fO=Jl(),Ql=class extends hO.default{constructor(){super(...arguments),this._walkAsync=uO.walk,this._readerStream=new fO.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))})}};ec.default=Ql});var Nm=$(rc=>{"use strict";Object.defineProperty(rc,"__esModule",{value:!0});var bi=Ut(),tc=class{constructor(e,r,i){this._patterns=e,this._settings=r,this._micromatchOptions=i,this._storage=[],this._fillStorage()}_fillStorage(){let e=bi.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 bi.pattern.getPatternParts(e,this._micromatchOptions).map(i=>bi.pattern.isDynamicPattern(i,this._settings)?{dynamic:!0,pattern:i,patternRe:bi.pattern.makeRe(i,this._micromatchOptions)}:{dynamic:!1,pattern:i})}_splitSegmentsIntoSections(e){return bi.array.splitWhen(e,r=>r.dynamic&&bi.pattern.hasGlobStar(r.pattern))}};rc.default=tc});var Dm=$(nc=>{"use strict";Object.defineProperty(nc,"__esModule",{value:!0});var pO=Nm(),ic=class extends pO.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((l,c)=>{let u=s.segments[c];return!!(u.dynamic&&u.patternRe.test(l)||!u.dynamic&&u.pattern===l)}))return!0}return!1}};nc.default=ic});var Mm=$(oc=>{"use strict";Object.defineProperty(oc,"__esModule",{value:!0});var js=Ut(),dO=Dm(),sc=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 dO.default(e,this._settings,this._micromatchOptions)}_getNegativePatternsRe(e){let r=e.filter(js.pattern.isAffectDepthOfReadingPattern);return js.pattern.convertPatternsToRe(r,this._micromatchOptions)}_filter(e,r,i,n){if(this._isSkippedByDeep(e,r.path)||this._isSkippedSymbolicLink(r))return!1;let s=js.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!js.pattern.matchAny(e,r)}};oc.default=sc});var Fm=$(lc=>{"use strict";Object.defineProperty(lc,"__esModule",{value:!0});var $r=Ut(),ac=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}};lc.default=ac});var Bm=$(uc=>{"use strict";Object.defineProperty(uc,"__esModule",{value:!0});var mO=Ut(),cc=class{constructor(e){this._settings=e}getFilter(){return e=>this._isNonFatalError(e)}_isNonFatalError(e){return mO.errno.isEnoentCodeError(e)||this._settings.suppressErrors}};uc.default=cc});var $m=$(fc=>{"use strict";Object.defineProperty(fc,"__esModule",{value:!0});var jm=Ut(),hc=class{constructor(e){this._settings=e}getTransformer(){return e=>this._transform(e)}_transform(e){let r=e.path;return this._settings.absolute&&(r=jm.path.makeAbsolute(this._settings.cwd,r),r=jm.path.unixify(r)),this._settings.markDirectories&&e.dirent.isDirectory()&&(r+="/"),this._settings.objectMode?Object.assign(Object.assign({},e),{path:r}):r}};fc.default=hc});var $s=$(dc=>{"use strict";Object.defineProperty(dc,"__esModule",{value:!0});var gO=require("path"),yO=Mm(),bO=Fm(),_O=Bm(),wO=$m(),pc=class{constructor(e){this._settings=e,this.errorFilter=new _O.default(this._settings),this.entryFilter=new bO.default(this._settings,this._getMicromatchOptions()),this.deepFilter=new yO.default(this._settings,this._getMicromatchOptions()),this.entryTransformer=new wO.default(this._settings)}_getRootDirectory(e){return gO.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}}};dc.default=pc});var qm=$(gc=>{"use strict";Object.defineProperty(gc,"__esModule",{value:!0});var SO=Im(),EO=$s(),mc=class extends EO.default{constructor(){super(...arguments),this._reader=new SO.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)}};gc.default=mc});var Hm=$(bc=>{"use strict";Object.defineProperty(bc,"__esModule",{value:!0});var vO=require("stream"),RO=Jl(),xO=$s(),yc=class extends xO.default{constructor(){super(...arguments),this._reader=new RO.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e),n=this.api(r,e,i),s=new vO.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)}};bc.default=yc});var Um=$(wc=>{"use strict";Object.defineProperty(wc,"__esModule",{value:!0});var AO=jr(),OO=Fs(),TO=Bs(),_c=class extends TO.default{constructor(){super(...arguments),this._walkSync=OO.walkSync,this._statSync=AO.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)}};wc.default=_c});var Gm=$(Ec=>{"use strict";Object.defineProperty(Ec,"__esModule",{value:!0});var kO=Um(),CO=$s(),Sc=class extends CO.default{constructor(){super(...arguments),this._reader=new kO.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)}};Ec.default=Sc});var zm=$(wi=>{"use strict";Object.defineProperty(wi,"__esModule",{value:!0});wi.DEFAULT_FILE_SYSTEM_ADAPTER=void 0;var _i=require("fs"),LO=require("os"),PO=Math.max(LO.cpus().length,1);wi.DEFAULT_FILE_SYSTEM_ADAPTER={lstat:_i.lstat,lstatSync:_i.lstatSync,stat:_i.stat,statSync:_i.statSync,readdir:_i.readdir,readdirSync:_i.readdirSync};var vc=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,PO),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({},wi.DEFAULT_FILE_SYSTEM_ADAPTER),e)}};wi.default=vc});var qs=$((jD,Vm)=>{"use strict";var Wm=zd(),Ym=Yd(),IO=qm(),NO=Hm(),DO=Gm(),Rc=zm(),qr=Ut();async function xc(t,e){Si(t);let r=Ac(t,IO.default,e),i=await Promise.all(r);return qr.array.flatten(i)}(function(t){function e(o,a){Si(o);let l=Ac(o,DO.default,a);return qr.array.flatten(l)}t.sync=e;function r(o,a){Si(o);let l=Ac(o,NO.default,a);return qr.stream.merge(l)}t.stream=r;function i(o,a){Si(o);let l=Ym.transform([].concat(o)),c=new Rc.default(a);return Wm.generate(l,c)}t.generateTasks=i;function n(o,a){Si(o);let l=new Rc.default(a);return qr.pattern.isDynamicPattern(o,l)}t.isDynamicPattern=n;function s(o){return Si(o),qr.path.escape(o)}t.escapePath=s})(xc||(xc={}));function Ac(t,e,r){let i=Ym.transform([].concat(t)),n=new Rc.default(r),s=Wm.generate(i,n),o=new e(n);return s.map(o.read,o)}function Si(t){if(![].concat(t).every(i=>qr.string.isString(i)&&!qr.string.isEmpty(i)))throw new TypeError("Patterns must be a string (non empty) or an array of strings")}Vm.exports=xc});var lg=$((UD,ag)=>{ag.exports=og;og.sync=XO;var ng=require("fs");function ZO(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 sg(t,e,r){return!t.isSymbolicLink()&&!t.isFile()?!1:ZO(e,r)}function og(t,e,r){ng.stat(t,function(i,n){r(i,i?!1:sg(n,t,e))})}function XO(t,e){return sg(ng.statSync(t),t,e)}});var pg=$((GD,fg)=>{fg.exports=ug;ug.sync=JO;var cg=require("fs");function ug(t,e,r){cg.stat(t,function(i,n){r(i,i?!1:hg(n,e))})}function JO(t,e){return hg(cg.statSync(t),e)}function hg(t,e){return t.isFile()&&QO(t,e)}function QO(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),l=parseInt("010",8),c=parseInt("001",8),u=a|l,f=r&c||r&l&&n===o||r&a&&i===s||r&u&&s===0;return f}});var mg=$((WD,dg)=>{var zD=require("fs"),Hs;process.platform==="win32"||global.TESTING_WINDOWS?Hs=lg():Hs=pg();dg.exports=Tc;Tc.sync=eT;function Tc(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){Tc(t,e||{},function(s,o){s?n(s):i(o)})})}Hs(t,e||{},function(i,n){i&&(i.code==="EACCES"||e&&e.ignoreErrors)&&(i=null,n=!1),r(i,n)})}function eT(t,e){try{return Hs.sync(t,e||{})}catch(r){if(e&&e.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var Eg=$((YD,Sg)=>{var vi=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",gg=require("path"),tT=vi?";":":",yg=mg(),bg=t=>Object.assign(new Error(`not found: ${t}`),{code:"ENOENT"}),_g=(t,e)=>{let r=e.colon||tT,i=t.match(/\//)||vi&&t.match(/\\/)?[""]:[...vi?[process.cwd()]:[],...(e.path||process.env.PATH||"").split(r)],n=vi?e.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",s=vi?n.split(r):[""];return vi&&t.indexOf(".")!==-1&&s[0]!==""&&s.unshift(""),{pathEnv:i,pathExt:s,pathExtExe:n}},wg=(t,e,r)=>{typeof e=="function"&&(r=e,e={}),e||(e={});let{pathEnv:i,pathExt:n,pathExtExe:s}=_g(t,e),o=[],a=c=>new Promise((u,f)=>{if(c===i.length)return e.all&&o.length?u(o):f(bg(t));let h=i[c],p=/^".*"$/.test(h)?h.slice(1,-1):h,g=gg.join(p,t),y=!p&&/^\.[\\\/]/.test(t)?t.slice(0,2)+g:g;u(l(y,c,0))}),l=(c,u,f)=>new Promise((h,p)=>{if(f===n.length)return h(a(u+1));let g=n[f];yg(c+g,{pathExt:s},(y,b)=>{if(!y&&b)if(e.all)o.push(c+g);else return h(c+g);return h(l(c,u,f+1))})});return r?a(0).then(c=>r(null,c),r):a(0)},rT=(t,e)=>{e=e||{};let{pathEnv:r,pathExt:i,pathExtExe:n}=_g(t,e),s=[];for(let o=0;o<r.length;o++){let a=r[o],l=/^".*"$/.test(a)?a.slice(1,-1):a,c=gg.join(l,t),u=!l&&/^\.[\\\/]/.test(t)?t.slice(0,2)+c:c;for(let f=0;f<i.length;f++){let h=u+i[f];try{if(yg.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 bg(t)};Sg.exports=wg;wg.sync=rT});var Cc=$((VD,kc)=>{"use strict";var vg=(t={})=>{let e=t.env||process.env;return(t.platform||process.platform)!=="win32"?"PATH":Object.keys(e).reverse().find(i=>i.toUpperCase()==="PATH")||"Path"};kc.exports=vg;kc.exports.default=vg});var Og=$((KD,Ag)=>{"use strict";var Rg=require("path"),iT=Eg(),nT=Cc();function xg(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=iT.sync(t.command,{path:r[nT({env:r})],pathExt:e?Rg.delimiter:void 0})}catch{}finally{s&&process.chdir(i)}return o&&(o=Rg.resolve(n?t.options.cwd:"",o)),o}function sT(t){return xg(t)||xg(t,!0)}Ag.exports=sT});var Tg=$((ZD,Pc)=>{"use strict";var Lc=/([()\][%!^"`<>&|;, *?])/g;function oT(t){return t=t.replace(Lc,"^$1"),t}function aT(t,e){return t=`${t}`,t=t.replace(/(\\*)"/g,'$1$1\\"'),t=t.replace(/(\\*)$/,"$1$1"),t=`"${t}"`,t=t.replace(Lc,"^$1"),e&&(t=t.replace(Lc,"^$1")),t}Pc.exports.command=oT;Pc.exports.argument=aT});var Cg=$((XD,kg)=>{"use strict";kg.exports=/^#!(.*)/});var Pg=$((JD,Lg)=>{"use strict";var lT=Cg();Lg.exports=(t="")=>{let e=t.match(lT);if(!e)return null;let[r,i]=e[0].replace(/#! ?/,"").split(" "),n=r.split("/").pop();return n==="env"?i:i?`${n} ${i}`:n}});var Ng=$((QD,Ig)=>{"use strict";var Ic=require("fs"),cT=Pg();function uT(t){let r=Buffer.alloc(150),i;try{i=Ic.openSync(t,"r"),Ic.readSync(i,r,0,150,0),Ic.closeSync(i)}catch{}return cT(r.toString())}Ig.exports=uT});var Bg=$((eM,Fg)=>{"use strict";var hT=require("path"),Dg=Og(),Mg=Tg(),fT=Ng(),pT=process.platform==="win32",dT=/\.(?:com|exe)$/i,mT=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function gT(t){t.file=Dg(t);let e=t.file&&fT(t.file);return e?(t.args.unshift(t.file),t.command=e,Dg(t)):t.file}function yT(t){if(!pT)return t;let e=gT(t),r=!dT.test(e);if(t.options.forceShell||r){let i=mT.test(e);t.command=hT.normalize(t.command),t.command=Mg.command(t.command),t.args=t.args.map(s=>Mg.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 bT(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:yT(i)}Fg.exports=bT});var qg=$((tM,$g)=>{"use strict";var Nc=process.platform==="win32";function Dc(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 _T(t,e){if(!Nc)return;let r=t.emit;t.emit=function(i,n){if(i==="exit"){let s=jg(n,e,"spawn");if(s)return r.call(t,"error",s)}return r.apply(t,arguments)}}function jg(t,e){return Nc&&t===1&&!e.file?Dc(e.original,"spawn"):null}function wT(t,e){return Nc&&t===1&&!e.file?Dc(e.original,"spawnSync"):null}$g.exports={hookChildProcess:_T,verifyENOENT:jg,verifyENOENTSync:wT,notFoundError:Dc}});var Gg=$((rM,Ri)=>{"use strict";var Hg=require("child_process"),Mc=Bg(),Fc=qg();function Ug(t,e,r){let i=Mc(t,e,r),n=Hg.spawn(i.command,i.args,i.options);return Fc.hookChildProcess(n,i),n}function ST(t,e,r){let i=Mc(t,e,r),n=Hg.spawnSync(i.command,i.args,i.options);return n.error=n.error||Fc.verifyENOENTSync(n.status,i),n}Ri.exports=Ug;Ri.exports.spawn=Ug;Ri.exports.sync=ST;Ri.exports._parse=Mc;Ri.exports._enoent=Fc});var Wg=$((iM,zg)=>{"use strict";zg.exports=t=>{let e=typeof t=="string"?`
|
4
4
|
`:`
|
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
|
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 Kg=$((nM,Rn)=>{"use strict";var vn=require("path"),Yg=Cc(),Vg=t=>{t={cwd:process.cwd(),path:process.env[Yg()],execPath:process.execPath,...t};let e,r=vn.resolve(t.cwd),i=[];for(;e!==r;)i.push(vn.join(r,"node_modules/.bin")),e=r,r=vn.resolve(r,"..");let n=vn.resolve(t.cwd,t.execPath,"..");return i.push(n),i.concat(t.path).join(vn.delimiter)};Rn.exports=Vg;Rn.exports.default=Vg;Rn.exports.env=t=>{t={env:process.env,...t};let e={...t.env},r=Yg({env:e});return t.path=e[r],e[r]=Rn.exports(t),e}});var Xg=$((sM,Bc)=>{"use strict";var Zg=(t,e)=>{for(let r of Reflect.ownKeys(e))Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r));return t};Bc.exports=Zg;Bc.exports.default=Zg});var Qg=$((oM,Gs)=>{"use strict";var ET=Xg(),Us=new WeakMap,Jg=(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(Us.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 ET(s,t),Us.set(s,i),s};Gs.exports=Jg;Gs.exports.default=Jg;Gs.exports.callCount=t=>{if(!Us.has(t))throw new Error(`The given function \`${t.name}\` is not wrapped by the \`onetime\` package`);return Us.get(t)}});var ey=$(zs=>{"use strict";Object.defineProperty(zs,"__esModule",{value:!0});zs.SIGNALS=void 0;var vT=[{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"}];zs.SIGNALS=vT});var jc=$(xi=>{"use strict";Object.defineProperty(xi,"__esModule",{value:!0});xi.SIGRTMAX=xi.getRealtimeSignals=void 0;var RT=function(){let t=ry-ty+1;return Array.from({length:t},xT)};xi.getRealtimeSignals=RT;var xT=function(t,e){return{name:`SIGRT${e+1}`,number:ty+e,action:"terminate",description:"Application-specific signal (realtime)",standard:"posix"}},ty=34,ry=64;xi.SIGRTMAX=ry});var iy=$(Ws=>{"use strict";Object.defineProperty(Ws,"__esModule",{value:!0});Ws.getSignals=void 0;var AT=require("os"),OT=ey(),TT=jc(),kT=function(){let t=(0,TT.getRealtimeSignals)();return[...OT.SIGNALS,...t].map(CT)};Ws.getSignals=kT;var CT=function({name:t,number:e,description:r,action:i,forced:n=!1,standard:s}){let{signals:{[t]:o}}=AT.constants,a=o!==void 0;return{name:t,number:a?o:e,description:r,supported:a,action:i,forced:n,standard:s}}});var sy=$(Ai=>{"use strict";Object.defineProperty(Ai,"__esModule",{value:!0});Ai.signalsByNumber=Ai.signalsByName=void 0;var LT=require("os"),ny=iy(),PT=jc(),IT=function(){return(0,ny.getSignals)().reduce(NT,{})},NT=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}}},DT=IT();Ai.signalsByName=DT;var MT=function(){let t=(0,ny.getSignals)(),e=PT.SIGRTMAX+1,r=Array.from({length:e},(i,n)=>FT(n,t));return Object.assign({},...r)},FT=function(t,e){let r=BT(t,e);if(r===void 0)return{};let{name:i,description:n,supported:s,action:o,forced:a,standard:l}=r;return{[t]:{name:i,number:t,description:n,supported:s,action:o,forced:a,standard:l}}},BT=function(t,e){let r=e.find(({name:i})=>LT.constants.signals[i]===t);return r!==void 0?r:e.find(i=>i.number===t)},jT=MT();Ai.signalsByNumber=jT});var ay=$((hM,oy)=>{"use strict";var{signalsByName:$T}=sy(),qT=({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",HT=({stdout:t,stderr:e,all:r,error:i,signal:n,exitCode:s,command:o,escapedCommand:a,timedOut:l,isCanceled:c,killed:u,parsed:{options:{timeout:f}}})=>{s=s===null?void 0:s,n=n===null?void 0:n;let h=n===void 0?void 0:$T[n].description,p=i&&i.code,y=`Command ${qT({timedOut:l,timeout:f,errorCode:p,signal:n,signalDescription:h,exitCode:s,isCanceled:c})}: ${o}`,b=Object.prototype.toString.call(i)==="[object Error]",x=b?`${y}
|
6
6
|
${i.message}`:y,k=[x,e,t].filter(Boolean).join(`
|
7
|
-
`);return b?(i.originalMessage=i.message,i.message=k):i=new Error(k),i.shortMessage=x,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=!!l,i.isCanceled=c,i.killed=u&&!l,i};oy.exports=HT});var cy=$((fM,$c)=>{"use strict";var Ys=["stdin","stdout","stderr"],UT=t=>Ys.some(e=>t[e]!==void 0),ly=t=>{if(!t)return;let{stdio:e}=t;if(e===void 0)return Ys.map(i=>t[i]);if(UT(t))throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${Ys.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,Ys.length);return Array.from({length:r},(i,n)=>e[n])};$c.exports=ly;$c.exports.node=t=>{let e=ly(t);return e==="ipc"?"ipc":e===void 0||typeof e=="string"?[e,e,e,"ipc"]:e.includes("ipc")?e:[...e,"ipc"]}});var uy=$((pM,Ks)=>{Ks.exports=["SIGABRT","SIGALRM","SIGHUP","SIGINT","SIGTERM"];process.platform!=="win32"&&Ks.exports.push("SIGVTALRM","SIGXCPU","SIGXFSZ","SIGUSR2","SIGTRAP","SIGSYS","SIGQUIT","SIGIOT");process.platform==="linux"&&Ks.exports.push("SIGIO","SIGPOLL","SIGPWR","SIGSTKFLT","SIGUNUSED")});var my=$((dM,ki)=>{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)?(hy=require("assert"),Oi=uy(),fy=/^win/i.test(ye.platform),xn=require("events"),typeof xn!="function"&&(xn=xn.EventEmitter),ye.__signal_exit_emitter__?Te=ye.__signal_exit_emitter__:(Te=ye.__signal_exit_emitter__=new xn,Te.count=0,Te.emitted={}),Te.infinite||(Te.setMaxListeners(1/0),Te.infinite=!0),ki.exports=function(t,e){if(!Hr(global.process))return function(){};hy.equal(typeof t,"function","a callback must be provided for exit handler"),Ti===!1&&qc();var r="exit";e&&e.alwaysLast&&(r="afterexit");var i=function(){Te.removeListener(r,t),Te.listeners("exit").length===0&&Te.listeners("afterexit").length===0&&Vs()};return Te.on(r,t),i},Vs=function(){!Ti||!Hr(global.process)||(Ti=!1,Oi.forEach(function(e){try{ye.removeListener(e,Zs[e])}catch{}}),ye.emit=Xs,ye.reallyExit=Hc,Te.count-=1)},ki.exports.unload=Vs,Ur=function(e,r,i){Te.emitted[e]||(Te.emitted[e]=!0,Te.emit(e,r,i))},Zs={},Oi.forEach(function(t){Zs[t]=function(){if(Hr(global.process)){var r=ye.listeners(t);r.length===Te.count&&(Vs(),Ur("exit",null,t),Ur("afterexit",null,t),fy&&t==="SIGHUP"&&(t="SIGINT"),ye.kill(ye.pid,t))}}}),ki.exports.signals=function(){return Oi},Ti=!1,qc=function(){Ti||!Hr(global.process)||(Ti=!0,Te.count+=1,Oi=Oi.filter(function(e){try{return ye.on(e,Zs[e]),!0}catch{return!1}}),ye.emit=dy,ye.reallyExit=py)},ki.exports.load=qc,Hc=ye.reallyExit,py=function(e){Hr(global.process)&&(ye.exitCode=e||0,Ur("exit",ye.exitCode,null),Ur("afterexit",ye.exitCode,null),Hc.call(ye,ye.exitCode))},Xs=ye.emit,dy=function(e,r){if(e==="exit"&&Hr(global.process)){r!==void 0&&(ye.exitCode=r);var i=Xs.apply(this,arguments);return Ur("exit",ye.exitCode,null),Ur("afterexit",ye.exitCode,null),i}else return Xs.apply(this,arguments)}):ki.exports=function(){return function(){}};var hy,Oi,fy,xn,Te,Vs,Ur,Zs,Ti,qc,Hc,py,Xs,dy});var yy=$((mM,gy)=>{"use strict";var GT=require("os"),zT=my(),WT=1e3*5,YT=(t,e="SIGTERM",r={})=>{let i=t(e);return KT(t,e,r,i),i},KT=(t,e,r,i)=>{if(!VT(e,r,i))return;let n=XT(r),s=setTimeout(()=>{t("SIGKILL")},n);s.unref&&s.unref()},VT=(t,{forceKillAfterTimeout:e},r)=>ZT(t)&&e!==!1&&r,ZT=t=>t===GT.constants.signals.SIGTERM||typeof t=="string"&&t.toUpperCase()==="SIGTERM",XT=({forceKillAfterTimeout:t=!0})=>{if(t===!0)return WT;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},JT=(t,e)=>{t.kill()&&(e.isCanceled=!0)},QT=(t,e,r)=>{t.kill(e),r(Object.assign(new Error("Timed out"),{timedOut:!0,signal:e}))},ek=(t,{timeout:e,killSignal:r="SIGTERM"},i)=>{if(e===0||e===void 0)return i;let n,s=new Promise((a,l)=>{n=setTimeout(()=>{QT(t,r,l)},e)}),o=i.finally(()=>{clearTimeout(n)});return Promise.race([s,o])},tk=({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})`)},rk=async(t,{cleanup:e,detached:r},i)=>{if(!e||r)return i;let n=zT(()=>{t.kill()});return i.finally(()=>{n()})};gy.exports={spawnedKill:YT,spawnedCancel:JT,setupTimeout:ek,validateTimeout:tk,setExitHandler:rk}});var _y=$((gM,by)=>{"use strict";var Ot=t=>t!==null&&typeof t=="object"&&typeof t.pipe=="function";Ot.writable=t=>Ot(t)&&t.writable!==!1&&typeof t._write=="function"&&typeof t._writableState=="object";Ot.readable=t=>Ot(t)&&t.readable!==!1&&typeof t._read=="function"&&typeof t._readableState=="object";Ot.duplex=t=>Ot.writable(t)&&Ot.readable(t);Ot.transform=t=>Ot.duplex(t)&&typeof t._transform=="function";by.exports=Ot});var Sy=$((yM,wy)=>{"use strict";var{PassThrough:ik}=require("stream");wy.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 ik({objectMode:n});r&&s.setEncoding(r);let o=0,a=[];return s.on("data",l=>{a.push(l),n?o=a.length:o+=l.length}),s.getBufferedValue=()=>e?a:i?Buffer.concat(a,o):a.join(""),s.getBufferedLength=()=>o,s}});var Ey=$((bM,An)=>{"use strict";var{constants:nk}=require("buffer"),sk=require("stream"),{promisify:ok}=require("util"),ak=Sy(),lk=ok(sk.pipeline),Js=class extends Error{constructor(){super("maxBuffer exceeded"),this.name="MaxBufferError"}};async function Uc(t,e){if(!t)throw new Error("Expected a stream");e={maxBuffer:1/0,...e};let{maxBuffer:r}=e,i=ak(e);return await new Promise((n,s)=>{let o=a=>{a&&i.getBufferedLength()<=nk.MAX_LENGTH&&(a.bufferedData=i.getBufferedValue()),s(a)};(async()=>{try{await lk(t,i),n()}catch(a){o(a)}})(),i.on("data",()=>{i.getBufferedLength()>r&&o(new Js)})}),i.getBufferedValue()}An.exports=Uc;An.exports.buffer=(t,e)=>Uc(t,{...e,encoding:"buffer"});An.exports.array=(t,e)=>Uc(t,{...e,array:!0});An.exports.MaxBufferError=Js});var Ry=$((_M,vy)=>{"use strict";var{PassThrough:ck}=require("stream");vy.exports=function(){var t=[],e=new ck({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 Ty=$((wM,Oy)=>{"use strict";var Ay=_y(),xy=Ey(),uk=Ry(),hk=(t,e)=>{e===void 0||t.stdin===void 0||(Ay(e)?e.pipe(t.stdin):t.stdin.end(e))},fk=(t,{all:e})=>{if(!e||!t.stdout&&!t.stderr)return;let r=uk();return t.stdout&&r.add(t.stdout),t.stderr&&r.add(t.stderr),r},Gc=async(t,e)=>{if(t){t.destroy();try{return await e}catch(r){return r.bufferedData}}},zc=(t,{encoding:e,buffer:r,maxBuffer:i})=>{if(!(!t||!r))return e?xy(t,{encoding:e,maxBuffer:i}):xy.buffer(t,{maxBuffer:i})},pk=async({stdout:t,stderr:e,all:r},{encoding:i,buffer:n,maxBuffer:s},o)=>{let a=zc(t,{encoding:i,buffer:n,maxBuffer:s}),l=zc(e,{encoding:i,buffer:n,maxBuffer:s}),c=zc(r,{encoding:i,buffer:n,maxBuffer:s*2});try{return await Promise.all([o,a,l,c])}catch(u){return Promise.all([{error:u,signal:u.signal,timedOut:u.timedOut},Gc(t,a),Gc(e,l),Gc(r,c)])}},dk=({input:t})=>{if(Ay(t))throw new TypeError("The `input` option cannot be a stream in sync mode")};Oy.exports={handleInput:hk,makeAllStream:fk,getSpawnedResult:pk,validateInputSync:dk}});var Cy=$((SM,ky)=>{"use strict";var mk=(async()=>{})().constructor.prototype,gk=["then","catch","finally"].map(t=>[t,Reflect.getOwnPropertyDescriptor(mk,t)]),yk=(t,e)=>{for(let[r,i]of gk){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},bk=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)})});ky.exports={mergePromise:yk,getSpawnedPromise:bk}});var Iy=$((EM,Py)=>{"use strict";var Ly=(t,e=[])=>Array.isArray(e)?[t,...e]:[t],_k=/^[\w.-]+$/,wk=/"/g,Sk=t=>typeof t!="string"||_k.test(t)?t:`"${t.replace(wk,'\\"')}"`,Ek=(t,e)=>Ly(t,e).join(" "),vk=(t,e)=>Ly(t,e).map(r=>Sk(r)).join(" "),Rk=/ +/g,xk=t=>{let e=[];for(let r of t.trim().split(Rk)){let i=e[e.length-1];i&&i.endsWith("\\")?e[e.length-1]=`${i.slice(0,-1)} ${r}`:e.push(r)}return e};Py.exports={joinCommand:Ek,getEscapedCommand:vk,parseCommand:xk}});var Li=$((vM,Ci)=>{"use strict";var Ak=require("path"),Wc=require("child_process"),Ok=Gg(),Tk=Wg(),kk=Vg(),Ck=Qg(),Qs=ay(),Dy=cy(),{spawnedKill:Lk,spawnedCancel:Pk,setupTimeout:Ik,validateTimeout:Nk,setExitHandler:Dk}=yy(),{handleInput:Mk,getSpawnedResult:Fk,makeAllStream:Bk,validateInputSync:jk}=Ty(),{mergePromise:Ny,getSpawnedPromise:$k}=Cy(),{joinCommand:My,parseCommand:Fy,getEscapedCommand:By}=Iy(),qk=1e3*1e3*100,Hk=({env:t,extendEnv:e,preferLocal:r,localDir:i,execPath:n})=>{let s=e?{...process.env,...t}:t;return r?kk.env({env:s,cwd:i,execPath:n}):s},jy=(t,e,r={})=>{let i=Ok._parse(t,e,r);return t=i.command,e=i.args,r=i.options,r={maxBuffer:qk,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=Hk(r),r.stdio=Dy(r),process.platform==="win32"&&Ak.basename(t,".exe")==="cmd"&&e.unshift("/q"),{file:t,args:e,options:r,parsed:i}},On=(t,e,r)=>typeof e!="string"&&!Buffer.isBuffer(e)?r===void 0?void 0:"":t.stripFinalNewline?Tk(e):e,eo=(t,e,r)=>{let i=jy(t,e,r),n=My(t,e),s=By(t,e);Nk(i.options);let o;try{o=Wc.spawn(i.file,i.args,i.options)}catch(p){let g=new Wc.ChildProcess,y=Promise.reject(Qs({error:p,stdout:"",stderr:"",all:"",command:n,escapedCommand:s,parsed:i,timedOut:!1,isCanceled:!1,killed:!1}));return Ny(g,y)}let a=$k(o),l=Ik(o,i.options,a),c=Dk(o,i.options,l),u={isCanceled:!1};o.kill=Lk.bind(null,o.kill.bind(o)),o.cancel=Pk.bind(null,o,u);let h=Ck(async()=>{let[{error:p,exitCode:g,signal:y,timedOut:b},x,k,C]=await Fk(o,i.options,c),T=On(i.options,x),O=On(i.options,k),I=On(i.options,C);if(p||g!==0||y!==null){let w=Qs({error:p,exitCode:g,signal:y,stdout:T,stderr:O,all:I,command:n,escapedCommand:s,parsed:i,timedOut:b,isCanceled:u.isCanceled,killed:o.killed});if(!i.options.reject)return w;throw w}return{command:n,escapedCommand:s,exitCode:0,stdout:T,stderr:O,all:I,failed:!1,timedOut:!1,isCanceled:!1,killed:!1}});return Mk(o,i.options.input),o.all=Bk(o,i.options),Ny(o,h)};Ci.exports=eo;Ci.exports.sync=(t,e,r)=>{let i=jy(t,e,r),n=My(t,e),s=By(t,e);jk(i.options);let o;try{o=Wc.spawnSync(i.file,i.args,i.options)}catch(c){throw Qs({error:c,stdout:"",stderr:"",all:"",command:n,escapedCommand:s,parsed:i,timedOut:!1,isCanceled:!1,killed:!1})}let a=On(i.options,o.stdout,o.error),l=On(i.options,o.stderr,o.error);if(o.error||o.status!==0||o.signal!==null){let c=Qs({stdout:a,stderr:l,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 c;throw c}return{command:n,escapedCommand:s,exitCode:0,stdout:a,stderr:l,failed:!1,timedOut:!1,isCanceled:!1,killed:!1}};Ci.exports.command=(t,e)=>{let[r,...i]=Fy(t);return eo(r,i,e)};Ci.exports.commandSync=(t,e)=>{let[r,...i]=Fy(t);return eo.sync(r,i,e)};Ci.exports.node=(t,e,r={})=>{e&&!Array.isArray(e)&&typeof e=="object"&&(r=e,e=[]);let i=Dy.node(r),n=process.execArgv.filter(a=>!a.startsWith("--inspect")),{nodePath:s=process.execPath,nodeOptions:o=n}=r;return eo(s,[...o,t,...Array.isArray(e)?e:[]],{...r,stdin:void 0,stdout:void 0,stderr:void 0,stdio:i,shell:!1})}});var Pi=$((TM,Gy)=>{"use strict";var Uy=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"]]);Gy.exports=t=>t?Object.keys(t).map(e=>[Uy.has(e)?Uy.get(e):e,t[e]]).reduce((e,r)=>(e[r[0]]=r[1],e),Object.create(null)):{}});var oo=$((kM,Qy)=>{"use strict";var zy=typeof process=="object"&&process?process:{stdout:null,stderr:null},Yk=require("events"),Wy=require("stream"),Yy=require("string_decoder").StringDecoder,zt=Symbol("EOF"),Wt=Symbol("maybeEmitEnd"),yr=Symbol("emittedEnd"),to=Symbol("emittingEnd"),Tn=Symbol("emittedError"),ro=Symbol("closed"),Ky=Symbol("read"),io=Symbol("flush"),Vy=Symbol("flushChunk"),Ye=Symbol("encoding"),Yt=Symbol("decoder"),no=Symbol("flowing"),kn=Symbol("paused"),Ii=Symbol("resume"),Se=Symbol("buffer"),Tt=Symbol("pipes"),ke=Symbol("bufferLength"),Vc=Symbol("bufferPush"),Zc=Symbol("bufferShift"),De=Symbol("objectMode"),Me=Symbol("destroyed"),Xc=Symbol("emitData"),Zy=Symbol("emitEnd"),Jc=Symbol("emitEnd2"),Kt=Symbol("async"),Cn=t=>Promise.resolve().then(t),Xy=global._MP_NO_ITERATOR_SYMBOLS_!=="1",Kk=Xy&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),Vk=Xy&&Symbol.iterator||Symbol("iterator not implemented"),Zk=t=>t==="end"||t==="finish"||t==="prefinish",Xk=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,Jk=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),so=class{constructor(e,r,i){this.src=e,this.dest=r,this.opts=i,this.ondrain=()=>e[Ii](),r.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},Qc=class extends so{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)}};Qy.exports=class Jy extends Wy{constructor(e){super(),this[no]=!1,this[kn]=!1,this[Tt]=[],this[Se]=[],this[De]=e&&e.objectMode||!1,this[De]?this[Ye]=null:this[Ye]=e&&e.encoding||null,this[Ye]==="buffer"&&(this[Ye]=null),this[Kt]=e&&!!e.async||!1,this[Yt]=this[Ye]?new Yy(this[Ye]):null,this[zt]=!1,this[yr]=!1,this[to]=!1,this[ro]=!1,this[Tn]=null,this.writable=!0,this.readable=!0,this[ke]=0,this[Me]=!1,e&&e.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[Se]}),e&&e.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[Tt]})}get bufferLength(){return this[ke]}get encoding(){return this[Ye]}set encoding(e){if(this[De])throw new Error("cannot set encoding in objectMode");if(this[Ye]&&e!==this[Ye]&&(this[Yt]&&this[Yt].lastNeed||this[ke]))throw new Error("cannot change encoding");this[Ye]!==e&&(this[Yt]=e?new Yy(e):null,this[Se].length&&(this[Se]=this[Se].map(r=>this[Yt].write(r)))),this[Ye]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[De]}set objectMode(e){this[De]=this[De]||!!e}get async(){return this[Kt]}set async(e){this[Kt]=this[Kt]||!!e}write(e,r,i){if(this[zt])throw new Error("write after end");if(this[Me])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]?Cn:s=>s();return!this[De]&&!Buffer.isBuffer(e)&&(Jk(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):Xk(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),this[De]?(this.flowing&&this[ke]!==0&&this[io](!0),this.flowing?this.emit("data",e):this[Vc](e),this[ke]!==0&&this.emit("readable"),i&&n(i),this.flowing):e.length?(typeof e=="string"&&!(r===this[Ye]&&!this[Yt].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[Ye]&&(e=this[Yt].write(e)),this.flowing&&this[ke]!==0&&this[io](!0),this.flowing?this.emit("data",e):this[Vc](e),this[ke]!==0&&this.emit("readable"),i&&n(i),this.flowing):(this[ke]!==0&&this.emit("readable"),i&&n(i),this.flowing)}read(e){if(this[Me])return null;if(this[ke]===0||e===0||e>this[ke])return this[Wt](),null;this[De]&&(e=null),this[Se].length>1&&!this[De]&&(this.encoding?this[Se]=[this[Se].join("")]:this[Se]=[Buffer.concat(this[Se],this[ke])]);let r=this[Ky](e||null,this[Se][0]);return this[Wt](),r}[Ky](e,r){return e===r.length||e===null?this[Zc]():(this[Se][0]=r.slice(e),r=r.slice(0,e),this[ke]-=e),this.emit("data",r),!this[Se].length&&!this[zt]&&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[zt]=!0,this.writable=!1,(this.flowing||!this[kn])&&this[Wt](),this}[Ii](){this[Me]||(this[kn]=!1,this[no]=!0,this.emit("resume"),this[Se].length?this[io]():this[zt]?this[Wt]():this.emit("drain"))}resume(){return this[Ii]()}pause(){this[no]=!1,this[kn]=!0}get destroyed(){return this[Me]}get flowing(){return this[no]}get paused(){return this[kn]}[Vc](e){this[De]?this[ke]+=1:this[ke]+=e.length,this[Se].push(e)}[Zc](){return this[Se].length&&(this[De]?this[ke]-=1:this[ke]-=this[Se][0].length),this[Se].shift()}[io](e){do;while(this[Vy](this[Zc]()));!e&&!this[Se].length&&!this[zt]&&this.emit("drain")}[Vy](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Me])return;let i=this[yr];return r=r||{},e===zy.stdout||e===zy.stderr?r.end=!1:r.end=r.end!==!1,r.proxyErrors=!!r.proxyErrors,i?r.end&&e.end():(this[Tt].push(r.proxyErrors?new Qc(this,e,r):new so(this,e,r)),this[Kt]?Cn(()=>this[Ii]()):this[Ii]()),e}unpipe(e){let r=this[Tt].find(i=>i.dest===e);r&&(this[Tt].splice(this[Tt].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[Tt].length&&!this.flowing?this[Ii]():e==="readable"&&this[ke]!==0?super.emit("readable"):Zk(e)&&this[yr]?(super.emit(e),this.removeAllListeners(e)):e==="error"&&this[Tn]&&(this[Kt]?Cn(()=>r.call(this,this[Tn])):r.call(this,this[Tn])),i}get emittedEnd(){return this[yr]}[Wt](){!this[to]&&!this[yr]&&!this[Me]&&this[Se].length===0&&this[zt]&&(this[to]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[ro]&&this.emit("close"),this[to]=!1)}emit(e,r,...i){if(e!=="error"&&e!=="close"&&e!==Me&&this[Me])return;if(e==="data")return r?this[Kt]?Cn(()=>this[Xc](r)):this[Xc](r):!1;if(e==="end")return this[Zy]();if(e==="close"){if(this[ro]=!0,!this[yr]&&!this[Me])return;let s=super.emit("close");return this.removeAllListeners("close"),s}else if(e==="error"){this[Tn]=r;let s=super.emit("error",r);return this[Wt](),s}else if(e==="resume"){let s=super.emit("resume");return this[Wt](),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[Wt](),n}[Xc](e){for(let i of this[Tt])i.dest.write(e)===!1&&this.pause();let r=super.emit("data",e);return this[Wt](),r}[Zy](){this[yr]||(this[yr]=!0,this.readable=!1,this[Kt]?Cn(()=>this[Jc]()):this[Jc]())}[Jc](){if(this[Yt]){let r=this[Yt].end();if(r){for(let i of this[Tt])i.dest.write(r);super.emit("data",r)}}for(let r of this[Tt])r.end();let e=super.emit("end");return this.removeAllListeners("end"),e}collect(){let e=[];this[De]||(e.dataLength=0);let r=this.promise();return this.on("data",i=>{e.push(i),this[De]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[De]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[De]?Promise.reject(new Error("cannot concat in objectMode")):this[Ye]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Me,()=>r(new Error("stream destroyed"))),this.on("error",i=>r(i)),this.on("end",()=>e())})}[Kk](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[zt])return Promise.resolve({done:!0});let i=null,n=null,s=c=>{this.removeListener("data",o),this.removeListener("end",a),n(c)},o=c=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:c,done:!!this[zt]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},l=()=>s(new Error("stream destroyed"));return new Promise((c,u)=>{n=u,i=c,this.once(Me,l),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[Vk](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Me]?(e?this.emit("error",e):this.emit(Me),this):(this[Me]=!0,this[Se].length=0,this[ke]=0,typeof this.close=="function"&&!this[ro]&&this.close(),e?this.emit("error",e):this.emit(Me),this)}static isStream(e){return!!e&&(e instanceof Jy||e instanceof Wy||e instanceof Yk&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var tb=$((CM,eb)=>{var Qk=require("zlib").constants||{ZLIB_VERNUM:4736};eb.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},Qk))});var su=$((LM,ub)=>{"use strict";var rb=typeof process=="object"&&process?process:{stdout:null,stderr:null},e1=require("events"),ib=require("stream"),nb=require("string_decoder").StringDecoder,Vt=Symbol("EOF"),Zt=Symbol("maybeEmitEnd"),br=Symbol("emittedEnd"),ao=Symbol("emittingEnd"),Ln=Symbol("emittedError"),lo=Symbol("closed"),sb=Symbol("read"),co=Symbol("flush"),ob=Symbol("flushChunk"),Ke=Symbol("encoding"),Xt=Symbol("decoder"),uo=Symbol("flowing"),Pn=Symbol("paused"),Ni=Symbol("resume"),Ce=Symbol("bufferLength"),eu=Symbol("bufferPush"),tu=Symbol("bufferShift"),Fe=Symbol("objectMode"),Be=Symbol("destroyed"),ru=Symbol("emitData"),ab=Symbol("emitEnd"),iu=Symbol("emitEnd2"),Jt=Symbol("async"),In=t=>Promise.resolve().then(t),lb=global._MP_NO_ITERATOR_SYMBOLS_!=="1",t1=lb&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),r1=lb&&Symbol.iterator||Symbol("iterator not implemented"),i1=t=>t==="end"||t==="finish"||t==="prefinish",n1=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,s1=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),ho=class{constructor(e,r,i){this.src=e,this.dest=r,this.opts=i,this.ondrain=()=>e[Ni](),r.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},nu=class extends ho{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)}};ub.exports=class cb extends ib{constructor(e){super(),this[uo]=!1,this[Pn]=!1,this.pipes=[],this.buffer=[],this[Fe]=e&&e.objectMode||!1,this[Fe]?this[Ke]=null:this[Ke]=e&&e.encoding||null,this[Ke]==="buffer"&&(this[Ke]=null),this[Jt]=e&&!!e.async||!1,this[Xt]=this[Ke]?new nb(this[Ke]):null,this[Vt]=!1,this[br]=!1,this[ao]=!1,this[lo]=!1,this[Ln]=null,this.writable=!0,this.readable=!0,this[Ce]=0,this[Be]=!1}get bufferLength(){return this[Ce]}get encoding(){return this[Ke]}set encoding(e){if(this[Fe])throw new Error("cannot set encoding in objectMode");if(this[Ke]&&e!==this[Ke]&&(this[Xt]&&this[Xt].lastNeed||this[Ce]))throw new Error("cannot change encoding");this[Ke]!==e&&(this[Xt]=e?new nb(e):null,this.buffer.length&&(this.buffer=this.buffer.map(r=>this[Xt].write(r)))),this[Ke]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[Fe]}set objectMode(e){this[Fe]=this[Fe]||!!e}get async(){return this[Jt]}set async(e){this[Jt]=this[Jt]||!!e}write(e,r,i){if(this[Vt])throw new Error("write after end");if(this[Be])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[Jt]?In:s=>s();return!this[Fe]&&!Buffer.isBuffer(e)&&(s1(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):n1(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),this[Fe]?(this.flowing&&this[Ce]!==0&&this[co](!0),this.flowing?this.emit("data",e):this[eu](e),this[Ce]!==0&&this.emit("readable"),i&&n(i),this.flowing):e.length?(typeof e=="string"&&!(r===this[Ke]&&!this[Xt].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[Ke]&&(e=this[Xt].write(e)),this.flowing&&this[Ce]!==0&&this[co](!0),this.flowing?this.emit("data",e):this[eu](e),this[Ce]!==0&&this.emit("readable"),i&&n(i),this.flowing):(this[Ce]!==0&&this.emit("readable"),i&&n(i),this.flowing)}read(e){if(this[Be])return null;if(this[Ce]===0||e===0||e>this[Ce])return this[Zt](),null;this[Fe]&&(e=null),this.buffer.length>1&&!this[Fe]&&(this.encoding?this.buffer=[this.buffer.join("")]:this.buffer=[Buffer.concat(this.buffer,this[Ce])]);let r=this[sb](e||null,this.buffer[0]);return this[Zt](),r}[sb](e,r){return e===r.length||e===null?this[tu]():(this.buffer[0]=r.slice(e),r=r.slice(0,e),this[Ce]-=e),this.emit("data",r),!this.buffer.length&&!this[Vt]&&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[Vt]=!0,this.writable=!1,(this.flowing||!this[Pn])&&this[Zt](),this}[Ni](){this[Be]||(this[Pn]=!1,this[uo]=!0,this.emit("resume"),this.buffer.length?this[co]():this[Vt]?this[Zt]():this.emit("drain"))}resume(){return this[Ni]()}pause(){this[uo]=!1,this[Pn]=!0}get destroyed(){return this[Be]}get flowing(){return this[uo]}get paused(){return this[Pn]}[eu](e){this[Fe]?this[Ce]+=1:this[Ce]+=e.length,this.buffer.push(e)}[tu](){return this.buffer.length&&(this[Fe]?this[Ce]-=1:this[Ce]-=this.buffer[0].length),this.buffer.shift()}[co](e){do;while(this[ob](this[tu]()));!e&&!this.buffer.length&&!this[Vt]&&this.emit("drain")}[ob](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Be])return;let i=this[br];return r=r||{},e===rb.stdout||e===rb.stderr?r.end=!1:r.end=r.end!==!1,r.proxyErrors=!!r.proxyErrors,i?r.end&&e.end():(this.pipes.push(r.proxyErrors?new nu(this,e,r):new ho(this,e,r)),this[Jt]?In(()=>this[Ni]()):this[Ni]()),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[Ni]():e==="readable"&&this[Ce]!==0?super.emit("readable"):i1(e)&&this[br]?(super.emit(e),this.removeAllListeners(e)):e==="error"&&this[Ln]&&(this[Jt]?In(()=>r.call(this,this[Ln])):r.call(this,this[Ln])),i}get emittedEnd(){return this[br]}[Zt](){!this[ao]&&!this[br]&&!this[Be]&&this.buffer.length===0&&this[Vt]&&(this[ao]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[lo]&&this.emit("close"),this[ao]=!1)}emit(e,r,...i){if(e!=="error"&&e!=="close"&&e!==Be&&this[Be])return;if(e==="data")return r?this[Jt]?In(()=>this[ru](r)):this[ru](r):!1;if(e==="end")return this[ab]();if(e==="close"){if(this[lo]=!0,!this[br]&&!this[Be])return;let s=super.emit("close");return this.removeAllListeners("close"),s}else if(e==="error"){this[Ln]=r;let s=super.emit("error",r);return this[Zt](),s}else if(e==="resume"){let s=super.emit("resume");return this[Zt](),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[Zt](),n}[ru](e){for(let i of this.pipes)i.dest.write(e)===!1&&this.pause();let r=super.emit("data",e);return this[Zt](),r}[ab](){this[br]||(this[br]=!0,this.readable=!1,this[Jt]?In(()=>this[iu]()):this[iu]())}[iu](){if(this[Xt]){let r=this[Xt].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[Fe]||(e.dataLength=0);let r=this.promise();return this.on("data",i=>{e.push(i),this[Fe]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[Fe]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[Fe]?Promise.reject(new Error("cannot concat in objectMode")):this[Ke]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Be,()=>r(new Error("stream destroyed"))),this.on("error",i=>r(i)),this.on("end",()=>e())})}[t1](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[Vt])return Promise.resolve({done:!0});let i=null,n=null,s=c=>{this.removeListener("data",o),this.removeListener("end",a),n(c)},o=c=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:c,done:!!this[Vt]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},l=()=>s(new Error("stream destroyed"));return new Promise((c,u)=>{n=u,i=c,this.once(Be,l),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[r1](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Be]?(e?this.emit("error",e):this.emit(Be),this):(this[Be]=!0,this.buffer.length=0,this[Ce]=0,typeof this.close=="function"&&!this[lo]&&this.close(),e?this.emit("error",e):this.emit(Be),this)}static isStream(e){return!!e&&(e instanceof cb||e instanceof ib||e instanceof e1&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var Su=$(tt=>{"use strict";var uu=require("assert"),_r=require("buffer").Buffer,pb=require("zlib"),Gr=tt.constants=tb(),o1=su(),hb=_r.concat,zr=Symbol("_superWrite"),Mi=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"}},a1=Symbol("opts"),Nn=Symbol("flushFlag"),fb=Symbol("finishFlushFlag"),wu=Symbol("fullFlushFlag"),de=Symbol("handle"),fo=Symbol("onError"),Di=Symbol("sawError"),ou=Symbol("level"),au=Symbol("strategy"),lu=Symbol("ended"),PM=Symbol("_defaultFullFlush"),po=class extends o1{constructor(e,r){if(!e||typeof e!="object")throw new TypeError("invalid options for ZlibBase constructor");super(e),this[Di]=!1,this[lu]=!1,this[a1]=e,this[Nn]=e.flush,this[fb]=e.finishFlush;try{this[de]=new pb[r](e)}catch(i){throw new Mi(i)}this[fo]=i=>{this[Di]||(this[Di]=!0,this.close(),this.emit("error",i))},this[de].on("error",i=>this[fo](new Mi(i))),this.once("end",()=>this.close)}close(){this[de]&&(this[de].close(),this[de]=null,this.emit("close"))}reset(){if(!this[Di])return uu(this[de],"zlib binding closed"),this[de].reset()}flush(e){this.ended||(typeof e!="number"&&(e=this[wu]),this.write(Object.assign(_r.alloc(0),{[Nn]:e})))}end(e,r,i){return e&&this.write(e,r),this.flush(this[fb]),this[lu]=!0,super.end(null,null,i)}get ended(){return this[lu]}write(e,r,i){if(typeof r=="function"&&(i=r,r="utf8"),typeof e=="string"&&(e=_r.from(e,r)),this[Di])return;uu(this[de],"zlib binding closed");let n=this[de]._handle,s=n.close;n.close=()=>{};let o=this[de].close;this[de].close=()=>{},_r.concat=c=>c;let a;try{let c=typeof e[Nn]=="number"?e[Nn]:this[Nn];a=this[de]._processChunk(e,c),_r.concat=hb}catch(c){_r.concat=hb,this[fo](new Mi(c))}finally{this[de]&&(this[de]._handle=n,n.close=s,this[de].close=o,this[de].removeAllListeners("error"))}this[de]&&this[de].on("error",c=>this[fo](new Mi(c)));let l;if(a)if(Array.isArray(a)&&a.length>0){l=this[zr](_r.from(a[0]));for(let c=1;c<a.length;c++)l=this[zr](a[c])}else l=this[zr](_r.from(a));return i&&i(),l}[zr](e){return super.write(e)}},Qt=class extends po{constructor(e,r){e=e||{},e.flush=e.flush||Gr.Z_NO_FLUSH,e.finishFlush=e.finishFlush||Gr.Z_FINISH,super(e,r),this[wu]=Gr.Z_FULL_FLUSH,this[ou]=e.level,this[au]=e.strategy}params(e,r){if(!this[Di]){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[ou]!==e||this[au]!==r){this.flush(Gr.Z_SYNC_FLUSH),uu(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[ou]=e,this[au]=r)}}}},hu=class extends Qt{constructor(e){super(e,"Deflate")}},fu=class extends Qt{constructor(e){super(e,"Inflate")}},cu=Symbol("_portable"),pu=class extends Qt{constructor(e){super(e,"Gzip"),this[cu]=e&&!!e.portable}[zr](e){return this[cu]?(this[cu]=!1,e[9]=255,super[zr](e)):super[zr](e)}},du=class extends Qt{constructor(e){super(e,"Gunzip")}},mu=class extends Qt{constructor(e){super(e,"DeflateRaw")}},gu=class extends Qt{constructor(e){super(e,"InflateRaw")}},yu=class extends Qt{constructor(e){super(e,"Unzip")}},mo=class extends po{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[wu]=Gr.BROTLI_OPERATION_FLUSH}},bu=class extends mo{constructor(e){super(e,"BrotliCompress")}},_u=class extends mo{constructor(e){super(e,"BrotliDecompress")}};tt.Deflate=hu;tt.Inflate=fu;tt.Gzip=pu;tt.Gunzip=du;tt.DeflateRaw=mu;tt.InflateRaw=gu;tt.Unzip=yu;typeof pb.BrotliCompress=="function"?(tt.BrotliCompress=bu,tt.BrotliDecompress=_u):tt.BrotliCompress=tt.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}});var Fi=$((DM,db)=>{var l1=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform;db.exports=l1!=="win32"?t=>t:t=>t&&t.replace(/\\/g,"/")});var go=$((FM,mb)=>{"use strict";var c1=oo(),Eu=Fi(),vu=Symbol("slurp");mb.exports=class extends c1{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=Eu(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=Eu(e.linkpath),this.uname=e.uname,this.gname=e.gname,r&&this[vu](r),i&&this[vu](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))}[vu](e,r){for(let i in e)e[i]!==null&&e[i]!==void 0&&!(r&&i==="path")&&(this[i]=i==="path"||i==="linkpath"?Eu(e[i]):e[i])}}});var Ru=$(yo=>{"use strict";yo.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"]]);yo.code=new Map(Array.from(yo.name).map(t=>[t[1],t[0]]))});var _b=$((jM,bb)=>{"use strict";var u1=(t,e)=>{if(Number.isSafeInteger(t))t<0?f1(t,e):h1(t,e);else throw Error("cannot encode number outside of javascript safe integer range");return e},h1=(t,e)=>{e[0]=128;for(var r=e.length;r>1;r--)e[r-1]=t&255,t=Math.floor(t/256)},f1=(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]=gb(n):n===0?e[i-1]=0:(r=!0,e[i-1]=yb(n))}},p1=t=>{let e=t[0],r=e===128?m1(t.slice(1,t.length)):e===255?d1(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},d1=t=>{for(var e=t.length,r=0,i=!1,n=e-1;n>-1;n--){var s=t[n],o;i?o=gb(s):s===0?o=s:(i=!0,o=yb(s)),o!==0&&(r-=o*Math.pow(256,e-n-1))}return r},m1=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},gb=t=>(255^t)&255,yb=t=>(255^t)+1&255;bb.exports={encode:u1,parse:p1}});var ji=$(($M,Sb)=>{"use strict";var xu=Ru(),Bi=require("path").posix,wb=_b(),Au=Symbol("slurp"),rt=Symbol("type"),ku=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[rt]="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=wr(e,r+100,8),this.uid=wr(e,r+108,8),this.gid=wr(e,r+116,8),this.size=wr(e,r+124,12),this.mtime=Ou(e,r+136,12),this.cksum=wr(e,r+148,12),this[Au](i),this[Au](n,!0),this[rt]=Wr(e,r+156,1),this[rt]===""&&(this[rt]="0"),this[rt]==="0"&&this.path.slice(-1)==="/"&&(this[rt]="5"),this[rt]==="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=wr(e,r+329,8),this.devmin=wr(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=Ou(e,r+476,12),this.ctime=Ou(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)}[Au](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=g1(this.path||"",i),s=n[0],o=n[1];this.needPax=n[2],this.needPax=Yr(e,r,100,s)||this.needPax,this.needPax=Sr(e,r+100,8,this.mode)||this.needPax,this.needPax=Sr(e,r+108,8,this.uid)||this.needPax,this.needPax=Sr(e,r+116,8,this.gid)||this.needPax,this.needPax=Sr(e,r+124,12,this.size)||this.needPax,this.needPax=Tu(e,r+136,12,this.mtime)||this.needPax,e[r+156]=this[rt].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=Sr(e,r+329,8,this.devmaj)||this.needPax,this.needPax=Sr(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=Tu(e,r+476,12,this.atime)||this.needPax,this.needPax=Tu(e,r+488,12,this.ctime)||this.needPax);let a=8*32;for(let l=r;l<r+148;l++)a+=e[l];for(let l=r+156;l<r+512;l++)a+=e[l];return this.cksum=a,Sr(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 xu.name.get(this[rt])||this[rt]}get typeKey(){return this[rt]}set type(e){xu.code.has(e)?this[rt]=xu.code.get(e):this[rt]=e}},g1=(t,e)=>{let i=t,n="",s,o=Bi.parse(t).root||".";if(Buffer.byteLength(i)<100)s=[i,n,!1];else{n=Bi.dirname(i),i=Bi.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=Bi.join(Bi.basename(n),i),n=Bi.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.*/,""),Ou=(t,e,r)=>y1(wr(t,e,r)),y1=t=>t===null?null:new Date(t*1e3),wr=(t,e,r)=>t[e]&128?wb.parse(t.slice(e,e+r)):_1(t,e,r),b1=t=>isNaN(t)?null:t,_1=(t,e,r)=>b1(parseInt(t.slice(e,e+r).toString("utf8").replace(/\0.*$/,"").trim(),8)),w1={12:8589934591,8:2097151},Sr=(t,e,r,i)=>i===null?!1:i>w1[r]||i<0?(wb.encode(i,t.slice(e,e+r)),!0):(S1(t,e,r,i),!1),S1=(t,e,r,i)=>t.write(E1(i,r),e,r,"ascii"),E1=(t,e)=>v1(Math.floor(t).toString(8),e),v1=(t,e)=>(t.length===e-1?t:new Array(e-t.length-1).join("0")+t+" ")+"\0",Tu=(t,e,r,i)=>i===null?!1:Sr(t,e,r,i.getTime()/1e3),R1=new Array(156).join("\0"),Yr=(t,e,r,i)=>i===null?!1:(t.write(i+R1,e,r,"utf8"),i.length!==Buffer.byteLength(i)||i.length>r);Sb.exports=ku});var bo=$((qM,Eb)=>{"use strict";var x1=ji(),A1=require("path"),Dn=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 x1({path:("PaxHeader/"+A1.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 b?(i.originalMessage=i.message,i.message=k):i=new Error(k),i.shortMessage=x,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=!!l,i.isCanceled=c,i.killed=u&&!l,i};oy.exports=HT});var cy=$((fM,$c)=>{"use strict";var Ys=["stdin","stdout","stderr"],UT=t=>Ys.some(e=>t[e]!==void 0),ly=t=>{if(!t)return;let{stdio:e}=t;if(e===void 0)return Ys.map(i=>t[i]);if(UT(t))throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${Ys.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,Ys.length);return Array.from({length:r},(i,n)=>e[n])};$c.exports=ly;$c.exports.node=t=>{let e=ly(t);return e==="ipc"?"ipc":e===void 0||typeof e=="string"?[e,e,e,"ipc"]:e.includes("ipc")?e:[...e,"ipc"]}});var uy=$((pM,Vs)=>{Vs.exports=["SIGABRT","SIGALRM","SIGHUP","SIGINT","SIGTERM"];process.platform!=="win32"&&Vs.exports.push("SIGVTALRM","SIGXCPU","SIGXFSZ","SIGUSR2","SIGTRAP","SIGSYS","SIGQUIT","SIGIOT");process.platform==="linux"&&Vs.exports.push("SIGIO","SIGPOLL","SIGPWR","SIGSTKFLT","SIGUNUSED")});var my=$((dM,ki)=>{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)?(hy=require("assert"),Oi=uy(),fy=/^win/i.test(ye.platform),xn=require("events"),typeof xn!="function"&&(xn=xn.EventEmitter),ye.__signal_exit_emitter__?Te=ye.__signal_exit_emitter__:(Te=ye.__signal_exit_emitter__=new xn,Te.count=0,Te.emitted={}),Te.infinite||(Te.setMaxListeners(1/0),Te.infinite=!0),ki.exports=function(t,e){if(!Hr(global.process))return function(){};hy.equal(typeof t,"function","a callback must be provided for exit handler"),Ti===!1&&qc();var r="exit";e&&e.alwaysLast&&(r="afterexit");var i=function(){Te.removeListener(r,t),Te.listeners("exit").length===0&&Te.listeners("afterexit").length===0&&Ks()};return Te.on(r,t),i},Ks=function(){!Ti||!Hr(global.process)||(Ti=!1,Oi.forEach(function(e){try{ye.removeListener(e,Zs[e])}catch{}}),ye.emit=Xs,ye.reallyExit=Hc,Te.count-=1)},ki.exports.unload=Ks,Ur=function(e,r,i){Te.emitted[e]||(Te.emitted[e]=!0,Te.emit(e,r,i))},Zs={},Oi.forEach(function(t){Zs[t]=function(){if(Hr(global.process)){var r=ye.listeners(t);r.length===Te.count&&(Ks(),Ur("exit",null,t),Ur("afterexit",null,t),fy&&t==="SIGHUP"&&(t="SIGINT"),ye.kill(ye.pid,t))}}}),ki.exports.signals=function(){return Oi},Ti=!1,qc=function(){Ti||!Hr(global.process)||(Ti=!0,Te.count+=1,Oi=Oi.filter(function(e){try{return ye.on(e,Zs[e]),!0}catch{return!1}}),ye.emit=dy,ye.reallyExit=py)},ki.exports.load=qc,Hc=ye.reallyExit,py=function(e){Hr(global.process)&&(ye.exitCode=e||0,Ur("exit",ye.exitCode,null),Ur("afterexit",ye.exitCode,null),Hc.call(ye,ye.exitCode))},Xs=ye.emit,dy=function(e,r){if(e==="exit"&&Hr(global.process)){r!==void 0&&(ye.exitCode=r);var i=Xs.apply(this,arguments);return Ur("exit",ye.exitCode,null),Ur("afterexit",ye.exitCode,null),i}else return Xs.apply(this,arguments)}):ki.exports=function(){return function(){}};var hy,Oi,fy,xn,Te,Ks,Ur,Zs,Ti,qc,Hc,py,Xs,dy});var yy=$((mM,gy)=>{"use strict";var GT=require("os"),zT=my(),WT=1e3*5,YT=(t,e="SIGTERM",r={})=>{let i=t(e);return VT(t,e,r,i),i},VT=(t,e,r,i)=>{if(!KT(e,r,i))return;let n=XT(r),s=setTimeout(()=>{t("SIGKILL")},n);s.unref&&s.unref()},KT=(t,{forceKillAfterTimeout:e},r)=>ZT(t)&&e!==!1&&r,ZT=t=>t===GT.constants.signals.SIGTERM||typeof t=="string"&&t.toUpperCase()==="SIGTERM",XT=({forceKillAfterTimeout:t=!0})=>{if(t===!0)return WT;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},JT=(t,e)=>{t.kill()&&(e.isCanceled=!0)},QT=(t,e,r)=>{t.kill(e),r(Object.assign(new Error("Timed out"),{timedOut:!0,signal:e}))},ek=(t,{timeout:e,killSignal:r="SIGTERM"},i)=>{if(e===0||e===void 0)return i;let n,s=new Promise((a,l)=>{n=setTimeout(()=>{QT(t,r,l)},e)}),o=i.finally(()=>{clearTimeout(n)});return Promise.race([s,o])},tk=({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})`)},rk=async(t,{cleanup:e,detached:r},i)=>{if(!e||r)return i;let n=zT(()=>{t.kill()});return i.finally(()=>{n()})};gy.exports={spawnedKill:YT,spawnedCancel:JT,setupTimeout:ek,validateTimeout:tk,setExitHandler:rk}});var _y=$((gM,by)=>{"use strict";var Ot=t=>t!==null&&typeof t=="object"&&typeof t.pipe=="function";Ot.writable=t=>Ot(t)&&t.writable!==!1&&typeof t._write=="function"&&typeof t._writableState=="object";Ot.readable=t=>Ot(t)&&t.readable!==!1&&typeof t._read=="function"&&typeof t._readableState=="object";Ot.duplex=t=>Ot.writable(t)&&Ot.readable(t);Ot.transform=t=>Ot.duplex(t)&&typeof t._transform=="function";by.exports=Ot});var Sy=$((yM,wy)=>{"use strict";var{PassThrough:ik}=require("stream");wy.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 ik({objectMode:n});r&&s.setEncoding(r);let o=0,a=[];return s.on("data",l=>{a.push(l),n?o=a.length:o+=l.length}),s.getBufferedValue=()=>e?a:i?Buffer.concat(a,o):a.join(""),s.getBufferedLength=()=>o,s}});var Ey=$((bM,An)=>{"use strict";var{constants:nk}=require("buffer"),sk=require("stream"),{promisify:ok}=require("util"),ak=Sy(),lk=ok(sk.pipeline),Js=class extends Error{constructor(){super("maxBuffer exceeded"),this.name="MaxBufferError"}};async function Uc(t,e){if(!t)throw new Error("Expected a stream");e={maxBuffer:1/0,...e};let{maxBuffer:r}=e,i=ak(e);return await new Promise((n,s)=>{let o=a=>{a&&i.getBufferedLength()<=nk.MAX_LENGTH&&(a.bufferedData=i.getBufferedValue()),s(a)};(async()=>{try{await lk(t,i),n()}catch(a){o(a)}})(),i.on("data",()=>{i.getBufferedLength()>r&&o(new Js)})}),i.getBufferedValue()}An.exports=Uc;An.exports.buffer=(t,e)=>Uc(t,{...e,encoding:"buffer"});An.exports.array=(t,e)=>Uc(t,{...e,array:!0});An.exports.MaxBufferError=Js});var Ry=$((_M,vy)=>{"use strict";var{PassThrough:ck}=require("stream");vy.exports=function(){var t=[],e=new ck({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 Ty=$((wM,Oy)=>{"use strict";var Ay=_y(),xy=Ey(),uk=Ry(),hk=(t,e)=>{e===void 0||t.stdin===void 0||(Ay(e)?e.pipe(t.stdin):t.stdin.end(e))},fk=(t,{all:e})=>{if(!e||!t.stdout&&!t.stderr)return;let r=uk();return t.stdout&&r.add(t.stdout),t.stderr&&r.add(t.stderr),r},Gc=async(t,e)=>{if(t){t.destroy();try{return await e}catch(r){return r.bufferedData}}},zc=(t,{encoding:e,buffer:r,maxBuffer:i})=>{if(!(!t||!r))return e?xy(t,{encoding:e,maxBuffer:i}):xy.buffer(t,{maxBuffer:i})},pk=async({stdout:t,stderr:e,all:r},{encoding:i,buffer:n,maxBuffer:s},o)=>{let a=zc(t,{encoding:i,buffer:n,maxBuffer:s}),l=zc(e,{encoding:i,buffer:n,maxBuffer:s}),c=zc(r,{encoding:i,buffer:n,maxBuffer:s*2});try{return await Promise.all([o,a,l,c])}catch(u){return Promise.all([{error:u,signal:u.signal,timedOut:u.timedOut},Gc(t,a),Gc(e,l),Gc(r,c)])}},dk=({input:t})=>{if(Ay(t))throw new TypeError("The `input` option cannot be a stream in sync mode")};Oy.exports={handleInput:hk,makeAllStream:fk,getSpawnedResult:pk,validateInputSync:dk}});var Cy=$((SM,ky)=>{"use strict";var mk=(async()=>{})().constructor.prototype,gk=["then","catch","finally"].map(t=>[t,Reflect.getOwnPropertyDescriptor(mk,t)]),yk=(t,e)=>{for(let[r,i]of gk){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},bk=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)})});ky.exports={mergePromise:yk,getSpawnedPromise:bk}});var Iy=$((EM,Py)=>{"use strict";var Ly=(t,e=[])=>Array.isArray(e)?[t,...e]:[t],_k=/^[\w.-]+$/,wk=/"/g,Sk=t=>typeof t!="string"||_k.test(t)?t:`"${t.replace(wk,'\\"')}"`,Ek=(t,e)=>Ly(t,e).join(" "),vk=(t,e)=>Ly(t,e).map(r=>Sk(r)).join(" "),Rk=/ +/g,xk=t=>{let e=[];for(let r of t.trim().split(Rk)){let i=e[e.length-1];i&&i.endsWith("\\")?e[e.length-1]=`${i.slice(0,-1)} ${r}`:e.push(r)}return e};Py.exports={joinCommand:Ek,getEscapedCommand:vk,parseCommand:xk}});var Li=$((vM,Ci)=>{"use strict";var Ak=require("path"),Wc=require("child_process"),Ok=Gg(),Tk=Wg(),kk=Kg(),Ck=Qg(),Qs=ay(),Dy=cy(),{spawnedKill:Lk,spawnedCancel:Pk,setupTimeout:Ik,validateTimeout:Nk,setExitHandler:Dk}=yy(),{handleInput:Mk,getSpawnedResult:Fk,makeAllStream:Bk,validateInputSync:jk}=Ty(),{mergePromise:Ny,getSpawnedPromise:$k}=Cy(),{joinCommand:My,parseCommand:Fy,getEscapedCommand:By}=Iy(),qk=1e3*1e3*100,Hk=({env:t,extendEnv:e,preferLocal:r,localDir:i,execPath:n})=>{let s=e?{...process.env,...t}:t;return r?kk.env({env:s,cwd:i,execPath:n}):s},jy=(t,e,r={})=>{let i=Ok._parse(t,e,r);return t=i.command,e=i.args,r=i.options,r={maxBuffer:qk,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=Hk(r),r.stdio=Dy(r),process.platform==="win32"&&Ak.basename(t,".exe")==="cmd"&&e.unshift("/q"),{file:t,args:e,options:r,parsed:i}},On=(t,e,r)=>typeof e!="string"&&!Buffer.isBuffer(e)?r===void 0?void 0:"":t.stripFinalNewline?Tk(e):e,eo=(t,e,r)=>{let i=jy(t,e,r),n=My(t,e),s=By(t,e);Nk(i.options);let o;try{o=Wc.spawn(i.file,i.args,i.options)}catch(p){let g=new Wc.ChildProcess,y=Promise.reject(Qs({error:p,stdout:"",stderr:"",all:"",command:n,escapedCommand:s,parsed:i,timedOut:!1,isCanceled:!1,killed:!1}));return Ny(g,y)}let a=$k(o),l=Ik(o,i.options,a),c=Dk(o,i.options,l),u={isCanceled:!1};o.kill=Lk.bind(null,o.kill.bind(o)),o.cancel=Pk.bind(null,o,u);let h=Ck(async()=>{let[{error:p,exitCode:g,signal:y,timedOut:b},x,k,C]=await Fk(o,i.options,c),T=On(i.options,x),O=On(i.options,k),I=On(i.options,C);if(p||g!==0||y!==null){let w=Qs({error:p,exitCode:g,signal:y,stdout:T,stderr:O,all:I,command:n,escapedCommand:s,parsed:i,timedOut:b,isCanceled:u.isCanceled,killed:o.killed});if(!i.options.reject)return w;throw w}return{command:n,escapedCommand:s,exitCode:0,stdout:T,stderr:O,all:I,failed:!1,timedOut:!1,isCanceled:!1,killed:!1}});return Mk(o,i.options.input),o.all=Bk(o,i.options),Ny(o,h)};Ci.exports=eo;Ci.exports.sync=(t,e,r)=>{let i=jy(t,e,r),n=My(t,e),s=By(t,e);jk(i.options);let o;try{o=Wc.spawnSync(i.file,i.args,i.options)}catch(c){throw Qs({error:c,stdout:"",stderr:"",all:"",command:n,escapedCommand:s,parsed:i,timedOut:!1,isCanceled:!1,killed:!1})}let a=On(i.options,o.stdout,o.error),l=On(i.options,o.stderr,o.error);if(o.error||o.status!==0||o.signal!==null){let c=Qs({stdout:a,stderr:l,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 c;throw c}return{command:n,escapedCommand:s,exitCode:0,stdout:a,stderr:l,failed:!1,timedOut:!1,isCanceled:!1,killed:!1}};Ci.exports.command=(t,e)=>{let[r,...i]=Fy(t);return eo(r,i,e)};Ci.exports.commandSync=(t,e)=>{let[r,...i]=Fy(t);return eo.sync(r,i,e)};Ci.exports.node=(t,e,r={})=>{e&&!Array.isArray(e)&&typeof e=="object"&&(r=e,e=[]);let i=Dy.node(r),n=process.execArgv.filter(a=>!a.startsWith("--inspect")),{nodePath:s=process.execPath,nodeOptions:o=n}=r;return eo(s,[...o,t,...Array.isArray(e)?e:[]],{...r,stdin:void 0,stdout:void 0,stderr:void 0,stdio:i,shell:!1})}});var Pi=$((TM,Gy)=>{"use strict";var Uy=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"]]);Gy.exports=t=>t?Object.keys(t).map(e=>[Uy.has(e)?Uy.get(e):e,t[e]]).reduce((e,r)=>(e[r[0]]=r[1],e),Object.create(null)):{}});var oo=$((kM,Qy)=>{"use strict";var zy=typeof process=="object"&&process?process:{stdout:null,stderr:null},Yk=require("events"),Wy=require("stream"),Yy=require("string_decoder").StringDecoder,zt=Symbol("EOF"),Wt=Symbol("maybeEmitEnd"),yr=Symbol("emittedEnd"),to=Symbol("emittingEnd"),Tn=Symbol("emittedError"),ro=Symbol("closed"),Vy=Symbol("read"),io=Symbol("flush"),Ky=Symbol("flushChunk"),Ye=Symbol("encoding"),Yt=Symbol("decoder"),no=Symbol("flowing"),kn=Symbol("paused"),Ii=Symbol("resume"),Se=Symbol("buffer"),Tt=Symbol("pipes"),ke=Symbol("bufferLength"),Kc=Symbol("bufferPush"),Zc=Symbol("bufferShift"),De=Symbol("objectMode"),Me=Symbol("destroyed"),Xc=Symbol("emitData"),Zy=Symbol("emitEnd"),Jc=Symbol("emitEnd2"),Vt=Symbol("async"),Cn=t=>Promise.resolve().then(t),Xy=global._MP_NO_ITERATOR_SYMBOLS_!=="1",Vk=Xy&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),Kk=Xy&&Symbol.iterator||Symbol("iterator not implemented"),Zk=t=>t==="end"||t==="finish"||t==="prefinish",Xk=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,Jk=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),so=class{constructor(e,r,i){this.src=e,this.dest=r,this.opts=i,this.ondrain=()=>e[Ii](),r.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},Qc=class extends so{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)}};Qy.exports=class Jy extends Wy{constructor(e){super(),this[no]=!1,this[kn]=!1,this[Tt]=[],this[Se]=[],this[De]=e&&e.objectMode||!1,this[De]?this[Ye]=null:this[Ye]=e&&e.encoding||null,this[Ye]==="buffer"&&(this[Ye]=null),this[Vt]=e&&!!e.async||!1,this[Yt]=this[Ye]?new Yy(this[Ye]):null,this[zt]=!1,this[yr]=!1,this[to]=!1,this[ro]=!1,this[Tn]=null,this.writable=!0,this.readable=!0,this[ke]=0,this[Me]=!1,e&&e.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[Se]}),e&&e.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[Tt]})}get bufferLength(){return this[ke]}get encoding(){return this[Ye]}set encoding(e){if(this[De])throw new Error("cannot set encoding in objectMode");if(this[Ye]&&e!==this[Ye]&&(this[Yt]&&this[Yt].lastNeed||this[ke]))throw new Error("cannot change encoding");this[Ye]!==e&&(this[Yt]=e?new Yy(e):null,this[Se].length&&(this[Se]=this[Se].map(r=>this[Yt].write(r)))),this[Ye]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[De]}set objectMode(e){this[De]=this[De]||!!e}get async(){return this[Vt]}set async(e){this[Vt]=this[Vt]||!!e}write(e,r,i){if(this[zt])throw new Error("write after end");if(this[Me])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[Vt]?Cn:s=>s();return!this[De]&&!Buffer.isBuffer(e)&&(Jk(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):Xk(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),this[De]?(this.flowing&&this[ke]!==0&&this[io](!0),this.flowing?this.emit("data",e):this[Kc](e),this[ke]!==0&&this.emit("readable"),i&&n(i),this.flowing):e.length?(typeof e=="string"&&!(r===this[Ye]&&!this[Yt].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[Ye]&&(e=this[Yt].write(e)),this.flowing&&this[ke]!==0&&this[io](!0),this.flowing?this.emit("data",e):this[Kc](e),this[ke]!==0&&this.emit("readable"),i&&n(i),this.flowing):(this[ke]!==0&&this.emit("readable"),i&&n(i),this.flowing)}read(e){if(this[Me])return null;if(this[ke]===0||e===0||e>this[ke])return this[Wt](),null;this[De]&&(e=null),this[Se].length>1&&!this[De]&&(this.encoding?this[Se]=[this[Se].join("")]:this[Se]=[Buffer.concat(this[Se],this[ke])]);let r=this[Vy](e||null,this[Se][0]);return this[Wt](),r}[Vy](e,r){return e===r.length||e===null?this[Zc]():(this[Se][0]=r.slice(e),r=r.slice(0,e),this[ke]-=e),this.emit("data",r),!this[Se].length&&!this[zt]&&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[zt]=!0,this.writable=!1,(this.flowing||!this[kn])&&this[Wt](),this}[Ii](){this[Me]||(this[kn]=!1,this[no]=!0,this.emit("resume"),this[Se].length?this[io]():this[zt]?this[Wt]():this.emit("drain"))}resume(){return this[Ii]()}pause(){this[no]=!1,this[kn]=!0}get destroyed(){return this[Me]}get flowing(){return this[no]}get paused(){return this[kn]}[Kc](e){this[De]?this[ke]+=1:this[ke]+=e.length,this[Se].push(e)}[Zc](){return this[Se].length&&(this[De]?this[ke]-=1:this[ke]-=this[Se][0].length),this[Se].shift()}[io](e){do;while(this[Ky](this[Zc]()));!e&&!this[Se].length&&!this[zt]&&this.emit("drain")}[Ky](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Me])return;let i=this[yr];return r=r||{},e===zy.stdout||e===zy.stderr?r.end=!1:r.end=r.end!==!1,r.proxyErrors=!!r.proxyErrors,i?r.end&&e.end():(this[Tt].push(r.proxyErrors?new Qc(this,e,r):new so(this,e,r)),this[Vt]?Cn(()=>this[Ii]()):this[Ii]()),e}unpipe(e){let r=this[Tt].find(i=>i.dest===e);r&&(this[Tt].splice(this[Tt].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[Tt].length&&!this.flowing?this[Ii]():e==="readable"&&this[ke]!==0?super.emit("readable"):Zk(e)&&this[yr]?(super.emit(e),this.removeAllListeners(e)):e==="error"&&this[Tn]&&(this[Vt]?Cn(()=>r.call(this,this[Tn])):r.call(this,this[Tn])),i}get emittedEnd(){return this[yr]}[Wt](){!this[to]&&!this[yr]&&!this[Me]&&this[Se].length===0&&this[zt]&&(this[to]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[ro]&&this.emit("close"),this[to]=!1)}emit(e,r,...i){if(e!=="error"&&e!=="close"&&e!==Me&&this[Me])return;if(e==="data")return r?this[Vt]?Cn(()=>this[Xc](r)):this[Xc](r):!1;if(e==="end")return this[Zy]();if(e==="close"){if(this[ro]=!0,!this[yr]&&!this[Me])return;let s=super.emit("close");return this.removeAllListeners("close"),s}else if(e==="error"){this[Tn]=r;let s=super.emit("error",r);return this[Wt](),s}else if(e==="resume"){let s=super.emit("resume");return this[Wt](),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[Wt](),n}[Xc](e){for(let i of this[Tt])i.dest.write(e)===!1&&this.pause();let r=super.emit("data",e);return this[Wt](),r}[Zy](){this[yr]||(this[yr]=!0,this.readable=!1,this[Vt]?Cn(()=>this[Jc]()):this[Jc]())}[Jc](){if(this[Yt]){let r=this[Yt].end();if(r){for(let i of this[Tt])i.dest.write(r);super.emit("data",r)}}for(let r of this[Tt])r.end();let e=super.emit("end");return this.removeAllListeners("end"),e}collect(){let e=[];this[De]||(e.dataLength=0);let r=this.promise();return this.on("data",i=>{e.push(i),this[De]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[De]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[De]?Promise.reject(new Error("cannot concat in objectMode")):this[Ye]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Me,()=>r(new Error("stream destroyed"))),this.on("error",i=>r(i)),this.on("end",()=>e())})}[Vk](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[zt])return Promise.resolve({done:!0});let i=null,n=null,s=c=>{this.removeListener("data",o),this.removeListener("end",a),n(c)},o=c=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:c,done:!!this[zt]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},l=()=>s(new Error("stream destroyed"));return new Promise((c,u)=>{n=u,i=c,this.once(Me,l),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[Kk](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Me]?(e?this.emit("error",e):this.emit(Me),this):(this[Me]=!0,this[Se].length=0,this[ke]=0,typeof this.close=="function"&&!this[ro]&&this.close(),e?this.emit("error",e):this.emit(Me),this)}static isStream(e){return!!e&&(e instanceof Jy||e instanceof Wy||e instanceof Yk&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var tb=$((CM,eb)=>{var Qk=require("zlib").constants||{ZLIB_VERNUM:4736};eb.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},Qk))});var su=$((LM,ub)=>{"use strict";var rb=typeof process=="object"&&process?process:{stdout:null,stderr:null},e1=require("events"),ib=require("stream"),nb=require("string_decoder").StringDecoder,Kt=Symbol("EOF"),Zt=Symbol("maybeEmitEnd"),br=Symbol("emittedEnd"),ao=Symbol("emittingEnd"),Ln=Symbol("emittedError"),lo=Symbol("closed"),sb=Symbol("read"),co=Symbol("flush"),ob=Symbol("flushChunk"),Ve=Symbol("encoding"),Xt=Symbol("decoder"),uo=Symbol("flowing"),Pn=Symbol("paused"),Ni=Symbol("resume"),Ce=Symbol("bufferLength"),eu=Symbol("bufferPush"),tu=Symbol("bufferShift"),Fe=Symbol("objectMode"),Be=Symbol("destroyed"),ru=Symbol("emitData"),ab=Symbol("emitEnd"),iu=Symbol("emitEnd2"),Jt=Symbol("async"),In=t=>Promise.resolve().then(t),lb=global._MP_NO_ITERATOR_SYMBOLS_!=="1",t1=lb&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),r1=lb&&Symbol.iterator||Symbol("iterator not implemented"),i1=t=>t==="end"||t==="finish"||t==="prefinish",n1=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,s1=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),ho=class{constructor(e,r,i){this.src=e,this.dest=r,this.opts=i,this.ondrain=()=>e[Ni](),r.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},nu=class extends ho{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)}};ub.exports=class cb extends ib{constructor(e){super(),this[uo]=!1,this[Pn]=!1,this.pipes=[],this.buffer=[],this[Fe]=e&&e.objectMode||!1,this[Fe]?this[Ve]=null:this[Ve]=e&&e.encoding||null,this[Ve]==="buffer"&&(this[Ve]=null),this[Jt]=e&&!!e.async||!1,this[Xt]=this[Ve]?new nb(this[Ve]):null,this[Kt]=!1,this[br]=!1,this[ao]=!1,this[lo]=!1,this[Ln]=null,this.writable=!0,this.readable=!0,this[Ce]=0,this[Be]=!1}get bufferLength(){return this[Ce]}get encoding(){return this[Ve]}set encoding(e){if(this[Fe])throw new Error("cannot set encoding in objectMode");if(this[Ve]&&e!==this[Ve]&&(this[Xt]&&this[Xt].lastNeed||this[Ce]))throw new Error("cannot change encoding");this[Ve]!==e&&(this[Xt]=e?new nb(e):null,this.buffer.length&&(this.buffer=this.buffer.map(r=>this[Xt].write(r)))),this[Ve]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[Fe]}set objectMode(e){this[Fe]=this[Fe]||!!e}get async(){return this[Jt]}set async(e){this[Jt]=this[Jt]||!!e}write(e,r,i){if(this[Kt])throw new Error("write after end");if(this[Be])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[Jt]?In:s=>s();return!this[Fe]&&!Buffer.isBuffer(e)&&(s1(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):n1(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),this[Fe]?(this.flowing&&this[Ce]!==0&&this[co](!0),this.flowing?this.emit("data",e):this[eu](e),this[Ce]!==0&&this.emit("readable"),i&&n(i),this.flowing):e.length?(typeof e=="string"&&!(r===this[Ve]&&!this[Xt].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[Ve]&&(e=this[Xt].write(e)),this.flowing&&this[Ce]!==0&&this[co](!0),this.flowing?this.emit("data",e):this[eu](e),this[Ce]!==0&&this.emit("readable"),i&&n(i),this.flowing):(this[Ce]!==0&&this.emit("readable"),i&&n(i),this.flowing)}read(e){if(this[Be])return null;if(this[Ce]===0||e===0||e>this[Ce])return this[Zt](),null;this[Fe]&&(e=null),this.buffer.length>1&&!this[Fe]&&(this.encoding?this.buffer=[this.buffer.join("")]:this.buffer=[Buffer.concat(this.buffer,this[Ce])]);let r=this[sb](e||null,this.buffer[0]);return this[Zt](),r}[sb](e,r){return e===r.length||e===null?this[tu]():(this.buffer[0]=r.slice(e),r=r.slice(0,e),this[Ce]-=e),this.emit("data",r),!this.buffer.length&&!this[Kt]&&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[Kt]=!0,this.writable=!1,(this.flowing||!this[Pn])&&this[Zt](),this}[Ni](){this[Be]||(this[Pn]=!1,this[uo]=!0,this.emit("resume"),this.buffer.length?this[co]():this[Kt]?this[Zt]():this.emit("drain"))}resume(){return this[Ni]()}pause(){this[uo]=!1,this[Pn]=!0}get destroyed(){return this[Be]}get flowing(){return this[uo]}get paused(){return this[Pn]}[eu](e){this[Fe]?this[Ce]+=1:this[Ce]+=e.length,this.buffer.push(e)}[tu](){return this.buffer.length&&(this[Fe]?this[Ce]-=1:this[Ce]-=this.buffer[0].length),this.buffer.shift()}[co](e){do;while(this[ob](this[tu]()));!e&&!this.buffer.length&&!this[Kt]&&this.emit("drain")}[ob](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Be])return;let i=this[br];return r=r||{},e===rb.stdout||e===rb.stderr?r.end=!1:r.end=r.end!==!1,r.proxyErrors=!!r.proxyErrors,i?r.end&&e.end():(this.pipes.push(r.proxyErrors?new nu(this,e,r):new ho(this,e,r)),this[Jt]?In(()=>this[Ni]()):this[Ni]()),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[Ni]():e==="readable"&&this[Ce]!==0?super.emit("readable"):i1(e)&&this[br]?(super.emit(e),this.removeAllListeners(e)):e==="error"&&this[Ln]&&(this[Jt]?In(()=>r.call(this,this[Ln])):r.call(this,this[Ln])),i}get emittedEnd(){return this[br]}[Zt](){!this[ao]&&!this[br]&&!this[Be]&&this.buffer.length===0&&this[Kt]&&(this[ao]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[lo]&&this.emit("close"),this[ao]=!1)}emit(e,r,...i){if(e!=="error"&&e!=="close"&&e!==Be&&this[Be])return;if(e==="data")return r?this[Jt]?In(()=>this[ru](r)):this[ru](r):!1;if(e==="end")return this[ab]();if(e==="close"){if(this[lo]=!0,!this[br]&&!this[Be])return;let s=super.emit("close");return this.removeAllListeners("close"),s}else if(e==="error"){this[Ln]=r;let s=super.emit("error",r);return this[Zt](),s}else if(e==="resume"){let s=super.emit("resume");return this[Zt](),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[Zt](),n}[ru](e){for(let i of this.pipes)i.dest.write(e)===!1&&this.pause();let r=super.emit("data",e);return this[Zt](),r}[ab](){this[br]||(this[br]=!0,this.readable=!1,this[Jt]?In(()=>this[iu]()):this[iu]())}[iu](){if(this[Xt]){let r=this[Xt].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[Fe]||(e.dataLength=0);let r=this.promise();return this.on("data",i=>{e.push(i),this[Fe]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[Fe]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[Fe]?Promise.reject(new Error("cannot concat in objectMode")):this[Ve]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Be,()=>r(new Error("stream destroyed"))),this.on("error",i=>r(i)),this.on("end",()=>e())})}[t1](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[Kt])return Promise.resolve({done:!0});let i=null,n=null,s=c=>{this.removeListener("data",o),this.removeListener("end",a),n(c)},o=c=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:c,done:!!this[Kt]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},l=()=>s(new Error("stream destroyed"));return new Promise((c,u)=>{n=u,i=c,this.once(Be,l),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[r1](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Be]?(e?this.emit("error",e):this.emit(Be),this):(this[Be]=!0,this.buffer.length=0,this[Ce]=0,typeof this.close=="function"&&!this[lo]&&this.close(),e?this.emit("error",e):this.emit(Be),this)}static isStream(e){return!!e&&(e instanceof cb||e instanceof ib||e instanceof e1&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var Su=$(tt=>{"use strict";var uu=require("assert"),_r=require("buffer").Buffer,pb=require("zlib"),Gr=tt.constants=tb(),o1=su(),hb=_r.concat,zr=Symbol("_superWrite"),Mi=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"}},a1=Symbol("opts"),Nn=Symbol("flushFlag"),fb=Symbol("finishFlushFlag"),wu=Symbol("fullFlushFlag"),de=Symbol("handle"),fo=Symbol("onError"),Di=Symbol("sawError"),ou=Symbol("level"),au=Symbol("strategy"),lu=Symbol("ended"),PM=Symbol("_defaultFullFlush"),po=class extends o1{constructor(e,r){if(!e||typeof e!="object")throw new TypeError("invalid options for ZlibBase constructor");super(e),this[Di]=!1,this[lu]=!1,this[a1]=e,this[Nn]=e.flush,this[fb]=e.finishFlush;try{this[de]=new pb[r](e)}catch(i){throw new Mi(i)}this[fo]=i=>{this[Di]||(this[Di]=!0,this.close(),this.emit("error",i))},this[de].on("error",i=>this[fo](new Mi(i))),this.once("end",()=>this.close)}close(){this[de]&&(this[de].close(),this[de]=null,this.emit("close"))}reset(){if(!this[Di])return uu(this[de],"zlib binding closed"),this[de].reset()}flush(e){this.ended||(typeof e!="number"&&(e=this[wu]),this.write(Object.assign(_r.alloc(0),{[Nn]:e})))}end(e,r,i){return e&&this.write(e,r),this.flush(this[fb]),this[lu]=!0,super.end(null,null,i)}get ended(){return this[lu]}write(e,r,i){if(typeof r=="function"&&(i=r,r="utf8"),typeof e=="string"&&(e=_r.from(e,r)),this[Di])return;uu(this[de],"zlib binding closed");let n=this[de]._handle,s=n.close;n.close=()=>{};let o=this[de].close;this[de].close=()=>{},_r.concat=c=>c;let a;try{let c=typeof e[Nn]=="number"?e[Nn]:this[Nn];a=this[de]._processChunk(e,c),_r.concat=hb}catch(c){_r.concat=hb,this[fo](new Mi(c))}finally{this[de]&&(this[de]._handle=n,n.close=s,this[de].close=o,this[de].removeAllListeners("error"))}this[de]&&this[de].on("error",c=>this[fo](new Mi(c)));let l;if(a)if(Array.isArray(a)&&a.length>0){l=this[zr](_r.from(a[0]));for(let c=1;c<a.length;c++)l=this[zr](a[c])}else l=this[zr](_r.from(a));return i&&i(),l}[zr](e){return super.write(e)}},Qt=class extends po{constructor(e,r){e=e||{},e.flush=e.flush||Gr.Z_NO_FLUSH,e.finishFlush=e.finishFlush||Gr.Z_FINISH,super(e,r),this[wu]=Gr.Z_FULL_FLUSH,this[ou]=e.level,this[au]=e.strategy}params(e,r){if(!this[Di]){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[ou]!==e||this[au]!==r){this.flush(Gr.Z_SYNC_FLUSH),uu(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[ou]=e,this[au]=r)}}}},hu=class extends Qt{constructor(e){super(e,"Deflate")}},fu=class extends Qt{constructor(e){super(e,"Inflate")}},cu=Symbol("_portable"),pu=class extends Qt{constructor(e){super(e,"Gzip"),this[cu]=e&&!!e.portable}[zr](e){return this[cu]?(this[cu]=!1,e[9]=255,super[zr](e)):super[zr](e)}},du=class extends Qt{constructor(e){super(e,"Gunzip")}},mu=class extends Qt{constructor(e){super(e,"DeflateRaw")}},gu=class extends Qt{constructor(e){super(e,"InflateRaw")}},yu=class extends Qt{constructor(e){super(e,"Unzip")}},mo=class extends po{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[wu]=Gr.BROTLI_OPERATION_FLUSH}},bu=class extends mo{constructor(e){super(e,"BrotliCompress")}},_u=class extends mo{constructor(e){super(e,"BrotliDecompress")}};tt.Deflate=hu;tt.Inflate=fu;tt.Gzip=pu;tt.Gunzip=du;tt.DeflateRaw=mu;tt.InflateRaw=gu;tt.Unzip=yu;typeof pb.BrotliCompress=="function"?(tt.BrotliCompress=bu,tt.BrotliDecompress=_u):tt.BrotliCompress=tt.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}});var Fi=$((DM,db)=>{var l1=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform;db.exports=l1!=="win32"?t=>t:t=>t&&t.replace(/\\/g,"/")});var go=$((FM,mb)=>{"use strict";var c1=oo(),Eu=Fi(),vu=Symbol("slurp");mb.exports=class extends c1{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=Eu(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=Eu(e.linkpath),this.uname=e.uname,this.gname=e.gname,r&&this[vu](r),i&&this[vu](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))}[vu](e,r){for(let i in e)e[i]!==null&&e[i]!==void 0&&!(r&&i==="path")&&(this[i]=i==="path"||i==="linkpath"?Eu(e[i]):e[i])}}});var Ru=$(yo=>{"use strict";yo.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"]]);yo.code=new Map(Array.from(yo.name).map(t=>[t[1],t[0]]))});var _b=$((jM,bb)=>{"use strict";var u1=(t,e)=>{if(Number.isSafeInteger(t))t<0?f1(t,e):h1(t,e);else throw Error("cannot encode number outside of javascript safe integer range");return e},h1=(t,e)=>{e[0]=128;for(var r=e.length;r>1;r--)e[r-1]=t&255,t=Math.floor(t/256)},f1=(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]=gb(n):n===0?e[i-1]=0:(r=!0,e[i-1]=yb(n))}},p1=t=>{let e=t[0],r=e===128?m1(t.slice(1,t.length)):e===255?d1(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},d1=t=>{for(var e=t.length,r=0,i=!1,n=e-1;n>-1;n--){var s=t[n],o;i?o=gb(s):s===0?o=s:(i=!0,o=yb(s)),o!==0&&(r-=o*Math.pow(256,e-n-1))}return r},m1=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},gb=t=>(255^t)&255,yb=t=>(255^t)+1&255;bb.exports={encode:u1,parse:p1}});var ji=$(($M,Sb)=>{"use strict";var xu=Ru(),Bi=require("path").posix,wb=_b(),Au=Symbol("slurp"),rt=Symbol("type"),ku=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[rt]="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=wr(e,r+100,8),this.uid=wr(e,r+108,8),this.gid=wr(e,r+116,8),this.size=wr(e,r+124,12),this.mtime=Ou(e,r+136,12),this.cksum=wr(e,r+148,12),this[Au](i),this[Au](n,!0),this[rt]=Wr(e,r+156,1),this[rt]===""&&(this[rt]="0"),this[rt]==="0"&&this.path.slice(-1)==="/"&&(this[rt]="5"),this[rt]==="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=wr(e,r+329,8),this.devmin=wr(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=Ou(e,r+476,12),this.ctime=Ou(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)}[Au](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=g1(this.path||"",i),s=n[0],o=n[1];this.needPax=n[2],this.needPax=Yr(e,r,100,s)||this.needPax,this.needPax=Sr(e,r+100,8,this.mode)||this.needPax,this.needPax=Sr(e,r+108,8,this.uid)||this.needPax,this.needPax=Sr(e,r+116,8,this.gid)||this.needPax,this.needPax=Sr(e,r+124,12,this.size)||this.needPax,this.needPax=Tu(e,r+136,12,this.mtime)||this.needPax,e[r+156]=this[rt].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=Sr(e,r+329,8,this.devmaj)||this.needPax,this.needPax=Sr(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=Tu(e,r+476,12,this.atime)||this.needPax,this.needPax=Tu(e,r+488,12,this.ctime)||this.needPax);let a=8*32;for(let l=r;l<r+148;l++)a+=e[l];for(let l=r+156;l<r+512;l++)a+=e[l];return this.cksum=a,Sr(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 xu.name.get(this[rt])||this[rt]}get typeKey(){return this[rt]}set type(e){xu.code.has(e)?this[rt]=xu.code.get(e):this[rt]=e}},g1=(t,e)=>{let i=t,n="",s,o=Bi.parse(t).root||".";if(Buffer.byteLength(i)<100)s=[i,n,!1];else{n=Bi.dirname(i),i=Bi.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=Bi.join(Bi.basename(n),i),n=Bi.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.*/,""),Ou=(t,e,r)=>y1(wr(t,e,r)),y1=t=>t===null?null:new Date(t*1e3),wr=(t,e,r)=>t[e]&128?wb.parse(t.slice(e,e+r)):_1(t,e,r),b1=t=>isNaN(t)?null:t,_1=(t,e,r)=>b1(parseInt(t.slice(e,e+r).toString("utf8").replace(/\0.*$/,"").trim(),8)),w1={12:8589934591,8:2097151},Sr=(t,e,r,i)=>i===null?!1:i>w1[r]||i<0?(wb.encode(i,t.slice(e,e+r)),!0):(S1(t,e,r,i),!1),S1=(t,e,r,i)=>t.write(E1(i,r),e,r,"ascii"),E1=(t,e)=>v1(Math.floor(t).toString(8),e),v1=(t,e)=>(t.length===e-1?t:new Array(e-t.length-1).join("0")+t+" ")+"\0",Tu=(t,e,r,i)=>i===null?!1:Sr(t,e,r,i.getTime()/1e3),R1=new Array(156).join("\0"),Yr=(t,e,r,i)=>i===null?!1:(t.write(i+R1,e,r,"utf8"),i.length!==Buffer.byteLength(i)||i.length>r);Sb.exports=ku});var bo=$((qM,Eb)=>{"use strict";var x1=ji(),A1=require("path"),Dn=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 x1({path:("PaxHeader/"+A1.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}};Dn.parse=(t,e,r)=>new Dn(O1(T1(t),e),r);var O1=(t,e)=>e?Object.keys(t).reduce((r,i)=>(r[i]=t[i],r),e):t,T1=t=>t.replace(/\n$/,"").split(`
|
9
|
-
`).reduce(k1,Object.create(null)),k1=(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};Eb.exports=Dn});var $i=$((HM,vb)=>{vb.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 _o=$((UM,Rb)=>{"use strict";Rb.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 Lu=$((zM,xb)=>{"use strict";var wo=["|","<",">","?",":"],Cu=wo.map(t=>String.fromCharCode(61440+t.charCodeAt(0))),C1=new Map(wo.map((t,e)=>[t,Cu[e]])),L1=new Map(Cu.map((t,e)=>[t,wo[e]]));xb.exports={encode:t=>wo.reduce((e,r)=>e.split(r).join(C1.get(r)),t),decode:t=>Cu.reduce((e,r)=>e.split(r).join(L1.get(r)),t)}});var Pu=$((WM,Ob)=>{var{isAbsolute:P1,parse:Ab}=require("path").win32;Ob.exports=t=>{let e="",r=Ab(t);for(;P1(t)||r.root;){let i=t.charAt(0)==="/"&&t.slice(0,4)!=="//?/"?"/":r.root;t=t.slice(i.length),e+=i,r=Ab(t)}return[e,t]}});var kb=$((YM,Tb)=>{"use strict";Tb.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 Hu=$((ZM,Ub)=>{"use strict";var Mb=oo(),Fb=bo(),Bb=ji(),Ct=require("fs"),Cb=require("path"),kt=Fi(),I1=$i(),jb=(t,e)=>e?(t=kt(t).replace(/^\.(\/|$)/,""),I1(e)+"/"+t):kt(t),N1=16*1024*1024,Lb=Symbol("process"),Pb=Symbol("file"),Ib=Symbol("directory"),Nu=Symbol("symlink"),Nb=Symbol("hardlink"),Mn=Symbol("header"),So=Symbol("read"),Du=Symbol("lstat"),Eo=Symbol("onlstat"),Mu=Symbol("onread"),Fu=Symbol("onreadlink"),Bu=Symbol("openfile"),ju=Symbol("onopenfile"),Er=Symbol("close"),vo=Symbol("mode"),$u=Symbol("awaitDrain"),Iu=Symbol("ondrain"),Lt=Symbol("prefix"),Db=Symbol("hadError"),$b=_o(),D1=Lu(),qb=Pu(),Hb=kb(),Ro=$b(class extends Mb{constructor(e,r){if(r=r||{},super(r),typeof e!="string")throw new TypeError("path is required");this.path=kt(e),this.portable=!!r.portable,this.myuid=process.getuid&&process.getuid()||0,this.myuser=process.env.USER||"",this.maxReadSize=r.maxReadSize||N1,this.linkCache=r.linkCache||new Map,this.statCache=r.statCache||new Map,this.preservePaths=!!r.preservePaths,this.cwd=kt(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?kt(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]=qb(this.path);n&&(this.path=s,i=n)}this.win32=!!r.win32||process.platform==="win32",this.win32&&(this.path=D1.decode(this.path.replace(/\\/g,"/")),e=e.replace(/\\/g,"/")),this.absolute=kt(r.absolute||Cb.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[Du]()}emit(e,...r){return e==="error"&&(this[Db]=!0),super.emit(e,...r)}[Du](){Ct.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=F1(e),this.emit("stat",e),this[Lb]()}[Lb](){switch(this.type){case"File":return this[Pb]();case"Directory":return this[Ib]();case"SymbolicLink":return this[Nu]();default:return this.end()}}[vo](e){return Hb(e,this.type==="Directory",this.portable)}[Lt](e){return jb(e,this.prefix)}[Mn](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new Bb({path:this[Lt](this.path),linkpath:this.type==="Link"?this[Lt](this.linkpath):this.linkpath,mode:this[vo](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 Fb({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[Lt](this.path),linkpath:this.type==="Link"?this[Lt](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)}[Ib](){this.path.slice(-1)!=="/"&&(this.path+="/"),this.stat.size=0,this[Mn](),this.end()}[Nu](){Ct.readlink(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[Fu](r)})}[Fu](e){this.linkpath=kt(e),this[Mn](),this.end()}[Nb](e){this.type="Link",this.linkpath=kt(Cb.relative(this.cwd,e)),this.stat.size=0,this[Mn](),this.end()}[Pb](){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[Nb](r)}this.linkCache.set(e,this.absolute)}if(this[Mn](),this.stat.size===0)return this.end();this[Bu]()}[Bu](){Ct.open(this.absolute,"r",(e,r)=>{if(e)return this.emit("error",e);this[ju](r)})}[ju](e){if(this.fd=e,this[Db])return this[Er]();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[So]()}[So](){let{fd:e,buf:r,offset:i,length:n,pos:s}=this;Ct.read(e,r,i,n,s,(o,a)=>{if(o)return this[Er](()=>this.emit("error",o));this[Mu](a)})}[Er](e){Ct.close(this.fd,e)}[Mu](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[Er](()=>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[Er](()=>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[Iu]():this[$u](()=>this[Iu]())}[$u](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)}[Iu](){if(!this.remain)return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),this[Er](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[So]()}}),qu=class extends Ro{[Du](){this[Eo](Ct.lstatSync(this.absolute))}[Nu](){this[Fu](Ct.readlinkSync(this.absolute))}[Bu](){this[ju](Ct.openSync(this.absolute,"r"))}[So](){let e=!0;try{let{fd:r,buf:i,offset:n,length:s,pos:o}=this,a=Ct.readSync(r,i,n,s,o);this[Mu](a),e=!1}finally{if(e)try{this[Er](()=>{})}catch{}}}[$u](e){e()}[Er](e){Ct.closeSync(this.fd),e()}},M1=$b(class extends Mb{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=kt(e.path),this.mode=this[vo](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=kt(e.linkpath),typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(!this.preservePaths){let[n,s]=qb(this.path);n&&(this.path=s,i=n)}this.remain=e.size,this.blockRemain=e.startBlockSize,this.header=new Bb({path:this[Lt](this.path),linkpath:this.type==="Link"?this[Lt](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 Fb({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[Lt](this.path),linkpath:this.type==="Link"?this[Lt](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)}[Lt](e){return jb(e,this.prefix)}[vo](e){return Hb(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()}});Ro.Sync=qu;Ro.Tar=M1;var F1=t=>t.isFile()?"File":t.isDirectory()?"Directory":t.isSymbolicLink()?"SymbolicLink":"Unsupported";Ub.exports=Ro});var zb=$((XM,Gb)=>{"use strict";Gb.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var Uu=$((JM,Wb)=>{"use strict";Wb.exports=ae;ae.Node=Kr;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++)j1(this,arguments[t]);return this.length};ae.prototype.unshift=function(){for(var t=0,e=arguments.length;t<e;t++)$1(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=B1(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 B1(t,e,r){var i=e===t.head?new Kr(r,null,e,t):new Kr(r,e,e.next,t);return i.next===null&&(t.tail=i),i.prev===null&&(t.head=i),t.length++,i}function j1(t,e){t.tail=new Kr(e,t.tail,null,t),t.head||(t.head=t.tail),t.length++}function $1(t,e){t.head=new Kr(e,null,t.head,t),t.tail||(t.tail=t.head),t.length++}function Kr(t,e,r,i){if(!(this instanceof Kr))return new Kr(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{zb()(ae)}catch{}});var Io=$((eF,Qb)=>{"use strict";var Lo=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}},q1=oo(),H1=Su(),U1=go(),Ju=Hu(),G1=Ju.Sync,z1=Ju.Tar,W1=Uu(),Yb=Buffer.alloc(1024),Oo=Symbol("onStat"),xo=Symbol("ended"),Pt=Symbol("queue"),qi=Symbol("current"),Vr=Symbol("process"),Ao=Symbol("processing"),Kb=Symbol("processJob"),It=Symbol("jobs"),Gu=Symbol("jobDone"),To=Symbol("addFSEntry"),Vb=Symbol("addTarEntry"),Ku=Symbol("stat"),Vu=Symbol("readdir"),ko=Symbol("onreaddir"),Co=Symbol("pipe"),Zb=Symbol("entry"),zu=Symbol("entryOpt"),Zu=Symbol("writeEntryClass"),Jb=Symbol("write"),Wu=Symbol("ondrain"),Po=require("fs"),Xb=require("path"),Y1=_o(),Yu=Fi(),Qu=Y1(class extends q1{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=Yu(e.prefix||""),this.linkCache=e.linkCache||new Map,this.statCache=e.statCache||new Map,this.readdirCache=e.readdirCache||new Map,this[Zu]=Ju,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 H1.Gzip(e.gzip),this.zip.on("data",r=>super.write(r)),this.zip.on("end",r=>super.end()),this.zip.on("drain",r=>this[Wu]()),this.on("resume",r=>this.zip.resume())):this.on("drain",this[Wu]),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[Pt]=new W1,this[It]=0,this.jobs=+e.jobs||4,this[Ao]=!1,this[xo]=!1}[Jb](e){return super.write(e)}add(e){return this.write(e),this}end(e){return e&&this.write(e),this[xo]=!0,this[Vr](),this}write(e){if(this[xo])throw new Error("write after end");return e instanceof U1?this[Vb](e):this[To](e),this.flowing}[Vb](e){let r=Yu(Xb.resolve(this.cwd,e.path));if(!this.filter(e.path,e))e.resume();else{let i=new Lo(e.path,r,!1);i.entry=new z1(e,this[zu](i)),i.entry.on("end",n=>this[Gu](i)),this[It]+=1,this[Pt].push(i)}this[Vr]()}[To](e){let r=Yu(Xb.resolve(this.cwd,e));this[Pt].push(new Lo(e,r)),this[Vr]()}[Ku](e){e.pending=!0,this[It]+=1;let r=this.follow?"stat":"lstat";Po[r](e.absolute,(i,n)=>{e.pending=!1,this[It]-=1,i?this.emit("error",i):this[Oo](e,n)})}[Oo](e,r){this.statCache.set(e.absolute,r),e.stat=r,this.filter(e.path,r)||(e.ignore=!0),this[Vr]()}[Vu](e){e.pending=!0,this[It]+=1,Po.readdir(e.absolute,(r,i)=>{if(e.pending=!1,this[It]-=1,r)return this.emit("error",r);this[ko](e,i)})}[ko](e,r){this.readdirCache.set(e.absolute,r),e.readdir=r,this[Vr]()}[Vr](){if(!this[Ao]){this[Ao]=!0;for(let e=this[Pt].head;e!==null&&this[It]<this.jobs;e=e.next)if(this[Kb](e.value),e.value.ignore){let r=e.next;this[Pt].removeNode(e),e.next=r}this[Ao]=!1,this[xo]&&!this[Pt].length&&this[It]===0&&(this.zip?this.zip.end(Yb):(super.write(Yb),super.end()))}}get[qi](){return this[Pt]&&this[Pt].head&&this[Pt].head.value}[Gu](e){this[Pt].shift(),this[It]-=1,this[Vr]()}[Kb](e){if(!e.pending){if(e.entry){e===this[qi]&&!e.piped&&this[Co](e);return}if(e.stat||(this.statCache.has(e.absolute)?this[Oo](e,this.statCache.get(e.absolute)):this[Ku](e)),!!e.stat&&!e.ignore&&!(!this.noDirRecurse&&e.stat.isDirectory()&&!e.readdir&&(this.readdirCache.has(e.absolute)?this[ko](e,this.readdirCache.get(e.absolute)):this[Vu](e),!e.readdir))){if(e.entry=this[Zb](e),!e.entry){e.ignore=!0;return}e===this[qi]&&!e.piped&&this[Co](e)}}}[zu](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}}[Zb](e){this[It]+=1;try{return new this[Zu](e.path,this[zu](e)).on("end",()=>this[Gu](e)).on("error",r=>this.emit("error",r))}catch(r){this.emit("error",r)}}[Wu](){this[qi]&&this[qi].entry&&this[qi].entry.resume()}[Co](e){e.piped=!0,e.readdir&&e.readdir.forEach(n=>{let s=e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[To](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()}}),Xu=class extends Qu{constructor(e){super(e),this[Zu]=G1}pause(){}resume(){}[Ku](e){let r=this.follow?"statSync":"lstatSync";this[Oo](e,Po[r](e.absolute))}[Vu](e,r){this[ko](e,Po.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[To](o+n)}),i?r.on("data",n=>{i.write(n)}):r.on("data",n=>{super[Jb](n)})}};Qu.Sync=Xu;Qb.exports=Qu});var Vi=$(Bn=>{"use strict";var K1=su(),V1=require("events").EventEmitter,Ve=require("fs"),rh=Ve.writev;if(!rh){let t=process.binding("fs"),e=t.FSReqWrap||t.FSReqCallback;rh=(r,i,n,s)=>{let o=(l,c)=>s(l,c,i),a=new e;a.oncomplete=o,t.writeBuffers(r,i,n,a)}}var Yi=Symbol("_autoClose"),gt=Symbol("_close"),Fn=Symbol("_ended"),fe=Symbol("_fd"),e_=Symbol("_finished"),Rr=Symbol("_flags"),eh=Symbol("_flush"),ih=Symbol("_handleChunk"),nh=Symbol("_makeBuf"),Bo=Symbol("_mode"),No=Symbol("_needDrain"),zi=Symbol("_onerror"),Ki=Symbol("_onopen"),th=Symbol("_onread"),Ui=Symbol("_onwrite"),xr=Symbol("_open"),er=Symbol("_path"),Zr=Symbol("_pos"),Nt=Symbol("_queue"),Gi=Symbol("_read"),t_=Symbol("_readSize"),vr=Symbol("_reading"),Do=Symbol("_remain"),r_=Symbol("_size"),Mo=Symbol("_write"),Hi=Symbol("_writing"),Fo=Symbol("_defaultFlag"),Wi=Symbol("_errored"),jo=class extends K1{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[er]=e,this[t_]=r.readSize||16*1024*1024,this[vr]=!1,this[r_]=typeof r.size=="number"?r.size:1/0,this[Do]=this[r_],this[Yi]=typeof r.autoClose=="boolean"?r.autoClose:!0,typeof this[fe]=="number"?this[Gi]():this[xr]()}get fd(){return this[fe]}get path(){return this[er]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[xr](){Ve.open(this[er],"r",(e,r)=>this[Ki](e,r))}[Ki](e,r){e?this[zi](e):(this[fe]=r,this.emit("open",r),this[Gi]())}[nh](){return Buffer.allocUnsafe(Math.min(this[t_],this[Do]))}[Gi](){if(!this[vr]){this[vr]=!0;let e=this[nh]();if(e.length===0)return process.nextTick(()=>this[th](null,0,e));Ve.read(this[fe],e,0,e.length,null,(r,i,n)=>this[th](r,i,n))}}[th](e,r,i){this[vr]=!1,e?this[zi](e):this[ih](r,i)&&this[Gi]()}[gt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ve.close(e,r=>r?this.emit("error",r):this.emit("close"))}}[zi](e){this[vr]=!0,this[gt](),this.emit("error",e)}[ih](e,r){let i=!1;return this[Do]-=e,e>0&&(i=super.write(e<r.length?r.slice(0,e):r)),(e===0||this[Do]<=0)&&(i=!1,this[gt](),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)}}},sh=class extends jo{[xr](){let e=!0;try{this[Ki](null,Ve.openSync(this[er],"r")),e=!1}finally{e&&this[gt]()}}[Gi](){let e=!0;try{if(!this[vr]){this[vr]=!0;do{let r=this[nh](),i=r.length===0?0:Ve.readSync(this[fe],r,0,r.length,null);if(!this[ih](i,r))break}while(!0);this[vr]=!1}e=!1}finally{e&&this[gt]()}}[gt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ve.closeSync(e),this.emit("close")}}},$o=class extends V1{constructor(e,r){r=r||{},super(r),this.readable=!1,this.writable=!0,this[Wi]=!1,this[Hi]=!1,this[Fn]=!1,this[No]=!1,this[Nt]=[],this[er]=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[Fo]=r.flags===void 0,this[Rr]=this[Fo]?i:r.flags,this[fe]===null&&this[xr]()}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[er]}[zi](e){this[gt](),this[Hi]=!0,this.emit("error",e)}[xr](){Ve.open(this[er],this[Rr],this[Bo],(e,r)=>this[Ki](e,r))}[Ki](e,r){this[Fo]&&this[Rr]==="r+"&&e&&e.code==="ENOENT"?(this[Rr]="w",this[xr]()):e?this[zi](e):(this[fe]=r,this.emit("open",r),this[eh]())}end(e,r){return e&&this.write(e,r),this[Fn]=!0,!this[Hi]&&!this[Nt].length&&typeof this[fe]=="number"&&this[Ui](null,0),this}write(e,r){return typeof e=="string"&&(e=Buffer.from(e,r)),this[Fn]?(this.emit("error",new Error("write() after end()")),!1):this[fe]===null||this[Hi]||this[Nt].length?(this[Nt].push(e),this[No]=!0,!1):(this[Hi]=!0,this[Mo](e),!0)}[Mo](e){Ve.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[Nt].length?this[eh]():(this[Hi]=!1,this[Fn]&&!this[e_]?(this[e_]=!0,this[gt](),this.emit("finish")):this[No]&&(this[No]=!1,this.emit("drain"))))}[eh](){if(this[Nt].length===0)this[Fn]&&this[Ui](null,0);else if(this[Nt].length===1)this[Mo](this[Nt].pop());else{let e=this[Nt];this[Nt]=[],rh(this[fe],e,this[Zr],(r,i)=>this[Ui](r,i))}}[gt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ve.close(e,r=>r?this.emit("error",r):this.emit("close"))}}},oh=class extends $o{[xr](){let e;if(this[Fo]&&this[Rr]==="r+")try{e=Ve.openSync(this[er],this[Rr],this[Bo])}catch(r){if(r.code==="ENOENT")return this[Rr]="w",this[xr]();throw r}else e=Ve.openSync(this[er],this[Rr],this[Bo]);this[Ki](null,e)}[gt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ve.closeSync(e),this.emit("close")}}[Mo](e){let r=!0;try{this[Ui](null,Ve.writeSync(this[fe],e,0,e.length,this[Zr])),r=!1}finally{if(r)try{this[gt]()}catch{}}}};Bn.ReadStream=jo;Bn.ReadStreamSync=sh;Bn.WriteStream=$o;Bn.WriteStreamSync=oh});var Yo=$((iF,u_)=>{"use strict";var Z1=_o(),X1=ji(),J1=require("events"),Q1=Uu(),eC=1024*1024,tC=go(),i_=bo(),rC=Su(),{nextTick:iC}=require("process"),ah=Buffer.from([31,139]),lt=Symbol("state"),Xr=Symbol("writeEntry"),tr=Symbol("readEntry"),lh=Symbol("nextEntry"),n_=Symbol("processEntry"),ct=Symbol("extendedHeader"),jn=Symbol("globalExtendedHeader"),Ar=Symbol("meta"),s_=Symbol("emitMeta"),me=Symbol("buffer"),rr=Symbol("queue"),Jr=Symbol("ended"),o_=Symbol("emittedEnd"),Qr=Symbol("emit"),Ze=Symbol("unzip"),qo=Symbol("consumeChunk"),Ho=Symbol("consumeChunkSub"),ch=Symbol("consumeBody"),a_=Symbol("consumeMeta"),l_=Symbol("consumeHeader"),Uo=Symbol("consuming"),uh=Symbol("bufferConcat"),hh=Symbol("maybeEnd"),$n=Symbol("writing"),Or=Symbol("aborted"),Go=Symbol("onDone"),ei=Symbol("sawValidEntry"),zo=Symbol("sawNullBlock"),Wo=Symbol("sawEOF"),c_=Symbol("closeStream"),nC=t=>!0;u_.exports=Z1(class extends J1{constructor(e){e=e||{},super(e),this.file=e.file||"",this[ei]=null,this.on(Go,r=>{(this[lt]==="begin"||this[ei]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),e.ondone?this.on(Go,e.ondone):this.on(Go,r=>{this.emit("prefinish"),this.emit("finish"),this.emit("end")}),this.strict=!!e.strict,this.maxMetaEntrySize=e.maxMetaEntrySize||eC,this.filter=typeof e.filter=="function"?e.filter:nC,this.writable=!0,this.readable=!1,this[rr]=new Q1,this[me]=null,this[tr]=null,this[Xr]=null,this[lt]="begin",this[Ar]="",this[ct]=null,this[jn]=null,this[Jr]=!1,this[Ze]=null,this[Or]=!1,this[zo]=!1,this[Wo]=!1,this.on("end",()=>this[c_]()),typeof e.onwarn=="function"&&this.on("warn",e.onwarn),typeof e.onentry=="function"&&this.on("entry",e.onentry)}[l_](e,r){this[ei]===null&&(this[ei]=!1);let i;try{i=new X1(e,r,this[ct],this[jn])}catch(n){return this.warn("TAR_ENTRY_INVALID",n)}if(i.nullBlock)this[zo]?(this[Wo]=!0,this[lt]==="begin"&&(this[lt]="header"),this[Qr]("eof")):(this[zo]=!0,this[Qr]("nullBlock"));else if(this[zo]=!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[Xr]=new tC(i,this[ct],this[jn]);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[lt]="ignore",s.resume()):s.size>0&&(this[Ar]="",s.on("data",o=>this[Ar]+=o),this[lt]="meta"):(this[ct]=null,s.ignore=s.ignore||!this.filter(s.path,s),s.ignore?(this[Qr]("ignoredEntry",s),this[lt]=s.remain?"ignore":"header",s.resume()):(s.remain?this[lt]="body":(this[lt]="header",s.end()),this[tr]?this[rr].push(s):(this[rr].push(s),this[lh]())))}}}[c_](){iC(()=>this.emit("close"))}[n_](e){let r=!0;return e?Array.isArray(e)?this.emit.apply(this,e):(this[tr]=e,this.emit("entry",e),e.emittedEnd||(e.on("end",i=>this[lh]()),r=!1)):(this[tr]=null,r=!1),r}[lh](){do;while(this[n_](this[rr].shift()));if(!this[rr].length){let e=this[tr];!e||e.flowing||e.size===e.remain?this[$n]||this.emit("drain"):e.once("drain",i=>this.emit("drain"))}}[ch](e,r){let i=this[Xr],n=i.blockRemain,s=n>=e.length&&r===0?e:e.slice(r,r+n);return i.write(s),i.blockRemain||(this[lt]="header",this[Xr]=null,i.end()),s.length}[a_](e,r){let i=this[Xr],n=this[ch](e,r);return this[Xr]||this[s_](i),n}[Qr](e,r,i){!this[rr].length&&!this[tr]?this.emit(e,r,i):this[rr].push([e,r,i])}[s_](e){switch(this[Qr]("meta",this[Ar]),e.type){case"ExtendedHeader":case"OldExtendedHeader":this[ct]=i_.parse(this[Ar],this[ct],!1);break;case"GlobalExtendedHeader":this[jn]=i_.parse(this[Ar],this[jn],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[ct]=this[ct]||Object.create(null),this[ct].path=this[Ar].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[ct]=this[ct]||Object.create(null),this[ct].linkpath=this[Ar].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+e.type)}}abort(e){this[Or]=!0,this.emit("abort",e),this.warn("TAR_ABORT",e,{recoverable:!1})}write(e){if(this[Or])return;if(this[Ze]===null&&e){if(this[me]&&(e=Buffer.concat([this[me],e]),this[me]=null),e.length<ah.length)return this[me]=e,!0;for(let i=0;this[Ze]===null&&i<ah.length;i++)e[i]!==ah[i]&&(this[Ze]=!1);if(this[Ze]===null){let i=this[Jr];this[Jr]=!1,this[Ze]=new rC.Unzip,this[Ze].on("data",s=>this[qo](s)),this[Ze].on("error",s=>this.abort(s)),this[Ze].on("end",s=>{this[Jr]=!0,this[qo]()}),this[$n]=!0;let n=this[Ze][i?"end":"write"](e);return this[$n]=!1,n}}this[$n]=!0,this[Ze]?this[Ze].write(e):this[qo](e),this[$n]=!1;let r=this[rr].length?!1:this[tr]?this[tr].flowing:!0;return!r&&!this[rr].length&&this[tr].once("drain",i=>this.emit("drain")),r}[uh](e){e&&!this[Or]&&(this[me]=this[me]?Buffer.concat([this[me],e]):e)}[hh](){if(this[Jr]&&!this[o_]&&!this[Or]&&!this[Uo]){this[o_]=!0;let e=this[Xr];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](Go)}}[qo](e){if(this[Uo])this[uh](e);else if(!e&&!this[me])this[hh]();else{if(this[Uo]=!0,this[me]){this[uh](e);let r=this[me];this[me]=null,this[Ho](r)}else this[Ho](e);for(;this[me]&&this[me].length>=512&&!this[Or]&&!this[Wo];){let r=this[me];this[me]=null,this[Ho](r)}this[Uo]=!1}(!this[me]||this[Jr])&&this[hh]()}[Ho](e){let r=0,i=e.length;for(;r+512<=i&&!this[Or]&&!this[Wo];)switch(this[lt]){case"begin":case"header":this[l_](e,r),r+=512;break;case"ignore":case"body":r+=this[ch](e,r);break;case"meta":r+=this[a_](e,r);break;default:throw new Error("invalid state: "+this[lt])}r<i&&(this[me]?this[me]=Buffer.concat([e.slice(r),this[me]]):this[me]=e.slice(r))}end(e){this[Or]||(this[Ze]?this[Ze].end(e):(this[Jr]=!0,this.write(e)))}})});var Ko=$((nF,d_)=>{"use strict";var sC=Pi(),f_=Yo(),Zi=require("fs"),oC=Vi(),h_=require("path"),fh=$i();d_.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=sC(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&&lC(i,e),i.noResume||aC(i),i.file&&i.sync?cC(i):i.file?uC(i,r):p_(i)};var aC=t=>{let e=t.onentry;t.onentry=e?r=>{e(r),r.resume()}:r=>r.resume()},lC=(t,e)=>{let r=new Map(e.map(s=>[fh(s),!0])),i=t.filter,n=(s,o)=>{let a=o||h_.parse(s).root||".",l=s===a?!1:r.has(s)?r.get(s):n(h_.dirname(s),a);return r.set(s,l),l};t.filter=i?(s,o)=>i(s,o)&&n(fh(s)):s=>n(fh(s))},cC=t=>{let e=p_(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,l=Buffer.allocUnsafe(o);for(n=Zi.openSync(r,"r");a<s.size;){let c=Zi.readSync(n,l,0,o,a);a+=c,e.write(l.slice(0,c))}e.end()}i=!1}finally{if(i&&n)try{Zi.closeSync(n)}catch{}}},uC=(t,e)=>{let r=new f_(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,(l,c)=>{if(l)a(l);else{let u=new oC.ReadStream(n,{readSize:i,size:c.size});u.on("error",a),u.pipe(r)}})});return e?s.then(e,e):s},p_=t=>new f_(t)});var w_=$((sF,__)=>{"use strict";var hC=Pi(),Vo=Io(),m_=Vi(),g_=Ko(),y_=require("path");__.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=hC(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?fC(i,e):i.file?pC(i,e,r):i.sync?dC(i,e):mC(i,e)};var fC=(t,e)=>{let r=new Vo.Sync(t),i=new m_.WriteStreamSync(t.file,{mode:t.mode||438});r.pipe(i),b_(r,e)},pC=(t,e,r)=>{let i=new Vo(t),n=new m_.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 ph(i,e),r?s.then(r,r):s},b_=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?g_({file:y_.resolve(t.cwd,r.slice(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},ph=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return g_({file:y_.resolve(t.cwd,r.slice(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>ph(t,e));t.add(r)}t.end()},dC=(t,e)=>{let r=new Vo.Sync(t);return b_(r,e),r},mC=(t,e)=>{let r=new Vo(t);return ph(r,e),r}});var dh=$((oF,O_)=>{"use strict";var gC=Pi(),S_=Io(),it=require("fs"),E_=Vi(),v_=Ko(),R_=require("path"),x_=ji();O_.exports=(t,e,r)=>{let i=gC(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?yC(i,e):_C(i,e,r)};var yC=(t,e)=>{let r=new S_.Sync(t),i=!0,n,s;try{try{n=it.openSync(t.file,"r+")}catch(l){if(l.code==="ENOENT")n=it.openSync(t.file,"w+");else throw l}let o=it.fstatSync(n),a=Buffer.alloc(512);e:for(s=0;s<o.size;s+=512){for(let u=0,f=0;u<512;u+=f){if(f=it.readSync(n,a,u,a.length-u,s+u),s===0&&a[0]===31&&a[1]===139)throw new Error("cannot append to compressed archives");if(!f)break e}let l=new x_(a);if(!l.cksumValid)break;let c=512*Math.ceil(l.size/512);if(s+c+512>o.size)break;s+=c,t.mtimeCache&&t.mtimeCache.set(l.path,l.mtime)}i=!1,bC(t,r,s,n,e)}finally{if(i)try{it.closeSync(n)}catch{}}},bC=(t,e,r,i,n)=>{let s=new E_.WriteStreamSync(t.file,{fd:i,start:r});e.pipe(s),wC(e,n)},_C=(t,e,r)=>{e=Array.from(e);let i=new S_(t),n=(o,a,l)=>{let c=(g,y)=>{g?it.close(o,b=>l(g)):l(null,y)},u=0;if(a===0)return c(null,0);let f=0,h=Buffer.alloc(512),p=(g,y)=>{if(g)return c(g);if(f+=y,f<512&&y)return it.read(o,h,f,h.length-f,u+f,p);if(u===0&&h[0]===31&&h[1]===139)return c(new Error("cannot append to compressed archives"));if(f<512)return c(null,u);let b=new x_(h);if(!b.cksumValid)return c(null,u);let x=512*Math.ceil(b.size/512);if(u+x+512>a||(u+=x+512,u>=a))return c(null,u);t.mtimeCache&&t.mtimeCache.set(b.path,b.mtime),f=0,it.read(o,h,0,512,u,p)};it.read(o,h,0,512,u,p)},s=new Promise((o,a)=>{i.on("error",a);let l="r+",c=(u,f)=>{if(u&&u.code==="ENOENT"&&l==="r+")return l="w+",it.open(t.file,l,c);if(u)return a(u);it.fstat(f,(h,p)=>{if(h)return it.close(f,()=>a(h));n(f,p.size,(g,y)=>{if(g)return a(g);let b=new E_.WriteStream(t.file,{fd:f,start:y});i.pipe(b),b.on("error",a),b.on("close",o),A_(i,e)})})};it.open(t.file,l,c)});return r?s.then(r,r):s},wC=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?v_({file:R_.resolve(t.cwd,r.slice(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},A_=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return v_({file:R_.resolve(t.cwd,r.slice(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>A_(t,e));t.add(r)}t.end()}});var k_=$((aF,T_)=>{"use strict";var SC=Pi(),EC=dh();T_.exports=(t,e,r)=>{let i=SC(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),vC(i),EC(i,e,r)};var vC=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 P_=$((lF,L_)=>{var{promisify:C_}=require("util"),Tr=require("fs"),RC=t=>{if(!t)t={mode:511,fs:Tr};else if(typeof t=="object")t={mode:511,fs:Tr,...t};else if(typeof t=="number")t={mode:t,fs:Tr};else if(typeof t=="string")t={mode:parseInt(t,8),fs:Tr};else throw new TypeError("invalid options argument");return t.mkdir=t.mkdir||t.fs.mkdir||Tr.mkdir,t.mkdirAsync=C_(t.mkdir),t.stat=t.stat||t.fs.stat||Tr.stat,t.statAsync=C_(t.stat),t.statSync=t.statSync||t.fs.statSync||Tr.statSync,t.mkdirSync=t.mkdirSync||t.fs.mkdirSync||Tr.mkdirSync,t};L_.exports=RC});var N_=$((cF,I_)=>{var xC=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:AC,parse:OC}=require("path"),TC=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=AC(t),xC==="win32"){let e=/[*|"<>?:]/,{root:r}=OC(t);if(e.test(t.substr(r.length)))throw Object.assign(new Error("Illegal characters in path."),{path:t,code:"EINVAL"})}return t};I_.exports=TC});var j_=$((uF,B_)=>{var{dirname:D_}=require("path"),M_=(t,e,r=void 0)=>r===e?Promise.resolve():t.statAsync(e).then(i=>i.isDirectory()?r:void 0,i=>i.code==="ENOENT"?M_(t,D_(e),e):void 0),F_=(t,e,r=void 0)=>{if(r!==e)try{return t.statSync(e).isDirectory()?r:void 0}catch(i){return i.code==="ENOENT"?F_(t,D_(e),e):void 0}};B_.exports={findMade:M_,findMadeSync:F_}});var yh=$((hF,q_)=>{var{dirname:$_}=require("path"),mh=(t,e,r)=>{e.recursive=!1;let i=$_(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 mh(i,e).then(s=>mh(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})})},gh=(t,e,r)=>{let i=$_(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 gh(t,e,gh(i,e,r));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;try{if(!e.statSync(t).isDirectory())throw n}catch{throw n}}};q_.exports={mkdirpManual:mh,mkdirpManualSync:gh}});var G_=$((fF,U_)=>{var{dirname:H_}=require("path"),{findMade:kC,findMadeSync:CC}=j_(),{mkdirpManual:LC,mkdirpManualSync:PC}=yh(),IC=(t,e)=>(e.recursive=!0,H_(t)===t?e.mkdirAsync(t,e):kC(e,t).then(i=>e.mkdirAsync(t,e).then(()=>i).catch(n=>{if(n.code==="ENOENT")return LC(t,e);throw n}))),NC=(t,e)=>{if(e.recursive=!0,H_(t)===t)return e.mkdirSync(t,e);let i=CC(e,t);try{return e.mkdirSync(t,e),i}catch(n){if(n.code==="ENOENT")return PC(t,e);throw n}};U_.exports={mkdirpNative:IC,mkdirpNativeSync:NC}});var K_=$((pF,Y_)=>{var z_=require("fs"),DC=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version,bh=DC.replace(/^v/,"").split("."),W_=+bh[0]>10||+bh[0]==10&&+bh[1]>=12,MC=W_?t=>t.mkdir===z_.mkdir:()=>!1,FC=W_?t=>t.mkdirSync===z_.mkdirSync:()=>!1;Y_.exports={useNative:MC,useNativeSync:FC}});var ew=$((dF,Q_)=>{var Xi=P_(),Ji=N_(),{mkdirpNative:V_,mkdirpNativeSync:Z_}=G_(),{mkdirpManual:X_,mkdirpManualSync:J_}=yh(),{useNative:BC,useNativeSync:jC}=K_(),Qi=(t,e)=>(t=Ji(t),e=Xi(e),BC(e)?V_(t,e):X_(t,e)),$C=(t,e)=>(t=Ji(t),e=Xi(e),jC(e)?Z_(t,e):J_(t,e));Qi.sync=$C;Qi.native=(t,e)=>V_(Ji(t),Xi(e));Qi.manual=(t,e)=>X_(Ji(t),Xi(e));Qi.nativeSync=(t,e)=>Z_(Ji(t),Xi(e));Qi.manualSync=(t,e)=>J_(Ji(t),Xi(e));Q_.exports=Qi});var aw=$((mF,ow)=>{"use strict";var ut=require("fs"),ti=require("path"),qC=ut.lchown?"lchown":"chown",HC=ut.lchownSync?"lchownSync":"chownSync",rw=ut.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),tw=(t,e,r)=>{try{return ut[HC](t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},UC=(t,e,r)=>{try{return ut.chownSync(t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},GC=rw?(t,e,r,i)=>n=>{!n||n.code!=="EISDIR"?i(n):ut.chown(t,e,r,i)}:(t,e,r,i)=>i,_h=rw?(t,e,r)=>{try{return tw(t,e,r)}catch(i){if(i.code!=="EISDIR")throw i;UC(t,e,r)}}:(t,e,r)=>tw(t,e,r),zC=process.version,iw=(t,e,r)=>ut.readdir(t,e,r),WC=(t,e)=>ut.readdirSync(t,e);/^v4\./.test(zC)&&(iw=(t,e,r)=>ut.readdir(t,r));var Zo=(t,e,r,i)=>{ut[qC](t,e,r,GC(t,e,r,n=>{i(n&&n.code!=="ENOENT"?n:null)}))},nw=(t,e,r,i,n)=>{if(typeof e=="string")return ut.lstat(ti.resolve(t,e),(s,o)=>{if(s)return n(s.code!=="ENOENT"?s:null);o.name=e,nw(t,o,r,i,n)});if(e.isDirectory())wh(ti.resolve(t,e.name),r,i,s=>{if(s)return n(s);let o=ti.resolve(t,e.name);Zo(o,r,i,n)});else{let s=ti.resolve(t,e.name);Zo(s,r,i,n)}},wh=(t,e,r,i)=>{iw(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 Zo(t,e,r,i);let o=s.length,a=null,l=c=>{if(!a){if(c)return i(a=c);if(--o===0)return Zo(t,e,r,i)}};s.forEach(c=>nw(t,c,e,r,l))})},YC=(t,e,r,i)=>{if(typeof e=="string")try{let n=ut.lstatSync(ti.resolve(t,e));n.name=e,e=n}catch(n){if(n.code==="ENOENT")return;throw n}e.isDirectory()&&sw(ti.resolve(t,e.name),r,i),_h(ti.resolve(t,e.name),r,i)},sw=(t,e,r)=>{let i;try{i=WC(t,{withFileTypes:!0})}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR"||n.code==="ENOTSUP")return _h(t,e,r);throw n}return i&&i.length&&i.forEach(n=>YC(t,n,e,r)),_h(t,e,r)};ow.exports=wh;wh.sync=sw});var hw=$((gF,Sh)=>{"use strict";var lw=ew(),ht=require("fs"),Xo=require("path"),cw=aw(),yt=Fi(),Jo=class extends Error{constructor(e,r){super("Cannot extract through symbolic link"),this.path=r,this.symlink=e}get name(){return"SylinkError"}},Qo=class extends Error{constructor(e,r){super(r+": Cannot cd into '"+e+"'"),this.path=e,this.code=r}get name(){return"CwdError"}},ea=(t,e)=>t.get(yt(e)),qn=(t,e,r)=>t.set(yt(e),r),KC=(t,e)=>{ht.stat(t,(r,i)=>{(r||!i.isDirectory())&&(r=new Qo(t,r&&r.code||"ENOTDIR")),e(r)})};Sh.exports=(t,e,r)=>{t=yt(t);let i=e.umask,n=e.mode|448,s=(n&i)!==0,o=e.uid,a=e.gid,l=typeof o=="number"&&typeof a=="number"&&(o!==e.processUid||a!==e.processGid),c=e.preserve,u=e.unlink,f=e.cache,h=yt(e.cwd),p=(b,x)=>{b?r(b):(qn(f,t,!0),x&&l?cw(x,o,a,k=>p(k)):s?ht.chmod(t,n,r):r())};if(f&&ea(f,t)===!0)return p();if(t===h)return KC(t,p);if(c)return lw(t,{mode:n}).then(b=>p(null,b),p);let y=yt(Xo.relative(h,t)).split("/");ta(h,y,n,f,u,h,null,p)};var ta=(t,e,r,i,n,s,o,a)=>{if(!e.length)return a(null,o);let l=e.shift(),c=yt(Xo.resolve(t+"/"+l));if(ea(i,c))return ta(c,e,r,i,n,s,o,a);ht.mkdir(c,r,uw(c,e,r,i,n,s,o,a))},uw=(t,e,r,i,n,s,o,a)=>l=>{l?ht.lstat(t,(c,u)=>{if(c)c.path=c.path&&yt(c.path),a(c);else if(u.isDirectory())ta(t,e,r,i,n,s,o,a);else if(n)ht.unlink(t,f=>{if(f)return a(f);ht.mkdir(t,r,uw(t,e,r,i,n,s,o,a))});else{if(u.isSymbolicLink())return a(new Jo(t,t+"/"+e.join("/")));a(l)}}):(o=o||t,ta(t,e,r,i,n,s,o,a))},VC=t=>{let e=!1,r="ENOTDIR";try{e=ht.statSync(t).isDirectory()}catch(i){r=i.code}finally{if(!e)throw new Qo(t,r)}};Sh.exports.sync=(t,e)=>{t=yt(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),l=e.preserve,c=e.unlink,u=e.cache,f=yt(e.cwd),h=b=>{qn(u,t,!0),b&&a&&cw.sync(b,s,o),n&&ht.chmodSync(t,i)};if(u&&ea(u,t)===!0)return h();if(t===f)return VC(f),h();if(l)return h(lw.sync(t,i));let g=yt(Xo.relative(f,t)).split("/"),y=null;for(let b=g.shift(),x=f;b&&(x+="/"+b);b=g.shift())if(x=yt(Xo.resolve(x)),!ea(u,x))try{ht.mkdirSync(x,i),y=y||x,qn(u,x,!0)}catch{let C=ht.lstatSync(x);if(C.isDirectory()){qn(u,x,!0);continue}else if(c){ht.unlinkSync(x),ht.mkdirSync(x,i),y=y||x,qn(u,x,!0);continue}else if(C.isSymbolicLink())return new Jo(x,x+"/"+g.join("/"))}return h(y)}});var vh=$((yF,fw)=>{var Eh=Object.create(null),{hasOwnProperty:ZC}=Object.prototype;fw.exports=t=>(ZC.call(Eh,t)||(Eh[t]=t.normalize("NFKD")),Eh[t])});var gw=$((bF,mw)=>{var pw=require("assert"),XC=vh(),JC=$i(),{join:dw}=require("path"),QC=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,eL=QC==="win32";mw.exports=()=>{let t=new Map,e=new Map,r=c=>c.split("/").slice(0,-1).reduce((f,h)=>(f.length&&(h=dw(f[f.length-1],h)),f.push(h||"/"),f),[]),i=new Set,n=c=>{let u=e.get(c);if(!u)throw new Error("function does not have any path reservations");return{paths:u.paths.map(f=>t.get(f)),dirs:[...u.dirs].map(f=>t.get(f))}},s=c=>{let{paths:u,dirs:f}=n(c);return u.every(h=>h[0]===c)&&f.every(h=>h[0]instanceof Set&&h[0].has(c))},o=c=>i.has(c)||!s(c)?!1:(i.add(c),c(()=>a(c)),!0),a=c=>{if(!i.has(c))return!1;let{paths:u,dirs:f}=e.get(c),h=new Set;return u.forEach(p=>{let g=t.get(p);pw.equal(g[0],c),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);pw(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(c)}),i.delete(c),h.forEach(p=>o(p)),!0};return{check:s,reserve:(c,u)=>{c=eL?["win32 parallelization disabled"]:c.map(h=>XC(JC(dw(h))).toLowerCase());let f=new Set(c.map(h=>r(h)).reduce((h,p)=>h.concat(p)));return e.set(u,{dirs:f,paths:c}),c.forEach(h=>{let p=t.get(h);p?p.push(u):t.set(h,[u])}),f.forEach(h=>{let p=t.get(h);p?p[p.length-1]instanceof Set?p[p.length-1].add(u):p.push(new Set([u])):t.set(h,[new Set([u])])}),o(u)}}}});var _w=$((_F,bw)=>{var tL=process.env.__FAKE_PLATFORM__||process.platform,rL=tL==="win32",iL=global.__FAKE_TESTING_FS__||require("fs"),{O_CREAT:nL,O_TRUNC:sL,O_WRONLY:oL,UV_FS_O_FILEMAP:yw=0}=iL.constants,aL=rL&&!!yw,lL=512*1024,cL=yw|sL|nL|oL;bw.exports=aL?t=>t<lL?cL:"w":()=>"w"});var Ph=$((wF,Iw)=>{"use strict";var uL=require("assert"),hL=Yo(),le=require("fs"),fL=Vi(),ir=require("path"),Cw=hw(),ww=Lu(),pL=gw(),dL=Pu(),nt=Fi(),mL=$i(),gL=vh(),Sw=Symbol("onEntry"),Ah=Symbol("checkFs"),Ew=Symbol("checkFs2"),na=Symbol("pruneCache"),Oh=Symbol("isReusable"),ft=Symbol("makeFs"),Th=Symbol("file"),kh=Symbol("directory"),sa=Symbol("link"),vw=Symbol("symlink"),Rw=Symbol("hardlink"),xw=Symbol("unsupported"),Aw=Symbol("checkPath"),kr=Symbol("mkdir"),je=Symbol("onError"),ra=Symbol("pending"),Ow=Symbol("pend"),en=Symbol("unpend"),Rh=Symbol("ended"),xh=Symbol("maybeClose"),Ch=Symbol("skip"),Hn=Symbol("doChown"),Un=Symbol("uid"),Gn=Symbol("gid"),zn=Symbol("checkedCwd"),Lw=require("crypto"),Pw=_w(),yL=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,Wn=yL==="win32",bL=(t,e)=>{if(!Wn)return le.unlink(t,e);let r=t+".DELETE."+Lw.randomBytes(16).toString("hex");le.rename(t,r,i=>{if(i)return e(i);le.unlink(r,e)})},_L=t=>{if(!Wn)return le.unlinkSync(t);let e=t+".DELETE."+Lw.randomBytes(16).toString("hex");le.renameSync(t,e),le.unlinkSync(e)},Tw=(t,e,r)=>t===t>>>0?t:e===e>>>0?e:r,kw=t=>gL(mL(nt(t))).toLowerCase(),wL=(t,e)=>{e=kw(e);for(let r of t.keys()){let i=kw(r);(i===e||i.indexOf(e+"/")===0)&&t.delete(r)}},SL=t=>{for(let e of t.keys())t.delete(e)},Yn=class extends hL{constructor(e){if(e||(e={}),e.ondone=r=>{this[Rh]=!0,this[xh]()},super(e),this[zn]=!1,this.reservations=pL(),this.transform=typeof e.transform=="function"?e.transform:null,this.writable=!0,this.readable=!1,this[ra]=0,this[Rh]=!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||Wn,this.newer=!!e.newer,this.keep=!!e.keep,this.noMtime=!!e.noMtime,this.preservePaths=!!e.preservePaths,this.unlink=!!e.unlink,this.cwd=nt(ir.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[Sw](r))}warn(e,r,i={}){return(e==="TAR_BAD_ARCHIVE"||e==="TAR_ABORT")&&(i.recoverable=!1),super.warn(e,r,i)}[xh](){this[Rh]&&this[ra]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"))}[Aw](e){if(this.strip){let r=nt(e.path).split("/");if(r.length<this.strip)return!1;if(e.path=r.slice(this.strip).join("/"),e.type==="Link"){let i=nt(e.linkpath).split("/");if(i.length>=this.strip)e.linkpath=i.slice(this.strip).join("/");else return!1}}if(!this.preservePaths){let r=nt(e.path),i=r.split("/");if(i.includes("..")||Wn&&/^[a-z]:\.\.$/i.test(i[0]))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:e,path:r}),!1;let[n,s]=dL(r);n&&(e.path=s,this.warn("TAR_ENTRY_INFO",`stripping ${n} from absolute path`,{entry:e,path:r}))}if(ir.isAbsolute(e.path)?e.absolute=nt(ir.resolve(e.path)):e.absolute=nt(ir.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:nt(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}=ir.win32.parse(e.absolute);e.absolute=r+ww.encode(e.absolute.slice(r.length));let{root:i}=ir.win32.parse(e.path);e.path=i+ww.encode(e.path.slice(i.length))}return!0}[Sw](e){if(!this[Aw](e))return e.resume();switch(uL.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[Ah](e);case"CharacterDevice":case"BlockDevice":case"FIFO":default:return this[xw](e)}}[je](e,r){e.name==="CwdError"?this.emit("error",e):(this.warn("TAR_ENTRY_ERROR",e,{entry:r}),this[en](),r.resume())}[kr](e,r,i){Cw(nt(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)}[Hn](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}[Un](e){return Tw(this.uid,e.uid,this.processUid)}[Gn](e){return Tw(this.gid,e.gid,this.processGid)}[Th](e,r){let i=e.mode&4095||this.fmode,n=new fL.WriteStream(e.absolute,{flags:Pw(e.size),mode:i,autoClose:!1});n.on("error",l=>{n.fd&&le.close(n.fd,()=>{}),n.write=()=>!0,this[je](l,e),r()});let s=1,o=l=>{if(l){n.fd&&le.close(n.fd,()=>{}),this[je](l,e),r();return}--s===0&&le.close(n.fd,c=>{c?this[je](c,e):this[en](),r()})};n.on("finish",l=>{let c=e.absolute,u=n.fd;if(e.mtime&&!this.noMtime){s++;let f=e.atime||new Date,h=e.mtime;le.futimes(u,f,h,p=>p?le.utimes(c,f,h,g=>o(g&&p)):o())}if(this[Hn](e)){s++;let f=this[Un](e),h=this[Gn](e);le.fchown(u,f,h,p=>p?le.chown(c,f,h,g=>o(g&&p)):o())}o()});let a=this.transform&&this.transform(e)||e;a!==e&&(a.on("error",l=>{this[je](l,e),r()}),e.pipe(a)),a.pipe(n)}[kh](e,r){let i=e.mode&4095||this.dmode;this[kr](e.absolute,i,n=>{if(n){this[je](n,e),r();return}let s=1,o=a=>{--s===0&&(r(),this[en](),e.resume())};e.mtime&&!this.noMtime&&(s++,le.utimes(e.absolute,e.atime||new Date,e.mtime,o)),this[Hn](e)&&(s++,le.chown(e.absolute,this[Un](e),this[Gn](e),o)),o()})}[xw](e){e.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${e.type}`,{entry:e}),e.resume()}[vw](e,r){this[sa](e,e.linkpath,"symlink",r)}[Rw](e,r){let i=nt(ir.resolve(this.cwd,e.linkpath));this[sa](e,i,"link",r)}[Ow](){this[ra]++}[en](){this[ra]--,this[xh]()}[Ch](e){this[en](),e.resume()}[Oh](e,r){return e.type==="File"&&!this.unlink&&r.isFile()&&r.nlink<=1&&!Wn}[Ah](e){this[Ow]();let r=[e.path];e.linkpath&&r.push(e.linkpath),this.reservations.reserve(r,i=>this[Ew](e,i))}[na](e){e.type==="SymbolicLink"?SL(this.dirCache):e.type!=="Directory"&&wL(this.dirCache,e.absolute)}[Ew](e,r){this[na](e);let i=a=>{this[na](e),r(a)},n=()=>{this[kr](this.cwd,this.dmode,a=>{if(a){this[je](a,e),i();return}this[zn]=!0,s()})},s=()=>{if(e.absolute!==this.cwd){let a=nt(ir.dirname(e.absolute));if(a!==this.cwd)return this[kr](a,this.dmode,l=>{if(l){this[je](l,e),i();return}o()})}o()},o=()=>{le.lstat(e.absolute,(a,l)=>{if(l&&(this.keep||this.newer&&l.mtime>e.mtime)){this[Ch](e),i();return}if(a||this[Oh](e,l))return this[ft](null,e,i);if(l.isDirectory()){if(e.type==="Directory"){let c=!this.noChmod&&e.mode&&(l.mode&4095)!==e.mode,u=f=>this[ft](f,e,i);return c?le.chmod(e.absolute,e.mode,u):u()}if(e.absolute!==this.cwd)return le.rmdir(e.absolute,c=>this[ft](c,e,i))}if(e.absolute===this.cwd)return this[ft](null,e,i);bL(e.absolute,c=>this[ft](c,e,i))})};this[zn]?s():n()}[ft](e,r,i){if(e){this[je](e,r),i();return}switch(r.type){case"File":case"OldFile":case"ContiguousFile":return this[Th](r,i);case"Link":return this[Rw](r,i);case"SymbolicLink":return this[vw](r,i);case"Directory":case"GNUDumpDir":return this[kh](r,i)}}[sa](e,r,i,n){le[i](r,e.absolute,s=>{s?this[je](s,e):(this[en](),e.resume()),n()})}},ia=t=>{try{return[null,t()]}catch(e){return[e,null]}},Lh=class extends Yn{[ft](e,r){return super[ft](e,r,()=>{})}[Ah](e){if(this[na](e),!this[zn]){let s=this[kr](this.cwd,this.dmode);if(s)return this[je](s,e);this[zn]=!0}if(e.absolute!==this.cwd){let s=nt(ir.dirname(e.absolute));if(s!==this.cwd){let o=this[kr](s,this.dmode);if(o)return this[je](o,e)}}let[r,i]=ia(()=>le.lstatSync(e.absolute));if(i&&(this.keep||this.newer&&i.mtime>e.mtime))return this[Ch](e);if(r||this[Oh](e,i))return this[ft](null,e);if(i.isDirectory()){if(e.type==="Directory"){let o=!this.noChmod&&e.mode&&(i.mode&4095)!==e.mode,[a]=o?ia(()=>{le.chmodSync(e.absolute,e.mode)}):[];return this[ft](a,e)}let[s]=ia(()=>le.rmdirSync(e.absolute));this[ft](s,e)}let[n]=e.absolute===this.cwd?[]:ia(()=>_L(e.absolute));this[ft](n,e)}[Th](e,r){let i=e.mode&4095||this.fmode,n=a=>{let l;try{le.closeSync(s)}catch(c){l=c}(a||l)&&this[je](a||l,e),r()},s;try{s=le.openSync(e.absolute,Pw(e.size),i)}catch(a){return n(a)}let o=this.transform&&this.transform(e)||e;o!==e&&(o.on("error",a=>this[je](a,e)),e.pipe(o)),o.on("data",a=>{try{le.writeSync(s,a,0,a.length)}catch(l){n(l)}}),o.on("end",a=>{let l=null;if(e.mtime&&!this.noMtime){let c=e.atime||new Date,u=e.mtime;try{le.futimesSync(s,c,u)}catch(f){try{le.utimesSync(e.absolute,c,u)}catch{l=f}}}if(this[Hn](e)){let c=this[Un](e),u=this[Gn](e);try{le.fchownSync(s,c,u)}catch(f){try{le.chownSync(e.absolute,c,u)}catch{l=l||f}}}n(l)})}[kh](e,r){let i=e.mode&4095||this.dmode,n=this[kr](e.absolute,i);if(n){this[je](n,e),r();return}if(e.mtime&&!this.noMtime)try{le.utimesSync(e.absolute,e.atime||new Date,e.mtime)}catch{}if(this[Hn](e))try{le.chownSync(e.absolute,this[Un](e),this[Gn](e))}catch{}r(),e.resume()}[kr](e,r){try{return Cw.sync(nt(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}}[sa](e,r,i,n){try{le[i+"Sync"](r,e.absolute),n(),e.resume()}catch(s){return this[je](s,e)}}};Yn.Sync=Lh;Iw.exports=Yn});var Bw=$((SF,Fw)=>{"use strict";var EL=Pi(),oa=Ph(),Dw=require("fs"),Mw=Vi(),Nw=require("path"),Ih=$i();Fw.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=EL(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&&vL(i,e),i.file&&i.sync?RL(i):i.file?xL(i,r):i.sync?AL(i):OL(i)};var vL=(t,e)=>{let r=new Map(e.map(s=>[Ih(s),!0])),i=t.filter,n=(s,o)=>{let a=o||Nw.parse(s).root||".",l=s===a?!1:r.has(s)?r.get(s):n(Nw.dirname(s),a);return r.set(s,l),l};t.filter=i?(s,o)=>i(s,o)&&n(Ih(s)):s=>n(Ih(s))},RL=t=>{let e=new oa.Sync(t),r=t.file,i=Dw.statSync(r),n=t.maxReadSize||16*1024*1024;new Mw.ReadStreamSync(r,{readSize:n,size:i.size}).pipe(e)},xL=(t,e)=>{let r=new oa(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("close",o),Dw.stat(n,(l,c)=>{if(l)a(l);else{let u=new Mw.ReadStream(n,{readSize:i,size:c.size});u.on("error",a),u.pipe(r)}})});return e?s.then(e,e):s},AL=t=>new oa.Sync(t),OL=t=>new oa(t)});var jw=$(Ae=>{"use strict";Ae.c=Ae.create=w_();Ae.r=Ae.replace=dh();Ae.t=Ae.list=Ko();Ae.u=Ae.update=k_();Ae.x=Ae.extract=Bw();Ae.Pack=Io();Ae.Unpack=Ph();Ae.Parse=Yo();Ae.ReadEntry=go();Ae.WriteEntry=Hu();Ae.Header=ji();Ae.Pax=bo();Ae.types=Ru()});var zw=$((AF,Gw)=>{function pt(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))}Gw.exports=pt;pt.prototype.reset=function(){this._attempts=1,this._timeouts=this._originalTimeouts.slice(0)};pt.prototype.stop=function(){this._timeout&&clearTimeout(this._timeout),this._timer&&clearTimeout(this._timer),this._timeouts=[],this._cachedTimeouts=null};pt.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};pt.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)};pt.prototype.try=function(t){console.log("Using RetryOperation.try() is deprecated"),this.attempt(t)};pt.prototype.start=function(t){console.log("Using RetryOperation.start() is deprecated"),this.attempt(t)};pt.prototype.start=pt.prototype.try;pt.prototype.errors=function(){return this._errors};pt.prototype.attempts=function(){return this._attempts};pt.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 Ww=$(ri=>{var LL=zw();ri.operation=function(t){var e=ri.timeouts(t);return new LL(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(l){var c=ri.operation(e),u=Array.prototype.slice.call(arguments,1),f=u.pop();u.push(function(h){c.retry(h)||(h&&(arguments[0]=c.mainError()),f.apply(this,arguments))}),c.attempt(function(){l.apply(t,u)})}.bind(t,o),t[s].options=e}}});var Kw=$((TF,Yw)=>{Yw.exports=Ww()});var Zw=$((kF,Vw)=>{var PL=Kw();function IL(t,e){function r(i,n){var s=e||{},o;"randomize"in s||(s.randomize=!0),o=PL.operation(s);function a(u){n(u||new Error("Aborted"))}function l(u,f){if(u.bail){a(u);return}o.retry(u)?s.onRetry&&s.onRetry(u,f):n(o.mainError())}function c(u){var f;try{f=t(a,u)}catch(h){l(h,u);return}Promise.resolve(f).then(i).catch(function(p){l(p,u)})}o.attempt(c)}return new Promise(r)}Vw.exports=IL});var QS=require("picocolors");var lE=ie(sf());function xa(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function fn(t){return fn=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},fn(t)}function Aa(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Oa(t,e){if(e&&(fn(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 Nr(t){return Nr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Nr(t)}function $t(t,e){return $t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,n){return i.__proto__=n,i},$t(t,e)}function Ta(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&&$t(t,e)}function ka(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function Ca(){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 Ca()?ai=Reflect.construct.bind():ai=function(n,s,o){var a=[null];a.push.apply(a,s);var l=Function.bind.apply(n,a),c=new l;return o&&$t(c,o.prototype),c},ai.apply(null,arguments)}function pn(t){var e=typeof Map=="function"?new Map:void 0;return pn=function(i){if(i===null||!ka(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,Nr(this).constructor)}return n.prototype=Object.create(i.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),$t(n,i)},pn(t)}var of=ie(require("find-up"));var cE=ie(require("fs-extra")),fN=function(t){Ta(e,t);function e(r){var i;return xa(this,e),i=Oa(this,Nr(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),i.directory=r,i}return e}(pn(Error));var pE=ie(require("json5"));var uE=ie(require("fs")),hE=ie(require("path"));var WO=ie(require("fs")),YO=ie(require("path"));function Ef(t){return typeof t=="undefined"||t===null}function dE(t){return typeof t=="object"&&t!==null}function mE(t){return Array.isArray(t)?t:Ef(t)?[]:[t]}function gE(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 yE(t,e){var r="",i;for(i=0;i<e;i+=1)r+=t;return r}function bE(t){return t===0&&Number.NEGATIVE_INFINITY===1/t}var _E=Ef,wE=dE,SE=mE,EE=yE,vE=bE,RE=gE,xe={isNothing:_E,isObject:wE,toArray:SE,repeat:EE,isNegativeZero:vE,extend:RE};function vf(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(k1,Object.create(null)),k1=(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};Eb.exports=Dn});var $i=$((HM,vb)=>{vb.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 _o=$((UM,Rb)=>{"use strict";Rb.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 Lu=$((zM,xb)=>{"use strict";var wo=["|","<",">","?",":"],Cu=wo.map(t=>String.fromCharCode(61440+t.charCodeAt(0))),C1=new Map(wo.map((t,e)=>[t,Cu[e]])),L1=new Map(Cu.map((t,e)=>[t,wo[e]]));xb.exports={encode:t=>wo.reduce((e,r)=>e.split(r).join(C1.get(r)),t),decode:t=>Cu.reduce((e,r)=>e.split(r).join(L1.get(r)),t)}});var Pu=$((WM,Ob)=>{var{isAbsolute:P1,parse:Ab}=require("path").win32;Ob.exports=t=>{let e="",r=Ab(t);for(;P1(t)||r.root;){let i=t.charAt(0)==="/"&&t.slice(0,4)!=="//?/"?"/":r.root;t=t.slice(i.length),e+=i,r=Ab(t)}return[e,t]}});var kb=$((YM,Tb)=>{"use strict";Tb.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 Hu=$((ZM,Ub)=>{"use strict";var Mb=oo(),Fb=bo(),Bb=ji(),Ct=require("fs"),Cb=require("path"),kt=Fi(),I1=$i(),jb=(t,e)=>e?(t=kt(t).replace(/^\.(\/|$)/,""),I1(e)+"/"+t):kt(t),N1=16*1024*1024,Lb=Symbol("process"),Pb=Symbol("file"),Ib=Symbol("directory"),Nu=Symbol("symlink"),Nb=Symbol("hardlink"),Mn=Symbol("header"),So=Symbol("read"),Du=Symbol("lstat"),Eo=Symbol("onlstat"),Mu=Symbol("onread"),Fu=Symbol("onreadlink"),Bu=Symbol("openfile"),ju=Symbol("onopenfile"),Er=Symbol("close"),vo=Symbol("mode"),$u=Symbol("awaitDrain"),Iu=Symbol("ondrain"),Lt=Symbol("prefix"),Db=Symbol("hadError"),$b=_o(),D1=Lu(),qb=Pu(),Hb=kb(),Ro=$b(class extends Mb{constructor(e,r){if(r=r||{},super(r),typeof e!="string")throw new TypeError("path is required");this.path=kt(e),this.portable=!!r.portable,this.myuid=process.getuid&&process.getuid()||0,this.myuser=process.env.USER||"",this.maxReadSize=r.maxReadSize||N1,this.linkCache=r.linkCache||new Map,this.statCache=r.statCache||new Map,this.preservePaths=!!r.preservePaths,this.cwd=kt(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?kt(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]=qb(this.path);n&&(this.path=s,i=n)}this.win32=!!r.win32||process.platform==="win32",this.win32&&(this.path=D1.decode(this.path.replace(/\\/g,"/")),e=e.replace(/\\/g,"/")),this.absolute=kt(r.absolute||Cb.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[Du]()}emit(e,...r){return e==="error"&&(this[Db]=!0),super.emit(e,...r)}[Du](){Ct.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=F1(e),this.emit("stat",e),this[Lb]()}[Lb](){switch(this.type){case"File":return this[Pb]();case"Directory":return this[Ib]();case"SymbolicLink":return this[Nu]();default:return this.end()}}[vo](e){return Hb(e,this.type==="Directory",this.portable)}[Lt](e){return jb(e,this.prefix)}[Mn](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new Bb({path:this[Lt](this.path),linkpath:this.type==="Link"?this[Lt](this.linkpath):this.linkpath,mode:this[vo](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 Fb({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[Lt](this.path),linkpath:this.type==="Link"?this[Lt](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)}[Ib](){this.path.slice(-1)!=="/"&&(this.path+="/"),this.stat.size=0,this[Mn](),this.end()}[Nu](){Ct.readlink(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[Fu](r)})}[Fu](e){this.linkpath=kt(e),this[Mn](),this.end()}[Nb](e){this.type="Link",this.linkpath=kt(Cb.relative(this.cwd,e)),this.stat.size=0,this[Mn](),this.end()}[Pb](){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[Nb](r)}this.linkCache.set(e,this.absolute)}if(this[Mn](),this.stat.size===0)return this.end();this[Bu]()}[Bu](){Ct.open(this.absolute,"r",(e,r)=>{if(e)return this.emit("error",e);this[ju](r)})}[ju](e){if(this.fd=e,this[Db])return this[Er]();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[So]()}[So](){let{fd:e,buf:r,offset:i,length:n,pos:s}=this;Ct.read(e,r,i,n,s,(o,a)=>{if(o)return this[Er](()=>this.emit("error",o));this[Mu](a)})}[Er](e){Ct.close(this.fd,e)}[Mu](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[Er](()=>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[Er](()=>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[Iu]():this[$u](()=>this[Iu]())}[$u](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)}[Iu](){if(!this.remain)return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),this[Er](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[So]()}}),qu=class extends Ro{[Du](){this[Eo](Ct.lstatSync(this.absolute))}[Nu](){this[Fu](Ct.readlinkSync(this.absolute))}[Bu](){this[ju](Ct.openSync(this.absolute,"r"))}[So](){let e=!0;try{let{fd:r,buf:i,offset:n,length:s,pos:o}=this,a=Ct.readSync(r,i,n,s,o);this[Mu](a),e=!1}finally{if(e)try{this[Er](()=>{})}catch{}}}[$u](e){e()}[Er](e){Ct.closeSync(this.fd),e()}},M1=$b(class extends Mb{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=kt(e.path),this.mode=this[vo](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=kt(e.linkpath),typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(!this.preservePaths){let[n,s]=qb(this.path);n&&(this.path=s,i=n)}this.remain=e.size,this.blockRemain=e.startBlockSize,this.header=new Bb({path:this[Lt](this.path),linkpath:this.type==="Link"?this[Lt](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 Fb({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[Lt](this.path),linkpath:this.type==="Link"?this[Lt](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)}[Lt](e){return jb(e,this.prefix)}[vo](e){return Hb(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()}});Ro.Sync=qu;Ro.Tar=M1;var F1=t=>t.isFile()?"File":t.isDirectory()?"Directory":t.isSymbolicLink()?"SymbolicLink":"Unsupported";Ub.exports=Ro});var zb=$((XM,Gb)=>{"use strict";Gb.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var Uu=$((JM,Wb)=>{"use strict";Wb.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++)j1(this,arguments[t]);return this.length};ae.prototype.unshift=function(){for(var t=0,e=arguments.length;t<e;t++)$1(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=B1(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 B1(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 j1(t,e){t.tail=new Vr(e,t.tail,null,t),t.head||(t.head=t.tail),t.length++}function $1(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{zb()(ae)}catch{}});var Io=$((eF,Qb)=>{"use strict";var Lo=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}},q1=oo(),H1=Su(),U1=go(),Ju=Hu(),G1=Ju.Sync,z1=Ju.Tar,W1=Uu(),Yb=Buffer.alloc(1024),Oo=Symbol("onStat"),xo=Symbol("ended"),Pt=Symbol("queue"),qi=Symbol("current"),Kr=Symbol("process"),Ao=Symbol("processing"),Vb=Symbol("processJob"),It=Symbol("jobs"),Gu=Symbol("jobDone"),To=Symbol("addFSEntry"),Kb=Symbol("addTarEntry"),Vu=Symbol("stat"),Ku=Symbol("readdir"),ko=Symbol("onreaddir"),Co=Symbol("pipe"),Zb=Symbol("entry"),zu=Symbol("entryOpt"),Zu=Symbol("writeEntryClass"),Jb=Symbol("write"),Wu=Symbol("ondrain"),Po=require("fs"),Xb=require("path"),Y1=_o(),Yu=Fi(),Qu=Y1(class extends q1{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=Yu(e.prefix||""),this.linkCache=e.linkCache||new Map,this.statCache=e.statCache||new Map,this.readdirCache=e.readdirCache||new Map,this[Zu]=Ju,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 H1.Gzip(e.gzip),this.zip.on("data",r=>super.write(r)),this.zip.on("end",r=>super.end()),this.zip.on("drain",r=>this[Wu]()),this.on("resume",r=>this.zip.resume())):this.on("drain",this[Wu]),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[Pt]=new W1,this[It]=0,this.jobs=+e.jobs||4,this[Ao]=!1,this[xo]=!1}[Jb](e){return super.write(e)}add(e){return this.write(e),this}end(e){return e&&this.write(e),this[xo]=!0,this[Kr](),this}write(e){if(this[xo])throw new Error("write after end");return e instanceof U1?this[Kb](e):this[To](e),this.flowing}[Kb](e){let r=Yu(Xb.resolve(this.cwd,e.path));if(!this.filter(e.path,e))e.resume();else{let i=new Lo(e.path,r,!1);i.entry=new z1(e,this[zu](i)),i.entry.on("end",n=>this[Gu](i)),this[It]+=1,this[Pt].push(i)}this[Kr]()}[To](e){let r=Yu(Xb.resolve(this.cwd,e));this[Pt].push(new Lo(e,r)),this[Kr]()}[Vu](e){e.pending=!0,this[It]+=1;let r=this.follow?"stat":"lstat";Po[r](e.absolute,(i,n)=>{e.pending=!1,this[It]-=1,i?this.emit("error",i):this[Oo](e,n)})}[Oo](e,r){this.statCache.set(e.absolute,r),e.stat=r,this.filter(e.path,r)||(e.ignore=!0),this[Kr]()}[Ku](e){e.pending=!0,this[It]+=1,Po.readdir(e.absolute,(r,i)=>{if(e.pending=!1,this[It]-=1,r)return this.emit("error",r);this[ko](e,i)})}[ko](e,r){this.readdirCache.set(e.absolute,r),e.readdir=r,this[Kr]()}[Kr](){if(!this[Ao]){this[Ao]=!0;for(let e=this[Pt].head;e!==null&&this[It]<this.jobs;e=e.next)if(this[Vb](e.value),e.value.ignore){let r=e.next;this[Pt].removeNode(e),e.next=r}this[Ao]=!1,this[xo]&&!this[Pt].length&&this[It]===0&&(this.zip?this.zip.end(Yb):(super.write(Yb),super.end()))}}get[qi](){return this[Pt]&&this[Pt].head&&this[Pt].head.value}[Gu](e){this[Pt].shift(),this[It]-=1,this[Kr]()}[Vb](e){if(!e.pending){if(e.entry){e===this[qi]&&!e.piped&&this[Co](e);return}if(e.stat||(this.statCache.has(e.absolute)?this[Oo](e,this.statCache.get(e.absolute)):this[Vu](e)),!!e.stat&&!e.ignore&&!(!this.noDirRecurse&&e.stat.isDirectory()&&!e.readdir&&(this.readdirCache.has(e.absolute)?this[ko](e,this.readdirCache.get(e.absolute)):this[Ku](e),!e.readdir))){if(e.entry=this[Zb](e),!e.entry){e.ignore=!0;return}e===this[qi]&&!e.piped&&this[Co](e)}}}[zu](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}}[Zb](e){this[It]+=1;try{return new this[Zu](e.path,this[zu](e)).on("end",()=>this[Gu](e)).on("error",r=>this.emit("error",r))}catch(r){this.emit("error",r)}}[Wu](){this[qi]&&this[qi].entry&&this[qi].entry.resume()}[Co](e){e.piped=!0,e.readdir&&e.readdir.forEach(n=>{let s=e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[To](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()}}),Xu=class extends Qu{constructor(e){super(e),this[Zu]=G1}pause(){}resume(){}[Vu](e){let r=this.follow?"statSync":"lstatSync";this[Oo](e,Po[r](e.absolute))}[Ku](e,r){this[ko](e,Po.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[To](o+n)}),i?r.on("data",n=>{i.write(n)}):r.on("data",n=>{super[Jb](n)})}};Qu.Sync=Xu;Qb.exports=Qu});var Ki=$(Bn=>{"use strict";var V1=su(),K1=require("events").EventEmitter,Ke=require("fs"),rh=Ke.writev;if(!rh){let t=process.binding("fs"),e=t.FSReqWrap||t.FSReqCallback;rh=(r,i,n,s)=>{let o=(l,c)=>s(l,c,i),a=new e;a.oncomplete=o,t.writeBuffers(r,i,n,a)}}var Yi=Symbol("_autoClose"),gt=Symbol("_close"),Fn=Symbol("_ended"),fe=Symbol("_fd"),e_=Symbol("_finished"),Rr=Symbol("_flags"),eh=Symbol("_flush"),ih=Symbol("_handleChunk"),nh=Symbol("_makeBuf"),Bo=Symbol("_mode"),No=Symbol("_needDrain"),zi=Symbol("_onerror"),Vi=Symbol("_onopen"),th=Symbol("_onread"),Ui=Symbol("_onwrite"),xr=Symbol("_open"),er=Symbol("_path"),Zr=Symbol("_pos"),Nt=Symbol("_queue"),Gi=Symbol("_read"),t_=Symbol("_readSize"),vr=Symbol("_reading"),Do=Symbol("_remain"),r_=Symbol("_size"),Mo=Symbol("_write"),Hi=Symbol("_writing"),Fo=Symbol("_defaultFlag"),Wi=Symbol("_errored"),jo=class extends V1{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[er]=e,this[t_]=r.readSize||16*1024*1024,this[vr]=!1,this[r_]=typeof r.size=="number"?r.size:1/0,this[Do]=this[r_],this[Yi]=typeof r.autoClose=="boolean"?r.autoClose:!0,typeof this[fe]=="number"?this[Gi]():this[xr]()}get fd(){return this[fe]}get path(){return this[er]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[xr](){Ke.open(this[er],"r",(e,r)=>this[Vi](e,r))}[Vi](e,r){e?this[zi](e):(this[fe]=r,this.emit("open",r),this[Gi]())}[nh](){return Buffer.allocUnsafe(Math.min(this[t_],this[Do]))}[Gi](){if(!this[vr]){this[vr]=!0;let e=this[nh]();if(e.length===0)return process.nextTick(()=>this[th](null,0,e));Ke.read(this[fe],e,0,e.length,null,(r,i,n)=>this[th](r,i,n))}}[th](e,r,i){this[vr]=!1,e?this[zi](e):this[ih](r,i)&&this[Gi]()}[gt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ke.close(e,r=>r?this.emit("error",r):this.emit("close"))}}[zi](e){this[vr]=!0,this[gt](),this.emit("error",e)}[ih](e,r){let i=!1;return this[Do]-=e,e>0&&(i=super.write(e<r.length?r.slice(0,e):r)),(e===0||this[Do]<=0)&&(i=!1,this[gt](),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)}}},sh=class extends jo{[xr](){let e=!0;try{this[Vi](null,Ke.openSync(this[er],"r")),e=!1}finally{e&&this[gt]()}}[Gi](){let e=!0;try{if(!this[vr]){this[vr]=!0;do{let r=this[nh](),i=r.length===0?0:Ke.readSync(this[fe],r,0,r.length,null);if(!this[ih](i,r))break}while(!0);this[vr]=!1}e=!1}finally{e&&this[gt]()}}[gt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ke.closeSync(e),this.emit("close")}}},$o=class extends K1{constructor(e,r){r=r||{},super(r),this.readable=!1,this.writable=!0,this[Wi]=!1,this[Hi]=!1,this[Fn]=!1,this[No]=!1,this[Nt]=[],this[er]=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[Fo]=r.flags===void 0,this[Rr]=this[Fo]?i:r.flags,this[fe]===null&&this[xr]()}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[er]}[zi](e){this[gt](),this[Hi]=!0,this.emit("error",e)}[xr](){Ke.open(this[er],this[Rr],this[Bo],(e,r)=>this[Vi](e,r))}[Vi](e,r){this[Fo]&&this[Rr]==="r+"&&e&&e.code==="ENOENT"?(this[Rr]="w",this[xr]()):e?this[zi](e):(this[fe]=r,this.emit("open",r),this[eh]())}end(e,r){return e&&this.write(e,r),this[Fn]=!0,!this[Hi]&&!this[Nt].length&&typeof this[fe]=="number"&&this[Ui](null,0),this}write(e,r){return typeof e=="string"&&(e=Buffer.from(e,r)),this[Fn]?(this.emit("error",new Error("write() after end()")),!1):this[fe]===null||this[Hi]||this[Nt].length?(this[Nt].push(e),this[No]=!0,!1):(this[Hi]=!0,this[Mo](e),!0)}[Mo](e){Ke.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[Nt].length?this[eh]():(this[Hi]=!1,this[Fn]&&!this[e_]?(this[e_]=!0,this[gt](),this.emit("finish")):this[No]&&(this[No]=!1,this.emit("drain"))))}[eh](){if(this[Nt].length===0)this[Fn]&&this[Ui](null,0);else if(this[Nt].length===1)this[Mo](this[Nt].pop());else{let e=this[Nt];this[Nt]=[],rh(this[fe],e,this[Zr],(r,i)=>this[Ui](r,i))}}[gt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ke.close(e,r=>r?this.emit("error",r):this.emit("close"))}}},oh=class extends $o{[xr](){let e;if(this[Fo]&&this[Rr]==="r+")try{e=Ke.openSync(this[er],this[Rr],this[Bo])}catch(r){if(r.code==="ENOENT")return this[Rr]="w",this[xr]();throw r}else e=Ke.openSync(this[er],this[Rr],this[Bo]);this[Vi](null,e)}[gt](){if(this[Yi]&&typeof this[fe]=="number"){let e=this[fe];this[fe]=null,Ke.closeSync(e),this.emit("close")}}[Mo](e){let r=!0;try{this[Ui](null,Ke.writeSync(this[fe],e,0,e.length,this[Zr])),r=!1}finally{if(r)try{this[gt]()}catch{}}}};Bn.ReadStream=jo;Bn.ReadStreamSync=sh;Bn.WriteStream=$o;Bn.WriteStreamSync=oh});var Yo=$((iF,u_)=>{"use strict";var Z1=_o(),X1=ji(),J1=require("events"),Q1=Uu(),eC=1024*1024,tC=go(),i_=bo(),rC=Su(),{nextTick:iC}=require("process"),ah=Buffer.from([31,139]),lt=Symbol("state"),Xr=Symbol("writeEntry"),tr=Symbol("readEntry"),lh=Symbol("nextEntry"),n_=Symbol("processEntry"),ct=Symbol("extendedHeader"),jn=Symbol("globalExtendedHeader"),Ar=Symbol("meta"),s_=Symbol("emitMeta"),me=Symbol("buffer"),rr=Symbol("queue"),Jr=Symbol("ended"),o_=Symbol("emittedEnd"),Qr=Symbol("emit"),Ze=Symbol("unzip"),qo=Symbol("consumeChunk"),Ho=Symbol("consumeChunkSub"),ch=Symbol("consumeBody"),a_=Symbol("consumeMeta"),l_=Symbol("consumeHeader"),Uo=Symbol("consuming"),uh=Symbol("bufferConcat"),hh=Symbol("maybeEnd"),$n=Symbol("writing"),Or=Symbol("aborted"),Go=Symbol("onDone"),ei=Symbol("sawValidEntry"),zo=Symbol("sawNullBlock"),Wo=Symbol("sawEOF"),c_=Symbol("closeStream"),nC=t=>!0;u_.exports=Z1(class extends J1{constructor(e){e=e||{},super(e),this.file=e.file||"",this[ei]=null,this.on(Go,r=>{(this[lt]==="begin"||this[ei]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),e.ondone?this.on(Go,e.ondone):this.on(Go,r=>{this.emit("prefinish"),this.emit("finish"),this.emit("end")}),this.strict=!!e.strict,this.maxMetaEntrySize=e.maxMetaEntrySize||eC,this.filter=typeof e.filter=="function"?e.filter:nC,this.writable=!0,this.readable=!1,this[rr]=new Q1,this[me]=null,this[tr]=null,this[Xr]=null,this[lt]="begin",this[Ar]="",this[ct]=null,this[jn]=null,this[Jr]=!1,this[Ze]=null,this[Or]=!1,this[zo]=!1,this[Wo]=!1,this.on("end",()=>this[c_]()),typeof e.onwarn=="function"&&this.on("warn",e.onwarn),typeof e.onentry=="function"&&this.on("entry",e.onentry)}[l_](e,r){this[ei]===null&&(this[ei]=!1);let i;try{i=new X1(e,r,this[ct],this[jn])}catch(n){return this.warn("TAR_ENTRY_INVALID",n)}if(i.nullBlock)this[zo]?(this[Wo]=!0,this[lt]==="begin"&&(this[lt]="header"),this[Qr]("eof")):(this[zo]=!0,this[Qr]("nullBlock"));else if(this[zo]=!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[Xr]=new tC(i,this[ct],this[jn]);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[lt]="ignore",s.resume()):s.size>0&&(this[Ar]="",s.on("data",o=>this[Ar]+=o),this[lt]="meta"):(this[ct]=null,s.ignore=s.ignore||!this.filter(s.path,s),s.ignore?(this[Qr]("ignoredEntry",s),this[lt]=s.remain?"ignore":"header",s.resume()):(s.remain?this[lt]="body":(this[lt]="header",s.end()),this[tr]?this[rr].push(s):(this[rr].push(s),this[lh]())))}}}[c_](){iC(()=>this.emit("close"))}[n_](e){let r=!0;return e?Array.isArray(e)?this.emit.apply(this,e):(this[tr]=e,this.emit("entry",e),e.emittedEnd||(e.on("end",i=>this[lh]()),r=!1)):(this[tr]=null,r=!1),r}[lh](){do;while(this[n_](this[rr].shift()));if(!this[rr].length){let e=this[tr];!e||e.flowing||e.size===e.remain?this[$n]||this.emit("drain"):e.once("drain",i=>this.emit("drain"))}}[ch](e,r){let i=this[Xr],n=i.blockRemain,s=n>=e.length&&r===0?e:e.slice(r,r+n);return i.write(s),i.blockRemain||(this[lt]="header",this[Xr]=null,i.end()),s.length}[a_](e,r){let i=this[Xr],n=this[ch](e,r);return this[Xr]||this[s_](i),n}[Qr](e,r,i){!this[rr].length&&!this[tr]?this.emit(e,r,i):this[rr].push([e,r,i])}[s_](e){switch(this[Qr]("meta",this[Ar]),e.type){case"ExtendedHeader":case"OldExtendedHeader":this[ct]=i_.parse(this[Ar],this[ct],!1);break;case"GlobalExtendedHeader":this[jn]=i_.parse(this[Ar],this[jn],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[ct]=this[ct]||Object.create(null),this[ct].path=this[Ar].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[ct]=this[ct]||Object.create(null),this[ct].linkpath=this[Ar].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+e.type)}}abort(e){this[Or]=!0,this.emit("abort",e),this.warn("TAR_ABORT",e,{recoverable:!1})}write(e){if(this[Or])return;if(this[Ze]===null&&e){if(this[me]&&(e=Buffer.concat([this[me],e]),this[me]=null),e.length<ah.length)return this[me]=e,!0;for(let i=0;this[Ze]===null&&i<ah.length;i++)e[i]!==ah[i]&&(this[Ze]=!1);if(this[Ze]===null){let i=this[Jr];this[Jr]=!1,this[Ze]=new rC.Unzip,this[Ze].on("data",s=>this[qo](s)),this[Ze].on("error",s=>this.abort(s)),this[Ze].on("end",s=>{this[Jr]=!0,this[qo]()}),this[$n]=!0;let n=this[Ze][i?"end":"write"](e);return this[$n]=!1,n}}this[$n]=!0,this[Ze]?this[Ze].write(e):this[qo](e),this[$n]=!1;let r=this[rr].length?!1:this[tr]?this[tr].flowing:!0;return!r&&!this[rr].length&&this[tr].once("drain",i=>this.emit("drain")),r}[uh](e){e&&!this[Or]&&(this[me]=this[me]?Buffer.concat([this[me],e]):e)}[hh](){if(this[Jr]&&!this[o_]&&!this[Or]&&!this[Uo]){this[o_]=!0;let e=this[Xr];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](Go)}}[qo](e){if(this[Uo])this[uh](e);else if(!e&&!this[me])this[hh]();else{if(this[Uo]=!0,this[me]){this[uh](e);let r=this[me];this[me]=null,this[Ho](r)}else this[Ho](e);for(;this[me]&&this[me].length>=512&&!this[Or]&&!this[Wo];){let r=this[me];this[me]=null,this[Ho](r)}this[Uo]=!1}(!this[me]||this[Jr])&&this[hh]()}[Ho](e){let r=0,i=e.length;for(;r+512<=i&&!this[Or]&&!this[Wo];)switch(this[lt]){case"begin":case"header":this[l_](e,r),r+=512;break;case"ignore":case"body":r+=this[ch](e,r);break;case"meta":r+=this[a_](e,r);break;default:throw new Error("invalid state: "+this[lt])}r<i&&(this[me]?this[me]=Buffer.concat([e.slice(r),this[me]]):this[me]=e.slice(r))}end(e){this[Or]||(this[Ze]?this[Ze].end(e):(this[Jr]=!0,this.write(e)))}})});var Vo=$((nF,d_)=>{"use strict";var sC=Pi(),f_=Yo(),Zi=require("fs"),oC=Ki(),h_=require("path"),fh=$i();d_.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=sC(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&&lC(i,e),i.noResume||aC(i),i.file&&i.sync?cC(i):i.file?uC(i,r):p_(i)};var aC=t=>{let e=t.onentry;t.onentry=e?r=>{e(r),r.resume()}:r=>r.resume()},lC=(t,e)=>{let r=new Map(e.map(s=>[fh(s),!0])),i=t.filter,n=(s,o)=>{let a=o||h_.parse(s).root||".",l=s===a?!1:r.has(s)?r.get(s):n(h_.dirname(s),a);return r.set(s,l),l};t.filter=i?(s,o)=>i(s,o)&&n(fh(s)):s=>n(fh(s))},cC=t=>{let e=p_(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,l=Buffer.allocUnsafe(o);for(n=Zi.openSync(r,"r");a<s.size;){let c=Zi.readSync(n,l,0,o,a);a+=c,e.write(l.slice(0,c))}e.end()}i=!1}finally{if(i&&n)try{Zi.closeSync(n)}catch{}}},uC=(t,e)=>{let r=new f_(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,(l,c)=>{if(l)a(l);else{let u=new oC.ReadStream(n,{readSize:i,size:c.size});u.on("error",a),u.pipe(r)}})});return e?s.then(e,e):s},p_=t=>new f_(t)});var w_=$((sF,__)=>{"use strict";var hC=Pi(),Ko=Io(),m_=Ki(),g_=Vo(),y_=require("path");__.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=hC(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?fC(i,e):i.file?pC(i,e,r):i.sync?dC(i,e):mC(i,e)};var fC=(t,e)=>{let r=new Ko.Sync(t),i=new m_.WriteStreamSync(t.file,{mode:t.mode||438});r.pipe(i),b_(r,e)},pC=(t,e,r)=>{let i=new Ko(t),n=new m_.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 ph(i,e),r?s.then(r,r):s},b_=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?g_({file:y_.resolve(t.cwd,r.slice(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},ph=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return g_({file:y_.resolve(t.cwd,r.slice(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>ph(t,e));t.add(r)}t.end()},dC=(t,e)=>{let r=new Ko.Sync(t);return b_(r,e),r},mC=(t,e)=>{let r=new Ko(t);return ph(r,e),r}});var dh=$((oF,O_)=>{"use strict";var gC=Pi(),S_=Io(),it=require("fs"),E_=Ki(),v_=Vo(),R_=require("path"),x_=ji();O_.exports=(t,e,r)=>{let i=gC(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?yC(i,e):_C(i,e,r)};var yC=(t,e)=>{let r=new S_.Sync(t),i=!0,n,s;try{try{n=it.openSync(t.file,"r+")}catch(l){if(l.code==="ENOENT")n=it.openSync(t.file,"w+");else throw l}let o=it.fstatSync(n),a=Buffer.alloc(512);e:for(s=0;s<o.size;s+=512){for(let u=0,f=0;u<512;u+=f){if(f=it.readSync(n,a,u,a.length-u,s+u),s===0&&a[0]===31&&a[1]===139)throw new Error("cannot append to compressed archives");if(!f)break e}let l=new x_(a);if(!l.cksumValid)break;let c=512*Math.ceil(l.size/512);if(s+c+512>o.size)break;s+=c,t.mtimeCache&&t.mtimeCache.set(l.path,l.mtime)}i=!1,bC(t,r,s,n,e)}finally{if(i)try{it.closeSync(n)}catch{}}},bC=(t,e,r,i,n)=>{let s=new E_.WriteStreamSync(t.file,{fd:i,start:r});e.pipe(s),wC(e,n)},_C=(t,e,r)=>{e=Array.from(e);let i=new S_(t),n=(o,a,l)=>{let c=(g,y)=>{g?it.close(o,b=>l(g)):l(null,y)},u=0;if(a===0)return c(null,0);let f=0,h=Buffer.alloc(512),p=(g,y)=>{if(g)return c(g);if(f+=y,f<512&&y)return it.read(o,h,f,h.length-f,u+f,p);if(u===0&&h[0]===31&&h[1]===139)return c(new Error("cannot append to compressed archives"));if(f<512)return c(null,u);let b=new x_(h);if(!b.cksumValid)return c(null,u);let x=512*Math.ceil(b.size/512);if(u+x+512>a||(u+=x+512,u>=a))return c(null,u);t.mtimeCache&&t.mtimeCache.set(b.path,b.mtime),f=0,it.read(o,h,0,512,u,p)};it.read(o,h,0,512,u,p)},s=new Promise((o,a)=>{i.on("error",a);let l="r+",c=(u,f)=>{if(u&&u.code==="ENOENT"&&l==="r+")return l="w+",it.open(t.file,l,c);if(u)return a(u);it.fstat(f,(h,p)=>{if(h)return it.close(f,()=>a(h));n(f,p.size,(g,y)=>{if(g)return a(g);let b=new E_.WriteStream(t.file,{fd:f,start:y});i.pipe(b),b.on("error",a),b.on("close",o),A_(i,e)})})};it.open(t.file,l,c)});return r?s.then(r,r):s},wC=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?v_({file:R_.resolve(t.cwd,r.slice(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},A_=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return v_({file:R_.resolve(t.cwd,r.slice(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>A_(t,e));t.add(r)}t.end()}});var k_=$((aF,T_)=>{"use strict";var SC=Pi(),EC=dh();T_.exports=(t,e,r)=>{let i=SC(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),vC(i),EC(i,e,r)};var vC=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 P_=$((lF,L_)=>{var{promisify:C_}=require("util"),Tr=require("fs"),RC=t=>{if(!t)t={mode:511,fs:Tr};else if(typeof t=="object")t={mode:511,fs:Tr,...t};else if(typeof t=="number")t={mode:t,fs:Tr};else if(typeof t=="string")t={mode:parseInt(t,8),fs:Tr};else throw new TypeError("invalid options argument");return t.mkdir=t.mkdir||t.fs.mkdir||Tr.mkdir,t.mkdirAsync=C_(t.mkdir),t.stat=t.stat||t.fs.stat||Tr.stat,t.statAsync=C_(t.stat),t.statSync=t.statSync||t.fs.statSync||Tr.statSync,t.mkdirSync=t.mkdirSync||t.fs.mkdirSync||Tr.mkdirSync,t};L_.exports=RC});var N_=$((cF,I_)=>{var xC=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:AC,parse:OC}=require("path"),TC=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=AC(t),xC==="win32"){let e=/[*|"<>?:]/,{root:r}=OC(t);if(e.test(t.substr(r.length)))throw Object.assign(new Error("Illegal characters in path."),{path:t,code:"EINVAL"})}return t};I_.exports=TC});var j_=$((uF,B_)=>{var{dirname:D_}=require("path"),M_=(t,e,r=void 0)=>r===e?Promise.resolve():t.statAsync(e).then(i=>i.isDirectory()?r:void 0,i=>i.code==="ENOENT"?M_(t,D_(e),e):void 0),F_=(t,e,r=void 0)=>{if(r!==e)try{return t.statSync(e).isDirectory()?r:void 0}catch(i){return i.code==="ENOENT"?F_(t,D_(e),e):void 0}};B_.exports={findMade:M_,findMadeSync:F_}});var yh=$((hF,q_)=>{var{dirname:$_}=require("path"),mh=(t,e,r)=>{e.recursive=!1;let i=$_(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 mh(i,e).then(s=>mh(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})})},gh=(t,e,r)=>{let i=$_(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 gh(t,e,gh(i,e,r));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;try{if(!e.statSync(t).isDirectory())throw n}catch{throw n}}};q_.exports={mkdirpManual:mh,mkdirpManualSync:gh}});var G_=$((fF,U_)=>{var{dirname:H_}=require("path"),{findMade:kC,findMadeSync:CC}=j_(),{mkdirpManual:LC,mkdirpManualSync:PC}=yh(),IC=(t,e)=>(e.recursive=!0,H_(t)===t?e.mkdirAsync(t,e):kC(e,t).then(i=>e.mkdirAsync(t,e).then(()=>i).catch(n=>{if(n.code==="ENOENT")return LC(t,e);throw n}))),NC=(t,e)=>{if(e.recursive=!0,H_(t)===t)return e.mkdirSync(t,e);let i=CC(e,t);try{return e.mkdirSync(t,e),i}catch(n){if(n.code==="ENOENT")return PC(t,e);throw n}};U_.exports={mkdirpNative:IC,mkdirpNativeSync:NC}});var V_=$((pF,Y_)=>{var z_=require("fs"),DC=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version,bh=DC.replace(/^v/,"").split("."),W_=+bh[0]>10||+bh[0]==10&&+bh[1]>=12,MC=W_?t=>t.mkdir===z_.mkdir:()=>!1,FC=W_?t=>t.mkdirSync===z_.mkdirSync:()=>!1;Y_.exports={useNative:MC,useNativeSync:FC}});var ew=$((dF,Q_)=>{var Xi=P_(),Ji=N_(),{mkdirpNative:K_,mkdirpNativeSync:Z_}=G_(),{mkdirpManual:X_,mkdirpManualSync:J_}=yh(),{useNative:BC,useNativeSync:jC}=V_(),Qi=(t,e)=>(t=Ji(t),e=Xi(e),BC(e)?K_(t,e):X_(t,e)),$C=(t,e)=>(t=Ji(t),e=Xi(e),jC(e)?Z_(t,e):J_(t,e));Qi.sync=$C;Qi.native=(t,e)=>K_(Ji(t),Xi(e));Qi.manual=(t,e)=>X_(Ji(t),Xi(e));Qi.nativeSync=(t,e)=>Z_(Ji(t),Xi(e));Qi.manualSync=(t,e)=>J_(Ji(t),Xi(e));Q_.exports=Qi});var aw=$((mF,ow)=>{"use strict";var ut=require("fs"),ti=require("path"),qC=ut.lchown?"lchown":"chown",HC=ut.lchownSync?"lchownSync":"chownSync",rw=ut.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),tw=(t,e,r)=>{try{return ut[HC](t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},UC=(t,e,r)=>{try{return ut.chownSync(t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},GC=rw?(t,e,r,i)=>n=>{!n||n.code!=="EISDIR"?i(n):ut.chown(t,e,r,i)}:(t,e,r,i)=>i,_h=rw?(t,e,r)=>{try{return tw(t,e,r)}catch(i){if(i.code!=="EISDIR")throw i;UC(t,e,r)}}:(t,e,r)=>tw(t,e,r),zC=process.version,iw=(t,e,r)=>ut.readdir(t,e,r),WC=(t,e)=>ut.readdirSync(t,e);/^v4\./.test(zC)&&(iw=(t,e,r)=>ut.readdir(t,r));var Zo=(t,e,r,i)=>{ut[qC](t,e,r,GC(t,e,r,n=>{i(n&&n.code!=="ENOENT"?n:null)}))},nw=(t,e,r,i,n)=>{if(typeof e=="string")return ut.lstat(ti.resolve(t,e),(s,o)=>{if(s)return n(s.code!=="ENOENT"?s:null);o.name=e,nw(t,o,r,i,n)});if(e.isDirectory())wh(ti.resolve(t,e.name),r,i,s=>{if(s)return n(s);let o=ti.resolve(t,e.name);Zo(o,r,i,n)});else{let s=ti.resolve(t,e.name);Zo(s,r,i,n)}},wh=(t,e,r,i)=>{iw(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 Zo(t,e,r,i);let o=s.length,a=null,l=c=>{if(!a){if(c)return i(a=c);if(--o===0)return Zo(t,e,r,i)}};s.forEach(c=>nw(t,c,e,r,l))})},YC=(t,e,r,i)=>{if(typeof e=="string")try{let n=ut.lstatSync(ti.resolve(t,e));n.name=e,e=n}catch(n){if(n.code==="ENOENT")return;throw n}e.isDirectory()&&sw(ti.resolve(t,e.name),r,i),_h(ti.resolve(t,e.name),r,i)},sw=(t,e,r)=>{let i;try{i=WC(t,{withFileTypes:!0})}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR"||n.code==="ENOTSUP")return _h(t,e,r);throw n}return i&&i.length&&i.forEach(n=>YC(t,n,e,r)),_h(t,e,r)};ow.exports=wh;wh.sync=sw});var hw=$((gF,Sh)=>{"use strict";var lw=ew(),ht=require("fs"),Xo=require("path"),cw=aw(),yt=Fi(),Jo=class extends Error{constructor(e,r){super("Cannot extract through symbolic link"),this.path=r,this.symlink=e}get name(){return"SylinkError"}},Qo=class extends Error{constructor(e,r){super(r+": Cannot cd into '"+e+"'"),this.path=e,this.code=r}get name(){return"CwdError"}},ea=(t,e)=>t.get(yt(e)),qn=(t,e,r)=>t.set(yt(e),r),VC=(t,e)=>{ht.stat(t,(r,i)=>{(r||!i.isDirectory())&&(r=new Qo(t,r&&r.code||"ENOTDIR")),e(r)})};Sh.exports=(t,e,r)=>{t=yt(t);let i=e.umask,n=e.mode|448,s=(n&i)!==0,o=e.uid,a=e.gid,l=typeof o=="number"&&typeof a=="number"&&(o!==e.processUid||a!==e.processGid),c=e.preserve,u=e.unlink,f=e.cache,h=yt(e.cwd),p=(b,x)=>{b?r(b):(qn(f,t,!0),x&&l?cw(x,o,a,k=>p(k)):s?ht.chmod(t,n,r):r())};if(f&&ea(f,t)===!0)return p();if(t===h)return VC(t,p);if(c)return lw(t,{mode:n}).then(b=>p(null,b),p);let y=yt(Xo.relative(h,t)).split("/");ta(h,y,n,f,u,h,null,p)};var ta=(t,e,r,i,n,s,o,a)=>{if(!e.length)return a(null,o);let l=e.shift(),c=yt(Xo.resolve(t+"/"+l));if(ea(i,c))return ta(c,e,r,i,n,s,o,a);ht.mkdir(c,r,uw(c,e,r,i,n,s,o,a))},uw=(t,e,r,i,n,s,o,a)=>l=>{l?ht.lstat(t,(c,u)=>{if(c)c.path=c.path&&yt(c.path),a(c);else if(u.isDirectory())ta(t,e,r,i,n,s,o,a);else if(n)ht.unlink(t,f=>{if(f)return a(f);ht.mkdir(t,r,uw(t,e,r,i,n,s,o,a))});else{if(u.isSymbolicLink())return a(new Jo(t,t+"/"+e.join("/")));a(l)}}):(o=o||t,ta(t,e,r,i,n,s,o,a))},KC=t=>{let e=!1,r="ENOTDIR";try{e=ht.statSync(t).isDirectory()}catch(i){r=i.code}finally{if(!e)throw new Qo(t,r)}};Sh.exports.sync=(t,e)=>{t=yt(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),l=e.preserve,c=e.unlink,u=e.cache,f=yt(e.cwd),h=b=>{qn(u,t,!0),b&&a&&cw.sync(b,s,o),n&&ht.chmodSync(t,i)};if(u&&ea(u,t)===!0)return h();if(t===f)return KC(f),h();if(l)return h(lw.sync(t,i));let g=yt(Xo.relative(f,t)).split("/"),y=null;for(let b=g.shift(),x=f;b&&(x+="/"+b);b=g.shift())if(x=yt(Xo.resolve(x)),!ea(u,x))try{ht.mkdirSync(x,i),y=y||x,qn(u,x,!0)}catch{let C=ht.lstatSync(x);if(C.isDirectory()){qn(u,x,!0);continue}else if(c){ht.unlinkSync(x),ht.mkdirSync(x,i),y=y||x,qn(u,x,!0);continue}else if(C.isSymbolicLink())return new Jo(x,x+"/"+g.join("/"))}return h(y)}});var vh=$((yF,fw)=>{var Eh=Object.create(null),{hasOwnProperty:ZC}=Object.prototype;fw.exports=t=>(ZC.call(Eh,t)||(Eh[t]=t.normalize("NFKD")),Eh[t])});var gw=$((bF,mw)=>{var pw=require("assert"),XC=vh(),JC=$i(),{join:dw}=require("path"),QC=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,eL=QC==="win32";mw.exports=()=>{let t=new Map,e=new Map,r=c=>c.split("/").slice(0,-1).reduce((f,h)=>(f.length&&(h=dw(f[f.length-1],h)),f.push(h||"/"),f),[]),i=new Set,n=c=>{let u=e.get(c);if(!u)throw new Error("function does not have any path reservations");return{paths:u.paths.map(f=>t.get(f)),dirs:[...u.dirs].map(f=>t.get(f))}},s=c=>{let{paths:u,dirs:f}=n(c);return u.every(h=>h[0]===c)&&f.every(h=>h[0]instanceof Set&&h[0].has(c))},o=c=>i.has(c)||!s(c)?!1:(i.add(c),c(()=>a(c)),!0),a=c=>{if(!i.has(c))return!1;let{paths:u,dirs:f}=e.get(c),h=new Set;return u.forEach(p=>{let g=t.get(p);pw.equal(g[0],c),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);pw(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(c)}),i.delete(c),h.forEach(p=>o(p)),!0};return{check:s,reserve:(c,u)=>{c=eL?["win32 parallelization disabled"]:c.map(h=>XC(JC(dw(h))).toLowerCase());let f=new Set(c.map(h=>r(h)).reduce((h,p)=>h.concat(p)));return e.set(u,{dirs:f,paths:c}),c.forEach(h=>{let p=t.get(h);p?p.push(u):t.set(h,[u])}),f.forEach(h=>{let p=t.get(h);p?p[p.length-1]instanceof Set?p[p.length-1].add(u):p.push(new Set([u])):t.set(h,[new Set([u])])}),o(u)}}}});var _w=$((_F,bw)=>{var tL=process.env.__FAKE_PLATFORM__||process.platform,rL=tL==="win32",iL=global.__FAKE_TESTING_FS__||require("fs"),{O_CREAT:nL,O_TRUNC:sL,O_WRONLY:oL,UV_FS_O_FILEMAP:yw=0}=iL.constants,aL=rL&&!!yw,lL=512*1024,cL=yw|sL|nL|oL;bw.exports=aL?t=>t<lL?cL:"w":()=>"w"});var Ph=$((wF,Iw)=>{"use strict";var uL=require("assert"),hL=Yo(),le=require("fs"),fL=Ki(),ir=require("path"),Cw=hw(),ww=Lu(),pL=gw(),dL=Pu(),nt=Fi(),mL=$i(),gL=vh(),Sw=Symbol("onEntry"),Ah=Symbol("checkFs"),Ew=Symbol("checkFs2"),na=Symbol("pruneCache"),Oh=Symbol("isReusable"),ft=Symbol("makeFs"),Th=Symbol("file"),kh=Symbol("directory"),sa=Symbol("link"),vw=Symbol("symlink"),Rw=Symbol("hardlink"),xw=Symbol("unsupported"),Aw=Symbol("checkPath"),kr=Symbol("mkdir"),je=Symbol("onError"),ra=Symbol("pending"),Ow=Symbol("pend"),en=Symbol("unpend"),Rh=Symbol("ended"),xh=Symbol("maybeClose"),Ch=Symbol("skip"),Hn=Symbol("doChown"),Un=Symbol("uid"),Gn=Symbol("gid"),zn=Symbol("checkedCwd"),Lw=require("crypto"),Pw=_w(),yL=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,Wn=yL==="win32",bL=(t,e)=>{if(!Wn)return le.unlink(t,e);let r=t+".DELETE."+Lw.randomBytes(16).toString("hex");le.rename(t,r,i=>{if(i)return e(i);le.unlink(r,e)})},_L=t=>{if(!Wn)return le.unlinkSync(t);let e=t+".DELETE."+Lw.randomBytes(16).toString("hex");le.renameSync(t,e),le.unlinkSync(e)},Tw=(t,e,r)=>t===t>>>0?t:e===e>>>0?e:r,kw=t=>gL(mL(nt(t))).toLowerCase(),wL=(t,e)=>{e=kw(e);for(let r of t.keys()){let i=kw(r);(i===e||i.indexOf(e+"/")===0)&&t.delete(r)}},SL=t=>{for(let e of t.keys())t.delete(e)},Yn=class extends hL{constructor(e){if(e||(e={}),e.ondone=r=>{this[Rh]=!0,this[xh]()},super(e),this[zn]=!1,this.reservations=pL(),this.transform=typeof e.transform=="function"?e.transform:null,this.writable=!0,this.readable=!1,this[ra]=0,this[Rh]=!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||Wn,this.newer=!!e.newer,this.keep=!!e.keep,this.noMtime=!!e.noMtime,this.preservePaths=!!e.preservePaths,this.unlink=!!e.unlink,this.cwd=nt(ir.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[Sw](r))}warn(e,r,i={}){return(e==="TAR_BAD_ARCHIVE"||e==="TAR_ABORT")&&(i.recoverable=!1),super.warn(e,r,i)}[xh](){this[Rh]&&this[ra]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"))}[Aw](e){if(this.strip){let r=nt(e.path).split("/");if(r.length<this.strip)return!1;if(e.path=r.slice(this.strip).join("/"),e.type==="Link"){let i=nt(e.linkpath).split("/");if(i.length>=this.strip)e.linkpath=i.slice(this.strip).join("/");else return!1}}if(!this.preservePaths){let r=nt(e.path),i=r.split("/");if(i.includes("..")||Wn&&/^[a-z]:\.\.$/i.test(i[0]))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:e,path:r}),!1;let[n,s]=dL(r);n&&(e.path=s,this.warn("TAR_ENTRY_INFO",`stripping ${n} from absolute path`,{entry:e,path:r}))}if(ir.isAbsolute(e.path)?e.absolute=nt(ir.resolve(e.path)):e.absolute=nt(ir.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:nt(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}=ir.win32.parse(e.absolute);e.absolute=r+ww.encode(e.absolute.slice(r.length));let{root:i}=ir.win32.parse(e.path);e.path=i+ww.encode(e.path.slice(i.length))}return!0}[Sw](e){if(!this[Aw](e))return e.resume();switch(uL.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[Ah](e);case"CharacterDevice":case"BlockDevice":case"FIFO":default:return this[xw](e)}}[je](e,r){e.name==="CwdError"?this.emit("error",e):(this.warn("TAR_ENTRY_ERROR",e,{entry:r}),this[en](),r.resume())}[kr](e,r,i){Cw(nt(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)}[Hn](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}[Un](e){return Tw(this.uid,e.uid,this.processUid)}[Gn](e){return Tw(this.gid,e.gid,this.processGid)}[Th](e,r){let i=e.mode&4095||this.fmode,n=new fL.WriteStream(e.absolute,{flags:Pw(e.size),mode:i,autoClose:!1});n.on("error",l=>{n.fd&&le.close(n.fd,()=>{}),n.write=()=>!0,this[je](l,e),r()});let s=1,o=l=>{if(l){n.fd&&le.close(n.fd,()=>{}),this[je](l,e),r();return}--s===0&&le.close(n.fd,c=>{c?this[je](c,e):this[en](),r()})};n.on("finish",l=>{let c=e.absolute,u=n.fd;if(e.mtime&&!this.noMtime){s++;let f=e.atime||new Date,h=e.mtime;le.futimes(u,f,h,p=>p?le.utimes(c,f,h,g=>o(g&&p)):o())}if(this[Hn](e)){s++;let f=this[Un](e),h=this[Gn](e);le.fchown(u,f,h,p=>p?le.chown(c,f,h,g=>o(g&&p)):o())}o()});let a=this.transform&&this.transform(e)||e;a!==e&&(a.on("error",l=>{this[je](l,e),r()}),e.pipe(a)),a.pipe(n)}[kh](e,r){let i=e.mode&4095||this.dmode;this[kr](e.absolute,i,n=>{if(n){this[je](n,e),r();return}let s=1,o=a=>{--s===0&&(r(),this[en](),e.resume())};e.mtime&&!this.noMtime&&(s++,le.utimes(e.absolute,e.atime||new Date,e.mtime,o)),this[Hn](e)&&(s++,le.chown(e.absolute,this[Un](e),this[Gn](e),o)),o()})}[xw](e){e.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${e.type}`,{entry:e}),e.resume()}[vw](e,r){this[sa](e,e.linkpath,"symlink",r)}[Rw](e,r){let i=nt(ir.resolve(this.cwd,e.linkpath));this[sa](e,i,"link",r)}[Ow](){this[ra]++}[en](){this[ra]--,this[xh]()}[Ch](e){this[en](),e.resume()}[Oh](e,r){return e.type==="File"&&!this.unlink&&r.isFile()&&r.nlink<=1&&!Wn}[Ah](e){this[Ow]();let r=[e.path];e.linkpath&&r.push(e.linkpath),this.reservations.reserve(r,i=>this[Ew](e,i))}[na](e){e.type==="SymbolicLink"?SL(this.dirCache):e.type!=="Directory"&&wL(this.dirCache,e.absolute)}[Ew](e,r){this[na](e);let i=a=>{this[na](e),r(a)},n=()=>{this[kr](this.cwd,this.dmode,a=>{if(a){this[je](a,e),i();return}this[zn]=!0,s()})},s=()=>{if(e.absolute!==this.cwd){let a=nt(ir.dirname(e.absolute));if(a!==this.cwd)return this[kr](a,this.dmode,l=>{if(l){this[je](l,e),i();return}o()})}o()},o=()=>{le.lstat(e.absolute,(a,l)=>{if(l&&(this.keep||this.newer&&l.mtime>e.mtime)){this[Ch](e),i();return}if(a||this[Oh](e,l))return this[ft](null,e,i);if(l.isDirectory()){if(e.type==="Directory"){let c=!this.noChmod&&e.mode&&(l.mode&4095)!==e.mode,u=f=>this[ft](f,e,i);return c?le.chmod(e.absolute,e.mode,u):u()}if(e.absolute!==this.cwd)return le.rmdir(e.absolute,c=>this[ft](c,e,i))}if(e.absolute===this.cwd)return this[ft](null,e,i);bL(e.absolute,c=>this[ft](c,e,i))})};this[zn]?s():n()}[ft](e,r,i){if(e){this[je](e,r),i();return}switch(r.type){case"File":case"OldFile":case"ContiguousFile":return this[Th](r,i);case"Link":return this[Rw](r,i);case"SymbolicLink":return this[vw](r,i);case"Directory":case"GNUDumpDir":return this[kh](r,i)}}[sa](e,r,i,n){le[i](r,e.absolute,s=>{s?this[je](s,e):(this[en](),e.resume()),n()})}},ia=t=>{try{return[null,t()]}catch(e){return[e,null]}},Lh=class extends Yn{[ft](e,r){return super[ft](e,r,()=>{})}[Ah](e){if(this[na](e),!this[zn]){let s=this[kr](this.cwd,this.dmode);if(s)return this[je](s,e);this[zn]=!0}if(e.absolute!==this.cwd){let s=nt(ir.dirname(e.absolute));if(s!==this.cwd){let o=this[kr](s,this.dmode);if(o)return this[je](o,e)}}let[r,i]=ia(()=>le.lstatSync(e.absolute));if(i&&(this.keep||this.newer&&i.mtime>e.mtime))return this[Ch](e);if(r||this[Oh](e,i))return this[ft](null,e);if(i.isDirectory()){if(e.type==="Directory"){let o=!this.noChmod&&e.mode&&(i.mode&4095)!==e.mode,[a]=o?ia(()=>{le.chmodSync(e.absolute,e.mode)}):[];return this[ft](a,e)}let[s]=ia(()=>le.rmdirSync(e.absolute));this[ft](s,e)}let[n]=e.absolute===this.cwd?[]:ia(()=>_L(e.absolute));this[ft](n,e)}[Th](e,r){let i=e.mode&4095||this.fmode,n=a=>{let l;try{le.closeSync(s)}catch(c){l=c}(a||l)&&this[je](a||l,e),r()},s;try{s=le.openSync(e.absolute,Pw(e.size),i)}catch(a){return n(a)}let o=this.transform&&this.transform(e)||e;o!==e&&(o.on("error",a=>this[je](a,e)),e.pipe(o)),o.on("data",a=>{try{le.writeSync(s,a,0,a.length)}catch(l){n(l)}}),o.on("end",a=>{let l=null;if(e.mtime&&!this.noMtime){let c=e.atime||new Date,u=e.mtime;try{le.futimesSync(s,c,u)}catch(f){try{le.utimesSync(e.absolute,c,u)}catch{l=f}}}if(this[Hn](e)){let c=this[Un](e),u=this[Gn](e);try{le.fchownSync(s,c,u)}catch(f){try{le.chownSync(e.absolute,c,u)}catch{l=l||f}}}n(l)})}[kh](e,r){let i=e.mode&4095||this.dmode,n=this[kr](e.absolute,i);if(n){this[je](n,e),r();return}if(e.mtime&&!this.noMtime)try{le.utimesSync(e.absolute,e.atime||new Date,e.mtime)}catch{}if(this[Hn](e))try{le.chownSync(e.absolute,this[Un](e),this[Gn](e))}catch{}r(),e.resume()}[kr](e,r){try{return Cw.sync(nt(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}}[sa](e,r,i,n){try{le[i+"Sync"](r,e.absolute),n(),e.resume()}catch(s){return this[je](s,e)}}};Yn.Sync=Lh;Iw.exports=Yn});var Bw=$((SF,Fw)=>{"use strict";var EL=Pi(),oa=Ph(),Dw=require("fs"),Mw=Ki(),Nw=require("path"),Ih=$i();Fw.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=EL(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&&vL(i,e),i.file&&i.sync?RL(i):i.file?xL(i,r):i.sync?AL(i):OL(i)};var vL=(t,e)=>{let r=new Map(e.map(s=>[Ih(s),!0])),i=t.filter,n=(s,o)=>{let a=o||Nw.parse(s).root||".",l=s===a?!1:r.has(s)?r.get(s):n(Nw.dirname(s),a);return r.set(s,l),l};t.filter=i?(s,o)=>i(s,o)&&n(Ih(s)):s=>n(Ih(s))},RL=t=>{let e=new oa.Sync(t),r=t.file,i=Dw.statSync(r),n=t.maxReadSize||16*1024*1024;new Mw.ReadStreamSync(r,{readSize:n,size:i.size}).pipe(e)},xL=(t,e)=>{let r=new oa(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("close",o),Dw.stat(n,(l,c)=>{if(l)a(l);else{let u=new Mw.ReadStream(n,{readSize:i,size:c.size});u.on("error",a),u.pipe(r)}})});return e?s.then(e,e):s},AL=t=>new oa.Sync(t),OL=t=>new oa(t)});var jw=$(Ae=>{"use strict";Ae.c=Ae.create=w_();Ae.r=Ae.replace=dh();Ae.t=Ae.list=Vo();Ae.u=Ae.update=k_();Ae.x=Ae.extract=Bw();Ae.Pack=Io();Ae.Unpack=Ph();Ae.Parse=Yo();Ae.ReadEntry=go();Ae.WriteEntry=Hu();Ae.Header=ji();Ae.Pax=bo();Ae.types=Ru()});var zw=$((AF,Gw)=>{function pt(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))}Gw.exports=pt;pt.prototype.reset=function(){this._attempts=1,this._timeouts=this._originalTimeouts.slice(0)};pt.prototype.stop=function(){this._timeout&&clearTimeout(this._timeout),this._timer&&clearTimeout(this._timer),this._timeouts=[],this._cachedTimeouts=null};pt.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};pt.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)};pt.prototype.try=function(t){console.log("Using RetryOperation.try() is deprecated"),this.attempt(t)};pt.prototype.start=function(t){console.log("Using RetryOperation.start() is deprecated"),this.attempt(t)};pt.prototype.start=pt.prototype.try;pt.prototype.errors=function(){return this._errors};pt.prototype.attempts=function(){return this._attempts};pt.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 Ww=$(ri=>{var LL=zw();ri.operation=function(t){var e=ri.timeouts(t);return new LL(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(l){var c=ri.operation(e),u=Array.prototype.slice.call(arguments,1),f=u.pop();u.push(function(h){c.retry(h)||(h&&(arguments[0]=c.mainError()),f.apply(this,arguments))}),c.attempt(function(){l.apply(t,u)})}.bind(t,o),t[s].options=e}}});var Vw=$((TF,Yw)=>{Yw.exports=Ww()});var Zw=$((kF,Kw)=>{var PL=Vw();function IL(t,e){function r(i,n){var s=e||{},o;"randomize"in s||(s.randomize=!0),o=PL.operation(s);function a(u){n(u||new Error("Aborted"))}function l(u,f){if(u.bail){a(u);return}o.retry(u)?s.onRetry&&s.onRetry(u,f):n(o.mainError())}function c(u){var f;try{f=t(a,u)}catch(h){l(h,u);return}Promise.resolve(f).then(i).catch(function(p){l(p,u)})}o.attempt(c)}return new Promise(r)}Kw.exports=IL});var QS=require("picocolors");var lE=ie(sf());function xa(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function fn(t){return fn=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},fn(t)}function Aa(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Oa(t,e){if(e&&(fn(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 Nr(t){return Nr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Nr(t)}function $t(t,e){return $t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,n){return i.__proto__=n,i},$t(t,e)}function Ta(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&&$t(t,e)}function ka(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function Ca(){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 Ca()?ai=Reflect.construct.bind():ai=function(n,s,o){var a=[null];a.push.apply(a,s);var l=Function.bind.apply(n,a),c=new l;return o&&$t(c,o.prototype),c},ai.apply(null,arguments)}function pn(t){var e=typeof Map=="function"?new Map:void 0;return pn=function(i){if(i===null||!ka(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,Nr(this).constructor)}return n.prototype=Object.create(i.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),$t(n,i)},pn(t)}var of=ie(require("find-up"));var cE=ie(require("fs-extra")),fN=function(t){Ta(e,t);function e(r){var i;return xa(this,e),i=Oa(this,Nr(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),i.directory=r,i}return e}(pn(Error));var pE=ie(require("json5"));var uE=ie(require("fs")),hE=ie(require("path"));var WO=ie(require("fs")),YO=ie(require("path"));function Ef(t){return typeof t=="undefined"||t===null}function dE(t){return typeof t=="object"&&t!==null}function mE(t){return Array.isArray(t)?t:Ef(t)?[]:[t]}function gE(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 yE(t,e){var r="",i;for(i=0;i<e;i+=1)r+=t;return r}function bE(t){return t===0&&Number.NEGATIVE_INFINITY===1/t}var _E=Ef,wE=dE,SE=mE,EE=yE,vE=bE,RE=gE,xe={isNothing:_E,isObject:wE,toArray:SE,repeat:EE,isNegativeZero:vE,extend:RE};function vf(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 mn(t,e){Error.call(this),this.name="YAMLException",this.reason=t,this.mark=e,this.message=vf(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}mn.prototype=Object.create(Error.prototype);mn.prototype.constructor=mn;mn.prototype.toString=function(e){return this.name+": "+vf(this,e)};var He=mn;function La(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 Pa(t,e){return xe.repeat(" ",e-t.length)+t}function xE(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="",l,c,u=Math.min(t.line+e.linesAfter,n.length).toString().length,f=e.maxLength-(e.indent+u+3);for(l=1;l<=e.linesBefore&&!(o-l<0);l++)c=La(t.buffer,i[o-l],n[o-l],t.position-(i[o]-i[o-l]),f),a=xe.repeat(" ",e.indent)+Pa((t.line-l+1).toString(),u)+" | "+c.str+`
|
12
12
|
`+a;for(c=La(t.buffer,i[o],n[o],t.position,f),a+=xe.repeat(" ",e.indent)+Pa((t.line+1).toString(),u)+" | "+c.str+`
|
13
13
|
`,a+=xe.repeat("-",e.indent+u+3+c.pos)+`^
|
14
14
|
`,l=1;l<=e.linesAfter&&!(o+l>=n.length);l++)c=La(t.buffer,i[o+l],n[o+l],t.position-(i[o]-i[o+l]),f),a+=xe.repeat(" ",e.indent)+Pa((t.line+l+1).toString(),u)+" | "+c.str+`
|
15
|
-
`;return a.replace(/\n$/,"")}var AE=xE,OE=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],TE=["scalar","sequence","mapping"];function kE(t){var e={};return t!==null&&Object.keys(t).forEach(function(r){t[r].forEach(function(i){e[String(i)]=r})}),e}function CE(t,e){if(e=e||{},Object.keys(e).forEach(function(r){if(OE.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=kE(e.styleAliases||null),TE.indexOf(this.kind)===-1)throw new He('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}var Le=CE;function af(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 LE(){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 Na(t){return this.extend(t)}Na.prototype.extend=function(e){var r=[],i=[];if(e instanceof Le)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 Le))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 Le))throw new He("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var n=Object.create(Na.prototype);return n.implicit=(this.implicit||[]).concat(r),n.explicit=(this.explicit||[]).concat(i),n.compiledImplicit=af(n,"implicit"),n.compiledExplicit=af(n,"explicit"),n.compiledTypeMap=LE(n.compiledImplicit,n.compiledExplicit),n};var Rf=Na,xf=new Le("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}}),Af=new Le("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}}),Of=new Le("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}}),Tf=new Rf({explicit:[xf,Af,Of]});function PE(t){if(t===null)return!0;var e=t.length;return e===1&&t==="~"||e===4&&(t==="null"||t==="Null"||t==="NULL")}function IE(){return null}function NE(t){return t===null}var kf=new Le("tag:yaml.org,2002:null",{kind:"scalar",resolve:PE,construct:IE,predicate:NE,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});function DE(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 ME(t){return t==="true"||t==="True"||t==="TRUE"}function FE(t){return Object.prototype.toString.call(t)==="[object Boolean]"}var Cf=new Le("tag:yaml.org,2002:bool",{kind:"scalar",resolve:DE,construct:ME,predicate:FE,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 BE(t){return 48<=t&&t<=57||65<=t&&t<=70||97<=t&&t<=102}function jE(t){return 48<=t&&t<=55}function $E(t){return 48<=t&&t<=57}function qE(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(!BE(t.charCodeAt(r)))return!1;i=!0}return i&&n!=="_"}if(n==="o"){for(r++;r<e;r++)if(n=t[r],n!=="_"){if(!jE(t.charCodeAt(r)))return!1;i=!0}return i&&n!=="_"}}if(n==="_")return!1;for(;r<e;r++)if(n=t[r],n!=="_"){if(!$E(t.charCodeAt(r)))return!1;i=!0}return!(!i||n==="_")}function HE(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 UE(t){return Object.prototype.toString.call(t)==="[object Number]"&&t%1===0&&!xe.isNegativeZero(t)}var Lf=new Le("tag:yaml.org,2002:int",{kind:"scalar",resolve:qE,construct:HE,predicate:UE,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"]}}),GE=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function zE(t){return!(t===null||!GE.test(t)||t[t.length-1]==="_")}function WE(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 YE=/^[-+]?[0-9]+e/;function
|
15
|
+
`;return a.replace(/\n$/,"")}var AE=xE,OE=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],TE=["scalar","sequence","mapping"];function kE(t){var e={};return t!==null&&Object.keys(t).forEach(function(r){t[r].forEach(function(i){e[String(i)]=r})}),e}function CE(t,e){if(e=e||{},Object.keys(e).forEach(function(r){if(OE.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=kE(e.styleAliases||null),TE.indexOf(this.kind)===-1)throw new He('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}var Le=CE;function af(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 LE(){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 Na(t){return this.extend(t)}Na.prototype.extend=function(e){var r=[],i=[];if(e instanceof Le)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 Le))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 Le))throw new He("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var n=Object.create(Na.prototype);return n.implicit=(this.implicit||[]).concat(r),n.explicit=(this.explicit||[]).concat(i),n.compiledImplicit=af(n,"implicit"),n.compiledExplicit=af(n,"explicit"),n.compiledTypeMap=LE(n.compiledImplicit,n.compiledExplicit),n};var Rf=Na,xf=new Le("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}}),Af=new Le("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}}),Of=new Le("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}}),Tf=new Rf({explicit:[xf,Af,Of]});function PE(t){if(t===null)return!0;var e=t.length;return e===1&&t==="~"||e===4&&(t==="null"||t==="Null"||t==="NULL")}function IE(){return null}function NE(t){return t===null}var kf=new Le("tag:yaml.org,2002:null",{kind:"scalar",resolve:PE,construct:IE,predicate:NE,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});function DE(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 ME(t){return t==="true"||t==="True"||t==="TRUE"}function FE(t){return Object.prototype.toString.call(t)==="[object Boolean]"}var Cf=new Le("tag:yaml.org,2002:bool",{kind:"scalar",resolve:DE,construct:ME,predicate:FE,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 BE(t){return 48<=t&&t<=57||65<=t&&t<=70||97<=t&&t<=102}function jE(t){return 48<=t&&t<=55}function $E(t){return 48<=t&&t<=57}function qE(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(!BE(t.charCodeAt(r)))return!1;i=!0}return i&&n!=="_"}if(n==="o"){for(r++;r<e;r++)if(n=t[r],n!=="_"){if(!jE(t.charCodeAt(r)))return!1;i=!0}return i&&n!=="_"}}if(n==="_")return!1;for(;r<e;r++)if(n=t[r],n!=="_"){if(!$E(t.charCodeAt(r)))return!1;i=!0}return!(!i||n==="_")}function HE(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 UE(t){return Object.prototype.toString.call(t)==="[object Number]"&&t%1===0&&!xe.isNegativeZero(t)}var Lf=new Le("tag:yaml.org,2002:int",{kind:"scalar",resolve:qE,construct:HE,predicate:UE,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"]}}),GE=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function zE(t){return!(t===null||!GE.test(t)||t[t.length-1]==="_")}function WE(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 YE=/^[-+]?[0-9]+e/;function VE(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(xe.isNegativeZero(t))return"-0.0";return r=t.toString(10),YE.test(r)?r.replace("e",".e"):r}function KE(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!==0||xe.isNegativeZero(t))}var Pf=new Le("tag:yaml.org,2002:float",{kind:"scalar",resolve:zE,construct:WE,predicate:KE,represent:VE,defaultStyle:"lowercase"}),If=Tf.extend({implicit:[kf,Cf,Lf,Pf]}),Nf=If,Df=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Mf=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 ZE(t){return t===null?!1:Df.exec(t)!==null||Mf.exec(t)!==null}function XE(t){var e,r,i,n,s,o,a,l=0,c=null,u,f,h;if(e=Df.exec(t),e===null&&(e=Mf.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(l=e[7].slice(0,3);l.length<3;)l+="0";l=+l}return e[9]&&(u=+e[10],f=+(e[11]||0),c=(u*60+f)*6e4,e[9]==="-"&&(c=-c)),h=new Date(Date.UTC(r,i,n,s,o,a,l)),c&&h.setTime(h.getTime()-c),h}function JE(t){return t.toISOString()}var Ff=new Le("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:ZE,construct:XE,instanceOf:Date,represent:JE});function QE(t){return t==="<<"||t===null}var Bf=new Le("tag:yaml.org,2002:merge",{kind:"scalar",resolve:QE}),ja=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
16
16
|
\r`;function ev(t){if(t===null)return!1;var e,r,i=0,n=t.length,s=ja;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 tv(t){var e,r,i=t.replace(/[\r\n=]/g,""),n=i.length,s=ja,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 rv(t){var e="",r=0,i,n,s=t.length,o=ja;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 iv(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"}var jf=new Le("tag:yaml.org,2002:binary",{kind:"scalar",resolve:ev,construct:tv,predicate:iv,represent:rv}),nv=Object.prototype.hasOwnProperty,sv=Object.prototype.toString;function ov(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,sv.call(n)!=="[object Object]")return!1;for(s in n)if(nv.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 av(t){return t!==null?t:[]}var $f=new Le("tag:yaml.org,2002:omap",{kind:"sequence",resolve:ov,construct:av}),lv=Object.prototype.toString;function cv(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],lv.call(i)!=="[object Object]"||(n=Object.keys(i),n.length!==1))return!1;s[e]=[n[0],i[n[0]]]}return!0}function uv(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 qf=new Le("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:cv,construct:uv}),hv=Object.prototype.hasOwnProperty;function fv(t){if(t===null)return!0;var e,r=t;for(e in r)if(hv.call(r,e)&&r[e]!==null)return!1;return!0}function pv(t){return t!==null?t:{}}var Hf=new Le("tag:yaml.org,2002:set",{kind:"mapping",resolve:fv,construct:pv}),$a=Nf.extend({implicit:[Ff,Bf],explicit:[jf,$f,qf,Hf]}),lr=Object.prototype.hasOwnProperty,as=1,Uf=2,Gf=3,ls=4,Ia=1,dv=2,lf=3,mv=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,gv=/[\x85\u2028\u2029]/,yv=/[,\[\]\{\}]/,zf=/^(?:!|!!|![a-z\-]+!)$/i,Wf=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function cf(t){return Object.prototype.toString.call(t)}function St(t){return t===10||t===13}function Mr(t){return t===9||t===32}function Ge(t){return t===9||t===32||t===10||t===13}function ci(t){return t===44||t===91||t===93||t===123||t===125}function bv(t){var e;return 48<=t&&t<=57?t-48:(e=t|32,97<=e&&e<=102?e-97+10:-1)}function _v(t){return t===120?2:t===117?4:t===85?8:0}function wv(t){return 48<=t&&t<=57?t-48:-1}function uf(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 Sv(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}var Yf=new Array(256),
|
18
|
-
`,e-1))}function vv(t,e,r){var i,n,s,o,a,l,c,u,f=t.kind,h=t.result,p;if(p=t.input.charCodeAt(t.position),Ge(p)||ci(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),Ge(n)||r&&ci(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),Ge(n)||r&&ci(n))break}else if(p===35){if(i=t.input.charCodeAt(t.position-1),Ge(i))break}else{if(t.position===t.lineStart&&fs(t)||r&&ci(p))break;if(St(p))if(l=t.line,c=t.lineStart,u=t.lineIndent,ve(t,!1,-1),t.lineIndent>=e){a=!0,p=t.input.charCodeAt(t.position);continue}else{t.position=o,t.line=l,t.lineStart=c,t.lineIndent=u;break}}a&&(ar(t,s,o,!1),Ha(t,t.line-l),s=o=t.position,a=!1),Mr(p)||(o=t.position+1),p=t.input.charCodeAt(++t.position)}return ar(t,s,o,!1),t.result?!0:(t.kind=f,t.result=h,!1)}function Rv(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(ar(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 St(r)?(ar(t,i,n,!0),Ha(t,ve(t,!1,e)),i=n=t.position):t.position===t.lineStart&&fs(t)?Q(t,"unexpected end of the document within a single quoted scalar"):(t.position++,n=t.position);Q(t,"unexpected end of the stream within a single quoted scalar")}function xv(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 ar(t,r,t.position,!0),t.position++,!0;if(a===92){if(ar(t,r,t.position,!0),a=t.input.charCodeAt(++t.position),St(a))ve(t,!1,e);else if(a<256&&Yf[a])t.result+=
|
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 Sv(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}var Yf=new Array(256),Vf=new Array(256);for(Dr=0;Dr<256;Dr++)Yf[Dr]=uf(Dr)?1:0,Vf[Dr]=uf(Dr);var Dr;function Ev(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||$a,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 Kf(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=AE(r),new He(e,r)}function Q(t,e){throw Kf(t,e)}function cs(t,e){t.onWarning&&t.onWarning.call(null,Kf(t,e))}var hf={YAML:function(e,r,i){var n,s,o;e.version!==null&&Q(e,"duplication of %YAML directive"),i.length!==1&&Q(e,"YAML directive accepts exactly one argument"),n=/^([0-9]+)\.([0-9]+)$/.exec(i[0]),n===null&&Q(e,"ill-formed argument of the YAML directive"),s=parseInt(n[1],10),o=parseInt(n[2],10),s!==1&&Q(e,"unacceptable YAML version of the document"),e.version=i[0],e.checkLineBreaks=o<2,o!==1&&o!==2&&cs(e,"unsupported YAML version of the document")},TAG:function(e,r,i){var n,s;i.length!==2&&Q(e,"TAG directive accepts exactly two arguments"),n=i[0],s=i[1],zf.test(n)||Q(e,"ill-formed tag handle (first argument) of the TAG directive"),lr.call(e.tagMap,n)&&Q(e,'there is a previously declared suffix for "'+n+'" tag handle'),Wf.test(s)||Q(e,"ill-formed tag prefix (second argument) of the TAG directive");try{s=decodeURIComponent(s)}catch{Q(e,"tag prefix is malformed: "+s)}e.tagMap[n]=s}};function ar(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||Q(t,"expected valid JSON character");else mv.test(a)&&Q(t,"the stream contains non-printable characters");t.result+=a}}function ff(t,e,r,i){var n,s,o,a;for(xe.isObject(r)||Q(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],lr.call(e,s)||(e[s]=r[s],i[s]=!0)}function ui(t,e,r,i,n,s,o,a,l){var c,u;if(Array.isArray(n))for(n=Array.prototype.slice.call(n),c=0,u=n.length;c<u;c+=1)Array.isArray(n[c])&&Q(t,"nested arrays are not supported inside keys"),typeof n=="object"&&cf(n[c])==="[object Object]"&&(n[c]="[object Object]");if(typeof n=="object"&&cf(n)==="[object Object]"&&(n="[object Object]"),n=String(n),e===null&&(e={}),i==="tag:yaml.org,2002:merge")if(Array.isArray(s))for(c=0,u=s.length;c<u;c+=1)ff(t,e,s[c],r);else ff(t,e,s,r);else!t.json&&!lr.call(r,n)&&lr.call(e,n)&&(t.line=o||t.line,t.lineStart=a||t.lineStart,t.position=l||t.position,Q(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 qa(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++):Q(t,"a line break is expected"),t.line+=1,t.lineStart=t.position,t.firstTabInLine=-1}function ve(t,e,r){for(var i=0,n=t.input.charCodeAt(t.position);n!==0;){for(;Mr(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(St(n))for(qa(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&&cs(t,"deficient indentation"),i}function fs(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||Ge(r)))}function Ha(t,e){e===1?t.result+=" ":e>1&&(t.result+=xe.repeat(`
|
18
|
+
`,e-1))}function vv(t,e,r){var i,n,s,o,a,l,c,u,f=t.kind,h=t.result,p;if(p=t.input.charCodeAt(t.position),Ge(p)||ci(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),Ge(n)||r&&ci(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),Ge(n)||r&&ci(n))break}else if(p===35){if(i=t.input.charCodeAt(t.position-1),Ge(i))break}else{if(t.position===t.lineStart&&fs(t)||r&&ci(p))break;if(St(p))if(l=t.line,c=t.lineStart,u=t.lineIndent,ve(t,!1,-1),t.lineIndent>=e){a=!0,p=t.input.charCodeAt(t.position);continue}else{t.position=o,t.line=l,t.lineStart=c,t.lineIndent=u;break}}a&&(ar(t,s,o,!1),Ha(t,t.line-l),s=o=t.position,a=!1),Mr(p)||(o=t.position+1),p=t.input.charCodeAt(++t.position)}return ar(t,s,o,!1),t.result?!0:(t.kind=f,t.result=h,!1)}function Rv(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(ar(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 St(r)?(ar(t,i,n,!0),Ha(t,ve(t,!1,e)),i=n=t.position):t.position===t.lineStart&&fs(t)?Q(t,"unexpected end of the document within a single quoted scalar"):(t.position++,n=t.position);Q(t,"unexpected end of the stream within a single quoted scalar")}function xv(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 ar(t,r,t.position,!0),t.position++,!0;if(a===92){if(ar(t,r,t.position,!0),a=t.input.charCodeAt(++t.position),St(a))ve(t,!1,e);else if(a<256&&Yf[a])t.result+=Vf[a],t.position++;else if((o=_v(a))>0){for(n=o,s=0;n>0;n--)a=t.input.charCodeAt(++t.position),(o=bv(a))>=0?s=(s<<4)+o:Q(t,"expected hexadecimal character");t.result+=Sv(s),t.position++}else Q(t,"unknown escape sequence");r=i=t.position}else St(a)?(ar(t,r,i,!0),Ha(t,ve(t,!1,e)),r=i=t.position):t.position===t.lineStart&&fs(t)?Q(t,"unexpected end of the document within a double quoted scalar"):(t.position++,i=t.position)}Q(t,"unexpected end of the stream within a double quoted scalar")}function Av(t,e){var r=!0,i,n,s,o=t.tag,a,l=t.anchor,c,u,f,h,p,g=Object.create(null),y,b,x,k;if(k=t.input.charCodeAt(t.position),k===91)u=93,p=!1,a=[];else if(k===123)u=125,p=!0,a={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=a),k=t.input.charCodeAt(++t.position);k!==0;){if(ve(t,!0,e),k=t.input.charCodeAt(t.position),k===u)return t.position++,t.tag=o,t.anchor=l,t.kind=p?"mapping":"sequence",t.result=a,!0;r?k===44&&Q(t,"expected the node content, but found ','"):Q(t,"missed comma between flow collection entries"),b=y=x=null,f=h=!1,k===63&&(c=t.input.charCodeAt(t.position+1),Ge(c)&&(f=h=!0,t.position++,ve(t,!0,e))),i=t.line,n=t.lineStart,s=t.position,hi(t,e,as,!1,!0),b=t.tag,y=t.result,ve(t,!0,e),k=t.input.charCodeAt(t.position),(h||t.line===i)&&k===58&&(f=!0,k=t.input.charCodeAt(++t.position),ve(t,!0,e),hi(t,e,as,!1,!0),x=t.result),p?ui(t,a,g,b,y,x,i,n,s):f?a.push(ui(t,null,g,b,y,x,i,n,s)):a.push(y),ve(t,!0,e),k=t.input.charCodeAt(t.position),k===44?(r=!0,k=t.input.charCodeAt(++t.position)):r=!1}Q(t,"unexpected end of the stream within a flow collection")}function Ov(t,e){var r,i,n=Ia,s=!1,o=!1,a=e,l=0,c=!1,u,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)Ia===n?n=f===43?lf:dv:Q(t,"repeat of a chomping mode identifier");else if((u=wv(f))>=0)u===0?Q(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?Q(t,"repeat of an indentation width identifier"):(a=e+u-1,o=!0);else break;if(Mr(f)){do f=t.input.charCodeAt(++t.position);while(Mr(f));if(f===35)do f=t.input.charCodeAt(++t.position);while(!St(f)&&f!==0)}for(;f!==0;){for(qa(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),St(f)){l++;continue}if(t.lineIndent<a){n===lf?t.result+=xe.repeat(`
|
19
19
|
`,s?1+l:l):n===Ia&&s&&(t.result+=`
|
20
20
|
`);break}for(i?Mr(f)?(c=!0,t.result+=xe.repeat(`
|
21
21
|
`,s?1+l:l)):c?(c=!1,t.result+=xe.repeat(`
|
22
22
|
`,l+1)):l===0?s&&(t.result+=" "):t.result+=xe.repeat(`
|
23
23
|
`,l):t.result+=xe.repeat(`
|
24
24
|
`,s?1+l:l),s=!0,o=!0,l=0,r=t.position;!St(f)&&f!==0;)f=t.input.charCodeAt(++t.position);ar(t,r,t.position,!1)}return!0}function pf(t,e){var r,i=t.tag,n=t.anchor,s=[],o,a=!1,l;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=s),l=t.input.charCodeAt(t.position);l!==0&&(t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,Q(t,"tab characters must not be used in indentation")),!(l!==45||(o=t.input.charCodeAt(t.position+1),!Ge(o))));){if(a=!0,t.position++,ve(t,!0,-1)&&t.lineIndent<=e){s.push(null),l=t.input.charCodeAt(t.position);continue}if(r=t.line,hi(t,e,Gf,!1,!0),s.push(t.result),ve(t,!0,-1),l=t.input.charCodeAt(t.position),(t.line===r||t.lineIndent>e)&&l!==0)Q(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 Tv(t,e,r){var i,n,s,o,a,l,c=t.tag,u=t.anchor,f={},h=Object.create(null),p=null,g=null,y=null,b=!1,x=!1,k;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=f),k=t.input.charCodeAt(t.position);k!==0;){if(!b&&t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,Q(t,"tab characters must not be used in indentation")),i=t.input.charCodeAt(t.position+1),s=t.line,(k===63||k===58)&&Ge(i))k===63?(b&&(ui(t,f,h,p,g,null,o,a,l),p=g=y=null),x=!0,b=!0,n=!0):b?(b=!1,n=!0):Q(t,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),t.position+=1,k=i;else{if(o=t.line,a=t.lineStart,l=t.position,!hi(t,r,Uf,!1,!0))break;if(t.line===s){for(k=t.input.charCodeAt(t.position);Mr(k);)k=t.input.charCodeAt(++t.position);if(k===58)k=t.input.charCodeAt(++t.position),Ge(k)||Q(t,"a whitespace character is expected after the key-value separator within a block mapping"),b&&(ui(t,f,h,p,g,null,o,a,l),p=g=y=null),x=!0,b=!1,n=!1,p=t.tag,g=t.result;else if(x)Q(t,"can not read an implicit mapping pair; a colon is missed");else return t.tag=c,t.anchor=u,!0}else if(x)Q(t,"can not read a block mapping entry; a multiline key may not be an implicit key");else return t.tag=c,t.anchor=u,!0}if((t.line===s||t.lineIndent>e)&&(b&&(o=t.line,a=t.lineStart,l=t.position),hi(t,e,ls,!0,n)&&(b?g=t.result:y=t.result),b||(ui(t,f,h,p,g,y,o,a,l),p=g=y=null),ve(t,!0,-1),k=t.input.charCodeAt(t.position)),(t.line===s||t.lineIndent>e)&&k!==0)Q(t,"bad indentation of a mapping entry");else if(t.lineIndent<e)break}return b&&ui(t,f,h,p,g,null,o,a,l),x&&(t.tag=c,t.anchor=u,t.kind="mapping",t.result=f),x}function kv(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&&Q(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)):Q(t,"unexpected end of the stream within a verbatim tag")}else{for(;o!==0&&!Ge(o);)o===33&&(i?Q(t,"tag suffix cannot contain exclamation marks"):(n=t.input.slice(e-1,t.position+1),zf.test(n)||Q(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),yv.test(s)&&Q(t,"tag suffix cannot contain flow indicator characters")}s&&!Wf.test(s)&&Q(t,"tag name cannot contain such characters: "+s);try{s=decodeURIComponent(s)}catch{Q(t,"tag name is malformed: "+s)}return r?t.tag=s:lr.call(t.tagMap,n)?t.tag=t.tagMap[n]+s:n==="!"?t.tag="!"+s:n==="!!"?t.tag="tag:yaml.org,2002:"+s:Q(t,'undeclared tag handle "'+n+'"'),!0}function Cv(t){var e,r;if(r=t.input.charCodeAt(t.position),r!==38)return!1;for(t.anchor!==null&&Q(t,"duplication of an anchor property"),r=t.input.charCodeAt(++t.position),e=t.position;r!==0&&!Ge(r)&&!ci(r);)r=t.input.charCodeAt(++t.position);return t.position===e&&Q(t,"name of an anchor node must contain at least one character"),t.anchor=t.input.slice(e,t.position),!0}function Lv(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&&!Ge(i)&&!ci(i);)i=t.input.charCodeAt(++t.position);return t.position===e&&Q(t,"name of an alias node must contain at least one character"),r=t.input.slice(e,t.position),lr.call(t.anchorMap,r)||Q(t,'unidentified alias "'+r+'"'),t.result=t.anchorMap[r],ve(t,!0,-1),!0}function hi(t,e,r,i,n){var s,o,a,l=1,c=!1,u=!1,f,h,p,g,y,b;if(t.listener!==null&&t.listener("open",t),t.tag=null,t.anchor=null,t.kind=null,t.result=null,s=o=a=ls===r||Gf===r,i&&ve(t,!0,-1)&&(c=!0,t.lineIndent>e?l=1:t.lineIndent===e?l=0:t.lineIndent<e&&(l=-1)),l===1)for(;kv(t)||Cv(t);)ve(t,!0,-1)?(c=!0,a=s,t.lineIndent>e?l=1:t.lineIndent===e?l=0:t.lineIndent<e&&(l=-1)):a=!1;if(a&&(a=c||n),(l===1||ls===r)&&(as===r||Uf===r?y=e:y=e+1,b=t.position-t.lineStart,l===1?a&&(pf(t,b)||Tv(t,b,y))||Av(t,y)?u=!0:(o&&Ov(t,y)||Rv(t,y)||xv(t,y)?u=!0:Lv(t)?(u=!0,(t.tag!==null||t.anchor!==null)&&Q(t,"alias node should not have any properties")):vv(t,y,as===r)&&(u=!0,t.tag===null&&(t.tag="?")),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):l===0&&(u=a&&pf(t,b))),t.tag===null)t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);else if(t.tag==="?"){for(t.result!==null&&t.kind!=="scalar"&&Q(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(lr.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||Q(t,"unknown tag !<"+t.tag+">"),t.result!==null&&g.kind!==t.kind&&Q(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)):Q(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||u}function Pv(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&&(ve(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&&!Ge(o);)o=t.input.charCodeAt(++t.position);for(i=t.input.slice(r,t.position),n=[],i.length<1&&Q(t,"directive name must not be less than one character in length");o!==0;){for(;Mr(o);)o=t.input.charCodeAt(++t.position);if(o===35){do o=t.input.charCodeAt(++t.position);while(o!==0&&!St(o));break}if(St(o))break;for(r=t.position;o!==0&&!Ge(o);)o=t.input.charCodeAt(++t.position);n.push(t.input.slice(r,t.position))}o!==0&&qa(t),lr.call(hf,i)?hf[i](t,i,n):cs(t,'unknown document directive "'+i+'"')}if(ve(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,ve(t,!0,-1)):s&&Q(t,"directives end mark is expected"),hi(t,t.lineIndent-1,ls,!1,!0),ve(t,!0,-1),t.checkLineBreaks&&gv.test(t.input.slice(e,t.position))&&cs(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&fs(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,ve(t,!0,-1));return}if(t.position<t.length-1)Q(t,"end of the stream or a document separator is expected");else return}function Zf(t,e){t=String(t),e=e||{},t.length!==0&&(t.charCodeAt(t.length-1)!==10&&t.charCodeAt(t.length-1)!==13&&(t+=`
|
25
|
-
`),t.charCodeAt(0)===65279&&(t=t.slice(1)));var r=new Ev(t,e),i=t.indexOf("\0");for(i!==-1&&(r.position=i,Q(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;)Pv(r);return r.documents}function Iv(t,e,r){e!==null&&typeof e=="object"&&typeof r=="undefined"&&(r=e,e=null);var i=Zf(t,r);if(typeof e!="function")return i;for(var n=0,s=i.length;n<s;n+=1)e(i[n])}function Nv(t,e){var r=Zf(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 Dv=Iv,Mv=Nv,Xf={loadAll:Dv,load:Mv},Jf=Object.prototype.toString,Qf=Object.prototype.hasOwnProperty,Ua=65279,Fv=9,gn=10,Bv=13,jv=32,$v=33,qv=34,Da=35,Hv=37,Uv=38,Gv=39,zv=42,ep=44,Wv=45,us=58,Yv=61,
|
25
|
+
`),t.charCodeAt(0)===65279&&(t=t.slice(1)));var r=new Ev(t,e),i=t.indexOf("\0");for(i!==-1&&(r.position=i,Q(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;)Pv(r);return r.documents}function Iv(t,e,r){e!==null&&typeof e=="object"&&typeof r=="undefined"&&(r=e,e=null);var i=Zf(t,r);if(typeof e!="function")return i;for(var n=0,s=i.length;n<s;n+=1)e(i[n])}function Nv(t,e){var r=Zf(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 Dv=Iv,Mv=Nv,Xf={loadAll:Dv,load:Mv},Jf=Object.prototype.toString,Qf=Object.prototype.hasOwnProperty,Ua=65279,Fv=9,gn=10,Bv=13,jv=32,$v=33,qv=34,Da=35,Hv=37,Uv=38,Gv=39,zv=42,ep=44,Wv=45,us=58,Yv=61,Vv=62,Kv=63,Zv=64,tp=91,rp=93,Xv=96,ip=123,Jv=124,np=125,Pe={};Pe[0]="\\0";Pe[7]="\\a";Pe[8]="\\b";Pe[9]="\\t";Pe[10]="\\n";Pe[11]="\\v";Pe[12]="\\f";Pe[13]="\\r";Pe[27]="\\e";Pe[34]='\\"';Pe[92]="\\\\";Pe[133]="\\N";Pe[160]="\\_";Pe[8232]="\\L";Pe[8233]="\\P";var Qv=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],e0=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function t0(t,e){var r,i,n,s,o,a,l;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)),l=t.compiledTypeMap.fallback[o],l&&Qf.call(l.styleAliases,a)&&(a=l.styleAliases[a]),r[o]=a;return r}function r0(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+xe.repeat("0",i-e.length)+e}var i0=1,yn=2;function n0(t){this.schema=t.schema||$a,this.indent=Math.max(1,t.indent||2),this.noArrayIndent=t.noArrayIndent||!1,this.skipInvalid=t.skipInvalid||!1,this.flowLevel=xe.isNothing(t.flowLevel)?-1:t.flowLevel,this.styleMap=t0(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==='"'?yn:i0,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 df(t,e){for(var r=xe.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 Ma(t,e){return`
|
28
|
-
`+xe.repeat(" ",t.indent*e)}function s0(t,e){var r,i,n;for(r=0,i=t.implicitTypes.length;r<i;r+=1)if(n=t.implicitTypes[r],n.resolve(e))return!0;return!1}function hs(t){return t===jv||t===Fv}function bn(t){return 32<=t&&t<=126||161<=t&&t<=55295&&t!==8232&&t!==8233||57344<=t&&t<=65533&&t!==Ua||65536<=t&&t<=1114111}function mf(t){return bn(t)&&t!==Ua&&t!==Bv&&t!==gn}function gf(t,e,r){var i=mf(t),n=i&&!hs(t);return(r?i:i&&t!==ep&&t!==tp&&t!==rp&&t!==ip&&t!==np)&&t!==Da&&!(e===us&&!n)||mf(e)&&!hs(e)&&t===Da||e===us&&n}function o0(t){return bn(t)&&t!==Ua&&!hs(t)&&t!==Wv&&t!==
|
28
|
+
`+xe.repeat(" ",t.indent*e)}function s0(t,e){var r,i,n;for(r=0,i=t.implicitTypes.length;r<i;r+=1)if(n=t.implicitTypes[r],n.resolve(e))return!0;return!1}function hs(t){return t===jv||t===Fv}function bn(t){return 32<=t&&t<=126||161<=t&&t<=55295&&t!==8232&&t!==8233||57344<=t&&t<=65533&&t!==Ua||65536<=t&&t<=1114111}function mf(t){return bn(t)&&t!==Ua&&t!==Bv&&t!==gn}function gf(t,e,r){var i=mf(t),n=i&&!hs(t);return(r?i:i&&t!==ep&&t!==tp&&t!==rp&&t!==ip&&t!==np)&&t!==Da&&!(e===us&&!n)||mf(e)&&!hs(e)&&t===Da||e===us&&n}function o0(t){return bn(t)&&t!==Ua&&!hs(t)&&t!==Wv&&t!==Kv&&t!==us&&t!==ep&&t!==tp&&t!==rp&&t!==ip&&t!==np&&t!==Da&&t!==Uv&&t!==zv&&t!==$v&&t!==Jv&&t!==Yv&&t!==Vv&&t!==Gv&&t!==qv&&t!==Hv&&t!==Zv&&t!==Xv}function a0(t){return!hs(t)&&t!==us}function dn(t,e){var r=t.charCodeAt(e),i;return r>=55296&&r<=56319&&e+1<t.length&&(i=t.charCodeAt(e+1),i>=56320&&i<=57343)?(r-55296)*1024+i-56320+65536:r}function sp(t){var e=/^\n* /;return e.test(t)}var op=1,Fa=2,ap=3,lp=4,li=5;function l0(t,e,r,i,n,s,o,a){var l,c=0,u=null,f=!1,h=!1,p=i!==-1,g=-1,y=o0(dn(t,0))&&a0(dn(t,t.length-1));if(e||o)for(l=0;l<t.length;c>=65536?l+=2:l++){if(c=dn(t,l),!bn(c))return li;y=y&&gf(c,u,a),u=c}else{for(l=0;l<t.length;c>=65536?l+=2:l++){if(c=dn(t,l),c===gn)f=!0,p&&(h=h||l-g-1>i&&t[g+1]!==" ",g=l);else if(!bn(c))return li;y=y&&gf(c,u,a),u=c}h=h||p&&l-g-1>i&&t[g+1]!==" "}return!f&&!h?y&&!o&&!n(t)?op:s===yn?li:Fa:r>9&&sp(t)?li:o?s===yn?li:Fa:h?lp:ap}function c0(t,e,r,i,n){t.dump=function(){if(e.length===0)return t.quotingType===yn?'""':"''";if(!t.noCompatMode&&(Qv.indexOf(e)!==-1||e0.test(e)))return t.quotingType===yn?'"'+e+'"':"'"+e+"'";var s=t.indent*Math.max(1,r),o=t.lineWidth===-1?-1:Math.max(Math.min(t.lineWidth,40),t.lineWidth-s),a=i||t.flowLevel>-1&&r>=t.flowLevel;function l(c){return s0(t,c)}switch(l0(e,a,t.indent,o,l,t.quotingType,t.forceQuotes&&!i,n)){case op:return e;case Fa:return"'"+e.replace(/'/g,"''")+"'";case ap:return"|"+yf(e,t.indent)+bf(df(e,s));case lp:return">"+yf(e,t.indent)+bf(df(u0(e,o),s));case li:return'"'+h0(e)+'"';default:throw new He("impossible error: invalid scalar style")}}()}function yf(t,e){var r=sp(t)?String(e):"",i=t[t.length-1]===`
|
29
29
|
`,n=i&&(t[t.length-2]===`
|
30
30
|
`||t===`
|
31
31
|
`),s=n?"+":i?"":"-";return r+s+`
|
@@ -37,13 +37,13 @@ ${i.message}`:y,k=[x,e,t].filter(Boolean).join(`
|
|
37
37
|
`+t.slice(n,s),n=s+1),o=a;return l+=`
|
38
38
|
`,t.length-n>e&&o>n?l+=t.slice(n,o)+`
|
39
39
|
`+t.slice(o+1):l+=t.slice(n),l.slice(1)}function h0(t){for(var e="",r=0,i,n=0;n<t.length;r>=65536?n+=2:n++)r=dn(t,n),i=Pe[r],!i&&bn(r)?(e+=t[n],r>=65536&&(e+=t[n+1])):e+=i||r0(r);return e}function f0(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)),(qt(t,e,a,!1,!1)||typeof a=="undefined"&&qt(t,e,null,!1,!1))&&(i!==""&&(i+=","+(t.condenseFlow?"":" ")),i+=t.dump);t.tag=n,t.dump="["+i+"]"}function wf(t,e,r,i){var n="",s=t.tag,o,a,l;for(o=0,a=r.length;o<a;o+=1)l=r[o],t.replacer&&(l=t.replacer.call(r,String(o),l)),(qt(t,e+1,l,!0,!0,!1,!0)||typeof l=="undefined"&&qt(t,e+1,null,!0,!0,!1,!0))&&((!i||n!=="")&&(n+=Ma(t,e)),t.dump&&gn===t.dump.charCodeAt(0)?n+="-":n+="- ",n+=t.dump);t.tag=s,t.dump=n||"[]"}function p0(t,e,r){var i="",n=t.tag,s=Object.keys(r),o,a,l,c,u;for(o=0,a=s.length;o<a;o+=1)u="",i!==""&&(u+=", "),t.condenseFlow&&(u+='"'),l=s[o],c=r[l],t.replacer&&(c=t.replacer.call(r,l,c)),qt(t,e,l,!1,!1)&&(t.dump.length>1024&&(u+="? "),u+=t.dump+(t.condenseFlow?'"':"")+":"+(t.condenseFlow?"":" "),qt(t,e,c,!1,!1)&&(u+=t.dump,i+=u));t.tag=n,t.dump="{"+i+"}"}function d0(t,e,r,i){var n="",s=t.tag,o=Object.keys(r),a,l,c,u,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,l=o.length;a<l;a+=1)h="",(!i||n!=="")&&(h+=Ma(t,e)),c=o[a],u=r[c],t.replacer&&(u=t.replacer.call(r,c,u)),qt(t,e+1,c,!0,!0,!0)&&(f=t.tag!==null&&t.tag!=="?"||t.dump&&t.dump.length>1024,f&&(t.dump&&gn===t.dump.charCodeAt(0)?h+="?":h+="? "),h+=t.dump,f&&(h+=Ma(t,e)),qt(t,e+1,u,!0,f)&&(t.dump&&gn===t.dump.charCodeAt(0)?h+=":":h+=": ",h+=t.dump,n+=h));t.tag=s,t.dump=n||"{}"}function Sf(t,e,r){var i,n,s,o,a,l;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(l=t.styleMap[a.tag]||a.defaultStyle,Jf.call(a.represent)==="[object Function]")i=a.represent(e,l);else if(Qf.call(a.represent,l))i=a.represent[l](e,l);else throw new He("!<"+a.tag+'> tag resolver accepts not "'+l+'" style');t.dump=i}return!0}return!1}function qt(t,e,r,i,n,s,o){t.tag=null,t.dump=r,Sf(t,r,!1)||Sf(t,r,!0);var a=Jf.call(t.dump),l=i,c;i&&(i=t.flowLevel<0||t.flowLevel>e);var u=a==="[object Object]"||a==="[object Array]",f,h;if(u&&(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(u&&h&&!t.usedDuplicates[f]&&(t.usedDuplicates[f]=!0),a==="[object Object]")i&&Object.keys(t.dump).length!==0?(d0(t,e,t.dump,n),h&&(t.dump="&ref_"+f+t.dump)):(p0(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?wf(t,e-1,t.dump,n):wf(t,e,t.dump,n),h&&(t.dump="&ref_"+f+t.dump)):(f0(t,e,t.dump),h&&(t.dump="&ref_"+f+" "+t.dump));else if(a==="[object String]")t.tag!=="?"&&c0(t,t.dump,e,s,l);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!=="?"&&(c=encodeURI(t.tag[0]==="!"?t.tag.slice(1):t.tag).replace(/!/g,"%21"),t.tag[0]==="!"?c="!"+c:c.slice(0,18)==="tag:yaml.org,2002:"?c="!!"+c.slice(18):c="!<"+c+">",t.dump=c+" "+t.dump)}return!0}function m0(t,e){var r=[],i=[],n,s;for(Ba(t,r,i),n=0,s=i.length;n<s;n+=1)e.duplicates.push(r[i[n]]);e.usedDuplicates=new Array(s)}function Ba(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)Ba(t[n],e,r);else for(i=Object.keys(t),n=0,s=i.length;n<s;n+=1)Ba(t[i[n]],e,r)}function g0(t,e){e=e||{};var r=new n0(e);r.noRefs||m0(t,r);var i=t;return r.replacer&&(i=r.replacer.call({"":i},"",i)),qt(r,0,i,!0,!0)?r.dump+`
|
40
|
-
`:""}var y0=g0,b0={dump:y0};function Ga(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 _0=Le,w0=Rf,S0=Tf,E0=If,v0=Nf,R0=$a,x0=Xf.load,A0=Xf.loadAll,O0=b0.dump,T0=He,k0={binary:jf,float:Pf,map:Of,null:kf,pairs:qf,set:Hf,timestamp:Ff,bool:Cf,int:Lf,merge:Bf,omap:$f,seq:Af,str:xf},C0=Ga("safeLoad","load"),L0=Ga("safeLoadAll","loadAll"),P0=Ga("safeDump","dump"),I0={Type:_0,Schema:w0,FAILSAFE_SCHEMA:S0,JSON_SCHEMA:E0,CORE_SCHEMA:v0,DEFAULT_SCHEMA:R0,load:x0,loadAll:A0,dump:O0,YAMLException:T0,types:k0,safeLoad:C0,safeLoadAll:L0,safeDump:P0},za=I0;var KO=ie(qs()),VO=ie(require("json5"));var ne={};oE(ne,{bold:()=>jO,dimmed:()=>qO,error:()=>ig,grey:()=>HO,info:()=>BO,item:()=>UO,log:()=>mr,turboBlue:()=>Ei,turboGradient:()=>FO,turboLoader:()=>tg,turboRed:()=>Qm,underline:()=>$O,warn:()=>rg,yellow:()=>eg});var We=require("picocolors"),Vm=ie(require("ora")),Zm=ie(require("gradient-string")),Xm="#0099F7",Jm="#F11712",MO="#FFFF00",Oc=t=>{let e=GO(t);return r=>`\x1B[38;5;${e}m${r}${(0,We.reset)("")}`},FO=(0,Zm.default)(Xm,Jm),Ei=Oc(Xm),Qm=Oc(Jm),eg=Oc(MO),tg=t=>(0,Vm.default)({text:t,spinner:{frames:[" ",Ei("> "),Ei(">> "),Ei(">>>")]}}),BO=(...t)=>{mr(Ei((0,We.bold)(">>>")),t.join(" "))},jO=(...t)=>{mr((0,We.bold)(t.join(" ")))},$O=(...t)=>{mr((0,We.underline)(t.join(" ")))},qO=(...t)=>{mr((0,We.dim)(t.join(" ")))},HO=(...t)=>{mr((0,We.gray)(t.join(" ")))},UO=(...t)=>{mr(Ei((0,We.bold)(" \u2022")),t.join(" "))},mr=(...t)=>{console.log(...t)},rg=(...t)=>{console.error(eg((0,We.bold)(">>>")),t.join(" "))},ig=(...t)=>{console.error(Qm((0,We.bold)(">>>")),t.join(" "))};function GO(t){let e=parseInt(t.slice(1),16),r=Math.floor(e/(256*256))%256,i=Math.floor(e/256)%256,n=e%256;return 16+36*Math.round(r/255*5)+6*Math.round(i/255*5)+Math.round(n/255*5)}var $y=ie(require("os")),qy=ie(Li());async function gr(t,e=[],r){let i={cwd:$y.default.tmpdir(),env:{COREPACK_ENABLE_STRICT:"0"},...r};try{let{stdout:n}=await(0,qy.default)(t,e,i);return n.trim()}catch{return}}async function Yc(){let[t,e,r,i]=await Promise.all([gr("yarnpkg",["--version"]),gr("npm",["--version"]),gr("pnpm",["--version"]),gr("bun",["--version"])]);return{yarn:t,pnpm:r,npm:e,bun:i}}async function Kc(){let[t,e,r,i]=await Promise.all([gr("yarnpkg",["global","bin"]),gr("npm",["config","get","prefix"]),gr("pnpm",["bin","--global"]),gr("bun",["pm","--g","bin"])]);return{yarn:t,pnpm:r,npm:e,bun:i}}var Uk=ie(require("fs-extra"));var Gk=ie(require("path")),zk=ie(require("fs-extra")),Wk=require("picocolors");var $w=require("stream"),qw=require("util"),TL=require("path"),kL=require("os"),Hw=require("fs"),CL=ie(jw());var vF=(0,qw.promisify)($w.Stream.pipeline);var Uw=require("fs-extra");var $L=ie(require("path")),qL=ie(Zw()),Xw=require("picocolors"),Nh=require("fs-extra");var eE=require("commander");var aa={name:"@turbo/codemod",version:"2.0.15-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/turborepo",directory:"packages/turbo-codemod"},bugs:{url:"https://github.com/vercel/turborepo/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",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",json5:"^2.2.3","is-git-clean":"^1.1.0",ora:"4.1.1",picocolors:"1.0.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/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 ln=ie(require("os")),VS=require("child_process"),Oe=require("picocolors"),ZS=require("inquirer");var Xe=require("picocolors"),fS=ie(require("ora"),1),pS=ie(require("gradient-string"),1);var qP=ie(Li(),1),nB=require("fs-extra");var cB=ie(qs(),1),hB=require("fs-extra"),pB=require("fs-extra"),mB=require("picocolors"),bS=require("stream"),_S=require("util"),_B=require("fs-extra"),vB=require("picocolors"),AB=require("fs-extra"),ii=ie(require("path"),1),Ue=require("fs-extra"),wS=ie(Li(),1),SS=ie(require("path"),1),ES=require("fs-extra"),vS=require("picocolors"),sr=ie(require("path"),1),RS=ie(Li(),1),st=require("fs-extra"),xS=ie(qs(),1);var Vn=ie(require("path"),1),Dt=require("fs-extra"),nn=ie(require("path"),1),Mt=require("fs-extra"),Zn=ie(require("path"),1),Ft=require("fs-extra"),ns=require("picocolors"),EI=ie(require("gradient-string"),1),vI=ie(Li(),1),RI=ie(require("ora"),1),xI=require("semver"),AI=require("picocolors"),UL=Object.create,Fh=Object.defineProperty,GL=Object.getOwnPropertyDescriptor,zL=Object.getOwnPropertyNames,WL=Object.getPrototypeOf,YL=Object.prototype.hasOwnProperty,te=(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')}),KL=(t,e)=>()=>(t&&(e=t(t=0)),e),ee=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),VL=(t,e)=>{for(var r in e)Fh(t,r,{get:e[r],enumerable:!0})},ZL=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of zL(e))!YL.call(t,n)&&n!==r&&Fh(t,n,{get:()=>e[n],enumerable:!(i=GL(e,n))||i.enumerable});return t},ua=(t,e,r)=>(r=t!=null?UL(WL(t)):{},ZL(e||!t||!t.__esModule?Fh(r,"default",{value:t,enumerable:!0}):r,t)),W=KL(()=>{}),XL=ee((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}),JL=ee((t,e)=>{W();var r=XL().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,l=Object.defineProperty||function(D,d,m){D[d]=m.value},c=typeof Symbol=="function"?Symbol:{},u=c.iterator||"@@iterator",f=c.asyncIterator||"@@asyncIterator",h=c.toStringTag||"@@toStringTag";function p(D,d,m){return Object.defineProperty(D,d,{value:m,enumerable:!0,configurable:!0,writable:!0}),D[d]}try{p({},"")}catch{p=function(D,d,m){return D[d]=m}}function g(D,d,m,_){var R=d&&d.prototype instanceof O?d:O,E=Object.create(R.prototype),M=new j(_||[]);return l(E,"_invoke",{value:V(D,m,M)}),E}function y(D,d,m){try{return{type:"normal",arg:D.call(d,m)}}catch(_){return{type:"throw",arg:_}}}s.wrap=g;var b="suspendedStart",x="suspendedYield",k="executing",C="completed",T={};function O(){}function I(){}function w(){}var v={};p(v,u,function(){return this});var F=Object.getPrototypeOf,q=F&&F(F(z([])));q&&q!==o&&a.call(q,u)&&(v=q);var P=w.prototype=O.prototype=Object.create(v);function U(D){["next","throw","return"].forEach(function(d){p(D,d,function(m){return this._invoke(d,m)})})}function K(D,d){function m(R,E,M,B){var Z=y(D[R],D,E);if(Z.type!=="throw"){var H=Z.arg,J=H.value;return J&&r(J)=="object"&&a.call(J,"__await")?d.resolve(J.__await).then(function(G){m("next",G,M,B)},function(G){m("throw",G,M,B)}):d.resolve(J).then(function(G){H.value=G,M(H)},function(G){return m("throw",G,M,B)})}B(Z.arg)}var _;l(this,"_invoke",{value:function(R,E){function M(){return new d(function(B,Z){m(R,E,B,Z)})}return _=_?_.then(M,M):M()}})}function V(D,d,m){var _=b;return function(R,E){if(_===k)throw new Error("Generator is already running");if(_===C){if(R==="throw")throw E;return{value:n,done:!0}}for(m.method=R,m.arg=E;;){var M=m.delegate;if(M){var B=N(M,m);if(B){if(B===T)continue;return B}}if(m.method==="next")m.sent=m._sent=m.arg;else if(m.method==="throw"){if(_===b)throw _=C,m.arg;m.dispatchException(m.arg)}else m.method==="return"&&m.abrupt("return",m.arg);_=k;var Z=y(D,d,m);if(Z.type==="normal"){if(_=m.done?C:x,Z.arg===T)continue;return{value:Z.arg,done:m.done}}Z.type==="throw"&&(_=C,m.method="throw",m.arg=Z.arg)}}}function N(D,d){var m=d.method,_=D.iterator[m];if(_===n)return d.delegate=null,m==="throw"&&D.iterator.return&&(d.method="return",d.arg=n,N(D,d),d.method==="throw")||m!=="return"&&(d.method="throw",d.arg=new TypeError("The iterator does not provide a '"+m+"' method")),T;var R=y(_,D.iterator,d.arg);if(R.type==="throw")return d.method="throw",d.arg=R.arg,d.delegate=null,T;var E=R.arg;return E?E.done?(d[D.resultName]=E.value,d.next=D.nextLoc,d.method!=="return"&&(d.method="next",d.arg=n),d.delegate=null,T):E:(d.method="throw",d.arg=new TypeError("iterator result is not an object"),d.delegate=null,T)}function A(D){var d={tryLoc:D[0]};1 in D&&(d.catchLoc=D[1]),2 in D&&(d.finallyLoc=D[2],d.afterLoc=D[3]),this.tryEntries.push(d)}function L(D){var d=D.completion||{};d.type="normal",delete d.arg,D.completion=d}function j(D){this.tryEntries=[{tryLoc:"root"}],D.forEach(A,this),this.reset(!0)}function z(D){if(D||D===""){var d=D[u];if(d)return d.call(D);if(typeof D.next=="function")return D;if(!isNaN(D.length)){var m=-1,_=function R(){for(;++m<D.length;)if(a.call(D,m))return R.value=D[m],R.done=!1,R;return R.value=n,R.done=!0,R};return _.next=_}}throw new TypeError(r(D)+" is not iterable")}return I.prototype=w,l(P,"constructor",{value:w,configurable:!0}),l(w,"constructor",{value:I,configurable:!0}),I.displayName=p(w,h,"GeneratorFunction"),s.isGeneratorFunction=function(D){var d=typeof D=="function"&&D.constructor;return!!d&&(d===I||(d.displayName||d.name)==="GeneratorFunction")},s.mark=function(D){return Object.setPrototypeOf?Object.setPrototypeOf(D,w):(D.__proto__=w,p(D,h,"GeneratorFunction")),D.prototype=Object.create(P),D},s.awrap=function(D){return{__await:D}},U(K.prototype),p(K.prototype,f,function(){return this}),s.AsyncIterator=K,s.async=function(D,d,m,_,R){R===void 0&&(R=Promise);var E=new K(g(D,d,m,_),R);return s.isGeneratorFunction(d)?E:E.next().then(function(M){return M.done?M.value:E.next()})},U(P),p(P,h,"Generator"),p(P,u,function(){return this}),p(P,"toString",function(){return"[object Generator]"}),s.keys=function(D){var d=Object(D),m=[];for(var _ in d)m.push(_);return m.reverse(),function R(){for(;m.length;){var E=m.pop();if(E in d)return R.value=E,R.done=!1,R}return R.done=!0,R}},s.values=z,j.prototype={constructor:j,reset:function(D){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(L),!D)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 D=this.tryEntries[0].completion;if(D.type==="throw")throw D.arg;return this.rval},dispatchException:function(D){if(this.done)throw D;var d=this;function m(Z,H){return E.type="throw",E.arg=D,d.next=Z,H&&(d.method="next",d.arg=n),!!H}for(var _=this.tryEntries.length-1;_>=0;--_){var R=this.tryEntries[_],E=R.completion;if(R.tryLoc==="root")return m("end");if(R.tryLoc<=this.prev){var M=a.call(R,"catchLoc"),B=a.call(R,"finallyLoc");if(M&&B){if(this.prev<R.catchLoc)return m(R.catchLoc,!0);if(this.prev<R.finallyLoc)return m(R.finallyLoc)}else if(M){if(this.prev<R.catchLoc)return m(R.catchLoc,!0)}else{if(!B)throw new Error("try statement without catch or finally");if(this.prev<R.finallyLoc)return m(R.finallyLoc)}}}},abrupt:function(D,d){for(var m=this.tryEntries.length-1;m>=0;--m){var _=this.tryEntries[m];if(_.tryLoc<=this.prev&&a.call(_,"finallyLoc")&&this.prev<_.finallyLoc){var R=_;break}}R&&(D==="break"||D==="continue")&&R.tryLoc<=d&&d<=R.finallyLoc&&(R=null);var E=R?R.completion:{};return E.type=D,E.arg=d,R?(this.method="next",this.next=R.finallyLoc,T):this.complete(E)},complete:function(D,d){if(D.type==="throw")throw D.arg;return D.type==="break"||D.type==="continue"?this.next=D.arg:D.type==="return"?(this.rval=this.arg=D.arg,this.method="return",this.next="end"):D.type==="normal"&&d&&(this.next=d),T},finish:function(D){for(var d=this.tryEntries.length-1;d>=0;--d){var m=this.tryEntries[d];if(m.finallyLoc===D)return this.complete(m.completion,m.afterLoc),L(m),T}},catch:function(D){for(var d=this.tryEntries.length-1;d>=0;--d){var m=this.tryEntries[d];if(m.tryLoc===D){var _=m.completion;if(_.type==="throw"){var R=_.arg;L(m)}return R}}throw new Error("illegal catch attempt")},delegateYield:function(D,d,m){return this.delegate={iterator:z(D),resultName:d,nextLoc:m},this.method==="next"&&(this.arg=n),T}},s}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports}),QL=ee((t,e)=>{W();var r=JL()();e.exports=r;try{regeneratorRuntime=r}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}}),eP=ee((t,e)=>{"use strict";W();var r=(i,...n)=>new Promise(s=>{s(i(...n))});e.exports=r,e.exports.default=r}),tP=ee((t,e)=>{"use strict";W();var r=eP(),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()()},l=(f,h,...p)=>{o++;let g=r(f,...p);h(g),g.then(a,a)},c=(f,h,...p)=>{o<n?l(f,h,...p):s.push(l.bind(null,f,h,...p))},u=(f,...h)=>new Promise(p=>c(f,p,...h));return Object.defineProperties(u,{activeCount:{get:()=>o},pendingCount:{get:()=>s.length},clearQueue:{value:()=>{s.length=0}}}),u};e.exports=i,e.exports.default=i}),rP=ee((t,e)=>{"use strict";W();var r=tP(),i=class extends Error{constructor(a){super(),this.value=a}},n=async(a,l)=>l(await a),s=async a=>{let l=await Promise.all(a);if(l[1]===!0)throw new i(l[0]);return!1},o=async(a,l,c)=>{c={concurrency:1/0,preserveOrder:!0,...c};let u=r(c.concurrency),f=[...a].map(p=>[p,u(n,p,l)]),h=r(c.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}),iP=ee((t,e)=>{"use strict";W();var r=te("path"),i=te("fs"),{promisify:n}=te("util"),s=rP(),o=n(i.stat),a=n(i.lstat),l={directory:"isDirectory",file:"isFile"};function c({type:f}){if(!(f in l))throw new Error(`Invalid type specified: ${f}`)}var u=(f,h)=>f===void 0||h[l[f]]();e.exports=async(f,h)=>{h={cwd:process.cwd(),type:"file",allowSymlinks:!0,...h},c(h);let p=h.allowSymlinks?o:a;return s(f,async g=>{try{let y=await p(r.resolve(h.cwd,g));return u(h.type,y)}catch{return!1}},h)},e.exports.sync=(f,h)=>{h={cwd:process.cwd(),allowSymlinks:!0,type:"file",...h},c(h);let p=h.allowSymlinks?i.statSync:i.lstatSync;for(let g of f)try{let y=p(r.resolve(h.cwd,g));if(u(h.type,y))return g}catch{}}}),nP=ee((t,e)=>{"use strict";W();var r=te("fs"),{promisify:i}=te("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}}}),sP=ee((t,e)=>{"use strict";W();var r=te("path"),i=iP(),n=nP(),s=Symbol("findUp.stop");e.exports=async(o,a={})=>{let l=r.resolve(a.cwd||""),{root:c}=r.parse(l),u=[].concat(o),f=async h=>{if(typeof o!="function")return i(u,h);let p=await o(h.cwd);return typeof p=="string"?i([p],h):p};for(;;){let h=await f({...a,cwd:l});if(h===s)return;if(h)return r.resolve(l,h);if(l===c)return;l=r.dirname(l)}},e.exports.sync=(o,a={})=>{let l=r.resolve(a.cwd||""),{root:c}=r.parse(l),u=[].concat(o),f=h=>{if(typeof o!="function")return i.sync(u,h);let p=o(h.cwd);return typeof p=="string"?i.sync([p],h):p};for(;;){let h=f({...a,cwd:l});if(h===s)return;if(h)return r.resolve(l,h);if(l===c)return;l=r.dirname(l)}},e.exports.exists=n,e.exports.sync.exists=n.sync,e.exports.stop=s}),Xn=ee((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)):{}}),Bh=ee((t,e)=>{"use strict";W();var r=typeof process=="object"&&process?process:{stdout:null,stderr:null},i=te("events"),n=te("stream"),s=te("string_decoder").StringDecoder,o=Symbol("EOF"),a=Symbol("maybeEmitEnd"),l=Symbol("emittedEnd"),c=Symbol("emittingEnd"),u=Symbol("emittedError"),f=Symbol("closed"),h=Symbol("read"),p=Symbol("flush"),g=Symbol("flushChunk"),y=Symbol("encoding"),b=Symbol("decoder"),x=Symbol("flowing"),k=Symbol("paused"),C=Symbol("resume"),T=Symbol("buffer"),O=Symbol("pipes"),I=Symbol("bufferLength"),w=Symbol("bufferPush"),v=Symbol("bufferShift"),F=Symbol("objectMode"),q=Symbol("destroyed"),P=Symbol("emitData"),U=Symbol("emitEnd"),K=Symbol("emitEnd2"),V=Symbol("async"),N=R=>Promise.resolve().then(R),A=global._MP_NO_ITERATOR_SYMBOLS_!=="1",L=A&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),j=A&&Symbol.iterator||Symbol("iterator not implemented"),z=R=>R==="end"||R==="finish"||R==="prefinish",D=R=>R instanceof ArrayBuffer||typeof R=="object"&&R.constructor&&R.constructor.name==="ArrayBuffer"&&R.byteLength>=0,d=R=>!Buffer.isBuffer(R)&&ArrayBuffer.isView(R),m=class{constructor(R,E,M){this.src=R,this.dest=E,this.opts=M,this.ondrain=()=>R[C](),E.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},_=class extends m{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(R,E,M){super(R,E,M),this.proxyErrors=B=>E.emit("error",B),R.on("error",this.proxyErrors)}};e.exports=class Qw extends n{constructor(E){super(),this[x]=!1,this[k]=!1,this[O]=[],this[T]=[],this[F]=E&&E.objectMode||!1,this[F]?this[y]=null:this[y]=E&&E.encoding||null,this[y]==="buffer"&&(this[y]=null),this[V]=E&&!!E.async||!1,this[b]=this[y]?new s(this[y]):null,this[o]=!1,this[l]=!1,this[c]=!1,this[f]=!1,this[u]=null,this.writable=!0,this.readable=!0,this[I]=0,this[q]=!1,E&&E.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[T]}),E&&E.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[O]})}get bufferLength(){return this[I]}get encoding(){return this[y]}set encoding(E){if(this[F])throw new Error("cannot set encoding in objectMode");if(this[y]&&E!==this[y]&&(this[b]&&this[b].lastNeed||this[I]))throw new Error("cannot change encoding");this[y]!==E&&(this[b]=E?new s(E):null,this[T].length&&(this[T]=this[T].map(M=>this[b].write(M)))),this[y]=E}setEncoding(E){this.encoding=E}get objectMode(){return this[F]}set objectMode(E){this[F]=this[F]||!!E}get async(){return this[V]}set async(E){this[V]=this[V]||!!E}write(E,M,B){if(this[o])throw new Error("write after end");if(this[q])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof M=="function"&&(B=M,M="utf8"),M||(M="utf8");let Z=this[V]?N:H=>H();return!this[F]&&!Buffer.isBuffer(E)&&(d(E)?E=Buffer.from(E.buffer,E.byteOffset,E.byteLength):D(E)?E=Buffer.from(E):typeof E!="string"&&(this.objectMode=!0)),this[F]?(this.flowing&&this[I]!==0&&this[p](!0),this.flowing?this.emit("data",E):this[w](E),this[I]!==0&&this.emit("readable"),B&&Z(B),this.flowing):E.length?(typeof E=="string"&&!(M===this[y]&&!this[b].lastNeed)&&(E=Buffer.from(E,M)),Buffer.isBuffer(E)&&this[y]&&(E=this[b].write(E)),this.flowing&&this[I]!==0&&this[p](!0),this.flowing?this.emit("data",E):this[w](E),this[I]!==0&&this.emit("readable"),B&&Z(B),this.flowing):(this[I]!==0&&this.emit("readable"),B&&Z(B),this.flowing)}read(E){if(this[q])return null;if(this[I]===0||E===0||E>this[I])return this[a](),null;this[F]&&(E=null),this[T].length>1&&!this[F]&&(this.encoding?this[T]=[this[T].join("")]:this[T]=[Buffer.concat(this[T],this[I])]);let M=this[h](E||null,this[T][0]);return this[a](),M}[h](E,M){return E===M.length||E===null?this[v]():(this[T][0]=M.slice(E),M=M.slice(0,E),this[I]-=E),this.emit("data",M),!this[T].length&&!this[o]&&this.emit("drain"),M}end(E,M,B){return typeof E=="function"&&(B=E,E=null),typeof M=="function"&&(B=M,M="utf8"),E&&this.write(E,M),B&&this.once("end",B),this[o]=!0,this.writable=!1,(this.flowing||!this[k])&&this[a](),this}[C](){this[q]||(this[k]=!1,this[x]=!0,this.emit("resume"),this[T].length?this[p]():this[o]?this[a]():this.emit("drain"))}resume(){return this[C]()}pause(){this[x]=!1,this[k]=!0}get destroyed(){return this[q]}get flowing(){return this[x]}get paused(){return this[k]}[w](E){this[F]?this[I]+=1:this[I]+=E.length,this[T].push(E)}[v](){return this[T].length&&(this[F]?this[I]-=1:this[I]-=this[T][0].length),this[T].shift()}[p](E){do;while(this[g](this[v]()));!E&&!this[T].length&&!this[o]&&this.emit("drain")}[g](E){return E?(this.emit("data",E),this.flowing):!1}pipe(E,M){if(this[q])return;let B=this[l];return M=M||{},E===r.stdout||E===r.stderr?M.end=!1:M.end=M.end!==!1,M.proxyErrors=!!M.proxyErrors,B?M.end&&E.end():(this[O].push(M.proxyErrors?new _(this,E,M):new m(this,E,M)),this[V]?N(()=>this[C]()):this[C]()),E}unpipe(E){let M=this[O].find(B=>B.dest===E);M&&(this[O].splice(this[O].indexOf(M),1),M.unpipe())}addListener(E,M){return this.on(E,M)}on(E,M){let B=super.on(E,M);return E==="data"&&!this[O].length&&!this.flowing?this[C]():E==="readable"&&this[I]!==0?super.emit("readable"):z(E)&&this[l]?(super.emit(E),this.removeAllListeners(E)):E==="error"&&this[u]&&(this[V]?N(()=>M.call(this,this[u])):M.call(this,this[u])),B}get emittedEnd(){return this[l]}[a](){!this[c]&&!this[l]&&!this[q]&&this[T].length===0&&this[o]&&(this[c]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[f]&&this.emit("close"),this[c]=!1)}emit(E,M,...B){if(E!=="error"&&E!=="close"&&E!==q&&this[q])return;if(E==="data")return M?this[V]?N(()=>this[P](M)):this[P](M):!1;if(E==="end")return this[U]();if(E==="close"){if(this[f]=!0,!this[l]&&!this[q])return;let H=super.emit("close");return this.removeAllListeners("close"),H}else if(E==="error"){this[u]=M;let H=super.emit("error",M);return this[a](),H}else if(E==="resume"){let H=super.emit("resume");return this[a](),H}else if(E==="finish"||E==="prefinish"){let H=super.emit(E);return this.removeAllListeners(E),H}let Z=super.emit(E,M,...B);return this[a](),Z}[P](E){for(let B of this[O])B.dest.write(E)===!1&&this.pause();let M=super.emit("data",E);return this[a](),M}[U](){this[l]||(this[l]=!0,this.readable=!1,this[V]?N(()=>this[K]()):this[K]())}[K](){if(this[b]){let M=this[b].end();if(M){for(let B of this[O])B.dest.write(M);super.emit("data",M)}}for(let M of this[O])M.end();let E=super.emit("end");return this.removeAllListeners("end"),E}collect(){let E=[];this[F]||(E.dataLength=0);let M=this.promise();return this.on("data",B=>{E.push(B),this[F]||(E.dataLength+=B.length)}),M.then(()=>E)}concat(){return this[F]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(E=>this[F]?Promise.reject(new Error("cannot concat in objectMode")):this[y]?E.join(""):Buffer.concat(E,E.dataLength))}promise(){return new Promise((E,M)=>{this.on(q,()=>M(new Error("stream destroyed"))),this.on("error",B=>M(B)),this.on("end",()=>E())})}[L](){return{next:()=>{let E=this.read();if(E!==null)return Promise.resolve({done:!1,value:E});if(this[o])return Promise.resolve({done:!0});let M=null,B=null,Z=re=>{this.removeListener("data",H),this.removeListener("end",J),B(re)},H=re=>{this.removeListener("error",Z),this.removeListener("end",J),this.pause(),M({value:re,done:!!this[o]})},J=()=>{this.removeListener("error",Z),this.removeListener("data",H),M({done:!0})},G=()=>Z(new Error("stream destroyed"));return new Promise((re,ue)=>{B=ue,M=re,this.once(q,G),this.once("error",Z),this.once("end",J),this.once("data",H)})}}}[j](){return{next:()=>{let E=this.read();return{value:E,done:E===null}}}}destroy(E){return this[q]?(E?this.emit("error",E):this.emit(q),this):(this[q]=!0,this[T].length=0,this[I]=0,typeof this.close=="function"&&!this[f]&&this.close(),E?this.emit("error",E):this.emit(q),this)}static isStream(E){return!!E&&(E instanceof Qw||E instanceof n||E instanceof i&&(typeof E.pipe=="function"||typeof E.write=="function"&&typeof E.end=="function"))}}}),oP=ee((t,e)=>{W();var r=te("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))}),eS=ee((t,e)=>{"use strict";W();var r=typeof process=="object"&&process?process:{stdout:null,stderr:null},i=te("events"),n=te("stream"),s=te("string_decoder").StringDecoder,o=Symbol("EOF"),a=Symbol("maybeEmitEnd"),l=Symbol("emittedEnd"),c=Symbol("emittingEnd"),u=Symbol("emittedError"),f=Symbol("closed"),h=Symbol("read"),p=Symbol("flush"),g=Symbol("flushChunk"),y=Symbol("encoding"),b=Symbol("decoder"),x=Symbol("flowing"),k=Symbol("paused"),C=Symbol("resume"),T=Symbol("bufferLength"),O=Symbol("bufferPush"),I=Symbol("bufferShift"),w=Symbol("objectMode"),v=Symbol("destroyed"),F=Symbol("emitData"),q=Symbol("emitEnd"),P=Symbol("emitEnd2"),U=Symbol("async"),K=m=>Promise.resolve().then(m),V=global._MP_NO_ITERATOR_SYMBOLS_!=="1",N=V&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),A=V&&Symbol.iterator||Symbol("iterator not implemented"),L=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),D=class{constructor(m,_,R){this.src=m,this.dest=_,this.opts=R,this.ondrain=()=>m[C](),_.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},d=class extends D{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(m,_,R){super(m,_,R),this.proxyErrors=E=>_.emit("error",E),m.on("error",this.proxyErrors)}};e.exports=class tS extends n{constructor(_){super(),this[x]=!1,this[k]=!1,this.pipes=[],this.buffer=[],this[w]=_&&_.objectMode||!1,this[w]?this[y]=null:this[y]=_&&_.encoding||null,this[y]==="buffer"&&(this[y]=null),this[U]=_&&!!_.async||!1,this[b]=this[y]?new s(this[y]):null,this[o]=!1,this[l]=!1,this[c]=!1,this[f]=!1,this[u]=null,this.writable=!0,this.readable=!0,this[T]=0,this[v]=!1}get bufferLength(){return this[T]}get encoding(){return this[y]}set encoding(_){if(this[w])throw new Error("cannot set encoding in objectMode");if(this[y]&&_!==this[y]&&(this[b]&&this[b].lastNeed||this[T]))throw new Error("cannot change encoding");this[y]!==_&&(this[b]=_?new s(_):null,this.buffer.length&&(this.buffer=this.buffer.map(R=>this[b].write(R)))),this[y]=_}setEncoding(_){this.encoding=_}get objectMode(){return this[w]}set objectMode(_){this[w]=this[w]||!!_}get async(){return this[U]}set async(_){this[U]=this[U]||!!_}write(_,R,E){if(this[o])throw new Error("write after end");if(this[v])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof R=="function"&&(E=R,R="utf8"),R||(R="utf8");let M=this[U]?K:B=>B();return!this[w]&&!Buffer.isBuffer(_)&&(z(_)?_=Buffer.from(_.buffer,_.byteOffset,_.byteLength):j(_)?_=Buffer.from(_):typeof _!="string"&&(this.objectMode=!0)),this[w]?(this.flowing&&this[T]!==0&&this[p](!0),this.flowing?this.emit("data",_):this[O](_),this[T]!==0&&this.emit("readable"),E&&M(E),this.flowing):_.length?(typeof _=="string"&&!(R===this[y]&&!this[b].lastNeed)&&(_=Buffer.from(_,R)),Buffer.isBuffer(_)&&this[y]&&(_=this[b].write(_)),this.flowing&&this[T]!==0&&this[p](!0),this.flowing?this.emit("data",_):this[O](_),this[T]!==0&&this.emit("readable"),E&&M(E),this.flowing):(this[T]!==0&&this.emit("readable"),E&&M(E),this.flowing)}read(_){if(this[v])return null;if(this[T]===0||_===0||_>this[T])return this[a](),null;this[w]&&(_=null),this.buffer.length>1&&!this[w]&&(this.encoding?this.buffer=[this.buffer.join("")]:this.buffer=[Buffer.concat(this.buffer,this[T])]);let R=this[h](_||null,this.buffer[0]);return this[a](),R}[h](_,R){return _===R.length||_===null?this[I]():(this.buffer[0]=R.slice(_),R=R.slice(0,_),this[T]-=_),this.emit("data",R),!this.buffer.length&&!this[o]&&this.emit("drain"),R}end(_,R,E){return typeof _=="function"&&(E=_,_=null),typeof R=="function"&&(E=R,R="utf8"),_&&this.write(_,R),E&&this.once("end",E),this[o]=!0,this.writable=!1,(this.flowing||!this[k])&&this[a](),this}[C](){this[v]||(this[k]=!1,this[x]=!0,this.emit("resume"),this.buffer.length?this[p]():this[o]?this[a]():this.emit("drain"))}resume(){return this[C]()}pause(){this[x]=!1,this[k]=!0}get destroyed(){return this[v]}get flowing(){return this[x]}get paused(){return this[k]}[O](_){this[w]?this[T]+=1:this[T]+=_.length,this.buffer.push(_)}[I](){return this.buffer.length&&(this[w]?this[T]-=1:this[T]-=this.buffer[0].length),this.buffer.shift()}[p](_){do;while(this[g](this[I]()));!_&&!this.buffer.length&&!this[o]&&this.emit("drain")}[g](_){return _?(this.emit("data",_),this.flowing):!1}pipe(_,R){if(this[v])return;let E=this[l];return R=R||{},_===r.stdout||_===r.stderr?R.end=!1:R.end=R.end!==!1,R.proxyErrors=!!R.proxyErrors,E?R.end&&_.end():(this.pipes.push(R.proxyErrors?new d(this,_,R):new D(this,_,R)),this[U]?K(()=>this[C]()):this[C]()),_}unpipe(_){let R=this.pipes.find(E=>E.dest===_);R&&(this.pipes.splice(this.pipes.indexOf(R),1),R.unpipe())}addListener(_,R){return this.on(_,R)}on(_,R){let E=super.on(_,R);return _==="data"&&!this.pipes.length&&!this.flowing?this[C]():_==="readable"&&this[T]!==0?super.emit("readable"):L(_)&&this[l]?(super.emit(_),this.removeAllListeners(_)):_==="error"&&this[u]&&(this[U]?K(()=>R.call(this,this[u])):R.call(this,this[u])),E}get emittedEnd(){return this[l]}[a](){!this[c]&&!this[l]&&!this[v]&&this.buffer.length===0&&this[o]&&(this[c]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[f]&&this.emit("close"),this[c]=!1)}emit(_,R,...E){if(_!=="error"&&_!=="close"&&_!==v&&this[v])return;if(_==="data")return R?this[U]?K(()=>this[F](R)):this[F](R):!1;if(_==="end")return this[q]();if(_==="close"){if(this[f]=!0,!this[l]&&!this[v])return;let B=super.emit("close");return this.removeAllListeners("close"),B}else if(_==="error"){this[u]=R;let B=super.emit("error",R);return this[a](),B}else if(_==="resume"){let B=super.emit("resume");return this[a](),B}else if(_==="finish"||_==="prefinish"){let B=super.emit(_);return this.removeAllListeners(_),B}let M=super.emit(_,R,...E);return this[a](),M}[F](_){for(let E of this.pipes)E.dest.write(_)===!1&&this.pause();let R=super.emit("data",_);return this[a](),R}[q](){this[l]||(this[l]=!0,this.readable=!1,this[U]?K(()=>this[P]()):this[P]())}[P](){if(this[b]){let R=this[b].end();if(R){for(let E of this.pipes)E.dest.write(R);super.emit("data",R)}}for(let R of this.pipes)R.end();let _=super.emit("end");return this.removeAllListeners("end"),_}collect(){let _=[];this[w]||(_.dataLength=0);let R=this.promise();return this.on("data",E=>{_.push(E),this[w]||(_.dataLength+=E.length)}),R.then(()=>_)}concat(){return this[w]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(_=>this[w]?Promise.reject(new Error("cannot concat in objectMode")):this[y]?_.join(""):Buffer.concat(_,_.dataLength))}promise(){return new Promise((_,R)=>{this.on(v,()=>R(new Error("stream destroyed"))),this.on("error",E=>R(E)),this.on("end",()=>_())})}[N](){return{next:()=>{let _=this.read();if(_!==null)return Promise.resolve({done:!1,value:_});if(this[o])return Promise.resolve({done:!0});let R=null,E=null,M=J=>{this.removeListener("data",B),this.removeListener("end",Z),E(J)},B=J=>{this.removeListener("error",M),this.removeListener("end",Z),this.pause(),R({value:J,done:!!this[o]})},Z=()=>{this.removeListener("error",M),this.removeListener("data",B),R({done:!0})},H=()=>M(new Error("stream destroyed"));return new Promise((J,G)=>{E=G,R=J,this.once(v,H),this.once("error",M),this.once("end",Z),this.once("data",B)})}}}[A](){return{next:()=>{let _=this.read();return{value:_,done:_===null}}}}destroy(_){return this[v]?(_?this.emit("error",_):this.emit(v),this):(this[v]=!0,this.buffer.length=0,this[T]=0,typeof this.close=="function"&&!this[f]&&this.close(),_?this.emit("error",_):this.emit(v),this)}static isStream(_){return!!_&&(_ instanceof tS||_ instanceof n||_ instanceof i&&(typeof _.pipe=="function"||typeof _.write=="function"&&typeof _.end=="function"))}}}),rS=ee(t=>{"use strict";W();var e=te("assert"),r=te("buffer").Buffer,i=te("zlib"),n=t.constants=oP(),s=eS(),o=r.concat,a=Symbol("_superWrite"),l=class extends Error{constructor(L){super("zlib: "+L.message),this.code=L.code,this.errno=L.errno,this.code||(this.code="ZLIB_ERROR"),this.message="zlib: "+L.message,Error.captureStackTrace(this,this.constructor)}get name(){return"ZlibError"}},c=Symbol("opts"),u=Symbol("flushFlag"),f=Symbol("finishFlushFlag"),h=Symbol("fullFlushFlag"),p=Symbol("handle"),g=Symbol("onError"),y=Symbol("sawError"),b=Symbol("level"),x=Symbol("strategy"),k=Symbol("ended"),C=Symbol("_defaultFullFlush"),T=class extends s{constructor(L,j){if(!L||typeof L!="object")throw new TypeError("invalid options for ZlibBase constructor");super(L),this[y]=!1,this[k]=!1,this[c]=L,this[u]=L.flush,this[f]=L.finishFlush;try{this[p]=new i[j](L)}catch(z){throw new l(z)}this[g]=z=>{this[y]||(this[y]=!0,this.close(),this.emit("error",z))},this[p].on("error",z=>this[g](new l(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(L){this.ended||(typeof L!="number"&&(L=this[h]),this.write(Object.assign(r.alloc(0),{[u]:L})))}end(L,j,z){return L&&this.write(L,j),this.flush(this[f]),this[k]=!0,super.end(null,null,z)}get ended(){return this[k]}write(L,j,z){if(typeof j=="function"&&(z=j,j="utf8"),typeof L=="string"&&(L=r.from(L,j)),this[y])return;e(this[p],"zlib binding closed");let D=this[p]._handle,d=D.close;D.close=()=>{};let m=this[p].close;this[p].close=()=>{},r.concat=E=>E;let _;try{let E=typeof L[u]=="number"?L[u]:this[u];_=this[p]._processChunk(L,E),r.concat=o}catch(E){r.concat=o,this[g](new l(E))}finally{this[p]&&(this[p]._handle=D,D.close=d,this[p].close=m,this[p].removeAllListeners("error"))}this[p]&&this[p].on("error",E=>this[g](new l(E)));let R;if(_)if(Array.isArray(_)&&_.length>0){R=this[a](r.from(_[0]));for(let E=1;E<_.length;E++)R=this[a](_[E])}else R=this[a](r.from(_));return z&&z(),R}[a](L){return super.write(L)}},O=class extends T{constructor(L,j){L=L||{},L.flush=L.flush||n.Z_NO_FLUSH,L.finishFlush=L.finishFlush||n.Z_FINISH,super(L,j),this[h]=n.Z_FULL_FLUSH,this[b]=L.level,this[x]=L.strategy}params(L,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[b]!==L||this[x]!==j){this.flush(n.Z_SYNC_FLUSH),e(this[p],"zlib binding closed");let z=this[p].flush;this[p].flush=(D,d)=>{this.flush(D),d()};try{this[p].params(L,j)}finally{this[p].flush=z}this[p]&&(this[b]=L,this[x]=j)}}}},I=class extends O{constructor(L){super(L,"Deflate")}},w=class extends O{constructor(L){super(L,"Inflate")}},v=Symbol("_portable"),F=class extends O{constructor(L){super(L,"Gzip"),this[v]=L&&!!L.portable}[a](L){return this[v]?(this[v]=!1,L[9]=255,super[a](L)):super[a](L)}},q=class extends O{constructor(L){super(L,"Gunzip")}},P=class extends O{constructor(L){super(L,"DeflateRaw")}},U=class extends O{constructor(L){super(L,"InflateRaw")}},K=class extends O{constructor(L){super(L,"Unzip")}},V=class extends T{constructor(L,j){L=L||{},L.flush=L.flush||n.BROTLI_OPERATION_PROCESS,L.finishFlush=L.finishFlush||n.BROTLI_OPERATION_FINISH,super(L,j),this[h]=n.BROTLI_OPERATION_FLUSH}},N=class extends V{constructor(L){super(L,"BrotliCompress")}},A=class extends V{constructor(L){super(L,"BrotliDecompress")}};t.Deflate=I,t.Inflate=w,t.Gzip=F,t.Gunzip=q,t.DeflateRaw=P,t.InflateRaw=U,t.Unzip=K,typeof i.BrotliCompress=="function"?(t.BrotliCompress=N,t.BrotliDecompress=A):t.BrotliCompress=t.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}}),Jn=ee((t,e)=>{W();var r=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform;e.exports=r!=="win32"?i=>i:i=>i&&i.replace(/\\/g,"/")}),jh=ee((t,e)=>{"use strict";W();var r=Bh(),i=Jn(),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,l=this.blockRemain;return this.remain=Math.max(0,a-o),this.blockRemain=Math.max(0,l-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])}}}),iS=ee(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]]))}),aP=ee((t,e)=>{"use strict";W();var r=(u,f)=>{if(Number.isSafeInteger(u))u<0?n(u,f):i(u,f);else throw Error("cannot encode number outside of javascript safe integer range");return f},i=(u,f)=>{f[0]=128;for(var h=f.length;h>1;h--)f[h-1]=u&255,u=Math.floor(u/256)},n=(u,f)=>{f[0]=255;var h=!1;u=u*-1;for(var p=f.length;p>1;p--){var g=u&255;u=Math.floor(u/256),h?f[p-1]=l(g):g===0?f[p-1]=0:(h=!0,f[p-1]=c(g))}},s=u=>{let f=u[0],h=f===128?a(u.slice(1,u.length)):f===255?o(u):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=u=>{for(var f=u.length,h=0,p=!1,g=f-1;g>-1;g--){var y=u[g],b;p?b=l(y):y===0?b=y:(p=!0,b=c(y)),b!==0&&(h-=b*Math.pow(256,f-g-1))}return h},a=u=>{for(var f=u.length,h=0,p=f-1;p>-1;p--){var g=u[p];g!==0&&(h+=g*Math.pow(256,f-p-1))}return h},l=u=>(255^u)&255,c=u=>(255^u)+1&255;e.exports={encode:r,parse:s}}),Qn=ee((t,e)=>{"use strict";W();var r=iS(),i=te("path").posix,n=aP(),s=Symbol("slurp"),o=Symbol("type"),a=class{constructor(w,v,F,q){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(w)?this.decode(w,v||0,F,q):w&&this.set(w)}decode(w,v,F,q){if(v||(v=0),!w||!(w.length>=v+512))throw new Error("need 512 bytes for header");if(this.path=c(w,v,100),this.mode=h(w,v+100,8),this.uid=h(w,v+108,8),this.gid=h(w,v+116,8),this.size=h(w,v+124,12),this.mtime=u(w,v+136,12),this.cksum=h(w,v+148,12),this[s](F),this[s](q,!0),this[o]=c(w,v+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=c(w,v+157,100),w.slice(v+257,v+265).toString()==="ustar\x0000")if(this.uname=c(w,v+265,32),this.gname=c(w,v+297,32),this.devmaj=h(w,v+329,8),this.devmin=h(w,v+337,8),w[v+475]!==0){let U=c(w,v+345,155);this.path=U+"/"+this.path}else{let U=c(w,v+345,130);U&&(this.path=U+"/"+this.path),this.atime=u(w,v+476,12),this.ctime=u(w,v+488,12)}let P=8*32;for(let U=v;U<v+148;U++)P+=w[U];for(let U=v+156;U<v+512;U++)P+=w[U];this.cksumValid=P===this.cksum,this.cksum===null&&P===8*32&&(this.nullBlock=!0)}[s](w,v){for(let F in w)w[F]!==null&&w[F]!==void 0&&!(v&&F==="path")&&(this[F]=w[F])}encode(w,v){if(w||(w=this.block=Buffer.alloc(512),v=0),v||(v=0),!(w.length>=v+512))throw new Error("need 512 bytes for header");let F=this.ctime||this.atime?130:155,q=l(this.path||"",F),P=q[0],U=q[1];this.needPax=q[2],this.needPax=I(w,v,100,P)||this.needPax,this.needPax=b(w,v+100,8,this.mode)||this.needPax,this.needPax=b(w,v+108,8,this.uid)||this.needPax,this.needPax=b(w,v+116,8,this.gid)||this.needPax,this.needPax=b(w,v+124,12,this.size)||this.needPax,this.needPax=T(w,v+136,12,this.mtime)||this.needPax,w[v+156]=this[o].charCodeAt(0),this.needPax=I(w,v+157,100,this.linkpath)||this.needPax,w.write("ustar\x0000",v+257,8),this.needPax=I(w,v+265,32,this.uname)||this.needPax,this.needPax=I(w,v+297,32,this.gname)||this.needPax,this.needPax=b(w,v+329,8,this.devmaj)||this.needPax,this.needPax=b(w,v+337,8,this.devmin)||this.needPax,this.needPax=I(w,v+345,F,U)||this.needPax,w[v+475]!==0?this.needPax=I(w,v+345,155,U)||this.needPax:(this.needPax=I(w,v+345,130,U)||this.needPax,this.needPax=T(w,v+476,12,this.atime)||this.needPax,this.needPax=T(w,v+488,12,this.ctime)||this.needPax);let K=8*32;for(let V=v;V<v+148;V++)K+=w[V];for(let V=v+156;V<v+512;V++)K+=w[V];return this.cksum=K,b(w,v+148,8,this.cksum),this.cksumValid=!0,this.needPax}set(w){for(let v in w)w[v]!==null&&w[v]!==void 0&&(this[v]=w[v])}get type(){return r.name.get(this[o])||this[o]}get typeKey(){return this[o]}set type(w){r.code.has(w)?this[o]=r.code.get(w):this[o]=w}},l=(w,v)=>{let F=w,q="",P,U=i.parse(w).root||".";if(Buffer.byteLength(F)<100)P=[F,q,!1];else{q=i.dirname(F),F=i.basename(F);do Buffer.byteLength(F)<=100&&Buffer.byteLength(q)<=v?P=[F,q,!1]:Buffer.byteLength(F)>100&&Buffer.byteLength(q)<=v?P=[F.slice(0,100-1),q,!0]:(F=i.join(i.basename(q),F),q=i.dirname(q));while(q!==U&&!P);P||(P=[w.slice(0,100-1),"",!0])}return P},c=(w,v,F)=>w.slice(v,v+F).toString("utf8").replace(/\0.*/,""),u=(w,v,F)=>f(h(w,v,F)),f=w=>w===null?null:new Date(w*1e3),h=(w,v,F)=>w[v]&128?n.parse(w.slice(v,v+F)):g(w,v,F),p=w=>isNaN(w)?null:w,g=(w,v,F)=>p(parseInt(w.slice(v,v+F).toString("utf8").replace(/\0.*$/,"").trim(),8)),y={12:8589934591,8:2097151},b=(w,v,F,q)=>q===null?!1:q>y[F]||q<0?(n.encode(q,w.slice(v,v+F)),!0):(x(w,v,F,q),!1),x=(w,v,F,q)=>w.write(k(q,F),v,F,"ascii"),k=(w,v)=>C(Math.floor(w).toString(8),v),C=(w,v)=>(w.length===v-1?w:new Array(v-w.length-1).join("0")+w+" ")+"\0",T=(w,v,F,q)=>q===null?!1:b(w,v,F,q.getTime()/1e3),O=new Array(156).join("\0"),I=(w,v,F,q)=>q===null?!1:(w.write(q+O,v,F,"utf8"),q.length!==Buffer.byteLength(q)||q.length>F);e.exports=a}),$h=ee((t,e)=>{"use strict";W();var r=Qn(),i=te("path"),n=class{constructor(l,c){this.atime=l.atime||null,this.charset=l.charset||null,this.comment=l.comment||null,this.ctime=l.ctime||null,this.gid=l.gid||null,this.gname=l.gname||null,this.linkpath=l.linkpath||null,this.mtime=l.mtime||null,this.path=l.path||null,this.size=l.size||null,this.uid=l.uid||null,this.uname=l.uname||null,this.dev=l.dev||null,this.ino=l.ino||null,this.nlink=l.nlink||null,this.global=c||!1}encode(){let l=this.encodeBody();if(l==="")return null;let c=Buffer.byteLength(l),u=512*Math.ceil(1+c/512),f=Buffer.allocUnsafe(u);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:c,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(l,512,c,"utf8");for(let h=c+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(l){if(this[l]===null||this[l]===void 0)return"";let c=this[l]instanceof Date?this[l].getTime()/1e3:this[l],u=" "+(l==="dev"||l==="ino"||l==="nlink"?"SCHILY.":"")+l+"="+c+`
|
40
|
+
`:""}var y0=g0,b0={dump:y0};function Ga(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 _0=Le,w0=Rf,S0=Tf,E0=If,v0=Nf,R0=$a,x0=Xf.load,A0=Xf.loadAll,O0=b0.dump,T0=He,k0={binary:jf,float:Pf,map:Of,null:kf,pairs:qf,set:Hf,timestamp:Ff,bool:Cf,int:Lf,merge:Bf,omap:$f,seq:Af,str:xf},C0=Ga("safeLoad","load"),L0=Ga("safeLoadAll","loadAll"),P0=Ga("safeDump","dump"),I0={Type:_0,Schema:w0,FAILSAFE_SCHEMA:S0,JSON_SCHEMA:E0,CORE_SCHEMA:v0,DEFAULT_SCHEMA:R0,load:x0,loadAll:A0,dump:O0,YAMLException:T0,types:k0,safeLoad:C0,safeLoadAll:L0,safeDump:P0},za=I0;var VO=ie(qs()),KO=ie(require("json5"));var ne={};oE(ne,{bold:()=>jO,dimmed:()=>qO,error:()=>ig,grey:()=>HO,info:()=>BO,item:()=>UO,log:()=>mr,turboBlue:()=>Ei,turboGradient:()=>FO,turboLoader:()=>tg,turboRed:()=>Qm,underline:()=>$O,warn:()=>rg,yellow:()=>eg});var We=require("picocolors"),Km=ie(require("ora")),Zm=ie(require("gradient-string")),Xm="#0099F7",Jm="#F11712",MO="#FFFF00",Oc=t=>{let e=GO(t);return r=>`\x1B[38;5;${e}m${r}${(0,We.reset)("")}`},FO=(0,Zm.default)(Xm,Jm),Ei=Oc(Xm),Qm=Oc(Jm),eg=Oc(MO),tg=t=>(0,Km.default)({text:t,spinner:{frames:[" ",Ei("> "),Ei(">> "),Ei(">>>")]}}),BO=(...t)=>{mr(Ei((0,We.bold)(">>>")),t.join(" "))},jO=(...t)=>{mr((0,We.bold)(t.join(" ")))},$O=(...t)=>{mr((0,We.underline)(t.join(" ")))},qO=(...t)=>{mr((0,We.dim)(t.join(" ")))},HO=(...t)=>{mr((0,We.gray)(t.join(" ")))},UO=(...t)=>{mr(Ei((0,We.bold)(" \u2022")),t.join(" "))},mr=(...t)=>{console.log(...t)},rg=(...t)=>{console.error(eg((0,We.bold)(">>>")),t.join(" "))},ig=(...t)=>{console.error(Qm((0,We.bold)(">>>")),t.join(" "))};function GO(t){let e=parseInt(t.slice(1),16),r=Math.floor(e/(256*256))%256,i=Math.floor(e/256)%256,n=e%256;return 16+36*Math.round(r/255*5)+6*Math.round(i/255*5)+Math.round(n/255*5)}var $y=ie(require("os")),qy=ie(Li());async function gr(t,e=[],r){let i={cwd:$y.default.tmpdir(),env:{COREPACK_ENABLE_STRICT:"0"},...r};try{let{stdout:n}=await(0,qy.default)(t,e,i);return n.trim()}catch{return}}async function Yc(){let[t,e,r,i]=await Promise.all([gr("yarnpkg",["--version"]),gr("npm",["--version"]),gr("pnpm",["--version"]),gr("bun",["--version"])]);return{yarn:t,pnpm:r,npm:e,bun:i}}async function Vc(){let[t,e,r,i]=await Promise.all([gr("yarnpkg",["global","bin"]),gr("npm",["config","get","prefix"]),gr("pnpm",["bin","--global"]),gr("bun",["pm","--g","bin"])]);return{yarn:t,pnpm:r,npm:e,bun:i}}var Uk=ie(require("fs-extra"));var Gk=ie(require("path")),zk=ie(require("fs-extra")),Wk=require("picocolors");var $w=require("stream"),qw=require("util"),TL=require("path"),kL=require("os"),Hw=require("fs"),CL=ie(jw());var vF=(0,qw.promisify)($w.Stream.pipeline);var Uw=require("fs-extra");var $L=ie(require("path")),qL=ie(Zw()),Xw=require("picocolors"),Nh=require("fs-extra");var eE=require("commander");var aa={name:"@turbo/codemod",version:"2.0.15-canary.2",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/turborepo",directory:"packages/turbo-codemod"},bugs:{url:"https://github.com/vercel/turborepo/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",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",json5:"^2.2.3","is-git-clean":"^1.1.0",ora:"4.1.1",picocolors:"1.0.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/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 ln=ie(require("os")),KS=require("child_process"),Oe=require("picocolors"),ZS=require("inquirer");var Xe=require("picocolors"),fS=ie(require("ora"),1),pS=ie(require("gradient-string"),1);var qP=ie(Li(),1),nB=require("fs-extra");var cB=ie(qs(),1),hB=require("fs-extra"),pB=require("fs-extra"),mB=require("picocolors"),bS=require("stream"),_S=require("util"),_B=require("fs-extra"),vB=require("picocolors"),AB=require("fs-extra"),ii=ie(require("path"),1),Ue=require("fs-extra"),wS=ie(Li(),1),SS=ie(require("path"),1),ES=require("fs-extra"),vS=require("picocolors"),sr=ie(require("path"),1),RS=ie(Li(),1),st=require("fs-extra"),xS=ie(qs(),1);var Kn=ie(require("path"),1),Dt=require("fs-extra"),nn=ie(require("path"),1),Mt=require("fs-extra"),Zn=ie(require("path"),1),Ft=require("fs-extra"),ns=require("picocolors"),EI=ie(require("gradient-string"),1),vI=ie(Li(),1),RI=ie(require("ora"),1),xI=require("semver"),AI=require("picocolors"),UL=Object.create,Fh=Object.defineProperty,GL=Object.getOwnPropertyDescriptor,zL=Object.getOwnPropertyNames,WL=Object.getPrototypeOf,YL=Object.prototype.hasOwnProperty,te=(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')}),VL=(t,e)=>()=>(t&&(e=t(t=0)),e),ee=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),KL=(t,e)=>{for(var r in e)Fh(t,r,{get:e[r],enumerable:!0})},ZL=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of zL(e))!YL.call(t,n)&&n!==r&&Fh(t,n,{get:()=>e[n],enumerable:!(i=GL(e,n))||i.enumerable});return t},ua=(t,e,r)=>(r=t!=null?UL(WL(t)):{},ZL(e||!t||!t.__esModule?Fh(r,"default",{value:t,enumerable:!0}):r,t)),W=VL(()=>{}),XL=ee((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}),JL=ee((t,e)=>{W();var r=XL().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,l=Object.defineProperty||function(D,d,m){D[d]=m.value},c=typeof Symbol=="function"?Symbol:{},u=c.iterator||"@@iterator",f=c.asyncIterator||"@@asyncIterator",h=c.toStringTag||"@@toStringTag";function p(D,d,m){return Object.defineProperty(D,d,{value:m,enumerable:!0,configurable:!0,writable:!0}),D[d]}try{p({},"")}catch{p=function(D,d,m){return D[d]=m}}function g(D,d,m,_){var R=d&&d.prototype instanceof O?d:O,E=Object.create(R.prototype),M=new j(_||[]);return l(E,"_invoke",{value:K(D,m,M)}),E}function y(D,d,m){try{return{type:"normal",arg:D.call(d,m)}}catch(_){return{type:"throw",arg:_}}}s.wrap=g;var b="suspendedStart",x="suspendedYield",k="executing",C="completed",T={};function O(){}function I(){}function w(){}var v={};p(v,u,function(){return this});var F=Object.getPrototypeOf,q=F&&F(F(z([])));q&&q!==o&&a.call(q,u)&&(v=q);var P=w.prototype=O.prototype=Object.create(v);function U(D){["next","throw","return"].forEach(function(d){p(D,d,function(m){return this._invoke(d,m)})})}function V(D,d){function m(R,E,M,B){var Z=y(D[R],D,E);if(Z.type!=="throw"){var H=Z.arg,J=H.value;return J&&r(J)=="object"&&a.call(J,"__await")?d.resolve(J.__await).then(function(G){m("next",G,M,B)},function(G){m("throw",G,M,B)}):d.resolve(J).then(function(G){H.value=G,M(H)},function(G){return m("throw",G,M,B)})}B(Z.arg)}var _;l(this,"_invoke",{value:function(R,E){function M(){return new d(function(B,Z){m(R,E,B,Z)})}return _=_?_.then(M,M):M()}})}function K(D,d,m){var _=b;return function(R,E){if(_===k)throw new Error("Generator is already running");if(_===C){if(R==="throw")throw E;return{value:n,done:!0}}for(m.method=R,m.arg=E;;){var M=m.delegate;if(M){var B=N(M,m);if(B){if(B===T)continue;return B}}if(m.method==="next")m.sent=m._sent=m.arg;else if(m.method==="throw"){if(_===b)throw _=C,m.arg;m.dispatchException(m.arg)}else m.method==="return"&&m.abrupt("return",m.arg);_=k;var Z=y(D,d,m);if(Z.type==="normal"){if(_=m.done?C:x,Z.arg===T)continue;return{value:Z.arg,done:m.done}}Z.type==="throw"&&(_=C,m.method="throw",m.arg=Z.arg)}}}function N(D,d){var m=d.method,_=D.iterator[m];if(_===n)return d.delegate=null,m==="throw"&&D.iterator.return&&(d.method="return",d.arg=n,N(D,d),d.method==="throw")||m!=="return"&&(d.method="throw",d.arg=new TypeError("The iterator does not provide a '"+m+"' method")),T;var R=y(_,D.iterator,d.arg);if(R.type==="throw")return d.method="throw",d.arg=R.arg,d.delegate=null,T;var E=R.arg;return E?E.done?(d[D.resultName]=E.value,d.next=D.nextLoc,d.method!=="return"&&(d.method="next",d.arg=n),d.delegate=null,T):E:(d.method="throw",d.arg=new TypeError("iterator result is not an object"),d.delegate=null,T)}function A(D){var d={tryLoc:D[0]};1 in D&&(d.catchLoc=D[1]),2 in D&&(d.finallyLoc=D[2],d.afterLoc=D[3]),this.tryEntries.push(d)}function L(D){var d=D.completion||{};d.type="normal",delete d.arg,D.completion=d}function j(D){this.tryEntries=[{tryLoc:"root"}],D.forEach(A,this),this.reset(!0)}function z(D){if(D||D===""){var d=D[u];if(d)return d.call(D);if(typeof D.next=="function")return D;if(!isNaN(D.length)){var m=-1,_=function R(){for(;++m<D.length;)if(a.call(D,m))return R.value=D[m],R.done=!1,R;return R.value=n,R.done=!0,R};return _.next=_}}throw new TypeError(r(D)+" is not iterable")}return I.prototype=w,l(P,"constructor",{value:w,configurable:!0}),l(w,"constructor",{value:I,configurable:!0}),I.displayName=p(w,h,"GeneratorFunction"),s.isGeneratorFunction=function(D){var d=typeof D=="function"&&D.constructor;return!!d&&(d===I||(d.displayName||d.name)==="GeneratorFunction")},s.mark=function(D){return Object.setPrototypeOf?Object.setPrototypeOf(D,w):(D.__proto__=w,p(D,h,"GeneratorFunction")),D.prototype=Object.create(P),D},s.awrap=function(D){return{__await:D}},U(V.prototype),p(V.prototype,f,function(){return this}),s.AsyncIterator=V,s.async=function(D,d,m,_,R){R===void 0&&(R=Promise);var E=new V(g(D,d,m,_),R);return s.isGeneratorFunction(d)?E:E.next().then(function(M){return M.done?M.value:E.next()})},U(P),p(P,h,"Generator"),p(P,u,function(){return this}),p(P,"toString",function(){return"[object Generator]"}),s.keys=function(D){var d=Object(D),m=[];for(var _ in d)m.push(_);return m.reverse(),function R(){for(;m.length;){var E=m.pop();if(E in d)return R.value=E,R.done=!1,R}return R.done=!0,R}},s.values=z,j.prototype={constructor:j,reset:function(D){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(L),!D)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 D=this.tryEntries[0].completion;if(D.type==="throw")throw D.arg;return this.rval},dispatchException:function(D){if(this.done)throw D;var d=this;function m(Z,H){return E.type="throw",E.arg=D,d.next=Z,H&&(d.method="next",d.arg=n),!!H}for(var _=this.tryEntries.length-1;_>=0;--_){var R=this.tryEntries[_],E=R.completion;if(R.tryLoc==="root")return m("end");if(R.tryLoc<=this.prev){var M=a.call(R,"catchLoc"),B=a.call(R,"finallyLoc");if(M&&B){if(this.prev<R.catchLoc)return m(R.catchLoc,!0);if(this.prev<R.finallyLoc)return m(R.finallyLoc)}else if(M){if(this.prev<R.catchLoc)return m(R.catchLoc,!0)}else{if(!B)throw new Error("try statement without catch or finally");if(this.prev<R.finallyLoc)return m(R.finallyLoc)}}}},abrupt:function(D,d){for(var m=this.tryEntries.length-1;m>=0;--m){var _=this.tryEntries[m];if(_.tryLoc<=this.prev&&a.call(_,"finallyLoc")&&this.prev<_.finallyLoc){var R=_;break}}R&&(D==="break"||D==="continue")&&R.tryLoc<=d&&d<=R.finallyLoc&&(R=null);var E=R?R.completion:{};return E.type=D,E.arg=d,R?(this.method="next",this.next=R.finallyLoc,T):this.complete(E)},complete:function(D,d){if(D.type==="throw")throw D.arg;return D.type==="break"||D.type==="continue"?this.next=D.arg:D.type==="return"?(this.rval=this.arg=D.arg,this.method="return",this.next="end"):D.type==="normal"&&d&&(this.next=d),T},finish:function(D){for(var d=this.tryEntries.length-1;d>=0;--d){var m=this.tryEntries[d];if(m.finallyLoc===D)return this.complete(m.completion,m.afterLoc),L(m),T}},catch:function(D){for(var d=this.tryEntries.length-1;d>=0;--d){var m=this.tryEntries[d];if(m.tryLoc===D){var _=m.completion;if(_.type==="throw"){var R=_.arg;L(m)}return R}}throw new Error("illegal catch attempt")},delegateYield:function(D,d,m){return this.delegate={iterator:z(D),resultName:d,nextLoc:m},this.method==="next"&&(this.arg=n),T}},s}e.exports=i,e.exports.__esModule=!0,e.exports.default=e.exports}),QL=ee((t,e)=>{W();var r=JL()();e.exports=r;try{regeneratorRuntime=r}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}}),eP=ee((t,e)=>{"use strict";W();var r=(i,...n)=>new Promise(s=>{s(i(...n))});e.exports=r,e.exports.default=r}),tP=ee((t,e)=>{"use strict";W();var r=eP(),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()()},l=(f,h,...p)=>{o++;let g=r(f,...p);h(g),g.then(a,a)},c=(f,h,...p)=>{o<n?l(f,h,...p):s.push(l.bind(null,f,h,...p))},u=(f,...h)=>new Promise(p=>c(f,p,...h));return Object.defineProperties(u,{activeCount:{get:()=>o},pendingCount:{get:()=>s.length},clearQueue:{value:()=>{s.length=0}}}),u};e.exports=i,e.exports.default=i}),rP=ee((t,e)=>{"use strict";W();var r=tP(),i=class extends Error{constructor(a){super(),this.value=a}},n=async(a,l)=>l(await a),s=async a=>{let l=await Promise.all(a);if(l[1]===!0)throw new i(l[0]);return!1},o=async(a,l,c)=>{c={concurrency:1/0,preserveOrder:!0,...c};let u=r(c.concurrency),f=[...a].map(p=>[p,u(n,p,l)]),h=r(c.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}),iP=ee((t,e)=>{"use strict";W();var r=te("path"),i=te("fs"),{promisify:n}=te("util"),s=rP(),o=n(i.stat),a=n(i.lstat),l={directory:"isDirectory",file:"isFile"};function c({type:f}){if(!(f in l))throw new Error(`Invalid type specified: ${f}`)}var u=(f,h)=>f===void 0||h[l[f]]();e.exports=async(f,h)=>{h={cwd:process.cwd(),type:"file",allowSymlinks:!0,...h},c(h);let p=h.allowSymlinks?o:a;return s(f,async g=>{try{let y=await p(r.resolve(h.cwd,g));return u(h.type,y)}catch{return!1}},h)},e.exports.sync=(f,h)=>{h={cwd:process.cwd(),allowSymlinks:!0,type:"file",...h},c(h);let p=h.allowSymlinks?i.statSync:i.lstatSync;for(let g of f)try{let y=p(r.resolve(h.cwd,g));if(u(h.type,y))return g}catch{}}}),nP=ee((t,e)=>{"use strict";W();var r=te("fs"),{promisify:i}=te("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}}}),sP=ee((t,e)=>{"use strict";W();var r=te("path"),i=iP(),n=nP(),s=Symbol("findUp.stop");e.exports=async(o,a={})=>{let l=r.resolve(a.cwd||""),{root:c}=r.parse(l),u=[].concat(o),f=async h=>{if(typeof o!="function")return i(u,h);let p=await o(h.cwd);return typeof p=="string"?i([p],h):p};for(;;){let h=await f({...a,cwd:l});if(h===s)return;if(h)return r.resolve(l,h);if(l===c)return;l=r.dirname(l)}},e.exports.sync=(o,a={})=>{let l=r.resolve(a.cwd||""),{root:c}=r.parse(l),u=[].concat(o),f=h=>{if(typeof o!="function")return i.sync(u,h);let p=o(h.cwd);return typeof p=="string"?i.sync([p],h):p};for(;;){let h=f({...a,cwd:l});if(h===s)return;if(h)return r.resolve(l,h);if(l===c)return;l=r.dirname(l)}},e.exports.exists=n,e.exports.sync.exists=n.sync,e.exports.stop=s}),Xn=ee((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)):{}}),Bh=ee((t,e)=>{"use strict";W();var r=typeof process=="object"&&process?process:{stdout:null,stderr:null},i=te("events"),n=te("stream"),s=te("string_decoder").StringDecoder,o=Symbol("EOF"),a=Symbol("maybeEmitEnd"),l=Symbol("emittedEnd"),c=Symbol("emittingEnd"),u=Symbol("emittedError"),f=Symbol("closed"),h=Symbol("read"),p=Symbol("flush"),g=Symbol("flushChunk"),y=Symbol("encoding"),b=Symbol("decoder"),x=Symbol("flowing"),k=Symbol("paused"),C=Symbol("resume"),T=Symbol("buffer"),O=Symbol("pipes"),I=Symbol("bufferLength"),w=Symbol("bufferPush"),v=Symbol("bufferShift"),F=Symbol("objectMode"),q=Symbol("destroyed"),P=Symbol("emitData"),U=Symbol("emitEnd"),V=Symbol("emitEnd2"),K=Symbol("async"),N=R=>Promise.resolve().then(R),A=global._MP_NO_ITERATOR_SYMBOLS_!=="1",L=A&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),j=A&&Symbol.iterator||Symbol("iterator not implemented"),z=R=>R==="end"||R==="finish"||R==="prefinish",D=R=>R instanceof ArrayBuffer||typeof R=="object"&&R.constructor&&R.constructor.name==="ArrayBuffer"&&R.byteLength>=0,d=R=>!Buffer.isBuffer(R)&&ArrayBuffer.isView(R),m=class{constructor(R,E,M){this.src=R,this.dest=E,this.opts=M,this.ondrain=()=>R[C](),E.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},_=class extends m{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(R,E,M){super(R,E,M),this.proxyErrors=B=>E.emit("error",B),R.on("error",this.proxyErrors)}};e.exports=class Qw extends n{constructor(E){super(),this[x]=!1,this[k]=!1,this[O]=[],this[T]=[],this[F]=E&&E.objectMode||!1,this[F]?this[y]=null:this[y]=E&&E.encoding||null,this[y]==="buffer"&&(this[y]=null),this[K]=E&&!!E.async||!1,this[b]=this[y]?new s(this[y]):null,this[o]=!1,this[l]=!1,this[c]=!1,this[f]=!1,this[u]=null,this.writable=!0,this.readable=!0,this[I]=0,this[q]=!1,E&&E.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[T]}),E&&E.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[O]})}get bufferLength(){return this[I]}get encoding(){return this[y]}set encoding(E){if(this[F])throw new Error("cannot set encoding in objectMode");if(this[y]&&E!==this[y]&&(this[b]&&this[b].lastNeed||this[I]))throw new Error("cannot change encoding");this[y]!==E&&(this[b]=E?new s(E):null,this[T].length&&(this[T]=this[T].map(M=>this[b].write(M)))),this[y]=E}setEncoding(E){this.encoding=E}get objectMode(){return this[F]}set objectMode(E){this[F]=this[F]||!!E}get async(){return this[K]}set async(E){this[K]=this[K]||!!E}write(E,M,B){if(this[o])throw new Error("write after end");if(this[q])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof M=="function"&&(B=M,M="utf8"),M||(M="utf8");let Z=this[K]?N:H=>H();return!this[F]&&!Buffer.isBuffer(E)&&(d(E)?E=Buffer.from(E.buffer,E.byteOffset,E.byteLength):D(E)?E=Buffer.from(E):typeof E!="string"&&(this.objectMode=!0)),this[F]?(this.flowing&&this[I]!==0&&this[p](!0),this.flowing?this.emit("data",E):this[w](E),this[I]!==0&&this.emit("readable"),B&&Z(B),this.flowing):E.length?(typeof E=="string"&&!(M===this[y]&&!this[b].lastNeed)&&(E=Buffer.from(E,M)),Buffer.isBuffer(E)&&this[y]&&(E=this[b].write(E)),this.flowing&&this[I]!==0&&this[p](!0),this.flowing?this.emit("data",E):this[w](E),this[I]!==0&&this.emit("readable"),B&&Z(B),this.flowing):(this[I]!==0&&this.emit("readable"),B&&Z(B),this.flowing)}read(E){if(this[q])return null;if(this[I]===0||E===0||E>this[I])return this[a](),null;this[F]&&(E=null),this[T].length>1&&!this[F]&&(this.encoding?this[T]=[this[T].join("")]:this[T]=[Buffer.concat(this[T],this[I])]);let M=this[h](E||null,this[T][0]);return this[a](),M}[h](E,M){return E===M.length||E===null?this[v]():(this[T][0]=M.slice(E),M=M.slice(0,E),this[I]-=E),this.emit("data",M),!this[T].length&&!this[o]&&this.emit("drain"),M}end(E,M,B){return typeof E=="function"&&(B=E,E=null),typeof M=="function"&&(B=M,M="utf8"),E&&this.write(E,M),B&&this.once("end",B),this[o]=!0,this.writable=!1,(this.flowing||!this[k])&&this[a](),this}[C](){this[q]||(this[k]=!1,this[x]=!0,this.emit("resume"),this[T].length?this[p]():this[o]?this[a]():this.emit("drain"))}resume(){return this[C]()}pause(){this[x]=!1,this[k]=!0}get destroyed(){return this[q]}get flowing(){return this[x]}get paused(){return this[k]}[w](E){this[F]?this[I]+=1:this[I]+=E.length,this[T].push(E)}[v](){return this[T].length&&(this[F]?this[I]-=1:this[I]-=this[T][0].length),this[T].shift()}[p](E){do;while(this[g](this[v]()));!E&&!this[T].length&&!this[o]&&this.emit("drain")}[g](E){return E?(this.emit("data",E),this.flowing):!1}pipe(E,M){if(this[q])return;let B=this[l];return M=M||{},E===r.stdout||E===r.stderr?M.end=!1:M.end=M.end!==!1,M.proxyErrors=!!M.proxyErrors,B?M.end&&E.end():(this[O].push(M.proxyErrors?new _(this,E,M):new m(this,E,M)),this[K]?N(()=>this[C]()):this[C]()),E}unpipe(E){let M=this[O].find(B=>B.dest===E);M&&(this[O].splice(this[O].indexOf(M),1),M.unpipe())}addListener(E,M){return this.on(E,M)}on(E,M){let B=super.on(E,M);return E==="data"&&!this[O].length&&!this.flowing?this[C]():E==="readable"&&this[I]!==0?super.emit("readable"):z(E)&&this[l]?(super.emit(E),this.removeAllListeners(E)):E==="error"&&this[u]&&(this[K]?N(()=>M.call(this,this[u])):M.call(this,this[u])),B}get emittedEnd(){return this[l]}[a](){!this[c]&&!this[l]&&!this[q]&&this[T].length===0&&this[o]&&(this[c]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[f]&&this.emit("close"),this[c]=!1)}emit(E,M,...B){if(E!=="error"&&E!=="close"&&E!==q&&this[q])return;if(E==="data")return M?this[K]?N(()=>this[P](M)):this[P](M):!1;if(E==="end")return this[U]();if(E==="close"){if(this[f]=!0,!this[l]&&!this[q])return;let H=super.emit("close");return this.removeAllListeners("close"),H}else if(E==="error"){this[u]=M;let H=super.emit("error",M);return this[a](),H}else if(E==="resume"){let H=super.emit("resume");return this[a](),H}else if(E==="finish"||E==="prefinish"){let H=super.emit(E);return this.removeAllListeners(E),H}let Z=super.emit(E,M,...B);return this[a](),Z}[P](E){for(let B of this[O])B.dest.write(E)===!1&&this.pause();let M=super.emit("data",E);return this[a](),M}[U](){this[l]||(this[l]=!0,this.readable=!1,this[K]?N(()=>this[V]()):this[V]())}[V](){if(this[b]){let M=this[b].end();if(M){for(let B of this[O])B.dest.write(M);super.emit("data",M)}}for(let M of this[O])M.end();let E=super.emit("end");return this.removeAllListeners("end"),E}collect(){let E=[];this[F]||(E.dataLength=0);let M=this.promise();return this.on("data",B=>{E.push(B),this[F]||(E.dataLength+=B.length)}),M.then(()=>E)}concat(){return this[F]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(E=>this[F]?Promise.reject(new Error("cannot concat in objectMode")):this[y]?E.join(""):Buffer.concat(E,E.dataLength))}promise(){return new Promise((E,M)=>{this.on(q,()=>M(new Error("stream destroyed"))),this.on("error",B=>M(B)),this.on("end",()=>E())})}[L](){return{next:()=>{let E=this.read();if(E!==null)return Promise.resolve({done:!1,value:E});if(this[o])return Promise.resolve({done:!0});let M=null,B=null,Z=re=>{this.removeListener("data",H),this.removeListener("end",J),B(re)},H=re=>{this.removeListener("error",Z),this.removeListener("end",J),this.pause(),M({value:re,done:!!this[o]})},J=()=>{this.removeListener("error",Z),this.removeListener("data",H),M({done:!0})},G=()=>Z(new Error("stream destroyed"));return new Promise((re,ue)=>{B=ue,M=re,this.once(q,G),this.once("error",Z),this.once("end",J),this.once("data",H)})}}}[j](){return{next:()=>{let E=this.read();return{value:E,done:E===null}}}}destroy(E){return this[q]?(E?this.emit("error",E):this.emit(q),this):(this[q]=!0,this[T].length=0,this[I]=0,typeof this.close=="function"&&!this[f]&&this.close(),E?this.emit("error",E):this.emit(q),this)}static isStream(E){return!!E&&(E instanceof Qw||E instanceof n||E instanceof i&&(typeof E.pipe=="function"||typeof E.write=="function"&&typeof E.end=="function"))}}}),oP=ee((t,e)=>{W();var r=te("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))}),eS=ee((t,e)=>{"use strict";W();var r=typeof process=="object"&&process?process:{stdout:null,stderr:null},i=te("events"),n=te("stream"),s=te("string_decoder").StringDecoder,o=Symbol("EOF"),a=Symbol("maybeEmitEnd"),l=Symbol("emittedEnd"),c=Symbol("emittingEnd"),u=Symbol("emittedError"),f=Symbol("closed"),h=Symbol("read"),p=Symbol("flush"),g=Symbol("flushChunk"),y=Symbol("encoding"),b=Symbol("decoder"),x=Symbol("flowing"),k=Symbol("paused"),C=Symbol("resume"),T=Symbol("bufferLength"),O=Symbol("bufferPush"),I=Symbol("bufferShift"),w=Symbol("objectMode"),v=Symbol("destroyed"),F=Symbol("emitData"),q=Symbol("emitEnd"),P=Symbol("emitEnd2"),U=Symbol("async"),V=m=>Promise.resolve().then(m),K=global._MP_NO_ITERATOR_SYMBOLS_!=="1",N=K&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),A=K&&Symbol.iterator||Symbol("iterator not implemented"),L=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),D=class{constructor(m,_,R){this.src=m,this.dest=_,this.opts=R,this.ondrain=()=>m[C](),_.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},d=class extends D{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(m,_,R){super(m,_,R),this.proxyErrors=E=>_.emit("error",E),m.on("error",this.proxyErrors)}};e.exports=class tS extends n{constructor(_){super(),this[x]=!1,this[k]=!1,this.pipes=[],this.buffer=[],this[w]=_&&_.objectMode||!1,this[w]?this[y]=null:this[y]=_&&_.encoding||null,this[y]==="buffer"&&(this[y]=null),this[U]=_&&!!_.async||!1,this[b]=this[y]?new s(this[y]):null,this[o]=!1,this[l]=!1,this[c]=!1,this[f]=!1,this[u]=null,this.writable=!0,this.readable=!0,this[T]=0,this[v]=!1}get bufferLength(){return this[T]}get encoding(){return this[y]}set encoding(_){if(this[w])throw new Error("cannot set encoding in objectMode");if(this[y]&&_!==this[y]&&(this[b]&&this[b].lastNeed||this[T]))throw new Error("cannot change encoding");this[y]!==_&&(this[b]=_?new s(_):null,this.buffer.length&&(this.buffer=this.buffer.map(R=>this[b].write(R)))),this[y]=_}setEncoding(_){this.encoding=_}get objectMode(){return this[w]}set objectMode(_){this[w]=this[w]||!!_}get async(){return this[U]}set async(_){this[U]=this[U]||!!_}write(_,R,E){if(this[o])throw new Error("write after end");if(this[v])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof R=="function"&&(E=R,R="utf8"),R||(R="utf8");let M=this[U]?V:B=>B();return!this[w]&&!Buffer.isBuffer(_)&&(z(_)?_=Buffer.from(_.buffer,_.byteOffset,_.byteLength):j(_)?_=Buffer.from(_):typeof _!="string"&&(this.objectMode=!0)),this[w]?(this.flowing&&this[T]!==0&&this[p](!0),this.flowing?this.emit("data",_):this[O](_),this[T]!==0&&this.emit("readable"),E&&M(E),this.flowing):_.length?(typeof _=="string"&&!(R===this[y]&&!this[b].lastNeed)&&(_=Buffer.from(_,R)),Buffer.isBuffer(_)&&this[y]&&(_=this[b].write(_)),this.flowing&&this[T]!==0&&this[p](!0),this.flowing?this.emit("data",_):this[O](_),this[T]!==0&&this.emit("readable"),E&&M(E),this.flowing):(this[T]!==0&&this.emit("readable"),E&&M(E),this.flowing)}read(_){if(this[v])return null;if(this[T]===0||_===0||_>this[T])return this[a](),null;this[w]&&(_=null),this.buffer.length>1&&!this[w]&&(this.encoding?this.buffer=[this.buffer.join("")]:this.buffer=[Buffer.concat(this.buffer,this[T])]);let R=this[h](_||null,this.buffer[0]);return this[a](),R}[h](_,R){return _===R.length||_===null?this[I]():(this.buffer[0]=R.slice(_),R=R.slice(0,_),this[T]-=_),this.emit("data",R),!this.buffer.length&&!this[o]&&this.emit("drain"),R}end(_,R,E){return typeof _=="function"&&(E=_,_=null),typeof R=="function"&&(E=R,R="utf8"),_&&this.write(_,R),E&&this.once("end",E),this[o]=!0,this.writable=!1,(this.flowing||!this[k])&&this[a](),this}[C](){this[v]||(this[k]=!1,this[x]=!0,this.emit("resume"),this.buffer.length?this[p]():this[o]?this[a]():this.emit("drain"))}resume(){return this[C]()}pause(){this[x]=!1,this[k]=!0}get destroyed(){return this[v]}get flowing(){return this[x]}get paused(){return this[k]}[O](_){this[w]?this[T]+=1:this[T]+=_.length,this.buffer.push(_)}[I](){return this.buffer.length&&(this[w]?this[T]-=1:this[T]-=this.buffer[0].length),this.buffer.shift()}[p](_){do;while(this[g](this[I]()));!_&&!this.buffer.length&&!this[o]&&this.emit("drain")}[g](_){return _?(this.emit("data",_),this.flowing):!1}pipe(_,R){if(this[v])return;let E=this[l];return R=R||{},_===r.stdout||_===r.stderr?R.end=!1:R.end=R.end!==!1,R.proxyErrors=!!R.proxyErrors,E?R.end&&_.end():(this.pipes.push(R.proxyErrors?new d(this,_,R):new D(this,_,R)),this[U]?V(()=>this[C]()):this[C]()),_}unpipe(_){let R=this.pipes.find(E=>E.dest===_);R&&(this.pipes.splice(this.pipes.indexOf(R),1),R.unpipe())}addListener(_,R){return this.on(_,R)}on(_,R){let E=super.on(_,R);return _==="data"&&!this.pipes.length&&!this.flowing?this[C]():_==="readable"&&this[T]!==0?super.emit("readable"):L(_)&&this[l]?(super.emit(_),this.removeAllListeners(_)):_==="error"&&this[u]&&(this[U]?V(()=>R.call(this,this[u])):R.call(this,this[u])),E}get emittedEnd(){return this[l]}[a](){!this[c]&&!this[l]&&!this[v]&&this.buffer.length===0&&this[o]&&(this[c]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[f]&&this.emit("close"),this[c]=!1)}emit(_,R,...E){if(_!=="error"&&_!=="close"&&_!==v&&this[v])return;if(_==="data")return R?this[U]?V(()=>this[F](R)):this[F](R):!1;if(_==="end")return this[q]();if(_==="close"){if(this[f]=!0,!this[l]&&!this[v])return;let B=super.emit("close");return this.removeAllListeners("close"),B}else if(_==="error"){this[u]=R;let B=super.emit("error",R);return this[a](),B}else if(_==="resume"){let B=super.emit("resume");return this[a](),B}else if(_==="finish"||_==="prefinish"){let B=super.emit(_);return this.removeAllListeners(_),B}let M=super.emit(_,R,...E);return this[a](),M}[F](_){for(let E of this.pipes)E.dest.write(_)===!1&&this.pause();let R=super.emit("data",_);return this[a](),R}[q](){this[l]||(this[l]=!0,this.readable=!1,this[U]?V(()=>this[P]()):this[P]())}[P](){if(this[b]){let R=this[b].end();if(R){for(let E of this.pipes)E.dest.write(R);super.emit("data",R)}}for(let R of this.pipes)R.end();let _=super.emit("end");return this.removeAllListeners("end"),_}collect(){let _=[];this[w]||(_.dataLength=0);let R=this.promise();return this.on("data",E=>{_.push(E),this[w]||(_.dataLength+=E.length)}),R.then(()=>_)}concat(){return this[w]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(_=>this[w]?Promise.reject(new Error("cannot concat in objectMode")):this[y]?_.join(""):Buffer.concat(_,_.dataLength))}promise(){return new Promise((_,R)=>{this.on(v,()=>R(new Error("stream destroyed"))),this.on("error",E=>R(E)),this.on("end",()=>_())})}[N](){return{next:()=>{let _=this.read();if(_!==null)return Promise.resolve({done:!1,value:_});if(this[o])return Promise.resolve({done:!0});let R=null,E=null,M=J=>{this.removeListener("data",B),this.removeListener("end",Z),E(J)},B=J=>{this.removeListener("error",M),this.removeListener("end",Z),this.pause(),R({value:J,done:!!this[o]})},Z=()=>{this.removeListener("error",M),this.removeListener("data",B),R({done:!0})},H=()=>M(new Error("stream destroyed"));return new Promise((J,G)=>{E=G,R=J,this.once(v,H),this.once("error",M),this.once("end",Z),this.once("data",B)})}}}[A](){return{next:()=>{let _=this.read();return{value:_,done:_===null}}}}destroy(_){return this[v]?(_?this.emit("error",_):this.emit(v),this):(this[v]=!0,this.buffer.length=0,this[T]=0,typeof this.close=="function"&&!this[f]&&this.close(),_?this.emit("error",_):this.emit(v),this)}static isStream(_){return!!_&&(_ instanceof tS||_ instanceof n||_ instanceof i&&(typeof _.pipe=="function"||typeof _.write=="function"&&typeof _.end=="function"))}}}),rS=ee(t=>{"use strict";W();var e=te("assert"),r=te("buffer").Buffer,i=te("zlib"),n=t.constants=oP(),s=eS(),o=r.concat,a=Symbol("_superWrite"),l=class extends Error{constructor(L){super("zlib: "+L.message),this.code=L.code,this.errno=L.errno,this.code||(this.code="ZLIB_ERROR"),this.message="zlib: "+L.message,Error.captureStackTrace(this,this.constructor)}get name(){return"ZlibError"}},c=Symbol("opts"),u=Symbol("flushFlag"),f=Symbol("finishFlushFlag"),h=Symbol("fullFlushFlag"),p=Symbol("handle"),g=Symbol("onError"),y=Symbol("sawError"),b=Symbol("level"),x=Symbol("strategy"),k=Symbol("ended"),C=Symbol("_defaultFullFlush"),T=class extends s{constructor(L,j){if(!L||typeof L!="object")throw new TypeError("invalid options for ZlibBase constructor");super(L),this[y]=!1,this[k]=!1,this[c]=L,this[u]=L.flush,this[f]=L.finishFlush;try{this[p]=new i[j](L)}catch(z){throw new l(z)}this[g]=z=>{this[y]||(this[y]=!0,this.close(),this.emit("error",z))},this[p].on("error",z=>this[g](new l(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(L){this.ended||(typeof L!="number"&&(L=this[h]),this.write(Object.assign(r.alloc(0),{[u]:L})))}end(L,j,z){return L&&this.write(L,j),this.flush(this[f]),this[k]=!0,super.end(null,null,z)}get ended(){return this[k]}write(L,j,z){if(typeof j=="function"&&(z=j,j="utf8"),typeof L=="string"&&(L=r.from(L,j)),this[y])return;e(this[p],"zlib binding closed");let D=this[p]._handle,d=D.close;D.close=()=>{};let m=this[p].close;this[p].close=()=>{},r.concat=E=>E;let _;try{let E=typeof L[u]=="number"?L[u]:this[u];_=this[p]._processChunk(L,E),r.concat=o}catch(E){r.concat=o,this[g](new l(E))}finally{this[p]&&(this[p]._handle=D,D.close=d,this[p].close=m,this[p].removeAllListeners("error"))}this[p]&&this[p].on("error",E=>this[g](new l(E)));let R;if(_)if(Array.isArray(_)&&_.length>0){R=this[a](r.from(_[0]));for(let E=1;E<_.length;E++)R=this[a](_[E])}else R=this[a](r.from(_));return z&&z(),R}[a](L){return super.write(L)}},O=class extends T{constructor(L,j){L=L||{},L.flush=L.flush||n.Z_NO_FLUSH,L.finishFlush=L.finishFlush||n.Z_FINISH,super(L,j),this[h]=n.Z_FULL_FLUSH,this[b]=L.level,this[x]=L.strategy}params(L,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[b]!==L||this[x]!==j){this.flush(n.Z_SYNC_FLUSH),e(this[p],"zlib binding closed");let z=this[p].flush;this[p].flush=(D,d)=>{this.flush(D),d()};try{this[p].params(L,j)}finally{this[p].flush=z}this[p]&&(this[b]=L,this[x]=j)}}}},I=class extends O{constructor(L){super(L,"Deflate")}},w=class extends O{constructor(L){super(L,"Inflate")}},v=Symbol("_portable"),F=class extends O{constructor(L){super(L,"Gzip"),this[v]=L&&!!L.portable}[a](L){return this[v]?(this[v]=!1,L[9]=255,super[a](L)):super[a](L)}},q=class extends O{constructor(L){super(L,"Gunzip")}},P=class extends O{constructor(L){super(L,"DeflateRaw")}},U=class extends O{constructor(L){super(L,"InflateRaw")}},V=class extends O{constructor(L){super(L,"Unzip")}},K=class extends T{constructor(L,j){L=L||{},L.flush=L.flush||n.BROTLI_OPERATION_PROCESS,L.finishFlush=L.finishFlush||n.BROTLI_OPERATION_FINISH,super(L,j),this[h]=n.BROTLI_OPERATION_FLUSH}},N=class extends K{constructor(L){super(L,"BrotliCompress")}},A=class extends K{constructor(L){super(L,"BrotliDecompress")}};t.Deflate=I,t.Inflate=w,t.Gzip=F,t.Gunzip=q,t.DeflateRaw=P,t.InflateRaw=U,t.Unzip=V,typeof i.BrotliCompress=="function"?(t.BrotliCompress=N,t.BrotliDecompress=A):t.BrotliCompress=t.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}}),Jn=ee((t,e)=>{W();var r=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform;e.exports=r!=="win32"?i=>i:i=>i&&i.replace(/\\/g,"/")}),jh=ee((t,e)=>{"use strict";W();var r=Bh(),i=Jn(),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,l=this.blockRemain;return this.remain=Math.max(0,a-o),this.blockRemain=Math.max(0,l-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])}}}),iS=ee(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]]))}),aP=ee((t,e)=>{"use strict";W();var r=(u,f)=>{if(Number.isSafeInteger(u))u<0?n(u,f):i(u,f);else throw Error("cannot encode number outside of javascript safe integer range");return f},i=(u,f)=>{f[0]=128;for(var h=f.length;h>1;h--)f[h-1]=u&255,u=Math.floor(u/256)},n=(u,f)=>{f[0]=255;var h=!1;u=u*-1;for(var p=f.length;p>1;p--){var g=u&255;u=Math.floor(u/256),h?f[p-1]=l(g):g===0?f[p-1]=0:(h=!0,f[p-1]=c(g))}},s=u=>{let f=u[0],h=f===128?a(u.slice(1,u.length)):f===255?o(u):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=u=>{for(var f=u.length,h=0,p=!1,g=f-1;g>-1;g--){var y=u[g],b;p?b=l(y):y===0?b=y:(p=!0,b=c(y)),b!==0&&(h-=b*Math.pow(256,f-g-1))}return h},a=u=>{for(var f=u.length,h=0,p=f-1;p>-1;p--){var g=u[p];g!==0&&(h+=g*Math.pow(256,f-p-1))}return h},l=u=>(255^u)&255,c=u=>(255^u)+1&255;e.exports={encode:r,parse:s}}),Qn=ee((t,e)=>{"use strict";W();var r=iS(),i=te("path").posix,n=aP(),s=Symbol("slurp"),o=Symbol("type"),a=class{constructor(w,v,F,q){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(w)?this.decode(w,v||0,F,q):w&&this.set(w)}decode(w,v,F,q){if(v||(v=0),!w||!(w.length>=v+512))throw new Error("need 512 bytes for header");if(this.path=c(w,v,100),this.mode=h(w,v+100,8),this.uid=h(w,v+108,8),this.gid=h(w,v+116,8),this.size=h(w,v+124,12),this.mtime=u(w,v+136,12),this.cksum=h(w,v+148,12),this[s](F),this[s](q,!0),this[o]=c(w,v+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=c(w,v+157,100),w.slice(v+257,v+265).toString()==="ustar\x0000")if(this.uname=c(w,v+265,32),this.gname=c(w,v+297,32),this.devmaj=h(w,v+329,8),this.devmin=h(w,v+337,8),w[v+475]!==0){let U=c(w,v+345,155);this.path=U+"/"+this.path}else{let U=c(w,v+345,130);U&&(this.path=U+"/"+this.path),this.atime=u(w,v+476,12),this.ctime=u(w,v+488,12)}let P=8*32;for(let U=v;U<v+148;U++)P+=w[U];for(let U=v+156;U<v+512;U++)P+=w[U];this.cksumValid=P===this.cksum,this.cksum===null&&P===8*32&&(this.nullBlock=!0)}[s](w,v){for(let F in w)w[F]!==null&&w[F]!==void 0&&!(v&&F==="path")&&(this[F]=w[F])}encode(w,v){if(w||(w=this.block=Buffer.alloc(512),v=0),v||(v=0),!(w.length>=v+512))throw new Error("need 512 bytes for header");let F=this.ctime||this.atime?130:155,q=l(this.path||"",F),P=q[0],U=q[1];this.needPax=q[2],this.needPax=I(w,v,100,P)||this.needPax,this.needPax=b(w,v+100,8,this.mode)||this.needPax,this.needPax=b(w,v+108,8,this.uid)||this.needPax,this.needPax=b(w,v+116,8,this.gid)||this.needPax,this.needPax=b(w,v+124,12,this.size)||this.needPax,this.needPax=T(w,v+136,12,this.mtime)||this.needPax,w[v+156]=this[o].charCodeAt(0),this.needPax=I(w,v+157,100,this.linkpath)||this.needPax,w.write("ustar\x0000",v+257,8),this.needPax=I(w,v+265,32,this.uname)||this.needPax,this.needPax=I(w,v+297,32,this.gname)||this.needPax,this.needPax=b(w,v+329,8,this.devmaj)||this.needPax,this.needPax=b(w,v+337,8,this.devmin)||this.needPax,this.needPax=I(w,v+345,F,U)||this.needPax,w[v+475]!==0?this.needPax=I(w,v+345,155,U)||this.needPax:(this.needPax=I(w,v+345,130,U)||this.needPax,this.needPax=T(w,v+476,12,this.atime)||this.needPax,this.needPax=T(w,v+488,12,this.ctime)||this.needPax);let V=8*32;for(let K=v;K<v+148;K++)V+=w[K];for(let K=v+156;K<v+512;K++)V+=w[K];return this.cksum=V,b(w,v+148,8,this.cksum),this.cksumValid=!0,this.needPax}set(w){for(let v in w)w[v]!==null&&w[v]!==void 0&&(this[v]=w[v])}get type(){return r.name.get(this[o])||this[o]}get typeKey(){return this[o]}set type(w){r.code.has(w)?this[o]=r.code.get(w):this[o]=w}},l=(w,v)=>{let F=w,q="",P,U=i.parse(w).root||".";if(Buffer.byteLength(F)<100)P=[F,q,!1];else{q=i.dirname(F),F=i.basename(F);do Buffer.byteLength(F)<=100&&Buffer.byteLength(q)<=v?P=[F,q,!1]:Buffer.byteLength(F)>100&&Buffer.byteLength(q)<=v?P=[F.slice(0,100-1),q,!0]:(F=i.join(i.basename(q),F),q=i.dirname(q));while(q!==U&&!P);P||(P=[w.slice(0,100-1),"",!0])}return P},c=(w,v,F)=>w.slice(v,v+F).toString("utf8").replace(/\0.*/,""),u=(w,v,F)=>f(h(w,v,F)),f=w=>w===null?null:new Date(w*1e3),h=(w,v,F)=>w[v]&128?n.parse(w.slice(v,v+F)):g(w,v,F),p=w=>isNaN(w)?null:w,g=(w,v,F)=>p(parseInt(w.slice(v,v+F).toString("utf8").replace(/\0.*$/,"").trim(),8)),y={12:8589934591,8:2097151},b=(w,v,F,q)=>q===null?!1:q>y[F]||q<0?(n.encode(q,w.slice(v,v+F)),!0):(x(w,v,F,q),!1),x=(w,v,F,q)=>w.write(k(q,F),v,F,"ascii"),k=(w,v)=>C(Math.floor(w).toString(8),v),C=(w,v)=>(w.length===v-1?w:new Array(v-w.length-1).join("0")+w+" ")+"\0",T=(w,v,F,q)=>q===null?!1:b(w,v,F,q.getTime()/1e3),O=new Array(156).join("\0"),I=(w,v,F,q)=>q===null?!1:(w.write(q+O,v,F,"utf8"),q.length!==Buffer.byteLength(q)||q.length>F);e.exports=a}),$h=ee((t,e)=>{"use strict";W();var r=Qn(),i=te("path"),n=class{constructor(l,c){this.atime=l.atime||null,this.charset=l.charset||null,this.comment=l.comment||null,this.ctime=l.ctime||null,this.gid=l.gid||null,this.gname=l.gname||null,this.linkpath=l.linkpath||null,this.mtime=l.mtime||null,this.path=l.path||null,this.size=l.size||null,this.uid=l.uid||null,this.uname=l.uname||null,this.dev=l.dev||null,this.ino=l.ino||null,this.nlink=l.nlink||null,this.global=c||!1}encode(){let l=this.encodeBody();if(l==="")return null;let c=Buffer.byteLength(l),u=512*Math.ceil(1+c/512),f=Buffer.allocUnsafe(u);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:c,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(l,512,c,"utf8");for(let h=c+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(l){if(this[l]===null||this[l]===void 0)return"";let c=this[l]instanceof Date?this[l].getTime()/1e3:this[l],u=" "+(l==="dev"||l==="ino"||l==="nlink"?"SCHILY.":"")+l+"="+c+`
|
41
41
|
`,f=Buffer.byteLength(u),h=Math.floor(Math.log(f)/Math.log(10))+1;return f+h>=Math.pow(10,h)&&(h+=1),h+f+u}};n.parse=(l,c,u)=>new n(s(o(l),c),u);var s=(l,c)=>c?Object.keys(l).reduce((u,f)=>(u[f]=l[f],u),c):l,o=l=>l.replace(/\n$/,"").split(`
|
42
|
-
`).reduce(a,Object.create(null)),a=(l,c)=>{let u=parseInt(c,10);if(u!==Buffer.byteLength(c)+1)return l;c=c.slice((u+" ").length);let f=c.split("="),h=f.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!h)return l;let p=f.join("=");return l[h]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(h)?new Date(p*1e3):/^[0-9]+$/.test(p)?+p:p,l};e.exports=n}),es=ee((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)}}),qh=ee((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))}}}),nS=ee((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,l)=>a.split(l).join(n.get(l)),o),decode:o=>i.reduce((a,l)=>a.split(l).join(s.get(l)),o)}}),sS=ee((t,e)=>{W();var{isAbsolute:r,parse:i}=te("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]}}),lP=ee((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)}),oS=ee((t,e)=>{"use strict";W();var r=Bh(),i=$h(),n=Qn(),s=te("fs"),o=te("path"),a=Jn(),l=es(),c=(m,_)=>_?(m=a(m).replace(/^\.(\/|$)/,""),l(_)+"/"+m):a(m),u=16*1024*1024,f=Symbol("process"),h=Symbol("file"),p=Symbol("directory"),g=Symbol("symlink"),y=Symbol("hardlink"),b=Symbol("header"),x=Symbol("read"),k=Symbol("lstat"),C=Symbol("onlstat"),T=Symbol("onread"),O=Symbol("onreadlink"),I=Symbol("openfile"),w=Symbol("onopenfile"),v=Symbol("close"),F=Symbol("mode"),q=Symbol("awaitDrain"),P=Symbol("ondrain"),U=Symbol("prefix"),K=Symbol("hadError"),V=qh(),N=nS(),A=sS(),L=lP(),j=V(class extends r{constructor(m,_){if(_=_||{},super(_),typeof m!="string")throw new TypeError("path is required");this.path=a(m),this.portable=!!_.portable,this.myuid=process.getuid&&process.getuid()||0,this.myuser=process.env.USER||"",this.maxReadSize=_.maxReadSize||u,this.linkCache=_.linkCache||new Map,this.statCache=_.statCache||new Map,this.preservePaths=!!_.preservePaths,this.cwd=a(_.cwd||process.cwd()),this.strict=!!_.strict,this.noPax=!!_.noPax,this.noMtime=!!_.noMtime,this.mtime=_.mtime||null,this.prefix=_.prefix?a(_.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 _.onwarn=="function"&&this.on("warn",_.onwarn);let R=!1;if(!this.preservePaths){let[E,M]=A(this.path);E&&(this.path=M,R=E)}this.win32=!!_.win32||process.platform==="win32",this.win32&&(this.path=N.decode(this.path.replace(/\\/g,"/")),m=m.replace(/\\/g,"/")),this.absolute=a(_.absolute||o.resolve(this.cwd,m)),this.path===""&&(this.path="./"),R&&this.warn("TAR_ENTRY_INFO",`stripping ${R} from absolute path`,{entry:this,path:R+this.path}),this.statCache.has(this.absolute)?this[C](this.statCache.get(this.absolute)):this[k]()}emit(m,..._){return m==="error"&&(this[K]=!0),super.emit(m,..._)}[k](){s.lstat(this.absolute,(m,_)=>{if(m)return this.emit("error",m);this[C](_)})}[C](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()}}[F](m){return L(m,this.type==="Directory",this.portable)}[U](m){return c(m,this.prefix)}[b](){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[F](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[b](),this.end()}[g](){s.readlink(this.absolute,(m,_)=>{if(m)return this.emit("error",m);this[O](_)})}[O](m){this.linkpath=a(m),this[b](),this.end()}[y](m){this.type="Link",this.linkpath=a(o.relative(this.cwd,m)),this.stat.size=0,this[b](),this.end()}[h](){if(this.stat.nlink>1){let m=this.stat.dev+":"+this.stat.ino;if(this.linkCache.has(m)){let _=this.linkCache.get(m);if(_.indexOf(this.cwd)===0)return this[y](_)}this.linkCache.set(m,this.absolute)}if(this[b](),this.stat.size===0)return this.end();this[I]()}[I](){s.open(this.absolute,"r",(m,_)=>{if(m)return this.emit("error",m);this[w](_)})}[w](m){if(this.fd=m,this[K])return this[v]();this.blockLen=512*Math.ceil(this.stat.size/512),this.blockRemain=this.blockLen;let _=Math.min(this.blockLen,this.maxReadSize);this.buf=Buffer.allocUnsafe(_),this.offset=0,this.pos=0,this.remain=this.stat.size,this.length=this.buf.length,this[x]()}[x](){let{fd:m,buf:_,offset:R,length:E,pos:M}=this;s.read(m,_,R,E,M,(B,Z)=>{if(B)return this[v](()=>this.emit("error",B));this[T](Z)})}[v](m){s.close(this.fd,m)}[T](m){if(m<=0&&this.remain>0){let R=new Error("encountered unexpected EOF");return R.path=this.absolute,R.syscall="read",R.code="EOF",this[v](()=>this.emit("error",R))}if(m>this.remain){let R=new Error("did not encounter expected EOF");return R.path=this.absolute,R.syscall="read",R.code="EOF",this[v](()=>this.emit("error",R))}if(m===this.remain)for(let R=m;R<this.length&&m<this.blockRemain;R++)this.buf[R+this.offset]=0,m++,this.remain++;let _=this.offset===0&&m===this.buf.length?this.buf:this.buf.slice(this.offset,this.offset+m);this.write(_)?this[P]():this[q](()=>this[P]())}[q](m){this.once("drain",m)}write(m){if(this.blockRemain<m.length){let _=new Error("writing more data than expected");return _.path=this.absolute,this.emit("error",_)}return this.remain-=m.length,this.blockRemain-=m.length,this.pos+=m.length,this.offset+=m.length,super.write(m)}[P](){if(!this.remain)return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),this[v](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[x]()}}),z=class extends j{[k](){this[C](s.lstatSync(this.absolute))}[g](){this[O](s.readlinkSync(this.absolute))}[I](){this[w](s.openSync(this.absolute,"r"))}[x](){let m=!0;try{let{fd:_,buf:R,offset:E,length:M,pos:B}=this,Z=s.readSync(_,R,E,M,B);this[T](Z),m=!1}finally{if(m)try{this[v](()=>{})}catch{}}}[q](m){m()}[v](m){s.closeSync(this.fd),m()}},D=V(class extends r{constructor(m,_){_=_||{},super(_),this.preservePaths=!!_.preservePaths,this.portable=!!_.portable,this.strict=!!_.strict,this.noPax=!!_.noPax,this.noMtime=!!_.noMtime,this.readEntry=m,this.type=m.type,this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.prefix=_.prefix||null,this.path=a(m.path),this.mode=this[F](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:_.mtime||m.mtime,this.atime=this.portable?null:m.atime,this.ctime=this.portable?null:m.ctime,this.linkpath=a(m.linkpath),typeof _.onwarn=="function"&&this.on("warn",_.onwarn);let R=!1;if(!this.preservePaths){let[E,M]=A(this.path);E&&(this.path=M,R=E)}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}),R&&this.warn("TAR_ENTRY_INFO",`stripping ${R} from absolute path`,{entry:this,path:R+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 c(m,this.prefix)}[F](m){return L(m,this.type==="Directory",this.portable)}write(m){let _=m.length;if(_>this.blockRemain)throw new Error("writing more to entry than is appropriate");return this.blockRemain-=_,super.write(m)}end(){return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),super.end()}});j.Sync=z,j.Tar=D;var d=m=>m.isFile()?"File":m.isDirectory()?"Directory":m.isSymbolicLink()?"SymbolicLink":"Unsupported";e.exports=j}),cP=ee((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}}}),aS=ee((t,e)=>{"use strict";W(),e.exports=r,r.Node=o,r.create=r;function r(a){var l=this;if(l instanceof r||(l=new r),l.tail=null,l.head=null,l.length=0,a&&typeof a.forEach=="function")a.forEach(function(f){l.push(f)});else if(arguments.length>0)for(var c=0,u=arguments.length;c<u;c++)l.push(arguments[c]);return l}r.prototype.removeNode=function(a){if(a.list!==this)throw new Error("removing node which does not belong to this list");var l=a.next,c=a.prev;return l&&(l.prev=c),c&&(c.next=l),a===this.head&&(this.head=l),a===this.tail&&(this.tail=c),a.list.length--,a.next=null,a.prev=null,a.list=null,l},r.prototype.unshiftNode=function(a){if(a!==this.head){a.list&&a.list.removeNode(a);var l=this.head;a.list=this,a.next=l,l&&(l.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 l=this.tail;a.list=this,a.prev=l,l&&(l.next=a),this.tail=a,this.head||(this.head=a),this.length++}},r.prototype.push=function(){for(var a=0,l=arguments.length;a<l;a++)n(this,arguments[a]);return this.length},r.prototype.unshift=function(){for(var a=0,l=arguments.length;a<l;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,l){l=l||this;for(var c=this.head,u=0;c!==null;u++)a.call(l,c.value,u,this),c=c.next},r.prototype.forEachReverse=function(a,l){l=l||this;for(var c=this.tail,u=this.length-1;c!==null;u--)a.call(l,c.value,u,this),c=c.prev},r.prototype.get=function(a){for(var l=0,c=this.head;c!==null&&l<a;l++)c=c.next;if(l===a&&c!==null)return c.value},r.prototype.getReverse=function(a){for(var l=0,c=this.tail;c!==null&&l<a;l++)c=c.prev;if(l===a&&c!==null)return c.value},r.prototype.map=function(a,l){l=l||this;for(var c=new r,u=this.head;u!==null;)c.push(a.call(l,u.value,this)),u=u.next;return c},r.prototype.mapReverse=function(a,l){l=l||this;for(var c=new r,u=this.tail;u!==null;)c.push(a.call(l,u.value,this)),u=u.prev;return c},r.prototype.reduce=function(a,l){var c,u=this.head;if(arguments.length>1)c=l;else if(this.head)u=this.head.next,c=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=0;u!==null;f++)c=a(c,u.value,f),u=u.next;return c},r.prototype.reduceReverse=function(a,l){var c,u=this.tail;if(arguments.length>1)c=l;else if(this.tail)u=this.tail.prev,c=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=this.length-1;u!==null;f--)c=a(c,u.value,f),u=u.prev;return c},r.prototype.toArray=function(){for(var a=new Array(this.length),l=0,c=this.head;c!==null;l++)a[l]=c.value,c=c.next;return a},r.prototype.toArrayReverse=function(){for(var a=new Array(this.length),l=0,c=this.tail;c!==null;l++)a[l]=c.value,c=c.prev;return a},r.prototype.slice=function(a,l){l=l||this.length,l<0&&(l+=this.length),a=a||0,a<0&&(a+=this.length);var c=new r;if(l<a||l<0)return c;a<0&&(a=0),l>this.length&&(l=this.length);for(var u=0,f=this.head;f!==null&&u<a;u++)f=f.next;for(;f!==null&&u<l;u++,f=f.next)c.push(f.value);return c},r.prototype.sliceReverse=function(a,l){l=l||this.length,l<0&&(l+=this.length),a=a||0,a<0&&(a+=this.length);var c=new r;if(l<a||l<0)return c;a<0&&(a=0),l>this.length&&(l=this.length);for(var u=this.length,f=this.tail;f!==null&&u>l;u--)f=f.prev;for(;f!==null&&u>a;u--,f=f.prev)c.push(f.value);return c},r.prototype.splice=function(a,l,...c){a>this.length&&(a=this.length-1),a<0&&(a=this.length+a);for(var u=0,f=this.head;f!==null&&u<a;u++)f=f.next;for(var h=[],u=0;f&&u<l;u++)h.push(f.value),f=this.removeNode(f);f===null&&(f=this.tail),f!==this.head&&f!==this.tail&&(f=f.prev);for(var u=0;u<c.length;u++)f=i(this,f,c[u]);return h},r.prototype.reverse=function(){for(var a=this.head,l=this.tail,c=a;c!==null;c=c.prev){var u=c.prev;c.prev=c.next,c.next=u}return this.head=l,this.tail=a,this};function i(a,l,c){var u=l===a.head?new o(c,null,l,a):new o(c,l,l.next,a);return u.next===null&&(a.tail=u),u.prev===null&&(a.head=u),a.length++,u}function n(a,l){a.tail=new o(l,a.tail,null,a),a.head||(a.head=a.tail),a.length++}function s(a,l){a.head=new o(l,null,a.head,a),a.tail||(a.tail=a.head),a.length++}function o(a,l,c,u){if(!(this instanceof o))return new o(a,l,c,u);this.list=u,this.value=a,l?(l.next=this,this.prev=l):this.prev=null,c?(c.prev=this,this.next=c):this.next=null}try{cP()(r)}catch{}}),Hh=ee((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=Bh(),n=rS(),s=jh(),o=oS(),a=o.Sync,l=o.Tar,c=aS(),u=Buffer.alloc(1024),f=Symbol("onStat"),h=Symbol("ended"),p=Symbol("queue"),g=Symbol("current"),y=Symbol("process"),b=Symbol("processing"),x=Symbol("processJob"),k=Symbol("jobs"),C=Symbol("jobDone"),T=Symbol("addFSEntry"),O=Symbol("addTarEntry"),I=Symbol("stat"),w=Symbol("readdir"),v=Symbol("onreaddir"),F=Symbol("pipe"),q=Symbol("entry"),P=Symbol("entryOpt"),U=Symbol("writeEntryClass"),K=Symbol("write"),V=Symbol("ondrain"),N=te("fs"),A=te("path"),L=qh(),j=Jn(),z=L(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[V]()),this.on("resume",m=>this.zip.resume())):this.on("drain",this[V]),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 c,this[k]=0,this.jobs=+d.jobs||4,this[b]=!1,this[h]=!1}[K](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[O](d):this[T](d),this.flowing}[O](d){let m=j(A.resolve(this.cwd,d.path));if(!this.filter(d.path,d))d.resume();else{let _=new r(d.path,m,!1);_.entry=new l(d,this[P](_)),_.entry.on("end",R=>this[C](_)),this[k]+=1,this[p].push(_)}this[y]()}[T](d){let m=j(A.resolve(this.cwd,d));this[p].push(new r(d,m)),this[y]()}[I](d){d.pending=!0,this[k]+=1;let m=this.follow?"stat":"lstat";N[m](d.absolute,(_,R)=>{d.pending=!1,this[k]-=1,_?this.emit("error",_):this[f](d,R)})}[f](d,m){this.statCache.set(d.absolute,m),d.stat=m,this.filter(d.path,m)||(d.ignore=!0),this[y]()}[w](d){d.pending=!0,this[k]+=1,N.readdir(d.absolute,(m,_)=>{if(d.pending=!1,this[k]-=1,m)return this.emit("error",m);this[v](d,_)})}[v](d,m){this.readdirCache.set(d.absolute,m),d.readdir=m,this[y]()}[y](){if(!this[b]){this[b]=!0;for(let d=this[p].head;d!==null&&this[k]<this.jobs;d=d.next)if(this[x](d.value),d.value.ignore){let m=d.next;this[p].removeNode(d),d.next=m}this[b]=!1,this[h]&&!this[p].length&&this[k]===0&&(this.zip?this.zip.end(u):(super.write(u),super.end()))}}get[g](){return this[p]&&this[p].head&&this[p].head.value}[C](d){this[p].shift(),this[k]-=1,this[y]()}[x](d){if(!d.pending){if(d.entry){d===this[g]&&!d.piped&&this[F](d);return}if(d.stat||(this.statCache.has(d.absolute)?this[f](d,this.statCache.get(d.absolute)):this[I](d)),!!d.stat&&!d.ignore&&!(!this.noDirRecurse&&d.stat.isDirectory()&&!d.readdir&&(this.readdirCache.has(d.absolute)?this[v](d,this.readdirCache.get(d.absolute)):this[w](d),!d.readdir))){if(d.entry=this[q](d),!d.entry){d.ignore=!0;return}d===this[g]&&!d.piped&&this[F](d)}}}[P](d){return{onwarn:(m,_,R)=>this.warn(m,_,R),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}}[q](d){this[k]+=1;try{return new this[U](d.path,this[P](d)).on("end",()=>this[C](d)).on("error",m=>this.emit("error",m))}catch(m){this.emit("error",m)}}[V](){this[g]&&this[g].entry&&this[g].entry.resume()}[F](d){d.piped=!0,d.readdir&&d.readdir.forEach(R=>{let E=d.path,M=E==="./"?"":E.replace(/\/*$/,"/");this[T](M+R)});let m=d.entry,_=this.zip;_?m.on("data",R=>{_.write(R)||m.pause()}):m.on("data",R=>{super.write(R)||m.pause()})}pause(){return this.zip&&this.zip.pause(),super.pause()}}),D=class extends z{constructor(d){super(d),this[U]=a}pause(){}resume(){}[I](d){let m=this.follow?"statSync":"lstatSync";this[f](d,N[m](d.absolute))}[w](d,m){this[v](d,N.readdirSync(d.absolute))}[F](d){let m=d.entry,_=this.zip;d.readdir&&d.readdir.forEach(R=>{let E=d.path,M=E==="./"?"":E.replace(/\/*$/,"/");this[T](M+R)}),_?m.on("data",R=>{_.write(R)}):m.on("data",R=>{super[K](R)})}};z.Sync=D,e.exports=z}),ts=ee(t=>{"use strict";W();var e=eS(),r=te("events").EventEmitter,i=te("fs"),n=i.writev;if(!n){let d=process.binding("fs"),m=d.FSReqWrap||d.FSReqCallback;n=(_,R,E,M)=>{let B=(H,J)=>M(H,J,R),Z=new m;Z.oncomplete=B,d.writeBuffers(_,R,E,Z)}}var s=Symbol("_autoClose"),o=Symbol("_close"),a=Symbol("_ended"),l=Symbol("_fd"),c=Symbol("_finished"),u=Symbol("_flags"),f=Symbol("_flush"),h=Symbol("_handleChunk"),p=Symbol("_makeBuf"),g=Symbol("_mode"),y=Symbol("_needDrain"),b=Symbol("_onerror"),x=Symbol("_onopen"),k=Symbol("_onread"),C=Symbol("_onwrite"),T=Symbol("_open"),O=Symbol("_path"),I=Symbol("_pos"),w=Symbol("_queue"),v=Symbol("_read"),F=Symbol("_readSize"),q=Symbol("_reading"),P=Symbol("_remain"),U=Symbol("_size"),K=Symbol("_write"),V=Symbol("_writing"),N=Symbol("_defaultFlag"),A=Symbol("_errored"),L=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[A]=!1,this[l]=typeof m.fd=="number"?m.fd:null,this[O]=d,this[F]=m.readSize||16*1024*1024,this[q]=!1,this[U]=typeof m.size=="number"?m.size:1/0,this[P]=this[U],this[s]=typeof m.autoClose=="boolean"?m.autoClose:!0,typeof this[l]=="number"?this[v]():this[T]()}get fd(){return this[l]}get path(){return this[O]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[T](){i.open(this[O],"r",(d,m)=>this[x](d,m))}[x](d,m){d?this[b](d):(this[l]=m,this.emit("open",m),this[v]())}[p](){return Buffer.allocUnsafe(Math.min(this[F],this[P]))}[v](){if(!this[q]){this[q]=!0;let d=this[p]();if(d.length===0)return process.nextTick(()=>this[k](null,0,d));i.read(this[l],d,0,d.length,null,(m,_,R)=>this[k](m,_,R))}}[k](d,m,_){this[q]=!1,d?this[b](d):this[h](m,_)&&this[v]()}[o](){if(this[s]&&typeof this[l]=="number"){let d=this[l];this[l]=null,i.close(d,m=>m?this.emit("error",m):this.emit("close"))}}[b](d){this[q]=!0,this[o](),this.emit("error",d)}[h](d,m){let _=!1;return this[P]-=d,d>0&&(_=super.write(d<m.length?m.slice(0,d):m)),(d===0||this[P]<=0)&&(_=!1,this[o](),super.end()),_}emit(d,m){switch(d){case"prefinish":case"finish":break;case"drain":typeof this[l]=="number"&&this[v]();break;case"error":return this[A]?void 0:(this[A]=!0,super.emit(d,m));default:return super.emit(d,m)}}},j=class extends L{[T](){let d=!0;try{this[x](null,i.openSync(this[O],"r")),d=!1}finally{d&&this[o]()}}[v](){let d=!0;try{if(!this[q]){this[q]=!0;do{let m=this[p](),_=m.length===0?0:i.readSync(this[l],m,0,m.length,null);if(!this[h](_,m))break}while(!0);this[q]=!1}d=!1}finally{d&&this[o]()}}[o](){if(this[s]&&typeof this[l]=="number"){let d=this[l];this[l]=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[A]=!1,this[V]=!1,this[a]=!1,this[y]=!1,this[w]=[],this[O]=d,this[l]=typeof m.fd=="number"?m.fd:null,this[g]=m.mode===void 0?438:m.mode,this[I]=typeof m.start=="number"?m.start:null,this[s]=typeof m.autoClose=="boolean"?m.autoClose:!0;let _=this[I]!==null?"r+":"w";this[N]=m.flags===void 0,this[u]=this[N]?_:m.flags,this[l]===null&&this[T]()}emit(d,m){if(d==="error"){if(this[A])return;this[A]=!0}return super.emit(d,m)}get fd(){return this[l]}get path(){return this[O]}[b](d){this[o](),this[V]=!0,this.emit("error",d)}[T](){i.open(this[O],this[u],this[g],(d,m)=>this[x](d,m))}[x](d,m){this[N]&&this[u]==="r+"&&d&&d.code==="ENOENT"?(this[u]="w",this[T]()):d?this[b](d):(this[l]=m,this.emit("open",m),this[f]())}end(d,m){return d&&this.write(d,m),this[a]=!0,!this[V]&&!this[w].length&&typeof this[l]=="number"&&this[C](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[l]===null||this[V]||this[w].length?(this[w].push(d),this[y]=!0,!1):(this[V]=!0,this[K](d),!0)}[K](d){i.write(this[l],d,0,d.length,this[I],(m,_)=>this[C](m,_))}[C](d,m){d?this[b](d):(this[I]!==null&&(this[I]+=m),this[w].length?this[f]():(this[V]=!1,this[a]&&!this[c]?(this[c]=!0,this[o](),this.emit("finish")):this[y]&&(this[y]=!1,this.emit("drain"))))}[f](){if(this[w].length===0)this[a]&&this[C](null,0);else if(this[w].length===1)this[K](this[w].pop());else{let d=this[w];this[w]=[],n(this[l],d,this[I],(m,_)=>this[C](m,_))}}[o](){if(this[s]&&typeof this[l]=="number"){let d=this[l];this[l]=null,i.close(d,m=>m?this.emit("error",m):this.emit("close"))}}},D=class extends z{[T](){let d;if(this[N]&&this[u]==="r+")try{d=i.openSync(this[O],this[u],this[g])}catch(m){if(m.code==="ENOENT")return this[u]="w",this[T]();throw m}else d=i.openSync(this[O],this[u],this[g]);this[x](null,d)}[o](){if(this[s]&&typeof this[l]=="number"){let d=this[l];this[l]=null,i.closeSync(d),this.emit("close")}}[K](d){let m=!0;try{this[C](null,i.writeSync(this[l],d,0,d.length,this[I])),m=!1}finally{if(m)try{this[o]()}catch{}}}};t.ReadStream=L,t.ReadStreamSync=j,t.WriteStream=z,t.WriteStreamSync=D}),Uh=ee((t,e)=>{"use strict";W();var r=qh(),i=Qn(),n=te("events"),s=aS(),o=1024*1024,a=jh(),l=$h(),c=rS(),{nextTick:u}=te("process"),f=Buffer.from([31,139]),h=Symbol("state"),p=Symbol("writeEntry"),g=Symbol("readEntry"),y=Symbol("nextEntry"),b=Symbol("processEntry"),x=Symbol("extendedHeader"),k=Symbol("globalExtendedHeader"),C=Symbol("meta"),T=Symbol("emitMeta"),O=Symbol("buffer"),I=Symbol("queue"),w=Symbol("ended"),v=Symbol("emittedEnd"),F=Symbol("emit"),q=Symbol("unzip"),P=Symbol("consumeChunk"),U=Symbol("consumeChunkSub"),K=Symbol("consumeBody"),V=Symbol("consumeMeta"),N=Symbol("consumeHeader"),A=Symbol("consuming"),L=Symbol("bufferConcat"),j=Symbol("maybeEnd"),z=Symbol("writing"),D=Symbol("aborted"),d=Symbol("onDone"),m=Symbol("sawValidEntry"),_=Symbol("sawNullBlock"),R=Symbol("sawEOF"),E=Symbol("closeStream"),M=B=>!0;e.exports=r(class extends n{constructor(B){B=B||{},super(B),this.file=B.file||"",this[m]=null,this.on(d,Z=>{(this[h]==="begin"||this[m]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),B.ondone?this.on(d,B.ondone):this.on(d,Z=>{this.emit("prefinish"),this.emit("finish"),this.emit("end")}),this.strict=!!B.strict,this.maxMetaEntrySize=B.maxMetaEntrySize||o,this.filter=typeof B.filter=="function"?B.filter:M,this.writable=!0,this.readable=!1,this[I]=new s,this[O]=null,this[g]=null,this[p]=null,this[h]="begin",this[C]="",this[x]=null,this[k]=null,this[w]=!1,this[q]=null,this[D]=!1,this[_]=!1,this[R]=!1,this.on("end",()=>this[E]()),typeof B.onwarn=="function"&&this.on("warn",B.onwarn),typeof B.onentry=="function"&&this.on("entry",B.onentry)}[N](B,Z){this[m]===null&&(this[m]=!1);let H;try{H=new i(B,Z,this[x],this[k])}catch(J){return this.warn("TAR_ENTRY_INVALID",J)}if(H.nullBlock)this[_]?(this[R]=!0,this[h]==="begin"&&(this[h]="header"),this[F]("eof")):(this[_]=!0,this[F]("nullBlock"));else if(this[_]=!1,!H.cksumValid)this.warn("TAR_ENTRY_INVALID","checksum failure",{header:H});else if(!H.path)this.warn("TAR_ENTRY_INVALID","path is required",{header:H});else{let J=H.type;if(/^(Symbolic)?Link$/.test(J)&&!H.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath required",{header:H});else if(!/^(Symbolic)?Link$/.test(J)&&H.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath forbidden",{header:H});else{let G=this[p]=new a(H,this[x],this[k]);if(!this[m])if(G.remain){let re=()=>{G.invalid||(this[m]=!0)};G.on("end",re)}else this[m]=!0;G.meta?G.size>this.maxMetaEntrySize?(G.ignore=!0,this[F]("ignoredEntry",G),this[h]="ignore",G.resume()):G.size>0&&(this[C]="",G.on("data",re=>this[C]+=re),this[h]="meta"):(this[x]=null,G.ignore=G.ignore||!this.filter(G.path,G),G.ignore?(this[F]("ignoredEntry",G),this[h]=G.remain?"ignore":"header",G.resume()):(G.remain?this[h]="body":(this[h]="header",G.end()),this[g]?this[I].push(G):(this[I].push(G),this[y]())))}}}[E](){u(()=>this.emit("close"))}[b](B){let Z=!0;return B?Array.isArray(B)?this.emit.apply(this,B):(this[g]=B,this.emit("entry",B),B.emittedEnd||(B.on("end",H=>this[y]()),Z=!1)):(this[g]=null,Z=!1),Z}[y](){do;while(this[b](this[I].shift()));if(!this[I].length){let B=this[g];!B||B.flowing||B.size===B.remain?this[z]||this.emit("drain"):B.once("drain",Z=>this.emit("drain"))}}[K](B,Z){let H=this[p],J=H.blockRemain,G=J>=B.length&&Z===0?B:B.slice(Z,Z+J);return H.write(G),H.blockRemain||(this[h]="header",this[p]=null,H.end()),G.length}[V](B,Z){let H=this[p],J=this[K](B,Z);return this[p]||this[T](H),J}[F](B,Z,H){!this[I].length&&!this[g]?this.emit(B,Z,H):this[I].push([B,Z,H])}[T](B){switch(this[F]("meta",this[C]),B.type){case"ExtendedHeader":case"OldExtendedHeader":this[x]=l.parse(this[C],this[x],!1);break;case"GlobalExtendedHeader":this[k]=l.parse(this[C],this[k],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[x]=this[x]||Object.create(null),this[x].path=this[C].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[x]=this[x]||Object.create(null),this[x].linkpath=this[C].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+B.type)}}abort(B){this[D]=!0,this.emit("abort",B),this.warn("TAR_ABORT",B,{recoverable:!1})}write(B){if(this[D])return;if(this[q]===null&&B){if(this[O]&&(B=Buffer.concat([this[O],B]),this[O]=null),B.length<f.length)return this[O]=B,!0;for(let H=0;this[q]===null&&H<f.length;H++)B[H]!==f[H]&&(this[q]=!1);if(this[q]===null){let H=this[w];this[w]=!1,this[q]=new c.Unzip,this[q].on("data",G=>this[P](G)),this[q].on("error",G=>this.abort(G)),this[q].on("end",G=>{this[w]=!0,this[P]()}),this[z]=!0;let J=this[q][H?"end":"write"](B);return this[z]=!1,J}}this[z]=!0,this[q]?this[q].write(B):this[P](B),this[z]=!1;let Z=this[I].length?!1:this[g]?this[g].flowing:!0;return!Z&&!this[I].length&&this[g].once("drain",H=>this.emit("drain")),Z}[L](B){B&&!this[D]&&(this[O]=this[O]?Buffer.concat([this[O],B]):B)}[j](){if(this[w]&&!this[v]&&!this[D]&&!this[A]){this[v]=!0;let B=this[p];if(B&&B.blockRemain){let Z=this[O]?this[O].length:0;this.warn("TAR_BAD_ARCHIVE",`Truncated input (needed ${B.blockRemain} more bytes, only ${Z} available)`,{entry:B}),this[O]&&B.write(this[O]),B.end()}this[F](d)}}[P](B){if(this[A])this[L](B);else if(!B&&!this[O])this[j]();else{if(this[A]=!0,this[O]){this[L](B);let Z=this[O];this[O]=null,this[U](Z)}else this[U](B);for(;this[O]&&this[O].length>=512&&!this[D]&&!this[R];){let Z=this[O];this[O]=null,this[U](Z)}this[A]=!1}(!this[O]||this[w])&&this[j]()}[U](B){let Z=0,H=B.length;for(;Z+512<=H&&!this[D]&&!this[R];)switch(this[h]){case"begin":case"header":this[N](B,Z),Z+=512;break;case"ignore":case"body":Z+=this[K](B,Z);break;case"meta":Z+=this[V](B,Z);break;default:throw new Error("invalid state: "+this[h])}Z<H&&(this[O]?this[O]=Buffer.concat([B.slice(Z),this[O]]):this[O]=B.slice(Z))}end(B){this[D]||(this[q]?this[q].end(B):(this[w]=!0,this.write(B)))}})}),Gh=ee((t,e)=>{"use strict";W();var r=Xn(),i=Uh(),n=te("fs"),s=ts(),o=te("path"),a=es();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 b=r(p);if(b.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!b.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return g.length&&c(b,g),b.noResume||l(b),b.file&&b.sync?u(b):b.file?f(b,y):h(b)};var l=p=>{let g=p.onentry;p.onentry=g?y=>{g(y),y.resume()}:y=>y.resume()},c=(p,g)=>{let y=new Map(g.map(k=>[a(k),!0])),b=p.filter,x=(k,C)=>{let T=C||o.parse(k).root||".",O=k===T?!1:y.has(k)?y.get(k):x(o.dirname(k),T);return y.set(k,O),O};p.filter=b?(k,C)=>b(k,C)&&x(a(k)):k=>x(a(k))},u=p=>{let g=h(p),y=p.file,b=!0,x;try{let k=n.statSync(y),C=p.maxReadSize||16*1024*1024;if(k.size<C)g.end(n.readFileSync(y));else{let T=0,O=Buffer.allocUnsafe(C);for(x=n.openSync(y,"r");T<k.size;){let I=n.readSync(x,O,0,C,T);T+=I,g.write(O.slice(0,I))}g.end()}b=!1}finally{if(b&&x)try{n.closeSync(x)}catch{}}},f=(p,g)=>{let y=new i(p),b=p.maxReadSize||16*1024*1024,x=p.file,k=new Promise((C,T)=>{y.on("error",T),y.on("end",C),n.stat(x,(O,I)=>{if(O)T(O);else{let w=new s.ReadStream(x,{readSize:b,size:I.size});w.on("error",T),w.pipe(y)}})});return g?k.then(g,g):k},h=p=>new i(p)}),uP=ee((t,e)=>{"use strict";W();var r=Xn(),i=Hh(),n=ts(),s=Gh(),o=te("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 b=r(p);if(b.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!b.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return b.file&&b.sync?a(b,g):b.file?l(b,g,y):b.sync?f(b,g):h(b,g)};var a=(p,g)=>{let y=new i.Sync(p),b=new n.WriteStreamSync(p.file,{mode:p.mode||438});y.pipe(b),c(y,g)},l=(p,g,y)=>{let b=new i(p),x=new n.WriteStream(p.file,{mode:p.mode||438});b.pipe(x);let k=new Promise((C,T)=>{x.on("error",T),x.on("close",C),b.on("error",T)});return u(b,g),y?k.then(y,y):k},c=(p,g)=>{g.forEach(y=>{y.charAt(0)==="@"?s({file:o.resolve(p.cwd,y.slice(1)),sync:!0,noResume:!0,onentry:b=>p.add(b)}):p.add(y)}),p.end()},u=(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:b=>p.add(b)}).then(b=>u(p,g));p.add(y)}p.end()},f=(p,g)=>{let y=new i.Sync(p);return c(y,g),y},h=(p,g)=>{let y=new i(p);return u(y,g),y}}),lS=ee((t,e)=>{"use strict";W();var r=Xn(),i=Hh(),n=te("fs"),s=ts(),o=Gh(),a=te("path"),l=Qn();e.exports=(g,y,b)=>{let x=r(g);if(!x.file)throw new TypeError("file is required");if(x.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),x.sync?c(x,y):f(x,y,b)};var c=(g,y)=>{let b=new i.Sync(g),x=!0,k,C;try{try{k=n.openSync(g.file,"r+")}catch(I){if(I.code==="ENOENT")k=n.openSync(g.file,"w+");else throw I}let T=n.fstatSync(k),O=Buffer.alloc(512);e:for(C=0;C<T.size;C+=512){for(let v=0,F=0;v<512;v+=F){if(F=n.readSync(k,O,v,O.length-v,C+v),C===0&&O[0]===31&&O[1]===139)throw new Error("cannot append to compressed archives");if(!F)break e}let I=new l(O);if(!I.cksumValid)break;let w=512*Math.ceil(I.size/512);if(C+w+512>T.size)break;C+=w,g.mtimeCache&&g.mtimeCache.set(I.path,I.mtime)}x=!1,u(g,b,C,k,y)}finally{if(x)try{n.closeSync(k)}catch{}}},u=(g,y,b,x,k)=>{let C=new s.WriteStreamSync(g.file,{fd:x,start:b});y.pipe(C),h(y,k)},f=(g,y,b)=>{y=Array.from(y);let x=new i(g),k=(T,O,I)=>{let w=(U,K)=>{U?n.close(T,V=>I(U)):I(null,K)},v=0;if(O===0)return w(null,0);let F=0,q=Buffer.alloc(512),P=(U,K)=>{if(U)return w(U);if(F+=K,F<512&&K)return n.read(T,q,F,q.length-F,v+F,P);if(v===0&&q[0]===31&&q[1]===139)return w(new Error("cannot append to compressed archives"));if(F<512)return w(null,v);let V=new l(q);if(!V.cksumValid)return w(null,v);let N=512*Math.ceil(V.size/512);if(v+N+512>O||(v+=N+512,v>=O))return w(null,v);g.mtimeCache&&g.mtimeCache.set(V.path,V.mtime),F=0,n.read(T,q,0,512,v,P)};n.read(T,q,0,512,v,P)},C=new Promise((T,O)=>{x.on("error",O);let I="r+",w=(v,F)=>{if(v&&v.code==="ENOENT"&&I==="r+")return I="w+",n.open(g.file,I,w);if(v)return O(v);n.fstat(F,(q,P)=>{if(q)return n.close(F,()=>O(q));k(F,P.size,(U,K)=>{if(U)return O(U);let V=new s.WriteStream(g.file,{fd:F,start:K});x.pipe(V),V.on("error",O),V.on("close",T),p(x,y)})})};n.open(g.file,I,w)});return b?C.then(b,b):C},h=(g,y)=>{y.forEach(b=>{b.charAt(0)==="@"?o({file:a.resolve(g.cwd,b.slice(1)),sync:!0,noResume:!0,onentry:x=>g.add(x)}):g.add(b)}),g.end()},p=(g,y)=>{for(;y.length;){let b=y.shift();if(b.charAt(0)==="@")return o({file:a.resolve(g.cwd,b.slice(1)),noResume:!0,onentry:x=>g.add(x)}).then(x=>p(g,y));g.add(b)}g.end()}}),hP=ee((t,e)=>{"use strict";W();var r=Xn(),i=lS();e.exports=(s,o,a)=>{let l=r(s);if(!l.file)throw new TypeError("file is required");if(l.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(l),i(l,o,a)};var n=s=>{let o=s.filter;s.mtimeCache||(s.mtimeCache=new Map),s.filter=o?(a,l)=>o(a,l)&&!(s.mtimeCache.get(a)>l.mtime):(a,l)=>!(s.mtimeCache.get(a)>l.mtime)}}),fP=ee((t,e)=>{W();var{promisify:r}=te("util"),i=te("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}),pP=ee((t,e)=>{W();var r=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:i,parse:n}=te("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:l}=n(o);if(a.test(o.substr(l.length)))throw Object.assign(new Error("Illegal characters in path."),{path:o,code:"EINVAL"})}return o};e.exports=s}),dP=ee((t,e)=>{W();var{dirname:r}=te("path"),i=(s,o,a=void 0)=>a===o?Promise.resolve():s.statAsync(o).then(l=>l.isDirectory()?a:void 0,l=>l.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(l){return l.code==="ENOENT"?n(s,r(o),o):void 0}};e.exports={findMade:i,findMadeSync:n}}),cS=ee((t,e)=>{W();var{dirname:r}=te("path"),i=(s,o,a)=>{o.recursive=!1;let l=r(s);return l===s?o.mkdirAsync(s,o).catch(c=>{if(c.code!=="EISDIR")throw c}):o.mkdirAsync(s,o).then(()=>a||s,c=>{if(c.code==="ENOENT")return i(l,o).then(u=>i(s,o,u));if(c.code!=="EEXIST"&&c.code!=="EROFS")throw c;return o.statAsync(s).then(u=>{if(u.isDirectory())return a;throw c},()=>{throw c})})},n=(s,o,a)=>{let l=r(s);if(o.recursive=!1,l===s)try{return o.mkdirSync(s,o)}catch(c){if(c.code!=="EISDIR")throw c;return}try{return o.mkdirSync(s,o),a||s}catch(c){if(c.code==="ENOENT")return n(s,o,n(l,o,a));if(c.code!=="EEXIST"&&c.code!=="EROFS")throw c;try{if(!o.statSync(s).isDirectory())throw c}catch{throw c}}};e.exports={mkdirpManual:i,mkdirpManualSync:n}}),mP=ee((t,e)=>{W();var{dirname:r}=te("path"),{findMade:i,findMadeSync:n}=dP(),{mkdirpManual:s,mkdirpManualSync:o}=cS(),a=(c,u)=>(u.recursive=!0,r(c)===c?u.mkdirAsync(c,u):i(u,c).then(f=>u.mkdirAsync(c,u).then(()=>f).catch(h=>{if(h.code==="ENOENT")return s(c,u);throw h}))),l=(c,u)=>{if(u.recursive=!0,r(c)===c)return u.mkdirSync(c,u);let f=n(u,c);try{return u.mkdirSync(c,u),f}catch(h){if(h.code==="ENOENT")return o(c,u);throw h}};e.exports={mkdirpNative:a,mkdirpNativeSync:l}}),gP=ee((t,e)=>{W();var r=te("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?l=>l.mkdir===r.mkdir:()=>!1,a=s?l=>l.mkdirSync===r.mkdirSync:()=>!1;e.exports={useNative:o,useNativeSync:a}}),yP=ee((t,e)=>{W();var r=fP(),i=pP(),{mkdirpNative:n,mkdirpNativeSync:s}=mP(),{mkdirpManual:o,mkdirpManualSync:a}=cS(),{useNative:l,useNativeSync:c}=gP(),u=(h,p)=>(h=i(h),p=r(p),l(p)?n(h,p):o(h,p)),f=(h,p)=>(h=i(h),p=r(p),c(p)?s(h,p):a(h,p));u.sync=f,u.native=(h,p)=>n(i(h),r(p)),u.manual=(h,p)=>o(i(h),r(p)),u.nativeSync=(h,p)=>s(i(h),r(p)),u.manualSync=(h,p)=>a(i(h),r(p)),e.exports=u}),bP=ee((t,e)=>{"use strict";W();var r=te("fs"),i=te("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=(C,T,O)=>{try{return r[s](C,T,O)}catch(I){if(I.code!=="ENOENT")throw I}},l=(C,T,O)=>{try{return r.chownSync(C,T,O)}catch(I){if(I.code!=="ENOENT")throw I}},c=o?(C,T,O,I)=>w=>{!w||w.code!=="EISDIR"?I(w):r.chown(C,T,O,I)}:(C,T,O,I)=>I,u=o?(C,T,O)=>{try{return a(C,T,O)}catch(I){if(I.code!=="EISDIR")throw I;l(C,T,O)}}:(C,T,O)=>a(C,T,O),f=process.version,h=(C,T,O)=>r.readdir(C,T,O),p=(C,T)=>r.readdirSync(C,T);/^v4\./.test(f)&&(h=(C,T,O)=>r.readdir(C,O));var g=(C,T,O,I)=>{r[n](C,T,O,c(C,T,O,w=>{I(w&&w.code!=="ENOENT"?w:null)}))},y=(C,T,O,I,w)=>{if(typeof T=="string")return r.lstat(i.resolve(C,T),(v,F)=>{if(v)return w(v.code!=="ENOENT"?v:null);F.name=T,y(C,F,O,I,w)});if(T.isDirectory())b(i.resolve(C,T.name),O,I,v=>{if(v)return w(v);let F=i.resolve(C,T.name);g(F,O,I,w)});else{let v=i.resolve(C,T.name);g(v,O,I,w)}},b=(C,T,O,I)=>{h(C,{withFileTypes:!0},(w,v)=>{if(w){if(w.code==="ENOENT")return I();if(w.code!=="ENOTDIR"&&w.code!=="ENOTSUP")return I(w)}if(w||!v.length)return g(C,T,O,I);let F=v.length,q=null,P=U=>{if(!q){if(U)return I(q=U);if(--F===0)return g(C,T,O,I)}};v.forEach(U=>y(C,U,T,O,P))})},x=(C,T,O,I)=>{if(typeof T=="string")try{let w=r.lstatSync(i.resolve(C,T));w.name=T,T=w}catch(w){if(w.code==="ENOENT")return;throw w}T.isDirectory()&&k(i.resolve(C,T.name),O,I),u(i.resolve(C,T.name),O,I)},k=(C,T,O)=>{let I;try{I=p(C,{withFileTypes:!0})}catch(w){if(w.code==="ENOENT")return;if(w.code==="ENOTDIR"||w.code==="ENOTSUP")return u(C,T,O);throw w}return I&&I.length&&I.forEach(w=>x(C,w,T,O)),u(C,T,O)};e.exports=b,b.sync=k}),_P=ee((t,e)=>{"use strict";W();var r=yP(),i=te("fs"),n=te("path"),s=bP(),o=Jn(),a=class extends Error{constructor(y,b){super("Cannot extract through symbolic link"),this.path=b,this.symlink=y}get name(){return"SylinkError"}},l=class extends Error{constructor(y,b){super(b+": Cannot cd into '"+y+"'"),this.path=y,this.code=b}get name(){return"CwdError"}},c=(y,b)=>y.get(o(b)),u=(y,b,x)=>y.set(o(b),x),f=(y,b)=>{i.stat(y,(x,k)=>{(x||!k.isDirectory())&&(x=new l(y,x&&x.code||"ENOTDIR")),b(x)})};e.exports=(y,b,x)=>{y=o(y);let k=b.umask,C=b.mode|448,T=(C&k)!==0,O=b.uid,I=b.gid,w=typeof O=="number"&&typeof I=="number"&&(O!==b.processUid||I!==b.processGid),v=b.preserve,F=b.unlink,q=b.cache,P=o(b.cwd),U=(V,N)=>{V?x(V):(u(q,y,!0),N&&w?s(N,O,I,A=>U(A)):T?i.chmod(y,C,x):x())};if(q&&c(q,y)===!0)return U();if(y===P)return f(y,U);if(v)return r(y,{mode:C}).then(V=>U(null,V),U);let K=o(n.relative(P,y)).split("/");h(P,K,C,q,F,P,null,U)};var h=(y,b,x,k,C,T,O,I)=>{if(!b.length)return I(null,O);let w=b.shift(),v=o(n.resolve(y+"/"+w));if(c(k,v))return h(v,b,x,k,C,T,O,I);i.mkdir(v,x,p(v,b,x,k,C,T,O,I))},p=(y,b,x,k,C,T,O,I)=>w=>{w?i.lstat(y,(v,F)=>{if(v)v.path=v.path&&o(v.path),I(v);else if(F.isDirectory())h(y,b,x,k,C,T,O,I);else if(C)i.unlink(y,q=>{if(q)return I(q);i.mkdir(y,x,p(y,b,x,k,C,T,O,I))});else{if(F.isSymbolicLink())return I(new a(y,y+"/"+b.join("/")));I(w)}}):(O=O||y,h(y,b,x,k,C,T,O,I))},g=y=>{let b=!1,x="ENOTDIR";try{b=i.statSync(y).isDirectory()}catch(k){x=k.code}finally{if(!b)throw new l(y,x)}};e.exports.sync=(y,b)=>{y=o(y);let x=b.umask,k=b.mode|448,C=(k&x)!==0,T=b.uid,O=b.gid,I=typeof T=="number"&&typeof O=="number"&&(T!==b.processUid||O!==b.processGid),w=b.preserve,v=b.unlink,F=b.cache,q=o(b.cwd),P=V=>{u(F,y,!0),V&&I&&s.sync(V,T,O),C&&i.chmodSync(y,k)};if(F&&c(F,y)===!0)return P();if(y===q)return g(q),P();if(w)return P(r.sync(y,k));let U=o(n.relative(q,y)).split("/"),K=null;for(let V=U.shift(),N=q;V&&(N+="/"+V);V=U.shift())if(N=o(n.resolve(N)),!c(F,N))try{i.mkdirSync(N,k),K=K||N,u(F,N,!0)}catch{let A=i.lstatSync(N);if(A.isDirectory()){u(F,N,!0);continue}else if(v){i.unlinkSync(N),i.mkdirSync(N,k),K=K||N,u(F,N,!0);continue}else if(A.isSymbolicLink())return new a(N,N+"/"+U.join("/"))}return P(K)}}),uS=ee((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])}),wP=ee((t,e)=>{W();var r=te("assert"),i=uS(),n=es(),{join:s}=te("path"),o=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,a=o==="win32";e.exports=()=>{let l=new Map,c=new Map,u=b=>b.split("/").slice(0,-1).reduce((x,k)=>(x.length&&(k=s(x[x.length-1],k)),x.push(k||"/"),x),[]),f=new Set,h=b=>{let x=c.get(b);if(!x)throw new Error("function does not have any path reservations");return{paths:x.paths.map(k=>l.get(k)),dirs:[...x.dirs].map(k=>l.get(k))}},p=b=>{let{paths:x,dirs:k}=h(b);return x.every(C=>C[0]===b)&&k.every(C=>C[0]instanceof Set&&C[0].has(b))},g=b=>f.has(b)||!p(b)?!1:(f.add(b),b(()=>y(b)),!0),y=b=>{if(!f.has(b))return!1;let{paths:x,dirs:k}=c.get(b),C=new Set;return x.forEach(T=>{let O=l.get(T);r.equal(O[0],b),O.length===1?l.delete(T):(O.shift(),typeof O[0]=="function"?C.add(O[0]):O[0].forEach(I=>C.add(I)))}),k.forEach(T=>{let O=l.get(T);r(O[0]instanceof Set),O[0].size===1&&O.length===1?l.delete(T):O[0].size===1?(O.shift(),C.add(O[0])):O[0].delete(b)}),f.delete(b),C.forEach(T=>g(T)),!0};return{check:p,reserve:(b,x)=>{b=a?["win32 parallelization disabled"]:b.map(C=>i(n(s(C))).toLowerCase());let k=new Set(b.map(C=>u(C)).reduce((C,T)=>C.concat(T)));return c.set(x,{dirs:k,paths:b}),b.forEach(C=>{let T=l.get(C);T?T.push(x):l.set(C,[x])}),k.forEach(C=>{let T=l.get(C);T?T[T.length-1]instanceof Set?T[T.length-1].add(x):T.push(new Set([x])):l.set(C,[new Set([x])])}),g(x)}}}}),SP=ee((t,e)=>{W();var r=process.env.__FAKE_PLATFORM__||process.platform,i=r==="win32",n=global.__FAKE_TESTING_FS__||te("fs"),{O_CREAT:s,O_TRUNC:o,O_WRONLY:a,UV_FS_O_FILEMAP:l=0}=n.constants,c=i&&!!l,u=512*1024,f=l|o|s|a;e.exports=c?h=>h<u?f:"w":()=>"w"}),hS=ee((t,e)=>{"use strict";W();var r=te("assert"),i=Uh(),n=te("fs"),s=ts(),o=te("path"),a=_P(),l=nS(),c=wP(),u=sS(),f=Jn(),h=es(),p=uS(),g=Symbol("onEntry"),y=Symbol("checkFs"),b=Symbol("checkFs2"),x=Symbol("pruneCache"),k=Symbol("isReusable"),C=Symbol("makeFs"),T=Symbol("file"),O=Symbol("directory"),I=Symbol("link"),w=Symbol("symlink"),v=Symbol("hardlink"),F=Symbol("unsupported"),q=Symbol("checkPath"),P=Symbol("mkdir"),U=Symbol("onError"),K=Symbol("pending"),V=Symbol("pend"),N=Symbol("unpend"),A=Symbol("ended"),L=Symbol("maybeClose"),j=Symbol("skip"),z=Symbol("doChown"),D=Symbol("uid"),d=Symbol("gid"),m=Symbol("checkedCwd"),_=te("crypto"),R=SP(),E=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,M=E==="win32",B=(S,Y)=>{if(!M)return n.unlink(S,Y);let X=S+".DELETE."+_.randomBytes(16).toString("hex");n.rename(S,X,oe=>{if(oe)return Y(oe);n.unlink(X,Y)})},Z=S=>{if(!M)return n.unlinkSync(S);let Y=S+".DELETE."+_.randomBytes(16).toString("hex");n.renameSync(S,Y),n.unlinkSync(Y)},H=(S,Y,X)=>S===S>>>0?S:Y===Y>>>0?Y:X,J=S=>p(h(f(S))).toLowerCase(),G=(S,Y)=>{Y=J(Y);for(let X of S.keys()){let oe=J(X);(oe===Y||oe.indexOf(Y+"/")===0)&&S.delete(X)}},re=S=>{for(let Y of S.keys())S.delete(Y)},ue=class extends i{constructor(S){if(S||(S={}),S.ondone=Y=>{this[A]=!0,this[L]()},super(S),this[m]=!1,this.reservations=c(),this.transform=typeof S.transform=="function"?S.transform:null,this.writable=!0,this.readable=!1,this[K]=0,this[A]=!1,this.dirCache=S.dirCache||new Map,typeof S.uid=="number"||typeof S.gid=="number"){if(typeof S.uid!="number"||typeof S.gid!="number")throw new TypeError("cannot set owner without number uid and gid");if(S.preserveOwner)throw new TypeError("cannot preserve owner in archive and also set owner explicitly");this.uid=S.uid,this.gid=S.gid,this.setOwner=!0}else this.uid=null,this.gid=null,this.setOwner=!1;S.preserveOwner===void 0&&typeof S.uid!="number"?this.preserveOwner=process.getuid&&process.getuid()===0:this.preserveOwner=!!S.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=S.forceChown===!0,this.win32=!!S.win32||M,this.newer=!!S.newer,this.keep=!!S.keep,this.noMtime=!!S.noMtime,this.preservePaths=!!S.preservePaths,this.unlink=!!S.unlink,this.cwd=f(o.resolve(S.cwd||process.cwd())),this.strip=+S.strip||0,this.processUmask=S.noChmod?0:process.umask(),this.umask=typeof S.umask=="number"?S.umask:this.processUmask,this.dmode=S.dmode||511&~this.umask,this.fmode=S.fmode||438&~this.umask,this.on("entry",Y=>this[g](Y))}warn(S,Y,X={}){return(S==="TAR_BAD_ARCHIVE"||S==="TAR_ABORT")&&(X.recoverable=!1),super.warn(S,Y,X)}[L](){this[A]&&this[K]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"))}[q](S){if(this.strip){let Y=f(S.path).split("/");if(Y.length<this.strip)return!1;if(S.path=Y.slice(this.strip).join("/"),S.type==="Link"){let X=f(S.linkpath).split("/");if(X.length>=this.strip)S.linkpath=X.slice(this.strip).join("/");else return!1}}if(!this.preservePaths){let Y=f(S.path),X=Y.split("/");if(X.includes("..")||M&&/^[a-z]:\.\.$/i.test(X[0]))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:S,path:Y}),!1;let[oe,ce]=u(Y);oe&&(S.path=ce,this.warn("TAR_ENTRY_INFO",`stripping ${oe} from absolute path`,{entry:S,path:Y}))}if(o.isAbsolute(S.path)?S.absolute=f(o.resolve(S.path)):S.absolute=f(o.resolve(this.cwd,S.path)),!this.preservePaths&&S.absolute.indexOf(this.cwd+"/")!==0&&S.absolute!==this.cwd)return this.warn("TAR_ENTRY_ERROR","path escaped extraction target",{entry:S,path:f(S.path),resolvedPath:S.absolute,cwd:this.cwd}),!1;if(S.absolute===this.cwd&&S.type!=="Directory"&&S.type!=="GNUDumpDir")return!1;if(this.win32){let{root:Y}=o.win32.parse(S.absolute);S.absolute=Y+l.encode(S.absolute.slice(Y.length));let{root:X}=o.win32.parse(S.path);S.path=X+l.encode(S.path.slice(X.length))}return!0}[g](S){if(!this[q](S))return S.resume();switch(r.equal(typeof S.absolute,"string"),S.type){case"Directory":case"GNUDumpDir":S.mode&&(S.mode=S.mode|448);case"File":case"OldFile":case"ContiguousFile":case"Link":case"SymbolicLink":return this[y](S);case"CharacterDevice":case"BlockDevice":case"FIFO":default:return this[F](S)}}[U](S,Y){S.name==="CwdError"?this.emit("error",S):(this.warn("TAR_ENTRY_ERROR",S,{entry:Y}),this[N](),Y.resume())}[P](S,Y,X){a(f(S),{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](S){return this.forceChown||this.preserveOwner&&(typeof S.uid=="number"&&S.uid!==this.processUid||typeof S.gid=="number"&&S.gid!==this.processGid)||typeof this.uid=="number"&&this.uid!==this.processUid||typeof this.gid=="number"&&this.gid!==this.processGid}[D](S){return H(this.uid,S.uid,this.processUid)}[d](S){return H(this.gid,S.gid,this.processGid)}[T](S,Y){let X=S.mode&4095||this.fmode,oe=new s.WriteStream(S.absolute,{flags:R(S.size),mode:X,autoClose:!1});oe.on("error",pe=>{oe.fd&&n.close(oe.fd,()=>{}),oe.write=()=>!0,this[U](pe,S),Y()});let ce=1,be=pe=>{if(pe){oe.fd&&n.close(oe.fd,()=>{}),this[U](pe,S),Y();return}--ce===0&&n.close(oe.fd,Re=>{Re?this[U](Re,S):this[N](),Y()})};oe.on("finish",pe=>{let Re=S.absolute,dt=oe.fd;if(S.mtime&&!this.noMtime){ce++;let mt=S.atime||new Date,un=S.mtime;n.futimes(dt,mt,un,hn=>hn?n.utimes(Re,mt,un,Ea=>be(Ea&&hn)):be())}if(this[z](S)){ce++;let mt=this[D](S),un=this[d](S);n.fchown(dt,mt,un,hn=>hn?n.chown(Re,mt,un,Ea=>be(Ea&&hn)):be())}be()});let he=this.transform&&this.transform(S)||S;he!==S&&(he.on("error",pe=>{this[U](pe,S),Y()}),S.pipe(he)),he.pipe(oe)}[O](S,Y){let X=S.mode&4095||this.dmode;this[P](S.absolute,X,oe=>{if(oe){this[U](oe,S),Y();return}let ce=1,be=he=>{--ce===0&&(Y(),this[N](),S.resume())};S.mtime&&!this.noMtime&&(ce++,n.utimes(S.absolute,S.atime||new Date,S.mtime,be)),this[z](S)&&(ce++,n.chown(S.absolute,this[D](S),this[d](S),be)),be()})}[F](S){S.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${S.type}`,{entry:S}),S.resume()}[w](S,Y){this[I](S,S.linkpath,"symlink",Y)}[v](S,Y){let X=f(o.resolve(this.cwd,S.linkpath));this[I](S,X,"link",Y)}[V](){this[K]++}[N](){this[K]--,this[L]()}[j](S){this[N](),S.resume()}[k](S,Y){return S.type==="File"&&!this.unlink&&Y.isFile()&&Y.nlink<=1&&!M}[y](S){this[V]();let Y=[S.path];S.linkpath&&Y.push(S.linkpath),this.reservations.reserve(Y,X=>this[b](S,X))}[x](S){S.type==="SymbolicLink"?re(this.dirCache):S.type!=="Directory"&&G(this.dirCache,S.absolute)}[b](S,Y){this[x](S);let X=he=>{this[x](S),Y(he)},oe=()=>{this[P](this.cwd,this.dmode,he=>{if(he){this[U](he,S),X();return}this[m]=!0,ce()})},ce=()=>{if(S.absolute!==this.cwd){let he=f(o.dirname(S.absolute));if(he!==this.cwd)return this[P](he,this.dmode,pe=>{if(pe){this[U](pe,S),X();return}be()})}be()},be=()=>{n.lstat(S.absolute,(he,pe)=>{if(pe&&(this.keep||this.newer&&pe.mtime>S.mtime)){this[j](S),X();return}if(he||this[k](S,pe))return this[C](null,S,X);if(pe.isDirectory()){if(S.type==="Directory"){let Re=!this.noChmod&&S.mode&&(pe.mode&4095)!==S.mode,dt=mt=>this[C](mt,S,X);return Re?n.chmod(S.absolute,S.mode,dt):dt()}if(S.absolute!==this.cwd)return n.rmdir(S.absolute,Re=>this[C](Re,S,X))}if(S.absolute===this.cwd)return this[C](null,S,X);B(S.absolute,Re=>this[C](Re,S,X))})};this[m]?ce():oe()}[C](S,Y,X){if(S){this[U](S,Y),X();return}switch(Y.type){case"File":case"OldFile":case"ContiguousFile":return this[T](Y,X);case"Link":return this[v](Y,X);case"SymbolicLink":return this[w](Y,X);case"Directory":case"GNUDumpDir":return this[O](Y,X)}}[I](S,Y,X,oe){n[X](Y,S.absolute,ce=>{ce?this[U](ce,S):(this[N](),S.resume()),oe()})}},Ee=S=>{try{return[null,S()]}catch(Y){return[Y,null]}},_e=class extends ue{[C](S,Y){return super[C](S,Y,()=>{})}[y](S){if(this[x](S),!this[m]){let ce=this[P](this.cwd,this.dmode);if(ce)return this[U](ce,S);this[m]=!0}if(S.absolute!==this.cwd){let ce=f(o.dirname(S.absolute));if(ce!==this.cwd){let be=this[P](ce,this.dmode);if(be)return this[U](be,S)}}let[Y,X]=Ee(()=>n.lstatSync(S.absolute));if(X&&(this.keep||this.newer&&X.mtime>S.mtime))return this[j](S);if(Y||this[k](S,X))return this[C](null,S);if(X.isDirectory()){if(S.type==="Directory"){let be=!this.noChmod&&S.mode&&(X.mode&4095)!==S.mode,[he]=be?Ee(()=>{n.chmodSync(S.absolute,S.mode)}):[];return this[C](he,S)}let[ce]=Ee(()=>n.rmdirSync(S.absolute));this[C](ce,S)}let[oe]=S.absolute===this.cwd?[]:Ee(()=>Z(S.absolute));this[C](oe,S)}[T](S,Y){let X=S.mode&4095||this.fmode,oe=he=>{let pe;try{n.closeSync(ce)}catch(Re){pe=Re}(he||pe)&&this[U](he||pe,S),Y()},ce;try{ce=n.openSync(S.absolute,R(S.size),X)}catch(he){return oe(he)}let be=this.transform&&this.transform(S)||S;be!==S&&(be.on("error",he=>this[U](he,S)),S.pipe(be)),be.on("data",he=>{try{n.writeSync(ce,he,0,he.length)}catch(pe){oe(pe)}}),be.on("end",he=>{let pe=null;if(S.mtime&&!this.noMtime){let Re=S.atime||new Date,dt=S.mtime;try{n.futimesSync(ce,Re,dt)}catch(mt){try{n.utimesSync(S.absolute,Re,dt)}catch{pe=mt}}}if(this[z](S)){let Re=this[D](S),dt=this[d](S);try{n.fchownSync(ce,Re,dt)}catch(mt){try{n.chownSync(S.absolute,Re,dt)}catch{pe=pe||mt}}}oe(pe)})}[O](S,Y){let X=S.mode&4095||this.dmode,oe=this[P](S.absolute,X);if(oe){this[U](oe,S),Y();return}if(S.mtime&&!this.noMtime)try{n.utimesSync(S.absolute,S.atime||new Date,S.mtime)}catch{}if(this[z](S))try{n.chownSync(S.absolute,this[D](S),this[d](S))}catch{}Y(),S.resume()}[P](S,Y){try{return a.sync(f(S),{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}}[I](S,Y,X,oe){try{n[X+"Sync"](Y,S.absolute),oe(),S.resume()}catch(ce){return this[U](ce,S)}}};ue.Sync=_e,e.exports=ue}),EP=ee((t,e)=>{"use strict";W();var r=Xn(),i=hS(),n=te("fs"),s=ts(),o=te("path"),a=es();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 b=r(p);if(b.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!b.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return g.length&&l(b,g),b.file&&b.sync?c(b):b.file?u(b,y):b.sync?f(b):h(b)};var l=(p,g)=>{let y=new Map(g.map(k=>[a(k),!0])),b=p.filter,x=(k,C)=>{let T=C||o.parse(k).root||".",O=k===T?!1:y.has(k)?y.get(k):x(o.dirname(k),T);return y.set(k,O),O};p.filter=b?(k,C)=>b(k,C)&&x(a(k)):k=>x(a(k))},c=p=>{let g=new i.Sync(p),y=p.file,b=n.statSync(y),x=p.maxReadSize||16*1024*1024;new s.ReadStreamSync(y,{readSize:x,size:b.size}).pipe(g)},u=(p,g)=>{let y=new i(p),b=p.maxReadSize||16*1024*1024,x=p.file,k=new Promise((C,T)=>{y.on("error",T),y.on("close",C),n.stat(x,(O,I)=>{if(O)T(O);else{let w=new s.ReadStream(x,{readSize:b,size:I.size});w.on("error",T),w.pipe(y)}})});return g?k.then(g,g):k},f=p=>new i.Sync(p),h=p=>new i(p)}),vP=ee(t=>{"use strict";W(),t.c=t.create=uP(),t.r=t.replace=lS(),t.t=t.list=Gh(),t.u=t.update=hP(),t.x=t.extract=EP(),t.Pack=Hh(),t.Unpack=hS(),t.Parse=Uh(),t.ReadEntry=jh(),t.WriteEntry=oS(),t.Header=Qn(),t.Pax=$h(),t.types=iS()}),RP=ee((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],l=a.message,c=(i[l]||0)+1;i[l]=c,c>=s&&(n=a,s=c)}return n}}),xP=ee(t=>{W();var e=RP();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,l){return a-l}),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],l=r[a];r[a]=function(c){var u=t.operation(i),f=Array.prototype.slice.call(arguments,1),h=f.pop();f.push(function(p){u.retry(p)||(p&&(arguments[0]=u.mainError()),h.apply(this,arguments))}),u.attempt(function(){c.apply(r,f)})}.bind(r,l),r[a].options=i}}}),AP=ee((t,e)=>{W(),e.exports=xP()}),OP=ee((t,e)=>{W();var r=AP();function i(n,s){function o(a,l){var c=s||{},u;"randomize"in c||(c.randomize=!0),u=r.operation(c);function f(g){l(g||new Error("Aborted"))}function h(g,y){if(g.bail){f(g);return}u.retry(g)?c.onRetry&&c.onRetry(g,y):l(u.mainError())}function p(g){var y;try{y=n(f,g)}catch(b){h(b,g);return}Promise.resolve(y).then(a).catch(function(b){h(b,g)})}u.attempt(p)}return new Promise(o)}e.exports=i}),TP={};VL(TP,{bold:()=>IP,dimmed:()=>DP,error:()=>jP,grey:()=>MP,info:()=>PP,item:()=>FP,log:()=>si,turboBlue:()=>tn,turboGradient:()=>CP,turboLoader:()=>LP,turboRed:()=>gS,underline:()=>NP,warn:()=>BP,yellow:()=>yS});W();var dS="#0099F7",mS="#F11712",kP="#FFFF00",zh=t=>{let e=$P(t);return r=>`\x1B[38;5;${e}m${r}${(0,Xe.reset)("")}`},CP=(0,pS.default)(dS,mS),tn=zh(dS),gS=zh(mS),yS=zh(kP),LP=t=>(0,fS.default)({text:t,spinner:{frames:[" ",tn("> "),tn(">> "),tn(">>>")]}}),PP=(...t)=>{si(tn((0,Xe.bold)(">>>")),t.join(" "))},IP=(...t)=>{si((0,Xe.bold)(t.join(" ")))},NP=(...t)=>{si((0,Xe.underline)(t.join(" ")))},DP=(...t)=>{si((0,Xe.dim)(t.join(" ")))},MP=(...t)=>{si((0,Xe.gray)(t.join(" ")))},FP=(...t)=>{si(tn((0,Xe.bold)(" \u2022")),t.join(" "))},si=(...t)=>{console.log(...t)},BP=(...t)=>{console.error(yS((0,Xe.bold)(">>>")),t.join(" "))},jP=(...t)=>{console.error(gS((0,Xe.bold)(">>>")),t.join(" "))};function $P(t){let e=parseInt(t.slice(1),16),r=Math.floor(e/(256*256))%256,i=Math.floor(e/256)%256,n=e%256;return 16+36*Math.round(r/255*5)+6*Math.round(i/255*5)+Math.round(n/255*5)}W();W();W();W();var rB=ua(QL());W();W();function HP(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}W();W();function Dh(t){return Dh=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},Dh(t)}W();function UP(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function GP(t,e){if(e&&(Dh(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return UP(t)}W();function ca(t){return ca=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ca(t)}W();W();function Kn(t,e){return Kn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Kn(t,e)}function zP(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&&Kn(t,e)}W();W();function WP(t){return Function.toString.call(t).indexOf("[native code]")!==-1}W();W();function YP(){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 la(t,e,r){return YP()?la=Reflect.construct.bind():la=function(i,n,s){var o=[null];o.push.apply(o,n);var a=Function.bind.apply(i,o),l=new a;return s&&Kn(l,s.prototype),l},la.apply(null,arguments)}function Mh(t){var e=typeof Map=="function"?new Map:void 0;return Mh=function(r){if(r===null||!WP(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 la(r,arguments,ca(this).constructor)}return i.prototype=Object.create(r.prototype,{constructor:{value:i,enumerable:!1,writable:!0,configurable:!0}}),Kn(i,r)},Mh(t)}var iB=ua(sP()),oB=function(t){zP(e,t);function e(r){var i;return HP(this,e),i=GP(this,ca(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),i.directory=r,i}return e}(Mh(Error));W();W();W();W();W();W();var yB=ua(vP()),bB=(0,_S.promisify)(bS.Stream.pipeline);W();W();var EB=ua(OP());W();W();W();var $e=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,$e)}};W();W();W();W();var KP=/^(?!_)(?<manager>.+)@(?<version>.+)$/;function Je({workspaceRoot:t}){let e=sr.default.join(t,"package.json");try{return(0,st.readJsonSync)(e,"utf8")}catch(r){if(r&&typeof r=="object"&&"code"in r){if(r.code==="ENOENT")throw new $e(`no "package.json" found at ${t}`,{type:"package_json-missing"});if(r.code==="EJSONPARSE")throw new $e(`failed to parse "package.json" at ${t}`,{type:"package_json-parse_error"})}throw new Error(`unexpected error reading "package.json" at ${t}`)}}function ha({workspaceRoot:t}){let{packageManager:e}=Je({workspaceRoot:t});if(e)try{let r=KP.exec(e);if(r){let[i,n]=r;return n}}catch{}}function rs({workspaceRoot:t}){let e=Je({workspaceRoot:t}),r=sr.default.basename(t),{name:i=r,description:n}=e;return{name:i,description:n}}function Jw({workspaceRoot:t}){let e=sr.default.join(t,"pnpm-workspace.yaml");if((0,st.existsSync)(e))try{let r=za.load((0,st.readFileSync)(e,"utf8"));if(r instanceof Object&&"packages"in r&&Array.isArray(r.packages))return r.packages}catch{throw new $e(`failed to parse ${e}`,{type:"pnpm-workspace_parse_error"})}return[]}function fa({root:t,lockFile:e,workspaceConfig:r}){let i=s=>sr.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 Wh({workspaces:t}){var e;return t?Array.isArray(t)?t:"packages"in t?(e=t.packages)!=null?e:[]:[]:[]}function pa({workspaceRoot:t,workspaceGlobs:e}){if(!e)return[];let r=e.filter(i=>i.startsWith("!")).map(i=>i.slice(1));return e.filter(i=>!i.startsWith("!")).flatMap(i=>{let n=[`${i}/package.json`];return(0,xS.sync)(n,{onlyFiles:!0,absolute:!0,cwd:t,ignore:["**/node_modules/**",...r]})}).map(i=>{let n=sr.default.dirname(i),{name:s,description:o}=rs({workspaceRoot:n});return{name:s,description:o,paths:{root:n,packageJson:i,nodeModules:sr.default.join(n,"node_modules")}}})}function VP({directory:t}){let e=sr.default.resolve(process.cwd(),t);return{exists:(0,st.existsSync)(e),absolute:e}}function Pr({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 ZP({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 nr({project:t,options:e}){e!=null&&e.dry||(0,st.rmSync)(t.paths.lockfile,{force:!0})}async function AS({project:t,options:e}){if(!(e!=null&&e.dry)&&(0,st.existsSync)(t.paths.lockfile))try{let{stdout:r}=await(0,RS.default)("bun",["bun.lockb"],{stdin:"ignore",cwd:t.paths.root});await(0,st.writeFile)(sr.default.join(t.paths.root,"yarn.lock"),r)}catch{}finally{(0,st.rmSync)(t.paths.lockfile,{force:!0})}}function XP({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 Cr({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=Je({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}=XP({dependencyList:h,project:t,to:r});s[f]=g,o[f]=p}});let l=f=>{let h=o[f].length;if(h>0)return`${(0,vS.green)(h.toString())} ${f}`},c=a.map(l).filter(Boolean),u=`./${SS.default.relative(t.paths.root,e.paths.packageJson)}`;if(c.length>=1){let f="updating";c.forEach((h,p)=>{c.length===1?f+=` ${h} in ${u}`:p===c.length-1?f+=`and ${h} in ${u}`:f+=` ${h}, `}),i.workspaceStep(f)}else i.workspaceStep(`no workspace dependencies found in ${u}`);n!=null&&n.dry||(0,ES.writeJSONSync)(e.paths.packageJson,s,{spaces:2})}var Lr={name:"pnpm",lock:"pnpm-lock.yaml"};async function OS(t){let e=ii.default.join(t.workspaceRoot,Lr.lock),r=ii.default.join(t.workspaceRoot,"pnpm-workspace.yaml"),i=ha({workspaceRoot:t.workspaceRoot});return(0,Ue.existsSync)(e)||(0,Ue.existsSync)(r)||i===Lr.name}async function JP(t){if(!await OS(t))throw new $e("Not a pnpm project",{type:"package_manager-unexpected"});let{name:e,description:r}=rs(t);return{name:e,description:r,packageManager:Lr.name,paths:fa({root:t.workspaceRoot,lockFile:Lr.lock,workspaceConfig:"pnpm-workspace.yaml"}),workspaceData:{globs:Jw(t),workspaces:pa({workspaceGlobs:Jw(t),...t})}}}async function QP(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;i.mainStep(Pr({action:"create",packageManager:Lr.name,project:e}));let o=Je({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,Ue.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),s&&(i.rootStep('adding "pnpm-workspace.yaml"'),(0,Ue.writeFileSync)(ii.default.join(e.paths.root,"pnpm-workspace.yaml"),`packages:
|
42
|
+
`).reduce(a,Object.create(null)),a=(l,c)=>{let u=parseInt(c,10);if(u!==Buffer.byteLength(c)+1)return l;c=c.slice((u+" ").length);let f=c.split("="),h=f.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!h)return l;let p=f.join("=");return l[h]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(h)?new Date(p*1e3):/^[0-9]+$/.test(p)?+p:p,l};e.exports=n}),es=ee((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)}}),qh=ee((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))}}}),nS=ee((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,l)=>a.split(l).join(n.get(l)),o),decode:o=>i.reduce((a,l)=>a.split(l).join(s.get(l)),o)}}),sS=ee((t,e)=>{W();var{isAbsolute:r,parse:i}=te("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]}}),lP=ee((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)}),oS=ee((t,e)=>{"use strict";W();var r=Bh(),i=$h(),n=Qn(),s=te("fs"),o=te("path"),a=Jn(),l=es(),c=(m,_)=>_?(m=a(m).replace(/^\.(\/|$)/,""),l(_)+"/"+m):a(m),u=16*1024*1024,f=Symbol("process"),h=Symbol("file"),p=Symbol("directory"),g=Symbol("symlink"),y=Symbol("hardlink"),b=Symbol("header"),x=Symbol("read"),k=Symbol("lstat"),C=Symbol("onlstat"),T=Symbol("onread"),O=Symbol("onreadlink"),I=Symbol("openfile"),w=Symbol("onopenfile"),v=Symbol("close"),F=Symbol("mode"),q=Symbol("awaitDrain"),P=Symbol("ondrain"),U=Symbol("prefix"),V=Symbol("hadError"),K=qh(),N=nS(),A=sS(),L=lP(),j=K(class extends r{constructor(m,_){if(_=_||{},super(_),typeof m!="string")throw new TypeError("path is required");this.path=a(m),this.portable=!!_.portable,this.myuid=process.getuid&&process.getuid()||0,this.myuser=process.env.USER||"",this.maxReadSize=_.maxReadSize||u,this.linkCache=_.linkCache||new Map,this.statCache=_.statCache||new Map,this.preservePaths=!!_.preservePaths,this.cwd=a(_.cwd||process.cwd()),this.strict=!!_.strict,this.noPax=!!_.noPax,this.noMtime=!!_.noMtime,this.mtime=_.mtime||null,this.prefix=_.prefix?a(_.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 _.onwarn=="function"&&this.on("warn",_.onwarn);let R=!1;if(!this.preservePaths){let[E,M]=A(this.path);E&&(this.path=M,R=E)}this.win32=!!_.win32||process.platform==="win32",this.win32&&(this.path=N.decode(this.path.replace(/\\/g,"/")),m=m.replace(/\\/g,"/")),this.absolute=a(_.absolute||o.resolve(this.cwd,m)),this.path===""&&(this.path="./"),R&&this.warn("TAR_ENTRY_INFO",`stripping ${R} from absolute path`,{entry:this,path:R+this.path}),this.statCache.has(this.absolute)?this[C](this.statCache.get(this.absolute)):this[k]()}emit(m,..._){return m==="error"&&(this[V]=!0),super.emit(m,..._)}[k](){s.lstat(this.absolute,(m,_)=>{if(m)return this.emit("error",m);this[C](_)})}[C](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()}}[F](m){return L(m,this.type==="Directory",this.portable)}[U](m){return c(m,this.prefix)}[b](){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[F](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[b](),this.end()}[g](){s.readlink(this.absolute,(m,_)=>{if(m)return this.emit("error",m);this[O](_)})}[O](m){this.linkpath=a(m),this[b](),this.end()}[y](m){this.type="Link",this.linkpath=a(o.relative(this.cwd,m)),this.stat.size=0,this[b](),this.end()}[h](){if(this.stat.nlink>1){let m=this.stat.dev+":"+this.stat.ino;if(this.linkCache.has(m)){let _=this.linkCache.get(m);if(_.indexOf(this.cwd)===0)return this[y](_)}this.linkCache.set(m,this.absolute)}if(this[b](),this.stat.size===0)return this.end();this[I]()}[I](){s.open(this.absolute,"r",(m,_)=>{if(m)return this.emit("error",m);this[w](_)})}[w](m){if(this.fd=m,this[V])return this[v]();this.blockLen=512*Math.ceil(this.stat.size/512),this.blockRemain=this.blockLen;let _=Math.min(this.blockLen,this.maxReadSize);this.buf=Buffer.allocUnsafe(_),this.offset=0,this.pos=0,this.remain=this.stat.size,this.length=this.buf.length,this[x]()}[x](){let{fd:m,buf:_,offset:R,length:E,pos:M}=this;s.read(m,_,R,E,M,(B,Z)=>{if(B)return this[v](()=>this.emit("error",B));this[T](Z)})}[v](m){s.close(this.fd,m)}[T](m){if(m<=0&&this.remain>0){let R=new Error("encountered unexpected EOF");return R.path=this.absolute,R.syscall="read",R.code="EOF",this[v](()=>this.emit("error",R))}if(m>this.remain){let R=new Error("did not encounter expected EOF");return R.path=this.absolute,R.syscall="read",R.code="EOF",this[v](()=>this.emit("error",R))}if(m===this.remain)for(let R=m;R<this.length&&m<this.blockRemain;R++)this.buf[R+this.offset]=0,m++,this.remain++;let _=this.offset===0&&m===this.buf.length?this.buf:this.buf.slice(this.offset,this.offset+m);this.write(_)?this[P]():this[q](()=>this[P]())}[q](m){this.once("drain",m)}write(m){if(this.blockRemain<m.length){let _=new Error("writing more data than expected");return _.path=this.absolute,this.emit("error",_)}return this.remain-=m.length,this.blockRemain-=m.length,this.pos+=m.length,this.offset+=m.length,super.write(m)}[P](){if(!this.remain)return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),this[v](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[x]()}}),z=class extends j{[k](){this[C](s.lstatSync(this.absolute))}[g](){this[O](s.readlinkSync(this.absolute))}[I](){this[w](s.openSync(this.absolute,"r"))}[x](){let m=!0;try{let{fd:_,buf:R,offset:E,length:M,pos:B}=this,Z=s.readSync(_,R,E,M,B);this[T](Z),m=!1}finally{if(m)try{this[v](()=>{})}catch{}}}[q](m){m()}[v](m){s.closeSync(this.fd),m()}},D=K(class extends r{constructor(m,_){_=_||{},super(_),this.preservePaths=!!_.preservePaths,this.portable=!!_.portable,this.strict=!!_.strict,this.noPax=!!_.noPax,this.noMtime=!!_.noMtime,this.readEntry=m,this.type=m.type,this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.prefix=_.prefix||null,this.path=a(m.path),this.mode=this[F](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:_.mtime||m.mtime,this.atime=this.portable?null:m.atime,this.ctime=this.portable?null:m.ctime,this.linkpath=a(m.linkpath),typeof _.onwarn=="function"&&this.on("warn",_.onwarn);let R=!1;if(!this.preservePaths){let[E,M]=A(this.path);E&&(this.path=M,R=E)}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}),R&&this.warn("TAR_ENTRY_INFO",`stripping ${R} from absolute path`,{entry:this,path:R+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 c(m,this.prefix)}[F](m){return L(m,this.type==="Directory",this.portable)}write(m){let _=m.length;if(_>this.blockRemain)throw new Error("writing more to entry than is appropriate");return this.blockRemain-=_,super.write(m)}end(){return this.blockRemain&&super.write(Buffer.alloc(this.blockRemain)),super.end()}});j.Sync=z,j.Tar=D;var d=m=>m.isFile()?"File":m.isDirectory()?"Directory":m.isSymbolicLink()?"SymbolicLink":"Unsupported";e.exports=j}),cP=ee((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}}}),aS=ee((t,e)=>{"use strict";W(),e.exports=r,r.Node=o,r.create=r;function r(a){var l=this;if(l instanceof r||(l=new r),l.tail=null,l.head=null,l.length=0,a&&typeof a.forEach=="function")a.forEach(function(f){l.push(f)});else if(arguments.length>0)for(var c=0,u=arguments.length;c<u;c++)l.push(arguments[c]);return l}r.prototype.removeNode=function(a){if(a.list!==this)throw new Error("removing node which does not belong to this list");var l=a.next,c=a.prev;return l&&(l.prev=c),c&&(c.next=l),a===this.head&&(this.head=l),a===this.tail&&(this.tail=c),a.list.length--,a.next=null,a.prev=null,a.list=null,l},r.prototype.unshiftNode=function(a){if(a!==this.head){a.list&&a.list.removeNode(a);var l=this.head;a.list=this,a.next=l,l&&(l.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 l=this.tail;a.list=this,a.prev=l,l&&(l.next=a),this.tail=a,this.head||(this.head=a),this.length++}},r.prototype.push=function(){for(var a=0,l=arguments.length;a<l;a++)n(this,arguments[a]);return this.length},r.prototype.unshift=function(){for(var a=0,l=arguments.length;a<l;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,l){l=l||this;for(var c=this.head,u=0;c!==null;u++)a.call(l,c.value,u,this),c=c.next},r.prototype.forEachReverse=function(a,l){l=l||this;for(var c=this.tail,u=this.length-1;c!==null;u--)a.call(l,c.value,u,this),c=c.prev},r.prototype.get=function(a){for(var l=0,c=this.head;c!==null&&l<a;l++)c=c.next;if(l===a&&c!==null)return c.value},r.prototype.getReverse=function(a){for(var l=0,c=this.tail;c!==null&&l<a;l++)c=c.prev;if(l===a&&c!==null)return c.value},r.prototype.map=function(a,l){l=l||this;for(var c=new r,u=this.head;u!==null;)c.push(a.call(l,u.value,this)),u=u.next;return c},r.prototype.mapReverse=function(a,l){l=l||this;for(var c=new r,u=this.tail;u!==null;)c.push(a.call(l,u.value,this)),u=u.prev;return c},r.prototype.reduce=function(a,l){var c,u=this.head;if(arguments.length>1)c=l;else if(this.head)u=this.head.next,c=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=0;u!==null;f++)c=a(c,u.value,f),u=u.next;return c},r.prototype.reduceReverse=function(a,l){var c,u=this.tail;if(arguments.length>1)c=l;else if(this.tail)u=this.tail.prev,c=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=this.length-1;u!==null;f--)c=a(c,u.value,f),u=u.prev;return c},r.prototype.toArray=function(){for(var a=new Array(this.length),l=0,c=this.head;c!==null;l++)a[l]=c.value,c=c.next;return a},r.prototype.toArrayReverse=function(){for(var a=new Array(this.length),l=0,c=this.tail;c!==null;l++)a[l]=c.value,c=c.prev;return a},r.prototype.slice=function(a,l){l=l||this.length,l<0&&(l+=this.length),a=a||0,a<0&&(a+=this.length);var c=new r;if(l<a||l<0)return c;a<0&&(a=0),l>this.length&&(l=this.length);for(var u=0,f=this.head;f!==null&&u<a;u++)f=f.next;for(;f!==null&&u<l;u++,f=f.next)c.push(f.value);return c},r.prototype.sliceReverse=function(a,l){l=l||this.length,l<0&&(l+=this.length),a=a||0,a<0&&(a+=this.length);var c=new r;if(l<a||l<0)return c;a<0&&(a=0),l>this.length&&(l=this.length);for(var u=this.length,f=this.tail;f!==null&&u>l;u--)f=f.prev;for(;f!==null&&u>a;u--,f=f.prev)c.push(f.value);return c},r.prototype.splice=function(a,l,...c){a>this.length&&(a=this.length-1),a<0&&(a=this.length+a);for(var u=0,f=this.head;f!==null&&u<a;u++)f=f.next;for(var h=[],u=0;f&&u<l;u++)h.push(f.value),f=this.removeNode(f);f===null&&(f=this.tail),f!==this.head&&f!==this.tail&&(f=f.prev);for(var u=0;u<c.length;u++)f=i(this,f,c[u]);return h},r.prototype.reverse=function(){for(var a=this.head,l=this.tail,c=a;c!==null;c=c.prev){var u=c.prev;c.prev=c.next,c.next=u}return this.head=l,this.tail=a,this};function i(a,l,c){var u=l===a.head?new o(c,null,l,a):new o(c,l,l.next,a);return u.next===null&&(a.tail=u),u.prev===null&&(a.head=u),a.length++,u}function n(a,l){a.tail=new o(l,a.tail,null,a),a.head||(a.head=a.tail),a.length++}function s(a,l){a.head=new o(l,null,a.head,a),a.tail||(a.tail=a.head),a.length++}function o(a,l,c,u){if(!(this instanceof o))return new o(a,l,c,u);this.list=u,this.value=a,l?(l.next=this,this.prev=l):this.prev=null,c?(c.prev=this,this.next=c):this.next=null}try{cP()(r)}catch{}}),Hh=ee((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=Bh(),n=rS(),s=jh(),o=oS(),a=o.Sync,l=o.Tar,c=aS(),u=Buffer.alloc(1024),f=Symbol("onStat"),h=Symbol("ended"),p=Symbol("queue"),g=Symbol("current"),y=Symbol("process"),b=Symbol("processing"),x=Symbol("processJob"),k=Symbol("jobs"),C=Symbol("jobDone"),T=Symbol("addFSEntry"),O=Symbol("addTarEntry"),I=Symbol("stat"),w=Symbol("readdir"),v=Symbol("onreaddir"),F=Symbol("pipe"),q=Symbol("entry"),P=Symbol("entryOpt"),U=Symbol("writeEntryClass"),V=Symbol("write"),K=Symbol("ondrain"),N=te("fs"),A=te("path"),L=qh(),j=Jn(),z=L(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 c,this[k]=0,this.jobs=+d.jobs||4,this[b]=!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[O](d):this[T](d),this.flowing}[O](d){let m=j(A.resolve(this.cwd,d.path));if(!this.filter(d.path,d))d.resume();else{let _=new r(d.path,m,!1);_.entry=new l(d,this[P](_)),_.entry.on("end",R=>this[C](_)),this[k]+=1,this[p].push(_)}this[y]()}[T](d){let m=j(A.resolve(this.cwd,d));this[p].push(new r(d,m)),this[y]()}[I](d){d.pending=!0,this[k]+=1;let m=this.follow?"stat":"lstat";N[m](d.absolute,(_,R)=>{d.pending=!1,this[k]-=1,_?this.emit("error",_):this[f](d,R)})}[f](d,m){this.statCache.set(d.absolute,m),d.stat=m,this.filter(d.path,m)||(d.ignore=!0),this[y]()}[w](d){d.pending=!0,this[k]+=1,N.readdir(d.absolute,(m,_)=>{if(d.pending=!1,this[k]-=1,m)return this.emit("error",m);this[v](d,_)})}[v](d,m){this.readdirCache.set(d.absolute,m),d.readdir=m,this[y]()}[y](){if(!this[b]){this[b]=!0;for(let d=this[p].head;d!==null&&this[k]<this.jobs;d=d.next)if(this[x](d.value),d.value.ignore){let m=d.next;this[p].removeNode(d),d.next=m}this[b]=!1,this[h]&&!this[p].length&&this[k]===0&&(this.zip?this.zip.end(u):(super.write(u),super.end()))}}get[g](){return this[p]&&this[p].head&&this[p].head.value}[C](d){this[p].shift(),this[k]-=1,this[y]()}[x](d){if(!d.pending){if(d.entry){d===this[g]&&!d.piped&&this[F](d);return}if(d.stat||(this.statCache.has(d.absolute)?this[f](d,this.statCache.get(d.absolute)):this[I](d)),!!d.stat&&!d.ignore&&!(!this.noDirRecurse&&d.stat.isDirectory()&&!d.readdir&&(this.readdirCache.has(d.absolute)?this[v](d,this.readdirCache.get(d.absolute)):this[w](d),!d.readdir))){if(d.entry=this[q](d),!d.entry){d.ignore=!0;return}d===this[g]&&!d.piped&&this[F](d)}}}[P](d){return{onwarn:(m,_,R)=>this.warn(m,_,R),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}}[q](d){this[k]+=1;try{return new this[U](d.path,this[P](d)).on("end",()=>this[C](d)).on("error",m=>this.emit("error",m))}catch(m){this.emit("error",m)}}[K](){this[g]&&this[g].entry&&this[g].entry.resume()}[F](d){d.piped=!0,d.readdir&&d.readdir.forEach(R=>{let E=d.path,M=E==="./"?"":E.replace(/\/*$/,"/");this[T](M+R)});let m=d.entry,_=this.zip;_?m.on("data",R=>{_.write(R)||m.pause()}):m.on("data",R=>{super.write(R)||m.pause()})}pause(){return this.zip&&this.zip.pause(),super.pause()}}),D=class extends z{constructor(d){super(d),this[U]=a}pause(){}resume(){}[I](d){let m=this.follow?"statSync":"lstatSync";this[f](d,N[m](d.absolute))}[w](d,m){this[v](d,N.readdirSync(d.absolute))}[F](d){let m=d.entry,_=this.zip;d.readdir&&d.readdir.forEach(R=>{let E=d.path,M=E==="./"?"":E.replace(/\/*$/,"/");this[T](M+R)}),_?m.on("data",R=>{_.write(R)}):m.on("data",R=>{super[V](R)})}};z.Sync=D,e.exports=z}),ts=ee(t=>{"use strict";W();var e=eS(),r=te("events").EventEmitter,i=te("fs"),n=i.writev;if(!n){let d=process.binding("fs"),m=d.FSReqWrap||d.FSReqCallback;n=(_,R,E,M)=>{let B=(H,J)=>M(H,J,R),Z=new m;Z.oncomplete=B,d.writeBuffers(_,R,E,Z)}}var s=Symbol("_autoClose"),o=Symbol("_close"),a=Symbol("_ended"),l=Symbol("_fd"),c=Symbol("_finished"),u=Symbol("_flags"),f=Symbol("_flush"),h=Symbol("_handleChunk"),p=Symbol("_makeBuf"),g=Symbol("_mode"),y=Symbol("_needDrain"),b=Symbol("_onerror"),x=Symbol("_onopen"),k=Symbol("_onread"),C=Symbol("_onwrite"),T=Symbol("_open"),O=Symbol("_path"),I=Symbol("_pos"),w=Symbol("_queue"),v=Symbol("_read"),F=Symbol("_readSize"),q=Symbol("_reading"),P=Symbol("_remain"),U=Symbol("_size"),V=Symbol("_write"),K=Symbol("_writing"),N=Symbol("_defaultFlag"),A=Symbol("_errored"),L=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[A]=!1,this[l]=typeof m.fd=="number"?m.fd:null,this[O]=d,this[F]=m.readSize||16*1024*1024,this[q]=!1,this[U]=typeof m.size=="number"?m.size:1/0,this[P]=this[U],this[s]=typeof m.autoClose=="boolean"?m.autoClose:!0,typeof this[l]=="number"?this[v]():this[T]()}get fd(){return this[l]}get path(){return this[O]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[T](){i.open(this[O],"r",(d,m)=>this[x](d,m))}[x](d,m){d?this[b](d):(this[l]=m,this.emit("open",m),this[v]())}[p](){return Buffer.allocUnsafe(Math.min(this[F],this[P]))}[v](){if(!this[q]){this[q]=!0;let d=this[p]();if(d.length===0)return process.nextTick(()=>this[k](null,0,d));i.read(this[l],d,0,d.length,null,(m,_,R)=>this[k](m,_,R))}}[k](d,m,_){this[q]=!1,d?this[b](d):this[h](m,_)&&this[v]()}[o](){if(this[s]&&typeof this[l]=="number"){let d=this[l];this[l]=null,i.close(d,m=>m?this.emit("error",m):this.emit("close"))}}[b](d){this[q]=!0,this[o](),this.emit("error",d)}[h](d,m){let _=!1;return this[P]-=d,d>0&&(_=super.write(d<m.length?m.slice(0,d):m)),(d===0||this[P]<=0)&&(_=!1,this[o](),super.end()),_}emit(d,m){switch(d){case"prefinish":case"finish":break;case"drain":typeof this[l]=="number"&&this[v]();break;case"error":return this[A]?void 0:(this[A]=!0,super.emit(d,m));default:return super.emit(d,m)}}},j=class extends L{[T](){let d=!0;try{this[x](null,i.openSync(this[O],"r")),d=!1}finally{d&&this[o]()}}[v](){let d=!0;try{if(!this[q]){this[q]=!0;do{let m=this[p](),_=m.length===0?0:i.readSync(this[l],m,0,m.length,null);if(!this[h](_,m))break}while(!0);this[q]=!1}d=!1}finally{d&&this[o]()}}[o](){if(this[s]&&typeof this[l]=="number"){let d=this[l];this[l]=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[A]=!1,this[K]=!1,this[a]=!1,this[y]=!1,this[w]=[],this[O]=d,this[l]=typeof m.fd=="number"?m.fd:null,this[g]=m.mode===void 0?438:m.mode,this[I]=typeof m.start=="number"?m.start:null,this[s]=typeof m.autoClose=="boolean"?m.autoClose:!0;let _=this[I]!==null?"r+":"w";this[N]=m.flags===void 0,this[u]=this[N]?_:m.flags,this[l]===null&&this[T]()}emit(d,m){if(d==="error"){if(this[A])return;this[A]=!0}return super.emit(d,m)}get fd(){return this[l]}get path(){return this[O]}[b](d){this[o](),this[K]=!0,this.emit("error",d)}[T](){i.open(this[O],this[u],this[g],(d,m)=>this[x](d,m))}[x](d,m){this[N]&&this[u]==="r+"&&d&&d.code==="ENOENT"?(this[u]="w",this[T]()):d?this[b](d):(this[l]=m,this.emit("open",m),this[f]())}end(d,m){return d&&this.write(d,m),this[a]=!0,!this[K]&&!this[w].length&&typeof this[l]=="number"&&this[C](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[l]===null||this[K]||this[w].length?(this[w].push(d),this[y]=!0,!1):(this[K]=!0,this[V](d),!0)}[V](d){i.write(this[l],d,0,d.length,this[I],(m,_)=>this[C](m,_))}[C](d,m){d?this[b](d):(this[I]!==null&&(this[I]+=m),this[w].length?this[f]():(this[K]=!1,this[a]&&!this[c]?(this[c]=!0,this[o](),this.emit("finish")):this[y]&&(this[y]=!1,this.emit("drain"))))}[f](){if(this[w].length===0)this[a]&&this[C](null,0);else if(this[w].length===1)this[V](this[w].pop());else{let d=this[w];this[w]=[],n(this[l],d,this[I],(m,_)=>this[C](m,_))}}[o](){if(this[s]&&typeof this[l]=="number"){let d=this[l];this[l]=null,i.close(d,m=>m?this.emit("error",m):this.emit("close"))}}},D=class extends z{[T](){let d;if(this[N]&&this[u]==="r+")try{d=i.openSync(this[O],this[u],this[g])}catch(m){if(m.code==="ENOENT")return this[u]="w",this[T]();throw m}else d=i.openSync(this[O],this[u],this[g]);this[x](null,d)}[o](){if(this[s]&&typeof this[l]=="number"){let d=this[l];this[l]=null,i.closeSync(d),this.emit("close")}}[V](d){let m=!0;try{this[C](null,i.writeSync(this[l],d,0,d.length,this[I])),m=!1}finally{if(m)try{this[o]()}catch{}}}};t.ReadStream=L,t.ReadStreamSync=j,t.WriteStream=z,t.WriteStreamSync=D}),Uh=ee((t,e)=>{"use strict";W();var r=qh(),i=Qn(),n=te("events"),s=aS(),o=1024*1024,a=jh(),l=$h(),c=rS(),{nextTick:u}=te("process"),f=Buffer.from([31,139]),h=Symbol("state"),p=Symbol("writeEntry"),g=Symbol("readEntry"),y=Symbol("nextEntry"),b=Symbol("processEntry"),x=Symbol("extendedHeader"),k=Symbol("globalExtendedHeader"),C=Symbol("meta"),T=Symbol("emitMeta"),O=Symbol("buffer"),I=Symbol("queue"),w=Symbol("ended"),v=Symbol("emittedEnd"),F=Symbol("emit"),q=Symbol("unzip"),P=Symbol("consumeChunk"),U=Symbol("consumeChunkSub"),V=Symbol("consumeBody"),K=Symbol("consumeMeta"),N=Symbol("consumeHeader"),A=Symbol("consuming"),L=Symbol("bufferConcat"),j=Symbol("maybeEnd"),z=Symbol("writing"),D=Symbol("aborted"),d=Symbol("onDone"),m=Symbol("sawValidEntry"),_=Symbol("sawNullBlock"),R=Symbol("sawEOF"),E=Symbol("closeStream"),M=B=>!0;e.exports=r(class extends n{constructor(B){B=B||{},super(B),this.file=B.file||"",this[m]=null,this.on(d,Z=>{(this[h]==="begin"||this[m]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),B.ondone?this.on(d,B.ondone):this.on(d,Z=>{this.emit("prefinish"),this.emit("finish"),this.emit("end")}),this.strict=!!B.strict,this.maxMetaEntrySize=B.maxMetaEntrySize||o,this.filter=typeof B.filter=="function"?B.filter:M,this.writable=!0,this.readable=!1,this[I]=new s,this[O]=null,this[g]=null,this[p]=null,this[h]="begin",this[C]="",this[x]=null,this[k]=null,this[w]=!1,this[q]=null,this[D]=!1,this[_]=!1,this[R]=!1,this.on("end",()=>this[E]()),typeof B.onwarn=="function"&&this.on("warn",B.onwarn),typeof B.onentry=="function"&&this.on("entry",B.onentry)}[N](B,Z){this[m]===null&&(this[m]=!1);let H;try{H=new i(B,Z,this[x],this[k])}catch(J){return this.warn("TAR_ENTRY_INVALID",J)}if(H.nullBlock)this[_]?(this[R]=!0,this[h]==="begin"&&(this[h]="header"),this[F]("eof")):(this[_]=!0,this[F]("nullBlock"));else if(this[_]=!1,!H.cksumValid)this.warn("TAR_ENTRY_INVALID","checksum failure",{header:H});else if(!H.path)this.warn("TAR_ENTRY_INVALID","path is required",{header:H});else{let J=H.type;if(/^(Symbolic)?Link$/.test(J)&&!H.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath required",{header:H});else if(!/^(Symbolic)?Link$/.test(J)&&H.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath forbidden",{header:H});else{let G=this[p]=new a(H,this[x],this[k]);if(!this[m])if(G.remain){let re=()=>{G.invalid||(this[m]=!0)};G.on("end",re)}else this[m]=!0;G.meta?G.size>this.maxMetaEntrySize?(G.ignore=!0,this[F]("ignoredEntry",G),this[h]="ignore",G.resume()):G.size>0&&(this[C]="",G.on("data",re=>this[C]+=re),this[h]="meta"):(this[x]=null,G.ignore=G.ignore||!this.filter(G.path,G),G.ignore?(this[F]("ignoredEntry",G),this[h]=G.remain?"ignore":"header",G.resume()):(G.remain?this[h]="body":(this[h]="header",G.end()),this[g]?this[I].push(G):(this[I].push(G),this[y]())))}}}[E](){u(()=>this.emit("close"))}[b](B){let Z=!0;return B?Array.isArray(B)?this.emit.apply(this,B):(this[g]=B,this.emit("entry",B),B.emittedEnd||(B.on("end",H=>this[y]()),Z=!1)):(this[g]=null,Z=!1),Z}[y](){do;while(this[b](this[I].shift()));if(!this[I].length){let B=this[g];!B||B.flowing||B.size===B.remain?this[z]||this.emit("drain"):B.once("drain",Z=>this.emit("drain"))}}[V](B,Z){let H=this[p],J=H.blockRemain,G=J>=B.length&&Z===0?B:B.slice(Z,Z+J);return H.write(G),H.blockRemain||(this[h]="header",this[p]=null,H.end()),G.length}[K](B,Z){let H=this[p],J=this[V](B,Z);return this[p]||this[T](H),J}[F](B,Z,H){!this[I].length&&!this[g]?this.emit(B,Z,H):this[I].push([B,Z,H])}[T](B){switch(this[F]("meta",this[C]),B.type){case"ExtendedHeader":case"OldExtendedHeader":this[x]=l.parse(this[C],this[x],!1);break;case"GlobalExtendedHeader":this[k]=l.parse(this[C],this[k],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[x]=this[x]||Object.create(null),this[x].path=this[C].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[x]=this[x]||Object.create(null),this[x].linkpath=this[C].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+B.type)}}abort(B){this[D]=!0,this.emit("abort",B),this.warn("TAR_ABORT",B,{recoverable:!1})}write(B){if(this[D])return;if(this[q]===null&&B){if(this[O]&&(B=Buffer.concat([this[O],B]),this[O]=null),B.length<f.length)return this[O]=B,!0;for(let H=0;this[q]===null&&H<f.length;H++)B[H]!==f[H]&&(this[q]=!1);if(this[q]===null){let H=this[w];this[w]=!1,this[q]=new c.Unzip,this[q].on("data",G=>this[P](G)),this[q].on("error",G=>this.abort(G)),this[q].on("end",G=>{this[w]=!0,this[P]()}),this[z]=!0;let J=this[q][H?"end":"write"](B);return this[z]=!1,J}}this[z]=!0,this[q]?this[q].write(B):this[P](B),this[z]=!1;let Z=this[I].length?!1:this[g]?this[g].flowing:!0;return!Z&&!this[I].length&&this[g].once("drain",H=>this.emit("drain")),Z}[L](B){B&&!this[D]&&(this[O]=this[O]?Buffer.concat([this[O],B]):B)}[j](){if(this[w]&&!this[v]&&!this[D]&&!this[A]){this[v]=!0;let B=this[p];if(B&&B.blockRemain){let Z=this[O]?this[O].length:0;this.warn("TAR_BAD_ARCHIVE",`Truncated input (needed ${B.blockRemain} more bytes, only ${Z} available)`,{entry:B}),this[O]&&B.write(this[O]),B.end()}this[F](d)}}[P](B){if(this[A])this[L](B);else if(!B&&!this[O])this[j]();else{if(this[A]=!0,this[O]){this[L](B);let Z=this[O];this[O]=null,this[U](Z)}else this[U](B);for(;this[O]&&this[O].length>=512&&!this[D]&&!this[R];){let Z=this[O];this[O]=null,this[U](Z)}this[A]=!1}(!this[O]||this[w])&&this[j]()}[U](B){let Z=0,H=B.length;for(;Z+512<=H&&!this[D]&&!this[R];)switch(this[h]){case"begin":case"header":this[N](B,Z),Z+=512;break;case"ignore":case"body":Z+=this[V](B,Z);break;case"meta":Z+=this[K](B,Z);break;default:throw new Error("invalid state: "+this[h])}Z<H&&(this[O]?this[O]=Buffer.concat([B.slice(Z),this[O]]):this[O]=B.slice(Z))}end(B){this[D]||(this[q]?this[q].end(B):(this[w]=!0,this.write(B)))}})}),Gh=ee((t,e)=>{"use strict";W();var r=Xn(),i=Uh(),n=te("fs"),s=ts(),o=te("path"),a=es();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 b=r(p);if(b.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!b.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return g.length&&c(b,g),b.noResume||l(b),b.file&&b.sync?u(b):b.file?f(b,y):h(b)};var l=p=>{let g=p.onentry;p.onentry=g?y=>{g(y),y.resume()}:y=>y.resume()},c=(p,g)=>{let y=new Map(g.map(k=>[a(k),!0])),b=p.filter,x=(k,C)=>{let T=C||o.parse(k).root||".",O=k===T?!1:y.has(k)?y.get(k):x(o.dirname(k),T);return y.set(k,O),O};p.filter=b?(k,C)=>b(k,C)&&x(a(k)):k=>x(a(k))},u=p=>{let g=h(p),y=p.file,b=!0,x;try{let k=n.statSync(y),C=p.maxReadSize||16*1024*1024;if(k.size<C)g.end(n.readFileSync(y));else{let T=0,O=Buffer.allocUnsafe(C);for(x=n.openSync(y,"r");T<k.size;){let I=n.readSync(x,O,0,C,T);T+=I,g.write(O.slice(0,I))}g.end()}b=!1}finally{if(b&&x)try{n.closeSync(x)}catch{}}},f=(p,g)=>{let y=new i(p),b=p.maxReadSize||16*1024*1024,x=p.file,k=new Promise((C,T)=>{y.on("error",T),y.on("end",C),n.stat(x,(O,I)=>{if(O)T(O);else{let w=new s.ReadStream(x,{readSize:b,size:I.size});w.on("error",T),w.pipe(y)}})});return g?k.then(g,g):k},h=p=>new i(p)}),uP=ee((t,e)=>{"use strict";W();var r=Xn(),i=Hh(),n=ts(),s=Gh(),o=te("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 b=r(p);if(b.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!b.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return b.file&&b.sync?a(b,g):b.file?l(b,g,y):b.sync?f(b,g):h(b,g)};var a=(p,g)=>{let y=new i.Sync(p),b=new n.WriteStreamSync(p.file,{mode:p.mode||438});y.pipe(b),c(y,g)},l=(p,g,y)=>{let b=new i(p),x=new n.WriteStream(p.file,{mode:p.mode||438});b.pipe(x);let k=new Promise((C,T)=>{x.on("error",T),x.on("close",C),b.on("error",T)});return u(b,g),y?k.then(y,y):k},c=(p,g)=>{g.forEach(y=>{y.charAt(0)==="@"?s({file:o.resolve(p.cwd,y.slice(1)),sync:!0,noResume:!0,onentry:b=>p.add(b)}):p.add(y)}),p.end()},u=(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:b=>p.add(b)}).then(b=>u(p,g));p.add(y)}p.end()},f=(p,g)=>{let y=new i.Sync(p);return c(y,g),y},h=(p,g)=>{let y=new i(p);return u(y,g),y}}),lS=ee((t,e)=>{"use strict";W();var r=Xn(),i=Hh(),n=te("fs"),s=ts(),o=Gh(),a=te("path"),l=Qn();e.exports=(g,y,b)=>{let x=r(g);if(!x.file)throw new TypeError("file is required");if(x.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),x.sync?c(x,y):f(x,y,b)};var c=(g,y)=>{let b=new i.Sync(g),x=!0,k,C;try{try{k=n.openSync(g.file,"r+")}catch(I){if(I.code==="ENOENT")k=n.openSync(g.file,"w+");else throw I}let T=n.fstatSync(k),O=Buffer.alloc(512);e:for(C=0;C<T.size;C+=512){for(let v=0,F=0;v<512;v+=F){if(F=n.readSync(k,O,v,O.length-v,C+v),C===0&&O[0]===31&&O[1]===139)throw new Error("cannot append to compressed archives");if(!F)break e}let I=new l(O);if(!I.cksumValid)break;let w=512*Math.ceil(I.size/512);if(C+w+512>T.size)break;C+=w,g.mtimeCache&&g.mtimeCache.set(I.path,I.mtime)}x=!1,u(g,b,C,k,y)}finally{if(x)try{n.closeSync(k)}catch{}}},u=(g,y,b,x,k)=>{let C=new s.WriteStreamSync(g.file,{fd:x,start:b});y.pipe(C),h(y,k)},f=(g,y,b)=>{y=Array.from(y);let x=new i(g),k=(T,O,I)=>{let w=(U,V)=>{U?n.close(T,K=>I(U)):I(null,V)},v=0;if(O===0)return w(null,0);let F=0,q=Buffer.alloc(512),P=(U,V)=>{if(U)return w(U);if(F+=V,F<512&&V)return n.read(T,q,F,q.length-F,v+F,P);if(v===0&&q[0]===31&&q[1]===139)return w(new Error("cannot append to compressed archives"));if(F<512)return w(null,v);let K=new l(q);if(!K.cksumValid)return w(null,v);let N=512*Math.ceil(K.size/512);if(v+N+512>O||(v+=N+512,v>=O))return w(null,v);g.mtimeCache&&g.mtimeCache.set(K.path,K.mtime),F=0,n.read(T,q,0,512,v,P)};n.read(T,q,0,512,v,P)},C=new Promise((T,O)=>{x.on("error",O);let I="r+",w=(v,F)=>{if(v&&v.code==="ENOENT"&&I==="r+")return I="w+",n.open(g.file,I,w);if(v)return O(v);n.fstat(F,(q,P)=>{if(q)return n.close(F,()=>O(q));k(F,P.size,(U,V)=>{if(U)return O(U);let K=new s.WriteStream(g.file,{fd:F,start:V});x.pipe(K),K.on("error",O),K.on("close",T),p(x,y)})})};n.open(g.file,I,w)});return b?C.then(b,b):C},h=(g,y)=>{y.forEach(b=>{b.charAt(0)==="@"?o({file:a.resolve(g.cwd,b.slice(1)),sync:!0,noResume:!0,onentry:x=>g.add(x)}):g.add(b)}),g.end()},p=(g,y)=>{for(;y.length;){let b=y.shift();if(b.charAt(0)==="@")return o({file:a.resolve(g.cwd,b.slice(1)),noResume:!0,onentry:x=>g.add(x)}).then(x=>p(g,y));g.add(b)}g.end()}}),hP=ee((t,e)=>{"use strict";W();var r=Xn(),i=lS();e.exports=(s,o,a)=>{let l=r(s);if(!l.file)throw new TypeError("file is required");if(l.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(l),i(l,o,a)};var n=s=>{let o=s.filter;s.mtimeCache||(s.mtimeCache=new Map),s.filter=o?(a,l)=>o(a,l)&&!(s.mtimeCache.get(a)>l.mtime):(a,l)=>!(s.mtimeCache.get(a)>l.mtime)}}),fP=ee((t,e)=>{W();var{promisify:r}=te("util"),i=te("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}),pP=ee((t,e)=>{W();var r=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:i,parse:n}=te("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:l}=n(o);if(a.test(o.substr(l.length)))throw Object.assign(new Error("Illegal characters in path."),{path:o,code:"EINVAL"})}return o};e.exports=s}),dP=ee((t,e)=>{W();var{dirname:r}=te("path"),i=(s,o,a=void 0)=>a===o?Promise.resolve():s.statAsync(o).then(l=>l.isDirectory()?a:void 0,l=>l.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(l){return l.code==="ENOENT"?n(s,r(o),o):void 0}};e.exports={findMade:i,findMadeSync:n}}),cS=ee((t,e)=>{W();var{dirname:r}=te("path"),i=(s,o,a)=>{o.recursive=!1;let l=r(s);return l===s?o.mkdirAsync(s,o).catch(c=>{if(c.code!=="EISDIR")throw c}):o.mkdirAsync(s,o).then(()=>a||s,c=>{if(c.code==="ENOENT")return i(l,o).then(u=>i(s,o,u));if(c.code!=="EEXIST"&&c.code!=="EROFS")throw c;return o.statAsync(s).then(u=>{if(u.isDirectory())return a;throw c},()=>{throw c})})},n=(s,o,a)=>{let l=r(s);if(o.recursive=!1,l===s)try{return o.mkdirSync(s,o)}catch(c){if(c.code!=="EISDIR")throw c;return}try{return o.mkdirSync(s,o),a||s}catch(c){if(c.code==="ENOENT")return n(s,o,n(l,o,a));if(c.code!=="EEXIST"&&c.code!=="EROFS")throw c;try{if(!o.statSync(s).isDirectory())throw c}catch{throw c}}};e.exports={mkdirpManual:i,mkdirpManualSync:n}}),mP=ee((t,e)=>{W();var{dirname:r}=te("path"),{findMade:i,findMadeSync:n}=dP(),{mkdirpManual:s,mkdirpManualSync:o}=cS(),a=(c,u)=>(u.recursive=!0,r(c)===c?u.mkdirAsync(c,u):i(u,c).then(f=>u.mkdirAsync(c,u).then(()=>f).catch(h=>{if(h.code==="ENOENT")return s(c,u);throw h}))),l=(c,u)=>{if(u.recursive=!0,r(c)===c)return u.mkdirSync(c,u);let f=n(u,c);try{return u.mkdirSync(c,u),f}catch(h){if(h.code==="ENOENT")return o(c,u);throw h}};e.exports={mkdirpNative:a,mkdirpNativeSync:l}}),gP=ee((t,e)=>{W();var r=te("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?l=>l.mkdir===r.mkdir:()=>!1,a=s?l=>l.mkdirSync===r.mkdirSync:()=>!1;e.exports={useNative:o,useNativeSync:a}}),yP=ee((t,e)=>{W();var r=fP(),i=pP(),{mkdirpNative:n,mkdirpNativeSync:s}=mP(),{mkdirpManual:o,mkdirpManualSync:a}=cS(),{useNative:l,useNativeSync:c}=gP(),u=(h,p)=>(h=i(h),p=r(p),l(p)?n(h,p):o(h,p)),f=(h,p)=>(h=i(h),p=r(p),c(p)?s(h,p):a(h,p));u.sync=f,u.native=(h,p)=>n(i(h),r(p)),u.manual=(h,p)=>o(i(h),r(p)),u.nativeSync=(h,p)=>s(i(h),r(p)),u.manualSync=(h,p)=>a(i(h),r(p)),e.exports=u}),bP=ee((t,e)=>{"use strict";W();var r=te("fs"),i=te("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=(C,T,O)=>{try{return r[s](C,T,O)}catch(I){if(I.code!=="ENOENT")throw I}},l=(C,T,O)=>{try{return r.chownSync(C,T,O)}catch(I){if(I.code!=="ENOENT")throw I}},c=o?(C,T,O,I)=>w=>{!w||w.code!=="EISDIR"?I(w):r.chown(C,T,O,I)}:(C,T,O,I)=>I,u=o?(C,T,O)=>{try{return a(C,T,O)}catch(I){if(I.code!=="EISDIR")throw I;l(C,T,O)}}:(C,T,O)=>a(C,T,O),f=process.version,h=(C,T,O)=>r.readdir(C,T,O),p=(C,T)=>r.readdirSync(C,T);/^v4\./.test(f)&&(h=(C,T,O)=>r.readdir(C,O));var g=(C,T,O,I)=>{r[n](C,T,O,c(C,T,O,w=>{I(w&&w.code!=="ENOENT"?w:null)}))},y=(C,T,O,I,w)=>{if(typeof T=="string")return r.lstat(i.resolve(C,T),(v,F)=>{if(v)return w(v.code!=="ENOENT"?v:null);F.name=T,y(C,F,O,I,w)});if(T.isDirectory())b(i.resolve(C,T.name),O,I,v=>{if(v)return w(v);let F=i.resolve(C,T.name);g(F,O,I,w)});else{let v=i.resolve(C,T.name);g(v,O,I,w)}},b=(C,T,O,I)=>{h(C,{withFileTypes:!0},(w,v)=>{if(w){if(w.code==="ENOENT")return I();if(w.code!=="ENOTDIR"&&w.code!=="ENOTSUP")return I(w)}if(w||!v.length)return g(C,T,O,I);let F=v.length,q=null,P=U=>{if(!q){if(U)return I(q=U);if(--F===0)return g(C,T,O,I)}};v.forEach(U=>y(C,U,T,O,P))})},x=(C,T,O,I)=>{if(typeof T=="string")try{let w=r.lstatSync(i.resolve(C,T));w.name=T,T=w}catch(w){if(w.code==="ENOENT")return;throw w}T.isDirectory()&&k(i.resolve(C,T.name),O,I),u(i.resolve(C,T.name),O,I)},k=(C,T,O)=>{let I;try{I=p(C,{withFileTypes:!0})}catch(w){if(w.code==="ENOENT")return;if(w.code==="ENOTDIR"||w.code==="ENOTSUP")return u(C,T,O);throw w}return I&&I.length&&I.forEach(w=>x(C,w,T,O)),u(C,T,O)};e.exports=b,b.sync=k}),_P=ee((t,e)=>{"use strict";W();var r=yP(),i=te("fs"),n=te("path"),s=bP(),o=Jn(),a=class extends Error{constructor(y,b){super("Cannot extract through symbolic link"),this.path=b,this.symlink=y}get name(){return"SylinkError"}},l=class extends Error{constructor(y,b){super(b+": Cannot cd into '"+y+"'"),this.path=y,this.code=b}get name(){return"CwdError"}},c=(y,b)=>y.get(o(b)),u=(y,b,x)=>y.set(o(b),x),f=(y,b)=>{i.stat(y,(x,k)=>{(x||!k.isDirectory())&&(x=new l(y,x&&x.code||"ENOTDIR")),b(x)})};e.exports=(y,b,x)=>{y=o(y);let k=b.umask,C=b.mode|448,T=(C&k)!==0,O=b.uid,I=b.gid,w=typeof O=="number"&&typeof I=="number"&&(O!==b.processUid||I!==b.processGid),v=b.preserve,F=b.unlink,q=b.cache,P=o(b.cwd),U=(K,N)=>{K?x(K):(u(q,y,!0),N&&w?s(N,O,I,A=>U(A)):T?i.chmod(y,C,x):x())};if(q&&c(q,y)===!0)return U();if(y===P)return f(y,U);if(v)return r(y,{mode:C}).then(K=>U(null,K),U);let V=o(n.relative(P,y)).split("/");h(P,V,C,q,F,P,null,U)};var h=(y,b,x,k,C,T,O,I)=>{if(!b.length)return I(null,O);let w=b.shift(),v=o(n.resolve(y+"/"+w));if(c(k,v))return h(v,b,x,k,C,T,O,I);i.mkdir(v,x,p(v,b,x,k,C,T,O,I))},p=(y,b,x,k,C,T,O,I)=>w=>{w?i.lstat(y,(v,F)=>{if(v)v.path=v.path&&o(v.path),I(v);else if(F.isDirectory())h(y,b,x,k,C,T,O,I);else if(C)i.unlink(y,q=>{if(q)return I(q);i.mkdir(y,x,p(y,b,x,k,C,T,O,I))});else{if(F.isSymbolicLink())return I(new a(y,y+"/"+b.join("/")));I(w)}}):(O=O||y,h(y,b,x,k,C,T,O,I))},g=y=>{let b=!1,x="ENOTDIR";try{b=i.statSync(y).isDirectory()}catch(k){x=k.code}finally{if(!b)throw new l(y,x)}};e.exports.sync=(y,b)=>{y=o(y);let x=b.umask,k=b.mode|448,C=(k&x)!==0,T=b.uid,O=b.gid,I=typeof T=="number"&&typeof O=="number"&&(T!==b.processUid||O!==b.processGid),w=b.preserve,v=b.unlink,F=b.cache,q=o(b.cwd),P=K=>{u(F,y,!0),K&&I&&s.sync(K,T,O),C&&i.chmodSync(y,k)};if(F&&c(F,y)===!0)return P();if(y===q)return g(q),P();if(w)return P(r.sync(y,k));let U=o(n.relative(q,y)).split("/"),V=null;for(let K=U.shift(),N=q;K&&(N+="/"+K);K=U.shift())if(N=o(n.resolve(N)),!c(F,N))try{i.mkdirSync(N,k),V=V||N,u(F,N,!0)}catch{let A=i.lstatSync(N);if(A.isDirectory()){u(F,N,!0);continue}else if(v){i.unlinkSync(N),i.mkdirSync(N,k),V=V||N,u(F,N,!0);continue}else if(A.isSymbolicLink())return new a(N,N+"/"+U.join("/"))}return P(V)}}),uS=ee((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])}),wP=ee((t,e)=>{W();var r=te("assert"),i=uS(),n=es(),{join:s}=te("path"),o=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,a=o==="win32";e.exports=()=>{let l=new Map,c=new Map,u=b=>b.split("/").slice(0,-1).reduce((x,k)=>(x.length&&(k=s(x[x.length-1],k)),x.push(k||"/"),x),[]),f=new Set,h=b=>{let x=c.get(b);if(!x)throw new Error("function does not have any path reservations");return{paths:x.paths.map(k=>l.get(k)),dirs:[...x.dirs].map(k=>l.get(k))}},p=b=>{let{paths:x,dirs:k}=h(b);return x.every(C=>C[0]===b)&&k.every(C=>C[0]instanceof Set&&C[0].has(b))},g=b=>f.has(b)||!p(b)?!1:(f.add(b),b(()=>y(b)),!0),y=b=>{if(!f.has(b))return!1;let{paths:x,dirs:k}=c.get(b),C=new Set;return x.forEach(T=>{let O=l.get(T);r.equal(O[0],b),O.length===1?l.delete(T):(O.shift(),typeof O[0]=="function"?C.add(O[0]):O[0].forEach(I=>C.add(I)))}),k.forEach(T=>{let O=l.get(T);r(O[0]instanceof Set),O[0].size===1&&O.length===1?l.delete(T):O[0].size===1?(O.shift(),C.add(O[0])):O[0].delete(b)}),f.delete(b),C.forEach(T=>g(T)),!0};return{check:p,reserve:(b,x)=>{b=a?["win32 parallelization disabled"]:b.map(C=>i(n(s(C))).toLowerCase());let k=new Set(b.map(C=>u(C)).reduce((C,T)=>C.concat(T)));return c.set(x,{dirs:k,paths:b}),b.forEach(C=>{let T=l.get(C);T?T.push(x):l.set(C,[x])}),k.forEach(C=>{let T=l.get(C);T?T[T.length-1]instanceof Set?T[T.length-1].add(x):T.push(new Set([x])):l.set(C,[new Set([x])])}),g(x)}}}}),SP=ee((t,e)=>{W();var r=process.env.__FAKE_PLATFORM__||process.platform,i=r==="win32",n=global.__FAKE_TESTING_FS__||te("fs"),{O_CREAT:s,O_TRUNC:o,O_WRONLY:a,UV_FS_O_FILEMAP:l=0}=n.constants,c=i&&!!l,u=512*1024,f=l|o|s|a;e.exports=c?h=>h<u?f:"w":()=>"w"}),hS=ee((t,e)=>{"use strict";W();var r=te("assert"),i=Uh(),n=te("fs"),s=ts(),o=te("path"),a=_P(),l=nS(),c=wP(),u=sS(),f=Jn(),h=es(),p=uS(),g=Symbol("onEntry"),y=Symbol("checkFs"),b=Symbol("checkFs2"),x=Symbol("pruneCache"),k=Symbol("isReusable"),C=Symbol("makeFs"),T=Symbol("file"),O=Symbol("directory"),I=Symbol("link"),w=Symbol("symlink"),v=Symbol("hardlink"),F=Symbol("unsupported"),q=Symbol("checkPath"),P=Symbol("mkdir"),U=Symbol("onError"),V=Symbol("pending"),K=Symbol("pend"),N=Symbol("unpend"),A=Symbol("ended"),L=Symbol("maybeClose"),j=Symbol("skip"),z=Symbol("doChown"),D=Symbol("uid"),d=Symbol("gid"),m=Symbol("checkedCwd"),_=te("crypto"),R=SP(),E=process.env.TESTING_TAR_FAKE_PLATFORM||process.platform,M=E==="win32",B=(S,Y)=>{if(!M)return n.unlink(S,Y);let X=S+".DELETE."+_.randomBytes(16).toString("hex");n.rename(S,X,oe=>{if(oe)return Y(oe);n.unlink(X,Y)})},Z=S=>{if(!M)return n.unlinkSync(S);let Y=S+".DELETE."+_.randomBytes(16).toString("hex");n.renameSync(S,Y),n.unlinkSync(Y)},H=(S,Y,X)=>S===S>>>0?S:Y===Y>>>0?Y:X,J=S=>p(h(f(S))).toLowerCase(),G=(S,Y)=>{Y=J(Y);for(let X of S.keys()){let oe=J(X);(oe===Y||oe.indexOf(Y+"/")===0)&&S.delete(X)}},re=S=>{for(let Y of S.keys())S.delete(Y)},ue=class extends i{constructor(S){if(S||(S={}),S.ondone=Y=>{this[A]=!0,this[L]()},super(S),this[m]=!1,this.reservations=c(),this.transform=typeof S.transform=="function"?S.transform:null,this.writable=!0,this.readable=!1,this[V]=0,this[A]=!1,this.dirCache=S.dirCache||new Map,typeof S.uid=="number"||typeof S.gid=="number"){if(typeof S.uid!="number"||typeof S.gid!="number")throw new TypeError("cannot set owner without number uid and gid");if(S.preserveOwner)throw new TypeError("cannot preserve owner in archive and also set owner explicitly");this.uid=S.uid,this.gid=S.gid,this.setOwner=!0}else this.uid=null,this.gid=null,this.setOwner=!1;S.preserveOwner===void 0&&typeof S.uid!="number"?this.preserveOwner=process.getuid&&process.getuid()===0:this.preserveOwner=!!S.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=S.forceChown===!0,this.win32=!!S.win32||M,this.newer=!!S.newer,this.keep=!!S.keep,this.noMtime=!!S.noMtime,this.preservePaths=!!S.preservePaths,this.unlink=!!S.unlink,this.cwd=f(o.resolve(S.cwd||process.cwd())),this.strip=+S.strip||0,this.processUmask=S.noChmod?0:process.umask(),this.umask=typeof S.umask=="number"?S.umask:this.processUmask,this.dmode=S.dmode||511&~this.umask,this.fmode=S.fmode||438&~this.umask,this.on("entry",Y=>this[g](Y))}warn(S,Y,X={}){return(S==="TAR_BAD_ARCHIVE"||S==="TAR_ABORT")&&(X.recoverable=!1),super.warn(S,Y,X)}[L](){this[A]&&this[V]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"))}[q](S){if(this.strip){let Y=f(S.path).split("/");if(Y.length<this.strip)return!1;if(S.path=Y.slice(this.strip).join("/"),S.type==="Link"){let X=f(S.linkpath).split("/");if(X.length>=this.strip)S.linkpath=X.slice(this.strip).join("/");else return!1}}if(!this.preservePaths){let Y=f(S.path),X=Y.split("/");if(X.includes("..")||M&&/^[a-z]:\.\.$/i.test(X[0]))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:S,path:Y}),!1;let[oe,ce]=u(Y);oe&&(S.path=ce,this.warn("TAR_ENTRY_INFO",`stripping ${oe} from absolute path`,{entry:S,path:Y}))}if(o.isAbsolute(S.path)?S.absolute=f(o.resolve(S.path)):S.absolute=f(o.resolve(this.cwd,S.path)),!this.preservePaths&&S.absolute.indexOf(this.cwd+"/")!==0&&S.absolute!==this.cwd)return this.warn("TAR_ENTRY_ERROR","path escaped extraction target",{entry:S,path:f(S.path),resolvedPath:S.absolute,cwd:this.cwd}),!1;if(S.absolute===this.cwd&&S.type!=="Directory"&&S.type!=="GNUDumpDir")return!1;if(this.win32){let{root:Y}=o.win32.parse(S.absolute);S.absolute=Y+l.encode(S.absolute.slice(Y.length));let{root:X}=o.win32.parse(S.path);S.path=X+l.encode(S.path.slice(X.length))}return!0}[g](S){if(!this[q](S))return S.resume();switch(r.equal(typeof S.absolute,"string"),S.type){case"Directory":case"GNUDumpDir":S.mode&&(S.mode=S.mode|448);case"File":case"OldFile":case"ContiguousFile":case"Link":case"SymbolicLink":return this[y](S);case"CharacterDevice":case"BlockDevice":case"FIFO":default:return this[F](S)}}[U](S,Y){S.name==="CwdError"?this.emit("error",S):(this.warn("TAR_ENTRY_ERROR",S,{entry:Y}),this[N](),Y.resume())}[P](S,Y,X){a(f(S),{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](S){return this.forceChown||this.preserveOwner&&(typeof S.uid=="number"&&S.uid!==this.processUid||typeof S.gid=="number"&&S.gid!==this.processGid)||typeof this.uid=="number"&&this.uid!==this.processUid||typeof this.gid=="number"&&this.gid!==this.processGid}[D](S){return H(this.uid,S.uid,this.processUid)}[d](S){return H(this.gid,S.gid,this.processGid)}[T](S,Y){let X=S.mode&4095||this.fmode,oe=new s.WriteStream(S.absolute,{flags:R(S.size),mode:X,autoClose:!1});oe.on("error",pe=>{oe.fd&&n.close(oe.fd,()=>{}),oe.write=()=>!0,this[U](pe,S),Y()});let ce=1,be=pe=>{if(pe){oe.fd&&n.close(oe.fd,()=>{}),this[U](pe,S),Y();return}--ce===0&&n.close(oe.fd,Re=>{Re?this[U](Re,S):this[N](),Y()})};oe.on("finish",pe=>{let Re=S.absolute,dt=oe.fd;if(S.mtime&&!this.noMtime){ce++;let mt=S.atime||new Date,un=S.mtime;n.futimes(dt,mt,un,hn=>hn?n.utimes(Re,mt,un,Ea=>be(Ea&&hn)):be())}if(this[z](S)){ce++;let mt=this[D](S),un=this[d](S);n.fchown(dt,mt,un,hn=>hn?n.chown(Re,mt,un,Ea=>be(Ea&&hn)):be())}be()});let he=this.transform&&this.transform(S)||S;he!==S&&(he.on("error",pe=>{this[U](pe,S),Y()}),S.pipe(he)),he.pipe(oe)}[O](S,Y){let X=S.mode&4095||this.dmode;this[P](S.absolute,X,oe=>{if(oe){this[U](oe,S),Y();return}let ce=1,be=he=>{--ce===0&&(Y(),this[N](),S.resume())};S.mtime&&!this.noMtime&&(ce++,n.utimes(S.absolute,S.atime||new Date,S.mtime,be)),this[z](S)&&(ce++,n.chown(S.absolute,this[D](S),this[d](S),be)),be()})}[F](S){S.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${S.type}`,{entry:S}),S.resume()}[w](S,Y){this[I](S,S.linkpath,"symlink",Y)}[v](S,Y){let X=f(o.resolve(this.cwd,S.linkpath));this[I](S,X,"link",Y)}[K](){this[V]++}[N](){this[V]--,this[L]()}[j](S){this[N](),S.resume()}[k](S,Y){return S.type==="File"&&!this.unlink&&Y.isFile()&&Y.nlink<=1&&!M}[y](S){this[K]();let Y=[S.path];S.linkpath&&Y.push(S.linkpath),this.reservations.reserve(Y,X=>this[b](S,X))}[x](S){S.type==="SymbolicLink"?re(this.dirCache):S.type!=="Directory"&&G(this.dirCache,S.absolute)}[b](S,Y){this[x](S);let X=he=>{this[x](S),Y(he)},oe=()=>{this[P](this.cwd,this.dmode,he=>{if(he){this[U](he,S),X();return}this[m]=!0,ce()})},ce=()=>{if(S.absolute!==this.cwd){let he=f(o.dirname(S.absolute));if(he!==this.cwd)return this[P](he,this.dmode,pe=>{if(pe){this[U](pe,S),X();return}be()})}be()},be=()=>{n.lstat(S.absolute,(he,pe)=>{if(pe&&(this.keep||this.newer&&pe.mtime>S.mtime)){this[j](S),X();return}if(he||this[k](S,pe))return this[C](null,S,X);if(pe.isDirectory()){if(S.type==="Directory"){let Re=!this.noChmod&&S.mode&&(pe.mode&4095)!==S.mode,dt=mt=>this[C](mt,S,X);return Re?n.chmod(S.absolute,S.mode,dt):dt()}if(S.absolute!==this.cwd)return n.rmdir(S.absolute,Re=>this[C](Re,S,X))}if(S.absolute===this.cwd)return this[C](null,S,X);B(S.absolute,Re=>this[C](Re,S,X))})};this[m]?ce():oe()}[C](S,Y,X){if(S){this[U](S,Y),X();return}switch(Y.type){case"File":case"OldFile":case"ContiguousFile":return this[T](Y,X);case"Link":return this[v](Y,X);case"SymbolicLink":return this[w](Y,X);case"Directory":case"GNUDumpDir":return this[O](Y,X)}}[I](S,Y,X,oe){n[X](Y,S.absolute,ce=>{ce?this[U](ce,S):(this[N](),S.resume()),oe()})}},Ee=S=>{try{return[null,S()]}catch(Y){return[Y,null]}},_e=class extends ue{[C](S,Y){return super[C](S,Y,()=>{})}[y](S){if(this[x](S),!this[m]){let ce=this[P](this.cwd,this.dmode);if(ce)return this[U](ce,S);this[m]=!0}if(S.absolute!==this.cwd){let ce=f(o.dirname(S.absolute));if(ce!==this.cwd){let be=this[P](ce,this.dmode);if(be)return this[U](be,S)}}let[Y,X]=Ee(()=>n.lstatSync(S.absolute));if(X&&(this.keep||this.newer&&X.mtime>S.mtime))return this[j](S);if(Y||this[k](S,X))return this[C](null,S);if(X.isDirectory()){if(S.type==="Directory"){let be=!this.noChmod&&S.mode&&(X.mode&4095)!==S.mode,[he]=be?Ee(()=>{n.chmodSync(S.absolute,S.mode)}):[];return this[C](he,S)}let[ce]=Ee(()=>n.rmdirSync(S.absolute));this[C](ce,S)}let[oe]=S.absolute===this.cwd?[]:Ee(()=>Z(S.absolute));this[C](oe,S)}[T](S,Y){let X=S.mode&4095||this.fmode,oe=he=>{let pe;try{n.closeSync(ce)}catch(Re){pe=Re}(he||pe)&&this[U](he||pe,S),Y()},ce;try{ce=n.openSync(S.absolute,R(S.size),X)}catch(he){return oe(he)}let be=this.transform&&this.transform(S)||S;be!==S&&(be.on("error",he=>this[U](he,S)),S.pipe(be)),be.on("data",he=>{try{n.writeSync(ce,he,0,he.length)}catch(pe){oe(pe)}}),be.on("end",he=>{let pe=null;if(S.mtime&&!this.noMtime){let Re=S.atime||new Date,dt=S.mtime;try{n.futimesSync(ce,Re,dt)}catch(mt){try{n.utimesSync(S.absolute,Re,dt)}catch{pe=mt}}}if(this[z](S)){let Re=this[D](S),dt=this[d](S);try{n.fchownSync(ce,Re,dt)}catch(mt){try{n.chownSync(S.absolute,Re,dt)}catch{pe=pe||mt}}}oe(pe)})}[O](S,Y){let X=S.mode&4095||this.dmode,oe=this[P](S.absolute,X);if(oe){this[U](oe,S),Y();return}if(S.mtime&&!this.noMtime)try{n.utimesSync(S.absolute,S.atime||new Date,S.mtime)}catch{}if(this[z](S))try{n.chownSync(S.absolute,this[D](S),this[d](S))}catch{}Y(),S.resume()}[P](S,Y){try{return a.sync(f(S),{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}}[I](S,Y,X,oe){try{n[X+"Sync"](Y,S.absolute),oe(),S.resume()}catch(ce){return this[U](ce,S)}}};ue.Sync=_e,e.exports=ue}),EP=ee((t,e)=>{"use strict";W();var r=Xn(),i=hS(),n=te("fs"),s=ts(),o=te("path"),a=es();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 b=r(p);if(b.sync&&typeof y=="function")throw new TypeError("callback not supported for sync tar functions");if(!b.file&&typeof y=="function")throw new TypeError("callback only supported with file option");return g.length&&l(b,g),b.file&&b.sync?c(b):b.file?u(b,y):b.sync?f(b):h(b)};var l=(p,g)=>{let y=new Map(g.map(k=>[a(k),!0])),b=p.filter,x=(k,C)=>{let T=C||o.parse(k).root||".",O=k===T?!1:y.has(k)?y.get(k):x(o.dirname(k),T);return y.set(k,O),O};p.filter=b?(k,C)=>b(k,C)&&x(a(k)):k=>x(a(k))},c=p=>{let g=new i.Sync(p),y=p.file,b=n.statSync(y),x=p.maxReadSize||16*1024*1024;new s.ReadStreamSync(y,{readSize:x,size:b.size}).pipe(g)},u=(p,g)=>{let y=new i(p),b=p.maxReadSize||16*1024*1024,x=p.file,k=new Promise((C,T)=>{y.on("error",T),y.on("close",C),n.stat(x,(O,I)=>{if(O)T(O);else{let w=new s.ReadStream(x,{readSize:b,size:I.size});w.on("error",T),w.pipe(y)}})});return g?k.then(g,g):k},f=p=>new i.Sync(p),h=p=>new i(p)}),vP=ee(t=>{"use strict";W(),t.c=t.create=uP(),t.r=t.replace=lS(),t.t=t.list=Gh(),t.u=t.update=hP(),t.x=t.extract=EP(),t.Pack=Hh(),t.Unpack=hS(),t.Parse=Uh(),t.ReadEntry=jh(),t.WriteEntry=oS(),t.Header=Qn(),t.Pax=$h(),t.types=iS()}),RP=ee((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],l=a.message,c=(i[l]||0)+1;i[l]=c,c>=s&&(n=a,s=c)}return n}}),xP=ee(t=>{W();var e=RP();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,l){return a-l}),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],l=r[a];r[a]=function(c){var u=t.operation(i),f=Array.prototype.slice.call(arguments,1),h=f.pop();f.push(function(p){u.retry(p)||(p&&(arguments[0]=u.mainError()),h.apply(this,arguments))}),u.attempt(function(){c.apply(r,f)})}.bind(r,l),r[a].options=i}}}),AP=ee((t,e)=>{W(),e.exports=xP()}),OP=ee((t,e)=>{W();var r=AP();function i(n,s){function o(a,l){var c=s||{},u;"randomize"in c||(c.randomize=!0),u=r.operation(c);function f(g){l(g||new Error("Aborted"))}function h(g,y){if(g.bail){f(g);return}u.retry(g)?c.onRetry&&c.onRetry(g,y):l(u.mainError())}function p(g){var y;try{y=n(f,g)}catch(b){h(b,g);return}Promise.resolve(y).then(a).catch(function(b){h(b,g)})}u.attempt(p)}return new Promise(o)}e.exports=i}),TP={};KL(TP,{bold:()=>IP,dimmed:()=>DP,error:()=>jP,grey:()=>MP,info:()=>PP,item:()=>FP,log:()=>si,turboBlue:()=>tn,turboGradient:()=>CP,turboLoader:()=>LP,turboRed:()=>gS,underline:()=>NP,warn:()=>BP,yellow:()=>yS});W();var dS="#0099F7",mS="#F11712",kP="#FFFF00",zh=t=>{let e=$P(t);return r=>`\x1B[38;5;${e}m${r}${(0,Xe.reset)("")}`},CP=(0,pS.default)(dS,mS),tn=zh(dS),gS=zh(mS),yS=zh(kP),LP=t=>(0,fS.default)({text:t,spinner:{frames:[" ",tn("> "),tn(">> "),tn(">>>")]}}),PP=(...t)=>{si(tn((0,Xe.bold)(">>>")),t.join(" "))},IP=(...t)=>{si((0,Xe.bold)(t.join(" ")))},NP=(...t)=>{si((0,Xe.underline)(t.join(" ")))},DP=(...t)=>{si((0,Xe.dim)(t.join(" ")))},MP=(...t)=>{si((0,Xe.gray)(t.join(" ")))},FP=(...t)=>{si(tn((0,Xe.bold)(" \u2022")),t.join(" "))},si=(...t)=>{console.log(...t)},BP=(...t)=>{console.error(yS((0,Xe.bold)(">>>")),t.join(" "))},jP=(...t)=>{console.error(gS((0,Xe.bold)(">>>")),t.join(" "))};function $P(t){let e=parseInt(t.slice(1),16),r=Math.floor(e/(256*256))%256,i=Math.floor(e/256)%256,n=e%256;return 16+36*Math.round(r/255*5)+6*Math.round(i/255*5)+Math.round(n/255*5)}W();W();W();W();var rB=ua(QL());W();W();function HP(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}W();W();function Dh(t){return Dh=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},Dh(t)}W();function UP(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function GP(t,e){if(e&&(Dh(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return UP(t)}W();function ca(t){return ca=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ca(t)}W();W();function Vn(t,e){return Vn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Vn(t,e)}function zP(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&&Vn(t,e)}W();W();function WP(t){return Function.toString.call(t).indexOf("[native code]")!==-1}W();W();function YP(){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 la(t,e,r){return YP()?la=Reflect.construct.bind():la=function(i,n,s){var o=[null];o.push.apply(o,n);var a=Function.bind.apply(i,o),l=new a;return s&&Vn(l,s.prototype),l},la.apply(null,arguments)}function Mh(t){var e=typeof Map=="function"?new Map:void 0;return Mh=function(r){if(r===null||!WP(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 la(r,arguments,ca(this).constructor)}return i.prototype=Object.create(r.prototype,{constructor:{value:i,enumerable:!1,writable:!0,configurable:!0}}),Vn(i,r)},Mh(t)}var iB=ua(sP()),oB=function(t){zP(e,t);function e(r){var i;return HP(this,e),i=GP(this,ca(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),i.directory=r,i}return e}(Mh(Error));W();W();W();W();W();W();var yB=ua(vP()),bB=(0,_S.promisify)(bS.Stream.pipeline);W();W();var EB=ua(OP());W();W();W();var $e=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,$e)}};W();W();W();W();var VP=/^(?!_)(?<manager>.+)@(?<version>.+)$/;function Je({workspaceRoot:t}){let e=sr.default.join(t,"package.json");try{return(0,st.readJsonSync)(e,"utf8")}catch(r){if(r&&typeof r=="object"&&"code"in r){if(r.code==="ENOENT")throw new $e(`no "package.json" found at ${t}`,{type:"package_json-missing"});if(r.code==="EJSONPARSE")throw new $e(`failed to parse "package.json" at ${t}`,{type:"package_json-parse_error"})}throw new Error(`unexpected error reading "package.json" at ${t}`)}}function ha({workspaceRoot:t}){let{packageManager:e}=Je({workspaceRoot:t});if(e)try{let r=VP.exec(e);if(r){let[i,n]=r;return n}}catch{}}function rs({workspaceRoot:t}){let e=Je({workspaceRoot:t}),r=sr.default.basename(t),{name:i=r,description:n}=e;return{name:i,description:n}}function Jw({workspaceRoot:t}){let e=sr.default.join(t,"pnpm-workspace.yaml");if((0,st.existsSync)(e))try{let r=za.load((0,st.readFileSync)(e,"utf8"));if(r instanceof Object&&"packages"in r&&Array.isArray(r.packages))return r.packages}catch{throw new $e(`failed to parse ${e}`,{type:"pnpm-workspace_parse_error"})}return[]}function fa({root:t,lockFile:e,workspaceConfig:r}){let i=s=>sr.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 Wh({workspaces:t}){var e;return t?Array.isArray(t)?t:"packages"in t?(e=t.packages)!=null?e:[]:[]:[]}function pa({workspaceRoot:t,workspaceGlobs:e}){if(!e)return[];let r=e.filter(i=>i.startsWith("!")).map(i=>i.slice(1));return e.filter(i=>!i.startsWith("!")).flatMap(i=>{let n=[`${i}/package.json`];return(0,xS.sync)(n,{onlyFiles:!0,absolute:!0,cwd:t,ignore:["**/node_modules/**",...r]})}).map(i=>{let n=sr.default.dirname(i),{name:s,description:o}=rs({workspaceRoot:n});return{name:s,description:o,paths:{root:n,packageJson:i,nodeModules:sr.default.join(n,"node_modules")}}})}function KP({directory:t}){let e=sr.default.resolve(process.cwd(),t);return{exists:(0,st.existsSync)(e),absolute:e}}function Pr({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 ZP({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 nr({project:t,options:e}){e!=null&&e.dry||(0,st.rmSync)(t.paths.lockfile,{force:!0})}async function AS({project:t,options:e}){if(!(e!=null&&e.dry)&&(0,st.existsSync)(t.paths.lockfile))try{let{stdout:r}=await(0,RS.default)("bun",["bun.lockb"],{stdin:"ignore",cwd:t.paths.root});await(0,st.writeFile)(sr.default.join(t.paths.root,"yarn.lock"),r)}catch{}finally{(0,st.rmSync)(t.paths.lockfile,{force:!0})}}function XP({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 Cr({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=Je({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}=XP({dependencyList:h,project:t,to:r});s[f]=g,o[f]=p}});let l=f=>{let h=o[f].length;if(h>0)return`${(0,vS.green)(h.toString())} ${f}`},c=a.map(l).filter(Boolean),u=`./${SS.default.relative(t.paths.root,e.paths.packageJson)}`;if(c.length>=1){let f="updating";c.forEach((h,p)=>{c.length===1?f+=` ${h} in ${u}`:p===c.length-1?f+=`and ${h} in ${u}`:f+=` ${h}, `}),i.workspaceStep(f)}else i.workspaceStep(`no workspace dependencies found in ${u}`);n!=null&&n.dry||(0,ES.writeJSONSync)(e.paths.packageJson,s,{spaces:2})}var Lr={name:"pnpm",lock:"pnpm-lock.yaml"};async function OS(t){let e=ii.default.join(t.workspaceRoot,Lr.lock),r=ii.default.join(t.workspaceRoot,"pnpm-workspace.yaml"),i=ha({workspaceRoot:t.workspaceRoot});return(0,Ue.existsSync)(e)||(0,Ue.existsSync)(r)||i===Lr.name}async function JP(t){if(!await OS(t))throw new $e("Not a pnpm project",{type:"package_manager-unexpected"});let{name:e,description:r}=rs(t);return{name:e,description:r,packageManager:Lr.name,paths:fa({root:t.workspaceRoot,lockFile:Lr.lock,workspaceConfig:"pnpm-workspace.yaml"}),workspaceData:{globs:Jw(t),workspaces:pa({workspaceGlobs:Jw(t),...t})}}}async function QP(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;i.mainStep(Pr({action:"create",packageManager:Lr.name,project:e}));let o=Je({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,Ue.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),s&&(i.rootStep('adding "pnpm-workspace.yaml"'),(0,Ue.writeFileSync)(ii.default.join(e.paths.root,"pnpm-workspace.yaml"),`packages:
|
43
43
|
${e.workspaceData.globs.map(a=>` - "${a}"`).join(`
|
44
|
-
`)}`))),s&&(Cr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Cr({workspace:a,project:e,to:r,logger:i,options:n})}))}async function eI(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Pr({action:"remove",packageManager:Lr.name,project:e}));let s=Je({workspaceRoot:e.paths.root});if(e.paths.workspaceConfig&&n&&(r.subStep('removing "pnpm-workspace.yaml"'),i!=null&&i.dry||(0,Ue.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,Ue.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,Ue.rm)(a,{recursive:!0,force:!0})))}catch{throw new $e("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function tI(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,Ue.rmSync)(e.paths.lockfile,{force:!0})}async function rI(t){let{project:e,options:r,logger:i}=t,n=()=>{i.subStep(`converting ${ii.default.relative(e.paths.root,e.paths.lockfile)} to ${Lr.lock}`)},s=async()=>{if(!(r!=null&&r.dry)&&(0,Ue.existsSync)(e.paths.lockfile))try{await(0,wS.default)(Lr.name,["import"],{stdio:"ignore",cwd:e.paths.root})}catch{}finally{nr({project:e,options:r})}};switch(e.packageManager){case"pnpm":break;case"bun":n(),await AS({project:e,options:r}),await s(),(0,Ue.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 iI={detect:OS,read:JP,create:QP,remove:eI,clean:tI,convertLock:rI};W();var rn={name:"npm",lock:"package-lock.json"};async function TS(t){let e=Vn.default.join(t.workspaceRoot,rn.lock),r=ha({workspaceRoot:t.workspaceRoot});return(0,Dt.existsSync)(e)||r===rn.name}async function nI(t){if(!await TS(t))throw new $e("Not an npm project",{type:"package_manager-unexpected"});let e=Je(t),{name:r,description:i}=rs(t),n=Wh({workspaces:e.workspaces});return{name:r,description:i,packageManager:rn.name,paths:fa({root:t.workspaceRoot,lockFile:rn.lock}),workspaceData:{globs:n,workspaces:pa({workspaceGlobs:n,...t})}}}async function sI(t){let{project:e,options:r,to:i,logger:n}=t,s=e.workspaceData.globs.length>0;n.mainStep(Pr({packageManager:rn.name,action:"create",project:e}));let o=Je({workspaceRoot:e.paths.root});n.rootHeader(),n.rootStep(`adding "packageManager" field to ${Vn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${i.name}@${i.version}`,s?(n.rootStep(`adding "workspaces" field to ${Vn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,r!=null&&r.dry||(0,Dt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),Cr({workspace:{name:"root",paths:e.paths},project:e,to:i,logger:n,options:r}),n.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Cr({workspace:a,project:e,to:i,logger:n,options:r})})):r!=null&&r.dry||(0,Dt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function oI(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Pr({packageManager:rn.name,action:"remove",project:e}));let s=Je({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,Dt.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,Dt.rm)(a,{recursive:!0,force:!0})))}catch{throw new $e("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function aI(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,Dt.rmSync)(e.paths.lockfile,{force:!0})}async function lI(t){let{project:e,options:r}=t;switch(e.packageManager){case"pnpm":nr({project:e,options:r});break;case"bun":nr({project:e,options:r});break;case"npm":break;case"yarn":nr({project:e,options:r});break}}var cI={detect:TS,read:nI,create:sI,remove:oI,clean:aI,convertLock:lI};W();var ni={name:"yarn",lock:"yarn.lock"};async function kS(t){let e=nn.default.join(t.workspaceRoot,ni.lock),r=ha({workspaceRoot:t.workspaceRoot});return(0,Mt.existsSync)(e)||r===ni.name}async function uI(t){if(!await kS(t))throw new $e("Not a yarn project",{type:"package_manager-unexpected"});let e=Je(t),{name:r,description:i}=rs(t),n=Wh({workspaces:e.workspaces});return{name:r,description:i,packageManager:ni.name,paths:fa({root:t.workspaceRoot,lockFile:ni.lock}),workspaceData:{globs:n,workspaces:pa({workspaceGlobs:n,...t})}}}async function hI(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;i.mainStep(Pr({packageManager:ni.name,action:"create",project:e}));let o=Je({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,Mt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),Cr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Cr({workspace:a,project:e,to:r,logger:i,options:n})})):n!=null&&n.dry||(0,Mt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function fI(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Pr({packageManager:ni.name,action:"remove",project:e}));let s=Je({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,Mt.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,Mt.rm)(a,{recursive:!0,force:!0})))}catch{throw new $e("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function pI(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,Mt.rmSync)(e.paths.lockfile,{force:!0})}async function dI(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":nr({project:e,options:r});break;case"bun":n(),await AS({project:e,options:r});break;case"npm":nr({project:e,options:r});break;case"yarn":break}}var mI={detect:kS,read:uI,create:hI,remove:fI,clean:pI,convertLock:dI};W();var sn={name:"bun",lock:"bun.lockb"};async function CS(t){let e=Zn.default.join(t.workspaceRoot,sn.lock),r=ha({workspaceRoot:t.workspaceRoot});return(0,Ft.existsSync)(e)||r===sn.name}async function gI(t){if(!await CS(t))throw new $e("Not a bun project",{type:"package_manager-unexpected"});let e=Je(t),{name:r,description:i}=rs(t),n=Wh({workspaces:e.workspaces});return{name:r,description:i,packageManager:sn.name,paths:fa({root:t.workspaceRoot,lockFile:sn.lock}),workspaceData:{globs:n,workspaces:pa({workspaceGlobs:n,...t})}}}async function yI(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;if(!ZP({project:e}))throw new $e("Unable to convert project to bun - workspace globs unsupported",{type:"bun-workspace_glob_error"});i.mainStep(Pr({packageManager:sn.name,action:"create",project:e}));let o=Je({workspaceRoot:e.paths.root});i.rootHeader(),i.rootStep(`adding "packageManager" field to ${Zn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${r.name}@${r.version}`,s?(i.rootStep(`adding "workspaces" field to ${Zn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,n!=null&&n.dry||(0,Ft.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),Cr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Cr({workspace:a,project:e,to:r,logger:i,options:n})})):n!=null&&n.dry||(0,Ft.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function bI(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Pr({packageManager:sn.name,action:"remove",project:e}));let s=Je({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,Ft.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,Ft.rm)(a,{recursive:!0,force:!0})))}catch{throw new $e("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function _I(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${Zn.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,Ft.rmSync)(e.paths.lockfile,{force:!0})}async function wI(t){let{project:e,options:r}=t;switch(e.packageManager){case"pnpm":nr({project:e,options:r});break;case"bun":break;case"npm":nr({project:e,options:r});break;case"yarn":nr({project:e,options:r});break}}var SI={detect:CS,read:gI,create:yI,remove:bI,clean:_I,convertLock:wI},LS={pnpm:iI,yarn:mI,npm:cI,bun:SI};W();async function is({root:t}){let{exists:e,absolute:r}=VP({directory:t});if(!e)throw new $e(`Could not find directory at ${r}. Ensure the directory exists.`,{type:"invalid_directory"});for(let{detect:i,read:n}of Object.values(LS))if(await i({workspaceRoot:r}))return n({workspaceRoot:r});throw new $e("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 Yh=require("picocolors"),PS=ie(require("is-git-clean"));function da({directory:t,force:e}){var n;let r=!1,i="Unable to determine if git directory is clean";try{r=PS.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(`${(0,Yh.yellow)("WARNING")}: ${i}. Forcibly continuing...`):(ne.log("Thank you for using @turbo/codemod!"),ne.log((0,Yh.yellow)(`
|
44
|
+
`)}`))),s&&(Cr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Cr({workspace:a,project:e,to:r,logger:i,options:n})}))}async function eI(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Pr({action:"remove",packageManager:Lr.name,project:e}));let s=Je({workspaceRoot:e.paths.root});if(e.paths.workspaceConfig&&n&&(r.subStep('removing "pnpm-workspace.yaml"'),i!=null&&i.dry||(0,Ue.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,Ue.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,Ue.rm)(a,{recursive:!0,force:!0})))}catch{throw new $e("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function tI(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,Ue.rmSync)(e.paths.lockfile,{force:!0})}async function rI(t){let{project:e,options:r,logger:i}=t,n=()=>{i.subStep(`converting ${ii.default.relative(e.paths.root,e.paths.lockfile)} to ${Lr.lock}`)},s=async()=>{if(!(r!=null&&r.dry)&&(0,Ue.existsSync)(e.paths.lockfile))try{await(0,wS.default)(Lr.name,["import"],{stdio:"ignore",cwd:e.paths.root})}catch{}finally{nr({project:e,options:r})}};switch(e.packageManager){case"pnpm":break;case"bun":n(),await AS({project:e,options:r}),await s(),(0,Ue.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 iI={detect:OS,read:JP,create:QP,remove:eI,clean:tI,convertLock:rI};W();var rn={name:"npm",lock:"package-lock.json"};async function TS(t){let e=Kn.default.join(t.workspaceRoot,rn.lock),r=ha({workspaceRoot:t.workspaceRoot});return(0,Dt.existsSync)(e)||r===rn.name}async function nI(t){if(!await TS(t))throw new $e("Not an npm project",{type:"package_manager-unexpected"});let e=Je(t),{name:r,description:i}=rs(t),n=Wh({workspaces:e.workspaces});return{name:r,description:i,packageManager:rn.name,paths:fa({root:t.workspaceRoot,lockFile:rn.lock}),workspaceData:{globs:n,workspaces:pa({workspaceGlobs:n,...t})}}}async function sI(t){let{project:e,options:r,to:i,logger:n}=t,s=e.workspaceData.globs.length>0;n.mainStep(Pr({packageManager:rn.name,action:"create",project:e}));let o=Je({workspaceRoot:e.paths.root});n.rootHeader(),n.rootStep(`adding "packageManager" field to ${Kn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${i.name}@${i.version}`,s?(n.rootStep(`adding "workspaces" field to ${Kn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,r!=null&&r.dry||(0,Dt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),Cr({workspace:{name:"root",paths:e.paths},project:e,to:i,logger:n,options:r}),n.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Cr({workspace:a,project:e,to:i,logger:n,options:r})})):r!=null&&r.dry||(0,Dt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function oI(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Pr({packageManager:rn.name,action:"remove",project:e}));let s=Je({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,Dt.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,Dt.rm)(a,{recursive:!0,force:!0})))}catch{throw new $e("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function aI(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${Kn.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,Dt.rmSync)(e.paths.lockfile,{force:!0})}async function lI(t){let{project:e,options:r}=t;switch(e.packageManager){case"pnpm":nr({project:e,options:r});break;case"bun":nr({project:e,options:r});break;case"npm":break;case"yarn":nr({project:e,options:r});break}}var cI={detect:TS,read:nI,create:sI,remove:oI,clean:aI,convertLock:lI};W();var ni={name:"yarn",lock:"yarn.lock"};async function kS(t){let e=nn.default.join(t.workspaceRoot,ni.lock),r=ha({workspaceRoot:t.workspaceRoot});return(0,Mt.existsSync)(e)||r===ni.name}async function uI(t){if(!await kS(t))throw new $e("Not a yarn project",{type:"package_manager-unexpected"});let e=Je(t),{name:r,description:i}=rs(t),n=Wh({workspaces:e.workspaces});return{name:r,description:i,packageManager:ni.name,paths:fa({root:t.workspaceRoot,lockFile:ni.lock}),workspaceData:{globs:n,workspaces:pa({workspaceGlobs:n,...t})}}}async function hI(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;i.mainStep(Pr({packageManager:ni.name,action:"create",project:e}));let o=Je({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,Mt.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),Cr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Cr({workspace:a,project:e,to:r,logger:i,options:n})})):n!=null&&n.dry||(0,Mt.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function fI(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Pr({packageManager:ni.name,action:"remove",project:e}));let s=Je({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,Mt.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,Mt.rm)(a,{recursive:!0,force:!0})))}catch{throw new $e("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function pI(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,Mt.rmSync)(e.paths.lockfile,{force:!0})}async function dI(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":nr({project:e,options:r});break;case"bun":n(),await AS({project:e,options:r});break;case"npm":nr({project:e,options:r});break;case"yarn":break}}var mI={detect:kS,read:uI,create:hI,remove:fI,clean:pI,convertLock:dI};W();var sn={name:"bun",lock:"bun.lockb"};async function CS(t){let e=Zn.default.join(t.workspaceRoot,sn.lock),r=ha({workspaceRoot:t.workspaceRoot});return(0,Ft.existsSync)(e)||r===sn.name}async function gI(t){if(!await CS(t))throw new $e("Not a bun project",{type:"package_manager-unexpected"});let e=Je(t),{name:r,description:i}=rs(t),n=Wh({workspaces:e.workspaces});return{name:r,description:i,packageManager:sn.name,paths:fa({root:t.workspaceRoot,lockFile:sn.lock}),workspaceData:{globs:n,workspaces:pa({workspaceGlobs:n,...t})}}}async function yI(t){let{project:e,to:r,logger:i,options:n}=t,s=e.workspaceData.globs.length>0;if(!ZP({project:e}))throw new $e("Unable to convert project to bun - workspace globs unsupported",{type:"bun-workspace_glob_error"});i.mainStep(Pr({packageManager:sn.name,action:"create",project:e}));let o=Je({workspaceRoot:e.paths.root});i.rootHeader(),i.rootStep(`adding "packageManager" field to ${Zn.default.relative(e.paths.root,e.paths.packageJson)}`),o.packageManager=`${r.name}@${r.version}`,s?(i.rootStep(`adding "workspaces" field to ${Zn.default.relative(e.paths.root,e.paths.packageJson)}`),o.workspaces=e.workspaceData.globs,n!=null&&n.dry||(0,Ft.writeJSONSync)(e.paths.packageJson,o,{spaces:2}),Cr({workspace:{name:"root",paths:e.paths},project:e,to:r,logger:i,options:n}),i.workspaceHeader(),e.workspaceData.workspaces.forEach(a=>{Cr({workspace:a,project:e,to:r,logger:i,options:n})})):n!=null&&n.dry||(0,Ft.writeJSONSync)(e.paths.packageJson,o,{spaces:2})}async function bI(t){let{project:e,logger:r,options:i}=t,n=e.workspaceData.globs.length>0;r.mainStep(Pr({packageManager:sn.name,action:"remove",project:e}));let s=Je({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,Ft.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,Ft.rm)(a,{recursive:!0,force:!0})))}catch{throw new $e("Failed to remove node_modules",{type:"error_removing_node_modules"})}}}async function _I(t){let{project:e,logger:r,options:i}=t;r.subStep(`removing ${Zn.default.relative(e.paths.root,e.paths.lockfile)}`),i!=null&&i.dry||(0,Ft.rmSync)(e.paths.lockfile,{force:!0})}async function wI(t){let{project:e,options:r}=t;switch(e.packageManager){case"pnpm":nr({project:e,options:r});break;case"bun":break;case"npm":nr({project:e,options:r});break;case"yarn":nr({project:e,options:r});break}}var SI={detect:CS,read:gI,create:yI,remove:bI,clean:_I,convertLock:wI},LS={pnpm:iI,yarn:mI,npm:cI,bun:SI};W();async function is({root:t}){let{exists:e,absolute:r}=KP({directory:t});if(!e)throw new $e(`Could not find directory at ${r}. Ensure the directory exists.`,{type:"invalid_directory"});for(let{detect:i,read:n}of Object.values(LS))if(await i({workspaceRoot:r}))return n({workspaceRoot:r});throw new $e("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 Yh=require("picocolors"),PS=ie(require("is-git-clean"));function da({directory:t,force:e}){var n;let r=!1,i="Unable to determine if git directory is clean";try{r=PS.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(`${(0,Yh.yellow)("WARNING")}: ${i}. Forcibly continuing...`):(ne.log("Thank you for using @turbo/codemod!"),ne.log((0,Yh.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 Kh=ie(require("path")),IS=ie(require("fs"));function on({directory:t}){let e=Kh.default.isAbsolute(t)?t:Kh.default.join(process.cwd(),t);return{exists:IS.default.existsSync(e),absolute:e}}var ss=require("picocolors");var qe=require("picocolors"),ma=class{constructor(e){this.transform=e.transformer,this.dry=e.dryRun}_log(...e){console.log(...e)}modified(...e){this._log((0,qe.green)(" MODIFIED "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}unchanged(...e){this._log((0,qe.gray)(" UNCHANGED "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}skipped(...e){this._log((0,qe.yellow)(" SKIPPED "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}error(...e){this._log((0,qe.red)(" ERROR "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}info(...e){this._log((0,qe.bold)(" INFO "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}};var NS=ie(require("os")),Vh=ie(require("path"));var an=require("picocolors"),ya=require("diff"),Ir=require("fs-extra"),ga=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{Vh.default.extname(e.filePath)===".json"?this.before=(0,Ir.readJsonSync)(e.filePath):this.before=(0,Ir.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,ya.diffJson)(this.before,e.after):this.changes=(0,ya.diffLines)(this.before,e.after):this.changes=[]}fileName(){return Vh.default.relative(this.rootPath,this.filePath)}write(){this.after&&(typeof this.after=="object"?(0,Ir.writeJsonSync)(this.filePath,this.after,{spaces:2}):(0,Ir.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((0,an.green)(r.value)):r.removed?process.stdout.write((0,an.red)(r.value)):process.stdout.write((0,an.dim)(r.value))}),ne.log(NS.default.EOL)):ne.log(this.after)}};var oi=class{constructor(e){this.modifications={};this.transform=e.transformer,this.rootPath=e.rootPath,this.dry=e.dryRun,this.print=e.print,this.logger=new ma(e)}abortTransform(e){return this.logger.error(e.reason),{fatalError:new Error(e.reason),changes:e.changes||{}}}modifyFile(e){this.modifications[e.filePath]=new ga({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((0,ss.dim)(n.fileName()));else try{n.write(),s.action="modified",this.logger.modified((0,ss.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((0,ss.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 DS=ie(require("path")),MS=require("fs-extra"),OI=["package.json","turbo.json",".git"];function FS({directory:t}){return OI.some(e=>(0,MS.existsSync)(DS.default.join(t,e)))}var BS=require("child_process");function bt(t,e,r){try{return(0,BS.execSync)(t,{stdio:"pipe",...e}).toString("utf8").trim()}catch{return r||void 0}}function jS(t,e){let{from:r}=e;if(r)return r;let i=bt("turbo --version",{cwd:t.paths.root});if(i)return i;let{packageManager:n}=t;return n==="yarn"?bt("yarn turbo --version",{cwd:t.paths.root}):n==="pnpm"?bt("pnpm turbo --version",{cwd:t.paths.root}):bt("npm exec -c 'turbo --version'",{cwd:t.paths.root})}var $S=ie(require("axios")),TI="https://registry.npmjs.org";async function kI({packageName:t}){try{return(await $S.default.get(`${TI}/${t}`)).data}catch{throw new Error(`Unable to fetch the latest version of ${t}`)}}async function qS({to:t}){let e=await kI({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 or=require("semver");var ba=ie(require("path")),US=ie(require("fs-extra")),HS=process.env.NODE_ENV==="test"?ba.default.join(__dirname,"../transforms"):ba.default.join(__dirname,"./transforms");function _a(){return US.default.readdirSync(HS).map(e=>{let r=ba.default.join(HS,e);try{return require(r).default}catch{return}}).filter(Boolean)}function GS({fromVersion:t,toVersion:e}){let r=t.split(".")[0],n=r!==e.split(".")[0]?`${r}.0.0`:t,s=_a().filter(o=>{var c;let a=(0,or.gt)(o.introducedIn,t)&&(0,or.lte)(o.introducedIn,e),l=((c=o.idempotent)!=null?c:!0)&&(0,or.gt)(o.introducedIn,n)&&(0,or.lte)(o.introducedIn,e);return a||l});return s.sort((o,a)=>(0,or.gt)(o.introducedIn,a.introducedIn)?1:(0,or.eq)(o.introducedIn,a.introducedIn)?0:-1),s}var zS=ie(require("path")),wa=require("fs-extra"),WS=require("semver");function CI(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 LI({packageManager:t,packageManagerVersion:e,installType:r,isUsingWorkspaces:i,to:n="latest"}){let s=o=>o.filter(Boolean).join(" ");switch(t){case"yarn":return(0,WS.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 PI({root:t}){let e=zS.default.join(t,"package.json");if(!(0,wa.existsSync)(e)){ne.error(`Unable to find package.json at ${e}`);return}let r=(0,wa.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 YS({project:t,to:e}){let r=bt("turbo bin",{cwd:t.paths.root,stdio:"pipe"}),i=await Kc(),n=Object.keys(i).find(u=>{let f=i[u];return f&&r?r.includes(f):!1});if(r&&n)return CI(n,e);let{packageManager:s}=t,o=t.workspaceData.globs.length>0,a=PI({root:t.paths.root}),c=(await Yc())[s];if(c&&a)return LI({packageManager:s,packageManagerVersion:c,installType:a,isUsingWorkspaces:o,to:e})}function KS({project:t}){try{let e={cwd:t.paths.root,stdio:"ignore"};if(bt("turbo bin",e))bt("turbo daemon stop",e);else{let i=`${t.packageManager} turbo daemon stop`;t.packageManager==="npm"&&(i="npm exec -c 'turbo daemon stop'"),bt(i,e)}}catch{}}function _t({message:t,success:e}){return e?(ne.bold((0,Oe.green)("Migration completed")),t&&ne.log(t),process.exit(0)):(ne.bold((0,Oe.red)("Migration failed")),t&&ne.log(t),process.exit(1))}async function Zh(t,e){e.dryRun||da({directory:t,force:e.force});let r=await(0,ZS.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 ${(0,Oe.dim)(`(${y})`)} does not exist`},filter:p=>p.trim()}]),{directoryInput:i=t}=r,{exists:n,absolute:s}=on({directory:i});if(!n)return _t({success:!1,message:`Directory ${(0,Oe.dim)(`(${s})`)} does not exist`});if(!FS({directory:s}))return _t({success:!1,message:`Directory (${(0,Oe.dim)(s)}) does not appear to be a repository`});let o;try{o=await is({root:s})}catch{return _t({success:!1,message:`Unable to read determine package manager details from ${(0,Oe.dim)(s)}`})}let a=jS(o,e);if(!a)return _t({success:!1,message:`Unable to infer the version of turbo being used by ${o.name}`});let l=e.to;try{l=await qS(e)}catch(p){let g="UNKNOWN_ERROR";return p instanceof Error&&(g=p.message),_t({success:!1,message:g})}if(!l)return _t({success:!1,message:"Unable to fetch the latest version of turbo"});if(a===l)return _t({success:!0,message:`Nothing to do, current version (${(0,Oe.bold)(a)}) is the same as the requested version (${(0,Oe.bold)(l)})`});let c=GS({fromVersion:a,toVersion:l});c.length===0&&ne.log(`No codemods required to migrate from ${a} to ${l}`,ln.default.EOL),e.dryRun||KS({project:o}),ne.log(`Upgrading turbo from ${(0,Oe.bold)(a)} to ${(0,Oe.bold)(l)} (${c.length===0?"no codemods required":`${c.length} required codemod${c.length===1?"":"s"}`})`,ln.default.EOL);let u=[];for(let[p,g]of c.entries()){ne.log(`(${p+1}/${c.length}) ${(0,Oe.bold)(`Running ${g.name}`)}`);let y=await g.transformer({root:o.paths.root,options:e});oi.logResults(y),u.push(y)}if(u.some(p=>p.fatalError||Object.keys(p.changes).some(g=>p.changes[g].error)))return _t({success:!1,message:"Could not complete migration due to codemod errors. Please fix the errors and try again."});let h=await YS({project:o,to:e.to});if(!h)return _t({success:!1,message:"Unable to determine upgrade command"});if(e.install)if(e.dryRun)ne.log(`Upgrading turbo with ${(0,Oe.bold)(h)} ${(0,Oe.dim)("(dry run)")}`,ln.default.EOL);else{ne.log(`Upgrading turbo with ${(0,Oe.bold)(h)}`,ln.default.EOL);try{(0,VS.execSync)(h,{stdio:"pipe",cwd:o.paths.root})}catch(p){return _t({success:!1,message:`Unable to upgrade turbo: ${String(p)}`})}}else ne.log(`Upgrade turbo with ${(0,Oe.bold)(h)}`,ln.default.EOL);_t({success:!0})}var wt=require("picocolors"),XS=require("inquirer");async function Xh(t,e,r){let i=_a();if(r.list)return ne.log(i.map(h=>`- ${(0,wt.cyan)(h.name)}`).join(`
|
46
|
+
You may use the --force flag to override this safety check.`),process.exit(1)))}var Vh=ie(require("path")),IS=ie(require("fs"));function on({directory:t}){let e=Vh.default.isAbsolute(t)?t:Vh.default.join(process.cwd(),t);return{exists:IS.default.existsSync(e),absolute:e}}var ss=require("picocolors");var qe=require("picocolors"),ma=class{constructor(e){this.transform=e.transformer,this.dry=e.dryRun}_log(...e){console.log(...e)}modified(...e){this._log((0,qe.green)(" MODIFIED "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}unchanged(...e){this._log((0,qe.gray)(" UNCHANGED "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}skipped(...e){this._log((0,qe.yellow)(" SKIPPED "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}error(...e){this._log((0,qe.red)(" ERROR "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}info(...e){this._log((0,qe.bold)(" INFO "),...e,this.dry?(0,qe.dim)("(dry run)"):"")}};var NS=ie(require("os")),Kh=ie(require("path"));var an=require("picocolors"),ya=require("diff"),Ir=require("fs-extra"),ga=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{Kh.default.extname(e.filePath)===".json"?this.before=(0,Ir.readJsonSync)(e.filePath):this.before=(0,Ir.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,ya.diffJson)(this.before,e.after):this.changes=(0,ya.diffLines)(this.before,e.after):this.changes=[]}fileName(){return Kh.default.relative(this.rootPath,this.filePath)}write(){this.after&&(typeof this.after=="object"?(0,Ir.writeJsonSync)(this.filePath,this.after,{spaces:2}):(0,Ir.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((0,an.green)(r.value)):r.removed?process.stdout.write((0,an.red)(r.value)):process.stdout.write((0,an.dim)(r.value))}),ne.log(NS.default.EOL)):ne.log(this.after)}};var oi=class{constructor(e){this.modifications={};this.transform=e.transformer,this.rootPath=e.rootPath,this.dry=e.dryRun,this.print=e.print,this.logger=new ma(e)}abortTransform(e){return this.logger.error(e.reason),{fatalError:new Error(e.reason),changes:e.changes||{}}}modifyFile(e){this.modifications[e.filePath]=new ga({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((0,ss.dim)(n.fileName()));else try{n.write(),s.action="modified",this.logger.modified((0,ss.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((0,ss.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 DS=ie(require("path")),MS=require("fs-extra"),OI=["package.json","turbo.json",".git"];function FS({directory:t}){return OI.some(e=>(0,MS.existsSync)(DS.default.join(t,e)))}var BS=require("child_process");function bt(t,e,r){try{return(0,BS.execSync)(t,{stdio:"pipe",...e}).toString("utf8").trim()}catch{return r||void 0}}function jS(t,e){let{from:r}=e;if(r)return r;let i=bt("turbo --version",{cwd:t.paths.root});if(i)return i;let{packageManager:n}=t;return n==="yarn"?bt("yarn turbo --version",{cwd:t.paths.root}):n==="pnpm"?bt("pnpm turbo --version",{cwd:t.paths.root}):bt("npm exec -c 'turbo --version'",{cwd:t.paths.root})}var $S=ie(require("axios")),TI="https://registry.npmjs.org";async function kI({packageName:t}){try{return(await $S.default.get(`${TI}/${t}`)).data}catch{throw new Error(`Unable to fetch the latest version of ${t}`)}}async function qS({to:t}){let e=await kI({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 or=require("semver");var ba=ie(require("path")),US=ie(require("fs-extra")),HS=process.env.NODE_ENV==="test"?ba.default.join(__dirname,"../transforms"):ba.default.join(__dirname,"./transforms");function _a(){return US.default.readdirSync(HS).map(e=>{let r=ba.default.join(HS,e);try{return require(r).default}catch{return}}).filter(Boolean)}function GS({fromVersion:t,toVersion:e}){let r=t.split(".")[0],n=r!==e.split(".")[0]?`${r}.0.0`:t,s=_a().filter(o=>{var c;let a=(0,or.gt)(o.introducedIn,t)&&(0,or.lte)(o.introducedIn,e),l=((c=o.idempotent)!=null?c:!0)&&(0,or.gt)(o.introducedIn,n)&&(0,or.lte)(o.introducedIn,e);return a||l});return s.sort((o,a)=>(0,or.gt)(o.introducedIn,a.introducedIn)?1:(0,or.eq)(o.introducedIn,a.introducedIn)?0:-1),s}var zS=ie(require("path")),wa=require("fs-extra"),WS=require("semver");function CI(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 LI({packageManager:t,packageManagerVersion:e,installType:r,isUsingWorkspaces:i,to:n="latest"}){let s=o=>o.filter(Boolean).join(" ");switch(t){case"yarn":return(0,WS.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 PI({root:t}){let e=zS.default.join(t,"package.json");if(!(0,wa.existsSync)(e)){ne.error(`Unable to find package.json at ${e}`);return}let r=(0,wa.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 YS({project:t,to:e}){let r=bt("turbo bin",{cwd:t.paths.root,stdio:"pipe"}),i=await Vc(),n=Object.keys(i).find(u=>{let f=i[u];return f&&r?r.includes(f):!1});if(r&&n)return CI(n,e);let{packageManager:s}=t,o=t.workspaceData.globs.length>0,a=PI({root:t.paths.root}),c=(await Yc())[s];if(c&&a)return LI({packageManager:s,packageManagerVersion:c,installType:a,isUsingWorkspaces:o,to:e})}function VS({project:t}){try{let e={cwd:t.paths.root,stdio:"ignore"};if(bt("turbo bin",e))bt("turbo daemon stop",e);else{let i=`${t.packageManager} turbo daemon stop`;t.packageManager==="npm"&&(i="npm exec -c 'turbo daemon stop'"),bt(i,e)}}catch{}}function _t({message:t,success:e}){return e?(ne.bold((0,Oe.green)("Migration completed")),t&&ne.log(t),process.exit(0)):(ne.bold((0,Oe.red)("Migration failed")),t&&ne.log(t),process.exit(1))}async function Zh(t,e){e.dryRun||da({directory:t,force:e.force});let r=await(0,ZS.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 ${(0,Oe.dim)(`(${y})`)} does not exist`},filter:p=>p.trim()}]),{directoryInput:i=t}=r,{exists:n,absolute:s}=on({directory:i});if(!n)return _t({success:!1,message:`Directory ${(0,Oe.dim)(`(${s})`)} does not exist`});if(!FS({directory:s}))return _t({success:!1,message:`Directory (${(0,Oe.dim)(s)}) does not appear to be a repository`});let o;try{o=await is({root:s})}catch{return _t({success:!1,message:`Unable to read determine package manager details from ${(0,Oe.dim)(s)}`})}let a=jS(o,e);if(!a)return _t({success:!1,message:`Unable to infer the version of turbo being used by ${o.name}`});let l=e.to;try{l=await qS(e)}catch(p){let g="UNKNOWN_ERROR";return p instanceof Error&&(g=p.message),_t({success:!1,message:g})}if(!l)return _t({success:!1,message:"Unable to fetch the latest version of turbo"});if(a===l)return _t({success:!0,message:`Nothing to do, current version (${(0,Oe.bold)(a)}) is the same as the requested version (${(0,Oe.bold)(l)})`});let c=GS({fromVersion:a,toVersion:l});c.length===0&&ne.log(`No codemods required to migrate from ${a} to ${l}`,ln.default.EOL),e.dryRun||VS({project:o}),ne.log(`Upgrading turbo from ${(0,Oe.bold)(a)} to ${(0,Oe.bold)(l)} (${c.length===0?"no codemods required":`${c.length} required codemod${c.length===1?"":"s"}`})`,ln.default.EOL);let u=[];for(let[p,g]of c.entries()){ne.log(`(${p+1}/${c.length}) ${(0,Oe.bold)(`Running ${g.name}`)}`);let y=await g.transformer({root:o.paths.root,options:e});oi.logResults(y),u.push(y)}if(u.some(p=>p.fatalError||Object.keys(p.changes).some(g=>p.changes[g].error)))return _t({success:!1,message:"Could not complete migration due to codemod errors. Please fix the errors and try again."});let h=await YS({project:o,to:e.to});if(!h)return _t({success:!1,message:"Unable to determine upgrade command"});if(e.install)if(e.dryRun)ne.log(`Upgrading turbo with ${(0,Oe.bold)(h)} ${(0,Oe.dim)("(dry run)")}`,ln.default.EOL);else{ne.log(`Upgrading turbo with ${(0,Oe.bold)(h)}`,ln.default.EOL);try{(0,KS.execSync)(h,{stdio:"pipe",cwd:o.paths.root})}catch(p){return _t({success:!1,message:`Unable to upgrade turbo: ${String(p)}`})}}else ne.log(`Upgrade turbo with ${(0,Oe.bold)(h)}`,ln.default.EOL);_t({success:!0})}var wt=require("picocolors"),XS=require("inquirer");async function Xh(t,e,r){let i=_a();if(r.list)return ne.log(i.map(h=>`- ${(0,wt.cyan)(h.name)}`).join(`
|
47
47
|
`)),process.exit(0);r.dryRun||da({directory:e,force:r.force});let n=await(0,XS.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 ${(0,wt.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:`${(0,wt.bold)(h.name)} - ${(0,wt.gray)(h.description)} ${(0,wt.gray)(`(${h.introducedIn})`)}`,value:h.name}))}]),{directoryInput:s=e,transformerInput:o=t}=n,{exists:a,absolute:l}=on({directory:s});if(!a)return ne.error(`Directory ${(0,wt.dim)(`(${l})`)} does not exist`),process.exit(1);let c=i.map(h=>h.name),u=i.find(h=>h.name===o);if(!u)return ne.error(`Invalid transform choice ${(0,wt.dim)(`(${t})`)}, pick one of:`),ne.error(c.map(h=>`- ${h}`).join(`
|
48
48
|
`)),process.exit(1);let f=await u.transformer({root:l,options:r});if(f.fatalError)return process.exit(1);oi.logResults(f)}var cn=require("picocolors"),JS=ie(require("update-check"));var II=(0,JS.default)(aa).catch(()=>null);async function Jh(){try{let t=await II;if(t!=null&&t.latest){let{packageManager:e}=await is({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((0,cn.yellow)((0,cn.bold)("A new version of `@turbo/codemod` is available!"))),ne.log(`You can update by running: ${(0,cn.cyan)(r)}`),ne.log()}process.exit()}catch{}}var Sa=new eE.Command;Sa.name("@turbo/codemod").description("Codemod transformations to help upgrade your Turborepo codebase when a feature is deprecated.").version(aa.version,"-v, --version","output the current version");Sa.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(Zh);Sa.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(Xh);Sa.parseAsync().then(Jh).catch(async t=>{ne.log(),ne.log((0,QS.red)("Unexpected error. Please report it as a bug:")),ne.log(t),ne.log(),await Jh(),process.exit(1)});
|
49
49
|
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
|