@lovrabet/rabetbase-cli 2.5.12-beta.1 → 2.5.12
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_0x50ba64=a358_0x2583;function a358_0x2583(_0x48b4df,_0x358c39){_0x48b4df=_0x48b4df-0xf8;const _0x2914ac=a358_0x2914();let _0x2583c8=_0x2914ac[_0x48b4df];return _0x2583c8;}(function(_0x41b8e3,_0x4eed0e){const _0x5f1a93=a358_0x2583,_0x309b90=_0x41b8e3();while(!![]){try{const _0x37d527=-parseInt(_0x5f1a93(0x117))/0x1+parseInt(_0x5f1a93(0x10e))/0x2+parseInt(_0x5f1a93(0xf9))/0x3+parseInt(_0x5f1a93(0x10a))/0x4+parseInt(_0x5f1a93(0xf8))/0x5*(parseInt(_0x5f1a93(0x105))/0x6)+parseInt(_0x5f1a93(0x113))/0x7*(-parseInt(_0x5f1a93(0x102))/0x8)+-parseInt(_0x5f1a93(0x112))/0x9;if(_0x37d527===_0x4eed0e)break;else _0x309b90['push'](_0x309b90['shift']());}catch(_0x3a4434){_0x309b90['push'](_0x309b90['shift']());}}}(a358_0x2914,0x4c8f5));import a358_0x9edfba from'node:fs';import a358_0x1370c9 from'node:path';import a358_0x313015 from'semver';import{getCdnConfig}from'../utils/cdn-config.js';function a358_0x2914(){const _0x14a726=['npm\x20install\x20','2671535gyApVO','1231149XcHrYH','\x20\x20\x20Upgrade\x20command:\x20','@lovrabet/sdk','stableVersion','package.json','latest','\x1b[0m','utf8','needsUpgrade','56JTktXo','1.2.0','\x20\x20\x20Stable\x20version:\x20','6uqdUQr','minVersion','readFileSync','join','node','674296xNGCKJ','existsSync','utf-8','coerce','919178PHOiST','packageName','devDependencies','dependencies','7583418okviuK','145103vNVzcT','↪\x20SDK\x20update\x20available','sdk','\x1b[33m','271559VdaEZm','log','parse'];a358_0x2914=function(){return _0x14a726;};return a358_0x2914();}const FALLBACK_MIN_SDK_VERSION=a358_0x50ba64(0x103);function isNonNumericVersion(_0x459a10){const _0x16d5ad=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x16d5ad['some'](_0x594a84=>_0x594a84['test'](_0x459a10));}function getInstalledVersion(_0xb1c3de,_0x3d4fb5){const _0x2c23b6=a358_0x50ba64;try{const _0xc45d1d=a358_0x1370c9['join'](_0xb1c3de,'node_modules',_0x3d4fb5,_0x2c23b6(0xfd));if(a358_0x9edfba[_0x2c23b6(0x10b)](_0xc45d1d)){const _0x2b13c0=JSON[_0x2c23b6(0x119)](a358_0x9edfba[_0x2c23b6(0x107)](_0xc45d1d,_0x2c23b6(0x10c)));return _0x2b13c0['version']||null;}}catch{}return null;}async function getSdkStableVersion(){const _0x3ffb7e=a358_0x50ba64;try{const _0x241b8b=await getCdnConfig();return _0x241b8b?.['sdk']?.[_0x3ffb7e(0x109)]?.[_0x3ffb7e(0xfc)]||null;}catch{return null;}}async function getSdkPackageName(){const _0x387775=a358_0x50ba64;try{const _0xfa3b11=await getCdnConfig();return _0xfa3b11?.[_0x387775(0x115)]?.[_0x387775(0x109)]?.[_0x387775(0x10f)]||_0x387775(0xfb);}catch{return _0x387775(0xfb);}}export async function checkSdkVersion(_0x115241){const _0x2af25a=a358_0x50ba64,_0x19af89=a358_0x1370c9[_0x2af25a(0x108)](_0x115241,_0x2af25a(0xfd)),[_0xabfa7d,_0x2df6a4]=await Promise['all']([getSdkStableVersion(),getSdkPackageName()]),_0x5e51b5=_0xabfa7d||FALLBACK_MIN_SDK_VERSION;if(!a358_0x9edfba[_0x2af25a(0x10b)](_0x19af89))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x5e51b5,'packageName':_0x2df6a4,'stableVersion':_0xabfa7d};try{const _0x78eaf0=JSON[_0x2af25a(0x119)](a358_0x9edfba[_0x2af25a(0x107)](_0x19af89,_0x2af25a(0x100))),_0x1e0863=_0x78eaf0[_0x2af25a(0x111)]||{},_0x3835bf=_0x78eaf0[_0x2af25a(0x110)]||{},_0x3b8475=_0x1e0863[_0x2df6a4]||_0x3835bf[_0x2df6a4];if(!_0x3b8475)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x5e51b5,'packageName':_0x2df6a4,'stableVersion':_0xabfa7d};let _0x5a21a3=getInstalledVersion(_0x115241,_0x2df6a4);!_0x5a21a3&&(_0x5a21a3=_0x3b8475);if(isNonNumericVersion(_0x3b8475))return{'installed':!![],'version':_0x5a21a3,'needsUpgrade':![],'minVersion':_0x5e51b5,'packageName':_0x2df6a4,'stableVersion':_0xabfa7d};const _0x2123f0=a358_0x313015[_0x2af25a(0x10d)](_0x5a21a3),_0x1e61c8=a358_0x313015[_0x2af25a(0x10d)](_0x5e51b5),_0x1f5ced=_0x2123f0&&_0x1e61c8?a358_0x313015['lt'](_0x2123f0,_0x1e61c8):![];return{'installed':!![],'version':_0x5a21a3,'needsUpgrade':_0x1f5ced,'minVersion':_0x5e51b5,'packageName':_0x2df6a4,'stableVersion':_0xabfa7d};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x5e51b5,'packageName':_0x2df6a4,'stableVersion':_0xabfa7d};}}export function checkSdkVersionSync(_0x1a014e){const _0x18a9fa=a358_0x50ba64,_0x36b674=a358_0x1370c9[_0x18a9fa(0x108)](_0x1a014e,_0x18a9fa(0xfd)),_0x2e9505=_0x18a9fa(0xfb);if(!a358_0x9edfba[_0x18a9fa(0x10b)](_0x36b674))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2e9505,'stableVersion':null};try{const _0x388030=JSON[_0x18a9fa(0x119)](a358_0x9edfba[_0x18a9fa(0x107)](_0x36b674,_0x18a9fa(0x100))),_0x13a1a9=_0x388030['dependencies']||{},_0x5536b4=_0x388030['devDependencies']||{},_0xd0e483=_0x13a1a9[_0x2e9505]||_0x5536b4[_0x2e9505];if(!_0xd0e483)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2e9505,'stableVersion':null};let _0xd1ee82=getInstalledVersion(_0x1a014e,_0x2e9505);!_0xd1ee82&&(_0xd1ee82=_0xd0e483);if(isNonNumericVersion(_0xd0e483))return{'installed':!![],'version':_0xd1ee82,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2e9505,'stableVersion':null};const _0x13cf7f=a358_0x313015[_0x18a9fa(0x10d)](_0xd1ee82),_0x41d154=_0x13cf7f?a358_0x313015['lt'](_0x13cf7f,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0xd1ee82,'needsUpgrade':_0x41d154,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2e9505,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2e9505,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x3af4d4){const _0x2d92c6=a358_0x50ba64;if(!_0x3af4d4[_0x2d92c6(0x101)])return;const _0x4334c7=_0x2d92c6(0x116),_0x26d318=_0x2d92c6(0xff),_0x5f3523='\x1b[1m',_0x545268=_0x3af4d4[_0x2d92c6(0x10f)]||_0x2d92c6(0xfb),_0x27bbf5=_0x3af4d4[_0x2d92c6(0xfc)]||_0x3af4d4[_0x2d92c6(0x106)],_0x9067=_0x2d92c6(0x11a)+_0x545268+'@'+(_0x27bbf5||_0x2d92c6(0xfe));console[_0x2d92c6(0x118)](),console['log'](''+_0x4334c7+_0x5f3523+_0x2d92c6(0x114)+_0x26d318),console[_0x2d92c6(0x118)](_0x4334c7+'\x20\x20\x20Current\x20version:\x20'+_0x545268+'@'+_0x3af4d4['version']+_0x26d318),console['log'](_0x4334c7+_0x2d92c6(0x104)+_0x27bbf5+_0x26d318),console[_0x2d92c6(0x118)](_0x4334c7+_0x2d92c6(0xfa)+_0x9067+_0x26d318),console[_0x2d92c6(0x118)]();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a359_0x3262(_0x2d193b,_0x2b764d){_0x2d193b=_0x2d193b-0x135;const _0x2f9627=a359_0x2f96();let _0x326227=_0x2f9627[_0x2d193b];return _0x326227;}(function(_0x190664,_0x524ede){const _0x5b087e=a359_0x3262,_0x114829=_0x190664();while(!![]){try{const _0x1256b0=-parseInt(_0x5b087e(0x13c))/0x1+-parseInt(_0x5b087e(0x143))/0x2*(-parseInt(_0x5b087e(0x144))/0x3)+parseInt(_0x5b087e(0x137))/0x4+-parseInt(_0x5b087e(0x151))/0x5*(parseInt(_0x5b087e(0x146))/0x6)+-parseInt(_0x5b087e(0x142))/0x7+parseInt(_0x5b087e(0x15b))/0x8+parseInt(_0x5b087e(0x135))/0x9;if(_0x1256b0===_0x524ede)break;else _0x114829['push'](_0x114829['shift']());}catch(_0xfee519){_0x114829['push'](_0x114829['shift']());}}}(a359_0x2f96,0x67958));function a359_0x2f96(){const _0x2f60de=['3754051XyJwcS','27038yLsSfJ','96vZOeLW','../..','560526RGhFVN','\x20\x20\x20','coerce','↪\x20Critical\x20CLI\x20upgrade\x20required','utf-8','\x20\x20\x20Upgrade\x20command:\x20','belowMinimum','\x20\x20\x20Stable\x20version:\x20','\x1b[1m','minimumVersionMessage','\x1b[31m','5rXrEhN','\x1b[0m','Minimum\x20supported:\x20','1.0.0','\x20\x20\x20Recommended\x20stable:\x20','\x1b[33m','parse','currentVersion','stableVersion','package.json','1866728ijasWF','\x20\x20\x20Minimum\x20supported:\x20','Current\x20version:\x20','1620711PgbyqQ','npm\x20install\x20-g\x20','1802856CEwnKZ','latest','version','minimumVersion','log','242748xpnldB','join','validation','upgradeMessage','Upgrade\x20command:\x20','↪\x20New\x20version\x20available'];a359_0x2f96=function(){return _0x2f60de;};return a359_0x2f96();}import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a359_0x5cc296 from'semver';import{getCliVersionPolicy}from'../utils/cli-version-policy.js';import{NPM_PACKAGE_NAME}from'../constant/cli.js';import{CliErrors}from'../errors.js';export function getCliUpgradeCommand(_0x4da2a7){const _0x566817=a359_0x3262,_0xc7f433=_0x4da2a7[_0x566817(0x159)]||_0x566817(0x138);return _0x566817(0x136)+NPM_PACKAGE_NAME+'@'+_0xc7f433;}function getCurrentCliVersion(){const _0x16557f=a359_0x3262;try{const _0xd63c9f=fileURLToPath(import.meta.url),_0x22966c=resolve(dirname(_0xd63c9f),_0x16557f(0x145)),_0x436055=resolve(_0x22966c,_0x16557f(0x15a)),_0x4407e5=JSON[_0x16557f(0x157)](readFileSync(_0x436055,_0x16557f(0x14a)));return _0x4407e5[_0x16557f(0x139)]||_0x16557f(0x154);}catch{return _0x16557f(0x154);}}export async function checkCliVersion(){const _0x43e4da=a359_0x3262,_0x31c98e=getCurrentCliVersion(),_0x698495=await getCliVersionPolicy(),_0x25f846=_0x698495?.[_0x43e4da(0x159)]||null,_0x3d371b=_0x698495?.[_0x43e4da(0x13a)]||null;let _0xf5030a=![],_0xb8940e=![];const _0x5c744a=a359_0x5cc296[_0x43e4da(0x148)](_0x31c98e);if(_0x5c744a&&_0x25f846)try{const _0x507c52=a359_0x5cc296[_0x43e4da(0x148)](_0x25f846);if(_0x507c52)_0xf5030a=a359_0x5cc296['lt'](_0x5c744a,_0x507c52);}catch{}if(_0x5c744a&&_0x3d371b)try{const _0x19fae7=a359_0x5cc296[_0x43e4da(0x148)](_0x3d371b);if(_0x19fae7)_0xb8940e=a359_0x5cc296['lt'](_0x5c744a,_0x19fae7);}catch{}return _0xb8940e&&(_0xf5030a=!![]),{'currentVersion':_0x31c98e,'stableVersion':_0x25f846,'minimumVersion':_0x3d371b,'needsUpgrade':_0xf5030a,'belowMinimum':_0xb8940e,'isPreRelease':![],'upgradeMessage':_0x698495?.['upgradeMessage'],'minimumVersionMessage':_0x698495?.[_0x43e4da(0x14f)]};}export function printCliUpgradeWarning(_0x509b9b){const _0x2aa25a=a359_0x3262;if(!_0x509b9b['needsUpgrade']&&!_0x509b9b[_0x2aa25a(0x14c)])return;const _0x347684=_0x2aa25a(0x150),_0x1cb5ce=_0x2aa25a(0x156),_0x414caa=_0x2aa25a(0x152),_0x40c664=_0x2aa25a(0x14e),_0x3151c8=getCliUpgradeCommand(_0x509b9b);console[_0x2aa25a(0x13b)](),_0x509b9b[_0x2aa25a(0x14c)]?(console[_0x2aa25a(0x13b)](''+_0x347684+_0x40c664+_0x2aa25a(0x149)+_0x414caa),console['log'](_0x347684+'\x20\x20\x20Current\x20CLI\x20version:\x20'+_0x509b9b['currentVersion']+_0x414caa),_0x509b9b[_0x2aa25a(0x13a)]&&console[_0x2aa25a(0x13b)](_0x347684+_0x2aa25a(0x15c)+_0x509b9b[_0x2aa25a(0x13a)]+_0x414caa),_0x509b9b['stableVersion']&&_0x509b9b[_0x2aa25a(0x159)]!==_0x509b9b['minimumVersion']&&console[_0x2aa25a(0x13b)](_0x347684+_0x2aa25a(0x155)+_0x509b9b['stableVersion']+_0x414caa),_0x509b9b[_0x2aa25a(0x14f)]&&console[_0x2aa25a(0x13b)](_0x347684+_0x2aa25a(0x147)+_0x509b9b[_0x2aa25a(0x14f)]+_0x414caa),console[_0x2aa25a(0x13b)](_0x347684+_0x2aa25a(0x14b)+_0x3151c8+_0x414caa)):(console[_0x2aa25a(0x13b)](''+_0x1cb5ce+_0x40c664+_0x2aa25a(0x141)+_0x414caa),console[_0x2aa25a(0x13b)](_0x1cb5ce+'\x20\x20\x20Current\x20CLI\x20version:\x20'+_0x509b9b[_0x2aa25a(0x158)]+_0x414caa),console[_0x2aa25a(0x13b)](_0x1cb5ce+_0x2aa25a(0x14d)+_0x509b9b[_0x2aa25a(0x159)]+_0x414caa),_0x509b9b[_0x2aa25a(0x13f)]&&console[_0x2aa25a(0x13b)](_0x1cb5ce+_0x2aa25a(0x147)+_0x509b9b[_0x2aa25a(0x13f)]+_0x414caa),console[_0x2aa25a(0x13b)](_0x1cb5ce+'\x20\x20\x20Upgrade\x20command:\x20'+_0x3151c8+_0x414caa)),console[_0x2aa25a(0x13b)]();}export function assertCliVersionSupported(_0x4588ac){const _0x418136=a359_0x3262;if(!_0x4588ac[_0x418136(0x14c)])return;const _0x572f12=[_0x4588ac[_0x418136(0x14f)],_0x418136(0x15d)+_0x4588ac[_0x418136(0x158)],_0x4588ac['minimumVersion']?_0x418136(0x153)+_0x4588ac[_0x418136(0x13a)]:null,_0x418136(0x140)+getCliUpgradeCommand(_0x4588ac)]['filter'](Boolean)[_0x418136(0x13d)]('\x0a');throw CliErrors[_0x418136(0x13e)]('Current\x20CLI\x20version\x20is\x20below\x20the\x20service\x20compatibility\x20support\x20line.',_0x572f12);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x33a30b,_0x43f5b0){const _0x2fbbe8=a360_0x5bf8,_0x2197c4=_0x33a30b();while(!![]){try{const _0x1f21c3=-parseInt(_0x2fbbe8(0xe2))/0x1*(-parseInt(_0x2fbbe8(0xcf))/0x2)+parseInt(_0x2fbbe8(0xcc))/0x3*(parseInt(_0x2fbbe8(0xda))/0x4)+-parseInt(_0x2fbbe8(0xca))/0x5+parseInt(_0x2fbbe8(0xd5))/0x6+-parseInt(_0x2fbbe8(0xc9))/0x7*(-parseInt(_0x2fbbe8(0xcd))/0x8)+parseInt(_0x2fbbe8(0xe0))/0x9*(parseInt(_0x2fbbe8(0xd9))/0xa)+-parseInt(_0x2fbbe8(0xd7))/0xb;if(_0x1f21c3===_0x43f5b0)break;else _0x2197c4['push'](_0x2197c4['shift']());}catch(_0x18fd0f){_0x2197c4['push'](_0x2197c4['shift']());}}}(a360_0x1977,0x7c7fa));import{getCliVersionPolicyUrl,getProjectTemplateAssetBaseUrl,getProjectTemplateLegacyAssetBaseUrl}from'../constant/cdn.js';function a360_0x1977(){const _0x58781f=['10367oRMwYe','1791505YxhPAS','projectTemplate','3IYmnaW','1376XlMNxY','stableVersion','8XhRgqa','upgradeMessage','now','minimumVersion','trim','latestVersion','3152418VQtUHv','prerelease','25312914wAQMPF','beta','10wrclDM','3230508OjtKhj','signal','cli','string','json','object','8937063TtOXHP','abort','147163aekpNp','valid'];a360_0x1977=function(){return _0x58781f;};return a360_0x1977();}import a360_0x4af1f5 from'semver';const CACHE_TTL=0x5*0x3c*0x3e8,FAILURE_CACHE_TTL=0x3c*0x3e8,FETCH_TIMEOUT_MS=0xbb8;export function isBetaCliVersion(_0xdc73ae){const _0x19571d=a360_0x5bf8,_0x45ef5e=a360_0x4af1f5[_0x19571d(0xe3)](_0xdc73ae);return _0x45ef5e?a360_0x4af1f5[_0x19571d(0xd6)](_0x45ef5e)?.[0x0]===_0x19571d(0xd8):![];}export function resolveProjectTemplateDescriptor(_0x52cdb2,_0x184e28){const _0x19bdd0=a360_0x5bf8;if(isBetaCliVersion(_0x184e28))return _0x52cdb2['beta']?.[_0x19bdd0(0xcb)]??_0x52cdb2['projectTemplate'];return _0x52cdb2[_0x19bdd0(0xcb)];}function pickString(_0x234712){const _0xb4c1f0=a360_0x5bf8;return typeof _0x234712===_0xb4c1f0(0xdd)&&_0x234712[_0xb4c1f0(0xd3)]()['length']>0x0?_0x234712[_0xb4c1f0(0xd3)]():null;}function normalizeCliVersionPolicy(_0x1082f9){const _0x2404c3=a360_0x5bf8;if(!_0x1082f9||typeof _0x1082f9!=='object')return null;const _0x332800=_0x1082f9,_0x67763b=_0x332800[_0x2404c3(0xdc)]&&typeof _0x332800[_0x2404c3(0xdc)]===_0x2404c3(0xdf)?_0x332800[_0x2404c3(0xdc)]:_0x332800,_0x46fb28=pickString(_0x67763b[_0x2404c3(0xce)])||pickString(_0x67763b[_0x2404c3(0xd4)])||pickString(_0x67763b['recommendedVersion']),_0x44ef34=pickString(_0x67763b[_0x2404c3(0xd2)])||pickString(_0x67763b['minVersion']);if(!_0x46fb28&&!_0x44ef34)return null;return{'stableVersion':_0x46fb28,'minimumVersion':_0x44ef34,'upgradeMessage':pickString(_0x67763b[_0x2404c3(0xd0)])||undefined,'minimumVersionMessage':pickString(_0x67763b['minimumVersionMessage'])||undefined};}async function fetchRabetbaseCdnConfigAt(_0x383fba){const _0x58f549=a360_0x5bf8,_0x869d3=new AbortController(),_0x22db98=setTimeout(()=>_0x869d3[_0x58f549(0xe1)](),FETCH_TIMEOUT_MS);try{const _0x58ab6f=await fetch(_0x383fba,{'headers':{'Accept':'application/json'},'signal':_0x869d3[_0x58f549(0xdb)]});if(!_0x58ab6f['ok'])return null;const _0x43508d=await _0x58ab6f[_0x58f549(0xde)]();return _0x43508d&&typeof _0x43508d===_0x58f549(0xdf)?_0x43508d:null;}catch{return null;}finally{clearTimeout(_0x22db98);}}export async function fetchRabetbaseCdnConfig(){return fetchRabetbaseCdnConfigAt(getCliVersionPolicyUrl());}export async function fetchProjectTemplateCdnConfig(){const _0x5aafb6=await getRabetbaseCdnConfig();return _0x5aafb6?{'config':_0x5aafb6,'assetBaseUrl':getProjectTemplateAssetBaseUrl(),'legacyAssetBaseUrl':getProjectTemplateLegacyAssetBaseUrl()}:null;}export async function fetchCliVersionPolicy(){return normalizeCliVersionPolicy(await fetchRabetbaseCdnConfig());}function a360_0x5bf8(_0x581ec1,_0x1ae363){_0x581ec1=_0x581ec1-0xc9;const _0x19779b=a360_0x1977();let _0x5bf8dd=_0x19779b[_0x581ec1];return _0x5bf8dd;}let cachedConfig=null,cacheTime=0x0,hasCachedConfig=![];export async function getRabetbaseCdnConfig(){const _0x5d3560=a360_0x5bf8,_0x23f0cb=Date[_0x5d3560(0xd1)]();if(hasCachedConfig){const _0x238a85=cachedConfig?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x23f0cb-cacheTime<_0x238a85)return cachedConfig;}return cachedConfig=await fetchRabetbaseCdnConfig(),cacheTime=_0x23f0cb,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
|
-
(function(
|
|
1
|
+
(function(_0x1e2b82,_0x45126d){const _0x4de80d=a361_0x46cb,_0x570155=_0x1e2b82();while(!![]){try{const _0xac00c2=-parseInt(_0x4de80d(0xc5))/0x1+parseInt(_0x4de80d(0xc2))/0x2*(-parseInt(_0x4de80d(0xc3))/0x3)+-parseInt(_0x4de80d(0xba))/0x4+-parseInt(_0x4de80d(0xc1))/0x5+-parseInt(_0x4de80d(0xbc))/0x6*(parseInt(_0x4de80d(0xbb))/0x7)+-parseInt(_0x4de80d(0xbf))/0x8*(parseInt(_0x4de80d(0xc0))/0x9)+parseInt(_0x4de80d(0xb9))/0xa*(parseInt(_0x4de80d(0xc4))/0xb);if(_0xac00c2===_0x45126d)break;else _0x570155['push'](_0x570155['shift']());}catch(_0x439635){_0x570155['push'](_0x570155['shift']());}}}(a361_0x5f06,0xb7c9c));import{initEnv}from'../constant/env.js';import{readRawConfig,getConfigAppCode as a361_0x1d75de,getMultiAppConfigs as a361_0x233701,getTemplateBaseUrl as a361_0x110704}from'../context.js';export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';export{isInProject}from'../context.js';export function readConfig(_0x8c90ea){const _0x4f9e4c=a361_0x46cb,_0x36bf4f=readRawConfig(_0x8c90ea);return _0x36bf4f[_0x4f9e4c(0xbe)]&&typeof _0x36bf4f['env']===_0x4f9e4c(0xbd)&&initEnv(_0x36bf4f[_0x4f9e4c(0xbe)]),_0x36bf4f;}function a361_0x46cb(_0x2a6ecb,_0x46e577){_0x2a6ecb=_0x2a6ecb-0xb9;const _0x5f06e5=a361_0x5f06();let _0x46cb7a=_0x5f06e5[_0x2a6ecb];return _0x46cb7a;}function a361_0x5f06(){const _0x4e8972=['2092200ufxvhj','45RRvWGZ','6951315HWNxmK','176570BKrhXf','9RsQKhu','24096171yPgvtW','989639NKZfmX','30bSWOJK','5433908anCPQx','217wDYaYt','98328oPSLIP','string','env'];a361_0x5f06=function(){return _0x4e8972;};return a361_0x5f06();}export function getConfigAppCode(){return a361_0x1d75de();}export function getMultiAppConfigs(_0xe7abd3='project'){return a361_0x233701(_0xe7abd3);}export function getTemplateBaseUrl(){return a361_0x110704();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a362_0x447f(){const _0x9bfd23=['number','21kcscih','744474vJCaUT','6677484viFnJG','trim','8UxDmKA','4269942mAUVyB','10VHnXyT','4822110VOrful','4oAJHtN','178AspDhb','5078232rkMfbf','4905605UPRYIF','isFinite','13358PAqPoV','object'];a362_0x447f=function(){return _0x9bfd23;};return a362_0x447f();}function a362_0x149a(_0x46bdf1,_0x627aee){_0x46bdf1=_0x46bdf1-0x68;const _0x447f9d=a362_0x447f();let _0x149a6b=_0x447f9d[_0x46bdf1];return _0x149a6b;}(function(_0x4e578e,_0x543d5b){const _0x2269db=a362_0x149a,_0x5cb326=_0x4e578e();while(!![]){try{const _0x208b7e=parseInt(_0x2269db(0x71))/0x1*(parseInt(_0x2269db(0x6d))/0x2)+-parseInt(_0x2269db(0x69))/0x3+-parseInt(_0x2269db(0x6c))/0x4*(parseInt(_0x2269db(0x6f))/0x5)+parseInt(_0x2269db(0x75))/0x6*(parseInt(_0x2269db(0x74))/0x7)+-parseInt(_0x2269db(0x68))/0x8*(-parseInt(_0x2269db(0x6b))/0x9)+-parseInt(_0x2269db(0x6a))/0xa*(-parseInt(_0x2269db(0x76))/0xb)+parseInt(_0x2269db(0x6e))/0xc;if(_0x208b7e===_0x543d5b)break;else _0x5cb326['push'](_0x5cb326['shift']());}catch(_0x1df05f){_0x5cb326['push'](_0x5cb326['shift']());}}}(a362_0x447f,0xb06fc));function toFiniteNumber(_0x2fbb82){const _0x492631=a362_0x149a;if(typeof _0x2fbb82===_0x492631(0x73)&&Number['isFinite'](_0x2fbb82))return _0x2fbb82;if(typeof _0x2fbb82==='string'){const _0x41a7e7=_0x2fbb82[_0x492631(0x77)]();if(!_0x41a7e7)return undefined;const _0x285bcb=Number(_0x41a7e7);if(Number[_0x492631(0x70)](_0x285bcb))return _0x285bcb;}return undefined;}export function normalizeEntityWithIdResponse(_0x2b85b9){const _0x3f6a44=a362_0x149a,_0x369f65=toFiniteNumber(_0x2b85b9);if(_0x369f65!==undefined)return{'id':_0x369f65,'entity':{'id':_0x369f65}};if(!_0x2b85b9||typeof _0x2b85b9!==_0x3f6a44(0x72))return{'id':undefined,'entity':{}};const _0x28d91d={..._0x2b85b9},_0x2cc7ee=toFiniteNumber(_0x28d91d['id']);return _0x2cc7ee!==undefined&&(_0x28d91d['id']=_0x2cc7ee),{'id':_0x2cc7ee,'entity':_0x28d91d};}
|
package/lib/utils/file-utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x50b5da,_0x261068){const _0x16a2fb=a363_0x3bf5,_0x4d8d41=_0x50b5da();while(!![]){try{const _0x33ef5b=parseInt(_0x16a2fb(0x17b))/0x1+parseInt(_0x16a2fb(0x17d))/0x2+parseInt(_0x16a2fb(0x179))/0x3*(-parseInt(_0x16a2fb(0x178))/0x4)+-parseInt(_0x16a2fb(0x17f))/0x5+parseInt(_0x16a2fb(0x17e))/0x6+-parseInt(_0x16a2fb(0x180))/0x7+-parseInt(_0x16a2fb(0x17a))/0x8;if(_0x33ef5b===_0x261068)break;else _0x4d8d41['push'](_0x4d8d41['shift']());}catch(_0x2ddfc4){_0x4d8d41['push'](_0x4d8d41['shift']());}}}(a363_0x11c6,0x9a81a));import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';function a363_0x3bf5(_0x4fa60d,_0x9f2a8a){_0x4fa60d=_0x4fa60d-0x178;const _0x11c6d9=a363_0x11c6();let _0x3bf552=_0x11c6d9[_0x4fa60d];return _0x3bf552;}import{join}from'node:path';export async function copyDir(_0x238e16,_0x49ed61){const _0x1413f7=a363_0x3bf5,_0x3d6d8a=statSync(_0x238e16);if(_0x3d6d8a[_0x1413f7(0x17c)]()){!existsSync(_0x49ed61)&&mkdirSync(_0x49ed61,{'recursive':!![]});const _0x24d875=readdirSync(_0x238e16);for(const _0x39f2af of _0x24d875){await copyDir(join(_0x238e16,_0x39f2af),join(_0x49ed61,_0x39f2af));}}else copyFileSync(_0x238e16,_0x49ed61);}export function ensureDir(_0x11b9b2){!existsSync(_0x11b9b2)&&mkdirSync(_0x11b9b2,{'recursive':!![]});}export function pathExists(_0x20ddea){return existsSync(_0x20ddea);}function a363_0x11c6(){const _0x34f019=['375ViwcAG','6647712BNOgwK','905706eIfZLd','isDirectory','2497070MLuBHp','5904990MxzhCD','5336350LHnVIG','2229073wzBTPb','9244crRLlu'];a363_0x11c6=function(){return _0x34f019;};return a363_0x11c6();}
|
package/lib/utils/guides-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a364_0x227903=a364_0x407a;(function(_0x594ece,_0x583d3a){const _0x9ffe7a=a364_0x407a,_0x242c48=_0x594ece();while(!![]){try{const _0x1e69a3=parseInt(_0x9ffe7a(0xd9))/0x1+-parseInt(_0x9ffe7a(0xd3))/0x2*(parseInt(_0x9ffe7a(0xe7))/0x3)+parseInt(_0x9ffe7a(0xe9))/0x4*(parseInt(_0x9ffe7a(0xca))/0x5)+-parseInt(_0x9ffe7a(0xce))/0x6+parseInt(_0x9ffe7a(0xd1))/0x7*(-parseInt(_0x9ffe7a(0xe8))/0x8)+parseInt(_0x9ffe7a(0xd7))/0x9*(-parseInt(_0x9ffe7a(0xcd))/0xa)+parseInt(_0x9ffe7a(0xc8))/0xb;if(_0x1e69a3===_0x583d3a)break;else _0x242c48['push'](_0x242c48['shift']());}catch(_0x4adaf6){_0x242c48['push'](_0x242c48['shift']());}}}(a364_0x42fa,0x7ace1));function a364_0x42fa(){const _0x2b4fa5=['3rqEiGV','860376LzSZjl','1801844bDxtqJ','statusText','.lovrabet/skill/guides','17880423dcoIAS','entries','10NyTUGL','map','extendContent','80yyvmYx','2766150uAEmcV','content','\x0a\x0a>更新时间:','7yDhnEc','CDN\x20request\x20failed:\x20','1513026JyIJPU','guides','title','lastUpdated','959499IOBPWW','object','154567iIxuSw','status','length','trimEnd','.lovrabet','replace','json','CDN\x20returned\x20invalid\x20data','skillTemplate','utf-8','cache','/skills/guides.json','keys','join'];a364_0x42fa=function(){return _0x2b4fa5;};return a364_0x42fa();}import{mkdirSync,writeFileSync}from'node:fs';import{dirname,join}from'node:path';function a364_0x407a(_0x10d356,_0x590340){_0x10d356=_0x10d356-0xc6;const _0x42fa51=a364_0x42fa();let _0x407a16=_0x42fa51[_0x10d356];return _0x407a16;}import{homedir}from'node:os';import{getTemplateBaseUrl}from'../utils/config.js';function getGuidesCdnUrl(){const _0x3286b0=a364_0x407a,_0x26bc7f=getTemplateBaseUrl();return _0x26bc7f+_0x3286b0(0xe4);}const CACHE_DIR=join(homedir(),a364_0x227903(0xdd),a364_0x227903(0xe3));export async function fetchGuidesFromCDN(){const _0x17eb11=a364_0x227903,_0x1b0bf0=getGuidesCdnUrl(),_0x102e52=await fetch(_0x1b0bf0,{'headers':{'Accept':'application/json'}});if(!_0x102e52['ok'])throw new Error(_0x17eb11(0xd2)+_0x102e52[_0x17eb11(0xda)]+'\x20'+_0x102e52[_0x17eb11(0xc6)]);const _0x3148cf=await _0x102e52[_0x17eb11(0xdf)]();if(!_0x3148cf[_0x17eb11(0xd4)]||typeof _0x3148cf[_0x17eb11(0xd4)]!==_0x17eb11(0xd8))throw new Error(_0x17eb11(0xe0));return _0x3148cf;}export function writeGuidesToProject(_0x363078,_0x531a27,_0x8ea37d=a364_0x227903(0xc7),_0x1a2d5d){const _0x55d9a3=a364_0x227903,_0x1aa04a=join(_0x531a27,_0x8ea37d);mkdirSync(_0x1aa04a,{'recursive':!![]});for(const [_0x48b471,_0x4464de]of Object[_0x55d9a3(0xc9)](_0x363078['guides'])){let _0x879330=_0x4464de[_0x55d9a3(0xcf)];_0x4464de[_0x55d9a3(0xd6)]&&(_0x879330=appendUpdateTime(_0x879330,_0x4464de['lastUpdated'])),writeFileSync(join(_0x1aa04a,_0x48b471+'.md'),_0x879330,_0x55d9a3(0xe2));}}export function appendUpdateTime(_0x3f14fd,_0x1c31d1){const _0x469db0=a364_0x227903;return _0x3f14fd=_0x3f14fd[_0x469db0(0xde)](/\n*>更新时间:.*$/m,''),_0x3f14fd[_0x469db0(0xdc)]()+(_0x469db0(0xd0)+_0x1c31d1);}export function getSkillTemplate(_0x42836f){const _0x276113=a364_0x227903;return _0x42836f[_0x276113(0xe1)]?.[_0x276113(0xcf)]||'';}export function appendExtendContents(_0x30e1e9,_0x30c8a2,_0x445408){const _0x2e34cc=a364_0x227903,_0x3a6f34=[];for(const [,_0x12dcd9]of Object['entries'](_0x30c8a2['guides'])){_0x12dcd9[_0x2e34cc(0xcc)]&&_0x3a6f34['push'](_0x12dcd9['extendContent'][_0x2e34cc(0xdc)]());}if(_0x3a6f34[_0x2e34cc(0xdb)]===0x0)return _0x30e1e9;return _0x30e1e9[_0x2e34cc(0xdc)]()+'\x0a\x0a'+_0x3a6f34[_0x2e34cc(0xe6)]('\x0a\x0a')+'\x0a';}export function writeSkillFile(_0x3da0fc,_0x321bde,_0x3a05fc){const _0x5a3f03=a364_0x227903,_0x2ae5a3=getSkillTemplate(_0x3da0fc);if(!_0x2ae5a3)throw new Error('CDN\x20data\x20is\x20missing\x20skillTemplate');const _0x3ceb08=dirname(_0x321bde);mkdirSync(_0x3ceb08,{'recursive':!![]});let _0x91279=_0x2ae5a3['replace'](/\{\{IDE_NAME\}\}/g,_0x3a05fc);_0x91279=appendExtendContents(_0x91279,_0x3da0fc),_0x3da0fc[_0x5a3f03(0xe1)][_0x5a3f03(0xd6)]&&(_0x91279=appendUpdateTime(_0x91279,_0x3da0fc[_0x5a3f03(0xe1)][_0x5a3f03(0xd6)])),writeFileSync(_0x321bde,_0x91279,_0x5a3f03(0xe2));}export async function installGuides(_0x192d31){const _0x1523cf=a364_0x227903,_0xa51a62=await fetchGuidesFromCDN();return writeGuidesToProject(_0xa51a62,_0x192d31),Object[_0x1523cf(0xe5)](_0xa51a62[_0x1523cf(0xd4)])[_0x1523cf(0xdb)];}export function getGuidesSummary(_0x5b65f7){const _0x22bd30=a364_0x227903;return Object[_0x22bd30(0xc9)](_0x5b65f7[_0x22bd30(0xd4)])[_0x22bd30(0xcb)](([_0x74ac2f,_0x3b37eb])=>({'key':_0x74ac2f,'title':_0x3b37eb[_0x22bd30(0xd5)],'path':_0x3b37eb['path']}));}
|
package/lib/utils/http-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a365_0x1c04(){const _0x4bd66d=['229976JGWgeg','application/json','statusText','content-type','name','ECONNRESET','12450956kUkXOP','TypeError','log','signal','Request\x20failed','36UdjpsP','text','fetch','includes','headers','1331620keaIHg','status','ENOTFOUND','247220TctVpv','45zvdvYw','867470umiJpr','1060542KIXhxB','url','\x20in\x20','32880402HJSliH','get'];a365_0x1c04=function(){return _0x4bd66d;};return a365_0x1c04();}(function(_0x24b6d7,_0x3184db){const _0x258274=a365_0x5f56,_0x557ece=_0x24b6d7();while(!![]){try{const _0x3a3319=-parseInt(_0x258274(0x179))/0x1+-parseInt(_0x258274(0x17e))/0x2+parseInt(_0x258274(0x174))/0x3*(-parseInt(_0x258274(0x17c))/0x4)+-parseInt(_0x258274(0x17d))/0x5*(-parseInt(_0x258274(0x17f))/0x6)+-parseInt(_0x258274(0x18a))/0x7+parseInt(_0x258274(0x184))/0x8+parseInt(_0x258274(0x182))/0x9;if(_0x3a3319===_0x3184db)break;else _0x557ece['push'](_0x557ece['shift']());}catch(_0x54e16a){_0x557ece['push'](_0x557ece['shift']());}}}(a365_0x1c04,0xf104f));export async function httpRequest(_0x20ad4b,_0x5962cf={}){const _0x549729=a365_0x5f56,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x5962cf;let _0x591813=null;for(let _0x592d26=0x0;_0x592d26<=retries;_0x592d26++){try{const _0x304889=new AbortController(),_0x1be526=setTimeout(()=>_0x304889['abort'](),timeout),_0xb35460=await fetch(_0x20ad4b,{'headers':headers,'signal':_0x304889[_0x549729(0x18d)]});clearTimeout(_0x1be526);let _0xaa57d9;const _0x1121f2=_0xb35460[_0x549729(0x178)][_0x549729(0x183)](_0x549729(0x187));return _0x1121f2?.[_0x549729(0x177)](_0x549729(0x185))?_0xaa57d9=await _0xb35460['json']():_0xaa57d9=await _0xb35460[_0x549729(0x175)](),{'ok':_0xb35460['ok'],'status':_0xb35460[_0x549729(0x17a)],'statusText':_0xb35460[_0x549729(0x186)],'data':_0xaa57d9,'headers':_0xb35460[_0x549729(0x178)],'url':_0xb35460[_0x549729(0x180)],'text':()=>_0xb35460[_0x549729(0x175)]()};}catch(_0x380501){_0x591813=_0x380501 instanceof Error?_0x380501:new Error(String(_0x380501));if(_0x592d26===retries)break;if(shouldRetry(_0x380501)){console[_0x549729(0x18c)]('*\x20Request\x20failed;\x20retry\x20'+(_0x592d26+0x1)+_0x549729(0x181)+retryDelay+'ms...'),await sleep(retryDelay);continue;}else break;}}throw _0x591813||new Error(_0x549729(0x173));}function a365_0x5f56(_0x6d343e,_0x44c719){_0x6d343e=_0x6d343e-0x173;const _0x1c0422=a365_0x1c04();let _0x5f56e2=_0x1c0422[_0x6d343e];return _0x5f56e2;}function shouldRetry(_0x4b4829){const _0x28a69c=a365_0x5f56;if(_0x4b4829 instanceof Error){if(_0x4b4829[_0x28a69c(0x188)]==='AbortError')return![];if(_0x4b4829[_0x28a69c(0x188)]===_0x28a69c(0x18b)&&_0x4b4829['message'][_0x28a69c(0x177)](_0x28a69c(0x176)))return!![];if(_0x4b4829['message'][_0x28a69c(0x177)](_0x28a69c(0x189)))return!![];if(_0x4b4829['message'][_0x28a69c(0x177)](_0x28a69c(0x17b)))return![];}return![];}function sleep(_0x24f6d1){return new Promise(_0x59c8c0=>setTimeout(_0x59c8c0,_0x24f6d1));}export function validateUrl(_0x286981){try{return new URL(_0x286981),!![];}catch{return![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x6faa3c,_0x3a2449){const _0x1dac8b=a366_0x5155,_0x411c0a=_0x6faa3c();while(!![]){try{const _0x98e378=parseInt(_0x1dac8b(0xc3))/0x1*(parseInt(_0x1dac8b(0xbf))/0x2)+parseInt(_0x1dac8b(0xc4))/0x3*(parseInt(_0x1dac8b(0xb9))/0x4)+-parseInt(_0x1dac8b(0xbe))/0x5+-parseInt(_0x1dac8b(0xc2))/0x6*(-parseInt(_0x1dac8b(0xba))/0x7)+-parseInt(_0x1dac8b(0xbc))/0x8+parseInt(_0x1dac8b(0xc0))/0x9*(parseInt(_0x1dac8b(0xbd))/0xa)+-parseInt(_0x1dac8b(0xc8))/0xb;if(_0x98e378===_0x3a2449)break;else _0x411c0a['push'](_0x411c0a['shift']());}catch(_0x5e5a98){_0x411c0a['push'](_0x411c0a['shift']());}}}(a366_0x4be2,0x93979));function a366_0x4be2(){const _0xe5a9b7=['3066075rSSaSr','isTTY','1175562BPuakd','154823oSBCZr','1940226DzHlGy','nonInteractive','stdin','true','143594gljQmT','setRawMode','4xcsbBD','14xemSMg','isRaw','7560808pmEjOF','20UUCyvE','2334500acVCis','4VMfZZT'];a366_0x4be2=function(){return _0xe5a9b7;};return a366_0x4be2();}function a366_0x5155(_0x50fed0,_0x1d46f6){_0x50fed0=_0x50fed0-0xb8;const _0x4be2d6=a366_0x4be2();let _0x51557b=_0x4be2d6[_0x50fed0];return _0x51557b;}function env(_0x26f6db){return process.env[`RABETBASE_${_0x26f6db}`]||process.env[`LOVRABET_${_0x26f6db}`]||undefined;}export function isNonInteractive(_0x2d0b74){const _0x571eb3=a366_0x5155;return!!(_0x2d0b74[_0x571eb3(0xc5)]||_0x2d0b74['ci']||env('CI')===_0x571eb3(0xc7)||process.env.CI===_0x571eb3(0xc7)||!process['stdout'][_0x571eb3(0xc1)]||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x59b06f=a366_0x5155;if(!process[_0x59b06f(0xc6)][_0x59b06f(0xc1)])return![];try{const _0x51eb30=process[_0x59b06f(0xc6)][_0x59b06f(0xbb)];return process[_0x59b06f(0xc6)][_0x59b06f(0xb8)](!![]),process[_0x59b06f(0xc6)][_0x59b06f(0xb8)](_0x51eb30??![]),!![];}catch{return![];}}
|
package/lib/utils/logger.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a367_0x1f6da6=a367_0x186f;(function(_0x3da290,_0x3fd348){const _0x2a7eea=a367_0x186f,_0x1a1c09=_0x3da290();while(!![]){try{const _0x1a7861=parseInt(_0x2a7eea(0x1fa))/0x1+-parseInt(_0x2a7eea(0x1ec))/0x2+-parseInt(_0x2a7eea(0x1dc))/0x3*(parseInt(_0x2a7eea(0x1f5))/0x4)+parseInt(_0x2a7eea(0x1f1))/0x5+parseInt(_0x2a7eea(0x1f9))/0x6*(parseInt(_0x2a7eea(0x202))/0x7)+parseInt(_0x2a7eea(0x1f4))/0x8+-parseInt(_0x2a7eea(0x200))/0x9;if(_0x1a7861===_0x3fd348)break;else _0x1a1c09['push'](_0x1a1c09['shift']());}catch(_0x5dd8e9){_0x1a1c09['push'](_0x1a1c09['shift']());}}}(a367_0x304e,0x8688f));import a367_0x5264fb from'winston';import a367_0x3d4598 from'node:fs';function a367_0x304e(){const _0x3a9241=['split','map','logFilePath','errors','combine','yellow','transports','initWinstonLogger','Starting:\x20','join','utf8','existsSync','clearLogs','logTask','readFileSync','54YIiekU','blue','setRawCommand','mkdirSync','writeFileSync','printf','timestamp','error','format','now','stringify','createLogger','warn','.lovrabet.log','readLogs','Failed\x20to\x20clear\x20logs:','854380YKjYEU','green','level','Failed\x20to\x20read\x20logs:','success','3753540NfTwob','addColors','currentRawCommand','3667704vxwjtY','29224AbNnlc','winstonLogger','red','trim','892158PYnZTX','462505pkAyDx','parse','info','command','getWinstonInstance','details','6395544ucqYbF','duration','7BiFDdF','toISOString','unknown','clear','setLogPath'];a367_0x304e=function(){return _0x3a9241;};return a367_0x304e();}function a367_0x186f(_0x50c00a,_0x20710b){_0x50c00a=_0x50c00a-0x1d3;const _0x304e46=a367_0x304e();let _0x186fef=_0x304e46[_0x50c00a];return _0x186fef;}import a367_0x41d109 from'node:path';class Logger{[a367_0x1f6da6(0x1f6)];[a367_0x1f6da6(0x209)];['currentRawCommand']='';constructor(){const _0x19ebeb=a367_0x1f6da6;this[_0x19ebeb(0x209)]='';}[a367_0x1f6da6(0x1de)](_0x466fcd){this['currentRawCommand']=_0x466fcd;}[a367_0x1f6da6(0x1d4)](){const _0x5eb52a=a367_0x1f6da6,_0x4275f9=a367_0x41d109['dirname'](this['logFilePath']);!a367_0x3d4598['existsSync'](_0x4275f9)&&a367_0x3d4598[_0x5eb52a(0x1df)](_0x4275f9,{'recursive':!![]});const _0x54b950=a367_0x5264fb[_0x5eb52a(0x1e4)][_0x5eb52a(0x20b)](a367_0x5264fb['format'][_0x5eb52a(0x1e2)](),a367_0x5264fb[_0x5eb52a(0x1e4)][_0x5eb52a(0x20a)]({'stack':!![]}),a367_0x5264fb[_0x5eb52a(0x1e4)][_0x5eb52a(0x1e1)](_0x339e95=>{const _0x2f2adb=_0x5eb52a,_0xf121b1={'timestamp':_0x339e95[_0x2f2adb(0x1e2)]||new Date()[_0x2f2adb(0x203)](),'level':_0x339e95[_0x2f2adb(0x1ee)]||_0x2f2adb(0x1fc),'command':_0x339e95[_0x2f2adb(0x1fd)]||_0x2f2adb(0x204),'rawCommand':_0x339e95['rawCommand']||this[_0x2f2adb(0x1f3)]||undefined,'message':_0x339e95['message']||'','duration':_0x339e95[_0x2f2adb(0x201)]||undefined,'details':_0x339e95[_0x2f2adb(0x1ff)]||undefined};return JSON[_0x2f2adb(0x1e6)](_0xf121b1);}));this[_0x5eb52a(0x1f6)]=a367_0x5264fb[_0x5eb52a(0x1e7)]({'level':_0x5eb52a(0x1fc),'format':_0x54b950,'transports':[new a367_0x5264fb[(_0x5eb52a(0x1d3))]['File']({'filename':this[_0x5eb52a(0x209)],'level':_0x5eb52a(0x1fc)})],'silent':![]}),a367_0x5264fb[_0x5eb52a(0x1f2)]({'success':_0x5eb52a(0x1ed),'error':_0x5eb52a(0x1f7),'warn':_0x5eb52a(0x20c),'info':_0x5eb52a(0x1dd)});}[a367_0x1f6da6(0x206)](_0x2e09ae){const _0x3ba5d1=a367_0x1f6da6;this['logFilePath']=a367_0x41d109[_0x3ba5d1(0x1d6)](_0x2e09ae,_0x3ba5d1(0x1e9)),this[_0x3ba5d1(0x1f6)]&&this[_0x3ba5d1(0x1f6)][_0x3ba5d1(0x205)](),this[_0x3ba5d1(0x1d4)]();}['info'](_0x17f959,_0x377c83,_0x3e9484){const _0x659d81=a367_0x1f6da6;if(!this[_0x659d81(0x209)]||!this['winstonLogger'])return;this[_0x659d81(0x1f6)][_0x659d81(0x1fc)](_0x377c83,{'command':_0x17f959,'details':_0x3e9484});}[a367_0x1f6da6(0x1f0)](_0x49cf21,_0x456d90,_0x22ddb1,_0x1338a4){const _0x585cb7=a367_0x1f6da6;if(!this[_0x585cb7(0x209)]||!this[_0x585cb7(0x1f6)])return;this[_0x585cb7(0x1f6)]['log'](_0x585cb7(0x1fc),_0x456d90,{'level':'success','command':_0x49cf21,'duration':_0x22ddb1,'details':_0x1338a4});}[a367_0x1f6da6(0x1e3)](_0x51f81c,_0x11508f,_0x194255){const _0x2a337e=a367_0x1f6da6;if(!this[_0x2a337e(0x209)]||!this[_0x2a337e(0x1f6)])return;this['winstonLogger'][_0x2a337e(0x1e3)](_0x11508f,{'command':_0x51f81c,'details':_0x194255});}[a367_0x1f6da6(0x1e8)](_0x3af2ef,_0x5f12dd,_0x552498){const _0x537bc6=a367_0x1f6da6;if(!this[_0x537bc6(0x209)]||!this[_0x537bc6(0x1f6)])return;this[_0x537bc6(0x1f6)][_0x537bc6(0x1e8)](_0x5f12dd,{'command':_0x3af2ef,'details':_0x552498});}async[a367_0x1f6da6(0x1da)](_0x137ad4,_0x16189a,_0x4f7ddf){const _0x52b664=a367_0x1f6da6,_0x5dac0b=Date['now']();this[_0x52b664(0x1fc)](_0x137ad4,_0x52b664(0x1d5)+_0x16189a);try{const _0x42d362=await _0x4f7ddf(),_0x578606=Date[_0x52b664(0x1e5)]()-_0x5dac0b;return this[_0x52b664(0x1f0)](_0x137ad4,'Completed:\x20'+_0x16189a,_0x578606),_0x42d362;}catch(_0x47d968){const _0x2dd707=Date[_0x52b664(0x1e5)]()-_0x5dac0b;this[_0x52b664(0x1e3)](_0x137ad4,'Failed:\x20'+_0x16189a,{'error':_0x47d968 instanceof Error?_0x47d968['message']:String(_0x47d968),'duration':_0x2dd707});throw _0x47d968;}}[a367_0x1f6da6(0x1ea)](){const _0x5408b6=a367_0x1f6da6;try{if(!a367_0x3d4598[_0x5408b6(0x1d8)](this['logFilePath']))return[];const _0x336a92=a367_0x3d4598[_0x5408b6(0x1db)](this[_0x5408b6(0x209)],_0x5408b6(0x1d7));return _0x336a92[_0x5408b6(0x207)]('\x0a')['filter'](_0x56dcb6=>_0x56dcb6[_0x5408b6(0x1f8)]())[_0x5408b6(0x208)](_0x561a1a=>JSON[_0x5408b6(0x1fb)](_0x561a1a));}catch(_0x3dd76c){return console[_0x5408b6(0x1e8)](_0x5408b6(0x1ef),_0x3dd76c),[];}}[a367_0x1f6da6(0x1d9)](){const _0x198de9=a367_0x1f6da6;try{a367_0x3d4598[_0x198de9(0x1d8)](this[_0x198de9(0x209)])&&a367_0x3d4598[_0x198de9(0x1e0)](this['logFilePath'],'',_0x198de9(0x1d7));}catch(_0x1cb78a){console[_0x198de9(0x1e8)](_0x198de9(0x1eb),_0x1cb78a);}}[a367_0x1f6da6(0x1fe)](){const _0x3faace=a367_0x1f6da6;return this[_0x3faace(0x1f6)];}}export const logger=new Logger();
|
package/lib/utils/params.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a368_0x3bcd(_0x31e593,_0x207d35){_0x31e593=_0x31e593-0x14f;const _0x301950=a368_0x3019();let _0x3bcd67=_0x301950[_0x31e593];return _0x3bcd67;}function a368_0x3019(){const _0x503ef5=['5566602PkwOVk','14aqPigd','5OtvgNl','parse','1336572eChnvX','30lmvROc','3700692htMMgy','5987993eWbyAY','125zJUihg','--params\x20must\x20be\x20a\x20JSON\x20object','65svHyMM','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','validation','14588UeWvtw','3twKOQD','Invalid\x20JSON\x20for\x20--params:\x20','82125mqeKLo','isArray','214888QOqFQh'];a368_0x3019=function(){return _0x503ef5;};return a368_0x3019();}(function(_0x290a1c,_0x3bf91c){const _0xdd655d=a368_0x3bcd,_0x34c8e4=_0x290a1c();while(!![]){try{const _0x1a7e29=parseInt(_0xdd655d(0x14f))/0x1*(-parseInt(_0xdd655d(0x154))/0x2)+-parseInt(_0xdd655d(0x155))/0x3*(-parseInt(_0xdd655d(0x160))/0x4)+-parseInt(_0xdd655d(0x15c))/0x5*(-parseInt(_0xdd655d(0x15a))/0x6)+-parseInt(_0xdd655d(0x15b))/0x7*(parseInt(_0xdd655d(0x159))/0x8)+parseInt(_0xdd655d(0x157))/0x9*(-parseInt(_0xdd655d(0x15f))/0xa)+parseInt(_0xdd655d(0x161))/0xb+-parseInt(_0xdd655d(0x15e))/0xc*(parseInt(_0xdd655d(0x151))/0xd);if(_0x1a7e29===_0x3bf91c)break;else _0x34c8e4['push'](_0x34c8e4['shift']());}catch(_0x76fbdc){_0x34c8e4['push'](_0x34c8e4['shift']());}}}(a368_0x3019,0xceebf));import{CliErrors}from'../errors.js';export function parseJsonParams(_0x1fbd02){const _0x1d1d0d=a368_0x3bcd;if(!_0x1fbd02)return undefined;let _0x7775dd;try{_0x7775dd=JSON[_0x1d1d0d(0x15d)](_0x1fbd02);}catch{throw CliErrors[_0x1d1d0d(0x153)](_0x1d1d0d(0x156)+_0x1fbd02);}if(!_0x7775dd||typeof _0x7775dd!=='object'||Array[_0x1d1d0d(0x158)](_0x7775dd))throw CliErrors[_0x1d1d0d(0x153)](_0x1d1d0d(0x150),_0x1d1d0d(0x152));return _0x7775dd;}
|
package/lib/utils/platform.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a369_0x586c(_0x4aeab1,_0x2eb18){_0x4aeab1=_0x4aeab1-0x1c7;const _0x5096a1=a369_0x5096();let _0x586c42=_0x5096a1[_0x4aeab1];return _0x586c42;}const a369_0x4b48ca=a369_0x586c;(function(_0xfd3fd4,_0x552f9c){const _0x4d9e30=a369_0x586c,_0x422ee0=_0xfd3fd4();while(!![]){try{const _0x1a6577=parseInt(_0x4d9e30(0x1d1))/0x1*(-parseInt(_0x4d9e30(0x1c7))/0x2)+parseInt(_0x4d9e30(0x1cb))/0x3+-parseInt(_0x4d9e30(0x1cc))/0x4*(-parseInt(_0x4d9e30(0x1ce))/0x5)+parseInt(_0x4d9e30(0x1d0))/0x6*(-parseInt(_0x4d9e30(0x1d2))/0x7)+-parseInt(_0x4d9e30(0x1cf))/0x8*(-parseInt(_0x4d9e30(0x1d3))/0x9)+parseInt(_0x4d9e30(0x1ca))/0xa+parseInt(_0x4d9e30(0x1c9))/0xb;if(_0x1a6577===_0x552f9c)break;else _0x422ee0['push'](_0x422ee0['shift']());}catch(_0x286281){_0x422ee0['push'](_0x422ee0['shift']());}}}(a369_0x5096,0xd15d5));export const isWindows=process[a369_0x4b48ca(0x1c8)]==='win32';function a369_0x5096(){const _0x34c44d=['204iehYJA','1311449NmhiCI','84217LRbhEG','756873CzUzPz','2ffKIlF','platform','2308064cEITNT','11555580iYAwrI','909564OzsUul','108LJMJHf','.cmd','106130LFuSsc','32dgpJBS'];a369_0x5096=function(){return _0x34c44d;};return a369_0x5096();}export function resolveNpmBin(_0x383c8c){const _0x479c0f=a369_0x4b48ca;return isWindows?_0x383c8c+_0x479c0f(0x1cd):_0x383c8c;}
|
package/lib/utils/sleep.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export function sleep(
|
|
1
|
+
export function sleep(_0x588db7){return new Promise(_0x29b30a=>setTimeout(_0x29b30a,_0x588db7));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a371_0x495e86=a371_0x25db;(function(_0x5f42cd,_0x680e6){const _0x430583=a371_0x25db,_0x452205=_0x5f42cd();while(!![]){try{const _0x30a074=-parseInt(_0x430583(0x1d2))/0x1+-parseInt(_0x430583(0x1c2))/0x2*(parseInt(_0x430583(0x1cd))/0x3)+parseInt(_0x430583(0x1ad))/0x4+-parseInt(_0x430583(0x19b))/0x5*(-parseInt(_0x430583(0x1c8))/0x6)+parseInt(_0x430583(0x1d0))/0x7+-parseInt(_0x430583(0x1be))/0x8+-parseInt(_0x430583(0x1c6))/0x9*(parseInt(_0x430583(0x1a9))/0xa);if(_0x30a074===_0x680e6)break;else _0x452205['push'](_0x452205['shift']());}catch(_0x5770ed){_0x452205['push'](_0x452205['shift']());}}}(a371_0x2575,0x8e456));function a371_0x2575(){const _0xe4ed6e=['info','readdir','alias:\x20\x22','replaceApiContent','isFile','writeFile','processFile','datasetCode:\x20\x22','Starting\x20template\x20content\x20replacement','copyFile','push','toComponentName','390sqWnca','YourModel','.json','getDate','4583668ckXenV','utf8','name','promises','getMinutes','.tpl','sdk-config','endsWith','message','alias','datasetCode','.css','tableName:\x20\x22','isDirectory','api','extname','mkdir','4561552GHQwvf','getFullYear','.jsx','Template\x20content\x20replacement\x20failed','5596lGayVf','readFile','.js','charAt','114741MzDzqS','.md','1577436anAStk','map','formatLocalTimestamp','split','processDirectory','339XKvEHf','.ts','getMonth','7979090duROmh','replace','845278mAzlQy','toDisplayTitle','getSeconds','toISOString','toUpperCase','replaceContent','pop','join','\x20},','template','padStart','getHours','includes','now','.tsx','Template\x20content\x20replacement\x20completed','slice','pad','10VmdFaU','toLowerCase'];a371_0x2575=function(){return _0xe4ed6e;};return a371_0x2575();}function a371_0x25db(_0x362079,_0x3fe826){_0x362079=_0x362079-0x19b;const _0x2575ba=a371_0x2575();let _0x25dbe4=_0x2575ba[_0x362079];return _0x25dbe4;}import a371_0x4c9a00 from'node:fs';import a371_0x5df76e from'node:path';import{logger}from'../utils/logger.js';import{getCliVersion}from'../utils/version.js';const CLI_VERSION=getCliVersion();export class TemplateReplacer{static[a371_0x495e86(0x1e3)](_0x14c712){const _0x3514e6=a371_0x495e86;return String(_0x14c712)[_0x3514e6(0x1dc)](0x2,'0');}static['formatLocalTimestamp'](_0x4ef742){const _0x29eb0e=a371_0x495e86,_0x2d573a=_0x4ef742[_0x29eb0e(0x1bf)](),_0x561bec=this[_0x29eb0e(0x1e3)](_0x4ef742[_0x29eb0e(0x1cf)]()+0x1),_0x114bda=this[_0x29eb0e(0x1e3)](_0x4ef742[_0x29eb0e(0x1ac)]()),_0x405437=this[_0x29eb0e(0x1e3)](_0x4ef742[_0x29eb0e(0x1dd)]()),_0x38a733=this[_0x29eb0e(0x1e3)](_0x4ef742[_0x29eb0e(0x1b1)]()),_0x25bed1=this[_0x29eb0e(0x1e3)](_0x4ef742[_0x29eb0e(0x1d4)]());return{'createdAt':_0x2d573a+'-'+_0x561bec+'-'+_0x114bda+'\x20'+_0x405437+':'+_0x38a733+':'+_0x25bed1,'createdDate':_0x2d573a+'-'+_0x561bec+'-'+_0x114bda,'createdTime':_0x405437+':'+_0x38a733+':'+_0x25bed1};}static[a371_0x495e86(0x1a8)](_0x48831c){const _0x58f60c=a371_0x495e86,_0x8cf9c9=_0x48831c[_0x58f60c(0x1cb)]('/')[_0x58f60c(0x1d8)]()||_0x48831c;return _0x8cf9c9[_0x58f60c(0x1cb)]('-')[_0x58f60c(0x1c9)](_0x16f5e9=>_0x16f5e9['charAt'](0x0)[_0x58f60c(0x1d6)]()+_0x16f5e9['slice'](0x1)[_0x58f60c(0x19c)]())[_0x58f60c(0x1d9)]('');}static[a371_0x495e86(0x1d3)](_0x14fe11){const _0x254d69=a371_0x495e86,_0xe927be=_0x14fe11[_0x254d69(0x1cb)]('/')[_0x254d69(0x1d8)]()||_0x14fe11;return _0xe927be[_0x254d69(0x1cb)]('-')[_0x254d69(0x1c9)](_0x65b99a=>_0x65b99a[_0x254d69(0x1c5)](0x0)[_0x254d69(0x1d6)]()+_0x65b99a[_0x254d69(0x1e2)](0x1)['toLowerCase']())['join']('\x20');}static[a371_0x495e86(0x1d7)](_0x1e0973,_0x437a23,_0xd60ed3){const _0x3d2ee7=a371_0x495e86,_0x3c9b31=this[_0x3d2ee7(0x1a8)](_0x437a23),_0x5ca2f4=this[_0x3d2ee7(0x1d3)](_0x437a23),{createdAt:_0x215895,createdDate:_0x539f7f,createdTime:_0x59ec11}=this[_0x3d2ee7(0x1ca)](new Date());let _0x3f9adb=_0x1e0973['replace'](/\{CliVersion\}/g,CLI_VERSION)[_0x3d2ee7(0x1d1)](/\{ComponentName\}/g,_0x3c9b31)['replace'](/\{DisplayTitle\}/g,_0x5ca2f4)[_0x3d2ee7(0x1d1)](/\{PageName\}/g,_0x437a23)['replace'](/\{TemplateName\}/g,_0xd60ed3)['replace'](/\{CreatedAt\}/g,_0x215895)[_0x3d2ee7(0x1d1)](/\{CreatedDate\}/g,_0x539f7f)[_0x3d2ee7(0x1d1)](/\{CreatedTime\}/g,_0x59ec11);return _0x3f9adb;}static[a371_0x495e86(0x1a0)](_0x4abc0a,_0x4486f4,_0x2a79c1,_0x4c3af1,_0x1fe52c,_0x5aaa41,_0x266b80,_0xb9f12b,_0x4f8823){const _0x3e110e=a371_0x495e86,_0x1d0f3b=new Date(),_0x16acaf=_0x1d0f3b[_0x3e110e(0x1d5)](),_0x38ce0f=_0x2a79c1[_0x3e110e(0x1c9)](_0x34c844=>{const _0x175535=_0x3e110e,_0x487e7f=[_0x175535(0x1a4)+_0x34c844[_0x175535(0x1b7)]+'\x22',_0x175535(0x1b9)+_0x34c844['tableName']+'\x22','name:\x20\x22'+_0x34c844[_0x175535(0x1af)]+'\x22'];return _0x34c844[_0x175535(0x1b6)]&&_0x487e7f[_0x175535(0x1a7)](_0x175535(0x19f)+_0x34c844[_0x175535(0x1b6)]+'\x22'),'\x0a\x20\x20\x20\x20{\x20'+_0x487e7f[_0x175535(0x1d9)](',\x20')+_0x175535(0x1da);})['join'](''),_0x491e70=_0x4c3af1||_0x2a79c1[0x0]?.['alias']||_0x3e110e(0x1aa);let _0x13aa9a=_0x4abc0a[_0x3e110e(0x1d1)](/\{AppCode\}/g,_0x4486f4)[_0x3e110e(0x1d1)](/\{ModelConfigs\}/g,_0x38ce0f)['replace'](/\{ExampleModelName\}/g,_0x491e70)[_0x3e110e(0x1d1)](/\{ApiFileName\}/g,_0x1fe52c||_0x3e110e(0x1bb))[_0x3e110e(0x1d1)](/\{ConfigName\}/g,_0x5aaa41||'default')[_0x3e110e(0x1d1)](/\{ClientConfigParam\}/g,_0x266b80||'')[_0x3e110e(0x1d1)](/\{SdkConfigFileName\}/g,_0x4f8823||_0x3e110e(0x1b3))[_0x3e110e(0x1d1)](/\{VarPrefix\}/g,_0xb9f12b||'LOVRABET')['replace'](/\{CreatedAt\}/g,_0x16acaf);return _0x13aa9a;}static async['processTemplate'](_0x403af0,_0x11a6ef,_0x935bd7,_0x9c84fb,_0x23c287=!![]){const _0x223b1a=a371_0x495e86,_0x110b0d=Date[_0x223b1a(0x1df)]();try{_0x23c287&&logger[_0x223b1a(0x19d)]('template',_0x223b1a(0x1a5),{'templatePath':_0x403af0,'targetPath':_0x11a6ef,'pageName':_0x935bd7,'templateName':_0x9c84fb});await a371_0x4c9a00['promises']['mkdir'](_0x11a6ef,{'recursive':!![]}),await this['processDirectory'](_0x403af0,_0x11a6ef,_0x935bd7,_0x9c84fb);if(_0x23c287){const _0x25dda6=Date[_0x223b1a(0x1df)]()-_0x110b0d;logger['success']('template',_0x223b1a(0x1e1),_0x25dda6,{'pageName':_0x935bd7,'templateName':_0x9c84fb});}}catch(_0x4dbbea){if(_0x23c287){const _0x33fb84=Date[_0x223b1a(0x1df)]()-_0x110b0d;logger['error'](_0x223b1a(0x1db),_0x223b1a(0x1c1),{'templatePath':_0x403af0,'targetPath':_0x11a6ef,'pageName':_0x935bd7,'templateName':_0x9c84fb,'error':_0x4dbbea instanceof Error?_0x4dbbea[_0x223b1a(0x1b5)]:String(_0x4dbbea),'duration':_0x33fb84});}throw _0x4dbbea;}}static async['processDirectory'](_0x1d7bae,_0x12fbbb,_0x1544ad,_0x5f2f67){const _0x534250=a371_0x495e86,_0x31d8c9=await a371_0x4c9a00[_0x534250(0x1b0)][_0x534250(0x19e)](_0x1d7bae,{'withFileTypes':!![]});for(const _0x2c8689 of _0x31d8c9){const _0x17b0df=a371_0x5df76e['join'](_0x1d7bae,_0x2c8689[_0x534250(0x1af)]);let _0x2b79bd=a371_0x5df76e['join'](_0x12fbbb,_0x2c8689[_0x534250(0x1af)]);_0x2c8689['name'][_0x534250(0x1b4)]('.tpl')&&(_0x2b79bd=a371_0x5df76e[_0x534250(0x1d9)](_0x12fbbb,_0x2c8689[_0x534250(0x1af)][_0x534250(0x1d1)](/\.tpl$/,'')));if(_0x2c8689[_0x534250(0x1ba)]())await a371_0x4c9a00[_0x534250(0x1b0)][_0x534250(0x1bd)](_0x2b79bd,{'recursive':!![]}),await this[_0x534250(0x1cc)](_0x17b0df,_0x2b79bd,_0x1544ad,_0x5f2f67);else _0x2c8689[_0x534250(0x1a1)]()&&await this['processFile'](_0x17b0df,_0x2b79bd,_0x1544ad,_0x5f2f67);}}static async[a371_0x495e86(0x1a3)](_0x1ccf6e,_0x602df7,_0x3c5d9c,_0x5001c1){const _0x498595=a371_0x495e86,_0x40d439=a371_0x5df76e[_0x498595(0x1bc)](_0x1ccf6e)[_0x498595(0x19c)]();_0x1ccf6e[_0x498595(0x1b4)](_0x498595(0x1b2))&&(_0x602df7=_0x602df7[_0x498595(0x1d1)](/\.tpl$/,''));const _0x4b541e=[_0x498595(0x1e0),_0x498595(0x1ce),_0x498595(0x1c0),_0x498595(0x1c4),_0x498595(0x1ab),_0x498595(0x1c7),_0x498595(0x1b8),'.scss','.tpl'];if(_0x4b541e[_0x498595(0x1de)](_0x40d439)||_0x1ccf6e[_0x498595(0x1b4)]('.tpl')){const _0x275646=await a371_0x4c9a00['promises'][_0x498595(0x1c3)](_0x1ccf6e,_0x498595(0x1ae)),_0x3ed4be=this[_0x498595(0x1d7)](_0x275646,_0x3c5d9c,_0x5001c1);await a371_0x4c9a00[_0x498595(0x1b0)][_0x498595(0x1a2)](_0x602df7,_0x3ed4be,_0x498595(0x1ae));}else await a371_0x4c9a00[_0x498595(0x1b0)][_0x498595(0x1a6)](_0x1ccf6e,_0x602df7);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x9906d7,_0x5d0c55){const _0x1221d3=a372_0x5f45,_0x22e100=_0x9906d7();while(!![]){try{const _0x1f6b85=parseInt(_0x1221d3(0x154))/0x1+-parseInt(_0x1221d3(0x150))/0x2+parseInt(_0x1221d3(0x151))/0x3+-parseInt(_0x1221d3(0x15f))/0x4*(parseInt(_0x1221d3(0x16b))/0x5)+parseInt(_0x1221d3(0x14e))/0x6*(parseInt(_0x1221d3(0x158))/0x7)+parseInt(_0x1221d3(0x15a))/0x8*(parseInt(_0x1221d3(0x160))/0x9)+-parseInt(_0x1221d3(0x169))/0xa*(-parseInt(_0x1221d3(0x156))/0xb);if(_0x1f6b85===_0x5d0c55)break;else _0x22e100['push'](_0x22e100['shift']());}catch(_0x590569){_0x22e100['push'](_0x22e100['shift']());}}}(a372_0x4f5c,0xaf1cc));import{mkdir,readFile,writeFile}from'node:fs/promises';function a372_0x4f5c(){const _0xb2558c=['now','716192EaVorw','\x20available,\x20current\x20','number',',\x20run:\x20','stringify','2328YKLoGh','108kKxqOL','\x20update','utf8','yes','toLowerCase','object','latest','trim','parse','639420FUvIAq','https://www.npmjs.com/package/','9645bMwWeb','true','lastNotifiedAt','5874QPVrca','valid','1486270BXABej','1899657aNXsse','.cache','checkedAt','76934WkeJzh','update-check.json','132XlasCD','stableVersion','224byDIoh'];a372_0x4f5c=function(){return _0xb2558c;};return a372_0x4f5c();}import{homedir}from'node:os';import{dirname,join}from'node:path';import a372_0x228520 from'semver';import{CLI_BIN_NAME,NPM_PACKAGE_NAME}from'../constant/cli.js';import{getCliVersionPolicy}from'../utils/cli-version-policy.js';import{getCliVersion}from'../utils/version.js';function a372_0x5f45(_0x4aa1f3,_0x4f679f){_0x4aa1f3=_0x4aa1f3-0x14e;const _0x4f5c85=a372_0x4f5c();let _0x5f4504=_0x4f5c85[_0x4aa1f3];return _0x5f4504;}const UPDATE_CHECK_TTL_MS=0xc*0x3c*0x3c*0x3e8,UPDATE_NOTICE_TTL_MS=0x18*0x3c*0x3c*0x3e8;function isUpdateNoticeDisabled(){const _0x3a636b=a372_0x5f45,_0x1596f0=process.env.RABETBASE_NO_UPDATE_NOTICE?.['trim']()[_0x3a636b(0x164)]();return _0x1596f0==='1'||_0x1596f0===_0x3a636b(0x16c)||_0x1596f0===_0x3a636b(0x163);}function cacheRoot(){const _0x5e8817=a372_0x5f45;return process.env.XDG_CACHE_HOME||process.env.LOCALAPPDATA||join(homedir(),_0x5e8817(0x152));}export function getUpdateNoticeCachePath(){const _0x315918=a372_0x5f45;return join(cacheRoot(),'rabetbase-cli',_0x315918(0x155));}async function readUpdateNoticeCache(){const _0x2b08cf=a372_0x5f45;try{const _0x27a4bd=await readFile(getUpdateNoticeCachePath(),'utf8'),_0x2d31e1=JSON[_0x2b08cf(0x168)](_0x27a4bd);if(!_0x2d31e1||typeof _0x2d31e1!==_0x2b08cf(0x165))return{};return _0x2d31e1;}catch{return{};}}async function writeUpdateNoticeCache(_0x589b3b){const _0x59b2a8=a372_0x5f45;try{const _0x5bee4c=getUpdateNoticeCachePath();await mkdir(dirname(_0x5bee4c),{'recursive':!![]}),await writeFile(_0x5bee4c,JSON[_0x59b2a8(0x15e)](_0x589b3b,null,0x2)+'\x0a',_0x59b2a8(0x162));}catch{}}function isFreshCheck(_0x4fe7f3,_0x2eed22){const _0x5eadad=a372_0x5f45;return typeof _0x4fe7f3[_0x5eadad(0x153)]===_0x5eadad(0x15c)&&_0x2eed22-_0x4fe7f3[_0x5eadad(0x153)]<UPDATE_CHECK_TTL_MS;}function isRecentlyNotified(_0x42b761,_0x4df51f,_0x8d3509){const _0x5bd094=a372_0x5f45;return _0x42b761['lastNotifiedVersion']===_0x4df51f&&typeof _0x42b761[_0x5bd094(0x16d)]==='number'&&_0x8d3509-_0x42b761[_0x5bd094(0x16d)]<UPDATE_NOTICE_TTL_MS;}export function buildNpmVersionUrl(_0x48551d){const _0x1f94ac=a372_0x5f45;return _0x1f94ac(0x16a)+NPM_PACKAGE_NAME+'/v/'+_0x48551d;}export async function resolveLatestUpdateNotice(){const _0x1c68d5=a372_0x5f45;if(isUpdateNoticeDisabled())return null;try{const _0x254fcf=Date[_0x1c68d5(0x159)](),_0x53ccd0=getCliVersion(),_0x56cbc7=await readUpdateNoticeCache();let _0x4ec2f2=isFreshCheck(_0x56cbc7,_0x254fcf)?_0x56cbc7[_0x1c68d5(0x166)]?.[_0x1c68d5(0x167)]():undefined;if(!_0x4ec2f2&&!isFreshCheck(_0x56cbc7,_0x254fcf)){const _0x5b1524=await getCliVersionPolicy();_0x4ec2f2=_0x5b1524?.[_0x1c68d5(0x157)]?.[_0x1c68d5(0x167)]()||undefined,await writeUpdateNoticeCache({..._0x56cbc7,'checkedAt':_0x254fcf,'latest':_0x4ec2f2,'failed':!_0x4ec2f2});}if(!_0x4ec2f2||!a372_0x228520[_0x1c68d5(0x14f)](_0x53ccd0)||!a372_0x228520[_0x1c68d5(0x14f)](_0x4ec2f2))return null;if(a372_0x228520['gte'](_0x53ccd0,_0x4ec2f2))return null;if(isRecentlyNotified(_0x56cbc7,_0x4ec2f2,_0x254fcf))return null;const _0x296128=CLI_BIN_NAME+_0x1c68d5(0x161);return await writeUpdateNoticeCache({..._0x56cbc7,'checkedAt':isFreshCheck(_0x56cbc7,_0x254fcf)?_0x56cbc7[_0x1c68d5(0x153)]:_0x254fcf,'latest':_0x4ec2f2,'failed':![],'lastNotifiedVersion':_0x4ec2f2,'lastNotifiedAt':_0x254fcf}),{'command':_0x296128,'current':_0x53ccd0,'latest':_0x4ec2f2,'url':buildNpmVersionUrl(_0x4ec2f2),'message':CLI_BIN_NAME+'\x20'+_0x4ec2f2+_0x1c68d5(0x15b)+_0x53ccd0+_0x1c68d5(0x15d)+_0x296128};}catch{return null;}}
|
package/lib/utils/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a373_0x493d(_0x53de9a,_0x4a947a){_0x53de9a=_0x53de9a-0x16d;var _0x23a978=a373_0x23a9();var _0x493d92=_0x23a978[_0x53de9a];return _0x493d92;}(function(_0x58455a,_0x549fc4){var _0x586554=a373_0x493d,_0x1ef51a=_0x58455a();while(!![]){try{var _0x599b86=parseInt(_0x586554(0x176))/0x1+-parseInt(_0x586554(0x177))/0x2*(-parseInt(_0x586554(0x16f))/0x3)+-parseInt(_0x586554(0x16e))/0x4+parseInt(_0x586554(0x16d))/0x5*(parseInt(_0x586554(0x175))/0x6)+parseInt(_0x586554(0x171))/0x7+-parseInt(_0x586554(0x173))/0x8*(-parseInt(_0x586554(0x170))/0x9)+-parseInt(_0x586554(0x172))/0xa*(parseInt(_0x586554(0x174))/0xb);if(_0x599b86===_0x549fc4)break;else _0x1ef51a['push'](_0x1ef51a['shift']());}catch(_0x5f1311){_0x1ef51a['push'](_0x1ef51a['shift']());}}}(a373_0x23a9,0xbb070));import{VERSION}from'../generated/build-info.js';function a373_0x23a9(){var _0x2cfe31=['256956rpmvVU','424058QLXoIt','3611400OWlKve','5484908prfCRq','15zgOMtU','18zHcUfT','6327972ziaxWn','1620100ntCByN','1959976erWWQq','88UGIOkh','6cMhoOs'];a373_0x23a9=function(){return _0x2cfe31;};return a373_0x23a9();}export function getCliVersion(){return VERSION;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a374_0x63d0(_0x17efad,_0x3f0fdb){_0x17efad=_0x17efad-0xe6;var _0x206a24=a374_0x206a();var _0x63d0b=_0x206a24[_0x17efad];return _0x63d0b;}(function(_0x1b8a8b,_0x15ec41){var _0x346339=a374_0x63d0,_0x38d79c=_0x1b8a8b();while(!![]){try{var _0x4168cf=parseInt(_0x346339(0xe9))/0x1*(parseInt(_0x346339(0xe8))/0x2)+parseInt(_0x346339(0xe6))/0x3*(parseInt(_0x346339(0xf0))/0x4)+parseInt(_0x346339(0xee))/0x5+-parseInt(_0x346339(0xe7))/0x6*(parseInt(_0x346339(0xea))/0x7)+parseInt(_0x346339(0xec))/0x8*(parseInt(_0x346339(0xeb))/0x9)+parseInt(_0x346339(0xed))/0xa+-parseInt(_0x346339(0xef))/0xb;if(_0x4168cf===_0x15ec41)break;else _0x38d79c['push'](_0x38d79c['shift']());}catch(_0x87f128){_0x38d79c['push'](_0x38d79c['shift']());}}}(a374_0x206a,0x2e890));import{setActiveCookie,clearActiveCookie}from'../core/api-client.js';function a374_0x206a(){var _0xa56832=['288OutxYM','3322580BMmoFM','64070BETDYA','6072693PsFeJo','4WPRNHm','883446heBJrw','1806372mqAzBb','634SSNois','143ZivUdL','7KAXRgV','89712zoKOrk'];a374_0x206a=function(){return _0xa56832;};return a374_0x206a();}export async function withActiveCookie(_0x5b37d5,_0x5cae1d){setActiveCookie(_0x5b37d5);try{return await _0x5cae1d();}finally{clearActiveCookie();}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2acf49,_0x31bd07){var _0x2b36b2=a375_0x5311,_0x462751=_0x2acf49();while(!![]){try{var _0x3a05c7=-parseInt(_0x2b36b2(0xcf))/0x1+parseInt(_0x2b36b2(0xd4))/0x2+-parseInt(_0x2b36b2(0xd0))/0x3+-parseInt(_0x2b36b2(0xd1))/0x4+parseInt(_0x2b36b2(0xd2))/0x5*(parseInt(_0x2b36b2(0xd5))/0x6)+-parseInt(_0x2b36b2(0xcb))/0x7*(-parseInt(_0x2b36b2(0xcc))/0x8)+-parseInt(_0x2b36b2(0xd3))/0x9*(-parseInt(_0x2b36b2(0xca))/0xa);if(_0x3a05c7===_0x31bd07)break;else _0x462751['push'](_0x462751['shift']());}catch(_0xdc4b9a){_0x462751['push'](_0x462751['shift']());}}}(a375_0x26c8,0x33857));function a375_0x5311(_0x3af837,_0x584843){_0x3af837=_0x3af837-0xca;var _0x26c810=a375_0x26c8();var _0x5311bc=_0x26c810[_0x3af837];return _0x5311bc;}export function writeCliSideChannelLine(_0x5d9af2){var _0x2ad43d=a375_0x5311;process[_0x2ad43d(0xcd)][_0x2ad43d(0xce)](_0x5d9af2+'\x0a');}function a375_0x26c8(){var _0xc36567=['stderr','write','19880fkyfnd','384210jNVykQ','352792vWMrKW','5ScqKpT','13347DbUras','230216DuDxZt','46296jKaOnq','1010NLkjvj','611002vmUqrS','16xgGmij'];a375_0x26c8=function(){return _0xc36567;};return a375_0x26c8();}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lovrabet/rabetbase-cli",
|
|
3
|
-
"version": "2.5.12
|
|
3
|
+
"version": "2.5.12",
|
|
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.12
|
|
3
|
+
version: 2.5.12
|
|
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.12
|
|
6
|
-
"skillVersion": "2.5.12
|
|
5
|
+
"packageVersion": "2.5.12",
|
|
6
|
+
"skillVersion": "2.5.12",
|
|
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": "1afd4d0220a5fa4437e8c70ea451609a1c91d855c850485b8c745f8a5a8e3e09"
|
|
163
163
|
}
|