@lovrabet/lovrabet-cli 2.2.4-beta.2 → 2.2.4
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.d.ts +19 -0
- 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/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 +4 -4
- package/skills/lovrabet/references/lovrabet-ocr-workflow.md +17 -2
- package/skills/lovrabet.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a84_0x151f01=a84_0x26fe;(function(_0x10d70c,_0x1ed510){const _0x568798=a84_0x26fe,_0x5c5519=_0x10d70c();while(!![]){try{const _0x308bea=parseInt(_0x568798(0xf1))/0x1+-parseInt(_0x568798(0xe1))/0x2+parseInt(_0x568798(0xde))/0x3*(parseInt(_0x568798(0xe3))/0x4)+-parseInt(_0x568798(0xf9))/0x5*(-parseInt(_0x568798(0xf7))/0x6)+-parseInt(_0x568798(0xf0))/0x7*(parseInt(_0x568798(0xfb))/0x8)+parseInt(_0x568798(0xe2))/0x9+-parseInt(_0x568798(0xfa))/0xa*(parseInt(_0x568798(0xdc))/0xb);if(_0x308bea===_0x1ed510)break;else _0x5c5519['push'](_0x5c5519['shift']());}catch(_0x507c7a){_0x5c5519['push'](_0x5c5519['shift']());}}}(a84_0x3278,0x26ace));function a84_0x3278(){const _0x1612ea=['233958HSPmBP','(empty)','toLowerCase','132WmBGmp','139374kHwxBe','4sQdMYX','trim','Retry\x20with\x20the\x20same\x20--provider\x20and\x20--account-id\x20only\x20after\x20checking\x20the\x20current\x20AccessKey\x20identity.','write','External\x20account\x20provider','External\x20account\x20binding\x20was\x20not\x20confirmed.','dingtalk','Unsupported\x20provider:\x20','user-account','validation','includes','The\x20current\x20binding\x20is\x20not\x20exposed\x20by\x20the\x20server;\x20before\x20is\x20unavailable.','Pass\x20the\x20external\x20account\x20ID\x20for\x20the\x20selected\x20provider.','7efzcSP','193740hgfoeJ','string','Pass\x20one\x20of:\x20','account-id','Bound\x20current\x20user\x20to\x20external\x20provider\x20account.','apiError','6bvolxR','bind','778895LhJVvE','10anpcbv','1217176WnfJzd','provider','1456004WhZFxU','join'];a84_0x3278=function(){return _0x1612ea;};return a84_0x3278();}import{bindExternalUserAccount,USER_ACCOUNT_BIND_PATH}from'../../core/api-client.js';function a84_0x26fe(_0x479ed8,_0x23de5b){_0x479ed8=_0x479ed8-0xdc;const _0x32787a=a84_0x3278();let _0x26fef7=_0x32787a[_0x479ed8];return _0x26fef7;}import{CliErrors}from'../../errors.js';const CURRENT_BINDING_WARNING=a84_0x151f01(0xee),SUPPORTED_PROVIDERS=[a84_0x151f01(0xe9)];function readBindingInput(_0x555fda){const _0x3fa5f4=a84_0x151f01,_0x291008=_0x555fda['str'](_0x3fa5f4(0xfc))['trim']()[_0x3fa5f4(0xe0)]();if(!SUPPORTED_PROVIDERS[_0x3fa5f4(0xed)](_0x291008))throw CliErrors[_0x3fa5f4(0xec)](_0x3fa5f4(0xea)+(_0x291008||_0x3fa5f4(0xdf))+'.',_0x3fa5f4(0xf3)+SUPPORTED_PROVIDERS[_0x3fa5f4(0xdd)](',\x20')+'.');const _0x1973dd=_0x555fda['str'](_0x3fa5f4(0xf4))[_0x3fa5f4(0xe4)]();if(!_0x1973dd)throw CliErrors[_0x3fa5f4(0xec)]('--account-id\x20cannot\x20be\x20empty.',_0x3fa5f4(0xef));return{'provider':_0x291008,'accountId':_0x1973dd};}function buildBindingData(_0x33297d,_0x4b5098,_0x2e66f2){const _0x317984=a84_0x151f01;return{'operation':_0x317984(0xf8),'selector':{'provider':_0x33297d,'accountId':_0x4b5098},'before':null,'after':{'provider':_0x33297d,'accountId':_0x4b5098,'bound':!![]},'dryRun':_0x2e66f2,'warnings':[CURRENT_BINDING_WARNING]};}export const bindUserAccount={'service':a84_0x151f01(0xeb),'command':'bind','description':'Bind\x20the\x20current\x20platform\x20user\x20to\x20an\x20external\x20provider\x20account','risk':a84_0x151f01(0xe6),'confirmationDescription':'将当前\x20AccessKey\x20所属的平台用户绑定到指定协同生态外部账号;已有同\x20provider\x20绑定可能被替换。','requiresAuth':!![],'requiresAppCode':![],'flags':[{'name':a84_0x151f01(0xfc),'type':a84_0x151f01(0xf2),'required':!![],'enum':[...SUPPORTED_PROVIDERS],'description':a84_0x151f01(0xe7)},{'name':'account-id','type':'string','required':!![],'description':'External\x20account\x20ID\x20for\x20the\x20selected\x20provider'}],async 'validate'(_0x40d01f){readBindingInput(_0x40d01f);},async 'dryRun'(_0x11b135){const {provider:_0x4f679c,accountId:_0x26ec37}=readBindingInput(_0x11b135);return{...buildBindingData(_0x4f679c,_0x26ec37,!![]),'method':'POST','url':USER_ACCOUNT_BIND_PATH,'body':{'provider':_0x4f679c,'accountId':_0x26ec37}};},async 'execute'(_0x2f00b2){const _0xfe3162=a84_0x151f01,{provider:_0x4bd555,accountId:_0x3101d9}=readBindingInput(_0x2f00b2),_0x39ab00=await bindExternalUserAccount(_0x4bd555,_0x3101d9);if(_0x39ab00!==!![])throw CliErrors[_0xfe3162(0xf6)](_0xfe3162(0xe8),_0xfe3162(0xe5));return{'ok':!![],'data':buildBindingData(_0x4bd555,_0x3101d9,![]),'message':_0xfe3162(0xf5)};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2b29f2,_0x524ec5){const _0x5834ac=a85_0x566b,_0x37cb29=_0x2b29f2();while(!![]){try{const _0x29bf28=parseInt(_0x5834ac(0x1ef))/0x1*(-parseInt(_0x5834ac(0x1f7))/0x2)+parseInt(_0x5834ac(0x1ee))/0x3+-parseInt(_0x5834ac(0x1f5))/0x4*(-parseInt(_0x5834ac(0x1f0))/0x5)+-parseInt(_0x5834ac(0x1f4))/0x6+parseInt(_0x5834ac(0x1ed))/0x7*(parseInt(_0x5834ac(0x1f2))/0x8)+-parseInt(_0x5834ac(0x1f6))/0x9+parseInt(_0x5834ac(0x1f3))/0xa*(parseInt(_0x5834ac(0x1f1))/0xb);if(_0x29bf28===_0x524ec5)break;else _0x37cb29['push'](_0x37cb29['shift']());}catch(_0x2d123a){_0x37cb29['push'](_0x37cb29['shift']());}}}(a85_0x53c0,0x84d62));import{bindUserAccount}from'../../commands/user-account/bind.js';function a85_0x566b(_0x8be840,_0x4e94ae){_0x8be840=_0x8be840-0x1ed;const _0x53c0a8=a85_0x53c0();let _0x566b95=_0x53c0a8[_0x8be840];return _0x566b95;}export const userAccountDefinitions=[bindUserAccount];function a85_0x53c0(){const _0x3fdbff=['8myAspK','10zBnazR','2051670OqZmEi','1108256dlUTjZ','5031531vzotgT','2AfYobm','3343844pVnDgi','1625850lzWOEA','431981MJaYTI','15itAPKh','288739RcdHSc'];a85_0x53c0=function(){return _0x3fdbff;};return a85_0x53c0();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a86_0xc663cb=a86_0x23dd;(function(_0x5d167b,_0x397624){const _0x13e5cc=a86_0x23dd,_0x442382=_0x5d167b();while(!![]){try{const _0x2a6c6d=parseInt(_0x13e5cc(0x19a))/0x1*(parseInt(_0x13e5cc(0x1a7))/0x2)+-parseInt(_0x13e5cc(0x1b8))/0x3+-parseInt(_0x13e5cc(0x191))/0x4+parseInt(_0x13e5cc(0x18d))/0x5*(-parseInt(_0x13e5cc(0x18a))/0x6)+parseInt(_0x13e5cc(0x1b0))/0x7*(-parseInt(_0x13e5cc(0x1ad))/0x8)+parseInt(_0x13e5cc(0x199))/0x9*(parseInt(_0x13e5cc(0x1ac))/0xa)+-parseInt(_0x13e5cc(0x192))/0xb*(-parseInt(_0x13e5cc(0x1a4))/0xc);if(_0x2a6c6d===_0x397624)break;else _0x442382['push'](_0x442382['shift']());}catch(_0x4bfd31){_0x442382['push'](_0x442382['shift']());}}}(a86_0x29db,0x3ce27));import{CLI_BIN_NAME}from'../../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../../constant/defaults.js';import{RUNTIME_ENV_VALUES}from'../../constant/env.js';import{CliErrors}from'../../errors.js';import{readConfigFile,resolveWriteConfigPath,writeConfigFile}from'../../context.js';function a86_0x23dd(_0x48b853,_0x401b2d){_0x48b853=_0x48b853-0x186;const _0x29db91=a86_0x29db();let _0x23dd3d=_0x29db91[_0x48b853];return _0x23dd3d;}import{findAppByName,isRuntimeAccessibleApp,runtimeInaccessibleAppError}from'../../commands/app/eligibility.js';const WORKSPACE_USE_FLAGS=[{'name':a86_0xc663cb(0x18c),'type':a86_0xc663cb(0x19f),'description':a86_0xc663cb(0x1ae)},{'name':a86_0xc663cb(0x1bb),'type':a86_0xc663cb(0x19f),'description':a86_0xc663cb(0x1b6)},{'name':'env','type':a86_0xc663cb(0x19f),'description':'Target\x20environment','enum':[...RUNTIME_ENV_VALUES]}];async function executeWorkspaceUse(_0x4a0d86,_0x3336bb){const _0x323f75=a86_0xc663cb,_0x362ccc=_0x4a0d86[_0x323f75(0x1b9)](_0x323f75(0x18c))[_0x323f75(0x1a0)](),_0x34ae5c=_0x4a0d86[_0x323f75(0x1b9)](_0x323f75(0x1bb))['trim'](),_0x25434e=_0x4a0d86[_0x323f75(0x1b9)](_0x323f75(0x1bd))[_0x323f75(0x1a0)](),_0x5a8636=resolveWorkspaceEnv(_0x25434e||_0x4a0d86[_0x323f75(0x1b7)]||DEFAULT_CONFIG_VALUES['env']);if(!_0x362ccc&&!_0x34ae5c)throw CliErrors[_0x323f75(0x197)](_0x323f75(0x1b4),'Usage:\x20'+CLI_BIN_NAME+_0x323f75(0x198)+_0x3336bb+'\x20--app\x20<name>\x20[--env\x20daily]\x20or\x20'+CLI_BIN_NAME+_0x323f75(0x198)+_0x3336bb+_0x323f75(0x1b3));if(_0x362ccc&&_0x34ae5c)throw CliErrors['validation'](_0x323f75(0x1c7),'Pass\x20either\x20--app\x20<name>\x20or\x20--appcode\x20<code>,\x20not\x20both.');const _0xc52be6=resolveWriteConfigPath(_0x323f75(0x18f)),_0x26caa5=readConfigFile(_0xc52be6);assertWorkspaceCommandState(_0x3336bb,_0x26caa5);const _0x24b1ad=_0x34ae5c||await resolveRemoteAppCode({'command':_0x3336bb,'appName':_0x362ccc,'env':_0x5a8636,'accessKey':_0x4a0d86[_0x323f75(0x1c1)]});return writeWorkspaceConfig({'command':_0x3336bb,'appName':_0x362ccc,'appcode':_0x24b1ad,'env':_0x5a8636,'shouldWriteEnv':!!_0x25434e,'accessKey':_0x4a0d86['accessKey']},_0xc52be6,_0x26caa5),{'ok':!![],'data':{'configPath':_0xc52be6,'app':_0x362ccc||null,'appcode':_0x24b1ad,'env':_0x25434e?_0x5a8636:null,'accessKeyWritten':![],'command':_0x323f75(0x1a9)+_0x3336bb},'message':buildWorkspaceMessage(_0xc52be6,_0x362ccc,_0x24b1ad,_0x25434e?_0x5a8636:undefined)};}async function resolveRemoteAppCode(_0x1c6d37){const _0x4e8da6=a86_0xc663cb;if(!_0x1c6d37[_0x4e8da6(0x1c1)])throw CliErrors['authRequired'](_0x4e8da6(0x1ab)+CLI_BIN_NAME+_0x4e8da6(0x198)+_0x1c6d37[_0x4e8da6(0x1c2)]+'.');const {setActiveAK:_0x157744}=await import(_0x4e8da6(0x186)),{getRemoteAppList:_0x4455ee}=await import(_0x4e8da6(0x19c));_0x157744(_0x1c6d37[_0x4e8da6(0x1c1)]);const _0x5bfdb3=await _0x4455ee({'env':_0x1c6d37['env'],'accessKey':_0x1c6d37['accessKey'],'noCache':![]}),_0x2b18e0=findAppByName(_0x5bfdb3[_0x4e8da6(0x1b2)],_0x1c6d37[_0x4e8da6(0x1bc)]);if(_0x2b18e0&&!isRuntimeAccessibleApp(_0x2b18e0))throw runtimeInaccessibleAppError(_0x2b18e0,'\x22'+_0x1c6d37[_0x4e8da6(0x1bc)]+'\x22');const _0x5a107f=_0x2b18e0?.[_0x4e8da6(0x1bf)]?.[_0x4e8da6(0x1a0)]();if(_0x5a107f)return _0x5a107f;const _0x23705f=_0x5bfdb3['items'][_0x4e8da6(0x19b)](_0x3c093a=>_0x3c093a['appName'])[_0x4e8da6(0x1af)](Boolean),_0x313ecc=_0x23705f[_0x4e8da6(0x1c5)]?_0x4e8da6(0x1b5)+Array[_0x4e8da6(0x1c0)](new Set(_0x23705f))[_0x4e8da6(0x1c3)](',\x20')+'.':_0x4e8da6(0x1aa)+CLI_BIN_NAME+_0x4e8da6(0x1be);throw CliErrors[_0x4e8da6(0x197)](_0x4e8da6(0x190)+_0x1c6d37[_0x4e8da6(0x1bc)]+_0x4e8da6(0x1c6),_0x313ecc);}function writeWorkspaceConfig(_0x2f1406,_0x3a8d76,_0x1f73ea){const _0x15d808=a86_0xc663cb;_0x2f1406['shouldWriteEnv']&&(_0x1f73ea[_0x15d808(0x1bd)]=_0x2f1406[_0x15d808(0x1bd)]);if(_0x2f1406[_0x15d808(0x1bc)]){const _0x49eef8=isRecord(_0x1f73ea['apps'])?{..._0x1f73ea['apps']}:{},_0x2e254d=isRecord(_0x49eef8[_0x2f1406['appName']])?_0x49eef8[_0x2f1406[_0x15d808(0x1bc)]]:{};return _0x49eef8[_0x2f1406[_0x15d808(0x1bc)]]={..._0x2e254d,'appcode':_0x2f1406[_0x15d808(0x1bb)]},_0x1f73ea['apps']=_0x49eef8,_0x1f73ea['defaultApp']=_0x2f1406[_0x15d808(0x1bc)],delete _0x1f73ea['appcode'],delete _0x1f73ea[_0x15d808(0x18c)],writeAndReturn(_0x3a8d76,_0x1f73ea);}return _0x1f73ea['appcode']=_0x2f1406[_0x15d808(0x1bb)],delete _0x1f73ea[_0x15d808(0x189)],delete _0x1f73ea['app'],writeAndReturn(_0x3a8d76,_0x1f73ea);}function writeAndReturn(_0x438106,_0x41799d){return writeConfigFile(_0x438106,_0x41799d),_0x438106;}function a86_0x29db(){const _0x56141e=['Workspace\x20app\x20context\x20is\x20already\x20initialized.','workspace\x20','Run\x20`','Resolving\x20--app\x20requires\x20accessKey.\x20Pass\x20--appcode\x20directly,\x20or\x20set\x20accessKey\x20before\x20running\x20','430qTNQet','32sdttkA','App\x20name\x20to\x20bind\x20as\x20the\x20current\x20workspace\x20default','filter','680176AImDIF','use','items','\x20--appcode\x20<code>\x20[--env\x20daily]','Missing\x20workspace\x20app\x20selector.','Available\x20apps:\x20','App\x20code\x20to\x20bind\x20directly','envName','876885ONGghm','str','\x0aDefault\x20app:\x20','appcode','appName','env','\x20app\x20list\x20--no-cache`\x20to\x20refresh\x20available\x20apps,\x20or\x20pass\x20--appcode\x20directly.','appCode','from','accessKey','command','join','includes','length','\x22\x20not\x20found.','Conflicting\x20workspace\x20app\x20selectors.','修改当前工作目录已有绑定的应用上下文','workspace','../../core/api-client.js','object','isArray','defaultApp','102mtJftJ','Invalid\x20env\x20\x22','app','46600XAMuxj','\x20workspace\x20init\x20--appcode\x20<code>`\x20first.','project','App\x20\x22','625096BWzijP','11JHPYYo','init','\x20workspace\x20init\x20--app\x20<name>`\x20or\x20`','write','apps','validation','\x20workspace\x20','99378HBcLTm','6115UYsJYQ','map','../../commands/app/remote-source.js','将更新当前工作目录已有的应用绑定,并把所选应用设为该目录的默认应用;不会写入\x20AccessKey。','Use\x20`','string','trim','Workspace\x20configured.\x0aConfig\x20file:\x20','\x0aEnv:\x20','将在尚未绑定应用的当前工作目录写入\x20Lovrabet\x20项目配置,并把所选应用设为该目录的默认应用;不会写入\x20AccessKey。','6014376WORDJM','\x20workspace\x20use\x20--app\x20<name>`\x20or\x20`','\x20workspace\x20use\x20--appcode\x20<code>`\x20to\x20change\x20it.','88ZZZUTC'];a86_0x29db=function(){return _0x56141e;};return a86_0x29db();}function resolveWorkspaceEnv(_0x506304){const _0x135174=a86_0xc663cb;if(RUNTIME_ENV_VALUES[_0x135174(0x1c4)](_0x506304))return _0x506304;throw CliErrors['validation'](_0x135174(0x18b)+_0x506304+'\x22.\x20Allowed:\x20'+RUNTIME_ENV_VALUES[_0x135174(0x1c3)](',\x20'));}function buildWorkspaceMessage(_0x2fcba4,_0x29bfe5,_0x2d45b7,_0x52b23c){const _0x1435ae=a86_0xc663cb,_0x56506a=_0x29bfe5?_0x29bfe5+'\x20('+_0x2d45b7+')':_0x2d45b7,_0x5d1d8f=_0x52b23c?_0x1435ae(0x1a2)+_0x52b23c:'';return _0x1435ae(0x1a1)+_0x2fcba4+_0x1435ae(0x1ba)+_0x56506a+_0x5d1d8f+'\x0aAccessKey:\x20not\x20written';}function isRecord(_0xb3ef5){const _0x6eeb07=a86_0xc663cb;return typeof _0xb3ef5===_0x6eeb07(0x187)&&_0xb3ef5!==null&&!Array[_0x6eeb07(0x188)](_0xb3ef5);}function hasWorkspaceAppBinding(_0x35bddd){const _0x394fb4=a86_0xc663cb;if(typeof _0x35bddd['appcode']===_0x394fb4(0x19f)&&_0x35bddd['appcode'][_0x394fb4(0x1a0)]()[_0x394fb4(0x1c5)]>0x0)return!![];if(typeof _0x35bddd['defaultApp']!==_0x394fb4(0x19f)||!_0x35bddd[_0x394fb4(0x189)][_0x394fb4(0x1a0)]())return![];if(!isRecord(_0x35bddd[_0x394fb4(0x196)]))return![];const _0x5030b4=_0x35bddd[_0x394fb4(0x196)][_0x35bddd[_0x394fb4(0x189)][_0x394fb4(0x1a0)]()];return isRecord(_0x5030b4)&&typeof _0x5030b4[_0x394fb4(0x1bb)]===_0x394fb4(0x19f)&&_0x5030b4['appcode'][_0x394fb4(0x1a0)]()['length']>0x0;}function assertWorkspaceCommandState(_0x49f9e9,_0x3bae63){const _0x25ce82=a86_0xc663cb,_0x902b9f=hasWorkspaceAppBinding(_0x3bae63);if(_0x49f9e9===_0x25ce82(0x193)&&_0x902b9f)throw CliErrors[_0x25ce82(0x197)](_0x25ce82(0x1a8),_0x25ce82(0x19e)+CLI_BIN_NAME+_0x25ce82(0x1a5)+CLI_BIN_NAME+_0x25ce82(0x1a6));if(_0x49f9e9===_0x25ce82(0x1b1)&&!_0x902b9f)throw CliErrors[_0x25ce82(0x197)]('Workspace\x20app\x20context\x20is\x20not\x20initialized.',_0x25ce82(0x1aa)+CLI_BIN_NAME+_0x25ce82(0x194)+CLI_BIN_NAME+_0x25ce82(0x18e));}function makeWorkspaceCommand(_0x1e59d7){const _0x50e409=a86_0xc663cb;return{'service':_0x50e409(0x1c9),'command':_0x1e59d7,'description':_0x1e59d7==='init'?'为尚未绑定应用的当前工作目录初始化应用上下文':_0x50e409(0x1c8),'risk':_0x50e409(0x195),'confirmationDescription':_0x1e59d7===_0x50e409(0x193)?_0x50e409(0x1a3):_0x50e409(0x19d),'requiresAuth':![],'requiresAppCode':![],'hasFormat':!![],'flags':WORKSPACE_USE_FLAGS,async 'execute'(_0x39a257){return executeWorkspaceUse(_0x39a257,_0x1e59d7);}};}export const workspaceDefinitions=[makeWorkspaceCommand(a86_0xc663cb(0x193)),makeWorkspaceCommand(a86_0xc663cb(0x1b1))];
|
package/lib/config/schema.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a87_0x148212=a87_0x15d2;(function(_0x37dacf,_0x3d04b0){const _0x46d755=a87_0x15d2,_0x5c331b=_0x37dacf();while(!![]){try{const _0x11fa66=parseInt(_0x46d755(0x1b1))/0x1*(-parseInt(_0x46d755(0x19a))/0x2)+-parseInt(_0x46d755(0x19c))/0x3*(parseInt(_0x46d755(0x1a8))/0x4)+parseInt(_0x46d755(0x1b5))/0x5*(parseInt(_0x46d755(0x1a2))/0x6)+parseInt(_0x46d755(0x196))/0x7*(parseInt(_0x46d755(0x1b6))/0x8)+parseInt(_0x46d755(0x197))/0x9+-parseInt(_0x46d755(0x19e))/0xa*(parseInt(_0x46d755(0x1ac))/0xb)+parseInt(_0x46d755(0x1ab))/0xc;if(_0x11fa66===_0x3d04b0)break;else _0x5c331b['push'](_0x5c331b['shift']());}catch(_0x40b0e6){_0x5c331b['push'](_0x5c331b['shift']());}}}(a87_0x1172,0xd596e));import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{RUNTIME_ENV_VALUES}from'../constant/env.js';import{OUTPUT_FORMAT_VALUES}from'../constant/output.js';export const CONFIG_FIELD_SCHEMAS={'env':{'description':a87_0x148212(0x199),'topLevel':!![],'cliSettableTopLevel':!![],'enumValues':RUNTIME_ENV_VALUES,'defaultValue':DEFAULT_CONFIG_VALUES[a87_0x148212(0x19d)],'importable':!![]},'format':{'description':a87_0x148212(0x1ae),'topLevel':!![],'cliSettableTopLevel':!![],'enumValues':OUTPUT_FORMAT_VALUES,'defaultValue':DEFAULT_CONFIG_VALUES[a87_0x148212(0x1b3)],'importable':!![]},'pageSize':{'description':a87_0x148212(0x1b2),'topLevel':!![],'cliSettableTopLevel':!![],'importable':!![]},'apiDomain':{'description':a87_0x148212(0x1a1),'topLevel':!![],'cliSettableTopLevel':!![],'importable':!![]},'userDomain':{'description':a87_0x148212(0x1a0),'topLevel':!![],'cliSettableTopLevel':!![],'importable':!![]},'runtimeDomain':{'description':a87_0x148212(0x1ad),'topLevel':!![],'cliSettableTopLevel':!![],'importable':!![]},'skillHubDomain':{'description':a87_0x148212(0x1af),'topLevel':!![],'cliSettableTopLevel':!![],'importable':!![]},'accessKey':{'description':a87_0x148212(0x1a3),'topLevel':!![],'cliSettableTopLevel':!![],'importable':!![]},'riskLevel':{'description':a87_0x148212(0x1b9),'topLevel':!![],'defaultValue':DEFAULT_CONFIG_VALUES[a87_0x148212(0x1a5)],'importable':!![]},'locale':{'description':a87_0x148212(0x1b7),'topLevel':!![],'defaultValue':DEFAULT_CONFIG_VALUES[a87_0x148212(0x1aa)],'importable':!![],'legacyCompatOnly':!![]}};export const TOP_LEVEL_CONFIG_KEYS=new Set(Object['entries'](CONFIG_FIELD_SCHEMAS)[a87_0x148212(0x1b8)](([,_0x53ec35])=>_0x53ec35['cliSettableTopLevel'])['map'](([_0x2a0061])=>_0x2a0061));export const CONFIG_ENUM_VALUES=Object[a87_0x148212(0x1a9)](Object[a87_0x148212(0x1a4)](CONFIG_FIELD_SCHEMAS)[a87_0x148212(0x1b8)](([,_0x257eb3])=>_0x257eb3[a87_0x148212(0x198)])[a87_0x148212(0x19b)](([_0x26bfb5,_0x4da353])=>[_0x26bfb5,[..._0x4da353[a87_0x148212(0x198)]||[]]]));export const IMPORTABLE_RUNTIME_CONFIG_KEYS=Object['entries'](CONFIG_FIELD_SCHEMAS)[a87_0x148212(0x1b8)](([,_0x2f2e5e])=>_0x2f2e5e[a87_0x148212(0x19f)])[a87_0x148212(0x19b)](([_0x4c34e2])=>_0x4c34e2);export function getConfigFieldSchema(_0x1b6dcc){return CONFIG_FIELD_SCHEMAS[_0x1b6dcc];}function a87_0x1172(){const _0x5ba331=['filter','Risk\x20level','14yFEiNH','5214780nWvxzi','enumValues','Target\x20environment','3358252KkCkDD','map','4947828bsVFOa','env','122770dztZHQ','importable','Override\x20user\x20domain','Override\x20API\x20domain','354JZfsUN','Access\x20key\x20(client-ak\x20auth)','entries','riskLevel',';\x20local\x20alias:\x20apps.<alias>.appcode','legacyCompatOnly','4yWSLge','fromEntries','locale','29465724rJRjLt','44tYqrnt','Override\x20runtime\x20domain','Default\x20output\x20format','Override\x20SkillHub\x20domain','Config\x20key.\x20Top-level:\x20','1pTkZQW','Default\x20page\x20size','format','join','65cRzGyO','4866832twXkBv','Locale'];a87_0x1172=function(){return _0x5ba331;};return a87_0x1172();}export function getConfigEnumValues(_0x18453b){const _0x251e20=a87_0x148212;return getConfigFieldSchema(_0x18453b)?.[_0x251e20(0x198)];}export function getConfigDefaultValue(_0x315496){return getConfigFieldSchema(_0x315496)?.['defaultValue'];}export function isTopLevelConfigKey(_0x269e7c){return TOP_LEVEL_CONFIG_KEYS['has'](_0x269e7c);}export function isLegacyCompatConfigKey(_0x14b83e){const _0x215cef=a87_0x148212;return getConfigFieldSchema(_0x14b83e)?.[_0x215cef(0x1a7)]===!![];}export function getTopLevelConfigKeyList(){return[...TOP_LEVEL_CONFIG_KEYS];}export function formatConfigKeyList(_0x53764b){const _0x219afc=a87_0x148212;return[..._0x53764b][_0x219afc(0x1b4)](',\x20');}function a87_0x15d2(_0xaa9c62,_0x40df93){_0xaa9c62=_0xaa9c62-0x196;const _0x1172f4=a87_0x1172();let _0x15d24d=_0x1172f4[_0xaa9c62];return _0x15d24d;}export function getTopLevelConfigKeySummary(){return formatConfigKeyList(getTopLevelConfigKeyList());}export function getConfigCommandKeyDescription(){const _0x45116d=a87_0x148212;return _0x45116d(0x1b0)+getTopLevelConfigKeySummary()+_0x45116d(0x1a6);}export function buildAppProfileListFields(_0x5930ea){return{'env':_0x5930ea,'hasAccessKey':![],'format':null,'pageSize':null,'riskLevel':null,'locale':null};}
|
package/lib/constant/app.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a88_0x55c308=a88_0x3128;(function(_0x4cb796,_0x4a0548){const _0x34f649=a88_0x3128,_0xed6b72=_0x4cb796();while(!![]){try{const _0x539b3e=-parseInt(_0x34f649(0xab))/0x1+parseInt(_0x34f649(0xa9))/0x2+parseInt(_0x34f649(0xa8))/0x3*(-parseInt(_0x34f649(0xb0))/0x4)+parseInt(_0x34f649(0xa6))/0x5*(-parseInt(_0x34f649(0xaa))/0x6)+parseInt(_0x34f649(0xa7))/0x7+-parseInt(_0x34f649(0xae))/0x8+-parseInt(_0x34f649(0xad))/0x9*(-parseInt(_0x34f649(0xaf))/0xa);if(_0x539b3e===_0x4a0548)break;else _0xed6b72['push'](_0xed6b72['shift']());}catch(_0x28eb14){_0xed6b72['push'](_0xed6b72['shift']());}}}(a88_0x3246,0x6343b));export const APP_PUBLISH_STATUS={'Published':a88_0x55c308(0xac),'Unpublished':'UNPUBLISH'};function a88_0x3128(_0x25f2a3,_0x15290d){_0x25f2a3=_0x25f2a3-0xa6;const _0x32464d=a88_0x3246();let _0x31283a=_0x32464d[_0x25f2a3];return _0x31283a;}export const RUNTIME_ACCESSIBLE_APP_STATUS=APP_PUBLISH_STATUS['Published'];function a88_0x3246(){const _0x16518b=['18PJqWtI','220653foyZvU','PUBLISHED','477CsaoiJ','4110736CCYbbH','116350DITGoM','4iLaIlJ','353655aoLSph','2883391LDeekY','566967LWubGr','1027392WNDagK'];a88_0x3246=function(){return _0x16518b;};return a88_0x3246();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a89_0x4275de=a89_0x1f35;function a89_0x1f35(_0x280381,_0x195d56){_0x280381=_0x280381-0x180;const _0x3f08ea=a89_0x3f08();let _0x1f35b3=_0x3f08ea[_0x280381];return _0x1f35b3;}(function(_0x51d568,_0x356bc5){const _0x480364=a89_0x1f35,_0x4dd51d=_0x51d568();while(!![]){try{const _0x23bc89=-parseInt(_0x480364(0x183))/0x1*(-parseInt(_0x480364(0x182))/0x2)+parseInt(_0x480364(0x180))/0x3+parseInt(_0x480364(0x181))/0x4*(-parseInt(_0x480364(0x184))/0x5)+-parseInt(_0x480364(0x188))/0x6+parseInt(_0x480364(0x186))/0x7+parseInt(_0x480364(0x18a))/0x8+-parseInt(_0x480364(0x185))/0x9*(parseInt(_0x480364(0x18b))/0xa);if(_0x23bc89===_0x356bc5)break;else _0x4dd51d['push'](_0x4dd51d['shift']());}catch(_0x2704dc){_0x4dd51d['push'](_0x4dd51d['shift']());}}}(a89_0x3f08,0x4bd22));export const AUTH_MODE={'ClientAk':a89_0x4275de(0x187)};function a89_0x3f08(){const _0x10ba32=['4209940yWDOul','1701639mYPWNG','2356ZkBeba','93230ENbYPD','3jfVMRj','2570RuUSWS','18lnJbqM','3889004XHpIkW','client-ak','2303838vmYWWM','ClientAk','4613112SdUKpZ'];a89_0x3f08=function(){return _0x10ba32;};return a89_0x3f08();}export function isAuthMode(_0x5bda58){const _0x1c6f94=a89_0x4275de;return _0x5bda58===AUTH_MODE[_0x1c6f94(0x189)];}
|
package/lib/constant/cli.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a90_0x52e1fe=a90_0x1508;(function(_0x3945be,_0x288886){const _0x176fe1=a90_0x1508,_0x59e62a=_0x3945be();while(!![]){try{const _0x1b6d5e=-parseInt(_0x176fe1(0xce))/0x1*(parseInt(_0x176fe1(0xee))/0x2)+-parseInt(_0x176fe1(0xe9))/0x3+parseInt(_0x176fe1(0xc1))/0x4*(-parseInt(_0x176fe1(0xec))/0x5)+parseInt(_0x176fe1(0xdd))/0x6+parseInt(_0x176fe1(0xc3))/0x7*(-parseInt(_0x176fe1(0xe7))/0x8)+parseInt(_0x176fe1(0xd9))/0x9*(-parseInt(_0x176fe1(0xf4))/0xa)+parseInt(_0x176fe1(0xcf))/0xb*(parseInt(_0x176fe1(0xf3))/0xc);if(_0x1b6d5e===_0x288886)break;else _0x59e62a['push'](_0x59e62a['shift']());}catch(_0x8a41c){_0x59e62a['push'](_0x59e62a['shift']());}}}(a90_0xa178,0x99c20));import{PRODUCT_CONFIG}from'../constant/product.js';import{LOVRABET_NPM_PACKAGE_NAME}from'../constant/distribution.js';export const CLI_BIN_NAME=PRODUCT_CONFIG[a90_0x52e1fe(0xcd)];export const CLI_DISPLAY_NAME=PRODUCT_CONFIG[a90_0x52e1fe(0xc7)];export const NPM_PACKAGE_NAME=LOVRABET_NPM_PACKAGE_NAME;function a90_0xa178(){const _0x30ae52=['nonInteractive','Verbose\x20output','<expr>','cliDisplayName','Select\x20app\x20profile\x20by\x20name','fromEntries','boolean','Force\x20non-interactive\x20mode\x20(CI)','Show\x20help','cliBinName','17mxjdeD','2519ivTohi','clear','meowKey','appcode','string','production\x20|\x20development\x20|\x20daily','name','Name\x20filter','format','env','1449963UMuarX','json\x20|\x20pretty\x20|\x20compress','Clear\x20output','sqlcode','3456390GwRkzu','Use\x20global\x20config\x20scope','dryRun','yes','<name>','Override\x20appcode','params','dry-run','help','Environment','610672NswNHj','global','3150093vPafCC','Preview\x20operation\x20without\x20executing','Record\x20ID','185aYuvXi','Filter\x20JSON\x20output\x20(JQ_PATH\x20>\x20bundled\x20jq\x20>\x20PATH;\x20implies\x20--format\x20json\x20when\x20current\x20format\x20is\x20pretty)','3234LZvwjE','type','Skip\x20confirmation\x20for\x20high-risk\x20writes','Output\x20format','non-interactive','105348kXGAVN','10JmXYcm','Alias\x20for\x20--non-interactive','verbose','36364Yfkkap','SQL\x20query\x20code','35zdPGDo'];a90_0xa178=function(){return _0x30ae52;};return a90_0xa178();}export const GLOBAL_FLAGS=[{'name':a90_0x52e1fe(0xd2),'meowKey':a90_0x52e1fe(0xd2),'type':'string','description':a90_0x52e1fe(0xe2),'hint':'<code>'},{'name':'app','meowKey':'app','type':'string','description':a90_0x52e1fe(0xc8),'hint':a90_0x52e1fe(0xe1)},{'name':a90_0x52e1fe(0xd8),'meowKey':a90_0x52e1fe(0xd8),'type':a90_0x52e1fe(0xd3),'description':a90_0x52e1fe(0xe6),'hint':a90_0x52e1fe(0xd4)},{'name':'format','meowKey':a90_0x52e1fe(0xd7),'type':a90_0x52e1fe(0xd3),'description':a90_0x52e1fe(0xf1),'hint':a90_0x52e1fe(0xda)},{'name':'jq','meowKey':'jq','type':a90_0x52e1fe(0xd3),'description':a90_0x52e1fe(0xed),'hint':a90_0x52e1fe(0xc6)},{'name':a90_0x52e1fe(0xe4),'meowKey':a90_0x52e1fe(0xdf),'type':a90_0x52e1fe(0xca),'description':a90_0x52e1fe(0xea)},{'name':a90_0x52e1fe(0xe0),'meowKey':a90_0x52e1fe(0xe0),'type':a90_0x52e1fe(0xca),'description':a90_0x52e1fe(0xf0)},{'name':'non-interactive','meowKey':a90_0x52e1fe(0xc4),'type':a90_0x52e1fe(0xca),'description':a90_0x52e1fe(0xcb)},{'name':a90_0x52e1fe(0xe8),'meowKey':a90_0x52e1fe(0xe8),'type':a90_0x52e1fe(0xca),'description':a90_0x52e1fe(0xde)},{'name':'ci','meowKey':'ci','type':a90_0x52e1fe(0xca),'description':a90_0x52e1fe(0xf5),'hidden':!![]},{'name':a90_0x52e1fe(0xe5),'meowKey':a90_0x52e1fe(0xe5),'type':a90_0x52e1fe(0xca),'description':a90_0x52e1fe(0xcc)},{'name':'id','meowKey':'id','type':'string','description':a90_0x52e1fe(0xeb),'hidden':!![]},{'name':'name','meowKey':a90_0x52e1fe(0xd5),'type':a90_0x52e1fe(0xd3),'description':a90_0x52e1fe(0xd6),'hidden':!![]},{'name':'sqlcode','meowKey':a90_0x52e1fe(0xdc),'type':a90_0x52e1fe(0xd3),'description':a90_0x52e1fe(0xc2),'hidden':!![]},{'name':a90_0x52e1fe(0xe3),'meowKey':a90_0x52e1fe(0xe3),'type':a90_0x52e1fe(0xd3),'description':'JSON\x20params\x20for\x20execute\x20commands','hidden':!![]},{'name':'verbose','meowKey':a90_0x52e1fe(0xc0),'type':a90_0x52e1fe(0xca),'description':a90_0x52e1fe(0xc5),'hidden':!![]},{'name':a90_0x52e1fe(0xd0),'meowKey':a90_0x52e1fe(0xd0),'type':'boolean','description':a90_0x52e1fe(0xdb),'hidden':!![]}];export const PIPELINE_FLAG_NAMES=new Set([a90_0x52e1fe(0xd2),'app',a90_0x52e1fe(0xd8),a90_0x52e1fe(0xd7),'jq',a90_0x52e1fe(0xe4),a90_0x52e1fe(0xe0),a90_0x52e1fe(0xf2),'ci']);function a90_0x1508(_0x4e774d,_0xa572c0){_0x4e774d=_0x4e774d-0xc0;const _0xa17871=a90_0xa178();let _0x150882=_0xa17871[_0x4e774d];return _0x150882;}export function buildMeowFlags(){const _0x3c0812=a90_0x52e1fe;return Object[_0x3c0812(0xc9)](GLOBAL_FLAGS['map'](_0x2aa696=>[_0x2aa696[_0x3c0812(0xd1)],{'type':_0x2aa696[_0x3c0812(0xef)]}]));}
|
package/lib/constant/defaults.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a91_0x2381(){const _0x99ff75=['4065210xaNoWR','40940eybStX','main','write','3359280QMXlFh','114EiaHEA','3OAdivP','1121142TEiklg','7rvPMDP','429420CdpUkB','528689qKCHlG','4243728dUTyPO','compress'];a91_0x2381=function(){return _0x99ff75;};return a91_0x2381();}function a91_0x23de(_0x523f1e,_0x360773){_0x523f1e=_0x523f1e-0xf7;const _0x238128=a91_0x2381();let _0x23de87=_0x238128[_0x523f1e];return _0x23de87;}const a91_0x154f21=a91_0x23de;(function(_0x543992,_0xa08ee6){const _0x479213=a91_0x23de,_0x26d9be=_0x543992();while(!![]){try{const _0x593210=parseInt(_0x479213(0xfc))/0x1+-parseInt(_0x479213(0xf9))/0x2+-parseInt(_0x479213(0xf8))/0x3*(-parseInt(_0x479213(0xfb))/0x4)+parseInt(_0x479213(0x100))/0x5*(-parseInt(_0x479213(0xf7))/0x6)+parseInt(_0x479213(0xfa))/0x7*(parseInt(_0x479213(0xfd))/0x8)+-parseInt(_0x479213(0xff))/0x9+parseInt(_0x479213(0x103))/0xa;if(_0x593210===_0xa08ee6)break;else _0x26d9be['push'](_0x26d9be['shift']());}catch(_0xc4872d){_0x26d9be['push'](_0x26d9be['shift']());}}}(a91_0x2381,0x51b0d));export const DEFAULT_APP_PROFILE_NAME=a91_0x154f21(0x101);export const DEFAULT_CONFIG_VALUES={'env':'production','format':a91_0x154f21(0xfe),'locale':'en-US','riskLevel':a91_0x154f21(0x102)};export const DEFAULT_COMMAND_OUTPUT_FORMAT=a91_0x154f21(0xfe);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a92_0x148e(_0x45287d,_0x25be0d){_0x45287d=_0x45287d-0x189;const _0x330e84=a92_0x330e();let _0x148e50=_0x330e84[_0x45287d];return _0x148e50;}const a92_0x3fbcf0=a92_0x148e;(function(_0x210ffd,_0x2f0c0c){const _0x512eae=a92_0x148e,_0x4498e4=_0x210ffd();while(!![]){try{const _0x451595=parseInt(_0x512eae(0x192))/0x1*(parseInt(_0x512eae(0x193))/0x2)+parseInt(_0x512eae(0x18f))/0x3*(parseInt(_0x512eae(0x18d))/0x4)+parseInt(_0x512eae(0x191))/0x5*(-parseInt(_0x512eae(0x18e))/0x6)+parseInt(_0x512eae(0x18a))/0x7+-parseInt(_0x512eae(0x189))/0x8*(parseInt(_0x512eae(0x18c))/0x9)+parseInt(_0x512eae(0x190))/0xa+parseInt(_0x512eae(0x18b))/0xb*(-parseInt(_0x512eae(0x195))/0xc);if(_0x451595===_0x2f0c0c)break;else _0x4498e4['push'](_0x4498e4['shift']());}catch(_0x3ed821){_0x4498e4['push'](_0x4498e4['shift']());}}}(a92_0x330e,0x72462));import{PRODUCT_CONFIG}from'../constant/product.js';function a92_0x330e(){const _0x5ba305=['156868NRtnBN','3192tUsGoG','21WPYZyE','5517360wyeYlE','5395fyrvyp','6IPRXYA','89686oxtJMm','skillSource','53016dPYcIL','npmPackageName','1642288cUcSDH','6055847bVRxQQ','242EgbsUY','36YDDBuL'];a92_0x330e=function(){return _0x5ba305;};return a92_0x330e();}export const LOVRABET_NPM_PACKAGE_NAME=PRODUCT_CONFIG[a92_0x3fbcf0(0x196)];export const LOVRABET_SKILL_SOURCE=PRODUCT_CONFIG[a92_0x3fbcf0(0x194)];export const NPM_REGISTRY_BASE_URL=PRODUCT_CONFIG['npmRegistryBaseUrl'];
|
package/lib/constant/domain.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a93_0x5532(_0x4adb47,_0x255331){_0x4adb47=_0x4adb47-0x159;const _0x46bded=a93_0x46bd();let _0x55320a=_0x46bded[_0x4adb47];return _0x55320a;}const a93_0x3a14dc=a93_0x5532;(function(_0x4102ed,_0x59573f){const _0x16bb37=a93_0x5532,_0x31abf8=_0x4102ed();while(!![]){try{const _0x232931=-parseInt(_0x16bb37(0x15a))/0x1*(parseInt(_0x16bb37(0x166))/0x2)+-parseInt(_0x16bb37(0x162))/0x3+parseInt(_0x16bb37(0x15f))/0x4+-parseInt(_0x16bb37(0x165))/0x5+parseInt(_0x16bb37(0x161))/0x6*(parseInt(_0x16bb37(0x159))/0x7)+-parseInt(_0x16bb37(0x168))/0x8+parseInt(_0x16bb37(0x15c))/0x9*(parseInt(_0x16bb37(0x160))/0xa);if(_0x232931===_0x59573f)break;else _0x31abf8['push'](_0x31abf8['shift']());}catch(_0x3f449a){_0x31abf8['push'](_0x31abf8['shift']());}}}(a93_0x46bd,0x5e5b8));import{getEnv,isProduction}from'../constant/env.js';import{PRODUCT_CONFIG}from'../constant/product.js';let customApiDomain,customUserDomain,customRuntimeDomain,customSkillHubDomain;export function initDomains(_0x59d600){const _0x2bbc40=a93_0x5532;customApiDomain=_0x59d600?.[_0x2bbc40(0x164)],customUserDomain=_0x59d600?.[_0x2bbc40(0x15e)],customRuntimeDomain=_0x59d600?.[_0x2bbc40(0x16b)],customSkillHubDomain=_0x59d600?.[_0x2bbc40(0x15d)];}export const getUserDomain=()=>customUserDomain||(isProduction(getEnv())?PRODUCT_CONFIG[a93_0x3a14dc(0x167)]['production'][a93_0x3a14dc(0x16d)]:PRODUCT_CONFIG[a93_0x3a14dc(0x167)][a93_0x3a14dc(0x16c)][a93_0x3a14dc(0x16d)]);export const getApiDomain=()=>customApiDomain||(isProduction(getEnv())?PRODUCT_CONFIG[a93_0x3a14dc(0x167)][a93_0x3a14dc(0x163)][a93_0x3a14dc(0x169)]:PRODUCT_CONFIG['domains'][a93_0x3a14dc(0x16c)][a93_0x3a14dc(0x169)]);function a93_0x46bd(){const _0x475a3f=['18VqcfkZ','skillHubDomain','userDomain','1280876EeWbNW','5717330GBumkM','438lWGWNF','730443iJMcbL','production','apiDomain','212280sdvuAg','26822RZGPaz','domains','2497184HpgZrv','api','runtime','runtimeDomain','nonProduction','user','24787ryRphD','55efnqPd','skillhub'];a93_0x46bd=function(){return _0x475a3f;};return a93_0x46bd();}export const getRuntimeDomain=()=>customRuntimeDomain||(isProduction(getEnv())?PRODUCT_CONFIG[a93_0x3a14dc(0x167)][a93_0x3a14dc(0x163)]['runtime']:PRODUCT_CONFIG[a93_0x3a14dc(0x167)][a93_0x3a14dc(0x16c)][a93_0x3a14dc(0x16a)]);export const getSkillHubDomain=()=>customSkillHubDomain||(isProduction(getEnv())?PRODUCT_CONFIG[a93_0x3a14dc(0x167)][a93_0x3a14dc(0x163)][a93_0x3a14dc(0x15b)]:PRODUCT_CONFIG[a93_0x3a14dc(0x167)][a93_0x3a14dc(0x16c)][a93_0x3a14dc(0x15b)]);
|
package/lib/constant/env.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a94_0x1d532a=a94_0x144e;(function(_0x1994bd,_0x2017e3){const _0x4ad287=a94_0x144e,_0x104f8c=_0x1994bd();while(!![]){try{const _0x1920f0=-parseInt(_0x4ad287(0x121))/0x1+-parseInt(_0x4ad287(0x11e))/0x2+parseInt(_0x4ad287(0x125))/0x3+parseInt(_0x4ad287(0x123))/0x4*(parseInt(_0x4ad287(0x124))/0x5)+parseInt(_0x4ad287(0x126))/0x6+parseInt(_0x4ad287(0x11f))/0x7+-parseInt(_0x4ad287(0x120))/0x8;if(_0x1920f0===_0x2017e3)break;else _0x104f8c['push'](_0x104f8c['shift']());}catch(_0x59791c){_0x104f8c['push'](_0x104f8c['shift']());}}}(a94_0x220f,0x5d735));import{productEnv}from'../constant/product.js';function a94_0x144e(_0x75a93f,_0x20d933){_0x75a93f=_0x75a93f-0x11e;const _0x220fa0=a94_0x220f();let _0x144e59=_0x220fa0[_0x75a93f];return _0x144e59;}function a94_0x220f(){const _0x39e057=['4200852iObxql','production','dev','493252xeVWMK','4535363NtOcrQ','11948480EHWSqd','71803QRzZKn','daily','1658140JTZvIO','5qhLniz','1296528NYvDus'];a94_0x220f=function(){return _0x39e057;};return a94_0x220f();}export const RUNTIME_ENV_VALUES=[a94_0x1d532a(0x127),'development',a94_0x1d532a(0x122)];export function normalizeEnv(_0x19e596){const _0x4f9a9a=a94_0x1d532a;return _0x19e596==='online'?_0x4f9a9a(0x127):_0x19e596;}export function isProduction(_0x5aaabc){const _0x36bfa6=a94_0x1d532a;return normalizeEnv(_0x5aaabc)===_0x36bfa6(0x127);}export function isDaily(_0xfcad18){return normalizeEnv(_0xfcad18)==='daily';}export function isDev(_0x5ec86c){const _0x47c93d=a94_0x1d532a,_0x19438e=normalizeEnv(_0x5ec86c);return _0x19438e==='development'||_0x19438e===_0x47c93d(0x128);}let env=normalizeEnv(productEnv('ENV')||a94_0x1d532a(0x127));export function getEnv(){return env;}export function initEnv(_0x1a7cc5){env=normalizeEnv(_0x1a7cc5);}
|
package/lib/constant/output.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a95_0x27fa2a=a95_0x2888;function a95_0x2888(_0x566190,_0x33fb04){_0x566190=_0x566190-0x1f4;const _0x2239ea=a95_0x2239();let _0x288812=_0x2239ea[_0x566190];return _0x288812;}function a95_0x2239(){const _0x22f710=['2144110mkLyks','1169940NhCskR','2219242TXxlFL','15186352Hjmkqy','pretty','92888YUFSxA','39684105nvsnzW','compress','7RsCxSa','11385774OpVHIo','4AuQWbc','json'];a95_0x2239=function(){return _0x22f710;};return a95_0x2239();}(function(_0x5ad998,_0x1b3ee8){const _0x37aea7=a95_0x2888,_0x3d08ec=_0x5ad998();while(!![]){try{const _0x4cdd99=parseInt(_0x37aea7(0x1f8))/0x1+parseInt(_0x37aea7(0x1f5))/0x2+-parseInt(_0x37aea7(0x1f4))/0x3+parseInt(_0x37aea7(0x1fd))/0x4*(-parseInt(_0x37aea7(0x1ff))/0x5)+-parseInt(_0x37aea7(0x1fc))/0x6+-parseInt(_0x37aea7(0x1fb))/0x7*(parseInt(_0x37aea7(0x1f6))/0x8)+parseInt(_0x37aea7(0x1f9))/0x9;if(_0x4cdd99===_0x1b3ee8)break;else _0x3d08ec['push'](_0x3d08ec['shift']());}catch(_0xa7d852){_0x3d08ec['push'](_0x3d08ec['shift']());}}}(a95_0x2239,0xf3709));export const OUTPUT_FORMAT_VALUES=[a95_0x27fa2a(0x1fe),a95_0x27fa2a(0x1f7),a95_0x27fa2a(0x1fa)];
|
package/lib/constant/product.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a96_0x4d2a(_0x11e542,_0x552015){_0x11e542=_0x11e542-0x1f0;const _0x473257=a96_0x4732();let _0x4d2a9f=_0x473257[_0x11e542];return _0x4d2a9f;}function a96_0x4732(){const _0x179479=['https://runtime.lovrabet.com','lovrabet/lovrabet-cli','15ZDxwMa','RABETBASE','legacyEnvPrefixes','cli:lovrabet-runtime','29248370pwwroE','168XNwQOz','1252296eEjDHa','218072yqBwXO','https://api.lovrabet.com','lovrabet','464097aoUOzB','https://skills-daily.lovrabet.com','https://user.lovrabet.com','envPrefix','101818NWyvaf','Lovrabet\x20Runtime\x20CLI','LOVRABET','https://daily-runtime.lovrabet.com','SKIP_NPX_SKILLS','https://registry.npmjs.org','/user/ak','@lovrabet/lovrabet-cli','map','.lovrabet-runtime.log','git@codeup.aliyun.com:yuntoo/open/lovrabet-runtime-cli.git','3258872kODLWp','18UaKBdL','1999884pXvinZ'];a96_0x4732=function(){return _0x179479;};return a96_0x4732();}const a96_0x30283b=a96_0x4d2a;(function(_0x1958e1,_0x22e312){const _0x1fd0b1=a96_0x4d2a,_0xfcbb19=_0x1958e1();while(!![]){try{const _0x1c1699=parseInt(_0x1fd0b1(0x204))/0x1*(-parseInt(_0x1fd0b1(0x1f2))/0x2)+-parseInt(_0x1fd0b1(0x200))/0x3+-parseInt(_0x1fd0b1(0x1f1))/0x4+-parseInt(_0x1fd0b1(0x1f6))/0x5*(parseInt(_0x1fd0b1(0x1f3))/0x6)+parseInt(_0x1fd0b1(0x1fb))/0x7*(parseInt(_0x1fd0b1(0x1fd))/0x8)+-parseInt(_0x1fd0b1(0x1fc))/0x9+parseInt(_0x1fd0b1(0x1fa))/0xa;if(_0x1c1699===_0x22e312)break;else _0xfcbb19['push'](_0xfcbb19['shift']());}catch(_0x5ea0b3){_0xfcbb19['push'](_0xfcbb19['shift']());}}}(a96_0x4732,0x874cc));export const PRODUCT_CONFIG={'cliBinName':'lovrabet','cliDisplayName':a96_0x30283b(0x205),'npmPackageName':a96_0x30283b(0x20b),'skillSource':a96_0x30283b(0x1f5),'internalSkillSource':a96_0x30283b(0x1f0),'globalSkillName':a96_0x30283b(0x1ff),'npmRegistryBaseUrl':a96_0x30283b(0x209),'envPrefix':a96_0x30283b(0x206),'legacyEnvPrefixes':[a96_0x30283b(0x1f7)],'configFileNames':['.lovrabet.json','.lovrabetrc'],'newConfigFileName':'.lovrabet.json','homeDirName':'.lovrabet','logFileName':a96_0x30283b(0x20d),'invokeSource':a96_0x30283b(0x1f9),'userCenterDisplayName':'Lovrabet\x20User\x20Center','skipNpxSkillsEnvSuffix':a96_0x30283b(0x208),'domains':{'production':{'user':a96_0x30283b(0x202),'api':a96_0x30283b(0x1fe),'runtime':a96_0x30283b(0x1f4),'skillhub':'https://skills.lovrabet.com'},'nonProduction':{'user':'https://user-daily.lovrabet.com','api':'https://daily-api.lovrabet.com','runtime':a96_0x30283b(0x207),'skillhub':a96_0x30283b(0x201)}},'accessKeyCreatePath':a96_0x30283b(0x20a)};export function productEnvName(_0x55da89){const _0x2e3b80=a96_0x30283b;return PRODUCT_CONFIG[_0x2e3b80(0x203)]+'_'+_0x55da89;}export function productEnvNames(_0x48f152){const _0x4f3954=a96_0x30283b;return[productEnvName(_0x48f152),...PRODUCT_CONFIG[_0x4f3954(0x1f8)][_0x4f3954(0x20c)](_0x31c28c=>_0x31c28c+'_'+_0x48f152)];}export function productEnv(_0x3be63b){for(const _0x5429d7 of productEnvNames(_0x3be63b)){const _0x3ed047=process.env[_0x5429d7];if(_0x3ed047!==undefined)return _0x3ed047;}return undefined;}
|
package/lib/constant/risk.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a97_0x43addf=a97_0x6447;function a97_0x389a(){const _0x3e6d05=['write','7YjUzxQ','77052jSPDJV','125040FbcTdy','103809VmlMTO','read','270720siHjoF','3wbiwwq','380382CGWWBN','889020zZUGLJ','484857JiHuro','high-risk-write'];a97_0x389a=function(){return _0x3e6d05;};return a97_0x389a();}function a97_0x6447(_0x1ca031,_0x2cb3c7){_0x1ca031=_0x1ca031-0x144;const _0x389a49=a97_0x389a();let _0x644712=_0x389a49[_0x1ca031];return _0x644712;}(function(_0x20060b,_0x20991f){const _0x34c358=a97_0x6447,_0x33d17f=_0x20060b();while(!![]){try{const _0x4f4d51=parseInt(_0x34c358(0x14c))/0x1+parseInt(_0x34c358(0x144))/0x2*(-parseInt(_0x34c358(0x14f))/0x3)+-parseInt(_0x34c358(0x14e))/0x4+parseInt(_0x34c358(0x145))/0x5+parseInt(_0x34c358(0x14a))/0x6*(parseInt(_0x34c358(0x149))/0x7)+parseInt(_0x34c358(0x14b))/0x8+parseInt(_0x34c358(0x146))/0x9;if(_0x4f4d51===_0x20991f)break;else _0x33d17f['push'](_0x33d17f['shift']());}catch(_0x3a2636){_0x33d17f['push'](_0x33d17f['shift']());}}}(a97_0x389a,0x19e67));export const RISK_LEVEL_VALUES=[a97_0x43addf(0x14d),a97_0x43addf(0x148),a97_0x43addf(0x147)];
|
package/lib/constant/url.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a98_0x4bf8b4=a98_0x4cc5;function a98_0xfc94(){const _0x593ebc=['4690420GbHwGI','836467uwVFnd','4526328rUVxRm','domains','1399089tMTSvK','5109216ucGwgO','accessKeyCreatePath','user','production','4094525IsfpbB','2475094TmbFUv'];a98_0xfc94=function(){return _0x593ebc;};return a98_0xfc94();}(function(_0x42beb7,_0x25b15b){const _0x2a8539=a98_0x4cc5,_0x186146=_0x42beb7();while(!![]){try{const _0x4be6d0=parseInt(_0x2a8539(0x142))/0x1+-parseInt(_0x2a8539(0x140))/0x2+parseInt(_0x2a8539(0x145))/0x3+parseInt(_0x2a8539(0x146))/0x4+parseInt(_0x2a8539(0x13f))/0x5+-parseInt(_0x2a8539(0x143))/0x6+-parseInt(_0x2a8539(0x141))/0x7;if(_0x4be6d0===_0x25b15b)break;else _0x186146['push'](_0x186146['shift']());}catch(_0x2e137a){_0x186146['push'](_0x186146['shift']());}}}(a98_0xfc94,0xb3f14));import{PRODUCT_CONFIG}from'../constant/product.js';function a98_0x4cc5(_0x149dd9,_0x51be6f){_0x149dd9=_0x149dd9-0x13c;const _0xfc9489=a98_0xfc94();let _0x4cc5f8=_0xfc9489[_0x149dd9];return _0x4cc5f8;}export const USER_ACCESS_KEY_CREATE_URL=''+PRODUCT_CONFIG[a98_0x4bf8b4(0x144)][a98_0x4bf8b4(0x13e)][a98_0x4bf8b4(0x13d)]+PRODUCT_CONFIG[a98_0x4bf8b4(0x13c)];
|
package/lib/context.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const a99_0x4229ec=a99_0x3de0;(function(_0x148b64,_0x57c094){const _0x1fc884=a99_0x3de0,_0x549c85=_0x148b64();while(!![]){try{const _0x8f9b02=-parseInt(_0x1fc884(0xf8))/0x1*(-parseInt(_0x1fc884(0xf7))/0x2)+-parseInt(_0x1fc884(0x10d))/0x3*(parseInt(_0x1fc884(0xc5))/0x4)+-parseInt(_0x1fc884(0xca))/0x5*(parseInt(_0x1fc884(0xe8))/0x6)+-parseInt(_0x1fc884(0xe1))/0x7+-parseInt(_0x1fc884(0x108))/0x8*(parseInt(_0x1fc884(0x10c))/0x9)+-parseInt(_0x1fc884(0xf6))/0xa*(-parseInt(_0x1fc884(0xd9))/0xb)+-parseInt(_0x1fc884(0xcd))/0xc*(-parseInt(_0x1fc884(0xda))/0xd);if(_0x8f9b02===_0x57c094)break;else _0x549c85['push'](_0x549c85['shift']());}catch(_0x4c2863){_0x549c85['push'](_0x549c85['shift']());}}}(a99_0x5774,0xb1271));import{readFileSync,existsSync,mkdirSync,renameSync,unlinkSync,writeFileSync}from'node:fs';function a99_0x5774(){const _0x24a665=['runtimeDomain','3197601qotkyr','3351345orpruk','riskLevel','maxRisk','newConfigFileName','4TUUHWd','env','high-risk-write','missing','object','1614590WpAZvN','values','stdin','12TkFhuo','nonInteractive','explicit','code','ENV','stdout','some','parse','.tmp','apiDomain','skillHubDomain','./constant/domain.js','5599ZoGlSR','47718658nguCIO','cwd','read','string','isTTY','PAGE_SIZE','local-alias','7065744OaSkkn','appcode','global','top-level','locale','APPCODE','projectConfig','6hJcbKX','configFileNames','slice','trim','cache','true','EXDEV','find','APP','setLogPath','authRequired','FORMAT','inherit','globalConfig','1090VsLvOw','2HrsRgJ','514762Nbwclu','setRawMode','project','EACCES','./constant/env.js','format','online','app','daily','raw','join','VERBOSE','accessKey','production','utf8','empty','24umWHPh','defaultApp','apps'];a99_0x5774=function(){return _0x24a665;};return a99_0x5774();}import{resolve,dirname}from'node:path';import{homedir}from'node:os';import{logger}from'./utils/logger.js';import{CliErrors}from'./errors.js';function a99_0x3de0(_0x28eec3,_0x4aac61){_0x28eec3=_0x28eec3-0xc3;const _0x57745f=a99_0x5774();let _0x3de084=_0x57745f[_0x28eec3];return _0x3de084;}import{CLI_BIN_NAME}from'./constant/cli.js';import{PRODUCT_CONFIG,productEnv,productEnvNames}from'./constant/product.js';import{DEFAULT_CONFIG_VALUES}from'./constant/defaults.js';import{normalizeEnv,isDaily,isDev}from'./constant/env.js';import{normalizeLegacyOutputFormat}from'./framework/types.js';import{resolveCachedAppCode}from'./commands/app/cache.js';export{AUTH_MODE,isAuthMode}from'./constant/auth-mode.js';const CONFIG_NAMES=PRODUCT_CONFIG[a99_0x4229ec(0xe9)];export const NEW_CONFIG_NAME=PRODUCT_CONFIG[a99_0x4229ec(0xc4)];function resolveConfigPath(_0x568a5e){for(const _0x1b2ede of CONFIG_NAMES){const _0x1c35f8=resolve(_0x568a5e,_0x1b2ede);if(existsSync(_0x1c35f8))return _0x1c35f8;}return undefined;}export function resolveWriteConfigPath(_0x18665b){const _0x5f4931=a99_0x4229ec,_0x59e33d=_0x18665b===_0x5f4931(0xfa)?process[_0x5f4931(0xdb)]():homedir(),_0x9f3395=resolveConfigPath(_0x59e33d);return _0x9f3395??resolve(_0x59e33d,NEW_CONFIG_NAME);}export function readConfigFile(_0x3715a7){const _0x56c583=a99_0x4229ec;try{if(existsSync(_0x3715a7)){const _0x48952f=readFileSync(_0x3715a7,{'encoding':_0x56c583(0x106)});if(_0x48952f){const _0x1ed836=JSON['parse'](_0x48952f);return migrateOnlineEnv(_0x3715a7,_0x1ed836),_0x1ed836;}}}catch{}return{};}function migrateOnlineEnv(_0x328850,_0x5c07b5){const _0x578df4=a99_0x4229ec;let _0x931b7a=![];_0x5c07b5[_0x578df4(0xc6)]===_0x578df4(0xfe)&&(_0x5c07b5[_0x578df4(0xc6)]='production',_0x931b7a=!![]);if(_0x5c07b5[_0x578df4(0x10a)]&&typeof _0x5c07b5[_0x578df4(0x10a)]===_0x578df4(0xc9))for(const _0x45ea4e of Object[_0x578df4(0xcb)](_0x5c07b5[_0x578df4(0x10a)])){_0x45ea4e&&_0x45ea4e['env']===_0x578df4(0xfe)&&(_0x45ea4e[_0x578df4(0xc6)]=_0x578df4(0x105),_0x931b7a=!![]);}if(_0x931b7a)try{writeConfigFile(_0x328850,_0x5c07b5);}catch{}}export function writeConfigFile(_0x2e1cbd,_0x1e2814){const _0x1dd3e4=a99_0x4229ec,_0x494761=dirname(_0x2e1cbd);!existsSync(_0x494761)&&mkdirSync(_0x494761,{'recursive':!![]});const _0x2e2f70=_0x2e1cbd+_0x1dd3e4(0xd5);try{writeFileSync(_0x2e2f70,JSON['stringify'](_0x1e2814,null,0x2)+'\x0a',{'encoding':'utf8','mode':0x180});try{renameSync(_0x2e2f70,_0x2e1cbd);}catch(_0x5229db){if(_0x5229db['code']==='EPERM'||_0x5229db[_0x1dd3e4(0xd0)]===_0x1dd3e4(0xee)||_0x5229db[_0x1dd3e4(0xd0)]===_0x1dd3e4(0xfb)){writeFileSync(_0x2e1cbd,JSON['stringify'](_0x1e2814,null,0x2)+'\x0a',{'encoding':_0x1dd3e4(0x106)});try{unlinkSync(_0x2e2f70);}catch{}}else throw _0x5229db;}}catch(_0x1c504f){try{unlinkSync(_0x2e2f70);}catch{}throw _0x1c504f;}}export function isNonInteractiveMode(_0x2d43f1){const _0x23519f=a99_0x4229ec;return!!(_0x2d43f1[_0x23519f(0xce)]||_0x2d43f1['ci']||productEnvNames('CI')[_0x23519f(0xd3)](_0x3b4642=>process.env[_0x3b4642]==='true')||process.env.CI===_0x23519f(0xed)||!process[_0x23519f(0xd2)]['isTTY']||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x20b61c=a99_0x4229ec;if(!process[_0x20b61c(0xcc)][_0x20b61c(0xde)])return![];try{const _0xc4371d=process[_0x20b61c(0xcc)]['isRaw'];return process[_0x20b61c(0xcc)]['setRawMode'](!![]),process[_0x20b61c(0xcc)][_0x20b61c(0xf9)](_0xc4371d??![]),!![];}catch{return![];}}export async function createContext(_0x4476ce){const _0x4713cb=a99_0x4229ec,_0x5b07d4=readRawConfig(),_0x301178=buildConfig(_0x5b07d4,_0x4476ce);await initGlobalEnvironment(_0x301178);const {getUserDomain:_0x1af7e5,getApiDomain:_0x40a44f}=await import('./constant/domain.js'),_0x5af938={'apiDomain':_0x40a44f(),'userDomain':_0x1af7e5()},_0x56701e=await buildAuth(_0x301178);logger[_0x4713cb(0xf1)](process['cwd']());const _0x37c4dd=(CLI_BIN_NAME+'\x20'+process['argv'][_0x4713cb(0xea)](0x2)[_0x4713cb(0x102)]('\x20'))[_0x4713cb(0xeb)]();logger['setRawCommand'](_0x37c4dd);const _0x179daf=isNonInteractiveMode(_0x4476ce);return{'config':_0x301178,'auth':_0x56701e,'logger':logger,'env':_0x5af938,'nonInteractive':_0x179daf};}export function buildConfigFromFlags(_0x51b2df){return buildConfig(readRawConfig(),_0x51b2df);}export function getLocalAppAliases(_0x2ed323){const _0x4fb416=a99_0x4229ec;return _0x2ed323[_0x4fb416(0x10a)]&&typeof _0x2ed323[_0x4fb416(0x10a)]===_0x4fb416(0xc9)?_0x2ed323[_0x4fb416(0x10a)]:{};}export function resolveLocalAppAliasCode(_0xe345db,_0x52d320){const _0x4ac119=a99_0x4229ec;if(!_0x52d320)return undefined;const _0x3ba21c=getLocalAppAliases(_0xe345db)[_0x52d320],_0x2eba41=_0x3ba21c?.[_0x4ac119(0xe2)];return typeof _0x2eba41===_0x4ac119(0xdd)&&_0x2eba41['trim']()?_0x2eba41[_0x4ac119(0xeb)]():undefined;}export function readAppCodeFromConfig(){const _0x4c4d3f=a99_0x4229ec,_0x147b0c=readRawConfig(),_0x6b5147=_0x147b0c[_0x4c4d3f(0xe2)]??_0x147b0c['app'];if(typeof _0x6b5147==='string'&&_0x6b5147[_0x4c4d3f(0xeb)]())return _0x6b5147[_0x4c4d3f(0xeb)]();const _0x21e2d5=resolveLocalAppAliasCode(_0x147b0c,typeof _0x147b0c[_0x4c4d3f(0x109)]==='string'?_0x147b0c[_0x4c4d3f(0x109)]:undefined);if(_0x21e2d5)return _0x21e2d5;const _0x620789=normalizeEnv(String(_0x147b0c[_0x4c4d3f(0xc6)]||_0x4c4d3f(0x105))),_0x27d68d=isDaily(_0x620789)?_0x4c4d3f(0x100):isDev(_0x620789)?'development':'production',_0x3c55c1=resolveCachedAppCode(typeof _0x147b0c[_0x4c4d3f(0x109)]===_0x4c4d3f(0xdd)?_0x147b0c[_0x4c4d3f(0x109)]:undefined,_0x27d68d,typeof _0x147b0c[_0x4c4d3f(0x104)]===_0x4c4d3f(0xdd)?_0x147b0c['accessKey']:undefined);if(_0x3c55c1)return _0x3c55c1;const _0x23652e=Object['values'](getLocalAppAliases(_0x147b0c))[_0x4c4d3f(0xef)](_0x5172ca=>_0x5172ca?.[_0x4c4d3f(0xe2)]);return typeof _0x23652e?.['appcode']==='string'&&_0x23652e[_0x4c4d3f(0xe2)][_0x4c4d3f(0xeb)]()?_0x23652e[_0x4c4d3f(0xe2)][_0x4c4d3f(0xeb)]():undefined;}export function readScopedConfig(_0x1cd367){const _0x56e736=a99_0x4229ec,_0x2d6eab=_0x1cd367[_0x56e736(0xe3)]?_0x56e736(0xe3):_0x56e736(0xfa);return readConfigFile(resolveWriteConfigPath(_0x2d6eab));}export function writeScopedConfig(_0x1b8286,_0x4843c8){const _0x2bfed2=a99_0x4229ec,_0x3c414a=_0x4843c8['global']?'global':_0x2bfed2(0xfa);writeConfigFile(resolveWriteConfigPath(_0x3c414a),_0x1b8286);}export async function initGlobalEnvironment(_0x4fc83c){const _0x5417b3=a99_0x4229ec,{initEnv:_0x1effc0}=await import(_0x5417b3(0xfc));_0x1effc0(_0x4fc83c[_0x5417b3(0xc6)]);const {initDomains:_0xd2944d}=await import(_0x5417b3(0xd8));_0xd2944d({'apiDomain':_0x4fc83c['raw'][_0x5417b3(0xd6)]||_0x4fc83c[_0x5417b3(0x101)]['host']||undefined,'userDomain':_0x4fc83c[_0x5417b3(0x101)]['userDomain']||undefined,'runtimeDomain':_0x4fc83c[_0x5417b3(0x101)][_0x5417b3(0x10b)]||undefined,'skillHubDomain':_0x4fc83c[_0x5417b3(0x101)][_0x5417b3(0xd7)]||undefined});}export function getProjectConfigPath(){const _0x3c970b=a99_0x4229ec;return resolveConfigPath(process[_0x3c970b(0xdb)]());}export function getGlobalConfigPath(){return resolveConfigPath(homedir());}export function inspectCliConfigJsonFile(_0x476226){const _0x456ff9=a99_0x4229ec;if(!existsSync(_0x476226))return{'status':_0x456ff9(0xc8)};try{const _0x365b38=readFileSync(_0x476226,{'encoding':_0x456ff9(0x106)});if(!_0x365b38?.[_0x456ff9(0xeb)]())return{'status':_0x456ff9(0x107)};const _0x457615=JSON[_0x456ff9(0xd4)](_0x365b38);return{'status':'ok','data':_0x457615};}catch(_0x142f72){return{'status':'error','message':_0x142f72 instanceof Error?_0x142f72['message']:String(_0x142f72)};}}export function loadRawConfigLayers(_0x3f6b57){const _0x581002=a99_0x4229ec;let _0x329046={},_0x4bfcf8={},_0x13eac4,_0x5a9cff;try{_0x13eac4=resolveConfigPath(homedir());if(_0x13eac4){const _0x202221=readFileSync(_0x13eac4,{'encoding':_0x581002(0x106)});if(_0x202221)_0x329046=JSON[_0x581002(0xd4)](_0x202221);}}catch{}try{const _0x4ebe18=_0x3f6b57||process[_0x581002(0xdb)]();_0x5a9cff=resolveConfigPath(_0x4ebe18);if(_0x5a9cff){const _0x16486e=readFileSync(_0x5a9cff,{'encoding':_0x581002(0x106)});if(_0x16486e)_0x4bfcf8=JSON['parse'](_0x16486e);}}catch{}return{'globalPath':_0x13eac4,'projectPath':_0x5a9cff,'globalConfig':_0x329046,'projectConfig':_0x4bfcf8};}function mergeRawConfigLayers(_0x1977c1){const _0x20c409=a99_0x4229ec,{globalConfig:_0x24fa4e,projectConfig:_0x353763}=_0x1977c1;if(_0x353763[_0x20c409(0xf4)]===![]){const _0x12bf60={..._0x353763};return delete _0x12bf60[_0x20c409(0xf4)],_0x12bf60;}const _0x45db2e={..._0x24fa4e,..._0x353763};if(_0x20c409(0x109)in _0x353763)_0x45db2e['defaultApp']=_0x353763[_0x20c409(0x109)];else _0x24fa4e[_0x20c409(0x109)]&&(_0x45db2e[_0x20c409(0x109)]=_0x24fa4e['defaultApp']);return _0x45db2e;}export function isInProject(){return!!getProjectConfigPath();}export function readRawConfig(_0x27b258){return mergeRawConfigLayers(loadRawConfigLayers(_0x27b258));}export function readRawConfigWithLayers(_0x45638e){const _0x5c588e=loadRawConfigLayers(_0x45638e);return{'config':mergeRawConfigLayers(_0x5c588e),'layers':_0x5c588e};}export function resolveDefaultAppSource(_0x1c43ed){const _0x31b0af=a99_0x4229ec;if(_0x31b0af(0x109)in _0x1c43ed[_0x31b0af(0xe7)])return _0x31b0af(0xfa);if(_0x1c43ed[_0x31b0af(0xe7)][_0x31b0af(0xf4)]===![])return null;if(_0x1c43ed[_0x31b0af(0xf5)]['defaultApp'])return _0x31b0af(0xe3);return null;}function buildConfig(_0xcc1c5a,_0x1be46a){const _0x39cd4b=a99_0x4229ec,_0x2d4b80=_0xcc1c5a[_0x39cd4b(0x109)]||undefined,_0x325e0d=_0x1be46a[_0x39cd4b(0xff)]||env(_0x39cd4b(0xf0))||undefined,_0x4fbc0f=_0x325e0d||_0x2d4b80||undefined,_0x3f81ef=env('ACCESS_KEY')||_0xcc1c5a[_0x39cd4b(0x104)]||undefined,_0x148429=_0x1be46a[_0x39cd4b(0xc6)]||env(_0x39cd4b(0xd1))||_0xcc1c5a[_0x39cd4b(0xc6)]||DEFAULT_CONFIG_VALUES[_0x39cd4b(0xc6)],_0x1367f5=normalizeEnv(String(_0x148429)),_0x481d8d=isDaily(_0x1367f5)?'daily':isDev(_0x1367f5)?'development':_0x39cd4b(0x105),_0x420938=typeof _0x1be46a[_0x39cd4b(0xe2)]===_0x39cd4b(0xdd)?_0x1be46a[_0x39cd4b(0xe2)]:undefined,_0xc0e2b6=env(_0x39cd4b(0xe6)),_0x3bf245=_0x325e0d?undefined:_0xcc1c5a[_0x39cd4b(0xe2)]||_0xcc1c5a[_0x39cd4b(0xff)]||undefined,_0xad8d33=_0x325e0d||(_0x3bf245?undefined:_0x2d4b80),_0x46ae46=resolveLocalAppAliasCode(_0xcc1c5a,_0xad8d33),_0x4e5e97=resolveCachedAppCode(_0xad8d33,_0x481d8d,_0x3f81ef),_0x797070=_0x420938||_0xc0e2b6||_0x3bf245||_0x46ae46||_0x4e5e97||undefined,_0x48df84=_0x420938?_0x39cd4b(0xcf):_0xc0e2b6?_0x39cd4b(0xc6):_0x3bf245?_0x39cd4b(0xe4):_0x46ae46?_0x39cd4b(0xe0):_0x4e5e97?_0x39cd4b(0xec):undefined,_0x52c075=_0xcc1c5a[_0x39cd4b(0xe5)]||DEFAULT_CONFIG_VALUES[_0x39cd4b(0xe5)],_0x13dcad=undefined,_0x375948=_0x1be46a['format']||env(_0x39cd4b(0xf3))||_0xcc1c5a[_0x39cd4b(0xfd)],_0x42606c=normalizeLegacyOutputFormat(_0x375948),_0x54c2ad=env(_0x39cd4b(0xdf))||_0xcc1c5a['pageSize'],_0x5d9c0f=_0x54c2ad?Number(_0x54c2ad)||undefined:undefined,_0x206d30=_0xcc1c5a[_0x39cd4b(0x10e)]||_0xcc1c5a[_0x39cd4b(0xc3)],_0x3f0b30=_0x206d30===_0x39cd4b(0xdc)||_0x206d30==='write'||_0x206d30===_0x39cd4b(0xc7)?_0x206d30:DEFAULT_CONFIG_VALUES[_0x39cd4b(0x10e)],_0x5b365c=env(_0x39cd4b(0x103)),_0x12ae39=_0x5b365c==='1'||_0x5b365c===_0x39cd4b(0xed);return{'appCode':typeof _0x797070===_0x39cd4b(0xdd)&&_0x797070['trim']()?_0x797070[_0x39cd4b(0xeb)]():undefined,'appCodeSource':_0x48df84,'env':_0x481d8d,'locale':_0x52c075,'cookie':_0x13dcad,'accessKey':_0x3f81ef,'format':_0x42606c,'pageSize':_0x5d9c0f,'riskLevel':_0x3f0b30,'verbose':_0x12ae39,'defaultApp':_0x2d4b80,'currentApp':typeof _0x4fbc0f===_0x39cd4b(0xdd)?_0x4fbc0f:undefined,'raw':_0xcc1c5a};}function env(_0x31c363){return productEnv(_0x31c363);}async function buildAuth(_0x184a5d){const _0x6ec7f2=a99_0x4229ec,_0x7b9125='',_0x44288c=!!_0x184a5d[_0x6ec7f2(0x104)];return{'cookie':_0x7b9125,'isLoggedIn':_0x44288c,async 'getOrLogin'(){const _0x4b4ed9=_0x6ec7f2;if(_0x44288c)return _0x7b9125;throw CliErrors[_0x4b4ed9(0xf2)]();}};}
|
|
1
|
+
const a99_0x4c1cad=a99_0x30e7;(function(_0x4410b5,_0x494c04){const _0x32f63b=a99_0x30e7,_0x54f1d1=_0x4410b5();while(!![]){try{const _0x2cc9c0=-parseInt(_0x32f63b(0x10c))/0x1*(parseInt(_0x32f63b(0x104))/0x2)+-parseInt(_0x32f63b(0x114))/0x3+-parseInt(_0x32f63b(0x12c))/0x4+-parseInt(_0x32f63b(0xf6))/0x5*(parseInt(_0x32f63b(0x124))/0x6)+parseInt(_0x32f63b(0x127))/0x7+-parseInt(_0x32f63b(0x130))/0x8+-parseInt(_0x32f63b(0x10f))/0x9*(-parseInt(_0x32f63b(0x125))/0xa);if(_0x2cc9c0===_0x494c04)break;else _0x54f1d1['push'](_0x54f1d1['shift']());}catch(_0x2818d4){_0x54f1d1['push'](_0x54f1d1['shift']());}}}(a99_0x4fef,0x46afa));import{readFileSync,existsSync,mkdirSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{homedir}from'node:os';import{logger}from'./utils/logger.js';import{CliErrors}from'./errors.js';import{CLI_BIN_NAME}from'./constant/cli.js';import{PRODUCT_CONFIG,productEnv,productEnvNames}from'./constant/product.js';import{DEFAULT_CONFIG_VALUES}from'./constant/defaults.js';import{normalizeEnv,isDaily,isDev}from'./constant/env.js';import{normalizeLegacyOutputFormat}from'./framework/types.js';import{resolveCachedAppCode}from'./commands/app/cache.js';export{AUTH_MODE,isAuthMode}from'./constant/auth-mode.js';function a99_0x30e7(_0x1cf047,_0x241746){_0x1cf047=_0x1cf047-0xf5;const _0x4fefdf=a99_0x4fef();let _0x30e71a=_0x4fefdf[_0x1cf047];return _0x30e71a;}const CONFIG_NAMES=PRODUCT_CONFIG[a99_0x4c1cad(0x100)];export const NEW_CONFIG_NAME=PRODUCT_CONFIG['newConfigFileName'];function a99_0x4fef(){const _0x2e6cfd=['EPERM','app','some','FORMAT','locale','.tmp','./constant/env.js','project','9012YAMiQn','18996130ciALrT','cwd','1815044dYPzPA','global','setRawMode','string','projectConfig','2138464ibQijS','missing','argv','setLogPath','1901040CmkjvL','daily','trim','./constant/domain.js','env','setRawCommand','skillHubDomain','runtimeDomain','APPCODE','isTTY','pageSize','online','PAGE_SIZE','format','raw','development','VERBOSE','local-alias','1835dgMPxO','object','riskLevel','slice','isRaw','inherit','explicit','accessKey','code','write','configFileNames','ACCESS_KEY','empty','production','1234bbMcay','EACCES','cache','high-risk-write','read','apps','appcode','userDomain','714EVvNbf','message','APP','9vmrdRD','maxRisk','defaultApp','stringify','apiDomain','316071AXJtzA','stdin','utf8','top-level','stdout','parse','host','true'];a99_0x4fef=function(){return _0x2e6cfd;};return a99_0x4fef();}function resolveConfigPath(_0x21322b){for(const _0x2c3086 of CONFIG_NAMES){const _0x28f6c6=resolve(_0x21322b,_0x2c3086);if(existsSync(_0x28f6c6))return _0x28f6c6;}return undefined;}export function resolveWriteConfigPath(_0x3c237e){const _0x35ddfa=a99_0x4c1cad,_0x5ec3d6=_0x3c237e===_0x35ddfa(0x123)?process['cwd']():homedir(),_0x4b1ddc=resolveConfigPath(_0x5ec3d6);return _0x4b1ddc??resolve(_0x5ec3d6,NEW_CONFIG_NAME);}export function readConfigFile(_0x106289){const _0x57b67a=a99_0x4c1cad;try{if(existsSync(_0x106289)){const _0x51af85=readFileSync(_0x106289,{'encoding':'utf8'});if(_0x51af85){const _0x2792e6=JSON[_0x57b67a(0x119)](_0x51af85);return migrateOnlineEnv(_0x106289,_0x2792e6),_0x2792e6;}}}catch{}return{};}function migrateOnlineEnv(_0x258d3f,_0x35bf9c){const _0x272154=a99_0x4c1cad;let _0x4d4822=![];_0x35bf9c[_0x272154(0x134)]===_0x272154(0x13b)&&(_0x35bf9c['env']=_0x272154(0x103),_0x4d4822=!![]);if(_0x35bf9c[_0x272154(0x109)]&&typeof _0x35bf9c[_0x272154(0x109)]===_0x272154(0xf7))for(const _0x37dcbe of Object['values'](_0x35bf9c[_0x272154(0x109)])){_0x37dcbe&&_0x37dcbe[_0x272154(0x134)]==='online'&&(_0x37dcbe['env']='production',_0x4d4822=!![]);}if(_0x4d4822)try{writeConfigFile(_0x258d3f,_0x35bf9c);}catch{}}export function writeConfigFile(_0x4692af,_0x50d732){const _0x586467=a99_0x4c1cad,_0x3d0f45=dirname(_0x4692af);!existsSync(_0x3d0f45)&&mkdirSync(_0x3d0f45,{'recursive':!![]});const _0x58a5ce=_0x4692af+_0x586467(0x121);try{writeFileSync(_0x58a5ce,JSON[_0x586467(0x112)](_0x50d732,null,0x2)+'\x0a',{'encoding':'utf8','mode':0x180});try{renameSync(_0x58a5ce,_0x4692af);}catch(_0x5c9d5d){if(_0x5c9d5d[_0x586467(0xfe)]===_0x586467(0x11c)||_0x5c9d5d[_0x586467(0xfe)]==='EXDEV'||_0x5c9d5d['code']===_0x586467(0x105)){writeFileSync(_0x4692af,JSON[_0x586467(0x112)](_0x50d732,null,0x2)+'\x0a',{'encoding':_0x586467(0x116)});try{unlinkSync(_0x58a5ce);}catch{}}else throw _0x5c9d5d;}}catch(_0x3947f2){try{unlinkSync(_0x58a5ce);}catch{}throw _0x3947f2;}}export function isNonInteractiveMode(_0x2661f8){const _0x20b9e5=a99_0x4c1cad;return!!(_0x2661f8['nonInteractive']||_0x2661f8['ci']||productEnvNames('CI')[_0x20b9e5(0x11e)](_0x1b302e=>process.env[_0x1b302e]===_0x20b9e5(0x11b))||process.env.CI===_0x20b9e5(0x11b)||!process[_0x20b9e5(0x118)]['isTTY']||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x343ce3=a99_0x4c1cad;if(!process[_0x343ce3(0x115)][_0x343ce3(0x139)])return![];try{const _0x247ad9=process[_0x343ce3(0x115)][_0x343ce3(0xfa)];return process[_0x343ce3(0x115)][_0x343ce3(0x129)](!![]),process[_0x343ce3(0x115)][_0x343ce3(0x129)](_0x247ad9??![]),!![];}catch{return![];}}export async function createContext(_0x5f3b3c){const _0x19865b=a99_0x4c1cad,_0xfbb0a0=readRawConfig(),_0x5cd56b=buildConfig(_0xfbb0a0,_0x5f3b3c);await initGlobalEnvironment(_0x5cd56b);const {getUserDomain:_0x33dad4,getApiDomain:_0x327704}=await import(_0x19865b(0x133)),_0x8115da={'apiDomain':_0x327704(),'userDomain':_0x33dad4()},_0x1a4d09=await buildAuth(_0x5cd56b);logger[_0x19865b(0x12f)](process['cwd']());const _0x2917f4=(CLI_BIN_NAME+'\x20'+process[_0x19865b(0x12e)][_0x19865b(0xf9)](0x2)['join']('\x20'))[_0x19865b(0x132)]();logger[_0x19865b(0x135)](_0x2917f4);const _0x1bc4ec=isNonInteractiveMode(_0x5f3b3c);return{'config':_0x5cd56b,'auth':_0x1a4d09,'logger':logger,'env':_0x8115da,'nonInteractive':_0x1bc4ec};}export function buildConfigFromFlags(_0xb61c2f){return buildConfig(readRawConfig(),_0xb61c2f);}export function getLocalAppAliases(_0x5ed893){const _0x3b6694=a99_0x4c1cad;return _0x5ed893[_0x3b6694(0x109)]&&typeof _0x5ed893[_0x3b6694(0x109)]===_0x3b6694(0xf7)?_0x5ed893[_0x3b6694(0x109)]:{};}export function resolveLocalAppAliasCode(_0x13b73e,_0x26f0c8){const _0x18b4a0=a99_0x4c1cad;if(!_0x26f0c8)return undefined;const _0x58b897=getLocalAppAliases(_0x13b73e)[_0x26f0c8],_0x36c613=_0x58b897?.[_0x18b4a0(0x10a)];return typeof _0x36c613==='string'&&_0x36c613[_0x18b4a0(0x132)]()?_0x36c613[_0x18b4a0(0x132)]():undefined;}export function readAppCodeFromConfig(){const _0x336cde=a99_0x4c1cad,_0x4e6dbc=readRawConfig(),_0x24655c=_0x4e6dbc[_0x336cde(0x10a)]??_0x4e6dbc[_0x336cde(0x11d)];if(typeof _0x24655c===_0x336cde(0x12a)&&_0x24655c[_0x336cde(0x132)]())return _0x24655c[_0x336cde(0x132)]();const _0x11a48b=resolveLocalAppAliasCode(_0x4e6dbc,typeof _0x4e6dbc[_0x336cde(0x111)]===_0x336cde(0x12a)?_0x4e6dbc[_0x336cde(0x111)]:undefined);if(_0x11a48b)return _0x11a48b;const _0x26d414=normalizeEnv(String(_0x4e6dbc[_0x336cde(0x134)]||_0x336cde(0x103))),_0x155285=isDaily(_0x26d414)?_0x336cde(0x131):isDev(_0x26d414)?'development':'production',_0x4d2717=resolveCachedAppCode(typeof _0x4e6dbc[_0x336cde(0x111)]===_0x336cde(0x12a)?_0x4e6dbc[_0x336cde(0x111)]:undefined,_0x155285,typeof _0x4e6dbc[_0x336cde(0xfd)]===_0x336cde(0x12a)?_0x4e6dbc[_0x336cde(0xfd)]:undefined);if(_0x4d2717)return _0x4d2717;const _0x37937f=Object['values'](getLocalAppAliases(_0x4e6dbc))['find'](_0x4a00ba=>_0x4a00ba?.[_0x336cde(0x10a)]);return typeof _0x37937f?.['appcode']===_0x336cde(0x12a)&&_0x37937f['appcode'][_0x336cde(0x132)]()?_0x37937f[_0x336cde(0x10a)]['trim']():undefined;}export function readScopedConfig(_0x460ece){const _0xe7f049=a99_0x4c1cad,_0x584224=_0x460ece[_0xe7f049(0x128)]?_0xe7f049(0x128):_0xe7f049(0x123);return readConfigFile(resolveWriteConfigPath(_0x584224));}export function writeScopedConfig(_0x2aa8fa,_0x3bd480){const _0x32b7df=a99_0x4c1cad,_0x237b0d=_0x3bd480[_0x32b7df(0x128)]?'global':'project';writeConfigFile(resolveWriteConfigPath(_0x237b0d),_0x2aa8fa);}export async function initGlobalEnvironment(_0x65eb3a){const _0x2198ad=a99_0x4c1cad,{initEnv:_0x2f4d0f}=await import(_0x2198ad(0x122));_0x2f4d0f(_0x65eb3a[_0x2198ad(0x134)]);const {initDomains:_0x39761c}=await import('./constant/domain.js');_0x39761c({'apiDomain':_0x65eb3a[_0x2198ad(0x13e)][_0x2198ad(0x113)]||_0x65eb3a['raw'][_0x2198ad(0x11a)]||undefined,'userDomain':_0x65eb3a[_0x2198ad(0x13e)][_0x2198ad(0x10b)]||undefined,'runtimeDomain':_0x65eb3a[_0x2198ad(0x13e)][_0x2198ad(0x137)]||undefined,'skillHubDomain':_0x65eb3a[_0x2198ad(0x13e)][_0x2198ad(0x136)]||undefined});}export function getProjectConfigPath(){const _0x297733=a99_0x4c1cad;return resolveConfigPath(process[_0x297733(0x126)]());}export function getGlobalConfigPath(){return resolveConfigPath(homedir());}export function inspectCliConfigJsonFile(_0x33cd36){const _0x3170bf=a99_0x4c1cad;if(!existsSync(_0x33cd36))return{'status':_0x3170bf(0x12d)};try{const _0x2dcf72=readFileSync(_0x33cd36,{'encoding':_0x3170bf(0x116)});if(!_0x2dcf72?.[_0x3170bf(0x132)]())return{'status':_0x3170bf(0x102)};const _0x1cf8ee=JSON[_0x3170bf(0x119)](_0x2dcf72);return{'status':'ok','data':_0x1cf8ee};}catch(_0x14776b){return{'status':'error','message':_0x14776b instanceof Error?_0x14776b[_0x3170bf(0x10d)]:String(_0x14776b)};}}export function loadRawConfigLayers(_0x16d86e){const _0x35e28a=a99_0x4c1cad;let _0x74b1d8={},_0x1b2d20={},_0x52e4dd,_0x6cead2;try{_0x52e4dd=resolveConfigPath(homedir());if(_0x52e4dd){const _0x12817f=readFileSync(_0x52e4dd,{'encoding':_0x35e28a(0x116)});if(_0x12817f)_0x74b1d8=JSON[_0x35e28a(0x119)](_0x12817f);}}catch{}try{const _0x28c127=_0x16d86e||process[_0x35e28a(0x126)]();_0x6cead2=resolveConfigPath(_0x28c127);if(_0x6cead2){const _0x470a99=readFileSync(_0x6cead2,{'encoding':_0x35e28a(0x116)});if(_0x470a99)_0x1b2d20=JSON[_0x35e28a(0x119)](_0x470a99);}}catch{}return{'globalPath':_0x52e4dd,'projectPath':_0x6cead2,'globalConfig':_0x74b1d8,'projectConfig':_0x1b2d20};}function mergeRawConfigLayers(_0x5c54db){const _0x28ed65=a99_0x4c1cad,{globalConfig:_0x994c18,projectConfig:_0x18c088}=_0x5c54db;if(_0x18c088[_0x28ed65(0xfb)]===![]){const _0x2070d8={..._0x18c088};return delete _0x2070d8[_0x28ed65(0xfb)],_0x2070d8;}const _0x59f421={..._0x994c18,..._0x18c088};if('defaultApp'in _0x18c088)_0x59f421['defaultApp']=_0x18c088[_0x28ed65(0x111)];else _0x994c18[_0x28ed65(0x111)]&&(_0x59f421[_0x28ed65(0x111)]=_0x994c18['defaultApp']);return _0x59f421;}export function isInProject(){return!!getProjectConfigPath();}export function readRawConfig(_0x30e18b){return mergeRawConfigLayers(loadRawConfigLayers(_0x30e18b));}export function readRawConfigWithLayers(_0x5a5887){const _0x2f5ccc=loadRawConfigLayers(_0x5a5887);return{'config':mergeRawConfigLayers(_0x2f5ccc),'layers':_0x2f5ccc};}export function resolveDefaultAppSource(_0x5bb343){const _0x47dd8a=a99_0x4c1cad;if(_0x47dd8a(0x111)in _0x5bb343[_0x47dd8a(0x12b)])return _0x47dd8a(0x123);if(_0x5bb343[_0x47dd8a(0x12b)][_0x47dd8a(0xfb)]===![])return null;if(_0x5bb343['globalConfig'][_0x47dd8a(0x111)])return _0x47dd8a(0x128);return null;}function buildConfig(_0x3169f5,_0x3d7138){const _0x2a307b=a99_0x4c1cad,_0x3b02b9=_0x3169f5[_0x2a307b(0x111)]||undefined,_0x88d1c0=_0x3d7138[_0x2a307b(0x11d)]||env(_0x2a307b(0x10e))||undefined,_0x53bb3e=_0x88d1c0||_0x3b02b9||undefined,_0x18201e=env(_0x2a307b(0x101))||_0x3169f5[_0x2a307b(0xfd)]||undefined,_0x574d67=_0x3d7138[_0x2a307b(0x134)]||env('ENV')||_0x3169f5[_0x2a307b(0x134)]||DEFAULT_CONFIG_VALUES['env'],_0x285a04=normalizeEnv(String(_0x574d67)),_0x252df3=isDaily(_0x285a04)?'daily':isDev(_0x285a04)?_0x2a307b(0x13f):_0x2a307b(0x103),_0x3a6b2e=typeof _0x3d7138['appcode']===_0x2a307b(0x12a)?_0x3d7138[_0x2a307b(0x10a)]:undefined,_0x27e4ff=env(_0x2a307b(0x138)),_0x5d5b50=_0x88d1c0?undefined:_0x3169f5[_0x2a307b(0x10a)]||_0x3169f5['app']||undefined,_0x1522a2=_0x88d1c0||(_0x5d5b50?undefined:_0x3b02b9),_0x490b62=resolveLocalAppAliasCode(_0x3169f5,_0x1522a2),_0x56be22=resolveCachedAppCode(_0x1522a2,_0x252df3,_0x18201e),_0x3857fc=_0x3a6b2e||_0x27e4ff||_0x5d5b50||_0x490b62||_0x56be22||undefined,_0x111239=_0x3a6b2e?_0x2a307b(0xfc):_0x27e4ff?_0x2a307b(0x134):_0x5d5b50?_0x2a307b(0x117):_0x490b62?_0x2a307b(0xf5):_0x56be22?_0x2a307b(0x106):undefined,_0x2bb8ea=_0x3169f5[_0x2a307b(0x120)]||DEFAULT_CONFIG_VALUES['locale'],_0xeb5543=undefined,_0x57788e=_0x3d7138[_0x2a307b(0x13d)]||env(_0x2a307b(0x11f))||_0x3169f5[_0x2a307b(0x13d)],_0x3d08e7=normalizeLegacyOutputFormat(_0x57788e),_0x12bcd0=env(_0x2a307b(0x13c))||_0x3169f5[_0x2a307b(0x13a)],_0x40ba3e=_0x12bcd0?Number(_0x12bcd0)||undefined:undefined,_0x3f0a73=_0x3169f5[_0x2a307b(0xf8)]||_0x3169f5[_0x2a307b(0x110)],_0xc0567b=_0x3f0a73===_0x2a307b(0x108)||_0x3f0a73===_0x2a307b(0xff)||_0x3f0a73===_0x2a307b(0x107)?_0x3f0a73:DEFAULT_CONFIG_VALUES[_0x2a307b(0xf8)],_0x3901d0=env(_0x2a307b(0x140)),_0x431296=_0x3901d0==='1'||_0x3901d0===_0x2a307b(0x11b);return{'appCode':typeof _0x3857fc===_0x2a307b(0x12a)&&_0x3857fc[_0x2a307b(0x132)]()?_0x3857fc[_0x2a307b(0x132)]():undefined,'appCodeSource':_0x111239,'env':_0x252df3,'locale':_0x2bb8ea,'cookie':_0xeb5543,'accessKey':_0x18201e,'format':_0x3d08e7,'pageSize':_0x40ba3e,'riskLevel':_0xc0567b,'verbose':_0x431296,'defaultApp':_0x3b02b9,'currentApp':typeof _0x53bb3e===_0x2a307b(0x12a)?_0x53bb3e:undefined,'raw':_0x3169f5};}function env(_0x1ba39b){return productEnv(_0x1ba39b);}async function buildAuth(_0x1ede51){const _0x5ba45d=a99_0x4c1cad,_0x4bbc9d='',_0x291d22=!!_0x1ede51[_0x5ba45d(0xfd)];return{'cookie':_0x4bbc9d,'isLoggedIn':_0x291d22,async 'getOrLogin'(){if(_0x291d22)return _0x4bbc9d;throw CliErrors['authRequired']();}};}
|