@cognite/cli 0.6.0-alpha.8 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli/cli.js +1 -1
- package/package.json +1 -1
package/dist/cli/cli.js
CHANGED
|
@@ -317,7 +317,7 @@ Cancelled.`),process.exit(130)),console.error(t),process.exit(1)}))}a(BM,"instal
|
|
|
317
317
|
`)+r,n=i+1,i=t.indexOf(`
|
|
318
318
|
`,n)}while(i!==-1);return s+=t.slice(n),s}a(Bj,"stringEncaseCRLFWithFirstIndex");var{stdout:Rj,stderr:Tj}=Dj,oE=Symbol("GENERATOR"),qu=Symbol("STYLER"),w1=Symbol("IS_EMPTY"),Oj=["ansi","ansi","ansi256","ansi16m"],Qu=Object.create(null),pwe=a((t,e={})=>{if(e.level&&!(Number.isInteger(e.level)&&e.level>=0&&e.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");let r=Rj?Rj.level:0;t.level=e.level===void 0?r:e.level},"applyOptions");var dwe=a(t=>{let e=a((...r)=>r.join(" "),"chalk");return pwe(e,t),Object.setPrototypeOf(e,b1.prototype),e},"chalkFactory");function b1(t){return dwe(t)}a(b1,"createChalk");Object.setPrototypeOf(b1.prototype,Function.prototype);for(let[t,e]of Object.entries(mi))Qu[t]={get(){let r=Ih(this,lE(e.open,e.close,this[qu]),this[w1]);return Object.defineProperty(this,t,{value:r}),r}};Qu.visible={get(){let t=Ih(this,this[qu],!0);return Object.defineProperty(this,"visible",{value:t}),t}};var uE=a((t,e,r,...i)=>t==="rgb"?e==="ansi16m"?mi[r].ansi16m(...i):e==="ansi256"?mi[r].ansi256(mi.rgbToAnsi256(...i)):mi[r].ansi(mi.rgbToAnsi(...i)):t==="hex"?uE("rgb",e,r,...mi.hexToRgb(...i)):mi[r][t](...i),"getModelAnsi"),cwe=["rgb","hex","ansi256"];for(let t of cwe){Qu[t]={get(){let{level:r}=this;return function(...i){let n=lE(uE(t,Oj[r],"color",...i),mi.color.close,this[qu]);return Ih(this,n,this[w1])}}};let e="bg"+t[0].toUpperCase()+t.slice(1);Qu[e]={get(){let{level:r}=this;return function(...i){let n=lE(uE(t,Oj[r],"bgColor",...i),mi.bgColor.close,this[qu]);return Ih(this,n,this[w1])}}}}var fwe=Object.defineProperties(()=>{},{...Qu,level:{enumerable:!0,get(){return this[oE].level},set(t){this[oE].level=t}}}),lE=a((t,e,r)=>{let i,n;return r===void 0?(i=t,n=e):(i=r.openAll+t,n=e+r.closeAll),{open:t,close:e,openAll:i,closeAll:n,parent:r}},"createStyler"),Ih=a((t,e,r)=>{let i=a((...n)=>hwe(i,n.length===1?""+n[0]:n.join(" ")),"builder");return Object.setPrototypeOf(i,fwe),i[oE]=t,i[qu]=e,i[w1]=r,i},"createBuilder"),hwe=a((t,e)=>{if(t.level<=0||!e)return t[w1]?"":e;let r=t[qu];if(r===void 0)return e;let{openAll:i,closeAll:n}=r;if(e.includes("\x1B"))for(;r!==void 0;)e=Ij(e,r.close,r.open),r=r.parent;let s=e.indexOf(`
|
|
319
319
|
`);return s!==-1&&(e=Bj(e,n,i,s)),i+e+n},"applyStyle");Object.defineProperties(b1.prototype,Qu);var PLe=b1(),pE=b1({level:Tj?Tj.level:0});function Fj(t,e){let r=[`\u26A0 Update available: ${t} -> ${e}`," Run npx @cognite/dune@latest"],i=Math.max(...r.map(u=>[...u].length))+2,n="\u2500".repeat(i),s=a(u=>`\u2502 ${u}${" ".repeat(i-1-[...u].length)}\u2502`,"pad"),o=[`\u250C${n}\u2510`,...r.map(s),`\u2514${n}\u2518`].join(`
|
|
320
|
-
`);return pE.bold.yellow(o)}a(Fj,"formatUpgradeWarning");function Awe(t){return t instanceof Error&&"code"in t&&typeof t.code=="string"&&t.code==="DEP0040"}a(Awe,"isDep0040Warning");var dE=process,gwe=dE.emit.bind(dE);dE.emit=function(t,...e){return t==="warning"&&Awe(e[0])?!1:gwe(t,...e)};BM();var Pa=new mwe;Pa.name("dune").description("Build and deploy React apps to Cognite Data Fusion").version("0.6.0
|
|
320
|
+
`);return pE.bold.yellow(o)}a(Fj,"formatUpgradeWarning");function Awe(t){return t instanceof Error&&"code"in t&&typeof t.code=="string"&&t.code==="DEP0040"}a(Awe,"isDep0040Warning");var dE=process,gwe=dE.emit.bind(dE);dE.emit=function(t,...e){return t==="warning"&&Awe(e[0])?!1:gwe(t,...e)};BM();var Pa=new mwe;Pa.name("dune").description("Build and deploy React apps to Cognite Data Fusion").version("0.6.0");Pa.hook("preAction",()=>{wj("0.6.0",{onOutdated:a((t,e)=>{console.warn(`
|
|
321
321
|
${Fj(t,e)}
|
|
322
322
|
`)},"onOutdated")})});CO(Pa);SM(Pa);xM(Pa);cE(Pa);var Bh=process.argv.slice(2);(Bh[0]==="."||Bh[0]==="./")&&Bh.unshift("create");Pa.parseAsync(Bh,{from:"user"}).catch(t=>{My(t)&&(console.error(`
|
|
323
323
|
Cancelled.`),process.exit(130)),console.error(t instanceof Error?`\u274C ${t.message}`:t),process.exit(1)});
|