@lovrabet/rabetbase-cli 2.0.9 → 2.0.11
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/lib/api/api-doc.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/doc.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/add.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/remote.js +1 -1
- package/lib/commands/app/remove.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app/use.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/new.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/links.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/init/index.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/update.js +1 -1
- package/lib/commands/project/create/enhanced-guided-create.js +1 -1
- package/lib/commands/project/create/format-elapsed.js +1 -1
- package/lib/commands/project/create/main.js +1 -1
- package/lib/commands/project/create/non-interactive.js +1 -1
- package/lib/commands/project/create/project-template-path.js +1 -1
- package/lib/commands/project/create/use-copy-project-template.js +1 -1
- package/lib/commands/project/create/use-format-code.js +1 -1
- package/lib/commands/project/create/use-install-dependencies.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/init.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/run/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/skill/index.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/sql/list.js +1 -1
- package/lib/commands/sql/save.js +1 -1
- package/lib/commands/sql/validate.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/paths.js +1 -0
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/sql-validator.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/flags.js +1 -1
- package/lib/framework/help.js +1 -1
- package/lib/framework/index.js +1 -1
- package/lib/framework/output.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.js +1 -1
- package/lib/help.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/telemetry/cli-command-trace.js +1 -1
- package/lib/telemetry/cli-help-trace.js +1 -1
- package/lib/telemetry/ensure-cli-otel-config.js +1 -1
- package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
- package/lib/telemetry/send-cli-trace-log.js +1 -1
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/copy-directory.js +1 -1
- package/lib/utils/file-utils.js +1 -1
- package/lib/utils/guides-cdn.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/is-non-interactive.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/rules-cdn.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/package.json +2 -2
package/lib/core/bff/hash.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x295dfb,_0x49a8b9){const _0x30a16a=a96_0x2157,_0x57ee59=_0x295dfb();while(!![]){try{const _0x1a9b84=-parseInt(_0x30a16a(0x1ad))/0x1*(-parseInt(_0x30a16a(0x1b3))/0x2)+-parseInt(_0x30a16a(0x1b4))/0x3*(-parseInt(_0x30a16a(0x1b7))/0x4)+parseInt(_0x30a16a(0x1ab))/0x5*(parseInt(_0x30a16a(0x1b8))/0x6)+-parseInt(_0x30a16a(0x1ba))/0x7+parseInt(_0x30a16a(0x1b2))/0x8+parseInt(_0x30a16a(0x1b6))/0x9*(parseInt(_0x30a16a(0x1b1))/0xa)+-parseInt(_0x30a16a(0x1b9))/0xb;if(_0x1a9b84===_0x49a8b9)break;else _0x57ee59['push'](_0x57ee59['shift']());}catch(_0x265c27){_0x57ee59['push'](_0x57ee59['shift']());}}}(a96_0x46dd,0x91999));import{readFile}from'node:fs/promises';import a96_0x201f62 from'node:crypto';function a96_0x2157(_0x433ac1,_0x13db7e){_0x433ac1=_0x433ac1-0x1ab;const _0x46dd0b=a96_0x46dd();let _0x2157e4=_0x46dd0b[_0x433ac1];return _0x2157e4;}export function computeContentHash(_0x5ed104){const _0x3ad077=a96_0x2157;return a96_0x201f62[_0x3ad077(0x1ae)](_0x3ad077(0x1af))[_0x3ad077(0x1ac)](_0x5ed104)['digest'](_0x3ad077(0x1b5));}function a96_0x46dd(){const _0x2fbf38=['3076108QeXIEE','8735JANrjA','update','7GRdKKh','createHash','md5','utf8','3967840uptRpK','4657024rMiqKF','65434mWEnzE','507363WzSzyk','hex','18DdlVdU','4esIxnQ','2238cioYaM','15286106QQLUeI'];a96_0x46dd=function(){return _0x2fbf38;};return a96_0x46dd();}export async function computeFileHash(_0x101808){const _0x585a14=a96_0x2157,_0x28e408=await readFile(_0x101808,_0x585a14(0x1b0));return computeContentHash(_0x28e408);}
|
package/lib/core/bff/lock.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1afa42,_0x32950b){const _0x2abf99=a97_0xfd35,_0x5766ff=_0x1afa42();while(!![]){try{const _0x518e78=parseInt(_0x2abf99(0x6f))/0x1+-parseInt(_0x2abf99(0x7b))/0x2+parseInt(_0x2abf99(0x76))/0x3+parseInt(_0x2abf99(0x67))/0x4*(parseInt(_0x2abf99(0x6b))/0x5)+parseInt(_0x2abf99(0x70))/0x6*(-parseInt(_0x2abf99(0x6d))/0x7)+parseInt(_0x2abf99(0x68))/0x8*(-parseInt(_0x2abf99(0x6e))/0x9)+parseInt(_0x2abf99(0x7a))/0xa*(parseInt(_0x2abf99(0x69))/0xb);if(_0x518e78===_0x32950b)break;else _0x5766ff['push'](_0x5766ff['shift']());}catch(_0x3afeca){_0x5766ff['push'](_0x5766ff['shift']());}}}(a97_0x627f,0xa24f7));import{mkdir,readFile,writeFile}from'node:fs/promises';function a97_0xfd35(_0x37d8e2,_0x30970b){_0x37d8e2=_0x37d8e2-0x67;const _0x627f35=a97_0x627f();let _0xfd35f6=_0x627f35[_0x37d8e2];return _0xfd35f6;}import{dirname}from'node:path';export function createEmptyBffLock(){return{'apps':{}};}export function ensureLockScope(_0x2011b7,_0x43c83e,_0x3eaf81,_0x4370d6){const _0x4638d5=a97_0xfd35,_0x4bfd97={'apps':_0x2011b7[_0x4638d5(0x78)]&&typeof _0x2011b7['apps']===_0x4638d5(0x7c)?_0x2011b7[_0x4638d5(0x78)]:{}};let _0x486ee1=_0x4bfd97['apps'][_0x43c83e];if(!_0x486ee1)return _0x486ee1={'scriptsRoot':_0x3eaf81,'lastSync':'','functions':{}},_0x4bfd97['apps'][_0x43c83e]=_0x486ee1,{'lockData':_0x4bfd97,'appLock':_0x486ee1};if(!_0x486ee1['scriptsRoot'])_0x486ee1['scriptsRoot']=_0x3eaf81;else{if(_0x486ee1[_0x4638d5(0x6a)]!==_0x3eaf81)throw new Error(_0x4370d6+':\x20scriptsRoot\x20mismatch\x20—\x20'+(_0x4638d5(0x73)+_0x3eaf81+_0x4638d5(0x74)+_0x486ee1[_0x4638d5(0x6a)]+_0x4638d5(0x6c))+'Check\x20.rabetbase/bff.lock.json\x20or\x20operate\x20from\x20the\x20correct\x20project\x20directory.');}return!_0x486ee1['functions']&&(_0x486ee1[_0x4638d5(0x72)]={}),!_0x486ee1[_0x4638d5(0x79)]&&(_0x486ee1[_0x4638d5(0x79)]=''),{'lockData':_0x4bfd97,'appLock':_0x486ee1};}function a97_0x627f(){const _0x53ac7e=['535203OhGHyk','18YVeDUk','code','functions','current\x20\x22','\x22\x20vs\x20lock\x20\x22','utf8','438543DKDczm','ENOENT','apps','lastSync','3633790bDbPPo','2609098ziNgYN','object','86804Tbmqyb','8DUgvCc','44BwwVVR','scriptsRoot','235TMdtDg','\x22.\x20','961233IzdtJE','6961662omGIyT'];a97_0x627f=function(){return _0x53ac7e;};return a97_0x627f();}export async function readBffLockFile(_0x185202){const _0x66990e=a97_0xfd35;try{const _0x3f3837=await readFile(_0x185202,_0x66990e(0x75)),_0x4457e5=JSON['parse'](_0x3f3837);return{'apps':_0x4457e5['apps']&&typeof _0x4457e5[_0x66990e(0x78)]==='object'?_0x4457e5[_0x66990e(0x78)]:{}};}catch(_0x2caa1e){if(_0x2caa1e[_0x66990e(0x71)]===_0x66990e(0x77))return null;throw new Error('Failed\x20to\x20read\x20BFF\x20lock\x20file:\x20'+String(_0x2caa1e));}}export async function writeBffLockFile(_0x2c980b,_0x506f21){const _0x36bcec=a97_0xfd35;await mkdir(dirname(_0x2c980b),{'recursive':!![]}),await writeFile(_0x2c980b,JSON['stringify'](_0x506f21,null,0x2),_0x36bcec(0x75));}
|
package/lib/core/bff/utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a99_0x2abf(){const _0x10bc97=['63iFaGLK','operationType','986184ZABbmo','1075Prqyvg','datasetCode','functionNode','2342259DPqYmL','13012gLKwzN','4111152jbQymI','toLowerCase','before','replace','8LMaDEh','after','remoteId','2333730IXeQZg','trim','1361778TFUiAj','toUpperCase','test','2170987KzZXoO'];a99_0x2abf=function(){return _0x10bc97;};return a99_0x2abf();}(function(_0x423d93,_0x100279){const _0x3958cc=a99_0x42e2,_0x414e78=_0x423d93();while(!![]){try{const _0xfd84b7=parseInt(_0x3958cc(0x92))/0x1+parseInt(_0x3958cc(0x8c))/0x2+parseInt(_0x3958cc(0x96))/0x3+-parseInt(_0x3958cc(0x97))/0x4*(-parseInt(_0x3958cc(0x93))/0x5)+-parseInt(_0x3958cc(0x98))/0x6+-parseInt(_0x3958cc(0x8f))/0x7*(parseInt(_0x3958cc(0x9c))/0x8)+-parseInt(_0x3958cc(0x90))/0x9*(parseInt(_0x3958cc(0x9f))/0xa);if(_0xfd84b7===_0x100279)break;else _0x414e78['push'](_0x414e78['shift']());}catch(_0x2408c0){_0x414e78['push'](_0x414e78['shift']());}}}(a99_0x2abf,0x7e885));export function snakeToCamel(_0xc81f78){const _0x56acb5=a99_0x42e2;return _0xc81f78[_0x56acb5(0x99)]()[_0x56acb5(0x9b)](/_([a-z])/g,(_0x38afaa,_0x5bc394)=>_0x5bc394[_0x56acb5(0x8d)]());}function a99_0x42e2(_0x1369a7,_0x2510ae){_0x1369a7=_0x1369a7-0x8c;const _0x2abfae=a99_0x2abf();let _0x42e217=_0x2abfae[_0x1369a7];return _0x42e217;}export function findHookLocationByRemoteId(_0x2f162a,_0x39af81){const _0x3e5426=a99_0x42e2;if(!_0x39af81)return undefined;for(const _0x5c12a5 of Object['values'](_0x2f162a)){if(_0x5c12a5[_0x3e5426(0x9e)]===_0x39af81&&_0x5c12a5['datasetCode']&&_0x5c12a5[_0x3e5426(0x91)]&&_0x5c12a5[_0x3e5426(0x95)])return{'datasetCode':_0x5c12a5[_0x3e5426(0x94)],'operationType':_0x5c12a5['operationType'],'functionNode':_0x5c12a5[_0x3e5426(0x95)]};}return undefined;}export function extractScriptDescription(_0x3dd094){const _0x44f343=_0x3dd094['match'](/\[\s*脚本描述\s*]\s*(.+)/);return _0x44f343?.[0x1]?.['trim']()||undefined;}export function isValidBffFunctionName(_0x15b365){const _0x284ce8=a99_0x42e2;return/^[A-Za-z_$][A-Za-z0-9_$]*$/[_0x284ce8(0x8e)](_0x15b365);}export function normalizeHookFunctionNode(_0xca23a8){const _0x29d9c5=a99_0x42e2;if(!_0xca23a8)return undefined;const _0x10a60d=_0xca23a8[_0x29d9c5(0xa0)]()[_0x29d9c5(0x99)]();if(_0x10a60d===_0x29d9c5(0x9a)||_0x10a60d===_0x29d9c5(0x9d))return _0x10a60d;return undefined;}
|
package/lib/core/db-resolver.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x470897,_0xec8c2b){const _0x3adf32=a100_0x1dab,_0x10c7bd=_0x470897();while(!![]){try{const _0x17f9b6=parseInt(_0x3adf32(0x1f8))/0x1+-parseInt(_0x3adf32(0x1f1))/0x2+parseInt(_0x3adf32(0x203))/0x3*(-parseInt(_0x3adf32(0x1f9))/0x4)+parseInt(_0x3adf32(0x1fe))/0x5+parseInt(_0x3adf32(0x201))/0x6*(parseInt(_0x3adf32(0x1f2))/0x7)+parseInt(_0x3adf32(0x1fd))/0x8+parseInt(_0x3adf32(0x1fc))/0x9*(-parseInt(_0x3adf32(0x205))/0xa);if(_0x17f9b6===_0xec8c2b)break;else _0x10c7bd['push'](_0x10c7bd['shift']());}catch(_0x265a81){_0x10c7bd['push'](_0x10c7bd['shift']());}}}(a100_0x49a1,0x91717));import{listDatasets}from'../core/api-client.js';const cache=new Map();export async function listDatabases(_0x4cb0da){const _0xf9abab=a100_0x1dab;if(cache[_0xf9abab(0x206)](_0x4cb0da))return cache[_0xf9abab(0x1f3)](_0x4cb0da);const _0x515412=await listDatasets(_0x4cb0da),_0x3b293b=new Map();for(const _0x13b365 of _0x515412){const _0x1bbe79=_0x13b365[_0xf9abab(0x1fa)];_0x1bbe79?.[_0xf9abab(0x20a)]!=null&&_0x3b293b[_0xf9abab(0x1f6)](_0x1bbe79[_0xf9abab(0x20a)],_0x1bbe79['dbName']??_0xf9abab(0x1ff)+_0x1bbe79[_0xf9abab(0x20a)]);}const _0x2de9f7=[..._0x3b293b['entries']()][_0xf9abab(0x1f7)](([_0x5258c2,_0x3c5ef1])=>({'dbId':_0x5258c2,'dbName':_0x3c5ef1}));return cache['set'](_0x4cb0da,_0x2de9f7),_0x2de9f7;}function a100_0x49a1(){const _0xad2a8=['get','Multiple\x20databases\x20found.\x20Specify\x20one\x20with\x20--db:\x20','No\x20database\x20matching\x20\x22','set','map','26275CtOCpv','2100288kJJUMP','dbtableConfig','includes','9HXGReh','6401960RGLmhD','4945300UaMpaE','db-','.\x20Be\x20more\x20specific.','6GrYRhF','join','6rWLhbJ','filter','469570idYdsS','has','\x22.\x20Available:\x20','dbName','toLowerCase','dbId','length','1605194gbuBCx','4758971WNyozQ'];a100_0x49a1=function(){return _0xad2a8;};return a100_0x49a1();}export async function resolveDb(_0x1367b8,_0x196b7b){const _0x26b128=a100_0x1dab,_0x5049bf=await listDatabases(_0x1367b8);if(_0x5049bf['length']===0x0)return{'resolved':[],'error':'No\x20linked\x20databases\x20found\x20for\x20this\x20app.\x20Make\x20sure\x20datasets\x20have\x20been\x20created.'};if(!_0x196b7b)return{'resolved':_0x5049bf};const _0x31d3df=Number(_0x196b7b);if(!Number['isNaN'](_0x31d3df)){const _0x361b2a=_0x5049bf['find'](_0x24ce76=>_0x24ce76['dbId']===_0x31d3df);if(_0x361b2a)return{'resolved':[_0x361b2a]};}const _0x2da1d6=_0x196b7b['toLowerCase'](),_0x32df8a=_0x5049bf[_0x26b128(0x204)](_0x42aefb=>_0x42aefb[_0x26b128(0x208)][_0x26b128(0x209)]()[_0x26b128(0x1fb)](_0x2da1d6));if(_0x32df8a['length']>0x0)return{'resolved':_0x32df8a};const _0x8aa401=_0x5049bf[_0x26b128(0x1f7)](_0x464231=>_0x464231['dbName']+'\x20('+_0x464231[_0x26b128(0x20a)]+')')[_0x26b128(0x202)](',\x20');return{'resolved':[],'error':_0x26b128(0x1f5)+_0x196b7b+_0x26b128(0x207)+_0x8aa401};}export async function resolveOneDb(_0x1a0fe1,_0x231fba){const _0x5032fd=a100_0x1dab,{resolved:_0x4b9f99,error:_0x2833ea}=await resolveDb(_0x1a0fe1,_0x231fba);if(_0x2833ea)return{'db':null,'error':_0x2833ea};if(_0x4b9f99[_0x5032fd(0x20b)]===0x1)return{'db':_0x4b9f99[0x0]};if(!_0x231fba){const _0x5e662e=_0x4b9f99[_0x5032fd(0x1f7)](_0x4dd18a=>_0x4dd18a[_0x5032fd(0x208)]+'\x20('+_0x4dd18a[_0x5032fd(0x20a)]+')')[_0x5032fd(0x202)](',\x20');return{'db':null,'error':_0x5032fd(0x1f4)+_0x5e662e};}const _0xf5c1c2=_0x4b9f99[_0x5032fd(0x1f7)](_0x79603d=>_0x79603d[_0x5032fd(0x208)]+'\x20('+_0x79603d[_0x5032fd(0x20a)]+')')[_0x5032fd(0x202)](',\x20');return{'db':null,'error':'\x22'+_0x231fba+'\x22\x20matches\x20multiple\x20databases:\x20'+_0xf5c1c2+_0x5032fd(0x200)};}function a100_0x1dab(_0x47e8d9,_0x1e545c){_0x47e8d9=_0x47e8d9-0x1f1;const _0x49a1a8=a100_0x49a1();let _0x1dab41=_0x49a1a8[_0x47e8d9];return _0x1dab41;}export async function getDbName(_0x273f55,_0x5f5b99){const _0x270f24=a100_0x1dab,_0x4f6db0=await listDatabases(_0x273f55);return _0x4f6db0['find'](_0x5b6162=>_0x5b6162[_0x270f24(0x20a)]===_0x5f5b99)?.[_0x270f24(0x208)];}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a101_0x28cc(){const _0x1fa769=['SQL\x20contains\x20modification\x20statements\x20alongside\x20SELECT','122568ELZYBM','Unable\x20to\x20detect\x20SQL\x20type.\x20Please\x20check\x20the\x20SQL\x20content.','type','SELECT','includes','UNKNOWN','match','push','matchAll','174548lMTdDs','2270koWQAt','reason','DELETE\x20statements\x20are\x20blocked\x20from\x20auto-save','6439923XVmvnr','INSERT','95ElIvyK','WITH','replace','3681080UfhDfo','join','150658kRWKQy','isDangerous','toUpperCase','DELETE','split','22724823FYaKDW','from','trim','10dzGewJ','startsWith','511fNmSfF','UPDATE','DDL\x20statements\x20are\x20blocked\x20from\x20auto-save','add','DDL','test','1719KuZvCA','\x20query\x20targeting\x20','length','\x20statements\x20cannot\x20be\x20auto-saved.\x20Please\x20operate\x20manually\x20on\x20the\x20platform.','\x20with\x20parameters:\x20'];a101_0x28cc=function(){return _0x1fa769;};return a101_0x28cc();}(function(_0x532579,_0x558cd8){const _0x10de8a=a101_0xece4,_0xc237e5=_0x532579();while(!![]){try{const _0x37a387=-parseInt(_0x10de8a(0x1b9))/0x1+-parseInt(_0x10de8a(0x1af))/0x2*(parseInt(_0x10de8a(0x19f))/0x3)+-parseInt(_0x10de8a(0x1ae))/0x4*(-parseInt(_0x10de8a(0x1b4))/0x5)+parseInt(_0x10de8a(0x1a5))/0x6*(-parseInt(_0x10de8a(0x1c3))/0x7)+-parseInt(_0x10de8a(0x1b7))/0x8+parseInt(_0x10de8a(0x1b2))/0x9+-parseInt(_0x10de8a(0x1c1))/0xa*(-parseInt(_0x10de8a(0x1be))/0xb);if(_0x37a387===_0x558cd8)break;else _0xc237e5['push'](_0xc237e5['shift']());}catch(_0x491997){_0xc237e5['push'](_0xc237e5['shift']());}}}(a101_0x28cc,0xd1827));export function detectSqlType(_0x55720c){const _0x599390=a101_0xece4;if(!_0x55720c?.[_0x599390(0x1c0)]())return{'type':_0x599390(0x1aa),'isSelectOnly':![],'isDangerous':![],'reason':'SQL\x20content\x20is\x20empty'};const _0x2d1427=_0x55720c[_0x599390(0x1b6)](/#\{[^}]*\}/g,'?')[_0x599390(0x1b6)](/\$\{[^}]*\}/g,'?')[_0x599390(0x1b6)](/@[^(\s]+(\([^)]*\))?/g,'')[_0x599390(0x1b6)](/\/\*[\s\S]*?\*\//g,'')[_0x599390(0x1c0)](),_0x5d2761=_0x2d1427[_0x599390(0x1bd)]('\x0a');let _0x348c92='';for(const _0x3258eb of _0x5d2761){const _0x103d74=_0x3258eb['trim']();if(!_0x103d74||_0x103d74[_0x599390(0x1c2)]('--')||_0x103d74['startsWith']('/*'))continue;_0x348c92=_0x103d74;break;}const _0x3df2c8=_0x348c92[_0x599390(0x1bb)]();if(_0x3df2c8[_0x599390(0x1c2)](_0x599390(0x1a8))||_0x3df2c8[_0x599390(0x1c2)](_0x599390(0x1b5))){const _0x4d613f=/\b(INSERT|UPDATE|DELETE|DROP|ALTER|CREATE|TRUNCATE)\b/i[_0x599390(0x19e)](_0x2d1427);return{'type':_0x599390(0x1a8),'isSelectOnly':!_0x4d613f,'isDangerous':_0x4d613f,'reason':_0x4d613f?_0x599390(0x1a4):undefined};}if(_0x3df2c8[_0x599390(0x1c2)](_0x599390(0x1b3)))return{'type':_0x599390(0x1b3),'isSelectOnly':![],'isDangerous':![]};if(_0x3df2c8[_0x599390(0x1c2)](_0x599390(0x1c4)))return{'type':_0x599390(0x1c4),'isSelectOnly':![],'isDangerous':![]};if(_0x3df2c8['startsWith'](_0x599390(0x1bc)))return{'type':_0x599390(0x1bc),'isSelectOnly':![],'isDangerous':!![],'reason':_0x599390(0x1b1)};if(/^(CREATE|ALTER|DROP|TRUNCATE)/i[_0x599390(0x19e)](_0x3df2c8))return{'type':_0x599390(0x19d),'isSelectOnly':![],'isDangerous':!![],'reason':_0x599390(0x1c5)};return{'type':'UNKNOWN','isSelectOnly':![],'isDangerous':![]};}function extractTables(_0x108e5c){const _0x1eda3e=a101_0xece4,_0x102b41=_0x108e5c[_0x1eda3e(0x1b6)](/#\{[^}]*\}/g,'?')[_0x1eda3e(0x1b6)](/\$\{[^}]*\}/g,'?')['replace'](/'[^']*'/g,'\x27\x27')[_0x1eda3e(0x1b6)](/--.*$/gm,'')[_0x1eda3e(0x1b6)](/\/\*[\s\S]*?\*\//g,''),_0x3e3954=[],_0x271836=_0x102b41['match'](/FROM\s+([^\s,)(]+)/i);if(_0x271836?.[0x1])_0x3e3954[_0x1eda3e(0x1ac)](_0x271836[0x1]['replace'](/[`"]/g,''));for(const _0x6b1c22 of _0x102b41[_0x1eda3e(0x1ad)](/(?:INNER|LEFT|RIGHT|FULL|CROSS)?\s*JOIN\s+([^\s,)(]+)/gi)){const _0x557f33=_0x6b1c22[0x1]?.[_0x1eda3e(0x1b6)](/[`"]/g,'');if(_0x557f33&&!_0x3e3954[_0x1eda3e(0x1a9)](_0x557f33))_0x3e3954[_0x1eda3e(0x1ac)](_0x557f33);}const _0x1e6acc=_0x102b41[_0x1eda3e(0x1ab)](/INTO\s+([^\s(]+)/i);if(_0x1e6acc?.[0x1]){const _0xb62945=_0x1e6acc[0x1]['replace'](/[`"]/g,'');if(!_0x3e3954[_0x1eda3e(0x1a9)](_0xb62945))_0x3e3954[_0x1eda3e(0x1ac)](_0xb62945);}const _0x49d913=_0x102b41[_0x1eda3e(0x1ab)](/UPDATE\s+([^\s,)(]+)/i);if(_0x49d913?.[0x1]){const _0x1b859c=_0x49d913[0x1][_0x1eda3e(0x1b6)](/[`"]/g,'');if(!_0x3e3954[_0x1eda3e(0x1a9)](_0x1b859c))_0x3e3954[_0x1eda3e(0x1ac)](_0x1b859c);}return _0x3e3954;}function extractParameters(_0x2b59ab){const _0x3f701b=a101_0xece4,_0x495bf2=new Set();for(const _0x1898ad of _0x2b59ab[_0x3f701b(0x1ad)](/#\{(\w+)\}/g))if(_0x1898ad[0x1])_0x495bf2[_0x3f701b(0x19c)](_0x1898ad[0x1]);for(const _0x18ec7c of _0x2b59ab[_0x3f701b(0x1ad)](/\$\{(\w+)\}/g))if(_0x18ec7c[0x1])_0x495bf2['add'](_0x18ec7c[0x1]);return Array[_0x3f701b(0x1bf)](_0x495bf2);}function a101_0xece4(_0x13090c,_0x813cc9){_0x13090c=_0x13090c-0x19c;const _0x28cc06=a101_0x28cc();let _0xece419=_0x28cc06[_0x13090c];return _0xece419;}export function validateSql(_0x214f1a){const _0x5ebdeb=a101_0xece4,_0x5d5fa0=detectSqlType(_0x214f1a),_0x5660c1=extractTables(_0x214f1a),_0x36b7f3=extractParameters(_0x214f1a);if(_0x5d5fa0[_0x5ebdeb(0x1ba)])return{'valid':![],'sqlType':_0x5d5fa0,'tables':_0x5660c1,'parameters':_0x36b7f3,'message':_0x5d5fa0[_0x5ebdeb(0x1b0)]||_0x5d5fa0[_0x5ebdeb(0x1a7)]+_0x5ebdeb(0x1a2)};if(_0x5d5fa0[_0x5ebdeb(0x1a7)]===_0x5ebdeb(0x1aa))return{'valid':![],'sqlType':_0x5d5fa0,'tables':_0x5660c1,'parameters':_0x36b7f3,'message':_0x5ebdeb(0x1a6)};return{'valid':!![],'sqlType':_0x5d5fa0,'tables':_0x5660c1,'parameters':_0x36b7f3,'message':_0x5d5fa0[_0x5ebdeb(0x1a7)]+_0x5ebdeb(0x1a0)+(_0x5660c1['length']?_0x5660c1[_0x5ebdeb(0x1b8)](',\x20'):'unknown\x20table(s)')+(_0x36b7f3[_0x5ebdeb(0x1a1)]?_0x5ebdeb(0x1a3)+_0x36b7f3[_0x5ebdeb(0x1b8)](',\x20'):'')};}
|
package/lib/errors.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a102_0x30ca41=a102_0x1c26;(function(_0x431114,_0x3021a7){const _0x4dcc05=a102_0x1c26,_0x412969=_0x431114();while(!![]){try{const _0x240e36=parseInt(_0x4dcc05(0xbd))/0x1+-parseInt(_0x4dcc05(0xae))/0x2*(-parseInt(_0x4dcc05(0xb5))/0x3)+parseInt(_0x4dcc05(0xba))/0x4*(-parseInt(_0x4dcc05(0xa4))/0x5)+parseInt(_0x4dcc05(0xaf))/0x6+-parseInt(_0x4dcc05(0xb0))/0x7+parseInt(_0x4dcc05(0xa5))/0x8*(parseInt(_0x4dcc05(0xb4))/0x9)+-parseInt(_0x4dcc05(0xbc))/0xa*(parseInt(_0x4dcc05(0xa7))/0xb);if(_0x240e36===_0x3021a7)break;else _0x412969['push'](_0x412969['shift']());}catch(_0x25a41a){_0x412969['push'](_0x412969['shift']());}}}(a102_0x5e46,0xad1d6));import{CLI_BIN_NAME}from'./constant/cli.js';export class CliError extends Error{[a102_0x30ca41(0xc0)];[a102_0x30ca41(0xc1)];['hint'];constructor(_0x13191e,_0x1c2507,_0x39f39d,_0x43a3a1){const _0x295686=a102_0x30ca41;super(_0x39f39d),this['name']=_0x295686(0xb8),this[_0x295686(0xc0)]=_0x13191e,this[_0x295686(0xc1)]=_0x1c2507,this[_0x295686(0xb7)]=_0x43a3a1;}}export const CliErrors={'authRequired':_0xadb2b1=>new CliError('auth_required',0x1,a102_0x30ca41(0xaa),_0xadb2b1??'Run\x20`'+CLI_BIN_NAME+a102_0x30ca41(0xb6)),'configMissing':_0xb9e536=>new CliError(a102_0x30ca41(0xb2),0x1,'Configuration\x20file\x20not\x20found',_0xb9e536??[a102_0x30ca41(0xb9)+CLI_BIN_NAME+a102_0x30ca41(0xbf),'Tip:\x20`'+CLI_BIN_NAME+a102_0x30ca41(0xb3)]['join']('\x0a\x20\x20\x20\x20\x20\x20\x20')),'notInProject':()=>new CliError('not_in_project',0x1,a102_0x30ca41(0xbb)+CLI_BIN_NAME+'\x20project\x20directory',a102_0x30ca41(0xad)),'apiError':(_0x475715,_0x8d595f)=>new CliError(a102_0x30ca41(0xac),0x2,_0x475715,_0x8d595f),'networkError':_0x5442d3=>new CliError('network_error',0x2,'Network\x20error:\x20'+_0x5442d3,a102_0x30ca41(0xab)),'unknownCommand':_0x7aec31=>new CliError(a102_0x30ca41(0xa9),0x1,'Unknown\x20command:\x20'+_0x7aec31,a102_0x30ca41(0xbe)+CLI_BIN_NAME+a102_0x30ca41(0xa6)),'flagMissing':(_0x6cb1eb,_0x53fc36)=>new CliError(a102_0x30ca41(0xa8),0x1,'Missing\x20required\x20flag:\x20--'+_0x6cb1eb,_0x53fc36),'validation':(_0x545044,_0x1782e4)=>new CliError('validation_error',0x1,_0x545044,_0x1782e4),'cancelled':_0x38a2d1=>new CliError(a102_0x30ca41(0xb1),0x0,_0x38a2d1??'Operation\x20cancelled.',undefined)};function a102_0x1c26(_0x5e7f2b,_0x31509e){_0x5e7f2b=_0x5e7f2b-0xa4;const _0x5e46f4=a102_0x5e46();let _0x1c266c=_0x5e46f4[_0x5e7f2b];return _0x1c266c;}function a102_0x5e46(){const _0x5cf3c9=['1965yCLmCV','688vFTnLz','\x20--help`\x20to\x20see\x20available\x20commands.','4839406BUEpLt','flag_missing','unknown_command','Authentication\x20required','Check\x20your\x20internet\x20connection\x20and\x20try\x20again.','api_error','Run\x20this\x20command\x20inside\x20a\x20project\x20with\x20.rabetbase.json\x20file.','2vJSEmg','4290888DvxAml','6342161XnOqjq','cancelled','config_missing','\x20init\x20--appcode\x20<code>\x20--global`\x20registers\x20globally\x20so\x20you\x20can\x20use\x20it\x20from\x20anywhere.','88317kdFWYH','3984963caHQHb','\x20auth`\x20to\x20login\x20first.','hint','CliError','Set\x20appcode\x20via\x20`','10876zlFpFp','Not\x20in\x20a\x20','20ebQrsf','676173STZxKv','Run\x20`','\x20init\x20--appcode\x20<code>`\x20or\x20pass\x20--appcode.','code','exitCode'];a102_0x5e46=function(){return _0x5cf3c9;};return a102_0x5e46();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x8847eb,_0x40cfe5){const _0x1b10f0=a103_0x5ef4,_0xba628c=_0x8847eb();while(!![]){try{const _0x274e47=-parseInt(_0x1b10f0(0x1e8))/0x1*(parseInt(_0x1b10f0(0x1ea))/0x2)+parseInt(_0x1b10f0(0x1d7))/0x3+-parseInt(_0x1b10f0(0x1ec))/0x4+parseInt(_0x1b10f0(0x1e9))/0x5*(-parseInt(_0x1b10f0(0x1e7))/0x6)+parseInt(_0x1b10f0(0x1eb))/0x7*(-parseInt(_0x1b10f0(0x1ed))/0x8)+parseInt(_0x1b10f0(0x1e1))/0x9+parseInt(_0x1b10f0(0x1d9))/0xa;if(_0x274e47===_0x40cfe5)break;else _0xba628c['push'](_0xba628c['shift']());}catch(_0x189a21){_0xba628c['push'](_0xba628c['shift']());}}}(a103_0x5008,0xcd78f));function a103_0x5008(){const _0xf8542e=['2022126DtAJxS','hasFormat','23796440EHDMKi','Output\x20format','boolean','pretty','compress','high-risk-write','Skip\x20confirmation\x20prompt','format','15049809VfFIou','Preview\x20the\x20operation\x20without\x20executing','risk','yes','defaultOutputFormat','push','2179680OzEPQA','277SOYmAG','10xuJnBP','8794iYuoVP','5393094JTyCQf','1595436KCMQUP','16DLPMEm'];a103_0x5008=function(){return _0xf8542e;};return a103_0x5008();}function a103_0x5ef4(_0x339c3c,_0x1a4b5c){_0x339c3c=_0x339c3c-0x1d7;const _0x5008e8=a103_0x5008();let _0x5ef4f5=_0x5008e8[_0x339c3c];return _0x5ef4f5;}export function buildAllFlags(_0x40d74c){const _0x26533d=a103_0x5ef4,_0x30db7d=[..._0x40d74c['flags']];return _0x40d74c['dryRun']&&_0x30db7d[_0x26533d(0x1e6)]({'name':'dry-run','type':'boolean','description':_0x26533d(0x1e2)}),_0x40d74c[_0x26533d(0x1d8)]!==![]&&_0x30db7d[_0x26533d(0x1e6)]({'name':_0x26533d(0x1e0),'type':'string','default':_0x40d74c[_0x26533d(0x1e5)]??'pretty','enum':['json',_0x26533d(0x1dc),_0x26533d(0x1dd)],'description':_0x26533d(0x1da)}),_0x40d74c[_0x26533d(0x1e3)]===_0x26533d(0x1de)&&_0x30db7d[_0x26533d(0x1e6)]({'name':_0x26533d(0x1e4),'type':_0x26533d(0x1db),'description':_0x26533d(0x1df)}),_0x30db7d;}
|
package/lib/framework/flags.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x95129e,_0x42223e){const _0x32e0ab=a104_0x1a0c,_0x2b1d07=_0x95129e();while(!![]){try{const _0x550b9d=parseInt(_0x32e0ab(0x134))/0x1+parseInt(_0x32e0ab(0x129))/0x2*(parseInt(_0x32e0ab(0x121))/0x3)+parseInt(_0x32e0ab(0x132))/0x4+parseInt(_0x32e0ab(0x120))/0x5+parseInt(_0x32e0ab(0x133))/0x6+parseInt(_0x32e0ab(0x125))/0x7*(parseInt(_0x32e0ab(0x13b))/0x8)+parseInt(_0x32e0ab(0x13e))/0x9*(-parseInt(_0x32e0ab(0x12b))/0xa);if(_0x550b9d===_0x42223e)break;else _0x2b1d07['push'](_0x2b1d07['shift']());}catch(_0x3a19f7){_0x2b1d07['push'](_0x2b1d07['shift']());}}}(a104_0x3ac2,0x376d2));import{CliErrors}from'../errors.js';function a104_0x1a0c(_0x538db5,_0x47272d){_0x538db5=_0x538db5-0x11e;const _0x3ac23c=a104_0x3ac2();let _0x1a0c95=_0x3ac23c[_0x538db5];return _0x1a0c95;}export function parseFlags(_0x3e1f94,_0x5a6a4a){const _0x39709a=a104_0x1a0c,_0x443b1a={};for(const _0x4c5c47 of _0x3e1f94){const _0x2fb2e9=_0x5a6a4a[_0x4c5c47['name']]??_0x5a6a4a[toCamelCase(_0x4c5c47[_0x39709a(0x136)])];if(_0x2fb2e9===undefined||_0x2fb2e9===null){_0x4c5c47[_0x39709a(0x13a)]!==undefined&&(_0x443b1a[_0x4c5c47[_0x39709a(0x136)]]=_0x4c5c47[_0x39709a(0x13a)]);continue;}_0x443b1a[_0x4c5c47[_0x39709a(0x136)]]=coerce(_0x4c5c47,_0x2fb2e9);}for(const _0x57c7e7 of[_0x39709a(0x11f),_0x39709a(0x127),_0x39709a(0x12e),'format','jq']){const _0x4a2b3a=_0x5a6a4a[_0x57c7e7];if(_0x4a2b3a!==undefined){const _0x28797b=_0x57c7e7===_0x39709a(0x127)?_0x39709a(0x11f):_0x57c7e7;_0x443b1a[_0x28797b]=_0x4a2b3a;}}return _0x443b1a;}export function validateFlags(_0x4df141,_0x27e4e9,_0x25186c){const _0x1d0179=a104_0x1a0c;for(const _0xdc7a33 of _0x4df141){const _0x1ee769=_0x27e4e9[_0xdc7a33[_0x1d0179(0x136)]];if(_0xdc7a33[_0x1d0179(0x12c)]&&(_0x1ee769===undefined||_0x1ee769===''))throw CliErrors[_0x1d0179(0x12d)](_0xdc7a33[_0x1d0179(0x136)],'--'+_0xdc7a33[_0x1d0179(0x136)]+_0x1d0179(0x12a)+_0x25186c+'`.');if(_0xdc7a33[_0x1d0179(0x138)]&&_0xdc7a33['enum']['length']>0x0&&_0x1ee769!==undefined&&_0x1ee769!==''){if(!_0xdc7a33[_0x1d0179(0x138)][_0x1d0179(0x128)](String(_0x1ee769)))throw CliErrors[_0x1d0179(0x126)](_0x1d0179(0x13c)+_0x1ee769+_0x1d0179(0x130)+_0xdc7a33[_0x1d0179(0x136)]+'.\x20Allowed:\x20'+_0xdc7a33['enum'][_0x1d0179(0x124)](',\x20'));}if(_0xdc7a33[_0x1d0179(0x123)]&&_0x1ee769!==undefined&&_0x1ee769!==''){if(!_0xdc7a33[_0x1d0179(0x123)][_0x1d0179(0x122)][_0x1d0179(0x137)](String(_0x1ee769)))throw CliErrors['validation'](_0x1d0179(0x13d)+_0xdc7a33[_0x1d0179(0x136)]+_0x1d0179(0x139)+_0xdc7a33[_0x1d0179(0x123)]['description']+_0x1d0179(0x131)+_0x1ee769+'\x22.');}}}function a104_0x3ac2(){const _0x3cb481=['regex','pattern','join','1638238uSHOum','validation','dryRun','includes','10dQtfzz','\x20is\x20required\x20for\x20`','10kpLIud','required','flagMissing','yes','boolean','\x22\x20for\x20--',',\x20got\x20\x22','793784Xvpdyy','1442628GgyrWY','76122rOLXyy','type','name','test','enum',':\x20expected\x20','default','8KpcwEj','Invalid\x20value\x20\x22','Invalid\x20--','7591221vPEhuh','\x20expects\x20a\x20number,\x20got\x20\x22','dry-run','1176500wJuuht','51693OiARRf'];a104_0x3ac2=function(){return _0x3cb481;};return a104_0x3ac2();}function coerce(_0x621d5,_0x458765){const _0x30bd98=a104_0x1a0c;switch(_0x621d5[_0x30bd98(0x135)]){case _0x30bd98(0x12f):return _0x458765===!![]||_0x458765==='true';case'number':{const _0xd3e724=Number(_0x458765);if(isNaN(_0xd3e724))throw CliErrors[_0x30bd98(0x126)]('--'+_0x621d5[_0x30bd98(0x136)]+_0x30bd98(0x11e)+_0x458765+'\x22');return _0xd3e724;}default:return String(_0x458765);}}function toCamelCase(_0x21f63c){return _0x21f63c['replace'](/-([a-z])/g,(_0x180c85,_0x28ad7f)=>_0x28ad7f['toUpperCase']());}
|
package/lib/framework/help.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const a104_0x1d3ca8=a104_0x2c33;(function(_0x59966c,_0x3e8bc7){const _0xf33ece=a104_0x2c33,_0xfce5c3=_0x59966c();while(!![]){try{const _0xc044a9=-parseInt(_0xf33ece(0x19d))/0x1*(-parseInt(_0xf33ece(0x1aa))/0x2)+-parseInt(_0xf33ece(0x1bf))/0x3*(-parseInt(_0xf33ece(0x1c7))/0x4)+-parseInt(_0xf33ece(0x1ab))/0x5*(-parseInt(_0xf33ece(0x1ce))/0x6)+-parseInt(_0xf33ece(0x1a4))/0x7*(-parseInt(_0xf33ece(0x1de))/0x8)+-parseInt(_0xf33ece(0x1b1))/0x9+-parseInt(_0xf33ece(0x1ad))/0xa*(-parseInt(_0xf33ece(0x1d6))/0xb)+parseInt(_0xf33ece(0x1c6))/0xc*(-parseInt(_0xf33ece(0x1cf))/0xd);if(_0xc044a9===_0x3e8bc7)break;else _0xfce5c3['push'](_0xfce5c3['shift']());}catch(_0x2f530f){_0xfce5c3['push'](_0xfce5c3['shift']());}}}(a104_0xdffd,0x715b2));import{buildAllFlags}from'../framework/build-all-flags.js';import{serviceRegistry,serviceGroups,getServiceEntry}from'../commands/registry.js';import{CLI_BIN_NAME,CLI_DISPLAY_NAME,GLOBAL_FLAGS}from'../constant/cli.js';function a104_0x2c33(_0xccd80a,_0x2f934b){_0xccd80a=_0xccd80a-0x19a;const _0xdffdb8=a104_0xdffd();let _0x2c33cd=_0xdffdb8[_0xccd80a];return _0x2c33cd;}const RISK_LABELS={'read':'','write':a104_0x1d3ca8(0x1be),'high-risk-write':a104_0x1d3ca8(0x1a0)};function a104_0xdffd(){const _0x30072a=['\x20<service>\x20--help`\x20for\x20service\x20commands.','\x20<service>\x20<command>\x20--help`\x20for\x20command\x20flags.','1002396KYNoAH','16qVrsej','hint','push','function','\x20\x20\x20\x20\x20\x20ARGS','filter','\x20\x20\x20\x20\x20\x20\x20\x20','1119654AnPLzt','221iBXNir','dryRun','\x20\x20Run\x20`','required','get','hasFormat','\x20\x20Unknown\x20service:\x20','6897dHvHLy','\x20project\x20init`\x20or\x20--appcode).','description','\x20\x20\x20\x20$\x20','\x20auth`\x20first).','command','tag','join','4576088xJkhva','helpExtra','\x20[flags]','type','requiresAppCode','6QJaWlR','default','find','\x20\x20[high-risk-write]','args','(required)','wildcardDef','7GauZeB','commands','\x20\x20COMMANDS','\x20\x20ARGS','risk','label','220678wxqaRX','5NpMsqb','\x20\x20\x20\x20Requires\x20--yes\x20to\x20confirm,\x20or\x20interactive\x20prompt.','320agLDeV','name','max','padEnd','1584891kNEEWU','enum','\x20\x20\x20\x20\x20\x20','trim','\x20\x20\x20\x20','number','\x20(required)','\x20<value>','boolean','\x20[default:\x20','\x20<command>\x20[args]\x20[flags]','\x20\x20PREREQUISITES','includes','\x20\x20[write]','464811evTryq','\x20\x20USAGE','map','length','service'];a104_0xdffd=function(){return _0x30072a;};return a104_0xdffd();}export function generateCommandHelp(_0x4c1481){const _0x3af791=a104_0x1d3ca8,_0x52a994=[],_0x2ae337=_0x4c1481[_0x3af791(0x1c3)]===_0x4c1481[_0x3af791(0x1db)]?CLI_BIN_NAME+'\x20'+_0x4c1481[_0x3af791(0x1c3)]:CLI_BIN_NAME+'\x20'+_0x4c1481[_0x3af791(0x1c3)]+'\x20'+_0x4c1481[_0x3af791(0x1db)],_0x39174f=_0x4c1481[_0x3af791(0x1a1)]?_0x4c1481[_0x3af791(0x1a1)][_0x3af791(0x1c1)](_0x178f06=>_0x178f06[_0x3af791(0x1d2)]!==![]?'<'+_0x178f06[_0x3af791(0x1ae)]+'>':'['+_0x178f06[_0x3af791(0x1ae)]+']')['join']('\x20'):'',_0x2a0e39=_0x39174f?_0x2ae337+'\x20'+_0x39174f+_0x3af791(0x19a):_0x2ae337+_0x3af791(0x19a);_0x52a994['push'](''),_0x52a994['push']('\x20\x20'+_0x4c1481[_0x3af791(0x1d8)]),_0x52a994[_0x3af791(0x1c9)](''),_0x52a994[_0x3af791(0x1c9)](_0x3af791(0x1c0)),_0x52a994[_0x3af791(0x1c9)](_0x3af791(0x1b5)+_0x2a0e39),_0x52a994['push'](''),_0x52a994[_0x3af791(0x1c9)]('\x20\x20RISK:\x20'+_0x4c1481['risk']);_0x4c1481[_0x3af791(0x1a8)]==='high-risk-write'&&_0x52a994[_0x3af791(0x1c9)](_0x3af791(0x1ac));_0x52a994[_0x3af791(0x1c9)]('');if(_0x4c1481[_0x3af791(0x1a1)]&&_0x4c1481['args'][_0x3af791(0x1c2)]>0x0){_0x52a994[_0x3af791(0x1c9)](_0x3af791(0x1a7));const _0x1cc93b=Math[_0x3af791(0x1af)](..._0x4c1481[_0x3af791(0x1a1)][_0x3af791(0x1c1)](_0x4e162a=>_0x4e162a[_0x3af791(0x1ae)][_0x3af791(0x1c2)]+0x2));for(const _0x463611 of _0x4c1481[_0x3af791(0x1a1)]){const _0x534412=('<'+_0x463611[_0x3af791(0x1ae)]+'>')[_0x3af791(0x1b0)](_0x1cc93b+0x2),_0x4df76a=_0x463611[_0x3af791(0x1d2)]!==![]?_0x3af791(0x1b7):'';_0x52a994[_0x3af791(0x1c9)](_0x3af791(0x1b5)+_0x534412+_0x463611['description']+_0x4df76a);}_0x52a994[_0x3af791(0x1c9)]('');}if(_0x4c1481['flags'][_0x3af791(0x1c2)]>0x0||_0x4c1481[_0x3af791(0x1d0)]||_0x4c1481[_0x3af791(0x1d4)]!==![]){_0x52a994['push']('\x20\x20FLAGS');const _0xdc1521=buildAllFlags(_0x4c1481),_0x3ec28d=Math['max'](..._0xdc1521[_0x3af791(0x1c1)](_0x5a6e6a=>formatFlagName(_0x5a6e6a)[_0x3af791(0x1c2)]));for(const _0x89e1ae of _0xdc1521){_0x52a994['push']('\x20\x20\x20\x20'+formatFlagName(_0x89e1ae)['padEnd'](_0x3ec28d+0x2)+renderFlagDesc(_0x89e1ae));}_0x52a994['push']('');}const _0x3f0f0d=[];_0x4c1481['requiresAuth']!==![]&&_0x3f0f0d[_0x3af791(0x1c9)]('Requires\x20authentication\x20(run\x20`'+CLI_BIN_NAME+_0x3af791(0x1da));_0x4c1481[_0x3af791(0x19c)]!==![]&&_0x3f0f0d[_0x3af791(0x1c9)]('Requires\x20appcode\x20(set\x20via\x20`'+CLI_BIN_NAME+_0x3af791(0x1d7));if(_0x3f0f0d['length']>0x0){_0x52a994[_0x3af791(0x1c9)](_0x3af791(0x1bc));for(const _0x109f43 of _0x3f0f0d){_0x52a994['push']('\x20\x20\x20\x20•\x20'+_0x109f43);}_0x52a994[_0x3af791(0x1c9)]('');}if(_0x4c1481['helpExtra']){const _0x52f41e=typeof _0x4c1481[_0x3af791(0x1df)]===_0x3af791(0x1ca)?_0x4c1481[_0x3af791(0x1df)]():_0x4c1481[_0x3af791(0x1df)];_0x52a994[_0x3af791(0x1c9)](_0x52f41e),_0x52a994[_0x3af791(0x1c9)]('');}return _0x52a994['join']('\x0a');}export function generateServiceHelp(_0x183b00){const _0x3c1737=a104_0x1d3ca8,_0x5f29d8=getServiceEntry(_0x183b00);if(!_0x5f29d8)return _0x3c1737(0x1d5)+_0x183b00+'\x0a';const _0x2f1d09=[],_0x8fe71f=serviceGroups[_0x3c1737(0x1d3)](_0x183b00);_0x2f1d09[_0x3c1737(0x1c9)](''),_0x2f1d09[_0x3c1737(0x1c9)]('\x20\x20'+_0x5f29d8[_0x3c1737(0x1a9)]),_0x2f1d09[_0x3c1737(0x1c9)](''),_0x2f1d09[_0x3c1737(0x1c9)](_0x3c1737(0x1c0)),_0x2f1d09['push'](_0x3c1737(0x1b5)+CLI_BIN_NAME+'\x20'+_0x183b00+_0x3c1737(0x1bb)),_0x2f1d09[_0x3c1737(0x1c9)](''),_0x2f1d09[_0x3c1737(0x1c9)](_0x3c1737(0x1a6));for(const _0x5880d3 of _0x5f29d8[_0x3c1737(0x1a5)]){_0x2f1d09[_0x3c1737(0x1c9)]('');const _0x584c0b=_0x5880d3[_0x3c1737(0x1dc)]?'\x20\x20'+_0x5880d3['tag'][_0x3c1737(0x1b4)]():'';_0x2f1d09['push'](_0x3c1737(0x1b5)+_0x5880d3['command']+_0x584c0b),_0x2f1d09[_0x3c1737(0x1c9)](_0x3c1737(0x1b3)+_0x5880d3['description']);const _0x250681=_0x8fe71f?.[_0x3c1737(0x19f)](_0x431710=>_0x431710['command']===_0x5880d3[_0x3c1737(0x1db)]);if(_0x250681?.[_0x3c1737(0x1a1)]&&_0x250681[_0x3c1737(0x1a1)][_0x3c1737(0x1c2)]>0x0){_0x2f1d09[_0x3c1737(0x1c9)](_0x3c1737(0x1cb));const _0x9cd99d=Math[_0x3c1737(0x1af)](..._0x250681[_0x3c1737(0x1a1)][_0x3c1737(0x1c1)](_0x5b4a55=>_0x5b4a55[_0x3c1737(0x1ae)][_0x3c1737(0x1c2)]+0x2));for(const _0x110bb9 of _0x250681[_0x3c1737(0x1a1)]){const _0xd308be=('<'+_0x110bb9[_0x3c1737(0x1ae)]+'>')['padEnd'](_0x9cd99d+0x2),_0x45114f=_0x110bb9['required']!==![]?'\x20(required)':'';_0x2f1d09['push'](_0x3c1737(0x1cd)+_0xd308be+_0x110bb9[_0x3c1737(0x1d8)]+_0x45114f);}}const _0x44fb1c=getCommandFlags(_0x183b00,_0x5880d3[_0x3c1737(0x1db)],_0x8fe71f);if(_0x44fb1c[_0x3c1737(0x1c2)]>0x0){const _0x4053b3=Math[_0x3c1737(0x1af)](..._0x44fb1c[_0x3c1737(0x1c1)](_0x5f6f59=>formatFlagName(_0x5f6f59)[_0x3c1737(0x1c2)]));for(const _0xd073b5 of _0x44fb1c){_0x2f1d09[_0x3c1737(0x1c9)](_0x3c1737(0x1b3)+formatFlagName(_0xd073b5)[_0x3c1737(0x1b0)](_0x4053b3+0x2)+renderFlagDesc(_0xd073b5));}}}return _0x2f1d09[_0x3c1737(0x1c9)](''),_0x2f1d09[_0x3c1737(0x1dd)]('\x0a');}export function generateFullHelp(){const _0x5f0abf=a104_0x1d3ca8,_0x1b9276=[];_0x1b9276[_0x5f0abf(0x1c9)](''),_0x1b9276[_0x5f0abf(0x1c9)]('\x20\x20'+CLI_DISPLAY_NAME),_0x1b9276[_0x5f0abf(0x1c9)](''),_0x1b9276[_0x5f0abf(0x1c9)](_0x5f0abf(0x1c0)),_0x1b9276[_0x5f0abf(0x1c9)](_0x5f0abf(0x1d9)+CLI_BIN_NAME+'\x20[global-options]\x20<service>\x20<command>\x20[flags]'),_0x1b9276[_0x5f0abf(0x1c9)](''),_0x1b9276[_0x5f0abf(0x1c9)]('\x20\x20GLOBAL\x20OPTIONS');const _0x20779c=GLOBAL_FLAGS[_0x5f0abf(0x1cc)](_0x2eebad=>!_0x2eebad['hidden']),_0x21ea40=Math[_0x5f0abf(0x1af)](..._0x20779c[_0x5f0abf(0x1c1)](_0x2b3da6=>{const _0x3afae4=_0x5f0abf,_0x234162=_0x2b3da6[_0x3afae4(0x1c8)]?'\x20'+_0x2b3da6['hint']:'';return('--'+_0x2b3da6[_0x3afae4(0x1ae)]+_0x234162)[_0x3afae4(0x1c2)];}));for(const _0xfd8870 of _0x20779c){const _0x25425b=_0xfd8870[_0x5f0abf(0x1c8)]?'\x20'+_0xfd8870['hint']:'',_0x5bc3fd=('--'+_0xfd8870[_0x5f0abf(0x1ae)]+_0x25425b)['padEnd'](_0x21ea40+0x2);_0x1b9276[_0x5f0abf(0x1c9)]('\x20\x20\x20\x20'+_0x5bc3fd+_0xfd8870[_0x5f0abf(0x1d8)]);}_0x1b9276[_0x5f0abf(0x1c9)](''),_0x1b9276[_0x5f0abf(0x1c9)]('\x20\x20COMMANDS'),_0x1b9276[_0x5f0abf(0x1c9)]('');for(const _0x39e9ee of serviceRegistry){_0x1b9276['push']('\x20\x20'+_0x39e9ee[_0x5f0abf(0x1a9)]);if(_0x39e9ee['isSingleCommand']){const _0x560e5d=_0x39e9ee['commands'][0x0],_0x32de48=_0x560e5d[_0x5f0abf(0x1dc)]??'';_0x1b9276[_0x5f0abf(0x1c9)](_0x5f0abf(0x1b5)+_0x39e9ee[_0x5f0abf(0x1c3)][_0x5f0abf(0x1b0)](0x12)+_0x560e5d[_0x5f0abf(0x1d8)]+_0x32de48);}else{const _0xea3ca9=_0x39e9ee[_0x5f0abf(0x1a5)][_0x5f0abf(0x1c1)](_0x236ac9=>_0x39e9ee[_0x5f0abf(0x1c3)]+'\x20'+_0x236ac9[_0x5f0abf(0x1db)]),_0x186dbf=Math[_0x5f0abf(0x1af)](..._0xea3ca9['map'](_0x4a0679=>_0x4a0679['length']));for(let _0x39e0a2=0x0;_0x39e0a2<_0x39e9ee['commands']['length'];_0x39e0a2++){const _0x5ebdce=_0x39e9ee[_0x5f0abf(0x1a5)][_0x39e0a2],_0x36aab6=_0x5ebdce[_0x5f0abf(0x1dc)]??'';_0x1b9276['push'](_0x5f0abf(0x1b5)+_0xea3ca9[_0x39e0a2][_0x5f0abf(0x1b0)](_0x186dbf+0x2)+_0x5ebdce[_0x5f0abf(0x1d8)]+_0x36aab6);}}if(_0x39e9ee[_0x5f0abf(0x1a3)]?.['helpExtra']){const _0x4a1913=typeof _0x39e9ee[_0x5f0abf(0x1a3)][_0x5f0abf(0x1df)]===_0x5f0abf(0x1ca)?_0x39e9ee[_0x5f0abf(0x1a3)][_0x5f0abf(0x1df)]():_0x39e9ee[_0x5f0abf(0x1a3)][_0x5f0abf(0x1df)];for(const _0x33af47 of _0x4a1913['split']('\x0a')){_0x1b9276[_0x5f0abf(0x1c9)]('\x20\x20'+_0x33af47);}}_0x1b9276[_0x5f0abf(0x1c9)]('');}return _0x1b9276[_0x5f0abf(0x1c9)](_0x5f0abf(0x1d1)+CLI_BIN_NAME+_0x5f0abf(0x1c4)),_0x1b9276[_0x5f0abf(0x1c9)](_0x5f0abf(0x1d1)+CLI_BIN_NAME+_0x5f0abf(0x1c5)),_0x1b9276[_0x5f0abf(0x1c9)](''),_0x1b9276[_0x5f0abf(0x1dd)]('\x0a');}function getCommandFlags(_0x3987d4,_0x1cc1bd,_0x25eb9e){if(_0x25eb9e){const _0x3b0948=_0x25eb9e['find'](_0x3299e8=>_0x3299e8['command']===_0x1cc1bd);if(_0x3b0948)return buildAllFlags(_0x3b0948);}return[];}function renderFlagDesc(_0x140770){const _0x1fb727=a104_0x1d3ca8;let _0x36c04c=_0x140770[_0x1fb727(0x1d8)];return _0x140770[_0x1fb727(0x1b2)]&&_0x140770[_0x1fb727(0x1b2)]['length']>0x0&&(_0x36c04c+='\x20('+_0x140770[_0x1fb727(0x1b2)][_0x1fb727(0x1dd)]('\x20|\x20')+')'),_0x140770['default']!==undefined&&_0x140770[_0x1fb727(0x19e)]!==''&&_0x140770[_0x1fb727(0x19e)]!==![]&&(_0x36c04c+=_0x1fb727(0x1ba)+_0x140770[_0x1fb727(0x19e)]+']'),_0x140770[_0x1fb727(0x1d2)]&&!_0x36c04c[_0x1fb727(0x1bd)](_0x1fb727(0x1a2))&&(_0x36c04c+=_0x1fb727(0x1b7)),_0x36c04c;}function formatFlagName(_0x2c7ae0){const _0x3517cf=a104_0x1d3ca8,_0x478f59=_0x2c7ae0[_0x3517cf(0x19b)]===_0x3517cf(0x1b9)?'':_0x2c7ae0[_0x3517cf(0x19b)]===_0x3517cf(0x1b6)?'\x20<n>':_0x3517cf(0x1b8);return'--'+_0x2c7ae0['name']+_0x478f59;}
|
|
1
|
+
const a105_0x106d5d=a105_0x54df;function a105_0x2fb8(){const _0x41194f=['2040EmYNJK','\x20[global-options]\x20<service>\x20<command>\x20[flags]','\x20\x20PREREQUISITES','high-risk-write','service','get','split','hint','2MtbvRs','4896388ETGQDk','boolean','7146mZMjAb','\x20\x20Unknown\x20service:\x20','367890DXGuvz','length','\x20auth`\x20first).','Requires\x20authentication\x20(run\x20`','\x20\x20COMMANDS','\x20(required)','\x20\x20[write]','510FbPFZC','\x20\x20[high-risk-write]','\x20<service>\x20<command>\x20--help`\x20for\x20command\x20flags.','\x20\x20FLAGS','\x20\x20RISK:\x20','hasFormat','Requires\x20appcode\x20(set\x20via\x20`','trim','number','default','commands','tag','1062039CechhB','473566WfQiCd','dryRun','47100TZSZhA','requiresAppCode','\x20\x20\x20\x20Requires\x20--yes\x20to\x20confirm,\x20or\x20interactive\x20prompt.','padEnd','isSingleCommand','7104713BEsiAm','\x20<n>','find','args','helpExtra','605JTxuEe','\x20[default:\x20','type','\x20project\x20init`\x20or\x20--appcode).','\x20\x20USAGE','risk','enum','\x20\x20\x20\x20\x20\x20','max','requiresAuth','required','\x20<service>\x20--help`\x20for\x20service\x20commands.','function','map','command','\x20[flags]','wildcardDef','label','push','\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20\x20\x20$\x20','name','\x20<value>','\x20\x20\x20\x20','description','join','\x20\x20ARGS','(required)','\x20\x20Run\x20`','includes'];a105_0x2fb8=function(){return _0x41194f;};return a105_0x2fb8();}(function(_0x17005e,_0x4bf996){const _0x5a5188=a105_0x54df,_0xb83b0f=_0x17005e();while(!![]){try{const _0x1f5761=-parseInt(_0x5a5188(0xb8))/0x1+parseInt(_0x5a5188(0xea))/0x2*(-parseInt(_0x5a5188(0xb7))/0x3)+parseInt(_0x5a5188(0xeb))/0x4+-parseInt(_0x5a5188(0xf6))/0x5*(parseInt(_0x5a5188(0xba))/0x6)+-parseInt(_0x5a5188(0xbf))/0x7+-parseInt(_0x5a5188(0xe2))/0x8*(-parseInt(_0x5a5188(0xed))/0x9)+-parseInt(_0x5a5188(0xef))/0xa*(-parseInt(_0x5a5188(0xc4))/0xb);if(_0x1f5761===_0x4bf996)break;else _0xb83b0f['push'](_0xb83b0f['shift']());}catch(_0x145f3b){_0xb83b0f['push'](_0xb83b0f['shift']());}}}(a105_0x2fb8,0xc4f44));function a105_0x54df(_0x56518b,_0x52659e){_0x56518b=_0x56518b-0xad;const _0x2fb83b=a105_0x2fb8();let _0x54dfd4=_0x2fb83b[_0x56518b];return _0x54dfd4;}import{buildAllFlags}from'../framework/build-all-flags.js';import{serviceRegistry,serviceGroups,getServiceEntry}from'../commands/registry.js';import{CLI_BIN_NAME,CLI_DISPLAY_NAME,GLOBAL_FLAGS}from'../constant/cli.js';const RISK_LABELS={'read':'','write':a105_0x106d5d(0xf5),'high-risk-write':a105_0x106d5d(0xf7)};export function generateCommandHelp(_0x539e38){const _0x2c3bb1=a105_0x106d5d,_0x1f43e1=[],_0x2faf1f=_0x539e38['service']===_0x539e38[_0x2c3bb1(0xd2)]?CLI_BIN_NAME+'\x20'+_0x539e38[_0x2c3bb1(0xe6)]:CLI_BIN_NAME+'\x20'+_0x539e38['service']+'\x20'+_0x539e38['command'],_0x584f91=_0x539e38['args']?_0x539e38[_0x2c3bb1(0xc2)]['map'](_0x1705f0=>_0x1705f0['required']!==![]?'<'+_0x1705f0[_0x2c3bb1(0xd9)]+'>':'['+_0x1705f0[_0x2c3bb1(0xd9)]+']')[_0x2c3bb1(0xdd)]('\x20'):'',_0x173269=_0x584f91?_0x2faf1f+'\x20'+_0x584f91+'\x20[flags]':_0x2faf1f+_0x2c3bb1(0xd3);_0x1f43e1[_0x2c3bb1(0xd6)](''),_0x1f43e1['push']('\x20\x20'+_0x539e38[_0x2c3bb1(0xdc)]),_0x1f43e1[_0x2c3bb1(0xd6)](''),_0x1f43e1[_0x2c3bb1(0xd6)](_0x2c3bb1(0xc8)),_0x1f43e1['push']('\x20\x20\x20\x20'+_0x173269),_0x1f43e1[_0x2c3bb1(0xd6)](''),_0x1f43e1[_0x2c3bb1(0xd6)](_0x2c3bb1(0xaf)+_0x539e38[_0x2c3bb1(0xc9)]);_0x539e38[_0x2c3bb1(0xc9)]===_0x2c3bb1(0xe5)&&_0x1f43e1[_0x2c3bb1(0xd6)](_0x2c3bb1(0xbc));_0x1f43e1[_0x2c3bb1(0xd6)]('');if(_0x539e38[_0x2c3bb1(0xc2)]&&_0x539e38[_0x2c3bb1(0xc2)][_0x2c3bb1(0xf0)]>0x0){_0x1f43e1[_0x2c3bb1(0xd6)](_0x2c3bb1(0xde));const _0x5e8e1d=Math[_0x2c3bb1(0xcc)](..._0x539e38[_0x2c3bb1(0xc2)]['map'](_0xafdcf3=>_0xafdcf3['name'][_0x2c3bb1(0xf0)]+0x2));for(const _0xe356f3 of _0x539e38[_0x2c3bb1(0xc2)]){const _0x16a8d1=('<'+_0xe356f3['name']+'>')[_0x2c3bb1(0xbd)](_0x5e8e1d+0x2),_0x5aeed6=_0xe356f3[_0x2c3bb1(0xce)]!==![]?_0x2c3bb1(0xf4):'';_0x1f43e1[_0x2c3bb1(0xd6)]('\x20\x20\x20\x20'+_0x16a8d1+_0xe356f3['description']+_0x5aeed6);}_0x1f43e1['push']('');}if(_0x539e38['flags'][_0x2c3bb1(0xf0)]>0x0||_0x539e38[_0x2c3bb1(0xb9)]||_0x539e38[_0x2c3bb1(0xb0)]!==![]){_0x1f43e1[_0x2c3bb1(0xd6)](_0x2c3bb1(0xae));const _0x2bb6c2=buildAllFlags(_0x539e38),_0x51ec6a=Math[_0x2c3bb1(0xcc)](..._0x2bb6c2[_0x2c3bb1(0xd1)](_0x1ddc7f=>formatFlagName(_0x1ddc7f)[_0x2c3bb1(0xf0)]));for(const _0x3663f1 of _0x2bb6c2){_0x1f43e1[_0x2c3bb1(0xd6)]('\x20\x20\x20\x20'+formatFlagName(_0x3663f1)[_0x2c3bb1(0xbd)](_0x51ec6a+0x2)+renderFlagDesc(_0x3663f1));}_0x1f43e1[_0x2c3bb1(0xd6)]('');}const _0x3b8210=[];_0x539e38[_0x2c3bb1(0xcd)]!==![]&&_0x3b8210[_0x2c3bb1(0xd6)](_0x2c3bb1(0xf2)+CLI_BIN_NAME+_0x2c3bb1(0xf1));_0x539e38[_0x2c3bb1(0xbb)]!==![]&&_0x3b8210[_0x2c3bb1(0xd6)](_0x2c3bb1(0xb1)+CLI_BIN_NAME+_0x2c3bb1(0xc7));if(_0x3b8210[_0x2c3bb1(0xf0)]>0x0){_0x1f43e1[_0x2c3bb1(0xd6)](_0x2c3bb1(0xe4));for(const _0x3fa2f3 of _0x3b8210){_0x1f43e1[_0x2c3bb1(0xd6)]('\x20\x20\x20\x20•\x20'+_0x3fa2f3);}_0x1f43e1[_0x2c3bb1(0xd6)]('');}if(_0x539e38[_0x2c3bb1(0xc3)]){const _0x4b8438=typeof _0x539e38[_0x2c3bb1(0xc3)]===_0x2c3bb1(0xd0)?_0x539e38['helpExtra']():_0x539e38[_0x2c3bb1(0xc3)];_0x1f43e1['push'](_0x4b8438),_0x1f43e1[_0x2c3bb1(0xd6)]('');}return _0x1f43e1[_0x2c3bb1(0xdd)]('\x0a');}export function generateServiceHelp(_0x4e5d87){const _0x23852f=a105_0x106d5d,_0x4d1ea5=getServiceEntry(_0x4e5d87);if(!_0x4d1ea5)return _0x23852f(0xee)+_0x4e5d87+'\x0a';const _0x408908=[],_0x1ae093=serviceGroups[_0x23852f(0xe7)](_0x4e5d87);_0x408908[_0x23852f(0xd6)](''),_0x408908['push']('\x20\x20'+_0x4d1ea5[_0x23852f(0xd5)]),_0x408908['push'](''),_0x408908[_0x23852f(0xd6)](_0x23852f(0xc8)),_0x408908[_0x23852f(0xd6)](_0x23852f(0xdb)+CLI_BIN_NAME+'\x20'+_0x4e5d87+'\x20<command>\x20[args]\x20[flags]'),_0x408908['push'](''),_0x408908[_0x23852f(0xd6)]('\x20\x20COMMANDS');for(const _0x559c6 of _0x4d1ea5[_0x23852f(0xb5)]){_0x408908['push']('');const _0x297e23=_0x559c6['tag']?'\x20\x20'+_0x559c6[_0x23852f(0xb6)][_0x23852f(0xb2)]():'';_0x408908['push'](_0x23852f(0xdb)+_0x559c6[_0x23852f(0xd2)]+_0x297e23),_0x408908[_0x23852f(0xd6)](_0x23852f(0xcb)+_0x559c6[_0x23852f(0xdc)]);const _0xf92812=_0x1ae093?.[_0x23852f(0xc1)](_0x1f27ee=>_0x1f27ee['command']===_0x559c6['command']);if(_0xf92812?.[_0x23852f(0xc2)]&&_0xf92812['args'][_0x23852f(0xf0)]>0x0){_0x408908[_0x23852f(0xd6)]('\x20\x20\x20\x20\x20\x20ARGS');const _0x3f87bf=Math[_0x23852f(0xcc)](..._0xf92812[_0x23852f(0xc2)][_0x23852f(0xd1)](_0x393e62=>_0x393e62['name']['length']+0x2));for(const _0x111c53 of _0xf92812['args']){const _0x2200d9=('<'+_0x111c53['name']+'>')[_0x23852f(0xbd)](_0x3f87bf+0x2),_0x110027=_0x111c53[_0x23852f(0xce)]!==![]?_0x23852f(0xf4):'';_0x408908[_0x23852f(0xd6)](_0x23852f(0xd7)+_0x2200d9+_0x111c53[_0x23852f(0xdc)]+_0x110027);}}const _0x298127=getCommandFlags(_0x4e5d87,_0x559c6[_0x23852f(0xd2)],_0x1ae093);if(_0x298127['length']>0x0){const _0x2e97fd=Math[_0x23852f(0xcc)](..._0x298127['map'](_0x3d009f=>formatFlagName(_0x3d009f)[_0x23852f(0xf0)]));for(const _0x33e66a of _0x298127){_0x408908[_0x23852f(0xd6)]('\x20\x20\x20\x20\x20\x20'+formatFlagName(_0x33e66a)[_0x23852f(0xbd)](_0x2e97fd+0x2)+renderFlagDesc(_0x33e66a));}}}return _0x408908[_0x23852f(0xd6)](''),_0x408908[_0x23852f(0xdd)]('\x0a');}export function generateFullHelp(){const _0x174150=a105_0x106d5d,_0x166f2c=[];_0x166f2c['push'](''),_0x166f2c[_0x174150(0xd6)]('\x20\x20'+CLI_DISPLAY_NAME),_0x166f2c[_0x174150(0xd6)](''),_0x166f2c['push'](_0x174150(0xc8)),_0x166f2c['push'](_0x174150(0xd8)+CLI_BIN_NAME+_0x174150(0xe3)),_0x166f2c[_0x174150(0xd6)](''),_0x166f2c[_0x174150(0xd6)]('\x20\x20GLOBAL\x20OPTIONS');const _0x1b2063=GLOBAL_FLAGS['filter'](_0x58fced=>!_0x58fced['hidden']),_0x2f8d73=Math['max'](..._0x1b2063[_0x174150(0xd1)](_0x3e095a=>{const _0x1cd66b=_0x174150,_0x5cfd59=_0x3e095a[_0x1cd66b(0xe9)]?'\x20'+_0x3e095a[_0x1cd66b(0xe9)]:'';return('--'+_0x3e095a[_0x1cd66b(0xd9)]+_0x5cfd59)[_0x1cd66b(0xf0)];}));for(const _0x8cce8d of _0x1b2063){const _0x4128be=_0x8cce8d[_0x174150(0xe9)]?'\x20'+_0x8cce8d[_0x174150(0xe9)]:'',_0x300d14=('--'+_0x8cce8d['name']+_0x4128be)[_0x174150(0xbd)](_0x2f8d73+0x2);_0x166f2c[_0x174150(0xd6)](_0x174150(0xdb)+_0x300d14+_0x8cce8d[_0x174150(0xdc)]);}_0x166f2c['push'](''),_0x166f2c['push'](_0x174150(0xf3)),_0x166f2c[_0x174150(0xd6)]('');for(const _0x37ada2 of serviceRegistry){_0x166f2c['push']('\x20\x20'+_0x37ada2[_0x174150(0xd5)]);if(_0x37ada2[_0x174150(0xbe)]){const _0x38df53=_0x37ada2['commands'][0x0],_0x22ceac=_0x38df53[_0x174150(0xb6)]??'';_0x166f2c[_0x174150(0xd6)](_0x174150(0xdb)+_0x37ada2[_0x174150(0xe6)]['padEnd'](0x12)+_0x38df53['description']+_0x22ceac);}else{const _0x27c05f=_0x37ada2[_0x174150(0xb5)][_0x174150(0xd1)](_0x88321e=>_0x37ada2['service']+'\x20'+_0x88321e['command']),_0xf22575=Math['max'](..._0x27c05f['map'](_0x49b920=>_0x49b920[_0x174150(0xf0)]));for(let _0x2f2817=0x0;_0x2f2817<_0x37ada2[_0x174150(0xb5)]['length'];_0x2f2817++){const _0x407253=_0x37ada2['commands'][_0x2f2817],_0x342d57=_0x407253[_0x174150(0xb6)]??'';_0x166f2c['push'](_0x174150(0xdb)+_0x27c05f[_0x2f2817][_0x174150(0xbd)](_0xf22575+0x2)+_0x407253[_0x174150(0xdc)]+_0x342d57);}}if(_0x37ada2[_0x174150(0xd4)]?.[_0x174150(0xc3)]){const _0x94331b=typeof _0x37ada2[_0x174150(0xd4)]['helpExtra']===_0x174150(0xd0)?_0x37ada2['wildcardDef']['helpExtra']():_0x37ada2[_0x174150(0xd4)][_0x174150(0xc3)];for(const _0x574630 of _0x94331b[_0x174150(0xe8)]('\x0a')){_0x166f2c[_0x174150(0xd6)]('\x20\x20'+_0x574630);}}_0x166f2c['push']('');}return _0x166f2c['push'](_0x174150(0xe0)+CLI_BIN_NAME+_0x174150(0xcf)),_0x166f2c[_0x174150(0xd6)](_0x174150(0xe0)+CLI_BIN_NAME+_0x174150(0xad)),_0x166f2c[_0x174150(0xd6)](''),_0x166f2c['join']('\x0a');}function getCommandFlags(_0x4bd657,_0x2e33f8,_0x3218dc){const _0x58dd38=a105_0x106d5d;if(_0x3218dc){const _0x11c8fc=_0x3218dc['find'](_0x19346a=>_0x19346a[_0x58dd38(0xd2)]===_0x2e33f8);if(_0x11c8fc)return buildAllFlags(_0x11c8fc);}return[];}function renderFlagDesc(_0x3e2e22){const _0x35d6d1=a105_0x106d5d;let _0xdbe5b6=_0x3e2e22[_0x35d6d1(0xdc)];return _0x3e2e22[_0x35d6d1(0xca)]&&_0x3e2e22[_0x35d6d1(0xca)][_0x35d6d1(0xf0)]>0x0&&(_0xdbe5b6+='\x20('+_0x3e2e22[_0x35d6d1(0xca)][_0x35d6d1(0xdd)]('\x20|\x20')+')'),_0x3e2e22[_0x35d6d1(0xb4)]!==undefined&&_0x3e2e22[_0x35d6d1(0xb4)]!==''&&_0x3e2e22[_0x35d6d1(0xb4)]!==![]&&(_0xdbe5b6+=_0x35d6d1(0xc5)+_0x3e2e22[_0x35d6d1(0xb4)]+']'),_0x3e2e22[_0x35d6d1(0xce)]&&!_0xdbe5b6[_0x35d6d1(0xe1)](_0x35d6d1(0xdf))&&(_0xdbe5b6+='\x20(required)'),_0xdbe5b6;}function formatFlagName(_0x2bdb84){const _0x137876=a105_0x106d5d,_0x53770a=_0x2bdb84[_0x137876(0xc6)]===_0x137876(0xec)?'':_0x2bdb84[_0x137876(0xc6)]===_0x137876(0xb3)?_0x137876(0xc0):_0x137876(0xda);return'--'+_0x2bdb84[_0x137876(0xd9)]+_0x53770a;}
|
package/lib/framework/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a106_0x3c61(){var _0x25d695=['9EnajPX','26eDZLpv','1294950AIRVzh','609903OnHplq','118676MfcLGP','18xaoHCM','44088tIPEPp','1658706WXJtWg','2189TfFZwn','8tRXPRd','117875uiRJzh','12701iLaZWB'];a106_0x3c61=function(){return _0x25d695;};return a106_0x3c61();}function a106_0x5dcf(_0x44acdc,_0xa4bdaa){_0x44acdc=_0x44acdc-0x9a;var _0x3c613b=a106_0x3c61();var _0x5dcf9a=_0x3c613b[_0x44acdc];return _0x5dcf9a;}(function(_0x13eb2a,_0xee14bc){var _0xf975e4=a106_0x5dcf,_0x5c8717=_0x13eb2a();while(!![]){try{var _0x48313c=-parseInt(_0xf975e4(0xa4))/0x1*(parseInt(_0xf975e4(0x9a))/0x2)+-parseInt(_0xf975e4(0xa5))/0x3*(-parseInt(_0xf975e4(0x9d))/0x4)+parseInt(_0xf975e4(0xa3))/0x5*(-parseInt(_0xf975e4(0x9e))/0x6)+parseInt(_0xf975e4(0xa0))/0x7*(-parseInt(_0xf975e4(0xa2))/0x8)+-parseInt(_0xf975e4(0x9c))/0x9+-parseInt(_0xf975e4(0x9b))/0xa+parseInt(_0xf975e4(0xa1))/0xb*(parseInt(_0xf975e4(0x9f))/0xc);if(_0x48313c===_0xee14bc)break;else _0x5c8717['push'](_0x5c8717['shift']());}catch(_0x1b8fab){_0x5c8717['push'](_0x5c8717['shift']());}}}(a106_0x3c61,0x24a3b));export{runCommand}from'../framework/runner.js';export{parseFlags,validateFlags}from'../framework/flags.js';export{formatOutput}from'../framework/output.js';export{generateCommandHelp,generateServiceHelp,generateFullHelp}from'../framework/help.js';export{extractList,extractPaging}from'../framework/response.js';export{riskLevelOrder}from'../framework/types.js';
|
package/lib/framework/output.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x51677f,_0xd62dad){const _0x591b61=a107_0x46ab,_0x18be39=_0x51677f();while(!![]){try{const _0x39be19=parseInt(_0x591b61(0x15f))/0x1+-parseInt(_0x591b61(0x176))/0x2+parseInt(_0x591b61(0x166))/0x3+parseInt(_0x591b61(0x16c))/0x4+parseInt(_0x591b61(0x188))/0x5+parseInt(_0x591b61(0x175))/0x6+-parseInt(_0x591b61(0x17e))/0x7*(parseInt(_0x591b61(0x18c))/0x8);if(_0x39be19===_0xd62dad)break;else _0x18be39['push'](_0x18be39['shift']());}catch(_0x6eb05d){_0x18be39['push'](_0x18be39['shift']());}}}(a107_0x2939,0x35d3e));import{applyJqFilter}from'../utils/apply-jq-filter.js';function a107_0x2939(){const _0x1529a9=['62650GdzwQL','risk','isArray','items','log','entries','stringify','dryRun','pretty','stdout','722120sMuNqj','keys','error','max','472PwOJjp','\x20items:\x0a','64817xtoczA','\x20(default\x20from\x20global\x20file)','trim','projectPath','(empty)','length','Found\x20','137772tpILoE','global','Error:\x20','command_error','message','globalPath','1468416CeicBF','\x20\x20Global\x20config:\x20\x20\x20','defaultApp','(none)','data','meta','\x20\x20Project\x20config:\x20\x20','\x20(default\x20from\x20project\x20file)','write','1880298vlMNsj','374248gJMoEz','map','endsWith','padEnd','\x20\x20Default\x20app:\x20\x20\x20\x20\x20','command','Unknown\x20error','object'];a107_0x2939=function(){return _0x1529a9;};return a107_0x2939();}export function formatOutput(_0x49eeb9,_0x11a56e){const _0x407709=a107_0x46ab,{format:_0x4f73b5}=_0x11a56e;switch(_0x4f73b5){case'json':printJson(_0x49eeb9,_0x11a56e);break;case'compress':printCompress(_0x49eeb9,_0x11a56e);break;case _0x407709(0x186):default:printPretty(_0x49eeb9,_0x11a56e);break;}}function a107_0x46ab(_0xf13e88,_0x2cd523){_0xf13e88=_0xf13e88-0x15e;const _0x2939aa=a107_0x2939();let _0x46ab3c=_0x2939aa[_0xf13e88];return _0x46ab3c;}function buildEnvelope(_0x2f391a,_0x2172f2){const _0xf43283=a107_0x46ab,_0x42a0b8={'ok':_0x2f391a['ok'],'command':_0x2172f2[_0xf43283(0x17b)],'risk':_0x2172f2[_0xf43283(0x17f)]};if(_0x2172f2[_0xf43283(0x185)])_0x42a0b8[_0xf43283(0x185)]=!![];if(_0x2f391a['data']!==undefined)_0x42a0b8[_0xf43283(0x170)]=_0x2f391a[_0xf43283(0x170)];return!_0x2f391a['ok']&&_0x2f391a[_0xf43283(0x16a)]&&(_0x42a0b8[_0xf43283(0x18a)]={'code':_0xf43283(0x169),'message':_0x2f391a[_0xf43283(0x16a)]}),_0x42a0b8;}function printJson(_0x16dd89,_0x5e50ed){const _0x4c1e7d=buildEnvelope(_0x16dd89,_0x5e50ed),_0x2f0066=JSON['stringify'](_0x4c1e7d,null,0x2)+'\x0a';writeJsonWithOptionalJq(_0x2f0066,_0x5e50ed);}function printCompress(_0x1e74fb,_0x572487){const _0x4197b1=a107_0x46ab,_0x3dd523=buildEnvelope(_0x1e74fb,_0x572487),_0x21706f=JSON[_0x4197b1(0x184)](_0x3dd523)+'\x0a';writeJsonWithOptionalJq(_0x21706f,_0x572487);}function writeJsonWithOptionalJq(_0x4cc96f,_0x30aa8c){const _0xe2a2c7=a107_0x46ab,_0x322f07=_0x30aa8c['jqFilter']?.[_0xe2a2c7(0x161)]();if(!_0x322f07){process['stdout'][_0xe2a2c7(0x174)](_0x4cc96f);return;}const _0x4619fb=applyJqFilter(_0x4cc96f,_0x322f07);process[_0xe2a2c7(0x187)][_0xe2a2c7(0x174)](_0x4619fb[_0xe2a2c7(0x178)]('\x0a')?_0x4619fb:_0x4619fb+'\x0a');}function isListWithMetaData(_0x17ec7d){const _0x592b8f=a107_0x46ab;return typeof _0x17ec7d===_0x592b8f(0x17d)&&_0x17ec7d!==null&&_0x592b8f(0x181)in _0x17ec7d&&Array[_0x592b8f(0x180)](_0x17ec7d[_0x592b8f(0x181)])&&_0x592b8f(0x171)in _0x17ec7d&&typeof _0x17ec7d[_0x592b8f(0x171)]===_0x592b8f(0x17d)&&_0x17ec7d[_0x592b8f(0x171)]!==null;}function printAppListMeta(_0x5d2b2f){const _0x1e37d4=a107_0x46ab,_0x3212dd=_0x5d2b2f['globalPath']!=null?String(_0x5d2b2f[_0x1e37d4(0x16b)]):_0x1e37d4(0x16f),_0x3f166a=_0x5d2b2f[_0x1e37d4(0x162)]!=null?String(_0x5d2b2f['projectPath']):_0x1e37d4(0x16f),_0x2c4156=_0x5d2b2f[_0x1e37d4(0x16e)]!=null?String(_0x5d2b2f[_0x1e37d4(0x16e)]):_0x1e37d4(0x16f),_0x3e1cf4=_0x5d2b2f['defaultAppSource'],_0x4b9ac7=_0x3e1cf4==='project'?_0x1e37d4(0x173):_0x3e1cf4===_0x1e37d4(0x167)?_0x1e37d4(0x160):'';console['log'](_0x1e37d4(0x16d)+_0x3212dd),console[_0x1e37d4(0x182)](_0x1e37d4(0x172)+_0x3f166a),console[_0x1e37d4(0x182)](_0x1e37d4(0x17a)+_0x2c4156+_0x4b9ac7),console[_0x1e37d4(0x182)]();}function printPretty(_0x327c0b,_0x5a3757){const _0x3bc920=a107_0x46ab;if(_0x5a3757[_0x3bc920(0x185)]){console[_0x3bc920(0x182)]('[dry-run]\x20Would\x20execute:'),console[_0x3bc920(0x182)](JSON[_0x3bc920(0x184)](_0x327c0b[_0x3bc920(0x170)],null,0x2));return;}if(!_0x327c0b['ok']){console[_0x3bc920(0x18a)](_0x3bc920(0x168)+(_0x327c0b['message']??_0x3bc920(0x17c)));return;}const _0x9e3e72=_0x327c0b[_0x3bc920(0x170)];if(_0x9e3e72===undefined||_0x9e3e72===null){if(_0x327c0b['message'])console[_0x3bc920(0x182)](_0x327c0b['message']);return;}if(isListWithMetaData(_0x9e3e72)){printAppListMeta(_0x9e3e72[_0x3bc920(0x171)]),printArrayPretty(_0x9e3e72['items']);return;}if(Array[_0x3bc920(0x180)](_0x9e3e72)){printArrayPretty(_0x9e3e72);return;}if(typeof _0x9e3e72===_0x3bc920(0x17d)){printObjectPretty(_0x9e3e72);return;}console[_0x3bc920(0x182)](String(_0x9e3e72));}function printObjectPretty(_0x4bf7af){const _0x5b054c=a107_0x46ab,_0x1af953=Math['max'](...Object[_0x5b054c(0x189)](_0x4bf7af)[_0x5b054c(0x177)](_0x2ca337=>_0x2ca337[_0x5b054c(0x164)]),0x0);for(const [_0x722fdf,_0x39f4ea]of Object[_0x5b054c(0x183)](_0x4bf7af)){if(_0x39f4ea===undefined||_0x39f4ea===null)continue;const _0x15915f=_0x722fdf[_0x5b054c(0x179)](_0x1af953);typeof _0x39f4ea===_0x5b054c(0x17d)?console[_0x5b054c(0x182)](_0x15915f+'\x20\x20'+JSON['stringify'](_0x39f4ea)):console[_0x5b054c(0x182)](_0x15915f+'\x20\x20'+_0x39f4ea);}}function printArrayPretty(_0x54e63b){const _0x3d74bf=a107_0x46ab;if(_0x54e63b['length']===0x0){console[_0x3d74bf(0x182)](_0x3d74bf(0x163));return;}console['log'](_0x3d74bf(0x165)+_0x54e63b[_0x3d74bf(0x164)]+_0x3d74bf(0x15e));for(const _0xf5635 of _0x54e63b){if(typeof _0xf5635===_0x3d74bf(0x17d)&&_0xf5635!==null){const _0x1ee9f4=Object[_0x3d74bf(0x183)](_0xf5635)['filter'](([,_0x117244])=>_0x117244!=null&&_0x117244!=='');if(_0x1ee9f4[_0x3d74bf(0x164)]===0x0)continue;const _0x21ee82=Math[_0x3d74bf(0x18b)](..._0x1ee9f4[_0x3d74bf(0x177)](([_0x557de9])=>_0x557de9['length']));for(const [_0x596f89,_0x214f10]of _0x1ee9f4){const _0x61694d=typeof _0x214f10===_0x3d74bf(0x17d)?JSON[_0x3d74bf(0x184)](_0x214f10):String(_0x214f10);console['log']('\x20\x20'+_0x596f89['padEnd'](_0x21ee82)+'\x20\x20'+_0x61694d);}console['log']('');}else console[_0x3d74bf(0x182)]('\x20\x20'+_0xf5635);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1369c6,_0x202268){var _0x4cab58=a108_0xcc09,_0x1ff3e8=_0x1369c6();while(!![]){try{var _0x1b1ee5=-parseInt(_0x4cab58(0x19e))/0x1+-parseInt(_0x4cab58(0x195))/0x2*(parseInt(_0x4cab58(0x1a1))/0x3)+-parseInt(_0x4cab58(0x19a))/0x4*(parseInt(_0x4cab58(0x19c))/0x5)+-parseInt(_0x4cab58(0x19b))/0x6*(-parseInt(_0x4cab58(0x193))/0x7)+-parseInt(_0x4cab58(0x198))/0x8*(parseInt(_0x4cab58(0x196))/0x9)+-parseInt(_0x4cab58(0x19f))/0xa*(-parseInt(_0x4cab58(0x197))/0xb)+parseInt(_0x4cab58(0x1a0))/0xc;if(_0x1b1ee5===_0x202268)break;else _0x1ff3e8['push'](_0x1ff3e8['shift']());}catch(_0x2981ec){_0x1ff3e8['push'](_0x1ff3e8['shift']());}}}(a108_0x6271,0xee7de));function a108_0xcc09(_0xc890f5,_0x3628c8){_0xc890f5=_0xc890f5-0x193;var _0x62715e=a108_0x6271();var _0xcc09f=_0x62715e[_0xc890f5];return _0xcc09f;}function a108_0x6271(){var _0xd8174a=['object','278qorfuZ','45UJtvuS','15279VFyiAd','2484056CKNRlq','paging','11536NPtmtN','49794bhsvxD','2770ZckosF','isArray','956387jRzKAk','9930KNKmuS','36803508ChkktT','20994cPjoeT','1358ltMxne'];a108_0x6271=function(){return _0xd8174a;};return a108_0x6271();}export function extractList(_0x2eff27){var _0x4229c3=a108_0xcc09;if(Array[_0x4229c3(0x19d)](_0x2eff27))return _0x2eff27;if(_0x2eff27&&typeof _0x2eff27==='object')return _0x2eff27['tableData']??[];return[];}export function extractPaging(_0x4fb924){var _0x2610c0=a108_0xcc09;if(_0x4fb924&&typeof _0x4fb924===_0x2610c0(0x194)&&!Array[_0x2610c0(0x19d)](_0x4fb924))return _0x4fb924[_0x2610c0(0x199)];return undefined;}
|
package/lib/framework/runner.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5269b1,_0x2ac857){const _0x5affe5=a109_0x1b4c,_0x48be3c=_0x5269b1();while(!![]){try{const _0x305d10=-parseInt(_0x5affe5(0x147))/0x1*(parseInt(_0x5affe5(0x161))/0x2)+-parseInt(_0x5affe5(0x143))/0x3*(-parseInt(_0x5affe5(0x135))/0x4)+parseInt(_0x5affe5(0x169))/0x5+parseInt(_0x5affe5(0x133))/0x6+parseInt(_0x5affe5(0x16b))/0x7*(parseInt(_0x5affe5(0x137))/0x8)+parseInt(_0x5affe5(0x14f))/0x9+parseInt(_0x5affe5(0x168))/0xa*(-parseInt(_0x5affe5(0x159))/0xb);if(_0x305d10===_0x2ac857)break;else _0x48be3c['push'](_0x48be3c['shift']());}catch(_0x39a5ec){_0x48be3c['push'](_0x48be3c['shift']());}}}(a109_0x2762,0xecc55));import{riskLevelOrder,normalizeLegacyOutputFormat}from'../framework/types.js';import{parseFlags,validateFlags}from'../framework/flags.js';function a109_0x2762(){const _0x457eed=['`\x20has\x20risk\x20level\x20\x22','--jq\x20only\x20applies\x20with\x20--format\x20json\x20or\x20--format\x20compress\x20(current:\x20','defaultFormat','code','defaultOutputFormat','356Vckxoc','isNonInteractive','length','High-risk\x20operation\x20`','service','pretty','\x22,\x20which\x20exceeds\x20the\x20configured\x20riskLevel\x20\x22','8980kiAaIL','3568420fbKRxm','stderr','7daaiyd','\x22.\x20','\x20api\x20pull`\x20first.','appCode','dryRun','requiresAppCode','\x20init\x20--appcode\x20<code>`\x20or\x20pass\x20--appcode.','--dry-run\x20is\x20not\x20supported\x20for\x20`','selectedAppName','\x0a\x20\x20\x20Continue?\x20[y/N]\x20','trim','createInterface','resolveApiDomain','`\x20requires\x20either\x20--code\x20or\x20--alias.','cookie','jqFilter','`\x20requires\x20--yes\x20in\x20non-interactive\x20mode.','command','node:readline','args','defaultPageSize','2158362FxEHAm','type','242636JDLXPP','risk','8903544wbbmJn','name','stdin','map','pagesize','question','../core/api-client.js','\x22.\x20visit\x20https://qizhiyuntu.feishu.cn/docx/JTiOdxQlXo2dQLxXVu6ctutcnme\x20for\x20more\x20information.','dry-run','hasFormat','requiresAuth','toLowerCase','51huIuxT','close','\x20\x20Edit\x20the\x20config\x20file\x20manually\x20and\x20set\x20riskLevel\x20to\x20\x22','validation','6178jTgdWr','configMissing','flags','resolveCookie','rawFlags','No\x20api.ts\x20found\x20in\x20','alias','apiDir','9040014SQpkkC','Available\x20aliases:\x20','string','format','json','cancelled','riskLevel','number','yes','.\x20Run\x20`','26367mvdIMT','Command\x20`','defaultVerbose'];a109_0x2762=function(){return _0x457eed;};return a109_0x2762();}function a109_0x1b4c(_0x1f2931,_0x23d0f2){_0x1f2931=_0x1f2931-0x133;const _0x2762c0=a109_0x2762();let _0x1b4c77=_0x2762c0[_0x1f2931];return _0x1b4c77;}import{formatOutput}from'../framework/output.js';import{CliErrors}from'../errors.js';import{resolveAlias,listAliases}from'../core/alias-resolver.js';import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_API_DIR}from'../constant/paths.js';export async function runCommand(_0x2d6913,_0x422e57){const _0x8ae64c=a109_0x1b4c,_0x15d9c0=CLI_BIN_NAME+'\x20'+_0x2d6913[_0x8ae64c(0x165)]+'\x20'+_0x2d6913[_0x8ae64c(0x17c)],_0x58fa5e=parseFlags(_0x2d6913[_0x8ae64c(0x149)],_0x422e57[_0x8ae64c(0x14b)]);validateFlags(_0x2d6913['flags'],_0x58fa5e,_0x15d9c0);if(!_0x58fa5e[_0x8ae64c(0x13f)]&&_0x422e57[_0x8ae64c(0x155)]&&riskLevelOrder(_0x2d6913[_0x8ae64c(0x136)])>riskLevelOrder(_0x422e57['riskLevel'])){if(_0x422e57[_0x8ae64c(0x162)])throw CliErrors['validation']('Command\x20`'+_0x15d9c0+_0x8ae64c(0x15c)+_0x2d6913['risk']+_0x8ae64c(0x167)+_0x422e57[_0x8ae64c(0x155)]+'\x22.');throw CliErrors[_0x8ae64c(0x146)](_0x8ae64c(0x15a)+_0x15d9c0+_0x8ae64c(0x15c)+_0x2d6913['risk']+_0x8ae64c(0x167)+_0x422e57[_0x8ae64c(0x155)]+'\x22.\x0a'+(_0x8ae64c(0x145)+_0x2d6913[_0x8ae64c(0x136)]+_0x8ae64c(0x13e)));}const _0x5cde0c=_0x422e57['apiDir']||DEFAULT_API_DIR;resolveAliasToCode(_0x2d6913,_0x58fa5e,_0x5cde0c,_0x15d9c0);let _0x35935f='';if(_0x2d6913[_0x8ae64c(0x141)]!==![]){_0x35935f=_0x422e57[_0x8ae64c(0x14a)]();if(!_0x35935f)throw CliErrors['authRequired']();const {setActiveCookie:_0x24a79a}=await import(_0x8ae64c(0x13d));_0x24a79a(_0x35935f);}let _0x5911d8='';if(_0x2d6913[_0x8ae64c(0x170)]!==![]){_0x5911d8=_0x422e57['resolveAppCode']()??'';if(!_0x5911d8)throw CliErrors[_0x8ae64c(0x148)]('Set\x20appcode\x20via\x20`'+CLI_BIN_NAME+_0x8ae64c(0x171));}let _0x562534=resolveFormat(_0x58fa5e,_0x2d6913,_0x422e57[_0x8ae64c(0x15e)]);const _0xd7fd9=resolveJqFilter(_0x58fa5e);_0xd7fd9&&_0x562534===_0x8ae64c(0x166)&&(_0x562534=_0x8ae64c(0x153));if(_0xd7fd9&&_0x562534!=='json'&&_0x562534!=='compress')throw CliErrors[_0x8ae64c(0x146)](_0x8ae64c(0x15d)+_0x562534+').');const _0x14d1bd=buildRuntimeContext({'appCode':_0x5911d8,'cookie':_0x35935f,'apiDomain':_0x422e57[_0x8ae64c(0x177)](),'format':_0x562534,'jqFilter':_0xd7fd9,'flags':_0x58fa5e,'def':_0x2d6913,'nonInteractive':_0x422e57[_0x8ae64c(0x162)],'defaultPageSize':_0x422e57[_0x8ae64c(0x17f)],'defaultVerbose':_0x422e57[_0x8ae64c(0x15b)],'apiDir':_0x5cde0c,'selectedAppName':_0x422e57[_0x8ae64c(0x173)],'args':_0x422e57['args']??[]});_0x2d6913['validate']&&await _0x2d6913['validate'](_0x14d1bd);if(_0x58fa5e[_0x8ae64c(0x13f)]){if(!_0x2d6913[_0x8ae64c(0x16f)])throw CliErrors[_0x8ae64c(0x146)](_0x8ae64c(0x172)+_0x15d9c0+'`.');const _0x327ab9=await _0x2d6913[_0x8ae64c(0x16f)](_0x14d1bd);formatOutput({'ok':!![],'data':_0x327ab9},{'command':_0x15d9c0,'risk':_0x2d6913[_0x8ae64c(0x136)],'format':_0x562534,'dryRun':!![],'jqFilter':_0xd7fd9});return;}if(_0x2d6913[_0x8ae64c(0x136)]==='high-risk-write'&&!_0x58fa5e['yes']){if(_0x422e57[_0x8ae64c(0x162)])throw CliErrors[_0x8ae64c(0x146)](_0x8ae64c(0x164)+_0x15d9c0+_0x8ae64c(0x17b));await requireConfirmation(_0x15d9c0);}const _0x40b965=await _0x2d6913['execute'](_0x14d1bd);formatOutput(_0x40b965,{'command':_0x15d9c0,'risk':_0x2d6913['risk'],'format':_0x562534,'jqFilter':_0xd7fd9});}function buildRuntimeContext(_0x24a1d3){const _0x5676ca=a109_0x1b4c,{flags:_0x4fd432,def:_0x18dabd}=_0x24a1d3,_0x3b39af=CLI_BIN_NAME+'\x20'+_0x18dabd[_0x5676ca(0x165)]+'\x20'+_0x18dabd[_0x5676ca(0x17c)];return{'appCode':_0x24a1d3[_0x5676ca(0x16e)],'cookie':_0x24a1d3[_0x5676ca(0x179)],'apiDomain':_0x24a1d3['apiDomain'],'format':_0x24a1d3['format'],'nonInteractive':_0x24a1d3['nonInteractive'],'apiDir':_0x24a1d3[_0x5676ca(0x14e)],'selectedAppName':_0x24a1d3[_0x5676ca(0x173)],'args':_0x24a1d3[_0x5676ca(0x17e)],'str'(_0x2f98ff){return String(_0x4fd432[_0x2f98ff]??'');},'bool'(_0x1b4d42){const _0x4602fb=_0x5676ca;if(_0x4fd432[_0x1b4d42]===!![])return!![];if(_0x1b4d42==='verbose'&&_0x24a1d3[_0x4602fb(0x15b)])return!![];return![];},'num'(_0xd2a8ac,_0x10978c){const _0x5509c8=_0x5676ca,_0x424407=_0x4fd432[_0xd2a8ac];if(typeof _0x424407===_0x5509c8(0x156))return _0x424407;if(_0xd2a8ac===_0x5509c8(0x13b)&&_0x24a1d3[_0x5509c8(0x17f)]!=null)return _0x24a1d3['defaultPageSize'];return _0x10978c??0x0;},'flag'(_0x11ec4c){return _0x4fd432[_0x11ec4c];},'output'(_0x21b2bd){const _0x14b934=_0x5676ca;formatOutput(_0x21b2bd,{'command':_0x3b39af,'risk':_0x18dabd['risk'],'format':_0x24a1d3[_0x14b934(0x152)],'jqFilter':_0x24a1d3[_0x14b934(0x17a)]});}};}function resolveJqFilter(_0x4d0577){const _0x26247f=a109_0x1b4c,_0x4c247f=_0x4d0577['jq'];if(_0x4c247f===undefined||_0x4c247f===null)return undefined;const _0xe47519=String(_0x4c247f)[_0x26247f(0x175)]();return _0xe47519===''?undefined:_0xe47519;}function resolveFormat(_0x20b1ad,_0x47db39,_0x3f2626){const _0x555d6a=a109_0x1b4c;if(_0x47db39[_0x555d6a(0x140)]===![])return _0x555d6a(0x166);const _0x5e2e23=normalizeLegacyOutputFormat(_0x20b1ad['format']);if(_0x5e2e23)return _0x5e2e23;const _0x2b1eb0=normalizeLegacyOutputFormat(_0x3f2626);if(_0x2b1eb0)return _0x2b1eb0;const _0x1d42e7=normalizeLegacyOutputFormat(_0x47db39[_0x555d6a(0x160)]);if(_0x1d42e7)return _0x1d42e7;return'pretty';}async function requireConfirmation(_0x93dbc){const _0x15976b=a109_0x1b4c,_0x3bbe18=await import(_0x15976b(0x17d)),_0x3385ea=_0x3bbe18[_0x15976b(0x176)]({'input':process[_0x15976b(0x139)],'output':process[_0x15976b(0x16a)]});return new Promise((_0x53a7fe,_0x7b1f24)=>{const _0x6fd372=_0x15976b;_0x3385ea[_0x6fd372(0x13c)]('⚠\x20\x20High-risk\x20operation:\x20'+_0x93dbc+_0x6fd372(0x174),_0x427b20=>{const _0x287038=_0x6fd372;_0x3385ea[_0x287038(0x144)](),_0x427b20[_0x287038(0x142)]()==='y'||_0x427b20['toLowerCase']()===_0x287038(0x157)?_0x53a7fe():_0x7b1f24(CliErrors[_0x287038(0x154)]('Operation\x20cancelled\x20by\x20user.'));});});}function resolveAliasToCode(_0x3cd475,_0x5935b9,_0x140f50,_0x3766d8){const _0x1a2a0f=a109_0x1b4c,_0x2eb68b=_0x3cd475[_0x1a2a0f(0x149)]['some'](_0x45ed02=>_0x45ed02['name']==='code'&&_0x45ed02[_0x1a2a0f(0x134)]===_0x1a2a0f(0x151)),_0x1ab1be=_0x3cd475[_0x1a2a0f(0x149)]['some'](_0x51bebb=>_0x51bebb[_0x1a2a0f(0x138)]===_0x1a2a0f(0x14d)&&_0x51bebb[_0x1a2a0f(0x134)]===_0x1a2a0f(0x151));if(!_0x2eb68b||!_0x1ab1be)return;const _0x2390a9=_0x5935b9[_0x1a2a0f(0x15f)]?String(_0x5935b9['code']):'',_0x32d83f=_0x5935b9[_0x1a2a0f(0x14d)]?String(_0x5935b9[_0x1a2a0f(0x14d)]):'';if(!_0x2390a9&&!_0x32d83f)throw CliErrors[_0x1a2a0f(0x146)]('`'+_0x3766d8+_0x1a2a0f(0x178));if(_0x32d83f&&!_0x2390a9){const _0x2f67c4=resolveAlias(_0x140f50,_0x32d83f);if(!_0x2f67c4){const _0x570d0e=listAliases(_0x140f50)[_0x1a2a0f(0x13a)](_0x14740d=>_0x14740d['alias']),_0x2ebf4b=_0x570d0e[_0x1a2a0f(0x163)]?_0x1a2a0f(0x150)+_0x570d0e['join'](',\x20'):_0x1a2a0f(0x14c)+_0x140f50+_0x1a2a0f(0x158)+CLI_BIN_NAME+_0x1a2a0f(0x16d);throw CliErrors[_0x1a2a0f(0x146)]('Unknown\x20alias\x20\x22'+_0x32d83f+_0x1a2a0f(0x16c)+_0x2ebf4b);}_0x5935b9[_0x1a2a0f(0x15f)]=_0x2f67c4;}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a110_0x5bfd(){const _0x502857=['757700pRjGaF','isSingleCommand','wildcardDef','default','push','hidden','flags','commands','enum','6014470MAfmuO','required','tag','../commands/registry.js','length','4605416OmulTG','696396wjQzgd','dryRun','source','4437498XyjuTA','trim','alias','hint','11328QymJOc','725PQhxUI','description','defaultCommand','service','regex','requiresAppCode','requiresAuth','map','1087584kOwUoq','pattern','command','<script>','helpExtra'];a110_0x5bfd=function(){return _0x502857;};return a110_0x5bfd();}(function(_0x54bf63,_0xcb0df4){const _0x885fa=a110_0x4e97,_0x8196f2=_0x54bf63();while(!![]){try{const _0x5d7c96=parseInt(_0x885fa(0xb4))/0x1+parseInt(_0x885fa(0xc3))/0x2+-parseInt(_0x885fa(0xaf))/0x3+-parseInt(_0x885fa(0xca))/0x4*(-parseInt(_0x885fa(0xcb))/0x5)+parseInt(_0x885fa(0xc6))/0x6+-parseInt(_0x885fa(0xbd))/0x7+-parseInt(_0x885fa(0xc2))/0x8;if(_0x5d7c96===_0xcb0df4)break;else _0x8196f2['push'](_0x8196f2['shift']());}catch(_0x447bd0){_0x8196f2['push'](_0x8196f2['shift']());}}}(a110_0x5bfd,0x6ffd2));import{buildAllFlags}from'../framework/build-all-flags.js';import{CLI_BIN_NAME,CLI_DISPLAY_NAME,GLOBAL_FLAGS}from'../constant/cli.js';import{VERSION,GIT_COMMIT}from'../generated/build-info.js';function serializeFlag(_0xe55e06){const _0xf0fe71=a110_0x4e97,_0xc0cc15={'name':_0xe55e06['name'],'type':_0xe55e06['type'],'description':_0xe55e06[_0xf0fe71(0xcc)]};if(_0xe55e06[_0xf0fe71(0xbe)]!==undefined)_0xc0cc15[_0xf0fe71(0xbe)]=_0xe55e06[_0xf0fe71(0xbe)];if(_0xe55e06[_0xf0fe71(0xb7)]!==undefined)_0xc0cc15[_0xf0fe71(0xb7)]=_0xe55e06['default'];if(_0xe55e06[_0xf0fe71(0xbc)]&&_0xe55e06['enum']['length']>0x0)_0xc0cc15['enum']=_0xe55e06[_0xf0fe71(0xbc)];if(_0xe55e06[_0xf0fe71(0xc8)])_0xc0cc15[_0xf0fe71(0xc8)]=_0xe55e06[_0xf0fe71(0xc8)];if(_0xe55e06['hidden'])_0xc0cc15[_0xf0fe71(0xb9)]=_0xe55e06[_0xf0fe71(0xb9)];return _0xe55e06['pattern']&&(_0xc0cc15[_0xf0fe71(0xb0)]={'source':_0xe55e06[_0xf0fe71(0xb0)]['regex'][_0xf0fe71(0xc5)],'flags':_0xe55e06['pattern'][_0xf0fe71(0xcf)][_0xf0fe71(0xba)],'description':_0xe55e06[_0xf0fe71(0xb0)][_0xf0fe71(0xcc)]}),_0xc0cc15;}function a110_0x4e97(_0x138c4f,_0x4f4912){_0x138c4f=_0x138c4f-0xae;const _0x5bfdee=a110_0x5bfd();let _0x4e9730=_0x5bfdee[_0x138c4f];return _0x4e9730;}function serializeHelpExtra(_0x417c2b){const _0x5e033c=a110_0x4e97;if(_0x417c2b[_0x5e033c(0xb3)]===undefined)return undefined;if(typeof _0x417c2b['helpExtra']==='function')return{'dynamic':!![]};return _0x417c2b[_0x5e033c(0xb3)];}function serializeCommand(_0x2cf6a5,_0x24454a){const _0x39ce78=a110_0x4e97,_0x5ca62c=_0x2cf6a5[_0x39ce78(0xd1)]!==![],_0x1fd920=_0x2cf6a5[_0x39ce78(0xd0)]!==![],_0x571693=_0x2cf6a5['hasFormat']!==![],_0xecf980=serializeHelpExtra(_0x2cf6a5);return{'command':_0x24454a['command'],'description':_0x24454a[_0x39ce78(0xcc)],..._0x24454a[_0x39ce78(0xbf)]?{'tag':_0x24454a[_0x39ce78(0xbf)][_0x39ce78(0xc7)]()}:{},'risk':_0x2cf6a5['risk'],'requiresAuth':_0x5ca62c,'requiresAppCode':_0x1fd920,'hasFormat':_0x571693,'supportsDryRun':Boolean(_0x2cf6a5[_0x39ce78(0xc4)]),..._0x2cf6a5['args']&&_0x2cf6a5['args'][_0x39ce78(0xc1)]>0x0?{'args':_0x2cf6a5['args']}:{},'flags':buildAllFlags(_0x2cf6a5)[_0x39ce78(0xae)](serializeFlag),..._0xecf980!==undefined?{'helpExtra':_0xecf980}:{}};}export async function buildSchemaPayload(){const _0x208df9=a110_0x4e97,{serviceRegistry:_0x29cb78,findDefinition:_0x5b8581}=await import(_0x208df9(0xc0)),_0x4b64f0=[];for(const _0x18b2b9 of _0x29cb78){const _0x4dcc5e=[];for(const _0x55ef6a of _0x18b2b9[_0x208df9(0xbb)]){const _0x4451a8=_0x55ef6a[_0x208df9(0xb1)]===_0x208df9(0xb2)&&_0x18b2b9['wildcardDef']?_0x18b2b9[_0x208df9(0xb6)]:_0x5b8581(_0x18b2b9[_0x208df9(0xce)],_0x55ef6a[_0x208df9(0xb1)]);if(!_0x4451a8)continue;_0x4dcc5e[_0x208df9(0xb8)](serializeCommand(_0x4451a8,_0x55ef6a));}_0x4b64f0[_0x208df9(0xb8)]({'service':_0x18b2b9[_0x208df9(0xce)],'label':_0x18b2b9['label'],..._0x18b2b9[_0x208df9(0xb5)]?{'isSingleCommand':!![]}:{},..._0x18b2b9[_0x208df9(0xcd)]?{'defaultCommand':_0x18b2b9[_0x208df9(0xcd)]}:{},'hasWildcard':Boolean(_0x18b2b9[_0x208df9(0xb6)]),'commands':_0x4dcc5e});}return{'schemaVersion':0x1,'cli':{'bin':CLI_BIN_NAME,'displayName':CLI_DISPLAY_NAME,'version':VERSION,'gitCommit':GIT_COMMIT},'globalFlags':GLOBAL_FLAGS['map'](_0x2af743=>({'name':_0x2af743['name'],'type':_0x2af743['type'],'description':_0x2af743[_0x208df9(0xcc)],..._0x2af743[_0x208df9(0xc9)]?{'hint':_0x2af743[_0x208df9(0xc9)]}:{},..._0x2af743['hidden']?{'hidden':!![]}:{}})),'services':_0x4b64f0};}
|
package/lib/framework/types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x4312bb,_0x58790b){const _0x4053e9=a111_0x4eae,_0x5e74f9=_0x4312bb();while(!![]){try{const _0x9ec494=-parseInt(_0x4053e9(0xc7))/0x1+-parseInt(_0x4053e9(0xc2))/0x2*(parseInt(_0x4053e9(0xc4))/0x3)+parseInt(_0x4053e9(0xc3))/0x4+parseInt(_0x4053e9(0xca))/0x5+-parseInt(_0x4053e9(0xcc))/0x6*(parseInt(_0x4053e9(0xc1))/0x7)+parseInt(_0x4053e9(0xc6))/0x8*(parseInt(_0x4053e9(0xc5))/0x9)+parseInt(_0x4053e9(0xbf))/0xa;if(_0x9ec494===_0x58790b)break;else _0x5e74f9['push'](_0x5e74f9['shift']());}catch(_0x1b6c66){_0x5e74f9['push'](_0x5e74f9['shift']());}}}(a111_0x5a59,0x3945d));function a111_0x4eae(_0x5787be,_0x327d68){_0x5787be=_0x5787be-0xbf;const _0x5a59e7=a111_0x5a59();let _0x4eaeb6=_0x5a59e7[_0x5787be];return _0x4eaeb6;}export function riskLevelOrder(_0x35ef39){const _0x1445fa=a111_0x4eae,_0x1efed1={'read':0x0,'write':0x1,'high-risk-write':0x2};return _0x1efed1[_0x35ef39??_0x1445fa(0xc0)]??0x0;}export function isValidFormat(_0x3438e2){const _0x2929b7=a111_0x4eae;return _0x3438e2==='json'||_0x3438e2===_0x2929b7(0xc8)||_0x3438e2===_0x2929b7(0xc9);}function a111_0x5a59(){const _0x29a221=['read','23723etxbBQ','2pmPgjN','1632064dUgrET','1042293ckHogu','3399705vlibWe','8lblKjv','53017hdfUrf','pretty','compress','608385xyILVI','table','798WHzmFy','1783360IyCSzX'];a111_0x5a59=function(){return _0x29a221;};return a111_0x5a59();}export function normalizeLegacyOutputFormat(_0x1a8794){const _0x1005fe=a111_0x4eae;if(_0x1a8794===_0x1005fe(0xcb))return _0x1005fe(0xc8);if(isValidFormat(_0x1a8794))return _0x1a8794;return undefined;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a112_0x524620=a112_0x3a8e;function a112_0x3d87(){const _0x4a1ad8=['3773136CwgxEk','46dhCHXc','43005srzUAB','75783SYnteV','40NVOBoZ','332pONtNG','360959YFOEnp','6aa2634','1285696toqybW','3538701pCgXTS','2.0.11','2530430sJHGwg'];a112_0x3d87=function(){return _0x4a1ad8;};return a112_0x3d87();}(function(_0x546e2a,_0x2d58a6){const _0x3aba84=a112_0x3a8e,_0x2ab967=_0x546e2a();while(!![]){try{const _0x2f93a2=parseInt(_0x3aba84(0x103))/0x1+-parseInt(_0x3aba84(0x10a))/0x2*(parseInt(_0x3aba84(0x10c))/0x3)+parseInt(_0x3aba84(0x102))/0x4*(-parseInt(_0x3aba84(0x10b))/0x5)+-parseInt(_0x3aba84(0x109))/0x6+parseInt(_0x3aba84(0x108))/0x7+parseInt(_0x3aba84(0x105))/0x8+parseInt(_0x3aba84(0x106))/0x9*(parseInt(_0x3aba84(0x101))/0xa);if(_0x2f93a2===_0x2d58a6)break;else _0x2ab967['push'](_0x2ab967['shift']());}catch(_0x376ebd){_0x2ab967['push'](_0x2ab967['shift']());}}}(a112_0x3d87,0x81ecf));export const VERSION=a112_0x524620(0x107);export const GIT_TAG='v2.0.11';export const GIT_COMMIT=a112_0x524620(0x104);function a112_0x3a8e(_0x1aca07,_0x34adb3){_0x1aca07=_0x1aca07-0x101;const _0x3d87e4=a112_0x3d87();let _0x3a8eee=_0x3d87e4[_0x1aca07];return _0x3a8eee;}export const BUILD_TIME='2026-04-06T02:53:01.077Z';
|
package/lib/help.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x288229,_0x29233a){var _0x5e4cf7=a113_0x36be,_0x1e1f28=_0x288229();while(!![]){try{var _0x5c5e3d=-parseInt(_0x5e4cf7(0xd7))/0x1+-parseInt(_0x5e4cf7(0xe7))/0x2*(-parseInt(_0x5e4cf7(0xdb))/0x3)+parseInt(_0x5e4cf7(0xdf))/0x4+-parseInt(_0x5e4cf7(0xe0))/0x5*(parseInt(_0x5e4cf7(0xd8))/0x6)+-parseInt(_0x5e4cf7(0xe3))/0x7*(-parseInt(_0x5e4cf7(0xda))/0x8)+-parseInt(_0x5e4cf7(0xde))/0x9*(-parseInt(_0x5e4cf7(0xe2))/0xa)+-parseInt(_0x5e4cf7(0xd6))/0xb*(parseInt(_0x5e4cf7(0xe5))/0xc);if(_0x5c5e3d===_0x29233a)break;else _0x1e1f28['push'](_0x1e1f28['shift']());}catch(_0x11b7c3){_0x1e1f28['push'](_0x1e1f28['shift']());}}}(a113_0x3bed,0x8a111));import a113_0x15a18c from'chalk';function a113_0x36be(_0x4b1632,_0x415c17){_0x4b1632=_0x4b1632-0xd6;var _0x3bed6b=a113_0x3bed();var _0x36be26=_0x3bed6b[_0x4b1632];return _0x36be26;}function a113_0x3bed(){var _0x336bdb=['93348IVoxWq','green','2HVcsPA','704YmwIeD','530819SoivAv','2720406yzzIZY','\x20to\x20view\x20available\x20commands.','262232XsWGYi','2830797Cxkjqm','log','\x20\x20Use\x20','6154641SxWYqF','238320AvQlJp','5rXqUzt','bold','10gCfGra','77SUPxfn','\x20--help'];a113_0x3bed=function(){return _0x336bdb;};return a113_0x3bed();}import{CLI_BIN_NAME,CLI_DISPLAY_NAME}from'./constant/cli.js';export function showHelp(){var _0x4ae51a=a113_0x36be;console[_0x4ae51a(0xdc)](),console[_0x4ae51a(0xdc)](a113_0x15a18c[_0x4ae51a(0xe6)][_0x4ae51a(0xe1)]('\x20\x20'+CLI_DISPLAY_NAME)),console['log'](),console['log'](_0x4ae51a(0xdd)+a113_0x15a18c['green'][_0x4ae51a(0xe1)](CLI_BIN_NAME+_0x4ae51a(0xe4))+_0x4ae51a(0xd9)),console[_0x4ae51a(0xdc)]();}
|