create-qwik 1.2.10 → 1.2.12
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/index.cjs
CHANGED
|
@@ -1,64 +1,61 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
|
-
* create-qwik 1.2.
|
|
3
|
+
* create-qwik 1.2.12
|
|
4
4
|
* Copyright Builder.io, Inc. All Rights Reserved.
|
|
5
5
|
* Use of this source code is governed by an MIT-style license that can be
|
|
6
6
|
* found in the LICENSE file at https://github.com/BuilderIO/qwik/blob/main/LICENSE
|
|
7
7
|
*/
|
|
8
|
-
"use strict";var Uo=Object.create;var Ye=Object.defineProperty;var Vo=Object.getOwnPropertyDescriptor;var Yo=Object.getOwnPropertyNames;var Go=Object.getPrototypeOf,Jo=Object.prototype.hasOwnProperty;var pt=(n,t)=>()=>(t||n((t={exports:{}}).exports,t),t.exports),Ko=(n,t)=>{for(var e in t)Ye(n,e,{get:t[e],enumerable:!0})},ni=(n,t,e,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Yo(t))!Jo.call(n,r)&&r!==e&&Ye(n,r,{get:()=>t[r],enumerable:!(s=Vo(t,r))||s.enumerable});return n};var ut=(n,t,e)=>(e=n!=null?Uo(Go(n)):{},ni(t||!n||!n.__esModule?Ye(e,"default",{value:n,enumerable:!0}):e,n)),Qo=n=>ni(Ye({},"__esModule",{value:!0}),n);var qn=pt((Qa,si)=>{"use strict";var Ln="\x1B",tt=`${Ln}[`,Zo="\x07",zn={to(n,t){return t?`${tt}${t+1};${n+1}H`:`${tt}${n+1}G`},move(n,t){let e="";return n<0?e+=`${tt}${-n}D`:n>0&&(e+=`${tt}${n}C`),t<0?e+=`${tt}${-t}A`:t>0&&(e+=`${tt}${t}B`),e},up:(n=1)=>`${tt}${n}A`,down:(n=1)=>`${tt}${n}B`,forward:(n=1)=>`${tt}${n}C`,backward:(n=1)=>`${tt}${n}D`,nextLine:(n=1)=>`${tt}E`.repeat(n),prevLine:(n=1)=>`${tt}F`.repeat(n),left:`${tt}G`,hide:`${tt}?25l`,show:`${tt}?25h`,save:`${Ln}7`,restore:`${Ln}8`},Xo={up:(n=1)=>`${tt}S`.repeat(n),down:(n=1)=>`${tt}T`.repeat(n)},tu={screen:`${tt}2J`,up:(n=1)=>`${tt}1J`.repeat(n),down:(n=1)=>`${tt}J`.repeat(n),line:`${tt}2K`,lineEnd:`${tt}K`,lineStart:`${tt}1K`,lines(n){let t="";for(let e=0;e<n;e++)t+=this.line+(e<n-1?zn.up():"");return n&&(t+=zn.left),t}};si.exports={cursor:zn,scroll:Xo,erase:tu,beep:Zo}});var Un=pt((Za,Hn)=>{var eu=require("tty"),nu=!("NO_COLOR"in process.env||process.argv.includes("--no-color"))&&("FORCE_COLOR"in process.env||process.argv.includes("--color")||process.platform==="win32"||eu.isatty(1)&&process.env.TERM!=="dumb"||"CI"in process.env),Q=(n,t,e=n)=>s=>{let r=""+s,o=r.indexOf(t,n.length);return~o?n+ii(r,t,e,o)+t:n+r+t},ii=(n,t,e,s)=>{let r=n.substring(0,s)+e,o=n.substring(s+t.length),i=o.indexOf(t);return~i?r+ii(o,t,e,i):r+o},ri=(n=nu)=>({isColorSupported:n,reset:n?t=>`\x1B[0m${t}\x1B[0m`:String,bold:n?Q("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"):String,dim:n?Q("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"):String,italic:n?Q("\x1B[3m","\x1B[23m"):String,underline:n?Q("\x1B[4m","\x1B[24m"):String,inverse:n?Q("\x1B[7m","\x1B[27m"):String,hidden:n?Q("\x1B[8m","\x1B[28m"):String,strikethrough:n?Q("\x1B[9m","\x1B[29m"):String,black:n?Q("\x1B[30m","\x1B[39m"):String,red:n?Q("\x1B[31m","\x1B[39m"):String,green:n?Q("\x1B[32m","\x1B[39m"):String,yellow:n?Q("\x1B[33m","\x1B[39m"):String,blue:n?Q("\x1B[34m","\x1B[39m"):String,magenta:n?Q("\x1B[35m","\x1B[39m"):String,cyan:n?Q("\x1B[36m","\x1B[39m"):String,white:n?Q("\x1B[37m","\x1B[39m"):String,gray:n?Q("\x1B[90m","\x1B[39m"):String,bgBlack:n?Q("\x1B[40m","\x1B[49m"):String,bgRed:n?Q("\x1B[41m","\x1B[49m"):String,bgGreen:n?Q("\x1B[42m","\x1B[49m"):String,bgYellow:n?Q("\x1B[43m","\x1B[49m"):String,bgBlue:n?Q("\x1B[44m","\x1B[49m"):String,bgMagenta:n?Q("\x1B[45m","\x1B[49m"):String,bgCyan:n?Q("\x1B[46m","\x1B[49m"):String,bgWhite:n?Q("\x1B[47m","\x1B[49m"):String});Hn.exports=ri();Hn.exports.createColors=ri});var Mi=pt((_c,Pi)=>{Pi.exports=Ii;Ii.sync=Ou;var ji=require("fs");function vu(n,t){var e=t.pathExt!==void 0?t.pathExt:process.env.PATHEXT;if(!e||(e=e.split(";"),e.indexOf("")!==-1))return!0;for(var s=0;s<e.length;s++){var r=e[s].toLowerCase();if(r&&n.substr(-r.length).toLowerCase()===r)return!0}return!1}function Si(n,t,e){return!n.isSymbolicLink()&&!n.isFile()?!1:vu(t,e)}function Ii(n,t,e){ji.stat(n,function(s,r){e(s,s?!1:Si(r,n,t))})}function Ou(n,t){return Si(ji.statSync(n),n,t)}});var Ri=pt((jc,Ni)=>{Ni.exports=ki;ki.sync=_u;var Wi=require("fs");function ki(n,t,e){Wi.stat(n,function(s,r){e(s,s?!1:Ti(r,t))})}function _u(n,t){return Ti(Wi.statSync(n),t)}function Ti(n,t){return n.isFile()&&ju(n,t)}function ju(n,t){var e=n.mode,s=n.uid,r=n.gid,o=t.uid!==void 0?t.uid:process.getuid&&process.getuid(),i=t.gid!==void 0?t.gid:process.getgid&&process.getgid(),a=parseInt("100",8),l=parseInt("010",8),h=parseInt("001",8),f=a|l,D=e&h||e&l&&r===i||e&a&&s===o||e&f&&o===0;return D}});var zi=pt((Ic,Li)=>{var Sc=require("fs"),rn;process.platform==="win32"||global.TESTING_WINDOWS?rn=Mi():rn=Ri();Li.exports=cs;cs.sync=Su;function cs(n,t,e){if(typeof t=="function"&&(e=t,t={}),!e){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(s,r){cs(n,t||{},function(o,i){o?r(o):s(i)})})}rn(n,t||{},function(s,r){s&&(s.code==="EACCES"||t&&t.ignoreErrors)&&(s=null,r=!1),e(s,r)})}function Su(n,t){try{return rn.sync(n,t||{})}catch(e){if(t&&t.ignoreErrors||e.code==="EACCES")return!1;throw e}}});var Ji=pt((Pc,Gi)=>{var we=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",qi=require("path"),Iu=we?";":":",Hi=zi(),Ui=n=>Object.assign(new Error(`not found: ${n}`),{code:"ENOENT"}),Vi=(n,t)=>{let e=t.colon||Iu,s=n.match(/\//)||we&&n.match(/\\/)?[""]:[...we?[process.cwd()]:[],...(t.path||process.env.PATH||"").split(e)],r=we?t.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",o=we?r.split(e):[""];return we&&n.indexOf(".")!==-1&&o[0]!==""&&o.unshift(""),{pathEnv:s,pathExt:o,pathExtExe:r}},Yi=(n,t,e)=>{typeof t=="function"&&(e=t,t={}),t||(t={});let{pathEnv:s,pathExt:r,pathExtExe:o}=Vi(n,t),i=[],a=h=>new Promise((f,D)=>{if(h===s.length)return t.all&&i.length?f(i):D(Ui(n));let m=s[h],C=/^".*"$/.test(m)?m.slice(1,-1):m,E=qi.join(C,n),b=!C&&/^\.[\\\/]/.test(n)?n.slice(0,2)+E:E;f(l(b,h,0))}),l=(h,f,D)=>new Promise((m,C)=>{if(D===r.length)return m(a(f+1));let E=r[D];Hi(h+E,{pathExt:o},(b,g)=>{if(!b&&g)if(t.all)i.push(h+E);else return m(h+E);return m(l(h,f,D+1))})});return e?a(0).then(h=>e(null,h),e):a(0)},Pu=(n,t)=>{t=t||{};let{pathEnv:e,pathExt:s,pathExtExe:r}=Vi(n,t),o=[];for(let i=0;i<e.length;i++){let a=e[i],l=/^".*"$/.test(a)?a.slice(1,-1):a,h=qi.join(l,n),f=!l&&/^\.[\\\/]/.test(n)?n.slice(0,2)+h:h;for(let D=0;D<s.length;D++){let m=f+s[D];try{if(Hi.sync(m,{pathExt:r}))if(t.all)o.push(m);else return m}catch{}}}if(t.all&&o.length)return o;if(t.nothrow)return null;throw Ui(n)};Gi.exports=Yi;Yi.sync=Pu});var Qi=pt((Mc,ls)=>{"use strict";var Ki=(n={})=>{let t=n.env||process.env;return(n.platform||process.platform)!=="win32"?"PATH":Object.keys(t).reverse().find(s=>s.toUpperCase()==="PATH")||"Path"};ls.exports=Ki;ls.exports.default=Ki});var er=pt((Wc,tr)=>{"use strict";var Zi=require("path"),Mu=Ji(),Wu=Qi();function Xi(n,t){let e=n.options.env||process.env,s=process.cwd(),r=n.options.cwd!=null,o=r&&process.chdir!==void 0&&!process.chdir.disabled;if(o)try{process.chdir(n.options.cwd)}catch{}let i;try{i=Mu.sync(n.command,{path:e[Wu({env:e})],pathExt:t?Zi.delimiter:void 0})}catch{}finally{o&&process.chdir(s)}return i&&(i=Zi.resolve(r?n.options.cwd:"",i)),i}function ku(n){return Xi(n)||Xi(n,!0)}tr.exports=ku});var nr=pt((kc,hs)=>{"use strict";var Ds=/([()\][%!^"`<>&|;, *?])/g;function Tu(n){return n=n.replace(Ds,"^$1"),n}function Nu(n,t){return n=`${n}`,n=n.replace(/(\\*)"/g,'$1$1\\"'),n=n.replace(/(\\*)$/,"$1$1"),n=`"${n}"`,n=n.replace(Ds,"^$1"),t&&(n=n.replace(Ds,"^$1")),n}hs.exports.command=Tu;hs.exports.argument=Nu});var ir=pt((Tc,sr)=>{"use strict";sr.exports=/^#!(.*)/});var or=pt((Nc,rr)=>{"use strict";var Ru=ir();rr.exports=(n="")=>{let t=n.match(Ru);if(!t)return null;let[e,s]=t[0].replace(/#! ?/,"").split(" "),r=e.split("/").pop();return r==="env"?s:s?`${r} ${s}`:r}});var ar=pt((Rc,ur)=>{"use strict";var fs=require("fs"),Lu=or();function zu(n){let e=Buffer.alloc(150),s;try{s=fs.openSync(n,"r"),fs.readSync(s,e,0,150,0),fs.closeSync(s)}catch{}return Lu(e.toString())}ur.exports=zu});var hr=pt((Lc,Dr)=>{"use strict";var qu=require("path"),cr=er(),lr=nr(),Hu=ar(),Uu=process.platform==="win32",Vu=/\.(?:com|exe)$/i,Yu=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function Gu(n){n.file=cr(n);let t=n.file&&Hu(n.file);return t?(n.args.unshift(n.file),n.command=t,cr(n)):n.file}function Ju(n){if(!Uu)return n;let t=Gu(n),e=!Vu.test(t);if(n.options.forceShell||e){let s=Yu.test(t);n.command=qu.normalize(n.command),n.command=lr.command(n.command),n.args=n.args.map(o=>lr.argument(o,s));let r=[n.command].concat(n.args).join(" ");n.args=["/d","/s","/c",`"${r}"`],n.command=process.env.comspec||"cmd.exe",n.options.windowsVerbatimArguments=!0}return n}function Ku(n,t,e){t&&!Array.isArray(t)&&(e=t,t=null),t=t?t.slice(0):[],e=Object.assign({},e);let s={command:n,args:t,options:e,file:void 0,original:{command:n,args:t}};return e.shell?s:Ju(s)}Dr.exports=Ku});var dr=pt((zc,pr)=>{"use strict";var ps=process.platform==="win32";function ds(n,t){return Object.assign(new Error(`${t} ${n.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${t} ${n.command}`,path:n.command,spawnargs:n.args})}function Qu(n,t){if(!ps)return;let e=n.emit;n.emit=function(s,r){if(s==="exit"){let o=fr(r,t,"spawn");if(o)return e.call(n,"error",o)}return e.apply(n,arguments)}}function fr(n,t){return ps&&n===1&&!t.file?ds(t.original,"spawn"):null}function Zu(n,t){return ps&&n===1&&!t.file?ds(t.original,"spawnSync"):null}pr.exports={hookChildProcess:Qu,verifyENOENT:fr,verifyENOENTSync:Zu,notFoundError:ds}});var Cr=pt((qc,Ae)=>{"use strict";var mr=require("child_process"),ms=hr(),gs=dr();function gr(n,t,e){let s=ms(n,t,e),r=mr.spawn(s.command,s.args,s.options);return gs.hookChildProcess(r,s),r}function Xu(n,t,e){let s=ms(n,t,e),r=mr.spawnSync(s.command,s.args,s.options);return r.error=r.error||gs.verifyENOENTSync(r.status,s),r}Ae.exports=gr;Ae.exports.spawn=gr;Ae.exports.sync=Xu;Ae.exports._parse=ms;Ae.exports._enoent=gs});var br=pt((Hc,Fr)=>{"use strict";Fr.exports=function(){if(process.env.npm_config_user_agent)return ta(process.env.npm_config_user_agent)};function ta(n){let t=n.split(" ")[0],e=t.lastIndexOf("/"),s=t.substring(0,e);return{name:s==="npminstall"?"cnpm":s,version:t.substring(e+1)}}});var Ja={};Ko(Ja,{createApp:()=>Ho,runCli:()=>Ya,runCreateCli:()=>Xs,runCreateInteractiveCli:()=>ei});module.exports=Qo(Ja);var gt=ut(qn(),1),be=require("process"),Ht=ut(require("readline"),1),Gn=ut(require("readline"),1),fi=require("tty"),Je=ut(Un(),1);function su({onlyFirst:n=!1}={}){let t=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(t,n?void 0:"g")}function pi(n){if(typeof n!="string")throw new TypeError(`Expected a \`string\`, got \`${typeof n}\``);return n.replace(su(),"")}var Jn={},iu={get exports(){return Jn},set exports(n){Jn=n}};(function(n){var t={};n.exports=t,t.eastAsianWidth=function(s){var r=s.charCodeAt(0),o=s.length==2?s.charCodeAt(1):0,i=r;return 55296<=r&&r<=56319&&56320<=o&&o<=57343&&(r&=1023,o&=1023,i=r<<10|o,i+=65536),i==12288||65281<=i&&i<=65376||65504<=i&&i<=65510?"F":i==8361||65377<=i&&i<=65470||65474<=i&&i<=65479||65482<=i&&i<=65487||65490<=i&&i<=65495||65498<=i&&i<=65500||65512<=i&&i<=65518?"H":4352<=i&&i<=4447||4515<=i&&i<=4519||4602<=i&&i<=4607||9001<=i&&i<=9002||11904<=i&&i<=11929||11931<=i&&i<=12019||12032<=i&&i<=12245||12272<=i&&i<=12283||12289<=i&&i<=12350||12353<=i&&i<=12438||12441<=i&&i<=12543||12549<=i&&i<=12589||12593<=i&&i<=12686||12688<=i&&i<=12730||12736<=i&&i<=12771||12784<=i&&i<=12830||12832<=i&&i<=12871||12880<=i&&i<=13054||13056<=i&&i<=19903||19968<=i&&i<=42124||42128<=i&&i<=42182||43360<=i&&i<=43388||44032<=i&&i<=55203||55216<=i&&i<=55238||55243<=i&&i<=55291||63744<=i&&i<=64255||65040<=i&&i<=65049||65072<=i&&i<=65106||65108<=i&&i<=65126||65128<=i&&i<=65131||110592<=i&&i<=110593||127488<=i&&i<=127490||127504<=i&&i<=127546||127552<=i&&i<=127560||127568<=i&&i<=127569||131072<=i&&i<=194367||177984<=i&&i<=196605||196608<=i&&i<=262141?"W":32<=i&&i<=126||162<=i&&i<=163||165<=i&&i<=166||i==172||i==175||10214<=i&&i<=10221||10629<=i&&i<=10630?"Na":i==161||i==164||167<=i&&i<=168||i==170||173<=i&&i<=174||176<=i&&i<=180||182<=i&&i<=186||188<=i&&i<=191||i==198||i==208||215<=i&&i<=216||222<=i&&i<=225||i==230||232<=i&&i<=234||236<=i&&i<=237||i==240||242<=i&&i<=243||247<=i&&i<=250||i==252||i==254||i==257||i==273||i==275||i==283||294<=i&&i<=295||i==299||305<=i&&i<=307||i==312||319<=i&&i<=322||i==324||328<=i&&i<=331||i==333||338<=i&&i<=339||358<=i&&i<=359||i==363||i==462||i==464||i==466||i==468||i==470||i==472||i==474||i==476||i==593||i==609||i==708||i==711||713<=i&&i<=715||i==717||i==720||728<=i&&i<=731||i==733||i==735||768<=i&&i<=879||913<=i&&i<=929||931<=i&&i<=937||945<=i&&i<=961||963<=i&&i<=969||i==1025||1040<=i&&i<=1103||i==1105||i==8208||8211<=i&&i<=8214||8216<=i&&i<=8217||8220<=i&&i<=8221||8224<=i&&i<=8226||8228<=i&&i<=8231||i==8240||8242<=i&&i<=8243||i==8245||i==8251||i==8254||i==8308||i==8319||8321<=i&&i<=8324||i==8364||i==8451||i==8453||i==8457||i==8467||i==8470||8481<=i&&i<=8482||i==8486||i==8491||8531<=i&&i<=8532||8539<=i&&i<=8542||8544<=i&&i<=8555||8560<=i&&i<=8569||i==8585||8592<=i&&i<=8601||8632<=i&&i<=8633||i==8658||i==8660||i==8679||i==8704||8706<=i&&i<=8707||8711<=i&&i<=8712||i==8715||i==8719||i==8721||i==8725||i==8730||8733<=i&&i<=8736||i==8739||i==8741||8743<=i&&i<=8748||i==8750||8756<=i&&i<=8759||8764<=i&&i<=8765||i==8776||i==8780||i==8786||8800<=i&&i<=8801||8804<=i&&i<=8807||8810<=i&&i<=8811||8814<=i&&i<=8815||8834<=i&&i<=8835||8838<=i&&i<=8839||i==8853||i==8857||i==8869||i==8895||i==8978||9312<=i&&i<=9449||9451<=i&&i<=9547||9552<=i&&i<=9587||9600<=i&&i<=9615||9618<=i&&i<=9621||9632<=i&&i<=9633||9635<=i&&i<=9641||9650<=i&&i<=9651||9654<=i&&i<=9655||9660<=i&&i<=9661||9664<=i&&i<=9665||9670<=i&&i<=9672||i==9675||9678<=i&&i<=9681||9698<=i&&i<=9701||i==9711||9733<=i&&i<=9734||i==9737||9742<=i&&i<=9743||9748<=i&&i<=9749||i==9756||i==9758||i==9792||i==9794||9824<=i&&i<=9825||9827<=i&&i<=9829||9831<=i&&i<=9834||9836<=i&&i<=9837||i==9839||9886<=i&&i<=9887||9918<=i&&i<=9919||9924<=i&&i<=9933||9935<=i&&i<=9953||i==9955||9960<=i&&i<=9983||i==10045||i==10071||10102<=i&&i<=10111||11093<=i&&i<=11097||12872<=i&&i<=12879||57344<=i&&i<=63743||65024<=i&&i<=65039||i==65533||127232<=i&&i<=127242||127248<=i&&i<=127277||127280<=i&&i<=127337||127344<=i&&i<=127386||917760<=i&&i<=917999||983040<=i&&i<=1048573||1048576<=i&&i<=1114109?"A":"N"},t.characterLength=function(s){var r=this.eastAsianWidth(s);return r=="F"||r=="W"||r=="A"?2:1};function e(s){return s.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]|[^\uD800-\uDFFF]/g)||[]}t.length=function(s){for(var r=e(s),o=0,i=0;i<r.length;i++)o=o+this.characterLength(r[i]);return o},t.slice=function(s,r,o){textLen=t.length(s),r=r||0,o=o||1,r<0&&(r=textLen+r),o<0&&(o=textLen+o);for(var i="",a=0,l=e(s),h=0;h<l.length;h++){var f=l[h],D=t.length(f);if(a>=r-(D==2?1:0))if(a+D<=o)i+=f;else break;a+=D}return i}})(iu);var ru=Jn,ou=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\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83E\uDDD1(?:\u200D(?:\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\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|\uD83D\uDC08\u200D\u2B1B|\u2764\uFE0F\u200D(?:\uD83D\uDD25|\uD83E\uDE79)|\uD83D\uDC41\uFE0F|\uD83C\uDFF3\uFE0F|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|[#\*0-9]\uFE0F\u20E3|\u2764\uFE0F|(?:\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])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|\uD83C\uDFF4|(?:[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\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]|\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};function Me(n,t={}){if(typeof n!="string"||n.length===0||(t={ambiguousIsNarrow:!0,...t},n=pi(n),n.length===0))return 0;n=n.replace(ou()," ");let e=t.ambiguousIsNarrow?1:2,s=0;for(let r of n){let o=r.codePointAt(0);if(!(o<=31||o>=127&&o<=159||o>=768&&o<=879))switch(ru.eastAsianWidth(r)){case"F":case"W":s+=2;break;case"A":s+=e;break;default:s+=1}}return s}var Vn=10,oi=(n=0)=>t=>`\x1B[${t+n}m`,ui=(n=0)=>t=>`\x1B[${38+n};5;${t}m`,ai=(n=0)=>(t,e,s)=>`\x1B[${38+n};2;${t};${e};${s}m`,Z={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]}};Object.keys(Z.modifier);var uu=Object.keys(Z.color),au=Object.keys(Z.bgColor);[...uu,...au];function cu(){let n=new Map;for(let[t,e]of Object.entries(Z)){for(let[s,r]of Object.entries(e))Z[s]={open:`\x1B[${r[0]}m`,close:`\x1B[${r[1]}m`},e[s]=Z[s],n.set(r[0],r[1]);Object.defineProperty(Z,t,{value:e,enumerable:!1})}return Object.defineProperty(Z,"codes",{value:n,enumerable:!1}),Z.color.close="\x1B[39m",Z.bgColor.close="\x1B[49m",Z.color.ansi=oi(),Z.color.ansi256=ui(),Z.color.ansi16m=ai(),Z.bgColor.ansi=oi(Vn),Z.bgColor.ansi256=ui(Vn),Z.bgColor.ansi16m=ai(Vn),Object.defineProperties(Z,{rgbToAnsi256:{value:(t,e,s)=>t===e&&e===s?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(e/255*5)+Math.round(s/255*5),enumerable:!1},hexToRgb:{value:t=>{let e=/[a-f\d]{6}|[a-f\d]{3}/i.exec(t.toString(16));if(!e)return[0,0,0];let[s]=e;s.length===3&&(s=[...s].map(o=>o+o).join(""));let r=Number.parseInt(s,16);return[r>>16&255,r>>8&255,r&255]},enumerable:!1},hexToAnsi256:{value:t=>Z.rgbToAnsi256(...Z.hexToRgb(t)),enumerable:!1},ansi256ToAnsi:{value:t=>{if(t<8)return 30+t;if(t<16)return 90+(t-8);let e,s,r;if(t>=232)e=((t-232)*10+8)/255,s=e,r=e;else{t-=16;let a=t%36;e=Math.floor(t/36)/5,s=Math.floor(a/6)/5,r=a%6/5}let o=Math.max(e,s,r)*2;if(o===0)return 30;let i=30+(Math.round(r)<<2|Math.round(s)<<1|Math.round(e));return o===2&&(i+=60),i},enumerable:!1},rgbToAnsi:{value:(t,e,s)=>Z.ansi256ToAnsi(Z.rgbToAnsi256(t,e,s)),enumerable:!1},hexToAnsi:{value:t=>Z.ansi256ToAnsi(Z.hexToAnsi256(t)),enumerable:!1}}),Z}var lu=cu(),Xe=new Set(["\x1B","\x9B"]),Du=39,Kn="\x07",di="[",hu="]",mi="m",Qn=`${hu}8;;`,ci=n=>`${Xe.values().next().value}${di}${n}${mi}`,li=n=>`${Xe.values().next().value}${Qn}${n}${Kn}`,fu=n=>n.split(" ").map(t=>Me(t)),Yn=(n,t,e)=>{let s=[...t],r=!1,o=!1,i=Me(pi(n[n.length-1]));for(let[a,l]of s.entries()){let h=Me(l);if(i+h<=e?n[n.length-1]+=l:(n.push(l),i=0),Xe.has(l)&&(r=!0,o=s.slice(a+1).join("").startsWith(Qn)),r){o?l===Kn&&(r=!1,o=!1):l===mi&&(r=!1);continue}i+=h,i===e&&a<s.length-1&&(n.push(""),i=0)}!i&&n[n.length-1].length>0&&n.length>1&&(n[n.length-2]+=n.pop())},pu=n=>{let t=n.split(" "),e=t.length;for(;e>0&&!(Me(t[e-1])>0);)e--;return e===t.length?n:t.slice(0,e).join(" ")+t.slice(e).join("")},du=(n,t,e={})=>{if(e.trim!==!1&&n.trim()==="")return"";let s="",r,o,i=fu(n),a=[""];for(let[h,f]of n.split(" ").entries()){e.trim!==!1&&(a[a.length-1]=a[a.length-1].trimStart());let D=Me(a[a.length-1]);if(h!==0&&(D>=t&&(e.wordWrap===!1||e.trim===!1)&&(a.push(""),D=0),(D>0||e.trim===!1)&&(a[a.length-1]+=" ",D++)),e.hard&&i[h]>t){let m=t-D,C=1+Math.floor((i[h]-m-1)/t);Math.floor((i[h]-1)/t)<C&&a.push(""),Yn(a,f,t);continue}if(D+i[h]>t&&D>0&&i[h]>0){if(e.wordWrap===!1&&D<t){Yn(a,f,t);continue}a.push("")}if(D+i[h]>t&&e.wordWrap===!1){Yn(a,f,t);continue}a[a.length-1]+=f}e.trim!==!1&&(a=a.map(h=>pu(h)));let l=[...a.join(`
|
|
9
|
-
`)];for(let[h,f]of
|
|
10
|
-
`?(o&&(s+=
|
|
11
|
-
`&&(r&&
|
|
8
|
+
"use strict";var Jo=Object.create;var Ye=Object.defineProperty;var Ko=Object.getOwnPropertyDescriptor;var Qo=Object.getOwnPropertyNames;var Zo=Object.getPrototypeOf,Xo=Object.prototype.hasOwnProperty;var pt=(n,t)=>()=>(t||n((t={exports:{}}).exports,t),t.exports),tu=(n,t)=>{for(var e in t)Ye(n,e,{get:t[e],enumerable:!0})},si=(n,t,e,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Qo(t))!Xo.call(n,r)&&r!==e&&Ye(n,r,{get:()=>t[r],enumerable:!(s=Ko(t,r))||s.enumerable});return n};var ut=(n,t,e)=>(e=n!=null?Jo(Zo(n)):{},si(t||!n||!n.__esModule?Ye(e,"default",{value:n,enumerable:!0}):e,n)),eu=n=>si(Ye({},"__esModule",{value:!0}),n);var Hn=pt((ic,ii)=>{"use strict";var zn="\x1B",tt=`${zn}[`,nu="\x07",qn={to(n,t){return t?`${tt}${t+1};${n+1}H`:`${tt}${n+1}G`},move(n,t){let e="";return n<0?e+=`${tt}${-n}D`:n>0&&(e+=`${tt}${n}C`),t<0?e+=`${tt}${-t}A`:t>0&&(e+=`${tt}${t}B`),e},up:(n=1)=>`${tt}${n}A`,down:(n=1)=>`${tt}${n}B`,forward:(n=1)=>`${tt}${n}C`,backward:(n=1)=>`${tt}${n}D`,nextLine:(n=1)=>`${tt}E`.repeat(n),prevLine:(n=1)=>`${tt}F`.repeat(n),left:`${tt}G`,hide:`${tt}?25l`,show:`${tt}?25h`,save:`${zn}7`,restore:`${zn}8`},su={up:(n=1)=>`${tt}S`.repeat(n),down:(n=1)=>`${tt}T`.repeat(n)},iu={screen:`${tt}2J`,up:(n=1)=>`${tt}1J`.repeat(n),down:(n=1)=>`${tt}J`.repeat(n),line:`${tt}2K`,lineEnd:`${tt}K`,lineStart:`${tt}1K`,lines(n){let t="";for(let e=0;e<n;e++)t+=this.line+(e<n-1?qn.up():"");return n&&(t+=qn.left),t}};ii.exports={cursor:qn,scroll:su,erase:iu,beep:nu}});var Vn=pt((rc,Un)=>{var ru=require("tty"),ou=!("NO_COLOR"in process.env||process.argv.includes("--no-color"))&&("FORCE_COLOR"in process.env||process.argv.includes("--color")||process.platform==="win32"||ru.isatty(1)&&process.env.TERM!=="dumb"||"CI"in process.env),Q=(n,t,e=n)=>s=>{let r=""+s,o=r.indexOf(t,n.length);return~o?n+ri(r,t,e,o)+t:n+r+t},ri=(n,t,e,s)=>{let r=n.substring(0,s)+e,o=n.substring(s+t.length),i=o.indexOf(t);return~i?r+ri(o,t,e,i):r+o},oi=(n=ou)=>({isColorSupported:n,reset:n?t=>`\x1B[0m${t}\x1B[0m`:String,bold:n?Q("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"):String,dim:n?Q("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"):String,italic:n?Q("\x1B[3m","\x1B[23m"):String,underline:n?Q("\x1B[4m","\x1B[24m"):String,inverse:n?Q("\x1B[7m","\x1B[27m"):String,hidden:n?Q("\x1B[8m","\x1B[28m"):String,strikethrough:n?Q("\x1B[9m","\x1B[29m"):String,black:n?Q("\x1B[30m","\x1B[39m"):String,red:n?Q("\x1B[31m","\x1B[39m"):String,green:n?Q("\x1B[32m","\x1B[39m"):String,yellow:n?Q("\x1B[33m","\x1B[39m"):String,blue:n?Q("\x1B[34m","\x1B[39m"):String,magenta:n?Q("\x1B[35m","\x1B[39m"):String,cyan:n?Q("\x1B[36m","\x1B[39m"):String,white:n?Q("\x1B[37m","\x1B[39m"):String,gray:n?Q("\x1B[90m","\x1B[39m"):String,bgBlack:n?Q("\x1B[40m","\x1B[49m"):String,bgRed:n?Q("\x1B[41m","\x1B[49m"):String,bgGreen:n?Q("\x1B[42m","\x1B[49m"):String,bgYellow:n?Q("\x1B[43m","\x1B[49m"):String,bgBlue:n?Q("\x1B[44m","\x1B[49m"):String,bgMagenta:n?Q("\x1B[45m","\x1B[49m"):String,bgCyan:n?Q("\x1B[46m","\x1B[49m"):String,bgWhite:n?Q("\x1B[47m","\x1B[49m"):String});Un.exports=oi();Un.exports.createColors=oi});var Pi=pt((kc,Mi)=>{"use strict";Mi.exports=function(){if(process.env.npm_config_user_agent)return _u(process.env.npm_config_user_agent)};function _u(n){let t=n.split(" ")[0],e=t.lastIndexOf("/"),s=t.substring(0,e);return{name:s==="npminstall"?"cnpm":s,version:t.substring(e+1)}}});var Ri=pt((Tc,Ni)=>{Ni.exports=Ti;Ti.sync=Su;var Wi=require("fs");function ju(n,t){var e=t.pathExt!==void 0?t.pathExt:process.env.PATHEXT;if(!e||(e=e.split(";"),e.indexOf("")!==-1))return!0;for(var s=0;s<e.length;s++){var r=e[s].toLowerCase();if(r&&n.substr(-r.length).toLowerCase()===r)return!0}return!1}function ki(n,t,e){return!n.isSymbolicLink()&&!n.isFile()?!1:ju(t,e)}function Ti(n,t,e){Wi.stat(n,function(s,r){e(s,s?!1:ki(r,n,t))})}function Su(n,t){return ki(Wi.statSync(n),n,t)}});var Ui=pt((Nc,Hi)=>{Hi.exports=zi;zi.sync=Iu;var Li=require("fs");function zi(n,t,e){Li.stat(n,function(s,r){e(s,s?!1:qi(r,t))})}function Iu(n,t){return qi(Li.statSync(n),t)}function qi(n,t){return n.isFile()&&Mu(n,t)}function Mu(n,t){var e=n.mode,s=n.uid,r=n.gid,o=t.uid!==void 0?t.uid:process.getuid&&process.getuid(),i=t.gid!==void 0?t.gid:process.getgid&&process.getgid(),a=parseInt("100",8),c=parseInt("010",8),h=parseInt("001",8),f=a|c,l=e&h||e&c&&r===i||e&a&&s===o||e&f&&o===0;return l}});var Gi=pt((Lc,Vi)=>{var Rc=require("fs"),on;process.platform==="win32"||global.TESTING_WINDOWS?on=Ri():on=Ui();Vi.exports=cs;cs.sync=Pu;function cs(n,t,e){if(typeof t=="function"&&(e=t,t={}),!e){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(s,r){cs(n,t||{},function(o,i){o?r(o):s(i)})})}on(n,t||{},function(s,r){s&&(s.code==="EACCES"||t&&t.ignoreErrors)&&(s=null,r=!1),e(s,r)})}function Pu(n,t){try{return on.sync(n,t||{})}catch(e){if(t&&t.ignoreErrors||e.code==="EACCES")return!1;throw e}}});var tr=pt((zc,Xi)=>{var Ae=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",Yi=require("path"),Wu=Ae?";":":",Ji=Gi(),Ki=n=>Object.assign(new Error(`not found: ${n}`),{code:"ENOENT"}),Qi=(n,t)=>{let e=t.colon||Wu,s=n.match(/\//)||Ae&&n.match(/\\/)?[""]:[...Ae?[process.cwd()]:[],...(t.path||process.env.PATH||"").split(e)],r=Ae?t.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",o=Ae?r.split(e):[""];return Ae&&n.indexOf(".")!==-1&&o[0]!==""&&o.unshift(""),{pathEnv:s,pathExt:o,pathExtExe:r}},Zi=(n,t,e)=>{typeof t=="function"&&(e=t,t={}),t||(t={});let{pathEnv:s,pathExt:r,pathExtExe:o}=Qi(n,t),i=[],a=h=>new Promise((f,l)=>{if(h===s.length)return t.all&&i.length?f(i):l(Ki(n));let m=s[h],C=/^".*"$/.test(m)?m.slice(1,-1):m,E=Yi.join(C,n),b=!C&&/^\.[\\\/]/.test(n)?n.slice(0,2)+E:E;f(c(b,h,0))}),c=(h,f,l)=>new Promise((m,C)=>{if(l===r.length)return m(a(f+1));let E=r[l];Ji(h+E,{pathExt:o},(b,g)=>{if(!b&&g)if(t.all)i.push(h+E);else return m(h+E);return m(c(h,f,l+1))})});return e?a(0).then(h=>e(null,h),e):a(0)},ku=(n,t)=>{t=t||{};let{pathEnv:e,pathExt:s,pathExtExe:r}=Qi(n,t),o=[];for(let i=0;i<e.length;i++){let a=e[i],c=/^".*"$/.test(a)?a.slice(1,-1):a,h=Yi.join(c,n),f=!c&&/^\.[\\\/]/.test(n)?n.slice(0,2)+h:h;for(let l=0;l<s.length;l++){let m=f+s[l];try{if(Ji.sync(m,{pathExt:r}))if(t.all)o.push(m);else return m}catch{}}}if(t.all&&o.length)return o;if(t.nothrow)return null;throw Ki(n)};Xi.exports=Zi;Zi.sync=ku});var nr=pt((qc,ls)=>{"use strict";var er=(n={})=>{let t=n.env||process.env;return(n.platform||process.platform)!=="win32"?"PATH":Object.keys(t).reverse().find(s=>s.toUpperCase()==="PATH")||"Path"};ls.exports=er;ls.exports.default=er});var or=pt((Hc,rr)=>{"use strict";var sr=require("path"),Tu=tr(),Nu=nr();function ir(n,t){let e=n.options.env||process.env,s=process.cwd(),r=n.options.cwd!=null,o=r&&process.chdir!==void 0&&!process.chdir.disabled;if(o)try{process.chdir(n.options.cwd)}catch{}let i;try{i=Tu.sync(n.command,{path:e[Nu({env:e})],pathExt:t?sr.delimiter:void 0})}catch{}finally{o&&process.chdir(s)}return i&&(i=sr.resolve(r?n.options.cwd:"",i)),i}function Ru(n){return ir(n)||ir(n,!0)}rr.exports=Ru});var ur=pt((Uc,hs)=>{"use strict";var Ds=/([()\][%!^"`<>&|;, *?])/g;function Lu(n){return n=n.replace(Ds,"^$1"),n}function zu(n,t){return n=`${n}`,n=n.replace(/(\\*)"/g,'$1$1\\"'),n=n.replace(/(\\*)$/,"$1$1"),n=`"${n}"`,n=n.replace(Ds,"^$1"),t&&(n=n.replace(Ds,"^$1")),n}hs.exports.command=Lu;hs.exports.argument=zu});var cr=pt((Vc,ar)=>{"use strict";ar.exports=/^#!(.*)/});var Dr=pt((Gc,lr)=>{"use strict";var qu=cr();lr.exports=(n="")=>{let t=n.match(qu);if(!t)return null;let[e,s]=t[0].replace(/#! ?/,"").split(" "),r=e.split("/").pop();return r==="env"?s:s?`${r} ${s}`:r}});var fr=pt((Yc,hr)=>{"use strict";var fs=require("fs"),Hu=Dr();function Uu(n){let e=Buffer.alloc(150),s;try{s=fs.openSync(n,"r"),fs.readSync(s,e,0,150,0),fs.closeSync(s)}catch{}return Hu(e.toString())}hr.exports=Uu});var gr=pt((Jc,mr)=>{"use strict";var Vu=require("path"),pr=or(),dr=ur(),Gu=fr(),Yu=process.platform==="win32",Ju=/\.(?:com|exe)$/i,Ku=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function Qu(n){n.file=pr(n);let t=n.file&&Gu(n.file);return t?(n.args.unshift(n.file),n.command=t,pr(n)):n.file}function Zu(n){if(!Yu)return n;let t=Qu(n),e=!Ju.test(t);if(n.options.forceShell||e){let s=Ku.test(t);n.command=Vu.normalize(n.command),n.command=dr.command(n.command),n.args=n.args.map(o=>dr.argument(o,s));let r=[n.command].concat(n.args).join(" ");n.args=["/d","/s","/c",`"${r}"`],n.command=process.env.comspec||"cmd.exe",n.options.windowsVerbatimArguments=!0}return n}function Xu(n,t,e){t&&!Array.isArray(t)&&(e=t,t=null),t=t?t.slice(0):[],e=Object.assign({},e);let s={command:n,args:t,options:e,file:void 0,original:{command:n,args:t}};return e.shell?s:Zu(s)}mr.exports=Xu});var Er=pt((Kc,Fr)=>{"use strict";var ps=process.platform==="win32";function ds(n,t){return Object.assign(new Error(`${t} ${n.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${t} ${n.command}`,path:n.command,spawnargs:n.args})}function ta(n,t){if(!ps)return;let e=n.emit;n.emit=function(s,r){if(s==="exit"){let o=Cr(r,t,"spawn");if(o)return e.call(n,"error",o)}return e.apply(n,arguments)}}function Cr(n,t){return ps&&n===1&&!t.file?ds(t.original,"spawn"):null}function ea(n,t){return ps&&n===1&&!t.file?ds(t.original,"spawnSync"):null}Fr.exports={hookChildProcess:ta,verifyENOENT:Cr,verifyENOENTSync:ea,notFoundError:ds}});var wr=pt((Qc,$e)=>{"use strict";var br=require("child_process"),ms=gr(),gs=Er();function yr(n,t,e){let s=ms(n,t,e),r=br.spawn(s.command,s.args,s.options);return gs.hookChildProcess(r,s),r}function na(n,t,e){let s=ms(n,t,e),r=br.spawnSync(s.command,s.args,s.options);return r.error=r.error||gs.verifyENOENTSync(r.status,s),r}$e.exports=yr;$e.exports.spawn=yr;$e.exports.sync=na;$e.exports._parse=ms;$e.exports._enoent=gs});var nc={};tu(nc,{createApp:()=>Yo,runCli:()=>tc,runCreateCli:()=>ti,runCreateInteractiveCli:()=>ni});module.exports=eu(nc);var gt=ut(Hn(),1),Ee=require("process"),Ht=ut(require("readline"),1),Jn=ut(require("readline"),1),pi=require("tty"),Ke=ut(Vn(),1);function uu({onlyFirst:n=!1}={}){let t=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(t,n?void 0:"g")}function di(n){if(typeof n!="string")throw new TypeError(`Expected a \`string\`, got \`${typeof n}\``);return n.replace(uu(),"")}var Kn={},au={get exports(){return Kn},set exports(n){Kn=n}};(function(n){var t={};n.exports=t,t.eastAsianWidth=function(s){var r=s.charCodeAt(0),o=s.length==2?s.charCodeAt(1):0,i=r;return 55296<=r&&r<=56319&&56320<=o&&o<=57343&&(r&=1023,o&=1023,i=r<<10|o,i+=65536),i==12288||65281<=i&&i<=65376||65504<=i&&i<=65510?"F":i==8361||65377<=i&&i<=65470||65474<=i&&i<=65479||65482<=i&&i<=65487||65490<=i&&i<=65495||65498<=i&&i<=65500||65512<=i&&i<=65518?"H":4352<=i&&i<=4447||4515<=i&&i<=4519||4602<=i&&i<=4607||9001<=i&&i<=9002||11904<=i&&i<=11929||11931<=i&&i<=12019||12032<=i&&i<=12245||12272<=i&&i<=12283||12289<=i&&i<=12350||12353<=i&&i<=12438||12441<=i&&i<=12543||12549<=i&&i<=12589||12593<=i&&i<=12686||12688<=i&&i<=12730||12736<=i&&i<=12771||12784<=i&&i<=12830||12832<=i&&i<=12871||12880<=i&&i<=13054||13056<=i&&i<=19903||19968<=i&&i<=42124||42128<=i&&i<=42182||43360<=i&&i<=43388||44032<=i&&i<=55203||55216<=i&&i<=55238||55243<=i&&i<=55291||63744<=i&&i<=64255||65040<=i&&i<=65049||65072<=i&&i<=65106||65108<=i&&i<=65126||65128<=i&&i<=65131||110592<=i&&i<=110593||127488<=i&&i<=127490||127504<=i&&i<=127546||127552<=i&&i<=127560||127568<=i&&i<=127569||131072<=i&&i<=194367||177984<=i&&i<=196605||196608<=i&&i<=262141?"W":32<=i&&i<=126||162<=i&&i<=163||165<=i&&i<=166||i==172||i==175||10214<=i&&i<=10221||10629<=i&&i<=10630?"Na":i==161||i==164||167<=i&&i<=168||i==170||173<=i&&i<=174||176<=i&&i<=180||182<=i&&i<=186||188<=i&&i<=191||i==198||i==208||215<=i&&i<=216||222<=i&&i<=225||i==230||232<=i&&i<=234||236<=i&&i<=237||i==240||242<=i&&i<=243||247<=i&&i<=250||i==252||i==254||i==257||i==273||i==275||i==283||294<=i&&i<=295||i==299||305<=i&&i<=307||i==312||319<=i&&i<=322||i==324||328<=i&&i<=331||i==333||338<=i&&i<=339||358<=i&&i<=359||i==363||i==462||i==464||i==466||i==468||i==470||i==472||i==474||i==476||i==593||i==609||i==708||i==711||713<=i&&i<=715||i==717||i==720||728<=i&&i<=731||i==733||i==735||768<=i&&i<=879||913<=i&&i<=929||931<=i&&i<=937||945<=i&&i<=961||963<=i&&i<=969||i==1025||1040<=i&&i<=1103||i==1105||i==8208||8211<=i&&i<=8214||8216<=i&&i<=8217||8220<=i&&i<=8221||8224<=i&&i<=8226||8228<=i&&i<=8231||i==8240||8242<=i&&i<=8243||i==8245||i==8251||i==8254||i==8308||i==8319||8321<=i&&i<=8324||i==8364||i==8451||i==8453||i==8457||i==8467||i==8470||8481<=i&&i<=8482||i==8486||i==8491||8531<=i&&i<=8532||8539<=i&&i<=8542||8544<=i&&i<=8555||8560<=i&&i<=8569||i==8585||8592<=i&&i<=8601||8632<=i&&i<=8633||i==8658||i==8660||i==8679||i==8704||8706<=i&&i<=8707||8711<=i&&i<=8712||i==8715||i==8719||i==8721||i==8725||i==8730||8733<=i&&i<=8736||i==8739||i==8741||8743<=i&&i<=8748||i==8750||8756<=i&&i<=8759||8764<=i&&i<=8765||i==8776||i==8780||i==8786||8800<=i&&i<=8801||8804<=i&&i<=8807||8810<=i&&i<=8811||8814<=i&&i<=8815||8834<=i&&i<=8835||8838<=i&&i<=8839||i==8853||i==8857||i==8869||i==8895||i==8978||9312<=i&&i<=9449||9451<=i&&i<=9547||9552<=i&&i<=9587||9600<=i&&i<=9615||9618<=i&&i<=9621||9632<=i&&i<=9633||9635<=i&&i<=9641||9650<=i&&i<=9651||9654<=i&&i<=9655||9660<=i&&i<=9661||9664<=i&&i<=9665||9670<=i&&i<=9672||i==9675||9678<=i&&i<=9681||9698<=i&&i<=9701||i==9711||9733<=i&&i<=9734||i==9737||9742<=i&&i<=9743||9748<=i&&i<=9749||i==9756||i==9758||i==9792||i==9794||9824<=i&&i<=9825||9827<=i&&i<=9829||9831<=i&&i<=9834||9836<=i&&i<=9837||i==9839||9886<=i&&i<=9887||9918<=i&&i<=9919||9924<=i&&i<=9933||9935<=i&&i<=9953||i==9955||9960<=i&&i<=9983||i==10045||i==10071||10102<=i&&i<=10111||11093<=i&&i<=11097||12872<=i&&i<=12879||57344<=i&&i<=63743||65024<=i&&i<=65039||i==65533||127232<=i&&i<=127242||127248<=i&&i<=127277||127280<=i&&i<=127337||127344<=i&&i<=127386||917760<=i&&i<=917999||983040<=i&&i<=1048573||1048576<=i&&i<=1114109?"A":"N"},t.characterLength=function(s){var r=this.eastAsianWidth(s);return r=="F"||r=="W"||r=="A"?2:1};function e(s){return s.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]|[^\uD800-\uDFFF]/g)||[]}t.length=function(s){for(var r=e(s),o=0,i=0;i<r.length;i++)o=o+this.characterLength(r[i]);return o},t.slice=function(s,r,o){textLen=t.length(s),r=r||0,o=o||1,r<0&&(r=textLen+r),o<0&&(o=textLen+o);for(var i="",a=0,c=e(s),h=0;h<c.length;h++){var f=c[h],l=t.length(f);if(a>=r-(l==2?1:0))if(a+l<=o)i+=f;else break;a+=l}return i}})(au);var cu=Kn,lu=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\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83E\uDDD1(?:\u200D(?:\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\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|\uD83D\uDC08\u200D\u2B1B|\u2764\uFE0F\u200D(?:\uD83D\uDD25|\uD83E\uDE79)|\uD83D\uDC41\uFE0F|\uD83C\uDFF3\uFE0F|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|[#\*0-9]\uFE0F\u20E3|\u2764\uFE0F|(?:\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])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|\uD83C\uDFF4|(?:[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\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]|\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};function ke(n,t={}){if(typeof n!="string"||n.length===0||(t={ambiguousIsNarrow:!0,...t},n=di(n),n.length===0))return 0;n=n.replace(lu()," ");let e=t.ambiguousIsNarrow?1:2,s=0;for(let r of n){let o=r.codePointAt(0);if(!(o<=31||o>=127&&o<=159||o>=768&&o<=879))switch(cu.eastAsianWidth(r)){case"F":case"W":s+=2;break;case"A":s+=e;break;default:s+=1}}return s}var Gn=10,ui=(n=0)=>t=>`\x1B[${t+n}m`,ai=(n=0)=>t=>`\x1B[${38+n};5;${t}m`,ci=(n=0)=>(t,e,s)=>`\x1B[${38+n};2;${t};${e};${s}m`,Z={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]}};Object.keys(Z.modifier);var Du=Object.keys(Z.color),hu=Object.keys(Z.bgColor);[...Du,...hu];function fu(){let n=new Map;for(let[t,e]of Object.entries(Z)){for(let[s,r]of Object.entries(e))Z[s]={open:`\x1B[${r[0]}m`,close:`\x1B[${r[1]}m`},e[s]=Z[s],n.set(r[0],r[1]);Object.defineProperty(Z,t,{value:e,enumerable:!1})}return Object.defineProperty(Z,"codes",{value:n,enumerable:!1}),Z.color.close="\x1B[39m",Z.bgColor.close="\x1B[49m",Z.color.ansi=ui(),Z.color.ansi256=ai(),Z.color.ansi16m=ci(),Z.bgColor.ansi=ui(Gn),Z.bgColor.ansi256=ai(Gn),Z.bgColor.ansi16m=ci(Gn),Object.defineProperties(Z,{rgbToAnsi256:{value:(t,e,s)=>t===e&&e===s?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(e/255*5)+Math.round(s/255*5),enumerable:!1},hexToRgb:{value:t=>{let e=/[a-f\d]{6}|[a-f\d]{3}/i.exec(t.toString(16));if(!e)return[0,0,0];let[s]=e;s.length===3&&(s=[...s].map(o=>o+o).join(""));let r=Number.parseInt(s,16);return[r>>16&255,r>>8&255,r&255]},enumerable:!1},hexToAnsi256:{value:t=>Z.rgbToAnsi256(...Z.hexToRgb(t)),enumerable:!1},ansi256ToAnsi:{value:t=>{if(t<8)return 30+t;if(t<16)return 90+(t-8);let e,s,r;if(t>=232)e=((t-232)*10+8)/255,s=e,r=e;else{t-=16;let a=t%36;e=Math.floor(t/36)/5,s=Math.floor(a/6)/5,r=a%6/5}let o=Math.max(e,s,r)*2;if(o===0)return 30;let i=30+(Math.round(r)<<2|Math.round(s)<<1|Math.round(e));return o===2&&(i+=60),i},enumerable:!1},rgbToAnsi:{value:(t,e,s)=>Z.ansi256ToAnsi(Z.rgbToAnsi256(t,e,s)),enumerable:!1},hexToAnsi:{value:t=>Z.ansi256ToAnsi(Z.hexToAnsi256(t)),enumerable:!1}}),Z}var pu=fu(),tn=new Set(["\x1B","\x9B"]),du=39,Qn="\x07",mi="[",mu="]",gi="m",Zn=`${mu}8;;`,li=n=>`${tn.values().next().value}${mi}${n}${gi}`,Di=n=>`${tn.values().next().value}${Zn}${n}${Qn}`,gu=n=>n.split(" ").map(t=>ke(t)),Yn=(n,t,e)=>{let s=[...t],r=!1,o=!1,i=ke(di(n[n.length-1]));for(let[a,c]of s.entries()){let h=ke(c);if(i+h<=e?n[n.length-1]+=c:(n.push(c),i=0),tn.has(c)&&(r=!0,o=s.slice(a+1).join("").startsWith(Zn)),r){o?c===Qn&&(r=!1,o=!1):c===gi&&(r=!1);continue}i+=h,i===e&&a<s.length-1&&(n.push(""),i=0)}!i&&n[n.length-1].length>0&&n.length>1&&(n[n.length-2]+=n.pop())},Cu=n=>{let t=n.split(" "),e=t.length;for(;e>0&&!(ke(t[e-1])>0);)e--;return e===t.length?n:t.slice(0,e).join(" ")+t.slice(e).join("")},Fu=(n,t,e={})=>{if(e.trim!==!1&&n.trim()==="")return"";let s="",r,o,i=gu(n),a=[""];for(let[h,f]of n.split(" ").entries()){e.trim!==!1&&(a[a.length-1]=a[a.length-1].trimStart());let l=ke(a[a.length-1]);if(h!==0&&(l>=t&&(e.wordWrap===!1||e.trim===!1)&&(a.push(""),l=0),(l>0||e.trim===!1)&&(a[a.length-1]+=" ",l++)),e.hard&&i[h]>t){let m=t-l,C=1+Math.floor((i[h]-m-1)/t);Math.floor((i[h]-1)/t)<C&&a.push(""),Yn(a,f,t);continue}if(l+i[h]>t&&l>0&&i[h]>0){if(e.wordWrap===!1&&l<t){Yn(a,f,t);continue}a.push("")}if(l+i[h]>t&&e.wordWrap===!1){Yn(a,f,t);continue}a[a.length-1]+=f}e.trim!==!1&&(a=a.map(h=>Cu(h)));let c=[...a.join(`
|
|
9
|
+
`)];for(let[h,f]of c.entries()){if(s+=f,tn.has(f)){let{groups:m}=new RegExp(`(?:\\${mi}(?<code>\\d+)m|\\${Zn}(?<uri>.*)${Qn})`).exec(c.slice(h).join(""))||{groups:{}};if(m.code!==void 0){let C=Number.parseFloat(m.code);r=C===du?void 0:C}else m.uri!==void 0&&(o=m.uri.length===0?void 0:m.uri)}let l=pu.codes.get(Number(r));c[h+1]===`
|
|
10
|
+
`?(o&&(s+=Di("")),r&&l&&(s+=li(l))):f===`
|
|
11
|
+
`&&(r&&l&&(s+=li(r)),o&&(s+=Di(o)))}return s};function hi(n,t,e){return String(n).normalize().replace(/\r\n/g,`
|
|
12
12
|
`).split(`
|
|
13
|
-
`).map(s=>
|
|
14
|
-
`)}function
|
|
13
|
+
`).map(s=>Fu(s,t,e)).join(`
|
|
14
|
+
`)}function Eu(n,t){if(n===t)return;let e=n.split(`
|
|
15
15
|
`),s=t.split(`
|
|
16
|
-
`),r=[];for(let o=0;o<Math.max(e.length,s.length);o++)e[o]!==s[o]&&r.push(o);return r}var
|
|
17
|
-
`),
|
|
18
|
-
`).length-1;this.output.write(gt.cursor.move(-999,t*-1))}render(){let t=
|
|
16
|
+
`),r=[];for(let o=0;o<Math.max(e.length,s.length);o++)e[o]!==s[o]&&r.push(o);return r}var Ci=Symbol("clack:cancel");function Ut(n){return n===Ci}function Je(n,t){n.isTTY&&n.setRawMode(t)}var fi=new Map([["k","up"],["j","down"],["h","left"],["l","right"]]),bu=new Set(["up","down","left","right","space","enter"]),Te=class{constructor({render:t,input:e=Ee.stdin,output:s=Ee.stdout,...r},o=!0){this._track=!1,this._cursor=0,this.state="initial",this.error="",this.subscribers=new Map,this._prevFrame="",this.opts=r,this.onKeypress=this.onKeypress.bind(this),this.close=this.close.bind(this),this.render=this.render.bind(this),this._render=t.bind(this),this._track=o,this.input=e,this.output=s}prompt(){let t=new pi.WriteStream(0);return t._write=(e,s,r)=>{this._track&&(this.value=this.rl.line.replace(/\t/g,""),this._cursor=this.rl.cursor,this.emit("value",this.value)),r()},this.input.pipe(t),this.rl=Jn.default.createInterface({input:this.input,output:t,tabSize:2,prompt:"",escapeCodeTimeout:50}),Jn.default.emitKeypressEvents(this.input,this.rl),this.rl.prompt(),this.opts.initialValue!==void 0&&this._track&&this.rl.write(this.opts.initialValue),this.input.on("keypress",this.onKeypress),Je(this.input,!0),this.output.on("resize",this.render),this.render(),new Promise((e,s)=>{this.once("submit",()=>{this.output.write(gt.cursor.show),this.output.off("resize",this.render),Je(this.input,!1),e(this.value)}),this.once("cancel",()=>{this.output.write(gt.cursor.show),this.output.off("resize",this.render),Je(this.input,!1),e(Ci)})})}on(t,e){let s=this.subscribers.get(t)??[];s.push({cb:e}),this.subscribers.set(t,s)}once(t,e){let s=this.subscribers.get(t)??[];s.push({cb:e,once:!0}),this.subscribers.set(t,s)}emit(t,...e){let s=this.subscribers.get(t)??[],r=[];for(let o of s)o.cb(...e),o.once&&r.push(()=>s.splice(s.indexOf(o),1));for(let o of r)o()}unsubscribe(){this.subscribers.clear()}onKeypress(t,e){if(this.state==="error"&&(this.state="active"),e!=null&&e.name&&!this._track&&fi.has(e.name)&&this.emit("cursor",fi.get(e.name)),e!=null&&e.name&&bu.has(e.name)&&this.emit("cursor",e.name),t&&(t.toLowerCase()==="y"||t.toLowerCase()==="n")&&this.emit("confirm",t.toLowerCase()==="y"),t&&this.emit("key",t.toLowerCase()),(e==null?void 0:e.name)==="return"){if(this.opts.validate){let s=this.opts.validate(this.value);s&&(this.error=s,this.state="error",this.rl.write(this.value))}this.state!=="error"&&(this.state="submit")}t===""&&(this.state="cancel"),(this.state==="submit"||this.state==="cancel")&&this.emit("finalize"),this.render(),(this.state==="submit"||this.state==="cancel")&&this.close()}close(){this.input.unpipe(),this.input.removeListener("keypress",this.onKeypress),this.output.write(`
|
|
17
|
+
`),Je(this.input,!1),this.rl.close(),this.emit(`${this.state}`,this.value),this.unsubscribe()}restoreCursor(){let t=hi(this._prevFrame,process.stdout.columns,{hard:!0}).split(`
|
|
18
|
+
`).length-1;this.output.write(gt.cursor.move(-999,t*-1))}render(){let t=hi(this._render(this)??"",process.stdout.columns,{hard:!0});if(t!==this._prevFrame){if(this.state==="initial")this.output.write(gt.cursor.hide);else{let e=Eu(this._prevFrame,t);if(this.restoreCursor(),e&&(e==null?void 0:e.length)===1){let s=e[0];this.output.write(gt.cursor.move(0,s)),this.output.write(gt.erase.lines(1));let r=t.split(`
|
|
19
19
|
`);this.output.write(r[s]),this._prevFrame=t,this.output.write(gt.cursor.move(0,r.length-s-1));return}else if(e&&(e==null?void 0:e.length)>1){let s=e[0];this.output.write(gt.cursor.move(0,s)),this.output.write(gt.erase.down());let r=t.split(`
|
|
20
20
|
`).slice(s);this.output.write(r.join(`
|
|
21
|
-
`)),this._prevFrame=t;return}this.output.write(gt.erase.down())}this.output.write(t),this.state==="initial"&&(this.state="active"),this._prevFrame=t}}},
|
|
21
|
+
`)),this._prevFrame=t;return}this.output.write(gt.erase.down())}this.output.write(t),this.state==="initial"&&(this.state="active"),this._prevFrame=t}}},Qe=class extends Te{get cursor(){return this.value?0:1}get _value(){return this.cursor===0}constructor(t){super(t,!1),this.value=!!t.initialValue,this.on("value",()=>{this.value=this._value}),this.on("confirm",e=>{this.output.write(gt.cursor.move(0,-1)),this.value=e,this.state="submit",this.close()}),this.on("cursor",()=>{this.value=!this.value})}};var Ze=class extends Te{constructor(t){super(t,!1),this.cursor=0,this.options=t.options,this.cursor=this.options.findIndex(({value:e})=>e===t.initialValue),this.cursor===-1&&(this.cursor=0),this.changeValue(),this.on("cursor",e=>{switch(e){case"left":case"up":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;break}this.changeValue()})}get _value(){return this.options[this.cursor]}changeValue(){this.value=this._value.value}};var Xe=class extends Te{constructor(t){super(t),this.valueWithCursor="",this.on("finalize",()=>{this.value||(this.value=t.defaultValue),this.valueWithCursor=this.value}),this.on("value",()=>{if(this.cursor>=this.value.length)this.valueWithCursor=`${this.value}${Ke.default.inverse(Ke.default.hidden("_"))}`;else{let e=this.value.slice(0,this.cursor),s=this.value.slice(this.cursor);this.valueWithCursor=`${e}${Ke.default.inverse(s[0])}${s.slice(1)}`}})}get cursor(){return this._cursor}};function Fi({input:n=Ee.stdin,output:t=Ee.stdout,overwrite:e=!0,hideCursor:s=!0}={}){let r=Ht.createInterface({input:n,output:t,prompt:"",tabSize:1});Ht.emitKeypressEvents(n,r),n.isTTY&&n.setRawMode(!0);let o=(i,{name:a})=>{if(String(i)===""&&process.exit(0),!e)return;Ht.moveCursor(t,a==="return"?0:-1,a==="return"?-1:0,()=>{Ht.clearLine(t,1,()=>{n.once("keypress",o)})})};return s&&process.stdout.write(gt.cursor.hide),n.once("keypress",o),()=>{n.off("keypress",o),s&&process.stdout.write(gt.cursor.show),n.isTTY&&n.setRawMode(!1),r.terminal=!1,r.close()}}var xt=ut(require("process"),1),w=ut(Vn(),1),be=ut(Hn(),1);function yu(){return xt.default.platform!=="win32"?xt.default.env.TERM!=="linux":!!xt.default.env.CI||!!xt.default.env.WT_SESSION||!!xt.default.env.TERMINUS_SUBLIME||xt.default.env.ConEmuTask==="{cmd::Cmder}"||xt.default.env.TERM_PROGRAM==="Terminus-Sublime"||xt.default.env.TERM_PROGRAM==="vscode"||xt.default.env.TERM==="xterm-256color"||xt.default.env.TERM==="alacritty"||xt.default.env.TERMINAL_EMULATOR==="JetBrains-JediTerm"}var Xn=yu(),at=(n,t)=>Xn?n:t,wu=at("\u25C6","*"),Ei=at("\u25A0","x"),bi=at("\u25B2","x"),ns=at("\u25C7","o"),Au=at("\u250C","T"),it=at("\u2502","|"),ye=at("\u2514","\u2014"),ts=at("\u25CF",">"),es=at("\u25CB"," "),hc=at("\u25FB","[\u2022]"),fc=at("\u25FC","[+]"),pc=at("\u25FB","[ ]"),dc=at("\u25AA","\u2022"),mc=at("\u2500","-"),gc=at("\u256E","+"),Cc=at("\u251C","+"),Fc=at("\u256F","+"),$u=at("\u25CF","\u2022"),xu=at("\u25C6","*"),Bu=at("\u25B2","!"),vu=at("\u25A0","x"),ss=n=>{switch(n){case"initial":case"active":return w.default.cyan(wu);case"cancel":return w.default.red(Ei);case"error":return w.default.yellow(bi);case"submit":return w.default.green(ns)}},yi=n=>new Xe({validate:n.validate,placeholder:n.placeholder,defaultValue:n.defaultValue,initialValue:n.initialValue,render(){var r;let t=`${w.default.gray(it)}
|
|
22
22
|
${ss(this.state)} ${n.message}
|
|
23
|
-
`,e=n.placeholder
|
|
24
|
-
${
|
|
25
|
-
${
|
|
26
|
-
`;case"submit":return`${t}${
|
|
27
|
-
|
|
28
|
-
${
|
|
29
|
-
`}}}).prompt();var
|
|
23
|
+
`,e=n.placeholder?w.default.inverse(n.placeholder[0])+w.default.dim(n.placeholder.slice(1)):w.default.inverse(w.default.hidden("_")),s=this.value?this.valueWithCursor:e;switch(this.state){case"error":return`${t.trim()}
|
|
24
|
+
${w.default.yellow(it)} ${s}
|
|
25
|
+
${w.default.yellow(ye)} ${w.default.yellow(this.error)}
|
|
26
|
+
`;case"submit":return`${t}${w.default.gray(it)} ${w.default.dim(this.value||n.placeholder)}`;case"cancel":return`${t}${w.default.gray(it)} ${w.default.strikethrough(w.default.dim(this.value??""))}${(r=this.value)!=null&&r.trim()?`
|
|
27
|
+
`+w.default.gray(it):""}`;default:return`${t}${w.default.cyan(it)} ${s}
|
|
28
|
+
${w.default.cyan(ye)}
|
|
29
|
+
`}}}).prompt();var en=n=>{let t=n.active??"Yes",e=n.inactive??"No";return new Qe({active:t,inactive:e,initialValue:n.initialValue??!0,render(){let s=`${w.default.gray(it)}
|
|
30
30
|
${ss(this.state)} ${n.message}
|
|
31
|
-
`,r=this.value?t:e;switch(this.state){case"submit":return`${s}${
|
|
32
|
-
${
|
|
33
|
-
${
|
|
34
|
-
`}}}).prompt()},is=n=>{let t=(
|
|
31
|
+
`,r=this.value?t:e;switch(this.state){case"submit":return`${s}${w.default.gray(it)} ${w.default.dim(r)}`;case"cancel":return`${s}${w.default.gray(it)} ${w.default.strikethrough(w.default.dim(r))}
|
|
32
|
+
${w.default.gray(it)}`;default:return`${s}${w.default.cyan(it)} ${this.value?`${w.default.green(ts)} ${t}`:`${w.default.dim(es)} ${w.default.dim(t)}`} ${w.default.dim("/")} ${this.value?`${w.default.dim(es)} ${w.default.dim(e)}`:`${w.default.green(ts)} ${e}`}
|
|
33
|
+
${w.default.cyan(ye)}
|
|
34
|
+
`}}}).prompt()},is=n=>{let t=(s,r)=>{let o=s.label??String(s.value);return r==="active"?`${w.default.green(ts)} ${o} ${s.hint?w.default.dim(`(${s.hint})`):""}`:r==="selected"?`${w.default.dim(o)}`:r==="cancelled"?`${w.default.strikethrough(w.default.dim(o))}`:`${w.default.dim(es)} ${w.default.dim(o)}`},e=0;return new Ze({options:n.options,initialValue:n.initialValue,render(){let s=`${w.default.gray(it)}
|
|
35
35
|
${ss(this.state)} ${n.message}
|
|
36
|
-
`;switch(this.state){case"submit":return`${
|
|
37
|
-
${
|
|
38
|
-
${
|
|
39
|
-
${
|
|
40
|
-
`}}}).prompt()};var se=(n="")=>{process.stdout.write(`${
|
|
41
|
-
|
|
42
|
-
`)},
|
|
43
|
-
`)},rs=(n="")=>{process.stdout.write(`${
|
|
44
|
-
${
|
|
45
|
-
|
|
46
|
-
`)},
|
|
47
|
-
`);e.push(`${t} ${s}`,...r.map(o=>`${
|
|
36
|
+
`;switch(this.state){case"submit":return`${s}${w.default.gray(it)} ${t(this.options[this.cursor],"selected")}`;case"cancel":return`${s}${w.default.gray(it)} ${t(this.options[this.cursor],"cancelled")}
|
|
37
|
+
${w.default.gray(it)}`;default:{let r=n.maxItems===void 0?1/0:Math.max(n.maxItems,5);this.cursor>=e+r-3?e=Math.max(Math.min(this.cursor-r+3,this.options.length-r),0):this.cursor<e+2&&(e=Math.max(this.cursor-2,0));let o=r<this.options.length&&e>0,i=r<this.options.length&&e+r<this.options.length;return`${s}${w.default.cyan(it)} ${this.options.slice(e,e+r).map((a,c,h)=>c===0&&o?w.default.dim("..."):c===h.length-1&&i?w.default.dim("..."):t(a,c+e===this.cursor?"active":"inactive")).join(`
|
|
38
|
+
${w.default.cyan(it)} `)}
|
|
39
|
+
${w.default.cyan(ye)}
|
|
40
|
+
`}}}}).prompt()};var se=(n="")=>{process.stdout.write(`${w.default.gray(ye)} ${w.default.red(n)}
|
|
41
|
+
|
|
42
|
+
`)},nn=(n="")=>{process.stdout.write(`${w.default.gray(Au)} ${n}
|
|
43
|
+
`)},rs=(n="")=>{process.stdout.write(`${w.default.gray(it)}
|
|
44
|
+
${w.default.gray(ye)} ${n}
|
|
45
|
+
|
|
46
|
+
`)},et={message:(n="",{symbol:t=w.default.gray(it)}={})=>{let e=[`${w.default.gray(it)}`];if(n){let[s,...r]=n.split(`
|
|
47
|
+
`);e.push(`${t} ${s}`,...r.map(o=>`${w.default.gray(it)} ${o}`))}process.stdout.write(`${e.join(`
|
|
48
48
|
`)}
|
|
49
|
-
`)},info:n=>{
|
|
50
|
-
|
|
51
|
-
`)
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
`):
|
|
57
|
-
|
|
58
|
-
`)
|
|
59
|
-
`)}function xr(n){return new Promise(t=>setTimeout(t,n))}function Br(n){n={...n};let t={name:n.name,version:n.version,description:n.description,scripts:n.scripts,dependencies:n.dependencies,devDependencies:n.devDependencies,main:n.main,qwik:n.qwik,module:n.module,types:n.types,exports:n.exports,files:n.files,engines:{node:">=15.0.0"}};Object.keys(t).forEach(s=>{delete n[s]}),delete n.__qwik__;let e=Object.keys(n).sort();for(let s of e)t[s]=n[s];return t}function vr(n){return n.toLocaleLowerCase().split("-").map(t=>t.charAt(0).toUpperCase()+t.slice(1)).join(" ")}function Yt(){var n;return((n=(0,wr.default)())==null?void 0:n.name)||"npm"}function on(n){console.error(`
|
|
60
|
-
\u274C ${bt(n)}
|
|
61
|
-
`),process.exit(1)}function Or(){console.log(vi(`
|
|
49
|
+
`)},info:n=>{et.message(n,{symbol:w.default.blue($u)})},success:n=>{et.message(n,{symbol:w.default.green(xu)})},step:n=>{et.message(n,{symbol:w.default.green(ns)})},warn:n=>{et.message(n,{symbol:w.default.yellow(Bu)})},warning:n=>{et.warn(n)},error:n=>{et.message(n,{symbol:w.default.red(vu)})}},we=()=>{let n=Xn?["\u25D2","\u25D0","\u25D3","\u25D1"]:["\u2022","o","O","0"],t=Xn?80:120,e,s,r=!1,o="",i=(f="")=>{r=!0,e=Fi(),o=f.replace(/\.+$/,""),process.stdout.write(`${w.default.gray(it)}
|
|
50
|
+
`);let l=0,m=0;s=setInterval(()=>{let C=w.default.magenta(n[l]),E=".".repeat(Math.floor(m)).slice(0,3);process.stdout.write(be.cursor.move(-999,0)),process.stdout.write(be.erase.down(1)),process.stdout.write(`${C} ${o}${E}`),l=l+1<n.length?l+1:0,m=m<n.length?m+.125:0},t)},a=(f="",l=0)=>{o=f??o,r=!1,clearInterval(s);let m=l===0?w.default.green(ns):l===1?w.default.red(Ei):w.default.red(bi);process.stdout.write(be.cursor.move(-999,0)),process.stdout.write(be.erase.down(1)),process.stdout.write(`${m} ${o}
|
|
51
|
+
`),e()},c=(f="")=>{o=f??o},h=f=>{let l=f>1?"Something went wrong":"Canceled";r&&a(l,f)};return process.on("uncaughtExceptionMonitor",()=>h(2)),process.on("unhandledRejection",()=>h(2)),process.on("SIGINT",()=>h(1)),process.on("SIGTERM",()=>h(1)),process.on("exit",h),{start:i,stop:a,message:c}};var os,wi,Ai,$i,xi=!0;typeof process<"u"&&({FORCE_COLOR:os,NODE_DISABLE_COLORS:wi,NO_COLOR:Ai,TERM:$i}=process.env||{},xi=process.stdout&&process.stdout.isTTY);var Ou={enabled:!wi&&Ai==null&&$i!=="dumb"&&(os!=null&&os!=="0"||xi)};function G(n,t){let e=new RegExp(`\\x1b\\[${t}m`,"g"),s=`\x1B[${n}m`,r=`\x1B[${t}m`;return function(o){return!Ou.enabled||o==null?o:s+(~(""+o).indexOf(r)?o.replace(e,r+s):o)+r}}var Bi=G(0,0),vi=G(1,22),yc=G(2,22),wc=G(3,23),Ac=G(4,24),$c=G(7,27),xc=G(8,28),Bc=G(9,29),vc=G(30,39),Et=G(31,39),Oi=G(32,39),_i=G(33,39),ji=G(34,39),Ct=G(35,39),bt=G(36,39),Si=G(37,39),Vt=G(90,39),Oc=G(90,39),_c=G(40,49),sn=G(41,49),jc=G(42,49),Sc=G(43,49),Ne=G(44,49),us=G(45,49),Ic=G(46,49),Mc=G(47,49);var as=ut(require("fs")),Ii=require("path"),rn=async n=>{let t=await as.default.promises.readdir(n);return await Promise.all(t.map(e=>as.default.promises.rm((0,Ii.join)(n,e),{recursive:!0})))};var fn=ut(require("fs")),pn=require("path");var $r=ut(Pi(),1),Es=ut(require("fs"),1),bs=require("path"),xr=ut(wr(),1);function xe(n,t,e){let s,r=new Promise(i=>{try{s=(0,xr.default)(n,t,{cwd:e,stdio:"ignore"}),s.on("error",a=>{a&&(a.message?et.error(Et(String(a.message))+`
|
|
52
|
+
|
|
53
|
+
`):et.error(Et(String(a))+`
|
|
54
|
+
|
|
55
|
+
`)),i(!1)}),s.on("close",a=>{i(a===0)})}catch{i(!1)}});return{abort:async()=>{s&&s.kill("SIGINT")},install:r}}async function Br(n){let t=(0,bs.join)(n,"package.json");return JSON.parse(await Es.default.promises.readFile(t,"utf-8"))}async function vr(n,t){let e=(0,bs.join)(n,"package.json");await Es.default.promises.writeFile(e,JSON.stringify(t,null,2)+`
|
|
56
|
+
`)}function Or(n){return new Promise(t=>setTimeout(t,n))}function _r(n){n={...n};let t={name:n.name,version:n.version,description:n.description,scripts:n.scripts,dependencies:n.dependencies,devDependencies:n.devDependencies,main:n.main,qwik:n.qwik,module:n.module,types:n.types,exports:n.exports,files:n.files,engines:{node:">=15.0.0"}};Object.keys(t).forEach(s=>{delete n[s]}),delete n.__qwik__;let e=Object.keys(n).sort();for(let s of e)t[s]=n[s];return t}function jr(n){return n.toLocaleLowerCase().split("-").map(t=>t.charAt(0).toUpperCase()+t.slice(1)).join(" ")}function Gt(){var n;return((n=(0,$r.default)())==null?void 0:n.name)||"npm"}function un(n){console.error(`
|
|
57
|
+
\u274C ${Et(n)}
|
|
58
|
+
`),process.exit(1)}function Sr(){console.log(ji(`
|
|
62
59
|
${Ct("............")}
|
|
63
60
|
.::: ${Ct(":--------:.")}
|
|
64
61
|
.:::: ${Ct(".:-------:.")}
|
|
@@ -72,44 +69,44 @@ ${$.default.green(ns)} ${s}
|
|
|
72
69
|
..::::::::::::
|
|
73
70
|
...::::
|
|
74
71
|
`),`
|
|
75
|
-
`)}function
|
|
72
|
+
`)}function Ir(){return process.platform!=="win32"?process.env.TERM!=="linux":!!process.env.CI||!!process.env.WT_SESSION||!!process.env.TERMINUS_SUBLIME||process.env.ConEmuTask==="{cmd::Cmder}"||process.env.TERM_PROGRAM==="Terminus-Sublime"||process.env.TERM_PROGRAM==="vscode"||process.env.TERM==="xterm-256color"||process.env.TERM==="alacritty"||process.env.TERMINAL_EMULATOR==="JetBrains-JediTerm"}var sa=Ir(),Be=(n,t)=>sa?n:t,Cs=Be("\u2502","|"),Ar=Be("\u2500","-"),ia=Be("\u256E","+"),ra=Be("\u251C","+"),oa=Be("\u256F","+"),ua=Be("\u25C7","o");function aa(){let n=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]))"].join("|");return new RegExp(n,"g")}var Fs=n=>n.replace(aa(),""),an=(n="",t="")=>{let e=`
|
|
76
73
|
${n}
|
|
77
74
|
`.split(`
|
|
78
|
-
`),s=e.reduce((
|
|
75
|
+
`),s=Fs(t).length,r=Math.max(e.reduce((i,a)=>(a=Fs(a),a.length>i?a.length:i),0),s)+2,o=e.map(i=>`${Vt(Cs)} ${Si(i)}${" ".repeat(r-Fs(i).length)}${Vt(Cs)}`).join(`
|
|
79
76
|
`);process.stdout.write(`${Vt(Cs)}
|
|
80
|
-
${
|
|
81
|
-
${
|
|
82
|
-
${Vt(
|
|
83
|
-
`)};var
|
|
77
|
+
${Oi(ua)} ${Bi(t)} ${Vt(Ar.repeat(Math.max(r-s-1,1))+ia)}
|
|
78
|
+
${o}
|
|
79
|
+
${Vt(ra+Ar.repeat(r+2)+oa)}
|
|
80
|
+
`)};var Wr=require("path"),As=ut(require("fs"),1);var cn=ut(require("fs"),1),ln=require("path");var ys=null;async function Dn(){if(!ys){let n=[],t=["app","feature","adapter"],e=(0,ln.join)(__dirname,"starters"),s=await cn.default.promises.readdir(e);await Promise.all(s.map(async r=>{let o=r.slice(0,r.length-1);if(t.includes(o)){let i=(0,ln.join)(e,r),a=await cn.default.promises.readdir(i);await Promise.all(a.map(async c=>{var l,m,C;let h=(0,ln.join)(i,c);if((await cn.default.promises.stat(h)).isDirectory()){let E=await Br(h),b={id:c,name:((l=E.__qwik__)==null?void 0:l.displayName)??jr(c),type:o,dir:h,pkgJson:E,docs:((m=E.__qwik__)==null?void 0:m.docs)??[],priority:((C=E==null?void 0:E.__qwik__)==null?void 0:C.priority)??0};n.push(b)}}))}})),n.sort((r,o)=>r.priority>o.priority?-1:r.priority<o.priority?1:r.id<o.id?-1:1),ys=n}return ys}var ie=ut(require("fs"),1),Mr=ut(require("os"),1),Bt=ut(require("path"),1);function re(n,t){return xe(n,["install"],t)}function Pr(n,t){let{tmpInstallDir:e}=ca(t),{install:s,abort:r}=re(n,e);return{abort:r,complete:async i=>{let a=!1;try{if(await s){let h=Bt.default.join(e,"node_modules"),f=Bt.default.join(i,"node_modules");await ie.default.promises.rename(h,f);try{await ie.default.promises.rename(Bt.default.join(e,"package-lock.json"),Bt.default.join(i,"package-lock.json"))}catch{}try{await ie.default.promises.rename(Bt.default.join(e,"yarn.lock"),Bt.default.join(i,"yarn.lock"))}catch{}try{await ie.default.promises.rename(Bt.default.join(e,"pnpm-lock.yaml"),Bt.default.join(i,"pnpm-lock.yaml"))}catch{}a=!0}}catch(c){c&&(c.message?et.error(Et(String(c.message))+`
|
|
84
81
|
|
|
85
|
-
`):
|
|
82
|
+
`):et.error(Et(String(c))+`
|
|
86
83
|
|
|
87
|
-
`))}if(!a){let
|
|
88
|
-
You might need to run ${
|
|
84
|
+
`))}if(!a){let c=`${sn(` ${n} install failed `)}
|
|
85
|
+
You might need to run ${bt(`"${n} install"`)} manually inside the root of the project.
|
|
89
86
|
|
|
90
|
-
`;
|
|
91
|
-
`,type:"modify"})}catch{n.files.push({path:e,content:s,type:"create"})}}async function
|
|
92
|
-
`,type:"modify"})}catch{n.files.push({path:e,content:s,type:"create"})}}function
|
|
87
|
+
`;et.error(c)}return a}}}function ca(n){let t="create-qwik-"+Math.round(Math.random()*Number.MAX_SAFE_INTEGER).toString(36).toLowerCase(),e=Bt.default.join(Mr.default.tmpdir(),t);try{ie.default.mkdirSync(e)}catch(o){et.error(`\u274C ${Et(String(o))}`)}let s=Bt.default.join(n.dir,"package.json"),r=Bt.default.join(e,"package.json");return ie.default.copyFileSync(s,r),{tmpInstallDir:e}}var dt=ut(require("fs"),1),Re=require("path");async function ws(n,t,e,s){let r=await dt.default.promises.readdir(e);await Promise.all(r.map(async o=>{let i=o==="gitignore"?".gitignore":o,a=(0,Re.extname)(i),c=(0,Re.join)(e,o),h=(0,Re.join)(s,i),f=await dt.default.promises.stat(c);f.isDirectory()?await ws(n,t,c,h):f.isFile()&&(i==="package.json"?await la(n,c,h):i==="settings.json"?await Da(n,c,h):i==="README.md"?await fa(n,c,h):i===".gitignore"||i===".prettierignore"||i===".eslintignore"?await pa(n,c,h):a===".css"?await da(n,c,h):dt.default.existsSync(h)?n.files.push({path:h,content:await dt.default.promises.readFile(c),type:"overwrite"}):n.files.push({path:h,content:await dt.default.promises.readFile(c),type:"create"}))}))}async function la(n,t,e){var r;let s=await dt.default.promises.readFile(t,"utf-8");try{let o=JSON.parse(s),i=["scripts","dependencies","devDependencies"],a=JSON.parse(await dt.default.promises.readFile(e,"utf-8"));if(i.forEach(c=>{ha(o,a,c)}),(r=a.scripts)!=null&&r.qwik){let c=a.scripts.qwik;delete a.scripts.qwik,a.scripts.qwik=c}n.files.push({path:e,content:JSON.stringify(a,null,2)+`
|
|
88
|
+
`,type:"modify"})}catch{n.files.push({path:e,content:s,type:"create"})}}async function Da(n,t,e){let s=await dt.default.promises.readFile(t,"utf-8");try{let r=JSON.parse(s),o=JSON.parse(await dt.default.promises.readFile(e,"utf-8"));Object.assign(r,o),n.files.push({path:e,content:JSON.stringify(r,null,2)+`
|
|
89
|
+
`,type:"modify"})}catch{n.files.push({path:e,content:s,type:"create"})}}function ha(n,t,e){if(n[e]){t[e]?Object.assign(t[e],{...n[e]}):t[e]={...n[e]};let s={},r=Object.keys(t[e]).sort();for(let o of r)s[o]=t[e][o];t[e]=s}}async function fa(n,t,e){let s=await dt.default.promises.readFile(t,"utf-8"),r,o="";try{o=await dt.default.promises.readFile(e,"utf-8"),o=o.trim()+`
|
|
93
90
|
|
|
94
|
-
`+s,r="modify"}catch{o=s,r="create"}let i=
|
|
95
|
-
`,type:r})}async function
|
|
91
|
+
`+s,r="modify"}catch{o=s,r="create"}let i=Gt();i!=="npm"&&(o=o.replace(/npm run/g,i)),n.files.push({path:e,content:o.trim()+`
|
|
92
|
+
`,type:r})}async function pa(n,t,e){let s=await dt.default.promises.readFile(t,"utf-8");try{let r=await dt.default.promises.readFile(e,"utf-8"),o=s.trim().split(/\r?\n/),i=r.trim().split(/\r?\n/);for(let a of o)i.includes(a)||(a.startsWith("#")&&i.push(""),i.push(a));n.files.push({path:e,content:i.join(`
|
|
96
93
|
`).trim()+`
|
|
97
|
-
`,type:"modify"})}catch{n.files.push({path:e,content:s,type:"create"})}}async function
|
|
94
|
+
`,type:"modify"})}catch{n.files.push({path:e,content:s,type:"create"})}}async function da(n,t,e){let s=await dt.default.promises.readFile(t,"utf-8");try{let r=await dt.default.promises.readFile(e,"utf-8"),o=s.trim()+`
|
|
98
95
|
|
|
99
96
|
`+r.trim()+`
|
|
100
|
-
`;n.files.push({path:e,content:o,type:"modify"})}catch{n.files.push({path:e,content:s,type:"create"})}}async function
|
|
101
|
-
You might need to run "${
|
|
102
|
-
`)}var
|
|
103
|
-
`),"Result"),rs("Happy coding! \u{1F389}")}var
|
|
97
|
+
`;n.files.push({path:e,content:o,type:"modify"})}catch{n.files.push({path:e,content:s,type:"create"})}}async function $s(n,t){let s=(await Dn()).find(a=>a.id===t.integration);if(!s)throw new Error(`Unable to find integration "${t.integration}"`);let r={files:[],installedDeps:{},installedScripts:Object.keys(s.pkgJson.scripts||{})};t.installDeps&&(r.installedDeps={...s.pkgJson.dependencies,...s.pkgJson.devDependencies}),await ws(r,t,s.dir,t.rootDir);let o=async a=>{let c=Object.keys(r.installedDeps).length>0,h=we();a&&h.start(`Updating app${c?" and installing dependencies":""}...`);let f=!0;try{let l=new Set(r.files.map(C=>(0,Wr.dirname)(C.path)));for(let C of Array.from(l))try{As.default.mkdirSync(C,{recursive:!0})}catch{}let m=Promise.all(r.files.map(async C=>{await As.default.promises.writeFile(C.path,C.content)}));if(t.installDeps&&Object.keys(r.installedDeps).length>0){let{install:C}=re(n,t.rootDir);f=await C}if(await m,a&&h.stop("App updated"),!f){let C=`${sn(` ${n} install failed `)}
|
|
98
|
+
You might need to run "${bt(`${n} install`)}" manually inside the root of the project.`;et.error(C)}}catch(l){a&&h.stop("App updated"),un(String(l))}};return{rootDir:t.rootDir,integration:s,updates:r,commit:o}}var xs,ma="library",hn="base",Le=class extends Error{constructor(t,e){super(),this.message=`Invalid app id "${t}". It can only be one of${e.map(s=>` "${s.id}"`)}.`}},ve=async n=>{xs||(xs=await Dn());let t=xs.filter(i=>i.type===n),e=t.filter(i=>i.id!==hn);function s(i,a=!0){return a?e.find(c=>c.id===i):t.find(c=>c.id===i)}function r(){return s(hn,!1)}function o(i){if(i===ma){let f=s(i);if(!f)throw new Le(i,e);return{baseApp:f}}let c=s(hn,!1),h=s(i);if(!c)throw new Le(hn,e);if(!h)throw new Le(i,e);return{baseApp:c,starterApp:h}}return{templates:t,standaloneTemplates:e,getAppById:s,getBootstrapApps:o,getBaseApp:r}};function ga(n){return typeof n=="string"&&n.trim().length>0}function Ca(n){if(!ga(n.outDir))throw new Error("Missing outDir");if(!(0,pn.isAbsolute)(n.outDir))throw new Error("outDir must be an absolute path")}async function Oe(n){let{appId:t,outDir:e,pkgManager:s,templateManager:r}=n,{baseApp:o,starterApp:i}=r.getBootstrapApps(t);Ca(n),fn.default.existsSync(e)||fn.default.mkdirSync(decodeURIComponent(e),{recursive:!0});let a=await Fa({baseApp:o,starterApp:i,pkgManager:s,outDir:e});return{starterId:n.appId,outDir:e,pkgManager:s,docs:a}}async function Fa({baseApp:n,starterApp:t,outDir:e,pkgManager:s}){let r=[...n.docs],o=t??n,i=_r({...n.pkgJson,name:`my-${o.pkgJson.name}`,description:o.pkgJson.description,scripts:void 0,dependencies:void 0,devDependencies:void 0});await vr(e,i);let a=(0,pn.join)(e,"README.md");return await fn.default.promises.writeFile(a,""),await(await $s(s,{rootDir:e,integration:n.id,installDeps:!1})).commit(!1),t&&(r.push(...t.docs),await(await $s(s,{rootDir:e,integration:t.id,installDeps:!1})).commit(!1)),r}var Xs=ut(require("fs"));async function dn(n,{pkgManager:t,spinner:e}){e.start(`Installing ${t} dependencies...`);let s=await n();return e.stop(`${s?"Installed":"Failed to install"} ${t} dependencies \u{1F4CB}`),s}function kr(n){let t=[];return n.length>0&&(t.push(`\u{1F4C4} ${bt("Relevant docs:")}`),n.forEach(e=>{t.push(` ${e}`)})),t.push(""),t.push(`\u{1F4AC} ${bt("Questions? Start the conversation at:")}`),t.push(" https://qwik.builder.io/chat"),t.push(" https://twitter.com/QwikDev"),t.push(""),t.join(`
|
|
99
|
+
`)}var Tr=require("path");function mn(n,t,e){let s=process.cwd()===t.outDir,r=(0,Tr.relative)(process.cwd(),t.outDir),o=[];s?o.push(`\u{1F984} ${us(" Success! ")}`):o.push(`\u{1F984} ${us(" Success! ")} ${bt("Project created in")} ${vi(Ct(r))} ${bt("directory")}`),o.push("");let i=n!=="npm"?`${n} qwik add`:"npm run qwik add";o.push(`\u{1F90D} ${bt("Integrations? Add Netlify, Cloudflare, Tailwind...")}`),o.push(` ${i}`),o.push(""),o.push(kr(t.docs)),o.push(`\u{1F440} ${bt("Presentations, Podcasts and Videos:")}`),o.push(" https://qwik.builder.io/media/"),o.push(""),o.push(`\u{1F430} ${bt("Next steps:")}`),s||o.push(` cd ${r}`),e||o.push(` ${n} install`),o.push(` ${n} start`),o.push(""),an(o.join(`
|
|
100
|
+
`),"Result"),rs("Happy coding! \u{1F389}")}var Bs=require("path"),Nr=ut(require("os"));function gn(n){return n.startsWith("~/")?(0,Bs.resolve)(Nr.default.homedir(),n):(0,Bs.resolve)(process.cwd(),n)}var $n=require("assert");var Ea={right:$a,center:xa},ba=0,Cn=1,ya=2,Fn=3,vs=class{constructor(t){var e;this.width=t.width,this.wrap=(e=t.wrap)!==null&&e!==void 0?e:!0,this.rows=[]}span(...t){let e=this.div(...t);e.span=!0}resetOutput(){this.rows=[]}div(...t){if(t.length===0&&this.div(""),this.wrap&&this.shouldApplyLayoutDSL(...t)&&typeof t[0]=="string")return this.applyLayoutDSL(t[0]);let e=t.map(s=>typeof s=="string"?this.colFromString(s):s);return this.rows.push(e),e}shouldApplyLayoutDSL(...t){return t.length===1&&typeof t[0]=="string"&&/[\t\n]/.test(t[0])}applyLayoutDSL(t){let e=t.split(`
|
|
104
101
|
`).map(r=>r.split(" ")),s=0;return e.forEach(r=>{r.length>1&&yt.stringWidth(r[0])>s&&(s=Math.min(Math.floor(this.width*.5),yt.stringWidth(r[0])))}),e.forEach(r=>{this.div(...r.map((o,i)=>({text:o.trim(),padding:this.measurePadding(o),width:i===0&&r.length>1?s:void 0})))}),this.rows[this.rows.length-1]}colFromString(t){return{text:t,padding:this.measurePadding(t)}}measurePadding(t){let e=yt.stripAnsi(t);return[0,e.match(/\s*$/)[0].length,0,e.match(/^\s*/)[0].length]}toString(){let t=[];return this.rows.forEach(e=>{this.rowToString(e,t)}),t.filter(e=>!e.hidden).map(e=>e.text).join(`
|
|
105
|
-
`)}rowToString(t,e){return this.rasterize(t).forEach((s,r)=>{let o="";s.forEach((i,a)=>{let{width:
|
|
102
|
+
`)}rowToString(t,e){return this.rasterize(t).forEach((s,r)=>{let o="";s.forEach((i,a)=>{let{width:c}=t[a],h=this.negatePadding(t[a]),f=i;if(h>yt.stringWidth(i)&&(f+=" ".repeat(h-yt.stringWidth(i))),t[a].align&&t[a].align!=="left"&&this.wrap){let m=Ea[t[a].align];f=m(f,h),yt.stringWidth(f)<h&&(f+=" ".repeat((c||0)-yt.stringWidth(f)-1))}let l=t[a].padding||[0,0,0,0];l[Fn]&&(o+=" ".repeat(l[Fn])),o+=Rr(t[a],f,"| "),o+=f,o+=Rr(t[a],f," |"),l[Cn]&&(o+=" ".repeat(l[Cn])),r===0&&e.length>0&&(o=this.renderInline(o,e[e.length-1]))}),e.push({text:o.replace(/ +$/,""),span:t.span})}),e}renderInline(t,e){let s=t.match(/^ */),r=s?s[0].length:0,o=e.text,i=yt.stringWidth(o.trimRight());return e.span?this.wrap?r<i?t:(e.hidden=!0,o.trimRight()+" ".repeat(r-i)+t.trimLeft()):(e.hidden=!0,o+t):t}rasterize(t){let e=[],s=this.columnWidths(t),r;return t.forEach((o,i)=>{o.width=s[i],this.wrap?r=yt.wrap(o.text,this.negatePadding(o),{hard:!0}).split(`
|
|
106
103
|
`):r=o.text.split(`
|
|
107
|
-
`),o.border&&(r.unshift("."+"-".repeat(this.negatePadding(o)+2)+"."),r.push("'"+"-".repeat(this.negatePadding(o)+2)+"'")),o.padding&&(r.unshift(...new Array(o.padding[
|
|
108
|
-
`),r+=n.charAt(o);return e&&s&&(r=`${e}${r}${s}`),r}function Os(n){return kr(n,{stringWidth:t=>[...t].length,stripAnsi:vs,wrap:Nr})}var ve=require("path"),Fn=require("fs");function Rr(n,t){let e=(0,ve.resolve)(".",n),s;for((0,Fn.statSync)(e).isDirectory()||(e=(0,ve.dirname)(e));;){if(s=t(e,(0,Fn.readdirSync)(e)),s)return(0,ve.resolve)(e,s);if(e=(0,ve.dirname)(s=e),s===e)break}}var no=require("util"),so=require("fs"),io=require("url");var Ur=require("util"),wn=require("path");function oe(n){if(n!==n.toLowerCase()&&n!==n.toUpperCase()||(n=n.toLowerCase()),n.indexOf("-")===-1&&n.indexOf("_")===-1)return n;{let e="",s=!1,r=n.match(/^-+/);for(let o=r?r[0].length:0;o<n.length;o++){let i=n.charAt(o);s&&(s=!1,i=i.toUpperCase()),o!==0&&(i==="-"||i==="_")?s=!0:i!=="-"&&i!=="_"&&(e+=i)}return e}}function bn(n,t){let e=n.toLowerCase();t=t||"-";let s="";for(let r=0;r<n.length;r++){let o=e.charAt(r),i=n.charAt(r);o!==i&&r>0?s+=`${t}${e.charAt(r)}`:s+=i}return s}function En(n){return n==null?!1:typeof n=="number"||/^0x[0-9a-f]+$/i.test(n)?!0:/^0[^.]/.test(n)?!1:/^[-]?(?:\d+(?:\.\d*)?|\.\d+)(e[-+]?\d+)?$/.test(n)}function Lr(n){if(Array.isArray(n))return n.map(i=>typeof i!="string"?i+"":i);n=n.trim();let t=0,e=null,s=null,r=null,o=[];for(let i=0;i<n.length;i++){if(e=s,s=n.charAt(i),s===" "&&!r){e!==" "&&t++;continue}s===r?r=null:(s==="'"||s==='"')&&!r&&(r=s),o[t]||(o[t]=""),o[t]+=s}return o}var vt;(function(n){n.BOOLEAN="boolean",n.STRING="string",n.NUMBER="number",n.ARRAY="array"})(vt||(vt={}));var zt,yn=class{constructor(t){zt=t}parse(t,e){let s=Object.assign({alias:void 0,array:void 0,boolean:void 0,config:void 0,configObjects:void 0,configuration:void 0,coerce:void 0,count:void 0,default:void 0,envPrefix:void 0,narg:void 0,normalize:void 0,string:void 0,number:void 0,__:void 0,key:void 0},e),r=Lr(t),o=typeof t=="string",i=ba(Object.assign(Object.create(null),s.alias)),a=Object.assign({"boolean-negation":!0,"camel-case-expansion":!0,"combine-arrays":!1,"dot-notation":!0,"duplicate-arguments-array":!0,"flatten-duplicate-arrays":!0,"greedy-arrays":!0,"halt-at-non-option":!1,"nargs-eats-options":!1,"negation-prefix":"no-","parse-numbers":!0,"parse-positional-numbers":!0,"populate--":!1,"set-placeholder-key":!1,"short-option-groups":!0,"strip-aliased":!1,"strip-dashed":!1,"unknown-options-as-args":!1},s.configuration),l=Object.assign(Object.create(null),s.default),h=s.configObjects||[],f=s.envPrefix,D=a["populate--"],m=D?"--":"_",C=Object.create(null),E=Object.create(null),b=s.__||zt.format,g={aliases:Object.create(null),arrays:Object.create(null),bools:Object.create(null),strings:Object.create(null),numbers:Object.create(null),counts:Object.create(null),normalize:Object.create(null),configs:Object.create(null),nargs:Object.create(null),coercions:Object.create(null),keys:[]},O=/^-([0-9]+(\.[0-9]+)?|\.[0-9]+)$/,T=new RegExp("^--"+a["negation-prefix"]+"(.+)");[].concat(s.array||[]).filter(Boolean).forEach(function(c){let d=typeof c=="object"?c.key:c,y=Object.keys(c).map(function(F){return{boolean:"bools",string:"strings",number:"numbers"}[F]}).filter(Boolean).pop();y&&(g[y][d]=!0),g.arrays[d]=!0,g.keys.push(d)}),[].concat(s.boolean||[]).filter(Boolean).forEach(function(c){g.bools[c]=!0,g.keys.push(c)}),[].concat(s.string||[]).filter(Boolean).forEach(function(c){g.strings[c]=!0,g.keys.push(c)}),[].concat(s.number||[]).filter(Boolean).forEach(function(c){g.numbers[c]=!0,g.keys.push(c)}),[].concat(s.count||[]).filter(Boolean).forEach(function(c){g.counts[c]=!0,g.keys.push(c)}),[].concat(s.normalize||[]).filter(Boolean).forEach(function(c){g.normalize[c]=!0,g.keys.push(c)}),typeof s.narg=="object"&&Object.entries(s.narg).forEach(([c,d])=>{typeof d=="number"&&(g.nargs[c]=d,g.keys.push(c))}),typeof s.coerce=="object"&&Object.entries(s.coerce).forEach(([c,d])=>{typeof d=="function"&&(g.coercions[c]=d,g.keys.push(c))}),typeof s.config<"u"&&(Array.isArray(s.config)||typeof s.config=="string"?[].concat(s.config).filter(Boolean).forEach(function(c){g.configs[c]=!0}):typeof s.config=="object"&&Object.entries(s.config).forEach(([c,d])=>{(typeof d=="boolean"||typeof d=="function")&&(g.configs[c]=d)})),ne(s.key,i,s.default,g.arrays),Object.keys(l).forEach(function(c){(g.aliases[c]||[]).forEach(function(d){l[d]=l[c]})});let H=null;Ve();let L=[],U=Object.assign(Object.create(null),{_:[]}),qt={};for(let c=0;c<r.length;c++){let d=r[c],y=d.replace(/^-{3,}/,"---"),F,p,_,A,I,ht;if(d!=="--"&&/^-/.test(d)&&st(d))It(d);else if(y.match(/^---+(=|$)/)){It(d);continue}else if(d.match(/^--.+=/)||!a["short-option-groups"]&&d.match(/^-.+=/))A=d.match(/^--?([^=]+)=([\s\S]*)$/),A!==null&&Array.isArray(A)&&A.length>=3&&(M(A[1],g.arrays)?c=te(c,A[1],r,A[2]):M(A[1],g.nargs)!==!1?c=Fe(c,A[1],r,A[2]):V(A[1],A[2],!0));else if(d.match(T)&&a["boolean-negation"])A=d.match(T),A!==null&&Array.isArray(A)&&A.length>=2&&(p=A[1],V(p,M(p,g.arrays)?[!1]:!1));else if(d.match(/^--.+/)||!a["short-option-groups"]&&d.match(/^-[^-]+/))A=d.match(/^--?(.+)/),A!==null&&Array.isArray(A)&&A.length>=2&&(p=A[1],M(p,g.arrays)?c=te(c,p,r):M(p,g.nargs)!==!1?c=Fe(c,p,r):(I=r[c+1],I!==void 0&&(!I.match(/^-/)||I.match(O))&&!M(p,g.bools)&&!M(p,g.counts)||/^(true|false)$/.test(I)?(V(p,I),c++):V(p,it(p))));else if(d.match(/^-.\..+=/))A=d.match(/^-([^=]+)=([\s\S]*)$/),A!==null&&Array.isArray(A)&&A.length>=3&&V(A[1],A[2]);else if(d.match(/^-.\..+/)&&!d.match(O))I=r[c+1],A=d.match(/^-(.\..+)/),A!==null&&Array.isArray(A)&&A.length>=2&&(p=A[1],I!==void 0&&!I.match(/^-/)&&!M(p,g.bools)&&!M(p,g.counts)?(V(p,I),c++):V(p,it(p)));else if(d.match(/^-[^-]+/)&&!d.match(O)){_=d.slice(1,-1).split(""),F=!1;for(let mt=0;mt<_.length;mt++){if(I=d.slice(mt+2),_[mt+1]&&_[mt+1]==="="){ht=d.slice(mt+3),p=_[mt],M(p,g.arrays)?c=te(c,p,r,ht):M(p,g.nargs)!==!1?c=Fe(c,p,r,ht):V(p,ht),F=!0;break}if(I==="-"){V(_[mt],I);continue}if(/[A-Za-z]/.test(_[mt])&&/^-?\d+(\.\d*)?(e-?\d+)?$/.test(I)&&M(I,g.bools)===!1){V(_[mt],I),F=!0;break}if(_[mt+1]&&_[mt+1].match(/\W/)){V(_[mt],I),F=!0;break}else V(_[mt],it(_[mt]))}p=d.slice(-1)[0],!F&&p!=="-"&&(M(p,g.arrays)?c=te(c,p,r):M(p,g.nargs)!==!1?c=Fe(c,p,r):(I=r[c+1],I!==void 0&&(!/^(-|--)[^-]/.test(I)||I.match(O))&&!M(p,g.bools)&&!M(p,g.counts)||/^(true|false)$/.test(I)?(V(p,I),c++):V(p,it(p))))}else if(d.match(/^-[0-9]$/)&&d.match(O)&&M(d.slice(1),g.bools))p=d.slice(1),V(p,it(p));else if(d==="--"){L=r.slice(c+1);break}else if(a["halt-at-non-option"]){L=r.slice(c);break}else It(d)}z(U,!0),z(U,!1),N(U),lt(),X(U,g.aliases,l,!0),Dt(U),a["set-placeholder-key"]&&ee(U),Object.keys(g.counts).forEach(function(c){Rt(U,c.split("."))||V(c,0)}),D&&L.length&&(U[m]=[]),L.forEach(function(c){U[m].push(c)}),a["camel-case-expansion"]&&a["strip-dashed"]&&Object.keys(U).filter(c=>c!=="--"&&c.includes("-")).forEach(c=>{delete U[c]}),a["strip-aliased"]&&[].concat(...Object.keys(i).map(c=>i[c])).forEach(c=>{a["camel-case-expansion"]&&c.includes("-")&&delete U[c.split(".").map(d=>oe(d)).join(".")],delete U[c]});function It(c){let d=v("_",c);(typeof d=="string"||typeof d=="number")&&U._.push(d)}function Fe(c,d,y,F){let p,_=M(d,g.nargs);if(_=typeof _!="number"||isNaN(_)?1:_,_===0)return Mt(F)||(H=Error(b("Argument unexpected for: %s",d))),V(d,it(d)),c;let A=Mt(F)?0:1;if(a["nargs-eats-options"])y.length-(c+1)+A<_&&(H=Error(b("Not enough arguments following: %s",d))),A=_;else{for(p=c+1;p<y.length&&(!y[p].match(/^-[^0-9]/)||y[p].match(O)||st(y[p]));p++)A++;A<_&&(H=Error(b("Not enough arguments following: %s",d)))}let I=Math.min(A,_);for(!Mt(F)&&I>0&&(V(d,F),I--),p=c+1;p<I+c+1;p++)V(d,y[p]);return c+I}function te(c,d,y,F){let p=[],_=F||y[c+1],A=M(d,g.nargs);if(M(d,g.bools)&&!/^(true|false)$/.test(_))p.push(!0);else if(Mt(_)||Mt(F)&&/^-/.test(_)&&!O.test(_)&&!st(_)){if(l[d]!==void 0){let I=l[d];p=Array.isArray(I)?I:[I]}}else{Mt(F)||p.push(w(d,F,!0));for(let I=c+1;I<y.length&&!(!a["greedy-arrays"]&&p.length>0||A&&typeof A=="number"&&p.length>=A||(_=y[I],/^-/.test(_)&&!O.test(_)&&!st(_)));I++)c=I,p.push(w(d,_,o))}return typeof A=="number"&&(A&&p.length<A||isNaN(A)&&p.length===0)&&(H=Error(b("Not enough arguments following: %s",d))),V(d,p),c}function V(c,d,y=o){if(/-/.test(c)&&a["camel-case-expansion"]){let _=c.split(".").map(function(A){return oe(A)}).join(".");j(c,_)}let F=w(c,d,y),p=c.split(".");Lt(U,p,F),g.aliases[c]&&g.aliases[c].forEach(function(_){let A=_.split(".");Lt(U,A,F)}),p.length>1&&a["dot-notation"]&&(g.aliases[p[0]]||[]).forEach(function(_){let A=_.split("."),I=[].concat(p);I.shift(),A=A.concat(I),(g.aliases[c]||[]).includes(A.join("."))||Lt(U,A,F)}),M(c,g.normalize)&&!M(c,g.arrays)&&[c].concat(g.aliases[c]||[]).forEach(function(A){Object.defineProperty(qt,A,{enumerable:!0,get(){return d},set(I){d=typeof I=="string"?zt.normalize(I):I}})})}function j(c,d){g.aliases[c]&&g.aliases[c].length||(g.aliases[c]=[d],C[d]=!0),g.aliases[d]&&g.aliases[d].length||j(d,c)}function w(c,d,y){y&&(d=Ea(d)),(M(c,g.bools)||M(c,g.counts))&&typeof d=="string"&&(d=d==="true");let F=Array.isArray(d)?d.map(function(p){return v(c,p)}):v(c,d);return M(c,g.counts)&&(Mt(F)||typeof F=="boolean")&&(F=_s()),M(c,g.normalize)&&M(c,g.arrays)&&(Array.isArray(d)?F=d.map(p=>zt.normalize(p)):F=zt.normalize(d)),F}function v(c,d){return!a["parse-positional-numbers"]&&c==="_"||!M(c,g.strings)&&!M(c,g.bools)&&!Array.isArray(d)&&(En(d)&&a["parse-numbers"]&&Number.isSafeInteger(Math.floor(parseFloat(`${d}`)))||!Mt(d)&&M(c,g.numbers))&&(d=Number(d)),d}function N(c){let d=Object.create(null);X(d,g.aliases,l),Object.keys(g.configs).forEach(function(y){let F=c[y]||d[y];if(F)try{let p=null,_=zt.resolve(zt.cwd(),F),A=g.configs[y];if(typeof A=="function"){try{p=A(_)}catch(I){p=I}if(p instanceof Error){H=p;return}}else p=zt.require(_);q(p)}catch(p){p.name==="PermissionDenied"?H=p:c[y]&&(H=Error(b("Invalid JSON config file: %s",F)))}})}function q(c,d){Object.keys(c).forEach(function(y){let F=c[y],p=d?d+"."+y:y;typeof F=="object"&&F!==null&&!Array.isArray(F)&&a["dot-notation"]?q(F,p):(!Rt(U,p.split("."))||M(p,g.arrays)&&a["combine-arrays"])&&V(p,F)})}function lt(){typeof h<"u"&&h.forEach(function(c){q(c)})}function z(c,d){if(typeof f>"u")return;let y=typeof f=="string"?f:"",F=zt.env();Object.keys(F).forEach(function(p){if(y===""||p.lastIndexOf(y,0)===0){let _=p.split("__").map(function(A,I){return I===0&&(A=A.substring(y.length)),oe(A)});(d&&g.configs[_.join(".")]||!d)&&!Rt(c,_)&&V(_.join("."),F[p])}})}function Dt(c){let d,y=new Set;Object.keys(c).forEach(function(F){if(!y.has(F)&&(d=M(F,g.coercions),typeof d=="function"))try{let p=v(F,d(c[F]));[].concat(g.aliases[F]||[],F).forEach(_=>{y.add(_),c[_]=p})}catch(p){H=p}})}function ee(c){return g.keys.forEach(d=>{~d.indexOf(".")||typeof c[d]>"u"&&(c[d]=void 0)}),c}function X(c,d,y,F=!1){Object.keys(y).forEach(function(p){Rt(c,p.split("."))||(Lt(c,p.split("."),y[p]),F&&(E[p]=!0),(d[p]||[]).forEach(function(_){Rt(c,_.split("."))||Lt(c,_.split("."),y[p])}))})}function Rt(c,d){let y=c;a["dot-notation"]||(d=[d.join(".")]),d.slice(0,-1).forEach(function(p){y=y[p]||{}});let F=d[d.length-1];return typeof y!="object"?!1:F in y}function Lt(c,d,y){let F=c;a["dot-notation"]||(d=[d.join(".")]),d.slice(0,-1).forEach(function(ht){ht=zr(ht),typeof F=="object"&&F[ht]===void 0&&(F[ht]={}),typeof F[ht]!="object"||Array.isArray(F[ht])?(Array.isArray(F[ht])?F[ht].push({}):F[ht]=[F[ht],{}],F=F[ht][F[ht].length-1]):F=F[ht]});let p=zr(d[d.length-1]),_=M(d.join("."),g.arrays),A=Array.isArray(y),I=a["duplicate-arguments-array"];!I&&M(p,g.nargs)&&(I=!0,(!Mt(F[p])&&g.nargs[p]===1||Array.isArray(F[p])&&F[p].length===g.nargs[p])&&(F[p]=void 0)),y===_s()?F[p]=_s(F[p]):Array.isArray(F[p])?I&&_&&A?F[p]=a["flatten-duplicate-arrays"]?F[p].concat(y):(Array.isArray(F[p][0])?F[p]:[F[p]]).concat([y]):!I&&!!_==!!A?F[p]=y:F[p]=F[p].concat([y]):F[p]===void 0&&_?F[p]=A?y:[y]:I&&!(F[p]===void 0||M(p,g.counts)||M(p,g.bools))?F[p]=[F[p],y]:F[p]=y}function ne(...c){c.forEach(function(d){Object.keys(d||{}).forEach(function(y){g.aliases[y]||(g.aliases[y]=[].concat(i[y]||[]),g.aliases[y].concat(y).forEach(function(F){if(/-/.test(F)&&a["camel-case-expansion"]){let p=oe(F);p!==y&&g.aliases[y].indexOf(p)===-1&&(g.aliases[y].push(p),C[p]=!0)}}),g.aliases[y].concat(y).forEach(function(F){if(F.length>1&&/[A-Z]/.test(F)&&a["camel-case-expansion"]){let p=bn(F,"-");p!==y&&g.aliases[y].indexOf(p)===-1&&(g.aliases[y].push(p),C[p]=!0)}}),g.aliases[y].forEach(function(F){g.aliases[F]=[y].concat(g.aliases[y].filter(function(p){return F!==p}))}))})})}function M(c,d){let y=[].concat(g.aliases[c]||[],c),F=Object.keys(d),p=y.find(_=>F.includes(_));return p?d[p]:!1}function Rn(c){let d=Object.keys(g);return[].concat(d.map(F=>g[F])).some(function(F){return Array.isArray(F)?F.includes(c):F[c]})}function P(c,...d){return[].concat(...d).some(function(F){let p=c.match(F);return p&&Rn(p[1])})}function K(c){if(c.match(O)||!c.match(/^-[^-]+/))return!1;let d=!0,y,F=c.slice(1).split("");for(let p=0;p<F.length;p++){if(y=c.slice(p+2),!Rn(F[p])){d=!1;break}if(F[p+1]&&F[p+1]==="="||y==="-"||/[A-Za-z]/.test(F[p])&&/^-?\d+(\.\d*)?(e-?\d+)?$/.test(y)||F[p+1]&&F[p+1].match(/\W/))break}return d}function st(c){return a["unknown-options-as-args"]&&R(c)}function R(c){return c=c.replace(/^-{3,}/,"--"),c.match(O)||K(c)?!1:!P(c,/^-+([^=]+?)=[\s\S]*$/,T,/^-+([^=]+?)$/,/^-+([^=]+?)-$/,/^-+([^=]+?\d+)$/,/^-+([^=]+?)\W+.*$/)}function it(c){return!M(c,g.bools)&&!M(c,g.counts)&&`${c}`in l?l[c]:ot(Pt(c))}function ot(c){return{[vt.BOOLEAN]:!0,[vt.STRING]:"",[vt.NUMBER]:void 0,[vt.ARRAY]:[]}[c]}function Pt(c){let d=vt.BOOLEAN;return M(c,g.strings)?d=vt.STRING:M(c,g.numbers)?d=vt.NUMBER:M(c,g.bools)?d=vt.BOOLEAN:M(c,g.arrays)&&(d=vt.ARRAY),d}function Mt(c){return c===void 0}function Ve(){Object.keys(g.counts).find(c=>M(c,g.arrays)?(H=Error(b("Invalid configuration: %s, opts.count excludes opts.array.",c)),!0):M(c,g.nargs)?(H=Error(b("Invalid configuration: %s, opts.count excludes opts.narg.",c)),!0):!1)}return{aliases:Object.assign({},g.aliases),argv:Object.assign(qt,U),configuration:a,defaulted:Object.assign({},E),error:H,newAliases:Object.assign({},C)}}};function ba(n){let t=[],e=Object.create(null),s=!0;for(Object.keys(n).forEach(function(r){t.push([].concat(n[r],r))});s;){s=!1;for(let r=0;r<t.length;r++)for(let o=r+1;o<t.length;o++)if(t[r].filter(function(a){return t[o].indexOf(a)!==-1}).length){t[r]=t[r].concat(t[o]),t.splice(o,1),s=!0;break}}return t.forEach(function(r){r=r.filter(function(i,a,l){return l.indexOf(i)===a});let o=r.pop();o!==void 0&&typeof o=="string"&&(e[o]=r)}),e}function _s(n){return n!==void 0?n+1:1}function zr(n){return n==="__proto__"?"___proto___":n}function Ea(n){return typeof n=="string"&&(n[0]==="'"||n[0]==='"')&&n[n.length-1]===n[0]?n.substring(1,n.length-1):n}var Vr=require("fs");var js,Ss,Is,qr=process&&process.env&&process.env.YARGS_MIN_NODE_VERSION?Number(process.env.YARGS_MIN_NODE_VERSION):12,Hr=(Ss=(js=process==null?void 0:process.versions)===null||js===void 0?void 0:js.node)!==null&&Ss!==void 0?Ss:(Is=process==null?void 0:process.version)===null||Is===void 0?void 0:Is.slice(1);if(Hr&&Number(Hr.match(/^([^.]+)/)[1])<qr)throw Error(`yargs parser supports a minimum Node.js version of ${qr}. Read our version support policy: https://github.com/yargs/yargs-parser#supported-nodejs-versions`);var ya=process?process.env:{},Yr=new yn({cwd:process.cwd,env:()=>ya,format:Ur.format,normalize:wn.normalize,resolve:wn.resolve,require:n=>{if(typeof require<"u")return require(n);if(n.match(/\.json$/))return JSON.parse((0,Vr.readFileSync)(n,"utf8"));throw Error("only .json config files are supported in ESM")}}),Le=function(t,e){return Yr.parse(t.slice(),e).argv};Le.detailed=function(n,t){return Yr.parse(n.slice(),t)};Le.camelCase=oe;Le.decamelize=bn;Le.looksLikeNumber=En;var Gr=Le;var kt=require("path");function wa(){return Aa()?0:1}function Aa(){return $a()&&!process.defaultApp}function $a(){return!!process.versions.electron}function Jr(){return process.argv[wa()]}var G=class n extends Error{constructor(t){super(t||"yargs error"),this.name="YError",Error.captureStackTrace&&Error.captureStackTrace(this,n)}};var Oe=require("fs"),Kr=require("util"),Qr=require("path"),Zr={fs:{readFileSync:Oe.readFileSync,writeFile:Oe.writeFile},format:Kr.format,resolve:Qr.resolve,exists:n=>{try{return(0,Oe.statSync)(n).isFile()}catch{return!1}}};var Wt,Ps=class{constructor(t){t=t||{},this.directory=t.directory||"./locales",this.updateFiles=typeof t.updateFiles=="boolean"?t.updateFiles:!0,this.locale=t.locale||"en",this.fallbackToLanguage=typeof t.fallbackToLanguage=="boolean"?t.fallbackToLanguage:!0,this.cache=Object.create(null),this.writeQueue=[]}__(...t){if(typeof arguments[0]!="string")return this._taggedLiteral(arguments[0],...arguments);let e=t.shift(),s=function(){};return typeof t[t.length-1]=="function"&&(s=t.pop()),s=s||function(){},this.cache[this.locale]||this._readLocaleFile(),!this.cache[this.locale][e]&&this.updateFiles?(this.cache[this.locale][e]=e,this._enqueueWrite({directory:this.directory,locale:this.locale,cb:s})):s(),Wt.format.apply(Wt.format,[this.cache[this.locale][e]||e].concat(t))}__n(){let t=Array.prototype.slice.call(arguments),e=t.shift(),s=t.shift(),r=t.shift(),o=function(){};typeof t[t.length-1]=="function"&&(o=t.pop()),this.cache[this.locale]||this._readLocaleFile();let i=r===1?e:s;this.cache[this.locale][e]&&(i=this.cache[this.locale][e][r===1?"one":"other"]),!this.cache[this.locale][e]&&this.updateFiles?(this.cache[this.locale][e]={one:e,other:s},this._enqueueWrite({directory:this.directory,locale:this.locale,cb:o})):o();let a=[i];return~i.indexOf("%d")&&a.push(r),Wt.format.apply(Wt.format,a.concat(t))}setLocale(t){this.locale=t}getLocale(){return this.locale}updateLocale(t){this.cache[this.locale]||this._readLocaleFile();for(let e in t)Object.prototype.hasOwnProperty.call(t,e)&&(this.cache[this.locale][e]=t[e])}_taggedLiteral(t,...e){let s="";return t.forEach(function(r,o){let i=e[o+1];s+=r,typeof i<"u"&&(s+="%s")}),this.__.apply(this,[s].concat([].slice.call(e,1)))}_enqueueWrite(t){this.writeQueue.push(t),this.writeQueue.length===1&&this._processWriteQueue()}_processWriteQueue(){let t=this,e=this.writeQueue[0],s=e.directory,r=e.locale,o=e.cb,i=this._resolveLocaleFile(s,r),a=JSON.stringify(this.cache[r],null,2);Wt.fs.writeFile(i,a,"utf-8",function(l){t.writeQueue.shift(),t.writeQueue.length>0&&t._processWriteQueue(),o(l)})}_readLocaleFile(){let t={},e=this._resolveLocaleFile(this.directory,this.locale);try{Wt.fs.readFileSync&&(t=JSON.parse(Wt.fs.readFileSync(e,"utf-8")))}catch(s){if(s instanceof SyntaxError&&(s.message="syntax error in "+e),s.code==="ENOENT")t={};else throw s}this.cache[this.locale]=t}_resolveLocaleFile(t,e){let s=Wt.resolve(t,"./",e+".json");if(this.fallbackToLanguage&&!this._fileExistsSync(s)&&~e.lastIndexOf("_")){let r=Wt.resolve(t,"./",e.split("_")[0]+".json");this._fileExistsSync(r)&&(s=r)}return s}_fileExistsSync(t){return Wt.exists(t)}};function Xr(n,t){Wt=t;let e=new Ps(n);return{__:e.__.bind(e),__n:e.__n.bind(e),setLocale:e.setLocale.bind(e),getLocale:e.getLocale.bind(e),updateLocale:e.updateLocale.bind(e),locale:e.locale}}var xa=n=>Xr(n,Zr),to=xa;var Oa={},Ba="require is not supported by ESM",eo="loading a directory of commands is not supported yet for ESM",ze;try{ze=(0,io.fileURLToPath)(Oa.url)}catch{ze=process.cwd()}var va=ze.substring(0,ze.lastIndexOf("node_modules")),ro={assert:{notStrictEqual:An.notStrictEqual,strictEqual:An.strictEqual},cliui:Os,findUp:Rr,getEnv:n=>process.env[n],inspect:no.inspect,getCallerFile:()=>{throw new G(eo)},getProcessArgvBin:Jr,mainFilename:va||process.cwd(),Parser:Gr,path:{basename:kt.basename,dirname:kt.dirname,extname:kt.extname,relative:kt.relative,resolve:kt.resolve},process:{argv:()=>process.argv,cwd:process.cwd,emitWarning:(n,t)=>process.emitWarning(n,t),execPath:()=>process.execPath,exit:process.exit,nextTick:process.nextTick,stdColumns:typeof process.stdout.columns<"u"?process.stdout.columns:null},readFileSync:so.readFileSync,require:()=>{throw new G(Ba)},requireDirectory:()=>{throw new G(eo)},stringWidth:n=>[...n].length,y18n:to({directory:(0,kt.resolve)(ze,"../../../locales"),updateFiles:!1})};function Ft(n,t,e,s){e.assert.notStrictEqual(n,t,s)}function Ms(n,t){t.assert.strictEqual(typeof n,"string")}function _e(n){return Object.keys(n)}function J(n){return!!n&&!!n.then&&typeof n.then=="function"}function Gt(n){let e=n.replace(/\s{2,}/g," ").split(/\s+(?![^[]*]|[^<]*>)/),s=/\.*[\][<>]/g,r=e.shift();if(!r)throw new Error(`No command found in: ${n}`);let o={cmd:r.replace(s,""),demanded:[],optional:[]};return e.forEach((i,a)=>{let l=!1;i=i.replace(/\s/g,""),/\.+[\]>]/.test(i)&&a===e.length-1&&(l=!0),/^\[/.test(i)?o.optional.push({cmd:i.replace(s,"").split("|"),variadic:l}):o.demanded.push({cmd:i.replace(s,"").split("|"),variadic:l})}),o}var _a=["first","second","third","fourth","fifth","sixth"];function x(n,t,e){function s(){return typeof n=="object"?[{demanded:[],optional:[]},n,t]:[Gt(`cmd ${n}`),t,e]}try{let r=0,[o,i,a]=s(),l=[].slice.call(i);for(;l.length&&l[l.length-1]===void 0;)l.pop();let h=a||l.length;if(h<o.demanded.length)throw new G(`Not enough arguments provided. Expected ${o.demanded.length} but received ${l.length}.`);let f=o.demanded.length+o.optional.length;if(h>f)throw new G(`Too many arguments provided. Expected max ${f} but received ${h}.`);o.demanded.forEach(D=>{let m=l.shift(),C=oo(m);D.cmd.filter(b=>b===C||b==="*").length===0&&uo(C,D.cmd,r),r+=1}),o.optional.forEach(D=>{if(l.length===0)return;let m=l.shift(),C=oo(m);D.cmd.filter(b=>b===C||b==="*").length===0&&uo(C,D.cmd,r),r+=1})}catch(r){console.warn(r.stack)}}function oo(n){return Array.isArray(n)?"array":n===null?"null":typeof n}function uo(n,t,e){throw new G(`Invalid ${_a[e]||"manyith"} argument. Expected ${t.join(" or ")} but received ${n}.`)}var $n=class{constructor(t){this.globalMiddleware=[],this.frozens=[],this.yargs=t}addMiddleware(t,e,s=!0,r=!1){if(x("<array|function> [boolean] [boolean] [boolean]",[t,e,s],arguments.length),Array.isArray(t)){for(let o=0;o<t.length;o++){if(typeof t[o]!="function")throw Error("middleware must be a function");let i=t[o];i.applyBeforeValidation=e,i.global=s}Array.prototype.push.apply(this.globalMiddleware,t)}else if(typeof t=="function"){let o=t;o.applyBeforeValidation=e,o.global=s,o.mutates=r,this.globalMiddleware.push(t)}return this.yargs}addCoerceMiddleware(t,e){let s=this.yargs.getAliases();return this.globalMiddleware=this.globalMiddleware.filter(r=>{let o=[...s[e]||[],e];return r.option?!o.includes(r.option):!0}),t.option=e,this.addMiddleware(t,!0,!0,!0)}getMiddleware(){return this.globalMiddleware}freeze(){this.frozens.push([...this.globalMiddleware])}unfreeze(){let t=this.frozens.pop();t!==void 0&&(this.globalMiddleware=t)}reset(){this.globalMiddleware=this.globalMiddleware.filter(t=>t.global)}};function ao(n){return n?n.map(t=>(t.applyBeforeValidation=!1,t)):[]}function ue(n,t,e,s){return e.reduce((r,o)=>{if(o.applyBeforeValidation!==s)return r;if(o.mutates){if(o.applied)return r;o.applied=!0}if(J(r))return r.then(i=>Promise.all([i,o(i,t)])).then(([i,a])=>Object.assign(i,a));{let i=o(r,t);return J(i)?i.then(a=>Object.assign(r,a)):Object.assign(r,i)}},n)}function ae(n,t,e=s=>{throw s}){try{let s=ja(n)?n():n;return J(s)?s.then(r=>t(r)):t(s)}catch(s){return e(s)}}function ja(n){return typeof n=="function"}function Ws(n){if(typeof require>"u")return null;for(let t=0,e=Object.keys(require.cache),s;t<e.length;t++)if(s=require.cache[e[t]],s.exports===n)return s;return null}var je=/(^\*)|(^\$0)/,ks=class{constructor(t,e,s,r){this.requireCache=new Set,this.handlers={},this.aliasMap={},this.frozens=[],this.shim=r,this.usage=t,this.globalMiddleware=s,this.validation=e}addDirectory(t,e,s,r){r=r||{},typeof r.recurse!="boolean"&&(r.recurse=!1),Array.isArray(r.extensions)||(r.extensions=["js"]);let o=typeof r.visit=="function"?r.visit:i=>i;r.visit=(i,a,l)=>{let h=o(i,a,l);if(h){if(this.requireCache.has(a))return h;this.requireCache.add(a),this.addHandler(h)}return h},this.shim.requireDirectory({require:e,filename:s},t,r)}addHandler(t,e,s,r,o,i){let a=[],l=ao(o);if(r=r||(()=>{}),Array.isArray(t))if(Sa(t))[t,...a]=t;else for(let h of t)this.addHandler(h);else if(Pa(t)){let h=Array.isArray(t.command)||typeof t.command=="string"?t.command:this.moduleName(t);t.aliases&&(h=[].concat(h).concat(t.aliases)),this.addHandler(h,this.extractDesc(t),t.builder,t.handler,t.middlewares,t.deprecated);return}else if(co(s)){this.addHandler([t].concat(a),e,s.builder,s.handler,s.middlewares,s.deprecated);return}if(typeof t=="string"){let h=Gt(t);a=a.map(m=>Gt(m).cmd);let f=!1,D=[h.cmd].concat(a).filter(m=>je.test(m)?(f=!0,!1):!0);D.length===0&&f&&D.push("$0"),f&&(h.cmd=D[0],a=D.slice(1),t=t.replace(je,h.cmd)),a.forEach(m=>{this.aliasMap[m]=h.cmd}),e!==!1&&this.usage.command(t,e,f,a,i),this.handlers[h.cmd]={original:t,description:e,handler:r,builder:s||{},middlewares:l,deprecated:i,demanded:h.demanded,optional:h.optional},f&&(this.defaultCommand=this.handlers[h.cmd])}}getCommandHandlers(){return this.handlers}getCommands(){return Object.keys(this.handlers).concat(Object.keys(this.aliasMap))}hasDefaultCommand(){return!!this.defaultCommand}runCommand(t,e,s,r,o,i){let a=this.handlers[t]||this.handlers[this.aliasMap[t]]||this.defaultCommand,l=e.getInternalMethods().getContext(),h=l.commands.slice(),f=!t;t&&(l.commands.push(t),l.fullCommands.push(a.original));let D=this.applyBuilderUpdateUsageAndParse(f,a,e,s.aliases,h,r,o,i);return J(D)?D.then(m=>this.applyMiddlewareAndGetResult(f,a,m.innerArgv,l,o,m.aliases,e)):this.applyMiddlewareAndGetResult(f,a,D.innerArgv,l,o,D.aliases,e)}applyBuilderUpdateUsageAndParse(t,e,s,r,o,i,a,l){let h=e.builder,f=s;if(xn(h)){s.getInternalMethods().getUsageInstance().freeze();let D=h(s.getInternalMethods().reset(r),l);if(J(D))return D.then(m=>(f=Do(m)?m:s,this.parseAndUpdateUsage(t,e,f,o,i,a)))}else Ia(h)&&(s.getInternalMethods().getUsageInstance().freeze(),f=s.getInternalMethods().reset(r),Object.keys(e.builder).forEach(D=>{f.option(D,h[D])}));return this.parseAndUpdateUsage(t,e,f,o,i,a)}parseAndUpdateUsage(t,e,s,r,o,i){t&&s.getInternalMethods().getUsageInstance().unfreeze(!0),this.shouldUpdateUsage(s)&&s.getInternalMethods().getUsageInstance().usage(this.usageFromParentCommandsCommandHandler(r,e),e.description);let a=s.getInternalMethods().runYargsParserAndExecuteCommands(null,void 0,!0,o,i);return J(a)?a.then(l=>({aliases:s.parsed.aliases,innerArgv:l})):{aliases:s.parsed.aliases,innerArgv:a}}shouldUpdateUsage(t){return!t.getInternalMethods().getUsageInstance().getUsageDisabled()&&t.getInternalMethods().getUsageInstance().getUsage().length===0}usageFromParentCommandsCommandHandler(t,e){let s=je.test(e.original)?e.original.replace(je,"").trim():e.original,r=t.filter(o=>!je.test(o));return r.push(s),`$0 ${r.join(" ")}`}handleValidationAndGetResult(t,e,s,r,o,i,a,l){if(!i.getInternalMethods().getHasOutput()){let h=i.getInternalMethods().runValidation(o,l,i.parsed.error,t);s=ae(s,f=>(h(f),f))}if(e.handler&&!i.getInternalMethods().getHasOutput()){i.getInternalMethods().setHasOutput();let h=!!i.getOptions().configuration["populate--"];i.getInternalMethods().postProcess(s,h,!1,!1),s=ue(s,i,a,!1),s=ae(s,f=>{let D=e.handler(f);return J(D)?D.then(()=>f):f}),t||i.getInternalMethods().getUsageInstance().cacheHelpMessage(),J(s)&&!i.getInternalMethods().hasParseCallback()&&s.catch(f=>{try{i.getInternalMethods().getUsageInstance().fail(null,f)}catch{}})}return t||(r.commands.pop(),r.fullCommands.pop()),s}applyMiddlewareAndGetResult(t,e,s,r,o,i,a){let l={};if(o)return s;a.getInternalMethods().getHasOutput()||(l=this.populatePositionals(e,s,r,a));let h=this.globalMiddleware.getMiddleware().slice(0).concat(e.middlewares),f=ue(s,a,h,!0);return J(f)?f.then(D=>this.handleValidationAndGetResult(t,e,D,r,i,a,h,l)):this.handleValidationAndGetResult(t,e,f,r,i,a,h,l)}populatePositionals(t,e,s,r){e._=e._.slice(s.commands.length);let o=t.demanded.slice(0),i=t.optional.slice(0),a={};for(this.validation.positionalCount(o.length,e._.length);o.length;){let l=o.shift();this.populatePositional(l,e,a)}for(;i.length;){let l=i.shift();this.populatePositional(l,e,a)}return e._=s.commands.concat(e._.map(l=>""+l)),this.postProcessPositionals(e,a,this.cmdToParseOptions(t.original),r),a}populatePositional(t,e,s){let r=t.cmd[0];t.variadic?s[r]=e._.splice(0).map(String):e._.length&&(s[r]=[String(e._.shift())])}cmdToParseOptions(t){let e={array:[],default:{},alias:{},demand:{}},s=Gt(t);return s.demanded.forEach(r=>{let[o,...i]=r.cmd;r.variadic&&(e.array.push(o),e.default[o]=[]),e.alias[o]=i,e.demand[o]=!0}),s.optional.forEach(r=>{let[o,...i]=r.cmd;r.variadic&&(e.array.push(o),e.default[o]=[]),e.alias[o]=i}),e}postProcessPositionals(t,e,s,r){let o=Object.assign({},r.getOptions());o.default=Object.assign(s.default,o.default);for(let h of Object.keys(s.alias))o.alias[h]=(o.alias[h]||[]).concat(s.alias[h]);o.array=o.array.concat(s.array),o.config={};let i=[];if(Object.keys(e).forEach(h=>{e[h].map(f=>{o.configuration["unknown-options-as-args"]&&(o.key[h]=!0),i.push(`--${h}`),i.push(f)})}),!i.length)return;let a=Object.assign({},o.configuration,{"populate--":!1}),l=this.shim.Parser.detailed(i,Object.assign({},o,{configuration:a}));if(l.error)r.getInternalMethods().getUsageInstance().fail(l.error.message,l.error);else{let h=Object.keys(e);Object.keys(e).forEach(f=>{h.push(...l.aliases[f])}),Object.keys(l.argv).forEach(f=>{h.includes(f)&&(e[f]||(e[f]=l.argv[f]),!this.isInConfigs(r,f)&&!this.isDefaulted(r,f)&&Object.prototype.hasOwnProperty.call(t,f)&&Object.prototype.hasOwnProperty.call(l.argv,f)&&(Array.isArray(t[f])||Array.isArray(l.argv[f]))?t[f]=[].concat(t[f],l.argv[f]):t[f]=l.argv[f])})}}isDefaulted(t,e){let{default:s}=t.getOptions();return Object.prototype.hasOwnProperty.call(s,e)||Object.prototype.hasOwnProperty.call(s,this.shim.Parser.camelCase(e))}isInConfigs(t,e){let{configObjects:s}=t.getOptions();return s.some(r=>Object.prototype.hasOwnProperty.call(r,e))||s.some(r=>Object.prototype.hasOwnProperty.call(r,this.shim.Parser.camelCase(e)))}runDefaultBuilderOn(t){if(!this.defaultCommand)return;if(this.shouldUpdateUsage(t)){let s=je.test(this.defaultCommand.original)?this.defaultCommand.original:this.defaultCommand.original.replace(/^[^[\]<>]*/,"$0 ");t.getInternalMethods().getUsageInstance().usage(s,this.defaultCommand.description)}let e=this.defaultCommand.builder;if(xn(e))return e(t,!0);co(e)||Object.keys(e).forEach(s=>{t.option(s,e[s])})}moduleName(t){let e=Ws(t);if(!e)throw new Error(`No command name given for module: ${this.shim.inspect(t)}`);return this.commandFromFilename(e.filename)}commandFromFilename(t){return this.shim.path.basename(t,this.shim.path.extname(t))}extractDesc({describe:t,description:e,desc:s}){for(let r of[t,e,s]){if(typeof r=="string"||r===!1)return r;Ft(r,!0,this.shim)}return!1}freeze(){this.frozens.push({handlers:this.handlers,aliasMap:this.aliasMap,defaultCommand:this.defaultCommand})}unfreeze(){let t=this.frozens.pop();Ft(t,void 0,this.shim),{handlers:this.handlers,aliasMap:this.aliasMap,defaultCommand:this.defaultCommand}=t}reset(){return this.handlers={},this.aliasMap={},this.defaultCommand=void 0,this.requireCache=new Set,this}};function lo(n,t,e,s){return new ks(n,t,e,s)}function co(n){return typeof n=="object"&&!!n.builder&&typeof n.handler=="function"}function Sa(n){return n.every(t=>typeof t=="string")}function xn(n){return typeof n=="function"}function Ia(n){return typeof n=="object"}function Pa(n){return typeof n=="object"&&!Array.isArray(n)}function Jt(n={},t=()=>!0){let e={};return _e(n).forEach(s=>{t(s,n[s])&&(e[s]=n[s])}),e}function Kt(n){typeof process>"u"||[process.stdout,process.stderr].forEach(t=>{let e=t;e._handle&&e.isTTY&&typeof e._handle.setBlocking=="function"&&e._handle.setBlocking(n)})}function Ma(n){return typeof n=="boolean"}function fo(n,t){let e=t.y18n.__,s={},r=[];s.failFn=function(w){r.push(w)};let o=null,i=null,a=!0;s.showHelpOnFail=function(w=!0,v){let[N,q]=typeof w=="string"?[!0,w]:[w,v];return n.getInternalMethods().isGlobalContext()&&(i=q),o=q,a=N,s};let l=!1;s.fail=function(w,v){let N=n.getInternalMethods().getLoggerInstance();if(r.length)for(let q=r.length-1;q>=0;--q){let lt=r[q];if(Ma(lt)){if(v)throw v;if(w)throw Error(w)}else lt(w,v,s)}else{if(n.getExitProcess()&&Kt(!0),!l){l=!0,a&&(n.showHelp("error"),N.error()),(w||v)&&N.error(w||v);let q=o||i;q&&((w||v)&&N.error(""),N.error(q))}if(v=v||new G(w),n.getExitProcess())return n.exit(1);if(n.getInternalMethods().hasParseCallback())return n.exit(1,v);throw v}};let h=[],f=!1;s.usage=(j,w)=>j===null?(f=!0,h=[],s):(f=!1,h.push([j,w||""]),s),s.getUsage=()=>h,s.getUsageDisabled=()=>f,s.getPositionalGroupName=()=>e("Positionals:");let D=[];s.example=(j,w)=>{D.push([j,w||""])};let m=[];s.command=function(w,v,N,q,lt=!1){N&&(m=m.map(z=>(z[2]=!1,z))),m.push([w,v||"",N,q,lt])},s.getCommands=()=>m;let C={};s.describe=function(w,v){Array.isArray(w)?w.forEach(N=>{s.describe(N,v)}):typeof w=="object"?Object.keys(w).forEach(N=>{s.describe(N,w[N])}):C[w]=v},s.getDescriptions=()=>C;let E=[];s.epilog=j=>{E.push(j)};let b=!1,g;s.wrap=j=>{b=!0,g=j},s.getWrap=()=>t.getEnv("YARGS_DISABLE_WRAP")?null:(b||(g=Fe(),b=!0),g);let O="__yargsString__:";s.deferY18nLookup=j=>O+j,s.help=function(){if(L)return L;H();let w=n.customScriptName?n.$0:t.path.basename(n.$0),v=n.getDemandedOptions(),N=n.getDemandedCommands(),q=n.getDeprecatedOptions(),lt=n.getGroups(),z=n.getOptions(),Dt=[];Dt=Dt.concat(Object.keys(C)),Dt=Dt.concat(Object.keys(v)),Dt=Dt.concat(Object.keys(N)),Dt=Dt.concat(Object.keys(z.default)),Dt=Dt.filter(qt),Dt=Object.keys(Dt.reduce((P,K)=>(K!=="_"&&(P[K]=!0),P),{}));let ee=s.getWrap(),X=t.cliui({width:ee,wrap:!!ee});if(!f){if(h.length)h.forEach(P=>{X.div({text:`${P[0].replace(/\$0/g,w)}`}),P[1]&&X.div({text:`${P[1]}`,padding:[1,0,0,0]})}),X.div();else if(m.length){let P=null;N._?P=`${w} <${e("command")}>
|
|
109
|
-
`:
|
|
110
|
-
`,X.div(`${
|
|
111
|
-
`);X.div(`${
|
|
112
|
-
`)}return X.toString().replace(/\s*$/,"")};function T(j,
|
|
104
|
+
`),o.border&&(r.unshift("."+"-".repeat(this.negatePadding(o)+2)+"."),r.push("'"+"-".repeat(this.negatePadding(o)+2)+"'")),o.padding&&(r.unshift(...new Array(o.padding[ba]||0).fill("")),r.push(...new Array(o.padding[ya]||0).fill(""))),r.forEach((a,c)=>{e[c]||e.push([]);let h=e[c];for(let f=0;f<i;f++)h[f]===void 0&&h.push("");h.push(a)})}),e}negatePadding(t){let e=t.width||0;return t.padding&&(e-=(t.padding[Fn]||0)+(t.padding[Cn]||0)),t.border&&(e-=4),e}columnWidths(t){if(!this.wrap)return t.map(i=>i.width||yt.stringWidth(i.text));let e=t.length,s=this.width,r=t.map(i=>{if(i.width)return e--,s-=i.width,i.width}),o=e?Math.floor(s/e):0;return r.map((i,a)=>i===void 0?Math.max(o,wa(t[a])):i)}};function Rr(n,t,e){return n.border?/[.']-+[.']/.test(t)?"":t.trim().length!==0?e:" ":""}function wa(n){let t=n.padding||[],e=1+(t[Fn]||0)+(t[Cn]||0);return n.border?e+4:e}function Aa(){return typeof process=="object"&&process.stdout&&process.stdout.columns?process.stdout.columns:80}function $a(n,t){n=n.trim();let e=yt.stringWidth(n);return e<t?" ".repeat(t-e)+n:n}function xa(n,t){n=n.trim();let e=yt.stringWidth(n);return e>=t?n:" ".repeat(t-e>>1)+n}var yt;function Lr(n,t){return yt=t,new vs({width:(n==null?void 0:n.width)||Aa(),wrap:n==null?void 0:n.wrap})}var zr=new RegExp("\x1B(?:\\[(?:\\d+[ABCDEFGJKSTm]|\\d+;\\d+[Hfm]|\\d+;\\d+;\\d+m|6n|s|u|\\?25[lh])|\\w)","g");function Os(n){return n.replace(zr,"")}function qr(n,t){let[e,s]=n.match(zr)||["",""];n=Os(n);let r="";for(let o=0;o<n.length;o++)o!==0&&o%t===0&&(r+=`
|
|
105
|
+
`),r+=n.charAt(o);return e&&s&&(r=`${e}${r}${s}`),r}function _s(n){return Lr(n,{stringWidth:t=>[...t].length,stripAnsi:Os,wrap:qr})}var _e=require("path"),En=require("fs");function Hr(n,t){let e=(0,_e.resolve)(".",n),s;for((0,En.statSync)(e).isDirectory()||(e=(0,_e.dirname)(e));;){if(s=t(e,(0,En.readdirSync)(e)),s)return(0,_e.resolve)(e,s);if(e=(0,_e.dirname)(s=e),s===e)break}}var oo=require("util"),uo=require("fs"),ao=require("url");var Jr=require("util"),An=require("path");function oe(n){if(n!==n.toLowerCase()&&n!==n.toUpperCase()||(n=n.toLowerCase()),n.indexOf("-")===-1&&n.indexOf("_")===-1)return n;{let e="",s=!1,r=n.match(/^-+/);for(let o=r?r[0].length:0;o<n.length;o++){let i=n.charAt(o);s&&(s=!1,i=i.toUpperCase()),o!==0&&(i==="-"||i==="_")?s=!0:i!=="-"&&i!=="_"&&(e+=i)}return e}}function bn(n,t){let e=n.toLowerCase();t=t||"-";let s="";for(let r=0;r<n.length;r++){let o=e.charAt(r),i=n.charAt(r);o!==i&&r>0?s+=`${t}${e.charAt(r)}`:s+=i}return s}function yn(n){return n==null?!1:typeof n=="number"||/^0x[0-9a-f]+$/i.test(n)?!0:/^0[^.]/.test(n)?!1:/^[-]?(?:\d+(?:\.\d*)?|\.\d+)(e[-+]?\d+)?$/.test(n)}function Ur(n){if(Array.isArray(n))return n.map(i=>typeof i!="string"?i+"":i);n=n.trim();let t=0,e=null,s=null,r=null,o=[];for(let i=0;i<n.length;i++){if(e=s,s=n.charAt(i),s===" "&&!r){e!==" "&&t++;continue}s===r?r=null:(s==="'"||s==='"')&&!r&&(r=s),o[t]||(o[t]=""),o[t]+=s}return o}var vt;(function(n){n.BOOLEAN="boolean",n.STRING="string",n.NUMBER="number",n.ARRAY="array"})(vt||(vt={}));var zt,wn=class{constructor(t){zt=t}parse(t,e){let s=Object.assign({alias:void 0,array:void 0,boolean:void 0,config:void 0,configObjects:void 0,configuration:void 0,coerce:void 0,count:void 0,default:void 0,envPrefix:void 0,narg:void 0,normalize:void 0,string:void 0,number:void 0,__:void 0,key:void 0},e),r=Ur(t),o=typeof t=="string",i=Ba(Object.assign(Object.create(null),s.alias)),a=Object.assign({"boolean-negation":!0,"camel-case-expansion":!0,"combine-arrays":!1,"dot-notation":!0,"duplicate-arguments-array":!0,"flatten-duplicate-arrays":!0,"greedy-arrays":!0,"halt-at-non-option":!1,"nargs-eats-options":!1,"negation-prefix":"no-","parse-numbers":!0,"parse-positional-numbers":!0,"populate--":!1,"set-placeholder-key":!1,"short-option-groups":!0,"strip-aliased":!1,"strip-dashed":!1,"unknown-options-as-args":!1},s.configuration),c=Object.assign(Object.create(null),s.default),h=s.configObjects||[],f=s.envPrefix,l=a["populate--"],m=l?"--":"_",C=Object.create(null),E=Object.create(null),b=s.__||zt.format,g={aliases:Object.create(null),arrays:Object.create(null),bools:Object.create(null),strings:Object.create(null),numbers:Object.create(null),counts:Object.create(null),normalize:Object.create(null),configs:Object.create(null),nargs:Object.create(null),coercions:Object.create(null),keys:[]},O=/^-([0-9]+(\.[0-9]+)?|\.[0-9]+)$/,T=new RegExp("^--"+a["negation-prefix"]+"(.+)");[].concat(s.array||[]).filter(Boolean).forEach(function(D){let d=typeof D=="object"?D.key:D,y=Object.keys(D).map(function(F){return{boolean:"bools",string:"strings",number:"numbers"}[F]}).filter(Boolean).pop();y&&(g[y][d]=!0),g.arrays[d]=!0,g.keys.push(d)}),[].concat(s.boolean||[]).filter(Boolean).forEach(function(D){g.bools[D]=!0,g.keys.push(D)}),[].concat(s.string||[]).filter(Boolean).forEach(function(D){g.strings[D]=!0,g.keys.push(D)}),[].concat(s.number||[]).filter(Boolean).forEach(function(D){g.numbers[D]=!0,g.keys.push(D)}),[].concat(s.count||[]).filter(Boolean).forEach(function(D){g.counts[D]=!0,g.keys.push(D)}),[].concat(s.normalize||[]).filter(Boolean).forEach(function(D){g.normalize[D]=!0,g.keys.push(D)}),typeof s.narg=="object"&&Object.entries(s.narg).forEach(([D,d])=>{typeof d=="number"&&(g.nargs[D]=d,g.keys.push(D))}),typeof s.coerce=="object"&&Object.entries(s.coerce).forEach(([D,d])=>{typeof d=="function"&&(g.coercions[D]=d,g.keys.push(D))}),typeof s.config<"u"&&(Array.isArray(s.config)||typeof s.config=="string"?[].concat(s.config).filter(Boolean).forEach(function(D){g.configs[D]=!0}):typeof s.config=="object"&&Object.entries(s.config).forEach(([D,d])=>{(typeof d=="boolean"||typeof d=="function")&&(g.configs[D]=d)})),ne(s.key,i,s.default,g.arrays),Object.keys(c).forEach(function(D){(g.aliases[D]||[]).forEach(function(d){c[d]=c[D]})});let H=null;Ge();let L=[],U=Object.assign(Object.create(null),{_:[]}),qt={};for(let D=0;D<r.length;D++){let d=r[D],y=d.replace(/^-{3,}/,"---"),F,p,_,$,I,ht;if(d!=="--"&&/^-/.test(d)&&nt(d))It(d);else if(y.match(/^---+(=|$)/)){It(d);continue}else if(d.match(/^--.+=/)||!a["short-option-groups"]&&d.match(/^-.+=/))$=d.match(/^--?([^=]+)=([\s\S]*)$/),$!==null&&Array.isArray($)&&$.length>=3&&(P($[1],g.arrays)?D=te(D,$[1],r,$[2]):P($[1],g.nargs)!==!1?D=Fe(D,$[1],r,$[2]):V($[1],$[2],!0));else if(d.match(T)&&a["boolean-negation"])$=d.match(T),$!==null&&Array.isArray($)&&$.length>=2&&(p=$[1],V(p,P(p,g.arrays)?[!1]:!1));else if(d.match(/^--.+/)||!a["short-option-groups"]&&d.match(/^-[^-]+/))$=d.match(/^--?(.+)/),$!==null&&Array.isArray($)&&$.length>=2&&(p=$[1],P(p,g.arrays)?D=te(D,p,r):P(p,g.nargs)!==!1?D=Fe(D,p,r):(I=r[D+1],I!==void 0&&(!I.match(/^-/)||I.match(O))&&!P(p,g.bools)&&!P(p,g.counts)||/^(true|false)$/.test(I)?(V(p,I),D++):V(p,st(p))));else if(d.match(/^-.\..+=/))$=d.match(/^-([^=]+)=([\s\S]*)$/),$!==null&&Array.isArray($)&&$.length>=3&&V($[1],$[2]);else if(d.match(/^-.\..+/)&&!d.match(O))I=r[D+1],$=d.match(/^-(.\..+)/),$!==null&&Array.isArray($)&&$.length>=2&&(p=$[1],I!==void 0&&!I.match(/^-/)&&!P(p,g.bools)&&!P(p,g.counts)?(V(p,I),D++):V(p,st(p)));else if(d.match(/^-[^-]+/)&&!d.match(O)){_=d.slice(1,-1).split(""),F=!1;for(let mt=0;mt<_.length;mt++){if(I=d.slice(mt+2),_[mt+1]&&_[mt+1]==="="){ht=d.slice(mt+3),p=_[mt],P(p,g.arrays)?D=te(D,p,r,ht):P(p,g.nargs)!==!1?D=Fe(D,p,r,ht):V(p,ht),F=!0;break}if(I==="-"){V(_[mt],I);continue}if(/[A-Za-z]/.test(_[mt])&&/^-?\d+(\.\d*)?(e-?\d+)?$/.test(I)&&P(I,g.bools)===!1){V(_[mt],I),F=!0;break}if(_[mt+1]&&_[mt+1].match(/\W/)){V(_[mt],I),F=!0;break}else V(_[mt],st(_[mt]))}p=d.slice(-1)[0],!F&&p!=="-"&&(P(p,g.arrays)?D=te(D,p,r):P(p,g.nargs)!==!1?D=Fe(D,p,r):(I=r[D+1],I!==void 0&&(!/^(-|--)[^-]/.test(I)||I.match(O))&&!P(p,g.bools)&&!P(p,g.counts)||/^(true|false)$/.test(I)?(V(p,I),D++):V(p,st(p))))}else if(d.match(/^-[0-9]$/)&&d.match(O)&&P(d.slice(1),g.bools))p=d.slice(1),V(p,st(p));else if(d==="--"){L=r.slice(D+1);break}else if(a["halt-at-non-option"]){L=r.slice(D);break}else It(d)}z(U,!0),z(U,!1),N(U),lt(),X(U,g.aliases,c,!0),Dt(U),a["set-placeholder-key"]&&ee(U),Object.keys(g.counts).forEach(function(D){Rt(U,D.split("."))||V(D,0)}),l&&L.length&&(U[m]=[]),L.forEach(function(D){U[m].push(D)}),a["camel-case-expansion"]&&a["strip-dashed"]&&Object.keys(U).filter(D=>D!=="--"&&D.includes("-")).forEach(D=>{delete U[D]}),a["strip-aliased"]&&[].concat(...Object.keys(i).map(D=>i[D])).forEach(D=>{a["camel-case-expansion"]&&D.includes("-")&&delete U[D.split(".").map(d=>oe(d)).join(".")],delete U[D]});function It(D){let d=v("_",D);(typeof d=="string"||typeof d=="number")&&U._.push(d)}function Fe(D,d,y,F){let p,_=P(d,g.nargs);if(_=typeof _!="number"||isNaN(_)?1:_,_===0)return Pt(F)||(H=Error(b("Argument unexpected for: %s",d))),V(d,st(d)),D;let $=Pt(F)?0:1;if(a["nargs-eats-options"])y.length-(D+1)+$<_&&(H=Error(b("Not enough arguments following: %s",d))),$=_;else{for(p=D+1;p<y.length&&(!y[p].match(/^-[^0-9]/)||y[p].match(O)||nt(y[p]));p++)$++;$<_&&(H=Error(b("Not enough arguments following: %s",d)))}let I=Math.min($,_);for(!Pt(F)&&I>0&&(V(d,F),I--),p=D+1;p<I+D+1;p++)V(d,y[p]);return D+I}function te(D,d,y,F){let p=[],_=F||y[D+1],$=P(d,g.nargs);if(P(d,g.bools)&&!/^(true|false)$/.test(_))p.push(!0);else if(Pt(_)||Pt(F)&&/^-/.test(_)&&!O.test(_)&&!nt(_)){if(c[d]!==void 0){let I=c[d];p=Array.isArray(I)?I:[I]}}else{Pt(F)||p.push(A(d,F,!0));for(let I=D+1;I<y.length&&!(!a["greedy-arrays"]&&p.length>0||$&&typeof $=="number"&&p.length>=$||(_=y[I],/^-/.test(_)&&!O.test(_)&&!nt(_)));I++)D=I,p.push(A(d,_,o))}return typeof $=="number"&&($&&p.length<$||isNaN($)&&p.length===0)&&(H=Error(b("Not enough arguments following: %s",d))),V(d,p),D}function V(D,d,y=o){if(/-/.test(D)&&a["camel-case-expansion"]){let _=D.split(".").map(function($){return oe($)}).join(".");j(D,_)}let F=A(D,d,y),p=D.split(".");Lt(U,p,F),g.aliases[D]&&g.aliases[D].forEach(function(_){let $=_.split(".");Lt(U,$,F)}),p.length>1&&a["dot-notation"]&&(g.aliases[p[0]]||[]).forEach(function(_){let $=_.split("."),I=[].concat(p);I.shift(),$=$.concat(I),(g.aliases[D]||[]).includes($.join("."))||Lt(U,$,F)}),P(D,g.normalize)&&!P(D,g.arrays)&&[D].concat(g.aliases[D]||[]).forEach(function($){Object.defineProperty(qt,$,{enumerable:!0,get(){return d},set(I){d=typeof I=="string"?zt.normalize(I):I}})})}function j(D,d){g.aliases[D]&&g.aliases[D].length||(g.aliases[D]=[d],C[d]=!0),g.aliases[d]&&g.aliases[d].length||j(d,D)}function A(D,d,y){y&&(d=va(d)),(P(D,g.bools)||P(D,g.counts))&&typeof d=="string"&&(d=d==="true");let F=Array.isArray(d)?d.map(function(p){return v(D,p)}):v(D,d);return P(D,g.counts)&&(Pt(F)||typeof F=="boolean")&&(F=js()),P(D,g.normalize)&&P(D,g.arrays)&&(Array.isArray(d)?F=d.map(p=>zt.normalize(p)):F=zt.normalize(d)),F}function v(D,d){return!a["parse-positional-numbers"]&&D==="_"||!P(D,g.strings)&&!P(D,g.bools)&&!Array.isArray(d)&&(yn(d)&&a["parse-numbers"]&&Number.isSafeInteger(Math.floor(parseFloat(`${d}`)))||!Pt(d)&&P(D,g.numbers))&&(d=Number(d)),d}function N(D){let d=Object.create(null);X(d,g.aliases,c),Object.keys(g.configs).forEach(function(y){let F=D[y]||d[y];if(F)try{let p=null,_=zt.resolve(zt.cwd(),F),$=g.configs[y];if(typeof $=="function"){try{p=$(_)}catch(I){p=I}if(p instanceof Error){H=p;return}}else p=zt.require(_);q(p)}catch(p){p.name==="PermissionDenied"?H=p:D[y]&&(H=Error(b("Invalid JSON config file: %s",F)))}})}function q(D,d){Object.keys(D).forEach(function(y){let F=D[y],p=d?d+"."+y:y;typeof F=="object"&&F!==null&&!Array.isArray(F)&&a["dot-notation"]?q(F,p):(!Rt(U,p.split("."))||P(p,g.arrays)&&a["combine-arrays"])&&V(p,F)})}function lt(){typeof h<"u"&&h.forEach(function(D){q(D)})}function z(D,d){if(typeof f>"u")return;let y=typeof f=="string"?f:"",F=zt.env();Object.keys(F).forEach(function(p){if(y===""||p.lastIndexOf(y,0)===0){let _=p.split("__").map(function($,I){return I===0&&($=$.substring(y.length)),oe($)});(d&&g.configs[_.join(".")]||!d)&&!Rt(D,_)&&V(_.join("."),F[p])}})}function Dt(D){let d,y=new Set;Object.keys(D).forEach(function(F){if(!y.has(F)&&(d=P(F,g.coercions),typeof d=="function"))try{let p=v(F,d(D[F]));[].concat(g.aliases[F]||[],F).forEach(_=>{y.add(_),D[_]=p})}catch(p){H=p}})}function ee(D){return g.keys.forEach(d=>{~d.indexOf(".")||typeof D[d]>"u"&&(D[d]=void 0)}),D}function X(D,d,y,F=!1){Object.keys(y).forEach(function(p){Rt(D,p.split("."))||(Lt(D,p.split("."),y[p]),F&&(E[p]=!0),(d[p]||[]).forEach(function(_){Rt(D,_.split("."))||Lt(D,_.split("."),y[p])}))})}function Rt(D,d){let y=D;a["dot-notation"]||(d=[d.join(".")]),d.slice(0,-1).forEach(function(p){y=y[p]||{}});let F=d[d.length-1];return typeof y!="object"?!1:F in y}function Lt(D,d,y){let F=D;a["dot-notation"]||(d=[d.join(".")]),d.slice(0,-1).forEach(function(ht){ht=Vr(ht),typeof F=="object"&&F[ht]===void 0&&(F[ht]={}),typeof F[ht]!="object"||Array.isArray(F[ht])?(Array.isArray(F[ht])?F[ht].push({}):F[ht]=[F[ht],{}],F=F[ht][F[ht].length-1]):F=F[ht]});let p=Vr(d[d.length-1]),_=P(d.join("."),g.arrays),$=Array.isArray(y),I=a["duplicate-arguments-array"];!I&&P(p,g.nargs)&&(I=!0,(!Pt(F[p])&&g.nargs[p]===1||Array.isArray(F[p])&&F[p].length===g.nargs[p])&&(F[p]=void 0)),y===js()?F[p]=js(F[p]):Array.isArray(F[p])?I&&_&&$?F[p]=a["flatten-duplicate-arrays"]?F[p].concat(y):(Array.isArray(F[p][0])?F[p]:[F[p]]).concat([y]):!I&&!!_==!!$?F[p]=y:F[p]=F[p].concat([y]):F[p]===void 0&&_?F[p]=$?y:[y]:I&&!(F[p]===void 0||P(p,g.counts)||P(p,g.bools))?F[p]=[F[p],y]:F[p]=y}function ne(...D){D.forEach(function(d){Object.keys(d||{}).forEach(function(y){g.aliases[y]||(g.aliases[y]=[].concat(i[y]||[]),g.aliases[y].concat(y).forEach(function(F){if(/-/.test(F)&&a["camel-case-expansion"]){let p=oe(F);p!==y&&g.aliases[y].indexOf(p)===-1&&(g.aliases[y].push(p),C[p]=!0)}}),g.aliases[y].concat(y).forEach(function(F){if(F.length>1&&/[A-Z]/.test(F)&&a["camel-case-expansion"]){let p=bn(F,"-");p!==y&&g.aliases[y].indexOf(p)===-1&&(g.aliases[y].push(p),C[p]=!0)}}),g.aliases[y].forEach(function(F){g.aliases[F]=[y].concat(g.aliases[y].filter(function(p){return F!==p}))}))})})}function P(D,d){let y=[].concat(g.aliases[D]||[],D),F=Object.keys(d),p=y.find(_=>F.includes(_));return p?d[p]:!1}function Ln(D){let d=Object.keys(g);return[].concat(d.map(F=>g[F])).some(function(F){return Array.isArray(F)?F.includes(D):F[D]})}function M(D,...d){return[].concat(...d).some(function(F){let p=D.match(F);return p&&Ln(p[1])})}function K(D){if(D.match(O)||!D.match(/^-[^-]+/))return!1;let d=!0,y,F=D.slice(1).split("");for(let p=0;p<F.length;p++){if(y=D.slice(p+2),!Ln(F[p])){d=!1;break}if(F[p+1]&&F[p+1]==="="||y==="-"||/[A-Za-z]/.test(F[p])&&/^-?\d+(\.\d*)?(e-?\d+)?$/.test(y)||F[p+1]&&F[p+1].match(/\W/))break}return d}function nt(D){return a["unknown-options-as-args"]&&R(D)}function R(D){return D=D.replace(/^-{3,}/,"--"),D.match(O)||K(D)?!1:!M(D,/^-+([^=]+?)=[\s\S]*$/,T,/^-+([^=]+?)$/,/^-+([^=]+?)-$/,/^-+([^=]+?\d+)$/,/^-+([^=]+?)\W+.*$/)}function st(D){return!P(D,g.bools)&&!P(D,g.counts)&&`${D}`in c?c[D]:ot(Mt(D))}function ot(D){return{[vt.BOOLEAN]:!0,[vt.STRING]:"",[vt.NUMBER]:void 0,[vt.ARRAY]:[]}[D]}function Mt(D){let d=vt.BOOLEAN;return P(D,g.strings)?d=vt.STRING:P(D,g.numbers)?d=vt.NUMBER:P(D,g.bools)?d=vt.BOOLEAN:P(D,g.arrays)&&(d=vt.ARRAY),d}function Pt(D){return D===void 0}function Ge(){Object.keys(g.counts).find(D=>P(D,g.arrays)?(H=Error(b("Invalid configuration: %s, opts.count excludes opts.array.",D)),!0):P(D,g.nargs)?(H=Error(b("Invalid configuration: %s, opts.count excludes opts.narg.",D)),!0):!1)}return{aliases:Object.assign({},g.aliases),argv:Object.assign(qt,U),configuration:a,defaulted:Object.assign({},E),error:H,newAliases:Object.assign({},C)}}};function Ba(n){let t=[],e=Object.create(null),s=!0;for(Object.keys(n).forEach(function(r){t.push([].concat(n[r],r))});s;){s=!1;for(let r=0;r<t.length;r++)for(let o=r+1;o<t.length;o++)if(t[r].filter(function(a){return t[o].indexOf(a)!==-1}).length){t[r]=t[r].concat(t[o]),t.splice(o,1),s=!0;break}}return t.forEach(function(r){r=r.filter(function(i,a,c){return c.indexOf(i)===a});let o=r.pop();o!==void 0&&typeof o=="string"&&(e[o]=r)}),e}function js(n){return n!==void 0?n+1:1}function Vr(n){return n==="__proto__"?"___proto___":n}function va(n){return typeof n=="string"&&(n[0]==="'"||n[0]==='"')&&n[n.length-1]===n[0]?n.substring(1,n.length-1):n}var Kr=require("fs");var Ss,Is,Ms,Gr=process&&process.env&&process.env.YARGS_MIN_NODE_VERSION?Number(process.env.YARGS_MIN_NODE_VERSION):12,Yr=(Is=(Ss=process==null?void 0:process.versions)===null||Ss===void 0?void 0:Ss.node)!==null&&Is!==void 0?Is:(Ms=process==null?void 0:process.version)===null||Ms===void 0?void 0:Ms.slice(1);if(Yr&&Number(Yr.match(/^([^.]+)/)[1])<Gr)throw Error(`yargs parser supports a minimum Node.js version of ${Gr}. Read our version support policy: https://github.com/yargs/yargs-parser#supported-nodejs-versions`);var Oa=process?process.env:{},Qr=new wn({cwd:process.cwd,env:()=>Oa,format:Jr.format,normalize:An.normalize,resolve:An.resolve,require:n=>{if(typeof require<"u")return require(n);if(n.match(/\.json$/))return JSON.parse((0,Kr.readFileSync)(n,"utf8"));throw Error("only .json config files are supported in ESM")}}),ze=function(t,e){return Qr.parse(t.slice(),e).argv};ze.detailed=function(n,t){return Qr.parse(n.slice(),t)};ze.camelCase=oe;ze.decamelize=bn;ze.looksLikeNumber=yn;var Zr=ze;var kt=require("path");function _a(){return ja()?0:1}function ja(){return Sa()&&!process.defaultApp}function Sa(){return!!process.versions.electron}function Xr(){return process.argv[_a()]}var Y=class n extends Error{constructor(t){super(t||"yargs error"),this.name="YError",Error.captureStackTrace&&Error.captureStackTrace(this,n)}};var je=require("fs"),to=require("util"),eo=require("path"),no={fs:{readFileSync:je.readFileSync,writeFile:je.writeFile},format:to.format,resolve:eo.resolve,exists:n=>{try{return(0,je.statSync)(n).isFile()}catch{return!1}}};var Wt,Ps=class{constructor(t){t=t||{},this.directory=t.directory||"./locales",this.updateFiles=typeof t.updateFiles=="boolean"?t.updateFiles:!0,this.locale=t.locale||"en",this.fallbackToLanguage=typeof t.fallbackToLanguage=="boolean"?t.fallbackToLanguage:!0,this.cache=Object.create(null),this.writeQueue=[]}__(...t){if(typeof arguments[0]!="string")return this._taggedLiteral(arguments[0],...arguments);let e=t.shift(),s=function(){};return typeof t[t.length-1]=="function"&&(s=t.pop()),s=s||function(){},this.cache[this.locale]||this._readLocaleFile(),!this.cache[this.locale][e]&&this.updateFiles?(this.cache[this.locale][e]=e,this._enqueueWrite({directory:this.directory,locale:this.locale,cb:s})):s(),Wt.format.apply(Wt.format,[this.cache[this.locale][e]||e].concat(t))}__n(){let t=Array.prototype.slice.call(arguments),e=t.shift(),s=t.shift(),r=t.shift(),o=function(){};typeof t[t.length-1]=="function"&&(o=t.pop()),this.cache[this.locale]||this._readLocaleFile();let i=r===1?e:s;this.cache[this.locale][e]&&(i=this.cache[this.locale][e][r===1?"one":"other"]),!this.cache[this.locale][e]&&this.updateFiles?(this.cache[this.locale][e]={one:e,other:s},this._enqueueWrite({directory:this.directory,locale:this.locale,cb:o})):o();let a=[i];return~i.indexOf("%d")&&a.push(r),Wt.format.apply(Wt.format,a.concat(t))}setLocale(t){this.locale=t}getLocale(){return this.locale}updateLocale(t){this.cache[this.locale]||this._readLocaleFile();for(let e in t)Object.prototype.hasOwnProperty.call(t,e)&&(this.cache[this.locale][e]=t[e])}_taggedLiteral(t,...e){let s="";return t.forEach(function(r,o){let i=e[o+1];s+=r,typeof i<"u"&&(s+="%s")}),this.__.apply(this,[s].concat([].slice.call(e,1)))}_enqueueWrite(t){this.writeQueue.push(t),this.writeQueue.length===1&&this._processWriteQueue()}_processWriteQueue(){let t=this,e=this.writeQueue[0],s=e.directory,r=e.locale,o=e.cb,i=this._resolveLocaleFile(s,r),a=JSON.stringify(this.cache[r],null,2);Wt.fs.writeFile(i,a,"utf-8",function(c){t.writeQueue.shift(),t.writeQueue.length>0&&t._processWriteQueue(),o(c)})}_readLocaleFile(){let t={},e=this._resolveLocaleFile(this.directory,this.locale);try{Wt.fs.readFileSync&&(t=JSON.parse(Wt.fs.readFileSync(e,"utf-8")))}catch(s){if(s instanceof SyntaxError&&(s.message="syntax error in "+e),s.code==="ENOENT")t={};else throw s}this.cache[this.locale]=t}_resolveLocaleFile(t,e){let s=Wt.resolve(t,"./",e+".json");if(this.fallbackToLanguage&&!this._fileExistsSync(s)&&~e.lastIndexOf("_")){let r=Wt.resolve(t,"./",e.split("_")[0]+".json");this._fileExistsSync(r)&&(s=r)}return s}_fileExistsSync(t){return Wt.exists(t)}};function so(n,t){Wt=t;let e=new Ps(n);return{__:e.__.bind(e),__n:e.__n.bind(e),setLocale:e.setLocale.bind(e),getLocale:e.getLocale.bind(e),updateLocale:e.updateLocale.bind(e),locale:e.locale}}var Ia=n=>so(n,no),io=Ia;var Wa={},Ma="require is not supported by ESM",ro="loading a directory of commands is not supported yet for ESM",qe;try{qe=(0,ao.fileURLToPath)(Wa.url)}catch{qe=process.cwd()}var Pa=qe.substring(0,qe.lastIndexOf("node_modules")),co={assert:{notStrictEqual:$n.notStrictEqual,strictEqual:$n.strictEqual},cliui:_s,findUp:Hr,getEnv:n=>process.env[n],inspect:oo.inspect,getCallerFile:()=>{throw new Y(ro)},getProcessArgvBin:Xr,mainFilename:Pa||process.cwd(),Parser:Zr,path:{basename:kt.basename,dirname:kt.dirname,extname:kt.extname,relative:kt.relative,resolve:kt.resolve},process:{argv:()=>process.argv,cwd:process.cwd,emitWarning:(n,t)=>process.emitWarning(n,t),execPath:()=>process.execPath,exit:process.exit,nextTick:process.nextTick,stdColumns:typeof process.stdout.columns<"u"?process.stdout.columns:null},readFileSync:uo.readFileSync,require:()=>{throw new Y(Ma)},requireDirectory:()=>{throw new Y(ro)},stringWidth:n=>[...n].length,y18n:io({directory:(0,kt.resolve)(qe,"../../../locales"),updateFiles:!1})};function Ft(n,t,e,s){e.assert.notStrictEqual(n,t,s)}function Ws(n,t){t.assert.strictEqual(typeof n,"string")}function Se(n){return Object.keys(n)}function J(n){return!!n&&!!n.then&&typeof n.then=="function"}function Yt(n){let e=n.replace(/\s{2,}/g," ").split(/\s+(?![^[]*]|[^<]*>)/),s=/\.*[\][<>]/g,r=e.shift();if(!r)throw new Error(`No command found in: ${n}`);let o={cmd:r.replace(s,""),demanded:[],optional:[]};return e.forEach((i,a)=>{let c=!1;i=i.replace(/\s/g,""),/\.+[\]>]/.test(i)&&a===e.length-1&&(c=!0),/^\[/.test(i)?o.optional.push({cmd:i.replace(s,"").split("|"),variadic:c}):o.demanded.push({cmd:i.replace(s,"").split("|"),variadic:c})}),o}var ka=["first","second","third","fourth","fifth","sixth"];function x(n,t,e){function s(){return typeof n=="object"?[{demanded:[],optional:[]},n,t]:[Yt(`cmd ${n}`),t,e]}try{let r=0,[o,i,a]=s(),c=[].slice.call(i);for(;c.length&&c[c.length-1]===void 0;)c.pop();let h=a||c.length;if(h<o.demanded.length)throw new Y(`Not enough arguments provided. Expected ${o.demanded.length} but received ${c.length}.`);let f=o.demanded.length+o.optional.length;if(h>f)throw new Y(`Too many arguments provided. Expected max ${f} but received ${h}.`);o.demanded.forEach(l=>{let m=c.shift(),C=lo(m);l.cmd.filter(b=>b===C||b==="*").length===0&&Do(C,l.cmd,r),r+=1}),o.optional.forEach(l=>{if(c.length===0)return;let m=c.shift(),C=lo(m);l.cmd.filter(b=>b===C||b==="*").length===0&&Do(C,l.cmd,r),r+=1})}catch(r){console.warn(r.stack)}}function lo(n){return Array.isArray(n)?"array":n===null?"null":typeof n}function Do(n,t,e){throw new Y(`Invalid ${ka[e]||"manyith"} argument. Expected ${t.join(" or ")} but received ${n}.`)}var xn=class{constructor(t){this.globalMiddleware=[],this.frozens=[],this.yargs=t}addMiddleware(t,e,s=!0,r=!1){if(x("<array|function> [boolean] [boolean] [boolean]",[t,e,s],arguments.length),Array.isArray(t)){for(let o=0;o<t.length;o++){if(typeof t[o]!="function")throw Error("middleware must be a function");let i=t[o];i.applyBeforeValidation=e,i.global=s}Array.prototype.push.apply(this.globalMiddleware,t)}else if(typeof t=="function"){let o=t;o.applyBeforeValidation=e,o.global=s,o.mutates=r,this.globalMiddleware.push(t)}return this.yargs}addCoerceMiddleware(t,e){let s=this.yargs.getAliases();return this.globalMiddleware=this.globalMiddleware.filter(r=>{let o=[...s[e]||[],e];return r.option?!o.includes(r.option):!0}),t.option=e,this.addMiddleware(t,!0,!0,!0)}getMiddleware(){return this.globalMiddleware}freeze(){this.frozens.push([...this.globalMiddleware])}unfreeze(){let t=this.frozens.pop();t!==void 0&&(this.globalMiddleware=t)}reset(){this.globalMiddleware=this.globalMiddleware.filter(t=>t.global)}};function ho(n){return n?n.map(t=>(t.applyBeforeValidation=!1,t)):[]}function ue(n,t,e,s){return e.reduce((r,o)=>{if(o.applyBeforeValidation!==s)return r;if(o.mutates){if(o.applied)return r;o.applied=!0}if(J(r))return r.then(i=>Promise.all([i,o(i,t)])).then(([i,a])=>Object.assign(i,a));{let i=o(r,t);return J(i)?i.then(a=>Object.assign(r,a)):Object.assign(r,i)}},n)}function ae(n,t,e=s=>{throw s}){try{let s=Ta(n)?n():n;return J(s)?s.then(r=>t(r)):t(s)}catch(s){return e(s)}}function Ta(n){return typeof n=="function"}function ks(n){if(typeof require>"u")return null;for(let t=0,e=Object.keys(require.cache),s;t<e.length;t++)if(s=require.cache[e[t]],s.exports===n)return s;return null}var Ie=/(^\*)|(^\$0)/,Ts=class{constructor(t,e,s,r){this.requireCache=new Set,this.handlers={},this.aliasMap={},this.frozens=[],this.shim=r,this.usage=t,this.globalMiddleware=s,this.validation=e}addDirectory(t,e,s,r){r=r||{},typeof r.recurse!="boolean"&&(r.recurse=!1),Array.isArray(r.extensions)||(r.extensions=["js"]);let o=typeof r.visit=="function"?r.visit:i=>i;r.visit=(i,a,c)=>{let h=o(i,a,c);if(h){if(this.requireCache.has(a))return h;this.requireCache.add(a),this.addHandler(h)}return h},this.shim.requireDirectory({require:e,filename:s},t,r)}addHandler(t,e,s,r,o,i){let a=[],c=ho(o);if(r=r||(()=>{}),Array.isArray(t))if(Na(t))[t,...a]=t;else for(let h of t)this.addHandler(h);else if(La(t)){let h=Array.isArray(t.command)||typeof t.command=="string"?t.command:this.moduleName(t);t.aliases&&(h=[].concat(h).concat(t.aliases)),this.addHandler(h,this.extractDesc(t),t.builder,t.handler,t.middlewares,t.deprecated);return}else if(fo(s)){this.addHandler([t].concat(a),e,s.builder,s.handler,s.middlewares,s.deprecated);return}if(typeof t=="string"){let h=Yt(t);a=a.map(m=>Yt(m).cmd);let f=!1,l=[h.cmd].concat(a).filter(m=>Ie.test(m)?(f=!0,!1):!0);l.length===0&&f&&l.push("$0"),f&&(h.cmd=l[0],a=l.slice(1),t=t.replace(Ie,h.cmd)),a.forEach(m=>{this.aliasMap[m]=h.cmd}),e!==!1&&this.usage.command(t,e,f,a,i),this.handlers[h.cmd]={original:t,description:e,handler:r,builder:s||{},middlewares:c,deprecated:i,demanded:h.demanded,optional:h.optional},f&&(this.defaultCommand=this.handlers[h.cmd])}}getCommandHandlers(){return this.handlers}getCommands(){return Object.keys(this.handlers).concat(Object.keys(this.aliasMap))}hasDefaultCommand(){return!!this.defaultCommand}runCommand(t,e,s,r,o,i){let a=this.handlers[t]||this.handlers[this.aliasMap[t]]||this.defaultCommand,c=e.getInternalMethods().getContext(),h=c.commands.slice(),f=!t;t&&(c.commands.push(t),c.fullCommands.push(a.original));let l=this.applyBuilderUpdateUsageAndParse(f,a,e,s.aliases,h,r,o,i);return J(l)?l.then(m=>this.applyMiddlewareAndGetResult(f,a,m.innerArgv,c,o,m.aliases,e)):this.applyMiddlewareAndGetResult(f,a,l.innerArgv,c,o,l.aliases,e)}applyBuilderUpdateUsageAndParse(t,e,s,r,o,i,a,c){let h=e.builder,f=s;if(Bn(h)){s.getInternalMethods().getUsageInstance().freeze();let l=h(s.getInternalMethods().reset(r),c);if(J(l))return l.then(m=>(f=mo(m)?m:s,this.parseAndUpdateUsage(t,e,f,o,i,a)))}else Ra(h)&&(s.getInternalMethods().getUsageInstance().freeze(),f=s.getInternalMethods().reset(r),Object.keys(e.builder).forEach(l=>{f.option(l,h[l])}));return this.parseAndUpdateUsage(t,e,f,o,i,a)}parseAndUpdateUsage(t,e,s,r,o,i){t&&s.getInternalMethods().getUsageInstance().unfreeze(!0),this.shouldUpdateUsage(s)&&s.getInternalMethods().getUsageInstance().usage(this.usageFromParentCommandsCommandHandler(r,e),e.description);let a=s.getInternalMethods().runYargsParserAndExecuteCommands(null,void 0,!0,o,i);return J(a)?a.then(c=>({aliases:s.parsed.aliases,innerArgv:c})):{aliases:s.parsed.aliases,innerArgv:a}}shouldUpdateUsage(t){return!t.getInternalMethods().getUsageInstance().getUsageDisabled()&&t.getInternalMethods().getUsageInstance().getUsage().length===0}usageFromParentCommandsCommandHandler(t,e){let s=Ie.test(e.original)?e.original.replace(Ie,"").trim():e.original,r=t.filter(o=>!Ie.test(o));return r.push(s),`$0 ${r.join(" ")}`}handleValidationAndGetResult(t,e,s,r,o,i,a,c){if(!i.getInternalMethods().getHasOutput()){let h=i.getInternalMethods().runValidation(o,c,i.parsed.error,t);s=ae(s,f=>(h(f),f))}if(e.handler&&!i.getInternalMethods().getHasOutput()){i.getInternalMethods().setHasOutput();let h=!!i.getOptions().configuration["populate--"];i.getInternalMethods().postProcess(s,h,!1,!1),s=ue(s,i,a,!1),s=ae(s,f=>{let l=e.handler(f);return J(l)?l.then(()=>f):f}),t||i.getInternalMethods().getUsageInstance().cacheHelpMessage(),J(s)&&!i.getInternalMethods().hasParseCallback()&&s.catch(f=>{try{i.getInternalMethods().getUsageInstance().fail(null,f)}catch{}})}return t||(r.commands.pop(),r.fullCommands.pop()),s}applyMiddlewareAndGetResult(t,e,s,r,o,i,a){let c={};if(o)return s;a.getInternalMethods().getHasOutput()||(c=this.populatePositionals(e,s,r,a));let h=this.globalMiddleware.getMiddleware().slice(0).concat(e.middlewares),f=ue(s,a,h,!0);return J(f)?f.then(l=>this.handleValidationAndGetResult(t,e,l,r,i,a,h,c)):this.handleValidationAndGetResult(t,e,f,r,i,a,h,c)}populatePositionals(t,e,s,r){e._=e._.slice(s.commands.length);let o=t.demanded.slice(0),i=t.optional.slice(0),a={};for(this.validation.positionalCount(o.length,e._.length);o.length;){let c=o.shift();this.populatePositional(c,e,a)}for(;i.length;){let c=i.shift();this.populatePositional(c,e,a)}return e._=s.commands.concat(e._.map(c=>""+c)),this.postProcessPositionals(e,a,this.cmdToParseOptions(t.original),r),a}populatePositional(t,e,s){let r=t.cmd[0];t.variadic?s[r]=e._.splice(0).map(String):e._.length&&(s[r]=[String(e._.shift())])}cmdToParseOptions(t){let e={array:[],default:{},alias:{},demand:{}},s=Yt(t);return s.demanded.forEach(r=>{let[o,...i]=r.cmd;r.variadic&&(e.array.push(o),e.default[o]=[]),e.alias[o]=i,e.demand[o]=!0}),s.optional.forEach(r=>{let[o,...i]=r.cmd;r.variadic&&(e.array.push(o),e.default[o]=[]),e.alias[o]=i}),e}postProcessPositionals(t,e,s,r){let o=Object.assign({},r.getOptions());o.default=Object.assign(s.default,o.default);for(let h of Object.keys(s.alias))o.alias[h]=(o.alias[h]||[]).concat(s.alias[h]);o.array=o.array.concat(s.array),o.config={};let i=[];if(Object.keys(e).forEach(h=>{e[h].map(f=>{o.configuration["unknown-options-as-args"]&&(o.key[h]=!0),i.push(`--${h}`),i.push(f)})}),!i.length)return;let a=Object.assign({},o.configuration,{"populate--":!1}),c=this.shim.Parser.detailed(i,Object.assign({},o,{configuration:a}));if(c.error)r.getInternalMethods().getUsageInstance().fail(c.error.message,c.error);else{let h=Object.keys(e);Object.keys(e).forEach(f=>{h.push(...c.aliases[f])}),Object.keys(c.argv).forEach(f=>{h.includes(f)&&(e[f]||(e[f]=c.argv[f]),!this.isInConfigs(r,f)&&!this.isDefaulted(r,f)&&Object.prototype.hasOwnProperty.call(t,f)&&Object.prototype.hasOwnProperty.call(c.argv,f)&&(Array.isArray(t[f])||Array.isArray(c.argv[f]))?t[f]=[].concat(t[f],c.argv[f]):t[f]=c.argv[f])})}}isDefaulted(t,e){let{default:s}=t.getOptions();return Object.prototype.hasOwnProperty.call(s,e)||Object.prototype.hasOwnProperty.call(s,this.shim.Parser.camelCase(e))}isInConfigs(t,e){let{configObjects:s}=t.getOptions();return s.some(r=>Object.prototype.hasOwnProperty.call(r,e))||s.some(r=>Object.prototype.hasOwnProperty.call(r,this.shim.Parser.camelCase(e)))}runDefaultBuilderOn(t){if(!this.defaultCommand)return;if(this.shouldUpdateUsage(t)){let s=Ie.test(this.defaultCommand.original)?this.defaultCommand.original:this.defaultCommand.original.replace(/^[^[\]<>]*/,"$0 ");t.getInternalMethods().getUsageInstance().usage(s,this.defaultCommand.description)}let e=this.defaultCommand.builder;if(Bn(e))return e(t,!0);fo(e)||Object.keys(e).forEach(s=>{t.option(s,e[s])})}moduleName(t){let e=ks(t);if(!e)throw new Error(`No command name given for module: ${this.shim.inspect(t)}`);return this.commandFromFilename(e.filename)}commandFromFilename(t){return this.shim.path.basename(t,this.shim.path.extname(t))}extractDesc({describe:t,description:e,desc:s}){for(let r of[t,e,s]){if(typeof r=="string"||r===!1)return r;Ft(r,!0,this.shim)}return!1}freeze(){this.frozens.push({handlers:this.handlers,aliasMap:this.aliasMap,defaultCommand:this.defaultCommand})}unfreeze(){let t=this.frozens.pop();Ft(t,void 0,this.shim),{handlers:this.handlers,aliasMap:this.aliasMap,defaultCommand:this.defaultCommand}=t}reset(){return this.handlers={},this.aliasMap={},this.defaultCommand=void 0,this.requireCache=new Set,this}};function po(n,t,e,s){return new Ts(n,t,e,s)}function fo(n){return typeof n=="object"&&!!n.builder&&typeof n.handler=="function"}function Na(n){return n.every(t=>typeof t=="string")}function Bn(n){return typeof n=="function"}function Ra(n){return typeof n=="object"}function La(n){return typeof n=="object"&&!Array.isArray(n)}function Jt(n={},t=()=>!0){let e={};return Se(n).forEach(s=>{t(s,n[s])&&(e[s]=n[s])}),e}function Kt(n){typeof process>"u"||[process.stdout,process.stderr].forEach(t=>{let e=t;e._handle&&e.isTTY&&typeof e._handle.setBlocking=="function"&&e._handle.setBlocking(n)})}function za(n){return typeof n=="boolean"}function Co(n,t){let e=t.y18n.__,s={},r=[];s.failFn=function(A){r.push(A)};let o=null,i=null,a=!0;s.showHelpOnFail=function(A=!0,v){let[N,q]=typeof A=="string"?[!0,A]:[A,v];return n.getInternalMethods().isGlobalContext()&&(i=q),o=q,a=N,s};let c=!1;s.fail=function(A,v){let N=n.getInternalMethods().getLoggerInstance();if(r.length)for(let q=r.length-1;q>=0;--q){let lt=r[q];if(za(lt)){if(v)throw v;if(A)throw Error(A)}else lt(A,v,s)}else{if(n.getExitProcess()&&Kt(!0),!c){c=!0,a&&(n.showHelp("error"),N.error()),(A||v)&&N.error(A||v);let q=o||i;q&&((A||v)&&N.error(""),N.error(q))}if(v=v||new Y(A),n.getExitProcess())return n.exit(1);if(n.getInternalMethods().hasParseCallback())return n.exit(1,v);throw v}};let h=[],f=!1;s.usage=(j,A)=>j===null?(f=!0,h=[],s):(f=!1,h.push([j,A||""]),s),s.getUsage=()=>h,s.getUsageDisabled=()=>f,s.getPositionalGroupName=()=>e("Positionals:");let l=[];s.example=(j,A)=>{l.push([j,A||""])};let m=[];s.command=function(A,v,N,q,lt=!1){N&&(m=m.map(z=>(z[2]=!1,z))),m.push([A,v||"",N,q,lt])},s.getCommands=()=>m;let C={};s.describe=function(A,v){Array.isArray(A)?A.forEach(N=>{s.describe(N,v)}):typeof A=="object"?Object.keys(A).forEach(N=>{s.describe(N,A[N])}):C[A]=v},s.getDescriptions=()=>C;let E=[];s.epilog=j=>{E.push(j)};let b=!1,g;s.wrap=j=>{b=!0,g=j},s.getWrap=()=>t.getEnv("YARGS_DISABLE_WRAP")?null:(b||(g=Fe(),b=!0),g);let O="__yargsString__:";s.deferY18nLookup=j=>O+j,s.help=function(){if(L)return L;H();let A=n.customScriptName?n.$0:t.path.basename(n.$0),v=n.getDemandedOptions(),N=n.getDemandedCommands(),q=n.getDeprecatedOptions(),lt=n.getGroups(),z=n.getOptions(),Dt=[];Dt=Dt.concat(Object.keys(C)),Dt=Dt.concat(Object.keys(v)),Dt=Dt.concat(Object.keys(N)),Dt=Dt.concat(Object.keys(z.default)),Dt=Dt.filter(qt),Dt=Object.keys(Dt.reduce((M,K)=>(K!=="_"&&(M[K]=!0),M),{}));let ee=s.getWrap(),X=t.cliui({width:ee,wrap:!!ee});if(!f){if(h.length)h.forEach(M=>{X.div({text:`${M[0].replace(/\$0/g,A)}`}),M[1]&&X.div({text:`${M[1]}`,padding:[1,0,0,0]})}),X.div();else if(m.length){let M=null;N._?M=`${A} <${e("command")}>
|
|
106
|
+
`:M=`${A} [${e("command")}]
|
|
107
|
+
`,X.div(`${M}`)}}if(m.length>1||m.length===1&&!m[0][2]){X.div(e("Commands:"));let M=n.getInternalMethods().getContext(),K=M.commands.length?`${M.commands.join(" ")} `:"";n.getInternalMethods().getParserConfiguration()["sort-commands"]===!0&&(m=m.sort((R,st)=>R[0].localeCompare(st[0])));let nt=A?`${A} `:"";m.forEach(R=>{let st=`${nt}${K}${R[0].replace(/^\$0 ?/,"")}`;X.span({text:st,padding:[0,2,0,2],width:T(m,ee,`${A}${K}`)+4},{text:R[1]});let ot=[];R[2]&&ot.push(`[${e("default")}]`),R[3]&&R[3].length&&ot.push(`[${e("aliases:")} ${R[3].join(", ")}]`),R[4]&&(typeof R[4]=="string"?ot.push(`[${e("deprecated: %s",R[4])}]`):ot.push(`[${e("deprecated")}]`)),ot.length?X.div({text:ot.join(" "),padding:[0,0,0,2],align:"right"}):X.div()}),X.div()}let Rt=(Object.keys(z.alias)||[]).concat(Object.keys(n.parsed.newAliases)||[]);Dt=Dt.filter(M=>!n.parsed.newAliases[M]&&Rt.every(K=>(z.alias[K]||[]).indexOf(M)===-1));let Lt=e("Options:");lt[Lt]||(lt[Lt]=[]),U(Dt,z.alias,lt,Lt);let ne=M=>/^--/.test(vn(M)),P=Object.keys(lt).filter(M=>lt[M].length>0).map(M=>{let K=lt[M].filter(qt).map(nt=>{if(Rt.includes(nt))return nt;for(let R=0,st;(st=Rt[R])!==void 0;R++)if((z.alias[st]||[]).includes(nt))return st;return nt});return{groupName:M,normalizedKeys:K}}).filter(({normalizedKeys:M})=>M.length>0).map(({groupName:M,normalizedKeys:K})=>{let nt=K.reduce((R,st)=>(R[st]=[st].concat(z.alias[st]||[]).map(ot=>M===s.getPositionalGroupName()?ot:(/^[0-9]$/.test(ot)?z.boolean.includes(st)?"-":"--":ot.length>1?"--":"-")+ot).sort((ot,Mt)=>ne(ot)===ne(Mt)?0:ne(ot)?1:-1).join(", "),R),{});return{groupName:M,normalizedKeys:K,switches:nt}});if(P.filter(({groupName:M})=>M!==s.getPositionalGroupName()).some(({normalizedKeys:M,switches:K})=>!M.every(nt=>ne(K[nt])))&&P.filter(({groupName:M})=>M!==s.getPositionalGroupName()).forEach(({normalizedKeys:M,switches:K})=>{M.forEach(nt=>{ne(K[nt])&&(K[nt]=qa(K[nt],4))})}),P.forEach(({groupName:M,normalizedKeys:K,switches:nt})=>{X.div(M),K.forEach(R=>{let st=nt[R],ot=C[R]||"",Mt=null;ot.includes(O)&&(ot=e(ot.substring(O.length))),z.boolean.includes(R)&&(Mt=`[${e("boolean")}]`),z.count.includes(R)&&(Mt=`[${e("count")}]`),z.string.includes(R)&&(Mt=`[${e("string")}]`),z.normalize.includes(R)&&(Mt=`[${e("string")}]`),z.array.includes(R)&&(Mt=`[${e("array")}]`),z.number.includes(R)&&(Mt=`[${e("number")}]`);let Pt=d=>typeof d=="string"?`[${e("deprecated: %s",d)}]`:`[${e("deprecated")}]`,Ge=[R in q?Pt(q[R]):null,Mt,R in v?`[${e("required")}]`:null,z.choices&&z.choices[R]?`[${e("choices:")} ${s.stringifiedValues(z.choices[R])}]`:null,It(z.default[R],z.defaultDescription[R])].filter(Boolean).join(" ");X.span({text:vn(st),padding:[0,2,0,2+go(st)],width:T(nt,ee)+4},ot);let D=n.getInternalMethods().getUsageConfiguration()["hide-types"]===!0;Ge&&!D?X.div({text:Ge,padding:[0,0,0,2],align:"right"}):X.div()}),X.div()}),l.length&&(X.div(e("Examples:")),l.forEach(M=>{M[0]=M[0].replace(/\$0/g,A)}),l.forEach(M=>{M[1]===""?X.div({text:M[0],padding:[0,2,0,2]}):X.div({text:M[0],padding:[0,2,0,2],width:T(l,ee)+4},{text:M[1]})}),X.div()),E.length>0){let M=E.map(K=>K.replace(/\$0/g,A)).join(`
|
|
108
|
+
`);X.div(`${M}
|
|
109
|
+
`)}return X.toString().replace(/\s*$/,"")};function T(j,A,v){let N=0;return Array.isArray(j)||(j=Object.values(j).map(q=>[q])),j.forEach(q=>{N=Math.max(t.stringWidth(v?`${v} ${vn(q[0])}`:vn(q[0]))+go(q[0]),N)}),A&&(N=Math.min(N,parseInt((A*.5).toString(),10))),N}function H(){let j=n.getDemandedOptions(),A=n.getOptions();(Object.keys(A.alias)||[]).forEach(v=>{A.alias[v].forEach(N=>{C[N]&&s.describe(v,C[N]),N in j&&n.demandOption(v,j[N]),A.boolean.includes(N)&&n.boolean(v),A.count.includes(N)&&n.count(v),A.string.includes(N)&&n.string(v),A.normalize.includes(N)&&n.normalize(v),A.array.includes(N)&&n.array(v),A.number.includes(N)&&n.number(v)})})}let L;s.cacheHelpMessage=function(){L=this.help()},s.clearCachedHelpMessage=function(){L=void 0},s.hasCachedHelpMessage=function(){return!!L};function U(j,A,v,N){let q=[],lt=null;return Object.keys(v).forEach(z=>{q=q.concat(v[z])}),j.forEach(z=>{lt=[z].concat(A[z]),lt.some(Dt=>q.indexOf(Dt)!==-1)||v[N].push(z)}),q}function qt(j){return n.getOptions().hiddenOptions.indexOf(j)<0||n.parsed.argv[n.getOptions().showHiddenOpt]}s.showHelp=j=>{let A=n.getInternalMethods().getLoggerInstance();j||(j="error"),(typeof j=="function"?j:A[j])(s.help())},s.functionDescription=j=>["(",j.name?t.Parser.decamelize(j.name,"-"):e("generated-value"),")"].join(""),s.stringifiedValues=function(A,v){let N="",q=v||", ",lt=[].concat(A);return!A||!lt.length||lt.forEach(z=>{N.length&&(N+=q),N+=JSON.stringify(z)}),N};function It(j,A){let v=`[${e("default:")} `;if(j===void 0&&!A)return null;if(A)v+=A;else switch(typeof j){case"string":v+=`"${j}"`;break;case"object":v+=JSON.stringify(j);break;default:v+=j}return`${v}]`}function Fe(){return t.process.stdColumns?Math.min(80,t.process.stdColumns):80}let te=null;s.version=j=>{te=j},s.showVersion=j=>{let A=n.getInternalMethods().getLoggerInstance();j||(j="error"),(typeof j=="function"?j:A[j])(te)},s.reset=function(A){return o=null,c=!1,h=[],f=!1,E=[],l=[],m=[],C=Jt(C,v=>!A[v]),s};let V=[];return s.freeze=function(){V.push({failMessage:o,failureOutput:c,usages:h,usageDisabled:f,epilogs:E,examples:l,commands:m,descriptions:C})},s.unfreeze=function(A=!1){let v=V.pop();v&&(A?(C={...v.descriptions,...C},m=[...v.commands,...m],h=[...v.usages,...h],l=[...v.examples,...l],E=[...v.epilogs,...E]):{failMessage:o,failureOutput:c,usages:h,usageDisabled:f,epilogs:E,examples:l,commands:m,descriptions:C}=v)},s}function Ns(n){return typeof n=="object"}function qa(n,t){return Ns(n)?{text:n.text,indentation:n.indentation+t}:{text:n,indentation:t}}function go(n){return Ns(n)?n.indentation:0}function vn(n){return Ns(n)?n.text:n}var Fo=`###-begin-{{app_name}}-completions-###
|
|
113
110
|
#
|
|
114
111
|
# yargs command completion script
|
|
115
112
|
#
|
|
@@ -137,7 +134,7 @@ _{{app_name}}_yargs_completions()
|
|
|
137
134
|
}
|
|
138
135
|
complete -o bashdefault -o default -F _{{app_name}}_yargs_completions {{app_name}}
|
|
139
136
|
###-end-{{app_name}}-completions-###
|
|
140
|
-
`,
|
|
137
|
+
`,Eo=`#compdef {{app_name}}
|
|
141
138
|
###-begin-{{app_name}}-completions-###
|
|
142
139
|
#
|
|
143
140
|
# yargs command completion script
|
|
@@ -156,14 +153,14 @@ _{{app_name}}_yargs_completions()
|
|
|
156
153
|
}
|
|
157
154
|
compdef _{{app_name}}_yargs_completions {{app_name}}
|
|
158
155
|
###-end-{{app_name}}-completions-###
|
|
159
|
-
`;var
|
|
156
|
+
`;var Rs=class{constructor(t,e,s,r){var o,i,a;this.yargs=t,this.usage=e,this.command=s,this.shim=r,this.completionKey="get-yargs-completions",this.aliases=null,this.customCompletionFunction=null,this.indexAfterLastReset=0,this.zshShell=(a=((o=this.shim.getEnv("SHELL"))===null||o===void 0?void 0:o.includes("zsh"))||((i=this.shim.getEnv("ZSH_NAME"))===null||i===void 0?void 0:i.includes("zsh")))!==null&&a!==void 0?a:!1}defaultCompletion(t,e,s,r){let o=this.command.getCommandHandlers();for(let a=0,c=t.length;a<c;++a)if(o[t[a]]&&o[t[a]].builder){let h=o[t[a]].builder;if(Bn(h)){this.indexAfterLastReset=a+1;let f=this.yargs.getInternalMethods().reset();return h(f,!0),f.argv}}let i=[];this.commandCompletions(i,t,s),this.optionCompletions(i,t,e,s),this.choicesFromOptionsCompletions(i,t,e,s),this.choicesFromPositionalsCompletions(i,t,e,s),r(null,i)}commandCompletions(t,e,s){let r=this.yargs.getInternalMethods().getContext().commands;!s.match(/^-/)&&r[r.length-1]!==s&&!this.previousArgHasChoices(e)&&this.usage.getCommands().forEach(o=>{let i=Yt(o[0]).cmd;if(e.indexOf(i)===-1)if(!this.zshShell)t.push(i);else{let a=o[1]||"";t.push(i.replace(/:/g,"\\:")+":"+a)}})}optionCompletions(t,e,s,r){if((r.match(/^-/)||r===""&&t.length===0)&&!this.previousArgHasChoices(e)){let o=this.yargs.getOptions(),i=this.yargs.getGroups()[this.usage.getPositionalGroupName()]||[];Object.keys(o.key).forEach(a=>{let c=!!o.configuration["boolean-negation"]&&o.boolean.includes(a);!i.includes(a)&&!o.hiddenOptions.includes(a)&&!this.argsContainKey(e,a,c)&&this.completeOptionKey(a,t,r,c&&!!o.default[a])})}}choicesFromOptionsCompletions(t,e,s,r){if(this.previousArgHasChoices(e)){let o=this.getPreviousArgChoices(e);o&&o.length>0&&t.push(...o.map(i=>i.replace(/:/g,"\\:")))}}choicesFromPositionalsCompletions(t,e,s,r){if(r===""&&t.length>0&&this.previousArgHasChoices(e))return;let o=this.yargs.getGroups()[this.usage.getPositionalGroupName()]||[],i=Math.max(this.indexAfterLastReset,this.yargs.getInternalMethods().getContext().commands.length+1),a=o[s._.length-i-1];if(!a)return;let c=this.yargs.getOptions().choices[a]||[];for(let h of c)h.startsWith(r)&&t.push(h.replace(/:/g,"\\:"))}getPreviousArgChoices(t){if(t.length<1)return;let e=t[t.length-1],s="";if(!e.startsWith("-")&&t.length>1&&(s=e,e=t[t.length-2]),!e.startsWith("-"))return;let r=e.replace(/^-+/,""),o=this.yargs.getOptions(),i=[r,...this.yargs.getAliases()[r]||[]],a;for(let c of i)if(Object.prototype.hasOwnProperty.call(o.key,c)&&Array.isArray(o.choices[c])){a=o.choices[c];break}if(a)return a.filter(c=>!s||c.startsWith(s))}previousArgHasChoices(t){let e=this.getPreviousArgChoices(t);return e!==void 0&&e.length>0}argsContainKey(t,e,s){let r=o=>t.indexOf((/^[^0-9]$/.test(o)?"-":"--")+o)!==-1;if(r(e)||s&&r(`no-${e}`))return!0;if(this.aliases){for(let o of this.aliases[e])if(r(o))return!0}return!1}completeOptionKey(t,e,s,r){var o,i,a,c;let h=t;if(this.zshShell){let C=this.usage.getDescriptions(),E=(i=(o=this===null||this===void 0?void 0:this.aliases)===null||o===void 0?void 0:o[t])===null||i===void 0?void 0:i.find(O=>{let T=C[O];return typeof T=="string"&&T.length>0}),b=E?C[E]:void 0,g=(c=(a=C[t])!==null&&a!==void 0?a:b)!==null&&c!==void 0?c:"";h=`${t.replace(/:/g,"\\:")}:${g.replace("__yargsString__:","").replace(/(\r\n|\n|\r)/gm," ")}`}let f=C=>/^--/.test(C),l=C=>/^[^0-9]$/.test(C),m=!f(s)&&l(t)?"-":"--";e.push(m+h),r&&e.push(m+"no-"+h)}customCompletion(t,e,s,r){if(Ft(this.customCompletionFunction,null,this.shim),Ua(this.customCompletionFunction)){let o=this.customCompletionFunction(s,e);return J(o)?o.then(i=>{this.shim.process.nextTick(()=>{r(null,i)})}).catch(i=>{this.shim.process.nextTick(()=>{r(i,void 0)})}):r(null,o)}else return Va(this.customCompletionFunction)?this.customCompletionFunction(s,e,(o=r)=>this.defaultCompletion(t,e,s,o),o=>{r(null,o)}):this.customCompletionFunction(s,e,o=>{r(null,o)})}getCompletion(t,e){let s=t.length?t[t.length-1]:"",r=this.yargs.parse(t,!0),o=this.customCompletionFunction?i=>this.customCompletion(t,i,s,e):i=>this.defaultCompletion(t,i,s,e);return J(r)?r.then(o):o(r)}generateCompletionScript(t,e){let s=this.zshShell?Eo:Fo,r=this.shim.path.basename(t);return t.match(/\.js$/)&&(t=`./${t}`),s=s.replace(/{{app_name}}/g,r),s=s.replace(/{{completion_command}}/g,e),s.replace(/{{app_path}}/g,t)}registerFunction(t){this.customCompletionFunction=t}setParsed(t){this.aliases=t.aliases}};function bo(n,t,e,s){return new Rs(n,t,e,s)}function Ua(n){return n.length<3}function Va(n){return n.length>3}function yo(n,t){if(n.length===0)return t.length;if(t.length===0)return n.length;let e=[],s;for(s=0;s<=t.length;s++)e[s]=[s];let r;for(r=0;r<=n.length;r++)e[0][r]=r;for(s=1;s<=t.length;s++)for(r=1;r<=n.length;r++)t.charAt(s-1)===n.charAt(r-1)?e[s][r]=e[s-1][r-1]:s>1&&r>1&&t.charAt(s-2)===n.charAt(r-1)&&t.charAt(s-1)===n.charAt(r-2)?e[s][r]=e[s-2][r-2]+1:e[s][r]=Math.min(e[s-1][r-1]+1,Math.min(e[s][r-1]+1,e[s-1][r]+1));return e[t.length][n.length]}var wo=["$0","--","_"];function Ao(n,t,e){let s=e.y18n.__,r=e.y18n.__n,o={};o.nonOptionCount=function(l){let m=n.getDemandedCommands(),E=l._.length+(l["--"]?l["--"].length:0)-n.getInternalMethods().getContext().commands.length;m._&&(E<m._.min||E>m._.max)&&(E<m._.min?m._.minMsg!==void 0?t.fail(m._.minMsg?m._.minMsg.replace(/\$0/g,E.toString()).replace(/\$1/,m._.min.toString()):null):t.fail(r("Not enough non-option arguments: got %s, need at least %s","Not enough non-option arguments: got %s, need at least %s",E,E.toString(),m._.min.toString())):E>m._.max&&(m._.maxMsg!==void 0?t.fail(m._.maxMsg?m._.maxMsg.replace(/\$0/g,E.toString()).replace(/\$1/,m._.max.toString()):null):t.fail(r("Too many non-option arguments: got %s, maximum of %s","Too many non-option arguments: got %s, maximum of %s",E,E.toString(),m._.max.toString()))))},o.positionalCount=function(l,m){m<l&&t.fail(r("Not enough non-option arguments: got %s, need at least %s","Not enough non-option arguments: got %s, need at least %s",m,m+"",l+""))},o.requiredArguments=function(l,m){let C=null;for(let E of Object.keys(m))(!Object.prototype.hasOwnProperty.call(l,E)||typeof l[E]>"u")&&(C=C||{},C[E]=m[E]);if(C){let E=[];for(let g of Object.keys(C)){let O=C[g];O&&E.indexOf(O)<0&&E.push(O)}let b=E.length?`
|
|
160
157
|
${E.join(`
|
|
161
|
-
`)}`:"";t.fail(r("Missing required argument: %s","Missing required arguments: %s",Object.keys(C).length,Object.keys(C).join(", ")+b))}},o.unknownArguments=function(
|
|
162
|
-
${s("Argument: %s, Given: %s, Choices: %s",g,t.stringifiedValues(C[g]),t.stringifiedValues(m.choices[g]))}`}),t.fail(b)};let i={};o.implies=function(
|
|
163
|
-
`;m.forEach(E=>{C+=E}),t.fail(C)}};let l={};o.conflicts=function(D,m){x("<string|object> [array|string]",[D,m],arguments.length),typeof D=="object"?Object.keys(D).forEach(C=>{o.conflicts(C,D[C])}):(n.global(D),l[D]||(l[D]=[]),Array.isArray(m)?m.forEach(C=>o.conflicts(D,C)):l[D].push(m))},o.getConflicting=()=>l,o.conflicting=function(D){Object.keys(D).forEach(m=>{l[m]&&l[m].forEach(C=>{C&&D[m]!==void 0&&D[C]!==void 0&&t.fail(s("Arguments %s and %s are mutually exclusive",m,C))})}),n.getInternalMethods().getParserConfiguration()["strip-dashed"]&&Object.keys(l).forEach(m=>{l[m].forEach(C=>{C&&D[e.Parser.camelCase(m)]!==void 0&&D[e.Parser.camelCase(C)]!==void 0&&t.fail(s("Arguments %s and %s are mutually exclusive",m,C))})})},o.recommendCommands=function(D,m){m=m.sort((g,O)=>O.length-g.length);let E=null,b=1/0;for(let g=0,O;(O=m[g])!==void 0;g++){let T=Co(D,O);T<=3&&T<b&&(b=T,E=O)}E&&t.fail(s("Did you mean %s?",E))},o.reset=function(D){return i=Jt(i,m=>!D[m]),l=Jt(l,m=>!D[m]),o};let h=[];return o.freeze=function(){h.push({implied:i,conflicting:l})},o.unfreeze=function(){let D=h.pop();Ft(D,void 0,e),{implied:i,conflicting:l}=D},o}var Rs=[],qe;function vn(n,t,e,s){qe=s;let r={};if(Object.prototype.hasOwnProperty.call(n,"extends")){if(typeof n.extends!="string")return r;let o=/\.json|\..*rc$/.test(n.extends),i=null;if(o)i=La(t,n.extends);else try{i=require.resolve(n.extends)}catch{return n}Ra(i),Rs.push(i),r=o?JSON.parse(qe.readFileSync(i,"utf8")):require(n.extends),delete n.extends,r=vn(r,qe.path.dirname(i),e,qe)}return Rs=[],e?Eo(r,n):Object.assign({},r,n)}function Ra(n){if(Rs.indexOf(n)>-1)throw new G(`Circular extended configurations: '${n}'.`)}function La(n,t){return qe.path.resolve(n,t)}function Eo(n,t){let e={};function s(r){return r&&typeof r=="object"&&!Array.isArray(r)}Object.assign(e,n);for(let r of Object.keys(t))s(t[r])&&s(e[r])?e[r]=Eo(n[r],t[r]):e[r]=t[r];return e}var B=function(n,t,e,s,r){if(s==="m")throw new TypeError("Private method is not writable");if(s==="a"&&!r)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?n!==t||!r:!t.has(n))throw new TypeError("Cannot write private member to an object whose class did not declare it");return s==="a"?r.call(n,e):r?r.value=e:t.set(n,e),e},u=function(n,t,e,s){if(e==="a"&&!s)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?n!==t||!s:!t.has(n))throw new TypeError("Cannot read private member from an object whose class did not declare it");return e==="m"?s:e==="a"?s.call(n):s?s.value:t.get(n)},ct,ce,He,Ot,wt,On,Qt,le,_n,_t,jn,jt,Tt,At,St,Sn,Se,ft,S,In,Pn,$t,De,Ie,he,Zt,Mn,W,fe,pe,de,k,Wn,Nt,rt;function Lo(n){return(t=[],e=n.process.cwd(),s)=>{let r=new Qs(t,e,s,n);return Object.defineProperty(r,"argv",{get:()=>r.parse(),enumerable:!0}),r.help(),r.version(),r}}var yo=Symbol("copyDoubleDash"),wo=Symbol("copyDoubleDash"),Ls=Symbol("deleteFromParserHintObject"),Ao=Symbol("emitWarning"),$o=Symbol("freeze"),xo=Symbol("getDollarZero"),me=Symbol("getParserConfiguration"),Bo=Symbol("getUsageConfiguration"),zs=Symbol("guessLocale"),vo=Symbol("guessVersion"),Oo=Symbol("parsePositionalNumbers"),qs=Symbol("pkgUp"),Xt=Symbol("populateParserHintArray"),Pe=Symbol("populateParserHintSingleValueDictionary"),Hs=Symbol("populateParserHintArrayDictionary"),Us=Symbol("populateParserHintDictionary"),Vs=Symbol("sanitizeKey"),Ys=Symbol("setKey"),Gs=Symbol("unfreeze"),_o=Symbol("validateAsync"),jo=Symbol("getCommandInstance"),So=Symbol("getContext"),Io=Symbol("getHasOutput"),Po=Symbol("getLoggerInstance"),Mo=Symbol("getParseContext"),Wo=Symbol("getUsageInstance"),ko=Symbol("getValidationInstance"),kn=Symbol("hasParseCallback"),To=Symbol("isGlobalContext"),ge=Symbol("postProcess"),No=Symbol("rebase"),Js=Symbol("reset"),Ue=Symbol("runYargsParserAndExecuteCommands"),Ks=Symbol("runValidation"),Ro=Symbol("setHasOutput"),Ce=Symbol("kTrackManuallySetKeys"),Qs=class{constructor(t=[],e,s,r){this.customScriptName=!1,this.parsed=!1,ct.set(this,void 0),ce.set(this,void 0),He.set(this,{commands:[],fullCommands:[]}),Ot.set(this,null),wt.set(this,null),On.set(this,"show-hidden"),Qt.set(this,null),le.set(this,!0),_n.set(this,{}),_t.set(this,!0),jn.set(this,[]),jt.set(this,void 0),Tt.set(this,{}),At.set(this,!1),St.set(this,null),Sn.set(this,!0),Se.set(this,void 0),ft.set(this,""),S.set(this,void 0),In.set(this,void 0),Pn.set(this,{}),$t.set(this,null),De.set(this,null),Ie.set(this,{}),he.set(this,{}),Zt.set(this,void 0),Mn.set(this,!1),W.set(this,void 0),fe.set(this,!1),pe.set(this,!1),de.set(this,!1),k.set(this,void 0),Wn.set(this,{}),Nt.set(this,null),rt.set(this,void 0),B(this,W,r,"f"),B(this,Zt,t,"f"),B(this,ce,e,"f"),B(this,In,s,"f"),B(this,jt,new $n(this),"f"),this.$0=this[xo](),this[Js](),B(this,ct,u(this,ct,"f"),"f"),B(this,k,u(this,k,"f"),"f"),B(this,rt,u(this,rt,"f"),"f"),B(this,S,u(this,S,"f"),"f"),u(this,S,"f").showHiddenOpt=u(this,On,"f"),B(this,Se,this[wo](),"f")}addHelpOpt(t,e){let s="help";return x("[string|boolean] [string]",[t,e],arguments.length),u(this,St,"f")&&(this[Ls](u(this,St,"f")),B(this,St,null,"f")),t===!1&&e===void 0?this:(B(this,St,typeof t=="string"?t:s,"f"),this.boolean(u(this,St,"f")),this.describe(u(this,St,"f"),e||u(this,k,"f").deferY18nLookup("Show help")),this)}help(t,e){return this.addHelpOpt(t,e)}addShowHiddenOpt(t,e){if(x("[string|boolean] [string]",[t,e],arguments.length),t===!1&&e===void 0)return this;let s=typeof t=="string"?t:u(this,On,"f");return this.boolean(s),this.describe(s,e||u(this,k,"f").deferY18nLookup("Show hidden options")),u(this,S,"f").showHiddenOpt=s,this}showHidden(t,e){return this.addShowHiddenOpt(t,e)}alias(t,e){return x("<object|string|array> [string|array]",[t,e],arguments.length),this[Hs](this.alias.bind(this),"alias",t,e),this}array(t){return x("<array|string>",[t],arguments.length),this[Xt]("array",t),this[Ce](t),this}boolean(t){return x("<array|string>",[t],arguments.length),this[Xt]("boolean",t),this[Ce](t),this}check(t,e){return x("<function> [boolean]",[t,e],arguments.length),this.middleware((s,r)=>ae(()=>t(s,r.getOptions()),o=>(o?(typeof o=="string"||o instanceof Error)&&u(this,k,"f").fail(o.toString(),o):u(this,k,"f").fail(u(this,W,"f").y18n.__("Argument check failed: %s",t.toString())),s),o=>(u(this,k,"f").fail(o.message?o.message:o.toString(),o),s)),!1,e),this}choices(t,e){return x("<object|string|array> [string|array]",[t,e],arguments.length),this[Hs](this.choices.bind(this),"choices",t,e),this}coerce(t,e){if(x("<object|string|array> [function]",[t,e],arguments.length),Array.isArray(t)){if(!e)throw new G("coerce callback must be provided");for(let s of t)this.coerce(s,e);return this}else if(typeof t=="object"){for(let s of Object.keys(t))this.coerce(s,t[s]);return this}if(!e)throw new G("coerce callback must be provided");return u(this,S,"f").key[t]=!0,u(this,jt,"f").addCoerceMiddleware((s,r)=>{let o;return Object.prototype.hasOwnProperty.call(s,t)?ae(()=>(o=r.getAliases(),e(s[t])),a=>{s[t]=a;let l=r.getInternalMethods().getParserConfiguration()["strip-aliased"];if(o[t]&&l!==!0)for(let h of o[t])s[h]=a;return s},a=>{throw new G(a.message)}):s},t),this}conflicts(t,e){return x("<string|object> [string|array]",[t,e],arguments.length),u(this,rt,"f").conflicts(t,e),this}config(t="config",e,s){return x("[object|string] [string|function] [function]",[t,e,s],arguments.length),typeof t=="object"&&!Array.isArray(t)?(t=vn(t,u(this,ce,"f"),this[me]()["deep-merge-config"]||!1,u(this,W,"f")),u(this,S,"f").configObjects=(u(this,S,"f").configObjects||[]).concat(t),this):(typeof e=="function"&&(s=e,e=void 0),this.describe(t,e||u(this,k,"f").deferY18nLookup("Path to JSON config file")),(Array.isArray(t)?t:[t]).forEach(r=>{u(this,S,"f").config[r]=s||!0}),this)}completion(t,e,s){return x("[string] [string|boolean|function] [function]",[t,e,s],arguments.length),typeof e=="function"&&(s=e,e=void 0),B(this,wt,t||u(this,wt,"f")||"completion","f"),!e&&e!==!1&&(e="generate completion script"),this.command(u(this,wt,"f"),e),s&&u(this,Ot,"f").registerFunction(s),this}command(t,e,s,r,o,i){return x("<string|array|object> [string|boolean] [function|object] [function] [array] [boolean|string]",[t,e,s,r,o,i],arguments.length),u(this,ct,"f").addHandler(t,e,s,r,o,i),this}commands(t,e,s,r,o,i){return this.command(t,e,s,r,o,i)}commandDir(t,e){x("<string> [object]",[t,e],arguments.length);let s=u(this,In,"f")||u(this,W,"f").require;return u(this,ct,"f").addDirectory(t,s,u(this,W,"f").getCallerFile(),e),this}count(t){return x("<array|string>",[t],arguments.length),this[Xt]("count",t),this[Ce](t),this}default(t,e,s){return x("<object|string|array> [*] [string]",[t,e,s],arguments.length),s&&(Ms(t,u(this,W,"f")),u(this,S,"f").defaultDescription[t]=s),typeof e=="function"&&(Ms(t,u(this,W,"f")),u(this,S,"f").defaultDescription[t]||(u(this,S,"f").defaultDescription[t]=u(this,k,"f").functionDescription(e)),e=e.call()),this[Pe](this.default.bind(this),"default",t,e),this}defaults(t,e,s){return this.default(t,e,s)}demandCommand(t=1,e,s,r){return x("[number] [number|string] [string|null|undefined] [string|null|undefined]",[t,e,s,r],arguments.length),typeof e!="number"&&(s=e,e=1/0),this.global("_",!1),u(this,S,"f").demandedCommands._={min:t,max:e,minMsg:s,maxMsg:r},this}demand(t,e,s){return Array.isArray(e)?(e.forEach(r=>{Ft(s,!0,u(this,W,"f")),this.demandOption(r,s)}),e=1/0):typeof e!="number"&&(s=e,e=1/0),typeof t=="number"?(Ft(s,!0,u(this,W,"f")),this.demandCommand(t,e,s,s)):Array.isArray(t)?t.forEach(r=>{Ft(s,!0,u(this,W,"f")),this.demandOption(r,s)}):typeof s=="string"?this.demandOption(t,s):(s===!0||typeof s>"u")&&this.demandOption(t),this}demandOption(t,e){return x("<object|string|array> [string]",[t,e],arguments.length),this[Pe](this.demandOption.bind(this),"demandedOptions",t,e),this}deprecateOption(t,e){return x("<string> [string|boolean]",[t,e],arguments.length),u(this,S,"f").deprecatedOptions[t]=e,this}describe(t,e){return x("<object|string|array> [string]",[t,e],arguments.length),this[Ys](t,!0),u(this,k,"f").describe(t,e),this}detectLocale(t){return x("<boolean>",[t],arguments.length),B(this,le,t,"f"),this}env(t){return x("[string|boolean]",[t],arguments.length),t===!1?delete u(this,S,"f").envPrefix:u(this,S,"f").envPrefix=t||"",this}epilogue(t){return x("<string>",[t],arguments.length),u(this,k,"f").epilog(t),this}epilog(t){return this.epilogue(t)}example(t,e){return x("<string|array> [string]",[t,e],arguments.length),Array.isArray(t)?t.forEach(s=>this.example(...s)):u(this,k,"f").example(t,e),this}exit(t,e){B(this,At,!0,"f"),B(this,Qt,e,"f"),u(this,_t,"f")&&u(this,W,"f").process.exit(t)}exitProcess(t=!0){return x("[boolean]",[t],arguments.length),B(this,_t,t,"f"),this}fail(t){if(x("<function|boolean>",[t],arguments.length),typeof t=="boolean"&&t!==!1)throw new G("Invalid first argument. Expected function or boolean 'false'");return u(this,k,"f").failFn(t),this}getAliases(){return this.parsed?this.parsed.aliases:{}}async getCompletion(t,e){return x("<array> [function]",[t,e],arguments.length),e?u(this,Ot,"f").getCompletion(t,e):new Promise((s,r)=>{u(this,Ot,"f").getCompletion(t,(o,i)=>{o?r(o):s(i)})})}getDemandedOptions(){return x([],0),u(this,S,"f").demandedOptions}getDemandedCommands(){return x([],0),u(this,S,"f").demandedCommands}getDeprecatedOptions(){return x([],0),u(this,S,"f").deprecatedOptions}getDetectLocale(){return u(this,le,"f")}getExitProcess(){return u(this,_t,"f")}getGroups(){return Object.assign({},u(this,Tt,"f"),u(this,he,"f"))}getHelp(){if(B(this,At,!0,"f"),!u(this,k,"f").hasCachedHelpMessage()){if(!this.parsed){let e=this[Ue](u(this,Zt,"f"),void 0,void 0,0,!0);if(J(e))return e.then(()=>u(this,k,"f").help())}let t=u(this,ct,"f").runDefaultBuilderOn(this);if(J(t))return t.then(()=>u(this,k,"f").help())}return Promise.resolve(u(this,k,"f").help())}getOptions(){return u(this,S,"f")}getStrict(){return u(this,fe,"f")}getStrictCommands(){return u(this,pe,"f")}getStrictOptions(){return u(this,de,"f")}global(t,e){return x("<string|array> [boolean]",[t,e],arguments.length),t=[].concat(t),e!==!1?u(this,S,"f").local=u(this,S,"f").local.filter(s=>t.indexOf(s)===-1):t.forEach(s=>{u(this,S,"f").local.includes(s)||u(this,S,"f").local.push(s)}),this}group(t,e){x("<string|array> <string>",[t,e],arguments.length);let s=u(this,he,"f")[e]||u(this,Tt,"f")[e];u(this,he,"f")[e]&&delete u(this,he,"f")[e];let r={};return u(this,Tt,"f")[e]=(s||[]).concat(t).filter(o=>r[o]?!1:r[o]=!0),this}hide(t){return x("<string>",[t],arguments.length),u(this,S,"f").hiddenOptions.push(t),this}implies(t,e){return x("<string|object> [number|string|array]",[t,e],arguments.length),u(this,rt,"f").implies(t,e),this}locale(t){return x("[string]",[t],arguments.length),t===void 0?(this[zs](),u(this,W,"f").y18n.getLocale()):(B(this,le,!1,"f"),u(this,W,"f").y18n.setLocale(t),this)}middleware(t,e,s){return u(this,jt,"f").addMiddleware(t,!!e,s)}nargs(t,e){return x("<string|object|array> [number]",[t,e],arguments.length),this[Pe](this.nargs.bind(this),"narg",t,e),this}normalize(t){return x("<array|string>",[t],arguments.length),this[Xt]("normalize",t),this}number(t){return x("<array|string>",[t],arguments.length),this[Xt]("number",t),this[Ce](t),this}option(t,e){if(x("<string|object> [object]",[t,e],arguments.length),typeof t=="object")Object.keys(t).forEach(s=>{this.options(s,t[s])});else{typeof e!="object"&&(e={}),this[Ce](t),u(this,Nt,"f")&&(t==="version"||(e==null?void 0:e.alias)==="version")&&this[Ao](['"version" is a reserved word.',"Please do one of the following:",'- Disable version with `yargs.version(false)` if using "version" as an option',"- Use the built-in `yargs.version` method instead (if applicable)","- Use a different option key","https://yargs.js.org/docs/#api-reference-version"].join(`
|
|
164
|
-
`),void 0,"versionWarning"),u(this,S,"f").key[t]=!0,e.alias&&this.alias(t,e.alias);let s=e.deprecate||e.deprecated;s&&this.deprecateOption(t,s);let r=e.demand||e.required||e.require;r&&this.demand(t,r),e.demandOption&&this.demandOption(t,typeof e.demandOption=="string"?e.demandOption:void 0),e.conflicts&&this.conflicts(t,e.conflicts),"default"in e&&this.default(t,e.default),e.implies!==void 0&&this.implies(t,e.implies),e.nargs!==void 0&&this.nargs(t,e.nargs),e.config&&this.config(t,e.configParser),e.normalize&&this.normalize(t),e.choices&&this.choices(t,e.choices),e.coerce&&this.coerce(t,e.coerce),e.group&&this.group(t,e.group),(e.boolean||e.type==="boolean")&&(this.boolean(t),e.alias&&this.boolean(e.alias)),(e.array||e.type==="array")&&(this.array(t),e.alias&&this.array(e.alias)),(e.number||e.type==="number")&&(this.number(t),e.alias&&this.number(e.alias)),(e.string||e.type==="string")&&(this.string(t),e.alias&&this.string(e.alias)),(e.count||e.type==="count")&&this.count(t),typeof e.global=="boolean"&&this.global(t,e.global),e.defaultDescription&&(u(this,S,"f").defaultDescription[t]=e.defaultDescription),e.skipValidation&&this.skipValidation(t);let o=e.describe||e.description||e.desc,i=u(this,k,"f").getDescriptions();(!Object.prototype.hasOwnProperty.call(i,t)||typeof o=="string")&&this.describe(t,o),e.hidden&&this.hide(t),e.requiresArg&&this.requiresArg(t)}return this}options(t,e){return this.option(t,e)}parse(t,e,s){x("[string|array] [function|boolean|object] [function]",[t,e,s],arguments.length),this[
|
|
165
|
-
`,"f"),B(this,ft,u(this,ft,"f")+t.join(" "),"f")},error:(...t)=>{this[
|
|
166
|
-
`,"f"),B(this,ft,u(this,ft,"f")+t.join(" "),"f")}}}[Ls](t){_e(u(this,S,"f")).forEach(e=>{if((r=>r==="configObjects")(e))return;let s=u(this,S,"f")[e];Array.isArray(s)?s.includes(t)&&s.splice(s.indexOf(t),1):typeof s=="object"&&delete s[t]}),delete u(this,k,"f").getDescriptions()[t]}[Ao](t,e,s){u(this,_n,"f")[s]||(u(this,W,"f").process.emitWarning(t,e),u(this,_n,"f")[s]=!0)}[$o](){u(this,jn,"f").push({options:u(this,S,"f"),configObjects:u(this,S,"f").configObjects.slice(0),exitProcess:u(this,_t,"f"),groups:u(this,Tt,"f"),strict:u(this,fe,"f"),strictCommands:u(this,pe,"f"),strictOptions:u(this,de,"f"),completionCommand:u(this,wt,"f"),output:u(this,ft,"f"),exitError:u(this,Qt,"f"),hasOutput:u(this,At,"f"),parsed:this.parsed,parseFn:u(this,$t,"f"),parseContext:u(this,De,"f")}),u(this,k,"f").freeze(),u(this,rt,"f").freeze(),u(this,ct,"f").freeze(),u(this,jt,"f").freeze()}[xo](){let t="",e;return/\b(node|iojs|electron)(\.exe)?$/.test(u(this,W,"f").process.argv()[0])?e=u(this,W,"f").process.argv().slice(1,2):e=u(this,W,"f").process.argv().slice(0,1),t=e.map(s=>{let r=this[No](u(this,ce,"f"),s);return s.match(/^(\/|([a-zA-Z]:)?\\)/)&&r.length<s.length?r:s}).join(" ").trim(),u(this,W,"f").getEnv("_")&&u(this,W,"f").getProcessArgvBin()===u(this,W,"f").getEnv("_")&&(t=u(this,W,"f").getEnv("_").replace(`${u(this,W,"f").path.dirname(u(this,W,"f").process.execPath())}/`,"")),t}[me](){return u(this,Pn,"f")}[Bo](){return u(this,Wn,"f")}[zs](){if(!u(this,le,"f"))return;let t=u(this,W,"f").getEnv("LC_ALL")||u(this,W,"f").getEnv("LC_MESSAGES")||u(this,W,"f").getEnv("LANG")||u(this,W,"f").getEnv("LANGUAGE")||"en_US";this.locale(t.replace(/[.:].*/,""))}[vo](){return this[qs]().version||"unknown"}[Oo](t){let e=t["--"]?t["--"]:t._;for(let s=0,r;(r=e[s])!==void 0;s++)u(this,W,"f").Parser.looksLikeNumber(r)&&Number.isSafeInteger(Math.floor(parseFloat(`${r}`)))&&(e[s]=Number(r));return t}[qs](t){let e=t||"*";if(u(this,Ie,"f")[e])return u(this,Ie,"f")[e];let s={};try{let r=t||u(this,W,"f").mainFilename;!t&&u(this,W,"f").path.extname(r)&&(r=u(this,W,"f").path.dirname(r));let o=u(this,W,"f").findUp(r,(i,a)=>{if(a.includes("package.json"))return"package.json"});Ft(o,void 0,u(this,W,"f")),s=JSON.parse(u(this,W,"f").readFileSync(o,"utf8"))}catch{}return u(this,Ie,"f")[e]=s||{},u(this,Ie,"f")[e]}[Xt](t,e){e=[].concat(e),e.forEach(s=>{s=this[Vs](s),u(this,S,"f")[t].push(s)})}[Pe](t,e,s,r){this[Us](t,e,s,r,(o,i,a)=>{u(this,S,"f")[o][i]=a})}[Hs](t,e,s,r){this[Us](t,e,s,r,(o,i,a)=>{u(this,S,"f")[o][i]=(u(this,S,"f")[o][i]||[]).concat(a)})}[Us](t,e,s,r,o){if(Array.isArray(s))s.forEach(i=>{t(i,r)});else if((i=>typeof i=="object")(s))for(let i of _e(s))t(i,s[i]);else o(e,this[Vs](s),r)}[Vs](t){return t==="__proto__"?"___proto___":t}[Ys](t,e){return this[Pe](this[Ys].bind(this),"key",t,e),this}[Gs](){var t,e,s,r,o,i,a,l,h,f,D,m;let C=u(this,jn,"f").pop();Ft(C,void 0,u(this,W,"f"));let E;t=this,e=this,s=this,r=this,o=this,i=this,a=this,l=this,h=this,f=this,D=this,m=this,{options:{set value(b){B(t,S,b,"f")}}.value,configObjects:E,exitProcess:{set value(b){B(e,_t,b,"f")}}.value,groups:{set value(b){B(s,Tt,b,"f")}}.value,output:{set value(b){B(r,ft,b,"f")}}.value,exitError:{set value(b){B(o,Qt,b,"f")}}.value,hasOutput:{set value(b){B(i,At,b,"f")}}.value,parsed:this.parsed,strict:{set value(b){B(a,fe,b,"f")}}.value,strictCommands:{set value(b){B(l,pe,b,"f")}}.value,strictOptions:{set value(b){B(h,de,b,"f")}}.value,completionCommand:{set value(b){B(f,wt,b,"f")}}.value,parseFn:{set value(b){B(D,$t,b,"f")}}.value,parseContext:{set value(b){B(m,De,b,"f")}}.value}=C,u(this,S,"f").configObjects=E,u(this,k,"f").unfreeze(),u(this,rt,"f").unfreeze(),u(this,ct,"f").unfreeze(),u(this,jt,"f").unfreeze()}[_o](t,e){return ae(e,s=>(t(s),s))}getInternalMethods(){return{getCommandInstance:this[jo].bind(this),getContext:this[So].bind(this),getHasOutput:this[Io].bind(this),getLoggerInstance:this[Po].bind(this),getParseContext:this[Mo].bind(this),getParserConfiguration:this[me].bind(this),getUsageConfiguration:this[Bo].bind(this),getUsageInstance:this[Wo].bind(this),getValidationInstance:this[ko].bind(this),hasParseCallback:this[kn].bind(this),isGlobalContext:this[To].bind(this),postProcess:this[ge].bind(this),reset:this[Js].bind(this),runValidation:this[Ks].bind(this),runYargsParserAndExecuteCommands:this[Ue].bind(this),setHasOutput:this[Ro].bind(this)}}[jo](){return u(this,ct,"f")}[So](){return u(this,He,"f")}[Io](){return u(this,At,"f")}[Po](){return u(this,Se,"f")}[Mo](){return u(this,De,"f")||{}}[Wo](){return u(this,k,"f")}[ko](){return u(this,rt,"f")}[kn](){return!!u(this,$t,"f")}[To](){return u(this,Sn,"f")}[ge](t,e,s,r){return s||J(t)||(e||(t=this[yo](t)),(this[me]()["parse-positional-numbers"]||this[me]()["parse-positional-numbers"]===void 0)&&(t=this[Oo](t)),r&&(t=ue(t,this,u(this,jt,"f").getMiddleware(),!1))),t}[Js](t={}){B(this,S,u(this,S,"f")||{},"f");let e={};e.local=u(this,S,"f").local||[],e.configObjects=u(this,S,"f").configObjects||[];let s={};e.local.forEach(i=>{s[i]=!0,(t[i]||[]).forEach(a=>{s[a]=!0})}),Object.assign(u(this,he,"f"),Object.keys(u(this,Tt,"f")).reduce((i,a)=>{let l=u(this,Tt,"f")[a].filter(h=>!(h in s));return l.length>0&&(i[a]=l),i},{})),B(this,Tt,{},"f");let r=["array","boolean","string","skipValidation","count","normalize","number","hiddenOptions"],o=["narg","key","alias","default","defaultDescription","config","choices","demandedOptions","demandedCommands","deprecatedOptions"];return r.forEach(i=>{e[i]=(u(this,S,"f")[i]||[]).filter(a=>!s[a])}),o.forEach(i=>{e[i]=Jt(u(this,S,"f")[i],a=>!s[a])}),e.envPrefix=u(this,S,"f").envPrefix,B(this,S,e,"f"),B(this,k,u(this,k,"f")?u(this,k,"f").reset(s):fo(this,u(this,W,"f")),"f"),B(this,rt,u(this,rt,"f")?u(this,rt,"f").reset(s):bo(this,u(this,k,"f"),u(this,W,"f")),"f"),B(this,ct,u(this,ct,"f")?u(this,ct,"f").reset():lo(u(this,k,"f"),u(this,rt,"f"),u(this,jt,"f"),u(this,W,"f")),"f"),u(this,Ot,"f")||B(this,Ot,go(this,u(this,k,"f"),u(this,ct,"f"),u(this,W,"f")),"f"),u(this,jt,"f").reset(),B(this,wt,null,"f"),B(this,ft,"","f"),B(this,Qt,null,"f"),B(this,At,!1,"f"),this.parsed=!1,this}[No](t,e){return u(this,W,"f").path.relative(t,e)}[Ue](t,e,s,r=0,o=!1){let i=!!s||o;t=t||u(this,Zt,"f"),u(this,S,"f").__=u(this,W,"f").y18n.__,u(this,S,"f").configuration=this[me]();let a=!!u(this,S,"f").configuration["populate--"],l=Object.assign({},u(this,S,"f").configuration,{"populate--":!0}),h=u(this,W,"f").Parser.detailed(t,Object.assign({},u(this,S,"f"),{configuration:{"parse-positional-numbers":!1,...l}})),f=Object.assign(h.argv,u(this,De,"f")),D,m=h.aliases,C=!1,E=!1;Object.keys(f).forEach(b=>{b===u(this,St,"f")&&f[b]?C=!0:b===u(this,Nt,"f")&&f[b]&&(E=!0)}),f.$0=this.$0,this.parsed=h,r===0&&u(this,k,"f").clearCachedHelpMessage();try{if(this[zs](),e)return this[ge](f,a,!!s,!1);u(this,St,"f")&&[u(this,St,"f")].concat(m[u(this,St,"f")]||[]).filter(H=>H.length>1).includes(""+f._[f._.length-1])&&(f._.pop(),C=!0),B(this,Sn,!1,"f");let b=u(this,ct,"f").getCommands(),g=u(this,Ot,"f").completionKey in f,O=C||g||o;if(f._.length){if(b.length){let T;for(let H=r||0,L;f._[H]!==void 0;H++)if(L=String(f._[H]),b.includes(L)&&L!==u(this,wt,"f")){let U=u(this,ct,"f").runCommand(L,this,h,H+1,o,C||E||o);return this[ge](U,a,!!s,!1)}else if(!T&&L!==u(this,wt,"f")){T=L;break}!u(this,ct,"f").hasDefaultCommand()&&u(this,Mn,"f")&&T&&!O&&u(this,rt,"f").recommendCommands(T,b)}u(this,wt,"f")&&f._.includes(u(this,wt,"f"))&&!g&&(u(this,_t,"f")&&Kt(!0),this.showCompletionScript(),this.exit(0))}if(u(this,ct,"f").hasDefaultCommand()&&!O){let T=u(this,ct,"f").runCommand(null,this,h,0,o,C||E||o);return this[ge](T,a,!!s,!1)}if(g){u(this,_t,"f")&&Kt(!0),t=[].concat(t);let T=t.slice(t.indexOf(`--${u(this,Ot,"f").completionKey}`)+1);return u(this,Ot,"f").getCompletion(T,(H,L)=>{if(H)throw new G(H.message);(L||[]).forEach(U=>{u(this,Se,"f").log(U)}),this.exit(0)}),this[ge](f,!a,!!s,!1)}if(u(this,At,"f")||(C?(u(this,_t,"f")&&Kt(!0),i=!0,this.showHelp("log"),this.exit(0)):E&&(u(this,_t,"f")&&Kt(!0),i=!0,u(this,k,"f").showVersion("log"),this.exit(0))),!i&&u(this,S,"f").skipValidation.length>0&&(i=Object.keys(f).some(T=>u(this,S,"f").skipValidation.indexOf(T)>=0&&f[T]===!0)),!i){if(h.error)throw new G(h.error.message);if(!g){let T=this[Ks](m,{},h.error);s||(D=ue(f,this,u(this,jt,"f").getMiddleware(),!0)),D=this[_o](T,D??f),J(D)&&!s&&(D=D.then(()=>ue(f,this,u(this,jt,"f").getMiddleware(),!1)))}}}catch(b){if(b instanceof G)u(this,k,"f").fail(b.message,b);else throw b}return this[ge](D??f,a,!!s,!0)}[Ks](t,e,s,r){let o={...this.getDemandedOptions()};return i=>{if(s)throw new G(s.message);u(this,rt,"f").nonOptionCount(i),u(this,rt,"f").requiredArguments(i,o);let a=!1;u(this,pe,"f")&&(a=u(this,rt,"f").unknownCommands(i)),u(this,fe,"f")&&!a?u(this,rt,"f").unknownArguments(i,t,e,!!r):u(this,de,"f")&&u(this,rt,"f").unknownArguments(i,t,{},!1,!1),u(this,rt,"f").limitedChoices(i),u(this,rt,"f").implications(i),u(this,rt,"f").conflicting(i)}}[Ro](){B(this,At,!0,"f")}[Ce](t){if(typeof t=="string")u(this,S,"f").key[t]=!0;else for(let e of t)u(this,S,"f").key[e]=!0}};function Do(n){return!!n&&typeof n.getInternalMethods=="function"}var za=Lo(ro),zo=za;function qa(n,t){return zo(n).strict().command("* <template> <outDir>","Create a new project powered by qwik",s=>s.positional("template",{type:"string",desc:"Starter template",choices:t}).positional("outDir",{type:"string",desc:"Directory of the project"}).option("force",{alias:"f",type:"boolean",default:!1,desc:"Overwrite target directory if it exists"}).option("installDeps",{alias:"i",default:!1,type:"boolean",desc:"Install dependencies"}).usage("npm create qwik@latest base ./my-project <options>")).argv}async function Xs(...n){let t=Yt(),e=await xe("app"),s=e.standaloneTemplates.map(({id:m})=>m),r=qa(n,s),{force:o,installDeps:i,template:a}=r,l=r.outDir;en(`Let's create a ${Te(" Qwik App ")} \u2728 (v1.2.10)`),Ha()?l=process.cwd():(l=mn(l),Zs.default.existsSync(l)&&Zs.default.readdirSync(l).length>0&&(o?await sn(l):(nt.error(`Directory "${l}" already exists.`),nt.info("Please either remove this directory, choose another location or run the command again with '--force | -f' flag."),se(),process.exit(1))));let h=await Be({outDir:l,appId:a,pkgManager:t,templateManager:e}),f=ye(),D=!1;return i&&(D=await pn(async()=>await re(t,l).install,{pkgManager:t,spinner:f})),dn(t,h,D),h}function Ha(){return Ua()}function Ua(){try{return process.cwd().startsWith("/home/projects/")}catch{}return!1}var Nn=require("path");var Tn=ut(require("fs"));var ti=[["Dad, can you put my shoes on?","I don't think they'll fit me."],["What do ghosts call their true love?","Their ghoul-friend"],["How do the trees get on the internet?","They log on."],["Lady: How do I spread love in this cruel world?","Random Dude: [...\u{1F498}]"],["How do you find Will Smith in the snow?"," Look for fresh prints."],["Why did the mushroom get invited to the party?","Because he was a fungi."],["Why is peter pan always flying?","Because he neverlands"],["How do you know if there\u2019s an elephant under your bed?","Your head hits the ceiling!"],["How do you fix a broken pizza?","With tomato paste."],["Why did the butcher work extra hours at the shop?","To make ends meat."],["What time is it?","I don't know... it keeps changing."],["What did the traffic light say to the car as it passed?","Don't look I'm changing!"],["What do you call someone with no nose?","Nobody knows."],["Why did the worker get fired from the orange juice factory?","Lack of concentration."],["What did the say to the ?","Nice belt."],["What animal is always at a game of cricket?","A bat."],["Why did the tomato blush?","Because it saw the salad dressing."],["What\u2019s E.T. short for?","He\u2019s only got little legs."],["What did the beaver say to the tree?","It's been nice gnawing you."],["What do you call a girl between two posts?","Annette."],["What do you call a boomerang that won't come back?","A stick."],["What do you do on a remote island?","Try and find the TV island it belongs to."],["Why did the barber win the race?","He took a short cut."],["Do you want a brief explanation of what an acorn is?","In a nutshell, it's an oak tree."],["What do you call a belt made out of watches?","A waist of time."],["How many lips does a flower have?","Tulips"],["Did you hear about the guy who invented Lifesavers?","They say he made a mint."],["I Got Hit In the Head By A Soda Can, But It Didn't Hurt That Much...","It was a soft drink."],["When a dad drives past a graveyard: Did you know that's a popular cemetery?","Yep, people are just dying to get in there"],["What did the fish say when it hit the wall?","Dam."],["Want to hear a joke about a piece of paper?","Never mind...it's tearable"],["What did the big flower say to the littler flower?","Hi, bud!"],["What has ears but cannot hear?","A field of corn."],["What's the best thing about elevator jokes?","They work on so many levels."],["Why can't your nose be inches long?","Because then it'd be a foot!"],["Why does Superman get invited to dinners?","Because he is a Supperhero."],["What's red and bad for your teeth?","A Brick."],["What's the difference between a guitar and a fish?",`You can tune a guitar but you can't "tuna"fish!`],["Why did the coffee file a police report?","It got mugged."],["What do you do when you see a space man?","Park your car, man."],["What do you give a sick lemon?","Lemonaid."],["Where do rabbits go after they get married?","On a bunny-moon."],["What creature is smarter than a talking parrot?","A spelling bee."],["How does the moon cut his hair?","Eclipse it."],["What do you get when you cross a chicken with a skunk?","A fowl smell!"],["Why do crabs never give to charity?","Because they\u2019re shellfish."],["did you know the first French fries weren't cooked in France?","they were cooked in Greece"],["Did you hear that the police have a warrant out on a midget psychic ripping people off?",'It reads "Small medium at large."'],["A termite walks into a bar and says...","'Where is the bar tended?'"],["Why do chicken coops only have two doors?","Because if they had four, they would be chicken sedans"],["What's the best thing about a Boolean?","Even if you're wrong, you're only off by a bit."],["If you put a million monkeys at a million keyboards, one of them will eventually write a Java program","the rest of them will write Perl"],["How many programmers does it take to change a lightbulb?","None that's a hardware problem"],["A user interface is like a joke.","If you have to explain it then it is not that good."],["['hip', 'hip']","(hip hip array)"],["A SQL query walks into a bar, walks up to two tables and asks...","'Can I join you?'"],["Which song would an exception sing?","Can't catch me - Avicii"],["Why do C# and Java developers keep breaking their keyboards?","Because they use a strongly typed language."],["What's the object-oriented way to become wealthy?","Inheritance"],["Where do programmers like to hangout?","The Foo Bar."],["Why do Java programmers wear glasses?","Because they don't C#"],["To understand what recursion is...","You must first understand what recursion is"],["The punchline often arrives before the set-up.","Do you know the problem with UDP jokes?"],["Why did the programmer quit his job?","Because he didn't get arrays."],["How do you check if a webpage is HTML?","Try it out on Internet Explorer"],["There are 10 types of people in this world...","Those who understand binary and those who don't"],["Why do programmers always mix up Halloween and Christmas?","Because Oct == Dec "],["I was gonna tell you a joke about UDP...","...but you might not get it."],["How do you get a squirrel to like you"," Act like a nut."],["Why did the math book look so sad"," Because of all of its problems!"],["What's the best way to watch a fly fishing tournament"," Live stream."],["Why couldn't the bicycle stand up by itself"," It was two tired."],["Why did the scarecrow win an award"," Because he was outstanding in his field."],["I ordered a chicken and an egg online. I\u2019ll let you know."," I\u2019ll let you know"],["How do you make a Kleenex dance"," Put a little boogie in it!"],["I'm reading a book about anti-gravity. It's impossible to put down!"," It's impossible to put down!"],["Why can't you hear a psychiatrist using the bathroom"," Because the 'P' is silent."],["I like telling Dad jokes. Sometimes he laughs!"," Sometimes he laughs!"],["I'm so good at sleeping, I can do it with my eyes closed!"," I can do it with my eyes closed!"],["How do you make a tissue dance"," You put a little boogie in it."],["What do you call cheese that isn't yours"," Nacho cheese."],["What kind of shoes do ninjas wear"," Sneakers!"],["What do you call a fake noodle"," An impasta."],["I made a pencil with two erasers. It was pointless."," It was pointless"],["I've got a great joke about construction, but I'm still working on it.",""],["Did I tell you the time I fell in love during a backflip"," I was heels over head!"],["What\u2019s an astronaut\u2019s favorite part of a computer"," The space bar."],["What time did the man go to the dentist"," Tooth hurt-y."],["It's inappropriate to make a 'dad joke' if you're not a dad. It's a faux pa."," It's a faux pa"],["What did the fish say when he hit the wall"," Dam."],["I don't trust stairs. They're always up to something."," They're always up to something"],["What do you call someone with no body and no nose"," Nobody knows."],["Did you hear the rumor about butter"," Well, I'm not going to spread it!"],["I used to hate facial hair...but then it grew on me.",null],["What's brown and sticky"," A stick."],["Can February March"," No, but April May!"],["Don't trust atoms. They make up everything!"," They make up everything!"],["Why don't eggs tell jokes"," They'd crack each other up."],["Did you hear about the circus fire"," It was in tents."],["How do lawyers say goodbye"," We'll be suing ya!"],["When does a joke become a dad joke"," When it becomes apparent."],["Wanna hear a joke about paper"," Never mind\u2014it's tearable."],["What did the coffee report to the police"," A mugging."],["Dad, can you put my shoes on","No, I don't think they'll fit me."],["How many tickles does it take to make an octopus laugh"," Ten tickles."],["Dad, did you get a haircut","No, I got them all cut!"],["My wife is really mad at the fact that I have no sense of direction."," So I packed up my stuff and right!"],["Why do bees have sticky hair"," Because they use a honeycomb."],["Which state has the most streets"," Rhode Island."],["I'm on a seafood diet. I see food and I eat it."," I see food and I eat it"],["Did you hear about the guy who invented the knock-knock joke"," He won the 'no-bell' prize."],["How does a penguin build its house"," Igloos it together."],["What do you call an elephant that doesn't matter"," An irrelephant."],["I wouldn't buy anything with velcro. It's a total rip-off."," It's a total rip-off"],["Dad, can you put the cat out","I didn't know it was on fire."],["What concert costs just 45 cents"," 50 Cent featuring Nickelback!"],["Why are elevator jokes so classic and good"," They work on many levels."],["Is this pool safe for diving"," It deep ends."],[`Knock knock.
|
|
158
|
+
`)}`:"";t.fail(r("Missing required argument: %s","Missing required arguments: %s",Object.keys(C).length,Object.keys(C).join(", ")+b))}},o.unknownArguments=function(l,m,C,E,b=!0){var g;let O=n.getInternalMethods().getCommandInstance().getCommands(),T=[],H=n.getInternalMethods().getContext();if(Object.keys(l).forEach(L=>{!wo.includes(L)&&!Object.prototype.hasOwnProperty.call(C,L)&&!Object.prototype.hasOwnProperty.call(n.getInternalMethods().getParseContext(),L)&&!o.isValidAndSomeAliasIsNotNew(L,m)&&T.push(L)}),b&&(H.commands.length>0||O.length>0||E)&&l._.slice(H.commands.length).forEach(L=>{O.includes(""+L)||T.push(""+L)}),b){let U=((g=n.getDemandedCommands()._)===null||g===void 0?void 0:g.max)||0,qt=H.commands.length+U;qt<l._.length&&l._.slice(qt).forEach(It=>{It=String(It),!H.commands.includes(It)&&!T.includes(It)&&T.push(It)})}T.length&&t.fail(r("Unknown argument: %s","Unknown arguments: %s",T.length,T.map(L=>L.trim()?L:`"${L}"`).join(", ")))},o.unknownCommands=function(l){let m=n.getInternalMethods().getCommandInstance().getCommands(),C=[],E=n.getInternalMethods().getContext();return(E.commands.length>0||m.length>0)&&l._.slice(E.commands.length).forEach(b=>{m.includes(""+b)||C.push(""+b)}),C.length>0?(t.fail(r("Unknown command: %s","Unknown commands: %s",C.length,C.join(", "))),!0):!1},o.isValidAndSomeAliasIsNotNew=function(l,m){if(!Object.prototype.hasOwnProperty.call(m,l))return!1;let C=n.parsed.newAliases;return[l,...m[l]].some(E=>!Object.prototype.hasOwnProperty.call(C,E)||!C[l])},o.limitedChoices=function(l){let m=n.getOptions(),C={};if(!Object.keys(m.choices).length)return;Object.keys(l).forEach(g=>{wo.indexOf(g)===-1&&Object.prototype.hasOwnProperty.call(m.choices,g)&&[].concat(l[g]).forEach(O=>{m.choices[g].indexOf(O)===-1&&O!==void 0&&(C[g]=(C[g]||[]).concat(O))})});let E=Object.keys(C);if(!E.length)return;let b=s("Invalid values:");E.forEach(g=>{b+=`
|
|
159
|
+
${s("Argument: %s, Given: %s, Choices: %s",g,t.stringifiedValues(C[g]),t.stringifiedValues(m.choices[g]))}`}),t.fail(b)};let i={};o.implies=function(l,m){x("<string|object> [array|number|string]",[l,m],arguments.length),typeof l=="object"?Object.keys(l).forEach(C=>{o.implies(C,l[C])}):(n.global(l),i[l]||(i[l]=[]),Array.isArray(m)?m.forEach(C=>o.implies(l,C)):(Ft(m,void 0,e),i[l].push(m)))},o.getImplied=function(){return i};function a(f,l){let m=Number(l);return l=isNaN(m)?l:m,typeof l=="number"?l=f._.length>=l:l.match(/^--no-.+/)?(l=l.match(/^--no-(.+)/)[1],l=!Object.prototype.hasOwnProperty.call(f,l)):l=Object.prototype.hasOwnProperty.call(f,l),l}o.implications=function(l){let m=[];if(Object.keys(i).forEach(C=>{let E=C;(i[C]||[]).forEach(b=>{let g=E,O=b;g=a(l,g),b=a(l,b),g&&!b&&m.push(` ${E} -> ${O}`)})}),m.length){let C=`${s("Implications failed:")}
|
|
160
|
+
`;m.forEach(E=>{C+=E}),t.fail(C)}};let c={};o.conflicts=function(l,m){x("<string|object> [array|string]",[l,m],arguments.length),typeof l=="object"?Object.keys(l).forEach(C=>{o.conflicts(C,l[C])}):(n.global(l),c[l]||(c[l]=[]),Array.isArray(m)?m.forEach(C=>o.conflicts(l,C)):c[l].push(m))},o.getConflicting=()=>c,o.conflicting=function(l){Object.keys(l).forEach(m=>{c[m]&&c[m].forEach(C=>{C&&l[m]!==void 0&&l[C]!==void 0&&t.fail(s("Arguments %s and %s are mutually exclusive",m,C))})}),n.getInternalMethods().getParserConfiguration()["strip-dashed"]&&Object.keys(c).forEach(m=>{c[m].forEach(C=>{C&&l[e.Parser.camelCase(m)]!==void 0&&l[e.Parser.camelCase(C)]!==void 0&&t.fail(s("Arguments %s and %s are mutually exclusive",m,C))})})},o.recommendCommands=function(l,m){m=m.sort((g,O)=>O.length-g.length);let E=null,b=1/0;for(let g=0,O;(O=m[g])!==void 0;g++){let T=yo(l,O);T<=3&&T<b&&(b=T,E=O)}E&&t.fail(s("Did you mean %s?",E))},o.reset=function(l){return i=Jt(i,m=>!l[m]),c=Jt(c,m=>!l[m]),o};let h=[];return o.freeze=function(){h.push({implied:i,conflicting:c})},o.unfreeze=function(){let l=h.pop();Ft(l,void 0,e),{implied:i,conflicting:c}=l},o}var Ls=[],He;function On(n,t,e,s){He=s;let r={};if(Object.prototype.hasOwnProperty.call(n,"extends")){if(typeof n.extends!="string")return r;let o=/\.json|\..*rc$/.test(n.extends),i=null;if(o)i=Ya(t,n.extends);else try{i=require.resolve(n.extends)}catch{return n}Ga(i),Ls.push(i),r=o?JSON.parse(He.readFileSync(i,"utf8")):require(n.extends),delete n.extends,r=On(r,He.path.dirname(i),e,He)}return Ls=[],e?$o(r,n):Object.assign({},r,n)}function Ga(n){if(Ls.indexOf(n)>-1)throw new Y(`Circular extended configurations: '${n}'.`)}function Ya(n,t){return He.path.resolve(n,t)}function $o(n,t){let e={};function s(r){return r&&typeof r=="object"&&!Array.isArray(r)}Object.assign(e,n);for(let r of Object.keys(t))s(t[r])&&s(e[r])?e[r]=$o(n[r],t[r]):e[r]=t[r];return e}var B=function(n,t,e,s,r){if(s==="m")throw new TypeError("Private method is not writable");if(s==="a"&&!r)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?n!==t||!r:!t.has(n))throw new TypeError("Cannot write private member to an object whose class did not declare it");return s==="a"?r.call(n,e):r?r.value=e:t.set(n,e),e},u=function(n,t,e,s){if(e==="a"&&!s)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?n!==t||!s:!t.has(n))throw new TypeError("Cannot read private member from an object whose class did not declare it");return e==="m"?s:e==="a"?s.call(n):s?s.value:t.get(n)},ct,ce,Ue,Ot,wt,_n,Qt,le,jn,_t,Sn,jt,Tt,At,St,In,Me,ft,S,Mn,Pn,$t,De,Pe,he,Zt,Wn,W,fe,pe,de,k,kn,Nt,rt;function Uo(n){return(t=[],e=n.process.cwd(),s)=>{let r=new Zs(t,e,s,n);return Object.defineProperty(r,"argv",{get:()=>r.parse(),enumerable:!0}),r.help(),r.version(),r}}var xo=Symbol("copyDoubleDash"),Bo=Symbol("copyDoubleDash"),zs=Symbol("deleteFromParserHintObject"),vo=Symbol("emitWarning"),Oo=Symbol("freeze"),_o=Symbol("getDollarZero"),me=Symbol("getParserConfiguration"),jo=Symbol("getUsageConfiguration"),qs=Symbol("guessLocale"),So=Symbol("guessVersion"),Io=Symbol("parsePositionalNumbers"),Hs=Symbol("pkgUp"),Xt=Symbol("populateParserHintArray"),We=Symbol("populateParserHintSingleValueDictionary"),Us=Symbol("populateParserHintArrayDictionary"),Vs=Symbol("populateParserHintDictionary"),Gs=Symbol("sanitizeKey"),Ys=Symbol("setKey"),Js=Symbol("unfreeze"),Mo=Symbol("validateAsync"),Po=Symbol("getCommandInstance"),Wo=Symbol("getContext"),ko=Symbol("getHasOutput"),To=Symbol("getLoggerInstance"),No=Symbol("getParseContext"),Ro=Symbol("getUsageInstance"),Lo=Symbol("getValidationInstance"),Tn=Symbol("hasParseCallback"),zo=Symbol("isGlobalContext"),ge=Symbol("postProcess"),qo=Symbol("rebase"),Ks=Symbol("reset"),Ve=Symbol("runYargsParserAndExecuteCommands"),Qs=Symbol("runValidation"),Ho=Symbol("setHasOutput"),Ce=Symbol("kTrackManuallySetKeys"),Zs=class{constructor(t=[],e,s,r){this.customScriptName=!1,this.parsed=!1,ct.set(this,void 0),ce.set(this,void 0),Ue.set(this,{commands:[],fullCommands:[]}),Ot.set(this,null),wt.set(this,null),_n.set(this,"show-hidden"),Qt.set(this,null),le.set(this,!0),jn.set(this,{}),_t.set(this,!0),Sn.set(this,[]),jt.set(this,void 0),Tt.set(this,{}),At.set(this,!1),St.set(this,null),In.set(this,!0),Me.set(this,void 0),ft.set(this,""),S.set(this,void 0),Mn.set(this,void 0),Pn.set(this,{}),$t.set(this,null),De.set(this,null),Pe.set(this,{}),he.set(this,{}),Zt.set(this,void 0),Wn.set(this,!1),W.set(this,void 0),fe.set(this,!1),pe.set(this,!1),de.set(this,!1),k.set(this,void 0),kn.set(this,{}),Nt.set(this,null),rt.set(this,void 0),B(this,W,r,"f"),B(this,Zt,t,"f"),B(this,ce,e,"f"),B(this,Mn,s,"f"),B(this,jt,new xn(this),"f"),this.$0=this[_o](),this[Ks](),B(this,ct,u(this,ct,"f"),"f"),B(this,k,u(this,k,"f"),"f"),B(this,rt,u(this,rt,"f"),"f"),B(this,S,u(this,S,"f"),"f"),u(this,S,"f").showHiddenOpt=u(this,_n,"f"),B(this,Me,this[Bo](),"f")}addHelpOpt(t,e){let s="help";return x("[string|boolean] [string]",[t,e],arguments.length),u(this,St,"f")&&(this[zs](u(this,St,"f")),B(this,St,null,"f")),t===!1&&e===void 0?this:(B(this,St,typeof t=="string"?t:s,"f"),this.boolean(u(this,St,"f")),this.describe(u(this,St,"f"),e||u(this,k,"f").deferY18nLookup("Show help")),this)}help(t,e){return this.addHelpOpt(t,e)}addShowHiddenOpt(t,e){if(x("[string|boolean] [string]",[t,e],arguments.length),t===!1&&e===void 0)return this;let s=typeof t=="string"?t:u(this,_n,"f");return this.boolean(s),this.describe(s,e||u(this,k,"f").deferY18nLookup("Show hidden options")),u(this,S,"f").showHiddenOpt=s,this}showHidden(t,e){return this.addShowHiddenOpt(t,e)}alias(t,e){return x("<object|string|array> [string|array]",[t,e],arguments.length),this[Us](this.alias.bind(this),"alias",t,e),this}array(t){return x("<array|string>",[t],arguments.length),this[Xt]("array",t),this[Ce](t),this}boolean(t){return x("<array|string>",[t],arguments.length),this[Xt]("boolean",t),this[Ce](t),this}check(t,e){return x("<function> [boolean]",[t,e],arguments.length),this.middleware((s,r)=>ae(()=>t(s,r.getOptions()),o=>(o?(typeof o=="string"||o instanceof Error)&&u(this,k,"f").fail(o.toString(),o):u(this,k,"f").fail(u(this,W,"f").y18n.__("Argument check failed: %s",t.toString())),s),o=>(u(this,k,"f").fail(o.message?o.message:o.toString(),o),s)),!1,e),this}choices(t,e){return x("<object|string|array> [string|array]",[t,e],arguments.length),this[Us](this.choices.bind(this),"choices",t,e),this}coerce(t,e){if(x("<object|string|array> [function]",[t,e],arguments.length),Array.isArray(t)){if(!e)throw new Y("coerce callback must be provided");for(let s of t)this.coerce(s,e);return this}else if(typeof t=="object"){for(let s of Object.keys(t))this.coerce(s,t[s]);return this}if(!e)throw new Y("coerce callback must be provided");return u(this,S,"f").key[t]=!0,u(this,jt,"f").addCoerceMiddleware((s,r)=>{let o;return Object.prototype.hasOwnProperty.call(s,t)?ae(()=>(o=r.getAliases(),e(s[t])),a=>{s[t]=a;let c=r.getInternalMethods().getParserConfiguration()["strip-aliased"];if(o[t]&&c!==!0)for(let h of o[t])s[h]=a;return s},a=>{throw new Y(a.message)}):s},t),this}conflicts(t,e){return x("<string|object> [string|array]",[t,e],arguments.length),u(this,rt,"f").conflicts(t,e),this}config(t="config",e,s){return x("[object|string] [string|function] [function]",[t,e,s],arguments.length),typeof t=="object"&&!Array.isArray(t)?(t=On(t,u(this,ce,"f"),this[me]()["deep-merge-config"]||!1,u(this,W,"f")),u(this,S,"f").configObjects=(u(this,S,"f").configObjects||[]).concat(t),this):(typeof e=="function"&&(s=e,e=void 0),this.describe(t,e||u(this,k,"f").deferY18nLookup("Path to JSON config file")),(Array.isArray(t)?t:[t]).forEach(r=>{u(this,S,"f").config[r]=s||!0}),this)}completion(t,e,s){return x("[string] [string|boolean|function] [function]",[t,e,s],arguments.length),typeof e=="function"&&(s=e,e=void 0),B(this,wt,t||u(this,wt,"f")||"completion","f"),!e&&e!==!1&&(e="generate completion script"),this.command(u(this,wt,"f"),e),s&&u(this,Ot,"f").registerFunction(s),this}command(t,e,s,r,o,i){return x("<string|array|object> [string|boolean] [function|object] [function] [array] [boolean|string]",[t,e,s,r,o,i],arguments.length),u(this,ct,"f").addHandler(t,e,s,r,o,i),this}commands(t,e,s,r,o,i){return this.command(t,e,s,r,o,i)}commandDir(t,e){x("<string> [object]",[t,e],arguments.length);let s=u(this,Mn,"f")||u(this,W,"f").require;return u(this,ct,"f").addDirectory(t,s,u(this,W,"f").getCallerFile(),e),this}count(t){return x("<array|string>",[t],arguments.length),this[Xt]("count",t),this[Ce](t),this}default(t,e,s){return x("<object|string|array> [*] [string]",[t,e,s],arguments.length),s&&(Ws(t,u(this,W,"f")),u(this,S,"f").defaultDescription[t]=s),typeof e=="function"&&(Ws(t,u(this,W,"f")),u(this,S,"f").defaultDescription[t]||(u(this,S,"f").defaultDescription[t]=u(this,k,"f").functionDescription(e)),e=e.call()),this[We](this.default.bind(this),"default",t,e),this}defaults(t,e,s){return this.default(t,e,s)}demandCommand(t=1,e,s,r){return x("[number] [number|string] [string|null|undefined] [string|null|undefined]",[t,e,s,r],arguments.length),typeof e!="number"&&(s=e,e=1/0),this.global("_",!1),u(this,S,"f").demandedCommands._={min:t,max:e,minMsg:s,maxMsg:r},this}demand(t,e,s){return Array.isArray(e)?(e.forEach(r=>{Ft(s,!0,u(this,W,"f")),this.demandOption(r,s)}),e=1/0):typeof e!="number"&&(s=e,e=1/0),typeof t=="number"?(Ft(s,!0,u(this,W,"f")),this.demandCommand(t,e,s,s)):Array.isArray(t)?t.forEach(r=>{Ft(s,!0,u(this,W,"f")),this.demandOption(r,s)}):typeof s=="string"?this.demandOption(t,s):(s===!0||typeof s>"u")&&this.demandOption(t),this}demandOption(t,e){return x("<object|string|array> [string]",[t,e],arguments.length),this[We](this.demandOption.bind(this),"demandedOptions",t,e),this}deprecateOption(t,e){return x("<string> [string|boolean]",[t,e],arguments.length),u(this,S,"f").deprecatedOptions[t]=e,this}describe(t,e){return x("<object|string|array> [string]",[t,e],arguments.length),this[Ys](t,!0),u(this,k,"f").describe(t,e),this}detectLocale(t){return x("<boolean>",[t],arguments.length),B(this,le,t,"f"),this}env(t){return x("[string|boolean]",[t],arguments.length),t===!1?delete u(this,S,"f").envPrefix:u(this,S,"f").envPrefix=t||"",this}epilogue(t){return x("<string>",[t],arguments.length),u(this,k,"f").epilog(t),this}epilog(t){return this.epilogue(t)}example(t,e){return x("<string|array> [string]",[t,e],arguments.length),Array.isArray(t)?t.forEach(s=>this.example(...s)):u(this,k,"f").example(t,e),this}exit(t,e){B(this,At,!0,"f"),B(this,Qt,e,"f"),u(this,_t,"f")&&u(this,W,"f").process.exit(t)}exitProcess(t=!0){return x("[boolean]",[t],arguments.length),B(this,_t,t,"f"),this}fail(t){if(x("<function|boolean>",[t],arguments.length),typeof t=="boolean"&&t!==!1)throw new Y("Invalid first argument. Expected function or boolean 'false'");return u(this,k,"f").failFn(t),this}getAliases(){return this.parsed?this.parsed.aliases:{}}async getCompletion(t,e){return x("<array> [function]",[t,e],arguments.length),e?u(this,Ot,"f").getCompletion(t,e):new Promise((s,r)=>{u(this,Ot,"f").getCompletion(t,(o,i)=>{o?r(o):s(i)})})}getDemandedOptions(){return x([],0),u(this,S,"f").demandedOptions}getDemandedCommands(){return x([],0),u(this,S,"f").demandedCommands}getDeprecatedOptions(){return x([],0),u(this,S,"f").deprecatedOptions}getDetectLocale(){return u(this,le,"f")}getExitProcess(){return u(this,_t,"f")}getGroups(){return Object.assign({},u(this,Tt,"f"),u(this,he,"f"))}getHelp(){if(B(this,At,!0,"f"),!u(this,k,"f").hasCachedHelpMessage()){if(!this.parsed){let e=this[Ve](u(this,Zt,"f"),void 0,void 0,0,!0);if(J(e))return e.then(()=>u(this,k,"f").help())}let t=u(this,ct,"f").runDefaultBuilderOn(this);if(J(t))return t.then(()=>u(this,k,"f").help())}return Promise.resolve(u(this,k,"f").help())}getOptions(){return u(this,S,"f")}getStrict(){return u(this,fe,"f")}getStrictCommands(){return u(this,pe,"f")}getStrictOptions(){return u(this,de,"f")}global(t,e){return x("<string|array> [boolean]",[t,e],arguments.length),t=[].concat(t),e!==!1?u(this,S,"f").local=u(this,S,"f").local.filter(s=>t.indexOf(s)===-1):t.forEach(s=>{u(this,S,"f").local.includes(s)||u(this,S,"f").local.push(s)}),this}group(t,e){x("<string|array> <string>",[t,e],arguments.length);let s=u(this,he,"f")[e]||u(this,Tt,"f")[e];u(this,he,"f")[e]&&delete u(this,he,"f")[e];let r={};return u(this,Tt,"f")[e]=(s||[]).concat(t).filter(o=>r[o]?!1:r[o]=!0),this}hide(t){return x("<string>",[t],arguments.length),u(this,S,"f").hiddenOptions.push(t),this}implies(t,e){return x("<string|object> [number|string|array]",[t,e],arguments.length),u(this,rt,"f").implies(t,e),this}locale(t){return x("[string]",[t],arguments.length),t===void 0?(this[qs](),u(this,W,"f").y18n.getLocale()):(B(this,le,!1,"f"),u(this,W,"f").y18n.setLocale(t),this)}middleware(t,e,s){return u(this,jt,"f").addMiddleware(t,!!e,s)}nargs(t,e){return x("<string|object|array> [number]",[t,e],arguments.length),this[We](this.nargs.bind(this),"narg",t,e),this}normalize(t){return x("<array|string>",[t],arguments.length),this[Xt]("normalize",t),this}number(t){return x("<array|string>",[t],arguments.length),this[Xt]("number",t),this[Ce](t),this}option(t,e){if(x("<string|object> [object]",[t,e],arguments.length),typeof t=="object")Object.keys(t).forEach(s=>{this.options(s,t[s])});else{typeof e!="object"&&(e={}),this[Ce](t),u(this,Nt,"f")&&(t==="version"||(e==null?void 0:e.alias)==="version")&&this[vo](['"version" is a reserved word.',"Please do one of the following:",'- Disable version with `yargs.version(false)` if using "version" as an option',"- Use the built-in `yargs.version` method instead (if applicable)","- Use a different option key","https://yargs.js.org/docs/#api-reference-version"].join(`
|
|
161
|
+
`),void 0,"versionWarning"),u(this,S,"f").key[t]=!0,e.alias&&this.alias(t,e.alias);let s=e.deprecate||e.deprecated;s&&this.deprecateOption(t,s);let r=e.demand||e.required||e.require;r&&this.demand(t,r),e.demandOption&&this.demandOption(t,typeof e.demandOption=="string"?e.demandOption:void 0),e.conflicts&&this.conflicts(t,e.conflicts),"default"in e&&this.default(t,e.default),e.implies!==void 0&&this.implies(t,e.implies),e.nargs!==void 0&&this.nargs(t,e.nargs),e.config&&this.config(t,e.configParser),e.normalize&&this.normalize(t),e.choices&&this.choices(t,e.choices),e.coerce&&this.coerce(t,e.coerce),e.group&&this.group(t,e.group),(e.boolean||e.type==="boolean")&&(this.boolean(t),e.alias&&this.boolean(e.alias)),(e.array||e.type==="array")&&(this.array(t),e.alias&&this.array(e.alias)),(e.number||e.type==="number")&&(this.number(t),e.alias&&this.number(e.alias)),(e.string||e.type==="string")&&(this.string(t),e.alias&&this.string(e.alias)),(e.count||e.type==="count")&&this.count(t),typeof e.global=="boolean"&&this.global(t,e.global),e.defaultDescription&&(u(this,S,"f").defaultDescription[t]=e.defaultDescription),e.skipValidation&&this.skipValidation(t);let o=e.describe||e.description||e.desc,i=u(this,k,"f").getDescriptions();(!Object.prototype.hasOwnProperty.call(i,t)||typeof o=="string")&&this.describe(t,o),e.hidden&&this.hide(t),e.requiresArg&&this.requiresArg(t)}return this}options(t,e){return this.option(t,e)}parse(t,e,s){x("[string|array] [function|boolean|object] [function]",[t,e,s],arguments.length),this[Oo](),typeof t>"u"&&(t=u(this,Zt,"f")),typeof e=="object"&&(B(this,De,e,"f"),e=s),typeof e=="function"&&(B(this,$t,e,"f"),e=!1),e||B(this,Zt,t,"f"),u(this,$t,"f")&&B(this,_t,!1,"f");let r=this[Ve](t,!!e),o=this.parsed;return u(this,Ot,"f").setParsed(this.parsed),J(r)?r.then(i=>(u(this,$t,"f")&&u(this,$t,"f").call(this,u(this,Qt,"f"),i,u(this,ft,"f")),i)).catch(i=>{throw u(this,$t,"f")&&u(this,$t,"f")(i,this.parsed.argv,u(this,ft,"f")),i}).finally(()=>{this[Js](),this.parsed=o}):(u(this,$t,"f")&&u(this,$t,"f").call(this,u(this,Qt,"f"),r,u(this,ft,"f")),this[Js](),this.parsed=o,r)}parseAsync(t,e,s){let r=this.parse(t,e,s);return J(r)?r:Promise.resolve(r)}parseSync(t,e,s){let r=this.parse(t,e,s);if(J(r))throw new Y(".parseSync() must not be used with asynchronous builders, handlers, or middleware");return r}parserConfiguration(t){return x("<object>",[t],arguments.length),B(this,Pn,t,"f"),this}pkgConf(t,e){x("<string> [string]",[t,e],arguments.length);let s=null,r=this[Hs](e||u(this,ce,"f"));return r[t]&&typeof r[t]=="object"&&(s=On(r[t],e||u(this,ce,"f"),this[me]()["deep-merge-config"]||!1,u(this,W,"f")),u(this,S,"f").configObjects=(u(this,S,"f").configObjects||[]).concat(s)),this}positional(t,e){x("<string> <object>",[t,e],arguments.length);let s=["default","defaultDescription","implies","normalize","choices","conflicts","coerce","type","describe","desc","description","alias"];e=Jt(e,(i,a)=>i==="type"&&!["string","number","boolean"].includes(a)?!1:s.includes(i));let r=u(this,Ue,"f").fullCommands[u(this,Ue,"f").fullCommands.length-1],o=r?u(this,ct,"f").cmdToParseOptions(r):{array:[],alias:{},default:{},demand:{}};return Se(o).forEach(i=>{let a=o[i];Array.isArray(a)?a.indexOf(t)!==-1&&(e[i]=!0):a[t]&&!(i in e)&&(e[i]=a[t])}),this.group(t,u(this,k,"f").getPositionalGroupName()),this.option(t,e)}recommendCommands(t=!0){return x("[boolean]",[t],arguments.length),B(this,Wn,t,"f"),this}required(t,e,s){return this.demand(t,e,s)}require(t,e,s){return this.demand(t,e,s)}requiresArg(t){return x("<array|string|object> [number]",[t],arguments.length),typeof t=="string"&&u(this,S,"f").narg[t]?this:(this[We](this.requiresArg.bind(this),"narg",t,NaN),this)}showCompletionScript(t,e){return x("[string] [string]",[t,e],arguments.length),t=t||this.$0,u(this,Me,"f").log(u(this,Ot,"f").generateCompletionScript(t,e||u(this,wt,"f")||"completion")),this}showHelp(t){if(x("[string|function]",[t],arguments.length),B(this,At,!0,"f"),!u(this,k,"f").hasCachedHelpMessage()){if(!this.parsed){let s=this[Ve](u(this,Zt,"f"),void 0,void 0,0,!0);if(J(s))return s.then(()=>{u(this,k,"f").showHelp(t)}),this}let e=u(this,ct,"f").runDefaultBuilderOn(this);if(J(e))return e.then(()=>{u(this,k,"f").showHelp(t)}),this}return u(this,k,"f").showHelp(t),this}scriptName(t){return this.customScriptName=!0,this.$0=t,this}showHelpOnFail(t,e){return x("[boolean|string] [string]",[t,e],arguments.length),u(this,k,"f").showHelpOnFail(t,e),this}showVersion(t){return x("[string|function]",[t],arguments.length),u(this,k,"f").showVersion(t),this}skipValidation(t){return x("<array|string>",[t],arguments.length),this[Xt]("skipValidation",t),this}strict(t){return x("[boolean]",[t],arguments.length),B(this,fe,t!==!1,"f"),this}strictCommands(t){return x("[boolean]",[t],arguments.length),B(this,pe,t!==!1,"f"),this}strictOptions(t){return x("[boolean]",[t],arguments.length),B(this,de,t!==!1,"f"),this}string(t){return x("<array|string>",[t],arguments.length),this[Xt]("string",t),this[Ce](t),this}terminalWidth(){return x([],0),u(this,W,"f").process.stdColumns}updateLocale(t){return this.updateStrings(t)}updateStrings(t){return x("<object>",[t],arguments.length),B(this,le,!1,"f"),u(this,W,"f").y18n.updateLocale(t),this}usage(t,e,s,r){if(x("<string|null|undefined> [string|boolean] [function|object] [function]",[t,e,s,r],arguments.length),e!==void 0){if(Ft(t,null,u(this,W,"f")),(t||"").match(/^\$0( |$)/))return this.command(t,e,s,r);throw new Y(".usage() description must start with $0 if being used as alias for .command()")}else return u(this,k,"f").usage(t),this}usageConfiguration(t){return x("<object>",[t],arguments.length),B(this,kn,t,"f"),this}version(t,e,s){let r="version";if(x("[boolean|string] [string] [string]",[t,e,s],arguments.length),u(this,Nt,"f")&&(this[zs](u(this,Nt,"f")),u(this,k,"f").version(void 0),B(this,Nt,null,"f")),arguments.length===0)s=this[So](),t=r;else if(arguments.length===1){if(t===!1)return this;s=t,t=r}else arguments.length===2&&(s=e,e=void 0);return B(this,Nt,typeof t=="string"?t:r,"f"),e=e||u(this,k,"f").deferY18nLookup("Show version number"),u(this,k,"f").version(s||void 0),this.boolean(u(this,Nt,"f")),this.describe(u(this,Nt,"f"),e),this}wrap(t){return x("<number|null|undefined>",[t],arguments.length),u(this,k,"f").wrap(t),this}[(ct=new WeakMap,ce=new WeakMap,Ue=new WeakMap,Ot=new WeakMap,wt=new WeakMap,_n=new WeakMap,Qt=new WeakMap,le=new WeakMap,jn=new WeakMap,_t=new WeakMap,Sn=new WeakMap,jt=new WeakMap,Tt=new WeakMap,At=new WeakMap,St=new WeakMap,In=new WeakMap,Me=new WeakMap,ft=new WeakMap,S=new WeakMap,Mn=new WeakMap,Pn=new WeakMap,$t=new WeakMap,De=new WeakMap,Pe=new WeakMap,he=new WeakMap,Zt=new WeakMap,Wn=new WeakMap,W=new WeakMap,fe=new WeakMap,pe=new WeakMap,de=new WeakMap,k=new WeakMap,kn=new WeakMap,Nt=new WeakMap,rt=new WeakMap,xo)](t){if(!t._||!t["--"])return t;t._.push.apply(t._,t["--"]);try{delete t["--"]}catch{}return t}[Bo](){return{log:(...t)=>{this[Tn]()||console.log(...t),B(this,At,!0,"f"),u(this,ft,"f").length&&B(this,ft,u(this,ft,"f")+`
|
|
162
|
+
`,"f"),B(this,ft,u(this,ft,"f")+t.join(" "),"f")},error:(...t)=>{this[Tn]()||console.error(...t),B(this,At,!0,"f"),u(this,ft,"f").length&&B(this,ft,u(this,ft,"f")+`
|
|
163
|
+
`,"f"),B(this,ft,u(this,ft,"f")+t.join(" "),"f")}}}[zs](t){Se(u(this,S,"f")).forEach(e=>{if((r=>r==="configObjects")(e))return;let s=u(this,S,"f")[e];Array.isArray(s)?s.includes(t)&&s.splice(s.indexOf(t),1):typeof s=="object"&&delete s[t]}),delete u(this,k,"f").getDescriptions()[t]}[vo](t,e,s){u(this,jn,"f")[s]||(u(this,W,"f").process.emitWarning(t,e),u(this,jn,"f")[s]=!0)}[Oo](){u(this,Sn,"f").push({options:u(this,S,"f"),configObjects:u(this,S,"f").configObjects.slice(0),exitProcess:u(this,_t,"f"),groups:u(this,Tt,"f"),strict:u(this,fe,"f"),strictCommands:u(this,pe,"f"),strictOptions:u(this,de,"f"),completionCommand:u(this,wt,"f"),output:u(this,ft,"f"),exitError:u(this,Qt,"f"),hasOutput:u(this,At,"f"),parsed:this.parsed,parseFn:u(this,$t,"f"),parseContext:u(this,De,"f")}),u(this,k,"f").freeze(),u(this,rt,"f").freeze(),u(this,ct,"f").freeze(),u(this,jt,"f").freeze()}[_o](){let t="",e;return/\b(node|iojs|electron)(\.exe)?$/.test(u(this,W,"f").process.argv()[0])?e=u(this,W,"f").process.argv().slice(1,2):e=u(this,W,"f").process.argv().slice(0,1),t=e.map(s=>{let r=this[qo](u(this,ce,"f"),s);return s.match(/^(\/|([a-zA-Z]:)?\\)/)&&r.length<s.length?r:s}).join(" ").trim(),u(this,W,"f").getEnv("_")&&u(this,W,"f").getProcessArgvBin()===u(this,W,"f").getEnv("_")&&(t=u(this,W,"f").getEnv("_").replace(`${u(this,W,"f").path.dirname(u(this,W,"f").process.execPath())}/`,"")),t}[me](){return u(this,Pn,"f")}[jo](){return u(this,kn,"f")}[qs](){if(!u(this,le,"f"))return;let t=u(this,W,"f").getEnv("LC_ALL")||u(this,W,"f").getEnv("LC_MESSAGES")||u(this,W,"f").getEnv("LANG")||u(this,W,"f").getEnv("LANGUAGE")||"en_US";this.locale(t.replace(/[.:].*/,""))}[So](){return this[Hs]().version||"unknown"}[Io](t){let e=t["--"]?t["--"]:t._;for(let s=0,r;(r=e[s])!==void 0;s++)u(this,W,"f").Parser.looksLikeNumber(r)&&Number.isSafeInteger(Math.floor(parseFloat(`${r}`)))&&(e[s]=Number(r));return t}[Hs](t){let e=t||"*";if(u(this,Pe,"f")[e])return u(this,Pe,"f")[e];let s={};try{let r=t||u(this,W,"f").mainFilename;!t&&u(this,W,"f").path.extname(r)&&(r=u(this,W,"f").path.dirname(r));let o=u(this,W,"f").findUp(r,(i,a)=>{if(a.includes("package.json"))return"package.json"});Ft(o,void 0,u(this,W,"f")),s=JSON.parse(u(this,W,"f").readFileSync(o,"utf8"))}catch{}return u(this,Pe,"f")[e]=s||{},u(this,Pe,"f")[e]}[Xt](t,e){e=[].concat(e),e.forEach(s=>{s=this[Gs](s),u(this,S,"f")[t].push(s)})}[We](t,e,s,r){this[Vs](t,e,s,r,(o,i,a)=>{u(this,S,"f")[o][i]=a})}[Us](t,e,s,r){this[Vs](t,e,s,r,(o,i,a)=>{u(this,S,"f")[o][i]=(u(this,S,"f")[o][i]||[]).concat(a)})}[Vs](t,e,s,r,o){if(Array.isArray(s))s.forEach(i=>{t(i,r)});else if((i=>typeof i=="object")(s))for(let i of Se(s))t(i,s[i]);else o(e,this[Gs](s),r)}[Gs](t){return t==="__proto__"?"___proto___":t}[Ys](t,e){return this[We](this[Ys].bind(this),"key",t,e),this}[Js](){var t,e,s,r,o,i,a,c,h,f,l,m;let C=u(this,Sn,"f").pop();Ft(C,void 0,u(this,W,"f"));let E;t=this,e=this,s=this,r=this,o=this,i=this,a=this,c=this,h=this,f=this,l=this,m=this,{options:{set value(b){B(t,S,b,"f")}}.value,configObjects:E,exitProcess:{set value(b){B(e,_t,b,"f")}}.value,groups:{set value(b){B(s,Tt,b,"f")}}.value,output:{set value(b){B(r,ft,b,"f")}}.value,exitError:{set value(b){B(o,Qt,b,"f")}}.value,hasOutput:{set value(b){B(i,At,b,"f")}}.value,parsed:this.parsed,strict:{set value(b){B(a,fe,b,"f")}}.value,strictCommands:{set value(b){B(c,pe,b,"f")}}.value,strictOptions:{set value(b){B(h,de,b,"f")}}.value,completionCommand:{set value(b){B(f,wt,b,"f")}}.value,parseFn:{set value(b){B(l,$t,b,"f")}}.value,parseContext:{set value(b){B(m,De,b,"f")}}.value}=C,u(this,S,"f").configObjects=E,u(this,k,"f").unfreeze(),u(this,rt,"f").unfreeze(),u(this,ct,"f").unfreeze(),u(this,jt,"f").unfreeze()}[Mo](t,e){return ae(e,s=>(t(s),s))}getInternalMethods(){return{getCommandInstance:this[Po].bind(this),getContext:this[Wo].bind(this),getHasOutput:this[ko].bind(this),getLoggerInstance:this[To].bind(this),getParseContext:this[No].bind(this),getParserConfiguration:this[me].bind(this),getUsageConfiguration:this[jo].bind(this),getUsageInstance:this[Ro].bind(this),getValidationInstance:this[Lo].bind(this),hasParseCallback:this[Tn].bind(this),isGlobalContext:this[zo].bind(this),postProcess:this[ge].bind(this),reset:this[Ks].bind(this),runValidation:this[Qs].bind(this),runYargsParserAndExecuteCommands:this[Ve].bind(this),setHasOutput:this[Ho].bind(this)}}[Po](){return u(this,ct,"f")}[Wo](){return u(this,Ue,"f")}[ko](){return u(this,At,"f")}[To](){return u(this,Me,"f")}[No](){return u(this,De,"f")||{}}[Ro](){return u(this,k,"f")}[Lo](){return u(this,rt,"f")}[Tn](){return!!u(this,$t,"f")}[zo](){return u(this,In,"f")}[ge](t,e,s,r){return s||J(t)||(e||(t=this[xo](t)),(this[me]()["parse-positional-numbers"]||this[me]()["parse-positional-numbers"]===void 0)&&(t=this[Io](t)),r&&(t=ue(t,this,u(this,jt,"f").getMiddleware(),!1))),t}[Ks](t={}){B(this,S,u(this,S,"f")||{},"f");let e={};e.local=u(this,S,"f").local||[],e.configObjects=u(this,S,"f").configObjects||[];let s={};e.local.forEach(i=>{s[i]=!0,(t[i]||[]).forEach(a=>{s[a]=!0})}),Object.assign(u(this,he,"f"),Object.keys(u(this,Tt,"f")).reduce((i,a)=>{let c=u(this,Tt,"f")[a].filter(h=>!(h in s));return c.length>0&&(i[a]=c),i},{})),B(this,Tt,{},"f");let r=["array","boolean","string","skipValidation","count","normalize","number","hiddenOptions"],o=["narg","key","alias","default","defaultDescription","config","choices","demandedOptions","demandedCommands","deprecatedOptions"];return r.forEach(i=>{e[i]=(u(this,S,"f")[i]||[]).filter(a=>!s[a])}),o.forEach(i=>{e[i]=Jt(u(this,S,"f")[i],a=>!s[a])}),e.envPrefix=u(this,S,"f").envPrefix,B(this,S,e,"f"),B(this,k,u(this,k,"f")?u(this,k,"f").reset(s):Co(this,u(this,W,"f")),"f"),B(this,rt,u(this,rt,"f")?u(this,rt,"f").reset(s):Ao(this,u(this,k,"f"),u(this,W,"f")),"f"),B(this,ct,u(this,ct,"f")?u(this,ct,"f").reset():po(u(this,k,"f"),u(this,rt,"f"),u(this,jt,"f"),u(this,W,"f")),"f"),u(this,Ot,"f")||B(this,Ot,bo(this,u(this,k,"f"),u(this,ct,"f"),u(this,W,"f")),"f"),u(this,jt,"f").reset(),B(this,wt,null,"f"),B(this,ft,"","f"),B(this,Qt,null,"f"),B(this,At,!1,"f"),this.parsed=!1,this}[qo](t,e){return u(this,W,"f").path.relative(t,e)}[Ve](t,e,s,r=0,o=!1){let i=!!s||o;t=t||u(this,Zt,"f"),u(this,S,"f").__=u(this,W,"f").y18n.__,u(this,S,"f").configuration=this[me]();let a=!!u(this,S,"f").configuration["populate--"],c=Object.assign({},u(this,S,"f").configuration,{"populate--":!0}),h=u(this,W,"f").Parser.detailed(t,Object.assign({},u(this,S,"f"),{configuration:{"parse-positional-numbers":!1,...c}})),f=Object.assign(h.argv,u(this,De,"f")),l,m=h.aliases,C=!1,E=!1;Object.keys(f).forEach(b=>{b===u(this,St,"f")&&f[b]?C=!0:b===u(this,Nt,"f")&&f[b]&&(E=!0)}),f.$0=this.$0,this.parsed=h,r===0&&u(this,k,"f").clearCachedHelpMessage();try{if(this[qs](),e)return this[ge](f,a,!!s,!1);u(this,St,"f")&&[u(this,St,"f")].concat(m[u(this,St,"f")]||[]).filter(H=>H.length>1).includes(""+f._[f._.length-1])&&(f._.pop(),C=!0),B(this,In,!1,"f");let b=u(this,ct,"f").getCommands(),g=u(this,Ot,"f").completionKey in f,O=C||g||o;if(f._.length){if(b.length){let T;for(let H=r||0,L;f._[H]!==void 0;H++)if(L=String(f._[H]),b.includes(L)&&L!==u(this,wt,"f")){let U=u(this,ct,"f").runCommand(L,this,h,H+1,o,C||E||o);return this[ge](U,a,!!s,!1)}else if(!T&&L!==u(this,wt,"f")){T=L;break}!u(this,ct,"f").hasDefaultCommand()&&u(this,Wn,"f")&&T&&!O&&u(this,rt,"f").recommendCommands(T,b)}u(this,wt,"f")&&f._.includes(u(this,wt,"f"))&&!g&&(u(this,_t,"f")&&Kt(!0),this.showCompletionScript(),this.exit(0))}if(u(this,ct,"f").hasDefaultCommand()&&!O){let T=u(this,ct,"f").runCommand(null,this,h,0,o,C||E||o);return this[ge](T,a,!!s,!1)}if(g){u(this,_t,"f")&&Kt(!0),t=[].concat(t);let T=t.slice(t.indexOf(`--${u(this,Ot,"f").completionKey}`)+1);return u(this,Ot,"f").getCompletion(T,(H,L)=>{if(H)throw new Y(H.message);(L||[]).forEach(U=>{u(this,Me,"f").log(U)}),this.exit(0)}),this[ge](f,!a,!!s,!1)}if(u(this,At,"f")||(C?(u(this,_t,"f")&&Kt(!0),i=!0,this.showHelp("log"),this.exit(0)):E&&(u(this,_t,"f")&&Kt(!0),i=!0,u(this,k,"f").showVersion("log"),this.exit(0))),!i&&u(this,S,"f").skipValidation.length>0&&(i=Object.keys(f).some(T=>u(this,S,"f").skipValidation.indexOf(T)>=0&&f[T]===!0)),!i){if(h.error)throw new Y(h.error.message);if(!g){let T=this[Qs](m,{},h.error);s||(l=ue(f,this,u(this,jt,"f").getMiddleware(),!0)),l=this[Mo](T,l??f),J(l)&&!s&&(l=l.then(()=>ue(f,this,u(this,jt,"f").getMiddleware(),!1)))}}}catch(b){if(b instanceof Y)u(this,k,"f").fail(b.message,b);else throw b}return this[ge](l??f,a,!!s,!0)}[Qs](t,e,s,r){let o={...this.getDemandedOptions()};return i=>{if(s)throw new Y(s.message);u(this,rt,"f").nonOptionCount(i),u(this,rt,"f").requiredArguments(i,o);let a=!1;u(this,pe,"f")&&(a=u(this,rt,"f").unknownCommands(i)),u(this,fe,"f")&&!a?u(this,rt,"f").unknownArguments(i,t,e,!!r):u(this,de,"f")&&u(this,rt,"f").unknownArguments(i,t,{},!1,!1),u(this,rt,"f").limitedChoices(i),u(this,rt,"f").implications(i),u(this,rt,"f").conflicting(i)}}[Ho](){B(this,At,!0,"f")}[Ce](t){if(typeof t=="string")u(this,S,"f").key[t]=!0;else for(let e of t)u(this,S,"f").key[e]=!0}};function mo(n){return!!n&&typeof n.getInternalMethods=="function"}var Ja=Uo(co),Vo=Ja;function Ka(n,t){return Vo(n).strict().command("* <template> <outDir>","Create a new project powered by qwik",s=>s.positional("template",{type:"string",desc:"Starter template",choices:t}).positional("outDir",{type:"string",desc:"Directory of the project"}).option("force",{alias:"f",type:"boolean",default:!1,desc:"Overwrite target directory if it exists"}).option("installDeps",{alias:"i",default:!1,type:"boolean",desc:"Install dependencies"}).usage("npm create qwik@latest base ./my-project <options>")).argv}async function ti(...n){let t=Gt(),e=await ve("app"),s=e.standaloneTemplates.map(({id:m})=>m),r=Ka(n,s),{force:o,installDeps:i,template:a}=r,c=r.outDir;nn(`Let's create a ${Ne(" Qwik App ")} \u2728 (v1.2.12)`),Qa()?c=process.cwd():(c=gn(c),Xs.default.existsSync(c)&&Xs.default.readdirSync(c).length>0&&(o?await rn(c):(et.error(`Directory "${c}" already exists.`),et.info("Please either remove this directory, choose another location or run the command again with '--force | -f' flag."),se(),process.exit(1))));let h=await Oe({outDir:c,appId:a,pkgManager:t,templateManager:e}),f=we(),l=!1;return i&&(l=await dn(async()=>await re(t,c).install,{pkgManager:t,spinner:f})),mn(t,h,l),h}function Qa(){return Za()}function Za(){try{return process.cwd().startsWith("/home/projects/")}catch{}return!1}var Rn=require("path");var Nn=ut(require("fs"));var ei=[["Dad, can you put my shoes on?","I don't think they'll fit me."],["What do ghosts call their true love?","Their ghoul-friend"],["How do the trees get on the internet?","They log on."],["Lady: How do I spread love in this cruel world?","Random Dude: [...\u{1F498}]"],["How do you find Will Smith in the snow?"," Look for fresh prints."],["Why did the mushroom get invited to the party?","Because he was a fungi."],["Why is peter pan always flying?","Because he neverlands"],["How do you know if there\u2019s an elephant under your bed?","Your head hits the ceiling!"],["How do you fix a broken pizza?","With tomato paste."],["Why did the butcher work extra hours at the shop?","To make ends meat."],["What time is it?","I don't know... it keeps changing."],["What did the traffic light say to the car as it passed?","Don't look I'm changing!"],["What do you call someone with no nose?","Nobody knows."],["Why did the worker get fired from the orange juice factory?","Lack of concentration."],["What did the say to the ?","Nice belt."],["What animal is always at a game of cricket?","A bat."],["Why did the tomato blush?","Because it saw the salad dressing."],["What\u2019s E.T. short for?","He\u2019s only got little legs."],["What did the beaver say to the tree?","It's been nice gnawing you."],["What do you call a girl between two posts?","Annette."],["What do you call a boomerang that won't come back?","A stick."],["What do you do on a remote island?","Try and find the TV island it belongs to."],["Why did the barber win the race?","He took a short cut."],["Do you want a brief explanation of what an acorn is?","In a nutshell, it's an oak tree."],["What do you call a belt made out of watches?","A waist of time."],["How many lips does a flower have?","Tulips"],["Did you hear about the guy who invented Lifesavers?","They say he made a mint."],["I Got Hit In the Head By A Soda Can, But It Didn't Hurt That Much...","It was a soft drink."],["When a dad drives past a graveyard: Did you know that's a popular cemetery?","Yep, people are just dying to get in there"],["What did the fish say when it hit the wall?","Dam."],["Want to hear a joke about a piece of paper?","Never mind...it's tearable"],["What did the big flower say to the littler flower?","Hi, bud!"],["What has ears but cannot hear?","A field of corn."],["What's the best thing about elevator jokes?","They work on so many levels."],["Why can't your nose be inches long?","Because then it'd be a foot!"],["Why does Superman get invited to dinners?","Because he is a Supperhero."],["What's red and bad for your teeth?","A Brick."],["What's the difference between a guitar and a fish?",`You can tune a guitar but you can't "tuna" fish!`],["Why did the coffee file a police report?","It got mugged."],["What do you do when you see a space man?","Park your car, man."],["What do you give a sick lemon?","Lemonaid."],["Where do rabbits go after they get married?","On a bunny-moon."],["What creature is smarter than a talking parrot?","A spelling bee."],["How does the moon cut his hair?","Eclipse it."],["What do you get when you cross a chicken with a skunk?","A fowl smell!"],["Why do crabs never give to charity?","Because they\u2019re shellfish."],["did you know the first French fries weren't cooked in France?","they were cooked in Greece"],["Did you hear that the police have a warrant out on a midget psychic ripping people off?",'It reads "Small medium at large."'],["A termite walks into a bar and says...","'Where is the bar tended?'"],["Why do chicken coops only have two doors?","Because if they had four, they would be chicken sedans"],["What's the best thing about a Boolean?","Even if you're wrong, you're only off by a bit."],["If you put a million monkeys at a million keyboards, one of them will eventually write a Java program","the rest of them will write Perl"],["How many programmers does it take to change a lightbulb?","None that's a hardware problem"],["A user interface is like a joke.","If you have to explain it then it is not that good."],["['hip', 'hip']","(hip hip array)"],["A SQL query walks into a bar, walks up to two tables and asks...","'Can I join you?'"],["Which song would an exception sing?","Can't catch me - Avicii"],["Why do C# and Java developers keep breaking their keyboards?","Because they use a strongly typed language."],["What's the object-oriented way to become wealthy?","Inheritance"],["Where do programmers like to hangout?","The Foo Bar."],["Why do Java programmers wear glasses?","Because they don't C#"],["To understand what recursion is...","You must first understand what recursion is"],["The punchline often arrives before the set-up.","Do you know the problem with UDP jokes?"],["Why did the programmer quit his job?","Because he didn't get arrays."],["How do you check if a webpage is HTML?","Try it out on Internet Explorer"],["There are 10 types of people in this world...","Those who understand binary and those who don't"],["Why do programmers always mix up Halloween and Christmas?","Because Oct == Dec "],["I was gonna tell you a joke about UDP...","...but you might not get it."],["How do you get a squirrel to like you"," Act like a nut."],["Why did the math book look so sad"," Because of all of its problems!"],["What's the best way to watch a fly fishing tournament"," Live stream."],["Why couldn't the bicycle stand up by itself"," It was two tired."],["Why did the scarecrow win an award"," Because he was outstanding in his field."],["I ordered a chicken and an egg online. I\u2019ll let you know."," I\u2019ll let you know"],["How do you make a Kleenex dance"," Put a little boogie in it!"],["I'm reading a book about anti-gravity. It's impossible to put down!"," It's impossible to put down!"],["Why can't you hear a psychiatrist using the bathroom"," Because the 'P' is silent."],["I like telling Dad jokes. Sometimes he laughs!"," Sometimes he laughs!"],["I'm so good at sleeping, I can do it with my eyes closed!"," I can do it with my eyes closed!"],["How do you make a tissue dance"," You put a little boogie in it."],["What do you call cheese that isn't yours"," Nacho cheese."],["What kind of shoes do ninjas wear"," Sneakers!"],["What do you call a fake noodle"," An impasta."],["I made a pencil with two erasers. It was pointless."," It was pointless"],["I've got a great joke about construction, but I'm still working on it.",""],["Did I tell you the time I fell in love during a backflip"," I was heels over head!"],["What\u2019s an astronaut\u2019s favorite part of a computer"," The space bar."],["What time did the man go to the dentist"," Tooth hurt-y."],["It's inappropriate to make a 'dad joke' if you're not a dad. It's a faux pa."," It's a faux pa"],["What did the fish say when he hit the wall"," Dam."],["I don't trust stairs. They're always up to something."," They're always up to something"],["What do you call someone with no body and no nose"," Nobody knows."],["Did you hear the rumor about butter"," Well, I'm not going to spread it!"],["I used to hate facial hair...but then it grew on me.",null],["What's brown and sticky"," A stick."],["Can February March"," No, but April May!"],["Don't trust atoms. They make up everything!"," They make up everything!"],["Why don't eggs tell jokes"," They'd crack each other up."],["Did you hear about the circus fire"," It was in tents."],["How do lawyers say goodbye"," We'll be suing ya!"],["When does a joke become a dad joke"," When it becomes apparent."],["Wanna hear a joke about paper"," Never mind\u2014it's tearable."],["What did the coffee report to the police"," A mugging."],["Dad, can you put my shoes on","No, I don't think they'll fit me."],["How many tickles does it take to make an octopus laugh"," Ten tickles."],["Dad, did you get a haircut","No, I got them all cut!"],["My wife is really mad at the fact that I have no sense of direction."," So I packed up my stuff and right!"],["Why do bees have sticky hair"," Because they use a honeycomb."],["Which state has the most streets"," Rhode Island."],["I'm on a seafood diet. I see food and I eat it."," I see food and I eat it"],["Did you hear about the guy who invented the knock-knock joke"," He won the 'no-bell' prize."],["How does a penguin build its house"," Igloos it together."],["What do you call an elephant that doesn't matter"," An irrelephant."],["I wouldn't buy anything with velcro. It's a total rip-off."," It's a total rip-off"],["Dad, can you put the cat out","I didn't know it was on fire."],["What concert costs just 45 cents"," 50 Cent featuring Nickelback!"],["Why are elevator jokes so classic and good"," They work on many levels."],["Is this pool safe for diving"," It deep ends."],[`Knock knock.
|
|
167
164
|
Who's there?
|
|
168
165
|
Cows go.
|
|
169
166
|
Cows go who?`,"No, cows go moo."],[`Knock knock.
|
|
@@ -177,8 +174,8 @@ ${E.join(`
|
|
|
177
174
|
Opportunity.`,"That is impossible. Opportunity doesn\u2019t come knocking twice!"],[`Knock knock.
|
|
178
175
|
Who's there?
|
|
179
176
|
Hatch.
|
|
180
|
-
Hatch who?`,"Bless you!"]];function
|
|
181
|
-
${H.trim()}`),"\u{1F648}")}}catch{}let E=
|
|
177
|
+
Hatch who?`,"Bless you!"]];function Go(){let n=Math.floor(Math.random()*ei.length);return ei[n]}async function ni(){let n=Gt(),t=await ve("app"),e="./qwik-app";nn(`Let's create a ${Ne(" Qwik App ")} \u2728 (v1.2.12)`),await Or(500);let s=await yi({message:`Where would you like to create your new project? ${Vt("(Use '.' or './' for current directory)")}`,placeholder:e})||e;Ut(s)&&(se("Operation cancelled."),process.exit(0));let r=t.getBaseApp();if(!r)throw new Error("Base app not found");let o=t.templates.filter(O=>O.id!==r.id),i=Pr(n,r),a=gn(s.trim());et.info(`Creating new project in ${Ne(" "+a+" ")} ... \u{1F407}`);let c=null;if(Nn.default.existsSync(a)&&Nn.default.readdirSync(a).length>0){let O=await is({message:`Directory "./${(0,Rn.relative)(process.cwd(),a)}" already exists and is not empty. What would you like to do?`,options:[{value:"exit",label:"Do not overwrite this directory and exit"},{value:"replace",label:"Remove contents of this directory"}]});(Ut(O)||O==="exit")&&(se("Operation cancelled."),process.exit(0)),O==="replace"&&(c=rn(a))}let h=await is({message:"Select a starter",options:o.map(O=>{var T;return{label:O.name,value:O.id,hint:(T=O.pkgJson)==null?void 0:T.description}})});Ut(h)&&(se("Operation cancelled."),process.exit(0));let f=h,l=await en({message:`Would you like to install ${n} dependencies?`,initialValue:!0});Ut(l)&&(se("Operation cancelled."),process.exit(0));let m=await en({message:"Initialize a new git repository?",initialValue:!0});c&&await c;let C=l;if(!C)i.abort();else try{let O=await en({message:"Finishing the install. Wanna hear a joke?",initialValue:!0});if(!Ut(O)&&O){let[T,H]=Go();an(Ct(`${T.trim()}
|
|
178
|
+
${H.trim()}`),"\u{1F648}")}}catch{}let E=we();E.start("Creating App...");let b=await Oe({appId:f,outDir:a,pkgManager:n,templateManager:t});if(E.stop("App Created \u{1F430}"),m)if(Nn.default.existsSync((0,Rn.join)(a,".git")))et.info("Git has already been initialized before. Skipping...");else{E.start("Git initializing...");try{let O=[];if(O.push(await xe("git",["init"],a).install),O.push(await xe("git",["add","-A"],a).install),O.push(await xe("git",["commit","-m","Initial commit \u26A1\uFE0F"],a).install),O.some(T=>T===!1))throw"";E.stop("Git initialized \u{1F3B2}")}catch{E.stop("Git failed to initialize"),et.error(Et("Git failed to initialize. You can do this manually by running: git init"))}}let g=!1;return C&&(g=await dn(async()=>{let O=await i.complete(b.outDir);return O&&await re(n,b.outDir).install},{pkgManager:n,spinner:E})),mn(n,b,g),b}async function Yo(n){let t=Gt(),e=await ve("app");return await Oe({appId:n.starterId,templateManager:e,outDir:n.outDir,pkgManager:t})}async function tc(){console.clear(),Sr(),ec();try{let n=process.argv.slice(2);n.length>0?await ti(...n):await ni()}catch(n){un(n.message||n)}}function ec(){let n=process.version,[t,e]=n.replace("v","").split(".");Number(t)<16?(console.error(Et(`Qwik requires Node.js 16.8 or higher. You are currently running Node.js ${n}.`)),process.exit(1)):Number(t)===16?Number(e)<8&&console.warn(_i(`Node.js 16.8 or higher is recommended. You are currently running Node.js ${n}.`)):Number(t)===18&&Number(e)<11&&console.error(Et(`Node.js 18.11 or higher is REQUIRED. From Node 18.0.0 to 18.11.0, there is a bug preventing correct behaviour of Qwik. You are currently running Node.js ${n}. https://github.com/BuilderIO/qwik/issues/3035`))}0&&(module.exports={createApp,runCli,runCreateCli,runCreateInteractiveCli});
|
|
182
179
|
/*! Bundled license information:
|
|
183
180
|
|
|
184
181
|
yargs-parser/build/lib/string-utils.js:
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-qwik",
|
|
3
3
|
"description": "Interactive CLI for create Qwik projects and adding features.",
|
|
4
|
-
"version": "1.2.
|
|
4
|
+
"version": "1.2.12",
|
|
5
5
|
"author": "Builder.io Team",
|
|
6
6
|
"bin": "./create-qwik.cjs",
|
|
7
7
|
"bugs": "https://github.com/BuilderIO/qwik/issues",
|
|
8
8
|
"devDependencies": {
|
|
9
|
-
"@clack/prompts": "^0.
|
|
9
|
+
"@clack/prompts": "^0.7.0",
|
|
10
10
|
"@types/yargs": "17.0.24",
|
|
11
11
|
"kleur": "4.1.5",
|
|
12
12
|
"yargs": "17.7.2"
|
|
@@ -2,5 +2,10 @@
|
|
|
2
2
|
"material-icon-theme.activeIconPack": "qwik",
|
|
3
3
|
"emmet.includeLanguages": {
|
|
4
4
|
"typescriptreact": "html"
|
|
5
|
+
},
|
|
6
|
+
"emmet.preferences": {
|
|
7
|
+
// to ensure closing tags are used (e.g. <img/> not just <img> like in HTML)
|
|
8
|
+
// https://github.com/microsoft/vscode/commit/083bf9020407ea5a91199eb1f0b373859df8d600#diff-88456bc9b7caa2f8126aea0107b4671db0f094961aaf39a7c689f890e23aaaba
|
|
9
|
+
"output.selfClosingStyle": "xhtml"
|
|
5
10
|
}
|
|
6
11
|
}
|
|
@@ -16,13 +16,13 @@
|
|
|
16
16
|
"qwik": "qwik"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
|
-
"@builder.io/qwik": "^1.2.
|
|
20
|
-
"@builder.io/qwik-city": "^1.2.
|
|
19
|
+
"@builder.io/qwik": "^1.2.12",
|
|
20
|
+
"@builder.io/qwik-city": "^1.2.12",
|
|
21
21
|
"@types/eslint": "8.44.1",
|
|
22
22
|
"@types/node": "^20.4.5",
|
|
23
23
|
"@typescript-eslint/eslint-plugin": "6.2.0",
|
|
24
24
|
"@typescript-eslint/parser": "6.2.0",
|
|
25
|
-
"eslint-plugin-qwik": "^1.2.
|
|
25
|
+
"eslint-plugin-qwik": "^1.2.12",
|
|
26
26
|
"eslint": "8.45.0",
|
|
27
27
|
"undici": "5.22.1",
|
|
28
28
|
"prettier": "3.0.0",
|
|
@@ -30,6 +30,9 @@
|
|
|
30
30
|
"vite": "4.4.7",
|
|
31
31
|
"vite-tsconfig-paths": "4.2.0"
|
|
32
32
|
},
|
|
33
|
+
"trustedDependencies": [
|
|
34
|
+
"sharp"
|
|
35
|
+
],
|
|
33
36
|
"engines": {
|
|
34
37
|
"node": ">=16.8.0 <18.0.0 || >=18.11"
|
|
35
38
|
},
|
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
import { defineConfig } from "vite";
|
|
2
|
+
import pkg from "./package.json";
|
|
2
3
|
import { qwikVite } from "@builder.io/qwik/optimizer";
|
|
3
4
|
import tsconfigPaths from "vite-tsconfig-paths";
|
|
4
5
|
|
|
6
|
+
const { dependencies = {}, peerDependencies = {} } = pkg as any;
|
|
7
|
+
const makeRegex = (dep) => new RegExp(`^${dep}(/.*)?$`);
|
|
8
|
+
const excludeAll = (obj) => Object.keys(obj).map(makeRegex);
|
|
9
|
+
|
|
5
10
|
export default defineConfig(() => {
|
|
6
11
|
return {
|
|
7
12
|
build: {
|
|
@@ -11,6 +16,14 @@ export default defineConfig(() => {
|
|
|
11
16
|
formats: ["es", "cjs"],
|
|
12
17
|
fileName: (format) => `index.qwik.${format === "es" ? "mjs" : "cjs"}`,
|
|
13
18
|
},
|
|
19
|
+
rollupOptions: {
|
|
20
|
+
// externalize deps that shouldn't be bundled into the library
|
|
21
|
+
external: [
|
|
22
|
+
/^node:.*/,
|
|
23
|
+
...excludeAll(dependencies),
|
|
24
|
+
...excludeAll(peerDependencies),
|
|
25
|
+
],
|
|
26
|
+
},
|
|
14
27
|
},
|
|
15
28
|
plugins: [qwikVite(), tsconfigPaths()],
|
|
16
29
|
};
|