@lovrabet/rabetbase-cli 2.3.9-beta.2 → 2.3.9
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/async-task.js +1 -0
- 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/delete.js +1 -0
- package/lib/commands/menu/group-create.js +1 -0
- package/lib/commands/menu/group-update.js +1 -0
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/regroup-start.js +1 -0
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/delete-plan.js +1 -0
- package/lib/commands/menu/shared/facts.js +1 -0
- 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/mutations.js +1 -0
- 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/task/index.js +1 -0
- package/lib/commands/task/status.js +1 -0
- 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-index-auditor.js +1 -0
- 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/error-output.js +1 -0
- package/lib/framework/explicit-yes.js +1 -0
- 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
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(function(_0x61f78,_0x540d4e){const _0x36d546=a207_0x2550,_0x1bb277=_0x61f78();while(!![]){try{const _0x4b4d84=-parseInt(_0x36d546(0x171))/0x1*(parseInt(_0x36d546(0x177))/0x2)+-parseInt(_0x36d546(0x17b))/0x3+-parseInt(_0x36d546(0x14c))/0x4*(-parseInt(_0x36d546(0x16c))/0x5)+-parseInt(_0x36d546(0x166))/0x6*(-parseInt(_0x36d546(0x14b))/0x7)+-parseInt(_0x36d546(0x174))/0x8*(parseInt(_0x36d546(0x147))/0x9)+parseInt(_0x36d546(0x16e))/0xa+-parseInt(_0x36d546(0x162))/0xb*(parseInt(_0x36d546(0x160))/0xc);if(_0x4b4d84===_0x540d4e)break;else _0x1bb277['push'](_0x1bb277['shift']());}catch(_0x559664){_0x1bb277['push'](_0x1bb277['shift']());}}}(a207_0x485a,0x2ce64));export function auditSqlJoinIndexes(_0x181afe,_0x548345){const _0x378900=a207_0x2550,_0x587626=[],_0x2ef88b=extractJoinFacts(_0x181afe)[_0x378900(0x141)](_0x44d835=>{const _0x4d6b86=_0x378900;if(_0x44d835[_0x4d6b86(0x15f)]||_0x44d835['columns']['length']===0x0)return _0x587626[_0x4d6b86(0x151)]({'code':_0x4d6b86(0x15e),'table':_0x44d835[_0x4d6b86(0x17e)],'alias':_0x44d835[_0x4d6b86(0x173)],'columns':_0x44d835['columns'],'reason':_0x44d835['unsupportedReason']??_0x4d6b86(0x157)}),{'table':_0x44d835['table'],'alias':_0x44d835[_0x4d6b86(0x173)],'columns':_0x44d835[_0x4d6b86(0x17c)],'status':_0x4d6b86(0x16a)};const _0x4fad82=resolveTableMetadata(_0x548345,_0x44d835['table']),_0x271828=(_0x4fad82?.['indexes']??[])['map'](_0x327034=>({'index':_0x327034,'matchedPrefix':findEqualityPrefix(_0x327034[_0x4d6b86(0x17c)],_0x44d835[_0x4d6b86(0x17c)])}))['filter'](_0x27de51=>_0x27de51[_0x4d6b86(0x148)][_0x4d6b86(0x15d)]>0x0),_0x97ff8=_0x271828[_0x4d6b86(0x169)]((_0x5b5d7a,_0x16ce9a)=>!_0x5b5d7a||_0x16ce9a[_0x4d6b86(0x148)][_0x4d6b86(0x15d)]>_0x5b5d7a[_0x4d6b86(0x148)][_0x4d6b86(0x15d)]?_0x16ce9a:_0x5b5d7a,_0x271828[0x0]);if(_0x97ff8)return{'table':_0x44d835[_0x4d6b86(0x17e)],'alias':_0x44d835[_0x4d6b86(0x173)],'columns':_0x44d835['columns'],'status':_0x4d6b86(0x182),'matchedIndex':{..._0x97ff8[_0x4d6b86(0x13e)],'matchedPrefix':_0x97ff8[_0x4d6b86(0x148)]}};const _0x540384=_0x4fad82?.[_0x4d6b86(0x184)][_0x4d6b86(0x16b)](_0x4ea5ec=>_0x4ea5ec['columns'][_0x4d6b86(0x179)](_0x1290ab=>_0x44d835[_0x4d6b86(0x17c)][_0x4d6b86(0x179)](_0x17f0bb=>columnNamesMatch(_0x1290ab,_0x17f0bb))))??[];if(_0x540384[_0x4d6b86(0x15d)]>0x0)return _0x587626[_0x4d6b86(0x151)]({'code':_0x4d6b86(0x161),'table':_0x44d835['table'],'alias':_0x44d835[_0x4d6b86(0x173)],'columns':_0x44d835[_0x4d6b86(0x17c)],'reason':_0x4d6b86(0x17a)}),{'table':_0x44d835[_0x4d6b86(0x17e)],'alias':_0x44d835['alias'],'columns':_0x44d835[_0x4d6b86(0x17c)],'status':_0x4d6b86(0x14e),'candidateIndexes':_0x540384};if(_0x4fad82&&_0x4fad82['metadataAvailable']!==![]&&_0x4fad82[_0x4d6b86(0x184)][_0x4d6b86(0x15d)]>0x0&&_0x44d835['columns'][_0x4d6b86(0x15d)]>0x0)return _0x587626[_0x4d6b86(0x151)]({'code':_0x4d6b86(0x178),'table':_0x44d835['table'],'alias':_0x44d835[_0x4d6b86(0x173)],'columns':_0x44d835[_0x4d6b86(0x17c)],'reason':'No\x20reported\x20index\x20contains\x20the\x20JOIN\x20access\x20columns.'}),{'table':_0x44d835[_0x4d6b86(0x17e)],'alias':_0x44d835[_0x4d6b86(0x173)],'columns':_0x44d835[_0x4d6b86(0x17c)],'status':_0x4d6b86(0x14e)};return _0x587626[_0x4d6b86(0x151)]({'code':_0x4d6b86(0x142),'table':_0x44d835['table'],'alias':_0x44d835[_0x4d6b86(0x173)],'columns':_0x44d835[_0x4d6b86(0x17c)],'reason':_0x4fad82?_0x4d6b86(0x152):'No\x20dataset\x20metadata\x20matched\x20the\x20JOIN\x20table.'}),{'table':_0x44d835[_0x4d6b86(0x17e)],'alias':_0x44d835[_0x4d6b86(0x173)],'columns':_0x44d835[_0x4d6b86(0x17c)],'status':_0x4d6b86(0x16a)};});return{'checked':_0x2ef88b[_0x378900(0x15d)]>0x0,'joins':_0x2ef88b,'warnings':_0x587626};}function extractJoinFacts(_0xb10aa){const _0x3a826a=a207_0x2550,_0x3f8c3e=maskNestedQueries(stripSqlNoise(_0xb10aa)),_0x8fc87d=maskQuotedIdentifiers(_0x3f8c3e),_0x55e184=[],_0x41c0fe=new Set(),_0x3a15ca=/\b(?:(INNER|LEFT|RIGHT|FULL)(?:\s+OUTER)?\s+)?JOIN\s+([`"\w$.]+)(?:\s+(?:AS\s+)?([`"\w$]+))?\s+ON\s+([\s\S]*?)(?=\s+(?:(?:(?:INNER|LEFT|RIGHT|FULL)(?:\s+OUTER)?\s+)?JOIN\b|(?:WHERE|GROUP\s+BY|ORDER\s+BY|HAVING|LIMIT|UNION)\b)|;|$)/gi;for(const _0x451b40 of _0x3f8c3e[_0x3a826a(0x14a)](_0x3a15ca)){const _0x2113e1=_0x451b40[_0x3a826a(0x13e)]??0x0,_0x8511ae=_0x451b40[0x0][_0x3a826a(0x15c)](/\bJOIN\b/i),_0x389aa2=_0x2113e1+Math[_0x3a826a(0x167)](0x0,_0x8511ae);if(!/^JOIN\b/i[_0x3a826a(0x176)](_0x8fc87d[_0x3a826a(0x15a)](_0x389aa2)))continue;_0x41c0fe[_0x3a826a(0x180)](_0x389aa2);const _0xf19b5=normalizeIdentifier(_0x451b40[0x1]||_0x3a826a(0x168)),_0x9b817e=normalizeIdentifier(_0x451b40[0x2]??''),_0xbe4d0b=normalizeIdentifier(_0x451b40[0x3]||_0x9b817e[_0x3a826a(0x165)]('.')['at'](-0x1)||_0x9b817e),_0x42077d=[],_0x2fc18b=_0x9b817e===_0x3a826a(0x159);let _0x3aff21=_0xf19b5===_0x3a826a(0x14f)||_0xf19b5===_0x3a826a(0x16f)||_0x2fc18b,_0x4239ae=_0x3aff21?_0x2fc18b?'Derived-table\x20JOIN\x20targets\x20are\x20not\x20supported.':_0xf19b5[_0x3a826a(0x158)]()+_0x3a826a(0x17f):undefined;const _0x55e050=stripOuterParentheses(_0x451b40[0x4]??'');hasTopLevelKeyword(_0x55e050,'OR')&&(_0x3aff21=!![],_0x4239ae??='OR-connected\x20JOIN\x20predicates\x20are\x20not\x20supported.');for(const _0x103a9e of splitTopLevelAnd(_0x55e050)){const _0x4af2d9=stripOuterParentheses(_0x103a9e);if(hasTopLevelKeyword(_0x4af2d9,'OR')){_0x3aff21=!![],_0x4239ae??=_0x3a826a(0x15b);continue;}const _0x2cb3f0=splitEquality(_0x4af2d9);if(!_0x2cb3f0){containsColumnReference(_0x103a9e,_0xbe4d0b)&&(_0x3aff21=!![]);continue;}const _0xe730a6=parseDirectColumnReference(_0x2cb3f0[0x0],_0xbe4d0b),_0x2c898a=parseDirectColumnReference(_0x2cb3f0[0x1],_0xbe4d0b),_0x4819cf=containsColumnReference(_0x2cb3f0[0x0],_0xbe4d0b),_0x37c5ad=containsColumnReference(_0x2cb3f0[0x1],_0xbe4d0b),_0x20213b=_0xe730a6&&!_0x37c5ad?_0xe730a6:_0x2c898a&&!_0x4819cf?_0x2c898a:null;if(_0x20213b&&!_0x42077d[_0x3a826a(0x17d)](_0x20213b))_0x42077d['push'](_0x20213b);else!_0x20213b&&containsColumnReference(_0x103a9e,_0xbe4d0b)&&(_0x3aff21=!![]);}_0x55e184[_0x3a826a(0x151)]({'table':_0x9b817e,'alias':_0xbe4d0b,'columns':_0x42077d,'unsupportedPredicate':_0x3aff21,'unsupportedReason':_0x4239ae,'position':_0x389aa2});}for(const _0x18f607 of _0x8fc87d['matchAll'](/\bJOIN\b/gi)){const _0x24b0d3=_0x18f607['index']??0x0;if(_0x41c0fe[_0x3a826a(0x150)](_0x24b0d3))continue;const _0x467b8a=/^\s+([`"\w$.]+)(?:\s+(?:AS\s+)?([`"\w$]+))?/[_0x3a826a(0x140)](_0x3f8c3e['slice'](_0x24b0d3+_0x18f607[0x0][_0x3a826a(0x15d)])),_0x4af96f=normalizeIdentifier(_0x467b8a?.[0x1]||_0x3a826a(0x155)),_0x697407=normalizeIdentifier(_0x467b8a?.[0x2]||''),_0x433264=isSqlClauseKeyword(_0x697407)?_0x4af96f[_0x3a826a(0x165)]('.')['at'](-0x1)||_0x4af96f:_0x697407||_0x4af96f[_0x3a826a(0x165)]('.')['at'](-0x1)||_0x4af96f;_0x55e184[_0x3a826a(0x151)]({'table':_0x4af96f,'alias':_0x433264,'columns':[],'unsupportedPredicate':!![],'unsupportedReason':_0x3a826a(0x154),'position':_0x24b0d3});}return _0x55e184[_0x3a826a(0x163)]((_0x5445f8,_0x3c5cf3)=>_0x5445f8['position']-_0x3c5cf3[_0x3a826a(0x143)]);}function stripSqlNoise(_0x29935d){const _0x568728=a207_0x2550,_0x5207be=Array[_0x568728(0x145)](_0x29935d),_0x51b1d4=(_0x3040f8,_0x1cefe7)=>{for(let _0xdd9ca2=_0x3040f8;_0xdd9ca2<_0x1cefe7;_0xdd9ca2+=0x1){_0x5207be[_0xdd9ca2]!=='\x0a'&&_0x5207be[_0xdd9ca2]!=='\x0d'&&(_0x5207be[_0xdd9ca2]='\x20');}};for(let _0x26cdab=0x0;_0x26cdab<_0x5207be[_0x568728(0x15d)];_0x26cdab+=0x1){const _0x274e3f=_0x5207be[_0x26cdab],_0x5ffb38=_0x5207be[_0x26cdab+0x1];if(_0x274e3f==='\x27'||_0x274e3f==='\x22'||_0x274e3f==='`'){const _0x2cd6a9=_0x274e3f,_0x57518c=_0x26cdab;_0x26cdab+=0x1;while(_0x26cdab<_0x5207be['length']){if(_0x5207be[_0x26cdab]==='\x5c'&&_0x26cdab+0x1<_0x5207be[_0x568728(0x15d)]){_0x26cdab+=0x2;continue;}if(_0x5207be[_0x26cdab]!==_0x2cd6a9){_0x26cdab+=0x1;continue;}if(_0x5207be[_0x26cdab+0x1]===_0x2cd6a9){_0x26cdab+=0x2;continue;}break;}if(_0x2cd6a9==='\x27')_0x51b1d4(_0x57518c,Math[_0x568728(0x13f)](_0x26cdab+0x1,_0x5207be[_0x568728(0x15d)]));continue;}if(_0x274e3f==='-'&&_0x5ffb38==='-'){const _0x265907=_0x26cdab;while(_0x26cdab<_0x5207be[_0x568728(0x15d)]&&_0x5207be[_0x26cdab]!=='\x0a')_0x26cdab+=0x1;_0x51b1d4(_0x265907,_0x26cdab);continue;}if(_0x274e3f==='/'&&_0x5ffb38==='*'){const _0x92820e=_0x26cdab;_0x26cdab+=0x2;while(_0x26cdab<_0x5207be[_0x568728(0x15d)]&&!(_0x5207be[_0x26cdab]==='*'&&_0x5207be[_0x26cdab+0x1]==='/')){_0x26cdab+=0x1;}_0x26cdab=Math[_0x568728(0x13f)](_0x26cdab+0x1,_0x5207be[_0x568728(0x15d)]-0x1),_0x51b1d4(_0x92820e,_0x26cdab+0x1);continue;}if(_0x274e3f==='#'&&_0x5ffb38!=='{'){const _0x81555a=_0x26cdab;while(_0x26cdab<_0x5207be['length']&&_0x5207be[_0x26cdab]!=='\x0a')_0x26cdab+=0x1;_0x51b1d4(_0x81555a,_0x26cdab);continue;}if((_0x274e3f==='#'||_0x274e3f==='$')&&_0x5ffb38==='{'){const _0x3d64ad=_0x26cdab;_0x26cdab+=0x2;while(_0x26cdab<_0x5207be[_0x568728(0x15d)]&&_0x5207be[_0x26cdab]!=='}')_0x26cdab+=0x1;_0x51b1d4(_0x3d64ad,Math['min'](_0x26cdab+0x1,_0x5207be[_0x568728(0x15d)]));}}return _0x5207be[_0x568728(0x164)]('');}function maskQuotedIdentifiers(_0x38817b){const _0x101c6f=a207_0x2550,_0x56135f=Array[_0x101c6f(0x145)](_0x38817b);for(let _0x371945=0x0;_0x371945<_0x56135f[_0x101c6f(0x15d)];_0x371945+=0x1){const _0x1283d1=_0x56135f[_0x371945];if(_0x1283d1!=='\x22'&&_0x1283d1!=='`')continue;_0x371945+=0x1;while(_0x371945<_0x56135f[_0x101c6f(0x15d)]){if(_0x56135f[_0x371945]===_0x1283d1){if(_0x56135f[_0x371945+0x1]===_0x1283d1){_0x56135f[_0x371945]='\x20',_0x56135f[_0x371945+0x1]='\x20',_0x371945+=0x2;continue;}break;}_0x56135f[_0x371945]='\x20',_0x371945+=0x1;}}return _0x56135f[_0x101c6f(0x164)]('');}function a207_0x2550(_0x7b4166,_0x186135){_0x7b4166=_0x7b4166-0x13e;const _0x485a4e=a207_0x485a();let _0x2550f7=_0x485a4e[_0x7b4166];return _0x2550f7;}function maskNestedQueries(_0xa418f6){const _0x486464=a207_0x2550,_0x6647ea=Array[_0x486464(0x145)](_0xa418f6);for(let _0x5edf91=0x0;_0x5edf91<_0x6647ea['length'];_0x5edf91+=0x1){if(_0x6647ea[_0x5edf91]!=='(')continue;const _0x22907a=_0xa418f6[_0x486464(0x15a)](_0x5edf91+0x1);if(!/^\s*(?:SELECT|WITH)\b/i[_0x486464(0x176)](_0x22907a))continue;let _0x14426c=0x1,_0x1ae4cb=_0x5edf91+0x1;for(;_0x1ae4cb<_0x6647ea['length']&&_0x14426c>0x0;_0x1ae4cb+=0x1){if(_0x6647ea[_0x1ae4cb]==='(')_0x14426c+=0x1;if(_0x6647ea[_0x1ae4cb]===')')_0x14426c-=0x1;}if(_0x14426c!==0x0)continue;for(let _0x2feb2d=_0x5edf91;_0x2feb2d<_0x1ae4cb;_0x2feb2d+=0x1){_0x6647ea[_0x2feb2d]='\x20';}const _0x4c4672='__sq__';for(let _0x2b1cd6=0x0;_0x2b1cd6<_0x4c4672[_0x486464(0x15d)]&&_0x5edf91+_0x2b1cd6<_0x1ae4cb;_0x2b1cd6+=0x1){_0x6647ea[_0x5edf91+_0x2b1cd6]=_0x4c4672[_0x2b1cd6];}_0x5edf91=_0x1ae4cb-0x1;}return _0x6647ea[_0x486464(0x164)]('');}function splitTopLevelAnd(_0xc5cc79){const _0x438c39=a207_0x2550,_0x5f2581=[];let _0x522f42=0x0,_0x5074a9=0x0;for(let _0x5125f5=0x0;_0x5125f5<_0xc5cc79[_0x438c39(0x15d)];_0x5125f5+=0x1){const _0x3ec185=_0xc5cc79[_0x5125f5];if(_0x3ec185==='(')_0x522f42+=0x1;if(_0x3ec185===')')_0x522f42=Math[_0x438c39(0x167)](0x0,_0x522f42-0x1);_0x522f42===0x0&&_0xc5cc79[_0x438c39(0x15a)](_0x5125f5)[_0x438c39(0x146)](/^AND\b/i)&&(_0x5125f5===0x0||/\s/[_0x438c39(0x176)](_0xc5cc79[_0x5125f5-0x1]??''))&&(_0x5f2581['push'](_0xc5cc79[_0x438c39(0x15a)](_0x5074a9,_0x5125f5)[_0x438c39(0x144)]()),_0x5125f5+=0x2,_0x5074a9=_0x5125f5+0x1);}const _0x72a00a=_0xc5cc79['slice'](_0x5074a9)[_0x438c39(0x144)]();if(_0x72a00a)_0x5f2581[_0x438c39(0x151)](_0x72a00a);return _0x5f2581;}function a207_0x485a(){const _0x115d9e=['table','\x20JOIN\x20direction\x20is\x20not\x20supported\x20by\x20static\x20index\x20auditing.','add','tableName','covered','inner','indexes','index','min','exec','map','INDEX_METADATA_UNAVAILABLE','position','trim','from','match','336123FzWSXy','matchedPrefix','(?:^|[^\x5cw$])','matchAll','2415322eGPyEb','5484zaPemN','where','warning','right','has','push','The\x20dataset\x20returned\x20no\x20distinguishable\x20index\x20metadata.','natural','Only\x20explicit\x20table\x20JOIN\x20clauses\x20with\x20an\x20ON\x20predicate\x20are\x20supported.','unknown','left','Not\x20every\x20JOIN\x20target\x20predicate\x20could\x20be\x20audited\x20safely.','toUpperCase','__sq__','slice','OR-connected\x20JOIN\x20predicates\x20are\x20not\x20supported.','search','length','JOIN_PREDICATE_UNSUPPORTED','unsupportedPredicate','500100xjbmkb','JOIN_INDEX_NOT_USABLE','55dbkIiP','sort','join','split','6RVLmzD','max','INNER','reduce','unavailable','filter','485ZSIhak','toLowerCase','2677200YNcvgL','full','\x5cs*\x5c.\x5cs*[\x5cw$]+','349RetrTf','using','alias','16ZGcTDE','replace','test','998IRFgyG','JOIN_INDEX_MISSING','some','Relevant\x20columns\x20do\x20not\x20form\x20a\x20complete\x20leftmost\x20index\x20prefix.','313875BBIZWQ','columns','includes'];a207_0x485a=function(){return _0x115d9e;};return a207_0x485a();}function hasTopLevelKeyword(_0x67a490,_0xcf961d){const _0x435688=a207_0x2550;let _0x150bf3=0x0;for(let _0x21da1d=0x0;_0x21da1d<_0x67a490[_0x435688(0x15d)];_0x21da1d+=0x1){const _0x1823fa=_0x67a490[_0x21da1d];if(_0x1823fa==='(')_0x150bf3+=0x1;if(_0x1823fa===')')_0x150bf3=Math[_0x435688(0x167)](0x0,_0x150bf3-0x1);if(_0x150bf3!==0x0)continue;const _0x144ffe=_0x67a490[_0x435688(0x15a)](_0x21da1d,_0x21da1d+_0xcf961d[_0x435688(0x15d)]),_0x5c45d9=_0x67a490[_0x21da1d-0x1]??'\x20',_0x2ccdee=_0x67a490[_0x21da1d+_0xcf961d[_0x435688(0x15d)]]??'\x20';if(_0x144ffe[_0x435688(0x158)]()===_0xcf961d[_0x435688(0x158)]()&&!/[\w$]/[_0x435688(0x176)](_0x5c45d9)&&!/[\w$]/[_0x435688(0x176)](_0x2ccdee))return!![];}return![];}function splitEquality(_0x4c3a65){const _0x2b1528=a207_0x2550,_0x202b3e=stripOuterParentheses(_0x4c3a65);let _0x29f3ff=0x0,_0x535563;for(let _0xbb7356=0x0;_0xbb7356<_0x202b3e[_0x2b1528(0x15d)];_0xbb7356+=0x1){const _0xdd6926=_0x202b3e[_0xbb7356];if(_0xdd6926==='(')_0x29f3ff+=0x1;if(_0xdd6926===')')_0x29f3ff=Math['max'](0x0,_0x29f3ff-0x1);const _0x15450b=_0x202b3e[_0xbb7356-0x1]??'',_0x24684e=_0x202b3e[_0xbb7356+0x1]??'';if(_0xdd6926==='='&&_0x29f3ff===0x0&&!/[!<>=:]/['test'](_0x15450b)&&_0x24684e!=='='){if(_0x535563!==undefined)return null;_0x535563=_0xbb7356;}}return _0x535563===undefined?null:[_0x202b3e[_0x2b1528(0x15a)](0x0,_0x535563)['trim'](),_0x202b3e[_0x2b1528(0x15a)](_0x535563+0x1)[_0x2b1528(0x144)]()];}function parseDirectColumnReference(_0x22122a,_0x64a8c){const _0x32fece=a207_0x2550,_0x34dd54=/^([`"]?[\w$]+[`"]?)\s*\.\s*([`"]?[\w$]+[`"]?)$/[_0x32fece(0x140)](stripOuterParentheses(_0x22122a));if(!_0x34dd54)return null;if(normalizeIdentifier(_0x34dd54[0x1]??'')!==normalizeIdentifier(_0x64a8c))return null;return normalizeIdentifier(_0x34dd54[0x2]??'');}function containsColumnReference(_0x4f3024,_0x2b1e0a){const _0x2885a2=a207_0x2550,_0x462b89=_0x4f3024[_0x2885a2(0x175)](/[`"]/g,''),_0x34009e=_0x2b1e0a[_0x2885a2(0x175)](/[.*+?^${}()|[\]\\]/g,'\x5c$&');return new RegExp(_0x2885a2(0x149)+_0x34009e+_0x2885a2(0x170),'i')['test'](_0x462b89);}function findEqualityPrefix(_0x2f9b5d,_0x567530){const _0x4cf4bb=a207_0x2550,_0x509136=new Set(_0x567530[_0x4cf4bb(0x141)](normalizeIdentifier)),_0x32da74=[];for(const _0x355b5d of _0x2f9b5d){if(!_0x509136[_0x4cf4bb(0x150)](normalizeIdentifier(_0x355b5d)))break;_0x32da74[_0x4cf4bb(0x151)](_0x355b5d);}return _0x32da74;}function resolveTableMetadata(_0x23bfd9,_0x5c093e){const _0x5227a9=a207_0x2550,_0x36b8f9=normalizeIdentifier(_0x5c093e),_0x12f85e=_0x23bfd9[_0x5227a9(0x16b)](_0xc65647=>normalizeIdentifier(_0xc65647[_0x5227a9(0x181)])===_0x36b8f9);if(_0x12f85e[_0x5227a9(0x15d)]===0x1)return _0x12f85e[0x0];const _0x3b8ed7=_0x36b8f9[_0x5227a9(0x17d)]('.'),_0x6674f3=_0x36b8f9[_0x5227a9(0x165)]('.')['at'](-0x1),_0x3781bb=_0x23bfd9[_0x5227a9(0x16b)](_0x256fcf=>{const _0x2ed652=_0x5227a9,_0x3975e7=normalizeIdentifier(_0x256fcf[_0x2ed652(0x181)]);if(_0x3b8ed7&&_0x3975e7[_0x2ed652(0x17d)]('.'))return![];return _0x3975e7[_0x2ed652(0x165)]('.')['at'](-0x1)===_0x6674f3;});return _0x3781bb[_0x5227a9(0x15d)]===0x1?_0x3781bb[0x0]:undefined;}function columnNamesMatch(_0x3d712c,_0x4af2fc){return normalizeIdentifier(_0x3d712c)===normalizeIdentifier(_0x4af2fc);}function normalizeIdentifier(_0x1f73ac){const _0xfc83f2=a207_0x2550;return _0x1f73ac[_0xfc83f2(0x175)](/[`"]/g,'')[_0xfc83f2(0x144)]()[_0xfc83f2(0x16d)]();}function isSqlClauseKeyword(_0x430c4e){const _0x41a2d4=a207_0x2550;return new Set(['on',_0x41a2d4(0x172),_0x41a2d4(0x14d),'join',_0x41a2d4(0x183),_0x41a2d4(0x156),_0x41a2d4(0x14f),_0x41a2d4(0x16f),'cross',_0x41a2d4(0x153)])[_0x41a2d4(0x150)](_0x430c4e);}function stripOuterParentheses(_0x2655f1){const _0x264d30=a207_0x2550;let _0x2ad95d=_0x2655f1[_0x264d30(0x144)]();while(_0x2ad95d['startsWith']('(')&&_0x2ad95d['endsWith'](')')){let _0x2478ab=0x0,_0x56bac1=!![];for(let _0xd5cf58=0x0;_0xd5cf58<_0x2ad95d[_0x264d30(0x15d)];_0xd5cf58+=0x1){if(_0x2ad95d[_0xd5cf58]==='(')_0x2478ab+=0x1;if(_0x2ad95d[_0xd5cf58]===')')_0x2478ab-=0x1;if(_0x2478ab===0x0&&_0xd5cf58<_0x2ad95d[_0x264d30(0x15d)]-0x1){_0x56bac1=![];break;}}if(!_0x56bac1||_0x2478ab!==0x0)break;_0x2ad95d=_0x2ad95d[_0x264d30(0x15a)](0x1,-0x1)[_0x264d30(0x144)]();}return _0x2ad95d;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a208_0x118c5d=a208_0x1b2a;(function(_0x2c431a,_0xc78c58){const _0x2be942=a208_0x1b2a,_0x5a1896=_0x2c431a();while(!![]){try{const _0x33b478=-parseInt(_0x2be942(0xe3))/0x1+-parseInt(_0x2be942(0xea))/0x2+-parseInt(_0x2be942(0xeb))/0x3*(parseInt(_0x2be942(0xef))/0x4)+parseInt(_0x2be942(0xe2))/0x5+parseInt(_0x2be942(0xed))/0x6+parseInt(_0x2be942(0xee))/0x7*(parseInt(_0x2be942(0xe6))/0x8)+-parseInt(_0x2be942(0xe4))/0x9*(-parseInt(_0x2be942(0xec))/0xa);if(_0x33b478===_0xc78c58)break;else _0x5a1896['push'](_0x5a1896['shift']());}catch(_0xbf8388){_0x5a1896['push'](_0x5a1896['shift']());}}}(a208_0x3bac,0x19e2e));function a208_0x1b2a(_0x203fd6,_0x3e3007){_0x203fd6=_0x203fd6-0xe1;const _0x3baca6=a208_0x3bac();let _0x1b2a28=_0x3baca6[_0x203fd6];return _0x1b2a28;}import{resolve}from'node:path';function a208_0x3bac(){const _0x40c18f=['1077078oHNcWe','46445lDgkrg','4OvDcTF','.rabetbase','17980yGMqda','201309ahfjIj','3618738CHfBee','sql-trash','56NzAfjS','sql','sql.lock.json','/sql','228646ALfTwc','629922LdLdTW','10nvHGmU'];a208_0x3bac=function(){return _0x40c18f;};return a208_0x3bac();}import{findProjectRootDirectory}from'../../context.js';const DOT_DIR=a208_0x118c5d(0xe1),LOCK_FILE_NAME=a208_0x118c5d(0xe8),TRASH_DIR_NAME=a208_0x118c5d(0xe5);export function loadSqlProjectConfig(_0x30f42d,_0x2b1edc){const _0x2ca702=a208_0x118c5d,_0x3581ec=resolve(_0x2b1edc??findProjectRootDirectory()),_0x274e6f=DOT_DIR+_0x2ca702(0xe9),_0x386dc1=_0x274e6f+'/'+_0x30f42d;return{'projectRoot':_0x3581ec,'appCode':_0x30f42d,'sqlWorkspaceRoot':_0x274e6f,'sqlRoot':_0x386dc1,'sqlRootDir':resolve(_0x3581ec,DOT_DIR,_0x2ca702(0xe7),_0x30f42d),'lockFilePath':resolve(_0x3581ec,DOT_DIR,LOCK_FILE_NAME),'trashDir':resolve(_0x3581ec,DOT_DIR,TRASH_DIR_NAME)};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2af970,_0x20debc){const _0x542c0e=a209_0x443c,_0xfe11f2=_0x2af970();while(!![]){try{const _0x4912e8=-parseInt(_0x542c0e(0xf9))/0x1+-parseInt(_0x542c0e(0x105))/0x2*(parseInt(_0x542c0e(0x104))/0x3)+parseInt(_0x542c0e(0xfc))/0x4*(parseInt(_0x542c0e(0xf6))/0x5)+parseInt(_0x542c0e(0xef))/0x6*(parseInt(_0x542c0e(0xea))/0x7)+-parseInt(_0x542c0e(0xec))/0x8+-parseInt(_0x542c0e(0xf5))/0x9*(-parseInt(_0x542c0e(0x101))/0xa)+parseInt(_0x542c0e(0xed))/0xb*(-parseInt(_0x542c0e(0xf7))/0xc);if(_0x4912e8===_0x20debc)break;else _0xfe11f2['push'](_0xfe11f2['shift']());}catch(_0x951e36){_0xfe11f2['push'](_0xfe11f2['shift']());}}}(a209_0x29c9,0x63b95));function a209_0x443c(_0x12bca4,_0x4239f5){_0x12bca4=_0x12bca4-0xea;const _0x29c905=a209_0x29c9();let _0x443c3f=_0x29c905[_0x12bca4];return _0x443c3f;}import{readdir,stat}from'node:fs/promises';import{extname,join,relative}from'node:path';import{buildDefaultSqlFileName,buildSqlRelativePath}from'./utils.js';function extensionToMode(_0x579939){const _0x13d7d8=a209_0x443c;if(_0x579939==='.sql')return _0x13d7d8(0xf0);if(_0x579939==='.xml')return'mybatisXml';return undefined;}async function scanSqlFilesRecursively(_0x2f9f81,_0x45bcf){const _0x3842e7=a209_0x443c,_0x1ed572=[];try{const _0xee8e4a=await readdir(_0x2f9f81,{'withFileTypes':!![]});for(const _0x520ead of _0xee8e4a){const _0x4577b5=join(_0x2f9f81,_0x520ead['name']);if(_0x520ead['isDirectory']()){_0x1ed572[_0x3842e7(0xfa)](...await scanSqlFilesRecursively(_0x4577b5,_0x45bcf));continue;}if(!_0x520ead[_0x3842e7(0xf8)]())continue;const _0x35c864=extname(_0x520ead['name'])[_0x3842e7(0x100)](),_0x412492=extensionToMode(_0x35c864);if(!_0x412492)continue;const _0x3af49d=relative(_0x45bcf,_0x4577b5)['replace'](/\\/g,'/'),_0x1e3fb0=_0x3af49d[_0x3842e7(0xfe)]('/')['filter'](Boolean),_0x48b398=parseSqlPath(_0x1e3fb0,_0x520ead['name'],_0x35c864);if(!_0x48b398)continue;_0x1ed572[_0x3842e7(0xfa)]({'sqlCode':_0x48b398[_0x3842e7(0xf4)],'sqlName':_0x48b398[_0x3842e7(0x102)],'dbDirectory':_0x1e3fb0[0x0],'filePath':_0x4577b5,'relativePath':_0x3af49d,'lockKey':_0x48b398[_0x3842e7(0xf4)],'mode':_0x412492});}}catch(_0x29a3c5){if(_0x29a3c5[_0x3842e7(0x106)]!==_0x3842e7(0x108))throw _0x29a3c5;}return _0x1ed572;}export async function scanLocalSqlQueries(_0x565ef0){const _0x5e40bd=a209_0x443c;return scanSqlFilesRecursively(_0x565ef0[_0x5e40bd(0x103)],_0x565ef0[_0x5e40bd(0x103)]);}export function resolveLocalSqlFilePath(_0x22bf54,_0x2ad922,_0x24829b){const _0x1fb749=a209_0x443c,_0x562286=_0x24829b?.[_0x1fb749(0xf2)]||(_0x24829b?.[_0x1fb749(0x102)]||_0x24829b?.['dbName']?buildSqlRelativePath(_0x2ad922,_0x24829b?.[_0x1fb749(0x102)],_0x24829b?.[_0x1fb749(0xff)],_0x24829b?.[_0x1fb749(0xfd)]||_0x1fb749(0xf0),_0x24829b?.[_0x1fb749(0xfb)]):buildDefaultSqlFileName(_0x2ad922,_0x24829b?.[_0x1fb749(0xfd)]||'sql'));return join(_0x22bf54['sqlRootDir'],_0x562286);}export async function directoryExists(_0x22d76a){const _0x175299=a209_0x443c;try{const _0x1844a4=await stat(_0x22d76a);return _0x1844a4[_0x175299(0xeb)]();}catch{return![];}}function parseSqlPath(_0x5263a7,_0x3a5fa1,_0x1914a6){const _0xfd7a74=a209_0x443c,_0x51523c=_0x3a5fa1[_0xfd7a74(0xf3)](0x0,-_0x1914a6[_0xfd7a74(0xf1)]);if(_0x5263a7['length']<0x2)return null;const _0x5143f3=_0x51523c[_0xfd7a74(0x107)]('_');if(_0x5143f3<=0x0||_0x5143f3>=_0x51523c['length']-0x1)return null;const _0x333b49=_0x51523c[_0xfd7a74(0xf3)](0x0,_0x5143f3);if(!isLikelySqlCode(_0x333b49))return null;return{'sqlCode':_0x333b49,'sqlName':_0x51523c[_0xfd7a74(0xf3)](_0x5143f3+0x1)};}function isLikelySqlCode(_0x1038f1){const _0x388b6a=a209_0x443c;return/^[A-Za-z0-9-]+-[A-Za-z0-9-]+$/[_0x388b6a(0xee)](_0x1038f1);}function a209_0x29c9(){const _0x198961=['3879528gXoHdp','419287KqzRff','test','174IosbPf','sql','length','path','slice','sqlCode','4921335rBTuiw','3763615VfrFkJ','108qLQmDi','isFile','484594HBOomw','push','dbId','4fPjNzr','mode','split','dbName','toLowerCase','10ylKmPz','sqlName','sqlRootDir','98151wzoZKf','10OfvdLo','code','indexOf','ENOENT','141232MOpKBj','isDirectory'];a209_0x29c9=function(){return _0x198961;};return a209_0x29c9();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x7123ad,_0x1d643c){const _0x1e9fc1=a210_0x2ab4,_0xc206ca=_0x7123ad();while(!![]){try{const _0x280283=parseInt(_0x1e9fc1(0xac))/0x1+-parseInt(_0x1e9fc1(0xa9))/0x2+-parseInt(_0x1e9fc1(0xa3))/0x3*(-parseInt(_0x1e9fc1(0xab))/0x4)+parseInt(_0x1e9fc1(0xa8))/0x5+parseInt(_0x1e9fc1(0xa6))/0x6*(-parseInt(_0x1e9fc1(0xad))/0x7)+parseInt(_0x1e9fc1(0xa5))/0x8+-parseInt(_0x1e9fc1(0xaa))/0x9*(-parseInt(_0x1e9fc1(0xa7))/0xa);if(_0x280283===_0x1d643c)break;else _0xc206ca['push'](_0xc206ca['shift']());}catch(_0xac8e8b){_0xc206ca['push'](_0xc206ca['shift']());}}}(a210_0x575d,0x7e46d));import{readFile}from'node:fs/promises';function a210_0x2ab4(_0x1ded89,_0x535255){_0x1ded89=_0x1ded89-0xa2;const _0x575d14=a210_0x575d();let _0x2ab41b=_0x575d14[_0x1ded89];return _0x2ab41b;}import a210_0x30c57e from'node:crypto';export function computeSqlContentHash(_0x12c453){const _0x5a9da6=a210_0x2ab4;return a210_0x30c57e['createHash'](_0x5a9da6(0xa4))['update'](_0x12c453)[_0x5a9da6(0xa2)]('hex');}function a210_0x575d(){const _0x210230=['43554TlnSDw','1080pqOLud','1657255GjzDNU','1336122cHilFl','39051XJLJeQ','8ZqdQWD','372478SDCrnB','854hDxsYr','digest','266877kyhaQa','md5','5763432SOyXoM'];a210_0x575d=function(){return _0x210230;};return a210_0x575d();}export async function computeSqlFileHash(_0x31b142){const _0x3f6847=await readFile(_0x31b142,'utf8');return computeSqlContentHash(_0x3f6847);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0xd72849,_0x288844){const _0xc714c5=a211_0x48c8,_0xabd76b=_0xd72849();while(!![]){try{const _0x49d670=parseInt(_0xc714c5(0x1e1))/0x1*(-parseInt(_0xc714c5(0x1db))/0x2)+parseInt(_0xc714c5(0x1e5))/0x3+parseInt(_0xc714c5(0x1e8))/0x4*(parseInt(_0xc714c5(0x1ee))/0x5)+parseInt(_0xc714c5(0x1e3))/0x6*(-parseInt(_0xc714c5(0x1dc))/0x7)+-parseInt(_0xc714c5(0x1e4))/0x8+-parseInt(_0xc714c5(0x1dd))/0x9*(-parseInt(_0xc714c5(0x1ec))/0xa)+-parseInt(_0xc714c5(0x1e7))/0xb*(-parseInt(_0xc714c5(0x1e0))/0xc);if(_0x49d670===_0x288844)break;else _0xabd76b['push'](_0xabd76b['shift']());}catch(_0x443270){_0xabd76b['push'](_0xabd76b['shift']());}}}(a211_0x3662,0x72df7));import{mkdir,readFile,writeFile}from'node:fs/promises';import{dirname}from'node:path';export function createEmptySqlLock(){return{'apps':{}};}export function ensureSqlLockScope(_0x2f840d,_0x193493,_0x23606a,_0x19cb63){const _0x5121ea=a211_0x48c8,_0x3ebe15=_0x2f840d??createEmptySqlLock();let _0x4acc3e=_0x3ebe15['apps'][_0x193493];if(!_0x4acc3e)return _0x4acc3e={'sqlRoot':_0x23606a,'lastSync':'','sqls':{}},_0x3ebe15['apps'][_0x193493]=_0x4acc3e,{'lockData':_0x3ebe15,'appLock':_0x4acc3e};if(!_0x4acc3e[_0x5121ea(0x1df)])_0x4acc3e[_0x5121ea(0x1df)]=_0x23606a;else{if(_0x4acc3e[_0x5121ea(0x1df)]!==_0x23606a)throw new Error(_0x19cb63+':\x20sqlRoot\x20mismatch\x20—\x20current\x20\x22'+_0x23606a+_0x5121ea(0x1da)+_0x4acc3e[_0x5121ea(0x1df)]+'\x22.\x20'+'Check\x20.rabetbase/sql.lock.json\x20or\x20operate\x20from\x20the\x20correct\x20project\x20directory.');}return!_0x4acc3e[_0x5121ea(0x1eb)]&&(_0x4acc3e[_0x5121ea(0x1eb)]={}),!_0x4acc3e[_0x5121ea(0x1e2)]&&(_0x4acc3e[_0x5121ea(0x1e2)]=''),{'lockData':_0x3ebe15,'appLock':_0x4acc3e};}function a211_0x3662(){const _0x448209=['sqls','2458580NuYtZm','ENOENT','5XKcFUw','\x22\x20vs\x20lock\x20\x22','26KxnoUK','170821iJWDbm','18VPQBGu','stringify','sqlRoot','7428wfCUmb','66782oelxrT','lastSync','156IrmCEK','1481208imtQtf','2599200vJylVF','utf8','4037RquTyj','2292100PNPcQx','Failed\x20to\x20read\x20SQL\x20lock\x20file:\x20','code'];a211_0x3662=function(){return _0x448209;};return a211_0x3662();}export async function readSqlLockFile(_0x177448){const _0x51349e=a211_0x48c8;try{const _0x43f5e7=await readFile(_0x177448,_0x51349e(0x1e6));return JSON['parse'](_0x43f5e7);}catch(_0x440a58){if(_0x440a58[_0x51349e(0x1ea)]===_0x51349e(0x1ed))return null;throw new Error(_0x51349e(0x1e9)+String(_0x440a58));}}function a211_0x48c8(_0x3d20e7,_0x92ee96){_0x3d20e7=_0x3d20e7-0x1da;const _0x3662a4=a211_0x3662();let _0x48c8b8=_0x3662a4[_0x3d20e7];return _0x48c8b8;}export async function writeSqlLockFile(_0x19c63d,_0x287fd5){const _0x91ee24=a211_0x48c8;await mkdir(dirname(_0x19c63d),{'recursive':!![]}),await writeFile(_0x19c63d,JSON[_0x91ee24(0x1de)](_0x287fd5,null,0x2),_0x91ee24(0x1e6));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x17c298,_0x192171){const _0x1e2741=a213_0x29ab,_0x5123bb=_0x17c298();while(!![]){try{const _0x33159e=-parseInt(_0x1e2741(0x1fd))/0x1+-parseInt(_0x1e2741(0x1ef))/0x2*(-parseInt(_0x1e2741(0x1f5))/0x3)+parseInt(_0x1e2741(0x1fc))/0x4*(parseInt(_0x1e2741(0x1f8))/0x5)+parseInt(_0x1e2741(0x1f3))/0x6*(parseInt(_0x1e2741(0x1ff))/0x7)+parseInt(_0x1e2741(0x202))/0x8*(-parseInt(_0x1e2741(0x1f2))/0x9)+-parseInt(_0x1e2741(0x1f6))/0xa*(-parseInt(_0x1e2741(0x1fe))/0xb)+parseInt(_0x1e2741(0x205))/0xc*(parseInt(_0x1e2741(0x203))/0xd);if(_0x33159e===_0x192171)break;else _0x5123bb['push'](_0x5123bb['shift']());}catch(_0xaab63f){_0x5123bb['push'](_0x5123bb['shift']());}}}(a213_0x939d,0xcf4e6));export function detectSqlMode(_0x14bf82){const _0x207ab1=a213_0x29ab,_0x40fded=_0x14bf82[_0x207ab1(0x201)]();if(/^<(select|insert|update|delete)\b/i[_0x207ab1(0x1fa)](_0x40fded))return'mybatisXml';return _0x207ab1(0x1f7);}function a213_0x939d(){const _0x519374=['541853XyxpNf','unknown-db','348LdVpvj','28642JwatyK','.sql','.xml','9JiSfJY','47802mOkFgr','trim','33wntUmD','3266330HweOOz','sql','3755OezDEk','unknown-sql','test','mybatisXml','7464onzyLn','1214798dRErBC','22uQlpNW','217SMVuXd','replace','trimStart','12831720apTPhT'];a213_0x939d=function(){return _0x519374;};return a213_0x939d();}export function getSqlFileExtension(_0x3c46c3){const _0x965229=a213_0x29ab;return _0x3c46c3===_0x965229(0x1fb)?_0x965229(0x1f1):_0x965229(0x1f0);}function a213_0x29ab(_0x45afa7,_0x402b0e){_0x45afa7=_0x45afa7-0x1ef;const _0x939dac=a213_0x939d();let _0x29ab34=_0x939dac[_0x45afa7];return _0x29ab34;}export function buildDefaultSqlFileName(_0x5c8d85,_0x199f69){return''+_0x5c8d85+getSqlFileExtension(_0x199f69);}export function sanitizeSqlPathSegment(_0x4441c3,_0x23c6b7){const _0x2dcb08=a213_0x29ab,_0x2ed57f=String(_0x4441c3??'')[_0x2dcb08(0x1f4)](),_0x50f796=_0x2ed57f['replace'](/[<>:"/\\|?*\u0000-\u001F]/g,'-')['replace'](/\s+/g,'-')[_0x2dcb08(0x200)](/-+/g,'-')[_0x2dcb08(0x200)](/^\.+/,'')[_0x2dcb08(0x200)](/\.+$/,'')['replace'](/^-+/,'')[_0x2dcb08(0x200)](/-+$/,'');return _0x50f796||_0x23c6b7;}export function buildDbDirectoryName(_0x353177,_0x34ac29){const _0x70253e=a213_0x29ab;return sanitizeSqlPathSegment(_0x353177,_0x34ac29!=null?'db-'+_0x34ac29:_0x70253e(0x204));}export function buildSqlRelativePath(_0x7f763b,_0x4252ea,_0x2f32e7,_0x2e1355,_0x20f9ee){const _0x1c9643=a213_0x29ab,_0x26d572=buildDbDirectoryName(_0x2f32e7,_0x20f9ee),_0x405789=sanitizeSqlPathSegment(_0x7f763b,_0x1c9643(0x1f9)),_0x3b4bcf=sanitizeSqlPathSegment(_0x4252ea,_0x405789);return _0x26d572+'/'+_0x405789+'_'+_0x3b4bcf+getSqlFileExtension(_0x2e1355);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a214_0x4638(_0x5e7868,_0x5f18cd){_0x5e7868=_0x5e7868-0x12b;const _0x471795=a214_0x4717();let _0x463825=_0x471795[_0x5e7868];return _0x463825;}(function(_0xab03da,_0x4fbafc){const _0x35ad7b=a214_0x4638,_0x3ef1dc=_0xab03da();while(!![]){try{const _0x319b43=-parseInt(_0x35ad7b(0x141))/0x1*(parseInt(_0x35ad7b(0x149))/0x2)+parseInt(_0x35ad7b(0x12f))/0x3+-parseInt(_0x35ad7b(0x13d))/0x4+-parseInt(_0x35ad7b(0x140))/0x5+-parseInt(_0x35ad7b(0x138))/0x6+parseInt(_0x35ad7b(0x14e))/0x7*(parseInt(_0x35ad7b(0x148))/0x8)+parseInt(_0x35ad7b(0x14f))/0x9;if(_0x319b43===_0x4fbafc)break;else _0x3ef1dc['push'](_0x3ef1dc['shift']());}catch(_0x3fba6d){_0x3ef1dc['push'](_0x3ef1dc['shift']());}}}(a214_0x4717,0xa85e2));export function detectSqlType(_0x243c10){const _0x384eb3=a214_0x4638;if(!_0x243c10?.['trim']())return{'type':_0x384eb3(0x136),'isSelectOnly':![],'isDangerous':![],'reason':'SQL\x20content\x20is\x20empty'};const _0x162d5e=_0x243c10[_0x384eb3(0x12e)](/#\{[^}]*\}/g,'?')[_0x384eb3(0x12e)](/\$\{[^}]*\}/g,'?')[_0x384eb3(0x12e)](/@[^(\s]+(\([^)]*\))?/g,'')[_0x384eb3(0x12e)](/\/\*[\s\S]*?\*\//g,'')[_0x384eb3(0x13c)](),_0x2672f8=_0x162d5e['split']('\x0a');let _0x56e211='';for(const _0xb36eef of _0x2672f8){const _0x2e82c6=_0xb36eef[_0x384eb3(0x13c)]();if(!_0x2e82c6||_0x2e82c6[_0x384eb3(0x130)]('--')||_0x2e82c6[_0x384eb3(0x130)]('/*'))continue;_0x56e211=_0x2e82c6;break;}const _0x37ca85=_0x56e211['toUpperCase']();if(_0x37ca85['startsWith'](_0x384eb3(0x145))||_0x37ca85[_0x384eb3(0x130)](_0x384eb3(0x13e))){const _0x4c40d6=/\b(INSERT|UPDATE|DELETE|DROP|ALTER|CREATE|TRUNCATE)\b/i['test'](_0x162d5e);return{'type':_0x384eb3(0x145),'isSelectOnly':!_0x4c40d6,'isDangerous':_0x4c40d6,'reason':_0x4c40d6?_0x384eb3(0x137):undefined};}if(_0x37ca85['startsWith'](_0x384eb3(0x146)))return{'type':'INSERT','isSelectOnly':![],'isDangerous':![]};if(_0x37ca85['startsWith'](_0x384eb3(0x132)))return{'type':_0x384eb3(0x132),'isSelectOnly':![],'isDangerous':![]};if(_0x37ca85[_0x384eb3(0x130)](_0x384eb3(0x14a)))return{'type':_0x384eb3(0x14a),'isSelectOnly':![],'isDangerous':!![],'reason':'DELETE\x20statements\x20are\x20blocked\x20from\x20auto-save'};if(/^(CREATE|ALTER|DROP|TRUNCATE)/i[_0x384eb3(0x12b)](_0x37ca85))return{'type':_0x384eb3(0x133),'isSelectOnly':![],'isDangerous':!![],'reason':_0x384eb3(0x144)};return{'type':_0x384eb3(0x136),'isSelectOnly':![],'isDangerous':![]};}function extractTables(_0x2b4f96){const _0x270d06=a214_0x4638,_0x2e09a0=_0x2b4f96[_0x270d06(0x12e)](/#\{[^}]*\}/g,'?')[_0x270d06(0x12e)](/\$\{[^}]*\}/g,'?')[_0x270d06(0x12e)](/'[^']*'/g,'\x27\x27')['replace'](/--.*$/gm,'')[_0x270d06(0x12e)](/\/\*[\s\S]*?\*\//g,''),_0x342125=[],_0x213d15=_0x2e09a0[_0x270d06(0x13b)](/FROM\s+([^\s,)(]+)/i);if(_0x213d15?.[0x1])_0x342125[_0x270d06(0x142)](_0x213d15[0x1][_0x270d06(0x12e)](/[`"]/g,''));for(const _0x53fa1f of _0x2e09a0['matchAll'](/(?:INNER|LEFT|RIGHT|FULL|CROSS)?\s*JOIN\s+([^\s,)(]+)/gi)){const _0x596c03=_0x53fa1f[0x1]?.[_0x270d06(0x12e)](/[`"]/g,'');if(_0x596c03&&!_0x342125[_0x270d06(0x134)](_0x596c03))_0x342125['push'](_0x596c03);}const _0x55e999=_0x2e09a0[_0x270d06(0x13b)](/INTO\s+([^\s(]+)/i);if(_0x55e999?.[0x1]){const _0x21ad0c=_0x55e999[0x1][_0x270d06(0x12e)](/[`"]/g,'');if(!_0x342125[_0x270d06(0x134)](_0x21ad0c))_0x342125[_0x270d06(0x142)](_0x21ad0c);}const _0x3cad34=_0x2e09a0[_0x270d06(0x13b)](/UPDATE\s+([^\s,)(]+)/i);if(_0x3cad34?.[0x1]){const _0x53c9a8=_0x3cad34[0x1]['replace'](/[`"]/g,'');if(!_0x342125[_0x270d06(0x134)](_0x53c9a8))_0x342125[_0x270d06(0x142)](_0x53c9a8);}return _0x342125;}function extractParameters(_0x298ea5){const _0x493879=a214_0x4638,_0x42aaf8=new Set();for(const _0x1c0553 of _0x298ea5[_0x493879(0x139)](/#\{(\w+)\}/g))if(_0x1c0553[0x1])_0x42aaf8['add'](_0x1c0553[0x1]);for(const _0x43501b of _0x298ea5[_0x493879(0x139)](/\$\{(\w+)\}/g))if(_0x43501b[0x1])_0x42aaf8[_0x493879(0x13f)](_0x43501b[0x1]);return Array[_0x493879(0x135)](_0x42aaf8);}function a214_0x4717(){const _0x3f65ac=['match','trim','377612ZwLNHN','WITH','add','1318510QNrBcy','345118rbxQal','push','\x20with\x20parameters:\x20','DDL\x20statements\x20are\x20blocked\x20from\x20auto-save','SELECT','INSERT','unknown\x20table(s)','1062768UBaIBz','2thpybk','DELETE','\x20query\x20targeting\x20','Unable\x20to\x20detect\x20SQL\x20type.\x20Please\x20check\x20the\x20SQL\x20content.','\x20statements\x20cannot\x20be\x20auto-saved.\x20Please\x20operate\x20manually\x20on\x20the\x20platform.','49DcizsY','4896999lPsbbL','join','test','type','isDangerous','replace','2170026JijgpN','startsWith','length','UPDATE','DDL','includes','from','UNKNOWN','SQL\x20contains\x20modification\x20statements\x20alongside\x20SELECT','4827108oCuyZJ','matchAll','reason'];a214_0x4717=function(){return _0x3f65ac;};return a214_0x4717();}export function validateSql(_0xcb0e0a){const _0x5acb28=a214_0x4638,_0x2fde96=detectSqlType(_0xcb0e0a),_0x548cb7=extractTables(_0xcb0e0a),_0x1e4810=extractParameters(_0xcb0e0a);if(_0x2fde96[_0x5acb28(0x12d)])return{'valid':![],'sqlType':_0x2fde96,'tables':_0x548cb7,'parameters':_0x1e4810,'message':_0x2fde96[_0x5acb28(0x13a)]||_0x2fde96[_0x5acb28(0x12c)]+_0x5acb28(0x14d)};if(_0x2fde96[_0x5acb28(0x12c)]===_0x5acb28(0x136))return{'valid':![],'sqlType':_0x2fde96,'tables':_0x548cb7,'parameters':_0x1e4810,'message':_0x5acb28(0x14c)};return{'valid':!![],'sqlType':_0x2fde96,'tables':_0x548cb7,'parameters':_0x1e4810,'message':_0x2fde96[_0x5acb28(0x12c)]+_0x5acb28(0x14b)+(_0x548cb7['length']?_0x548cb7[_0x5acb28(0x150)](',\x20'):_0x5acb28(0x147))+(_0x1e4810[_0x5acb28(0x131)]?_0x5acb28(0x143)+_0x1e4810[_0x5acb28(0x150)](',\x20'):'')};}
|
package/lib/errors.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a215_0x50c00b=a215_0xec60;function a215_0xec60(_0x1ef78a,_0x428e21){_0x1ef78a=_0x1ef78a-0xb8;const _0x3c11ad=a215_0x3c11();let _0xec60d7=_0x3c11ad[_0x1ef78a];return _0xec60d7;}function a215_0x3c11(){const _0x45c38c=['732956kSSAEN','1305368LjUlTM','2yLwPdQ','6jqWOiH','165539ObUKQG','4347680KCKeLf','1324960iZheIC','\x0a\x20\x20\x20\x20\x20\x20\x20','22056uYFuHb','4213opOojw','Set\x20appcode\x20via\x20`','\x20init\x20--appcode\x20<code>\x20--global`\x20registers\x20globally\x20so\x20you\x20can\x20use\x20it\x20from\x20anywhere.','36lYkDIZ','3mGxsxC','\x20init\x20--appcode\x20<code>`\x20or\x20pass\x20--appcode.','\x20auth`\x20to\x20login\x20first.','339255UVhmoZ','Run\x20this\x20command\x20inside\x20a\x20project\x20with\x20.rabetbase.json\x20file.','Tip:\x20`'];a215_0x3c11=function(){return _0x45c38c;};return a215_0x3c11();}(function(_0x272a92,_0x5e1aab){const _0x31d577=a215_0xec60,_0x2caffa=_0x272a92();while(!![]){try{const _0x28017a=parseInt(_0x31d577(0xc1))/0x1*(parseInt(_0x31d577(0xbf))/0x2)+-parseInt(_0x31d577(0xca))/0x3*(parseInt(_0x31d577(0xbd))/0x4)+parseInt(_0x31d577(0xba))/0x5*(parseInt(_0x31d577(0xc0))/0x6)+-parseInt(_0x31d577(0xc3))/0x7+parseInt(_0x31d577(0xbe))/0x8*(-parseInt(_0x31d577(0xc9))/0x9)+parseInt(_0x31d577(0xc2))/0xa+-parseInt(_0x31d577(0xc6))/0xb*(-parseInt(_0x31d577(0xc5))/0xc);if(_0x28017a===_0x5e1aab)break;else _0x2caffa['push'](_0x2caffa['shift']());}catch(_0x2bead5){_0x2caffa['push'](_0x2caffa['shift']());}}}(a215_0x3c11,0x54b1d));import{CliError,createCliErrors}from'@lovrabet/cli-framework';import{CLI_BIN_NAME}from'./constant/cli.js';export{CliError};export const CliErrors=createCliErrors({'cliBinName':CLI_BIN_NAME,'authRequiredHint':'Run\x20`'+CLI_BIN_NAME+a215_0x50c00b(0xb9),'configMissingHint':[a215_0x50c00b(0xc7)+CLI_BIN_NAME+a215_0x50c00b(0xb8),a215_0x50c00b(0xbc)+CLI_BIN_NAME+a215_0x50c00b(0xc8)]['join'](a215_0x50c00b(0xc4)),'notInProjectHint':a215_0x50c00b(0xbb)});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x164de0,_0x32a63e){const _0x4e84bc=a216_0x4cc2,_0x36b2e2=_0x164de0();while(!![]){try{const _0x486117=parseInt(_0x4e84bc(0x111))/0x1+parseInt(_0x4e84bc(0x112))/0x2+-parseInt(_0x4e84bc(0x116))/0x3+parseInt(_0x4e84bc(0x10c))/0x4*(parseInt(_0x4e84bc(0x10d))/0x5)+-parseInt(_0x4e84bc(0x10f))/0x6+parseInt(_0x4e84bc(0x115))/0x7+-parseInt(_0x4e84bc(0x110))/0x8*(-parseInt(_0x4e84bc(0x113))/0x9);if(_0x486117===_0x32a63e)break;else _0x36b2e2['push'](_0x36b2e2['shift']());}catch(_0x596996){_0x36b2e2['push'](_0x36b2e2['shift']());}}}(a216_0x4c63,0xe7611));import{DEFAULT_COMMAND_OUTPUT_FORMAT}from'../constant/defaults.js';function a216_0x4c63(){const _0x1d4cd2=['179558piBtXR','301856Gkvvbc','447345pfsnDX','map','4033337HLZlCt','2143377YMPmym','name','504692mIHhHh','10ZTIAOu','yes','5629680kJTTOj','232xjgIiW'];a216_0x4c63=function(){return _0x1d4cd2;};return a216_0x4c63();}import{buildAllFlags as a216_0x2eb775}from'@lovrabet/cli-framework';function a216_0x4cc2(_0x42ed2f,_0x16672a){_0x42ed2f=_0x42ed2f-0x10c;const _0x4c6338=a216_0x4c63();let _0x4cc2ca=_0x4c6338[_0x42ed2f];return _0x4cc2ca;}import{EXPLICIT_YES_FLAG_DESCRIPTION,requiresExplicitYes}from'../framework/explicit-yes.js';export function buildAllFlags(_0x71f99d){const _0xbe01df=a216_0x4cc2,_0x6f3b86=a216_0x2eb775(_0x71f99d,{'defaultOutputFormat':DEFAULT_COMMAND_OUTPUT_FORMAT});if(!requiresExplicitYes(_0x71f99d))return _0x6f3b86;return _0x6f3b86[_0xbe01df(0x114)](_0x13944c=>_0x13944c[_0xbe01df(0x117)]===_0xbe01df(0x10e)?{..._0x13944c,'description':EXPLICIT_YES_FLAG_DESCRIPTION}:_0x13944c);}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(function(_0x125d23,_0x2cb9bb){var _0x5a30a6=a217_0x1de5,_0x4cfe4a=_0x125d23();while(!![]){try{var _0x5bfdf8=parseInt(_0x5a30a6(0xd5))/0x1+-parseInt(_0x5a30a6(0xd2))/0x2+parseInt(_0x5a30a6(0xcf))/0x3+parseInt(_0x5a30a6(0xd9))/0x4*(parseInt(_0x5a30a6(0xd1))/0x5)+-parseInt(_0x5a30a6(0xd6))/0x6+-parseInt(_0x5a30a6(0xd8))/0x7+parseInt(_0x5a30a6(0xd4))/0x8;if(_0x5bfdf8===_0x2cb9bb)break;else _0x4cfe4a['push'](_0x4cfe4a['shift']());}catch(_0x1cc446){_0x4cfe4a['push'](_0x4cfe4a['shift']());}}}(a217_0x3941,0xed540));import{resolveOutputConfig}from'@lovrabet/cli-framework';export function usesStructuredErrorOutput(_0x556a92){var _0x34bbe6=a217_0x1de5;return _0x556a92?.[_0x34bbe6(0xd7)]===!![];}function a217_0x3941(){var _0x34e09c=['6694176RREvEl','structuredErrors','4466336KMiLzp','1761092TMjRHQ','compress','format','flags','624540ogaSOQ','defaultFormat','20FzAAiV','597552aWeGeg','def','6654288SrBdUg','223558MIuJXN'];a217_0x3941=function(){return _0x34e09c;};return a217_0x3941();}function a217_0x1de5(_0x2eb50a,_0x336cdc){_0x2eb50a=_0x2eb50a-0xcc;var _0x3941de=a217_0x3941();var _0x1de555=_0x3941de[_0x2eb50a];return _0x1de555;}export function resolveErrorOutputFormat(_0x288dd4){var _0x3b4372=a217_0x1de5;if(!_0x288dd4[_0x3b4372(0xd3)])return _0x288dd4[_0x3b4372(0xd0)]??_0x3b4372(0xcc);return resolveOutputConfig({'flags':_0x288dd4[_0x3b4372(0xce)]??{},'def':_0x288dd4['def'],'configDefault':_0x288dd4[_0x3b4372(0xd0)]})[_0x3b4372(0xcd)];}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function a218_0x3e31(){const _0x3b561f=['24176sokJBs','6656804CHizMu','command','menu\x20delete','1edLsGz','7518660IPfYwn','215qMxDHg','7276356arqZqh','menu\x20regroup-start','2246912AqvRPd','Required\x20for\x20execution\x20after\x20reviewing\x20the\x20--dry-run\x20plan','service','1231106XZmiDQ','4891050FWCMhn','menu\x20group-update','menu\x20group-create'];a218_0x3e31=function(){return _0x3b561f;};return a218_0x3e31();}function a218_0x2c02(_0x5146cd,_0x31cdbf){_0x5146cd=_0x5146cd-0xcd;const _0x3e3146=a218_0x3e31();let _0x2c0218=_0x3e3146[_0x5146cd];return _0x2c0218;}const a218_0x4b8a8b=a218_0x2c02;(function(_0x23b37a,_0x565a7d){const _0x41a7ea=a218_0x2c02,_0xeae631=_0x23b37a();while(!![]){try{const _0x5e7b3d=-parseInt(_0x41a7ea(0xd3))/0x1*(-parseInt(_0x41a7ea(0xdb))/0x2)+-parseInt(_0x41a7ea(0xdc))/0x3+parseInt(_0x41a7ea(0xcf))/0x4*(parseInt(_0x41a7ea(0xd5))/0x5)+parseInt(_0x41a7ea(0xd4))/0x6+parseInt(_0x41a7ea(0xd0))/0x7+parseInt(_0x41a7ea(0xd8))/0x8+-parseInt(_0x41a7ea(0xd6))/0x9;if(_0x5e7b3d===_0x565a7d)break;else _0xeae631['push'](_0xeae631['shift']());}catch(_0x1e041c){_0xeae631['push'](_0xeae631['shift']());}}}(a218_0x3e31,0xe0fd5));const EXPLICIT_YES_COMMANDS=new Set([a218_0x4b8a8b(0xd2),a218_0x4b8a8b(0xce),a218_0x4b8a8b(0xcd),a218_0x4b8a8b(0xd7)]);export const EXPLICIT_YES_FLAG_DESCRIPTION=a218_0x4b8a8b(0xd9);export function requiresExplicitYes(_0x583a5c){const _0x3c3aea=a218_0x4b8a8b;return EXPLICIT_YES_COMMANDS['has'](_0x583a5c[_0x3c3aea(0xda)]+'\x20'+_0x583a5c[_0x3c3aea(0xd1)]);}
|
package/lib/framework/flags.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x2cea30,_0x5c73ab){const _0x572ab3=a219_0x7208,_0x349413=_0x2cea30();while(!![]){try{const _0x517a72=parseInt(_0x572ab3(0x181))/0x1*(-parseInt(_0x572ab3(0x17d))/0x2)+parseInt(_0x572ab3(0x182))/0x3*(-parseInt(_0x572ab3(0x17a))/0x4)+-parseInt(_0x572ab3(0x17c))/0x5*(parseInt(_0x572ab3(0x180))/0x6)+parseInt(_0x572ab3(0x17e))/0x7+parseInt(_0x572ab3(0x17b))/0x8+-parseInt(_0x572ab3(0x17f))/0x9*(-parseInt(_0x572ab3(0x183))/0xa)+parseInt(_0x572ab3(0x184))/0xb;if(_0x517a72===_0x5c73ab)break;else _0x349413['push'](_0x349413['shift']());}catch(_0x3389db){_0x349413['push'](_0x349413['shift']());}}}(a219_0x5e10,0x97065));function a219_0x5e10(){const _0x4a11c0=['94004ftbhzl','5202834NiOEuD','47907MykvIM','1008TfSZPz','4fHdVhg','75aWawfB','1660OtheNT','6752614glCdZO','105620FLXWhG','2362368pWRtgk','31825GAkHvP'];a219_0x5e10=function(){return _0x4a11c0;};return a219_0x5e10();}import{createFlagHelpers}from'@lovrabet/cli-framework';import{CliErrors}from'../errors.js';const helpers=createFlagHelpers(CliErrors);export const parseFlags=helpers['parseFlags'];function a219_0x7208(_0x56e6da,_0x4ac626){_0x56e6da=_0x56e6da-0x17a;const _0x5e10c0=a219_0x5e10();let _0x7208f4=_0x5e10c0[_0x56e6da];return _0x7208f4;}export const validateFlags=helpers['validateFlags'];
|
package/lib/framework/help.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a220_0x5cb868=a220_0x1923;(function(_0x3d40fb,_0x51f8a8){const _0x15577e=a220_0x1923,_0x5c3372=_0x3d40fb();while(!![]){try{const _0x1e080a=parseInt(_0x15577e(0x190))/0x1*(parseInt(_0x15577e(0x196))/0x2)+-parseInt(_0x15577e(0x18d))/0x3*(-parseInt(_0x15577e(0x195))/0x4)+parseInt(_0x15577e(0x19a))/0x5+-parseInt(_0x15577e(0x19b))/0x6+parseInt(_0x15577e(0x198))/0x7+parseInt(_0x15577e(0x197))/0x8*(-parseInt(_0x15577e(0x193))/0x9)+parseInt(_0x15577e(0x199))/0xa*(parseInt(_0x15577e(0x192))/0xb);if(_0x1e080a===_0x51f8a8)break;else _0x5c3372['push'](_0x5c3372['shift']());}catch(_0x4d18b8){_0x5c3372['push'](_0x5c3372['shift']());}}}(a220_0x1c95,0x527b9));import{createHelpGenerators}from'@lovrabet/cli-framework';import{buildAllFlags}from'../framework/build-all-flags.js';function a220_0x1923(_0x422f18,_0x5662e2){_0x422f18=_0x422f18-0x18c;const _0x1c95b4=a220_0x1c95();let _0x1923df=_0x1c95b4[_0x422f18];return _0x1923df;}import{serviceRegistry,serviceGroups,getServiceEntry}from'../commands/registry.js';import{CLI_BIN_NAME,CLI_DISPLAY_NAME,GLOBAL_FLAGS}from'../constant/cli.js';import{requiresExplicitYes}from'../framework/explicit-yes.js';const generators=createHelpGenerators({'cliBinName':CLI_BIN_NAME,'cliDisplayName':CLI_DISPLAY_NAME,'globalFlags':GLOBAL_FLAGS,'serviceRegistry':serviceRegistry,'getServiceEntry':getServiceEntry,'getServiceDefinitions':_0x30df05=>serviceGroups['get'](_0x30df05),'buildAllFlags':buildAllFlags,'appPrerequisiteText':a220_0x5cb868(0x19d)+CLI_BIN_NAME+a220_0x5cb868(0x18f),'serviceUsageSuffix':a220_0x5cb868(0x194)});export function generateCommandHelp(_0x19be65){const _0x5e4b09=a220_0x5cb868,_0x332976=generators[_0x5e4b09(0x18e)](_0x19be65);if(!requiresExplicitYes(_0x19be65))return _0x332976;return _0x332976['replace'](_0x5e4b09(0x18c),_0x5e4b09(0x191));}export const generateServiceHelp=generators[a220_0x5cb868(0x19e)];function a220_0x1c95(){const _0x546e4b=['generateCommandHelp','\x20workspace\x20init`\x20or\x20--appcode).','1GJrmok','Requires\x20explicit\x20--yes\x20for\x20execution;\x20use\x20--dry-run\x20to\x20preview.','55nqjYqa','484119YMhlen','\x20[args]\x20[flags]','143348LOXXMH','370910Ycfnwq','16IEwCzh','3262413BDjpKV','563190mQmLSW','18855dGvjzG','3593760XqGgUi','generateFullHelp','Requires\x20appcode\x20(set\x20via\x20`','generateServiceHelp','Requires\x20--yes\x20to\x20confirm,\x20or\x20interactive\x20prompt.','9dGxGdV'];a220_0x1c95=function(){return _0x546e4b;};return a220_0x1c95();}export const generateFullHelp=generators[a220_0x5cb868(0x19c)];
|
package/lib/framework/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a221_0x5643(_0x11beac,_0x66eb32){_0x11beac=_0x11beac-0x183;var _0x32ffb5=a221_0x32ff();var _0x564322=_0x32ffb5[_0x11beac];return _0x564322;}(function(_0x750212,_0x5ac7c3){var _0x4d8084=a221_0x5643,_0x495b9b=_0x750212();while(!![]){try{var _0x37d0eb=parseInt(_0x4d8084(0x185))/0x1*(parseInt(_0x4d8084(0x18b))/0x2)+-parseInt(_0x4d8084(0x18a))/0x3+-parseInt(_0x4d8084(0x183))/0x4+-parseInt(_0x4d8084(0x188))/0x5+parseInt(_0x4d8084(0x186))/0x6*(parseInt(_0x4d8084(0x184))/0x7)+-parseInt(_0x4d8084(0x187))/0x8+parseInt(_0x4d8084(0x189))/0x9;if(_0x37d0eb===_0x5ac7c3)break;else _0x495b9b['push'](_0x495b9b['shift']());}catch(_0x4a0514){_0x495b9b['push'](_0x495b9b['shift']());}}}(a221_0x32ff,0x3c7ba));export{runCommand}from'../framework/runner.js';export{parseFlags,validateFlags}from'../framework/flags.js';export{formatOutput}from'../framework/output.js';export{generateCommandHelp,generateServiceHelp,generateFullHelp}from'../framework/help.js';export{extractList,extractPaging}from'../framework/response.js';function a221_0x32ff(){var _0x2fbd48=['3HMwTvu','1406130ydnfMm','3023792FdyGtt','2460660LyJYmH','9929538CltaTO','533652cUENVd','179932Vauvpd','1247228QduFuo','7TXrxHG'];a221_0x32ff=function(){return _0x2fbd48;};return a221_0x32ff();}export{riskLevelOrder}from'../framework/types.js';
|
package/lib/framework/output.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x400a78,_0x599b9f){const _0x4e6a6a=a222_0x166e,_0x25f685=_0x400a78();while(!![]){try{const _0x180bf2=-parseInt(_0x4e6a6a(0xad))/0x1+-parseInt(_0x4e6a6a(0xaa))/0x2*(-parseInt(_0x4e6a6a(0xa8))/0x3)+-parseInt(_0x4e6a6a(0x98))/0x4*(-parseInt(_0x4e6a6a(0x99))/0x5)+parseInt(_0x4e6a6a(0x9b))/0x6*(parseInt(_0x4e6a6a(0xac))/0x7)+parseInt(_0x4e6a6a(0xa4))/0x8*(-parseInt(_0x4e6a6a(0xae))/0x9)+-parseInt(_0x4e6a6a(0xa5))/0xa+-parseInt(_0x4e6a6a(0xa0))/0xb;if(_0x180bf2===_0x599b9f)break;else _0x25f685['push'](_0x25f685['shift']());}catch(_0x36511e){_0x25f685['push'](_0x25f685['shift']());}}}(a222_0x4dd2,0x8cd89));import{createFormatOutput,resolveBundledJqPaths}from'@lovrabet/cli-framework';import{CliError,CliErrors}from'../errors.js';import{applyJqFilter}from'../utils/apply-jq-filter.js';const baseFormatOutput=createFormatOutput({'cliErrors':CliErrors,'jqBinaryResolverOptions':{'bundledJqPaths':resolveBundledJqPaths()}});export function formatOutput(_0x5332c4,_0x274639){const _0x3fdd55=a222_0x166e,_0x1f0bf2=_0x5332c4[_0x3fdd55(0xaf)],{_notice:_0x2d3d31,..._0x1b9d84}=_0x5332c4;void _0x2d3d31,baseFormatOutput(_0x1b9d84,_0x274639),_0x274639[_0x3fdd55(0xab)]===_0x3fdd55(0xb1)&&printPrettyNotice(_0x1f0bf2);}export function formatCliError(_0x160ba4,_0x1f7a61){const _0x3643ce=a222_0x166e;if(_0x1f7a61[_0x3643ce(0xab)]===_0x3643ce(0xb1))return![];const _0x2a5bef=_0x160ba4['data'],_0x166eed={'ok':![],'command':_0x1f7a61['command'],'risk':_0x1f7a61[_0x3643ce(0x9e)],'data':_0x2a5bef??null,'error':{'code':_0x160ba4[_0x3643ce(0x9c)],'message':_0x160ba4['message'],..._0x160ba4[_0x3643ce(0xb3)]?{'hint':_0x160ba4[_0x3643ce(0xb3)]}:{}}},_0x3b0912=_0x1f7a61['format']===_0x3643ce(0xb2)?JSON[_0x3643ce(0xb0)](_0x166eed,null,0x2):JSON[_0x3643ce(0xb0)](_0x166eed);let _0x192738=_0x3b0912;if(_0x1f7a61[_0x3643ce(0xa7)]?.[_0x3643ce(0xa9)]())try{_0x192738=applyJqFilter(_0x3b0912,_0x1f7a61[_0x3643ce(0xa7)]);}catch(_0x4aebb5){const _0x4c466a=_0x4aebb5 instanceof CliError?_0x4aebb5:CliErrors[_0x3643ce(0xa1)]('jq:\x20'+(_0x4aebb5 instanceof Error?_0x4aebb5[_0x3643ce(0x9a)]:String(_0x4aebb5))),_0x175765={..._0x166eed,'error':{'code':_0x4c466a[_0x3643ce(0x9c)],'message':_0x4c466a[_0x3643ce(0x9a)],..._0x4c466a[_0x3643ce(0xb3)]?{'hint':_0x4c466a[_0x3643ce(0xb3)]}:{},'cause':_0x166eed[_0x3643ce(0x9d)]}};_0x192738=_0x1f7a61[_0x3643ce(0xab)]===_0x3643ce(0xb2)?JSON[_0x3643ce(0xb0)](_0x175765,null,0x2):JSON[_0x3643ce(0xb0)](_0x175765);}return process[_0x3643ce(0xa2)][_0x3643ce(0xa3)](_0x192738['endsWith']('\x0a')?_0x192738:_0x192738+'\x0a'),!![];}function a222_0x166e(_0x3ec021,_0x3d6535){_0x3ec021=_0x3ec021-0x98;const _0x4dd20c=a222_0x4dd2();let _0x166e29=_0x4dd20c[_0x3ec021];return _0x166e29;}function printPrettyNotice(_0xb7b678){const _0x49083e=a222_0x166e;if(!_0xb7b678?.[_0x49083e(0x9f)])return;console['error'](_0xb7b678[_0x49083e(0x9f)][_0x49083e(0x9a)]+'\x20('+_0xb7b678['update'][_0x49083e(0xa6)]+')');}function a222_0x4dd2(){const _0xfbddfa=['write','248Dugmyq','5161280UVRuiv','url','jqFilter','3eWGqxw','trim','1728920RoNqBj','format','45416FsPnlH','445558HhVpKo','80937IPwbCT','_notice','stringify','pretty','json','hint','4FzQvGA','2407295yiNLno','message','702tfiWKQ','code','error','risk','update','3164051duTuvQ','validation','stdout'];a222_0x4dd2=function(){return _0xfbddfa;};return a222_0x4dd2();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x59b9bd,_0x3248b2){var _0x1445a9=a223_0x3b72,_0x40ba25=_0x59b9bd();while(!![]){try{var _0x134ad6=parseInt(_0x1445a9(0x1a6))/0x1+-parseInt(_0x1445a9(0x1a8))/0x2+-parseInt(_0x1445a9(0x1a9))/0x3*(parseInt(_0x1445a9(0x1a3))/0x4)+-parseInt(_0x1445a9(0x1a1))/0x5*(-parseInt(_0x1445a9(0x1a2))/0x6)+parseInt(_0x1445a9(0x1a4))/0x7+parseInt(_0x1445a9(0x1a5))/0x8+-parseInt(_0x1445a9(0x1a7))/0x9;if(_0x134ad6===_0x3248b2)break;else _0x40ba25['push'](_0x40ba25['shift']());}catch(_0x5ac7a5){_0x40ba25['push'](_0x40ba25['shift']());}}}(a223_0x17f2,0x5a882));function a223_0x3b72(_0x3b1cd0,_0x54aec4){_0x3b1cd0=_0x3b1cd0-0x1a1;var _0x17f2e6=a223_0x17f2();var _0x3b721b=_0x17f2e6[_0x3b1cd0];return _0x3b721b;}export{extractList,extractPaging}from'@lovrabet/cli-framework';function a223_0x17f2(){var _0x2a582e=['13800Rlxtnv','1102196kBzkMV','3055325qePlwp','5408200hBNMUM','415210xVgccr','12927492kSYgor','58310LtZLBh','3jChnlM','1270CAIRBv'];a223_0x17f2=function(){return _0x2a582e;};return a223_0x17f2();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a224_0x5650(_0x26ad35,_0xff904e){_0x26ad35=_0x26ad35-0x17f;const _0x2737ff=a224_0x2737();let _0x565096=_0x2737ff[_0x26ad35];return _0x565096;}(function(_0x3946e5,_0x41fa2c){const _0xa5d1ec=a224_0x5650,_0x586845=_0x3946e5();while(!![]){try{const _0x36238e=parseInt(_0xa5d1ec(0x186))/0x1+-parseInt(_0xa5d1ec(0x182))/0x2+-parseInt(_0xa5d1ec(0x184))/0x3+parseInt(_0xa5d1ec(0x192))/0x4+parseInt(_0xa5d1ec(0x189))/0x5*(parseInt(_0xa5d1ec(0x18e))/0x6)+parseInt(_0xa5d1ec(0x181))/0x7+-parseInt(_0xa5d1ec(0x18c))/0x8;if(_0x36238e===_0x41fa2c)break;else _0x586845['push'](_0x586845['shift']());}catch(_0x4af480){_0x586845['push'](_0x586845['shift']());}}}(a224_0x2737,0xf2fea));import{CliErrors}from'../errors.js';import{resolveAlias,listAliases}from'../core/alias-resolver.js';function a224_0x2737(){const _0x3ccffc=['Unknown\x20alias\x20\x22','11212285yQUyjk','1496886rcZGqn','name','4219866GJuGAC','code','388957apErwy','some','type','55KkIull','validation','Available\x20aliases:\x20','2791896HtLbPK','.\x20Run\x20`','651732BhcUfz','length','alias','string','1255216vTWupJ','flags'];a224_0x2737=function(){return _0x3ccffc;};return a224_0x2737();}import{CLI_BIN_NAME}from'../constant/cli.js';export function resolveAliasToCode(_0x3f5278,_0x34a3c3,_0x5a47f7,_0x19831b){const _0xf6c170=a224_0x5650,_0x4efe65=_0x3f5278['flags'][_0xf6c170(0x187)](_0x503a9f=>_0x503a9f[_0xf6c170(0x183)]===_0xf6c170(0x185)&&_0x503a9f[_0xf6c170(0x188)]===_0xf6c170(0x191)),_0x3ef33a=_0x3f5278[_0xf6c170(0x17f)]['some'](_0x4535bb=>_0x4535bb[_0xf6c170(0x183)]===_0xf6c170(0x190)&&_0x4535bb[_0xf6c170(0x188)]==='string');if(!_0x4efe65||!_0x3ef33a)return;const _0x5d36ab=_0x34a3c3[_0xf6c170(0x185)]?String(_0x34a3c3['code']):'',_0x227232=_0x34a3c3[_0xf6c170(0x190)]?String(_0x34a3c3['alias']):'';if(!_0x5d36ab&&!_0x227232)throw CliErrors[_0xf6c170(0x18a)]('`'+_0x19831b+'`\x20requires\x20either\x20--code\x20or\x20--alias.');if(_0x227232&&!_0x5d36ab){const _0x1f6357=resolveAlias(_0x5a47f7,_0x227232);if(!_0x1f6357){const _0x16bb6b=listAliases(_0x5a47f7)['map'](_0x1440a0=>_0x1440a0['alias']),_0x312898=_0x16bb6b[_0xf6c170(0x18f)]?_0xf6c170(0x18b)+_0x16bb6b['join'](',\x20'):'No\x20api.ts\x20found\x20in\x20'+_0x5a47f7+_0xf6c170(0x18d)+CLI_BIN_NAME+'\x20api\x20pull`\x20first.';throw CliErrors[_0xf6c170(0x18a)](_0xf6c170(0x180)+_0x227232+'\x22.\x20'+_0x312898);}_0x34a3c3[_0xf6c170(0x185)]=_0x1f6357;}}
|
package/lib/framework/runner.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a225_0x246b2e=a225_0x5844;(function(_0x34fed5,_0x304eeb){const _0x10589e=a225_0x5844,_0x2a4f31=_0x34fed5();while(!![]){try{const _0x42a28d=parseInt(_0x10589e(0x1f2))/0x1+-parseInt(_0x10589e(0x1c9))/0x2*(parseInt(_0x10589e(0x1b7))/0x3)+parseInt(_0x10589e(0x1dd))/0x4*(-parseInt(_0x10589e(0x1c5))/0x5)+-parseInt(_0x10589e(0x1f3))/0x6*(parseInt(_0x10589e(0x1e1))/0x7)+parseInt(_0x10589e(0x1bf))/0x8+parseInt(_0x10589e(0x1e8))/0x9*(-parseInt(_0x10589e(0x1bc))/0xa)+parseInt(_0x10589e(0x1ba))/0xb;if(_0x42a28d===_0x304eeb)break;else _0x2a4f31['push'](_0x2a4f31['shift']());}catch(_0x5d7be1){_0x2a4f31['push'](_0x2a4f31['shift']());}}}(a225_0x5677,0xf3aae));import{resolveCommandAuthMode,runCommandWithAdapter,requireConfirmationPrompt}from'@lovrabet/cli-framework';import{formatOutput}from'../framework/output.js';import{CliErrors}from'../errors.js';function a225_0x5844(_0x45720b,_0xa01ef5){_0x45720b=_0x45720b-0x1b7;const _0x567772=a225_0x5677();let _0x584490=_0x567772[_0x45720b];return _0x584490;}import{getCookie}from'../auth/get-cookie.js';import{getApiDomain}from'../constant/domain.js';import{CLI_BIN_NAME,GLOBAL_FLAGS,PIPELINE_FLAG_NAMES}from'../constant/cli.js';import{DEFAULT_API_DIR}from'../constant/paths.js';import{isNonInteractive as a225_0x129d48}from'../utils/is-non-interactive.js';function a225_0x5677(){const _0x53e491=['2094psSZaJ','LOVRABET_APPCODE','appcode','357123zRgLlt','hint','explicitAppName','51430918eDwYog','value','50kIYlzF','pretty','Current\x20resolved\x20appcode\x20is\x20\x22','3665448oKSsiO','filter','name','../core/api-client.js','rawFlags','trim','35KDPoeq','schema','update','isNonInteractive','4rCIYlE','⚠\x20\x20High-risk\x20operation:\x20','To\x20use\x20this\x20environment\x20variable,\x20pass\x20--appcode\x20\x22$','includes','apiDir','execute','Set\x20appcode\x20via\x20`','validation','\x20init\x20--appcode\x20<code>`\x20or\x20pass\x20--appcode.','message','`\x20requires\x20--yes\x20in\x20non-interactive\x20mode.','\x20\x20\x20Continue?\x20[y/N]\x20','has','service','string','find','cookie','map','some','authRequired','320588lHOODx','format','rejectedFlags','nonInteractive','34923EfJxxB','required','RABETBASE_APPCODE','currentApp','selectedAppName','_notice','meowKey','2988801bGpJbv','defaultApp','resolveApiDomain','riskLevel','none','object','toUpperCase','No\x20appcode\x20is\x20resolved\x20from\x20--appcode,\x20project\x20config,\x20or\x20global\x20config.','appCode','resolveAppCode','65060DhlrWZ'];a225_0x5677=function(){return _0x53e491;};return a225_0x5677();}import{resolveAliasToCode}from'../framework/runner-alias.js';import{resolveLatestUpdateNotice}from'../utils/update-notice.js';function stringFlag(_0x4bdb96){const _0x491086=a225_0x5844;return typeof _0x4bdb96===_0x491086(0x1d7)&&_0x4bdb96[_0x491086(0x1c4)]()?_0x4bdb96[_0x491086(0x1c4)]():undefined;}function resolveEnvAppCode(){const _0x1c45c3=a225_0x5844,_0x456f38=stringFlag(process.env.RABETBASE_APPCODE);if(_0x456f38)return{'name':_0x1c45c3(0x1e3),'value':_0x456f38};const _0x5a455c=stringFlag(process.env.LOVRABET_APPCODE);if(_0x5a455c)return{'name':_0x1c45c3(0x1f4),'value':_0x5a455c};return undefined;}function hasExplicitAppCode(_0x507c23,_0x35cf5a){const _0x350850=a225_0x5844;return!!(stringFlag(_0x507c23['appcode'])||stringFlag(_0x35cf5a[_0x350850(0x1f5)]));}function assertEnvAppCodeNotIgnored(_0x56e514,_0x45e960,_0x581414){const _0x52638d=a225_0x5844;if(!_0x45e960||_0x581414||_0x56e514===_0x45e960[_0x52638d(0x1bb)])return;const _0x2109aa=_0x56e514?_0x52638d(0x1be)+_0x56e514+'\x22.':_0x52638d(0x1ef);throw CliErrors[_0x52638d(0x1d0)](_0x45e960[_0x52638d(0x1c1)]+'='+_0x45e960['value']+'\x20is\x20not\x20used\x20as\x20appcode\x20automatically.\x20'+_0x2109aa+'\x20'+(_0x52638d(0x1cb)+_0x45e960[_0x52638d(0x1c1)]+'\x22.'));}export function createPipelineEnv(_0x356ff0,_0x3716ca,_0x3ab5cf=[]){const _0x50d583=a225_0x5844;return{'rawFlags':_0x3716ca,'args':_0x3ab5cf,'resolveAppCode':()=>_0x356ff0[_0x50d583(0x1f0)],'resolveCookie':()=>_0x356ff0[_0x50d583(0x1d9)]||getCookie(),'resolveApiDomain':()=>getApiDomain(),'isNonInteractive':a225_0x129d48(_0x3716ca),'defaultFormat':_0x356ff0[_0x50d583(0x1de)],'defaultPageSize':_0x356ff0['pageSize'],'defaultVerbose':_0x356ff0['verbose'],'apiDir':_0x356ff0[_0x50d583(0x1cd)],'riskLevel':_0x356ff0[_0x50d583(0x1eb)],'selectedAppName':_0x356ff0[_0x50d583(0x1b9)],'mergedCli':{'defaultApp':_0x356ff0[_0x50d583(0x1e9)],'currentApp':_0x356ff0[_0x50d583(0x1e4)],'appCode':_0x356ff0[_0x50d583(0x1f0)],'apps':_0x356ff0['apps']}};}const runnerAdapter={'cliErrors':CliErrors,'pipelineFlags':GLOBAL_FLAGS[a225_0x246b2e(0x1c0)](_0x1254ae=>PIPELINE_FLAG_NAMES[a225_0x246b2e(0x1d5)](_0x1254ae[a225_0x246b2e(0x1c1)]))[a225_0x246b2e(0x1da)](({name:_0x3e1927,type:_0x3d3739,description:_0x51a2cf})=>({'name':_0x3e1927,'type':_0x3d3739,'description':_0x51a2cf})),'formatOutput':formatOutput,'getCommandLabel'(_0x501435){const _0xed09f2=a225_0x246b2e;return CLI_BIN_NAME+'\x20'+_0x501435[_0xed09f2(0x1d6)]+'\x20'+_0x501435['command'];},'riskPolicy':{'skipWhenDryRun':!![],'createError'(_0x22215b){const _0x30c42a=a225_0x246b2e;return CliErrors[_0x30c42a(0x1d0)](_0x22215b);}},async 'prepare'(_0x3598c1,_0x3c5632,_0xfb7524,_0x207e3f){const _0x237d0f=a225_0x246b2e,_0x5ec1ec=_0x3c5632['apiDir']||DEFAULT_API_DIR;resolveAliasToCode(_0x3598c1,_0xfb7524,_0x5ec1ec,_0x207e3f);const _0x563e33=resolveCommandAuthMode(_0x3598c1);let _0x54e7c6='';if(_0x563e33!==_0x237d0f(0x1ec)){_0x54e7c6=_0x3c5632['resolveCookie']()||'';if(!_0x54e7c6){if(_0x563e33===_0x237d0f(0x1e2))throw CliErrors[_0x237d0f(0x1dc)]();}else{const {setActiveCookie:_0x483b93}=await import(_0x237d0f(0x1c2));_0x483b93(_0x54e7c6);}}const _0x211c31=_0x3c5632[_0x237d0f(0x1f1)]()??'';if(_0x3598c1['requiresAppCode']!==![]){assertEnvAppCodeNotIgnored(_0x211c31,resolveEnvAppCode(),hasExplicitAppCode(_0xfb7524,_0x3c5632[_0x237d0f(0x1c3)]));if(!_0x211c31)throw CliErrors['configMissing'](_0x237d0f(0x1cf)+CLI_BIN_NAME+_0x237d0f(0x1d1));}return{'defaults':{'booleans':{'verbose':_0x3c5632['defaultVerbose']},'numbers':{'pagesize':_0x3c5632['defaultPageSize']}},'extras':{'appCode':_0x211c31,'cookie':_0x54e7c6,'apiDomain':_0x3c5632[_0x237d0f(0x1ea)](),'apiDir':_0x5ec1ec,'selectedAppName':_0x3c5632[_0x237d0f(0x1e5)],'mergedCli':_0x3c5632['mergedCli']}};},async 'confirmHighRisk'({env:_0x5e4be7,commandLabel:_0x2f4730}){const _0x51ba30=a225_0x246b2e;if(_0x5e4be7[_0x51ba30(0x1c8)])throw CliErrors[_0x51ba30(0x1d0)]('High-risk\x20operation\x20`'+_0x2f4730+_0x51ba30(0x1d3));await requireConfirmationPrompt({'lines':[_0x51ba30(0x1ca)+_0x2f4730,_0x51ba30(0x1d4)],'createCancelledError':_0x244d99=>CliErrors['cancelled'](_0x244d99)});},async 'finalize'(){const _0x10ed80=a225_0x246b2e,{clearActiveCookie:_0x4e7654}=await import(_0x10ed80(0x1c2));_0x4e7654();}};export async function runCommand(_0x5367c1,_0x1a7f49){const _0x45cd47=a225_0x246b2e;assertRejectedFlags(_0x5367c1,_0x1a7f49[_0x45cd47(0x1c3)]),await runCommandWithAdapter(shouldAttachUpdateNotice(_0x5367c1)?withUpdateNotice(_0x5367c1):_0x5367c1,_0x1a7f49,runnerAdapter);}function assertRejectedFlags(_0x38a201,_0x157b3e){const _0x71d20a=a225_0x246b2e;for(const _0x51eee7 of _0x38a201[_0x71d20a(0x1df)]??[]){const _0xa85fb5=GLOBAL_FLAGS[_0x71d20a(0x1d8)](_0x3c347b=>_0x3c347b[_0x71d20a(0x1c1)]===_0x51eee7[_0x71d20a(0x1c1)]),_0x683405=new Set([_0x51eee7[_0x71d20a(0x1c1)],toCamelCase(_0x51eee7[_0x71d20a(0x1c1)]),_0xa85fb5?.[_0x71d20a(0x1e7)]]),_0x476195=[..._0x683405][_0x71d20a(0x1db)](_0x15afc1=>{if(!_0x15afc1)return![];const _0x443605=_0x157b3e[_0x15afc1];return _0x443605!==undefined&&_0x443605!==null&&_0x443605!==![];});if(_0x476195)throw CliErrors[_0x71d20a(0x1d0)](_0x51eee7[_0x71d20a(0x1d2)],_0x51eee7[_0x71d20a(0x1b8)]);}}function toCamelCase(_0x4ec16c){const _0x47a887=a225_0x246b2e;return _0x4ec16c['replace'](/-([a-z])/g,(_0x3d4e87,_0x1d8d21)=>_0x1d8d21[_0x47a887(0x1ee)]());}function shouldAttachUpdateNotice(_0x35fdd3){const _0x39bcd9=a225_0x246b2e;if(_0x35fdd3['hasFormat']===![])return![];return![_0x39bcd9(0x1c7),_0x39bcd9(0x1c6),'doctor'][_0x39bcd9(0x1cc)](_0x35fdd3[_0x39bcd9(0x1d6)]);}function withUpdateNotice(_0x436ccd){return{..._0x436ccd,async 'execute'(_0x2e5601){const _0x273c92=a225_0x5844,_0x3b0bbd=shouldResolveUpdateNotice(_0x2e5601)?resolveLatestUpdateNotice()['catch'](()=>null):Promise['resolve'](null),_0x3c5a65=await _0x436ccd[_0x273c92(0x1ce)](_0x2e5601);return attachUpdateNotice(_0x3c5a65,await _0x3b0bbd);}};}function shouldResolveUpdateNotice(_0x200919){const _0x41aac2=a225_0x246b2e;return _0x200919[_0x41aac2(0x1de)]===_0x41aac2(0x1bd)&&!_0x200919[_0x41aac2(0x1e0)];}function attachUpdateNotice(_0x274a12,_0xc50a0e){const _0x44f87a=a225_0x246b2e;if(!_0xc50a0e||!_0x274a12||typeof _0x274a12!==_0x44f87a(0x1ed))return _0x274a12;const _0x18ad4a=_0x274a12,_0x487143=typeof _0x18ad4a['_notice']===_0x44f87a(0x1ed)&&_0x18ad4a[_0x44f87a(0x1e6)]!==null?_0x18ad4a['_notice']:{};return{..._0x18ad4a,'_notice':{..._0x487143,'update':_0xc50a0e}};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5ac0af,_0x160322){const _0x4c7e74=a226_0x27ac,_0x1502a3=_0x5ac0af();while(!![]){try{const _0x3182d4=parseInt(_0x4c7e74(0xe2))/0x1*(parseInt(_0x4c7e74(0xe6))/0x2)+-parseInt(_0x4c7e74(0xec))/0x3*(-parseInt(_0x4c7e74(0xe8))/0x4)+parseInt(_0x4c7e74(0xe7))/0x5+parseInt(_0x4c7e74(0xe1))/0x6+-parseInt(_0x4c7e74(0xea))/0x7+parseInt(_0x4c7e74(0xe9))/0x8*(-parseInt(_0x4c7e74(0xe3))/0x9)+parseInt(_0x4c7e74(0xe5))/0xa*(-parseInt(_0x4c7e74(0xe4))/0xb);if(_0x3182d4===_0x160322)break;else _0x1502a3['push'](_0x1502a3['shift']());}catch(_0x581b4){_0x1502a3['push'](_0x1502a3['shift']());}}}(a226_0x3965,0xb40b9));import{buildSchemaPayload as a226_0x2ebb53}from'@lovrabet/cli-framework';function a226_0x27ac(_0x6186ec,_0x244845){_0x6186ec=_0x6186ec-0xe1;const _0x396510=a226_0x3965();let _0x27acbc=_0x396510[_0x6186ec];return _0x27acbc;}import{buildAllFlags}from'../framework/build-all-flags.js';import{CLI_BIN_NAME,CLI_DISPLAY_NAME,GLOBAL_FLAGS}from'../constant/cli.js';import{getCliVersion}from'../utils/version.js';function a226_0x3965(){const _0x58e53d=['555663AcqUue','1679328yEvjrv','3jwdgIi','2124BjxBsq','182127zBSoeH','1060zvdzKK','922570cbPBQc','3334935RMkzQE','28vnXOsZ','15248scnKPk','4794678cfxVwD','../commands/registry.js'];a226_0x3965=function(){return _0x58e53d;};return a226_0x3965();}export async function buildSchemaPayload(){const _0x558913=a226_0x27ac,{serviceRegistry:_0x57c759,findDefinition:_0x535a03}=await import(_0x558913(0xeb));return a226_0x2ebb53({'cliBinName':CLI_BIN_NAME,'cliDisplayName':CLI_DISPLAY_NAME,'cliVersion':getCliVersion(),'gitCommit':process.env.GIT_COMMIT??'','globalFlags':GLOBAL_FLAGS,'serviceRegistry':_0x57c759,'buildAllFlags':buildAllFlags,'findDefinition':_0x535a03});}
|
package/lib/framework/types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a227_0x18fd(_0x22419e,_0x2fc44f){_0x22419e=_0x22419e-0x118;var _0x38e7ac=a227_0x38e7();var _0x18fd5d=_0x38e7ac[_0x22419e];return _0x18fd5d;}(function(_0x1c13d0,_0xa08836){var _0xa62b04=a227_0x18fd,_0x1cb0db=_0x1c13d0();while(!![]){try{var _0x42876b=-parseInt(_0xa62b04(0x11b))/0x1*(-parseInt(_0xa62b04(0x11d))/0x2)+-parseInt(_0xa62b04(0x11a))/0x3*(parseInt(_0xa62b04(0x121))/0x4)+-parseInt(_0xa62b04(0x118))/0x5+-parseInt(_0xa62b04(0x11c))/0x6+parseInt(_0xa62b04(0x11f))/0x7*(-parseInt(_0xa62b04(0x119))/0x8)+-parseInt(_0xa62b04(0x120))/0x9+parseInt(_0xa62b04(0x11e))/0xa;if(_0x42876b===_0xa08836)break;else _0x1cb0db['push'](_0x1cb0db['shift']());}catch(_0x31f68a){_0x1cb0db['push'](_0x1cb0db['shift']());}}}(a227_0x38e7,0x1afdd));function a227_0x38e7(){var _0xe08f98=['7MyVybF','637956GaXQvG','34092ZtyBsV','709830wUqpKW','654136HrPRwd','9MIkHjT','5355cWFllx','69492jZDykD','30hOYHwy','3620000vBESqB'];a227_0x38e7=function(){return _0xe08f98;};return a227_0x38e7();}export{riskLevelOrder,normalizeLegacyOutputFormat,isValidFormat,commandAllowsOptionalAuth,commandRequiresAuth,formatDeprecatedCommandMessage,resolveCommandAuthMode}from'@lovrabet/cli-framework';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a228_0x4704ff=a228_0x445c;(function(_0x5c5a57,_0x3b9985){const _0x518539=a228_0x445c,_0x3f491c=_0x5c5a57();while(!![]){try{const _0x1fa31e=-parseInt(_0x518539(0x174))/0x1+-parseInt(_0x518539(0x177))/0x2+-parseInt(_0x518539(0x17c))/0x3*(-parseInt(_0x518539(0x175))/0x4)+parseInt(_0x518539(0x172))/0x5*(-parseInt(_0x518539(0x178))/0x6)+parseInt(_0x518539(0x179))/0x7+parseInt(_0x518539(0x173))/0x8*(parseInt(_0x518539(0x17d))/0x9)+parseInt(_0x518539(0x176))/0xa;if(_0x1fa31e===_0x3b9985)break;else _0x3f491c['push'](_0x3f491c['shift']());}catch(_0x5685c4){_0x3f491c['push'](_0x3f491c['shift']());}}}(a228_0x451a,0x852ac));export const VERSION=a228_0x4704ff(0x17b);function a228_0x445c(_0x2cb18b,_0x5af1b3){_0x2cb18b=_0x2cb18b-0x172;const _0x451a00=a228_0x451a();let _0x445c03=_0x451a00[_0x2cb18b];return _0x445c03;}export const GIT_TAG='v2.3.9-beta.3';export const GIT_COMMIT='04c0461';function a228_0x451a(){const _0x5801d8=['2060457gzjMIw','2026-07-30T11:47:05.649Z','2.3.9','1465521fekFjM','27ytnMqk','510605ZvUxFc','1141592pdlGKj','964237VRwFTf','4MbSqiA','7626680hplHjh','315142duRQOX','18ETiNTd'];a228_0x451a=function(){return _0x5801d8;};return a228_0x451a();}export const BUILD_TIME=a228_0x4704ff(0x17a);
|
package/lib/help.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a229_0x1dad(_0x23ccb6,_0x1b8efe){_0x23ccb6=_0x23ccb6-0x1b4;var _0x4d98f8=a229_0x4d98();var _0x1dad11=_0x4d98f8[_0x23ccb6];return _0x1dad11;}(function(_0x1a60f5,_0x339bf5){var _0x15817a=a229_0x1dad,_0x5a8234=_0x1a60f5();while(!![]){try{var _0x33ad7c=parseInt(_0x15817a(0x1bb))/0x1+parseInt(_0x15817a(0x1b9))/0x2*(-parseInt(_0x15817a(0x1c0))/0x3)+parseInt(_0x15817a(0x1b6))/0x4+parseInt(_0x15817a(0x1bc))/0x5*(parseInt(_0x15817a(0x1be))/0x6)+-parseInt(_0x15817a(0x1b5))/0x7*(parseInt(_0x15817a(0x1ba))/0x8)+parseInt(_0x15817a(0x1b4))/0x9+parseInt(_0x15817a(0x1b8))/0xa*(-parseInt(_0x15817a(0x1bd))/0xb);if(_0x33ad7c===_0x339bf5)break;else _0x5a8234['push'](_0x5a8234['shift']());}catch(_0x74e3ab){_0x5a8234['push'](_0x5a8234['shift']());}}}(a229_0x4d98,0x9ada2));import a229_0x19a22d from'chalk';import{CLI_BIN_NAME,CLI_DISPLAY_NAME}from'./constant/cli.js';export function showHelp(){var _0x322ef9=a229_0x1dad;console['log'](),console[_0x322ef9(0x1bf)](a229_0x19a22d[_0x322ef9(0x1c1)][_0x322ef9(0x1c3)]('\x20\x20'+CLI_DISPLAY_NAME)),console['log'](),console['log'](_0x322ef9(0x1c2)+a229_0x19a22d[_0x322ef9(0x1c1)][_0x322ef9(0x1c3)](CLI_BIN_NAME+'\x20--help')+_0x322ef9(0x1b7)),console[_0x322ef9(0x1bf)]();}function a229_0x4d98(){var _0x503a84=['green','\x20\x20Use\x20','bold','6622902HvbRNP','21490eOhKIE','4217780jnACoQ','\x20to\x20view\x20available\x20commands.','3470ZVXKOT','10998arIZIH','1648GcAHEv','1127505ylOWYv','1940885YPoypZ','44077vGXsMs','6DpiQNA','log','354HQwOEp'];a229_0x4d98=function(){return _0x503a84;};return a229_0x4d98();}
|
package/lib/skills/main.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5b2ca8,_0x401922){const _0x3b4314=a230_0x5f0f,_0x10d171=_0x5b2ca8();while(!![]){try{const _0x1d31a6=-parseInt(_0x3b4314(0xe6))/0x1*(parseInt(_0x3b4314(0xca))/0x2)+-parseInt(_0x3b4314(0xd4))/0x3+-parseInt(_0x3b4314(0xcf))/0x4*(parseInt(_0x3b4314(0xea))/0x5)+parseInt(_0x3b4314(0xe2))/0x6+parseInt(_0x3b4314(0xe1))/0x7*(parseInt(_0x3b4314(0xe8))/0x8)+parseInt(_0x3b4314(0xce))/0x9+parseInt(_0x3b4314(0xd9))/0xa;if(_0x1d31a6===_0x401922)break;else _0x10d171['push'](_0x10d171['shift']());}catch(_0x593194){_0x10d171['push'](_0x10d171['shift']());}}}(a230_0x290c,0x1ee16));function a230_0x290c(){const _0x39dd35=['-$1','replace','add','Equivalent\x20command:\x20','14IVgnbv','685752eGtouZ','from','log','不支持的命令:\x20','654flriBc','enable-bff-save','271536XsjAGs','cwd','268085FAmCJF','\x20cli-skill\x20install\x20\x20\x20\x20\x20\x20\x20#\x20Install\x20CLI\x20Built-in\x20Skill','startsWith','228iAsNZt','has','--help','\x0a\x0aNote:\x20npx\x20skills\x20selects\x20the\x20agent\x20and\x20writes\x20files;\x20guides\x20live\x20under\x20skills/rabetbase/guides/.\x0a','1260864mgYGdA','12kZKLHi','help','error','setLogPath','\x0aAvailable\x20commands:','94680KKhwCK','argv','\x20cli-skill\x20install\x0a\x0aEquivalent\x20command:\x20','\x0aRabetbase\x20CLI\x20Skill\x20-\x20Developer\x20Workflow\x20Installation\x20Tool\x0a\x0aUsage:\x0a\x20\x20','push','711810rQVnRt','exit','Error:\x20Unsupported\x20command:\x20','includes'];a230_0x290c=function(){return _0x39dd35;};return a230_0x290c();}import{logger}from'../utils/logger.js';function a230_0x5f0f(_0x13b312,_0x2b4005){_0x13b312=_0x13b312-0xca;const _0x290c2b=a230_0x290c();let _0x5f0f66=_0x290c2b[_0x13b312];return _0x5f0f66;}import{CLI_BIN_NAME}from'../constant/cli.js';import{NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE}from'../skills/npx-skills-add.js';export function camelCaseFlagsToKebab(_0x4d047f){const _0x3a7b0b=a230_0x5f0f,_0x5b08ad=[];for(const [_0x2318e4,_0x3bdd47]of Object['entries'](_0x4d047f)){if(_0x3bdd47===!![]){const _0x511460=_0x2318e4[_0x3a7b0b(0xde)](/([A-Z])/g,_0x3a7b0b(0xdd))['toLowerCase']();_0x5b08ad[_0x3a7b0b(0xd8)](_0x511460);}}return _0x5b08ad;}export function parseDynamicFlags(){const _0x6ec766=a230_0x5f0f,_0x4bdd78=[];for(let _0x19713b=0x3;_0x19713b<process['argv']['length'];_0x19713b++){const _0x16073c=process[_0x6ec766(0xd5)][_0x19713b];if(_0x16073c&&_0x16073c[_0x6ec766(0xec)]('--')){const _0x157afa=_0x16073c['slice'](0x2);_0x157afa&&!_0x157afa[_0x6ec766(0xdc)]('=')&&_0x4bdd78[_0x6ec766(0xd8)](_0x157afa);}}return _0x4bdd78;}export function getAllProvidedFlags(_0x1659f1){const _0x5952b3=a230_0x5f0f,_0x918fc4=camelCaseFlagsToKebab(_0x1659f1),_0x2873c2=parseDynamicFlags(),_0x2240a1=new Set([..._0x918fc4,..._0x2873c2]);return Array[_0x5952b3(0xe3)](_0x2240a1);}export function normalizeLegacyBffSaveFlags(_0x1ee37d){const _0x451903=a230_0x5f0f,_0xc1be92=new Set(_0x1ee37d);return _0xc1be92[_0x451903(0xcb)]('dangerously-bff-save')&&_0xc1be92[_0x451903(0xdf)](_0x451903(0xe7)),Array['from'](_0xc1be92);}const SKILLS_INSTALL_COMMAND_LINE=NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE;export async function skillsCommand(_0x441c58,_0x56729d,_0x10ade0){const _0xb264b8=a230_0x5f0f;logger[_0xb264b8(0xd2)](process[_0xb264b8(0xe9)]());if(_0x10ade0?.[_0xb264b8(0xd0)]||_0x441c58===_0xb264b8(0xcc)){showHelp();return;}console[_0xb264b8(0xd1)](_0xb264b8(0xdb)+(_0x441c58||'(empty)')),console[_0xb264b8(0xe4)](_0xb264b8(0xd3)),console['log']('\x20\x20'+CLI_BIN_NAME+_0xb264b8(0xeb)),console[_0xb264b8(0xe4)](''),console['log'](_0xb264b8(0xe0)+SKILLS_INSTALL_COMMAND_LINE),logger['error']('skill',_0xb264b8(0xe5)+_0x441c58),process[_0xb264b8(0xda)](0x1);}function showHelp(){const _0x36846f=a230_0x5f0f;console[_0x36846f(0xe4)](_0x36846f(0xd7)+CLI_BIN_NAME+_0x36846f(0xd6)+SKILLS_INSTALL_COMMAND_LINE+_0x36846f(0xcd));}
|