@lovrabet/lovrabet-cli 2.3.11 → 2.3.12-beta.1
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/approval/index.js +1 -1
- package/lib/commands/artifact/index.d.ts +13 -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/init.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/data/import-excel.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/issue/context.js +1 -1
- package/lib/commands/issue/index.js +1 -1
- package/lib/commands/issue/report.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/domain-config.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/region.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.d.ts +3 -2
- package/lib/core/api-client.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/kb-management-client.js +1 -1
- package/lib/core/kb-sdk-errors.js +1 -1
- package/lib/core/kb-search-client.js +1 -1
- package/lib/core/sdk-client.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/access-error.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/generated/official-routing.js +1 -1
- package/lib/generated/routing-contract.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/services/dataset-import/auto-id-runner.js +1 -1
- package/lib/services/dataset-import/excel-reader.js +1 -1
- package/lib/services/dataset-import/image-bytes.js +1 -1
- package/lib/services/dataset-import/image-ooxml.js +1 -1
- package/lib/services/dataset-import/image-runner.js +1 -1
- package/lib/services/dataset-import/metadata.js +1 -1
- package/lib/services/dataset-import/preview.js +1 -1
- package/lib/services/dataset-import/runner.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/access-key-redaction.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.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/positive-safe-integer.js +1 -1
- package/lib/utils/redaction.js +1 -1
- package/lib/utils/runtime-user-id.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 +1 -1
- package/skills/lovrabet.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a96_0xb32889=a96_0x2b82;(function(_0x36b729,_0x465df3){const _0xa5e0cb=a96_0x2b82,_0x578a08=_0x36b729();while(!![]){try{const _0x11c362=parseInt(_0xa5e0cb(0xda))/0x1+parseInt(_0xa5e0cb(0xd2))/0x2+-parseInt(_0xa5e0cb(0xd6))/0x3*(parseInt(_0xa5e0cb(0xd9))/0x4)+-parseInt(_0xa5e0cb(0xd7))/0x5*(parseInt(_0xa5e0cb(0xd3))/0x6)+-parseInt(_0xa5e0cb(0xdd))/0x7*(-parseInt(_0xa5e0cb(0xde))/0x8)+parseInt(_0xa5e0cb(0xd5))/0x9+-parseInt(_0xa5e0cb(0xd8))/0xa*(parseInt(_0xa5e0cb(0xdc))/0xb);if(_0x11c362===_0x465df3)break;else _0x578a08['push'](_0x578a08['shift']());}catch(_0x4c6474){_0x578a08['push'](_0x578a08['shift']());}}}(a96_0x3830,0x5636e));function a96_0x2b82(_0x52bcfa,_0x316825){_0x52bcfa=_0x52bcfa-0xd2;const _0x383068=a96_0x3830();let _0x2b82a9=_0x383068[_0x52bcfa];return _0x2b82a9;}function a96_0x3830(){const _0x3d8f01=['3083479tjghAc','8ahtpxo','941736WZaLyV','25128AELgei','ClientAk','3792447jnTcfD','137031DZpkXZ','370ldSvvS','872150xqlZXn','16hnAhhI','646801VquLaK','client-ak','143iJNsZf'];a96_0x3830=function(){return _0x3d8f01;};return a96_0x3830();}export const AUTH_MODE={'ClientAk':a96_0xb32889(0xdb)};export function isAuthMode(_0xa13b87){const _0x318cc8=a96_0xb32889;return _0xa13b87===AUTH_MODE[_0x318cc8(0xd4)];}
|
package/lib/constant/cli.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a97_0xa4ae63=a97_0x4692;(function(_0x4fe7cc,_0x4fad82){const _0x10d06a=a97_0x4692,_0x463177=_0x4fe7cc();while(!![]){try{const _0x37aedb=-parseInt(_0x10d06a(0x184))/0x1*(-parseInt(_0x10d06a(0x181))/0x2)+-parseInt(_0x10d06a(0x169))/0x3+-parseInt(_0x10d06a(0x177))/0x4+-parseInt(_0x10d06a(0x17f))/0x5*(parseInt(_0x10d06a(0x186))/0x6)+parseInt(_0x10d06a(0x16e))/0x7*(parseInt(_0x10d06a(0x167))/0x8)+-parseInt(_0x10d06a(0x18d))/0x9+-parseInt(_0x10d06a(0x173))/0xa*(-parseInt(_0x10d06a(0x183))/0xb);if(_0x37aedb===_0x4fad82)break;else _0x463177['push'](_0x463177['shift']());}catch(_0x2d2329){_0x463177['push'](_0x463177['shift']());}}}(a97_0x53a5,0x757c3));import{PRODUCT_CONFIG}from'../constant/product.js';function a97_0x53a5(){const _0x2a54e4=['dryRun','JSON\x20params\x20for\x20execute\x20commands','app','clear','888SMktUM','Clear\x20output','742698KaECCr','Override\x20appcode','Environment','type','<expr>','49462vSJLbR','appcode','Filter\x20JSON\x20output\x20(JQ_PATH\x20>\x20bundled\x20jq\x20>\x20PATH;\x20implies\x20--format\x20json\x20when\x20current\x20format\x20is\x20pretty)','production\x20|\x20development\x20|\x20daily','Name\x20filter','610930XoDvBP','name','format','yes','3307024RaPbYo','string','params','<code>','boolean','non-interactive','verbose','global','10BYqosZ','meowKey','4568qfmtSF','Force\x20non-interactive\x20mode\x20(CI)','77wetglN','237CBeAul','Skip\x20confirmation\x20for\x20high-risk\x20writes','206784pfnBPu','help','sqlcode','env','cliBinName','SQL\x20query\x20code','Preview\x20operation\x20without\x20executing','1159344aKrYLs','map','Verbose\x20output','dry-run','Record\x20ID','<name>','cliDisplayName','json\x20|\x20pretty\x20|\x20compress'];a97_0x53a5=function(){return _0x2a54e4;};return a97_0x53a5();}import{LOVRABET_NPM_PACKAGE_NAME}from'../constant/distribution.js';export const CLI_BIN_NAME=PRODUCT_CONFIG[a97_0xa4ae63(0x18a)];export const CLI_DISPLAY_NAME=PRODUCT_CONFIG[a97_0xa4ae63(0x193)];export const NPM_PACKAGE_NAME=LOVRABET_NPM_PACKAGE_NAME;export const GLOBAL_FLAGS=[{'name':a97_0xa4ae63(0x16f),'meowKey':'appcode','type':a97_0xa4ae63(0x178),'description':a97_0xa4ae63(0x16a),'hint':a97_0xa4ae63(0x17a)},{'name':a97_0xa4ae63(0x197),'meowKey':a97_0xa4ae63(0x197),'type':a97_0xa4ae63(0x178),'description':'Select\x20app\x20profile\x20by\x20name','hint':a97_0xa4ae63(0x192)},{'name':a97_0xa4ae63(0x189),'meowKey':a97_0xa4ae63(0x189),'type':a97_0xa4ae63(0x178),'description':a97_0xa4ae63(0x16b),'hint':a97_0xa4ae63(0x171)},{'name':a97_0xa4ae63(0x175),'meowKey':a97_0xa4ae63(0x175),'type':a97_0xa4ae63(0x178),'description':'Output\x20format','hint':a97_0xa4ae63(0x194)},{'name':'jq','meowKey':'jq','type':a97_0xa4ae63(0x178),'description':a97_0xa4ae63(0x170),'hint':a97_0xa4ae63(0x16d)},{'name':a97_0xa4ae63(0x190),'meowKey':a97_0xa4ae63(0x195),'type':'boolean','description':a97_0xa4ae63(0x18c)},{'name':a97_0xa4ae63(0x176),'meowKey':a97_0xa4ae63(0x176),'type':a97_0xa4ae63(0x17b),'description':a97_0xa4ae63(0x185)},{'name':a97_0xa4ae63(0x17c),'meowKey':'nonInteractive','type':'boolean','description':a97_0xa4ae63(0x182)},{'name':a97_0xa4ae63(0x17e),'meowKey':'global','type':a97_0xa4ae63(0x17b),'description':'Use\x20global\x20config\x20scope'},{'name':'ci','meowKey':'ci','type':'boolean','description':'Alias\x20for\x20--non-interactive','hidden':!![]},{'name':'help','meowKey':a97_0xa4ae63(0x187),'type':a97_0xa4ae63(0x17b),'description':'Show\x20help'},{'name':'id','meowKey':'id','type':a97_0xa4ae63(0x178),'description':a97_0xa4ae63(0x191),'hidden':!![]},{'name':a97_0xa4ae63(0x174),'meowKey':'name','type':'string','description':a97_0xa4ae63(0x172),'hidden':!![]},{'name':'sqlcode','meowKey':a97_0xa4ae63(0x188),'type':a97_0xa4ae63(0x178),'description':a97_0xa4ae63(0x18b),'hidden':!![]},{'name':'params','meowKey':a97_0xa4ae63(0x179),'type':a97_0xa4ae63(0x178),'description':a97_0xa4ae63(0x196),'hidden':!![]},{'name':a97_0xa4ae63(0x17d),'meowKey':a97_0xa4ae63(0x17d),'type':a97_0xa4ae63(0x17b),'description':a97_0xa4ae63(0x18f),'hidden':!![]},{'name':a97_0xa4ae63(0x166),'meowKey':a97_0xa4ae63(0x166),'type':a97_0xa4ae63(0x17b),'description':a97_0xa4ae63(0x168),'hidden':!![]}];export const PIPELINE_FLAG_NAMES=new Set([a97_0xa4ae63(0x16f),a97_0xa4ae63(0x197),a97_0xa4ae63(0x189),a97_0xa4ae63(0x175),'jq',a97_0xa4ae63(0x190),'yes',a97_0xa4ae63(0x17c),'ci']);function a97_0x4692(_0x313c86,_0x46ba8f){_0x313c86=_0x313c86-0x166;const _0x53a521=a97_0x53a5();let _0x469293=_0x53a521[_0x313c86];return _0x469293;}export function buildMeowFlags(){const _0x398234=a97_0xa4ae63;return Object['fromEntries'](GLOBAL_FLAGS[_0x398234(0x18e)](_0x12bade=>[_0x12bade[_0x398234(0x180)],{'type':_0x12bade[_0x398234(0x16c)]}]));}
|
package/lib/constant/defaults.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a98_0x3ef8e0=a98_0x2f07;function a98_0x454f(){const _0x30e102=['1565354ZPnHKO','main','441004eQoHIU','en-US','581679bxnFyQ','5uiFweC','273588Fagqhj','1248804QPrbWt','write','8pzDHom','4044078nalplw','compress','production','177068jaWIMD'];a98_0x454f=function(){return _0x30e102;};return a98_0x454f();}(function(_0x24b434,_0x2839a7){const _0x1ee207=a98_0x2f07,_0x5df008=_0x24b434();while(!![]){try{const _0x3ed843=parseInt(_0x1ee207(0x7b))/0x1+parseInt(_0x1ee207(0x7e))/0x2+-parseInt(_0x1ee207(0x72))/0x3+parseInt(_0x1ee207(0x74))/0x4*(-parseInt(_0x1ee207(0x73))/0x5)+-parseInt(_0x1ee207(0x75))/0x6+-parseInt(_0x1ee207(0x7c))/0x7+parseInt(_0x1ee207(0x77))/0x8*(parseInt(_0x1ee207(0x78))/0x9);if(_0x3ed843===_0x2839a7)break;else _0x5df008['push'](_0x5df008['shift']());}catch(_0x5b798e){_0x5df008['push'](_0x5df008['shift']());}}}(a98_0x454f,0x25522));export const DEFAULT_APP_PROFILE_NAME=a98_0x3ef8e0(0x7d);export const DEFAULT_CONFIG_VALUES={'env':a98_0x3ef8e0(0x7a),'format':'compress','locale':a98_0x3ef8e0(0x7f),'riskLevel':a98_0x3ef8e0(0x76)};function a98_0x2f07(_0x5c7839,_0x477c88){_0x5c7839=_0x5c7839-0x72;const _0x454fbf=a98_0x454f();let _0x2f07d6=_0x454fbf[_0x5c7839];return _0x2f07d6;}export const DEFAULT_COMMAND_OUTPUT_FORMAT=a98_0x3ef8e0(0x79);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a99_0x16008d=a99_0x1742;function a99_0x51d4(){const _0x4c4c0e=['cliCdnBaseUrl','760624JPdPVR','1529888IxSFVx','706430EBWpGy','16KyGnuq','/dist/lovrabet-cli/config/index.json','8590tixKjB','npmRegistryBaseUrl','82050HLRMwF','1665shAqvz','8008264hExAJz','1odFqWQ','30486CBoxaN','49NPVIVD','skillSource','npmPackageName'];a99_0x51d4=function(){return _0x4c4c0e;};return a99_0x51d4();}(function(_0x4b5471,_0x166ca3){const _0x59f184=a99_0x1742,_0x49b84b=_0x4b5471();while(!![]){try{const _0x50b46e=-parseInt(_0x59f184(0x158))/0x1*(-parseInt(_0x59f184(0x15e))/0x2)+parseInt(_0x59f184(0x159))/0x3+-parseInt(_0x59f184(0x161))/0x4*(-parseInt(_0x59f184(0x160))/0x5)+parseInt(_0x59f184(0x155))/0x6*(-parseInt(_0x59f184(0x15a))/0x7)+parseInt(_0x59f184(0x15f))/0x8+parseInt(_0x59f184(0x156))/0x9*(parseInt(_0x59f184(0x163))/0xa)+-parseInt(_0x59f184(0x157))/0xb;if(_0x50b46e===_0x166ca3)break;else _0x49b84b['push'](_0x49b84b['shift']());}catch(_0x5427ab){_0x49b84b['push'](_0x49b84b['shift']());}}}(a99_0x51d4,0x75ae4));import{PRODUCT_CONFIG}from'../constant/product.js';export const LOVRABET_NPM_PACKAGE_NAME=PRODUCT_CONFIG[a99_0x16008d(0x15c)];export const LOVRABET_SKILL_SOURCE=PRODUCT_CONFIG[a99_0x16008d(0x15b)];export const NPM_REGISTRY_BASE_URL=PRODUCT_CONFIG[a99_0x16008d(0x164)];export const LOVRABET_CLI_CDN_BASE_URL=PRODUCT_CONFIG[a99_0x16008d(0x15d)];function a99_0x1742(_0x296753,_0x2e8a23){_0x296753=_0x296753-0x155;const _0x51d40c=a99_0x51d4();let _0x1742d1=_0x51d40c[_0x296753];return _0x1742d1;}export const LOVRABET_CLI_VERSION_POLICY_URL=LOVRABET_CLI_CDN_BASE_URL+a99_0x16008d(0x162);
|
package/lib/constant/domain.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a100_0x13a913=a100_0x2d25;(function(_0x52e4c6,_0x745f55){const _0xbd466b=a100_0x2d25,_0x12bf29=_0x52e4c6();while(!![]){try{const _0x34d2e9=-parseInt(_0xbd466b(0x76))/0x1*(-parseInt(_0xbd466b(0x77))/0x2)+parseInt(_0xbd466b(0x68))/0x3*(-parseInt(_0xbd466b(0x71))/0x4)+parseInt(_0xbd466b(0x7c))/0x5+-parseInt(_0xbd466b(0x6c))/0x6*(-parseInt(_0xbd466b(0x72))/0x7)+parseInt(_0xbd466b(0x6a))/0x8+parseInt(_0xbd466b(0x74))/0x9+parseInt(_0xbd466b(0x70))/0xa*(-parseInt(_0xbd466b(0x73))/0xb);if(_0x34d2e9===_0x745f55)break;else _0x12bf29['push'](_0x12bf29['shift']());}catch(_0x2f0556){_0x12bf29['push'](_0x12bf29['shift']());}}}(a100_0x50ea,0x8fc03));import{CliErrors}from'../errors.js';import{getEnv,isProduction}from'../constant/env.js';import{OFFICIAL_ROUTING_PROFILES}from'../generated/official-routing.js';function a100_0x50ea(){const _0x69dc01=['daily','3QoegMT','serviceDomains','2632936upaEXL','runtime','1591776qdZDFB','kbServiceDomain','kbService','runtimeDomain','10rFCIdm','57372GNDYCP','14rklVvX','29682961jfEQXK','5239701nudECm','user','2CdeWDd','929218LdRtTc','apiDomain','skillDomain','api','validation','4652405ppADhd','userDomain','region','Configure\x20a\x20trusted\x20harnessDomain\x20HTTPS\x20origin\x20in\x20the\x20connection\x20settings.','production'];a100_0x50ea=function(){return _0x69dc01;};return a100_0x50ea();}import{DEFAULT_LOVRABET_REGION}from'../constant/region.js';let customApiDomain,customUserDomain,customRuntimeDomain,customSkillDomain,customKbServiceDomain,customHarnessDomain,activeRegion=DEFAULT_LOVRABET_REGION;export function initDomains(_0x120cf1){const _0x42b2c9=a100_0x2d25;customApiDomain=_0x120cf1?.[_0x42b2c9(0x78)],customUserDomain=_0x120cf1?.[_0x42b2c9(0x7d)],customRuntimeDomain=_0x120cf1?.[_0x42b2c9(0x6f)],customSkillDomain=_0x120cf1?.[_0x42b2c9(0x79)],customKbServiceDomain=_0x120cf1?.[_0x42b2c9(0x6d)],customHarnessDomain=_0x120cf1?.['harnessDomain'],activeRegion=_0x120cf1?.[_0x42b2c9(0x64)]??DEFAULT_LOVRABET_REGION;}const getActiveRegionDomains=()=>{const _0x3d3b9f=a100_0x2d25,_0x1c6ac3=OFFICIAL_ROUTING_PROFILES[activeRegion][_0x3d3b9f(0x69)];return isProduction(getEnv())?_0x1c6ac3['production']:'daily'in _0x1c6ac3?_0x1c6ac3[_0x3d3b9f(0x67)]:_0x1c6ac3[_0x3d3b9f(0x66)];};export const getUserDomain=()=>customUserDomain||getActiveRegionDomains()[a100_0x13a913(0x75)];export const getApiDomain=()=>customApiDomain||getActiveRegionDomains()[a100_0x13a913(0x7a)];export const getRuntimeDomain=()=>customRuntimeDomain||getActiveRegionDomains()[a100_0x13a913(0x6b)];export const getSkillDomain=()=>customSkillDomain||getActiveRegionDomains()['skill'];function a100_0x2d25(_0x22ae76,_0x594e17){_0x22ae76=_0x22ae76-0x64;const _0x50eae1=a100_0x50ea();let _0x2d25eb=_0x50eae1[_0x22ae76];return _0x2d25eb;}export const getKbServiceDomain=()=>{const _0x300f81=a100_0x13a913;if(customKbServiceDomain)return customKbServiceDomain;const _0x4ff90c=getActiveRegionDomains();return'kbService'in _0x4ff90c?_0x4ff90c[_0x300f81(0x6e)]:undefined;};export const getHarnessDomain=()=>{if(customHarnessDomain)return customHarnessDomain;const _0x1a70e6=getActiveRegionDomains();return'harness'in _0x1a70e6?_0x1a70e6['harness']:undefined;};export function requireHarnessDomain(){const _0x2b28e8=a100_0x13a913,_0x1151c3=getHarnessDomain();if(!_0x1151c3)throw CliErrors[_0x2b28e8(0x7b)]('Harness\x20is\x20not\x20configured.',_0x2b28e8(0x65));return _0x1151c3;}
|
package/lib/constant/env.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a101_0x145b50=a101_0x22a1;(function(_0xe8e5f,_0x2a1300){const _0x86c7e3=a101_0x22a1,_0x11c425=_0xe8e5f();while(!![]){try{const _0x2e2e43=parseInt(_0x86c7e3(0x78))/0x1*(parseInt(_0x86c7e3(0x70))/0x2)+-parseInt(_0x86c7e3(0x6f))/0x3*(parseInt(_0x86c7e3(0x72))/0x4)+-parseInt(_0x86c7e3(0x68))/0x5*(parseInt(_0x86c7e3(0x77))/0x6)+parseInt(_0x86c7e3(0x67))/0x7+parseInt(_0x86c7e3(0x6e))/0x8*(parseInt(_0x86c7e3(0x6c))/0x9)+-parseInt(_0x86c7e3(0x6a))/0xa*(-parseInt(_0x86c7e3(0x69))/0xb)+-parseInt(_0x86c7e3(0x6d))/0xc;if(_0x2e2e43===_0x2a1300)break;else _0x11c425['push'](_0x11c425['shift']());}catch(_0x4c5c9c){_0x11c425['push'](_0x11c425['shift']());}}}(a101_0x385b,0x99402));import{productEnv}from'../constant/product.js';export const RUNTIME_ENV_VALUES=[a101_0x145b50(0x74),a101_0x145b50(0x75),'daily'];export function normalizeEnv(_0x566591){const _0x3a89dc=a101_0x145b50;return _0x566591===_0x3a89dc(0x76)||_0x566591===_0x3a89dc(0x73)?'production':_0x566591;}function a101_0x385b(){const _0x539139=['6YlztRg','866993qdjZys','dev','6860273ZfMyQa','1279310XnoqKR','1256409OYLWix','70ETAeBB','daily','2185695mYvodi','24548976THOuMb','16FkIxtl','237bacscp','2YRAkfd','ENV','10276kptilz','prod','production','development','online'];a101_0x385b=function(){return _0x539139;};return a101_0x385b();}export function isProduction(_0x463ba2){return normalizeEnv(_0x463ba2)==='production';}export function isDaily(_0x3e21d6){const _0x1c6df6=a101_0x145b50;return normalizeEnv(_0x3e21d6)===_0x1c6df6(0x6b);}export function isDev(_0x1541e9){const _0x2c1b48=a101_0x145b50,_0x237b54=normalizeEnv(_0x1541e9);return _0x237b54===_0x2c1b48(0x75)||_0x237b54===_0x2c1b48(0x79);}let env=normalizeEnv(productEnv(a101_0x145b50(0x71))||'production');function a101_0x22a1(_0x49b809,_0x18aa7){_0x49b809=_0x49b809-0x67;const _0x385b85=a101_0x385b();let _0x22a1c3=_0x385b85[_0x49b809];return _0x22a1c3;}export function getEnv(){return env;}export function initEnv(_0x18ed77){env=normalizeEnv(_0x18ed77);}
|
package/lib/constant/output.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a102_0x1b60ef=a102_0x39c4;(function(_0x5a3bf0,_0x14836d){const _0x5957ad=a102_0x39c4,_0xf305fb=_0x5a3bf0();while(!![]){try{const _0x675505=-parseInt(_0x5957ad(0x13a))/0x1*(parseInt(_0x5957ad(0x133))/0x2)+parseInt(_0x5957ad(0x132))/0x3+parseInt(_0x5957ad(0x12d))/0x4*(parseInt(_0x5957ad(0x139))/0x5)+-parseInt(_0x5957ad(0x135))/0x6*(parseInt(_0x5957ad(0x130))/0x7)+parseInt(_0x5957ad(0x138))/0x8*(-parseInt(_0x5957ad(0x136))/0x9)+-parseInt(_0x5957ad(0x12e))/0xa*(parseInt(_0x5957ad(0x13b))/0xb)+-parseInt(_0x5957ad(0x137))/0xc*(parseInt(_0x5957ad(0x131))/0xd);if(_0x675505===_0x14836d)break;else _0xf305fb['push'](_0xf305fb['shift']());}catch(_0x96fc4a){_0xf305fb['push'](_0xf305fb['shift']());}}}(a102_0x1467,0xabff3));function a102_0x39c4(_0x1a2e44,_0x2aa4a5){_0x1a2e44=_0x1a2e44-0x12d;const _0x146737=a102_0x1467();let _0x39c465=_0x146737[_0x1a2e44];return _0x39c465;}function a102_0x1467(){const _0x279083=['compress','7uSQoLL','9438kkjjDg','4023936LSnaQl','1018FGkWnZ','pretty','3456786odpvZt','44856jArMiB','1344psQqrT','440QuXELh','6370670DzstqW','5TotKTE','3581743WqDRUO','4dFGFBS','30GUcrlP'];a102_0x1467=function(){return _0x279083;};return a102_0x1467();}export const OUTPUT_FORMAT_VALUES=['json',a102_0x1b60ef(0x134),a102_0x1b60ef(0x12f)];
|
package/lib/constant/product.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a103_0x22a8e7=a103_0x4e9e;function a103_0x2652(){const _0x25bac2=['envPrefix','lovrabet','https://g.lovrabet.com','4OfsMNR','.lovrabet-runtime.log','cli:lovrabet-runtime','570846pZHVVx','map','Lovrabet\x20Runtime\x20CLI','git@codeup.aliyun.com:yuntoo/open/lovrabet-runtime-cli.git','LOVRABET','.lovrabet','492587IUmlDH','lovrabet/lovrabet-cli','/user/ak','legacyEnvPrefixes','582136nuOqNy','.lovrabet.json','1568995ZenjUD','985187LKNdrh','72mEMncq','6KTsvip','2542560OEssJo','279782tTrwMg','@lovrabet/lovrabet-cli','Lovrabet\x20User\x20Center','https://registry.npmjs.org'];a103_0x2652=function(){return _0x25bac2;};return a103_0x2652();}(function(_0x2ed7ac,_0x1d88b2){const _0x2b2c03=a103_0x4e9e,_0x2692bc=_0x2ed7ac();while(!![]){try{const _0x3dd022=parseInt(_0x2b2c03(0x1b4))/0x1+parseInt(_0x2b2c03(0x1bf))/0x2+parseInt(_0x2b2c03(0x1c9))/0x3*(parseInt(_0x2b2c03(0x1c6))/0x4)+-parseInt(_0x2b2c03(0x1ba))/0x5*(parseInt(_0x2b2c03(0x1bd))/0x6)+-parseInt(_0x2b2c03(0x1bb))/0x7+parseInt(_0x2b2c03(0x1b8))/0x8*(parseInt(_0x2b2c03(0x1bc))/0x9)+-parseInt(_0x2b2c03(0x1be))/0xa;if(_0x3dd022===_0x1d88b2)break;else _0x2692bc['push'](_0x2692bc['shift']());}catch(_0x5dac33){_0x2692bc['push'](_0x2692bc['shift']());}}}(a103_0x2652,0xa9f24));export const PRODUCT_CONFIG={'cliBinName':a103_0x22a8e7(0x1c4),'cliDisplayName':a103_0x22a8e7(0x1cb),'npmPackageName':a103_0x22a8e7(0x1c0),'skillSource':a103_0x22a8e7(0x1b5),'internalSkillSource':a103_0x22a8e7(0x1cc),'globalSkillName':a103_0x22a8e7(0x1c4),'npmRegistryBaseUrl':a103_0x22a8e7(0x1c2),'cliCdnBaseUrl':a103_0x22a8e7(0x1c5),'envPrefix':a103_0x22a8e7(0x1cd),'legacyEnvPrefixes':['RABETBASE'],'configFileNames':[a103_0x22a8e7(0x1b9)],'newConfigFileName':a103_0x22a8e7(0x1b9),'homeDirName':a103_0x22a8e7(0x1b3),'logFileName':a103_0x22a8e7(0x1c7),'invokeSource':a103_0x22a8e7(0x1c8),'userCenterDisplayName':a103_0x22a8e7(0x1c1),'skipNpxSkillsEnvSuffix':'SKIP_NPX_SKILLS','accessKeyCreatePath':a103_0x22a8e7(0x1b6)};export function productEnvName(_0x30042d){const _0x3e3c18=a103_0x22a8e7;return PRODUCT_CONFIG[_0x3e3c18(0x1c3)]+'_'+_0x30042d;}export function productEnvNames(_0x12cb78){const _0x3887a2=a103_0x22a8e7;return[productEnvName(_0x12cb78),...PRODUCT_CONFIG[_0x3887a2(0x1b7)][_0x3887a2(0x1ca)](_0x35bd81=>_0x35bd81+'_'+_0x12cb78)];}function a103_0x4e9e(_0xb8ad0c,_0xaec130){_0xb8ad0c=_0xb8ad0c-0x1b3;const _0x2652cb=a103_0x2652();let _0x4e9e33=_0x2652cb[_0xb8ad0c];return _0x4e9e33;}export function productEnv(_0x4f3499){for(const _0xafd924 of productEnvNames(_0x4f3499)){const _0x1649b8=process.env[_0xafd924];if(_0x1649b8!==undefined)return _0x1649b8;}return undefined;}
|
package/lib/constant/region.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a104_0x2969(){const _0x33c241=['6112656FcOfkV','validation','\x22\x20is\x20not\x20currently\x20available.','549464YSaWZI','string','Region\x20\x22','557544vkOdIE','66457qnNiFw','138103szGoOf','includes','Available\x20regions:\x20','Run\x20`lovrabet\x20config\x20init`\x20to\x20restore\x20the\x20global\x20country/region\x20configuration.','Invalid\x20region\x20value:\x20expected\x20a\x20string,\x20received\x20','4HcevMd','1640748jzqUwz','9vUyvJQ','.\x20Run\x20`lovrabet\x20config\x20init`\x20to\x20repair\x20the\x20global\x20configuration.','join','17439070kxviOz','5iVSDmy'];a104_0x2969=function(){return _0x33c241;};return a104_0x2969();}(function(_0xe4dc27,_0x51ca28){const _0x2f88fe=a104_0x31b4,_0x1381df=_0xe4dc27();while(!![]){try{const _0x32499e=-parseInt(_0x2f88fe(0xcf))/0x1*(-parseInt(_0x2f88fe(0xd5))/0x2)+parseInt(_0x2f88fe(0xce))/0x3+-parseInt(_0x2f88fe(0xd6))/0x4+parseInt(_0x2f88fe(0xc7))/0x5*(-parseInt(_0x2f88fe(0xc8))/0x6)+-parseInt(_0x2f88fe(0xd0))/0x7+-parseInt(_0x2f88fe(0xcb))/0x8+parseInt(_0x2f88fe(0xc3))/0x9*(parseInt(_0x2f88fe(0xc6))/0xa);if(_0x32499e===_0x51ca28)break;else _0x1381df['push'](_0x1381df['shift']());}catch(_0x1de831){_0x1381df['push'](_0x1381df['shift']());}}}(a104_0x2969,0x8520e));import{DEFAULT_REGION,ENABLED_REGION_VALUES,REGION_ALIASES,REGION_VALUES}from'../generated/official-routing.js';import{CliErrors}from'../errors.js';export const LOVRABET_REGION_VALUES=REGION_VALUES;export const ENABLED_LOVRABET_REGION_VALUES=ENABLED_REGION_VALUES;export const DEFAULT_LOVRABET_REGION=DEFAULT_REGION;function a104_0x31b4(_0x40139e,_0x5475b0){_0x40139e=_0x40139e-0xc3;const _0x2969e4=a104_0x2969();let _0x31b415=_0x2969e4[_0x40139e];return _0x31b415;}export function isLovrabetRegion(_0x2e60e1){const _0x2458f9=a104_0x31b4;return typeof _0x2e60e1==='string'&&LOVRABET_REGION_VALUES[_0x2458f9(0xd1)](_0x2e60e1);}export function isEnabledLovrabetRegion(_0x229e1b){const _0x2203e4=a104_0x31b4;return typeof _0x229e1b===_0x2203e4(0xcc)&&ENABLED_LOVRABET_REGION_VALUES[_0x2203e4(0xd1)](_0x229e1b);}export function normalizeLovrabetRegion(_0x2fa43e){const _0x165688=a104_0x31b4;if(_0x2fa43e===undefined||_0x2fa43e===null||_0x2fa43e==='')return DEFAULT_LOVRABET_REGION;if(typeof _0x2fa43e!==_0x165688(0xcc))throw CliErrors['validation'](_0x165688(0xd4)+typeof _0x2fa43e+'.',_0x165688(0xd3));const _0x5aee32=REGION_ALIASES[_0x2fa43e]??_0x2fa43e;if(isEnabledLovrabetRegion(_0x5aee32))return _0x5aee32;throw CliErrors[_0x165688(0xc9)](_0x165688(0xcd)+_0x2fa43e+_0x165688(0xca),_0x165688(0xd2)+ENABLED_LOVRABET_REGION_VALUES[_0x165688(0xc5)](',\x20')+_0x165688(0xc4));}
|
package/lib/constant/risk.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a105_0x4217ba=a105_0x11a1;function a105_0x3c78(){const _0x4980d0=['6blSpTg','27097202WuufDZ','7sdkedE','3384930VrYRIY','5529608TkCgYf','7177304FeraAi','high-risk-write','1BxKCax','498114UyDOXQ','read','260RlOLOb','106712GWEsng','1605072dVxTIa'];a105_0x3c78=function(){return _0x4980d0;};return a105_0x3c78();}(function(_0x775ce5,_0x2155a7){const _0x387e5d=a105_0x11a1,_0x2241fe=_0x775ce5();while(!![]){try{const _0x1c43f8=parseInt(_0x387e5d(0x196))/0x1*(parseInt(_0x387e5d(0x19a))/0x2)+-parseInt(_0x387e5d(0x19b))/0x3+-parseInt(_0x387e5d(0x1a0))/0x4+parseInt(_0x387e5d(0x19f))/0x5*(parseInt(_0x387e5d(0x19c))/0x6)+parseInt(_0x387e5d(0x19e))/0x7*(parseInt(_0x387e5d(0x1a1))/0x8)+parseInt(_0x387e5d(0x197))/0x9*(-parseInt(_0x387e5d(0x199))/0xa)+parseInt(_0x387e5d(0x19d))/0xb;if(_0x1c43f8===_0x2155a7)break;else _0x2241fe['push'](_0x2241fe['shift']());}catch(_0x38e1e3){_0x2241fe['push'](_0x2241fe['shift']());}}}(a105_0x3c78,0xb3501));function a105_0x11a1(_0x1fcbbd,_0x586a97){_0x1fcbbd=_0x1fcbbd-0x195;const _0x3c78f5=a105_0x3c78();let _0x11a192=_0x3c78f5[_0x1fcbbd];return _0x11a192;}export const RISK_LEVEL_VALUES=[a105_0x4217ba(0x198),'write',a105_0x4217ba(0x195)];
|
package/lib/constant/url.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5ef809,_0x1b011d){const _0x929b63=a106_0x4651,_0x37e551=_0x5ef809();while(!![]){try{const _0x18a47e=parseInt(_0x929b63(0x13b))/0x1+-parseInt(_0x929b63(0x13a))/0x2+parseInt(_0x929b63(0x144))/0x3+parseInt(_0x929b63(0x142))/0x4+parseInt(_0x929b63(0x143))/0x5*(parseInt(_0x929b63(0x138))/0x6)+parseInt(_0x929b63(0x140))/0x7*(parseInt(_0x929b63(0x13e))/0x8)+parseInt(_0x929b63(0x13c))/0x9*(-parseInt(_0x929b63(0x139))/0xa);if(_0x18a47e===_0x1b011d)break;else _0x37e551['push'](_0x37e551['shift']());}catch(_0x18c06d){_0x37e551['push'](_0x37e551['shift']());}}}(a106_0x4155,0xb392a));function a106_0x4651(_0x38a32a,_0x35ad44){_0x38a32a=_0x38a32a-0x138;const _0x415525=a106_0x4155();let _0x465173=_0x415525[_0x38a32a];return _0x465173;}import{PRODUCT_CONFIG}from'../constant/product.js';import{OFFICIAL_ROUTING_PROFILES}from'../generated/official-routing.js';function a106_0x4155(){const _0x28be78=['production','1788588RJowsJ','27015oSmSLb','622578MgBaia','1038YNnyfD','10cdzzTW','271950VEZFzz','12546bYDvWV','16183161pJogeD','accessKeyCreatePath','128JMBegM','user','467117RTRBTc'];a106_0x4155=function(){return _0x28be78;};return a106_0x4155();}import{DEFAULT_LOVRABET_REGION}from'../constant/region.js';export function getUserAccessKeyCreateUrl(_0x452ce6=DEFAULT_LOVRABET_REGION){const _0x37fd53=a106_0x4651,_0x51ea0a=OFFICIAL_ROUTING_PROFILES[_0x452ce6]['serviceDomains'][_0x37fd53(0x141)][_0x37fd53(0x13f)];return''+_0x51ea0a+PRODUCT_CONFIG[_0x37fd53(0x13d)];}export const USER_ACCESS_KEY_CREATE_URL=getUserAccessKeyCreateUrl();
|
package/lib/context.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x3b21d2,_0x475cbf){const _0x93fc4e=a107_0x84ab,_0x2d631d=_0x3b21d2();while(!![]){try{const _0x34245b=-parseInt(_0x93fc4e(0x17b))/0x1+-parseInt(_0x93fc4e(0x163))/0x2+-parseInt(_0x93fc4e(0x162))/0x3*(parseInt(_0x93fc4e(0x192))/0x4)+-parseInt(_0x93fc4e(0x1b1))/0x5*(-parseInt(_0x93fc4e(0x196))/0x6)+-parseInt(_0x93fc4e(0x167))/0x7*(parseInt(_0x93fc4e(0x174))/0x8)+-parseInt(_0x93fc4e(0x1a5))/0x9*(parseInt(_0x93fc4e(0x1a0))/0xa)+parseInt(_0x93fc4e(0x1b5))/0xb*(parseInt(_0x93fc4e(0x1aa))/0xc);if(_0x34245b===_0x475cbf)break;else _0x2d631d['push'](_0x2d631d['shift']());}catch(_0x14e804){_0x2d631d['push'](_0x2d631d['shift']());}}}(a107_0x299f,0xec66a));function a107_0x299f(){const _0xfa1d13=['read','locale','ACCESS_KEY','39905nhyeuN','.tmp','missing','region','11qMUSGE','apiDomain','nativeToolAvailable','PAGE_SIZE','69sSJLQg','2302050jHJcfF','./constant/env.js','accessKey','find','1591156LGZthv','code','explicit','project','platformDomain','stdout','agentDomain','empty','top-level','EACCES','online','projectConfig','./constant/domain.js','40incEFI','object','stringify','setRawCommand','harnessDomain','defaultApp','skillDomain','112970wOFUZq','isRaw','stdin','high-risk-write','global','write','global\x20config','error','VERBOSE','apps','string','raw','skillHubDomain','development','globalConfig','app','routing','production','setLogPath','APP','env','join','appCode','315184lGAdfe','kbServiceDomain','message','trim','1002bSwHYN','authRequired','FORMAT','nonInteractive','runtimeDomain','cache','true','parse','setRawMode','cwd','13221810SMvLyZ','riskLevel','userDomain','format','local-alias','9lbecEq','EPERM','utf8','APPCODE','isTTY','62045940bQVKNX','values','slice','appcode'];a107_0x299f=function(){return _0xfa1d13;};return a107_0x299f();}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{redactCommandArgv}from'./utils/redaction.js';function a107_0x84ab(_0x3d8564,_0x54d06b){_0x3d8564=_0x3d8564-0x161;const _0x299f21=a107_0x299f();let _0x84ab77=_0x299f21[_0x3d8564];return _0x84ab77;}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';import{normalizeLovrabetRegion}from'./constant/region.js';import{normalizeDomainOrigin,resolveEnterpriseRoutingConfig}from'./config/domain-config.js';export{AUTH_MODE,isAuthMode}from'./constant/auth-mode.js';const CONFIG_NAMES=PRODUCT_CONFIG['configFileNames'];export const NEW_CONFIG_NAME=PRODUCT_CONFIG['newConfigFileName'];function resolveConfigPath(_0x3a4943){for(const _0x352696 of CONFIG_NAMES){const _0x30ee3a=resolve(_0x3a4943,_0x352696);if(existsSync(_0x30ee3a))return _0x30ee3a;}return undefined;}export function resolveWriteConfigPath(_0x17e863){const _0x365c34=a107_0x84ab,_0x55c7e9=_0x17e863===_0x365c34(0x16a)?process[_0x365c34(0x19f)]():homedir(),_0x3af103=resolveConfigPath(_0x55c7e9);return _0x3af103??resolve(_0x55c7e9,NEW_CONFIG_NAME);}export function readConfigFile(_0x4a616b){const _0xd9c31c=a107_0x84ab;try{if(existsSync(_0x4a616b)){const _0x5015a6=readFileSync(_0x4a616b,{'encoding':'utf8'});if(_0x5015a6){const _0x1371ae=JSON[_0xd9c31c(0x19d)](_0x5015a6);return migrateOnlineEnv(_0x4a616b,_0x1371ae),_0x1371ae;}}}catch{}return{};}function migrateOnlineEnv(_0x5ce39a,_0xcb17e6){const _0x211747=a107_0x84ab;let _0x572598=![];_0xcb17e6[_0x211747(0x18f)]===_0x211747(0x171)&&(_0xcb17e6[_0x211747(0x18f)]=_0x211747(0x18c),_0x572598=!![]);if(_0xcb17e6[_0x211747(0x184)]&&typeof _0xcb17e6['apps']===_0x211747(0x175))for(const _0x578301 of Object[_0x211747(0x1ab)](_0xcb17e6[_0x211747(0x184)])){_0x578301&&_0x578301['env']===_0x211747(0x171)&&(_0x578301[_0x211747(0x18f)]=_0x211747(0x18c),_0x572598=!![]);}if(_0x572598)try{writeConfigFile(_0x5ce39a,_0xcb17e6);}catch{}}export function writeConfigFile(_0x2694eb,_0x485ed1){const _0x5e69b5=a107_0x84ab,_0xb5028b=dirname(_0x2694eb);!existsSync(_0xb5028b)&&mkdirSync(_0xb5028b,{'recursive':!![]});const _0x331b95=_0x2694eb+_0x5e69b5(0x1b2);try{writeFileSync(_0x331b95,JSON['stringify'](_0x485ed1,null,0x2)+'\x0a',{'encoding':_0x5e69b5(0x1a7),'mode':0x180});try{renameSync(_0x331b95,_0x2694eb);}catch(_0xa3717a){if(_0xa3717a[_0x5e69b5(0x168)]===_0x5e69b5(0x1a6)||_0xa3717a[_0x5e69b5(0x168)]==='EXDEV'||_0xa3717a['code']===_0x5e69b5(0x170)){writeFileSync(_0x2694eb,JSON[_0x5e69b5(0x176)](_0x485ed1,null,0x2)+'\x0a',{'encoding':_0x5e69b5(0x1a7)});try{unlinkSync(_0x331b95);}catch{}}else throw _0xa3717a;}}catch(_0x3c3512){try{unlinkSync(_0x331b95);}catch{}throw _0x3c3512;}}export function isNonInteractiveMode(_0x510e4f){const _0x1fac3b=a107_0x84ab;return!!(_0x510e4f[_0x1fac3b(0x199)]||_0x510e4f['ci']||productEnvNames('CI')['some'](_0x592b3e=>process.env[_0x592b3e]===_0x1fac3b(0x19c))||process.env.CI===_0x1fac3b(0x19c)||!process[_0x1fac3b(0x16c)][_0x1fac3b(0x1a9)]||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x3e0937=a107_0x84ab;if(!process['stdin'][_0x3e0937(0x1a9)])return![];try{const _0x3046a2=process[_0x3e0937(0x17d)][_0x3e0937(0x17c)];return process[_0x3e0937(0x17d)]['setRawMode'](!![]),process[_0x3e0937(0x17d)][_0x3e0937(0x19e)](_0x3046a2??![]),!![];}catch{return![];}}export async function createContext(_0x32bf77){const _0x266b4c=a107_0x84ab,_0x1caea6=buildConfigFromFlags(_0x32bf77);await initGlobalEnvironment(_0x1caea6);const {getUserDomain:_0x5ac55b,getApiDomain:_0x3f2b01}=await import(_0x266b4c(0x173)),_0x57a701={'apiDomain':_0x3f2b01(),'userDomain':_0x5ac55b()},_0x43f9ae=await buildAuth(_0x1caea6);logger[_0x266b4c(0x18d)](process[_0x266b4c(0x19f)]());const _0x1d00af=(CLI_BIN_NAME+'\x20'+redactCommandArgv(process['argv'][_0x266b4c(0x1ac)](0x2))[_0x266b4c(0x190)]('\x20'))['trim']();logger[_0x266b4c(0x177)](_0x1d00af);const _0xcc4644=isNonInteractiveMode(_0x32bf77);return{'config':_0x1caea6,'auth':_0x43f9ae,'logger':logger,'env':_0x57a701,'nonInteractive':_0xcc4644};}export function buildConfigFromFlags(_0x5dc96e){return buildConfig(loadRawConfigLayers(),_0x5dc96e);}export function getLocalAppAliases(_0x1e1d66){const _0x27bd67=a107_0x84ab;return _0x1e1d66[_0x27bd67(0x184)]&&typeof _0x1e1d66[_0x27bd67(0x184)]==='object'?_0x1e1d66[_0x27bd67(0x184)]:{};}export function resolveLocalAppAliasCode(_0x225eba,_0x5100ce){const _0x23d4e3=a107_0x84ab;if(!_0x5100ce)return undefined;const _0xf2a062=getLocalAppAliases(_0x225eba)[_0x5100ce],_0x36e7c3=_0xf2a062?.['appcode'];return typeof _0x36e7c3===_0x23d4e3(0x185)&&_0x36e7c3['trim']()?_0x36e7c3[_0x23d4e3(0x195)]():undefined;}export function readAppCodeFromConfig(){const _0x42f7df=a107_0x84ab;return buildConfigFromFlags({})[_0x42f7df(0x191)];}export function readScopedConfig(_0x16e6ce){const _0x233b10=a107_0x84ab,_0x21c7b5=_0x16e6ce['global']?_0x233b10(0x17f):_0x233b10(0x16a);return readConfigFile(resolveWriteConfigPath(_0x21c7b5));}export function writeScopedConfig(_0x3c994d,_0x2d161e){const _0x14649c=a107_0x84ab,_0x40dc96=_0x2d161e['global']?_0x14649c(0x17f):_0x14649c(0x16a);writeConfigFile(resolveWriteConfigPath(_0x40dc96),_0x3c994d);}export async function initGlobalEnvironment(_0x2e3eef){const _0x4bcc4d=a107_0x84ab,{initEnv:_0x203087}=await import(_0x4bcc4d(0x164));_0x203087(_0x2e3eef[_0x4bcc4d(0x18f)]);const {initDomains:_0x1ca435}=await import(_0x4bcc4d(0x173)),_0x371454=resolveEnterpriseRoutingConfig(_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x18b)]);_0x1ca435({'apiDomain':_0x371454?_0x371454[_0x4bcc4d(0x1b6)]:_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x1b6)]||_0x2e3eef['raw']['host']||undefined,'userDomain':_0x371454?_0x371454[_0x4bcc4d(0x1a2)]:_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x1a2)]||undefined,'runtimeDomain':_0x371454?_0x371454[_0x4bcc4d(0x19a)]:_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x19a)]||undefined,'skillDomain':_0x371454?_0x371454['skillDomain']:_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x17a)]||_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x187)]||_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x16d)]||_0x2e3eef['raw'][_0x4bcc4d(0x16b)]||undefined,'kbServiceDomain':_0x371454?_0x371454[_0x4bcc4d(0x193)]:typeof _0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x193)]==='string'&&_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x193)][_0x4bcc4d(0x195)]()?_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x193)]:undefined,'harnessDomain':_0x371454?_0x371454[_0x4bcc4d(0x178)]:_0x2e3eef['raw'][_0x4bcc4d(0x178)]===undefined?undefined:normalizeDomainOrigin(_0x4bcc4d(0x178),_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x178)]),'region':normalizeLovrabetRegion(_0x2e3eef[_0x4bcc4d(0x186)][_0x4bcc4d(0x1b4)])});}export function getProjectConfigPath(){const _0x17eec6=a107_0x84ab;return resolveConfigPath(process[_0x17eec6(0x19f)]());}export function getGlobalConfigPath(){return resolveConfigPath(homedir());}export function inspectCliConfigJsonFile(_0x58c314){const _0x1803e4=a107_0x84ab;if(!existsSync(_0x58c314))return{'status':_0x1803e4(0x1b3)};try{const _0xbb1049=readFileSync(_0x58c314,{'encoding':'utf8'});if(!_0xbb1049?.[_0x1803e4(0x195)]())return{'status':_0x1803e4(0x16e)};const _0x570816=JSON[_0x1803e4(0x19d)](_0xbb1049);return{'status':'ok','data':_0x570816};}catch(_0x130074){return{'status':_0x1803e4(0x182),'message':_0x130074 instanceof Error?_0x130074[_0x1803e4(0x194)]:String(_0x130074)};}}export function loadRawConfigLayers(_0x294906){const _0x3b42dd=a107_0x84ab;let _0x5c0fef={},_0x5796c3={},_0x4f44a9,_0x337e3d;try{_0x4f44a9=resolveConfigPath(homedir());if(_0x4f44a9){const _0x1c1688=readFileSync(_0x4f44a9,{'encoding':_0x3b42dd(0x1a7)});if(_0x1c1688)_0x5c0fef=JSON[_0x3b42dd(0x19d)](_0x1c1688);}}catch{}try{const _0x5eb23f=_0x294906||process[_0x3b42dd(0x19f)]();_0x337e3d=resolveConfigPath(_0x5eb23f);if(_0x337e3d){const _0x2603a3=readFileSync(_0x337e3d,{'encoding':_0x3b42dd(0x1a7)});if(_0x2603a3)_0x5796c3=JSON['parse'](_0x2603a3);}}catch{}return{'globalPath':_0x4f44a9,'projectPath':_0x337e3d,'globalConfig':_0x5c0fef,'projectConfig':_0x5796c3};}function mergeRawConfigLayers(_0x52742d){const _0x337959=a107_0x84ab,{globalConfig:_0x402205,projectConfig:_0x5480e8}=_0x52742d,_0x57ce93={..._0x402205,..._0x5480e8};delete _0x57ce93['inherit'];if('defaultApp'in _0x5480e8)_0x57ce93[_0x337959(0x179)]=_0x5480e8[_0x337959(0x179)];else _0x402205[_0x337959(0x179)]&&(_0x57ce93['defaultApp']=_0x402205['defaultApp']);return _0x57ce93;}export function isInProject(){return!!getProjectConfigPath();}export function readRawConfig(_0x3e6c40){return mergeRawConfigLayers(loadRawConfigLayers(_0x3e6c40));}export function readRawConfigWithLayers(_0x1ccbd6){const _0x201061=loadRawConfigLayers(_0x1ccbd6);return{'config':mergeRawConfigLayers(_0x201061),'layers':_0x201061};}export function resolveDefaultAppSource(_0x1cfdc1){const _0x2030a2=a107_0x84ab;if(_0x2030a2(0x179)in _0x1cfdc1[_0x2030a2(0x172)])return'project';if(_0x1cfdc1[_0x2030a2(0x189)]['defaultApp'])return'global';return null;}function buildConfig(_0x4dd753,_0x5ad163){const _0x259b5e=a107_0x84ab,_0x2c7a6b=mergeRawConfigLayers(_0x4dd753),{projectConfig:_0x482b8d}=_0x4dd753,_0x4fe2c2=_0x2c7a6b[_0x259b5e(0x179)]||undefined,_0x2dfbe5=typeof _0x5ad163[_0x259b5e(0x1ad)]===_0x259b5e(0x185)?_0x5ad163[_0x259b5e(0x1ad)]:undefined,_0x5155eb=_0x482b8d[_0x259b5e(0x1ad)]||_0x482b8d[_0x259b5e(0x18a)],_0x28b94f=!_0x2dfbe5&&!_0x5ad163[_0x259b5e(0x18a)]&&!_0x5155eb&&!_0x482b8d['defaultApp'],_0x50f0fc=_0x28b94f?env(_0x259b5e(0x1a8)):undefined,_0x504180=_0x5ad163[_0x259b5e(0x18a)]||(_0x28b94f&&!_0x50f0fc?env(_0x259b5e(0x18e)):undefined),_0xb9d095=_0x504180||_0x4fe2c2||undefined,_0x53a23d=_0x504180||_0x50f0fc?undefined:_0x5155eb||(_0x482b8d[_0x259b5e(0x179)]?undefined:_0x2c7a6b[_0x259b5e(0x1ad)]||_0x2c7a6b[_0x259b5e(0x18a)]||undefined),_0x5af21e=_0x504180||(_0x53a23d?undefined:_0x4fe2c2),_0x2c14b5=resolveLocalAppAliasCode(_0x2c7a6b,_0x5af21e),_0x54353a=productEnvNames(_0x259b5e(0x1b0))[_0x259b5e(0x166)](_0x8cea7f=>process.env[_0x8cea7f]!==undefined),_0x431e98=_0x54353a?process.env[_0x54353a]:undefined,_0x202a41=_0x482b8d[_0x259b5e(0x165)]||_0x431e98||_0x2c7a6b[_0x259b5e(0x165)]||undefined,_0x368499=_0x482b8d[_0x259b5e(0x165)]?'project\x20config':_0x431e98?_0x54353a:_0x2c7a6b[_0x259b5e(0x165)]?_0x259b5e(0x181):undefined,_0x57f911=_0x5ad163[_0x259b5e(0x18f)]||_0x2c7a6b[_0x259b5e(0x18f)]||env('ENV')||DEFAULT_CONFIG_VALUES[_0x259b5e(0x18f)],_0x5c2b59=normalizeEnv(String(_0x57f911)),_0x3ea723=isDaily(_0x5c2b59)?'daily':isDev(_0x5c2b59)?_0x259b5e(0x188):_0x259b5e(0x18c),_0x16bade=_0x2dfbe5||_0x50f0fc||_0x53a23d||_0x2c14b5?undefined:resolveCachedAppCode(_0x5af21e,_0x3ea723,_0x202a41),_0x533eb4=_0x2dfbe5||_0x50f0fc||_0x53a23d||_0x2c14b5||_0x16bade||undefined,_0x44e921=_0x2dfbe5?_0x259b5e(0x169):_0x50f0fc?'env':_0x53a23d?_0x259b5e(0x16f):_0x2c14b5?_0x259b5e(0x1a4):_0x16bade?_0x259b5e(0x19b):undefined,_0x2f13d0=_0x2c7a6b[_0x259b5e(0x1af)]||DEFAULT_CONFIG_VALUES['locale'],_0x56fc4a=undefined,_0x3cd3dc=_0x5ad163[_0x259b5e(0x1a3)]||env(_0x259b5e(0x198))||_0x2c7a6b[_0x259b5e(0x1a3)],_0x172ede=normalizeLegacyOutputFormat(_0x3cd3dc),_0x114da9=env(_0x259b5e(0x161))||_0x2c7a6b['pageSize'],_0x5bc772=_0x114da9?Number(_0x114da9)||undefined:undefined,_0x3d3f49=_0x2c7a6b[_0x259b5e(0x1a1)],_0x1c3f49=_0x3d3f49===_0x259b5e(0x1ae)||_0x3d3f49===_0x259b5e(0x180)||_0x3d3f49===_0x259b5e(0x17e)?_0x3d3f49:DEFAULT_CONFIG_VALUES[_0x259b5e(0x1a1)],_0x574bb9=_0x2c7a6b[_0x259b5e(0x1b7)]===!![],_0x2b4cbb=env(_0x259b5e(0x183)),_0x3bdca0=_0x2b4cbb==='1'||_0x2b4cbb===_0x259b5e(0x19c);return{'appCode':typeof _0x533eb4===_0x259b5e(0x185)&&_0x533eb4[_0x259b5e(0x195)]()?_0x533eb4[_0x259b5e(0x195)]():undefined,'appCodeSource':_0x44e921,'env':_0x3ea723,'locale':_0x2f13d0,'cookie':_0x56fc4a,'accessKey':_0x202a41,'accessKeySource':_0x368499,'format':_0x172ede,'pageSize':_0x5bc772,'riskLevel':_0x1c3f49,'nativeToolAvailable':_0x574bb9,'verbose':_0x3bdca0,'defaultApp':_0x4fe2c2,'currentApp':typeof _0xb9d095==='string'?_0xb9d095:undefined,'raw':_0x2c7a6b};}function env(_0x181378){return productEnv(_0x181378);}async function buildAuth(_0x55c0aa){const _0x263b85=a107_0x84ab,_0x285f9b='',_0x4162b9=!!_0x55c0aa[_0x263b85(0x165)];return{'cookie':_0x285f9b,'isLoggedIn':_0x4162b9,async 'getOrLogin'(){const _0x2a2bc1=_0x263b85;if(_0x4162b9)return _0x285f9b;throw CliErrors[_0x2a2bc1(0x197)]();}};}
|
|
1
|
+
const a107_0x2477f2=a107_0x3bba;(function(_0xaf4d3a,_0x32212e){const _0x12aff0=a107_0x3bba,_0x5802b0=_0xaf4d3a();while(!![]){try{const _0x44c816=parseInt(_0x12aff0(0x9c))/0x1*(parseInt(_0x12aff0(0x90))/0x2)+parseInt(_0x12aff0(0xc0))/0x3+-parseInt(_0x12aff0(0xb6))/0x4*(-parseInt(_0x12aff0(0xc7))/0x5)+-parseInt(_0x12aff0(0x93))/0x6+parseInt(_0x12aff0(0xc6))/0x7*(parseInt(_0x12aff0(0xb4))/0x8)+-parseInt(_0x12aff0(0x8a))/0x9*(-parseInt(_0x12aff0(0xb2))/0xa)+-parseInt(_0x12aff0(0x95))/0xb;if(_0x44c816===_0x32212e)break;else _0x5802b0['push'](_0x5802b0['shift']());}catch(_0x3dac){_0x5802b0['push'](_0x5802b0['shift']());}}}(a107_0xefb6,0x4f614));import{readFileSync,existsSync,mkdirSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import{resolve,dirname}from'node:path';function a107_0x3bba(_0x476d7c,_0x4bc80c){_0x476d7c=_0x476d7c-0x7f;const _0xefb625=a107_0xefb6();let _0x3bba24=_0xefb625[_0x476d7c];return _0x3bba24;}import{homedir}from'node:os';import{logger}from'./utils/logger.js';import{redactCommandArgv}from'./utils/redaction.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';function a107_0xefb6(){const _0x457836=['EPERM','EXDEV','app','./constant/env.js','isTTY','values','join','runtimeDomain','8901aUdMAn','configFileNames','stdin','object','nonInteractive','error','1215512jHaeAc','trim','pageSize','881532UmOskQ','online','25528151zUkUdH','write','skillHubDomain','message','accessKey','userDomain','harnessDomain','1sjgsZJ','riskLevel','raw','routing','global','missing','locale','apps','production','skillDomain','parse','utf8','cwd','explicit','defaultApp','kbServiceDomain','projectConfig','setRawMode','string','isRaw','format','globalConfig','5410YpcuML','apiDomain','144RTPmkR','local-alias','4652nhJabS','stdout','.tmp','true','PAGE_SIZE','empty','nativeToolAvailable','platformDomain','host','stringify','1663515vOaOvj','cache','ENV','project','agentDomain','env','250089GDCxVW','1945FdTZjY','find','high-risk-write','appCode','setLogPath','code','slice','appcode','./constant/domain.js','development','setRawCommand'];a107_0xefb6=function(){return _0x457836;};return a107_0xefb6();}import{normalizeLegacyOutputFormat}from'./framework/types.js';import{resolveCachedAppCode}from'./commands/app/cache.js';import{normalizeLovrabetRegion}from'./constant/region.js';import{normalizeDomainOrigin,resolveEnterpriseRoutingConfig}from'./config/domain-config.js';export{AUTH_MODE,isAuthMode}from'./constant/auth-mode.js';const CONFIG_NAMES=PRODUCT_CONFIG[a107_0x2477f2(0x8b)];export const NEW_CONFIG_NAME=PRODUCT_CONFIG['newConfigFileName'];function resolveConfigPath(_0x398e84){for(const _0x3067a6 of CONFIG_NAMES){const _0x242e48=resolve(_0x398e84,_0x3067a6);if(existsSync(_0x242e48))return _0x242e48;}return undefined;}export function resolveWriteConfigPath(_0x2f4a29){const _0xeaf3e1=a107_0x2477f2,_0x490e1a=_0x2f4a29===_0xeaf3e1(0xc3)?process[_0xeaf3e1(0xa8)]():homedir(),_0x56a2c1=resolveConfigPath(_0x490e1a);return _0x56a2c1??resolve(_0x490e1a,NEW_CONFIG_NAME);}export function readConfigFile(_0x49006c){const _0x21e0d7=a107_0x2477f2;try{if(existsSync(_0x49006c)){const _0x1509b7=readFileSync(_0x49006c,{'encoding':_0x21e0d7(0xa7)});if(_0x1509b7){const _0x1c25c5=JSON['parse'](_0x1509b7);return migrateOnlineEnv(_0x49006c,_0x1c25c5),_0x1c25c5;}}}catch{}return{};}function migrateOnlineEnv(_0x4617d0,_0x1c930b){const _0x4069d7=a107_0x2477f2;let _0x7a1105=![];_0x1c930b[_0x4069d7(0xc5)]===_0x4069d7(0x94)&&(_0x1c930b[_0x4069d7(0xc5)]=_0x4069d7(0xa4),_0x7a1105=!![]);if(_0x1c930b['apps']&&typeof _0x1c930b[_0x4069d7(0xa3)]===_0x4069d7(0x8d))for(const _0x23c315 of Object[_0x4069d7(0x87)](_0x1c930b[_0x4069d7(0xa3)])){_0x23c315&&_0x23c315['env']==='online'&&(_0x23c315[_0x4069d7(0xc5)]='production',_0x7a1105=!![]);}if(_0x7a1105)try{writeConfigFile(_0x4617d0,_0x1c930b);}catch{}}export function writeConfigFile(_0x25dc6a,_0x34573e){const _0x2d2845=a107_0x2477f2,_0xaa8688=dirname(_0x25dc6a);!existsSync(_0xaa8688)&&mkdirSync(_0xaa8688,{'recursive':!![]});const _0x3ec359=_0x25dc6a+_0x2d2845(0xb8);try{writeFileSync(_0x3ec359,JSON['stringify'](_0x34573e,null,0x2)+'\x0a',{'encoding':_0x2d2845(0xa7),'mode':0x180});try{renameSync(_0x3ec359,_0x25dc6a);}catch(_0x3c7f73){if(_0x3c7f73[_0x2d2845(0xcc)]===_0x2d2845(0x82)||_0x3c7f73['code']===_0x2d2845(0x83)||_0x3c7f73[_0x2d2845(0xcc)]==='EACCES'){writeFileSync(_0x25dc6a,JSON[_0x2d2845(0xbf)](_0x34573e,null,0x2)+'\x0a',{'encoding':_0x2d2845(0xa7)});try{unlinkSync(_0x3ec359);}catch{}}else throw _0x3c7f73;}}catch(_0x46a6a4){try{unlinkSync(_0x3ec359);}catch{}throw _0x46a6a4;}}export function isNonInteractiveMode(_0x294c96){const _0x4a826f=a107_0x2477f2;return!!(_0x294c96[_0x4a826f(0x8e)]||_0x294c96['ci']||productEnvNames('CI')['some'](_0x5ded2b=>process.env[_0x5ded2b]===_0x4a826f(0xb9))||process.env.CI==='true'||!process[_0x4a826f(0xb7)][_0x4a826f(0x86)]||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0xbf8622=a107_0x2477f2;if(!process[_0xbf8622(0x8c)][_0xbf8622(0x86)])return![];try{const _0x58d82e=process[_0xbf8622(0x8c)][_0xbf8622(0xaf)];return process['stdin'][_0xbf8622(0xad)](!![]),process[_0xbf8622(0x8c)][_0xbf8622(0xad)](_0x58d82e??![]),!![];}catch{return![];}}export async function createContext(_0x3d0dad){const _0xcbc421=a107_0x2477f2,_0x3f178a=buildConfigFromFlags(_0x3d0dad);await initGlobalEnvironment(_0x3f178a);const {getUserDomain:_0x154729,getApiDomain:_0xc42829}=await import(_0xcbc421(0x7f)),_0x26b6de={'apiDomain':_0xc42829(),'userDomain':_0x154729()},_0x276600=await buildAuth(_0x3f178a);logger[_0xcbc421(0xcb)](process[_0xcbc421(0xa8)]());const _0x30a00b=(CLI_BIN_NAME+'\x20'+redactCommandArgv(process['argv'][_0xcbc421(0xcd)](0x2))[_0xcbc421(0x88)]('\x20'))[_0xcbc421(0x91)]();logger[_0xcbc421(0x81)](_0x30a00b);const _0x190a03=isNonInteractiveMode(_0x3d0dad);return{'config':_0x3f178a,'auth':_0x276600,'logger':logger,'env':_0x26b6de,'nonInteractive':_0x190a03};}export function buildConfigFromFlags(_0x59c9f7){return buildConfig(loadRawConfigLayers(),_0x59c9f7);}export function getLocalAppAliases(_0x4ccff8){const _0x50366=a107_0x2477f2;return _0x4ccff8[_0x50366(0xa3)]&&typeof _0x4ccff8[_0x50366(0xa3)]===_0x50366(0x8d)?_0x4ccff8[_0x50366(0xa3)]:{};}export function resolveLocalAppAliasCode(_0x2413d2,_0x367b47){const _0x1fb66f=a107_0x2477f2;if(!_0x367b47)return undefined;const _0x428645=getLocalAppAliases(_0x2413d2)[_0x367b47],_0xa85a30=_0x428645?.[_0x1fb66f(0xce)];return typeof _0xa85a30===_0x1fb66f(0xae)&&_0xa85a30[_0x1fb66f(0x91)]()?_0xa85a30['trim']():undefined;}export function readAppCodeFromConfig(){const _0x30091c=a107_0x2477f2;return buildConfigFromFlags({})[_0x30091c(0xca)];}export function readScopedConfig(_0x30fc86){const _0x1c5222=a107_0x2477f2,_0x2a907a=_0x30fc86['global']?_0x1c5222(0xa0):_0x1c5222(0xc3);return readConfigFile(resolveWriteConfigPath(_0x2a907a));}export function writeScopedConfig(_0x32ca88,_0x10695b){const _0x3bbbc0=a107_0x2477f2,_0x1018f2=_0x10695b['global']?'global':_0x3bbbc0(0xc3);writeConfigFile(resolveWriteConfigPath(_0x1018f2),_0x32ca88);}export async function initGlobalEnvironment(_0x5ba5e4){const _0x38e37a=a107_0x2477f2,{initEnv:_0x2459ac}=await import(_0x38e37a(0x85));_0x2459ac(_0x5ba5e4[_0x38e37a(0xc5)]);const {initDomains:_0x5ac3b2}=await import(_0x38e37a(0x7f)),_0x488588=resolveEnterpriseRoutingConfig(_0x5ba5e4[_0x38e37a(0x9e)][_0x38e37a(0x9f)]);_0x5ac3b2({'apiDomain':_0x488588?_0x488588[_0x38e37a(0xb3)]:_0x5ba5e4['raw'][_0x38e37a(0xb3)]||_0x5ba5e4['raw'][_0x38e37a(0xbe)]||undefined,'userDomain':_0x488588?_0x488588['userDomain']:_0x5ba5e4[_0x38e37a(0x9e)][_0x38e37a(0x9a)]||undefined,'runtimeDomain':_0x488588?_0x488588[_0x38e37a(0x89)]:_0x5ba5e4[_0x38e37a(0x9e)][_0x38e37a(0x89)]||undefined,'skillDomain':_0x488588?_0x488588['skillDomain']:_0x5ba5e4['raw'][_0x38e37a(0xa5)]||_0x5ba5e4[_0x38e37a(0x9e)][_0x38e37a(0x97)]||_0x5ba5e4[_0x38e37a(0x9e)][_0x38e37a(0xc4)]||_0x5ba5e4[_0x38e37a(0x9e)][_0x38e37a(0xbd)]||undefined,'kbServiceDomain':_0x488588?_0x488588[_0x38e37a(0xab)]:typeof _0x5ba5e4[_0x38e37a(0x9e)]['kbServiceDomain']===_0x38e37a(0xae)&&_0x5ba5e4[_0x38e37a(0x9e)]['kbServiceDomain']['trim']()?_0x5ba5e4[_0x38e37a(0x9e)][_0x38e37a(0xab)]:undefined,'harnessDomain':_0x488588?_0x488588['harnessDomain']:_0x5ba5e4[_0x38e37a(0x9e)]['harnessDomain']===undefined?undefined:normalizeDomainOrigin('harnessDomain',_0x5ba5e4[_0x38e37a(0x9e)][_0x38e37a(0x9b)]),'region':normalizeLovrabetRegion(_0x5ba5e4[_0x38e37a(0x9e)]['region'])});}export function getProjectConfigPath(){const _0x4b46e1=a107_0x2477f2;return resolveConfigPath(process[_0x4b46e1(0xa8)]());}export function getGlobalConfigPath(){return resolveConfigPath(homedir());}export function inspectCliConfigJsonFile(_0x3691f9){const _0x5ddec7=a107_0x2477f2;if(!existsSync(_0x3691f9))return{'status':_0x5ddec7(0xa1)};try{const _0xc975ec=readFileSync(_0x3691f9,{'encoding':_0x5ddec7(0xa7)});if(!_0xc975ec?.[_0x5ddec7(0x91)]())return{'status':_0x5ddec7(0xbb)};const _0x21b123=JSON[_0x5ddec7(0xa6)](_0xc975ec);return{'status':'ok','data':_0x21b123};}catch(_0x2ef2f1){return{'status':_0x5ddec7(0x8f),'message':_0x2ef2f1 instanceof Error?_0x2ef2f1[_0x5ddec7(0x98)]:String(_0x2ef2f1)};}}export function loadRawConfigLayers(_0x197144){const _0x2197aa=a107_0x2477f2;let _0x271aa7={},_0x5f20cb={},_0x28b01b,_0x8cda97;try{_0x28b01b=resolveConfigPath(homedir());if(_0x28b01b){const _0x4823c3=readFileSync(_0x28b01b,{'encoding':_0x2197aa(0xa7)});if(_0x4823c3)_0x271aa7=JSON[_0x2197aa(0xa6)](_0x4823c3);}}catch{}try{const _0x5eec75=_0x197144||process[_0x2197aa(0xa8)]();_0x8cda97=resolveConfigPath(_0x5eec75);if(_0x8cda97){const _0x85ad1e=readFileSync(_0x8cda97,{'encoding':_0x2197aa(0xa7)});if(_0x85ad1e)_0x5f20cb=JSON['parse'](_0x85ad1e);}}catch{}return{'globalPath':_0x28b01b,'projectPath':_0x8cda97,'globalConfig':_0x271aa7,'projectConfig':_0x5f20cb};}function mergeRawConfigLayers(_0x3827bc){const _0x286f42=a107_0x2477f2,{globalConfig:_0xb936b1,projectConfig:_0x1e7a53}=_0x3827bc,_0x57656c={..._0xb936b1,..._0x1e7a53};delete _0x57656c['inherit'];if(_0x286f42(0xaa)in _0x1e7a53)_0x57656c[_0x286f42(0xaa)]=_0x1e7a53[_0x286f42(0xaa)];else _0xb936b1[_0x286f42(0xaa)]&&(_0x57656c[_0x286f42(0xaa)]=_0xb936b1[_0x286f42(0xaa)]);return _0x57656c;}export function isInProject(){return!!getProjectConfigPath();}export function readRawConfig(_0x21a2a5){return mergeRawConfigLayers(loadRawConfigLayers(_0x21a2a5));}export function readRawConfigWithLayers(_0x41c735){const _0xd93784=loadRawConfigLayers(_0x41c735);return{'config':mergeRawConfigLayers(_0xd93784),'layers':_0xd93784};}export function resolveDefaultAppSource(_0x569c4d){const _0x2eafb4=a107_0x2477f2;if('defaultApp'in _0x569c4d[_0x2eafb4(0xac)])return'project';if(_0x569c4d[_0x2eafb4(0xb1)]['defaultApp'])return _0x2eafb4(0xa0);return null;}function buildConfig(_0x57bf03,_0x44a57b){const _0x36242f=a107_0x2477f2,_0x40bab4=mergeRawConfigLayers(_0x57bf03),{projectConfig:_0x3cff0c}=_0x57bf03,_0x42f0cb=_0x40bab4[_0x36242f(0xaa)]||undefined,_0x2b2cfc=typeof _0x44a57b['appcode']===_0x36242f(0xae)?_0x44a57b['appcode']:undefined,_0x5116cd=_0x3cff0c['appcode']||_0x3cff0c[_0x36242f(0x84)],_0xce8da5=!_0x2b2cfc&&!_0x44a57b[_0x36242f(0x84)]&&!_0x5116cd&&!_0x3cff0c[_0x36242f(0xaa)],_0x2767ea=_0xce8da5?env('APPCODE'):undefined,_0x303e14=_0x44a57b[_0x36242f(0x84)]||(_0xce8da5&&!_0x2767ea?env('APP'):undefined),_0x3a8415=_0x303e14||_0x42f0cb||undefined,_0x41427e=_0x303e14||_0x2767ea?undefined:_0x5116cd||(_0x3cff0c['defaultApp']?undefined:_0x40bab4[_0x36242f(0xce)]||_0x40bab4[_0x36242f(0x84)]||undefined),_0x486ad9=_0x303e14||(_0x41427e?undefined:_0x42f0cb),_0x419450=resolveLocalAppAliasCode(_0x40bab4,_0x486ad9),_0x5eae5e=productEnvNames('ACCESS_KEY')[_0x36242f(0xc8)](_0x279560=>process.env[_0x279560]!==undefined),_0x522ee2=_0x5eae5e?process.env[_0x5eae5e]:undefined,_0x57eee4=_0x3cff0c['accessKey']||_0x522ee2||_0x40bab4[_0x36242f(0x99)]||undefined,_0x317471=_0x3cff0c['accessKey']?'project\x20config':_0x522ee2?_0x5eae5e:_0x40bab4['accessKey']?'global\x20config':undefined,_0x2a55f7=_0x44a57b[_0x36242f(0xc5)]||_0x40bab4['env']||env(_0x36242f(0xc2))||DEFAULT_CONFIG_VALUES[_0x36242f(0xc5)],_0x47eb90=normalizeEnv(String(_0x2a55f7)),_0x194653=isDaily(_0x47eb90)?'daily':isDev(_0x47eb90)?_0x36242f(0x80):_0x36242f(0xa4),_0x42aff4=_0x2b2cfc||_0x2767ea||_0x41427e||_0x419450?undefined:resolveCachedAppCode(_0x486ad9,_0x194653,_0x57eee4),_0x139df5=_0x2b2cfc||_0x2767ea||_0x41427e||_0x419450||_0x42aff4||undefined,_0x50190c=_0x2b2cfc?_0x36242f(0xa9):_0x2767ea?_0x36242f(0xc5):_0x41427e?'top-level':_0x419450?_0x36242f(0xb5):_0x42aff4?_0x36242f(0xc1):undefined,_0x57a54b=_0x40bab4['locale']||DEFAULT_CONFIG_VALUES[_0x36242f(0xa2)],_0x2a9377=undefined,_0x23fd05=_0x44a57b[_0x36242f(0xb0)]||env('FORMAT')||_0x40bab4[_0x36242f(0xb0)],_0x15d4cd=normalizeLegacyOutputFormat(_0x23fd05),_0x4bde6b=env(_0x36242f(0xba))||_0x40bab4[_0x36242f(0x92)],_0x5375ff=_0x4bde6b?Number(_0x4bde6b)||undefined:undefined,_0x20cbfe=_0x40bab4[_0x36242f(0x9d)],_0x33567c=_0x20cbfe==='read'||_0x20cbfe===_0x36242f(0x96)||_0x20cbfe===_0x36242f(0xc9)?_0x20cbfe:DEFAULT_CONFIG_VALUES['riskLevel'],_0x9a1dc7=_0x40bab4[_0x36242f(0xbc)]===!![],_0x3997bd=env('VERBOSE'),_0x3215a9=_0x3997bd==='1'||_0x3997bd===_0x36242f(0xb9);return{'appCode':typeof _0x139df5===_0x36242f(0xae)&&_0x139df5[_0x36242f(0x91)]()?_0x139df5[_0x36242f(0x91)]():undefined,'appCodeSource':_0x50190c,'env':_0x194653,'locale':_0x57a54b,'cookie':_0x2a9377,'accessKey':_0x57eee4,'accessKeySource':_0x317471,'format':_0x15d4cd,'pageSize':_0x5375ff,'riskLevel':_0x33567c,'nativeToolAvailable':_0x9a1dc7,'verbose':_0x3215a9,'defaultApp':_0x42f0cb,'currentApp':typeof _0x3a8415===_0x36242f(0xae)?_0x3a8415:undefined,'raw':_0x40bab4};}function env(_0x66492b){return productEnv(_0x66492b);}async function buildAuth(_0x319186){const _0x28c023=a107_0x2477f2,_0x4b3402='',_0x48b31c=!!_0x319186[_0x28c023(0x99)];return{'cookie':_0x4b3402,'isLoggedIn':_0x48b31c,async 'getOrLogin'(){if(_0x48b31c)return _0x4b3402;throw CliErrors['authRequired']();}};}
|
package/lib/core/api-client.d.ts
CHANGED
|
@@ -33,8 +33,9 @@ export type SqlListResult = DataList<SqlQuery>;
|
|
|
33
33
|
* handle both shapes.
|
|
34
34
|
*/
|
|
35
35
|
export declare function getSqlQueryInfo(appCode: string, sqlCode: string): Promise<SqlQuery>;
|
|
36
|
+
export type RuntimeArtifactType = "react_module" | "react_page";
|
|
36
37
|
export interface RuntimeArtifactUpsertInput {
|
|
37
|
-
artifactType:
|
|
38
|
+
artifactType: RuntimeArtifactType;
|
|
38
39
|
name?: string;
|
|
39
40
|
content: string;
|
|
40
41
|
metadata?: Record<string, unknown>;
|
|
@@ -330,7 +331,7 @@ export type NotificationChannelType = "EMAIL" | "FEISHU" | "DINGTALK" | "WECOM"
|
|
|
330
331
|
/** Lists app-level notification configs without using the development Cookie flow. */
|
|
331
332
|
export declare function listNotificationChannelConfigs(appCode: string, channelType: NotificationChannelType): Promise<NotificationChannelConfigItem[]>;
|
|
332
333
|
export declare function listRuntimeArtifacts(appCode: string, options?: {
|
|
333
|
-
artifactType?:
|
|
334
|
+
artifactType?: RuntimeArtifactType;
|
|
334
335
|
source?: string;
|
|
335
336
|
favorite?: boolean;
|
|
336
337
|
}): Promise<RuntimeArtifactItem[]>;
|