@muxcodecli/cli 1.15.17 → 1.15.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bip-bop-01-ga21wr3r.mp3 +0 -0
- package/dist/bip-bop-03-kgfd4rq4.mp3 +0 -0
- package/dist/chunk-0hqmdrjr.js +3 -0
- package/dist/chunk-0npjzye0.js +2 -0
- package/dist/chunk-0pe6y883.js +2 -0
- package/dist/chunk-0qqpjj2h.js +3 -0
- package/dist/chunk-0r3h8jgj.js +2 -0
- package/dist/chunk-11285jfy.js +3 -0
- package/dist/chunk-11ant2kk.js +3 -0
- package/dist/chunk-124qmktt.js +18 -0
- package/dist/chunk-138ntz3h.js +2 -0
- package/dist/chunk-1e73ypg5.js +3 -0
- package/dist/chunk-1evcc54z.js +3 -0
- package/dist/chunk-1mqsg5s7.js +75 -0
- package/dist/chunk-1pv2317e.js +7 -0
- package/dist/chunk-1y3ssxx6.js +2 -0
- package/dist/chunk-20x8vsdn.js +7 -0
- package/dist/chunk-21x3anp4.js +9 -0
- package/dist/chunk-22qpzg37.js +212 -0
- package/dist/chunk-2bt5mtgm.js +3 -0
- package/dist/chunk-2d95ene8.js +2 -0
- package/dist/chunk-2h2zq5cp.js +2 -0
- package/dist/chunk-2pc63est.js +2 -0
- package/dist/chunk-33gs9z8d.js +2 -0
- package/dist/chunk-33vwwxjk.js +2 -0
- package/dist/chunk-3dq7hfxc.js +9 -0
- package/dist/chunk-3jvft1k1.js +2 -0
- package/dist/chunk-4jqh4mpm.js +2 -0
- package/dist/chunk-4mgyaytc.js +672 -0
- package/dist/chunk-4va8fzq1.js +2 -0
- package/dist/chunk-4wkq9y2z.js +7 -0
- package/dist/chunk-526nbm9e.js +2 -0
- package/dist/chunk-5a6895cv.js +37 -0
- package/dist/chunk-5e9dq2av.js +2 -0
- package/dist/chunk-5jn2z3nf.js +3 -0
- package/dist/chunk-5npr1qyq.js +574 -0
- package/dist/chunk-5sfky0gz.js +8 -0
- package/dist/chunk-5t7xqdvk.js +3 -0
- package/dist/chunk-5tpqj6ag.js +10 -0
- package/dist/chunk-5v5015am.js +12 -0
- package/dist/chunk-5wawdxv2.js +7 -0
- package/dist/chunk-6btrg3ff.js +2 -0
- package/dist/chunk-6skbzman.js +6 -0
- package/dist/chunk-6sz698ew.js +11 -0
- package/dist/chunk-6xzrzmsr.js +2 -0
- package/dist/chunk-7848rf5q.js +63 -0
- package/dist/chunk-7ep2edcv.js +12 -0
- package/dist/chunk-7svw66kw.js +13 -0
- package/dist/chunk-7xgr8vx6.js +2 -0
- package/dist/chunk-7zjn6m1m.js +2 -0
- package/dist/chunk-8atqb297.js +12 -0
- package/dist/chunk-8ebkxjar.js +7 -0
- package/dist/chunk-8j3aw4qg.js +3 -0
- package/dist/chunk-8jy0dvcn.js +3 -0
- package/dist/chunk-8refh038.js +2 -0
- package/dist/chunk-93cszp8k.js +3 -0
- package/dist/chunk-93ze3gcb.js +2 -0
- package/dist/chunk-98yxzxtd.js +2 -0
- package/dist/chunk-9g64kggy.js +3 -0
- package/dist/chunk-9h1pwxb2.js +8 -0
- package/dist/chunk-9j4j9nrm.js +2 -0
- package/dist/chunk-9kzczwh0.js +3 -0
- package/dist/chunk-9n629gtn.js +3 -0
- package/dist/chunk-9y59sxde.js +2 -0
- package/dist/chunk-a2m5jyd8.js +2 -0
- package/dist/chunk-a595cp8s.js +2 -0
- package/dist/chunk-ak0k3m4q.js +3 -0
- package/dist/chunk-apksmrz9.js +3 -0
- package/dist/chunk-b05r09sj.js +10 -0
- package/dist/chunk-b47e563q.js +2 -0
- package/dist/chunk-b57avnse.js +2 -0
- package/dist/chunk-bfjq7w7k.js +2 -0
- package/dist/chunk-bhc70qet.js +3 -0
- package/dist/chunk-bvtscj68.js +2 -0
- package/dist/chunk-bw2cy5v0.js +8 -0
- package/dist/chunk-c7dvyh2x.js +2 -0
- package/dist/chunk-cbz8b7g5.js +3 -0
- package/dist/chunk-cw4vbnet.js +3 -0
- package/dist/chunk-czcj3j9y.js +2 -0
- package/dist/chunk-dg466kdp.js +2 -0
- package/dist/chunk-dmscgnhq.js +2 -0
- package/dist/chunk-dtk4m8rm.js +3 -0
- package/dist/chunk-dy7akyj3.js +2 -0
- package/dist/chunk-e2wv2sp4.js +2 -0
- package/dist/chunk-e8j03wnd.js +3 -0
- package/dist/chunk-egkp6tct.js +2 -0
- package/dist/chunk-emfc800a.js +2 -0
- package/dist/chunk-envnht72.js +4 -0
- package/dist/chunk-eskw1cj2.js +3 -0
- package/dist/chunk-ezz15tyg.js +2 -0
- package/dist/chunk-fkmzj0qt.js +16 -0
- package/dist/chunk-fqt3c3g5.js +4 -0
- package/dist/chunk-frbht418.js +19 -0
- package/dist/chunk-ftz8cqfq.js +2 -0
- package/dist/chunk-g4jxdrr6.js +2 -0
- package/dist/chunk-g52xzmrr.js +2 -0
- package/dist/chunk-gbtvkje9.js +4 -0
- package/dist/chunk-gm9msqq5.js +8 -0
- package/dist/chunk-gxat3dpd.js +3 -0
- package/dist/chunk-hfppq1w5.js +4 -0
- package/dist/chunk-jdg870gy.js +1683 -0
- package/dist/chunk-jfz77m78.js +3 -0
- package/dist/chunk-jg9r58pf.js +16 -0
- package/dist/chunk-jgzt4945.js +2 -0
- package/dist/chunk-jh2epywq.js +2 -0
- package/dist/chunk-jpj6a56k.js +2 -0
- package/dist/chunk-jw4sgq23.js +2 -0
- package/dist/chunk-jws11ngd.js +2 -0
- package/dist/chunk-jxhz82qt.js +2 -0
- package/dist/chunk-k19y2psf.js +4 -0
- package/dist/chunk-k6cj14zk.js +2 -0
- package/dist/chunk-kktm0pdc.js +3 -0
- package/dist/chunk-kmr27ake.js +160 -0
- package/dist/chunk-kyhwvbvq.js +2 -0
- package/dist/chunk-mgn5pejx.js +2 -0
- package/dist/chunk-mskyzxb3.js +3 -0
- package/dist/chunk-my9cfmvt.js +5 -0
- package/dist/chunk-n4vx7kvs.js +389 -0
- package/dist/chunk-nc44rvs7.js +23 -0
- package/dist/chunk-ng3vbpmy.js +3 -0
- package/dist/chunk-nmnp5g5p.js +228 -0
- package/dist/chunk-nn0t3xmn.js +2 -0
- package/dist/chunk-npr41z9a.js +19 -0
- package/dist/chunk-ntvr3177.js +25 -0
- package/dist/chunk-pkc5hkha.js +2 -0
- package/dist/chunk-ppg6zhae.js +3 -0
- package/dist/chunk-pqwm9zk1.js +6 -0
- package/dist/chunk-ptvjmfqx.js +2 -0
- package/dist/chunk-q1r48y0y.js +34 -0
- package/dist/chunk-q9yddd1r.js +3 -0
- package/dist/chunk-qavtgsrh.js +2 -0
- package/dist/chunk-qvh8ghjw.js +7 -0
- package/dist/chunk-qx6r187q.js +2 -0
- package/dist/chunk-r093mfa8.js +32 -0
- package/dist/chunk-rbaj9ktq.js +2 -0
- package/dist/chunk-rkf9ynkx.js +3 -0
- package/dist/chunk-rpp44jtx.js +3 -0
- package/dist/chunk-rrvwp351.js +2 -0
- package/dist/chunk-rs8fsgqt.js +81 -0
- package/dist/chunk-s4gy87ft.js +8 -0
- package/dist/chunk-s5qq2ch2.js +12 -0
- package/dist/chunk-s92578qx.js +71 -0
- package/dist/chunk-snsb760m.js +2 -0
- package/dist/chunk-sp1cvejp.js +2 -0
- package/dist/chunk-spb3tm25.js +4 -0
- package/dist/chunk-srnmswkj.js +2 -0
- package/dist/chunk-sxgbzwrs.js +2 -0
- package/dist/chunk-t2s6m9t2.js +35 -0
- package/dist/chunk-t98sdxty.js +2 -0
- package/dist/chunk-tbnxx5na.js +2 -0
- package/dist/chunk-tfxm3qz4.js +2 -0
- package/dist/chunk-treb38pz.js +3 -0
- package/dist/chunk-tvw8tfpr.js +6 -0
- package/dist/chunk-v107htgw.js +101 -0
- package/dist/chunk-v8at4gnt.js +2 -0
- package/dist/chunk-vmr3get8.js +2 -0
- package/dist/chunk-vqrnejgj.js +71 -0
- package/dist/chunk-vvwy955j.js +3 -0
- package/dist/chunk-w5jxffnq.js +2 -0
- package/dist/chunk-wcbh5jqy.js +3 -0
- package/dist/chunk-wfmrnep1.js +2 -0
- package/dist/chunk-wk11yy8h.js +3 -0
- package/dist/chunk-wn5f1tfj.js +2 -0
- package/dist/chunk-wpm2p1gq.js +3 -0
- package/dist/chunk-wxkyv5gj.js +2 -0
- package/dist/chunk-wyed730e.js +2 -0
- package/dist/chunk-x65zs89t.js +3 -0
- package/dist/chunk-x6zjq78z.js +2 -0
- package/dist/chunk-xedav0qx.js +3 -0
- package/dist/chunk-xmftb9ad.js +38 -0
- package/dist/chunk-xvtkw7hj.js +3 -0
- package/dist/chunk-xy0txg0n.js +2 -0
- package/dist/chunk-y7s5cpwr.js +34 -0
- package/dist/chunk-yg48tfvv.js +16 -0
- package/dist/chunk-ygpen625.js +3 -0
- package/dist/chunk-ymb45bt6.js +2 -0
- package/dist/chunk-yp2zfcvh.js +8 -0
- package/dist/chunk-z3mx7n44.js +3 -0
- package/dist/chunk-zaj612bw.js +3 -0
- package/dist/chunk-zb3179f9.js +3 -0
- package/dist/chunk-zhd8f4pc.js +759 -0
- package/dist/chunk-zjpnyah2.js +3 -0
- package/dist/cli/cmd/tui/worker.js +2 -0
- package/dist/highlights-eq9cgrbb.scm +604 -0
- package/dist/highlights-ghv9g403.scm +205 -0
- package/dist/highlights-hk7bwhj4.scm +284 -0
- package/dist/highlights-r812a2qc.scm +150 -0
- package/dist/highlights-x6tmsnaa.scm +115 -0
- package/dist/index.js +146 -5742
- package/dist/injections-73j83es3.scm +27 -0
- package/dist/muxcode-linux-x64 +0 -0
- package/dist/nope-03-2z8weyjw.mp3 +0 -0
- package/dist/photon_rs_bg-bq08arze.wasm +0 -0
- package/dist/staplebops-06-rz29m246.mp3 +0 -0
- package/dist/tree-sitter-3jzf13jk.wasm +0 -0
- package/dist/tree-sitter-bash-hq5s6fxb.wasm +0 -0
- package/dist/tree-sitter-javascript-nd0q4pe9.wasm +0 -0
- package/dist/tree-sitter-markdown-411r6y9b.wasm +0 -0
- package/dist/tree-sitter-markdown_inline-j5349f42.wasm +0 -0
- package/dist/tree-sitter-powershell-ryb2ffqs.wasm +0 -0
- package/dist/tree-sitter-typescript-zxjzwt75.wasm +0 -0
- package/dist/tree-sitter-zig-e78zbjpm.wasm +0 -0
- package/dist/yup-01-30ecpeh9.mp3 +0 -0
- package/package.json +2 -2
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
import{ib as W,jb as Q}from"./chunk-dtk4m8rm.js";import{xj as V}from"./chunk-9n629gtn.js";function U(){let B,G;return{promise:new Promise((z,F)=>{B=z,G=F}),resolve:B,reject:G}}async function $(B){let G=U(),H=U(),z={queue:[],closed:B.footer.isClosed},F,D=(A,M)=>{B.trace?.write("ui.patch",M),B.footer.event(A)},L=()=>{if(!z.closed||F)return;H.resolve()},R=()=>{if(z.closed)return;z.closed=!0,z.queue.length=0,z.ctrl?.abort(),G.resolve({type:"closed"}),L()},S=()=>{if(F||z.closed||z.queue.length===0)return;F=(async()=>{try{while(!z.closed&&z.queue.length>0){let A=z.queue.shift();if(!A)continue;if(A.mode!=="shell"&&Q(A.text)){if(D({type:"queue",queue:z.queue.length},{queue:z.queue.length}),!B.onNewSession){D({type:"stream.patch",patch:{status:"new sessions unavailable"}},{status:"new sessions unavailable"});continue}D({type:"stream.patch",patch:{phase:"running",status:"starting new session",queue:z.queue.length}},{phase:"running",status:"starting new session",queue:z.queue.length}),await B.onNewSession();continue}D({type:"turn.send",queue:z.queue.length},{phase:"running",status:"sending prompt",queue:z.queue.length});let M=Date.now(),I=new AbortController;z.ctrl=I;try{if(await B.footer.idle(),z.closed)break;if(A.mode!=="shell"){let K={kind:"user",text:A.text,phase:"start",source:"system"};B.trace?.write("ui.commit",K),B.footer.append(K)}if(B.onSend?.(A),z.closed)break;let J=B.run(A,I.signal).then(()=>({type:"done"}),(K)=>({type:"error",error:K})),O=await Promise.race([J,G.promise]);if(O.type==="closed"){I.abort();break}if(O.type==="error")throw O.error}finally{if(z.ctrl===I)z.ctrl=void 0;let J=V(Math.max(0,Date.now()-M));D({type:"turn.duration",duration:J},{duration:J})}}}catch(A){H.reject(A);return}finally{F=void 0,D({type:"turn.idle",queue:z.queue.length},{phase:"idle",status:"",queue:z.queue.length})}L()})()},T=(A)=>{if(!A.text.trim()||z.closed)return;if(A.mode!=="shell"&&W(A.text)){B.footer.close();return}if(z.queue.push(A),D({type:"queue",queue:z.queue.length},{queue:z.queue.length}),A.mode!=="shell"&&Q(A.text)){S();return}D({type:"first",first:!1},{first:!1}),S()},X=B.footer.onPrompt((A)=>{T(A)}),Y=B.footer.onClose(()=>{R()});try{if(z.closed)return;T({text:B.initialInput??"",parts:[]}),L(),await H.promise}finally{X(),Y(),R(),await F?.catch(()=>{})}}
|
|
3
|
+
export{$ as ab};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
import{SF as p8}from"./chunk-8j3aw4qg.js";import{fileURLToPath as r6}from"url";import{posix as e6,win32 as t0}from"path";import{fileURLToPath as t6}from"url";import{lstatSync as Q7,readdir as J7,readdirSync as Z7,readlinkSync as Y7,realpathSync as K7}from"fs";import*as V7 from"fs";import{lstat as X7,readdir as H7,readlink as W7,realpath as z7}from"fs/promises";import{EventEmitter as Z2}from"events";import J5 from"stream";import{StringDecoder as $7}from"string_decoder";var h2=(Q,J,Z)=>{let Y=Q instanceof RegExp?j2(Q,Z):Q,K=J instanceof RegExp?j2(J,Z):J,V=Y!==null&&K!=null&&p5(Y,K,Z);return V&&{start:V[0],end:V[1],pre:Z.slice(0,V[0]),body:Z.slice(V[0]+Y.length,V[1]),post:Z.slice(V[1]+K.length)}},j2=(Q,J)=>{let Z=J.match(Q);return Z?Z[0]:null},p5=(Q,J,Z)=>{let Y,K,V,X,W,H=Z.indexOf(Q),z=Z.indexOf(J,H+1),q=H;if(H>=0&&z>0){if(Q===J)return[H,z];for(Y=[],V=Z.length;q>=0&&!W;){if(q===H)Y.push(q),H=Z.indexOf(Q,q+1);else if(Y.length===1){let $=Y.pop();$!==void 0&&(W=[$,z])}else K=Y.pop(),K!==void 0&&K<V&&(V=K,X=z),z=Z.indexOf(J,q+1);q=H<z&&H>=0?H:z}Y.length&&X!==void 0&&(W=[V,X])}return W},f2="\x00SLASH"+Math.random()+"\x00",d2="\x00OPEN"+Math.random()+"\x00",Q2="\x00CLOSE"+Math.random()+"\x00",c2="\x00COMMA"+Math.random()+"\x00",l2="\x00PERIOD"+Math.random()+"\x00",n5=new RegExp(f2,"g"),r5=new RegExp(d2,"g"),i5=new RegExp(Q2,"g"),a5=new RegExp(c2,"g"),s5=new RegExp(l2,"g"),e5=/\\\\/g,t5=/\\{/g,Q6=/\\}/g,J6=/\\,/g,Z6=/\\./g,Y6=1e5;function l0(Q){return isNaN(Q)?Q.charCodeAt(0):parseInt(Q,10)}function K6(Q){return Q.replace(e5,f2).replace(t5,d2).replace(Q6,Q2).replace(J6,c2).replace(Z6,l2)}function V6(Q){return Q.replace(n5,"\\").replace(r5,"{").replace(i5,"}").replace(a5,",").replace(s5,".")}function o2(Q){if(!Q)return[""];let J=[],Z=h2("{","}",Q);if(!Z)return Q.split(",");let{pre:Y,body:K,post:V}=Z,X=Y.split(",");X[X.length-1]+="{"+K+"}";let W=o2(V);return V.length&&(X[X.length-1]+=W.shift(),X.push.apply(X,W)),J.push.apply(J,X),J}function X6(Q,J={}){if(!Q)return[];let{max:Z=Y6}=J;return Q.slice(0,2)==="{}"&&(Q="\\{\\}"+Q.slice(2)),U0(K6(Q),Z,!0).map(V6)}function H6(Q){return"{"+Q+"}"}function W6(Q){return/^-?0\d/.test(Q)}function z6(Q,J){return Q<=J}function $6(Q,J){return Q>=J}function U0(Q,J,Z){let Y=[],K=h2("{","}",Q);if(!K)return[Q];let V=K.pre,X=K.post.length?U0(K.post,J,!1):[""];if(/\$$/.test(K.pre))for(let W=0;W<X.length&&W<J;W++){let H=V+"{"+K.body+"}"+X[W];Y.push(H)}else{let W=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(K.body),H=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(K.body),z=W||H,q=K.body.indexOf(",")>=0;if(!z&&!q)return K.post.match(/,(?!,).*\}/)?(Q=K.pre+"{"+K.body+Q2+K.post,U0(Q,J,!0)):[Q];let $;if(z)$=K.body.split(/\.\./);else if($=o2(K.body),$.length===1&&$[0]!==void 0&&($=U0($[0],J,!1).map(H6),$.length===1))return X.map((U)=>K.pre+$[0]+U);let F;if(z&&$[0]!==void 0&&$[1]!==void 0){let U=l0($[0]),G=l0($[1]),_=Math.max($[0].length,$[1].length),O=$.length===3&&$[2]!==void 0?Math.abs(l0($[2])):1,C=z6;G<U&&(O*=-1,C=$6);let j=$.some(W6);F=[];for(let k=U;C(k,G);k+=O){let B;if(H)B=String.fromCharCode(k),B==="\\"&&(B="");else if(B=String(k),j){let L=_-B.length;if(L>0){let g=Array(L+1).join("0");k<0?B="-"+g+B.slice(1):B=g+B}}F.push(B)}}else{F=[];for(let U=0;U<$.length;U++)F.push.apply(F,U0($[U],J,!1))}for(let U=0;U<F.length;U++)for(let G=0;G<X.length&&Y.length<J;G++){let _=V+F[U]+X[G];(!Z||z||_)&&Y.push(_)}}return Y}var w0=(Q)=>{if(typeof Q!="string")throw TypeError("invalid pattern");if(Q.length>65536)throw TypeError("pattern is too long")},q6={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}",!0],"[:alpha:]":["\\p{L}\\p{Nl}",!0],"[:ascii:]":["\\x00-\\x7f",!1],"[:blank:]":["\\p{Zs}\\t",!0],"[:cntrl:]":["\\p{Cc}",!0],"[:digit:]":["\\p{Nd}",!0],"[:graph:]":["\\p{Z}\\p{C}",!0,!0],"[:lower:]":["\\p{Ll}",!0],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}",!0],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f",!0],"[:upper:]":["\\p{Lu}",!0],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}",!0],"[:xdigit:]":["A-Fa-f0-9",!1]},X0=(Q)=>Q.replace(/[[\]\\-]/g,"\\$&"),U6=(Q)=>Q.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),k2=(Q)=>Q.join(""),F6=(Q,J)=>{let Z=J;if(Q.charAt(Z)!=="[")throw Error("not in a brace expression");let Y=[],K=[],V=Z+1,X=!1,W=!1,H=!1,z=!1,q=Z,$="";Q:for(;V<Q.length;){let G=Q.charAt(V);if((G==="!"||G==="^")&&V===Z+1){z=!0,V++;continue}if(G==="]"&&X&&!H){q=V+1;break}if(X=!0,G==="\\"&&!H){H=!0,V++;continue}if(G==="["&&!H){for(let[_,[O,C,j]]of Object.entries(q6))if(Q.startsWith(_,V)){if($)return["$.",!1,Q.length-Z,!0];V+=_.length,j?K.push(O):Y.push(O),W=W||C;continue Q}}if(H=!1,$){G>$?Y.push(X0($)+"-"+X0(G)):G===$&&Y.push(X0(G)),$="",V++;continue}if(Q.startsWith("-]",V+1)){Y.push(X0(G+"-")),V+=2;continue}if(Q.startsWith("-",V+1)){$=G,V+=2;continue}Y.push(X0(G)),V++}if(q<V)return["",!1,0,!1];if(!Y.length&&!K.length)return["$.",!1,Q.length-Z,!0];if(K.length===0&&Y.length===1&&/^\\?.$/.test(Y[0])&&!z){let G=Y[0].length===2?Y[0].slice(-1):Y[0];return[U6(G),!1,q-Z,!1]}let F="["+(z?"^":"")+k2(Y)+"]",U="["+(z?"":"^")+k2(K)+"]";return[Y.length&&K.length?"("+F+"|"+U+")":Y.length?F:U,W,q-Z,!0]},K0=(Q,{windowsPathsNoEscape:J=!1,magicalBraces:Z=!0}={})=>Z?J?Q.replace(/\[([^\/\\])\]/g,"$1"):Q.replace(/((?!\\).|^)\[([^\/\\])\]/g,"$1$2").replace(/\\([^\/])/g,"$1"):J?Q.replace(/\[([^\/\\{}])\]/g,"$1"):Q.replace(/((?!\\).|^)\[([^\/\\{}])\]/g,"$1$2").replace(/\\([^\/{}])/g,"$1"),G6=new Set(["!","?","+","*","@"]),B2=(Q)=>G6.has(Q),_6="(?!(?:^|/)\\.\\.?(?:$|/))",R0="(?!\\.)",C6=new Set(["[","."]),O6=new Set(["..","."]),j6=new Set("().*{}+?[]^$\\!"),k6=(Q)=>Q.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),J2="[^/]",L2=J2+"*?",R2=J2+"+?",p2=class Q{type;#Q;#Z;#K=!1;#J=[];#Y;#_;#F;#W=!1;#H;#$;#q=!1;constructor(J,Z,Y={}){this.type=J,J&&(this.#Z=!0),this.#Y=Z,this.#Q=this.#Y?this.#Y.#Q:this,this.#H=this.#Q===this?Y:this.#Q.#H,this.#F=this.#Q===this?[]:this.#Q.#F,J==="!"&&!this.#Q.#W&&this.#F.push(this),this.#_=this.#Y?this.#Y.#J.length:0}get hasMagic(){if(this.#Z!==void 0)return this.#Z;for(let J of this.#J)if(typeof J!="string"&&(J.type||J.hasMagic))return this.#Z=!0;return this.#Z}toString(){return this.#$!==void 0?this.#$:this.type?this.#$=this.type+"("+this.#J.map((J)=>String(J)).join("|")+")":this.#$=this.#J.map((J)=>String(J)).join("")}#z(){if(this!==this.#Q)throw Error("should only call on root");if(this.#W)return this;this.toString(),this.#W=!0;let J;for(;J=this.#F.pop();){if(J.type!=="!")continue;let Z=J,Y=Z.#Y;for(;Y;){for(let K=Z.#_+1;!Y.type&&K<Y.#J.length;K++)for(let V of J.#J){if(typeof V=="string")throw Error("string part in extglob AST??");V.copyIn(Y.#J[K])}Z=Y,Y=Z.#Y}}return this}push(...J){for(let Z of J)if(Z!==""){if(typeof Z!="string"&&!(Z instanceof Q&&Z.#Y===this))throw Error("invalid part: "+Z);this.#J.push(Z)}}toJSON(){let J=this.type===null?this.#J.slice().map((Z)=>typeof Z=="string"?Z:Z.toJSON()):[this.type,...this.#J.map((Z)=>Z.toJSON())];return this.isStart()&&!this.type&&J.unshift([]),this.isEnd()&&(this===this.#Q||this.#Q.#W&&this.#Y?.type==="!")&&J.push({}),J}isStart(){if(this.#Q===this)return!0;if(!this.#Y?.isStart())return!1;if(this.#_===0)return!0;let J=this.#Y;for(let Z=0;Z<this.#_;Z++){let Y=J.#J[Z];if(!(Y instanceof Q&&Y.type==="!"))return!1}return!0}isEnd(){if(this.#Q===this||this.#Y?.type==="!")return!0;if(!this.#Y?.isEnd())return!1;if(!this.type)return this.#Y?.isEnd();let J=this.#Y?this.#Y.#J.length:0;return this.#_===J-1}copyIn(J){typeof J=="string"?this.push(J):this.push(J.clone(this))}clone(J){let Z=new Q(this.type,J);for(let Y of this.#J)Z.copyIn(Y);return Z}static#X(J,Z,Y,K){let V=!1,X=!1,W=-1,H=!1;if(Z.type===null){let U=Y,G="";for(;U<J.length;){let _=J.charAt(U++);if(V||_==="\\"){V=!V,G+=_;continue}if(X){U===W+1?(_==="^"||_==="!")&&(H=!0):_==="]"&&!(U===W+2&&H)&&(X=!1),G+=_;continue}else if(_==="["){X=!0,W=U,H=!1,G+=_;continue}if(!K.noext&&B2(_)&&J.charAt(U)==="("){Z.push(G),G="";let O=new Q(_,Z);U=Q.#X(J,O,U,K),Z.push(O);continue}G+=_}return Z.push(G),U}let z=Y+1,q=new Q(null,Z),$=[],F="";for(;z<J.length;){let U=J.charAt(z++);if(V||U==="\\"){V=!V,F+=U;continue}if(X){z===W+1?(U==="^"||U==="!")&&(H=!0):U==="]"&&!(z===W+2&&H)&&(X=!1),F+=U;continue}else if(U==="["){X=!0,W=z,H=!1,F+=U;continue}if(B2(U)&&J.charAt(z)==="("){q.push(F),F="";let G=new Q(U,q);q.push(G),z=Q.#X(J,G,z,K);continue}if(U==="|"){q.push(F),F="",$.push(q),q=new Q(null,Z);continue}if(U===")")return F===""&&Z.#J.length===0&&(Z.#q=!0),q.push(F),F="",Z.push(...$,q),z;F+=U}return Z.type=null,Z.#Z=void 0,Z.#J=[J.substring(Y-1)],z}static fromGlob(J,Z={}){let Y=new Q(null,void 0,Z);return Q.#X(J,Y,0,Z),Y}toMMPattern(){if(this!==this.#Q)return this.#Q.toMMPattern();let J=this.toString(),[Z,Y,K,V]=this.toRegExpSource();if(!(K||this.#Z||this.#H.nocase&&!this.#H.nocaseMagicOnly&&J.toUpperCase()!==J.toLowerCase()))return Y;let X=(this.#H.nocase?"i":"")+(V?"u":"");return Object.assign(new RegExp(`^${Z}$`,X),{_src:Z,_glob:J})}get options(){return this.#H}toRegExpSource(J){let Z=J??!!this.#H.dot;if(this.#Q===this&&this.#z(),!this.type){let H=this.isStart()&&this.isEnd()&&!this.#J.some((F)=>typeof F!="string"),z=this.#J.map((F)=>{let[U,G,_,O]=typeof F=="string"?Q.#L(F,this.#Z,H):F.toRegExpSource(J);return this.#Z=this.#Z||_,this.#K=this.#K||O,U}).join(""),q="";if(this.isStart()&&typeof this.#J[0]=="string"&&!(this.#J.length===1&&O6.has(this.#J[0]))){let F=C6,U=Z&&F.has(z.charAt(0))||z.startsWith("\\.")&&F.has(z.charAt(2))||z.startsWith("\\.\\.")&&F.has(z.charAt(4)),G=!Z&&!J&&F.has(z.charAt(0));q=U?_6:G?R0:""}let $="";return this.isEnd()&&this.#Q.#W&&this.#Y?.type==="!"&&($="(?:$|\\/)"),[q+z+$,K0(z),this.#Z=!!this.#Z,this.#K]}let Y=this.type==="*"||this.type==="+",K=this.type==="!"?"(?:(?!(?:":"(?:",V=this.#C(Z);if(this.isStart()&&this.isEnd()&&!V&&this.type!=="!"){let H=this.toString();return this.#J=[H],this.type=null,this.#Z=void 0,[H,K0(this.toString()),!1,!1]}let X=!Y||J||Z||!R0?"":this.#C(!0);X===V&&(X=""),X&&(V=`(?:${V})(?:${X})*?`);let W="";if(this.type==="!"&&this.#q)W=(this.isStart()&&!Z?R0:"")+R2;else{let H=this.type==="!"?"))"+(this.isStart()&&!Z&&!J?R0:"")+L2+")":this.type==="@"?")":this.type==="?"?")?":this.type==="+"&&X?")":this.type==="*"&&X?")?":`)${this.type}`;W=K+V+H}return[W,K0(V),this.#Z=!!this.#Z,this.#K]}#C(J){return this.#J.map((Z)=>{if(typeof Z=="string")throw Error("string type in extglob ast??");let[Y,K,V,X]=Z.toRegExpSource(J);return this.#K=this.#K||X,Y}).filter((Z)=>!(this.isStart()&&this.isEnd())||!!Z).join("|")}static#L(J,Z,Y=!1){let K=!1,V="",X=!1,W=!1;for(let H=0;H<J.length;H++){let z=J.charAt(H);if(K){K=!1,V+=(j6.has(z)?"\\":"")+z;continue}if(z==="*"){if(W)continue;W=!0,V+=Y&&/^[*]+$/.test(J)?R2:L2,Z=!0;continue}else W=!1;if(z==="\\"){H===J.length-1?V+="\\\\":K=!0;continue}if(z==="["){let[q,$,F,U]=F6(J,H);if(F){V+=q,X=X||$,H+=F-1,Z=Z||U;continue}}if(z==="?"){V+=J2,Z=!0;continue}V+=k6(z)}return[V,K0(J),!!Z,X]}},n2=(Q,{windowsPathsNoEscape:J=!1,magicalBraces:Z=!1}={})=>Z?J?Q.replace(/[?*()[\]{}]/g,"[$&]"):Q.replace(/[?*()[\]\\{}]/g,"\\$&"):J?Q.replace(/[?*()[\]]/g,"[$&]"):Q.replace(/[?*()[\]\\]/g,"\\$&"),T=(Q,J,Z={})=>(w0(J),!Z.nocomment&&J.charAt(0)==="#"?!1:new i(J,Z).match(Q)),B6=/^\*+([^+@!?\*\[\(]*)$/,L6=(Q)=>(J)=>!J.startsWith(".")&&J.endsWith(Q),R6=(Q)=>(J)=>J.endsWith(Q),A6=(Q)=>(Q=Q.toLowerCase(),(J)=>!J.startsWith(".")&&J.toLowerCase().endsWith(Q)),I6=(Q)=>(Q=Q.toLowerCase(),(J)=>J.toLowerCase().endsWith(Q)),N6=/^\*+\.\*+$/,v6=(Q)=>!Q.startsWith(".")&&Q.includes("."),D6=(Q)=>Q!=="."&&Q!==".."&&Q.includes("."),M6=/^\.\*+$/,E6=(Q)=>Q!=="."&&Q!==".."&&Q.startsWith("."),P6=/^\*+$/,T6=(Q)=>Q.length!==0&&!Q.startsWith("."),w6=(Q)=>Q.length!==0&&Q!=="."&&Q!=="..",y6=/^\?+([^+@!?\*\[\(]*)?$/,S6=([Q,J=""])=>{let Z=r2([Q]);return J?(J=J.toLowerCase(),(Y)=>Z(Y)&&Y.toLowerCase().endsWith(J)):Z},u6=([Q,J=""])=>{let Z=i2([Q]);return J?(J=J.toLowerCase(),(Y)=>Z(Y)&&Y.toLowerCase().endsWith(J)):Z},x6=([Q,J=""])=>{let Z=i2([Q]);return J?(Y)=>Z(Y)&&Y.endsWith(J):Z},b6=([Q,J=""])=>{let Z=r2([Q]);return J?(Y)=>Z(Y)&&Y.endsWith(J):Z},r2=([Q])=>{let J=Q.length;return(Z)=>Z.length===J&&!Z.startsWith(".")},i2=([Q])=>{let J=Q.length;return(Z)=>Z.length===J&&Z!=="."&&Z!==".."},a2=typeof process=="object"&&process?typeof process.env=="object"&&process.env&&process.env.__MINIMATCH_TESTING_PLATFORM__||process.platform:"posix",A2={win32:{sep:"\\"},posix:{sep:"/"}},m6=a2==="win32"?A2.win32.sep:A2.posix.sep;T.sep=m6;var P=Symbol("globstar **");T.GLOBSTAR=P;var g6="[^/]",h6=g6+"*?",f6="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?",d6="(?:(?!(?:\\/|^)\\.).)*?",c6=(Q,J={})=>(Z)=>T(Z,Q,J);T.filter=c6;var u=(Q,J={})=>Object.assign({},Q,J),l6=(Q)=>{if(!Q||typeof Q!="object"||!Object.keys(Q).length)return T;let J=T;return Object.assign((Z,Y,K={})=>J(Z,Y,u(Q,K)),{Minimatch:class extends J.Minimatch{constructor(Z,Y={}){super(Z,u(Q,Y))}static defaults(Z){return J.defaults(u(Q,Z)).Minimatch}},AST:class extends J.AST{constructor(Z,Y,K={}){super(Z,Y,u(Q,K))}static fromGlob(Z,Y={}){return J.AST.fromGlob(Z,u(Q,Y))}},unescape:(Z,Y={})=>J.unescape(Z,u(Q,Y)),escape:(Z,Y={})=>J.escape(Z,u(Q,Y)),filter:(Z,Y={})=>J.filter(Z,u(Q,Y)),defaults:(Z)=>J.defaults(u(Q,Z)),makeRe:(Z,Y={})=>J.makeRe(Z,u(Q,Y)),braceExpand:(Z,Y={})=>J.braceExpand(Z,u(Q,Y)),match:(Z,Y,K={})=>J.match(Z,Y,u(Q,K)),sep:J.sep,GLOBSTAR:P})};T.defaults=l6;var s2=(Q,J={})=>(w0(Q),J.nobrace||!/\{(?:(?!\{).)*\}/.test(Q)?[Q]:X6(Q,{max:J.braceExpandMax}));T.braceExpand=s2;var o6=(Q,J={})=>new i(Q,J).makeRe();T.makeRe=o6;var p6=(Q,J,Z={})=>{let Y=new i(J,Z);return Q=Q.filter((K)=>Y.match(K)),Y.options.nonull&&!Q.length&&Q.push(J),Q};T.match=p6;var I2=/[?*]|[+@!]\(.*?\)|\[|\]/,n6=(Q)=>Q.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),i=class{options;set;pattern;windowsPathsNoEscape;nonegate;negate;comment;empty;preserveMultipleSlashes;partial;globSet;globParts;nocase;isWindows;platform;windowsNoMagicRoot;regexp;constructor(Q,J={}){w0(Q),J=J||{},this.options=J,this.pattern=Q,this.platform=J.platform||a2,this.isWindows=this.platform==="win32";let Z="allowWindowsEscape";this.windowsPathsNoEscape=!!J.windowsPathsNoEscape||J[Z]===!1,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!J.preserveMultipleSlashes,this.regexp=null,this.negate=!1,this.nonegate=!!J.nonegate,this.comment=!1,this.empty=!1,this.partial=!!J.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=J.windowsNoMagicRoot!==void 0?J.windowsNoMagicRoot:!!(this.isWindows&&this.nocase),this.globSet=[],this.globParts=[],this.set=[],this.make()}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(let Q of this.set)for(let J of Q)if(typeof J!="string")return!0;return!1}debug(...Q){}make(){let Q=this.pattern,J=this.options;if(!J.nocomment&&Q.charAt(0)==="#"){this.comment=!0;return}if(!Q){this.empty=!0;return}this.parseNegate(),this.globSet=[...new Set(this.braceExpand())],J.debug&&(this.debug=(...K)=>console.error(...K)),this.debug(this.pattern,this.globSet);let Z=this.globSet.map((K)=>this.slashSplit(K));this.globParts=this.preprocess(Z),this.debug(this.pattern,this.globParts);let Y=this.globParts.map((K,V,X)=>{if(this.isWindows&&this.windowsNoMagicRoot){let W=K[0]===""&&K[1]===""&&(K[2]==="?"||!I2.test(K[2]))&&!I2.test(K[3]),H=/^[a-z]:/i.test(K[0]);if(W)return[...K.slice(0,4),...K.slice(4).map((z)=>this.parse(z))];if(H)return[K[0],...K.slice(1).map((z)=>this.parse(z))]}return K.map((W)=>this.parse(W))});if(this.debug(this.pattern,Y),this.set=Y.filter((K)=>K.indexOf(!1)===-1),this.isWindows)for(let K=0;K<this.set.length;K++){let V=this.set[K];V[0]===""&&V[1]===""&&this.globParts[K][2]==="?"&&typeof V[3]=="string"&&/^[a-z]:$/i.test(V[3])&&(V[2]="?")}this.debug(this.pattern,this.set)}preprocess(Q){if(this.options.noglobstar)for(let Z=0;Z<Q.length;Z++)for(let Y=0;Y<Q[Z].length;Y++)Q[Z][Y]==="**"&&(Q[Z][Y]="*");let{optimizationLevel:J=1}=this.options;return J>=2?(Q=this.firstPhasePreProcess(Q),Q=this.secondPhasePreProcess(Q)):J>=1?Q=this.levelOneOptimize(Q):Q=this.adjascentGlobstarOptimize(Q),Q}adjascentGlobstarOptimize(Q){return Q.map((J)=>{let Z=-1;for(;(Z=J.indexOf("**",Z+1))!==-1;){let Y=Z;for(;J[Y+1]==="**";)Y++;Y!==Z&&J.splice(Z,Y-Z)}return J})}levelOneOptimize(Q){return Q.map((J)=>(J=J.reduce((Z,Y)=>{let K=Z[Z.length-1];return Y==="**"&&K==="**"?Z:Y===".."&&K&&K!==".."&&K!=="."&&K!=="**"?(Z.pop(),Z):(Z.push(Y),Z)},[]),J.length===0?[""]:J))}levelTwoFileOptimize(Q){Array.isArray(Q)||(Q=this.slashSplit(Q));let J=!1;do{if(J=!1,!this.preserveMultipleSlashes){for(let Y=1;Y<Q.length-1;Y++){let K=Q[Y];Y===1&&K===""&&Q[0]===""||(K==="."||K==="")&&(J=!0,Q.splice(Y,1),Y--)}Q[0]==="."&&Q.length===2&&(Q[1]==="."||Q[1]==="")&&(J=!0,Q.pop())}let Z=0;for(;(Z=Q.indexOf("..",Z+1))!==-1;){let Y=Q[Z-1];Y&&Y!=="."&&Y!==".."&&Y!=="**"&&(J=!0,Q.splice(Z-1,2),Z-=2)}}while(J);return Q.length===0?[""]:Q}firstPhasePreProcess(Q){let J=!1;do{J=!1;for(let Z of Q){let Y=-1;for(;(Y=Z.indexOf("**",Y+1))!==-1;){let V=Y;for(;Z[V+1]==="**";)V++;V>Y&&Z.splice(Y+1,V-Y);let X=Z[Y+1],W=Z[Y+2],H=Z[Y+3];if(X!==".."||!W||W==="."||W===".."||!H||H==="."||H==="..")continue;J=!0,Z.splice(Y,1);let z=Z.slice(0);z[Y]="**",Q.push(z),Y--}if(!this.preserveMultipleSlashes){for(let V=1;V<Z.length-1;V++){let X=Z[V];V===1&&X===""&&Z[0]===""||(X==="."||X==="")&&(J=!0,Z.splice(V,1),V--)}Z[0]==="."&&Z.length===2&&(Z[1]==="."||Z[1]==="")&&(J=!0,Z.pop())}let K=0;for(;(K=Z.indexOf("..",K+1))!==-1;){let V=Z[K-1];if(V&&V!=="."&&V!==".."&&V!=="**"){J=!0;let X=K===1&&Z[K+1]==="**"?["."]:[];Z.splice(K-1,2,...X),Z.length===0&&Z.push(""),K-=2}}}}while(J);return Q}secondPhasePreProcess(Q){for(let J=0;J<Q.length-1;J++)for(let Z=J+1;Z<Q.length;Z++){let Y=this.partsMatch(Q[J],Q[Z],!this.preserveMultipleSlashes);if(Y){Q[J]=[],Q[Z]=Y;break}}return Q.filter((J)=>J.length)}partsMatch(Q,J,Z=!1){let Y=0,K=0,V=[],X="";for(;Y<Q.length&&K<J.length;)if(Q[Y]===J[K])V.push(X==="b"?J[K]:Q[Y]),Y++,K++;else if(Z&&Q[Y]==="**"&&J[K]===Q[Y+1])V.push(Q[Y]),Y++;else if(Z&&J[K]==="**"&&Q[Y]===J[K+1])V.push(J[K]),K++;else if(Q[Y]==="*"&&J[K]&&(this.options.dot||!J[K].startsWith("."))&&J[K]!=="**"){if(X==="b")return!1;X="a",V.push(Q[Y]),Y++,K++}else if(J[K]==="*"&&Q[Y]&&(this.options.dot||!Q[Y].startsWith("."))&&Q[Y]!=="**"){if(X==="a")return!1;X="b",V.push(J[K]),Y++,K++}else return!1;return Q.length===J.length&&V}parseNegate(){if(this.nonegate)return;let Q=this.pattern,J=!1,Z=0;for(let Y=0;Y<Q.length&&Q.charAt(Y)==="!";Y++)J=!J,Z++;Z&&(this.pattern=Q.slice(Z)),this.negate=J}matchOne(Q,J,Z=!1){let Y=this.options;if(this.isWindows){let G=typeof Q[0]=="string"&&/^[a-z]:$/i.test(Q[0]),_=!G&&Q[0]===""&&Q[1]===""&&Q[2]==="?"&&/^[a-z]:$/i.test(Q[3]),O=typeof J[0]=="string"&&/^[a-z]:$/i.test(J[0]),C=!O&&J[0]===""&&J[1]===""&&J[2]==="?"&&typeof J[3]=="string"&&/^[a-z]:$/i.test(J[3]),j=_?3:G?0:void 0,k=C?3:O?0:void 0;if(typeof j=="number"&&typeof k=="number"){let[B,L]=[Q[j],J[k]];B.toLowerCase()===L.toLowerCase()&&(J[k]=B,k>j?J=J.slice(k):j>k&&(Q=Q.slice(j)))}}let{optimizationLevel:K=1}=this.options;K>=2&&(Q=this.levelTwoFileOptimize(Q)),this.debug("matchOne",this,{file:Q,pattern:J}),this.debug("matchOne",Q.length,J.length);for(var V=0,X=0,W=Q.length,H=J.length;V<W&&X<H;V++,X++){this.debug("matchOne loop");var z=J[X],q=Q[V];if(this.debug(J,z,q),z===!1)return!1;if(z===P){this.debug("GLOBSTAR",[J,z,q]);var $=V,F=X+1;if(F===H){for(this.debug("** at the end");V<W;V++)if(Q[V]==="."||Q[V]===".."||!Y.dot&&Q[V].charAt(0)===".")return!1;return!0}for(;$<W;){var U=Q[$];if(this.debug(`
|
|
3
|
+
globstar while`,Q,$,J,F,U),this.matchOne(Q.slice($),J.slice(F),Z))return this.debug("globstar found match!",$,W,U),!0;if(U==="."||U===".."||!Y.dot&&U.charAt(0)==="."){this.debug("dot detected!",Q,$,J,F);break}this.debug("globstar swallow a segment, and continue"),$++}return!!(Z&&(this.debug(`
|
|
4
|
+
>>> no match, partial?`,Q,$,J,F),$===W))}let G;if(typeof z=="string"?(G=q===z,this.debug("string match",z,q,G)):(G=z.test(q),this.debug("pattern match",z,q,G)),!G)return!1}if(V===W&&X===H)return!0;if(V===W)return Z;if(X===H)return V===W-1&&Q[V]==="";throw Error("wtf?")}braceExpand(){return s2(this.pattern,this.options)}parse(Q){w0(Q);let J=this.options;if(Q==="**")return P;if(Q==="")return"";let Z,Y=null;(Z=Q.match(P6))?Y=J.dot?w6:T6:(Z=Q.match(B6))?Y=(J.nocase?J.dot?I6:A6:J.dot?R6:L6)(Z[1]):(Z=Q.match(y6))?Y=(J.nocase?J.dot?u6:S6:J.dot?x6:b6)(Z):(Z=Q.match(N6))?Y=J.dot?D6:v6:(Z=Q.match(M6))&&(Y=E6);let K=p2.fromGlob(Q,this.options).toMMPattern();return Y&&typeof K=="object"&&Reflect.defineProperty(K,"test",{value:Y}),K}makeRe(){if(this.regexp||this.regexp===!1)return this.regexp;let Q=this.set;if(!Q.length)return this.regexp=!1,this.regexp;let J=this.options,Z=J.noglobstar?h6:J.dot?f6:d6,Y=new Set(J.nocase?["i"]:[]),K=Q.map((W)=>{let H=W.map((q)=>{if(q instanceof RegExp)for(let $ of q.flags.split(""))Y.add($);return typeof q=="string"?n6(q):q===P?P:q._src});H.forEach((q,$)=>{let F=H[$+1],U=H[$-1];q!==P||U===P||(U===void 0?F!==void 0&&F!==P?H[$+1]="(?:\\/|"+Z+"\\/)?"+F:H[$]=Z:F===void 0?H[$-1]=U+"(?:\\/|\\/"+Z+")?":F!==P&&(H[$-1]=U+"(?:\\/|\\/"+Z+"\\/)"+F,H[$+1]=P))});let z=H.filter((q)=>q!==P);if(this.partial&&z.length>=1){let q=[];for(let $=1;$<=z.length;$++)q.push(z.slice(0,$).join("/"));return"(?:"+q.join("|")+")"}return z.join("/")}).join("|"),[V,X]=Q.length>1?["(?:",")"]:["",""];K="^"+V+K+X+"$",this.partial&&(K="^(?:\\/|"+V+K.slice(1,-1)+X+")$"),this.negate&&(K="^(?!"+K+").+$");try{this.regexp=new RegExp(K,[...Y].join(""))}catch{this.regexp=!1}return this.regexp}slashSplit(Q){return this.preserveMultipleSlashes?Q.split("/"):this.isWindows&&/^\/\/[^\/]+/.test(Q)?["",...Q.split(/\/+/)]:Q.split(/\/+/)}match(Q,J=this.partial){if(this.debug("match",Q,this.pattern),this.comment)return!1;if(this.empty)return Q==="";if(Q==="/"&&J)return!0;let Z=this.options;this.isWindows&&(Q=Q.split("\\").join("/"));let Y=this.slashSplit(Q);this.debug(this.pattern,"split",Y);let K=this.set;this.debug(this.pattern,"set",K);let V=Y[Y.length-1];if(!V)for(let X=Y.length-2;!V&&X>=0;X--)V=Y[X];for(let X=0;X<K.length;X++){let W=K[X],H=Y;if(Z.matchBase&&W.length===1&&(H=[V]),this.matchOne(H,W,J))return Z.flipNegate?!0:!this.negate}return Z.flipNegate?!1:this.negate}static defaults(Q){return T.defaults(Q).Minimatch}};T.AST=p2;T.Minimatch=i;T.escape=n2;T.unescape=K0;var i6=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,e2=new Set,e0=typeof process=="object"&&process?process:{},t2=(Q,J,Z,Y)=>{typeof e0.emitWarning=="function"?e0.emitWarning(Q,J,Z,Y):console.error(`[${Z}] ${J}: ${Q}`)},y0=globalThis.AbortController,N2=globalThis.AbortSignal;if(typeof y0>"u"){N2=class{onabort;_onabort=[];reason;aborted=!1;addEventListener(Z,Y){this._onabort.push(Y)}},y0=class{constructor(){J()}signal=new N2;abort(Z){if(!this.signal.aborted){this.signal.reason=Z,this.signal.aborted=!0;for(let Y of this.signal._onabort)Y(Z);this.signal.onabort?.(Z)}}};let Q=e0.env?.LRU_CACHE_IGNORE_AC_WARNING!=="1",J=()=>{Q&&(Q=!1,t2("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",J))}}var a6=(Q)=>!e2.has(Q),r=(Q)=>Q&&Q===Math.floor(Q)&&Q>0&&isFinite(Q),Q5=(Q)=>r(Q)?Q<=Math.pow(2,8)?Uint8Array:Q<=Math.pow(2,16)?Uint16Array:Q<=Math.pow(2,32)?Uint32Array:Q<=Number.MAX_SAFE_INTEGER?P0:null:null,P0=class extends Array{constructor(Q){super(Q),this.fill(0)}},s6=class Q{heap;length;static#Q=!1;static create(J){let Z=Q5(J);if(!Z)return[];Q.#Q=!0;let Y=new Q(J,Z);return Q.#Q=!1,Y}constructor(J,Z){if(!Q.#Q)throw TypeError("instantiate Stack using Stack.create(n)");this.heap=new Z(J),this.length=0}push(J){this.heap[this.length++]=J}pop(){return this.heap[--this.length]}},x0=class Q{#Q;#Z;#K;#J;#Y;#_;#F;#W;get perf(){return this.#W}ttl;ttlResolution;ttlAutopurge;updateAgeOnGet;updateAgeOnHas;allowStale;noDisposeOnSet;noUpdateTTL;maxEntrySize;sizeCalculation;noDeleteOnFetchRejection;noDeleteOnStaleGet;allowStaleOnFetchAbort;allowStaleOnFetchRejection;ignoreFetchAbort;#H;#$;#q;#z;#X;#C;#L;#O;#j;#v;#k;#A;#I;#G;#B;#R;#D;#V;#S;static unsafeExposeInternals(J){return{starts:J.#I,ttls:J.#G,autopurgeTimers:J.#B,sizes:J.#A,keyMap:J.#q,keyList:J.#z,valList:J.#X,next:J.#C,prev:J.#L,get head(){return J.#O},get tail(){return J.#j},free:J.#v,isBackgroundFetch:(Z)=>J.#U(Z),backgroundFetch:(Z,Y,K,V)=>J.#d(Z,Y,K,V),moveToTail:(Z)=>J.#x(Z),indexes:(Z)=>J.#P(Z),rindexes:(Z)=>J.#T(Z),isStale:(Z)=>J.#N(Z)}}get max(){return this.#Q}get maxSize(){return this.#Z}get calculatedSize(){return this.#$}get size(){return this.#H}get fetchMethod(){return this.#_}get memoMethod(){return this.#F}get dispose(){return this.#K}get onInsert(){return this.#J}get disposeAfter(){return this.#Y}constructor(J){let{max:Z=0,ttl:Y,ttlResolution:K=1,ttlAutopurge:V,updateAgeOnGet:X,updateAgeOnHas:W,allowStale:H,dispose:z,onInsert:q,disposeAfter:$,noDisposeOnSet:F,noUpdateTTL:U,maxSize:G=0,maxEntrySize:_=0,sizeCalculation:O,fetchMethod:C,memoMethod:j,noDeleteOnFetchRejection:k,noDeleteOnStaleGet:B,allowStaleOnFetchRejection:L,allowStaleOnFetchAbort:g,ignoreFetchAbort:l,perf:Q0}=J;if(Q0!==void 0&&typeof Q0?.now!="function")throw TypeError("perf option must have a now() method if specified");if(this.#W=Q0??i6,Z!==0&&!r(Z))throw TypeError("max option must be a nonnegative integer");let J0=Z?Q5(Z):Array;if(!J0)throw Error("invalid max value: "+Z);if(this.#Q=Z,this.#Z=G,this.maxEntrySize=_||this.#Z,this.sizeCalculation=O,this.sizeCalculation){if(!this.#Z&&!this.maxEntrySize)throw TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw TypeError("sizeCalculation set to non-function")}if(j!==void 0&&typeof j!="function")throw TypeError("memoMethod must be a function if defined");if(this.#F=j,C!==void 0&&typeof C!="function")throw TypeError("fetchMethod must be a function if specified");if(this.#_=C,this.#D=!!C,this.#q=new Map,this.#z=Array(Z).fill(void 0),this.#X=Array(Z).fill(void 0),this.#C=new J0(Z),this.#L=new J0(Z),this.#O=0,this.#j=0,this.#v=s6.create(Z),this.#H=0,this.#$=0,typeof z=="function"&&(this.#K=z),typeof q=="function"&&(this.#J=q),typeof $=="function"?(this.#Y=$,this.#k=[]):(this.#Y=void 0,this.#k=void 0),this.#R=!!this.#K,this.#S=!!this.#J,this.#V=!!this.#Y,this.noDisposeOnSet=!!F,this.noUpdateTTL=!!U,this.noDeleteOnFetchRejection=!!k,this.allowStaleOnFetchRejection=!!L,this.allowStaleOnFetchAbort=!!g,this.ignoreFetchAbort=!!l,this.maxEntrySize!==0){if(this.#Z!==0&&!r(this.#Z))throw TypeError("maxSize must be a positive integer if specified");if(!r(this.maxEntrySize))throw TypeError("maxEntrySize must be a positive integer if specified");this.#l()}if(this.allowStale=!!H,this.noDeleteOnStaleGet=!!B,this.updateAgeOnGet=!!X,this.updateAgeOnHas=!!W,this.ttlResolution=r(K)||K===0?K:1,this.ttlAutopurge=!!V,this.ttl=Y||0,this.ttl){if(!r(this.ttl))throw TypeError("ttl must be a positive integer if specified");this.#w()}if(this.#Q===0&&this.ttl===0&&this.#Z===0)throw TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!this.#Q&&!this.#Z){let c0="LRU_CACHE_UNBOUNDED";a6(c0)&&(e2.add(c0),t2("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",c0,Q))}}getRemainingTTL(J){return this.#q.has(J)?1/0:0}#w(){let J=new P0(this.#Q),Z=new P0(this.#Q);this.#G=J,this.#I=Z;let Y=this.ttlAutopurge?Array(this.#Q):void 0;this.#B=Y,this.#m=(X,W,H=this.#W.now())=>{if(Z[X]=W!==0?H:0,J[X]=W,Y?.[X]&&(clearTimeout(Y[X]),Y[X]=void 0),W!==0&&Y){let z=setTimeout(()=>{this.#N(X)&&this.#E(this.#z[X],"expire")},W+1);z.unref&&z.unref(),Y[X]=z}},this.#M=(X)=>{Z[X]=J[X]!==0?this.#W.now():0},this.#y=(X,W)=>{if(J[W]){let H=J[W],z=Z[W];if(!H||!z)return;X.ttl=H,X.start=z,X.now=K||V();let q=X.now-z;X.remainingTTL=H-q}};let K=0,V=()=>{let X=this.#W.now();if(this.ttlResolution>0){K=X;let W=setTimeout(()=>K=0,this.ttlResolution);W.unref&&W.unref()}return X};this.getRemainingTTL=(X)=>{let W=this.#q.get(X);if(W===void 0)return 0;let H=J[W],z=Z[W];if(!H||!z)return 1/0;let q=(K||V())-z;return H-q},this.#N=(X)=>{let W=Z[X],H=J[X];return!!H&&!!W&&(K||V())-W>H}}#M=()=>{};#y=()=>{};#m=()=>{};#N=()=>!1;#l(){let J=new P0(this.#Q);this.#$=0,this.#A=J,this.#b=(Z)=>{this.#$-=J[Z],J[Z]=0},this.#g=(Z,Y,K,V)=>{if(this.#U(Y))return 0;if(!r(K))if(V){if(typeof V!="function")throw TypeError("sizeCalculation must be a function");if(K=V(Y,Z),!r(K))throw TypeError("sizeCalculation return invalid (expect positive integer)")}else throw TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");return K},this.#u=(Z,Y,K)=>{if(J[Z]=Y,this.#Z){let V=this.#Z-J[Z];for(;this.#$>V;)this.#f(!0)}this.#$+=J[Z],K&&(K.entrySize=Y,K.totalCalculatedSize=this.#$)}}#b=(J)=>{};#u=(J,Z,Y)=>{};#g=(J,Z,Y,K)=>{if(Y||K)throw TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0};*#P({allowStale:J=this.allowStale}={}){if(this.#H)for(let Z=this.#j;!(!this.#h(Z)||((J||!this.#N(Z))&&(yield Z),Z===this.#O));)Z=this.#L[Z]}*#T({allowStale:J=this.allowStale}={}){if(this.#H)for(let Z=this.#O;!(!this.#h(Z)||((J||!this.#N(Z))&&(yield Z),Z===this.#j));)Z=this.#C[Z]}#h(J){return J!==void 0&&this.#q.get(this.#z[J])===J}*entries(){for(let J of this.#P())this.#X[J]!==void 0&&this.#z[J]!==void 0&&!this.#U(this.#X[J])&&(yield[this.#z[J],this.#X[J]])}*rentries(){for(let J of this.#T())this.#X[J]!==void 0&&this.#z[J]!==void 0&&!this.#U(this.#X[J])&&(yield[this.#z[J],this.#X[J]])}*keys(){for(let J of this.#P()){let Z=this.#z[J];Z!==void 0&&!this.#U(this.#X[J])&&(yield Z)}}*rkeys(){for(let J of this.#T()){let Z=this.#z[J];Z!==void 0&&!this.#U(this.#X[J])&&(yield Z)}}*values(){for(let J of this.#P())this.#X[J]!==void 0&&!this.#U(this.#X[J])&&(yield this.#X[J])}*rvalues(){for(let J of this.#T())this.#X[J]!==void 0&&!this.#U(this.#X[J])&&(yield this.#X[J])}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="LRUCache";find(J,Z={}){for(let Y of this.#P()){let K=this.#X[Y],V=this.#U(K)?K.__staleWhileFetching:K;if(V!==void 0&&J(V,this.#z[Y],this))return this.get(this.#z[Y],Z)}}forEach(J,Z=this){for(let Y of this.#P()){let K=this.#X[Y],V=this.#U(K)?K.__staleWhileFetching:K;V!==void 0&&J.call(Z,V,this.#z[Y],this)}}rforEach(J,Z=this){for(let Y of this.#T()){let K=this.#X[Y],V=this.#U(K)?K.__staleWhileFetching:K;V!==void 0&&J.call(Z,V,this.#z[Y],this)}}purgeStale(){let J=!1;for(let Z of this.#T({allowStale:!0}))this.#N(Z)&&(this.#E(this.#z[Z],"expire"),J=!0);return J}info(J){let Z=this.#q.get(J);if(Z===void 0)return;let Y=this.#X[Z],K=this.#U(Y)?Y.__staleWhileFetching:Y;if(K===void 0)return;let V={value:K};if(this.#G&&this.#I){let X=this.#G[Z],W=this.#I[Z];if(X&&W){let H=X-(this.#W.now()-W);V.ttl=H,V.start=Date.now()}}return this.#A&&(V.size=this.#A[Z]),V}dump(){let J=[];for(let Z of this.#P({allowStale:!0})){let Y=this.#z[Z],K=this.#X[Z],V=this.#U(K)?K.__staleWhileFetching:K;if(V===void 0||Y===void 0)continue;let X={value:V};if(this.#G&&this.#I){X.ttl=this.#G[Z];let W=this.#W.now()-this.#I[Z];X.start=Math.floor(Date.now()-W)}this.#A&&(X.size=this.#A[Z]),J.unshift([Y,X])}return J}load(J){this.clear();for(let[Z,Y]of J){if(Y.start){let K=Date.now()-Y.start;Y.start=this.#W.now()-K}this.set(Z,Y.value,Y)}}set(J,Z,Y={}){if(Z===void 0)return this.delete(J),this;let{ttl:K=this.ttl,start:V,noDisposeOnSet:X=this.noDisposeOnSet,sizeCalculation:W=this.sizeCalculation,status:H}=Y,{noUpdateTTL:z=this.noUpdateTTL}=Y,q=this.#g(J,Z,Y.size||0,W);if(this.maxEntrySize&&q>this.maxEntrySize)return H&&(H.set="miss",H.maxEntrySizeExceeded=!0),this.#E(J,"set"),this;let $=this.#H===0?void 0:this.#q.get(J);if($===void 0)$=this.#H===0?this.#j:this.#v.length!==0?this.#v.pop():this.#H===this.#Q?this.#f(!1):this.#H,this.#z[$]=J,this.#X[$]=Z,this.#q.set(J,$),this.#C[this.#j]=$,this.#L[$]=this.#j,this.#j=$,this.#H++,this.#u($,q,H),H&&(H.set="add"),z=!1,this.#S&&this.#J?.(Z,J,"add");else{this.#x($);let F=this.#X[$];if(Z!==F){if(this.#D&&this.#U(F)){F.__abortController.abort(Error("replaced"));let{__staleWhileFetching:U}=F;U!==void 0&&!X&&(this.#R&&this.#K?.(U,J,"set"),this.#V&&this.#k?.push([U,J,"set"]))}else X||(this.#R&&this.#K?.(F,J,"set"),this.#V&&this.#k?.push([F,J,"set"]));if(this.#b($),this.#u($,q,H),this.#X[$]=Z,H){H.set="replace";let U=F&&this.#U(F)?F.__staleWhileFetching:F;U!==void 0&&(H.oldValue=U)}}else H&&(H.set="update");this.#S&&this.onInsert?.(Z,J,Z===F?"update":"replace")}if(K!==0&&!this.#G&&this.#w(),this.#G&&(z||this.#m($,K,V),H&&this.#y(H,$)),!X&&this.#V&&this.#k){let F=this.#k,U;for(;U=F?.shift();)this.#Y?.(...U)}return this}pop(){try{for(;this.#H;){let J=this.#X[this.#O];if(this.#f(!0),this.#U(J)){if(J.__staleWhileFetching)return J.__staleWhileFetching}else if(J!==void 0)return J}}finally{if(this.#V&&this.#k){let J=this.#k,Z;for(;Z=J?.shift();)this.#Y?.(...Z)}}}#f(J){let Z=this.#O,Y=this.#z[Z],K=this.#X[Z];return this.#D&&this.#U(K)?K.__abortController.abort(Error("evicted")):(this.#R||this.#V)&&(this.#R&&this.#K?.(K,Y,"evict"),this.#V&&this.#k?.push([K,Y,"evict"])),this.#b(Z),this.#B?.[Z]&&(clearTimeout(this.#B[Z]),this.#B[Z]=void 0),J&&(this.#z[Z]=void 0,this.#X[Z]=void 0,this.#v.push(Z)),this.#H===1?(this.#O=this.#j=0,this.#v.length=0):this.#O=this.#C[Z],this.#q.delete(Y),this.#H--,Z}has(J,Z={}){let{updateAgeOnHas:Y=this.updateAgeOnHas,status:K}=Z,V=this.#q.get(J);if(V!==void 0){let X=this.#X[V];if(this.#U(X)&&X.__staleWhileFetching===void 0)return!1;if(this.#N(V))K&&(K.has="stale",this.#y(K,V));else return Y&&this.#M(V),K&&(K.has="hit",this.#y(K,V)),!0}else K&&(K.has="miss");return!1}peek(J,Z={}){let{allowStale:Y=this.allowStale}=Z,K=this.#q.get(J);if(K===void 0||!Y&&this.#N(K))return;let V=this.#X[K];return this.#U(V)?V.__staleWhileFetching:V}#d(J,Z,Y,K){let V=Z===void 0?void 0:this.#X[Z];if(this.#U(V))return V;let X=new y0,{signal:W}=Y;W?.addEventListener("abort",()=>X.abort(W.reason),{signal:X.signal});let H={signal:X.signal,options:Y,context:K},z=(_,O=!1)=>{let{aborted:C}=X.signal,j=Y.ignoreFetchAbort&&_!==void 0,k=Y.ignoreFetchAbort||!!(Y.allowStaleOnFetchAbort&&_!==void 0);if(Y.status&&(C&&!O?(Y.status.fetchAborted=!0,Y.status.fetchError=X.signal.reason,j&&(Y.status.fetchAbortIgnored=!0)):Y.status.fetchResolved=!0),C&&!j&&!O)return $(X.signal.reason,k);let B=U,L=this.#X[Z];return(L===U||j&&O&&L===void 0)&&(_===void 0?B.__staleWhileFetching!==void 0?this.#X[Z]=B.__staleWhileFetching:this.#E(J,"fetch"):(Y.status&&(Y.status.fetchUpdated=!0),this.set(J,_,H.options))),_},q=(_)=>(Y.status&&(Y.status.fetchRejected=!0,Y.status.fetchError=_),$(_,!1)),$=(_,O)=>{let{aborted:C}=X.signal,j=C&&Y.allowStaleOnFetchAbort,k=j||Y.allowStaleOnFetchRejection,B=k||Y.noDeleteOnFetchRejection,L=U;if(this.#X[Z]===U&&(!B||!O&&L.__staleWhileFetching===void 0?this.#E(J,"fetch"):j||(this.#X[Z]=L.__staleWhileFetching)),k)return Y.status&&L.__staleWhileFetching!==void 0&&(Y.status.returnedStale=!0),L.__staleWhileFetching;if(L.__returned===L)throw _},F=(_,O)=>{let C=this.#_?.(J,V,H);C&&C instanceof Promise&&C.then((j)=>_(j===void 0?void 0:j),O),X.signal.addEventListener("abort",()=>{(!Y.ignoreFetchAbort||Y.allowStaleOnFetchAbort)&&(_(void 0),Y.allowStaleOnFetchAbort&&(_=(j)=>z(j,!0)))})};Y.status&&(Y.status.fetchDispatched=!0);let U=new Promise(F).then(z,q),G=Object.assign(U,{__abortController:X,__staleWhileFetching:V,__returned:void 0});return Z===void 0?(this.set(J,G,{...H.options,status:void 0}),Z=this.#q.get(J)):this.#X[Z]=G,G}#U(J){if(!this.#D)return!1;let Z=J;return!!Z&&Z instanceof Promise&&Z.hasOwnProperty("__staleWhileFetching")&&Z.__abortController instanceof y0}async fetch(J,Z={}){let{allowStale:Y=this.allowStale,updateAgeOnGet:K=this.updateAgeOnGet,noDeleteOnStaleGet:V=this.noDeleteOnStaleGet,ttl:X=this.ttl,noDisposeOnSet:W=this.noDisposeOnSet,size:H=0,sizeCalculation:z=this.sizeCalculation,noUpdateTTL:q=this.noUpdateTTL,noDeleteOnFetchRejection:$=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:F=this.allowStaleOnFetchRejection,ignoreFetchAbort:U=this.ignoreFetchAbort,allowStaleOnFetchAbort:G=this.allowStaleOnFetchAbort,context:_,forceRefresh:O=!1,status:C,signal:j}=Z;if(!this.#D)return C&&(C.fetch="get"),this.get(J,{allowStale:Y,updateAgeOnGet:K,noDeleteOnStaleGet:V,status:C});let k={allowStale:Y,updateAgeOnGet:K,noDeleteOnStaleGet:V,ttl:X,noDisposeOnSet:W,size:H,sizeCalculation:z,noUpdateTTL:q,noDeleteOnFetchRejection:$,allowStaleOnFetchRejection:F,allowStaleOnFetchAbort:G,ignoreFetchAbort:U,status:C,signal:j},B=this.#q.get(J);if(B===void 0){C&&(C.fetch="miss");let L=this.#d(J,B,k,_);return L.__returned=L}else{let L=this.#X[B];if(this.#U(L)){let J0=Y&&L.__staleWhileFetching!==void 0;return C&&(C.fetch="inflight",J0&&(C.returnedStale=!0)),J0?L.__staleWhileFetching:L.__returned=L}let g=this.#N(B);if(!O&&!g)return C&&(C.fetch="hit"),this.#x(B),K&&this.#M(B),C&&this.#y(C,B),L;let l=this.#d(J,B,k,_),Q0=l.__staleWhileFetching!==void 0&&Y;return C&&(C.fetch=g?"stale":"refresh",Q0&&g&&(C.returnedStale=!0)),Q0?l.__staleWhileFetching:l.__returned=l}}async forceFetch(J,Z={}){let Y=await this.fetch(J,Z);if(Y===void 0)throw Error("fetch() returned undefined");return Y}memo(J,Z={}){let Y=this.#F;if(!Y)throw Error("no memoMethod provided to constructor");let{context:K,forceRefresh:V,...X}=Z,W=this.get(J,X);if(!V&&W!==void 0)return W;let H=Y(J,W,{options:X,context:K});return this.set(J,H,X),H}get(J,Z={}){let{allowStale:Y=this.allowStale,updateAgeOnGet:K=this.updateAgeOnGet,noDeleteOnStaleGet:V=this.noDeleteOnStaleGet,status:X}=Z,W=this.#q.get(J);if(W!==void 0){let H=this.#X[W],z=this.#U(H);return X&&this.#y(X,W),this.#N(W)?(X&&(X.get="stale"),z?(X&&Y&&H.__staleWhileFetching!==void 0&&(X.returnedStale=!0),Y?H.__staleWhileFetching:void 0):(V||this.#E(J,"expire"),X&&Y&&(X.returnedStale=!0),Y?H:void 0)):(X&&(X.get="hit"),z?H.__staleWhileFetching:(this.#x(W),K&&this.#M(W),H))}else X&&(X.get="miss")}#c(J,Z){this.#L[Z]=J,this.#C[J]=Z}#x(J){J!==this.#j&&(J===this.#O?this.#O=this.#C[J]:this.#c(this.#L[J],this.#C[J]),this.#c(this.#j,J),this.#j=J)}delete(J){return this.#E(J,"delete")}#E(J,Z){let Y=!1;if(this.#H!==0){let K=this.#q.get(J);if(K!==void 0)if(this.#B?.[K]&&(clearTimeout(this.#B?.[K]),this.#B[K]=void 0),Y=!0,this.#H===1)this.#o(Z);else{this.#b(K);let V=this.#X[K];if(this.#U(V)?V.__abortController.abort(Error("deleted")):(this.#R||this.#V)&&(this.#R&&this.#K?.(V,J,Z),this.#V&&this.#k?.push([V,J,Z])),this.#q.delete(J),this.#z[K]=void 0,this.#X[K]=void 0,K===this.#j)this.#j=this.#L[K];else if(K===this.#O)this.#O=this.#C[K];else{let X=this.#L[K];this.#C[X]=this.#C[K];let W=this.#C[K];this.#L[W]=this.#L[K]}this.#H--,this.#v.push(K)}}if(this.#V&&this.#k?.length){let K=this.#k,V;for(;V=K?.shift();)this.#Y?.(...V)}return Y}clear(){return this.#o("delete")}#o(J){for(let Z of this.#T({allowStale:!0})){let Y=this.#X[Z];if(this.#U(Y))Y.__abortController.abort(Error("deleted"));else{let K=this.#z[Z];this.#R&&this.#K?.(Y,K,J),this.#V&&this.#k?.push([Y,K,J])}}if(this.#q.clear(),this.#X.fill(void 0),this.#z.fill(void 0),this.#G&&this.#I){this.#G.fill(0),this.#I.fill(0);for(let Z of this.#B??[])Z!==void 0&&clearTimeout(Z);this.#B?.fill(void 0)}if(this.#A&&this.#A.fill(0),this.#O=0,this.#j=0,this.#v.length=0,this.#$=0,this.#H=0,this.#V&&this.#k){let Z=this.#k,Y;for(;Y=Z?.shift();)this.#Y?.(...Y)}}},v2=typeof process=="object"&&process?process:{stdout:null,stderr:null},q7=(Q)=>!!Q&&typeof Q=="object"&&(Q instanceof S0||Q instanceof J5||U7(Q)||F7(Q)),U7=(Q)=>!!Q&&typeof Q=="object"&&Q instanceof Z2&&typeof Q.pipe=="function"&&Q.pipe!==J5.Writable.prototype.pipe,F7=(Q)=>!!Q&&typeof Q=="object"&&Q instanceof Z2&&typeof Q.write=="function"&&typeof Q.end=="function",o=Symbol("EOF"),p=Symbol("maybeEmitEnd"),n=Symbol("emittedEnd"),A0=Symbol("emittingEnd"),H0=Symbol("emittedError"),I0=Symbol("closed"),D2=Symbol("read"),N0=Symbol("flush"),M2=Symbol("flushChunk"),h=Symbol("encoding"),Z0=Symbol("decoder"),A=Symbol("flowing"),W0=Symbol("paused"),Y0=Symbol("resume"),I=Symbol("buffer"),E=Symbol("pipes"),N=Symbol("bufferLength"),o0=Symbol("bufferPush"),v0=Symbol("bufferShift"),D=Symbol("objectMode"),R=Symbol("destroyed"),p0=Symbol("error"),n0=Symbol("emitData"),E2=Symbol("emitEnd"),r0=Symbol("emitEnd2"),d=Symbol("async"),i0=Symbol("abort"),D0=Symbol("aborted"),z0=Symbol("signal"),s=Symbol("dataListeners"),S=Symbol("discarded"),$0=(Q)=>Promise.resolve().then(Q),G7=(Q)=>Q(),_7=(Q)=>Q==="end"||Q==="finish"||Q==="prefinish",C7=(Q)=>Q instanceof ArrayBuffer||!!Q&&typeof Q=="object"&&Q.constructor&&Q.constructor.name==="ArrayBuffer"&&Q.byteLength>=0,O7=(Q)=>!Buffer.isBuffer(Q)&&ArrayBuffer.isView(Q),Z5=class{src;dest;opts;ondrain;constructor(Q,J,Z){this.src=Q,this.dest=J,this.opts=Z,this.ondrain=()=>Q[Y0](),this.dest.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(Q){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},j7=class extends Z5{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(Q,J,Z){super(Q,J,Z),this.proxyErrors=(Y)=>J.emit("error",Y),Q.on("error",this.proxyErrors)}},k7=(Q)=>!!Q.objectMode,B7=(Q)=>!Q.objectMode&&!!Q.encoding&&Q.encoding!=="buffer",S0=class extends Z2{[A]=!1;[W0]=!1;[E]=[];[I]=[];[D];[h];[d];[Z0];[o]=!1;[n]=!1;[A0]=!1;[I0]=!1;[H0]=null;[N]=0;[R]=!1;[z0];[D0]=!1;[s]=0;[S]=!1;writable=!0;readable=!0;constructor(...Q){let J=Q[0]||{};if(super(),J.objectMode&&typeof J.encoding=="string")throw TypeError("Encoding and objectMode may not be used together");k7(J)?(this[D]=!0,this[h]=null):B7(J)?(this[h]=J.encoding,this[D]=!1):(this[D]=!1,this[h]=null),this[d]=!!J.async,this[Z0]=this[h]?new $7(this[h]):null,J&&J.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[I]}),J&&J.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[E]});let{signal:Z}=J;Z&&(this[z0]=Z,Z.aborted?this[i0]():Z.addEventListener("abort",()=>this[i0]()))}get bufferLength(){return this[N]}get encoding(){return this[h]}set encoding(Q){throw Error("Encoding must be set at instantiation time")}setEncoding(Q){throw Error("Encoding must be set at instantiation time")}get objectMode(){return this[D]}set objectMode(Q){throw Error("objectMode must be set at instantiation time")}get async(){return this[d]}set async(Q){this[d]=this[d]||!!Q}[i0](){this[D0]=!0,this.emit("abort",this[z0]?.reason),this.destroy(this[z0]?.reason)}get aborted(){return this[D0]}set aborted(Q){}write(Q,J,Z){if(this[D0])return!1;if(this[o])throw Error("write after end");if(this[R])return this.emit("error",Object.assign(Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof J=="function"&&(Z=J,J="utf8"),J||(J="utf8");let Y=this[d]?$0:G7;if(!this[D]&&!Buffer.isBuffer(Q)){if(O7(Q))Q=Buffer.from(Q.buffer,Q.byteOffset,Q.byteLength);else if(C7(Q))Q=Buffer.from(Q);else if(typeof Q!="string")throw Error("Non-contiguous data written to non-objectMode stream")}return this[D]?(this[A]&&this[N]!==0&&this[N0](!0),this[A]?this.emit("data",Q):this[o0](Q),this[N]!==0&&this.emit("readable"),Z&&Y(Z),this[A]):Q.length?(typeof Q=="string"&&!(J===this[h]&&!this[Z0]?.lastNeed)&&(Q=Buffer.from(Q,J)),Buffer.isBuffer(Q)&&this[h]&&(Q=this[Z0].write(Q)),this[A]&&this[N]!==0&&this[N0](!0),this[A]?this.emit("data",Q):this[o0](Q),this[N]!==0&&this.emit("readable"),Z&&Y(Z),this[A]):(this[N]!==0&&this.emit("readable"),Z&&Y(Z),this[A])}read(Q){if(this[R])return null;if(this[S]=!1,this[N]===0||Q===0||Q&&Q>this[N])return this[p](),null;this[D]&&(Q=null),this[I].length>1&&!this[D]&&(this[I]=[this[h]?this[I].join(""):Buffer.concat(this[I],this[N])]);let J=this[D2](Q||null,this[I][0]);return this[p](),J}[D2](Q,J){if(this[D])this[v0]();else{let Z=J;Q===Z.length||Q===null?this[v0]():typeof Z=="string"?(this[I][0]=Z.slice(Q),J=Z.slice(0,Q),this[N]-=Q):(this[I][0]=Z.subarray(Q),J=Z.subarray(0,Q),this[N]-=Q)}return this.emit("data",J),!this[I].length&&!this[o]&&this.emit("drain"),J}end(Q,J,Z){return typeof Q=="function"&&(Z=Q,Q=void 0),typeof J=="function"&&(Z=J,J="utf8"),Q!==void 0&&this.write(Q,J),Z&&this.once("end",Z),this[o]=!0,this.writable=!1,(this[A]||!this[W0])&&this[p](),this}[Y0](){this[R]||(!this[s]&&!this[E].length&&(this[S]=!0),this[W0]=!1,this[A]=!0,this.emit("resume"),this[I].length?this[N0]():this[o]?this[p]():this.emit("drain"))}resume(){return this[Y0]()}pause(){this[A]=!1,this[W0]=!0,this[S]=!1}get destroyed(){return this[R]}get flowing(){return this[A]}get paused(){return this[W0]}[o0](Q){this[D]?this[N]+=1:this[N]+=Q.length,this[I].push(Q)}[v0](){return this[D]?this[N]-=1:this[N]-=this[I][0].length,this[I].shift()}[N0](Q=!1){do;while(this[M2](this[v0]())&&this[I].length);!Q&&!this[I].length&&!this[o]&&this.emit("drain")}[M2](Q){return this.emit("data",Q),this[A]}pipe(Q,J){if(this[R])return Q;this[S]=!1;let Z=this[n];return J=J||{},Q===v2.stdout||Q===v2.stderr?J.end=!1:J.end=J.end!==!1,J.proxyErrors=!!J.proxyErrors,Z?J.end&&Q.end():(this[E].push(J.proxyErrors?new j7(this,Q,J):new Z5(this,Q,J)),this[d]?$0(()=>this[Y0]()):this[Y0]()),Q}unpipe(Q){let J=this[E].find((Z)=>Z.dest===Q);J&&(this[E].length===1?(this[A]&&this[s]===0&&(this[A]=!1),this[E]=[]):this[E].splice(this[E].indexOf(J),1),J.unpipe())}addListener(Q,J){return this.on(Q,J)}on(Q,J){let Z=super.on(Q,J);if(Q==="data")this[S]=!1,this[s]++,!this[E].length&&!this[A]&&this[Y0]();else if(Q==="readable"&&this[N]!==0)super.emit("readable");else if(_7(Q)&&this[n])super.emit(Q),this.removeAllListeners(Q);else if(Q==="error"&&this[H0]){let Y=J;this[d]?$0(()=>Y.call(this,this[H0])):Y.call(this,this[H0])}return Z}removeListener(Q,J){return this.off(Q,J)}off(Q,J){let Z=super.off(Q,J);return Q==="data"&&(this[s]=this.listeners("data").length,this[s]===0&&!this[S]&&!this[E].length&&(this[A]=!1)),Z}removeAllListeners(Q){let J=super.removeAllListeners(Q);return(Q==="data"||Q===void 0)&&(this[s]=0,!this[S]&&!this[E].length&&(this[A]=!1)),J}get emittedEnd(){return this[n]}[p](){!this[A0]&&!this[n]&&!this[R]&&this[I].length===0&&this[o]&&(this[A0]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[I0]&&this.emit("close"),this[A0]=!1)}emit(Q,...J){let Z=J[0];if(Q!=="error"&&Q!=="close"&&Q!==R&&this[R])return!1;if(Q==="data")return!this[D]&&!Z?!1:this[d]?($0(()=>this[n0](Z)),!0):this[n0](Z);if(Q==="end")return this[E2]();if(Q==="close"){if(this[I0]=!0,!this[n]&&!this[R])return!1;let K=super.emit("close");return this.removeAllListeners("close"),K}else if(Q==="error"){this[H0]=Z,super.emit(p0,Z);let K=!this[z0]||this.listeners("error").length?super.emit("error",Z):!1;return this[p](),K}else if(Q==="resume"){let K=super.emit("resume");return this[p](),K}else if(Q==="finish"||Q==="prefinish"){let K=super.emit(Q);return this.removeAllListeners(Q),K}let Y=super.emit(Q,...J);return this[p](),Y}[n0](Q){for(let Z of this[E])Z.dest.write(Q)===!1&&this.pause();let J=this[S]?!1:super.emit("data",Q);return this[p](),J}[E2](){return this[n]?!1:(this[n]=!0,this.readable=!1,this[d]?($0(()=>this[r0]()),!0):this[r0]())}[r0](){if(this[Z0]){let J=this[Z0].end();if(J){for(let Z of this[E])Z.dest.write(J);this[S]||super.emit("data",J)}}for(let J of this[E])J.end();let Q=super.emit("end");return this.removeAllListeners("end"),Q}async collect(){let Q=Object.assign([],{dataLength:0});this[D]||(Q.dataLength=0);let J=this.promise();return this.on("data",(Z)=>{Q.push(Z),this[D]||(Q.dataLength+=Z.length)}),await J,Q}async concat(){if(this[D])throw Error("cannot concat in objectMode");let Q=await this.collect();return this[h]?Q.join(""):Buffer.concat(Q,Q.dataLength)}async promise(){return new Promise((Q,J)=>{this.on(R,()=>J(Error("stream destroyed"))),this.on("error",(Z)=>J(Z)),this.on("end",()=>Q())})}[Symbol.asyncIterator](){this[S]=!1;let Q=!1,J=async()=>(this.pause(),Q=!0,{value:void 0,done:!0});return{next:()=>{if(Q)return J();let Z=this.read();if(Z!==null)return Promise.resolve({done:!1,value:Z});if(this[o])return J();let Y,K,V=(z)=>{this.off("data",X),this.off("end",W),this.off(R,H),J(),K(z)},X=(z)=>{this.off("error",V),this.off("end",W),this.off(R,H),this.pause(),Y({value:z,done:!!this[o]})},W=()=>{this.off("error",V),this.off("data",X),this.off(R,H),J(),Y({done:!0,value:void 0})},H=()=>V(Error("stream destroyed"));return new Promise((z,q)=>{K=q,Y=z,this.once(R,H),this.once("error",V),this.once("end",W),this.once("data",X)})},throw:J,return:J,[Symbol.asyncIterator](){return this}}}[Symbol.iterator](){this[S]=!1;let Q=!1,J=()=>(this.pause(),this.off(p0,J),this.off(R,J),this.off("end",J),Q=!0,{done:!0,value:void 0}),Z=()=>{if(Q)return J();let Y=this.read();return Y===null?J():{done:!1,value:Y}};return this.once("end",J),this.once(p0,J),this.once(R,J),{next:Z,throw:J,return:J,[Symbol.iterator](){return this}}}destroy(Q){if(this[R])return Q?this.emit("error",Q):this.emit(R),this;this[R]=!0,this[S]=!0,this[I].length=0,this[N]=0;let J=this;return typeof J.close=="function"&&!this[I0]&&J.close(),Q?this.emit("error",Q):this.emit(R),this}static get isStream(){return q7}},L7=K7.native,F0={lstatSync:Q7,readdir:J7,readdirSync:Z7,readlinkSync:Y7,realpathSync:L7,promises:{lstat:X7,readdir:H7,readlink:W7,realpath:z7}},Y5=(Q)=>!Q||Q===F0||Q===V7?F0:{...F0,...Q,promises:{...F0.promises,...Q.promises||{}}},K5=/^\\\\\?\\([a-z]:)\\?$/i,R7=(Q)=>Q.replace(/\//g,"\\").replace(K5,"$1\\"),A7=/[\\\/]/,b=0,V5=1,X5=2,c=4,H5=6,W5=8,e=10,z5=12,x=15,q0=~x,a0=16,P2=32,G0=64,f=128,M0=256,T0=512,T2=G0|f|T0,I7=1023,s0=(Q)=>Q.isFile()?W5:Q.isDirectory()?c:Q.isSymbolicLink()?e:Q.isCharacterDevice()?X5:Q.isBlockDevice()?H5:Q.isSocket()?z5:Q.isFIFO()?V5:b,w2=new x0({max:4096}),_0=(Q)=>{let J=w2.get(Q);if(J)return J;let Z=Q.normalize("NFKD");return w2.set(Q,Z),Z},y2=new x0({max:4096}),E0=(Q)=>{let J=y2.get(Q);if(J)return J;let Z=_0(Q.toLowerCase());return y2.set(Q,Z),Z},S2=class extends x0{constructor(){super({max:256})}},N7=class extends x0{constructor(Q=16384){super({maxSize:Q,sizeCalculation:(J)=>J.length+1})}},$5=Symbol("PathScurry setAsCwd"),w=class{name;root;roots;parent;nocase;isCWD=!1;#Q;#Z;get dev(){return this.#Z}#K;get mode(){return this.#K}#J;get nlink(){return this.#J}#Y;get uid(){return this.#Y}#_;get gid(){return this.#_}#F;get rdev(){return this.#F}#W;get blksize(){return this.#W}#H;get ino(){return this.#H}#$;get size(){return this.#$}#q;get blocks(){return this.#q}#z;get atimeMs(){return this.#z}#X;get mtimeMs(){return this.#X}#C;get ctimeMs(){return this.#C}#L;get birthtimeMs(){return this.#L}#O;get atime(){return this.#O}#j;get mtime(){return this.#j}#v;get ctime(){return this.#v}#k;get birthtime(){return this.#k}#A;#I;#G;#B;#R;#D;#V;#S;#w;#M;get parentPath(){return(this.parent||this).fullpath()}get path(){return this.parentPath}constructor(Q,J=b,Z,Y,K,V,X){this.name=Q,this.#A=K?E0(Q):_0(Q),this.#V=J&I7,this.nocase=K,this.roots=Y,this.root=Z||this,this.#S=V,this.#G=X.fullpath,this.#R=X.relative,this.#D=X.relativePosix,this.parent=X.parent,this.parent?this.#Q=this.parent.#Q:this.#Q=Y5(X.fs)}depth(){return this.#I!==void 0?this.#I:this.parent?this.#I=this.parent.depth()+1:this.#I=0}childrenCache(){return this.#S}resolve(Q){if(!Q)return this;let J=this.getRootString(Q),Z=Q.substring(J.length).split(this.splitSep);return J?this.getRoot(J).#y(Z):this.#y(Z)}#y(Q){let J=this;for(let Z of Q)J=J.child(Z);return J}children(){let Q=this.#S.get(this);if(Q)return Q;let J=Object.assign([],{provisional:0});return this.#S.set(this,J),this.#V&=~a0,J}child(Q,J){if(Q===""||Q===".")return this;if(Q==="..")return this.parent||this;let Z=this.children(),Y=this.nocase?E0(Q):_0(Q);for(let W of Z)if(W.#A===Y)return W;let K=this.parent?this.sep:"",V=this.#G?this.#G+K+Q:void 0,X=this.newChild(Q,b,{...J,parent:this,fullpath:V});return this.canReaddir()||(X.#V|=f),Z.push(X),X}relative(){if(this.isCWD)return"";if(this.#R!==void 0)return this.#R;let Q=this.name,J=this.parent;if(!J)return this.#R=this.name;let Z=J.relative();return Z+(!Z||!J.parent?"":this.sep)+Q}relativePosix(){if(this.sep==="/")return this.relative();if(this.isCWD)return"";if(this.#D!==void 0)return this.#D;let Q=this.name,J=this.parent;if(!J)return this.#D=this.fullpathPosix();let Z=J.relativePosix();return Z+(!Z||!J.parent?"":"/")+Q}fullpath(){if(this.#G!==void 0)return this.#G;let Q=this.name,J=this.parent;if(!J)return this.#G=this.name;let Z=J.fullpath()+(J.parent?this.sep:"")+Q;return this.#G=Z}fullpathPosix(){if(this.#B!==void 0)return this.#B;if(this.sep==="/")return this.#B=this.fullpath();if(!this.parent){let Y=this.fullpath().replace(/\\/g,"/");return/^[a-z]:\//i.test(Y)?this.#B=`//?/${Y}`:this.#B=Y}let Q=this.parent,J=Q.fullpathPosix(),Z=J+(!J||!Q.parent?"":"/")+this.name;return this.#B=Z}isUnknown(){return(this.#V&x)===b}isType(Q){return this[`is${Q}`]()}getType(){return this.isUnknown()?"Unknown":this.isDirectory()?"Directory":this.isFile()?"File":this.isSymbolicLink()?"SymbolicLink":this.isFIFO()?"FIFO":this.isCharacterDevice()?"CharacterDevice":this.isBlockDevice()?"BlockDevice":this.isSocket()?"Socket":"Unknown"}isFile(){return(this.#V&x)===W5}isDirectory(){return(this.#V&x)===c}isCharacterDevice(){return(this.#V&x)===X5}isBlockDevice(){return(this.#V&x)===H5}isFIFO(){return(this.#V&x)===V5}isSocket(){return(this.#V&x)===z5}isSymbolicLink(){return(this.#V&e)===e}lstatCached(){return this.#V&P2?this:void 0}readlinkCached(){return this.#w}realpathCached(){return this.#M}readdirCached(){let Q=this.children();return Q.slice(0,Q.provisional)}canReadlink(){if(this.#w)return!0;if(!this.parent)return!1;let Q=this.#V&x;return!(Q!==b&&Q!==e||this.#V&M0||this.#V&f)}calledReaddir(){return!!(this.#V&a0)}isENOENT(){return!!(this.#V&f)}isNamed(Q){return this.nocase?this.#A===E0(Q):this.#A===_0(Q)}async readlink(){let Q=this.#w;if(Q)return Q;if(this.canReadlink()&&this.parent)try{let J=await this.#Q.promises.readlink(this.fullpath()),Z=(await this.parent.realpath())?.resolve(J);if(Z)return this.#w=Z}catch(J){this.#T(J.code);return}}readlinkSync(){let Q=this.#w;if(Q)return Q;if(this.canReadlink()&&this.parent)try{let J=this.#Q.readlinkSync(this.fullpath()),Z=this.parent.realpathSync()?.resolve(J);if(Z)return this.#w=Z}catch(J){this.#T(J.code);return}}#m(Q){this.#V|=a0;for(let J=Q.provisional;J<Q.length;J++){let Z=Q[J];Z&&Z.#N()}}#N(){this.#V&f||(this.#V=(this.#V|f)&q0,this.#l())}#l(){let Q=this.children();Q.provisional=0;for(let J of Q)J.#N()}#b(){this.#V|=T0,this.#u()}#u(){if(this.#V&G0)return;let Q=this.#V;(Q&x)===c&&(Q&=q0),this.#V=Q|G0,this.#l()}#g(Q=""){Q==="ENOTDIR"||Q==="EPERM"?this.#u():Q==="ENOENT"?this.#N():this.children().provisional=0}#P(Q=""){Q==="ENOTDIR"?this.parent.#u():Q==="ENOENT"&&this.#N()}#T(Q=""){let J=this.#V;J|=M0,Q==="ENOENT"&&(J|=f),(Q==="EINVAL"||Q==="UNKNOWN")&&(J&=q0),this.#V=J,Q==="ENOTDIR"&&this.parent&&this.parent.#u()}#h(Q,J){return this.#d(Q,J)||this.#f(Q,J)}#f(Q,J){let Z=s0(Q),Y=this.newChild(Q.name,Z,{parent:this}),K=Y.#V&x;return K!==c&&K!==e&&K!==b&&(Y.#V|=G0),J.unshift(Y),J.provisional++,Y}#d(Q,J){for(let Z=J.provisional;Z<J.length;Z++){let Y=J[Z];if((this.nocase?E0(Q.name):_0(Q.name))===Y.#A)return this.#U(Q,Y,Z,J)}}#U(Q,J,Z,Y){let K=J.name;return J.#V=J.#V&q0|s0(Q),K!==Q.name&&(J.name=Q.name),Z!==Y.provisional&&(Z===Y.length-1?Y.pop():Y.splice(Z,1),Y.unshift(J)),Y.provisional++,J}async lstat(){if((this.#V&f)===0)try{return this.#c(await this.#Q.promises.lstat(this.fullpath())),this}catch(Q){this.#P(Q.code)}}lstatSync(){if((this.#V&f)===0)try{return this.#c(this.#Q.lstatSync(this.fullpath())),this}catch(Q){this.#P(Q.code)}}#c(Q){let{atime:J,atimeMs:Z,birthtime:Y,birthtimeMs:K,blksize:V,blocks:X,ctime:W,ctimeMs:H,dev:z,gid:q,ino:$,mode:F,mtime:U,mtimeMs:G,nlink:_,rdev:O,size:C,uid:j}=Q;this.#O=J,this.#z=Z,this.#k=Y,this.#L=K,this.#W=V,this.#q=X,this.#v=W,this.#C=H,this.#Z=z,this.#_=q,this.#H=$,this.#K=F,this.#j=U,this.#X=G,this.#J=_,this.#F=O,this.#$=C,this.#Y=j;let k=s0(Q);this.#V=this.#V&q0|k|P2,k!==b&&k!==c&&k!==e&&(this.#V|=G0)}#x=[];#E=!1;#o(Q){this.#E=!1;let J=this.#x.slice();this.#x.length=0,J.forEach((Z)=>Z(null,Q))}readdirCB(Q,J=!1){if(!this.canReaddir()){J?Q(null,[]):queueMicrotask(()=>Q(null,[]));return}let Z=this.children();if(this.calledReaddir()){let K=Z.slice(0,Z.provisional);J?Q(null,K):queueMicrotask(()=>Q(null,K));return}if(this.#x.push(Q),this.#E)return;this.#E=!0;let Y=this.fullpath();this.#Q.readdir(Y,{withFileTypes:!0},(K,V)=>{if(K)this.#g(K.code),Z.provisional=0;else{for(let X of V)this.#h(X,Z);this.#m(Z)}this.#o(Z.slice(0,Z.provisional))})}#p;async readdir(){if(!this.canReaddir())return[];let Q=this.children();if(this.calledReaddir())return Q.slice(0,Q.provisional);let J=this.fullpath();if(this.#p)await this.#p;else{let Z=()=>{};this.#p=new Promise((Y)=>Z=Y);try{for(let Y of await this.#Q.promises.readdir(J,{withFileTypes:!0}))this.#h(Y,Q);this.#m(Q)}catch(Y){this.#g(Y.code),Q.provisional=0}this.#p=void 0,Z()}return Q.slice(0,Q.provisional)}readdirSync(){if(!this.canReaddir())return[];let Q=this.children();if(this.calledReaddir())return Q.slice(0,Q.provisional);let J=this.fullpath();try{for(let Z of this.#Q.readdirSync(J,{withFileTypes:!0}))this.#h(Z,Q);this.#m(Q)}catch(Z){this.#g(Z.code),Q.provisional=0}return Q.slice(0,Q.provisional)}canReaddir(){if(this.#V&T2)return!1;let Q=x&this.#V;return Q===b||Q===c||Q===e}shouldWalk(Q,J){return(this.#V&c)===c&&!(this.#V&T2)&&!Q.has(this)&&(!J||J(this))}async realpath(){if(this.#M)return this.#M;if(!((T0|M0|f)&this.#V))try{let Q=await this.#Q.promises.realpath(this.fullpath());return this.#M=this.resolve(Q)}catch{this.#b()}}realpathSync(){if(this.#M)return this.#M;if(!((T0|M0|f)&this.#V))try{let Q=this.#Q.realpathSync(this.fullpath());return this.#M=this.resolve(Q)}catch{this.#b()}}[$5](Q){if(Q===this)return;Q.isCWD=!1,this.isCWD=!0;let J=new Set([]),Z=[],Y=this;for(;Y&&Y.parent;)J.add(Y),Y.#R=Z.join(this.sep),Y.#D=Z.join("/"),Y=Y.parent,Z.push("..");for(Y=Q;Y&&Y.parent&&!J.has(Y);)Y.#R=void 0,Y.#D=void 0,Y=Y.parent}},q5=class Q extends w{sep="\\";splitSep=A7;constructor(J,Z=b,Y,K,V,X,W){super(J,Z,Y,K,V,X,W)}newChild(J,Z=b,Y={}){return new Q(J,Z,this.root,this.roots,this.nocase,this.childrenCache(),Y)}getRootString(J){return t0.parse(J).root}getRoot(J){if(J=R7(J.toUpperCase()),J===this.root.name)return this.root;for(let[Z,Y]of Object.entries(this.roots))if(this.sameRoot(J,Z))return this.roots[J]=Y;return this.roots[J]=new Y2(J,this).root}sameRoot(J,Z=this.root.name){return J=J.toUpperCase().replace(/\//g,"\\").replace(K5,"$1\\"),J===Z}},U5=class Q extends w{splitSep="/";sep="/";constructor(J,Z=b,Y,K,V,X,W){super(J,Z,Y,K,V,X,W)}getRootString(J){return J.startsWith("/")?"/":""}getRoot(J){return this.root}newChild(J,Z=b,Y={}){return new Q(J,Z,this.root,this.roots,this.nocase,this.childrenCache(),Y)}},F5=class{root;rootPath;roots;cwd;#Q;#Z;#K;nocase;#J;constructor(Q=process.cwd(),J,Z,{nocase:Y,childrenCacheSize:K=16384,fs:V=F0}={}){this.#J=Y5(V),(Q instanceof URL||Q.startsWith("file://"))&&(Q=t6(Q));let X=J.resolve(Q);this.roots=Object.create(null),this.rootPath=this.parseRootPath(X),this.#Q=new S2,this.#Z=new S2,this.#K=new N7(K);let W=X.substring(this.rootPath.length).split(Z);if(W.length===1&&!W[0]&&W.pop(),Y===void 0)throw TypeError("must provide nocase setting to PathScurryBase ctor");this.nocase=Y,this.root=this.newRoot(this.#J),this.roots[this.rootPath]=this.root;let H=this.root,z=W.length-1,q=J.sep,$=this.rootPath,F=!1;for(let U of W){let G=z--;H=H.child(U,{relative:Array(G).fill("..").join(q),relativePosix:Array(G).fill("..").join("/"),fullpath:$+=(F?"":q)+U}),F=!0}this.cwd=H}depth(Q=this.cwd){return typeof Q=="string"&&(Q=this.cwd.resolve(Q)),Q.depth()}childrenCache(){return this.#K}resolve(...Q){let J="";for(let K=Q.length-1;K>=0;K--){let V=Q[K];if(!(!V||V===".")&&(J=J?`${V}/${J}`:V,this.isAbsolute(V)))break}let Z=this.#Q.get(J);if(Z!==void 0)return Z;let Y=this.cwd.resolve(J).fullpath();return this.#Q.set(J,Y),Y}resolvePosix(...Q){let J="";for(let K=Q.length-1;K>=0;K--){let V=Q[K];if(!(!V||V===".")&&(J=J?`${V}/${J}`:V,this.isAbsolute(V)))break}let Z=this.#Z.get(J);if(Z!==void 0)return Z;let Y=this.cwd.resolve(J).fullpathPosix();return this.#Z.set(J,Y),Y}relative(Q=this.cwd){return typeof Q=="string"&&(Q=this.cwd.resolve(Q)),Q.relative()}relativePosix(Q=this.cwd){return typeof Q=="string"&&(Q=this.cwd.resolve(Q)),Q.relativePosix()}basename(Q=this.cwd){return typeof Q=="string"&&(Q=this.cwd.resolve(Q)),Q.name}dirname(Q=this.cwd){return typeof Q=="string"&&(Q=this.cwd.resolve(Q)),(Q.parent||Q).fullpath()}async readdir(Q=this.cwd,J={withFileTypes:!0}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q,Q=this.cwd);let{withFileTypes:Z}=J;if(Q.canReaddir()){let Y=await Q.readdir();return Z?Y:Y.map((K)=>K.name)}else return[]}readdirSync(Q=this.cwd,J={withFileTypes:!0}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q,Q=this.cwd);let{withFileTypes:Z=!0}=J;return Q.canReaddir()?Z?Q.readdirSync():Q.readdirSync().map((Y)=>Y.name):[]}async lstat(Q=this.cwd){return typeof Q=="string"&&(Q=this.cwd.resolve(Q)),Q.lstat()}lstatSync(Q=this.cwd){return typeof Q=="string"&&(Q=this.cwd.resolve(Q)),Q.lstatSync()}async readlink(Q=this.cwd,{withFileTypes:J}={withFileTypes:!1}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q.withFileTypes,Q=this.cwd);let Z=await Q.readlink();return J?Z:Z?.fullpath()}readlinkSync(Q=this.cwd,{withFileTypes:J}={withFileTypes:!1}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q.withFileTypes,Q=this.cwd);let Z=Q.readlinkSync();return J?Z:Z?.fullpath()}async realpath(Q=this.cwd,{withFileTypes:J}={withFileTypes:!1}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q.withFileTypes,Q=this.cwd);let Z=await Q.realpath();return J?Z:Z?.fullpath()}realpathSync(Q=this.cwd,{withFileTypes:J}={withFileTypes:!1}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q.withFileTypes,Q=this.cwd);let Z=Q.realpathSync();return J?Z:Z?.fullpath()}async walk(Q=this.cwd,J={}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q,Q=this.cwd);let{withFileTypes:Z=!0,follow:Y=!1,filter:K,walkFilter:V}=J,X=[];(!K||K(Q))&&X.push(Z?Q:Q.fullpath());let W=new Set,H=(q,$)=>{W.add(q),q.readdirCB((F,U)=>{if(F)return $(F);let G=U.length;if(!G)return $();let _=()=>{--G===0&&$()};for(let O of U)(!K||K(O))&&X.push(Z?O:O.fullpath()),Y&&O.isSymbolicLink()?O.realpath().then((C)=>C?.isUnknown()?C.lstat():C).then((C)=>C?.shouldWalk(W,V)?H(C,_):_()):O.shouldWalk(W,V)?H(O,_):_()},!0)},z=Q;return new Promise((q,$)=>{H(z,(F)=>{if(F)return $(F);q(X)})})}walkSync(Q=this.cwd,J={}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q,Q=this.cwd);let{withFileTypes:Z=!0,follow:Y=!1,filter:K,walkFilter:V}=J,X=[];(!K||K(Q))&&X.push(Z?Q:Q.fullpath());let W=new Set([Q]);for(let H of W){let z=H.readdirSync();for(let q of z){(!K||K(q))&&X.push(Z?q:q.fullpath());let $=q;if(q.isSymbolicLink()){if(!(Y&&($=q.realpathSync())))continue;$.isUnknown()&&$.lstatSync()}$.shouldWalk(W,V)&&W.add($)}}return X}[Symbol.asyncIterator](){return this.iterate()}iterate(Q=this.cwd,J={}){return typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q,Q=this.cwd),this.stream(Q,J)[Symbol.asyncIterator]()}[Symbol.iterator](){return this.iterateSync()}*iterateSync(Q=this.cwd,J={}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q,Q=this.cwd);let{withFileTypes:Z=!0,follow:Y=!1,filter:K,walkFilter:V}=J;(!K||K(Q))&&(yield Z?Q:Q.fullpath());let X=new Set([Q]);for(let W of X){let H=W.readdirSync();for(let z of H){(!K||K(z))&&(yield Z?z:z.fullpath());let q=z;if(z.isSymbolicLink()){if(!(Y&&(q=z.realpathSync())))continue;q.isUnknown()&&q.lstatSync()}q.shouldWalk(X,V)&&X.add(q)}}}stream(Q=this.cwd,J={}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q,Q=this.cwd);let{withFileTypes:Z=!0,follow:Y=!1,filter:K,walkFilter:V}=J,X=new S0({objectMode:!0});(!K||K(Q))&&X.write(Z?Q:Q.fullpath());let W=new Set,H=[Q],z=0,q=()=>{let $=!1;for(;!$;){let F=H.shift();if(!F){z===0&&X.end();return}z++,W.add(F);let U=(_,O,C=!1)=>{if(_)return X.emit("error",_);if(Y&&!C){let j=[];for(let k of O)k.isSymbolicLink()&&j.push(k.realpath().then((B)=>B?.isUnknown()?B.lstat():B));if(j.length){Promise.all(j).then(()=>U(null,O,!0));return}}for(let j of O)j&&(!K||K(j))&&(X.write(Z?j:j.fullpath())||($=!0));z--;for(let j of O){let k=j.realpathCached()||j;k.shouldWalk(W,V)&&H.push(k)}$&&!X.flowing?X.once("drain",q):G||q()},G=!0;F.readdirCB(U,!0),G=!1}};return q(),X}streamSync(Q=this.cwd,J={}){typeof Q=="string"?Q=this.cwd.resolve(Q):Q instanceof w||(J=Q,Q=this.cwd);let{withFileTypes:Z=!0,follow:Y=!1,filter:K,walkFilter:V}=J,X=new S0({objectMode:!0}),W=new Set;(!K||K(Q))&&X.write(Z?Q:Q.fullpath());let H=[Q],z=0,q=()=>{let $=!1;for(;!$;){let F=H.shift();if(!F){z===0&&X.end();return}z++,W.add(F);let U=F.readdirSync();for(let G of U)(!K||K(G))&&(X.write(Z?G:G.fullpath())||($=!0));z--;for(let G of U){let _=G;if(G.isSymbolicLink()){if(!(Y&&(_=G.realpathSync())))continue;_.isUnknown()&&_.lstatSync()}_.shouldWalk(W,V)&&H.push(_)}}$&&!X.flowing&&X.once("drain",q)};return q(),X}chdir(Q=this.cwd){let J=this.cwd;this.cwd=typeof Q=="string"?this.cwd.resolve(Q):Q,this.cwd[$5](J)}},Y2=class extends F5{sep="\\";constructor(Q=process.cwd(),J={}){let{nocase:Z=!0}=J;super(Q,t0,"\\",{...J,nocase:Z}),this.nocase=Z;for(let Y=this.cwd;Y;Y=Y.parent)Y.nocase=this.nocase}parseRootPath(Q){return t0.parse(Q).root.toUpperCase()}newRoot(Q){return new q5(this.rootPath,c,void 0,this.roots,this.nocase,this.childrenCache(),{fs:Q})}isAbsolute(Q){return Q.startsWith("/")||Q.startsWith("\\")||/^[a-z]:(\/|\\)/i.test(Q)}},K2=class extends F5{sep="/";constructor(Q=process.cwd(),J={}){let{nocase:Z=!1}=J;super(Q,e6,"/",{...J,nocase:Z}),this.nocase=Z}parseRootPath(Q){return"/"}newRoot(Q){return new U5(this.rootPath,c,void 0,this.roots,this.nocase,this.childrenCache(),{fs:Q})}isAbsolute(Q){return Q.startsWith("/")}},G5=class extends K2{constructor(Q=process.cwd(),J={}){let{nocase:Z=!0}=J;super(Q,{...J,nocase:Z})}},v9=process.platform==="win32"?q5:U5,v7=process.platform==="win32"?Y2:process.platform==="darwin"?G5:K2,D7=(Q)=>Q.length>=1,M7=(Q)=>Q.length>=1,E7=Symbol.for("nodejs.util.inspect.custom"),_5=class Q{#Q;#Z;#K;length;#J;#Y;#_;#F;#W;#H;#$=!0;constructor(J,Z,Y,K){if(!D7(J))throw TypeError("empty pattern list");if(!M7(Z))throw TypeError("empty glob list");if(Z.length!==J.length)throw TypeError("mismatched pattern list and glob list lengths");if(this.length=J.length,Y<0||Y>=this.length)throw TypeError("index out of range");if(this.#Q=J,this.#Z=Z,this.#K=Y,this.#J=K,this.#K===0){if(this.isUNC()){let[V,X,W,H,...z]=this.#Q,[q,$,F,U,...G]=this.#Z;z[0]===""&&(z.shift(),G.shift());let _=[V,X,W,H,""].join("/"),O=[q,$,F,U,""].join("/");this.#Q=[_,...z],this.#Z=[O,...G],this.length=this.#Q.length}else if(this.isDrive()||this.isAbsolute()){let[V,...X]=this.#Q,[W,...H]=this.#Z;X[0]===""&&(X.shift(),H.shift());let z=V+"/",q=W+"/";this.#Q=[z,...X],this.#Z=[q,...H],this.length=this.#Q.length}}}[E7](){return"Pattern <"+this.#Z.slice(this.#K).join("/")+">"}pattern(){return this.#Q[this.#K]}isString(){return typeof this.#Q[this.#K]=="string"}isGlobstar(){return this.#Q[this.#K]===P}isRegExp(){return this.#Q[this.#K]instanceof RegExp}globString(){return this.#_=this.#_||(this.#K===0?this.isAbsolute()?this.#Z[0]+this.#Z.slice(1).join("/"):this.#Z.join("/"):this.#Z.slice(this.#K).join("/"))}hasMore(){return this.length>this.#K+1}rest(){return this.#Y!==void 0?this.#Y:this.hasMore()?(this.#Y=new Q(this.#Q,this.#Z,this.#K+1,this.#J),this.#Y.#H=this.#H,this.#Y.#W=this.#W,this.#Y.#F=this.#F,this.#Y):this.#Y=null}isUNC(){let J=this.#Q;return this.#W!==void 0?this.#W:this.#W=this.#J==="win32"&&this.#K===0&&J[0]===""&&J[1]===""&&typeof J[2]=="string"&&!!J[2]&&typeof J[3]=="string"&&!!J[3]}isDrive(){let J=this.#Q;return this.#F!==void 0?this.#F:this.#F=this.#J==="win32"&&this.#K===0&&this.length>1&&typeof J[0]=="string"&&/^[a-z]:$/i.test(J[0])}isAbsolute(){let J=this.#Q;return this.#H!==void 0?this.#H:this.#H=J[0]===""&&J.length>1||this.isDrive()||this.isUNC()}root(){let J=this.#Q[0];return typeof J=="string"&&this.isAbsolute()&&this.#K===0?J:""}checkFollowGlobstar(){return!(this.#K===0||!this.isGlobstar()||!this.#$)}markFollowGlobstar(){return this.#K===0||!this.isGlobstar()||!this.#$?!1:(this.#$=!1,!0)}},P7=typeof process=="object"&&process&&typeof process.platform=="string"?process.platform:"linux",u2=class{relative;relativeChildren;absolute;absoluteChildren;platform;mmopts;constructor(Q,{nobrace:J,nocase:Z,noext:Y,noglobstar:K,platform:V=P7}){this.relative=[],this.absolute=[],this.relativeChildren=[],this.absoluteChildren=[],this.platform=V,this.mmopts={dot:!0,nobrace:J,nocase:Z,noext:Y,noglobstar:K,optimizationLevel:2,platform:V,nocomment:!0,nonegate:!0};for(let X of Q)this.add(X)}add(Q){let J=new i(Q,this.mmopts);for(let Z=0;Z<J.set.length;Z++){let Y=J.set[Z],K=J.globParts[Z];if(!Y||!K)throw Error("invalid pattern object");for(;Y[0]==="."&&K[0]===".";)Y.shift(),K.shift();let V=new _5(Y,K,0,this.platform),X=new i(V.globString(),this.mmopts),W=K[K.length-1]==="**",H=V.isAbsolute();H?this.absolute.push(X):this.relative.push(X),W&&(H?this.absoluteChildren.push(X):this.relativeChildren.push(X))}}ignored(Q){let J=Q.fullpath(),Z=`${J}/`,Y=Q.relative()||".",K=`${Y}/`;for(let V of this.relative)if(V.match(Y)||V.match(K))return!0;for(let V of this.absolute)if(V.match(J)||V.match(Z))return!0;return!1}childrenIgnored(Q){let J=Q.fullpath()+"/",Z=(Q.relative()||".")+"/";for(let Y of this.relativeChildren)if(Y.match(Z))return!0;for(let Y of this.absoluteChildren)if(Y.match(J))return!0;return!1}},T7=class Q{store;constructor(J=new Map){this.store=J}copy(){return new Q(new Map(this.store))}hasWalked(J,Z){return this.store.get(J.fullpath())?.has(Z.globString())}storeWalked(J,Z){let Y=J.fullpath(),K=this.store.get(Y);K?K.add(Z.globString()):this.store.set(Y,new Set([Z.globString()]))}},w7=class{store=new Map;add(Q,J,Z){let Y=(J?2:0)|(Z?1:0),K=this.store.get(Q);this.store.set(Q,K===void 0?Y:Y&K)}entries(){return[...this.store.entries()].map(([Q,J])=>[Q,!!(J&2),!!(J&1)])}},y7=class{store=new Map;add(Q,J){if(!Q.canReaddir())return;let Z=this.store.get(Q);Z?Z.find((Y)=>Y.globString()===J.globString())||Z.push(J):this.store.set(Q,[J])}get(Q){let J=this.store.get(Q);if(!J)throw Error("attempting to walk unknown path");return J}entries(){return this.keys().map((Q)=>[Q,this.store.get(Q)])}keys(){return[...this.store.keys()].filter((Q)=>Q.canReaddir())}},x2=class Q{hasWalkedCache;matches=new w7;subwalks=new y7;patterns;follow;dot;opts;constructor(J,Z){this.opts=J,this.follow=!!J.follow,this.dot=!!J.dot,this.hasWalkedCache=Z?Z.copy():new T7}processPatterns(J,Z){this.patterns=Z;let Y=Z.map((K)=>[J,K]);for(let[K,V]of Y){this.hasWalkedCache.storeWalked(K,V);let X=V.root(),W=V.isAbsolute()&&this.opts.absolute!==!1;if(X){K=K.resolve(X==="/"&&this.opts.root!==void 0?this.opts.root:X);let $=V.rest();if($)V=$;else{this.matches.add(K,!0,!1);continue}}if(K.isENOENT())continue;let H,z,q=!1;for(;typeof(H=V.pattern())=="string"&&(z=V.rest());)K=K.resolve(H),V=z,q=!0;if(H=V.pattern(),z=V.rest(),q){if(this.hasWalkedCache.hasWalked(K,V))continue;this.hasWalkedCache.storeWalked(K,V)}if(typeof H=="string"){let $=H===".."||H===""||H===".";this.matches.add(K.resolve(H),W,$);continue}else if(H===P){(!K.isSymbolicLink()||this.follow||V.checkFollowGlobstar())&&this.subwalks.add(K,V);let $=z?.pattern(),F=z?.rest();if(!z||($===""||$===".")&&!F)this.matches.add(K,W,$===""||$===".");else if($===".."){let U=K.parent||K;F?this.hasWalkedCache.hasWalked(U,F)||this.subwalks.add(U,F):this.matches.add(U,W,!0)}}else H instanceof RegExp&&this.subwalks.add(K,V)}return this}subwalkTargets(){return this.subwalks.keys()}child(){return new Q(this.opts,this.hasWalkedCache)}filterEntries(J,Z){let Y=this.subwalks.get(J),K=this.child();for(let V of Z)for(let X of Y){let W=X.isAbsolute(),H=X.pattern(),z=X.rest();H===P?K.testGlobstar(V,X,z,W):H instanceof RegExp?K.testRegExp(V,H,z,W):K.testString(V,H,z,W)}return K}testGlobstar(J,Z,Y,K){if((this.dot||!J.name.startsWith("."))&&(Z.hasMore()||this.matches.add(J,K,!1),J.canReaddir()&&(this.follow||!J.isSymbolicLink()?this.subwalks.add(J,Z):J.isSymbolicLink()&&(Y&&Z.checkFollowGlobstar()?this.subwalks.add(J,Y):Z.markFollowGlobstar()&&this.subwalks.add(J,Z)))),Y){let V=Y.pattern();if(typeof V=="string"&&V!==".."&&V!==""&&V!==".")this.testString(J,V,Y.rest(),K);else if(V===".."){let X=J.parent||J;this.subwalks.add(X,Y)}else V instanceof RegExp&&this.testRegExp(J,V,Y.rest(),K)}}testRegExp(J,Z,Y,K){Z.test(J.name)&&(Y?this.subwalks.add(J,Y):this.matches.add(J,K,!1))}testString(J,Z,Y,K){J.isNamed(Z)&&(Y?this.subwalks.add(J,Y):this.matches.add(J,K,!1))}},S7=(Q,J)=>typeof Q=="string"?new u2([Q],J):Array.isArray(Q)?new u2(Q,J):Q,C5=class{path;patterns;opts;seen=new Set;paused=!1;aborted=!1;#Q=[];#Z;#K;signal;maxDepth;includeChildMatches;constructor(Q,J,Z){if(this.patterns=Q,this.path=J,this.opts=Z,this.#K=!Z.posix&&Z.platform==="win32"?"\\":"/",this.includeChildMatches=Z.includeChildMatches!==!1,(Z.ignore||!this.includeChildMatches)&&(this.#Z=S7(Z.ignore??[],Z),!this.includeChildMatches&&typeof this.#Z.add!="function"))throw Error("cannot ignore child matches, ignore lacks add() method.");this.maxDepth=Z.maxDepth||1/0,Z.signal&&(this.signal=Z.signal,this.signal.addEventListener("abort",()=>{this.#Q.length=0}))}#J(Q){return this.seen.has(Q)||!!this.#Z?.ignored?.(Q)}#Y(Q){return!!this.#Z?.childrenIgnored?.(Q)}pause(){this.paused=!0}resume(){if(this.signal?.aborted)return;this.paused=!1;let Q;for(;!this.paused&&(Q=this.#Q.shift());)Q()}onResume(Q){this.signal?.aborted||(this.paused?this.#Q.push(Q):Q())}async matchCheck(Q,J){if(J&&this.opts.nodir)return;let Z;if(this.opts.realpath){if(Z=Q.realpathCached()||await Q.realpath(),!Z)return;Q=Z}let Y=Q.isUnknown()||this.opts.stat?await Q.lstat():Q;if(this.opts.follow&&this.opts.nodir&&Y?.isSymbolicLink()){let K=await Y.realpath();K&&(K.isUnknown()||this.opts.stat)&&await K.lstat()}return this.matchCheckTest(Y,J)}matchCheckTest(Q,J){return Q&&(this.maxDepth===1/0||Q.depth()<=this.maxDepth)&&(!J||Q.canReaddir())&&(!this.opts.nodir||!Q.isDirectory())&&(!this.opts.nodir||!this.opts.follow||!Q.isSymbolicLink()||!Q.realpathCached()?.isDirectory())&&!this.#J(Q)?Q:void 0}matchCheckSync(Q,J){if(J&&this.opts.nodir)return;let Z;if(this.opts.realpath){if(Z=Q.realpathCached()||Q.realpathSync(),!Z)return;Q=Z}let Y=Q.isUnknown()||this.opts.stat?Q.lstatSync():Q;if(this.opts.follow&&this.opts.nodir&&Y?.isSymbolicLink()){let K=Y.realpathSync();K&&(K?.isUnknown()||this.opts.stat)&&K.lstatSync()}return this.matchCheckTest(Y,J)}matchFinish(Q,J){if(this.#J(Q))return;if(!this.includeChildMatches&&this.#Z?.add){let K=`${Q.relativePosix()}/**`;this.#Z.add(K)}let Z=this.opts.absolute===void 0?J:this.opts.absolute;this.seen.add(Q);let Y=this.opts.mark&&Q.isDirectory()?this.#K:"";if(this.opts.withFileTypes)this.matchEmit(Q);else if(Z){let K=this.opts.posix?Q.fullpathPosix():Q.fullpath();this.matchEmit(K+Y)}else{let K=this.opts.posix?Q.relativePosix():Q.relative(),V=this.opts.dotRelative&&!K.startsWith(".."+this.#K)?"."+this.#K:"";this.matchEmit(K?V+K+Y:"."+Y)}}async match(Q,J,Z){let Y=await this.matchCheck(Q,Z);Y&&this.matchFinish(Y,J)}matchSync(Q,J,Z){let Y=this.matchCheckSync(Q,Z);Y&&this.matchFinish(Y,J)}walkCB(Q,J,Z){this.signal?.aborted&&Z(),this.walkCB2(Q,J,new x2(this.opts),Z)}walkCB2(Q,J,Z,Y){if(this.#Y(Q))return Y();if(this.signal?.aborted&&Y(),this.paused){this.onResume(()=>this.walkCB2(Q,J,Z,Y));return}Z.processPatterns(Q,J);let K=1,V=()=>{--K===0&&Y()};for(let[X,W,H]of Z.matches.entries())this.#J(X)||(K++,this.match(X,W,H).then(()=>V()));for(let X of Z.subwalkTargets()){if(this.maxDepth!==1/0&&X.depth()>=this.maxDepth)continue;K++;let W=X.readdirCached();X.calledReaddir()?this.walkCB3(X,W,Z,V):X.readdirCB((H,z)=>this.walkCB3(X,z,Z,V),!0)}V()}walkCB3(Q,J,Z,Y){Z=Z.filterEntries(Q,J);let K=1,V=()=>{--K===0&&Y()};for(let[X,W,H]of Z.matches.entries())this.#J(X)||(K++,this.match(X,W,H).then(()=>V()));for(let[X,W]of Z.subwalks.entries())K++,this.walkCB2(X,W,Z.child(),V);V()}walkCBSync(Q,J,Z){this.signal?.aborted&&Z(),this.walkCB2Sync(Q,J,new x2(this.opts),Z)}walkCB2Sync(Q,J,Z,Y){if(this.#Y(Q))return Y();if(this.signal?.aborted&&Y(),this.paused){this.onResume(()=>this.walkCB2Sync(Q,J,Z,Y));return}Z.processPatterns(Q,J);let K=1,V=()=>{--K===0&&Y()};for(let[X,W,H]of Z.matches.entries())this.#J(X)||this.matchSync(X,W,H);for(let X of Z.subwalkTargets()){if(this.maxDepth!==1/0&&X.depth()>=this.maxDepth)continue;K++;let W=X.readdirSync();this.walkCB3Sync(X,W,Z,V)}V()}walkCB3Sync(Q,J,Z,Y){Z=Z.filterEntries(Q,J);let K=1,V=()=>{--K===0&&Y()};for(let[X,W,H]of Z.matches.entries())this.#J(X)||this.matchSync(X,W,H);for(let[X,W]of Z.subwalks.entries())K++,this.walkCB2Sync(X,W,Z.child(),V);V()}},b2=class extends C5{matches=new Set;constructor(Q,J,Z){super(Q,J,Z)}matchEmit(Q){this.matches.add(Q)}async walk(){if(this.signal?.aborted)throw this.signal.reason;return this.path.isUnknown()&&await this.path.lstat(),await new Promise((Q,J)=>{this.walkCB(this.path,this.patterns,()=>{this.signal?.aborted?J(this.signal.reason):Q(this.matches)})}),this.matches}walkSync(){if(this.signal?.aborted)throw this.signal.reason;return this.path.isUnknown()&&this.path.lstatSync(),this.walkCBSync(this.path,this.patterns,()=>{if(this.signal?.aborted)throw this.signal.reason}),this.matches}},m2=class extends C5{results;constructor(Q,J,Z){super(Q,J,Z),this.results=new S0({signal:this.signal,objectMode:!0}),this.results.on("drain",()=>this.resume()),this.results.on("resume",()=>this.resume())}matchEmit(Q){this.results.write(Q),this.results.flowing||this.pause()}stream(){let Q=this.path;return Q.isUnknown()?Q.lstat().then(()=>{this.walkCB(Q,this.patterns,()=>this.results.end())}):this.walkCB(Q,this.patterns,()=>this.results.end()),this.results}streamSync(){return this.path.isUnknown()&&this.path.lstatSync(),this.walkCBSync(this.path,this.patterns,()=>this.results.end()),this.results}},u7=typeof process=="object"&&process&&typeof process.platform=="string"?process.platform:"linux",t=class{absolute;cwd;root;dot;dotRelative;follow;ignore;magicalBraces;mark;matchBase;maxDepth;nobrace;nocase;nodir;noext;noglobstar;pattern;platform;realpath;scurry;stat;signal;windowsPathsNoEscape;withFileTypes;includeChildMatches;opts;patterns;constructor(Q,J){if(!J)throw TypeError("glob options required");if(this.withFileTypes=!!J.withFileTypes,this.signal=J.signal,this.follow=!!J.follow,this.dot=!!J.dot,this.dotRelative=!!J.dotRelative,this.nodir=!!J.nodir,this.mark=!!J.mark,J.cwd?(J.cwd instanceof URL||J.cwd.startsWith("file://"))&&(J.cwd=r6(J.cwd)):this.cwd="",this.cwd=J.cwd||"",this.root=J.root,this.magicalBraces=!!J.magicalBraces,this.nobrace=!!J.nobrace,this.noext=!!J.noext,this.realpath=!!J.realpath,this.absolute=J.absolute,this.includeChildMatches=J.includeChildMatches!==!1,this.noglobstar=!!J.noglobstar,this.matchBase=!!J.matchBase,this.maxDepth=typeof J.maxDepth=="number"?J.maxDepth:1/0,this.stat=!!J.stat,this.ignore=J.ignore,this.withFileTypes&&this.absolute!==void 0)throw Error("cannot set absolute and withFileTypes:true");if(typeof Q=="string"&&(Q=[Q]),this.windowsPathsNoEscape=!!J.windowsPathsNoEscape||J.allowWindowsEscape===!1,this.windowsPathsNoEscape&&(Q=Q.map((W)=>W.replace(/\\/g,"/"))),this.matchBase){if(J.noglobstar)throw TypeError("base matching requires globstar");Q=Q.map((W)=>W.includes("/")?W:`./**/${W}`)}if(this.pattern=Q,this.platform=J.platform||u7,this.opts={...J,platform:this.platform},J.scurry){if(this.scurry=J.scurry,J.nocase!==void 0&&J.nocase!==J.scurry.nocase)throw Error("nocase option contradicts provided scurry option")}else{let W=J.platform==="win32"?Y2:J.platform==="darwin"?G5:J.platform?K2:v7;this.scurry=new W(this.cwd,{nocase:J.nocase,fs:J.fs})}this.nocase=this.scurry.nocase;let Z=this.platform==="darwin"||this.platform==="win32",Y={braceExpandMax:1e4,...J,dot:this.dot,matchBase:this.matchBase,nobrace:this.nobrace,nocase:this.nocase,nocaseMagicOnly:Z,nocomment:!0,noext:this.noext,nonegate:!0,optimizationLevel:2,platform:this.platform,windowsPathsNoEscape:this.windowsPathsNoEscape,debug:!!this.opts.debug},K=this.pattern.map((W)=>new i(W,Y)),[V,X]=K.reduce((W,H)=>(W[0].push(...H.set),W[1].push(...H.globParts),W),[[],[]]);this.patterns=V.map((W,H)=>{let z=X[H];if(!z)throw Error("invalid pattern object");return new _5(W,z,0,this.platform)})}async walk(){return[...await new b2(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).walk()]}walkSync(){return[...new b2(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).walkSync()]}stream(){return new m2(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).stream()}streamSync(){return new m2(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).streamSync()}iterateSync(){return this.streamSync()[Symbol.iterator]()}[Symbol.iterator](){return this.iterateSync()}iterate(){return this.stream()[Symbol.asyncIterator]()}[Symbol.asyncIterator](){return this.iterate()}},x7=(Q,J={})=>{Array.isArray(Q)||(Q=[Q]);for(let Z of Q)if(new i(Z,J).hasMagic())return!0;return!1};function b0(Q,J={}){return new t(Q,J).streamSync()}function O5(Q,J={}){return new t(Q,J).stream()}function m0(Q,J={}){return new t(Q,J).walkSync()}async function g2(Q,J={}){return new t(Q,J).walk()}function g0(Q,J={}){return new t(Q,J).iterateSync()}function j5(Q,J={}){return new t(Q,J).iterate()}var b7=b0,m7=Object.assign(O5,{sync:b0}),g7=g0,h7=Object.assign(j5,{sync:g0}),f7=Object.assign(m0,{stream:b0,iterate:g0}),u0=Object.assign(g2,{glob:g2,globSync:m0,sync:f7,globStream:O5,stream:m7,globStreamSync:b0,streamSync:b7,globIterate:j5,iterate:h7,globIterateSync:g0,iterateSync:g7,Glob:t,hasMagic:x7,escape:n2,unescape:K0});u0.glob=u0;var V2=(Q,J,Z)=>{let Y=Q instanceof RegExp?k5(Q,Z):Q,K=J instanceof RegExp?k5(J,Z):J,V=Y!==null&&K!=null&&d7(Y,K,Z);return V&&{start:V[0],end:V[1],pre:Z.slice(0,V[0]),body:Z.slice(V[0]+Y.length,V[1]),post:Z.slice(V[1]+K.length)}},k5=(Q,J)=>{let Z=J.match(Q);return Z?Z[0]:null},d7=(Q,J,Z)=>{let Y,K,V,X=void 0,W,H=Z.indexOf(Q),z=Z.indexOf(J,H+1),q=H;if(H>=0&&z>0){if(Q===J)return[H,z];Y=[],V=Z.length;while(q>=0&&!W){if(q===H)Y.push(q),H=Z.indexOf(Q,q+1);else if(Y.length===1){let $=Y.pop();if($!==void 0)W=[$,z]}else{if(K=Y.pop(),K!==void 0&&K<V)V=K,X=z;z=Z.indexOf(J,q+1)}q=H<z&&H>=0?H:z}if(Y.length&&X!==void 0)W=[V,X]}return W};var B5="\x00SLASH"+Math.random()+"\x00",L5="\x00OPEN"+Math.random()+"\x00",H2="\x00CLOSE"+Math.random()+"\x00",R5="\x00COMMA"+Math.random()+"\x00",A5="\x00PERIOD"+Math.random()+"\x00",c7=new RegExp(B5,"g"),l7=new RegExp(L5,"g"),o7=new RegExp(H2,"g"),p7=new RegExp(R5,"g"),n7=new RegExp(A5,"g"),r7=/\\\\/g,i7=/\\{/g,a7=/\\}/g,s7=/\\,/g,e7=/\\\./g,t7=1e5;function X2(Q){return!isNaN(Q)?parseInt(Q,10):Q.charCodeAt(0)}function Q8(Q){return Q.replace(r7,B5).replace(i7,L5).replace(a7,H2).replace(s7,R5).replace(e7,A5)}function J8(Q){return Q.replace(c7,"\\").replace(l7,"{").replace(o7,"}").replace(p7,",").replace(n7,".")}function I5(Q){if(!Q)return[""];let J=[],Z=V2("{","}",Q);if(!Z)return Q.split(",");let{pre:Y,body:K,post:V}=Z,X=Y.split(",");X[X.length-1]+="{"+K+"}";let W=I5(V);if(V.length)X[X.length-1]+=W.shift(),X.push.apply(X,W);return J.push.apply(J,X),J}function N5(Q,J={}){if(!Q)return[];let{max:Z=t7}=J;if(Q.slice(0,2)==="{}")Q="\\{\\}"+Q.slice(2);return C0(Q8(Q),Z,!0).map(J8)}function Z8(Q){return"{"+Q+"}"}function Y8(Q){return/^-?0\d/.test(Q)}function K8(Q,J){return Q<=J}function V8(Q,J){return Q>=J}function C0(Q,J,Z){let Y=[],K=V2("{","}",Q);if(!K)return[Q];let V=K.pre,X=K.post.length?C0(K.post,J,!1):[""];if(/\$$/.test(K.pre))for(let W=0;W<X.length&&W<J;W++){let H=V+"{"+K.body+"}"+X[W];Y.push(H)}else{let W=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(K.body),H=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(K.body),z=W||H,q=K.body.indexOf(",")>=0;if(!z&&!q){if(K.post.match(/,(?!,).*\}/))return Q=K.pre+"{"+K.body+H2+K.post,C0(Q,J,!0);return[Q]}let $;if(z)$=K.body.split(/\.\./);else if($=I5(K.body),$.length===1&&$[0]!==void 0){if($=C0($[0],J,!1).map(Z8),$.length===1)return X.map((U)=>K.pre+$[0]+U)}let F;if(z&&$[0]!==void 0&&$[1]!==void 0){let U=X2($[0]),G=X2($[1]),_=Math.max($[0].length,$[1].length),O=$.length===3&&$[2]!==void 0?Math.max(Math.abs(X2($[2])),1):1,C=K8;if(G<U)O*=-1,C=V8;let k=$.some(Y8);F=[];for(let B=U;C(B,G);B+=O){let L;if(H){if(L=String.fromCharCode(B),L==="\\")L=""}else if(L=String(B),k){let g=_-L.length;if(g>0){let l=Array(g+1).join("0");if(B<0)L="-"+l+L.slice(1);else L=l+L}}F.push(L)}}else{F=[];for(let U=0;U<$.length;U++)F.push.apply(F,C0($[U],J,!1))}for(let U=0;U<F.length;U++)for(let G=0;G<X.length&&Y.length<J;G++){let _=V+F[U]+X[G];if(!Z||z||_)Y.push(_)}}return Y}var O0=(Q)=>{if(typeof Q!=="string")throw TypeError("invalid pattern");if(Q.length>65536)throw TypeError("pattern is too long")};var X8={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}",!0],"[:alpha:]":["\\p{L}\\p{Nl}",!0],"[:ascii:]":["\\x00-\\x7f",!1],"[:blank:]":["\\p{Zs}\\t",!0],"[:cntrl:]":["\\p{Cc}",!0],"[:digit:]":["\\p{Nd}",!0],"[:graph:]":["\\p{Z}\\p{C}",!0,!0],"[:lower:]":["\\p{Ll}",!0],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}",!0],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f",!0],"[:upper:]":["\\p{Lu}",!0],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}",!0],"[:xdigit:]":["A-Fa-f0-9",!1]},j0=(Q)=>Q.replace(/[[\]\\-]/g,"\\$&"),H8=(Q)=>Q.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),v5=(Q)=>Q.join(""),D5=(Q,J)=>{let Z=J;if(Q.charAt(Z)!=="[")throw Error("not in a brace expression");let Y=[],K=[],V=Z+1,X=!1,W=!1,H=!1,z=!1,q=Z,$="";Q:while(V<Q.length){let _=Q.charAt(V);if((_==="!"||_==="^")&&V===Z+1){z=!0,V++;continue}if(_==="]"&&X&&!H){q=V+1;break}if(X=!0,_==="\\"){if(!H){H=!0,V++;continue}}if(_==="["&&!H){for(let[O,[C,j,k]]of Object.entries(X8))if(Q.startsWith(O,V)){if($)return["$.",!1,Q.length-Z,!0];if(V+=O.length,k)K.push(C);else Y.push(C);W=W||j;continue Q}}if(H=!1,$){if(_>$)Y.push(j0($)+"-"+j0(_));else if(_===$)Y.push(j0(_));$="",V++;continue}if(Q.startsWith("-]",V+1)){Y.push(j0(_+"-")),V+=2;continue}if(Q.startsWith("-",V+1)){$=_,V+=2;continue}Y.push(j0(_)),V++}if(q<V)return["",!1,0,!1];if(!Y.length&&!K.length)return["$.",!1,Q.length-Z,!0];if(K.length===0&&Y.length===1&&/^\\?.$/.test(Y[0])&&!z){let _=Y[0].length===2?Y[0].slice(-1):Y[0];return[H8(_),!1,q-Z,!1]}let F="["+(z?"^":"")+v5(Y)+"]",U="["+(z?"":"^")+v5(K)+"]";return[Y.length&&K.length?"("+F+"|"+U+")":Y.length?F:U,W,q-Z,!0]};var a=(Q,{windowsPathsNoEscape:J=!1,magicalBraces:Z=!0}={})=>{if(Z)return J?Q.replace(/\[([^/\\])\]/g,"$1"):Q.replace(/((?!\\).|^)\[([^/\\])\]/g,"$1$2").replace(/\\([^/])/g,"$1");return J?Q.replace(/\[([^/\\{}])\]/g,"$1"):Q.replace(/((?!\\).|^)\[([^/\\{}])\]/g,"$1$2").replace(/\\([^/{}])/g,"$1")};var y,W8=new Set(["!","?","+","*","@"]),W2=(Q)=>W8.has(Q),M5=(Q)=>W2(Q.type),z8=new Map([["!",["@"]],["?",["?","@"]],["@",["@"]],["*",["*","+","?","@"]],["+",["+","@"]]]),$8=new Map([["!",["?"]],["@",["?"]],["+",["?","*"]]]),q8=new Map([["!",["?","@"]],["?",["?","@"]],["@",["?","@"]],["*",["*","+","?","@"]],["+",["+","@","?","*"]]]),E5=new Map([["!",new Map([["!","@"]])],["?",new Map([["*","*"],["+","*"]])],["@",new Map([["!","!"],["?","?"],["@","@"],["*","*"],["+","+"]])],["+",new Map([["?","*"],["*","*"]])]]),U8="(?!(?:^|/)\\.\\.?(?:$|/))",h0="(?!\\.)",F8=new Set(["[","."]),G8=new Set(["..","."]),_8=new Set("().*{}+?[]^$\\!"),C8=(Q)=>Q.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),z2="[^/]",P5=z2+"*?",T5=z2+"+?",O8=0;class V0{type;#Q;#Z;#K=!1;#J=[];#Y;#_;#F;#W=!1;#H;#$;#q=!1;id=++O8;get depth(){return(this.#Y?.depth??-1)+1}[Symbol.for("nodejs.util.inspect.custom")](){return{"@@type":"AST",id:this.id,type:this.type,root:this.#Q.id,parent:this.#Y?.id,depth:this.depth,partsLength:this.#J.length,parts:this.#J}}constructor(Q,J,Z={}){if(this.type=Q,Q)this.#Z=!0;if(this.#Y=J,this.#Q=this.#Y?this.#Y.#Q:this,this.#H=this.#Q===this?Z:this.#Q.#H,this.#F=this.#Q===this?[]:this.#Q.#F,Q==="!"&&!this.#Q.#W)this.#F.push(this);this.#_=this.#Y?this.#Y.#J.length:0}get hasMagic(){if(this.#Z!==void 0)return this.#Z;for(let Q of this.#J){if(typeof Q==="string")continue;if(Q.type||Q.hasMagic)return this.#Z=!0}return this.#Z}toString(){return this.#$!==void 0?this.#$:!this.type?this.#$=this.#J.map((Q)=>String(Q)).join(""):this.#$=this.type+"("+this.#J.map((Q)=>String(Q)).join("|")+")"}#z(){if(this!==this.#Q)throw Error("should only call on root");if(this.#W)return this;this.toString(),this.#W=!0;let Q;while(Q=this.#F.pop()){if(Q.type!=="!")continue;let J=Q,Z=J.#Y;while(Z){for(let Y=J.#_+1;!Z.type&&Y<Z.#J.length;Y++)for(let K of Q.#J){if(typeof K==="string")throw Error("string part in extglob AST??");K.copyIn(Z.#J[Y])}J=Z,Z=J.#Y}}return this}push(...Q){for(let J of Q){if(J==="")continue;if(typeof J!=="string"&&!(J instanceof y&&J.#Y===this))throw Error("invalid part: "+J);this.#J.push(J)}}toJSON(){let Q=this.type===null?this.#J.slice().map((J)=>typeof J==="string"?J:J.toJSON()):[this.type,...this.#J.map((J)=>J.toJSON())];if(this.isStart()&&!this.type)Q.unshift([]);if(this.isEnd()&&(this===this.#Q||this.#Q.#W&&this.#Y?.type==="!"))Q.push({});return Q}isStart(){if(this.#Q===this)return!0;if(!this.#Y?.isStart())return!1;if(this.#_===0)return!0;let Q=this.#Y;for(let J=0;J<this.#_;J++){let Z=Q.#J[J];if(!(Z instanceof y&&Z.type==="!"))return!1}return!0}isEnd(){if(this.#Q===this)return!0;if(this.#Y?.type==="!")return!0;if(!this.#Y?.isEnd())return!1;if(!this.type)return this.#Y?.isEnd();let Q=this.#Y?this.#Y.#J.length:0;return this.#_===Q-1}copyIn(Q){if(typeof Q==="string")this.push(Q);else this.push(Q.clone(this))}clone(Q){let J=new y(this.type,Q);for(let Z of this.#J)J.copyIn(Z);return J}static#X(Q,J,Z,Y,K){let V=Y.maxExtglobRecursion??2,X=!1,W=!1,H=-1,z=!1;if(J.type===null){let G=Z,_="";while(G<Q.length){let O=Q.charAt(G++);if(X||O==="\\"){X=!X,_+=O;continue}if(W){if(G===H+1){if(O==="^"||O==="!")z=!0}else if(O==="]"&&!(G===H+2&&z))W=!1;_+=O;continue}else if(O==="["){W=!0,H=G,z=!1,_+=O;continue}if(!Y.noext&&W2(O)&&Q.charAt(G)==="("&&K<=V){J.push(_),_="";let j=new y(O,J);G=y.#X(Q,j,G,Y,K+1),J.push(j);continue}_+=O}return J.push(_),G}let q=Z+1,$=new y(null,J),F=[],U="";while(q<Q.length){let G=Q.charAt(q++);if(X||G==="\\"){X=!X,U+=G;continue}if(W){if(q===H+1){if(G==="^"||G==="!")z=!0}else if(G==="]"&&!(q===H+2&&z))W=!1;U+=G;continue}else if(G==="["){W=!0,H=q,z=!1,U+=G;continue}if(!Y.noext&&W2(G)&&Q.charAt(q)==="("&&(K<=V||J&&J.#O(G))){let O=J&&J.#O(G)?0:1;$.push(U),U="";let C=new y(G,$);$.push(C),q=y.#X(Q,C,q,Y,K+O);continue}if(G==="|"){$.push(U),U="",F.push($),$=new y(null,J);continue}if(G===")"){if(U===""&&J.#J.length===0)J.#q=!0;return $.push(U),U="",J.push(...F,$),q}U+=G}return J.type=null,J.#Z=void 0,J.#J=[Q.substring(Z-1)],q}#C(Q){return this.#L(Q,$8)}#L(Q,J=z8){if(!Q||typeof Q!=="object"||Q.type!==null||Q.#J.length!==1||this.type===null)return!1;let Z=Q.#J[0];if(!Z||typeof Z!=="object"||Z.type===null)return!1;return this.#O(Z.type,J)}#O(Q,J=q8){return!!J.get(this.type)?.includes(Q)}#j(Q,J){let Z=Q.#J[0],Y=new y(null,Z,this.options);Y.#J.push(""),Z.push(Y),this.#v(Q,J)}#v(Q,J){let Z=Q.#J[0];this.#J.splice(J,1,...Z.#J);for(let Y of Z.#J)if(typeof Y==="object")Y.#Y=this;this.#$=void 0}#k(Q){return!!E5.get(this.type)?.has(Q)}#A(Q){if(!Q||typeof Q!=="object"||Q.type!==null||Q.#J.length!==1||this.type===null||this.#J.length!==1)return!1;let J=Q.#J[0];if(!J||typeof J!=="object"||J.type===null)return!1;return this.#k(J.type)}#I(Q){let J=E5.get(this.type),Z=Q.#J[0],Y=J?.get(Z.type);if(!Y)return!1;this.#J=Z.#J;for(let K of this.#J)if(typeof K==="object")K.#Y=this;this.type=Y,this.#$=void 0,this.#q=!1}static fromGlob(Q,J={}){let Z=new y(null,void 0,J);return y.#X(Q,Z,0,J,0),Z}toMMPattern(){if(this!==this.#Q)return this.#Q.toMMPattern();let Q=this.toString(),[J,Z,Y,K]=this.toRegExpSource();if(!(Y||this.#Z||this.#H.nocase&&!this.#H.nocaseMagicOnly&&Q.toUpperCase()!==Q.toLowerCase()))return Z;let X=(this.#H.nocase?"i":"")+(K?"u":"");return Object.assign(new RegExp(`^${J}$`,X),{_src:J,_glob:Q})}get options(){return this.#H}toRegExpSource(Q){let J=Q??!!this.#H.dot;if(this.#Q===this)this.#G(),this.#z();if(!M5(this)){let W=this.isStart()&&this.isEnd()&&!this.#J.some((F)=>typeof F!=="string"),H=this.#J.map((F)=>{let[U,G,_,O]=typeof F==="string"?y.#R(F,this.#Z,W):F.toRegExpSource(Q);return this.#Z=this.#Z||_,this.#K=this.#K||O,U}).join(""),z="";if(this.isStart()){if(typeof this.#J[0]==="string"){if(!(this.#J.length===1&&G8.has(this.#J[0]))){let U=F8,G=J&&U.has(H.charAt(0))||H.startsWith("\\.")&&U.has(H.charAt(2))||H.startsWith("\\.\\.")&&U.has(H.charAt(4)),_=!J&&!Q&&U.has(H.charAt(0));z=G?U8:_?h0:""}}}let q="";if(this.isEnd()&&this.#Q.#W&&this.#Y?.type==="!")q="(?:$|\\/)";return[z+H+q,a(H),this.#Z=!!this.#Z,this.#K]}let Z=this.type==="*"||this.type==="+",Y=this.type==="!"?"(?:(?!(?:":"(?:",K=this.#B(J);if(this.isStart()&&this.isEnd()&&!K&&this.type!=="!"){let W=this.toString(),H=this;return H.#J=[W],H.type=null,H.#Z=void 0,[W,a(this.toString()),!1,!1]}let V=!Z||Q||J||!h0?"":this.#B(!0);if(V===K)V="";if(V)K=`(?:${K})(?:${V})*?`;let X="";if(this.type==="!"&&this.#q)X=(this.isStart()&&!J?h0:"")+T5;else{let W=this.type==="!"?"))"+(this.isStart()&&!J&&!Q?h0:"")+P5+")":this.type==="@"?")":this.type==="?"?")?":this.type==="+"&&V?")":this.type==="*"&&V?")?":`)${this.type}`;X=Y+K+W}return[X,a(K),this.#Z=!!this.#Z,this.#K]}#G(){if(!M5(this)){for(let Q of this.#J)if(typeof Q==="object")Q.#G()}else{let Q=0,J=!1;do{J=!0;for(let Z=0;Z<this.#J.length;Z++){let Y=this.#J[Z];if(typeof Y==="object"){if(Y.#G(),this.#L(Y))J=!1,this.#v(Y,Z);else if(this.#C(Y))J=!1,this.#j(Y,Z);else if(this.#A(Y))J=!1,this.#I(Y)}}}while(!J&&++Q<10)}this.#$=void 0}#B(Q){return this.#J.map((J)=>{if(typeof J==="string")throw Error("string type in extglob ast??");let[Z,Y,K,V]=J.toRegExpSource(Q);return this.#K=this.#K||V,Z}).filter((J)=>!(this.isStart()&&this.isEnd())||!!J).join("|")}static#R(Q,J,Z=!1){let Y=!1,K="",V=!1,X=!1;for(let W=0;W<Q.length;W++){let H=Q.charAt(W);if(Y){Y=!1,K+=(_8.has(H)?"\\":"")+H;continue}if(H==="*"){if(X)continue;X=!0,K+=Z&&/^[*]+$/.test(Q)?T5:P5,J=!0;continue}else X=!1;if(H==="\\"){if(W===Q.length-1)K+="\\\\";else Y=!0;continue}if(H==="["){let[z,q,$,F]=D5(Q,W);if($){K+=z,V=V||q,W+=$-1,J=J||F;continue}}if(H==="?"){K+=z2,J=!0;continue}K+=C8(H)}return[K,a(Q),!!J,V]}}y=V0;var $2=(Q,{windowsPathsNoEscape:J=!1,magicalBraces:Z=!1}={})=>{if(Z)return J?Q.replace(/[?*()[\]{}]/g,"[$&]"):Q.replace(/[?*()[\]\\{}]/g,"\\$&");return J?Q.replace(/[?*()[\]]/g,"[$&]"):Q.replace(/[?*()[\]\\]/g,"\\$&")};var v=(Q,J,Z={})=>{if(O0(J),!Z.nocomment&&J.charAt(0)==="#")return!1;return new k0(J,Z).match(Q)},j8=/^\*+([^+@!?*[(]*)$/,k8=(Q)=>(J)=>!J.startsWith(".")&&J.endsWith(Q),B8=(Q)=>(J)=>J.endsWith(Q),L8=(Q)=>{return Q=Q.toLowerCase(),(J)=>!J.startsWith(".")&&J.toLowerCase().endsWith(Q)},R8=(Q)=>{return Q=Q.toLowerCase(),(J)=>J.toLowerCase().endsWith(Q)},A8=/^\*+\.\*+$/,I8=(Q)=>!Q.startsWith(".")&&Q.includes("."),N8=(Q)=>Q!=="."&&Q!==".."&&Q.includes("."),v8=/^\.\*+$/,D8=(Q)=>Q!=="."&&Q!==".."&&Q.startsWith("."),M8=/^\*+$/,E8=(Q)=>Q.length!==0&&!Q.startsWith("."),P8=(Q)=>Q.length!==0&&Q!=="."&&Q!=="..",T8=/^\?+([^+@!?*[(]*)?$/,w8=([Q,J=""])=>{let Z=S5([Q]);if(!J)return Z;return J=J.toLowerCase(),(Y)=>Z(Y)&&Y.toLowerCase().endsWith(J)},y8=([Q,J=""])=>{let Z=u5([Q]);if(!J)return Z;return J=J.toLowerCase(),(Y)=>Z(Y)&&Y.toLowerCase().endsWith(J)},S8=([Q,J=""])=>{let Z=u5([Q]);return!J?Z:(Y)=>Z(Y)&&Y.endsWith(J)},u8=([Q,J=""])=>{let Z=S5([Q]);return!J?Z:(Y)=>Z(Y)&&Y.endsWith(J)},S5=([Q])=>{let J=Q.length;return(Z)=>Z.length===J&&!Z.startsWith(".")},u5=([Q])=>{let J=Q.length;return(Z)=>Z.length===J&&Z!=="."&&Z!==".."},x5=typeof process==="object"&&process?typeof process.env==="object"&&process.env&&process.env.__MINIMATCH_TESTING_PLATFORM__||process.platform:"posix",w5={win32:{sep:"\\"},posix:{sep:"/"}},x8=x5==="win32"?w5.win32.sep:w5.posix.sep;v.sep=x8;var M=Symbol("globstar **");v.GLOBSTAR=M;var b8="[^/]",m8=b8+"*?",g8="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?",h8="(?:(?!(?:\\/|^)\\.).)*?",f8=(Q,J={})=>(Z)=>v(Z,Q,J);v.filter=f8;var m=(Q,J={})=>Object.assign({},Q,J),d8=(Q)=>{if(!Q||typeof Q!=="object"||!Object.keys(Q).length)return v;let J=v;return Object.assign((Y,K,V={})=>J(Y,K,m(Q,V)),{Minimatch:class extends J.Minimatch{constructor(K,V={}){super(K,m(Q,V))}static defaults(K){return J.defaults(m(Q,K)).Minimatch}},AST:class extends J.AST{constructor(K,V,X={}){super(K,V,m(Q,X))}static fromGlob(K,V={}){return J.AST.fromGlob(K,m(Q,V))}},unescape:(Y,K={})=>J.unescape(Y,m(Q,K)),escape:(Y,K={})=>J.escape(Y,m(Q,K)),filter:(Y,K={})=>J.filter(Y,m(Q,K)),defaults:(Y)=>J.defaults(m(Q,Y)),makeRe:(Y,K={})=>J.makeRe(Y,m(Q,K)),braceExpand:(Y,K={})=>J.braceExpand(Y,m(Q,K)),match:(Y,K,V={})=>J.match(Y,K,m(Q,V)),sep:J.sep,GLOBSTAR:M})};v.defaults=d8;var b5=(Q,J={})=>{if(O0(Q),J.nobrace||!/\{(?:(?!\{).)*\}/.test(Q))return[Q];return N5(Q,{max:J.braceExpandMax})};v.braceExpand=b5;var c8=(Q,J={})=>new k0(Q,J).makeRe();v.makeRe=c8;var l8=(Q,J,Z={})=>{let Y=new k0(J,Z);if(Q=Q.filter((K)=>Y.match(K)),Y.options.nonull&&!Q.length)Q.push(J);return Q};v.match=l8;var y5=/[?*]|[+@!]\(.*?\)|\[|\]/,o8=(Q)=>Q.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&");class k0{options;set;pattern;windowsPathsNoEscape;nonegate;negate;comment;empty;preserveMultipleSlashes;partial;globSet;globParts;nocase;isWindows;platform;windowsNoMagicRoot;maxGlobstarRecursion;regexp;constructor(Q,J={}){O0(Q),J=J||{},this.options=J,this.maxGlobstarRecursion=J.maxGlobstarRecursion??200,this.pattern=Q,this.platform=J.platform||x5,this.isWindows=this.platform==="win32";let Z="allowWindowsEscape";if(this.windowsPathsNoEscape=!!J.windowsPathsNoEscape||J[Z]===!1,this.windowsPathsNoEscape)this.pattern=this.pattern.replace(/\\/g,"/");this.preserveMultipleSlashes=!!J.preserveMultipleSlashes,this.regexp=null,this.negate=!1,this.nonegate=!!J.nonegate,this.comment=!1,this.empty=!1,this.partial=!!J.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=J.windowsNoMagicRoot!==void 0?J.windowsNoMagicRoot:!!(this.isWindows&&this.nocase),this.globSet=[],this.globParts=[],this.set=[],this.make()}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(let Q of this.set)for(let J of Q)if(typeof J!=="string")return!0;return!1}debug(...Q){}make(){let Q=this.pattern,J=this.options;if(!J.nocomment&&Q.charAt(0)==="#"){this.comment=!0;return}if(!Q){this.empty=!0;return}if(this.parseNegate(),this.globSet=[...new Set(this.braceExpand())],J.debug)this.debug=(...K)=>console.error(...K);this.debug(this.pattern,this.globSet);let Z=this.globSet.map((K)=>this.slashSplit(K));this.globParts=this.preprocess(Z),this.debug(this.pattern,this.globParts);let Y=this.globParts.map((K,V,X)=>{if(this.isWindows&&this.windowsNoMagicRoot){let W=K[0]===""&&K[1]===""&&(K[2]==="?"||!y5.test(K[2]))&&!y5.test(K[3]),H=/^[a-z]:/i.test(K[0]);if(W)return[...K.slice(0,4),...K.slice(4).map((z)=>this.parse(z))];else if(H)return[K[0],...K.slice(1).map((z)=>this.parse(z))]}return K.map((W)=>this.parse(W))});if(this.debug(this.pattern,Y),this.set=Y.filter((K)=>K.indexOf(!1)===-1),this.isWindows)for(let K=0;K<this.set.length;K++){let V=this.set[K];if(V[0]===""&&V[1]===""&&this.globParts[K][2]==="?"&&typeof V[3]==="string"&&/^[a-z]:$/i.test(V[3]))V[2]="?"}this.debug(this.pattern,this.set)}preprocess(Q){if(this.options.noglobstar){for(let Z of Q)for(let Y=0;Y<Z.length;Y++)if(Z[Y]==="**")Z[Y]="*"}let{optimizationLevel:J=1}=this.options;if(J>=2)Q=this.firstPhasePreProcess(Q),Q=this.secondPhasePreProcess(Q);else if(J>=1)Q=this.levelOneOptimize(Q);else Q=this.adjascentGlobstarOptimize(Q);return Q}adjascentGlobstarOptimize(Q){return Q.map((J)=>{let Z=-1;while((Z=J.indexOf("**",Z+1))!==-1){let Y=Z;while(J[Y+1]==="**")Y++;if(Y!==Z)J.splice(Z,Y-Z)}return J})}levelOneOptimize(Q){return Q.map((J)=>{return J=J.reduce((Z,Y)=>{let K=Z[Z.length-1];if(Y==="**"&&K==="**")return Z;if(Y===".."){if(K&&K!==".."&&K!=="."&&K!=="**")return Z.pop(),Z}return Z.push(Y),Z},[]),J.length===0?[""]:J})}levelTwoFileOptimize(Q){if(!Array.isArray(Q))Q=this.slashSplit(Q);let J=!1;do{if(J=!1,!this.preserveMultipleSlashes){for(let Y=1;Y<Q.length-1;Y++){let K=Q[Y];if(Y===1&&K===""&&Q[0]==="")continue;if(K==="."||K==="")J=!0,Q.splice(Y,1),Y--}if(Q[0]==="."&&Q.length===2&&(Q[1]==="."||Q[1]===""))J=!0,Q.pop()}let Z=0;while((Z=Q.indexOf("..",Z+1))!==-1){let Y=Q[Z-1];if(Y&&Y!=="."&&Y!==".."&&Y!=="**"&&!(this.isWindows&&/^[a-z]:$/i.test(Y)))J=!0,Q.splice(Z-1,2),Z-=2}}while(J);return Q.length===0?[""]:Q}firstPhasePreProcess(Q){let J=!1;do{J=!1;for(let Z of Q){let Y=-1;while((Y=Z.indexOf("**",Y+1))!==-1){let V=Y;while(Z[V+1]==="**")V++;if(V>Y)Z.splice(Y+1,V-Y);let X=Z[Y+1],W=Z[Y+2],H=Z[Y+3];if(X!=="..")continue;if(!W||W==="."||W===".."||!H||H==="."||H==="..")continue;J=!0,Z.splice(Y,1);let z=Z.slice(0);z[Y]="**",Q.push(z),Y--}if(!this.preserveMultipleSlashes){for(let V=1;V<Z.length-1;V++){let X=Z[V];if(V===1&&X===""&&Z[0]==="")continue;if(X==="."||X==="")J=!0,Z.splice(V,1),V--}if(Z[0]==="."&&Z.length===2&&(Z[1]==="."||Z[1]===""))J=!0,Z.pop()}let K=0;while((K=Z.indexOf("..",K+1))!==-1){let V=Z[K-1];if(V&&V!=="."&&V!==".."&&V!=="**"){J=!0;let W=K===1&&Z[K+1]==="**"?["."]:[];if(Z.splice(K-1,2,...W),Z.length===0)Z.push("");K-=2}}}}while(J);return Q}secondPhasePreProcess(Q){for(let J=0;J<Q.length-1;J++)for(let Z=J+1;Z<Q.length;Z++){let Y=this.partsMatch(Q[J],Q[Z],!this.preserveMultipleSlashes);if(Y){Q[J]=[],Q[Z]=Y;break}}return Q.filter((J)=>J.length)}partsMatch(Q,J,Z=!1){let Y=0,K=0,V=[],X="";while(Y<Q.length&&K<J.length)if(Q[Y]===J[K])V.push(X==="b"?J[K]:Q[Y]),Y++,K++;else if(Z&&Q[Y]==="**"&&J[K]===Q[Y+1])V.push(Q[Y]),Y++;else if(Z&&J[K]==="**"&&Q[Y]===J[K+1])V.push(J[K]),K++;else if(Q[Y]==="*"&&J[K]&&(this.options.dot||!J[K].startsWith("."))&&J[K]!=="**"){if(X==="b")return!1;X="a",V.push(Q[Y]),Y++,K++}else if(J[K]==="*"&&Q[Y]&&(this.options.dot||!Q[Y].startsWith("."))&&Q[Y]!=="**"){if(X==="a")return!1;X="b",V.push(J[K]),Y++,K++}else return!1;return Q.length===J.length&&V}parseNegate(){if(this.nonegate)return;let Q=this.pattern,J=!1,Z=0;for(let Y=0;Y<Q.length&&Q.charAt(Y)==="!";Y++)J=!J,Z++;if(Z)this.pattern=Q.slice(Z);this.negate=J}matchOne(Q,J,Z=!1){let Y=0,K=0;if(this.isWindows){let X=typeof Q[0]==="string"&&/^[a-z]:$/i.test(Q[0]),W=!X&&Q[0]===""&&Q[1]===""&&Q[2]==="?"&&/^[a-z]:$/i.test(Q[3]),H=typeof J[0]==="string"&&/^[a-z]:$/i.test(J[0]),z=!H&&J[0]===""&&J[1]===""&&J[2]==="?"&&typeof J[3]==="string"&&/^[a-z]:$/i.test(J[3]),q=W?3:X?0:void 0,$=z?3:H?0:void 0;if(typeof q==="number"&&typeof $==="number"){let[F,U]=[Q[q],J[$]];if(F.toLowerCase()===U.toLowerCase())J[$]=F,K=$,Y=q}}let{optimizationLevel:V=1}=this.options;if(V>=2)Q=this.levelTwoFileOptimize(Q);if(J.includes(M))return this.#Q(Q,J,Z,Y,K);return this.#K(Q,J,Z,Y,K)}#Q(Q,J,Z,Y,K){let V=J.indexOf(M,K),X=J.lastIndexOf(M),[W,H,z]=Z?[J.slice(K,V),J.slice(V+1),[]]:[J.slice(K,V),J.slice(V+1,X),J.slice(X+1)];if(W.length){let C=Q.slice(Y,Y+W.length);if(!this.#K(C,W,Z,0,0))return!1;Y+=W.length,K+=W.length}let q=0;if(z.length){if(z.length+Y>Q.length)return!1;let C=Q.length-z.length;if(this.#K(Q,z,Z,C,0))q=z.length;else{if(Q[Q.length-1]!==""||Y+z.length===Q.length)return!1;if(C--,!this.#K(Q,z,Z,C,0))return!1;q=z.length+1}}if(!H.length){let C=!!q;for(let j=Y;j<Q.length-q;j++){let k=String(Q[j]);if(C=!0,k==="."||k===".."||!this.options.dot&&k.startsWith("."))return!1}return Z||C}let $=[[[],0]],F=$[0],U=0,G=[0];for(let C of H)if(C===M)G.push(U),F=[[],0],$.push(F);else F[0].push(C),U++;let _=$.length-1,O=Q.length-q;for(let C of $)C[1]=O-(G[_--]+C[0].length);return!!this.#Z(Q,$,Y,0,Z,0,!!q)}#Z(Q,J,Z,Y,K,V,X){let W=J[Y];if(!W){for(let q=Z;q<Q.length;q++){X=!0;let $=Q[q];if($==="."||$===".."||!this.options.dot&&$.startsWith("."))return!1}return X}let[H,z]=W;while(Z<=z){if(this.#K(Q.slice(0,Z+H.length),H,K,Z,0)&&V<this.maxGlobstarRecursion){let F=this.#Z(Q,J,Z+H.length,Y+1,K,V+1,X);if(F!==!1)return F}let $=Q[Z];if($==="."||$===".."||!this.options.dot&&$.startsWith("."))return!1;Z++}return K||null}#K(Q,J,Z,Y,K){let V,X,W,H;for(V=Y,X=K,H=Q.length,W=J.length;V<H&&X<W;V++,X++){this.debug("matchOne loop");let z=J[X],q=Q[V];if(this.debug(J,z,q),z===!1||z===M)return!1;let $;if(typeof z==="string")$=q===z,this.debug("string match",z,q,$);else $=z.test(q),this.debug("pattern match",z,q,$);if(!$)return!1}if(V===H&&X===W)return!0;else if(V===H)return Z;else if(X===W)return V===H-1&&Q[V]==="";else throw Error("wtf?")}braceExpand(){return b5(this.pattern,this.options)}parse(Q){O0(Q);let J=this.options;if(Q==="**")return M;if(Q==="")return"";let Z,Y=null;if(Z=Q.match(M8))Y=J.dot?P8:E8;else if(Z=Q.match(j8))Y=(J.nocase?J.dot?R8:L8:J.dot?B8:k8)(Z[1]);else if(Z=Q.match(T8))Y=(J.nocase?J.dot?y8:w8:J.dot?S8:u8)(Z);else if(Z=Q.match(A8))Y=J.dot?N8:I8;else if(Z=Q.match(v8))Y=D8;let K=V0.fromGlob(Q,this.options).toMMPattern();if(Y&&typeof K==="object")Reflect.defineProperty(K,"test",{value:Y});return K}makeRe(){if(this.regexp||this.regexp===!1)return this.regexp;let Q=this.set;if(!Q.length)return this.regexp=!1,this.regexp;let J=this.options,Z=J.noglobstar?m8:J.dot?g8:h8,Y=new Set(J.nocase?["i"]:[]),K=Q.map((W)=>{let H=W.map((q)=>{if(q instanceof RegExp)for(let $ of q.flags.split(""))Y.add($);return typeof q==="string"?o8(q):q===M?M:q._src});H.forEach((q,$)=>{let F=H[$+1],U=H[$-1];if(q!==M||U===M)return;if(U===void 0)if(F!==void 0&&F!==M)H[$+1]="(?:\\/|"+Z+"\\/)?"+F;else H[$]=Z;else if(F===void 0)H[$-1]=U+"(?:\\/|\\/"+Z+")?";else if(F!==M)H[$-1]=U+"(?:\\/|\\/"+Z+"\\/)"+F,H[$+1]=M});let z=H.filter((q)=>q!==M);if(this.partial&&z.length>=1){let q=[];for(let $=1;$<=z.length;$++)q.push(z.slice(0,$).join("/"));return"(?:"+q.join("|")+")"}return z.join("/")}).join("|"),[V,X]=Q.length>1?["(?:",")"]:["",""];if(K="^"+V+K+X+"$",this.partial)K="^(?:\\/|"+V+K.slice(1,-1)+X+")$";if(this.negate)K="^(?!"+K+").+$";try{this.regexp=new RegExp(K,[...Y].join(""))}catch{this.regexp=!1}return this.regexp}slashSplit(Q){if(this.preserveMultipleSlashes)return Q.split("/");else if(this.isWindows&&/^\/\/[^/]+/.test(Q))return["",...Q.split(/\/+/)];else return Q.split(/\/+/)}match(Q,J=this.partial){if(this.debug("match",Q,this.pattern),this.comment)return!1;if(this.empty)return Q==="";if(Q==="/"&&J)return!0;let Z=this.options;if(this.isWindows)Q=Q.split("\\").join("/");let Y=this.slashSplit(Q);this.debug(this.pattern,"split",Y);let K=this.set;this.debug(this.pattern,"set",K);let V=Y[Y.length-1];if(!V)for(let X=Y.length-2;!V&&X>=0;X--)V=Y[X];for(let X of K){let W=Y;if(Z.matchBase&&X.length===1)W=[V];if(this.matchOne(W,X,J)){if(Z.flipNegate)return!0;return!this.negate}}if(Z.flipNegate)return!1;return this.negate}static defaults(Q){return v.defaults(Q).Minimatch}}v.AST=V0;v.Minimatch=k0;v.escape=$2;v.unescape=a;var q2;((j4)=>{function Q(K){return{cwd:K.cwd,absolute:K.absolute,dot:K.dot,follow:K.symlink??!1,nodir:K.include!=="all"}}async function J(K,V={}){return u0(K,Q(V))}j4.scan=J;function Z(K,V={}){return m0(K,Q(V))}j4.scanSync=Z;function Y(K,V){return v(V,K,{dot:!0})}j4.match=Y})(q2||={});function B4(Q){return!!Q&&typeof Q==="object"&&!Array.isArray(Q)}var O2={};p8(O2,{writeStream:()=>W9,writeJson:()=>H9,write:()=>o5,windowsPath:()=>C2,up:()=>C9,statAsync:()=>J9,stat:()=>l5,size:()=>Z9,resolveFilePath:()=>U9,resolve:()=>q9,readText:()=>Y9,readJson:()=>K9,readBytes:()=>V9,readArrayBuffer:()=>X9,overlaps:()=>F9,normalizePathPattern:()=>$9,normalizePath:()=>B0,mimeType:()=>z9,isDir:()=>Q9,globUp:()=>O9,findUp:()=>_9,exists:()=>G2,contains:()=>G9,Filesystem:()=>O2});import{chmod as n8,mkdir as g5,readFile as d0,stat as r8,writeFile as f0}from"fs/promises";import{createWriteStream as i8,existsSync as h5,statSync as f5}from"fs";import{realpathSync as d5}from"fs";import{dirname as L0,isAbsolute as a8,join as F2,relative as U2,resolve as c5,win32 as m5}from"path";import{Readable as s8}from"stream";import{pipeline as e8}from"stream/promises";import{fileURLToPath as t8}from"url";async function G2(Q){return h5(Q)}async function Q9(Q){try{return f5(Q).isDirectory()}catch{return!1}}function l5(Q){return f5(Q,{throwIfNoEntry:!1})??void 0}async function J9(Q){return r8(Q).catch((J)=>{if(_2(J))return;throw J})}async function Z9(Q){let J=l5(Q)?.size??0;return typeof J==="bigint"?Number(J):J}async function Y9(Q){return d0(Q,"utf-8")}async function K9(Q){return JSON.parse(await d0(Q,"utf-8"))}async function V9(Q){return d0(Q)}async function X9(Q){let J=await d0(Q);return J.buffer.slice(J.byteOffset,J.byteOffset+J.byteLength)}function _2(Q){return typeof Q==="object"&&Q!==null&&"code"in Q&&Q.code==="ENOENT"}async function o5(Q,J,Z){try{if(Z)await f0(Q,J,{mode:Z});else await f0(Q,J)}catch(Y){if(_2(Y)){if(await g5(L0(Q),{recursive:!0}),Z)await f0(Q,J,{mode:Z});else await f0(Q,J);return}throw Y}}async function H9(Q,J,Z){return o5(Q,JSON.stringify(J,null,2),Z)}async function W9(Q,J,Z){let Y=L0(Q);if(!h5(Y))await g5(Y,{recursive:!0});let K=J instanceof ReadableStream?s8.fromWeb(J):J,V=i8(Q);if(await e8(K,V),Z)await n8(Q,Z)}async function z9(Q){let{lookup:J}=await import("./chunk-wyed730e.js");return J(Q)||"application/octet-stream"}function B0(Q){if(process.platform!=="win32")return Q;let J=m5.normalize(m5.resolve(C2(Q)));try{return d5.native(J)}catch{return J}}function $9(Q){if(process.platform!=="win32")return Q;if(Q==="*")return Q;let J=Q.match(/^(.*)[\\/]\*$/);if(!J)return B0(Q);let Z=/^[A-Za-z]:$/.test(J[1])?J[1]+"\\":J[1];return F2(B0(Z),"*")}function q9(Q){let J=c5(C2(Q));try{return B0(d5(J))}catch(Z){if(_2(Z))return B0(J);throw Z}}function U9(Q,J){let Z=J.startsWith("file://")?t8(J):J;if(a8(Z))return Z;return c5(Q,Z)}function C2(Q){if(process.platform!=="win32")return Q;return Q.replace(/^\/([a-zA-Z]):(?:[\\/]|$)/,(J,Z)=>`${Z.toUpperCase()}:/`).replace(/^\/([a-zA-Z])(?:\/|$)/,(J,Z)=>`${Z.toUpperCase()}:/`).replace(/^\/cygdrive\/([a-zA-Z])(?:\/|$)/,(J,Z)=>`${Z.toUpperCase()}:/`).replace(/^\/mnt\/([a-zA-Z])(?:\/|$)/,(J,Z)=>`${Z.toUpperCase()}:/`)}function F9(Q,J){let Z=U2(Q,J),Y=U2(J,Q);return!Z||!Z.startsWith("..")||!Y||!Y.startsWith("..")}function G9(Q,J){return!U2(Q,J).startsWith("..")}async function _9(Q,J,Z,Y){let K=[J],V=J;while(!0){if(Z===V)break;let H=L0(V);if(H===V)break;K.push(H),V=H}let X=Array.isArray(Q)?Q:[Q],W=[];for(let H of Y?.rootFirst?K.toReversed():K)for(let z of X){let q=F2(H,z);if(await G2(q))W.push(q)}return W}async function*C9(Q){let{targets:J,start:Z,stop:Y}=Q,K=Z;while(!0){for(let X of J){let W=F2(K,X);if(await G2(W))yield W}if(Y===K)break;let V=L0(K);if(V===K)break;K=V}}async function O9(Q,J,Z){let Y=J,K=[];while(!0){try{let X=await q2.scan(Q,{cwd:Y,absolute:!0,include:"file",dot:!0});K.push(...X)}catch{}if(Z===Y)break;let V=L0(Y);if(V===Y)break;Y=V}return K}
|
|
5
|
+
export{q2 as bs,B4 as cs,G2 as ds,Y9 as es,V9 as fs,O2 as gs};
|