@lovrabet/rabetbase-cli 2.5.11-beta.1 → 2.5.11
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
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
const a358_0xddae56=a358_0x4e6c;(function(_0x3e224b,_0x2b4b8a){const _0xe44345=a358_0x4e6c,_0x7bca1e=_0x3e224b();while(!![]){try{const _0x5c5ee9=-parseInt(_0xe44345(0xa6))/0x1+-parseInt(_0xe44345(0xb5))/0x2*(parseInt(_0xe44345(0xbb))/0x3)+parseInt(_0xe44345(0xa7))/0x4+-parseInt(_0xe44345(0xa4))/0x5*(-parseInt(_0xe44345(0xb9))/0x6)+parseInt(_0xe44345(0xa5))/0x7*(-parseInt(_0xe44345(0xad))/0x8)+parseInt(_0xe44345(0xae))/0x9*(parseInt(_0xe44345(0xcb))/0xa)+-parseInt(_0xe44345(0xbe))/0xb;if(_0x5c5ee9===_0x2b4b8a)break;else _0x7bca1e['push'](_0x7bca1e['shift']());}catch(_0x4b151d){_0x7bca1e['push'](_0x7bca1e['shift']());}}}(a358_0x4e12,0x6614b));import a358_0x24a756 from'node:fs';import a358_0x39c635 from'node:path';import a358_0x5c70d6 from'semver';import{getCdnConfig}from'../utils/cdn-config.js';const FALLBACK_MIN_SDK_VERSION=a358_0xddae56(0xc9);function isNonNumericVersion(_0x1cc4af){const _0x11957e=a358_0xddae56,_0x5ac937=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x5ac937[_0x11957e(0xc8)](_0x36b8a8=>_0x36b8a8[_0x11957e(0xa3)](_0x1cc4af));}function getInstalledVersion(_0x1263c6,_0x223c76){const _0x3d2d13=a358_0xddae56;try{const _0x11a4d5=a358_0x39c635[_0x3d2d13(0xb2)](_0x1263c6,_0x3d2d13(0xb0),_0x223c76,_0x3d2d13(0xb6));if(a358_0x24a756[_0x3d2d13(0xaf)](_0x11a4d5)){const _0x5e6266=JSON[_0x3d2d13(0xb7)](a358_0x24a756[_0x3d2d13(0xc3)](_0x11a4d5,_0x3d2d13(0xa9)));return _0x5e6266[_0x3d2d13(0xb8)]||null;}}catch{}return null;}function a358_0x4e6c(_0x1169d0,_0x110a3c){_0x1169d0=_0x1169d0-0xa3;const _0x4e1220=a358_0x4e12();let _0x4e6cbc=_0x4e1220[_0x1169d0];return _0x4e6cbc;}async function getSdkStableVersion(){const _0x465506=a358_0xddae56;try{const _0x5c3a23=await getCdnConfig();return _0x5c3a23?.[_0x465506(0xb1)]?.[_0x465506(0xc1)]?.[_0x465506(0xab)]||null;}catch{return null;}}async function getSdkPackageName(){const _0x20284c=a358_0xddae56;try{const _0x5f5959=await getCdnConfig();return _0x5f5959?.[_0x20284c(0xb1)]?.[_0x20284c(0xc1)]?.['packageName']||_0x20284c(0xc0);}catch{return _0x20284c(0xc0);}}export async function checkSdkVersion(_0x1ed7fe){const _0x23aabc=a358_0xddae56,_0x1edcc2=a358_0x39c635[_0x23aabc(0xb2)](_0x1ed7fe,_0x23aabc(0xb6)),[_0x186bc6,_0x5c5f2]=await Promise[_0x23aabc(0xb4)]([getSdkStableVersion(),getSdkPackageName()]),_0x10e12b=_0x186bc6||FALLBACK_MIN_SDK_VERSION;if(!a358_0x24a756[_0x23aabc(0xaf)](_0x1edcc2))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x10e12b,'packageName':_0x5c5f2,'stableVersion':_0x186bc6};try{const _0x237298=JSON[_0x23aabc(0xb7)](a358_0x24a756[_0x23aabc(0xc3)](_0x1edcc2,'utf8')),_0xec7996=_0x237298[_0x23aabc(0xaa)]||{},_0x19a83d=_0x237298[_0x23aabc(0xca)]||{},_0x38e002=_0xec7996[_0x5c5f2]||_0x19a83d[_0x5c5f2];if(!_0x38e002)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x10e12b,'packageName':_0x5c5f2,'stableVersion':_0x186bc6};let _0x2f28bf=getInstalledVersion(_0x1ed7fe,_0x5c5f2);!_0x2f28bf&&(_0x2f28bf=_0x38e002);if(isNonNumericVersion(_0x38e002))return{'installed':!![],'version':_0x2f28bf,'needsUpgrade':![],'minVersion':_0x10e12b,'packageName':_0x5c5f2,'stableVersion':_0x186bc6};const _0x5419c6=a358_0x5c70d6[_0x23aabc(0xc2)](_0x2f28bf),_0x444b8e=a358_0x5c70d6[_0x23aabc(0xc2)](_0x10e12b),_0x57c6ba=_0x5419c6&&_0x444b8e?a358_0x5c70d6['lt'](_0x5419c6,_0x444b8e):![];return{'installed':!![],'version':_0x2f28bf,'needsUpgrade':_0x57c6ba,'minVersion':_0x10e12b,'packageName':_0x5c5f2,'stableVersion':_0x186bc6};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x10e12b,'packageName':_0x5c5f2,'stableVersion':_0x186bc6};}}function a358_0x4e12(){const _0x2ed158=['↪\x20SDK\x20update\x20available','3705284guGNam','\x20\x20\x20Upgrade\x20command:\x20','@lovrabet/sdk','node','coerce','readFileSync','\x20\x20\x20Current\x20version:\x20','\x20\x20\x20Stable\x20version:\x20','\x1b[33m','minVersion','some','1.2.0','devDependencies','10ywbbns','needsUpgrade','test','2615pWASLw','1145739LBQnws','216188tzsFZV','1059480GCUCqg','packageName','utf-8','dependencies','stableVersion','log','8VMkxFV','7311105SrZLFB','existsSync','node_modules','sdk','join','utf8','all','126cDHwoU','package.json','parse','version','8148PrjQEz','\x1b[0m','31077ChShPc','\x1b[1m'];a358_0x4e12=function(){return _0x2ed158;};return a358_0x4e12();}export function checkSdkVersionSync(_0x31f383){const _0x265ff8=a358_0xddae56,_0x3e0e7f=a358_0x39c635['join'](_0x31f383,_0x265ff8(0xb6)),_0x58e9c5=_0x265ff8(0xc0);if(!a358_0x24a756['existsSync'](_0x3e0e7f))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x58e9c5,'stableVersion':null};try{const _0x14d335=JSON['parse'](a358_0x24a756[_0x265ff8(0xc3)](_0x3e0e7f,_0x265ff8(0xb3))),_0x332764=_0x14d335[_0x265ff8(0xaa)]||{},_0x55d508=_0x14d335[_0x265ff8(0xca)]||{},_0x400c20=_0x332764[_0x58e9c5]||_0x55d508[_0x58e9c5];if(!_0x400c20)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x58e9c5,'stableVersion':null};let _0x425545=getInstalledVersion(_0x31f383,_0x58e9c5);!_0x425545&&(_0x425545=_0x400c20);if(isNonNumericVersion(_0x400c20))return{'installed':!![],'version':_0x425545,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x58e9c5,'stableVersion':null};const _0x36aad9=a358_0x5c70d6[_0x265ff8(0xc2)](_0x425545),_0x1a1539=_0x36aad9?a358_0x5c70d6['lt'](_0x36aad9,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0x425545,'needsUpgrade':_0x1a1539,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x58e9c5,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x58e9c5,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x4b7915){const _0x2fb766=a358_0xddae56;if(!_0x4b7915[_0x2fb766(0xcc)])return;const _0x2c865e=_0x2fb766(0xc6),_0x3fa239=_0x2fb766(0xba),_0x142832=_0x2fb766(0xbc),_0x20c579=_0x4b7915[_0x2fb766(0xa8)]||_0x2fb766(0xc0),_0x29ef5c=_0x4b7915[_0x2fb766(0xab)]||_0x4b7915[_0x2fb766(0xc7)],_0x14c901='npm\x20install\x20'+_0x20c579+'@'+(_0x29ef5c||'latest');console[_0x2fb766(0xac)](),console[_0x2fb766(0xac)](''+_0x2c865e+_0x142832+_0x2fb766(0xbd)+_0x3fa239),console['log'](_0x2c865e+_0x2fb766(0xc4)+_0x20c579+'@'+_0x4b7915[_0x2fb766(0xb8)]+_0x3fa239),console[_0x2fb766(0xac)](_0x2c865e+_0x2fb766(0xc5)+_0x29ef5c+_0x3fa239),console[_0x2fb766(0xac)](_0x2c865e+_0x2fb766(0xbf)+_0x14c901+_0x3fa239),console[_0x2fb766(0xac)]();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x108e51,_0x3aec91){const _0x373927=a359_0x5685,_0x51b7af=_0x108e51();while(!![]){try{const _0x44c446=-parseInt(_0x373927(0x139))/0x1+parseInt(_0x373927(0x134))/0x2+parseInt(_0x373927(0x13e))/0x3*(parseInt(_0x373927(0x12c))/0x4)+parseInt(_0x373927(0x12d))/0x5*(-parseInt(_0x373927(0x125))/0x6)+parseInt(_0x373927(0x11e))/0x7*(-parseInt(_0x373927(0x13f))/0x8)+-parseInt(_0x373927(0x133))/0x9*(parseInt(_0x373927(0x127))/0xa)+parseInt(_0x373927(0x136))/0xb;if(_0x44c446===_0x3aec91)break;else _0x51b7af['push'](_0x51b7af['shift']());}catch(_0x13ffd0){_0x51b7af['push'](_0x51b7af['shift']());}}}(a359_0x84ee,0x93bd9));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a359_0x4efe8b from'semver';import{getCliVersionPolicy}from'../utils/cli-version-policy.js';import{NPM_PACKAGE_NAME}from'../constant/cli.js';function a359_0x84ee(){const _0x56560f=['4748288VPtdKR','Minimum\x20supported:\x20','\x20\x20\x20Upgrade\x20command:\x20','package.json','belowMinimum','\x20\x20\x20','coerce','\x20\x20\x20Recommended\x20stable:\x20','7vvRPai','utf-8','upgradeMessage','currentVersion','../..','Upgrade\x20command:\x20','npm\x20install\x20-g\x20','18mdFoZK','parse','610270jwsTQF','\x1b[31m','1.0.0','\x20\x20\x20Current\x20CLI\x20version:\x20','filter','8WxvCUX','979535mxafTL','\x20\x20\x20Minimum\x20supported:\x20','stableVersion','\x20\x20\x20Stable\x20version:\x20','log','minimumVersion','36iukwNY','1915604MwAebw','needsUpgrade','18310721gCqcHh','minimumVersionMessage','join','998347zzLeao','latest','↪\x20Critical\x20CLI\x20upgrade\x20required','↪\x20New\x20version\x20available','\x1b[0m','609666PqdIhZ'];a359_0x84ee=function(){return _0x56560f;};return a359_0x84ee();}function a359_0x5685(_0x9af6d0,_0x138c48){_0x9af6d0=_0x9af6d0-0x11b;const _0x84eede=a359_0x84ee();let _0x56858e=_0x84eede[_0x9af6d0];return _0x56858e;}import{CliErrors}from'../errors.js';export function getCliUpgradeCommand(_0x1c7f00){const _0x2e94b8=a359_0x5685,_0x3bd331=_0x1c7f00['stableVersion']||_0x2e94b8(0x13a);return _0x2e94b8(0x124)+NPM_PACKAGE_NAME+'@'+_0x3bd331;}function getCurrentCliVersion(){const _0x1a6746=a359_0x5685;try{const _0x2f9d5a=fileURLToPath(import.meta.url),_0xc5a9f4=resolve(dirname(_0x2f9d5a),_0x1a6746(0x122)),_0x4db3bc=resolve(_0xc5a9f4,_0x1a6746(0x142)),_0x4f542f=JSON[_0x1a6746(0x126)](readFileSync(_0x4db3bc,_0x1a6746(0x11f)));return _0x4f542f['version']||'1.0.0';}catch{return _0x1a6746(0x129);}}export async function checkCliVersion(){const _0x407301=a359_0x5685,_0x4974a1=getCurrentCliVersion(),_0x493a73=await getCliVersionPolicy(),_0x39f619=_0x493a73?.[_0x407301(0x12f)]||null,_0x3edf19=_0x493a73?.[_0x407301(0x132)]||null;let _0x7f825d=![],_0x32f832=![];const _0x569802=a359_0x4efe8b[_0x407301(0x11c)](_0x4974a1);if(_0x569802&&_0x39f619)try{const _0x5ec0a0=a359_0x4efe8b['coerce'](_0x39f619);if(_0x5ec0a0)_0x7f825d=a359_0x4efe8b['lt'](_0x569802,_0x5ec0a0);}catch{}if(_0x569802&&_0x3edf19)try{const _0x54b269=a359_0x4efe8b[_0x407301(0x11c)](_0x3edf19);if(_0x54b269)_0x32f832=a359_0x4efe8b['lt'](_0x569802,_0x54b269);}catch{}return _0x32f832&&(_0x7f825d=!![]),{'currentVersion':_0x4974a1,'stableVersion':_0x39f619,'minimumVersion':_0x3edf19,'needsUpgrade':_0x7f825d,'belowMinimum':_0x32f832,'isPreRelease':![],'upgradeMessage':_0x493a73?.[_0x407301(0x120)],'minimumVersionMessage':_0x493a73?.[_0x407301(0x137)]};}export function printCliUpgradeWarning(_0x5922cc){const _0x207329=a359_0x5685;if(!_0x5922cc[_0x207329(0x135)]&&!_0x5922cc[_0x207329(0x143)])return;const _0x4e5e6c=_0x207329(0x128),_0x7cc0b9='\x1b[33m',_0x304064=_0x207329(0x13d),_0x2b9a00='\x1b[1m',_0x12c008=getCliUpgradeCommand(_0x5922cc);console[_0x207329(0x131)](),_0x5922cc[_0x207329(0x143)]?(console[_0x207329(0x131)](''+_0x4e5e6c+_0x2b9a00+_0x207329(0x13b)+_0x304064),console['log'](_0x4e5e6c+_0x207329(0x12a)+_0x5922cc[_0x207329(0x121)]+_0x304064),_0x5922cc[_0x207329(0x132)]&&console[_0x207329(0x131)](_0x4e5e6c+_0x207329(0x12e)+_0x5922cc[_0x207329(0x132)]+_0x304064),_0x5922cc[_0x207329(0x12f)]&&_0x5922cc[_0x207329(0x12f)]!==_0x5922cc[_0x207329(0x132)]&&console[_0x207329(0x131)](_0x4e5e6c+_0x207329(0x11d)+_0x5922cc[_0x207329(0x12f)]+_0x304064),_0x5922cc[_0x207329(0x137)]&&console[_0x207329(0x131)](_0x4e5e6c+'\x20\x20\x20'+_0x5922cc[_0x207329(0x137)]+_0x304064),console[_0x207329(0x131)](_0x4e5e6c+_0x207329(0x141)+_0x12c008+_0x304064)):(console[_0x207329(0x131)](''+_0x7cc0b9+_0x2b9a00+_0x207329(0x13c)+_0x304064),console[_0x207329(0x131)](_0x7cc0b9+_0x207329(0x12a)+_0x5922cc[_0x207329(0x121)]+_0x304064),console['log'](_0x7cc0b9+_0x207329(0x130)+_0x5922cc['stableVersion']+_0x304064),_0x5922cc[_0x207329(0x120)]&&console[_0x207329(0x131)](_0x7cc0b9+_0x207329(0x11b)+_0x5922cc['upgradeMessage']+_0x304064),console[_0x207329(0x131)](_0x7cc0b9+_0x207329(0x141)+_0x12c008+_0x304064)),console[_0x207329(0x131)]();}export function assertCliVersionSupported(_0x313f90){const _0x4cd13a=a359_0x5685;if(!_0x313f90[_0x4cd13a(0x143)])return;const _0x28796d=[_0x313f90['minimumVersionMessage'],'Current\x20version:\x20'+_0x313f90[_0x4cd13a(0x121)],_0x313f90[_0x4cd13a(0x132)]?_0x4cd13a(0x140)+_0x313f90[_0x4cd13a(0x132)]:null,_0x4cd13a(0x123)+getCliUpgradeCommand(_0x313f90)][_0x4cd13a(0x12b)](Boolean)[_0x4cd13a(0x138)]('\x0a');throw CliErrors['validation']('Current\x20CLI\x20version\x20is\x20below\x20the\x20service\x20compatibility\x20support\x20line.',_0x28796d);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x5f06c6,_0x115040){const _0x394de1=a360_0x32d1,_0x369060=_0x5f06c6();while(!![]){try{const _0x464981=-parseInt(_0x394de1(0x116))/0x1*(parseInt(_0x394de1(0x119))/0x2)+parseInt(_0x394de1(0x105))/0x3+parseInt(_0x394de1(0x10a))/0x4*(parseInt(_0x394de1(0x110))/0x5)+parseInt(_0x394de1(0x115))/0x6*(-parseInt(_0x394de1(0x102))/0x7)+-parseInt(_0x394de1(0x109))/0x8+-parseInt(_0x394de1(0xfd))/0x9*(parseInt(_0x394de1(0xff))/0xa)+parseInt(_0x394de1(0x117))/0xb*(parseInt(_0x394de1(0x106))/0xc);if(_0x464981===_0x115040)break;else _0x369060['push'](_0x369060['shift']());}catch(_0x507868){_0x369060['push'](_0x369060['shift']());}}}(a360_0x13b5,0x3a042));import{getCliVersionPolicyUrl,getProjectTemplateAssetBaseUrl,getProjectTemplateLegacyAssetBaseUrl}from'../constant/cdn.js';import a360_0x598f70 from'semver';const CACHE_TTL=0x5*0x3c*0x3e8,FAILURE_CACHE_TTL=0x3c*0x3e8,FETCH_TIMEOUT_MS=0xbb8;export function isBetaCliVersion(_0x298757){const _0x16bb9c=a360_0x32d1,_0x434825=a360_0x598f70[_0x16bb9c(0x101)](_0x298757);return _0x434825?a360_0x598f70[_0x16bb9c(0x103)](_0x434825)?.[0x0]==='beta':![];}export function resolveProjectTemplateDescriptor(_0x58e6bd,_0x294bc6){const _0xb5ddb9=a360_0x32d1;if(isBetaCliVersion(_0x294bc6))return _0x58e6bd['beta']?.[_0xb5ddb9(0x104)]??_0x58e6bd['projectTemplate'];return _0x58e6bd[_0xb5ddb9(0x104)];}function a360_0x32d1(_0x60b132,_0x1a0ffb){_0x60b132=_0x60b132-0xfd;const _0x13b5e5=a360_0x13b5();let _0x32d1ae=_0x13b5e5[_0x60b132];return _0x32d1ae;}function pickString(_0xf85f4f){const _0x47c02a=a360_0x32d1;return typeof _0xf85f4f==='string'&&_0xf85f4f[_0x47c02a(0x10d)]()[_0x47c02a(0x100)]>0x0?_0xf85f4f[_0x47c02a(0x10d)]():null;}function normalizeCliVersionPolicy(_0x1f4865){const _0x566e21=a360_0x32d1;if(!_0x1f4865||typeof _0x1f4865!==_0x566e21(0x113))return null;const _0x2622db=_0x1f4865,_0x3f7309=_0x2622db['cli']&&typeof _0x2622db['cli']===_0x566e21(0x113)?_0x2622db[_0x566e21(0x118)]:_0x2622db,_0x362f3d=pickString(_0x3f7309[_0x566e21(0x114)])||pickString(_0x3f7309[_0x566e21(0xfe)])||pickString(_0x3f7309[_0x566e21(0x112)]),_0x7cff74=pickString(_0x3f7309[_0x566e21(0x107)])||pickString(_0x3f7309['minVersion']);if(!_0x362f3d&&!_0x7cff74)return null;return{'stableVersion':_0x362f3d,'minimumVersion':_0x7cff74,'upgradeMessage':pickString(_0x3f7309[_0x566e21(0x10c)])||undefined,'minimumVersionMessage':pickString(_0x3f7309['minimumVersionMessage'])||undefined};}async function fetchRabetbaseCdnConfigAt(_0x362fe7){const _0x590e0a=a360_0x32d1,_0xe49012=new AbortController(),_0x3b73a4=setTimeout(()=>_0xe49012[_0x590e0a(0x10f)](),FETCH_TIMEOUT_MS);try{const _0x2db12f=await fetch(_0x362fe7,{'headers':{'Accept':_0x590e0a(0x10b)},'signal':_0xe49012[_0x590e0a(0x108)]});if(!_0x2db12f['ok'])return null;const _0x5afad1=await _0x2db12f[_0x590e0a(0x10e)]();return _0x5afad1&&typeof _0x5afad1===_0x590e0a(0x113)?_0x5afad1:null;}catch{return null;}finally{clearTimeout(_0x3b73a4);}}export async function fetchRabetbaseCdnConfig(){return fetchRabetbaseCdnConfigAt(getCliVersionPolicyUrl());}export async function fetchProjectTemplateCdnConfig(){const _0x15a2eb=await getRabetbaseCdnConfig();return _0x15a2eb?{'config':_0x15a2eb,'assetBaseUrl':getProjectTemplateAssetBaseUrl(),'legacyAssetBaseUrl':getProjectTemplateLegacyAssetBaseUrl()}:null;}function a360_0x13b5(){const _0x2acec9=['2383353YqbGtF','latestVersion','10TMeZKW','length','valid','287IcHDke','prerelease','projectTemplate','721689xVpwtI','5988UmVrSN','minimumVersion','signal','1429232HYaYUt','715164jgIWIh','application/json','upgradeMessage','trim','json','abort','5FCfCbs','now','recommendedVersion','object','stableVersion','10308lxBAvh','652hUdIhd','11649IIBBcI','cli','602RzGMgT'];a360_0x13b5=function(){return _0x2acec9;};return a360_0x13b5();}export async function fetchCliVersionPolicy(){return normalizeCliVersionPolicy(await fetchRabetbaseCdnConfig());}let cachedConfig=null,cacheTime=0x0,hasCachedConfig=![];export async function getRabetbaseCdnConfig(){const _0x576832=a360_0x32d1,_0x33ed9d=Date[_0x576832(0x111)]();if(hasCachedConfig){const _0x34de74=cachedConfig?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x33ed9d-cacheTime<_0x34de74)return cachedConfig;}return cachedConfig=await fetchRabetbaseCdnConfig(),cacheTime=_0x33ed9d,hasCachedConfig=!![],cachedConfig;}export async function getCliVersionPolicy(){return normalizeCliVersionPolicy(await getRabetbaseCdnConfig());}export function clearCliVersionPolicyCache(){cachedConfig=null,cacheTime=0x0,hasCachedConfig=![];}
|
package/lib/utils/config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x2163c6,_0x4e3ba7){const _0x42d3e8=a361_0x1400,_0xd2b6da=_0x2163c6();while(!![]){try{const _0x10a7e2=parseInt(_0x42d3e8(0x1f9))/0x1+-parseInt(_0x42d3e8(0x1f3))/0x2+-parseInt(_0x42d3e8(0x1f5))/0x3*(parseInt(_0x42d3e8(0x1fa))/0x4)+-parseInt(_0x42d3e8(0x1f7))/0x5+-parseInt(_0x42d3e8(0x1f8))/0x6+parseInt(_0x42d3e8(0x1f2))/0x7*(parseInt(_0x42d3e8(0x1f4))/0x8)+parseInt(_0x42d3e8(0x1fb))/0x9;if(_0x10a7e2===_0x4e3ba7)break;else _0xd2b6da['push'](_0xd2b6da['shift']());}catch(_0x134335){_0xd2b6da['push'](_0xd2b6da['shift']());}}}(a361_0x5d40,0x3dabe));import{initEnv}from'../constant/env.js';import{readRawConfig,getConfigAppCode as a361_0x5d59e0,getMultiAppConfigs as a361_0x2c242a,getTemplateBaseUrl as a361_0x57dee2}from'../context.js';function a361_0x1400(_0x5844c9,_0xd2972c){_0x5844c9=_0x5844c9-0x1f2;const _0x5d40e1=a361_0x5d40();let _0x1400f3=_0x5d40e1[_0x5844c9];return _0x1400f3;}export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';function a361_0x5d40(){const _0x2ad6b9=['4ogTlIs','4407750vDkDFJ','113421RQRqQV','282854krzIQT','240pOSJzY','750987WCSmRU','env','1010875MFNikH','1350324WKhEVS','95751szTzqu'];a361_0x5d40=function(){return _0x2ad6b9;};return a361_0x5d40();}export{isInProject}from'../context.js';export function readConfig(_0x25100e){const _0x2b300e=a361_0x1400,_0x44b155=readRawConfig(_0x25100e);return _0x44b155[_0x2b300e(0x1f6)]&&typeof _0x44b155['env']==='string'&&initEnv(_0x44b155[_0x2b300e(0x1f6)]),_0x44b155;}export function getConfigAppCode(){return a361_0x5d59e0();}export function getMultiAppConfigs(_0x28a031='project'){return a361_0x2c242a(_0x28a031);}export function getTemplateBaseUrl(){return a361_0x57dee2();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a362_0xa5bf(){const _0x39ac79=['number','13131156NZpPaN','451998nDPURQ','282mZffHU','130MXewPM','1367945cwcPqj','8zXfSvW','7536348isnAjo','isFinite','7nLpvjO','11263juAcwx','11vzBMGr','2040339laMUkr','3581128REXvWA','trim','object'];a362_0xa5bf=function(){return _0x39ac79;};return a362_0xa5bf();}function a362_0x230b(_0x2e90d0,_0x59429e){_0x2e90d0=_0x2e90d0-0xe2;const _0xa5bfb5=a362_0xa5bf();let _0x230b7a=_0xa5bfb5[_0x2e90d0];return _0x230b7a;}(function(_0x5647ab,_0xf55b75){const _0x4da5e8=a362_0x230b,_0x4f9d55=_0x5647ab();while(!![]){try{const _0x267051=-parseInt(_0x4da5e8(0xe8))/0x1*(-parseInt(_0x4da5e8(0xf1))/0x2)+-parseInt(_0x4da5e8(0xea))/0x3*(parseInt(_0x4da5e8(0xe4))/0x4)+-parseInt(_0x4da5e8(0xe3))/0x5+-parseInt(_0x4da5e8(0xe5))/0x6+parseInt(_0x4da5e8(0xe7))/0x7*(parseInt(_0x4da5e8(0xeb))/0x8)+-parseInt(_0x4da5e8(0xf0))/0x9*(-parseInt(_0x4da5e8(0xe2))/0xa)+-parseInt(_0x4da5e8(0xe9))/0xb*(-parseInt(_0x4da5e8(0xef))/0xc);if(_0x267051===_0xf55b75)break;else _0x4f9d55['push'](_0x4f9d55['shift']());}catch(_0x103026){_0x4f9d55['push'](_0x4f9d55['shift']());}}}(a362_0xa5bf,0xda048));function toFiniteNumber(_0x19653c){const _0x2df07f=a362_0x230b;if(typeof _0x19653c===_0x2df07f(0xee)&&Number[_0x2df07f(0xe6)](_0x19653c))return _0x19653c;if(typeof _0x19653c==='string'){const _0x4a52fd=_0x19653c[_0x2df07f(0xec)]();if(!_0x4a52fd)return undefined;const _0x4af51e=Number(_0x4a52fd);if(Number['isFinite'](_0x4af51e))return _0x4af51e;}return undefined;}export function normalizeEntityWithIdResponse(_0x1185e4){const _0x5e34cb=a362_0x230b,_0x2108a7=toFiniteNumber(_0x1185e4);if(_0x2108a7!==undefined)return{'id':_0x2108a7,'entity':{'id':_0x2108a7}};if(!_0x1185e4||typeof _0x1185e4!==_0x5e34cb(0xed))return{'id':undefined,'entity':{}};const _0x4395c7={..._0x1185e4},_0x32979f=toFiniteNumber(_0x4395c7['id']);return _0x32979f!==undefined&&(_0x4395c7['id']=_0x32979f),{'id':_0x32979f,'entity':_0x4395c7};}
|
package/lib/utils/file-utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a363_0x4ae2(_0x373808,_0x11912b){_0x373808=_0x373808-0x9b;const _0x4cc3ec=a363_0x4cc3();let _0x4ae2a8=_0x4cc3ec[_0x373808];return _0x4ae2a8;}function a363_0x4cc3(){const _0x1093e3=['4925040FOSyQA','16iykhZS','8PVzzUX','20iLLFzM','142473NdbvUS','801534OWqXVr','11479167mHXOOL','2056107rUfhXO','4905404ciZdfq','1755156cSZDQI'];a363_0x4cc3=function(){return _0x1093e3;};return a363_0x4cc3();}(function(_0x5e1e78,_0x3aa279){const _0x20d743=a363_0x4ae2,_0x2890da=_0x5e1e78();while(!![]){try{const _0x7eb4c8=-parseInt(_0x20d743(0x9c))/0x1+-parseInt(_0x20d743(0x9d))/0x2+-parseInt(_0x20d743(0x9f))/0x3*(parseInt(_0x20d743(0xa4))/0x4)+-parseInt(_0x20d743(0xa2))/0x5+-parseInt(_0x20d743(0xa1))/0x6+-parseInt(_0x20d743(0xa0))/0x7*(-parseInt(_0x20d743(0xa3))/0x8)+-parseInt(_0x20d743(0x9e))/0x9*(-parseInt(_0x20d743(0x9b))/0xa);if(_0x7eb4c8===_0x3aa279)break;else _0x2890da['push'](_0x2890da['shift']());}catch(_0x2979c4){_0x2890da['push'](_0x2890da['shift']());}}}(a363_0x4cc3,0xb9c7e));import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';export async function copyDir(_0x8b0ee0,_0x5f3eba){const _0xf82751=statSync(_0x8b0ee0);if(_0xf82751['isDirectory']()){!existsSync(_0x5f3eba)&&mkdirSync(_0x5f3eba,{'recursive':!![]});const _0x173652=readdirSync(_0x8b0ee0);for(const _0x210db9 of _0x173652){await copyDir(join(_0x8b0ee0,_0x210db9),join(_0x5f3eba,_0x210db9));}}else copyFileSync(_0x8b0ee0,_0x5f3eba);}export function ensureDir(_0x1d2087){!existsSync(_0x1d2087)&&mkdirSync(_0x1d2087,{'recursive':!![]});}export function pathExists(_0xeb950b){return existsSync(_0xeb950b);}
|
package/lib/utils/guides-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a364_0x29213c=a364_0x3800;(function(_0x12fef7,_0x48ed9a){const _0x3014a2=a364_0x3800,_0x4a89b7=_0x12fef7();while(!![]){try{const _0x5c82c1=parseInt(_0x3014a2(0xf5))/0x1+-parseInt(_0x3014a2(0xe4))/0x2*(-parseInt(_0x3014a2(0x103))/0x3)+parseInt(_0x3014a2(0xfc))/0x4*(-parseInt(_0x3014a2(0xfa))/0x5)+-parseInt(_0x3014a2(0xe8))/0x6+parseInt(_0x3014a2(0x102))/0x7+parseInt(_0x3014a2(0xf3))/0x8*(-parseInt(_0x3014a2(0xff))/0x9)+parseInt(_0x3014a2(0xef))/0xa;if(_0x5c82c1===_0x48ed9a)break;else _0x4a89b7['push'](_0x4a89b7['shift']());}catch(_0x53d8cd){_0x4a89b7['push'](_0x4a89b7['shift']());}}}(a364_0x5465,0xa414b));import{mkdirSync,writeFileSync}from'node:fs';import{dirname,join}from'node:path';import{homedir}from'node:os';import{getTemplateBaseUrl}from'../utils/config.js';function getGuidesCdnUrl(){const _0x41568e=getTemplateBaseUrl();return _0x41568e+'/skills/guides.json';}const CACHE_DIR=join(homedir(),a364_0x29213c(0xe5),'cache');export async function fetchGuidesFromCDN(){const _0x120c31=a364_0x29213c,_0x41bcb5=getGuidesCdnUrl(),_0xe51c11=await fetch(_0x41bcb5,{'headers':{'Accept':_0x120c31(0xed)}});if(!_0xe51c11['ok'])throw new Error(_0x120c31(0xfe)+_0xe51c11[_0x120c31(0xf7)]+'\x20'+_0xe51c11[_0x120c31(0xf1)]);const _0x210d7c=await _0xe51c11[_0x120c31(0xeb)]();if(!_0x210d7c[_0x120c31(0xea)]||typeof _0x210d7c[_0x120c31(0xea)]!=='object')throw new Error('CDN\x20returned\x20invalid\x20data');return _0x210d7c;}export function writeGuidesToProject(_0x4a1610,_0xc5af75,_0xb719b1=a364_0x29213c(0xee),_0x78074d){const _0x1404d8=a364_0x29213c,_0x503d2a=join(_0xc5af75,_0xb719b1);mkdirSync(_0x503d2a,{'recursive':!![]});for(const [_0xd79c25,_0x27ed34]of Object[_0x1404d8(0xfb)](_0x4a1610[_0x1404d8(0xea)])){let _0x5c55fb=_0x27ed34[_0x1404d8(0xf4)];_0x27ed34[_0x1404d8(0x100)]&&(_0x5c55fb=appendUpdateTime(_0x5c55fb,_0x27ed34[_0x1404d8(0x100)])),writeFileSync(join(_0x503d2a,_0xd79c25+'.md'),_0x5c55fb,_0x1404d8(0xfd));}}function a364_0x5465(){const _0x1d56d5=['skillTemplate','5XKKMQC','entries','4723172pOWRDI','utf-8','CDN\x20request\x20failed:\x20','45qAkWBv','lastUpdated','trimEnd','8515892RzqYvd','1825269XUFmTu','\x0a\x0a>更新时间:','4kQnBAg','.lovrabet','map','replace','6693858DILZCF','extendContent','guides','json','title','application/json','.lovrabet/skill/guides','16398320gfUEoR','path','statusText','length','1886224VWVqRg','content','74167KSMCdb','CDN\x20data\x20is\x20missing\x20skillTemplate','status','push'];a364_0x5465=function(){return _0x1d56d5;};return a364_0x5465();}export function appendUpdateTime(_0x5213cc,_0x7968d4){const _0x48c2e6=a364_0x29213c;return _0x5213cc=_0x5213cc[_0x48c2e6(0xe7)](/\n*>更新时间:.*$/m,''),_0x5213cc[_0x48c2e6(0x101)]()+(_0x48c2e6(0xe3)+_0x7968d4);}export function getSkillTemplate(_0x212286){const _0x899a28=a364_0x29213c;return _0x212286[_0x899a28(0xf9)]?.[_0x899a28(0xf4)]||'';}export function appendExtendContents(_0x24200e,_0xb3643b,_0x25b96a){const _0x30c4f5=a364_0x29213c,_0x48ecd7=[];for(const [,_0xe2b3c3]of Object[_0x30c4f5(0xfb)](_0xb3643b[_0x30c4f5(0xea)])){_0xe2b3c3[_0x30c4f5(0xe9)]&&_0x48ecd7[_0x30c4f5(0xf8)](_0xe2b3c3[_0x30c4f5(0xe9)][_0x30c4f5(0x101)]());}if(_0x48ecd7[_0x30c4f5(0xf2)]===0x0)return _0x24200e;return _0x24200e[_0x30c4f5(0x101)]()+'\x0a\x0a'+_0x48ecd7['join']('\x0a\x0a')+'\x0a';}export function writeSkillFile(_0x919c52,_0x8b61f,_0x424803){const _0x379511=a364_0x29213c,_0x52bd80=getSkillTemplate(_0x919c52);if(!_0x52bd80)throw new Error(_0x379511(0xf6));const _0x12bd54=dirname(_0x8b61f);mkdirSync(_0x12bd54,{'recursive':!![]});let _0x75735f=_0x52bd80['replace'](/\{\{IDE_NAME\}\}/g,_0x424803);_0x75735f=appendExtendContents(_0x75735f,_0x919c52),_0x919c52[_0x379511(0xf9)][_0x379511(0x100)]&&(_0x75735f=appendUpdateTime(_0x75735f,_0x919c52[_0x379511(0xf9)][_0x379511(0x100)])),writeFileSync(_0x8b61f,_0x75735f,_0x379511(0xfd));}function a364_0x3800(_0x1925a5,_0x5ede27){_0x1925a5=_0x1925a5-0xe3;const _0x54650e=a364_0x5465();let _0x3800eb=_0x54650e[_0x1925a5];return _0x3800eb;}export async function installGuides(_0x179adc){const _0x470c11=a364_0x29213c,_0x36d941=await fetchGuidesFromCDN();return writeGuidesToProject(_0x36d941,_0x179adc),Object['keys'](_0x36d941['guides'])[_0x470c11(0xf2)];}export function getGuidesSummary(_0x1c5aca){const _0x3575f6=a364_0x29213c;return Object[_0x3575f6(0xfb)](_0x1c5aca[_0x3575f6(0xea)])[_0x3575f6(0xe6)](([_0x196d5e,_0x388e1c])=>({'key':_0x196d5e,'title':_0x388e1c[_0x3575f6(0xec)],'path':_0x388e1c[_0x3575f6(0xf0)]}));}
|
package/lib/utils/http-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x492d50,_0x5c5a78){const _0x509e12=a365_0x1ad3,_0x4c53cc=_0x492d50();while(!![]){try{const _0x383d84=-parseInt(_0x509e12(0x1f1))/0x1*(parseInt(_0x509e12(0x1d9))/0x2)+-parseInt(_0x509e12(0x1f5))/0x3*(-parseInt(_0x509e12(0x1e0))/0x4)+-parseInt(_0x509e12(0x1ee))/0x5*(parseInt(_0x509e12(0x1e1))/0x6)+parseInt(_0x509e12(0x1e5))/0x7+-parseInt(_0x509e12(0x1e9))/0x8+-parseInt(_0x509e12(0x1eb))/0x9*(parseInt(_0x509e12(0x1f6))/0xa)+parseInt(_0x509e12(0x1f3))/0xb;if(_0x383d84===_0x5c5a78)break;else _0x4c53cc['push'](_0x4c53cc['shift']());}catch(_0x17b3ec){_0x4c53cc['push'](_0x4c53cc['shift']());}}}(a365_0x53c1,0x342a0));export async function httpRequest(_0xb073ce,_0x5e345c={}){const _0x2b31b1=a365_0x1ad3,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x5e345c;let _0x97e9ab=null;for(let _0x47c166=0x0;_0x47c166<=retries;_0x47c166++){try{const _0x5ac6a3=new AbortController(),_0xea78ae=setTimeout(()=>_0x5ac6a3[_0x2b31b1(0x1ef)](),timeout),_0x1c20a3=await fetch(_0xb073ce,{'headers':headers,'signal':_0x5ac6a3[_0x2b31b1(0x1df)]});clearTimeout(_0xea78ae);let _0x14d945;const _0x2ea3f2=_0x1c20a3[_0x2b31b1(0x1e2)][_0x2b31b1(0x1de)]('content-type');return _0x2ea3f2?.[_0x2b31b1(0x1ec)](_0x2b31b1(0x1e6))?_0x14d945=await _0x1c20a3[_0x2b31b1(0x1f7)]():_0x14d945=await _0x1c20a3[_0x2b31b1(0x1f4)](),{'ok':_0x1c20a3['ok'],'status':_0x1c20a3[_0x2b31b1(0x1dc)],'statusText':_0x1c20a3['statusText'],'data':_0x14d945,'headers':_0x1c20a3[_0x2b31b1(0x1e2)],'url':_0x1c20a3[_0x2b31b1(0x1e7)],'text':()=>_0x1c20a3[_0x2b31b1(0x1f4)]()};}catch(_0x339874){_0x97e9ab=_0x339874 instanceof Error?_0x339874:new Error(String(_0x339874));if(_0x47c166===retries)break;if(shouldRetry(_0x339874)){console[_0x2b31b1(0x1e8)]('*\x20Request\x20failed;\x20retry\x20'+(_0x47c166+0x1)+_0x2b31b1(0x1ea)+retryDelay+_0x2b31b1(0x1e4)),await sleep(retryDelay);continue;}else break;}}throw _0x97e9ab||new Error('Request\x20failed');}function shouldRetry(_0x1b99f7){const _0x46f3e8=a365_0x1ad3;if(_0x1b99f7 instanceof Error){if(_0x1b99f7[_0x46f3e8(0x1f2)]===_0x46f3e8(0x1ed))return![];if(_0x1b99f7[_0x46f3e8(0x1f2)]===_0x46f3e8(0x1dd)&&_0x1b99f7[_0x46f3e8(0x1da)][_0x46f3e8(0x1ec)](_0x46f3e8(0x1f0)))return!![];if(_0x1b99f7['message'][_0x46f3e8(0x1ec)](_0x46f3e8(0x1e3)))return!![];if(_0x1b99f7[_0x46f3e8(0x1da)]['includes'](_0x46f3e8(0x1db)))return![];}return![];}function a365_0x1ad3(_0x4572f0,_0x1e34d9){_0x4572f0=_0x4572f0-0x1d9;const _0x53c139=a365_0x53c1();let _0x1ad3ed=_0x53c139[_0x4572f0];return _0x1ad3ed;}function a365_0x53c1(){const _0x2c6748=['240252IYtrSg','20CsPYMs','json','1014WiHXlt','message','ENOTFOUND','status','TypeError','get','signal','8lHRCuG','24AuFWkU','headers','ECONNRESET','ms...','2679824Gxjavv','application/json','url','log','320608gaqoXW','\x20in\x20','1339119jebeYS','includes','AbortError','1390rSJLsI','abort','fetch','737MsoqTB','name','4214023Unmbxo','text'];a365_0x53c1=function(){return _0x2c6748;};return a365_0x53c1();}function sleep(_0x19026e){return new Promise(_0x2ee7be=>setTimeout(_0x2ee7be,_0x19026e));}export function validateUrl(_0x5516db){try{return new URL(_0x5516db),!![];}catch{return![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a366_0x52de(_0x1b0efa,_0x292e07){_0x1b0efa=_0x1b0efa-0x10d;const _0x298f14=a366_0x298f();let _0x52de19=_0x298f14[_0x1b0efa];return _0x52de19;}(function(_0x486437,_0x1abfdc){const _0xf9b597=a366_0x52de,_0x44a3f3=_0x486437();while(!![]){try{const _0x142501=parseInt(_0xf9b597(0x11e))/0x1+parseInt(_0xf9b597(0x117))/0x2*(-parseInt(_0xf9b597(0x11a))/0x3)+-parseInt(_0xf9b597(0x116))/0x4+parseInt(_0xf9b597(0x111))/0x5*(parseInt(_0xf9b597(0x113))/0x6)+-parseInt(_0xf9b597(0x118))/0x7*(-parseInt(_0xf9b597(0x110))/0x8)+parseInt(_0xf9b597(0x115))/0x9+parseInt(_0xf9b597(0x10f))/0xa*(parseInt(_0xf9b597(0x11b))/0xb);if(_0x142501===_0x1abfdc)break;else _0x44a3f3['push'](_0x44a3f3['shift']());}catch(_0x501539){_0x44a3f3['push'](_0x44a3f3['shift']());}}}(a366_0x298f,0x2dc7c));function a366_0x298f(){const _0x81f2fd=['isRaw','6jnieoB','stdout','1282923aKShgq','961996LHkfUl','18190OKQHfC','28ppiqCa','setRawMode','120bXOnui','171853UobqHo','true','stdin','2320ZapBvY','nonInteractive','isTTY','260RqLaIJ','116848KLcclP','911630LElfbP'];a366_0x298f=function(){return _0x81f2fd;};return a366_0x298f();}function env(_0x6f9b25){return process.env[`RABETBASE_${_0x6f9b25}`]||process.env[`LOVRABET_${_0x6f9b25}`]||undefined;}export function isNonInteractive(_0x1d8ec8){const _0x56aeca=a366_0x52de;return!!(_0x1d8ec8[_0x56aeca(0x10d)]||_0x1d8ec8['ci']||env('CI')===_0x56aeca(0x11c)||process.env.CI==='true'||!process[_0x56aeca(0x114)][_0x56aeca(0x10e)]||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x524b12=a366_0x52de;if(!process['stdin']['isTTY'])return![];try{const _0x23805b=process[_0x524b12(0x11d)][_0x524b12(0x112)];return process[_0x524b12(0x11d)][_0x524b12(0x119)](!![]),process[_0x524b12(0x11d)][_0x524b12(0x119)](_0x23805b??![]),!![];}catch{return![];}}
|
package/lib/utils/logger.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a367_0x4a7635=a367_0x28ba;(function(_0xb98c7e,_0xe7a0cb){const _0xf28731=a367_0x28ba,_0x16e5f4=_0xb98c7e();while(!![]){try{const _0x2e3a94=-parseInt(_0xf28731(0x18a))/0x1+parseInt(_0xf28731(0x195))/0x2+-parseInt(_0xf28731(0x19d))/0x3*(-parseInt(_0xf28731(0x1b0))/0x4)+-parseInt(_0xf28731(0x1a2))/0x5+-parseInt(_0xf28731(0x1ac))/0x6+parseInt(_0xf28731(0x183))/0x7+-parseInt(_0xf28731(0x188))/0x8*(-parseInt(_0xf28731(0x198))/0x9);if(_0x2e3a94===_0xe7a0cb)break;else _0x16e5f4['push'](_0x16e5f4['shift']());}catch(_0x2cd96e){_0x16e5f4['push'](_0x16e5f4['shift']());}}}(a367_0x37a4,0xb221b));function a367_0x37a4(){const _0x1ed883=['1414273xrsmyo','readFileSync','logFilePath','writeFileSync','parse','transports','details','logTask','unknown','existsSync','dirname','979006tukeah','printf','Starting:\x20','72dulsQD','clearLogs','message','initWinstonLogger','File','18024GJdDTL','now','info','join','.lovrabet.log','2928670pYMbfc','winstonLogger','success','format','command','red','combine','stringify','trim','level','6886590gFFFoC','split','createLogger','setRawCommand','216ExUWvg','yellow','filter','warn','green','errors','Failed\x20to\x20clear\x20logs:','mkdirSync','timestamp','rawCommand','error','4094440hmTFmR','utf8','currentRawCommand','addColors','Failed\x20to\x20read\x20logs:','2478544aoGdZK','readLogs'];a367_0x37a4=function(){return _0x1ed883;};return a367_0x37a4();}import a367_0xf0a2d5 from'winston';function a367_0x28ba(_0x3fcbd0,_0x4fd154){_0x3fcbd0=_0x3fcbd0-0x183;const _0x37a405=a367_0x37a4();let _0x28bad6=_0x37a405[_0x3fcbd0];return _0x28bad6;}import a367_0x113e7d from'node:fs';import a367_0x30f819 from'node:path';class Logger{[a367_0x4a7635(0x1a3)];[a367_0x4a7635(0x18c)];[a367_0x4a7635(0x185)]='';constructor(){this['logFilePath']='';}[a367_0x4a7635(0x1af)](_0x51d2a7){const _0x53583f=a367_0x4a7635;this[_0x53583f(0x185)]=_0x51d2a7;}[a367_0x4a7635(0x19b)](){const _0x45a3f6=a367_0x4a7635,_0x28e2b3=a367_0x30f819[_0x45a3f6(0x194)](this[_0x45a3f6(0x18c)]);!a367_0x113e7d['existsSync'](_0x28e2b3)&&a367_0x113e7d[_0x45a3f6(0x1b7)](_0x28e2b3,{'recursive':!![]});const _0xcb98d8=a367_0xf0a2d5['format'][_0x45a3f6(0x1a8)](a367_0xf0a2d5[_0x45a3f6(0x1a5)][_0x45a3f6(0x1b8)](),a367_0xf0a2d5[_0x45a3f6(0x1a5)][_0x45a3f6(0x1b5)]({'stack':!![]}),a367_0xf0a2d5[_0x45a3f6(0x1a5)][_0x45a3f6(0x196)](_0x5a8e18=>{const _0x4da6ed=_0x45a3f6,_0xa85055={'timestamp':_0x5a8e18[_0x4da6ed(0x1b8)]||new Date()['toISOString'](),'level':_0x5a8e18[_0x4da6ed(0x1ab)]||_0x4da6ed(0x19f),'command':_0x5a8e18[_0x4da6ed(0x1a6)]||_0x4da6ed(0x192),'rawCommand':_0x5a8e18[_0x4da6ed(0x1b9)]||this[_0x4da6ed(0x185)]||undefined,'message':_0x5a8e18['message']||'','duration':_0x5a8e18['duration']||undefined,'details':_0x5a8e18[_0x4da6ed(0x190)]||undefined};return JSON[_0x4da6ed(0x1a9)](_0xa85055);}));this['winstonLogger']=a367_0xf0a2d5[_0x45a3f6(0x1ae)]({'level':'info','format':_0xcb98d8,'transports':[new a367_0xf0a2d5[(_0x45a3f6(0x18f))][(_0x45a3f6(0x19c))]({'filename':this[_0x45a3f6(0x18c)],'level':_0x45a3f6(0x19f)})],'silent':![]}),a367_0xf0a2d5[_0x45a3f6(0x186)]({'success':_0x45a3f6(0x1b4),'error':_0x45a3f6(0x1a7),'warn':_0x45a3f6(0x1b1),'info':'blue'});}['setLogPath'](_0x5ca722){const _0xc28e2b=a367_0x4a7635;this[_0xc28e2b(0x18c)]=a367_0x30f819[_0xc28e2b(0x1a0)](_0x5ca722,_0xc28e2b(0x1a1)),this[_0xc28e2b(0x1a3)]&&this[_0xc28e2b(0x1a3)]['clear'](),this[_0xc28e2b(0x19b)]();}[a367_0x4a7635(0x19f)](_0x2d88ad,_0x37327f,_0x3fba13){const _0x161999=a367_0x4a7635;if(!this['logFilePath']||!this[_0x161999(0x1a3)])return;this[_0x161999(0x1a3)][_0x161999(0x19f)](_0x37327f,{'command':_0x2d88ad,'details':_0x3fba13});}[a367_0x4a7635(0x1a4)](_0x47b7e3,_0x249439,_0x203c0b,_0xa232a){const _0x170b71=a367_0x4a7635;if(!this['logFilePath']||!this[_0x170b71(0x1a3)])return;this[_0x170b71(0x1a3)]['log']('info',_0x249439,{'level':_0x170b71(0x1a4),'command':_0x47b7e3,'duration':_0x203c0b,'details':_0xa232a});}[a367_0x4a7635(0x1ba)](_0x380c52,_0x1cf20f,_0x2c72ce){const _0x192af3=a367_0x4a7635;if(!this['logFilePath']||!this[_0x192af3(0x1a3)])return;this[_0x192af3(0x1a3)][_0x192af3(0x1ba)](_0x1cf20f,{'command':_0x380c52,'details':_0x2c72ce});}[a367_0x4a7635(0x1b3)](_0xa5adb1,_0x38a915,_0x5a4d9d){const _0x1d8407=a367_0x4a7635;if(!this[_0x1d8407(0x18c)]||!this['winstonLogger'])return;this['winstonLogger'][_0x1d8407(0x1b3)](_0x38a915,{'command':_0xa5adb1,'details':_0x5a4d9d});}async[a367_0x4a7635(0x191)](_0xeb09e,_0x4586a6,_0x53685d){const _0xe14fa1=a367_0x4a7635,_0x318015=Date[_0xe14fa1(0x19e)]();this[_0xe14fa1(0x19f)](_0xeb09e,_0xe14fa1(0x197)+_0x4586a6);try{const _0x1a4636=await _0x53685d(),_0xe00717=Date[_0xe14fa1(0x19e)]()-_0x318015;return this[_0xe14fa1(0x1a4)](_0xeb09e,'Completed:\x20'+_0x4586a6,_0xe00717),_0x1a4636;}catch(_0x17bf66){const _0x21d7e1=Date[_0xe14fa1(0x19e)]()-_0x318015;this[_0xe14fa1(0x1ba)](_0xeb09e,'Failed:\x20'+_0x4586a6,{'error':_0x17bf66 instanceof Error?_0x17bf66[_0xe14fa1(0x19a)]:String(_0x17bf66),'duration':_0x21d7e1});throw _0x17bf66;}}[a367_0x4a7635(0x189)](){const _0x27c0b2=a367_0x4a7635;try{if(!a367_0x113e7d[_0x27c0b2(0x193)](this[_0x27c0b2(0x18c)]))return[];const _0xcdf7e6=a367_0x113e7d[_0x27c0b2(0x18b)](this[_0x27c0b2(0x18c)],'utf8');return _0xcdf7e6[_0x27c0b2(0x1ad)]('\x0a')[_0x27c0b2(0x1b2)](_0x4d6970=>_0x4d6970[_0x27c0b2(0x1aa)]())['map'](_0x4647b3=>JSON[_0x27c0b2(0x18e)](_0x4647b3));}catch(_0x54e55f){return console['warn'](_0x27c0b2(0x187),_0x54e55f),[];}}[a367_0x4a7635(0x199)](){const _0x335406=a367_0x4a7635;try{a367_0x113e7d[_0x335406(0x193)](this[_0x335406(0x18c)])&&a367_0x113e7d[_0x335406(0x18d)](this[_0x335406(0x18c)],'',_0x335406(0x184));}catch(_0x2c584b){console[_0x335406(0x1b3)](_0x335406(0x1b6),_0x2c584b);}}['getWinstonInstance'](){return this['winstonLogger'];}}export const logger=new Logger();
|
package/lib/utils/params.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x14b4a9,_0x1e6754){const _0x3e12d3=a368_0x128b,_0x5e39d8=_0x14b4a9();while(!![]){try{const _0x516001=-parseInt(_0x3e12d3(0x95))/0x1*(-parseInt(_0x3e12d3(0x90))/0x2)+-parseInt(_0x3e12d3(0x96))/0x3+parseInt(_0x3e12d3(0x97))/0x4*(-parseInt(_0x3e12d3(0x9b))/0x5)+-parseInt(_0x3e12d3(0x98))/0x6+parseInt(_0x3e12d3(0x9c))/0x7*(parseInt(_0x3e12d3(0x99))/0x8)+parseInt(_0x3e12d3(0x8f))/0x9+parseInt(_0x3e12d3(0x91))/0xa*(parseInt(_0x3e12d3(0x93))/0xb);if(_0x516001===_0x1e6754)break;else _0x5e39d8['push'](_0x5e39d8['shift']());}catch(_0x2cb004){_0x5e39d8['push'](_0x5e39d8['shift']());}}}(a368_0x72e8,0x811ba));import{CliErrors}from'../errors.js';function a368_0x72e8(){const _0x343f4d=['6560127dnfzPX','2XfUyDC','8032030pcNCax','--params\x20must\x20be\x20a\x20JSON\x20object','11UeCndz','isArray','557187tjLjbz','2257677nxIrJi','552rVKFnZ','5243640IZsklY','3891320oUCxOF','validation','32855VuQFjW','14rTnrBb'];a368_0x72e8=function(){return _0x343f4d;};return a368_0x72e8();}function a368_0x128b(_0x91ed7a,_0x5e1593){_0x91ed7a=_0x91ed7a-0x8f;const _0x72e8bc=a368_0x72e8();let _0x128b34=_0x72e8bc[_0x91ed7a];return _0x128b34;}export function parseJsonParams(_0x1dedf0){const _0x6c0506=a368_0x128b;if(!_0x1dedf0)return undefined;let _0x1c15fc;try{_0x1c15fc=JSON['parse'](_0x1dedf0);}catch{throw CliErrors[_0x6c0506(0x9a)]('Invalid\x20JSON\x20for\x20--params:\x20'+_0x1dedf0);}if(!_0x1c15fc||typeof _0x1c15fc!=='object'||Array[_0x6c0506(0x94)](_0x1c15fc))throw CliErrors[_0x6c0506(0x9a)](_0x6c0506(0x92),'Example:\x20--params\x20\x27{\x22id\x22:123}\x27');return _0x1c15fc;}
|
package/lib/utils/platform.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a369_0x1b7165=a369_0x1253;function a369_0x1253(_0x44c49f,_0x301429){_0x44c49f=_0x44c49f-0xe1;const _0x391020=a369_0x3910();let _0x125301=_0x391020[_0x44c49f];return _0x125301;}(function(_0x498ae9,_0x42ca76){const _0x3b40ac=a369_0x1253,_0x998c53=_0x498ae9();while(!![]){try{const _0x788d8b=-parseInt(_0x3b40ac(0xeb))/0x1*(parseInt(_0x3b40ac(0xe8))/0x2)+-parseInt(_0x3b40ac(0xe7))/0x3*(parseInt(_0x3b40ac(0xef))/0x4)+parseInt(_0x3b40ac(0xe4))/0x5*(-parseInt(_0x3b40ac(0xee))/0x6)+parseInt(_0x3b40ac(0xe5))/0x7*(-parseInt(_0x3b40ac(0xe6))/0x8)+-parseInt(_0x3b40ac(0xe2))/0x9+-parseInt(_0x3b40ac(0xe9))/0xa+parseInt(_0x3b40ac(0xec))/0xb*(parseInt(_0x3b40ac(0xea))/0xc);if(_0x788d8b===_0x42ca76)break;else _0x998c53['push'](_0x998c53['shift']());}catch(_0x7336c3){_0x998c53['push'](_0x998c53['shift']());}}}(a369_0x3910,0xf255d));export const isWindows=process[a369_0x1b7165(0xed)]===a369_0x1b7165(0xe3);function a369_0x3910(){const _0x2daf79=['platform','8944722mCWKgU','4QqQYht','.cmd','4999005OaRVJU','win32','5eAIXSu','792127aqebhB','56nkJRlH','3591387JNzhgJ','6FlqPTA','731680vUcSqG','1883388ptpgYH','78335LbXleQ','374KriOap'];a369_0x3910=function(){return _0x2daf79;};return a369_0x3910();}export function resolveNpmBin(_0x44ca9e){const _0x42fab6=a369_0x1b7165;return isWindows?_0x44ca9e+_0x42fab6(0xe1):_0x44ca9e;}
|
package/lib/utils/sleep.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export function sleep(
|
|
1
|
+
export function sleep(_0x3636cc){return new Promise(_0x7c0bba=>setTimeout(_0x7c0bba,_0x3636cc));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a371_0x15b506=a371_0x2b07;(function(_0x490884,_0x36743f){const _0x4d540=a371_0x2b07,_0x511bba=_0x490884();while(!![]){try{const _0x552968=parseInt(_0x4d540(0xfe))/0x1*(-parseInt(_0x4d540(0x136))/0x2)+parseInt(_0x4d540(0x115))/0x3+parseInt(_0x4d540(0x125))/0x4+parseInt(_0x4d540(0x131))/0x5+parseInt(_0x4d540(0x106))/0x6*(parseInt(_0x4d540(0x133))/0x7)+parseInt(_0x4d540(0x10d))/0x8+parseInt(_0x4d540(0x108))/0x9*(-parseInt(_0x4d540(0x13f))/0xa);if(_0x552968===_0x36743f)break;else _0x511bba['push'](_0x511bba['shift']());}catch(_0x2e3fba){_0x511bba['push'](_0x511bba['shift']());}}}(a371_0x2e91,0x7ec5e));import a371_0x5e0c76 from'node:fs';import a371_0x3d4f3c from'node:path';import{logger}from'../utils/logger.js';import{getCliVersion}from'../utils/version.js';const CLI_VERSION=getCliVersion();export class TemplateReplacer{static[a371_0x15b506(0x135)](_0x2a1c66){const _0x3d64d8=a371_0x15b506;return String(_0x2a1c66)[_0x3d64d8(0x10c)](0x2,'0');}static[a371_0x15b506(0x11c)](_0x153cfe){const _0x4084c3=a371_0x15b506,_0xd7a406=_0x153cfe[_0x4084c3(0x101)](),_0x318f25=this[_0x4084c3(0x135)](_0x153cfe[_0x4084c3(0x118)]()+0x1),_0x4c901f=this[_0x4084c3(0x135)](_0x153cfe[_0x4084c3(0x11e)]()),_0x1135b3=this[_0x4084c3(0x135)](_0x153cfe['getHours']()),_0x4af0a1=this['pad'](_0x153cfe[_0x4084c3(0x10e)]()),_0x31fb99=this['pad'](_0x153cfe[_0x4084c3(0x132)]());return{'createdAt':_0xd7a406+'-'+_0x318f25+'-'+_0x4c901f+'\x20'+_0x1135b3+':'+_0x4af0a1+':'+_0x31fb99,'createdDate':_0xd7a406+'-'+_0x318f25+'-'+_0x4c901f,'createdTime':_0x1135b3+':'+_0x4af0a1+':'+_0x31fb99};}static[a371_0x15b506(0x128)](_0xf18556){const _0x31fa7e=a371_0x15b506,_0x3415f9=_0xf18556[_0x31fa7e(0x10b)]('/')[_0x31fa7e(0x134)]()||_0xf18556;return _0x3415f9[_0x31fa7e(0x10b)]('-')['map'](_0x4b66be=>_0x4b66be['charAt'](0x0)[_0x31fa7e(0x129)]()+_0x4b66be[_0x31fa7e(0x11b)](0x1)[_0x31fa7e(0x110)]())[_0x31fa7e(0x114)]('');}static['toDisplayTitle'](_0x1f02fe){const _0x747e95=a371_0x15b506,_0x5eb073=_0x1f02fe['split']('/')[_0x747e95(0x134)]()||_0x1f02fe;return _0x5eb073[_0x747e95(0x10b)]('-')[_0x747e95(0x116)](_0x190140=>_0x190140[_0x747e95(0x105)](0x0)['toUpperCase']()+_0x190140[_0x747e95(0x11b)](0x1)[_0x747e95(0x110)]())[_0x747e95(0x114)]('\x20');}static[a371_0x15b506(0x13a)](_0x37a0b6,_0x153530,_0x145cbe){const _0x2ced35=a371_0x15b506,_0x5cc9e5=this[_0x2ced35(0x128)](_0x153530),_0x39bdb9=this[_0x2ced35(0x104)](_0x153530),{createdAt:_0x60a38f,createdDate:_0x594dc3,createdTime:_0x62c3b9}=this['formatLocalTimestamp'](new Date());let _0x1895f1=_0x37a0b6[_0x2ced35(0x112)](/\{CliVersion\}/g,CLI_VERSION)[_0x2ced35(0x112)](/\{ComponentName\}/g,_0x5cc9e5)[_0x2ced35(0x112)](/\{DisplayTitle\}/g,_0x39bdb9)['replace'](/\{PageName\}/g,_0x153530)['replace'](/\{TemplateName\}/g,_0x145cbe)[_0x2ced35(0x112)](/\{CreatedAt\}/g,_0x60a38f)[_0x2ced35(0x112)](/\{CreatedDate\}/g,_0x594dc3)[_0x2ced35(0x112)](/\{CreatedTime\}/g,_0x62c3b9);return _0x1895f1;}static[a371_0x15b506(0x11d)](_0x13ee74,_0xed4ffc,_0x3ac1cd,_0x3f5d02,_0x1f12c4,_0x451e8f,_0x3139d7,_0x4be8fe,_0x505435){const _0xa86fe2=a371_0x15b506,_0x4c9233=new Date(),_0x2ffbce=_0x4c9233[_0xa86fe2(0x12e)](),_0x2cbb3d=_0x3ac1cd[_0xa86fe2(0x116)](_0x4bb323=>{const _0x12e94f=_0xa86fe2,_0x3d0717=[_0x12e94f(0x126)+_0x4bb323[_0x12e94f(0x11a)]+'\x22','tableName:\x20\x22'+_0x4bb323['tableName']+'\x22',_0x12e94f(0x12f)+_0x4bb323['name']+'\x22'];return _0x4bb323[_0x12e94f(0x113)]&&_0x3d0717[_0x12e94f(0x13b)](_0x12e94f(0x109)+_0x4bb323[_0x12e94f(0x113)]+'\x22'),_0x12e94f(0x137)+_0x3d0717[_0x12e94f(0x114)](',\x20')+_0x12e94f(0x121);})[_0xa86fe2(0x114)](''),_0x471289=_0x3f5d02||_0x3ac1cd[0x0]?.[_0xa86fe2(0x113)]||_0xa86fe2(0x10f);let _0x3435e8=_0x13ee74[_0xa86fe2(0x112)](/\{AppCode\}/g,_0xed4ffc)[_0xa86fe2(0x112)](/\{ModelConfigs\}/g,_0x2cbb3d)[_0xa86fe2(0x112)](/\{ExampleModelName\}/g,_0x471289)[_0xa86fe2(0x112)](/\{ApiFileName\}/g,_0x1f12c4||_0xa86fe2(0x138))[_0xa86fe2(0x112)](/\{ConfigName\}/g,_0x451e8f||'default')[_0xa86fe2(0x112)](/\{ClientConfigParam\}/g,_0x3139d7||'')['replace'](/\{SdkConfigFileName\}/g,_0x505435||_0xa86fe2(0x107))[_0xa86fe2(0x112)](/\{VarPrefix\}/g,_0x4be8fe||'LOVRABET')[_0xa86fe2(0x112)](/\{CreatedAt\}/g,_0x2ffbce);return _0x3435e8;}static async['processTemplate'](_0x1e6c60,_0x3a3370,_0x3ad1af,_0x535e9e,_0x233090=!![]){const _0x49e7d9=a371_0x15b506,_0xf7b865=Date['now']();try{_0x233090&&logger[_0x49e7d9(0x140)](_0x49e7d9(0x13c),'Starting\x20template\x20content\x20replacement',{'templatePath':_0x1e6c60,'targetPath':_0x3a3370,'pageName':_0x3ad1af,'templateName':_0x535e9e});await a371_0x5e0c76['promises'][_0x49e7d9(0xfc)](_0x3a3370,{'recursive':!![]}),await this[_0x49e7d9(0xff)](_0x1e6c60,_0x3a3370,_0x3ad1af,_0x535e9e);if(_0x233090){const _0x2c61d9=Date[_0x49e7d9(0x139)]()-_0xf7b865;logger['success']('template',_0x49e7d9(0xfd),_0x2c61d9,{'pageName':_0x3ad1af,'templateName':_0x535e9e});}}catch(_0x29bd07){if(_0x233090){const _0x108ff7=Date[_0x49e7d9(0x139)]()-_0xf7b865;logger[_0x49e7d9(0x122)](_0x49e7d9(0x13c),'Template\x20content\x20replacement\x20failed',{'templatePath':_0x1e6c60,'targetPath':_0x3a3370,'pageName':_0x3ad1af,'templateName':_0x535e9e,'error':_0x29bd07 instanceof Error?_0x29bd07[_0x49e7d9(0x119)]:String(_0x29bd07),'duration':_0x108ff7});}throw _0x29bd07;}}static async[a371_0x15b506(0xff)](_0x44505c,_0x426d9a,_0x2f8b56,_0x267c6b){const _0x175bbc=a371_0x15b506,_0x58566a=await a371_0x5e0c76[_0x175bbc(0x103)][_0x175bbc(0x12a)](_0x44505c,{'withFileTypes':!![]});for(const _0x150cc3 of _0x58566a){const _0x38b099=a371_0x3d4f3c[_0x175bbc(0x114)](_0x44505c,_0x150cc3[_0x175bbc(0x11f)]);let _0x5533fa=a371_0x3d4f3c['join'](_0x426d9a,_0x150cc3[_0x175bbc(0x11f)]);_0x150cc3[_0x175bbc(0x11f)]['endsWith'](_0x175bbc(0x123))&&(_0x5533fa=a371_0x3d4f3c[_0x175bbc(0x114)](_0x426d9a,_0x150cc3[_0x175bbc(0x11f)]['replace'](/\.tpl$/,'')));if(_0x150cc3[_0x175bbc(0x12c)]())await a371_0x5e0c76[_0x175bbc(0x103)][_0x175bbc(0xfc)](_0x5533fa,{'recursive':!![]}),await this['processDirectory'](_0x38b099,_0x5533fa,_0x2f8b56,_0x267c6b);else _0x150cc3[_0x175bbc(0x12d)]()&&await this['processFile'](_0x38b099,_0x5533fa,_0x2f8b56,_0x267c6b);}}static async[a371_0x15b506(0x102)](_0x14a9b0,_0x143ea9,_0x4f85f4,_0xee69cb){const _0x67079f=a371_0x15b506,_0x506f5c=a371_0x3d4f3c[_0x67079f(0x100)](_0x14a9b0)[_0x67079f(0x110)]();_0x14a9b0['endsWith'](_0x67079f(0x123))&&(_0x143ea9=_0x143ea9[_0x67079f(0x112)](/\.tpl$/,''));const _0x100f86=[_0x67079f(0x12b),_0x67079f(0x130),_0x67079f(0x13d),'.js',_0x67079f(0x10a),_0x67079f(0x141),_0x67079f(0x117),_0x67079f(0x111),_0x67079f(0x123)];if(_0x100f86['includes'](_0x506f5c)||_0x14a9b0[_0x67079f(0x127)](_0x67079f(0x123))){const _0xc2398b=await a371_0x5e0c76[_0x67079f(0x103)]['readFile'](_0x14a9b0,_0x67079f(0x13e)),_0x1d1ba3=this[_0x67079f(0x13a)](_0xc2398b,_0x4f85f4,_0xee69cb);await a371_0x5e0c76[_0x67079f(0x103)][_0x67079f(0x120)](_0x143ea9,_0x1d1ba3,_0x67079f(0x13e));}else await a371_0x5e0c76['promises'][_0x67079f(0x124)](_0x14a9b0,_0x143ea9);}}function a371_0x2b07(_0x22bbce,_0x27f9df){_0x22bbce=_0x22bbce-0xfc;const _0x2e9129=a371_0x2e91();let _0x2b07c5=_0x2e9129[_0x22bbce];return _0x2b07c5;}function a371_0x2e91(){const _0x2f889c=['.json','split','padStart','7414264zhxNfs','getMinutes','YourModel','toLowerCase','.scss','replace','alias','join','2820723WtkZpl','map','.css','getMonth','message','datasetCode','slice','formatLocalTimestamp','replaceApiContent','getDate','name','writeFile','\x20},','error','.tpl','copyFile','2543860rrRKco','datasetCode:\x20\x22','endsWith','toComponentName','toUpperCase','readdir','.tsx','isDirectory','isFile','toISOString','name:\x20\x22','.ts','2632745DzWVkZ','getSeconds','2723DlYoCT','pop','pad','2ZAbzdO','\x0a\x20\x20\x20\x20{\x20','api','now','replaceContent','push','template','.jsx','utf8','8650jgiLPh','info','.md','mkdir','Template\x20content\x20replacement\x20completed','552782eKQoOs','processDirectory','extname','getFullYear','processFile','promises','toDisplayTitle','charAt','1014ZyWtFP','sdk-config','21051QuovXp','alias:\x20\x22'];a371_0x2e91=function(){return _0x2f889c;};return a371_0x2e91();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x5d4e0d,_0x9cccc1){const _0x2101e0=a372_0xeb7b,_0x5e68a0=_0x5d4e0d();while(!![]){try{const _0x33ae36=-parseInt(_0x2101e0(0x1f6))/0x1+-parseInt(_0x2101e0(0x1f8))/0x2*(parseInt(_0x2101e0(0x1ec))/0x3)+parseInt(_0x2101e0(0x200))/0x4+parseInt(_0x2101e0(0x1f5))/0x5*(parseInt(_0x2101e0(0x203))/0x6)+parseInt(_0x2101e0(0x1fd))/0x7+parseInt(_0x2101e0(0x1f3))/0x8*(-parseInt(_0x2101e0(0x202))/0x9)+parseInt(_0x2101e0(0x1ff))/0xa*(parseInt(_0x2101e0(0x1f4))/0xb);if(_0x33ae36===_0x9cccc1)break;else _0x5e68a0['push'](_0x5e68a0['shift']());}catch(_0x4bfa0b){_0x5e68a0['push'](_0x5e68a0['shift']());}}}(a372_0xb650,0x8d587));import{mkdir,readFile,writeFile}from'node:fs/promises';import{homedir}from'node:os';import{dirname,join}from'node:path';import a372_0x1eeeab from'semver';import{CLI_BIN_NAME,NPM_PACKAGE_NAME}from'../constant/cli.js';function a372_0xb650(){const _0x560568=['trim','362brWPQD','object','number','checkedAt','lastNotifiedAt','5359424SmJwUm','parse','2710QEqTOl','1861968mHrvjD','valid','9607581ENqdho','6GvVyLI','stringify','\x20update','utf8','15117hrsUKN','/v/',',\x20run:\x20','true','.cache','lastNotifiedVersion','toLowerCase','8pmIssX','83721Vnbsfl','157915sLLgTB','766769XcPYRW'];a372_0xb650=function(){return _0x560568;};return a372_0xb650();}import{getCliVersionPolicy}from'../utils/cli-version-policy.js';import{getCliVersion}from'../utils/version.js';const UPDATE_CHECK_TTL_MS=0xc*0x3c*0x3c*0x3e8,UPDATE_NOTICE_TTL_MS=0x18*0x3c*0x3c*0x3e8;function isUpdateNoticeDisabled(){const _0x3e6da4=a372_0xeb7b,_0x55928f=process.env.RABETBASE_NO_UPDATE_NOTICE?.[_0x3e6da4(0x1f7)]()[_0x3e6da4(0x1f2)]();return _0x55928f==='1'||_0x55928f===_0x3e6da4(0x1ef)||_0x55928f==='yes';}function cacheRoot(){const _0x2d6ac2=a372_0xeb7b;return process.env.XDG_CACHE_HOME||process.env.LOCALAPPDATA||join(homedir(),_0x2d6ac2(0x1f0));}function a372_0xeb7b(_0x596165,_0x26f574){_0x596165=_0x596165-0x1ec;const _0xb65068=a372_0xb650();let _0xeb7b76=_0xb65068[_0x596165];return _0xeb7b76;}export function getUpdateNoticeCachePath(){return join(cacheRoot(),'rabetbase-cli','update-check.json');}async function readUpdateNoticeCache(){const _0x48611a=a372_0xeb7b;try{const _0x251845=await readFile(getUpdateNoticeCachePath(),_0x48611a(0x206)),_0x2eda77=JSON[_0x48611a(0x1fe)](_0x251845);if(!_0x2eda77||typeof _0x2eda77!==_0x48611a(0x1f9))return{};return _0x2eda77;}catch{return{};}}async function writeUpdateNoticeCache(_0x3f1100){const _0x17739a=a372_0xeb7b;try{const _0x4b474b=getUpdateNoticeCachePath();await mkdir(dirname(_0x4b474b),{'recursive':!![]}),await writeFile(_0x4b474b,JSON[_0x17739a(0x204)](_0x3f1100,null,0x2)+'\x0a','utf8');}catch{}}function isFreshCheck(_0x104c54,_0x367207){const _0x45cefe=a372_0xeb7b;return typeof _0x104c54['checkedAt']===_0x45cefe(0x1fa)&&_0x367207-_0x104c54[_0x45cefe(0x1fb)]<UPDATE_CHECK_TTL_MS;}function isRecentlyNotified(_0x421304,_0x42f951,_0x3dd929){const _0x1e3fbd=a372_0xeb7b;return _0x421304[_0x1e3fbd(0x1f1)]===_0x42f951&&typeof _0x421304[_0x1e3fbd(0x1fc)]===_0x1e3fbd(0x1fa)&&_0x3dd929-_0x421304[_0x1e3fbd(0x1fc)]<UPDATE_NOTICE_TTL_MS;}export function buildNpmVersionUrl(_0x283bdb){const _0x5a7b8a=a372_0xeb7b;return'https://www.npmjs.com/package/'+NPM_PACKAGE_NAME+_0x5a7b8a(0x1ed)+_0x283bdb;}export async function resolveLatestUpdateNotice(){const _0x25a969=a372_0xeb7b;if(isUpdateNoticeDisabled())return null;try{const _0x54e99a=Date['now'](),_0x6849a9=getCliVersion(),_0xfe3bbe=await readUpdateNoticeCache();let _0x34a702=isFreshCheck(_0xfe3bbe,_0x54e99a)?_0xfe3bbe['latest']?.[_0x25a969(0x1f7)]():undefined;if(!_0x34a702&&!isFreshCheck(_0xfe3bbe,_0x54e99a)){const _0x19d273=await getCliVersionPolicy();_0x34a702=_0x19d273?.['stableVersion']?.[_0x25a969(0x1f7)]()||undefined,await writeUpdateNoticeCache({..._0xfe3bbe,'checkedAt':_0x54e99a,'latest':_0x34a702,'failed':!_0x34a702});}if(!_0x34a702||!a372_0x1eeeab[_0x25a969(0x201)](_0x6849a9)||!a372_0x1eeeab['valid'](_0x34a702))return null;if(a372_0x1eeeab['gte'](_0x6849a9,_0x34a702))return null;if(isRecentlyNotified(_0xfe3bbe,_0x34a702,_0x54e99a))return null;const _0x459ee5=CLI_BIN_NAME+_0x25a969(0x205);return await writeUpdateNoticeCache({..._0xfe3bbe,'checkedAt':isFreshCheck(_0xfe3bbe,_0x54e99a)?_0xfe3bbe[_0x25a969(0x1fb)]:_0x54e99a,'latest':_0x34a702,'failed':![],'lastNotifiedVersion':_0x34a702,'lastNotifiedAt':_0x54e99a}),{'command':_0x459ee5,'current':_0x6849a9,'latest':_0x34a702,'url':buildNpmVersionUrl(_0x34a702),'message':CLI_BIN_NAME+'\x20'+_0x34a702+'\x20available,\x20current\x20'+_0x6849a9+_0x25a969(0x1ee)+_0x459ee5};}catch{return null;}}
|
package/lib/utils/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x187590,_0xf7afb3){var _0x53e7c6=a373_0x15bf,_0x47f0b6=_0x187590();while(!![]){try{var _0x49541c=-parseInt(_0x53e7c6(0xad))/0x1*(parseInt(_0x53e7c6(0xb2))/0x2)+-parseInt(_0x53e7c6(0xaf))/0x3+-parseInt(_0x53e7c6(0xb1))/0x4*(-parseInt(_0x53e7c6(0xaa))/0x5)+parseInt(_0x53e7c6(0xb3))/0x6+parseInt(_0x53e7c6(0xb4))/0x7*(parseInt(_0x53e7c6(0xae))/0x8)+-parseInt(_0x53e7c6(0xac))/0x9*(parseInt(_0x53e7c6(0xb0))/0xa)+parseInt(_0x53e7c6(0xab))/0xb;if(_0x49541c===_0xf7afb3)break;else _0x47f0b6['push'](_0x47f0b6['shift']());}catch(_0x509304){_0x47f0b6['push'](_0x47f0b6['shift']());}}}(a373_0xa826,0x9c127));function a373_0x15bf(_0x123219,_0x1a7de7){_0x123219=_0x123219-0xaa;var _0xa82617=a373_0xa826();var _0x15bf11=_0xa82617[_0x123219];return _0x15bf11;}import{VERSION}from'../generated/build-info.js';export function getCliVersion(){return VERSION;}function a373_0xa826(){var _0x2a2d97=['284wecAQU','38CmLZBI','280854MzMxSl','14PBJYzR','79460asbBbV','4231964RpkjXC','7480197rsMuQy','35941llaVFV','2400888WuadBs','20412SOGueG','10ZdwdUm'];a373_0xa826=function(){return _0x2a2d97;};return a373_0xa826();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x13f638,_0x2888e4){var _0xa9ccd3=a374_0x3d75,_0x2fd4b2=_0x13f638();while(!![]){try{var _0xcbe870=-parseInt(_0xa9ccd3(0x1c0))/0x1+-parseInt(_0xa9ccd3(0x1bd))/0x2*(parseInt(_0xa9ccd3(0x1c4))/0x3)+-parseInt(_0xa9ccd3(0x1bf))/0x4+parseInt(_0xa9ccd3(0x1c1))/0x5*(-parseInt(_0xa9ccd3(0x1be))/0x6)+parseInt(_0xa9ccd3(0x1bb))/0x7*(parseInt(_0xa9ccd3(0x1c3))/0x8)+-parseInt(_0xa9ccd3(0x1bc))/0x9+parseInt(_0xa9ccd3(0x1c2))/0xa;if(_0xcbe870===_0x2888e4)break;else _0x2fd4b2['push'](_0x2fd4b2['shift']());}catch(_0x153785){_0x2fd4b2['push'](_0x2fd4b2['shift']());}}}(a374_0x8395,0x6d790));function a374_0x8395(){var _0x295a57=['21282400yszWMe','4378360cgTRrR','22845jrfDoM','7mDBSMy','3285576kaUwAG','118lsQAWZ','4494sIxTVN','2432764NDYncg','251084oUHWjG','3695sXONIj'];a374_0x8395=function(){return _0x295a57;};return a374_0x8395();}function a374_0x3d75(_0x4ee47d,_0x168a7b){_0x4ee47d=_0x4ee47d-0x1bb;var _0x839586=a374_0x8395();var _0x3d7575=_0x839586[_0x4ee47d];return _0x3d7575;}import{setActiveCookie,clearActiveCookie}from'../core/api-client.js';export async function withActiveCookie(_0x469441,_0x5ca1dd){setActiveCookie(_0x469441);try{return await _0x5ca1dd();}finally{clearActiveCookie();}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x3c5e36,_0x13b38f){var _0x1d9f65=a375_0x1bf4,_0x469c77=_0x3c5e36();while(!![]){try{var _0x224d5e=-parseInt(_0x1d9f65(0xef))/0x1*(parseInt(_0x1d9f65(0xf3))/0x2)+parseInt(_0x1d9f65(0xf1))/0x3+parseInt(_0x1d9f65(0xfa))/0x4+parseInt(_0x1d9f65(0xf6))/0x5*(parseInt(_0x1d9f65(0xf5))/0x6)+-parseInt(_0x1d9f65(0xf7))/0x7*(-parseInt(_0x1d9f65(0xf4))/0x8)+-parseInt(_0x1d9f65(0xf8))/0x9*(-parseInt(_0x1d9f65(0xf9))/0xa)+-parseInt(_0x1d9f65(0xf0))/0xb;if(_0x224d5e===_0x13b38f)break;else _0x469c77['push'](_0x469c77['shift']());}catch(_0x288647){_0x469c77['push'](_0x469c77['shift']());}}}(a375_0x48d2,0x6e6e5));function a375_0x48d2(){var _0x346158=['35685VyITsO','1630UGCsiD','3368548AySsBx','write','1EBWkiT','24015178mYQFxd','1999689KNZgbH','stderr','1736870jADJmQ','9224RDBcRH','3582ADsWVq','3785vyOwtB','5446vvTuMm'];a375_0x48d2=function(){return _0x346158;};return a375_0x48d2();}function a375_0x1bf4(_0x1cbba3,_0x5ffe1b){_0x1cbba3=_0x1cbba3-0xee;var _0x48d232=a375_0x48d2();var _0x1bf4b9=_0x48d232[_0x1cbba3];return _0x1bf4b9;}export function writeCliSideChannelLine(_0x3aaa6f){var _0x4efb77=a375_0x1bf4;process[_0x4efb77(0xf2)][_0x4efb77(0xee)](_0x3aaa6f+'\x0a');}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lovrabet/rabetbase-cli",
|
|
3
|
-
"version": "2.5.11
|
|
3
|
+
"version": "2.5.11",
|
|
4
4
|
"description": "Developer CLI for Lovrabet apps, datasets, pages, SQL, Backend Function, database connections, skills, and AI agent workflows.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE",
|
|
6
6
|
"keywords": [
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: rabetbase
|
|
3
|
-
version: 2.5.11
|
|
3
|
+
version: 2.5.11
|
|
4
4
|
description: "Use for Lovrabet development work through the rabetbase CLI: create or bind projects (including creating an AppCode project in the current folder), pull Dataset/API facts and maintain SDK clients, or manage datasets, Instant API access policies, database connections, pages, host frontend integration, frontend subapp resources, SQL, Backend Functions, approval flows and workflows, menus, notifications, knowledge bases and kb search, Agent Context Rules, roles, files, OCR, deployment metadata, platform issues, and 钉钉沙箱账号绑定. Trigger when the user mentions rabetbase, Lovrabet development, AppCode, Dataset, Instant API allow/deny/route policy, project creation, api pull/codegen, dblink, page, host frontend integration, subapp resource versions, SQL, BFF, creating or designing an approval flow, workflow, business process, or multi-step approval, menu, notification, knowledge base, kb search, Agent Context Rules, RULES.md, DATABASE.md, rule list/get/set, role, file/OCR, or related development workflows."
|
|
5
5
|
metadata:
|
|
6
6
|
requires:
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
"schemaVersion": 1,
|
|
3
3
|
"name": "rabetbase",
|
|
4
4
|
"packageName": "@lovrabet/rabetbase-cli",
|
|
5
|
-
"packageVersion": "2.5.11
|
|
6
|
-
"skillVersion": "2.5.11
|
|
5
|
+
"packageVersion": "2.5.11",
|
|
6
|
+
"skillVersion": "2.5.11",
|
|
7
7
|
"files": [
|
|
8
8
|
"SKILL.md",
|
|
9
9
|
"guides/approval-flow-development-workflow.md",
|
|
@@ -159,5 +159,5 @@
|
|
|
159
159
|
"references/rabetbase-user-account.md",
|
|
160
160
|
"references/rabetbase-workspace.md"
|
|
161
161
|
],
|
|
162
|
-
"digest": "
|
|
162
|
+
"digest": "71d5a95e909c19546333ce873561d079a8604fa879f2eacc36c4503619d437e6"
|
|
163
163
|
}
|