@lovrabet/rabetbase-cli 2.5.13-beta.1 → 2.5.13
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/api-group.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/api/generate-sdk-config-file.js +1 -1
- package/lib/api/legacy-api-file.js +1 -1
- package/lib/api/model-registry-file.js +1 -1
- package/lib/api/model-registry-scaffold.js +1 -1
- package/lib/api/model-source.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/detail.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/members-list.js +1 -1
- package/lib/commands/app/remote-directory.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/logs.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 -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/delete.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/init.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/dataset/batch-design.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/business-groups.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/cross-relation-create.js +1 -1
- package/lib/commands/dataset/cross-relation-delete.js +1 -1
- package/lib/commands/dataset/cross-relation-list.js +1 -1
- package/lib/commands/dataset/cross-relation-shared.js +1 -1
- package/lib/commands/dataset/cross-relation-update.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/design-context.js +1 -1
- package/lib/commands/dataset/design-start.js +1 -1
- package/lib/commands/dataset/design-status.js +1 -1
- package/lib/commands/dataset/design-sync-retry.js +1 -1
- package/lib/commands/dataset/design-sync-status.js +1 -1
- package/lib/commands/dataset/design-validate.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-restore.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/dataset/user-deleted-field-list.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/cross-db-analysis-shared.js +1 -1
- package/lib/commands/db/cross-db-analyze-latest.js +1 -1
- package/lib/commands/db/cross-db-analyze-start.js +1 -1
- package/lib/commands/db/cross-db-analyze-status.js +1 -1
- package/lib/commands/db/delete.js +1 -1
- package/lib/commands/db/detail.js +1 -1
- package/lib/commands/db/diff-refresh-start.js +1 -1
- package/lib/commands/db/diff-refresh-status.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/table-diff-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/deployment/index.js +1 -1
- package/lib/commands/deployment/sync-all.js +1 -1
- package/lib/commands/deployment/sync-jobs.js +1 -1
- package/lib/commands/deployment/sync-status.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/flow/create.js +1 -1
- package/lib/commands/flow/detail.js +1 -1
- package/lib/commands/flow/index.js +1 -1
- package/lib/commands/flow/list.js +1 -1
- package/lib/commands/flow/page-list.js +1 -1
- package/lib/commands/flow/publish.js +1 -1
- package/lib/commands/flow/runtime-resources-shared.js +1 -1
- package/lib/commands/flow/runtime-role-list.js +1 -1
- package/lib/commands/flow/runtime-role-user-list.js +1 -1
- package/lib/commands/flow/runtime-user-search.js +1 -1
- package/lib/commands/flow/shared.js +1 -1
- package/lib/commands/flow/update.js +1 -1
- package/lib/commands/flow/validate.js +1 -1
- package/lib/commands/instant-api-policy/current.js +1 -1
- package/lib/commands/instant-api-policy/index.js +1 -1
- package/lib/commands/instant-api-policy/init.js +1 -1
- package/lib/commands/instant-api-policy/publish.js +1 -1
- package/lib/commands/instant-api-policy/pull.js +1 -1
- package/lib/commands/instant-api-policy/revision.js +1 -1
- package/lib/commands/instant-api-policy/revisions.js +1 -1
- package/lib/commands/instant-api-policy/rollback.js +1 -1
- package/lib/commands/instant-api-policy/shared.js +1 -1
- package/lib/commands/instant-api-policy/validate.js +1 -1
- package/lib/commands/issue/context.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/kb/create.js +1 -1
- package/lib/commands/kb/delete.js +1 -1
- package/lib/commands/kb/detail.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/kb/list.js +1 -1
- package/lib/commands/kb/search.js +1 -1
- package/lib/commands/kb/shared.js +1 -1
- package/lib/commands/kb/update.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/asset-update.js +1 -1
- package/lib/commands/menu/delete.js +1 -1
- package/lib/commands/menu/external-link-create.js +1 -1
- package/lib/commands/menu/external-link-update.js +1 -1
- package/lib/commands/menu/group-create.js +1 -1
- package/lib/commands/menu/group-update.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/move.js +1 -1
- package/lib/commands/menu/regroup-start.js +1 -1
- package/lib/commands/menu/rename.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/delete-plan.js +1 -1
- package/lib/commands/menu/shared/facts.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/mutations.js +1 -1
- package/lib/commands/menu/shared/path.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/subapp-assets.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/subapp-assets-status.js +1 -1
- package/lib/commands/menu/subapp-assets-update.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/visibility-update.js +1 -1
- package/lib/commands/notification/config-create.js +1 -1
- package/lib/commands/notification/config-delete.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/config-update.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/notification/shared.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/page/create.js +1 -1
- package/lib/commands/page/custom/detail.js +1 -1
- package/lib/commands/page/custom/list.js +1 -1
- package/lib/commands/page/custom/publish.js +1 -1
- package/lib/commands/page/custom/shared.js +1 -1
- package/lib/commands/page/custom/syntax.js +1 -1
- package/lib/commands/page/custom/update.js +1 -1
- package/lib/commands/page/data-list-status.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/restore.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/project/api-architecture-upgrade.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/materialize-project-template.js +1 -1
- package/lib/commands/project/create/project-name.js +1 -1
- package/lib/commands/project/create/project-template-archive.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/domain-routing-sync.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.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/rule/get.js +1 -1
- package/lib/commands/rule/index.js +1 -1
- package/lib/commands/rule/list.js +1 -1
- package/lib/commands/rule/set.js +1 -1
- package/lib/commands/rule/shared.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/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 -1
- package/lib/commands/task/status.js +1 -1
- package/lib/commands/tenant/index.js +1 -1
- package/lib/commands/tenant/members-list.js +1 -1
- package/lib/commands/tenant/shared.js +1 -1
- package/lib/commands/user-account/dingding-sandbox-bind.js +1 -1
- package/lib/commands/user-account/feishu-bind.js +1 -1
- package/lib/commands/user-account/index.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/domain-config.js +1 -1
- package/lib/config/project-domain-routing.js +1 -1
- package/lib/config/region-config.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/region.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/constant/routing-profile.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/hook-directory.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/cross-db-analysis.js +1 -1
- package/lib/core/cross-db-relation.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/flow-config.js +1 -1
- package/lib/core/instant-api-policy/config.js +1 -1
- package/lib/core/instant-api-policy/endpoints.js +1 -1
- package/lib/core/kb-management-client.js +1 -1
- package/lib/core/kb-search-client.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/page/lr-smart-jsx.js +1 -1
- package/lib/core/sql-index-auditor.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/error-output.js +1 -1
- package/lib/framework/explicit-yes.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/supported-flags.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.d.ts +4 -4
- package/lib/generated/build-info.js +1 -1
- package/lib/generated/official-routing.js +1 -1
- package/lib/generated/routing-contract.js +1 -1
- package/lib/help.js +1 -1
- package/lib/postinstall.js +1 -1
- package/lib/runtime/confirmation.js +1 -1
- package/lib/runtime/event.js +1 -1
- package/lib/runtime/index.js +1 -1
- package/lib/runtime/queue.js +1 -1
- package/lib/runtime/resolve.js +1 -1
- package/lib/services/dataset-design/checkpoint.js +1 -1
- package/lib/services/dataset-design/commands.js +1 -1
- package/lib/services/dataset-design/contract.js +1 -1
- package/lib/skills/builtin-skill.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/skills/skill-presence.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/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/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/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/skills/rabetbase/SKILL.md +1 -1
- package/skills/rabetbase-dataset-generation/SKILL.md +1 -1
- package/skills/rabetbase-page-generation/SKILL.md +1 -1
- package/skills/rabetbase.manifest.json +3 -3
package/lib/commands/bff/push.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const a44_0xad0615=a44_0x3e85;(function(_0x1960fc,_0x6e2039){const _0x227280=a44_0x3e85,_0x29b8fd=_0x1960fc();while(!![]){try{const _0x32354c=-parseInt(_0x227280(0x1da))/0x1+parseInt(_0x227280(0x21f))/0x2+-parseInt(_0x227280(0x1f4))/0x3+-parseInt(_0x227280(0x206))/0x4*(parseInt(_0x227280(0x201))/0x5)+-parseInt(_0x227280(0x1e1))/0x6+parseInt(_0x227280(0x228))/0x7*(parseInt(_0x227280(0x219))/0x8)+parseInt(_0x227280(0x1bc))/0x9*(parseInt(_0x227280(0x208))/0xa);if(_0x32354c===_0x6e2039)break;else _0x29b8fd['push'](_0x29b8fd['shift']());}catch(_0x5a363c){_0x29b8fd['push'](_0x29b8fd['shift']());}}}(a44_0x3283,0x2ec7f));import{readFile}from'node:fs/promises';import{saveBffScript,getBffScriptInfo,getBffScriptStatistics,getPlatformErrorCode,listDatasets,clearBffScriptCache}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';function a44_0x3e85(_0x521c7a,_0x3281db){_0x521c7a=_0x521c7a-0x1b7;const _0x328300=a44_0x3283();let _0x3e855c=_0x328300[_0x521c7a];return _0x3e855c;}import{resolveApiModelSource}from'../../api/model-source.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{normalizeBffType,scanLocalBffFunctions}from'../../core/bff/file-system.js';import{buildHookDirectoryIndexes,assertUnambiguousHookAliases,assertUnambiguousHookDirectoryMappings,preflightPushHookDirectories,trackedHookDirectoryMappings}from'../../core/bff/hook-directory.js';import{computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile,writeBffLockFile}from'../../core/bff/lock.js';import{extractScriptDescription,snakeToCamel}from'../../core/bff/utils.js';import{sleep}from'../../utils/sleep.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{CliErrors}from'../../errors.js';const CACHE_CLEAR_ATTEMPTS=0x2,CACHE_CLEAR_INTERVAL_MS=0x12c;export const bffPush={'service':a44_0xad0615(0x20f),'command':a44_0xad0615(0x225),'description':'Push\x20local\x20Backend\x20Function\x20scripts\x20to\x20remote','risk':a44_0xad0615(0x21d),'structuredErrors':!![],'flags':[{'name':a44_0xad0615(0x22b),'type':a44_0xad0615(0x1cd),'description':a44_0xad0615(0x1cc),'enum':['COMMON','ENDPOINT',a44_0xad0615(0x21b)]},{'name':a44_0xad0615(0x1e8),'type':a44_0xad0615(0x1cd),'description':a44_0xad0615(0x1be)},{'name':a44_0xad0615(0x1f9),'type':'boolean','description':'Force\x20push\x20ignoring\x20hash\x20protection'}],async 'dryRun'(_0x1369e3){const _0x3dfc88=a44_0xad0615,_0x43fc33=loadBffProjectConfig(_0x1369e3[_0x3dfc88(0x1fd)]),_0x557633=await readBffLockFile(_0x43fc33['lockFilePath']),{appLock:_0x54a637}=ensureLockScope(_0x557633??createEmptyBffLock(),_0x1369e3[_0x3dfc88(0x1fd)],_0x43fc33[_0x3dfc88(0x1ec)],'push'),_0x4503df=await getTargetFunctions(_0x43fc33,_0x1369e3),_0x148e38=_0x4503df['some'](_0x3757e0=>_0x3757e0[_0x3dfc88(0x22b)]===_0x3dfc88(0x21b))?await scanLocalBffFunctions(_0x43fc33,_0x3dfc88(0x21b)):_0x4503df,_0x2cac38=await buildHookMaps(_0x1369e3[_0x3dfc88(0x1fd)],_0x1369e3[_0x3dfc88(0x1e7)],_0x148e38,_0x54a637,_0x1369e3[_0x3dfc88(0x202)]||_0x1369e3[_0x3dfc88(0x1c1)]?.['currentApp']||_0x1369e3[_0x3dfc88(0x1c1)]?.[_0x3dfc88(0x1db)]),_0x8452e9=_0x1369e3[_0x3dfc88(0x1f5)](_0x3dfc88(0x1f9)),_0x439961=[];for(const _0x290381 of _0x4503df){const _0x4d24b7=await computeFileHash(_0x290381['filePath']),_0xde73e5=_0x54a637['functions'][_0x290381[_0x3dfc88(0x1f3)]],_0x2cd334=!!_0xde73e5&&_0xde73e5[_0x3dfc88(0x220)]===_0x4d24b7,_0x5a30e4=_0x2cac38[_0x3dfc88(0x1c5)]['get'](_0x290381[_0x3dfc88(0x1f3)]),_0x4e2b6f=!!_0xde73e5?.[_0x3dfc88(0x1fa)]&&_0xde73e5[_0x3dfc88(0x1ef)]==null&&(_0x8452e9||!_0x2cd334),_0x5aee6c=_0x4e2b6f?missingRemoteVersionConflict(_0x290381,_0xde73e5):undefined,_0x15d3a6=_0x2cac38[_0x3dfc88(0x1d1)]['has'](_0x290381[_0x3dfc88(0x1f3)])?_0x3dfc88(0x217):!_0x8452e9&&_0x2cd334?_0x3dfc88(0x1d0):_0x5aee6c?_0x3dfc88(0x1fe):_0x3dfc88(0x21c);_0x439961['push']({'lockKey':_0x290381[_0x3dfc88(0x1f3)],'filePath':_0x290381[_0x3dfc88(0x1de)],'remoteId':_0xde73e5?.[_0x3dfc88(0x1fa)]??null,'mode':_0xde73e5?.[_0x3dfc88(0x1fa)]?'update':_0x3dfc88(0x214),'status':_0x15d3a6,..._0x2cac38[_0x3dfc88(0x1d1)]['has'](_0x290381[_0x3dfc88(0x1f3)])?{'error':_0x2cac38[_0x3dfc88(0x1d1)][_0x3dfc88(0x226)](_0x290381[_0x3dfc88(0x1f3)])}:{},..._0x5aee6c?{'conflict':_0x5aee6c}:{},..._0x2cac38['existingHooks']['has'](_0x290381[_0x3dfc88(0x1f3)])?{'datasetCode':_0xde73e5?.[_0x3dfc88(0x1d9)],'bindingPreserved':!![],'warnings':[existingHookWarning(_0x290381['lockKey'])]}:{},..._0x5a30e4?{'alias':_0x5a30e4[_0x3dfc88(0x1e6)]??null,'datasetCode':_0x5a30e4[_0x3dfc88(0x1d9)],'operationType':_0x290381[_0x3dfc88(0x1ed)],'functionNode':_0x290381['functionNode'],'warnings':_0x5a30e4['warnings']}:{}});}return{'method':'POST','url':_0x3dfc88(0x21a),'body':{'appCode':_0x1369e3[_0x3dfc88(0x1fd)],'force':_0x8452e9,'files':_0x439961,'cacheClearAtRuntime':_0x439961[_0x3dfc88(0x223)](_0xf00931=>_0xf00931['status']===_0x3dfc88(0x21c)),'cacheClearAtRuntimeTimes':_0x439961[_0x3dfc88(0x223)](_0x225372=>_0x225372['status']===_0x3dfc88(0x21c))?CACHE_CLEAR_ATTEMPTS:0x0},'description':_0x3dfc88(0x221)+_0x439961[_0x3dfc88(0x1f1)]+_0x3dfc88(0x1f6)};},async 'execute'(_0x546e4d){const _0x4e24bc=a44_0xad0615,_0x1e0fa0=loadBffProjectConfig(_0x546e4d[_0x4e24bc(0x1fd)]),_0x198079=await readBffLockFile(_0x1e0fa0[_0x4e24bc(0x1d2)]),{lockData:_0x5bc079,appLock:_0x11da3e}=ensureLockScope(_0x198079??createEmptyBffLock(),_0x546e4d[_0x4e24bc(0x1fd)],_0x1e0fa0[_0x4e24bc(0x1ec)],_0x4e24bc(0x225)),_0x55b057=await getTargetFunctions(_0x1e0fa0,_0x546e4d);if(_0x55b057[_0x4e24bc(0x1f1)]===0x0)return{'ok':!![],'data':{'uploaded':[],'skipped':[],'conflicts':[],'failed':[]},'message':_0x4e24bc(0x1e0)};const _0x16621e=_0x546e4d[_0x4e24bc(0x1f5)](_0x4e24bc(0x1f9)),_0x1a0147=JSON[_0x4e24bc(0x203)](JSON[_0x4e24bc(0x1c3)](_0x5bc079)),_0x7a9c95=_0x1a0147[_0x4e24bc(0x215)][_0x546e4d[_0x4e24bc(0x1fd)]];if(!_0x7a9c95)throw new Error(_0x4e24bc(0x1bf)+_0x546e4d['appCode']+_0x4e24bc(0x1eb));const _0x175215=_0x55b057[_0x4e24bc(0x223)](_0x32510e=>_0x32510e[_0x4e24bc(0x22b)]==='HOOK')?await scanLocalBffFunctions(_0x1e0fa0,_0x4e24bc(0x21b)):_0x55b057,_0x36bfd1=await buildHookMaps(_0x546e4d['appCode'],_0x546e4d[_0x4e24bc(0x1e7)],_0x175215,_0x7a9c95,_0x546e4d[_0x4e24bc(0x202)]||_0x546e4d[_0x4e24bc(0x1c1)]?.[_0x4e24bc(0x1c0)]||_0x546e4d[_0x4e24bc(0x1c1)]?.[_0x4e24bc(0x1db)]),_0x5c6ab6=[],_0x572eac=[],_0x19e72f=[],_0x47d0cb=[];for(const _0x1d9195 of _0x55b057){const _0x20f35c=_0x36bfd1['failures'][_0x4e24bc(0x226)](_0x1d9195[_0x4e24bc(0x1f3)]);if(_0x20f35c){_0x47d0cb[_0x4e24bc(0x225)]({'lockKey':_0x1d9195[_0x4e24bc(0x1f3)],'error':_0x20f35c});continue;}const _0x2c0d5c=await computeFileHash(_0x1d9195[_0x4e24bc(0x1de)]),_0x57c1f5=_0x7a9c95[_0x4e24bc(0x1e4)][_0x1d9195[_0x4e24bc(0x1f3)]];if(!_0x16621e&&_0x57c1f5&&_0x57c1f5[_0x4e24bc(0x220)]===_0x2c0d5c){_0x572eac[_0x4e24bc(0x225)]({'lockKey':_0x1d9195[_0x4e24bc(0x1f3)],'reason':_0x4e24bc(0x1d0)});continue;}if(_0x57c1f5?.[_0x4e24bc(0x1fa)]&&_0x57c1f5[_0x4e24bc(0x1ef)]==null){_0x19e72f[_0x4e24bc(0x225)](missingRemoteVersionConflict(_0x1d9195,_0x57c1f5));continue;}try{await uploadSingleFunction(_0x546e4d[_0x4e24bc(0x1fd)],_0x1d9195,_0x7a9c95,_0x36bfd1);const _0x1c2659=_0x7a9c95[_0x4e24bc(0x1e4)][_0x1d9195[_0x4e24bc(0x1f3)]];_0x5c6ab6['push']({'lockKey':_0x1d9195['lockKey'],'remoteId':_0x1c2659?.[_0x4e24bc(0x1fa)]??0x0});}catch(_0x214777){const _0x2aa472=remoteVersionChangedConflict(_0x1d9195,_0x57c1f5,_0x214777);if(_0x2aa472){_0x19e72f[_0x4e24bc(0x225)](_0x2aa472);continue;}_0x47d0cb[_0x4e24bc(0x225)]({'lockKey':_0x1d9195[_0x4e24bc(0x1f3)],'error':_0x214777 instanceof Error?_0x214777[_0x4e24bc(0x1df)]:String(_0x214777)});}}_0x7a9c95[_0x4e24bc(0x1dd)]=new Date()['toISOString'](),await writeBffLockFile(_0x1e0fa0[_0x4e24bc(0x1d2)],_0x1a0147),await waitForUploadedLockEntries(_0x1e0fa0[_0x4e24bc(0x1d2)],_0x546e4d[_0x4e24bc(0x1fd)],_0x5c6ab6['map'](_0x13cacb=>_0x13cacb[_0x4e24bc(0x1f3)]));let _0x4447ff={'attempted':![],'cleared':![]};if(_0x5c6ab6['length']>0x0)try{let _0x5198df='';for(let _0x2445eb=0x0;_0x2445eb<CACHE_CLEAR_ATTEMPTS;_0x2445eb+=0x1){_0x5198df=await clearBffScriptCache(),_0x2445eb<CACHE_CLEAR_ATTEMPTS-0x1&&await sleep(CACHE_CLEAR_INTERVAL_MS);}_0x4447ff={'attempted':!![],'cleared':!![],'message':_0x5198df||_0x4e24bc(0x229)};}catch(_0x110e0a){_0x4447ff={'attempted':!![],'cleared':![],'error':_0x110e0a instanceof Error?_0x110e0a[_0x4e24bc(0x1df)]:String(_0x110e0a)};}const _0x29db53=_0x47d0cb[_0x4e24bc(0x1f1)]===0x0&&(_0x4447ff[_0x4e24bc(0x1ff)]?_0x4447ff[_0x4e24bc(0x1e9)]:!![]),_0x41e941=_0x29db53,_0x4d7520=_0x4447ff[_0x4e24bc(0x1ff)]?_0x4447ff[_0x4e24bc(0x1e9)]?_0x4e24bc(0x1dc):_0x4e24bc(0x1bb):_0x4e24bc(0x224);return{'ok':_0x41e941,'data':{'uploaded':_0x5c6ab6,'skipped':_0x572eac,'conflicts':_0x19e72f,'failed':_0x47d0cb,'cacheClear':_0x4447ff,'warnings':[...[..._0x36bfd1[_0x4e24bc(0x1c5)][_0x4e24bc(0x1d8)]()][_0x4e24bc(0x210)](_0x3a5c91=>_0x3a5c91['warnings']),...[..._0x36bfd1[_0x4e24bc(0x1e2)]][_0x4e24bc(0x1c6)](existingHookWarning)]},'message':formatPushMessage(_0x5c6ab6['length'],_0x572eac[_0x4e24bc(0x1f1)],_0x19e72f[_0x4e24bc(0x1f1)],_0x47d0cb['length'],_0x4d7520)};}};function missingRemoteVersionConflict(_0x14251e,_0x5a9afe){const _0x1b47e2=a44_0xad0615;return remoteVersionConflict(_0x14251e,_0x5a9afe,_0x1b47e2(0x212),_0x1b47e2(0x1ea));}function remoteVersionChangedConflict(_0x487e2e,_0x3ad80c,_0x207844){const _0x1c0816=a44_0xad0615;if(!_0x3ad80c?.['remoteId']||_0x3ad80c['version']==null||!isRemoteVersionConflict(_0x207844))return undefined;return remoteVersionConflict(_0x487e2e,_0x3ad80c,_0x1c0816(0x20b),_0x1c0816(0x1fb));}function remoteVersionConflict(_0x17b2e9,_0x2c8b30,_0x483cc0,_0xd1016){const _0x121e43=a44_0xad0615;return{'code':_0x483cc0,'lockKey':_0x17b2e9[_0x121e43(0x1f3)],'filePath':_0x17b2e9[_0x121e43(0x1de)],'remoteId':_0x2c8b30[_0x121e43(0x1fa)],..._0x2c8b30[_0x121e43(0x1ef)]!=null?{'expectedVersion':_0x2c8b30[_0x121e43(0x1ef)]}:{},'message':_0xd1016,'nextAction':{'action':_0x121e43(0x1f0),'command':CLI_BIN_NAME+'\x20bff\x20detail\x20--id\x20'+_0x2c8b30[_0x121e43(0x1fa)]+_0x121e43(0x1bd),'requiresReview':!![],'message':_0x121e43(0x204)}};}function isRemoteVersionConflict(_0x4d094f){const _0x4a53ab=a44_0xad0615,_0x31f6b9=_0x4d094f instanceof Error?_0x4d094f[_0x4a53ab(0x1df)]:String(_0x4d094f),_0x298b6b=getPlatformErrorCode(_0x4d094f)??'';return[_0x31f6b9,_0x298b6b]['some'](_0x3edd7c=>/(?:version|optimistic)[\s_-]*(?:conflict|mismatch|changed|stale|out[\s_-]*of[\s_-]*date)|(?:conflict|mismatch|changed|stale|out[\s_-]*of[\s_-]*date)[\s_-]*(?:version|optimistic)/i[_0x4a53ab(0x200)](_0x3edd7c));}function a44_0x3283(){const _0x204300=['9EpSqmE','\x20--format\x20compress','Push\x20only\x20the\x20named\x20function\x20(requires\x20--type)','Lock\x20scope\x20for\x20app\x20\x22','currentApp','mergedCli','afterScriptId','stringify','description','resolutions','map','--name\x20requires\x20--type\x20to\x20identify\x20the\x20function.','size','dataset','functionName','\x20conflict','Push\x20only\x20this\x20script\x20type','string','before','script','unchanged','failures','lockFilePath','profileName','set','filter','Local\x20function\x20not\x20found:\x20','startsWith','values','datasetCode','58685kRCirP','defaultApp','runtime\x20cache\x20cleared','lastSync','filePath','message','No\x20local\x20Backend\x20Function\x20scripts\x20found.','1515840KRLRnj','existingHooks','\x20uploaded','functions','scriptType','alias','apiDir','name','cleared','The\x20local\x20sync\x20lock\x20has\x20no\x20remote\x20version\x20for\x20this\x20script.','\x22\x20not\x20found\x20after\x20ensureLockScope.','scriptsRoot','operationType','HOOK_DATASET_NOT_FOUND:','version','review_remote_and_merge','length','datasetId','lockKey','326082OWseyF','bool','\x20local\x20Backend\x20Function\x20script(s)\x20for\x20push\x20and\x20clear\x20runtime\x20cache\x20if\x20files\x20are\x20uploaded','Incomplete\x20HOOK\x20path:\x20','str','force','remoteId','Remote\x20script\x20version\x20changed\x20since\x20the\x20last\x20pull.','Dataset\x20metadata\x20is\x20unavailable;\x20the\x20existing\x20script\x20and\x20binding\x20were\x20verified.\x20Update\x20by\x20script\x20ID\x20without\x20rebinding.','appCode','conflict','attempted','test','15INZrch','selectedAppName','parse','Review\x20the\x20current\x20remote\x20source,\x20merge\x20it\x20into\x20the\x20local\x20script,\x20then\x20retry\x20push.\x20Do\x20not\x20use\x20--force\x20unless\x20you\x20intentionally\x20discard\x20local\x20changes.','every','283924OZkqOX','Cannot\x20verify\x20existing\x20HOOK\x20binding:\x20','5985680ADfByf','requires','Multiple\x20HOOK\x20directories\x20reference\x20the\x20same\x20missing\x20Dataset.\x20Resolve\x20duplicate\x20directories\x20before\x20pushing.','BFF_REMOTE_VERSION_CHANGED','Lock\x20file\x20not\x20settled\x20after\x20push\x20for\x20','functionNode','Existing\x20HOOK\x20identity,\x20version\x20or\x20binding\x20does\x20not\x20match\x20the\x20local\x20lock.\x20Pull\x20and\x20review\x20before\x20pushing.','bff','flatMap','delete','BFF_REMOTE_VERSION_MISSING','\x20resolution','create','apps',':\x20missing\x20remote\x20version.\x20Run\x20`push`\x20after\x20`pull`\x20to\x20sync\x20version\x20info.','failed','join','22736BNgSkk','/api/management/library/scripts/save','HOOK','would_push','write','add','25718QDfpqc','hash','Would\x20inspect\x20','require','some','runtime\x20cache\x20not\x20needed','push','get','beforeScriptId','525OqukVa','Runtime\x20script\x20cache\x20cleared.','Push\x20complete:\x20','type','has','EXISTING_HOOK_BINDING_PRESERVED','utf8','validation','runtime\x20cache\x20clear\x20failed'];a44_0x3283=function(){return _0x204300;};return a44_0x3283();}function formatPushMessage(_0x5e031d,_0x3e1fda,_0x1a3e8f,_0x4054c5,_0x2140ed){const _0x35676c=a44_0xad0615,_0x116840=[_0x35676c(0x22a)+_0x5e031d+_0x35676c(0x1e3),_0x3e1fda+'\x20skipped'];_0x1a3e8f>0x0&&_0x116840[_0x35676c(0x225)](_0x1a3e8f+_0x35676c(0x1cb)+(_0x1a3e8f===0x1?'':'s')+'\x20'+(_0x1a3e8f===0x1?_0x35676c(0x209):_0x35676c(0x222))+_0x35676c(0x213));if(_0x4054c5>0x0)_0x116840['push'](_0x4054c5+'\x20failed');return _0x116840[_0x35676c(0x225)](_0x2140ed),_0x116840[_0x35676c(0x218)](',\x20');}async function getTargetFunctions(_0x2eaa5b,_0x448ab0){const _0x5243ea=a44_0xad0615,_0x337f17=_0x448ab0[_0x5243ea(0x1f8)]('type'),_0x1488bd=_0x448ab0[_0x5243ea(0x1f8)](_0x5243ea(0x1e8)),_0x27d159=normalizeBffType(_0x337f17)??undefined;if(_0x1488bd&&!_0x27d159)throw CliErrors[_0x5243ea(0x1ba)](_0x5243ea(0x1c7));const _0x330b0d=await scanLocalBffFunctions(_0x2eaa5b,_0x27d159);if(_0x1488bd){const _0x234dec=_0x330b0d[_0x5243ea(0x1d5)](_0x8968ee=>_0x8968ee[_0x5243ea(0x1e8)]===_0x1488bd);if(_0x234dec[_0x5243ea(0x1f1)]===0x0)throw CliErrors['validation'](_0x5243ea(0x1d6)+_0x27d159+'/'+_0x1488bd);return _0x234dec;}return _0x330b0d;}function existingHookWarning(_0x4719e7){const _0x48f89b=a44_0xad0615;return{'code':_0x48f89b(0x1b8),'lockKey':_0x4719e7,'message':_0x48f89b(0x1fc)};}async function buildHookMaps(_0x4e2b8f,_0x2624d1,_0x272340,_0x18d400,_0x3bbf26){const _0x199866=a44_0xad0615,_0x17c5a0=_0x272340[_0x199866(0x223)](_0x3f0f24=>_0x3f0f24[_0x199866(0x22b)]==='HOOK');if(!_0x17c5a0)return{'resolutions':new Map(),'failures':new Map(),'existingHooks':new Set()};const _0x2d6e2e=resolveApiModelSource(_0x2624d1,_0x4e2b8f,_0x3bbf26),_0x1ce584=loadAliasMap(_0x2624d1,undefined,_0x2d6e2e['filePath'],_0x2d6e2e[_0x199866(0x1d3)]);assertUnambiguousHookAliases(_0x1ce584);const _0x54c25c=[..._0x1ce584[_0x199866(0x1c6)](_0x525ebc=>[_0x525ebc[_0x199866(0x1e6)],_0x525ebc[_0x199866(0x1d9)]]),...trackedHookDirectoryMappings(_0x18d400)[_0x199866(0x1c6)](_0x4fafe8=>[_0x4fafe8[_0x199866(0x1e6)],_0x4fafe8[_0x199866(0x1d9)]])],_0x3077b7=await listDatasets(_0x4e2b8f);assertUnambiguousHookDirectoryMappings(_0x54c25c[_0x199866(0x1c6)](([_0x41f303,_0x13f596])=>({'alias':_0x41f303,'datasetCode':_0x13f596})));const _0x348128=buildHookDirectoryIndexes(_0x3077b7,_0x54c25c),_0x3c9795=new Map(),_0x57af78=preflightPushHookDirectories(_0x272340,_0x18d400,_0x348128,_0x3c9795),_0x3a5b80=new Set(),_0x373b2d=_0x272340['filter'](_0x16a75a=>_0x3c9795[_0x199866(0x226)](_0x16a75a[_0x199866(0x1f3)])?.[_0x199866(0x1d7)](_0x199866(0x1ee))&&_0x18d400[_0x199866(0x1e4)][_0x16a75a[_0x199866(0x1f3)]]?.[_0x199866(0x1fa)]&&_0x18d400[_0x199866(0x1e4)][_0x16a75a[_0x199866(0x1f3)]]?.[_0x199866(0x1d9)]);if(_0x373b2d[_0x199866(0x1f1)]>0x0){let _0x445a60;try{_0x445a60=await getBffScriptStatistics(_0x4e2b8f);}catch(_0x317dd4){for(const _0x4ace7d of _0x373b2d)_0x3c9795['set'](_0x4ace7d[_0x199866(0x1f3)],_0x199866(0x207)+(_0x317dd4 instanceof Error?_0x317dd4[_0x199866(0x1df)]:String(_0x317dd4)));return{'resolutions':_0x57af78,'failures':_0x3c9795,'existingHooks':_0x3a5b80};}for(const _0x15e312 of _0x373b2d){const _0x1af62c=_0x18d400[_0x199866(0x1e4)][_0x15e312['lockKey']];try{const _0xb71ffd=new Set(_0x272340[_0x199866(0x1d5)](_0x2f18b7=>_0x2f18b7[_0x199866(0x22b)]===_0x199866(0x21b)&&_0x18d400[_0x199866(0x1e4)][_0x2f18b7['lockKey']]?.['datasetCode']===_0x1af62c[_0x199866(0x1d9)])[_0x199866(0x1c6)](_0x20fe21=>_0x20fe21[_0x199866(0x1e6)]));if(_0xb71ffd[_0x199866(0x1c8)]>0x1)throw CliErrors[_0x199866(0x1ba)](_0x199866(0x20a));const _0x3a6a08=_0x445a60[_0x199866(0x210)](_0x26f7a2=>[{'datasetCode':_0x26f7a2['datasetCode'],'operationType':snakeToCamel(_0x26f7a2[_0x199866(0x1ed)]),'functionNode':_0x199866(0x1ce),'id':_0x26f7a2[_0x199866(0x227)]},{'datasetCode':_0x26f7a2['datasetCode'],'operationType':snakeToCamel(_0x26f7a2['operationType']),'functionNode':'after','id':_0x26f7a2[_0x199866(0x1c2)]}])[_0x199866(0x1d5)](_0x31f27d=>_0x31f27d['id']===_0x1af62c[_0x199866(0x1fa)]),_0x68a49b=await getBffScriptInfo(_0x1af62c[_0x199866(0x1fa)]);if(_0x68a49b['id']!==_0x1af62c['remoteId']||_0x68a49b[_0x199866(0x1fd)]!==_0x4e2b8f||_0x68a49b[_0x199866(0x1e5)]!==_0x199866(0x21b)||_0x68a49b[_0x199866(0x1ca)]!==_0x15e312[_0x199866(0x1e8)]||_0x1af62c['version']==null||_0x68a49b[_0x199866(0x1ef)]!==_0x1af62c['version']||_0x3a6a08[_0x199866(0x1f1)]!==0x1||_0x3a6a08[0x0]['datasetCode']!==_0x1af62c[_0x199866(0x1d9)]||_0x3a6a08[0x0][_0x199866(0x1ed)]!==_0x15e312[_0x199866(0x1ed)]||_0x3a6a08[0x0][_0x199866(0x20d)]!==_0x15e312[_0x199866(0x20d)]||_0x1af62c[_0x199866(0x1ed)]!==_0x15e312[_0x199866(0x1ed)]||_0x1af62c['functionNode']!==_0x15e312['functionNode'])throw CliErrors['validation'](_0x199866(0x20e));_0x3a5b80[_0x199866(0x21e)](_0x15e312['lockKey']),_0x3c9795[_0x199866(0x211)](_0x15e312[_0x199866(0x1f3)]);}catch(_0x1421b3){_0x3c9795[_0x199866(0x1d4)](_0x15e312[_0x199866(0x1f3)],_0x1421b3 instanceof Error?_0x1421b3[_0x199866(0x1df)]:String(_0x1421b3));}}}return{'resolutions':_0x57af78,'failures':_0x3c9795,'existingHooks':_0x3a5b80};}async function uploadSingleFunction(_0x41082a,_0x252b88,_0xcae50b,_0x504c0e){const _0x818bb1=a44_0xad0615,_0x20081f=await readFile(_0x252b88[_0x818bb1(0x1de)],_0x818bb1(0x1b9)),_0x5ac78e=await computeFileHash(_0x252b88[_0x818bb1(0x1de)]),_0x11d353=_0xcae50b[_0x818bb1(0x1e4)][_0x252b88['lockKey']];if(_0x11d353?.[_0x818bb1(0x1fa)]&&_0x11d353[_0x818bb1(0x1ef)]==null)throw CliErrors[_0x818bb1(0x1ba)](_0x252b88[_0x818bb1(0x1f3)]+_0x818bb1(0x216));let _0x20e499=extractScriptDescription(_0x20081f);if(!_0x20e499&&_0x11d353?.['remoteId']){const _0x437872=await getBffScriptInfo(_0x11d353['remoteId']);_0x20e499=_0x437872[_0x818bb1(0x1c4)]||undefined;}const _0x1413f1={'appCode':_0x41082a,'functionName':_0x252b88[_0x818bb1(0x1e8)],'scriptType':_0x252b88[_0x818bb1(0x22b)],'scriptContent':_0x20081f};if(_0x11d353?.['remoteId'])_0x1413f1['id']=_0x11d353[_0x818bb1(0x1fa)];if(_0x11d353?.[_0x818bb1(0x1ef)]!=null)_0x1413f1[_0x818bb1(0x1ef)]=_0x11d353[_0x818bb1(0x1ef)];if(_0x20e499)_0x1413f1[_0x818bb1(0x1c4)]=_0x20e499;if(_0x252b88[_0x818bb1(0x22b)]==='HOOK'){const _0x43ed73=_0x504c0e['resolutions'][_0x818bb1(0x226)](_0x252b88[_0x818bb1(0x1f3)]);if(!_0x43ed73&&!_0x504c0e['existingHooks'][_0x818bb1(0x1b7)](_0x252b88[_0x818bb1(0x1f3)])||!_0x252b88[_0x818bb1(0x1ed)]||!_0x252b88[_0x818bb1(0x20d)])throw CliErrors['validation'](_0x818bb1(0x1f7)+_0x252b88[_0x818bb1(0x1f3)]);_0x43ed73&&(_0x1413f1[_0x818bb1(0x1f2)]=_0x43ed73[_0x818bb1(0x1c9)]['id'],_0x1413f1[_0x818bb1(0x1ed)]=_0x252b88[_0x818bb1(0x1ed)]),_0x1413f1[_0x818bb1(0x20d)]=_0x252b88[_0x818bb1(0x20d)];}const _0x4d3495=await saveBffScript(_0x1413f1),_0x3b295a=_0x4d3495['id'],_0x364f97=_0x4d3495[_0x818bb1(0x1cf)]??await getBffScriptInfo(_0x3b295a),_0x12c99d={'hash':_0x5ac78e,'remoteId':_0x3b295a,'version':_0x364f97[_0x818bb1(0x1ef)]};if(_0x252b88[_0x818bb1(0x22b)]===_0x818bb1(0x21b)){const _0x556d1a=_0x504c0e[_0x818bb1(0x1c5)][_0x818bb1(0x226)](_0x252b88[_0x818bb1(0x1f3)]);if(!_0x556d1a){_0xcae50b[_0x818bb1(0x1e4)][_0x252b88[_0x818bb1(0x1f3)]]={..._0x11d353,..._0x12c99d};return;}_0x12c99d[_0x818bb1(0x1e6)]=_0x556d1a[_0x818bb1(0x1e6)]??_0x11d353?.[_0x818bb1(0x1e6)],_0x12c99d[_0x818bb1(0x1d9)]=_0x556d1a['datasetCode'],_0x12c99d[_0x818bb1(0x1ed)]=_0x252b88[_0x818bb1(0x1ed)],_0x12c99d[_0x818bb1(0x20d)]=_0x252b88[_0x818bb1(0x20d)];}_0xcae50b[_0x818bb1(0x1e4)][_0x252b88[_0x818bb1(0x1f3)]]=_0x12c99d;}const LOCK_SETTLE_RETRY_COUNT=0x14,LOCK_SETTLE_DELAY_MS=0x64;async function waitForUploadedLockEntries(_0x16b99b,_0x15fac8,_0x2cc9f0){const _0x1f9fc7=a44_0xad0615;if(_0x2cc9f0[_0x1f9fc7(0x1f1)]===0x0)return;for(let _0x1b8dfa=0x0;_0x1b8dfa<LOCK_SETTLE_RETRY_COUNT;_0x1b8dfa+=0x1){const _0x13eed1=await readBffLockFile(_0x16b99b),_0x545abe=_0x13eed1?.['apps']?.[_0x15fac8]?.['functions']??{},_0x59d6f7=_0x2cc9f0[_0x1f9fc7(0x205)](_0x2ea208=>!!_0x545abe[_0x2ea208]?.[_0x1f9fc7(0x1fa)]);if(_0x59d6f7)return;await sleep(LOCK_SETTLE_DELAY_MS);}throw new Error(_0x1f9fc7(0x20c)+_0x2cc9f0['join'](',\x20')+'.');}
|
|
1
|
+
const a44_0x1c3065=a44_0x529e;(function(_0x4d03d1,_0x5975dd){const _0x29400c=a44_0x529e,_0x7d28b7=_0x4d03d1();while(!![]){try{const _0x32469c=parseInt(_0x29400c(0x118))/0x1+-parseInt(_0x29400c(0x129))/0x2*(-parseInt(_0x29400c(0x133))/0x3)+parseInt(_0x29400c(0xe6))/0x4*(-parseInt(_0x29400c(0xd5))/0x5)+parseInt(_0x29400c(0xe5))/0x6*(parseInt(_0x29400c(0xdb))/0x7)+-parseInt(_0x29400c(0xea))/0x8+-parseInt(_0x29400c(0xe8))/0x9+parseInt(_0x29400c(0x120))/0xa*(parseInt(_0x29400c(0xf0))/0xb);if(_0x32469c===_0x5975dd)break;else _0x7d28b7['push'](_0x7d28b7['shift']());}catch(_0x16d8fc){_0x7d28b7['push'](_0x7d28b7['shift']());}}}(a44_0x3e74,0xf2edc));import{readFile}from'node:fs/promises';import{saveBffScript,getBffScriptInfo,getBffScriptStatistics,getPlatformErrorCode,listDatasets,clearBffScriptCache}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';import{resolveApiModelSource}from'../../api/model-source.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{normalizeBffType,scanLocalBffFunctions}from'../../core/bff/file-system.js';import{buildHookDirectoryIndexes,assertUnambiguousHookAliases,assertUnambiguousHookDirectoryMappings,preflightPushHookDirectories,trackedHookDirectoryMappings}from'../../core/bff/hook-directory.js';import{computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile,writeBffLockFile}from'../../core/bff/lock.js';import{extractScriptDescription,snakeToCamel}from'../../core/bff/utils.js';import{sleep}from'../../utils/sleep.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{CliErrors}from'../../errors.js';const CACHE_CLEAR_ATTEMPTS=0x2,CACHE_CLEAR_INTERVAL_MS=0x12c;export const bffPush={'service':a44_0x1c3065(0x104),'command':a44_0x1c3065(0x100),'description':a44_0x1c3065(0xe4),'risk':'write','structuredErrors':!![],'flags':[{'name':a44_0x1c3065(0xcf),'type':a44_0x1c3065(0x110),'description':a44_0x1c3065(0xfc),'enum':[a44_0x1c3065(0xdf),a44_0x1c3065(0xe9),'HOOK']},{'name':a44_0x1c3065(0xeb),'type':a44_0x1c3065(0x110),'description':a44_0x1c3065(0xee)},{'name':a44_0x1c3065(0x130),'type':'boolean','description':a44_0x1c3065(0xcb)}],async 'dryRun'(_0x25bd26){const _0x5c0245=a44_0x1c3065,_0x2d843f=loadBffProjectConfig(_0x25bd26['appCode']),_0x522aed=await readBffLockFile(_0x2d843f['lockFilePath']),{appLock:_0x1a082a}=ensureLockScope(_0x522aed??createEmptyBffLock(),_0x25bd26[_0x5c0245(0x108)],_0x2d843f[_0x5c0245(0x136)],_0x5c0245(0x100)),_0x25b0c0=await getTargetFunctions(_0x2d843f,_0x25bd26),_0x39ba58=_0x25b0c0[_0x5c0245(0x119)](_0x3caa0d=>_0x3caa0d['type']===_0x5c0245(0x122))?await scanLocalBffFunctions(_0x2d843f,'HOOK'):_0x25b0c0,_0x311808=await buildHookMaps(_0x25bd26[_0x5c0245(0x108)],_0x25bd26[_0x5c0245(0x10f)],_0x39ba58,_0x1a082a,_0x25bd26[_0x5c0245(0x103)]||_0x25bd26[_0x5c0245(0xfb)]?.[_0x5c0245(0x121)]||_0x25bd26[_0x5c0245(0xfb)]?.[_0x5c0245(0xd9)]),_0x2922bd=_0x25bd26['bool'](_0x5c0245(0x130)),_0x28ad02=[];for(const _0x4cf460 of _0x25b0c0){const _0xf6def2=await computeFileHash(_0x4cf460['filePath']),_0x10b170=_0x1a082a[_0x5c0245(0xce)][_0x4cf460[_0x5c0245(0xde)]],_0x421864=!!_0x10b170&&_0x10b170[_0x5c0245(0xe1)]===_0xf6def2,_0x27def8=_0x311808[_0x5c0245(0x109)]['get'](_0x4cf460[_0x5c0245(0xde)]),_0x8cd2ec=!!_0x10b170?.[_0x5c0245(0xf6)]&&_0x10b170[_0x5c0245(0xef)]==null&&(_0x2922bd||!_0x421864),_0x22e7fa=_0x8cd2ec?missingRemoteVersionConflict(_0x4cf460,_0x10b170):undefined,_0x269da3=_0x311808[_0x5c0245(0xd3)][_0x5c0245(0x116)](_0x4cf460[_0x5c0245(0xde)])?_0x5c0245(0x106):!_0x2922bd&&_0x421864?_0x5c0245(0x126):_0x22e7fa?'conflict':_0x5c0245(0x11c);_0x28ad02[_0x5c0245(0x100)]({'lockKey':_0x4cf460[_0x5c0245(0xde)],'filePath':_0x4cf460[_0x5c0245(0x137)],'remoteId':_0x10b170?.[_0x5c0245(0xf6)]??null,'mode':_0x10b170?.[_0x5c0245(0xf6)]?_0x5c0245(0x105):_0x5c0245(0x11f),'status':_0x269da3,..._0x311808[_0x5c0245(0xd3)][_0x5c0245(0x116)](_0x4cf460[_0x5c0245(0xde)])?{'error':_0x311808[_0x5c0245(0xd3)][_0x5c0245(0xcc)](_0x4cf460[_0x5c0245(0xde)])}:{},..._0x22e7fa?{'conflict':_0x22e7fa}:{},..._0x311808[_0x5c0245(0x135)][_0x5c0245(0x116)](_0x4cf460['lockKey'])?{'datasetCode':_0x10b170?.[_0x5c0245(0x13b)],'bindingPreserved':!![],'warnings':[existingHookWarning(_0x4cf460[_0x5c0245(0xde)])]}:{},..._0x27def8?{'alias':_0x27def8[_0x5c0245(0x11e)]??null,'datasetCode':_0x27def8['datasetCode'],'operationType':_0x4cf460[_0x5c0245(0xf1)],'functionNode':_0x4cf460[_0x5c0245(0xd4)],'warnings':_0x27def8['warnings']}:{}});}return{'method':_0x5c0245(0xf2),'url':_0x5c0245(0x115),'body':{'appCode':_0x25bd26['appCode'],'force':_0x2922bd,'files':_0x28ad02,'cacheClearAtRuntime':_0x28ad02[_0x5c0245(0x119)](_0x2f3030=>_0x2f3030[_0x5c0245(0x10a)]===_0x5c0245(0x11c)),'cacheClearAtRuntimeTimes':_0x28ad02[_0x5c0245(0x119)](_0x14f0d9=>_0x14f0d9['status']===_0x5c0245(0x11c))?CACHE_CLEAR_ATTEMPTS:0x0},'description':_0x5c0245(0x117)+_0x28ad02[_0x5c0245(0xfd)]+'\x20local\x20Backend\x20Function\x20script(s)\x20for\x20push\x20and\x20clear\x20runtime\x20cache\x20if\x20files\x20are\x20uploaded'};},async 'execute'(_0x2ffbf4){const _0x270509=a44_0x1c3065,_0x2f7422=loadBffProjectConfig(_0x2ffbf4[_0x270509(0x108)]),_0x7bf914=await readBffLockFile(_0x2f7422[_0x270509(0xd2)]),{lockData:_0x29fb03,appLock:_0x511b1b}=ensureLockScope(_0x7bf914??createEmptyBffLock(),_0x2ffbf4['appCode'],_0x2f7422[_0x270509(0x136)],_0x270509(0x100)),_0x3d000e=await getTargetFunctions(_0x2f7422,_0x2ffbf4);if(_0x3d000e[_0x270509(0xfd)]===0x0)return{'ok':!![],'data':{'uploaded':[],'skipped':[],'conflicts':[],'failed':[]},'message':_0x270509(0xd1)};const _0x2e943e=_0x2ffbf4['bool'](_0x270509(0x130)),_0x555c90=JSON[_0x270509(0x128)](JSON[_0x270509(0x12b)](_0x29fb03)),_0x7df380=_0x555c90[_0x270509(0x12e)][_0x2ffbf4[_0x270509(0x108)]];if(!_0x7df380)throw new Error(_0x270509(0x13d)+_0x2ffbf4[_0x270509(0x108)]+'\x22\x20not\x20found\x20after\x20ensureLockScope.');const _0x71a833=_0x3d000e[_0x270509(0x119)](_0x27d5b4=>_0x27d5b4[_0x270509(0xcf)]===_0x270509(0x122))?await scanLocalBffFunctions(_0x2f7422,_0x270509(0x122)):_0x3d000e,_0x3c47a3=await buildHookMaps(_0x2ffbf4[_0x270509(0x108)],_0x2ffbf4[_0x270509(0x10f)],_0x71a833,_0x7df380,_0x2ffbf4[_0x270509(0x103)]||_0x2ffbf4['mergedCli']?.[_0x270509(0x121)]||_0x2ffbf4['mergedCli']?.[_0x270509(0xd9)]),_0x46366c=[],_0xeab10e=[],_0x14e7d1=[],_0x553085=[];for(const _0x560106 of _0x3d000e){const _0x3461d5=_0x3c47a3[_0x270509(0xd3)][_0x270509(0xcc)](_0x560106[_0x270509(0xde)]);if(_0x3461d5){_0x553085[_0x270509(0x100)]({'lockKey':_0x560106['lockKey'],'error':_0x3461d5});continue;}const _0x3949c6=await computeFileHash(_0x560106[_0x270509(0x137)]),_0x57a16a=_0x7df380[_0x270509(0xce)][_0x560106[_0x270509(0xde)]];if(!_0x2e943e&&_0x57a16a&&_0x57a16a[_0x270509(0xe1)]===_0x3949c6){_0xeab10e['push']({'lockKey':_0x560106[_0x270509(0xde)],'reason':_0x270509(0x126)});continue;}if(_0x57a16a?.[_0x270509(0xf6)]&&_0x57a16a[_0x270509(0xef)]==null){_0x14e7d1[_0x270509(0x100)](missingRemoteVersionConflict(_0x560106,_0x57a16a));continue;}try{await uploadSingleFunction(_0x2ffbf4[_0x270509(0x108)],_0x560106,_0x7df380,_0x3c47a3);const _0xa9738c=_0x7df380[_0x270509(0xce)][_0x560106[_0x270509(0xde)]];_0x46366c[_0x270509(0x100)]({'lockKey':_0x560106[_0x270509(0xde)],'remoteId':_0xa9738c?.[_0x270509(0xf6)]??0x0});}catch(_0x536189){const _0x1da99f=remoteVersionChangedConflict(_0x560106,_0x57a16a,_0x536189);if(_0x1da99f){_0x14e7d1[_0x270509(0x100)](_0x1da99f);continue;}_0x553085[_0x270509(0x100)]({'lockKey':_0x560106[_0x270509(0xde)],'error':_0x536189 instanceof Error?_0x536189[_0x270509(0x10c)]:String(_0x536189)});}}_0x7df380[_0x270509(0xfe)]=new Date()[_0x270509(0xdd)](),await writeBffLockFile(_0x2f7422[_0x270509(0xd2)],_0x555c90),await waitForUploadedLockEntries(_0x2f7422['lockFilePath'],_0x2ffbf4['appCode'],_0x46366c['map'](_0x1baba9=>_0x1baba9[_0x270509(0xde)]));let _0x5a4795={'attempted':![],'cleared':![]};if(_0x46366c[_0x270509(0xfd)]>0x0)try{let _0x43820e='';for(let _0x1f25b2=0x0;_0x1f25b2<CACHE_CLEAR_ATTEMPTS;_0x1f25b2+=0x1){_0x43820e=await clearBffScriptCache(),_0x1f25b2<CACHE_CLEAR_ATTEMPTS-0x1&&await sleep(CACHE_CLEAR_INTERVAL_MS);}_0x5a4795={'attempted':!![],'cleared':!![],'message':_0x43820e||'Runtime\x20script\x20cache\x20cleared.'};}catch(_0x748f5b){_0x5a4795={'attempted':!![],'cleared':![],'error':_0x748f5b instanceof Error?_0x748f5b['message']:String(_0x748f5b)};}const _0x427533=_0x553085['length']===0x0&&(_0x5a4795[_0x270509(0x13a)]?_0x5a4795[_0x270509(0xe3)]:!![]),_0x41e5d3=_0x427533,_0x26f64e=_0x5a4795[_0x270509(0x13a)]?_0x5a4795[_0x270509(0xe3)]?_0x270509(0xdc):_0x270509(0x101):_0x270509(0x111);return{'ok':_0x41e5d3,'data':{'uploaded':_0x46366c,'skipped':_0xeab10e,'conflicts':_0x14e7d1,'failed':_0x553085,'cacheClear':_0x5a4795,'warnings':[...[..._0x3c47a3[_0x270509(0x109)][_0x270509(0x11b)]()][_0x270509(0xe2)](_0x401279=>_0x401279[_0x270509(0x12d)]),...[..._0x3c47a3[_0x270509(0x135)]][_0x270509(0xf4)](existingHookWarning)]},'message':formatPushMessage(_0x46366c[_0x270509(0xfd)],_0xeab10e[_0x270509(0xfd)],_0x14e7d1[_0x270509(0xfd)],_0x553085[_0x270509(0xfd)],_0x26f64e)};}};function missingRemoteVersionConflict(_0x31ec8c,_0x1c5aa1){const _0x55f064=a44_0x1c3065;return remoteVersionConflict(_0x31ec8c,_0x1c5aa1,_0x55f064(0xd6),'The\x20local\x20sync\x20lock\x20has\x20no\x20remote\x20version\x20for\x20this\x20script.');}function remoteVersionChangedConflict(_0x474f6c,_0xd5a32,_0x4b521e){const _0xaff146=a44_0x1c3065;if(!_0xd5a32?.[_0xaff146(0xf6)]||_0xd5a32[_0xaff146(0xef)]==null||!isRemoteVersionConflict(_0x4b521e))return undefined;return remoteVersionConflict(_0x474f6c,_0xd5a32,_0xaff146(0x123),_0xaff146(0xd0));}function remoteVersionConflict(_0x5c6900,_0x3f2efa,_0x1b36fa,_0x26d028){const _0x5110d2=a44_0x1c3065;return{'code':_0x1b36fa,'lockKey':_0x5c6900[_0x5110d2(0xde)],'filePath':_0x5c6900[_0x5110d2(0x137)],'remoteId':_0x3f2efa[_0x5110d2(0xf6)],..._0x3f2efa[_0x5110d2(0xef)]!=null?{'expectedVersion':_0x3f2efa['version']}:{},'message':_0x26d028,'nextAction':{'action':_0x5110d2(0xfa),'command':CLI_BIN_NAME+'\x20bff\x20detail\x20--id\x20'+_0x3f2efa[_0x5110d2(0xf6)]+_0x5110d2(0x131),'requiresReview':!![],'message':_0x5110d2(0x138)}};}function isRemoteVersionConflict(_0x2b2363){const _0xe6fc6b=a44_0x1c3065,_0x43c65a=_0x2b2363 instanceof Error?_0x2b2363[_0xe6fc6b(0x10c)]:String(_0x2b2363),_0x393b7f=getPlatformErrorCode(_0x2b2363)??'';return[_0x43c65a,_0x393b7f][_0xe6fc6b(0x119)](_0xcc2b85=>/(?:version|optimistic)[\s_-]*(?:conflict|mismatch|changed|stale|out[\s_-]*of[\s_-]*date)|(?:conflict|mismatch|changed|stale|out[\s_-]*of[\s_-]*date)[\s_-]*(?:version|optimistic)/i[_0xe6fc6b(0x10b)](_0xcc2b85));}function formatPushMessage(_0x28e726,_0x5bb011,_0x258d4d,_0x2befe4,_0x4897cf){const _0x30c59c=a44_0x1c3065,_0x1baa8c=[_0x30c59c(0xcd)+_0x28e726+_0x30c59c(0x12a),_0x5bb011+_0x30c59c(0xec)];_0x258d4d>0x0&&_0x1baa8c['push'](_0x258d4d+_0x30c59c(0x11a)+(_0x258d4d===0x1?'':'s')+'\x20'+(_0x258d4d===0x1?_0x30c59c(0x11d):_0x30c59c(0xe7))+_0x30c59c(0x13c));if(_0x2befe4>0x0)_0x1baa8c[_0x30c59c(0x100)](_0x2befe4+'\x20failed');return _0x1baa8c[_0x30c59c(0x100)](_0x4897cf),_0x1baa8c['join'](',\x20');}async function getTargetFunctions(_0x14485e,_0x28a473){const _0x4e9ce8=a44_0x1c3065,_0x67d1b5=_0x28a473['str'](_0x4e9ce8(0xcf)),_0x1d8d6c=_0x28a473['str'](_0x4e9ce8(0xeb)),_0x1aaed6=normalizeBffType(_0x67d1b5)??undefined;if(_0x1d8d6c&&!_0x1aaed6)throw CliErrors['validation'](_0x4e9ce8(0xf3));const _0xee6fab=await scanLocalBffFunctions(_0x14485e,_0x1aaed6);if(_0x1d8d6c){const _0x41033c=_0xee6fab[_0x4e9ce8(0x125)](_0x145706=>_0x145706[_0x4e9ce8(0xeb)]===_0x1d8d6c);if(_0x41033c[_0x4e9ce8(0xfd)]===0x0)throw CliErrors[_0x4e9ce8(0x139)](_0x4e9ce8(0xf9)+_0x1aaed6+'/'+_0x1d8d6c);return _0x41033c;}return _0xee6fab;}function a44_0x529e(_0x2b2e83,_0x5e7ba3){_0x2b2e83=_0x2b2e83-0xcb;const _0x3e7451=a44_0x3e74();let _0x529e7a=_0x3e7451[_0x2b2e83];return _0x529e7a;}function existingHookWarning(_0x144365){const _0x3612ef=a44_0x1c3065;return{'code':_0x3612ef(0x112),'lockKey':_0x144365,'message':_0x3612ef(0x113)};}async function buildHookMaps(_0x43a4d8,_0xf0582b,_0x2a275f,_0x230e7b,_0x1172d7){const _0x43f881=a44_0x1c3065,_0x1f4f5f=_0x2a275f[_0x43f881(0x119)](_0x136627=>_0x136627[_0x43f881(0xcf)]===_0x43f881(0x122));if(!_0x1f4f5f)return{'resolutions':new Map(),'failures':new Map(),'existingHooks':new Set()};const _0x505bef=resolveApiModelSource(_0xf0582b,_0x43a4d8,_0x1172d7),_0x36c245=loadAliasMap(_0xf0582b,undefined,_0x505bef[_0x43f881(0x137)],_0x505bef[_0x43f881(0xed)]);assertUnambiguousHookAliases(_0x36c245);const _0x5288b4=[..._0x36c245['map'](_0xb10e38=>[_0xb10e38['alias'],_0xb10e38['datasetCode']]),...trackedHookDirectoryMappings(_0x230e7b)[_0x43f881(0xf4)](_0x527b92=>[_0x527b92[_0x43f881(0x11e)],_0x527b92[_0x43f881(0x13b)]])],_0x16958b=await listDatasets(_0x43a4d8);assertUnambiguousHookDirectoryMappings(_0x5288b4[_0x43f881(0xf4)](([_0x4d6bce,_0x3399ef])=>({'alias':_0x4d6bce,'datasetCode':_0x3399ef})));const _0x2ab01b=buildHookDirectoryIndexes(_0x16958b,_0x5288b4),_0x131178=new Map(),_0x145933=preflightPushHookDirectories(_0x2a275f,_0x230e7b,_0x2ab01b,_0x131178),_0x13298a=new Set(),_0x4b6048=_0x2a275f['filter'](_0x3d750c=>_0x131178['get'](_0x3d750c[_0x43f881(0xde)])?.[_0x43f881(0xf5)](_0x43f881(0x10e))&&_0x230e7b[_0x43f881(0xce)][_0x3d750c['lockKey']]?.[_0x43f881(0xf6)]&&_0x230e7b[_0x43f881(0xce)][_0x3d750c[_0x43f881(0xde)]]?.[_0x43f881(0x13b)]);if(_0x4b6048[_0x43f881(0xfd)]>0x0){let _0x206244;try{_0x206244=await getBffScriptStatistics(_0x43a4d8);}catch(_0x1ffeac){for(const _0x508b84 of _0x4b6048)_0x131178[_0x43f881(0xf7)](_0x508b84[_0x43f881(0xde)],_0x43f881(0x114)+(_0x1ffeac instanceof Error?_0x1ffeac[_0x43f881(0x10c)]:String(_0x1ffeac)));return{'resolutions':_0x145933,'failures':_0x131178,'existingHooks':_0x13298a};}for(const _0x52fc45 of _0x4b6048){const _0x178c17=_0x230e7b[_0x43f881(0xce)][_0x52fc45[_0x43f881(0xde)]];try{const _0x3a1cc1=new Set(_0x2a275f['filter'](_0x5bda1c=>_0x5bda1c[_0x43f881(0xcf)]===_0x43f881(0x122)&&_0x230e7b[_0x43f881(0xce)][_0x5bda1c[_0x43f881(0xde)]]?.['datasetCode']===_0x178c17[_0x43f881(0x13b)])['map'](_0x483935=>_0x483935[_0x43f881(0x11e)]));if(_0x3a1cc1[_0x43f881(0xe0)]>0x1)throw CliErrors[_0x43f881(0x139)](_0x43f881(0xd7));const _0x2a08ce=_0x206244[_0x43f881(0xe2)](_0x4eb74b=>[{'datasetCode':_0x4eb74b['datasetCode'],'operationType':snakeToCamel(_0x4eb74b['operationType']),'functionNode':_0x43f881(0x107),'id':_0x4eb74b[_0x43f881(0xda)]},{'datasetCode':_0x4eb74b[_0x43f881(0x13b)],'operationType':snakeToCamel(_0x4eb74b[_0x43f881(0xf1)]),'functionNode':_0x43f881(0x12f),'id':_0x4eb74b[_0x43f881(0x124)]}])[_0x43f881(0x125)](_0x171e55=>_0x171e55['id']===_0x178c17[_0x43f881(0xf6)]),_0xacb4b5=await getBffScriptInfo(_0x178c17['remoteId']);if(_0xacb4b5['id']!==_0x178c17[_0x43f881(0xf6)]||_0xacb4b5[_0x43f881(0x108)]!==_0x43a4d8||_0xacb4b5[_0x43f881(0x102)]!=='HOOK'||_0xacb4b5[_0x43f881(0x127)]!==_0x52fc45[_0x43f881(0xeb)]||_0x178c17[_0x43f881(0xef)]==null||_0xacb4b5[_0x43f881(0xef)]!==_0x178c17[_0x43f881(0xef)]||_0x2a08ce['length']!==0x1||_0x2a08ce[0x0][_0x43f881(0x13b)]!==_0x178c17[_0x43f881(0x13b)]||_0x2a08ce[0x0][_0x43f881(0xf1)]!==_0x52fc45[_0x43f881(0xf1)]||_0x2a08ce[0x0][_0x43f881(0xd4)]!==_0x52fc45[_0x43f881(0xd4)]||_0x178c17[_0x43f881(0xf1)]!==_0x52fc45[_0x43f881(0xf1)]||_0x178c17[_0x43f881(0xd4)]!==_0x52fc45[_0x43f881(0xd4)])throw CliErrors[_0x43f881(0x139)](_0x43f881(0x12c));_0x13298a[_0x43f881(0x10d)](_0x52fc45['lockKey']),_0x131178['delete'](_0x52fc45[_0x43f881(0xde)]);}catch(_0x20063f){_0x131178['set'](_0x52fc45[_0x43f881(0xde)],_0x20063f instanceof Error?_0x20063f[_0x43f881(0x10c)]:String(_0x20063f));}}}return{'resolutions':_0x145933,'failures':_0x131178,'existingHooks':_0x13298a};}function a44_0x3e74(){const _0x52b059=['7380COHIyU','BFF_REMOTE_VERSION_MISSING','Multiple\x20HOOK\x20directories\x20reference\x20the\x20same\x20missing\x20Dataset.\x20Resolve\x20duplicate\x20directories\x20before\x20pushing.','datasetId','defaultApp','beforeScriptId','5868303XeYhPz','runtime\x20cache\x20cleared','toISOString','lockKey','COMMON','size','hash','flatMap','cleared','Push\x20local\x20Backend\x20Function\x20scripts\x20to\x20remote','6APnjvl','4508reaMor','require','6935463rOMseI','ENDPOINT','1150152uWZQtZ','name','\x20skipped','profileName','Push\x20only\x20the\x20named\x20function\x20(requires\x20--type)','version','9386223IyUzTJ','operationType','POST','--name\x20requires\x20--type\x20to\x20identify\x20the\x20function.','map','startsWith','remoteId','set','Lock\x20file\x20not\x20settled\x20after\x20push\x20for\x20','Local\x20function\x20not\x20found:\x20','review_remote_and_merge','mergedCli','Push\x20only\x20this\x20script\x20type','length','lastSync','description','push','runtime\x20cache\x20clear\x20failed','scriptType','selectedAppName','bff','update','failed','before','appCode','resolutions','status','test','message','add','HOOK_DATASET_NOT_FOUND:','apiDir','string','runtime\x20cache\x20not\x20needed','EXISTING_HOOK_BINDING_PRESERVED','Dataset\x20metadata\x20is\x20unavailable;\x20the\x20existing\x20script\x20and\x20binding\x20were\x20verified.\x20Update\x20by\x20script\x20ID\x20without\x20rebinding.','Cannot\x20verify\x20existing\x20HOOK\x20binding:\x20','/api/management/library/scripts/save','has','Would\x20inspect\x20','118495Hyralg','some','\x20conflict','values','would_push','requires','alias','create','30fkGtoM','currentApp','HOOK','BFF_REMOTE_VERSION_CHANGED','afterScriptId','filter','unchanged','functionName','parse','16046RfHkjP','\x20uploaded','stringify','Existing\x20HOOK\x20identity,\x20version\x20or\x20binding\x20does\x20not\x20match\x20the\x20local\x20lock.\x20Pull\x20and\x20review\x20before\x20pushing.','warnings','apps','after','force','\x20--format\x20compress','script','21VQPnqu','Incomplete\x20HOOK\x20path:\x20','existingHooks','scriptsRoot','filePath','Review\x20the\x20current\x20remote\x20source,\x20merge\x20it\x20into\x20the\x20local\x20script,\x20then\x20retry\x20push.\x20Do\x20not\x20use\x20--force\x20unless\x20you\x20intentionally\x20discard\x20local\x20changes.','validation','attempted','datasetCode','\x20resolution','Lock\x20scope\x20for\x20app\x20\x22',':\x20missing\x20remote\x20version.\x20Run\x20`push`\x20after\x20`pull`\x20to\x20sync\x20version\x20info.','dataset','Force\x20push\x20ignoring\x20hash\x20protection','get','Push\x20complete:\x20','functions','type','Remote\x20script\x20version\x20changed\x20since\x20the\x20last\x20pull.','No\x20local\x20Backend\x20Function\x20scripts\x20found.','lockFilePath','failures','functionNode'];a44_0x3e74=function(){return _0x52b059;};return a44_0x3e74();}async function uploadSingleFunction(_0x4b724e,_0x1c35c3,_0x214b38,_0x3b3613){const _0x2e79d4=a44_0x1c3065,_0x2dab4c=await readFile(_0x1c35c3[_0x2e79d4(0x137)],'utf8'),_0x529d95=await computeFileHash(_0x1c35c3['filePath']),_0x26ba8a=_0x214b38['functions'][_0x1c35c3[_0x2e79d4(0xde)]];if(_0x26ba8a?.[_0x2e79d4(0xf6)]&&_0x26ba8a[_0x2e79d4(0xef)]==null)throw CliErrors['validation'](_0x1c35c3[_0x2e79d4(0xde)]+_0x2e79d4(0x13e));let _0x4e7bb4=extractScriptDescription(_0x2dab4c);if(!_0x4e7bb4&&_0x26ba8a?.[_0x2e79d4(0xf6)]){const _0x2b4b9b=await getBffScriptInfo(_0x26ba8a[_0x2e79d4(0xf6)]);_0x4e7bb4=_0x2b4b9b['description']||undefined;}const _0x141343={'appCode':_0x4b724e,'functionName':_0x1c35c3[_0x2e79d4(0xeb)],'scriptType':_0x1c35c3[_0x2e79d4(0xcf)],'scriptContent':_0x2dab4c};if(_0x26ba8a?.[_0x2e79d4(0xf6)])_0x141343['id']=_0x26ba8a[_0x2e79d4(0xf6)];if(_0x26ba8a?.['version']!=null)_0x141343[_0x2e79d4(0xef)]=_0x26ba8a[_0x2e79d4(0xef)];if(_0x4e7bb4)_0x141343[_0x2e79d4(0xff)]=_0x4e7bb4;if(_0x1c35c3[_0x2e79d4(0xcf)]===_0x2e79d4(0x122)){const _0x13aa01=_0x3b3613['resolutions'][_0x2e79d4(0xcc)](_0x1c35c3[_0x2e79d4(0xde)]);if(!_0x13aa01&&!_0x3b3613[_0x2e79d4(0x135)][_0x2e79d4(0x116)](_0x1c35c3[_0x2e79d4(0xde)])||!_0x1c35c3[_0x2e79d4(0xf1)]||!_0x1c35c3['functionNode'])throw CliErrors[_0x2e79d4(0x139)](_0x2e79d4(0x134)+_0x1c35c3[_0x2e79d4(0xde)]);_0x13aa01&&(_0x141343[_0x2e79d4(0xd8)]=_0x13aa01[_0x2e79d4(0x13f)]['id'],_0x141343[_0x2e79d4(0xf1)]=_0x1c35c3[_0x2e79d4(0xf1)]),_0x141343['functionNode']=_0x1c35c3[_0x2e79d4(0xd4)];}const _0x785c11=await saveBffScript(_0x141343),_0x3a9bab=_0x785c11['id'],_0x44a042=_0x785c11[_0x2e79d4(0x132)]??await getBffScriptInfo(_0x3a9bab),_0x95261a={'hash':_0x529d95,'remoteId':_0x3a9bab,'version':_0x44a042[_0x2e79d4(0xef)]};if(_0x1c35c3['type']==='HOOK'){const _0x45adf2=_0x3b3613[_0x2e79d4(0x109)][_0x2e79d4(0xcc)](_0x1c35c3[_0x2e79d4(0xde)]);if(!_0x45adf2){_0x214b38[_0x2e79d4(0xce)][_0x1c35c3[_0x2e79d4(0xde)]]={..._0x26ba8a,..._0x95261a};return;}_0x95261a[_0x2e79d4(0x11e)]=_0x45adf2[_0x2e79d4(0x11e)]??_0x26ba8a?.[_0x2e79d4(0x11e)],_0x95261a[_0x2e79d4(0x13b)]=_0x45adf2['datasetCode'],_0x95261a[_0x2e79d4(0xf1)]=_0x1c35c3[_0x2e79d4(0xf1)],_0x95261a[_0x2e79d4(0xd4)]=_0x1c35c3[_0x2e79d4(0xd4)];}_0x214b38[_0x2e79d4(0xce)][_0x1c35c3[_0x2e79d4(0xde)]]=_0x95261a;}const LOCK_SETTLE_RETRY_COUNT=0x14,LOCK_SETTLE_DELAY_MS=0x64;async function waitForUploadedLockEntries(_0xf01919,_0x534b2e,_0x1a1dad){const _0xe99306=a44_0x1c3065;if(_0x1a1dad['length']===0x0)return;for(let _0x372ced=0x0;_0x372ced<LOCK_SETTLE_RETRY_COUNT;_0x372ced+=0x1){const _0x1ef31e=await readBffLockFile(_0xf01919),_0x4e5552=_0x1ef31e?.[_0xe99306(0x12e)]?.[_0x534b2e]?.[_0xe99306(0xce)]??{},_0x155716=_0x1a1dad['every'](_0x5a1bab=>!!_0x4e5552[_0x5a1bab]?.[_0xe99306(0xf6)]);if(_0x155716)return;await sleep(LOCK_SETTLE_DELAY_MS);}throw new Error(_0xe99306(0xf8)+_0x1a1dad['join'](',\x20')+'.');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a45_0x27b3(_0x21d8c9,_0x4e4ca5){_0x21d8c9=_0x21d8c9-0x173;const _0x153d69=a45_0x153d();let _0x27b32e=_0x153d69[_0x21d8c9];return _0x27b32e;}const a45_0x3d4cdf=a45_0x27b3;(function(_0xf71321,_0x49a01f){const _0x1ff7e0=a45_0x27b3,_0xa6f2e5=_0xf71321();while(!![]){try{const _0x3b4b05=-parseInt(_0x1ff7e0(0x187))/0x1*(parseInt(_0x1ff7e0(0x182))/0x2)+parseInt(_0x1ff7e0(0x196))/0x3+-parseInt(_0x1ff7e0(0x177))/0x4*(-parseInt(_0x1ff7e0(0x181))/0x5)+-parseInt(_0x1ff7e0(0x183))/0x6+parseInt(_0x1ff7e0(0x174))/0x7*(parseInt(_0x1ff7e0(0x18f))/0x8)+parseInt(_0x1ff7e0(0x179))/0x9+-parseInt(_0x1ff7e0(0x180))/0xa;if(_0x3b4b05===_0x49a01f)break;else _0xa6f2e5['push'](_0xa6f2e5['shift']());}catch(_0x1271fd){_0xa6f2e5['push'](_0xa6f2e5['shift']());}}}(a45_0x153d,0x3bbf4));import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';import{resolveApiModelSource}from'../../api/model-source.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{createHookLocationMap,resolveRemoteScriptTarget,scanLocalBffFunctions}from'../../core/bff/file-system.js';function a45_0x153d(){const _0x406582=['length','\x20modified,\x20','profileName','currentApp','599824TpVcVp','appCode','\x20remote-only','Also\x20check\x20for\x20remote-only\x20scripts\x20not\x20present\x20locally','apiDir','\x20added,\x20','push','1411287mlqIxv','lockKey','map','hash','read','35FdXwOo','alias','filePath','22524mrUIHp','has','908676ithyLO','status','mergedCli','selectedAppName','defaultApp','Check\x20local\x20Backend\x20Function\x20sync\x20status\x20against\x20lock\x20file','All\x20Backend\x20Function\x20scripts\x20are\x20in\x20sync.','4604090eeBLKM','135KJpYxQ','2CpbJcq','10302tzKpTQ','functions','all','boolean','391470DsNxgC','remote','datasetCode','scriptsRoot'];a45_0x153d=function(){return _0x406582;};return a45_0x153d();}import{computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile}from'../../core/bff/lock.js';export const bffStatus={'service':'bff','command':a45_0x3d4cdf(0x17a),'description':a45_0x3d4cdf(0x17e),'risk':a45_0x3d4cdf(0x173),'flags':[{'name':a45_0x3d4cdf(0x188),'type':a45_0x3d4cdf(0x186),'description':a45_0x3d4cdf(0x192)}],async 'execute'(_0x4e82ab){const _0x10d2cc=a45_0x3d4cdf,_0x20cd17=loadBffProjectConfig(_0x4e82ab[_0x10d2cc(0x190)]),_0x488093=await readBffLockFile(_0x20cd17['lockFilePath']),{appLock:_0x42c9ad}=ensureLockScope(_0x488093??createEmptyBffLock(),_0x4e82ab[_0x10d2cc(0x190)],_0x20cd17[_0x10d2cc(0x18a)],_0x10d2cc(0x17a)),_0x1a3640=await scanLocalBffFunctions(_0x20cd17),_0x3b9571=[],_0x1c1343=[],_0x15b53f=[];for(const _0x434a5e of _0x1a3640){const _0x165d7a=await computeFileHash(_0x434a5e[_0x10d2cc(0x176)]),_0x103b71=_0x42c9ad[_0x10d2cc(0x184)][_0x434a5e[_0x10d2cc(0x197)]];if(!_0x103b71)_0x3b9571[_0x10d2cc(0x195)](_0x434a5e[_0x10d2cc(0x197)]);else _0x103b71[_0x10d2cc(0x199)]!==_0x165d7a?_0x1c1343[_0x10d2cc(0x195)](_0x434a5e[_0x10d2cc(0x197)]):_0x15b53f[_0x10d2cc(0x195)](_0x434a5e['lockKey']);}const _0x46e528=[];if(_0x4e82ab['bool'](_0x10d2cc(0x188))){const _0x997c87=resolveApiModelSource(_0x4e82ab['apiDir'],_0x4e82ab[_0x10d2cc(0x190)],_0x4e82ab[_0x10d2cc(0x17c)]||_0x4e82ab[_0x10d2cc(0x17b)]?.[_0x10d2cc(0x18e)]||_0x4e82ab[_0x10d2cc(0x17b)]?.[_0x10d2cc(0x17d)]),_0x173fd5=loadAliasMap(_0x4e82ab[_0x10d2cc(0x193)],undefined,_0x997c87[_0x10d2cc(0x176)],_0x997c87[_0x10d2cc(0x18d)]),_0xe9b64e=new Map(_0x173fd5[_0x10d2cc(0x198)](_0x52cdb3=>[_0x52cdb3[_0x10d2cc(0x189)],_0x52cdb3[_0x10d2cc(0x175)]])),[_0x34a206,_0x64db5d]=await Promise[_0x10d2cc(0x185)]([listBffScripts(_0x4e82ab['appCode']),getBffScriptStatistics(_0x4e82ab[_0x10d2cc(0x190)])]),_0x40338f=createHookLocationMap(_0x64db5d),_0x5e9a62=new Set(_0x1a3640[_0x10d2cc(0x198)](_0x4fca31=>_0x4fca31['lockKey']));for(const _0x2cd2b6 of _0x34a206){const _0x8d17dd=resolveRemoteScriptTarget(_0x20cd17,_0x2cd2b6,_0x40338f,_0x42c9ad[_0x10d2cc(0x184)],_0xe9b64e);_0x8d17dd&&!_0x5e9a62[_0x10d2cc(0x178)](_0x8d17dd[_0x10d2cc(0x197)])&&_0x46e528[_0x10d2cc(0x195)](_0x8d17dd[_0x10d2cc(0x197)]);}}const _0x8a3515=_0x3b9571[_0x10d2cc(0x18b)]===0x0&&_0x1c1343[_0x10d2cc(0x18b)]===0x0&&_0x46e528[_0x10d2cc(0x18b)]===0x0;return{'ok':!![],'data':{'added':_0x3b9571,'modified':_0x1c1343,'unchanged':_0x15b53f,'remoteOnly':_0x46e528},'message':_0x8a3515?_0x10d2cc(0x17f):_0x3b9571[_0x10d2cc(0x18b)]+_0x10d2cc(0x194)+_0x1c1343[_0x10d2cc(0x18b)]+_0x10d2cc(0x18c)+_0x15b53f['length']+'\x20unchanged'+(_0x46e528['length']>0x0?',\x20'+_0x46e528['length']+_0x10d2cc(0x191):'')};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a46_0x1649(_0x1ba880,_0x2853ec){_0x1ba880=_0x1ba880-0x126;const _0x429ded=a46_0x429d();let _0x164952=_0x429ded[_0x1ba880];return _0x164952;}function a46_0x429d(){const _0xd94d1f=['202513xjYbek','installedPath','cli-skill','apiError','\x20is\x20already\x20current','cwd','changed','pipe','nonInteractive',']:\x20','\x20at\x20','Installing\x20CLI\x20Built-in\x20Skill\x20from\x20the\x20current\x20package.','5625EYdnrh','read','CLI\x20Built-in\x20Skill\x20','Resolve\x20the\x20Skills\x20CLI\x20installation\x20issue\x20and\x20run:\x20','2701731YLVqXj','Install\x20or\x20refresh\x20the\x20Rabetbase\x20CLI\x20Built-in\x20Skill','setLogPath','1467420qyFysQ','log','unknown','8LonuOp','2538232owXICc','info','skillVersion','\x20via\x20skills@latest','code','inherit','error','5578435LtYurM','14230IQnIFF','203DwyiVa','repairCommand','4168jJgKep'];a46_0x429d=function(){return _0xd94d1f;};return a46_0x429d();}const a46_0x1eb32b=a46_0x1649;(function(_0x130bf2,_0x2dddb3){const _0x125793=a46_0x1649,_0x12f0d8=_0x130bf2();while(!![]){try{const _0x2cbf6a=-parseInt(_0x125793(0x12d))/0x1*(-parseInt(_0x125793(0x143))/0x2)+parseInt(_0x125793(0x13d))/0x3+-parseInt(_0x125793(0x144))/0x4+-parseInt(_0x125793(0x128))/0x5+-parseInt(_0x125793(0x140))/0x6+-parseInt(_0x125793(0x12a))/0x7*(-parseInt(_0x125793(0x12c))/0x8)+parseInt(_0x125793(0x139))/0x9*(parseInt(_0x125793(0x129))/0xa);if(_0x2cbf6a===_0x2dddb3)break;else _0x12f0d8['push'](_0x12f0d8['shift']());}catch(_0x4f3e60){_0x12f0d8['push'](_0x12f0d8['shift']());}}}(a46_0x429d,0x9770a));import{CliErrors}from'../../errors.js';import{installBuiltinSkill}from'../../skills/builtin-skill.js';import{logger}from'../../utils/logger.js';export const cliSkillDefinitions=[{'service':a46_0x1eb32b(0x12f),'command':'install','description':a46_0x1eb32b(0x13e),'risk':a46_0x1eb32b(0x13a),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x23dd24){const _0x1621d8=a46_0x1eb32b;logger[_0x1621d8(0x13f)](process[_0x1621d8(0x132)]()),logger[_0x1621d8(0x145)]('cli-skill-install',_0x1621d8(0x138));const _0x1b7a08=installBuiltinSkill({'stdio':_0x23dd24[_0x1621d8(0x135)]?_0x1621d8(0x134):_0x1621d8(0x126)});if(!_0x1b7a08['ok'])throw CliErrors[_0x1621d8(0x130)]('Built-in\x20Skill\x20install\x20failed\x20['+_0x1b7a08[_0x1621d8(0x148)]+_0x1621d8(0x136)+(_0x1b7a08[_0x1621d8(0x127)]||_0x1621d8(0x142)),_0x1621d8(0x13c)+_0x1b7a08[_0x1621d8(0x12b)]);return console[_0x1621d8(0x141)](_0x1b7a08[_0x1621d8(0x133)]?_0x1621d8(0x13b)+_0x1b7a08[_0x1621d8(0x146)]+'\x20installed'+(_0x1b7a08['installedPath']?_0x1621d8(0x137)+_0x1b7a08[_0x1621d8(0x12e)]:_0x1621d8(0x147)):_0x1621d8(0x13b)+_0x1b7a08[_0x1621d8(0x146)]+_0x1621d8(0x131)+(_0x1b7a08[_0x1621d8(0x12e)]?_0x1621d8(0x137)+_0x1b7a08['installedPath']:'')),{'ok':!![]};}}];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a47_0x5bb842=a47_0x107d;(function(_0x3e79cb,_0x23ea10){const _0x5be222=a47_0x107d,_0x1d64a9=_0x3e79cb();while(!![]){try{const _0x2160bb=parseInt(_0x5be222(0xf7))/0x1+parseInt(_0x5be222(0xeb))/0x2*(parseInt(_0x5be222(0xb1))/0x3)+-parseInt(_0x5be222(0xed))/0x4+-parseInt(_0x5be222(0xba))/0x5+-parseInt(_0x5be222(0xe8))/0x6*(parseInt(_0x5be222(0xf1))/0x7)+parseInt(_0x5be222(0xad))/0x8+parseInt(_0x5be222(0xc8))/0x9;if(_0x2160bb===_0x23ea10)break;else _0x1d64a9['push'](_0x1d64a9['shift']());}catch(_0x438460){_0x1d64a9['push'](_0x1d64a9['shift']());}}}(a47_0xf05d,0x495fe));import a47_0x378bf7 from'chalk';import a47_0xf35b70 from'ora';import a47_0x353f3f from'semver';import{execa}from'execa';function a47_0x107d(_0x47ccbe,_0x2c5152){_0x47ccbe=_0x47ccbe-0xac;const _0xf05d67=a47_0xf05d();let _0x107d2a=_0xf05d67[_0x47ccbe];return _0x107d2a;}import{CLI_BIN_NAME,NPM_PACKAGE_NAME}from'../constant/cli.js';import{VERSION,GIT_COMMIT,BUILD_TIME}from'../generated/build-info.js';import{CliErrors}from'../errors.js';import{inspectInstalledBuiltinSkillVersion,installBuiltinSkill}from'../skills/builtin-skill.js';import{resolveNpmBin}from'../utils/platform.js';function getCurrentVersion(){const _0xea799e=a47_0x107d;return GIT_COMMIT!==_0xea799e(0xdb)?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME[_0xea799e(0xb7)](0x0,0xa)+')':VERSION;}function detectPackageManager(){const _0x5c6c72=a47_0x107d,_0x57f798=process['execPath'][_0x5c6c72(0xc6)]();if(_0x57f798['includes']('bun'))return'bun';return _0x5c6c72(0xbf);}const updateFlags=[{'name':'beta','type':a47_0x5bb842(0xe0),'description':a47_0x5bb842(0xb9),'default':![]},{'name':a47_0x5bb842(0xdd),'type':a47_0x5bb842(0xb6),'description':'Install\x20a\x20specific\x20CLI\x20version'}];function getRequestedVersion(_0x9241d5){const _0x4bc17b=a47_0x5bb842;return _0x9241d5[_0x4bc17b(0x100)](_0x4bc17b(0xdd))[_0x4bc17b(0xe9)]();}function a47_0xf05d(){const _0x361814=['Try\x20manually:\x20','Unable\x20to\x20resolve\x20beta\x20version\x20from\x20npm','source','Run:\x20','expected\x20','state','/dist-tags','Current\x20version:\x20',',\x20then\x20verify\x20with:\x20','beta','unknown','Update\x20failed','version','start','valid','boolean','repairCommand',',\x20state\x20','CLI\x20Built-in\x20Skill\x20repair\x20failed\x20[','read','Unable\x20to\x20check\x20for\x20updates\x20(network\x20error)','--beta\x20and\x20--version\x20cannot\x20be\x20used\x20together.','object','1223058FIbCAI','trim','Beta\x20version:\x20','186qaVulK','fail','418996cwcdjk','\x20doctor','message','run','7zwVwnS','Already\x20on\x20requested\x20version\x20(v','\x20→\x20','Update\x20available:\x20','json','Requested\x20version:\x20','306549GFULoI','current','Try\x20manually:\x20npm\x20install\x20-g\x20','map','\x20update\x20--version\x20<version>','CLI\x20updated\x20to\x20v','bool','length','Updating\x20via\x20','str','validation','skillVersion','272624GKWcSN','pipe','Update\x20rabetbase\x20CLI\x20to\x20the\x20latest\x20version','filter','3447rCvIuN','update','Checking\x20for\x20updates...','green','Invalid\x20version:\x20','string','slice','\x20install\x20-g\x20','Install\x20the\x20version\x20from\x20npm\x20beta\x20dist-tag','1433920BAuhSN','\x20is\x20newer\x20than\x20npm\x20latest\x20v','yellow','Choose\x20either\x20npm\x20beta\x20dist-tag\x20or\x20an\x20exact\x20version.','code','npm','succeed','...','https://registry.npmjs.org/-/package/','error','latest','\x20\x20CLI\x20Built-in\x20Skill\x20','toLowerCase','Already\x20up\x20to\x20date\x20(v','4035906cptpAc','log','apiError','gray','timeout',',\x20found\x20','Updated\x20to\x20v','Version\x20comparison\x20failed','\x20is\x20up\x20to\x20date.'];a47_0xf05d=function(){return _0x361814;};return a47_0xf05d();}async function validateUpdateFlags(_0x409ba7){const _0x270042=a47_0x5bb842,_0x45e429=_0x409ba7[_0x270042(0xfd)](_0x270042(0xda)),_0x3b50eb=getRequestedVersion(_0x409ba7);if(_0x45e429&&_0x3b50eb)throw CliErrors['validation'](_0x270042(0xe6),_0x270042(0xbd));if(_0x3b50eb&&!a47_0x353f3f[_0x270042(0xdf)](_0x3b50eb))throw CliErrors[_0x270042(0x101)](_0x270042(0xb5)+_0x3b50eb,'Use\x20a\x20full\x20semver\x20such\x20as\x202.1.6\x20or\x202.1.6-beta.1.');}async function fetchNpmDistTags(){const _0x478dd0=a47_0x5bb842;try{const _0x574525=await fetch(_0x478dd0(0xc2)+encodeURIComponent(NPM_PACKAGE_NAME)+_0x478dd0(0xd7),{'signal':AbortSignal[_0x478dd0(0xcc)](0x2710)});if(!_0x574525['ok'])return null;const _0x3514d2=await _0x574525[_0x478dd0(0xf5)]();if(!_0x3514d2||typeof _0x3514d2!==_0x478dd0(0xe7))return null;return Object['fromEntries'](Object['entries'](_0x3514d2)[_0x478dd0(0xb0)](([,_0x312e0a])=>typeof _0x312e0a===_0x478dd0(0xb6)&&_0x312e0a['trim']()[_0x478dd0(0xfe)]>0x0)[_0x478dd0(0xfa)](([_0x4e8de,_0x2dc194])=>[_0x4e8de,String(_0x2dc194)[_0x478dd0(0xe9)]()]));}catch{return null;}}async function fetchNpmDistTagVersion(_0x589d90){const _0x21dbc2=await fetchNpmDistTags();return _0x21dbc2?.[_0x589d90]??null;}async function fetchLatestVersion(){return fetchNpmDistTagVersion('latest');}async function resolveTargetVersion(_0x1e90ea){const _0x4a2615=a47_0x5bb842,_0x24dcde=getRequestedVersion(_0x1e90ea);if(_0x24dcde)return{'version':_0x24dcde,'source':_0x4a2615(0xdd)};if(_0x1e90ea[_0x4a2615(0xfd)](_0x4a2615(0xda))){const _0x97a04a=await fetchNpmDistTagVersion(_0x4a2615(0xda));if(!_0x97a04a)return null;return{'version':_0x97a04a,'source':_0x4a2615(0xda)};}const _0x1db257=await fetchLatestVersion();if(!_0x1db257)return null;return{'version':_0x1db257,'source':_0x4a2615(0xc4)};}function shouldInstallTarget(_0x111c93,_0x1940be){const _0xa90901=a47_0x5bb842;if(_0x1940be[_0xa90901(0xd3)]===_0xa90901(0xdd)||_0x1940be[_0xa90901(0xd3)]==='beta')return!a47_0x353f3f['eq'](_0x111c93,_0x1940be[_0xa90901(0xdd)]);return a47_0x353f3f['lt'](_0x111c93,_0x1940be[_0xa90901(0xdd)]);}function getInstallPlanLabel(_0xca0e0f,_0x105160){const _0x303131=a47_0x5bb842;switch(_0x105160['source']){case _0x303131(0xda):return _0x303131(0xea)+a47_0x378bf7[_0x303131(0xbc)](_0xca0e0f)+'\x20→\x20'+a47_0x378bf7[_0x303131(0xb4)](_0x105160[_0x303131(0xdd)]);case'version':return _0x303131(0xf6)+a47_0x378bf7[_0x303131(0xbc)](_0xca0e0f)+_0x303131(0xf3)+a47_0x378bf7['green'](_0x105160['version']);case _0x303131(0xc4):default:return _0x303131(0xf4)+a47_0x378bf7[_0x303131(0xbc)](_0xca0e0f)+'\x20→\x20'+a47_0x378bf7['green'](_0x105160[_0x303131(0xdd)]);}}function repairCurrentBuiltinSkill(){const _0x58eec5=a47_0x5bb842;console[_0x58eec5(0xc9)](a47_0x378bf7[_0x58eec5(0xcb)]('Checking\x20CLI\x20Built-in\x20Skill...'));const _0x581ad7=installBuiltinSkill();if(_0x581ad7['ok']){console['log'](a47_0x378bf7[_0x58eec5(0xcb)](_0x58eec5(0xc5)+_0x581ad7[_0x58eec5(0xac)]+_0x58eec5(0xd0)));return;}throw CliErrors[_0x58eec5(0xca)](_0x58eec5(0xe3)+_0x581ad7[_0x58eec5(0xbe)]+']:\x20'+(_0x581ad7[_0x58eec5(0xc3)]||'unknown'),_0x58eec5(0xd4)+_0x581ad7[_0x58eec5(0xe1)]+',\x20then\x20verify\x20with:\x20'+CLI_BIN_NAME+_0x58eec5(0xee));}function verifyUpdatedBuiltinSkill(_0x37fba0){const _0x32f171=a47_0x5bb842,_0x42476e=inspectInstalledBuiltinSkillVersion(_0x37fba0);if(_0x42476e[_0x32f171(0xd6)]===_0x32f171(0xf8)){console['log'](a47_0x378bf7[_0x32f171(0xcb)](_0x32f171(0xc5)+_0x37fba0+_0x32f171(0xd0)));return;}const _0x183b5b=_0x42476e[_0x32f171(0xac)]?_0x32f171(0xd5)+_0x37fba0+_0x32f171(0xcd)+_0x42476e[_0x32f171(0xac)]:_0x32f171(0xd5)+_0x37fba0+_0x32f171(0xe2)+_0x42476e[_0x32f171(0xd6)];throw CliErrors['apiError'](_0x32f171(0xfc)+_0x37fba0+',\x20but\x20Built-in\x20Skill\x20verification\x20failed:\x20'+_0x183b5b,'Run:\x20'+_0x42476e['repairCommand']+_0x32f171(0xd9)+CLI_BIN_NAME+_0x32f171(0xee));}async function execute(_0x316267){const _0x6939a4=a47_0x5bb842;await validateUpdateFlags(_0x316267);const _0x289679=getCurrentVersion();console[_0x6939a4(0xc9)](_0x6939a4(0xd8)+_0x289679);const _0x4aab4c=a47_0xf35b70(_0x6939a4(0xb3))['start'](),_0xd1855=await resolveTargetVersion(_0x316267);if(!_0xd1855){const _0x4bac05=_0x316267[_0x6939a4(0xfd)](_0x6939a4(0xda))?_0x6939a4(0xd2):_0x6939a4(0xe5);_0x4aab4c[_0x6939a4(0xec)](_0x4bac05);throw CliErrors[_0x6939a4(0xca)](_0x4bac05,_0x6939a4(0xf9)+NPM_PACKAGE_NAME+'@'+(_0x316267[_0x6939a4(0xfd)](_0x6939a4(0xda))?_0x6939a4(0xda):_0x6939a4(0xc4)));}const _0x2cc82c=a47_0x353f3f[_0x6939a4(0xdf)](VERSION),_0x4cbffd=a47_0x353f3f['valid'](_0xd1855[_0x6939a4(0xdd)]);if(!_0x2cc82c||!_0x4cbffd){_0x4aab4c[_0x6939a4(0xec)](_0x6939a4(0xcf));throw CliErrors[_0x6939a4(0xca)]('Version\x20comparison\x20failed','Check\x20the\x20CLI\x20and\x20npm\x20versions,\x20then\x20retry:\x20'+CLI_BIN_NAME+_0x6939a4(0xfb));}if(!shouldInstallTarget(_0x2cc82c,_0xd1855)){const _0x19517f=_0xd1855[_0x6939a4(0xd3)]===_0x6939a4(0xdd)?_0x6939a4(0xf2)+_0xd1855[_0x6939a4(0xdd)]+')':a47_0x353f3f['gt'](_0x2cc82c,_0x4cbffd)?'Current\x20version\x20v'+_0x289679+_0x6939a4(0xbb)+_0xd1855['version']:_0x6939a4(0xc7)+_0xd1855[_0x6939a4(0xdd)]+')';return _0x4aab4c[_0x6939a4(0xc0)](_0x19517f),repairCurrentBuiltinSkill(),{'ok':!![]};}_0x4aab4c['info'](getInstallPlanLabel(_0x289679,_0xd1855));const _0x451be4=detectPackageManager(),_0x9920c1=_0x451be4===_0x6939a4(0xbf)?resolveNpmBin(_0x6939a4(0xbf)):_0x451be4,_0x33b9b6=a47_0xf35b70(_0x6939a4(0xff)+_0x451be4+_0x6939a4(0xc1))[_0x6939a4(0xde)]();try{await execa(_0x9920c1,['install','-g',NPM_PACKAGE_NAME+'@'+_0xd1855[_0x6939a4(0xdd)]],{'stdio':_0x6939a4(0xae)}),_0x33b9b6['succeed'](_0x6939a4(0xce)+_0xd1855[_0x6939a4(0xdd)]),console['log'](a47_0x378bf7[_0x6939a4(0xcb)]('\x20\x20Restart\x20your\x20terminal\x20to\x20use\x20the\x20new\x20version.'));}catch(_0x5b0382){_0x33b9b6[_0x6939a4(0xec)](_0x6939a4(0xdc));throw CliErrors['apiError']('Update\x20failed:\x20'+(_0x5b0382 instanceof Error?_0x5b0382[_0x6939a4(0xef)]:String(_0x5b0382)),_0x6939a4(0xd1)+_0x451be4+_0x6939a4(0xb8)+NPM_PACKAGE_NAME+'@'+_0xd1855['version']);}return verifyUpdatedBuiltinSkill(_0xd1855[_0x6939a4(0xdd)]),{'ok':!![]};}export const updateDefinition={'service':a47_0x5bb842(0xb2),'command':a47_0x5bb842(0xf0),'description':a47_0x5bb842(0xaf),'risk':a47_0x5bb842(0xe4),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':updateFlags,'validate':validateUpdateFlags,'execute':execute};
|
|
1
|
+
const a47_0x1a2b28=a47_0x4578;(function(_0x4dec69,_0x48492a){const _0xc9318=a47_0x4578,_0x57c875=_0x4dec69();while(!![]){try{const _0x4cd3d4=parseInt(_0xc9318(0x11b))/0x1+-parseInt(_0xc9318(0x148))/0x2+parseInt(_0xc9318(0x10b))/0x3+parseInt(_0xc9318(0x13f))/0x4+parseInt(_0xc9318(0x135))/0x5+parseInt(_0xc9318(0x115))/0x6*(parseInt(_0xc9318(0x105))/0x7)+parseInt(_0xc9318(0x117))/0x8*(-parseInt(_0xc9318(0x140))/0x9);if(_0x4cd3d4===_0x48492a)break;else _0x57c875['push'](_0x57c875['shift']());}catch(_0x572e65){_0x57c875['push'](_0x57c875['shift']());}}}(a47_0x143b,0xa6a99));import a47_0x40414c from'chalk';import a47_0x10471f from'ora';import a47_0x503a18 from'semver';import{execa}from'execa';import{CLI_BIN_NAME,NPM_PACKAGE_NAME}from'../constant/cli.js';import{VERSION,GIT_COMMIT,BUILD_TIME}from'../generated/build-info.js';import{CliErrors}from'../errors.js';import{inspectInstalledBuiltinSkillVersion,installBuiltinSkill}from'../skills/builtin-skill.js';import{resolveNpmBin}from'../utils/platform.js';function a47_0x143b(){const _0x204649=['\x20doctor','error','source','3297534OdejZu','toLowerCase','2565256QqTNTJ','CLI\x20updated\x20to\x20v','read','valid','13827JDAJLs','str','--beta\x20and\x20--version\x20cannot\x20be\x20used\x20together.','current','bool','green','state','repairCommand','validation','Current\x20version\x20v','Update\x20available:\x20','expected\x20','includes','Unable\x20to\x20resolve\x20beta\x20version\x20from\x20npm','Requested\x20version:\x20','/dist-tags','Try\x20manually:\x20',',\x20state\x20','\x20install\x20-g\x20','message','skillVersion','start','succeed','trim','Version\x20comparison\x20failed','latest','247810JlBwbp','yellow','Use\x20a\x20full\x20semver\x20such\x20as\x202.1.6\x20or\x202.1.6-beta.1.','object','json','\x20\x20CLI\x20Built-in\x20Skill\x20','Unable\x20to\x20check\x20for\x20updates\x20(network\x20error)','filter','\x20\x20Restart\x20your\x20terminal\x20to\x20use\x20the\x20new\x20version.','slice','4245256FzsYjV','36sIdpRW','Updating\x20via\x20','log','Updated\x20to\x20v','string','Checking\x20CLI\x20Built-in\x20Skill...','version','unknown','2100064eHjCrJ','Run:\x20','execPath','fromEntries','npm','Install\x20the\x20version\x20from\x20npm\x20beta\x20dist-tag','CLI\x20Built-in\x20Skill\x20repair\x20failed\x20[','entries','\x20is\x20up\x20to\x20date.','\x20→\x20','beta','Update\x20failed:\x20','gray','14vUIXno','info','Update\x20rabetbase\x20CLI\x20to\x20the\x20latest\x20version','apiError','Beta\x20version:\x20','fail','2374284ONZvoY','Update\x20failed','Install\x20a\x20specific\x20CLI\x20version','https://registry.npmjs.org/-/package/','Try\x20manually:\x20npm\x20install\x20-g\x20',',\x20then\x20verify\x20with:\x20','bun'];a47_0x143b=function(){return _0x204649;};return a47_0x143b();}function getCurrentVersion(){const _0x42eaa3=a47_0x4578;return GIT_COMMIT!==_0x42eaa3(0x147)?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME[_0x42eaa3(0x13e)](0x0,0xa)+')':VERSION;}function detectPackageManager(){const _0x8f58d7=a47_0x4578,_0xa4ccfa=process[_0x8f58d7(0x14a)][_0x8f58d7(0x116)]();if(_0xa4ccfa[_0x8f58d7(0x127)](_0x8f58d7(0x111)))return _0x8f58d7(0x111);return _0x8f58d7(0x14c);}const updateFlags=[{'name':'beta','type':'boolean','description':a47_0x1a2b28(0x14d),'default':![]},{'name':a47_0x1a2b28(0x146),'type':a47_0x1a2b28(0x144),'description':a47_0x1a2b28(0x10d)}];function getRequestedVersion(_0x59e010){const _0x454651=a47_0x1a2b28;return _0x59e010[_0x454651(0x11c)](_0x454651(0x146))['trim']();}async function validateUpdateFlags(_0x4df434){const _0x4e21d2=a47_0x1a2b28,_0x1b25a9=_0x4df434[_0x4e21d2(0x11f)](_0x4e21d2(0x152)),_0x3b21aa=getRequestedVersion(_0x4df434);if(_0x1b25a9&&_0x3b21aa)throw CliErrors[_0x4e21d2(0x123)](_0x4e21d2(0x11d),'Choose\x20either\x20npm\x20beta\x20dist-tag\x20or\x20an\x20exact\x20version.');if(_0x3b21aa&&!a47_0x503a18[_0x4e21d2(0x11a)](_0x3b21aa))throw CliErrors[_0x4e21d2(0x123)]('Invalid\x20version:\x20'+_0x3b21aa,_0x4e21d2(0x137));}async function fetchNpmDistTags(){const _0x3806d0=a47_0x1a2b28;try{const _0xefa68=await fetch(_0x3806d0(0x10e)+encodeURIComponent(NPM_PACKAGE_NAME)+_0x3806d0(0x12a),{'signal':AbortSignal['timeout'](0x2710)});if(!_0xefa68['ok'])return null;const _0x43f08b=await _0xefa68[_0x3806d0(0x139)]();if(!_0x43f08b||typeof _0x43f08b!==_0x3806d0(0x138))return null;return Object[_0x3806d0(0x14b)](Object[_0x3806d0(0x14f)](_0x43f08b)[_0x3806d0(0x13c)](([,_0x138201])=>typeof _0x138201===_0x3806d0(0x144)&&_0x138201[_0x3806d0(0x132)]()['length']>0x0)['map'](([_0x5329f9,_0x17d97c])=>[_0x5329f9,String(_0x17d97c)[_0x3806d0(0x132)]()]));}catch{return null;}}async function fetchNpmDistTagVersion(_0x52235d){const _0x340062=await fetchNpmDistTags();return _0x340062?.[_0x52235d]??null;}async function fetchLatestVersion(){const _0x53d089=a47_0x1a2b28;return fetchNpmDistTagVersion(_0x53d089(0x134));}async function resolveTargetVersion(_0x43a70e){const _0xd9fd2d=a47_0x1a2b28,_0x5e80dd=getRequestedVersion(_0x43a70e);if(_0x5e80dd)return{'version':_0x5e80dd,'source':'version'};if(_0x43a70e[_0xd9fd2d(0x11f)](_0xd9fd2d(0x152))){const _0x1782d3=await fetchNpmDistTagVersion(_0xd9fd2d(0x152));if(!_0x1782d3)return null;return{'version':_0x1782d3,'source':'beta'};}const _0x322242=await fetchLatestVersion();if(!_0x322242)return null;return{'version':_0x322242,'source':_0xd9fd2d(0x134)};}function shouldInstallTarget(_0x4e2608,_0x533a3d){const _0x52871c=a47_0x1a2b28;if(_0x533a3d[_0x52871c(0x114)]===_0x52871c(0x146)||_0x533a3d[_0x52871c(0x114)]===_0x52871c(0x152))return!a47_0x503a18['eq'](_0x4e2608,_0x533a3d[_0x52871c(0x146)]);return a47_0x503a18['lt'](_0x4e2608,_0x533a3d[_0x52871c(0x146)]);}function getInstallPlanLabel(_0x1c1ac7,_0x18f1d0){const _0x15d6e9=a47_0x1a2b28;switch(_0x18f1d0['source']){case _0x15d6e9(0x152):return _0x15d6e9(0x109)+a47_0x40414c[_0x15d6e9(0x136)](_0x1c1ac7)+_0x15d6e9(0x151)+a47_0x40414c['green'](_0x18f1d0['version']);case _0x15d6e9(0x146):return _0x15d6e9(0x129)+a47_0x40414c[_0x15d6e9(0x136)](_0x1c1ac7)+'\x20→\x20'+a47_0x40414c[_0x15d6e9(0x120)](_0x18f1d0[_0x15d6e9(0x146)]);case _0x15d6e9(0x134):default:return _0x15d6e9(0x125)+a47_0x40414c['yellow'](_0x1c1ac7)+_0x15d6e9(0x151)+a47_0x40414c[_0x15d6e9(0x120)](_0x18f1d0['version']);}}function repairCurrentBuiltinSkill(){const _0x3cd13b=a47_0x1a2b28;console[_0x3cd13b(0x142)](a47_0x40414c['gray'](_0x3cd13b(0x145)));const _0xf22bdb=installBuiltinSkill();if(_0xf22bdb['ok']){console[_0x3cd13b(0x142)](a47_0x40414c['gray'](_0x3cd13b(0x13a)+_0xf22bdb[_0x3cd13b(0x12f)]+_0x3cd13b(0x150)));return;}throw CliErrors[_0x3cd13b(0x108)](_0x3cd13b(0x14e)+_0xf22bdb['code']+']:\x20'+(_0xf22bdb[_0x3cd13b(0x113)]||'unknown'),'Run:\x20'+_0xf22bdb['repairCommand']+',\x20then\x20verify\x20with:\x20'+CLI_BIN_NAME+_0x3cd13b(0x112));}function verifyUpdatedBuiltinSkill(_0x5eee59){const _0x2fabe2=a47_0x1a2b28,_0x2c3dfb=inspectInstalledBuiltinSkillVersion(_0x5eee59);if(_0x2c3dfb[_0x2fabe2(0x121)]===_0x2fabe2(0x11e)){console[_0x2fabe2(0x142)](a47_0x40414c[_0x2fabe2(0x104)]('\x20\x20CLI\x20Built-in\x20Skill\x20'+_0x5eee59+_0x2fabe2(0x150)));return;}const _0x245509=_0x2c3dfb['skillVersion']?_0x2fabe2(0x126)+_0x5eee59+',\x20found\x20'+_0x2c3dfb[_0x2fabe2(0x12f)]:_0x2fabe2(0x126)+_0x5eee59+_0x2fabe2(0x12c)+_0x2c3dfb[_0x2fabe2(0x121)];throw CliErrors[_0x2fabe2(0x108)](_0x2fabe2(0x118)+_0x5eee59+',\x20but\x20Built-in\x20Skill\x20verification\x20failed:\x20'+_0x245509,_0x2fabe2(0x149)+_0x2c3dfb[_0x2fabe2(0x122)]+_0x2fabe2(0x110)+CLI_BIN_NAME+_0x2fabe2(0x112));}async function execute(_0x1b8dd9){const _0x5595b9=a47_0x1a2b28;await validateUpdateFlags(_0x1b8dd9);const _0x5982bd=getCurrentVersion();console[_0x5595b9(0x142)]('Current\x20version:\x20'+_0x5982bd);const _0x31b4dd=a47_0x10471f('Checking\x20for\x20updates...')[_0x5595b9(0x130)](),_0x3d6fd1=await resolveTargetVersion(_0x1b8dd9);if(!_0x3d6fd1){const _0x30e70a=_0x1b8dd9[_0x5595b9(0x11f)]('beta')?_0x5595b9(0x128):_0x5595b9(0x13b);_0x31b4dd[_0x5595b9(0x10a)](_0x30e70a);throw CliErrors['apiError'](_0x30e70a,_0x5595b9(0x10f)+NPM_PACKAGE_NAME+'@'+(_0x1b8dd9[_0x5595b9(0x11f)](_0x5595b9(0x152))?'beta':_0x5595b9(0x134)));}const _0x530024=a47_0x503a18[_0x5595b9(0x11a)](VERSION),_0x18c890=a47_0x503a18[_0x5595b9(0x11a)](_0x3d6fd1[_0x5595b9(0x146)]);if(!_0x530024||!_0x18c890){_0x31b4dd['fail']('Version\x20comparison\x20failed');throw CliErrors[_0x5595b9(0x108)](_0x5595b9(0x133),'Check\x20the\x20CLI\x20and\x20npm\x20versions,\x20then\x20retry:\x20'+CLI_BIN_NAME+'\x20update\x20--version\x20<version>');}if(!shouldInstallTarget(_0x530024,_0x3d6fd1)){const _0x20e7e7=_0x3d6fd1[_0x5595b9(0x114)]==='version'?'Already\x20on\x20requested\x20version\x20(v'+_0x3d6fd1['version']+')':a47_0x503a18['gt'](_0x530024,_0x18c890)?_0x5595b9(0x124)+_0x5982bd+'\x20is\x20newer\x20than\x20npm\x20latest\x20v'+_0x3d6fd1[_0x5595b9(0x146)]:'Already\x20up\x20to\x20date\x20(v'+_0x3d6fd1['version']+')';return _0x31b4dd[_0x5595b9(0x131)](_0x20e7e7),repairCurrentBuiltinSkill(),{'ok':!![]};}_0x31b4dd[_0x5595b9(0x106)](getInstallPlanLabel(_0x5982bd,_0x3d6fd1));const _0x8e5865=detectPackageManager(),_0x42780d=_0x8e5865===_0x5595b9(0x14c)?resolveNpmBin(_0x5595b9(0x14c)):_0x8e5865,_0x55f543=a47_0x10471f(_0x5595b9(0x141)+_0x8e5865+'...')[_0x5595b9(0x130)]();try{await execa(_0x42780d,['install','-g',NPM_PACKAGE_NAME+'@'+_0x3d6fd1[_0x5595b9(0x146)]],{'stdio':'pipe'}),_0x55f543[_0x5595b9(0x131)](_0x5595b9(0x143)+_0x3d6fd1[_0x5595b9(0x146)]),console[_0x5595b9(0x142)](a47_0x40414c[_0x5595b9(0x104)](_0x5595b9(0x13d)));}catch(_0x1b2a10){_0x55f543[_0x5595b9(0x10a)](_0x5595b9(0x10c));throw CliErrors[_0x5595b9(0x108)](_0x5595b9(0x153)+(_0x1b2a10 instanceof Error?_0x1b2a10[_0x5595b9(0x12e)]:String(_0x1b2a10)),_0x5595b9(0x12b)+_0x8e5865+_0x5595b9(0x12d)+NPM_PACKAGE_NAME+'@'+_0x3d6fd1['version']);}return verifyUpdatedBuiltinSkill(_0x3d6fd1[_0x5595b9(0x146)]),{'ok':!![]};}function a47_0x4578(_0x476dfb,_0x254082){_0x476dfb=_0x476dfb-0x104;const _0x143b2e=a47_0x143b();let _0x457832=_0x143b2e[_0x476dfb];return _0x457832;}export const updateDefinition={'service':'update','command':'run','description':a47_0x1a2b28(0x107),'risk':a47_0x1a2b28(0x119),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':updateFlags,'validate':validateUpdateFlags,'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a48_0xf8e5(_0x5b06ad,_0x21300f){_0x5b06ad=_0x5b06ad-0x1f2;const _0x3f80f7=a48_0x3f80();let _0xf8e586=_0x3f80f7[_0x5b06ad];return _0xf8e586;}(function(_0x376324,_0x3724b2){const _0x5f2643=a48_0xf8e5,_0x218260=_0x376324();while(!![]){try{const _0x4935b1=-parseInt(_0x5f2643(0x1f6))/0x1*(-parseInt(_0x5f2643(0x1f7))/0x2)+parseInt(_0x5f2643(0x1f2))/0x3+parseInt(_0x5f2643(0x1fa))/0x4*(parseInt(_0x5f2643(0x1f4))/0x5)+-parseInt(_0x5f2643(0x1f9))/0x6*(parseInt(_0x5f2643(0x1f3))/0x7)+-parseInt(_0x5f2643(0x1fb))/0x8+parseInt(_0x5f2643(0x1f8))/0x9+-parseInt(_0x5f2643(0x1f5))/0xa;if(_0x4935b1===_0x3724b2)break;else _0x218260['push'](_0x218260['shift']());}catch(_0x39957d){_0x218260['push'](_0x218260['shift']());}}}(a48_0x3f80,0x85524));import{codegenSdk}from'../../commands/codegen/sdk.js';import{codegenSql}from'../../commands/codegen/sql.js';function a48_0x3f80(){const _0x3e3764=['18dmuePp','4LFeIzk','2299424OViKcn','1771494gaNcKc','2340443RIpcnu','3706985JNKPCr','5477960GoHsMz','12227UnzvrB','38HFVgRU','7381323yeTWmc'];a48_0x3f80=function(){return _0x3e3764;};return a48_0x3f80();}export const codegenDefinitions=[codegenSdk,codegenSql];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a49_0x354f(){const _0x30180a=['32742QOnGkk','code','Generate\x20TypeScript\x20SDK\x20code\x20for\x20a\x20dataset\x20operation','6RmHMux','tableName','65XfGfgr','2315467vAdWPn','1083642dSPnjR','3868tCQrJD','codegen','bool','string','657116CTooyM','alias','15xVAHGx','appCode','str','416rDDOVz','skip-imports','operation','1840790GiRqiE','boolean','36UYIjsc','4231031XoSuDq','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon)'];a49_0x354f=function(){return _0x30180a;};return a49_0x354f();}const a49_0x37b3c5=a49_0xbb6b;(function(_0x38de3e,_0x362528){const _0x4a170e=a49_0xbb6b,_0x424df9=_0x38de3e();while(!![]){try{const _0x316f40=parseInt(_0x4a170e(0xa2))/0x1*(-parseInt(_0x4a170e(0xa5))/0x2)+parseInt(_0x4a170e(0xa4))/0x3+-parseInt(_0x4a170e(0xa9))/0x4*(-parseInt(_0x4a170e(0x92))/0x5)+parseInt(_0x4a170e(0xa0))/0x6*(parseInt(_0x4a170e(0x9b))/0x7)+parseInt(_0x4a170e(0x95))/0x8*(-parseInt(_0x4a170e(0x9d))/0x9)+-parseInt(_0x4a170e(0x98))/0xa+parseInt(_0x4a170e(0xa3))/0xb*(-parseInt(_0x4a170e(0x9a))/0xc);if(_0x316f40===_0x362528)break;else _0x424df9['push'](_0x424df9['shift']());}catch(_0x293e9f){_0x424df9['push'](_0x424df9['shift']());}}}(a49_0x354f,0x5015c));import{getOperationDetail,generateSdkCode}from'../../core/api-client.js';import{CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a49_0xbb6b(_0x2925c6,_0x41f84f){_0x2925c6=_0x2925c6-0x91;const _0x354f76=a49_0x354f();let _0xbb6b19=_0x354f76[_0x2925c6];return _0xbb6b19;}export const codegenSdk={'service':a49_0x37b3c5(0xa6),'command':'sdk','description':a49_0x37b3c5(0x9f),'risk':'read','flags':[CODE_FLAG_OPTIONAL,{'name':a49_0x37b3c5(0x91),'type':a49_0x37b3c5(0xa8),'description':a49_0x37b3c5(0x9c)},{'name':a49_0x37b3c5(0x97),'type':a49_0x37b3c5(0xa8),'required':!![],'description':'Operation\x20name\x20(e.g.\x20filter,\x20getOne,\x20create,\x20update)'},{'name':a49_0x37b3c5(0x96),'type':a49_0x37b3c5(0x99),'description':'Omit\x20import\x20statements\x20from\x20generated\x20code'}],async 'execute'(_0x314b05){const _0x5c51fc=a49_0x37b3c5,{dataset:_0x18352b,operation:_0x19e0f6}=await getOperationDetail(_0x314b05[_0x5c51fc(0x93)],_0x314b05[_0x5c51fc(0x94)](_0x5c51fc(0x9e)),_0x314b05['str']('operation')),_0x51c4d7=generateSdkCode(_0x18352b,_0x19e0f6,{'includeImports':!_0x314b05[_0x5c51fc(0xa7)]('skip-imports')});return{'ok':!![],'data':{'dataset':{'name':_0x18352b['name'],'code':_0x18352b[_0x5c51fc(0x9e)],'tableName':_0x18352b[_0x5c51fc(0xa1)]},'operation':_0x314b05[_0x5c51fc(0x94)](_0x5c51fc(0x97)),'code':_0x51c4d7}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a50_0xc7434d=a50_0x2eac;function a50_0x493c(){const _0x378ba0=['35FvakZa','str','8778NuGlYv','bff','3726666hKTyKM','8VWvJMm','sql','Generate\x20TypeScript\x20code\x20for\x20a\x20custom\x20SQL\x20query','codegen','read','sdk','no-imports','284542blgQvO','Code\x20target:\x20sdk\x20(default)\x20or\x20bff','sqlCode','35836YDDqlh','1714690ECSQTz','target','2352MVGbOF','3KTVgLy','bool','appCode','259412vuDIEp','18035446RHyqfG'];a50_0x493c=function(){return _0x378ba0;};return a50_0x493c();}(function(_0x153c7e,_0x49d72f){const _0xd0a521=a50_0x2eac,_0x410501=_0x153c7e();while(!![]){try{const _0x7c96da=-parseInt(_0xd0a521(0x19a))/0x1+parseInt(_0xd0a521(0x197))/0x2*(-parseInt(_0xd0a521(0x19e))/0x3)+parseInt(_0xd0a521(0x1a1))/0x4*(-parseInt(_0xd0a521(0x1a3))/0x5)+parseInt(_0xd0a521(0x19d))/0x6*(-parseInt(_0xd0a521(0x18d))/0x7)+parseInt(_0xd0a521(0x190))/0x8*(-parseInt(_0xd0a521(0x18f))/0x9)+parseInt(_0xd0a521(0x19b))/0xa+parseInt(_0xd0a521(0x1a2))/0xb;if(_0x7c96da===_0x49d72f)break;else _0x410501['push'](_0x410501['shift']());}catch(_0x6d9ef5){_0x410501['push'](_0x410501['shift']());}}}(a50_0x493c,0x42bb7));function a50_0x2eac(_0x26d4bf,_0x3a5d1e){_0x26d4bf=_0x26d4bf-0x18c;const _0x493c1e=a50_0x493c();let _0x2eace1=_0x493c1e[_0x26d4bf];return _0x2eace1;}import{getSqlQueryInfo,generateSqlCodeTemplate}from'../../core/api-client.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';export const codegenSql={'service':a50_0xc7434d(0x193),'command':a50_0xc7434d(0x191),'description':a50_0xc7434d(0x192),'risk':a50_0xc7434d(0x194),'flags':[SQLCODE_FLAG,{'name':a50_0xc7434d(0x19c),'type':'string','description':a50_0xc7434d(0x198),'default':a50_0xc7434d(0x195),'enum':[a50_0xc7434d(0x195),a50_0xc7434d(0x18e)]},{'name':a50_0xc7434d(0x196),'type':'boolean','description':'Omit\x20import\x20statements\x20from\x20generated\x20code'}],async 'execute'(_0xcddb92){const _0x1fc941=a50_0xc7434d,_0x475e01=await getSqlQueryInfo(_0xcddb92[_0x1fc941(0x1a0)],_0xcddb92[_0x1fc941(0x18c)]('sqlcode')),_0xc86577=_0xcddb92[_0x1fc941(0x18c)](_0x1fc941(0x19c))||_0x1fc941(0x195),_0x20c15b=generateSqlCodeTemplate(_0x475e01,{'target':_0xc86577,'includeImports':!_0xcddb92[_0x1fc941(0x19f)](_0x1fc941(0x196))});return{'ok':!![],'data':{'sqlCode':_0x475e01[_0x1fc941(0x199)],'sqlName':_0x475e01['sqlName'],'target':_0xc86577,'code':_0x20c15b}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a51_0x13ac(){const _0x42b9b7=['271249dSfwHC','Updated','\x20Default\x20app\x20changed\x20to\x20\x22','910972TOowfi','args','validation','App\x20code','\x20Note:\x20app\x20\x22','Added','\x20<name>','Removed\x20app\x20\x22','210rkwNUL','global','trim','\x22\x20is\x20selected\x20automatically.','5PonjDW','162531BUHmJk','2YKEgZE','\x20<name>\x20[--global]','514482xeFGUE','keys','globalConfig','appcode','\x22\x20not\x20found.','boolean','1681823EXgftT','string','apps','Missing\x20app\x20name.','project','str','894513yOKgPa','\x20config.','\x20<name>\x20--appcode\x20<code>','8136agWvtN','flagMissing','60QkTqrT','projectConfig','232uYBgzi','Use\x20global\x20config\x20scope','defaultApp','\x20Default\x20app\x20is\x20\x22','1246lfHIuC','App\x20\x22','length','Usage:\x20','object','both','\x22\x20(appcode:\x20'];a51_0x13ac=function(){return _0x42b9b7;};return a51_0x13ac();}(function(_0x18172c,_0x55dd66){const _0x292c2b=a51_0xc43e,_0x656b3c=_0x18172c();while(!![]){try{const _0xb68772=-parseInt(_0x292c2b(0x14c))/0x1+-parseInt(_0x292c2b(0x14a))/0x2*(parseInt(_0x292c2b(0x127))/0x3)+parseInt(_0x292c2b(0x13c))/0x4*(parseInt(_0x292c2b(0x148))/0x5)+parseInt(_0x292c2b(0x12a))/0x6*(parseInt(_0x292c2b(0x132))/0x7)+parseInt(_0x292c2b(0x12e))/0x8*(-parseInt(_0x292c2b(0x149))/0x9)+parseInt(_0x292c2b(0x144))/0xa*(parseInt(_0x292c2b(0x139))/0xb)+parseInt(_0x292c2b(0x12c))/0xc*(parseInt(_0x292c2b(0x152))/0xd);if(_0xb68772===_0x55dd66)break;else _0x656b3c['push'](_0x656b3c['shift']());}catch(_0x2c2534){_0x656b3c['push'](_0x656b3c['shift']());}}}(a51_0x13ac,0x489e1));import{CliErrors}from'../../errors.js';function a51_0xc43e(_0x5ddc1e,_0x488e48){_0x5ddc1e=_0x5ddc1e-0x125;const _0x13ac1a=a51_0x13ac();let _0xc43e74=_0x13ac1a[_0x5ddc1e];return _0xc43e74;}import{CLI_BIN_NAME}from'../../constant/cli.js';import{collectAppProfileOverrides,getAppProfileFlagDefs,normalizeStoredDefaultApp}from'../../config/schema.js';import{readRawConfigWithLayers}from'../../context.js';import{readConfig,writeConfig,scopeLabel,resolveAppScopeForWrite,appDefinedIn}from'../../commands/app/shared.js';export function buildAppAddFlags(){const _0x8e3830=a51_0xc43e;return[{'name':_0x8e3830(0x14f),'type':_0x8e3830(0x153),'description':_0x8e3830(0x13f),'required':!![]},{'name':_0x8e3830(0x145),'type':'boolean','description':_0x8e3830(0x12f),'default':![]},...getAppProfileFlagDefs()];}export function buildAppRemoveFlags(){const _0x5240ff=a51_0xc43e;return[{'name':_0x5240ff(0x145),'type':_0x5240ff(0x151),'description':'Use\x20global\x20config\x20scope','default':![]}];}export async function validateAppName(_0x26833a,_0xe098d4){const _0x255a8d=a51_0xc43e,_0x248128=_0x26833a[_0x255a8d(0x13d)][0x0]?.[_0x255a8d(0x146)]();if(!_0x248128)throw CliErrors[_0x255a8d(0x13e)](_0x255a8d(0x155),'Usage:\x20'+CLI_BIN_NAME+'\x20'+_0xe098d4+_0x255a8d(0x142));}export async function runAppAdd(_0x4974fc,_0x16dafc){const _0x9b212a=a51_0xc43e,_0xb4a0c=_0x4974fc[_0x9b212a(0x13d)][0x0]?.[_0x9b212a(0x146)]();if(!_0xb4a0c)throw CliErrors[_0x9b212a(0x13e)]('Missing\x20app\x20name.',_0x9b212a(0x135)+CLI_BIN_NAME+'\x20'+_0x16dafc+_0x9b212a(0x129));const _0x667a1d=_0x4974fc['str'](_0x9b212a(0x14f));if(!_0x667a1d)throw CliErrors[_0x9b212a(0x12b)]('appcode',_0x9b212a(0x135)+CLI_BIN_NAME+'\x20'+_0x16dafc+_0x9b212a(0x129));const _0x6fd6ea={'global':_0x4974fc['bool'](_0x9b212a(0x145))},_0x339cd9=readConfig(_0x6fd6ea);if(!_0x339cd9[_0x9b212a(0x154)])_0x339cd9[_0x9b212a(0x154)]={};const _0x49e77d={'appcode':_0x667a1d,...collectAppProfileOverrides(_0x2d220d=>_0x4974fc[_0x9b212a(0x126)](_0x2d220d))},_0x427c4d=_0x339cd9[_0x9b212a(0x154)],_0x373932=Object[_0x9b212a(0x14d)](_0x427c4d),_0xcd4b1d=typeof _0x339cd9[_0x9b212a(0x130)]==='string'&&_0x427c4d[_0x339cd9[_0x9b212a(0x130)]]?_0x339cd9[_0x9b212a(0x130)]:_0x373932[_0x9b212a(0x134)]===0x1?_0x373932[0x0]:undefined,_0x35a2c7=!!_0x427c4d[_0xb4a0c];_0x427c4d[_0xb4a0c]=_0x49e77d;const _0x50b560=normalizeStoredDefaultApp(_0x339cd9,_0xcd4b1d);writeConfig(_0x339cd9,_0x6fd6ea);const _0x550672=!_0x35a2c7&&_0x50b560?_0x9b212a(0x131)+_0x50b560+'\x22.':'',_0x2da485=(_0x35a2c7?_0x9b212a(0x13a):_0x9b212a(0x141))+'\x20app\x20\x22'+_0xb4a0c+_0x9b212a(0x138)+_0x667a1d+')'+scopeLabel(_0x6fd6ea)+'.'+_0x550672;return{'ok':!![],'message':_0x2da485};}export async function runAppRemove(_0x1e7c0b,_0x3c5be1){const _0x433ee7=a51_0xc43e,_0x3d87eb=_0x1e7c0b[_0x433ee7(0x13d)][0x0]?.['trim']();if(!_0x3d87eb)throw CliErrors[_0x433ee7(0x13e)](_0x433ee7(0x155),_0x433ee7(0x135)+CLI_BIN_NAME+'\x20'+_0x3c5be1+_0x433ee7(0x14b));const _0x20718d=_0x1e7c0b['bool'](_0x433ee7(0x145)),{config:_0x32ff3f,layers:_0xb8891f}=readRawConfigWithLayers(),_0x14347f=_0x32ff3f[_0x433ee7(0x154)]??{};if(!_0x14347f[_0x3d87eb])throw CliErrors['validation'](_0x433ee7(0x133)+_0x3d87eb+_0x433ee7(0x150));const _0x16c61c=_0xb8891f[_0x433ee7(0x14e)]['apps']&&typeof _0xb8891f[_0x433ee7(0x14e)][_0x433ee7(0x154)]===_0x433ee7(0x136)?_0xb8891f[_0x433ee7(0x14e)][_0x433ee7(0x154)]:{},_0x20ced8=_0xb8891f[_0x433ee7(0x12d)][_0x433ee7(0x154)]&&typeof _0xb8891f[_0x433ee7(0x12d)][_0x433ee7(0x154)]==='object'?_0xb8891f[_0x433ee7(0x12d)]['apps']:{},_0x27b9a5=appDefinedIn(_0x3d87eb,_0x16c61c,_0x20ced8),_0x263c10=resolveAppScopeForWrite(_0x3d87eb,_0x20718d,_0xb8891f),_0x290e8d={'global':_0x263c10===_0x433ee7(0x145)},_0x404c1a=readConfig(_0x290e8d),_0x38a3bc=_0x404c1a['apps'];if(!_0x38a3bc||!_0x38a3bc[_0x3d87eb])throw CliErrors['validation'](_0x433ee7(0x133)+_0x3d87eb+_0x433ee7(0x150));delete _0x38a3bc[_0x3d87eb];let _0x1fbaf4='';const _0x2c9b6a=typeof _0x404c1a['defaultApp']===_0x433ee7(0x153)?_0x404c1a[_0x433ee7(0x130)]:undefined,_0xf7eb82=Object['keys'](_0x38a3bc),_0x16a5cf=_0x2c9b6a===_0x3d87eb?_0xf7eb82[0x0]:_0x2c9b6a,_0x4ad822=normalizeStoredDefaultApp(_0x404c1a,_0x16a5cf);if(_0x2c9b6a===_0x3d87eb&&_0xf7eb82[_0x433ee7(0x134)]===0x1)_0x1fbaf4='\x20Remaining\x20app\x20\x22'+_0xf7eb82[0x0]+_0x433ee7(0x147);else _0x2c9b6a===_0x3d87eb&&_0x4ad822&&(_0x1fbaf4=_0x433ee7(0x13b)+_0x4ad822+'\x22.');Object[_0x433ee7(0x14d)](_0x38a3bc)['length']===0x0&&(delete _0x404c1a[_0x433ee7(0x154)],delete _0x404c1a['defaultApp']);writeConfig(_0x404c1a,_0x290e8d);const _0x4a2d5b=_0x27b9a5===_0x433ee7(0x137)?_0x433ee7(0x140)+_0x3d87eb+'\x22\x20still\x20defined\x20in\x20'+(_0x263c10===_0x433ee7(0x125)?_0x433ee7(0x145):_0x433ee7(0x125))+_0x433ee7(0x128):'';return{'ok':!![],'message':_0x433ee7(0x143)+_0x3d87eb+'\x22'+scopeLabel(_0x290e8d)+'.'+_0x1fbaf4+_0x4a2d5b};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2e377d,_0x206f99){const _0x3aa781=a52_0xc1e7,_0x1fc96a=_0x2e377d();while(!![]){try{const _0x2cd00b=-parseInt(_0x3aa781(0x1dc))/0x1*(parseInt(_0x3aa781(0x1d6))/0x2)+-parseInt(_0x3aa781(0x1e2))/0x3+parseInt(_0x3aa781(0x1f0))/0x4+-parseInt(_0x3aa781(0x1d4))/0x5+parseInt(_0x3aa781(0x1e5))/0x6*(parseInt(_0x3aa781(0x1e0))/0x7)+-parseInt(_0x3aa781(0x1ef))/0x8*(-parseInt(_0x3aa781(0x1e9))/0x9)+parseInt(_0x3aa781(0x1da))/0xa*(-parseInt(_0x3aa781(0x1d2))/0xb);if(_0x2cd00b===_0x206f99)break;else _0x1fc96a['push'](_0x1fc96a['shift']());}catch(_0x10487b){_0x1fc96a['push'](_0x1fc96a['shift']());}}}(a52_0x5b66,0x457f7));import{input,checkbox,select}from'@inquirer/prompts';import a52_0x301497 from'chalk';function a52_0xc1e7(_0x181ea7,_0x2324d9){_0x181ea7=_0x181ea7-0x1cb;const _0x5b668a=a52_0x5b66();let _0xc1e7f8=_0x5b668a[_0x181ea7];return _0xc1e7f8;}import{validateAppcode}from'../../commands/common/validate.js';import{listRemoteApps}from'../../core/api-client.js';import{withActiveCookie}from'../../utils/with-active-cookie.js';function a52_0x5b66(){const _0x1f72b5=['(No\x20login\x20session.\x20Enter\x20an\x20App\x20Code\x20manually\x20or\x20skip.)','Fetching\x20available\x20apps...','appName','7IIaGgm','cyan','548670xKMuiW','App\x20Code:','Could\x20not\x20fetch\x20the\x20remote\x20app\x20list.\x20Enter\x20an\x20App\x20Code\x20manually.','3151794diutQp','trim','\x0aNo\x20available\x20apps\x20found.','message','95400OTVPVG','yellow','Invalid\x20App\x20Code','custom','manual','\x20apps.\x20Select\x20with\x20space,\x20a=all,\x20i=invert:','408lxcUIn','1720720jqTCzr','map','No\x20available\x20apps\x20found.','gray','✎\x20Enter\x20manually','✎\x20Enter\x20appcode\x20manually','(Skip;\x20configure\x20later\x20with\x20config\x20set\x20appcode)','length','6424847fIMXkT','find','1469680FiDJjO','\x20\x20(','27366ApkJRq','(Skip;\x20configure\x20later)','Found\x20','appCode','10dmAWhS','skip','11giziYf'];a52_0x5b66=function(){return _0x1f72b5;};return a52_0x5b66();}import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';export async function promptCustomAppcode(){const _0x24422b=a52_0xc1e7,_0x8ff700=await input({'message':_0x24422b(0x1e3),'validate':_0x22570f=>{const _0x34fcc9=_0x24422b,_0x5cb079=validateAppcode(_0x22570f[_0x34fcc9(0x1e6)]());return _0x5cb079['valid']||_0x5cb079[_0x34fcc9(0x1e8)]||_0x34fcc9(0x1eb);}});return _0x8ff700['trim']();}export async function promptAppSelection(_0x21b36a){const _0x408392=a52_0xc1e7,_0x33d197=[{'name':a52_0x301497['yellow'](_0x408392(0x1cf)),'value':-0x1},..._0x21b36a[_0x408392(0x1cb)]((_0x4a65c5,_0x56a7ad)=>({'name':_0x4a65c5[_0x408392(0x1df)]+'\x20\x20'+a52_0x301497['gray']('('+_0x4a65c5[_0x408392(0x1d9)]+')'),'value':_0x56a7ad}))],_0x179d07=await checkbox({'message':_0x408392(0x1d8)+a52_0x301497[_0x408392(0x1e1)](_0x21b36a[_0x408392(0x1d1)])+_0x408392(0x1ee),'choices':_0x33d197,'loop':![]});if(_0x179d07['includes'](-0x1))return'custom';if(_0x179d07[_0x408392(0x1d1)]===0x0)return _0x408392(0x1ec);return _0x179d07[_0x408392(0x1cb)](_0x485402=>_0x21b36a[_0x485402]);}export async function promptSingleAppSelection(_0x559a2f){const _0x511569=a52_0xc1e7,_0x115341=[{'name':a52_0x301497[_0x511569(0x1cd)](_0x511569(0x1d0)),'value':'skip'},{'name':a52_0x301497['yellow']('✎\x20Enter\x20appcode\x20manually'),'value':_0x511569(0x1ec)},..._0x559a2f[_0x511569(0x1cb)](_0xa6ee69=>({'name':_0xa6ee69['appName']+'\x20\x20'+a52_0x301497[_0x511569(0x1cd)]('('+_0xa6ee69[_0x511569(0x1d9)]+')'),'value':_0xa6ee69[_0x511569(0x1d9)]}))],_0x208cc8=await select({'message':'Select\x20the\x20app\x20to\x20bind:','choices':_0x115341});if(_0x208cc8===_0x511569(0x1db))return _0x511569(0x1db);if(_0x208cc8===_0x511569(0x1ec))return _0x511569(0x1ec);return _0x559a2f[_0x511569(0x1d3)](_0x35e89a=>_0x35e89a[_0x511569(0x1d9)]===_0x208cc8);}export async function selectSingleAppcode(_0x43b866){const _0x47b8c9=a52_0xc1e7;if(!_0x43b866)return writeCliSideChannelLine(a52_0x301497[_0x47b8c9(0x1cd)](_0x47b8c9(0x1dd))),_fallbackOrSkip();writeCliSideChannelLine('Fetching\x20available\x20apps...');let _0x5008b3;try{_0x5008b3=await withActiveCookie(_0x43b866,()=>listRemoteApps());}catch(_0x140ef7){writeCliSideChannelLine(a52_0x301497[_0x47b8c9(0x1ea)](_0x47b8c9(0x1e4)));if(_0x140ef7 instanceof Error)writeCliSideChannelLine(a52_0x301497[_0x47b8c9(0x1cd)](_0x47b8c9(0x1d5)+_0x140ef7[_0x47b8c9(0x1e8)]+')'));return _fallbackOrSkip();}if(_0x5008b3[_0x47b8c9(0x1d1)]===0x0)return writeCliSideChannelLine(a52_0x301497[_0x47b8c9(0x1ea)](_0x47b8c9(0x1cc))),_fallbackOrSkip();const _0x5a6601=await promptSingleAppSelection(_0x5008b3);if(_0x5a6601===_0x47b8c9(0x1db))return'';if(_0x5a6601===_0x47b8c9(0x1ec))return promptCustomAppcode();return _0x5a6601[_0x47b8c9(0x1d9)];}export async function selectMultipleApps(_0x415a4e){const _0x19bed3=a52_0xc1e7;writeCliSideChannelLine(_0x19bed3(0x1de));let _0x328600;try{_0x328600=await withActiveCookie(_0x415a4e,()=>listRemoteApps());}catch(_0x272bcf){writeCliSideChannelLine('\x0aCould\x20not\x20fetch\x20the\x20remote\x20app\x20list.\x20Enter\x20an\x20App\x20Code\x20manually.');if(_0x272bcf instanceof Error)writeCliSideChannelLine(_0x19bed3(0x1d5)+_0x272bcf[_0x19bed3(0x1e8)]+')');return _0x19bed3(0x1ec);}if(_0x328600['length']===0x0)return writeCliSideChannelLine(_0x19bed3(0x1e7)),'custom';return promptAppSelection(_0x328600);}async function _fallbackOrSkip(){const _0x31d206=a52_0xc1e7,_0x4f77d5=await select({'message':_0x31d206(0x1e3),'choices':[{'name':a52_0x301497['gray'](_0x31d206(0x1d7)),'value':_0x31d206(0x1db)},{'name':a52_0x301497[_0x31d206(0x1ea)](_0x31d206(0x1ce)),'value':_0x31d206(0x1ed)}]});if(_0x4f77d5===_0x31d206(0x1db))return'';return promptCustomAppcode();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a53_0x175728=a53_0x137e;(function(_0x43fb63,_0x2fe9ac){const _0x1a9fb3=a53_0x137e,_0x1a0b56=_0x43fb63();while(!![]){try{const _0x101a44=parseInt(_0x1a9fb3(0xe2))/0x1*(parseInt(_0x1a9fb3(0xf6))/0x2)+-parseInt(_0x1a9fb3(0xe4))/0x3*(-parseInt(_0x1a9fb3(0xec))/0x4)+-parseInt(_0x1a9fb3(0xe9))/0x5*(parseInt(_0x1a9fb3(0xe6))/0x6)+parseInt(_0x1a9fb3(0xef))/0x7*(parseInt(_0x1a9fb3(0xfe))/0x8)+-parseInt(_0x1a9fb3(0xeb))/0x9+-parseInt(_0x1a9fb3(0xea))/0xa+parseInt(_0x1a9fb3(0xf9))/0xb*(parseInt(_0x1a9fb3(0xfd))/0xc);if(_0x101a44===_0x2fe9ac)break;else _0x1a0b56['push'](_0x1a0b56['shift']());}catch(_0x40a90f){_0x1a0b56['push'](_0x1a0b56['shift']());}}}(a53_0x4cf3,0x93d4b));function a53_0x4cf3(){const _0x21f60d=['4331090sfPVPr','8838927CuUODR','11504SawsZM','apiError','\x20--appcode\x20','16030ORDESm','SUCCESS','Task\x20','has','PENDING','\x20--format\x20compress','\x20task\x20status\x20--task-id\x20','6570lVitss','\x27\x5c\x27\x27','PROCESSING','35222qUwZrb','status','\x20failed:\x20','taskId','1608HfqNKA','4112gPFiXH','\x20completed\x20successfully.','\x20failed.','toUpperCase','Async\x20task\x20','FAILED','247kESyxT','Async\x20task\x20response\x20did\x20not\x20contain\x20a\x20taskId.','351VEDPyX','string','30984lNEHcF','trim','errorMessage','710KUPsLR'];a53_0x4cf3=function(){return _0x21f60d;};return a53_0x4cf3();}import{CLI_BIN_NAME}from'../../constant/cli.js';import{CliErrors}from'../../errors.js';const TERMINAL_STATUSES=new Set([a53_0x175728(0xf0),a53_0x175728(0xe1)]),NON_TERMINAL_STATUSES=new Set([a53_0x175728(0xf3),a53_0x175728(0xf8)]);export function normalizeAsyncTask(_0x24d7a6){const _0x400e69=a53_0x175728,_0x1807d5=typeof _0x24d7a6?.[_0x400e69(0xfc)]===_0x400e69(0xe5)?_0x24d7a6['taskId'][_0x400e69(0xe7)]():'';if(!_0x1807d5)throw CliErrors['apiError'](_0x400e69(0xe3));const _0x4a0e05=typeof _0x24d7a6['status']===_0x400e69(0xe5)?_0x24d7a6[_0x400e69(0xfa)][_0x400e69(0xe7)]()[_0x400e69(0x101)]():'';if(!_0x4a0e05)throw CliErrors[_0x400e69(0xed)](_0x400e69(0xe0)+_0x1807d5+'\x20response\x20did\x20not\x20contain\x20a\x20status.');return{'taskId':_0x1807d5,'status':_0x4a0e05,'errorMessage':typeof _0x24d7a6[_0x400e69(0xe8)]===_0x400e69(0xe5)&&_0x24d7a6[_0x400e69(0xe8)]['trim']()?_0x24d7a6[_0x400e69(0xe8)][_0x400e69(0xe7)]():null,'isTerminal':TERMINAL_STATUSES[_0x400e69(0xf2)](_0x4a0e05),'knownStatus':TERMINAL_STATUSES[_0x400e69(0xf2)](_0x4a0e05)||NON_TERMINAL_STATUSES[_0x400e69(0xf2)](_0x4a0e05)};}export function buildAsyncTaskStatusCommand(_0x4754da,_0x3812f3){const _0x2b34e0=a53_0x175728;return CLI_BIN_NAME+_0x2b34e0(0xf5)+quoteShellArg(_0x4754da)+_0x2b34e0(0xee)+quoteShellArg(_0x3812f3)+_0x2b34e0(0xf4);}export function asyncTaskMessage(_0xb7e16e){const _0x13a1cc=a53_0x175728;switch(_0xb7e16e[_0x13a1cc(0xfa)]){case _0x13a1cc(0xf3):return _0x13a1cc(0xf1)+_0xb7e16e[_0x13a1cc(0xfc)]+'\x20is\x20pending.';case _0x13a1cc(0xf8):return _0x13a1cc(0xf1)+_0xb7e16e[_0x13a1cc(0xfc)]+'\x20is\x20processing.';case _0x13a1cc(0xf0):return _0x13a1cc(0xf1)+_0xb7e16e['taskId']+_0x13a1cc(0xff);case _0x13a1cc(0xe1):return _0xb7e16e['errorMessage']?_0x13a1cc(0xf1)+_0xb7e16e[_0x13a1cc(0xfc)]+_0x13a1cc(0xfb)+_0xb7e16e['errorMessage']:_0x13a1cc(0xf1)+_0xb7e16e[_0x13a1cc(0xfc)]+_0x13a1cc(0x100);default:return _0x13a1cc(0xf1)+_0xb7e16e[_0x13a1cc(0xfc)]+'\x20returned\x20unknown\x20status\x20'+_0xb7e16e[_0x13a1cc(0xfa)]+'.';}}function a53_0x137e(_0x5ea65d,_0x1cd478){_0x5ea65d=_0x5ea65d-0xe0;const _0x4cf38c=a53_0x4cf3();let _0x137e71=_0x4cf38c[_0x5ea65d];return _0x137e71;}function quoteShellArg(_0xabfddf){const _0x2c52c6=a53_0x175728;return'\x27'+_0xabfddf['replace'](/'/g,_0x2c52c6(0xf7))+'\x27';}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a54_0x4ac8(){var _0x246c7a=['331119kIdlYN','defineProperties','description','4550124yNEtpJ','12415336RBiRsd','10447598xdqNtY','765670ZlIfOF','3450148YWNnQx','5SvEsLF','18XdvHyt','117350qgAyUk','1969KUsCsU','9OeUbnL','method'];a54_0x4ac8=function(){return _0x246c7a;};return a54_0x4ac8();}(function(_0x54f6bb,_0x5f2fcf){var _0x31890b=a54_0x4e74,_0x4bd349=_0x54f6bb();while(!![]){try{var _0x20a0a9=parseInt(_0x31890b(0x128))/0x1+-parseInt(_0x31890b(0x11d))/0x2*(parseInt(_0x31890b(0x122))/0x3)+parseInt(_0x31890b(0x129))/0x4+parseInt(_0x31890b(0x12a))/0x5*(-parseInt(_0x31890b(0x125))/0x6)+parseInt(_0x31890b(0x127))/0x7+parseInt(_0x31890b(0x126))/0x8*(parseInt(_0x31890b(0x120))/0x9)+parseInt(_0x31890b(0x11e))/0xa*(-parseInt(_0x31890b(0x11f))/0xb);if(_0x20a0a9===_0x5f2fcf)break;else _0x4bd349['push'](_0x4bd349['shift']());}catch(_0x205811){_0x4bd349['push'](_0x4bd349['shift']());}}}(a54_0x4ac8,0xc848a));function a54_0x4e74(_0x286389,_0x570d4d){_0x286389=_0x286389-0x11d;var _0x4ac8a6=a54_0x4ac8();var _0x4e749b=_0x4ac8a6[_0x286389];return _0x4e749b;}export function asDryRunResult(_0x3d292b,_0x1b2b34){var _0x3f5d38=a54_0x4e74;return Object[_0x3f5d38(0x123)](_0x3d292b,{'method':{'value':_0x1b2b34[_0x3f5d38(0x121)],'enumerable':![]},'url':{'value':_0x1b2b34['url'],'enumerable':![]},..._0x1b2b34[_0x3f5d38(0x124)]?{'description':{'value':_0x1b2b34[_0x3f5d38(0x124)],'enumerable':![]}}:{}});}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a55_0xb7dd4e=a55_0x3f04;(function(_0x3d3178,_0x1d0f15){const _0x1420e2=a55_0x3f04,_0x42c791=_0x3d3178();while(!![]){try{const _0xfd2b03=-parseInt(_0x1420e2(0x1fd))/0x1*(parseInt(_0x1420e2(0x202))/0x2)+-parseInt(_0x1420e2(0x1fc))/0x3+-parseInt(_0x1420e2(0x1e5))/0x4*(parseInt(_0x1420e2(0x1e7))/0x5)+-parseInt(_0x1420e2(0x1f5))/0x6*(-parseInt(_0x1420e2(0x1de))/0x7)+-parseInt(_0x1420e2(0x1fe))/0x8+-parseInt(_0x1420e2(0x1fb))/0x9*(-parseInt(_0x1420e2(0x1ee))/0xa)+parseInt(_0x1420e2(0x204))/0xb*(parseInt(_0x1420e2(0x1dd))/0xc);if(_0xfd2b03===_0x1d0f15)break;else _0x42c791['push'](_0x42c791['shift']());}catch(_0x4088e4){_0x42c791['push'](_0x42c791['shift']());}}}(a55_0x92ab,0x909dc));export const CROSS_RELATION_FROM_DATASET_FLAG={'name':a55_0xb7dd4e(0x1f0),'type':a55_0xb7dd4e(0x1f2),'required':!![],'description':a55_0xb7dd4e(0x1fa)};export const CROSS_RELATION_FROM_COLUMN_FLAG={'name':a55_0xb7dd4e(0x1df),'type':a55_0xb7dd4e(0x1f2),'required':!![],'description':a55_0xb7dd4e(0x1f8)};export const CROSS_RELATION_TO_DATASET_FLAG={'name':a55_0xb7dd4e(0x1ed),'type':a55_0xb7dd4e(0x1f2),'required':!![],'description':a55_0xb7dd4e(0x1e2)};export const CROSS_RELATION_TO_COLUMN_FLAG={'name':'to-column','type':'string','required':!![],'description':a55_0xb7dd4e(0x1e9)};export const CROSS_RELATION_DBLINK_FLAG={'name':'from-dblink-id','type':a55_0xb7dd4e(0x1f3),'description':a55_0xb7dd4e(0x1e8)};export const CROSS_RELATION_LABEL_FLAG={'name':'to-label-column','type':a55_0xb7dd4e(0x1f2),'description':a55_0xb7dd4e(0x1ec)};export const CROSS_RELATION_CARDINALITY_FLAG={'name':a55_0xb7dd4e(0x203),'type':a55_0xb7dd4e(0x1f2),'enum':['ONE_TO_ONE',a55_0xb7dd4e(0x200),a55_0xb7dd4e(0x1f6),'MANY_TO_MANY'],'description':a55_0xb7dd4e(0x1ea)};export const GLOBAL_SCOPE_FLAG={'name':a55_0xb7dd4e(0x201),'type':a55_0xb7dd4e(0x1f9),'default':![],'description':a55_0xb7dd4e(0x1e6)};export const DATASET_CODE_PATTERN={'regex':/^[a-f0-9]{32}(?:_[^_\s]+_[^_\s]+)?$/i,'description':a55_0xb7dd4e(0x1f1)};function a55_0x3f04(_0x20d062,_0x5081a0){_0x20d062=_0x20d062-0x1dd;const _0x92ab8f=a55_0x92ab();let _0x3f041a=_0x92ab8f[_0x20d062];return _0x3f041a;}export const CODE_FLAG={'name':'code','type':a55_0xb7dd4e(0x1f2),'required':!![],'description':a55_0xb7dd4e(0x1e3),'pattern':DATASET_CODE_PATTERN};export const CODE_FLAG_OPTIONAL={...CODE_FLAG,'required':![]};export const DATASETCODE_FLAG_OPTIONAL={...CODE_FLAG_OPTIONAL,'name':a55_0xb7dd4e(0x1e4),'description':a55_0xb7dd4e(0x1e3)};export const SQLCODE_FLAG={'name':a55_0xb7dd4e(0x1f7),'type':a55_0xb7dd4e(0x1f2),'required':!![],'description':'SQL\x20code\x20identifier\x20(format:\x20xxxxxxxx-xxxxxxxx,\x20e.g.\x202305f915-dd48cd4c)','pattern':{'regex':/^[a-f0-9]{8}-[a-f0-9]{8}$/i,'description':a55_0xb7dd4e(0x1eb)}};export const APPCODE_FLAG_OPTIONAL={'name':a55_0xb7dd4e(0x1ef),'type':'string','required':![],'description':a55_0xb7dd4e(0x1e1)};export const APPCODE_FLAG={...APPCODE_FLAG_OPTIONAL,'required':!![],'description':a55_0xb7dd4e(0x1e0)};export const SQLCODE_FLAG_OPTIONAL={...SQLCODE_FLAG,'required':![]};export const DBLINK_ID_FLAG={'name':'id','type':a55_0xb7dd4e(0x1f3),'required':!![],'description':a55_0xb7dd4e(0x1f4)};function a55_0x92ab(){const _0x1db7be=['Source\x20DB_TABLE\x20dataset\x20code','3576942ecRMtC','3103356loxcNd','21531ohgyOs','2763704TpcAaR','MYSQL','ONE_TO_MANY','global','106kPOaDx','cardinality','31163pkxhpR','Database\x20product\x20type','9756ylYTWL','666827njQrgT','from-column','App\x20code\x20(e.g.\x20app-xxxxx)','App\x20code\x20(overrides\x20config\x20file,\x20e.g.\x20app-xxxxx)','Target\x20DB_TABLE\x20dataset\x20code','Dataset\x20code\x20(32-char\x20hex,\x20optionally\x20with\x20_xx_xx\x20suffix)','datasetcode','288xhlySL','Write\x20to\x20the\x20global\x20configuration','17645syepxo','Source\x20database\x20connection\x20ID;\x20derived\x20from\x20the\x20source\x20dataset\x20when\x20omitted','Target\x20field\x20name','Relation\x20cardinality;\x20create\x20leaves\x20it\x20unset\x20when\x20omitted,\x20update\x20keeps\x20the\x20current\x20value','SQL\x20code\x20in\x20format\x20xxxxxxxx-xxxxxxxx\x20(e.g.\x202305f915-dd48cd4c)','Target\x20display\x20field;\x20create\x20defaults\x20to\x20the\x20target\x20field,\x20update\x20keeps\x20the\x20current\x20value','to-datasetcode','10vvfDkn','appcode','from-datasetcode','a\x2032-character\x20hex\x20code,\x20optionally\x20with\x20`_xx_xx`\x20suffix\x20(e.g.\x2099a909313f1fa7153186431e1c551588\x20or\x2099a909313f1fa7153186431e1c551588_75_3c7120aa)','string','number','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','42VCqaIZ','MANY_TO_ONE','sqlcode','Source\x20field\x20name\x20used\x20to\x20locate\x20the\x20relation','boolean'];a55_0x92ab=function(){return _0x1db7be;};return a55_0x92ab();}export const DB_TYPE_FLAG={'name':'dbtype','type':a55_0xb7dd4e(0x1f2),'required':!![],'description':a55_0xb7dd4e(0x205),'enum':[a55_0xb7dd4e(0x1ff),'POSTGRESQL']};export const SKIP_CONNECTION_TEST_FLAG={'name':'skip-connection-test','type':'boolean','description':'Skip\x20testing\x20the\x20unsaved\x20database\x20configuration\x20before\x20create/update'};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x3b7f57,_0x57db5e){const _0x2a2f8b=a56_0x3220,_0x47c230=_0x3b7f57();while(!![]){try{const _0x401ec3=parseInt(_0x2a2f8b(0xd1))/0x1*(-parseInt(_0x2a2f8b(0xc7))/0x2)+parseInt(_0x2a2f8b(0xcf))/0x3*(parseInt(_0x2a2f8b(0xc2))/0x4)+-parseInt(_0x2a2f8b(0xc9))/0x5*(parseInt(_0x2a2f8b(0xc8))/0x6)+parseInt(_0x2a2f8b(0xc3))/0x7+parseInt(_0x2a2f8b(0xcd))/0x8*(parseInt(_0x2a2f8b(0xcc))/0x9)+-parseInt(_0x2a2f8b(0xca))/0xa+parseInt(_0x2a2f8b(0xcb))/0xb;if(_0x401ec3===_0x57db5e)break;else _0x47c230['push'](_0x47c230['shift']());}catch(_0x15948b){_0x47c230['push'](_0x47c230['shift']());}}}(a56_0x415f,0xcdf0a));import{existsSync,statSync}from'node:fs';function a56_0x415f(){const _0x22c27f=['File\x20exceeds\x20the\x20development\x20upload\x20limit\x20of\x2050\x20MB:\x20','4uTMnpH','40894qThXIX','isFile','size','File\x20is\x20not\x20a\x20regular\x20file:\x20','10eGAkop','26742zBRNGh','955StYDRI','15610650jGBfcr','44644446YeHgTB','395919eTGJnI','24YtKWaB','ceil','1848033BPtQTq','validation','311306yamwGq','toFixed'];a56_0x415f=function(){return _0x22c27f;};return a56_0x415f();}import{CliErrors}from'../../errors.js';function a56_0x3220(_0x38b553,_0x16e489){_0x38b553=_0x38b553-0xc1;const _0x415f44=a56_0x415f();let _0x322055=_0x415f44[_0x38b553];return _0x322055;}const BYTES_PER_MB=0x400*0x400;export const DEVELOPMENT_UPLOAD_MAX_BYTES=0x32*BYTES_PER_MB;function formatBytes(_0x1a8c33){const _0x12aaa5=a56_0x3220;if(_0x1a8c33>=BYTES_PER_MB){const _0x3184b9=Math[_0x12aaa5(0xce)](_0x1a8c33/BYTES_PER_MB*0x64)/0x64;return _0x3184b9[_0x12aaa5(0xd2)](0x2)+'\x20MB';}return _0x1a8c33+'\x20B';}export function requireDevelopmentUploadFile(_0x505c65,_0x711b57){const _0xea8bc5=a56_0x3220,_0x29c9d3=_0x505c65['trim']();if(!_0x29c9d3)throw CliErrors[_0xea8bc5(0xd0)](_0x711b57+'\x20path\x20is\x20required.');if(!existsSync(_0x29c9d3))throw CliErrors[_0xea8bc5(0xd0)]('File\x20not\x20found:\x20'+_0x29c9d3);const _0x1c61a1=statSync(_0x29c9d3);if(!_0x1c61a1[_0xea8bc5(0xc4)]())throw CliErrors[_0xea8bc5(0xd0)](_0xea8bc5(0xc6)+_0x29c9d3);if(_0x1c61a1['size']>DEVELOPMENT_UPLOAD_MAX_BYTES)throw CliErrors[_0xea8bc5(0xd0)](_0xea8bc5(0xc1)+_0x29c9d3+'\x20('+formatBytes(_0x1c61a1[_0xea8bc5(0xc5)])+')');return{'path':_0x29c9d3,'size':_0x1c61a1[_0xea8bc5(0xc5)]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a57_0x4bde(_0x5b15a4,_0xa3a8a2){_0x5b15a4=_0x5b15a4-0x172;const _0x1db85c=a57_0x1db8();let _0x4bde66=_0x1db85c[_0x5b15a4];return _0x4bde66;}(function(_0xcd4f43,_0x5a58ca){const _0x4a0c25=a57_0x4bde,_0x573dc0=_0xcd4f43();while(!![]){try{const _0x48440b=parseInt(_0x4a0c25(0x173))/0x1*(-parseInt(_0x4a0c25(0x17c))/0x2)+-parseInt(_0x4a0c25(0x183))/0x3*(-parseInt(_0x4a0c25(0x17f))/0x4)+-parseInt(_0x4a0c25(0x177))/0x5*(parseInt(_0x4a0c25(0x174))/0x6)+-parseInt(_0x4a0c25(0x178))/0x7*(-parseInt(_0x4a0c25(0x172))/0x8)+parseInt(_0x4a0c25(0x179))/0x9*(-parseInt(_0x4a0c25(0x17e))/0xa)+-parseInt(_0x4a0c25(0x17b))/0xb+-parseInt(_0x4a0c25(0x17a))/0xc*(-parseInt(_0x4a0c25(0x180))/0xd);if(_0x48440b===_0x5a58ca)break;else _0x573dc0['push'](_0x573dc0['shift']());}catch(_0x3688cd){_0x573dc0['push'](_0x573dc0['shift']());}}}(a57_0x1db8,0xa7b27));function a57_0x1db8(){const _0x459677=['2EaelPf','length','10LoZYGQ','68rpyxWa','2665HzMiRs','Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','App\x20Code\x20cannot\x20exceed\x20100\x20characters','149445TTzWoH','35656sBWroW','230890akgYJn','66zpEPhC','test','trim','158810BAMiLh','504xMYMze','10448892GbJyWJ','82776OAoyLY','1690722ynUNze'];a57_0x1db8=function(){return _0x459677;};return a57_0x1db8();}export function validateAppcode(_0x1cf726){const _0x59fb98=a57_0x4bde,_0x58277b=_0x1cf726[_0x59fb98(0x176)]();if(!_0x58277b)return{'valid':![],'message':'App\x20Code\x20cannot\x20be\x20empty'};if(_0x58277b[_0x59fb98(0x17d)]>0x64)return{'valid':![],'message':_0x59fb98(0x182)};if(!/^[A-Za-z0-9_-]+$/[_0x59fb98(0x175)](_0x58277b))return{'valid':![],'message':_0x59fb98(0x181)};return{'valid':!![]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a58_0x9ee0(){const _0x35fc41=['\x20already\x20absent','inherit','boolean','2796093Rblkbe','\x20config\x20delete\x20<key>\x20[--global]','4326114jfghfA','Project','delete','5224Anirkw','2253310FGNllR','\x22\x20is\x20not\x20deletable.','17504663BFLMus','9wqUkxL','Top-level\x20key\x20\x22','833aTvOGy','15FHUirD','6TLBANU','hasOwnProperty','prototype','\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.','defaultApp','riskLevel','validation','config','Missing\x20key\x20argument.','Global','has','Use\x20workspace\x20commands\x20to\x20modify\x20apps\x20and\x20their\x20default\x20selection.','\x20deleted','Usage:\x20','213757vFdqQC','Delete\x20a\x20config\x20value\x20from\x20one\x20scope','Delete\x20from\x20global\x20config\x20(~/.rabetbase.json)','key','bool','116300yDwoHg','Top-level\x20config\x20key;\x20legacy\x20inherit\x20is\x20accepted\x20for\x20migration','args','global','write','call'];a58_0x9ee0=function(){return _0x35fc41;};return a58_0x9ee0();}const a58_0x4a9201=a58_0x133c;(function(_0x2cad6b,_0x1dc4a9){const _0x13b5a0=a58_0x133c,_0x1789a4=_0x2cad6b();while(!![]){try{const _0x418b97=parseInt(_0x13b5a0(0x1b6))/0x1*(-parseInt(_0x13b5a0(0x1a8))/0x2)+-parseInt(_0x13b5a0(0x19b))/0x3+-parseInt(_0x13b5a0(0x1bb))/0x4*(parseInt(_0x13b5a0(0x1a7))/0x5)+parseInt(_0x13b5a0(0x19d))/0x6+-parseInt(_0x13b5a0(0x1a6))/0x7*(-parseInt(_0x13b5a0(0x1a0))/0x8)+parseInt(_0x13b5a0(0x1a4))/0x9*(-parseInt(_0x13b5a0(0x1a1))/0xa)+parseInt(_0x13b5a0(0x1a3))/0xb;if(_0x418b97===_0x1dc4a9)break;else _0x1789a4['push'](_0x1789a4['shift']());}catch(_0x164013){_0x1789a4['push'](_0x1789a4['shift']());}}}(a58_0x9ee0,0x7b189));import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME,isTopLevelConfigKey,readScopedConfig,resolveWriteScope,writeScopedConfig}from'../../commands/config/shared.js';const LEGACY_DELETABLE_KEYS=new Set([a58_0x4a9201(0x1c2)]),EXTRA_DELETABLE_KEYS=new Set([a58_0x4a9201(0x1ac),'routing']);async function execute(_0x30d52d){const _0x9582ed=a58_0x4a9201,_0x47a0e2=_0x30d52d[_0x9582ed(0x1bd)][0x0]?.['trim']();if(!_0x47a0e2)throw CliErrors[_0x9582ed(0x1ae)](_0x9582ed(0x1b0),_0x9582ed(0x1b5)+CLI_BIN_NAME+_0x9582ed(0x19c));if(_0x47a0e2===_0x9582ed(0x1ad))throw CliErrors[_0x9582ed(0x1ae)](_0x9582ed(0x1ab));if(!isTopLevelConfigKey(_0x47a0e2)&&!EXTRA_DELETABLE_KEYS['has'](_0x47a0e2)&&!LEGACY_DELETABLE_KEYS[_0x9582ed(0x1b2)](_0x47a0e2))throw CliErrors[_0x9582ed(0x1ae)](_0x9582ed(0x1a5)+_0x47a0e2+_0x9582ed(0x1a2),_0x9582ed(0x1b3));const _0x5846d1=resolveWriteScope({'global':_0x30d52d[_0x9582ed(0x1ba)](_0x9582ed(0x1be))}),_0x58cfd8=readScopedConfig(_0x5846d1),_0x520c6e=Object[_0x9582ed(0x1aa)][_0x9582ed(0x1a9)][_0x9582ed(0x1c0)](_0x58cfd8,_0x47a0e2);_0x520c6e&&(delete _0x58cfd8[_0x47a0e2],writeScopedConfig(_0x58cfd8,_0x5846d1));const _0xaacbdc=_0x5846d1==='global'?_0x9582ed(0x1b1):_0x9582ed(0x19e);return{'ok':!![],'message':_0x520c6e?'✓\x20'+_0xaacbdc+'\x20'+_0x47a0e2+_0x9582ed(0x1b4):'✓\x20'+_0xaacbdc+'\x20'+_0x47a0e2+_0x9582ed(0x1c1),'data':{'key':_0x47a0e2,'scope':_0x5846d1,'changed':_0x520c6e}};}function a58_0x133c(_0x2ecaf6,_0xcc37af){_0x2ecaf6=_0x2ecaf6-0x19b;const _0x9ee084=a58_0x9ee0();let _0x133c11=_0x9ee084[_0x2ecaf6];return _0x133c11;}export const configDeleteDefinition={'service':a58_0x4a9201(0x1af),'command':a58_0x4a9201(0x19f),'description':a58_0x4a9201(0x1b7),'risk':a58_0x4a9201(0x1bf),'requiresAuth':![],'requiresAppCode':![],'args':[{'name':a58_0x4a9201(0x1b9),'description':a58_0x4a9201(0x1bc),'required':!![]}],'flags':[{'name':a58_0x4a9201(0x1be),'type':a58_0x4a9201(0x1c3),'description':a58_0x4a9201(0x1b8),'default':![]}],'execute':execute};
|