diff --git a/dist/index.js b/dist/index.js index d5a2acef..3eab54ac 100755 --- a/dist/index.js +++ b/dist/index.js @@ -87,7 +87,7 @@ function print() { __p += __j.call(arguments, '') } `);let a=r?lNe:dNe;for(let o=0;o{var{info:hNe,debug:xY}=r9(),ln=rw(),e1=class{constructor(t){this.setOptions(t),this.x=null,this.y=null}setOptions(t){["boolean","number","string"].indexOf(typeof t)!==-1&&(t={content:""+t}),t=t||{},this.options=t;let r=t.content;if(["boolean","number","string"].indexOf(typeof r)!==-1)this.content=String(r);else if(!r)this.content=this.options.href||"";else throw new Error("Content needs to be a primitive, got: "+typeof r);this.colSpan=t.colSpan||1,this.rowSpan=t.rowSpan||1,this.options.href&&Object.defineProperty(this,"href",{get(){return this.options.href}})}mergeTableOptions(t,r){this.cells=r;let n=this.options.chars||{},a=t.chars,o=this.chars={};gNe.forEach(function(d){nw(n,a,d,o)}),this.truncate=this.options.truncate||t.truncate;let u=this.options.style=this.options.style||{},l=t.style;nw(u,l,"padding-left",this),nw(u,l,"padding-right",this),this.head=u.head||l.head,this.border=u.border||l.border,this.fixedWidth=t.colWidths[this.x],this.lines=this.computeLines(t),this.desiredWidth=ln.strlen(this.content)+this.paddingLeft+this.paddingRight,this.desiredHeight=this.lines.length}computeLines(t){let r=t.wordWrap||t.textWrap,{wordWrap:n=r}=this.options;if(this.fixedWidth&&n){if(this.fixedWidth-=this.paddingLeft+this.paddingRight,this.colSpan){let u=1;for(;uln.hyperlink(this.href,n)):r}init(t){let r=this.x,n=this.y;this.widths=t.colWidths.slice(r,r+this.colSpan),this.heights=t.rowHeights.slice(n,n+this.rowSpan),this.width=this.widths.reduce(gY,-1),this.height=this.heights.reduce(gY,-1),this.hAlign=this.options.hAlign||t.colAligns[r],this.vAlign=this.options.vAlign||t.rowAligns[n],this.drawRight=r+this.colSpan==t.colWidths.length}draw(t,r){if(t=="top")return this.drawTop(this.drawRight);if(t=="bottom")return this.drawBottom(this.drawRight);let n=ln.truncate(this.content,10,this.truncate);t||hNe(`${this.y}-${this.x}: ${this.rowSpan-t}x${this.colSpan} Cell ${n}`);let a=Math.max(this.height-this.lines.length,0),o;switch(this.vAlign){case"center":o=Math.ceil(a/2);break;case"bottom":o=a;break;default:o=0}if(t=o+this.lines.length)return this.drawEmpty(this.drawRight,r);let u=this.lines.length>this.height&&t+1>=this.height;return this.drawLine(t-o,this.drawRight,u,r)}drawTop(t){let r=[];return this.cells?this.widths.forEach(function(n,a){r.push(this._topLeftChar(a)),r.push(ln.repeat(this.chars[this.y==0?"top":"mid"],n))},this):(r.push(this._topLeftChar(0)),r.push(ln.repeat(this.chars[this.y==0?"top":"mid"],this.width))),t&&r.push(this.chars[this.y==0?"topRight":"rightMid"]),this.wrapWithStyleColors("border",r.join(""))}_topLeftChar(t){let r=this.x+t,n;if(this.y==0)n=r==0?"topLeft":t==0?"topMid":"top";else if(r==0)n="leftMid";else if(n=t==0?"midMid":"bottomMid",this.cells&&(this.cells[this.y-1][r]instanceof e1.ColSpanCell&&(n=t==0?"topMid":"mid"),t==0)){let o=1;for(;this.cells[this.y][r-o]instanceof e1.ColSpanCell;)o++;this.cells[this.y][r-o]instanceof e1.RowSpanCell&&(n="leftMid")}return this.chars[n]}wrapWithStyleColors(t,r){if(this[t]&&this[t].length)try{let n=Qy();for(let a=this[t].length-1;a>=0;a--)n=n[this[t][a]];return n(r)}catch{return r}else return r}drawLine(t,r,n,a){let o=this.chars[this.x==0?"left":"middle"];if(this.x&&a&&this.cells){let y=this.cells[this.y+a][this.x-1];for(;y instanceof Gc;)y=this.cells[y.y][y.x-1];y instanceof zc||(o=this.chars.rightMid)}let u=ln.repeat(" ",this.paddingLeft),l=r?this.chars.right:"",d=ln.repeat(" ",this.paddingRight),f=this.lines[t],v=this.width-(this.paddingLeft+this.paddingRight);n&&(f+=this.truncate||"\u2026");let g=ln.truncate(f,v,this.truncate);return g=ln.pad(g,v," ",this.hAlign),g=u+g+d,this.stylizeLine(o,g,l)}stylizeLine(t,r,n){return t=this.wrapWithStyleColors("border",t),n=this.wrapWithStyleColors("border",n),this.y===0&&(r=this.wrapWithStyleColors("head",r)),t+r+n}drawBottom(t){let r=this.chars[this.x==0?"bottomLeft":"bottomMid"],n=ln.repeat(this.chars.bottom,this.width),a=t?this.chars.bottomRight:"";return this.wrapWithStyleColors("border",r+n+a)}drawEmpty(t,r){let n=this.chars[this.x==0?"left":"middle"];if(this.x&&r&&this.cells){let u=this.cells[this.y+r][this.x-1];for(;u instanceof Gc;)u=this.cells[u.y][u.x-1];u instanceof zc||(n=this.chars.rightMid)}let a=t?this.chars.right:"",o=ln.repeat(" ",this.width);return this.stylizeLine(n,o,a)}},Gc=class{constructor(){}draw(t){return typeof t=="number"&&xY(`${this.y}-${this.x}: 1x1 ColSpanCell`),""}init(){}mergeTableOptions(){}},zc=class{constructor(t){this.originalCell=t}init(t){let r=this.y,n=this.originalCell.y;this.cellOffset=r-n,this.offset=vNe(t.rowHeights,n,this.cellOffset)}draw(t){return t=="top"?this.originalCell.draw(this.offset,this.cellOffset):t=="bottom"?this.originalCell.draw("bottom"):(xY(`${this.y}-${this.x}: 1x${this.colSpan} RowSpanCell for ${this.originalCell.content}`),this.originalCell.draw(this.offset+1+t))}mergeTableOptions(){}};function vY(...e){return e.filter(t=>t!=null).shift()}function nw(e,t,r,n){let a=r.split("-");a.length>1?(a[1]=a[1].charAt(0).toUpperCase()+a[1].substr(1),a=a.join(""),n[a]=vY(e[a],e[r],t[a],t[r])):n[r]=vY(e[r],t[r])}function vNe(e,t,r){let n=e[t];for(let a=1;a{var{warn:xNe,debug:bNe}=r9(),iw=bY(),{ColSpanCell:yNe,RowSpanCell:_Ne}=iw;(function(){function e(C,S){return C[S]>0?e(C,S+1):S}function t(C){let S={};C.forEach(function(T,O){let N=0;T.forEach(function(j){j.y=O,j.x=O?e(S,N):N;let J=j.rowSpan||1,ie=j.colSpan||1;if(J>1)for(let ae=0;ae{S[j]--,S[j]<1&&delete S[j]})})}function r(C){let S=0;return C.forEach(function(T){T.forEach(function(O){S=Math.max(S,O.x+(O.colSpan||1))})}),S}function n(C){return C.length}function a(C,S){let T=C.y,O=C.y-1+(C.rowSpan||1),N=S.y,j=S.y-1+(S.rowSpan||1),J=!(T>j||N>O),ie=C.x,ae=C.x-1+(C.colSpan||1),be=S.x,pt=S.x-1+(S.colSpan||1),K=!(ie>pt||be>ae);return J&&K}function o(C,S,T){let O=Math.min(C.length-1,T),N={x:S,y:T};for(let j=0;j<=O;j++){let J=C[j];for(let ie=0;ie=0;S--){let T=C[S];for(let O=0;O1?l.push(v):u[v[r]]=Math.max(u[v[r]]||0,v[t]||0,n)})}),a.forEach(function(f,v){typeof f=="number"&&(u[v]=f)});for(let f=l.length-1;f>=0;f--){let v=l[f],g=v[e],y=v[r],C=u[y],S=typeof a[y]=="number"?0:1;if(typeof C=="number")for(let T=1;TC){let T=0;for(;S>0&&v[t]>C;){if(typeof a[y+T]!="number"){let O=Math.round((v[t]-C)/S);C+=O,u[y+T]+=O,S--}T++}}}Object.assign(a,u,d);for(let f=0;f{var Ya=r9(),wNe=rw(),aw=wY(),a9=class extends Array{constructor(t){super();let r=wNe.mergeOptions(t);if(Object.defineProperty(this,"options",{value:r,enumerable:r.debug}),r.debug){switch(typeof r.debug){case"boolean":Ya.setDebugLevel(Ya.WARN);break;case"number":Ya.setDebugLevel(r.debug);break;case"string":Ya.setDebugLevel(parseInt(r.debug,10));break;default:Ya.setDebugLevel(Ya.WARN),Ya.warn(`Debug option is expected to be boolean, number, or string. Received a ${typeof r.debug}`)}Object.defineProperty(this,"messages",{get(){return Ya.debugMessages()}})}}toString(){let t=this,r=this.options.head&&this.options.head.length;r?(t=[this.options.head],this.length&&t.push.apply(t,this)):this.options.style.head=[];let n=aw.makeTableLayout(t);n.forEach(function(o){o.forEach(function(u){u.mergeTableOptions(this.options,n)},this)},this),aw.computeWidths(this.options.colWidths,n),aw.computeHeights(this.options.rowHeights,n),n.forEach(function(o){o.forEach(function(u){u.init(this.options)},this)},this);let a=[];for(let o=0;oYa.reset();function ow(e,t,r){let n=[];e.forEach(function(o){n.push(o.draw(t))});let a=n.join("");a.length&&r.push(a)}EY.exports=a9});var CY=m((uit,SY)=>{SY.exports=DY()});var qNe={};fre(qNe,{DEFAULT_FUNCTION_NAME:()=>Ma,GRAPHQL_ENV_BUILD_PATH:()=>Fc,GRAPHQL_ENV_PRODUCTION_PATH:()=>ti,GRAPHQL_PATH:()=>Jt,GRAPHQL_ROOT:()=>qt,PRISMA_SCHEMA_PATH:()=>Pc,SKEET_CONFIG_PATH:()=>Mu,program:()=>Pe});module.exports=mre(qNe);var yJ=se(a2());var sD=se(oD(),1),{program:HNe,createCommand:GNe,createArgument:zNe,createOption:KNe,CommanderError:YNe,InvalidArgumentError:JNe,InvalidOptionArgumentError:QNe,Command:uD,Argument:ZNe,Option:XNe,Help:eRe}=sD.default;var pD="0.20.2";var lD=(e=0)=>t=>`\x1B[${t+e}m`,dD=(e=0)=>t=>`\x1B[${38+e};5;${t}m`,cD=(e=0)=>(t,r,n)=>`\x1B[${38+e};2;${t};${r};${n}m`,ct={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]}},nRe=Object.keys(ct.modifier),Ure=Object.keys(ct.color),Vre=Object.keys(ct.bgColor),iRe=[...Ure,...Vre];function $re(){let e=new Map;for(let[t,r]of Object.entries(ct)){for(let[n,a]of Object.entries(r))ct[n]={open:`\x1B[${a[0]}m`,close:`\x1B[${a[1]}m`},r[n]=ct[n],e.set(a[0],a[1]);Object.defineProperty(ct,t,{value:r,enumerable:!1})}return Object.defineProperty(ct,"codes",{value:e,enumerable:!1}),ct.color.close="\x1B[39m",ct.bgColor.close="\x1B[49m",ct.color.ansi=lD(),ct.color.ansi256=dD(),ct.color.ansi16m=cD(),ct.bgColor.ansi=lD(10),ct.bgColor.ansi256=dD(10),ct.bgColor.ansi16m=cD(10),Object.defineProperties(ct,{rgbToAnsi256:{value(t,r,n){return t===r&&r===n?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5)},enumerable:!1},hexToRgb:{value(t){let r=/[a-f\d]{6}|[a-f\d]{3}/i.exec(t.toString(16));if(!r)return[0,0,0];let[n]=r;n.length===3&&(n=[...n].map(o=>o+o).join(""));let a=Number.parseInt(n,16);return[a>>16&255,a>>8&255,a&255]},enumerable:!1},hexToAnsi256:{value:t=>ct.rgbToAnsi256(...ct.hexToRgb(t)),enumerable:!1},ansi256ToAnsi:{value(t){if(t<8)return 30+t;if(t<16)return 90+(t-8);let r,n,a;if(t>=232)r=((t-232)*10+8)/255,n=r,a=r;else{t-=16;let l=t%36;r=Math.floor(t/36)/5,n=Math.floor(l/6)/5,a=l%6/5}let o=Math.max(r,n,a)*2;if(o===0)return 30;let u=30+(Math.round(a)<<2|Math.round(n)<<1|Math.round(r));return o===2&&(u+=60),u},enumerable:!1},rgbToAnsi:{value:(t,r,n)=>ct.ansi256ToAnsi(ct.rgbToAnsi256(t,r,n)),enumerable:!1},hexToAnsi:{value:t=>ct.ansi256ToAnsi(ct.hexToAnsi256(t)),enumerable:!1}}),ct}var Wre=$re(),Gn=Wre;var l2=se(require("node:process"),1),mD=se(require("node:os"),1),f7=se(require("node:tty"),1);function yn(e,t=globalThis.Deno?globalThis.Deno.args:l2.default.argv){let r=e.startsWith("-")?"":e.length===1?"-":"--",n=t.indexOf(r+e),a=t.indexOf("--");return n!==-1&&(a===-1||n=2,has16m:e>=3}}function zre(e,{streamIsTTY:t,sniffFlags:r=!0}={}){let n=Hre();n!==void 0&&(p2=n);let a=r?p2:n;if(a===0)return 0;if(r){if(yn("color=16m")||yn("color=full")||yn("color=truecolor"))return 3;if(yn("color=256"))return 2}if("TF_BUILD"in xt&&"AGENT_NAME"in xt)return 1;if(e&&!t&&a===void 0)return 0;let o=a||0;if(xt.TERM==="dumb")return o;if(l2.default.platform==="win32"){let u=mD.default.release().split(".");return Number(u[0])>=10&&Number(u[2])>=10586?Number(u[2])>=14931?3:2:1}if("CI"in xt)return"GITHUB_ACTIONS"in xt||"GITEA_ACTIONS"in xt?3:["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","BUILDKITE","DRONE"].some(u=>u in xt)||xt.CI_NAME==="codeship"?1:o;if("TEAMCITY_VERSION"in xt)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(xt.TEAMCITY_VERSION)?1:0;if(xt.COLORTERM==="truecolor"||xt.TERM==="xterm-kitty")return 3;if("TERM_PROGRAM"in xt){let u=Number.parseInt((xt.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(xt.TERM_PROGRAM){case"iTerm.app":return u>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(xt.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(xt.TERM)||"COLORTERM"in xt?1:o}function fD(e,t={}){let r=zre(e,{streamIsTTY:e&&e.isTTY,...t});return Gre(r)}var Kre={stdout:fD({isTTY:f7.default.isatty(1)}),stderr:fD({isTTY:f7.default.isatty(2)})},hD=Kre;function vD(e,t,r){let n=e.indexOf(t);if(n===-1)return e;let a=t.length,o=0,u="";do u+=e.slice(o,n)+t+r,o=n+a,n=e.indexOf(t,o);while(n!==-1);return u+=e.slice(o),u}function gD(e,t,r,n){let a=0,o="";do{let u=e[n-1]==="\r";o+=e.slice(a,u?n-1:n)+t+(u?`\r +`)[0].length}};a9.reset=()=>Ya.reset();function ow(e,t,r){let n=[];e.forEach(function(o){n.push(o.draw(t))});let a=n.join("");a.length&&r.push(a)}EY.exports=a9});var CY=m((uit,SY)=>{SY.exports=DY()});var qNe={};fre(qNe,{DEFAULT_FUNCTION_NAME:()=>Ma,GRAPHQL_ENV_BUILD_PATH:()=>Fc,GRAPHQL_ENV_PRODUCTION_PATH:()=>ti,GRAPHQL_PATH:()=>Jt,GRAPHQL_ROOT:()=>qt,PRISMA_SCHEMA_PATH:()=>Pc,SKEET_CONFIG_PATH:()=>Mu,program:()=>Pe});module.exports=mre(qNe);var yJ=se(a2());var sD=se(oD(),1),{program:HNe,createCommand:GNe,createArgument:zNe,createOption:KNe,CommanderError:YNe,InvalidArgumentError:JNe,InvalidOptionArgumentError:QNe,Command:uD,Argument:ZNe,Option:XNe,Help:eRe}=sD.default;var pD="0.20.3";var lD=(e=0)=>t=>`\x1B[${t+e}m`,dD=(e=0)=>t=>`\x1B[${38+e};5;${t}m`,cD=(e=0)=>(t,r,n)=>`\x1B[${38+e};2;${t};${r};${n}m`,ct={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]}},nRe=Object.keys(ct.modifier),Ure=Object.keys(ct.color),Vre=Object.keys(ct.bgColor),iRe=[...Ure,...Vre];function $re(){let e=new Map;for(let[t,r]of Object.entries(ct)){for(let[n,a]of Object.entries(r))ct[n]={open:`\x1B[${a[0]}m`,close:`\x1B[${a[1]}m`},r[n]=ct[n],e.set(a[0],a[1]);Object.defineProperty(ct,t,{value:r,enumerable:!1})}return Object.defineProperty(ct,"codes",{value:e,enumerable:!1}),ct.color.close="\x1B[39m",ct.bgColor.close="\x1B[49m",ct.color.ansi=lD(),ct.color.ansi256=dD(),ct.color.ansi16m=cD(),ct.bgColor.ansi=lD(10),ct.bgColor.ansi256=dD(10),ct.bgColor.ansi16m=cD(10),Object.defineProperties(ct,{rgbToAnsi256:{value(t,r,n){return t===r&&r===n?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5)},enumerable:!1},hexToRgb:{value(t){let r=/[a-f\d]{6}|[a-f\d]{3}/i.exec(t.toString(16));if(!r)return[0,0,0];let[n]=r;n.length===3&&(n=[...n].map(o=>o+o).join(""));let a=Number.parseInt(n,16);return[a>>16&255,a>>8&255,a&255]},enumerable:!1},hexToAnsi256:{value:t=>ct.rgbToAnsi256(...ct.hexToRgb(t)),enumerable:!1},ansi256ToAnsi:{value(t){if(t<8)return 30+t;if(t<16)return 90+(t-8);let r,n,a;if(t>=232)r=((t-232)*10+8)/255,n=r,a=r;else{t-=16;let l=t%36;r=Math.floor(t/36)/5,n=Math.floor(l/6)/5,a=l%6/5}let o=Math.max(r,n,a)*2;if(o===0)return 30;let u=30+(Math.round(a)<<2|Math.round(n)<<1|Math.round(r));return o===2&&(u+=60),u},enumerable:!1},rgbToAnsi:{value:(t,r,n)=>ct.ansi256ToAnsi(ct.rgbToAnsi256(t,r,n)),enumerable:!1},hexToAnsi:{value:t=>ct.ansi256ToAnsi(ct.hexToAnsi256(t)),enumerable:!1}}),ct}var Wre=$re(),Gn=Wre;var l2=se(require("node:process"),1),mD=se(require("node:os"),1),f7=se(require("node:tty"),1);function yn(e,t=globalThis.Deno?globalThis.Deno.args:l2.default.argv){let r=e.startsWith("-")?"":e.length===1?"-":"--",n=t.indexOf(r+e),a=t.indexOf("--");return n!==-1&&(a===-1||n=2,has16m:e>=3}}function zre(e,{streamIsTTY:t,sniffFlags:r=!0}={}){let n=Hre();n!==void 0&&(p2=n);let a=r?p2:n;if(a===0)return 0;if(r){if(yn("color=16m")||yn("color=full")||yn("color=truecolor"))return 3;if(yn("color=256"))return 2}if("TF_BUILD"in xt&&"AGENT_NAME"in xt)return 1;if(e&&!t&&a===void 0)return 0;let o=a||0;if(xt.TERM==="dumb")return o;if(l2.default.platform==="win32"){let u=mD.default.release().split(".");return Number(u[0])>=10&&Number(u[2])>=10586?Number(u[2])>=14931?3:2:1}if("CI"in xt)return"GITHUB_ACTIONS"in xt||"GITEA_ACTIONS"in xt?3:["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","BUILDKITE","DRONE"].some(u=>u in xt)||xt.CI_NAME==="codeship"?1:o;if("TEAMCITY_VERSION"in xt)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(xt.TEAMCITY_VERSION)?1:0;if(xt.COLORTERM==="truecolor"||xt.TERM==="xterm-kitty")return 3;if("TERM_PROGRAM"in xt){let u=Number.parseInt((xt.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(xt.TERM_PROGRAM){case"iTerm.app":return u>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(xt.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(xt.TERM)||"COLORTERM"in xt?1:o}function fD(e,t={}){let r=zre(e,{streamIsTTY:e&&e.isTTY,...t});return Gre(r)}var Kre={stdout:fD({isTTY:f7.default.isatty(1)}),stderr:fD({isTTY:f7.default.isatty(2)})},hD=Kre;function vD(e,t,r){let n=e.indexOf(t);if(n===-1)return e;let a=t.length,o=0,u="";do u+=e.slice(o,n)+t+r,o=n+a,n=e.indexOf(t,o);while(n!==-1);return u+=e.slice(o),u}function gD(e,t,r,n){let a=0,o="";do{let u=e[n-1]==="\r";o+=e.slice(a,u?n-1:n)+t+(u?`\r `:` `)+r,a=n+1,n=e.indexOf(` `,a)}while(n!==-1);return o+=e.slice(a),o}var{stdout:xD,stderr:bD}=hD,m7=Symbol("GENERATOR"),A1=Symbol("STYLER"),Ll=Symbol("IS_EMPTY"),yD=["ansi","ansi","ansi256","ansi16m"],O1=Object.create(null),Yre=(e,t={})=>{if(t.level&&!(Number.isInteger(t.level)&&t.level>=0&&t.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");let r=xD?xD.level:0;e.level=t.level===void 0?r:t.level};var Jre=e=>{let t=(...r)=>r.join(" ");return Yre(t,e),Object.setPrototypeOf(t,jl.prototype),t};function jl(e){return Jre(e)}Object.setPrototypeOf(jl.prototype,Function.prototype);for(let[e,t]of Object.entries(Gn))O1[e]={get(){let r=d2(this,v7(t.open,t.close,this[A1]),this[Ll]);return Object.defineProperty(this,e,{value:r}),r}};O1.visible={get(){let e=d2(this,this[A1],!0);return Object.defineProperty(this,"visible",{value:e}),e}};var h7=(e,t,r,...n)=>e==="rgb"?t==="ansi16m"?Gn[r].ansi16m(...n):t==="ansi256"?Gn[r].ansi256(Gn.rgbToAnsi256(...n)):Gn[r].ansi(Gn.rgbToAnsi(...n)):e==="hex"?h7("rgb",t,r,...Gn.hexToRgb(...n)):Gn[r][e](...n),Qre=["rgb","hex","ansi256"];for(let e of Qre){O1[e]={get(){let{level:r}=this;return function(...n){let a=v7(h7(e,yD[r],"color",...n),Gn.color.close,this[A1]);return d2(this,a,this[Ll])}}};let t="bg"+e[0].toUpperCase()+e.slice(1);O1[t]={get(){let{level:r}=this;return function(...n){let a=v7(h7(e,yD[r],"bgColor",...n),Gn.bgColor.close,this[A1]);return d2(this,a,this[Ll])}}}}var Zre=Object.defineProperties(()=>{},{...O1,level:{enumerable:!0,get(){return this[m7].level},set(e){this[m7].level=e}}}),v7=(e,t,r)=>{let n,a;return r===void 0?(n=e,a=t):(n=r.openAll+e,a=t+r.closeAll),{open:e,close:t,openAll:n,closeAll:a,parent:r}},d2=(e,t,r)=>{let n=(...a)=>Xre(n,a.length===1?""+a[0]:a.join(" "));return Object.setPrototypeOf(n,Zre),n[m7]=e,n[A1]=t,n[Ll]=r,n},Xre=(e,t)=>{if(e.level<=0||!t)return e[Ll]?"":t;let r=e[A1];if(r===void 0)return t;let{openAll:n,closeAll:a}=r;if(t.includes("\x1B"))for(;r!==void 0;)t=vD(t,r.close,r.open),r=r.parent;let o=t.indexOf(` @@ -441,7 +441,7 @@ firebase-debug.log **/public/workbox-*.js.map **/public/worker-*.js.map **/public/fallback-*.js - `),{filePath:r,body:n}};var MU=se(B8()),UU=async(e,t)=>{let r=`${e}/skeet-cloud.config.json`,n=await dSe(),a=t==="Next.js (React) - GraphQL"?[{queueName:"createUser",location:"asia-northeast1",maxAttempts:3,maxConcurrent:1,maxRate:1,maxInterval:"10s",minInterval:"1s"},{queueName:"createChatRoomMessage",location:"asia-northeast1",maxAttempts:3,maxConcurrent:1,maxRate:1,maxInterval:"10s",minInterval:"1s"}]:[],o=`{ + `),{filePath:r,body:n}};var MU=se(B8()),UU=async(e,t)=>{let r=`${e}/skeet-cloud.config.json`,n=await dSe(),a=t==="Next.js (React) - GraphQL"?[{queueName:"createUser",location:"asia-northeast1",maxAttempts:3,maxConcurrent:1,maxRate:1,maxInterval:"10s",minInterval:"1s"},{queueName:"createChatRoomMessage",location:"asia-northeast1",maxAttempts:3,maxConcurrent:1,maxRate:1,maxInterval:"10s",minInterval:"1s"}]:[],o=t==="Next.js (React) - GraphQL"?{name:`skeet-${e}-graphql`,url:"",cpu:1,maxConcurrency:80,maxInstances:100,minInstances:0,memory:"4Gi"}:{},u=t==="Next.js (React) - GraphQL"?{databaseVersion:"POSTGRES_15",cpu:1,memory:"3840MiB",storageSize:10,whiteList:""}:{},l=`{ "app": { "name": "${e}", "projectId": "${e}", @@ -451,22 +451,8 @@ firebase-debug.log "nsDomain": "your-nameserver.com", "lbDomain": "loadbalancer.your-app-url.com" }, - "cloudRun": { - "name": "skeet-${e}-graphql", - "url": "", - "cpu": 1, - "maxConcurrency": 80, - "maxInstances": 100, - "minInstances": 0, - "memory": "4Gi" - }, - "db": { - "databaseVersion": "POSTGRES_15", - "cpu": 1, - "memory": "3840MiB", - "storageSize": 10, - "whiteList": "" - }, + "cloudRun": ${o}, + "db": ${u}, "taskQueues": ${JSON.stringify(a)}, "cloudArmor": [ { @@ -499,7 +485,7 @@ firebase-debug.log } ] } -`;return{filePath:r,body:o}},dSe=async()=>{try{return(await(await cSe("https://api.ipify.org/?format=json")).json()).ip.replace(/\r?\n/g,"")}catch{return""}},cSe=async e=>{try{return await(0,MU.default)(e,{method:"GET",headers:{"Content-Type":"application/json"}})}catch(t){throw console.log({e:t}),new Error("sendGET failed")}};var VU=require("fs"),$U=async e=>{(0,VU.mkdirSync)(".github/workflows",{recursive:!0});let t="18.16.0",r=Hr(e),n=In(e),a=`functions-${n}.yml`,o=`.github/workflows/${a}`,u=`name: ${r} +`;return{filePath:r,body:l}},dSe=async()=>{try{return(await(await cSe("https://api.ipify.org/?format=json")).json()).ip.replace(/\r?\n/g,"")}catch{return""}},cSe=async e=>{try{return await(0,MU.default)(e,{method:"GET",headers:{"Content-Type":"application/json"}})}catch(t){throw console.log({e:t}),new Error("sendGET failed")}};var VU=require("fs"),$U=async e=>{(0,VU.mkdirSync)(".github/workflows",{recursive:!0});let t="18.16.0",r=Hr(e),n=In(e),a=`functions-${n}.yml`,o=`.github/workflows/${a}`,u=`name: ${r} on: push: branches: diff --git a/src/lib/version.ts b/src/lib/version.ts index 3c5b8dab..2c6b6981 100644 --- a/src/lib/version.ts +++ b/src/lib/version.ts @@ -1 +1 @@ -export const VERSION = '0.20.2' \ No newline at end of file +export const VERSION = '0.20.3' \ No newline at end of file