UNPKG

@northflank/cli

Version:

Provides a command-line interface to the Northflank platform.

1 lines 4.99 kB
'use strict';const a7c=a7K;(function(Z,K){const I=a7K,O=Z();while(!![]){try{const g=parseInt(I(0x9c))/0x1+parseInt(I(0xbb))/0x2+-parseInt(I(0xbc))/0x3+-parseInt(I(0x8e))/0x4*(parseInt(I(0xb7))/0x5)+-parseInt(I(0x88))/0x6*(-parseInt(I(0x9d))/0x7)+parseInt(I(0xb1))/0x8*(parseInt(I(0x87))/0x9)+parseInt(I(0xb4))/0xa*(parseInt(I(0xb3))/0xb);if(g===K)break;else O['push'](O['shift']());}catch(N){O['push'](O['shift']());}}}(a7Z,0x82eab));function a7Z(){const b=['includes','1236408ZciiWK','defineProperty','hasOwnProperty','stringify','replace','keys','printAsTable','format','disabled','inspect','toString','sort','chalk','printResponse','420359OXxTNi','63OitzfC','length','get','util','log','writable','handleYamlOutput','js-yaml','__importStar','isObjectLike','getSeconds','getDate','handleFormattedOutput','createdat','updatedat','call','\x20(HTTP\x20status:\x20','getMinutes','map','create','2609608zujezK','__importDefault','198cqFUqH','319170uPFQMu','consoleFormat','isUndefined','10exGmMK','lodash','handleJsonOutput','__esModule','438640IymhaI','1463778GofyFp','toLowerCase','default','getOwnPropertyDescriptor','getHours','getFullYear','\x20found','bold','columnify','The\x20request\x20was\x20completed\x20successfully','9Donfph','67986GXbNdR','configurable','set','isEmpty','getMonth'];a7Z=function(){return b;};return a7Z();}var __createBinding=this&&this['__createBinding']||(Object[a7c(0xb0)]?function(Z,K,O,g){const E=a7c;if(g===undefined)g=O;var N=Object[E(0xbf)](K,O);(!N||(E(0x9f)in N?!K[E(0xba)]:N[E(0xa2)]||N[E(0x89)]))&&(N={'enumerable':!![],'get':function(){return K[O];}}),Object[E(0x8f)](Z,g,N);}:function(Z,K,O,g){if(g===undefined)g=O;Z[g]=K[O];}),__setModuleDefault=this&&this['__setModuleDefault']||(Object[a7c(0xb0)]?function(Z,K){const p=a7c;Object[p(0x8f)](Z,p(0xbe),{'enumerable':!![],'value':K});}:function(Z,K){const T=a7c;Z[T(0xbe)]=K;}),__importStar=this&&this[a7c(0xa5)]||function(Z){const J=a7c;if(Z&&Z[J(0xba)])return Z;var K={};if(Z!=null){for(var O in Z)if(O!=='default'&&Object['prototype'][J(0x90)][J(0xac)](Z,O))__createBinding(K,Z,O);}return __setModuleDefault(K,Z),K;},__importDefault=this&&this[a7c(0xb2)]||function(Z){const q=a7c;return Z&&Z[q(0xba)]?Z:{'default':Z};};Object[a7c(0x8f)](exports,a7c(0xba),{'value':!![]}),exports['printResponse']=exports[a7c(0xa9)]=exports[a7c(0xa3)]=exports[a7c(0xb9)]=exports[a7c(0xb5)]=exports['printAsTable']=void 0x0;const chalk_1=__importDefault(require(a7c(0x9a))),_=__importStar(require(a7c(0xb8))),util=__importStar(require(a7c(0xa0))),yaml=require(a7c(0xa4)),columnify=require(a7c(0x85));function printAsTable(Z,K,O,g=![],N=0x0){const Y=a7c;!g&&console['log'](''+chalk_1[Y(0xbe)][Y(0xc3)](K));function H(s){const P=Y;return s===P(0x96)?s:s[P(0x92)](P(0x96),'');}function o(s,R){const S=Y;function y(B){const C=a7K,V=new Date(B);return V[C(0xa8)]()+'/'+V[C(0x8c)]()+'/'+V[C(0xc1)]()+'\x0a'+V[C(0xc0)]()+':'+V[C(0xae)]()+':'+V[C(0xa7)]();}const W=[S(0xaa),S(0xab)];if(W[S(0x8d)](R['toLowerCase']())&&_['isFinite'](s)&&s[S(0x98)]()['length']===0xd)return y(Number(s));if(_['isBoolean'](s)){if(R!==S(0x96)&&R['includes']('disabled'))return s?'x':'✔';return s?'✔':'x';}if(_[S(0xa6)](s))return util[S(0x97)](s,{'showHidden':![],'depth':null,'colors':!![],'compact':!![]});return s;}if(_['isArrayLike'](Z)){Z[Y(0x9e)]===0x0&&console[Y(0xa1)]('No\x20'+K['toLowerCase']()+Y(0xc2));const s=Z[Y(0xaf)]((W,B)=>{const n=Y,V={'i':B+N};return Object[n(0x93)](W)['forEach'](M=>{const k=n;(_[k(0xb6)](O)||O[k(0x8d)](M[k(0xbd)]()))&&_[k(0x8a)](V,H(M),o(W[M],M));}),V;}),R=_['clone'](Object[Y(0x93)]((s===null||s===void 0x0?void 0x0:s[0x0])||[]))[Y(0x99)]((W,B)=>{const V=M=>M!=='i'?M!=='internalId'?0x0:0x1:0x2;return V(B)-V(W);}),y={'maxWidth':0x1e,'preserveNewLines':!![],'showHeaders':!g,'config':{'_id':{'maxWidth':0x5,'truncate':!![]},'i':{'showHeaders':![]}},'columns':R};console[Y(0xa1)](columnify(s,y));}else console[Y(0xa1)](Z);}exports[a7c(0x94)]=printAsTable;function consoleFormat(Z,K){const x=a7c;if(_[x(0x8b)](Z)){const O=K?x(0xad)+K+')':'';return chalk_1[x(0xbe)]['green'](x(0x86))+O;}if(!_[x(0xa6)](Z))return Z===null||Z===void 0x0?void 0x0:Z[x(0x98)]();return util['inspect'](Z,{'showHidden':![],'depth':null,'colors':!![],'compact':!![]});}exports[a7c(0xb5)]=consoleFormat;const handleJsonOutput=(Z,K)=>{const m=a7c,O=Z==='json';if(O)console[m(0xa1)](JSON[m(0x91)](K,null,'\x20'));};exports[a7c(0xb9)]=handleJsonOutput;function a7K(Z,K){const O=a7Z();return a7K=function(g,N){g=g-0x85;let H=O[g];return H;},a7K(Z,K);}const handleYamlOutput=(Z,K)=>{const r=a7c,O=Z==='yaml'||Z==='yml';if(O)console[r(0xa1)](yaml['safeDump'](K));};exports[a7c(0xa3)]=handleYamlOutput;const handleFormattedOutput=(Z,K)=>{const D=a7c,O=Z===D(0x95);if(O)console[D(0xa1)](consoleFormat(K));};exports[a7c(0xa9)]=handleFormattedOutput;const printResponse=(Z,K)=>{const d=a7c;(0x0,exports[d(0xb9)])(Z,K),(0x0,exports['handleYamlOutput'])(Z,K),(0x0,exports['handleFormattedOutput'])(Z,K);};exports[a7c(0x9b)]=printResponse;