@lovrabet/rabetbase-cli 2.5.10-beta.3 → 2.5.10-beta.5
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 +4 -4
- 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_0x50cdd6=a358_0x2188;(function(_0x4f8504,_0x210a22){const _0x345769=a358_0x2188,_0x21dc4f=_0x4f8504();while(!![]){try{const _0x2eb77a=-parseInt(_0x345769(0xe7))/0x1*(parseInt(_0x345769(0xea))/0x2)+parseInt(_0x345769(0xd4))/0x3+parseInt(_0x345769(0xd7))/0x4+parseInt(_0x345769(0xed))/0x5*(-parseInt(_0x345769(0xe5))/0x6)+-parseInt(_0x345769(0xe9))/0x7*(-parseInt(_0x345769(0xe8))/0x8)+parseInt(_0x345769(0xe2))/0x9+-parseInt(_0x345769(0xe1))/0xa;if(_0x2eb77a===_0x210a22)break;else _0x21dc4f['push'](_0x21dc4f['shift']());}catch(_0x77bc70){_0x21dc4f['push'](_0x21dc4f['shift']());}}}(a358_0x3f0e,0x54c38));import a358_0x4303e6 from'node:fs';import a358_0x433e90 from'node:path';import a358_0x48a08c from'semver';function a358_0x2188(_0x50631b,_0x577fee){_0x50631b=_0x50631b-0xc7;const _0x3f0ea8=a358_0x3f0e();let _0x21882e=_0x3f0ea8[_0x50631b];return _0x21882e;}import{getCdnConfig}from'../utils/cdn-config.js';function a358_0x3f0e(){const _0x4f0173=['↪\x20SDK\x20update\x20available','\x20\x20\x20Upgrade\x20command:\x20','some','packageName','1368657hPvGUB','@lovrabet/sdk','sdk','313348PMzWZT','log','package.json','utf8','\x20\x20\x20Current\x20version:\x20','coerce','readFileSync','parse','join','1.2.0','3072600dVRBJa','191871QmUjsJ','all','npm\x20install\x20','54LMldkU','needsUpgrade','271403zHpXoz','904EaNeMl','22981fPuyfY','2XiNYzy','existsSync','version','555ChTmtB','dependencies','node_modules','test','minVersion','node','\x20\x20\x20Stable\x20version:\x20','\x1b[33m','devDependencies','stableVersion','\x1b[0m'];a358_0x3f0e=function(){return _0x4f0173;};return a358_0x3f0e();}const FALLBACK_MIN_SDK_VERSION=a358_0x50cdd6(0xe0);function isNonNumericVersion(_0x57e3a4){const _0x2fdd3f=a358_0x50cdd6,_0x520b18=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x520b18[_0x2fdd3f(0xd2)](_0x3eabf8=>_0x3eabf8[_0x2fdd3f(0xc8)](_0x57e3a4));}function getInstalledVersion(_0x31f6ba,_0x307749){const _0x523b12=a358_0x50cdd6;try{const _0x5379a2=a358_0x433e90[_0x523b12(0xdf)](_0x31f6ba,_0x523b12(0xc7),_0x307749,'package.json');if(a358_0x4303e6[_0x523b12(0xeb)](_0x5379a2)){const _0x3f7d57=JSON[_0x523b12(0xde)](a358_0x4303e6[_0x523b12(0xdd)](_0x5379a2,'utf-8'));return _0x3f7d57[_0x523b12(0xec)]||null;}}catch{}return null;}async function getSdkStableVersion(){const _0x30c4d8=a358_0x50cdd6;try{const _0x4c8008=await getCdnConfig();return _0x4c8008?.[_0x30c4d8(0xd6)]?.['node']?.[_0x30c4d8(0xce)]||null;}catch{return null;}}async function getSdkPackageName(){const _0x511b00=a358_0x50cdd6;try{const _0x35e687=await getCdnConfig();return _0x35e687?.[_0x511b00(0xd6)]?.[_0x511b00(0xca)]?.[_0x511b00(0xd3)]||'@lovrabet/sdk';}catch{return _0x511b00(0xd5);}}export async function checkSdkVersion(_0x383b28){const _0x332f2a=a358_0x50cdd6,_0x300696=a358_0x433e90[_0x332f2a(0xdf)](_0x383b28,_0x332f2a(0xd9)),[_0x12e0df,_0x5830a6]=await Promise[_0x332f2a(0xe3)]([getSdkStableVersion(),getSdkPackageName()]),_0x5f580c=_0x12e0df||FALLBACK_MIN_SDK_VERSION;if(!a358_0x4303e6['existsSync'](_0x300696))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x5f580c,'packageName':_0x5830a6,'stableVersion':_0x12e0df};try{const _0x550072=JSON[_0x332f2a(0xde)](a358_0x4303e6['readFileSync'](_0x300696,_0x332f2a(0xda))),_0x2a124f=_0x550072[_0x332f2a(0xee)]||{},_0x30d3c0=_0x550072[_0x332f2a(0xcd)]||{},_0x4af959=_0x2a124f[_0x5830a6]||_0x30d3c0[_0x5830a6];if(!_0x4af959)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x5f580c,'packageName':_0x5830a6,'stableVersion':_0x12e0df};let _0x2cc52c=getInstalledVersion(_0x383b28,_0x5830a6);!_0x2cc52c&&(_0x2cc52c=_0x4af959);if(isNonNumericVersion(_0x4af959))return{'installed':!![],'version':_0x2cc52c,'needsUpgrade':![],'minVersion':_0x5f580c,'packageName':_0x5830a6,'stableVersion':_0x12e0df};const _0x219c20=a358_0x48a08c[_0x332f2a(0xdc)](_0x2cc52c),_0x449ac7=a358_0x48a08c[_0x332f2a(0xdc)](_0x5f580c),_0x45231a=_0x219c20&&_0x449ac7?a358_0x48a08c['lt'](_0x219c20,_0x449ac7):![];return{'installed':!![],'version':_0x2cc52c,'needsUpgrade':_0x45231a,'minVersion':_0x5f580c,'packageName':_0x5830a6,'stableVersion':_0x12e0df};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x5f580c,'packageName':_0x5830a6,'stableVersion':_0x12e0df};}}export function checkSdkVersionSync(_0x434013){const _0x4142c6=a358_0x50cdd6,_0x26e4e1=a358_0x433e90[_0x4142c6(0xdf)](_0x434013,'package.json'),_0x736a12='@lovrabet/sdk';if(!a358_0x4303e6[_0x4142c6(0xeb)](_0x26e4e1))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x736a12,'stableVersion':null};try{const _0x5c31c4=JSON[_0x4142c6(0xde)](a358_0x4303e6[_0x4142c6(0xdd)](_0x26e4e1,_0x4142c6(0xda))),_0x1991e3=_0x5c31c4[_0x4142c6(0xee)]||{},_0x4a62a8=_0x5c31c4['devDependencies']||{},_0x5652cb=_0x1991e3[_0x736a12]||_0x4a62a8[_0x736a12];if(!_0x5652cb)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x736a12,'stableVersion':null};let _0x40f4ae=getInstalledVersion(_0x434013,_0x736a12);!_0x40f4ae&&(_0x40f4ae=_0x5652cb);if(isNonNumericVersion(_0x5652cb))return{'installed':!![],'version':_0x40f4ae,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x736a12,'stableVersion':null};const _0xdad9b0=a358_0x48a08c[_0x4142c6(0xdc)](_0x40f4ae),_0x3c2fe6=_0xdad9b0?a358_0x48a08c['lt'](_0xdad9b0,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0x40f4ae,'needsUpgrade':_0x3c2fe6,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x736a12,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x736a12,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x4a58fb){const _0x3fe28c=a358_0x50cdd6;if(!_0x4a58fb[_0x3fe28c(0xe6)])return;const _0x22b5a4=_0x3fe28c(0xcc),_0x49d13f=_0x3fe28c(0xcf),_0x1e98ec='\x1b[1m',_0x15bb3b=_0x4a58fb[_0x3fe28c(0xd3)]||'@lovrabet/sdk',_0x1ccac2=_0x4a58fb[_0x3fe28c(0xce)]||_0x4a58fb[_0x3fe28c(0xc9)],_0x48f393=_0x3fe28c(0xe4)+_0x15bb3b+'@'+(_0x1ccac2||'latest');console[_0x3fe28c(0xd8)](),console[_0x3fe28c(0xd8)](''+_0x22b5a4+_0x1e98ec+_0x3fe28c(0xd0)+_0x49d13f),console['log'](_0x22b5a4+_0x3fe28c(0xdb)+_0x15bb3b+'@'+_0x4a58fb[_0x3fe28c(0xec)]+_0x49d13f),console[_0x3fe28c(0xd8)](_0x22b5a4+_0x3fe28c(0xcb)+_0x1ccac2+_0x49d13f),console[_0x3fe28c(0xd8)](_0x22b5a4+_0x3fe28c(0xd1)+_0x48f393+_0x49d13f),console['log']();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4d8631,_0x502a7f){const _0x56bbb2=a359_0x5a7a,_0x1f82fa=_0x4d8631();while(!![]){try{const _0x341908=-parseInt(_0x56bbb2(0xc4))/0x1+parseInt(_0x56bbb2(0xdb))/0x2+parseInt(_0x56bbb2(0xd8))/0x3*(-parseInt(_0x56bbb2(0xcf))/0x4)+parseInt(_0x56bbb2(0xc8))/0x5+-parseInt(_0x56bbb2(0xdd))/0x6*(-parseInt(_0x56bbb2(0xbc))/0x7)+parseInt(_0x56bbb2(0xd5))/0x8+-parseInt(_0x56bbb2(0xcd))/0x9*(parseInt(_0x56bbb2(0xd3))/0xa);if(_0x341908===_0x502a7f)break;else _0x1f82fa['push'](_0x1f82fa['shift']());}catch(_0x376fb7){_0x1f82fa['push'](_0x1f82fa['shift']());}}}(a359_0x30db,0x42149));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a359_0x3da284 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(_0x31544b){const _0x3c5f98=a359_0x5a7a,_0x115adb=_0x31544b[_0x3c5f98(0xd1)]||_0x3c5f98(0xe1);return _0x3c5f98(0xc5)+NPM_PACKAGE_NAME+'@'+_0x115adb;}function getCurrentCliVersion(){const _0x4aacd5=a359_0x5a7a;try{const _0xb849da=fileURLToPath(import.meta.url),_0x12443a=resolve(dirname(_0xb849da),_0x4aacd5(0xc3)),_0x260add=resolve(_0x12443a,_0x4aacd5(0xd4)),_0x5c0f04=JSON[_0x4aacd5(0xdc)](readFileSync(_0x260add,'utf-8'));return _0x5c0f04['version']||_0x4aacd5(0xce);}catch{return'1.0.0';}}function a359_0x5a7a(_0x3b42a7,_0x4a5d31){_0x3b42a7=_0x3b42a7-0xbc;const _0x30db0c=a359_0x30db();let _0x5a7a5f=_0x30db0c[_0x3b42a7];return _0x5a7a5f;}export async function checkCliVersion(){const _0x2790a4=a359_0x5a7a,_0x533cd2=getCurrentCliVersion(),_0x6b7cb3=await getCliVersionPolicy(),_0x57a3d0=_0x6b7cb3?.[_0x2790a4(0xd1)]||null,_0x10f256=_0x6b7cb3?.['minimumVersion']||null;let _0x27250d=![],_0x500928=![];const _0x44c052=a359_0x3da284[_0x2790a4(0xc9)](_0x533cd2);if(_0x44c052&&_0x57a3d0)try{const _0x254117=a359_0x3da284[_0x2790a4(0xc9)](_0x57a3d0);if(_0x254117)_0x27250d=a359_0x3da284['lt'](_0x44c052,_0x254117);}catch{}if(_0x44c052&&_0x10f256)try{const _0x30b3f5=a359_0x3da284['coerce'](_0x10f256);if(_0x30b3f5)_0x500928=a359_0x3da284['lt'](_0x44c052,_0x30b3f5);}catch{}return _0x500928&&(_0x27250d=!![]),{'currentVersion':_0x533cd2,'stableVersion':_0x57a3d0,'minimumVersion':_0x10f256,'needsUpgrade':_0x27250d,'belowMinimum':_0x500928,'isPreRelease':![],'upgradeMessage':_0x6b7cb3?.[_0x2790a4(0xe0)],'minimumVersionMessage':_0x6b7cb3?.['minimumVersionMessage']};}function a359_0x30db(){const _0x520312=['parse','1847454LoXHTY','\x20\x20\x20Recommended\x20stable:\x20','\x1b[1m','upgradeMessage','latest','join','\x20\x20\x20Minimum\x20supported:\x20','belowMinimum','7cjDHSY','minimumVersion','\x20\x20\x20Stable\x20version:\x20','needsUpgrade','\x1b[33m','\x1b[31m','Minimum\x20supported:\x20','../..','361088ZyZpgg','npm\x20install\x20-g\x20','\x20\x20\x20Current\x20CLI\x20version:\x20','log','431355UIZtLX','coerce','minimumVersionMessage','Current\x20version:\x20','↪\x20New\x20version\x20available','1117494heCHWu','1.0.0','645008YoErrO','\x20\x20\x20','stableVersion','filter','10jAiFDe','package.json','3612008ljyDwI','\x20\x20\x20Upgrade\x20command:\x20','currentVersion','3jfENzw','\x1b[0m','Upgrade\x20command:\x20','142980yabAvL'];a359_0x30db=function(){return _0x520312;};return a359_0x30db();}export function printCliUpgradeWarning(_0x3af7c2){const _0x2a4963=a359_0x5a7a;if(!_0x3af7c2[_0x2a4963(0xbf)]&&!_0x3af7c2['belowMinimum'])return;const _0x32d611=_0x2a4963(0xc1),_0x2cd473=_0x2a4963(0xc0),_0x652ae4=_0x2a4963(0xd9),_0x474ff7=_0x2a4963(0xdf),_0x3ad6dc=getCliUpgradeCommand(_0x3af7c2);console['log'](),_0x3af7c2['belowMinimum']?(console[_0x2a4963(0xc7)](''+_0x32d611+_0x474ff7+'↪\x20Critical\x20CLI\x20upgrade\x20required'+_0x652ae4),console[_0x2a4963(0xc7)](_0x32d611+_0x2a4963(0xc6)+_0x3af7c2[_0x2a4963(0xd7)]+_0x652ae4),_0x3af7c2['minimumVersion']&&console[_0x2a4963(0xc7)](_0x32d611+_0x2a4963(0xe3)+_0x3af7c2['minimumVersion']+_0x652ae4),_0x3af7c2['stableVersion']&&_0x3af7c2[_0x2a4963(0xd1)]!==_0x3af7c2['minimumVersion']&&console['log'](_0x32d611+_0x2a4963(0xde)+_0x3af7c2[_0x2a4963(0xd1)]+_0x652ae4),_0x3af7c2[_0x2a4963(0xca)]&&console[_0x2a4963(0xc7)](_0x32d611+_0x2a4963(0xd0)+_0x3af7c2['minimumVersionMessage']+_0x652ae4),console[_0x2a4963(0xc7)](_0x32d611+_0x2a4963(0xd6)+_0x3ad6dc+_0x652ae4)):(console[_0x2a4963(0xc7)](''+_0x2cd473+_0x474ff7+_0x2a4963(0xcc)+_0x652ae4),console['log'](_0x2cd473+_0x2a4963(0xc6)+_0x3af7c2[_0x2a4963(0xd7)]+_0x652ae4),console[_0x2a4963(0xc7)](_0x2cd473+_0x2a4963(0xbe)+_0x3af7c2['stableVersion']+_0x652ae4),_0x3af7c2['upgradeMessage']&&console[_0x2a4963(0xc7)](_0x2cd473+_0x2a4963(0xd0)+_0x3af7c2[_0x2a4963(0xe0)]+_0x652ae4),console[_0x2a4963(0xc7)](_0x2cd473+'\x20\x20\x20Upgrade\x20command:\x20'+_0x3ad6dc+_0x652ae4)),console[_0x2a4963(0xc7)]();}export function assertCliVersionSupported(_0x44c2ce){const _0x59fb07=a359_0x5a7a;if(!_0x44c2ce[_0x59fb07(0xe4)])return;const _0x54d4c0=[_0x44c2ce[_0x59fb07(0xca)],_0x59fb07(0xcb)+_0x44c2ce[_0x59fb07(0xd7)],_0x44c2ce[_0x59fb07(0xbd)]?_0x59fb07(0xc2)+_0x44c2ce[_0x59fb07(0xbd)]:null,_0x59fb07(0xda)+getCliUpgradeCommand(_0x44c2ce)][_0x59fb07(0xd2)](Boolean)[_0x59fb07(0xe2)]('\x0a');throw CliErrors['validation']('Current\x20CLI\x20version\x20is\x20below\x20the\x20service\x20compatibility\x20support\x20line.',_0x54d4c0);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x16831d,_0x1f082b){const _0x31a90d=a360_0x16cb,_0x8ecd58=_0x16831d();while(!![]){try{const _0x2b3d31=-parseInt(_0x31a90d(0x148))/0x1+-parseInt(_0x31a90d(0x14a))/0x2+-parseInt(_0x31a90d(0x14e))/0x3+parseInt(_0x31a90d(0x152))/0x4*(-parseInt(_0x31a90d(0x151))/0x5)+-parseInt(_0x31a90d(0x13e))/0x6+-parseInt(_0x31a90d(0x14b))/0x7+parseInt(_0x31a90d(0x150))/0x8;if(_0x2b3d31===_0x1f082b)break;else _0x8ecd58['push'](_0x8ecd58['shift']());}catch(_0x984dd3){_0x8ecd58['push'](_0x8ecd58['shift']());}}}(a360_0x3493,0x25dd1));import{getCliVersionPolicyUrl,getProjectTemplateAssetBaseUrl,getProjectTemplateLegacyAssetBaseUrl}from'../constant/cdn.js';import a360_0x20c2b4 from'semver';const CACHE_TTL=0x5*0x3c*0x3e8,FAILURE_CACHE_TTL=0x3c*0x3e8,FETCH_TIMEOUT_MS=0xbb8;export function isBetaCliVersion(_0x5e2584){const _0x190b40=a360_0x16cb,_0x419034=a360_0x20c2b4[_0x190b40(0x14d)](_0x5e2584);return _0x419034?a360_0x20c2b4[_0x190b40(0x143)](_0x419034)?.[0x0]==='beta':![];}export function resolveProjectTemplateDescriptor(_0xba33ec,_0x3ee6fa){const _0x2a2c1c=a360_0x16cb;if(isBetaCliVersion(_0x3ee6fa))return _0xba33ec['beta']?.[_0x2a2c1c(0x144)]??_0xba33ec[_0x2a2c1c(0x144)];return _0xba33ec[_0x2a2c1c(0x144)];}function pickString(_0xd3e17c){const _0x18ada2=a360_0x16cb;return typeof _0xd3e17c==='string'&&_0xd3e17c[_0x18ada2(0x14f)]()[_0x18ada2(0x140)]>0x0?_0xd3e17c[_0x18ada2(0x14f)]():null;}function normalizeCliVersionPolicy(_0x2ad4d6){const _0xc76cc3=a360_0x16cb;if(!_0x2ad4d6||typeof _0x2ad4d6!=='object')return null;const _0x3a176d=_0x2ad4d6,_0x2bf11a=_0x3a176d[_0xc76cc3(0x13c)]&&typeof _0x3a176d['cli']==='object'?_0x3a176d[_0xc76cc3(0x13c)]:_0x3a176d,_0x1d6806=pickString(_0x2bf11a[_0xc76cc3(0x13b)])||pickString(_0x2bf11a[_0xc76cc3(0x14c)])||pickString(_0x2bf11a[_0xc76cc3(0x145)]),_0x2906ce=pickString(_0x2bf11a[_0xc76cc3(0x141)])||pickString(_0x2bf11a['minVersion']);if(!_0x1d6806&&!_0x2906ce)return null;return{'stableVersion':_0x1d6806,'minimumVersion':_0x2906ce,'upgradeMessage':pickString(_0x2bf11a[_0xc76cc3(0x149)])||undefined,'minimumVersionMessage':pickString(_0x2bf11a[_0xc76cc3(0x13f)])||undefined};}async function fetchRabetbaseCdnConfigAt(_0x119c1a){const _0x35c7f0=a360_0x16cb,_0x127eb4=new AbortController(),_0x2c9c0c=setTimeout(()=>_0x127eb4[_0x35c7f0(0x142)](),FETCH_TIMEOUT_MS);try{const _0x368b20=await fetch(_0x119c1a,{'headers':{'Accept':_0x35c7f0(0x13a)},'signal':_0x127eb4[_0x35c7f0(0x147)]});if(!_0x368b20['ok'])return null;const _0x211eaa=await _0x368b20[_0x35c7f0(0x146)]();return _0x211eaa&&typeof _0x211eaa==='object'?_0x211eaa:null;}catch{return null;}finally{clearTimeout(_0x2c9c0c);}}export async function fetchRabetbaseCdnConfig(){return fetchRabetbaseCdnConfigAt(getCliVersionPolicyUrl());}export async function fetchProjectTemplateCdnConfig(){const _0x19ddb9=await getRabetbaseCdnConfig();return _0x19ddb9?{'config':_0x19ddb9,'assetBaseUrl':getProjectTemplateAssetBaseUrl(),'legacyAssetBaseUrl':getProjectTemplateLegacyAssetBaseUrl()}:null;}export async function fetchCliVersionPolicy(){return normalizeCliVersionPolicy(await fetchRabetbaseCdnConfig());}let cachedConfig=null,cacheTime=0x0,hasCachedConfig=![];export async function getRabetbaseCdnConfig(){const _0x16304f=a360_0x16cb,_0x4bf926=Date[_0x16304f(0x13d)]();if(hasCachedConfig){const _0x146c4b=cachedConfig?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x4bf926-cacheTime<_0x146c4b)return cachedConfig;}return cachedConfig=await fetchRabetbaseCdnConfig(),cacheTime=_0x4bf926,hasCachedConfig=!![],cachedConfig;}function a360_0x16cb(_0xf08e9d,_0x1956b7){_0xf08e9d=_0xf08e9d-0x13a;const _0x349301=a360_0x3493();let _0x16cb38=_0x349301[_0xf08e9d];return _0x16cb38;}export async function getCliVersionPolicy(){return normalizeCliVersionPolicy(await getRabetbaseCdnConfig());}function a360_0x3493(){const _0x4d6ed7=['now','1281330VPhWHt','minimumVersionMessage','length','minimumVersion','abort','prerelease','projectTemplate','recommendedVersion','json','signal','291850NHGjWZ','upgradeMessage','73096jyMhCZ','305984SzwKlE','latestVersion','valid','423033ujCbfa','trim','8594192SzAIeR','5SAXzTQ','770036IrMcLH','application/json','stableVersion','cli'];a360_0x3493=function(){return _0x4d6ed7;};return a360_0x3493();}export function clearCliVersionPolicyCache(){cachedConfig=null,cacheTime=0x0,hasCachedConfig=![];}
|
package/lib/utils/config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a361_0x1ef48a=a361_0x52f2;function a361_0x602d(){const _0x3a89ee=['1283600NtFnTw','env','680682eMXitb','string','project','732213uymAVB','4092774GlJCwv','10185128pyTmZR','582318KVLVXh','935978tZEJvs','25YhQlNL'];a361_0x602d=function(){return _0x3a89ee;};return a361_0x602d();}(function(_0x4a92e7,_0x3fe655){const _0x3e0450=a361_0x52f2,_0x1e7f56=_0x4a92e7();while(!![]){try{const _0x76ecfc=parseInt(_0x3e0450(0xaa))/0x1+-parseInt(_0x3e0450(0xab))/0x2+-parseInt(_0x3e0450(0xa7))/0x3+parseInt(_0x3e0450(0xad))/0x4+-parseInt(_0x3e0450(0xac))/0x5*(parseInt(_0x3e0450(0xaf))/0x6)+-parseInt(_0x3e0450(0xa8))/0x7+parseInt(_0x3e0450(0xa9))/0x8;if(_0x76ecfc===_0x3fe655)break;else _0x1e7f56['push'](_0x1e7f56['shift']());}catch(_0x3c0c7f){_0x1e7f56['push'](_0x1e7f56['shift']());}}}(a361_0x602d,0x4c43e));import{initEnv}from'../constant/env.js';import{readRawConfig,getConfigAppCode as a361_0x12993f,getMultiAppConfigs as a361_0x485a2e,getTemplateBaseUrl as a361_0x1f49e3}from'../context.js';export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';export{isInProject}from'../context.js';export function readConfig(_0x10d1ce){const _0x54b86d=a361_0x52f2,_0x3b7cb5=readRawConfig(_0x10d1ce);return _0x3b7cb5[_0x54b86d(0xae)]&&typeof _0x3b7cb5[_0x54b86d(0xae)]===_0x54b86d(0xb0)&&initEnv(_0x3b7cb5[_0x54b86d(0xae)]),_0x3b7cb5;}function a361_0x52f2(_0x4145ab,_0x272b7f){_0x4145ab=_0x4145ab-0xa6;const _0x602d78=a361_0x602d();let _0x52f275=_0x602d78[_0x4145ab];return _0x52f275;}export function getConfigAppCode(){return a361_0x12993f();}export function getMultiAppConfigs(_0x456968=a361_0x1ef48a(0xa6)){return a361_0x485a2e(_0x456968);}export function getTemplateBaseUrl(){return a361_0x1f49e3();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x9b58f1,_0x15efcb){const _0x5aeaad=a362_0xfc03,_0x2f1bd4=_0x9b58f1();while(!![]){try{const _0x3d5ea3=-parseInt(_0x5aeaad(0x115))/0x1*(-parseInt(_0x5aeaad(0x118))/0x2)+parseInt(_0x5aeaad(0x11b))/0x3*(-parseInt(_0x5aeaad(0x113))/0x4)+parseInt(_0x5aeaad(0x111))/0x5*(-parseInt(_0x5aeaad(0x11a))/0x6)+-parseInt(_0x5aeaad(0x11f))/0x7*(parseInt(_0x5aeaad(0x110))/0x8)+-parseInt(_0x5aeaad(0x11c))/0x9*(parseInt(_0x5aeaad(0x116))/0xa)+-parseInt(_0x5aeaad(0x117))/0xb*(-parseInt(_0x5aeaad(0x120))/0xc)+parseInt(_0x5aeaad(0x11d))/0xd;if(_0x3d5ea3===_0x15efcb)break;else _0x2f1bd4['push'](_0x2f1bd4['shift']());}catch(_0x3ffbd0){_0x2f1bd4['push'](_0x2f1bd4['shift']());}}}(a362_0x4ff6,0x6b12b));function a362_0x4ff6(){const _0x31541c=['trim','719mHgnuo','8660jASVRN','11bYsFsz','514mFtwAJ','number','573168xHQwfu','12FvdQQg','333hnwanJ','15347618JRtpIW','object','35nOoEwG','6814932kdcOOt','1264056vzwklx','30HMqdEB','string','99464DxPYub'];a362_0x4ff6=function(){return _0x31541c;};return a362_0x4ff6();}function a362_0xfc03(_0x595955,_0x146b37){_0x595955=_0x595955-0x110;const _0x4ff658=a362_0x4ff6();let _0xfc03a4=_0x4ff658[_0x595955];return _0xfc03a4;}function toFiniteNumber(_0x4359c4){const _0xae6248=a362_0xfc03;if(typeof _0x4359c4===_0xae6248(0x119)&&Number['isFinite'](_0x4359c4))return _0x4359c4;if(typeof _0x4359c4===_0xae6248(0x112)){const _0x51a079=_0x4359c4[_0xae6248(0x114)]();if(!_0x51a079)return undefined;const _0x483c52=Number(_0x51a079);if(Number['isFinite'](_0x483c52))return _0x483c52;}return undefined;}export function normalizeEntityWithIdResponse(_0x3be33f){const _0x4a74f8=a362_0xfc03,_0x4007df=toFiniteNumber(_0x3be33f);if(_0x4007df!==undefined)return{'id':_0x4007df,'entity':{'id':_0x4007df}};if(!_0x3be33f||typeof _0x3be33f!==_0x4a74f8(0x11e))return{'id':undefined,'entity':{}};const _0x30c392={..._0x3be33f},_0x243c1d=toFiniteNumber(_0x30c392['id']);return _0x243c1d!==undefined&&(_0x30c392['id']=_0x243c1d),{'id':_0x243c1d,'entity':_0x30c392};}
|
package/lib/utils/file-utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x220f7a,_0xfabd06){const _0x240e7c=a363_0x53a0,_0x4f0bfa=_0x220f7a();while(!![]){try{const _0x5122c0=-parseInt(_0x240e7c(0xa9))/0x1+parseInt(_0x240e7c(0xa8))/0x2*(-parseInt(_0x240e7c(0xad))/0x3)+parseInt(_0x240e7c(0xae))/0x4+-parseInt(_0x240e7c(0xaa))/0x5+parseInt(_0x240e7c(0xa6))/0x6+-parseInt(_0x240e7c(0xab))/0x7*(-parseInt(_0x240e7c(0xaf))/0x8)+-parseInt(_0x240e7c(0xac))/0x9;if(_0x5122c0===_0xfabd06)break;else _0x4f0bfa['push'](_0x4f0bfa['shift']());}catch(_0x42aa43){_0x4f0bfa['push'](_0x4f0bfa['shift']());}}}(a363_0x1934,0x33f12));import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';function a363_0x53a0(_0x27ee0d,_0x5c9f79){_0x27ee0d=_0x27ee0d-0xa6;const _0x1934bc=a363_0x1934();let _0x53a027=_0x1934bc[_0x27ee0d];return _0x53a027;}export async function copyDir(_0x1ad08d,_0x5620af){const _0x40a7e9=a363_0x53a0,_0x52b6c1=statSync(_0x1ad08d);if(_0x52b6c1[_0x40a7e9(0xa7)]()){!existsSync(_0x5620af)&&mkdirSync(_0x5620af,{'recursive':!![]});const _0x348ead=readdirSync(_0x1ad08d);for(const _0x1ba10b of _0x348ead){await copyDir(join(_0x1ad08d,_0x1ba10b),join(_0x5620af,_0x1ba10b));}}else copyFileSync(_0x1ad08d,_0x5620af);}function a363_0x1934(){const _0x4b9c47=['1765956eNHVCH','isDirectory','164zaFCGx','199309gkAzDu','126920qpBQeo','13755rAWFVa','801450LPGZCU','9378lPSdQR','1427392Lnwdqa','536JHMZms'];a363_0x1934=function(){return _0x4b9c47;};return a363_0x1934();}export function ensureDir(_0x2f676b){!existsSync(_0x2f676b)&&mkdirSync(_0x2f676b,{'recursive':!![]});}export function pathExists(_0x5020a7){return existsSync(_0x5020a7);}
|
package/lib/utils/guides-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a364_0x2c3410=a364_0x288d;(function(_0x24a401,_0x33df46){const _0x3e9206=a364_0x288d,_0x32d60b=_0x24a401();while(!![]){try{const _0x326722=-parseInt(_0x3e9206(0x1a3))/0x1*(-parseInt(_0x3e9206(0x198))/0x2)+-parseInt(_0x3e9206(0x1ba))/0x3*(parseInt(_0x3e9206(0x1b3))/0x4)+-parseInt(_0x3e9206(0x1b0))/0x5*(parseInt(_0x3e9206(0x19e))/0x6)+-parseInt(_0x3e9206(0x1b1))/0x7*(parseInt(_0x3e9206(0x1bb))/0x8)+parseInt(_0x3e9206(0x1b7))/0x9+-parseInt(_0x3e9206(0x1a5))/0xa*(parseInt(_0x3e9206(0x19d))/0xb)+parseInt(_0x3e9206(0x1b2))/0xc;if(_0x326722===_0x33df46)break;else _0x32d60b['push'](_0x32d60b['shift']());}catch(_0x4e25bb){_0x32d60b['push'](_0x32d60b['shift']());}}}(a364_0x3c8a,0xe62b1));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 _0x2913ec=a364_0x288d,_0x41353b=getTemplateBaseUrl();return _0x41353b+_0x2913ec(0x1af);}const CACHE_DIR=join(homedir(),a364_0x2c3410(0x1ac),'cache');export async function fetchGuidesFromCDN(){const _0x8fd6d6=a364_0x2c3410,_0x50bdca=getGuidesCdnUrl(),_0x1ef878=await fetch(_0x50bdca,{'headers':{'Accept':_0x8fd6d6(0x1ab)}});if(!_0x1ef878['ok'])throw new Error(_0x8fd6d6(0x1a8)+_0x1ef878['status']+'\x20'+_0x1ef878[_0x8fd6d6(0x19b)]);const _0x26c7c4=await _0x1ef878['json']();if(!_0x26c7c4[_0x8fd6d6(0x1b4)]||typeof _0x26c7c4[_0x8fd6d6(0x1b4)]!=='object')throw new Error(_0x8fd6d6(0x1a1));return _0x26c7c4;}function a364_0x3c8a(){const _0x39de36=['lastUpdated','application/json','.lovrabet','extendContent','content','/skills/guides.json','9210ErgZka','1673SaNkIc','56619012kdMHOT','5492edSWlR','guides','join','path','7070049MuvqXD','push','map','1623kaULpH','62968AjzeSo','5456ozBbIn','keys','\x0a\x0a>更新时间:','statusText','entries','14047LCBgrU','5454fqqwaq','trimEnd','replace','CDN\x20returned\x20invalid\x20data','utf-8','347GOqJCQ','CDN\x20data\x20is\x20missing\x20skillTemplate','9470TEIjQw','length','skillTemplate','CDN\x20request\x20failed:\x20','.md'];a364_0x3c8a=function(){return _0x39de36;};return a364_0x3c8a();}function a364_0x288d(_0x4399dd,_0x3db2ff){_0x4399dd=_0x4399dd-0x198;const _0x3c8a79=a364_0x3c8a();let _0x288d71=_0x3c8a79[_0x4399dd];return _0x288d71;}export function writeGuidesToProject(_0x4361c5,_0x13be3f,_0x3d27db='.lovrabet/skill/guides',_0x47dbbb){const _0x3de7b5=a364_0x2c3410,_0x26826f=join(_0x13be3f,_0x3d27db);mkdirSync(_0x26826f,{'recursive':!![]});for(const [_0xddea18,_0x3f2c4a]of Object['entries'](_0x4361c5[_0x3de7b5(0x1b4)])){let _0x234217=_0x3f2c4a['content'];_0x3f2c4a[_0x3de7b5(0x1aa)]&&(_0x234217=appendUpdateTime(_0x234217,_0x3f2c4a['lastUpdated'])),writeFileSync(join(_0x26826f,_0xddea18+_0x3de7b5(0x1a9)),_0x234217,_0x3de7b5(0x1a2));}}export function appendUpdateTime(_0x4783cf,_0x55629f){const _0x698473=a364_0x2c3410;return _0x4783cf=_0x4783cf[_0x698473(0x1a0)](/\n*>更新时间:.*$/m,''),_0x4783cf[_0x698473(0x19f)]()+(_0x698473(0x19a)+_0x55629f);}export function getSkillTemplate(_0x1c4ef6){const _0x5153ae=a364_0x2c3410;return _0x1c4ef6[_0x5153ae(0x1a7)]?.[_0x5153ae(0x1ae)]||'';}export function appendExtendContents(_0x4c16ef,_0x14a70e,_0x2e934b){const _0x422c41=a364_0x2c3410,_0x285552=[];for(const [,_0x182600]of Object[_0x422c41(0x19c)](_0x14a70e[_0x422c41(0x1b4)])){_0x182600[_0x422c41(0x1ad)]&&_0x285552[_0x422c41(0x1b8)](_0x182600[_0x422c41(0x1ad)]['trimEnd']());}if(_0x285552[_0x422c41(0x1a6)]===0x0)return _0x4c16ef;return _0x4c16ef[_0x422c41(0x19f)]()+'\x0a\x0a'+_0x285552[_0x422c41(0x1b5)]('\x0a\x0a')+'\x0a';}export function writeSkillFile(_0x1d05b2,_0x28bccf,_0x217c63){const _0x2981c2=a364_0x2c3410,_0x3e437a=getSkillTemplate(_0x1d05b2);if(!_0x3e437a)throw new Error(_0x2981c2(0x1a4));const _0x5845f3=dirname(_0x28bccf);mkdirSync(_0x5845f3,{'recursive':!![]});let _0xd09e91=_0x3e437a[_0x2981c2(0x1a0)](/\{\{IDE_NAME\}\}/g,_0x217c63);_0xd09e91=appendExtendContents(_0xd09e91,_0x1d05b2),_0x1d05b2[_0x2981c2(0x1a7)][_0x2981c2(0x1aa)]&&(_0xd09e91=appendUpdateTime(_0xd09e91,_0x1d05b2[_0x2981c2(0x1a7)][_0x2981c2(0x1aa)])),writeFileSync(_0x28bccf,_0xd09e91,_0x2981c2(0x1a2));}export async function installGuides(_0x35628c){const _0x49a9b9=a364_0x2c3410,_0x42fc5f=await fetchGuidesFromCDN();return writeGuidesToProject(_0x42fc5f,_0x35628c),Object[_0x49a9b9(0x199)](_0x42fc5f[_0x49a9b9(0x1b4)])['length'];}export function getGuidesSummary(_0x14a85b){const _0x3cd06b=a364_0x2c3410;return Object[_0x3cd06b(0x19c)](_0x14a85b[_0x3cd06b(0x1b4)])[_0x3cd06b(0x1b9)](([_0x3965b9,_0x114e50])=>({'key':_0x3965b9,'title':_0x114e50['title'],'path':_0x114e50[_0x3cd06b(0x1b6)]}));}
|
package/lib/utils/http-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4f12ba,_0x49d014){const _0x439fd5=a365_0x4d9e,_0xf7c58f=_0x4f12ba();while(!![]){try{const _0x41ef9b=-parseInt(_0x439fd5(0xee))/0x1+parseInt(_0x439fd5(0xef))/0x2*(-parseInt(_0x439fd5(0xe5))/0x3)+-parseInt(_0x439fd5(0xfd))/0x4*(-parseInt(_0x439fd5(0xe2))/0x5)+-parseInt(_0x439fd5(0xea))/0x6*(parseInt(_0x439fd5(0xf8))/0x7)+parseInt(_0x439fd5(0xfb))/0x8+parseInt(_0x439fd5(0xe8))/0x9+-parseInt(_0x439fd5(0xf9))/0xa*(-parseInt(_0x439fd5(0xf4))/0xb);if(_0x41ef9b===_0x49d014)break;else _0xf7c58f['push'](_0xf7c58f['shift']());}catch(_0x395e18){_0xf7c58f['push'](_0xf7c58f['shift']());}}}(a365_0x24f4,0x43688));function a365_0x24f4(){const _0x2c44ad=['content-type','get','316634tyDCMG','1994TnREcn','message','*\x20Request\x20failed;\x20retry\x20','statusText','includes','1095259HJlIzM','log','text','application/json','1254827RHBHAq','50FphulL','abort','2436176AjSXkZ','ms...','342892tbkcOh','\x20in\x20','5JKzSFk','ECONNRESET','name','549cIacPC','TypeError','url','2210589PLBzxY','Request\x20failed','12ZzaIXb','headers'];a365_0x24f4=function(){return _0x2c44ad;};return a365_0x24f4();}function a365_0x4d9e(_0x40c9fc,_0x56a3e7){_0x40c9fc=_0x40c9fc-0xe1;const _0x24f471=a365_0x24f4();let _0x4d9e3b=_0x24f471[_0x40c9fc];return _0x4d9e3b;}export async function httpRequest(_0x1c7bd7,_0x37a264={}){const _0x4aefc8=a365_0x4d9e,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x37a264;let _0x41dbe3=null;for(let _0x27e941=0x0;_0x27e941<=retries;_0x27e941++){try{const _0x6a9a0a=new AbortController(),_0x2f9c4c=setTimeout(()=>_0x6a9a0a[_0x4aefc8(0xfa)](),timeout),_0x2a4847=await fetch(_0x1c7bd7,{'headers':headers,'signal':_0x6a9a0a['signal']});clearTimeout(_0x2f9c4c);let _0x236ea1;const _0xc53643=_0x2a4847['headers'][_0x4aefc8(0xed)](_0x4aefc8(0xec));return _0xc53643?.[_0x4aefc8(0xf3)](_0x4aefc8(0xf7))?_0x236ea1=await _0x2a4847['json']():_0x236ea1=await _0x2a4847[_0x4aefc8(0xf6)](),{'ok':_0x2a4847['ok'],'status':_0x2a4847['status'],'statusText':_0x2a4847[_0x4aefc8(0xf2)],'data':_0x236ea1,'headers':_0x2a4847[_0x4aefc8(0xeb)],'url':_0x2a4847[_0x4aefc8(0xe7)],'text':()=>_0x2a4847[_0x4aefc8(0xf6)]()};}catch(_0xc5691){_0x41dbe3=_0xc5691 instanceof Error?_0xc5691:new Error(String(_0xc5691));if(_0x27e941===retries)break;if(shouldRetry(_0xc5691)){console[_0x4aefc8(0xf5)](_0x4aefc8(0xf1)+(_0x27e941+0x1)+_0x4aefc8(0xe1)+retryDelay+_0x4aefc8(0xfc)),await sleep(retryDelay);continue;}else break;}}throw _0x41dbe3||new Error(_0x4aefc8(0xe9));}function shouldRetry(_0x303c54){const _0x5a1410=a365_0x4d9e;if(_0x303c54 instanceof Error){if(_0x303c54[_0x5a1410(0xe4)]==='AbortError')return![];if(_0x303c54[_0x5a1410(0xe4)]===_0x5a1410(0xe6)&&_0x303c54[_0x5a1410(0xf0)]['includes']('fetch'))return!![];if(_0x303c54[_0x5a1410(0xf0)]['includes'](_0x5a1410(0xe3)))return!![];if(_0x303c54[_0x5a1410(0xf0)][_0x5a1410(0xf3)]('ENOTFOUND'))return![];}return![];}function sleep(_0x2ba159){return new Promise(_0x123851=>setTimeout(_0x123851,_0x2ba159));}export function validateUrl(_0x3ee194){try{return new URL(_0x3ee194),!![];}catch{return![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5876dd,_0xabdcc9){const _0x51d6bc=a366_0x3ba6,_0x3e3b26=_0x5876dd();while(!![]){try{const _0x5f48b9=parseInt(_0x51d6bc(0xa5))/0x1*(-parseInt(_0x51d6bc(0xa8))/0x2)+parseInt(_0x51d6bc(0x9f))/0x3*(-parseInt(_0x51d6bc(0xa2))/0x4)+parseInt(_0x51d6bc(0xa7))/0x5+parseInt(_0x51d6bc(0xaa))/0x6*(-parseInt(_0x51d6bc(0xa3))/0x7)+parseInt(_0x51d6bc(0xa9))/0x8+-parseInt(_0x51d6bc(0xa1))/0x9+parseInt(_0x51d6bc(0x9b))/0xa;if(_0x5f48b9===_0xabdcc9)break;else _0x3e3b26['push'](_0x3e3b26['shift']());}catch(_0x323e56){_0x3e3b26['push'](_0x3e3b26['shift']());}}}(a366_0x4f2b,0x7ab92));function a366_0x3ba6(_0x927e12,_0x2be7e6){_0x927e12=_0x927e12-0x9b;const _0x4f2bf0=a366_0x4f2b();let _0x3ba627=_0x4f2bf0[_0x927e12];return _0x3ba627;}function env(_0x5f5bce){return process.env[`RABETBASE_${_0x5f5bce}`]||process.env[`LOVRABET_${_0x5f5bce}`]||undefined;}export function isNonInteractive(_0x3ba225){const _0x3b5ad2=a366_0x3ba6;return!!(_0x3ba225[_0x3b5ad2(0x9e)]||_0x3ba225['ci']||env('CI')===_0x3b5ad2(0x9d)||process.env.CI===_0x3b5ad2(0x9d)||!process[_0x3b5ad2(0xa0)][_0x3b5ad2(0xa4)]||!isStdinRawModeSupported());}function a366_0x4f2b(){const _0xa4e1c3=['6sHmRKy','6264992cAddsS','354kcRviU','4572240gaMEQr','setRawMode','true','nonInteractive','189noAcQP','stdout','1480365PdEEOE','25224RAIxYN','33803hDwWLi','isTTY','28949zvKKKO','stdin','979235jIruaR'];a366_0x4f2b=function(){return _0xa4e1c3;};return a366_0x4f2b();}function isStdinRawModeSupported(){const _0x37f749=a366_0x3ba6;if(!process['stdin'][_0x37f749(0xa4)])return![];try{const _0x3222e=process[_0x37f749(0xa6)]['isRaw'];return process['stdin'][_0x37f749(0x9c)](!![]),process['stdin'][_0x37f749(0x9c)](_0x3222e??![]),!![];}catch{return![];}}
|
package/lib/utils/logger.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a367_0x2a88(){const _0x4daf47=['addColors','winstonLogger','setRawCommand','utf8','8856592lOhxUI','965418FylBzv','error','level','dirname','now','328426JFErfq','clear','duration','toISOString','3141284sGFdwa','currentRawCommand','4537629uSmrix','readFileSync','trim','yellow','initWinstonLogger','join','writeFileSync','9wQHpcD','logFilePath','Completed:\x20','Starting:\x20','timestamp','setLogPath','split','combine','7fJCpOc','log','24421930BwMoVY','info','map','existsSync','success','rawCommand','transports','message','File','printf','logTask','mkdirSync','format','green','329074rKiHaY','warn','5ZVvVNI','details'];a367_0x2a88=function(){return _0x4daf47;};return a367_0x2a88();}const a367_0x147439=a367_0x558b;(function(_0x2a0033,_0x1fb313){const _0x18a077=a367_0x558b,_0x1e7f4b=_0x2a0033();while(!![]){try{const _0x34aa3d=-parseInt(_0x18a077(0x1ea))/0x1+-parseInt(_0x18a077(0x1f8))/0x2*(parseInt(_0x18a077(0x1d2))/0x3)+parseInt(_0x18a077(0x1fc))/0x4*(parseInt(_0x18a077(0x1ec))/0x5)+-parseInt(_0x18a077(0x1f3))/0x6*(parseInt(_0x18a077(0x1da))/0x7)+-parseInt(_0x18a077(0x1f2))/0x8+-parseInt(_0x18a077(0x1fe))/0x9+parseInt(_0x18a077(0x1dc))/0xa;if(_0x34aa3d===_0x1fb313)break;else _0x1e7f4b['push'](_0x1e7f4b['shift']());}catch(_0x3ae8c7){_0x1e7f4b['push'](_0x1e7f4b['shift']());}}}(a367_0x2a88,0x9ab2b));import a367_0x57a535 from'winston';import a367_0x3ea7d9 from'node:fs';import a367_0x4fa35b from'node:path';function a367_0x558b(_0xc161ae,_0x19b12a){_0xc161ae=_0xc161ae-0x1d0;const _0x2a8878=a367_0x2a88();let _0x558bd=_0x2a8878[_0xc161ae];return _0x558bd;}class Logger{[a367_0x147439(0x1ef)];['logFilePath'];[a367_0x147439(0x1fd)]='';constructor(){this['logFilePath']='';}[a367_0x147439(0x1f0)](_0x3ea8b7){const _0xffa6d=a367_0x147439;this[_0xffa6d(0x1fd)]=_0x3ea8b7;}[a367_0x147439(0x202)](){const _0x2b5530=a367_0x147439,_0x2052fe=a367_0x4fa35b[_0x2b5530(0x1f6)](this[_0x2b5530(0x1d3)]);!a367_0x3ea7d9[_0x2b5530(0x1df)](_0x2052fe)&&a367_0x3ea7d9[_0x2b5530(0x1e7)](_0x2052fe,{'recursive':!![]});const _0x411385=a367_0x57a535['format'][_0x2b5530(0x1d9)](a367_0x57a535['format'][_0x2b5530(0x1d6)](),a367_0x57a535['format']['errors']({'stack':!![]}),a367_0x57a535[_0x2b5530(0x1e8)][_0x2b5530(0x1e5)](_0x2a9384=>{const _0x366bff=_0x2b5530,_0x2cae31={'timestamp':_0x2a9384[_0x366bff(0x1d6)]||new Date()[_0x366bff(0x1fb)](),'level':_0x2a9384[_0x366bff(0x1f5)]||'info','command':_0x2a9384['command']||'unknown','rawCommand':_0x2a9384[_0x366bff(0x1e1)]||this[_0x366bff(0x1fd)]||undefined,'message':_0x2a9384[_0x366bff(0x1e3)]||'','duration':_0x2a9384[_0x366bff(0x1fa)]||undefined,'details':_0x2a9384[_0x366bff(0x1ed)]||undefined};return JSON['stringify'](_0x2cae31);}));this[_0x2b5530(0x1ef)]=a367_0x57a535['createLogger']({'level':'info','format':_0x411385,'transports':[new a367_0x57a535[(_0x2b5530(0x1e2))][(_0x2b5530(0x1e4))]({'filename':this[_0x2b5530(0x1d3)],'level':'info'})],'silent':![]}),a367_0x57a535[_0x2b5530(0x1ee)]({'success':_0x2b5530(0x1e9),'error':'red','warn':_0x2b5530(0x201),'info':'blue'});}[a367_0x147439(0x1d7)](_0x3cfe77){const _0x1c177e=a367_0x147439;this[_0x1c177e(0x1d3)]=a367_0x4fa35b[_0x1c177e(0x1d0)](_0x3cfe77,'.lovrabet.log'),this[_0x1c177e(0x1ef)]&&this[_0x1c177e(0x1ef)][_0x1c177e(0x1f9)](),this[_0x1c177e(0x202)]();}['info'](_0x57add9,_0x3c519c,_0x3871a5){const _0x4fe095=a367_0x147439;if(!this[_0x4fe095(0x1d3)]||!this[_0x4fe095(0x1ef)])return;this['winstonLogger'][_0x4fe095(0x1dd)](_0x3c519c,{'command':_0x57add9,'details':_0x3871a5});}['success'](_0x39849b,_0x308521,_0x2271dd,_0x2eebb5){const _0x350caa=a367_0x147439;if(!this[_0x350caa(0x1d3)]||!this['winstonLogger'])return;this[_0x350caa(0x1ef)][_0x350caa(0x1db)]('info',_0x308521,{'level':_0x350caa(0x1e0),'command':_0x39849b,'duration':_0x2271dd,'details':_0x2eebb5});}['error'](_0x396106,_0xc8434d,_0x252e70){const _0x4542da=a367_0x147439;if(!this[_0x4542da(0x1d3)]||!this[_0x4542da(0x1ef)])return;this[_0x4542da(0x1ef)]['error'](_0xc8434d,{'command':_0x396106,'details':_0x252e70});}['warn'](_0x8e714,_0x24273b,_0x154488){const _0x3e4731=a367_0x147439;if(!this[_0x3e4731(0x1d3)]||!this[_0x3e4731(0x1ef)])return;this[_0x3e4731(0x1ef)][_0x3e4731(0x1eb)](_0x24273b,{'command':_0x8e714,'details':_0x154488});}async[a367_0x147439(0x1e6)](_0x2a8cd9,_0x1b8a2b,_0x4bfc0b){const _0x19f412=a367_0x147439,_0x3a3081=Date[_0x19f412(0x1f7)]();this[_0x19f412(0x1dd)](_0x2a8cd9,_0x19f412(0x1d5)+_0x1b8a2b);try{const _0x5e4413=await _0x4bfc0b(),_0x18b1f7=Date[_0x19f412(0x1f7)]()-_0x3a3081;return this[_0x19f412(0x1e0)](_0x2a8cd9,_0x19f412(0x1d4)+_0x1b8a2b,_0x18b1f7),_0x5e4413;}catch(_0x3ae9a9){const _0x3ddc44=Date[_0x19f412(0x1f7)]()-_0x3a3081;this[_0x19f412(0x1f4)](_0x2a8cd9,'Failed:\x20'+_0x1b8a2b,{'error':_0x3ae9a9 instanceof Error?_0x3ae9a9[_0x19f412(0x1e3)]:String(_0x3ae9a9),'duration':_0x3ddc44});throw _0x3ae9a9;}}['readLogs'](){const _0x252098=a367_0x147439;try{if(!a367_0x3ea7d9[_0x252098(0x1df)](this[_0x252098(0x1d3)]))return[];const _0x33e032=a367_0x3ea7d9[_0x252098(0x1ff)](this[_0x252098(0x1d3)],'utf8');return _0x33e032[_0x252098(0x1d8)]('\x0a')['filter'](_0x1fab63=>_0x1fab63[_0x252098(0x200)]())[_0x252098(0x1de)](_0x24c5af=>JSON['parse'](_0x24c5af));}catch(_0x5ec625){return console[_0x252098(0x1eb)]('Failed\x20to\x20read\x20logs:',_0x5ec625),[];}}['clearLogs'](){const _0x38fdef=a367_0x147439;try{a367_0x3ea7d9[_0x38fdef(0x1df)](this[_0x38fdef(0x1d3)])&&a367_0x3ea7d9[_0x38fdef(0x1d1)](this['logFilePath'],'',_0x38fdef(0x1f1));}catch(_0x333d16){console['warn']('Failed\x20to\x20clear\x20logs:',_0x333d16);}}['getWinstonInstance'](){return this['winstonLogger'];}}export const logger=new Logger();
|
package/lib/utils/params.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a368_0x2e91(){const _0x255131=['isArray','parse','4199097dLCDnI','Invalid\x20JSON\x20for\x20--params:\x20','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','9348630mGDdKu','object','21tcPreX','--params\x20must\x20be\x20a\x20JSON\x20object','4476664cSTjzQ','14188zDQZHR','2810035gUcbIA','20867229BplloJ','1239mNKVyQ','129548QFxnlt','validation'];a368_0x2e91=function(){return _0x255131;};return a368_0x2e91();}function a368_0x55a1(_0x103774,_0x28538c){_0x103774=_0x103774-0xc6;const _0x2e91c3=a368_0x2e91();let _0x55a150=_0x2e91c3[_0x103774];return _0x55a150;}(function(_0x298fc4,_0x5550cf){const _0x4726ee=a368_0x55a1,_0x2ca5f9=_0x298fc4();while(!![]){try{const _0x41a2c5=-parseInt(_0x4726ee(0xd4))/0x1*(-parseInt(_0x4726ee(0xcb))/0x2)+parseInt(_0x4726ee(0xca))/0x3*(-parseInt(_0x4726ee(0xc7))/0x4)+parseInt(_0x4726ee(0xc8))/0x5+parseInt(_0x4726ee(0xd2))/0x6+parseInt(_0x4726ee(0xcf))/0x7+parseInt(_0x4726ee(0xc6))/0x8+-parseInt(_0x4726ee(0xc9))/0x9;if(_0x41a2c5===_0x5550cf)break;else _0x2ca5f9['push'](_0x2ca5f9['shift']());}catch(_0x4fd348){_0x2ca5f9['push'](_0x2ca5f9['shift']());}}}(a368_0x2e91,0xd1108));import{CliErrors}from'../errors.js';export function parseJsonParams(_0xe22f35){const _0x137742=a368_0x55a1;if(!_0xe22f35)return undefined;let _0x315d29;try{_0x315d29=JSON[_0x137742(0xce)](_0xe22f35);}catch{throw CliErrors[_0x137742(0xcc)](_0x137742(0xd0)+_0xe22f35);}if(!_0x315d29||typeof _0x315d29!==_0x137742(0xd3)||Array[_0x137742(0xcd)](_0x315d29))throw CliErrors[_0x137742(0xcc)](_0x137742(0xd5),_0x137742(0xd1));return _0x315d29;}
|
package/lib/utils/platform.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a369_0x312d(){const _0x58ec55=['4KqVzgU','128nwNjsl','10ddOkwC','183434RKuNBD','567990PjfUUV','win32','5343399CRjfYl','.cmd','123637seGWhC','1422552rZfqwK','26978URLRMh','platform','1559980Ezpmke'];a369_0x312d=function(){return _0x58ec55;};return a369_0x312d();}const a369_0x2a1db7=a369_0x1a93;function a369_0x1a93(_0x4bd0c9,_0x487c0c){_0x4bd0c9=_0x4bd0c9-0xad;const _0x312dc2=a369_0x312d();let _0x1a930a=_0x312dc2[_0x4bd0c9];return _0x1a930a;}(function(_0x507ce4,_0x2d658d){const _0x5104fd=a369_0x1a93,_0x5cb393=_0x507ce4();while(!![]){try{const _0x588298=-parseInt(_0x5104fd(0xad))/0x1+-parseInt(_0x5104fd(0xb5))/0x2+-parseInt(_0x5104fd(0xb6))/0x3*(parseInt(_0x5104fd(0xb2))/0x4)+-parseInt(_0x5104fd(0xb1))/0x5+parseInt(_0x5104fd(0xae))/0x6+-parseInt(_0x5104fd(0xaf))/0x7*(-parseInt(_0x5104fd(0xb3))/0x8)+-parseInt(_0x5104fd(0xb8))/0x9*(-parseInt(_0x5104fd(0xb4))/0xa);if(_0x588298===_0x2d658d)break;else _0x5cb393['push'](_0x5cb393['shift']());}catch(_0x2d56f5){_0x5cb393['push'](_0x5cb393['shift']());}}}(a369_0x312d,0x2aeab));export const isWindows=process[a369_0x2a1db7(0xb0)]===a369_0x2a1db7(0xb7);export function resolveNpmBin(_0x50c319){const _0x1c4ab8=a369_0x2a1db7;return isWindows?_0x50c319+_0x1c4ab8(0xb9):_0x50c319;}
|
package/lib/utils/sleep.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export function sleep(
|
|
1
|
+
export function sleep(_0x4be724){return new Promise(_0x8aa58f=>setTimeout(_0x8aa58f,_0x4be724));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a371_0x3d50e6=a371_0x4f6d;function a371_0x4d2f(){const _0x430c25=['replaceApiContent','3858enUUrx','1297581niscmr','default','name:\x20\x22','.scss','getMonth','alias:\x20\x22','875450sJGLeX','getSeconds','mkdir','writeFile','.md','getFullYear','join','toLowerCase','message','pop','datasetCode','alias','getHours','extname','isDirectory','4087035kBaRui','.js','YourModel','split','.css','tableName','processDirectory','getMinutes','utf8','charAt','push','Starting\x20template\x20content\x20replacement','processFile','readFile','.tsx','info','toDisplayTitle','error','template','tableName:\x20\x22','getDate','.json','replace','4pWOnnq','1042872ejccIk','pad','toUpperCase','success','now','processTemplate','name','1183tsAGMi','toComponentName','LOVRABET','map','3244280lNeRAV','datasetCode:\x20\x22','endsWith','includes','10130049EeXodU','\x20},','sdk-config','.ts','.tpl','formatLocalTimestamp','Template\x20content\x20replacement\x20completed','isFile','slice','readdir','toISOString','\x0a\x20\x20\x20\x20{\x20','promises'];a371_0x4d2f=function(){return _0x430c25;};return a371_0x4d2f();}(function(_0x373f19,_0x4b8ee1){const _0x4df167=a371_0x4f6d,_0x23f24b=_0x373f19();while(!![]){try{const _0x53ea61=-parseInt(_0x4df167(0xf3))/0x1+-parseInt(_0x4df167(0xcf))/0x2+parseInt(_0x4df167(0xed))/0x3+-parseInt(_0x4df167(0xce))/0x4*(-parseInt(_0x4df167(0x102))/0x5)+-parseInt(_0x4df167(0xec))/0x6*(parseInt(_0x4df167(0xd6))/0x7)+-parseInt(_0x4df167(0xda))/0x8+parseInt(_0x4df167(0xde))/0x9;if(_0x53ea61===_0x4b8ee1)break;else _0x23f24b['push'](_0x23f24b['shift']());}catch(_0x2a505b){_0x23f24b['push'](_0x23f24b['shift']());}}}(a371_0x4d2f,0x71617));import a371_0x559c96 from'node:fs';import a371_0x978537 from'node:path';import{logger}from'../utils/logger.js';import{getCliVersion}from'../utils/version.js';const CLI_VERSION=getCliVersion();function a371_0x4f6d(_0x4ef270,_0x6f50cf){_0x4ef270=_0x4ef270-0xcd;const _0x4d2f88=a371_0x4d2f();let _0x4f6dd8=_0x4d2f88[_0x4ef270];return _0x4f6dd8;}export class TemplateReplacer{static[a371_0x3d50e6(0xd0)](_0x795baa){return String(_0x795baa)['padStart'](0x2,'0');}static[a371_0x3d50e6(0xe3)](_0x2fa7f8){const _0x3bb19d=a371_0x3d50e6,_0x4aa332=_0x2fa7f8[_0x3bb19d(0xf8)](),_0x449e20=this[_0x3bb19d(0xd0)](_0x2fa7f8[_0x3bb19d(0xf1)]()+0x1),_0x3cd848=this[_0x3bb19d(0xd0)](_0x2fa7f8[_0x3bb19d(0x116)]()),_0x51380a=this['pad'](_0x2fa7f8[_0x3bb19d(0xff)]()),_0x181da5=this['pad'](_0x2fa7f8[_0x3bb19d(0x109)]()),_0x3c8f01=this[_0x3bb19d(0xd0)](_0x2fa7f8[_0x3bb19d(0xf4)]());return{'createdAt':_0x4aa332+'-'+_0x449e20+'-'+_0x3cd848+'\x20'+_0x51380a+':'+_0x181da5+':'+_0x3c8f01,'createdDate':_0x4aa332+'-'+_0x449e20+'-'+_0x3cd848,'createdTime':_0x51380a+':'+_0x181da5+':'+_0x3c8f01};}static[a371_0x3d50e6(0xd7)](_0x444ede){const _0x107965=a371_0x3d50e6,_0x53cc45=_0x444ede[_0x107965(0x105)]('/')[_0x107965(0xfc)]()||_0x444ede;return _0x53cc45[_0x107965(0x105)]('-')['map'](_0x1a5211=>_0x1a5211[_0x107965(0x10b)](0x0)[_0x107965(0xd1)]()+_0x1a5211[_0x107965(0xe6)](0x1)[_0x107965(0xfa)]())[_0x107965(0xf9)]('');}static[a371_0x3d50e6(0x112)](_0x1b9307){const _0x389f70=a371_0x3d50e6,_0x460f6e=_0x1b9307[_0x389f70(0x105)]('/')[_0x389f70(0xfc)]()||_0x1b9307;return _0x460f6e[_0x389f70(0x105)]('-')[_0x389f70(0xd9)](_0x387424=>_0x387424[_0x389f70(0x10b)](0x0)[_0x389f70(0xd1)]()+_0x387424[_0x389f70(0xe6)](0x1)[_0x389f70(0xfa)]())['join']('\x20');}static['replaceContent'](_0x29e7d1,_0x478546,_0x300b8d){const _0x6cad7b=a371_0x3d50e6,_0x2209c5=this['toComponentName'](_0x478546),_0x57e460=this[_0x6cad7b(0x112)](_0x478546),{createdAt:_0x143656,createdDate:_0xcbdc97,createdTime:_0x2813fb}=this[_0x6cad7b(0xe3)](new Date());let _0x2452b6=_0x29e7d1[_0x6cad7b(0xcd)](/\{CliVersion\}/g,CLI_VERSION)[_0x6cad7b(0xcd)](/\{ComponentName\}/g,_0x2209c5)[_0x6cad7b(0xcd)](/\{DisplayTitle\}/g,_0x57e460)[_0x6cad7b(0xcd)](/\{PageName\}/g,_0x478546)[_0x6cad7b(0xcd)](/\{TemplateName\}/g,_0x300b8d)[_0x6cad7b(0xcd)](/\{CreatedAt\}/g,_0x143656)[_0x6cad7b(0xcd)](/\{CreatedDate\}/g,_0xcbdc97)[_0x6cad7b(0xcd)](/\{CreatedTime\}/g,_0x2813fb);return _0x2452b6;}static[a371_0x3d50e6(0xeb)](_0x3a4ae5,_0x303eaa,_0x27a416,_0x2a11f1,_0x1166d1,_0x368236,_0x2d293b,_0x296a6d,_0x37547a){const _0x324fe7=a371_0x3d50e6,_0x16554b=new Date(),_0x277a64=_0x16554b[_0x324fe7(0xe8)](),_0x106e43=_0x27a416['map'](_0x14148a=>{const _0x16522b=_0x324fe7,_0x5c90ad=[_0x16522b(0xdb)+_0x14148a[_0x16522b(0xfd)]+'\x22',_0x16522b(0x115)+_0x14148a[_0x16522b(0x107)]+'\x22',_0x16522b(0xef)+_0x14148a[_0x16522b(0xd5)]+'\x22'];return _0x14148a['alias']&&_0x5c90ad[_0x16522b(0x10c)](_0x16522b(0xf2)+_0x14148a[_0x16522b(0xfe)]+'\x22'),_0x16522b(0xe9)+_0x5c90ad[_0x16522b(0xf9)](',\x20')+_0x16522b(0xdf);})[_0x324fe7(0xf9)](''),_0x171169=_0x2a11f1||_0x27a416[0x0]?.[_0x324fe7(0xfe)]||_0x324fe7(0x104);let _0x39f3d1=_0x3a4ae5['replace'](/\{AppCode\}/g,_0x303eaa)[_0x324fe7(0xcd)](/\{ModelConfigs\}/g,_0x106e43)[_0x324fe7(0xcd)](/\{ExampleModelName\}/g,_0x171169)[_0x324fe7(0xcd)](/\{ApiFileName\}/g,_0x1166d1||'api')[_0x324fe7(0xcd)](/\{ConfigName\}/g,_0x368236||_0x324fe7(0xee))[_0x324fe7(0xcd)](/\{ClientConfigParam\}/g,_0x2d293b||'')['replace'](/\{SdkConfigFileName\}/g,_0x37547a||_0x324fe7(0xe0))['replace'](/\{VarPrefix\}/g,_0x296a6d||_0x324fe7(0xd8))['replace'](/\{CreatedAt\}/g,_0x277a64);return _0x39f3d1;}static async[a371_0x3d50e6(0xd4)](_0x2417e5,_0x7cf279,_0x2edf9f,_0x10fd5e,_0x468d88=!![]){const _0x23e699=a371_0x3d50e6,_0x4219dc=Date[_0x23e699(0xd3)]();try{_0x468d88&&logger[_0x23e699(0x111)](_0x23e699(0x114),_0x23e699(0x10d),{'templatePath':_0x2417e5,'targetPath':_0x7cf279,'pageName':_0x2edf9f,'templateName':_0x10fd5e});await a371_0x559c96['promises']['mkdir'](_0x7cf279,{'recursive':!![]}),await this[_0x23e699(0x108)](_0x2417e5,_0x7cf279,_0x2edf9f,_0x10fd5e);if(_0x468d88){const _0x3daded=Date[_0x23e699(0xd3)]()-_0x4219dc;logger[_0x23e699(0xd2)]('template',_0x23e699(0xe4),_0x3daded,{'pageName':_0x2edf9f,'templateName':_0x10fd5e});}}catch(_0x4ace83){if(_0x468d88){const _0x4a1015=Date[_0x23e699(0xd3)]()-_0x4219dc;logger[_0x23e699(0x113)](_0x23e699(0x114),'Template\x20content\x20replacement\x20failed',{'templatePath':_0x2417e5,'targetPath':_0x7cf279,'pageName':_0x2edf9f,'templateName':_0x10fd5e,'error':_0x4ace83 instanceof Error?_0x4ace83[_0x23e699(0xfb)]:String(_0x4ace83),'duration':_0x4a1015});}throw _0x4ace83;}}static async[a371_0x3d50e6(0x108)](_0x1c0311,_0x22f7eb,_0x3e554d,_0x3e2bbd){const _0x7476e2=a371_0x3d50e6,_0x263cd7=await a371_0x559c96['promises'][_0x7476e2(0xe7)](_0x1c0311,{'withFileTypes':!![]});for(const _0x3fe177 of _0x263cd7){const _0x532fdc=a371_0x978537[_0x7476e2(0xf9)](_0x1c0311,_0x3fe177['name']);let _0x52cdfc=a371_0x978537['join'](_0x22f7eb,_0x3fe177['name']);_0x3fe177[_0x7476e2(0xd5)][_0x7476e2(0xdc)](_0x7476e2(0xe2))&&(_0x52cdfc=a371_0x978537[_0x7476e2(0xf9)](_0x22f7eb,_0x3fe177['name'][_0x7476e2(0xcd)](/\.tpl$/,'')));if(_0x3fe177[_0x7476e2(0x101)]())await a371_0x559c96['promises'][_0x7476e2(0xf5)](_0x52cdfc,{'recursive':!![]}),await this[_0x7476e2(0x108)](_0x532fdc,_0x52cdfc,_0x3e554d,_0x3e2bbd);else _0x3fe177[_0x7476e2(0xe5)]()&&await this[_0x7476e2(0x10e)](_0x532fdc,_0x52cdfc,_0x3e554d,_0x3e2bbd);}}static async[a371_0x3d50e6(0x10e)](_0xc527b3,_0xb008b4,_0x3f6382,_0x2ff591){const _0xc8f616=a371_0x3d50e6,_0xdf9b0b=a371_0x978537[_0xc8f616(0x100)](_0xc527b3)[_0xc8f616(0xfa)]();_0xc527b3['endsWith'](_0xc8f616(0xe2))&&(_0xb008b4=_0xb008b4[_0xc8f616(0xcd)](/\.tpl$/,''));const _0x33ef0e=[_0xc8f616(0x110),_0xc8f616(0xe1),'.jsx',_0xc8f616(0x103),_0xc8f616(0x117),_0xc8f616(0xf7),_0xc8f616(0x106),_0xc8f616(0xf0),'.tpl'];if(_0x33ef0e[_0xc8f616(0xdd)](_0xdf9b0b)||_0xc527b3[_0xc8f616(0xdc)](_0xc8f616(0xe2))){const _0x19a1d2=await a371_0x559c96['promises'][_0xc8f616(0x10f)](_0xc527b3,_0xc8f616(0x10a)),_0xfa3f7a=this['replaceContent'](_0x19a1d2,_0x3f6382,_0x2ff591);await a371_0x559c96[_0xc8f616(0xea)][_0xc8f616(0xf6)](_0xb008b4,_0xfa3f7a,'utf8');}else await a371_0x559c96['promises']['copyFile'](_0xc527b3,_0xb008b4);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x5bcad3,_0x1c03a3){const _0x28e8e2=a372_0x1dd2,_0x1cc080=_0x5bcad3();while(!![]){try{const _0x51b8f1=-parseInt(_0x28e8e2(0x163))/0x1*(parseInt(_0x28e8e2(0x150))/0x2)+-parseInt(_0x28e8e2(0x15d))/0x3+-parseInt(_0x28e8e2(0x15b))/0x4+-parseInt(_0x28e8e2(0x158))/0x5+parseInt(_0x28e8e2(0x155))/0x6+parseInt(_0x28e8e2(0x151))/0x7*(parseInt(_0x28e8e2(0x15c))/0x8)+parseInt(_0x28e8e2(0x169))/0x9;if(_0x51b8f1===_0x1c03a3)break;else _0x1cc080['push'](_0x1cc080['shift']());}catch(_0x4ad816){_0x1cc080['push'](_0x1cc080['shift']());}}}(a372_0x1e3d,0x6598f));import{mkdir,readFile,writeFile}from'node:fs/promises';import{homedir}from'node:os';import{dirname,join}from'node:path';import a372_0x274993 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_0x1e3d(){const _0xee17d6=[',\x20run:\x20','toLowerCase','trim','5887638DKlfFy','stableVersion','lastNotifiedVersion','number','true','44WanGUc','3072643PXXzKa','yes','valid','gte','1755714PiThMa','lastNotifiedAt','now','400960XcxYLW','https://www.npmjs.com/package/','\x20available,\x20current\x20','1011424OZbpDr','8nYOEuv','1727055oEtlvO','object','.cache','latest','checkedAt','utf8','2767JzcBOW','\x20update','update-check.json'];a372_0x1e3d=function(){return _0xee17d6;};return a372_0x1e3d();}const UPDATE_CHECK_TTL_MS=0xc*0x3c*0x3c*0x3e8,UPDATE_NOTICE_TTL_MS=0x18*0x3c*0x3c*0x3e8;function isUpdateNoticeDisabled(){const _0x145e27=a372_0x1dd2,_0x1f7a2f=process.env.RABETBASE_NO_UPDATE_NOTICE?.['trim']()[_0x145e27(0x167)]();return _0x1f7a2f==='1'||_0x1f7a2f===_0x145e27(0x16d)||_0x1f7a2f===_0x145e27(0x152);}function cacheRoot(){const _0x37a136=a372_0x1dd2;return process.env.XDG_CACHE_HOME||process.env.LOCALAPPDATA||join(homedir(),_0x37a136(0x15f));}export function getUpdateNoticeCachePath(){const _0x3cc41e=a372_0x1dd2;return join(cacheRoot(),'rabetbase-cli',_0x3cc41e(0x165));}async function readUpdateNoticeCache(){const _0x40da97=a372_0x1dd2;try{const _0x4c9128=await readFile(getUpdateNoticeCachePath(),_0x40da97(0x162)),_0x5961a7=JSON['parse'](_0x4c9128);if(!_0x5961a7||typeof _0x5961a7!==_0x40da97(0x15e))return{};return _0x5961a7;}catch{return{};}}async function writeUpdateNoticeCache(_0x498430){try{const _0x561af4=getUpdateNoticeCachePath();await mkdir(dirname(_0x561af4),{'recursive':!![]}),await writeFile(_0x561af4,JSON['stringify'](_0x498430,null,0x2)+'\x0a','utf8');}catch{}}function a372_0x1dd2(_0x239e27,_0x55c335){_0x239e27=_0x239e27-0x150;const _0x1e3de2=a372_0x1e3d();let _0x1dd253=_0x1e3de2[_0x239e27];return _0x1dd253;}function isFreshCheck(_0x3891df,_0x115b44){const _0x394e34=a372_0x1dd2;return typeof _0x3891df['checkedAt']===_0x394e34(0x16c)&&_0x115b44-_0x3891df[_0x394e34(0x161)]<UPDATE_CHECK_TTL_MS;}function isRecentlyNotified(_0x469529,_0x2fcddb,_0x352e3e){const _0x82a987=a372_0x1dd2;return _0x469529[_0x82a987(0x16b)]===_0x2fcddb&&typeof _0x469529[_0x82a987(0x156)]===_0x82a987(0x16c)&&_0x352e3e-_0x469529[_0x82a987(0x156)]<UPDATE_NOTICE_TTL_MS;}export function buildNpmVersionUrl(_0x336442){const _0x4ca0fa=a372_0x1dd2;return _0x4ca0fa(0x159)+NPM_PACKAGE_NAME+'/v/'+_0x336442;}export async function resolveLatestUpdateNotice(){const _0x5bee9a=a372_0x1dd2;if(isUpdateNoticeDisabled())return null;try{const _0x538f1c=Date[_0x5bee9a(0x157)](),_0x54b88d=getCliVersion(),_0x502768=await readUpdateNoticeCache();let _0x330b24=isFreshCheck(_0x502768,_0x538f1c)?_0x502768[_0x5bee9a(0x160)]?.['trim']():undefined;if(!_0x330b24&&!isFreshCheck(_0x502768,_0x538f1c)){const _0x14de7d=await getCliVersionPolicy();_0x330b24=_0x14de7d?.[_0x5bee9a(0x16a)]?.[_0x5bee9a(0x168)]()||undefined,await writeUpdateNoticeCache({..._0x502768,'checkedAt':_0x538f1c,'latest':_0x330b24,'failed':!_0x330b24});}if(!_0x330b24||!a372_0x274993[_0x5bee9a(0x153)](_0x54b88d)||!a372_0x274993['valid'](_0x330b24))return null;if(a372_0x274993[_0x5bee9a(0x154)](_0x54b88d,_0x330b24))return null;if(isRecentlyNotified(_0x502768,_0x330b24,_0x538f1c))return null;const _0x159070=CLI_BIN_NAME+_0x5bee9a(0x164);return await writeUpdateNoticeCache({..._0x502768,'checkedAt':isFreshCheck(_0x502768,_0x538f1c)?_0x502768[_0x5bee9a(0x161)]:_0x538f1c,'latest':_0x330b24,'failed':![],'lastNotifiedVersion':_0x330b24,'lastNotifiedAt':_0x538f1c}),{'command':_0x159070,'current':_0x54b88d,'latest':_0x330b24,'url':buildNpmVersionUrl(_0x330b24),'message':CLI_BIN_NAME+'\x20'+_0x330b24+_0x5bee9a(0x15a)+_0x54b88d+_0x5bee9a(0x166)+_0x159070};}catch{return null;}}
|
package/lib/utils/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a373_0x6913(_0x5d92ed,_0x16f65a){_0x5d92ed=_0x5d92ed-0x17e;var _0x16c176=a373_0x16c1();var _0x691370=_0x16c176[_0x5d92ed];return _0x691370;}(function(_0x3a8eb9,_0x3840da){var _0x5bfbfe=a373_0x6913,_0xabfd35=_0x3a8eb9();while(!![]){try{var _0x2c8f7c=parseInt(_0x5bfbfe(0x186))/0x1+-parseInt(_0x5bfbfe(0x185))/0x2+parseInt(_0x5bfbfe(0x181))/0x3+parseInt(_0x5bfbfe(0x17f))/0x4+parseInt(_0x5bfbfe(0x180))/0x5*(parseInt(_0x5bfbfe(0x182))/0x6)+parseInt(_0x5bfbfe(0x183))/0x7*(-parseInt(_0x5bfbfe(0x17e))/0x8)+-parseInt(_0x5bfbfe(0x184))/0x9;if(_0x2c8f7c===_0x3840da)break;else _0xabfd35['push'](_0xabfd35['shift']());}catch(_0x129e29){_0xabfd35['push'](_0xabfd35['shift']());}}}(a373_0x16c1,0x47ea5));import{VERSION}from'../generated/build-info.js';export function getCliVersion(){return VERSION;}function a373_0x16c1(){var _0x273779=['1913472TgRgwR','593174yznrbT','25388KhNFyn','17016mbLegX','1762988QBoQGV','2565MnYppd','146697cSnHxt','5790eeFhbc','679uSkIZg'];a373_0x16c1=function(){return _0x273779;};return a373_0x16c1();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a374_0x1727(_0x72b8a2,_0x468541){_0x72b8a2=_0x72b8a2-0x9b;var _0x215b0d=a374_0x215b();var _0x1727d7=_0x215b0d[_0x72b8a2];return _0x1727d7;}(function(_0x2c3164,_0xb39608){var _0x5bbc1c=a374_0x1727,_0x4e0f83=_0x2c3164();while(!![]){try{var _0x1d08a7=-parseInt(_0x5bbc1c(0x9b))/0x1*(-parseInt(_0x5bbc1c(0xa2))/0x2)+parseInt(_0x5bbc1c(0xa1))/0x3+parseInt(_0x5bbc1c(0x9c))/0x4+-parseInt(_0x5bbc1c(0xa0))/0x5+-parseInt(_0x5bbc1c(0x9e))/0x6+parseInt(_0x5bbc1c(0x9d))/0x7+parseInt(_0x5bbc1c(0x9f))/0x8;if(_0x1d08a7===_0xb39608)break;else _0x4e0f83['push'](_0x4e0f83['shift']());}catch(_0x311116){_0x4e0f83['push'](_0x4e0f83['shift']());}}}(a374_0x215b,0x9a1a3));import{setActiveCookie,clearActiveCookie}from'../core/api-client.js';export async function withActiveCookie(_0x4f74a9,_0x20c9e0){setActiveCookie(_0x4f74a9);try{return await _0x20c9e0();}finally{clearActiveCookie();}}function a374_0x215b(){var _0x5bc26b=['604653CLWOac','2393784MBqmLu','4150432Hlzqik','5130885TtTZiO','2887809Bpnkjb','2EAKNhz','424828ZtwKuB','254920qLAqfS'];a374_0x215b=function(){return _0x5bc26b;};return a374_0x215b();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a375_0x27c1(){var _0x4bcb7a=['2068641ItmMHf','2740480bPNAGg','737947WoVQDc','70748IQxjCf','85ZsbkMQ','14xiNKlQ','92495unTTcQ','32VMZnxD','488325LuKVLx','3053814MkaWCX'];a375_0x27c1=function(){return _0x4bcb7a;};return a375_0x27c1();}function a375_0x585b(_0x30e3f2,_0x302638){_0x30e3f2=_0x30e3f2-0xd9;var _0x27c11e=a375_0x27c1();var _0x585b34=_0x27c11e[_0x30e3f2];return _0x585b34;}(function(_0x182cc7,_0x9cc80d){var _0x539ffe=a375_0x585b,_0x373d58=_0x182cc7();while(!![]){try{var _0x52caed=-parseInt(_0x539ffe(0xd9))/0x1*(-parseInt(_0x539ffe(0xe2))/0x2)+-parseInt(_0x539ffe(0xdb))/0x3+-parseInt(_0x539ffe(0xe0))/0x4*(-parseInt(_0x539ffe(0xe1))/0x5)+-parseInt(_0x539ffe(0xdc))/0x6+-parseInt(_0x539ffe(0xdf))/0x7*(parseInt(_0x539ffe(0xda))/0x8)+parseInt(_0x539ffe(0xdd))/0x9+parseInt(_0x539ffe(0xde))/0xa;if(_0x52caed===_0x9cc80d)break;else _0x373d58['push'](_0x373d58['shift']());}catch(_0x52ecdf){_0x373d58['push'](_0x373d58['shift']());}}}(a375_0x27c1,0x578d5));export function writeCliSideChannelLine(_0x4b84d6){process['stderr']['write'](_0x4b84d6+'\x0a');}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lovrabet/rabetbase-cli",
|
|
3
|
-
"version": "2.5.10-beta.
|
|
3
|
+
"version": "2.5.10-beta.5",
|
|
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": [
|
|
@@ -98,9 +98,9 @@
|
|
|
98
98
|
],
|
|
99
99
|
"dependencies": {
|
|
100
100
|
"@inquirer/prompts": "^8.3.2",
|
|
101
|
-
"@lovrabet/cli-framework": "1.0.
|
|
102
|
-
"@lovrabet/otel-logger": "1.0.1
|
|
103
|
-
"@lovrabet/sdk": "1.6.1
|
|
101
|
+
"@lovrabet/cli-framework": "1.0.10",
|
|
102
|
+
"@lovrabet/otel-logger": "1.0.1",
|
|
103
|
+
"@lovrabet/sdk": "1.6.1",
|
|
104
104
|
"@opentelemetry/api": "^1.9.1",
|
|
105
105
|
"chalk": "^5.6.2",
|
|
106
106
|
"execa": "^9.6.0",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: rabetbase
|
|
3
|
-
version: 2.5.10-beta.
|
|
3
|
+
version: 2.5.10-beta.5
|
|
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.10-beta.
|
|
6
|
-
"skillVersion": "2.5.10-beta.
|
|
5
|
+
"packageVersion": "2.5.10-beta.5",
|
|
6
|
+
"skillVersion": "2.5.10-beta.5",
|
|
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": "86a8538bb6d30613c4aa70cf3f3ca77ad0c2b9b3f8799e61d6023f1707fe24ae"
|
|
163
163
|
}
|