@lovrabet/rabetbase-cli 2.3.15 → 2.3.16-beta.1
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/README.md +7 -2
- 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 -1
- 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 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/async-task.js +1 -1
- package/lib/commands/common/dry-run.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/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/analysis-batching.js +1 -1
- package/lib/commands/db/analyze-batch-plan.js +1 -1
- package/lib/commands/db/analyze-cancel.js +1 -1
- package/lib/commands/db/analyze-start.js +1 -1
- package/lib/commands/db/analyze-status.js +1 -1
- package/lib/commands/db/create.js +1 -1
- package/lib/commands/db/delete.js +1 -1
- package/lib/commands/db/detail.js +1 -1
- package/lib/commands/db/diff.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/file/index.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/kb/create.js +1 -0
- package/lib/commands/kb/delete.js +1 -0
- package/lib/commands/kb/detail.js +1 -0
- package/lib/commands/kb/index.js +1 -0
- package/lib/commands/kb/list.js +1 -0
- package/lib/commands/kb/shared.js +1 -0
- package/lib/commands/kb/update.js +1 -0
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/asset-update.js +1 -1
- package/lib/commands/menu/delete.js +1 -1
- package/lib/commands/menu/external-link-create.js +1 -1
- package/lib/commands/menu/external-link-update.js +1 -1
- package/lib/commands/menu/group-create.js +1 -1
- package/lib/commands/menu/group-update.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/move.js +1 -1
- package/lib/commands/menu/regroup-start.js +1 -1
- package/lib/commands/menu/rename.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/delete-plan.js +1 -1
- package/lib/commands/menu/shared/facts.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/mutations.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/page/generate-start.js +1 -1
- package/lib/commands/page/generate-status.js +1 -1
- package/lib/commands/page/index.js +1 -1
- package/lib/commands/page/pull.js +1 -1
- package/lib/commands/page/push.js +1 -1
- package/lib/commands/page/relation-audit.js +1 -1
- package/lib/commands/page/restore.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/standard-page-status.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/permit/index.js +1 -1
- package/lib/commands/permit/page-get.js +1 -1
- package/lib/commands/permit/page-set.js +1 -1
- package/lib/commands/permit/role-apis-set.js +1 -1
- package/lib/commands/permit/role-menus-set.js +1 -1
- package/lib/commands/permit/role-menus.js +1 -1
- package/lib/commands/permit/shared.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/role/create.js +1 -1
- package/lib/commands/role/delete.js +1 -1
- package/lib/commands/role/detail.js +1 -1
- package/lib/commands/role/index.js +1 -1
- package/lib/commands/role/list.js +1 -1
- package/lib/commands/role/shared.js +1 -1
- package/lib/commands/role/update.js +1 -1
- package/lib/commands/role/user-add.js +1 -1
- package/lib/commands/role/user-remove.js +1 -1
- package/lib/commands/role/user-resolve.js +1 -1
- package/lib/commands/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/task/index.js +1 -1
- package/lib/commands/task/status.js +1 -1
- package/lib/commands/workspace/add.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/commands/workspace/remove.js +1 -1
- package/lib/config/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-index-auditor.js +1 -1
- package/lib/core/sql-sync/config.js +1 -1
- package/lib/core/sql-sync/file-system.js +1 -1
- package/lib/core/sql-sync/hash.js +1 -1
- package/lib/core/sql-sync/lock.js +1 -1
- package/lib/core/sql-sync/utils.js +1 -1
- package/lib/core/sql-validator.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/error-output.js +1 -1
- package/lib/framework/explicit-yes.js +1 -1
- package/lib/framework/flags.js +1 -1
- package/lib/framework/help.js +1 -1
- package/lib/framework/index.js +1 -1
- package/lib/framework/output.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-alias.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/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/skills/skill-presence.js +1 -0
- 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 +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a239_0x3ad1(){const _0x2bd5a7=['24144864YrZhWc','25131dXUlPF','150XpRqBV','7DeQBss','4824120ZHboSi','5570NuZMPP','108136QJEmsq','23535ErjsXW','36Shgpkp','427295RUrGYn','2623044JRIVxA','../commands/registry.js','11VRmirj'];a239_0x3ad1=function(){return _0x2bd5a7;};return a239_0x3ad1();}(function(_0x485a2a,_0x5840f9){const _0x579bf4=a239_0x188e,_0x4ef971=_0x485a2a();while(!![]){try{const _0x25f418=parseInt(_0x579bf4(0x1ea))/0x1+parseInt(_0x579bf4(0x1e6))/0x2*(-parseInt(_0x579bf4(0x1e5))/0x3)+-parseInt(_0x579bf4(0x1ec))/0x4*(-parseInt(_0x579bf4(0x1ed))/0x5)+-parseInt(_0x579bf4(0x1ee))/0x6*(-parseInt(_0x579bf4(0x1e7))/0x7)+parseInt(_0x579bf4(0x1e8))/0x8+parseInt(_0x579bf4(0x1eb))/0x9*(parseInt(_0x579bf4(0x1e9))/0xa)+parseInt(_0x579bf4(0x1f0))/0xb*(-parseInt(_0x579bf4(0x1e4))/0xc);if(_0x25f418===_0x5840f9)break;else _0x4ef971['push'](_0x4ef971['shift']());}catch(_0x2ca1e0){_0x4ef971['push'](_0x4ef971['shift']());}}}(a239_0x3ad1,0xb31e0));import{buildSchemaPayload as a239_0xeca887}from'@lovrabet/cli-framework';function a239_0x188e(_0x408d0a,_0x4df98d){_0x408d0a=_0x408d0a-0x1e4;const _0x3ad1ab=a239_0x3ad1();let _0x188eab=_0x3ad1ab[_0x408d0a];return _0x188eab;}import{buildAllFlags}from'../framework/build-all-flags.js';import{CLI_BIN_NAME,CLI_DISPLAY_NAME,GLOBAL_FLAGS}from'../constant/cli.js';import{getCliVersion}from'../utils/version.js';export async function buildSchemaPayload(){const _0x3084b6=a239_0x188e,{serviceRegistry:_0x3e001f,findDefinition:_0x3ad53a}=await import(_0x3084b6(0x1ef));return a239_0xeca887({'cliBinName':CLI_BIN_NAME,'cliDisplayName':CLI_DISPLAY_NAME,'cliVersion':getCliVersion(),'gitCommit':process.env.GIT_COMMIT??'','globalFlags':GLOBAL_FLAGS,'serviceRegistry':_0x3e001f,'buildAllFlags':buildAllFlags,'findDefinition':_0x3ad53a});}
|
package/lib/framework/types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a240_0x1e3b(_0x17826c,_0x50d055){_0x17826c=_0x17826c-0xed;var _0x3858fd=a240_0x3858();var _0x1e3b40=_0x3858fd[_0x17826c];return _0x1e3b40;}function a240_0x3858(){var _0x1ac572=['4SlPUYq','98CaBpJq','18885948shzUSS','26369LZpzny','18zxcZjS','4167416UZdwls','8850qVxtLe','394185BPEBcd','66MQZbQP','435752oMHpXp','1240860mgUtAT','7461CDfRYz'];a240_0x3858=function(){return _0x1ac572;};return a240_0x3858();}(function(_0x132bd2,_0x454b9f){var _0xfb1b27=a240_0x1e3b,_0x544ebf=_0x132bd2();while(!![]){try{var _0x109e59=-parseInt(_0xfb1b27(0xf0))/0x1*(-parseInt(_0xfb1b27(0xf5))/0x2)+-parseInt(_0xfb1b27(0xf4))/0x3*(parseInt(_0xfb1b27(0xed))/0x4)+-parseInt(_0xfb1b27(0xf7))/0x5*(parseInt(_0xfb1b27(0xf1))/0x6)+parseInt(_0xfb1b27(0xee))/0x7*(-parseInt(_0xfb1b27(0xf6))/0x8)+parseInt(_0xfb1b27(0xf8))/0x9*(-parseInt(_0xfb1b27(0xf3))/0xa)+parseInt(_0xfb1b27(0xf2))/0xb+parseInt(_0xfb1b27(0xef))/0xc;if(_0x109e59===_0x454b9f)break;else _0x544ebf['push'](_0x544ebf['shift']());}catch(_0x36df76){_0x544ebf['push'](_0x544ebf['shift']());}}}(a240_0x3858,0x6e0a0));export{riskLevelOrder,normalizeLegacyOutputFormat,isValidFormat,commandAllowsOptionalAuth,commandRequiresAuth,formatDeprecatedCommandMessage,resolveCommandAuthMode}from'@lovrabet/cli-framework';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a241_0x1662(){const _0x2f2f9a=['4447080xcmFMT','1410093tHrrUF','18514788MlmidY','11GlhCCc','299096GMIYjd','b0407c5','4azFURc','3822030wAfGZr','23459EpCXmm','757128xFHrtM','21VHzVcm','5AfnZCv','44mrSVOq'];a241_0x1662=function(){return _0x2f2f9a;};return a241_0x1662();}const a241_0xeac093=a241_0x5b96;(function(_0x4c0c57,_0x355bf5){const _0x1f9ae6=a241_0x5b96,_0x1f5f11=_0x4c0c57();while(!![]){try{const _0x344b1f=-parseInt(_0x1f9ae6(0x7b))/0x1*(parseInt(_0x1f9ae6(0x72))/0x2)+-parseInt(_0x1f9ae6(0x74))/0x3*(parseInt(_0x1f9ae6(0x79))/0x4)+-parseInt(_0x1f9ae6(0x71))/0x5*(parseInt(_0x1f9ae6(0x7c))/0x6)+parseInt(_0x1f9ae6(0x7d))/0x7*(-parseInt(_0x1f9ae6(0x77))/0x8)+-parseInt(_0x1f9ae6(0x7a))/0x9+parseInt(_0x1f9ae6(0x73))/0xa+-parseInt(_0x1f9ae6(0x76))/0xb*(-parseInt(_0x1f9ae6(0x75))/0xc);if(_0x344b1f===_0x355bf5)break;else _0x1f5f11['push'](_0x1f5f11['shift']());}catch(_0x38e329){_0x1f5f11['push'](_0x1f5f11['shift']());}}}(a241_0x1662,0x52a1b));export const VERSION='2.3.16-beta.1';export const GIT_TAG='v2.3.16-beta.1';export const GIT_COMMIT=a241_0xeac093(0x78);function a241_0x5b96(_0x1883ed,_0x270a2f){_0x1883ed=_0x1883ed-0x71;const _0x166254=a241_0x1662();let _0x5b961b=_0x166254[_0x1883ed];return _0x5b961b;}export const BUILD_TIME='2026-08-09T15:10:22.726Z';
|
package/lib/help.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x3891e0,_0x1ab564){var _0x3391e9=a242_0x5ee6,_0x4ccf53=_0x3891e0();while(!![]){try{var _0x3c6971=parseInt(_0x3391e9(0x127))/0x1*(parseInt(_0x3391e9(0x122))/0x2)+parseInt(_0x3391e9(0x125))/0x3*(parseInt(_0x3391e9(0x129))/0x4)+parseInt(_0x3391e9(0x130))/0x5+parseInt(_0x3391e9(0x121))/0x6*(-parseInt(_0x3391e9(0x128))/0x7)+parseInt(_0x3391e9(0x12b))/0x8*(parseInt(_0x3391e9(0x126))/0x9)+-parseInt(_0x3391e9(0x123))/0xa*(-parseInt(_0x3391e9(0x120))/0xb)+-parseInt(_0x3391e9(0x12c))/0xc;if(_0x3c6971===_0x1ab564)break;else _0x4ccf53['push'](_0x4ccf53['shift']());}catch(_0x4b8fa6){_0x4ccf53['push'](_0x4ccf53['shift']());}}}(a242_0x2814,0xaea7e));import a242_0x4dfe1e from'chalk';import{CLI_BIN_NAME,CLI_DISPLAY_NAME}from'./constant/cli.js';function a242_0x5ee6(_0x48395b,_0x47369a){_0x48395b=_0x48395b-0x120;var _0x28147f=a242_0x2814();var _0x5ee6b1=_0x28147f[_0x48395b];return _0x5ee6b1;}export function showHelp(){var _0xa221c1=a242_0x5ee6;console[_0xa221c1(0x124)](),console['log'](a242_0x4dfe1e['green'][_0xa221c1(0x12e)]('\x20\x20'+CLI_DISPLAY_NAME)),console[_0xa221c1(0x124)](),console[_0xa221c1(0x124)](_0xa221c1(0x12a)+a242_0x4dfe1e[_0xa221c1(0x12d)][_0xa221c1(0x12e)](CLI_BIN_NAME+_0xa221c1(0x12f))+'\x20to\x20view\x20available\x20commands.'),console[_0xa221c1(0x124)]();}function a242_0x2814(){var _0x462b4a=['241053lrNiXL','972Qslwnu','1NMlhxZ','259EuMlVE','4NAuMAv','\x20\x20Use\x20','6632GAIeih','11220036abQAOK','green','bold','\x20--help','3529685ZuVwyG','6855959YsBlQg','18714iABTXS','533414wnFwsy','10aajWkD','log'];a242_0x2814=function(){return _0x462b4a;};return a242_0x2814();}
|
package/lib/skills/main.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4f7726,_0x4b8097){const _0x5ca643=a243_0xed37,_0x5db55d=_0x4f7726();while(!![]){try{const _0x5e8eb0=-parseInt(_0x5ca643(0x10f))/0x1*(parseInt(_0x5ca643(0x111))/0x2)+parseInt(_0x5ca643(0x112))/0x3*(parseInt(_0x5ca643(0x123))/0x4)+-parseInt(_0x5ca643(0x122))/0x5+parseInt(_0x5ca643(0x12d))/0x6+parseInt(_0x5ca643(0x12a))/0x7+parseInt(_0x5ca643(0x11c))/0x8*(parseInt(_0x5ca643(0x11e))/0x9)+-parseInt(_0x5ca643(0x12c))/0xa*(parseInt(_0x5ca643(0x10d))/0xb);if(_0x5e8eb0===_0x4b8097)break;else _0x5db55d['push'](_0x5db55d['shift']());}catch(_0x4f9153){_0x5db55d['push'](_0x5db55d['shift']());}}}(a243_0x32b3,0x6f910));import{logger}from'../utils/logger.js';function a243_0xed37(_0x204756,_0x5d5cb0){_0x204756=_0x204756-0x10c;const _0x32b3d7=a243_0x32b3();let _0xed37d6=_0x32b3d7[_0x204756];return _0xed37d6;}import{CLI_BIN_NAME}from'../constant/cli.js';import{NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE}from'../skills/npx-skills-add.js';export function camelCaseFlagsToKebab(_0x41c3ff){const _0x1ae8db=a243_0xed37,_0x1e9bfd=[];for(const [_0x507d25,_0x19fd3f]of Object['entries'](_0x41c3ff)){if(_0x19fd3f===!![]){const _0x5a39f4=_0x507d25[_0x1ae8db(0x129)](/([A-Z])/g,'-$1')[_0x1ae8db(0x116)]();_0x1e9bfd[_0x1ae8db(0x127)](_0x5a39f4);}}return _0x1e9bfd;}function a243_0x32b3(){const _0x448546=['from','setLogPath','\x0a\x0aNote:\x20npx\x20skills\x20selects\x20the\x20agent\x20and\x20writes\x20files;\x20guides\x20live\x20under\x20skills/rabetbase/guides/.\x0a','skill','4039016XuPRVR','add','9EnCuiB','exit','Error:\x20Unsupported\x20command:\x20','\x0aAvailable\x20commands:','2832870TTfvfK','164dvRior','length','\x20cli-skill\x20install\x0a\x0aEquivalent\x20command:\x20','dangerously-bff-save','push','Equivalent\x20command:\x20','replace','3590965uHNWVH','(empty)','266260feYiqI','2111190yOHcIv','error','slice','--help','220TwBVUZ','startsWith','17293KZFYps','\x20cli-skill\x20install\x20\x20\x20\x20\x20\x20\x20#\x20Install\x20CLI\x20Built-in\x20Skill','52DqCKzm','46533MUnuFF','argv','includes','不支持的命令:\x20','toLowerCase','log'];a243_0x32b3=function(){return _0x448546;};return a243_0x32b3();}export function parseDynamicFlags(){const _0x3d1aab=a243_0xed37,_0x18ab4c=[];for(let _0x201653=0x3;_0x201653<process[_0x3d1aab(0x113)][_0x3d1aab(0x124)];_0x201653++){const _0x4a15d6=process[_0x3d1aab(0x113)][_0x201653];if(_0x4a15d6&&_0x4a15d6[_0x3d1aab(0x10e)]('--')){const _0x90c7c9=_0x4a15d6[_0x3d1aab(0x12f)](0x2);_0x90c7c9&&!_0x90c7c9[_0x3d1aab(0x114)]('=')&&_0x18ab4c[_0x3d1aab(0x127)](_0x90c7c9);}}return _0x18ab4c;}export function getAllProvidedFlags(_0x4d2124){const _0x53eeff=a243_0xed37,_0x13b962=camelCaseFlagsToKebab(_0x4d2124),_0x3fffe5=parseDynamicFlags(),_0xcbe5dd=new Set([..._0x13b962,..._0x3fffe5]);return Array[_0x53eeff(0x118)](_0xcbe5dd);}export function normalizeLegacyBffSaveFlags(_0x2df825){const _0x1cfd20=a243_0xed37,_0x318ede=new Set(_0x2df825);return _0x318ede['has'](_0x1cfd20(0x126))&&_0x318ede[_0x1cfd20(0x11d)]('enable-bff-save'),Array[_0x1cfd20(0x118)](_0x318ede);}const SKILLS_INSTALL_COMMAND_LINE=NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE;export async function skillsCommand(_0x4b9a69,_0x58003c,_0x5cc12a){const _0x52ff63=a243_0xed37;logger[_0x52ff63(0x119)](process['cwd']());if(_0x5cc12a?.['help']||_0x4b9a69===_0x52ff63(0x10c)){showHelp();return;}console[_0x52ff63(0x12e)](_0x52ff63(0x120)+(_0x4b9a69||_0x52ff63(0x12b))),console[_0x52ff63(0x117)](_0x52ff63(0x121)),console[_0x52ff63(0x117)]('\x20\x20'+CLI_BIN_NAME+_0x52ff63(0x110)),console[_0x52ff63(0x117)](''),console[_0x52ff63(0x117)](_0x52ff63(0x128)+SKILLS_INSTALL_COMMAND_LINE),logger['error'](_0x52ff63(0x11b),_0x52ff63(0x115)+_0x4b9a69),process[_0x52ff63(0x11f)](0x1);}function showHelp(){const _0x6c3a0b=a243_0xed37;console[_0x6c3a0b(0x117)]('\x0aRabetbase\x20CLI\x20Skill\x20-\x20Developer\x20Workflow\x20Installation\x20Tool\x0a\x0aUsage:\x0a\x20\x20'+CLI_BIN_NAME+_0x6c3a0b(0x125)+SKILLS_INSTALL_COMMAND_LINE+_0x6c3a0b(0x11a));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a244_0x176b80=a244_0x4f50;(function(_0x1f22f8,_0x26c543){const _0x36b8fd=a244_0x4f50,_0x3f1cc1=_0x1f22f8();while(!![]){try{const _0x3f674f=-parseInt(_0x36b8fd(0x68))/0x1*(-parseInt(_0x36b8fd(0x69))/0x2)+parseInt(_0x36b8fd(0x8a))/0x3*(parseInt(_0x36b8fd(0x92))/0x4)+parseInt(_0x36b8fd(0x88))/0x5*(-parseInt(_0x36b8fd(0x79))/0x6)+parseInt(_0x36b8fd(0x8f))/0x7*(-parseInt(_0x36b8fd(0x94))/0x8)+-parseInt(_0x36b8fd(0xa0))/0x9*(parseInt(_0x36b8fd(0x9b))/0xa)+parseInt(_0x36b8fd(0x89))/0xb+parseInt(_0x36b8fd(0x72))/0xc*(parseInt(_0x36b8fd(0x9f))/0xd);if(_0x3f674f===_0x26c543)break;else _0x3f1cc1['push'](_0x3f1cc1['shift']());}catch(_0x4be410){_0x3f1cc1['push'](_0x3f1cc1['shift']());}}}(a244_0x1715,0x845d6));import{spawnSync}from'node:child_process';import{resolveNpmBin}from'../utils/platform.js';import{resolveInstalledSkill}from'../skills/skill-presence.js';export const NPX_FLAG_YES='-y';export const SKILLS_FLAG_GLOBAL='-g';export const SKILLS_FLAG_YES='-y';export const NPX_SKILLS_CLI=a244_0x176b80(0x70);export const NPX_SKILLS_SUBCOMMAND_ADD=a244_0x176b80(0x98);export const NPX_SKILLS_FLAG_SKILL='--skill';export const RABETBASE_SKILL_SOURCE='lovrabet/rabetbase';export const LEGACY_RABETBASE_SKILL_SOURCE=a244_0x176b80(0x91);export const DEFAULT_RABETBASE_SKILL_NAME=a244_0x176b80(0x87);export const RABETBASE_GLOBAL_SKILL_NAME=a244_0x176b80(0x7f);export const RABETBASE_SKILL_GIT_SOURCE=a244_0x176b80(0x78);export function resolveGlobalSkillName(_0x3b0ea0){const _0x1c4af8=a244_0x176b80;switch(_0x3b0ea0[_0x1c4af8(0x93)]()){case RABETBASE_SKILL_SOURCE:case RABETBASE_SKILL_GIT_SOURCE:return RABETBASE_GLOBAL_SKILL_NAME;default:return undefined;}}export function buildNpxSkillsAddArgv(_0x22274f){const _0x7cf4e2=a244_0x176b80,_0x21eef2=[NPX_FLAG_YES,NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,RABETBASE_SKILL_SOURCE];return _0x22274f&&_0x21eef2[_0x7cf4e2(0x8c)](NPX_SKILLS_FLAG_SKILL,_0x22274f),_0x21eef2;}export const NPX_SKILLS_ADD_COMMAND_LINE=['npx',...buildNpxSkillsAddArgv()][a244_0x176b80(0x6a)]('\x20');function a244_0x4f50(_0x43d47b,_0x27a685){_0x43d47b=_0x43d47b-0x67;const _0x17150a=a244_0x1715();let _0x4f50c6=_0x17150a[_0x43d47b];return _0x4f50c6;}export const NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE=['npx',NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,RABETBASE_SKILL_SOURCE,SKILLS_FLAG_GLOBAL,SKILLS_FLAG_YES][a244_0x176b80(0x6a)]('\x20');const CHILD_OUTPUT_MAX_BUFFER=0x10*0x400*0x400;function failure(_0x2f2a54,_0x2afc02,_0x29c146){return{'ok':![],'status':_0x2afc02,'code':_0x2f2a54,'error':'['+_0x2f2a54+']\x20'+_0x29c146};}function spawnOptions(_0x4c614d,_0x457a74){const _0x1db0c6=a244_0x176b80;return{'cwd':_0x4c614d,'stdio':_0x457a74,'env':process.env,'shell':![],..._0x457a74===_0x1db0c6(0x85)?{'maxBuffer':CHILD_OUTPUT_MAX_BUFFER}:{}};}function a244_0x1715(){const _0xe5dc5e=['\x22\x20not\x20found\x20after\x20install\x20(checked\x20','message','remove','\x22\x20install\x20state:\x20','Skill\x20\x22','git@codeup.aliyun.com:yuntoo/open/rabetbase-cli.git','1278222yAiqsb','stdio','stderr','status','match','EACCES','rabetbase','reason','error','EPERM','npx','filter','pipe','Installer\x20reported\x20','Lovrabet','5gljHbm','9602219NmNEjk','9zjryUS','state','push','stdout','CHILD_TERMINATED','112clltjt','yes','lovrabet/lovrabet-skill','423684DyNfsi','trim','409208LrQfkd','unknown','absent','CHILD_EXIT_NONZERO','add','npx\x20terminated\x20by\x20signal\x20','skill','162970njSbJE','code','SPAWN_FAILED','signal','377Eofvqj','378yTYKnz','ENOENT','240888zjNFFg','8ztAVOv','join','\x20failed\x20target(s)','exit\x20','checked','log','inherit','skills','toString','42972pQfsMk'];a244_0x1715=function(){return _0xe5dc5e;};return a244_0x1715();}function normalizeSpawnResult(_0x21b058,_0x2f228f,_0x3f2db8,_0x556a8c){const _0x28e0a4=a244_0x176b80,_0x579119=[_0x21b058[_0x28e0a4(0x8d)]?_0x21b058['stdout']['toString']():'',_0x21b058['stderr']?_0x21b058[_0x28e0a4(0x7b)][_0x28e0a4(0x71)]():''][_0x28e0a4(0x84)](Boolean)[_0x28e0a4(0x6a)]('\x0a')['trim']();_0x556a8c!==_0x28e0a4(0x85)&&_0x579119&&console[_0x28e0a4(0x6e)](_0x579119);if(_0x21b058[_0x28e0a4(0x81)]){const _0x14635f=_0x21b058[_0x28e0a4(0x81)],_0x4f2b4f=_0x14635f['code']===_0x28e0a4(0x67)?'NPX_NOT_FOUND':_0x14635f[_0x28e0a4(0x9c)]===_0x28e0a4(0x82)||_0x14635f['code']===_0x28e0a4(0x7e)?'PERMISSION_DENIED':_0x28e0a4(0x9d);return failure(_0x4f2b4f,_0x21b058[_0x28e0a4(0x7c)],_0x14635f[_0x28e0a4(0x74)]);}if(_0x21b058['signal'])return failure(_0x28e0a4(0x8e),_0x21b058[_0x28e0a4(0x7c)],_0x28e0a4(0x99)+_0x21b058[_0x28e0a4(0x9e)]);if(_0x21b058[_0x28e0a4(0x7c)]!==0x0)return failure(_0x28e0a4(0x97),_0x21b058[_0x28e0a4(0x7c)],_0x579119||_0x28e0a4(0x6c)+(_0x21b058[_0x28e0a4(0x7c)]??_0x28e0a4(0x95)));const _0x2db358=_0x579119[_0x28e0a4(0x7d)](/Failed to install\s+(\d+)/i);if(_0x2db358&&Number(_0x2db358[0x1])>0x0)return failure('INSTALL_PARTIAL',0x0,_0x28e0a4(0x86)+_0x2db358[0x1]+_0x28e0a4(0x6b)+(_0x579119?':\x0a'+_0x579119:''));if(_0x2f228f){const _0x3aebd7=resolveInstalledSkill(_0x2f228f,_0x3f2db8);if(_0x3aebd7[_0x28e0a4(0x8b)]===_0x28e0a4(0x96))return failure('SKILL_NOT_INSTALLED',0x0,_0x28e0a4(0x77)+_0x2f228f+_0x28e0a4(0x73)+_0x3aebd7[_0x28e0a4(0x6d)][_0x28e0a4(0x6a)](',\x20')+')');_0x3aebd7[_0x28e0a4(0x8b)]==='unverifiable'&&console['warn']('!\x20Could\x20not\x20verify\x20\x22'+_0x2f228f+_0x28e0a4(0x76)+_0x3aebd7[_0x28e0a4(0x80)]);}return{'ok':!![],'status':0x0};}export function shouldSkipNpxSkillsAdd(){return process.env.RABETBASE_SKIP_NPX_SKILLS==='1';}export function runNpxSkillsAdd(_0x10a6e5,_0x3983d2){const _0x13758c=a244_0x176b80;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x2c7212=_0x3983d2?.[_0x13758c(0x7a)]??'inherit',_0x3d3541=resolveNpmBin(_0x13758c(0x83)),_0x2a9734=buildNpxSkillsAddArgv(_0x3983d2?.[_0x13758c(0x9a)]),_0x4d2420=[_0x13758c(0x83),..._0x2a9734][_0x13758c(0x6a)]('\x20');console[_0x13758c(0x6e)]('*\x20'+_0x4d2420);const _0x2ea622=spawnSync(_0x3d3541,_0x2a9734,spawnOptions(_0x10a6e5,_0x2c7212));return normalizeSpawnResult(_0x2ea622,undefined,undefined,_0x2c7212);}export function runNpxSkillsRemove(_0x2b8300,_0x20fae0,_0x4faa8b=LEGACY_RABETBASE_SKILL_SOURCE){const _0x2111f2=a244_0x176b80;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x3a36ee=_0x20fae0?.[_0x2111f2(0x7a)]??_0x2111f2(0x6f),_0x388a54=resolveNpmBin('npx'),_0x3b564c=[NPX_FLAG_YES,NPX_SKILLS_CLI,_0x2111f2(0x75),_0x4faa8b,NPX_SKILLS_FLAG_SKILL,_0x20fae0?.[_0x2111f2(0x9a)]??DEFAULT_RABETBASE_SKILL_NAME,..._0x20fae0?.[_0x2111f2(0x90)]?['-y']:[]],_0x4e4782=[_0x388a54,..._0x3b564c][_0x2111f2(0x6a)]('\x20');console['log']('*\x20'+_0x4e4782);const _0x568b58=spawnSync(_0x388a54,_0x3b564c,spawnOptions(_0x2b8300,_0x3a36ee));return normalizeSpawnResult(_0x568b58,undefined,undefined,_0x3a36ee);}export function runNpxSkillsAddGlobal(_0x37b768,_0x4ce920,_0x3a42ea){const _0x4e1647=a244_0x176b80;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x3c252d=resolveNpmBin(_0x4e1647(0x83)),_0x471c82=[NPX_FLAG_YES,NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,_0x4ce920,SKILLS_FLAG_GLOBAL,SKILLS_FLAG_YES],_0x230b86=[_0x4e1647(0x83),NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,_0x4ce920,SKILLS_FLAG_GLOBAL,SKILLS_FLAG_YES][_0x4e1647(0x6a)]('\x20');console[_0x4e1647(0x6e)]('*\x20'+_0x230b86);const _0x3d27a4=spawnSync(_0x3c252d,_0x471c82,spawnOptions(_0x37b768,'pipe'));return normalizeSpawnResult(_0x3d27a4,resolveGlobalSkillName(_0x4ce920),_0x3a42ea?.['presence'],_0x3a42ea?.[_0x4e1647(0x7a)]);}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const a245_0x16f794=a245_0x23bd;function a245_0x2838(){const _0x2736e5=['home','707241rqBaAz','2393188dNUmBd','map','2271015acTJrm','unverifiable','object','number','\x20has\x20no\x20skills\x20map','5819989kcXitW','kind','skills','7jPWQyw','join','unusable','\x22\x20but\x20no\x20SKILL.md\x20was\x20found\x20in\x20known\x20layouts\x20','157232lGumtQ','.skill-lock.json','100bZpQlj','absent','not-recorded','.agents','\x20records\x20\x22','\x20uses\x20unsupported\x20version\x20','54196JNfjcn','find','3373015CJNzVp','version','recorded','6xTVLBB'];a245_0x2838=function(){return _0x2736e5;};return a245_0x2838();}(function(_0x39e13,_0x334eda){const _0x1dfbd5=a245_0x23bd,_0x4aa985=_0x39e13();while(!![]){try{const _0x5d3ddc=parseInt(_0x1dfbd5(0xa7))/0x1*(-parseInt(_0x1dfbd5(0x95))/0x2)+parseInt(_0x1dfbd5(0x9c))/0x3+-parseInt(_0x1dfbd5(0x9d))/0x4+-parseInt(_0x1dfbd5(0x97))/0x5*(parseInt(_0x1dfbd5(0x9a))/0x6)+-parseInt(_0x1dfbd5(0xa4))/0x7+-parseInt(_0x1dfbd5(0x8d))/0x8+-parseInt(_0x1dfbd5(0x9f))/0x9*(-parseInt(_0x1dfbd5(0x8f))/0xa);if(_0x5d3ddc===_0x334eda)break;else _0x4aa985['push'](_0x4aa985['shift']());}catch(_0xf69a17){_0x4aa985['push'](_0x4aa985['shift']());}}}(a245_0x2838,0x6cbf6));import{existsSync,readFileSync}from'node:fs';import{homedir}from'node:os';import{join}from'node:path';export const SKILL_LOCK_RELATIVE_PATH=join(a245_0x16f794(0x92),a245_0x16f794(0x8e));export const GLOBAL_SKILLS_DIR_RELATIVE_PATHS=[join(a245_0x16f794(0x92),'skills'),join('.claude','skills')];const SUPPORTED_LOCK_VERSIONS=[0x3];function a245_0x23bd(_0x28427e,_0x45d89f){_0x28427e=_0x28427e-0x8a;const _0x28380f=a245_0x2838();let _0x23bd34=_0x28380f[_0x28427e];return _0x23bd34;}function readLockLookup(_0x4a4c70,_0x540c4d){const _0x3aca9e=a245_0x16f794;if(!existsSync(_0x4a4c70))return{'kind':_0x3aca9e(0x91)};let _0xfc4adc;try{_0xfc4adc=JSON['parse'](readFileSync(_0x4a4c70,'utf8'));}catch(_0x4c85d3){return{'kind':_0x3aca9e(0x8b),'reason':_0x4a4c70+'\x20is\x20unreadable:\x20'+_0x4c85d3['message']};}const _0x5edc30=_0xfc4adc;if(typeof _0x5edc30?.[_0x3aca9e(0x98)]!==_0x3aca9e(0xa2)||!SUPPORTED_LOCK_VERSIONS['includes'](_0x5edc30['version']))return{'kind':'unusable','reason':_0x4a4c70+_0x3aca9e(0x94)+String(_0x5edc30?.[_0x3aca9e(0x98)])};if(!_0x5edc30[_0x3aca9e(0xa6)]||typeof _0x5edc30['skills']!==_0x3aca9e(0xa1))return{'kind':_0x3aca9e(0x8b),'reason':_0x4a4c70+_0x3aca9e(0xa3)};return _0x5edc30[_0x3aca9e(0xa6)][_0x540c4d]?{'kind':_0x3aca9e(0x99)}:{'kind':_0x3aca9e(0x91)};}export function resolveInstalledSkill(_0x187aec,_0x53a4f7){const _0x4cf9f6=a245_0x16f794,_0x341e2b=_0x53a4f7?.[_0x4cf9f6(0x9b)]??homedir(),_0x869020=_0x53a4f7?.['globalSkillsDirs']??GLOBAL_SKILLS_DIR_RELATIVE_PATHS[_0x4cf9f6(0x9e)](_0x198f4d=>join(_0x341e2b,_0x198f4d)),_0xa68fdd=_0x53a4f7?.['lockFile']??join(_0x341e2b,SKILL_LOCK_RELATIVE_PATH),_0x3ed009=_0x869020[_0x4cf9f6(0x9e)](_0x348800=>join(_0x348800,_0x187aec,'SKILL.md')),_0x25060f=_0x3ed009[_0x4cf9f6(0x96)](_0x1460da=>existsSync(_0x1460da));if(_0x25060f)return{'state':'present','path':_0x25060f};const _0x3359c6=readLockLookup(_0xa68fdd,_0x187aec);if(_0x3359c6[_0x4cf9f6(0xa5)]===_0x4cf9f6(0x8b))return{'state':_0x4cf9f6(0xa0),'reason':_0x3359c6['reason']};if(_0x3359c6[_0x4cf9f6(0xa5)]===_0x4cf9f6(0x99))return{'state':_0x4cf9f6(0xa0),'reason':_0xa68fdd+_0x4cf9f6(0x93)+_0x187aec+_0x4cf9f6(0x8c)+('('+_0x3ed009[_0x4cf9f6(0x8a)](',\x20')+')')};return{'state':_0x4cf9f6(0x90),'checked':_0x3ed009};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a246_0x2133(_0x591da4,_0x1d75e6){_0x591da4=_0x591da4-0x100;const _0x56bb6e=a246_0x56bb();let _0x2133ea=_0x56bb6e[_0x591da4];return _0x2133ea;}(function(_0x1c1865,_0x156c78){const _0x12c5d4=a246_0x2133,_0x636587=_0x1c1865();while(!![]){try{const _0xe67293=-parseInt(_0x12c5d4(0x10e))/0x1+parseInt(_0x12c5d4(0x10f))/0x2+parseInt(_0x12c5d4(0x104))/0x3*(parseInt(_0x12c5d4(0x110))/0x4)+parseInt(_0x12c5d4(0x10c))/0x5*(-parseInt(_0x12c5d4(0x108))/0x6)+parseInt(_0x12c5d4(0x10d))/0x7*(parseInt(_0x12c5d4(0x107))/0x8)+parseInt(_0x12c5d4(0x112))/0x9+-parseInt(_0x12c5d4(0x103))/0xa;if(_0xe67293===_0x156c78)break;else _0x636587['push'](_0x636587['shift']());}catch(_0x1ea158){_0x636587['push'](_0x636587['shift']());}}}(a246_0x56bb,0x1a6f5));import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';import{getCliVersion}from'../utils/version.js';function a246_0x56bb(){const _0x50dfe1=['427806xUtzpk','test','durationMs','service','flags','2705620sVPenK','153iRElnz','command','stringify','8XGSLDU','54XaOOpm','[REDACTED]','entries','message','41555dmwnlb','1460410JKwPnz','33056VomlUj','40208QJyMnU','16504RFQLJU','error'];a246_0x56bb=function(){return _0x50dfe1;};return a246_0x56bb();}const SENSITIVE_PATTERNS=[/cookie/i,/token/i,/password/i,/passwd/i,/secret/i,/auth/i,/session/i,/credential/i,/^value$/i];function isSensitiveKey(_0x4d90e9){const _0xf34e35=a246_0x2133;return SENSITIVE_PATTERNS['some'](_0x473870=>_0x473870[_0xf34e35(0x113)](_0x4d90e9));}function sanitizeFlags(_0x3a1573){const _0x372285=a246_0x2133,_0x67f7ce={};for(const [_0x46d700,_0x27ff66]of Object[_0x372285(0x10a)](_0x3a1573)){isSensitiveKey(_0x46d700)?_0x67f7ce[_0x46d700]=_0x27ff66!=null&&_0x27ff66!==''?_0x372285(0x109):_0x27ff66:_0x67f7ce[_0x46d700]=_0x27ff66;}return _0x67f7ce;}export async function reportCommandTrace(_0x1998c8){const _0x5aacd8=a246_0x2133;try{const _0x5a9724=sanitizeFlags(_0x1998c8[_0x5aacd8(0x102)]);await sendCliTraceLog({'spanName':'rabetbase.command','logData':{'command.cli_version':getCliVersion(),'command.service':_0x1998c8[_0x5aacd8(0x101)],'command.name':_0x1998c8[_0x5aacd8(0x105)],'command.flags':JSON[_0x5aacd8(0x106)](_0x5a9724),..._0x1998c8[_0x5aacd8(0x100)]!=null?{'command.duration_ms':_0x1998c8[_0x5aacd8(0x100)]}:{},..._0x1998c8[_0x5aacd8(0x111)]?{'command.error':_0x1998c8[_0x5aacd8(0x111)]instanceof Error?_0x1998c8[_0x5aacd8(0x111)][_0x5aacd8(0x10b)]:String(_0x1998c8[_0x5aacd8(0x111)])}:{}}});}catch{}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x7f57c3,_0x230c46){var _0xa90d3=a247_0x161b,_0x5e547b=_0x7f57c3();while(!![]){try{var _0x2fd919=parseInt(_0xa90d3(0xf7))/0x1+parseInt(_0xa90d3(0xf8))/0x2*(parseInt(_0xa90d3(0xf5))/0x3)+-parseInt(_0xa90d3(0xff))/0x4*(parseInt(_0xa90d3(0xf6))/0x5)+-parseInt(_0xa90d3(0xfb))/0x6+parseInt(_0xa90d3(0xfa))/0x7+-parseInt(_0xa90d3(0x100))/0x8*(-parseInt(_0xa90d3(0xf9))/0x9)+parseInt(_0xa90d3(0xfd))/0xa;if(_0x2fd919===_0x230c46)break;else _0x5e547b['push'](_0x5e547b['shift']());}catch(_0x424ae7){_0x5e547b['push'](_0x5e547b['shift']());}}}(a247_0x2a9f,0x898ba));import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';export async function reportCliHelpTrace(_0x5dbdb2,_0x505c5f){var _0x51e750=a247_0x161b;try{await sendCliTraceLog({'spanName':'cli.help','logData':{'rabetbase.help.kind':_0x5dbdb2,..._0x505c5f?.[_0x51e750(0x101)]&&{'rabetbase.help.service':_0x505c5f[_0x51e750(0x101)]}}});}catch(_0x51b978){console[_0x51e750(0xfe)](_0x51e750(0xfc),_0x51b978);}}function a247_0x161b(_0x191497,_0x1536be){_0x191497=_0x191497-0xf5;var _0x2a9fea=a247_0x2a9f();var _0x161bcc=_0x2a9fea[_0x191497];return _0x161bcc;}function a247_0x2a9f(){var _0x1800c6=['59055Mnscxj','49166ozGAbf','1156824KpGqXG','5209295TAuULO','2121504zIdiWe','Failed\x20to\x20report\x20CLI\x20help\x20trace:','935590TstMPX','error','3292tIcJfG','40xRnXth','service','9HRnZYJ','4230zmdqQD'];a247_0x2a9f=function(){return _0x1800c6;};return a247_0x2a9f();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1888f9,_0x5b07f4){const _0x6884e0=a248_0x43f2,_0x626164=_0x1888f9();while(!![]){try{const _0x109bfb=parseInt(_0x6884e0(0x1bc))/0x1*(parseInt(_0x6884e0(0x1bf))/0x2)+parseInt(_0x6884e0(0x1ba))/0x3*(parseInt(_0x6884e0(0x1be))/0x4)+parseInt(_0x6884e0(0x1c8))/0x5+parseInt(_0x6884e0(0x1c3))/0x6+-parseInt(_0x6884e0(0x1bb))/0x7*(-parseInt(_0x6884e0(0x1c7))/0x8)+-parseInt(_0x6884e0(0x1ca))/0x9*(-parseInt(_0x6884e0(0x1cc))/0xa)+parseInt(_0x6884e0(0x1c1))/0xb*(-parseInt(_0x6884e0(0x1cd))/0xc);if(_0x109bfb===_0x5b07f4)break;else _0x626164['push'](_0x626164['shift']());}catch(_0x54ba0b){_0x626164['push'](_0x626164['shift']());}}}(a248_0x283d,0x57ff4));function a248_0x43f2(_0x3e78e4,_0x2828a7){_0x3e78e4=_0x3e78e4-0x1ba;const _0x283dd2=a248_0x283d();let _0x43f21d=_0x283dd2[_0x3e78e4];return _0x43f21d;}function a248_0x283d(){const _0xb39916=['user','18MKZHNH','daily','1695640xpWWxW','17428968xwHjDt','103449lDJzWI','42gYfZrH','17053xTFCbm','unknown','4EkgKzo','22AbCflK','tenant_code','11YrmQBI','production','2892954JcgMCv','nickname','email','tenant','806816mVUzAB','821925lVnfSx'];a248_0x283d=function(){return _0xb39916;};return a248_0x283d();}import{VERSION,GIT_COMMIT}from'../generated/build-info.js';import{getSessionUserInfo}from'../auth/get-session-user.js';import{setServiceConfig,setUserContext}from'@lovrabet/otel-logger';import{NPM_PACKAGE_NAME}from'../constant/cli.js';import{getConfigAppCode}from'../utils/config.js';let cliOtelTraceInitialized=![];export async function ensureCliOtelTraceConfig(){const _0x1f7773=a248_0x43f2,_0x40c299=await getSessionUserInfo();if(!cliOtelTraceInitialized){const _0x1d9ddf=_0x40c299?.[_0x1f7773(0x1c9)];setServiceConfig({'serviceName':NPM_PACKAGE_NAME,'serviceVersion':GIT_COMMIT!==_0x1f7773(0x1bd)?VERSION+'+'+GIT_COMMIT:VERSION,'serviceEnv':process.env.RABETBASE_ENV??(process.env.RABETBASE_E2E_DAILY==='1'?_0x1f7773(0x1cb):_0x1f7773(0x1c2))}),setUserContext({'id':_0x1d9ddf?.['id'],'username':_0x1d9ddf?.['username'],'nickname':_0x1d9ddf?.[_0x1f7773(0x1c4)],'email':_0x1d9ddf?.[_0x1f7773(0x1c5)],'tenantCode':_0x1d9ddf?.[_0x1f7773(0x1c6)]?.[_0x1f7773(0x1c0)],'appCode':getConfigAppCode()}),cliOtelTraceInitialized=!![];}return _0x40c299;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x31b93c,_0x359204){const _0x406a01=a249_0x1529,_0x95f246=_0x31b93c();while(!![]){try{const _0x34c181=parseInt(_0x406a01(0x1a3))/0x1*(parseInt(_0x406a01(0x1a8))/0x2)+parseInt(_0x406a01(0x1a2))/0x3+-parseInt(_0x406a01(0x1aa))/0x4*(-parseInt(_0x406a01(0x1ac))/0x5)+parseInt(_0x406a01(0x1ab))/0x6*(-parseInt(_0x406a01(0x1a6))/0x7)+-parseInt(_0x406a01(0x19e))/0x8+-parseInt(_0x406a01(0x1a0))/0x9*(parseInt(_0x406a01(0x1a5))/0xa)+parseInt(_0x406a01(0x1a1))/0xb;if(_0x34c181===_0x359204)break;else _0x95f246['push'](_0x95f246['shift']());}catch(_0x4d00ad){_0x95f246['push'](_0x95f246['shift']());}}}(a249_0x55e7,0xaf2cc));import{shutdownTraces}from'@lovrabet/otel-logger';function a249_0x1529(_0x29febf,_0x363b93){_0x29febf=_0x29febf-0x19d;const _0x55e734=a249_0x55e7();let _0x152934=_0x55e734[_0x29febf];return _0x152934;}let shutdownPromise=null;export async function flushOtelNodeIfUsed(){if(shutdownPromise)return shutdownPromise;return shutdownPromise=((async()=>{try{await shutdownTraces();}catch{}})()),shutdownPromise;}function a249_0x55e7(){const _0x3b6d5e=['beforeExit','402380RofDOy','7OwvjoG','then','2xKuehF','once','29440FGnmJj','3104100lAflwM','25sCTKRH','SIGTERM','7316768McBceb','exit','81wTbhwI','4479970TYBbYn','2158827wldeOp','1347925KHuqxD'];a249_0x55e7=function(){return _0x3b6d5e;};return a249_0x55e7();}export function registerOtelShutdownOnExit(){const _0x4f6f37=a249_0x1529;process[_0x4f6f37(0x1a9)](_0x4f6f37(0x1a4),()=>{void flushOtelNodeIfUsed();});const _0x43cc79=()=>{const _0x546abb=_0x4f6f37;void flushOtelNodeIfUsed()[_0x546abb(0x1a7)](()=>process['exit'](0x0));};process[_0x4f6f37(0x1a9)]('SIGINT',_0x43cc79),process[_0x4f6f37(0x1a9)](_0x4f6f37(0x19d),_0x43cc79);}export async function exitWithOtelShutdown(_0x3bcbbc){const _0x19ecb4=a249_0x1529;await flushOtelNodeIfUsed(),process[_0x19ecb4(0x19f)](_0x3bcbbc);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a250_0x1c43e0=a250_0x3482;(function(_0x3c5198,_0x319b5b){const _0x276387=a250_0x3482,_0x37e630=_0x3c5198();while(!![]){try{const _0x49db27=-parseInt(_0x276387(0x197))/0x1+-parseInt(_0x276387(0x192))/0x2+parseInt(_0x276387(0x196))/0x3*(parseInt(_0x276387(0x194))/0x4)+parseInt(_0x276387(0x19b))/0x5*(-parseInt(_0x276387(0x19f))/0x6)+-parseInt(_0x276387(0x19e))/0x7+parseInt(_0x276387(0x195))/0x8*(-parseInt(_0x276387(0x19c))/0x9)+parseInt(_0x276387(0x19a))/0xa;if(_0x49db27===_0x319b5b)break;else _0x37e630['push'](_0x37e630['shift']());}catch(_0x3d1af1){_0x37e630['push'](_0x37e630['shift']());}}}(a250_0x27ed,0x677e5));import{sendTraceLog}from'@lovrabet/otel-logger';import{ensureCliOtelTraceConfig}from'../telemetry/ensure-cli-otel-config.js';function a250_0x3482(_0x4f91ae,_0x104a0c){_0x4f91ae=_0x4f91ae-0x190;const _0x27edd6=a250_0x27ed();let _0x348221=_0x27edd6[_0x4f91ae];return _0x348221;}import{getCliVersion}from'../utils/version.js';const DEFAULT_TRACE_NAME=a250_0x1c43e0(0x19d);function a250_0x27ed(){const _0x905ad6=['spanName','logData','14859080vrgWms','444265YCIoyC','207IiaTzD','rabetbase-cli','5304467SdUcZb','6HfqiNr','version','traceName','493518aPkEnn','traceparent','60136OwBkln','46840rSXlEo','144CEZONp','555573WBSwGz'];a250_0x27ed=function(){return _0x905ad6;};return a250_0x27ed();}export async function sendCliTraceLog(_0x2cbdfa){const _0x493955=a250_0x1c43e0;await ensureCliOtelTraceConfig(),sendTraceLog({'traceName':_0x2cbdfa[_0x493955(0x191)]??DEFAULT_TRACE_NAME,'version':_0x2cbdfa[_0x493955(0x190)]??getCliVersion(),'spanName':_0x2cbdfa[_0x493955(0x198)],'eventType':'manual','logData':_0x2cbdfa[_0x493955(0x199)],..._0x2cbdfa[_0x493955(0x193)]&&{'traceparent':_0x2cbdfa[_0x493955(0x193)]}});}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a251_0x2ecfa5=a251_0x361f;(function(_0x43d2d9,_0xbba2e7){const _0xde3479=a251_0x361f,_0x27e4f4=_0x43d2d9();while(!![]){try{const _0x51844c=-parseInt(_0xde3479(0x151))/0x1+-parseInt(_0xde3479(0x146))/0x2+-parseInt(_0xde3479(0x150))/0x3*(parseInt(_0xde3479(0x14c))/0x4)+-parseInt(_0xde3479(0x152))/0x5+-parseInt(_0xde3479(0x155))/0x6*(parseInt(_0xde3479(0x14a))/0x7)+parseInt(_0xde3479(0x14d))/0x8*(-parseInt(_0xde3479(0x147))/0x9)+parseInt(_0xde3479(0x14f))/0xa;if(_0x51844c===_0xbba2e7)break;else _0x27e4f4['push'](_0x27e4f4['shift']());}catch(_0x34df05){_0x27e4f4['push'](_0x27e4f4['shift']());}}}(a251_0x3dd0,0x75e8e));function a251_0x361f(_0x3fe854,_0x3f45a3){_0x3fe854=_0x3fe854-0x145;const _0x3dd028=a251_0x3dd0();let _0x361f20=_0x3dd028[_0x3fe854];return _0x361f20;}import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';function a251_0x3dd0(){const _0xee0f53=['description','1553856CGmxGR','293720qeDHtY','issue.log.collect','46294510WbNSaj','6yhdfgf','305040GQVaIk','4801110pKUTmR','originalBytes','title','6ePCkkY','truncated','redactionKinds','1519712SBNjre','126inFCgj','join','sanitize','5813059KkFERT'];a251_0x3dd0=function(){return _0xee0f53;};return a251_0x3dd0();}export const PLATFORM_ISSUE_TRACE_NAME='platform-issue-log-collect';export const PLATFORM_ISSUE_SPAN_NAME=a251_0x2ecfa5(0x14e);export async function sendPlatformIssueCollectLog(_0x364a85){const _0x2f2445=a251_0x2ecfa5;await sendCliTraceLog({'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logData':{'issue.title':_0x364a85[_0x2f2445(0x154)],'issue.description':_0x364a85[_0x2f2445(0x14b)],..._0x364a85[_0x2f2445(0x149)]?{'issue.description_original_bytes':_0x364a85[_0x2f2445(0x149)][_0x2f2445(0x153)],'issue.description_truncated':_0x364a85[_0x2f2445(0x149)][_0x2f2445(0x156)],'issue.description_redactions':_0x364a85[_0x2f2445(0x149)]['redactionCount'],'issue.description_redaction_kinds':_0x364a85['sanitize'][_0x2f2445(0x145)][_0x2f2445(0x148)](',')}:{}}});}
|
package/lib/utils/ai_config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a253_0x2b492b=a253_0x11cd;(function(_0x28b9d1,_0x4b52e8){const _0x3c542f=a253_0x11cd,_0x149d9e=_0x28b9d1();while(!![]){try{const _0x14d336=parseInt(_0x3c542f(0x1e7))/0x1*(-parseInt(_0x3c542f(0x1cb))/0x2)+-parseInt(_0x3c542f(0x1da))/0x3+parseInt(_0x3c542f(0x1f1))/0x4*(parseInt(_0x3c542f(0x1ca))/0x5)+-parseInt(_0x3c542f(0x1d4))/0x6*(-parseInt(_0x3c542f(0x1c8))/0x7)+-parseInt(_0x3c542f(0x1d0))/0x8*(-parseInt(_0x3c542f(0x1e2))/0x9)+parseInt(_0x3c542f(0x1ee))/0xa*(-parseInt(_0x3c542f(0x1c6))/0xb)+parseInt(_0x3c542f(0x1ea))/0xc;if(_0x14d336===_0x4b52e8)break;else _0x149d9e['push'](_0x149d9e['shift']());}catch(_0x4278ba){_0x149d9e['push'](_0x149d9e['shift']());}}}(a253_0x53cf,0x9a4a9));export const CORE_IDE_CONFIGS={'cursor':{'name':a253_0x2b492b(0x1d7),'description':a253_0x2b492b(0x1cc),'folders':[a253_0x2b492b(0x1d5),'.cursor'],'files':[{'type':a253_0x2b492b(0x1db),'path':a253_0x2b492b(0x1dd),'template':a253_0x2b492b(0x1d8)}]},'windsurf':{'name':a253_0x2b492b(0x1f6),'description':a253_0x2b492b(0x1d6),'folders':[a253_0x2b492b(0x1ce)],'files':[{'type':'file','path':'.windsurf/workflows/rabetbase.md','template':'SKILL.md.tpl'}]},'claude':{'name':a253_0x2b492b(0x1f2),'description':a253_0x2b492b(0x1f2),'folders':[a253_0x2b492b(0x1fd)],'files':[{'type':'file','path':a253_0x2b492b(0x1e8),'template':'SKILL.md.tpl'}]},'cline':{'name':'Cline','description':a253_0x2b492b(0x1f5),'folders':[a253_0x2b492b(0x1c9)],'files':[{'type':a253_0x2b492b(0x1db),'path':a253_0x2b492b(0x1de),'template':a253_0x2b492b(0x1d8)}]},'codex':{'name':a253_0x2b492b(0x1ef),'description':a253_0x2b492b(0x1e4),'folders':[a253_0x2b492b(0x1dc)],'files':[{'type':'file','path':a253_0x2b492b(0x1ff),'template':a253_0x2b492b(0x1d8)}]},'opencode':{'name':a253_0x2b492b(0x1ec),'description':'OpenCode\x20IDE','folders':[a253_0x2b492b(0x1c7)],'files':[{'type':a253_0x2b492b(0x1db),'path':a253_0x2b492b(0x1d9),'template':a253_0x2b492b(0x1d8)}]},'qoder':{'name':'Qoder','description':a253_0x2b492b(0x1cf),'folders':[a253_0x2b492b(0x1e6)],'files':[{'type':a253_0x2b492b(0x1db),'path':a253_0x2b492b(0x1e0),'template':'SKILL.md.tpl'},{'type':a253_0x2b492b(0x1db),'path':'.qoder/skills/lovrabet/SKILL.md','template':a253_0x2b492b(0x1d8)}]},'codebuddy':{'name':a253_0x2b492b(0x1fb),'description':a253_0x2b492b(0x1fa),'folders':[a253_0x2b492b(0x1e3)],'files':[{'type':a253_0x2b492b(0x1db),'path':a253_0x2b492b(0x1df),'template':a253_0x2b492b(0x1d8)}]},'trae':{'name':'Trae','description':a253_0x2b492b(0x1d2),'folders':[a253_0x2b492b(0x201)],'files':[{'type':a253_0x2b492b(0x1db),'path':a253_0x2b492b(0x1f7),'template':'SKILL.md.tpl'}]}};export const IDE_CONFIGS={...CORE_IDE_CONFIGS,'agent':{'name':a253_0x2b492b(0x1f0),'description':a253_0x2b492b(0x1f4),'folders':['.agent'],'files':[{'type':a253_0x2b492b(0x1db),'path':'.agent/skills/lovrabet/SKILL.md','template':a253_0x2b492b(0x1d8)}]},'antigravity':{'name':a253_0x2b492b(0x1fe),'description':a253_0x2b492b(0x1f8),'folders':[a253_0x2b492b(0x1f9)],'files':[{'type':a253_0x2b492b(0x1db),'path':a253_0x2b492b(0x1e9),'template':a253_0x2b492b(0x1d8)}]}};function a253_0x53cf(){const _0x13c60d=['.claude/skills/lovrabet/SKILL.md','.agent/skills/lovrabet/SKILL.md','12139944UwnYUl','agent','OpenCode','cline','3530YoiZrJ','Codex','其他\x20(通用模板)','45260zqVzUk','Claude\x20Code','qoder','通用模板\x20-\x20兜底方案','Cline\x20IDE','Windsurf','.trae/skills/lovrabet/SKILL.md','Antigravity\x20IDE','.agent','CodeBuddy\x20IDE','CodeBuddy','cursor','.claude','Antigravity','.codex/skills/lovrabet/SKILL.md','claude','.trae','33682rdElRF','.opencode','90013cqbRjc','.cline','455LNIWBy','150vHzxss','Cursor\x20IDE','opencode','.windsurf','Qoder\x20IDE','8664784AgsvIc','codebuddy','Trae\x20IDE','trae','30FwasIa','.cursorrules','Windsurf\x20IDE','Cursor','SKILL.md.tpl','.opencode/skills/lovrabet/SKILL.md','2479296VUPaHr','file','.codex','.cursor/skills/rabetbase.md','.cline/skills/lovrabet/SKILL.md','.codebuddy/skills/lovrabet/SKILL.md','.qoder/rules/rabetbase.md','windsurf','9bdfihx','.codebuddy','Codex\x20IDE','codex','.qoder','8659eqaRwg'];a253_0x53cf=function(){return _0x13c60d;};return a253_0x53cf();}export const CORE_IDE_LIST=[a253_0x2b492b(0x200),'cline',a253_0x2b492b(0x1d1),a253_0x2b492b(0x1e5),a253_0x2b492b(0x1fc),a253_0x2b492b(0x1cd),a253_0x2b492b(0x1f3),a253_0x2b492b(0x1d3),a253_0x2b492b(0x1e1)];function a253_0x11cd(_0x46e35f,_0x4fe60a){_0x46e35f=_0x46e35f-0x1c6;const _0x53cf71=a253_0x53cf();let _0x11cd94=_0x53cf71[_0x46e35f];return _0x11cd94;}export const IDE_LIST=['antigravity','claude',a253_0x2b492b(0x1ed),'codebuddy',a253_0x2b492b(0x1e5),a253_0x2b492b(0x1fc),a253_0x2b492b(0x1cd),a253_0x2b492b(0x1f3),a253_0x2b492b(0x1d3),'windsurf',a253_0x2b492b(0x1eb)];export const ALL_CORE_IDES=['cursor',a253_0x2b492b(0x1e1),a253_0x2b492b(0x200),'cline',a253_0x2b492b(0x1e5),a253_0x2b492b(0x1cd),a253_0x2b492b(0x1f3),'codebuddy',a253_0x2b492b(0x1d3)];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a254_0x4f80(_0x5a3782,_0x284c7c){_0x5a3782=_0x5a3782-0x74;const _0x12d761=a254_0x12d7();let _0x4f80ce=_0x12d761[_0x5a3782];return _0x4f80ce;}(function(_0x5f0509,_0x13148c){const _0x148911=a254_0x4f80,_0x3bc12c=_0x5f0509();while(!![]){try{const _0x1e5048=parseInt(_0x148911(0x7a))/0x1+parseInt(_0x148911(0x74))/0x2+parseInt(_0x148911(0x7c))/0x3+parseInt(_0x148911(0x79))/0x4+-parseInt(_0x148911(0x78))/0x5*(parseInt(_0x148911(0x77))/0x6)+-parseInt(_0x148911(0x76))/0x7*(parseInt(_0x148911(0x75))/0x8)+-parseInt(_0x148911(0x7b))/0x9;if(_0x1e5048===_0x13148c)break;else _0x3bc12c['push'](_0x3bc12c['shift']());}catch(_0x41e252){_0x3bc12c['push'](_0x3bc12c['shift']());}}}(a254_0x12d7,0x406ab));function a254_0x12d7(){const _0x245a8a=['6gOGkIJ','1169435gaDThG','1776584hxsQeI','42130qUJHkq','1046565CTZloH','651885doppcg','826494PxdkFz','8IOBLLD','3519565giTpEl'];a254_0x12d7=function(){return _0x245a8a;};return a254_0x12d7();}import{createJqFilter,resolveBundledJqPaths}from'@lovrabet/cli-framework';import{CliErrors}from'../errors.js';export const applyJqFilter=createJqFilter(CliErrors,{'bundledJqPaths':resolveBundledJqPaths()});
|
package/lib/utils/cdn-config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1133a1,_0x1be354){const _0x533058=a255_0x3eb0,_0x1fdb9d=_0x1133a1();while(!![]){try{const _0x21d092=-parseInt(_0x533058(0x193))/0x1+parseInt(_0x533058(0x198))/0x2+parseInt(_0x533058(0x199))/0x3+parseInt(_0x533058(0x19c))/0x4*(-parseInt(_0x533058(0x190))/0x5)+parseInt(_0x533058(0x195))/0x6*(-parseInt(_0x533058(0x19d))/0x7)+parseInt(_0x533058(0x192))/0x8+parseInt(_0x533058(0x196))/0x9;if(_0x21d092===_0x1be354)break;else _0x1fdb9d['push'](_0x1fdb9d['shift']());}catch(_0x1229ae){_0x1fdb9d['push'](_0x1fdb9d['shift']());}}}(a255_0x4217,0x31041));function a255_0x3eb0(_0x483fd4,_0x4f22a1){_0x483fd4=_0x483fd4-0x18f;const _0x4217c9=a255_0x4217();let _0x3eb019=_0x4217c9[_0x483fd4];return _0x3eb019;}import{getTemplateBaseUrl}from'../utils/config.js';export async function fetchCdnConfig(){const _0x38191d=a255_0x3eb0,_0x2cffd7=getTemplateBaseUrl(),_0x2e1020=[_0x2cffd7+'/config.json',_0x2cffd7+_0x38191d(0x18f)];for(const _0x52b27c of _0x2e1020){try{const _0x315a40=await fetch(_0x52b27c,{'headers':{'Accept':_0x38191d(0x191)}});if(!_0x315a40['ok'])continue;const _0x2a06b1=await _0x315a40[_0x38191d(0x194)]();if(!_0x2a06b1[_0x38191d(0x19b)]?.['stableVersion']||!_0x2a06b1[_0x38191d(0x197)]?.['node']?.[_0x38191d(0x19e)])continue;return _0x2a06b1;}catch{}}return null;}let cachedConfig=null,cacheTime=0x0;function a255_0x4217(){const _0x3ce3de=['15168BUUBEf','168937XdSTIc','json','48gFvrtR','4876209ipragk','sdk','126390SJdtzq','684021Itygcx','now','cli','12GMbrgZ','90251YnZDhM','stableVersion','/config/index.json','603415oJVFxq','application/json'];a255_0x4217=function(){return _0x3ce3de;};return a255_0x4217();}const CACHE_TTL=0x5*0x3c*0x3e8,FAILURE_CACHE_TTL=0x3c*0x3e8;let hasCachedConfig=![];export async function getCdnConfig(){const _0x5ba6ce=a255_0x3eb0,_0x3d074c=Date[_0x5ba6ce(0x19a)]();if(hasCachedConfig){const _0x4c8f71=cachedConfig?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x3d074c-cacheTime<_0x4c8f71)return cachedConfig;}const _0x502fda=await fetchCdnConfig();return cachedConfig=_0x502fda,cacheTime=_0x3d074c,hasCachedConfig=!![],_0x502fda;}export function clearCdnConfigCache(){cachedConfig=null,cacheTime=0x0,hasCachedConfig=![];}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
const a256_0x291006=a256_0x309e;(function(_0x2dcda1,_0x6aaabb){const _0x40e157=a256_0x309e,_0x5a30c4=_0x2dcda1();while(!![]){try{const _0x5dfd27=parseInt(_0x40e157(0x153))/0x1*(-parseInt(_0x40e157(0x14d))/0x2)+parseInt(_0x40e157(0x154))/0x3+-parseInt(_0x40e157(0x16f))/0x4+parseInt(_0x40e157(0x172))/0x5+-parseInt(_0x40e157(0x163))/0x6+parseInt(_0x40e157(0x14e))/0x7+parseInt(_0x40e157(0x15c))/0x8*(parseInt(_0x40e157(0x160))/0x9);if(_0x5dfd27===_0x6aaabb)break;else _0x5a30c4['push'](_0x5a30c4['shift']());}catch(_0x312dba){_0x5a30c4['push'](_0x5a30c4['shift']());}}}(a256_0x48d0,0x47925));import a256_0x5980d6 from'node:fs';import a256_0x245ca6 from'node:path';function a256_0x309e(_0x3dfe90,_0x2ac401){_0x3dfe90=_0x3dfe90-0x14c;const _0x48d0a6=a256_0x48d0();let _0x309eb9=_0x48d0a6[_0x3dfe90];return _0x309eb9;}import a256_0x385707 from'semver';import{getCdnConfig}from'../utils/cdn-config.js';function a256_0x48d0(){const _0x54506a=['latest','stableVersion','1.2.0','9hAfZID','@lovrabet/sdk','node_modules','2950428FWknmK','↪\x20SDK\x20update\x20available','package.json','utf8','test','\x1b[0m','needsUpgrade','\x20\x20\x20Upgrade\x20command:\x20','all','minVersion','some','log','2114992ehljzr','devDependencies','readFileSync','2281440yoHRKz','packageName','52ioUljg','3914967XvOUjO','npm\x20install\x20','sdk','\x1b[33m','\x20\x20\x20Current\x20version:\x20','11525GGUtEw','95733sxpZcs','version','existsSync','parse','dependencies','join','node','coerce','4526504sqgzjr'];a256_0x48d0=function(){return _0x54506a;};return a256_0x48d0();}const FALLBACK_MIN_SDK_VERSION=a256_0x291006(0x15f);function isNonNumericVersion(_0x545bf5){const _0x116e86=a256_0x291006,_0x12bb15=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x12bb15[_0x116e86(0x16d)](_0x3566ab=>_0x3566ab[_0x116e86(0x167)](_0x545bf5));}function getInstalledVersion(_0x3b4996,_0x183a91){const _0x6d9c4d=a256_0x291006;try{const _0x14f97e=a256_0x245ca6[_0x6d9c4d(0x159)](_0x3b4996,_0x6d9c4d(0x162),_0x183a91,_0x6d9c4d(0x165));if(a256_0x5980d6[_0x6d9c4d(0x156)](_0x14f97e)){const _0x203ca=JSON['parse'](a256_0x5980d6[_0x6d9c4d(0x171)](_0x14f97e,'utf-8'));return _0x203ca[_0x6d9c4d(0x155)]||null;}}catch{}return null;}async function getSdkStableVersion(){const _0x4a4a58=a256_0x291006;try{const _0x308a69=await getCdnConfig();return _0x308a69?.[_0x4a4a58(0x150)]?.[_0x4a4a58(0x15a)]?.[_0x4a4a58(0x15e)]||null;}catch{return null;}}async function getSdkPackageName(){const _0x557cab=a256_0x291006;try{const _0x5ac605=await getCdnConfig();return _0x5ac605?.[_0x557cab(0x150)]?.[_0x557cab(0x15a)]?.[_0x557cab(0x14c)]||'@lovrabet/sdk';}catch{return _0x557cab(0x161);}}export async function checkSdkVersion(_0x333398){const _0x2092dc=a256_0x291006,_0x4548f0=a256_0x245ca6['join'](_0x333398,'package.json'),[_0x2605f0,_0x1ca998]=await Promise[_0x2092dc(0x16b)]([getSdkStableVersion(),getSdkPackageName()]),_0x1bb9a0=_0x2605f0||FALLBACK_MIN_SDK_VERSION;if(!a256_0x5980d6[_0x2092dc(0x156)](_0x4548f0))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x1bb9a0,'packageName':_0x1ca998,'stableVersion':_0x2605f0};try{const _0x472010=JSON[_0x2092dc(0x157)](a256_0x5980d6[_0x2092dc(0x171)](_0x4548f0,_0x2092dc(0x166))),_0x5d0df5=_0x472010[_0x2092dc(0x158)]||{},_0x1ed0ca=_0x472010[_0x2092dc(0x170)]||{},_0x3f255a=_0x5d0df5[_0x1ca998]||_0x1ed0ca[_0x1ca998];if(!_0x3f255a)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x1bb9a0,'packageName':_0x1ca998,'stableVersion':_0x2605f0};let _0x2a7dfe=getInstalledVersion(_0x333398,_0x1ca998);!_0x2a7dfe&&(_0x2a7dfe=_0x3f255a);if(isNonNumericVersion(_0x3f255a))return{'installed':!![],'version':_0x2a7dfe,'needsUpgrade':![],'minVersion':_0x1bb9a0,'packageName':_0x1ca998,'stableVersion':_0x2605f0};const _0x2dda29=a256_0x385707['coerce'](_0x2a7dfe),_0x1c74e9=a256_0x385707[_0x2092dc(0x15b)](_0x1bb9a0),_0x58aed4=_0x2dda29&&_0x1c74e9?a256_0x385707['lt'](_0x2dda29,_0x1c74e9):![];return{'installed':!![],'version':_0x2a7dfe,'needsUpgrade':_0x58aed4,'minVersion':_0x1bb9a0,'packageName':_0x1ca998,'stableVersion':_0x2605f0};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x1bb9a0,'packageName':_0x1ca998,'stableVersion':_0x2605f0};}}export function checkSdkVersionSync(_0x2916fe){const _0x20c855=a256_0x291006,_0x4fee9b=a256_0x245ca6[_0x20c855(0x159)](_0x2916fe,'package.json'),_0x3a2b19=_0x20c855(0x161);if(!a256_0x5980d6[_0x20c855(0x156)](_0x4fee9b))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x3a2b19,'stableVersion':null};try{const _0xcd6174=JSON['parse'](a256_0x5980d6[_0x20c855(0x171)](_0x4fee9b,_0x20c855(0x166))),_0x1b9014=_0xcd6174[_0x20c855(0x158)]||{},_0x29c9c6=_0xcd6174[_0x20c855(0x170)]||{},_0x1384b7=_0x1b9014[_0x3a2b19]||_0x29c9c6[_0x3a2b19];if(!_0x1384b7)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x3a2b19,'stableVersion':null};let _0xf16a8d=getInstalledVersion(_0x2916fe,_0x3a2b19);!_0xf16a8d&&(_0xf16a8d=_0x1384b7);if(isNonNumericVersion(_0x1384b7))return{'installed':!![],'version':_0xf16a8d,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x3a2b19,'stableVersion':null};const _0x255c37=a256_0x385707[_0x20c855(0x15b)](_0xf16a8d),_0xd9659=_0x255c37?a256_0x385707['lt'](_0x255c37,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0xf16a8d,'needsUpgrade':_0xd9659,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x3a2b19,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x3a2b19,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x1e4ce0){const _0x392fa4=a256_0x291006;if(!_0x1e4ce0[_0x392fa4(0x169)])return;const _0x1fa5ce=_0x392fa4(0x151),_0x2be95d=_0x392fa4(0x168),_0x9aaf25='\x1b[1m',_0x3baa4e=_0x1e4ce0[_0x392fa4(0x14c)]||'@lovrabet/sdk',_0x4ad6b4=_0x1e4ce0[_0x392fa4(0x15e)]||_0x1e4ce0[_0x392fa4(0x16c)],_0x3e4817=_0x392fa4(0x14f)+_0x3baa4e+'@'+(_0x4ad6b4||_0x392fa4(0x15d));console[_0x392fa4(0x16e)](),console[_0x392fa4(0x16e)](''+_0x1fa5ce+_0x9aaf25+_0x392fa4(0x164)+_0x2be95d),console[_0x392fa4(0x16e)](_0x1fa5ce+_0x392fa4(0x152)+_0x3baa4e+'@'+_0x1e4ce0[_0x392fa4(0x155)]+_0x2be95d),console[_0x392fa4(0x16e)](_0x1fa5ce+'\x20\x20\x20Stable\x20version:\x20'+_0x4ad6b4+_0x2be95d),console[_0x392fa4(0x16e)](_0x1fa5ce+_0x392fa4(0x16a)+_0x3e4817+_0x2be95d),console[_0x392fa4(0x16e)]();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4cfddd,_0x311584){const _0x2d66c9=a257_0x5b43,_0x5b4eb3=_0x4cfddd();while(!![]){try{const _0x210f55=-parseInt(_0x2d66c9(0x76))/0x1*(parseInt(_0x2d66c9(0x7a))/0x2)+parseInt(_0x2d66c9(0x75))/0x3*(parseInt(_0x2d66c9(0x74))/0x4)+-parseInt(_0x2d66c9(0x8b))/0x5*(-parseInt(_0x2d66c9(0x93))/0x6)+-parseInt(_0x2d66c9(0x7c))/0x7+-parseInt(_0x2d66c9(0x95))/0x8+-parseInt(_0x2d66c9(0x98))/0x9+parseInt(_0x2d66c9(0x87))/0xa;if(_0x210f55===_0x311584)break;else _0x5b4eb3['push'](_0x5b4eb3['shift']());}catch(_0x5e51c2){_0x5b4eb3['push'](_0x5b4eb3['shift']());}}}(a257_0xb92b,0x20ee6));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a257_0x4bb5cf from'semver';import{getCliVersionPolicy}from'../utils/cli-version-policy.js';import{NPM_PACKAGE_NAME}from'../constant/cli.js';function a257_0xb92b(){const _0x1959be=['log','2228640DCvgUN','stableVersion','Upgrade\x20command:\x20','\x20\x20\x20Upgrade\x20command:\x20','912055DmjAsa','↪\x20New\x20version\x20available','currentVersion','1.0.0','Minimum\x20supported:\x20','\x20\x20\x20Recommended\x20stable:\x20','join','filter','6aqAgaA','belowMinimum','1179384BEAVPw','\x1b[33m','\x20\x20\x20Minimum\x20supported:\x20','509220wrazir','minimumVersionMessage','minimumVersion','Current\x20CLI\x20version\x20is\x20below\x20the\x20service\x20compatibility\x20support\x20line.','907684CdpfjW','3weKVjU','9xtfgKJ','\x20\x20\x20Stable\x20version:\x20','\x20\x20\x20','../..','13266ofHrbu','coerce','1635270vAafDZ','npm\x20install\x20-g\x20','\x1b[0m','\x20\x20\x20Current\x20CLI\x20version:\x20','package.json','latest','Current\x20version:\x20','upgradeMessage','utf-8','↪\x20Critical\x20CLI\x20upgrade\x20required'];a257_0xb92b=function(){return _0x1959be;};return a257_0xb92b();}import{CliErrors}from'../errors.js';export function getCliUpgradeCommand(_0x259bda){const _0x26071d=a257_0x5b43,_0x5225d6=_0x259bda[_0x26071d(0x88)]||_0x26071d(0x81);return _0x26071d(0x7d)+NPM_PACKAGE_NAME+'@'+_0x5225d6;}function getCurrentCliVersion(){const _0x3b9695=a257_0x5b43;try{const _0xdb2168=fileURLToPath(import.meta.url),_0x59b972=resolve(dirname(_0xdb2168),_0x3b9695(0x79)),_0x5d3978=resolve(_0x59b972,_0x3b9695(0x80)),_0x34577b=JSON['parse'](readFileSync(_0x5d3978,_0x3b9695(0x84)));return _0x34577b['version']||_0x3b9695(0x8e);}catch{return _0x3b9695(0x8e);}}export async function checkCliVersion(){const _0x480dd7=a257_0x5b43,_0x32dcff=getCurrentCliVersion(),_0x250796=await getCliVersionPolicy(),_0x1e4ddb=_0x250796?.[_0x480dd7(0x88)]||null,_0x54034f=_0x250796?.['minimumVersion']||null;let _0xfadd90=![],_0x3e2928=![];const _0x584669=a257_0x4bb5cf[_0x480dd7(0x7b)](_0x32dcff);if(_0x584669&&_0x1e4ddb)try{const _0x1be2ac=a257_0x4bb5cf[_0x480dd7(0x7b)](_0x1e4ddb);if(_0x1be2ac)_0xfadd90=a257_0x4bb5cf['lt'](_0x584669,_0x1be2ac);}catch{}if(_0x584669&&_0x54034f)try{const _0x360c0d=a257_0x4bb5cf['coerce'](_0x54034f);if(_0x360c0d)_0x3e2928=a257_0x4bb5cf['lt'](_0x584669,_0x360c0d);}catch{}return _0x3e2928&&(_0xfadd90=!![]),{'currentVersion':_0x32dcff,'stableVersion':_0x1e4ddb,'minimumVersion':_0x54034f,'needsUpgrade':_0xfadd90,'belowMinimum':_0x3e2928,'isPreRelease':![],'upgradeMessage':_0x250796?.[_0x480dd7(0x83)],'minimumVersionMessage':_0x250796?.[_0x480dd7(0x99)]};}export function printCliUpgradeWarning(_0x4bd37a){const _0x12cbef=a257_0x5b43;if(!_0x4bd37a['needsUpgrade']&&!_0x4bd37a[_0x12cbef(0x94)])return;const _0x2b064b='\x1b[31m',_0xfe461f=_0x12cbef(0x96),_0x5d4347=_0x12cbef(0x7e),_0x32645f='\x1b[1m',_0x5b195d=getCliUpgradeCommand(_0x4bd37a);console[_0x12cbef(0x86)](),_0x4bd37a[_0x12cbef(0x94)]?(console[_0x12cbef(0x86)](''+_0x2b064b+_0x32645f+_0x12cbef(0x85)+_0x5d4347),console[_0x12cbef(0x86)](_0x2b064b+_0x12cbef(0x7f)+_0x4bd37a[_0x12cbef(0x8d)]+_0x5d4347),_0x4bd37a[_0x12cbef(0x9a)]&&console[_0x12cbef(0x86)](_0x2b064b+_0x12cbef(0x97)+_0x4bd37a[_0x12cbef(0x9a)]+_0x5d4347),_0x4bd37a[_0x12cbef(0x88)]&&_0x4bd37a[_0x12cbef(0x88)]!==_0x4bd37a['minimumVersion']&&console['log'](_0x2b064b+_0x12cbef(0x90)+_0x4bd37a[_0x12cbef(0x88)]+_0x5d4347),_0x4bd37a[_0x12cbef(0x99)]&&console[_0x12cbef(0x86)](_0x2b064b+_0x12cbef(0x78)+_0x4bd37a[_0x12cbef(0x99)]+_0x5d4347),console[_0x12cbef(0x86)](_0x2b064b+_0x12cbef(0x8a)+_0x5b195d+_0x5d4347)):(console[_0x12cbef(0x86)](''+_0xfe461f+_0x32645f+_0x12cbef(0x8c)+_0x5d4347),console[_0x12cbef(0x86)](_0xfe461f+_0x12cbef(0x7f)+_0x4bd37a[_0x12cbef(0x8d)]+_0x5d4347),console[_0x12cbef(0x86)](_0xfe461f+_0x12cbef(0x77)+_0x4bd37a[_0x12cbef(0x88)]+_0x5d4347),_0x4bd37a[_0x12cbef(0x83)]&&console[_0x12cbef(0x86)](_0xfe461f+_0x12cbef(0x78)+_0x4bd37a[_0x12cbef(0x83)]+_0x5d4347),console[_0x12cbef(0x86)](_0xfe461f+_0x12cbef(0x8a)+_0x5b195d+_0x5d4347)),console[_0x12cbef(0x86)]();}function a257_0x5b43(_0x472b46,_0x5c8b23){_0x472b46=_0x472b46-0x73;const _0xb92bc7=a257_0xb92b();let _0x5b4338=_0xb92bc7[_0x472b46];return _0x5b4338;}export function assertCliVersionSupported(_0x255353){const _0x18c601=a257_0x5b43;if(!_0x255353['belowMinimum'])return;const _0x5682a9=[_0x255353[_0x18c601(0x99)],_0x18c601(0x82)+_0x255353['currentVersion'],_0x255353['minimumVersion']?_0x18c601(0x8f)+_0x255353[_0x18c601(0x9a)]:null,_0x18c601(0x89)+getCliUpgradeCommand(_0x255353)][_0x18c601(0x92)](Boolean)[_0x18c601(0x91)]('\x0a');throw CliErrors['validation'](_0x18c601(0x73),_0x5682a9);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1d41c2,_0x4dfd3a){const _0x4cd691=a258_0x1734,_0x5165db=_0x1d41c2();while(!![]){try{const _0x3cc789=parseInt(_0x4cd691(0x1a9))/0x1*(-parseInt(_0x4cd691(0x1b3))/0x2)+-parseInt(_0x4cd691(0x1af))/0x3+-parseInt(_0x4cd691(0x1b1))/0x4+parseInt(_0x4cd691(0x1b2))/0x5+-parseInt(_0x4cd691(0x1a8))/0x6+parseInt(_0x4cd691(0x1b8))/0x7*(parseInt(_0x4cd691(0x1b7))/0x8)+parseInt(_0x4cd691(0x1b0))/0x9*(parseInt(_0x4cd691(0x1bc))/0xa);if(_0x3cc789===_0x4dfd3a)break;else _0x5165db['push'](_0x5165db['shift']());}catch(_0x39181d){_0x5165db['push'](_0x5165db['shift']());}}}(a258_0x3ad5,0x4c3bc));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(_0x876e7e){const _0x553329=a258_0x1734;return typeof _0x876e7e===_0x553329(0x1bb)&&_0x876e7e[_0x553329(0x1b5)]()[_0x553329(0x1bd)]>0x0?_0x876e7e[_0x553329(0x1b5)]():null;}function a258_0x1734(_0x3480a5,_0x2d8ae3){_0x3480a5=_0x3480a5-0x1a6;const _0x3ad5e9=a258_0x3ad5();let _0x1734d3=_0x3ad5e9[_0x3480a5];return _0x1734d3;}function normalizeCliVersionPolicy(_0x1e7a62){const _0x739729=a258_0x1734;if(!_0x1e7a62||typeof _0x1e7a62!==_0x739729(0x1b4))return null;const _0x24d0b3=_0x1e7a62,_0x283e18=_0x24d0b3[_0x739729(0x1bf)]&&typeof _0x24d0b3[_0x739729(0x1bf)]==='object'?_0x24d0b3[_0x739729(0x1bf)]:_0x24d0b3,_0x40b01d=pickString(_0x283e18[_0x739729(0x1b9)])||pickString(_0x283e18[_0x739729(0x1ad)])||pickString(_0x283e18[_0x739729(0x1be)]),_0x2ff7ea=pickString(_0x283e18['minimumVersion'])||pickString(_0x283e18[_0x739729(0x1ab)]);if(!_0x40b01d&&!_0x2ff7ea)return null;return{'stableVersion':_0x40b01d,'minimumVersion':_0x2ff7ea,'upgradeMessage':pickString(_0x283e18[_0x739729(0x1b6)])||undefined,'minimumVersionMessage':pickString(_0x283e18[_0x739729(0x1ae)])||undefined};}export async function fetchCliVersionPolicy(){const _0x14d281=a258_0x1734,_0x1d6efa=new AbortController(),_0x57e8f7=setTimeout(()=>_0x1d6efa[_0x14d281(0x1ba)](),FETCH_TIMEOUT_MS);try{const _0x2d5597=await fetch(CLI_VERSION_POLICY_URL,{'headers':{'Accept':_0x14d281(0x1a7)},'signal':_0x1d6efa[_0x14d281(0x1aa)]});if(!_0x2d5597['ok'])return null;const _0x4ad10f=await _0x2d5597[_0x14d281(0x1ac)]();return normalizeCliVersionPolicy(_0x4ad10f);}catch{return null;}finally{clearTimeout(_0x57e8f7);}}let cachedPolicy=null,cacheTime=0x0,hasCachedPolicy=![];export async function getCliVersionPolicy(){const _0x386e00=a258_0x1734,_0x157206=Date[_0x386e00(0x1a6)]();if(hasCachedPolicy){const _0x2c8081=cachedPolicy?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x157206-cacheTime<_0x2c8081)return cachedPolicy;}const _0x4ba7fd=await fetchCliVersionPolicy();return cachedPolicy=_0x4ba7fd,cacheTime=_0x157206,hasCachedPolicy=!![],_0x4ba7fd;}export function clearCliVersionPolicyCache(){cachedPolicy=null,cacheTime=0x0,hasCachedPolicy=![];}function a258_0x3ad5(){const _0x5a219c=['signal','minVersion','json','latestVersion','minimumVersionMessage','1295718AfIFJu','36HaQhKn','2029764ZvNZYr','1148500pLyvgn','11288DzNrdq','object','trim','upgradeMessage','884880DqTlTB','14kLdyVL','stableVersion','abort','string','3287590YpKsEA','length','recommendedVersion','cli','now','application/json','2442726uLcLPG','19OORXUX'];a258_0x3ad5=function(){return _0x5a219c;};return a258_0x3ad5();}
|
package/lib/utils/config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x2304f0,_0x16a756){const _0x23947b=a259_0x20fd,_0x25b0ba=_0x2304f0();while(!![]){try{const _0x4536d6=-parseInt(_0x23947b(0x151))/0x1+parseInt(_0x23947b(0x153))/0x2+parseInt(_0x23947b(0x154))/0x3*(parseInt(_0x23947b(0x14d))/0x4)+parseInt(_0x23947b(0x14a))/0x5+-parseInt(_0x23947b(0x152))/0x6+-parseInt(_0x23947b(0x14c))/0x7+-parseInt(_0x23947b(0x14b))/0x8*(parseInt(_0x23947b(0x150))/0x9);if(_0x4536d6===_0x16a756)break;else _0x25b0ba['push'](_0x25b0ba['shift']());}catch(_0x448e30){_0x25b0ba['push'](_0x25b0ba['shift']());}}}(a259_0x5864,0x27723));import{initEnv}from'../constant/env.js';import{readRawConfig,getConfigAppCode as a259_0x8dfe81,getMultiAppConfigs as a259_0x5d40f6,getTemplateBaseUrl as a259_0x20057c}from'../context.js';export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';function a259_0x20fd(_0x26dad7,_0x559983){_0x26dad7=_0x26dad7-0x14a;const _0x586438=a259_0x5864();let _0x20fd2e=_0x586438[_0x26dad7];return _0x20fd2e;}export{isInProject}from'../context.js';export function readConfig(_0xe5b7d3){const _0xd85076=a259_0x20fd,_0x1795a5=readRawConfig(_0xe5b7d3);return _0x1795a5['env']&&typeof _0x1795a5[_0xd85076(0x14e)]===_0xd85076(0x14f)&&initEnv(_0x1795a5[_0xd85076(0x14e)]),_0x1795a5;}function a259_0x5864(){const _0x28aa09=['env','string','98964wjEDLQ','2316CaXuYX','129720JiSrAQ','412602byDPzd','93NvoCIH','347995nVbfJd','32UvWest','1949542jYoKjV','29948gKqnbt'];a259_0x5864=function(){return _0x28aa09;};return a259_0x5864();}export function getConfigAppCode(){return a259_0x8dfe81();}export function getMultiAppConfigs(_0x54df64='project'){return a259_0x5d40f6(_0x54df64);}export function getTemplateBaseUrl(){return a259_0x20057c();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a260_0x4bfd(){const _0x3b3ca7=['1651113utsZVw','join','6038znsZRi','877148FUNkhH','isDirectory','复制目录时出错:','637lZsLPV','1133450djVDMB','249420yBWALE','readdirSync','copyFileSync','name','1042136MVMpAp','101QgUNTS','21954OLjkJH','error'];a260_0x4bfd=function(){return _0x3b3ca7;};return a260_0x4bfd();}(function(_0x3e8138,_0x3ad7bb){const _0x586ccb=a260_0x3b2b,_0x200515=_0x3e8138();while(!![]){try{const _0x5338d0=parseInt(_0x586ccb(0xdd))/0x1*(parseInt(_0x586ccb(0xd2))/0x2)+-parseInt(_0x586ccb(0xd8))/0x3+-parseInt(_0x586ccb(0xd3))/0x4+parseInt(_0x586ccb(0xd7))/0x5+-parseInt(_0x586ccb(0xce))/0x6*(parseInt(_0x586ccb(0xd6))/0x7)+parseInt(_0x586ccb(0xdc))/0x8+parseInt(_0x586ccb(0xd0))/0x9;if(_0x5338d0===_0x3ad7bb)break;else _0x200515['push'](_0x200515['shift']());}catch(_0x2d16f2){_0x200515['push'](_0x200515['shift']());}}}(a260_0x4bfd,0x33411));import a260_0x2053ff from'node:path';import a260_0x5d351b from'node:fs';function a260_0x3b2b(_0x4bbff1,_0x1e9e98){_0x4bbff1=_0x4bbff1-0xce;const _0x4bfdbd=a260_0x4bfd();let _0x3b2b01=_0x4bfdbd[_0x4bbff1];return _0x3b2b01;}export async function copyDirectory(_0x43c052,_0xf504fb){const _0x1b62e5=a260_0x3b2b;try{const _0x75f25c=a260_0x5d351b[_0x1b62e5(0xd9)](_0x43c052,{'withFileTypes':!![]});a260_0x5d351b['mkdirSync'](_0xf504fb,{'recursive':!![]});for(const _0x998588 of _0x75f25c){const _0x3e445f=a260_0x2053ff['join'](_0x43c052,_0x998588['name']),_0x2fc6a6=a260_0x2053ff[_0x1b62e5(0xd1)](_0xf504fb,_0x998588[_0x1b62e5(0xdb)]);_0x998588[_0x1b62e5(0xd4)]()?await copyDirectory(_0x3e445f,_0x2fc6a6):a260_0x5d351b[_0x1b62e5(0xda)](_0x3e445f,_0x2fc6a6);}}catch(_0x521ef1){console[_0x1b62e5(0xcf)](_0x1b62e5(0xd5),_0x521ef1);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1cc92e,_0x34f82d){const _0x3b40ec=a261_0x5bba,_0x18ed5d=_0x1cc92e();while(!![]){try{const _0x5ea4e7=parseInt(_0x3b40ec(0xa7))/0x1+-parseInt(_0x3b40ec(0x9f))/0x2*(parseInt(_0x3b40ec(0x9d))/0x3)+-parseInt(_0x3b40ec(0xa3))/0x4*(parseInt(_0x3b40ec(0xa1))/0x5)+parseInt(_0x3b40ec(0x9c))/0x6*(-parseInt(_0x3b40ec(0xa5))/0x7)+parseInt(_0x3b40ec(0xa4))/0x8+-parseInt(_0x3b40ec(0xa0))/0x9+-parseInt(_0x3b40ec(0xa9))/0xa*(-parseInt(_0x3b40ec(0x9e))/0xb);if(_0x5ea4e7===_0x34f82d)break;else _0x18ed5d['push'](_0x18ed5d['shift']());}catch(_0x58f991){_0x18ed5d['push'](_0x18ed5d['shift']());}}}(a261_0x3f77,0xed0a9));function a261_0x5bba(_0x5a2c9f,_0x42230f){_0x5a2c9f=_0x5a2c9f-0x9b;const _0x3f77ec=a261_0x3f77();let _0x5bba73=_0x3f77ec[_0x5a2c9f];return _0x5bba73;}function toFiniteNumber(_0x4ea541){const _0x4067a6=a261_0x5bba;if(typeof _0x4ea541===_0x4067a6(0xa2)&&Number[_0x4067a6(0xaa)](_0x4ea541))return _0x4ea541;if(typeof _0x4ea541===_0x4067a6(0x9b)){const _0x44a0de=_0x4ea541[_0x4067a6(0xa8)]();if(!_0x44a0de)return undefined;const _0x128417=Number(_0x44a0de);if(Number[_0x4067a6(0xaa)](_0x128417))return _0x128417;}return undefined;}export function normalizeEntityWithIdResponse(_0x59cd03){const _0x3eb815=a261_0x5bba,_0x4e048b=toFiniteNumber(_0x59cd03);if(_0x4e048b!==undefined)return{'id':_0x4e048b,'entity':{'id':_0x4e048b}};if(!_0x59cd03||typeof _0x59cd03!==_0x3eb815(0xa6))return{'id':undefined,'entity':{}};const _0x32d0fa={..._0x59cd03},_0x49f0a2=toFiniteNumber(_0x32d0fa['id']);return _0x49f0a2!==undefined&&(_0x32d0fa['id']=_0x49f0a2),{'id':_0x49f0a2,'entity':_0x32d0fa};}function a261_0x3f77(){const _0x53bbd6=['isFinite','string','702258JkxFlQ','4086Rkhyfr','11annbtZ','918jZHypA','6823314YgFyuF','385rRAnRF','number','56884VvxWWs','3605432hRmbPN','35qmZpKJ','object','1471245akJnRR','trim','21125330jfXUwT'];a261_0x3f77=function(){return _0x53bbd6;};return a261_0x3f77();}
|
package/lib/utils/file-utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a262_0x65c4(){const _0x34e2e7=['201CBjcMh','120ADLpLs','6180349ulOBLs','7324KgibLd','5909337jaVfcO','30534NjpuoZ','isDirectory','7872720ayjSSQ','968616qDxJkL','10NqqoxA','580dWBBTr','17757FlCvLp'];a262_0x65c4=function(){return _0x34e2e7;};return a262_0x65c4();}function a262_0x9ca9(_0x577f0a,_0x2b4e64){_0x577f0a=_0x577f0a-0x76;const _0x65c4ec=a262_0x65c4();let _0x9ca9b1=_0x65c4ec[_0x577f0a];return _0x9ca9b1;}(function(_0x189781,_0x48eecf){const _0x24b9a0=a262_0x9ca9,_0x409f1d=_0x189781();while(!![]){try{const _0x1f19a0=-parseInt(_0x24b9a0(0x78))/0x1*(-parseInt(_0x24b9a0(0x7b))/0x2)+parseInt(_0x24b9a0(0x77))/0x3*(parseInt(_0x24b9a0(0x76))/0x4)+parseInt(_0x24b9a0(0x79))/0x5*(-parseInt(_0x24b9a0(0x7d))/0x6)+parseInt(_0x24b9a0(0x7a))/0x7+-parseInt(_0x24b9a0(0x7f))/0x8+parseInt(_0x24b9a0(0x7c))/0x9*(-parseInt(_0x24b9a0(0x81))/0xa)+-parseInt(_0x24b9a0(0x80))/0xb;if(_0x1f19a0===_0x48eecf)break;else _0x409f1d['push'](_0x409f1d['shift']());}catch(_0x12581d){_0x409f1d['push'](_0x409f1d['shift']());}}}(a262_0x65c4,0x98ead));import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';export async function copyDir(_0x2abc7f,_0x2c904e){const _0x4747af=a262_0x9ca9,_0x7651e6=statSync(_0x2abc7f);if(_0x7651e6[_0x4747af(0x7e)]()){!existsSync(_0x2c904e)&&mkdirSync(_0x2c904e,{'recursive':!![]});const _0x5e88cb=readdirSync(_0x2abc7f);for(const _0x5454d1 of _0x5e88cb){await copyDir(join(_0x2abc7f,_0x5454d1),join(_0x2c904e,_0x5454d1));}}else copyFileSync(_0x2abc7f,_0x2c904e);}export function ensureDir(_0x110e1a){!existsSync(_0x110e1a)&&mkdirSync(_0x110e1a,{'recursive':!![]});}export function pathExists(_0x4e009d){return existsSync(_0x4e009d);}
|