ts-pantry 0.9.13 → 0.9.16

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/bin/cli.js CHANGED
@@ -1,4 +1,4 @@
1
- import{M as f6,N as g6,R as K6,S as u6,T as m6}from"../chunk-tj7z6teg.js";import"../chunk-gt3n3063.js";import{Fa as i,Ga as _6,Ia as G6,Ja as p,Oa as d6,Sa as U6}from"../chunk-h2pyrnjr.js";import"../chunk-9vn4jn9p.js";import{fb as a,gb as J6,hb as q6}from"../chunk-xxpems7r.js";import"../chunk-mtvbvxsd.js";import"../chunk-5kvy4he0.js";import{Bb as h6,Cb as iz}from"../chunk-jywhngj7.js";import"../chunk-04eamjdw.js";import{Jb as f}from"../chunk-sd8qadhd.js";import W from"node:fs";import R from"node:path";import L from"node:process";import{EventEmitter as t6}from"node:events";import F6 from"node:process";import o from"node:process";import m from"node:process";import Uz,{stdin as J0,stdout as q0}from"node:process";import w6,{stdin as Hz,stdout as Vz}from"node:process";import Fz from"node:readline";var{create:n6,getPrototypeOf:c6,defineProperty:V6,getOwnPropertyNames:a6}=Object,i6=Object.prototype.hasOwnProperty,I=(z,$,Q)=>{Q=z!=null?n6(c6(z)):{};let Z=$||!z||!z.__esModule?V6(Q,"default",{value:z,enumerable:!0}):Q;for(let Y of a6(z))if(!i6.call(Z,Y))V6(Z,Y,{get:()=>z[Y],enumerable:!0});return Z},z6=(z,$)=>()=>($||z(($={exports:{}}).exports,$),$.exports),p6=z6((z,$)=>{function Q(Y){return Y==null?[]:Array.isArray(Y)?Y:[Y]}function Z(Y,X,J,q){var j,G=Y[X],K=~q.string.indexOf(X)?J==null||J===!0?"":String(J):typeof J==="boolean"?J:~q.boolean.indexOf(X)?J==="false"?!1:J==="true"||(Y._.push((j=+J,j*0===0)?j:J),!!J):(j=+J,j*0===0)?j:J;Y[X]=G==null?K:Array.isArray(G)?G.concat(K):[G,K]}$.exports=function(Y,X){Y=Y||[],X=X||{};var J,q,j,G,K,V={_:[]},U=0,F=0,H=0,O=Y.length;let b=X.alias!==void 0,M=X.unknown!==void 0,D=X.default!==void 0;if(X.alias=X.alias||{},X.string=Q(X.string),X.boolean=Q(X.boolean),b)for(J in X.alias){q=X.alias[J]=Q(X.alias[J]);for(U=0;U<q.length;U++)(X.alias[q[U]]=q.concat(J)).splice(U,1)}for(U=X.boolean.length;U-- >0;){q=X.alias[X.boolean[U]]||[];for(F=q.length;F-- >0;)X.boolean.push(q[F])}for(U=X.string.length;U-- >0;){q=X.alias[X.string[U]]||[];for(F=q.length;F-- >0;)X.string.push(q[F])}if(D){for(J in X.default)if(G=typeof X.default[J],q=X.alias[J]=X.alias[J]||[],X[G]!==void 0){X[G].push(J);for(U=0;U<q.length;U++)X[G].push(q[U])}}let w=M?Object.keys(X.alias):[];for(U=0;U<O;U++){if(j=Y[U],j==="--"){V._=V._.concat(Y.slice(++U));break}for(F=0;F<j.length;F++)if(j.charCodeAt(F)!==45)break;if(F===0)V._.push(j);else if(j.substring(F,F+3)==="no-"){if(G=j.substring(F+3),M&&!~w.indexOf(G))return X.unknown(j);V[G]=!1}else{for(H=F+1;H<j.length;H++)if(j.charCodeAt(H)===61)break;G=j.substring(F,H),K=j.substring(++H)||(U+1===O||(""+Y[U+1]).charCodeAt(0)===45||Y[++U]),q=F===2?[G]:G;for(H=0;H<q.length;H++){if(G=q[H],M&&!~w.indexOf(G))return X.unknown("-".repeat(F)+G);Z(V,G,H+1<q.length||K,X)}}}if(D){for(J in X.default)if(V[J]===void 0)V[J]=X.default[J]}if(b)for(J in V){q=X.alias[J]||[];while(q.length>0)V[q.shift()]=V[J]}return V}}),C=z6((z,$)=>{var Q=process||{},Z=Q.argv||[],Y=Q.env||{},X=!(!!Y.NO_COLOR||Z.includes("--no-color"))&&(!!Y.FORCE_COLOR||Z.includes("--color")||Q.platform==="win32"||(Q.stdout||{}).isTTY&&Y.TERM!=="dumb"||!!Y.CI),J=(G,K,V=G)=>(U)=>{let F=""+U,H=F.indexOf(K,G.length);return~H?G+q(F,K,V,H)+K:G+F+K},q=(G,K,V,U)=>{let F="",H=0;do F+=G.substring(H,U)+V,H=U+K.length,U=G.indexOf(K,H);while(~U);return F+G.substring(H)},j=(G=X)=>{let K=G?J:()=>String;return{isColorSupported:G,reset:K("\x1B[0m","\x1B[0m"),bold:K("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:K("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:K("\x1B[3m","\x1B[23m"),underline:K("\x1B[4m","\x1B[24m"),inverse:K("\x1B[7m","\x1B[27m"),hidden:K("\x1B[8m","\x1B[28m"),strikethrough:K("\x1B[9m","\x1B[29m"),black:K("\x1B[30m","\x1B[39m"),red:K("\x1B[31m","\x1B[39m"),green:K("\x1B[32m","\x1B[39m"),yellow:K("\x1B[33m","\x1B[39m"),blue:K("\x1B[34m","\x1B[39m"),magenta:K("\x1B[35m","\x1B[39m"),cyan:K("\x1B[36m","\x1B[39m"),white:K("\x1B[37m","\x1B[39m"),gray:K("\x1B[90m","\x1B[39m"),bgBlack:K("\x1B[40m","\x1B[49m"),bgRed:K("\x1B[41m","\x1B[49m"),bgGreen:K("\x1B[42m","\x1B[49m"),bgYellow:K("\x1B[43m","\x1B[49m"),bgBlue:K("\x1B[44m","\x1B[49m"),bgMagenta:K("\x1B[45m","\x1B[49m"),bgCyan:K("\x1B[46m","\x1B[49m"),bgWhite:K("\x1B[47m","\x1B[49m"),blackBright:K("\x1B[90m","\x1B[39m"),redBright:K("\x1B[91m","\x1B[39m"),greenBright:K("\x1B[92m","\x1B[39m"),yellowBright:K("\x1B[93m","\x1B[39m"),blueBright:K("\x1B[94m","\x1B[39m"),magentaBright:K("\x1B[95m","\x1B[39m"),cyanBright:K("\x1B[96m","\x1B[39m"),whiteBright:K("\x1B[97m","\x1B[39m"),bgBlackBright:K("\x1B[100m","\x1B[49m"),bgRedBright:K("\x1B[101m","\x1B[49m"),bgGreenBright:K("\x1B[102m","\x1B[49m"),bgYellowBright:K("\x1B[103m","\x1B[49m"),bgBlueBright:K("\x1B[104m","\x1B[49m"),bgMagentaBright:K("\x1B[105m","\x1B[49m"),bgCyanBright:K("\x1B[106m","\x1B[49m"),bgWhiteBright:K("\x1B[107m","\x1B[49m")}};$.exports=j(),$.exports.createColors=j}),r6=z6((z,$)=>{$.exports=()=>{return/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE])))?))?|\uDC6F(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE89\uDE8F-\uDEC2\uDEC6\uDECE-\uDEDC\uDEDF-\uDEE9]|\uDD3C(?:\u200D[\u2640\u2642]\uFE0F?|\uD83C[\uDFFB-\uDFFF])?|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g}}),s6=I(p6(),1);function I6(z){return z.replace(/[<[].+/,"").trim()}function e6(z){let $=/<([^>]+)>/g,Q=/\[([^\]]+)\]/g,Z=[],Y=(q)=>{let j=!1,G=q[1];if(G.startsWith("..."))G=G.slice(3),j=!0;return{required:q[0].startsWith("<"),value:G,variadic:j}},X;while(X=$.exec(z))Z.push(Y(X));let J;while(J=Q.exec(z))Z.push(Y(J));return Z}function o6(z){let $={alias:{},boolean:[]};for(let[Q,Z]of z.entries()){if(Z.names.length>1)$.alias[Z.names[0]]=Z.names.slice(1);if(Z.isBoolean)if(Z.negated){if(!z.some((X,J)=>{return J!==Q&&X.names.some((q)=>Z.names.includes(q))&&typeof X.required==="boolean"}))$.boolean.push(Z.names[0])}else $.boolean.push(Z.names[0])}return $}function W6(z){return z.sort(($,Q)=>{return $.length>Q.length?-1:1})[0]}function L6(z,$){return z.length>=$?z:`${z}${" ".repeat($-z.length)}`}function zz(z){return z.replace(/([a-z])-([a-z])/g,($,Q,Z)=>{return Q+Z.toUpperCase()})}function $z(z,$,Q){let Z=0,Y=$.length,X=z,J;for(;Z<Y;++Z)J=X[$[Z]],X=X[$[Z]]=Z===Y-1?Q:J!=null?J:!!~$[Z+1].indexOf(".")||!(+$[Z+1]>-1)?{}:[]}function Qz(z,$){for(let Q of Object.keys($)){let Z=$[Q];if(Z.shouldTransform){if(z[Q]=Array.prototype.concat.call([],z[Q]),typeof Z.transformFunction==="function")z[Q]=z[Q].map(Z.transformFunction)}}}function Zz(z){let $=/([^\\/]+)$/.exec(z);return $?$[1]:""}function R6(z){return z.split(".").map(($,Q)=>{return Q===0?zz($):$}).join(".")}class u extends Error{constructor(z){super(z);if(this.name=this.constructor.name,typeof Error.captureStackTrace==="function")Error.captureStackTrace(this,this.constructor);else this.stack=Error(z).stack}}function Yz(){let{env:z}=F6,{TERM:$,TERM_PROGRAM:Q}=z;if(F6.platform!=="win32")return $!=="linux";return Boolean(z.WT_SESSION)||Boolean(z.TERMINUS_SUBLIME)||z.ConEmuTask==="{cmd::Cmder}"||Q==="Terminus-Sublime"||Q==="vscode"||$==="xterm-256color"||$==="alacritty"||$==="rxvt-unicode"||$==="rxvt-unicode-256color"||z.TERMINAL_EMULATOR==="JetBrains-JediTerm"}var l="\x1B",E=`${l}[`;var S={to(z,$){if(!$)return`${E}${z+1}G`;return`${E}${$+1};${z+1}H`},move(z,$){let Q="";if(z<0)Q+=`${E}${-z}D`;else if(z>0)Q+=`${E}${z}C`;if($<0)Q+=`${E}${-$}A`;else if($>0)Q+=`${E}${$}B`;return Q},up:(z=1)=>`${E}${z}A`,down:(z=1)=>`${E}${z}B`,forward:(z=1)=>`${E}${z}C`,backward:(z=1)=>`${E}${z}D`,nextLine:(z=1)=>`${E}E`.repeat(z),prevLine:(z=1)=>`${E}F`.repeat(z),left:`${E}G`,hide:`${E}?25l`,show:`${E}?25h`,save:`${l}7`,restore:`${l}8`};var r={screen:`${E}2J`,up:(z=1)=>`${E}1J`.repeat(z),down:(z=1)=>`${E}J`.repeat(z),line:`${E}2K`,lineEnd:`${E}K`,lineStart:`${E}1K`,lines(z){let $="";for(let Q=0;Q<z;Q++)$+=this.line+(Q<z-1?S.up():"");if(z)$+=S.left;return $}},z0={screen:`${l}c`};class E6{rawName;description;name;names;isBoolean;required;config;negated;constructor(z,$,Q){if(this.rawName=z,this.description=$,this.config=Object.assign({},Q),z=z.replace(/\.\*/g,""),this.negated=!1,this.names=I6(z).split(",").map((Z)=>{let Y=Z.trim().replace(/^-{1,2}/,"");if(Y.startsWith("no-"))this.negated=!0,Y=Y.replace(/^no-/,"");return R6(Y)}).sort((Z,Y)=>Z.length>Y.length?1:-1),this.name=this.names[this.names.length-1],this.negated&&this.config.default==null)this.config.default=!0;if(z.includes("<"))this.required=!0;else if(z.includes("["))this.required=!1;else this.isBoolean=!0}}var Q0=o.argv,Xz=`${o.platform}-${o.arch} bun-v${typeof Bun<"u"?Bun.version:"unknown"}`,Jz=m.argv,qz=`${m.platform}-${m.arch} node-${m.version}`;class $6{rawName;description;config;cli;options;aliasNames;name;args;commandAction;usageText;versionNumber;examples;helpCallback;globalCommand;constructor(z,$,Q,Z){if(this.rawName=z,this.description=$,this.config=Q,this.cli=Z,this.options=[],this.aliasNames=[],this.name=I6(z),this.args=e6(z),this.examples=[],!Q)this.config={}}usage(z){return this.usageText=z,this}allowUnknownOptions(){return this.config.allowUnknownOptions=!0,this}ignoreOptionDefaultValue(){return this.config.ignoreOptionDefaultValue=!0,this}version(z,$="-v, --version"){return this.versionNumber=z,this.option($,"Display version number"),this}example(z){return this.examples.push(z),this}option(z,$,Q){let Z=new E6(z,$,Q);return this.options.push(Z),this}alias(z){return this.aliasNames.push(z),this}action(z){return this.commandAction=z,this}isMatched(z){return this.name===z||this.aliasNames.includes(z)}get isDefaultCommand(){return this.name===""||this.aliasNames.includes("!")}get isGlobalCommand(){return this instanceof Q6}hasOption(z){return z=z.split(".")[0],!!this.options.find(($)=>{return $.names.includes(z)})}outputHelp(){let{name:z,commands:$}=this.cli,{versionNumber:Q,options:Z,helpCallback:Y}=this.cli.globalCommand,X=[{body:`${z}${Q?`/${Q}`:""}`}];if(X.push({title:"Usage",body:` $ ${z} ${this.usageText||this.rawName}`}),(this.isGlobalCommand||this.isDefaultCommand)&&$.length>0){let j=W6($.map((G)=>G.rawName));X.push({title:"Commands",body:$.map((G)=>{return` ${L6(G.rawName,j.length)} ${G.description}`}).join(`
1
+ import{L as f6,M as g6,Q as K6,R as u6,S as m6}from"../chunk-q1zn0ezj.js";import"../chunk-mcz89rzg.js";import{Ja as i,Ka as _6,Ma as G6,Na as p,Sa as d6,Wa as U6}from"../chunk-f5n4jscp.js";import"../chunk-cret7mf0.js";import{jb as a,kb as J6,lb as q6}from"../chunk-rkak2mvz.js";import"../chunk-25sbj7mh.js";import"../chunk-dmcn6rf1.js";import{Fb as h6,Gb as iz}from"../chunk-cxg0wv4z.js";import"../chunk-9yep1cys.js";import{Nb as f}from"../chunk-z5kje5x9.js";import W from"node:fs";import R from"node:path";import L from"node:process";import{EventEmitter as t6}from"node:events";import F6 from"node:process";import o from"node:process";import m from"node:process";import Uz,{stdin as J0,stdout as q0}from"node:process";import w6,{stdin as Hz,stdout as Vz}from"node:process";import Fz from"node:readline";var{create:n6,getPrototypeOf:c6,defineProperty:V6,getOwnPropertyNames:a6}=Object,i6=Object.prototype.hasOwnProperty,I=(z,$,Q)=>{Q=z!=null?n6(c6(z)):{};let Z=$||!z||!z.__esModule?V6(Q,"default",{value:z,enumerable:!0}):Q;for(let Y of a6(z))if(!i6.call(Z,Y))V6(Z,Y,{get:()=>z[Y],enumerable:!0});return Z},z6=(z,$)=>()=>($||z(($={exports:{}}).exports,$),$.exports),p6=z6((z,$)=>{function Q(Y){return Y==null?[]:Array.isArray(Y)?Y:[Y]}function Z(Y,X,J,q){var j,G=Y[X],K=~q.string.indexOf(X)?J==null||J===!0?"":String(J):typeof J==="boolean"?J:~q.boolean.indexOf(X)?J==="false"?!1:J==="true"||(Y._.push((j=+J,j*0===0)?j:J),!!J):(j=+J,j*0===0)?j:J;Y[X]=G==null?K:Array.isArray(G)?G.concat(K):[G,K]}$.exports=function(Y,X){Y=Y||[],X=X||{};var J,q,j,G,K,V={_:[]},U=0,F=0,H=0,O=Y.length;let b=X.alias!==void 0,M=X.unknown!==void 0,D=X.default!==void 0;if(X.alias=X.alias||{},X.string=Q(X.string),X.boolean=Q(X.boolean),b)for(J in X.alias){q=X.alias[J]=Q(X.alias[J]);for(U=0;U<q.length;U++)(X.alias[q[U]]=q.concat(J)).splice(U,1)}for(U=X.boolean.length;U-- >0;){q=X.alias[X.boolean[U]]||[];for(F=q.length;F-- >0;)X.boolean.push(q[F])}for(U=X.string.length;U-- >0;){q=X.alias[X.string[U]]||[];for(F=q.length;F-- >0;)X.string.push(q[F])}if(D){for(J in X.default)if(G=typeof X.default[J],q=X.alias[J]=X.alias[J]||[],X[G]!==void 0){X[G].push(J);for(U=0;U<q.length;U++)X[G].push(q[U])}}let w=M?Object.keys(X.alias):[];for(U=0;U<O;U++){if(j=Y[U],j==="--"){V._=V._.concat(Y.slice(++U));break}for(F=0;F<j.length;F++)if(j.charCodeAt(F)!==45)break;if(F===0)V._.push(j);else if(j.substring(F,F+3)==="no-"){if(G=j.substring(F+3),M&&!~w.indexOf(G))return X.unknown(j);V[G]=!1}else{for(H=F+1;H<j.length;H++)if(j.charCodeAt(H)===61)break;G=j.substring(F,H),K=j.substring(++H)||(U+1===O||(""+Y[U+1]).charCodeAt(0)===45||Y[++U]),q=F===2?[G]:G;for(H=0;H<q.length;H++){if(G=q[H],M&&!~w.indexOf(G))return X.unknown("-".repeat(F)+G);Z(V,G,H+1<q.length||K,X)}}}if(D){for(J in X.default)if(V[J]===void 0)V[J]=X.default[J]}if(b)for(J in V){q=X.alias[J]||[];while(q.length>0)V[q.shift()]=V[J]}return V}}),C=z6((z,$)=>{var Q=process||{},Z=Q.argv||[],Y=Q.env||{},X=!(!!Y.NO_COLOR||Z.includes("--no-color"))&&(!!Y.FORCE_COLOR||Z.includes("--color")||Q.platform==="win32"||(Q.stdout||{}).isTTY&&Y.TERM!=="dumb"||!!Y.CI),J=(G,K,V=G)=>(U)=>{let F=""+U,H=F.indexOf(K,G.length);return~H?G+q(F,K,V,H)+K:G+F+K},q=(G,K,V,U)=>{let F="",H=0;do F+=G.substring(H,U)+V,H=U+K.length,U=G.indexOf(K,H);while(~U);return F+G.substring(H)},j=(G=X)=>{let K=G?J:()=>String;return{isColorSupported:G,reset:K("\x1B[0m","\x1B[0m"),bold:K("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:K("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:K("\x1B[3m","\x1B[23m"),underline:K("\x1B[4m","\x1B[24m"),inverse:K("\x1B[7m","\x1B[27m"),hidden:K("\x1B[8m","\x1B[28m"),strikethrough:K("\x1B[9m","\x1B[29m"),black:K("\x1B[30m","\x1B[39m"),red:K("\x1B[31m","\x1B[39m"),green:K("\x1B[32m","\x1B[39m"),yellow:K("\x1B[33m","\x1B[39m"),blue:K("\x1B[34m","\x1B[39m"),magenta:K("\x1B[35m","\x1B[39m"),cyan:K("\x1B[36m","\x1B[39m"),white:K("\x1B[37m","\x1B[39m"),gray:K("\x1B[90m","\x1B[39m"),bgBlack:K("\x1B[40m","\x1B[49m"),bgRed:K("\x1B[41m","\x1B[49m"),bgGreen:K("\x1B[42m","\x1B[49m"),bgYellow:K("\x1B[43m","\x1B[49m"),bgBlue:K("\x1B[44m","\x1B[49m"),bgMagenta:K("\x1B[45m","\x1B[49m"),bgCyan:K("\x1B[46m","\x1B[49m"),bgWhite:K("\x1B[47m","\x1B[49m"),blackBright:K("\x1B[90m","\x1B[39m"),redBright:K("\x1B[91m","\x1B[39m"),greenBright:K("\x1B[92m","\x1B[39m"),yellowBright:K("\x1B[93m","\x1B[39m"),blueBright:K("\x1B[94m","\x1B[39m"),magentaBright:K("\x1B[95m","\x1B[39m"),cyanBright:K("\x1B[96m","\x1B[39m"),whiteBright:K("\x1B[97m","\x1B[39m"),bgBlackBright:K("\x1B[100m","\x1B[49m"),bgRedBright:K("\x1B[101m","\x1B[49m"),bgGreenBright:K("\x1B[102m","\x1B[49m"),bgYellowBright:K("\x1B[103m","\x1B[49m"),bgBlueBright:K("\x1B[104m","\x1B[49m"),bgMagentaBright:K("\x1B[105m","\x1B[49m"),bgCyanBright:K("\x1B[106m","\x1B[49m"),bgWhiteBright:K("\x1B[107m","\x1B[49m")}};$.exports=j(),$.exports.createColors=j}),r6=z6((z,$)=>{$.exports=()=>{return/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE])))?))?|\uDC6F(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE89\uDE8F-\uDEC2\uDEC6\uDECE-\uDEDC\uDEDF-\uDEE9]|\uDD3C(?:\u200D[\u2640\u2642]\uFE0F?|\uD83C[\uDFFB-\uDFFF])?|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g}}),s6=I(p6(),1);function I6(z){return z.replace(/[<[].+/,"").trim()}function e6(z){let $=/<([^>]+)>/g,Q=/\[([^\]]+)\]/g,Z=[],Y=(q)=>{let j=!1,G=q[1];if(G.startsWith("..."))G=G.slice(3),j=!0;return{required:q[0].startsWith("<"),value:G,variadic:j}},X;while(X=$.exec(z))Z.push(Y(X));let J;while(J=Q.exec(z))Z.push(Y(J));return Z}function o6(z){let $={alias:{},boolean:[]};for(let[Q,Z]of z.entries()){if(Z.names.length>1)$.alias[Z.names[0]]=Z.names.slice(1);if(Z.isBoolean)if(Z.negated){if(!z.some((X,J)=>{return J!==Q&&X.names.some((q)=>Z.names.includes(q))&&typeof X.required==="boolean"}))$.boolean.push(Z.names[0])}else $.boolean.push(Z.names[0])}return $}function W6(z){return z.sort(($,Q)=>{return $.length>Q.length?-1:1})[0]}function L6(z,$){return z.length>=$?z:`${z}${" ".repeat($-z.length)}`}function zz(z){return z.replace(/([a-z])-([a-z])/g,($,Q,Z)=>{return Q+Z.toUpperCase()})}function $z(z,$,Q){let Z=0,Y=$.length,X=z,J;for(;Z<Y;++Z)J=X[$[Z]],X=X[$[Z]]=Z===Y-1?Q:J!=null?J:!!~$[Z+1].indexOf(".")||!(+$[Z+1]>-1)?{}:[]}function Qz(z,$){for(let Q of Object.keys($)){let Z=$[Q];if(Z.shouldTransform){if(z[Q]=Array.prototype.concat.call([],z[Q]),typeof Z.transformFunction==="function")z[Q]=z[Q].map(Z.transformFunction)}}}function Zz(z){let $=/([^\\/]+)$/.exec(z);return $?$[1]:""}function R6(z){return z.split(".").map(($,Q)=>{return Q===0?zz($):$}).join(".")}class u extends Error{constructor(z){super(z);if(this.name=this.constructor.name,typeof Error.captureStackTrace==="function")Error.captureStackTrace(this,this.constructor);else this.stack=Error(z).stack}}function Yz(){let{env:z}=F6,{TERM:$,TERM_PROGRAM:Q}=z;if(F6.platform!=="win32")return $!=="linux";return Boolean(z.WT_SESSION)||Boolean(z.TERMINUS_SUBLIME)||z.ConEmuTask==="{cmd::Cmder}"||Q==="Terminus-Sublime"||Q==="vscode"||$==="xterm-256color"||$==="alacritty"||$==="rxvt-unicode"||$==="rxvt-unicode-256color"||z.TERMINAL_EMULATOR==="JetBrains-JediTerm"}var l="\x1B",E=`${l}[`;var S={to(z,$){if(!$)return`${E}${z+1}G`;return`${E}${$+1};${z+1}H`},move(z,$){let Q="";if(z<0)Q+=`${E}${-z}D`;else if(z>0)Q+=`${E}${z}C`;if($<0)Q+=`${E}${-$}A`;else if($>0)Q+=`${E}${$}B`;return Q},up:(z=1)=>`${E}${z}A`,down:(z=1)=>`${E}${z}B`,forward:(z=1)=>`${E}${z}C`,backward:(z=1)=>`${E}${z}D`,nextLine:(z=1)=>`${E}E`.repeat(z),prevLine:(z=1)=>`${E}F`.repeat(z),left:`${E}G`,hide:`${E}?25l`,show:`${E}?25h`,save:`${l}7`,restore:`${l}8`};var r={screen:`${E}2J`,up:(z=1)=>`${E}1J`.repeat(z),down:(z=1)=>`${E}J`.repeat(z),line:`${E}2K`,lineEnd:`${E}K`,lineStart:`${E}1K`,lines(z){let $="";for(let Q=0;Q<z;Q++)$+=this.line+(Q<z-1?S.up():"");if(z)$+=S.left;return $}},z0={screen:`${l}c`};class E6{rawName;description;name;names;isBoolean;required;config;negated;constructor(z,$,Q){if(this.rawName=z,this.description=$,this.config=Object.assign({},Q),z=z.replace(/\.\*/g,""),this.negated=!1,this.names=I6(z).split(",").map((Z)=>{let Y=Z.trim().replace(/^-{1,2}/,"");if(Y.startsWith("no-"))this.negated=!0,Y=Y.replace(/^no-/,"");return R6(Y)}).sort((Z,Y)=>Z.length>Y.length?1:-1),this.name=this.names[this.names.length-1],this.negated&&this.config.default==null)this.config.default=!0;if(z.includes("<"))this.required=!0;else if(z.includes("["))this.required=!1;else this.isBoolean=!0}}var Q0=o.argv,Xz=`${o.platform}-${o.arch} bun-v${typeof Bun<"u"?Bun.version:"unknown"}`,Jz=m.argv,qz=`${m.platform}-${m.arch} node-${m.version}`;class $6{rawName;description;config;cli;options;aliasNames;name;args;commandAction;usageText;versionNumber;examples;helpCallback;globalCommand;constructor(z,$,Q,Z){if(this.rawName=z,this.description=$,this.config=Q,this.cli=Z,this.options=[],this.aliasNames=[],this.name=I6(z),this.args=e6(z),this.examples=[],!Q)this.config={}}usage(z){return this.usageText=z,this}allowUnknownOptions(){return this.config.allowUnknownOptions=!0,this}ignoreOptionDefaultValue(){return this.config.ignoreOptionDefaultValue=!0,this}version(z,$="-v, --version"){return this.versionNumber=z,this.option($,"Display version number"),this}example(z){return this.examples.push(z),this}option(z,$,Q){let Z=new E6(z,$,Q);return this.options.push(Z),this}alias(z){return this.aliasNames.push(z),this}action(z){return this.commandAction=z,this}isMatched(z){return this.name===z||this.aliasNames.includes(z)}get isDefaultCommand(){return this.name===""||this.aliasNames.includes("!")}get isGlobalCommand(){return this instanceof Q6}hasOption(z){return z=z.split(".")[0],!!this.options.find(($)=>{return $.names.includes(z)})}outputHelp(){let{name:z,commands:$}=this.cli,{versionNumber:Q,options:Z,helpCallback:Y}=this.cli.globalCommand,X=[{body:`${z}${Q?`/${Q}`:""}`}];if(X.push({title:"Usage",body:` $ ${z} ${this.usageText||this.rawName}`}),(this.isGlobalCommand||this.isDefaultCommand)&&$.length>0){let j=W6($.map((G)=>G.rawName));X.push({title:"Commands",body:$.map((G)=>{return` ${L6(G.rawName,j.length)} ${G.description}`}).join(`
2
2
  `)}),X.push({title:"For more info, run any command with the `--help` flag",body:$.map((G)=>` $ ${z}${G.name===""?"":` ${G.name}`} --help`).join(`
3
3
  `)})}let q=this.isGlobalCommand?Z:[...this.options,...Z||[]];if(!this.isGlobalCommand&&!this.isDefaultCommand)q=q.filter((j)=>j.name!=="version");if(q.length>0){let j=W6(q.map((G)=>G.rawName));X.push({title:"Options",body:q.map((G)=>{return` ${L6(G.rawName,j.length)} ${G.description} ${G.config.default===void 0?"":`(default: ${G.config.default})`}`}).join(`
4
4
  `)})}if(this.examples.length>0)X.push({title:"Examples",body:this.examples.map((j)=>{if(typeof j==="function")return j(z);return j}).join(`
@@ -19,7 +19,7 @@ ${j.body}`:j.body}).join(`
19
19
  `).length-1;this.output.write(S.move(-999,z*-1))}render(){let z=T6(this._render(this)??"",w6.stdout.columns,{hard:!0,trim:!1});if(z===this._prevFrame)return;if(this.state==="initial")this.output.write(S.hide);else{let $=jz(this._prevFrame,z);if(this.restoreCursor(),$&&$?.length===1){let Q=$[0];this.output.write(S.move(0,Q)),this.output.write(r.lines(1));let Z=z.split(`
20
20
  `);this.output.write(Z[Q]),this._prevFrame=z,this.output.write(S.move(0,Z.length-Q-1));return}if($&&$?.length>1){let Q=$[0];this.output.write(S.move(0,Q)),this.output.write(r.down());let Y=z.split(`
21
21
  `).slice(Q);this.output.write(Y.join(`
22
- `)),this._prevFrame=z;return}this.output.write(r.down())}if(this.output.write(z),this.state==="initial")this.state="active";this._prevFrame=z}}function hz(z,$){if(z===void 0)return 0;if($.length===0)return 0;let Z=$.findIndex((Y)=>Y.value===z);return Z!==-1?Z:0}function fz(z,$){return($.label??String($.value)).toLowerCase().includes(z.toLowerCase())}function gz(z,$){if(!$)return;if(z)return $;return $[0]}class _z extends X6{filteredOptions;multiple;isNavigating=!1;selectedValues=[];focusedValue;#z=0;#Q="";#Z;#$;get cursor(){return this.#z}get userInputWithCursor(){if(!this.userInput)return s.default.inverse(s.default.hidden("_"));if(this._cursor>=this.userInput.length)return`${this.userInput}█`;let z=this.userInput.slice(0,this._cursor),[$,...Q]=this.userInput.slice(this._cursor);return`${z}${s.default.inverse($)}${Q.join("")}`}get options(){if(typeof this.#$==="function")return this.#$();return this.#$}constructor(z){super(z);this.#$=z.options;let $=this.options;this.filteredOptions=[...$],this.multiple=z.multiple===!0,this.#Z=z.filter??fz;let Q;if(z.initialValue&&Array.isArray(z.initialValue))if(this.multiple)Q=z.initialValue;else Q=z.initialValue.slice(0,1);else if(!this.multiple&&this.options.length>0)Q=[this.options[0].value];if(Q)for(let Z of Q){let Y=$.findIndex((X)=>X.value===Z);if(Y!==-1)this.toggleSelected(Z),this.#z=Y}this.focusedValue=this.options[this.#z]?.value,this.on("key",(Z,Y)=>this.#Y(Z,Y)),this.on("userInput",(Z)=>this.#X(Z))}_isActionKey(z,$){return z==="\t"||this.multiple&&this.isNavigating&&$.name==="space"&&z!==void 0&&z!==""}#Y(z,$){let Q=$.name==="up",Z=$.name==="down",Y=$.name==="return";if(Q||Z){if(this.#z=Math.max(0,Math.min(this.#z+(Q?-1:1),this.filteredOptions.length-1)),this.focusedValue=this.filteredOptions[this.#z]?.value,!this.multiple)this.selectedValues=[this.focusedValue];this.isNavigating=!0}else if(Y)this.value=gz(this.multiple,this.selectedValues);else if(this.multiple)if(this.focusedValue!==void 0&&($.name==="tab"||this.isNavigating&&$.name==="space"))this.toggleSelected(this.focusedValue);else this.isNavigating=!1;else{if(this.focusedValue)this.selectedValues=[this.focusedValue];this.isNavigating=!1}}deselectAll(){this.selectedValues=[]}toggleSelected(z){if(this.filteredOptions.length===0)return;if(this.multiple)if(this.selectedValues.includes(z))this.selectedValues=this.selectedValues.filter(($)=>$!==z);else this.selectedValues=[...this.selectedValues,z];else this.selectedValues=[z]}#X(z){if(z!==this.#Q){this.#Q=z;let $=this.options;if(z)this.filteredOptions=$.filter((Q)=>this.#Z(z,Q));else this.filteredOptions=[...$];if(this.#z=hz(this.focusedValue,this.filteredOptions),this.focusedValue=this.filteredOptions[this.#z]?.value,!this.multiple)if(this.focusedValue!==void 0)this.toggleSelected(this.focusedValue);else this.deselectAll()}}}class dz extends X6{options;cursor=0;#z;getGroupItems(z){return this.options.filter(($)=>$.group===z)}isGroupSelected(z){let $=this.getGroupItems(z),Q=this.value;if(Q===void 0)return!1;return $.every((Z)=>Q.includes(Z.value))}toggleValue(){let z=this.options[this.cursor];if(this.value===void 0)this.value=[];if(z.group===!0){let $=z.value,Q=this.getGroupItems($);if(this.isGroupSelected($))this.value=this.value.filter((Z)=>Q.findIndex((Y)=>Y.value===Z)===-1);else this.value=[...this.value,...Q.map((Z)=>Z.value)];this.value=Array.from(new Set(this.value))}else{let $=this.value.includes(z.value);this.value=$?this.value.filter((Q)=>Q!==z.value):[...this.value,z.value]}}constructor(z){super(z,!1);let{options:$}=z;this.#z=z.selectableGroups!==!1,this.options=Object.entries($).flatMap(([Q,Z])=>[{value:Q,group:!0,label:Q},...Z.map((Y)=>({...Y,group:Q}))]),this.value=[...z.initialValues??[]],this.cursor=Math.max(this.options.findIndex(({value:Q})=>Q===z.cursorAt),this.#z?0:1),this.on("cursor",(Q)=>{switch(Q){case"left":case"up":{this.cursor=this.cursor===0?this.options.length-1:this.cursor-1;let Z=this.options[this.cursor]?.group===!0;if(!this.#z&&Z)this.cursor=this.cursor===0?this.options.length-1:this.cursor-1;break}case"down":case"right":{this.cursor=this.cursor===this.options.length-1?0:this.cursor+1;let Z=this.options[this.cursor]?.group===!0;if(!this.#z&&Z)this.cursor=this.cursor===this.options.length-1?0:this.cursor+1;break}case"space":this.toggleValue();break}})}}var V0=I(C(),1);var F0=I(C(),1);var W0=I(C(),1),h={red:["\x1B[31m","\x1B[39m"],green:["\x1B[32m","\x1B[39m"],blue:["\x1B[34m","\x1B[39m"],yellow:["\x1B[33m","\x1B[39m"],cyan:["\x1B[36m","\x1B[39m"],magenta:["\x1B[35m","\x1B[39m"],white:["\x1B[37m","\x1B[39m"],gray:["\x1B[90m","\x1B[39m"],bgRed:["\x1B[41m","\x1B[49m"],bgGreen:["\x1B[42m","\x1B[49m"],bgBlue:["\x1B[44m","\x1B[49m"],bgYellow:["\x1B[43m","\x1B[49m"],bgCyan:["\x1B[46m","\x1B[49m"],bgMagenta:["\x1B[45m","\x1B[49m"],bold:["\x1B[1m","\x1B[22m"],italic:["\x1B[3m","\x1B[23m"],underline:["\x1B[4m","\x1B[24m"],dim:["\x1B[2m","\x1B[22m"],inverse:["\x1B[7m","\x1B[27m"],hidden:["\x1B[8m","\x1B[28m"],strikethrough:["\x1B[9m","\x1B[29m"]},g={primary:"blue",secondary:"cyan",success:"green",warning:"yellow",error:"red",info:"magenta",muted:"gray"};function uz(){return!0}function mz(){let z={};z.supportsColor=uz();function $(Z,Y=[]){let X=Z===""?[]:[...Y,Z],J=function(j){if(!z.supportsColor)return j;let G="",K="";for(let V of X)if(V in g&&g[V]in h){let U=g[V];G+=h[U][0],K=h[U][1]+K}else if(V in h)G+=h[V][0],K=h[V][1]+K;return G+j+K},q=[...Object.keys(h),...Object.keys(g)];for(let j of q)if(!(j in J))Object.defineProperty(J,j,{get(){return $(j,X)}});return J}let Q=[...Object.keys(h),...Object.keys(g)];for(let Z of Q)if(!(Z in z))Object.defineProperty(z,Z,{get(){return $(Z)}});return z}var L0=mz();var xz=Yz();var T=(z,$)=>xz?z:$,M0=T("◆","*"),w0=T("■","x"),O0=T("▲","x"),B0=T("◇","o"),D0=T("┌","T"),lz=T("│","|"),b0=T("└","—"),N0=T("●",">"),T0=T("○"," "),I0=T("◻","[•]"),R0=T("◼","[+]"),E0=T("◻","[ ]"),C0=T("▪","•"),A0=T("─","-"),P0=T("╮","+"),y0=T("├","+"),v0=T("╯","+"),k0=T("●","•"),S0=T("◆","*"),h0=T("▲","!"),f0=T("■","x");var g0=I(C(),1);var _0=I(C(),1);var d0=I(C(),1);var u0=I(C(),1);var m0=I(C(),1);var x0=I(C(),1);var l0=I(C(),1);var n0=I(C(),1);var c0=I(C(),1),a0=I(C(),1);var i0={light:T("─","-"),heavy:T("━","="),block:T("█","#")};var p0=I(C(),1);var r0=I(C(),1);var nz=I(C(),1);function cz(){return`${nz.default.gray(lz)} `}var s0=cz();var t0=I(C(),1);var e0=I(C(),1);var v6="0.9.13";iz();async function pz(z="src/pantry"){if(!W.existsSync(z))throw Error(`Pantry directory not found: ${z}. Please run 'bun ./bin/cli.ts update-pantry' first.`);let $=[];function Q(Z,Y=""){let X=W.readdirSync(Z,{withFileTypes:!0}),J=R.join(Z,"package.yml");if(Y&&W.existsSync(J))$.push(Y);for(let q of X)if(q.isDirectory()&&!q.name.startsWith(".")){let j=Y?`${Y}/${q.name}`:q.name,G=R.join(Z,q.name);Q(G,j)}}return Q(z),console.log(`\uD83D\uDCE6 Found ${$.length} packages in local pantry`),$.sort()}async function rz(z=!1){async function $(J){let q=new URL("https://s3.amazonaws.com/dist.tea.xyz/");if(q.searchParams.set("list-type","2"),q.searchParams.set("prefix",""),q.searchParams.set("max-keys","1000"),J)q.searchParams.set("continuation-token",J);let j=await fetch(q.toString());if(!j.ok)throw Error(`Failed to fetch S3 listing: ${j.status}`);let G=await j.text(),K=[],V=G.match(/<Key>([^<]+)<\/Key>/g);if(V)for(let O of V){let b=O.replace(/<Key>([^<]+)<\/Key>/,"$1");K.push({Key:b})}let U=G.includes("<IsTruncated>true</IsTruncated>"),F=G.match(/<NextContinuationToken>([^<]+)<\/NextContinuationToken>/),H=F?F[1]:void 0;return{IsTruncated:U,NextContinuationToken:H,Contents:K}}console.log("Scraping packages from S3 registry...");let Q=new Set,Z;do{let J=await $(Z);for(let q of J.Contents){let j=q.Key,G=j.split("/");if(G.length===0)continue;if(G[0].startsWith(".")||G[0].includes(" ")||j.match(/\.(md|txt|yml|yaml|json)$/i))continue;let K=["darwin","linux","windows"],V=-1;for(let U=1;U<G.length;U++)if(K.includes(G[U])){V=U;break}if(V>0){let U=G.slice(0,V).join("/");if(U.includes("."))Q.add(U)}else if(G.length>=2&&G[0].includes(".")&&!G[1].startsWith("v")&&!G[1].match(/^\d/)){let U=`${G[0]}/${G[1]}`;Q.add(U)}else if(G.length>=1&&G[0].includes("."))Q.add(G[0])}Z=J.NextContinuationToken,console.log(`Found ${Q.size} packages so far...`)}while(Z);let Y=Array.from(Q).sort(),X=[];for(let J of Y){if(!J.includes(".")||J.match(/^[a-z0-9.-]+\.[a-z]{2,}(\/[\w.-]+){0,20}$/i)===null)continue;if(J.endsWith("/README.rst")||J.endsWith("/README")||J.includes("/docs/"))continue;if(J.endsWith("/.pkgroot"))continue;if(["amazon.com/aws","charm.sh","code.videolan.org","crates.io"].includes(J))continue;X.push(J)}return console.log(`\uD83D\uDCE6 Found ${X.length} valid packages in registry`),X}async function sz(z,$){let Z=`/**
22
+ `)),this._prevFrame=z;return}this.output.write(r.down())}if(this.output.write(z),this.state==="initial")this.state="active";this._prevFrame=z}}function hz(z,$){if(z===void 0)return 0;if($.length===0)return 0;let Z=$.findIndex((Y)=>Y.value===z);return Z!==-1?Z:0}function fz(z,$){return($.label??String($.value)).toLowerCase().includes(z.toLowerCase())}function gz(z,$){if(!$)return;if(z)return $;return $[0]}class _z extends X6{filteredOptions;multiple;isNavigating=!1;selectedValues=[];focusedValue;#z=0;#Q="";#Z;#$;get cursor(){return this.#z}get userInputWithCursor(){if(!this.userInput)return s.default.inverse(s.default.hidden("_"));if(this._cursor>=this.userInput.length)return`${this.userInput}█`;let z=this.userInput.slice(0,this._cursor),[$,...Q]=this.userInput.slice(this._cursor);return`${z}${s.default.inverse($)}${Q.join("")}`}get options(){if(typeof this.#$==="function")return this.#$();return this.#$}constructor(z){super(z);this.#$=z.options;let $=this.options;this.filteredOptions=[...$],this.multiple=z.multiple===!0,this.#Z=z.filter??fz;let Q;if(z.initialValue&&Array.isArray(z.initialValue))if(this.multiple)Q=z.initialValue;else Q=z.initialValue.slice(0,1);else if(!this.multiple&&this.options.length>0)Q=[this.options[0].value];if(Q)for(let Z of Q){let Y=$.findIndex((X)=>X.value===Z);if(Y!==-1)this.toggleSelected(Z),this.#z=Y}this.focusedValue=this.options[this.#z]?.value,this.on("key",(Z,Y)=>this.#Y(Z,Y)),this.on("userInput",(Z)=>this.#X(Z))}_isActionKey(z,$){return z==="\t"||this.multiple&&this.isNavigating&&$.name==="space"&&z!==void 0&&z!==""}#Y(z,$){let Q=$.name==="up",Z=$.name==="down",Y=$.name==="return";if(Q||Z){if(this.#z=Math.max(0,Math.min(this.#z+(Q?-1:1),this.filteredOptions.length-1)),this.focusedValue=this.filteredOptions[this.#z]?.value,!this.multiple)this.selectedValues=[this.focusedValue];this.isNavigating=!0}else if(Y)this.value=gz(this.multiple,this.selectedValues);else if(this.multiple)if(this.focusedValue!==void 0&&($.name==="tab"||this.isNavigating&&$.name==="space"))this.toggleSelected(this.focusedValue);else this.isNavigating=!1;else{if(this.focusedValue)this.selectedValues=[this.focusedValue];this.isNavigating=!1}}deselectAll(){this.selectedValues=[]}toggleSelected(z){if(this.filteredOptions.length===0)return;if(this.multiple)if(this.selectedValues.includes(z))this.selectedValues=this.selectedValues.filter(($)=>$!==z);else this.selectedValues=[...this.selectedValues,z];else this.selectedValues=[z]}#X(z){if(z!==this.#Q){this.#Q=z;let $=this.options;if(z)this.filteredOptions=$.filter((Q)=>this.#Z(z,Q));else this.filteredOptions=[...$];if(this.#z=hz(this.focusedValue,this.filteredOptions),this.focusedValue=this.filteredOptions[this.#z]?.value,!this.multiple)if(this.focusedValue!==void 0)this.toggleSelected(this.focusedValue);else this.deselectAll()}}}class dz extends X6{options;cursor=0;#z;getGroupItems(z){return this.options.filter(($)=>$.group===z)}isGroupSelected(z){let $=this.getGroupItems(z),Q=this.value;if(Q===void 0)return!1;return $.every((Z)=>Q.includes(Z.value))}toggleValue(){let z=this.options[this.cursor];if(this.value===void 0)this.value=[];if(z.group===!0){let $=z.value,Q=this.getGroupItems($);if(this.isGroupSelected($))this.value=this.value.filter((Z)=>Q.findIndex((Y)=>Y.value===Z)===-1);else this.value=[...this.value,...Q.map((Z)=>Z.value)];this.value=Array.from(new Set(this.value))}else{let $=this.value.includes(z.value);this.value=$?this.value.filter((Q)=>Q!==z.value):[...this.value,z.value]}}constructor(z){super(z,!1);let{options:$}=z;this.#z=z.selectableGroups!==!1,this.options=Object.entries($).flatMap(([Q,Z])=>[{value:Q,group:!0,label:Q},...Z.map((Y)=>({...Y,group:Q}))]),this.value=[...z.initialValues??[]],this.cursor=Math.max(this.options.findIndex(({value:Q})=>Q===z.cursorAt),this.#z?0:1),this.on("cursor",(Q)=>{switch(Q){case"left":case"up":{this.cursor=this.cursor===0?this.options.length-1:this.cursor-1;let Z=this.options[this.cursor]?.group===!0;if(!this.#z&&Z)this.cursor=this.cursor===0?this.options.length-1:this.cursor-1;break}case"down":case"right":{this.cursor=this.cursor===this.options.length-1?0:this.cursor+1;let Z=this.options[this.cursor]?.group===!0;if(!this.#z&&Z)this.cursor=this.cursor===this.options.length-1?0:this.cursor+1;break}case"space":this.toggleValue();break}})}}var V0=I(C(),1);var F0=I(C(),1);var W0=I(C(),1),h={red:["\x1B[31m","\x1B[39m"],green:["\x1B[32m","\x1B[39m"],blue:["\x1B[34m","\x1B[39m"],yellow:["\x1B[33m","\x1B[39m"],cyan:["\x1B[36m","\x1B[39m"],magenta:["\x1B[35m","\x1B[39m"],white:["\x1B[37m","\x1B[39m"],gray:["\x1B[90m","\x1B[39m"],bgRed:["\x1B[41m","\x1B[49m"],bgGreen:["\x1B[42m","\x1B[49m"],bgBlue:["\x1B[44m","\x1B[49m"],bgYellow:["\x1B[43m","\x1B[49m"],bgCyan:["\x1B[46m","\x1B[49m"],bgMagenta:["\x1B[45m","\x1B[49m"],bold:["\x1B[1m","\x1B[22m"],italic:["\x1B[3m","\x1B[23m"],underline:["\x1B[4m","\x1B[24m"],dim:["\x1B[2m","\x1B[22m"],inverse:["\x1B[7m","\x1B[27m"],hidden:["\x1B[8m","\x1B[28m"],strikethrough:["\x1B[9m","\x1B[29m"]},g={primary:"blue",secondary:"cyan",success:"green",warning:"yellow",error:"red",info:"magenta",muted:"gray"};function uz(){return!0}function mz(){let z={};z.supportsColor=uz();function $(Z,Y=[]){let X=Z===""?[]:[...Y,Z],J=function(j){if(!z.supportsColor)return j;let G="",K="";for(let V of X)if(V in g&&g[V]in h){let U=g[V];G+=h[U][0],K=h[U][1]+K}else if(V in h)G+=h[V][0],K=h[V][1]+K;return G+j+K},q=[...Object.keys(h),...Object.keys(g)];for(let j of q)if(!(j in J))Object.defineProperty(J,j,{get(){return $(j,X)}});return J}let Q=[...Object.keys(h),...Object.keys(g)];for(let Z of Q)if(!(Z in z))Object.defineProperty(z,Z,{get(){return $(Z)}});return z}var L0=mz();var xz=Yz();var T=(z,$)=>xz?z:$,M0=T("◆","*"),w0=T("■","x"),O0=T("▲","x"),B0=T("◇","o"),D0=T("┌","T"),lz=T("│","|"),b0=T("└","—"),N0=T("●",">"),T0=T("○"," "),I0=T("◻","[•]"),R0=T("◼","[+]"),E0=T("◻","[ ]"),C0=T("▪","•"),A0=T("─","-"),P0=T("╮","+"),y0=T("├","+"),v0=T("╯","+"),k0=T("●","•"),S0=T("◆","*"),h0=T("▲","!"),f0=T("■","x");var g0=I(C(),1);var _0=I(C(),1);var d0=I(C(),1);var u0=I(C(),1);var m0=I(C(),1);var x0=I(C(),1);var l0=I(C(),1);var n0=I(C(),1);var c0=I(C(),1),a0=I(C(),1);var i0={light:T("─","-"),heavy:T("━","="),block:T("█","#")};var p0=I(C(),1);var r0=I(C(),1);var nz=I(C(),1);function cz(){return`${nz.default.gray(lz)} `}var s0=cz();var t0=I(C(),1);var e0=I(C(),1);var v6="0.9.16";iz();async function pz(z="src/pantry"){if(!W.existsSync(z))throw Error(`Pantry directory not found: ${z}. Please run 'bun ./bin/cli.ts update-pantry' first.`);let $=[];function Q(Z,Y=""){let X=W.readdirSync(Z,{withFileTypes:!0}),J=R.join(Z,"package.yml");if(Y&&W.existsSync(J))$.push(Y);for(let q of X)if(q.isDirectory()&&!q.name.startsWith(".")){let j=Y?`${Y}/${q.name}`:q.name,G=R.join(Z,q.name);Q(G,j)}}return Q(z),console.log(`\uD83D\uDCE6 Found ${$.length} packages in local pantry`),$.sort()}async function rz(z=!1){async function $(J){let q=new URL("https://s3.amazonaws.com/dist.tea.xyz/");if(q.searchParams.set("list-type","2"),q.searchParams.set("prefix",""),q.searchParams.set("max-keys","1000"),J)q.searchParams.set("continuation-token",J);let j=await fetch(q.toString());if(!j.ok)throw Error(`Failed to fetch S3 listing: ${j.status}`);let G=await j.text(),K=[],V=G.match(/<Key>([^<]+)<\/Key>/g);if(V)for(let O of V){let b=O.replace(/<Key>([^<]+)<\/Key>/,"$1");K.push({Key:b})}let U=G.includes("<IsTruncated>true</IsTruncated>"),F=G.match(/<NextContinuationToken>([^<]+)<\/NextContinuationToken>/),H=F?F[1]:void 0;return{IsTruncated:U,NextContinuationToken:H,Contents:K}}console.log("Scraping packages from S3 registry...");let Q=new Set,Z;do{let J=await $(Z);for(let q of J.Contents){let j=q.Key,G=j.split("/");if(G.length===0)continue;if(G[0].startsWith(".")||G[0].includes(" ")||j.match(/\.(md|txt|yml|yaml|json)$/i))continue;let K=["darwin","linux","windows"],V=-1;for(let U=1;U<G.length;U++)if(K.includes(G[U])){V=U;break}if(V>0){let U=G.slice(0,V).join("/");if(U.includes("."))Q.add(U)}else if(G.length>=2&&G[0].includes(".")&&!G[1].startsWith("v")&&!G[1].match(/^\d/)){let U=`${G[0]}/${G[1]}`;Q.add(U)}else if(G.length>=1&&G[0].includes("."))Q.add(G[0])}Z=J.NextContinuationToken,console.log(`Found ${Q.size} packages so far...`)}while(Z);let Y=Array.from(Q).sort(),X=[];for(let J of Y){if(!J.includes(".")||J.match(/^[a-z0-9.-]+\.[a-z]{2,}(\/[\w.-]+){0,20}$/i)===null)continue;if(J.endsWith("/README.rst")||J.endsWith("/README")||J.includes("/docs/"))continue;if(J.endsWith("/.pkgroot"))continue;if(["amazon.com/aws","charm.sh","code.videolan.org","crates.io"].includes(J))continue;X.push(J)}return console.log(`\uD83D\uDCE6 Found ${X.length} valid packages in registry`),X}async function sz(z,$){let Z=`/**
23
23
  * Constants used throughout the ts-pkgx package
24
24
  * This file is auto-generated from ${$}. Do not edit manually.
25
25
  * Generated on ${new Date().toISOString()}
@@ -84,14 +84,14 @@ Conflicts found:`),U.conflicts.forEach((H)=>{console.log(` ${H.package}: ${H.ve
84
84
  \uD83D\uDE80 Install commands:`),console.log(`
85
85
  Using pkgx:`);let H=U.uniquePackages.map((O)=>`+${O}`).join(" ");console.log(`sh <(curl https://pkgx.sh) ${H} -- $SHELL -i`),console.log(`
86
86
  Or install individually:`),U.uniquePackages.forEach((O)=>{console.log(`pkgx +${O}`)})}if(Object.values(U.osSpecificDeps).reduce((H,O)=>H+O.length,0)>0)console.log(`
87
- \uD83D\uDDA5️ OS-specific dependencies:`),Object.entries(U.osSpecificDeps).forEach(([H,O])=>{if(O.length>0)console.log(` ${H}: ${O.map((b)=>b.name).join(", ")}`)})}L.exit(0)}catch(Q){if($.json){let Z={success:!1,error:String(Q),timestamp:new Date().toISOString()};console.log(JSON.stringify(Z))}else console.error("Error resolving dependencies:",Q);L.exit(1)}});A.command("get-php-versions","Get PHP versions suitable for CI/CD workflows").option("--format <type>","Output format: json (default), yaml, or csv",{default:"json"}).option("--branches <branches>","Comma-separated list of PHP branches to include (e.g., 8.4,8.3,8.2)").option("--fallback <versions>","Comma-separated list of fallback versions if detection fails").action(async(z)=>{try{let{getPhpVersionsForWorkflow:$}=await import("../chunk-sm3nm634.js"),Q={};if(z.branches)Q.supportedBranches=z.branches.split(",").map((Y)=>Y.trim());if(z.fallback)Q.fallbackVersions=z.fallback.split(",").map((Y)=>Y.trim());let Z=$(Q);switch(z.format.toLowerCase()){case"yaml":console.log(`php_versions:
87
+ \uD83D\uDDA5️ OS-specific dependencies:`),Object.entries(U.osSpecificDeps).forEach(([H,O])=>{if(O.length>0)console.log(` ${H}: ${O.map((b)=>b.name).join(", ")}`)})}L.exit(0)}catch(Q){if($.json){let Z={success:!1,error:String(Q),timestamp:new Date().toISOString()};console.log(JSON.stringify(Z))}else console.error("Error resolving dependencies:",Q);L.exit(1)}});A.command("get-php-versions","Get PHP versions suitable for CI/CD workflows").option("--format <type>","Output format: json (default), yaml, or csv",{default:"json"}).option("--branches <branches>","Comma-separated list of PHP branches to include (e.g., 8.4,8.3,8.2)").option("--fallback <versions>","Comma-separated list of fallback versions if detection fails").action(async(z)=>{try{let{getPhpVersionsForWorkflow:$}=await import("../chunk-h59trmsa.js"),Q={};if(z.branches)Q.supportedBranches=z.branches.split(",").map((Y)=>Y.trim());if(z.fallback)Q.fallbackVersions=z.fallback.split(",").map((Y)=>Y.trim());let Z=$(Q);switch(z.format.toLowerCase()){case"yaml":console.log(`php_versions:
88
88
  ${Z.map((Y)=>` - "${Y}"`).join(`
89
- `)}`);break;case"csv":console.log(Z.join(","));break;case"json":default:console.log(JSON.stringify(Z));break}L.exit(0)}catch($){console.error("Error getting PHP versions:",$),L.exit(1)}});A.command("generate-zig","Generate Zig package definitions from TypeScript packages").option("--packages-dir <dir>","Directory containing TypeScript package files",{default:"src/packages"}).option("--output <file>","Output Zig file path",{default:"packages.zig"}).option("--aliases","Also generate aliases file").option("--aliases-output <file>","Output file for Zig aliases",{default:"aliases.zig"}).action(async(z)=>{try{let{generateZigDefinitions:$,generateZigAliases:Q}=await import("../chunk-zeg3rmkd.js"),{packagesDir:Z="src/packages",output:Y="packages.zig",aliases:X=!1,aliasesOutput:J="aliases.zig"}=z;if(console.log("\uD83D\uDE80 Generating Zig package definitions..."),await $(Z,Y),X)console.log(`
89
+ `)}`);break;case"csv":console.log(Z.join(","));break;case"json":default:console.log(JSON.stringify(Z));break}L.exit(0)}catch($){console.error("Error getting PHP versions:",$),L.exit(1)}});A.command("generate-zig","Generate Zig package definitions from TypeScript packages").option("--packages-dir <dir>","Directory containing TypeScript package files",{default:"src/packages"}).option("--output <file>","Output Zig file path",{default:"packages.zig"}).option("--aliases","Also generate aliases file").option("--aliases-output <file>","Output file for Zig aliases",{default:"aliases.zig"}).action(async(z)=>{try{let{generateZigDefinitions:$,generateZigAliases:Q}=await import("../chunk-7988wrce.js"),{packagesDir:Z="src/packages",output:Y="packages.zig",aliases:X=!1,aliasesOutput:J="aliases.zig"}=z;if(console.log("\uD83D\uDE80 Generating Zig package definitions..."),await $(Z,Y),X)console.log(`
90
90
  \uD83D\uDE80 Generating Zig package aliases...`),await Q(Z,J);console.log(`
91
- ✅ Zig code generation complete!`),L.exit(0)}catch($){console.error("Error generating Zig definitions:",$),L.exit(1)}});A.command("apps","List installed desktop applications with version info").option("-j, --json","Output as JSON").action(async(z)=>{try{let{scanInstalledApps:$}=await import("../chunk-9dtaqjcw.js"),Q=$();if(z.json)console.log(JSON.stringify({success:!0,apps:Q,total:Q.length}));else{console.log(`
91
+ ✅ Zig code generation complete!`),L.exit(0)}catch($){console.error("Error generating Zig definitions:",$),L.exit(1)}});A.command("apps","List installed desktop applications with version info").option("-j, --json","Output as JSON").action(async(z)=>{try{let{scanInstalledApps:$}=await import("../chunk-dyq40v7s.js"),Q=$();if(z.json)console.log(JSON.stringify({success:!0,apps:Q,total:Q.length}));else{console.log(`
92
92
  Installed Desktop Apps (${Q.length}):
93
- `),console.log("Application".padEnd(40)+"Version"),console.log("-".repeat(60));for(let Z of Q)console.log(`${Z.name.padEnd(40)}${Z.version}`)}L.exit(0)}catch($){console.error("Error listing apps:",$),L.exit(1)}});A.command("apps-outdated","Check for outdated desktop applications").option("-j, --json","Output as JSON").action(async(z)=>{try{let{checkAppUpdates:$}=await import("../chunk-9dtaqjcw.js");if(!z.json)console.log("Checking desktop apps for updates...");let Q=$(),Z=Q.filter((Y)=>Y.updateAvailable);if(z.json)console.log(JSON.stringify({success:!0,apps:Q,outdated:Z.length,total:Q.length,timestamp:new Date().toISOString()}));else{if(Z.length>0){console.log(`
93
+ `),console.log("Application".padEnd(40)+"Version"),console.log("-".repeat(60));for(let Z of Q)console.log(`${Z.name.padEnd(40)}${Z.version}`)}L.exit(0)}catch($){console.error("Error listing apps:",$),L.exit(1)}});A.command("apps-outdated","Check for outdated desktop applications").option("-j, --json","Output as JSON").action(async(z)=>{try{let{checkAppUpdates:$}=await import("../chunk-dyq40v7s.js");if(!z.json)console.log("Checking desktop apps for updates...");let Q=$(),Z=Q.filter((Y)=>Y.updateAvailable);if(z.json)console.log(JSON.stringify({success:!0,apps:Q,outdated:Z.length,total:Q.length,timestamp:new Date().toISOString()}));else{if(Z.length>0){console.log(`
94
94
  Outdated Apps (${Z.length}):
95
95
  `),console.log("Application".padEnd(30)+"Current".padEnd(16)+"Latest".padEnd(16)+"Source"),console.log("-".repeat(75));for(let X of Z)console.log(`${X.name.padEnd(30)}${X.currentVersion.padEnd(16)}${(X.latestVersion||"?").padEnd(16)}${X.source}`)}else console.log(`
96
96
  All desktop apps are up to date!`);let Y=Q.filter((X)=>!X.updateAvailable&&X.source!=="system"&&X.source!=="unknown");if(Y.length>0)console.log(`
97
- ${Y.length} app(s) up to date, ${Q.filter((X)=>X.source==="unknown").length} unchecked`)}L.exit(0)}catch($){console.error("Error checking app updates:",$),L.exit(1)}});A.command("apps-update <name>","Update a desktop application via Homebrew").action(async(z)=>{try{let{APP_CASK_MAP:$,getCaskToken:Q,updateApp:Z}=await import("../chunk-9dtaqjcw.js"),Y=$[z]||Q(z);if(!Y)console.error(`No Homebrew cask found for "${z}"`),L.exit(1);console.log(`Updating ${z} (cask: ${Y})...`);let X=await Z(Y);if(X.success)console.log(`Successfully updated ${z} to ${X.version}`);else console.error(`Failed to update ${z}: ${X.error}`),L.exit(1);L.exit(0)}catch($){console.error("Error updating app:",$),L.exit(1)}});A.help();A.version(v6);var U$=A.parse();if(L.argv.length<=2||L.argv.includes("--help")||L.argv.includes("-h"))L.exit(0);
97
+ ${Y.length} app(s) up to date, ${Q.filter((X)=>X.source==="unknown").length} unchecked`)}L.exit(0)}catch($){console.error("Error checking app updates:",$),L.exit(1)}});A.command("apps-update <name>","Update a desktop application via Homebrew").action(async(z)=>{try{let{APP_CASK_MAP:$,getCaskToken:Q,updateApp:Z}=await import("../chunk-dyq40v7s.js"),Y=$[z]||Q(z);if(!Y)console.error(`No Homebrew cask found for "${z}"`),L.exit(1);console.log(`Updating ${z} (cask: ${Y})...`);let X=await Z(Y);if(X.success)console.log(`Successfully updated ${z} to ${X.version}`);else console.error(`Failed to update ${z}: ${X.error}`),L.exit(1);L.exit(0)}catch($){console.error("Error updating app:",$),L.exit(1)}});A.help();A.version(v6);var U$=A.parse();if(L.argv.length<=2||L.argv.includes("--help")||L.argv.includes("-h"))L.exit(0);
@@ -0,0 +1 @@
1
+ import{jb as a,kb as b,lb as c,mb as d,nb as e}from"./chunk-rkak2mvz.js";import"./chunk-z5kje5x9.js";export{d as PACKAGE_ALIASES,c as DEFAULT_TIMEOUT_MS,b as DEFAULT_CACHE_EXPIRATION_MINUTES,a as DEFAULT_CACHE_DIR,e as ALL_KNOWN_PACKAGES};
@@ -1,2 +1,2 @@
1
- import{Ab as T,zb as I}from"./chunk-5kvy4he0.js";import{Bb as _,Cb as w}from"./chunk-jywhngj7.js";import{Gb as y,Jb as M}from"./chunk-sd8qadhd.js";w();async function Y(){try{let{packages:E}=await import("./chunk-hz1p5s8f.js");return E}catch{return{}}}async function F(E){let q=Z(E);if(!q)return null;let z=(await Y())[q];if(!z||!z.versions||z.versions.length===0)return null;return z.versions[0]}async function x(E){let q=Z(E);if(!q)return[];let z=(await Y())[q];if(!z||!z.versions)return[];return[...z.versions]}function f(E={}){let q=["8.4.11","8.3.14","8.2.26","8.1.30"],H=E.fallbackVersions||q;try{let{pantry:z}=(T(),y(I)),G=z.phpnet||z.php;if(!G||!G.versions||G.versions.length===0)return H;let K=[...G.versions],J=E.supportedBranches||D(K),Q=new Map;for(let R of K){let[W,X]=R.split(".");if(!W||!X)continue;let U=`${W}.${X}`;if(J.includes(U)&&!Q.has(U))Q.set(U,R)}let O=J.map((R)=>Q.get(R)).filter(Boolean);return O.length>0?O:H}catch{return H}}function D(E){let q=new Map;for(let z of E){let[G,K]=z.split(".");if(!G||!K)continue;let J=`${G}.${K}`;q.set(J,(q.get(J)||0)+1)}return Array.from(q.keys()).filter((z)=>{let[G]=z.split(".");return G==="8"&&q.get(z)>3}).sort((z,G)=>{let[K,J]=z.split(".").map(Number),[Q,O]=G.split(".").map(Number);if(K!==Q)return Q-K;return O-J}).slice(0,4)}async function C(E,q){return(await x(E)).includes(q)}async function P(E,q="latest"){if(q==="latest")return await F(E);let H=await x(E);if(H.length===0)return null;if(H.includes(q))return q;if(q.startsWith("^")){let G=q.slice(1).split(".")[0];return H.filter((J)=>J.startsWith(`${G}.`))[0]||null}if(q.startsWith("~")){let z=q.slice(1),[G,K]=z.split("."),J=`${G}.${K}.`;return H.filter((O)=>O.startsWith(J))[0]||null}if(q.startsWith(">=")){let z=q.slice(2);return H.filter((K)=>K>=z)[0]||null}return await F(E)}async function $(E){let q=Z(E);if(!q)return null;let z=(await Y())[q];if(!z)return null;let G=await F(E);if(!G)return null;return{name:String(E),domain:q,description:z.description||"",latestVersion:G,totalVersions:z.versions?.length||0,programs:[...z.programs||[]],dependencies:[...z.dependencies||[]],companions:[...z.companions||[]],versions:[...z.versions||[]]}}function Z(E){let q=String(E);if(q in _){let H=_[q];return L(H)}return L(q)}function L(E){if(E.includes("/")){let[q,...H]=E.split("/"),z=H.join("/"),G=q.replace(/\./g,""),K=z.replace(/[/\-_.]/g,"").toLowerCase();return`${G}${K}`.toLowerCase()}return E.replace(/[.-]/g,"").toLowerCase()}async function h(E){let q=[],H=E.toLowerCase();for(let[G,K]of Object.entries(_))if(G.toLowerCase().includes(H)){let J=await $(G);if(J)q.push(J)}let z=await Y();for(let[G,K]of Object.entries(z))if(G.toLowerCase().includes(H)||K.description?.toLowerCase().includes(H)){let J=await $(G);if(J&&!q.some((Q)=>Q.domain===G))q.push(J)}return q}async function N(E){let q=[],H=await Y();for(let z of Object.keys(H))if(E.test(z)){let G=await $(z);if(G)q.push(G)}return q}async function j(E=10){let q=[],H=await Y();for(let z of Object.keys(H)){let G=await $(z);if(G&&G.totalVersions>=E)q.push(G)}return q.sort((z,G)=>G.totalVersions-z.totalVersions)}async function S(E=50){return(await j(5)).slice(0,E)}async function V(E){try{let q=E.lastIndexOf("@");if(q===-1){let J=E;if(!Z(J))return{isValid:!1,error:`Unknown package: ${J}`};return{isValid:!0,packageName:J}}let H=E.slice(0,q),z=E.slice(q+1);if(!Z(H))return{isValid:!1,error:`Unknown package: ${H}`};if(z==="latest")return{isValid:!0,packageName:H,version:z};if(!await C(H,z))return{isValid:!1,packageName:H,version:z,error:`Version ${z} not available for package ${H}`};return{isValid:!0,packageName:H,version:z}}catch{return{isValid:!1,error:`Invalid package specification: ${E}`}}}function d(E,q){if(!q||q.length===0)return null;let H=[...q].sort((O,R)=>{let W=O.split(".").map(Number),X=R.split(".").map(Number);for(let U=0;U<Math.max(W.length,X.length);U++){let A=W[U]||0,B=X[U]||0;if(A!==B)return B-A}return 0}),z=E.replace(/^[\^~]/,""),G=z.split("."),K=Number.parseInt(G[0],10),J=Number.parseInt(G[1]||"0",10);if(E.startsWith("^"))return H.filter((R)=>{return Number.parseInt(R.split(".")[0],10)===K})[0]||null;if(E.startsWith("~"))return H.filter((R)=>{let W=R.split("."),X=Number.parseInt(W[0],10),U=Number.parseInt(W[1]||"0",10);return X===K&&U===J})[0]||null;if(H.includes(z))return z;return H.filter((O)=>O.startsWith(z))[0]||H[0]||null}
2
- export{F as kb,x as lb,f as mb,C as nb,P as ob,$ as pb,Z as qb,h as rb,N as sb,j as tb,S as ub,V as vb,d as wb};
1
+ import{Db as I,Eb as T}from"./chunk-dmcn6rf1.js";import{Fb as _,Gb as w}from"./chunk-cxg0wv4z.js";import{Kb as y,Nb as M}from"./chunk-z5kje5x9.js";w();async function Y(){try{let{packages:E}=await import("./chunk-h75t6wv0.js");return E}catch{return{}}}async function F(E){let q=Z(E);if(!q)return null;let z=(await Y())[q];if(!z||!z.versions||z.versions.length===0)return null;return z.versions[0]}async function x(E){let q=Z(E);if(!q)return[];let z=(await Y())[q];if(!z||!z.versions)return[];return[...z.versions]}function f(E={}){let q=["8.4.11","8.3.14","8.2.26","8.1.30"],H=E.fallbackVersions||q;try{let{pantry:z}=(T(),y(I)),G=z.phpnet||z.php;if(!G||!G.versions||G.versions.length===0)return H;let K=[...G.versions],J=E.supportedBranches||D(K),Q=new Map;for(let R of K){let[W,X]=R.split(".");if(!W||!X)continue;let U=`${W}.${X}`;if(J.includes(U)&&!Q.has(U))Q.set(U,R)}let O=J.map((R)=>Q.get(R)).filter(Boolean);return O.length>0?O:H}catch{return H}}function D(E){let q=new Map;for(let z of E){let[G,K]=z.split(".");if(!G||!K)continue;let J=`${G}.${K}`;q.set(J,(q.get(J)||0)+1)}return Array.from(q.keys()).filter((z)=>{let[G]=z.split(".");return G==="8"&&q.get(z)>3}).sort((z,G)=>{let[K,J]=z.split(".").map(Number),[Q,O]=G.split(".").map(Number);if(K!==Q)return Q-K;return O-J}).slice(0,4)}async function C(E,q){return(await x(E)).includes(q)}async function P(E,q="latest"){if(q==="latest")return await F(E);let H=await x(E);if(H.length===0)return null;if(H.includes(q))return q;if(q.startsWith("^")){let G=q.slice(1).split(".")[0];return H.filter((J)=>J.startsWith(`${G}.`))[0]||null}if(q.startsWith("~")){let z=q.slice(1),[G,K]=z.split("."),J=`${G}.${K}.`;return H.filter((O)=>O.startsWith(J))[0]||null}if(q.startsWith(">=")){let z=q.slice(2);return H.filter((K)=>K>=z)[0]||null}return await F(E)}async function $(E){let q=Z(E);if(!q)return null;let z=(await Y())[q];if(!z)return null;let G=await F(E);if(!G)return null;return{name:String(E),domain:q,description:z.description||"",latestVersion:G,totalVersions:z.versions?.length||0,programs:[...z.programs||[]],dependencies:[...z.dependencies||[]],companions:[...z.companions||[]],versions:[...z.versions||[]]}}function Z(E){let q=String(E);if(q in _){let H=_[q];return L(H)}return L(q)}function L(E){if(E.includes("/")){let[q,...H]=E.split("/"),z=H.join("/"),G=q.replace(/\./g,""),K=z.replace(/[/\-_.]/g,"").toLowerCase();return`${G}${K}`.toLowerCase()}return E.replace(/[.-]/g,"").toLowerCase()}async function h(E){let q=[],H=E.toLowerCase();for(let[G,K]of Object.entries(_))if(G.toLowerCase().includes(H)){let J=await $(G);if(J)q.push(J)}let z=await Y();for(let[G,K]of Object.entries(z))if(G.toLowerCase().includes(H)||K.description?.toLowerCase().includes(H)){let J=await $(G);if(J&&!q.some((Q)=>Q.domain===G))q.push(J)}return q}async function N(E){let q=[],H=await Y();for(let z of Object.keys(H))if(E.test(z)){let G=await $(z);if(G)q.push(G)}return q}async function j(E=10){let q=[],H=await Y();for(let z of Object.keys(H)){let G=await $(z);if(G&&G.totalVersions>=E)q.push(G)}return q.sort((z,G)=>G.totalVersions-z.totalVersions)}async function S(E=50){return(await j(5)).slice(0,E)}async function V(E){try{let q=E.lastIndexOf("@");if(q===-1){let J=E;if(!Z(J))return{isValid:!1,error:`Unknown package: ${J}`};return{isValid:!0,packageName:J}}let H=E.slice(0,q),z=E.slice(q+1);if(!Z(H))return{isValid:!1,error:`Unknown package: ${H}`};if(z==="latest")return{isValid:!0,packageName:H,version:z};if(!await C(H,z))return{isValid:!1,packageName:H,version:z,error:`Version ${z} not available for package ${H}`};return{isValid:!0,packageName:H,version:z}}catch{return{isValid:!1,error:`Invalid package specification: ${E}`}}}function d(E,q){if(!q||q.length===0)return null;let H=[...q].sort((O,R)=>{let W=O.split(".").map(Number),X=R.split(".").map(Number);for(let U=0;U<Math.max(W.length,X.length);U++){let A=W[U]||0,B=X[U]||0;if(A!==B)return B-A}return 0}),z=E.replace(/^[\^~]/,""),G=z.split("."),K=Number.parseInt(G[0],10),J=Number.parseInt(G[1]||"0",10);if(E.startsWith("^"))return H.filter((R)=>{return Number.parseInt(R.split(".")[0],10)===K})[0]||null;if(E.startsWith("~"))return H.filter((R)=>{let W=R.split("."),X=Number.parseInt(W[0],10),U=Number.parseInt(W[1]||"0",10);return X===K&&U===J})[0]||null;if(H.includes(z))return z;return H.filter((O)=>O.startsWith(z))[0]||H[0]||null}
2
+ export{F as ob,x as pb,f as qb,C as rb,P as sb,$ as tb,Z as ub,h as vb,N as wb,j as xb,S as yb,V as zb,d as Ab};
@@ -1 +1 @@
1
- import{$a as i,Ta as a,Ua as b,Va as c,Wa as d,Xa as e,Ya as f,Za as g,_a as h,ab as j,bb as k,cb as l,db as m,eb as n}from"./chunk-9vn4jn9p.js";import"./chunk-jywhngj7.js";import"./chunk-sd8qadhd.js";export{b as shouldProceedWithGitHubRequest,a as saveRateLimitInfo,d as saveGitHubPackageCache,k as resolvePackageDomain,f as logPkgxProjects,m as isKnownAlias,j as guessOriginalDomain,l as getPackageAliases,c as getGitHubPackageCache,n as getCanonicalDomain,g as formatObjectWithoutQuotedKeys,e as fetchPackageListFromGitHub,h as convertDomainToVarName,i as convertDomainToFileName};
1
+ import{$a as e,Xa as a,Ya as b,Za as c,_a as d,ab as f,bb as g,cb as h,db as i,eb as j,fb as k,gb as l,hb as m,ib as n}from"./chunk-cret7mf0.js";import"./chunk-cxg0wv4z.js";import"./chunk-z5kje5x9.js";export{b as shouldProceedWithGitHubRequest,a as saveRateLimitInfo,d as saveGitHubPackageCache,k as resolvePackageDomain,f as logPkgxProjects,m as isKnownAlias,j as guessOriginalDomain,l as getPackageAliases,c as getGitHubPackageCache,n as getCanonicalDomain,g as formatObjectWithoutQuotedKeys,e as fetchPackageListFromGitHub,h as convertDomainToVarName,i as convertDomainToFileName};
@@ -1,4 +1,4 @@
1
- import{Db as R,Eb as T}from"./chunk-04eamjdw.js";import"./chunk-sd8qadhd.js";import E from"node:fs";import I from"node:path";function z(j,J){let L=R(j);if(L.length===0)return J;if(T(j))return L;return[...new Set([...J,...L])]}function O(j){let J=[],L=E.readdirSync(j,{withFileTypes:!0});for(let w of L){let Q=I.join(j,w.name);if(w.isDirectory())J.push(...O(Q));else if(w.isFile()&&w.name.endsWith(".ts")&&w.name!=="index.ts"&&w.name!=="aliases.ts")J.push(Q)}return J}function C(j,J){let L=j.startsWith("v")?j.slice(1):j,w=J.startsWith("v")?J.slice(1):J,Q=L.split(/[.-]/),W=w.split(/[.-]/);for(let q=0;q<Math.max(Q.length,W.length);q++){let K=Q[q]||"0",X=W[q]||"0",_=Number.parseInt(K,10),$=Number.parseInt(X,10);if(!Number.isNaN(_)&&!Number.isNaN($)){if(_>$)return-1;if(_<$)return 1}else{if(K>X)return-1;if(K<X)return 1}}return 0}function Y(j){return j.replace(/\\/g,"\\\\").replace(/"/g,"\\\"").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t")}function V(j){let J=j.programs.map((q)=>`"${Y(q)}"`).join(", "),L=j.dependencies.map((q)=>`"${Y(q)}"`).join(", "),w=j.buildDependencies.map((q)=>`"${Y(q)}"`).join(", "),Q=j.aliases.map((q)=>`"${Y(q)}"`).join(", "),W=j.versions.map((q)=>`"${Y(q)}"`).join(", ");return` .{
1
+ import{Hb as R,Ib as T}from"./chunk-9yep1cys.js";import"./chunk-z5kje5x9.js";import E from"node:fs";import I from"node:path";function z(j,J){let L=R(j);if(L.length===0)return J;if(T(j))return L;return[...new Set([...J,...L])]}function O(j){let J=[],L=E.readdirSync(j,{withFileTypes:!0});for(let w of L){let Q=I.join(j,w.name);if(w.isDirectory())J.push(...O(Q));else if(w.isFile()&&w.name.endsWith(".ts")&&w.name!=="index.ts"&&w.name!=="aliases.ts")J.push(Q)}return J}function C(j,J){let L=j.startsWith("v")?j.slice(1):j,w=J.startsWith("v")?J.slice(1):J,Q=L.split(/[.-]/),W=w.split(/[.-]/);for(let q=0;q<Math.max(Q.length,W.length);q++){let K=Q[q]||"0",X=W[q]||"0",_=Number.parseInt(K,10),$=Number.parseInt(X,10);if(!Number.isNaN(_)&&!Number.isNaN($)){if(_>$)return-1;if(_<$)return 1}else{if(K>X)return-1;if(K<X)return 1}}return 0}function Y(j){return j.replace(/\\/g,"\\\\").replace(/"/g,"\\\"").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t")}function V(j){let J=j.programs.map((q)=>`"${Y(q)}"`).join(", "),L=j.dependencies.map((q)=>`"${Y(q)}"`).join(", "),w=j.buildDependencies.map((q)=>`"${Y(q)}"`).join(", "),Q=j.aliases.map((q)=>`"${Y(q)}"`).join(", "),W=j.versions.map((q)=>`"${Y(q)}"`).join(", ");return` .{
2
2
  .name = "${Y(j.name)}",
3
3
  .domain = "${Y(j.domain)}",
4
4
  .description = "${Y(j.description)}",
@@ -1,2 +1,2 @@
1
1
  var j=[{domain:"php.net",aliases:["php"]},{domain:"ruby-lang.org",aliases:["ruby"]},{domain:"go.dev",aliases:["go"]},{domain:"nodejs.org",aliases:["node"]},{domain:"python.org",aliases:["python","py"]},{domain:"openjdk.org",aliases:["java","jdk"]},{domain:"kotlinlang.org",aliases:["kotlin"]},{domain:"scala-lang.org",aliases:["scala"]},{domain:"deno.land",aliases:["deno"]},{domain:"openssl.org",aliases:["openssl"]},{domain:"cmake.org",aliases:["cmake"]},{domain:"gradle.org",aliases:["gradle"]},{domain:"maven.apache.org",aliases:["maven","mvn"]},{domain:"curl.se",aliases:["curl"]},{domain:"git-scm.com",aliases:["git"]},{domain:"vim.org",aliases:["vim","vi"]},{domain:"gnupg.org",aliases:["gpg"]},{domain:"crates.io/ripgrep",aliases:["ripgrep","rg"]},{domain:"npmjs.com",aliases:["npm"]},{domain:"classic.yarnpkg.com",aliases:["yarn"]},{domain:"bun.sh",aliases:["bun","bun.com"]},{domain:"docker.com/cli",aliases:["docker"]},{domain:"terraform.io",aliases:["terraform"]},{domain:"kubernetes.io/kubectl",aliases:["kubectl"]},{domain:"helm.sh",aliases:["helm"]},{domain:"sqlite.org",aliases:["sqlite"]},{domain:"postgresql.org",aliases:["postgres","postgresql"]},{domain:"redis.io",aliases:["redis"]},{domain:"mysql.com",aliases:["mysql"]},{domain:"s3tools.org",aliases:["s3cmd"]},{domain:"aws.amazon.com/cdk",aliases:["cdk","aws/cdk"]},{domain:"info-zip.org/zip",aliases:["zip"]},{domain:"info-zip.org/unzip",aliases:["unzip"]}];function k(b){let c=j.find((h)=>h.domain===b);return c?c.aliases:[]}function q(b){return j.find((h)=>h.domain===b)?.replace===!0}function u(){let b={};for(let c of j)for(let h of c.aliases)b[h]=c.domain;return b}
2
- export{k as Db,q as Eb,u as Fb};
2
+ export{k as Hb,q as Ib,u as Jb};
@@ -1,4 +1,4 @@
1
- import{Bb as y,Cb as H}from"./chunk-jywhngj7.js";import{Jb as E}from"./chunk-sd8qadhd.js";H();import x from"node:fs";import S from"node:path";import A from"node:process";var O=S.join(A.cwd(),"github-rate-limit.json"),w=S.join(A.cwd(),"github-cache.json"),R=10,W=3600000;function F(X){try{let J=X.get("X-RateLimit-Remaining"),$=X.get("X-RateLimit-Reset"),Z=X.get("X-RateLimit-Limit");if(J&&$&&Z){let V=new Date(Number($)*1000),Y={remaining:Number(J),limit:Number(Z),resetTime:V.toISOString(),resetTimestamp:Number($)*1000,lastUpdated:new Date().toISOString()};x.writeFileSync(O,JSON.stringify(Y,null,2)),console.warn(`GitHub API rate limit info saved to ${O}`),console.warn(`Rate limit: ${J}/${Z} remaining, resets at ${V.toLocaleString()}`)}}catch(J){console.error("Failed to save GitHub rate limit info:",J)}}function M(){try{if(!x.existsSync(O))return!0;let X=JSON.parse(x.readFileSync(O,"utf8")),J=Date.now();if(J>=X.resetTimestamp)return!0;if(X.remaining<=R){let $=new Date(X.resetTimestamp);console.warn(`GitHub API rate limit almost exhausted (${X.remaining}/${X.limit} remaining). Preserving remaining calls until reset at ${$.toLocaleString()}`);let Z=X.resetTimestamp-J;if(Z<300000)console.error(`Waiting ${Math.round(Z/1000)} seconds for rate limit to reset...`);return!1}return!0}catch(X){return console.error("Error checking GitHub rate limit:",X),!0}}function T(){try{if(!x.existsSync(w))return null;let X=JSON.parse(x.readFileSync(w,"utf8")),J=Date.now();if(X.timestamp&&J-X.timestamp<W){let $=new Date(X.timestamp+W);if(console.error(`Using GitHub API cache from ${new Date(X.timestamp).toLocaleString()}, expires at ${$.toLocaleString()}`),Array.isArray(X.packages))return console.error(`Using ${X.packages.length} packages from GitHub API cache`),X.packages;else if(Array.isArray(X.data))return console.error(`Using ${X.data.length} packages from GitHub API cache (old format)`),X.data;else return console.error("GitHub API cache has invalid format, fetching fresh data"),null}return console.error(`GitHub API cache expired (older than ${W/1000/60} minutes), fetching fresh data`),null}catch(X){return console.error("Error reading GitHub cache:",X),null}}function U(X){try{let J={timestamp:Date.now(),packages:X};x.writeFileSync(w,JSON.stringify(J,null,2)),console.error(`GitHub API package list cached to ${w} (${X.length} packages)`)}catch(J){console.error("Error saving GitHub cache:",J)}}async function k(X=0,J){if(J){if(J.startsWith("/")||J.includes("/bin/"))return console.error(`Error: '${J}' appears to be a path, not a valid package name.`),[];return console.log(`Single package mode: only fetching '${J}'`),[J]}console.log("Fetching package list from GitHub API...");let $=T();if($)return console.log("Using cached package list, no GitHub API calls needed"),X>0?$.slice(0,X):$;try{if(!M()){console.warn("GitHub API rate limit preventing request - using cached data or hardcoded list");let z=["node","bun.sh","python.org","go.dev","rust-lang.org","deno.land","ruby-lang.org","php.net","dart.dev","postgresql.org","mozilla.org","mysql.com","nginx.org","redis.io","mongodb.com"];return U(z),X>0?z.slice(0,X):z}console.error("No valid cache found, making GitHub API requests");let Z=await fetch("https://api.github.com/repos/pkgxdev/pantry/contents/projects",{headers:{Accept:"application/vnd.github.v3+json","User-Agent":"ts-pantry"}});if(F(Z.headers),!Z.ok)throw Error(`GitHub API responded with ${Z.status}: ${Z.statusText}`);let Y=(await Z.json()).filter((z)=>z.type==="dir").map((z)=>z.name);console.error(`Found ${Y.length} base projects on GitHub`);let q=[...Y],K=["agwa.name","acorn.io","apache.org","aquasecurity.github.io","aws.amazon.com"],C=["alsa-project.org/alsa-lib","apple.com/remote_cmds","android.com/cmdline-tools","anchore.com/syft","argoproj.github.io/cd","argoproj.github.io/workflows","amrdeveloper.github.io/GQL","authzed.com/spicedb","arduino.github.io/arduino-cli","aomedia.googlesource.com/aom","akuity.io/kargo","asciinema.org/agg","ansible.com/ansible-lint","astral.sh/ruff","astral.sh/uv","apollographql.com/rover","brxken128.github.io/dexios","cedarpolicy.com/cli","blake2.net/libb2"];for(let z of K){if(!M()){console.error(`Skipping nested path check for ${z} due to rate limit concerns`);continue}try{console.error(`Checking for nested projects in ${z}...`);let Q=await fetch(`https://api.github.com/repos/pkgxdev/pantry/contents/projects/${z}`,{headers:{Accept:"application/vnd.github.v3+json","User-Agent":"ts-pantry"}});if(F(Q.headers),!Q.ok){console.error(`Failed to fetch nested projects for ${z}: ${Q.status}`);continue}let B=(await Q.json()).filter((v)=>v.type==="dir").map((v)=>`${z}/${v.name}`);console.error(`Found ${B.length} nested projects for ${z}: ${B.join(", ")}`),q.push(...B)}catch(Q){console.error(`Error fetching nested projects for ${z}:`,Q)}}for(let z of C)if(!q.includes(z))console.error(`Adding known nested project: ${z}`),q.push(z);U(q),console.error(`Cached ${q.length} packages for future use (valid for ${W/60000} minutes)`);let D=X>0?q.slice(0,X):q;return console.error(`Total of ${q.length} projects found (including nested paths)`),D}catch(Z){return console.error("Error fetching package list from GitHub:",Z),[]}}async function b(){try{let{fetchPkgxProjects:X}=await import("./chunk-7vhbay27.js"),J=await X();if(console.error(`Found ${J.length} projects`),J.length>0){if(console.error("First 10 projects:"),J.slice(0,10).forEach(($)=>{console.error(`- ${$.name}`)}),J.length>10)console.error(`... and ${J.length-10} more`)}return J}catch(X){return console.error("Failed to fetch projects:",X),[]}}function G(X,J=2){if(X===null)return"null";if(X===void 0)return"undefined";if(Array.isArray(X)){if(X.length===0)return"[]";if(X.every((Z)=>typeof Z==="string")){if(X.length===1)return`[${JSON.stringify(X[0])}]`;let Z=X.map((V)=>JSON.stringify(V)).join(`,
1
+ import{Fb as y,Gb as H}from"./chunk-cxg0wv4z.js";import{Nb as E}from"./chunk-z5kje5x9.js";H();import x from"node:fs";import S from"node:path";import A from"node:process";var O=S.join(A.cwd(),"github-rate-limit.json"),w=S.join(A.cwd(),"github-cache.json"),R=10,W=3600000;function F(X){try{let J=X.get("X-RateLimit-Remaining"),$=X.get("X-RateLimit-Reset"),Z=X.get("X-RateLimit-Limit");if(J&&$&&Z){let V=new Date(Number($)*1000),Y={remaining:Number(J),limit:Number(Z),resetTime:V.toISOString(),resetTimestamp:Number($)*1000,lastUpdated:new Date().toISOString()};x.writeFileSync(O,JSON.stringify(Y,null,2)),console.warn(`GitHub API rate limit info saved to ${O}`),console.warn(`Rate limit: ${J}/${Z} remaining, resets at ${V.toLocaleString()}`)}}catch(J){console.error("Failed to save GitHub rate limit info:",J)}}function M(){try{if(!x.existsSync(O))return!0;let X=JSON.parse(x.readFileSync(O,"utf8")),J=Date.now();if(J>=X.resetTimestamp)return!0;if(X.remaining<=R){let $=new Date(X.resetTimestamp);console.warn(`GitHub API rate limit almost exhausted (${X.remaining}/${X.limit} remaining). Preserving remaining calls until reset at ${$.toLocaleString()}`);let Z=X.resetTimestamp-J;if(Z<300000)console.error(`Waiting ${Math.round(Z/1000)} seconds for rate limit to reset...`);return!1}return!0}catch(X){return console.error("Error checking GitHub rate limit:",X),!0}}function T(){try{if(!x.existsSync(w))return null;let X=JSON.parse(x.readFileSync(w,"utf8")),J=Date.now();if(X.timestamp&&J-X.timestamp<W){let $=new Date(X.timestamp+W);if(console.error(`Using GitHub API cache from ${new Date(X.timestamp).toLocaleString()}, expires at ${$.toLocaleString()}`),Array.isArray(X.packages))return console.error(`Using ${X.packages.length} packages from GitHub API cache`),X.packages;else if(Array.isArray(X.data))return console.error(`Using ${X.data.length} packages from GitHub API cache (old format)`),X.data;else return console.error("GitHub API cache has invalid format, fetching fresh data"),null}return console.error(`GitHub API cache expired (older than ${W/1000/60} minutes), fetching fresh data`),null}catch(X){return console.error("Error reading GitHub cache:",X),null}}function U(X){try{let J={timestamp:Date.now(),packages:X};x.writeFileSync(w,JSON.stringify(J,null,2)),console.error(`GitHub API package list cached to ${w} (${X.length} packages)`)}catch(J){console.error("Error saving GitHub cache:",J)}}async function k(X=0,J){if(J){if(J.startsWith("/")||J.includes("/bin/"))return console.error(`Error: '${J}' appears to be a path, not a valid package name.`),[];return console.log(`Single package mode: only fetching '${J}'`),[J]}console.log("Fetching package list from GitHub API...");let $=T();if($)return console.log("Using cached package list, no GitHub API calls needed"),X>0?$.slice(0,X):$;try{if(!M()){console.warn("GitHub API rate limit preventing request - using cached data or hardcoded list");let z=["node","bun.sh","python.org","go.dev","rust-lang.org","deno.land","ruby-lang.org","php.net","dart.dev","postgresql.org","mozilla.org","mysql.com","nginx.org","redis.io","mongodb.com"];return U(z),X>0?z.slice(0,X):z}console.error("No valid cache found, making GitHub API requests");let Z=await fetch("https://api.github.com/repos/pkgxdev/pantry/contents/projects",{headers:{Accept:"application/vnd.github.v3+json","User-Agent":"ts-pantry"}});if(F(Z.headers),!Z.ok)throw Error(`GitHub API responded with ${Z.status}: ${Z.statusText}`);let Y=(await Z.json()).filter((z)=>z.type==="dir").map((z)=>z.name);console.error(`Found ${Y.length} base projects on GitHub`);let q=[...Y],K=["agwa.name","acorn.io","apache.org","aquasecurity.github.io","aws.amazon.com"],C=["alsa-project.org/alsa-lib","apple.com/remote_cmds","android.com/cmdline-tools","anchore.com/syft","argoproj.github.io/cd","argoproj.github.io/workflows","amrdeveloper.github.io/GQL","authzed.com/spicedb","arduino.github.io/arduino-cli","aomedia.googlesource.com/aom","akuity.io/kargo","asciinema.org/agg","ansible.com/ansible-lint","astral.sh/ruff","astral.sh/uv","apollographql.com/rover","brxken128.github.io/dexios","cedarpolicy.com/cli","blake2.net/libb2"];for(let z of K){if(!M()){console.error(`Skipping nested path check for ${z} due to rate limit concerns`);continue}try{console.error(`Checking for nested projects in ${z}...`);let Q=await fetch(`https://api.github.com/repos/pkgxdev/pantry/contents/projects/${z}`,{headers:{Accept:"application/vnd.github.v3+json","User-Agent":"ts-pantry"}});if(F(Q.headers),!Q.ok){console.error(`Failed to fetch nested projects for ${z}: ${Q.status}`);continue}let B=(await Q.json()).filter((v)=>v.type==="dir").map((v)=>`${z}/${v.name}`);console.error(`Found ${B.length} nested projects for ${z}: ${B.join(", ")}`),q.push(...B)}catch(Q){console.error(`Error fetching nested projects for ${z}:`,Q)}}for(let z of C)if(!q.includes(z))console.error(`Adding known nested project: ${z}`),q.push(z);U(q),console.error(`Cached ${q.length} packages for future use (valid for ${W/60000} minutes)`);let D=X>0?q.slice(0,X):q;return console.error(`Total of ${q.length} projects found (including nested paths)`),D}catch(Z){return console.error("Error fetching package list from GitHub:",Z),[]}}async function b(){try{let{fetchPkgxProjects:X}=await import("./chunk-qfevhm4j.js"),J=await X();if(console.error(`Found ${J.length} projects`),J.length>0){if(console.error("First 10 projects:"),J.slice(0,10).forEach(($)=>{console.error(`- ${$.name}`)}),J.length>10)console.error(`... and ${J.length-10} more`)}return J}catch(X){return console.error("Failed to fetch projects:",X),[]}}function G(X,J=2){if(X===null)return"null";if(X===void 0)return"undefined";if(Array.isArray(X)){if(X.length===0)return"[]";if(X.every((Z)=>typeof Z==="string")){if(X.length===1)return`[${JSON.stringify(X[0])}]`;let Z=X.map((V)=>JSON.stringify(V)).join(`,
2
2
  ${" ".repeat(J)}`);return`[
3
3
  ${" ".repeat(J)}${Z}
4
4
  ${" ".repeat(J-2)}]`}let $=X.map((Z)=>G(Z,J+2)).join(`,
@@ -8,4 +8,4 @@ ${" ".repeat(J)}]`}if(typeof X==="object")return`{
8
8
  ${Object.entries(X).map(([Z,V])=>{let Y=typeof V==="string"?JSON.stringify(V):G(V,J+2);return`${" ".repeat(J)}${Z}: ${Y}`}).join(`,
9
9
  `)}
10
10
  }`;return String(X)}function g(X){if(X.includes("/")){let J=X.split("/"),$=J[0],Z=J.slice(1),V=$.replace(/[.-]/g,""),Y=Z.map((K)=>K.replace(/[.-]/g,"")),q="";if(Y.length>0){let K=Y[0];if(V.includes(K.toLowerCase()))q="";else if(Y.length===1)q=K;else q=K}return`${V}${q}`.toLowerCase()}return X.replace(/[.-]/g,"").toLowerCase()}function j(X){if(X.includes("/")){let[J,$]=X.split("/"),Z=J.replace(/\./g,""),V=$.replace(/\//g,"-");return`${Z}-${V}`.toLowerCase()}return X.replace(/\./g,"").toLowerCase()}function p(X){if(X.includes("-")){let $=X.indexOf("-"),Z=X.substring(0,$),V=X.substring($+1),Y=Z;if(Y.endsWith("org")&&!Y.endsWith(".org"))Y=Y.replace(/org$/,".org");if(Y.endsWith("io")&&!Y.endsWith(".io"))Y=Y.replace(/io$/,".io");if(Y.endsWith("com")&&!Y.endsWith(".com"))Y=Y.replace(/com$/,".com");if(Y.endsWith("sh")&&!Y.endsWith(".sh"))Y=Y.replace(/sh$/,".sh");if(Y.endsWith("dev")&&!Y.endsWith(".dev"))Y=Y.replace(/dev$/,".dev");if(Y.endsWith("net")&&!Y.endsWith(".net"))Y=Y.replace(/net$/,".net");if(Y.endsWith("name")&&!Y.endsWith(".name"))Y=Y.replace(/name$/,".name");return`${Y}/${V}`}let J=X;if(J.endsWith("org")&&!J.endsWith(".org"))J=J.replace(/org$/,".org");if(J.endsWith("io")&&!J.endsWith(".io"))J=J.replace(/io$/,".io");if(J.endsWith("com")&&!J.endsWith(".com"))J=J.replace(/com$/,".com");if(J.endsWith("sh")&&!J.endsWith(".sh"))J=J.replace(/sh$/,".sh");if(J.endsWith("dev")&&!J.endsWith(".dev"))J=J.replace(/dev$/,".dev");if(J.endsWith("net")&&!J.endsWith(".net"))J=J.replace(/net$/,".net");if(J.endsWith("land")&&!J.endsWith(".land"))J=J.replace(/land$/,".land");return J}function N(X){let[J]=X.split("@");if(y[J])return y[J];if(J.includes("."))return J;return`${J}.org`}function P(){return{...y}}function h(X){let[J]=X.split("@");return J in y}function l(X){return N(X)}
11
- export{F as Ta,M as Ua,T as Va,U as Wa,k as Xa,b as Ya,G as Za,g as _a,j as $a,p as ab,N as bb,P as cb,h as db,l as eb};
11
+ export{F as Xa,M as Ya,T as Za,U as _a,k as $a,b as ab,G as bb,g as cb,j as db,p as eb,N as fb,P as gb,h as hb,l as ib};