@wallabyjs/cli 1.0.7 → 1.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +19 -19
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -1,11 +1,11 @@
1
- var ca=Object.create;var ht=Object.defineProperty;var ua=Object.getOwnPropertyDescriptor;var fa=Object.getOwnPropertyNames;var la=Object.getPrototypeOf,da=Object.prototype.hasOwnProperty;var ve=(e,t)=>()=>(e&&(t=e(e=0)),t);var S=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),ma=(e,t)=>{for(var r in t)ht(e,r,{get:t[r],enumerable:!0})},$r=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of fa(t))!da.call(e,o)&&o!==r&&ht(e,o,{get:()=>t[o],enumerable:!(n=ua(t,o))||n.enumerable});return e};var X=(e,t,r)=>(r=e!=null?ca(la(e)):{},$r(t||!e||!e.__esModule?ht(r,"default",{value:e,enumerable:!0}):r,e)),ha=e=>$r(ht({},"__esModule",{value:!0}),e);var K=S(Mt=>{"use strict";Mt.fromCallback=function(e){return Object.defineProperty(function(...t){if(typeof t[t.length-1]=="function")e.apply(this,t);else return new Promise((r,n)=>{t.push((o,i)=>o!=null?n(o):r(i)),e.apply(this,t)})},"name",{value:e.name})};Mt.fromPromise=function(e){return Object.defineProperty(function(...t){let r=t[t.length-1];if(typeof r!="function")return e.apply(this,t);t.pop(),e.apply(this,t).then(n=>r(null,n),r)},"name",{value:e.name})}});var Hr=S((Vf,Mr)=>{var Ie=require("constants"),pa=process.cwd,pt=null,ya=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return pt||(pt=pa.call(process)),pt};try{process.cwd()}catch{}typeof process.chdir=="function"&&(Ht=process.chdir,process.chdir=function(e){pt=null,Ht.call(process,e)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,Ht));var Ht;Mr.exports=ga;function ga(e){Ie.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&t(e),e.lutimes||r(e),e.chown=i(e.chown),e.fchown=i(e.fchown),e.lchown=i(e.lchown),e.chmod=n(e.chmod),e.fchmod=n(e.fchmod),e.lchmod=n(e.lchmod),e.chownSync=s(e.chownSync),e.fchownSync=s(e.fchownSync),e.lchownSync=s(e.lchownSync),e.chmodSync=o(e.chmodSync),e.fchmodSync=o(e.fchmodSync),e.lchmodSync=o(e.lchmodSync),e.stat=a(e.stat),e.fstat=a(e.fstat),e.lstat=a(e.lstat),e.statSync=c(e.statSync),e.fstatSync=c(e.fstatSync),e.lstatSync=c(e.lstatSync),e.chmod&&!e.lchmod&&(e.lchmod=function(l,d,h){h&&process.nextTick(h)},e.lchmodSync=function(){}),e.chown&&!e.lchown&&(e.lchown=function(l,d,h,p){p&&process.nextTick(p)},e.lchownSync=function(){}),ya==="win32"&&(e.rename=typeof e.rename!="function"?e.rename:function(l){function d(h,p,f){var y=Date.now(),w=0;l(h,p,function m(E){if(E&&(E.code==="EACCES"||E.code==="EPERM"||E.code==="EBUSY")&&Date.now()-y<6e4){setTimeout(function(){e.stat(p,function(L,B){L&&L.code==="ENOENT"?l(h,p,m):f(E)})},w),w<100&&(w+=10);return}f&&f(E)})}return Object.setPrototypeOf&&Object.setPrototypeOf(d,l),d}(e.rename)),e.read=typeof e.read!="function"?e.read:function(l){function d(h,p,f,y,w,m){var E;if(m&&typeof m=="function"){var L=0;E=function(B,pe,j){if(B&&B.code==="EAGAIN"&&L<10)return L++,l.call(e,h,p,f,y,w,E);m.apply(this,arguments)}}return l.call(e,h,p,f,y,w,E)}return Object.setPrototypeOf&&Object.setPrototypeOf(d,l),d}(e.read),e.readSync=typeof e.readSync!="function"?e.readSync:function(l){return function(d,h,p,f,y){for(var w=0;;)try{return l.call(e,d,h,p,f,y)}catch(m){if(m.code==="EAGAIN"&&w<10){w++;continue}throw m}}}(e.readSync);function t(l){l.lchmod=function(d,h,p){l.open(d,Ie.O_WRONLY|Ie.O_SYMLINK,h,function(f,y){if(f){p&&p(f);return}l.fchmod(y,h,function(w){l.close(y,function(m){p&&p(w||m)})})})},l.lchmodSync=function(d,h){var p=l.openSync(d,Ie.O_WRONLY|Ie.O_SYMLINK,h),f=!0,y;try{y=l.fchmodSync(p,h),f=!1}finally{if(f)try{l.closeSync(p)}catch{}else l.closeSync(p)}return y}}function r(l){Ie.hasOwnProperty("O_SYMLINK")&&l.futimes?(l.lutimes=function(d,h,p,f){l.open(d,Ie.O_SYMLINK,function(y,w){if(y){f&&f(y);return}l.futimes(w,h,p,function(m){l.close(w,function(E){f&&f(m||E)})})})},l.lutimesSync=function(d,h,p){var f=l.openSync(d,Ie.O_SYMLINK),y,w=!0;try{y=l.futimesSync(f,h,p),w=!1}finally{if(w)try{l.closeSync(f)}catch{}else l.closeSync(f)}return y}):l.futimes&&(l.lutimes=function(d,h,p,f){f&&process.nextTick(f)},l.lutimesSync=function(){})}function n(l){return l&&function(d,h,p){return l.call(e,d,h,function(f){u(f)&&(f=null),p&&p.apply(this,arguments)})}}function o(l){return l&&function(d,h){try{return l.call(e,d,h)}catch(p){if(!u(p))throw p}}}function i(l){return l&&function(d,h,p,f){return l.call(e,d,h,p,function(y){u(y)&&(y=null),f&&f.apply(this,arguments)})}}function s(l){return l&&function(d,h,p){try{return l.call(e,d,h,p)}catch(f){if(!u(f))throw f}}}function a(l){return l&&function(d,h,p){typeof h=="function"&&(p=h,h=null);function f(y,w){w&&(w.uid<0&&(w.uid+=4294967296),w.gid<0&&(w.gid+=4294967296)),p&&p.apply(this,arguments)}return h?l.call(e,d,h,f):l.call(e,d,f)}}function c(l){return l&&function(d,h){var p=h?l.call(e,d,h):l.call(e,d);return p&&(p.uid<0&&(p.uid+=4294967296),p.gid<0&&(p.gid+=4294967296)),p}}function u(l){if(!l||l.code==="ENOSYS")return!0;var d=!process.getuid||process.getuid()!==0;return!!(d&&(l.code==="EINVAL"||l.code==="EPERM"))}}});var Gr=S((Gf,Vr)=>{var Wr=require("stream").Stream;Vr.exports=wa;function wa(e){return{ReadStream:t,WriteStream:r};function t(n,o){if(!(this instanceof t))return new t(n,o);Wr.call(this);var i=this;this.path=n,this.fd=null,this.readable=!0,this.paused=!1,this.flags="r",this.mode=438,this.bufferSize=64*1024,o=o||{};for(var s=Object.keys(o),a=0,c=s.length;a<c;a++){var u=s[a];this[u]=o[u]}if(this.encoding&&this.setEncoding(this.encoding),this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw TypeError("end must be a Number");if(this.start>this.end)throw new Error("start must be <= end");this.pos=this.start}if(this.fd!==null){process.nextTick(function(){i._read()});return}e.open(this.path,this.flags,this.mode,function(l,d){if(l){i.emit("error",l),i.readable=!1;return}i.fd=d,i.emit("open",d),i._read()})}function r(n,o){if(!(this instanceof r))return new r(n,o);Wr.call(this),this.path=n,this.fd=null,this.writable=!0,this.flags="w",this.encoding="binary",this.mode=438,this.bytesWritten=0,o=o||{};for(var i=Object.keys(o),s=0,a=i.length;s<a;s++){var c=i[s];this[c]=o[c]}if(this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.start<0)throw new Error("start must be >= zero");this.pos=this.start}this.busy=!1,this._queue=[],this.fd===null&&(this._open=e.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}});var Zr=S((zf,zr)=>{"use strict";zr.exports=Sa;var Ea=Object.getPrototypeOf||function(e){return e.__proto__};function Sa(e){if(e===null||typeof e!="object")return e;if(e instanceof Object)var t={__proto__:Ea(e)};else var t=Object.create(null);return Object.getOwnPropertyNames(e).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r))}),t}});var $e=S((Zf,Gt)=>{var H=require("fs"),xa=Hr(),va=Gr(),Ca=Zr(),yt=require("util"),te,wt;typeof Symbol=="function"&&typeof Symbol.for=="function"?(te=Symbol.for("graceful-fs.queue"),wt=Symbol.for("graceful-fs.previous")):(te="___graceful-fs.queue",wt="___graceful-fs.previous");function ba(){}function Kr(e,t){Object.defineProperty(e,te,{get:function(){return t}})}var ke=ba;yt.debuglog?ke=yt.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(ke=function(){var e=yt.format.apply(yt,arguments);e="GFS4: "+e.split(/\n/).join(`
2
- GFS4: `),console.error(e)});H[te]||(jr=global[te]||[],Kr(H,jr),H.close=function(e){function t(r,n){return e.call(H,r,function(o){o||Xr(),typeof n=="function"&&n.apply(this,arguments)})}return Object.defineProperty(t,wt,{value:e}),t}(H.close),H.closeSync=function(e){function t(r){e.apply(H,arguments),Xr()}return Object.defineProperty(t,wt,{value:e}),t}(H.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){ke(H[te]),require("assert").equal(H[te].length,0)}));var jr;global[te]||Kr(global,H[te]);Gt.exports=Wt(Ca(H));process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!H.__patched&&(Gt.exports=Wt(H),H.__patched=!0);function Wt(e){xa(e),e.gracefulify=Wt,e.createReadStream=pe,e.createWriteStream=j;var t=e.readFile;e.readFile=r;function r(b,O,D){return typeof O=="function"&&(D=O,O=null),q(b,O,D);function q(U,$,A,v){return t(U,$,function(C){C&&(C.code==="EMFILE"||C.code==="ENFILE")?Be([q,[U,$,A],C,v||Date.now(),Date.now()]):typeof A=="function"&&A.apply(this,arguments)})}}var n=e.writeFile;e.writeFile=o;function o(b,O,D,q){return typeof D=="function"&&(q=D,D=null),U(b,O,D,q);function U($,A,v,C,N){return n($,A,v,function(g){g&&(g.code==="EMFILE"||g.code==="ENFILE")?Be([U,[$,A,v,C],g,N||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}var i=e.appendFile;i&&(e.appendFile=s);function s(b,O,D,q){return typeof D=="function"&&(q=D,D=null),U(b,O,D,q);function U($,A,v,C,N){return i($,A,v,function(g){g&&(g.code==="EMFILE"||g.code==="ENFILE")?Be([U,[$,A,v,C],g,N||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}var a=e.copyFile;a&&(e.copyFile=c);function c(b,O,D,q){return typeof D=="function"&&(q=D,D=0),U(b,O,D,q);function U($,A,v,C,N){return a($,A,v,function(g){g&&(g.code==="EMFILE"||g.code==="ENFILE")?Be([U,[$,A,v,C],g,N||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}var u=e.readdir;e.readdir=d;var l=/^v[0-5]\./;function d(b,O,D){typeof O=="function"&&(D=O,O=null);var q=l.test(process.version)?function(A,v,C,N){return u(A,U(A,v,C,N))}:function(A,v,C,N){return u(A,v,U(A,v,C,N))};return q(b,O,D);function U($,A,v,C){return function(N,g){N&&(N.code==="EMFILE"||N.code==="ENFILE")?Be([q,[$,A,v],N,C||Date.now(),Date.now()]):(g&&g.sort&&g.sort(),typeof v=="function"&&v.call(this,N,g))}}}if(process.version.substr(0,4)==="v0.8"){var h=va(e);m=h.ReadStream,L=h.WriteStream}var p=e.ReadStream;p&&(m.prototype=Object.create(p.prototype),m.prototype.open=E);var f=e.WriteStream;f&&(L.prototype=Object.create(f.prototype),L.prototype.open=B),Object.defineProperty(e,"ReadStream",{get:function(){return m},set:function(b){m=b},enumerable:!0,configurable:!0}),Object.defineProperty(e,"WriteStream",{get:function(){return L},set:function(b){L=b},enumerable:!0,configurable:!0});var y=m;Object.defineProperty(e,"FileReadStream",{get:function(){return y},set:function(b){y=b},enumerable:!0,configurable:!0});var w=L;Object.defineProperty(e,"FileWriteStream",{get:function(){return w},set:function(b){w=b},enumerable:!0,configurable:!0});function m(b,O){return this instanceof m?(p.apply(this,arguments),this):m.apply(Object.create(m.prototype),arguments)}function E(){var b=this;ye(b.path,b.flags,b.mode,function(O,D){O?(b.autoClose&&b.destroy(),b.emit("error",O)):(b.fd=D,b.emit("open",D),b.read())})}function L(b,O){return this instanceof L?(f.apply(this,arguments),this):L.apply(Object.create(L.prototype),arguments)}function B(){var b=this;ye(b.path,b.flags,b.mode,function(O,D){O?(b.destroy(),b.emit("error",O)):(b.fd=D,b.emit("open",D))})}function pe(b,O){return new e.ReadStream(b,O)}function j(b,O){return new e.WriteStream(b,O)}var oe=e.open;e.open=ye;function ye(b,O,D,q){return typeof D=="function"&&(q=D,D=null),U(b,O,D,q);function U($,A,v,C,N){return oe($,A,v,function(g,T){g&&(g.code==="EMFILE"||g.code==="ENFILE")?Be([U,[$,A,v,C],g,N||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}return e}function Be(e){ke("ENQUEUE",e[0].name,e[1]),H[te].push(e),Vt()}var gt;function Xr(){for(var e=Date.now(),t=0;t<H[te].length;++t)H[te][t].length>2&&(H[te][t][3]=e,H[te][t][4]=e);Vt()}function Vt(){if(clearTimeout(gt),gt=void 0,H[te].length!==0){var e=H[te].shift(),t=e[0],r=e[1],n=e[2],o=e[3],i=e[4];if(o===void 0)ke("RETRY",t.name,r),t.apply(null,r);else if(Date.now()-o>=6e4){ke("TIMEOUT",t.name,r);var s=r.pop();typeof s=="function"&&s.call(null,n)}else{var a=Date.now()-i,c=Math.max(i-o,1),u=Math.min(c*1.2,100);a>=u?(ke("RETRY",t.name,r),t.apply(null,r.concat([o]))):H[te].push(e)}gt===void 0&&(gt=setTimeout(Vt,0))}}});var ae=S(Ne=>{"use strict";var Jr=K().fromCallback,se=$e(),Na=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter(e=>typeof se[e]=="function");Object.assign(Ne,se);Na.forEach(e=>{Ne[e]=Jr(se[e])});Ne.exists=function(e,t){return typeof t=="function"?se.exists(e,t):new Promise(r=>se.exists(e,r))};Ne.read=function(e,t,r,n,o,i){return typeof i=="function"?se.read(e,t,r,n,o,i):new Promise((s,a)=>{se.read(e,t,r,n,o,(c,u,l)=>{if(c)return a(c);s({bytesRead:u,buffer:l})})})};Ne.write=function(e,t,...r){return typeof r[r.length-1]=="function"?se.write(e,t,...r):new Promise((n,o)=>{se.write(e,t,...r,(i,s,a)=>{if(i)return o(i);n({bytesWritten:s,buffer:a})})})};Ne.readv=function(e,t,...r){return typeof r[r.length-1]=="function"?se.readv(e,t,...r):new Promise((n,o)=>{se.readv(e,t,...r,(i,s,a)=>{if(i)return o(i);n({bytesRead:s,buffers:a})})})};Ne.writev=function(e,t,...r){return typeof r[r.length-1]=="function"?se.writev(e,t,...r):new Promise((n,o)=>{se.writev(e,t,...r,(i,s,a)=>{if(i)return o(i);n({bytesWritten:s,buffers:a})})})};typeof se.realpath.native=="function"?Ne.realpath.native=Jr(se.realpath.native):process.emitWarning("fs.realpath.native is not a function. Is fs being monkey-patched?","Warning","fs-extra-WARN0003")});var Qr=S((Xf,Yr)=>{"use strict";var Da=require("path");Yr.exports.checkPath=function(t){if(process.platform==="win32"&&/[<>:"|?*]/.test(t.replace(Da.parse(t).root,""))){let n=new Error(`Path contains invalid characters: ${t}`);throw n.code="EINVAL",n}}});var nn=S((Kf,zt)=>{"use strict";var en=ae(),{checkPath:tn}=Qr(),rn=e=>{let t={mode:511};return typeof e=="number"?e:{...t,...e}.mode};zt.exports.makeDir=async(e,t)=>(tn(e),en.mkdir(e,{mode:rn(t),recursive:!0}));zt.exports.makeDirSync=(e,t)=>(tn(e),en.mkdirSync(e,{mode:rn(t),recursive:!0}))});var we=S((Jf,on)=>{"use strict";var Oa=K().fromPromise,{makeDir:Ia,makeDirSync:Zt}=nn(),jt=Oa(Ia);on.exports={mkdirs:jt,mkdirsSync:Zt,mkdirp:jt,mkdirpSync:Zt,ensureDir:jt,ensureDirSync:Zt}});var Le=S((Yf,an)=>{"use strict";var La=K().fromPromise,sn=ae();function Fa(e){return sn.access(e).then(()=>!0).catch(()=>!1)}an.exports={pathExists:La(Fa),pathExistsSync:sn.existsSync}});var Xt=S((Qf,cn)=>{"use strict";var Me=ae(),_a=K().fromPromise;async function Ta(e,t,r){let n=await Me.open(e,"r+"),o=null;try{await Me.futimes(n,t,r)}finally{try{await Me.close(n)}catch(i){o=i}}if(o)throw o}function Aa(e,t,r){let n=Me.openSync(e,"r+");return Me.futimesSync(n,t,r),Me.closeSync(n)}cn.exports={utimesMillis:_a(Ta),utimesMillisSync:Aa}});var Re=S((el,dn)=>{"use strict";var He=ae(),J=require("path"),un=K().fromPromise;function ka(e,t,r){let n=r.dereference?o=>He.stat(o,{bigint:!0}):o=>He.lstat(o,{bigint:!0});return Promise.all([n(e),n(t).catch(o=>{if(o.code==="ENOENT")return null;throw o})]).then(([o,i])=>({srcStat:o,destStat:i}))}function Ra(e,t,r){let n,o=r.dereference?s=>He.statSync(s,{bigint:!0}):s=>He.lstatSync(s,{bigint:!0}),i=o(e);try{n=o(t)}catch(s){if(s.code==="ENOENT")return{srcStat:i,destStat:null};throw s}return{srcStat:i,destStat:n}}async function Pa(e,t,r,n){let{srcStat:o,destStat:i}=await ka(e,t,n);if(i){if(Qe(o,i)){let s=J.basename(e),a=J.basename(t);if(r==="move"&&s!==a&&s.toLowerCase()===a.toLowerCase())return{srcStat:o,destStat:i,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(o.isDirectory()&&!i.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!o.isDirectory()&&i.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(o.isDirectory()&&Kt(e,t))throw new Error(Et(e,t,r));return{srcStat:o,destStat:i}}function qa(e,t,r,n){let{srcStat:o,destStat:i}=Ra(e,t,n);if(i){if(Qe(o,i)){let s=J.basename(e),a=J.basename(t);if(r==="move"&&s!==a&&s.toLowerCase()===a.toLowerCase())return{srcStat:o,destStat:i,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(o.isDirectory()&&!i.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!o.isDirectory()&&i.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(o.isDirectory()&&Kt(e,t))throw new Error(Et(e,t,r));return{srcStat:o,destStat:i}}async function fn(e,t,r,n){let o=J.resolve(J.dirname(e)),i=J.resolve(J.dirname(r));if(i===o||i===J.parse(i).root)return;let s;try{s=await He.stat(i,{bigint:!0})}catch(a){if(a.code==="ENOENT")return;throw a}if(Qe(t,s))throw new Error(Et(e,r,n));return fn(e,t,i,n)}function ln(e,t,r,n){let o=J.resolve(J.dirname(e)),i=J.resolve(J.dirname(r));if(i===o||i===J.parse(i).root)return;let s;try{s=He.statSync(i,{bigint:!0})}catch(a){if(a.code==="ENOENT")return;throw a}if(Qe(t,s))throw new Error(Et(e,r,n));return ln(e,t,i,n)}function Qe(e,t){return t.ino&&t.dev&&t.ino===e.ino&&t.dev===e.dev}function Kt(e,t){let r=J.resolve(e).split(J.sep).filter(o=>o),n=J.resolve(t).split(J.sep).filter(o=>o);return r.every((o,i)=>n[i]===o)}function Et(e,t,r){return`Cannot ${r} '${e}' to a subdirectory of itself, '${t}'.`}dn.exports={checkPaths:un(Pa),checkPathsSync:qa,checkParentPaths:un(fn),checkParentPathsSync:ln,isSrcSubdir:Kt,areIdentical:Qe}});var gn=S((tl,yn)=>{"use strict";var ne=ae(),et=require("path"),{mkdirs:Ua}=we(),{pathExists:Ba}=Le(),{utimesMillis:$a}=Xt(),tt=Re();async function Ma(e,t,r={}){typeof r=="function"&&(r={filter:r}),r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
1
+ var sa=Object.create;var ht=Object.defineProperty;var aa=Object.getOwnPropertyDescriptor;var ca=Object.getOwnPropertyNames;var ua=Object.getPrototypeOf,fa=Object.prototype.hasOwnProperty;var ve=(e,t)=>()=>(e&&(t=e(e=0)),t);var S=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),la=(e,t)=>{for(var r in t)ht(e,r,{get:t[r],enumerable:!0})},Ur=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of ca(t))!fa.call(e,o)&&o!==r&&ht(e,o,{get:()=>t[o],enumerable:!(n=aa(t,o))||n.enumerable});return e};var X=(e,t,r)=>(r=e!=null?sa(ua(e)):{},Ur(t||!e||!e.__esModule?ht(r,"default",{value:e,enumerable:!0}):r,e)),da=e=>Ur(ht({},"__esModule",{value:!0}),e);var K=S(Mt=>{"use strict";Mt.fromCallback=function(e){return Object.defineProperty(function(...t){if(typeof t[t.length-1]=="function")e.apply(this,t);else return new Promise((r,n)=>{t.push((o,i)=>o!=null?n(o):r(i)),e.apply(this,t)})},"name",{value:e.name})};Mt.fromPromise=function(e){return Object.defineProperty(function(...t){let r=t[t.length-1];if(typeof r!="function")return e.apply(this,t);t.pop(),e.apply(this,t).then(n=>r(null,n),r)},"name",{value:e.name})}});var $r=S((Mf,Br)=>{var Ie=require("constants"),ma=process.cwd,pt=null,ha=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return pt||(pt=ma.call(process)),pt};try{process.cwd()}catch{}typeof process.chdir=="function"&&(Ht=process.chdir,process.chdir=function(e){pt=null,Ht.call(process,e)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,Ht));var Ht;Br.exports=pa;function pa(e){Ie.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&t(e),e.lutimes||r(e),e.chown=i(e.chown),e.fchown=i(e.fchown),e.lchown=i(e.lchown),e.chmod=n(e.chmod),e.fchmod=n(e.fchmod),e.lchmod=n(e.lchmod),e.chownSync=s(e.chownSync),e.fchownSync=s(e.fchownSync),e.lchownSync=s(e.lchownSync),e.chmodSync=o(e.chmodSync),e.fchmodSync=o(e.fchmodSync),e.lchmodSync=o(e.lchmodSync),e.stat=a(e.stat),e.fstat=a(e.fstat),e.lstat=a(e.lstat),e.statSync=c(e.statSync),e.fstatSync=c(e.fstatSync),e.lstatSync=c(e.lstatSync),e.chmod&&!e.lchmod&&(e.lchmod=function(l,d,h){h&&process.nextTick(h)},e.lchmodSync=function(){}),e.chown&&!e.lchown&&(e.lchown=function(l,d,h,p){p&&process.nextTick(p)},e.lchownSync=function(){}),ha==="win32"&&(e.rename=typeof e.rename!="function"?e.rename:function(l){function d(h,p,f){var y=Date.now(),w=0;l(h,p,function m(E){if(E&&(E.code==="EACCES"||E.code==="EPERM"||E.code==="EBUSY")&&Date.now()-y<6e4){setTimeout(function(){e.stat(p,function(L,B){L&&L.code==="ENOENT"?l(h,p,m):f(E)})},w),w<100&&(w+=10);return}f&&f(E)})}return Object.setPrototypeOf&&Object.setPrototypeOf(d,l),d}(e.rename)),e.read=typeof e.read!="function"?e.read:function(l){function d(h,p,f,y,w,m){var E;if(m&&typeof m=="function"){var L=0;E=function(B,pe,j){if(B&&B.code==="EAGAIN"&&L<10)return L++,l.call(e,h,p,f,y,w,E);m.apply(this,arguments)}}return l.call(e,h,p,f,y,w,E)}return Object.setPrototypeOf&&Object.setPrototypeOf(d,l),d}(e.read),e.readSync=typeof e.readSync!="function"?e.readSync:function(l){return function(d,h,p,f,y){for(var w=0;;)try{return l.call(e,d,h,p,f,y)}catch(m){if(m.code==="EAGAIN"&&w<10){w++;continue}throw m}}}(e.readSync);function t(l){l.lchmod=function(d,h,p){l.open(d,Ie.O_WRONLY|Ie.O_SYMLINK,h,function(f,y){if(f){p&&p(f);return}l.fchmod(y,h,function(w){l.close(y,function(m){p&&p(w||m)})})})},l.lchmodSync=function(d,h){var p=l.openSync(d,Ie.O_WRONLY|Ie.O_SYMLINK,h),f=!0,y;try{y=l.fchmodSync(p,h),f=!1}finally{if(f)try{l.closeSync(p)}catch{}else l.closeSync(p)}return y}}function r(l){Ie.hasOwnProperty("O_SYMLINK")&&l.futimes?(l.lutimes=function(d,h,p,f){l.open(d,Ie.O_SYMLINK,function(y,w){if(y){f&&f(y);return}l.futimes(w,h,p,function(m){l.close(w,function(E){f&&f(m||E)})})})},l.lutimesSync=function(d,h,p){var f=l.openSync(d,Ie.O_SYMLINK),y,w=!0;try{y=l.futimesSync(f,h,p),w=!1}finally{if(w)try{l.closeSync(f)}catch{}else l.closeSync(f)}return y}):l.futimes&&(l.lutimes=function(d,h,p,f){f&&process.nextTick(f)},l.lutimesSync=function(){})}function n(l){return l&&function(d,h,p){return l.call(e,d,h,function(f){u(f)&&(f=null),p&&p.apply(this,arguments)})}}function o(l){return l&&function(d,h){try{return l.call(e,d,h)}catch(p){if(!u(p))throw p}}}function i(l){return l&&function(d,h,p,f){return l.call(e,d,h,p,function(y){u(y)&&(y=null),f&&f.apply(this,arguments)})}}function s(l){return l&&function(d,h,p){try{return l.call(e,d,h,p)}catch(f){if(!u(f))throw f}}}function a(l){return l&&function(d,h,p){typeof h=="function"&&(p=h,h=null);function f(y,w){w&&(w.uid<0&&(w.uid+=4294967296),w.gid<0&&(w.gid+=4294967296)),p&&p.apply(this,arguments)}return h?l.call(e,d,h,f):l.call(e,d,f)}}function c(l){return l&&function(d,h){var p=h?l.call(e,d,h):l.call(e,d);return p&&(p.uid<0&&(p.uid+=4294967296),p.gid<0&&(p.gid+=4294967296)),p}}function u(l){if(!l||l.code==="ENOSYS")return!0;var d=!process.getuid||process.getuid()!==0;return!!(d&&(l.code==="EINVAL"||l.code==="EPERM"))}}});var Wr=S((Hf,Hr)=>{var Mr=require("stream").Stream;Hr.exports=ya;function ya(e){return{ReadStream:t,WriteStream:r};function t(n,o){if(!(this instanceof t))return new t(n,o);Mr.call(this);var i=this;this.path=n,this.fd=null,this.readable=!0,this.paused=!1,this.flags="r",this.mode=438,this.bufferSize=64*1024,o=o||{};for(var s=Object.keys(o),a=0,c=s.length;a<c;a++){var u=s[a];this[u]=o[u]}if(this.encoding&&this.setEncoding(this.encoding),this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw TypeError("end must be a Number");if(this.start>this.end)throw new Error("start must be <= end");this.pos=this.start}if(this.fd!==null){process.nextTick(function(){i._read()});return}e.open(this.path,this.flags,this.mode,function(l,d){if(l){i.emit("error",l),i.readable=!1;return}i.fd=d,i.emit("open",d),i._read()})}function r(n,o){if(!(this instanceof r))return new r(n,o);Mr.call(this),this.path=n,this.fd=null,this.writable=!0,this.flags="w",this.encoding="binary",this.mode=438,this.bytesWritten=0,o=o||{};for(var i=Object.keys(o),s=0,a=i.length;s<a;s++){var c=i[s];this[c]=o[c]}if(this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.start<0)throw new Error("start must be >= zero");this.pos=this.start}this.busy=!1,this._queue=[],this.fd===null&&(this._open=e.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}});var Gr=S((Wf,Vr)=>{"use strict";Vr.exports=wa;var ga=Object.getPrototypeOf||function(e){return e.__proto__};function wa(e){if(e===null||typeof e!="object")return e;if(e instanceof Object)var t={__proto__:ga(e)};else var t=Object.create(null);return Object.getOwnPropertyNames(e).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r))}),t}});var $e=S((Vf,Gt)=>{var H=require("fs"),Ea=$r(),Sa=Wr(),xa=Gr(),yt=require("util"),te,wt;typeof Symbol=="function"&&typeof Symbol.for=="function"?(te=Symbol.for("graceful-fs.queue"),wt=Symbol.for("graceful-fs.previous")):(te="___graceful-fs.queue",wt="___graceful-fs.previous");function va(){}function jr(e,t){Object.defineProperty(e,te,{get:function(){return t}})}var ke=va;yt.debuglog?ke=yt.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(ke=function(){var e=yt.format.apply(yt,arguments);e="GFS4: "+e.split(/\n/).join(`
2
+ GFS4: `),console.error(e)});H[te]||(zr=global[te]||[],jr(H,zr),H.close=function(e){function t(r,n){return e.call(H,r,function(o){o||Zr(),typeof n=="function"&&n.apply(this,arguments)})}return Object.defineProperty(t,wt,{value:e}),t}(H.close),H.closeSync=function(e){function t(r){e.apply(H,arguments),Zr()}return Object.defineProperty(t,wt,{value:e}),t}(H.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){ke(H[te]),require("assert").equal(H[te].length,0)}));var zr;global[te]||jr(global,H[te]);Gt.exports=Wt(xa(H));process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!H.__patched&&(Gt.exports=Wt(H),H.__patched=!0);function Wt(e){Ea(e),e.gracefulify=Wt,e.createReadStream=pe,e.createWriteStream=j;var t=e.readFile;e.readFile=r;function r(b,O,D){return typeof O=="function"&&(D=O,O=null),q(b,O,D);function q(U,$,A,v){return t(U,$,function(C){C&&(C.code==="EMFILE"||C.code==="ENFILE")?Be([q,[U,$,A],C,v||Date.now(),Date.now()]):typeof A=="function"&&A.apply(this,arguments)})}}var n=e.writeFile;e.writeFile=o;function o(b,O,D,q){return typeof D=="function"&&(q=D,D=null),U(b,O,D,q);function U($,A,v,C,N){return n($,A,v,function(g){g&&(g.code==="EMFILE"||g.code==="ENFILE")?Be([U,[$,A,v,C],g,N||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}var i=e.appendFile;i&&(e.appendFile=s);function s(b,O,D,q){return typeof D=="function"&&(q=D,D=null),U(b,O,D,q);function U($,A,v,C,N){return i($,A,v,function(g){g&&(g.code==="EMFILE"||g.code==="ENFILE")?Be([U,[$,A,v,C],g,N||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}var a=e.copyFile;a&&(e.copyFile=c);function c(b,O,D,q){return typeof D=="function"&&(q=D,D=0),U(b,O,D,q);function U($,A,v,C,N){return a($,A,v,function(g){g&&(g.code==="EMFILE"||g.code==="ENFILE")?Be([U,[$,A,v,C],g,N||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}var u=e.readdir;e.readdir=d;var l=/^v[0-5]\./;function d(b,O,D){typeof O=="function"&&(D=O,O=null);var q=l.test(process.version)?function(A,v,C,N){return u(A,U(A,v,C,N))}:function(A,v,C,N){return u(A,v,U(A,v,C,N))};return q(b,O,D);function U($,A,v,C){return function(N,g){N&&(N.code==="EMFILE"||N.code==="ENFILE")?Be([q,[$,A,v],N,C||Date.now(),Date.now()]):(g&&g.sort&&g.sort(),typeof v=="function"&&v.call(this,N,g))}}}if(process.version.substr(0,4)==="v0.8"){var h=Sa(e);m=h.ReadStream,L=h.WriteStream}var p=e.ReadStream;p&&(m.prototype=Object.create(p.prototype),m.prototype.open=E);var f=e.WriteStream;f&&(L.prototype=Object.create(f.prototype),L.prototype.open=B),Object.defineProperty(e,"ReadStream",{get:function(){return m},set:function(b){m=b},enumerable:!0,configurable:!0}),Object.defineProperty(e,"WriteStream",{get:function(){return L},set:function(b){L=b},enumerable:!0,configurable:!0});var y=m;Object.defineProperty(e,"FileReadStream",{get:function(){return y},set:function(b){y=b},enumerable:!0,configurable:!0});var w=L;Object.defineProperty(e,"FileWriteStream",{get:function(){return w},set:function(b){w=b},enumerable:!0,configurable:!0});function m(b,O){return this instanceof m?(p.apply(this,arguments),this):m.apply(Object.create(m.prototype),arguments)}function E(){var b=this;ye(b.path,b.flags,b.mode,function(O,D){O?(b.autoClose&&b.destroy(),b.emit("error",O)):(b.fd=D,b.emit("open",D),b.read())})}function L(b,O){return this instanceof L?(f.apply(this,arguments),this):L.apply(Object.create(L.prototype),arguments)}function B(){var b=this;ye(b.path,b.flags,b.mode,function(O,D){O?(b.destroy(),b.emit("error",O)):(b.fd=D,b.emit("open",D))})}function pe(b,O){return new e.ReadStream(b,O)}function j(b,O){return new e.WriteStream(b,O)}var oe=e.open;e.open=ye;function ye(b,O,D,q){return typeof D=="function"&&(q=D,D=null),U(b,O,D,q);function U($,A,v,C,N){return oe($,A,v,function(g,T){g&&(g.code==="EMFILE"||g.code==="ENFILE")?Be([U,[$,A,v,C],g,N||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}return e}function Be(e){ke("ENQUEUE",e[0].name,e[1]),H[te].push(e),Vt()}var gt;function Zr(){for(var e=Date.now(),t=0;t<H[te].length;++t)H[te][t].length>2&&(H[te][t][3]=e,H[te][t][4]=e);Vt()}function Vt(){if(clearTimeout(gt),gt=void 0,H[te].length!==0){var e=H[te].shift(),t=e[0],r=e[1],n=e[2],o=e[3],i=e[4];if(o===void 0)ke("RETRY",t.name,r),t.apply(null,r);else if(Date.now()-o>=6e4){ke("TIMEOUT",t.name,r);var s=r.pop();typeof s=="function"&&s.call(null,n)}else{var a=Date.now()-i,c=Math.max(i-o,1),u=Math.min(c*1.2,100);a>=u?(ke("RETRY",t.name,r),t.apply(null,r.concat([o]))):H[te].push(e)}gt===void 0&&(gt=setTimeout(Vt,0))}}});var ae=S(Ne=>{"use strict";var Xr=K().fromCallback,se=$e(),Ca=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter(e=>typeof se[e]=="function");Object.assign(Ne,se);Ca.forEach(e=>{Ne[e]=Xr(se[e])});Ne.exists=function(e,t){return typeof t=="function"?se.exists(e,t):new Promise(r=>se.exists(e,r))};Ne.read=function(e,t,r,n,o,i){return typeof i=="function"?se.read(e,t,r,n,o,i):new Promise((s,a)=>{se.read(e,t,r,n,o,(c,u,l)=>{if(c)return a(c);s({bytesRead:u,buffer:l})})})};Ne.write=function(e,t,...r){return typeof r[r.length-1]=="function"?se.write(e,t,...r):new Promise((n,o)=>{se.write(e,t,...r,(i,s,a)=>{if(i)return o(i);n({bytesWritten:s,buffer:a})})})};Ne.readv=function(e,t,...r){return typeof r[r.length-1]=="function"?se.readv(e,t,...r):new Promise((n,o)=>{se.readv(e,t,...r,(i,s,a)=>{if(i)return o(i);n({bytesRead:s,buffers:a})})})};Ne.writev=function(e,t,...r){return typeof r[r.length-1]=="function"?se.writev(e,t,...r):new Promise((n,o)=>{se.writev(e,t,...r,(i,s,a)=>{if(i)return o(i);n({bytesWritten:s,buffers:a})})})};typeof se.realpath.native=="function"?Ne.realpath.native=Xr(se.realpath.native):process.emitWarning("fs.realpath.native is not a function. Is fs being monkey-patched?","Warning","fs-extra-WARN0003")});var Jr=S((zf,Kr)=>{"use strict";var ba=require("path");Kr.exports.checkPath=function(t){if(process.platform==="win32"&&/[<>:"|?*]/.test(t.replace(ba.parse(t).root,""))){let n=new Error(`Path contains invalid characters: ${t}`);throw n.code="EINVAL",n}}});var tn=S((Zf,zt)=>{"use strict";var Yr=ae(),{checkPath:Qr}=Jr(),en=e=>{let t={mode:511};return typeof e=="number"?e:{...t,...e}.mode};zt.exports.makeDir=async(e,t)=>(Qr(e),Yr.mkdir(e,{mode:en(t),recursive:!0}));zt.exports.makeDirSync=(e,t)=>(Qr(e),Yr.mkdirSync(e,{mode:en(t),recursive:!0}))});var we=S((jf,rn)=>{"use strict";var Na=K().fromPromise,{makeDir:Da,makeDirSync:Zt}=tn(),jt=Na(Da);rn.exports={mkdirs:jt,mkdirsSync:Zt,mkdirp:jt,mkdirpSync:Zt,ensureDir:jt,ensureDirSync:Zt}});var Le=S((Xf,on)=>{"use strict";var Oa=K().fromPromise,nn=ae();function Ia(e){return nn.access(e).then(()=>!0).catch(()=>!1)}on.exports={pathExists:Oa(Ia),pathExistsSync:nn.existsSync}});var Xt=S((Kf,sn)=>{"use strict";var Me=ae(),La=K().fromPromise;async function Fa(e,t,r){let n=await Me.open(e,"r+"),o=null;try{await Me.futimes(n,t,r)}finally{try{await Me.close(n)}catch(i){o=i}}if(o)throw o}function _a(e,t,r){let n=Me.openSync(e,"r+");return Me.futimesSync(n,t,r),Me.closeSync(n)}sn.exports={utimesMillis:La(Fa),utimesMillisSync:_a}});var Re=S((Jf,fn)=>{"use strict";var He=ae(),J=require("path"),an=K().fromPromise;function Ta(e,t,r){let n=r.dereference?o=>He.stat(o,{bigint:!0}):o=>He.lstat(o,{bigint:!0});return Promise.all([n(e),n(t).catch(o=>{if(o.code==="ENOENT")return null;throw o})]).then(([o,i])=>({srcStat:o,destStat:i}))}function Aa(e,t,r){let n,o=r.dereference?s=>He.statSync(s,{bigint:!0}):s=>He.lstatSync(s,{bigint:!0}),i=o(e);try{n=o(t)}catch(s){if(s.code==="ENOENT")return{srcStat:i,destStat:null};throw s}return{srcStat:i,destStat:n}}async function ka(e,t,r,n){let{srcStat:o,destStat:i}=await Ta(e,t,n);if(i){if(Qe(o,i)){let s=J.basename(e),a=J.basename(t);if(r==="move"&&s!==a&&s.toLowerCase()===a.toLowerCase())return{srcStat:o,destStat:i,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(o.isDirectory()&&!i.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!o.isDirectory()&&i.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(o.isDirectory()&&Kt(e,t))throw new Error(Et(e,t,r));return{srcStat:o,destStat:i}}function Ra(e,t,r,n){let{srcStat:o,destStat:i}=Aa(e,t,n);if(i){if(Qe(o,i)){let s=J.basename(e),a=J.basename(t);if(r==="move"&&s!==a&&s.toLowerCase()===a.toLowerCase())return{srcStat:o,destStat:i,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(o.isDirectory()&&!i.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!o.isDirectory()&&i.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(o.isDirectory()&&Kt(e,t))throw new Error(Et(e,t,r));return{srcStat:o,destStat:i}}async function cn(e,t,r,n){let o=J.resolve(J.dirname(e)),i=J.resolve(J.dirname(r));if(i===o||i===J.parse(i).root)return;let s;try{s=await He.stat(i,{bigint:!0})}catch(a){if(a.code==="ENOENT")return;throw a}if(Qe(t,s))throw new Error(Et(e,r,n));return cn(e,t,i,n)}function un(e,t,r,n){let o=J.resolve(J.dirname(e)),i=J.resolve(J.dirname(r));if(i===o||i===J.parse(i).root)return;let s;try{s=He.statSync(i,{bigint:!0})}catch(a){if(a.code==="ENOENT")return;throw a}if(Qe(t,s))throw new Error(Et(e,r,n));return un(e,t,i,n)}function Qe(e,t){return t.ino&&t.dev&&t.ino===e.ino&&t.dev===e.dev}function Kt(e,t){let r=J.resolve(e).split(J.sep).filter(o=>o),n=J.resolve(t).split(J.sep).filter(o=>o);return r.every((o,i)=>n[i]===o)}function Et(e,t,r){return`Cannot ${r} '${e}' to a subdirectory of itself, '${t}'.`}fn.exports={checkPaths:an(ka),checkPathsSync:Ra,checkParentPaths:an(cn),checkParentPathsSync:un,isSrcSubdir:Kt,areIdentical:Qe}});var pn=S((Yf,hn)=>{"use strict";var ne=ae(),et=require("path"),{mkdirs:Pa}=we(),{pathExists:qa}=Le(),{utimesMillis:Ua}=Xt(),tt=Re();async function Ba(e,t,r={}){typeof r=="function"&&(r={filter:r}),r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
3
3
 
4
- see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0001");let{srcStat:n,destStat:o}=await tt.checkPaths(e,t,"copy",r);if(await tt.checkParentPaths(e,n,t,"copy"),!await hn(e,t,r))return;let s=et.dirname(t);await Ba(s)||await Ua(s),await pn(o,e,t,r)}async function hn(e,t,r){return r.filter?r.filter(e,t):!0}async function pn(e,t,r,n){let i=await(n.dereference?ne.stat:ne.lstat)(t);if(i.isDirectory())return Ga(i,e,t,r,n);if(i.isFile()||i.isCharacterDevice()||i.isBlockDevice())return Ha(i,e,t,r,n);if(i.isSymbolicLink())return za(e,t,r,n);throw i.isSocket()?new Error(`Cannot copy a socket file: ${t}`):i.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}async function Ha(e,t,r,n,o){if(!t)return mn(e,r,n,o);if(o.overwrite)return await ne.unlink(n),mn(e,r,n,o);if(o.errorOnExist)throw new Error(`'${n}' already exists`)}async function mn(e,t,r,n){if(await ne.copyFile(t,r),n.preserveTimestamps){Wa(e.mode)&&await Va(r,e.mode);let o=await ne.stat(t);await $a(r,o.atime,o.mtime)}return ne.chmod(r,e.mode)}function Wa(e){return(e&128)===0}function Va(e,t){return ne.chmod(e,t|128)}async function Ga(e,t,r,n,o){t||await ne.mkdir(n);let i=await ne.readdir(r);await Promise.all(i.map(async s=>{let a=et.join(r,s),c=et.join(n,s);if(!await hn(a,c,o))return;let{destStat:l}=await tt.checkPaths(a,c,"copy",o);return pn(l,a,c,o)})),t||await ne.chmod(n,e.mode)}async function za(e,t,r,n){let o=await ne.readlink(t);if(n.dereference&&(o=et.resolve(process.cwd(),o)),!e)return ne.symlink(o,r);let i=null;try{i=await ne.readlink(r)}catch(s){if(s.code==="EINVAL"||s.code==="UNKNOWN")return ne.symlink(o,r);throw s}if(n.dereference&&(i=et.resolve(process.cwd(),i)),tt.isSrcSubdir(o,i))throw new Error(`Cannot copy '${o}' to a subdirectory of itself, '${i}'.`);if(tt.isSrcSubdir(i,o))throw new Error(`Cannot overwrite '${i}' with '${o}'.`);return await ne.unlink(r),ne.symlink(o,r)}yn.exports=Ma});var vn=S((rl,xn)=>{"use strict";var ce=$e(),rt=require("path"),Za=we().mkdirsSync,ja=Xt().utimesMillisSync,nt=Re();function Xa(e,t,r){typeof r=="function"&&(r={filter:r}),r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
4
+ see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0001");let{srcStat:n,destStat:o}=await tt.checkPaths(e,t,"copy",r);if(await tt.checkParentPaths(e,n,t,"copy"),!await dn(e,t,r))return;let s=et.dirname(t);await qa(s)||await Pa(s),await mn(o,e,t,r)}async function dn(e,t,r){return r.filter?r.filter(e,t):!0}async function mn(e,t,r,n){let i=await(n.dereference?ne.stat:ne.lstat)(t);if(i.isDirectory())return Wa(i,e,t,r,n);if(i.isFile()||i.isCharacterDevice()||i.isBlockDevice())return $a(i,e,t,r,n);if(i.isSymbolicLink())return Va(e,t,r,n);throw i.isSocket()?new Error(`Cannot copy a socket file: ${t}`):i.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}async function $a(e,t,r,n,o){if(!t)return ln(e,r,n,o);if(o.overwrite)return await ne.unlink(n),ln(e,r,n,o);if(o.errorOnExist)throw new Error(`'${n}' already exists`)}async function ln(e,t,r,n){if(await ne.copyFile(t,r),n.preserveTimestamps){Ma(e.mode)&&await Ha(r,e.mode);let o=await ne.stat(t);await Ua(r,o.atime,o.mtime)}return ne.chmod(r,e.mode)}function Ma(e){return(e&128)===0}function Ha(e,t){return ne.chmod(e,t|128)}async function Wa(e,t,r,n,o){t||await ne.mkdir(n);let i=await ne.readdir(r);await Promise.all(i.map(async s=>{let a=et.join(r,s),c=et.join(n,s);if(!await dn(a,c,o))return;let{destStat:l}=await tt.checkPaths(a,c,"copy",o);return mn(l,a,c,o)})),t||await ne.chmod(n,e.mode)}async function Va(e,t,r,n){let o=await ne.readlink(t);if(n.dereference&&(o=et.resolve(process.cwd(),o)),!e)return ne.symlink(o,r);let i=null;try{i=await ne.readlink(r)}catch(s){if(s.code==="EINVAL"||s.code==="UNKNOWN")return ne.symlink(o,r);throw s}if(n.dereference&&(i=et.resolve(process.cwd(),i)),tt.isSrcSubdir(o,i))throw new Error(`Cannot copy '${o}' to a subdirectory of itself, '${i}'.`);if(tt.isSrcSubdir(i,o))throw new Error(`Cannot overwrite '${i}' with '${o}'.`);return await ne.unlink(r),ne.symlink(o,r)}hn.exports=Ba});var Sn=S((Qf,En)=>{"use strict";var ce=$e(),rt=require("path"),Ga=we().mkdirsSync,za=Xt().utimesMillisSync,nt=Re();function Za(e,t,r){typeof r=="function"&&(r={filter:r}),r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
5
5
 
6
- see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0002");let{srcStat:n,destStat:o}=nt.checkPathsSync(e,t,"copy",r);if(nt.checkParentPathsSync(e,n,t,"copy"),r.filter&&!r.filter(e,t))return;let i=rt.dirname(t);return ce.existsSync(i)||Za(i),wn(o,e,t,r)}function wn(e,t,r,n){let i=(n.dereference?ce.statSync:ce.lstatSync)(t);if(i.isDirectory())return rc(i,e,t,r,n);if(i.isFile()||i.isCharacterDevice()||i.isBlockDevice())return Ka(i,e,t,r,n);if(i.isSymbolicLink())return oc(e,t,r,n);throw i.isSocket()?new Error(`Cannot copy a socket file: ${t}`):i.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}function Ka(e,t,r,n,o){return t?Ja(e,r,n,o):En(e,r,n,o)}function Ja(e,t,r,n){if(n.overwrite)return ce.unlinkSync(r),En(e,t,r,n);if(n.errorOnExist)throw new Error(`'${r}' already exists`)}function En(e,t,r,n){return ce.copyFileSync(t,r),n.preserveTimestamps&&Ya(e.mode,t,r),Jt(r,e.mode)}function Ya(e,t,r){return Qa(e)&&ec(r,e),tc(t,r)}function Qa(e){return(e&128)===0}function ec(e,t){return Jt(e,t|128)}function Jt(e,t){return ce.chmodSync(e,t)}function tc(e,t){let r=ce.statSync(e);return ja(t,r.atime,r.mtime)}function rc(e,t,r,n,o){return t?Sn(r,n,o):nc(e.mode,r,n,o)}function nc(e,t,r,n){return ce.mkdirSync(r),Sn(t,r,n),Jt(r,e)}function Sn(e,t,r){ce.readdirSync(e).forEach(n=>ic(n,e,t,r))}function ic(e,t,r,n){let o=rt.join(t,e),i=rt.join(r,e);if(n.filter&&!n.filter(o,i))return;let{destStat:s}=nt.checkPathsSync(o,i,"copy",n);return wn(s,o,i,n)}function oc(e,t,r,n){let o=ce.readlinkSync(t);if(n.dereference&&(o=rt.resolve(process.cwd(),o)),e){let i;try{i=ce.readlinkSync(r)}catch(s){if(s.code==="EINVAL"||s.code==="UNKNOWN")return ce.symlinkSync(o,r);throw s}if(n.dereference&&(i=rt.resolve(process.cwd(),i)),nt.isSrcSubdir(o,i))throw new Error(`Cannot copy '${o}' to a subdirectory of itself, '${i}'.`);if(nt.isSrcSubdir(i,o))throw new Error(`Cannot overwrite '${i}' with '${o}'.`);return sc(o,r)}else return ce.symlinkSync(o,r)}function sc(e,t){return ce.unlinkSync(t),ce.symlinkSync(e,t)}xn.exports=Xa});var St=S((nl,Cn)=>{"use strict";var ac=K().fromPromise;Cn.exports={copy:ac(gn()),copySync:vn()}});var it=S((il,Nn)=>{"use strict";var bn=$e(),cc=K().fromCallback;function uc(e,t){bn.rm(e,{recursive:!0,force:!0},t)}function fc(e){bn.rmSync(e,{recursive:!0,force:!0})}Nn.exports={remove:cc(uc),removeSync:fc}});var An=S((ol,Tn)=>{"use strict";var lc=K().fromPromise,In=ae(),Ln=require("path"),Fn=we(),_n=it(),Dn=lc(async function(t){let r;try{r=await In.readdir(t)}catch{return Fn.mkdirs(t)}return Promise.all(r.map(n=>_n.remove(Ln.join(t,n))))});function On(e){let t;try{t=In.readdirSync(e)}catch{return Fn.mkdirsSync(e)}t.forEach(r=>{r=Ln.join(e,r),_n.removeSync(r)})}Tn.exports={emptyDirSync:On,emptydirSync:On,emptyDir:Dn,emptydir:Dn}});var qn=S((sl,Pn)=>{"use strict";var dc=K().fromPromise,kn=require("path"),De=ae(),Rn=we();async function mc(e){let t;try{t=await De.stat(e)}catch{}if(t&&t.isFile())return;let r=kn.dirname(e),n=null;try{n=await De.stat(r)}catch(o){if(o.code==="ENOENT"){await Rn.mkdirs(r),await De.writeFile(e,"");return}else throw o}n.isDirectory()?await De.writeFile(e,""):await De.readdir(r)}function hc(e){let t;try{t=De.statSync(e)}catch{}if(t&&t.isFile())return;let r=kn.dirname(e);try{De.statSync(r).isDirectory()||De.readdirSync(r)}catch(n){if(n&&n.code==="ENOENT")Rn.mkdirsSync(r);else throw n}De.writeFileSync(e,"")}Pn.exports={createFile:dc(mc),createFileSync:hc}});var Hn=S((al,Mn)=>{"use strict";var pc=K().fromPromise,Un=require("path"),Fe=ae(),Bn=we(),{pathExists:yc}=Le(),{areIdentical:$n}=Re();async function gc(e,t){let r;try{r=await Fe.lstat(t)}catch{}let n;try{n=await Fe.lstat(e)}catch(s){throw s.message=s.message.replace("lstat","ensureLink"),s}if(r&&$n(n,r))return;let o=Un.dirname(t);await yc(o)||await Bn.mkdirs(o),await Fe.link(e,t)}function wc(e,t){let r;try{r=Fe.lstatSync(t)}catch{}try{let i=Fe.lstatSync(e);if(r&&$n(i,r))return}catch(i){throw i.message=i.message.replace("lstat","ensureLink"),i}let n=Un.dirname(t);return Fe.existsSync(n)||Bn.mkdirsSync(n),Fe.linkSync(e,t)}Mn.exports={createLink:pc(gc),createLinkSync:wc}});var Vn=S((cl,Wn)=>{"use strict";var _e=require("path"),ot=ae(),{pathExists:Ec}=Le(),Sc=K().fromPromise;async function xc(e,t){if(_e.isAbsolute(e)){try{await ot.lstat(e)}catch(i){throw i.message=i.message.replace("lstat","ensureSymlink"),i}return{toCwd:e,toDst:e}}let r=_e.dirname(t),n=_e.join(r,e);if(await Ec(n))return{toCwd:n,toDst:e};try{await ot.lstat(e)}catch(i){throw i.message=i.message.replace("lstat","ensureSymlink"),i}return{toCwd:e,toDst:_e.relative(r,e)}}function vc(e,t){if(_e.isAbsolute(e)){if(!ot.existsSync(e))throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}let r=_e.dirname(t),n=_e.join(r,e);if(ot.existsSync(n))return{toCwd:n,toDst:e};if(!ot.existsSync(e))throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:_e.relative(r,e)}}Wn.exports={symlinkPaths:Sc(xc),symlinkPathsSync:vc}});var Zn=S((ul,zn)=>{"use strict";var Gn=ae(),Cc=K().fromPromise;async function bc(e,t){if(t)return t;let r;try{r=await Gn.lstat(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}function Nc(e,t){if(t)return t;let r;try{r=Gn.lstatSync(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}zn.exports={symlinkType:Cc(bc),symlinkTypeSync:Nc}});var Jn=S((fl,Kn)=>{"use strict";var Dc=K().fromPromise,jn=require("path"),Ce=ae(),{mkdirs:Oc,mkdirsSync:Ic}=we(),{symlinkPaths:Lc,symlinkPathsSync:Fc}=Vn(),{symlinkType:_c,symlinkTypeSync:Tc}=Zn(),{pathExists:Ac}=Le(),{areIdentical:Xn}=Re();async function kc(e,t,r){let n;try{n=await Ce.lstat(t)}catch{}if(n&&n.isSymbolicLink()){let[a,c]=await Promise.all([Ce.stat(e),Ce.stat(t)]);if(Xn(a,c))return}let o=await Lc(e,t);e=o.toDst;let i=await _c(o.toCwd,r),s=jn.dirname(t);return await Ac(s)||await Oc(s),Ce.symlink(e,t,i)}function Rc(e,t,r){let n;try{n=Ce.lstatSync(t)}catch{}if(n&&n.isSymbolicLink()){let a=Ce.statSync(e),c=Ce.statSync(t);if(Xn(a,c))return}let o=Fc(e,t);e=o.toDst,r=Tc(o.toCwd,r);let i=jn.dirname(t);return Ce.existsSync(i)||Ic(i),Ce.symlinkSync(e,t,r)}Kn.exports={createSymlink:Dc(kc),createSymlinkSync:Rc}});var oi=S((ll,ii)=>{"use strict";var{createFile:Yn,createFileSync:Qn}=qn(),{createLink:ei,createLinkSync:ti}=Hn(),{createSymlink:ri,createSymlinkSync:ni}=Jn();ii.exports={createFile:Yn,createFileSync:Qn,ensureFile:Yn,ensureFileSync:Qn,createLink:ei,createLinkSync:ti,ensureLink:ei,ensureLinkSync:ti,createSymlink:ri,createSymlinkSync:ni,ensureSymlink:ri,ensureSymlinkSync:ni}});var xt=S((dl,si)=>{function Pc(e,{EOL:t=`
7
- `,finalEOL:r=!0,replacer:n=null,spaces:o}={}){let i=r?t:"";return JSON.stringify(e,n,o).replace(/\n/g,t)+i}function qc(e){return Buffer.isBuffer(e)&&(e=e.toString("utf8")),e.replace(/^\uFEFF/,"")}si.exports={stringify:Pc,stripBom:qc}});var fi=S((ml,ui)=>{var We;try{We=$e()}catch{We=require("fs")}var vt=K(),{stringify:ai,stripBom:ci}=xt();async function Uc(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||We,n="throws"in t?t.throws:!0,o=await vt.fromCallback(r.readFile)(e,t);o=ci(o);let i;try{i=JSON.parse(o,t?t.reviver:null)}catch(s){if(n)throw s.message=`${e}: ${s.message}`,s;return null}return i}var Bc=vt.fromPromise(Uc);function $c(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||We,n="throws"in t?t.throws:!0;try{let o=r.readFileSync(e,t);return o=ci(o),JSON.parse(o,t.reviver)}catch(o){if(n)throw o.message=`${e}: ${o.message}`,o;return null}}async function Mc(e,t,r={}){let n=r.fs||We,o=ai(t,r);await vt.fromCallback(n.writeFile)(e,o,r)}var Hc=vt.fromPromise(Mc);function Wc(e,t,r={}){let n=r.fs||We,o=ai(t,r);return n.writeFileSync(e,o,r)}var Vc={readFile:Bc,readFileSync:$c,writeFile:Hc,writeFileSync:Wc};ui.exports=Vc});var di=S((hl,li)=>{"use strict";var Ct=fi();li.exports={readJson:Ct.readFile,readJsonSync:Ct.readFileSync,writeJson:Ct.writeFile,writeJsonSync:Ct.writeFileSync}});var bt=S((pl,pi)=>{"use strict";var Gc=K().fromPromise,Yt=ae(),mi=require("path"),hi=we(),zc=Le().pathExists;async function Zc(e,t,r="utf-8"){let n=mi.dirname(e);return await zc(n)||await hi.mkdirs(n),Yt.writeFile(e,t,r)}function jc(e,...t){let r=mi.dirname(e);Yt.existsSync(r)||hi.mkdirsSync(r),Yt.writeFileSync(e,...t)}pi.exports={outputFile:Gc(Zc),outputFileSync:jc}});var gi=S((yl,yi)=>{"use strict";var{stringify:Xc}=xt(),{outputFile:Kc}=bt();async function Jc(e,t,r={}){let n=Xc(t,r);await Kc(e,n,r)}yi.exports=Jc});var Ei=S((gl,wi)=>{"use strict";var{stringify:Yc}=xt(),{outputFileSync:Qc}=bt();function eu(e,t,r){let n=Yc(t,r);Qc(e,n,r)}wi.exports=eu});var xi=S((wl,Si)=>{"use strict";var tu=K().fromPromise,ue=di();ue.outputJson=tu(gi());ue.outputJsonSync=Ei();ue.outputJSON=ue.outputJson;ue.outputJSONSync=ue.outputJsonSync;ue.writeJSON=ue.writeJson;ue.writeJSONSync=ue.writeJsonSync;ue.readJSON=ue.readJson;ue.readJSONSync=ue.readJsonSync;Si.exports=ue});var Di=S((El,Ni)=>{"use strict";var ru=ae(),vi=require("path"),{copy:nu}=St(),{remove:bi}=it(),{mkdirp:iu}=we(),{pathExists:ou}=Le(),Ci=Re();async function su(e,t,r={}){let n=r.overwrite||r.clobber||!1,{srcStat:o,isChangingCase:i=!1}=await Ci.checkPaths(e,t,"move",r);await Ci.checkParentPaths(e,o,t,"move");let s=vi.dirname(t);return vi.parse(s).root!==s&&await iu(s),au(e,t,n,i)}async function au(e,t,r,n){if(!n){if(r)await bi(t);else if(await ou(t))throw new Error("dest already exists.")}try{await ru.rename(e,t)}catch(o){if(o.code!=="EXDEV")throw o;await cu(e,t,r)}}async function cu(e,t,r){return await nu(e,t,{overwrite:r,errorOnExist:!0,preserveTimestamps:!0}),bi(e)}Ni.exports=su});var _i=S((Sl,Fi)=>{"use strict";var Ii=$e(),er=require("path"),uu=St().copySync,Li=it().removeSync,fu=we().mkdirpSync,Oi=Re();function lu(e,t,r){r=r||{};let n=r.overwrite||r.clobber||!1,{srcStat:o,isChangingCase:i=!1}=Oi.checkPathsSync(e,t,"move",r);return Oi.checkParentPathsSync(e,o,t,"move"),du(t)||fu(er.dirname(t)),mu(e,t,n,i)}function du(e){let t=er.dirname(e);return er.parse(t).root===t}function mu(e,t,r,n){if(n)return Qt(e,t,r);if(r)return Li(t),Qt(e,t,r);if(Ii.existsSync(t))throw new Error("dest already exists.");return Qt(e,t,r)}function Qt(e,t,r){try{Ii.renameSync(e,t)}catch(n){if(n.code!=="EXDEV")throw n;return hu(e,t,r)}}function hu(e,t,r){return uu(e,t,{overwrite:r,errorOnExist:!0,preserveTimestamps:!0}),Li(e)}Fi.exports=lu});var Ai=S((xl,Ti)=>{"use strict";var pu=K().fromPromise;Ti.exports={move:pu(Di()),moveSync:_i()}});var Ri=S((vl,ki)=>{"use strict";ki.exports={...ae(),...St(),...An(),...oi(),...xi(),...we(),...Ai(),...bt(),...Le(),...it()}});var Vi=S((bl,ir)=>{var Hi=process.argv||[],It=process.env,Du=!("NO_COLOR"in It||Hi.includes("--no-color"))&&("FORCE_COLOR"in It||Hi.includes("--color")||process.platform==="win32"||require!=null&&require("tty").isatty(1)&&It.TERM!=="dumb"||"CI"in It),Ou=(e,t,r=e)=>n=>{let o=""+n,i=o.indexOf(t,e.length);return~i?e+Iu(o,t,r,i)+t:e+o+t},Iu=(e,t,r,n)=>{let o="",i=0;do o+=e.substring(i,n)+r,i=n+t.length,n=e.indexOf(t,i);while(~n);return o+e.substring(i)},Wi=(e=Du)=>{let t=e?Ou:()=>String;return{isColorSupported:e,reset:t("\x1B[0m","\x1B[0m"),bold:t("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:t("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:t("\x1B[3m","\x1B[23m"),underline:t("\x1B[4m","\x1B[24m"),inverse:t("\x1B[7m","\x1B[27m"),hidden:t("\x1B[8m","\x1B[28m"),strikethrough:t("\x1B[9m","\x1B[29m"),black:t("\x1B[30m","\x1B[39m"),red:t("\x1B[31m","\x1B[39m"),green:t("\x1B[32m","\x1B[39m"),yellow:t("\x1B[33m","\x1B[39m"),blue:t("\x1B[34m","\x1B[39m"),magenta:t("\x1B[35m","\x1B[39m"),cyan:t("\x1B[36m","\x1B[39m"),white:t("\x1B[37m","\x1B[39m"),gray:t("\x1B[90m","\x1B[39m"),bgBlack:t("\x1B[40m","\x1B[49m"),bgRed:t("\x1B[41m","\x1B[49m"),bgGreen:t("\x1B[42m","\x1B[49m"),bgYellow:t("\x1B[43m","\x1B[49m"),bgBlue:t("\x1B[44m","\x1B[49m"),bgMagenta:t("\x1B[45m","\x1B[49m"),bgCyan:t("\x1B[46m","\x1B[49m"),bgWhite:t("\x1B[47m","\x1B[49m")}};ir.exports=Wi();ir.exports.createColors=Wi});var Xi=S((Nl,ji)=>{ji.exports=Zi;Zi.sync=Fu;var Gi=require("fs");function Lu(e,t){var r=t.pathExt!==void 0?t.pathExt:process.env.PATHEXT;if(!r||(r=r.split(";"),r.indexOf("")!==-1))return!0;for(var n=0;n<r.length;n++){var o=r[n].toLowerCase();if(o&&e.substr(-o.length).toLowerCase()===o)return!0}return!1}function zi(e,t,r){return!e.isSymbolicLink()&&!e.isFile()?!1:Lu(t,r)}function Zi(e,t,r){Gi.stat(e,function(n,o){r(n,n?!1:zi(o,e,t))})}function Fu(e,t){return zi(Gi.statSync(e),e,t)}});var eo=S((Dl,Qi)=>{Qi.exports=Ji;Ji.sync=_u;var Ki=require("fs");function Ji(e,t,r){Ki.stat(e,function(n,o){r(n,n?!1:Yi(o,t))})}function _u(e,t){return Yi(Ki.statSync(e),t)}function Yi(e,t){return e.isFile()&&Tu(e,t)}function Tu(e,t){var r=e.mode,n=e.uid,o=e.gid,i=t.uid!==void 0?t.uid:process.getuid&&process.getuid(),s=t.gid!==void 0?t.gid:process.getgid&&process.getgid(),a=parseInt("100",8),c=parseInt("010",8),u=parseInt("001",8),l=a|c,d=r&u||r&c&&o===s||r&a&&n===i||r&l&&i===0;return d}});var ro=S((Il,to)=>{var Ol=require("fs"),Lt;process.platform==="win32"||global.TESTING_WINDOWS?Lt=Xi():Lt=eo();to.exports=or;or.sync=Au;function or(e,t,r){if(typeof t=="function"&&(r=t,t={}),!r){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(n,o){or(e,t||{},function(i,s){i?o(i):n(s)})})}Lt(e,t||{},function(n,o){n&&(n.code==="EACCES"||t&&t.ignoreErrors)&&(n=null,o=!1),r(n,o)})}function Au(e,t){try{return Lt.sync(e,t||{})}catch(r){if(t&&t.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var uo=S((Ll,co)=>{var Ve=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",no=require("path"),ku=Ve?";":":",io=ro(),oo=e=>Object.assign(new Error(`not found: ${e}`),{code:"ENOENT"}),so=(e,t)=>{let r=t.colon||ku,n=e.match(/\//)||Ve&&e.match(/\\/)?[""]:[...Ve?[process.cwd()]:[],...(t.path||process.env.PATH||"").split(r)],o=Ve?t.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",i=Ve?o.split(r):[""];return Ve&&e.indexOf(".")!==-1&&i[0]!==""&&i.unshift(""),{pathEnv:n,pathExt:i,pathExtExe:o}},ao=(e,t,r)=>{typeof t=="function"&&(r=t,t={}),t||(t={});let{pathEnv:n,pathExt:o,pathExtExe:i}=so(e,t),s=[],a=u=>new Promise((l,d)=>{if(u===n.length)return t.all&&s.length?l(s):d(oo(e));let h=n[u],p=/^".*"$/.test(h)?h.slice(1,-1):h,f=no.join(p,e),y=!p&&/^\.[\\\/]/.test(e)?e.slice(0,2)+f:f;l(c(y,u,0))}),c=(u,l,d)=>new Promise((h,p)=>{if(d===o.length)return h(a(l+1));let f=o[d];io(u+f,{pathExt:i},(y,w)=>{if(!y&&w)if(t.all)s.push(u+f);else return h(u+f);return h(c(u,l,d+1))})});return r?a(0).then(u=>r(null,u),r):a(0)},Ru=(e,t)=>{t=t||{};let{pathEnv:r,pathExt:n,pathExtExe:o}=so(e,t),i=[];for(let s=0;s<r.length;s++){let a=r[s],c=/^".*"$/.test(a)?a.slice(1,-1):a,u=no.join(c,e),l=!c&&/^\.[\\\/]/.test(e)?e.slice(0,2)+u:u;for(let d=0;d<n.length;d++){let h=l+n[d];try{if(io.sync(h,{pathExt:o}))if(t.all)i.push(h);else return h}catch{}}}if(t.all&&i.length)return i;if(t.nothrow)return null;throw oo(e)};co.exports=ao;ao.sync=Ru});var lo=S((Fl,sr)=>{"use strict";var fo=(e={})=>{let t=e.env||process.env;return(e.platform||process.platform)!=="win32"?"PATH":Object.keys(t).reverse().find(n=>n.toUpperCase()==="PATH")||"Path"};sr.exports=fo;sr.exports.default=fo});var yo=S((_l,po)=>{"use strict";var mo=require("path"),Pu=uo(),qu=lo();function ho(e,t){let r=e.options.env||process.env,n=process.cwd(),o=e.options.cwd!=null,i=o&&process.chdir!==void 0&&!process.chdir.disabled;if(i)try{process.chdir(e.options.cwd)}catch{}let s;try{s=Pu.sync(e.command,{path:r[qu({env:r})],pathExt:t?mo.delimiter:void 0})}catch{}finally{i&&process.chdir(n)}return s&&(s=mo.resolve(o?e.options.cwd:"",s)),s}function Uu(e){return ho(e)||ho(e,!0)}po.exports=Uu});var go=S((Tl,cr)=>{"use strict";var ar=/([()\][%!^"`<>&|;, *?])/g;function Bu(e){return e=e.replace(ar,"^$1"),e}function $u(e,t){return e=`${e}`,e=e.replace(/(\\*)"/g,'$1$1\\"'),e=e.replace(/(\\*)$/,"$1$1"),e=`"${e}"`,e=e.replace(ar,"^$1"),t&&(e=e.replace(ar,"^$1")),e}cr.exports.command=Bu;cr.exports.argument=$u});var Eo=S((Al,wo)=>{"use strict";wo.exports=/^#!(.*)/});var xo=S((kl,So)=>{"use strict";var Mu=Eo();So.exports=(e="")=>{let t=e.match(Mu);if(!t)return null;let[r,n]=t[0].replace(/#! ?/,"").split(" "),o=r.split("/").pop();return o==="env"?n:n?`${o} ${n}`:o}});var Co=S((Rl,vo)=>{"use strict";var ur=require("fs"),Hu=xo();function Wu(e){let r=Buffer.alloc(150),n;try{n=ur.openSync(e,"r"),ur.readSync(n,r,0,150,0),ur.closeSync(n)}catch{}return Hu(r.toString())}vo.exports=Wu});var Oo=S((Pl,Do)=>{"use strict";var Vu=require("path"),bo=yo(),No=go(),Gu=Co(),zu=process.platform==="win32",Zu=/\.(?:com|exe)$/i,ju=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function Xu(e){e.file=bo(e);let t=e.file&&Gu(e.file);return t?(e.args.unshift(e.file),e.command=t,bo(e)):e.file}function Ku(e){if(!zu)return e;let t=Xu(e),r=!Zu.test(t);if(e.options.forceShell||r){let n=ju.test(t);e.command=Vu.normalize(e.command),e.command=No.command(e.command),e.args=e.args.map(i=>No.argument(i,n));let o=[e.command].concat(e.args).join(" ");e.args=["/d","/s","/c",`"${o}"`],e.command=process.env.comspec||"cmd.exe",e.options.windowsVerbatimArguments=!0}return e}function Ju(e,t,r){t&&!Array.isArray(t)&&(r=t,t=null),t=t?t.slice(0):[],r=Object.assign({},r);let n={command:e,args:t,options:r,file:void 0,original:{command:e,args:t}};return r.shell?n:Ku(n)}Do.exports=Ju});var Fo=S((ql,Lo)=>{"use strict";var fr=process.platform==="win32";function lr(e,t){return Object.assign(new Error(`${t} ${e.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${t} ${e.command}`,path:e.command,spawnargs:e.args})}function Yu(e,t){if(!fr)return;let r=e.emit;e.emit=function(n,o){if(n==="exit"){let i=Io(o,t,"spawn");if(i)return r.call(e,"error",i)}return r.apply(e,arguments)}}function Io(e,t){return fr&&e===1&&!t.file?lr(t.original,"spawn"):null}function Qu(e,t){return fr&&e===1&&!t.file?lr(t.original,"spawnSync"):null}Lo.exports={hookChildProcess:Yu,verifyENOENT:Io,verifyENOENTSync:Qu,notFoundError:lr}});var Ao=S((Ul,Ge)=>{"use strict";var _o=require("child_process"),dr=Oo(),mr=Fo();function To(e,t,r){let n=dr(e,t,r),o=_o.spawn(n.command,n.args,n.options);return mr.hookChildProcess(o,n),o}function ef(e,t,r){let n=dr(e,t,r),o=_o.spawnSync(n.command,n.args,n.options);return o.error=o.error||mr.verifyENOENTSync(o.status,n),o}Ge.exports=To;Ge.exports.spawn=To;Ge.exports.sync=ef;Ge.exports._parse=dr;Ge.exports._enoent=mr});var ko=S((Bl,tf)=>{tf.exports=["|/-\\","\u2802-\u2013\u2014\u2013-","\u25D0\u25D3\u25D1\u25D2","\u25F4\u25F7\u25F6\u25F5","\u25F0\u25F3\u25F2\u25F1","\u2596\u2598\u259D\u2597","\u25A0\u25A1\u25AA\u25AB","\u258C\u2580\u2590\u2584","\u2589\u258A\u258B\u258C\u258D\u258E\u258F\u258E\u258D\u258C\u258B\u258A\u2589","\u2581\u2583\u2584\u2585\u2586\u2587\u2588\u2587\u2586\u2585\u2584\u2583","\u2190\u2196\u2191\u2197\u2192\u2198\u2193\u2199","\u2524\u2518\u2534\u2514\u251C\u250C\u252C\u2510","\u25E2\u25E3\u25E4\u25E5",".oO\xB0Oo.",".oO@*",["\u{1F30D}","\u{1F30E}","\u{1F30F}"],"\u25E1\u25E1 \u2299\u2299 \u25E0\u25E0","\u2631\u2632\u2634","\u280B\u2819\u2839\u2838\u283C\u2834\u2826\u2827\u2807\u280F","\u280B\u2819\u281A\u281E\u2816\u2826\u2834\u2832\u2833\u2813","\u2804\u2806\u2807\u280B\u2819\u2838\u2830\u2820\u2830\u2838\u2819\u280B\u2807\u2806","\u280B\u2819\u281A\u2812\u2802\u2802\u2812\u2832\u2834\u2826\u2816\u2812\u2810\u2810\u2812\u2813\u280B","\u2801\u2809\u2819\u281A\u2812\u2802\u2802\u2812\u2832\u2834\u2824\u2804\u2804\u2824\u2834\u2832\u2812\u2802\u2802\u2812\u281A\u2819\u2809\u2801","\u2808\u2809\u280B\u2813\u2812\u2810\u2810\u2812\u2816\u2826\u2824\u2820\u2820\u2824\u2826\u2816\u2812\u2810\u2810\u2812\u2813\u280B\u2809\u2808","\u2801\u2801\u2809\u2819\u281A\u2812\u2802\u2802\u2812\u2832\u2834\u2824\u2804\u2804\u2824\u2820\u2820\u2824\u2826\u2816\u2812\u2810\u2810\u2812\u2813\u280B\u2809\u2808\u2808","\u2884\u2882\u2881\u2841\u2848\u2850\u2860","\u28B9\u28BA\u28BC\u28F8\u28C7\u2867\u2857\u284F","\u28FE\u28FD\u28FB\u28BF\u287F\u28DF\u28EF\u28F7","\u2801\u2802\u2804\u2840\u2880\u2820\u2810\u2808",["\u{1F311}","\u{1F312}","\u{1F313}","\u{1F314}","\u{1F315}","\u{1F31D}","\u{1F316}","\u{1F317}","\u{1F318}","\u{1F31A}"],["\u{1F55B}","\u{1F550}","\u{1F551}","\u{1F552}","\u{1F553}","\u{1F554}","\u{1F555}","\u{1F556}","\u{1F557}","\u{1F558}","\u{1F559}","\u{1F55A}"]]});var Bo=S(Uo=>{var Ro=require("readline"),Po=0,qo=60;function rf(e){this.clearLine(this.stream),this.stream.write(e)}var fe=function(e){if(!(this instanceof fe))return new fe(e);typeof e=="string"?e={text:e}:e||(e={}),this.text=e.text||"",this.setSpinnerString(Po),this.setSpinnerDelay(qo),this.onTick=e.onTick||rf,this.stream=e.stream||process.stdout};fe.spinners=ko();fe.setDefaultSpinnerString=function(e){return Po=e,this};fe.setDefaultSpinnerDelay=function(e){return qo=e,this};fe.prototype.start=function(){if(this.stream===process.stdout&&this.stream.isTTY!==!0)return this;var e=0,t=this,r=function(){var n=t.text.indexOf("%s")>-1?t.text.replace("%s",t.chars[e]):t.chars[e]+" "+t.text;t.onTick(n),e=++e%t.chars.length};return r(),this.id=setInterval(r,this.delay),this};fe.prototype.isSpinning=function(){return this.id!==void 0};fe.prototype.setSpinnerDelay=function(e){return this.delay=e,this};fe.prototype.setSpinnerString=function(e){let t=of(e,this.spinners);return this.chars=Array.isArray(t)?t:t.split(""),this};fe.prototype.setSpinnerTitle=function(e){return this.text=e,this};fe.prototype.stop=function(e){return this.isSpinning===!1?this:(clearInterval(this.id),this.id=void 0,e&&this.clearLine(this.stream),this)};fe.prototype.clearLine=function(e){return Ro.clearLine(e,0),Ro.cursorTo(e,0),this};function nf(e){return typeof e=="number"&&e%1===0}function of(e,t){if(!nf(e))return e+"";var r=fe.spinners.length;return e=e>=r?0:e,e=e<0?r+e:e,fe.spinners[e]}Uo.Spinner=fe});function sf(){try{return pr.default.statSync("/.dockerenv"),!0}catch{return!1}}function af(){try{return pr.default.readFileSync("/proc/self/cgroup","utf8").includes("docker")}catch{return!1}}function yr(){return hr===void 0&&(hr=sf()||af()),hr}var pr,hr,$o=ve(()=>{pr=X(require("node:fs"),1)});function ze(){return gr===void 0&&(gr=cf()||yr()),gr}var Mo,gr,cf,wr=ve(()=>{Mo=X(require("node:fs"),1);$o();cf=()=>{try{return Mo.default.statSync("/run/.containerenv"),!0}catch{return!1}}});var Er,Wo,Vo,Ho,at,Go=ve(()=>{Er=X(require("node:process"),1),Wo=X(require("node:os"),1),Vo=X(require("node:fs"),1);wr();Ho=()=>{if(Er.default.platform!=="linux")return!1;if(Wo.default.release().toLowerCase().includes("microsoft"))return!ze();try{return Vo.default.readFileSync("/proc/version","utf8").toLowerCase().includes("microsoft")?!ze():!1}catch{return!1}},at=Er.default.env.__IS_WSL_TEST__?Ho:Ho()});function Pe(e,t,r){let n=o=>Object.defineProperty(e,t,{value:o,enumerable:!0,writable:!0});return Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get(){let o=r();return n(o),o},set(o){n(o)}}),e}var zo=ve(()=>{});async function Sr(){if(jo.default.platform!=="darwin")throw new Error("macOS only");let{stdout:e}=await uf("defaults",["read","com.apple.LaunchServices/com.apple.launchservices.secure","LSHandlers"]);return/LSHandlerRoleAll = "(?!-)(?<id>[^"]+?)";\s+?LSHandlerURLScheme = (?:http|https);/.exec(e)?.groups.id??"com.apple.Safari"}var Zo,jo,Xo,uf,Ko=ve(()=>{Zo=require("node:util"),jo=X(require("node:process"),1),Xo=require("node:child_process"),uf=(0,Zo.promisify)(Xo.execFile)});async function Qo(e,{humanReadableOutput:t=!0}={}){if(Jo.default.platform!=="darwin")throw new Error("macOS only");let r=t?[]:["-ss"],{stdout:n}=await ff("osascript",["-e",e,r]);return n.trim()}var Jo,Yo,xr,ff,es=ve(()=>{Jo=X(require("node:process"),1),Yo=require("node:util"),xr=require("node:child_process"),ff=(0,Yo.promisify)(xr.execFile)});async function vr(e){return Qo(`tell application "Finder" to set app_path to application file id "${e}" as string
8
- tell application "System Events" to get value of property list item "CFBundleName" of property list file (app_path & ":Contents:Info.plist")`)}var ts=ve(()=>{es()});async function Cr(e=lf){let{stdout:t}=await e("reg",["QUERY"," HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\Shell\\Associations\\UrlAssociations\\http\\UserChoice","/v","ProgId"]),r=/ProgId\s*REG_SZ\s*(?<id>\S+)/.exec(t);if(!r)throw new Ft(`Cannot find Windows browser in stdout: ${JSON.stringify(t)}`);let{id:n}=r.groups,o=df[n];if(!o)throw new Ft(`Unknown browser ID: ${n}`);return o}var rs,ns,lf,df,Ft,is=ve(()=>{rs=require("node:util"),ns=require("node:child_process"),lf=(0,rs.promisify)(ns.execFile),df={AppXq0fevzme2pys62n3e0fbqa7peapykr8v:{name:"Edge",id:"com.microsoft.edge.old"},MSEdgeDHTML:{name:"Edge",id:"com.microsoft.edge"},MSEdgeHTM:{name:"Edge",id:"com.microsoft.edge"},"IE.HTTP":{name:"Internet Explorer",id:"com.microsoft.ie"},FirefoxURL:{name:"Firefox",id:"org.mozilla.firefox"},ChromeHTML:{name:"Chrome",id:"com.google.chrome"},BraveHTML:{name:"Brave",id:"com.brave.Browser"},BraveBHTML:{name:"Brave Beta",id:"com.brave.Browser.beta"},BraveSSHTM:{name:"Brave Nightly",id:"com.brave.Browser.nightly"}},Ft=class extends Error{}});async function br(){if(_t.default.platform==="darwin"){let e=await Sr();return{name:await vr(e),id:e}}if(_t.default.platform==="linux"){let{stdout:e}=await mf("xdg-mime",["query","default","x-scheme-handler/http"]),t=e.trim();return{name:hf(t.replace(/.desktop$/,"").replace("-"," ")),id:t}}if(_t.default.platform==="win32")return Cr();throw new Error("Only macOS, Linux, and Windows are supported")}var os,_t,ss,mf,hf,as=ve(()=>{os=require("node:util"),_t=X(require("node:process"),1),ss=require("node:child_process");Ko();ts();is();mf=(0,os.promisify)(ss.execFile),hf=e=>e.toLowerCase().replaceAll(/(?:^|\s|-)\S/g,t=>t.toUpperCase())});var ps={};ma(ps,{apps:()=>Ue,default:()=>wf,openApp:()=>gf});function ls(e){if(typeof e=="string"||Array.isArray(e))return e;let{[us]:t}=e;if(!t)throw new Error(`${us} is not supported`);return t}function Or({[Ze]:e},{wsl:t}){if(t&&at)return ls(t);if(!e)throw new Error(`${Ze} is not supported`);return ls(e)}var ct,ds,Dr,ms,hs,qe,Ef,Nr,cs,Ze,us,pf,fs,ut,yf,gf,Ue,wf,ys=ve(()=>{ct=X(require("node:process"),1),ds=require("node:buffer"),Dr=X(require("node:path"),1),ms=require("node:url"),hs=X(require("node:child_process"),1),qe=X(require("node:fs/promises"),1);Go();zo();as();wr();Ef={},Nr=Dr.default.dirname((0,ms.fileURLToPath)(Ef.url)),cs=Dr.default.join(Nr,"xdg-open"),{platform:Ze,arch:us}=ct.default,pf=(()=>{let e="/mnt/",t;return async function(){if(t)return t;let r="/etc/wsl.conf",n=!1;try{await qe.default.access(r,qe.constants.F_OK),n=!0}catch{}if(!n)return e;let o=await qe.default.readFile(r,{encoding:"utf8"}),i=/(?<!#.*)root\s*=\s*(?<mountPoint>.*)/g.exec(o);return i?(t=i.groups.mountPoint.trim(),t=t.endsWith("/")?t:`${t}/`,t):e}})(),fs=async(e,t)=>{let r;for(let n of e)try{return await t(n)}catch(o){r=o}throw r},ut=async e=>{if(e={wait:!1,background:!1,newInstance:!1,allowNonzeroExitCode:!1,...e},Array.isArray(e.app))return fs(e.app,a=>ut({...e,app:a}));let{name:t,arguments:r=[]}=e.app??{};if(r=[...r],Array.isArray(t))return fs(t,a=>ut({...e,app:{name:a,arguments:r}}));if(t==="browser"||t==="browserPrivate"){let a={"com.google.chrome":"chrome","google-chrome.desktop":"chrome","org.mozilla.firefox":"firefox","firefox.desktop":"firefox","com.microsoft.msedge":"edge","com.microsoft.edge":"edge","microsoft-edge.desktop":"edge"},c={chrome:"--incognito",firefox:"--private-window",edge:"--inPrivate"},u=await br();if(u.id in a){let l=a[u.id];return t==="browserPrivate"&&r.push(c[l]),ut({...e,app:{name:Ue[l],arguments:r}})}throw new Error(`${u.name} is not supported as a default browser`)}let n,o=[],i={};if(Ze==="darwin")n="open",e.wait&&o.push("--wait-apps"),e.background&&o.push("--background"),e.newInstance&&o.push("--new"),t&&o.push("-a",t);else if(Ze==="win32"||at&&!ze()&&!t){let a=await pf();n=at?`${a}c/Windows/System32/WindowsPowerShell/v1.0/powershell.exe`:`${ct.default.env.SYSTEMROOT||ct.default.env.windir||"C:\\Windows"}\\System32\\WindowsPowerShell\\v1.0\\powershell`,o.push("-NoProfile","-NonInteractive","-ExecutionPolicy","Bypass","-EncodedCommand"),at||(i.windowsVerbatimArguments=!0);let c=["Start"];e.wait&&c.push("-Wait"),t?(c.push(`"\`"${t}\`""`),e.target&&r.push(e.target)):e.target&&c.push(`"${e.target}"`),r.length>0&&(r=r.map(u=>`"\`"${u}\`""`),c.push("-ArgumentList",r.join(","))),e.target=ds.Buffer.from(c.join(" "),"utf16le").toString("base64")}else{if(t)n=t;else{let a=!Nr||Nr==="/",c=!1;try{await qe.default.access(cs,qe.constants.X_OK),c=!0}catch{}n=ct.default.versions.electron??(Ze==="android"||a||!c)?"xdg-open":cs}r.length>0&&o.push(...r),e.wait||(i.stdio="ignore",i.detached=!0)}Ze==="darwin"&&r.length>0&&o.push("--args",...r),e.target&&o.push(e.target);let s=hs.default.spawn(n,o,i);return e.wait?new Promise((a,c)=>{s.once("error",c),s.once("close",u=>{if(!e.allowNonzeroExitCode&&u>0){c(new Error(`Exited with code ${u}`));return}a(s)})}):(s.unref(),s)},yf=(e,t)=>{if(typeof e!="string")throw new TypeError("Expected a `target`");return ut({...t,target:e})},gf=(e,t)=>{if(typeof e!="string"&&!Array.isArray(e))throw new TypeError("Expected a valid `name`");let{arguments:r=[]}=t??{};if(r!=null&&!Array.isArray(r))throw new TypeError("Expected `appArguments` as Array type");return ut({...t,app:{name:e,arguments:r}})};Ue={};Pe(Ue,"chrome",()=>Or({darwin:"google chrome",win32:"chrome",linux:["google-chrome","google-chrome-stable","chromium"]},{wsl:{ia32:"/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe",x64:["/mnt/c/Program Files/Google/Chrome/Application/chrome.exe","/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe"]}}));Pe(Ue,"firefox",()=>Or({darwin:"firefox",win32:"C:\\Program Files\\Mozilla Firefox\\firefox.exe",linux:"firefox"},{wsl:"/mnt/c/Program Files/Mozilla Firefox/firefox.exe"}));Pe(Ue,"edge",()=>Or({darwin:"microsoft edge",win32:"msedge",linux:["microsoft-edge","microsoft-edge-dev"]},{wsl:"/mnt/c/Program Files (x86)/Microsoft/Edge/Application/msedge.exe"}));Pe(Ue,"browser",()=>"browser");Pe(Ue,"browserPrivate",()=>"browserPrivate");wf=yf});var Tt=S(gs=>{gs.require=function(){var e=require("fs");if(process.versions.electron)try{e=require("original-fs")}catch{}return e}});var Ir=S((ad,ws)=>{ws.exports={LOCHDR:30,LOCSIG:67324752,LOCVER:4,LOCFLG:6,LOCHOW:8,LOCTIM:10,LOCCRC:14,LOCSIZ:18,LOCLEN:22,LOCNAM:26,LOCEXT:28,EXTSIG:134695760,EXTHDR:16,EXTCRC:4,EXTSIZ:8,EXTLEN:12,CENHDR:46,CENSIG:33639248,CENVEM:4,CENVER:6,CENFLG:8,CENHOW:10,CENTIM:12,CENCRC:16,CENSIZ:20,CENLEN:24,CENNAM:28,CENEXT:30,CENCOM:32,CENDSK:34,CENATT:36,CENATX:38,CENOFF:42,ENDHDR:22,ENDSIG:101010256,ENDSUB:8,ENDTOT:10,ENDSIZ:12,ENDOFF:16,ENDCOM:20,STORED:0,SHRUNK:1,REDUCED1:2,REDUCED2:3,REDUCED3:4,REDUCED4:5,IMPLODED:6,DEFLATED:8,ENHANCED_DEFLATED:9,PKWARE:10,BZIP2:12,LZMA:14,IBM_TERSE:18,IBM_LZ77:19,FLG_ENC:0,FLG_COMP1:1,FLG_COMP2:2,FLG_DESC:4,FLG_ENH:8,FLG_STR:16,FLG_LNG:1024,FLG_MSK:4096,FILE:0,BUFFER:1,NONE:2,EF_ID:0,EF_SIZE:2,ID_ZIP64:1,ID_AVINFO:7,ID_PFS:8,ID_OS2:9,ID_NTFS:10,ID_OPENVMS:12,ID_UNIX:13,ID_FORK:14,ID_PATCH:15,ID_X509_PKCS7:20,ID_X509_CERTID_F:21,ID_X509_CERTID_C:22,ID_STRONGENC:23,ID_RECORD_MGT:24,ID_X509_PKCS7_RL:25,ID_IBM1:101,ID_IBM2:102,ID_POSZIP:18064,EF_ZIP64_OR_32:4294967295,EF_ZIP64_OR_16:65535,EF_ZIP64_SUNCOMP:0,EF_ZIP64_SCOMP:8,EF_ZIP64_RHO:16,EF_ZIP64_DSN:24}});var Lr=S((cd,Es)=>{Es.exports={INVALID_LOC:"Invalid LOC header (bad signature)",INVALID_CEN:"Invalid CEN header (bad signature)",INVALID_END:"Invalid END header (bad signature)",NO_DATA:"Nothing to decompress",BAD_CRC:"CRC32 checksum failed",FILE_IN_THE_WAY:"There is a file in the way: %s",UNKNOWN_METHOD:"Invalid/unsupported compression method",AVAIL_DATA:"inflate::Available inflate data did not terminate",INVALID_DISTANCE:"inflate::Invalid literal/length or distance code in fixed or dynamic block",TO_MANY_CODES:"inflate::Dynamic block code description: too many length or distance codes",INVALID_REPEAT_LEN:"inflate::Dynamic block code description: repeat more than specified lengths",INVALID_REPEAT_FIRST:"inflate::Dynamic block code description: repeat lengths with no first length",INCOMPLETE_CODES:"inflate::Dynamic block code description: code lengths codes incomplete",INVALID_DYN_DISTANCE:"inflate::Dynamic block code description: invalid distance code lengths",INVALID_CODES_LEN:"inflate::Dynamic block code description: invalid literal/length code lengths",INVALID_STORE_BLOCK:"inflate::Stored block length did not match one's complement",INVALID_BLOCK_TYPE:"inflate::Invalid block type (type == 3)",CANT_EXTRACT_FILE:"Could not extract the file",CANT_OVERRIDE:"Target file already exists",NO_ZIP:"No zip file was loaded",NO_ENTRY:"Entry doesn't exist",DIRECTORY_CONTENT_ERROR:"A directory cannot have content",FILE_NOT_FOUND:"File not found: %s",NOT_IMPLEMENTED:"Not implemented",INVALID_FILENAME:"Invalid filename",INVALID_FORMAT:"Invalid or unsupported zip format. No END header found"}});var xs=S((ud,Ss)=>{var P=Tt().require(),je=require("path");P.existsSync=P.existsSync||je.existsSync;Ss.exports=function(){var e=[],t=Ir(),r=Lr(),n=je.sep;function o(s){var a=s.split(n)[0];s.split(n).forEach(function(c){if(!(!c||c.substr(-1,1)===":")){a+=n+c;var u;try{u=P.statSync(a)}catch{P.mkdirSync(a)}if(u&&u.isFile())throw r.FILE_IN_THE_WAY.replace("%s",a)}})}function i(s,a,c){typeof a=="boolean"&&(c=a,a=void 0);var u=[];return P.readdirSync(s).forEach(function(l){var d=je.join(s,l);P.statSync(d).isDirectory()&&c&&(u=u.concat(i(d,a,c))),(!a||a.test(d))&&u.push(je.normalize(d)+(P.statSync(d).isDirectory()?n:""))}),u}return{makeDir:function(s){o(s)},crc32:function(s){typeof s=="string"&&(s=Buffer.alloc(s.length,s));var a=Buffer.alloc(4);if(!e.length)for(var c=0;c<256;c++){for(var u=c,l=8;--l>=0;)u&1?u=3988292384^u>>>1:u=u>>>1;u<0&&(a.writeInt32LE(u,0),u=a.readUInt32LE(0)),e[c]=u}for(var d=0,h=0,p=s.length,f=~d;--p>=0;)f=e[(f^s[h++])&255]^f>>>8;return d=~f,a.writeInt32LE(d&4294967295,0),a.readUInt32LE(0)},methodToString:function(s){switch(s){case t.STORED:return"STORED ("+s+")";case t.DEFLATED:return"DEFLATED ("+s+")";default:return"UNSUPPORTED ("+s+")"}},writeFileTo:function(s,a,c,u){if(P.existsSync(s)){if(!c)return!1;var l=P.statSync(s);if(l.isDirectory())return!1}var d=je.dirname(s);P.existsSync(d)||o(d);var h;try{h=P.openSync(s,"w",438)}catch{P.chmodSync(s,438),h=P.openSync(s,"w",438)}if(h)try{P.writeSync(h,a,0,a.length,0)}catch(p){throw p}finally{P.closeSync(h)}return P.chmodSync(s,u||438),!0},writeFileToAsync:function(s,a,c,u,l){typeof u=="function"&&(l=u,u=void 0),P.exists(s,function(d){if(d&&!c)return l(!1);P.stat(s,function(h,p){if(d&&p.isDirectory())return l(!1);var f=je.dirname(s);P.exists(f,function(y){y||o(f),P.open(s,"w",438,function(w,m){w?P.chmod(s,438,function(){P.open(s,"w",438,function(E,L){P.write(L,a,0,a.length,0,function(){P.close(L,function(){P.chmod(s,u||438,function(){l(!0)})})})})}):m?P.write(m,a,0,a.length,0,function(){P.close(m,function(){P.chmod(s,u||438,function(){l(!0)})})}):P.chmod(s,u||438,function(){l(!0)})})})})})},findFiles:function(s){return i(s,!0)},getAttributes:function(s){},setAttributes:function(s){},toBuffer:function(s){return Buffer.isBuffer(s)?s:s.length===0?Buffer.alloc(0):Buffer.alloc(s.length,s,"utf8")},Constants:t,Errors:r}}()});var bs=S((fd,Cs)=>{var At=Tt().require(),vs=require("path");At.existsSync=At.existsSync||vs.existsSync;Cs.exports=function(e){var t=e||"",r=0,n=i(),o=null;function i(){return{directory:!1,readonly:!1,hidden:!1,executable:!1,mtime:0,atime:0}}return t&&At.existsSync(t)?(o=At.statSync(t),n.directory=o.isDirectory(),n.mtime=o.mtime,n.atime=o.atime,n.executable=!!(1&parseInt((o.mode&parseInt("777",8)).toString(8)[0])),n.readonly=!!(2&parseInt((o.mode&parseInt("777",8)).toString(8)[0])),n.hidden=vs.basename(t)[0]==="."):console.warn("Invalid path: "+t),{get directory(){return n.directory},get readOnly(){return n.readonly},get hidden(){return n.hidden},get mtime(){return n.mtime},get atime(){return n.atime},get executable(){return n.executable},decodeAttributes:function(s){},encodeAttributes:function(s){},toString:function(){return`{
6
+ see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0002");let{srcStat:n,destStat:o}=nt.checkPathsSync(e,t,"copy",r);if(nt.checkParentPathsSync(e,n,t,"copy"),r.filter&&!r.filter(e,t))return;let i=rt.dirname(t);return ce.existsSync(i)||Ga(i),yn(o,e,t,r)}function yn(e,t,r,n){let i=(n.dereference?ce.statSync:ce.lstatSync)(t);if(i.isDirectory())return ec(i,e,t,r,n);if(i.isFile()||i.isCharacterDevice()||i.isBlockDevice())return ja(i,e,t,r,n);if(i.isSymbolicLink())return nc(e,t,r,n);throw i.isSocket()?new Error(`Cannot copy a socket file: ${t}`):i.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}function ja(e,t,r,n,o){return t?Xa(e,r,n,o):gn(e,r,n,o)}function Xa(e,t,r,n){if(n.overwrite)return ce.unlinkSync(r),gn(e,t,r,n);if(n.errorOnExist)throw new Error(`'${r}' already exists`)}function gn(e,t,r,n){return ce.copyFileSync(t,r),n.preserveTimestamps&&Ka(e.mode,t,r),Jt(r,e.mode)}function Ka(e,t,r){return Ja(e)&&Ya(r,e),Qa(t,r)}function Ja(e){return(e&128)===0}function Ya(e,t){return Jt(e,t|128)}function Jt(e,t){return ce.chmodSync(e,t)}function Qa(e,t){let r=ce.statSync(e);return za(t,r.atime,r.mtime)}function ec(e,t,r,n,o){return t?wn(r,n,o):tc(e.mode,r,n,o)}function tc(e,t,r,n){return ce.mkdirSync(r),wn(t,r,n),Jt(r,e)}function wn(e,t,r){ce.readdirSync(e).forEach(n=>rc(n,e,t,r))}function rc(e,t,r,n){let o=rt.join(t,e),i=rt.join(r,e);if(n.filter&&!n.filter(o,i))return;let{destStat:s}=nt.checkPathsSync(o,i,"copy",n);return yn(s,o,i,n)}function nc(e,t,r,n){let o=ce.readlinkSync(t);if(n.dereference&&(o=rt.resolve(process.cwd(),o)),e){let i;try{i=ce.readlinkSync(r)}catch(s){if(s.code==="EINVAL"||s.code==="UNKNOWN")return ce.symlinkSync(o,r);throw s}if(n.dereference&&(i=rt.resolve(process.cwd(),i)),nt.isSrcSubdir(o,i))throw new Error(`Cannot copy '${o}' to a subdirectory of itself, '${i}'.`);if(nt.isSrcSubdir(i,o))throw new Error(`Cannot overwrite '${i}' with '${o}'.`);return ic(o,r)}else return ce.symlinkSync(o,r)}function ic(e,t){return ce.unlinkSync(t),ce.symlinkSync(e,t)}En.exports=Za});var St=S((el,xn)=>{"use strict";var oc=K().fromPromise;xn.exports={copy:oc(pn()),copySync:Sn()}});var it=S((tl,Cn)=>{"use strict";var vn=$e(),sc=K().fromCallback;function ac(e,t){vn.rm(e,{recursive:!0,force:!0},t)}function cc(e){vn.rmSync(e,{recursive:!0,force:!0})}Cn.exports={remove:sc(ac),removeSync:cc}});var _n=S((rl,Fn)=>{"use strict";var uc=K().fromPromise,Dn=ae(),On=require("path"),In=we(),Ln=it(),bn=uc(async function(t){let r;try{r=await Dn.readdir(t)}catch{return In.mkdirs(t)}return Promise.all(r.map(n=>Ln.remove(On.join(t,n))))});function Nn(e){let t;try{t=Dn.readdirSync(e)}catch{return In.mkdirsSync(e)}t.forEach(r=>{r=On.join(e,r),Ln.removeSync(r)})}Fn.exports={emptyDirSync:Nn,emptydirSync:Nn,emptyDir:bn,emptydir:bn}});var Rn=S((nl,kn)=>{"use strict";var fc=K().fromPromise,Tn=require("path"),De=ae(),An=we();async function lc(e){let t;try{t=await De.stat(e)}catch{}if(t&&t.isFile())return;let r=Tn.dirname(e),n=null;try{n=await De.stat(r)}catch(o){if(o.code==="ENOENT"){await An.mkdirs(r),await De.writeFile(e,"");return}else throw o}n.isDirectory()?await De.writeFile(e,""):await De.readdir(r)}function dc(e){let t;try{t=De.statSync(e)}catch{}if(t&&t.isFile())return;let r=Tn.dirname(e);try{De.statSync(r).isDirectory()||De.readdirSync(r)}catch(n){if(n&&n.code==="ENOENT")An.mkdirsSync(r);else throw n}De.writeFileSync(e,"")}kn.exports={createFile:fc(lc),createFileSync:dc}});var $n=S((il,Bn)=>{"use strict";var mc=K().fromPromise,Pn=require("path"),Fe=ae(),qn=we(),{pathExists:hc}=Le(),{areIdentical:Un}=Re();async function pc(e,t){let r;try{r=await Fe.lstat(t)}catch{}let n;try{n=await Fe.lstat(e)}catch(s){throw s.message=s.message.replace("lstat","ensureLink"),s}if(r&&Un(n,r))return;let o=Pn.dirname(t);await hc(o)||await qn.mkdirs(o),await Fe.link(e,t)}function yc(e,t){let r;try{r=Fe.lstatSync(t)}catch{}try{let i=Fe.lstatSync(e);if(r&&Un(i,r))return}catch(i){throw i.message=i.message.replace("lstat","ensureLink"),i}let n=Pn.dirname(t);return Fe.existsSync(n)||qn.mkdirsSync(n),Fe.linkSync(e,t)}Bn.exports={createLink:mc(pc),createLinkSync:yc}});var Hn=S((ol,Mn)=>{"use strict";var _e=require("path"),ot=ae(),{pathExists:gc}=Le(),wc=K().fromPromise;async function Ec(e,t){if(_e.isAbsolute(e)){try{await ot.lstat(e)}catch(i){throw i.message=i.message.replace("lstat","ensureSymlink"),i}return{toCwd:e,toDst:e}}let r=_e.dirname(t),n=_e.join(r,e);if(await gc(n))return{toCwd:n,toDst:e};try{await ot.lstat(e)}catch(i){throw i.message=i.message.replace("lstat","ensureSymlink"),i}return{toCwd:e,toDst:_e.relative(r,e)}}function Sc(e,t){if(_e.isAbsolute(e)){if(!ot.existsSync(e))throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}let r=_e.dirname(t),n=_e.join(r,e);if(ot.existsSync(n))return{toCwd:n,toDst:e};if(!ot.existsSync(e))throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:_e.relative(r,e)}}Mn.exports={symlinkPaths:wc(Ec),symlinkPathsSync:Sc}});var Gn=S((sl,Vn)=>{"use strict";var Wn=ae(),xc=K().fromPromise;async function vc(e,t){if(t)return t;let r;try{r=await Wn.lstat(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}function Cc(e,t){if(t)return t;let r;try{r=Wn.lstatSync(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}Vn.exports={symlinkType:xc(vc),symlinkTypeSync:Cc}});var Xn=S((al,jn)=>{"use strict";var bc=K().fromPromise,zn=require("path"),Ce=ae(),{mkdirs:Nc,mkdirsSync:Dc}=we(),{symlinkPaths:Oc,symlinkPathsSync:Ic}=Hn(),{symlinkType:Lc,symlinkTypeSync:Fc}=Gn(),{pathExists:_c}=Le(),{areIdentical:Zn}=Re();async function Tc(e,t,r){let n;try{n=await Ce.lstat(t)}catch{}if(n&&n.isSymbolicLink()){let[a,c]=await Promise.all([Ce.stat(e),Ce.stat(t)]);if(Zn(a,c))return}let o=await Oc(e,t);e=o.toDst;let i=await Lc(o.toCwd,r),s=zn.dirname(t);return await _c(s)||await Nc(s),Ce.symlink(e,t,i)}function Ac(e,t,r){let n;try{n=Ce.lstatSync(t)}catch{}if(n&&n.isSymbolicLink()){let a=Ce.statSync(e),c=Ce.statSync(t);if(Zn(a,c))return}let o=Ic(e,t);e=o.toDst,r=Fc(o.toCwd,r);let i=zn.dirname(t);return Ce.existsSync(i)||Dc(i),Ce.symlinkSync(e,t,r)}jn.exports={createSymlink:bc(Tc),createSymlinkSync:Ac}});var ni=S((cl,ri)=>{"use strict";var{createFile:Kn,createFileSync:Jn}=Rn(),{createLink:Yn,createLinkSync:Qn}=$n(),{createSymlink:ei,createSymlinkSync:ti}=Xn();ri.exports={createFile:Kn,createFileSync:Jn,ensureFile:Kn,ensureFileSync:Jn,createLink:Yn,createLinkSync:Qn,ensureLink:Yn,ensureLinkSync:Qn,createSymlink:ei,createSymlinkSync:ti,ensureSymlink:ei,ensureSymlinkSync:ti}});var xt=S((ul,ii)=>{function kc(e,{EOL:t=`
7
+ `,finalEOL:r=!0,replacer:n=null,spaces:o}={}){let i=r?t:"";return JSON.stringify(e,n,o).replace(/\n/g,t)+i}function Rc(e){return Buffer.isBuffer(e)&&(e=e.toString("utf8")),e.replace(/^\uFEFF/,"")}ii.exports={stringify:kc,stripBom:Rc}});var ci=S((fl,ai)=>{var We;try{We=$e()}catch{We=require("fs")}var vt=K(),{stringify:oi,stripBom:si}=xt();async function Pc(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||We,n="throws"in t?t.throws:!0,o=await vt.fromCallback(r.readFile)(e,t);o=si(o);let i;try{i=JSON.parse(o,t?t.reviver:null)}catch(s){if(n)throw s.message=`${e}: ${s.message}`,s;return null}return i}var qc=vt.fromPromise(Pc);function Uc(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||We,n="throws"in t?t.throws:!0;try{let o=r.readFileSync(e,t);return o=si(o),JSON.parse(o,t.reviver)}catch(o){if(n)throw o.message=`${e}: ${o.message}`,o;return null}}async function Bc(e,t,r={}){let n=r.fs||We,o=oi(t,r);await vt.fromCallback(n.writeFile)(e,o,r)}var $c=vt.fromPromise(Bc);function Mc(e,t,r={}){let n=r.fs||We,o=oi(t,r);return n.writeFileSync(e,o,r)}var Hc={readFile:qc,readFileSync:Uc,writeFile:$c,writeFileSync:Mc};ai.exports=Hc});var fi=S((ll,ui)=>{"use strict";var Ct=ci();ui.exports={readJson:Ct.readFile,readJsonSync:Ct.readFileSync,writeJson:Ct.writeFile,writeJsonSync:Ct.writeFileSync}});var bt=S((dl,mi)=>{"use strict";var Wc=K().fromPromise,Yt=ae(),li=require("path"),di=we(),Vc=Le().pathExists;async function Gc(e,t,r="utf-8"){let n=li.dirname(e);return await Vc(n)||await di.mkdirs(n),Yt.writeFile(e,t,r)}function zc(e,...t){let r=li.dirname(e);Yt.existsSync(r)||di.mkdirsSync(r),Yt.writeFileSync(e,...t)}mi.exports={outputFile:Wc(Gc),outputFileSync:zc}});var pi=S((ml,hi)=>{"use strict";var{stringify:Zc}=xt(),{outputFile:jc}=bt();async function Xc(e,t,r={}){let n=Zc(t,r);await jc(e,n,r)}hi.exports=Xc});var gi=S((hl,yi)=>{"use strict";var{stringify:Kc}=xt(),{outputFileSync:Jc}=bt();function Yc(e,t,r){let n=Kc(t,r);Jc(e,n,r)}yi.exports=Yc});var Ei=S((pl,wi)=>{"use strict";var Qc=K().fromPromise,ue=fi();ue.outputJson=Qc(pi());ue.outputJsonSync=gi();ue.outputJSON=ue.outputJson;ue.outputJSONSync=ue.outputJsonSync;ue.writeJSON=ue.writeJson;ue.writeJSONSync=ue.writeJsonSync;ue.readJSON=ue.readJson;ue.readJSONSync=ue.readJsonSync;wi.exports=ue});var bi=S((yl,Ci)=>{"use strict";var eu=ae(),Si=require("path"),{copy:tu}=St(),{remove:vi}=it(),{mkdirp:ru}=we(),{pathExists:nu}=Le(),xi=Re();async function iu(e,t,r={}){let n=r.overwrite||r.clobber||!1,{srcStat:o,isChangingCase:i=!1}=await xi.checkPaths(e,t,"move",r);await xi.checkParentPaths(e,o,t,"move");let s=Si.dirname(t);return Si.parse(s).root!==s&&await ru(s),ou(e,t,n,i)}async function ou(e,t,r,n){if(!n){if(r)await vi(t);else if(await nu(t))throw new Error("dest already exists.")}try{await eu.rename(e,t)}catch(o){if(o.code!=="EXDEV")throw o;await su(e,t,r)}}async function su(e,t,r){return await tu(e,t,{overwrite:r,errorOnExist:!0,preserveTimestamps:!0}),vi(e)}Ci.exports=iu});var Li=S((gl,Ii)=>{"use strict";var Di=$e(),er=require("path"),au=St().copySync,Oi=it().removeSync,cu=we().mkdirpSync,Ni=Re();function uu(e,t,r){r=r||{};let n=r.overwrite||r.clobber||!1,{srcStat:o,isChangingCase:i=!1}=Ni.checkPathsSync(e,t,"move",r);return Ni.checkParentPathsSync(e,o,t,"move"),fu(t)||cu(er.dirname(t)),lu(e,t,n,i)}function fu(e){let t=er.dirname(e);return er.parse(t).root===t}function lu(e,t,r,n){if(n)return Qt(e,t,r);if(r)return Oi(t),Qt(e,t,r);if(Di.existsSync(t))throw new Error("dest already exists.");return Qt(e,t,r)}function Qt(e,t,r){try{Di.renameSync(e,t)}catch(n){if(n.code!=="EXDEV")throw n;return du(e,t,r)}}function du(e,t,r){return au(e,t,{overwrite:r,errorOnExist:!0,preserveTimestamps:!0}),Oi(e)}Ii.exports=uu});var _i=S((wl,Fi)=>{"use strict";var mu=K().fromPromise;Fi.exports={move:mu(bi()),moveSync:Li()}});var Ai=S((El,Ti)=>{"use strict";Ti.exports={...ae(),...St(),..._n(),...ni(),...Ei(),...we(),..._i(),...bt(),...Le(),...it()}});var Hi=S((xl,ir)=>{var $i=process.argv||[],It=process.env,bu=!("NO_COLOR"in It||$i.includes("--no-color"))&&("FORCE_COLOR"in It||$i.includes("--color")||process.platform==="win32"||require!=null&&require("tty").isatty(1)&&It.TERM!=="dumb"||"CI"in It),Nu=(e,t,r=e)=>n=>{let o=""+n,i=o.indexOf(t,e.length);return~i?e+Du(o,t,r,i)+t:e+o+t},Du=(e,t,r,n)=>{let o="",i=0;do o+=e.substring(i,n)+r,i=n+t.length,n=e.indexOf(t,i);while(~n);return o+e.substring(i)},Mi=(e=bu)=>{let t=e?Nu:()=>String;return{isColorSupported:e,reset:t("\x1B[0m","\x1B[0m"),bold:t("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:t("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:t("\x1B[3m","\x1B[23m"),underline:t("\x1B[4m","\x1B[24m"),inverse:t("\x1B[7m","\x1B[27m"),hidden:t("\x1B[8m","\x1B[28m"),strikethrough:t("\x1B[9m","\x1B[29m"),black:t("\x1B[30m","\x1B[39m"),red:t("\x1B[31m","\x1B[39m"),green:t("\x1B[32m","\x1B[39m"),yellow:t("\x1B[33m","\x1B[39m"),blue:t("\x1B[34m","\x1B[39m"),magenta:t("\x1B[35m","\x1B[39m"),cyan:t("\x1B[36m","\x1B[39m"),white:t("\x1B[37m","\x1B[39m"),gray:t("\x1B[90m","\x1B[39m"),bgBlack:t("\x1B[40m","\x1B[49m"),bgRed:t("\x1B[41m","\x1B[49m"),bgGreen:t("\x1B[42m","\x1B[49m"),bgYellow:t("\x1B[43m","\x1B[49m"),bgBlue:t("\x1B[44m","\x1B[49m"),bgMagenta:t("\x1B[45m","\x1B[49m"),bgCyan:t("\x1B[46m","\x1B[49m"),bgWhite:t("\x1B[47m","\x1B[49m")}};ir.exports=Mi();ir.exports.createColors=Mi});var Zi=S((vl,zi)=>{zi.exports=Gi;Gi.sync=Iu;var Wi=require("fs");function Ou(e,t){var r=t.pathExt!==void 0?t.pathExt:process.env.PATHEXT;if(!r||(r=r.split(";"),r.indexOf("")!==-1))return!0;for(var n=0;n<r.length;n++){var o=r[n].toLowerCase();if(o&&e.substr(-o.length).toLowerCase()===o)return!0}return!1}function Vi(e,t,r){return!e.isSymbolicLink()&&!e.isFile()?!1:Ou(t,r)}function Gi(e,t,r){Wi.stat(e,function(n,o){r(n,n?!1:Vi(o,e,t))})}function Iu(e,t){return Vi(Wi.statSync(e),e,t)}});var Yi=S((Cl,Ji)=>{Ji.exports=Xi;Xi.sync=Lu;var ji=require("fs");function Xi(e,t,r){ji.stat(e,function(n,o){r(n,n?!1:Ki(o,t))})}function Lu(e,t){return Ki(ji.statSync(e),t)}function Ki(e,t){return e.isFile()&&Fu(e,t)}function Fu(e,t){var r=e.mode,n=e.uid,o=e.gid,i=t.uid!==void 0?t.uid:process.getuid&&process.getuid(),s=t.gid!==void 0?t.gid:process.getgid&&process.getgid(),a=parseInt("100",8),c=parseInt("010",8),u=parseInt("001",8),l=a|c,d=r&u||r&c&&o===s||r&a&&n===i||r&l&&i===0;return d}});var eo=S((Nl,Qi)=>{var bl=require("fs"),Lt;process.platform==="win32"||global.TESTING_WINDOWS?Lt=Zi():Lt=Yi();Qi.exports=or;or.sync=_u;function or(e,t,r){if(typeof t=="function"&&(r=t,t={}),!r){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(n,o){or(e,t||{},function(i,s){i?o(i):n(s)})})}Lt(e,t||{},function(n,o){n&&(n.code==="EACCES"||t&&t.ignoreErrors)&&(n=null,o=!1),r(n,o)})}function _u(e,t){try{return Lt.sync(e,t||{})}catch(r){if(t&&t.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var ao=S((Dl,so)=>{var Ve=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",to=require("path"),Tu=Ve?";":":",ro=eo(),no=e=>Object.assign(new Error(`not found: ${e}`),{code:"ENOENT"}),io=(e,t)=>{let r=t.colon||Tu,n=e.match(/\//)||Ve&&e.match(/\\/)?[""]:[...Ve?[process.cwd()]:[],...(t.path||process.env.PATH||"").split(r)],o=Ve?t.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",i=Ve?o.split(r):[""];return Ve&&e.indexOf(".")!==-1&&i[0]!==""&&i.unshift(""),{pathEnv:n,pathExt:i,pathExtExe:o}},oo=(e,t,r)=>{typeof t=="function"&&(r=t,t={}),t||(t={});let{pathEnv:n,pathExt:o,pathExtExe:i}=io(e,t),s=[],a=u=>new Promise((l,d)=>{if(u===n.length)return t.all&&s.length?l(s):d(no(e));let h=n[u],p=/^".*"$/.test(h)?h.slice(1,-1):h,f=to.join(p,e),y=!p&&/^\.[\\\/]/.test(e)?e.slice(0,2)+f:f;l(c(y,u,0))}),c=(u,l,d)=>new Promise((h,p)=>{if(d===o.length)return h(a(l+1));let f=o[d];ro(u+f,{pathExt:i},(y,w)=>{if(!y&&w)if(t.all)s.push(u+f);else return h(u+f);return h(c(u,l,d+1))})});return r?a(0).then(u=>r(null,u),r):a(0)},Au=(e,t)=>{t=t||{};let{pathEnv:r,pathExt:n,pathExtExe:o}=io(e,t),i=[];for(let s=0;s<r.length;s++){let a=r[s],c=/^".*"$/.test(a)?a.slice(1,-1):a,u=to.join(c,e),l=!c&&/^\.[\\\/]/.test(e)?e.slice(0,2)+u:u;for(let d=0;d<n.length;d++){let h=l+n[d];try{if(ro.sync(h,{pathExt:o}))if(t.all)i.push(h);else return h}catch{}}}if(t.all&&i.length)return i;if(t.nothrow)return null;throw no(e)};so.exports=oo;oo.sync=Au});var uo=S((Ol,sr)=>{"use strict";var co=(e={})=>{let t=e.env||process.env;return(e.platform||process.platform)!=="win32"?"PATH":Object.keys(t).reverse().find(n=>n.toUpperCase()==="PATH")||"Path"};sr.exports=co;sr.exports.default=co});var ho=S((Il,mo)=>{"use strict";var fo=require("path"),ku=ao(),Ru=uo();function lo(e,t){let r=e.options.env||process.env,n=process.cwd(),o=e.options.cwd!=null,i=o&&process.chdir!==void 0&&!process.chdir.disabled;if(i)try{process.chdir(e.options.cwd)}catch{}let s;try{s=ku.sync(e.command,{path:r[Ru({env:r})],pathExt:t?fo.delimiter:void 0})}catch{}finally{i&&process.chdir(n)}return s&&(s=fo.resolve(o?e.options.cwd:"",s)),s}function Pu(e){return lo(e)||lo(e,!0)}mo.exports=Pu});var po=S((Ll,cr)=>{"use strict";var ar=/([()\][%!^"`<>&|;, *?])/g;function qu(e){return e=e.replace(ar,"^$1"),e}function Uu(e,t){return e=`${e}`,e=e.replace(/(\\*)"/g,'$1$1\\"'),e=e.replace(/(\\*)$/,"$1$1"),e=`"${e}"`,e=e.replace(ar,"^$1"),t&&(e=e.replace(ar,"^$1")),e}cr.exports.command=qu;cr.exports.argument=Uu});var go=S((Fl,yo)=>{"use strict";yo.exports=/^#!(.*)/});var Eo=S((_l,wo)=>{"use strict";var Bu=go();wo.exports=(e="")=>{let t=e.match(Bu);if(!t)return null;let[r,n]=t[0].replace(/#! ?/,"").split(" "),o=r.split("/").pop();return o==="env"?n:n?`${o} ${n}`:o}});var xo=S((Tl,So)=>{"use strict";var ur=require("fs"),$u=Eo();function Mu(e){let r=Buffer.alloc(150),n;try{n=ur.openSync(e,"r"),ur.readSync(n,r,0,150,0),ur.closeSync(n)}catch{}return $u(r.toString())}So.exports=Mu});var No=S((Al,bo)=>{"use strict";var Hu=require("path"),vo=ho(),Co=po(),Wu=xo(),Vu=process.platform==="win32",Gu=/\.(?:com|exe)$/i,zu=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function Zu(e){e.file=vo(e);let t=e.file&&Wu(e.file);return t?(e.args.unshift(e.file),e.command=t,vo(e)):e.file}function ju(e){if(!Vu)return e;let t=Zu(e),r=!Gu.test(t);if(e.options.forceShell||r){let n=zu.test(t);e.command=Hu.normalize(e.command),e.command=Co.command(e.command),e.args=e.args.map(i=>Co.argument(i,n));let o=[e.command].concat(e.args).join(" ");e.args=["/d","/s","/c",`"${o}"`],e.command=process.env.comspec||"cmd.exe",e.options.windowsVerbatimArguments=!0}return e}function Xu(e,t,r){t&&!Array.isArray(t)&&(r=t,t=null),t=t?t.slice(0):[],r=Object.assign({},r);let n={command:e,args:t,options:r,file:void 0,original:{command:e,args:t}};return r.shell?n:ju(n)}bo.exports=Xu});var Io=S((kl,Oo)=>{"use strict";var fr=process.platform==="win32";function lr(e,t){return Object.assign(new Error(`${t} ${e.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${t} ${e.command}`,path:e.command,spawnargs:e.args})}function Ku(e,t){if(!fr)return;let r=e.emit;e.emit=function(n,o){if(n==="exit"){let i=Do(o,t,"spawn");if(i)return r.call(e,"error",i)}return r.apply(e,arguments)}}function Do(e,t){return fr&&e===1&&!t.file?lr(t.original,"spawn"):null}function Ju(e,t){return fr&&e===1&&!t.file?lr(t.original,"spawnSync"):null}Oo.exports={hookChildProcess:Ku,verifyENOENT:Do,verifyENOENTSync:Ju,notFoundError:lr}});var _o=S((Rl,Ge)=>{"use strict";var Lo=require("child_process"),dr=No(),mr=Io();function Fo(e,t,r){let n=dr(e,t,r),o=Lo.spawn(n.command,n.args,n.options);return mr.hookChildProcess(o,n),o}function Yu(e,t,r){let n=dr(e,t,r),o=Lo.spawnSync(n.command,n.args,n.options);return o.error=o.error||mr.verifyENOENTSync(o.status,n),o}Ge.exports=Fo;Ge.exports.spawn=Fo;Ge.exports.sync=Yu;Ge.exports._parse=dr;Ge.exports._enoent=mr});var To=S((Pl,Qu)=>{Qu.exports=["|/-\\","\u2802-\u2013\u2014\u2013-","\u25D0\u25D3\u25D1\u25D2","\u25F4\u25F7\u25F6\u25F5","\u25F0\u25F3\u25F2\u25F1","\u2596\u2598\u259D\u2597","\u25A0\u25A1\u25AA\u25AB","\u258C\u2580\u2590\u2584","\u2589\u258A\u258B\u258C\u258D\u258E\u258F\u258E\u258D\u258C\u258B\u258A\u2589","\u2581\u2583\u2584\u2585\u2586\u2587\u2588\u2587\u2586\u2585\u2584\u2583","\u2190\u2196\u2191\u2197\u2192\u2198\u2193\u2199","\u2524\u2518\u2534\u2514\u251C\u250C\u252C\u2510","\u25E2\u25E3\u25E4\u25E5",".oO\xB0Oo.",".oO@*",["\u{1F30D}","\u{1F30E}","\u{1F30F}"],"\u25E1\u25E1 \u2299\u2299 \u25E0\u25E0","\u2631\u2632\u2634","\u280B\u2819\u2839\u2838\u283C\u2834\u2826\u2827\u2807\u280F","\u280B\u2819\u281A\u281E\u2816\u2826\u2834\u2832\u2833\u2813","\u2804\u2806\u2807\u280B\u2819\u2838\u2830\u2820\u2830\u2838\u2819\u280B\u2807\u2806","\u280B\u2819\u281A\u2812\u2802\u2802\u2812\u2832\u2834\u2826\u2816\u2812\u2810\u2810\u2812\u2813\u280B","\u2801\u2809\u2819\u281A\u2812\u2802\u2802\u2812\u2832\u2834\u2824\u2804\u2804\u2824\u2834\u2832\u2812\u2802\u2802\u2812\u281A\u2819\u2809\u2801","\u2808\u2809\u280B\u2813\u2812\u2810\u2810\u2812\u2816\u2826\u2824\u2820\u2820\u2824\u2826\u2816\u2812\u2810\u2810\u2812\u2813\u280B\u2809\u2808","\u2801\u2801\u2809\u2819\u281A\u2812\u2802\u2802\u2812\u2832\u2834\u2824\u2804\u2804\u2824\u2820\u2820\u2824\u2826\u2816\u2812\u2810\u2810\u2812\u2813\u280B\u2809\u2808\u2808","\u2884\u2882\u2881\u2841\u2848\u2850\u2860","\u28B9\u28BA\u28BC\u28F8\u28C7\u2867\u2857\u284F","\u28FE\u28FD\u28FB\u28BF\u287F\u28DF\u28EF\u28F7","\u2801\u2802\u2804\u2840\u2880\u2820\u2810\u2808",["\u{1F311}","\u{1F312}","\u{1F313}","\u{1F314}","\u{1F315}","\u{1F31D}","\u{1F316}","\u{1F317}","\u{1F318}","\u{1F31A}"],["\u{1F55B}","\u{1F550}","\u{1F551}","\u{1F552}","\u{1F553}","\u{1F554}","\u{1F555}","\u{1F556}","\u{1F557}","\u{1F558}","\u{1F559}","\u{1F55A}"]]});var qo=S(Po=>{var Ao=require("readline"),ko=0,Ro=60;function ef(e){this.clearLine(this.stream),this.stream.write(e)}var fe=function(e){if(!(this instanceof fe))return new fe(e);typeof e=="string"?e={text:e}:e||(e={}),this.text=e.text||"",this.setSpinnerString(ko),this.setSpinnerDelay(Ro),this.onTick=e.onTick||ef,this.stream=e.stream||process.stdout};fe.spinners=To();fe.setDefaultSpinnerString=function(e){return ko=e,this};fe.setDefaultSpinnerDelay=function(e){return Ro=e,this};fe.prototype.start=function(){if(this.stream===process.stdout&&this.stream.isTTY!==!0)return this;var e=0,t=this,r=function(){var n=t.text.indexOf("%s")>-1?t.text.replace("%s",t.chars[e]):t.chars[e]+" "+t.text;t.onTick(n),e=++e%t.chars.length};return r(),this.id=setInterval(r,this.delay),this};fe.prototype.isSpinning=function(){return this.id!==void 0};fe.prototype.setSpinnerDelay=function(e){return this.delay=e,this};fe.prototype.setSpinnerString=function(e){let t=rf(e,this.spinners);return this.chars=Array.isArray(t)?t:t.split(""),this};fe.prototype.setSpinnerTitle=function(e){return this.text=e,this};fe.prototype.stop=function(e){return this.isSpinning===!1?this:(clearInterval(this.id),this.id=void 0,e&&this.clearLine(this.stream),this)};fe.prototype.clearLine=function(e){return Ao.clearLine(e,0),Ao.cursorTo(e,0),this};function tf(e){return typeof e=="number"&&e%1===0}function rf(e,t){if(!tf(e))return e+"";var r=fe.spinners.length;return e=e>=r?0:e,e=e<0?r+e:e,fe.spinners[e]}Po.Spinner=fe});function nf(){try{return pr.default.statSync("/.dockerenv"),!0}catch{return!1}}function of(){try{return pr.default.readFileSync("/proc/self/cgroup","utf8").includes("docker")}catch{return!1}}function yr(){return hr===void 0&&(hr=nf()||of()),hr}var pr,hr,Uo=ve(()=>{pr=X(require("node:fs"),1)});function ze(){return gr===void 0&&(gr=sf()||yr()),gr}var Bo,gr,sf,wr=ve(()=>{Bo=X(require("node:fs"),1);Uo();sf=()=>{try{return Bo.default.statSync("/run/.containerenv"),!0}catch{return!1}}});var Er,Mo,Ho,$o,at,Wo=ve(()=>{Er=X(require("node:process"),1),Mo=X(require("node:os"),1),Ho=X(require("node:fs"),1);wr();$o=()=>{if(Er.default.platform!=="linux")return!1;if(Mo.default.release().toLowerCase().includes("microsoft"))return!ze();try{return Ho.default.readFileSync("/proc/version","utf8").toLowerCase().includes("microsoft")?!ze():!1}catch{return!1}},at=Er.default.env.__IS_WSL_TEST__?$o:$o()});function Pe(e,t,r){let n=o=>Object.defineProperty(e,t,{value:o,enumerable:!0,writable:!0});return Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get(){let o=r();return n(o),o},set(o){n(o)}}),e}var Vo=ve(()=>{});async function Sr(){if(zo.default.platform!=="darwin")throw new Error("macOS only");let{stdout:e}=await af("defaults",["read","com.apple.LaunchServices/com.apple.launchservices.secure","LSHandlers"]);return/LSHandlerRoleAll = "(?!-)(?<id>[^"]+?)";\s+?LSHandlerURLScheme = (?:http|https);/.exec(e)?.groups.id??"com.apple.Safari"}var Go,zo,Zo,af,jo=ve(()=>{Go=require("node:util"),zo=X(require("node:process"),1),Zo=require("node:child_process"),af=(0,Go.promisify)(Zo.execFile)});async function Jo(e,{humanReadableOutput:t=!0}={}){if(Xo.default.platform!=="darwin")throw new Error("macOS only");let r=t?[]:["-ss"],{stdout:n}=await cf("osascript",["-e",e,r]);return n.trim()}var Xo,Ko,xr,cf,Yo=ve(()=>{Xo=X(require("node:process"),1),Ko=require("node:util"),xr=require("node:child_process"),cf=(0,Ko.promisify)(xr.execFile)});async function vr(e){return Jo(`tell application "Finder" to set app_path to application file id "${e}" as string
8
+ tell application "System Events" to get value of property list item "CFBundleName" of property list file (app_path & ":Contents:Info.plist")`)}var Qo=ve(()=>{Yo()});async function Cr(e=uf){let{stdout:t}=await e("reg",["QUERY"," HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\Shell\\Associations\\UrlAssociations\\http\\UserChoice","/v","ProgId"]),r=/ProgId\s*REG_SZ\s*(?<id>\S+)/.exec(t);if(!r)throw new Ft(`Cannot find Windows browser in stdout: ${JSON.stringify(t)}`);let{id:n}=r.groups,o=ff[n];if(!o)throw new Ft(`Unknown browser ID: ${n}`);return o}var es,ts,uf,ff,Ft,rs=ve(()=>{es=require("node:util"),ts=require("node:child_process"),uf=(0,es.promisify)(ts.execFile),ff={AppXq0fevzme2pys62n3e0fbqa7peapykr8v:{name:"Edge",id:"com.microsoft.edge.old"},MSEdgeDHTML:{name:"Edge",id:"com.microsoft.edge"},MSEdgeHTM:{name:"Edge",id:"com.microsoft.edge"},"IE.HTTP":{name:"Internet Explorer",id:"com.microsoft.ie"},FirefoxURL:{name:"Firefox",id:"org.mozilla.firefox"},ChromeHTML:{name:"Chrome",id:"com.google.chrome"},BraveHTML:{name:"Brave",id:"com.brave.Browser"},BraveBHTML:{name:"Brave Beta",id:"com.brave.Browser.beta"},BraveSSHTM:{name:"Brave Nightly",id:"com.brave.Browser.nightly"}},Ft=class extends Error{}});async function br(){if(_t.default.platform==="darwin"){let e=await Sr();return{name:await vr(e),id:e}}if(_t.default.platform==="linux"){let{stdout:e}=await lf("xdg-mime",["query","default","x-scheme-handler/http"]),t=e.trim();return{name:df(t.replace(/.desktop$/,"").replace("-"," ")),id:t}}if(_t.default.platform==="win32")return Cr();throw new Error("Only macOS, Linux, and Windows are supported")}var ns,_t,is,lf,df,os=ve(()=>{ns=require("node:util"),_t=X(require("node:process"),1),is=require("node:child_process");jo();Qo();rs();lf=(0,ns.promisify)(is.execFile),df=e=>e.toLowerCase().replaceAll(/(?:^|\s|-)\S/g,t=>t.toUpperCase())});var ms={};la(ms,{apps:()=>Ue,default:()=>yf,openApp:()=>pf});function us(e){if(typeof e=="string"||Array.isArray(e))return e;let{[as]:t}=e;if(!t)throw new Error(`${as} is not supported`);return t}function Nr({[Ze]:e},{wsl:t}){if(t&&at)return us(t);if(!e)throw new Error(`${Ze} is not supported`);return us(e)}var ct,fs,ls,ds,qe,ss,Ze,as,mf,cs,ut,hf,pf,Ue,yf,hs=ve(()=>{ct=X(require("node:process"),1),fs=require("node:buffer"),ls=X(require("node:path"),1),ds=X(require("node:child_process"),1),qe=X(require("node:fs/promises"),1);Wo();Vo();os();wr();ss=ls.default.join(__dirname,"xdg-open"),{platform:Ze,arch:as}=ct.default,mf=(()=>{let e="/mnt/",t;return async function(){if(t)return t;let r="/etc/wsl.conf",n=!1;try{await qe.default.access(r,qe.constants.F_OK),n=!0}catch{}if(!n)return e;let o=await qe.default.readFile(r,{encoding:"utf8"}),i=/(?<!#.*)root\s*=\s*(?<mountPoint>.*)/g.exec(o);return i?(t=i.groups.mountPoint.trim(),t=t.endsWith("/")?t:`${t}/`,t):e}})(),cs=async(e,t)=>{let r;for(let n of e)try{return await t(n)}catch(o){r=o}throw r},ut=async e=>{if(e={wait:!1,background:!1,newInstance:!1,allowNonzeroExitCode:!1,...e},Array.isArray(e.app))return cs(e.app,a=>ut({...e,app:a}));let{name:t,arguments:r=[]}=e.app??{};if(r=[...r],Array.isArray(t))return cs(t,a=>ut({...e,app:{name:a,arguments:r}}));if(t==="browser"||t==="browserPrivate"){let a={"com.google.chrome":"chrome","google-chrome.desktop":"chrome","org.mozilla.firefox":"firefox","firefox.desktop":"firefox","com.microsoft.msedge":"edge","com.microsoft.edge":"edge","microsoft-edge.desktop":"edge"},c={chrome:"--incognito",firefox:"--private-window",edge:"--inPrivate"},u=await br();if(u.id in a){let l=a[u.id];return t==="browserPrivate"&&r.push(c[l]),ut({...e,app:{name:Ue[l],arguments:r}})}throw new Error(`${u.name} is not supported as a default browser`)}let n,o=[],i={};if(Ze==="darwin")n="open",e.wait&&o.push("--wait-apps"),e.background&&o.push("--background"),e.newInstance&&o.push("--new"),t&&o.push("-a",t);else if(Ze==="win32"||at&&!ze()&&!t){let a=await mf();n=at?`${a}c/Windows/System32/WindowsPowerShell/v1.0/powershell.exe`:`${ct.default.env.SYSTEMROOT||ct.default.env.windir||"C:\\Windows"}\\System32\\WindowsPowerShell\\v1.0\\powershell`,o.push("-NoProfile","-NonInteractive","-ExecutionPolicy","Bypass","-EncodedCommand"),at||(i.windowsVerbatimArguments=!0);let c=["Start"];e.wait&&c.push("-Wait"),t?(c.push(`"\`"${t}\`""`),e.target&&r.push(e.target)):e.target&&c.push(`"${e.target}"`),r.length>0&&(r=r.map(u=>`"\`"${u}\`""`),c.push("-ArgumentList",r.join(","))),e.target=fs.Buffer.from(c.join(" "),"utf16le").toString("base64")}else{if(t)n=t;else{let a=!__dirname||__dirname==="/",c=!1;try{await qe.default.access(ss,qe.constants.X_OK),c=!0}catch{}n=ct.default.versions.electron??(Ze==="android"||a||!c)?"xdg-open":ss}r.length>0&&o.push(...r),e.wait||(i.stdio="ignore",i.detached=!0)}Ze==="darwin"&&r.length>0&&o.push("--args",...r),e.target&&o.push(e.target);let s=ds.default.spawn(n,o,i);return e.wait?new Promise((a,c)=>{s.once("error",c),s.once("close",u=>{if(!e.allowNonzeroExitCode&&u>0){c(new Error(`Exited with code ${u}`));return}a(s)})}):(s.unref(),s)},hf=(e,t)=>{if(typeof e!="string")throw new TypeError("Expected a `target`");return ut({...t,target:e})},pf=(e,t)=>{if(typeof e!="string"&&!Array.isArray(e))throw new TypeError("Expected a valid `name`");let{arguments:r=[]}=t??{};if(r!=null&&!Array.isArray(r))throw new TypeError("Expected `appArguments` as Array type");return ut({...t,app:{name:e,arguments:r}})};Ue={};Pe(Ue,"chrome",()=>Nr({darwin:"google chrome",win32:"chrome",linux:["google-chrome","google-chrome-stable","chromium"]},{wsl:{ia32:"/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe",x64:["/mnt/c/Program Files/Google/Chrome/Application/chrome.exe","/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe"]}}));Pe(Ue,"firefox",()=>Nr({darwin:"firefox",win32:"C:\\Program Files\\Mozilla Firefox\\firefox.exe",linux:"firefox"},{wsl:"/mnt/c/Program Files/Mozilla Firefox/firefox.exe"}));Pe(Ue,"edge",()=>Nr({darwin:"microsoft edge",win32:"msedge",linux:["microsoft-edge","microsoft-edge-dev"]},{wsl:"/mnt/c/Program Files (x86)/Microsoft/Edge/Application/msedge.exe"}));Pe(Ue,"browser",()=>"browser");Pe(Ue,"browserPrivate",()=>"browserPrivate");yf=hf});var Tt=S(ps=>{ps.require=function(){var e=require("fs");if(process.versions.electron)try{e=require("original-fs")}catch{}return e}});var Dr=S((id,ys)=>{ys.exports={LOCHDR:30,LOCSIG:67324752,LOCVER:4,LOCFLG:6,LOCHOW:8,LOCTIM:10,LOCCRC:14,LOCSIZ:18,LOCLEN:22,LOCNAM:26,LOCEXT:28,EXTSIG:134695760,EXTHDR:16,EXTCRC:4,EXTSIZ:8,EXTLEN:12,CENHDR:46,CENSIG:33639248,CENVEM:4,CENVER:6,CENFLG:8,CENHOW:10,CENTIM:12,CENCRC:16,CENSIZ:20,CENLEN:24,CENNAM:28,CENEXT:30,CENCOM:32,CENDSK:34,CENATT:36,CENATX:38,CENOFF:42,ENDHDR:22,ENDSIG:101010256,ENDSUB:8,ENDTOT:10,ENDSIZ:12,ENDOFF:16,ENDCOM:20,STORED:0,SHRUNK:1,REDUCED1:2,REDUCED2:3,REDUCED3:4,REDUCED4:5,IMPLODED:6,DEFLATED:8,ENHANCED_DEFLATED:9,PKWARE:10,BZIP2:12,LZMA:14,IBM_TERSE:18,IBM_LZ77:19,FLG_ENC:0,FLG_COMP1:1,FLG_COMP2:2,FLG_DESC:4,FLG_ENH:8,FLG_STR:16,FLG_LNG:1024,FLG_MSK:4096,FILE:0,BUFFER:1,NONE:2,EF_ID:0,EF_SIZE:2,ID_ZIP64:1,ID_AVINFO:7,ID_PFS:8,ID_OS2:9,ID_NTFS:10,ID_OPENVMS:12,ID_UNIX:13,ID_FORK:14,ID_PATCH:15,ID_X509_PKCS7:20,ID_X509_CERTID_F:21,ID_X509_CERTID_C:22,ID_STRONGENC:23,ID_RECORD_MGT:24,ID_X509_PKCS7_RL:25,ID_IBM1:101,ID_IBM2:102,ID_POSZIP:18064,EF_ZIP64_OR_32:4294967295,EF_ZIP64_OR_16:65535,EF_ZIP64_SUNCOMP:0,EF_ZIP64_SCOMP:8,EF_ZIP64_RHO:16,EF_ZIP64_DSN:24}});var Or=S((od,gs)=>{gs.exports={INVALID_LOC:"Invalid LOC header (bad signature)",INVALID_CEN:"Invalid CEN header (bad signature)",INVALID_END:"Invalid END header (bad signature)",NO_DATA:"Nothing to decompress",BAD_CRC:"CRC32 checksum failed",FILE_IN_THE_WAY:"There is a file in the way: %s",UNKNOWN_METHOD:"Invalid/unsupported compression method",AVAIL_DATA:"inflate::Available inflate data did not terminate",INVALID_DISTANCE:"inflate::Invalid literal/length or distance code in fixed or dynamic block",TO_MANY_CODES:"inflate::Dynamic block code description: too many length or distance codes",INVALID_REPEAT_LEN:"inflate::Dynamic block code description: repeat more than specified lengths",INVALID_REPEAT_FIRST:"inflate::Dynamic block code description: repeat lengths with no first length",INCOMPLETE_CODES:"inflate::Dynamic block code description: code lengths codes incomplete",INVALID_DYN_DISTANCE:"inflate::Dynamic block code description: invalid distance code lengths",INVALID_CODES_LEN:"inflate::Dynamic block code description: invalid literal/length code lengths",INVALID_STORE_BLOCK:"inflate::Stored block length did not match one's complement",INVALID_BLOCK_TYPE:"inflate::Invalid block type (type == 3)",CANT_EXTRACT_FILE:"Could not extract the file",CANT_OVERRIDE:"Target file already exists",NO_ZIP:"No zip file was loaded",NO_ENTRY:"Entry doesn't exist",DIRECTORY_CONTENT_ERROR:"A directory cannot have content",FILE_NOT_FOUND:"File not found: %s",NOT_IMPLEMENTED:"Not implemented",INVALID_FILENAME:"Invalid filename",INVALID_FORMAT:"Invalid or unsupported zip format. No END header found"}});var Es=S((sd,ws)=>{var P=Tt().require(),je=require("path");P.existsSync=P.existsSync||je.existsSync;ws.exports=function(){var e=[],t=Dr(),r=Or(),n=je.sep;function o(s){var a=s.split(n)[0];s.split(n).forEach(function(c){if(!(!c||c.substr(-1,1)===":")){a+=n+c;var u;try{u=P.statSync(a)}catch{P.mkdirSync(a)}if(u&&u.isFile())throw r.FILE_IN_THE_WAY.replace("%s",a)}})}function i(s,a,c){typeof a=="boolean"&&(c=a,a=void 0);var u=[];return P.readdirSync(s).forEach(function(l){var d=je.join(s,l);P.statSync(d).isDirectory()&&c&&(u=u.concat(i(d,a,c))),(!a||a.test(d))&&u.push(je.normalize(d)+(P.statSync(d).isDirectory()?n:""))}),u}return{makeDir:function(s){o(s)},crc32:function(s){typeof s=="string"&&(s=Buffer.alloc(s.length,s));var a=Buffer.alloc(4);if(!e.length)for(var c=0;c<256;c++){for(var u=c,l=8;--l>=0;)u&1?u=3988292384^u>>>1:u=u>>>1;u<0&&(a.writeInt32LE(u,0),u=a.readUInt32LE(0)),e[c]=u}for(var d=0,h=0,p=s.length,f=~d;--p>=0;)f=e[(f^s[h++])&255]^f>>>8;return d=~f,a.writeInt32LE(d&4294967295,0),a.readUInt32LE(0)},methodToString:function(s){switch(s){case t.STORED:return"STORED ("+s+")";case t.DEFLATED:return"DEFLATED ("+s+")";default:return"UNSUPPORTED ("+s+")"}},writeFileTo:function(s,a,c,u){if(P.existsSync(s)){if(!c)return!1;var l=P.statSync(s);if(l.isDirectory())return!1}var d=je.dirname(s);P.existsSync(d)||o(d);var h;try{h=P.openSync(s,"w",438)}catch{P.chmodSync(s,438),h=P.openSync(s,"w",438)}if(h)try{P.writeSync(h,a,0,a.length,0)}catch(p){throw p}finally{P.closeSync(h)}return P.chmodSync(s,u||438),!0},writeFileToAsync:function(s,a,c,u,l){typeof u=="function"&&(l=u,u=void 0),P.exists(s,function(d){if(d&&!c)return l(!1);P.stat(s,function(h,p){if(d&&p.isDirectory())return l(!1);var f=je.dirname(s);P.exists(f,function(y){y||o(f),P.open(s,"w",438,function(w,m){w?P.chmod(s,438,function(){P.open(s,"w",438,function(E,L){P.write(L,a,0,a.length,0,function(){P.close(L,function(){P.chmod(s,u||438,function(){l(!0)})})})})}):m?P.write(m,a,0,a.length,0,function(){P.close(m,function(){P.chmod(s,u||438,function(){l(!0)})})}):P.chmod(s,u||438,function(){l(!0)})})})})})},findFiles:function(s){return i(s,!0)},getAttributes:function(s){},setAttributes:function(s){},toBuffer:function(s){return Buffer.isBuffer(s)?s:s.length===0?Buffer.alloc(0):Buffer.alloc(s.length,s,"utf8")},Constants:t,Errors:r}}()});var vs=S((ad,xs)=>{var At=Tt().require(),Ss=require("path");At.existsSync=At.existsSync||Ss.existsSync;xs.exports=function(e){var t=e||"",r=0,n=i(),o=null;function i(){return{directory:!1,readonly:!1,hidden:!1,executable:!1,mtime:0,atime:0}}return t&&At.existsSync(t)?(o=At.statSync(t),n.directory=o.isDirectory(),n.mtime=o.mtime,n.atime=o.atime,n.executable=!!(1&parseInt((o.mode&parseInt("777",8)).toString(8)[0])),n.readonly=!!(2&parseInt((o.mode&parseInt("777",8)).toString(8)[0])),n.hidden=Ss.basename(t)[0]==="."):console.warn("Invalid path: "+t),{get directory(){return n.directory},get readOnly(){return n.readonly},get hidden(){return n.hidden},get mtime(){return n.mtime},get atime(){return n.atime},get executable(){return n.executable},decodeAttributes:function(s){},encodeAttributes:function(s){},toString:function(){return`{
9
9
  "path" : "`+t+`,
10
10
  "isDirectory" : `+n.directory+`,
11
11
  "isReadOnly" : `+n.readonly+`,
@@ -13,7 +13,7 @@ tell application "System Events" to get value of property list item "CFBundleNam
13
13
  "isExecutable" : `+n.executable+`,
14
14
  "mTime" : `+n.mtime+`
15
15
  "aTime" : `+n.atime+`
16
- }`}}}});var Ke=S((ld,Xe)=>{Xe.exports=xs();Xe.exports.FileSystem=Tt();Xe.exports.Constants=Ir();Xe.exports.Errors=Lr();Xe.exports.FileAttr=bs()});var Ds=S((dd,Ns)=>{var kt=Ke(),x=kt.Constants;Ns.exports=function(){var e=10,t=10,r=0,n=0,o=0,i=0,s=0,a=0,c=0,u=0,l=0,d=0,h=0,p=0,f=0,y={};function w(m){m=new Date(m),o=(m.getFullYear()-1980&127)<<25|m.getMonth()+1<<21|m.getDate()<<16|m.getHours()<<11|m.getMinutes()<<5|m.getSeconds()>>1}return w(+new Date),{get made(){return e},set made(m){e=m},get version(){return t},set version(m){t=m},get flags(){return r},set flags(m){r=m},get method(){return n},set method(m){n=m},get time(){return new Date((o>>25&127)+1980,(o>>21&15)-1,o>>16&31,o>>11&31,o>>5&63,(o&31)<<1)},set time(m){w(m)},get crc(){return i},set crc(m){i=m},get compressedSize(){return s},set compressedSize(m){s=m},get size(){return a},set size(m){a=m},get fileNameLength(){return c},set fileNameLength(m){c=m},get extraLength(){return u},set extraLength(m){u=m},get commentLength(){return l},set commentLength(m){l=m},get diskNumStart(){return d},set diskNumStart(m){d=m},get inAttr(){return h},set inAttr(m){h=m},get attr(){return p},set attr(m){p=m},get offset(){return f},set offset(m){f=m},get encripted(){return(r&1)===1},get entryHeaderSize(){return x.CENHDR+c+u+l},get realDataOffset(){return f+x.LOCHDR+y.fnameLen+y.extraLen},get dataHeader(){return y},loadDataHeaderFromBinary:function(m){var E=m.slice(f,f+x.LOCHDR);if(E.readUInt32LE(0)!==x.LOCSIG)throw kt.Errors.INVALID_LOC;y={version:E.readUInt16LE(x.LOCVER),flags:E.readUInt16LE(x.LOCFLG),method:E.readUInt16LE(x.LOCHOW),time:E.readUInt32LE(x.LOCTIM),crc:E.readUInt32LE(x.LOCCRC),compressedSize:E.readUInt32LE(x.LOCSIZ),size:E.readUInt32LE(x.LOCLEN),fnameLen:E.readUInt16LE(x.LOCNAM),extraLen:E.readUInt16LE(x.LOCEXT)}},loadFromBinary:function(m){if(m.length!==x.CENHDR||m.readUInt32LE(0)!==x.CENSIG)throw kt.Errors.INVALID_CEN;e=m.readUInt16LE(x.CENVEM),t=m.readUInt16LE(x.CENVER),r=m.readUInt16LE(x.CENFLG),n=m.readUInt16LE(x.CENHOW),o=m.readUInt32LE(x.CENTIM),i=m.readUInt32LE(x.CENCRC),s=m.readUInt32LE(x.CENSIZ),a=m.readUInt32LE(x.CENLEN),c=m.readUInt16LE(x.CENNAM),u=m.readUInt16LE(x.CENEXT),l=m.readUInt16LE(x.CENCOM),d=m.readUInt16LE(x.CENDSK),h=m.readUInt16LE(x.CENATT),p=m.readUInt32LE(x.CENATX),f=m.readUInt32LE(x.CENOFF)},dataHeaderToBinary:function(){var m=Buffer.alloc(x.LOCHDR);return m.writeUInt32LE(x.LOCSIG,0),m.writeUInt16LE(t,x.LOCVER),m.writeUInt16LE(r,x.LOCFLG),m.writeUInt16LE(n,x.LOCHOW),m.writeUInt32LE(o,x.LOCTIM),m.writeUInt32LE(i,x.LOCCRC),m.writeUInt32LE(s,x.LOCSIZ),m.writeUInt32LE(a,x.LOCLEN),m.writeUInt16LE(c,x.LOCNAM),m.writeUInt16LE(u,x.LOCEXT),m},entryHeaderToBinary:function(){var m=Buffer.alloc(x.CENHDR+c+u+l);return m.writeUInt32LE(x.CENSIG,0),m.writeUInt16LE(e,x.CENVEM),m.writeUInt16LE(t,x.CENVER),m.writeUInt16LE(r,x.CENFLG),m.writeUInt16LE(n,x.CENHOW),m.writeUInt32LE(o,x.CENTIM),m.writeUInt32LE(i,x.CENCRC),m.writeUInt32LE(s,x.CENSIZ),m.writeUInt32LE(a,x.CENLEN),m.writeUInt16LE(c,x.CENNAM),m.writeUInt16LE(u,x.CENEXT),m.writeUInt16LE(l,x.CENCOM),m.writeUInt16LE(d,x.CENDSK),m.writeUInt16LE(h,x.CENATT),m.writeUInt32LE(p,x.CENATX),m.writeUInt32LE(f,x.CENOFF),m.fill(0,x.CENHDR),m},toString:function(){return`{
16
+ }`}}}});var Ke=S((cd,Xe)=>{Xe.exports=Es();Xe.exports.FileSystem=Tt();Xe.exports.Constants=Dr();Xe.exports.Errors=Or();Xe.exports.FileAttr=vs()});var bs=S((ud,Cs)=>{var kt=Ke(),x=kt.Constants;Cs.exports=function(){var e=10,t=10,r=0,n=0,o=0,i=0,s=0,a=0,c=0,u=0,l=0,d=0,h=0,p=0,f=0,y={};function w(m){m=new Date(m),o=(m.getFullYear()-1980&127)<<25|m.getMonth()+1<<21|m.getDate()<<16|m.getHours()<<11|m.getMinutes()<<5|m.getSeconds()>>1}return w(+new Date),{get made(){return e},set made(m){e=m},get version(){return t},set version(m){t=m},get flags(){return r},set flags(m){r=m},get method(){return n},set method(m){n=m},get time(){return new Date((o>>25&127)+1980,(o>>21&15)-1,o>>16&31,o>>11&31,o>>5&63,(o&31)<<1)},set time(m){w(m)},get crc(){return i},set crc(m){i=m},get compressedSize(){return s},set compressedSize(m){s=m},get size(){return a},set size(m){a=m},get fileNameLength(){return c},set fileNameLength(m){c=m},get extraLength(){return u},set extraLength(m){u=m},get commentLength(){return l},set commentLength(m){l=m},get diskNumStart(){return d},set diskNumStart(m){d=m},get inAttr(){return h},set inAttr(m){h=m},get attr(){return p},set attr(m){p=m},get offset(){return f},set offset(m){f=m},get encripted(){return(r&1)===1},get entryHeaderSize(){return x.CENHDR+c+u+l},get realDataOffset(){return f+x.LOCHDR+y.fnameLen+y.extraLen},get dataHeader(){return y},loadDataHeaderFromBinary:function(m){var E=m.slice(f,f+x.LOCHDR);if(E.readUInt32LE(0)!==x.LOCSIG)throw kt.Errors.INVALID_LOC;y={version:E.readUInt16LE(x.LOCVER),flags:E.readUInt16LE(x.LOCFLG),method:E.readUInt16LE(x.LOCHOW),time:E.readUInt32LE(x.LOCTIM),crc:E.readUInt32LE(x.LOCCRC),compressedSize:E.readUInt32LE(x.LOCSIZ),size:E.readUInt32LE(x.LOCLEN),fnameLen:E.readUInt16LE(x.LOCNAM),extraLen:E.readUInt16LE(x.LOCEXT)}},loadFromBinary:function(m){if(m.length!==x.CENHDR||m.readUInt32LE(0)!==x.CENSIG)throw kt.Errors.INVALID_CEN;e=m.readUInt16LE(x.CENVEM),t=m.readUInt16LE(x.CENVER),r=m.readUInt16LE(x.CENFLG),n=m.readUInt16LE(x.CENHOW),o=m.readUInt32LE(x.CENTIM),i=m.readUInt32LE(x.CENCRC),s=m.readUInt32LE(x.CENSIZ),a=m.readUInt32LE(x.CENLEN),c=m.readUInt16LE(x.CENNAM),u=m.readUInt16LE(x.CENEXT),l=m.readUInt16LE(x.CENCOM),d=m.readUInt16LE(x.CENDSK),h=m.readUInt16LE(x.CENATT),p=m.readUInt32LE(x.CENATX),f=m.readUInt32LE(x.CENOFF)},dataHeaderToBinary:function(){var m=Buffer.alloc(x.LOCHDR);return m.writeUInt32LE(x.LOCSIG,0),m.writeUInt16LE(t,x.LOCVER),m.writeUInt16LE(r,x.LOCFLG),m.writeUInt16LE(n,x.LOCHOW),m.writeUInt32LE(o,x.LOCTIM),m.writeUInt32LE(i,x.LOCCRC),m.writeUInt32LE(s,x.LOCSIZ),m.writeUInt32LE(a,x.LOCLEN),m.writeUInt16LE(c,x.LOCNAM),m.writeUInt16LE(u,x.LOCEXT),m},entryHeaderToBinary:function(){var m=Buffer.alloc(x.CENHDR+c+u+l);return m.writeUInt32LE(x.CENSIG,0),m.writeUInt16LE(e,x.CENVEM),m.writeUInt16LE(t,x.CENVER),m.writeUInt16LE(r,x.CENFLG),m.writeUInt16LE(n,x.CENHOW),m.writeUInt32LE(o,x.CENTIM),m.writeUInt32LE(i,x.CENCRC),m.writeUInt32LE(s,x.CENSIZ),m.writeUInt32LE(a,x.CENLEN),m.writeUInt16LE(c,x.CENNAM),m.writeUInt16LE(u,x.CENEXT),m.writeUInt16LE(l,x.CENCOM),m.writeUInt16LE(d,x.CENDSK),m.writeUInt16LE(h,x.CENATT),m.writeUInt32LE(p,x.CENATX),m.writeUInt32LE(f,x.CENOFF),m.fill(0,x.CENHDR),m},toString:function(){return`{
17
17
  "made" : `+e+`,
18
18
  "version" : `+t+`,
19
19
  "flags" : `+r+`,
@@ -30,13 +30,13 @@ tell application "System Events" to get value of property list item "CFBundleNam
30
30
  "attr" : `+p+`,
31
31
  "offset" : `+f+`,
32
32
  "entryHeaderSize" : `+(x.CENHDR+c+u+l)+` bytes
33
- }`}}}});var Ls=S((md,Is)=>{var Os=Ke(),ie=Os.Constants;Is.exports=function(){var e=0,t=0,r=0,n=0,o=0;return{get diskEntries(){return e},set diskEntries(i){e=t=i},get totalEntries(){return t},set totalEntries(i){t=e=i},get size(){return r},set size(i){r=i},get offset(){return n},set offset(i){n=i},get commentLength(){return o},set commentLength(i){o=i},get mainHeaderSize(){return ie.ENDHDR+o},loadFromBinary:function(i){if(i.length!==ie.ENDHDR||i.readUInt32LE(0)!==ie.ENDSIG)throw Os.Errors.INVALID_END;e=i.readUInt16LE(ie.ENDSUB),t=i.readUInt16LE(ie.ENDTOT),r=i.readUInt32LE(ie.ENDSIZ),n=i.readUInt32LE(ie.ENDOFF),o=i.readUInt16LE(ie.ENDCOM)},toBinary:function(){var i=Buffer.alloc(ie.ENDHDR+o);return i.writeUInt32LE(ie.ENDSIG,0),i.writeUInt32LE(0,4),i.writeUInt16LE(e,ie.ENDSUB),i.writeUInt16LE(t,ie.ENDTOT),i.writeUInt32LE(r,ie.ENDSIZ),i.writeUInt32LE(n,ie.ENDOFF),i.writeUInt16LE(o,ie.ENDCOM),i.fill(" ",ie.ENDHDR),i},toString:function(){return`{
33
+ }`}}}});var Os=S((fd,Ds)=>{var Ns=Ke(),ie=Ns.Constants;Ds.exports=function(){var e=0,t=0,r=0,n=0,o=0;return{get diskEntries(){return e},set diskEntries(i){e=t=i},get totalEntries(){return t},set totalEntries(i){t=e=i},get size(){return r},set size(i){r=i},get offset(){return n},set offset(i){n=i},get commentLength(){return o},set commentLength(i){o=i},get mainHeaderSize(){return ie.ENDHDR+o},loadFromBinary:function(i){if(i.length!==ie.ENDHDR||i.readUInt32LE(0)!==ie.ENDSIG)throw Ns.Errors.INVALID_END;e=i.readUInt16LE(ie.ENDSUB),t=i.readUInt16LE(ie.ENDTOT),r=i.readUInt32LE(ie.ENDSIZ),n=i.readUInt32LE(ie.ENDOFF),o=i.readUInt16LE(ie.ENDCOM)},toBinary:function(){var i=Buffer.alloc(ie.ENDHDR+o);return i.writeUInt32LE(ie.ENDSIG,0),i.writeUInt32LE(0,4),i.writeUInt16LE(e,ie.ENDSUB),i.writeUInt16LE(t,ie.ENDTOT),i.writeUInt32LE(r,ie.ENDSIZ),i.writeUInt32LE(n,ie.ENDOFF),i.writeUInt16LE(o,ie.ENDCOM),i.fill(" ",ie.ENDHDR),i},toString:function(){return`{
34
34
  "diskEntries" : `+e+`,
35
35
  "totalEntries" : `+t+`,
36
36
  "size" : `+r+` bytes,
37
37
  "offset" : 0x`+n.toString(16).toUpperCase()+`,
38
38
  "commentLength" : 0x`+o+`
39
- }`}}}});var _r=S(Fr=>{Fr.EntryHeader=Ds();Fr.MainHeader=Ls()});var Fs=S(()=>{});var As=S((gd,Ts)=>{var _s=require("buffer").Buffer;function Sf(e){var t=32768,r=_s.alloc(65536),n=0,o=null,i,s,a=0,c=0,u=-1,l=!1,d=0,h=0,p,f,y,w,m=0,E=[0,1,3,7,15,31,63,127,255,511,1023,2047,4095,8191,16383,32767,65535],L=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],B=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,99,99],pe=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577],j=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],oe=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];function ye(v,C,N,g,T,F){this.status=0,this.r=null,this.maxbit=0;var Q,Oe,k,z=[],ee=[],M=[],ge=[],Z={extra:0,bitcnt:0,lbase:0,next:null};k=this.r=null;for(var R=0;R<17;R++)ee[R]=0,M[R]=0,z[R]=0;for(R=0;R<288;R++)ge[R]=0;Q=C>256?v[256]:16;for(var me=-1;++me<C;)ee[v[me]]++;if(ee[0]!==C){for(var I=1;I<=16&&ee[I]===0;I++);var be=I;for(R=16;R!==0&&ee[R]===0;R--);var dt=R;F<I&&(F=I);for(var Je=1<<I;I<R;I++,Je<<=1)if((Je-=ee[I])<0){this.status=2,this.maxbit=F;return}if((Je-=ee[R])<0){this.status=2,this.maxbit=F;return}ee[R]+=Je,z[1]=I=0,me=1;for(var mt=2;--R>0;)z[mt++]=I+=ee[me++];me=0,R=0;do(I=v[me++])&&(ge[z[I]++]=R);while(++R<C);C=z[dt],z[0]=R=0,me=0;for(var re=-1,de=M[0]=0,xe=null,Ae=0,Ye=[];be<=dt;be++)for(var $t=ee[be];$t-- >0;){for(;be>de+M[1+re];){if(de+=M[1+re],re++,Ae=(Ae=dt-de)>F?F:Ae,(Oe=1<<(I=be-de))>$t+1)for(Oe-=$t+1,mt=be;++I<Ae&&!((Oe<<=1)<=ee[++mt]);)Oe-=ee[mt];for(de+I>Q&&de<Q&&(I=Q-de),Ae=1<<I,M[1+re]=I,xe=[];xe.length<Ae;)xe.push({extra:0,bitcnt:0,lbase:0,next:null});k==null?k=this.r={next:null,list:null}:k=k.next={next:null,list:null},k.next=null,k.list=xe,Ye[re]=xe,re>0&&(z[re]=R,Z.bitcnt=M[re],Z.extra=16+I,Z.next=xe,I=(R&(1<<de)-1)>>de-M[re],Ye[re-1][I].extra=Z.extra,Ye[re-1][I].bitcnt=Z.bitcnt,Ye[re-1][I].lbase=Z.lbase,Ye[re-1][I].next=Z.next)}for(Z.bitcnt=be-de,me>=C?Z.extra=99:ge[me]<N?(Z.extra=ge[me]<256?16:15,Z.lbase=ge[me++]):(Z.extra=T[ge[me]-N],Z.lbase=g[ge[me++]-N]),Oe=1<<be-de,I=R>>de;I<Ae;I+=Oe)xe[I].extra=Z.extra,xe[I].bitcnt=Z.bitcnt,xe[I].lbase=Z.lbase,xe[I].next=Z.next;for(I=1<<be-1;R&I;I>>=1)R^=I;for(R^=I;(R&(1<<de)-1)!==z[re];)de-=M[re],re--}this.maxbit=M[1],this.status=Je!==0&&dt!==1?1:0}}function b(v){for(;c<v;)a|=e[m++]<<c,c+=8;return a}function O(v){return c-=v,a>>=v}function D(v){for(;c<v;)a|=e[m++]<<c,c+=8;var C=a&E[v];return a>>=v,c-=v,C}function q(v,C,N){var g,T;if(N===0)return 0;for(var F=0;;){for(T=p.list[b(y)&E[y]],g=T.extra;g>16;){if(g===99)return-1;O(T.bitcnt),g-=16,T=T.next[b(g)&E[g]],g=T.extra}if(O(T.bitcnt),g===16){if(n&=t-1,v[C+F++]=r[n++]=T.lbase,F===N)return N;continue}if(g===15)break;for(d=T.lbase+D(g),T=f.list[b(w)&E[w]],g=T.extra;g>16;){if(g===99)return-1;O(T.bitcnt),g-=16,T=T.next[b(g)&E[g]],g=T.extra}for(O(T.bitcnt),h=n-T.lbase-D(g);d>0&&F<N;)d--,h&=t-1,n&=t-1,v[C+F++]=r[n++]=r[h++];if(F===N)return N}return u=-1,F}function U(v,C,N){O(c&7);var g=D(16);if(g!==(~D(16)&65535))return-1;for(d=g,g=0;d>0&&g<N;)d--,n&=t-1,v[C+g++]=r[n++]=D(8);return d===0&&(u=-1),g}function $(v,C,N){var g=0;if(o==null){for(var T=[],F=0;F<144;F++)T[F]=8;for(;F<256;F++)T[F]=9;for(;F<280;F++)T[F]=7;for(;F<288;F++)T[F]=8;s=7;var Q=new ye(T,288,257,L,B,s);if(Q.status!==0)return-1;for(o=Q.r,s=Q.maxbit,F=0;F<30;F++)T[F]=5;if(g=5,Q=new ye(T,30,0,pe,j,g),Q.status>1)return o=null,-1;i=Q.r,g=Q.maxbit}return p=o,f=i,y=s,w=g,q(v,C,N)}function A(v,C,N){for(var g=new Array(572),T=0;T<572;T++)g[T]=0;var F=257+D(5),Q=1+D(5),Oe=4+D(4);if(F>286||Q>30)return-1;for(var k=0;k<Oe;k++)g[oe[k]]=D(3);for(;k<19;k++)g[oe[k]]=0;y=7;var z=new ye(g,19,19,null,null,y);if(z.status!==0)return-1;p=z.r,y=z.maxbit;for(var ee=F+Q,M=0,ge=0;M<ee;){var Z=p.list[b(y)&E[y]];if(k=Z.bitcnt,O(k),k=Z.lbase,k<16)g[M++]=ge=k;else if(k===16){if(k=3+D(2),M+k>ee)return-1;for(;k-- >0;)g[M++]=ge}else if(k===17){if(k=3+D(3),M+k>ee)return-1;for(;k-- >0;)g[M++]=0;ge=0}else{if(k=11+D(7),M+k>ee)return-1;for(;k-- >0;)g[M++]=0;ge=0}}if(y=9,z=new ye(g,F,257,L,B,y),y===0&&(z.status=1),z.status!==0)return-1;for(p=z.r,y=z.maxbit,M=0;M<Q;M++)g[M]=g[M+F];return w=6,z=new ye(g,Q,0,pe,j,w),f=z.r,w=z.maxbit,w===0&&F>257||z.status!==0?-1:q(v,C,N)}return{inflate:function(v){p=null;for(var C=v.length,N=0,g;N<C;){if(l&&u===-1)return;if(d>0){if(u!==0)for(;d>0&&N<C;)d--,h&=t-1,n&=t-1,v[N++]=r[n++]=r[h++];else{for(;d>0&&N<C;)d--,n&=t-1,v[N++]=r[n++]=D(8);d===0&&(u=-1)}if(N===C)return}if(u===-1){if(l)break;l=D(1)!==0,u=D(2),p=null,d=0}switch(u){case 0:g=U(v,N,C-N);break;case 1:g=p!=null?q(v,N,C-N):$(v,N,C-N);break;case 2:g=p!=null?q(v,N,C-N):A(v,N,C-N);break;default:g=-1;break}if(g===-1)return;N+=g}}}}Ts.exports=function(e){var t=require("zlib");return{inflateAsync:function(r){var n=t.createInflateRaw(),o=[],i=0;n.on("data",function(s){o.push(s),i+=s.length}),n.on("end",function(){var s=_s.alloc(i),a=0;s.fill(0);for(var c=0;c<o.length;c++){var u=o[c];u.copy(s,a),a+=u.length}r&&r(s)}),n.end(e)},inflate:function(r){var n={x:new Sf(e)};n.x.inflate(r),delete n.x}}}});var ks=S(Tr=>{Tr.Deflater=Fs();Tr.Inflater=As()});var Ar=S((Ed,Ps)=>{var W=Ke(),xf=_r(),he=W.Constants,Rs=ks();Ps.exports=function(e){var t=new xf.EntryHeader,r=Buffer.alloc(0),n=Buffer.alloc(0),o=!1,i=null,s=Buffer.alloc(0);function a(){return!e||!Buffer.isBuffer(e)?Buffer.alloc(0):(t.loadDataHeaderFromBinary(e),e.slice(t.realDataOffset,t.realDataOffset+t.compressedSize))}function c(f){return!((t.flags&8)!==8&&W.crc32(f)!==t.crc)}function u(f,y,w){if(typeof y>"u"&&typeof f=="string"&&(w=f,f=void 0),o)return f&&y&&y(Buffer.alloc(0),W.Errors.DIRECTORY_CONTENT_ERROR),Buffer.alloc(0);var m=a();if(m.length===0)return f&&y&&y(m,W.Errors.NO_DATA),m;var E=Buffer.alloc(t.size);switch(t.method){case W.Constants.STORED:return m.copy(E),c(E)?(f&&y&&y(E),E):(f&&y&&y(E,W.Errors.BAD_CRC),W.Errors.BAD_CRC);case W.Constants.DEFLATED:var L=new Rs.Inflater(m);if(f)L.inflateAsync(function(B){B.copy(E,0),c(E)?y&&y(E):y&&y(E,W.Errors.BAD_CRC)});else return L.inflate(E),c(E)||console.warn(W.Errors.BAD_CRC+" "+r.toString()),E;break;default:return f&&y&&y(Buffer.alloc(0),W.Errors.UNKNOWN_METHOD),W.Errors.UNKNOWN_METHOD}}function l(f,y){if((!i||!i.length)&&Buffer.isBuffer(e))return f&&y&&y(a()),a();if(i.length&&!o){var w;switch(t.method){case W.Constants.STORED:return t.compressedSize=t.size,w=Buffer.alloc(i.length),i.copy(w),f&&y&&y(w),w;default:case W.Constants.DEFLATED:var m=new Rs.Deflater(i);if(f)m.deflateAsync(function(L){w=Buffer.alloc(L.length),t.compressedSize=L.length,L.copy(w),y&&y(w)});else{var E=m.deflate();return t.compressedSize=E.length,E}m=null;break}}else if(f&&y)y(Buffer.alloc(0));else return Buffer.alloc(0)}function d(f,y){return(f.readUInt32LE(y+4)<<4)+f.readUInt32LE(y)}function h(f){for(var y=0,w,m,E;y<f.length;)w=f.readUInt16LE(y),y+=2,m=f.readUInt16LE(y),y+=2,E=f.slice(y,y+m),y+=m,he.ID_ZIP64===w&&p(E)}function p(f){var y,w,m,E;f.length>=he.EF_ZIP64_SCOMP&&(y=d(f,he.EF_ZIP64_SUNCOMP),t.size===he.EF_ZIP64_OR_32&&(t.size=y)),f.length>=he.EF_ZIP64_RHO&&(w=d(f,he.EF_ZIP64_SCOMP),t.compressedSize===he.EF_ZIP64_OR_32&&(t.compressedSize=w)),f.length>=he.EF_ZIP64_DSN&&(m=d(f,he.EF_ZIP64_RHO),t.offset===he.EF_ZIP64_OR_32&&(t.offset=m)),f.length>=he.EF_ZIP64_DSN+4&&(E=f.readUInt32LE(he.EF_ZIP64_DSN),t.diskNumStart===he.EF_ZIP64_OR_16&&(t.diskNumStart=E))}return{get entryName(){return r.toString()},get rawEntryName(){return r},set entryName(f){r=W.toBuffer(f);var y=r[r.length-1];o=y===47||y===92,t.fileNameLength=r.length},get extra(){return s},set extra(f){s=f,t.extraLength=f.length,h(f)},get comment(){return n.toString()},set comment(f){n=W.toBuffer(f),t.commentLength=n.length},get name(){var f=r.toString();return o?f.substr(f.length-1).split("/").pop():f.split("/").pop()},get isDirectory(){return o},getCompressedData:function(){return l(!1,null)},getCompressedDataAsync:function(f){l(!0,f)},setData:function(f){i=W.toBuffer(f),!o&&i.length?(t.size=i.length,t.method=W.Constants.STORED,t.crc=W.crc32(f),t.changed=!0):t.method=W.Constants.STORED},getData:function(f){return t.changed?i:u(!1,null,f)},getDataAsync:function(f,y){t.changed?f(i):u(!0,f,y)},set attr(f){t.attr=f},get attr(){return t.attr},set header(f){t.loadFromBinary(f)},get header(){return t},packHeader:function(){var f=t.entryHeaderToBinary();return r.copy(f,W.Constants.CENHDR),t.extraLength&&s.copy(f,W.Constants.CENHDR+r.length),t.commentLength&&n.copy(f,W.Constants.CENHDR+r.length+t.extraLength,n.length),f},toString:function(){return`{
39
+ }`}}}});var Lr=S(Ir=>{Ir.EntryHeader=bs();Ir.MainHeader=Os()});var Is=S(()=>{});var _s=S((hd,Fs)=>{var Ls=require("buffer").Buffer;function gf(e){var t=32768,r=Ls.alloc(65536),n=0,o=null,i,s,a=0,c=0,u=-1,l=!1,d=0,h=0,p,f,y,w,m=0,E=[0,1,3,7,15,31,63,127,255,511,1023,2047,4095,8191,16383,32767,65535],L=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],B=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,99,99],pe=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577],j=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],oe=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];function ye(v,C,N,g,T,F){this.status=0,this.r=null,this.maxbit=0;var Q,Oe,k,z=[],ee=[],M=[],ge=[],Z={extra:0,bitcnt:0,lbase:0,next:null};k=this.r=null;for(var R=0;R<17;R++)ee[R]=0,M[R]=0,z[R]=0;for(R=0;R<288;R++)ge[R]=0;Q=C>256?v[256]:16;for(var me=-1;++me<C;)ee[v[me]]++;if(ee[0]!==C){for(var I=1;I<=16&&ee[I]===0;I++);var be=I;for(R=16;R!==0&&ee[R]===0;R--);var dt=R;F<I&&(F=I);for(var Je=1<<I;I<R;I++,Je<<=1)if((Je-=ee[I])<0){this.status=2,this.maxbit=F;return}if((Je-=ee[R])<0){this.status=2,this.maxbit=F;return}ee[R]+=Je,z[1]=I=0,me=1;for(var mt=2;--R>0;)z[mt++]=I+=ee[me++];me=0,R=0;do(I=v[me++])&&(ge[z[I]++]=R);while(++R<C);C=z[dt],z[0]=R=0,me=0;for(var re=-1,de=M[0]=0,xe=null,Ae=0,Ye=[];be<=dt;be++)for(var $t=ee[be];$t-- >0;){for(;be>de+M[1+re];){if(de+=M[1+re],re++,Ae=(Ae=dt-de)>F?F:Ae,(Oe=1<<(I=be-de))>$t+1)for(Oe-=$t+1,mt=be;++I<Ae&&!((Oe<<=1)<=ee[++mt]);)Oe-=ee[mt];for(de+I>Q&&de<Q&&(I=Q-de),Ae=1<<I,M[1+re]=I,xe=[];xe.length<Ae;)xe.push({extra:0,bitcnt:0,lbase:0,next:null});k==null?k=this.r={next:null,list:null}:k=k.next={next:null,list:null},k.next=null,k.list=xe,Ye[re]=xe,re>0&&(z[re]=R,Z.bitcnt=M[re],Z.extra=16+I,Z.next=xe,I=(R&(1<<de)-1)>>de-M[re],Ye[re-1][I].extra=Z.extra,Ye[re-1][I].bitcnt=Z.bitcnt,Ye[re-1][I].lbase=Z.lbase,Ye[re-1][I].next=Z.next)}for(Z.bitcnt=be-de,me>=C?Z.extra=99:ge[me]<N?(Z.extra=ge[me]<256?16:15,Z.lbase=ge[me++]):(Z.extra=T[ge[me]-N],Z.lbase=g[ge[me++]-N]),Oe=1<<be-de,I=R>>de;I<Ae;I+=Oe)xe[I].extra=Z.extra,xe[I].bitcnt=Z.bitcnt,xe[I].lbase=Z.lbase,xe[I].next=Z.next;for(I=1<<be-1;R&I;I>>=1)R^=I;for(R^=I;(R&(1<<de)-1)!==z[re];)de-=M[re],re--}this.maxbit=M[1],this.status=Je!==0&&dt!==1?1:0}}function b(v){for(;c<v;)a|=e[m++]<<c,c+=8;return a}function O(v){return c-=v,a>>=v}function D(v){for(;c<v;)a|=e[m++]<<c,c+=8;var C=a&E[v];return a>>=v,c-=v,C}function q(v,C,N){var g,T;if(N===0)return 0;for(var F=0;;){for(T=p.list[b(y)&E[y]],g=T.extra;g>16;){if(g===99)return-1;O(T.bitcnt),g-=16,T=T.next[b(g)&E[g]],g=T.extra}if(O(T.bitcnt),g===16){if(n&=t-1,v[C+F++]=r[n++]=T.lbase,F===N)return N;continue}if(g===15)break;for(d=T.lbase+D(g),T=f.list[b(w)&E[w]],g=T.extra;g>16;){if(g===99)return-1;O(T.bitcnt),g-=16,T=T.next[b(g)&E[g]],g=T.extra}for(O(T.bitcnt),h=n-T.lbase-D(g);d>0&&F<N;)d--,h&=t-1,n&=t-1,v[C+F++]=r[n++]=r[h++];if(F===N)return N}return u=-1,F}function U(v,C,N){O(c&7);var g=D(16);if(g!==(~D(16)&65535))return-1;for(d=g,g=0;d>0&&g<N;)d--,n&=t-1,v[C+g++]=r[n++]=D(8);return d===0&&(u=-1),g}function $(v,C,N){var g=0;if(o==null){for(var T=[],F=0;F<144;F++)T[F]=8;for(;F<256;F++)T[F]=9;for(;F<280;F++)T[F]=7;for(;F<288;F++)T[F]=8;s=7;var Q=new ye(T,288,257,L,B,s);if(Q.status!==0)return-1;for(o=Q.r,s=Q.maxbit,F=0;F<30;F++)T[F]=5;if(g=5,Q=new ye(T,30,0,pe,j,g),Q.status>1)return o=null,-1;i=Q.r,g=Q.maxbit}return p=o,f=i,y=s,w=g,q(v,C,N)}function A(v,C,N){for(var g=new Array(572),T=0;T<572;T++)g[T]=0;var F=257+D(5),Q=1+D(5),Oe=4+D(4);if(F>286||Q>30)return-1;for(var k=0;k<Oe;k++)g[oe[k]]=D(3);for(;k<19;k++)g[oe[k]]=0;y=7;var z=new ye(g,19,19,null,null,y);if(z.status!==0)return-1;p=z.r,y=z.maxbit;for(var ee=F+Q,M=0,ge=0;M<ee;){var Z=p.list[b(y)&E[y]];if(k=Z.bitcnt,O(k),k=Z.lbase,k<16)g[M++]=ge=k;else if(k===16){if(k=3+D(2),M+k>ee)return-1;for(;k-- >0;)g[M++]=ge}else if(k===17){if(k=3+D(3),M+k>ee)return-1;for(;k-- >0;)g[M++]=0;ge=0}else{if(k=11+D(7),M+k>ee)return-1;for(;k-- >0;)g[M++]=0;ge=0}}if(y=9,z=new ye(g,F,257,L,B,y),y===0&&(z.status=1),z.status!==0)return-1;for(p=z.r,y=z.maxbit,M=0;M<Q;M++)g[M]=g[M+F];return w=6,z=new ye(g,Q,0,pe,j,w),f=z.r,w=z.maxbit,w===0&&F>257||z.status!==0?-1:q(v,C,N)}return{inflate:function(v){p=null;for(var C=v.length,N=0,g;N<C;){if(l&&u===-1)return;if(d>0){if(u!==0)for(;d>0&&N<C;)d--,h&=t-1,n&=t-1,v[N++]=r[n++]=r[h++];else{for(;d>0&&N<C;)d--,n&=t-1,v[N++]=r[n++]=D(8);d===0&&(u=-1)}if(N===C)return}if(u===-1){if(l)break;l=D(1)!==0,u=D(2),p=null,d=0}switch(u){case 0:g=U(v,N,C-N);break;case 1:g=p!=null?q(v,N,C-N):$(v,N,C-N);break;case 2:g=p!=null?q(v,N,C-N):A(v,N,C-N);break;default:g=-1;break}if(g===-1)return;N+=g}}}}Fs.exports=function(e){var t=require("zlib");return{inflateAsync:function(r){var n=t.createInflateRaw(),o=[],i=0;n.on("data",function(s){o.push(s),i+=s.length}),n.on("end",function(){var s=Ls.alloc(i),a=0;s.fill(0);for(var c=0;c<o.length;c++){var u=o[c];u.copy(s,a),a+=u.length}r&&r(s)}),n.end(e)},inflate:function(r){var n={x:new gf(e)};n.x.inflate(r),delete n.x}}}});var Ts=S(Fr=>{Fr.Deflater=Is();Fr.Inflater=_s()});var _r=S((yd,ks)=>{var W=Ke(),wf=Lr(),he=W.Constants,As=Ts();ks.exports=function(e){var t=new wf.EntryHeader,r=Buffer.alloc(0),n=Buffer.alloc(0),o=!1,i=null,s=Buffer.alloc(0);function a(){return!e||!Buffer.isBuffer(e)?Buffer.alloc(0):(t.loadDataHeaderFromBinary(e),e.slice(t.realDataOffset,t.realDataOffset+t.compressedSize))}function c(f){return!((t.flags&8)!==8&&W.crc32(f)!==t.crc)}function u(f,y,w){if(typeof y>"u"&&typeof f=="string"&&(w=f,f=void 0),o)return f&&y&&y(Buffer.alloc(0),W.Errors.DIRECTORY_CONTENT_ERROR),Buffer.alloc(0);var m=a();if(m.length===0)return f&&y&&y(m,W.Errors.NO_DATA),m;var E=Buffer.alloc(t.size);switch(t.method){case W.Constants.STORED:return m.copy(E),c(E)?(f&&y&&y(E),E):(f&&y&&y(E,W.Errors.BAD_CRC),W.Errors.BAD_CRC);case W.Constants.DEFLATED:var L=new As.Inflater(m);if(f)L.inflateAsync(function(B){B.copy(E,0),c(E)?y&&y(E):y&&y(E,W.Errors.BAD_CRC)});else return L.inflate(E),c(E)||console.warn(W.Errors.BAD_CRC+" "+r.toString()),E;break;default:return f&&y&&y(Buffer.alloc(0),W.Errors.UNKNOWN_METHOD),W.Errors.UNKNOWN_METHOD}}function l(f,y){if((!i||!i.length)&&Buffer.isBuffer(e))return f&&y&&y(a()),a();if(i.length&&!o){var w;switch(t.method){case W.Constants.STORED:return t.compressedSize=t.size,w=Buffer.alloc(i.length),i.copy(w),f&&y&&y(w),w;default:case W.Constants.DEFLATED:var m=new As.Deflater(i);if(f)m.deflateAsync(function(L){w=Buffer.alloc(L.length),t.compressedSize=L.length,L.copy(w),y&&y(w)});else{var E=m.deflate();return t.compressedSize=E.length,E}m=null;break}}else if(f&&y)y(Buffer.alloc(0));else return Buffer.alloc(0)}function d(f,y){return(f.readUInt32LE(y+4)<<4)+f.readUInt32LE(y)}function h(f){for(var y=0,w,m,E;y<f.length;)w=f.readUInt16LE(y),y+=2,m=f.readUInt16LE(y),y+=2,E=f.slice(y,y+m),y+=m,he.ID_ZIP64===w&&p(E)}function p(f){var y,w,m,E;f.length>=he.EF_ZIP64_SCOMP&&(y=d(f,he.EF_ZIP64_SUNCOMP),t.size===he.EF_ZIP64_OR_32&&(t.size=y)),f.length>=he.EF_ZIP64_RHO&&(w=d(f,he.EF_ZIP64_SCOMP),t.compressedSize===he.EF_ZIP64_OR_32&&(t.compressedSize=w)),f.length>=he.EF_ZIP64_DSN&&(m=d(f,he.EF_ZIP64_RHO),t.offset===he.EF_ZIP64_OR_32&&(t.offset=m)),f.length>=he.EF_ZIP64_DSN+4&&(E=f.readUInt32LE(he.EF_ZIP64_DSN),t.diskNumStart===he.EF_ZIP64_OR_16&&(t.diskNumStart=E))}return{get entryName(){return r.toString()},get rawEntryName(){return r},set entryName(f){r=W.toBuffer(f);var y=r[r.length-1];o=y===47||y===92,t.fileNameLength=r.length},get extra(){return s},set extra(f){s=f,t.extraLength=f.length,h(f)},get comment(){return n.toString()},set comment(f){n=W.toBuffer(f),t.commentLength=n.length},get name(){var f=r.toString();return o?f.substr(f.length-1).split("/").pop():f.split("/").pop()},get isDirectory(){return o},getCompressedData:function(){return l(!1,null)},getCompressedDataAsync:function(f){l(!0,f)},setData:function(f){i=W.toBuffer(f),!o&&i.length?(t.size=i.length,t.method=W.Constants.STORED,t.crc=W.crc32(f),t.changed=!0):t.method=W.Constants.STORED},getData:function(f){return t.changed?i:u(!1,null,f)},getDataAsync:function(f,y){t.changed?f(i):u(!0,f,y)},set attr(f){t.attr=f},get attr(){return t.attr},set header(f){t.loadFromBinary(f)},get header(){return t},packHeader:function(){var f=t.entryHeaderToBinary();return r.copy(f,W.Constants.CENHDR),t.extraLength&&s.copy(f,W.Constants.CENHDR+r.length),t.commentLength&&n.copy(f,W.Constants.CENHDR+r.length+t.extraLength,n.length),f},toString:function(){return`{
40
40
  "entryName" : "`+r.toString()+`",
41
41
  "name" : "`+(o?r.toString().replace(/\/$/,"").split("/").pop():r.toString().split("/").pop())+`",
42
42
  "comment" : "`+n.toString()+`",
@@ -44,33 +44,33 @@ tell application "System Events" to get value of property list item "CFBundleNam
44
44
  "header" : `+t.toString().replace(/\t/mg," ").replace(/}/mg," }")+`,
45
45
  "compressedData" : <`+(e&&e.length+" bytes buffer"||"null")+`>
46
46
  "data" : <`+(i&&i.length+" bytes buffer"||"null")+`>
47
- }`}}}});var Us=S((Sd,qs)=>{var vf=Ar(),Cf=_r(),Ee=Ke();qs.exports=function(e,t){var r=[],n={},o=Buffer.alloc(0),i="",s=Ee.FileSystem.require(),a=null,c=new Cf.MainHeader;t===Ee.Constants.FILE?(i=e,a=s.readFileSync(i),l()):t===Ee.Constants.BUFFER&&(a=e,l());function u(){n={},r=new Array(c.diskEntries);for(var d=c.offset,h=0;h<r.length;h++){var p=d,f=new vf(a);f.header=a.slice(p,p+=Ee.Constants.CENHDR),f.entryName=a.slice(p,p+=f.header.fileNameLength),f.header.extraLength&&(f.extra=a.slice(p,p+=f.header.extraLength)),f.header.commentLength&&(f.comment=a.slice(p,p+f.header.commentLength)),d+=f.header.entryHeaderSize,r[h]=f,n[f.entryName]=f}}function l(){var d=a.length-Ee.Constants.ENDHDR,h=Math.max(0,d-65535),p=-1;for(d;d>=h;d--)if(a[d]===80&&a.readUInt32LE(d)===Ee.Constants.ENDSIG){p=d;break}if(!~p)throw Ee.Errors.INVALID_FORMAT;c.loadFromBinary(a.slice(p,p+Ee.Constants.ENDHDR)),c.commentLength&&(o=a.slice(p+Ee.Constants.ENDHDR)),u()}return{get entries(){return r},get comment(){return o.toString()},set comment(d){c.commentLength=d.length,o=d},getEntry:function(d){return n[d]||null},setEntry:function(d){r.push(d),n[d.entryName]=d,c.totalEntries=r.length},deleteEntry:function(d){var h=n[d];if(h&&h.isDirectory){var p=this;this.getEntryChildren(h).forEach(function(f){f.entryName!==d&&p.deleteEntry(f.entryName)})}r.splice(r.indexOf(h),1),delete n[d],c.totalEntries=r.length},getEntryChildren:function(d){if(d.isDirectory){var h=[],p=d.entryName,f=p.length;return r.forEach(function(y){y.entryName.substr(0,f)===p&&h.push(y)}),h}return[]},compressToBuffer:function(){r.length>1&&r.sort(function(m,E){var L=m.entryName.toLowerCase(),B=E.entryName.toLowerCase();return L<B?-1:L>B?1:0});var d=0,h=[],p=[],f=0;c.size=0,c.offset=0,r.forEach(function(m){var E=m.getCompressedData();m.header.offset=f;var L=m.header.dataHeaderToBinary(),B=m.entryName+m.extra.toString(),pe=Buffer.alloc(B.length,B),j=L.length+pe.length+E.length;f+=j,h.push(L),h.push(pe),h.push(E);var oe=m.packHeader();p.push(oe),c.size+=oe.length,d+=j+oe.length}),d+=c.mainHeaderSize,c.offset=f,f=0;var y=Buffer.alloc(d);h.forEach(function(m){m.copy(y,f),f+=m.length}),p.forEach(function(m){m.copy(y,f),f+=m.length});var w=c.toBinary();return o&&o.copy(w,Ee.Constants.ENDHDR),w.copy(y,f),y},toAsyncBuffer:function(d,h,p,f){r.length>1&&r.sort(function(B,pe){var j=B.entryName.toLowerCase(),oe=pe.entryName.toLowerCase();return j>oe?-1:j<oe?1:0});var y=0,w=[],m=[],E=0;c.size=0,c.offset=0;var L=function(B){var pe=arguments.callee;if(B.length){var j=B.pop(),oe=j.entryName+j.extra.toString();p&&p(oe),j.getCompressedDataAsync(function(ye){f&&f(oe),j.header.offset=E;var b=j.header.dataHeaderToBinary(),O=Buffer.alloc(oe),D=b.length+O.length+ye.length;E+=D,w.push(b),w.push(O),w.push(ye);var q=j.packHeader();if(m.push(q),c.size+=q.length,y+=D+q.length,B.length)pe(B);else{y+=c.mainHeaderSize,c.offset=E,E=0;var U=Buffer.alloc(y);w.forEach(function(A){A.copy(U,E),E+=A.length}),m.forEach(function(A){A.copy(U,E),E+=A.length});var $=c.toBinary();o&&o.copy($,Ee.Constants.ENDHDR),$.copy(U,E),d(U)}})}};L(r)}}}});var $s=S((vd,Bs)=>{var V=Ke(),Se=V.FileSystem.require(),le=require("path");Se.existsSync=Se.existsSync||le.existsSync;var bf=Ar(),kr=Us(),xd=/^win/.test(process.platform);Bs.exports=function(e){var t=void 0,r="";if(e&&typeof e=="string")if(Se.existsSync(e))r=e,t=new kr(e,V.Constants.FILE);else throw V.Errors.INVALID_FILENAME;else e&&Buffer.isBuffer(e)?t=new kr(e,V.Constants.BUFFER):t=new kr(null,V.Constants.NONE);function n(i,s){i=le.resolve(le.normalize(i));for(var a=s.split("/"),c=0,u=a.length;c<u;c++){var l=le.normalize(le.join(i,a.slice(c,u).join(le.sep)));if(l.indexOf(i)===0)return l}return le.normalize(le.join(i,le.basename(s)))}function o(i){if(i&&t){var s;if(typeof i=="string"&&(s=t.getEntry(i)),typeof i=="object"&&typeof i.entryName<"u"&&typeof i.header<"u"&&(s=t.getEntry(i.entryName)),s)return s}return null}return{readFile:function(i){var s=o(i);return s&&s.getData()||null},readFileAsync:function(i,s){var a=o(i);a?a.getDataAsync(s):s(null,"getEntry failed for:"+i)},readAsText:function(i,s){var a=o(i);if(a){var c=a.getData();if(c&&c.length)return c.toString(s||"utf8")}return""},readAsTextAsync:function(i,s,a){var c=o(i);c?c.getDataAsync(function(u){u&&u.length?s(u.toString(a||"utf8")):s("")}):s("")},deleteFile:function(i){var s=o(i);s&&t.deleteEntry(s.entryName)},addZipComment:function(i){t.comment=i},getZipComment:function(){return t.comment||""},addZipEntryComment:function(i,s){var a=o(i);a&&(a.comment=s)},getZipEntryComment:function(i){var s=o(i);return s&&s.comment||""},updateFile:function(i,s){var a=o(i);a&&a.setData(s)},addLocalFile:function(i,s,a){if(Se.existsSync(i)){s?(s=s.split("\\").join("/"),s.charAt(s.length-1)!=="/"&&(s+="/")):s="";var c=i.split("\\").join("/").split("/").pop();a?this.addFile(s+a,Se.readFileSync(i),"",0):this.addFile(s+c,Se.readFileSync(i),"",0)}else throw V.Errors.FILE_NOT_FOUND.replace("%s",i)},addLocalFolder:function(i,s,a){if(a===void 0?a=function(){return!0}:a instanceof RegExp&&(a=function(l){return function(d){return l.test(d)}}(a)),s?(s=s.split("\\").join("/"),s.charAt(s.length-1)!=="/"&&(s+="/")):s="",i=le.normalize(i),i=i.split("\\").join("/"),i.charAt(i.length-1)!=="/"&&(i+="/"),Se.existsSync(i)){var c=V.findFiles(i),u=this;c.length&&c.forEach(function(l){var d=l.split("\\").join("/").replace(new RegExp(i.replace(/(\(|\))/g,"\\$1"),"i"),"");a(d)&&(d.charAt(d.length-1)!=="/"?u.addFile(s+d,Se.readFileSync(l),"",0):u.addFile(s+d,Buffer.alloc(0),"",0))})}else throw V.Errors.FILE_NOT_FOUND.replace("%s",i)},addFile:function(i,s,a,c){var u=new bf;u.entryName=i,u.comment=a||"",c||(u.isDirectory?c=16877<<16|16:c=420<<16),u.attr=c,u.setData(s),t.setEntry(u)},getEntries:function(){return t?t.entries:[]},getEntry:function(i){return o(i)},extractEntryTo:function(i,s,a,c){c=c||!1,a=typeof a>"u"?!0:a;var u=o(i);if(!u)throw V.Errors.NO_ENTRY;var l=u.entryName,d=n(s,a?l:le.basename(l));if(u.isDirectory){d=le.resolve(d,"..");var h=t.getEntryChildren(u);return h.forEach(function(f){if(!f.isDirectory){var y=f.getData();if(!y)throw V.Errors.CANT_EXTRACT_FILE;var w=n(s,a?f.entryName:le.basename(f.entryName));V.writeFileTo(w,y,c)}}),!0}var p=u.getData();if(!p)throw V.Errors.CANT_EXTRACT_FILE;if(Se.existsSync(d)&&!c)throw V.Errors.CANT_OVERRIDE;return V.writeFileTo(d,p,c),!0},test:function(){if(!t)return!1;for(var i in t.entries)try{if(i.isDirectory)continue;var s=t.entries[i].getData();if(!s)return!1}catch{return!1}return!0},extractAllTo:function(i,s){if(s=s||!1,!t)throw V.Errors.NO_ZIP;t.entries.forEach(function(a){var c=n(i,a.entryName.toString());if(a.isDirectory){V.makeDir(c);return}var u=a.getData();if(!u)throw V.Errors.CANT_EXTRACT_FILE;V.writeFileTo(c,u,s),Se.utimesSync(c,a.header.time,a.header.time)})},extractAllToAsync:function(i,s,a){if(a||(a=function(){}),s=s||!1,!t){a(new Error(V.Errors.NO_ZIP));return}var c=t.entries,u=c.length;c.forEach(function(l){if(!(u<=0)){var d=le.normalize(l.entryName.toString());if(l.isDirectory){V.makeDir(n(i,d)),--u===0&&a(void 0);return}l.getDataAsync(function(h){if(!(u<=0)){if(!h){u=0,a(new Error(V.Errors.CANT_EXTRACT_FILE));return}V.writeFileToAsync(n(i,d),h,s,function(p){if(Se.utimesSync(le.resolve(i,d),l.header.time,l.header.time),!(u<=0)){if(!p){u=0,a(new Error("Unable to write"));return}--u===0&&a(void 0)}})}})}})},writeZip:function(i,s){if(arguments.length===1&&typeof i=="function"&&(s=i,i=""),!i&&r&&(i=r),!!i){var a=t.compressToBuffer();if(a){var c=V.writeFileTo(i,a,!0);typeof s=="function"&&s(c?null:new Error("failed"),"")}}},toBuffer:function(i,s,a,c){return this.valueOf=2,typeof i=="function"?(t.toAsyncBuffer(i,s,a,c),null):t.compressToBuffer()}}}});var G=require("node:path"),Ut=require("node:child_process"),Gs=require("node:os"),Y=X(Ri());var Ui=require("events");function tr(e){return e==null?[]:Array.isArray(e)?e:[e]}function yu(e,t,r,n){var o,i=e[t],s=~n.string.indexOf(t)?r==null||r===!0?"":String(r):typeof r=="boolean"?r:~n.boolean.indexOf(t)?r==="false"?!1:r==="true"||(e._.push((o=+r,o*0===0?o:r)),!!r):(o=+r,o*0===0?o:r);e[t]=i==null?s:Array.isArray(i)?i.concat(s):[i,s]}function gu(e,t){e=e||[],t=t||{};var r,n,o,i,s,a={_:[]},c=0,u=0,l=0,d=e.length;let h=t.alias!==void 0,p=t.unknown!==void 0,f=t.default!==void 0;if(t.alias=t.alias||{},t.string=tr(t.string),t.boolean=tr(t.boolean),h)for(r in t.alias)for(n=t.alias[r]=tr(t.alias[r]),c=0;c<n.length;c++)(t.alias[n[c]]=n.concat(r)).splice(c,1);for(c=t.boolean.length;c-- >0;)for(n=t.alias[t.boolean[c]]||[],u=n.length;u-- >0;)t.boolean.push(n[u]);for(c=t.string.length;c-- >0;)for(n=t.alias[t.string[c]]||[],u=n.length;u-- >0;)t.string.push(n[u]);if(f){for(r in t.default)if(i=typeof t.default[r],n=t.alias[r]=t.alias[r]||[],t[i]!==void 0)for(t[i].push(r),c=0;c<n.length;c++)t[i].push(n[c])}let y=p?Object.keys(t.alias):[];for(c=0;c<d;c++){if(o=e[c],o==="--"){a._=a._.concat(e.slice(++c));break}for(u=0;u<o.length&&o.charCodeAt(u)===45;u++);if(u===0)a._.push(o);else if(o.substring(u,u+3)==="no-"){if(i=o.substring(u+3),p&&!~y.indexOf(i))return t.unknown(o);a[i]=!1}else{for(l=u+1;l<o.length&&o.charCodeAt(l)!==61;l++);for(i=o.substring(u,l),s=o.substring(++l)||c+1===d||(""+e[c+1]).charCodeAt(0)===45||e[++c],n=u===2?[i]:i,l=0;l<n.length;l++){if(i=n[l],p&&!~y.indexOf(i))return t.unknown("-".repeat(u)+i);yu(a,i,l+1<n.length||s,t)}}}if(f)for(r in t.default)a[r]===void 0&&(a[r]=t.default[r]);if(h)for(r in a)for(n=t.alias[r]||[];n.length>0;)a[n.shift()]=a[r];return a}var Bi=e=>e.replace(/[<[].+/,"").trim(),wu=e=>{let t=/<([^>]+)>/g,r=/\[([^\]]+)\]/g,n=[],o=a=>{let c=!1,u=a[1];return u.startsWith("...")&&(u=u.slice(3),c=!0),{required:a[0].startsWith("<"),value:u,variadic:c}},i;for(;i=t.exec(e);)n.push(o(i));let s;for(;s=r.exec(e);)n.push(o(s));return n},Eu=e=>{let t={alias:{},boolean:[]};for(let[r,n]of e.entries())n.names.length>1&&(t.alias[n.names[0]]=n.names.slice(1)),n.isBoolean&&(n.negated&&e.some((i,s)=>s!==r&&i.names.some(a=>n.names.includes(a))&&typeof i.required=="boolean")||t.boolean.push(n.names[0]));return t},Pi=e=>e.sort((t,r)=>t.length>r.length?-1:1)[0],qi=(e,t)=>e.length>=t?e:`${e}${" ".repeat(t-e.length)}`,Su=e=>e.replace(/([a-z])-([a-z])/g,(t,r,n)=>r+n.toUpperCase()),xu=(e,t,r)=>{let n=0,o=t.length,i=e,s;for(;n<o;++n)s=i[t[n]],i=i[t[n]]=n===o-1?r:s??(~t[n+1].indexOf(".")||!(+t[n+1]>-1)?{}:[])},vu=(e,t)=>{for(let r of Object.keys(t)){let n=t[r];n.shouldTransform&&(e[r]=Array.prototype.concat.call([],e[r]),typeof n.transformFunction=="function"&&(e[r]=e[r].map(n.transformFunction)))}},Cu=e=>{let t=/([^\\\/]+)$/.exec(e);return t?t[1]:""},$i=e=>e.split(".").map((t,r)=>r===0?Su(t):t).join("."),st=class extends Error{constructor(t){super(t),this.name=this.constructor.name,typeof Error.captureStackTrace=="function"?Error.captureStackTrace(this,this.constructor):this.stack=new Error(t).stack}},rr=class{constructor(t,r,n){this.rawName=t,this.description=r,this.config=Object.assign({},n),t=t.replace(/\.\*/g,""),this.negated=!1,this.names=Bi(t).split(",").map(o=>{let i=o.trim().replace(/^-{1,2}/,"");return i.startsWith("no-")&&(this.negated=!0,i=i.replace(/^no-/,"")),$i(i)}).sort((o,i)=>o.length>i.length?1:-1),this.name=this.names[this.names.length-1],this.negated&&this.config.default==null&&(this.config.default=!0),t.includes("<")?this.required=!0:t.includes("[")?this.required=!1:this.isBoolean=!0}},bu=process.argv,Nu=`${process.platform}-${process.arch} node-${process.version}`,Dt=class{constructor(t,r,n={},o){this.rawName=t,this.description=r,this.config=n,this.cli=o,this.options=[],this.aliasNames=[],this.name=Bi(t),this.args=wu(t),this.examples=[]}usage(t){return this.usageText=t,this}allowUnknownOptions(){return this.config.allowUnknownOptions=!0,this}ignoreOptionDefaultValue(){return this.config.ignoreOptionDefaultValue=!0,this}version(t,r="-v, --version"){return this.versionNumber=t,this.option(r,"Display version number"),this}example(t){return this.examples.push(t),this}option(t,r,n){let o=new rr(t,r,n);return this.options.push(o),this}alias(t){return this.aliasNames.push(t),this}action(t){return this.commandAction=t,this}isMatched(t){return this.name===t||this.aliasNames.includes(t)}get isDefaultCommand(){return this.name===""||this.aliasNames.includes("!")}get isGlobalCommand(){return this instanceof Ot}hasOption(t){return t=t.split(".")[0],this.options.find(r=>r.names.includes(t))}outputHelp(){let{name:t,commands:r}=this.cli,{versionNumber:n,options:o,helpCallback:i}=this.cli.globalCommand,s=[{body:`${t}${n?`/${n}`:""}`}];if(s.push({title:"Usage",body:` $ ${t} ${this.usageText||this.rawName}`}),(this.isGlobalCommand||this.isDefaultCommand)&&r.length>0){let u=Pi(r.map(l=>l.rawName));s.push({title:"Commands",body:r.map(l=>` ${qi(l.rawName,u.length)} ${l.description}`).join(`
47
+ }`}}}});var Ps=S((gd,Rs)=>{var Ef=_r(),Sf=Lr(),Ee=Ke();Rs.exports=function(e,t){var r=[],n={},o=Buffer.alloc(0),i="",s=Ee.FileSystem.require(),a=null,c=new Sf.MainHeader;t===Ee.Constants.FILE?(i=e,a=s.readFileSync(i),l()):t===Ee.Constants.BUFFER&&(a=e,l());function u(){n={},r=new Array(c.diskEntries);for(var d=c.offset,h=0;h<r.length;h++){var p=d,f=new Ef(a);f.header=a.slice(p,p+=Ee.Constants.CENHDR),f.entryName=a.slice(p,p+=f.header.fileNameLength),f.header.extraLength&&(f.extra=a.slice(p,p+=f.header.extraLength)),f.header.commentLength&&(f.comment=a.slice(p,p+f.header.commentLength)),d+=f.header.entryHeaderSize,r[h]=f,n[f.entryName]=f}}function l(){var d=a.length-Ee.Constants.ENDHDR,h=Math.max(0,d-65535),p=-1;for(d;d>=h;d--)if(a[d]===80&&a.readUInt32LE(d)===Ee.Constants.ENDSIG){p=d;break}if(!~p)throw Ee.Errors.INVALID_FORMAT;c.loadFromBinary(a.slice(p,p+Ee.Constants.ENDHDR)),c.commentLength&&(o=a.slice(p+Ee.Constants.ENDHDR)),u()}return{get entries(){return r},get comment(){return o.toString()},set comment(d){c.commentLength=d.length,o=d},getEntry:function(d){return n[d]||null},setEntry:function(d){r.push(d),n[d.entryName]=d,c.totalEntries=r.length},deleteEntry:function(d){var h=n[d];if(h&&h.isDirectory){var p=this;this.getEntryChildren(h).forEach(function(f){f.entryName!==d&&p.deleteEntry(f.entryName)})}r.splice(r.indexOf(h),1),delete n[d],c.totalEntries=r.length},getEntryChildren:function(d){if(d.isDirectory){var h=[],p=d.entryName,f=p.length;return r.forEach(function(y){y.entryName.substr(0,f)===p&&h.push(y)}),h}return[]},compressToBuffer:function(){r.length>1&&r.sort(function(m,E){var L=m.entryName.toLowerCase(),B=E.entryName.toLowerCase();return L<B?-1:L>B?1:0});var d=0,h=[],p=[],f=0;c.size=0,c.offset=0,r.forEach(function(m){var E=m.getCompressedData();m.header.offset=f;var L=m.header.dataHeaderToBinary(),B=m.entryName+m.extra.toString(),pe=Buffer.alloc(B.length,B),j=L.length+pe.length+E.length;f+=j,h.push(L),h.push(pe),h.push(E);var oe=m.packHeader();p.push(oe),c.size+=oe.length,d+=j+oe.length}),d+=c.mainHeaderSize,c.offset=f,f=0;var y=Buffer.alloc(d);h.forEach(function(m){m.copy(y,f),f+=m.length}),p.forEach(function(m){m.copy(y,f),f+=m.length});var w=c.toBinary();return o&&o.copy(w,Ee.Constants.ENDHDR),w.copy(y,f),y},toAsyncBuffer:function(d,h,p,f){r.length>1&&r.sort(function(B,pe){var j=B.entryName.toLowerCase(),oe=pe.entryName.toLowerCase();return j>oe?-1:j<oe?1:0});var y=0,w=[],m=[],E=0;c.size=0,c.offset=0;var L=function(B){var pe=arguments.callee;if(B.length){var j=B.pop(),oe=j.entryName+j.extra.toString();p&&p(oe),j.getCompressedDataAsync(function(ye){f&&f(oe),j.header.offset=E;var b=j.header.dataHeaderToBinary(),O=Buffer.alloc(oe),D=b.length+O.length+ye.length;E+=D,w.push(b),w.push(O),w.push(ye);var q=j.packHeader();if(m.push(q),c.size+=q.length,y+=D+q.length,B.length)pe(B);else{y+=c.mainHeaderSize,c.offset=E,E=0;var U=Buffer.alloc(y);w.forEach(function(A){A.copy(U,E),E+=A.length}),m.forEach(function(A){A.copy(U,E),E+=A.length});var $=c.toBinary();o&&o.copy($,Ee.Constants.ENDHDR),$.copy(U,E),d(U)}})}};L(r)}}}});var Us=S((Ed,qs)=>{var V=Ke(),Se=V.FileSystem.require(),le=require("path");Se.existsSync=Se.existsSync||le.existsSync;var xf=_r(),Tr=Ps(),wd=/^win/.test(process.platform);qs.exports=function(e){var t=void 0,r="";if(e&&typeof e=="string")if(Se.existsSync(e))r=e,t=new Tr(e,V.Constants.FILE);else throw V.Errors.INVALID_FILENAME;else e&&Buffer.isBuffer(e)?t=new Tr(e,V.Constants.BUFFER):t=new Tr(null,V.Constants.NONE);function n(i,s){i=le.resolve(le.normalize(i));for(var a=s.split("/"),c=0,u=a.length;c<u;c++){var l=le.normalize(le.join(i,a.slice(c,u).join(le.sep)));if(l.indexOf(i)===0)return l}return le.normalize(le.join(i,le.basename(s)))}function o(i){if(i&&t){var s;if(typeof i=="string"&&(s=t.getEntry(i)),typeof i=="object"&&typeof i.entryName<"u"&&typeof i.header<"u"&&(s=t.getEntry(i.entryName)),s)return s}return null}return{readFile:function(i){var s=o(i);return s&&s.getData()||null},readFileAsync:function(i,s){var a=o(i);a?a.getDataAsync(s):s(null,"getEntry failed for:"+i)},readAsText:function(i,s){var a=o(i);if(a){var c=a.getData();if(c&&c.length)return c.toString(s||"utf8")}return""},readAsTextAsync:function(i,s,a){var c=o(i);c?c.getDataAsync(function(u){u&&u.length?s(u.toString(a||"utf8")):s("")}):s("")},deleteFile:function(i){var s=o(i);s&&t.deleteEntry(s.entryName)},addZipComment:function(i){t.comment=i},getZipComment:function(){return t.comment||""},addZipEntryComment:function(i,s){var a=o(i);a&&(a.comment=s)},getZipEntryComment:function(i){var s=o(i);return s&&s.comment||""},updateFile:function(i,s){var a=o(i);a&&a.setData(s)},addLocalFile:function(i,s,a){if(Se.existsSync(i)){s?(s=s.split("\\").join("/"),s.charAt(s.length-1)!=="/"&&(s+="/")):s="";var c=i.split("\\").join("/").split("/").pop();a?this.addFile(s+a,Se.readFileSync(i),"",0):this.addFile(s+c,Se.readFileSync(i),"",0)}else throw V.Errors.FILE_NOT_FOUND.replace("%s",i)},addLocalFolder:function(i,s,a){if(a===void 0?a=function(){return!0}:a instanceof RegExp&&(a=function(l){return function(d){return l.test(d)}}(a)),s?(s=s.split("\\").join("/"),s.charAt(s.length-1)!=="/"&&(s+="/")):s="",i=le.normalize(i),i=i.split("\\").join("/"),i.charAt(i.length-1)!=="/"&&(i+="/"),Se.existsSync(i)){var c=V.findFiles(i),u=this;c.length&&c.forEach(function(l){var d=l.split("\\").join("/").replace(new RegExp(i.replace(/(\(|\))/g,"\\$1"),"i"),"");a(d)&&(d.charAt(d.length-1)!=="/"?u.addFile(s+d,Se.readFileSync(l),"",0):u.addFile(s+d,Buffer.alloc(0),"",0))})}else throw V.Errors.FILE_NOT_FOUND.replace("%s",i)},addFile:function(i,s,a,c){var u=new xf;u.entryName=i,u.comment=a||"",c||(u.isDirectory?c=16877<<16|16:c=420<<16),u.attr=c,u.setData(s),t.setEntry(u)},getEntries:function(){return t?t.entries:[]},getEntry:function(i){return o(i)},extractEntryTo:function(i,s,a,c){c=c||!1,a=typeof a>"u"?!0:a;var u=o(i);if(!u)throw V.Errors.NO_ENTRY;var l=u.entryName,d=n(s,a?l:le.basename(l));if(u.isDirectory){d=le.resolve(d,"..");var h=t.getEntryChildren(u);return h.forEach(function(f){if(!f.isDirectory){var y=f.getData();if(!y)throw V.Errors.CANT_EXTRACT_FILE;var w=n(s,a?f.entryName:le.basename(f.entryName));V.writeFileTo(w,y,c)}}),!0}var p=u.getData();if(!p)throw V.Errors.CANT_EXTRACT_FILE;if(Se.existsSync(d)&&!c)throw V.Errors.CANT_OVERRIDE;return V.writeFileTo(d,p,c),!0},test:function(){if(!t)return!1;for(var i in t.entries)try{if(i.isDirectory)continue;var s=t.entries[i].getData();if(!s)return!1}catch{return!1}return!0},extractAllTo:function(i,s){if(s=s||!1,!t)throw V.Errors.NO_ZIP;t.entries.forEach(function(a){var c=n(i,a.entryName.toString());if(a.isDirectory){V.makeDir(c);return}var u=a.getData();if(!u)throw V.Errors.CANT_EXTRACT_FILE;V.writeFileTo(c,u,s),Se.utimesSync(c,a.header.time,a.header.time)})},extractAllToAsync:function(i,s,a){if(a||(a=function(){}),s=s||!1,!t){a(new Error(V.Errors.NO_ZIP));return}var c=t.entries,u=c.length;c.forEach(function(l){if(!(u<=0)){var d=le.normalize(l.entryName.toString());if(l.isDirectory){V.makeDir(n(i,d)),--u===0&&a(void 0);return}l.getDataAsync(function(h){if(!(u<=0)){if(!h){u=0,a(new Error(V.Errors.CANT_EXTRACT_FILE));return}V.writeFileToAsync(n(i,d),h,s,function(p){if(Se.utimesSync(le.resolve(i,d),l.header.time,l.header.time),!(u<=0)){if(!p){u=0,a(new Error("Unable to write"));return}--u===0&&a(void 0)}})}})}})},writeZip:function(i,s){if(arguments.length===1&&typeof i=="function"&&(s=i,i=""),!i&&r&&(i=r),!!i){var a=t.compressToBuffer();if(a){var c=V.writeFileTo(i,a,!0);typeof s=="function"&&s(c?null:new Error("failed"),"")}}},toBuffer:function(i,s,a,c){return this.valueOf=2,typeof i=="function"?(t.toAsyncBuffer(i,s,a,c),null):t.compressToBuffer()}}}});var G=require("node:path"),Ut=require("node:child_process"),Ws=require("node:os"),Y=X(Ai());var Pi=require("events");function tr(e){return e==null?[]:Array.isArray(e)?e:[e]}function hu(e,t,r,n){var o,i=e[t],s=~n.string.indexOf(t)?r==null||r===!0?"":String(r):typeof r=="boolean"?r:~n.boolean.indexOf(t)?r==="false"?!1:r==="true"||(e._.push((o=+r,o*0===0?o:r)),!!r):(o=+r,o*0===0?o:r);e[t]=i==null?s:Array.isArray(i)?i.concat(s):[i,s]}function pu(e,t){e=e||[],t=t||{};var r,n,o,i,s,a={_:[]},c=0,u=0,l=0,d=e.length;let h=t.alias!==void 0,p=t.unknown!==void 0,f=t.default!==void 0;if(t.alias=t.alias||{},t.string=tr(t.string),t.boolean=tr(t.boolean),h)for(r in t.alias)for(n=t.alias[r]=tr(t.alias[r]),c=0;c<n.length;c++)(t.alias[n[c]]=n.concat(r)).splice(c,1);for(c=t.boolean.length;c-- >0;)for(n=t.alias[t.boolean[c]]||[],u=n.length;u-- >0;)t.boolean.push(n[u]);for(c=t.string.length;c-- >0;)for(n=t.alias[t.string[c]]||[],u=n.length;u-- >0;)t.string.push(n[u]);if(f){for(r in t.default)if(i=typeof t.default[r],n=t.alias[r]=t.alias[r]||[],t[i]!==void 0)for(t[i].push(r),c=0;c<n.length;c++)t[i].push(n[c])}let y=p?Object.keys(t.alias):[];for(c=0;c<d;c++){if(o=e[c],o==="--"){a._=a._.concat(e.slice(++c));break}for(u=0;u<o.length&&o.charCodeAt(u)===45;u++);if(u===0)a._.push(o);else if(o.substring(u,u+3)==="no-"){if(i=o.substring(u+3),p&&!~y.indexOf(i))return t.unknown(o);a[i]=!1}else{for(l=u+1;l<o.length&&o.charCodeAt(l)!==61;l++);for(i=o.substring(u,l),s=o.substring(++l)||c+1===d||(""+e[c+1]).charCodeAt(0)===45||e[++c],n=u===2?[i]:i,l=0;l<n.length;l++){if(i=n[l],p&&!~y.indexOf(i))return t.unknown("-".repeat(u)+i);hu(a,i,l+1<n.length||s,t)}}}if(f)for(r in t.default)a[r]===void 0&&(a[r]=t.default[r]);if(h)for(r in a)for(n=t.alias[r]||[];n.length>0;)a[n.shift()]=a[r];return a}var qi=e=>e.replace(/[<[].+/,"").trim(),yu=e=>{let t=/<([^>]+)>/g,r=/\[([^\]]+)\]/g,n=[],o=a=>{let c=!1,u=a[1];return u.startsWith("...")&&(u=u.slice(3),c=!0),{required:a[0].startsWith("<"),value:u,variadic:c}},i;for(;i=t.exec(e);)n.push(o(i));let s;for(;s=r.exec(e);)n.push(o(s));return n},gu=e=>{let t={alias:{},boolean:[]};for(let[r,n]of e.entries())n.names.length>1&&(t.alias[n.names[0]]=n.names.slice(1)),n.isBoolean&&(n.negated&&e.some((i,s)=>s!==r&&i.names.some(a=>n.names.includes(a))&&typeof i.required=="boolean")||t.boolean.push(n.names[0]));return t},ki=e=>e.sort((t,r)=>t.length>r.length?-1:1)[0],Ri=(e,t)=>e.length>=t?e:`${e}${" ".repeat(t-e.length)}`,wu=e=>e.replace(/([a-z])-([a-z])/g,(t,r,n)=>r+n.toUpperCase()),Eu=(e,t,r)=>{let n=0,o=t.length,i=e,s;for(;n<o;++n)s=i[t[n]],i=i[t[n]]=n===o-1?r:s??(~t[n+1].indexOf(".")||!(+t[n+1]>-1)?{}:[])},Su=(e,t)=>{for(let r of Object.keys(t)){let n=t[r];n.shouldTransform&&(e[r]=Array.prototype.concat.call([],e[r]),typeof n.transformFunction=="function"&&(e[r]=e[r].map(n.transformFunction)))}},xu=e=>{let t=/([^\\\/]+)$/.exec(e);return t?t[1]:""},Ui=e=>e.split(".").map((t,r)=>r===0?wu(t):t).join("."),st=class extends Error{constructor(t){super(t),this.name=this.constructor.name,typeof Error.captureStackTrace=="function"?Error.captureStackTrace(this,this.constructor):this.stack=new Error(t).stack}},rr=class{constructor(t,r,n){this.rawName=t,this.description=r,this.config=Object.assign({},n),t=t.replace(/\.\*/g,""),this.negated=!1,this.names=qi(t).split(",").map(o=>{let i=o.trim().replace(/^-{1,2}/,"");return i.startsWith("no-")&&(this.negated=!0,i=i.replace(/^no-/,"")),Ui(i)}).sort((o,i)=>o.length>i.length?1:-1),this.name=this.names[this.names.length-1],this.negated&&this.config.default==null&&(this.config.default=!0),t.includes("<")?this.required=!0:t.includes("[")?this.required=!1:this.isBoolean=!0}},vu=process.argv,Cu=`${process.platform}-${process.arch} node-${process.version}`,Dt=class{constructor(t,r,n={},o){this.rawName=t,this.description=r,this.config=n,this.cli=o,this.options=[],this.aliasNames=[],this.name=qi(t),this.args=yu(t),this.examples=[]}usage(t){return this.usageText=t,this}allowUnknownOptions(){return this.config.allowUnknownOptions=!0,this}ignoreOptionDefaultValue(){return this.config.ignoreOptionDefaultValue=!0,this}version(t,r="-v, --version"){return this.versionNumber=t,this.option(r,"Display version number"),this}example(t){return this.examples.push(t),this}option(t,r,n){let o=new rr(t,r,n);return this.options.push(o),this}alias(t){return this.aliasNames.push(t),this}action(t){return this.commandAction=t,this}isMatched(t){return this.name===t||this.aliasNames.includes(t)}get isDefaultCommand(){return this.name===""||this.aliasNames.includes("!")}get isGlobalCommand(){return this instanceof Ot}hasOption(t){return t=t.split(".")[0],this.options.find(r=>r.names.includes(t))}outputHelp(){let{name:t,commands:r}=this.cli,{versionNumber:n,options:o,helpCallback:i}=this.cli.globalCommand,s=[{body:`${t}${n?`/${n}`:""}`}];if(s.push({title:"Usage",body:` $ ${t} ${this.usageText||this.rawName}`}),(this.isGlobalCommand||this.isDefaultCommand)&&r.length>0){let u=ki(r.map(l=>l.rawName));s.push({title:"Commands",body:r.map(l=>` ${Ri(l.rawName,u.length)} ${l.description}`).join(`
48
48
  `)}),s.push({title:"For more info, run any command with the `--help` flag",body:r.map(l=>` $ ${t}${l.name===""?"":` ${l.name}`} --help`).join(`
49
- `)})}let c=this.isGlobalCommand?o:[...this.options,...o||[]];if(!this.isGlobalCommand&&!this.isDefaultCommand&&(c=c.filter(u=>u.name!=="version")),c.length>0){let u=Pi(c.map(l=>l.rawName));s.push({title:"Options",body:c.map(l=>` ${qi(l.rawName,u.length)} ${l.description} ${l.config.default===void 0?"":`(default: ${l.config.default})`}`).join(`
49
+ `)})}let c=this.isGlobalCommand?o:[...this.options,...o||[]];if(!this.isGlobalCommand&&!this.isDefaultCommand&&(c=c.filter(u=>u.name!=="version")),c.length>0){let u=ki(c.map(l=>l.rawName));s.push({title:"Options",body:c.map(l=>` ${Ri(l.rawName,u.length)} ${l.description} ${l.config.default===void 0?"":`(default: ${l.config.default})`}`).join(`
50
50
  `)})}this.examples.length>0&&s.push({title:"Examples",body:this.examples.map(u=>typeof u=="function"?u(t):u).join(`
51
51
  `)}),i&&(s=i(s)||s),console.log(s.map(u=>u.title?`${u.title}:
52
52
  ${u.body}`:u.body).join(`
53
53
 
54
- `))}outputVersion(){let{name:t}=this.cli,{versionNumber:r}=this.cli.globalCommand;r&&console.log(`${t}/${r} ${Nu}`)}checkRequiredArgs(){let t=this.args.filter(r=>r.required).length;if(this.cli.args.length<t)throw new st(`missing required args for command \`${this.rawName}\``)}checkUnknownOptions(){let{options:t,globalCommand:r}=this.cli;if(!this.config.allowUnknownOptions){for(let n of Object.keys(t))if(n!=="--"&&!this.hasOption(n)&&!r.hasOption(n))throw new st(`Unknown option \`${n.length>1?`--${n}`:`-${n}`}\``)}}checkOptionValue(){let{options:t,globalCommand:r}=this.cli,n=[...r.options,...this.options];for(let o of n){let i=t[o.name.split(".")[0]];if(o.required){let s=n.some(a=>a.negated&&a.names.includes(o.name));if(i===!0||i===!1&&!s)throw new st(`option \`${o.rawName}\` value is missing`)}}}},Ot=class extends Dt{constructor(t){super("@@global@@","",{},t)}},Nt=Object.assign,nr=class extends Ui.EventEmitter{constructor(t=""){super(),this.name=t,this.commands=[],this.rawArgs=[],this.args=[],this.options={},this.globalCommand=new Ot(this),this.globalCommand.usage("<command> [options]")}usage(t){return this.globalCommand.usage(t),this}command(t,r,n){let o=new Dt(t,r||"",n,this);return o.globalCommand=this.globalCommand,this.commands.push(o),o}option(t,r,n){return this.globalCommand.option(t,r,n),this}help(t){return this.globalCommand.option("-h, --help","Display this message"),this.globalCommand.helpCallback=t,this.showHelpOnExit=!0,this}version(t,r="-v, --version"){return this.globalCommand.version(t,r),this.showVersionOnExit=!0,this}example(t){return this.globalCommand.example(t),this}outputHelp(){this.matchedCommand?this.matchedCommand.outputHelp():this.globalCommand.outputHelp()}outputVersion(){this.globalCommand.outputVersion()}setParsedInfo({args:t,options:r},n,o){return this.args=t,this.options=r,n&&(this.matchedCommand=n),o&&(this.matchedCommandName=o),this}unsetMatchedCommand(){this.matchedCommand=void 0,this.matchedCommandName=void 0}parse(t=bu,{run:r=!0}={}){this.rawArgs=t,this.name||(this.name=t[1]?Cu(t[1]):"cli");let n=!0;for(let i of this.commands){let s=this.mri(t.slice(2),i),a=s.args[0];if(i.isMatched(a)){n=!1;let c=Nt(Nt({},s),{args:s.args.slice(1)});this.setParsedInfo(c,i,a),this.emit(`command:${a}`,i)}}if(n){for(let i of this.commands)if(i.name===""){n=!1;let s=this.mri(t.slice(2),i);this.setParsedInfo(s,i),this.emit("command:!",i)}}if(n){let i=this.mri(t.slice(2));this.setParsedInfo(i)}this.options.help&&this.showHelpOnExit&&(this.outputHelp(),r=!1,this.unsetMatchedCommand()),this.options.version&&this.showVersionOnExit&&this.matchedCommandName==null&&(this.outputVersion(),r=!1,this.unsetMatchedCommand());let o={args:this.args,options:this.options};return r&&this.runMatchedCommand(),!this.matchedCommand&&this.args[0]&&this.emit("command:*"),o}mri(t,r){let n=[...this.globalCommand.options,...r?r.options:[]],o=Eu(n),i=[],s=t.indexOf("--");s>-1&&(i=t.slice(s+1),t=t.slice(0,s));let a=gu(t,o);a=Object.keys(a).reduce((h,p)=>Nt(Nt({},h),{[$i(p)]:a[p]}),{_:[]});let c=a._,u={"--":i},l=r&&r.config.ignoreOptionDefaultValue?r.config.ignoreOptionDefaultValue:this.globalCommand.config.ignoreOptionDefaultValue,d=Object.create(null);for(let h of n){if(!l&&h.config.default!==void 0)for(let p of h.names)u[p]=h.config.default;Array.isArray(h.config.type)&&d[h.name]===void 0&&(d[h.name]=Object.create(null),d[h.name].shouldTransform=!0,d[h.name].transformFunction=h.config.type[0])}for(let h of Object.keys(a))if(h!=="_"){let p=h.split(".");xu(u,p,a[h]),vu(u,d)}return{args:c,options:u}}runMatchedCommand(){let{args:t,options:r,matchedCommand:n}=this;if(!n||!n.commandAction)return;n.checkUnknownOptions(),n.checkOptionValue(),n.checkRequiredArgs();let o=[];return n.args.forEach((i,s)=>{i.variadic?o.push(t.slice(s)):o.push(t[s])}),o.push(r),n.commandAction.apply(this,o)}},Mi=(e="")=>new nr(e);var _=X(Vi()),zs=X(Ao()),Zs=X(Bo()),Nf=!1,Rt="https",js=!0,Xs=__dirname,Df=(0,G.join)(Xs,"bin"),Bt=Mi("wallaby"),Ks=require((0,G.join)(Xs,"package.json")).version,Br=(0,G.join)((0,Gs.homedir)(),".wallaby"),Te=(0,G.join)(Br,"cli"),Pr=(0,G.join)(Te,"downloads"),Js=(0,G.join)(Br,"key.lic"),Ys=(0,G.join)(Te,"wallaby.json"),qr=(0,G.join)(Te,"core.json"),Ms=()=>Rt+"://update.wallabyjs.com/",Of=10*60*1e3,Pt,Rr=0,ft,lt;Bt.command("[root]","start wallaby").option("--doNotOpen","do not open browser on startup").option("--smart","use smart (lazy) start to run tests of modified test files only: https://wallabyjs.com/docs/intro/smart-start.html").option("--config <path>","use config file: https://wallabyjs.com/docs/config/overview.html").option("--update","force Wallaby Core update to the latest version before starting").option("--useHttp","use http instead of https for downloading Wallaby dependencies").option("--useNonStrictSSL","do not use strict SSL for downloading Wallaby dependencies").option("--suppressExpirationNotifications","do not notify about license expiration").action(async(e,t)=>{kf(t),t.useHttp&&(Rt="http"),t.useNonStrictSSL&&(js=!1),Y.default.ensureDirSync(Br),Y.default.ensureDirSync(Te),await ta(t)});Bt.help();Bt.version(Ks);Bt.parse();function Qs(e){clearTimeout(Pt),Pt=setTimeout(async()=>{await ea(e)},Of)}async function ea(e){try{lt=await oa(e),lt?.updated&&(ft?.process.send({type:"coreUpdated",version:qt(lt.path)}),Rr=0)}catch{Rr++}finally{Rr<=3&&Qs(lt?.path||e)}}async function ta(e){clearTimeout(Pt),ft?.process.removeAllListeners(),ft?.process.kill();let{path:t,type:r}=lt||await Lf({forceUpdate:e.update});ft=If(t,e),r==="dist"&&Qs(ft.path)}function If(e,t){let r=["--cli=true","--lkp="+Js];t.smart&&r.push("--smartStart=true"),t.config&&r.push("--configPath="+(0,G.resolve)(t.config));let n=qt((0,G.dirname)(e)),[,,o]=n.split(".");parseInt(o,10)<1608&&(process.stdout.write(_.red(`${_.bold("Wallaby Core")} v${n} is not supported.
54
+ `))}outputVersion(){let{name:t}=this.cli,{versionNumber:r}=this.cli.globalCommand;r&&console.log(`${t}/${r} ${Cu}`)}checkRequiredArgs(){let t=this.args.filter(r=>r.required).length;if(this.cli.args.length<t)throw new st(`missing required args for command \`${this.rawName}\``)}checkUnknownOptions(){let{options:t,globalCommand:r}=this.cli;if(!this.config.allowUnknownOptions){for(let n of Object.keys(t))if(n!=="--"&&!this.hasOption(n)&&!r.hasOption(n))throw new st(`Unknown option \`${n.length>1?`--${n}`:`-${n}`}\``)}}checkOptionValue(){let{options:t,globalCommand:r}=this.cli,n=[...r.options,...this.options];for(let o of n){let i=t[o.name.split(".")[0]];if(o.required){let s=n.some(a=>a.negated&&a.names.includes(o.name));if(i===!0||i===!1&&!s)throw new st(`option \`${o.rawName}\` value is missing`)}}}},Ot=class extends Dt{constructor(t){super("@@global@@","",{},t)}},Nt=Object.assign,nr=class extends Pi.EventEmitter{constructor(t=""){super(),this.name=t,this.commands=[],this.rawArgs=[],this.args=[],this.options={},this.globalCommand=new Ot(this),this.globalCommand.usage("<command> [options]")}usage(t){return this.globalCommand.usage(t),this}command(t,r,n){let o=new Dt(t,r||"",n,this);return o.globalCommand=this.globalCommand,this.commands.push(o),o}option(t,r,n){return this.globalCommand.option(t,r,n),this}help(t){return this.globalCommand.option("-h, --help","Display this message"),this.globalCommand.helpCallback=t,this.showHelpOnExit=!0,this}version(t,r="-v, --version"){return this.globalCommand.version(t,r),this.showVersionOnExit=!0,this}example(t){return this.globalCommand.example(t),this}outputHelp(){this.matchedCommand?this.matchedCommand.outputHelp():this.globalCommand.outputHelp()}outputVersion(){this.globalCommand.outputVersion()}setParsedInfo({args:t,options:r},n,o){return this.args=t,this.options=r,n&&(this.matchedCommand=n),o&&(this.matchedCommandName=o),this}unsetMatchedCommand(){this.matchedCommand=void 0,this.matchedCommandName=void 0}parse(t=vu,{run:r=!0}={}){this.rawArgs=t,this.name||(this.name=t[1]?xu(t[1]):"cli");let n=!0;for(let i of this.commands){let s=this.mri(t.slice(2),i),a=s.args[0];if(i.isMatched(a)){n=!1;let c=Nt(Nt({},s),{args:s.args.slice(1)});this.setParsedInfo(c,i,a),this.emit(`command:${a}`,i)}}if(n){for(let i of this.commands)if(i.name===""){n=!1;let s=this.mri(t.slice(2),i);this.setParsedInfo(s,i),this.emit("command:!",i)}}if(n){let i=this.mri(t.slice(2));this.setParsedInfo(i)}this.options.help&&this.showHelpOnExit&&(this.outputHelp(),r=!1,this.unsetMatchedCommand()),this.options.version&&this.showVersionOnExit&&this.matchedCommandName==null&&(this.outputVersion(),r=!1,this.unsetMatchedCommand());let o={args:this.args,options:this.options};return r&&this.runMatchedCommand(),!this.matchedCommand&&this.args[0]&&this.emit("command:*"),o}mri(t,r){let n=[...this.globalCommand.options,...r?r.options:[]],o=gu(n),i=[],s=t.indexOf("--");s>-1&&(i=t.slice(s+1),t=t.slice(0,s));let a=pu(t,o);a=Object.keys(a).reduce((h,p)=>Nt(Nt({},h),{[Ui(p)]:a[p]}),{_:[]});let c=a._,u={"--":i},l=r&&r.config.ignoreOptionDefaultValue?r.config.ignoreOptionDefaultValue:this.globalCommand.config.ignoreOptionDefaultValue,d=Object.create(null);for(let h of n){if(!l&&h.config.default!==void 0)for(let p of h.names)u[p]=h.config.default;Array.isArray(h.config.type)&&d[h.name]===void 0&&(d[h.name]=Object.create(null),d[h.name].shouldTransform=!0,d[h.name].transformFunction=h.config.type[0])}for(let h of Object.keys(a))if(h!=="_"){let p=h.split(".");Eu(u,p,a[h]),Su(u,d)}return{args:c,options:u}}runMatchedCommand(){let{args:t,options:r,matchedCommand:n}=this;if(!n||!n.commandAction)return;n.checkUnknownOptions(),n.checkOptionValue(),n.checkRequiredArgs();let o=[];return n.args.forEach((i,s)=>{i.variadic?o.push(t.slice(s)):o.push(t[s])}),o.push(r),n.commandAction.apply(this,o)}},Bi=(e="")=>new nr(e);var _=X(Hi()),Vs=X(_o()),Gs=X(qo()),vf=!1,Rt="https",zs=!0,Zs=__dirname,Cf=(0,G.join)(Zs,"bin"),Bt=Bi("wallaby"),js=require((0,G.join)(Zs,"package.json")).version,qr=(0,G.join)((0,Ws.homedir)(),".wallaby"),Te=(0,G.join)(qr,"cli"),kr=(0,G.join)(Te,"downloads"),Xs=(0,G.join)(qr,"key.lic"),Ks=(0,G.join)(Te,"wallaby.json"),Rr=(0,G.join)(Te,"core.json"),Bs=()=>Rt+"://update.wallabyjs.com/",bf=10*60*1e3,Pt,Ar=0,ft,lt;Bt.command("[root]","start wallaby").option("--doNotOpen","do not open browser on startup").option("--smart","use smart (lazy) start to run tests of modified test files only: https://wallabyjs.com/docs/intro/smart-start.html").option("--config <path>","use config file: https://wallabyjs.com/docs/config/overview.html").option("--update","force Wallaby Core update to the latest version before starting").option("--useHttp","use http instead of https for downloading Wallaby dependencies").option("--useNonStrictSSL","do not use strict SSL for downloading Wallaby dependencies").option("--suppressExpirationNotifications","do not notify about license expiration").action(async(e,t)=>{_f(t),t.useHttp&&(Rt="http"),t.useNonStrictSSL&&(zs=!1),Y.default.ensureDirSync(qr),Y.default.ensureDirSync(Te),await Qs(t)});Bt.help();Bt.version(js);Bt.parse();function Js(e){clearTimeout(Pt),Pt=setTimeout(async()=>{await Ys(e)},bf)}async function Ys(e){try{lt=await na(e),lt?.updated&&(ft?.process.send({type:"coreUpdated",version:qt(lt.path)}),Ar=0)}catch{Ar++}finally{Ar<=3&&Js(lt?.path||e)}}async function Qs(e){clearTimeout(Pt),ft?.process.removeAllListeners(),ft?.process.kill();let{path:t,type:r}=lt||await Df({forceUpdate:e.update});ft=Nf(t,e),r==="dist"&&Js(ft.path)}function Nf(e,t){let r=["--cli=true","--lkp="+Xs];t.smart&&r.push("--smartStart=true"),t.config&&r.push("--configPath="+(0,G.resolve)(t.config));let n=qt((0,G.dirname)(e)),[,,o]=n.split(".");parseInt(o,10)<1608&&(process.stdout.write(_.red(`${_.bold("Wallaby Core")} v${n} is not supported.
55
55
  `)),process.stdout.write(_.red(`Run with ${_.bold("--update")} flag to get the latest version of Wallaby Core.
56
- `)),process.exit(1));let i=(0,Ut.fork)(e,r,{env:process.env,silent:!0});return t.printLinks=!0,i.on("message",s=>{switch(s?.type){case"uiStarted":t.port=s.port,Af(t,n);break;case"notification":Tf(t,s.notification);break;case"restart":ta(t);break;case"licenseChanged":clearTimeout(Pt),ea(e);break;case"stopped":break;default:break}}),i.on("exit",()=>{process.stdout.write(_.gray(`
56
+ `)),process.exit(1));let i=(0,Ut.fork)(e,r,{env:process.env,silent:!0});return t.printLinks=!0,i.on("message",s=>{switch(s?.type){case"uiStarted":t.port=s.port,Ff(t,n);break;case"notification":Lf(t,s.notification);break;case"restart":Qs(t);break;case"licenseChanged":clearTimeout(Pt),Ys(e);break;case"stopped":break;default:break}}),i.on("exit",()=>{process.stdout.write(_.gray(`
57
57
  ${_.bold("WALLABY CORE")} stopped
58
- `))}),{process:i,path:e}}async function Lf(e){if(Nf)return{path:require.resolve("../wallaby/server"),type:"dev"};let t=Ff();return t?{path:t,type:"npm"}:{path:await _f(e),type:"dist"}}function Ff(){try{let e=require.resolve("@wallabyjs/core"),t=(0,G.join)(e,"server.js");if(Y.default.existsSync(t))return t}catch{}}async function _f(e){let t=ia(),r=await oa(t,{forceLatestVersion:e?.forceUpdate,useInstalledVersion:!0});if(!r)throw new Error("Could not resolve Wallaby Core");return(0,G.join)(r.path,"server.js")}function Tf(e,t){if(!t.text)return;let r=[];if(~t.text.indexOf("expire")&&t.type==="warning"&&e.suppressExpirationNotifications)return;let n=`http://localhost:${e.port}`;~t.text.indexOf("activate-link")&&e.port&&r.push({title:"Enter License",url:n}),~t.text.indexOf("continue-trial-link")&&e.port&&r.push({title:"Continue Trial",url:n}),t.button&&r.push({title:t.button.label,url:t.button.link}),t.text=t.text.replace(/<br\/><br\/>/g," ").replace(/<br\/>/g," ").replace(/<a\s+(?:[^>]*?\s+)?href=['"]([^'"]*)['"]/g,(i,s)=>(s.startsWith("http")&&r.push({url:s}),i)).replace(/<[^>]*>/g,"");let o=t.type==="error"?_.red:t.type==="warning"?_.yellow:_.green;if(process.stdout.write(o(`
58
+ `))}),{process:i,path:e}}async function Df(e){if(vf)return{path:require.resolve("../wallaby/server"),type:"dev"};let t=Of();return t?{path:t,type:"npm"}:{path:await If(e),type:"dist"}}function Of(){try{let e=require.resolve("@wallabyjs/core"),t=(0,G.join)(e,"server.js");if(Y.default.existsSync(t))return t}catch{}}async function If(e){let t=ra(),r=await na(t,{forceLatestVersion:e?.forceUpdate,useInstalledVersion:!0});if(!r)throw new Error("Could not resolve Wallaby Core");return(0,G.join)(r.path,"server.js")}function Lf(e,t){if(!t.text)return;let r=[];if(~t.text.indexOf("expire")&&t.type==="warning"&&e.suppressExpirationNotifications)return;let n=`http://localhost:${e.port}`;~t.text.indexOf("activate-link")&&e.port&&r.push({title:"Enter License",url:n}),~t.text.indexOf("continue-trial-link")&&e.port&&r.push({title:"Continue Trial",url:n}),t.button&&r.push({title:t.button.label,url:t.button.link}),t.text=t.text.replace(/<br\/><br\/>/g," ").replace(/<br\/>/g," ").replace(/<a\s+(?:[^>]*?\s+)?href=['"]([^'"]*)['"]/g,(i,s)=>(s.startsWith("http")&&r.push({url:s}),i)).replace(/<[^>]*>/g,"");let o=t.type==="error"?_.red:t.type==="warning"?_.yellow:_.green;if(process.stdout.write(o(`
59
59
  \u2691 ${t.text}
60
60
 
61
61
  `)),r.length)for(let i of r)process.stdout.write(`${_.green(" \u279C ")}${_.bold(_.yellow(i.title?i.title+": ":""))}${_.cyan(i.url)}
62
- `)}function Af(e,t){let r=`http://localhost:${e.port}`;process.stdout.write(_.green(` ${_.bold("WALLABY CORE")} v${t}
62
+ `)}function Ff(e,t){let r=`http://localhost:${e.port}`;process.stdout.write(_.green(` ${_.bold("WALLABY CORE")} v${t}
63
63
  `)),e.printLinks&&(process.stdout.write(`${_.green(" \u279C ")}${_.bold(_.yellow("UI:"))} ${_.cyan(r)}
64
64
  `),process.stdout.write(`${_.green(" \u279C ")}${_.bold(_.dim("Docs:"))} ${_.cyan("https://wallabyjs.com/docs")}
65
- `)),e.doNotOpen||Rf(r)}function kf(e){for(let[t,r]of Object.entries(e))Array.isArray(r)&&(e[t]=r[r.length-1])}function Rf(e){let t=process.env.BROWSER||"";if(t.toLowerCase().endsWith(".js"))Pf(t,e);else if(t.toLowerCase()!=="none"){let r=process.env.BROWSER_ARGS?process.env.BROWSER_ARGS.split(" "):[];qf(t,r,e)}}function Pf(e,t){let r=process.argv.slice(2);(0,zs.default)(process.execPath,[e,...r,t],{stdio:"inherit"}).on("close",o=>{o!==0&&process.stdout.write(_.red(`
65
+ `)),e.doNotOpen||Tf(r)}function _f(e){for(let[t,r]of Object.entries(e))Array.isArray(r)&&(e[t]=r[r.length-1])}function Tf(e){let t=process.env.BROWSER||"";if(t.toLowerCase().endsWith(".js"))Af(t,e);else if(t.toLowerCase()!=="none"){let r=process.env.BROWSER_ARGS?process.env.BROWSER_ARGS.split(" "):[];kf(t,r,e)}}function Af(e,t){let r=process.argv.slice(2);(0,Vs.default)(process.execPath,[e,...r,t],{stdio:"inherit"}).on("close",o=>{o!==0&&process.stdout.write(_.red(`
66
66
  The script specified as BROWSER environment variable failed.
67
67
 
68
- ${_.cyan(e)} exited with code ${o}.`))})}var Hs=["Google Chrome Canary","Google Chrome Dev","Google Chrome Beta","Google Chrome","Microsoft Edge","Brave Browser","Vivaldi","Chromium"];async function qf(e,t,r){let n=e==="google chrome"?"Google Chrome":e;if(process.platform==="darwin"&&(!n||Hs.includes(n)))try{let i=await Ws("ps cax"),s=n&&i.includes(n)?n:Hs.find(a=>i.includes(a));if(s)return await Ws(`osascript openChrome.applescript "${encodeURI(r)}" "${s}"`,{cwd:Df}),!0}catch{}process.platform==="darwin"&&e==="open"&&(e=void 0);try{let i=e?{app:{name:e,arguments:t}}:{};return new Promise(async(s,a)=>{let c;try{c=(ys(),ha(ps)).default}catch{try{c=(await eval?.("import('open')")).default}catch{}}c&&c(r,i).then(u=>{u.on("error",a)}).catch(a)}).catch(s=>{process.stderr.write(s.stack||s.message)}),!0}catch{return!1}}function Ws(e,t){return new Promise((r,n)=>{(0,Ut.exec)(e,t,(o,i)=>{o?n(o):r(i.toString())})})}function ra(){try{let e=r=>r&&r.replace(/^\s+|\s+$/gm,""),t=Y.default.readFileSync(Js).toString();if(t){let r=t.split(":");r.length===2&&(t=e(r[1]))}return Buffer.from(t,"base64").toString().split(`
69
- `)[2]}catch{}}function Uf(){try{let[e,t,r]=ra().split("/");return new Date(Date.UTC(parseInt(r,10),parseInt(t,10)-1,parseInt(e,10)))}catch{}}async function na(e,t){try{await Y.default.remove(e)}catch(r){if(t)throw r;await na(e,!0)}}function ia(e,t){let r;if(!e)try{e=JSON.parse(Y.default.readFileSync(qr).toString())}catch{}e||(e={});let n=Uf()?.getTime(),o=Object.keys(e).map(a=>({id:a,folder:(0,G.join)(Te,"wallaby"+a),...e[a]})).sort((a,c)=>c.releaseDate-a.releaseDate),i=new Date().getTime()-1e3*1440*5;o.forEach(a=>{if(!Y.default.existsSync(a.folder))t=!0,delete e[a.id];else if(a.invalidated&&Object.keys(a.expiry).length===0&&a.invalidated<i){t=!0,delete e[a.id];try{na(a.folder,!0)}catch{}}});let s=o.filter(a=>(!n||a.releaseDate<n)&&e[a.id]);if(s.length){if(n&&n<new Date().getTime()&&!e[s[0].id].expiry[n]){e[s[0].id].expiry[n]=!0;for(let c=1;c<s.length;c++)delete e[s[c].id].expiry[n];t=!0}let a=(s.find(c=>!c.invalidated)||s[0]).id;r=(0,G.join)(Te,"wallaby"+a)}return t&&Y.default.writeFileSync(qr,JSON.stringify(e)),r}async function oa(e,t){let r=!1,n=e,o=t?.forceLatestVersion,i=t?.useInstalledVersion,s=ra(),a=Ms(),c=h=>$f({name:"version",from:`${h}wallaby.json?${s?"expiry="+s.replace(/\//g,"-"):""}`,to:Ys}),u=o?!1:n&&Y.default.existsSync(n),l=(0,G.join)(Pr,"wallaby.zip");if(!u&&!o&&Y.default.existsSync(l))try{n=await aa(l),u=!!n&&Y.default.existsSync(n),r=!0}catch{}let d;if(i&&u)d={core:u&&qt(n)||"unknown"};else{let h=Ur("Downloading version file");try{try{await c(Ms())}catch{a=`${Rt}://s3.amazonaws.com/wallaby-downloads/`,await c("http://update.wallabyjs.com/")}}finally{h()}d=Bf()}if(!(u&&qt(n)===d.core))try{n=await Vs({name:"core",from:`${a}wallaby-v${d.core}.zip`}),r=!0}catch{n=await Vs({name:"core",from:`${Rt}://s3.amazonaws.com/wallaby-downloads/wallaby-v${d.core}.zip`}),r=!0}return{path:n,updated:r,type:"dist"}}function Bf(){let e=JSON.parse(Y.default.readFileSync(Ys).toString()),t;return e.latestServer.forEach(r=>{r.substring(0,r.lastIndexOf("."))===Ks.substring(0,r.lastIndexOf("."))&&(t=r)}),{core:t}}function qt(e){return JSON.parse(Y.default.readFileSync((0,G.join)(e,"package.json")).toString()).version}async function Vs(e){let t=Ur("Downloading core"),r=(0,G.join)(Pr,"wallaby.zip");try{Y.default.ensureDirSync(Pr),await sa(e.from,e.name,r,2e6)}finally{t()}let n=Ur("Extracting core");try{return await aa(r)}catch(o){throw new Error(`Error while unzipping wallaby.js ${e.name} file: ${o.message}`)}finally{n()}}async function $f(e){return await sa(e.from,e.name,e.to)}function sa(e,t,r,n){let o=!1,i=()=>!o&&(o=!0),s="This may occur when you are behind proxy.";return new Promise(async(a,c)=>{try{let u=global.fetch,l={headers:{"User-Agent":"node "+process.version},agent:void 0};if(e.startsWith("https:")){let h=require("https");js===!1&&(l.agent=new h.Agent({rejectUnauthorized:!1}))}let d=await u(e,l);if(!d.ok||d.status!==200)throw new Error(`Error while downloading wallaby.js ${t}, status code: ${d.status}. ${s}`);if(n&&d.headers.get("content-length")&&parseInt(d.headers.get("content-length"),10)<n)throw new Error(`Error while downloading wallaby.js ${t}, file is corrupt. ${s}`);{let h=await d.arrayBuffer();Y.default.writeFileSync(r,Buffer.from(h)),i()&&a(r)}}catch(u){i()&&c(u)}})}async function aa(e){let t=$s(),r=new t(e),n=new Date(r.getEntry("package.json").header.time);n.setMinutes(n.getMinutes()-n.getTimezoneOffset());let o=JSON.parse(r.readAsText("package.json")).version,[i,s,a]=o.split(".").map(h=>parseInt(h)),c=require("crypto");if(i>1||s>0||a>1091){let h=`-----BEGIN RSA PUBLIC KEY-----
68
+ ${_.cyan(e)} exited with code ${o}.`))})}var $s=["Google Chrome Canary","Google Chrome Dev","Google Chrome Beta","Google Chrome","Microsoft Edge","Brave Browser","Vivaldi","Chromium"];async function kf(e,t,r){let n=e==="google chrome"?"Google Chrome":e;if(process.platform==="darwin"&&(!n||$s.includes(n)))try{let i=await Ms("ps cax"),s=n&&i.includes(n)?n:$s.find(a=>i.includes(a));if(s)return await Ms(`osascript openChrome.applescript "${encodeURI(r)}" "${s}"`,{cwd:Cf}),!0}catch{}process.platform==="darwin"&&e==="open"&&(e=void 0);try{let i=e?{app:{name:e,arguments:t}}:{};return new Promise(async(s,a)=>{let c;try{c=(hs(),da(ms)).default}catch{try{c=(await eval?.("import('open')")).default}catch{}}c&&c(r,i).then(u=>{u.on("error",a)}).catch(a)}).catch(s=>{process.stderr.write(s.stack||s.message)}),!0}catch{return!1}}function Ms(e,t){return new Promise((r,n)=>{(0,Ut.exec)(e,t,(o,i)=>{o?n(o):r(i.toString())})})}function ea(){try{let e=r=>r&&r.replace(/^\s+|\s+$/gm,""),t=Y.default.readFileSync(Xs).toString();if(t){let r=t.split(":");r.length===2&&(t=e(r[1]))}return Buffer.from(t,"base64").toString().split(`
69
+ `)[2]}catch{}}function Rf(){try{let[e,t,r]=ea().split("/");return new Date(Date.UTC(parseInt(r,10),parseInt(t,10)-1,parseInt(e,10)))}catch{}}async function ta(e,t){try{await Y.default.remove(e)}catch(r){if(t)throw r;await ta(e,!0)}}function ra(e,t){let r;if(!e)try{e=JSON.parse(Y.default.readFileSync(Rr).toString())}catch{}e||(e={});let n=Rf()?.getTime(),o=Object.keys(e).map(a=>({id:a,folder:(0,G.join)(Te,"wallaby"+a),...e[a]})).sort((a,c)=>c.releaseDate-a.releaseDate),i=new Date().getTime()-1e3*1440*5;o.forEach(a=>{if(!Y.default.existsSync(a.folder))t=!0,delete e[a.id];else if(a.invalidated&&Object.keys(a.expiry).length===0&&a.invalidated<i){t=!0,delete e[a.id];try{ta(a.folder,!0)}catch{}}});let s=o.filter(a=>(!n||a.releaseDate<n)&&e[a.id]);if(s.length){if(n&&n<new Date().getTime()&&!e[s[0].id].expiry[n]){e[s[0].id].expiry[n]=!0;for(let c=1;c<s.length;c++)delete e[s[c].id].expiry[n];t=!0}let a=(s.find(c=>!c.invalidated)||s[0]).id;r=(0,G.join)(Te,"wallaby"+a)}return t&&Y.default.writeFileSync(Rr,JSON.stringify(e)),r}async function na(e,t){let r=!1,n=e,o=t?.forceLatestVersion,i=t?.useInstalledVersion,s=ea(),a=Bs(),c=h=>qf({name:"version",from:`${h}wallaby.json?${s?"expiry="+s.replace(/\//g,"-"):""}`,to:Ks}),u=o?!1:n&&Y.default.existsSync(n),l=(0,G.join)(kr,"wallaby.zip");if(!u&&!o&&Y.default.existsSync(l))try{n=await oa(l),u=!!n&&Y.default.existsSync(n),r=!0}catch{}let d;if(i&&u)d={core:u&&qt(n)||"unknown"};else{let h=Pr("Downloading version file");try{try{await c(Bs())}catch{a=`${Rt}://s3.amazonaws.com/wallaby-downloads/`,await c("http://update.wallabyjs.com/")}}finally{h()}d=Pf()}if(!(u&&qt(n)===d.core))try{n=await Hs({name:"core",from:`${a}wallaby-v${d.core}.zip`}),r=!0}catch{n=await Hs({name:"core",from:`${Rt}://s3.amazonaws.com/wallaby-downloads/wallaby-v${d.core}.zip`}),r=!0}return{path:n,updated:r,type:"dist"}}function Pf(){let e=JSON.parse(Y.default.readFileSync(Ks).toString()),t;return e.latestServer.forEach(r=>{r.substring(0,r.lastIndexOf("."))===js.substring(0,r.lastIndexOf("."))&&(t=r)}),{core:t}}function qt(e){return JSON.parse(Y.default.readFileSync((0,G.join)(e,"package.json")).toString()).version}async function Hs(e){let t=Pr("Downloading core"),r=(0,G.join)(kr,"wallaby.zip");try{Y.default.ensureDirSync(kr),await ia(e.from,e.name,r,2e6)}finally{t()}let n=Pr("Extracting core");try{return await oa(r)}catch(o){throw new Error(`Error while unzipping wallaby.js ${e.name} file: ${o.message}`)}finally{n()}}async function qf(e){return await ia(e.from,e.name,e.to)}function ia(e,t,r,n){let o=!1,i=()=>!o&&(o=!0),s="This may occur when you are behind proxy.";return new Promise(async(a,c)=>{try{let u=global.fetch,l={headers:{"User-Agent":"node "+process.version},agent:void 0};if(e.startsWith("https:")){let h=require("https");zs===!1&&(l.agent=new h.Agent({rejectUnauthorized:!1}))}let d=await u(e,l);if(!d.ok||d.status!==200)throw new Error(`Error while downloading wallaby.js ${t}, status code: ${d.status}. ${s}`);if(n&&d.headers.get("content-length")&&parseInt(d.headers.get("content-length"),10)<n)throw new Error(`Error while downloading wallaby.js ${t}, file is corrupt. ${s}`);{let h=await d.arrayBuffer();Y.default.writeFileSync(r,Buffer.from(h)),i()&&a(r)}}catch(u){i()&&c(u)}})}async function oa(e){let t=Us(),r=new t(e),n=new Date(r.getEntry("package.json").header.time);n.setMinutes(n.getMinutes()-n.getTimezoneOffset());let o=JSON.parse(r.readAsText("package.json")).version,[i,s,a]=o.split(".").map(h=>parseInt(h)),c=require("crypto");if(i>1||s>0||a>1091){let h=`-----BEGIN RSA PUBLIC KEY-----
70
70
  MIIBCgKCAQEAngwMnSkF1zlHJggr7kXXO02ytYIlzMdvQxHu6hli+TFIeO72HNfK
71
71
  P27g+f8EtlPRB0UwnpAHtkJHNCdwpo04eU8hS8g9vbmNf00luUJGuUHnf62Pp0EI
72
72
  KbGKJvzkdPgfs62MItfi4uf+XiHa8rN0Bk7hRbddI1zA4Wupf/E0wZ7UorgCE9XB
73
73
  EM6VULphGdHorpmHBW5deeCHIledtMOpOfDSM5lvjiqgVqmjNYT+WXCwjN8yCcyU
74
74
  oedY3afSHTyqiuInKcpXd+VJQb2+d7y583Pb3+kDGraBMGFJaWGewm7+IYIlgk5C
75
75
  uk54FsjCvwvaa0SKr2rkIBKuyFX3ZGymyQIDAQAB
76
- -----END RSA PUBLIC KEY-----`,p=r.getEntries();p.sort((w,m)=>w.entryName.localeCompare(m.entryName));let f=r.readAsText("signature.txt"),y=c.createVerify("RSA-SHA512");if(p.forEach(w=>{w.entryName!=="signature.txt"&&y.update(w.getData())}),!y.verify(h,Buffer.from(f,"base64")))throw new Error("could not verify core version")}let l=c.randomBytes(3).toString("hex");for(;Y.default.existsSync((0,G.join)(Te,"wallaby"+l));)l=c.randomBytes(3).toString("hex");let d=(0,G.join)(Te,"wallaby"+l);return await new Promise((h,p)=>{r.extractAllToAsync(d,!0,f=>{f?p(f):h(void 0)})}),Mf(l,n.getTime())}function Mf(e,t){let r;try{r=JSON.parse(Y.default.readFileSync(qr).toString());let n=new Date().getTime();Object.keys(r).forEach(o=>{!r[o].invalidated&&r[o].releaseDate<=t&&(r[o].invalidated=n)})}catch{r={}}return r[e]={releaseDate:t,invalidated:!1,expiry:{}},ia(r,!0)}function Ur(e){var t=new Zs.Spinner;return t.setSpinnerString(4),t.setSpinnerDelay(250),t.setSpinnerTitle(` ${_.green("%s")} ${e}`),t.start(),()=>t.stop(!0)}
76
+ -----END RSA PUBLIC KEY-----`,p=r.getEntries();p.sort((w,m)=>w.entryName.localeCompare(m.entryName));let f=r.readAsText("signature.txt"),y=c.createVerify("RSA-SHA512");if(p.forEach(w=>{w.entryName!=="signature.txt"&&y.update(w.getData())}),!y.verify(h,Buffer.from(f,"base64")))throw new Error("could not verify core version")}let l=c.randomBytes(3).toString("hex");for(;Y.default.existsSync((0,G.join)(Te,"wallaby"+l));)l=c.randomBytes(3).toString("hex");let d=(0,G.join)(Te,"wallaby"+l);return await new Promise((h,p)=>{r.extractAllToAsync(d,!0,f=>{f?p(f):h(void 0)})}),Uf(l,n.getTime())}function Uf(e,t){let r;try{r=JSON.parse(Y.default.readFileSync(Rr).toString());let n=new Date().getTime();Object.keys(r).forEach(o=>{!r[o].invalidated&&r[o].releaseDate<=t&&(r[o].invalidated=n)})}catch{r={}}return r[e]={releaseDate:t,invalidated:!1,expiry:{}},ra(r,!0)}function Pr(e){var t=new Gs.Spinner;return t.setSpinnerString(4),t.setSpinnerDelay(250),t.setSpinnerTitle(` ${_.green("%s")} ${e}`),t.start(),()=>t.stop(!0)}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wallabyjs/cli",
3
- "version": "1.0.7",
3
+ "version": "1.0.8",
4
4
  "main": "./index.js",
5
5
  "description": "Wallaby CLI",
6
6
  "homepage": "https://wallabyjs.com",