@lovrabet/rabetbase-cli 2.3.4-beta.2 → 2.3.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/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.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/add.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/remote-directory.js +1 -0
- package/lib/commands/app/remove.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/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 -0
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/dry-run.js +1 -0
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.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/data/filter.js +1 -1
- package/lib/commands/data/getOne.js +1 -1
- package/lib/commands/data/index.js +1 -1
- package/lib/commands/data/shared.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/capability.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-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/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.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/tables.js +1 -1
- package/lib/commands/db/test.js +1 -1
- package/lib/commands/db/update.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/init/index.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/logs/index.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/shared/compare-table.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/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/update.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/shared.js +1 -1
- package/lib/commands/page/standard-page-status.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/permit/index.js +1 -0
- package/lib/commands/permit/page-get.js +1 -0
- package/lib/commands/permit/page-set.js +1 -0
- package/lib/commands/permit/role-apis-set.js +1 -0
- package/lib/commands/permit/role-menus-set.js +1 -0
- package/lib/commands/permit/role-menus.js +1 -0
- package/lib/commands/permit/shared.js +1 -0
- 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/non-interactive.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/index.js +1 -1
- package/lib/commands/project/init.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/create.js +1 -0
- package/lib/commands/role/delete.js +1 -0
- package/lib/commands/role/detail.js +1 -0
- package/lib/commands/role/index.js +1 -0
- package/lib/commands/role/list.js +1 -0
- package/lib/commands/role/shared.js +1 -0
- package/lib/commands/role/update.js +1 -0
- package/lib/commands/role/user-add.js +1 -0
- package/lib/commands/role/user-remove.js +1 -0
- package/lib/commands/role/user-resolve.js +1 -0
- 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/save.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/workspace/add.js +1 -0
- package/lib/commands/workspace/index.js +1 -1
- package/lib/commands/workspace/remove.js +1 -0
- 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/risk.js +1 -1
- package/lib/context/app-resolver.js +1 -1
- package/lib/context/auth-resolver.js +1 -1
- package/lib/context/config-loader.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/db-resolver.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/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/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/types.js +1 -1
- package/lib/generated/build-info.js +1 -1
- package/lib/help.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.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/copy-directory.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/rules-cdn.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 +2 -2
- package/lib/commands/app/discover.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a223_0x1bfa(_0x134dce,_0x226452){_0x134dce=_0x134dce-0x1d6;const _0x729d52=a223_0x729d();let _0x1bfaa9=_0x729d52[_0x134dce];return _0x1bfaa9;}const a223_0xe09bfd=a223_0x1bfa;(function(_0x127c2f,_0x3ec12a){const _0x24955a=a223_0x1bfa,_0x2c92f2=_0x127c2f();while(!![]){try{const _0x12e681=-parseInt(_0x24955a(0x1f7))/0x1+parseInt(_0x24955a(0x1dd))/0x2+-parseInt(_0x24955a(0x1e1))/0x3+-parseInt(_0x24955a(0x1f6))/0x4+parseInt(_0x24955a(0x1fc))/0x5+parseInt(_0x24955a(0x1df))/0x6*(parseInt(_0x24955a(0x1f9))/0x7)+-parseInt(_0x24955a(0x1e5))/0x8*(-parseInt(_0x24955a(0x1fa))/0x9);if(_0x12e681===_0x3ec12a)break;else _0x2c92f2['push'](_0x2c92f2['shift']());}catch(_0x46a1eb){_0x2c92f2['push'](_0x2c92f2['shift']());}}}(a223_0x729d,0x3984b));import a223_0x46c92e from'node:fs';import a223_0x278bac from'node:path';import a223_0x25795a from'semver';import{getCdnConfig}from'../utils/cdn-config.js';const FALLBACK_MIN_SDK_VERSION=a223_0xe09bfd(0x1e9);function isNonNumericVersion(_0x25a72d){const _0x44c7ed=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x44c7ed['some'](_0x251300=>_0x251300['test'](_0x25a72d));}function getInstalledVersion(_0x3b70f3,_0x270eb6){const _0x247cde=a223_0xe09bfd;try{const _0x59b0e5=a223_0x278bac[_0x247cde(0x1e8)](_0x3b70f3,_0x247cde(0x1e6),_0x270eb6,_0x247cde(0x1fb));if(a223_0x46c92e[_0x247cde(0x1f2)](_0x59b0e5)){const _0x5e473b=JSON[_0x247cde(0x1ed)](a223_0x46c92e[_0x247cde(0x1dc)](_0x59b0e5,'utf-8'));return _0x5e473b[_0x247cde(0x1f5)]||null;}}catch{}return null;}async function getSdkStableVersion(){const _0x2bcea4=a223_0xe09bfd;try{const _0x20754c=await getCdnConfig();return _0x20754c?.[_0x2bcea4(0x1ea)]?.[_0x2bcea4(0x1e4)]?.['stableVersion']||null;}catch{return null;}}async function getSdkPackageName(){const _0x116a50=a223_0xe09bfd;try{const _0x12d50f=await getCdnConfig();return _0x12d50f?.[_0x116a50(0x1ea)]?.[_0x116a50(0x1e4)]?.['packageName']||_0x116a50(0x1d8);}catch{return _0x116a50(0x1d8);}}export async function checkSdkVersion(_0x34b858){const _0x2e2045=a223_0xe09bfd,_0x49c3d3=a223_0x278bac[_0x2e2045(0x1e8)](_0x34b858,'package.json'),[_0x23582d,_0x4cddd7]=await Promise[_0x2e2045(0x1e2)]([getSdkStableVersion(),getSdkPackageName()]),_0x3cbc52=_0x23582d||FALLBACK_MIN_SDK_VERSION;if(!a223_0x46c92e[_0x2e2045(0x1f2)](_0x49c3d3))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x3cbc52,'packageName':_0x4cddd7,'stableVersion':_0x23582d};try{const _0x53b565=JSON[_0x2e2045(0x1ed)](a223_0x46c92e['readFileSync'](_0x49c3d3,_0x2e2045(0x1d9))),_0x49fb4b=_0x53b565[_0x2e2045(0x1da)]||{},_0x1f0345=_0x53b565[_0x2e2045(0x1f8)]||{},_0x6e1f3f=_0x49fb4b[_0x4cddd7]||_0x1f0345[_0x4cddd7];if(!_0x6e1f3f)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x3cbc52,'packageName':_0x4cddd7,'stableVersion':_0x23582d};let _0x555417=getInstalledVersion(_0x34b858,_0x4cddd7);!_0x555417&&(_0x555417=_0x6e1f3f);if(isNonNumericVersion(_0x6e1f3f))return{'installed':!![],'version':_0x555417,'needsUpgrade':![],'minVersion':_0x3cbc52,'packageName':_0x4cddd7,'stableVersion':_0x23582d};const _0x4632fe=a223_0x25795a[_0x2e2045(0x1f3)](_0x555417),_0x2a9be4=a223_0x25795a['coerce'](_0x3cbc52),_0x3e9079=_0x4632fe&&_0x2a9be4?a223_0x25795a['lt'](_0x4632fe,_0x2a9be4):![];return{'installed':!![],'version':_0x555417,'needsUpgrade':_0x3e9079,'minVersion':_0x3cbc52,'packageName':_0x4cddd7,'stableVersion':_0x23582d};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x3cbc52,'packageName':_0x4cddd7,'stableVersion':_0x23582d};}}function a223_0x729d(){const _0x104203=['npm\x20install\x20','log','@lovrabet/sdk','utf8','dependencies','stableVersion','readFileSync','416018WSDIEq','latest','28866dETHls','\x20\x20\x20Stable\x20version:\x20','1364757stqGPk','all','needsUpgrade','node','1306808KwUWeF','node_modules','\x1b[33m','join','1.2.0','sdk','↪\x20SDK\x20update\x20available','packageName','parse','\x1b[0m','\x20\x20\x20Current\x20version:\x20','minVersion','\x1b[1m','existsSync','coerce','\x20\x20\x20Upgrade\x20command:\x20','version','1519812iHlGCA','435324jXCZmp','devDependencies','35WzYbjj','63NHGwGn','package.json','651350zepVGY'];a223_0x729d=function(){return _0x104203;};return a223_0x729d();}export function checkSdkVersionSync(_0x3167ce){const _0x2be076=a223_0xe09bfd,_0x246229=a223_0x278bac[_0x2be076(0x1e8)](_0x3167ce,_0x2be076(0x1fb)),_0x10e1b0=_0x2be076(0x1d8);if(!a223_0x46c92e[_0x2be076(0x1f2)](_0x246229))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x10e1b0,'stableVersion':null};try{const _0x51ff06=JSON[_0x2be076(0x1ed)](a223_0x46c92e[_0x2be076(0x1dc)](_0x246229,_0x2be076(0x1d9))),_0xbc839c=_0x51ff06[_0x2be076(0x1da)]||{},_0x24f659=_0x51ff06[_0x2be076(0x1f8)]||{},_0x451f27=_0xbc839c[_0x10e1b0]||_0x24f659[_0x10e1b0];if(!_0x451f27)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x10e1b0,'stableVersion':null};let _0x47c170=getInstalledVersion(_0x3167ce,_0x10e1b0);!_0x47c170&&(_0x47c170=_0x451f27);if(isNonNumericVersion(_0x451f27))return{'installed':!![],'version':_0x47c170,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x10e1b0,'stableVersion':null};const _0xf7ed16=a223_0x25795a[_0x2be076(0x1f3)](_0x47c170),_0x47b5f8=_0xf7ed16?a223_0x25795a['lt'](_0xf7ed16,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0x47c170,'needsUpgrade':_0x47b5f8,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x10e1b0,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x10e1b0,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x67c012){const _0x1d93ba=a223_0xe09bfd;if(!_0x67c012[_0x1d93ba(0x1e3)])return;const _0x14339e=_0x1d93ba(0x1e7),_0x27b494=_0x1d93ba(0x1ee),_0x20555a=_0x1d93ba(0x1f1),_0x588ddf=_0x67c012[_0x1d93ba(0x1ec)]||_0x1d93ba(0x1d8),_0x37eb14=_0x67c012[_0x1d93ba(0x1db)]||_0x67c012[_0x1d93ba(0x1f0)],_0x30664c=_0x1d93ba(0x1d6)+_0x588ddf+'@'+(_0x37eb14||_0x1d93ba(0x1de));console[_0x1d93ba(0x1d7)](),console[_0x1d93ba(0x1d7)](''+_0x14339e+_0x20555a+_0x1d93ba(0x1eb)+_0x27b494),console[_0x1d93ba(0x1d7)](_0x14339e+_0x1d93ba(0x1ef)+_0x588ddf+'@'+_0x67c012[_0x1d93ba(0x1f5)]+_0x27b494),console[_0x1d93ba(0x1d7)](_0x14339e+_0x1d93ba(0x1e0)+_0x37eb14+_0x27b494),console[_0x1d93ba(0x1d7)](_0x14339e+_0x1d93ba(0x1f4)+_0x30664c+_0x27b494),console[_0x1d93ba(0x1d7)]();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x36eeee,_0x408b7c){const _0x3a503f=a224_0x5326,_0x52e35c=_0x36eeee();while(!![]){try{const _0xe06041=parseInt(_0x3a503f(0x1eb))/0x1+-parseInt(_0x3a503f(0x1dd))/0x2*(-parseInt(_0x3a503f(0x1d5))/0x3)+parseInt(_0x3a503f(0x1e8))/0x4*(-parseInt(_0x3a503f(0x1fd))/0x5)+-parseInt(_0x3a503f(0x1e0))/0x6*(parseInt(_0x3a503f(0x1e3))/0x7)+parseInt(_0x3a503f(0x1f1))/0x8*(-parseInt(_0x3a503f(0x1e2))/0x9)+parseInt(_0x3a503f(0x1e6))/0xa+parseInt(_0x3a503f(0x1fb))/0xb;if(_0xe06041===_0x408b7c)break;else _0x52e35c['push'](_0x52e35c['shift']());}catch(_0x26094b){_0x52e35c['push'](_0x52e35c['shift']());}}}(a224_0x196a,0xd74c7));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';function a224_0x196a(){const _0x17e6f8=['\x1b[0m','coerce','latest','27094067jRygZh','join','5zMfSDt','package.json','currentVersion','30XVQyOT','stableVersion','\x20\x20\x20Upgrade\x20command:\x20','validation','Current\x20CLI\x20version\x20is\x20below\x20the\x20service\x20compatibility\x20support\x20line.','Upgrade\x20command:\x20','minimumVersion','Minimum\x20supported:\x20','44744NMMQQs','↪\x20Critical\x20CLI\x20upgrade\x20required','↪\x20New\x20version\x20available','7967142adluvJ','belowMinimum','45HBPrSL','7IYVRZX','log','\x20\x20\x20Minimum\x20supported:\x20','7853060tFHdda','\x20\x20\x20Recommended\x20stable:\x20','3714268lIthyw','\x1b[33m','npm\x20install\x20-g\x20','1074504EhAxqy','parse','1.0.0','\x20\x20\x20Current\x20CLI\x20version:\x20','upgradeMessage','\x1b[31m','2253344JNcqcf','needsUpgrade','filter','utf-8','minimumVersionMessage','version','Current\x20version:\x20'];a224_0x196a=function(){return _0x17e6f8;};return a224_0x196a();}import a224_0x3d27ad from'semver';import{getCliVersionPolicy}from'../utils/cli-version-policy.js';import{NPM_PACKAGE_NAME}from'../constant/cli.js';function a224_0x5326(_0x4e7f54,_0x6a2c00){_0x4e7f54=_0x4e7f54-0x1d3;const _0x196a97=a224_0x196a();let _0x5326f4=_0x196a97[_0x4e7f54];return _0x5326f4;}import{CliErrors}from'../errors.js';export function getCliUpgradeCommand(_0x170327){const _0x5cf164=a224_0x5326,_0x38850f=_0x170327[_0x5cf164(0x1d6)]||_0x5cf164(0x1fa);return _0x5cf164(0x1ea)+NPM_PACKAGE_NAME+'@'+_0x38850f;}function getCurrentCliVersion(){const _0x3c91d1=a224_0x5326;try{const _0x41f46f=fileURLToPath(import.meta.url),_0xc592ff=resolve(dirname(_0x41f46f),'../..'),_0x398d6f=resolve(_0xc592ff,_0x3c91d1(0x1d3)),_0x8f0b84=JSON[_0x3c91d1(0x1ec)](readFileSync(_0x398d6f,_0x3c91d1(0x1f4)));return _0x8f0b84[_0x3c91d1(0x1f6)]||_0x3c91d1(0x1ed);}catch{return _0x3c91d1(0x1ed);}}export async function checkCliVersion(){const _0x3822ce=a224_0x5326,_0x15545c=getCurrentCliVersion(),_0x440307=await getCliVersionPolicy(),_0x1b6949=_0x440307?.[_0x3822ce(0x1d6)]||null,_0x4198df=_0x440307?.[_0x3822ce(0x1db)]||null;let _0x56e0ba=![],_0x44841c=![];const _0x48e2e7=a224_0x3d27ad[_0x3822ce(0x1f9)](_0x15545c);if(_0x48e2e7&&_0x1b6949)try{const _0x20f0a9=a224_0x3d27ad['coerce'](_0x1b6949);if(_0x20f0a9)_0x56e0ba=a224_0x3d27ad['lt'](_0x48e2e7,_0x20f0a9);}catch{}if(_0x48e2e7&&_0x4198df)try{const _0x1ea432=a224_0x3d27ad['coerce'](_0x4198df);if(_0x1ea432)_0x44841c=a224_0x3d27ad['lt'](_0x48e2e7,_0x1ea432);}catch{}return _0x44841c&&(_0x56e0ba=!![]),{'currentVersion':_0x15545c,'stableVersion':_0x1b6949,'minimumVersion':_0x4198df,'needsUpgrade':_0x56e0ba,'belowMinimum':_0x44841c,'isPreRelease':![],'upgradeMessage':_0x440307?.[_0x3822ce(0x1ef)],'minimumVersionMessage':_0x440307?.['minimumVersionMessage']};}export function printCliUpgradeWarning(_0x456197){const _0x4e23e0=a224_0x5326;if(!_0x456197[_0x4e23e0(0x1f2)]&&!_0x456197[_0x4e23e0(0x1e1)])return;const _0x5c8dcd=_0x4e23e0(0x1f0),_0x560e39=_0x4e23e0(0x1e9),_0x4f1fdd=_0x4e23e0(0x1f8),_0x1d9eab='\x1b[1m',_0xc7f7bb=getCliUpgradeCommand(_0x456197);console[_0x4e23e0(0x1e4)](),_0x456197[_0x4e23e0(0x1e1)]?(console[_0x4e23e0(0x1e4)](''+_0x5c8dcd+_0x1d9eab+_0x4e23e0(0x1de)+_0x4f1fdd),console[_0x4e23e0(0x1e4)](_0x5c8dcd+'\x20\x20\x20Current\x20CLI\x20version:\x20'+_0x456197[_0x4e23e0(0x1d4)]+_0x4f1fdd),_0x456197[_0x4e23e0(0x1db)]&&console[_0x4e23e0(0x1e4)](_0x5c8dcd+_0x4e23e0(0x1e5)+_0x456197[_0x4e23e0(0x1db)]+_0x4f1fdd),_0x456197[_0x4e23e0(0x1d6)]&&_0x456197[_0x4e23e0(0x1d6)]!==_0x456197[_0x4e23e0(0x1db)]&&console[_0x4e23e0(0x1e4)](_0x5c8dcd+_0x4e23e0(0x1e7)+_0x456197[_0x4e23e0(0x1d6)]+_0x4f1fdd),_0x456197[_0x4e23e0(0x1f5)]&&console['log'](_0x5c8dcd+'\x20\x20\x20'+_0x456197[_0x4e23e0(0x1f5)]+_0x4f1fdd),console[_0x4e23e0(0x1e4)](_0x5c8dcd+_0x4e23e0(0x1d7)+_0xc7f7bb+_0x4f1fdd)):(console[_0x4e23e0(0x1e4)](''+_0x560e39+_0x1d9eab+_0x4e23e0(0x1df)+_0x4f1fdd),console[_0x4e23e0(0x1e4)](_0x560e39+_0x4e23e0(0x1ee)+_0x456197['currentVersion']+_0x4f1fdd),console[_0x4e23e0(0x1e4)](_0x560e39+'\x20\x20\x20Stable\x20version:\x20'+_0x456197[_0x4e23e0(0x1d6)]+_0x4f1fdd),_0x456197[_0x4e23e0(0x1ef)]&&console['log'](_0x560e39+'\x20\x20\x20'+_0x456197[_0x4e23e0(0x1ef)]+_0x4f1fdd),console['log'](_0x560e39+'\x20\x20\x20Upgrade\x20command:\x20'+_0xc7f7bb+_0x4f1fdd)),console[_0x4e23e0(0x1e4)]();}export function assertCliVersionSupported(_0x1f7056){const _0x35c09c=a224_0x5326;if(!_0x1f7056[_0x35c09c(0x1e1)])return;const _0x487383=[_0x1f7056[_0x35c09c(0x1f5)],_0x35c09c(0x1f7)+_0x1f7056[_0x35c09c(0x1d4)],_0x1f7056['minimumVersion']?_0x35c09c(0x1dc)+_0x1f7056['minimumVersion']:null,_0x35c09c(0x1da)+getCliUpgradeCommand(_0x1f7056)][_0x35c09c(0x1f3)](Boolean)[_0x35c09c(0x1fc)]('\x0a');throw CliErrors[_0x35c09c(0x1d8)](_0x35c09c(0x1d9),_0x487383);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2294a2,_0x21e634){const _0x49dc30=a225_0x5938,_0x23b628=_0x2294a2();while(!![]){try{const _0x235cea=-parseInt(_0x49dc30(0x122))/0x1+parseInt(_0x49dc30(0x11b))/0x2+parseInt(_0x49dc30(0x111))/0x3+parseInt(_0x49dc30(0x11f))/0x4+-parseInt(_0x49dc30(0x113))/0x5+parseInt(_0x49dc30(0x120))/0x6+parseInt(_0x49dc30(0x11e))/0x7*(-parseInt(_0x49dc30(0x11d))/0x8);if(_0x235cea===_0x21e634)break;else _0x23b628['push'](_0x23b628['shift']());}catch(_0x2c2ac9){_0x23b628['push'](_0x23b628['shift']());}}}(a225_0x85a2,0xabcf3));import{CLI_VERSION_POLICY_URL}from'../constant/cdn.js';function a225_0x85a2(){const _0x530f24=['signal','trim','1464610GatFTb','application/json','29816WaFcfx','4333XiBYJK','3174116hXJiAg','6413400RrAbjv','latestVersion','154919LXmadw','recommendedVersion','minVersion','json','3300984rEXqMy','string','2646995OEveim','length','cli','minimumVersionMessage','minimumVersion','upgradeMessage'];a225_0x85a2=function(){return _0x530f24;};return a225_0x85a2();}const CACHE_TTL=0x5*0x3c*0x3e8,FAILURE_CACHE_TTL=0x3c*0x3e8,FETCH_TIMEOUT_MS=0xbb8;function pickString(_0x249050){const _0x8f430d=a225_0x5938;return typeof _0x249050===_0x8f430d(0x112)&&_0x249050[_0x8f430d(0x11a)]()[_0x8f430d(0x114)]>0x0?_0x249050['trim']():null;}function normalizeCliVersionPolicy(_0x287c2a){const _0xaa81c6=a225_0x5938;if(!_0x287c2a||typeof _0x287c2a!=='object')return null;const _0x520612=_0x287c2a,_0x5a953a=_0x520612[_0xaa81c6(0x115)]&&typeof _0x520612[_0xaa81c6(0x115)]==='object'?_0x520612['cli']:_0x520612,_0x2249be=pickString(_0x5a953a['stableVersion'])||pickString(_0x5a953a[_0xaa81c6(0x121)])||pickString(_0x5a953a[_0xaa81c6(0x10e)]),_0x41aca8=pickString(_0x5a953a[_0xaa81c6(0x117)])||pickString(_0x5a953a[_0xaa81c6(0x10f)]);if(!_0x2249be&&!_0x41aca8)return null;return{'stableVersion':_0x2249be,'minimumVersion':_0x41aca8,'upgradeMessage':pickString(_0x5a953a[_0xaa81c6(0x118)])||undefined,'minimumVersionMessage':pickString(_0x5a953a[_0xaa81c6(0x116)])||undefined};}export async function fetchCliVersionPolicy(){const _0x19e45e=a225_0x5938,_0x499e68=new AbortController(),_0x384c69=setTimeout(()=>_0x499e68['abort'](),FETCH_TIMEOUT_MS);try{const _0x3f9562=await fetch(CLI_VERSION_POLICY_URL,{'headers':{'Accept':_0x19e45e(0x11c)},'signal':_0x499e68[_0x19e45e(0x119)]});if(!_0x3f9562['ok'])return null;const _0xee0c7f=await _0x3f9562[_0x19e45e(0x110)]();return normalizeCliVersionPolicy(_0xee0c7f);}catch{return null;}finally{clearTimeout(_0x384c69);}}function a225_0x5938(_0x2cc5bc,_0x4092f7){_0x2cc5bc=_0x2cc5bc-0x10e;const _0x85a2fe=a225_0x85a2();let _0x5938fe=_0x85a2fe[_0x2cc5bc];return _0x5938fe;}let cachedPolicy=null,cacheTime=0x0,hasCachedPolicy=![];export async function getCliVersionPolicy(){const _0x3047ca=Date['now']();if(hasCachedPolicy){const _0x1dcae9=cachedPolicy?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x3047ca-cacheTime<_0x1dcae9)return cachedPolicy;}const _0x1c758a=await fetchCliVersionPolicy();return cachedPolicy=_0x1c758a,cacheTime=_0x3047ca,hasCachedPolicy=!![],_0x1c758a;}export function clearCliVersionPolicyCache(){cachedPolicy=null,cacheTime=0x0,hasCachedPolicy=![];}
|
package/lib/utils/config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a226_0x32fe(_0x265f9b,_0x55af29){_0x265f9b=_0x265f9b-0x19a;const _0x158e40=a226_0x158e();let _0x32fea4=_0x158e40[_0x265f9b];return _0x32fea4;}(function(_0x30efa3,_0x1d670c){const _0x24278e=a226_0x32fe,_0x2c89ac=_0x30efa3();while(!![]){try{const _0x48348f=-parseInt(_0x24278e(0x1a5))/0x1*(parseInt(_0x24278e(0x1a3))/0x2)+-parseInt(_0x24278e(0x19f))/0x3*(parseInt(_0x24278e(0x1a6))/0x4)+parseInt(_0x24278e(0x1a1))/0x5+parseInt(_0x24278e(0x19c))/0x6*(-parseInt(_0x24278e(0x1a4))/0x7)+parseInt(_0x24278e(0x19b))/0x8*(-parseInt(_0x24278e(0x19d))/0x9)+-parseInt(_0x24278e(0x19a))/0xa*(-parseInt(_0x24278e(0x19e))/0xb)+parseInt(_0x24278e(0x1a0))/0xc;if(_0x48348f===_0x1d670c)break;else _0x2c89ac['push'](_0x2c89ac['shift']());}catch(_0x1b5195){_0x2c89ac['push'](_0x2c89ac['shift']());}}}(a226_0x158e,0x8b7e3));import{initEnv}from'../constant/env.js';import{readRawConfig,getConfigAppCode as a226_0x431b64,getMultiAppConfigs as a226_0x44adb6,getTemplateBaseUrl as a226_0x608b29}from'../context.js';export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';export{isInProject}from'../context.js';export function readConfig(_0x339e13){const _0x4dc109=a226_0x32fe,_0xe19092=readRawConfig(_0x339e13);return _0xe19092[_0x4dc109(0x1a2)]&&typeof _0xe19092[_0x4dc109(0x1a2)]==='string'&&initEnv(_0xe19092['env']),_0xe19092;}export function getConfigAppCode(){return a226_0x431b64();}function a226_0x158e(){const _0x4ca994=['211183okagRl','93967WHCOfk','156RwIrGB','7776190EFkfNK','156376gGEgwC','138VGUKXl','9pgRWYa','11qTGUQq','31548GPIgqO','5932752TRQfze','3993870INBhkh','env','8FFbMYl'];a226_0x158e=function(){return _0x4ca994;};return a226_0x158e();}export function getMultiAppConfigs(_0x551a76='project'){return a226_0x44adb6(_0x551a76);}export function getTemplateBaseUrl(){return a226_0x608b29();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x455120,_0x2966ba){const _0x8b9d1b=a227_0x87d0,_0x1762cf=_0x455120();while(!![]){try{const _0x2fbd56=parseInt(_0x8b9d1b(0xb4))/0x1+-parseInt(_0x8b9d1b(0xbd))/0x2+parseInt(_0x8b9d1b(0xbe))/0x3*(-parseInt(_0x8b9d1b(0xaf))/0x4)+parseInt(_0x8b9d1b(0xb2))/0x5*(-parseInt(_0x8b9d1b(0xb3))/0x6)+parseInt(_0x8b9d1b(0xbc))/0x7*(parseInt(_0x8b9d1b(0xbb))/0x8)+-parseInt(_0x8b9d1b(0xb0))/0x9*(parseInt(_0x8b9d1b(0xb8))/0xa)+parseInt(_0x8b9d1b(0xb1))/0xb;if(_0x2fbd56===_0x2966ba)break;else _0x1762cf['push'](_0x1762cf['shift']());}catch(_0x169a7d){_0x1762cf['push'](_0x1762cf['shift']());}}}(a227_0x28b2,0xb8332));import a227_0x31e937 from'node:path';function a227_0x28b2(){const _0x39f2cf=['4451499NMpztW','20474190aAsXRO','6149905ITRNbM','6TvDcHf','805334gFJLUC','join','readdirSync','isDirectory','10ABnNcs','error','name','25416xCijdw','1708mXfHLq','399740iiSlHB','6aMDTIU','mkdirSync','复制目录时出错:','1525736zVEzMa'];a227_0x28b2=function(){return _0x39f2cf;};return a227_0x28b2();}function a227_0x87d0(_0xb686d6,_0xa3ed45){_0xb686d6=_0xb686d6-0xaf;const _0x28b2a4=a227_0x28b2();let _0x87d078=_0x28b2a4[_0xb686d6];return _0x87d078;}import a227_0x40cd36 from'node:fs';export async function copyDirectory(_0x4bde27,_0x5cf322){const _0x2e722f=a227_0x87d0;try{const _0x381de3=a227_0x40cd36[_0x2e722f(0xb6)](_0x4bde27,{'withFileTypes':!![]});a227_0x40cd36[_0x2e722f(0xbf)](_0x5cf322,{'recursive':!![]});for(const _0x46750e of _0x381de3){const _0x2126d7=a227_0x31e937[_0x2e722f(0xb5)](_0x4bde27,_0x46750e[_0x2e722f(0xba)]),_0xe21dfb=a227_0x31e937[_0x2e722f(0xb5)](_0x5cf322,_0x46750e['name']);_0x46750e[_0x2e722f(0xb7)]()?await copyDirectory(_0x2126d7,_0xe21dfb):a227_0x40cd36['copyFileSync'](_0x2126d7,_0xe21dfb);}}catch(_0x1f0aef){console[_0x2e722f(0xb9)](_0x2e722f(0xc0),_0x1f0aef);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a228_0x2544(){const _0x355d0f=['2042817LUrjWm','145115YrbQQb','isFinite','trim','2734227GRYXJT','8mLSoOl','5080929qpmlkH','2lkqaix','222HRfabF','3850444dQMLFr','24386580GttZKa','1365015fkQLxY','object'];a228_0x2544=function(){return _0x355d0f;};return a228_0x2544();}(function(_0x431ed7,_0xad19cb){const _0x5b0f91=a228_0x2fb2,_0x48d433=_0x431ed7();while(!![]){try{const _0x1611a7=-parseInt(_0x5b0f91(0x1ad))/0x1+-parseInt(_0x5b0f91(0x1a9))/0x2*(parseInt(_0x5b0f91(0x1af))/0x3)+parseInt(_0x5b0f91(0x1ab))/0x4+parseInt(_0x5b0f91(0x1b0))/0x5*(-parseInt(_0x5b0f91(0x1aa))/0x6)+parseInt(_0x5b0f91(0x1a8))/0x7+parseInt(_0x5b0f91(0x1b4))/0x8*(-parseInt(_0x5b0f91(0x1b3))/0x9)+parseInt(_0x5b0f91(0x1ac))/0xa;if(_0x1611a7===_0xad19cb)break;else _0x48d433['push'](_0x48d433['shift']());}catch(_0x467222){_0x48d433['push'](_0x48d433['shift']());}}}(a228_0x2544,0xabc14));function toFiniteNumber(_0x4b87f2){const _0x378f6f=a228_0x2fb2;if(typeof _0x4b87f2==='number'&&Number[_0x378f6f(0x1b1)](_0x4b87f2))return _0x4b87f2;if(typeof _0x4b87f2==='string'){const _0x3ea839=_0x4b87f2[_0x378f6f(0x1b2)]();if(!_0x3ea839)return undefined;const _0x3c4a01=Number(_0x3ea839);if(Number['isFinite'](_0x3c4a01))return _0x3c4a01;}return undefined;}function a228_0x2fb2(_0x5c1b7b,_0x152f19){_0x5c1b7b=_0x5c1b7b-0x1a8;const _0x25449f=a228_0x2544();let _0x2fb20e=_0x25449f[_0x5c1b7b];return _0x2fb20e;}export function normalizeEntityWithIdResponse(_0x3a5116){const _0x254ff1=a228_0x2fb2,_0x45847f=toFiniteNumber(_0x3a5116);if(_0x45847f!==undefined)return{'id':_0x45847f,'entity':{'id':_0x45847f}};if(!_0x3a5116||typeof _0x3a5116!==_0x254ff1(0x1ae))return{'id':undefined,'entity':{}};const _0x500fd9={..._0x3a5116},_0x5ec273=toFiniteNumber(_0x500fd9['id']);return _0x5ec273!==undefined&&(_0x500fd9['id']=_0x5ec273),{'id':_0x5ec273,'entity':_0x500fd9};}
|
package/lib/utils/file-utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a229_0x1e50(_0x3fe6c1,_0x3926f0){_0x3fe6c1=_0x3fe6c1-0xdb;const _0x3cf9fb=a229_0x3cf9();let _0x1e5086=_0x3cf9fb[_0x3fe6c1];return _0x1e5086;}(function(_0x722a74,_0x1a90ae){const _0x36eca9=a229_0x1e50,_0x34251d=_0x722a74();while(!![]){try{const _0x234a6e=-parseInt(_0x36eca9(0xdc))/0x1+-parseInt(_0x36eca9(0xdf))/0x2*(parseInt(_0x36eca9(0xde))/0x3)+parseInt(_0x36eca9(0xe2))/0x4+parseInt(_0x36eca9(0xe4))/0x5*(parseInt(_0x36eca9(0xdd))/0x6)+-parseInt(_0x36eca9(0xe0))/0x7*(-parseInt(_0x36eca9(0xe5))/0x8)+parseInt(_0x36eca9(0xe3))/0x9+-parseInt(_0x36eca9(0xdb))/0xa;if(_0x234a6e===_0x1a90ae)break;else _0x34251d['push'](_0x34251d['shift']());}catch(_0x3d7f8a){_0x34251d['push'](_0x34251d['shift']());}}}(a229_0x3cf9,0x57012));import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';function a229_0x3cf9(){const _0x56f723=['74094nhsCFl','14760yZgpwX','9HHZPIM','15634Eegqqx','1617189xQnDXD','isDirectory','2727332aWCmfW','697338xBHezF','1435DjyeKt','16HeEDkJ','14734740ODwcFl'];a229_0x3cf9=function(){return _0x56f723;};return a229_0x3cf9();}export async function copyDir(_0x4db263,_0x354569){const _0xe1e39e=a229_0x1e50,_0x3be7ae=statSync(_0x4db263);if(_0x3be7ae[_0xe1e39e(0xe1)]()){!existsSync(_0x354569)&&mkdirSync(_0x354569,{'recursive':!![]});const _0x1b08e2=readdirSync(_0x4db263);for(const _0x49ac97 of _0x1b08e2){await copyDir(join(_0x4db263,_0x49ac97),join(_0x354569,_0x49ac97));}}else copyFileSync(_0x4db263,_0x354569);}export function ensureDir(_0x2a968c){!existsSync(_0x2a968c)&&mkdirSync(_0x2a968c,{'recursive':!![]});}export function pathExists(_0x85d3c2){return existsSync(_0x85d3c2);}
|
package/lib/utils/guides-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a230_0x4497e8=a230_0xb52c;(function(_0x303b20,_0x3ac6fa){const _0x33a8c6=a230_0xb52c,_0x59cc5e=_0x303b20();while(!![]){try{const _0x2704cf=parseInt(_0x33a8c6(0xb4))/0x1*(parseInt(_0x33a8c6(0xa5))/0x2)+-parseInt(_0x33a8c6(0x99))/0x3*(-parseInt(_0x33a8c6(0x9e))/0x4)+-parseInt(_0x33a8c6(0x9a))/0x5*(-parseInt(_0x33a8c6(0xb7))/0x6)+parseInt(_0x33a8c6(0xa7))/0x7+parseInt(_0x33a8c6(0x96))/0x8*(parseInt(_0x33a8c6(0xa2))/0x9)+parseInt(_0x33a8c6(0x9f))/0xa*(-parseInt(_0x33a8c6(0x9c))/0xb)+-parseInt(_0x33a8c6(0xb3))/0xc;if(_0x2704cf===_0x3ac6fa)break;else _0x59cc5e['push'](_0x59cc5e['shift']());}catch(_0x52c28d){_0x59cc5e['push'](_0x59cc5e['shift']());}}}(a230_0x262b,0x54bca));function a230_0xb52c(_0x5a82e6,_0x79cb90){_0x5a82e6=_0x5a82e6-0x95;const _0x262b71=a230_0x262b();let _0xb52c7a=_0x262b71[_0x5a82e6];return _0xb52c7a;}import{mkdirSync,writeFileSync}from'node:fs';import{dirname,join}from'node:path';import{homedir}from'node:os';import{getTemplateBaseUrl}from'../utils/config.js';function getGuidesCdnUrl(){const _0x2a3a63=a230_0xb52c,_0x1622aa=getTemplateBaseUrl();return _0x1622aa+_0x2a3a63(0xb1);}const CACHE_DIR=join(homedir(),a230_0x4497e8(0xa8),a230_0x4497e8(0xae));export async function fetchGuidesFromCDN(){const _0x3160d5=a230_0x4497e8,_0x125ea3=getGuidesCdnUrl(),_0x203537=await fetch(_0x125ea3,{'headers':{'Accept':_0x3160d5(0xb6)}});if(!_0x203537['ok'])throw new Error(_0x3160d5(0x97)+_0x203537['status']+'\x20'+_0x203537[_0x3160d5(0x9b)]);const _0x598ab0=await _0x203537[_0x3160d5(0x95)]();if(!_0x598ab0[_0x3160d5(0xa6)]||typeof _0x598ab0[_0x3160d5(0xa6)]!==_0x3160d5(0xad))throw new Error(_0x3160d5(0xab));return _0x598ab0;}function a230_0x262b(){const _0x21f281=['2362494OpCIsi','json','311776CIyBbb','CDN\x20请求失败:\x20','\x0a\x0a>更新时间:','219vPalVk','5NLyrRb','statusText','167849cZHBmh','skillTemplate','8788cJHlrN','70cJNHHS','extendContent','trimEnd','63BkzEjh','lastUpdated','entries','7024YcvDWE','guides','2806748ctJYwj','.lovrabet','keys','utf-8','CDN\x20返回数据格式错误','length','object','cache','push','.md','/skills/guides.json','map','15525348WbCiDT','148kZLvWJ','content','application/json'];a230_0x262b=function(){return _0x21f281;};return a230_0x262b();}export function writeGuidesToProject(_0xdef647,_0x168923,_0x35cf84='.lovrabet/skill/guides',_0x3f1793){const _0x3bf1ab=a230_0x4497e8,_0x580750=join(_0x168923,_0x35cf84);mkdirSync(_0x580750,{'recursive':!![]});for(const [_0x140000,_0x1f17a1]of Object[_0x3bf1ab(0xa4)](_0xdef647[_0x3bf1ab(0xa6)])){let _0x2be549=_0x1f17a1[_0x3bf1ab(0xb5)];_0x1f17a1[_0x3bf1ab(0xa3)]&&(_0x2be549=appendUpdateTime(_0x2be549,_0x1f17a1[_0x3bf1ab(0xa3)])),writeFileSync(join(_0x580750,_0x140000+_0x3bf1ab(0xb0)),_0x2be549,_0x3bf1ab(0xaa));}}export function appendUpdateTime(_0xe62d39,_0x6680be){const _0xc43f41=a230_0x4497e8;return _0xe62d39=_0xe62d39['replace'](/\n*>更新时间:.*$/m,''),_0xe62d39['trimEnd']()+(_0xc43f41(0x98)+_0x6680be);}export function getSkillTemplate(_0x579042){const _0x3723de=a230_0x4497e8;return _0x579042[_0x3723de(0x9d)]?.[_0x3723de(0xb5)]||'';}export function appendExtendContents(_0x53e0e1,_0x24687b,_0x490381){const _0x545f70=a230_0x4497e8,_0x3687bc=[];for(const [,_0x4dee28]of Object[_0x545f70(0xa4)](_0x24687b['guides'])){_0x4dee28[_0x545f70(0xa0)]&&_0x3687bc[_0x545f70(0xaf)](_0x4dee28['extendContent'][_0x545f70(0xa1)]());}if(_0x3687bc[_0x545f70(0xac)]===0x0)return _0x53e0e1;return _0x53e0e1[_0x545f70(0xa1)]()+'\x0a\x0a'+_0x3687bc['join']('\x0a\x0a')+'\x0a';}export function writeSkillFile(_0x273fb6,_0x290cb2,_0x28f83c){const _0x5998ea=a230_0x4497e8,_0x463663=getSkillTemplate(_0x273fb6);if(!_0x463663)throw new Error('CDN\x20数据中缺少\x20skillTemplate');const _0x598f2a=dirname(_0x290cb2);mkdirSync(_0x598f2a,{'recursive':!![]});let _0x131e8f=_0x463663['replace'](/\{\{IDE_NAME\}\}/g,_0x28f83c);_0x131e8f=appendExtendContents(_0x131e8f,_0x273fb6),_0x273fb6[_0x5998ea(0x9d)][_0x5998ea(0xa3)]&&(_0x131e8f=appendUpdateTime(_0x131e8f,_0x273fb6[_0x5998ea(0x9d)][_0x5998ea(0xa3)])),writeFileSync(_0x290cb2,_0x131e8f,_0x5998ea(0xaa));}export async function installGuides(_0x1703a8){const _0x261ee0=a230_0x4497e8,_0x178d15=await fetchGuidesFromCDN();return writeGuidesToProject(_0x178d15,_0x1703a8),Object[_0x261ee0(0xa9)](_0x178d15[_0x261ee0(0xa6)])[_0x261ee0(0xac)];}export function getGuidesSummary(_0x56b037){const _0x39c856=a230_0x4497e8;return Object['entries'](_0x56b037[_0x39c856(0xa6)])[_0x39c856(0xb2)](([_0x388cae,_0x2ee1dc])=>({'key':_0x388cae,'title':_0x2ee1dc['title'],'path':_0x2ee1dc['path']}));}
|
package/lib/utils/http-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x383b39,_0x58a020){const _0x2889aa=a231_0x4833,_0x4aa443=_0x383b39();while(!![]){try{const _0x543668=parseInt(_0x2889aa(0xe7))/0x1*(-parseInt(_0x2889aa(0xe9))/0x2)+-parseInt(_0x2889aa(0xfe))/0x3+-parseInt(_0x2889aa(0xe5))/0x4+-parseInt(_0x2889aa(0xf8))/0x5+-parseInt(_0x2889aa(0xf4))/0x6+parseInt(_0x2889aa(0xff))/0x7*(parseInt(_0x2889aa(0xf0))/0x8)+parseInt(_0x2889aa(0xe6))/0x9;if(_0x543668===_0x58a020)break;else _0x4aa443['push'](_0x4aa443['shift']());}catch(_0x332278){_0x4aa443['push'](_0x4aa443['shift']());}}}(a231_0x1594,0xceb60));export async function httpRequest(_0x177dfa,_0x320be4={}){const _0x34654d=a231_0x4833,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x320be4;let _0x3ebff7=null;for(let _0x510cde=0x0;_0x510cde<=retries;_0x510cde++){try{const _0x470c72=new AbortController(),_0x2d2462=setTimeout(()=>_0x470c72[_0x34654d(0x101)](),timeout),_0x2411d4=await fetch(_0x177dfa,{'headers':headers,'signal':_0x470c72[_0x34654d(0xf3)]});clearTimeout(_0x2d2462);let _0x399248;const _0xf8ed40=_0x2411d4['headers']['get'](_0x34654d(0xfb));return _0xf8ed40?.[_0x34654d(0xf1)](_0x34654d(0xf7))?_0x399248=await _0x2411d4[_0x34654d(0xfa)]():_0x399248=await _0x2411d4[_0x34654d(0xf6)](),{'ok':_0x2411d4['ok'],'status':_0x2411d4[_0x34654d(0xf9)],'statusText':_0x2411d4[_0x34654d(0x100)],'data':_0x399248,'headers':_0x2411d4[_0x34654d(0xee)],'url':_0x2411d4[_0x34654d(0xef)],'text':()=>_0x2411d4[_0x34654d(0xf6)]()};}catch(_0x4a9e4f){_0x3ebff7=_0x4a9e4f instanceof Error?_0x4a9e4f:new Error(String(_0x4a9e4f));if(_0x510cde===retries)break;if(shouldRetry(_0x4a9e4f)){console[_0x34654d(0xf5)](_0x34654d(0xed)+retryDelay+_0x34654d(0xea)+(_0x510cde+0x1)+_0x34654d(0xfc)),await sleep(retryDelay);continue;}else break;}}throw _0x3ebff7||new Error(_0x34654d(0xfd));}function shouldRetry(_0x30903d){const _0x5a1c53=a231_0x4833;if(_0x30903d instanceof Error){if(_0x30903d['name']===_0x5a1c53(0xf2))return![];if(_0x30903d['name']===_0x5a1c53(0xec)&&_0x30903d[_0x5a1c53(0xeb)][_0x5a1c53(0xf1)](_0x5a1c53(0xe8)))return!![];if(_0x30903d[_0x5a1c53(0xeb)][_0x5a1c53(0xf1)]('ECONNRESET'))return!![];if(_0x30903d[_0x5a1c53(0xeb)]['includes']('ENOTFOUND'))return![];}return![];}function a231_0x1594(){const _0xe16efc=['5566876QkkGxG','34298082LXwIZb','1CVhFtr','fetch','591374kOoDid','ms\x20后进行第\x20','message','TypeError','*\x20请求失败,','headers','url','313160eSkJmX','includes','AbortError','signal','799590uwpMxU','log','text','application/json','272490dQRcTm','status','json','content-type','\x20次重试...','Request\x20failed','3619428jkYDTw','21sEwfIy','statusText','abort'];a231_0x1594=function(){return _0xe16efc;};return a231_0x1594();}function a231_0x4833(_0x3db9e7,_0x4b417e){_0x3db9e7=_0x3db9e7-0xe5;const _0x1594ff=a231_0x1594();let _0x4833ad=_0x1594ff[_0x3db9e7];return _0x4833ad;}function sleep(_0x5c2769){return new Promise(_0x61101e=>setTimeout(_0x61101e,_0x5c2769));}export function validateUrl(_0x2327a7){try{return new URL(_0x2327a7),!![];}catch{return![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a232_0x3cbb(_0x2756d2,_0x2154cf){_0x2756d2=_0x2756d2-0xc9;const _0x4b36ba=a232_0x4b36();let _0x3cbb62=_0x4b36ba[_0x2756d2];return _0x3cbb62;}(function(_0x102f4b,_0x16428e){const _0x2b1992=a232_0x3cbb,_0x5e8299=_0x102f4b();while(!![]){try{const _0x1a8dcb=-parseInt(_0x2b1992(0xcf))/0x1*(parseInt(_0x2b1992(0xd0))/0x2)+parseInt(_0x2b1992(0xd3))/0x3*(-parseInt(_0x2b1992(0xcb))/0x4)+-parseInt(_0x2b1992(0xd7))/0x5+-parseInt(_0x2b1992(0xd1))/0x6*(-parseInt(_0x2b1992(0xd2))/0x7)+-parseInt(_0x2b1992(0xd5))/0x8+parseInt(_0x2b1992(0xce))/0x9*(parseInt(_0x2b1992(0xcd))/0xa)+-parseInt(_0x2b1992(0xc9))/0xb*(parseInt(_0x2b1992(0xca))/0xc);if(_0x1a8dcb===_0x16428e)break;else _0x5e8299['push'](_0x5e8299['shift']());}catch(_0x35895c){_0x5e8299['push'](_0x5e8299['shift']());}}}(a232_0x4b36,0xb087e));function env(_0x23e487){return process.env[`RABETBASE_${_0x23e487}`]||process.env[`LOVRABET_${_0x23e487}`]||undefined;}export function isNonInteractive(_0x4d3cb6){const _0x26bf3c=a232_0x3cbb;return!!(_0x4d3cb6['nonInteractive']||_0x4d3cb6['ci']||env('CI')===_0x26bf3c(0xd6)||process.env.CI===_0x26bf3c(0xd6)||!process[_0x26bf3c(0xd9)]['isTTY']||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x59e4d7=a232_0x3cbb;if(!process[_0x59e4d7(0xd8)]['isTTY'])return![];try{const _0x47d547=process[_0x59e4d7(0xd8)][_0x59e4d7(0xcc)];return process['stdin'][_0x59e4d7(0xd4)](!![]),process['stdin'][_0x59e4d7(0xd4)](_0x47d547??![]),!![];}catch{return![];}}function a232_0x4b36(){const _0x23e1a2=['2122365AxovKc','stdin','stdout','1507MAGfYu','20748UOWrog','128888VftmUU','isRaw','40hTNLvl','2587770EjXHAl','2QLBNDf','933848mPHoJr','8475426qDQcbv','7DpuRrP','3fuXkTr','setRawMode','1697640AetlvA','true'];a232_0x4b36=function(){return _0x23e1a2;};return a232_0x4b36();}
|
package/lib/utils/logger.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a233_0x181e0a=a233_0x510d;function a233_0x510d(_0x319e6,_0x1ba411){_0x319e6=_0x319e6-0x144;const _0x4b255b=a233_0x4b25();let _0x510da2=_0x4b255b[_0x319e6];return _0x510da2;}(function(_0x5152eb,_0x4e3d83){const _0x4e7c0e=a233_0x510d,_0x1bc4d9=_0x5152eb();while(!![]){try{const _0x34d54a=parseInt(_0x4e7c0e(0x174))/0x1+parseInt(_0x4e7c0e(0x146))/0x2+parseInt(_0x4e7c0e(0x15b))/0x3+-parseInt(_0x4e7c0e(0x161))/0x4+parseInt(_0x4e7c0e(0x168))/0x5+-parseInt(_0x4e7c0e(0x173))/0x6*(-parseInt(_0x4e7c0e(0x15a))/0x7)+-parseInt(_0x4e7c0e(0x15c))/0x8;if(_0x34d54a===_0x4e3d83)break;else _0x1bc4d9['push'](_0x1bc4d9['shift']());}catch(_0x34a782){_0x1bc4d9['push'](_0x1bc4d9['shift']());}}}(a233_0x4b25,0xe86f5));import a233_0x103902 from'winston';import a233_0x9fb554 from'node:fs';import a233_0x49a3d3 from'node:path';class Logger{[a233_0x181e0a(0x16f)];[a233_0x181e0a(0x149)];[a233_0x181e0a(0x169)]='';constructor(){this['logFilePath']='';}[a233_0x181e0a(0x15d)](_0x1bbbb5){this['currentRawCommand']=_0x1bbbb5;}[a233_0x181e0a(0x16a)](){const _0x4b7987=a233_0x181e0a,_0x5b7e39=a233_0x49a3d3['dirname'](this[_0x4b7987(0x149)]);!a233_0x9fb554[_0x4b7987(0x16b)](_0x5b7e39)&&a233_0x9fb554['mkdirSync'](_0x5b7e39,{'recursive':!![]});const _0x21cf55=a233_0x103902[_0x4b7987(0x165)][_0x4b7987(0x145)](a233_0x103902[_0x4b7987(0x165)][_0x4b7987(0x156)](),a233_0x103902['format']['errors']({'stack':!![]}),a233_0x103902[_0x4b7987(0x165)][_0x4b7987(0x147)](_0x397594=>{const _0xbc0702=_0x4b7987,_0x4b2092={'timestamp':_0x397594[_0xbc0702(0x156)]||new Date()[_0xbc0702(0x150)](),'level':_0x397594[_0xbc0702(0x172)]||'info','command':_0x397594[_0xbc0702(0x148)]||_0xbc0702(0x163),'rawCommand':_0x397594[_0xbc0702(0x162)]||this[_0xbc0702(0x169)]||undefined,'message':_0x397594[_0xbc0702(0x14c)]||'','duration':_0x397594['duration']||undefined,'details':_0x397594[_0xbc0702(0x159)]||undefined};return JSON[_0xbc0702(0x152)](_0x4b2092);}));this[_0x4b7987(0x16f)]=a233_0x103902[_0x4b7987(0x16e)]({'level':'info','format':_0x21cf55,'transports':[new a233_0x103902[(_0x4b7987(0x14b))][(_0x4b7987(0x170))]({'filename':this[_0x4b7987(0x149)],'level':_0x4b7987(0x155)})],'silent':![]}),a233_0x103902['addColors']({'success':_0x4b7987(0x160),'error':'red','warn':_0x4b7987(0x15f),'info':'blue'});}[a233_0x181e0a(0x14e)](_0x2c92e8){const _0x420daa=a233_0x181e0a;this[_0x420daa(0x149)]=a233_0x49a3d3[_0x420daa(0x15e)](_0x2c92e8,_0x420daa(0x153)),this['winstonLogger']&&this[_0x420daa(0x16f)][_0x420daa(0x14d)](),this[_0x420daa(0x16a)]();}[a233_0x181e0a(0x155)](_0x5970f1,_0x39d99c,_0x4d292e){const _0x518f00=a233_0x181e0a;if(!this['logFilePath']||!this[_0x518f00(0x16f)])return;this['winstonLogger']['info'](_0x39d99c,{'command':_0x5970f1,'details':_0x4d292e});}[a233_0x181e0a(0x144)](_0xa4a2ac,_0x404c4e,_0x39f607,_0x1cbc48){const _0x190618=a233_0x181e0a;if(!this['logFilePath']||!this[_0x190618(0x16f)])return;this[_0x190618(0x16f)]['log'](_0x190618(0x155),_0x404c4e,{'level':'success','command':_0xa4a2ac,'duration':_0x39f607,'details':_0x1cbc48});}[a233_0x181e0a(0x14a)](_0x15e022,_0x1dc178,_0x5361a7){const _0x34a63f=a233_0x181e0a;if(!this[_0x34a63f(0x149)]||!this[_0x34a63f(0x16f)])return;this[_0x34a63f(0x16f)][_0x34a63f(0x14a)](_0x1dc178,{'command':_0x15e022,'details':_0x5361a7});}['warn'](_0x446493,_0x41512c,_0x23cf3e){const _0x2defaa=a233_0x181e0a;if(!this['logFilePath']||!this[_0x2defaa(0x16f)])return;this[_0x2defaa(0x16f)][_0x2defaa(0x164)](_0x41512c,{'command':_0x446493,'details':_0x23cf3e});}async['logTask'](_0x5f3aad,_0x217dcf,_0x28635b){const _0x37b00a=a233_0x181e0a,_0x12c4d8=Date[_0x37b00a(0x14f)]();this[_0x37b00a(0x155)](_0x5f3aad,_0x37b00a(0x167)+_0x217dcf);try{const _0x2cf627=await _0x28635b(),_0x453b0b=Date['now']()-_0x12c4d8;return this[_0x37b00a(0x144)](_0x5f3aad,_0x37b00a(0x154)+_0x217dcf,_0x453b0b),_0x2cf627;}catch(_0xc287a0){const _0x468c5d=Date[_0x37b00a(0x14f)]()-_0x12c4d8;this[_0x37b00a(0x14a)](_0x5f3aad,'失败:\x20'+_0x217dcf,{'error':_0xc287a0 instanceof Error?_0xc287a0[_0x37b00a(0x14c)]:String(_0xc287a0),'duration':_0x468c5d});throw _0xc287a0;}}[a233_0x181e0a(0x175)](){const _0x450982=a233_0x181e0a;try{if(!a233_0x9fb554[_0x450982(0x16b)](this[_0x450982(0x149)]))return[];const _0x577fe6=a233_0x9fb554['readFileSync'](this['logFilePath'],_0x450982(0x16d));return _0x577fe6[_0x450982(0x166)]('\x0a')[_0x450982(0x151)](_0x2d70c5=>_0x2d70c5[_0x450982(0x16c)]())[_0x450982(0x158)](_0x4845=>JSON['parse'](_0x4845));}catch(_0x2e2094){return console[_0x450982(0x164)](_0x450982(0x171),_0x2e2094),[];}}['clearLogs'](){const _0xa1cdf3=a233_0x181e0a;try{a233_0x9fb554[_0xa1cdf3(0x16b)](this[_0xa1cdf3(0x149)])&&a233_0x9fb554['writeFileSync'](this[_0xa1cdf3(0x149)],'','utf8');}catch(_0x4f56d0){console['warn']('Failed\x20to\x20clear\x20logs:',_0x4f56d0);}}[a233_0x181e0a(0x157)](){const _0x57e3ec=a233_0x181e0a;return this[_0x57e3ec(0x16f)];}}export const logger=new Logger();function a233_0x4b25(){const _0x3dad77=['now','toISOString','filter','stringify','.lovrabet.log','完成:\x20','info','timestamp','getWinstonInstance','map','details','1309OKOyyk','3575436raPWbV','12332528JSGPUf','setRawCommand','join','yellow','green','5762388UxVPez','rawCommand','unknown','warn','format','split','开始执行:\x20','3741330oAeqhs','currentRawCommand','initWinstonLogger','existsSync','trim','utf8','createLogger','winstonLogger','File','Failed\x20to\x20read\x20logs:','level','10722XDCoSz','1208175hMADoA','readLogs','success','combine','903588FpnXHJ','printf','command','logFilePath','error','transports','message','clear','setLogPath'];a233_0x4b25=function(){return _0x3dad77;};return a233_0x4b25();}
|
package/lib/utils/params.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a234_0x9e7c(_0xe27fd9,_0x610b6e){_0xe27fd9=_0xe27fd9-0x134;const _0x5c5bf9=a234_0x5c5b();let _0x9e7c43=_0x5c5bf9[_0xe27fd9];return _0x9e7c43;}(function(_0x2f1fc5,_0x61596){const _0x2f3f83=a234_0x9e7c,_0x32fb14=_0x2f1fc5();while(!![]){try{const _0x12e98d=-parseInt(_0x2f3f83(0x13a))/0x1*(parseInt(_0x2f3f83(0x13f))/0x2)+-parseInt(_0x2f3f83(0x13c))/0x3*(parseInt(_0x2f3f83(0x135))/0x4)+parseInt(_0x2f3f83(0x140))/0x5*(-parseInt(_0x2f3f83(0x139))/0x6)+-parseInt(_0x2f3f83(0x142))/0x7+parseInt(_0x2f3f83(0x13d))/0x8*(parseInt(_0x2f3f83(0x143))/0x9)+-parseInt(_0x2f3f83(0x13e))/0xa+parseInt(_0x2f3f83(0x137))/0xb;if(_0x12e98d===_0x61596)break;else _0x32fb14['push'](_0x32fb14['shift']());}catch(_0xc964f6){_0x32fb14['push'](_0x32fb14['shift']());}}}(a234_0x5c5b,0xdeeca));import{CliErrors}from'../errors.js';export function parseJsonParams(_0x29e6e6){const _0x415405=a234_0x9e7c;if(!_0x29e6e6)return undefined;let _0x5313cd;try{_0x5313cd=JSON[_0x415405(0x141)](_0x29e6e6);}catch{throw CliErrors[_0x415405(0x136)](_0x415405(0x134)+_0x29e6e6);}if(!_0x5313cd||typeof _0x5313cd!==_0x415405(0x138)||Array['isArray'](_0x5313cd))throw CliErrors[_0x415405(0x136)]('--params\x20must\x20be\x20a\x20JSON\x20object',_0x415405(0x13b));return _0x5313cd;}function a234_0x5c5b(){const _0x2f28df=['10gRJqvl','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','3nEeVju','178976OMGUkX','3390960ICbEdx','169578AZDsvZ','2774220WnKpra','parse','2958466GERsLx','423nviDQm','Invalid\x20JSON\x20for\x20--params:\x20','3075268XEQFYk','validation','30743889CTOyoX','object','6pwaVXM'];a234_0x5c5b=function(){return _0x2f28df;};return a234_0x5c5b();}
|
package/lib/utils/platform.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a235_0xaa09(_0x293805,_0x1b615c){_0x293805=_0x293805-0x65;const _0x5a749a=a235_0x5a74();let _0xaa09c1=_0x5a749a[_0x293805];return _0xaa09c1;}const a235_0x39d86d=a235_0xaa09;(function(_0x2903b6,_0x492e37){const _0x4cfc30=a235_0xaa09,_0x173ba2=_0x2903b6();while(!![]){try{const _0x42c000=-parseInt(_0x4cfc30(0x67))/0x1*(parseInt(_0x4cfc30(0x6b))/0x2)+-parseInt(_0x4cfc30(0x6a))/0x3+parseInt(_0x4cfc30(0x66))/0x4*(-parseInt(_0x4cfc30(0x65))/0x5)+-parseInt(_0x4cfc30(0x6f))/0x6+parseInt(_0x4cfc30(0x68))/0x7+parseInt(_0x4cfc30(0x69))/0x8+parseInt(_0x4cfc30(0x6d))/0x9;if(_0x42c000===_0x492e37)break;else _0x173ba2['push'](_0x173ba2['shift']());}catch(_0xdb8191){_0x173ba2['push'](_0x173ba2['shift']());}}}(a235_0x5a74,0x8559d));export const isWindows=process[a235_0x39d86d(0x6e)]===a235_0x39d86d(0x6c);export function resolveNpmBin(_0x109920){const _0x9609df=a235_0x39d86d;return isWindows?_0x109920+_0x9609df(0x70):_0x109920;}function a235_0x5a74(){const _0x216ee5=['89pboKwm','2395218fWwXsn','8676112eyqMya','1290468SOdOHi','13388uRUukD','win32','10142937OkYtTe','platform','512958BIZvLR','.cmd','4480305IgiTAH','4GNmXoo'];a235_0x5a74=function(){return _0x216ee5;};return a235_0x5a74();}
|
package/lib/utils/rules-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a236_0x5b36(){const _0x597c7d=['3094242zLLJvp','application/json','string','lovrabet_rules.mdc','本地模板文件不存在:\x20','utf-8','2828ZYfNKK','../../templates/rules/lovrabet_rules.mdc.tpl','21679317KTGpUe','.cursor/rules','content','750557yEiEfL','agents.md','5lPEXna','statusText','json','31664BdDKnX','1408392eSNQhT','6558426jSilXP','status','572769NApFNS'];a236_0x5b36=function(){return _0x597c7d;};return a236_0x5b36();}const a236_0x310081=a236_0x3828;(function(_0x348d17,_0x2ec87d){const _0xf374da=a236_0x3828,_0x1b3f09=_0x348d17();while(!![]){try{const _0x5c2232=parseInt(_0xf374da(0x109))/0x1+parseInt(_0xf374da(0x113))/0x2+parseInt(_0xf374da(0x112))/0x3+parseInt(_0xf374da(0x10f))/0x4+parseInt(_0xf374da(0x10b))/0x5*(-parseInt(_0xf374da(0x110))/0x6)+-parseInt(_0xf374da(0x119))/0x7*(-parseInt(_0xf374da(0x10e))/0x8)+-parseInt(_0xf374da(0x106))/0x9;if(_0x5c2232===_0x2ec87d)break;else _0x1b3f09['push'](_0x1b3f09['shift']());}catch(_0x1b9b0d){_0x1b3f09['push'](_0x1b3f09['shift']());}}}(a236_0x5b36,0xe4f77));import{existsSync,mkdirSync,readFileSync,writeFileSync}from'node:fs';import{dirname,join,resolve}from'node:path';import{fileURLToPath}from'node:url';import{getTemplateBaseUrl}from'../utils/config.js';import{appendUpdateTime}from'../utils/guides-cdn.js';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function getRulesCdnUrl(){const _0x108a26=getTemplateBaseUrl();return _0x108a26+'/rules/rules.json';}const LOCAL_TEMPLATE_PATH=resolve(__dirname,a236_0x310081(0x11a));export async function fetchRulesFromCDN(){const _0x11fdd6=a236_0x310081,_0x2ee3d5=getRulesCdnUrl(),_0x5b3a8c=await fetch(_0x2ee3d5,{'headers':{'Accept':_0x11fdd6(0x114)}});if(!_0x5b3a8c['ok'])throw new Error('CDN\x20请求失败:\x20'+_0x5b3a8c[_0x11fdd6(0x111)]+'\x20'+_0x5b3a8c[_0x11fdd6(0x10c)]);const _0x246e3b=await _0x5b3a8c[_0x11fdd6(0x10d)]();if(!_0x246e3b[_0x11fdd6(0x108)]||typeof _0x246e3b[_0x11fdd6(0x108)]!==_0x11fdd6(0x115))throw new Error('CDN\x20返回数据格式错误');return _0x246e3b;}export async function getRulesContent(){const _0x3a6162=a236_0x310081;try{const _0x4b26f5=await fetchRulesFromCDN();return _0x4b26f5[_0x3a6162(0x108)];}catch{return readLocalTemplate();}}export function readLocalTemplate(){const _0x278fb1=a236_0x310081;if(existsSync(LOCAL_TEMPLATE_PATH))return readFileSync(LOCAL_TEMPLATE_PATH,'utf-8');throw new Error(_0x278fb1(0x117)+LOCAL_TEMPLATE_PATH);}function a236_0x3828(_0x4f049a,_0x40bdaf){_0x4f049a=_0x4f049a-0x106;const _0x5b368c=a236_0x5b36();let _0x38288e=_0x5b368c[_0x4f049a];return _0x38288e;}export async function writeRulesFile(_0x151796){const _0x79082a=a236_0x310081,_0x4312e8=await fetchRulesFromCDN()['catch'](()=>null);let _0x1daa06;_0x4312e8?(_0x1daa06=_0x4312e8[_0x79082a(0x108)],_0x4312e8['lastUpdated']&&(_0x1daa06=appendUpdateTime(_0x1daa06,_0x4312e8['lastUpdated']))):_0x1daa06=readLocalTemplate();const _0x5c8986=dirname(_0x151796);!existsSync(_0x5c8986)&&mkdirSync(_0x5c8986,{'recursive':!![]}),writeFileSync(_0x151796,_0x1daa06,_0x79082a(0x118));}export async function copyRulesToCursor(_0x35be29){const _0x637a2d=a236_0x310081,_0x64698b=join(_0x35be29,_0x637a2d(0x107)),_0x351d6a=join(_0x64698b,_0x637a2d(0x116));if(existsSync(_0x351d6a))return![];return await writeRulesFile(_0x351d6a),!![];}export async function copyRulesToAgentsMd(_0x36bf37){const _0x2d23f1=a236_0x310081,_0x4ba3dd=join(_0x36bf37,_0x2d23f1(0x10a));if(existsSync(_0x4ba3dd))return![];return await writeRulesFile(_0x4ba3dd),!![];}
|
package/lib/utils/sleep.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export function sleep(
|
|
1
|
+
export function sleep(_0xd98191){return new Promise(_0x12cb29=>setTimeout(_0x12cb29,_0xd98191));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a238_0x41187f=a238_0x26a0;function a238_0x4f20(){const _0x266514=['template','default','success','模板内容替换失败','getMonth','pad','.jsx','replaceApiContent','promises','join','42QpupZF','processTemplate','.js','info','datasetCode:\x20\x22','slice','now','alias','.css','.ts','\x20},','\x0a\x20\x20\x20\x20{\x20','toLowerCase','getFullYear','utf8','replaceContent','name','processDirectory','774hgcVUZ','4dPjFyI','name:\x20\x22','datasetCode','toComponentName','32610aFgmmh','endsWith','charAt','readdir','alias:\x20\x22','.tpl','mkdir','toUpperCase','.md','382314FlIqJB','formatLocalTimestamp','getHours','push','toDisplayTitle','tableName','split','模板内容替换完成','extname','error','2568840hlpNpu','writeFile','688945PFccoM','processFile','message','toISOString','63951aeFfxK','.json','.tsx','map','getDate','tableName:\x20\x22','pop','10493736wUmhXF','LOVRABET','replace','isFile','12FePpih','4931NhSbGV'];a238_0x4f20=function(){return _0x266514;};return a238_0x4f20();}(function(_0x3357dd,_0x362f42){const _0xa10402=a238_0x26a0,_0x3b41fd=_0x3357dd();while(!![]){try{const _0x2d6155=-parseInt(_0xa10402(0x108))/0x1+parseInt(_0xa10402(0x107))/0x2*(-parseInt(_0xa10402(0x143))/0x3)+-parseInt(_0xa10402(0x126))/0x4*(parseInt(_0xa10402(0x13f))/0x5)+parseInt(_0xa10402(0x133))/0x6*(-parseInt(_0xa10402(0x113))/0x7)+-parseInt(_0xa10402(0x13d))/0x8+-parseInt(_0xa10402(0x125))/0x9*(-parseInt(_0xa10402(0x12a))/0xa)+parseInt(_0xa10402(0x14a))/0xb;if(_0x2d6155===_0x362f42)break;else _0x3b41fd['push'](_0x3b41fd['shift']());}catch(_0x1235fb){_0x3b41fd['push'](_0x3b41fd['shift']());}}}(a238_0x4f20,0x3f91d));import a238_0x34807b from'node:fs';import a238_0x2e6a20 from'node:path';import{logger}from'../utils/logger.js';import{getCliVersion}from'../utils/version.js';const CLI_VERSION=getCliVersion();function a238_0x26a0(_0x2f6b96,_0x176981){_0x2f6b96=_0x2f6b96-0x104;const _0x4f20b4=a238_0x4f20();let _0x26a05b=_0x4f20b4[_0x2f6b96];return _0x26a05b;}export class TemplateReplacer{static['pad'](_0x47ac34){return String(_0x47ac34)['padStart'](0x2,'0');}static[a238_0x41187f(0x134)](_0xfee484){const _0x5f31ca=a238_0x41187f,_0x3dd006=_0xfee484[_0x5f31ca(0x120)](),_0x93c2db=this[_0x5f31ca(0x10e)](_0xfee484[_0x5f31ca(0x10d)]()+0x1),_0x13c859=this[_0x5f31ca(0x10e)](_0xfee484[_0x5f31ca(0x147)]()),_0x99d689=this[_0x5f31ca(0x10e)](_0xfee484[_0x5f31ca(0x135)]()),_0x2a1c6b=this[_0x5f31ca(0x10e)](_0xfee484['getMinutes']()),_0x24d0b6=this[_0x5f31ca(0x10e)](_0xfee484['getSeconds']());return{'createdAt':_0x3dd006+'-'+_0x93c2db+'-'+_0x13c859+'\x20'+_0x99d689+':'+_0x2a1c6b+':'+_0x24d0b6,'createdDate':_0x3dd006+'-'+_0x93c2db+'-'+_0x13c859,'createdTime':_0x99d689+':'+_0x2a1c6b+':'+_0x24d0b6};}static[a238_0x41187f(0x129)](_0xf678a9){const _0x44f46d=a238_0x41187f,_0x2de5ac=_0xf678a9[_0x44f46d(0x139)]('/')[_0x44f46d(0x149)]()||_0xf678a9;return _0x2de5ac[_0x44f46d(0x139)]('-')[_0x44f46d(0x146)](_0x588776=>_0x588776[_0x44f46d(0x12c)](0x0)['toUpperCase']()+_0x588776[_0x44f46d(0x118)](0x1)[_0x44f46d(0x11f)]())[_0x44f46d(0x112)]('');}static[a238_0x41187f(0x137)](_0x41e8fe){const _0x2d916e=a238_0x41187f,_0xc7ae20=_0x41e8fe['split']('/')['pop']()||_0x41e8fe;return _0xc7ae20[_0x2d916e(0x139)]('-')[_0x2d916e(0x146)](_0x320ada=>_0x320ada[_0x2d916e(0x12c)](0x0)[_0x2d916e(0x131)]()+_0x320ada[_0x2d916e(0x118)](0x1)['toLowerCase']())[_0x2d916e(0x112)]('\x20');}static['replaceContent'](_0x4808ed,_0x1f7cf6,_0x21b8cd){const _0x3a05c8=a238_0x41187f,_0x2cb975=this['toComponentName'](_0x1f7cf6),_0x409b8d=this[_0x3a05c8(0x137)](_0x1f7cf6),{createdAt:_0x23df0e,createdDate:_0x451fad,createdTime:_0x1f076b}=this[_0x3a05c8(0x134)](new Date());let _0x382bce=_0x4808ed[_0x3a05c8(0x105)](/\{CliVersion\}/g,CLI_VERSION)[_0x3a05c8(0x105)](/\{ComponentName\}/g,_0x2cb975)[_0x3a05c8(0x105)](/\{DisplayTitle\}/g,_0x409b8d)[_0x3a05c8(0x105)](/\{PageName\}/g,_0x1f7cf6)['replace'](/\{TemplateName\}/g,_0x21b8cd)['replace'](/\{CreatedAt\}/g,_0x23df0e)[_0x3a05c8(0x105)](/\{CreatedDate\}/g,_0x451fad)['replace'](/\{CreatedTime\}/g,_0x1f076b);return _0x382bce;}static[a238_0x41187f(0x110)](_0x571e93,_0x22afa6,_0x24d981,_0x32d5ef,_0x8bb2d,_0xe5164,_0x189a9f,_0x423aa7){const _0x55a075=a238_0x41187f,_0x59c54a=new Date(),_0x5c2333=_0x59c54a[_0x55a075(0x142)](),_0x2b1da0=_0x24d981[_0x55a075(0x146)](_0x1daa11=>{const _0x5cb66a=_0x55a075,_0x8de434=[_0x5cb66a(0x117)+_0x1daa11[_0x5cb66a(0x128)]+'\x22',_0x5cb66a(0x148)+_0x1daa11[_0x5cb66a(0x138)]+'\x22',_0x5cb66a(0x127)+_0x1daa11[_0x5cb66a(0x123)]+'\x22'];return _0x1daa11[_0x5cb66a(0x11a)]&&_0x8de434[_0x5cb66a(0x136)](_0x5cb66a(0x12e)+_0x1daa11[_0x5cb66a(0x11a)]+'\x22'),_0x5cb66a(0x11e)+_0x8de434[_0x5cb66a(0x112)](',\x20')+_0x5cb66a(0x11d);})[_0x55a075(0x112)](''),_0x5d9d3e=_0x32d5ef||_0x24d981[0x0]?.[_0x55a075(0x11a)]||'YourModel';let _0x40ee77=_0x571e93[_0x55a075(0x105)](/\{AppCode\}/g,_0x22afa6)[_0x55a075(0x105)](/\{ModelConfigs\}/g,_0x2b1da0)[_0x55a075(0x105)](/\{ExampleModelName\}/g,_0x5d9d3e)[_0x55a075(0x105)](/\{ApiFileName\}/g,_0x8bb2d||'api')[_0x55a075(0x105)](/\{ConfigName\}/g,_0xe5164||_0x55a075(0x10a))['replace'](/\{ClientConfigParam\}/g,_0x189a9f||'')[_0x55a075(0x105)](/\{VarPrefix\}/g,_0x423aa7||_0x55a075(0x104))[_0x55a075(0x105)](/\{CreatedAt\}/g,_0x5c2333);return _0x40ee77;}static async[a238_0x41187f(0x114)](_0x5ca174,_0x3d1554,_0x38c27c,_0xcbcd05,_0x1ba5fb=!![]){const _0x55d54c=a238_0x41187f,_0x48884a=Date[_0x55d54c(0x119)]();try{_0x1ba5fb&&logger[_0x55d54c(0x116)](_0x55d54c(0x109),'开始处理模板内容替换',{'templatePath':_0x5ca174,'targetPath':_0x3d1554,'pageName':_0x38c27c,'templateName':_0xcbcd05});await a238_0x34807b['promises'][_0x55d54c(0x130)](_0x3d1554,{'recursive':!![]}),await this['processDirectory'](_0x5ca174,_0x3d1554,_0x38c27c,_0xcbcd05);if(_0x1ba5fb){const _0x1e1227=Date[_0x55d54c(0x119)]()-_0x48884a;logger[_0x55d54c(0x10b)](_0x55d54c(0x109),_0x55d54c(0x13a),_0x1e1227,{'pageName':_0x38c27c,'templateName':_0xcbcd05});}}catch(_0x2c5eb6){if(_0x1ba5fb){const _0x27e238=Date['now']()-_0x48884a;logger[_0x55d54c(0x13c)](_0x55d54c(0x109),_0x55d54c(0x10c),{'templatePath':_0x5ca174,'targetPath':_0x3d1554,'pageName':_0x38c27c,'templateName':_0xcbcd05,'error':_0x2c5eb6 instanceof Error?_0x2c5eb6[_0x55d54c(0x141)]:String(_0x2c5eb6),'duration':_0x27e238});}throw _0x2c5eb6;}}static async[a238_0x41187f(0x124)](_0x46956a,_0x15adcd,_0x1ea6ed,_0x39bfc7){const _0x43b7c7=a238_0x41187f,_0x59e832=await a238_0x34807b[_0x43b7c7(0x111)][_0x43b7c7(0x12d)](_0x46956a,{'withFileTypes':!![]});for(const _0x11cc0a of _0x59e832){const _0x415f9b=a238_0x2e6a20[_0x43b7c7(0x112)](_0x46956a,_0x11cc0a[_0x43b7c7(0x123)]);let _0x180253=a238_0x2e6a20[_0x43b7c7(0x112)](_0x15adcd,_0x11cc0a[_0x43b7c7(0x123)]);_0x11cc0a['name'][_0x43b7c7(0x12b)](_0x43b7c7(0x12f))&&(_0x180253=a238_0x2e6a20[_0x43b7c7(0x112)](_0x15adcd,_0x11cc0a['name']['replace'](/\.tpl$/,'')));if(_0x11cc0a['isDirectory']())await a238_0x34807b['promises'][_0x43b7c7(0x130)](_0x180253,{'recursive':!![]}),await this[_0x43b7c7(0x124)](_0x415f9b,_0x180253,_0x1ea6ed,_0x39bfc7);else _0x11cc0a[_0x43b7c7(0x106)]()&&await this[_0x43b7c7(0x140)](_0x415f9b,_0x180253,_0x1ea6ed,_0x39bfc7);}}static async['processFile'](_0x3a5c0f,_0x5e6285,_0x1e581f,_0x10df72){const _0x3433c9=a238_0x41187f,_0x497861=a238_0x2e6a20[_0x3433c9(0x13b)](_0x3a5c0f)[_0x3433c9(0x11f)]();_0x3a5c0f[_0x3433c9(0x12b)](_0x3433c9(0x12f))&&(_0x5e6285=_0x5e6285['replace'](/\.tpl$/,''));const _0xcb051e=[_0x3433c9(0x145),_0x3433c9(0x11c),_0x3433c9(0x10f),_0x3433c9(0x115),_0x3433c9(0x144),_0x3433c9(0x132),_0x3433c9(0x11b),'.scss',_0x3433c9(0x12f)];if(_0xcb051e['includes'](_0x497861)||_0x3a5c0f['endsWith'](_0x3433c9(0x12f))){const _0x2e655e=await a238_0x34807b['promises']['readFile'](_0x3a5c0f,'utf8'),_0x64a655=this[_0x3433c9(0x122)](_0x2e655e,_0x1e581f,_0x10df72);await a238_0x34807b[_0x3433c9(0x111)][_0x3433c9(0x13e)](_0x5e6285,_0x64a655,_0x3433c9(0x121));}else await a238_0x34807b[_0x3433c9(0x111)]['copyFile'](_0x3a5c0f,_0x5e6285);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3017cc,_0x409942){const _0x204223=a239_0x52fd,_0x39e283=_0x3017cc();while(!![]){try{const _0x312ad7=parseInt(_0x204223(0x193))/0x1*(parseInt(_0x204223(0x188))/0x2)+parseInt(_0x204223(0x18c))/0x3+-parseInt(_0x204223(0x19f))/0x4*(-parseInt(_0x204223(0x197))/0x5)+-parseInt(_0x204223(0x18f))/0x6+parseInt(_0x204223(0x18e))/0x7*(-parseInt(_0x204223(0x185))/0x8)+-parseInt(_0x204223(0x19a))/0x9+-parseInt(_0x204223(0x18b))/0xa*(parseInt(_0x204223(0x196))/0xb);if(_0x312ad7===_0x409942)break;else _0x39e283['push'](_0x39e283['shift']());}catch(_0x42030d){_0x39e283['push'](_0x39e283['shift']());}}}(a239_0x39c8,0x764dd));import{mkdir,readFile,writeFile}from'node:fs/promises';import{homedir}from'node:os';import{dirname,join}from'node:path';import a239_0x3a3469 from'semver';import{CLI_BIN_NAME,NPM_PACKAGE_NAME}from'../constant/cli.js';import{getCliVersionPolicy}from'../utils/cli-version-policy.js';import{getCliVersion}from'../utils/version.js';const UPDATE_CHECK_TTL_MS=0xc*0x3c*0x3c*0x3e8,UPDATE_NOTICE_TTL_MS=0x18*0x3c*0x3c*0x3e8;function isUpdateNoticeDisabled(){const _0x1b1a3d=a239_0x52fd,_0x3b72bd=process.env.RABETBASE_NO_UPDATE_NOTICE?.[_0x1b1a3d(0x195)]()[_0x1b1a3d(0x198)]();return _0x3b72bd==='1'||_0x3b72bd===_0x1b1a3d(0x18a)||_0x3b72bd===_0x1b1a3d(0x1a5);}function cacheRoot(){const _0xb8ebee=a239_0x52fd;return process.env.XDG_CACHE_HOME||process.env.LOCALAPPDATA||join(homedir(),_0xb8ebee(0x19c));}export function getUpdateNoticeCachePath(){const _0x43c540=a239_0x52fd;return join(cacheRoot(),_0x43c540(0x19d),_0x43c540(0x186));}async function readUpdateNoticeCache(){const _0x170068=a239_0x52fd;try{const _0x5e535d=await readFile(getUpdateNoticeCachePath(),'utf8'),_0x245132=JSON[_0x170068(0x1a2)](_0x5e535d);if(!_0x245132||typeof _0x245132!==_0x170068(0x19b))return{};return _0x245132;}catch{return{};}}async function writeUpdateNoticeCache(_0x48c733){const _0x5db824=a239_0x52fd;try{const _0x5a1b4c=getUpdateNoticeCachePath();await mkdir(dirname(_0x5a1b4c),{'recursive':!![]}),await writeFile(_0x5a1b4c,JSON['stringify'](_0x48c733,null,0x2)+'\x0a',_0x5db824(0x1a3));}catch{}}function a239_0x39c8(){const _0x34330a=['255dAaeav','toLowerCase','valid','390177ItmWuD','object','.cache','rabetbase-cli','stableVersion','15020rECzFe','gte','checkedAt','parse','utf8','\x20update','yes','\x20available,\x20current\x20','85856EIIVzu','update-check.json','lastNotifiedAt','936kKQMen','https://www.npmjs.com/package/','true','40BwVDTL','1627698mwGbfR',',\x20run:\x20','287dnamJA','2578158znaFEk','now','number','/v/','1801smHDDV','lastNotifiedVersion','trim','493097NbdpDS'];a239_0x39c8=function(){return _0x34330a;};return a239_0x39c8();}function isFreshCheck(_0x2faad2,_0x85872b){const _0x624ffb=a239_0x52fd;return typeof _0x2faad2[_0x624ffb(0x1a1)]===_0x624ffb(0x191)&&_0x85872b-_0x2faad2[_0x624ffb(0x1a1)]<UPDATE_CHECK_TTL_MS;}function a239_0x52fd(_0x3dbe94,_0x15a40a){_0x3dbe94=_0x3dbe94-0x185;const _0x39c891=a239_0x39c8();let _0x52fd70=_0x39c891[_0x3dbe94];return _0x52fd70;}function isRecentlyNotified(_0x1a8f86,_0x32291b,_0x43126c){const _0x55055b=a239_0x52fd;return _0x1a8f86[_0x55055b(0x194)]===_0x32291b&&typeof _0x1a8f86[_0x55055b(0x187)]===_0x55055b(0x191)&&_0x43126c-_0x1a8f86[_0x55055b(0x187)]<UPDATE_NOTICE_TTL_MS;}export function buildNpmVersionUrl(_0x31903d){const _0xc99a=a239_0x52fd;return _0xc99a(0x189)+NPM_PACKAGE_NAME+_0xc99a(0x192)+_0x31903d;}export async function resolveLatestUpdateNotice(){const _0xdab9ce=a239_0x52fd;if(isUpdateNoticeDisabled())return null;try{const _0x5cc337=Date[_0xdab9ce(0x190)](),_0x56a1eb=getCliVersion(),_0xc97e43=await readUpdateNoticeCache();let _0xd73b78=isFreshCheck(_0xc97e43,_0x5cc337)?_0xc97e43['latest']?.[_0xdab9ce(0x195)]():undefined;if(!_0xd73b78&&!isFreshCheck(_0xc97e43,_0x5cc337)){const _0x5c590d=await getCliVersionPolicy();_0xd73b78=_0x5c590d?.[_0xdab9ce(0x19e)]?.[_0xdab9ce(0x195)]()||undefined,await writeUpdateNoticeCache({..._0xc97e43,'checkedAt':_0x5cc337,'latest':_0xd73b78,'failed':!_0xd73b78});}if(!_0xd73b78||!a239_0x3a3469[_0xdab9ce(0x199)](_0x56a1eb)||!a239_0x3a3469[_0xdab9ce(0x199)](_0xd73b78))return null;if(a239_0x3a3469[_0xdab9ce(0x1a0)](_0x56a1eb,_0xd73b78))return null;if(isRecentlyNotified(_0xc97e43,_0xd73b78,_0x5cc337))return null;const _0x48c8ed=CLI_BIN_NAME+_0xdab9ce(0x1a4);return await writeUpdateNoticeCache({..._0xc97e43,'checkedAt':isFreshCheck(_0xc97e43,_0x5cc337)?_0xc97e43[_0xdab9ce(0x1a1)]:_0x5cc337,'latest':_0xd73b78,'failed':![],'lastNotifiedVersion':_0xd73b78,'lastNotifiedAt':_0x5cc337}),{'command':_0x48c8ed,'current':_0x56a1eb,'latest':_0xd73b78,'url':buildNpmVersionUrl(_0xd73b78),'message':CLI_BIN_NAME+'\x20'+_0xd73b78+_0xdab9ce(0x1a6)+_0x56a1eb+_0xdab9ce(0x18d)+_0x48c8ed};}catch{return null;}}
|
package/lib/utils/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x49889a,_0x5ee2fa){var _0x4dcc50=a240_0x294b,_0x1d6214=_0x49889a();while(!![]){try{var _0x589b31=parseInt(_0x4dcc50(0x1c7))/0x1*(parseInt(_0x4dcc50(0x1c4))/0x2)+parseInt(_0x4dcc50(0x1c3))/0x3*(-parseInt(_0x4dcc50(0x1cd))/0x4)+parseInt(_0x4dcc50(0x1c9))/0x5*(parseInt(_0x4dcc50(0x1c8))/0x6)+-parseInt(_0x4dcc50(0x1c5))/0x7+parseInt(_0x4dcc50(0x1c6))/0x8*(parseInt(_0x4dcc50(0x1cc))/0x9)+parseInt(_0x4dcc50(0x1c2))/0xa*(-parseInt(_0x4dcc50(0x1ca))/0xb)+-parseInt(_0x4dcc50(0x1cb))/0xc;if(_0x589b31===_0x5ee2fa)break;else _0x1d6214['push'](_0x1d6214['shift']());}catch(_0x2d254b){_0x1d6214['push'](_0x1d6214['shift']());}}}(a240_0x17f8,0x5f6d6));import{VERSION}from'../generated/build-info.js';function a240_0x17f8(){var _0x5d081a=['150741qNvSZe','16bpVLQG','321160tEBypf','61323tHptPR','2IVyXwf','4488253MnBRDK','56xBZsql','726889oomIeC','30qlWwJb','659105xZaNxL','66zUlufa','2360736KOSlUN'];a240_0x17f8=function(){return _0x5d081a;};return a240_0x17f8();}function a240_0x294b(_0x1503ec,_0x4268ae){_0x1503ec=_0x1503ec-0x1c2;var _0x17f8b3=a240_0x17f8();var _0x294bd3=_0x17f8b3[_0x1503ec];return _0x294bd3;}export function getCliVersion(){return VERSION;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a241_0x438f(_0x2d8c54,_0x5602d8){_0x2d8c54=_0x2d8c54-0x10e;var _0x11f291=a241_0x11f2();var _0x438fa6=_0x11f291[_0x2d8c54];return _0x438fa6;}function a241_0x11f2(){var _0x4e445c=['178353vQFIqy','80yQWrfz','627273bbemQu','72kSkfJB','330434tsNKXp','11903199eluGTn','154884XDCwJP','4tduFwX','12dYEFFy','201069gYcToY','596380DpkWAZ'];a241_0x11f2=function(){return _0x4e445c;};return a241_0x11f2();}(function(_0x53115d,_0x2dc6a4){var _0x1243a5=a241_0x438f,_0x3d8a2c=_0x53115d();while(!![]){try{var _0x5c44ef=parseInt(_0x1243a5(0x117))/0x1+parseInt(_0x1243a5(0x10e))/0x2+parseInt(_0x1243a5(0x115))/0x3*(parseInt(_0x1243a5(0x10f))/0x4)+-parseInt(_0x1243a5(0x112))/0x5*(-parseInt(_0x1243a5(0x110))/0x6)+-parseInt(_0x1243a5(0x113))/0x7*(-parseInt(_0x1243a5(0x116))/0x8)+-parseInt(_0x1243a5(0x111))/0x9*(-parseInt(_0x1243a5(0x114))/0xa)+-parseInt(_0x1243a5(0x118))/0xb;if(_0x5c44ef===_0x2dc6a4)break;else _0x3d8a2c['push'](_0x3d8a2c['shift']());}catch(_0x5637d1){_0x3d8a2c['push'](_0x3d8a2c['shift']());}}}(a241_0x11f2,0x2c4c9));import{setActiveCookie,clearActiveCookie}from'../core/api-client.js';export async function withActiveCookie(_0x3a65f2,_0x3d8b83){setActiveCookie(_0x3a65f2);try{return await _0x3d8b83();}finally{clearActiveCookie();}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a242_0x464c(_0x2822e2,_0x24e410){_0x2822e2=_0x2822e2-0xf7;var _0x5e7942=a242_0x5e79();var _0x464c86=_0x5e7942[_0x2822e2];return _0x464c86;}function a242_0x5e79(){var _0x3bbbe1=['524WGhkiK','1355XaFvIc','1JmzHyp','433539LsacDH','2274nAzpXH','write','3018baTRVU','2452760zhHqvH','161304QHeibZ','48EMSavI','32972XoCOCG','1551942ZZdbKz'];a242_0x5e79=function(){return _0x3bbbe1;};return a242_0x5e79();}(function(_0x2d148e,_0x282c1c){var _0x502b41=a242_0x464c,_0x223327=_0x2d148e();while(!![]){try{var _0x79d1ea=parseInt(_0x502b41(0x101))/0x1*(-parseInt(_0x502b41(0xfd))/0x2)+parseInt(_0x502b41(0xf9))/0x3*(-parseInt(_0x502b41(0xff))/0x4)+parseInt(_0x502b41(0x100))/0x5*(parseInt(_0x502b41(0xf7))/0x6)+parseInt(_0x502b41(0xfe))/0x7+parseInt(_0x502b41(0xfc))/0x8*(-parseInt(_0x502b41(0x102))/0x9)+parseInt(_0x502b41(0xfa))/0xa+parseInt(_0x502b41(0xfb))/0xb;if(_0x79d1ea===_0x282c1c)break;else _0x223327['push'](_0x223327['shift']());}catch(_0x376d3c){_0x223327['push'](_0x223327['shift']());}}}(a242_0x5e79,0x23e71));export function writeCliSideChannelLine(_0x71ad65){var _0x50ce04=a242_0x464c;process['stderr'][_0x50ce04(0xf8)](_0x71ad65+'\x0a');}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lovrabet/rabetbase-cli",
|
|
3
|
-
"version": "2.3.4-beta.
|
|
3
|
+
"version": "2.3.4-beta.4",
|
|
4
4
|
"description": "Developer CLI for Lovrabet apps, datasets, pages, SQL, BFF, database connections, skills, and AI agent workflows.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE",
|
|
6
6
|
"keywords": [
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"test:ui": "vitest --ui",
|
|
48
48
|
"test:watch": "vitest --watch",
|
|
49
49
|
"test:unit": "vitest run test/unit",
|
|
50
|
-
"test:app": "vitest run test/unit/commands/app-shared.test.ts test/unit/commands/app-add.test.ts test/unit/commands/app-remove.test.ts test/unit/commands/app-list.test.ts test/unit/commands/app-
|
|
50
|
+
"test:app": "vitest run test/unit/commands/app-shared.test.ts test/unit/commands/app-add.test.ts test/unit/commands/app-remove.test.ts test/unit/commands/app-list.test.ts test/unit/commands/workspace.test.ts test/unit/commands/app-workspace-migration.test.ts",
|
|
51
51
|
"test:integration": "vitest run test/integration",
|
|
52
52
|
"test:e2e": "vitest run test/e2e",
|
|
53
53
|
"test:e2e:daily": "RABETBASE_E2E_DAILY=1 vitest run test/e2e/daily-app-smoke.test.ts",
|