@lovrabet/rabetbase-cli 2.1.7-beta.2 → 2.1.7-beta.3
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/discover.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/remove.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app/use.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-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-selector.js +1 -1
- 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/delete.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/link-create.js +1 -1
- package/lib/commands/dataset/link-delete.js +1 -1
- package/lib/commands/dataset/link-shared.js +1 -1
- package/lib/commands/dataset/link-update.js +1 -1
- package/lib/commands/dataset/links.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.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/report.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/index.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/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/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/run/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/skill/index.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/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.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/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
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x276074,_0x154a98){const _0x3a441a=a182_0x114e,_0x56491c=_0x276074();while(!![]){try{const _0x98ef1f=parseInt(_0x3a441a(0x1a9))/0x1*(-parseInt(_0x3a441a(0x1d1))/0x2)+parseInt(_0x3a441a(0x1c0))/0x3+-parseInt(_0x3a441a(0x1af))/0x4*(-parseInt(_0x3a441a(0x1bd))/0x5)+parseInt(_0x3a441a(0x1c9))/0x6*(-parseInt(_0x3a441a(0x1c2))/0x7)+-parseInt(_0x3a441a(0x1c1))/0x8*(parseInt(_0x3a441a(0x1c4))/0x9)+parseInt(_0x3a441a(0x1b4))/0xa+parseInt(_0x3a441a(0x1b0))/0xb;if(_0x98ef1f===_0x154a98)break;else _0x56491c['push'](_0x56491c['shift']());}catch(_0x276803){_0x56491c['push'](_0x56491c['shift']());}}}(a182_0x286d,0xd12be));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a182_0x4e604a from'semver';import{getCliVersionPolicy}from'../utils/cli-version-policy.js';function a182_0x286d(){const _0x3542e7=['minimumVersionMessage','\x1b[31m','4qeINja','parse','\x20\x20\x20','636806WCDlEj','1.0.0','Minimum\x20required:\x20','\x20\x20\x20Current\x20CLI\x20version:\x20','\x1b[0m','\x20\x20\x20Minimum\x20required:\x20','16mmqByE','9966605CBeyhP','log','join','stableVersion','13414760nlHQhj','\x20\x20\x20Upgrade\x20command:\x20','\x1b[33m','upgradeMessage','↪\x20Critical\x20CLI\x20upgrade\x20required','npm\x20install\x20-g\x20','belowMinimum','\x20\x20\x20Recommended\x20stable:\x20','↪\x20New\x20version\x20available','340980oEDCFq','package.json','minimumVersion','3901644AfwUIM','835912oqGzUT','6713434oZMFmX','coerce','63HjyJyM','Upgrade\x20command:\x20','currentVersion','Current\x20version:\x20','../..','6trVykR','\x1b[1m','filter','\x20\x20\x20Stable\x20version:\x20','needsUpgrade','Current\x20CLI\x20version\x20is\x20below\x20the\x20minimum\x20supported\x20version.'];a182_0x286d=function(){return _0x3542e7;};return a182_0x286d();}import{NPM_PACKAGE_NAME}from'../constant/cli.js';import{CliErrors}from'../errors.js';export function getCliUpgradeCommand(_0x1d5ad4){const _0x4516ad=a182_0x114e,_0x5abada=_0x1d5ad4['stableVersion']||'latest';return _0x4516ad(0x1b9)+NPM_PACKAGE_NAME+'@'+_0x5abada;}function getCurrentCliVersion(){const _0x2f9651=a182_0x114e;try{const _0x4542f5=fileURLToPath(import.meta.url),_0x1252ce=resolve(dirname(_0x4542f5),_0x2f9651(0x1c8)),_0x19d086=resolve(_0x1252ce,_0x2f9651(0x1be)),_0x3e2a87=JSON[_0x2f9651(0x1a7)](readFileSync(_0x19d086,'utf-8'));return _0x3e2a87['version']||_0x2f9651(0x1aa);}catch{return _0x2f9651(0x1aa);}}function a182_0x114e(_0x1fba2a,_0x103f91){_0x1fba2a=_0x1fba2a-0x1a7;const _0x286d17=a182_0x286d();let _0x114e59=_0x286d17[_0x1fba2a];return _0x114e59;}export async function checkCliVersion(){const _0x1a7a84=a182_0x114e,_0x5a6c7b=getCurrentCliVersion(),_0x1e0033=await getCliVersionPolicy(),_0x471791=_0x1e0033?.[_0x1a7a84(0x1b3)]||null,_0x25e967=_0x1e0033?.['minimumVersion']||null;let _0x5c68b9=![],_0x52ddb7=![];const _0xb825c6=a182_0x4e604a[_0x1a7a84(0x1c3)](_0x5a6c7b);if(_0xb825c6&&_0x471791)try{const _0x110186=a182_0x4e604a['coerce'](_0x471791);if(_0x110186)_0x5c68b9=a182_0x4e604a['lt'](_0xb825c6,_0x110186);}catch{}if(_0xb825c6&&_0x25e967)try{const _0x3cf0dd=a182_0x4e604a[_0x1a7a84(0x1c3)](_0x25e967);if(_0x3cf0dd)_0x52ddb7=a182_0x4e604a['lt'](_0xb825c6,_0x3cf0dd);}catch{}return _0x52ddb7&&(_0x5c68b9=!![]),{'currentVersion':_0x5a6c7b,'stableVersion':_0x471791,'minimumVersion':_0x25e967,'needsUpgrade':_0x5c68b9,'belowMinimum':_0x52ddb7,'isPreRelease':![],'upgradeMessage':_0x1e0033?.[_0x1a7a84(0x1b7)],'minimumVersionMessage':_0x1e0033?.[_0x1a7a84(0x1cf)]};}export function printCliUpgradeWarning(_0x3c9c26){const _0x4d4fd2=a182_0x114e;if(!_0x3c9c26[_0x4d4fd2(0x1cd)]&&!_0x3c9c26['belowMinimum'])return;const _0x105624=_0x4d4fd2(0x1d0),_0x18951c=_0x4d4fd2(0x1b6),_0x22c398=_0x4d4fd2(0x1ad),_0x5de5e0=_0x4d4fd2(0x1ca),_0x4066d0=getCliUpgradeCommand(_0x3c9c26);console[_0x4d4fd2(0x1b1)](),_0x3c9c26[_0x4d4fd2(0x1ba)]?(console[_0x4d4fd2(0x1b1)](''+_0x105624+_0x5de5e0+_0x4d4fd2(0x1b8)+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x105624+_0x4d4fd2(0x1ac)+_0x3c9c26[_0x4d4fd2(0x1c6)]+_0x22c398),_0x3c9c26[_0x4d4fd2(0x1bf)]&&console[_0x4d4fd2(0x1b1)](_0x105624+_0x4d4fd2(0x1ae)+_0x3c9c26['minimumVersion']+_0x22c398),_0x3c9c26[_0x4d4fd2(0x1b3)]&&_0x3c9c26[_0x4d4fd2(0x1b3)]!==_0x3c9c26[_0x4d4fd2(0x1bf)]&&console[_0x4d4fd2(0x1b1)](_0x105624+_0x4d4fd2(0x1bb)+_0x3c9c26[_0x4d4fd2(0x1b3)]+_0x22c398),_0x3c9c26[_0x4d4fd2(0x1cf)]&&console['log'](_0x105624+_0x4d4fd2(0x1a8)+_0x3c9c26[_0x4d4fd2(0x1cf)]+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x105624+_0x4d4fd2(0x1b5)+_0x4066d0+_0x22c398)):(console['log'](''+_0x18951c+_0x5de5e0+_0x4d4fd2(0x1bc)+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x18951c+_0x4d4fd2(0x1ac)+_0x3c9c26[_0x4d4fd2(0x1c6)]+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x18951c+_0x4d4fd2(0x1cc)+_0x3c9c26['stableVersion']+_0x22c398),_0x3c9c26[_0x4d4fd2(0x1b7)]&&console['log'](_0x18951c+_0x4d4fd2(0x1a8)+_0x3c9c26[_0x4d4fd2(0x1b7)]+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x18951c+_0x4d4fd2(0x1b5)+_0x4066d0+_0x22c398)),console[_0x4d4fd2(0x1b1)]();}export function assertCliVersionSupported(_0x55d4fa){const _0x4d6641=a182_0x114e;if(!_0x55d4fa[_0x4d6641(0x1ba)])return;const _0x1d4c13=[_0x55d4fa[_0x4d6641(0x1cf)],_0x4d6641(0x1c7)+_0x55d4fa[_0x4d6641(0x1c6)],_0x55d4fa[_0x4d6641(0x1bf)]?_0x4d6641(0x1ab)+_0x55d4fa[_0x4d6641(0x1bf)]:null,_0x4d6641(0x1c5)+getCliUpgradeCommand(_0x55d4fa)][_0x4d6641(0x1cb)](Boolean)[_0x4d6641(0x1b2)]('\x0a');throw CliErrors['validation'](_0x4d6641(0x1ce),_0x1d4c13);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x483688,_0x278565){const _0x5a02e0=a183_0x461a,_0xd4460e=_0x483688();while(!![]){try{const _0xfd256a=-parseInt(_0x5a02e0(0xb7))/0x1+-parseInt(_0x5a02e0(0xcb))/0x2+-parseInt(_0x5a02e0(0xbc))/0x3+parseInt(_0x5a02e0(0xc2))/0x4*(-parseInt(_0x5a02e0(0xc7))/0x5)+parseInt(_0x5a02e0(0xc3))/0x6+parseInt(_0x5a02e0(0xc8))/0x7+-parseInt(_0x5a02e0(0xc1))/0x8*(-parseInt(_0x5a02e0(0xcc))/0x9);if(_0xfd256a===_0x278565)break;else _0xd4460e['push'](_0xd4460e['shift']());}catch(_0x431113){_0xd4460e['push'](_0xd4460e['shift']());}}}(a183_0x57a9,0x90e0b));import{CLI_VERSION_POLICY_URL}from'../constant/cdn.js';const CACHE_TTL=0x5*0x3c*0x3e8,FAILURE_CACHE_TTL=0x3c*0x3e8,FETCH_TIMEOUT_MS=0xbb8;function pickString(_0x3ed030){const _0x39e32b=a183_0x461a;return typeof _0x3ed030===_0x39e32b(0xbd)&&_0x3ed030[_0x39e32b(0xb6)]()[_0x39e32b(0xb4)]>0x0?_0x3ed030['trim']():null;}function normalizeCliVersionPolicy(_0x574ebe){const _0x2331c3=a183_0x461a;if(!_0x574ebe||typeof _0x574ebe!==_0x2331c3(0xc6))return null;const _0x3f6354=_0x574ebe,_0x2b4560=_0x3f6354[_0x2331c3(0xba)]&&typeof _0x3f6354['cli']===_0x2331c3(0xc6)?_0x3f6354[_0x2331c3(0xba)]:_0x3f6354,_0x51247e=pickString(_0x2b4560[_0x2331c3(0xc9)])||pickString(_0x2b4560[_0x2331c3(0xbf)])||pickString(_0x2b4560[_0x2331c3(0xb9)]),_0x371bcc=pickString(_0x2b4560[_0x2331c3(0xc0)])||pickString(_0x2b4560[_0x2331c3(0xb8)]);if(!_0x51247e&&!_0x371bcc)return null;return{'stableVersion':_0x51247e,'minimumVersion':_0x371bcc,'upgradeMessage':pickString(_0x2b4560[_0x2331c3(0xc5)])||undefined,'minimumVersionMessage':pickString(_0x2b4560[_0x2331c3(0xc4)])||undefined};}export async function fetchCliVersionPolicy(){const _0x784f62=a183_0x461a,_0x4f20d7=new AbortController(),_0x57e110=setTimeout(()=>_0x4f20d7[_0x784f62(0xb5)](),FETCH_TIMEOUT_MS);try{const _0x4103cd=await fetch(CLI_VERSION_POLICY_URL,{'headers':{'Accept':_0x784f62(0xca)},'signal':_0x4f20d7[_0x784f62(0xbb)]});if(!_0x4103cd['ok'])return null;const _0x3ff79f=await _0x4103cd['json']();return normalizeCliVersionPolicy(_0x3ff79f);}catch{return null;}finally{clearTimeout(_0x57e110);}}function a183_0x57a9(){const _0xed119f=['now','latestVersion','minimumVersion','11736944gAbGFL','4006808HWnMOQ','1396236xnJglx','minimumVersionMessage','upgradeMessage','object','5OkVKzn','2678109BVkZwR','stableVersion','application/json','765376OZpDau','18jDpgFS','length','abort','trim','676260gWicco','minVersion','recommendedVersion','cli','signal','2686380MjNbGn','string'];a183_0x57a9=function(){return _0xed119f;};return a183_0x57a9();}function a183_0x461a(_0x4222c4,_0x5f5bb5){_0x4222c4=_0x4222c4-0xb4;const _0x57a9d2=a183_0x57a9();let _0x461a84=_0x57a9d2[_0x4222c4];return _0x461a84;}let cachedPolicy=null,cacheTime=0x0,hasCachedPolicy=![];export async function getCliVersionPolicy(){const _0xec87db=a183_0x461a,_0x1cbcb7=Date[_0xec87db(0xbe)]();if(hasCachedPolicy){const _0x49fe0b=cachedPolicy?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x1cbcb7-cacheTime<_0x49fe0b)return cachedPolicy;}const _0x4f232b=await fetchCliVersionPolicy();return cachedPolicy=_0x4f232b,cacheTime=_0x1cbcb7,hasCachedPolicy=!![],_0x4f232b;}export function clearCliVersionPolicyCache(){cachedPolicy=null,cacheTime=0x0,hasCachedPolicy=![];}
|
package/lib/utils/config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a184_0x3057d6=a184_0x4b24;(function(_0x4547b4,_0x3b4c70){const _0x2eed18=a184_0x4b24,_0x61e4a4=_0x4547b4();while(!![]){try{const _0xa105b=parseInt(_0x2eed18(0x1c1))/0x1*(parseInt(_0x2eed18(0x1ba))/0x2)+parseInt(_0x2eed18(0x1b7))/0x3*(parseInt(_0x2eed18(0x1c2))/0x4)+parseInt(_0x2eed18(0x1bb))/0x5+parseInt(_0x2eed18(0x1bf))/0x6+-parseInt(_0x2eed18(0x1b8))/0x7*(parseInt(_0x2eed18(0x1bd))/0x8)+parseInt(_0x2eed18(0x1b6))/0x9+-parseInt(_0x2eed18(0x1b9))/0xa;if(_0xa105b===_0x3b4c70)break;else _0x61e4a4['push'](_0x61e4a4['shift']());}catch(_0x113854){_0x61e4a4['push'](_0x61e4a4['shift']());}}}(a184_0x26af,0x92efb));import{initEnv}from'../constant/env.js';function a184_0x4b24(_0x5140ee,_0x3c3017){_0x5140ee=_0x5140ee-0x1b6;const _0x26afba=a184_0x26af();let _0x4b241b=_0x26afba[_0x5140ee];return _0x4b241b;}import{readRawConfig,getConfigAppCode as a184_0x2187a8,getMultiAppConfigs as a184_0x4d56d8,getTemplateBaseUrl as a184_0x997425}from'../context.js';export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';export{isInProject}from'../context.js';function a184_0x26af(){const _0x4fb73d=['7VLtzJY','28655400jKYibu','1812310FQUfiI','3292160WouCdL','string','481976Oqrsib','project','2124852rhZDXJ','env','1Imhbvp','1432gmOjjb','10359243bXOaVi','3837GamxNB'];a184_0x26af=function(){return _0x4fb73d;};return a184_0x26af();}export function readConfig(_0x5f4ff4){const _0x239304=a184_0x4b24,_0x1d9edc=readRawConfig(_0x5f4ff4);return _0x1d9edc[_0x239304(0x1c0)]&&typeof _0x1d9edc[_0x239304(0x1c0)]===_0x239304(0x1bc)&&initEnv(_0x1d9edc[_0x239304(0x1c0)]),_0x1d9edc;}export function getConfigAppCode(){return a184_0x2187a8();}export function getMultiAppConfigs(_0x5d7865=a184_0x3057d6(0x1be)){return a184_0x4d56d8(_0x5d7865);}export function getTemplateBaseUrl(){return a184_0x997425();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a185_0x9965(){const _0x571767=['20UNaIXm','20030810ItjceJ','446201FrTgpM','10274496KTuWfc','491356QGvyWj','isDirectory','1034208LekBLh','9tzSynZ','name','384242DNmbyq','复制目录时出错:','readdirSync','1LkadRs','368826fgGkdC','join'];a185_0x9965=function(){return _0x571767;};return a185_0x9965();}(function(_0xef9f52,_0x187a20){const _0x134e61=a185_0x4029,_0x172c37=_0xef9f52();while(!![]){try{const _0x365b90=-parseInt(_0x134e61(0xab))/0x1*(parseInt(_0x134e61(0xa8))/0x2)+-parseInt(_0x134e61(0xa5))/0x3+parseInt(_0x134e61(0xa3))/0x4*(parseInt(_0x134e61(0x9f))/0x5)+-parseInt(_0x134e61(0x9d))/0x6+parseInt(_0x134e61(0xa1))/0x7+-parseInt(_0x134e61(0xa2))/0x8+parseInt(_0x134e61(0xa6))/0x9*(parseInt(_0x134e61(0xa0))/0xa);if(_0x365b90===_0x187a20)break;else _0x172c37['push'](_0x172c37['shift']());}catch(_0x59bec9){_0x172c37['push'](_0x172c37['shift']());}}}(a185_0x9965,0xa4ed4));import a185_0x2ead9f from'node:path';function a185_0x4029(_0x2c1901,_0x3dfdf3){_0x2c1901=_0x2c1901-0x9d;const _0x99657b=a185_0x9965();let _0x40294c=_0x99657b[_0x2c1901];return _0x40294c;}import a185_0x240353 from'node:fs';export async function copyDirectory(_0x571fd6,_0x29fb8c){const _0x364dd8=a185_0x4029;try{const _0x499b51=a185_0x240353[_0x364dd8(0xaa)](_0x571fd6,{'withFileTypes':!![]});a185_0x240353['mkdirSync'](_0x29fb8c,{'recursive':!![]});for(const _0x24559b of _0x499b51){const _0x4d3d3e=a185_0x2ead9f[_0x364dd8(0x9e)](_0x571fd6,_0x24559b[_0x364dd8(0xa7)]),_0x5ba628=a185_0x2ead9f[_0x364dd8(0x9e)](_0x29fb8c,_0x24559b[_0x364dd8(0xa7)]);_0x24559b[_0x364dd8(0xa4)]()?await copyDirectory(_0x4d3d3e,_0x5ba628):a185_0x240353['copyFileSync'](_0x4d3d3e,_0x5ba628);}}catch(_0x3fbcea){console['error'](_0x364dd8(0xa9),_0x3fbcea);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a186_0xe7fb(){const _0xe04765=['12021300LGYFey','172109MtGYMO','142MxqPjL','420411OSdDjy','1751305qrQKvm','288387YOBXec','6xjCZQX','4cyTLju','40CGPfpQ','string','70LNjRje','1063xIAirC','trim','38079jnygzi','isFinite'];a186_0xe7fb=function(){return _0xe04765;};return a186_0xe7fb();}(function(_0x2c9ccd,_0x5b8856){const _0xe3311a=a186_0x49fc,_0x2546cf=_0x2c9ccd();while(!![]){try{const _0x3b2694=parseInt(_0xe3311a(0xb1))/0x1*(-parseInt(_0xe3311a(0xb7))/0x2)+-parseInt(_0xe3311a(0xa9))/0x3+-parseInt(_0xe3311a(0xad))/0x4*(parseInt(_0xe3311a(0xaa))/0x5)+parseInt(_0xe3311a(0xac))/0x6*(-parseInt(_0xe3311a(0xb6))/0x7)+parseInt(_0xe3311a(0xae))/0x8*(parseInt(_0xe3311a(0xb3))/0x9)+-parseInt(_0xe3311a(0xb0))/0xa*(parseInt(_0xe3311a(0xab))/0xb)+parseInt(_0xe3311a(0xb5))/0xc;if(_0x3b2694===_0x5b8856)break;else _0x2546cf['push'](_0x2546cf['shift']());}catch(_0x2d5c08){_0x2546cf['push'](_0x2546cf['shift']());}}}(a186_0xe7fb,0x3cc79));function toFiniteNumber(_0x4db6fc){const _0xd8fcb7=a186_0x49fc;if(typeof _0x4db6fc==='number'&&Number[_0xd8fcb7(0xb4)](_0x4db6fc))return _0x4db6fc;if(typeof _0x4db6fc===_0xd8fcb7(0xaf)){const _0x2c3cc6=_0x4db6fc[_0xd8fcb7(0xb2)]();if(!_0x2c3cc6)return undefined;const _0x2ca075=Number(_0x2c3cc6);if(Number[_0xd8fcb7(0xb4)](_0x2ca075))return _0x2ca075;}return undefined;}function a186_0x49fc(_0x40e217,_0x175aac){_0x40e217=_0x40e217-0xa9;const _0xe7fbca=a186_0xe7fb();let _0x49fce0=_0xe7fbca[_0x40e217];return _0x49fce0;}export function normalizeEntityWithIdResponse(_0x154d76){const _0x1486fc=toFiniteNumber(_0x154d76);if(_0x1486fc!==undefined)return{'id':_0x1486fc,'entity':{'id':_0x1486fc}};if(!_0x154d76||typeof _0x154d76!=='object')return{'id':undefined,'entity':{}};const _0x55d675={..._0x154d76},_0xac4906=toFiniteNumber(_0x55d675['id']);return _0xac4906!==undefined&&(_0x55d675['id']=_0xac4906),{'id':_0xac4906,'entity':_0x55d675};}
|
package/lib/utils/file-utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x9d2dc1,_0x41bde0){const _0x51aad9=a187_0x1574,_0x1b4b59=_0x9d2dc1();while(!![]){try{const _0x1976a0=parseInt(_0x51aad9(0xd9))/0x1*(parseInt(_0x51aad9(0xdb))/0x2)+-parseInt(_0x51aad9(0xdf))/0x3+parseInt(_0x51aad9(0xd4))/0x4*(parseInt(_0x51aad9(0xe0))/0x5)+parseInt(_0x51aad9(0xdc))/0x6*(parseInt(_0x51aad9(0xdd))/0x7)+parseInt(_0x51aad9(0xda))/0x8*(-parseInt(_0x51aad9(0xd5))/0x9)+-parseInt(_0x51aad9(0xd8))/0xa*(-parseInt(_0x51aad9(0xd7))/0xb)+parseInt(_0x51aad9(0xde))/0xc*(-parseInt(_0x51aad9(0xd6))/0xd);if(_0x1976a0===_0x41bde0)break;else _0x1b4b59['push'](_0x1b4b59['shift']());}catch(_0x3a25f9){_0x1b4b59['push'](_0x1b4b59['shift']());}}}(a187_0x9c8e,0x2bfdb));import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';function a187_0x9c8e(){const _0x2ee055=['7JzdkIM','96ZoQnXN','303084WuOSjl','69550XhFhhn','isDirectory','20KGVpBr','64026yEnMet','48971ZrjuwJ','38819pCpWeG','270bHhGIj','8065sdNWVx','344QBqQJt','38ERJrFX','1795110nOYjLM'];a187_0x9c8e=function(){return _0x2ee055;};return a187_0x9c8e();}export async function copyDir(_0x28270c,_0x53ff6a){const _0x53b526=a187_0x1574,_0x5697c4=statSync(_0x28270c);if(_0x5697c4[_0x53b526(0xe1)]()){!existsSync(_0x53ff6a)&&mkdirSync(_0x53ff6a,{'recursive':!![]});const _0x21a916=readdirSync(_0x28270c);for(const _0x13e73e of _0x21a916){await copyDir(join(_0x28270c,_0x13e73e),join(_0x53ff6a,_0x13e73e));}}else copyFileSync(_0x28270c,_0x53ff6a);}function a187_0x1574(_0x596d41,_0x24ffe0){_0x596d41=_0x596d41-0xd4;const _0x9c8e29=a187_0x9c8e();let _0x157474=_0x9c8e29[_0x596d41];return _0x157474;}export function ensureDir(_0xd0e8b){!existsSync(_0xd0e8b)&&mkdirSync(_0xd0e8b,{'recursive':!![]});}export function pathExists(_0x2d62e3){return existsSync(_0x2d62e3);}
|
package/lib/utils/guides-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a188_0x5e63(_0x12e112,_0x4748ed){_0x12e112=_0x12e112-0x1d3;const _0x47bf8a=a188_0x47bf();let _0x5e6367=_0x47bf8a[_0x12e112];return _0x5e6367;}const a188_0x13d14b=a188_0x5e63;(function(_0x1f4402,_0x33394e){const _0x187540=a188_0x5e63,_0x2763ee=_0x1f4402();while(!![]){try{const _0x11f74b=parseInt(_0x187540(0x1d6))/0x1+-parseInt(_0x187540(0x1e3))/0x2+-parseInt(_0x187540(0x1de))/0x3+-parseInt(_0x187540(0x1e6))/0x4+-parseInt(_0x187540(0x1d9))/0x5+parseInt(_0x187540(0x1e4))/0x6+parseInt(_0x187540(0x1e8))/0x7*(parseInt(_0x187540(0x1eb))/0x8);if(_0x11f74b===_0x33394e)break;else _0x2763ee['push'](_0x2763ee['shift']());}catch(_0x5ddbb9){_0x2763ee['push'](_0x2763ee['shift']());}}}(a188_0x47bf,0x18859));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 _0x178d35=a188_0x5e63,_0x54c968=getTemplateBaseUrl();return _0x54c968+_0x178d35(0x1db);}const CACHE_DIR=join(homedir(),a188_0x13d14b(0x1e1),'cache');export async function fetchGuidesFromCDN(){const _0x3dd58b=a188_0x13d14b,_0x3bfcc2=getGuidesCdnUrl(),_0x47de32=await fetch(_0x3bfcc2,{'headers':{'Accept':_0x3dd58b(0x1dc)}});if(!_0x47de32['ok'])throw new Error(_0x3dd58b(0x1e2)+_0x47de32[_0x3dd58b(0x1ea)]+'\x20'+_0x47de32['statusText']);const _0x81d865=await _0x47de32['json']();if(!_0x81d865[_0x3dd58b(0x1ec)]||typeof _0x81d865[_0x3dd58b(0x1ec)]!=='object')throw new Error(_0x3dd58b(0x1d5));return _0x81d865;}export function writeGuidesToProject(_0xe4efd0,_0x27d15e,_0x3234ad=a188_0x13d14b(0x1e0),_0x5415df){const _0x1b6d7c=a188_0x13d14b,_0x8f42ce=join(_0x27d15e,_0x3234ad);mkdirSync(_0x8f42ce,{'recursive':!![]});for(const [_0x971773,_0x41861f]of Object['entries'](_0xe4efd0['guides'])){let _0x4b1a31=_0x41861f[_0x1b6d7c(0x1dd)];_0x41861f[_0x1b6d7c(0x1df)]&&(_0x4b1a31=appendUpdateTime(_0x4b1a31,_0x41861f[_0x1b6d7c(0x1df)])),writeFileSync(join(_0x8f42ce,_0x971773+_0x1b6d7c(0x1e9)),_0x4b1a31,_0x1b6d7c(0x1da));}}export function appendUpdateTime(_0x128a2a,_0x444f17){const _0x248cdc=a188_0x13d14b;return _0x128a2a=_0x128a2a[_0x248cdc(0x1ef)](/\n*>更新时间:.*$/m,''),_0x128a2a[_0x248cdc(0x1d4)]()+(_0x248cdc(0x1e7)+_0x444f17);}export function getSkillTemplate(_0x451d3d){const _0x501cf5=a188_0x13d14b;return _0x451d3d[_0x501cf5(0x1e5)]?.[_0x501cf5(0x1dd)]||'';}export function appendExtendContents(_0x81c7f1,_0x7c58a,_0xd395a5){const _0x3c64ca=a188_0x13d14b,_0xd38162=[];for(const [,_0x2e0b1e]of Object[_0x3c64ca(0x1d7)](_0x7c58a['guides'])){_0x2e0b1e['extendContent']&&_0xd38162['push'](_0x2e0b1e[_0x3c64ca(0x1ed)][_0x3c64ca(0x1d4)]());}if(_0xd38162['length']===0x0)return _0x81c7f1;return _0x81c7f1[_0x3c64ca(0x1d4)]()+'\x0a\x0a'+_0xd38162['join']('\x0a\x0a')+'\x0a';}function a188_0x47bf(){const _0x43825c=['140570KZwAUN','entries','title','120725LmVIFb','utf-8','/skills/guides.json','application/json','content','377283EuwgJL','lastUpdated','.lovrabet/skill/guides','.lovrabet','CDN\x20请求失败:\x20','58842jMEwPD','669894afxVCS','skillTemplate','344332AQpkYm','\x0a\x0a>更新时间:','56zdaFCA','.md','status','113632AZNmoY','guides','extendContent','CDN\x20数据中缺少\x20skillTemplate','replace','path','trimEnd','CDN\x20返回数据格式错误'];a188_0x47bf=function(){return _0x43825c;};return a188_0x47bf();}export function writeSkillFile(_0xc5e5c,_0xa7be49,_0xb6cddc){const _0x4e84ef=a188_0x13d14b,_0x2367b0=getSkillTemplate(_0xc5e5c);if(!_0x2367b0)throw new Error(_0x4e84ef(0x1ee));const _0x12f043=dirname(_0xa7be49);mkdirSync(_0x12f043,{'recursive':!![]});let _0x3a57eb=_0x2367b0['replace'](/\{\{IDE_NAME\}\}/g,_0xb6cddc);_0x3a57eb=appendExtendContents(_0x3a57eb,_0xc5e5c),_0xc5e5c['skillTemplate'][_0x4e84ef(0x1df)]&&(_0x3a57eb=appendUpdateTime(_0x3a57eb,_0xc5e5c[_0x4e84ef(0x1e5)]['lastUpdated'])),writeFileSync(_0xa7be49,_0x3a57eb,_0x4e84ef(0x1da));}export async function installGuides(_0x40120d){const _0x27f952=a188_0x13d14b,_0x5a3220=await fetchGuidesFromCDN();return writeGuidesToProject(_0x5a3220,_0x40120d),Object['keys'](_0x5a3220[_0x27f952(0x1ec)])['length'];}export function getGuidesSummary(_0x1a4cd0){const _0x28a39e=a188_0x13d14b;return Object['entries'](_0x1a4cd0[_0x28a39e(0x1ec)])['map'](([_0x2bf767,_0x460a50])=>({'key':_0x2bf767,'title':_0x460a50[_0x28a39e(0x1d8)],'path':_0x460a50[_0x28a39e(0x1d3)]}));}
|
package/lib/utils/http-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a189_0x25e0(){const _0x2275c1=['json','9cdzmdP','73jxBUqj','\x20次重试...','411940GMooKl','ms\x20后进行第\x20','log','get','771529oAxyEs','application/json','text','headers','4315308KkwWqX','TypeError','statusText','*\x20请求失败,','33716tidOIT','12FIhkfe','30HVCbmO','signal','2966CZtdkO','Request\x20failed','1727352UplrRI','fetch','includes','url','AbortError','abort','message','status','24GqRkXr','96873MNIVtR'];a189_0x25e0=function(){return _0x2275c1;};return a189_0x25e0();}(function(_0x271d40,_0x4d290c){const _0x268034=a189_0x3922,_0x5ccde9=_0x271d40();while(!![]){try{const _0x4ffc15=-parseInt(_0x268034(0x1cf))/0x1*(parseInt(_0x268034(0x1c1))/0x2)+-parseInt(_0x268034(0x1ce))/0x3*(parseInt(_0x268034(0x1bd))/0x4)+parseInt(_0x268034(0x1d1))/0x5*(parseInt(_0x268034(0x1be))/0x6)+-parseInt(_0x268034(0x1cc))/0x7*(-parseInt(_0x268034(0x1cb))/0x8)+parseInt(_0x268034(0x1c3))/0x9+parseInt(_0x268034(0x1bf))/0xa*(parseInt(_0x268034(0x1b5))/0xb)+-parseInt(_0x268034(0x1b9))/0xc;if(_0x4ffc15===_0x4d290c)break;else _0x5ccde9['push'](_0x5ccde9['shift']());}catch(_0x210b72){_0x5ccde9['push'](_0x5ccde9['shift']());}}}(a189_0x25e0,0x1c31b));export async function httpRequest(_0x4a9c18,_0x195953={}){const _0x58b431=a189_0x3922,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x195953;let _0x11a6d9=null;for(let _0x2968c2=0x0;_0x2968c2<=retries;_0x2968c2++){try{const _0x4f21d4=new AbortController(),_0x20146b=setTimeout(()=>_0x4f21d4[_0x58b431(0x1c8)](),timeout),_0x1e4d20=await fetch(_0x4a9c18,{'headers':headers,'signal':_0x4f21d4[_0x58b431(0x1c0)]});clearTimeout(_0x20146b);let _0x3fc56a;const _0x153b58=_0x1e4d20[_0x58b431(0x1b8)][_0x58b431(0x1b4)]('content-type');return _0x153b58?.[_0x58b431(0x1c5)](_0x58b431(0x1b6))?_0x3fc56a=await _0x1e4d20[_0x58b431(0x1cd)]():_0x3fc56a=await _0x1e4d20[_0x58b431(0x1b7)](),{'ok':_0x1e4d20['ok'],'status':_0x1e4d20[_0x58b431(0x1ca)],'statusText':_0x1e4d20[_0x58b431(0x1bb)],'data':_0x3fc56a,'headers':_0x1e4d20[_0x58b431(0x1b8)],'url':_0x1e4d20[_0x58b431(0x1c6)],'text':()=>_0x1e4d20[_0x58b431(0x1b7)]()};}catch(_0x5ddf12){_0x11a6d9=_0x5ddf12 instanceof Error?_0x5ddf12:new Error(String(_0x5ddf12));if(_0x2968c2===retries)break;if(shouldRetry(_0x5ddf12)){console[_0x58b431(0x1b3)](_0x58b431(0x1bc)+retryDelay+_0x58b431(0x1b2)+(_0x2968c2+0x1)+_0x58b431(0x1d0)),await sleep(retryDelay);continue;}else break;}}throw _0x11a6d9||new Error(_0x58b431(0x1c2));}function a189_0x3922(_0x1598c8,_0x31562c){_0x1598c8=_0x1598c8-0x1b2;const _0x25e02d=a189_0x25e0();let _0x3922b3=_0x25e02d[_0x1598c8];return _0x3922b3;}function shouldRetry(_0x103e1c){const _0x3d87cc=a189_0x3922;if(_0x103e1c instanceof Error){if(_0x103e1c['name']===_0x3d87cc(0x1c7))return![];if(_0x103e1c['name']===_0x3d87cc(0x1ba)&&_0x103e1c[_0x3d87cc(0x1c9)][_0x3d87cc(0x1c5)](_0x3d87cc(0x1c4)))return!![];if(_0x103e1c[_0x3d87cc(0x1c9)][_0x3d87cc(0x1c5)]('ECONNRESET'))return!![];if(_0x103e1c[_0x3d87cc(0x1c9)][_0x3d87cc(0x1c5)]('ENOTFOUND'))return![];}return![];}function sleep(_0x447d81){return new Promise(_0x3619a0=>setTimeout(_0x3619a0,_0x447d81));}export function validateUrl(_0x44ee3a){try{return new URL(_0x44ee3a),!![];}catch{return![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x2b31a8,_0x480fb3){const _0x3d950a=a190_0x5199,_0x4f615d=_0x2b31a8();while(!![]){try{const _0x24187a=parseInt(_0x3d950a(0x119))/0x1*(parseInt(_0x3d950a(0x112))/0x2)+-parseInt(_0x3d950a(0x111))/0x3+parseInt(_0x3d950a(0x113))/0x4+parseInt(_0x3d950a(0x116))/0x5*(parseInt(_0x3d950a(0x10e))/0x6)+-parseInt(_0x3d950a(0x114))/0x7*(parseInt(_0x3d950a(0x10c))/0x8)+parseInt(_0x3d950a(0x11a))/0x9*(parseInt(_0x3d950a(0x10b))/0xa)+-parseInt(_0x3d950a(0x117))/0xb;if(_0x24187a===_0x480fb3)break;else _0x4f615d['push'](_0x4f615d['shift']());}catch(_0x120ece){_0x4f615d['push'](_0x4f615d['shift']());}}}(a190_0x5a44,0x7b333));function a190_0x5a44(){const _0x517547=['true','1379555hvIZVA','3716515pplWoo','isTTY','89isDMnb','477NtUsVr','121030EmCfxI','123088iBfENS','isRaw','6CQmmfz','setRawMode','stdin','977907EEXGbx','7992MvwyAk','628036ktSCkj','119iCNHSH'];a190_0x5a44=function(){return _0x517547;};return a190_0x5a44();}function a190_0x5199(_0x5a8949,_0x4a85f7){_0x5a8949=_0x5a8949-0x10b;const _0x5a4419=a190_0x5a44();let _0x519904=_0x5a4419[_0x5a8949];return _0x519904;}function env(_0x4ad253){return process.env[`RABETBASE_${_0x4ad253}`]||process.env[`LOVRABET_${_0x4ad253}`]||undefined;}export function isNonInteractive(_0x11aa58){const _0x70a27b=a190_0x5199;return!!(_0x11aa58['nonInteractive']||_0x11aa58['ci']||env('CI')===_0x70a27b(0x115)||process.env.CI===_0x70a27b(0x115)||!process['stdout'][_0x70a27b(0x118)]||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x4af503=a190_0x5199;if(!process['stdin'][_0x4af503(0x118)])return![];try{const _0x2bc7e0=process[_0x4af503(0x110)][_0x4af503(0x10d)];return process[_0x4af503(0x110)][_0x4af503(0x10f)](!![]),process[_0x4af503(0x110)][_0x4af503(0x10f)](_0x2bc7e0??![]),!![];}catch{return![];}}
|
package/lib/utils/logger.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a191_0x48fcdb=a191_0x3000;function a191_0x5dfd(){const _0x5329c6=['addColors','311190HbsLlO','duration','info','transports','currentRawCommand','winstonLogger','logFilePath','4441195oEmiss','readFileSync','existsSync','join','1SzyaBc','initWinstonLogger','writeFileSync','timestamp','.lovrabet.log','setLogPath','error','dirname','trim','utf8','details','90879BLbkDj','setRawCommand','map','green','stringify','readLogs','errors','red','getWinstonInstance','2833420icuFSy','format','level','printf','warn','开始执行:\x20','3220202Vlywdf','3159940eZzxXs','119eSReMq','now','897296GCMcxB','blue','toISOString','rawCommand','yellow','90qIxSov','success'];a191_0x5dfd=function(){return _0x5329c6;};return a191_0x5dfd();}(function(_0x5284a2,_0x144e35){const _0x2b4ca9=a191_0x3000,_0x32470f=_0x5284a2();while(!![]){try{const _0x79de3d=parseInt(_0x2b4ca9(0xdc))/0x1*(-parseInt(_0x2b4ca9(0xc5))/0x2)+parseInt(_0x2b4ca9(0xb6))/0x3+-parseInt(_0x2b4ca9(0xc6))/0x4+parseInt(_0x2b4ca9(0xd8))/0x5+parseInt(_0x2b4ca9(0xd1))/0x6*(parseInt(_0x2b4ca9(0xc7))/0x7)+-parseInt(_0x2b4ca9(0xc9))/0x8*(-parseInt(_0x2b4ca9(0xce))/0x9)+parseInt(_0x2b4ca9(0xbf))/0xa;if(_0x79de3d===_0x144e35)break;else _0x32470f['push'](_0x32470f['shift']());}catch(_0x4835b3){_0x32470f['push'](_0x32470f['shift']());}}}(a191_0x5dfd,0xc48f9));import a191_0x7859df from'winston';import a191_0xc925f4 from'node:fs';function a191_0x3000(_0x1f3eeb,_0x5635b1){_0x1f3eeb=_0x1f3eeb-0xb3;const _0x5dfde5=a191_0x5dfd();let _0x300045=_0x5dfde5[_0x1f3eeb];return _0x300045;}import a191_0x5eb79c from'node:path';class Logger{[a191_0x48fcdb(0xd6)];[a191_0x48fcdb(0xd7)];['currentRawCommand']='';constructor(){const _0x5eba00=a191_0x48fcdb;this[_0x5eba00(0xd7)]='';}[a191_0x48fcdb(0xb7)](_0x3e908d){const _0x4fb042=a191_0x48fcdb;this[_0x4fb042(0xd5)]=_0x3e908d;}[a191_0x48fcdb(0xdd)](){const _0x557f45=a191_0x48fcdb,_0x299b36=a191_0x5eb79c[_0x557f45(0xe3)](this[_0x557f45(0xd7)]);!a191_0xc925f4['existsSync'](_0x299b36)&&a191_0xc925f4['mkdirSync'](_0x299b36,{'recursive':!![]});const _0x431423=a191_0x7859df[_0x557f45(0xc0)]['combine'](a191_0x7859df[_0x557f45(0xc0)][_0x557f45(0xdf)](),a191_0x7859df['format'][_0x557f45(0xbc)]({'stack':!![]}),a191_0x7859df['format'][_0x557f45(0xc2)](_0x48c053=>{const _0x343e84=_0x557f45,_0x57443c={'timestamp':_0x48c053[_0x343e84(0xdf)]||new Date()[_0x343e84(0xcb)](),'level':_0x48c053[_0x343e84(0xc1)]||'info','command':_0x48c053['command']||'unknown','rawCommand':_0x48c053[_0x343e84(0xcc)]||this[_0x343e84(0xd5)]||undefined,'message':_0x48c053['message']||'','duration':_0x48c053[_0x343e84(0xd2)]||undefined,'details':_0x48c053[_0x343e84(0xb5)]||undefined};return JSON[_0x343e84(0xba)](_0x57443c);}));this[_0x557f45(0xd6)]=a191_0x7859df['createLogger']({'level':_0x557f45(0xd3),'format':_0x431423,'transports':[new a191_0x7859df[(_0x557f45(0xd4))]['File']({'filename':this[_0x557f45(0xd7)],'level':'info'})],'silent':![]}),a191_0x7859df[_0x557f45(0xd0)]({'success':_0x557f45(0xb9),'error':_0x557f45(0xbd),'warn':_0x557f45(0xcd),'info':_0x557f45(0xca)});}[a191_0x48fcdb(0xe1)](_0x5a5d8f){const _0x4043d1=a191_0x48fcdb;this['logFilePath']=a191_0x5eb79c[_0x4043d1(0xdb)](_0x5a5d8f,_0x4043d1(0xe0)),this[_0x4043d1(0xd6)]&&this[_0x4043d1(0xd6)]['clear'](),this[_0x4043d1(0xdd)]();}[a191_0x48fcdb(0xd3)](_0x21d983,_0x1bff8f,_0x463e2f){const _0x2ce5b5=a191_0x48fcdb;if(!this[_0x2ce5b5(0xd7)]||!this[_0x2ce5b5(0xd6)])return;this[_0x2ce5b5(0xd6)][_0x2ce5b5(0xd3)](_0x1bff8f,{'command':_0x21d983,'details':_0x463e2f});}[a191_0x48fcdb(0xcf)](_0x16ed63,_0x39f572,_0x444865,_0x570099){const _0x204aa5=a191_0x48fcdb;if(!this[_0x204aa5(0xd7)]||!this['winstonLogger'])return;this[_0x204aa5(0xd6)]['log'](_0x204aa5(0xd3),_0x39f572,{'level':'success','command':_0x16ed63,'duration':_0x444865,'details':_0x570099});}[a191_0x48fcdb(0xe2)](_0x5d519b,_0x423110,_0x310b40){const _0x2667d0=a191_0x48fcdb;if(!this[_0x2667d0(0xd7)]||!this[_0x2667d0(0xd6)])return;this[_0x2667d0(0xd6)][_0x2667d0(0xe2)](_0x423110,{'command':_0x5d519b,'details':_0x310b40});}[a191_0x48fcdb(0xc3)](_0x5ad758,_0x4d6e90,_0x53eacd){const _0x4a31c5=a191_0x48fcdb;if(!this[_0x4a31c5(0xd7)]||!this[_0x4a31c5(0xd6)])return;this[_0x4a31c5(0xd6)][_0x4a31c5(0xc3)](_0x4d6e90,{'command':_0x5ad758,'details':_0x53eacd});}async['logTask'](_0x27c9d4,_0x3d65cd,_0x342eff){const _0x4f70ba=a191_0x48fcdb,_0x342400=Date[_0x4f70ba(0xc8)]();this[_0x4f70ba(0xd3)](_0x27c9d4,_0x4f70ba(0xc4)+_0x3d65cd);try{const _0x226390=await _0x342eff(),_0x620149=Date[_0x4f70ba(0xc8)]()-_0x342400;return this[_0x4f70ba(0xcf)](_0x27c9d4,'完成:\x20'+_0x3d65cd,_0x620149),_0x226390;}catch(_0x4ad333){const _0x2b0cb2=Date[_0x4f70ba(0xc8)]()-_0x342400;this['error'](_0x27c9d4,'失败:\x20'+_0x3d65cd,{'error':_0x4ad333 instanceof Error?_0x4ad333['message']:String(_0x4ad333),'duration':_0x2b0cb2});throw _0x4ad333;}}[a191_0x48fcdb(0xbb)](){const _0x2f0ff3=a191_0x48fcdb;try{if(!a191_0xc925f4[_0x2f0ff3(0xda)](this[_0x2f0ff3(0xd7)]))return[];const _0x2a25ac=a191_0xc925f4[_0x2f0ff3(0xd9)](this[_0x2f0ff3(0xd7)],_0x2f0ff3(0xb4));return _0x2a25ac['split']('\x0a')['filter'](_0x5039e0=>_0x5039e0[_0x2f0ff3(0xb3)]())[_0x2f0ff3(0xb8)](_0x52b393=>JSON['parse'](_0x52b393));}catch(_0x56f289){return console[_0x2f0ff3(0xc3)]('Failed\x20to\x20read\x20logs:',_0x56f289),[];}}['clearLogs'](){const _0x2f82ed=a191_0x48fcdb;try{a191_0xc925f4['existsSync'](this['logFilePath'])&&a191_0xc925f4[_0x2f82ed(0xde)](this['logFilePath'],'','utf8');}catch(_0x4f95f9){console[_0x2f82ed(0xc3)]('Failed\x20to\x20clear\x20logs:',_0x4f95f9);}}[a191_0x48fcdb(0xbe)](){const _0x55dace=a191_0x48fcdb;return this[_0x55dace(0xd6)];}}export const logger=new Logger();
|
package/lib/utils/params.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a192_0x50cc(_0x4b5e3b,_0x5135d6){_0x4b5e3b=_0x4b5e3b-0x1ba;const _0x34f9c3=a192_0x34f9();let _0x50cc21=_0x34f9c3[_0x4b5e3b];return _0x50cc21;}(function(_0x1787d4,_0x35bdcc){const _0x418c52=a192_0x50cc,_0x5b8f2c=_0x1787d4();while(!![]){try{const _0x320543=-parseInt(_0x418c52(0x1c6))/0x1+parseInt(_0x418c52(0x1ca))/0x2*(-parseInt(_0x418c52(0x1c7))/0x3)+-parseInt(_0x418c52(0x1c4))/0x4*(parseInt(_0x418c52(0x1c9))/0x5)+-parseInt(_0x418c52(0x1c3))/0x6*(-parseInt(_0x418c52(0x1c1))/0x7)+-parseInt(_0x418c52(0x1c5))/0x8+-parseInt(_0x418c52(0x1bd))/0x9*(-parseInt(_0x418c52(0x1c8))/0xa)+parseInt(_0x418c52(0x1ba))/0xb;if(_0x320543===_0x35bdcc)break;else _0x5b8f2c['push'](_0x5b8f2c['shift']());}catch(_0x4c7257){_0x5b8f2c['push'](_0x5b8f2c['shift']());}}}(a192_0x34f9,0x281d3));import{CliErrors}from'../errors.js';function a192_0x34f9(){const _0x1fad01=['3DIRrYi','20EECslA','615675RilmHM','240074UvKNfh','object','4959955lXPNcI','parse','isArray','372753zLfZVu','Invalid\x20JSON\x20for\x20--params:\x20','validation','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','7fCcoVo','--params\x20must\x20be\x20a\x20JSON\x20object','1941834HNndQc','4GdvYbW','1818896QjxkMe','222537ilFiEq'];a192_0x34f9=function(){return _0x1fad01;};return a192_0x34f9();}export function parseJsonParams(_0x4ceea1){const _0x12ac99=a192_0x50cc;if(!_0x4ceea1)return undefined;let _0x31fec0;try{_0x31fec0=JSON[_0x12ac99(0x1bb)](_0x4ceea1);}catch{throw CliErrors[_0x12ac99(0x1bf)](_0x12ac99(0x1be)+_0x4ceea1);}if(!_0x31fec0||typeof _0x31fec0!==_0x12ac99(0x1cb)||Array[_0x12ac99(0x1bc)](_0x31fec0))throw CliErrors[_0x12ac99(0x1bf)](_0x12ac99(0x1c2),_0x12ac99(0x1c0));return _0x31fec0;}
|
package/lib/utils/platform.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a193_0x1bb6(_0x29b782,_0x16ff5b){_0x29b782=_0x29b782-0x11b;const _0x27219b=a193_0x2721();let _0x1bb6c8=_0x27219b[_0x29b782];return _0x1bb6c8;}const a193_0x480580=a193_0x1bb6;(function(_0x23539e,_0x3bdb13){const _0x3fd286=a193_0x1bb6,_0x4199cf=_0x23539e();while(!![]){try{const _0x2cd569=-parseInt(_0x3fd286(0x11e))/0x1*(-parseInt(_0x3fd286(0x120))/0x2)+parseInt(_0x3fd286(0x11d))/0x3*(parseInt(_0x3fd286(0x124))/0x4)+-parseInt(_0x3fd286(0x122))/0x5+parseInt(_0x3fd286(0x126))/0x6+-parseInt(_0x3fd286(0x11b))/0x7+parseInt(_0x3fd286(0x11f))/0x8+-parseInt(_0x3fd286(0x11c))/0x9*(parseInt(_0x3fd286(0x123))/0xa);if(_0x2cd569===_0x3bdb13)break;else _0x4199cf['push'](_0x4199cf['shift']());}catch(_0x1afc17){_0x4199cf['push'](_0x4199cf['shift']());}}}(a193_0x2721,0x70fb2));export const isWindows=process[a193_0x480580(0x121)]==='win32';export function resolveNpmBin(_0x182617){const _0x105348=a193_0x480580;return isWindows?_0x182617+_0x105348(0x125):_0x182617;}function a193_0x2721(){const _0x1374a3=['4518342BrwcUN','1432060tplHiD','270909ooXYkD','2392245MEibJi','172savADL','4940816znGrcT','2620FMKjzW','platform','4566585zsctPm','270OLSouh','4tplQGM','.cmd'];a193_0x2721=function(){return _0x1374a3;};return a193_0x2721();}
|
package/lib/utils/rules-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a194_0x4cc999=a194_0x290a;(function(_0x500b5f,_0x441dcc){const _0x44db77=a194_0x290a,_0x22a9ca=_0x500b5f();while(!![]){try{const _0x1c424b=-parseInt(_0x44db77(0x13c))/0x1*(parseInt(_0x44db77(0x13f))/0x2)+-parseInt(_0x44db77(0x12d))/0x3+parseInt(_0x44db77(0x133))/0x4+parseInt(_0x44db77(0x134))/0x5+parseInt(_0x44db77(0x12c))/0x6*(-parseInt(_0x44db77(0x13d))/0x7)+-parseInt(_0x44db77(0x12b))/0x8*(-parseInt(_0x44db77(0x13e))/0x9)+parseInt(_0x44db77(0x136))/0xa;if(_0x1c424b===_0x441dcc)break;else _0x22a9ca['push'](_0x22a9ca['shift']());}catch(_0x53120d){_0x22a9ca['push'](_0x22a9ca['shift']());}}}(a194_0x500d,0xd4391));import{existsSync,mkdirSync,readFileSync,writeFileSync}from'node:fs';import{dirname,join,resolve}from'node:path';import{fileURLToPath}from'node:url';function a194_0x500d(){const _0x138cfb=['242fehhIa','5021891qkuoNh','338139FPsepi','356NRCUBW','/rules/rules.json','../../templates/rules/lovrabet_rules.mdc.tpl','24fXyBzC','6rWBbJw','3006648rXukIS','statusText','content','.cursor/rules','json','lastUpdated','492564ltiabu','2148155GqRWFm','agents.md','19664850cJeQtG','CDN\x20请求失败:\x20','utf-8','catch','lovrabet_rules.mdc','application/json'];a194_0x500d=function(){return _0x138cfb;};return a194_0x500d();}import{getTemplateBaseUrl}from'../utils/config.js';import{appendUpdateTime}from'../utils/guides-cdn.js';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function a194_0x290a(_0x3bcdc2,_0x13d581){_0x3bcdc2=_0x3bcdc2-0x12a;const _0x500d72=a194_0x500d();let _0x290aa7=_0x500d72[_0x3bcdc2];return _0x290aa7;}function getRulesCdnUrl(){const _0x418dfe=a194_0x290a,_0x4fb29a=getTemplateBaseUrl();return _0x4fb29a+_0x418dfe(0x140);}const LOCAL_TEMPLATE_PATH=resolve(__dirname,a194_0x4cc999(0x12a));export async function fetchRulesFromCDN(){const _0x33486a=a194_0x4cc999,_0x4e4dc3=getRulesCdnUrl(),_0x2b4388=await fetch(_0x4e4dc3,{'headers':{'Accept':_0x33486a(0x13b)}});if(!_0x2b4388['ok'])throw new Error(_0x33486a(0x137)+_0x2b4388['status']+'\x20'+_0x2b4388[_0x33486a(0x12e)]);const _0x3b387d=await _0x2b4388[_0x33486a(0x131)]();if(!_0x3b387d[_0x33486a(0x12f)]||typeof _0x3b387d[_0x33486a(0x12f)]!=='string')throw new Error('CDN\x20返回数据格式错误');return _0x3b387d;}export async function getRulesContent(){const _0x470a89=a194_0x4cc999;try{const _0x2ede3d=await fetchRulesFromCDN();return _0x2ede3d[_0x470a89(0x12f)];}catch{return readLocalTemplate();}}export function readLocalTemplate(){const _0x365277=a194_0x4cc999;if(existsSync(LOCAL_TEMPLATE_PATH))return readFileSync(LOCAL_TEMPLATE_PATH,_0x365277(0x138));throw new Error('本地模板文件不存在:\x20'+LOCAL_TEMPLATE_PATH);}export async function writeRulesFile(_0x5ad6eb){const _0x1d6084=a194_0x4cc999,_0x8053bd=await fetchRulesFromCDN()[_0x1d6084(0x139)](()=>null);let _0x41401b;_0x8053bd?(_0x41401b=_0x8053bd['content'],_0x8053bd[_0x1d6084(0x132)]&&(_0x41401b=appendUpdateTime(_0x41401b,_0x8053bd[_0x1d6084(0x132)]))):_0x41401b=readLocalTemplate();const _0x15fcb5=dirname(_0x5ad6eb);!existsSync(_0x15fcb5)&&mkdirSync(_0x15fcb5,{'recursive':!![]}),writeFileSync(_0x5ad6eb,_0x41401b,_0x1d6084(0x138));}export async function copyRulesToCursor(_0x5e1594){const _0x128459=a194_0x4cc999,_0x5e3fb1=join(_0x5e1594,_0x128459(0x130)),_0x537f44=join(_0x5e3fb1,_0x128459(0x13a));if(existsSync(_0x537f44))return![];return await writeRulesFile(_0x537f44),!![];}export async function copyRulesToAgentsMd(_0x4061d7){const _0x2a4e6c=a194_0x4cc999,_0x5e6773=join(_0x4061d7,_0x2a4e6c(0x135));if(existsSync(_0x5e6773))return![];return await writeRulesFile(_0x5e6773),!![];}
|
package/lib/utils/sleep.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export function sleep(
|
|
1
|
+
export function sleep(_0x26639a){return new Promise(_0x42236d=>setTimeout(_0x42236d,_0x26639a));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a196_0x4fb692=a196_0x2460;(function(_0x5158d0,_0xf4f5c2){const _0x34de83=a196_0x2460,_0x9c1358=_0x5158d0();while(!![]){try{const _0xc721ee=-parseInt(_0x34de83(0x220))/0x1+-parseInt(_0x34de83(0x214))/0x2*(parseInt(_0x34de83(0x226))/0x3)+parseInt(_0x34de83(0x223))/0x4+parseInt(_0x34de83(0x1df))/0x5*(parseInt(_0x34de83(0x20d))/0x6)+parseInt(_0x34de83(0x1f0))/0x7*(-parseInt(_0x34de83(0x202))/0x8)+parseInt(_0x34de83(0x21e))/0x9+parseInt(_0x34de83(0x203))/0xa;if(_0xc721ee===_0xf4f5c2)break;else _0x9c1358['push'](_0x9c1358['shift']());}catch(_0x3133f8){_0x9c1358['push'](_0x9c1358['shift']());}}}(a196_0x5450,0x1da46));import a196_0x5674ef from'node:fs';function a196_0x2460(_0x4eb6c1,_0x11c328){_0x4eb6c1=_0x4eb6c1-0x1df;const _0x545022=a196_0x5450();let _0x246055=_0x545022[_0x4eb6c1];return _0x246055;}function a196_0x5450(){const _0x3d701f=['utf8','\x20},','YourModel','toLowerCase','.js','模板内容替换失败','push','pad','418968FCHIEI','1111130gqstei','replace','join','.scss','\x0a\x20\x20\x20\x20{\x20','error','alias:\x20\x22','padStart','alias','default','24lnDBSR','.tpl','模板内容替换完成','.tsx','isFile','tableName:\x20\x22','name','7338uwTADj','success','slice','readdir','replaceApiContent','isDirectory','tableName','charAt','.ts','getHours','1845423ngnxVE','.jsx','129533xfdJGn','replaceContent','getSeconds','424872CMXfVV','mkdir','toComponentName','102qOKlKC','138035eIdSWA','template','info','getMonth','datasetCode:\x20\x22','message','promises','processDirectory','now','processTemplate','includes','toUpperCase','extname','.json','LOVRABET','writeFile','toISOString','21SFUjhZ','.css','endsWith','formatLocalTimestamp','name:\x20\x22','split','copyFile','toDisplayTitle','getMinutes','map'];a196_0x5450=function(){return _0x3d701f;};return a196_0x5450();}import a196_0x167f1e from'node:path';import{logger}from'../utils/logger.js';import{getCliVersion}from'../utils/version.js';const CLI_VERSION=getCliVersion();export class TemplateReplacer{static[a196_0x4fb692(0x201)](_0x4eed3c){const _0xd70336=a196_0x4fb692;return String(_0x4eed3c)[_0xd70336(0x20a)](0x2,'0');}static[a196_0x4fb692(0x1f3)](_0x9c9c96){const _0x40ca65=a196_0x4fb692,_0x48b27c=_0x9c9c96['getFullYear'](),_0x5d095d=this[_0x40ca65(0x201)](_0x9c9c96[_0x40ca65(0x1e2)]()+0x1),_0x484176=this[_0x40ca65(0x201)](_0x9c9c96['getDate']()),_0x1c3fca=this[_0x40ca65(0x201)](_0x9c9c96[_0x40ca65(0x21d)]()),_0x431de9=this[_0x40ca65(0x201)](_0x9c9c96[_0x40ca65(0x1f8)]()),_0x19b3e9=this[_0x40ca65(0x201)](_0x9c9c96[_0x40ca65(0x222)]());return{'createdAt':_0x48b27c+'-'+_0x5d095d+'-'+_0x484176+'\x20'+_0x1c3fca+':'+_0x431de9+':'+_0x19b3e9,'createdDate':_0x48b27c+'-'+_0x5d095d+'-'+_0x484176,'createdTime':_0x1c3fca+':'+_0x431de9+':'+_0x19b3e9};}static[a196_0x4fb692(0x225)](_0x356b9d){const _0x45a879=a196_0x4fb692,_0x5ae56f=_0x356b9d['split']('/')['pop']()||_0x356b9d;return _0x5ae56f[_0x45a879(0x1f5)]('-')[_0x45a879(0x1f9)](_0x4ef9bd=>_0x4ef9bd[_0x45a879(0x21b)](0x0)[_0x45a879(0x1ea)]()+_0x4ef9bd['slice'](0x1)[_0x45a879(0x1fd)]())[_0x45a879(0x205)]('');}static[a196_0x4fb692(0x1f7)](_0x3e5d17){const _0x2a541f=a196_0x4fb692,_0x1c84ab=_0x3e5d17[_0x2a541f(0x1f5)]('/')['pop']()||_0x3e5d17;return _0x1c84ab['split']('-')[_0x2a541f(0x1f9)](_0x14e33a=>_0x14e33a['charAt'](0x0)[_0x2a541f(0x1ea)]()+_0x14e33a[_0x2a541f(0x216)](0x1)[_0x2a541f(0x1fd)]())[_0x2a541f(0x205)]('\x20');}static[a196_0x4fb692(0x221)](_0x56991f,_0x20e5db,_0x56b69d){const _0x5d4816=a196_0x4fb692,_0x3d8cb9=this[_0x5d4816(0x225)](_0x20e5db),_0x296f01=this['toDisplayTitle'](_0x20e5db),{createdAt:_0x4faf6e,createdDate:_0x1b04e2,createdTime:_0x33f705}=this[_0x5d4816(0x1f3)](new Date());let _0x44e839=_0x56991f[_0x5d4816(0x204)](/\{CliVersion\}/g,CLI_VERSION)[_0x5d4816(0x204)](/\{ComponentName\}/g,_0x3d8cb9)[_0x5d4816(0x204)](/\{DisplayTitle\}/g,_0x296f01)[_0x5d4816(0x204)](/\{PageName\}/g,_0x20e5db)['replace'](/\{TemplateName\}/g,_0x56b69d)[_0x5d4816(0x204)](/\{CreatedAt\}/g,_0x4faf6e)[_0x5d4816(0x204)](/\{CreatedDate\}/g,_0x1b04e2)[_0x5d4816(0x204)](/\{CreatedTime\}/g,_0x33f705);return _0x44e839;}static[a196_0x4fb692(0x218)](_0x2613e4,_0x31bbb4,_0x5e271f,_0xa8f5d,_0x51fe56,_0x463085,_0x4eaf2a,_0x2cd7db){const _0x56cee6=a196_0x4fb692,_0x52c53f=new Date(),_0x3b6403=_0x52c53f[_0x56cee6(0x1ef)](),_0x49c995=_0x5e271f[_0x56cee6(0x1f9)](_0x5ca1c8=>{const _0x569658=_0x56cee6,_0x4e9186=[_0x569658(0x1e3)+_0x5ca1c8['datasetCode']+'\x22',_0x569658(0x212)+_0x5ca1c8[_0x569658(0x21a)]+'\x22',_0x569658(0x1f4)+_0x5ca1c8[_0x569658(0x213)]+'\x22'];return _0x5ca1c8[_0x569658(0x20b)]&&_0x4e9186[_0x569658(0x200)](_0x569658(0x209)+_0x5ca1c8[_0x569658(0x20b)]+'\x22'),_0x569658(0x207)+_0x4e9186[_0x569658(0x205)](',\x20')+_0x569658(0x1fb);})[_0x56cee6(0x205)](''),_0x31434c=_0xa8f5d||_0x5e271f[0x0]?.[_0x56cee6(0x20b)]||_0x56cee6(0x1fc);let _0x62cbec=_0x2613e4['replace'](/\{AppCode\}/g,_0x31bbb4)[_0x56cee6(0x204)](/\{ModelConfigs\}/g,_0x49c995)[_0x56cee6(0x204)](/\{ExampleModelName\}/g,_0x31434c)[_0x56cee6(0x204)](/\{ApiFileName\}/g,_0x51fe56||'api')[_0x56cee6(0x204)](/\{ConfigName\}/g,_0x463085||_0x56cee6(0x20c))[_0x56cee6(0x204)](/\{ClientConfigParam\}/g,_0x4eaf2a||'')[_0x56cee6(0x204)](/\{VarPrefix\}/g,_0x2cd7db||_0x56cee6(0x1ed))[_0x56cee6(0x204)](/\{CreatedAt\}/g,_0x3b6403);return _0x62cbec;}static async[a196_0x4fb692(0x1e8)](_0x27929a,_0x19e0f6,_0x491be4,_0x2d23ac,_0x3a3ba0=!![]){const _0x5cbb42=a196_0x4fb692,_0x16546b=Date[_0x5cbb42(0x1e7)]();try{_0x3a3ba0&&logger[_0x5cbb42(0x1e1)]('template','开始处理模板内容替换',{'templatePath':_0x27929a,'targetPath':_0x19e0f6,'pageName':_0x491be4,'templateName':_0x2d23ac});await a196_0x5674ef['promises']['mkdir'](_0x19e0f6,{'recursive':!![]}),await this['processDirectory'](_0x27929a,_0x19e0f6,_0x491be4,_0x2d23ac);if(_0x3a3ba0){const _0x428569=Date[_0x5cbb42(0x1e7)]()-_0x16546b;logger[_0x5cbb42(0x215)]('template',_0x5cbb42(0x20f),_0x428569,{'pageName':_0x491be4,'templateName':_0x2d23ac});}}catch(_0x513a08){if(_0x3a3ba0){const _0x3f6ba1=Date[_0x5cbb42(0x1e7)]()-_0x16546b;logger[_0x5cbb42(0x208)](_0x5cbb42(0x1e0),_0x5cbb42(0x1ff),{'templatePath':_0x27929a,'targetPath':_0x19e0f6,'pageName':_0x491be4,'templateName':_0x2d23ac,'error':_0x513a08 instanceof Error?_0x513a08[_0x5cbb42(0x1e4)]:String(_0x513a08),'duration':_0x3f6ba1});}throw _0x513a08;}}static async['processDirectory'](_0x429990,_0x159a67,_0x1dcd26,_0x5ba026){const _0x4ab28c=a196_0x4fb692,_0x5ea5aa=await a196_0x5674ef[_0x4ab28c(0x1e5)][_0x4ab28c(0x217)](_0x429990,{'withFileTypes':!![]});for(const _0x2589fa of _0x5ea5aa){const _0x209122=a196_0x167f1e[_0x4ab28c(0x205)](_0x429990,_0x2589fa[_0x4ab28c(0x213)]);let _0xdcc879=a196_0x167f1e['join'](_0x159a67,_0x2589fa[_0x4ab28c(0x213)]);_0x2589fa[_0x4ab28c(0x213)][_0x4ab28c(0x1f2)](_0x4ab28c(0x20e))&&(_0xdcc879=a196_0x167f1e[_0x4ab28c(0x205)](_0x159a67,_0x2589fa[_0x4ab28c(0x213)][_0x4ab28c(0x204)](/\.tpl$/,'')));if(_0x2589fa[_0x4ab28c(0x219)]())await a196_0x5674ef[_0x4ab28c(0x1e5)][_0x4ab28c(0x224)](_0xdcc879,{'recursive':!![]}),await this[_0x4ab28c(0x1e6)](_0x209122,_0xdcc879,_0x1dcd26,_0x5ba026);else _0x2589fa[_0x4ab28c(0x211)]()&&await this['processFile'](_0x209122,_0xdcc879,_0x1dcd26,_0x5ba026);}}static async['processFile'](_0x177cf0,_0x346149,_0x3bacab,_0x5c59a7){const _0xc5d40e=a196_0x4fb692,_0x2e74ab=a196_0x167f1e[_0xc5d40e(0x1eb)](_0x177cf0)[_0xc5d40e(0x1fd)]();_0x177cf0[_0xc5d40e(0x1f2)](_0xc5d40e(0x20e))&&(_0x346149=_0x346149[_0xc5d40e(0x204)](/\.tpl$/,''));const _0x522d81=[_0xc5d40e(0x210),_0xc5d40e(0x21c),_0xc5d40e(0x21f),_0xc5d40e(0x1fe),_0xc5d40e(0x1ec),'.md',_0xc5d40e(0x1f1),_0xc5d40e(0x206),_0xc5d40e(0x20e)];if(_0x522d81[_0xc5d40e(0x1e9)](_0x2e74ab)||_0x177cf0[_0xc5d40e(0x1f2)](_0xc5d40e(0x20e))){const _0x8ad128=await a196_0x5674ef[_0xc5d40e(0x1e5)]['readFile'](_0x177cf0,'utf8'),_0x4b8ded=this[_0xc5d40e(0x221)](_0x8ad128,_0x3bacab,_0x5c59a7);await a196_0x5674ef['promises'][_0xc5d40e(0x1ee)](_0x346149,_0x4b8ded,_0xc5d40e(0x1fa));}else await a196_0x5674ef[_0xc5d40e(0x1e5)][_0xc5d40e(0x1f6)](_0x177cf0,_0x346149);}}
|
package/lib/utils/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1f2f44,_0x22b6b5){var _0x329ef6=a197_0x5a94,_0x4f6348=_0x1f2f44();while(!![]){try{var _0x37b9e1=parseInt(_0x329ef6(0xe1))/0x1*(parseInt(_0x329ef6(0xdb))/0x2)+parseInt(_0x329ef6(0xe0))/0x3*(-parseInt(_0x329ef6(0xdd))/0x4)+-parseInt(_0x329ef6(0xdf))/0x5*(parseInt(_0x329ef6(0xdc))/0x6)+parseInt(_0x329ef6(0xe3))/0x7*(-parseInt(_0x329ef6(0xe6))/0x8)+-parseInt(_0x329ef6(0xde))/0x9+parseInt(_0x329ef6(0xe2))/0xa*(-parseInt(_0x329ef6(0xe5))/0xb)+parseInt(_0x329ef6(0xe4))/0xc;if(_0x37b9e1===_0x22b6b5)break;else _0x4f6348['push'](_0x4f6348['shift']());}catch(_0x596f49){_0x4f6348['push'](_0x4f6348['shift']());}}}(a197_0x1f06,0xe423a));function a197_0x5a94(_0x24a5ed,_0x33d663){_0x24a5ed=_0x24a5ed-0xdb;var _0x1f06de=a197_0x1f06();var _0x5a94b1=_0x1f06de[_0x24a5ed];return _0x5a94b1;}function a197_0x1f06(){var _0x5d95ea=['1TYWGFB','10568090iwTvpq','139146UrcLHZ','39087432XBFVdK','11SzlVDs','392WNDiYa','2740538XSmorr','414mlctsL','199140dapgll','2468331lSZeke','93365CWgXCJ','6nYjCgi'];a197_0x1f06=function(){return _0x5d95ea;};return a197_0x1f06();}import{VERSION}from'../generated/build-info.js';export function getCliVersion(){return VERSION;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x20f17e,_0x13633b){var _0x3a5389=a198_0x4820,_0x26d414=_0x20f17e();while(!![]){try{var _0x23c710=-parseInt(_0x3a5389(0x102))/0x1*(parseInt(_0x3a5389(0x104))/0x2)+parseInt(_0x3a5389(0xfb))/0x3*(-parseInt(_0x3a5389(0xfa))/0x4)+-parseInt(_0x3a5389(0xfc))/0x5*(parseInt(_0x3a5389(0xff))/0x6)+parseInt(_0x3a5389(0x103))/0x7*(-parseInt(_0x3a5389(0x101))/0x8)+parseInt(_0x3a5389(0xfd))/0x9+-parseInt(_0x3a5389(0xf8))/0xa*(-parseInt(_0x3a5389(0x100))/0xb)+-parseInt(_0x3a5389(0xf9))/0xc*(-parseInt(_0x3a5389(0xfe))/0xd);if(_0x23c710===_0x13633b)break;else _0x26d414['push'](_0x26d414['shift']());}catch(_0x4545eb){_0x26d414['push'](_0x26d414['shift']());}}}(a198_0x391b,0x2fc80));function a198_0x4820(_0x19aba5,_0x15c58b){_0x19aba5=_0x19aba5-0xf8;var _0x391b8f=a198_0x391b();var _0x48204e=_0x391b8f[_0x19aba5];return _0x48204e;}import{setActiveCookie,clearActiveCookie}from'../core/api-client.js';function a198_0x391b(){var _0x424d9e=['130KPRhkD','510YChSoA','486035JyxaQx','122872Emvyrd','61485qcexTt','91YBtoWK','8qwWlMN','70ziPJth','348468JHXPuX','2372MKYMkq','747UkjTlC','5045YdXCCD','2475504eHRvQX'];a198_0x391b=function(){return _0x424d9e;};return a198_0x391b();}export async function withActiveCookie(_0x495782,_0x49ae08){setActiveCookie(_0x495782);try{return await _0x49ae08();}finally{clearActiveCookie();}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3eda99,_0x24df31){var _0xd70c1d=a199_0x40f6,_0x10c41a=_0x3eda99();while(!![]){try{var _0x24c9e0=-parseInt(_0xd70c1d(0x65))/0x1+-parseInt(_0xd70c1d(0x6b))/0x2+parseInt(_0xd70c1d(0x68))/0x3+parseInt(_0xd70c1d(0x6a))/0x4+-parseInt(_0xd70c1d(0x67))/0x5*(parseInt(_0xd70c1d(0x66))/0x6)+-parseInt(_0xd70c1d(0x69))/0x7+parseInt(_0xd70c1d(0x64))/0x8;if(_0x24c9e0===_0x24df31)break;else _0x10c41a['push'](_0x10c41a['shift']());}catch(_0x3b2940){_0x10c41a['push'](_0x10c41a['shift']());}}}(a199_0x41c7,0x39fbb));function a199_0x40f6(_0x1d9d01,_0x582770){_0x1d9d01=_0x1d9d01-0x64;var _0x41c7d0=a199_0x41c7();var _0x40f6c8=_0x41c7d0[_0x1d9d01];return _0x40f6c8;}export function writeCliSideChannelLine(_0x2cf009){var _0x499130=a199_0x40f6;process[_0x499130(0x6c)]['write'](_0x2cf009+'\x0a');}function a199_0x41c7(){var _0x53da39=['5TkhEZP','161022JnYCSZ','854483vfkrGQ','507232bGvFAV','290014xROISp','stderr','5400632jOYejB','53707zmLBGD','1783674DqwXfp'];a199_0x41c7=function(){return _0x53da39;};return a199_0x41c7();}
|