From 2bbba4d1be99ebbeee62ef029e85e45f4ef66513 Mon Sep 17 00:00:00 2001 From: POPPIN-FUMI Date: Tue, 1 Aug 2023 12:32:02 +0200 Subject: [PATCH] fix skeet config gen --- README.md | 2 +- dist/index.js | 6 +++--- package.json | 2 +- src/lib/version.ts | 2 +- src/templates/init/skeet-cloud.config.ts | 4 ++-- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index c973c4ac..b957176b 100755 --- a/README.md +++ b/README.md @@ -82,7 +82,7 @@ $ npm install -g firebase-tools $ skeet create ``` -![Skeet Create Command](https://storage.googleapis.com/skeet-assets/imgs/backend/skeet-createv0.21.png) +![Skeet Create Command](https://storage.googleapis.com/skeet-assets/imgs/backend/skeet-create-v0.22.png) You can choose a template for the frontend. diff --git a/dist/index.js b/dist/index.js index 255dc957..7d4178a4 100755 --- a/dist/index.js +++ b/dist/index.js @@ -87,7 +87,7 @@ function print() { __p += __j.call(arguments, '') } `);let a=r?cNe:fNe;for(let o=0;o{var{info:gNe,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={};bNe.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||gNe(`${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=xNe(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 xNe(e,t,r){let n=e[t];for(let a=1;a{var{warn:yNe,debug:_Ne}=r9(),iw=bY(),{ColSpanCell:wNe,RowSpanCell:ENe}=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(),DNe=rw(),aw=wY(),a9=class extends Array{constructor(t){super();let r=DNe.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((lit,SY)=>{SY.exports=DY()});var kNe={};hre(kNe,{DEFAULT_FUNCTION_NAME:()=>Ma,GRAPHQL_ENV_BUILD_PATH:()=>Fc,GRAPHQL_ENV_PRODUCTION_PATH:()=>ti,GRAPHQL_PATH:()=>Jt,GRAPHQL_ROOT:()=>At,PRISMA_SCHEMA_PATH:()=>Pc,SKEET_CONFIG_PATH:()=>Mu,program:()=>Pe});module.exports=vre(kNe);var wJ=se(a2());var sD=se(oD(),1),{program:zNe,createCommand:KNe,createArgument:YNe,createOption:JNe,CommanderError:QNe,InvalidArgumentError:ZNe,InvalidOptionArgumentError:XNe,Command:uD,Argument:eRe,Option:tRe,Help:rRe}=sD.default;var pD="0.22.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]}},aRe=Object.keys(ct.modifier),$re=Object.keys(ct.color),Wre=Object.keys(ct.bgColor),oRe=[...$re,...Wre];function Hre(){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 Gre=Hre(),Gn=Gre;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 Yre(e,{streamIsTTY:t,sniffFlags:r=!0}={}){let n=zre();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=Yre(e,{streamIsTTY:e&&e.isTTY,...t});return Kre(r)}var Jre={stdout:fD({isTTY:f7.default.isatty(1)}),stderr:fD({isTTY:f7.default.isatty(2)})},hD=Jre;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((lit,SY)=>{SY.exports=DY()});var kNe={};hre(kNe,{DEFAULT_FUNCTION_NAME:()=>Ma,GRAPHQL_ENV_BUILD_PATH:()=>Fc,GRAPHQL_ENV_PRODUCTION_PATH:()=>ti,GRAPHQL_PATH:()=>Jt,GRAPHQL_ROOT:()=>At,PRISMA_SCHEMA_PATH:()=>Pc,SKEET_CONFIG_PATH:()=>Mu,program:()=>Pe});module.exports=vre(kNe);var wJ=se(a2());var sD=se(oD(),1),{program:zNe,createCommand:KNe,createArgument:YNe,createOption:JNe,CommanderError:QNe,InvalidArgumentError:ZNe,InvalidOptionArgumentError:XNe,Command:uD,Argument:eRe,Option:tRe,Help:rRe}=sD.default;var pD="0.22.4";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]}},aRe=Object.keys(ct.modifier),$re=Object.keys(ct.color),Wre=Object.keys(ct.bgColor),oRe=[...$re,...Wre];function Hre(){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 Gre=Hre(),Gn=Gre;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 Yre(e,{streamIsTTY:t,sniffFlags:r=!0}={}){let n=zre();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=Yre(e,{streamIsTTY:e&&e.isTTY,...t});return Kre(r)}var Jre={stdout:fD({isTTY:f7.default.isatty(1)}),stderr:fD({isTTY:f7.default.isatty(2)})},hD=Jre;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),Qre=(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 Zre=e=>{let t=(...r)=>r.join(" ");return Qre(t,e),Object.setPrototypeOf(t,jl.prototype),t};function jl(e){return Zre(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),Xre=["rgb","hex","ansi256"];for(let e of Xre){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 ene=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)=>tne(n,a.length===1?""+a[0]:a.join(" "));return Object.setPrototypeOf(n,ene),n[m7]=e,n[A1]=t,n[Ll]=r,n},tne=(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(` @@ -452,8 +452,8 @@ firebase-debug.log "lbDomain": "loadbalancer.your-app-url.com", "functionsDomain": "functions.your-app-url.com", }, - "cloudRun": ${o}, - "db": ${u}, + "cloudRun": ${JSON.stringify(o)}, + "db": ${JSON.stringify(u)}, "taskQueues": ${JSON.stringify(a)}, "cloudArmor": [ { diff --git a/package.json b/package.json index 00589a31..51ceb32e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@skeet-framework/cli", - "version": "0.22.3", + "version": "0.22.4", "description": "Skeet CLI", "main": "dist/index.js", "repository": "https://github.com/elsoul/skeet-cli", diff --git a/src/lib/version.ts b/src/lib/version.ts index 17da418c..d800dc3e 100644 --- a/src/lib/version.ts +++ b/src/lib/version.ts @@ -1 +1 @@ -export const VERSION = '0.22.3' \ No newline at end of file +export const VERSION = '0.22.4' \ No newline at end of file diff --git a/src/templates/init/skeet-cloud.config.ts b/src/templates/init/skeet-cloud.config.ts index d218182b..dec0e17a 100644 --- a/src/templates/init/skeet-cloud.config.ts +++ b/src/templates/init/skeet-cloud.config.ts @@ -63,8 +63,8 @@ export const skeetCloudConfigGen = async ( "lbDomain": "loadbalancer.your-app-url.com", "functionsDomain": "functions.your-app-url.com", }, - "cloudRun": ${cloudRunBody}, - "db": ${dbBody}, + "cloudRun": ${JSON.stringify(cloudRunBody)}, + "db": ${JSON.stringify(dbBody)}, "taskQueues": ${JSON.stringify(taskQueues)}, "cloudArmor": [ {