@tsmodule/tsmodule 31.0.1 → 31.1.0
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/commands/build/index.js +329 -5
- package/dist/commands/build/lib/emitTsDeclarations.js +284 -3
- package/dist/commands/create/index.js +20 -1
- package/dist/commands/create/lib/createTemplate.js +10 -1
- package/dist/commands/create/lib/rewritePkgJson.js +4 -1
- package/dist/commands/dev/index.js +334 -3
- package/dist/commands/execute/index.js +10 -1
- package/dist/commands/normalize/index.js +317 -3
- package/dist/commands/normalize/lib/typescriptApi.js +282 -1
- package/dist/constants.js +4 -1
- package/dist/index.js +361 -5
- package/dist/loader/index.js +12 -1
- package/dist/loader/types.js +3 -0
- package/dist/types/index.js +3 -1
- package/dist/utils/cwd.js +4 -1
- package/dist/utils/pkgJson.js +4 -1
- package/dist/utils/require.js +4 -1
- package/dist/utils/resolve.js +4 -1
- package/dist/utils/stdin.js +12 -1
- package/package.json +3 -3
@@ -1 +1,20 @@
|
|
1
|
-
|
1
|
+
|
2
|
+
await(async()=>{let{dirname:e}=await import("path"),{fileURLToPath:i}=await import("url");if(typeof globalThis.__filename>"u"&&(globalThis.__filename=i(import.meta.url)),typeof globalThis.__dirname>"u"&&(globalThis.__dirname=e(globalThis.__filename)),typeof globalThis.require>"u"){let{default:a}=await import("module");globalThis.require=a.createRequire(import.meta.url)}})();
|
3
|
+
|
4
|
+
var Ma=Object.create;var dr=Object.defineProperty;var La=Object.getOwnPropertyDescriptor;var ja=Object.getOwnPropertyNames;var Ua=Object.getPrototypeOf,Wa=Object.prototype.hasOwnProperty;var $a=e=>dr(e,"__esModule",{value:!0});var E=(e=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(e,{get:(t,r)=>(typeof require!="undefined"?require:t)[r]}):e)(function(e){if(typeof require!="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});var Ga=(e,t)=>()=>(e&&(t=e(e=0)),t);var m=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var Ya=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of ja(t))!Wa.call(e,i)&&(r||i!=="default")&&dr(e,i,{get:()=>t[i],enumerable:!(n=La(t,i))||n.enumerable});return e},Be=(e,t)=>Ya($a(dr(e!=null?Ma(Ua(e)):{},"default",!t&&e&&e.__esModule?{get:()=>e.default,enumerable:!0}:{value:e,enumerable:!0})),e);var a=Ga(()=>{});var jn=m((fd,xr)=>{"use strict";a();var Ln=(e,t)=>{for(let r of Reflect.ownKeys(t))Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r));return e};xr.exports=Ln;xr.exports.default=Ln});var Wn=m((ld,Rt)=>{"use strict";a();var hu=jn(),bt=new WeakMap,Un=(e,t={})=>{if(typeof e!="function")throw new TypeError("Expected a function");let r,n=0,i=e.displayName||e.name||"<anonymous>",o=function(...s){if(bt.set(o,++n),n===1)r=e.apply(this,s),e=null;else if(t.throw===!0)throw new Error(`Function \`${i}\` can only be called once`);return r};return hu(o,e),bt.set(o,n),o};Rt.exports=Un;Rt.exports.default=Un;Rt.exports.callCount=e=>{if(!bt.has(e))throw new Error(`The given function \`${e.name}\` is not wrapped by the \`onetime\` package`);return bt.get(e)}});var $n=m((cd,Tt)=>{a();Tt.exports=["SIGABRT","SIGALRM","SIGHUP","SIGINT","SIGTERM"];process.platform!=="win32"&&Tt.exports.push("SIGVTALRM","SIGXCPU","SIGXFSZ","SIGUSR2","SIGTRAP","SIGSYS","SIGQUIT","SIGIOT");process.platform==="linux"&&Tt.exports.push("SIGIO","SIGPOLL","SIGPWR","SIGSTKFLT","SIGUNUSED")});var Jn=m((hd,je)=>{a();var F=global.process,Ee=function(e){return e&&typeof e=="object"&&typeof e.removeListener=="function"&&typeof e.emit=="function"&&typeof e.reallyExit=="function"&&typeof e.listeners=="function"&&typeof e.kill=="function"&&typeof e.pid=="number"&&typeof e.on=="function"};Ee(F)?(Gn=E("assert"),Me=$n(),Yn=/^win/i.test(F.platform),Ze=E("events"),typeof Ze!="function"&&(Ze=Ze.EventEmitter),F.__signal_exit_emitter__?I=F.__signal_exit_emitter__:(I=F.__signal_exit_emitter__=new Ze,I.count=0,I.emitted={}),I.infinite||(I.setMaxListeners(1/0),I.infinite=!0),je.exports=function(e,t){if(!Ee(global.process))return function(){};Gn.equal(typeof e,"function","a callback must be provided for exit handler"),Le===!1&&vr();var r="exit";t&&t.alwaysLast&&(r="afterexit");var n=function(){I.removeListener(r,e),I.listeners("exit").length===0&&I.listeners("afterexit").length===0&&Ot()};return I.on(r,e),n},Ot=function(){!Le||!Ee(global.process)||(Le=!1,Me.forEach(function(t){try{F.removeListener(t,Ct[t])}catch{}}),F.emit=At,F.reallyExit=wr,I.count-=1)},je.exports.unload=Ot,be=function(t,r,n){I.emitted[t]||(I.emitted[t]=!0,I.emit(t,r,n))},Ct={},Me.forEach(function(e){Ct[e]=function(){if(!!Ee(global.process)){var r=F.listeners(e);r.length===I.count&&(Ot(),be("exit",null,e),be("afterexit",null,e),Yn&&e==="SIGHUP"&&(e="SIGINT"),F.kill(F.pid,e))}}}),je.exports.signals=function(){return Me},Le=!1,vr=function(){Le||!Ee(global.process)||(Le=!0,I.count+=1,Me=Me.filter(function(t){try{return F.on(t,Ct[t]),!0}catch{return!1}}),F.emit=Vn,F.reallyExit=Hn)},je.exports.load=vr,wr=F.reallyExit,Hn=function(t){!Ee(global.process)||(F.exitCode=t||0,be("exit",F.exitCode,null),be("afterexit",F.exitCode,null),wr.call(F,F.exitCode))},At=F.emit,Vn=function(t,r){if(t==="exit"&&Ee(global.process)){r!==void 0&&(F.exitCode=r);var n=At.apply(this,arguments);return be("exit",F.exitCode,null),be("afterexit",F.exitCode,null),n}else return At.apply(this,arguments)}):je.exports=function(){return function(){}};var Gn,Me,Yn,Ze,I,Ot,be,Ct,Le,vr,wr,Hn,At,Vn});var zn=m((gd,yu)=>{yu.exports={dots:{interval:80,frames:["⠋","⠙","⠹","⠸","⠼","⠴","⠦","⠧","⠇","⠏"]},dots2:{interval:80,frames:["⣾","⣽","⣻","⢿","⡿","⣟","⣯","⣷"]},dots3:{interval:80,frames:["⠋","⠙","⠚","⠞","⠖","⠦","⠴","⠲","⠳","⠓"]},dots4:{interval:80,frames:["⠄","⠆","⠇","⠋","⠙","⠸","⠰","⠠","⠰","⠸","⠙","⠋","⠇","⠆"]},dots5:{interval:80,frames:["⠋","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋"]},dots6:{interval:80,frames:["⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠴","⠲","⠒","⠂","⠂","⠒","⠚","⠙","⠉","⠁"]},dots7:{interval:80,frames:["⠈","⠉","⠋","⠓","⠒","⠐","⠐","⠒","⠖","⠦","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈"]},dots8:{interval:80,frames:["⠁","⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈","⠈"]},dots9:{interval:80,frames:["⢹","⢺","⢼","⣸","⣇","⡧","⡗","⡏"]},dots10:{interval:80,frames:["⢄","⢂","⢁","⡁","⡈","⡐","⡠"]},dots11:{interval:100,frames:["⠁","⠂","⠄","⡀","⢀","⠠","⠐","⠈"]},dots12:{interval:80,frames:["⢀⠀","⡀⠀","⠄⠀","⢂⠀","⡂⠀","⠅⠀","⢃⠀","⡃⠀","⠍⠀","⢋⠀","⡋⠀","⠍⠁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⢈⠩","⡀⢙","⠄⡙","⢂⠩","⡂⢘","⠅⡘","⢃⠨","⡃⢐","⠍⡐","⢋⠠","⡋⢀","⠍⡁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⠈⠩","⠀⢙","⠀⡙","⠀⠩","⠀⢘","⠀⡘","⠀⠨","⠀⢐","⠀⡐","⠀⠠","⠀⢀","⠀⡀"]},dots8Bit:{interval:80,frames:["⠀","⠁","⠂","⠃","⠄","⠅","⠆","⠇","⡀","⡁","⡂","⡃","⡄","⡅","⡆","⡇","⠈","⠉","⠊","⠋","⠌","⠍","⠎","⠏","⡈","⡉","⡊","⡋","⡌","⡍","⡎","⡏","⠐","⠑","⠒","⠓","⠔","⠕","⠖","⠗","⡐","⡑","⡒","⡓","⡔","⡕","⡖","⡗","⠘","⠙","⠚","⠛","⠜","⠝","⠞","⠟","⡘","⡙","⡚","⡛","⡜","⡝","⡞","⡟","⠠","⠡","⠢","⠣","⠤","⠥","⠦","⠧","⡠","⡡","⡢","⡣","⡤","⡥","⡦","⡧","⠨","⠩","⠪","⠫","⠬","⠭","⠮","⠯","⡨","⡩","⡪","⡫","⡬","⡭","⡮","⡯","⠰","⠱","⠲","⠳","⠴","⠵","⠶","⠷","⡰","⡱","⡲","⡳","⡴","⡵","⡶","⡷","⠸","⠹","⠺","⠻","⠼","⠽","⠾","⠿","⡸","⡹","⡺","⡻","⡼","⡽","⡾","⡿","⢀","⢁","⢂","⢃","⢄","⢅","⢆","⢇","⣀","⣁","⣂","⣃","⣄","⣅","⣆","⣇","⢈","⢉","⢊","⢋","⢌","⢍","⢎","⢏","⣈","⣉","⣊","⣋","⣌","⣍","⣎","⣏","⢐","⢑","⢒","⢓","⢔","⢕","⢖","⢗","⣐","⣑","⣒","⣓","⣔","⣕","⣖","⣗","⢘","⢙","⢚","⢛","⢜","⢝","⢞","⢟","⣘","⣙","⣚","⣛","⣜","⣝","⣞","⣟","⢠","⢡","⢢","⢣","⢤","⢥","⢦","⢧","⣠","⣡","⣢","⣣","⣤","⣥","⣦","⣧","⢨","⢩","⢪","⢫","⢬","⢭","⢮","⢯","⣨","⣩","⣪","⣫","⣬","⣭","⣮","⣯","⢰","⢱","⢲","⢳","⢴","⢵","⢶","⢷","⣰","⣱","⣲","⣳","⣴","⣵","⣶","⣷","⢸","⢹","⢺","⢻","⢼","⢽","⢾","⢿","⣸","⣹","⣺","⣻","⣼","⣽","⣾","⣿"]},line:{interval:130,frames:["-","\\","|","/"]},line2:{interval:100,frames:["⠂","-","–","—","–","-"]},pipe:{interval:100,frames:["┤","┘","┴","└","├","┌","┬","┐"]},simpleDots:{interval:400,frames:[". ",".. ","..."," "]},simpleDotsScrolling:{interval:200,frames:[". ",".. ","..."," .."," ."," "]},star:{interval:70,frames:["✶","✸","✹","✺","✹","✷"]},star2:{interval:80,frames:["+","x","*"]},flip:{interval:70,frames:["_","_","_","-","`","`","'","´","-","_","_","_"]},hamburger:{interval:100,frames:["☱","☲","☴"]},growVertical:{interval:120,frames:["▁","▃","▄","▅","▆","▇","▆","▅","▄","▃"]},growHorizontal:{interval:120,frames:["▏","▎","▍","▌","▋","▊","▉","▊","▋","▌","▍","▎"]},balloon:{interval:140,frames:[" ",".","o","O","@","*"," "]},balloon2:{interval:120,frames:[".","o","O","°","O","o","."]},noise:{interval:100,frames:["▓","▒","░"]},bounce:{interval:120,frames:["⠁","⠂","⠄","⠂"]},boxBounce:{interval:120,frames:["▖","▘","▝","▗"]},boxBounce2:{interval:100,frames:["▌","▀","▐","▄"]},triangle:{interval:50,frames:["◢","◣","◤","◥"]},arc:{interval:100,frames:["◜","◠","◝","◞","◡","◟"]},circle:{interval:120,frames:["◡","⊙","◠"]},squareCorners:{interval:180,frames:["◰","◳","◲","◱"]},circleQuarters:{interval:120,frames:["◴","◷","◶","◵"]},circleHalves:{interval:50,frames:["◐","◓","◑","◒"]},squish:{interval:100,frames:["╫","╪"]},toggle:{interval:250,frames:["⊶","⊷"]},toggle2:{interval:80,frames:["▫","▪"]},toggle3:{interval:120,frames:["□","■"]},toggle4:{interval:100,frames:["■","□","▪","▫"]},toggle5:{interval:100,frames:["▮","▯"]},toggle6:{interval:300,frames:["ဝ","၀"]},toggle7:{interval:80,frames:["⦾","⦿"]},toggle8:{interval:100,frames:["◍","◌"]},toggle9:{interval:100,frames:["◉","◎"]},toggle10:{interval:100,frames:["㊂","㊀","㊁"]},toggle11:{interval:50,frames:["⧇","⧆"]},toggle12:{interval:120,frames:["☗","☖"]},toggle13:{interval:80,frames:["=","*","-"]},arrow:{interval:100,frames:["←","↖","↑","↗","→","↘","↓","↙"]},arrow2:{interval:80,frames:["⬆️ ","↗️ ","➡️ ","↘️ ","⬇️ ","↙️ ","⬅️ ","↖️ "]},arrow3:{interval:120,frames:["▹▹▹▹▹","▸▹▹▹▹","▹▸▹▹▹","▹▹▸▹▹","▹▹▹▸▹","▹▹▹▹▸"]},bouncingBar:{interval:80,frames:["[ ]","[= ]","[== ]","[=== ]","[ ===]","[ ==]","[ =]","[ ]","[ =]","[ ==]","[ ===]","[====]","[=== ]","[== ]","[= ]"]},bouncingBall:{interval:80,frames:["( ● )","( ● )","( ● )","( ● )","( ●)","( ● )","( ● )","( ● )","( ● )","(● )"]},smiley:{interval:200,frames:["😄 ","😝 "]},monkey:{interval:300,frames:["🙈 ","🙈 ","🙉 ","🙊 "]},hearts:{interval:100,frames:["💛 ","💙 ","💜 ","💚 ","❤️ "]},clock:{interval:100,frames:["🕛 ","🕐 ","🕑 ","🕒 ","🕓 ","🕔 ","🕕 ","🕖 ","🕗 ","🕘 ","🕙 ","🕚 "]},earth:{interval:180,frames:["🌍 ","🌎 ","🌏 "]},material:{interval:17,frames:["█▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","██▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","███▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","████▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","██████▁▁▁▁▁▁▁▁▁▁▁▁▁▁","██████▁▁▁▁▁▁▁▁▁▁▁▁▁▁","███████▁▁▁▁▁▁▁▁▁▁▁▁▁","████████▁▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","██████████▁▁▁▁▁▁▁▁▁▁","███████████▁▁▁▁▁▁▁▁▁","█████████████▁▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁▁██████████████▁▁▁▁","▁▁▁██████████████▁▁▁","▁▁▁▁█████████████▁▁▁","▁▁▁▁██████████████▁▁","▁▁▁▁██████████████▁▁","▁▁▁▁▁██████████████▁","▁▁▁▁▁██████████████▁","▁▁▁▁▁██████████████▁","▁▁▁▁▁▁██████████████","▁▁▁▁▁▁██████████████","▁▁▁▁▁▁▁█████████████","▁▁▁▁▁▁▁█████████████","▁▁▁▁▁▁▁▁████████████","▁▁▁▁▁▁▁▁████████████","▁▁▁▁▁▁▁▁▁███████████","▁▁▁▁▁▁▁▁▁███████████","▁▁▁▁▁▁▁▁▁▁██████████","▁▁▁▁▁▁▁▁▁▁██████████","▁▁▁▁▁▁▁▁▁▁▁▁████████","▁▁▁▁▁▁▁▁▁▁▁▁▁███████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁██████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█████","█▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","██▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","██▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","███▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","████▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","█████▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","█████▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","██████▁▁▁▁▁▁▁▁▁▁▁▁▁█","████████▁▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","███████████▁▁▁▁▁▁▁▁▁","████████████▁▁▁▁▁▁▁▁","████████████▁▁▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁▁▁█████████████▁▁▁▁","▁▁▁▁▁████████████▁▁▁","▁▁▁▁▁████████████▁▁▁","▁▁▁▁▁▁███████████▁▁▁","▁▁▁▁▁▁▁▁█████████▁▁▁","▁▁▁▁▁▁▁▁█████████▁▁▁","▁▁▁▁▁▁▁▁▁█████████▁▁","▁▁▁▁▁▁▁▁▁█████████▁▁","▁▁▁▁▁▁▁▁▁▁█████████▁","▁▁▁▁▁▁▁▁▁▁▁████████▁","▁▁▁▁▁▁▁▁▁▁▁████████▁","▁▁▁▁▁▁▁▁▁▁▁▁███████▁","▁▁▁▁▁▁▁▁▁▁▁▁███████▁","▁▁▁▁▁▁▁▁▁▁▁▁▁███████","▁▁▁▁▁▁▁▁▁▁▁▁▁███████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁"]},moon:{interval:80,frames:["🌑 ","🌒 ","🌓 ","🌔 ","🌕 ","🌖 ","🌗 ","🌘 "]},runner:{interval:140,frames:["🚶 ","🏃 "]},pong:{interval:80,frames:["▐⠂ ▌","▐⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂▌","▐ ⠠▌","▐ ⡀▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐⠠ ▌"]},shark:{interval:120,frames:["▐|\\____________▌","▐_|\\___________▌","▐__|\\__________▌","▐___|\\_________▌","▐____|\\________▌","▐_____|\\_______▌","▐______|\\______▌","▐_______|\\_____▌","▐________|\\____▌","▐_________|\\___▌","▐__________|\\__▌","▐___________|\\_▌","▐____________|\\▌","▐____________/|▌","▐___________/|_▌","▐__________/|__▌","▐_________/|___▌","▐________/|____▌","▐_______/|_____▌","▐______/|______▌","▐_____/|_______▌","▐____/|________▌","▐___/|_________▌","▐__/|__________▌","▐_/|___________▌","▐/|____________▌"]},dqpb:{interval:100,frames:["d","q","p","b"]},weather:{interval:100,frames:["☀️ ","☀️ ","☀️ ","🌤 ","⛅️ ","🌥 ","☁️ ","🌧 ","🌨 ","🌧 ","🌨 ","🌧 ","🌨 ","⛈ ","🌨 ","🌧 ","🌨 ","☁️ ","🌥 ","⛅️ ","🌤 ","☀️ ","☀️ "]},christmas:{interval:400,frames:["🌲","🎄"]},grenade:{interval:80,frames:["، ","′ "," ´ "," ‾ "," ⸌"," ⸊"," |"," ⁎"," ⁕"," ෴ "," ⁓"," "," "," "]},point:{interval:125,frames:["∙∙∙","●∙∙","∙●∙","∙∙●","∙∙∙"]},layer:{interval:150,frames:["-","=","≡"]},betaWave:{interval:80,frames:["ρββββββ","βρβββββ","ββρββββ","βββρβββ","ββββρββ","βββββρβ","ββββββρ"]},fingerDance:{interval:160,frames:["🤘 ","🤟 ","🖖 ","✋ ","🤚 ","👆 "]},fistBump:{interval:80,frames:["🤜 🤛 ","🤜 🤛 ","🤜 🤛 "," 🤜 🤛 "," 🤜🤛 "," 🤜✨🤛 ","🤜 ✨ 🤛 "]},soccerHeader:{interval:80,frames:[" 🧑⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 "]},mindblown:{interval:160,frames:["😐 ","😐 ","😮 ","😮 ","😦 ","😦 ","😧 ","😧 ","🤯 ","💥 ","✨ "," "," "," "]},speaker:{interval:160,frames:["🔈 ","🔉 ","🔊 ","🔉 "]},orangePulse:{interval:100,frames:["🔸 ","🔶 ","🟠 ","🟠 ","🔶 "]},bluePulse:{interval:100,frames:["🔹 ","🔷 ","🔵 ","🔵 ","🔷 "]},orangeBluePulse:{interval:100,frames:["🔸 ","🔶 ","🟠 ","🟠 ","🔶 ","🔹 ","🔷 ","🔵 ","🔵 ","🔷 "]},timeTravel:{interval:100,frames:["🕛 ","🕚 ","🕙 ","🕘 ","🕗 ","🕖 ","🕕 ","🕔 ","🕓 ","🕒 ","🕑 ","🕐 "]},aesthetic:{interval:80,frames:["▰▱▱▱▱▱▱","▰▰▱▱▱▱▱","▰▰▰▱▱▱▱","▰▰▰▰▱▱▱","▰▰▰▰▰▱▱","▰▰▰▰▰▰▱","▰▰▰▰▰▰▰","▰▱▱▱▱▱▱"]}}});var ri=m((xd,ti)=>{"use strict";a();var Ft=Object.assign({},zn()),ei=Object.keys(Ft);Object.defineProperty(Ft,"random",{get(){let e=Math.floor(Math.random()*ei.length),t=ei[e];return Ft[t]}});ti.exports=Ft});var ni=m((Od,Pt)=>{a();var xu=function(){"use strict";function e(s,u,f,p){var l;typeof u=="object"&&(f=u.depth,p=u.prototype,l=u.filter,u=u.circular);var h=[],y=[],d=typeof Buffer<"u";typeof u>"u"&&(u=!0),typeof f>"u"&&(f=1/0);function _(g,v){if(g===null)return null;if(v==0)return g;var w,D;if(typeof g!="object")return g;if(e.__isArray(g))w=[];else if(e.__isRegExp(g))w=new RegExp(g.source,o(g)),g.lastIndex&&(w.lastIndex=g.lastIndex);else if(e.__isDate(g))w=new Date(g.getTime());else{if(d&&Buffer.isBuffer(g))return Buffer.allocUnsafe?w=Buffer.allocUnsafe(g.length):w=new Buffer(g.length),g.copy(w),w;typeof p>"u"?(D=Object.getPrototypeOf(g),w=Object.create(D)):(w=Object.create(p),D=p)}if(u){var le=h.indexOf(g);if(le!=-1)return y[le];h.push(g),y.push(w)}for(var ce in g){var ke;D&&(ke=Object.getOwnPropertyDescriptor(D,ce)),!(ke&&ke.set==null)&&(w[ce]=_(g[ce],v-1))}return w}return _(s,f)}e.clonePrototype=function(u){if(u===null)return null;var f=function(){};return f.prototype=u,new f};function t(s){return Object.prototype.toString.call(s)}e.__objToStr=t;function r(s){return typeof s=="object"&&t(s)==="[object Date]"}e.__isDate=r;function n(s){return typeof s=="object"&&t(s)==="[object Array]"}e.__isArray=n;function i(s){return typeof s=="object"&&t(s)==="[object RegExp]"}e.__isRegExp=i;function o(s){var u="";return s.global&&(u+="g"),s.ignoreCase&&(u+="i"),s.multiline&&(u+="m"),u}return e.__getRegExpFlags=o,e}();typeof Pt=="object"&&Pt.exports&&(Pt.exports=xu)});var oi=m((Cd,ii)=>{a();var vu=ni();ii.exports=function(e,t){return e=e||{},Object.keys(t).forEach(function(r){typeof e[r]>"u"&&(e[r]=vu(t[r]))}),e}});var ai=m((Ad,si)=>{a();si.exports=[[768,879],[1155,1158],[1160,1161],[1425,1469],[1471,1471],[1473,1474],[1476,1477],[1479,1479],[1536,1539],[1552,1557],[1611,1630],[1648,1648],[1750,1764],[1767,1768],[1770,1773],[1807,1807],[1809,1809],[1840,1866],[1958,1968],[2027,2035],[2305,2306],[2364,2364],[2369,2376],[2381,2381],[2385,2388],[2402,2403],[2433,2433],[2492,2492],[2497,2500],[2509,2509],[2530,2531],[2561,2562],[2620,2620],[2625,2626],[2631,2632],[2635,2637],[2672,2673],[2689,2690],[2748,2748],[2753,2757],[2759,2760],[2765,2765],[2786,2787],[2817,2817],[2876,2876],[2879,2879],[2881,2883],[2893,2893],[2902,2902],[2946,2946],[3008,3008],[3021,3021],[3134,3136],[3142,3144],[3146,3149],[3157,3158],[3260,3260],[3263,3263],[3270,3270],[3276,3277],[3298,3299],[3393,3395],[3405,3405],[3530,3530],[3538,3540],[3542,3542],[3633,3633],[3636,3642],[3655,3662],[3761,3761],[3764,3769],[3771,3772],[3784,3789],[3864,3865],[3893,3893],[3895,3895],[3897,3897],[3953,3966],[3968,3972],[3974,3975],[3984,3991],[3993,4028],[4038,4038],[4141,4144],[4146,4146],[4150,4151],[4153,4153],[4184,4185],[4448,4607],[4959,4959],[5906,5908],[5938,5940],[5970,5971],[6002,6003],[6068,6069],[6071,6077],[6086,6086],[6089,6099],[6109,6109],[6155,6157],[6313,6313],[6432,6434],[6439,6440],[6450,6450],[6457,6459],[6679,6680],[6912,6915],[6964,6964],[6966,6970],[6972,6972],[6978,6978],[7019,7027],[7616,7626],[7678,7679],[8203,8207],[8234,8238],[8288,8291],[8298,8303],[8400,8431],[12330,12335],[12441,12442],[43014,43014],[43019,43019],[43045,43046],[64286,64286],[65024,65039],[65056,65059],[65279,65279],[65529,65531],[68097,68099],[68101,68102],[68108,68111],[68152,68154],[68159,68159],[119143,119145],[119155,119170],[119173,119179],[119210,119213],[119362,119364],[917505,917505],[917536,917631],[917760,917999]]});var ci=m((Dd,Rr)=>{"use strict";a();var wu=oi(),tt=ai(),fi={nul:0,control:0};Rr.exports=function(t){return li(t,fi)};Rr.exports.config=function(e){return e=wu(e||{},fi),function(r){return li(r,e)}};function li(e,t){if(typeof e!="string")return ui(e,t);for(var r=0,n=0;n<e.length;n++){var i=ui(e.charCodeAt(n),t);if(i<0)return-1;r+=i}return r}function ui(e,t){return e===0?t.nul:e<32||e>=127&&e<160?t.control:Su(e)?0:1+(e>=4352&&(e<=4447||e==9001||e==9002||e>=11904&&e<=42191&&e!=12351||e>=44032&&e<=55203||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65135||e>=65280&&e<=65376||e>=65504&&e<=65510||e>=131072&&e<=196605||e>=196608&&e<=262141))}function Su(e){var t=0,r=tt.length-1,n;if(e<tt[0][0]||e>tt[r][1])return!1;for(;r>=t;)if(n=Math.floor((t+r)/2),e>tt[n][1])t=n+1;else if(e<tt[n][0])r=n-1;else return!0;return!1}});var Or=m((Pd,hi)=>{a();hi.exports=E("stream")});var mi=m((Nd,yi)=>{"use strict";a();function di(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Eu(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?di(Object(r),!0).forEach(function(n){bu(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):di(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function bu(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ru(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function pi(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function Tu(e,t,r){return t&&pi(e.prototype,t),r&&pi(e,r),e}var Ou=E("buffer"),Nt=Ou.Buffer,Cu=E("util"),Cr=Cu.inspect,Au=Cr&&Cr.custom||"inspect";function Du(e,t,r){Nt.prototype.copy.call(e,t,r)}yi.exports=function(){function e(){Ru(this,e),this.head=null,this.tail=null,this.length=0}return Tu(e,[{key:"push",value:function(r){var n={data:r,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length}},{key:"unshift",value:function(r){var n={data:r,next:this.head};this.length===0&&(this.tail=n),this.head=n,++this.length}},{key:"shift",value:function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var n=this.head,i=""+n.data;n=n.next;)i+=r+n.data;return i}},{key:"concat",value:function(r){if(this.length===0)return Nt.alloc(0);for(var n=Nt.allocUnsafe(r>>>0),i=this.head,o=0;i;)Du(i.data,n,o),o+=i.data.length,i=i.next;return n}},{key:"consume",value:function(r,n){var i;return r<this.head.data.length?(i=this.head.data.slice(0,r),this.head.data=this.head.data.slice(r)):r===this.head.data.length?i=this.shift():i=n?this._getString(r):this._getBuffer(r),i}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(r){var n=this.head,i=1,o=n.data;for(r-=o.length;n=n.next;){var s=n.data,u=r>s.length?s.length:r;if(u===s.length?o+=s:o+=s.slice(0,r),r-=u,r===0){u===s.length?(++i,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=s.slice(u));break}++i}return this.length-=i,o}},{key:"_getBuffer",value:function(r){var n=Nt.allocUnsafe(r),i=this.head,o=1;for(i.data.copy(n),r-=i.data.length;i=i.next;){var s=i.data,u=r>s.length?s.length:r;if(s.copy(n,n.length-r,0,u),r-=u,r===0){u===s.length?(++o,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=s.slice(u));break}++o}return this.length-=o,n}},{key:Au,value:function(r,n){return Cr(this,Eu({},n,{depth:0,customInspect:!1}))}}]),e}()});var Dr=m((kd,gi)=>{"use strict";a();function Fu(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(Ar,this,e)):process.nextTick(Ar,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(o){!t&&o?r._writableState?r._writableState.errorEmitted?process.nextTick(kt,r):(r._writableState.errorEmitted=!0,process.nextTick(_i,r,o)):process.nextTick(_i,r,o):t?(process.nextTick(kt,r),t(o)):process.nextTick(kt,r)}),this)}function _i(e,t){Ar(e,t),kt(e)}function kt(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function Pu(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function Ar(e,t){e.emit("error",t)}function Nu(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}gi.exports={destroy:Fu,undestroy:Pu,errorOrDestroy:Nu}});var he=m((Bd,wi)=>{"use strict";a();var vi={};function ee(e,t,r){r||(r=Error);function n(o,s,u){return typeof t=="string"?t:t(o,s,u)}class i extends r{constructor(s,u,f){super(n(s,u,f))}}i.prototype.name=r.name,i.prototype.code=e,vi[e]=i}function xi(e,t){if(Array.isArray(e)){let r=e.length;return e=e.map(n=>String(n)),r>2?`one of ${t} ${e.slice(0,r-1).join(", ")}, or `+e[r-1]:r===2?`one of ${t} ${e[0]} or ${e[1]}`:`of ${t} ${e[0]}`}else return`of ${t} ${String(e)}`}function ku(e,t,r){return e.substr(!r||r<0?0:+r,t.length)===t}function Bu(e,t,r){return(r===void 0||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}function qu(e,t,r){return typeof r!="number"&&(r=0),r+t.length>e.length?!1:e.indexOf(t,r)!==-1}ee("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError);ee("ERR_INVALID_ARG_TYPE",function(e,t,r){let n;typeof t=="string"&&ku(t,"not ")?(n="must not be",t=t.replace(/^not /,"")):n="must be";let i;if(Bu(e," argument"))i=`The ${e} ${n} ${xi(t,"type")}`;else{let o=qu(e,".")?"property":"argument";i=`The "${e}" ${o} ${n} ${xi(t,"type")}`}return i+=`. Received type ${typeof r}`,i},TypeError);ee("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");ee("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"});ee("ERR_STREAM_PREMATURE_CLOSE","Premature close");ee("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"});ee("ERR_MULTIPLE_CALLBACK","Callback called multiple times");ee("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");ee("ERR_STREAM_WRITE_AFTER_END","write after end");ee("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);ee("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError);ee("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");wi.exports.codes=vi});var Fr=m((qd,Si)=>{"use strict";a();var Iu=he().codes.ERR_INVALID_OPT_VALUE;function Mu(e,t,r){return e.highWaterMark!=null?e.highWaterMark:t?e[r]:null}function Lu(e,t,r,n){var i=Mu(t,n,r);if(i!=null){if(!(isFinite(i)&&Math.floor(i)===i)||i<0){var o=n?r:"highWaterMark";throw new Iu(o,i)}return Math.floor(i)}return e.objectMode?16:16*1024}Si.exports={getHighWaterMark:Lu}});var Ei=m((Id,Pr)=>{a();typeof Object.create=="function"?Pr.exports=function(t,r){r&&(t.super_=r,t.prototype=Object.create(r.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:Pr.exports=function(t,r){if(r){t.super_=r;var n=function(){};n.prototype=r.prototype,t.prototype=new n,t.prototype.constructor=t}}});var Re=m((Md,kr)=>{a();try{if(Nr=E("util"),typeof Nr.inherits!="function")throw"";kr.exports=Nr.inherits}catch{kr.exports=Ei()}var Nr});var Ri=m((Ld,bi)=>{a();bi.exports=E("util").deprecate});var Ir=m((jd,Fi)=>{"use strict";a();Fi.exports=N;function Oi(e){var t=this;this.next=null,this.entry=null,this.finish=function(){df(t,e)}}var We;N.WritableState=nt;var ju={deprecate:Ri()},Ci=Or(),qt=E("buffer").Buffer,Uu=global.Uint8Array||function(){};function Wu(e){return qt.from(e)}function $u(e){return qt.isBuffer(e)||e instanceof Uu}var qr=Dr(),Gu=Fr(),Yu=Gu.getHighWaterMark,de=he().codes,Hu=de.ERR_INVALID_ARG_TYPE,Vu=de.ERR_METHOD_NOT_IMPLEMENTED,Ju=de.ERR_MULTIPLE_CALLBACK,Ku=de.ERR_STREAM_CANNOT_PIPE,Xu=de.ERR_STREAM_DESTROYED,Qu=de.ERR_STREAM_NULL_VALUES,Zu=de.ERR_STREAM_WRITE_AFTER_END,zu=de.ERR_UNKNOWN_ENCODING,$e=qr.errorOrDestroy;Re()(N,Ci);function ef(){}function nt(e,t,r){We=We||Te(),e=e||{},typeof r!="boolean"&&(r=t instanceof We),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=Yu(this,e,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var n=e.decodeStrings===!1;this.decodeStrings=!n,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(i){uf(t,i)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=e.emitClose!==!1,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new Oi(this)}nt.prototype.getBuffer=function(){for(var t=this.bufferedRequest,r=[];t;)r.push(t),t=t.next;return r};(function(){try{Object.defineProperty(nt.prototype,"buffer",{get:ju.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var Bt;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(Bt=Function.prototype[Symbol.hasInstance],Object.defineProperty(N,Symbol.hasInstance,{value:function(t){return Bt.call(this,t)?!0:this!==N?!1:t&&t._writableState instanceof nt}})):Bt=function(t){return t instanceof this};function N(e){We=We||Te();var t=this instanceof We;if(!t&&!Bt.call(N,this))return new N(e);this._writableState=new nt(e,this,t),this.writable=!0,e&&(typeof e.write=="function"&&(this._write=e.write),typeof e.writev=="function"&&(this._writev=e.writev),typeof e.destroy=="function"&&(this._destroy=e.destroy),typeof e.final=="function"&&(this._final=e.final)),Ci.call(this)}N.prototype.pipe=function(){$e(this,new Ku)};function tf(e,t){var r=new Zu;$e(e,r),process.nextTick(t,r)}function rf(e,t,r,n){var i;return r===null?i=new Qu:typeof r!="string"&&!t.objectMode&&(i=new Hu("chunk",["string","Buffer"],r)),i?($e(e,i),process.nextTick(n,i),!1):!0}N.prototype.write=function(e,t,r){var n=this._writableState,i=!1,o=!n.objectMode&&$u(e);return o&&!qt.isBuffer(e)&&(e=Wu(e)),typeof t=="function"&&(r=t,t=null),o?t="buffer":t||(t=n.defaultEncoding),typeof r!="function"&&(r=ef),n.ending?tf(this,r):(o||rf(this,n,e,r))&&(n.pendingcb++,i=of(this,n,o,e,t,r)),i};N.prototype.cork=function(){this._writableState.corked++};N.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest&&Ai(this,e))};N.prototype.setDefaultEncoding=function(t){if(typeof t=="string"&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new zu(t);return this._writableState.defaultEncoding=t,this};Object.defineProperty(N.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function nf(e,t,r){return!e.objectMode&&e.decodeStrings!==!1&&typeof t=="string"&&(t=qt.from(t,r)),t}Object.defineProperty(N.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function of(e,t,r,n,i,o){if(!r){var s=nf(t,n,i);n!==s&&(r=!0,i="buffer",n=s)}var u=t.objectMode?1:n.length;t.length+=u;var f=t.length<t.highWaterMark;if(f||(t.needDrain=!0),t.writing||t.corked){var p=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:o,next:null},p?p.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else Br(e,t,!1,u,n,i,o);return f}function Br(e,t,r,n,i,o,s){t.writelen=n,t.writecb=s,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new Xu("write")):r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function sf(e,t,r,n,i){--t.pendingcb,r?(process.nextTick(i,n),process.nextTick(rt,e,t),e._writableState.errorEmitted=!0,$e(e,n)):(i(n),e._writableState.errorEmitted=!0,$e(e,n),rt(e,t))}function af(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function uf(e,t){var r=e._writableState,n=r.sync,i=r.writecb;if(typeof i!="function")throw new Ju;if(af(r),t)sf(e,r,n,t,i);else{var o=Di(r)||e.destroyed;!o&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&Ai(e,r),n?process.nextTick(Ti,e,r,o,i):Ti(e,r,o,i)}}function Ti(e,t,r,n){r||ff(e,t),t.pendingcb--,n(),rt(e,t)}function ff(e,t){t.length===0&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function Ai(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),o=t.corkedRequestsFree;o.entry=r;for(var s=0,u=!0;r;)i[s]=r,r.isBuf||(u=!1),r=r.next,s+=1;i.allBuffers=u,Br(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new Oi(t),t.bufferedRequestCount=0}else{for(;r;){var f=r.chunk,p=r.encoding,l=r.callback,h=t.objectMode?1:f.length;if(Br(e,t,!1,h,f,p,l),r=r.next,t.bufferedRequestCount--,t.writing)break}r===null&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}N.prototype._write=function(e,t,r){r(new Vu("_write()"))};N.prototype._writev=null;N.prototype.end=function(e,t,r){var n=this._writableState;return typeof e=="function"?(r=e,e=null,t=null):typeof t=="function"&&(r=t,t=null),e!=null&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||hf(this,n,r),this};Object.defineProperty(N.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function Di(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}function lf(e,t){e._final(function(r){t.pendingcb--,r&&$e(e,r),t.prefinished=!0,e.emit("prefinish"),rt(e,t)})}function cf(e,t){!t.prefinished&&!t.finalCalled&&(typeof e._final=="function"&&!t.destroyed?(t.pendingcb++,t.finalCalled=!0,process.nextTick(lf,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function rt(e,t){var r=Di(t);if(r&&(cf(e,t),t.pendingcb===0&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var n=e._readableState;(!n||n.autoDestroy&&n.endEmitted)&&e.destroy()}return r}function hf(e,t,r){t.ending=!0,rt(e,t),r&&(t.finished?process.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}function df(e,t,r){var n=e.entry;for(e.entry=null;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree.next=e}Object.defineProperty(N.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(t){!this._writableState||(this._writableState.destroyed=t)}});N.prototype.destroy=qr.destroy;N.prototype._undestroy=qr.undestroy;N.prototype._destroy=function(e,t){t(e)}});var Te=m((Ud,Ni)=>{"use strict";a();var pf=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};Ni.exports=ae;var Pi=jr(),Lr=Ir();Re()(ae,Pi);for(Mr=pf(Lr.prototype),It=0;It<Mr.length;It++)Mt=Mr[It],ae.prototype[Mt]||(ae.prototype[Mt]=Lr.prototype[Mt]);var Mr,Mt,It;function ae(e){if(!(this instanceof ae))return new ae(e);Pi.call(this,e),Lr.call(this,e),this.allowHalfOpen=!0,e&&(e.readable===!1&&(this.readable=!1),e.writable===!1&&(this.writable=!1),e.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",yf)))}Object.defineProperty(ae.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});Object.defineProperty(ae.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(ae.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function yf(){this._writableState.ended||process.nextTick(mf,this)}function mf(e){e.end()}Object.defineProperty(ae.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(t){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=t,this._writableState.destroyed=t)}})});var qi=m((Ur,Bi)=>{a();var Lt=E("buffer"),ue=Lt.Buffer;function ki(e,t){for(var r in e)t[r]=e[r]}ue.from&&ue.alloc&&ue.allocUnsafe&&ue.allocUnsafeSlow?Bi.exports=Lt:(ki(Lt,Ur),Ur.Buffer=Oe);function Oe(e,t,r){return ue(e,t,r)}Oe.prototype=Object.create(ue.prototype);ki(ue,Oe);Oe.from=function(e,t,r){if(typeof e=="number")throw new TypeError("Argument must not be a number");return ue(e,t,r)};Oe.alloc=function(e,t,r){if(typeof e!="number")throw new TypeError("Argument must be a number");var n=ue(e);return t!==void 0?typeof r=="string"?n.fill(t,r):n.fill(t):n.fill(0),n};Oe.allocUnsafe=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return ue(e)};Oe.allocUnsafeSlow=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return Lt.SlowBuffer(e)}});var Gr=m(Mi=>{"use strict";a();var $r=qi().Buffer,Ii=$r.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function _f(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function gf(e){var t=_f(e);if(typeof t!="string"&&($r.isEncoding===Ii||!Ii(e)))throw new Error("Unknown encoding: "+e);return t||e}Mi.StringDecoder=it;function it(e){this.encoding=gf(e);var t;switch(this.encoding){case"utf16le":this.text=bf,this.end=Rf,t=4;break;case"utf8":this.fillLast=wf,t=4;break;case"base64":this.text=Tf,this.end=Of,t=3;break;default:this.write=Cf,this.end=Af;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=$r.allocUnsafe(t)}it.prototype.write=function(e){if(e.length===0)return"";var t,r;if(this.lastNeed){if(t=this.fillLast(e),t===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""};it.prototype.end=Ef;it.prototype.text=Sf;it.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length};function Wr(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function xf(e,t,r){var n=t.length-1;if(n<r)return 0;var i=Wr(t[n]);return i>=0?(i>0&&(e.lastNeed=i-1),i):--n<r||i===-2?0:(i=Wr(t[n]),i>=0?(i>0&&(e.lastNeed=i-2),i):--n<r||i===-2?0:(i=Wr(t[n]),i>=0?(i>0&&(i===2?i=0:e.lastNeed=i-3),i):0))}function vf(e,t,r){if((t[0]&192)!==128)return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128)return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&(t[2]&192)!==128)return e.lastNeed=2,"�"}}function wf(e){var t=this.lastTotal-this.lastNeed,r=vf(this,e,t);if(r!==void 0)return r;if(this.lastNeed<=e.length)return e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length}function Sf(e,t){var r=xf(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}function Ef(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t}function bf(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function Rf(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function Tf(e,t){var r=(e.length-t)%3;return r===0?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function Of(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function Cf(e){return e.toString(this.encoding)}function Af(e){return e&&e.length?this.write(e):""}});var jt=m(($d,Ui)=>{"use strict";a();var Li=he().codes.ERR_STREAM_PREMATURE_CLOSE;function Df(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];e.apply(this,n)}}}function Ff(){}function Pf(e){return e.setHeader&&typeof e.abort=="function"}function ji(e,t,r){if(typeof t=="function")return ji(e,null,t);t||(t={}),r=Df(r||Ff);var n=t.readable||t.readable!==!1&&e.readable,i=t.writable||t.writable!==!1&&e.writable,o=function(){e.writable||u()},s=e._writableState&&e._writableState.finished,u=function(){i=!1,s=!0,n||r.call(e)},f=e._readableState&&e._readableState.endEmitted,p=function(){n=!1,f=!0,i||r.call(e)},l=function(_){r.call(e,_)},h=function(){var _;if(n&&!f)return(!e._readableState||!e._readableState.ended)&&(_=new Li),r.call(e,_);if(i&&!s)return(!e._writableState||!e._writableState.ended)&&(_=new Li),r.call(e,_)},y=function(){e.req.on("finish",u)};return Pf(e)?(e.on("complete",u),e.on("abort",h),e.req?y():e.on("request",y)):i&&!e._writableState&&(e.on("end",o),e.on("close",o)),e.on("end",p),e.on("finish",u),t.error!==!1&&e.on("error",l),e.on("close",h),function(){e.removeListener("complete",u),e.removeListener("abort",h),e.removeListener("request",y),e.req&&e.req.removeListener("finish",u),e.removeListener("end",o),e.removeListener("close",o),e.removeListener("finish",u),e.removeListener("end",p),e.removeListener("error",l),e.removeListener("close",h)}}Ui.exports=ji});var $i=m((Gd,Wi)=>{"use strict";a();var Ut;function pe(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Nf=jt(),ye=Symbol("lastResolve"),Ce=Symbol("lastReject"),ot=Symbol("error"),Wt=Symbol("ended"),Ae=Symbol("lastPromise"),Yr=Symbol("handlePromise"),De=Symbol("stream");function me(e,t){return{value:e,done:t}}function kf(e){var t=e[ye];if(t!==null){var r=e[De].read();r!==null&&(e[Ae]=null,e[ye]=null,e[Ce]=null,t(me(r,!1)))}}function Bf(e){process.nextTick(kf,e)}function qf(e,t){return function(r,n){e.then(function(){if(t[Wt]){r(me(void 0,!0));return}t[Yr](r,n)},n)}}var If=Object.getPrototypeOf(function(){}),Mf=Object.setPrototypeOf((Ut={get stream(){return this[De]},next:function(){var t=this,r=this[ot];if(r!==null)return Promise.reject(r);if(this[Wt])return Promise.resolve(me(void 0,!0));if(this[De].destroyed)return new Promise(function(s,u){process.nextTick(function(){t[ot]?u(t[ot]):s(me(void 0,!0))})});var n=this[Ae],i;if(n)i=new Promise(qf(n,this));else{var o=this[De].read();if(o!==null)return Promise.resolve(me(o,!1));i=new Promise(this[Yr])}return this[Ae]=i,i}},pe(Ut,Symbol.asyncIterator,function(){return this}),pe(Ut,"return",function(){var t=this;return new Promise(function(r,n){t[De].destroy(null,function(i){if(i){n(i);return}r(me(void 0,!0))})})}),Ut),If),Lf=function(t){var r,n=Object.create(Mf,(r={},pe(r,De,{value:t,writable:!0}),pe(r,ye,{value:null,writable:!0}),pe(r,Ce,{value:null,writable:!0}),pe(r,ot,{value:null,writable:!0}),pe(r,Wt,{value:t._readableState.endEmitted,writable:!0}),pe(r,Yr,{value:function(o,s){var u=n[De].read();u?(n[Ae]=null,n[ye]=null,n[Ce]=null,o(me(u,!1))):(n[ye]=o,n[Ce]=s)},writable:!0}),r));return n[Ae]=null,Nf(t,function(i){if(i&&i.code!=="ERR_STREAM_PREMATURE_CLOSE"){var o=n[Ce];o!==null&&(n[Ae]=null,n[ye]=null,n[Ce]=null,o(i)),n[ot]=i;return}var s=n[ye];s!==null&&(n[Ae]=null,n[ye]=null,n[Ce]=null,s(me(void 0,!0))),n[Wt]=!0}),t.on("readable",Bf.bind(null,n)),n};Wi.exports=Lf});var Vi=m((Yd,Hi)=>{"use strict";a();function Gi(e,t,r,n,i,o,s){try{var u=e[o](s),f=u.value}catch(p){r(p);return}u.done?t(f):Promise.resolve(f).then(n,i)}function jf(e){return function(){var t=this,r=arguments;return new Promise(function(n,i){var o=e.apply(t,r);function s(f){Gi(o,n,i,s,u,"next",f)}function u(f){Gi(o,n,i,s,u,"throw",f)}s(void 0)})}}function Yi(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Uf(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Yi(Object(r),!0).forEach(function(n){Wf(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Yi(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Wf(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var $f=he().codes.ERR_INVALID_ARG_TYPE;function Gf(e,t,r){var n;if(t&&typeof t.next=="function")n=t;else if(t&&t[Symbol.asyncIterator])n=t[Symbol.asyncIterator]();else if(t&&t[Symbol.iterator])n=t[Symbol.iterator]();else throw new $f("iterable",["Iterable"],t);var i=new e(Uf({objectMode:!0},r)),o=!1;i._read=function(){o||(o=!0,s())};function s(){return u.apply(this,arguments)}function u(){return u=jf(function*(){try{var f=yield n.next(),p=f.value,l=f.done;l?i.push(null):i.push(yield p)?s():o=!1}catch(h){i.destroy(h)}}),u.apply(this,arguments)}return i}Hi.exports=Gf});var jr=m((Vd,no)=>{"use strict";a();no.exports=b;var Ge;b.ReadableState=Qi;var Hd=E("events").EventEmitter,Xi=function(t,r){return t.listeners(r).length},at=Or(),$t=E("buffer").Buffer,Yf=global.Uint8Array||function(){};function Hf(e){return $t.from(e)}function Vf(e){return $t.isBuffer(e)||e instanceof Yf}var Hr=E("util"),S;Hr&&Hr.debuglog?S=Hr.debuglog("stream"):S=function(){};var Jf=mi(),zr=Dr(),Kf=Fr(),Xf=Kf.getHighWaterMark,Gt=he().codes,Qf=Gt.ERR_INVALID_ARG_TYPE,Zf=Gt.ERR_STREAM_PUSH_AFTER_EOF,zf=Gt.ERR_METHOD_NOT_IMPLEMENTED,el=Gt.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,Ye,Vr,Jr;Re()(b,at);var st=zr.errorOrDestroy,Kr=["error","close","destroy","pause","resume"];function tl(e,t,r){if(typeof e.prependListener=="function")return e.prependListener(t,r);!e._events||!e._events[t]?e.on(t,r):Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]}function Qi(e,t,r){Ge=Ge||Te(),e=e||{},typeof r!="boolean"&&(r=t instanceof Ge),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=Xf(this,e,"readableHighWaterMark",r),this.buffer=new Jf,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=e.emitClose!==!1,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(Ye||(Ye=Gr().StringDecoder),this.decoder=new Ye(e.encoding),this.encoding=e.encoding)}function b(e){if(Ge=Ge||Te(),!(this instanceof b))return new b(e);var t=this instanceof Ge;this._readableState=new Qi(e,this,t),this.readable=!0,e&&(typeof e.read=="function"&&(this._read=e.read),typeof e.destroy=="function"&&(this._destroy=e.destroy)),at.call(this)}Object.defineProperty(b.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(t){!this._readableState||(this._readableState.destroyed=t)}});b.prototype.destroy=zr.destroy;b.prototype._undestroy=zr.undestroy;b.prototype._destroy=function(e,t){t(e)};b.prototype.push=function(e,t){var r=this._readableState,n;return r.objectMode?n=!0:typeof e=="string"&&(t=t||r.defaultEncoding,t!==r.encoding&&(e=$t.from(e,t),t=""),n=!0),Zi(this,e,t,!1,n)};b.prototype.unshift=function(e){return Zi(this,e,null,!0,!1)};function Zi(e,t,r,n,i){S("readableAddChunk",t);var o=e._readableState;if(t===null)o.reading=!1,il(e,o);else{var s;if(i||(s=rl(o,t)),s)st(e,s);else if(o.objectMode||t&&t.length>0)if(typeof t!="string"&&!o.objectMode&&Object.getPrototypeOf(t)!==$t.prototype&&(t=Hf(t)),n)o.endEmitted?st(e,new el):Xr(e,o,t,!0);else if(o.ended)st(e,new Zf);else{if(o.destroyed)return!1;o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||t.length!==0?Xr(e,o,t,!1):Zr(e,o)):Xr(e,o,t,!1)}else n||(o.reading=!1,Zr(e,o))}return!o.ended&&(o.length<o.highWaterMark||o.length===0)}function Xr(e,t,r,n){t.flowing&&t.length===0&&!t.sync?(t.awaitDrain=0,e.emit("data",r)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&Yt(e)),Zr(e,t)}function rl(e,t){var r;return!Vf(t)&&typeof t!="string"&&t!==void 0&&!e.objectMode&&(r=new Qf("chunk",["string","Buffer","Uint8Array"],t)),r}b.prototype.isPaused=function(){return this._readableState.flowing===!1};b.prototype.setEncoding=function(e){Ye||(Ye=Gr().StringDecoder);var t=new Ye(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,n="";r!==null;)n+=t.write(r.data),r=r.next;return this._readableState.buffer.clear(),n!==""&&this._readableState.buffer.push(n),this._readableState.length=n.length,this};var Ji=1073741824;function nl(e){return e>=Ji?e=Ji:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function Ki(e,t){return e<=0||t.length===0&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=nl(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}b.prototype.read=function(e){S("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(e!==0&&(t.emittedReadable=!1),e===0&&t.needReadable&&((t.highWaterMark!==0?t.length>=t.highWaterMark:t.length>0)||t.ended))return S("read: emitReadable",t.length,t.ended),t.length===0&&t.ended?Qr(this):Yt(this),null;if(e=Ki(e,t),e===0&&t.ended)return t.length===0&&Qr(this),null;var n=t.needReadable;S("need readable",n),(t.length===0||t.length-e<t.highWaterMark)&&(n=!0,S("length less than watermark",n)),t.ended||t.reading?(n=!1,S("reading or ended",n)):n&&(S("do read"),t.reading=!0,t.sync=!0,t.length===0&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=Ki(r,t)));var i;return e>0?i=to(e,t):i=null,i===null?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),t.length===0&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&Qr(this)),i!==null&&this.emit("data",i),i};function il(e,t){if(S("onEofChunk"),!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?Yt(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,zi(e)))}}function Yt(e){var t=e._readableState;S("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(S("emitReadable",t.flowing),t.emittedReadable=!0,process.nextTick(zi,e))}function zi(e){var t=e._readableState;S("emitReadable_",t.destroyed,t.length,t.ended),!t.destroyed&&(t.length||t.ended)&&(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,en(e)}function Zr(e,t){t.readingMore||(t.readingMore=!0,process.nextTick(ol,e,t))}function ol(e,t){for(;!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&t.length===0);){var r=t.length;if(S("maybeReadMore read 0"),e.read(0),r===t.length)break}t.readingMore=!1}b.prototype._read=function(e){st(this,new zf("_read()"))};b.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e);break}n.pipesCount+=1,S("pipe count=%d opts=%j",n.pipesCount,t);var i=(!t||t.end!==!1)&&e!==process.stdout&&e!==process.stderr,o=i?u:g;n.endEmitted?process.nextTick(o):r.once("end",o),e.on("unpipe",s);function s(v,w){S("onunpipe"),v===r&&w&&w.hasUnpiped===!1&&(w.hasUnpiped=!0,l())}function u(){S("onend"),e.end()}var f=sl(r);e.on("drain",f);var p=!1;function l(){S("cleanup"),e.removeListener("close",d),e.removeListener("finish",_),e.removeListener("drain",f),e.removeListener("error",y),e.removeListener("unpipe",s),r.removeListener("end",u),r.removeListener("end",g),r.removeListener("data",h),p=!0,n.awaitDrain&&(!e._writableState||e._writableState.needDrain)&&f()}r.on("data",h);function h(v){S("ondata");var w=e.write(v);S("dest.write",w),w===!1&&((n.pipesCount===1&&n.pipes===e||n.pipesCount>1&&ro(n.pipes,e)!==-1)&&!p&&(S("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function y(v){S("onerror",v),g(),e.removeListener("error",y),Xi(e,"error")===0&&st(e,v)}tl(e,"error",y);function d(){e.removeListener("finish",_),g()}e.once("close",d);function _(){S("onfinish"),e.removeListener("close",d),g()}e.once("finish",_);function g(){S("unpipe"),r.unpipe(e)}return e.emit("pipe",r),n.flowing||(S("pipe resume"),r.resume()),e};function sl(e){return function(){var r=e._readableState;S("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,r.awaitDrain===0&&Xi(e,"data")&&(r.flowing=!0,en(e))}}b.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(t.pipesCount===0)return this;if(t.pipesCount===1)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r),this);if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=ro(t.pipes,e);return s===-1?this:(t.pipes.splice(s,1),t.pipesCount-=1,t.pipesCount===1&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r),this)};b.prototype.on=function(e,t){var r=at.prototype.on.call(this,e,t),n=this._readableState;return e==="data"?(n.readableListening=this.listenerCount("readable")>0,n.flowing!==!1&&this.resume()):e==="readable"&&!n.endEmitted&&!n.readableListening&&(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,S("on readable",n.length,n.reading),n.length?Yt(this):n.reading||process.nextTick(al,this)),r};b.prototype.addListener=b.prototype.on;b.prototype.removeListener=function(e,t){var r=at.prototype.removeListener.call(this,e,t);return e==="readable"&&process.nextTick(eo,this),r};b.prototype.removeAllListeners=function(e){var t=at.prototype.removeAllListeners.apply(this,arguments);return(e==="readable"||e===void 0)&&process.nextTick(eo,this),t};function eo(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function al(e){S("readable nexttick read 0"),e.read(0)}b.prototype.resume=function(){var e=this._readableState;return e.flowing||(S("resume"),e.flowing=!e.readableListening,ul(this,e)),e.paused=!1,this};function ul(e,t){t.resumeScheduled||(t.resumeScheduled=!0,process.nextTick(fl,e,t))}function fl(e,t){S("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),en(e),t.flowing&&!t.reading&&e.read(0)}b.prototype.pause=function(){return S("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(S("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function en(e){var t=e._readableState;for(S("flow",t.flowing);t.flowing&&e.read()!==null;);}b.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;e.on("end",function(){if(S("wrapped end"),r.decoder&&!r.ended){var s=r.decoder.end();s&&s.length&&t.push(s)}t.push(null)}),e.on("data",function(s){if(S("wrapped data"),r.decoder&&(s=r.decoder.write(s)),!(r.objectMode&&s==null)&&!(!r.objectMode&&(!s||!s.length))){var u=t.push(s);u||(n=!0,e.pause())}});for(var i in e)this[i]===void 0&&typeof e[i]=="function"&&(this[i]=function(u){return function(){return e[u].apply(e,arguments)}}(i));for(var o=0;o<Kr.length;o++)e.on(Kr[o],this.emit.bind(this,Kr[o]));return this._read=function(s){S("wrapped _read",s),n&&(n=!1,e.resume())},this};typeof Symbol=="function"&&(b.prototype[Symbol.asyncIterator]=function(){return Vr===void 0&&(Vr=$i()),Vr(this)});Object.defineProperty(b.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Object.defineProperty(b.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(b.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}});b._fromList=to;Object.defineProperty(b.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function to(e,t){if(t.length===0)return null;var r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(t.decoder?r=t.buffer.join(""):t.buffer.length===1?r=t.buffer.first():r=t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r}function Qr(e){var t=e._readableState;S("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,process.nextTick(ll,t,e))}function ll(e,t){if(S("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&e.length===0&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}typeof Symbol=="function"&&(b.from=function(e,t){return Jr===void 0&&(Jr=Vi()),Jr(b,e,t)});function ro(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}});var tn=m((Jd,oo)=>{"use strict";a();oo.exports=fe;var Ht=he().codes,cl=Ht.ERR_METHOD_NOT_IMPLEMENTED,hl=Ht.ERR_MULTIPLE_CALLBACK,dl=Ht.ERR_TRANSFORM_ALREADY_TRANSFORMING,pl=Ht.ERR_TRANSFORM_WITH_LENGTH_0,Vt=Te();Re()(fe,Vt);function yl(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(n===null)return this.emit("error",new hl);r.writechunk=null,r.writecb=null,t!=null&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function fe(e){if(!(this instanceof fe))return new fe(e);Vt.call(this,e),this._transformState={afterTransform:yl.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&(typeof e.transform=="function"&&(this._transform=e.transform),typeof e.flush=="function"&&(this._flush=e.flush)),this.on("prefinish",ml)}function ml(){var e=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(t,r){io(e,t,r)}):io(this,null,null)}fe.prototype.push=function(e,t){return this._transformState.needTransform=!1,Vt.prototype.push.call(this,e,t)};fe.prototype._transform=function(e,t,r){r(new cl("_transform()"))};fe.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}};fe.prototype._read=function(e){var t=this._transformState;t.writechunk!==null&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0};fe.prototype._destroy=function(e,t){Vt.prototype._destroy.call(this,e,function(r){t(r)})};function io(e,t,r){if(t)return e.emit("error",t);if(r!=null&&e.push(r),e._writableState.length)throw new pl;if(e._transformState.transforming)throw new dl;return e.push(null)}});var uo=m((Kd,ao)=>{"use strict";a();ao.exports=ut;var so=tn();Re()(ut,so);function ut(e){if(!(this instanceof ut))return new ut(e);so.call(this,e)}ut.prototype._transform=function(e,t,r){r(null,e)}});var po=m((Xd,ho)=>{"use strict";a();var rn;function _l(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}var co=he().codes,gl=co.ERR_MISSING_ARGS,xl=co.ERR_STREAM_DESTROYED;function fo(e){if(e)throw e}function vl(e){return e.setHeader&&typeof e.abort=="function"}function wl(e,t,r,n){n=_l(n);var i=!1;e.on("close",function(){i=!0}),rn===void 0&&(rn=jt()),rn(e,{readable:t,writable:r},function(s){if(s)return n(s);i=!0,n()});var o=!1;return function(s){if(!i&&!o){if(o=!0,vl(e))return e.abort();if(typeof e.destroy=="function")return e.destroy();n(s||new xl("pipe"))}}}function lo(e){e()}function Sl(e,t){return e.pipe(t)}function El(e){return!e.length||typeof e[e.length-1]!="function"?fo:e.pop()}function bl(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];var n=El(t);if(Array.isArray(t[0])&&(t=t[0]),t.length<2)throw new gl("streams");var i,o=t.map(function(s,u){var f=u<t.length-1,p=u>0;return wl(s,f,p,function(l){i||(i=l),l&&o.forEach(lo),!f&&(o.forEach(lo),n(i))})});return t.reduce(Sl)}ho.exports=bl});var yo=m((te,lt)=>{a();var ft=E("stream");process.env.READABLE_STREAM==="disable"&&ft?(lt.exports=ft.Readable,Object.assign(lt.exports,ft),lt.exports.Stream=ft):(te=lt.exports=jr(),te.Stream=ft||te,te.Readable=te,te.Writable=Ir(),te.Duplex=Te(),te.Transform=tn(),te.PassThrough=uo(),te.finished=jt(),te.pipeline=po())});var go=m((Qd,_o)=>{"use strict";a();var{Buffer:ne}=E("buffer"),mo=Symbol.for("BufferList");function A(e){if(!(this instanceof A))return new A(e);A._init.call(this,e)}A._init=function(t){Object.defineProperty(this,mo,{value:!0}),this._bufs=[],this.length=0,t&&this.append(t)};A.prototype._new=function(t){return new A(t)};A.prototype._offset=function(t){if(t===0)return[0,0];let r=0;for(let n=0;n<this._bufs.length;n++){let i=r+this._bufs[n].length;if(t<i||n===this._bufs.length-1)return[n,t-r];r=i}};A.prototype._reverseOffset=function(e){let t=e[0],r=e[1];for(let n=0;n<t;n++)r+=this._bufs[n].length;return r};A.prototype.get=function(t){if(t>this.length||t<0)return;let r=this._offset(t);return this._bufs[r[0]][r[1]]};A.prototype.slice=function(t,r){return typeof t=="number"&&t<0&&(t+=this.length),typeof r=="number"&&r<0&&(r+=this.length),this.copy(null,0,t,r)};A.prototype.copy=function(t,r,n,i){if((typeof n!="number"||n<0)&&(n=0),(typeof i!="number"||i>this.length)&&(i=this.length),n>=this.length||i<=0)return t||ne.alloc(0);let o=!!t,s=this._offset(n),u=i-n,f=u,p=o&&r||0,l=s[1];if(n===0&&i===this.length){if(!o)return this._bufs.length===1?this._bufs[0]:ne.concat(this._bufs,this.length);for(let h=0;h<this._bufs.length;h++)this._bufs[h].copy(t,p),p+=this._bufs[h].length;return t}if(f<=this._bufs[s[0]].length-l)return o?this._bufs[s[0]].copy(t,r,l,l+f):this._bufs[s[0]].slice(l,l+f);o||(t=ne.allocUnsafe(u));for(let h=s[0];h<this._bufs.length;h++){let y=this._bufs[h].length-l;if(f>y)this._bufs[h].copy(t,p,l),p+=y;else{this._bufs[h].copy(t,p,l,l+f),p+=y;break}f-=y,l&&(l=0)}return t.length>p?t.slice(0,p):t};A.prototype.shallowSlice=function(t,r){if(t=t||0,r=typeof r!="number"?this.length:r,t<0&&(t+=this.length),r<0&&(r+=this.length),t===r)return this._new();let n=this._offset(t),i=this._offset(r),o=this._bufs.slice(n[0],i[0]+1);return i[1]===0?o.pop():o[o.length-1]=o[o.length-1].slice(0,i[1]),n[1]!==0&&(o[0]=o[0].slice(n[1])),this._new(o)};A.prototype.toString=function(t,r,n){return this.slice(r,n).toString(t)};A.prototype.consume=function(t){if(t=Math.trunc(t),Number.isNaN(t)||t<=0)return this;for(;this._bufs.length;)if(t>=this._bufs[0].length)t-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift();else{this._bufs[0]=this._bufs[0].slice(t),this.length-=t;break}return this};A.prototype.duplicate=function(){let t=this._new();for(let r=0;r<this._bufs.length;r++)t.append(this._bufs[r]);return t};A.prototype.append=function(t){if(t==null)return this;if(t.buffer)this._appendBuffer(ne.from(t.buffer,t.byteOffset,t.byteLength));else if(Array.isArray(t))for(let r=0;r<t.length;r++)this.append(t[r]);else if(this._isBufferList(t))for(let r=0;r<t._bufs.length;r++)this.append(t._bufs[r]);else typeof t=="number"&&(t=t.toString()),this._appendBuffer(ne.from(t));return this};A.prototype._appendBuffer=function(t){this._bufs.push(t),this.length+=t.length};A.prototype.indexOf=function(e,t,r){if(r===void 0&&typeof t=="string"&&(r=t,t=void 0),typeof e=="function"||Array.isArray(e))throw new TypeError('The "value" argument must be one of type string, Buffer, BufferList, or Uint8Array.');if(typeof e=="number"?e=ne.from([e]):typeof e=="string"?e=ne.from(e,r):this._isBufferList(e)?e=e.slice():Array.isArray(e.buffer)?e=ne.from(e.buffer,e.byteOffset,e.byteLength):ne.isBuffer(e)||(e=ne.from(e)),t=Number(t||0),isNaN(t)&&(t=0),t<0&&(t=this.length+t),t<0&&(t=0),e.length===0)return t>this.length?this.length:t;let n=this._offset(t),i=n[0],o=n[1];for(;i<this._bufs.length;i++){let s=this._bufs[i];for(;o<s.length;)if(s.length-o>=e.length){let f=s.indexOf(e,o);if(f!==-1)return this._reverseOffset([i,f]);o=s.length-e.length+1}else{let f=this._reverseOffset([i,o]);if(this._match(f,e))return f;o++}o=0}return-1};A.prototype._match=function(e,t){if(this.length-e<t.length)return!1;for(let r=0;r<t.length;r++)if(this.get(e+r)!==t[r])return!1;return!0};(function(){let e={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1,readIntBE:null,readIntLE:null,readUIntBE:null,readUIntLE:null};for(let t in e)(function(r){e[r]===null?A.prototype[r]=function(n,i){return this.slice(n,n+i)[r](0,i)}:A.prototype[r]=function(n=0){return this.slice(n,n+e[r])[r](0)}})(t)})();A.prototype._isBufferList=function(t){return t instanceof A||A.isBufferList(t)};A.isBufferList=function(t){return t!=null&&t[mo]};_o.exports=A});var xo=m((Zd,Jt)=>{"use strict";a();var nn=yo().Duplex,Rl=Re(),ct=go();function $(e){if(!(this instanceof $))return new $(e);if(typeof e=="function"){this._callback=e;let t=function(n){this._callback&&(this._callback(n),this._callback=null)}.bind(this);this.on("pipe",function(n){n.on("error",t)}),this.on("unpipe",function(n){n.removeListener("error",t)}),e=null}ct._init.call(this,e),nn.call(this)}Rl($,nn);Object.assign($.prototype,ct.prototype);$.prototype._new=function(t){return new $(t)};$.prototype._write=function(t,r,n){this._appendBuffer(t),typeof n=="function"&&n()};$.prototype._read=function(t){if(!this.length)return this.push(null);t=Math.min(t,this.length),this.push(this.slice(0,t)),this.consume(t)};$.prototype.end=function(t){nn.prototype.end.call(this,t),this._callback&&(this._callback(null,this.slice()),this._callback=null)};$.prototype._destroy=function(t,r){this._bufs.length=0,this.length=0,r(t)};$.prototype._isBufferList=function(t){return t instanceof $||t instanceof ct||$.isBufferList(t)};$.isBufferList=ct.isBufferList;Jt.exports=$;Jt.exports.BufferListStream=$;Jt.exports.BufferList=ct});var K=m(un=>{"use strict";a();un.fromCallback=function(e){return Object.defineProperty(function(...t){if(typeof t[t.length-1]=="function")e.apply(this,t);else return new Promise((r,n)=>{e.call(this,...t,(i,o)=>i!=null?n(i):r(o))})},"name",{value:e.name})};un.fromPromise=function(e){return Object.defineProperty(function(...t){let r=t[t.length-1];if(typeof r!="function")return e.apply(this,t);e.apply(this,t.slice(0,-1)).then(n=>r(null,n),r)},"name",{value:e.name})}});var To=m((y0,Ro)=>{a();var _e=E("constants"),Fl=process.cwd,Qt=null,Pl=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return Qt||(Qt=Fl.call(process)),Qt};try{process.cwd()}catch{}typeof process.chdir=="function"&&(fn=process.chdir,process.chdir=function(e){Qt=null,fn.call(process,e)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,fn));var fn;Ro.exports=Nl;function Nl(e){_e.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&t(e),e.lutimes||r(e),e.chown=o(e.chown),e.fchown=o(e.fchown),e.lchown=o(e.lchown),e.chmod=n(e.chmod),e.fchmod=n(e.fchmod),e.lchmod=n(e.lchmod),e.chownSync=s(e.chownSync),e.fchownSync=s(e.fchownSync),e.lchownSync=s(e.lchownSync),e.chmodSync=i(e.chmodSync),e.fchmodSync=i(e.fchmodSync),e.lchmodSync=i(e.lchmodSync),e.stat=u(e.stat),e.fstat=u(e.fstat),e.lstat=u(e.lstat),e.statSync=f(e.statSync),e.fstatSync=f(e.fstatSync),e.lstatSync=f(e.lstatSync),e.lchmod||(e.lchmod=function(l,h,y){y&&process.nextTick(y)},e.lchmodSync=function(){}),e.lchown||(e.lchown=function(l,h,y,d){d&&process.nextTick(d)},e.lchownSync=function(){}),Pl==="win32"&&(e.rename=function(l){return function(h,y,d){var _=Date.now(),g=0;l(h,y,function v(w){if(w&&(w.code==="EACCES"||w.code==="EPERM")&&Date.now()-_<6e4){setTimeout(function(){e.stat(y,function(D,le){D&&D.code==="ENOENT"?l(h,y,v):d(w)})},g),g<100&&(g+=10);return}d&&d(w)})}}(e.rename)),e.read=function(l){function h(y,d,_,g,v,w){var D;if(w&&typeof w=="function"){var le=0;D=function(ce,ke,Rn){if(ce&&ce.code==="EAGAIN"&&le<10)return le++,l.call(e,y,d,_,g,v,D);w.apply(this,arguments)}}return l.call(e,y,d,_,g,v,D)}return Object.setPrototypeOf&&Object.setPrototypeOf(h,l),h}(e.read),e.readSync=function(l){return function(h,y,d,_,g){for(var v=0;;)try{return l.call(e,h,y,d,_,g)}catch(w){if(w.code==="EAGAIN"&&v<10){v++;continue}throw w}}}(e.readSync);function t(l){l.lchmod=function(h,y,d){l.open(h,_e.O_WRONLY|_e.O_SYMLINK,y,function(_,g){if(_){d&&d(_);return}l.fchmod(g,y,function(v){l.close(g,function(w){d&&d(v||w)})})})},l.lchmodSync=function(h,y){var d=l.openSync(h,_e.O_WRONLY|_e.O_SYMLINK,y),_=!0,g;try{g=l.fchmodSync(d,y),_=!1}finally{if(_)try{l.closeSync(d)}catch{}else l.closeSync(d)}return g}}function r(l){_e.hasOwnProperty("O_SYMLINK")?(l.lutimes=function(h,y,d,_){l.open(h,_e.O_SYMLINK,function(g,v){if(g){_&&_(g);return}l.futimes(v,y,d,function(w){l.close(v,function(D){_&&_(w||D)})})})},l.lutimesSync=function(h,y,d){var _=l.openSync(h,_e.O_SYMLINK),g,v=!0;try{g=l.futimesSync(_,y,d),v=!1}finally{if(v)try{l.closeSync(_)}catch{}else l.closeSync(_)}return g}):(l.lutimes=function(h,y,d,_){_&&process.nextTick(_)},l.lutimesSync=function(){})}function n(l){return l&&function(h,y,d){return l.call(e,h,y,function(_){p(_)&&(_=null),d&&d.apply(this,arguments)})}}function i(l){return l&&function(h,y){try{return l.call(e,h,y)}catch(d){if(!p(d))throw d}}}function o(l){return l&&function(h,y,d,_){return l.call(e,h,y,d,function(g){p(g)&&(g=null),_&&_.apply(this,arguments)})}}function s(l){return l&&function(h,y,d){try{return l.call(e,h,y,d)}catch(_){if(!p(_))throw _}}}function u(l){return l&&function(h,y,d){typeof y=="function"&&(d=y,y=null);function _(g,v){v&&(v.uid<0&&(v.uid+=4294967296),v.gid<0&&(v.gid+=4294967296)),d&&d.apply(this,arguments)}return y?l.call(e,h,y,_):l.call(e,h,_)}}function f(l){return l&&function(h,y){var d=y?l.call(e,h,y):l.call(e,h);return d&&(d.uid<0&&(d.uid+=4294967296),d.gid<0&&(d.gid+=4294967296)),d}}function p(l){if(!l||l.code==="ENOSYS")return!0;var h=!process.getuid||process.getuid()!==0;return!!(h&&(l.code==="EINVAL"||l.code==="EPERM"))}}});var Ao=m((m0,Co)=>{a();var Oo=E("stream").Stream;Co.exports=kl;function kl(e){return{ReadStream:t,WriteStream:r};function t(n,i){if(!(this instanceof t))return new t(n,i);Oo.call(this);var o=this;this.path=n,this.fd=null,this.readable=!0,this.paused=!1,this.flags="r",this.mode=438,this.bufferSize=64*1024,i=i||{};for(var s=Object.keys(i),u=0,f=s.length;u<f;u++){var p=s[u];this[p]=i[p]}if(this.encoding&&this.setEncoding(this.encoding),this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw TypeError("end must be a Number");if(this.start>this.end)throw new Error("start must be <= end");this.pos=this.start}if(this.fd!==null){process.nextTick(function(){o._read()});return}e.open(this.path,this.flags,this.mode,function(l,h){if(l){o.emit("error",l),o.readable=!1;return}o.fd=h,o.emit("open",h),o._read()})}function r(n,i){if(!(this instanceof r))return new r(n,i);Oo.call(this),this.path=n,this.fd=null,this.writable=!0,this.flags="w",this.encoding="binary",this.mode=438,this.bytesWritten=0,i=i||{};for(var o=Object.keys(i),s=0,u=o.length;s<u;s++){var f=o[s];this[f]=i[f]}if(this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.start<0)throw new Error("start must be >= zero");this.pos=this.start}this.busy=!1,this._queue=[],this.fd===null&&(this._open=e.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}});var Fo=m((_0,Do)=>{"use strict";a();Do.exports=ql;var Bl=Object.getPrototypeOf||function(e){return e.__proto__};function ql(e){if(e===null||typeof e!="object")return e;if(e instanceof Object)var t={__proto__:Bl(e)};else var t=Object.create(null);return Object.getOwnPropertyNames(e).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r))}),t}});var V=m((g0,hn)=>{a();var P=E("fs"),Il=To(),Ml=Ao(),Ll=Fo(),Zt=E("util"),W,er;typeof Symbol=="function"&&typeof Symbol.for=="function"?(W=Symbol.for("graceful-fs.queue"),er=Symbol.for("graceful-fs.previous")):(W="___graceful-fs.queue",er="___graceful-fs.previous");function jl(){}function ko(e,t){Object.defineProperty(e,W,{get:function(){return t}})}var Fe=jl;Zt.debuglog?Fe=Zt.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(Fe=function(){var e=Zt.format.apply(Zt,arguments);e="GFS4: "+e.split(/\n/).join(`
|
5
|
+
GFS4: `),console.error(e)});P[W]||(Po=global[W]||[],ko(P,Po),P.close=function(e){function t(r,n){return e.call(P,r,function(i){i||No(),typeof n=="function"&&n.apply(this,arguments)})}return Object.defineProperty(t,er,{value:e}),t}(P.close),P.closeSync=function(e){function t(r){e.apply(P,arguments),No()}return Object.defineProperty(t,er,{value:e}),t}(P.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){Fe(P[W]),E("assert").equal(P[W].length,0)}));var Po;global[W]||ko(global,P[W]);hn.exports=ln(Ll(P));process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!P.__patched&&(hn.exports=ln(P),P.__patched=!0);function ln(e){Il(e),e.gracefulify=ln,e.createReadStream=ce,e.createWriteStream=ke;var t=e.readFile;e.readFile=r;function r(x,T,R){return typeof T=="function"&&(R=T,T=null),L(x,T,R);function L(j,U,B,Y){return t(j,U,function(C){C&&(C.code==="EMFILE"||C.code==="ENFILE")?He([L,[j,U,B],C,Y||Date.now(),Date.now()]):typeof B=="function"&&B.apply(this,arguments)})}}var n=e.writeFile;e.writeFile=i;function i(x,T,R,L){return typeof R=="function"&&(L=R,R=null),j(x,T,R,L);function j(U,B,Y,C,Z){return n(U,B,Y,function(q){q&&(q.code==="EMFILE"||q.code==="ENFILE")?He([j,[U,B,Y,C],q,Z||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}var o=e.appendFile;o&&(e.appendFile=s);function s(x,T,R,L){return typeof R=="function"&&(L=R,R=null),j(x,T,R,L);function j(U,B,Y,C,Z){return o(U,B,Y,function(q){q&&(q.code==="EMFILE"||q.code==="ENFILE")?He([j,[U,B,Y,C],q,Z||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}var u=e.copyFile;u&&(e.copyFile=f);function f(x,T,R,L){return typeof R=="function"&&(L=R,R=0),j(x,T,R,L);function j(U,B,Y,C,Z){return u(U,B,Y,function(q){q&&(q.code==="EMFILE"||q.code==="ENFILE")?He([j,[U,B,Y,C],q,Z||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}var p=e.readdir;e.readdir=l;function l(x,T,R){return typeof T=="function"&&(R=T,T=null),L(x,T,R);function L(j,U,B,Y){return p(j,U,function(C,Z){C&&(C.code==="EMFILE"||C.code==="ENFILE")?He([L,[j,U,B],C,Y||Date.now(),Date.now()]):(Z&&Z.sort&&Z.sort(),typeof B=="function"&&B.call(this,C,Z))})}}if(process.version.substr(0,4)==="v0.8"){var h=Ml(e);v=h.ReadStream,D=h.WriteStream}var y=e.ReadStream;y&&(v.prototype=Object.create(y.prototype),v.prototype.open=w);var d=e.WriteStream;d&&(D.prototype=Object.create(d.prototype),D.prototype.open=le),Object.defineProperty(e,"ReadStream",{get:function(){return v},set:function(x){v=x},enumerable:!0,configurable:!0}),Object.defineProperty(e,"WriteStream",{get:function(){return D},set:function(x){D=x},enumerable:!0,configurable:!0});var _=v;Object.defineProperty(e,"FileReadStream",{get:function(){return _},set:function(x){_=x},enumerable:!0,configurable:!0});var g=D;Object.defineProperty(e,"FileWriteStream",{get:function(){return g},set:function(x){g=x},enumerable:!0,configurable:!0});function v(x,T){return this instanceof v?(y.apply(this,arguments),this):v.apply(Object.create(v.prototype),arguments)}function w(){var x=this;hr(x.path,x.flags,x.mode,function(T,R){T?(x.autoClose&&x.destroy(),x.emit("error",T)):(x.fd=R,x.emit("open",R),x.read())})}function D(x,T){return this instanceof D?(d.apply(this,arguments),this):D.apply(Object.create(D.prototype),arguments)}function le(){var x=this;hr(x.path,x.flags,x.mode,function(T,R){T?(x.destroy(),x.emit("error",T)):(x.fd=R,x.emit("open",R))})}function ce(x,T){return new e.ReadStream(x,T)}function ke(x,T){return new e.WriteStream(x,T)}var Rn=e.open;e.open=hr;function hr(x,T,R,L){return typeof R=="function"&&(L=R,R=null),j(x,T,R,L);function j(U,B,Y,C,Z){return Rn(U,B,Y,function(q,Wh){q&&(q.code==="EMFILE"||q.code==="ENFILE")?He([j,[U,B,Y,C],q,Z||Date.now(),Date.now()]):typeof C=="function"&&C.apply(this,arguments)})}}return e}function He(e){Fe("ENQUEUE",e[0].name,e[1]),P[W].push(e),cn()}var zt;function No(){for(var e=Date.now(),t=0;t<P[W].length;++t)P[W][t].length>2&&(P[W][t][3]=e,P[W][t][4]=e);cn()}function cn(){if(clearTimeout(zt),zt=void 0,P[W].length!==0){var e=P[W].shift(),t=e[0],r=e[1],n=e[2],i=e[3],o=e[4];if(i===void 0)Fe("RETRY",t.name,r),t.apply(null,r);else if(Date.now()-i>=6e4){Fe("TIMEOUT",t.name,r);var s=r.pop();typeof s=="function"&&s.call(null,n)}else{var u=Date.now()-o,f=Math.max(o-i,1),p=Math.min(f*1.2,100);u>=p?(Fe("RETRY",t.name,r),t.apply(null,r.concat([i]))):P[W].push(e)}zt===void 0&&(zt=setTimeout(cn,0))}}});var Pe=m(ge=>{"use strict";a();var Bo=K().fromCallback,Q=V(),Ul=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter(e=>typeof Q[e]=="function");Object.assign(ge,Q);Ul.forEach(e=>{ge[e]=Bo(Q[e])});ge.realpath.native=Bo(Q.realpath.native);ge.exists=function(e,t){return typeof t=="function"?Q.exists(e,t):new Promise(r=>Q.exists(e,r))};ge.read=function(e,t,r,n,i,o){return typeof o=="function"?Q.read(e,t,r,n,i,o):new Promise((s,u)=>{Q.read(e,t,r,n,i,(f,p,l)=>{if(f)return u(f);s({bytesRead:p,buffer:l})})})};ge.write=function(e,t,...r){return typeof r[r.length-1]=="function"?Q.write(e,t,...r):new Promise((n,i)=>{Q.write(e,t,...r,(o,s,u)=>{if(o)return i(o);n({bytesWritten:s,buffer:u})})})};typeof Q.writev=="function"&&(ge.writev=function(e,t,...r){return typeof r[r.length-1]=="function"?Q.writev(e,t,...r):new Promise((n,i)=>{Q.writev(e,t,...r,(o,s,u)=>{if(o)return i(o);n({bytesWritten:s,buffers:u})})})})});var Io=m((v0,qo)=>{"use strict";a();var Wl=E("path");qo.exports.checkPath=function(t){if(process.platform==="win32"&&/[<>:"|?*]/.test(t.replace(Wl.parse(t).root,""))){let n=new Error(`Path contains invalid characters: ${t}`);throw n.code="EINVAL",n}}});var Uo=m((w0,dn)=>{"use strict";a();var Mo=Pe(),{checkPath:Lo}=Io(),jo=e=>{let t={mode:511};return typeof e=="number"?e:{...t,...e}.mode};dn.exports.makeDir=async(e,t)=>(Lo(e),Mo.mkdir(e,{mode:jo(t),recursive:!0}));dn.exports.makeDirSync=(e,t)=>(Lo(e),Mo.mkdirSync(e,{mode:jo(t),recursive:!0}))});var oe=m((S0,Wo)=>{"use strict";a();var $l=K().fromPromise,{makeDir:Gl,makeDirSync:pn}=Uo(),yn=$l(Gl);Wo.exports={mkdirs:yn,mkdirsSync:pn,mkdirp:yn,mkdirpSync:pn,ensureDir:yn,ensureDirSync:pn}});var xe=m((E0,Go)=>{"use strict";a();var Yl=K().fromPromise,$o=Pe();function Hl(e){return $o.access(e).then(()=>!0).catch(()=>!1)}Go.exports={pathExists:Yl(Hl),pathExistsSync:$o.existsSync}});var mn=m((b0,Yo)=>{"use strict";a();var Ve=V();function Vl(e,t,r,n){Ve.open(e,"r+",(i,o)=>{if(i)return n(i);Ve.futimes(o,t,r,s=>{Ve.close(o,u=>{n&&n(s||u)})})})}function Jl(e,t,r){let n=Ve.openSync(e,"r+");return Ve.futimesSync(n,t,r),Ve.closeSync(n)}Yo.exports={utimesMillis:Vl,utimesMillisSync:Jl}});var Ne=m((R0,Jo)=>{"use strict";a();var Je=Pe(),M=E("path"),Kl=E("util");function Xl(e,t,r){let n=r.dereference?i=>Je.stat(i,{bigint:!0}):i=>Je.lstat(i,{bigint:!0});return Promise.all([n(e),n(t).catch(i=>{if(i.code==="ENOENT")return null;throw i})]).then(([i,o])=>({srcStat:i,destStat:o}))}function Ql(e,t,r){let n,i=r.dereference?s=>Je.statSync(s,{bigint:!0}):s=>Je.lstatSync(s,{bigint:!0}),o=i(e);try{n=i(t)}catch(s){if(s.code==="ENOENT")return{srcStat:o,destStat:null};throw s}return{srcStat:o,destStat:n}}function Zl(e,t,r,n,i){Kl.callbackify(Xl)(e,t,n,(o,s)=>{if(o)return i(o);let{srcStat:u,destStat:f}=s;if(f){if(dt(u,f)){let p=M.basename(e),l=M.basename(t);return r==="move"&&p!==l&&p.toLowerCase()===l.toLowerCase()?i(null,{srcStat:u,destStat:f,isChangingCase:!0}):i(new Error("Source and destination must not be the same."))}if(u.isDirectory()&&!f.isDirectory())return i(new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`));if(!u.isDirectory()&&f.isDirectory())return i(new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`))}return u.isDirectory()&&_n(e,t)?i(new Error(tr(e,t,r))):i(null,{srcStat:u,destStat:f})})}function zl(e,t,r,n){let{srcStat:i,destStat:o}=Ql(e,t,n);if(o){if(dt(i,o)){let s=M.basename(e),u=M.basename(t);if(r==="move"&&s!==u&&s.toLowerCase()===u.toLowerCase())return{srcStat:i,destStat:o,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(i.isDirectory()&&!o.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!i.isDirectory()&&o.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(i.isDirectory()&&_n(e,t))throw new Error(tr(e,t,r));return{srcStat:i,destStat:o}}function Ho(e,t,r,n,i){let o=M.resolve(M.dirname(e)),s=M.resolve(M.dirname(r));if(s===o||s===M.parse(s).root)return i();Je.stat(s,{bigint:!0},(u,f)=>u?u.code==="ENOENT"?i():i(u):dt(t,f)?i(new Error(tr(e,r,n))):Ho(e,t,s,n,i))}function Vo(e,t,r,n){let i=M.resolve(M.dirname(e)),o=M.resolve(M.dirname(r));if(o===i||o===M.parse(o).root)return;let s;try{s=Je.statSync(o,{bigint:!0})}catch(u){if(u.code==="ENOENT")return;throw u}if(dt(t,s))throw new Error(tr(e,r,n));return Vo(e,t,o,n)}function dt(e,t){return t.ino&&t.dev&&t.ino===e.ino&&t.dev===e.dev}function _n(e,t){let r=M.resolve(e).split(M.sep).filter(i=>i),n=M.resolve(t).split(M.sep).filter(i=>i);return r.reduce((i,o,s)=>i&&n[s]===o,!0)}function tr(e,t,r){return`Cannot ${r} '${e}' to a subdirectory of itself, '${t}'.`}Jo.exports={checkPaths:Zl,checkPathsSync:zl,checkParentPaths:Ho,checkParentPathsSync:Vo,isSrcSubdir:_n,areIdentical:dt}});var rs=m((T0,ts)=>{"use strict";a();var X=V(),pt=E("path"),ec=oe().mkdirs,tc=xe().pathExists,rc=mn().utimesMillis,yt=Ne();function nc(e,t,r,n){typeof r=="function"&&!n?(n=r,r={}):typeof r=="function"&&(r={filter:r}),n=n||function(){},r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;
|
6
|
+
|
7
|
+
see https://github.com/jprichardson/node-fs-extra/issues/269`),yt.checkPaths(e,t,"copy",r,(i,o)=>{if(i)return n(i);let{srcStat:s,destStat:u}=o;yt.checkParentPaths(e,s,t,"copy",f=>f?n(f):r.filter?Qo(Ko,u,e,t,r,n):Ko(u,e,t,r,n))})}function Ko(e,t,r,n,i){let o=pt.dirname(r);tc(o,(s,u)=>{if(s)return i(s);if(u)return rr(e,t,r,n,i);ec(o,f=>f?i(f):rr(e,t,r,n,i))})}function Qo(e,t,r,n,i,o){Promise.resolve(i.filter(r,n)).then(s=>s?e(t,r,n,i,o):o(),s=>o(s))}function ic(e,t,r,n,i){return n.filter?Qo(rr,e,t,r,n,i):rr(e,t,r,n,i)}function rr(e,t,r,n,i){(n.dereference?X.stat:X.lstat)(t,(s,u)=>s?i(s):u.isDirectory()?cc(u,e,t,r,n,i):u.isFile()||u.isCharacterDevice()||u.isBlockDevice()?oc(u,e,t,r,n,i):u.isSymbolicLink()?pc(e,t,r,n,i):u.isSocket()?i(new Error(`Cannot copy a socket file: ${t}`)):u.isFIFO()?i(new Error(`Cannot copy a FIFO pipe: ${t}`)):i(new Error(`Unknown file: ${t}`)))}function oc(e,t,r,n,i,o){return t?sc(e,r,n,i,o):Zo(e,r,n,i,o)}function sc(e,t,r,n,i){if(n.overwrite)X.unlink(r,o=>o?i(o):Zo(e,t,r,n,i));else return n.errorOnExist?i(new Error(`'${r}' already exists`)):i()}function Zo(e,t,r,n,i){X.copyFile(t,r,o=>o?i(o):n.preserveTimestamps?ac(e.mode,t,r,i):nr(r,e.mode,i))}function ac(e,t,r,n){return uc(e)?fc(r,e,i=>i?n(i):Xo(e,t,r,n)):Xo(e,t,r,n)}function uc(e){return(e&128)===0}function fc(e,t,r){return nr(e,t|128,r)}function Xo(e,t,r,n){lc(t,r,i=>i?n(i):nr(r,e,n))}function nr(e,t,r){return X.chmod(e,t,r)}function lc(e,t,r){X.stat(e,(n,i)=>n?r(n):rc(t,i.atime,i.mtime,r))}function cc(e,t,r,n,i,o){return t?zo(r,n,i,o):hc(e.mode,r,n,i,o)}function hc(e,t,r,n,i){X.mkdir(r,o=>{if(o)return i(o);zo(t,r,n,s=>s?i(s):nr(r,e,i))})}function zo(e,t,r,n){X.readdir(e,(i,o)=>i?n(i):es(o,e,t,r,n))}function es(e,t,r,n,i){let o=e.pop();return o?dc(e,o,t,r,n,i):i()}function dc(e,t,r,n,i,o){let s=pt.join(r,t),u=pt.join(n,t);yt.checkPaths(s,u,"copy",i,(f,p)=>{if(f)return o(f);let{destStat:l}=p;ic(l,s,u,i,h=>h?o(h):es(e,r,n,i,o))})}function pc(e,t,r,n,i){X.readlink(t,(o,s)=>{if(o)return i(o);if(n.dereference&&(s=pt.resolve(process.cwd(),s)),e)X.readlink(r,(u,f)=>u?u.code==="EINVAL"||u.code==="UNKNOWN"?X.symlink(s,r,i):i(u):(n.dereference&&(f=pt.resolve(process.cwd(),f)),yt.isSrcSubdir(s,f)?i(new Error(`Cannot copy '${s}' to a subdirectory of itself, '${f}'.`)):e.isDirectory()&&yt.isSrcSubdir(f,s)?i(new Error(`Cannot overwrite '${f}' with '${s}'.`)):yc(s,r,i)));else return X.symlink(s,r,i)})}function yc(e,t,r){X.unlink(t,n=>n?r(n):X.symlink(e,t,r))}ts.exports=nc});var as=m((O0,ss)=>{"use strict";a();var G=V(),mt=E("path"),mc=oe().mkdirsSync,_c=mn().utimesMillisSync,_t=Ne();function gc(e,t,r){typeof r=="function"&&(r={filter:r}),r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;
|
8
|
+
|
9
|
+
see https://github.com/jprichardson/node-fs-extra/issues/269`);let{srcStat:n,destStat:i}=_t.checkPathsSync(e,t,"copy",r);return _t.checkParentPathsSync(e,n,t,"copy"),xc(i,e,t,r)}function xc(e,t,r,n){if(n.filter&&!n.filter(t,r))return;let i=mt.dirname(r);return G.existsSync(i)||mc(i),ns(e,t,r,n)}function vc(e,t,r,n){if(!(n.filter&&!n.filter(t,r)))return ns(e,t,r,n)}function ns(e,t,r,n){let o=(n.dereference?G.statSync:G.lstatSync)(t);if(o.isDirectory())return Oc(o,e,t,r,n);if(o.isFile()||o.isCharacterDevice()||o.isBlockDevice())return wc(o,e,t,r,n);if(o.isSymbolicLink())return Dc(e,t,r,n);throw o.isSocket()?new Error(`Cannot copy a socket file: ${t}`):o.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}function wc(e,t,r,n,i){return t?Sc(e,r,n,i):is(e,r,n,i)}function Sc(e,t,r,n){if(n.overwrite)return G.unlinkSync(r),is(e,t,r,n);if(n.errorOnExist)throw new Error(`'${r}' already exists`)}function is(e,t,r,n){return G.copyFileSync(t,r),n.preserveTimestamps&&Ec(e.mode,t,r),gn(r,e.mode)}function Ec(e,t,r){return bc(e)&&Rc(r,e),Tc(t,r)}function bc(e){return(e&128)===0}function Rc(e,t){return gn(e,t|128)}function gn(e,t){return G.chmodSync(e,t)}function Tc(e,t){let r=G.statSync(e);return _c(t,r.atime,r.mtime)}function Oc(e,t,r,n,i){return t?os(r,n,i):Cc(e.mode,r,n,i)}function Cc(e,t,r,n){return G.mkdirSync(r),os(t,r,n),gn(r,e)}function os(e,t,r){G.readdirSync(e).forEach(n=>Ac(n,e,t,r))}function Ac(e,t,r,n){let i=mt.join(t,e),o=mt.join(r,e),{destStat:s}=_t.checkPathsSync(i,o,"copy",n);return vc(s,i,o,n)}function Dc(e,t,r,n){let i=G.readlinkSync(t);if(n.dereference&&(i=mt.resolve(process.cwd(),i)),e){let o;try{o=G.readlinkSync(r)}catch(s){if(s.code==="EINVAL"||s.code==="UNKNOWN")return G.symlinkSync(i,r);throw s}if(n.dereference&&(o=mt.resolve(process.cwd(),o)),_t.isSrcSubdir(i,o))throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${o}'.`);if(G.statSync(r).isDirectory()&&_t.isSrcSubdir(o,i))throw new Error(`Cannot overwrite '${o}' with '${i}'.`);return Fc(i,r)}else return G.symlinkSync(i,r)}function Fc(e,t){return G.unlinkSync(t),G.symlinkSync(e,t)}ss.exports=gc});var ir=m((C0,us)=>{"use strict";a();var Pc=K().fromCallback;us.exports={copy:Pc(rs()),copySync:as()}});var _s=m((A0,ms)=>{"use strict";a();var fs=V(),ds=E("path"),O=E("assert"),gt=process.platform==="win32";function ps(e){["unlink","chmod","stat","lstat","rmdir","readdir"].forEach(r=>{e[r]=e[r]||fs[r],r=r+"Sync",e[r]=e[r]||fs[r]}),e.maxBusyTries=e.maxBusyTries||3}function xn(e,t,r){let n=0;typeof t=="function"&&(r=t,t={}),O(e,"rimraf: missing path"),O.strictEqual(typeof e,"string","rimraf: path should be a string"),O.strictEqual(typeof r,"function","rimraf: callback function required"),O(t,"rimraf: invalid options argument provided"),O.strictEqual(typeof t,"object","rimraf: options should be object"),ps(t),ls(e,t,function i(o){if(o){if((o.code==="EBUSY"||o.code==="ENOTEMPTY"||o.code==="EPERM")&&n<t.maxBusyTries){n++;let s=n*100;return setTimeout(()=>ls(e,t,i),s)}o.code==="ENOENT"&&(o=null)}r(o)})}function ls(e,t,r){O(e),O(t),O(typeof r=="function"),t.lstat(e,(n,i)=>{if(n&&n.code==="ENOENT")return r(null);if(n&&n.code==="EPERM"&>)return cs(e,t,n,r);if(i&&i.isDirectory())return or(e,t,n,r);t.unlink(e,o=>{if(o){if(o.code==="ENOENT")return r(null);if(o.code==="EPERM")return gt?cs(e,t,o,r):or(e,t,o,r);if(o.code==="EISDIR")return or(e,t,o,r)}return r(o)})})}function cs(e,t,r,n){O(e),O(t),O(typeof n=="function"),t.chmod(e,438,i=>{i?n(i.code==="ENOENT"?null:r):t.stat(e,(o,s)=>{o?n(o.code==="ENOENT"?null:r):s.isDirectory()?or(e,t,r,n):t.unlink(e,n)})})}function hs(e,t,r){let n;O(e),O(t);try{t.chmodSync(e,438)}catch(i){if(i.code==="ENOENT")return;throw r}try{n=t.statSync(e)}catch(i){if(i.code==="ENOENT")return;throw r}n.isDirectory()?sr(e,t,r):t.unlinkSync(e)}function or(e,t,r,n){O(e),O(t),O(typeof n=="function"),t.rmdir(e,i=>{i&&(i.code==="ENOTEMPTY"||i.code==="EEXIST"||i.code==="EPERM")?Nc(e,t,n):i&&i.code==="ENOTDIR"?n(r):n(i)})}function Nc(e,t,r){O(e),O(t),O(typeof r=="function"),t.readdir(e,(n,i)=>{if(n)return r(n);let o=i.length,s;if(o===0)return t.rmdir(e,r);i.forEach(u=>{xn(ds.join(e,u),t,f=>{if(!s){if(f)return r(s=f);--o===0&&t.rmdir(e,r)}})})})}function ys(e,t){let r;t=t||{},ps(t),O(e,"rimraf: missing path"),O.strictEqual(typeof e,"string","rimraf: path should be a string"),O(t,"rimraf: missing options"),O.strictEqual(typeof t,"object","rimraf: options should be object");try{r=t.lstatSync(e)}catch(n){if(n.code==="ENOENT")return;n.code==="EPERM"&>&&hs(e,t,n)}try{r&&r.isDirectory()?sr(e,t,null):t.unlinkSync(e)}catch(n){if(n.code==="ENOENT")return;if(n.code==="EPERM")return gt?hs(e,t,n):sr(e,t,n);if(n.code!=="EISDIR")throw n;sr(e,t,n)}}function sr(e,t,r){O(e),O(t);try{t.rmdirSync(e)}catch(n){if(n.code==="ENOTDIR")throw r;if(n.code==="ENOTEMPTY"||n.code==="EEXIST"||n.code==="EPERM")kc(e,t);else if(n.code!=="ENOENT")throw n}}function kc(e,t){if(O(e),O(t),t.readdirSync(e).forEach(r=>ys(ds.join(e,r),t)),gt){let r=Date.now();do try{return t.rmdirSync(e,t)}catch{}while(Date.now()-r<500)}else return t.rmdirSync(e,t)}ms.exports=xn;xn.sync=ys});var xt=m((D0,xs)=>{"use strict";a();var ar=V(),Bc=K().fromCallback,gs=_s();function qc(e,t){if(ar.rm)return ar.rm(e,{recursive:!0,force:!0},t);gs(e,t)}function Ic(e){if(ar.rmSync)return ar.rmSync(e,{recursive:!0,force:!0});gs.sync(e)}xs.exports={remove:Bc(qc),removeSync:Ic}});var Os=m((F0,Ts)=>{"use strict";a();var Mc=K().fromPromise,Ss=Pe(),Es=E("path"),bs=oe(),Rs=xt(),vs=Mc(async function(t){let r;try{r=await Ss.readdir(t)}catch{return bs.mkdirs(t)}return Promise.all(r.map(n=>Rs.remove(Es.join(t,n))))});function ws(e){let t;try{t=Ss.readdirSync(e)}catch{return bs.mkdirsSync(e)}t.forEach(r=>{r=Es.join(e,r),Rs.removeSync(r)})}Ts.exports={emptyDirSync:ws,emptydirSync:ws,emptyDir:vs,emptydir:vs}});var Fs=m((P0,Ds)=>{"use strict";a();var Lc=K().fromCallback,Cs=E("path"),ve=V(),As=oe();function jc(e,t){function r(){ve.writeFile(e,"",n=>{if(n)return t(n);t()})}ve.stat(e,(n,i)=>{if(!n&&i.isFile())return t();let o=Cs.dirname(e);ve.stat(o,(s,u)=>{if(s)return s.code==="ENOENT"?As.mkdirs(o,f=>{if(f)return t(f);r()}):t(s);u.isDirectory()?r():ve.readdir(o,f=>{if(f)return t(f)})})})}function Uc(e){let t;try{t=ve.statSync(e)}catch{}if(t&&t.isFile())return;let r=Cs.dirname(e);try{ve.statSync(r).isDirectory()||ve.readdirSync(r)}catch(n){if(n&&n.code==="ENOENT")As.mkdirsSync(r);else throw n}ve.writeFileSync(e,"")}Ds.exports={createFile:Lc(jc),createFileSync:Uc}});var qs=m((N0,Bs)=>{"use strict";a();var Wc=K().fromCallback,Ps=E("path"),we=V(),Ns=oe(),$c=xe().pathExists,{areIdentical:ks}=Ne();function Gc(e,t,r){function n(i,o){we.link(i,o,s=>{if(s)return r(s);r(null)})}we.lstat(t,(i,o)=>{we.lstat(e,(s,u)=>{if(s)return s.message=s.message.replace("lstat","ensureLink"),r(s);if(o&&ks(u,o))return r(null);let f=Ps.dirname(t);$c(f,(p,l)=>{if(p)return r(p);if(l)return n(e,t);Ns.mkdirs(f,h=>{if(h)return r(h);n(e,t)})})})})}function Yc(e,t){let r;try{r=we.lstatSync(t)}catch{}try{let o=we.lstatSync(e);if(r&&ks(o,r))return}catch(o){throw o.message=o.message.replace("lstat","ensureLink"),o}let n=Ps.dirname(t);return we.existsSync(n)||Ns.mkdirsSync(n),we.linkSync(e,t)}Bs.exports={createLink:Wc(Gc),createLinkSync:Yc}});var Ms=m((k0,Is)=>{"use strict";a();var Se=E("path"),vt=V(),Hc=xe().pathExists;function Vc(e,t,r){if(Se.isAbsolute(e))return vt.lstat(e,n=>n?(n.message=n.message.replace("lstat","ensureSymlink"),r(n)):r(null,{toCwd:e,toDst:e}));{let n=Se.dirname(t),i=Se.join(n,e);return Hc(i,(o,s)=>o?r(o):s?r(null,{toCwd:i,toDst:e}):vt.lstat(e,u=>u?(u.message=u.message.replace("lstat","ensureSymlink"),r(u)):r(null,{toCwd:e,toDst:Se.relative(n,e)})))}}function Jc(e,t){let r;if(Se.isAbsolute(e)){if(r=vt.existsSync(e),!r)throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}else{let n=Se.dirname(t),i=Se.join(n,e);if(r=vt.existsSync(i),r)return{toCwd:i,toDst:e};if(r=vt.existsSync(e),!r)throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:Se.relative(n,e)}}}Is.exports={symlinkPaths:Vc,symlinkPathsSync:Jc}});var Us=m((B0,js)=>{"use strict";a();var Ls=V();function Kc(e,t,r){if(r=typeof t=="function"?t:r,t=typeof t=="function"?!1:t,t)return r(null,t);Ls.lstat(e,(n,i)=>{if(n)return r(null,"file");t=i&&i.isDirectory()?"dir":"file",r(null,t)})}function Xc(e,t){let r;if(t)return t;try{r=Ls.lstatSync(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}js.exports={symlinkType:Kc,symlinkTypeSync:Xc}});var Ks=m((q0,Js)=>{"use strict";a();var Qc=K().fromCallback,$s=E("path"),se=Pe(),Gs=oe(),Zc=Gs.mkdirs,zc=Gs.mkdirsSync,Ys=Ms(),eh=Ys.symlinkPaths,th=Ys.symlinkPathsSync,Hs=Us(),rh=Hs.symlinkType,nh=Hs.symlinkTypeSync,ih=xe().pathExists,{areIdentical:Vs}=Ne();function oh(e,t,r,n){n=typeof r=="function"?r:n,r=typeof r=="function"?!1:r,se.lstat(t,(i,o)=>{!i&&o.isSymbolicLink()?Promise.all([se.stat(e),se.stat(t)]).then(([s,u])=>{if(Vs(s,u))return n(null);Ws(e,t,r,n)}):Ws(e,t,r,n)})}function Ws(e,t,r,n){eh(e,t,(i,o)=>{if(i)return n(i);e=o.toDst,rh(o.toCwd,r,(s,u)=>{if(s)return n(s);let f=$s.dirname(t);ih(f,(p,l)=>{if(p)return n(p);if(l)return se.symlink(e,t,u,n);Zc(f,h=>{if(h)return n(h);se.symlink(e,t,u,n)})})})})}function sh(e,t,r){let n;try{n=se.lstatSync(t)}catch{}if(n&&n.isSymbolicLink()){let u=se.statSync(e),f=se.statSync(t);if(Vs(u,f))return}let i=th(e,t);e=i.toDst,r=nh(i.toCwd,r);let o=$s.dirname(t);return se.existsSync(o)||zc(o),se.symlinkSync(e,t,r)}Js.exports={createSymlink:Qc(oh),createSymlinkSync:sh}});var na=m((I0,ra)=>{"use strict";a();var{createFile:Xs,createFileSync:Qs}=Fs(),{createLink:Zs,createLinkSync:zs}=qs(),{createSymlink:ea,createSymlinkSync:ta}=Ks();ra.exports={createFile:Xs,createFileSync:Qs,ensureFile:Xs,ensureFileSync:Qs,createLink:Zs,createLinkSync:zs,ensureLink:Zs,ensureLinkSync:zs,createSymlink:ea,createSymlinkSync:ta,ensureSymlink:ea,ensureSymlinkSync:ta}});var ur=m((M0,ia)=>{a();function ah(e,{EOL:t=`
|
10
|
+
`,finalEOL:r=!0,replacer:n=null,spaces:i}={}){let o=r?t:"";return JSON.stringify(e,n,i).replace(/\n/g,t)+o}function uh(e){return Buffer.isBuffer(e)&&(e=e.toString("utf8")),e.replace(/^\uFEFF/,"")}ia.exports={stringify:ah,stripBom:uh}});var ua=m((L0,aa)=>{a();var Ke;try{Ke=V()}catch{Ke=E("fs")}var fr=K(),{stringify:oa,stripBom:sa}=ur();async function fh(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||Ke,n="throws"in t?t.throws:!0,i=await fr.fromCallback(r.readFile)(e,t);i=sa(i);let o;try{o=JSON.parse(i,t?t.reviver:null)}catch(s){if(n)throw s.message=`${e}: ${s.message}`,s;return null}return o}var lh=fr.fromPromise(fh);function ch(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||Ke,n="throws"in t?t.throws:!0;try{let i=r.readFileSync(e,t);return i=sa(i),JSON.parse(i,t.reviver)}catch(i){if(n)throw i.message=`${e}: ${i.message}`,i;return null}}async function hh(e,t,r={}){let n=r.fs||Ke,i=oa(t,r);await fr.fromCallback(n.writeFile)(e,i,r)}var dh=fr.fromPromise(hh);function ph(e,t,r={}){let n=r.fs||Ke,i=oa(t,r);return n.writeFileSync(e,i,r)}var yh={readFile:lh,readFileSync:ch,writeFile:dh,writeFileSync:ph};aa.exports=yh});var la=m((j0,fa)=>{"use strict";a();var lr=ua();fa.exports={readJson:lr.readFile,readJsonSync:lr.readFileSync,writeJson:lr.writeFile,writeJsonSync:lr.writeFileSync}});var cr=m((U0,da)=>{"use strict";a();var mh=K().fromCallback,wt=V(),ca=E("path"),ha=oe(),_h=xe().pathExists;function gh(e,t,r,n){typeof r=="function"&&(n=r,r="utf8");let i=ca.dirname(e);_h(i,(o,s)=>{if(o)return n(o);if(s)return wt.writeFile(e,t,r,n);ha.mkdirs(i,u=>{if(u)return n(u);wt.writeFile(e,t,r,n)})})}function xh(e,...t){let r=ca.dirname(e);if(wt.existsSync(r))return wt.writeFileSync(e,...t);ha.mkdirsSync(r),wt.writeFileSync(e,...t)}da.exports={outputFile:mh(gh),outputFileSync:xh}});var ya=m((W0,pa)=>{"use strict";a();var{stringify:vh}=ur(),{outputFile:wh}=cr();async function Sh(e,t,r={}){let n=vh(t,r);await wh(e,n,r)}pa.exports=Sh});var _a=m(($0,ma)=>{"use strict";a();var{stringify:Eh}=ur(),{outputFileSync:bh}=cr();function Rh(e,t,r){let n=Eh(t,r);bh(e,n,r)}ma.exports=Rh});var xa=m((G0,ga)=>{"use strict";a();var Th=K().fromPromise,J=la();J.outputJson=Th(ya());J.outputJsonSync=_a();J.outputJSON=J.outputJson;J.outputJSONSync=J.outputJsonSync;J.writeJSON=J.writeJson;J.writeJSONSync=J.writeJsonSync;J.readJSON=J.readJson;J.readJSONSync=J.readJsonSync;ga.exports=J});var ba=m((Y0,Ea)=>{"use strict";a();var Oh=V(),wn=E("path"),Ch=ir().copy,Sa=xt().remove,Ah=oe().mkdirp,Dh=xe().pathExists,va=Ne();function Fh(e,t,r,n){typeof r=="function"&&(n=r,r={});let i=r.overwrite||r.clobber||!1;va.checkPaths(e,t,"move",r,(o,s)=>{if(o)return n(o);let{srcStat:u,isChangingCase:f=!1}=s;va.checkParentPaths(e,u,t,"move",p=>{if(p)return n(p);if(Ph(t))return wa(e,t,i,f,n);Ah(wn.dirname(t),l=>l?n(l):wa(e,t,i,f,n))})})}function Ph(e){let t=wn.dirname(e);return wn.parse(t).root===t}function wa(e,t,r,n,i){if(n)return vn(e,t,r,i);if(r)return Sa(t,o=>o?i(o):vn(e,t,r,i));Dh(t,(o,s)=>o?i(o):s?i(new Error("dest already exists.")):vn(e,t,r,i))}function vn(e,t,r,n){Oh.rename(e,t,i=>i?i.code!=="EXDEV"?n(i):Nh(e,t,r,n):n())}function Nh(e,t,r,n){Ch(e,t,{overwrite:r,errorOnExist:!0},o=>o?n(o):Sa(e,n))}Ea.exports=Fh});var Aa=m((H0,Ca)=>{"use strict";a();var Ta=V(),En=E("path"),kh=ir().copySync,Oa=xt().removeSync,Bh=oe().mkdirpSync,Ra=Ne();function qh(e,t,r){r=r||{};let n=r.overwrite||r.clobber||!1,{srcStat:i,isChangingCase:o=!1}=Ra.checkPathsSync(e,t,"move",r);return Ra.checkParentPathsSync(e,i,t,"move"),Ih(t)||Bh(En.dirname(t)),Mh(e,t,n,o)}function Ih(e){let t=En.dirname(e);return En.parse(t).root===t}function Mh(e,t,r,n){if(n)return Sn(e,t,r);if(r)return Oa(t),Sn(e,t,r);if(Ta.existsSync(t))throw new Error("dest already exists.");return Sn(e,t,r)}function Sn(e,t,r){try{Ta.renameSync(e,t)}catch(n){if(n.code!=="EXDEV")throw n;return Lh(e,t,r)}}function Lh(e,t,r){return kh(e,t,{overwrite:r,errorOnExist:!0}),Oa(e)}Ca.exports=qh});var Fa=m((V0,Da)=>{"use strict";a();var jh=K().fromCallback;Da.exports={move:jh(ba()),moveSync:Aa()}});var Na=m((J0,Pa)=>{"use strict";a();Pa.exports={...Pe(),...ir(),...Os(),...na(),...xa(),...oe(),...Fa(),...cr(),...xe(),...xt()}});a();a();a();var Tn=(e=0)=>t=>`\x1B[${t+e}m`,On=(e=0)=>t=>`\x1B[${38+e};5;${t}m`,Cn=(e=0)=>(t,r,n)=>`\x1B[${38+e};2;${t};${r};${n}m`;function Ha(){let e=new Map,t={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};t.color.gray=t.color.blackBright,t.bgColor.bgGray=t.bgColor.bgBlackBright,t.color.grey=t.color.blackBright,t.bgColor.bgGrey=t.bgColor.bgBlackBright;for(let[r,n]of Object.entries(t)){for(let[i,o]of Object.entries(n))t[i]={open:`\x1B[${o[0]}m`,close:`\x1B[${o[1]}m`},n[i]=t[i],e.set(o[0],o[1]);Object.defineProperty(t,r,{value:n,enumerable:!1})}return Object.defineProperty(t,"codes",{value:e,enumerable:!1}),t.color.close="\x1B[39m",t.bgColor.close="\x1B[49m",t.color.ansi=Tn(),t.color.ansi256=On(),t.color.ansi16m=Cn(),t.bgColor.ansi=Tn(10),t.bgColor.ansi256=On(10),t.bgColor.ansi16m=Cn(10),Object.defineProperties(t,{rgbToAnsi256:{value:(r,n,i)=>r===n&&n===i?r<8?16:r>248?231:Math.round((r-8)/247*24)+232:16+36*Math.round(r/255*5)+6*Math.round(n/255*5)+Math.round(i/255*5),enumerable:!1},hexToRgb:{value:r=>{let n=/(?<colorString>[a-f\d]{6}|[a-f\d]{3})/i.exec(r.toString(16));if(!n)return[0,0,0];let{colorString:i}=n.groups;i.length===3&&(i=[...i].map(s=>s+s).join(""));let o=Number.parseInt(i,16);return[o>>16&255,o>>8&255,o&255]},enumerable:!1},hexToAnsi256:{value:r=>t.rgbToAnsi256(...t.hexToRgb(r)),enumerable:!1},ansi256ToAnsi:{value:r=>{if(r<8)return 30+r;if(r<16)return 90+(r-8);let n,i,o;if(r>=232)n=((r-232)*10+8)/255,i=n,o=n;else{r-=16;let f=r%36;n=Math.floor(r/36)/5,i=Math.floor(f/6)/5,o=f%6/5}let s=Math.max(n,i,o)*2;if(s===0)return 30;let u=30+(Math.round(o)<<2|Math.round(i)<<1|Math.round(n));return s===2&&(u+=60),u},enumerable:!1},rgbToAnsi:{value:(r,n,i)=>t.ansi256ToAnsi(t.rgbToAnsi256(r,n,i)),enumerable:!1},hexToAnsi:{value:r=>t.ansi256ToAnsi(t.hexToAnsi256(r)),enumerable:!1}}),t}var Va=Ha(),re=Va;a();import pr from"node:process";import Ja from"node:os";import An from"node:tty";function z(e,t=pr.argv){let r=e.startsWith("-")?"":e.length===1?"-":"--",n=t.indexOf(r+e),i=t.indexOf("--");return n!==-1&&(i===-1||n<i)}var{env:k}=pr,St;z("no-color")||z("no-colors")||z("color=false")||z("color=never")?St=0:(z("color")||z("colors")||z("color=true")||z("color=always"))&&(St=1);function Ka(){if("FORCE_COLOR"in k)return k.FORCE_COLOR==="true"?1:k.FORCE_COLOR==="false"?0:k.FORCE_COLOR.length===0?1:Math.min(Number.parseInt(k.FORCE_COLOR,10),3)}function Xa(e){return e===0?!1:{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function Qa(e,{streamIsTTY:t,sniffFlags:r=!0}={}){let n=Ka();n!==void 0&&(St=n);let i=r?St:n;if(i===0)return 0;if(r){if(z("color=16m")||z("color=full")||z("color=truecolor"))return 3;if(z("color=256"))return 2}if(e&&!t&&i===void 0)return 0;let o=i||0;if(k.TERM==="dumb")return o;if(pr.platform==="win32"){let s=Ja.release().split(".");return Number(s[0])>=10&&Number(s[2])>=10586?Number(s[2])>=14931?3:2:1}if("CI"in k)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE","DRONE"].some(s=>s in k)||k.CI_NAME==="codeship"?1:o;if("TEAMCITY_VERSION"in k)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(k.TEAMCITY_VERSION)?1:0;if("TF_BUILD"in k&&"AGENT_NAME"in k)return 1;if(k.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in k){let s=Number.parseInt((k.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(k.TERM_PROGRAM){case"iTerm.app":return s>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(k.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(k.TERM)||"COLORTERM"in k?1:o}function Dn(e,t={}){let r=Qa(e,{streamIsTTY:e&&e.isTTY,...t});return Xa(r)}var Za={stdout:Dn({isTTY:An.isatty(1)}),stderr:Dn({isTTY:An.isatty(2)})},Fn=Za;a();function Pn(e,t,r){let n=e.indexOf(t);if(n===-1)return e;let i=t.length,o=0,s="";do s+=e.substr(o,n-o)+t+r,o=n+i,n=e.indexOf(t,o);while(n!==-1);return s+=e.slice(o),s}function Nn(e,t,r,n){let i=0,o="";do{let s=e[n-1]==="\r";o+=e.substr(i,(s?n-1:n)-i)+t+(s?`\r
|
11
|
+
`:`
|
12
|
+
`)+r,i=n+1,n=e.indexOf(`
|
13
|
+
`,i)}while(n!==-1);return o+=e.slice(i),o}var{stdout:kn,stderr:Bn}=Fn,yr=Symbol("GENERATOR"),qe=Symbol("STYLER"),Xe=Symbol("IS_EMPTY"),qn=["ansi","ansi","ansi256","ansi16m"],Ie=Object.create(null),za=(e,t={})=>{if(t.level&&!(Number.isInteger(t.level)&&t.level>=0&&t.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");let r=kn?kn.level:0;e.level=t.level===void 0?r:t.level};var eu=e=>{let t=(...r)=>r.join(" ");return za(t,e),Object.setPrototypeOf(t,Qe.prototype),t};function Qe(e){return eu(e)}Object.setPrototypeOf(Qe.prototype,Function.prototype);for(let[e,t]of Object.entries(re))Ie[e]={get(){let r=Et(this,_r(t.open,t.close,this[qe]),this[Xe]);return Object.defineProperty(this,e,{value:r}),r}};Ie.visible={get(){let e=Et(this,this[qe],!0);return Object.defineProperty(this,"visible",{value:e}),e}};var mr=(e,t,r,...n)=>e==="rgb"?t==="ansi16m"?re[r].ansi16m(...n):t==="ansi256"?re[r].ansi256(re.rgbToAnsi256(...n)):re[r].ansi(re.rgbToAnsi(...n)):e==="hex"?mr("rgb",t,r,...re.hexToRgb(...n)):re[r][e](...n),tu=["rgb","hex","ansi256"];for(let e of tu){Ie[e]={get(){let{level:r}=this;return function(...n){let i=_r(mr(e,qn[r],"color",...n),re.color.close,this[qe]);return Et(this,i,this[Xe])}}};let t="bg"+e[0].toUpperCase()+e.slice(1);Ie[t]={get(){let{level:r}=this;return function(...n){let i=_r(mr(e,qn[r],"bgColor",...n),re.bgColor.close,this[qe]);return Et(this,i,this[Xe])}}}}var ru=Object.defineProperties(()=>{},{...Ie,level:{enumerable:!0,get(){return this[yr].level},set(e){this[yr].level=e}}}),_r=(e,t,r)=>{let n,i;return r===void 0?(n=e,i=t):(n=r.openAll+e,i=t+r.closeAll),{open:e,close:t,openAll:n,closeAll:i,parent:r}},Et=(e,t,r)=>{let n=(...i)=>nu(n,i.length===1?""+i[0]:i.join(" "));return Object.setPrototypeOf(n,ru),n[yr]=e,n[qe]=t,n[Xe]=r,n},nu=(e,t)=>{if(e.level<=0||!t)return e[Xe]?"":t;let r=e[qe];if(r===void 0)return t;let{openAll:n,closeAll:i}=r;if(t.includes("\x1B"))for(;r!==void 0;)t=Pn(t,r.close,r.open),r=r.parent;let o=t.indexOf(`
|
14
|
+
`);return o!==-1&&(t=Nn(t,i,n,o)),n+t+i};Object.defineProperties(Qe.prototype,Ie);var iu=Qe(),td=Qe({level:Bn?Bn.level:0});var H=iu;a();a();var ou={win32:e=>({cmd:"cmd.exe",args:["/d","/s","/c",e]})},su={"cp -rf":{win32:"xcopy /E /S /G /Q /Y"},ln:{win32:"mklink"},pkill:{win32:"taskkill /T /F /pid"}},In=(e,t,r)=>{let n={...ou,...t},i={...su,...r},o=u=>{let f=process.platform,p=n[f];if(p)return p(u);let[l,...h]=u.split(" ");return{cmd:l,args:h}},s=(u=>{let f=Object.entries(i);for(let[p,l]of f)if(u.startsWith(p)){let h=process.platform,y=l[h];if(!y)break;return`${y} ${u.slice(p.length)}`}return u})(e);return o(s)};import{spawn as au,execSync as uu}from"child_process";a();var fu=process.platform==="linux"||process.platform==="darwin",gr=process.platform==="win32",lu={stdio:"pipe",shell:!0,detached:!gr,env:process.env},cu={log:!0,commandTranslations:{},shellTranslations:{},...lu},Mn=({log:e=!0,commandTranslations:t={},shellTranslations:r={},...n}=cu)=>{let i=null;return{childProcess:i,async run(o){if(i)throw new Error("Only one command per shell.");if(typeof o=="object"){let f=process.platform;o.posix&&fu&&(f="posix");let p=o[f];if(!p)throw new Error("No command found for platform: "+JSON.stringify({platform:process.platform,command:o}));o=p}let{cmd:s,args:u}=In(o,r,t);return e&&console.log(H.dim(`
|
15
|
+
$ ${o}
|
16
|
+
`)),await new Promise((f,p)=>{i=au(s,u,n);let l="",h="";if(!i)throw new Error("Child process was not set.");let y=d=>{i=null;let _={code:d,stdout:l,stderr:h};d===0||d===1&&!gr?f(_):p(_)};i.stdout?.on("data",d=>{l+=d.toString()}),i.stderr?.on("data",d=>{h+=d.toString()}),i.on("close",y),i.on("exit",y),i.on("error",y),i.stdout?.pipe(process.stdout),i.stderr?.pipe(process.stderr)})},kill(o="SIGKILL"){if(i?.pid)if(gr)uu(`taskkill /t /f /pid ${i.pid}`);else return process.kill(-i.pid,o);return!0}}};a();import Kt from"node:process";a();import Zn from"node:process";a();var Kn=Be(Wn(),1),Xn=Be(Jn(),1);import du from"node:process";var pu=(0,Kn.default)(()=>{(0,Xn.default)(()=>{du.stderr.write("\x1B[?25h")},{alwaysLast:!0})}),Qn=pu;var Dt=!1,Ue={};Ue.show=(e=Zn.stderr)=>{!e.isTTY||(Dt=!1,e.write("\x1B[?25h"))};Ue.hide=(e=Zn.stderr)=>{!e.isTTY||(Qn(),Dt=!0,e.write("\x1B[?25l"))};Ue.toggle=(e,t)=>{e!==void 0&&(Dt=e),Dt?Ue.show(t):Ue.hide(t)};var Sr=Ue;var ht=Be(ri(),1);a();a();function ze(){return process.platform!=="win32"?process.env.TERM!=="linux":Boolean(process.env.CI)||Boolean(process.env.WT_SESSION)||process.env.ConEmuTask==="{cmd::Cmder}"||process.env.TERM_PROGRAM==="vscode"||process.env.TERM==="xterm-256color"||process.env.TERM==="alacritty"}var mu={info:H.blue("ℹ"),success:H.green("✔"),warning:H.yellow("⚠"),error:H.red("✖")},_u={info:H.blue("i"),success:H.green("√"),warning:H.yellow("‼"),error:H.red("×")},gu=ze()?mu:_u,et=gu;a();a();function Er({onlyFirst:e=!1}={}){let t=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(t,e?void 0:"g")}function br(e){if(typeof e!="string")throw new TypeError(`Expected a \`string\`, got \`${typeof e}\``);return e.replace(Er(),"")}var wo=Be(ci(),1);a();function Tr({stream:e=process.stdout}={}){return Boolean(e&&e.isTTY&&process.env.TERM!=="dumb"&&!("CI"in process.env))}a();var vo=Be(xo(),1);import ie from"node:process";import Tl from"node:readline";var Ol=3,on=class{#r=0;#l=new vo.BufferListStream;#i;#n;constructor(){this.#l.pipe(ie.stdout);let t=this;this.#i=function(r,n,...i){let{stdin:o}=ie;if(t.#r>0||o.emit===t.#i){if(r==="keypress")return;r==="data"&&n.includes(Ol)&&ie.emit("SIGINT"),Reflect.apply(t.#i,this,[r,n,...i])}else Reflect.apply(ie.stdin.emit,this,[r,n,...i])}}start(){this.#r++,this.#r===1&&this._realStart()}stop(){if(this.#r<=0)throw new Error("`stop` called more times than `start`");this.#r--,this.#r===0&&this._realStop()}_realStart(){ie.platform!=="win32"&&(this.#n=Tl.createInterface({input:ie.stdin,output:this.#l}),this.#n.on("SIGINT",()=>{ie.listenerCount("SIGINT")===0?ie.emit("SIGINT"):(this.#n.close(),ie.kill(ie.pid,"SIGINT"))}))}_realStop(){ie.platform!=="win32"&&(this.#n.close(),this.#n=void 0)}};var Xt,So=class{#r=0;#l=!1;#i=0;#n=0;#e;#s;#t;#c;#h;#a;#u;#f;#d;#o;color;constructor(t){Xt||(Xt=new on),typeof t=="string"&&(t={text:t}),this.#e={color:"cyan",stream:Kt.stderr,discardStdin:!0,hideCursor:!0,...t},this.color=this.#e.color,this.spinner=this.#e.spinner,this.#h=this.#e.interval,this.#t=this.#e.stream,this.#a=typeof this.#e.isEnabled=="boolean"?this.#e.isEnabled:Tr({stream:this.#t}),this.#u=typeof this.#e.isSilent=="boolean"?this.#e.isSilent:!1,this.text=this.#e.text,this.prefixText=this.#e.prefixText,this.indent=this.#e.indent,Kt.env.NODE_ENV==="test"&&(this._stream=this.#t,this._isEnabled=this.#a,Object.defineProperty(this,"_linesToClear",{get(){return this.#r},set(r){this.#r=r}}),Object.defineProperty(this,"_frameIndex",{get(){return this.#n}}),Object.defineProperty(this,"_lineCount",{get(){return this.#i}}))}get indent(){return this.#f}set indent(t=0){if(!(t>=0&&Number.isInteger(t)))throw new Error("The `indent` option must be an integer from 0 and up");this.#f=t,this.updateLineCount()}get interval(){return this.#h||this.#s.interval||100}get spinner(){return this.#s}set spinner(t){if(this.#n=0,this.#h=void 0,typeof t=="object"){if(t.frames===void 0)throw new Error("The given spinner must have a `frames` property");this.#s=t}else if(!ze())this.#s=ht.default.line;else if(t===void 0)this.#s=ht.default.dots;else if(t!=="default"&&ht.default[t])this.#s=ht.default[t];else throw new Error(`There is no built-in spinner named '${t}'. See https://github.com/sindresorhus/cli-spinners/blob/main/spinners.json for a full list.`)}get text(){return this.#d}set text(t){this.#d=t||"",this.updateLineCount()}get prefixText(){return this.#o}set prefixText(t){this.#o=t||"",this.updateLineCount()}get isSpinning(){return this.#c!==void 0}getFullPrefixText(t=this.#o,r=" "){return typeof t=="string"&&t!==""?t+r:typeof t=="function"?t()+r:""}updateLineCount(){let t=this.#t.columns||80,r=this.getFullPrefixText(this.#o,"-");this.#i=0;for(let n of br(" ".repeat(this.#f)+r+"--"+this.#d).split(`
|
17
|
+
`))this.#i+=Math.max(1,Math.ceil((0,wo.default)(n)/t))}get isEnabled(){return this.#a&&!this.#u}set isEnabled(t){if(typeof t!="boolean")throw new TypeError("The `isEnabled` option must be a boolean");this.#a=t}get isSilent(){return this.#u}set isSilent(t){if(typeof t!="boolean")throw new TypeError("The `isSilent` option must be a boolean");this.#u=t}frame(){let{frames:t}=this.#s,r=t[this.#n];this.color&&(r=H[this.color](r)),this.#n=++this.#n%t.length;let n=typeof this.#o=="string"&&this.#o!==""?this.#o+" ":"",i=typeof this.text=="string"?" "+this.text:"";return n+r+i}clear(){if(!this.#a||!this.#t.isTTY)return this;this.#t.cursorTo(0);for(let t=0;t<this.#r;t++)t>0&&this.#t.moveCursor(0,-1),this.#t.clearLine(1);return(this.#f||this.lastIndent!==this.#f)&&this.#t.cursorTo(this.#f),this.lastIndent=this.#f,this.#r=0,this}render(){return this.#u?this:(this.clear(),this.#t.write(this.frame()),this.#r=this.#i,this)}start(t){return t&&(this.text=t),this.#u?this:this.#a?this.isSpinning?this:(this.#e.hideCursor&&Sr.hide(this.#t),this.#e.discardStdin&&Kt.stdin.isTTY&&(this.#l=!0,Xt.start()),this.render(),this.#c=setInterval(this.render.bind(this),this.interval),this):(this.text&&this.#t.write(`- ${this.text}
|
18
|
+
`),this)}stop(){return this.#a?(clearInterval(this.#c),this.#c=void 0,this.#n=0,this.clear(),this.#e.hideCursor&&Sr.show(this.#t),this.#e.discardStdin&&Kt.stdin.isTTY&&this.#l&&(Xt.stop(),this.#l=!1),this):this}succeed(t){return this.stopAndPersist({symbol:et.success,text:t})}fail(t){return this.stopAndPersist({symbol:et.error,text:t})}warn(t){return this.stopAndPersist({symbol:et.warning,text:t})}info(t){return this.stopAndPersist({symbol:et.info,text:t})}stopAndPersist(t={}){if(this.#u)return this;let r=t.prefixText||this.#o,n=t.text||this.text,i=typeof n=="string"?" "+n:"";return this.stop(),this.#t.write(`${this.getFullPrefixText(r," ")}${t.symbol||" "}${i}
|
19
|
+
`),this}};function sn(e){return new So(e)}a();import{dirname as Cl,resolve as Al}from"path";import{fileURLToPath as Dl}from"url";var Eo={default:[],react:["@tsmodule/react","react","react-dom"]},an={default:["@types/node"],react:["next","@types/react","@types/react-dom","eslint","eslint-config-next","tailwindcss","autoprefixer","cssnano","postcss","postcss-import"]},bo=Al(Cl(Dl(import.meta.url)),"..");a();var Ba=Be(Na(),1);import{resolve as ka}from"path";var bn=async(e,t)=>{let r=ka(bo,`./templates/${e}`),n=ka(t);await(0,Ba.copy)(r,n,{overwrite:!0,recursive:!0})};a();import qa from"fs/promises";import{resolve as Uh}from"path";var Ia=async e=>{let t=Uh(process.cwd(),e,"package.json"),r=await qa.readFile(t,"utf-8"),n=JSON.parse(r);n.name=e,await qa.writeFile(t,JSON.stringify(n,null,2))};globalThis.SHELL_OPTIONS={stdio:["ignore","ignore","inherit"]};var ap=async(e,{react:t=!1})=>{let r=Mn(),n=sn(`Creating new module ${H.blueBright(e)}.`).start();await bn("default",e),t&&await bn("react",e),await Ia(e),n.succeed("Project created."),process.chdir(e);let i=[],o=["@tsmodule/tsmodule"];t?(i.push(...Eo.react),o.push(...an.react)):o.push(...an.default),i.length&&await r.run(`yarn add ${i.join(" ")}`),o.length&&await r.run(`yarn add -D ${o.join(" ")}`),n.succeed("Dependencies installed."),await r.run("git init"),n.succeed("Git initialized.")};export{ap as create};
|
20
|
+
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
@@ -1 +1,10 @@
|
|
1
|
-
|
1
|
+
|
2
|
+
await(async()=>{let{dirname:e}=await import("path"),{fileURLToPath:i}=await import("url");if(typeof globalThis.__filename>"u"&&(globalThis.__filename=i(import.meta.url)),typeof globalThis.__dirname>"u"&&(globalThis.__dirname=e(globalThis.__filename)),typeof globalThis.require>"u"){let{default:a}=await import("module");globalThis.require=a.createRequire(import.meta.url)}})();
|
3
|
+
|
4
|
+
var an=Object.create;var _e=Object.defineProperty;var ln=Object.getOwnPropertyDescriptor;var yn=Object.getOwnPropertyNames;var mn=Object.getPrototypeOf,dn=Object.prototype.hasOwnProperty;var hn=e=>_e(e,"__esModule",{value:!0});var P=(e=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(e,{get:(t,r)=>(typeof require!="undefined"?require:t)[r]}):e)(function(e){if(typeof require!="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});var Sn=(e,t)=>()=>(e&&(t=e(e=0)),t);var w=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var wn=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of yn(t))!dn.call(e,i)&&(r||i!=="default")&&_e(e,i,{get:()=>t[i],enumerable:!(n=ln(t,i))||n.enumerable});return e},pn=(e,t)=>wn(hn(_e(e!=null?an(mn(e)):{},"default",!t&&e&&e.__esModule?{get:()=>e.default,enumerable:!0}:{value:e,enumerable:!0})),e);var f=Sn(()=>{});var W=w(Le=>{"use strict";f();Le.fromCallback=function(e){return Object.defineProperty(function(...t){if(typeof t[t.length-1]=="function")e.apply(this,t);else return new Promise((r,n)=>{e.call(this,...t,(i,o)=>i!=null?n(i):r(o))})},"name",{value:e.name})};Le.fromPromise=function(e){return Object.defineProperty(function(...t){let r=t[t.length-1];if(typeof r!="function")return e.apply(this,t);e.apply(this,t.slice(0,-1)).then(n=>r(null,n),r)},"name",{value:e.name})}});var be=w((Jo,Ze)=>{f();var K=P("constants"),qn=process.cwd,Se=null,Fn=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return Se||(Se=qn.call(process)),Se};try{process.cwd()}catch{}typeof process.chdir=="function"&&(Ie=process.chdir,process.chdir=function(e){Se=null,Ie.call(process,e)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,Ie));var Ie;Ze.exports=xn;function xn(e){K.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&t(e),e.lutimes||r(e),e.chown=o(e.chown),e.fchown=o(e.fchown),e.lchown=o(e.lchown),e.chmod=n(e.chmod),e.fchmod=n(e.fchmod),e.lchmod=n(e.lchmod),e.chownSync=u(e.chownSync),e.fchownSync=u(e.fchownSync),e.lchownSync=u(e.lchownSync),e.chmodSync=i(e.chmodSync),e.fchmodSync=i(e.fchmodSync),e.lchmodSync=i(e.lchmodSync),e.stat=c(e.stat),e.fstat=c(e.fstat),e.lstat=c(e.lstat),e.statSync=a(e.statSync),e.fstatSync=a(e.fstatSync),e.lstatSync=a(e.lstatSync),e.lchmod||(e.lchmod=function(s,y,m){m&&process.nextTick(m)},e.lchmodSync=function(){}),e.lchown||(e.lchown=function(s,y,m,l){l&&process.nextTick(l)},e.lchownSync=function(){}),Fn==="win32"&&(e.rename=function(s){return function(y,m,l){var h=Date.now(),q=0;s(y,m,function p(O){if(O&&(O.code==="EACCES"||O.code==="EPERM")&&Date.now()-h<6e4){setTimeout(function(){e.stat(m,function(T,oe){T&&T.code==="ENOENT"?s(y,m,p):l(O)})},q),q<100&&(q+=10);return}l&&l(O)})}}(e.rename)),e.read=function(s){function y(m,l,h,q,p,O){var T;if(O&&typeof O=="function"){var oe=0;T=function(he,Xe,He){if(he&&he.code==="EAGAIN"&&oe<10)return oe++,s.call(e,m,l,h,q,p,T);O.apply(this,arguments)}}return s.call(e,m,l,h,q,p,T)}return Object.setPrototypeOf&&Object.setPrototypeOf(y,s),y}(e.read),e.readSync=function(s){return function(y,m,l,h,q){for(var p=0;;)try{return s.call(e,y,m,l,h,q)}catch(O){if(O.code==="EAGAIN"&&p<10){p++;continue}throw O}}}(e.readSync);function t(s){s.lchmod=function(y,m,l){s.open(y,K.O_WRONLY|K.O_SYMLINK,m,function(h,q){if(h){l&&l(h);return}s.fchmod(q,m,function(p){s.close(q,function(O){l&&l(p||O)})})})},s.lchmodSync=function(y,m){var l=s.openSync(y,K.O_WRONLY|K.O_SYMLINK,m),h=!0,q;try{q=s.fchmodSync(l,m),h=!1}finally{if(h)try{s.closeSync(l)}catch{}else s.closeSync(l)}return q}}function r(s){K.hasOwnProperty("O_SYMLINK")?(s.lutimes=function(y,m,l,h){s.open(y,K.O_SYMLINK,function(q,p){if(q){h&&h(q);return}s.futimes(p,m,l,function(O){s.close(p,function(T){h&&h(O||T)})})})},s.lutimesSync=function(y,m,l){var h=s.openSync(y,K.O_SYMLINK),q,p=!0;try{q=s.futimesSync(h,m,l),p=!1}finally{if(p)try{s.closeSync(h)}catch{}else s.closeSync(h)}return q}):(s.lutimes=function(y,m,l,h){h&&process.nextTick(h)},s.lutimesSync=function(){})}function n(s){return s&&function(y,m,l){return s.call(e,y,m,function(h){k(h)&&(h=null),l&&l.apply(this,arguments)})}}function i(s){return s&&function(y,m){try{return s.call(e,y,m)}catch(l){if(!k(l))throw l}}}function o(s){return s&&function(y,m,l,h){return s.call(e,y,m,l,function(q){k(q)&&(q=null),h&&h.apply(this,arguments)})}}function u(s){return s&&function(y,m,l){try{return s.call(e,y,m,l)}catch(h){if(!k(h))throw h}}}function c(s){return s&&function(y,m,l){typeof m=="function"&&(l=m,m=null);function h(q,p){p&&(p.uid<0&&(p.uid+=4294967296),p.gid<0&&(p.gid+=4294967296)),l&&l.apply(this,arguments)}return m?s.call(e,y,m,h):s.call(e,y,h)}}function a(s){return s&&function(y,m){var l=m?s.call(e,y,m):s.call(e,y);return l&&(l.uid<0&&(l.uid+=4294967296),l.gid<0&&(l.gid+=4294967296)),l}}function k(s){if(!s||s.code==="ENOSYS")return!0;var y=!process.getuid||process.getuid()!==0;return!!(y&&(s.code==="EINVAL"||s.code==="EPERM"))}}});var rt=w((Bo,tt)=>{f();var et=P("stream").Stream;tt.exports=gn;function gn(e){return{ReadStream:t,WriteStream:r};function t(n,i){if(!(this instanceof t))return new t(n,i);et.call(this);var o=this;this.path=n,this.fd=null,this.readable=!0,this.paused=!1,this.flags="r",this.mode=438,this.bufferSize=64*1024,i=i||{};for(var u=Object.keys(i),c=0,a=u.length;c<a;c++){var k=u[c];this[k]=i[k]}if(this.encoding&&this.setEncoding(this.encoding),this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw TypeError("end must be a Number");if(this.start>this.end)throw new Error("start must be <= end");this.pos=this.start}if(this.fd!==null){process.nextTick(function(){o._read()});return}e.open(this.path,this.flags,this.mode,function(s,y){if(s){o.emit("error",s),o.readable=!1;return}o.fd=y,o.emit("open",y),o._read()})}function r(n,i){if(!(this instanceof r))return new r(n,i);et.call(this),this.path=n,this.fd=null,this.writable=!0,this.flags="w",this.encoding="binary",this.mode=438,this.bytesWritten=0,i=i||{};for(var o=Object.keys(i),u=0,c=o.length;u<c;u++){var a=o[u];this[a]=i[a]}if(this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.start<0)throw new Error("start must be >= zero");this.pos=this.start}this.busy=!1,this._queue=[],this.fd===null&&(this._open=e.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}});var it=w((Uo,nt)=>{"use strict";f();nt.exports=On;var Pn=Object.getPrototypeOf||function(e){return e.__proto__};function On(e){if(e===null||typeof e!="object")return e;if(e instanceof Object)var t={__proto__:Pn(e)};else var t=Object.create(null);return Object.getOwnPropertyNames(e).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r))}),t}});var M=w((Yo,je)=>{f();var g=P("fs"),Dn=be(),Nn=rt(),Tn=it(),we=P("util"),R,Ee;typeof Symbol=="function"&&typeof Symbol.for=="function"?(R=Symbol.for("graceful-fs.queue"),Ee=Symbol.for("graceful-fs.previous")):(R="___graceful-fs.queue",Ee="___graceful-fs.previous");function Cn(){}function ct(e,t){Object.defineProperty(e,R,{get:function(){return t}})}var Z=Cn;we.debuglog?Z=we.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(Z=function(){var e=we.format.apply(we,arguments);e="GFS4: "+e.split(/\n/).join(`
|
5
|
+
GFS4: `),console.error(e)});g[R]||(ot=global[R]||[],ct(g,ot),g.close=function(e){function t(r,n){return e.call(g,r,function(i){i||ut(),typeof n=="function"&&n.apply(this,arguments)})}return Object.defineProperty(t,Ee,{value:e}),t}(g.close),g.closeSync=function(e){function t(r){e.apply(g,arguments),ut()}return Object.defineProperty(t,Ee,{value:e}),t}(g.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){Z(g[R]),P("assert").equal(g[R].length,0)}));var ot;global[R]||ct(global,g[R]);je.exports=Re(Tn(g));process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!g.__patched&&(je.exports=Re(g),g.__patched=!0);function Re(e){Dn(e),e.gracefulify=Re,e.createReadStream=he,e.createWriteStream=Xe;var t=e.readFile;e.readFile=r;function r(d,v,E){return typeof v=="function"&&(E=v,v=null),_(d,v,E);function _(L,I,D,j){return t(L,I,function(x){x&&(x.code==="EMFILE"||x.code==="ENFILE")?te([_,[L,I,D],x,j||Date.now(),Date.now()]):typeof D=="function"&&D.apply(this,arguments)})}}var n=e.writeFile;e.writeFile=i;function i(d,v,E,_){return typeof E=="function"&&(_=E,E=null),L(d,v,E,_);function L(I,D,j,x,U){return n(I,D,j,function(N){N&&(N.code==="EMFILE"||N.code==="ENFILE")?te([L,[I,D,j,x],N,U||Date.now(),Date.now()]):typeof x=="function"&&x.apply(this,arguments)})}}var o=e.appendFile;o&&(e.appendFile=u);function u(d,v,E,_){return typeof E=="function"&&(_=E,E=null),L(d,v,E,_);function L(I,D,j,x,U){return o(I,D,j,function(N){N&&(N.code==="EMFILE"||N.code==="ENFILE")?te([L,[I,D,j,x],N,U||Date.now(),Date.now()]):typeof x=="function"&&x.apply(this,arguments)})}}var c=e.copyFile;c&&(e.copyFile=a);function a(d,v,E,_){return typeof E=="function"&&(_=E,E=0),L(d,v,E,_);function L(I,D,j,x,U){return c(I,D,j,function(N){N&&(N.code==="EMFILE"||N.code==="ENFILE")?te([L,[I,D,j,x],N,U||Date.now(),Date.now()]):typeof x=="function"&&x.apply(this,arguments)})}}var k=e.readdir;e.readdir=s;function s(d,v,E){return typeof v=="function"&&(E=v,v=null),_(d,v,E);function _(L,I,D,j){return k(L,I,function(x,U){x&&(x.code==="EMFILE"||x.code==="ENFILE")?te([_,[L,I,D],x,j||Date.now(),Date.now()]):(U&&U.sort&&U.sort(),typeof D=="function"&&D.call(this,x,U))})}}if(process.version.substr(0,4)==="v0.8"){var y=Nn(e);p=y.ReadStream,T=y.WriteStream}var m=e.ReadStream;m&&(p.prototype=Object.create(m.prototype),p.prototype.open=O);var l=e.WriteStream;l&&(T.prototype=Object.create(l.prototype),T.prototype.open=oe),Object.defineProperty(e,"ReadStream",{get:function(){return p},set:function(d){p=d},enumerable:!0,configurable:!0}),Object.defineProperty(e,"WriteStream",{get:function(){return T},set:function(d){T=d},enumerable:!0,configurable:!0});var h=p;Object.defineProperty(e,"FileReadStream",{get:function(){return h},set:function(d){h=d},enumerable:!0,configurable:!0});var q=T;Object.defineProperty(e,"FileWriteStream",{get:function(){return q},set:function(d){q=d},enumerable:!0,configurable:!0});function p(d,v){return this instanceof p?(m.apply(this,arguments),this):p.apply(Object.create(p.prototype),arguments)}function O(){var d=this;Ce(d.path,d.flags,d.mode,function(v,E){v?(d.autoClose&&d.destroy(),d.emit("error",v)):(d.fd=E,d.emit("open",E),d.read())})}function T(d,v){return this instanceof T?(l.apply(this,arguments),this):T.apply(Object.create(T.prototype),arguments)}function oe(){var d=this;Ce(d.path,d.flags,d.mode,function(v,E){v?(d.destroy(),d.emit("error",v)):(d.fd=E,d.emit("open",E))})}function he(d,v){return new e.ReadStream(d,v)}function Xe(d,v){return new e.WriteStream(d,v)}var He=e.open;e.open=Ce;function Ce(d,v,E,_){return typeof E=="function"&&(_=E,E=null),L(d,v,E,_);function L(I,D,j,x,U){return He(I,D,j,function(N,Lo){N&&(N.code==="EMFILE"||N.code==="ENFILE")?te([L,[I,D,j,x],N,U||Date.now(),Date.now()]):typeof x=="function"&&x.apply(this,arguments)})}}return e}function te(e){Z("ENQUEUE",e[0].name,e[1]),g[R].push(e),$e()}var pe;function ut(){for(var e=Date.now(),t=0;t<g[R].length;++t)g[R][t].length>2&&(g[R][t][3]=e,g[R][t][4]=e);$e()}function $e(){if(clearTimeout(pe),pe=void 0,g[R].length!==0){var e=g[R].shift(),t=e[0],r=e[1],n=e[2],i=e[3],o=e[4];if(i===void 0)Z("RETRY",t.name,r),t.apply(null,r);else if(Date.now()-i>=6e4){Z("TIMEOUT",t.name,r);var u=r.pop();typeof u=="function"&&u.call(null,n)}else{var c=Date.now()-o,a=Math.max(o-i,1),k=Math.min(a*1.2,100);c>=k?(Z("RETRY",t.name,r),t.apply(null,r.concat([i]))):g[R].push(e)}pe===void 0&&(pe=setTimeout($e,0))}}});var b=w(V=>{"use strict";f();var st=W().fromCallback,B=M(),_n=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter(e=>typeof B[e]=="function");Object.assign(V,B);_n.forEach(e=>{V[e]=st(B[e])});V.realpath.native=st(B.realpath.native);V.exists=function(e,t){return typeof t=="function"?B.exists(e,t):new Promise(r=>B.exists(e,r))};V.read=function(e,t,r,n,i,o){return typeof o=="function"?B.read(e,t,r,n,i,o):new Promise((u,c)=>{B.read(e,t,r,n,i,(a,k,s)=>{if(a)return c(a);u({bytesRead:k,buffer:s})})})};V.write=function(e,t,...r){return typeof r[r.length-1]=="function"?B.write(e,t,...r):new Promise((n,i)=>{B.write(e,t,...r,(o,u,c)=>{if(o)return i(o);n({bytesWritten:u,buffer:c})})})};typeof B.writev=="function"&&(V.writev=function(e,t,...r){return typeof r[r.length-1]=="function"?B.writev(e,t,...r):new Promise((n,i)=>{B.writev(e,t,...r,(o,u,c)=>{if(o)return i(o);n({bytesWritten:u,buffers:c})})})})});var at=w((Ko,ft)=>{"use strict";f();var Ln=P("path");ft.exports.checkPath=function(t){if(process.platform==="win32"&&/[<>:"|?*]/.test(t.replace(Ln.parse(t).root,""))){let n=new Error(`Path contains invalid characters: ${t}`);throw n.code="EINVAL",n}}});var dt=w((Vo,Me)=>{"use strict";f();var lt=b(),{checkPath:yt}=at(),mt=e=>{let t={mode:511};return typeof e=="number"?e:{...t,...e}.mode};Me.exports.makeDir=async(e,t)=>(yt(e),lt.mkdir(e,{mode:mt(t),recursive:!0}));Me.exports.makeDirSync=(e,t)=>(yt(e),lt.mkdirSync(e,{mode:mt(t),recursive:!0}))});var Y=w((Qo,ht)=>{"use strict";f();var In=W().fromPromise,{makeDir:Rn,makeDirSync:Ae}=dt(),We=In(Rn);ht.exports={mkdirs:We,mkdirsSync:Ae,mkdirp:We,mkdirpSync:Ae,ensureDir:We,ensureDirSync:Ae}});var Q=w((Xo,wt)=>{"use strict";f();var $n=W().fromPromise,St=b();function jn(e){return St.access(e).then(()=>!0).catch(()=>!1)}wt.exports={pathExists:$n(jn),pathExistsSync:St.existsSync}});var Je=w((Ho,pt)=>{"use strict";f();var re=M();function Mn(e,t,r,n){re.open(e,"r+",(i,o)=>{if(i)return n(i);re.futimes(o,t,r,u=>{re.close(o,c=>{n&&n(u||c)})})})}function An(e,t,r){let n=re.openSync(e,"r+");return re.futimesSync(n,t,r),re.closeSync(n)}pt.exports={utimesMillis:Mn,utimesMillisSync:An}});var ee=w((zo,kt)=>{"use strict";f();var ne=b(),C=P("path"),Wn=P("util");function Jn(e,t,r){let n=r.dereference?i=>ne.stat(i,{bigint:!0}):i=>ne.lstat(i,{bigint:!0});return Promise.all([n(e),n(t).catch(i=>{if(i.code==="ENOENT")return null;throw i})]).then(([i,o])=>({srcStat:i,destStat:o}))}function Bn(e,t,r){let n,i=r.dereference?u=>ne.statSync(u,{bigint:!0}):u=>ne.lstatSync(u,{bigint:!0}),o=i(e);try{n=i(t)}catch(u){if(u.code==="ENOENT")return{srcStat:o,destStat:null};throw u}return{srcStat:o,destStat:n}}function Un(e,t,r,n,i){Wn.callbackify(Jn)(e,t,n,(o,u)=>{if(o)return i(o);let{srcStat:c,destStat:a}=u;if(a){if(ue(c,a)){let k=C.basename(e),s=C.basename(t);return r==="move"&&k!==s&&k.toLowerCase()===s.toLowerCase()?i(null,{srcStat:c,destStat:a,isChangingCase:!0}):i(new Error("Source and destination must not be the same."))}if(c.isDirectory()&&!a.isDirectory())return i(new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`));if(!c.isDirectory()&&a.isDirectory())return i(new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`))}return c.isDirectory()&&Be(e,t)?i(new Error(ve(e,t,r))):i(null,{srcStat:c,destStat:a})})}function Yn(e,t,r,n){let{srcStat:i,destStat:o}=Bn(e,t,n);if(o){if(ue(i,o)){let u=C.basename(e),c=C.basename(t);if(r==="move"&&u!==c&&u.toLowerCase()===c.toLowerCase())return{srcStat:i,destStat:o,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(i.isDirectory()&&!o.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!i.isDirectory()&&o.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(i.isDirectory()&&Be(e,t))throw new Error(ve(e,t,r));return{srcStat:i,destStat:o}}function Et(e,t,r,n,i){let o=C.resolve(C.dirname(e)),u=C.resolve(C.dirname(r));if(u===o||u===C.parse(u).root)return i();ne.stat(u,{bigint:!0},(c,a)=>c?c.code==="ENOENT"?i():i(c):ue(t,a)?i(new Error(ve(e,r,n))):Et(e,t,u,n,i))}function vt(e,t,r,n){let i=C.resolve(C.dirname(e)),o=C.resolve(C.dirname(r));if(o===i||o===C.parse(o).root)return;let u;try{u=ne.statSync(o,{bigint:!0})}catch(c){if(c.code==="ENOENT")return;throw c}if(ue(t,u))throw new Error(ve(e,r,n));return vt(e,t,o,n)}function ue(e,t){return t.ino&&t.dev&&t.ino===e.ino&&t.dev===e.dev}function Be(e,t){let r=C.resolve(e).split(C.sep).filter(i=>i),n=C.resolve(t).split(C.sep).filter(i=>i);return r.reduce((i,o,u)=>i&&n[u]===o,!0)}function ve(e,t,r){return`Cannot ${r} '${e}' to a subdirectory of itself, '${t}'.`}kt.exports={checkPaths:Un,checkPathsSync:Yn,checkParentPaths:Et,checkParentPathsSync:vt,isSrcSubdir:Be,areIdentical:ue}});var Nt=w((Zo,Dt)=>{"use strict";f();var J=M(),ce=P("path"),Gn=Y().mkdirs,Kn=Q().pathExists,Vn=Je().utimesMillis,se=ee();function Qn(e,t,r,n){typeof r=="function"&&!n?(n=r,r={}):typeof r=="function"&&(r={filter:r}),n=n||function(){},r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;
|
6
|
+
|
7
|
+
see https://github.com/jprichardson/node-fs-extra/issues/269`),se.checkPaths(e,t,"copy",r,(i,o)=>{if(i)return n(i);let{srcStat:u,destStat:c}=o;se.checkParentPaths(e,u,t,"copy",a=>a?n(a):r.filter?xt(qt,c,e,t,r,n):qt(c,e,t,r,n))})}function qt(e,t,r,n,i){let o=ce.dirname(r);Kn(o,(u,c)=>{if(u)return i(u);if(c)return ke(e,t,r,n,i);Gn(o,a=>a?i(a):ke(e,t,r,n,i))})}function xt(e,t,r,n,i,o){Promise.resolve(i.filter(r,n)).then(u=>u?e(t,r,n,i,o):o(),u=>o(u))}function Xn(e,t,r,n,i){return n.filter?xt(ke,e,t,r,n,i):ke(e,t,r,n,i)}function ke(e,t,r,n,i){(n.dereference?J.stat:J.lstat)(t,(u,c)=>u?i(u):c.isDirectory()?ri(c,e,t,r,n,i):c.isFile()||c.isCharacterDevice()||c.isBlockDevice()?Hn(c,e,t,r,n,i):c.isSymbolicLink()?oi(e,t,r,n,i):c.isSocket()?i(new Error(`Cannot copy a socket file: ${t}`)):c.isFIFO()?i(new Error(`Cannot copy a FIFO pipe: ${t}`)):i(new Error(`Unknown file: ${t}`)))}function Hn(e,t,r,n,i,o){return t?zn(e,r,n,i,o):gt(e,r,n,i,o)}function zn(e,t,r,n,i){if(n.overwrite)J.unlink(r,o=>o?i(o):gt(e,t,r,n,i));else return n.errorOnExist?i(new Error(`'${r}' already exists`)):i()}function gt(e,t,r,n,i){J.copyFile(t,r,o=>o?i(o):n.preserveTimestamps?Zn(e.mode,t,r,i):qe(r,e.mode,i))}function Zn(e,t,r,n){return bn(e)?ei(r,e,i=>i?n(i):Ft(e,t,r,n)):Ft(e,t,r,n)}function bn(e){return(e&128)===0}function ei(e,t,r){return qe(e,t|128,r)}function Ft(e,t,r,n){ti(t,r,i=>i?n(i):qe(r,e,n))}function qe(e,t,r){return J.chmod(e,t,r)}function ti(e,t,r){J.stat(e,(n,i)=>n?r(n):Vn(t,i.atime,i.mtime,r))}function ri(e,t,r,n,i,o){return t?Pt(r,n,i,o):ni(e.mode,r,n,i,o)}function ni(e,t,r,n,i){J.mkdir(r,o=>{if(o)return i(o);Pt(t,r,n,u=>u?i(u):qe(r,e,i))})}function Pt(e,t,r,n){J.readdir(e,(i,o)=>i?n(i):Ot(o,e,t,r,n))}function Ot(e,t,r,n,i){let o=e.pop();return o?ii(e,o,t,r,n,i):i()}function ii(e,t,r,n,i,o){let u=ce.join(r,t),c=ce.join(n,t);se.checkPaths(u,c,"copy",i,(a,k)=>{if(a)return o(a);let{destStat:s}=k;Xn(s,u,c,i,y=>y?o(y):Ot(e,r,n,i,o))})}function oi(e,t,r,n,i){J.readlink(t,(o,u)=>{if(o)return i(o);if(n.dereference&&(u=ce.resolve(process.cwd(),u)),e)J.readlink(r,(c,a)=>c?c.code==="EINVAL"||c.code==="UNKNOWN"?J.symlink(u,r,i):i(c):(n.dereference&&(a=ce.resolve(process.cwd(),a)),se.isSrcSubdir(u,a)?i(new Error(`Cannot copy '${u}' to a subdirectory of itself, '${a}'.`)):e.isDirectory()&&se.isSrcSubdir(a,u)?i(new Error(`Cannot overwrite '${a}' with '${u}'.`)):ui(u,r,i)));else return J.symlink(u,r,i)})}function ui(e,t,r){J.unlink(t,n=>n?r(n):J.symlink(e,t,r))}Dt.exports=Qn});var It=w((bo,Lt)=>{"use strict";f();var $=M(),fe=P("path"),ci=Y().mkdirsSync,si=Je().utimesMillisSync,ae=ee();function fi(e,t,r){typeof r=="function"&&(r={filter:r}),r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;
|
8
|
+
|
9
|
+
see https://github.com/jprichardson/node-fs-extra/issues/269`);let{srcStat:n,destStat:i}=ae.checkPathsSync(e,t,"copy",r);return ae.checkParentPathsSync(e,n,t,"copy"),ai(i,e,t,r)}function ai(e,t,r,n){if(n.filter&&!n.filter(t,r))return;let i=fe.dirname(r);return $.existsSync(i)||ci(i),Tt(e,t,r,n)}function li(e,t,r,n){if(!(n.filter&&!n.filter(t,r)))return Tt(e,t,r,n)}function Tt(e,t,r,n){let o=(n.dereference?$.statSync:$.lstatSync)(t);if(o.isDirectory())return pi(o,e,t,r,n);if(o.isFile()||o.isCharacterDevice()||o.isBlockDevice())return yi(o,e,t,r,n);if(o.isSymbolicLink())return ki(e,t,r,n);throw o.isSocket()?new Error(`Cannot copy a socket file: ${t}`):o.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}function yi(e,t,r,n,i){return t?mi(e,r,n,i):Ct(e,r,n,i)}function mi(e,t,r,n){if(n.overwrite)return $.unlinkSync(r),Ct(e,t,r,n);if(n.errorOnExist)throw new Error(`'${r}' already exists`)}function Ct(e,t,r,n){return $.copyFileSync(t,r),n.preserveTimestamps&&di(e.mode,t,r),Ue(r,e.mode)}function di(e,t,r){return hi(e)&&Si(r,e),wi(t,r)}function hi(e){return(e&128)===0}function Si(e,t){return Ue(e,t|128)}function Ue(e,t){return $.chmodSync(e,t)}function wi(e,t){let r=$.statSync(e);return si(t,r.atime,r.mtime)}function pi(e,t,r,n,i){return t?_t(r,n,i):Ei(e.mode,r,n,i)}function Ei(e,t,r,n){return $.mkdirSync(r),_t(t,r,n),Ue(r,e)}function _t(e,t,r){$.readdirSync(e).forEach(n=>vi(n,e,t,r))}function vi(e,t,r,n){let i=fe.join(t,e),o=fe.join(r,e),{destStat:u}=ae.checkPathsSync(i,o,"copy",n);return li(u,i,o,n)}function ki(e,t,r,n){let i=$.readlinkSync(t);if(n.dereference&&(i=fe.resolve(process.cwd(),i)),e){let o;try{o=$.readlinkSync(r)}catch(u){if(u.code==="EINVAL"||u.code==="UNKNOWN")return $.symlinkSync(i,r);throw u}if(n.dereference&&(o=fe.resolve(process.cwd(),o)),ae.isSrcSubdir(i,o))throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${o}'.`);if($.statSync(r).isDirectory()&&ae.isSrcSubdir(o,i))throw new Error(`Cannot overwrite '${o}' with '${i}'.`);return qi(i,r)}else return $.symlinkSync(i,r)}function qi(e,t){return $.unlinkSync(t),$.symlinkSync(e,t)}Lt.exports=fi});var Fe=w((eu,Rt)=>{"use strict";f();var Fi=W().fromCallback;Rt.exports={copy:Fi(Nt()),copySync:It()}});var Yt=w((tu,Ut)=>{"use strict";f();var $t=M(),Wt=P("path"),F=P("assert"),le=process.platform==="win32";function Jt(e){["unlink","chmod","stat","lstat","rmdir","readdir"].forEach(r=>{e[r]=e[r]||$t[r],r=r+"Sync",e[r]=e[r]||$t[r]}),e.maxBusyTries=e.maxBusyTries||3}function Ye(e,t,r){let n=0;typeof t=="function"&&(r=t,t={}),F(e,"rimraf: missing path"),F.strictEqual(typeof e,"string","rimraf: path should be a string"),F.strictEqual(typeof r,"function","rimraf: callback function required"),F(t,"rimraf: invalid options argument provided"),F.strictEqual(typeof t,"object","rimraf: options should be object"),Jt(t),jt(e,t,function i(o){if(o){if((o.code==="EBUSY"||o.code==="ENOTEMPTY"||o.code==="EPERM")&&n<t.maxBusyTries){n++;let u=n*100;return setTimeout(()=>jt(e,t,i),u)}o.code==="ENOENT"&&(o=null)}r(o)})}function jt(e,t,r){F(e),F(t),F(typeof r=="function"),t.lstat(e,(n,i)=>{if(n&&n.code==="ENOENT")return r(null);if(n&&n.code==="EPERM"&&le)return Mt(e,t,n,r);if(i&&i.isDirectory())return xe(e,t,n,r);t.unlink(e,o=>{if(o){if(o.code==="ENOENT")return r(null);if(o.code==="EPERM")return le?Mt(e,t,o,r):xe(e,t,o,r);if(o.code==="EISDIR")return xe(e,t,o,r)}return r(o)})})}function Mt(e,t,r,n){F(e),F(t),F(typeof n=="function"),t.chmod(e,438,i=>{i?n(i.code==="ENOENT"?null:r):t.stat(e,(o,u)=>{o?n(o.code==="ENOENT"?null:r):u.isDirectory()?xe(e,t,r,n):t.unlink(e,n)})})}function At(e,t,r){let n;F(e),F(t);try{t.chmodSync(e,438)}catch(i){if(i.code==="ENOENT")return;throw r}try{n=t.statSync(e)}catch(i){if(i.code==="ENOENT")return;throw r}n.isDirectory()?ge(e,t,r):t.unlinkSync(e)}function xe(e,t,r,n){F(e),F(t),F(typeof n=="function"),t.rmdir(e,i=>{i&&(i.code==="ENOTEMPTY"||i.code==="EEXIST"||i.code==="EPERM")?xi(e,t,n):i&&i.code==="ENOTDIR"?n(r):n(i)})}function xi(e,t,r){F(e),F(t),F(typeof r=="function"),t.readdir(e,(n,i)=>{if(n)return r(n);let o=i.length,u;if(o===0)return t.rmdir(e,r);i.forEach(c=>{Ye(Wt.join(e,c),t,a=>{if(!u){if(a)return r(u=a);--o===0&&t.rmdir(e,r)}})})})}function Bt(e,t){let r;t=t||{},Jt(t),F(e,"rimraf: missing path"),F.strictEqual(typeof e,"string","rimraf: path should be a string"),F(t,"rimraf: missing options"),F.strictEqual(typeof t,"object","rimraf: options should be object");try{r=t.lstatSync(e)}catch(n){if(n.code==="ENOENT")return;n.code==="EPERM"&&le&&At(e,t,n)}try{r&&r.isDirectory()?ge(e,t,null):t.unlinkSync(e)}catch(n){if(n.code==="ENOENT")return;if(n.code==="EPERM")return le?At(e,t,n):ge(e,t,n);if(n.code!=="EISDIR")throw n;ge(e,t,n)}}function ge(e,t,r){F(e),F(t);try{t.rmdirSync(e)}catch(n){if(n.code==="ENOTDIR")throw r;if(n.code==="ENOTEMPTY"||n.code==="EEXIST"||n.code==="EPERM")gi(e,t);else if(n.code!=="ENOENT")throw n}}function gi(e,t){if(F(e),F(t),t.readdirSync(e).forEach(r=>Bt(Wt.join(e,r),t)),le){let r=Date.now();do try{return t.rmdirSync(e,t)}catch{}while(Date.now()-r<500)}else return t.rmdirSync(e,t)}Ut.exports=Ye;Ye.sync=Bt});var ye=w((ru,Kt)=>{"use strict";f();var Pe=M(),Pi=W().fromCallback,Gt=Yt();function Oi(e,t){if(Pe.rm)return Pe.rm(e,{recursive:!0,force:!0},t);Gt(e,t)}function Di(e){if(Pe.rmSync)return Pe.rmSync(e,{recursive:!0,force:!0});Gt.sync(e)}Kt.exports={remove:Pi(Oi),removeSync:Di}});var er=w((nu,bt)=>{"use strict";f();var Ni=W().fromPromise,Xt=b(),Ht=P("path"),zt=Y(),Zt=ye(),Vt=Ni(async function(t){let r;try{r=await Xt.readdir(t)}catch{return zt.mkdirs(t)}return Promise.all(r.map(n=>Zt.remove(Ht.join(t,n))))});function Qt(e){let t;try{t=Xt.readdirSync(e)}catch{return zt.mkdirsSync(e)}t.forEach(r=>{r=Ht.join(e,r),Zt.removeSync(r)})}bt.exports={emptyDirSync:Qt,emptydirSync:Qt,emptyDir:Vt,emptydir:Vt}});var ir=w((iu,nr)=>{"use strict";f();var Ti=W().fromCallback,tr=P("path"),X=M(),rr=Y();function Ci(e,t){function r(){X.writeFile(e,"",n=>{if(n)return t(n);t()})}X.stat(e,(n,i)=>{if(!n&&i.isFile())return t();let o=tr.dirname(e);X.stat(o,(u,c)=>{if(u)return u.code==="ENOENT"?rr.mkdirs(o,a=>{if(a)return t(a);r()}):t(u);c.isDirectory()?r():X.readdir(o,a=>{if(a)return t(a)})})})}function _i(e){let t;try{t=X.statSync(e)}catch{}if(t&&t.isFile())return;let r=tr.dirname(e);try{X.statSync(r).isDirectory()||X.readdirSync(r)}catch(n){if(n&&n.code==="ENOENT")rr.mkdirsSync(r);else throw n}X.writeFileSync(e,"")}nr.exports={createFile:Ti(Ci),createFileSync:_i}});var fr=w((ou,sr)=>{"use strict";f();var Li=W().fromCallback,or=P("path"),H=M(),ur=Y(),Ii=Q().pathExists,{areIdentical:cr}=ee();function Ri(e,t,r){function n(i,o){H.link(i,o,u=>{if(u)return r(u);r(null)})}H.lstat(t,(i,o)=>{H.lstat(e,(u,c)=>{if(u)return u.message=u.message.replace("lstat","ensureLink"),r(u);if(o&&cr(c,o))return r(null);let a=or.dirname(t);Ii(a,(k,s)=>{if(k)return r(k);if(s)return n(e,t);ur.mkdirs(a,y=>{if(y)return r(y);n(e,t)})})})})}function $i(e,t){let r;try{r=H.lstatSync(t)}catch{}try{let o=H.lstatSync(e);if(r&&cr(o,r))return}catch(o){throw o.message=o.message.replace("lstat","ensureLink"),o}let n=or.dirname(t);return H.existsSync(n)||ur.mkdirsSync(n),H.linkSync(e,t)}sr.exports={createLink:Li(Ri),createLinkSync:$i}});var lr=w((uu,ar)=>{"use strict";f();var z=P("path"),me=M(),ji=Q().pathExists;function Mi(e,t,r){if(z.isAbsolute(e))return me.lstat(e,n=>n?(n.message=n.message.replace("lstat","ensureSymlink"),r(n)):r(null,{toCwd:e,toDst:e}));{let n=z.dirname(t),i=z.join(n,e);return ji(i,(o,u)=>o?r(o):u?r(null,{toCwd:i,toDst:e}):me.lstat(e,c=>c?(c.message=c.message.replace("lstat","ensureSymlink"),r(c)):r(null,{toCwd:e,toDst:z.relative(n,e)})))}}function Ai(e,t){let r;if(z.isAbsolute(e)){if(r=me.existsSync(e),!r)throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}else{let n=z.dirname(t),i=z.join(n,e);if(r=me.existsSync(i),r)return{toCwd:i,toDst:e};if(r=me.existsSync(e),!r)throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:z.relative(n,e)}}}ar.exports={symlinkPaths:Mi,symlinkPathsSync:Ai}});var dr=w((cu,mr)=>{"use strict";f();var yr=M();function Wi(e,t,r){if(r=typeof t=="function"?t:r,t=typeof t=="function"?!1:t,t)return r(null,t);yr.lstat(e,(n,i)=>{if(n)return r(null,"file");t=i&&i.isDirectory()?"dir":"file",r(null,t)})}function Ji(e,t){let r;if(t)return t;try{r=yr.lstatSync(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}mr.exports={symlinkType:Wi,symlinkTypeSync:Ji}});var qr=w((su,kr)=>{"use strict";f();var Bi=W().fromCallback,Sr=P("path"),G=b(),wr=Y(),Ui=wr.mkdirs,Yi=wr.mkdirsSync,pr=lr(),Gi=pr.symlinkPaths,Ki=pr.symlinkPathsSync,Er=dr(),Vi=Er.symlinkType,Qi=Er.symlinkTypeSync,Xi=Q().pathExists,{areIdentical:vr}=ee();function Hi(e,t,r,n){n=typeof r=="function"?r:n,r=typeof r=="function"?!1:r,G.lstat(t,(i,o)=>{!i&&o.isSymbolicLink()?Promise.all([G.stat(e),G.stat(t)]).then(([u,c])=>{if(vr(u,c))return n(null);hr(e,t,r,n)}):hr(e,t,r,n)})}function hr(e,t,r,n){Gi(e,t,(i,o)=>{if(i)return n(i);e=o.toDst,Vi(o.toCwd,r,(u,c)=>{if(u)return n(u);let a=Sr.dirname(t);Xi(a,(k,s)=>{if(k)return n(k);if(s)return G.symlink(e,t,c,n);Ui(a,y=>{if(y)return n(y);G.symlink(e,t,c,n)})})})})}function zi(e,t,r){let n;try{n=G.lstatSync(t)}catch{}if(n&&n.isSymbolicLink()){let c=G.statSync(e),a=G.statSync(t);if(vr(c,a))return}let i=Ki(e,t);e=i.toDst,r=Qi(i.toCwd,r);let o=Sr.dirname(t);return G.existsSync(o)||Yi(o),G.symlinkSync(e,t,r)}kr.exports={createSymlink:Bi(Hi),createSymlinkSync:zi}});var Tr=w((fu,Nr)=>{"use strict";f();var{createFile:Fr,createFileSync:xr}=ir(),{createLink:gr,createLinkSync:Pr}=fr(),{createSymlink:Or,createSymlinkSync:Dr}=qr();Nr.exports={createFile:Fr,createFileSync:xr,ensureFile:Fr,ensureFileSync:xr,createLink:gr,createLinkSync:Pr,ensureLink:gr,ensureLinkSync:Pr,createSymlink:Or,createSymlinkSync:Dr,ensureSymlink:Or,ensureSymlinkSync:Dr}});var Oe=w((au,Cr)=>{f();function Zi(e,{EOL:t=`
|
10
|
+
`,finalEOL:r=!0,replacer:n=null,spaces:i}={}){let o=r?t:"";return JSON.stringify(e,n,i).replace(/\n/g,t)+o}function bi(e){return Buffer.isBuffer(e)&&(e=e.toString("utf8")),e.replace(/^\uFEFF/,"")}Cr.exports={stringify:Zi,stripBom:bi}});var Rr=w((lu,Ir)=>{f();var ie;try{ie=M()}catch{ie=P("fs")}var De=W(),{stringify:_r,stripBom:Lr}=Oe();async function eo(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||ie,n="throws"in t?t.throws:!0,i=await De.fromCallback(r.readFile)(e,t);i=Lr(i);let o;try{o=JSON.parse(i,t?t.reviver:null)}catch(u){if(n)throw u.message=`${e}: ${u.message}`,u;return null}return o}var to=De.fromPromise(eo);function ro(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||ie,n="throws"in t?t.throws:!0;try{let i=r.readFileSync(e,t);return i=Lr(i),JSON.parse(i,t.reviver)}catch(i){if(n)throw i.message=`${e}: ${i.message}`,i;return null}}async function no(e,t,r={}){let n=r.fs||ie,i=_r(t,r);await De.fromCallback(n.writeFile)(e,i,r)}var io=De.fromPromise(no);function oo(e,t,r={}){let n=r.fs||ie,i=_r(t,r);return n.writeFileSync(e,i,r)}var uo={readFile:to,readFileSync:ro,writeFile:io,writeFileSync:oo};Ir.exports=uo});var jr=w((yu,$r)=>{"use strict";f();var Ne=Rr();$r.exports={readJson:Ne.readFile,readJsonSync:Ne.readFileSync,writeJson:Ne.writeFile,writeJsonSync:Ne.writeFileSync}});var Te=w((mu,Wr)=>{"use strict";f();var co=W().fromCallback,de=M(),Mr=P("path"),Ar=Y(),so=Q().pathExists;function fo(e,t,r,n){typeof r=="function"&&(n=r,r="utf8");let i=Mr.dirname(e);so(i,(o,u)=>{if(o)return n(o);if(u)return de.writeFile(e,t,r,n);Ar.mkdirs(i,c=>{if(c)return n(c);de.writeFile(e,t,r,n)})})}function ao(e,...t){let r=Mr.dirname(e);if(de.existsSync(r))return de.writeFileSync(e,...t);Ar.mkdirsSync(r),de.writeFileSync(e,...t)}Wr.exports={outputFile:co(fo),outputFileSync:ao}});var Br=w((du,Jr)=>{"use strict";f();var{stringify:lo}=Oe(),{outputFile:yo}=Te();async function mo(e,t,r={}){let n=lo(t,r);await yo(e,n,r)}Jr.exports=mo});var Yr=w((hu,Ur)=>{"use strict";f();var{stringify:ho}=Oe(),{outputFileSync:So}=Te();function wo(e,t,r){let n=ho(t,r);So(e,n,r)}Ur.exports=wo});var Kr=w((Su,Gr)=>{"use strict";f();var po=W().fromPromise,A=jr();A.outputJson=po(Br());A.outputJsonSync=Yr();A.outputJSON=A.outputJson;A.outputJSONSync=A.outputJsonSync;A.writeJSON=A.writeJson;A.writeJSONSync=A.writeJsonSync;A.readJSON=A.readJson;A.readJSONSync=A.readJsonSync;Gr.exports=A});var zr=w((wu,Hr)=>{"use strict";f();var Eo=M(),Ke=P("path"),vo=Fe().copy,Xr=ye().remove,ko=Y().mkdirp,qo=Q().pathExists,Vr=ee();function Fo(e,t,r,n){typeof r=="function"&&(n=r,r={});let i=r.overwrite||r.clobber||!1;Vr.checkPaths(e,t,"move",r,(o,u)=>{if(o)return n(o);let{srcStat:c,isChangingCase:a=!1}=u;Vr.checkParentPaths(e,c,t,"move",k=>{if(k)return n(k);if(xo(t))return Qr(e,t,i,a,n);ko(Ke.dirname(t),s=>s?n(s):Qr(e,t,i,a,n))})})}function xo(e){let t=Ke.dirname(e);return Ke.parse(t).root===t}function Qr(e,t,r,n,i){if(n)return Ge(e,t,r,i);if(r)return Xr(t,o=>o?i(o):Ge(e,t,r,i));qo(t,(o,u)=>o?i(o):u?i(new Error("dest already exists.")):Ge(e,t,r,i))}function Ge(e,t,r,n){Eo.rename(e,t,i=>i?i.code!=="EXDEV"?n(i):go(e,t,r,n):n())}function go(e,t,r,n){vo(e,t,{overwrite:r,errorOnExist:!0},o=>o?n(o):Xr(e,n))}Hr.exports=Fo});var rn=w((pu,tn)=>{"use strict";f();var br=M(),Qe=P("path"),Po=Fe().copySync,en=ye().removeSync,Oo=Y().mkdirpSync,Zr=ee();function Do(e,t,r){r=r||{};let n=r.overwrite||r.clobber||!1,{srcStat:i,isChangingCase:o=!1}=Zr.checkPathsSync(e,t,"move",r);return Zr.checkParentPathsSync(e,i,t,"move"),No(t)||Oo(Qe.dirname(t)),To(e,t,n,o)}function No(e){let t=Qe.dirname(e);return Qe.parse(t).root===t}function To(e,t,r,n){if(n)return Ve(e,t,r);if(r)return en(t),Ve(e,t,r);if(br.existsSync(t))throw new Error("dest already exists.");return Ve(e,t,r)}function Ve(e,t,r){try{br.renameSync(e,t)}catch(n){if(n.code!=="EXDEV")throw n;return Co(e,t,r)}}function Co(e,t,r){return Po(e,t,{overwrite:r,errorOnExist:!0}),en(e)}tn.exports=Do});var on=w((Eu,nn)=>{"use strict";f();var _o=W().fromCallback;nn.exports={move:_o(zr()),moveSync:rn()}});var cn=w((vu,un)=>{"use strict";f();un.exports={...b(),...Fe(),...er(),...Tr(),...Kr(),...Y(),...on(),...Te(),...Q(),...ye()}});f();f();import{dirname as En,resolve as vn}from"path";import{fileURLToPath as kn}from"url";var ze=vn(En(kn(import.meta.url)),"..");var fn=pn(cn(),1);import{resolve as sn}from"path";var Fu=async(e,t)=>{let r=sn(ze,`./templates/${e}`),n=sn(t);await(0,fn.copy)(r,n,{overwrite:!0,recursive:!0})};export{Fu as copyTemplate};
|
@@ -1 +1,4 @@
|
|
1
|
-
|
1
|
+
|
2
|
+
await(async()=>{let{dirname:e}=await import("path"),{fileURLToPath:i}=await import("url");if(typeof globalThis.__filename>"u"&&(globalThis.__filename=i(import.meta.url)),typeof globalThis.__dirname>"u"&&(globalThis.__dirname=e(globalThis.__filename)),typeof globalThis.require>"u"){let{default:a}=await import("module");globalThis.require=a.createRequire(import.meta.url)}})();
|
3
|
+
|
4
|
+
import o from"fs/promises";import{resolve as t}from"path";var p=async s=>{let a=t(process.cwd(),s,"package.json"),n=await o.readFile(a,"utf-8"),e=JSON.parse(n);e.name=s,await o.writeFile(a,JSON.stringify(e,null,2))};export{p as rewritePkgJson};
|