@lovrabet/rabetbase-cli 2.3.8-beta.1 → 2.3.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/api-doc.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/login-success-html.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/generate.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/add.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/remote-directory.js +1 -1
- package/lib/commands/app/remove.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/delete.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/app-config/list.js +1 -1
- package/lib/commands/app-config/set.js +1 -1
- package/lib/commands/app-config/shared.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/create.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-registry.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/dry-run.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/data/filter.js +1 -1
- package/lib/commands/data/getOne.js +1 -1
- package/lib/commands/data/index.js +1 -1
- package/lib/commands/data/shared.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/extend-update.js +1 -1
- package/lib/commands/dataset/field-update.js +1 -1
- package/lib/commands/dataset/generate.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.js +1 -1
- package/lib/commands/dataset/relation-audit.js +1 -1
- package/lib/commands/dataset/relation-create.js +1 -1
- package/lib/commands/dataset/relation-delete.js +1 -1
- package/lib/commands/dataset/relation-shared.js +1 -1
- package/lib/commands/dataset/relation-update.js +1 -1
- package/lib/commands/dataset/relations.js +1 -1
- package/lib/commands/dataset/rename.js +1 -1
- package/lib/commands/dataset/restore.js +1 -1
- package/lib/commands/db/analysis-batching.js +1 -1
- package/lib/commands/db/analyze-batch-plan.js +1 -1
- package/lib/commands/db/analyze-cancel.js +1 -1
- package/lib/commands/db/analyze-start.js +1 -1
- package/lib/commands/db/analyze-status.js +1 -1
- package/lib/commands/db/create.js +1 -1
- package/lib/commands/db/delete.js +1 -1
- package/lib/commands/db/detail.js +1 -1
- package/lib/commands/db/diff.js +1 -1
- package/lib/commands/db/index.js +1 -1
- package/lib/commands/db/list.js +1 -1
- package/lib/commands/db/shared.js +1 -1
- package/lib/commands/db/tables.js +1 -1
- package/lib/commands/db/test.js +1 -1
- package/lib/commands/db/update.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/init/index.js +1 -1
- package/lib/commands/issue/index.js +1 -1
- package/lib/commands/issue/nudge.js +1 -1
- package/lib/commands/issue/report.js +1 -1
- package/lib/commands/issue/shared.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/update.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/page/generate-start.js +1 -1
- package/lib/commands/page/generate-status.js +1 -1
- package/lib/commands/page/index.js +1 -1
- package/lib/commands/page/pull.js +1 -1
- package/lib/commands/page/push.js +1 -1
- package/lib/commands/page/relation-audit.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/standard-page-status.js +1 -1
- package/lib/commands/page/sync.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-apis-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/project/create/enhanced-guided-create.js +1 -1
- package/lib/commands/project/create/format-elapsed.js +1 -1
- package/lib/commands/project/create/main.js +1 -1
- package/lib/commands/project/create/non-interactive.js +1 -1
- package/lib/commands/project/create/project-template-path.js +1 -1
- package/lib/commands/project/create/use-copy-project-template.js +1 -1
- package/lib/commands/project/create/use-format-code.js +1 -1
- package/lib/commands/project/create/use-install-dependencies.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/init.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/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/role/user-resolve.js +1 -1
- package/lib/commands/run/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/sql/create.js +1 -1
- package/lib/commands/sql/delete.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/sql/list.js +1 -1
- package/lib/commands/sql/pull.js +1 -1
- package/lib/commands/sql/push.js +1 -1
- package/lib/commands/sql/save.js +1 -1
- package/lib/commands/sql/shared.js +1 -1
- package/lib/commands/sql/status.js +1 -1
- package/lib/commands/sql/validate.js +1 -1
- package/lib/commands/workspace/add.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/commands/workspace/remove.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/cdn.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.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/paths.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/context/app-resolver.js +1 -1
- package/lib/context/auth-resolver.js +1 -1
- package/lib/context/config-loader.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/page/file-system.js +1 -1
- package/lib/core/page/hash.js +1 -1
- package/lib/core/page/lock.js +1 -1
- package/lib/core/sql-sync/config.js +1 -1
- package/lib/core/sql-sync/file-system.js +1 -1
- package/lib/core/sql-sync/hash.js +1 -1
- package/lib/core/sql-sync/lock.js +1 -1
- package/lib/core/sql-sync/utils.js +1 -1
- package/lib/core/sql-validator.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/flags.js +1 -1
- package/lib/framework/help.js +1 -1
- package/lib/framework/index.js +1 -1
- package/lib/framework/output.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-alias.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.js +1 -1
- package/lib/help.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/telemetry/cli-command-trace.js +1 -1
- package/lib/telemetry/cli-help-trace.js +1 -1
- package/lib/telemetry/ensure-cli-otel-config.js +1 -1
- package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
- package/lib/telemetry/send-cli-trace-log.js +1 -1
- package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/copy-directory.js +1 -1
- package/lib/utils/entity-with-id.js +1 -1
- package/lib/utils/file-utils.js +1 -1
- package/lib/utils/guides-cdn.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/is-non-interactive.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/rules-cdn.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
package/lib/constant/cli.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const a173_0x57a8c4=a173_0x1edf;(function(_0xa83709,_0xa95872){const _0x34499f=a173_0x1edf,_0x27c4c3=_0xa83709();while(!![]){try{const _0x50cdb4=parseInt(_0x34499f(0x184))/0x1*(-parseInt(_0x34499f(0x170))/0x2)+parseInt(_0x34499f(0x178))/0x3*(-parseInt(_0x34499f(0x14f))/0x4)+parseInt(_0x34499f(0x14a))/0x5+parseInt(_0x34499f(0x198))/0x6*(parseInt(_0x34499f(0x182))/0x7)+parseInt(_0x34499f(0x14e))/0x8*(parseInt(_0x34499f(0x18a))/0x9)+parseInt(_0x34499f(0x189))/0xa*(-parseInt(_0x34499f(0x13b))/0xb)+-parseInt(_0x34499f(0x131))/0xc;if(_0x50cdb4===_0xa95872)break;else _0x27c4c3['push'](_0x27c4c3['shift']());}catch(_0x505b59){_0x27c4c3['push'](_0x27c4c3['shift']());}}}(a173_0x30b4,0x313da));export const CLI_BIN_NAME=a173_0x57a8c4(0x186);export const CLI_DISPLAY_NAME='Rabetbase\x20CLI';export const NPM_PACKAGE_NAME=a173_0x57a8c4(0x145);function a173_0x1edf(_0x114878,_0xdffb92){_0x114878=_0x114878-0x130;const _0x30b4af=a173_0x30b4();let _0x1edf15=_0x30b4af[_0x114878];return _0x1edf15;}function a173_0x30b4(){const _0x5de635=['operationType','non-interactive','Force\x20non-interactive\x20mode\x20(CI)','Config\x20key','217OgzhJz','Filter\x20JSON\x20output\x20(JQ_PATH\x20>\x20bundled\x20jq\x20>\x20PATH;\x20use\x20with\x20--format\x20json\x20or\x20compress)','84041kCDUDq','Alias\x20for\x20--non-interactive','rabetbase','operation-type','Schemas','2150HBSEBe','9WFWruq','<name>','target','type','sqlname','sql','yes','all','expectedCount','sqlcode','project','Confirm\x20destructive\x20action','Output\x20path','Watch\x20mode','66174toThVr','Use\x20project\x20config\x20scope','json\x20|\x20pretty\x20|\x20compress','output','Name','operation','env','233508hBZHdH','Apply\x20to\x20all','Target\x20path','dryRun','key','dry-run','SQL\x20name','from-env','Record\x20ID','expected-count','8283RiKEGp','Use\x20remote','watch','boolean','dbid','skipImports','code','name','Description','Reveal\x20sensitive\x20value','@lovrabet/rabetbase-cli','pagesize','enableBffSave','skip-imports','Environment','1604525KAkyUr','nonInteractive','Page\x20number','Keyword\x20filter','106408UTCeEx','499916bLSWPw','meowKey','DB\x20ID','clear','app','Dataset\x20code','title','reveal','help','Preview\x20operation\x20without\x20executing','Operation\x20type','enable-bff-save','verbose','functionNode','Show\x20help','Clear','File\x20path','datasetcode','map','file','Skip\x20import\x20generation','params','SQL\x20string','descriptionFile','string','Override\x20appcode','schemas','keyword','<expr>','global','description-file','page','db-id','4NXcOKl','function-node','dbId','appcode','Select\x20app\x20profile\x20by\x20name','description','confirm','stdin','3dygFjP','Page\x20size','Tags','format','Use\x20global\x20config\x20scope','remote'];a173_0x30b4=function(){return _0x5de635;};return a173_0x30b4();}export const GLOBAL_FLAGS=[{'name':'appcode','meowKey':a173_0x57a8c4(0x173),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x168),'hint':'<code>'},{'name':'app','meowKey':'app','type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x174),'hint':a173_0x57a8c4(0x18b)},{'name':a173_0x57a8c4(0x130),'meowKey':'env','type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x149),'hint':'production\x20|\x20daily'},{'name':a173_0x57a8c4(0x17b),'meowKey':a173_0x57a8c4(0x17b),'type':a173_0x57a8c4(0x167),'description':'Output\x20format','hint':a173_0x57a8c4(0x19a)},{'name':'jq','meowKey':'jq','type':'string','description':a173_0x57a8c4(0x183),'hint':a173_0x57a8c4(0x16b)},{'name':a173_0x57a8c4(0x136),'meowKey':a173_0x57a8c4(0x134),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x158)},{'name':'yes','meowKey':a173_0x57a8c4(0x190),'type':'boolean','description':'Skip\x20confirmation\x20for\x20high-risk\x20writes'},{'name':a173_0x57a8c4(0x17f),'meowKey':a173_0x57a8c4(0x14b),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x180)},{'name':a173_0x57a8c4(0x16c),'meowKey':a173_0x57a8c4(0x16c),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x17c)},{'name':a173_0x57a8c4(0x194),'meowKey':a173_0x57a8c4(0x194),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x199)},{'name':'ci','meowKey':'ci','type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x185),'hidden':!![]},{'name':a173_0x57a8c4(0x157),'meowKey':a173_0x57a8c4(0x157),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x15d)},{'name':a173_0x57a8c4(0x142),'meowKey':'name','type':'string','description':a173_0x57a8c4(0x19c),'hidden':!![]},{'name':a173_0x57a8c4(0x155),'meowKey':a173_0x57a8c4(0x155),'type':a173_0x57a8c4(0x167),'description':'Title','hidden':!![]},{'name':a173_0x57a8c4(0x152),'meowKey':'clear','type':'boolean','description':a173_0x57a8c4(0x15e),'hidden':!![]},{'name':a173_0x57a8c4(0x13d),'meowKey':a173_0x57a8c4(0x13d),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x197),'hidden':!![]},{'name':a173_0x57a8c4(0x19b),'meowKey':a173_0x57a8c4(0x19b),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x196),'hidden':!![]},{'name':'params','meowKey':a173_0x57a8c4(0x164),'type':'string','description':'JSON\x20params','hidden':!![]},{'name':a173_0x57a8c4(0x160),'meowKey':a173_0x57a8c4(0x160),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x154),'hidden':!![]},{'name':a173_0x57a8c4(0x191),'meowKey':a173_0x57a8c4(0x191),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x132),'hidden':!![]},{'name':a173_0x57a8c4(0x15a),'meowKey':a173_0x57a8c4(0x147),'type':a173_0x57a8c4(0x13e),'description':'Enable\x20BFF\x20save','hidden':!![]},{'name':'id','meowKey':'id','type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x139),'hidden':!![]},{'name':a173_0x57a8c4(0x18d),'meowKey':a173_0x57a8c4(0x18d),'type':a173_0x57a8c4(0x167),'description':'Type\x20filter','hidden':!![]},{'name':a173_0x57a8c4(0x162),'meowKey':a173_0x57a8c4(0x162),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x15f),'hidden':!![]},{'name':a173_0x57a8c4(0x193),'meowKey':a173_0x57a8c4(0x193),'type':'string','description':'SQL\x20code','hidden':!![]},{'name':'sql-name','meowKey':'sqlName','type':a173_0x57a8c4(0x167),'description':'SQL\x20name','hidden':!![]},{'name':a173_0x57a8c4(0x18e),'meowKey':a173_0x57a8c4(0x18e),'type':'string','description':a173_0x57a8c4(0x137),'hidden':!![]},{'name':a173_0x57a8c4(0x16f),'meowKey':a173_0x57a8c4(0x172),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x151),'hidden':!![]},{'name':a173_0x57a8c4(0x13f),'meowKey':a173_0x57a8c4(0x13f),'type':'string','description':a173_0x57a8c4(0x151),'hidden':!![]},{'name':a173_0x57a8c4(0x175),'meowKey':a173_0x57a8c4(0x175),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x143),'hidden':!![]},{'name':a173_0x57a8c4(0x16d),'meowKey':a173_0x57a8c4(0x166),'type':a173_0x57a8c4(0x167),'description':'Description\x20file','hidden':!![]},{'name':a173_0x57a8c4(0x16e),'meowKey':a173_0x57a8c4(0x16e),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x14c),'hidden':!![]},{'name':a173_0x57a8c4(0x146),'meowKey':a173_0x57a8c4(0x146),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x179),'hidden':!![]},{'name':a173_0x57a8c4(0x16a),'meowKey':a173_0x57a8c4(0x16a),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x14d),'hidden':!![]},{'name':a173_0x57a8c4(0x141),'meowKey':'code','type':a173_0x57a8c4(0x167),'description':'Code\x20filter','hidden':!![]},{'name':a173_0x57a8c4(0x18f),'meowKey':a173_0x57a8c4(0x18f),'type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x165),'hidden':!![]},{'name':a173_0x57a8c4(0x169),'meowKey':'schemas','type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x188),'hidden':!![]},{'name':'operation','meowKey':a173_0x57a8c4(0x19d),'type':'string','description':'Operation\x20type','hidden':!![]},{'name':a173_0x57a8c4(0x18c),'meowKey':a173_0x57a8c4(0x18c),'type':'string','description':a173_0x57a8c4(0x133),'hidden':!![]},{'name':a173_0x57a8c4(0x148),'meowKey':a173_0x57a8c4(0x140),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x163),'hidden':!![]},{'name':a173_0x57a8c4(0x135),'meowKey':'key','type':'string','description':a173_0x57a8c4(0x181),'hidden':!![]},{'name':'value','meowKey':'value','type':a173_0x57a8c4(0x167),'description':'Config\x20value','hidden':!![]},{'name':'tags','meowKey':'tags','type':a173_0x57a8c4(0x167),'description':a173_0x57a8c4(0x17a),'hidden':!![]},{'name':'stdin','meowKey':a173_0x57a8c4(0x177),'type':a173_0x57a8c4(0x13e),'description':'Read\x20value\x20from\x20stdin','hidden':!![]},{'name':a173_0x57a8c4(0x138),'meowKey':'fromEnv','type':a173_0x57a8c4(0x167),'description':'Read\x20value\x20from\x20environment\x20variable','hidden':!![]},{'name':a173_0x57a8c4(0x156),'meowKey':a173_0x57a8c4(0x156),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x144),'hidden':!![]},{'name':'force','meowKey':'force','type':a173_0x57a8c4(0x13e),'description':'Force\x20overwrite','hidden':!![]},{'name':a173_0x57a8c4(0x176),'meowKey':a173_0x57a8c4(0x176),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x195),'hidden':!![]},{'name':a173_0x57a8c4(0x17d),'meowKey':a173_0x57a8c4(0x17d),'type':a173_0x57a8c4(0x13e),'description':a173_0x57a8c4(0x13c),'hidden':!![]},{'name':a173_0x57a8c4(0x15b),'meowKey':a173_0x57a8c4(0x15b),'type':a173_0x57a8c4(0x13e),'description':'Verbose\x20output','hidden':!![]},{'name':a173_0x57a8c4(0x13a),'meowKey':a173_0x57a8c4(0x192),'type':'string','description':'Expected\x20affected\x20count','hidden':!![]},{'name':a173_0x57a8c4(0x187),'meowKey':a173_0x57a8c4(0x17e),'type':'string','description':a173_0x57a8c4(0x159),'hidden':!![]},{'name':a173_0x57a8c4(0x171),'meowKey':a173_0x57a8c4(0x15c),'type':a173_0x57a8c4(0x167),'description':'Function\x20node','hidden':!![]}];export const PIPELINE_FLAG_NAMES=new Set([a173_0x57a8c4(0x173),a173_0x57a8c4(0x153),'env',a173_0x57a8c4(0x17b),'jq',a173_0x57a8c4(0x136),a173_0x57a8c4(0x190),a173_0x57a8c4(0x17f),'ci']);export function buildMeowFlags(){const _0x3df22c=a173_0x57a8c4;return Object['fromEntries'](GLOBAL_FLAGS[_0x3df22c(0x161)](_0x22c2f2=>[_0x22c2f2[_0x3df22c(0x150)],{'type':_0x22c2f2[_0x3df22c(0x18d)]}]));}
|
|
1
|
+
const a173_0x438463=a173_0x3699;(function(_0x23f7a4,_0x328015){const _0x350718=a173_0x3699,_0x83bc1e=_0x23f7a4();while(!![]){try{const _0x56a989=parseInt(_0x350718(0x110))/0x1+parseInt(_0x350718(0x123))/0x2+-parseInt(_0x350718(0x101))/0x3+-parseInt(_0x350718(0xff))/0x4*(-parseInt(_0x350718(0x128))/0x5)+-parseInt(_0x350718(0x13d))/0x6+-parseInt(_0x350718(0x111))/0x7+parseInt(_0x350718(0x14b))/0x8;if(_0x56a989===_0x328015)break;else _0x83bc1e['push'](_0x83bc1e['shift']());}catch(_0x28a555){_0x83bc1e['push'](_0x83bc1e['shift']());}}}(a173_0x50fa,0xea8e7));export const CLI_BIN_NAME=a173_0x438463(0x12c);export const CLI_DISPLAY_NAME=a173_0x438463(0xeb);export const NPM_PACKAGE_NAME=a173_0x438463(0x129);function a173_0x3699(_0x53eed9,_0xb92587){_0x53eed9=_0x53eed9-0xe5;const _0x50fa13=a173_0x50fa();let _0x369965=_0x50fa13[_0x53eed9];return _0x369965;}export const GLOBAL_FLAGS=[{'name':a173_0x438463(0x125),'meowKey':a173_0x438463(0x125),'type':a173_0x438463(0x105),'description':a173_0x438463(0x10a),'hint':a173_0x438463(0x11f)},{'name':a173_0x438463(0x14d),'meowKey':a173_0x438463(0x14d),'type':a173_0x438463(0x105),'description':a173_0x438463(0x140),'hint':'<name>'},{'name':a173_0x438463(0x11a),'meowKey':a173_0x438463(0x11a),'type':a173_0x438463(0x105),'description':a173_0x438463(0x118),'hint':a173_0x438463(0x11e)},{'name':a173_0x438463(0xee),'meowKey':'format','type':a173_0x438463(0x105),'description':a173_0x438463(0x12f),'hint':a173_0x438463(0x12d)},{'name':'jq','meowKey':'jq','type':a173_0x438463(0x105),'description':'Filter\x20JSON\x20output\x20(JQ_PATH\x20>\x20bundled\x20jq\x20>\x20PATH;\x20use\x20with\x20--format\x20json\x20or\x20compress)','hint':a173_0x438463(0x131)},{'name':a173_0x438463(0xe5),'meowKey':a173_0x438463(0xf3),'type':a173_0x438463(0x102),'description':a173_0x438463(0x115)},{'name':a173_0x438463(0x142),'meowKey':'yes','type':'boolean','description':a173_0x438463(0x117)},{'name':'non-interactive','meowKey':a173_0x438463(0x11b),'type':'boolean','description':'Force\x20non-interactive\x20mode\x20(CI)'},{'name':'global','meowKey':a173_0x438463(0x133),'type':a173_0x438463(0x102),'description':'Use\x20global\x20config\x20scope'},{'name':'project','meowKey':'project','type':a173_0x438463(0x102),'description':a173_0x438463(0xfa)},{'name':'ci','meowKey':'ci','type':'boolean','description':a173_0x438463(0x13e),'hidden':!![]},{'name':a173_0x438463(0x109),'meowKey':a173_0x438463(0x109),'type':'boolean','description':a173_0x438463(0x148)},{'name':a173_0x438463(0xfb),'meowKey':'name','type':a173_0x438463(0x105),'description':'Name','hidden':!![]},{'name':a173_0x438463(0xec),'meowKey':a173_0x438463(0xec),'type':a173_0x438463(0x105),'description':'Title','hidden':!![]},{'name':a173_0x438463(0x10d),'meowKey':a173_0x438463(0x10d),'type':'boolean','description':a173_0x438463(0x127),'hidden':!![]},{'name':a173_0x438463(0xe9),'meowKey':a173_0x438463(0xe9),'type':a173_0x438463(0x102),'description':a173_0x438463(0x12e),'hidden':!![]},{'name':a173_0x438463(0x13a),'meowKey':a173_0x438463(0x13a),'type':a173_0x438463(0x105),'description':a173_0x438463(0x141),'hidden':!![]},{'name':a173_0x438463(0x10c),'meowKey':a173_0x438463(0x10c),'type':'string','description':a173_0x438463(0x10e),'hidden':!![]},{'name':a173_0x438463(0x12b),'meowKey':a173_0x438463(0x12b),'type':'string','description':'Dataset\x20code','hidden':!![]},{'name':a173_0x438463(0x14a),'meowKey':a173_0x438463(0x14a),'type':a173_0x438463(0x102),'description':a173_0x438463(0x10f),'hidden':!![]},{'name':'enable-bff-save','meowKey':a173_0x438463(0x130),'type':a173_0x438463(0x102),'description':'Enable\x20BFF\x20save','hidden':!![]},{'name':'id','meowKey':'id','type':a173_0x438463(0x105),'description':'Record\x20ID','hidden':!![]},{'name':a173_0x438463(0x138),'meowKey':a173_0x438463(0x138),'type':a173_0x438463(0x105),'description':'Type\x20filter','hidden':!![]},{'name':'file','meowKey':a173_0x438463(0x145),'type':a173_0x438463(0x105),'description':a173_0x438463(0xe8),'hidden':!![]},{'name':a173_0x438463(0x107),'meowKey':a173_0x438463(0x107),'type':'string','description':'SQL\x20code','hidden':!![]},{'name':a173_0x438463(0xfe),'meowKey':a173_0x438463(0x126),'type':a173_0x438463(0x105),'description':a173_0x438463(0x119),'hidden':!![]},{'name':a173_0x438463(0x134),'meowKey':a173_0x438463(0x134),'type':a173_0x438463(0x105),'description':'SQL\x20name','hidden':!![]},{'name':'db-id','meowKey':'dbId','type':a173_0x438463(0x105),'description':a173_0x438463(0x10b),'hidden':!![]},{'name':a173_0x438463(0x135),'meowKey':'dbid','type':a173_0x438463(0x105),'description':a173_0x438463(0x10b),'hidden':!![]},{'name':a173_0x438463(0x132),'meowKey':a173_0x438463(0x132),'type':'string','description':'Description','hidden':!![]},{'name':a173_0x438463(0xf7),'meowKey':a173_0x438463(0x150),'type':'string','description':a173_0x438463(0x14e),'hidden':!![]},{'name':a173_0x438463(0x106),'meowKey':'page','type':'string','description':a173_0x438463(0x136),'hidden':!![]},{'name':a173_0x438463(0x13c),'meowKey':a173_0x438463(0x13c),'type':'string','description':a173_0x438463(0xf8),'hidden':!![]},{'name':a173_0x438463(0x114),'meowKey':a173_0x438463(0x114),'type':'string','description':a173_0x438463(0xf1),'hidden':!![]},{'name':a173_0x438463(0x144),'meowKey':a173_0x438463(0x144),'type':a173_0x438463(0x105),'description':a173_0x438463(0xe7),'hidden':!![]},{'name':'sql','meowKey':a173_0x438463(0x149),'type':a173_0x438463(0x105),'description':a173_0x438463(0x12a),'hidden':!![]},{'name':a173_0x438463(0x124),'meowKey':a173_0x438463(0x124),'type':a173_0x438463(0x105),'description':a173_0x438463(0x113),'hidden':!![]},{'name':a173_0x438463(0xf0),'meowKey':a173_0x438463(0xf0),'type':'string','description':a173_0x438463(0x13b),'hidden':!![]},{'name':'target','meowKey':a173_0x438463(0x104),'type':'string','description':'Target\x20path','hidden':!![]},{'name':'skip-imports','meowKey':'skipImports','type':a173_0x438463(0x102),'description':a173_0x438463(0xf4),'hidden':!![]},{'name':'key','meowKey':a173_0x438463(0x108),'type':a173_0x438463(0x105),'description':a173_0x438463(0x112),'hidden':!![]},{'name':a173_0x438463(0xf5),'meowKey':'value','type':a173_0x438463(0x105),'description':'Config\x20value','hidden':!![]},{'name':'tags','meowKey':a173_0x438463(0xf9),'type':'string','description':'Tags','hidden':!![]},{'name':'stdin','meowKey':a173_0x438463(0x13f),'type':a173_0x438463(0x102),'description':a173_0x438463(0xea),'hidden':!![]},{'name':a173_0x438463(0x103),'meowKey':a173_0x438463(0x100),'type':'string','description':a173_0x438463(0x121),'hidden':!![]},{'name':a173_0x438463(0x137),'meowKey':'reveal','type':'boolean','description':a173_0x438463(0x11c),'hidden':!![]},{'name':a173_0x438463(0xe6),'meowKey':a173_0x438463(0xe6),'type':a173_0x438463(0x102),'description':a173_0x438463(0x11d),'hidden':!![]},{'name':a173_0x438463(0x14f),'meowKey':'confirm','type':'boolean','description':a173_0x438463(0xef),'hidden':!![]},{'name':a173_0x438463(0xfc),'meowKey':a173_0x438463(0xfc),'type':a173_0x438463(0x102),'description':a173_0x438463(0x143),'hidden':!![]},{'name':a173_0x438463(0xed),'meowKey':a173_0x438463(0xed),'type':a173_0x438463(0x102),'description':a173_0x438463(0xfd),'hidden':!![]},{'name':a173_0x438463(0x139),'meowKey':a173_0x438463(0x116),'type':a173_0x438463(0x105),'description':a173_0x438463(0x146),'hidden':!![]},{'name':a173_0x438463(0xf6),'meowKey':a173_0x438463(0x120),'type':a173_0x438463(0x105),'description':a173_0x438463(0x13b),'hidden':!![]},{'name':'function-node','meowKey':'functionNode','type':a173_0x438463(0x105),'description':a173_0x438463(0x14c),'hidden':!![]}];export const PIPELINE_FLAG_NAMES=new Set([a173_0x438463(0x125),'app','env','format','jq',a173_0x438463(0xe5),'yes','non-interactive','ci']);export function buildMeowFlags(){const _0x56c5a5=a173_0x438463;return Object[_0x56c5a5(0xf2)](GLOBAL_FLAGS[_0x56c5a5(0x147)](_0x1d661e=>[_0x1d661e[_0x56c5a5(0x122)],{'type':_0x1d661e[_0x56c5a5(0x138)]}]));}function a173_0x50fa(){const _0x332461=['json\x20|\x20pretty\x20|\x20compress','Watch\x20mode','Output\x20format','enableBffSave','<expr>','description','global','sqlname','dbid','Page\x20number','reveal','type','expected-count','output','Operation\x20type','pagesize','5525148CVXQyp','Alias\x20for\x20--non-interactive','stdin','Select\x20app\x20profile\x20by\x20name','Output\x20path','yes','Use\x20remote','code','file','Expected\x20affected\x20count','map','Show\x20help','sql','all','23861504quIhCL','Function\x20node','app','Description\x20file','confirm','descriptionFile','dry-run','force','Code\x20filter','File\x20path','watch','Read\x20value\x20from\x20stdin','Rabetbase\x20CLI','title','verbose','format','Confirm\x20destructive\x20action','operation','Keyword\x20filter','fromEntries','dryRun','Skip\x20import\x20generation','value','operation-type','description-file','Page\x20size','tags','Use\x20project\x20config\x20scope','name','remote','Verbose\x20output','sql-name','4184296olLeJT','fromEnv','4402743spQjRR','boolean','from-env','target','string','page','sqlcode','key','help','Override\x20appcode','DB\x20ID','params','clear','JSON\x20params','Apply\x20to\x20all','224213dloqUL','11218151jKximH','Config\x20key','Schemas','keyword','Preview\x20operation\x20without\x20executing','expectedCount','Skip\x20confirmation\x20for\x20high-risk\x20writes','Environment','SQL\x20name','env','nonInteractive','Reveal\x20sensitive\x20value','Force\x20overwrite','production\x20|\x20daily','<code>','operationType','Read\x20value\x20from\x20environment\x20variable','meowKey','1397600WisYgh','schemas','appcode','sqlName','Clear','5bntsiC','@lovrabet/rabetbase-cli','SQL\x20string','datasetcode','rabetbase'];a173_0x50fa=function(){return _0x332461;};return a173_0x50fa();}
|
package/lib/constant/defaults.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a174_0x181c05=a174_0x22ed;(function(_0x5a2525,_0x2fa61d){const _0x2da703=a174_0x22ed,_0x4fb16e=_0x5a2525();while(!![]){try{const _0x3b94ca=parseInt(_0x2da703(0x195))/0x1*(-parseInt(_0x2da703(0x194))/0x2)+parseInt(_0x2da703(0x196))/0x3*(-parseInt(_0x2da703(0x19a))/0x4)+-parseInt(_0x2da703(0x192))/0x5*(-parseInt(_0x2da703(0x193))/0x6)+-parseInt(_0x2da703(0x18f))/0x7+parseInt(_0x2da703(0x18e))/0x8+-parseInt(_0x2da703(0x197))/0x9+parseInt(_0x2da703(0x198))/0xa;if(_0x3b94ca===_0x2fa61d)break;else _0x4fb16e['push'](_0x4fb16e['shift']());}catch(_0x233093){_0x4fb16e['push'](_0x4fb16e['shift']());}}}(a174_0x1d74,0x412cb));function a174_0x1d74(){const _0x56fc10=['356lUShyC','186yEgcCW','3pRXTgf','3678219EQSQRR','7231280XgmOrc','compress','1190100bqzCNC','3397928cEOqnf','2727228tRpAEe','production','en-US','620035nfvLsk','12sDbhnA'];a174_0x1d74=function(){return _0x56fc10;};return a174_0x1d74();}import{DEFAULT_API_DIR}from'../constant/paths.js';function a174_0x22ed(_0x14b17a,_0x3b5d00){_0x14b17a=_0x14b17a-0x18e;const _0x1d748a=a174_0x1d74();let _0x22ed43=_0x1d748a[_0x14b17a];return _0x22ed43;}export const DEFAULT_CONFIG_VALUES={'env':a174_0x181c05(0x190),'format':'compress','locale':a174_0x181c05(0x191),'riskLevel':'high-risk-write','apiDir':DEFAULT_API_DIR};export const DEFAULT_COMMAND_OUTPUT_FORMAT=a174_0x181c05(0x199);
|
package/lib/constant/domain.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a175_0x3f78(){const _0x4cd7a4=['apiDomain','https://daily-api.lovrabet.com','/web-app/app/','77845yzgkvd','777mpnMLf','userDomain','15064hvgSid','168dWRWwi','372492jEoaCb','92wnMLaZ','949810CRSKmI','55euoxdS','323253JpUVuG','7202TEvxjR','runtimeDomain','https://api.lovrabet.com','https://app.lovrabet.com','https://runtime.lovrabet.com','1478358HsGsWn'];a175_0x3f78=function(){return _0x4cd7a4;};return a175_0x3f78();}const a175_0x14ec6f=a175_0x2e31;(function(_0x5f486f,_0x29dc4d){const _0x51e080=a175_0x2e31,_0x883282=_0x5f486f();while(!![]){try{const _0x30f8df=parseInt(_0x51e080(0x17a))/0x1*(parseInt(_0x51e080(0x176))/0x2)+-parseInt(_0x51e080(0x179))/0x3+parseInt(_0x51e080(0x175))/0x4+parseInt(_0x51e080(0x183))/0x5*(-parseInt(_0x51e080(0x187))/0x6)+parseInt(_0x51e080(0x184))/0x7*(parseInt(_0x51e080(0x186))/0x8)+-parseInt(_0x51e080(0x17f))/0x9+parseInt(_0x51e080(0x177))/0xa*(parseInt(_0x51e080(0x178))/0xb);if(_0x30f8df===_0x29dc4d)break;else _0x883282['push'](_0x883282['shift']());}catch(_0x394eac){_0x883282['push'](_0x883282['shift']());}}}(a175_0x3f78,0x61c04));import{getEnv,isProduction}from'../constant/env.js';let customApiDomain,customUserDomain,customRuntimeDomain;export function initDomains(_0x42340f){const _0x131779=a175_0x2e31;customApiDomain=_0x42340f?.[_0x131779(0x180)],customUserDomain=_0x42340f?.[_0x131779(0x185)],customRuntimeDomain=_0x42340f?.[_0x131779(0x17b)];}function a175_0x2e31(_0x5e4c08,_0x5d80ec){_0x5e4c08=_0x5e4c08-0x175;const _0x3f784c=a175_0x3f78();let _0x2e316f=_0x3f784c[_0x5e4c08];return _0x2e316f;}export const getUserDomain=()=>customUserDomain||(isProduction(getEnv())?'https://user.lovrabet.com':'https://user-daily.lovrabet.com');export const getApiDomain=()=>customApiDomain||(isProduction(getEnv())?a175_0x14ec6f(0x17c):a175_0x14ec6f(0x181));export const getRuntimeDomain=()=>customRuntimeDomain||(isProduction(getEnv())?a175_0x14ec6f(0x17e):'https://daily-runtime.lovrabet.com');export const getAppDomain=()=>isProduction(getEnv())?a175_0x14ec6f(0x17d):'https://daily.lovrabet.com';export const getAppBaseUrl=_0x3ed383=>{const _0x7e7a66=a175_0x14ec6f,_0x4711a0=encodeURIComponent(_0x3ed383['trim']());return isProduction(getEnv())?getAppDomain()+'/app/'+_0x4711a0:getAppDomain()+_0x7e7a66(0x182)+_0x4711a0;};
|
package/lib/constant/env.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a176_0x20e9fc=a176_0x555b;(function(_0x35ad77,_0x36fdc3){const _0xd93465=a176_0x555b,_0x52be3c=_0x35ad77();while(!![]){try{const _0x5f05d8=parseInt(_0xd93465(0x198))/0x1+parseInt(_0xd93465(0x1a0))/0x2+-parseInt(_0xd93465(0x196))/0x3*(-parseInt(_0xd93465(0x193))/0x4)+-parseInt(_0xd93465(0x195))/0x5+-parseInt(_0xd93465(0x194))/0x6*(parseInt(_0xd93465(0x19e))/0x7)+parseInt(_0xd93465(0x19d))/0x8+-parseInt(_0xd93465(0x199))/0x9;if(_0x5f05d8===_0x36fdc3)break;else _0x52be3c['push'](_0x52be3c['shift']());}catch(_0x28f5ab){_0x52be3c['push'](_0x52be3c['shift']());}}}(a176_0x24c1,0xa5f6d));export const RABETBASE_ENV_VALUES=['production',a176_0x20e9fc(0x19c)];export function normalizeEnv(_0x163394){const _0x5608f6=a176_0x20e9fc;return _0x163394===_0x5608f6(0x19a)?_0x5608f6(0x19f):_0x163394;}export function isProduction(_0x147ebc){const _0x2ccde7=a176_0x20e9fc;return normalizeEnv(_0x147ebc)===_0x2ccde7(0x19f);}export function isDaily(_0x384815){const _0x56c65d=a176_0x20e9fc;return normalizeEnv(_0x384815)===_0x56c65d(0x19c);}export function isDev(_0x30234c){const _0x4297de=a176_0x20e9fc,_0x2d98d6=normalizeEnv(_0x30234c);return _0x2d98d6===_0x4297de(0x197)||_0x2d98d6===_0x4297de(0x19b);}function a176_0x555b(_0x406fd1,_0x26b0eb){_0x406fd1=_0x406fd1-0x193;const _0x24c1b3=a176_0x24c1();let _0x555be5=_0x24c1b3[_0x406fd1];return _0x555be5;}let env=normalizeEnv(process.env.RABETBASE_ENV||process.env.LOVRABET_ENV||a176_0x20e9fc(0x19f));function a176_0x24c1(){const _0x1f06b3=['daily','4880248IEoZAn','5873zwtquM','production','1451430QEwfga','217368MIXtyx','9246KWbGwj','4441460gFHGTi','63ZooIXQ','development','1163024PAWBsG','7010748RHLLZc','online','dev'];a176_0x24c1=function(){return _0x1f06b3;};return a176_0x24c1();}export function getEnv(){return env;}export function initEnv(_0x3b9574){env=normalizeEnv(_0x3b9574);}
|
package/lib/constant/output.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a177_0x591a(){const _0x483e78=['455250QUxwcP','1jYXrcK','compress','4451825meZHRJ','2229521zVZWyg','pretty','60QZPSRh','3844431cQIJEq','150639chxYGO','988212VXUkei','8BjzPIo','6395910ArlRXF','json'];a177_0x591a=function(){return _0x483e78;};return a177_0x591a();}function a177_0x1889(_0x208abd,_0x666f0f){_0x208abd=_0x208abd-0x130;const _0x591ae7=a177_0x591a();let _0x1889c4=_0x591ae7[_0x208abd];return _0x1889c4;}const a177_0x57d210=a177_0x1889;(function(_0x189388,_0x1924d3){const _0x583a67=a177_0x1889,_0x1a389e=_0x189388();while(!![]){try{const _0x584dce=parseInt(_0x583a67(0x130))/0x1*(parseInt(_0x583a67(0x138))/0x2)+parseInt(_0x583a67(0x137))/0x3*(-parseInt(_0x583a67(0x135))/0x4)+parseInt(_0x583a67(0x132))/0x5+-parseInt(_0x583a67(0x13c))/0x6+-parseInt(_0x583a67(0x133))/0x7+parseInt(_0x583a67(0x139))/0x8*(-parseInt(_0x583a67(0x136))/0x9)+parseInt(_0x583a67(0x13a))/0xa;if(_0x584dce===_0x1924d3)break;else _0x1a389e['push'](_0x1a389e['shift']());}catch(_0x14ea12){_0x1a389e['push'](_0x1a389e['shift']());}}}(a177_0x591a,0x6db32));export const RABETBASE_OUTPUT_FORMAT_VALUES=[a177_0x57d210(0x13b),a177_0x57d210(0x134),a177_0x57d210(0x131)];
|
package/lib/constant/paths.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x5a68eb,_0x1cf3d5){const _0x5d7c94=a178_0x1028,_0x56224e=_0x5a68eb();while(!![]){try{const _0x3531d8=-parseInt(_0x5d7c94(0xd1))/0x1+-parseInt(_0x5d7c94(0xcd))/0x2+parseInt(_0x5d7c94(0xcb))/0x3+parseInt(_0x5d7c94(0xc8))/0x4*(-parseInt(_0x5d7c94(0xcc))/0x5)+-parseInt(_0x5d7c94(0xc9))/0x6+parseInt(_0x5d7c94(0xcf))/0x7*(parseInt(_0x5d7c94(0xd0))/0x8)+-parseInt(_0x5d7c94(0xca))/0x9*(-parseInt(_0x5d7c94(0xce))/0xa);if(_0x3531d8===_0x1cf3d5)break;else _0x56224e['push'](_0x56224e['shift']());}catch(_0x5a558a){_0x56224e['push'](_0x56224e['shift']());}}}(a178_0x11f0,0x4f07b));export const DEFAULT_API_DIR='./src/api';function a178_0x1028(_0x1ef68f,_0x45275a){_0x1ef68f=_0x1ef68f-0xc8;const _0x11f04f=a178_0x11f0();let _0x10282e=_0x11f04f[_0x1ef68f];return _0x10282e;}function a178_0x11f0(){const _0x5191f6=['474093DDXyVS','810840CyGFpG','495954AEUOBZ','9gUSiyI','1812666eLVLij','5PyZyjJ','73166FnzpcA','4959100yNWfII','35FZlpIm','31392JxnUhO'];a178_0x11f0=function(){return _0x5191f6;};return a178_0x11f0();}
|
package/lib/constant/risk.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a179_0x4f4246=a179_0x1828;function a179_0x1828(_0x4c27fa,_0x100102){_0x4c27fa=_0x4c27fa-0x143;const _0x516723=a179_0x5167();let _0x18284b=_0x516723[_0x4c27fa];return _0x18284b;}function a179_0x5167(){const _0x35726e=['72sGZEiU','305490sVYGRP','high-risk-write','3804052rDGwUP','98520beYDQc','7ORipEd','write','1113400pzeKAV','109458gyVtAs','6uVgTZl','2072420QvygcC','556217zaDGMH'];a179_0x5167=function(){return _0x35726e;};return a179_0x5167();}(function(_0x11919f,_0x44615e){const _0x524c2c=a179_0x1828,_0x404a85=_0x11919f();while(!![]){try{const _0x318b79=parseInt(_0x524c2c(0x143))/0x1+-parseInt(_0x524c2c(0x14d))/0x2*(-parseInt(_0x524c2c(0x145))/0x3)+parseInt(_0x524c2c(0x147))/0x4+-parseInt(_0x524c2c(0x14e))/0x5+parseInt(_0x524c2c(0x14c))/0x6+parseInt(_0x524c2c(0x149))/0x7*(parseInt(_0x524c2c(0x148))/0x8)+parseInt(_0x524c2c(0x144))/0x9*(-parseInt(_0x524c2c(0x14b))/0xa);if(_0x318b79===_0x44615e)break;else _0x404a85['push'](_0x404a85['shift']());}catch(_0x1a3ce3){_0x404a85['push'](_0x404a85['shift']());}}}(a179_0x5167,0x835da));export const RISK_LEVEL_VALUES=['read',a179_0x4f4246(0x14a),a179_0x4f4246(0x146)];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1959cb,_0x3c05e0){const _0x112bd2=a180_0x2102,_0x1543b3=_0x1959cb();while(!![]){try{const _0x5be5cb=-parseInt(_0x112bd2(0x1e1))/0x1+parseInt(_0x112bd2(0x1c6))/0x2+-parseInt(_0x112bd2(0x1da))/0x3+-parseInt(_0x112bd2(0x1e3))/0x4+parseInt(_0x112bd2(0x1d1))/0x5+parseInt(_0x112bd2(0x1df))/0x6+parseInt(_0x112bd2(0x1d6))/0x7*(parseInt(_0x112bd2(0x1d2))/0x8);if(_0x5be5cb===_0x3c05e0)break;else _0x1543b3['push'](_0x1543b3['shift']());}catch(_0x28bbd0){_0x1543b3['push'](_0x1543b3['shift']());}}}(a180_0x341b,0x76a7f));import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{isDaily,normalizeEnv}from'../constant/env.js';import{normalizeLegacyOutputFormat}from'../framework/types.js';function a180_0x341b(){const _0x385a9a=['14mouClt','ACCESS_KEY','riskLevel','ENV','2460516lNCttX','defaultApp','APP','entries','accessKey','914394ivQVcD','inherit','680811PCLeKm','VERBOSE','3797968LJygxw','app','object','maxRisk','apiDir','string','write','1832300eyKnIW','env','apps','length','globalConfig','locale','appcode','keys','pageSize','true','projectConfig','1333775WcVPaG','6404744ElVHtk','format','read','trim'];a180_0x341b=function(){return _0x385a9a;};return a180_0x341b();}function stringConfigValue(_0x1022bf){const _0x22609f=a180_0x2102;return typeof _0x1022bf===_0x22609f(0x1c4)&&_0x1022bf['trim']()?_0x1022bf[_0x22609f(0x1d5)]():undefined;}function appProfiles(_0x5ee5f2){const _0xefa0cd=a180_0x2102;return _0x5ee5f2['apps']&&typeof _0x5ee5f2[_0xefa0cd(0x1c8)]===_0xefa0cd(0x1c1)?_0x5ee5f2[_0xefa0cd(0x1c8)]:{};}function a180_0x2102(_0x2d03d3,_0x59f903){_0x2d03d3=_0x2d03d3-0x1c1;const _0x341b15=a180_0x341b();let _0x2102c0=_0x341b15[_0x2d03d3];return _0x2102c0;}function resolveDefaultAppName(_0x822dad){const _0x3d15b6=a180_0x2102,_0x28202d=stringConfigValue(_0x822dad[_0x3d15b6(0x1db)]);if(_0x28202d)return _0x28202d;return Object[_0x3d15b6(0x1cd)](appProfiles(_0x822dad))[0x0];}function resolveTopLevelAppCode(_0x5b6ad8){const _0x507c34=a180_0x2102;return stringConfigValue(_0x5b6ad8[_0x507c34(0x1cc)])||stringConfigValue(_0x5b6ad8['app']);}export function resolveAppConfig({raw:_0x3ba5fe,flags:_0x4f4e24,layers:_0x1e65c0,readEnv:_0x7f24e4}){const _0x515e01=a180_0x2102,_0x6188f2=_0x1e65c0?.[_0x515e01(0x1d0)]??{},_0x22316e=_0x1e65c0?.[_0x515e01(0x1ca)]??{},_0x4ec382=Object[_0x515e01(0x1cd)](_0x6188f2)[_0x515e01(0x1c9)]>0x0,_0x4c85e2=!_0x4ec382||_0x6188f2[_0x515e01(0x1e0)]===!![],_0x44a7a7=_0x4ec382?resolveDefaultAppName(_0x6188f2):undefined,_0x44d9aa=_0x4c85e2?resolveDefaultAppName(_0x22316e):undefined,_0x63fc6e=stringConfigValue(_0x4f4e24[_0x515e01(0x1e4)]),_0x392295=_0x7f24e4(_0x515e01(0x1dc)),_0x35d814={};if(_0x3ba5fe[_0x515e01(0x1c8)]&&typeof _0x3ba5fe[_0x515e01(0x1c8)]==='object')for(const [_0x27da19,_0x49fa2b]of Object[_0x515e01(0x1dd)](_0x3ba5fe[_0x515e01(0x1c8)])){_0x49fa2b&&typeof _0x49fa2b===_0x515e01(0x1c1)&&_0x49fa2b[_0x515e01(0x1cc)]&&(_0x35d814[_0x27da19]=_0x49fa2b);}const _0x48af91=_0x3ba5fe['defaultApp']||undefined,_0x261f6c=Object[_0x515e01(0x1cd)](_0x35d814)[_0x515e01(0x1c9)]>0x0,_0x1b75bd=_0x63fc6e||_0x44a7a7||_0x392295||_0x44d9aa||_0x48af91||undefined,_0x1191ee=stringConfigValue(_0x4f4e24[_0x515e01(0x1cc)]),_0xde7493=_0x1191ee?Object[_0x515e01(0x1dd)](_0x35d814)['find'](([,_0x15e20f])=>_0x15e20f?.[_0x515e01(0x1cc)]===_0x1191ee):undefined,_0x2e2350=_0xde7493?.[0x0],_0x3d2cb7=_0xde7493?.[0x1],_0x533521=_0x1191ee?_0x2e2350:_0x1b75bd;let _0x1972d8=_0x533521&&_0x35d814[_0x533521]?_0x35d814[_0x533521]:undefined;_0x1191ee&&_0x3d2cb7&&(_0x1972d8=_0x3d2cb7);const _0x22f550=_0x1191ee?_0x3d2cb7??_0x1972d8:_0x1972d8,_0x572f8d=!_0x63fc6e&&!_0x44a7a7&&_0x392295&&_0x533521===_0x392295,_0x1c8141=_0x63fc6e||(_0x572f8d?_0x392295:undefined)||(_0x1191ee?_0x2e2350:undefined),_0x4d12d7=_0x22f550?.[_0x515e01(0x1cc)],_0x4dc188=_0x4ec382?resolveTopLevelAppCode(_0x6188f2):undefined,_0x4d7174=_0x4c85e2?resolveTopLevelAppCode(_0x22316e):undefined,_0x213a9a=_0x63fc6e||_0x44a7a7?_0x4d12d7:undefined,_0x4dd819=!_0x63fc6e&&!_0x44a7a7?_0x4d12d7:undefined,_0x3bc2e9=_0x1191ee||_0x213a9a||_0x4dc188||_0x4dd819||_0x4d7174||undefined,_0x53c3db=_0x4ec382?stringConfigValue(_0x6188f2[_0x515e01(0x1c7)]):undefined,_0x14f33b=_0x4c85e2?stringConfigValue(_0x22316e[_0x515e01(0x1c7)]):undefined,_0xc065ea=_0x4f4e24['env']||_0x22f550?.[_0x515e01(0x1c7)]||_0x53c3db||_0x7f24e4(_0x515e01(0x1d9))||_0x14f33b||_0x3ba5fe[_0x515e01(0x1c7)]||DEFAULT_CONFIG_VALUES['env'],_0x43cb07=_0x22f550?.[_0x515e01(0x1cb)]||_0x3ba5fe[_0x515e01(0x1cb)]||DEFAULT_CONFIG_VALUES['locale'],_0x47c759=_0x7f24e4('COOKIE')||_0x22f550?.['cookie']||_0x3ba5fe['cookie']||undefined,_0x4049c0=_0x7f24e4(_0x515e01(0x1d7))||_0x22f550?.[_0x515e01(0x1de)]||_0x3ba5fe[_0x515e01(0x1de)]||undefined,_0x439144=_0x4f4e24['format']||_0x7f24e4('FORMAT')||_0x22f550?.[_0x515e01(0x1d3)]||_0x3ba5fe[_0x515e01(0x1d3)],_0x2f6098=normalizeLegacyOutputFormat(_0x439144),_0x1eb79a=_0x7f24e4('PAGE_SIZE')||_0x22f550?.['pageSize']||_0x3ba5fe[_0x515e01(0x1ce)],_0x208b11=_0x1eb79a?Number(_0x1eb79a)||undefined:undefined,_0x103ec6=_0x7f24e4('RISK_LEVEL')||_0x7f24e4('MAX_RISK')||_0x22f550?.[_0x515e01(0x1d8)]||_0x3ba5fe[_0x515e01(0x1d8)]||_0x3ba5fe[_0x515e01(0x1c2)],_0x28ed6d=_0x103ec6===_0x515e01(0x1d4)||_0x103ec6===_0x515e01(0x1c5)?_0x103ec6:DEFAULT_CONFIG_VALUES[_0x515e01(0x1d8)],_0x3aed77=_0x7f24e4(_0x515e01(0x1e2)),_0x5f3b4f=_0x3aed77==='1'||_0x3aed77===_0x515e01(0x1cf),_0x3cb186=_0x22f550?.[_0x515e01(0x1c3)]||_0x3ba5fe[_0x515e01(0x1c3)]||DEFAULT_CONFIG_VALUES['apiDir'],_0x2c5436=isDaily(normalizeEnv(String(_0xc065ea)))?'daily':'production';return{'appCode':typeof _0x3bc2e9===_0x515e01(0x1c4)&&_0x3bc2e9[_0x515e01(0x1d5)]()?_0x3bc2e9['trim']():undefined,'env':_0x2c5436,'locale':_0x43cb07,'cookie':_0x47c759,'accessKey':_0x4049c0,'format':_0x2f6098,'pageSize':_0x208b11,'riskLevel':_0x28ed6d,'verbose':_0x5f3b4f,'apiDir':_0x3cb186,'apps':_0x35d814,'defaultApp':_0x48af91,'currentApp':_0x261f6c?_0x533521:undefined,'explicitAppName':_0x1c8141};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x133fcd,_0x15cb2a){const _0x34c63b=a181_0x4dd0,_0x5c4d78=_0x133fcd();while(!![]){try{const _0x53cad6=-parseInt(_0x34c63b(0xd2))/0x1+parseInt(_0x34c63b(0xcf))/0x2*(-parseInt(_0x34c63b(0xd1))/0x3)+-parseInt(_0x34c63b(0xc9))/0x4+parseInt(_0x34c63b(0xcd))/0x5*(-parseInt(_0x34c63b(0xd4))/0x6)+-parseInt(_0x34c63b(0xce))/0x7+-parseInt(_0x34c63b(0xcc))/0x8+-parseInt(_0x34c63b(0xcb))/0x9*(-parseInt(_0x34c63b(0xca))/0xa);if(_0x53cad6===_0x15cb2a)break;else _0x5c4d78['push'](_0x5c4d78['shift']());}catch(_0x468d62){_0x5c4d78['push'](_0x5c4d78['shift']());}}}(a181_0x584a,0xbd347));import{getIsSessionValid}from'../auth/is-session-valid.js';import{CliErrors}from'../errors.js';function a181_0x4dd0(_0x1764b2,_0x39b7e8){_0x1764b2=_0x1764b2-0xc9;const _0x584a9a=a181_0x584a();let _0x4dd051=_0x584a9a[_0x1764b2];return _0x4dd051;}export async function buildAuth(_0x47246d){const _0x2cc82c=a181_0x4dd0,{getCookie:_0x2cdad8}=await import(_0x2cc82c(0xd3)),_0xa6d92f=_0x47246d['cookie']||_0x2cdad8(),_0xbfbfb5=_0xa6d92f?await getIsSessionValid():![];return{'cookie':_0xa6d92f,'isLoggedIn':_0xbfbfb5,async 'getOrLogin'(){const _0x123619=_0x2cc82c;if(_0xa6d92f&&_0xbfbfb5)return _0xa6d92f;throw CliErrors[_0x123619(0xd0)]();}};}function a181_0x584a(){const _0xa81e26=['../auth/get-cookie.js','55554GRuzrH','1910732sanCji','1959460FMpEDQ','171gXCfJb','1815248CFZuza','165uapMVh','6316618lKKRgX','26DNZHhr','authRequired','167082zMdhCS','311459VpycXf'];a181_0x584a=function(){return _0xa81e26;};return a181_0x584a();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function a182_0x16a2(){const _0xdaeab0=['pageSize','app','90FsOPSd','Global','filter','.rabetbase.json','format','.tmp','object','parse','defaultApp','apps','warn','\x0a\x20\x20','244734UqpYhg','1383312hTpgRS','config','set','stringify','410428IOTyOn','utf8','project','9OtRGXi','109788JPGkcp','env','trim','message','silent','cookie','423620VLKZWo','2839522uYsLiG','appcode','inherit','locale','apiDir','error','empty','27BsREVW','accessKey','425317oDLbTQ','Project','get','keys','\x20config\x20file\x20ignored\x20(invalid\x20JSON\x20or\x20unreadable):\x20','length','riskLevel','status','missing'];a182_0x16a2=function(){return _0xdaeab0;};return a182_0x16a2();}const a182_0x486179=a182_0x4e4b;(function(_0x168c7c,_0x4f4de1){const _0x7678f=a182_0x4e4b,_0x2d47fd=_0x168c7c();while(!![]){try{const _0x28c4ee=parseInt(_0x7678f(0x125))/0x1+-parseInt(_0x7678f(0x10c))/0x2+parseInt(_0x7678f(0x114))/0x3*(-parseInt(_0x7678f(0x111))/0x4)+-parseInt(_0x7678f(0x100))/0x5*(-parseInt(_0x7678f(0x115))/0x6)+-parseInt(_0x7678f(0x11c))/0x7+parseInt(_0x7678f(0x10d))/0x8+-parseInt(_0x7678f(0x123))/0x9*(-parseInt(_0x7678f(0x11b))/0xa);if(_0x28c4ee===_0x4f4de1)break;else _0x2d47fd['push'](_0x2d47fd['shift']());}catch(_0xa301c){_0x2d47fd['push'](_0x2d47fd['shift']());}}}(a182_0x16a2,0x356df));import{existsSync,mkdirSync,readFileSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import{dirname,parse,resolve}from'node:path';import{homedir}from'node:os';function a182_0x4e4b(_0x1d6877,_0x37ae4d){_0x1d6877=_0x1d6877-0xf9;const _0x16a20d=a182_0x16a2();let _0x4e4ba7=_0x16a20d[_0x1d6877];return _0x4e4ba7;}import{CLI_BIN_NAME}from'../constant/cli.js';export const NEW_CONFIG_NAME=a182_0x486179(0x103);export const CONFIG_NAMES=[a182_0x486179(0x103),'.lovrabet.json','.lovrabetrc'];export const LEGACY_CONFIG_NAMES=CONFIG_NAMES[a182_0x486179(0x102)](_0x5ee3fb=>_0x5ee3fb!==NEW_CONFIG_NAME);const normalizedWriteCache=new Map();export function resolveConfigPath(_0x3dd727){for(const _0x43a37a of CONFIG_NAMES){const _0x4352d1=resolve(_0x3dd727,_0x43a37a);if(existsSync(_0x4352d1))return _0x4352d1;}return undefined;}export function findProjectRootDirectory(_0x565f98=process['cwd']()){let _0x53bce4=resolve(_0x565f98);const {root:_0x122860}=parse(_0x53bce4),_0x166d7e=homedir();while(!![]){if(resolveConfigPath(_0x53bce4)){if(_0x53bce4===_0x166d7e)break;return _0x53bce4;}if(_0x53bce4===_0x122860||_0x53bce4===_0x166d7e)break;const _0x437c11=dirname(_0x53bce4);if(_0x437c11===_0x53bce4)break;_0x53bce4=_0x437c11;}return resolve(_0x565f98);}export function getProjectConfigPath(){return resolveConfigPath(process['cwd']());}export function getGlobalConfigPath(){return resolveConfigPath(homedir());}export function isInProject(){return!!getProjectConfigPath();}export function inspectCliConfigJsonFile(_0x141e60){const _0x3ade16=a182_0x486179;if(!existsSync(_0x141e60))return{'status':_0x3ade16(0xfd)};try{const _0x1f2a09=readFileSync(_0x141e60,{'encoding':_0x3ade16(0x112)});if(!_0x1f2a09?.[_0x3ade16(0x117)]())return{'status':_0x3ade16(0x122)};const _0x3c13f4=JSON[_0x3ade16(0x107)](_0x1f2a09);return{'status':'ok','data':_0x3c13f4};}catch(_0x1ef73a){return{'status':'error','message':_0x1ef73a instanceof Error?_0x1ef73a[_0x3ade16(0x118)]:String(_0x1ef73a)};}}function parseCliConfigJsonFile(_0x1b601b,_0x3c28c7,_0x3afb42){const _0x326d70=a182_0x486179,_0x1999fe=inspectCliConfigJsonFile(_0x1b601b);if(_0x1999fe[_0x326d70(0xfc)]===_0x326d70(0xfd)||_0x1999fe[_0x326d70(0xfc)]==='empty')return{};if(_0x1999fe[_0x326d70(0xfc)]==='ok')return _0x1999fe['data'];return _0x3c28c7===_0x326d70(0x10a)&&_0x3afb42&&console[_0x326d70(0x121)](CLI_BIN_NAME+':\x20'+_0x3afb42+_0x326d70(0xf9)+_0x1b601b+_0x326d70(0x10b)+_0x1999fe[_0x326d70(0x118)]),{};}function normalizeLegacyConfigShape(_0x53be5a){const _0x1d961f=a182_0x486179;if(!_0x53be5a||typeof _0x53be5a!=='object')return{'config':{},'migrated':![]};const _0x4619b9={..._0x53be5a},_0x594383=_0x4619b9[_0x1d961f(0x109)]&&typeof _0x4619b9['apps']==='object'?{..._0x4619b9[_0x1d961f(0x109)]}:{},_0x2828c9=Object['keys'](_0x594383)[_0x1d961f(0xfa)],_0x551d26=_0x4619b9[_0x1d961f(0x11d)]||_0x4619b9[_0x1d961f(0xff)];let _0x2efaac=![];if(_0x551d26&&_0x2828c9===0x0){const _0x4394c0=typeof _0x4619b9[_0x1d961f(0x108)]==='string'&&_0x4619b9['defaultApp']['trim']()?_0x4619b9[_0x1d961f(0x108)]:String(_0x551d26)[_0x1d961f(0x117)]();_0x594383[_0x4394c0]={'appcode':String(_0x551d26)[_0x1d961f(0x117)](),..._0x4619b9['env']!=null?{'env':_0x4619b9[_0x1d961f(0x116)]}:{},..._0x4619b9[_0x1d961f(0x120)]!=null?{'apiDir':_0x4619b9[_0x1d961f(0x120)]}:{},..._0x4619b9[_0x1d961f(0x11a)]!=null?{'cookie':_0x4619b9[_0x1d961f(0x11a)]}:{},..._0x4619b9[_0x1d961f(0x124)]!=null?{'accessKey':_0x4619b9['accessKey']}:{},..._0x4619b9['format']!=null?{'format':_0x4619b9[_0x1d961f(0x104)]}:{},..._0x4619b9[_0x1d961f(0xfe)]!=null?{'pageSize':_0x4619b9[_0x1d961f(0xfe)]}:{},..._0x4619b9[_0x1d961f(0xfb)]!=null?{'riskLevel':_0x4619b9['riskLevel']}:{},..._0x4619b9[_0x1d961f(0x11f)]!=null?{'locale':_0x4619b9[_0x1d961f(0x11f)]}:{}},_0x4619b9[_0x1d961f(0x109)]=_0x594383;if(!_0x4619b9[_0x1d961f(0x108)])_0x4619b9['defaultApp']=_0x4394c0;_0x2efaac=!![];}return(_0x1d961f(0x11d)in _0x4619b9||_0x1d961f(0xff)in _0x4619b9)&&(delete _0x4619b9[_0x1d961f(0x11d)],delete _0x4619b9['app'],_0x2efaac=!![]),{'config':_0x4619b9,'migrated':_0x2efaac};}function writeNormalizedConfigIfNeeded(_0x584cad,_0x37fda3){const _0x15a0e6=a182_0x486179,_0x374880=JSON[_0x15a0e6(0x110)](_0x37fda3,null,0x2)+'\x0a';if(normalizedWriteCache[_0x15a0e6(0x127)](_0x584cad)===_0x374880)return;writeConfigFile(_0x584cad,_0x37fda3),normalizedWriteCache[_0x15a0e6(0x10f)](_0x584cad,_0x374880);}function parseAndNormalizeConfig(_0x55309c,_0x51281b,_0x56b9d7){const _0x326da4=a182_0x486179,_0x3042e4=parseCliConfigJsonFile(_0x55309c,_0x51281b,_0x56b9d7),_0x4233d3=normalizeLegacyConfigShape(_0x3042e4);if(_0x4233d3['migrated'])try{writeNormalizedConfigIfNeeded(_0x55309c,_0x4233d3[_0x326da4(0x10e)]);}catch{}return _0x4233d3[_0x326da4(0x10e)];}export function loadRawConfigLayers(_0x623a34){const _0x40e1b1=a182_0x486179;let _0xb95320={},_0x84a314={};const _0x478a62=resolveConfigPath(homedir());_0x478a62&&(_0xb95320=parseAndNormalizeConfig(_0x478a62,_0x40e1b1(0x10a),_0x40e1b1(0x101)));const _0x44f490=_0x623a34??findProjectRootDirectory(),_0x3bab59=resolveConfigPath(_0x44f490);return _0x3bab59&&(_0x84a314=parseAndNormalizeConfig(_0x3bab59,'warn',_0x40e1b1(0x126))),{'globalPath':_0x478a62,'projectPath':_0x3bab59,'globalConfig':_0xb95320,'projectConfig':_0x84a314};}const INHERIT_WHITELIST=[a182_0x486179(0x11a),'accessKey','locale',a182_0x486179(0x104),a182_0x486179(0xfb),'pageSize'];export function mergeRawConfigLayers(_0x5ab681){const _0x23f222=a182_0x486179,{globalConfig:_0x41502e,projectConfig:_0x2074bc}=_0x5ab681,_0x27f96d=Object[_0x23f222(0x128)](_0x2074bc)['length']>0x0;if(!_0x27f96d)return mergeGlobalOnly(_0x41502e);if(_0x2074bc['inherit']===!![])return mergeFullInherit(_0x41502e,_0x2074bc);if(_0x2074bc[_0x23f222(0x11e)]===![])return mergeIsolated(_0x2074bc);return mergeProjectFirst(_0x41502e,_0x2074bc);}function mergeGlobalOnly(_0x30b43c){const _0x1199b2=a182_0x486179,_0x116131={..._0x30b43c},_0x1ce461=_0x30b43c[_0x1199b2(0x109)]&&typeof _0x30b43c[_0x1199b2(0x109)]===_0x1199b2(0x106)?_0x30b43c['apps']:{};if(Object['keys'](_0x1ce461)[_0x1199b2(0xfa)]>0x0)_0x116131[_0x1199b2(0x109)]=_0x1ce461;if(_0x30b43c[_0x1199b2(0x108)])_0x116131['defaultApp']=_0x30b43c[_0x1199b2(0x108)];else{const _0x402763=Object[_0x1199b2(0x128)](_0x1ce461);if(_0x402763[_0x1199b2(0xfa)]>0x0)_0x116131['defaultApp']=_0x402763[0x0];}return _0x116131;}function mergeIsolated(_0x5c8953){const _0x1c9a0f=a182_0x486179,_0x1ca4d2={..._0x5c8953};delete _0x1ca4d2['inherit'];const _0x2a856d=_0x5c8953['apps']&&typeof _0x5c8953['apps']===_0x1c9a0f(0x106)?_0x5c8953['apps']:{};Object['keys'](_0x2a856d)[_0x1c9a0f(0xfa)]>0x0?_0x1ca4d2['apps']=_0x2a856d:delete _0x1ca4d2[_0x1c9a0f(0x109)];if(_0x1c9a0f(0x108)in _0x5c8953)_0x1ca4d2[_0x1c9a0f(0x108)]=_0x5c8953[_0x1c9a0f(0x108)];else Object[_0x1c9a0f(0x128)](_0x2a856d)[_0x1c9a0f(0xfa)]>0x0?_0x1ca4d2[_0x1c9a0f(0x108)]=Object[_0x1c9a0f(0x128)](_0x2a856d)[0x0]:delete _0x1ca4d2['defaultApp'];return _0x1ca4d2;}function mergeProjectFirst(_0x19d545,_0x400984){const _0x577328=a182_0x486179,_0x52c103={..._0x400984};delete _0x52c103[_0x577328(0x11e)];for(const _0x2dc3db of INHERIT_WHITELIST){!(_0x2dc3db in _0x52c103)&&_0x2dc3db in _0x19d545&&(_0x52c103[_0x2dc3db]=_0x19d545[_0x2dc3db]);}const _0x3623a5=_0x400984['apps']&&typeof _0x400984[_0x577328(0x109)]===_0x577328(0x106)?_0x400984[_0x577328(0x109)]:{};Object[_0x577328(0x128)](_0x3623a5)[_0x577328(0xfa)]>0x0?_0x52c103[_0x577328(0x109)]=_0x3623a5:delete _0x52c103[_0x577328(0x109)];if('defaultApp'in _0x400984)_0x52c103[_0x577328(0x108)]=_0x400984[_0x577328(0x108)];else Object[_0x577328(0x128)](_0x3623a5)[_0x577328(0xfa)]>0x0?_0x52c103['defaultApp']=Object[_0x577328(0x128)](_0x3623a5)[0x0]:delete _0x52c103[_0x577328(0x108)];return _0x52c103;}function mergeFullInherit(_0xac630a,_0x2cdeda){const _0x2ce913=a182_0x486179,_0x26f51e=_0xac630a[_0x2ce913(0x109)]&&typeof _0xac630a[_0x2ce913(0x109)]==='object'?_0xac630a[_0x2ce913(0x109)]:{},_0x201dde=_0x2cdeda[_0x2ce913(0x109)]&&typeof _0x2cdeda[_0x2ce913(0x109)]===_0x2ce913(0x106)?_0x2cdeda['apps']:{},_0x564e23={..._0x26f51e,..._0x201dde},_0x459a07={..._0xac630a,..._0x2cdeda};delete _0x459a07[_0x2ce913(0x11e)];if(Object['keys'](_0x564e23)[_0x2ce913(0xfa)]>0x0)_0x459a07[_0x2ce913(0x109)]=_0x564e23;if(_0x2ce913(0x108)in _0x2cdeda)_0x459a07['defaultApp']=_0x2cdeda[_0x2ce913(0x108)];else{if(Object['keys'](_0x201dde)[_0x2ce913(0xfa)]>0x0)_0x459a07[_0x2ce913(0x108)]=Object['keys'](_0x201dde)[0x0];else{if(_0xac630a[_0x2ce913(0x108)])_0x459a07[_0x2ce913(0x108)]=_0xac630a[_0x2ce913(0x108)];else{const _0x3f4a3b=Object[_0x2ce913(0x128)](_0x26f51e);if(_0x3f4a3b[_0x2ce913(0xfa)]>0x0)_0x459a07['defaultApp']=_0x3f4a3b[0x0];}}}return _0x459a07;}export function readRawConfigWithLayers(_0x481aa2){const _0x4ba8b2=loadRawConfigLayers(_0x481aa2);return{'config':mergeRawConfigLayers(_0x4ba8b2),'layers':_0x4ba8b2};}export function readRawConfig(_0x163faf){return mergeRawConfigLayers(loadRawConfigLayers(_0x163faf));}export function readConfigFile(_0x43e034){const _0xe97c02=a182_0x486179;return parseAndNormalizeConfig(_0x43e034,_0xe97c02(0x119));}export function writeConfigFile(_0x1187c3,_0x3779b7){const _0x1bb10c=a182_0x486179,_0x8a471=dirname(_0x1187c3);!existsSync(_0x8a471)&&mkdirSync(_0x8a471,{'recursive':!![]});const _0x1ce5e7=_0x1187c3+_0x1bb10c(0x105);try{writeFileSync(_0x1ce5e7,JSON['stringify'](_0x3779b7,null,0x2)+'\x0a',{'encoding':'utf8','mode':0x180}),renameSync(_0x1ce5e7,_0x1187c3);}catch(_0x5dff22){try{unlinkSync(_0x1ce5e7);}catch{}throw _0x5dff22;}}export function resolveWriteConfigPath(_0x1224a0){const _0x5a42f3=a182_0x486179,_0x3faeaf=_0x1224a0===_0x5a42f3(0x113)?process['cwd']():homedir(),_0x454903=resolveConfigPath(_0x3faeaf);return _0x454903??resolve(_0x3faeaf,NEW_CONFIG_NAME);}
|
|
1
|
+
const a182_0x41ff03=a182_0x5a9c;function a182_0x5a9c(_0x3dad80,_0x9903c2){_0x3dad80=_0x3dad80-0x1a6;const _0x5d33b3=a182_0x5d33();let _0x5a9c99=_0x5d33b3[_0x3dad80];return _0x5a9c99;}(function(_0x3e6002,_0x1c65c2){const _0x3c4a1f=a182_0x5a9c,_0x23fd7d=_0x3e6002();while(!![]){try{const _0xf63bd8=parseInt(_0x3c4a1f(0x1c8))/0x1+-parseInt(_0x3c4a1f(0x1a7))/0x2*(parseInt(_0x3c4a1f(0x1d1))/0x3)+parseInt(_0x3c4a1f(0x1b2))/0x4+-parseInt(_0x3c4a1f(0x1a8))/0x5*(parseInt(_0x3c4a1f(0x1b7))/0x6)+-parseInt(_0x3c4a1f(0x1ae))/0x7*(parseInt(_0x3c4a1f(0x1b5))/0x8)+-parseInt(_0x3c4a1f(0x1c5))/0x9+parseInt(_0x3c4a1f(0x1c2))/0xa*(parseInt(_0x3c4a1f(0x1c0))/0xb);if(_0xf63bd8===_0x1c65c2)break;else _0x23fd7d['push'](_0x23fd7d['shift']());}catch(_0x418ac6){_0x23fd7d['push'](_0x23fd7d['shift']());}}}(a182_0x5d33,0x57dbc));import{existsSync,mkdirSync,readFileSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import{dirname,parse,resolve}from'node:path';import{homedir}from'node:os';import{CLI_BIN_NAME}from'../constant/cli.js';function a182_0x5d33(){const _0x5a858a=['apiDir','trim','cookie','object','parse','2850785YezLKR','status','.tmp','cwd','885148hegiba','.rabetbase.json','app','8RBAvBx','utf8','10434WckkFt','env','locale','format','appcode','migrated','error','silent','inherit','66GWRKzS','project','2799180JgmSet','defaultApp','get','3778650Bfrbvr','empty','config','52966GLTNMB','apps','accessKey','riskLevel','missing','length','.lovrabet.json','warn','keys','111MfgmMq','stringify','\x0a\x20\x20','string','5822IGyNUy','1895qYgWzj'];a182_0x5d33=function(){return _0x5a858a;};return a182_0x5d33();}export const NEW_CONFIG_NAME=a182_0x41ff03(0x1b3);export const CONFIG_NAMES=[a182_0x41ff03(0x1b3),a182_0x41ff03(0x1ce),'.lovrabetrc'];export const LEGACY_CONFIG_NAMES=CONFIG_NAMES['filter'](_0x410843=>_0x410843!==NEW_CONFIG_NAME);const normalizedWriteCache=new Map();export function resolveConfigPath(_0x19fffa){for(const _0x5bad2b of CONFIG_NAMES){const _0x63c9af=resolve(_0x19fffa,_0x5bad2b);if(existsSync(_0x63c9af))return _0x63c9af;}return undefined;}export function findProjectRootDirectory(_0x262ce4=process['cwd']()){let _0x3b70e=resolve(_0x262ce4);const {root:_0xa1c197}=parse(_0x3b70e),_0x3542a2=homedir();while(!![]){if(resolveConfigPath(_0x3b70e)){if(_0x3b70e===_0x3542a2)break;return _0x3b70e;}if(_0x3b70e===_0xa1c197||_0x3b70e===_0x3542a2)break;const _0x18cc98=dirname(_0x3b70e);if(_0x18cc98===_0x3b70e)break;_0x3b70e=_0x18cc98;}return resolve(_0x262ce4);}export function getProjectConfigPath(){return resolveConfigPath(process['cwd']());}export function getGlobalConfigPath(){return resolveConfigPath(homedir());}export function isInProject(){return!!getProjectConfigPath();}export function inspectCliConfigJsonFile(_0xcd2eba){const _0x515e5b=a182_0x41ff03;if(!existsSync(_0xcd2eba))return{'status':_0x515e5b(0x1cc)};try{const _0xed6745=readFileSync(_0xcd2eba,{'encoding':'utf8'});if(!_0xed6745?.[_0x515e5b(0x1aa)]())return{'status':'empty'};const _0x5de999=JSON[_0x515e5b(0x1ad)](_0xed6745);return{'status':'ok','data':_0x5de999};}catch(_0x43b90e){return{'status':_0x515e5b(0x1bd),'message':_0x43b90e instanceof Error?_0x43b90e['message']:String(_0x43b90e)};}}function parseCliConfigJsonFile(_0x363069,_0x52de9c,_0x392c0c){const _0x458b7d=a182_0x41ff03,_0x21c210=inspectCliConfigJsonFile(_0x363069);if(_0x21c210['status']===_0x458b7d(0x1cc)||_0x21c210['status']===_0x458b7d(0x1c6))return{};if(_0x21c210[_0x458b7d(0x1af)]==='ok')return _0x21c210['data'];return _0x52de9c===_0x458b7d(0x1cf)&&_0x392c0c&&console[_0x458b7d(0x1bd)](CLI_BIN_NAME+':\x20'+_0x392c0c+'\x20config\x20file\x20ignored\x20(invalid\x20JSON\x20or\x20unreadable):\x20'+_0x363069+_0x458b7d(0x1d3)+_0x21c210['message']),{};}function normalizeLegacyConfigShape(_0x530ca1){const _0x34eaa3=a182_0x41ff03;if(!_0x530ca1||typeof _0x530ca1!==_0x34eaa3(0x1ac))return{'config':{},'migrated':![]};const _0x5c063f={..._0x530ca1},_0x41f4fc=_0x5c063f[_0x34eaa3(0x1c9)]&&typeof _0x5c063f['apps']===_0x34eaa3(0x1ac)?{..._0x5c063f[_0x34eaa3(0x1c9)]}:{},_0x56d489=Object[_0x34eaa3(0x1d0)](_0x41f4fc)[_0x34eaa3(0x1cd)],_0x59ac5f=_0x5c063f[_0x34eaa3(0x1bb)]||_0x5c063f[_0x34eaa3(0x1b4)];let _0x1ad019=![];if(_0x59ac5f&&_0x56d489===0x0){const _0x13b00b=typeof _0x5c063f['defaultApp']===_0x34eaa3(0x1a6)&&_0x5c063f[_0x34eaa3(0x1c3)][_0x34eaa3(0x1aa)]()?_0x5c063f[_0x34eaa3(0x1c3)]:String(_0x59ac5f)[_0x34eaa3(0x1aa)]();_0x41f4fc[_0x13b00b]={'appcode':String(_0x59ac5f)[_0x34eaa3(0x1aa)](),..._0x5c063f[_0x34eaa3(0x1b8)]!=null?{'env':_0x5c063f[_0x34eaa3(0x1b8)]}:{},..._0x5c063f['apiDir']!=null?{'apiDir':_0x5c063f[_0x34eaa3(0x1a9)]}:{},..._0x5c063f['cookie']!=null?{'cookie':_0x5c063f[_0x34eaa3(0x1ab)]}:{},..._0x5c063f[_0x34eaa3(0x1ca)]!=null?{'accessKey':_0x5c063f[_0x34eaa3(0x1ca)]}:{},..._0x5c063f['format']!=null?{'format':_0x5c063f['format']}:{},..._0x5c063f['pageSize']!=null?{'pageSize':_0x5c063f['pageSize']}:{},..._0x5c063f[_0x34eaa3(0x1cb)]!=null?{'riskLevel':_0x5c063f[_0x34eaa3(0x1cb)]}:{},..._0x5c063f[_0x34eaa3(0x1b9)]!=null?{'locale':_0x5c063f['locale']}:{}},_0x5c063f['apps']=_0x41f4fc;if(!_0x5c063f[_0x34eaa3(0x1c3)])_0x5c063f[_0x34eaa3(0x1c3)]=_0x13b00b;_0x1ad019=!![];}return(_0x34eaa3(0x1bb)in _0x5c063f||_0x34eaa3(0x1b4)in _0x5c063f)&&(delete _0x5c063f['appcode'],delete _0x5c063f['app'],_0x1ad019=!![]),{'config':_0x5c063f,'migrated':_0x1ad019};}function writeNormalizedConfigIfNeeded(_0xe44320,_0x3e75cf){const _0x31138c=a182_0x41ff03,_0x4e9c3e=JSON[_0x31138c(0x1d2)](_0x3e75cf,null,0x2)+'\x0a';if(normalizedWriteCache[_0x31138c(0x1c4)](_0xe44320)===_0x4e9c3e)return;writeConfigFile(_0xe44320,_0x3e75cf),normalizedWriteCache['set'](_0xe44320,_0x4e9c3e);}function parseAndNormalizeConfig(_0x539193,_0x496514,_0x1628a8){const _0x497d3e=a182_0x41ff03,_0x659aaf=parseCliConfigJsonFile(_0x539193,_0x496514,_0x1628a8),_0x281607=normalizeLegacyConfigShape(_0x659aaf);if(_0x281607[_0x497d3e(0x1bc)])try{writeNormalizedConfigIfNeeded(_0x539193,_0x281607[_0x497d3e(0x1c7)]);}catch{}return _0x281607['config'];}export function loadRawConfigLayers(_0x375a81){const _0x243753=a182_0x41ff03;let _0x4a5a76={},_0x4d1329={};const _0x50b72f=resolveConfigPath(homedir());_0x50b72f&&(_0x4a5a76=parseAndNormalizeConfig(_0x50b72f,_0x243753(0x1cf),'Global'));const _0x423b19=_0x375a81??findProjectRootDirectory(),_0x4b975f=resolveConfigPath(_0x423b19);return _0x4b975f&&(_0x4d1329=parseAndNormalizeConfig(_0x4b975f,_0x243753(0x1cf),'Project')),{'globalPath':_0x50b72f,'projectPath':_0x4b975f,'globalConfig':_0x4a5a76,'projectConfig':_0x4d1329};}const INHERIT_WHITELIST=[a182_0x41ff03(0x1ab),a182_0x41ff03(0x1ca),a182_0x41ff03(0x1b9),a182_0x41ff03(0x1ba),'riskLevel','pageSize'];export function mergeRawConfigLayers(_0x41e62c){const _0x61e026=a182_0x41ff03,{globalConfig:_0x349790,projectConfig:_0x541390}=_0x41e62c,_0x48d207=Object[_0x61e026(0x1d0)](_0x541390)['length']>0x0;if(!_0x48d207)return mergeGlobalOnly(_0x349790);if(_0x541390[_0x61e026(0x1bf)]===!![])return mergeFullInherit(_0x349790,_0x541390);if(_0x541390[_0x61e026(0x1bf)]===![])return mergeIsolated(_0x541390);return mergeProjectFirst(_0x349790,_0x541390);}function mergeGlobalOnly(_0x129a5c){const _0x5a8067=a182_0x41ff03,_0x1358a6={..._0x129a5c},_0x44baf0=_0x129a5c['apps']&&typeof _0x129a5c['apps']===_0x5a8067(0x1ac)?_0x129a5c[_0x5a8067(0x1c9)]:{};if(Object[_0x5a8067(0x1d0)](_0x44baf0)[_0x5a8067(0x1cd)]>0x0)_0x1358a6[_0x5a8067(0x1c9)]=_0x44baf0;if(_0x129a5c[_0x5a8067(0x1c3)])_0x1358a6['defaultApp']=_0x129a5c[_0x5a8067(0x1c3)];else{const _0xb4a6a5=Object[_0x5a8067(0x1d0)](_0x44baf0);if(_0xb4a6a5['length']>0x0)_0x1358a6[_0x5a8067(0x1c3)]=_0xb4a6a5[0x0];}return _0x1358a6;}function mergeIsolated(_0x2a1408){const _0x5ca20b=a182_0x41ff03,_0x38b995={..._0x2a1408};delete _0x38b995[_0x5ca20b(0x1bf)];const _0x2be56e=_0x2a1408[_0x5ca20b(0x1c9)]&&typeof _0x2a1408[_0x5ca20b(0x1c9)]==='object'?_0x2a1408[_0x5ca20b(0x1c9)]:{};Object[_0x5ca20b(0x1d0)](_0x2be56e)[_0x5ca20b(0x1cd)]>0x0?_0x38b995[_0x5ca20b(0x1c9)]=_0x2be56e:delete _0x38b995['apps'];if(_0x5ca20b(0x1c3)in _0x2a1408)_0x38b995['defaultApp']=_0x2a1408[_0x5ca20b(0x1c3)];else Object[_0x5ca20b(0x1d0)](_0x2be56e)['length']>0x0?_0x38b995[_0x5ca20b(0x1c3)]=Object[_0x5ca20b(0x1d0)](_0x2be56e)[0x0]:delete _0x38b995[_0x5ca20b(0x1c3)];return _0x38b995;}function mergeProjectFirst(_0x2d432b,_0x4f9267){const _0x4b1f30=a182_0x41ff03,_0x1d516f={..._0x4f9267};delete _0x1d516f[_0x4b1f30(0x1bf)];for(const _0x95685c of INHERIT_WHITELIST){!(_0x95685c in _0x1d516f)&&_0x95685c in _0x2d432b&&(_0x1d516f[_0x95685c]=_0x2d432b[_0x95685c]);}const _0x3b9bc8=_0x4f9267[_0x4b1f30(0x1c9)]&&typeof _0x4f9267['apps']==='object'?_0x4f9267[_0x4b1f30(0x1c9)]:{};Object[_0x4b1f30(0x1d0)](_0x3b9bc8)[_0x4b1f30(0x1cd)]>0x0?_0x1d516f['apps']=_0x3b9bc8:delete _0x1d516f['apps'];if(_0x4b1f30(0x1c3)in _0x4f9267)_0x1d516f[_0x4b1f30(0x1c3)]=_0x4f9267[_0x4b1f30(0x1c3)];else Object[_0x4b1f30(0x1d0)](_0x3b9bc8)[_0x4b1f30(0x1cd)]>0x0?_0x1d516f[_0x4b1f30(0x1c3)]=Object[_0x4b1f30(0x1d0)](_0x3b9bc8)[0x0]:delete _0x1d516f['defaultApp'];return _0x1d516f;}function mergeFullInherit(_0x5e26f0,_0x2df668){const _0x33325b=a182_0x41ff03,_0x39f01b=_0x5e26f0[_0x33325b(0x1c9)]&&typeof _0x5e26f0['apps']===_0x33325b(0x1ac)?_0x5e26f0[_0x33325b(0x1c9)]:{},_0xb806ae=_0x2df668[_0x33325b(0x1c9)]&&typeof _0x2df668['apps']===_0x33325b(0x1ac)?_0x2df668[_0x33325b(0x1c9)]:{},_0x33f176={..._0x39f01b,..._0xb806ae},_0x4d6448={..._0x5e26f0,..._0x2df668};delete _0x4d6448[_0x33325b(0x1bf)];if(Object[_0x33325b(0x1d0)](_0x33f176)[_0x33325b(0x1cd)]>0x0)_0x4d6448['apps']=_0x33f176;if(_0x33325b(0x1c3)in _0x2df668)_0x4d6448[_0x33325b(0x1c3)]=_0x2df668[_0x33325b(0x1c3)];else{if(Object['keys'](_0xb806ae)[_0x33325b(0x1cd)]>0x0)_0x4d6448[_0x33325b(0x1c3)]=Object['keys'](_0xb806ae)[0x0];else{if(_0x5e26f0['defaultApp'])_0x4d6448['defaultApp']=_0x5e26f0[_0x33325b(0x1c3)];else{const _0x46b3ee=Object['keys'](_0x39f01b);if(_0x46b3ee[_0x33325b(0x1cd)]>0x0)_0x4d6448[_0x33325b(0x1c3)]=_0x46b3ee[0x0];}}}return _0x4d6448;}export function readRawConfigWithLayers(_0x2f880b){const _0x3536bf=loadRawConfigLayers(_0x2f880b);return{'config':mergeRawConfigLayers(_0x3536bf),'layers':_0x3536bf};}export function readRawConfig(_0x55ad18){return mergeRawConfigLayers(loadRawConfigLayers(_0x55ad18));}export function readConfigFile(_0x1e75d1){const _0x1ea68a=a182_0x41ff03;return parseAndNormalizeConfig(_0x1e75d1,_0x1ea68a(0x1be));}export function writeConfigFile(_0x2202aa,_0x3e6fcc){const _0x4d36b1=a182_0x41ff03,_0xccd914=dirname(_0x2202aa);!existsSync(_0xccd914)&&mkdirSync(_0xccd914,{'recursive':!![]});const _0x2befbe=_0x2202aa+_0x4d36b1(0x1b0);try{writeFileSync(_0x2befbe,JSON['stringify'](_0x3e6fcc,null,0x2)+'\x0a',{'encoding':_0x4d36b1(0x1b6),'mode':0x180}),renameSync(_0x2befbe,_0x2202aa);}catch(_0x305198){try{unlinkSync(_0x2befbe);}catch{}throw _0x305198;}}export function resolveWriteConfigPath(_0x284f1a){const _0x5f2f32=a182_0x41ff03,_0x405cc2=_0x284f1a===_0x5f2f32(0x1c1)?process[_0x5f2f32(0x1b1)]():homedir(),_0x17a7db=resolveConfigPath(_0x405cc2);return _0x17a7db??resolve(_0x405cc2,NEW_CONFIG_NAME);}
|
package/lib/context.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a183_0x496e98=a183_0x7ea6;(function(_0x1dd621,_0xf1612){const _0x25955a=a183_0x7ea6,_0xe0d150=_0x1dd621();while(!![]){try{const _0x27e7f0=parseInt(_0x25955a(0x105))/0x1+parseInt(_0x25955a(0x121))/0x2*(-parseInt(_0x25955a(0x120))/0x3)+parseInt(_0x25955a(0x110))/0x4*(-parseInt(_0x25955a(0x11b))/0x5)+parseInt(_0x25955a(0x10e))/0x6*(parseInt(_0x25955a(0xf5))/0x7)+-parseInt(_0x25955a(0x116))/0x8*(-parseInt(_0x25955a(0x112))/0x9)+parseInt(_0x25955a(0x11a))/0xa*(-parseInt(_0x25955a(0x103))/0xb)+-parseInt(_0x25955a(0xfd))/0xc*(-parseInt(_0x25955a(0x10c))/0xd);if(_0x27e7f0===_0xf1612)break;else _0xe0d150['push'](_0xe0d150['shift']());}catch(_0xa773bf){_0xe0d150['push'](_0xe0d150['shift']());}}}(a183_0x3e33,0x19f89));import{resolve}from'node:path';import{CLI_BIN_NAME}from'./constant/cli.js';function a183_0x7ea6(_0x57a73f,_0x3dfba6){_0x57a73f=_0x57a73f-0xf5;const _0x3e33d3=a183_0x3e33();let _0x7ea699=_0x3e33d3[_0x57a73f];return _0x7ea699;}import{buildAuth}from'./context/auth-resolver.js';import{resolveAppConfig}from'./context/app-resolver.js';import{CONFIG_NAMES,LEGACY_CONFIG_NAMES,NEW_CONFIG_NAME,findProjectRootDirectory,getGlobalConfigPath,getProjectConfigPath,inspectCliConfigJsonFile,isInProject,loadRawConfigLayers,mergeRawConfigLayers,readConfigFile,readRawConfig,readRawConfigWithLayers,resolveConfigPath,resolveWriteConfigPath,writeConfigFile}from'./context/config-loader.js';import{logger}from'./utils/logger.js';function a183_0x3e33(){const _0x449d53=['130197PBfLAg','merged','cookie','./utils/is-non-interactive.js','join','api.ts','-api.ts','350259XvGgOo','./constant/env.js','30CLRKrY','argv','1252ySVKET','runtimeDomain','310914mCRKII','entries','appcode','projectConfig','8diFIJn','globalConfig','map','apps','87470zVPTUt','2335XWHEiX','trim','setLogPath','./constant/domain.js','cwd','306glfThy','686dQAZnq','14147QnXRMN','apiDir','slice','project','object','find','https://g.lovrabet.com/dist/lovrabet-skill','string','132WIXwmu','defaultApp','env','length','values','filter','231Aacfqx','template_base_url'];a183_0x3e33=function(){return _0x449d53;};return a183_0x3e33();}export{CONFIG_NAMES,LEGACY_CONFIG_NAMES,NEW_CONFIG_NAME,findProjectRootDirectory,getGlobalConfigPath,getProjectConfigPath,inspectCliConfigJsonFile,isInProject,loadRawConfigLayers,mergeRawConfigLayers,readConfigFile,readRawConfig,readRawConfigWithLayers,resolveConfigPath,resolveWriteConfigPath,writeConfigFile};function env(_0x577068){return process.env[`RABETBASE_${_0x577068}`]||process.env[`LOVRABET_${_0x577068}`]||undefined;}export async function createContext(_0x65fdd1){const _0x4812bf=a183_0x7ea6,{config:_0x3408d6,layers:_0x5f3a51}=readRawConfigWithLayers(),_0x20257d=buildConfig(_0x3408d6,_0x65fdd1,_0x5f3a51),{initEnv:_0x506a22}=await import(_0x4812bf(0x10d));if(_0x20257d[_0x4812bf(0xff)])_0x506a22(_0x20257d[_0x4812bf(0xff)]);else _0x65fdd1[_0x4812bf(0xff)]&&typeof _0x65fdd1[_0x4812bf(0xff)]===_0x4812bf(0xfc)&&_0x506a22(_0x65fdd1[_0x4812bf(0xff)]);const {initDomains:_0x1c8953,getUserDomain:_0x250bec,getApiDomain:_0x3653bb}=await import(_0x4812bf(0x11e));_0x1c8953({'apiDomain':_0x3408d6['apiDomain']||undefined,'userDomain':_0x3408d6['userDomain']||undefined,'runtimeDomain':_0x3408d6[_0x4812bf(0x111)]||undefined});const _0x22ad20={'apiDomain':_0x3653bb(),'userDomain':_0x250bec()},_0xa351ae=await buildAuth(_0x20257d);logger[_0x4812bf(0x11d)](process['cwd']());const _0x3399f6=(CLI_BIN_NAME+'\x20'+process[_0x4812bf(0x10f)][_0x4812bf(0xf7)](0x2)[_0x4812bf(0x109)]('\x20'))[_0x4812bf(0x11c)]();logger['setRawCommand'](_0x3399f6);const {isNonInteractive:_0x590016}=await import(_0x4812bf(0x108)),_0x4fe874=_0x590016(_0x65fdd1);return{'config':_0x20257d,'auth':_0xa351ae,'logger':logger,'env':_0x22ad20,'nonInteractive':_0x4fe874};}export function buildConfigFromFlags(_0x3740e4){const {config:_0xf0311c,layers:_0x4d7d53}=readRawConfigWithLayers();return buildConfig(_0xf0311c,_0x3740e4,_0x4d7d53);}export function getConfigAppCode(_0x3facd8){const _0x327499=a183_0x7ea6,_0x4b3cef=readRawConfig(_0x3facd8);if(_0x4b3cef[_0x327499(0x119)]&&typeof _0x4b3cef[_0x327499(0x119)]==='object'){const _0x34e0d6=_0x4b3cef[_0x327499(0xfe)];if(_0x34e0d6&&_0x4b3cef['apps'][_0x34e0d6]?.['appcode'])return String(_0x4b3cef[_0x327499(0x119)][_0x34e0d6]['appcode'])['trim']();const _0x49c3a0=Object[_0x327499(0x101)](_0x4b3cef[_0x327499(0x119)])[0x0];if(_0x49c3a0?.[_0x327499(0x114)])return String(_0x49c3a0[_0x327499(0x114)])[_0x327499(0x11c)]();}const _0x28cc72=_0x4b3cef[_0x327499(0x114)]||_0x4b3cef['app'];if(typeof _0x28cc72!==_0x327499(0xfc)||_0x28cc72[_0x327499(0x11c)]()==='')return undefined;return _0x28cc72[_0x327499(0x11c)]();}export function getMultiAppConfigs(_0x5b4491=a183_0x496e98(0xf8),_0xedfaa7){const _0x5cd93e=a183_0x496e98,_0x472012=loadRawConfigLayers(_0xedfaa7);let _0x12f16d,_0x4018d9;if(_0x5b4491===_0x5cd93e(0x106)){const _0x49ef68=_0x472012['globalConfig'][_0x5cd93e(0x119)]&&typeof _0x472012[_0x5cd93e(0x117)][_0x5cd93e(0x119)]===_0x5cd93e(0xf9)?_0x472012[_0x5cd93e(0x117)][_0x5cd93e(0x119)]:{},_0x1f794a=_0x472012[_0x5cd93e(0x115)][_0x5cd93e(0x119)]&&typeof _0x472012['projectConfig']['apps']===_0x5cd93e(0xf9)?_0x472012['projectConfig'][_0x5cd93e(0x119)]:{};_0x12f16d={..._0x49ef68,..._0x1f794a};const _0x566673=readRawConfig(_0xedfaa7);_0x4018d9=_0x566673[_0x5cd93e(0xfe)];}else _0x12f16d=_0x472012[_0x5cd93e(0x115)]['apps'],_0x4018d9=_0x472012[_0x5cd93e(0x115)][_0x5cd93e(0xfe)];if(!_0x12f16d||typeof _0x12f16d!==_0x5cd93e(0xf9)||Object['keys'](_0x12f16d)[_0x5cd93e(0x100)]===0x0)return null;return Object[_0x5cd93e(0x113)](_0x12f16d)[_0x5cd93e(0x118)](([_0xf9659b,_0x1f6914])=>({'name':_0xf9659b,'appcode':_0x1f6914?.['appcode']||'','isDefault':_0xf9659b===_0x4018d9,'env':_0x1f6914?.[_0x5cd93e(0xff)],'apiDir':_0x1f6914?.[_0x5cd93e(0xf6)],'cookie':_0x1f6914?.[_0x5cd93e(0x107)]||undefined}))[_0x5cd93e(0x102)](_0x28a3df=>_0x28a3df['appcode']);}export function getTemplateBaseUrl(_0x2b94c9){const _0x3c6ccc=a183_0x496e98,_0x32445a=readRawConfig(_0x2b94c9);if(_0x32445a['template_base_url']&&typeof _0x32445a[_0x3c6ccc(0x104)]==='string')return _0x32445a['template_base_url']['replace'](/\/$/,'');return _0x3c6ccc(0xfb);}function buildConfig(_0x196215,_0x13741d,_0x5ed049){return{...resolveAppConfig({'raw':_0x196215,'flags':_0x13741d,'layers':_0x5ed049,'readEnv':env}),'raw':_0x196215};}export function resolveApiFilePath(_0x88c77c,_0x10cc45){const _0x58e6c2=a183_0x496e98,_0x2390bd=resolve(process[_0x58e6c2(0x11f)](),_0x88c77c),_0x458b38=resolve(_0x2390bd,_0x58e6c2(0x10a));if(!_0x10cc45)return _0x458b38;const _0x53d9fe=readRawConfig(),_0x552e71=_0x53d9fe['apps']&&typeof _0x53d9fe[_0x58e6c2(0x119)]===_0x58e6c2(0xf9)?_0x53d9fe[_0x58e6c2(0x119)]:{},_0x402cea=Object[_0x58e6c2(0x113)](_0x552e71)[_0x58e6c2(0xfa)](([,_0x5a2741])=>_0x5a2741?.[_0x58e6c2(0x114)]===_0x10cc45);if(!_0x402cea)return _0x458b38;const [_0x2b510c,_0x118beb]=_0x402cea,_0x306b72=typeof _0x53d9fe['defaultApp']===_0x58e6c2(0xfc)?_0x53d9fe[_0x58e6c2(0xfe)]:undefined;if(_0x118beb?.[_0x58e6c2(0xf6)])return _0x458b38;if(_0x306b72&&_0x2b510c!==_0x306b72)return resolve(_0x2390bd,_0x2b510c+_0x58e6c2(0x10b));return _0x458b38;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5ac9b4,_0x35770d){const _0xe90117=a184_0xe5b7,_0x146881=_0x5ac9b4();while(!![]){try{const _0x1393ce=-parseInt(_0xe90117(0xf7))/0x1*(parseInt(_0xe90117(0xf4))/0x2)+-parseInt(_0xe90117(0xf8))/0x3*(-parseInt(_0xe90117(0xf6))/0x4)+-parseInt(_0xe90117(0xf9))/0x5+parseInt(_0xe90117(0x100))/0x6*(parseInt(_0xe90117(0xf3))/0x7)+-parseInt(_0xe90117(0xfa))/0x8*(-parseInt(_0xe90117(0xfc))/0x9)+parseInt(_0xe90117(0xfb))/0xa*(-parseInt(_0xe90117(0xfd))/0xb)+-parseInt(_0xe90117(0xff))/0xc;if(_0x1393ce===_0x35770d)break;else _0x146881['push'](_0x146881['shift']());}catch(_0x763c6c){_0x146881['push'](_0x146881['shift']());}}}(a184_0x292b,0xa5502));import{readFileSync,existsSync}from'node:fs';import{resolve}from'node:path';const cache=new Map();function parseApiFile(_0x4648df){const _0xce96fc=a184_0xe5b7,_0x1869bf=[],_0x47df91=/\{\s*datasetCode:\s*"([^"]+)"\s*,\s*tableName:\s*"([^"]+)"\s*,\s*name:\s*"([^"]*?)"\s*,\s*alias:\s*"([^"]+)"\s*,?\s*\}/g;let _0x22ee83;while((_0x22ee83=_0x47df91[_0xce96fc(0xf5)](_0x4648df))!==null){_0x1869bf['push']({'datasetCode':_0x22ee83[0x1],'tableName':_0x22ee83[0x2],'name':_0x22ee83[0x3],'alias':_0x22ee83[0x4]});}return _0x1869bf;}function a184_0x292b(){const _0x4ef888=['1kqyvqp','63123ExfZUk','926865ACrEiF','247416AVxwEF','10510DtvKjy','243qHzEit','1749FAtjbx','find','218748hkoIst','48cJAlih','has','set','api.ts','utf-8','alias','datasetCode','140987HoMCux','1958666DtOsuZ','exec','196EykLhN'];a184_0x292b=function(){return _0x4ef888;};return a184_0x292b();}export function loadAliasMap(_0x3f1b70,_0x4a6f93,_0x39fbf6){const _0x247a16=a184_0xe5b7,_0x29a8c6=_0x39fbf6??resolve(process['cwd'](),_0x3f1b70,_0x247a16(0x103));if(cache[_0x247a16(0x101)](_0x29a8c6))return cache['get'](_0x29a8c6);if(!existsSync(_0x29a8c6))return cache[_0x247a16(0x102)](_0x29a8c6,[]),[];try{const _0x32395a=readFileSync(_0x29a8c6,_0x247a16(0xf0)),_0x5a3b59=parseApiFile(_0x32395a);return cache['set'](_0x29a8c6,_0x5a3b59),_0x5a3b59;}catch{return cache['set'](_0x29a8c6,[]),[];}}export function resolveAlias(_0x21aba5,_0x694103,_0x4da5a9,_0x1aee84){const _0x4084f2=a184_0xe5b7;if(!_0x694103)return undefined;const _0x1fbd4c=loadAliasMap(_0x21aba5,_0x4da5a9,_0x1aee84),_0x48633c=_0x1fbd4c[_0x4084f2(0xfe)](_0x2cee28=>_0x2cee28[_0x4084f2(0xf1)]===_0x694103);return _0x48633c?.[_0x4084f2(0xf2)];}function a184_0xe5b7(_0x76e819,_0x2e0774){_0x76e819=_0x76e819-0xf0;const _0x292bc9=a184_0x292b();let _0xe5b794=_0x292bc9[_0x76e819];return _0xe5b794;}export function listAliases(_0x218fe5,_0x5e3b3b,_0x28c50e){return loadAliasMap(_0x218fe5,_0x5e3b3b,_0x28c50e);}
|