@lovrabet/lovrabet-cli 2.2.4-beta.1 → 2.2.4-beta.2
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/cli.js +1 -1
- package/lib/commands/api-doc/index.js +1 -1
- package/lib/commands/app/cache.js +1 -1
- package/lib/commands/app/definitions.js +1 -1
- package/lib/commands/app/eligibility.js +1 -1
- package/lib/commands/app/mock-loader.js +1 -1
- package/lib/commands/app/remote-source.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/artifact/index.js +1 -1
- package/lib/commands/auth/device.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/auth/prompt.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/exec.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/common/config-policy.js +1 -1
- package/lib/commands/common/constraints.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/config/definitions.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/data/index.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/sdk-doc.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/init.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/notification/shared.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/permit/dataset-get.js +1 -1
- package/lib/commands/permit/dataset-set.js +1 -1
- package/lib/commands/permit/index.js +1 -1
- package/lib/commands/permit/page-get.js +1 -1
- package/lib/commands/permit/page-set.js +1 -1
- package/lib/commands/permit/role-menus-set.js +1 -1
- package/lib/commands/permit/role-menus.js +1 -1
- package/lib/commands/permit/shared.js +1 -1
- package/lib/commands/personal-bff/index.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/create.js +1 -1
- package/lib/commands/role/delete.js +1 -1
- package/lib/commands/role/detail.js +1 -1
- package/lib/commands/role/index.js +1 -1
- package/lib/commands/role/list.js +1 -1
- package/lib/commands/role/shared.js +1 -1
- package/lib/commands/role/update.js +1 -1
- package/lib/commands/role/user-add.js +1 -1
- package/lib/commands/role/user-remove.js +1 -1
- package/lib/commands/schedule/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/service/dynamic.js +1 -1
- package/lib/commands/service/function-name-adapter.js +1 -1
- package/lib/commands/service/index.js +1 -1
- package/lib/commands/service/registry.js +1 -1
- package/lib/commands/skill/commands/create.js +1 -1
- package/lib/commands/skill/commands/diagram.js +1 -1
- package/lib/commands/skill/commands/install.js +1 -1
- package/lib/commands/skill/commands/list.js +1 -1
- package/lib/commands/skill/commands/push.js +1 -1
- package/lib/commands/skill/commands/validate.js +1 -1
- package/lib/commands/skill/diagram.js +1 -1
- package/lib/commands/skill/flags.js +1 -1
- package/lib/commands/skill/index.js +1 -1
- package/lib/commands/skill/manifest-helpers.js +1 -1
- package/lib/commands/skill/push-execute.js +1 -1
- package/lib/commands/skill/push-flow-helpers.js +1 -1
- package/lib/commands/skill/push-retarget.js +1 -1
- package/lib/commands/skill/scopes.js +1 -1
- package/lib/commands/skill/summary.js +1 -1
- package/lib/commands/skill/templates.js +1 -1
- package/lib/commands/skill/validate.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/update.js +1 -1
- package/lib/commands/user-account/bind.js +1 -1
- package/lib/commands/user-account/index.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/app.js +1 -1
- package/lib/constant/auth-mode.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/distribution.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/product.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/constant/url.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/sdk-client.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/dryrun.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/preparse.js +1 -1
- package/lib/framework/rate-limit.js +1 -1
- package/lib/framework/raw-flags.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-confirmation.js +1 -1
- package/lib/framework/runner-error.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/service-order.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.d.ts +4 -4
- package/lib/generated/build-info.js +1 -1
- package/lib/help.js +1 -1
- package/lib/postinstall.js +1 -1
- package/lib/runtime/confirmation.js +1 -1
- package/lib/runtime/event.js +1 -1
- package/lib/runtime/index.js +1 -1
- package/lib/runtime/queue.js +1 -1
- package/lib/runtime/resolve.js +1 -1
- package/lib/skills/builtin-skill.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/skills/runtime-skill-sync/constants.js +1 -1
- package/lib/skills/runtime-skill-sync/fs-utils.js +1 -1
- package/lib/skills/runtime-skill-sync/hashing.js +1 -1
- package/lib/skills/runtime-skill-sync/install-target.js +1 -1
- package/lib/skills/runtime-skill-sync/links.js +1 -1
- package/lib/skills/runtime-skill-sync/list-local.js +1 -1
- package/lib/skills/runtime-skill-sync/local-files.js +1 -1
- package/lib/skills/runtime-skill-sync/materialize.js +1 -1
- package/lib/skills/runtime-skill-sync/metadata.js +1 -1
- package/lib/skills/runtime-skill-sync/paths.js +1 -1
- package/lib/skills/runtime-skill-sync/push.js +1 -1
- package/lib/skills/runtime-skill-sync/scopes.js +1 -1
- package/lib/skills/runtime-skill-sync/types.d.ts +1 -0
- package/lib/skills/runtime-skill-sync/zip-codec.js +1 -1
- package/lib/skills/runtime-skill-sync/zip-package.js +1 -1
- package/lib/skills/runtime-skill-sync.js +1 -1
- package/lib/skills/skill-presence.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/lossless-json.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
- package/skills/lovrabet/SKILL.md +2 -2
- package/skills/lovrabet/references/lovrabet-skill-authoring.md +5 -4
- package/skills/lovrabet.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a28_0xac715d=a28_0x4391;function a28_0x4391(_0x42c21e,_0x4d046e){_0x42c21e=_0x42c21e-0x9f;const _0x4fa94a=a28_0x4fa9();let _0x439169=_0x4fa94a[_0x42c21e];return _0x439169;}(function(_0x1e91f8,_0x505c40){const _0x4de0a6=a28_0x4391,_0x3de488=_0x1e91f8();while(!![]){try{const _0x376404=parseInt(_0x4de0a6(0xae))/0x1*(parseInt(_0x4de0a6(0xad))/0x2)+parseInt(_0x4de0a6(0x9f))/0x3*(-parseInt(_0x4de0a6(0xa2))/0x4)+-parseInt(_0x4de0a6(0xa8))/0x5+-parseInt(_0x4de0a6(0xb2))/0x6+parseInt(_0x4de0a6(0xa0))/0x7+parseInt(_0x4de0a6(0xb0))/0x8*(-parseInt(_0x4de0a6(0xa5))/0x9)+-parseInt(_0x4de0a6(0xb1))/0xa*(-parseInt(_0x4de0a6(0xa1))/0xb);if(_0x376404===_0x505c40)break;else _0x3de488['push'](_0x3de488['shift']());}catch(_0x241685){_0x3de488['push'](_0x3de488['shift']());}}}(a28_0x4fa9,0x6679c));import{getDatasetSdkUsageDoc}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';const DEFAULT_MARKDOWN=a28_0xac715d(0xac);function a28_0x4fa9(){const _0x49be3e=['code','2198405nhijoY','trim','sdk-doc','Dataset\x20code\x20(32\x20characters).\x20Numeric\x20dataset\x20IDs\x20are\x20not\x20accepted.','#\x20Dataset\x20SDK\x20Usage\x20Documentation\x0a\x0a暂无\x20SDK\x20使用文档','1260606FFVpON','1rfvKzx','str','192KthTYu','25820IgYXiK','2976468IgPasF','4764FIyDAZ','869176UaFNMO','3344fRspQC','132SpbIhy','appCode','read','49311ayWkSr','Get\x20SDK\x20usage\x20markdown\x20for\x20a\x20dataset\x20code'];a28_0x4fa9=function(){return _0x49be3e;};return a28_0x4fa9();}export function formatDatasetSdkMarkdown(_0x1fd852){const _0x54cbe4=a28_0xac715d,_0x2dbba7=typeof _0x1fd852==='string'?_0x1fd852[_0x54cbe4(0xa9)]():'';return _0x2dbba7||DEFAULT_MARKDOWN;}export const datasetSdkDoc={'service':'dataset','command':a28_0xac715d(0xaa),'description':a28_0xac715d(0xa6),'risk':a28_0xac715d(0xa4),'flags':[{...CODE_FLAG,'description':a28_0xac715d(0xab)}],async 'execute'(_0x44205e){const _0x1f891b=a28_0xac715d,_0x30a9f0=_0x44205e[_0x1f891b(0xaf)](_0x1f891b(0xa7)),_0x1629df=await getDatasetSdkUsageDoc(_0x30a9f0,_0x44205e[_0x1f891b(0xa3)]);return{'ok':!![],'data':{'code':_0x30a9f0,'appCode':_0x44205e[_0x1f891b(0xa3)],'markdown':formatDatasetSdkMarkdown(_0x1629df)}};}};
|
package/lib/commands/doctor.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const a29_0x40e4fe=a29_0x1928;(function(_0x27e3fa,_0x3fcb8c){const _0x20d207=a29_0x1928,_0x580d04=_0x27e3fa();while(!![]){try{const _0x3a16e0=-parseInt(_0x20d207(0x135))/0x1*(-parseInt(_0x20d207(0x136))/0x2)+-parseInt(_0x20d207(0xfc))/0x3*(-parseInt(_0x20d207(0x108))/0x4)+-parseInt(_0x20d207(0xdc))/0x5+-parseInt(_0x20d207(0x129))/0x6*(parseInt(_0x20d207(0x100))/0x7)+-parseInt(_0x20d207(0xe2))/0x8+-parseInt(_0x20d207(0x103))/0x9*(-parseInt(_0x20d207(0x10b))/0xa)+-parseInt(_0x20d207(0xe8))/0xb*(-parseInt(_0x20d207(0xea))/0xc);if(_0x3a16e0===_0x3fcb8c)break;else _0x580d04['push'](_0x580d04['shift']());}catch(_0x3243ec){_0x580d04['push'](_0x580d04['shift']());}}}(a29_0x2db2,0xc4436));import a29_0x3c4d3e from'chalk';import{CLI_BIN_NAME}from'../constant/cli.js';function a29_0x2db2(){const _0x3d4ce6=['\x20\x20Session\x20check:\x20\x20\x20','Diagnose\x20CLI\x20configuration\x20and\x20environment','length','padEnd','Project','\x20\x20accessKey:\x20\x20\x20\x20\x20\x20\x20','\x20\x20Skill\x20Version:\x20\x20\x20','\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20','yellow','ClientAk','locale','\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Config\x20Files','name','\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20','current','commandCount','✓\x20Valid\x20JSON','platform','state','\x20doctor','arch','✓\x20Loaded','currentApp','env','\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','pageSize','18fgzBLt','reason','bold','verbose','version','repeat','\x20\x20API\x20Endpoints','green','skillVersion','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20','(no\x20file)','7UhcfiZ','441380KbtHOl','\x20\x20Services:\x20\x20\x20\x20\x20\x20\x20\x20','appCode','\x20\x20Registry:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20─','⚠\x20Empty','(default)','(not\x20set)','(none)','message','\x20\x20Package\x20Version:\x20','\x20\x20State:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20userDomain:\x20\x20\x20\x20\x20\x20','\x20\x20Commands:\x20\x20\x20\x20\x20\x20\x20\x20','6999220Zbukwe','\x20\x20Auth','path','\x20\x20Merged\x20Config','\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','(missing)','4890448VZMatw','(unnamed)','\x20\x20Config\x20JSON','\x20\x20auth\x20(effective):\x20','\x20(legacy/compat\x20only)','\x20\x20runtimeDomain:\x20\x20\x20','572vZloME','source','39252MHtHpG','\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','serviceCode','accessKey','read','missing','\x20\x20Built-in\x20Skill','⚠\x20Empty\x20(treated\x20as\x20{})','\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20','✓\x20current','gray','status','repairCommand','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','red','doctor','format','(not\x20found)','865827TdUxKl','registryPath','\x20\x20Repair:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','Global','2538669ajHxPj','log','defaultApp','18rezFjM','packageVersion','✗\x20Invalid\x20JSON','services','\x20\x20Reason:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','20ejgkzY','riskLevel','\x20\x20Installed\x20Path:\x20\x20','3725390fVjDPa','installedPath'];a29_0x2db2=function(){return _0x3d4ce6;};return a29_0x2db2();}import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';function a29_0x1928(_0x570efa,_0x5959fd){_0x570efa=_0x570efa-0xd2;const _0x2db23c=a29_0x2db2();let _0x192829=_0x2db23c[_0x570efa];return _0x192829;}import{getCliVersion}from'../utils/version.js';import{getApiDomain,getRuntimeDomain,getUserDomain}from'../constant/domain.js';import{buildConfigFromFlags,initGlobalEnvironment,getProjectConfigPath,getGlobalConfigPath,inspectCliConfigJsonFile}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';import{isLegacyCompatConfigKey}from'../config/schema.js';import{inspectServiceRegistry}from'../commands/service/registry.js';import{inspectBuiltinSkill}from'../skills/builtin-skill.js';async function execute(_0xd48886){const _0x3e20ba=a29_0x1928,_0x1459f8=getCliVersion(),_0x319811=buildConfigFromFlags({});await initGlobalEnvironment(_0x319811),console[_0x3e20ba(0x101)](),console[_0x3e20ba(0x101)](a29_0x3c4d3e['bold'](CLI_BIN_NAME+_0x3e20ba(0x121))),console['log'](a29_0x3c4d3e[_0x3e20ba(0xf4)]('─'['repeat'](0x32))),console[_0x3e20ba(0x101)](_0x3e20ba(0x11b)+_0x1459f8),console[_0x3e20ba(0x101)]('\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+process[_0x3e20ba(0x12d)]),console['log']('\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20'+process[_0x3e20ba(0x11f)]+'\x20'+process[_0x3e20ba(0x122)]);const _0x1e1a91=inspectBuiltinSkill();console['log'](),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0x12b)](_0x3e20ba(0xf0))),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xd2)['repeat'](0x1e))),console[_0x3e20ba(0x101)](_0x3e20ba(0xd9)+(_0x1e1a91[_0x3e20ba(0x120)]===_0x3e20ba(0x11c)?a29_0x3c4d3e[_0x3e20ba(0x130)](_0x3e20ba(0xf3)):a29_0x3c4d3e[_0x3e20ba(0xf8)]('✗\x20'+_0x1e1a91[_0x3e20ba(0x120)]))),console[_0x3e20ba(0x101)](_0x3e20ba(0xd8)+_0x1e1a91[_0x3e20ba(0x104)]),console[_0x3e20ba(0x101)](_0x3e20ba(0x113)+(_0x1e1a91[_0x3e20ba(0x131)]||a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xe1)))),console[_0x3e20ba(0x101)](_0x3e20ba(0x10a)+(_0x1e1a91[_0x3e20ba(0x10c)]||a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xfb))));_0x1e1a91[_0x3e20ba(0x120)]!==_0x3e20ba(0x11c)&&console[_0x3e20ba(0x101)](_0x3e20ba(0xfe)+_0x1e1a91[_0x3e20ba(0xf6)]);_0x1e1a91[_0x3e20ba(0x12a)]&&console['log'](_0x3e20ba(0x107)+_0x1e1a91[_0x3e20ba(0x12a)]);console['log'](),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0x12b)](_0x3e20ba(0x119))),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xd2)[_0x3e20ba(0x12e)](0x1e)));const _0x107768=getGlobalConfigPath(),_0x429fd4=getProjectConfigPath();console[_0x3e20ba(0x101)](_0x3e20ba(0xeb)+(_0x107768||a29_0x3c4d3e[_0x3e20ba(0xf4)]('(not\x20found)'))),console[_0x3e20ba(0x101)](_0x3e20ba(0x114)+(_0x429fd4||a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xfb)))),console[_0x3e20ba(0x101)](),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0x12b)](_0x3e20ba(0xe4))),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xd2)[_0x3e20ba(0x12e)](0x1e)));const _0x46cdc1=(_0x314ade,_0x41bb99)=>{const _0x16d391=_0x3e20ba;if(!_0x41bb99){console['log']('\x20\x20'+_0x314ade[_0x16d391(0x110)](0x11)+'\x20'+a29_0x3c4d3e[_0x16d391(0xf4)](_0x16d391(0x134)));return;}const _0xf1dc4=inspectCliConfigJsonFile(_0x41bb99);if(_0xf1dc4[_0x16d391(0xf5)]==='ok')console[_0x16d391(0x101)]('\x20\x20'+_0x314ade[_0x16d391(0x110)](0x11)+'\x20'+a29_0x3c4d3e[_0x16d391(0x130)](_0x16d391(0x11e)));else{if(_0xf1dc4[_0x16d391(0xf5)]==='empty')console[_0x16d391(0x101)]('\x20\x20'+_0x314ade['padEnd'](0x11)+'\x20'+a29_0x3c4d3e[_0x16d391(0x115)](_0x16d391(0xf1)));else _0xf1dc4[_0x16d391(0xf5)]===_0x16d391(0xef)?console['log']('\x20\x20'+_0x314ade['padEnd'](0x11)+'\x20'+a29_0x3c4d3e[_0x16d391(0xf4)](_0x16d391(0xe1))):(console[_0x16d391(0x101)]('\x20\x20'+_0x314ade[_0x16d391(0x110)](0x11)+'\x20'+a29_0x3c4d3e[_0x16d391(0xf8)](_0x16d391(0x105))),console[_0x16d391(0x101)]('\x20\x20'+''[_0x16d391(0x110)](0x11)+'\x20'+a29_0x3c4d3e['red'](_0xf1dc4[_0x16d391(0xd7)])));}};_0x46cdc1(_0x3e20ba(0xff),_0x107768),_0x46cdc1(_0x3e20ba(0x111),_0x429fd4),console[_0x3e20ba(0x101)](),console['log'](a29_0x3c4d3e['bold'](_0x3e20ba(0xdf))),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xd2)[_0x3e20ba(0x12e)](0x1e))),console[_0x3e20ba(0x101)](_0x3e20ba(0x118)+(_0x319811[_0x3e20ba(0x138)]||a29_0x3c4d3e[_0x3e20ba(0xf8)](_0x3e20ba(0xd5)))),console[_0x3e20ba(0x101)](_0x3e20ba(0xe0)+_0x319811[_0x3e20ba(0x125)]);const _0x1d028a=isLegacyCompatConfigKey(_0x3e20ba(0x117))?a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x319811[_0x3e20ba(0x117)]+_0x3e20ba(0xe6)):_0x319811[_0x3e20ba(0x117)];console[_0x3e20ba(0x101)]('\x20\x20locale:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x1d028a),console[_0x3e20ba(0x101)](_0x3e20ba(0x127)+(_0x319811[_0x3e20ba(0x102)]||a29_0x3c4d3e[_0x3e20ba(0xf4)]('(none)'))),console[_0x3e20ba(0x101)]('\x20\x20currentApp:\x20\x20\x20\x20\x20\x20'+(_0x319811[_0x3e20ba(0x124)]||a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xd6)))),console[_0x3e20ba(0x101)]('\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x319811[_0x3e20ba(0xfa)]||a29_0x3c4d3e[_0x3e20ba(0xf4)]('(default:\x20'+DEFAULT_CONFIG_VALUES[_0x3e20ba(0xfa)]+')'))),console[_0x3e20ba(0x101)](_0x3e20ba(0x132)+(_0x319811[_0x3e20ba(0x128)]??a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xd4)))),console[_0x3e20ba(0x101)](_0x3e20ba(0xf2)+_0x319811[_0x3e20ba(0x109)]),console[_0x3e20ba(0x101)](_0x3e20ba(0x133)+_0x319811[_0x3e20ba(0x12c)]),console['log'](_0x3e20ba(0xe5)+AUTH_MODE['ClientAk']),console[_0x3e20ba(0x101)](_0x3e20ba(0x112)+(_0x319811[_0x3e20ba(0xed)]?a29_0x3c4d3e[_0x3e20ba(0x130)]('(set,\x20length='+_0x319811[_0x3e20ba(0xed)][_0x3e20ba(0x10f)]+')'):a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xd6)))),console[_0x3e20ba(0x101)](),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0x12b)](_0x3e20ba(0x12f))),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0xf4)]('\x20\x20─'[_0x3e20ba(0x12e)](0x1e))),console[_0x3e20ba(0x101)](_0x3e20ba(0xf7)+getApiDomain()),console[_0x3e20ba(0x101)](_0x3e20ba(0xda)+getUserDomain()),console[_0x3e20ba(0x101)](_0x3e20ba(0xe7)+getRuntimeDomain()),console[_0x3e20ba(0x101)](),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0x12b)]('\x20\x20Service\x20Tree')),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xd2)[_0x3e20ba(0x12e)](0x1e)));const _0x313515=inspectServiceRegistry();console[_0x3e20ba(0x101)](_0x3e20ba(0x139)+_0x313515[_0x3e20ba(0xfd)]),console['log'](_0x3e20ba(0x126)+formatServiceRegistryStatus(_0x313515)),console[_0x3e20ba(0x101)](_0x3e20ba(0x137)+_0x313515['serviceCount']),console[_0x3e20ba(0x101)](_0x3e20ba(0xdb)+_0x313515[_0x3e20ba(0x11d)]);for(const _0x4d7f45 of _0x313515[_0x3e20ba(0x106)]){console['log']('\x20\x20'+(_0x4d7f45[_0x3e20ba(0xec)]+':')[_0x3e20ba(0x110)](0x11)+'\x20'+(_0x4d7f45[_0x3e20ba(0x11a)]||a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xe3)))+'\x20('+_0x4d7f45[_0x3e20ba(0x11d)]+'\x20commands)'),console[_0x3e20ba(0x101)]('\x20\x20'+''[_0x3e20ba(0x110)](0x11)+'\x20Imported\x20from:\x20'+_0x4d7f45[_0x3e20ba(0xe9)][_0x3e20ba(0xde)]);}return console[_0x3e20ba(0x101)](),console[_0x3e20ba(0x101)](a29_0x3c4d3e['bold'](_0x3e20ba(0xdd))),console[_0x3e20ba(0x101)](a29_0x3c4d3e[_0x3e20ba(0xf4)](_0x3e20ba(0xd2)[_0x3e20ba(0x12e)](0x1e))),console[_0x3e20ba(0x101)]('\x20\x20Mode:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+a29_0x3c4d3e[_0x3e20ba(0x130)](AUTH_MODE[_0x3e20ba(0x116)]+'\x20(accessKey)')),console[_0x3e20ba(0x101)](_0x3e20ba(0x10d)+a29_0x3c4d3e[_0x3e20ba(0xf4)]('(removed\x20—\x20cookie\x20auth\x20disabled)')),console['log'](),{'ok':!![]};}function formatServiceRegistryStatus(_0x28a974){const _0x151a71=a29_0x1928;if(_0x28a974['status']==='ok')return a29_0x3c4d3e[_0x151a71(0x130)](_0x151a71(0x123));if(_0x28a974[_0x151a71(0xf5)]===_0x151a71(0xef))return a29_0x3c4d3e[_0x151a71(0xf4)](_0x151a71(0xfb));if(_0x28a974[_0x151a71(0xf5)]==='empty')return a29_0x3c4d3e['yellow'](_0x151a71(0xd3));return a29_0x3c4d3e[_0x151a71(0xf8)]('✗\x20Invalid'+(_0x28a974[_0x151a71(0xd7)]?':\x20'+_0x28a974[_0x151a71(0xd7)]:''));}export const doctorDefinition={'service':a29_0x40e4fe(0xf9),'command':'check','description':a29_0x40e4fe(0x10e),'risk':a29_0x40e4fe(0xee),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
|
|
1
|
+
const a29_0x72f595=a29_0x389f;(function(_0xccf3f2,_0x44d336){const _0x244ebb=a29_0x389f,_0x5ea5ad=_0xccf3f2();while(!![]){try{const _0x5a3814=-parseInt(_0x244ebb(0x134))/0x1+-parseInt(_0x244ebb(0x156))/0x2+-parseInt(_0x244ebb(0x162))/0x3+-parseInt(_0x244ebb(0x196))/0x4*(parseInt(_0x244ebb(0x175))/0x5)+-parseInt(_0x244ebb(0x158))/0x6+parseInt(_0x244ebb(0x165))/0x7+-parseInt(_0x244ebb(0x148))/0x8*(-parseInt(_0x244ebb(0x163))/0x9);if(_0x5a3814===_0x44d336)break;else _0x5ea5ad['push'](_0x5ea5ad['shift']());}catch(_0x30e0b2){_0x5ea5ad['push'](_0x5ea5ad['shift']());}}}(a29_0x2451,0x7888f));import a29_0x330871 from'chalk';import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{getCliVersion}from'../utils/version.js';import{getApiDomain,getRuntimeDomain,getUserDomain}from'../constant/domain.js';function a29_0x2451(){const _0x3ea21c=['(set,\x20length=','appCode','\x20\x20Commands:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20userDomain:\x20\x20\x20\x20\x20\x20','✓\x20current','\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20','format','\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','env','Diagnose\x20CLI\x20configuration\x20and\x20environment','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','(none)','ClientAk','doctor','reason','name','currentApp','19644XDmBVA','\x20\x20accessKey:\x20\x20\x20\x20\x20\x20\x20','\x20\x20Service\x20Tree','packageVersion','\x20\x20Reason:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','385398dDjMfC','(default)','services','(not\x20found)','read','serviceCode','green','(unnamed)','✗\x20Invalid\x20JSON','registryPath','\x20\x20Installed\x20Path:\x20\x20','\x20\x20Package\x20Version:\x20','locale','\x20\x20Registry:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20','commandCount','check','verbose','yellow','(no\x20file)','27423464hIyiad','gray','\x20\x20Session\x20check:\x20\x20\x20','(missing)','length','status','\x20\x20Services:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20State:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','arch','\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','padEnd','pageSize','\x20\x20locale:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20','1203452AWkLcu','state','5695500zXMpco','message','bold','Project','\x20\x20Merged\x20Config','\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','accessKey','\x20\x20Config\x20Files','⚠\x20Empty\x20(treated\x20as\x20{})','\x20\x20Config\x20JSON','1124811NdNgtf','9CCXaDs','defaultApp','1380582Jrwang','riskLevel','\x20\x20Repair:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','red','empty','repeat','missing','\x20(legacy/compat\x20only)','\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','current','version','\x20\x20─','\x20\x20currentApp:\x20\x20\x20\x20\x20\x20','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Built-in\x20Skill','835BDUQjx','installedPath','(not\x20set)','Global','\x20\x20API\x20Endpoints','(default:\x20','log','platform','\x20Imported\x20from:\x20','skillVersion','\x20\x20runtimeDomain:\x20\x20\x20','(removed\x20—\x20cookie\x20auth\x20disabled)','serviceCount','✗\x20Invalid','\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20'];a29_0x2451=function(){return _0x3ea21c;};return a29_0x2451();}import{buildConfigFromFlags,initGlobalEnvironment,getProjectConfigPath,getGlobalConfigPath,inspectCliConfigJsonFile}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';import{isLegacyCompatConfigKey}from'../config/schema.js';import{inspectServiceRegistry}from'../commands/service/registry.js';function a29_0x389f(_0x98d953,_0x25bc4a){_0x98d953=_0x98d953-0x133;const _0x2451e0=a29_0x2451();let _0x389fa1=_0x2451e0[_0x98d953];return _0x389fa1;}import{inspectBuiltinSkill}from'../skills/builtin-skill.js';async function execute(_0x485650){const _0x588ca0=a29_0x389f,_0x3cd1b0=getCliVersion(),_0x35b040=buildConfigFromFlags({});await initGlobalEnvironment(_0x35b040),console[_0x588ca0(0x17b)](),console[_0x588ca0(0x17b)](a29_0x330871['bold'](CLI_BIN_NAME+'\x20doctor')),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x149)]('─'[_0x588ca0(0x16a)](0x32))),console[_0x588ca0(0x17b)]('\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20'+_0x3cd1b0),console[_0x588ca0(0x17b)](_0x588ca0(0x16d)+process[_0x588ca0(0x16f)]),console['log'](_0x588ca0(0x18a)+process[_0x588ca0(0x17c)]+'\x20'+process[_0x588ca0(0x150)]);const _0x43eafc=inspectBuiltinSkill();console[_0x588ca0(0x17b)](),console[_0x588ca0(0x17b)](a29_0x330871['bold'](_0x588ca0(0x174))),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x170)[_0x588ca0(0x16a)](0x1e))),console['log'](_0x588ca0(0x14f)+(_0x43eafc[_0x588ca0(0x157)]===_0x588ca0(0x16e)?a29_0x330871[_0x588ca0(0x13a)](_0x588ca0(0x188)):a29_0x330871[_0x588ca0(0x168)]('✗\x20'+_0x43eafc[_0x588ca0(0x157)]))),console['log'](_0x588ca0(0x13f)+_0x43eafc[_0x588ca0(0x199)]),console['log']('\x20\x20Skill\x20Version:\x20\x20\x20'+(_0x43eafc[_0x588ca0(0x17e)]||a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x14b)))),console[_0x588ca0(0x17b)](_0x588ca0(0x13e)+(_0x43eafc[_0x588ca0(0x176)]||a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x137))));_0x43eafc['state']!==_0x588ca0(0x16e)&&console[_0x588ca0(0x17b)](_0x588ca0(0x167)+_0x43eafc['repairCommand']);_0x43eafc[_0x588ca0(0x193)]&&console['log'](_0x588ca0(0x133)+_0x43eafc[_0x588ca0(0x193)]);console[_0x588ca0(0x17b)](),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x15a)](_0x588ca0(0x15f))),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x170)[_0x588ca0(0x16a)](0x1e)));const _0x1f409a=getGlobalConfigPath(),_0x1cda5f=getProjectConfigPath();console[_0x588ca0(0x17b)]('\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x1f409a||a29_0x330871['gray'](_0x588ca0(0x137)))),console['log'](_0x588ca0(0x183)+(_0x1cda5f||a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x137)))),console['log'](),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x15a)](_0x588ca0(0x161))),console['log'](a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x170)[_0x588ca0(0x16a)](0x1e)));const _0x26b40c=(_0x4e8d3a,_0x2f8bc2)=>{const _0x1d971d=_0x588ca0;if(!_0x2f8bc2){console[_0x1d971d(0x17b)]('\x20\x20'+_0x4e8d3a[_0x1d971d(0x152)](0x11)+'\x20'+a29_0x330871[_0x1d971d(0x149)](_0x1d971d(0x147)));return;}const _0x4eb899=inspectCliConfigJsonFile(_0x2f8bc2);if(_0x4eb899[_0x1d971d(0x14d)]==='ok')console[_0x1d971d(0x17b)]('\x20\x20'+_0x4e8d3a[_0x1d971d(0x152)](0x11)+'\x20'+a29_0x330871[_0x1d971d(0x13a)]('✓\x20Valid\x20JSON'));else{if(_0x4eb899[_0x1d971d(0x14d)]==='empty')console[_0x1d971d(0x17b)]('\x20\x20'+_0x4e8d3a[_0x1d971d(0x152)](0x11)+'\x20'+a29_0x330871['yellow'](_0x1d971d(0x160)));else _0x4eb899['status']===_0x1d971d(0x16b)?console[_0x1d971d(0x17b)]('\x20\x20'+_0x4e8d3a[_0x1d971d(0x152)](0x11)+'\x20'+a29_0x330871[_0x1d971d(0x149)](_0x1d971d(0x14b))):(console[_0x1d971d(0x17b)]('\x20\x20'+_0x4e8d3a[_0x1d971d(0x152)](0x11)+'\x20'+a29_0x330871['red'](_0x1d971d(0x13c))),console['log']('\x20\x20'+''[_0x1d971d(0x152)](0x11)+'\x20'+a29_0x330871[_0x1d971d(0x168)](_0x4eb899[_0x1d971d(0x159)])));}};_0x26b40c(_0x588ca0(0x178),_0x1f409a),_0x26b40c(_0x588ca0(0x15b),_0x1cda5f),console[_0x588ca0(0x17b)](),console[_0x588ca0(0x17b)](a29_0x330871['bold'](_0x588ca0(0x15c))),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x170)[_0x588ca0(0x16a)](0x1e))),console[_0x588ca0(0x17b)](_0x588ca0(0x142)+(_0x35b040[_0x588ca0(0x185)]||a29_0x330871[_0x588ca0(0x168)](_0x588ca0(0x177)))),console[_0x588ca0(0x17b)](_0x588ca0(0x151)+_0x35b040[_0x588ca0(0x18d)]);const _0x548ff6=isLegacyCompatConfigKey('locale')?a29_0x330871[_0x588ca0(0x149)](_0x35b040[_0x588ca0(0x140)]+_0x588ca0(0x16c)):_0x35b040[_0x588ca0(0x140)];console[_0x588ca0(0x17b)](_0x588ca0(0x154)+_0x548ff6),console[_0x588ca0(0x17b)](_0x588ca0(0x18f)+(_0x35b040[_0x588ca0(0x164)]||a29_0x330871['gray']('(none)'))),console[_0x588ca0(0x17b)](_0x588ca0(0x171)+(_0x35b040[_0x588ca0(0x195)]||a29_0x330871['gray'](_0x588ca0(0x190)))),console[_0x588ca0(0x17b)](_0x588ca0(0x15d)+(_0x35b040[_0x588ca0(0x18b)]||a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x17a)+DEFAULT_CONFIG_VALUES[_0x588ca0(0x18b)]+')'))),console[_0x588ca0(0x17b)](_0x588ca0(0x173)+(_0x35b040[_0x588ca0(0x153)]??a29_0x330871['gray'](_0x588ca0(0x135)))),console['log'](_0x588ca0(0x155)+_0x35b040[_0x588ca0(0x166)]),console[_0x588ca0(0x17b)](_0x588ca0(0x189)+_0x35b040[_0x588ca0(0x145)]),console[_0x588ca0(0x17b)]('\x20\x20auth\x20(effective):\x20'+AUTH_MODE[_0x588ca0(0x191)]),console[_0x588ca0(0x17b)](_0x588ca0(0x197)+(_0x35b040[_0x588ca0(0x15e)]?a29_0x330871[_0x588ca0(0x13a)](_0x588ca0(0x184)+_0x35b040['accessKey'][_0x588ca0(0x14c)]+')'):a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x190)))),console[_0x588ca0(0x17b)](),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x15a)](_0x588ca0(0x179))),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x170)[_0x588ca0(0x16a)](0x1e))),console[_0x588ca0(0x17b)](_0x588ca0(0x172)+getApiDomain()),console[_0x588ca0(0x17b)](_0x588ca0(0x187)+getUserDomain()),console['log'](_0x588ca0(0x17f)+getRuntimeDomain()),console['log'](),console['log'](a29_0x330871[_0x588ca0(0x15a)](_0x588ca0(0x198))),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x170)[_0x588ca0(0x16a)](0x1e)));const _0xdb439f=inspectServiceRegistry();console[_0x588ca0(0x17b)](_0x588ca0(0x141)+_0xdb439f[_0x588ca0(0x13d)]),console[_0x588ca0(0x17b)](_0x588ca0(0x18c)+formatServiceRegistryStatus(_0xdb439f)),console['log'](_0x588ca0(0x14e)+_0xdb439f[_0x588ca0(0x181)]),console[_0x588ca0(0x17b)](_0x588ca0(0x186)+_0xdb439f['commandCount']);for(const _0x40e95d of _0xdb439f[_0x588ca0(0x136)]){console[_0x588ca0(0x17b)]('\x20\x20'+(_0x40e95d[_0x588ca0(0x139)]+':')[_0x588ca0(0x152)](0x11)+'\x20'+(_0x40e95d[_0x588ca0(0x194)]||a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x13b)))+'\x20('+_0x40e95d[_0x588ca0(0x143)]+'\x20commands)'),console[_0x588ca0(0x17b)]('\x20\x20'+''[_0x588ca0(0x152)](0x11)+_0x588ca0(0x17d)+_0x40e95d['source']['path']);}return console[_0x588ca0(0x17b)](),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x15a)]('\x20\x20Auth')),console[_0x588ca0(0x17b)](a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x170)[_0x588ca0(0x16a)](0x1e))),console[_0x588ca0(0x17b)]('\x20\x20Mode:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+a29_0x330871[_0x588ca0(0x13a)](AUTH_MODE[_0x588ca0(0x191)]+'\x20(accessKey)')),console[_0x588ca0(0x17b)](_0x588ca0(0x14a)+a29_0x330871[_0x588ca0(0x149)](_0x588ca0(0x180))),console[_0x588ca0(0x17b)](),{'ok':!![]};}function formatServiceRegistryStatus(_0x1ed71c){const _0x5dde78=a29_0x389f;if(_0x1ed71c[_0x5dde78(0x14d)]==='ok')return a29_0x330871['green']('✓\x20Loaded');if(_0x1ed71c['status']===_0x5dde78(0x16b))return a29_0x330871[_0x5dde78(0x149)]('(not\x20found)');if(_0x1ed71c[_0x5dde78(0x14d)]===_0x5dde78(0x169))return a29_0x330871[_0x5dde78(0x146)]('⚠\x20Empty');return a29_0x330871[_0x5dde78(0x168)](_0x5dde78(0x182)+(_0x1ed71c[_0x5dde78(0x159)]?':\x20'+_0x1ed71c[_0x5dde78(0x159)]:''));}export const doctorDefinition={'service':a29_0x72f595(0x192),'command':a29_0x72f595(0x144),'description':a29_0x72f595(0x18e),'risk':a29_0x72f595(0x138),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a30_0x3745cb=a30_0x36dd;(function(_0x3e2ee7,_0x5052b8){const _0x146744=a30_0x36dd,_0x311dfb=_0x3e2ee7();while(!![]){try{const _0xddf607=parseInt(_0x146744(0x130))/0x1+parseInt(_0x146744(0x146))/0x2+parseInt(_0x146744(0x142))/0x3*(parseInt(_0x146744(0x139))/0x4)+parseInt(_0x146744(0x128))/0x5*(parseInt(_0x146744(0x143))/0x6)+parseInt(_0x146744(0x12b))/0x7*(parseInt(_0x146744(0x13e))/0x8)+-parseInt(_0x146744(0x134))/0x9*(-parseInt(_0x146744(0x133))/0xa)+-parseInt(_0x146744(0x127))/0xb;if(_0xddf607===_0x5052b8)break;else _0x311dfb['push'](_0x311dfb['shift']());}catch(_0x10afa7){_0x311dfb['push'](_0x311dfb['shift']());}}}(a30_0x2c1e,0x59f7f));import{requireRuntimeUploadFile}from'../../commands/common/local-file.js';import{queryRuntimeFileUrl,uploadRuntimeFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const FILE_FLAG={'name':a30_0x3745cb(0x140),'type':a30_0x3745cb(0x145),'required':!![],'description':a30_0x3745cb(0x12d)},FILEPATH_FLAG={'name':a30_0x3745cb(0x12e),'type':a30_0x3745cb(0x145),'required':!![],'description':a30_0x3745cb(0x12a)},DOWNLOAD_FLAG={'name':'download','type':a30_0x3745cb(0x132),'description':a30_0x3745cb(0x13d)},LONG_TERM_FLAG={'name':a30_0x3745cb(0x120),'type':'boolean','description':a30_0x3745cb(0x135)};function a30_0x36dd(_0x1d6b1d,_0x3bfeac){_0x1d6b1d=_0x1d6b1d-0x11f;const _0x2c1ef3=a30_0x2c1e();let _0x36dd44=_0x2c1ef3[_0x1d6b1d];return _0x36dd44;}function a30_0x2c1e(){const _0x107de7=['trim','long-term','path','Preview:\x20upload\x20','read','download','Uploaded\x20file.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','validation','16501837aiKUAD','15tYFtQy','appCode','Runtime\x20filePath\x20returned\x20by\x20file\x20upload;\x20store\x20it\x20in\x20file\x20fields\x20and\x20durable\x20data','1468782gfEeod','upload','Path\x20to\x20the\x20local\x20file\x20to\x20upload','filepath','description','209057drWSGq','bool','boolean','49890aHdtBQ','747wXKQzc','Return\x20a\x203-year\x20URL\x20for\x20URL-only\x20content\x20embedding\x20such\x20as\x20rich\x20text,\x20Markdown,\x20or\x20HTML','Upload\x20a\x20local\x20file\x20and\x20return\x20filePath\x20for\x20durable\x20references','POST','\x20to\x20runtime\x20app\x20','1109944JVGBjr','body','Uploaded\x20file:\x20','.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','Return\x20a\x20short-lived\x20download\x20URL\x20instead\x20of\x20a\x20short-lived\x20preview\x20URL','8qkuqgd','str','file','query-url','3TBrekL','595194PpHoHH','/client/uploadFile','string','921250KJjjSc','build'];a30_0x2c1e=function(){return _0x107de7;};return a30_0x2c1e();}function requireFilePath(_0x21f0e7){const _0x528e00=a30_0x3745cb,_0x589181=_0x21f0e7[_0x528e00(0x11f)]();if(!_0x589181)throw CliErrors[_0x528e00(0x126)]('filePath\x20is\x20required.');return _0x589181;}const fileUpload={'service':a30_0x3745cb(0x140),'command':a30_0x3745cb(0x12c),'description':a30_0x3745cb(0x136),'risk':'read','flags':[FILE_FLAG],async 'dryRun'(_0x29c2be){const _0x2d598b=a30_0x3745cb,_0x565536=requireRuntimeUploadFile(_0x29c2be['str'](_0x2d598b(0x140)),'File');return dryRun(_0x2d598b(0x137),_0x2d598b(0x144))[_0x2d598b(0x13a)]({'appCode':_0x29c2be[_0x2d598b(0x129)],'multipart':{'file':_0x565536}})[_0x2d598b(0x12f)](_0x2d598b(0x122)+_0x565536[_0x2d598b(0x121)]+_0x2d598b(0x138)+_0x29c2be[_0x2d598b(0x129)])[_0x2d598b(0x147)]();},async 'execute'(_0x50c84d){const _0x3dbb6a=a30_0x3745cb,_0x3282cf=requireRuntimeUploadFile(_0x50c84d[_0x3dbb6a(0x13f)]('file'),'File'),_0x2872e4=await uploadRuntimeFile(_0x50c84d[_0x3dbb6a(0x129)],_0x3282cf[_0x3dbb6a(0x121)]);return{'ok':!![],'data':_0x2872e4,'message':_0x2872e4['filePath']?_0x3dbb6a(0x13b)+_0x2872e4['filePath']+_0x3dbb6a(0x13c):_0x3dbb6a(0x125)};}},fileQueryUrl={'service':a30_0x3745cb(0x140),'command':a30_0x3745cb(0x141),'description':'Query\x20a\x20short-lived\x20URL\x20for\x20preview,\x20download,\x20OCR,\x20or\x20immediate\x20access','risk':a30_0x3745cb(0x123),'flags':[FILEPATH_FLAG,DOWNLOAD_FLAG,LONG_TERM_FLAG],async 'execute'(_0x15f882){const _0xbf7dd3=a30_0x3745cb,_0x4e48a8=requireFilePath(_0x15f882['str']('filepath')),_0x49add9=await queryRuntimeFileUrl(_0x4e48a8,{'download':_0x15f882['bool'](_0xbf7dd3(0x124)),'longTerm':_0x15f882[_0xbf7dd3(0x131)]('long-term')});return{'ok':!![],'data':_0x49add9};}};export const fileDefinitions=[fileUpload,fileQueryUrl];
|
package/lib/commands/init.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a31_0x31f66d=a31_0x58e9;function a31_0x1981(){const _0x2fd569=['entries','boolean','object','validation','Legacy\x20/\x20multi-app\x20.rabetbase.json\x20is\x20no\x20longer\x20supported\x20for\x20import.','riskLevel','cwd','15609570ZTFICR','apps','451752XpFwoK','string','4170700yQOMgu','Import\x20from\x20a\x20.rabetbase.json\x20file\x20path','\x20\x20config:\x20\x20','Imported\x20from\x20','yes','9ixsgrU','parse','Override\x20imported\x20default\x20env','Invalid\x20env\x20\x22','defaultApp','Run\x20`rabetbase\x20project\x20upgrade`\x20first,\x20then\x20retry\x20`lovrabet\x20app\x20import`.','project','global','3282936QGqAFw','Skip\x20confirmation\x20when\x20overwriting','4CdjjzT','\x20\x20appcode:\x20','message','28CTEHxp','Source\x20file\x20not\x20found:\x20','341594XGEAmi','9787488HAmzbo','appcode','file','4561216htvFdD','newConfigFileName','Override\x20imported\x20default\x20appcode','7mFqDyp',')\x20instead\x20of\x20project','\x20\x20default:\x20','Source\x20file\x20does\x20not\x20contain\x20an\x20importable\x20appcode.','log','env'];a31_0x1981=function(){return _0x2fd569;};return a31_0x1981();}(function(_0x1e4771,_0x5c23f5){const _0x5c09f1=a31_0x58e9,_0x1e6ee9=_0x1e4771();while(!![]){try{const _0x388c52=-parseInt(_0x5c09f1(0x1e0))/0x1*(parseInt(_0x5c09f1(0x1e5))/0x2)+-parseInt(_0x5c09f1(0x1fb))/0x3*(parseInt(_0x5c09f1(0x1e3))/0x4)+parseInt(_0x5c09f1(0x1fd))/0x5+-parseInt(_0x5c09f1(0x20a))/0x6+-parseInt(_0x5c09f1(0x1ec))/0x7*(-parseInt(_0x5c09f1(0x1e6))/0x8)+-parseInt(_0x5c09f1(0x202))/0x9*(-parseInt(_0x5c09f1(0x1f9))/0xa)+-parseInt(_0x5c09f1(0x1e9))/0xb;if(_0x388c52===_0x5c23f5)break;else _0x1e6ee9['push'](_0x1e6ee9['shift']());}catch(_0xe0c977){_0x1e6ee9['push'](_0x1e6ee9['shift']());}}}(a31_0x1981,0xe0795));import{existsSync,readFileSync}from'node:fs';import{resolve,isAbsolute}from'node:path';import{CliErrors}from'../errors.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{RUNTIME_ENV_VALUES}from'../constant/env.js';import{IMPORTABLE_RUNTIME_CONFIG_KEYS}from'../config/schema.js';import{resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../context.js';import{PRODUCT_CONFIG}from'../constant/product.js';export const appImportFlagDefs=[{'name':a31_0x31f66d(0x1e8),'type':a31_0x31f66d(0x1fc),'description':a31_0x31f66d(0x1fe),'required':!![]},{'name':'appcode','type':a31_0x31f66d(0x1fc),'description':a31_0x31f66d(0x1eb)},{'name':'env','type':'string','description':a31_0x31f66d(0x204),'enum':[...RUNTIME_ENV_VALUES]},{'name':a31_0x31f66d(0x209),'type':a31_0x31f66d(0x1f3),'description':'Write\x20to\x20global\x20(~/'+PRODUCT_CONFIG[a31_0x31f66d(0x1ea)]+a31_0x31f66d(0x1ed),'default':![]},{'name':a31_0x31f66d(0x201),'type':'boolean','description':a31_0x31f66d(0x1df),'default':![]}];function a31_0x58e9(_0x3cb5bc,_0x2fd7bf){_0x3cb5bc=_0x3cb5bc-0x1df;const _0x19811c=a31_0x1981();let _0x58e942=_0x19811c[_0x3cb5bc];return _0x58e942;}export async function runAppImport(_0x106b51){const _0x4856a9=a31_0x31f66d,_0x203597=_0x106b51['global']?_0x4856a9(0x209):_0x4856a9(0x208),_0x59a13b=resolveWriteConfigPath(_0x203597);await runFromImport(_0x106b51,_0x59a13b);}async function runFromImport(_0x1a76ab,_0x88949d){const _0x716872=a31_0x31f66d,_0x234945=resolveFilePath(_0x1a76ab[_0x716872(0x1e8)]);if(!existsSync(_0x234945))throw CliErrors[_0x716872(0x1f5)](_0x716872(0x1e4)+_0x234945);const _0xcd14c5=readSourceFile(_0x234945),_0x53eef4=convertToRuntimeConfig(_0xcd14c5);_0x1a76ab['appcode']&&(_0x53eef4[_0x716872(0x1e7)]=String(_0x1a76ab[_0x716872(0x1e7)]));_0x1a76ab[_0x716872(0x1f1)]&&(_0x53eef4[_0x716872(0x1f1)]=resolveImportEnv(_0x1a76ab));if(!_0x53eef4[_0x716872(0x1e7)])throw CliErrors[_0x716872(0x1f5)](_0x716872(0x1ef),'Provide\x20--appcode\x20<code>\x20or\x20use\x20an\x20upgraded\x20.rabetbase.json\x20with\x20top-level\x20appcode.\x20Legacy\x20files\x20must\x20be\x20upgraded\x20first\x20with\x20`rabetbase\x20project\x20upgrade`.');await writeImportConfig(_0x88949d,_0x53eef4,_0x1a76ab),console[_0x716872(0x1f0)](_0x716872(0x200)+_0x234945),console[_0x716872(0x1f0)](_0x716872(0x1ff)+_0x88949d),console[_0x716872(0x1f0)](_0x716872(0x1e1)+_0x53eef4['appcode']);if(_0x53eef4[_0x716872(0x206)])console['log'](_0x716872(0x1ee)+_0x53eef4[_0x716872(0x206)]);}function convertToRuntimeConfig(_0x5567d6){const _0x2e2e53=a31_0x31f66d;if(_0x5567d6[_0x2e2e53(0x1fa)]&&typeof _0x5567d6['apps']===_0x2e2e53(0x1f4))throw CliErrors[_0x2e2e53(0x1f5)](_0x2e2e53(0x1f6),_0x2e2e53(0x207));const _0x5087f9={};for(const _0x59698d of IMPORTABLE_RUNTIME_CONFIG_KEYS){_0x5567d6[_0x59698d]!==undefined&&(_0x5087f9[_0x59698d]=_0x5567d6[_0x59698d]);}return!_0x5087f9[_0x2e2e53(0x1f7)]&&(_0x5087f9['riskLevel']=DEFAULT_CONFIG_VALUES[_0x2e2e53(0x1f7)]),_0x5087f9;}async function writeImportConfig(_0x43acfb,_0x2fb8a6,_0x1bdc35){const _0x507d44=a31_0x31f66d;let _0x1a5ebd={};existsSync(_0x43acfb)&&!_0x1bdc35[_0x507d44(0x201)]&&(_0x1a5ebd=readConfigFile(_0x43acfb));for(const [_0x2c4548,_0x418322]of Object[_0x507d44(0x1f2)](_0x2fb8a6)){_0x418322!==undefined&&(_0x1a5ebd[_0x2c4548]=_0x418322);}if(_0x1a5ebd['app'])delete _0x1a5ebd['app'];writeConfigFile(_0x43acfb,_0x1a5ebd);}function resolveFilePath(_0x1f2574){const _0x1418c7=a31_0x31f66d;return isAbsolute(_0x1f2574)?_0x1f2574:resolve(process[_0x1418c7(0x1f8)](),_0x1f2574);}function readSourceFile(_0x37c693){const _0x598ad9=a31_0x31f66d;try{const _0x589e6d=readFileSync(_0x37c693,{'encoding':'utf8'});return JSON[_0x598ad9(0x203)](_0x589e6d);}catch(_0x1e79fd){throw CliErrors[_0x598ad9(0x1f5)]('Failed\x20to\x20parse\x20source\x20file:\x20'+_0x1e79fd[_0x598ad9(0x1e2)]);}}function resolveImportEnv(_0x2556b8){const _0xf1ff51=a31_0x31f66d,_0x2b085a=_0x2556b8[_0xf1ff51(0x1f1)];if(_0x2b085a===undefined||_0x2b085a==='')return DEFAULT_CONFIG_VALUES['env'];if(!RUNTIME_ENV_VALUES['includes'](_0x2b085a))throw CliErrors['validation'](_0xf1ff51(0x205)+_0x2b085a+'\x22.\x20Allowed:\x20'+RUNTIME_ENV_VALUES['join'](',\x20'));return _0x2b085a;}
|
package/lib/commands/kb/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a32_0x329f56=a32_0x344a;(function(_0x543bdc,_0x37f109){const _0x3db715=a32_0x344a,_0x5e23c2=_0x543bdc();while(!![]){try{const _0x1155df=-parseInt(_0x3db715(0x106))/0x1+-parseInt(_0x3db715(0xcf))/0x2*(parseInt(_0x3db715(0x103))/0x3)+-parseInt(_0x3db715(0xf3))/0x4*(parseInt(_0x3db715(0xdc))/0x5)+-parseInt(_0x3db715(0xd2))/0x6*(-parseInt(_0x3db715(0xf1))/0x7)+-parseInt(_0x3db715(0xd7))/0x8*(parseInt(_0x3db715(0xd1))/0x9)+-parseInt(_0x3db715(0xfb))/0xa+-parseInt(_0x3db715(0xee))/0xb*(-parseInt(_0x3db715(0xe7))/0xc);if(_0x1155df===_0x37f109)break;else _0x5e23c2['push'](_0x5e23c2['shift']());}catch(_0x20a57c){_0x5e23c2['push'](_0x5e23c2['shift']());}}}(a32_0xe4f9,0x2119f));import{existsSync,readFileSync,statSync}from'node:fs';function a32_0x344a(_0x344736,_0x47fd9e){_0x344736=_0x344736-0xc9;const _0xe4f9a5=a32_0xe4f9();let _0x344a5c=_0xe4f9a5[_0x344736];return _0x344a5c;}import{createPersonalKnowledgeBaseItem,getPersonalKnowledgeBaseItem,listPersonalKnowledgeBaseItems,searchKnowledgeBase,updatePersonalKnowledgeBaseItem}from'../../core/api-client.js';import{ID_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';function a32_0xe4f9(){const _0xdeaa53=['139005oCBtKA','599754kOLLQi','list','body','根据本地文件创建个人知识库条目','POST','8UYFlNM','utf8','str','content','把本地文件内容保存为个人知识库条目,并进入后续检索同步流程。','160YHgTbO','create','Search\x20query\x20is\x20required.','version','description','根据本地文件更新个人知识库条目','/client/knowledge-base/personal/','num','map','verbose','Personal\x20knowledge-base\x20entry\x20ID','60fieulp','read','string','ragStatus','build','appCode','Show\x20one\x20personal\x20knowledge-base\x20entry\x20by\x20id','873796HUqsAI','/client/knowledge-base/personal/create','updateTime','14vqlBYV','detail','31336wOJrrB','file','query','update','title','write','Updated\x20KB\x20entry\x20','--topk\x20must\x20be\x20a\x20positive\x20number.','1685060aphbEW','Personal\x20knowledge-base\x20entry\x20title','search','isFile','bool','topk','metadata','用本地文件内容替换个人知识库条目正文,并触发新的检索同步。','5703wqguGm','trim','scope','24975iAEsWk','isFinite','score','flag','Preview:\x20update\x20personal\x20knowledge-base\x20entry\x20','length','ragErrorMessage','createTime','Search\x20visible\x20company\x20and\x20personal\x20knowledge\x20base\x20content','List\x20personal\x20knowledge-base\x20entries\x20for\x20the\x20current\x20app','Path\x20to\x20a\x20local\x20UTF-8\x20text\x20or\x20Markdown\x20file','validation','2FFAakr','Override\x20the\x20existing\x20entry\x20title'];a32_0xe4f9=function(){return _0xdeaa53;};return a32_0xe4f9();}import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const TITLE_FLAG={'name':'title','type':a32_0x329f56(0xe9),'required':!![],'description':a32_0x329f56(0xfc)},FILE_FLAG={'name':a32_0x329f56(0xf4),'type':a32_0x329f56(0xe9),'required':!![],'description':a32_0x329f56(0xcd)},QUERY_FLAG={'name':a32_0x329f56(0xf5),'type':a32_0x329f56(0xe9),'required':!![],'description':'Search\x20query\x20for\x20visible\x20company\x20and\x20personal\x20knowledge'},TOPK_FLAG={'name':a32_0x329f56(0x100),'type':'number','description':'Maximum\x20number\x20of\x20search\x20hits\x20to\x20return'};function readKnowledgeFile(_0x31b8d6){const _0x24ee88=a32_0x329f56;if(!_0x31b8d6)throw CliErrors[_0x24ee88(0xce)]('File\x20path\x20is\x20required.');if(!existsSync(_0x31b8d6))throw CliErrors['validation']('File\x20not\x20found:\x20'+_0x31b8d6);if(!statSync(_0x31b8d6)[_0x24ee88(0xfe)]())throw CliErrors[_0x24ee88(0xce)]('File\x20is\x20not\x20a\x20regular\x20file:\x20'+_0x31b8d6);return readFileSync(_0x31b8d6,_0x24ee88(0xd8));}function summarizePersonalItem(_0x32abd6){const _0x40f4b5=a32_0x329f56;return{'id':_0x32abd6['id'],'title':_0x32abd6[_0x40f4b5(0xf7)],'version':_0x32abd6[_0x40f4b5(0xdf)],'ragStatus':_0x32abd6['ragStatus'],'ragErrorMessage':_0x32abd6[_0x40f4b5(0xc9)],'updateTime':_0x32abd6[_0x40f4b5(0xf0)]};}function detailPersonalItem(_0x4562c1){const _0x5c03c0=a32_0x329f56;return{'id':_0x4562c1['id'],'appCode':_0x4562c1['appCode'],'scope':_0x4562c1[_0x5c03c0(0x105)],'userId':_0x4562c1['userId'],'title':_0x4562c1[_0x5c03c0(0xf7)],'content':_0x4562c1[_0x5c03c0(0xda)]??'','version':_0x4562c1['version'],'ragStatus':_0x4562c1[_0x5c03c0(0xea)],'ragErrorMessage':_0x4562c1[_0x5c03c0(0xc9)],'createTime':_0x4562c1[_0x5c03c0(0xca)],'updateTime':_0x4562c1[_0x5c03c0(0xf0)]};}function summarizeSearchHit(_0x2a01b8){const _0x30c845=a32_0x329f56;return{'scope':_0x2a01b8[_0x30c845(0x105)],'title':_0x2a01b8[_0x30c845(0xf7)],'docId':_0x2a01b8['docId'],'score':_0x2a01b8[_0x30c845(0x108)],'weightedScore':_0x2a01b8['weightedScore'],'content':_0x2a01b8[_0x30c845(0xda)],'metadata':_0x2a01b8[_0x30c845(0x101)]};}function readTopK(_0x5889b1){const _0x288598=a32_0x329f56,_0x485599=_0x5889b1[_0x288598(0x109)]('topk');if(_0x485599===undefined||_0x485599===null||_0x485599==='')return undefined;const _0x44e7f8=_0x5889b1[_0x288598(0xe3)](_0x288598(0x100));if(!Number[_0x288598(0x107)](_0x44e7f8)||_0x44e7f8<0x1)throw CliErrors[_0x288598(0xce)](_0x288598(0xfa));return _0x44e7f8;}const kbList={'service':'kb','command':a32_0x329f56(0xd3),'description':a32_0x329f56(0xcc),'risk':a32_0x329f56(0xe8),'flags':[VERBOSE_FLAG],async 'execute'(_0x4b3c04){const _0x2aa949=a32_0x329f56,_0x526c8d=await listPersonalKnowledgeBaseItems(_0x4b3c04[_0x2aa949(0xec)]);if(_0x4b3c04[_0x2aa949(0xff)](_0x2aa949(0xe5)))return{'ok':!![],'data':{'total':_0x526c8d[_0x2aa949(0x10b)],'items':_0x526c8d}};return{'ok':!![],'data':{'total':_0x526c8d[_0x2aa949(0x10b)],'items':_0x526c8d[_0x2aa949(0xe4)](summarizePersonalItem)}};}},kbDetail={'service':'kb','command':a32_0x329f56(0xf2),'description':a32_0x329f56(0xed),'risk':'read','flags':[{...ID_FLAG,'description':'Personal\x20knowledge-base\x20entry\x20ID'}],async 'execute'(_0x580dd9){const _0x364555=a32_0x329f56,_0x1599be=await getPersonalKnowledgeBaseItem(_0x580dd9[_0x364555(0xe3)]('id'),_0x580dd9[_0x364555(0xec)]);return{'ok':!![],'data':detailPersonalItem(_0x1599be)};}},kbCreate={'service':'kb','command':a32_0x329f56(0xdd),'description':a32_0x329f56(0xd5),'risk':'write','confirmationDescription':a32_0x329f56(0xdb),'flags':[TITLE_FLAG,FILE_FLAG],async 'execute'(_0x2550fe){const _0x53dab9=a32_0x329f56,_0x13a4fe=_0x2550fe[_0x53dab9(0xd9)](_0x53dab9(0xf7)),_0x3bdb54=readKnowledgeFile(_0x2550fe[_0x53dab9(0xd9)](_0x53dab9(0xf4))),_0x2e68bd=await createPersonalKnowledgeBaseItem(_0x2550fe[_0x53dab9(0xec)],{'title':_0x13a4fe,'content':_0x3bdb54});return{'ok':!![],'data':summarizePersonalItem(_0x2e68bd),'message':'Created\x20KB\x20entry\x20'+_0x2e68bd['id']+'\x20('+_0x2e68bd['title']+')'};},async 'dryRun'(_0x2a2291){const _0xc7a47b=a32_0x329f56,_0x1943fe=_0x2a2291[_0xc7a47b(0xd9)](_0xc7a47b(0xf7)),_0x5f4a70=readKnowledgeFile(_0x2a2291[_0xc7a47b(0xd9)](_0xc7a47b(0xf4)));return dryRun(_0xc7a47b(0xd6),_0xc7a47b(0xef))[_0xc7a47b(0xd4)]({'appCode':_0x2a2291[_0xc7a47b(0xec)],'title':_0x1943fe,'content':_0x5f4a70})[_0xc7a47b(0xe0)]('Preview:\x20create\x20personal\x20knowledge-base\x20entry\x20\x22'+_0x1943fe+'\x22')[_0xc7a47b(0xeb)]();}},kbUpdate={'service':'kb','command':a32_0x329f56(0xf6),'description':a32_0x329f56(0xe1),'risk':a32_0x329f56(0xf8),'confirmationDescription':a32_0x329f56(0x102),'flags':[{...ID_FLAG,'description':a32_0x329f56(0xe6)},{...TITLE_FLAG,'required':![],'description':a32_0x329f56(0xd0)},FILE_FLAG],async 'execute'(_0x334cdd){const _0x4095f4=a32_0x329f56,_0x1e5b61=_0x334cdd[_0x4095f4(0xe3)]('id'),_0x314497=readKnowledgeFile(_0x334cdd[_0x4095f4(0xd9)](_0x4095f4(0xf4))),_0x19bbc9=_0x334cdd[_0x4095f4(0xd9)](_0x4095f4(0xf7))||(await getPersonalKnowledgeBaseItem(_0x1e5b61,_0x334cdd['appCode']))[_0x4095f4(0xf7)],_0x421fcc=await updatePersonalKnowledgeBaseItem(_0x1e5b61,_0x334cdd['appCode'],{'title':_0x19bbc9,'content':_0x314497});return{'ok':!![],'data':summarizePersonalItem(_0x421fcc),'message':_0x4095f4(0xf9)+_0x421fcc['id']+'\x20('+_0x421fcc[_0x4095f4(0xf7)]+')'};},async 'dryRun'(_0x2c5b25){const _0x255858=a32_0x329f56,_0x5d2a7f=_0x2c5b25[_0x255858(0xe3)]('id'),_0x5c3027=readKnowledgeFile(_0x2c5b25[_0x255858(0xd9)](_0x255858(0xf4))),_0xe3269a=_0x2c5b25[_0x255858(0xd9)](_0x255858(0xf7))||(await getPersonalKnowledgeBaseItem(_0x5d2a7f,_0x2c5b25['appCode']))[_0x255858(0xf7)];return dryRun(_0x255858(0xd6),_0x255858(0xe2)+_0x5d2a7f+'/update')[_0x255858(0xd4)]({'appCode':_0x2c5b25[_0x255858(0xec)],'title':_0xe3269a,'content':_0x5c3027})[_0x255858(0xe0)](_0x255858(0x10a)+_0x5d2a7f)[_0x255858(0xeb)]();}},kbSearch={'service':'kb','command':a32_0x329f56(0xfd),'description':a32_0x329f56(0xcb),'risk':a32_0x329f56(0xe8),'flags':[QUERY_FLAG,TOPK_FLAG],async 'validate'(_0x257a20){const _0x478d75=a32_0x329f56;if(!_0x257a20[_0x478d75(0xd9)](_0x478d75(0xf5))[_0x478d75(0x104)]())throw CliErrors['validation'](_0x478d75(0xde));readTopK(_0x257a20);},async 'execute'(_0x31c7d0){const _0xdd7d4d=a32_0x329f56,_0x3f5171=_0x31c7d0[_0xdd7d4d(0xd9)]('query')[_0xdd7d4d(0x104)](),_0x430d03=readTopK(_0x31c7d0),_0x52adf3=await searchKnowledgeBase(_0x31c7d0[_0xdd7d4d(0xec)],{'query':_0x3f5171,'topK':_0x430d03});return{'ok':!![],'data':{'total':_0x52adf3[_0xdd7d4d(0x10b)],'hits':_0x52adf3[_0xdd7d4d(0xe4)](summarizeSearchHit)}};}};export const kbDefinitions=[kbList,kbDetail,kbCreate,kbUpdate,kbSearch];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a33_0x2e5d(){const _0x55d6b8=['6MJqzXm','70WdTSBH','toLocaleString','forEach','command','\x20logs:\x0a','57124MYCZuA','stringify','length','success','readLogs','read','error','duration','\x20\x20\x20Details:\x20','\x20\x20\x20Time:\x20','timestamp','11ttDhfn','View\x20command\x20history\x20logs','4WEeYPw','2083653hiPnkb','level','keys','213276wYkojn','124666PPAcHo','\x20\x20\x20Duration:\x20','logs','*\x20No\x20logs\x20found','message','3383224eihEpD','530875BkmZqd','warn','en-US','log','1417310eqQsDQ','details'];a33_0x2e5d=function(){return _0x55d6b8;};return a33_0x2e5d();}const a33_0x15f049=a33_0x3c43;(function(_0x1dea3d,_0x27cb7b){const _0x555778=a33_0x3c43,_0x21789a=_0x1dea3d();while(!![]){try{const _0x2671eb=parseInt(_0x555778(0x73))/0x1+parseInt(_0x555778(0x85))/0x2*(-parseInt(_0x555778(0x6d))/0x3)+-parseInt(_0x555778(0x80))/0x4*(-parseInt(_0x555778(0x67))/0x5)+-parseInt(_0x555778(0x84))/0x6*(-parseInt(_0x555778(0x6e))/0x7)+-parseInt(_0x555778(0x66))/0x8+parseInt(_0x555778(0x81))/0x9+parseInt(_0x555778(0x6b))/0xa*(parseInt(_0x555778(0x7e))/0xb);if(_0x2671eb===_0x27cb7b)break;else _0x21789a['push'](_0x21789a['shift']());}catch(_0x1f3434){_0x21789a['push'](_0x21789a['shift']());}}}(a33_0x2e5d,0x54176));import{logger}from'../../utils/logger.js';import{CLI_DISPLAY_NAME}from'../../constant/cli.js';function printLogs(_0x385fbf){const _0x1d318d=a33_0x3c43;if(_0x385fbf['length']===0x0){console[_0x1d318d(0x6a)](_0x1d318d(0x88));return;}console['log']('*\x20'+CLI_DISPLAY_NAME+_0x1d318d(0x72)),_0x385fbf[_0x1d318d(0x70)]((_0x546ea4,_0x3761e2)=>{const _0x3b1294=_0x1d318d,_0x593aa2=new Date(_0x546ea4[_0x3b1294(0x7d)])[_0x3b1294(0x6f)](_0x3b1294(0x69)),_0x7e862b=_0x546ea4[_0x3b1294(0x82)]===_0x3b1294(0x76)?'√':_0x546ea4[_0x3b1294(0x82)]===_0x3b1294(0x79)?'×':_0x546ea4[_0x3b1294(0x82)]===_0x3b1294(0x68)?'!':'i';console[_0x3b1294(0x6a)](_0x3761e2+0x1+'.\x20'+_0x7e862b+'\x20['+_0x546ea4[_0x3b1294(0x71)]+']\x20'+_0x546ea4[_0x3b1294(0x89)]),console[_0x3b1294(0x6a)](_0x3b1294(0x7c)+_0x593aa2),_0x546ea4[_0x3b1294(0x7a)]&&console['log'](_0x3b1294(0x86)+_0x546ea4[_0x3b1294(0x7a)]+'ms'),_0x546ea4[_0x3b1294(0x6c)]&&Object[_0x3b1294(0x83)](_0x546ea4['details'])[_0x3b1294(0x75)]>0x0&&console[_0x3b1294(0x6a)](_0x3b1294(0x7b)+JSON[_0x3b1294(0x74)](_0x546ea4['details'],null,0x2)),console['log']('');});}function a33_0x3c43(_0x106f68,_0x1ada7d){_0x106f68=_0x106f68-0x66;const _0x2e5d29=a33_0x2e5d();let _0x3c4362=_0x2e5d29[_0x106f68];return _0x3c4362;}export const logsDefinitions=[{'service':a33_0x15f049(0x87),'command':'show','description':a33_0x15f049(0x7f),'risk':a33_0x15f049(0x78),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x4f5cc8){const _0x1a9bb7=a33_0x15f049;return printLogs(logger[_0x1a9bb7(0x77)]()),{'ok':!![]};}}];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a34_0x48af15=a34_0x3023;function a34_0x6f6d(){const _0x2a1808=['read','appCode','Found\x20','656253UJWdqP','notification','\x20notification\x20config(s)','400741tfnRRz','config-list','10YpHOTp','3ASEUKp','type','1862273vjGRJf','length','Notification\x20channel\x20type','139866zFAtvZ','1468504mdbDgP','string','EMAIL','681848AUgsGN','5xUzgub','771466GMjsDP','List\x20app-level\x20notification\x20configs\x20and\x20their\x20configCode\x20values'];a34_0x6f6d=function(){return _0x2a1808;};return a34_0x6f6d();}function a34_0x3023(_0x19aff7,_0x141e52){_0x19aff7=_0x19aff7-0x1e1;const _0x6f6d6e=a34_0x6f6d();let _0x302355=_0x6f6d6e[_0x19aff7];return _0x302355;}(function(_0xe6fe14,_0x426397){const _0x465af2=a34_0x3023,_0x9a60c1=_0xe6fe14();while(!![]){try{const _0x5d8bf9=parseInt(_0x465af2(0x1f5))/0x1+parseInt(_0x465af2(0x1ed))/0x2+-parseInt(_0x465af2(0x1e2))/0x3*(parseInt(_0x465af2(0x1eb))/0x4)+parseInt(_0x465af2(0x1ec))/0x5*(-parseInt(_0x465af2(0x1e7))/0x6)+-parseInt(_0x465af2(0x1e4))/0x7+-parseInt(_0x465af2(0x1e8))/0x8+-parseInt(_0x465af2(0x1f2))/0x9*(-parseInt(_0x465af2(0x1e1))/0xa);if(_0x5d8bf9===_0x426397)break;else _0x9a60c1['push'](_0x9a60c1['shift']());}catch(_0xf3afd3){_0x9a60c1['push'](_0x9a60c1['shift']());}}}(a34_0x6f6d,0x34bd0));import{listNotificationChannelConfigs}from'../../core/api-client.js';import{NOTIFICATION_CHANNEL_TYPES,projectNotificationListConfig,readNotificationChannelType}from'../../commands/notification/shared.js';export const notificationConfigList={'service':a34_0x48af15(0x1f3),'command':a34_0x48af15(0x1f6),'description':a34_0x48af15(0x1ee),'risk':a34_0x48af15(0x1ef),'flags':[{'name':a34_0x48af15(0x1e3),'type':a34_0x48af15(0x1e9),'description':a34_0x48af15(0x1e6),'enum':NOTIFICATION_CHANNEL_TYPES,'default':a34_0x48af15(0x1ea)}],async 'validate'(_0x55dc9a){readNotificationChannelType(_0x55dc9a);},async 'execute'(_0x351907){const _0x2e6936=a34_0x48af15,_0x2757f3=readNotificationChannelType(_0x351907),_0x559def=await listNotificationChannelConfigs(_0x351907['appCode'],_0x2757f3),_0x57c986=_0x559def['map'](projectNotificationListConfig);return{'ok':!![],'data':{'appCode':_0x351907[_0x2e6936(0x1f0)],'channelType':_0x2757f3,'count':_0x57c986[_0x2e6936(0x1e5)],'configs':_0x57c986},'message':_0x2e6936(0x1f1)+_0x57c986[_0x2e6936(0x1e5)]+'\x20'+_0x2757f3+_0x2e6936(0x1f4)};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a35_0x1d89(){const _0x270403=['1505426FjXFbP','63EHbaMU','8WwMqgL','4350693KwRmwo','5870965LnRIYy','1027542fLQYmH','14440572JbmGMH','10eEECSw','5083852ENkpxK','1IVkAXc','26786683xkqVFt'];a35_0x1d89=function(){return _0x270403;};return a35_0x1d89();}(function(_0x30615c,_0x55e585){const _0x1e012f=a35_0x5307,_0x2e55f8=_0x30615c();while(!![]){try{const _0x445844=parseInt(_0x1e012f(0xd4))/0x1*(-parseInt(_0x1e012f(0xd6))/0x2)+-parseInt(_0x1e012f(0xd9))/0x3+parseInt(_0x1e012f(0xde))/0x4+parseInt(_0x1e012f(0xda))/0x5+-parseInt(_0x1e012f(0xdb))/0x6*(-parseInt(_0x1e012f(0xd7))/0x7)+parseInt(_0x1e012f(0xd8))/0x8*(parseInt(_0x1e012f(0xdc))/0x9)+parseInt(_0x1e012f(0xdd))/0xa*(-parseInt(_0x1e012f(0xd5))/0xb);if(_0x445844===_0x55e585)break;else _0x2e55f8['push'](_0x2e55f8['shift']());}catch(_0xf0a666){_0x2e55f8['push'](_0x2e55f8['shift']());}}}(a35_0x1d89,0xe8a30));function a35_0x5307(_0x3d6005,_0x3634f8){_0x3d6005=_0x3d6005-0xd4;const _0x1d89c3=a35_0x1d89();let _0x5307c6=_0x1d89c3[_0x3d6005];return _0x5307c6;}import{notificationConfigList}from'../../commands/notification/config-list.js';export const notificationDefinitions=[notificationConfigList];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a36_0x39e74e=a36_0x94ed;function a36_0x6198(){const _0x1dde42=['createTime','isArray','string','isSafeInteger','Item\x20','5297320fYLkIA','\x20is\x20missing\x20required\x20field\x20\x22','Invalid\x20--type:\x20','apiError','2280820puvoGz','\x20must\x20be\x20an\x20object.','updateTime','type','323680yxumaG','includes','Invalid\x20notification\x20config\x20response.','7rDveHr','EMAIL','934902DvJJkt','description','6mgmVBD','Allowed\x20values:\x20','validation','WEBHOOK','configName','number','join','\x20has\x20invalid\x20field\x20\x22id\x22.','configCode','trim','1172606PVQyTi','str','object','1544773PGCAYu','6055536WiMMJO'];a36_0x6198=function(){return _0x1dde42;};return a36_0x6198();}(function(_0x5c97ce,_0x495ca1){const _0xecc26b=a36_0x94ed,_0x34caf9=_0x5c97ce();while(!![]){try{const _0x4670f4=-parseInt(_0xecc26b(0x9b))/0x1+parseInt(_0xecc26b(0x98))/0x2*(parseInt(_0xecc26b(0xb1))/0x3)+-parseInt(_0xecc26b(0xa6))/0x4+parseInt(_0xecc26b(0xaa))/0x5+parseInt(_0xecc26b(0x9c))/0x6+-parseInt(_0xecc26b(0xad))/0x7*(-parseInt(_0xecc26b(0xa2))/0x8)+parseInt(_0xecc26b(0xaf))/0x9;if(_0x4670f4===_0x495ca1)break;else _0x34caf9['push'](_0x34caf9['shift']());}catch(_0x1e5e29){_0x34caf9['push'](_0x34caf9['shift']());}}}(a36_0x6198,0xdb27f));import{CliErrors}from'../../errors.js';export const NOTIFICATION_CHANNEL_TYPES=[a36_0x39e74e(0xae),'FEISHU','DINGTALK','WECOM',a36_0x39e74e(0x91)];export function readNotificationChannelType(_0xd3d032){const _0x137ae7=a36_0x39e74e,_0x29d119=_0xd3d032[_0x137ae7(0x99)](_0x137ae7(0xa9))[_0x137ae7(0x97)]()||_0x137ae7(0xae);if(!NOTIFICATION_CHANNEL_TYPES[_0x137ae7(0xab)](_0x29d119))throw CliErrors[_0x137ae7(0x90)](_0x137ae7(0xa4)+_0x29d119,_0x137ae7(0x8f)+NOTIFICATION_CHANNEL_TYPES[_0x137ae7(0x94)](',\x20')+'.');return _0x29d119;}export function projectNotificationListConfig(_0x7988e,_0x4197ec){const _0x46b202=a36_0x39e74e,_0x369916=requireResponseObject(_0x7988e,_0x4197ec);return{'id':normalizeNullableId(_0x369916['id'],_0x4197ec),'configCode':requireResponseString(_0x369916['configCode'],_0x46b202(0x96),_0x4197ec),'configName':requireResponseString(_0x369916[_0x46b202(0x92)],_0x46b202(0x92),_0x4197ec),'channelType':requireResponseString(_0x369916['channelType'],'channelType',_0x4197ec),'description':normalizeNullableString(_0x369916[_0x46b202(0xb0)]),'createTime':normalizeNullableString(_0x369916[_0x46b202(0x9d)]),'updateTime':normalizeNullableString(_0x369916[_0x46b202(0xa8)])};}function requireResponseObject(_0x5ae97e,_0x314c95){const _0xf03c9b=a36_0x39e74e;if(typeof _0x5ae97e!==_0xf03c9b(0x9a)||_0x5ae97e===null||Array[_0xf03c9b(0x9e)](_0x5ae97e))throw CliErrors['apiError'](_0xf03c9b(0xac),_0xf03c9b(0xa1)+(_0x314c95+0x1)+_0xf03c9b(0xa7));return _0x5ae97e;}function requireResponseString(_0xc5fb8,_0xb8bba8,_0x329c75){const _0x4269bc=a36_0x39e74e;if(typeof _0xc5fb8!=='string'||!_0xc5fb8[_0x4269bc(0x97)]())throw CliErrors['apiError'](_0x4269bc(0xac),_0x4269bc(0xa1)+(_0x329c75+0x1)+_0x4269bc(0xa3)+_0xb8bba8+'\x22.');return _0xc5fb8[_0x4269bc(0x97)]();}function normalizeNullableString(_0xfb247c){const _0x4000b4=a36_0x39e74e;return typeof _0xfb247c===_0x4000b4(0x9f)&&_0xfb247c[_0x4000b4(0x97)]()?_0xfb247c[_0x4000b4(0x97)]():null;}function a36_0x94ed(_0x20d290,_0x20e265){_0x20d290=_0x20d290-0x8f;const _0x61981d=a36_0x6198();let _0x94ed19=_0x61981d[_0x20d290];return _0x94ed19;}function normalizeNullableId(_0x28d562,_0x1dc341){const _0x2dd712=a36_0x39e74e;if(_0x28d562===undefined||_0x28d562===null)return null;if(typeof _0x28d562===_0x2dd712(0x93)&&Number[_0x2dd712(0xa0)](_0x28d562))return _0x28d562;if(typeof _0x28d562===_0x2dd712(0x9f)&&/^-?\d+$/['test'](_0x28d562[_0x2dd712(0x97)]()))return _0x28d562['trim']();throw CliErrors[_0x2dd712(0xa5)](_0x2dd712(0xac),_0x2dd712(0xa1)+(_0x1dc341+0x1)+_0x2dd712(0x95));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a37_0x89502e=a37_0x4f9f;function a37_0x43eb(){const _0x1388d2=['3016296PiWHLE','Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.','description','scene','Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20','path','<filePath\x20returned\x20by\x20/client/uploadFile>','validation','Preview:\x20recognize\x20','appCode','length','Local\x20image\x20or\x20PDF\x20file;\x20current\x20backend\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR','File\x20upload\x20response\x20missing\x20filePath.','2007IIlsXK','imageFile','fileUrl','ocr','366311mkZENB','invoice','image-file','General','/client/ocr','使用运行态\x20OCR\x20服务识别\x20URL\x20或本地文件中的文字','94fvKRnR','fileName','form','\x20OCR','/client/uploadFile','57640oWkVYU','idcard','image-url','string','Table','15448qBJUmi','41853khXHzS','190bQEfvS','read','IdCard','POST','recognize','Publicly\x20accessible\x20image\x20or\x20file\x20URL','30963ogEIud','build','.\x20Supported\x20scenes:\x20','OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard','body','/client/queryFileUrl','filePath','general','toLowerCase','112JvejxH','count','imageUrl','trim','str','396832wEwNDv'];a37_0x43eb=function(){return _0x1388d2;};return a37_0x43eb();}(function(_0x1df052,_0x346634){const _0x32262e=a37_0x4f9f,_0x15c6f0=_0x1df052();while(!![]){try{const _0x3a7099=parseInt(_0x32262e(0xd4))/0x1+-parseInt(_0x32262e(0xec))/0x2*(-parseInt(_0x32262e(0xfe))/0x3)+-parseInt(_0x32262e(0xcf))/0x4*(parseInt(_0x32262e(0xf1))/0x5)+-parseInt(_0x32262e(0xd5))/0x6+parseInt(_0x32262e(0xf7))/0x7+parseInt(_0x32262e(0xf6))/0x8*(-parseInt(_0x32262e(0xe2))/0x9)+-parseInt(_0x32262e(0xf8))/0xa*(-parseInt(_0x32262e(0xe6))/0xb);if(_0x3a7099===_0x346634)break;else _0x15c6f0['push'](_0x15c6f0['shift']());}catch(_0x50ed3d){_0x15c6f0['push'](_0x15c6f0['shift']());}}}(a37_0x43eb,0x40938));import{requireRuntimeUploadFile}from'../../commands/common/local-file.js';import{queryRuntimeFileUrl,recognizeRuntimeOcr,uploadRuntimeFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const SUPPORTED_SCENES=[a37_0x89502e(0xe7),a37_0x89502e(0xcd),a37_0x89502e(0xee),'idCard'],SCENE_TO_LEGACY_TYPE={'invoice':'Invoice','general':a37_0x89502e(0xe9),'form':a37_0x89502e(0xf5),'idCard':a37_0x89502e(0xfa)},SCENE_FLAG={'name':a37_0x89502e(0xd8),'type':a37_0x89502e(0xf4),'required':!![],'enum':[...SUPPORTED_SCENES],'description':a37_0x89502e(0x101)},IMAGE_FILE_FLAG={'name':'image-file','type':a37_0x89502e(0xf4),'description':a37_0x89502e(0xe0)},IMAGE_URL_FLAG={'name':a37_0x89502e(0xf3),'type':'string','description':a37_0x89502e(0xfd)};function a37_0x4f9f(_0x4dc08e,_0xc18d76){_0x4dc08e=_0x4dc08e-0xca;const _0x43ebbf=a37_0x43eb();let _0x4f9f88=_0x43ebbf[_0x4dc08e];return _0x4f9f88;}function normalizeScene(_0x40e08a){const _0x288f3c=a37_0x89502e,_0x26a765=_0x40e08a[_0x288f3c(0xd2)]()[_0x288f3c(0xce)]();if(_0x26a765===_0x288f3c(0xf2))return'idCard';if(_0x26a765===_0x288f3c(0xe7)||_0x26a765===_0x288f3c(0xcd)||_0x26a765===_0x288f3c(0xee))return _0x26a765;throw CliErrors[_0x288f3c(0xdc)]('Unsupported\x20OCR\x20scene:\x20'+_0x40e08a+_0x288f3c(0x100)+SUPPORTED_SCENES['join'](',\x20'));}function selectedInputs(_0x2eb942){const _0x3e6e41=a37_0x89502e,_0x3707e5=_0x2eb942[_0x3e6e41(0xd3)](_0x3e6e41(0xe8))['trim'](),_0x3a565f=_0x2eb942[_0x3e6e41(0xd3)](_0x3e6e41(0xf3))[_0x3e6e41(0xd2)]();return{'imageFile':_0x3707e5,'imageUrl':_0x3a565f,'count':[_0x3707e5,_0x3a565f]['filter'](Boolean)[_0x3e6e41(0xdf)]};}function validateInputSelection(_0x8bdd0a){const _0x54a774=a37_0x89502e,_0xbb912f=selectedInputs(_0x8bdd0a);if(_0xbb912f[_0x54a774(0xd0)]!==0x1)throw CliErrors['validation'](_0x54a774(0xd6));return _0xbb912f;}function withScene(_0x25e52b,_0x40af73,_0x4d065a){const _0x3756e6=a37_0x89502e;return{..._0x25e52b,'scene':_0x40af73,..._0x4d065a?{'sourceFile':{'fileName':_0x4d065a[_0x3756e6(0xed)],'filePath':_0x4d065a[_0x3756e6(0xcc)]}}:{}};}const ocrRecognize={'service':a37_0x89502e(0xe5),'command':a37_0x89502e(0xfc),'description':a37_0x89502e(0xeb),'risk':a37_0x89502e(0xf9),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x5d57cb){const _0x20de80=a37_0x89502e,_0x3a23b5=normalizeScene(_0x5d57cb['str'](_0x20de80(0xd8))),_0x55aeff=SCENE_TO_LEGACY_TYPE[_0x3a23b5],_0x5dd4e7=validateInputSelection(_0x5d57cb);if(_0x5dd4e7[_0x20de80(0xd1)])return dryRun(_0x20de80(0xfb),'/client/ocr')[_0x20de80(0xca)]({'appCode':_0x5d57cb['appCode'],'url':_0x5dd4e7['imageUrl'],'type':_0x55aeff})['description'](_0x20de80(0xdd)+_0x3a23b5+'\x20OCR\x20from\x20URL')[_0x20de80(0xff)]();const _0x31776c=requireRuntimeUploadFile(_0x5dd4e7[_0x20de80(0xe3)],_0x20de80(0xe8));return dryRun(_0x20de80(0xfb),_0x20de80(0xf0))[_0x20de80(0xca)]({'steps':[{'method':_0x20de80(0xfb),'url':_0x20de80(0xf0),'body':{'appCode':_0x5d57cb[_0x20de80(0xde)],'multipart':{'file':_0x31776c}}},{'method':_0x20de80(0xfb),'url':_0x20de80(0xcb),'body':{'filePath':_0x20de80(0xdb),'downloadFlag':![]}},{'method':_0x20de80(0xfb),'url':_0x20de80(0xea),'body':{'appCode':_0x5d57cb[_0x20de80(0xde)],'url':'<fileUrl\x20returned\x20by\x20/client/queryFileUrl>','type':_0x55aeff}}]})[_0x20de80(0xd7)](_0x20de80(0xd9)+_0x3a23b5+_0x20de80(0xef))['build']();},async 'execute'(_0xee5201){const _0x4f8986=a37_0x89502e,_0x333e91=normalizeScene(_0xee5201[_0x4f8986(0xd3)](_0x4f8986(0xd8))),_0xf9d8f8=SCENE_TO_LEGACY_TYPE[_0x333e91],_0x11cc60=validateInputSelection(_0xee5201);if(_0x11cc60[_0x4f8986(0xd1)]){const _0x3f9322=await recognizeRuntimeOcr(_0xee5201['appCode'],{'url':_0x11cc60[_0x4f8986(0xd1)],'type':_0xf9d8f8});return{'ok':!![],'data':withScene(_0x3f9322,_0x333e91)};}const _0x5e3ed9=requireRuntimeUploadFile(_0x11cc60['imageFile'],_0x4f8986(0xe8)),_0xbd3b85=await uploadRuntimeFile(_0xee5201[_0x4f8986(0xde)],_0x5e3ed9[_0x4f8986(0xda)]);if(!_0xbd3b85[_0x4f8986(0xcc)])throw CliErrors['apiError'](_0x4f8986(0xe1));const _0x1ddb6c=await queryRuntimeFileUrl(_0xbd3b85[_0x4f8986(0xcc)],{'download':![]});if(!_0x1ddb6c[_0x4f8986(0xe4)])throw CliErrors['apiError']('File\x20URL\x20response\x20missing\x20fileUrl.');const _0x351a75=await recognizeRuntimeOcr(_0xee5201[_0x4f8986(0xde)],{'url':_0x1ddb6c[_0x4f8986(0xe4)],'type':_0xf9d8f8});return{'ok':!![],'data':withScene(_0x351a75,_0x333e91,_0xbd3b85)};}};export const ocrDefinitions=[ocrRecognize];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a38_0x58a71e=a38_0x3234;(function(_0x17d200,_0xb01729){const _0x4d3e87=a38_0x3234,_0x5e604e=_0x17d200();while(!![]){try{const _0x23ab85=parseInt(_0x4d3e87(0x1ed))/0x1*(parseInt(_0x4d3e87(0x1f4))/0x2)+-parseInt(_0x4d3e87(0x1fa))/0x3+parseInt(_0x4d3e87(0x1f9))/0x4*(parseInt(_0x4d3e87(0x1ee))/0x5)+parseInt(_0x4d3e87(0x1f8))/0x6*(-parseInt(_0x4d3e87(0x1fc))/0x7)+-parseInt(_0x4d3e87(0x1f6))/0x8*(-parseInt(_0x4d3e87(0x1f3))/0x9)+parseInt(_0x4d3e87(0x1f1))/0xa*(parseInt(_0x4d3e87(0x1ec))/0xb)+-parseInt(_0x4d3e87(0x1eb))/0xc;if(_0x23ab85===_0xb01729)break;else _0x5e604e['push'](_0x5e604e['shift']());}catch(_0x2dbbd3){_0x5e604e['push'](_0x5e604e['shift']());}}}(a38_0x545c,0x81091));function a38_0x545c(){const _0xa14a2e=['str','8YuTloo','read','6bYDUGK','208purXpy','1655499MFLTiD','Runtime\x20role\x20ID\x20or\x20exact\x20role\x20name','6570123bdQbTj','appCode','runtime','3672744vUsHXJ','66407rlIKId','55795oFrDYR','47315IRLOeJ','string','dataset-get','1570oaYYoh','Show\x20runtime\x20dataset\x20permissions,\x20optionally\x20evaluated\x20for\x20one\x20role','3446757LAWGxA','18mDMgNm'];a38_0x545c=function(){return _0xa14a2e;};return a38_0x545c();}function a38_0x3234(_0x2d0194,_0x356785){_0x2d0194=_0x2d0194-0x1eb;const _0x545c8f=a38_0x545c();let _0x323479=_0x545c8f[_0x2d0194];return _0x323479;}import{listRuntimeDatasetPermits,listRuntimeDatasetRolePermits}from'../../core/api-client.js';import{resolveRuntimeRoleRef}from'../../commands/role/shared.js';export const permitDatasetGet={'service':'permit','command':a38_0x58a71e(0x1f0),'description':a38_0x58a71e(0x1f2),'risk':a38_0x58a71e(0x1f7),'flags':[{'name':'role','type':a38_0x58a71e(0x1ef),'description':a38_0x58a71e(0x1fb)}],async 'execute'(_0x8267a8){const _0x3fb0fd=a38_0x58a71e,_0xa2e667=_0x8267a8[_0x3fb0fd(0x1f5)]('role')['trim']();if(!_0xa2e667)return{'ok':!![],'data':{'scope':_0x3fb0fd(0x1fe),'datasets':await listRuntimeDatasetRolePermits(_0x8267a8[_0x3fb0fd(0x1fd)])}};const _0x52ee63=await resolveRuntimeRoleRef(_0x8267a8[_0x3fb0fd(0x1fd)],_0xa2e667);return{'ok':!![],'data':{'scope':_0x3fb0fd(0x1fe),'role':{'id':_0x52ee63['id'],'roleName':_0x52ee63['roleName'],'roleType':_0x52ee63['roleType']},'datasets':await listRuntimeDatasetPermits(_0x8267a8[_0x3fb0fd(0x1fd)],_0x52ee63['id'])}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a39_0x75b796=a39_0x1a1c;(function(_0xc499f,_0x3aa25d){const _0x3fa6c2=a39_0x1a1c,_0x35f849=_0xc499f();while(!![]){try{const _0x1e4fcc=-parseInt(_0x3fa6c2(0x186))/0x1*(parseInt(_0x3fa6c2(0x16e))/0x2)+-parseInt(_0x3fa6c2(0x162))/0x3*(parseInt(_0x3fa6c2(0x180))/0x4)+parseInt(_0x3fa6c2(0x17c))/0x5*(parseInt(_0x3fa6c2(0x18e))/0x6)+-parseInt(_0x3fa6c2(0x161))/0x7*(-parseInt(_0x3fa6c2(0x169))/0x8)+-parseInt(_0x3fa6c2(0x194))/0x9*(-parseInt(_0x3fa6c2(0x16f))/0xa)+parseInt(_0x3fa6c2(0x164))/0xb*(parseInt(_0x3fa6c2(0x17f))/0xc)+-parseInt(_0x3fa6c2(0x15e))/0xd;if(_0x1e4fcc===_0x3aa25d)break;else _0x35f849['push'](_0x35f849['shift']());}catch(_0x10a402){_0x35f849['push'](_0x35f849['shift']());}}}(a39_0xee27,0x94379));import{listRuntimeDatasetRolePermits,listRuntimePermitRoles,saveRuntimeDatasetRolePermits}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';function a39_0xee27(){const _0x31bc0d=['188AoBzby','130130kPLCOt','revoke','push','description','Grant\x20or\x20revoke\x20selected\x20runtime\x20dataset\x20actions\x20for\x20one\x20role','str','\x20already\x20reflects\x20','appCode','DATA_DETAIL','role','map','toUpperCase','DATA_DELETE','3198970oLWJLc','find','actions','72444oJozMI','428344ZWdBnC','before','includes','changed','Dataset\x20','bool','866YKsTsX','permitList','--actions','dataset-','DATA_EXPORT','\x20for\x20role\x20','roles','body','6QoENxB','DATA_UPDATE','resourceType','授予或收回目标角色对指定数据集动作的权限;变更会影响该角色用户的数据操作能力。','POST','warnings','369AjjSiP','join','build','/client/permit/resource/batch-save-dataset','operation','validation','rolePermit','string','permit','permitId','15624882bduXKN','dataset-set','DATA_ROW','7FFBEdz','24DMeQRo','\x20does\x20not\x20expose\x20','1969AqQQfk','\x20was\x20not\x20found.','dataPermitList','Runtime\x20dataset\x20','Preview:\x20','3945224byeRtA','resourceName','datasets','grant','after'];a39_0xee27=function(){return _0x31bc0d;};return a39_0xee27();}import{dryRun}from'../../framework/dryrun.js';import{resolveRuntimeRoleRef}from'../../commands/role/shared.js';function a39_0x1a1c(_0x93471,_0x3edb7f){_0x93471=_0x93471-0x15b;const _0xee27c5=a39_0xee27();let _0x1a1cd2=_0xee27c5[_0x93471];return _0x1a1cd2;}import{applyRuntimeRolePermission,assertGrantOrRevoke,assertRuntimePermissionManager,assertRuntimePermitRoleConfigurable,GRANT_FLAG,REVOKE_FLAG,ROLE_REF_FLAG,runtimePermitWriteResult,splitRefs}from'../../commands/permit/shared.js';const DATA_ACTIONS=['DATA_CREATE',a39_0x75b796(0x18f),a39_0x75b796(0x17b),a39_0x75b796(0x177),a39_0x75b796(0x18a),a39_0x75b796(0x160)],DATASETS_FLAG={'name':a39_0x75b796(0x16b),'type':a39_0x75b796(0x15b),'required':!![],'description':'Comma-separated\x20runtime\x20dataset\x20codes'},ACTIONS_FLAG={'name':a39_0x75b796(0x17e),'type':a39_0x75b796(0x15b),'required':!![],'description':'Comma-separated\x20actions:\x20'+DATA_ACTIONS[a39_0x75b796(0x195)](',\x20')};async function prepare(_0x34ed90){const _0x2866ef=a39_0x75b796;await assertRuntimePermissionManager(_0x34ed90[_0x2866ef(0x176)]);const _0x4261f1=assertGrantOrRevoke(_0x34ed90['bool'](_0x2866ef(0x16c)),_0x34ed90[_0x2866ef(0x185)](_0x2866ef(0x170))),_0x2b3e53=await resolveRuntimeRoleRef(_0x34ed90['appCode'],_0x34ed90[_0x2866ef(0x174)](_0x2866ef(0x178)));assertRuntimePermitRoleConfigurable(_0x2b3e53);const _0x16853b=splitRefs(_0x34ed90['str'](_0x2866ef(0x16b)),'--datasets'),_0x4fc66e=[...new Set(splitRefs(_0x34ed90[_0x2866ef(0x174)](_0x2866ef(0x17e)),_0x2866ef(0x188))[_0x2866ef(0x179)](_0x148e7d=>_0x148e7d[_0x2866ef(0x17a)]()))],_0x1af6b5=_0x4fc66e['filter'](_0x4da73d=>!DATA_ACTIONS[_0x2866ef(0x182)](_0x4da73d));if(_0x1af6b5['length']>0x0)throw CliErrors['validation']('Invalid\x20dataset\x20actions:\x20'+_0x1af6b5[_0x2866ef(0x195)](',\x20')+'.');const _0x3fdb36=await listRuntimeDatasetRolePermits(_0x34ed90[_0x2866ef(0x176)]),_0x3e8994=await listRuntimePermitRoles(_0x34ed90[_0x2866ef(0x176)]),_0x48ccf1=[],_0x3aaaf2=[],_0xb1a1cb=[],_0x50bf07=[];for(const _0x13c2de of _0x16853b){const _0x3d26a3=_0x3fdb36[_0x2866ef(0x17d)](_0x2189c8=>_0x2189c8['datasetCode']===_0x13c2de);if(!_0x3d26a3)throw CliErrors[_0x2866ef(0x199)](_0x2866ef(0x167)+_0x13c2de+_0x2866ef(0x165));for(const _0xf2fd8 of _0x4fc66e){const _0x90fd93=_0x3d26a3[_0x2866ef(0x166)][_0x2866ef(0x17d)](_0x44fab7=>_0x44fab7[_0x2866ef(0x190)]===_0xf2fd8);if(!_0x90fd93)throw CliErrors[_0x2866ef(0x199)](_0x2866ef(0x184)+_0x13c2de+_0x2866ef(0x163)+_0xf2fd8+'.');const _0x1a0afb=applyRuntimeRolePermission(_0x90fd93[_0x2866ef(0x19a)],_0x2b3e53,_0x3e8994,_0x4261f1);_0x3aaaf2[_0x2866ef(0x171)]({'datasetCode':_0x13c2de,'resourceType':_0xf2fd8,'rolePermit':_0x90fd93[_0x2866ef(0x19a)]}),_0xb1a1cb[_0x2866ef(0x171)]({'datasetCode':_0x13c2de,'resourceType':_0xf2fd8,'rolePermit':_0x1a0afb[_0x2866ef(0x18c)]}),_0x1a0afb[_0x2866ef(0x183)]?_0x48ccf1[_0x2866ef(0x171)]({..._0x90fd93[_0x2866ef(0x15d)]!=null?{'id':_0x90fd93['permitId']}:{},'appCode':_0x34ed90[_0x2866ef(0x176)],'resourceCode':_0x13c2de,'resourceType':_0xf2fd8,'resourceName':_0x90fd93[_0x2866ef(0x16a)],'rolePermit':_0x1a0afb[_0x2866ef(0x18c)]}):_0x50bf07['push'](_0x13c2de+'/'+_0xf2fd8+_0x2866ef(0x175)+_0x4261f1+_0x2866ef(0x18b)+_0x2b3e53['id']+'.');}}return{'operation':_0x4261f1,'role':_0x2b3e53,'datasetCodes':_0x16853b,'actions':_0x4fc66e,'permitList':_0x48ccf1,'before':_0x3aaaf2,'after':_0xb1a1cb,'warnings':_0x50bf07};}export const permitDatasetSet={'service':a39_0x75b796(0x15c),'command':a39_0x75b796(0x15f),'description':a39_0x75b796(0x173),'risk':'high-risk-write','confirmationDescription':a39_0x75b796(0x191),'flags':[ROLE_REF_FLAG,GRANT_FLAG,REVOKE_FLAG,DATASETS_FLAG,ACTIONS_FLAG],async 'validate'(_0x449ba0){const _0x4fc970=a39_0x75b796;assertGrantOrRevoke(_0x449ba0[_0x4fc970(0x185)](_0x4fc970(0x16c)),_0x449ba0['bool'](_0x4fc970(0x170)));},async 'dryRun'(_0x32cc12){const _0x47bfdd=a39_0x75b796,_0x5869f2=await prepare(_0x32cc12);return dryRun(_0x47bfdd(0x192),_0x47bfdd(0x197))[_0x47bfdd(0x18d)]({'appCode':_0x32cc12['appCode'],'permitList':_0x5869f2[_0x47bfdd(0x187)]})[_0x47bfdd(0x172)](_0x47bfdd(0x168)+_0x5869f2['operation']+'\x20selected\x20runtime\x20dataset\x20actions')[_0x47bfdd(0x196)]();},async 'execute'(_0x1ff3da){const _0x27985a=a39_0x75b796,_0x334d61=await prepare(_0x1ff3da);return _0x334d61['permitList']['length']>0x0&&await saveRuntimeDatasetRolePermits(_0x1ff3da[_0x27985a(0x176)],_0x334d61[_0x27985a(0x187)]),{'ok':!![],'data':runtimePermitWriteResult(_0x27985a(0x189)+_0x334d61[_0x27985a(0x198)],{'roleId':_0x334d61[_0x27985a(0x178)]['id'],'datasetCodes':_0x334d61['datasetCodes'],'actions':_0x334d61['actions']},_0x334d61[_0x27985a(0x181)],_0x334d61[_0x27985a(0x16d)],{'method':_0x27985a(0x192),'path':_0x27985a(0x197)},_0x334d61[_0x27985a(0x193)])};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a40_0x236c(){const _0x1b5faf=['9csFDdI','3303902igZWLv','180356AERUot','190jgNYCi','267312fYjsES','981IycghR','1310286POTtwy','3905464jCPkfh','44838uipEGY','5wOJIwU','5552XIGwJB'];a40_0x236c=function(){return _0x1b5faf;};return a40_0x236c();}(function(_0x41f0aa,_0xe66ce2){const _0x15391e=a40_0x6608,_0x44ed83=_0x41f0aa();while(!![]){try{const _0x40e7be=parseInt(_0x15391e(0x98))/0x1+-parseInt(_0x15391e(0x9c))/0x2+parseInt(_0x15391e(0x99))/0x3*(-parseInt(_0x15391e(0x9e))/0x4)+-parseInt(_0x15391e(0x9d))/0x5*(-parseInt(_0x15391e(0x9a))/0x6)+-parseInt(_0x15391e(0x95))/0x7+parseInt(_0x15391e(0x9b))/0x8*(parseInt(_0x15391e(0x9f))/0x9)+parseInt(_0x15391e(0x97))/0xa*(parseInt(_0x15391e(0x96))/0xb);if(_0x40e7be===_0xe66ce2)break;else _0x44ed83['push'](_0x44ed83['shift']());}catch(_0x221711){_0x44ed83['push'](_0x44ed83['shift']());}}}(a40_0x236c,0x524df));import{permitPageGet}from'../../commands/permit/page-get.js';import{permitPageSet}from'../../commands/permit/page-set.js';import{permitRoleMenus}from'../../commands/permit/role-menus.js';import{permitRoleMenusSet}from'../../commands/permit/role-menus-set.js';import{permitDatasetGet}from'../../commands/permit/dataset-get.js';function a40_0x6608(_0x2683e3,_0x594005){_0x2683e3=_0x2683e3-0x95;const _0x236c2f=a40_0x236c();let _0x660899=_0x236c2f[_0x2683e3];return _0x660899;}import{permitDatasetSet}from'../../commands/permit/dataset-set.js';export const permitDefinitions=[permitPageGet,permitPageSet,permitRoleMenus,permitRoleMenusSet,permitDatasetGet,permitDatasetSet];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a41_0x455f(){const _0x42f318=['menu-id','8266070cjMkWf','11TxUvkq','185348hYTeqb','142JZmlmN','Get\x20runtime\x20page\x20permission\x20slots\x20by\x20menu\x20ID','6213ozVkjr','1958785TkoWGs','3818997qNejxS','32AhIMUZ','page-get','43841MCFOzm','permit','15wjhBRT','num','2552808mAdfnM'];a41_0x455f=function(){return _0x42f318;};return a41_0x455f();}const a41_0x37537d=a41_0x28a0;(function(_0x94b63d,_0xc8c892){const _0x43caf4=a41_0x28a0,_0x20a786=_0x94b63d();while(!![]){try{const _0x48cda8=parseInt(_0x43caf4(0x12f))/0x1*(parseInt(_0x43caf4(0x12d))/0x2)+parseInt(_0x43caf4(0x136))/0x3*(parseInt(_0x43caf4(0x12c))/0x4)+-parseInt(_0x43caf4(0x130))/0x5+-parseInt(_0x43caf4(0x138))/0x6+parseInt(_0x43caf4(0x134))/0x7*(-parseInt(_0x43caf4(0x132))/0x8)+-parseInt(_0x43caf4(0x131))/0x9+parseInt(_0x43caf4(0x12a))/0xa*(parseInt(_0x43caf4(0x12b))/0xb);if(_0x48cda8===_0xc8c892)break;else _0x20a786['push'](_0x20a786['shift']());}catch(_0x3f356d){_0x20a786['push'](_0x20a786['shift']());}}}(a41_0x455f,0x38d65));import{getRuntimePagePermit}from'../../core/api-client.js';function a41_0x28a0(_0x474e5b,_0x2f7346){_0x474e5b=_0x474e5b-0x129;const _0x455f73=a41_0x455f();let _0x28a033=_0x455f73[_0x474e5b];return _0x28a033;}import{MENU_ID_FLAG,projectRuntimePagePermit}from'../../commands/permit/shared.js';export const permitPageGet={'service':a41_0x37537d(0x135),'command':a41_0x37537d(0x133),'description':a41_0x37537d(0x12e),'risk':'read','flags':[MENU_ID_FLAG],async 'execute'(_0x199c9a){const _0x4c6cc7=a41_0x37537d,_0x33488c=await getRuntimePagePermit(_0x199c9a[_0x4c6cc7(0x137)](_0x4c6cc7(0x129)));return{'ok':!![],'data':{'scope':'runtime','page':projectRuntimePagePermit(_0x33488c)}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a42_0x479691=a42_0x4318;(function(_0xdc31f4,_0x25e4bf){const _0x4efff1=a42_0x4318,_0x3ff50b=_0xdc31f4();while(!![]){try{const _0x44debf=-parseInt(_0x4efff1(0x148))/0x1*(parseInt(_0x4efff1(0x146))/0x2)+-parseInt(_0x4efff1(0x14c))/0x3+-parseInt(_0x4efff1(0x164))/0x4*(parseInt(_0x4efff1(0x14a))/0x5)+parseInt(_0x4efff1(0x156))/0x6*(-parseInt(_0x4efff1(0x160))/0x7)+parseInt(_0x4efff1(0x147))/0x8+parseInt(_0x4efff1(0x151))/0x9+parseInt(_0x4efff1(0x14b))/0xa;if(_0x44debf===_0x25e4bf)break;else _0x3ff50b['push'](_0x3ff50b['shift']());}catch(_0x50d8cc){_0x3ff50b['push'](_0x3ff50b['shift']());}}}(a42_0x499d,0xeb026));function a42_0x4318(_0xb5acd2,_0x58bebd){_0xb5acd2=_0xb5acd2-0x145;const _0x499d22=a42_0x499d();let _0x431880=_0x499d22[_0xb5acd2];return _0x431880;}function a42_0x499d(){const _0x24aac2=['Page\x20menu\x20','20eowalF','25927760KscAOU','602901HXZyut','permit','Menu\x20','str','menuId','11189898kmTvhP','page-set','Preview:\x20update\x20page\x20permission\x20slots\x20','menu-id','page','6PQJBGC','allowSelf','rolePermit','key','\x20does\x20not\x20belong\x20to\x20app\x20','Set\x20selected\x20runtime\x20page\x20permission\x20slots','join','build','flag','num','7162939JincAO','validation','slots','push','1487944voELwB','POST','appCode','修改指定运行页面的角色权限槽位;未获授权的用户可能无法查看页面或执行数据操作。','length','body','/client/permit/page/save','Pass\x20at\x20least\x20one\x20page\x20role\x20flag\x20to\x20update.','524ksMVWd','9327840rXxNjf','5066BNtvvX'];a42_0x499d=function(){return _0x24aac2;};return a42_0x499d();}import{getRuntimePagePermit,saveRuntimePagePermit}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';import{assertRuntimePermissionManager,MENU_ID_FLAG,PAGE_ROLE_FLAGS,PAGE_SLOT_SPECS,projectRuntimePagePermit,resolveRuntimePermitRoles,runtimePermitWriteResult,splitRefs}from'../../commands/permit/shared.js';async function prepare(_0x303a38){const _0xdae0b4=a42_0x4318;await assertRuntimePermissionManager(_0x303a38['appCode']);const _0x1803ac=_0x303a38[_0xdae0b4(0x15f)](_0xdae0b4(0x154)),_0x5d3870=await getRuntimePagePermit(_0x1803ac);if(_0x5d3870[_0xdae0b4(0x166)]&&_0x5d3870[_0xdae0b4(0x166)]!==_0x303a38[_0xdae0b4(0x166)])throw CliErrors[_0xdae0b4(0x161)](_0xdae0b4(0x14e)+_0x1803ac+_0xdae0b4(0x15a)+_0x303a38[_0xdae0b4(0x166)]+'.');const _0xaebe04=structuredClone(_0x5d3870),_0x3e56cb=[];for(const _0x2d62db of PAGE_SLOT_SPECS){if(_0x303a38[_0xdae0b4(0x15e)](_0x2d62db['flag'])===undefined)continue;const _0x35fd84=_0x5d3870[_0x2d62db[_0xdae0b4(0x159)]];if(!_0x35fd84)throw CliErrors['validation'](_0xdae0b4(0x149)+_0x1803ac+'\x20does\x20not\x20expose\x20'+_0x2d62db[_0xdae0b4(0x159)]+'.');_0x35fd84[_0xdae0b4(0x158)]=await resolveRuntimePermitRoles(_0x303a38[_0xdae0b4(0x166)],splitRefs(_0x303a38[_0xdae0b4(0x14f)](_0x2d62db[_0xdae0b4(0x15e)]),'--'+_0x2d62db['flag']),_0x2d62db[_0xdae0b4(0x157)]),_0x3e56cb[_0xdae0b4(0x163)](_0x2d62db[_0xdae0b4(0x159)]);}if(_0x3e56cb[_0xdae0b4(0x168)]===0x0)throw CliErrors[_0xdae0b4(0x161)](_0xdae0b4(0x145));return{'menuId':_0x1803ac,'page':_0x5d3870,'before':_0xaebe04,'slots':_0x3e56cb};}export const permitPageSet={'service':a42_0x479691(0x14d),'command':a42_0x479691(0x152),'description':a42_0x479691(0x15b),'risk':'high-risk-write','confirmationDescription':a42_0x479691(0x167),'flags':[MENU_ID_FLAG,...PAGE_ROLE_FLAGS],async 'dryRun'(_0x4135c2){const _0x4e87dc=a42_0x479691,_0x1cccc8=await prepare(_0x4135c2);return dryRun(_0x4e87dc(0x165),_0x4e87dc(0x16a))[_0x4e87dc(0x169)](_0x1cccc8[_0x4e87dc(0x155)])['description'](_0x4e87dc(0x153)+_0x1cccc8[_0x4e87dc(0x162)][_0x4e87dc(0x15c)](',\x20'))[_0x4e87dc(0x15d)]();},async 'execute'(_0x467655){const _0x5ad8b7=a42_0x479691,_0x53c1a3=await prepare(_0x467655),_0x13f3bd=await saveRuntimePagePermit(_0x53c1a3['page']);return{'ok':!![],'data':runtimePermitWriteResult(_0x5ad8b7(0x152),{'menuId':_0x53c1a3[_0x5ad8b7(0x150)],'slots':_0x53c1a3[_0x5ad8b7(0x162)]},projectRuntimePagePermit(_0x53c1a3['before']),projectRuntimePagePermit(_0x13f3bd),{'method':_0x5ad8b7(0x165),'path':_0x5ad8b7(0x16a)})};}};
|