@lovrabet/rabetbase-cli 2.5.4-beta.3 → 2.5.4-beta.4
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/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/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/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/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/index.js +1 -1
- package/lib/commands/issue/nudge.js +1 -1
- package/lib/commands/issue/report.js +1 -1
- package/lib/commands/issue/shared.js +1 -1
- package/lib/commands/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/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/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.d.ts +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-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/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/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/telemetry/send-platform-issue-collect-log.js +1 -1
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/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 +2 -2
- package/skills/rabetbase/references/rabetbase-user-account.md +8 -8
- package/skills/rabetbase.manifest.json +3 -3
package/lib/api/api-doc.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a0_0x7d17a9=a0_0x59b0;(function(_0x24f18a,_0x4ab22e){const _0x2a796e=a0_0x59b0,_0x4004cd=_0x24f18a();while(!![]){try{const _0x3c4eb6=-parseInt(_0x2a796e(0x16a))/0x1+parseInt(_0x2a796e(0x16f))/0x2*(parseInt(_0x2a796e(0x158))/0x3)+-parseInt(_0x2a796e(0x159))/0x4+-parseInt(_0x2a796e(0x167))/0x5*(-parseInt(_0x2a796e(0x165))/0x6)+-parseInt(_0x2a796e(0x154))/0x7*(parseInt(_0x2a796e(0x156))/0x8)+-parseInt(_0x2a796e(0x15e))/0x9+parseInt(_0x2a796e(0x16d))/0xa;if(_0x3c4eb6===_0x4ab22e)break;else _0x4004cd['push'](_0x4004cd['shift']());}catch(_0x449f45){_0x4004cd['push'](_0x4004cd['shift']());}}}(a0_0x192b,0x9aa5c));import{mkdirSync,writeFileSync}from'node:fs';import a0_0x2255ac from'node:path';import{fetchDatasetDoc}from'../core/api-client.js';function a0_0x59b0(_0x1c3f2b,_0x4d3a3a){_0x1c3f2b=_0x1c3f2b-0x153;const _0x192b80=a0_0x192b();let _0x59b0b4=_0x192b80[_0x1c3f2b];return _0x59b0b4;}import{logger}from'../utils/logger.js';export{fetchDatasetDoc}from'../core/api-client.js';function a0_0x192b(){const _0x381b5d=['572744VzfQah','log','push','.md','475062qjUcWW','datasetCode','16Nubivl','./docs','9ZvevBy','945972PeviGO','Generated\x20docs\x20successfully:\x20','join','success',']\x20Generating:\x20','9397773blkPnb','error','length','tableName','utf8','message','✗\x20Failed:\x20','7554njnMuS','Waiting\x203\x20seconds...\x0a','1880eomvYW','✓\x20Generated:\x20','.md\x20(','16404KlZaZP','.md\x20-\x20','name','7337620eRUwTc','api-doc'];a0_0x192b=function(){return _0x381b5d;};return a0_0x192b();}function delay(_0x5b197d){return new Promise(_0x3d47aa=>setTimeout(_0x3d47aa,_0x5b197d));}export async function generateDatasetDocs(_0x54d729,_0x4d1475,_0x4ad824,_0x418a06=a0_0x7d17a9(0x157),_0x268f75,_0xac3db1){const _0x283019=a0_0x7d17a9;mkdirSync(_0x418a06,{'recursive':!![]});const _0x27af8f=[],_0x37bb0b=_0x54d729[_0x283019(0x160)];console[_0x283019(0x170)]('\x0a'+_0x37bb0b+'\x20datasets\x20to\x20generate\x20docs\x20for\x0a');for(let _0x159138=0x0;_0x159138<_0x54d729[_0x283019(0x160)];_0x159138++){const _0x45ea82=_0x54d729[_0x159138],_0x338a11=_0x159138+0x1,_0x2f381d=_0x45ea82[_0x283019(0x161)];try{console['log']('['+_0x338a11+'/'+_0x37bb0b+_0x283019(0x15d)+_0x2f381d+_0x283019(0x169)+_0x45ea82[_0x283019(0x16c)]+')');if(_0x268f75)_0x268f75(_0x338a11,_0x37bb0b,_0x2f381d);const _0x3bbd3d=await fetchDatasetDoc({'appCode':_0x4d1475,'cookie':_0x4ad824,'datasetCode':_0x45ea82['datasetCode'],'datasetId':_0x45ea82['id'],'enableAI':![],'extraParams':_0xac3db1}),_0x3f9c63=a0_0x2255ac[_0x283019(0x15b)](_0x418a06,_0x2f381d+'.md');writeFileSync(_0x3f9c63,_0x3bbd3d,{'encoding':_0x283019(0x162)}),console[_0x283019(0x170)](_0x283019(0x168)+_0x2f381d+_0x283019(0x153)),logger[_0x283019(0x15c)](_0x283019(0x16e),_0x283019(0x15a)+_0x2f381d,undefined,{'datasetCode':_0x45ea82[_0x283019(0x155)],'datasetName':_0x45ea82[_0x283019(0x16c)],'filePath':_0x3f9c63,'progress':_0x338a11+'/'+_0x37bb0b}),_0x27af8f['push']({'datasetCode':_0x45ea82[_0x283019(0x155)],'datasetName':_0x45ea82[_0x283019(0x16c)],'filePath':_0x3f9c63,'success':!![]});if(_0x338a11<_0x37bb0b)await delay(0x1388);}catch(_0xa292f9){const _0x185d50=_0xa292f9 instanceof Error?_0xa292f9[_0x283019(0x163)]:String(_0xa292f9);console[_0x283019(0x170)](_0x283019(0x164)+_0x2f381d+_0x283019(0x16b)+_0x185d50),logger[_0x283019(0x15f)](_0x283019(0x16e),'Failed\x20to\x20generate\x20docs:\x20'+_0x45ea82[_0x283019(0x155)],{'datasetCode':_0x45ea82[_0x283019(0x155)],'datasetName':_0x45ea82[_0x283019(0x16c)],'error':_0x185d50,'progress':_0x338a11+'/'+_0x37bb0b}),_0x27af8f[_0x283019(0x171)]({'datasetCode':_0x45ea82[_0x283019(0x155)],'datasetName':_0x45ea82['name'],'filePath':'','success':![],'error':_0x185d50}),_0x338a11<_0x37bb0b&&(console['log'](_0x283019(0x166)),await delay(0xbb8));}}return _0x27af8f;}
|
package/lib/api/api-group.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a1_0x42c802=a1_0x118e;(function(_0x5784e6,_0x3ee785){const _0x433105=a1_0x118e,_0x1d648d=_0x5784e6();while(!![]){try{const _0x26a808=-parseInt(_0x433105(0x128))/0x1*(-parseInt(_0x433105(0x121))/0x2)+-parseInt(_0x433105(0x11d))/0x3*(parseInt(_0x433105(0x12f))/0x4)+-parseInt(_0x433105(0x124))/0x5*(-parseInt(_0x433105(0x116))/0x6)+parseInt(_0x433105(0x12b))/0x7+-parseInt(_0x433105(0x118))/0x8+-parseInt(_0x433105(0x12a))/0x9+parseInt(_0x433105(0x131))/0xa*(-parseInt(_0x433105(0x114))/0xb);if(_0x26a808===_0x3ee785)break;else _0x1d648d['push'](_0x1d648d['shift']());}catch(_0x4cb6bb){_0x1d648d['push'](_0x1d648d['shift']());}}}(a1_0x5236,0x7c7ad));import a1_0x268e09 from'node:path';function a1_0x118e(_0x36f442,_0x26a13f){_0x36f442=_0x36f442-0x114;const _0x52363d=a1_0x5236();let _0x118eff=_0x52363d[_0x36f442];return _0x118eff;}function a1_0x5236(){const _0x33231b=['trim','name','106599EMQhlJ','add','normalizedApiDir','map','2HQzovi','set','.\x20Use\x20a\x20different\x20apiDir\x20for\x20a\x20separate\x20API.','2780VLITbM','size','API\x20group\x20\x22','get','65271iEZWAa','cwd','2315745YaRcxE','3026359xbVnuo','validation','flatMap','resolve','24tavtMw','join','289900LZhMuU','values','some','33mdoyuH','outputDir','10272wVahuM','apiGroup','3057104nuZzFk','filter','push'];a1_0x5236=function(){return _0x33231b;};return a1_0x5236();}import{CliErrors}from'../errors.js';export function normalizeApiDir(_0x435cad,_0x2d0fe7=process['cwd']()){const _0x589de7=a1_0x118e;return a1_0x268e09[_0x589de7(0x12e)](_0x2d0fe7,_0x435cad);}function normalizedApiGroup(_0x5e62ca){const _0x5c35bc=a1_0x118e,_0x37680d=_0x5e62ca?.[_0x5c35bc(0x11b)]();return _0x37680d||undefined;}export function resolveApiProfileLayouts(_0xf2bd99,_0x7b693b,_0x9b327=process[a1_0x42c802(0x129)]()){const _0x814a9=a1_0x42c802,_0x5a6b1c=_0xf2bd99[_0x814a9(0x120)](_0x5a7b64=>{const _0x22cdae=_0x814a9,_0x113438=_0x7b693b(_0x5a7b64);return{'app':_0x5a7b64,'outputDir':_0x113438,'normalizedApiDir':normalizeApiDir(_0x113438,_0x9b327),'apiGroup':normalizedApiGroup(_0x5a7b64[_0x22cdae(0x117)])};}),_0x9c7646=new Map();for(const _0x445cb2 of _0x5a6b1c){if(!_0x445cb2[_0x814a9(0x117)])continue;const _0x4e1fc9=_0x9c7646['get'](_0x445cb2[_0x814a9(0x117)])??new Set();_0x4e1fc9[_0x814a9(0x11e)](_0x445cb2[_0x814a9(0x11f)]),_0x9c7646[_0x814a9(0x122)](_0x445cb2[_0x814a9(0x117)],_0x4e1fc9);}for(const [_0x263a9a,_0x3f60e0]of _0x9c7646){if(_0x3f60e0[_0x814a9(0x125)]>0x1)throw CliErrors[_0x814a9(0x12c)](_0x814a9(0x126)+_0x263a9a+'\x22\x20resolves\x20to\x20multiple\x20API\x20directories.','Profiles\x20in\x20the\x20same\x20API\x20group\x20must\x20use\x20the\x20same\x20apiDir.');}const _0x28a66f=new Map();for(const _0x427cfb of _0x5a6b1c){const _0x360211=_0x28a66f[_0x814a9(0x127)](_0x427cfb['normalizedApiDir'])??[];_0x360211[_0x814a9(0x11a)](_0x427cfb),_0x28a66f['set'](_0x427cfb[_0x814a9(0x11f)],_0x360211);}for(const _0x1b7f7f of _0x28a66f[_0x814a9(0x132)]()){const _0x6af7f0=new Set(_0x1b7f7f[_0x814a9(0x12d)](_0x499256=>_0x499256[_0x814a9(0x117)]?[_0x499256[_0x814a9(0x117)]]:[]));if(_0x6af7f0[_0x814a9(0x125)]===0x0)continue;if(_0x6af7f0[_0x814a9(0x125)]>0x1||_0x1b7f7f[_0x814a9(0x133)](_0x2aca10=>!_0x2aca10[_0x814a9(0x117)])){const _0x376cfa=_0x1b7f7f['map'](_0x322ad9=>_0x322ad9['app'][_0x814a9(0x11c)])[_0x814a9(0x130)](',\x20');throw CliErrors['validation']('API\x20directory\x20\x22'+_0x1b7f7f[0x0][_0x814a9(0x115)]+'\x22\x20is\x20assigned\x20to\x20incompatible\x20API\x20groups.','Profiles\x20sharing\x20one\x20apiDir\x20must\x20use\x20the\x20same\x20explicit\x20apiGroup.\x20Conflicting\x20profiles:\x20'+_0x376cfa+_0x814a9(0x123));}}return _0x5a6b1c;}export function getRegistryGroup(_0x522e25,_0x41a6c7){const _0x2010c6=a1_0x42c802;if(_0x41a6c7[_0x2010c6(0x117)])return _0x522e25[_0x2010c6(0x119)](_0x2976a7=>_0x2976a7[_0x2010c6(0x117)]===_0x41a6c7[_0x2010c6(0x117)]);const _0xe95912=_0x522e25[_0x2010c6(0x119)](_0x582fb7=>_0x582fb7[_0x2010c6(0x11f)]===_0x41a6c7[_0x2010c6(0x11f)]);return _0xe95912['length']===0x1?_0xe95912:undefined;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a2_0x1640(){var _0x2915cc=['6GTXjIj','98DCQgDA','641750OteEdx','239913EVNlLW','627319cSCgSo','1608472CPWxNl','196902nCfiQq','12BLhygF','1782635zqgVKV','8054lasfcp'];a2_0x1640=function(){return _0x2915cc;};return a2_0x1640();}function a2_0x2d9e(_0xe9691b,_0x839246){_0xe9691b=_0xe9691b-0x82;var _0x16409a=a2_0x1640();var _0x2d9e14=_0x16409a[_0xe9691b];return _0x2d9e14;}(function(_0x2c44e2,_0x59b230){var _0x3fd392=a2_0x2d9e,_0xb2ae90=_0x2c44e2();while(!![]){try{var _0x3ef93d=parseInt(_0x3fd392(0x88))/0x1*(-parseInt(_0x3fd392(0x8a))/0x2)+parseInt(_0x3fd392(0x82))/0x3*(parseInt(_0x3fd392(0x86))/0x4)+parseInt(_0x3fd392(0x87))/0x5+parseInt(_0x3fd392(0x89))/0x6*(-parseInt(_0x3fd392(0x83))/0x7)+parseInt(_0x3fd392(0x84))/0x8+-parseInt(_0x3fd392(0x85))/0x9+-parseInt(_0x3fd392(0x8b))/0xa;if(_0x3ef93d===_0x59b230)break;else _0xb2ae90['push'](_0xb2ae90['shift']());}catch(_0x1aed95){_0xb2ae90['push'](_0xb2ae90['shift']());}}}(a2_0x1640,0x3776f));export{fetchModelList}from'../core/api-client.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x8e59cc,_0x31a752){const _0x2d93b2=a3_0x50a7,_0x4761f9=_0x8e59cc();while(!![]){try{const _0x52d900=-parseInt(_0x2d93b2(0x166))/0x1+parseInt(_0x2d93b2(0x173))/0x2*(-parseInt(_0x2d93b2(0x18c))/0x3)+-parseInt(_0x2d93b2(0x181))/0x4*(-parseInt(_0x2d93b2(0x17e))/0x5)+-parseInt(_0x2d93b2(0x15d))/0x6*(-parseInt(_0x2d93b2(0x156))/0x7)+parseInt(_0x2d93b2(0x169))/0x8*(parseInt(_0x2d93b2(0x162))/0x9)+parseInt(_0x2d93b2(0x179))/0xa+parseInt(_0x2d93b2(0x152))/0xb;if(_0x52d900===_0x31a752)break;else _0x4761f9['push'](_0x4761f9['shift']());}catch(_0xda1159){_0x4761f9['push'](_0x4761f9['shift']());}}}(a3_0x363d,0x3fed2));import a3_0xa81ef3 from'prettier';import{existsSync,mkdirSync,writeFileSync,readFileSync}from'node:fs';import a3_0x413515 from'node:path';import{fileURLToPath}from'node:url';import{TemplateReplacer}from'../utils/template-replacer.js';import{CLI_BIN_NAME}from'../constant/cli.js';function a3_0x363d(){const _0x44768f=['dirname','toUpperCase','modelRuntime','test','key','scaffoldMode','init-api','created','93fiqexy','path','resolve','preserved','-api','format','refreshed','1329438YoRfeQ','basename','modelProfile','templates/generate-api','124481ZHqktK','LOVRABET_RUNTIME_DOMAIN','\x20config\x20set\x20app\x20<value>`','includes','missing','tableName','typescript','18Prkaku','utf8','allowEmptyModelReplacement','API\x20scaffold\x20written.','success','91620AiBQxT','api.ts.tpl','stringify','runtimeDomain','432500sdCcKM','\x20refreshed;\x20existing\x20TypeScript\x20left\x20unchanged.','length','168TzpkRV','none','join','APP_','Model\x20facts\x20refreshed.','../..','defaultName','client.ts.tpl','LOVRABET','name','21824UeKEhP','overwritten','.ts','action','default','{\x20apiConfigName:\x20','1313620TxGZzp',',\x20env:\x20','client','-client','alias','25dzOtFJ','api','datasetCode','410612skgJuM','replace','replaceApiContent'];a3_0x363d=function(){return _0x44768f;};return a3_0x363d();}import{logger}from'../utils/logger.js';function a3_0x50a7(_0x1477d6,_0x5bfdb0){_0x1477d6=_0x1477d6-0x14d;const _0x363dca=a3_0x363d();let _0x50a70f=_0x363dca[_0x1477d6];return _0x50a70f;}import{isProduction}from'../constant/env.js';import{generateSdkConfigFile}from'../api/generate-sdk-config-file.js';import{MODEL_REGISTRY_FILE_NAME,MODEL_RUNTIME_FILE_NAME,updateModelRegistry}from'../api/model-registry-file.js';import{renderModelRegistryScaffold}from'../api/model-registry-scaffold.js';function fileAction(_0x4b775e,_0x340077){const _0x44ec34=a3_0x50a7;if(!_0x340077)return _0x4b775e?_0x44ec34(0x14e):_0x44ec34(0x15a);return _0x4b775e?_0x44ec34(0x174):_0x44ec34(0x18b);}export async function generateApiFile(_0x2af113,_0x2f1e1a,_0x1500ec,_0x1ebcac,_0x18f0a2,_0x5ba831,_0x5baa32,_0x2133e0={},_0x3cb135={}){const _0x5b6b81=a3_0x50a7;if(!_0x1500ec)throw new Error('Please\x20configure\x20app\x20code\x20first\x20via\x20`'+CLI_BIN_NAME+_0x5b6b81(0x158));const _0x421b79=_0x1ebcac&&!_0x5baa32,_0x5ac123=!!_0x3cb135[_0x5b6b81(0x154)],_0x4c8dc3=_0x5ac123||_0x421b79,_0x4fa8f4=_0x5baa32||_0x1500ec,_0x90586a=_0x5ac123||_0x421b79?_0x5b6b81(0x177):_0x4fa8f4,_0x5b9abe=_0x5ac123||_0x421b79?'CONFIG_NAMES.DEFAULT':JSON[_0x5b6b81(0x164)](_0x4fa8f4),_0x2ee428=!isProduction(_0x18f0a2),_0x3f4664=_0x2ee428?_0x5b6b81(0x17a)+JSON['stringify'](_0x18f0a2):'',_0x2df6c2=_0x5b6b81(0x178)+_0x5b9abe+_0x3f4664+',\x20...LOVRABET_SDK_CONFIG\x20}',_0x5ff12b=_0x5ac123?'':_0x2f1e1a,_0x365711=_0x5ff12b?_0x5ff12b+_0x5b6b81(0x14f):'api',_0x5ab8c2=_0x5ff12b?_0x5ff12b+_0x5b6b81(0x17c):'client',_0x4af7d3=_0x5ff12b&&!/^app-[a-f0-9]+$/i['test'](_0x5ff12b)?_0x5ff12b[_0x5b6b81(0x182)](/-/g,'_')[_0x5b6b81(0x185)]():_0x5b6b81(0x171),_0x303875=/^\d/[_0x5b6b81(0x187)](_0x4af7d3)?_0x5b6b81(0x16c)+_0x4af7d3:_0x4af7d3,_0x57014f=_0x2af113['map'](_0x4ff797=>({'datasetCode':_0x4ff797[_0x5b6b81(0x180)],'tableName':_0x4ff797[_0x5b6b81(0x15b)],'name':_0x4ff797[_0x5b6b81(0x172)]||'','alias':_0x4ff797['alias']||_0x4ff797[_0x5b6b81(0x188)]})),_0x49fd22=fileURLToPath(import.meta.url),_0x10f1d7=a3_0x413515[_0x5b6b81(0x14d)](a3_0x413515[_0x5b6b81(0x184)](_0x49fd22),_0x5b6b81(0x16e)),_0x5146d9=a3_0x413515[_0x5b6b81(0x16b)](_0x10f1d7,_0x5b6b81(0x155)),_0x3f1ec4=a3_0x413515[_0x5b6b81(0x16b)](_0x5146d9,_0x5b6b81(0x163)),_0x275e5a=a3_0x413515[_0x5b6b81(0x16b)](_0x5146d9,_0x5b6b81(0x170)),_0x3f961a=_0x5ba831;mkdirSync(_0x3f961a,{'recursive':!![]});const _0x87e19d=_0x5ac123?{}:_0x2133e0,_0x2afa6a=await generateSdkConfigFile(_0x3f961a,_0x87e19d,_0x5ff12b),_0x4b6a6d=a3_0x413515[_0x5b6b81(0x153)](_0x2afa6a,_0x5b6b81(0x175)),_0x3a9127=a3_0x413515[_0x5b6b81(0x16b)](_0x3f961a,_0x365711+_0x5b6b81(0x175)),_0x58574b=a3_0x413515[_0x5b6b81(0x16b)](_0x3f961a,_0x5ab8c2+_0x5b6b81(0x175)),_0xc6a30e=_0x3cb135['overwriteTypescript']===!![],_0x7ba2a0=existsSync(_0x3a9127),_0x76c527=existsSync(_0x58574b),_0xff19a4=_0x3cb135[_0x5b6b81(0x189)]??(_0xc6a30e?'replace':_0x5b6b81(0x15a)),_0x56ea0e=_0xff19a4===_0x5b6b81(0x182)||_0xff19a4===_0x5b6b81(0x15a)&&!_0x7ba2a0,_0x198bec=_0xff19a4===_0x5b6b81(0x182)||_0xff19a4===_0x5b6b81(0x15a)&&!_0x76c527,_0x4714be=_0x3cb135[_0x5b6b81(0x154)]?updateModelRegistry({'outputDir':_0x3f961a,'profileName':_0x3cb135['modelProfile']['name'],'defaultProfile':_0x3cb135[_0x5b6b81(0x154)][_0x5b6b81(0x16f)],'appCode':_0x1500ec,'runtimeDomain':_0x3cb135['modelProfile'][_0x5b6b81(0x165)],'models':_0x57014f,'allowEmptyReplacement':_0x3cb135[_0x5b6b81(0x15f)]===!![]}):undefined,_0x18c43b=_0x4714be?a3_0x413515[_0x5b6b81(0x16b)](_0x3f961a,MODEL_RUNTIME_FILE_NAME):undefined,_0x23654e=_0x18c43b?existsSync(_0x18c43b):![],_0x2e24c1=_0x5ac123&&_0xff19a4!==_0x5b6b81(0x16a)?await renderModelRegistryScaffold(_0x3f961a):undefined;_0x18c43b&&_0x2e24c1&&writeFileSync(_0x18c43b,_0x2e24c1[_0x5b6b81(0x186)],'utf8');const _0x152295=_0x57014f[0x0]?.[_0x5b6b81(0x17d)];if(_0x56ea0e){const _0x1405a3=_0x2e24c1?.[_0x5b6b81(0x17f)]??readFileSync(_0x3f1ec4,'utf8'),_0xa6b9b4=_0x5ac123?_0x1405a3:TemplateReplacer[_0x5b6b81(0x183)](_0x1405a3,_0x1500ec,_0x57014f,_0x152295,_0x365711,_0x5b9abe,undefined,_0x303875);writeFileSync(_0x3a9127,await a3_0xa81ef3[_0x5b6b81(0x150)](_0xa6b9b4,{'parser':_0x5b6b81(0x15c)}),{'encoding':'utf8'});}if(_0x198bec){const _0x184ca7=_0x2e24c1?.[_0x5b6b81(0x17b)]??readFileSync(_0x275e5a,'utf8'),_0x1195c9=_0x5ac123?_0x184ca7:TemplateReplacer[_0x5b6b81(0x183)](_0x184ca7,_0x1500ec,_0x57014f,_0x152295,_0x365711,_0x5b9abe,_0x2df6c2,_0x303875,_0x4b6a6d);writeFileSync(_0x58574b,await a3_0xa81ef3['format'](_0x1195c9,{'parser':_0x5b6b81(0x15c)}),{'encoding':_0x5b6b81(0x15e)});}const _0x45cb47=_0x57014f[_0x5b6b81(0x168)],_0x5dce9f={'api':{'path':_0x3a9127,'action':fileAction(_0x7ba2a0,_0x56ea0e)},'client':{'path':_0x58574b,'action':fileAction(_0x76c527,_0x198bec)},'sdkConfig':{'path':_0x2afa6a,'action':_0x5b6b81(0x151)},..._0x4714be?{'modelRegistry':{'path':_0x4714be[_0x5b6b81(0x18d)],'action':_0x4714be['existed']?_0x5b6b81(0x151):'created'},'modelRuntime':{'path':_0x18c43b,'action':_0x2e24c1?_0x23654e?_0x5b6b81(0x151):_0x5b6b81(0x18b):_0x23654e?'preserved':_0x5b6b81(0x15a)}}:{}},_0xf00b64=existsSync(_0x3a9127)&&readFileSync(_0x3a9127,_0x5b6b81(0x15e))[_0x5b6b81(0x159)](MODEL_REGISTRY_FILE_NAME[_0x5b6b81(0x182)](_0x5b6b81(0x175),'')),_0x448379=existsSync(_0x58574b)&&readFileSync(_0x58574b,_0x5b6b81(0x15e))[_0x5b6b81(0x159)](_0x5b6b81(0x157)),_0x2002c9=_0x5ac123?!_0xf00b64||!_0x448379||!existsSync(_0x18c43b):![],_0x5f15a6=_0x5ac123?_0x2002c9:_0x5dce9f[_0x5b6b81(0x17f)][_0x5b6b81(0x176)]===_0x5b6b81(0x14e)||_0x5dce9f[_0x5b6b81(0x17b)][_0x5b6b81(0x176)]===_0x5b6b81(0x14e);return logger[_0x5b6b81(0x161)](_0x5b6b81(0x18a),_0x5f15a6?a3_0x413515['basename'](_0x2afa6a)+_0x5b6b81(0x167):_0x5ac123?_0x5b6b81(0x16d):_0x5b6b81(0x160),undefined,{'apiFile':_0x3a9127,'clientFile':_0x58574b,'sdkConfig':_0x2afa6a,'modelCount':_0x45cb47,'configName':_0x90586a,'isDefaultConfig':_0x4c8dc3,'needsAgentMerge':_0x5f15a6,'needsProjectUpgrade':_0x2002c9,'files':_0x5dce9f}),{'appCode':_0x1500ec,'modelCount':_0x45cb47,'models':_0x57014f,'apiFilePath':_0x3a9127,'clientFilePath':_0x58574b,'sdkConfigPath':_0x2afa6a,'modelRegistryPath':_0x4714be?.[_0x5b6b81(0x18d)],'modelRuntimePath':_0x18c43b,'modelProfile':_0x3cb135[_0x5b6b81(0x154)]?.[_0x5b6b81(0x172)],'configName':_0x90586a,'isDefaultConfig':_0x4c8dc3,'sdkRouting':_0x87e19d,'files':_0x5dce9f,'needsAgentMerge':_0x5f15a6,'needsProjectUpgrade':_0x2002c9};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a4_0x1df01c=a4_0x3588;(function(_0x5e079f,_0x5416b3){const _0x11b995=a4_0x3588,_0x40f333=_0x5e079f();while(!![]){try{const _0x1551ee=-parseInt(_0x11b995(0xfe))/0x1+-parseInt(_0x11b995(0xf7))/0x2*(parseInt(_0x11b995(0xef))/0x3)+parseInt(_0x11b995(0xfb))/0x4+-parseInt(_0x11b995(0xf4))/0x5+-parseInt(_0x11b995(0xf3))/0x6+-parseInt(_0x11b995(0xfd))/0x7+parseInt(_0x11b995(0xec))/0x8;if(_0x1551ee===_0x5416b3)break;else _0x40f333['push'](_0x40f333['shift']());}catch(_0x1dd5e5){_0x40f333['push'](_0x40f333['shift']());}}}(a4_0x49fe,0x7eeb5));import{mkdirSync,writeFileSync}from'node:fs';function a4_0x49fe(){const _0x1a6272=['format','push','runtimeDomain','2044914kqpLtk','143505YLsiei','typescript','join','838388UAUKlE','{\x0a\x20\x20','-sdk-config.ts','/**\x0a\x20*\x20Lovrabet\x20SDK\x20runtime\x20routing.\x0a\x20*\x20Generated\x20by\x20Rabetbase\x20CLI.\x20Do\x20not\x20add\x20credentials\x20to\x20this\x20file.\x0a\x20*/\x0aexport\x20const\x20LOVRABET_SDK_CONFIG\x20=\x20','3955396DLxhTn','sdk-config.ts','1836429IpfxkI','219441mTDbCT','6412112fcJmIC','runtimeDomain:\x20','utf8','3PAfJOj'];a4_0x49fe=function(){return _0x1a6272;};return a4_0x49fe();}function a4_0x3588(_0x2b9321,_0x547187){_0x2b9321=_0x2b9321-0xec;const _0x49fe72=a4_0x49fe();let _0x358870=_0x49fe72[_0x2b9321];return _0x358870;}import a4_0x5c172c from'node:path';import a4_0xa12c06 from'prettier';export const SDK_CONFIG_FILE_NAME=a4_0x1df01c(0xfc);export function getSdkConfigFileName(_0x3daace=''){const _0x4ab600=a4_0x1df01c;return _0x3daace?_0x3daace+_0x4ab600(0xf9):SDK_CONFIG_FILE_NAME;}export async function generateSdkConfigFile(_0x3026ad,_0x580b31={},_0x3051df=''){const _0x33ae76=a4_0x1df01c,_0x8d920e=[];_0x580b31[_0x33ae76(0xf2)]&&_0x8d920e[_0x33ae76(0xf1)](_0x33ae76(0xed)+JSON['stringify'](_0x580b31[_0x33ae76(0xf2)]));const _0x367579=_0x8d920e['length']>0x0?_0x33ae76(0xf8)+_0x8d920e['join'](',\x0a\x20\x20')+',\x0a}':'{}',_0x4652d3=_0x33ae76(0xfa)+_0x367579+'\x20as\x20const;\x0a';mkdirSync(_0x3026ad,{'recursive':!![]});const _0x15f96e=a4_0x5c172c[_0x33ae76(0xf6)](_0x3026ad,getSdkConfigFileName(_0x3051df));return writeFileSync(_0x15f96e,await a4_0xa12c06[_0x33ae76(0xf0)](_0x4652d3,{'parser':_0x33ae76(0xf5)}),_0x33ae76(0xee)),_0x15f96e;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x4e9226,_0x4ae82a){const _0x547df5=a5_0x55f1,_0x4bcd7d=_0x4e9226();while(!![]){try{const _0x24350a=parseInt(_0x547df5(0xc1))/0x1*(-parseInt(_0x547df5(0xbd))/0x2)+parseInt(_0x547df5(0xb6))/0x3+-parseInt(_0x547df5(0xc5))/0x4+-parseInt(_0x547df5(0xb3))/0x5*(parseInt(_0x547df5(0xbb))/0x6)+parseInt(_0x547df5(0xc3))/0x7*(parseInt(_0x547df5(0xc7))/0x8)+parseInt(_0x547df5(0xc9))/0x9+-parseInt(_0x547df5(0xb9))/0xa*(-parseInt(_0x547df5(0xb5))/0xb);if(_0x24350a===_0x4ae82a)break;else _0x4bcd7d['push'](_0x4bcd7d['shift']());}catch(_0x27c0ed){_0x4bcd7d['push'](_0x4bcd7d['shift']());}}}(a5_0x2481,0x42a0e));export function parseLegacyApiModels(_0x5bc32c){const _0x130612=a5_0x55f1,_0x3d6956=[],_0x3eae03=/\{\s*datasetCode:\s*"([^"]+)"\s*,\s*tableName:\s*"([^"]+)"\s*,\s*name:\s*"([^"]*?)"\s*,\s*alias:\s*"([^"]+)"\s*,?\s*\}/g;let _0xed7f3;while((_0xed7f3=_0x3eae03['exec'](_0x5bc32c))!==null){_0x3d6956[_0x130612(0xbe)]({'datasetCode':_0xed7f3[0x1],'tableName':_0xed7f3[0x2],'name':_0xed7f3[0x3],'alias':_0xed7f3[0x4]});}return _0x3d6956;}export function parseLegacyApiAppCode(_0x1fe6cf){const _0x6bf4d7=a5_0x55f1;return _0x1fe6cf[_0x6bf4d7(0xc6)](/export\s+const\s+[A-Z0-9_]*APP_CODE(?:\s*:\s*string)?\s*=\s*["']([^"']+)["']/)?.[0x1];}function stripComments(_0x32e57e){const _0x30c0f6=a5_0x55f1;return _0x32e57e[_0x30c0f6(0xc2)](/\/\*[\s\S]*?\*\//g,'')[_0x30c0f6(0xc2)](/\/\/.*$/gm,'');}export function isLegacyGeneratedApiScaffold(_0x1a3b60){const _0x11bf77=a5_0x55f1;if(!_0x1a3b60[_0x11bf77(0xb4)]('Generated\x20by\x20Rabetbase\x20CLI'))return![];const _0x2bd719=stripComments(_0x1a3b60),_0x4c5a90=[..._0x2bd719['matchAll'](/^import[\s\S]*?from\s+["']([^"']+)["'];?$/gm)][_0x11bf77(0xbf)](_0x4cbf06=>_0x4cbf06[0x1]);if(_0x4c5a90['length']!==0x1||_0x4c5a90[0x0]!==_0x11bf77(0xba))return![];const _0x4c7130=[..._0x2bd719[_0x11bf77(0xc4)](/^(?:export\s+)?const\s+([A-Za-z_$][\w$]*)/gm)]['map'](_0x3e3058=>_0x3e3058[0x1]);if(_0x4c7130[_0x11bf77(0xb7)]!==0x2||!_0x4c7130[_0x11bf77(0xb8)](_0xb18579=>_0xb18579['endsWith'](_0x11bf77(0xc0)))||!_0x4c7130[_0x11bf77(0xb8)](_0x1faee3=>_0x1faee3[_0x11bf77(0xc8)]('MODELS_CONFIG')))return![];const _0x57c65d=[..._0x2bd719[_0x11bf77(0xc4)](/^([A-Za-z_$][\w$]*)\s*\(/gm)][_0x11bf77(0xbf)](_0x3a6a59=>_0x3a6a59[0x1]);return _0x57c65d[_0x11bf77(0xb7)]===0x1&&_0x57c65d[0x0]==='registerModels';}function a5_0x55f1(_0x217b90,_0x21662f){_0x217b90=_0x217b90-0xb3;const _0x248119=a5_0x2481();let _0x55f1e5=_0x248119[_0x217b90];return _0x55f1e5;}export function isLegacyGeneratedClientScaffold(_0x1f8893){const _0x35aa40=a5_0x55f1;if(!_0x1f8893['includes']('Generated\x20by\x20Rabetbase\x20CLI'))return![];const _0x2fc215=stripComments(_0x1f8893),_0x1a80fc=[..._0x2fc215[_0x35aa40(0xc4)](/^(?:import[\s\S]*?from\s+|import\s+)["']([^"']+)["'];?$/gm)]['map'](_0x3aee07=>_0x3aee07[0x1]);if(_0x1a80fc[_0x35aa40(0xb8)](_0xee8220=>_0xee8220!==_0x35aa40(0xba)&&!/^\.\/(?:[\w-]+-)?(?:api|sdk-config)$/['test'](_0xee8220??'')))return![];const _0x15e91c=[..._0x2fc215[_0x35aa40(0xc4)](/^(?:export\s+)?const\s+([A-Za-z_$][\w$]*)/gm)][_0x35aa40(0xbf)](_0x21cd3b=>_0x21cd3b[0x1]);return _0x15e91c[_0x35aa40(0xb7)]===0x1&&_0x15e91c[0x0]===_0x35aa40(0xbc);}function a5_0x2481(){const _0x37c108=['913712uTfxaa','match','10728GeJvYp','endsWith','4847319ITLbAw','5BdvphY','includes','1771MVDZrm','977925HYIXAZ','length','some','24060OYLCuv','@lovrabet/sdk','1648398RJSzvb','lovrabetClient','1048274RhGEVJ','push','map','APP_CODE','1simhsU','replace','252eqWGUU','matchAll'];a5_0x2481=function(){return _0x37c108;};return a5_0x2481();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a6_0x1c9924=a6_0x204c;(function(_0x340823,_0x5e77fb){const _0x1e3851=a6_0x204c,_0x3e72b7=_0x340823();while(!![]){try{const _0x54259c=-parseInt(_0x1e3851(0x12f))/0x1*(-parseInt(_0x1e3851(0x112))/0x2)+-parseInt(_0x1e3851(0x11a))/0x3+parseInt(_0x1e3851(0x10f))/0x4*(parseInt(_0x1e3851(0x108))/0x5)+parseInt(_0x1e3851(0x117))/0x6*(parseInt(_0x1e3851(0x109))/0x7)+-parseInt(_0x1e3851(0x134))/0x8*(parseInt(_0x1e3851(0x118))/0x9)+-parseInt(_0x1e3851(0x12c))/0xa+parseInt(_0x1e3851(0x10e))/0xb;if(_0x54259c===_0x5e77fb)break;else _0x3e72b7['push'](_0x3e72b7['shift']());}catch(_0x6c1c82){_0x3e72b7['push'](_0x3e72b7['shift']());}}}(a6_0x3b77,0x5de15));import{existsSync,mkdirSync,readFileSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import a6_0x444cb9 from'node:path';export const MODEL_REGISTRY_FILE_NAME=a6_0x1c9924(0x114);function a6_0x204c(_0x36ba92,_0x2a6c3c){_0x36ba92=_0x36ba92-0x101;const _0x3b77aa=a6_0x3b77();let _0x204c54=_0x3b77aa[_0x36ba92];return _0x204c54;}function a6_0x3b77(){const _0x114068=['models.generated.ts','Verify\x20the\x20selected\x20app\x20and\x20login,\x20or\x20rerun\x20with\x20--force\x20--yes\x20if\x20the\x20profile\x20is\x20intentionally\x20empty.','isArray','20070hOWmQr','156042aIrRaI','\x20as\x20const\x20satisfies\x20LovrabetModelRegistry;\x0a','1247304runEhH','datasetCodes','profileName','\x22\x20and\x20\x22','profiles','\x20model(s)\x20in\x20profile\x20\x22','Refusing\x20to\x20replace\x20','.tmp','string','Model\x20alias\x20\x22','name','map','length','slice','\x22\x20maps\x20to\x20both\x20aliases\x20\x22','key','set','object','4556080SXQjDh','\x0aexport\x20const\x20LOVRABET_MODEL_REGISTRY\x20=\x0a\x20\x20','filter','40446MbFBZC','trim','datasetCode','appCode','value','344dDraVY','indexOf','Table\x20\x22','push','entries','runtimeDomain','get','find','protocol','replace','join','\x22\x20in\x20profile\x20\x22','alias','tableName','keys','/*\x20rabetbase-model-registry:v2\x20*/','test','now','models','\x22\x20maps\x20to\x20alias\x20\x22','3446110OvEoUf','1358gwTniX','parse','stringify','\x22\x20in\x20the\x20registry\x20but\x20\x22','split','622611rNcAzt','4jFDBQW','every','\x22\x20with\x20an\x20empty\x20result.\x20','30SaUiam','defaultProfile'];a6_0x3b77=function(){return _0x114068;};return a6_0x3b77();}export const MODEL_RUNTIME_FILE_NAME='model-runtime.ts';export const MODEL_REGISTRY_VERSION_MARKER=a6_0x1c9924(0x103);const LEGACY_MODEL_REGISTRY_V2_PROTOCOL='lovrabet-model-registry/v2',REGISTRY_START='/*\x20rabetbase-model-registry:start\x20*/',REGISTRY_END='/*\x20rabetbase-model-registry:end\x20*/';function emptyRegistry(_0x1284f3){return{'defaultProfile':_0x1284f3,'profiles':{},'models':[]};}function extractRegistryJson(_0x1bfbab){const _0x36fb7e=a6_0x1c9924,_0x5325e1=_0x1bfbab['indexOf'](REGISTRY_START),_0x5aaa7b=_0x1bfbab[_0x36fb7e(0x135)](REGISTRY_END);if(_0x5325e1<0x0||_0x5aaa7b<=_0x5325e1)return undefined;return _0x1bfbab[_0x36fb7e(0x127)](_0x5325e1+REGISTRY_START[_0x36fb7e(0x126)],_0x5aaa7b)[_0x36fb7e(0x130)]()[_0x36fb7e(0x13d)](/\s+as const satisfies LovrabetModelRegistry;?$/,'')[_0x36fb7e(0x13d)](/;$/,'');}function migrateLegacyRegistry(_0x3713e1){const _0x573332=a6_0x1c9924,_0x3f349c=emptyRegistry(_0x3713e1[_0x573332(0x113)]);for(const [_0x1efab1,_0x311b82]of Object[_0x573332(0x138)](_0x3713e1[_0x573332(0x11e)])){_0x3f349c[_0x573332(0x11e)][_0x1efab1]={'appCode':_0x311b82[_0x573332(0x132)],'runtimeDomain':_0x311b82[_0x573332(0x139)]},mergeProfileModels(_0x3f349c,_0x1efab1,_0x311b82['models']);}return _0x3f349c;}function generatedObjectLiteralToJson(_0x1f528f){const _0x5c6833=a6_0x1c9924;let _0x3d394d='',_0x9b1429,_0x475b43=![],_0x5a6a5e;for(let _0xa387b5=0x0;_0xa387b5<_0x1f528f[_0x5c6833(0x126)];_0xa387b5++){const _0x4728a0=_0x1f528f[_0xa387b5];if(_0x9b1429){_0x3d394d+=_0x4728a0;if(_0x475b43)_0x475b43=![];else{if(_0x4728a0==='\x5c')_0x475b43=!![];else{if(_0x4728a0===_0x9b1429)_0x9b1429=undefined;}}continue;}if(_0x4728a0==='\x22'){_0x9b1429=_0x4728a0,_0x3d394d+=_0x4728a0,_0x5a6a5e=_0x5c6833(0x133);continue;}if(_0x4728a0===','){let _0x514f38=_0xa387b5+0x1;while(/\s/['test'](_0x1f528f[_0x514f38]??''))_0x514f38++;if(_0x1f528f[_0x514f38]==='}'||_0x1f528f[_0x514f38]===']')continue;_0x3d394d+=_0x4728a0,_0x5a6a5e=',';continue;}if(_0x4728a0==='{'||_0x4728a0==='['){_0x3d394d+=_0x4728a0,_0x5a6a5e=_0x4728a0;continue;}if(_0x4728a0==='}'||_0x4728a0===']'){_0x3d394d+=_0x4728a0,_0x5a6a5e=_0x4728a0;continue;}if((_0x5a6a5e==='{'||_0x5a6a5e===',')&&/[A-Za-z_$]/[_0x5c6833(0x104)](_0x4728a0)){let _0xcb3f58=_0xa387b5+0x1;while(/[A-Za-z0-9_$]/[_0x5c6833(0x104)](_0x1f528f[_0xcb3f58]??''))_0xcb3f58++;let _0x3b3fc8=_0xcb3f58;while(/\s/[_0x5c6833(0x104)](_0x1f528f[_0x3b3fc8]??''))_0x3b3fc8++;if(_0x1f528f[_0x3b3fc8]===':'){_0x3d394d+=JSON[_0x5c6833(0x10b)](_0x1f528f[_0x5c6833(0x127)](_0xa387b5,_0xcb3f58)),_0xa387b5=_0xcb3f58-0x1,_0x5a6a5e=_0x5c6833(0x129);continue;}}_0x3d394d+=_0x4728a0;if(!/\s/['test'](_0x4728a0)&&_0x4728a0!==':')_0x5a6a5e=_0x5c6833(0x133);}return _0x3d394d;}function parseGeneratedRegistryJson(_0x2b994f){const _0x3c42d4=a6_0x1c9924;try{return JSON[_0x3c42d4(0x10a)](_0x2b994f);}catch{return JSON[_0x3c42d4(0x10a)](generatedObjectLiteralToJson(_0x2b994f));}}function normalizeModelEntries(_0x5e3fd2,_0x27d77f){const _0x3ab6bb=a6_0x1c9924,_0x516bcb=Object[_0x3ab6bb(0x102)](_0x5e3fd2),_0x541a71=[];for(const _0xd38fef of _0x27d77f){if(!_0xd38fef||typeof _0xd38fef!=='object'||Array[_0x3ab6bb(0x116)](_0xd38fef))return undefined;const _0x224983=_0xd38fef;if(typeof _0x224983[_0x3ab6bb(0x140)]!==_0x3ab6bb(0x122)||typeof _0x224983[_0x3ab6bb(0x101)]!==_0x3ab6bb(0x122)||typeof _0x224983[_0x3ab6bb(0x124)]!==_0x3ab6bb(0x122))return undefined;let _0x2d6016;if(typeof _0x224983[_0x3ab6bb(0x131)]===_0x3ab6bb(0x122)&&_0x224983['datasetCodes']===undefined)_0x2d6016=Object['fromEntries'](_0x516bcb[_0x3ab6bb(0x125)](_0x5a97b7=>[_0x5a97b7,_0x224983['datasetCode']]));else{if(_0x224983[_0x3ab6bb(0x131)]===undefined&&_0x224983[_0x3ab6bb(0x11b)]&&typeof _0x224983[_0x3ab6bb(0x11b)]==='object'&&!Array['isArray'](_0x224983[_0x3ab6bb(0x11b)])&&Object['values'](_0x224983['datasetCodes'])['every'](_0x48a360=>typeof _0x48a360===_0x3ab6bb(0x122)))_0x2d6016={..._0x224983[_0x3ab6bb(0x11b)]};else return undefined;}_0x541a71[_0x3ab6bb(0x137)]({'alias':_0x224983[_0x3ab6bb(0x140)],'tableName':_0x224983[_0x3ab6bb(0x101)],'name':_0x224983[_0x3ab6bb(0x124)],'datasetCodes':_0x2d6016});}return _0x541a71;}export function parseModelRegistry(_0x4314d9){const _0x43f6d4=a6_0x1c9924,_0x36f8f7=extractRegistryJson(_0x4314d9);if(!_0x36f8f7)return undefined;try{const _0x10afd1=parseGeneratedRegistryJson(_0x36f8f7);if(typeof _0x10afd1[_0x43f6d4(0x113)]!==_0x43f6d4(0x122)||!_0x10afd1[_0x43f6d4(0x11e)]||typeof _0x10afd1[_0x43f6d4(0x11e)]!==_0x43f6d4(0x12b))return undefined;if(_0x10afd1[_0x43f6d4(0x13c)]==='lovrabet-model-registry/v1')return migrateLegacyRegistry(_0x10afd1);if(!(_0x10afd1[_0x43f6d4(0x13c)]===LEGACY_MODEL_REGISTRY_V2_PROTOCOL||_0x10afd1['protocol']===undefined&&_0x4314d9['includes'](MODEL_REGISTRY_VERSION_MARKER))||!Array[_0x43f6d4(0x116)](_0x10afd1[_0x43f6d4(0x106)]))return undefined;const _0x544e25=_0x10afd1[_0x43f6d4(0x11e)],_0x5dbfc3=normalizeModelEntries(_0x544e25,_0x10afd1[_0x43f6d4(0x106)]);if(!_0x5dbfc3)return undefined;return{'defaultProfile':_0x10afd1[_0x43f6d4(0x113)],'profiles':_0x544e25,'models':_0x5dbfc3};}catch{return undefined;}}export function readModelRegistry(_0x21e460){if(!existsSync(_0x21e460))return undefined;try{return parseModelRegistry(readFileSync(_0x21e460,'utf8'));}catch{return undefined;}}function registrySource(_0x598f6e){const _0x4310b7=a6_0x1c9924,_0x445376=Object[_0x4310b7(0x102)](_0x598f6e['profiles']),_0x3ab4f3=_0x598f6e[_0x4310b7(0x106)][_0x4310b7(0x125)](_0x203852=>{const _0x51149d=_0x4310b7,_0x2b3207=_0x445376['map'](_0x30c800=>_0x203852['datasetCodes'][_0x30c800]),_0x16b65f=_0x2b3207[0x0],_0x3e595f=_0x16b65f!==undefined&&_0x2b3207[_0x51149d(0x110)](_0x10bed8=>_0x10bed8===_0x16b65f),_0x3bf6c9={'alias':_0x203852[_0x51149d(0x140)],'tableName':_0x203852[_0x51149d(0x101)],'name':_0x203852['name']};return _0x3e595f?{..._0x3bf6c9,'datasetCode':_0x16b65f}:{..._0x3bf6c9,'datasetCodes':_0x203852[_0x51149d(0x11b)]};}),_0x29a101=JSON[_0x4310b7(0x10b)]({'defaultProfile':_0x598f6e['defaultProfile'],'profiles':_0x598f6e['profiles'],'models':_0x3ab4f3},null,0x2)[_0x4310b7(0x10d)]('\x0a')['map'](_0x3f1919=>'\x20\x20'+_0x3f1919)[_0x4310b7(0x13e)]('\x0a');return'/**\x0a\x20*\x20Dataset\x20model\x20facts\x20generated\x20by\x20Rabetbase\x20CLI.\x0a\x20*\x0a\x20*\x20This\x20file\x20is\x20safe\x20to\x20commit.\x20Do\x20not\x20edit\x20it\x20manually\x20and\x20never\x20add\x20credentials.\x0a\x20*/\x0a\x0aexport\x20interface\x20LovrabetModelProfile\x20{\x0a\x20\x20appCode:\x20string;\x0a\x20\x20runtimeDomain:\x20string;\x0a}\x0a\x0aexport\x20interface\x20LovrabetModelEntryMetadata\x20{\x0a\x20\x20alias:\x20string;\x0a\x20\x20tableName:\x20string;\x0a\x20\x20name:\x20string;\x0a}\x0a\x0aexport\x20type\x20LovrabetModelEntry\x20=\x20LovrabetModelEntryMetadata\x20&\x20(\x0a\x20\x20|\x20{\x20datasetCode:\x20string;\x20datasetCodes?:\x20never\x20}\x0a\x20\x20|\x20{\x20datasetCode?:\x20never;\x20datasetCodes:\x20Record<string,\x20string>\x20}\x0a);\x0a\x0aexport\x20interface\x20LovrabetModelRegistry\x20{\x0a\x20\x20defaultProfile:\x20string;\x0a\x20\x20profiles:\x20Record<string,\x20LovrabetModelProfile>;\x0a\x20\x20models:\x20LovrabetModelEntry[];\x0a}\x0a\x0a'+MODEL_REGISTRY_VERSION_MARKER+_0x4310b7(0x12d)+REGISTRY_START+'\x0a'+_0x29a101+_0x4310b7(0x119)+REGISTRY_END+'\x0a';}function mergeProfileModels(_0x862fe5,_0x13faa2,_0x263c32){const _0x47d098=a6_0x1c9924,_0x25e117=_0x263c32[_0x47d098(0x125)](_0x57cb67=>({..._0x57cb67,'alias':_0x57cb67[_0x47d098(0x140)]||_0x57cb67[_0x47d098(0x101)]})),_0xc4b4c6=new Map(),_0x516230=new Map();for(const _0x3ff684 of _0x25e117){const _0x12b232=_0xc4b4c6[_0x47d098(0x13a)](_0x3ff684[_0x47d098(0x140)]);if(_0x12b232&&_0x12b232!==_0x3ff684[_0x47d098(0x101)])throw new Error(_0x47d098(0x123)+_0x3ff684[_0x47d098(0x140)]+'\x22\x20maps\x20to\x20both\x20\x22'+_0x12b232+_0x47d098(0x11d)+_0x3ff684[_0x47d098(0x101)]+'\x22\x20in\x20profile\x20\x22'+_0x13faa2+'\x22.');const _0x12d4d2=_0x516230[_0x47d098(0x13a)](_0x3ff684['tableName']);if(_0x12d4d2&&_0x12d4d2!==_0x3ff684['alias'])throw new Error(_0x47d098(0x136)+_0x3ff684['tableName']+_0x47d098(0x128)+_0x12d4d2+'\x22\x20and\x20\x22'+_0x3ff684[_0x47d098(0x140)]+_0x47d098(0x13f)+_0x13faa2+'\x22.');_0xc4b4c6[_0x47d098(0x12a)](_0x3ff684[_0x47d098(0x140)],_0x3ff684[_0x47d098(0x101)]),_0x516230['set'](_0x3ff684[_0x47d098(0x101)],_0x3ff684[_0x47d098(0x140)]);const _0x49f22f=_0x862fe5[_0x47d098(0x106)][_0x47d098(0x13b)](_0x10bbf1=>_0x10bbf1[_0x47d098(0x140)]===_0x3ff684['alias']);if(_0x49f22f&&_0x49f22f[_0x47d098(0x101)]!==_0x3ff684[_0x47d098(0x101)])throw new Error('Model\x20alias\x20\x22'+_0x3ff684[_0x47d098(0x140)]+'\x22\x20maps\x20to\x20table\x20\x22'+_0x49f22f[_0x47d098(0x101)]+_0x47d098(0x10c)+_0x3ff684['tableName']+_0x47d098(0x13f)+_0x13faa2+'\x22.');const _0x66ae1f=_0x862fe5[_0x47d098(0x106)][_0x47d098(0x13b)](_0x354779=>_0x354779[_0x47d098(0x101)]===_0x3ff684['tableName']);if(_0x66ae1f&&_0x66ae1f[_0x47d098(0x140)]!==_0x3ff684[_0x47d098(0x140)])throw new Error('Table\x20\x22'+_0x3ff684[_0x47d098(0x101)]+_0x47d098(0x107)+_0x66ae1f[_0x47d098(0x140)]+'\x22\x20in\x20the\x20registry\x20but\x20\x22'+_0x3ff684[_0x47d098(0x140)]+_0x47d098(0x13f)+_0x13faa2+'\x22.');}for(const _0x4c6ed8 of _0x862fe5[_0x47d098(0x106)]){delete _0x4c6ed8[_0x47d098(0x11b)][_0x13faa2];}for(const _0x201367 of _0x25e117){let _0x27df5e=_0x862fe5[_0x47d098(0x106)]['find'](_0x12749c=>_0x12749c[_0x47d098(0x140)]===_0x201367['alias']);!_0x27df5e&&(_0x27df5e={'alias':_0x201367['alias'],'tableName':_0x201367[_0x47d098(0x101)],'name':_0x201367[_0x47d098(0x124)],'datasetCodes':{}},_0x862fe5['models'][_0x47d098(0x137)](_0x27df5e)),(_0x13faa2===_0x862fe5[_0x47d098(0x113)]||!_0x27df5e[_0x47d098(0x11b)][_0x862fe5[_0x47d098(0x113)]])&&(_0x27df5e['alias']=_0x201367[_0x47d098(0x140)],_0x27df5e[_0x47d098(0x101)]=_0x201367[_0x47d098(0x101)],_0x27df5e['name']=_0x201367[_0x47d098(0x124)]),_0x27df5e[_0x47d098(0x11b)][_0x13faa2]=_0x201367[_0x47d098(0x131)];}_0x862fe5['models']=_0x862fe5[_0x47d098(0x106)][_0x47d098(0x12e)](_0x31ea20=>Object['keys'](_0x31ea20[_0x47d098(0x11b)])['length']>0x0);}function removeUnboundProfiles(_0x2e4c8a){const _0x1b8a7a=a6_0x1c9924,_0x5c2acf=Object['entries'](_0x2e4c8a[_0x1b8a7a(0x11e)])[_0x1b8a7a(0x12e)](([,_0x5e770e])=>_0x5e770e[_0x1b8a7a(0x132)]==='NOT-SET')[_0x1b8a7a(0x125)](([_0x408dfc])=>_0x408dfc);if(_0x5c2acf['length']===0x0)return;for(const _0xc3f4 of _0x5c2acf){delete _0x2e4c8a['profiles'][_0xc3f4];for(const _0x97df8a of _0x2e4c8a['models']){delete _0x97df8a[_0x1b8a7a(0x11b)][_0xc3f4];}}_0x2e4c8a[_0x1b8a7a(0x106)]=_0x2e4c8a[_0x1b8a7a(0x106)][_0x1b8a7a(0x12e)](_0x253af5=>Object[_0x1b8a7a(0x102)](_0x253af5[_0x1b8a7a(0x11b)])[_0x1b8a7a(0x126)]>0x0);}export function getProfileModels(_0x400c0f,_0x2ef35c){const _0x9d1d3f=a6_0x1c9924;return _0x400c0f[_0x9d1d3f(0x106)]['flatMap'](_0x24206a=>{const _0x109f96=_0x9d1d3f,_0x21935c=_0x24206a['datasetCodes'][_0x2ef35c];return _0x21935c?[{'datasetCode':_0x21935c,'tableName':_0x24206a[_0x109f96(0x101)],'name':_0x24206a[_0x109f96(0x124)],'alias':_0x24206a['alias']}]:[];});}export function updateModelRegistry(_0x23d2d1){const _0x18cb35=a6_0x1c9924,_0x334bed=a6_0x444cb9[_0x18cb35(0x13e)](_0x23d2d1['outputDir'],MODEL_REGISTRY_FILE_NAME),_0x206b4d=existsSync(_0x334bed),_0x3433e9=readModelRegistry(_0x334bed);if(_0x206b4d&&!_0x3433e9)throw new Error(MODEL_REGISTRY_FILE_NAME+'\x20is\x20not\x20a\x20valid\x20Rabetbase\x20generated\x20file.\x20Move\x20or\x20repair\x20it\x20before\x20pulling\x20models\x20again.');const _0x484d2b=_0x3433e9??emptyRegistry(_0x23d2d1[_0x18cb35(0x113)]);if(_0x23d2d1['appCode']!=='NOT-SET')removeUnboundProfiles(_0x484d2b);const _0x49ea56=_0x3433e9?getProfileModels(_0x3433e9,_0x23d2d1[_0x18cb35(0x11c)])[_0x18cb35(0x126)]:0x0;if(_0x49ea56>0x0&&_0x23d2d1['models'][_0x18cb35(0x126)]===0x0&&!_0x23d2d1['allowEmptyReplacement'])throw new Error(_0x18cb35(0x120)+_0x49ea56+_0x18cb35(0x11f)+_0x23d2d1['profileName']+_0x18cb35(0x111)+_0x18cb35(0x115));_0x484d2b['defaultProfile']=_0x23d2d1[_0x18cb35(0x113)],_0x484d2b[_0x18cb35(0x11e)][_0x23d2d1[_0x18cb35(0x11c)]]={'appCode':_0x23d2d1[_0x18cb35(0x132)],'runtimeDomain':_0x23d2d1['runtimeDomain']},mergeProfileModels(_0x484d2b,_0x23d2d1[_0x18cb35(0x11c)],_0x23d2d1[_0x18cb35(0x106)]),mkdirSync(_0x23d2d1['outputDir'],{'recursive':!![]});const _0x2b65a4=_0x334bed+'.'+process['pid']+'.'+Date[_0x18cb35(0x105)]()+_0x18cb35(0x121);try{writeFileSync(_0x2b65a4,registrySource(_0x484d2b),{'encoding':'utf8','mode':0x1a4}),renameSync(_0x2b65a4,_0x334bed);}catch(_0x2355e4){try{unlinkSync(_0x2b65a4);}catch{}throw _0x2355e4;}return{'path':_0x334bed,'registry':_0x484d2b,'existed':_0x206b4d};}
|
|
1
|
+
const a6_0x394297=a6_0x56b0;(function(_0x343e35,_0x28fd6c){const _0x26bc17=a6_0x56b0,_0x29d1bc=_0x343e35();while(!![]){try{const _0x3a634e=-parseInt(_0x26bc17(0x108))/0x1+-parseInt(_0x26bc17(0x136))/0x2+parseInt(_0x26bc17(0x12f))/0x3*(-parseInt(_0x26bc17(0x114))/0x4)+parseInt(_0x26bc17(0x12e))/0x5*(-parseInt(_0x26bc17(0x13b))/0x6)+-parseInt(_0x26bc17(0x10f))/0x7*(-parseInt(_0x26bc17(0x120))/0x8)+parseInt(_0x26bc17(0x110))/0x9+parseInt(_0x26bc17(0x112))/0xa*(parseInt(_0x26bc17(0x10c))/0xb);if(_0x3a634e===_0x28fd6c)break;else _0x29d1bc['push'](_0x29d1bc['shift']());}catch(_0x3c3b89){_0x29d1bc['push'](_0x29d1bc['shift']());}}}(a6_0x20ca,0xa173b));import{existsSync,mkdirSync,readFileSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import a6_0x5519ea from'node:path';export const MODEL_REGISTRY_FILE_NAME=a6_0x394297(0x126);export const MODEL_RUNTIME_FILE_NAME=a6_0x394297(0x111);export const MODEL_REGISTRY_VERSION_MARKER='/*\x20rabetbase-model-registry:v2\x20*/';const LEGACY_MODEL_REGISTRY_V2_PROTOCOL=a6_0x394297(0x12a),REGISTRY_START=a6_0x394297(0x13a),REGISTRY_END=a6_0x394297(0x143);function emptyRegistry(_0x42181f){return{'defaultProfile':_0x42181f,'profiles':{},'models':[]};}function extractRegistryJson(_0x121d8d){const _0x4c1f9f=a6_0x394297,_0x39edaa=_0x121d8d['indexOf'](REGISTRY_START),_0x340a36=_0x121d8d[_0x4c1f9f(0x105)](REGISTRY_END);if(_0x39edaa<0x0||_0x340a36<=_0x39edaa)return undefined;return _0x121d8d[_0x4c1f9f(0x140)](_0x39edaa+REGISTRY_START[_0x4c1f9f(0x113)],_0x340a36)['trim']()[_0x4c1f9f(0x123)](/\s+as const satisfies LovrabetModelRegistry;?$/,'')[_0x4c1f9f(0x123)](/;$/,'');}function migrateLegacyRegistry(_0x4cb657){const _0xee7be4=a6_0x394297,_0x2fd339=emptyRegistry(_0x4cb657['defaultProfile']);for(const [_0x432436,_0x2226e4]of Object[_0xee7be4(0x144)](_0x4cb657[_0xee7be4(0x12d)])){_0x2fd339[_0xee7be4(0x12d)][_0x432436]={'appCode':_0x2226e4[_0xee7be4(0x103)],'runtimeDomain':_0x2226e4[_0xee7be4(0x116)]},mergeProfileModels(_0x2fd339,_0x432436,_0x2226e4[_0xee7be4(0x133)]);}return _0x2fd339;}function generatedObjectLiteralToJson(_0x4564f6){const _0x53c0b0=a6_0x394297;let _0x5dfa14='',_0x5cf514,_0xf4cbd0=![],_0x5d806b;for(let _0x2e4800=0x0;_0x2e4800<_0x4564f6[_0x53c0b0(0x113)];_0x2e4800++){const _0x3430c2=_0x4564f6[_0x2e4800];if(_0x5cf514){_0x5dfa14+=_0x3430c2;if(_0xf4cbd0)_0xf4cbd0=![];else{if(_0x3430c2==='\x5c')_0xf4cbd0=!![];else{if(_0x3430c2===_0x5cf514)_0x5cf514=undefined;}}continue;}if(_0x3430c2==='\x22'){_0x5cf514=_0x3430c2,_0x5dfa14+=_0x3430c2,_0x5d806b=_0x53c0b0(0x122);continue;}if(_0x3430c2===','){let _0x204170=_0x2e4800+0x1;while(/\s/['test'](_0x4564f6[_0x204170]??''))_0x204170++;if(_0x4564f6[_0x204170]==='}'||_0x4564f6[_0x204170]===']')continue;_0x5dfa14+=_0x3430c2,_0x5d806b=',';continue;}if(_0x3430c2==='{'||_0x3430c2==='['){_0x5dfa14+=_0x3430c2,_0x5d806b=_0x3430c2;continue;}if(_0x3430c2==='}'||_0x3430c2===']'){_0x5dfa14+=_0x3430c2,_0x5d806b=_0x3430c2;continue;}if((_0x5d806b==='{'||_0x5d806b===',')&&/[A-Za-z_$]/[_0x53c0b0(0x102)](_0x3430c2)){let _0x1ae022=_0x2e4800+0x1;while(/[A-Za-z0-9_$]/[_0x53c0b0(0x102)](_0x4564f6[_0x1ae022]??''))_0x1ae022++;let _0x4912f1=_0x1ae022;while(/\s/[_0x53c0b0(0x102)](_0x4564f6[_0x4912f1]??''))_0x4912f1++;if(_0x4564f6[_0x4912f1]===':'){_0x5dfa14+=JSON[_0x53c0b0(0x145)](_0x4564f6[_0x53c0b0(0x140)](_0x2e4800,_0x1ae022)),_0x2e4800=_0x1ae022-0x1,_0x5d806b=_0x53c0b0(0x127);continue;}}_0x5dfa14+=_0x3430c2;if(!/\s/[_0x53c0b0(0x102)](_0x3430c2)&&_0x3430c2!==':')_0x5d806b=_0x53c0b0(0x122);}return _0x5dfa14;}function parseGeneratedRegistryJson(_0x527e6a){const _0x4b69d6=a6_0x394297;try{return JSON[_0x4b69d6(0x13d)](_0x527e6a);}catch{return JSON[_0x4b69d6(0x13d)](generatedObjectLiteralToJson(_0x527e6a));}}function normalizeModelEntries(_0x16b747,_0x342bcb){const _0x48a775=a6_0x394297,_0x54ef41=Object[_0x48a775(0x106)](_0x16b747),_0x263eb6=[];for(const _0x26a69b of _0x342bcb){if(!_0x26a69b||typeof _0x26a69b!=='object'||Array[_0x48a775(0x139)](_0x26a69b))return undefined;const _0x28104a=_0x26a69b;if(typeof _0x28104a[_0x48a775(0xfd)]!==_0x48a775(0x10a)||typeof _0x28104a['tableName']!==_0x48a775(0x10a)||typeof _0x28104a[_0x48a775(0x12c)]!==_0x48a775(0x10a))return undefined;let _0x14afdc;if(typeof _0x28104a[_0x48a775(0x147)]==='string'&&_0x28104a[_0x48a775(0x104)]===undefined)_0x14afdc=Object[_0x48a775(0x148)](_0x54ef41[_0x48a775(0x115)](_0x541140=>[_0x541140,_0x28104a['datasetCode']]));else{if(_0x28104a[_0x48a775(0x147)]===undefined&&_0x28104a['datasetCodes']&&typeof _0x28104a['datasetCodes']===_0x48a775(0x13c)&&!Array[_0x48a775(0x139)](_0x28104a[_0x48a775(0x104)])&&Object[_0x48a775(0x125)](_0x28104a[_0x48a775(0x104)])[_0x48a775(0x13f)](_0x3aa2cb=>typeof _0x3aa2cb===_0x48a775(0x10a)))_0x14afdc={..._0x28104a[_0x48a775(0x104)]};else return undefined;}_0x263eb6[_0x48a775(0x117)]({'alias':_0x28104a[_0x48a775(0xfd)],'tableName':_0x28104a[_0x48a775(0x11f)],'name':_0x28104a[_0x48a775(0x12c)],'datasetCodes':_0x14afdc});}return _0x263eb6;}function a6_0x56b0(_0x19a098,_0x5919bc){_0x19a098=_0x19a098-0xfb;const _0x20cae8=a6_0x20ca();let _0x56b089=_0x20cae8[_0x19a098];return _0x56b089;}export function parseModelRegistry(_0x12162d){const _0x503e58=a6_0x394297,_0xa56281=extractRegistryJson(_0x12162d);if(!_0xa56281)return undefined;try{const _0x285f04=parseGeneratedRegistryJson(_0xa56281);if(typeof _0x285f04[_0x503e58(0x107)]!=='string'||!_0x285f04[_0x503e58(0x12d)]||typeof _0x285f04[_0x503e58(0x12d)]!==_0x503e58(0x13c))return undefined;if(_0x285f04[_0x503e58(0x10b)]===_0x503e58(0x12b))return migrateLegacyRegistry(_0x285f04);if(!(_0x285f04['protocol']===LEGACY_MODEL_REGISTRY_V2_PROTOCOL||_0x285f04['protocol']===undefined&&_0x12162d[_0x503e58(0x11e)](MODEL_REGISTRY_VERSION_MARKER))||!Array[_0x503e58(0x139)](_0x285f04['models']))return undefined;const _0x54aa44=_0x285f04[_0x503e58(0x12d)],_0x12eb51=normalizeModelEntries(_0x54aa44,_0x285f04[_0x503e58(0x133)]);if(!_0x12eb51)return undefined;return{'defaultProfile':_0x285f04[_0x503e58(0x107)],'profiles':_0x54aa44,'models':_0x12eb51};}catch{return undefined;}}function a6_0x20ca(){const _0x27c478=['\x22\x20and\x20\x22','utf8','models','\x22\x20with\x20an\x20empty\x20result.\x20','outputDir','1121484nCSfxo','allowEmptyReplacement','\x22\x20maps\x20to\x20both\x20aliases\x20\x22','isArray','/*\x20rabetbase-model-registry:start\x20*/','1970124hBpgyW','object','parse','NOT-SET','every','slice','Verify\x20the\x20selected\x20app\x20and\x20login,\x20or\x20rerun\x20with\x20--force\x20--yes\x20if\x20the\x20profile\x20is\x20intentionally\x20empty.','/**\x0a\x20*\x20Dataset\x20model\x20facts\x20generated\x20by\x20Rabetbase\x20CLI.\x0a\x20*\x0a\x20*\x20This\x20file\x20is\x20safe\x20to\x20commit.\x20Do\x20not\x20edit\x20it\x20manually\x20and\x20never\x20add\x20credentials.\x0a\x20*/\x0a\x0aexport\x20interface\x20LovrabetModelProfile\x20{\x0a\x20\x20appCode:\x20string;\x0a\x20\x20runtimeDomain:\x20string;\x0a}\x0a\x0aexport\x20interface\x20LovrabetModelEntryMetadata\x20{\x0a\x20\x20alias:\x20string;\x0a\x20\x20tableName:\x20string;\x0a\x20\x20name:\x20string;\x0a}\x0a\x0aexport\x20type\x20LovrabetModelEntry\x20=\x20LovrabetModelEntryMetadata\x20&\x20(\x0a\x20\x20|\x20{\x20datasetCode:\x20string;\x20datasetCodes?:\x20never\x20}\x0a\x20\x20|\x20{\x20datasetCode?:\x20never;\x20datasetCodes:\x20Record<string,\x20string>\x20}\x0a);\x0a\x0aexport\x20interface\x20LovrabetModelRegistry\x20{\x0a\x20\x20defaultProfile:\x20string;\x0a\x20\x20profiles:\x20Record<string,\x20LovrabetModelProfile>;\x0a\x20\x20models:\x20LovrabetModelEntry[];\x0a}\x0a\x0a','/*\x20rabetbase-model-registry:end\x20*/','entries','stringify','.tmp','datasetCode','fromEntries','\x22\x20maps\x20to\x20table\x20\x22','Table\x20\x22','alias','\x0aexport\x20const\x20LOVRABET_MODEL_REGISTRY\x20=\x0a\x20\x20','\x22\x20in\x20the\x20registry\x20but\x20\x22','filter','pid','test','appCode','datasetCodes','indexOf','keys','defaultProfile','359588ihWKlS','\x20as\x20const\x20satisfies\x20LovrabetModelRegistry;\x0a','string','protocol','922614rLxeJA','\x22\x20maps\x20to\x20both\x20\x22','\x20is\x20not\x20a\x20valid\x20Rabetbase\x20generated\x20file.\x20Move\x20or\x20repair\x20it\x20before\x20pulling\x20models\x20again.','24731CKSHgW','10659051IQVLZz','model-runtime.ts','210cZkAFo','length','84VZEeDG','map','runtimeDomain','push','\x22\x20in\x20profile\x20\x22','join','profileName','now','get','\x20model(s)\x20in\x20profile\x20\x22','includes','tableName','1736Drpbdd','\x22\x20maps\x20to\x20alias\x20\x22','value','replace','Model\x20alias\x20\x22','values','models.generated.ts','key','flatMap','find','lovrabet-model-registry/v2','lovrabet-model-registry/v1','name','profiles','15tjUCOo','163665dxpbzO','split'];a6_0x20ca=function(){return _0x27c478;};return a6_0x20ca();}export function readModelRegistry(_0x374016){if(!existsSync(_0x374016))return undefined;try{return parseModelRegistry(readFileSync(_0x374016,'utf8'));}catch{return undefined;}}function registrySource(_0x4a1871){const _0x1c1615=a6_0x394297,_0x33a5c5=Object[_0x1c1615(0x106)](_0x4a1871[_0x1c1615(0x12d)]),_0x262544=_0x4a1871['models'][_0x1c1615(0x115)](_0x32c6fa=>{const _0xb4f90=_0x1c1615,_0x4d16cc=_0x33a5c5[_0xb4f90(0x115)](_0xdca6fd=>_0x32c6fa[_0xb4f90(0x104)][_0xdca6fd]),_0x40bd5b=_0x4d16cc[0x0],_0x3e916a=_0x40bd5b!==undefined&&_0x4d16cc['every'](_0xef26bb=>_0xef26bb===_0x40bd5b),_0xa9aa6a={'alias':_0x32c6fa['alias'],'tableName':_0x32c6fa['tableName'],'name':_0x32c6fa[_0xb4f90(0x12c)]};return _0x3e916a?{..._0xa9aa6a,'datasetCode':_0x40bd5b}:{..._0xa9aa6a,'datasetCodes':_0x32c6fa[_0xb4f90(0x104)]};}),_0x2ef2e4=JSON['stringify']({'defaultProfile':_0x4a1871[_0x1c1615(0x107)],'profiles':_0x4a1871[_0x1c1615(0x12d)],'models':_0x262544},null,0x2)[_0x1c1615(0x130)]('\x0a')[_0x1c1615(0x115)](_0x5216b4=>'\x20\x20'+_0x5216b4)[_0x1c1615(0x119)]('\x0a');return _0x1c1615(0x142)+MODEL_REGISTRY_VERSION_MARKER+_0x1c1615(0xfe)+REGISTRY_START+'\x0a'+_0x2ef2e4+_0x1c1615(0x109)+REGISTRY_END+'\x0a';}function mergeProfileModels(_0x16dcd7,_0x42f1c1,_0x2f2fde){const _0x2339c4=a6_0x394297,_0x1a283e=_0x2f2fde[_0x2339c4(0x115)](_0x587885=>({..._0x587885,'alias':_0x587885[_0x2339c4(0xfd)]||_0x587885[_0x2339c4(0x11f)]})),_0x2675ce=new Map(),_0x7a74b5=new Map();for(const _0x26b515 of _0x1a283e){const _0x3c727b=_0x2675ce['get'](_0x26b515[_0x2339c4(0xfd)]);if(_0x3c727b&&_0x3c727b!==_0x26b515[_0x2339c4(0x11f)])throw new Error(_0x2339c4(0x124)+_0x26b515[_0x2339c4(0xfd)]+_0x2339c4(0x10d)+_0x3c727b+_0x2339c4(0x131)+_0x26b515[_0x2339c4(0x11f)]+'\x22\x20in\x20profile\x20\x22'+_0x42f1c1+'\x22.');const _0x15c000=_0x7a74b5[_0x2339c4(0x11c)](_0x26b515['tableName']);if(_0x15c000&&_0x15c000!==_0x26b515[_0x2339c4(0xfd)])throw new Error(_0x2339c4(0xfc)+_0x26b515[_0x2339c4(0x11f)]+_0x2339c4(0x138)+_0x15c000+'\x22\x20and\x20\x22'+_0x26b515['alias']+'\x22\x20in\x20profile\x20\x22'+_0x42f1c1+'\x22.');_0x2675ce['set'](_0x26b515[_0x2339c4(0xfd)],_0x26b515[_0x2339c4(0x11f)]),_0x7a74b5['set'](_0x26b515[_0x2339c4(0x11f)],_0x26b515[_0x2339c4(0xfd)]);const _0x4e4a8f=_0x16dcd7[_0x2339c4(0x133)]['find'](_0x1a009d=>_0x1a009d['alias']===_0x26b515[_0x2339c4(0xfd)]);if(_0x4e4a8f&&_0x4e4a8f[_0x2339c4(0x11f)]!==_0x26b515['tableName'])throw new Error(_0x2339c4(0x124)+_0x26b515[_0x2339c4(0xfd)]+_0x2339c4(0xfb)+_0x4e4a8f[_0x2339c4(0x11f)]+_0x2339c4(0xff)+_0x26b515[_0x2339c4(0x11f)]+_0x2339c4(0x118)+_0x42f1c1+'\x22.');const _0x5e8ea6=_0x16dcd7[_0x2339c4(0x133)][_0x2339c4(0x129)](_0x4963a1=>_0x4963a1[_0x2339c4(0x11f)]===_0x26b515[_0x2339c4(0x11f)]);if(_0x5e8ea6&&_0x5e8ea6['alias']!==_0x26b515[_0x2339c4(0xfd)])throw new Error(_0x2339c4(0xfc)+_0x26b515[_0x2339c4(0x11f)]+_0x2339c4(0x121)+_0x5e8ea6[_0x2339c4(0xfd)]+_0x2339c4(0xff)+_0x26b515[_0x2339c4(0xfd)]+_0x2339c4(0x118)+_0x42f1c1+'\x22.');}for(const _0x27d462 of _0x16dcd7[_0x2339c4(0x133)]){delete _0x27d462[_0x2339c4(0x104)][_0x42f1c1];}for(const _0x1e811f of _0x1a283e){let _0x2ed402=_0x16dcd7[_0x2339c4(0x133)][_0x2339c4(0x129)](_0x268e4b=>_0x268e4b[_0x2339c4(0xfd)]===_0x1e811f[_0x2339c4(0xfd)]);!_0x2ed402&&(_0x2ed402={'alias':_0x1e811f[_0x2339c4(0xfd)],'tableName':_0x1e811f[_0x2339c4(0x11f)],'name':_0x1e811f[_0x2339c4(0x12c)],'datasetCodes':{}},_0x16dcd7['models'][_0x2339c4(0x117)](_0x2ed402)),(_0x42f1c1===_0x16dcd7[_0x2339c4(0x107)]||!_0x2ed402['datasetCodes'][_0x16dcd7[_0x2339c4(0x107)]])&&(_0x2ed402[_0x2339c4(0xfd)]=_0x1e811f['alias'],_0x2ed402[_0x2339c4(0x11f)]=_0x1e811f[_0x2339c4(0x11f)],_0x2ed402[_0x2339c4(0x12c)]=_0x1e811f['name']),_0x2ed402[_0x2339c4(0x104)][_0x42f1c1]=_0x1e811f[_0x2339c4(0x147)];}_0x16dcd7[_0x2339c4(0x133)]=_0x16dcd7[_0x2339c4(0x133)]['filter'](_0x205799=>Object[_0x2339c4(0x106)](_0x205799[_0x2339c4(0x104)])[_0x2339c4(0x113)]>0x0);}function removeUnboundProfiles(_0x464cee){const _0x3fc6ef=a6_0x394297,_0x2319c1=Object[_0x3fc6ef(0x144)](_0x464cee[_0x3fc6ef(0x12d)])['filter'](([,_0x354257])=>_0x354257[_0x3fc6ef(0x103)]===_0x3fc6ef(0x13e))[_0x3fc6ef(0x115)](([_0x4af1ec])=>_0x4af1ec);if(_0x2319c1[_0x3fc6ef(0x113)]===0x0)return;for(const _0x4a9bde of _0x2319c1){delete _0x464cee['profiles'][_0x4a9bde];for(const _0x1f759b of _0x464cee[_0x3fc6ef(0x133)]){delete _0x1f759b[_0x3fc6ef(0x104)][_0x4a9bde];}}_0x464cee[_0x3fc6ef(0x133)]=_0x464cee[_0x3fc6ef(0x133)][_0x3fc6ef(0x100)](_0x5834c9=>Object[_0x3fc6ef(0x106)](_0x5834c9['datasetCodes'])[_0x3fc6ef(0x113)]>0x0);}export function getProfileModels(_0x61fb37,_0x3d956c){const _0x63e2a8=a6_0x394297;return _0x61fb37[_0x63e2a8(0x133)][_0x63e2a8(0x128)](_0x3fc835=>{const _0x13c2ac=_0x63e2a8,_0x155de1=_0x3fc835['datasetCodes'][_0x3d956c];return _0x155de1?[{'datasetCode':_0x155de1,'tableName':_0x3fc835[_0x13c2ac(0x11f)],'name':_0x3fc835[_0x13c2ac(0x12c)],'alias':_0x3fc835[_0x13c2ac(0xfd)]}]:[];});}export function updateModelRegistry(_0x177c33){const _0x558aef=a6_0x394297,_0x4c8e0f=a6_0x5519ea[_0x558aef(0x119)](_0x177c33[_0x558aef(0x135)],MODEL_REGISTRY_FILE_NAME),_0x29b528=existsSync(_0x4c8e0f),_0x5e93f8=readModelRegistry(_0x4c8e0f);if(_0x29b528&&!_0x5e93f8)throw new Error(MODEL_REGISTRY_FILE_NAME+_0x558aef(0x10e));const _0x17b4cd=_0x5e93f8??emptyRegistry(_0x177c33['defaultProfile']);if(_0x177c33[_0x558aef(0x103)]!==_0x558aef(0x13e))removeUnboundProfiles(_0x17b4cd);const _0x5e14d7=_0x5e93f8?getProfileModels(_0x5e93f8,_0x177c33['profileName'])[_0x558aef(0x113)]:0x0;if(_0x5e14d7>0x0&&_0x177c33[_0x558aef(0x133)]['length']===0x0&&!_0x177c33[_0x558aef(0x137)])throw new Error('Refusing\x20to\x20replace\x20'+_0x5e14d7+_0x558aef(0x11d)+_0x177c33['profileName']+_0x558aef(0x134)+_0x558aef(0x141));_0x17b4cd[_0x558aef(0x107)]=_0x177c33[_0x558aef(0x107)],_0x17b4cd[_0x558aef(0x12d)][_0x177c33[_0x558aef(0x11a)]]={'appCode':_0x177c33[_0x558aef(0x103)],'runtimeDomain':_0x177c33['runtimeDomain']},mergeProfileModels(_0x17b4cd,_0x177c33[_0x558aef(0x11a)],_0x177c33[_0x558aef(0x133)]),mkdirSync(_0x177c33[_0x558aef(0x135)],{'recursive':!![]});const _0x1a30c1=_0x4c8e0f+'.'+process[_0x558aef(0x101)]+'.'+Date[_0x558aef(0x11b)]()+_0x558aef(0x146);try{writeFileSync(_0x1a30c1,registrySource(_0x17b4cd),{'encoding':_0x558aef(0x132),'mode':0x1a4}),renameSync(_0x1a30c1,_0x4c8e0f);}catch(_0x120281){try{unlinkSync(_0x1a30c1);}catch{}throw _0x120281;}return{'path':_0x4c8e0f,'registry':_0x17b4cd,'existed':_0x29b528};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a7_0x45c9(){const _0xb547a5=['63ZCHNYE','{ProjectRoutingImport}','404TWFreV','replace','startsWith','typescript','3083zgQmgP','profile-api.ts.tpl','all','4964caRiNG','48664WArMQA','join','utf8','resolve','7103410fgBBfT','63IWkluO','1330206Ytzyej','1033465leuoCp','relative','format','8225511URXCmB'];a7_0x45c9=function(){return _0xb547a5;};return a7_0x45c9();}(function(_0x470a81,_0xd0793f){const _0xbf9ba2=a7_0x1a1d,_0x2979ad=_0x470a81();while(!![]){try{const _0x2cca1c=parseInt(_0xbf9ba2(0x195))/0x1*(parseInt(_0xbf9ba2(0x191))/0x2)+-parseInt(_0xbf9ba2(0x18f))/0x3*(-parseInt(_0xbf9ba2(0x198))/0x4)+parseInt(_0xbf9ba2(0x18b))/0x5+parseInt(_0xbf9ba2(0x18a))/0x6+-parseInt(_0xbf9ba2(0x18e))/0x7+parseInt(_0xbf9ba2(0x199))/0x8*(parseInt(_0xbf9ba2(0x189))/0x9)+parseInt(_0xbf9ba2(0x188))/0xa;if(_0x2cca1c===_0xd0793f)break;else _0x2979ad['push'](_0x2979ad['shift']());}catch(_0x14c4be){_0x2979ad['push'](_0x2979ad['shift']());}}}(a7_0x45c9,0x9fede));import{readFileSync}from'node:fs';import a7_0x28b402 from'node:path';import{fileURLToPath}from'node:url';import a7_0x506808 from'prettier';function a7_0x1a1d(_0x19818a,_0x121b26){_0x19818a=_0x19818a-0x187;const _0x45c906=a7_0x45c9();let _0x1a1d55=_0x45c906[_0x19818a];return _0x1a1d55;}import{PROJECT_DOMAIN_ROUTING_FILE_NAME}from'../config/project-domain-routing.js';function relativeImport(_0x19ce7a,_0x2131c6){const _0x273130=a7_0x1a1d;let _0x31229c=a7_0x28b402[_0x273130(0x18c)](_0x19ce7a,_0x2131c6)[_0x273130(0x192)](/\\/g,'/');if(!_0x31229c[_0x273130(0x193)]('.'))_0x31229c='./'+_0x31229c;return _0x31229c;}export async function renderModelRegistryScaffold(_0x5dbf2f,_0x41a6d8=process['cwd']()){const _0x4abe57=a7_0x1a1d,_0x4182bf=fileURLToPath(import.meta.url),_0x539bde=a7_0x28b402[_0x4abe57(0x187)](a7_0x28b402['dirname'](_0x4182bf),'../../templates/generate-api'),_0x5c6946=relativeImport(a7_0x28b402['resolve'](_0x5dbf2f),a7_0x28b402[_0x4abe57(0x187)](_0x41a6d8,PROJECT_DOMAIN_ROUTING_FILE_NAME)),_0x12c16e=readFileSync(a7_0x28b402['join'](_0x539bde,_0x4abe57(0x196)),'utf8')[_0x4abe57(0x192)](_0x4abe57(0x190),_0x5c6946),[_0xf65f38,_0x5da6dc,_0x4ff7]=await Promise[_0x4abe57(0x197)]([a7_0x506808['format'](_0x12c16e,{'parser':_0x4abe57(0x194)}),a7_0x506808[_0x4abe57(0x18d)](readFileSync(a7_0x28b402[_0x4abe57(0x19a)](_0x539bde,'profile-client.ts.tpl'),_0x4abe57(0x19b)),{'parser':_0x4abe57(0x194)}),a7_0x506808['format'](readFileSync(a7_0x28b402[_0x4abe57(0x19a)](_0x539bde,'model-runtime.ts.tpl'),_0x4abe57(0x19b)),{'parser':_0x4abe57(0x194)})]);return{'api':_0xf65f38,'client':_0x5da6dc,'modelRuntime':_0x4ff7};}
|
package/lib/api/model-source.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3ec2f2,_0x6d6ac1){const _0x503bf9=a8_0x360e,_0x543536=_0x3ec2f2();while(!![]){try{const _0x7572f2=parseInt(_0x503bf9(0x206))/0x1+parseInt(_0x503bf9(0x200))/0x2*(-parseInt(_0x503bf9(0x1f0))/0x3)+parseInt(_0x503bf9(0x203))/0x4+parseInt(_0x503bf9(0x1fb))/0x5*(parseInt(_0x503bf9(0x1e9))/0x6)+parseInt(_0x503bf9(0x1ff))/0x7+-parseInt(_0x503bf9(0x1f5))/0x8*(-parseInt(_0x503bf9(0x1f7))/0x9)+-parseInt(_0x503bf9(0x1fe))/0xa;if(_0x7572f2===_0x6d6ac1)break;else _0x543536['push'](_0x543536['shift']());}catch(_0x7b26fe){_0x543536['push'](_0x543536['shift']());}}}(a8_0x1f6d,0xefe51));import{existsSync}from'node:fs';import a8_0x1c5e85 from'node:path';import{readRawConfig}from'../context/config-loader.js';import{MODEL_REGISTRY_FILE_NAME,readModelRegistry}from'../api/model-registry-file.js';function a8_0x360e(_0x42c4d1,_0x2f6371){_0x42c4d1=_0x42c4d1-0x1e6;const _0x1f6d0b=a8_0x1f6d();let _0x360ed4=_0x1f6d0b[_0x42c4d1];return _0x360ed4;}import{CliErrors}from'../errors.js';import{CLI_BIN_NAME}from'../constant/cli.js';function a8_0x1f6d(){const _0xa2fee7=['\x22\x20is\x20missing\x20from\x20','profiles','validation','-api.ts','6YoRJyY','`\x20first.','string','defaultProfile','AppCode\x20\x22','map','apiDir','6FMHJwq','object','find','length','entries','24yyosDj','defaultApp','2860020oabNyW','api.ts','apps','appcode','3640005gJXCpq','Model\x20profile\x20\x22','Run\x20`','31904420AJaPWT','2239013TfHTBi','127054xPVZqx','filter','resolve','6685392lIQOAb','\x22\x20belongs\x20to\x20multiple\x20model\x20profiles:\x20','cwd','627557rjXPHS'];a8_0x1f6d=function(){return _0xa2fee7;};return a8_0x1f6d();}export function resolveApiModelSource(_0x7dbc8,_0x56cafb,_0x119980){const _0x17aa6d=a8_0x360e,_0x56d982=a8_0x1c5e85[_0x17aa6d(0x202)](process[_0x17aa6d(0x205)](),_0x7dbc8),_0x3846e2=a8_0x1c5e85[_0x17aa6d(0x202)](_0x56d982,_0x17aa6d(0x1f8)),_0x426b5c=a8_0x1c5e85[_0x17aa6d(0x202)](_0x56d982,MODEL_REGISTRY_FILE_NAME),_0x1df260=readModelRegistry(_0x426b5c);if(_0x1df260){const _0x2451ff=_0x56cafb?Object[_0x17aa6d(0x1f4)](_0x1df260['profiles'])[_0x17aa6d(0x201)](([,_0x23a7cc])=>_0x23a7cc['appCode']===_0x56cafb):[];if(_0x119980){if(_0x1df260[_0x17aa6d(0x1e6)][_0x119980])return{'filePath':_0x426b5c,'profileName':_0x119980};if(_0x2451ff[_0x17aa6d(0x1f3)]>0x0)throw CliErrors[_0x17aa6d(0x1e7)](_0x17aa6d(0x1fc)+_0x119980+_0x17aa6d(0x207)+MODEL_REGISTRY_FILE_NAME+'.',_0x17aa6d(0x1fd)+CLI_BIN_NAME+'\x20api\x20pull\x20--app\x20'+_0x119980+_0x17aa6d(0x1ea));}else{if(_0x2451ff[_0x17aa6d(0x1f3)]===0x1)return{'filePath':_0x426b5c,'profileName':_0x2451ff[0x0][0x0]};if(_0x2451ff['length']>0x1)throw new Error(_0x17aa6d(0x1ed)+_0x56cafb+_0x17aa6d(0x204)+_0x2451ff[_0x17aa6d(0x1ee)](([_0x55e662])=>_0x55e662)['join'](',\x20')+'.\x20'+'Select\x20the\x20target\x20explicitly\x20with\x20--app\x20<profile>.');if(_0x1df260['profiles'][_0x1df260[_0x17aa6d(0x1ec)]]&&!_0x56cafb)return{'filePath':_0x426b5c,'profileName':_0x1df260[_0x17aa6d(0x1ec)]};}}if(!_0x56cafb&&!_0x119980)return{'filePath':_0x3846e2};const _0x12ebcf=readRawConfig(),_0x2b1055=_0x12ebcf[_0x17aa6d(0x1f9)]&&typeof _0x12ebcf[_0x17aa6d(0x1f9)]===_0x17aa6d(0x1f1)?_0x12ebcf['apps']:{},_0x589fdd=_0x119980&&_0x2b1055[_0x119980]?[_0x119980,_0x2b1055[_0x119980]]:Object['entries'](_0x2b1055)[_0x17aa6d(0x1f2)](([,_0x377827])=>_0x377827?.[_0x17aa6d(0x1fa)]===_0x56cafb);if(!_0x589fdd)return{'filePath':_0x3846e2};const [_0x3044df,_0x5575c9]=_0x589fdd,_0x1def17=typeof _0x12ebcf[_0x17aa6d(0x1f6)]===_0x17aa6d(0x1eb)?_0x12ebcf[_0x17aa6d(0x1f6)]:undefined;if(_0x5575c9?.[_0x17aa6d(0x1ef)])return{'filePath':_0x3846e2};if(_0x1def17&&_0x3044df!==_0x1def17){const _0x328b94=a8_0x1c5e85[_0x17aa6d(0x202)](_0x56d982,_0x3044df+_0x17aa6d(0x1e8));if(existsSync(_0x328b94))return{'filePath':_0x328b94};}return{'filePath':_0x3846e2};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0xef7bc9,_0x2db078){const _0x5e34ed=a9_0x171c,_0x14cd6d=_0xef7bc9();while(!![]){try{const _0x29f58e=-parseInt(_0x5e34ed(0x131))/0x1+parseInt(_0x5e34ed(0x140))/0x2+parseInt(_0x5e34ed(0x141))/0x3+-parseInt(_0x5e34ed(0x136))/0x4+-parseInt(_0x5e34ed(0x132))/0x5*(parseInt(_0x5e34ed(0x13a))/0x6)+-parseInt(_0x5e34ed(0x134))/0x7*(parseInt(_0x5e34ed(0x143))/0x8)+-parseInt(_0x5e34ed(0x13d))/0x9*(-parseInt(_0x5e34ed(0x13c))/0xa);if(_0x29f58e===_0x2db078)break;else _0x14cd6d['push'](_0x14cd6d['shift']());}catch(_0x5434ef){_0x14cd6d['push'](_0x14cd6d['shift']());}}}(a9_0x21a1,0xe4eb3));import{getIsSessionValid}from'../auth/is-session-valid.js';import{authServer}from'../auth/auth-server.js';import{CLI_BIN_NAME}from'../constant/cli.js';function a9_0x171c(_0x464c90,_0x37a7a8){_0x464c90=_0x464c90-0x131;const _0x21a12e=a9_0x21a1();let _0x171cf9=_0x21a12e[_0x464c90];return _0x171cf9;}import{CliErrors}from'../errors.js';import{confirm}from'@inquirer/prompts';import a9_0xa2ba13 from'ora';export async function runAuthServer(_0x129c28){const _0x3eac6b=a9_0x171c,_0x42eb11=await getIsSessionValid();if(_0x42eb11){console[_0x3eac6b(0x142)]('√\x20Valid\x20session\x20detected,\x20no\x20login\x20required.');return;}if(_0x129c28?.['nonInteractive']&&!_0x129c28[_0x3eac6b(0x138)])throw CliErrors['validation']('Browser\x20login\x20cannot\x20run\x20in\x20non-interactive\x20mode.','Run\x20`'+CLI_BIN_NAME+'\x20auth\x20login\x20--yes`\x20and\x20open\x20the\x20printed\x20URL\x20in\x20your\x20browser.');const _0x3fefe3=_0x129c28?.[_0x3eac6b(0x138)]?!![]:await confirm({'message':'No\x20valid\x20session.\x20Login\x20now?','default':!![]});if(!_0x3fefe3)return;if(_0x129c28?.[_0x3eac6b(0x135)]){console['log'](_0x3eac6b(0x13f));const _0x87b6a=await authServer({'silent':![],'openBrowser':![]});_0x87b6a?console[_0x3eac6b(0x142)]('*\x20Login\x20successful!'):console[_0x3eac6b(0x142)](_0x3eac6b(0x137));return;}const _0x2f755e=a9_0xa2ba13(_0x3eac6b(0x13e))[_0x3eac6b(0x13b)](),_0x109480=await authServer({'silent':!![],'openBrowser':!![]});_0x2f755e[_0x3eac6b(0x133)](),_0x109480?console[_0x3eac6b(0x142)](_0x3eac6b(0x139)):console[_0x3eac6b(0x142)]('!\x20Login\x20failed.');}function a9_0x21a1(){const _0x16982a=['171wQmQrv','Logging\x20in...\x20Please\x20complete\x20login\x20in\x20your\x20browser.','Starting\x20browser\x20login.\x20Share\x20the\x20printed\x20URL\x20with\x20the\x20user.','2686626fOflaU','3015156iEgpvq','log','2572616fnKSKR','1371360FuWSjo','10jXiXlb','stop','7ROKiAj','nonInteractive','3873272smeOJm','!\x20Login\x20failed.','autoYes','*\x20Login\x20successful!','415818bCYRJL','start','731130GlUkDy'];a9_0x21a1=function(){return _0x16982a;};return a9_0x21a1();}
|
package/lib/auth/auth-server.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a10_0x5204b4=a10_0x43c3;(function(_0x170689,_0x87079f){const _0x2671f6=a10_0x43c3,_0x3d3468=_0x170689();while(!![]){try{const _0x4d8a80=parseInt(_0x2671f6(0xed))/0x1+-parseInt(_0x2671f6(0xf0))/0x2*(-parseInt(_0x2671f6(0xe9))/0x3)+parseInt(_0x2671f6(0xf7))/0x4*(-parseInt(_0x2671f6(0xea))/0x5)+-parseInt(_0x2671f6(0xec))/0x6*(-parseInt(_0x2671f6(0x102))/0x7)+-parseInt(_0x2671f6(0xd3))/0x8+-parseInt(_0x2671f6(0x101))/0x9+parseInt(_0x2671f6(0xf9))/0xa;if(_0x4d8a80===_0x87079f)break;else _0x3d3468['push'](_0x3d3468['shift']());}catch(_0x3706ea){_0x3d3468['push'](_0x3d3468['shift']());}}}(a10_0x38ae,0x4fc5e));import{writeFileSync}from'node:fs';import a10_0x579faa from'node:http';import a10_0x25dcb7 from'node:https';import{getUserDomain}from'../constant/domain.js';import{getOfficialRoutingCdn,getOfficialRoutingProfile}from'../constant/routing-profile.js';import{getProjectDomainRoutingManifest}from'../config/project-domain-routing.js';import{exec}from'node:child_process';import{getIsSessionValid}from'../auth/is-session-valid.js';function a10_0x43c3(_0x10d830,_0x377956){_0x10d830=_0x10d830-0xcf;const _0x38ae4a=a10_0x38ae();let _0x43c345=_0x38ae4a[_0x10d830];return _0x43c345;}import{cookieFile}from'../auth/constant.js';function a10_0x38ae(){const _0x1aaee2=['/sign-in?redirect=','silent','end','lovrabet','darwin','💡\x20Open\x20the\x20login\x20URL\x20above\x20in\x20your\x20browser\x20to\x20complete\x20authorization.','utf-8','session','win32','Auth\x20server\x20error:','address','cmd\x20/c\x20start\x20\x22\x22\x20\x22','✅\x20Browser\x20opened.\x20Please\x20complete\x20login\x20in\x20the\x20browser.','⚠️\x20\x20Failed\x20to\x20open\x20browser\x20automatically','3nbeWPR','2681040cRETHO','openBrowser','6YucGwf','582067tXRskf','isAuth','platform','829066sctKtA','certificateUrl','object','/cert/lovrabet-dev.json','127.0.0.1','error','catch','4VaTafD','🌐\x20Attempting\x20to\x20open\x20browser\x20automatically...','5518470vSFnUo','open\x20\x22','listen','port','🔗\x20Please\x20copy\x20the\x20login\x20URL\x20into\x20your\x20browser:','writeHead','user','cookie','4831983axaulY','3173275qooHmq','📍\x20Login\x20URL:','createServer','🔐\x20Starting\x20login\x20service...','💡\x20If\x20the\x20browser\x20does\x20not\x20open\x20automatically,\x20copy\x20the\x20login\x20URL\x20above\x20into\x20your\x20browser.','4815416qnSqml','text/html;\x20charset=utf-8','then','timeoutMs','origin','log','local','close'];a10_0x38ae=function(){return _0x1aaee2;};return a10_0x38ae();}import{buildLoginSuccessHtml}from'../auth/login-success-html.js';export const AUTH_LOGIN_TIMEOUT_MS=0xa*0x3c*0x3e8;export function resolveAuthCallbackRouting(_0x4087d1){const _0x4200be=a10_0x43c3;if(!_0x4087d1)return getProjectDomainRoutingManifest()[_0x4200be(0xd9)];const _0x2bad05=getOfficialRoutingProfile(_0x4087d1),_0x2bb1c1=getOfficialRoutingCdn(_0x4087d1);return{'origin':_0x2bad05[_0x4200be(0xd9)]['origin'],'certificateUrl':_0x2bb1c1[_0x4200be(0xde)]+_0x4200be(0xf3)};}function withPort(_0x305b5e,_0x5757a5){const _0x4f9413=a10_0x43c3,_0x2c7306=new URL(_0x305b5e);return _0x2c7306[_0x4f9413(0xfc)]=String(_0x5757a5),_0x2c7306[_0x4f9413(0xd7)];}export async function authServer(_0xfe3e33){const _0x4e66f6=a10_0x43c3,_0x1b5f0d=_0xfe3e33?.[_0x4e66f6(0xdc)]||![],_0x207e0c=_0xfe3e33?.[_0x4e66f6(0xeb)]??!![],_0x136fd5=_0xfe3e33?.[_0x4e66f6(0xd6)]??AUTH_LOGIN_TIMEOUT_MS;if(await getIsSessionValid())return!![];const _0xb1b40d=resolveAuthCallbackRouting(),_0x27878d=_0xb1b40d[_0x4e66f6(0xf1)]?await(await fetch(_0xb1b40d[_0x4e66f6(0xf1)]))['json']():undefined;return new Promise(async(_0x362820,_0x4a2548)=>{const _0x27803b=_0x4e66f6;let _0x4e47e2=0x0,_0x4d3ab7=![],_0x268af5;const _0x1803c4=async(_0x54a322,_0x5392a2)=>{const _0x547ca4=a10_0x43c3,_0x4fa355=getUserDomain(),_0x2e81b8=_0x54a322['headers'][_0x547ca4(0x100)]||'',_0x362a9c=await fetch(_0x4fa355+'/api/auth/get-session',{'headers':{'cookie':_0x2e81b8}})[_0x547ca4(0xd5)](_0x550cdd=>_0x550cdd['json']()),_0x328a0d=_0x362a9c&&_0x362a9c[_0x547ca4(0xe2)]&&_0x362a9c[_0x547ca4(0xff)];if(_0x328a0d){writeFileSync(cookieFile,_0x2e81b8,_0x547ca4(0xe1));const _0x28f45f=buildLoginSuccessHtml();_0x5392a2[_0x547ca4(0xfe)](0xc8,{'Content-Type':_0x547ca4(0xd4)}),_0x5392a2[_0x547ca4(0xdd)](_0x28f45f),_0x4f91e9(!![]);}else{const _0x15c75b=encodeURIComponent(withPort(_0xb1b40d['origin'],_0x4e47e2));_0x5392a2[_0x547ca4(0xfe)](0x12e,{'location':_0x4fa355+_0x547ca4(0xdb)+_0x15c75b}),_0x5392a2['end']();return;}},_0x2fee7c=_0x27878d?a10_0x25dcb7[_0x27803b(0xd0)](_0x27878d,_0x1803c4):a10_0x579faa[_0x27803b(0xd0)](_0x1803c4);function _0x4f91e9(_0x1d475f){const _0x2ac6a8=_0x27803b;if(_0x4d3ab7)return;_0x4d3ab7=!![],_0x268af5&&clearTimeout(_0x268af5),_0x2fee7c[_0x2ac6a8(0xda)](),_0x362820(_0x1d475f);}_0x2fee7c[_0x27803b(0xfb)](0x0,_0x27803b(0xf4),()=>{const _0x34d6d4=_0x27803b,_0x814241=_0x2fee7c[_0x34d6d4(0xe5)]();_0x4e47e2=typeof _0x814241===_0x34d6d4(0xf2)&&_0x814241?_0x814241[_0x34d6d4(0xfc)]:Number(_0x814241);const _0x3e649d=withPort(_0xb1b40d[_0x34d6d4(0xd7)],_0x4e47e2);_0x268af5=setTimeout(()=>{const _0x512e88=_0x34d6d4;!_0x1b5f0d&&console[_0x512e88(0xd8)]('!\x20Login\x20URL\x20expired\x20after\x2010\x20minutes.\x20Run\x20the\x20login\x20command\x20again\x20to\x20get\x20a\x20new\x20URL.'),_0x4f91e9(![]);},_0x136fd5);!_0x1b5f0d&&(console['log'](_0x34d6d4(0xd1)),console['log'](_0x34d6d4(0xcf),_0x3e649d),_0x207e0c?(console['log'](_0x34d6d4(0xf8)),console[_0x34d6d4(0xd8)](''),console[_0x34d6d4(0xd8)](_0x34d6d4(0xd2))):console[_0x34d6d4(0xd8)](_0x34d6d4(0xe0)),console[_0x34d6d4(0xd8)](''));if(!_0x207e0c)return;openInBrowser(_0x3e649d)[_0x34d6d4(0xd5)](_0x4deeda=>{const _0x1a2f32=_0x34d6d4;!_0x1b5f0d&&(_0x4deeda?console[_0x1a2f32(0xd8)](_0x1a2f32(0xe7)):(console[_0x1a2f32(0xd8)](_0x1a2f32(0xe8)),console['log'](_0x1a2f32(0xfd),_0x3e649d)),console['log'](''));})[_0x34d6d4(0xf6)](()=>{const _0x4311cf=_0x34d6d4;!_0x1b5f0d&&(console[_0x4311cf(0xd8)](_0x4311cf(0xe8)),console[_0x4311cf(0xd8)]('🔗\x20Please\x20copy\x20the\x20login\x20URL\x20into\x20your\x20browser:',_0x3e649d),console[_0x4311cf(0xd8)](''));});}),_0x2fee7c['on'](_0x27803b(0xf5),_0x47cc6b=>{const _0x594483=_0x27803b;if(_0x4d3ab7)return;_0x4d3ab7=!![],_0x268af5&&clearTimeout(_0x268af5),!_0x1b5f0d&&console[_0x594483(0xf5)](_0x594483(0xe4),_0x47cc6b),_0x2fee7c[_0x594483(0xda)](),_0x4a2548(_0x47cc6b);});});}function openInBrowser(_0x556e66){return new Promise(_0x63f879=>{const _0x381575=a10_0x43c3,_0x4352a0=process[_0x381575(0xef)];let _0x5cd97f;if(_0x4352a0===_0x381575(0xe3))_0x5cd97f=_0x381575(0xe6)+_0x556e66+'\x22';else _0x4352a0===_0x381575(0xdf)?_0x5cd97f=_0x381575(0xfa)+_0x556e66+'\x22':_0x5cd97f='xdg-open\x20\x22'+_0x556e66+'\x22';exec(_0x5cd97f,_0x3b5db8=>{_0x3b5db8?_0x63f879(![]):_0x63f879(!![]);});});}if(import.meta.main){const isAuth=await authServer();console['log'](a10_0x5204b4(0xee),isAuth);}
|
package/lib/auth/constant.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a11_0x4bb2d8=a11_0x3aa3;(function(_0x4535b6,_0x3e0289){const _0x181e2a=a11_0x3aa3,_0x3d07d9=_0x4535b6();while(!![]){try{const _0x12ed26=-parseInt(_0x181e2a(0x1f3))/0x1+parseInt(_0x181e2a(0x1ea))/0x2+parseInt(_0x181e2a(0x1ef))/0x3*(-parseInt(_0x181e2a(0x1e9))/0x4)+-parseInt(_0x181e2a(0x1ec))/0x5*(parseInt(_0x181e2a(0x1ee))/0x6)+parseInt(_0x181e2a(0x1ed))/0x7*(-parseInt(_0x181e2a(0x1f1))/0x8)+parseInt(_0x181e2a(0x1f0))/0x9*(-parseInt(_0x181e2a(0x1f2))/0xa)+parseInt(_0x181e2a(0x1e8))/0xb;if(_0x12ed26===_0x3e0289)break;else _0x3d07d9['push'](_0x3d07d9['shift']());}catch(_0x21ac93){_0x3d07d9['push'](_0x3d07d9['shift']());}}}(a11_0x7e83,0x4c725));import{mkdirSync}from'node:fs';import{homedir}from'node:os';import{join}from'node:path';function a11_0x3aa3(_0x1260f2,_0x1a648c){_0x1260f2=_0x1260f2-0x1e8;const _0x7e8397=a11_0x7e83();let _0x3aa36b=_0x7e8397[_0x1260f2];return _0x3aa36b;}export const configDir=join(homedir(),a11_0x4bb2d8(0x1f4));export const cookieFile=join(configDir,a11_0x4bb2d8(0x1eb));mkdirSync(configDir,{'recursive':!![]});function a11_0x7e83(){const _0x487de2=['10PxrIEI','7kVzxIW','581916IgWLoe','72TBBJKW','4840731DgPSKO','3740696rjzmpB','10TXGLvj','333390nCVbHK','.lovrabet','18641007KYsdYI','9692JNwTZz','418896rKgdlC','cookie'];a11_0x7e83=function(){return _0x487de2;};return a11_0x7e83();}
|
package/lib/auth/get-cookie.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x24552c,_0xd529d){var _0x51028e=a12_0x3f60,_0x51d1d3=_0x24552c();while(!![]){try{var _0x2984b5=-parseInt(_0x51028e(0xb0))/0x1+-parseInt(_0x51028e(0xb1))/0x2+-parseInt(_0x51028e(0xb3))/0x3+-parseInt(_0x51028e(0xb5))/0x4+-parseInt(_0x51028e(0xb2))/0x5*(-parseInt(_0x51028e(0xb4))/0x6)+-parseInt(_0x51028e(0xaf))/0x7+parseInt(_0x51028e(0xae))/0x8;if(_0x2984b5===_0xd529d)break;else _0x51d1d3['push'](_0x51d1d3['shift']());}catch(_0x2ae6ed){_0x51d1d3['push'](_0x51d1d3['shift']());}}}(a12_0x2fc7,0x2cd89));function a12_0x2fc7(){var _0x5bc94e=['515487yfFfZW','365025wHTRWo','462600EUagPo','828025XZAAng','770298MRBAqL','12attwxO','1330224evCjRT','8894136zroYNw'];a12_0x2fc7=function(){return _0x5bc94e;};return a12_0x2fc7();}import{readFileSync}from'node:fs';import{cookieFile}from'../auth/constant.js';function a12_0x3f60(_0x3fe235,_0x1c5dad){_0x3fe235=_0x3fe235-0xae;var _0x2fc79c=a12_0x2fc7();var _0x3f604f=_0x2fc79c[_0x3fe235];return _0x3f604f;}export function getCookie(){try{return readFileSync(cookieFile,'utf-8');}catch{}return'';}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x1bd5b4,_0x351bf9){const _0x3fab00=a13_0xf5a2,_0xd4b49=_0x1bd5b4();while(!![]){try{const _0x1c5e08=-parseInt(_0x3fab00(0xa3))/0x1+parseInt(_0x3fab00(0x9c))/0x2*(-parseInt(_0x3fab00(0xa1))/0x3)+parseInt(_0x3fab00(0xaa))/0x4*(-parseInt(_0x3fab00(0xa7))/0x5)+parseInt(_0x3fab00(0xa4))/0x6*(parseInt(_0x3fab00(0xa0))/0x7)+parseInt(_0x3fab00(0x9e))/0x8+-parseInt(_0x3fab00(0xa8))/0x9+parseInt(_0x3fab00(0xa9))/0xa;if(_0x1c5e08===_0x351bf9)break;else _0xd4b49['push'](_0xd4b49['shift']());}catch(_0x3f056b){_0xd4b49['push'](_0xd4b49['shift']());}}}(a13_0x3fa4,0x28165));import{existsSync,readFileSync}from'node:fs';import{getUserDomain}from'../constant/domain.js';import{cookieFile}from'../auth/constant.js';function a13_0xf5a2(_0x37d848,_0x2464b8){_0x37d848=_0x37d848-0x9c;const _0x3fa4f4=a13_0x3fa4();let _0xf5a249=_0x3fa4f4[_0x37d848];return _0xf5a249;}function a13_0x3fa4(){const _0x5a95c7=['1131944txgqqO','user','18347ShJaLI','54lJmaMQ','/api/auth/get-session','185729ebRkPy','642kqSpHG','utf-8','session','23905YahHiU','2607039SIoHqh','4293480EkQuTa','4UpPRaQ','22990nHFnEx','json'];a13_0x3fa4=function(){return _0x5a95c7;};return a13_0x3fa4();}export async function getSessionUserInfo(){const _0x5a3367=a13_0xf5a2;try{if(!existsSync(cookieFile))return null;const _0x2df690=readFileSync(cookieFile,_0x5a3367(0xa5)),_0xa10d6d=await fetch(getUserDomain()+_0x5a3367(0xa2),{'headers':{'cookie':_0x2df690}});if(!_0xa10d6d['ok'])return null;const _0x398c1e=await _0xa10d6d[_0x5a3367(0x9d)]();if(!_0x398c1e[_0x5a3367(0xa6)]||!_0x398c1e[_0x5a3367(0x9f)])return null;return _0x398c1e;}catch{return null;}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x249c2e,_0x407d1c){const _0x5edfe=a14_0x3cae,_0x74620a=_0x249c2e();while(!![]){try{const _0x12959a=parseInt(_0x5edfe(0x1e1))/0x1+-parseInt(_0x5edfe(0x1e4))/0x2*(parseInt(_0x5edfe(0x1e0))/0x3)+-parseInt(_0x5edfe(0x1e2))/0x4*(parseInt(_0x5edfe(0x1df))/0x5)+-parseInt(_0x5edfe(0x1e9))/0x6*(parseInt(_0x5edfe(0x1e6))/0x7)+-parseInt(_0x5edfe(0x1e3))/0x8*(parseInt(_0x5edfe(0x1de))/0x9)+parseInt(_0x5edfe(0x1e8))/0xa*(parseInt(_0x5edfe(0x1eb))/0xb)+parseInt(_0x5edfe(0x1dc))/0xc;if(_0x12959a===_0x407d1c)break;else _0x74620a['push'](_0x74620a['shift']());}catch(_0x284045){_0x74620a['push'](_0x74620a['shift']());}}}(a14_0x5d70,0x497eb));import{existsSync,readFileSync}from'node:fs';import{getUserDomain}from'../constant/domain.js';import{cookieFile}from'../auth/constant.js';function a14_0x3cae(_0x3f20a9,_0x56a087){_0x3f20a9=_0x3f20a9-0x1dc;const _0x5d7006=a14_0x5d70();let _0x3cae20=_0x5d7006[_0x3f20a9];return _0x3cae20;}function a14_0x5d70(){const _0x13886a=['2OCdmTn','user','77RikofL','then','10XTYIaa','72258sPAZCj','/api/auth/get-session','5565571eKmmNk','6823416PQJAxb','json','36AQliab','933950SmeKvp','28386lkYzFQ','256709EAzDwQ','12MXSvAQ','655896YAPoBp'];a14_0x5d70=function(){return _0x13886a;};return a14_0x5d70();}export async function getIsSessionValid(){const _0x2c9874=a14_0x3cae;try{if(!existsSync(cookieFile))return![];const _0x6efaa0=readFileSync(cookieFile,'utf-8'),_0x2f04ff=await fetch(getUserDomain()+_0x2c9874(0x1ea),{'headers':{'cookie':_0x6efaa0}})[_0x2c9874(0x1e7)](_0x31cebd=>_0x31cebd[_0x2c9874(0x1dd)]());return _0x2f04ff&&_0x2f04ff['session']&&_0x2f04ff[_0x2c9874(0x1e5)];}catch{}return![];}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a15_0x519b(_0x2d4cf0,_0x2165d9){_0x2d4cf0=_0x2d4cf0-0xe0;const _0x4ad6df=a15_0x4ad6();let _0x519b66=_0x4ad6df[_0x2d4cf0];return _0x519b66;}(function(_0x473948,_0x55d23b){const _0x58d72b=a15_0x519b,_0x5afe9d=_0x473948();while(!![]){try{const _0x4f00ab=-parseInt(_0x58d72b(0xe8))/0x1+parseInt(_0x58d72b(0xe4))/0x2*(-parseInt(_0x58d72b(0xe7))/0x3)+parseInt(_0x58d72b(0xe2))/0x4*(parseInt(_0x58d72b(0xea))/0x5)+-parseInt(_0x58d72b(0xe3))/0x6*(parseInt(_0x58d72b(0xe5))/0x7)+-parseInt(_0x58d72b(0xe6))/0x8+parseInt(_0x58d72b(0xec))/0x9+-parseInt(_0x58d72b(0xe9))/0xa*(-parseInt(_0x58d72b(0xed))/0xb);if(_0x4f00ab===_0x55d23b)break;else _0x5afe9d['push'](_0x5afe9d['shift']());}catch(_0x4e6ca6){_0x5afe9d['push'](_0x5afe9d['shift']());}}}(a15_0x4ad6,0x6d0ea));export function buildLoginSuccessHtml(){const _0x41f883=a15_0x519b,_0x333105=_0x41f883(0xe0);return _0x41f883(0xe1)+_0x333105+_0x41f883(0xeb);}function a15_0x4ad6(){const _0x8da4ec=['</div>\x0a\x20\x20\x20\x20<p\x20class=\x22cli-hint\x22>Rabetbase\x20CLI\x20·\x20session\x20saved\x20locally</p>\x0a\x20\x20</div>\x0a\x20\x20<script>\x0a\x20\x20(function(){\x0a\x20\x20\x20\x20var\x20t\x20=\x205;\x0a\x20\x20\x20\x20var\x20el\x20=\x20document.getElementById(\x27t\x27);\x0a\x20\x20\x20\x20var\x20manual\x20=\x20document.getElementById(\x27manualMsg\x27);\x0a\x20\x20\x20\x20var\x20id\x20=\x20setInterval(function(){\x0a\x20\x20\x20\x20\x20\x20t--;\x0a\x20\x20\x20\x20\x20\x20if\x20(t\x20<=\x200)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20clearInterval(id);\x0a\x20\x20\x20\x20\x20\x20\x20\x20el.textContent\x20=\x20\x270\x27;\x0a\x20\x20\x20\x20\x20\x20\x20\x20try\x20{\x20window.close();\x20}\x20catch(e)\x20{}\x0a\x20\x20\x20\x20\x20\x20\x20\x20setTimeout(function(){\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if\x20(!window.closed)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20manual.style.display\x20=\x20\x27block\x27;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20},\x20300);\x0a\x20\x20\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20el.textContent\x20=\x20String(t);\x0a\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20},\x201000);\x0a\x20\x20})();\x0a\x20\x20</script>\x0a</body>\x0a</html>','3428370CRKsYJ','21385287UDUCzk','Unable\x20to\x20close\x20automatically.\x20Please\x20close\x20this\x20tab\x20or\x20window\x20manually.','<!doctype\x20html>\x0a<html\x20lang=\x22en\x22>\x0a<head>\x0a\x20\x20<meta\x20charset=\x22utf-8\x22>\x0a\x20\x20<meta\x20name=\x22viewport\x22\x20content=\x22width=device-width,\x20initial-scale=1\x22>\x0a\x20\x20<title>Login\x20successful\x20·\x20Rabetbase\x20CLI</title>\x0a\x20\x20<style>\x0a\x20\x20\x20\x20:root\x20{\x0a\x20\x20\x20\x20\x20\x20--bg0:\x20#0f1419;\x0a\x20\x20\x20\x20\x20\x20--bg1:\x20#1a2332;\x0a\x20\x20\x20\x20\x20\x20--card:\x20#ffffff;\x0a\x20\x20\x20\x20\x20\x20--text:\x20#1c2128;\x0a\x20\x20\x20\x20\x20\x20--muted:\x20#5c6570;\x0a\x20\x20\x20\x20\x20\x20--accent:\x20#2563eb;\x0a\x20\x20\x20\x20\x20\x20--accent-soft:\x20#eff6ff;\x0a\x20\x20\x20\x20\x20\x20--success:\x20#059669;\x0a\x20\x20\x20\x20\x20\x20--radius:\x2016px;\x0a\x20\x20\x20\x20\x20\x20--shadow:\x200\x2025px\x2050px\x20-12px\x20rgba(15,\x2020,\x2025,\x200.35);\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20*\x20{\x20box-sizing:\x20border-box;\x20}\x0a\x20\x20\x20\x20body\x20{\x0a\x20\x20\x20\x20\x20\x20margin:\x200;\x0a\x20\x20\x20\x20\x20\x20min-height:\x20100vh;\x0a\x20\x20\x20\x20\x20\x20display:\x20flex;\x0a\x20\x20\x20\x20\x20\x20align-items:\x20center;\x0a\x20\x20\x20\x20\x20\x20justify-content:\x20center;\x0a\x20\x20\x20\x20\x20\x20padding:\x2024px;\x0a\x20\x20\x20\x20\x20\x20font-family:\x20ui-sans-serif,\x20system-ui,\x20-apple-system,\x20\x22Segoe\x20UI\x22,\x20Roboto,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x22Helvetica\x20Neue\x22,\x20Arial,\x20\x22Noto\x20Sans\x22,\x20\x22PingFang\x20SC\x22,\x20\x22Microsoft\x20YaHei\x22,\x20sans-serif;\x0a\x20\x20\x20\x20\x20\x20background:\x20linear-gradient(160deg,\x20var(--bg0)\x200%,\x20var(--bg1)\x2045%,\x20#243047\x20100%);\x0a\x20\x20\x20\x20\x20\x20color:\x20var(--text);\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20.card\x20{\x0a\x20\x20\x20\x20\x20\x20width:\x20100%;\x0a\x20\x20\x20\x20\x20\x20max-width:\x20420px;\x0a\x20\x20\x20\x20\x20\x20background:\x20var(--card);\x0a\x20\x20\x20\x20\x20\x20border-radius:\x20var(--radius);\x0a\x20\x20\x20\x20\x20\x20box-shadow:\x20var(--shadow);\x0a\x20\x20\x20\x20\x20\x20padding:\x2040px\x2036px\x2032px;\x0a\x20\x20\x20\x20\x20\x20text-align:\x20center;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20.icon\x20{\x0a\x20\x20\x20\x20\x20\x20width:\x2064px;\x0a\x20\x20\x20\x20\x20\x20height:\x2064px;\x0a\x20\x20\x20\x20\x20\x20margin:\x200\x20auto\x2020px;\x0a\x20\x20\x20\x20\x20\x20border-radius:\x2050%;\x0a\x20\x20\x20\x20\x20\x20background:\x20var(--accent-soft);\x0a\x20\x20\x20\x20\x20\x20display:\x20flex;\x0a\x20\x20\x20\x20\x20\x20align-items:\x20center;\x0a\x20\x20\x20\x20\x20\x20justify-content:\x20center;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20.icon\x20svg\x20{\x20width:\x2036px;\x20height:\x2036px;\x20}\x0a\x20\x20\x20\x20h1\x20{\x0a\x20\x20\x20\x20\x20\x20margin:\x200\x200\x2012px;\x0a\x20\x20\x20\x20\x20\x20font-size:\x201.375rem;\x0a\x20\x20\x20\x20\x20\x20font-weight:\x20600;\x0a\x20\x20\x20\x20\x20\x20letter-spacing:\x20-0.02em;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20p.lead\x20{\x0a\x20\x20\x20\x20\x20\x20margin:\x200\x200\x208px;\x0a\x20\x20\x20\x20\x20\x20font-size:\x200.9375rem;\x0a\x20\x20\x20\x20\x20\x20color:\x20var(--muted);\x0a\x20\x20\x20\x20\x20\x20line-height:\x201.55;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20.countdown\x20{\x0a\x20\x20\x20\x20\x20\x20display:\x20inline-flex;\x0a\x20\x20\x20\x20\x20\x20align-items:\x20center;\x0a\x20\x20\x20\x20\x20\x20gap:\x206px;\x0a\x20\x20\x20\x20\x20\x20margin-top:\x2016px;\x0a\x20\x20\x20\x20\x20\x20padding:\x208px\x2014px;\x0a\x20\x20\x20\x20\x20\x20font-size:\x200.875rem;\x0a\x20\x20\x20\x20\x20\x20font-variant-numeric:\x20tabular-nums;\x0a\x20\x20\x20\x20\x20\x20color:\x20var(--accent);\x0a\x20\x20\x20\x20\x20\x20background:\x20var(--accent-soft);\x0a\x20\x20\x20\x20\x20\x20border-radius:\x20999px;\x0a\x20\x20\x20\x20\x20\x20font-weight:\x20500;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20#manualMsg\x20{\x0a\x20\x20\x20\x20\x20\x20display:\x20none;\x0a\x20\x20\x20\x20\x20\x20margin-top:\x2020px;\x0a\x20\x20\x20\x20\x20\x20font-size:\x200.8125rem;\x0a\x20\x20\x20\x20\x20\x20color:\x20#b91c1c;\x0a\x20\x20\x20\x20\x20\x20line-height:\x201.45;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20.cli-hint\x20{\x0a\x20\x20\x20\x20\x20\x20margin-top:\x2028px;\x0a\x20\x20\x20\x20\x20\x20padding-top:\x2024px;\x0a\x20\x20\x20\x20\x20\x20border-top:\x201px\x20solid\x20#e8ecf0;\x0a\x20\x20\x20\x20\x20\x20font-size:\x200.75rem;\x0a\x20\x20\x20\x20\x20\x20color:\x20#8b949e;\x0a\x20\x20\x20\x20}\x0a\x20\x20</style>\x0a</head>\x0a<body>\x0a\x20\x20<div\x20class=\x22card\x22\x20role=\x22status\x22\x20aria-live=\x22polite\x22>\x0a\x20\x20\x20\x20<div\x20class=\x22icon\x22\x20aria-hidden=\x22true\x22>\x0a\x20\x20\x20\x20\x20\x20<svg\x20viewBox=\x220\x200\x2024\x2024\x22\x20fill=\x22none\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<circle\x20cx=\x2212\x22\x20cy=\x2212\x22\x20r=\x2210\x22\x20stroke=\x22#059669\x22\x20stroke-width=\x222\x22\x20fill=\x22none\x22/>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<path\x20d=\x22M8\x2012.5l2.5\x202.5L16\x209\x22\x20stroke=\x22#059669\x22\x20stroke-width=\x222\x22\x20stroke-linecap=\x22round\x22\x20stroke-linejoin=\x22round\x22/>\x0a\x20\x20\x20\x20\x20\x20</svg>\x0a\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20<h1>Login\x20successful</h1>\x0a\x20\x20\x20\x20<p\x20class=\x22lead\x22>You\x20can\x20return\x20to\x20the\x20terminal\x20to\x20continue.\x20This\x20window\x20will\x20try\x20to\x20close\x20automatically.</p>\x0a\x20\x20\x20\x20<div\x20class=\x22countdown\x22>\x0a\x20\x20\x20\x20\x20\x20Closing\x20in\x20<span\x20id=\x22t\x22>5</span>s\x0a\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20<div\x20id=\x22manualMsg\x22>','375596QjrUsf','12yOvSNL','430CWTUaF','1727999pgogpn','4853288XsLbNn','438ZKraQX','840483jNtyaq','10pEMUOu','5VvSKUt'];a15_0x4ad6=function(){return _0x8da4ec;};return a15_0x4ad6();}
|
package/lib/auth/logout.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a16_0x423b(_0x532b58,_0x92b8a9){_0x532b58=_0x532b58-0x8f;var _0x3a7a3d=a16_0x3a7a();var _0x423b87=_0x3a7a3d[_0x532b58];return _0x423b87;}(function(_0x2744fb,_0x443fa7){var _0x7c0d07=a16_0x423b,_0x189132=_0x2744fb();while(!![]){try{var _0x1dd5d9=parseInt(_0x7c0d07(0x95))/0x1*(-parseInt(_0x7c0d07(0x9d))/0x2)+parseInt(_0x7c0d07(0x9a))/0x3*(parseInt(_0x7c0d07(0x96))/0x4)+parseInt(_0x7c0d07(0x92))/0x5*(parseInt(_0x7c0d07(0x98))/0x6)+-parseInt(_0x7c0d07(0x94))/0x7*(parseInt(_0x7c0d07(0x9c))/0x8)+-parseInt(_0x7c0d07(0x99))/0x9+-parseInt(_0x7c0d07(0x91))/0xa*(-parseInt(_0x7c0d07(0x93))/0xb)+parseInt(_0x7c0d07(0x97))/0xc;if(_0x1dd5d9===_0x443fa7)break;else _0x189132['push'](_0x189132['shift']());}catch(_0x29ed50){_0x189132['push'](_0x189132['shift']());}}}(a16_0x3a7a,0xd3078));import{unlinkSync,existsSync}from'node:fs';import{cookieFile}from'../auth/constant.js';function a16_0x3a7a(){var _0x34856b=['24183384xcwKRd','840nsZfnh','7313697domopx','3EVudca','✓\x20Logged\x20out','3454376fgqUAq','1126196pzyDXT','log','!\x20Not\x20logged\x20in','10egHQRI','38555CYNKTa','1011417RRCECx','21nFljqz','2OIhCOY','3647308rosCmR'];a16_0x3a7a=function(){return _0x34856b;};return a16_0x3a7a();}export function logout(){var _0x4f471d=a16_0x423b;existsSync(cookieFile)?(unlinkSync(cookieFile),console[_0x4f471d(0x8f)](_0x4f471d(0x9b))):console[_0x4f471d(0x8f)](_0x4f471d(0x90));}
|
package/lib/cli-flags.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a17_0x401458=a17_0x2643;function a17_0x2643(_0x37020b,_0xdd890c){_0x37020b=_0x37020b-0x16f;const _0x3edacb=a17_0x3eda();let _0x264340=_0x3edacb[_0x37020b];return _0x264340;}(function(_0x78d493,_0x201046){const _0x47cabc=a17_0x2643,_0x108346=_0x78d493();while(!![]){try{const _0x5255dc=-parseInt(_0x47cabc(0x177))/0x1*(parseInt(_0x47cabc(0x17a))/0x2)+parseInt(_0x47cabc(0x171))/0x3+-parseInt(_0x47cabc(0x170))/0x4+-parseInt(_0x47cabc(0x173))/0x5*(parseInt(_0x47cabc(0x174))/0x6)+parseInt(_0x47cabc(0x178))/0x7+-parseInt(_0x47cabc(0x179))/0x8*(-parseInt(_0x47cabc(0x172))/0x9)+parseInt(_0x47cabc(0x175))/0xa*(parseInt(_0x47cabc(0x176))/0xb);if(_0x5255dc===_0x201046)break;else _0x108346['push'](_0x108346['shift']());}catch(_0x4a9a1c){_0x108346['push'](_0x108346['shift']());}}}(a17_0x3eda,0x27630));export const dynamicCliFlags={'enableBffSave':{'type':a17_0x401458(0x16f)}};function a17_0x3eda(){const _0x4f9498=['2WLscmG','boolean','607492PEUBvM','530385ZcEgus','99VBIncT','15MhkOzf','74442OiIrRv','90NNUBMw','303886gvuFgz','193416gGaDgF','376257FKSvFy','47024oiPcwX'];a17_0x3eda=function(){return _0x4f9498;};return a17_0x3eda();}
|