From 572500d7144953f5436615693623d5eb091007d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Belin?= Date: Mon, 22 Jan 2024 21:01:22 +0100 Subject: [PATCH] Port the source code to TypeScript --- bin/mc2it_card.js | 50 ++++++++++++++++------------------ package.json | 6 ++--- src/card.ts | 26 ++++++++++++++++++ src/cli.ts | 30 +++++++++++++++++++++ src/index.ts | 1 + src/mc2it_card/Program.hx | 56 --------------------------------------- tool/dist.js | 2 +- 7 files changed, 84 insertions(+), 87 deletions(-) create mode 100644 src/card.ts create mode 100644 src/cli.ts create mode 100644 src/index.ts delete mode 100644 src/mc2it_card/Program.hx diff --git a/bin/mc2it_card.js b/bin/mc2it_card.js index 6977618..baaa1b8 100755 --- a/bin/mc2it_card.js +++ b/bin/mc2it_card.js @@ -1,30 +1,26 @@ #!/usr/bin/env node -(function(je){"use strict";var S=function(){return R.__string_rec(this,"")},O=O||{},u,Le=require("child_process");class p{static string(e){return R.__string_rec(e,"")}static parseInt(e){let t=parseInt(e);return isNaN(t)?null:t}}p.__name__=!0;class Q{static environment(){let e=new ge,t=0,r=oe.fields(process.env);for(;t=0&&e=e.length)break;if(!this.matchSub(e,r)){n+=p.string(g.substr(e,r,null));break}let s=this.matchedPos();n+=p.string(g.substr(e,r,s.pos-r)),n+=p.string(t(this)),s.len==0?(n+=p.string(g.substr(e,s.pos,1)),r=s.pos+1):r=s.pos+s.len}while(this.r.global);return!this.r.global&&r>0&&r0){let k=n[n.length-1]+1,N="",j=0;for(;j2)return 0}let r=Q.environment().h.TERM;return r!=null&&new U("cygwin|xterm|vt100","").match(r)?0:2}static exec(e,t){let r=Le.spawnSync(e,t??[],{}),n=r.stdout==null?"":r.stdout.toString();return n==null&&(n=""),{exit:r.status,stdout:n}}}f.__name__=!0;class ne{static fromString(e){if(e=e.toLowerCase(),e.charAt(0)=="#"||g.substr(e,0,3)=="bg#"){let t=e.indexOf("#"),r=g.substr(e,t+1,null);if(r.length==3){let s=r.split("");r=[s[0],s[0],s[1],s[1],s[2],s[2]].join("")}return new U("[^0-9a-f]","i").match(r)||r.length<6?"":e.substring(0,t)+"#"+r}switch(e){case"!":return"invert";case"/":return"reset";case"b":return"bold";case"bg_gray":return"bg_light_black";case"gray":return"light_black";case"i":return"italic";case"u":return"underline";default:return e}}}class g{static cca(e,t){let r=e.charCodeAt(t);if(r==r)return r}static substr(e,t,r){if(r==null)r=e.length;else if(r<0)if(t==0)r=e.length+r;else return"";return e.substr(t,r)}static now(){return Date.now()}}g.__name__=!0;class X{static fold(e,t,r){let n=Re(e);for(;n.hasNext();)r=t(n.next(),r);return r}static find(e,t){let r=Re(e);for(;r.hasNext();){let n=r.next();if(t(n))return n}return null}}X.__name__=!0,Math.__name__=!0;class _e{constructor(){this.b=""}toString(){return this.b}}_e.__name__=!0;class A{static isSpace(e,t){let r=g.cca(e,t);return r>8&&r<14?!0:r==32}static ltrim(e){let t=e.length,r=0;for(;r0?g.substr(e,r,t-r):e}static rtrim(e){let t=e.length,r=0;for(;r0?g.substr(e,0,t-r):e}static trim(e){return A.ltrim(A.rtrim(e))}static lpad(e,t,r){if(t.length<=0)return e;let n="";for(r-=e.length;n.lengthe.length)throw F.thrown(W.OutsideBounds);let n=e.b,s=r;for(;s>0;)this.writeByte(n[t]),++t,--s;return r}writeFullBytes(e,t,r){for(;r>0;){let n=this.writeBytes(e,t,r);t+=n,r-=n}}writeString(e,t){let r=H.ofString(e,t);this.writeFullBytes(r,0,r.length)}}he.__name__=!0;class se extends he{constructor(e){super(),this.fd=e}writeByte(e){le.writeSync(this.fd,String.fromCodePoint(e))}writeBytes(e,t,r){let n=e.b;return le.writeSync(this.fd,pe.from(n.buffer,n.byteOffset,e.length),t,r)}writeString(e,t){le.writeSync(this.fd,e)}}se.__name__=!0;var C=O["haxe.StackItem"]={__ename__:!0,__constructs__:null,CFunction:{_hx_name:"CFunction",_hx_index:0,__enum__:"haxe.StackItem",toString:S},Module:(u=function(i){return{_hx_index:1,m:i,__enum__:"haxe.StackItem",toString:S}},u._hx_name="Module",u.__params__=["m"],u),FilePos:(u=function(i,e,t,r){return{_hx_index:2,s:i,file:e,line:t,column:r,__enum__:"haxe.StackItem",toString:S}},u._hx_name="FilePos",u.__params__=["s","file","line","column"],u),Method:(u=function(i,e){return{_hx_index:3,classname:i,method:e,__enum__:"haxe.StackItem",toString:S}},u._hx_name="Method",u.__params__=["classname","method"],u),LocalFunction:(u=function(i){return{_hx_index:4,v:i,__enum__:"haxe.StackItem",toString:S}},u._hx_name="LocalFunction",u.__params__=["v"],u)};C.__constructs__=[C.CFunction,C.Module,C.FilePos,C.Method,C.LocalFunction];class F extends Error{constructor(e,t,r){super(e),this.message=e,this.__previousException=t,this.__nativeException=r??this}unwrap(){return this.__nativeException}toString(){return this.get_message()}get_message(){return this.message}get_native(){return this.__nativeException}static caught(e){return e instanceof F?e:e instanceof Error?new F(e.message,null,e):new ie(e,null,e)}static thrown(e){return e instanceof F?e.get_native():e instanceof Error?e:new ie(e)}}F.__name__=!0;class ie extends F{constructor(e,t,r){super(String(e),t,r),this.value=e}unwrap(){return this.value}}ie.__name__=!0;class ge{constructor(){this.h=Object.create(null)}}ge.__name__=!0;class de extends F{constructor(e,t,r){super(e,t),r==null?this.posInfos={fileName:"(unknown)",lineNumber:0,className:"(unknown)",methodName:"(unknown)"}:this.posInfos=r}toString(){return""+super.toString()+" in "+this.posInfos.className+"."+this.posInfos.methodName+" at "+this.posInfos.fileName+":"+this.posInfos.lineNumber}}de.__name__=!0;class fe extends de{constructor(e,t,r){e==null&&(e="Not implemented"),super(e,t,r)}}fe.__name__=!0;class H{constructor(e){this.length=e.byteLength,this.b=new Uint8Array(e),this.b.bufferValue=e,e.hxBytes=this,e.bytes=this.b}static ofString(e,t){if(t==Z.RawNative){let s=new Uint8Array(e.length<<1),c=0,l=e.length;for(;c>8}return new H(s.buffer)}let r=[],n=0;for(;n>6),r.push(128|s&63)):s<=65535?(r.push(224|s>>12),r.push(128|s>>6&63),r.push(128|s&63)):(r.push(240|s>>18),r.push(128|s>>12&63),r.push(128|s>>6&63),r.push(128|s&63))}return new H(new Uint8Array(r).buffer)}}H.__name__=!0;var Z=O["haxe.io.Encoding"]={__ename__:!0,__constructs__:null,UTF8:{_hx_name:"UTF8",_hx_index:0,__enum__:"haxe.io.Encoding",toString:S},RawNative:{_hx_name:"RawNative",_hx_index:1,__enum__:"haxe.io.Encoding",toString:S}};Z.__constructs__=[Z.UTF8,Z.RawNative];var W=O["haxe.io.Error"]={__ename__:!0,__constructs__:null,Blocked:{_hx_name:"Blocked",_hx_index:0,__enum__:"haxe.io.Error",toString:S},Overflow:{_hx_name:"Overflow",_hx_index:1,__enum__:"haxe.io.Error",toString:S},OutsideBounds:{_hx_name:"OutsideBounds",_hx_index:2,__enum__:"haxe.io.Error",toString:S},Custom:(u=function(i){return{_hx_index:3,e:i,__enum__:"haxe.io.Error",toString:S}},u._hx_name="Custom",u.__params__=["e"],u)};W.__constructs__=[W.Blocked,W.Overflow,W.OutsideBounds,W.Custom];class me{constructor(e){this.current=0,this.array=e}hasNext(){return this.current=5)return"<...>";let r=typeof e;switch(r=="function"&&(e.__name__||e.__ename__)&&(r="object"),r){case"function":return"";case"object":if(e.__enum__){let a=O[e.__enum__].__constructs__[e._hx_index],m=a._hx_name;return a.__params__?(t=t+" ",m+"("+function(_){var h;let b=[];{let d=0,w=a.__params__;for(;d0?",":"")+R.__string_rec(e[_],t)}return o+="]",o}let n;try{n=e.toString}catch{return"???"}if(n!=null&&n!=Object.toString&&typeof n=="function"){let o=e.toString();if(o!="[object Object]")return o}let s=`{ -`;t+=" ";let c=e.hasOwnProperty!=null,l=null;for(l in e)c&&!e.hasOwnProperty(l)||l=="prototype"||l=="__class__"||l=="__super__"||l=="__interfaces__"||l=="__properties__"||(s.length!=2&&(s+=`, -`),s+=t+l+" : "+R.__string_rec(e[l],t));return t=t.substring(1),s+=` -`+t+"}",s;case"string":return e;default:return String(e)}}}R.__name__=!0;var le=require("fs"),pe=require("buffer").Buffer;class y{static center(e,t){return y.line(e,""+y.repeat(e," ",Math.floor((39-y.getLength(e,t))/2))+t)}static footer(e){return y.addLine(e,"\u2570"+y.repeat(e,"\u2500")+"\u256F")}static header(e){return y.addLine(e,"\u256D"+y.repeat(e,"\u2500")+"\u256E")}static label(e,t,r){return y.line(e,A.lpad(""+t+": "," ",28)+r)}static line(e,t){return t==null&&(t=""),y.addLine(e,"\u2502"+t+y.repeat(e," ",39-y.getLength(e,t))+"\u2502")}static addLine(e,t){return e.b+=p.string(" "+t+P.newLine),e}static getLength(e,t){let r=new RegExp("<[^<]*>","g".split("u").join(""));return t.replace(r,"").length}static repeat(e,t,r){r==null&&(r=39);let n=[],s=0;for(;sMC2IT - Distribution & Services")),"GitHub","https://github.com/mc2it")),"Card","npx @mc2it/card"),"Email","dev@mc2it.com"),"Website","https://www.mc2it.com")));f.formatMode=0,f.logPrefix="";let t=f.logPrefix+(""+P.newLine+p.string(e));return t==null&&(t=""),f.printFormatted(t+` -`,0),Y.NOISE}static main(){new we(new P,new ve(5)).process(process.argv.slice(2)).handle(be.exit)}}P.__name__=!0;class be{static exit(e){switch(e._hx_index){case 0:process.exit(0);break;case 1:let t=e.failure,r=t.message;t.data!=null&&(r+=", "+(t.data==null?"null":p.string(t.data))),process.stdout.write(p.string(r)),process.stdout.write(` -`);let n=t.code;process.exit(n);break}}}be.__name__=!0;class xe{constructor(e){this.buffer=e}}xe.__name__=!0;class q{static get(){return q.doc==null&&(q.doc={doc:`\r - Print the business card of MC2IT, distribution and services.\r -\r - > npx @mc2it/card [flags]\r -`,commands:[{isDefault:!0,isSub:!1,names:[],doc:null}],flags:[{names:["--help"],aliases:["h"],doc:" Display this help. "},{names:["--version"],aliases:["v"],doc:" Output the version number. "}]}),q.doc}}q.__name__=!0;class ee{constructor(e,t,r){this.command=e,this.prompt=t,this.hasFlags=r}processArgs(e){let t=this;return this.hasFlags?I.catchExceptions(function(){let r=ee.expandAssignments(e),n=[],s=0,c=!1;for(;s()=>(F||u((F={exports:{}}).exports,F),F.exports);var Bu=(u,F,e,D)=>{if(F&&typeof F=="object"||typeof F=="function")for(let C of ou(F))!su.call(u,C)&&C!==e&&oD(u,C,{get:()=>F[C],enumerable:!(D=iu(F,C))||D.enumerable});return u};var T=(u,F,e)=>(e=u!=null?nu(lu(u)):{},Bu(F||!u||!u.__esModule?oD(e,"default",{value:u,enumerable:!0}):e,u));var BD=h((A0,P)=>{var d={};typeof P>"u"?window.eastasianwidth=d:P.exports=d;d.eastAsianWidth=function(u){var F=u.charCodeAt(0),e=u.length==2?u.charCodeAt(1):0,D=F;return 55296<=F&&F<=56319&&56320<=e&&e<=57343&&(F&=1023,e&=1023,D=F<<10|e,D+=65536),D==12288||65281<=D&&D<=65376||65504<=D&&D<=65510?"F":D==8361||65377<=D&&D<=65470||65474<=D&&D<=65479||65482<=D&&D<=65487||65490<=D&&D<=65495||65498<=D&&D<=65500||65512<=D&&D<=65518?"H":4352<=D&&D<=4447||4515<=D&&D<=4519||4602<=D&&D<=4607||9001<=D&&D<=9002||11904<=D&&D<=11929||11931<=D&&D<=12019||12032<=D&&D<=12245||12272<=D&&D<=12283||12289<=D&&D<=12350||12353<=D&&D<=12438||12441<=D&&D<=12543||12549<=D&&D<=12589||12593<=D&&D<=12686||12688<=D&&D<=12730||12736<=D&&D<=12771||12784<=D&&D<=12830||12832<=D&&D<=12871||12880<=D&&D<=13054||13056<=D&&D<=19903||19968<=D&&D<=42124||42128<=D&&D<=42182||43360<=D&&D<=43388||44032<=D&&D<=55203||55216<=D&&D<=55238||55243<=D&&D<=55291||63744<=D&&D<=64255||65040<=D&&D<=65049||65072<=D&&D<=65106||65108<=D&&D<=65126||65128<=D&&D<=65131||110592<=D&&D<=110593||127488<=D&&D<=127490||127504<=D&&D<=127546||127552<=D&&D<=127560||127568<=D&&D<=127569||131072<=D&&D<=194367||177984<=D&&D<=196605||196608<=D&&D<=262141?"W":32<=D&&D<=126||162<=D&&D<=163||165<=D&&D<=166||D==172||D==175||10214<=D&&D<=10221||10629<=D&&D<=10630?"Na":D==161||D==164||167<=D&&D<=168||D==170||173<=D&&D<=174||176<=D&&D<=180||182<=D&&D<=186||188<=D&&D<=191||D==198||D==208||215<=D&&D<=216||222<=D&&D<=225||D==230||232<=D&&D<=234||236<=D&&D<=237||D==240||242<=D&&D<=243||247<=D&&D<=250||D==252||D==254||D==257||D==273||D==275||D==283||294<=D&&D<=295||D==299||305<=D&&D<=307||D==312||319<=D&&D<=322||D==324||328<=D&&D<=331||D==333||338<=D&&D<=339||358<=D&&D<=359||D==363||D==462||D==464||D==466||D==468||D==470||D==472||D==474||D==476||D==593||D==609||D==708||D==711||713<=D&&D<=715||D==717||D==720||728<=D&&D<=731||D==733||D==735||768<=D&&D<=879||913<=D&&D<=929||931<=D&&D<=937||945<=D&&D<=961||963<=D&&D<=969||D==1025||1040<=D&&D<=1103||D==1105||D==8208||8211<=D&&D<=8214||8216<=D&&D<=8217||8220<=D&&D<=8221||8224<=D&&D<=8226||8228<=D&&D<=8231||D==8240||8242<=D&&D<=8243||D==8245||D==8251||D==8254||D==8308||D==8319||8321<=D&&D<=8324||D==8364||D==8451||D==8453||D==8457||D==8467||D==8470||8481<=D&&D<=8482||D==8486||D==8491||8531<=D&&D<=8532||8539<=D&&D<=8542||8544<=D&&D<=8555||8560<=D&&D<=8569||D==8585||8592<=D&&D<=8601||8632<=D&&D<=8633||D==8658||D==8660||D==8679||D==8704||8706<=D&&D<=8707||8711<=D&&D<=8712||D==8715||D==8719||D==8721||D==8725||D==8730||8733<=D&&D<=8736||D==8739||D==8741||8743<=D&&D<=8748||D==8750||8756<=D&&D<=8759||8764<=D&&D<=8765||D==8776||D==8780||D==8786||8800<=D&&D<=8801||8804<=D&&D<=8807||8810<=D&&D<=8811||8814<=D&&D<=8815||8834<=D&&D<=8835||8838<=D&&D<=8839||D==8853||D==8857||D==8869||D==8895||D==8978||9312<=D&&D<=9449||9451<=D&&D<=9547||9552<=D&&D<=9587||9600<=D&&D<=9615||9618<=D&&D<=9621||9632<=D&&D<=9633||9635<=D&&D<=9641||9650<=D&&D<=9651||9654<=D&&D<=9655||9660<=D&&D<=9661||9664<=D&&D<=9665||9670<=D&&D<=9672||D==9675||9678<=D&&D<=9681||9698<=D&&D<=9701||D==9711||9733<=D&&D<=9734||D==9737||9742<=D&&D<=9743||9748<=D&&D<=9749||D==9756||D==9758||D==9792||D==9794||9824<=D&&D<=9825||9827<=D&&D<=9829||9831<=D&&D<=9834||9836<=D&&D<=9837||D==9839||9886<=D&&D<=9887||9918<=D&&D<=9919||9924<=D&&D<=9933||9935<=D&&D<=9953||D==9955||9960<=D&&D<=9983||D==10045||D==10071||10102<=D&&D<=10111||11093<=D&&D<=11097||12872<=D&&D<=12879||57344<=D&&D<=63743||65024<=D&&D<=65039||D==65533||127232<=D&&D<=127242||127248<=D&&D<=127277||127280<=D&&D<=127337||127344<=D&&D<=127386||917760<=D&&D<=917999||983040<=D&&D<=1048573||1048576<=D&&D<=1114109?"A":"N"};d.characterLength=function(u){var F=this.eastAsianWidth(u);return F=="F"||F=="W"||F=="A"?2:1};function sD(u){return u.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]|[^\uD800-\uDFFF]/g)||[]}d.length=function(u){for(var F=sD(u),e=0,D=0;D=F-(n==2?1:0))if(C+n<=e)D+=E;else break;C+=n}return D}});var cD=h((f0,aD)=>{"use strict";aD.exports=function(){return/\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67)\uDB40\uDC7F|(?:\uD83E\uDDD1\uD83C\uDFFF\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFC-\uDFFF])|\uD83D\uDC68(?:\uD83C\uDFFB(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|[\u2695\u2696\u2708]\uFE0F|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))?|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])\uFE0F|\u200D(?:(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D[\uDC66\uDC67])|\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC)?|(?:\uD83D\uDC69(?:\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69]))|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC69(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE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\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDE36\u200D\uD83C\uDF2B|\uD83C\uDFF3\uFE0F\u200D\u26A7|\uD83D\uDC3B\u200D\u2744|(?:(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\uD83C\uDFF4\u200D\u2620|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])\u200D[\u2640\u2642]|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u3030\u303D\u3297\u3299]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]|\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|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDE35\u200D\uD83D\uDCAB|\uD83D\uDE2E\u200D\uD83D\uDCA8|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83E\uDDD1(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83D\uDC69(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF6\uD83C\uDDE6|\uD83C\uDDF4\uD83C\uDDF2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C50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270C\u270D]|\uD83D[\uDD74\uDD90])(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC08\uDC15\uDC3B\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE2E\uDE35\uDE36\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5]|\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD]|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF]|[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\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-\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0D\uDD0E\uDD10-\uDD17\uDD1D\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78\uDD7A-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCB\uDDD0\uDDE0-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6]|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26A7\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5-\uDED7\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDD77\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g}});var TD=h((_0,Nu)=>{Nu.exports={single:{topLeft:"\u250C",top:"\u2500",topRight:"\u2510",right:"\u2502",bottomRight:"\u2518",bottom:"\u2500",bottomLeft:"\u2514",left:"\u2502"},double:{topLeft:"\u2554",top:"\u2550",topRight:"\u2557",right:"\u2551",bottomRight:"\u255D",bottom:"\u2550",bottomLeft:"\u255A",left:"\u2551"},round:{topLeft:"\u256D",top:"\u2500",topRight:"\u256E",right:"\u2502",bottomRight:"\u256F",bottom:"\u2500",bottomLeft:"\u2570",left:"\u2502"},bold:{topLeft:"\u250F",top:"\u2501",topRight:"\u2513",right:"\u2503",bottomRight:"\u251B",bottom:"\u2501",bottomLeft:"\u2517",left:"\u2503"},singleDouble:{topLeft:"\u2553",top:"\u2500",topRight:"\u2556",right:"\u2551",bottomRight:"\u255C",bottom:"\u2500",bottomLeft:"\u2559",left:"\u2551"},doubleSingle:{topLeft:"\u2552",top:"\u2550",topRight:"\u2555",right:"\u2502",bottomRight:"\u255B",bottom:"\u2550",bottomLeft:"\u2558",left:"\u2502"},classic:{topLeft:"+",top:"-",topRight:"+",right:"|",bottomRight:"+",bottom:"-",bottomLeft:"+",left:"|"},arrow:{topLeft:"\u2198",top:"\u2193",topRight:"\u2199",right:"\u2190",bottomRight:"\u2196",bottom:"\u2191",bottomLeft:"\u2197",left:"\u2192"}}});var z=h((j0,H)=>{"use strict";var OD=TD();H.exports=OD;H.exports.default=OD});var _D=h(($0,SD)=>{"use strict";SD.exports=({onlyFirst:u=!1}={})=>{let F=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(F,u?void 0:"g")}});var kD=h((W0,jD)=>{"use strict";var ku=_D();jD.exports=u=>typeof u=="string"?u.replace(ku(),""):u});var WD=h((G0,X)=>{"use strict";var $D=u=>Number.isNaN(u)?!1:u>=4352&&(u<=4447||u===9001||u===9002||11904<=u&&u<=12871&&u!==12351||12880<=u&&u<=19903||19968<=u&&u<=42182||43360<=u&&u<=43388||44032<=u&&u<=55203||63744<=u&&u<=64255||65040<=u&&u<=65049||65072<=u&&u<=65131||65281<=u&&u<=65376||65504<=u&&u<=65510||110592<=u&&u<=110593||127488<=u&&u<=127569||131072<=u&&u<=262141);X.exports=$D;X.exports.default=$D});var UD=h((U0,GD)=>{"use strict";GD.exports=function(){return/\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F|\uD83D\uDC68(?:\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68\uD83C\uDFFB|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|[\u2695\u2696\u2708]\uFE0F|\uD83D[\uDC66\uDC67]|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708])\uFE0F|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C[\uDFFB-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)\uD83C\uDFFB|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB\uDFFC])|\uD83D\uDC69(?:\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB-\uDFFD])|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|(?:(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)\uFE0F|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\u200D[\u2640\u2642])|\uD83C\uDFF4\u200D\u2620)\uFE0F|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF4\uD83C\uDDF2|\uD83C\uDDF6\uD83C\uDDE6|[#\*0-9]\uFE0F\u20E3|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDE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23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5\uDEEB\uDEEC\uDEF4-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g}});var PD=h((Y0,DD)=>{"use strict";var $u=kD(),Wu=WD(),Gu=UD(),YD=u=>{if(typeof u!="string"||u.length===0||(u=$u(u),u.length===0))return 0;u=u.replace(Gu()," ");let F=0;for(let e=0;e=127&&D<=159||D>=768&&D<=879||(D>65535&&e++,F+=Wu(D)?2:1)}return F};DD.exports=YD;DD.exports.default=YD});var KD=h((P0,ZD)=>{"use strict";var Uu=PD();function p(u,F){if(!u)return u;F=F||{};let e=F.align||"center";if(e==="left")return u;let D=F.split||` +`,C=F.pad||" ",t=e!=="right"?Yu:Pu,r=!1;Array.isArray(u)||(r=!0,u=String(u).split(D));let E,n=0;return u=u.map(function(i){return i=String(i),E=Uu(i),n=Math.max(E,n),{str:i,width:E}}).map(function(i){return new Array(t(n,i.width)+1).join(C)+i.str}),r?u.join(D):u}p.left=function(F){return p(F,{align:"left"})};p.center=function(F){return p(F,{align:"center"})};p.right=function(F){return p(F,{align:"right"})};ZD.exports=p;function Yu(u,F){return Math.floor((u-F)/2)}function Pu(u,F){return u-F}});import Eu from"node:console";import{parseArgs as o0}from"node:util";var lD={bugs:"https://github.com/mc2it/card/issues",description:"Business card of MC2IT, distribution and services.",homepage:"https://mc2it.github.io/card",license:"MIT",name:"@mc2it/card",repository:"mc2it/card",type:"module",version:"5.0.0",author:{email:"dev@mc2it.com",name:"MC2IT",url:"https://www.mc2it.com"},bin:{mc2it_card:"./bin/mc2it_card.js"},contributors:[{email:"cedric@belin.io",name:"C\xE9dric Belin",url:"https://belin.io"}],devDependencies:{"@types/node":"^20.11.5","@typescript-eslint/eslint-plugin":"^6.19.1","@typescript-eslint/parser":"^6.19.1",boxen:"^7.1.1",chalk:"^5.3.0",esbuild:"^0.19.11",eslint:"^8.56.0",typedoc:"^0.25.7",typescript:"^5.3.3"},engines:{node:">=20.0.0"},exports:{types:"./lib/index.d.ts",import:"./lib/index.js"},files:["lib/","src/"],keywords:["card","cli","mc2it"],scripts:{build:"tsc --project src/tsconfig.json && esbuild --allow-overwrite --bundle --format=esm --legal-comments=none --log-level=warning --minify --outfile=bin/mc2it_card.js --platform=node src/cli.ts",clean:"node tool/clean.js",dist:"npm run clean && npm run build && node tool/dist.js && git update-index --chmod=+x bin/mc2it_card.js",doc:"typedoc --options etc/typedoc.json && node tool/doc.js",lint:"tsc --project tsconfig.json && eslint --config=etc/eslint.json src tool",postpublish:"node tool/publish.js",prepack:"npm run dist",start:"npm run build && node bin/mc2it_card.js"}};import W from"node:process";function U({onlyFirst:u=!1}={}){let F=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(F,u?void 0:"g")}var cu=U();function Y(u){if(typeof u!="string")throw new TypeError(`Expected a \`string\`, got \`${typeof u}\``);return u.replace(cu,"")}var xD=T(BD(),1),AD=T(cD(),1);function x(u,F={}){if(typeof u!="string"||u.length===0||(F={ambiguousIsNarrow:!0,...F},u=Y(u),u.length===0))return 0;u=u.replace((0,AD.default)()," ");let e=F.ambiguousIsNarrow?1:2,D=0;for(let C of u){let t=C.codePointAt(0);if(t<=31||t>=127&&t<=159||t>=768&&t<=879)continue;switch(xD.default.eastAsianWidth(C)){case"F":case"W":D+=2;break;case"A":D+=e;break;default:D+=1}}return D}var fD=(u=0)=>F=>`\x1B[${F+u}m`,gD=(u=0)=>F=>`\x1B[${38+u};5;${F}m`,hD=(u=0)=>(F,e,D)=>`\x1B[${38+u};2;${F};${e};${D}m`,l={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}},m0=Object.keys(l.modifier),xu=Object.keys(l.color),Au=Object.keys(l.bgColor),d0=[...xu,...Au];function fu(){let u=new Map;for(let[F,e]of Object.entries(l)){for(let[D,C]of Object.entries(e))l[D]={open:`\x1B[${C[0]}m`,close:`\x1B[${C[1]}m`},e[D]=l[D],u.set(C[0],C[1]);Object.defineProperty(l,F,{value:e,enumerable:!1})}return Object.defineProperty(l,"codes",{value:u,enumerable:!1}),l.color.close="\x1B[39m",l.bgColor.close="\x1B[49m",l.color.ansi=fD(),l.color.ansi256=gD(),l.color.ansi16m=hD(),l.bgColor.ansi=fD(10),l.bgColor.ansi256=gD(10),l.bgColor.ansi16m=hD(10),Object.defineProperties(l,{rgbToAnsi256:{value(F,e,D){return F===e&&e===D?F<8?16:F>248?231:Math.round((F-8)/247*24)+232:16+36*Math.round(F/255*5)+6*Math.round(e/255*5)+Math.round(D/255*5)},enumerable:!1},hexToRgb:{value(F){let e=/[a-f\d]{6}|[a-f\d]{3}/i.exec(F.toString(16));if(!e)return[0,0,0];let[D]=e;D.length===3&&(D=[...D].map(t=>t+t).join(""));let C=Number.parseInt(D,16);return[C>>16&255,C>>8&255,C&255]},enumerable:!1},hexToAnsi256:{value:F=>l.rgbToAnsi256(...l.hexToRgb(F)),enumerable:!1},ansi256ToAnsi:{value(F){if(F<8)return 30+F;if(F<16)return 90+(F-8);let e,D,C;if(F>=232)e=((F-232)*10+8)/255,D=e,C=e;else{F-=16;let E=F%36;e=Math.floor(F/36)/5,D=Math.floor(E/6)/5,C=E%6/5}let t=Math.max(e,D,C)*2;if(t===0)return 30;let r=30+(Math.round(C)<<2|Math.round(D)<<1|Math.round(e));return t===2&&(r+=60),r},enumerable:!1},rgbToAnsi:{value:(F,e,D)=>l.ansi256ToAnsi(l.rgbToAnsi256(F,e,D)),enumerable:!1},hexToAnsi:{value:F=>l.ansi256ToAnsi(l.hexToAnsi256(F)),enumerable:!1}}),l}var gu=fu(),g=gu;import Z from"node:process";import hu from"node:os";import mD from"node:tty";function f(u,F=globalThis.Deno?globalThis.Deno.args:Z.argv){let e=u.startsWith("-")?"":u.length===1?"-":"--",D=F.indexOf(e+u),C=F.indexOf("--");return D!==-1&&(C===-1||D=2,has16m:u>=3}}function bu(u,{streamIsTTY:F,sniffFlags:e=!0}={}){let D=mu();D!==void 0&&(S=D);let C=e?S:D;if(C===0)return 0;if(e){if(f("color=16m")||f("color=full")||f("color=truecolor"))return 3;if(f("color=256"))return 2}if("TF_BUILD"in B&&"AGENT_NAME"in B)return 1;if(u&&!F&&C===void 0)return 0;let t=C||0;if(B.TERM==="dumb")return t;if(Z.platform==="win32"){let r=hu.release().split(".");return Number(r[0])>=10&&Number(r[2])>=10586?Number(r[2])>=14931?3:2:1}if("CI"in B)return"GITHUB_ACTIONS"in B||"GITEA_ACTIONS"in B?3:["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","BUILDKITE","DRONE"].some(r=>r in B)||B.CI_NAME==="codeship"?1:t;if("TEAMCITY_VERSION"in B)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(B.TEAMCITY_VERSION)?1:0;if(B.COLORTERM==="truecolor"||B.TERM==="xterm-kitty")return 3;if("TERM_PROGRAM"in B){let r=Number.parseInt((B.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(B.TERM_PROGRAM){case"iTerm.app":return r>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(B.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(B.TERM)||"COLORTERM"in B?1:t}function dD(u,F={}){let e=bu(u,{streamIsTTY:u&&u.isTTY,...F});return du(e)}var pu={stdout:dD({isTTY:mD.isatty(1)}),stderr:dD({isTTY:mD.isatty(2)})},bD=pu;function pD(u,F,e){let D=u.indexOf(F);if(D===-1)return u;let C=F.length,t=0,r="";do r+=u.slice(t,D)+F+e,t=D+C,D=u.indexOf(F,t);while(D!==-1);return r+=u.slice(t),r}function yD(u,F,e,D){let C=0,t="";do{let r=u[D-1]==="\r";t+=u.slice(C,r?D-1:D)+F+(r?`\r +`:` +`)+e,C=D+1,D=u.indexOf(` +`,C)}while(D!==-1);return t+=u.slice(C),t}var{stdout:RD,stderr:wD}=bD,K=Symbol("GENERATOR"),y=Symbol("STYLER"),O=Symbol("IS_EMPTY"),vD=["ansi","ansi","ansi256","ansi16m"],R=Object.create(null),yu=(u,F={})=>{if(F.level&&!(Number.isInteger(F.level)&&F.level>=0&&F.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");let e=RD?RD.level:0;u.level=F.level===void 0?e:F.level};var Ru=u=>{let F=(...e)=>e.join(" ");return yu(F,u),Object.setPrototypeOf(F,N.prototype),F};function N(u){return Ru(u)}Object.setPrototypeOf(N.prototype,Function.prototype);for(let[u,F]of Object.entries(g))R[u]={get(){let e=_(this,q(F.open,F.close,this[y]),this[O]);return Object.defineProperty(this,u,{value:e}),e}};R.visible={get(){let u=_(this,this[y],!0);return Object.defineProperty(this,"visible",{value:u}),u}};var V=(u,F,e,...D)=>u==="rgb"?F==="ansi16m"?g[e].ansi16m(...D):F==="ansi256"?g[e].ansi256(g.rgbToAnsi256(...D)):g[e].ansi(g.rgbToAnsi(...D)):u==="hex"?V("rgb",F,e,...g.hexToRgb(...D)):g[e][u](...D),wu=["rgb","hex","ansi256"];for(let u of wu){R[u]={get(){let{level:e}=this;return function(...D){let C=q(V(u,vD[e],"color",...D),g.color.close,this[y]);return _(this,C,this[O])}}};let F="bg"+u[0].toUpperCase()+u.slice(1);R[F]={get(){let{level:e}=this;return function(...D){let C=q(V(u,vD[e],"bgColor",...D),g.bgColor.close,this[y]);return _(this,C,this[O])}}}}var vu=Object.defineProperties(()=>{},{...R,level:{enumerable:!0,get(){return this[K].level},set(u){this[K].level=u}}}),q=(u,F,e)=>{let D,C;return e===void 0?(D=u,C=F):(D=e.openAll+u,C=F+e.closeAll),{open:u,close:F,openAll:D,closeAll:C,parent:e}},_=(u,F,e)=>{let D=(...C)=>Tu(D,C.length===1?""+C[0]:C.join(" "));return Object.setPrototypeOf(D,vu),D[K]=u,D[y]=F,D[O]=e,D},Tu=(u,F)=>{if(u.level<=0||!F)return u[O]?"":F;let e=u[y];if(e===void 0)return F;let{openAll:D,closeAll:C}=e;if(F.includes("\x1B"))for(;e!==void 0;)F=pD(F,e.close,e.open),e=e.parent;let t=F.indexOf(` +`);return t!==-1&&(F=yD(F,C,D,t)),D+F+C};Object.defineProperties(N.prototype,R);var Ou=N(),L0=N({level:wD?wD.level:0});var a=Ou;function j(u){let F=0;for(let e of u.split(` +`))F=Math.max(F,x(e));return F}var Cu=T(z(),1);var Lu=/[\p{Lu}]/u,Mu=/[\p{Ll}]/u,ND=/^[\p{Lu}](?![\p{Lu}])/gu,ID=/([\p{Alpha}\p{N}_]|$)/u,J=/[_.\- ]+/,Iu=new RegExp("^"+J.source),LD=new RegExp(J.source+ID.source,"gu"),MD=new RegExp("\\d+"+ID.source,"gu"),Su=(u,F,e,D)=>{let C=!1,t=!1,r=!1,E=!1;for(let n=0;n2?u[n-3]==="-":!0,C&&Lu.test(i)?(u=u.slice(0,n)+"-"+u.slice(n),C=!1,r=t,t=!0,n++):t&&r&&Mu.test(i)&&(!E||D)?(u=u.slice(0,n-1)+"-"+u.slice(n-1),r=t,t=!1,C=!0):(C=F(i)===i&&e(i)!==i,r=t,t=e(i)===i&&F(i)!==i)}return u},_u=(u,F)=>(ND.lastIndex=0,u.replace(ND,e=>F(e))),ju=(u,F)=>(LD.lastIndex=0,MD.lastIndex=0,u.replace(LD,(e,D)=>F(D)).replace(MD,e=>F(e)));function Q(u,F){if(!(typeof u=="string"||Array.isArray(u)))throw new TypeError("Expected the input to be `string | string[]`");if(F={pascalCase:!1,preserveConsecutiveUppercase:!1,...F},Array.isArray(u)?u=u.map(t=>t.trim()).filter(t=>t.length).join("-"):u=u.trim(),u.length===0)return"";let e=F.locale===!1?t=>t.toLowerCase():t=>t.toLocaleLowerCase(F.locale),D=F.locale===!1?t=>t.toUpperCase():t=>t.toLocaleUpperCase(F.locale);return u.length===1?J.test(u)?"":F.pascalCase?D(u):e(u):(u!==e(u)&&(u=Su(u,e,D,F.preserveConsecutiveUppercase)),u=u.replace(Iu,""),u=F.preserveConsecutiveUppercase?_u(u,e):e(u),F.pascalCase&&(u=D(u.charAt(0))+u.slice(1)),ju(u,D))}var rD=T(KD(),1);function uD({onlyFirst:u=!1}={}){let F=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(F,u?void 0:"g")}var Zu=uD();function FD(u){if(typeof u!="string")throw new TypeError(`Expected a \`string\`, got \`${typeof u}\``);return u.replace(Zu,"")}var VD=(u=0)=>F=>`\x1B[${F+u}m`,qD=(u=0)=>F=>`\x1B[${38+u};5;${F}m`,HD=(u=0)=>(F,e,D)=>`\x1B[${38+u};2;${F};${e};${D}m`,s={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}},q0=Object.keys(s.modifier),Ku=Object.keys(s.color),Vu=Object.keys(s.bgColor),H0=[...Ku,...Vu];function qu(){let u=new Map;for(let[F,e]of Object.entries(s)){for(let[D,C]of Object.entries(e))s[D]={open:`\x1B[${C[0]}m`,close:`\x1B[${C[1]}m`},e[D]=s[D],u.set(C[0],C[1]);Object.defineProperty(s,F,{value:e,enumerable:!1})}return Object.defineProperty(s,"codes",{value:u,enumerable:!1}),s.color.close="\x1B[39m",s.bgColor.close="\x1B[49m",s.color.ansi=VD(),s.color.ansi256=qD(),s.color.ansi16m=HD(),s.bgColor.ansi=VD(10),s.bgColor.ansi256=qD(10),s.bgColor.ansi16m=HD(10),Object.defineProperties(s,{rgbToAnsi256:{value:(F,e,D)=>F===e&&e===D?F<8?16:F>248?231:Math.round((F-8)/247*24)+232:16+36*Math.round(F/255*5)+6*Math.round(e/255*5)+Math.round(D/255*5),enumerable:!1},hexToRgb:{value:F=>{let e=/[a-f\d]{6}|[a-f\d]{3}/i.exec(F.toString(16));if(!e)return[0,0,0];let[D]=e;D.length===3&&(D=[...D].map(t=>t+t).join(""));let C=Number.parseInt(D,16);return[C>>16&255,C>>8&255,C&255]},enumerable:!1},hexToAnsi256:{value:F=>s.rgbToAnsi256(...s.hexToRgb(F)),enumerable:!1},ansi256ToAnsi:{value:F=>{if(F<8)return 30+F;if(F<16)return 90+(F-8);let e,D,C;if(F>=232)e=((F-232)*10+8)/255,D=e,C=e;else{F-=16;let E=F%36;e=Math.floor(F/36)/5,D=Math.floor(E/6)/5,C=E%6/5}let t=Math.max(e,D,C)*2;if(t===0)return 30;let r=30+(Math.round(C)<<2|Math.round(D)<<1|Math.round(e));return t===2&&(r+=60),r},enumerable:!1},rgbToAnsi:{value:(F,e,D)=>s.ansi256ToAnsi(s.rgbToAnsi256(F,e,D)),enumerable:!1},hexToAnsi:{value:F=>s.ansi256ToAnsi(s.hexToAnsi256(F)),enumerable:!1}}),s}var Hu=qu(),zD=Hu;var k=new Set(["\x1B","\x9B"]),zu=39,CD="\x07",XD="[",Ju="]",Du="m",tD=`${Ju}8;;`,JD=u=>`${k.values().next().value}${XD}${u}${Du}`,QD=u=>`${k.values().next().value}${tD}${u}${CD}`,Qu=u=>u.split(" ").map(F=>x(F)),eD=(u,F,e)=>{let D=[...F],C=!1,t=!1,r=x(FD(u[u.length-1]));for(let[E,n]of D.entries()){let i=x(n);if(r+i<=e?u[u.length-1]+=n:(u.push(n),r=0),k.has(n)&&(C=!0,t=D.slice(E+1).join("").startsWith(tD)),C){t?n===CD&&(C=!1,t=!1):n===Du&&(C=!1);continue}r+=i,r===e&&E0&&u.length>1&&(u[u.length-2]+=u.pop())},Xu=u=>{let F=u.split(" "),e=F.length;for(;e>0&&!(x(F[e-1])>0);)e--;return e===F.length?u:F.slice(0,e).join(" ")+F.slice(e).join("")},D0=(u,F,e={})=>{if(e.trim!==!1&&u.trim()==="")return"";let D="",C,t,r=Qu(u),E=[""];for(let[i,o]of u.split(" ").entries()){e.trim!==!1&&(E[E.length-1]=E[E.length-1].trimStart());let c=x(E[E.length-1]);if(i!==0&&(c>=F&&(e.wordWrap===!1||e.trim===!1)&&(E.push(""),c=0),(c>0||e.trim===!1)&&(E[E.length-1]+=" ",c++)),e.hard&&r[i]>F){let m=F-c,w=1+Math.floor((r[i]-m-1)/F);Math.floor((r[i]-1)/F)F&&c>0&&r[i]>0){if(e.wordWrap===!1&&cF&&e.wordWrap===!1){eD(E,o,F);continue}E[E.length-1]+=o}e.trim!==!1&&(E=E.map(i=>Xu(i)));let n=[...E.join(` +`)];for(let[i,o]of n.entries()){if(D+=o,k.has(o)){let{groups:m}=new RegExp(`(?:\\${XD}(?\\d+)m|\\${tD}(?.*)${CD})`).exec(n.slice(i).join(""))||{groups:{}};if(m.code!==void 0){let w=Number.parseFloat(m.code);C=w===zu?void 0:w}else m.uri!==void 0&&(t=m.uri.length===0?void 0:m.uri)}let c=zD.codes.get(Number(C));n[i+1]===` +`?(t&&(D+=QD("")),C&&c&&(D+=JD(c))):o===` +`&&(C&&c&&(D+=JD(C)),t&&(D+=QD(t)))}return D};function $(u,F,e){return String(u).normalize().replace(/\r\n/g,` +`).split(` +`).map(D=>D0(D,F,e)).join(` +`)}var i0=T(z(),1),b=` +`,A=" ",L="none",tu=()=>{let{env:u,stdout:F,stderr:e}=W;return F?.columns?F.columns:e?.columns?e.columns:u.COLUMNS?Number.parseInt(u.COLUMNS,10):80},uu=u=>typeof u=="number"?{top:u,right:u*3,bottom:u,left:u*3}:{top:0,right:0,bottom:0,left:0,...u},M=u=>u===L?0:2,u0=u=>{let F=["topLeft","topRight","bottomRight","bottomLeft","left","right","top","bottom"],e;if(u===L){u={};for(let D of F)u[D]=""}if(typeof u=="string"){if(e=Cu.default[u],!e)throw new TypeError(`Invalid border style: ${u}`)}else{typeof u?.vertical=="string"&&(u.left=u.vertical,u.right=u.vertical),typeof u?.horizontal=="string"&&(u.top=u.horizontal,u.bottom=u.horizontal);for(let D of F)if(u[D]===null||typeof u[D]!="string")throw new TypeError(`Invalid border style: ${D}`);e=u}return e},F0=(u,F,e)=>{let D="",C=x(u);switch(e){case"left":{D=u+F.slice(C);break}case"right":{D=F.slice(C)+u;break}default:{F=F.slice(C),F.length%2===1?(F=F.slice(Math.floor(F.length/2)),D=F.slice(1)+u+F):(F=F.slice(F.length/2),D=F+u+F);break}}return D},e0=(u,{padding:F,width:e,textAlignment:D,height:C})=>{u=(0,rD.default)(u,{align:D});let t=u.split(b),r=j(u),E=e-F.left-F.right;if(r>E){let o=[];for(let c of t){let m=$(c,E,{hard:!0}),G=(0,rD.default)(m,{align:D}).split(` +`),iD=Math.max(...G.map(v=>x(v)));for(let v of G){let I;switch(D){case"center":{I=A.repeat((E-iD)/2)+v;break}case"right":{I=A.repeat(E-iD)+v;break}default:{I=v;break}}o.push(I)}}t=o}D==="center"&&rA.repeat((E-r)/2)+o):D==="right"&&rA.repeat(E-r)+o));let n=A.repeat(F.left),i=A.repeat(F.right);return t=t.map(o=>n+o+i),t=t.map(o=>{if(e-x(o)>0)switch(D){case"center":return o+A.repeat(e-x(o));case"right":return o+A.repeat(e-x(o));default:return o+A.repeat(e-x(o))}return o}),F.top>0&&(t=[...Array.from({length:F.top}).fill(A.repeat(e)),...t]),F.bottom>0&&(t=[...t,...Array.from({length:F.bottom}).fill(A.repeat(e))]),C&&t.length>C?t=t.slice(0,C):C&&t.length{let D=o=>{let c=e.borderColor?E0(e.borderColor)(o):o;return e.dimBorder?a.dim(c):c},C=o=>e.backgroundColor?n0(e.backgroundColor)(o):o,t=u0(e.borderStyle),r=tu(),E=A.repeat(e.margin.left);if(e.float==="center"){let o=Math.max((r-F-M(e.borderStyle))/2,0);E=A.repeat(o)}else if(e.float==="right"){let o=Math.max(r-F-e.margin.right-M(e.borderStyle),0);E=A.repeat(o)}let n="";e.margin.top&&(n+=b.repeat(e.margin.top)),(e.borderStyle!==L||e.title)&&(n+=D(E+t.topLeft+(e.title?F0(e.title,t.top.repeat(F),e.titleAlignment):t.top.repeat(F))+t.topRight)+b);let i=u.split(b);return n+=i.map(o=>E+D(t.left)+C(o)+D(t.right)).join(b),e.borderStyle!==L&&(n+=b+D(E+t.bottomLeft+t.bottom.repeat(F)+t.bottomRight)),e.margin.bottom&&(n+=b.repeat(e.margin.bottom)),n},t0=u=>{if(u.fullscreen&&W?.stdout){let F=[W.stdout.columns,W.stdout.rows];typeof u.fullscreen=="function"&&(F=u.fullscreen(...F)),u.width||(u.width=F[0]),u.height||(u.height=F[1])}return u.width&&(u.width=Math.max(1,u.width-M(u.borderStyle))),u.height&&(u.height=Math.max(1,u.height-M(u.borderStyle))),u},Fu=(u,F)=>F===L?u:` ${u} `,r0=(u,F)=>{F=t0(F);let e=F.width!==void 0,D=tu(),C=M(F.borderStyle),t=D-F.margin.left-F.margin.right-C,r=j($(u,D-C,{hard:!0,trim:!1}))+F.padding.left+F.padding.right;if(F.title&&e?(F.title=F.title.slice(0,Math.max(0,F.width-2)),F.title&&(F.title=Fu(F.title,F.borderStyle))):F.title&&(F.title=F.title.slice(0,Math.max(0,t-2)),F.title&&(F.title=Fu(F.title,F.borderStyle),x(F.title)>r&&(F.width=x(F.title)))),F.width=F.width?F.width:r,!e){if(F.margin.left&&F.margin.right&&F.width>t){let n=(D-F.width-C)/(F.margin.left+F.margin.right);F.margin.left=Math.max(0,Math.floor(F.margin.left*n)),F.margin.right=Math.max(0,Math.floor(F.margin.right*n))}F.width=Math.min(F.width,D-C-F.margin.left-F.margin.right)}return F.width-(F.padding.left+F.padding.right)<=0&&(F.padding.left=0,F.padding.right=0),F.height&&F.height-(F.padding.top+F.padding.bottom)<=0&&(F.padding.top=0,F.padding.bottom=0),F},ED=u=>u.match(/^#(?:[0-f]{3}){1,2}$/i),eu=u=>typeof u=="string"&&(a[u]??ED(u)),E0=u=>ED(u)?a.hex(u):a[u],n0=u=>ED(u)?a.bgHex(u):a[Q(["bg",u])];function nD(u,F){if(F={padding:0,borderStyle:"single",dimBorder:!1,textAlignment:"left",float:"left",titleAlignment:"left",...F},F.align&&(F.textAlignment=F.align),F.borderColor&&!eu(F.borderColor))throw new Error(`${F.borderColor} is not a valid borderColor`);if(F.backgroundColor&&!eu(F.backgroundColor))throw new Error(`${F.backgroundColor} is not a valid backgroundColor`);return F.padding=uu(F.padding),F.margin=uu(F.margin),F=r0(u,F),u=e0(u,F),C0(u,F.width,F)}function ru(u=0){let F=[`${a.white.bold(" MC2IT")} ${a.white("- Distribution & Services")}`,"",`${a.white.bold(" GitHub:")} ${a.gray("https://github.com/")}${a.cyan("mc2it")}`,"",`${a.white.bold(" Card:")} ${a.yellow("npx")} ${a.white("@mc2it/card")}`,`${a.white.bold(" Email:")} ${a.white("dev@mc2it.com")}`,`${a.white.bold("Website:")} ${a.white("https://www.mc2it.com")}`];return nD(F.join(` +`),{borderColor:"green",borderStyle:"round",margin:u,padding:1})}var l0=` +Print the business card of MC2IT, distribution and services. -`));let n=e.commands,s=[],c=0;for(;c0){let a=X.fold(s,function(h,b){let d=0,w=h.names;for(;db&&(b=k.length)}return b},0);this.root!=null&&(t+=p.string(" Usage: "+this.root+` -`)),t+=p.string(` Subcommands: -`);let m=function(h,b){b==null&&(b="(doc missing)"),t+=p.string(o.indent(A.lpad(h," ",a)+" : "+A.trim(o.indent(b,a+3)),6)+` -`)},_=0;for(;_1){let d=1,w=h.names.length;for(;d0){let a=function(d){let w=d.names.join(", ");if(d.aliases.length>0){let k=d.aliases,N=new Array(k.length),j=0,ue=k.length;for(;jw&&(w=k.length),w},0),_=function(d,w){w==null&&(w=""),t+=p.string(o.indent(A.lpad(d," ",m)+" : "+A.trim(o.indent(w,m+3)),6)+` -`)};t=(t+=` -`)+p.string(` Flags: -`);let h=0,b=e.flags;for(;h>1&&e.compact()}}}Be.__name__=!0;class L{constructor(e){L._hx_skip_constructor||this._hx_constructor(e)}_hx_constructor(e){this.disposeHandlers=[],this.f=e}dispose(){let e=this.disposeHandlers;if(e!=null){this.disposeHandlers=null;let t=this.f;this.f=L.noop,t();let r=0;for(;r0){this.used=0;let r=this.ondrain;x.depth<500?(x.depth++,r(),x.depth--):x.defer(r)}}invoke(e){let t=this;if(x.depth<500){if(x.depth++,t.disposeHandlers!=null)if(t.busy){if(t.destructive!=!0){let r=t,n=e,s=function(){r.invoke(n)};t.queue.push(s)}}else{t.busy=!0,t.destructive&&t.dispose();let r=t.cells.length,n=0;for(;n0&&t.queue.shift()())}x.depth--}else x.defer(function(){if(t.disposeHandlers!=null)if(t.busy){if(t.destructive!=!0){let r=t,n=e,s=function(){r.invoke(n)};t.queue.push(s)}}else{t.busy=!0,t.destructive&&t.dispose();let r=t.cells.length,n=0;for(;n0&&t.queue.shift()())}})}compact(){if(!this.busy)if(this.used==0){this.resize(0);let e=this.ondrain;x.depth<500?(x.depth++,e(),x.depth--):x.defer(e)}else{let e=0,t=0,r=this.cells.length;for(;t>10)+55232)+String.fromCharCode((i&1023)+56320)}),String.__name__=!0,Array.__name__=!0,typeof performance<"u"&&typeof performance.now=="function"&&(g.now=performance.now.bind(performance)),R.__toStr={}.toString,f.formatMode=f.determineConsoleFormatMode(),f.logPrefix="> ",f.unicodeCompatibilityMode=Q.systemName()=="Windows"?1:0,f.unicodeCompatibilityEnabled=!1,f.formatTagPattern=new U("(\\\\)?<(/)?([^><{}\\s]*|{[^}<>]*})>","g"),P.newLine=Q.systemName()=="Windows"?`\r -`:` -`,x.depth=0,L._hx_skip_constructor=!1,M._hx_skip_constructor=!1,E.NEVER_INST=new M,Y.NOISE=new V(new z(v.Success(null))),P.main()})(global); +Options: + -h, --help Display this help. + -v, --version Output the version number. +`;try{let{values:u}=o0({options:{help:{short:"h",type:"boolean"},version:{short:"v",type:"boolean"}}});Eu.log(u.help?l0.trim():u.version?lD.version:ru(1))}catch(u){Eu.error(u instanceof Error?u.message:u),process.exitCode=1} diff --git a/package.json b/package.json index e3d0d3f..a47ac32 100644 --- a/package.json +++ b/package.json @@ -50,13 +50,13 @@ "mc2it" ], "scripts": { - "build": "tsc --project src/tsconfig.json", + "build": "tsc --project src/tsconfig.json && esbuild --allow-overwrite --bundle --format=esm --legal-comments=none --log-level=warning --minify --outfile=bin/mc2it_card.js --platform=node src/cli.ts", "clean": "node tool/clean.js", - "dist": "npm run clean && npm run build", + "dist": "npm run clean && npm run build && node tool/dist.js && git update-index --chmod=+x bin/mc2it_card.js", "doc": "typedoc --options etc/typedoc.json && node tool/doc.js", "lint": "tsc --project tsconfig.json && eslint --config=etc/eslint.json src tool", "postpublish": "node tool/publish.js", "prepack": "npm run dist", - "start": "node bin/mc2it_card.js" + "start": "npm run build && node bin/mc2it_card.js" } } diff --git a/src/card.ts b/src/card.ts new file mode 100644 index 0000000..4b98e77 --- /dev/null +++ b/src/card.ts @@ -0,0 +1,26 @@ +import boxen from "boxen"; +import chalk from "chalk"; + +/** + * Returns the card content. + * @param margin The margin size. + * @returns The card content. + */ +export function getCard(margin = 0): string { + const buffer = [ + `${chalk.white.bold(" MC2IT")} ${chalk.white("- Distribution & Services")}`, + "", + `${chalk.white.bold(" GitHub:")} ${chalk.gray("https://github.com/")}${chalk.cyan("mc2it")}`, + "", + `${chalk.white.bold(" Card:")} ${chalk.yellow("npx")} ${chalk.white("@mc2it/card")}`, + `${chalk.white.bold(" Email:")} ${chalk.white("dev@mc2it.com")}`, + `${chalk.white.bold("Website:")} ${chalk.white("https://www.mc2it.com")}` + ]; + + return boxen(buffer.join("\n"), { + borderColor: "green", + borderStyle: "round", + margin, + padding: 1 + }); +} diff --git a/src/cli.ts b/src/cli.ts new file mode 100644 index 0000000..802b689 --- /dev/null +++ b/src/cli.ts @@ -0,0 +1,30 @@ +import console from "node:console"; +import {parseArgs} from "node:util"; +import pkg from "../package.json" with {type: "json"}; +import {getCard} from "./card.js"; + +// The usage information. +const usage = ` +Print the business card of MC2IT, distribution and services. + +Usage: + npx @mc2it/card + +Options: + -h, --help Display this help. + -v, --version Output the version number. +`; + +// Start the application. +try { + const {values} = parseArgs({options: { + help: {short: "h", type: "boolean"}, + version: {short: "v", type: "boolean"} + }}); + + console.log(values.help ? usage.trim() : (values.version ? pkg.version : getCard(1))); +} +catch (error) { + console.error(error instanceof Error ? error.message : error); + process.exitCode = 1; +} diff --git a/src/index.ts b/src/index.ts new file mode 100644 index 0000000..be6944f --- /dev/null +++ b/src/index.ts @@ -0,0 +1 @@ +export * from "./card.js"; diff --git a/src/mc2it_card/Program.hx b/src/mc2it_card/Program.hx deleted file mode 100644 index 6dbef89..0000000 --- a/src/mc2it_card/Program.hx +++ /dev/null @@ -1,56 +0,0 @@ -package mc2it_card; - -import tink.Cli; -using StringTools; -using tink.CoreApi; - -/** - Print the business card of MC2IT, distribution and services. - - > npx @mc2it/card [flags] -**/ -@:noDoc final class Program { - - /** The string corresponding to a line break. **/ - public static final newLine = Sys.systemName() == "Windows" ? "\r\n" : "\n"; - - /** Display this help. **/ - public var help = false; - - /** Output the version number. **/ - public var version = false; - - /** Creates a new program. **/ - public function new() {} - - /** Application entry point. **/ - public static function main() - Cli.process(Sys.args(), new Program()).handle(Cli.exit); - - // Runs this command. - @:defaultCommand - public function run() { - if (help || version) { - Sys.println(version ? Platform.packageVersion : Cli.getDoc(this)); - return Promise.NOISE; - } - - final builder = new CardBuilder() - .header() - .line() - .center("MC2IT - Distribution & Services") - .line() - .label("GitHub", "https://github.com/mc2it") - .line() - .label("Card", "npx @mc2it/card") - .label("Email", "dev@mc2it.com") - .label("Website", "https://www.mc2it.com") - .line() - .footer(); - - Console.formatMode = AsciiTerminal; - Console.logPrefix = ""; - Console.log('$newLine$builder'); - return Promise.NOISE; - } -} diff --git a/tool/dist.js b/tool/dist.js index ca686df..c6b0d47 100644 --- a/tool/dist.js +++ b/tool/dist.js @@ -3,4 +3,4 @@ import {shebang} from "./tools.js"; /** * Packages the project. */ -shebang("bin/belin_card.js"); +shebang("bin/mc2it_card.js");