@lovrabet/rabetbase-cli 2.5.1-beta.6 → 2.5.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/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/api/generate-sdk-config-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/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/members-list.js +1 -1
- package/lib/commands/app/remote-directory.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/delete.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/app-config/list.js +1 -1
- package/lib/commands/app-config/set.js +1 -1
- package/lib/commands/app-config/shared.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/create.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-registry.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/async-task.js +1 -1
- package/lib/commands/common/dry-run.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/delete.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/init.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/business-groups.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/extend-update.js +1 -1
- package/lib/commands/dataset/field-restore.js +1 -1
- package/lib/commands/dataset/field-update.js +1 -1
- package/lib/commands/dataset/generate.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.js +1 -1
- package/lib/commands/dataset/relation-audit.js +1 -1
- package/lib/commands/dataset/relation-create.js +1 -1
- package/lib/commands/dataset/relation-delete.js +1 -1
- package/lib/commands/dataset/relation-shared.js +1 -1
- package/lib/commands/dataset/relation-update.js +1 -1
- package/lib/commands/dataset/relations.js +1 -1
- package/lib/commands/dataset/rename.js +1 -1
- package/lib/commands/dataset/restore.js +1 -1
- package/lib/commands/dataset/user-deleted-field-list.js +1 -1
- package/lib/commands/db/analysis-batching.js +1 -1
- package/lib/commands/db/analyze-batch-plan.js +1 -1
- package/lib/commands/db/analyze-cancel.js +1 -1
- package/lib/commands/db/analyze-start.js +1 -1
- package/lib/commands/db/analyze-status.js +1 -1
- package/lib/commands/db/create.js +1 -1
- package/lib/commands/db/delete.js +1 -1
- package/lib/commands/db/detail.js +1 -1
- package/lib/commands/db/diff-refresh-start.js +1 -1
- package/lib/commands/db/diff-refresh-status.js +1 -1
- package/lib/commands/db/diff.js +1 -1
- package/lib/commands/db/index.js +1 -1
- package/lib/commands/db/list.js +1 -1
- package/lib/commands/db/shared.js +1 -1
- package/lib/commands/db/table-diff-shared.js +1 -1
- package/lib/commands/db/tables.js +1 -1
- package/lib/commands/db/test.js +1 -1
- package/lib/commands/db/update.js +1 -1
- package/lib/commands/deployment/auto-sync.js +1 -1
- package/lib/commands/deployment/index.js +1 -1
- package/lib/commands/deployment/sync.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/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 -1
- package/lib/commands/kb/delete.js +1 -1
- package/lib/commands/kb/detail.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/kb/list.js +1 -1
- package/lib/commands/kb/search.js +1 -1
- package/lib/commands/kb/shared.js +1 -1
- package/lib/commands/kb/update.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/asset-update.js +1 -1
- package/lib/commands/menu/delete.js +1 -1
- package/lib/commands/menu/external-link-create.js +1 -1
- package/lib/commands/menu/external-link-update.js +1 -1
- package/lib/commands/menu/group-create.js +1 -1
- package/lib/commands/menu/group-update.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/move.js +1 -1
- package/lib/commands/menu/regroup-start.js +1 -1
- package/lib/commands/menu/rename.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/delete-plan.js +1 -1
- package/lib/commands/menu/shared/facts.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/mutations.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/visibility-update.js +1 -1
- package/lib/commands/notification/config-create.js +1 -1
- package/lib/commands/notification/config-delete.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/config-update.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/notification/shared.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/page/create.js +1 -1
- package/lib/commands/page/custom/detail.js +1 -1
- package/lib/commands/page/custom/list.js +1 -1
- package/lib/commands/page/custom/publish.js +1 -1
- package/lib/commands/page/custom/shared.js +1 -1
- package/lib/commands/page/custom/syntax.js +1 -1
- package/lib/commands/page/custom/template.js +1 -1
- package/lib/commands/page/custom/update.js +1 -1
- package/lib/commands/page/data-list-status.js +1 -1
- package/lib/commands/page/generate-start.js +1 -1
- package/lib/commands/page/generate-status.js +1 -1
- package/lib/commands/page/index.js +1 -1
- package/lib/commands/page/pull.js +1 -1
- package/lib/commands/page/push.js +1 -1
- package/lib/commands/page/relation-audit.js +1 -1
- package/lib/commands/page/restore.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/project/create/enhanced-guided-create.js +1 -1
- package/lib/commands/project/create/format-elapsed.js +1 -1
- package/lib/commands/project/create/main.js +1 -1
- package/lib/commands/project/create/materialize-project-template.js +1 -1
- package/lib/commands/project/create/project-name.js +1 -1
- package/lib/commands/project/create/project-template-archive.js +1 -1
- package/lib/commands/project/create/project-template-path.js +1 -1
- package/lib/commands/project/create/use-copy-project-template.js +1 -1
- package/lib/commands/project/create/use-format-code.js +1 -1
- package/lib/commands/project/create/use-install-dependencies.js +1 -1
- package/lib/commands/project/domain-routing-sync.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/delete.js +1 -1
- package/lib/commands/role/detail.js +1 -1
- package/lib/commands/role/index.js +1 -1
- package/lib/commands/role/list.js +1 -1
- package/lib/commands/role/shared.js +1 -1
- package/lib/commands/role/update.js +1 -1
- package/lib/commands/role/user-add.js +1 -1
- package/lib/commands/role/user-remove.js +1 -1
- package/lib/commands/role/user-resolve.js +1 -1
- package/lib/commands/rule/get.js +1 -1
- package/lib/commands/rule/index.js +1 -1
- package/lib/commands/rule/list.js +1 -1
- package/lib/commands/rule/set.js +1 -1
- package/lib/commands/rule/shared.js +1 -1
- package/lib/commands/run/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/sql/create.js +1 -1
- package/lib/commands/sql/delete.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/sql/list.js +1 -1
- package/lib/commands/sql/pull.js +1 -1
- package/lib/commands/sql/push.js +1 -1
- package/lib/commands/sql/shared.js +1 -1
- package/lib/commands/sql/status.js +1 -1
- package/lib/commands/sql/validate.js +1 -1
- package/lib/commands/task/index.js +1 -1
- package/lib/commands/task/status.js +1 -1
- package/lib/commands/tenant/index.js +1 -1
- package/lib/commands/tenant/members-list.js +1 -1
- package/lib/commands/tenant/shared.js +1 -1
- package/lib/commands/user-account/dingding-sandbox-bind.js +1 -1
- package/lib/commands/user-account/index.js +1 -1
- package/lib/commands/workspace/add.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/commands/workspace/remove.js +1 -1
- package/lib/config/deployment-sync.js +1 -1
- package/lib/config/domain-config.js +1 -1
- package/lib/config/project-domain-routing.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/cdn.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/paths.js +1 -1
- package/lib/constant/region.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/constant/routing-profile.js +1 -1
- package/lib/context/app-resolver.js +1 -1
- package/lib/context/auth-resolver.js +1 -1
- package/lib/context/config-loader.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/kb-search-client.js +1 -1
- package/lib/core/page/file-system.js +1 -1
- package/lib/core/page/hash.js +1 -1
- package/lib/core/page/lock.js +1 -1
- package/lib/core/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.d.ts +4 -4
- package/lib/generated/build-info.js +1 -1
- package/lib/generated/official-routing.js +1 -1
- package/lib/generated/routing-contract.js +1 -1
- package/lib/help.js +1 -1
- package/lib/postinstall.js +1 -1
- package/lib/runtime/confirmation.js +1 -1
- package/lib/runtime/event.js +1 -1
- package/lib/runtime/index.js +1 -1
- package/lib/runtime/queue.js +1 -1
- package/lib/runtime/resolve.js +1 -1
- package/lib/skills/builtin-skill.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/skills/skill-presence.js +1 -1
- package/lib/telemetry/cli-command-trace.js +1 -1
- package/lib/telemetry/cli-help-trace.js +1 -1
- package/lib/telemetry/ensure-cli-otel-config.js +1 -1
- package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
- package/lib/telemetry/send-cli-trace-log.js +1 -1
- package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/entity-with-id.js +1 -1
- package/lib/utils/file-utils.js +1 -1
- package/lib/utils/guides-cdn.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/is-non-interactive.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
- package/skills/rabetbase/SKILL.md +1 -1
- package/skills/rabetbase.manifest.json +3 -3
package/lib/runtime/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3c4b8d,_0x5e0112){const _0x34b5dc=a277_0x3ade,_0x573011=_0x3c4b8d();while(!![]){try{const _0x1dcda3=-parseInt(_0x34b5dc(0x1cc))/0x1*(parseInt(_0x34b5dc(0x1bc))/0x2)+-parseInt(_0x34b5dc(0x1b6))/0x3*(-parseInt(_0x34b5dc(0x1cb))/0x4)+parseInt(_0x34b5dc(0x1ab))/0x5+-parseInt(_0x34b5dc(0x1b5))/0x6+-parseInt(_0x34b5dc(0x1c3))/0x7*(parseInt(_0x34b5dc(0x1bb))/0x8)+-parseInt(_0x34b5dc(0x1c9))/0x9*(parseInt(_0x34b5dc(0x1c4))/0xa)+parseInt(_0x34b5dc(0x1ad))/0xb;if(_0x1dcda3===_0x5e0112)break;else _0x573011['push'](_0x573011['shift']());}catch(_0x11875c){_0x573011['push'](_0x573011['shift']());}}}(a277_0x51a6,0x8035a));import{buildConfigFromFlags,initGlobalEnvironment,isRoutingRecoveryService}from'../context.js';import{createPipelineEnv,createRabetbaseRunnerAdapter,finalizeRabetbaseRuntimeState,runCommand}from'../framework/runner.js';import{buildRabetbaseConfirmationRequest}from'../runtime/confirmation.js';import{canonicalRabetbaseOperation,createRabetbaseWriteMetadata}from'../runtime/event.js';import{runSerialized}from'../runtime/queue.js';function a277_0x51a6(){const _0x5aab78=['presentation','result','command','1363584zZFhWT','3SLSGfR','definition','stringify','signal','execute','8lrEmlE','48gmTIhg','reason','service','data','message','Rabetbase\x20invocation\x20aborted.','format','3712611qlABtO','884550Ngqttp','risk','dry-run','dryRun','high-risk-write','36ZkKYlt','isNonInteractive','3935092pfdOca','43388aZqpaf','yes','riskLevel','2982435cCzAOs','Rabetbase\x20invocation\x20completed\x20without\x20a\x20captured\x20command\x20result.','12074205eUEoUV','present','AbortError','rawFlags','args'];a277_0x51a6=function(){return _0x5aab78;};return a277_0x51a6();}import{resolveRabetbaseInvocation}from'../runtime/resolve.js';const defaultPresentation={'present'({result:_0x569c52,command:_0x3979d4,risk:_0x5ec43a,dryRun:_0x28cbcd}){const _0x226938=a277_0x3ade;return JSON[_0x226938(0x1b8)]({'ok':_0x569c52['ok'],'command':_0x3979d4,'risk':_0x5ec43a,..._0x28cbcd?{'dryRun':!![]}:{},..._0x569c52[_0x226938(0x1bf)]!==undefined?{'data':_0x569c52[_0x226938(0x1bf)]}:{},..._0x569c52[_0x226938(0x1c0)]?{'message':_0x569c52[_0x226938(0x1c0)]}:{}});}};export async function invokeRabetbase(_0x424490,_0x3e2c37){const _0x4252b2=a277_0x3ade;throwIfAborted(_0x3e2c37[_0x4252b2(0x1b9)]);const _0x13e2ad=await resolveRabetbaseInvocation(_0x424490),_0x23e177=canonicalRabetbaseOperation(_0x13e2ad[_0x4252b2(0x1b7)]);return await confirmWriteBeforeQueue(_0x13e2ad['definition'],_0x13e2ad[_0x4252b2(0x1b0)],_0x23e177,_0x3e2c37),runSerialized(async()=>{const _0x30ff47=_0x4252b2,_0x2300e5={};try{throwIfAborted(_0x3e2c37[_0x30ff47(0x1b9)]);const _0x312298=buildConfigFromFlags(_0x13e2ad[_0x30ff47(0x1b0)]);!isRoutingRecoveryService(_0x13e2ad['definition'][_0x30ff47(0x1be)])&&await initGlobalEnvironment(_0x312298);const _0x2f5df9=createPipelineEnv(_0x312298,{..._0x13e2ad[_0x30ff47(0x1b0)],'yes':_0x13e2ad[_0x30ff47(0x1b7)]['risk']===_0x30ff47(0x1c8)?!![]:_0x13e2ad[_0x30ff47(0x1b0)][_0x30ff47(0x1a9)],'nonInteractive':!![]},_0x13e2ad[_0x30ff47(0x1b1)]);_0x2f5df9[_0x30ff47(0x1ca)]=!![],_0x2f5df9[_0x30ff47(0x1aa)]=_0x30ff47(0x1c8);const _0x2ceab8=withAbortSignal(_0x13e2ad[_0x30ff47(0x1b7)],_0x3e2c37[_0x30ff47(0x1b9)]),_0x1f1cd7=createRabetbaseRunnerAdapter({'formatOutput'(_0x2f1f9e,_0x11a6a7){const _0x26544c=_0x30ff47;_0x2300e5[_0x26544c(0x1b3)]=_0x2f1f9e,_0x2300e5[_0x26544c(0x1b4)]=_0x11a6a7[_0x26544c(0x1b4)],_0x2300e5[_0x26544c(0x1c5)]=_0x11a6a7['risk'],_0x2300e5[_0x26544c(0x1c2)]=_0x11a6a7['format'],_0x2300e5[_0x26544c(0x1c7)]=_0x11a6a7[_0x26544c(0x1c7)]===!![];},async 'confirmHighRisk'(){throw new Error('Embedded\x20Rabetbase\x20confirmation\x20must\x20run\x20before\x20the\x20execution\x20queue.');}});await runCommand(_0x2ceab8,_0x2f5df9,_0x1f1cd7);if(!_0x2300e5[_0x30ff47(0x1b3)]||!_0x2300e5[_0x30ff47(0x1b4)]||!_0x2300e5[_0x30ff47(0x1c5)]||!_0x2300e5[_0x30ff47(0x1c2)])throw new Error(_0x30ff47(0x1ac));const _0x4295ee=_0x2300e5[_0x30ff47(0x1c7)]===!![],_0x34a122=_0x3e2c37[_0x30ff47(0x1b2)]??defaultPresentation,_0x1dc488={'result':_0x2300e5[_0x30ff47(0x1b3)],'command':_0x2300e5[_0x30ff47(0x1b4)],'operation':_0x23e177,'risk':_0x2300e5[_0x30ff47(0x1c5)],'format':_0x2300e5[_0x30ff47(0x1c2)],'dryRun':_0x4295ee},_0x5ed617=createRabetbaseWriteMetadata(_0x13e2ad[_0x30ff47(0x1b7)],_0x23e177,_0x2300e5[_0x30ff47(0x1b3)],_0x4295ee);let _0x5b9084;try{_0x5b9084=await _0x34a122[_0x30ff47(0x1ae)](_0x1dc488);}catch(_0x315c6d){if(!_0x5ed617||_0x34a122===defaultPresentation)throw _0x315c6d;_0x5b9084=await defaultPresentation[_0x30ff47(0x1ae)](_0x1dc488);}return{'operation':_0x23e177,'risk':_0x2300e5[_0x30ff47(0x1c5)],'mode':_0x4295ee?_0x30ff47(0x1c6):'execute','result':_0x2300e5['result'],'output':_0x5b9084,..._0x5ed617?{'metadata':_0x5ed617}:{}};}finally{await finalizeRabetbaseRuntimeState();}});}function a277_0x3ade(_0x39fe14,_0x2fa8fd){_0x39fe14=_0x39fe14-0x1a9;const _0x51a69a=a277_0x51a6();let _0x3ade70=_0x51a69a[_0x39fe14];return _0x3ade70;}async function confirmWriteBeforeQueue(_0xe74cbd,_0x1faf8e,_0x33cf2b,_0x2ae3cb){const _0x4f163d=a277_0x3ade;if(_0x1faf8e[_0x4f163d(0x1c7)]===!![]||_0xe74cbd[_0x4f163d(0x1c5)]!=='write'&&_0xe74cbd[_0x4f163d(0x1c5)]!==_0x4f163d(0x1c8))return;await _0x2ae3cb['confirmation']['confirm'](buildRabetbaseConfirmationRequest(_0xe74cbd,_0x33cf2b,_0x2ae3cb[_0x4f163d(0x1b9)]));}function withAbortSignal(_0x39254c,_0x348c0a){return{..._0x39254c,async 'execute'(_0x3c61c6){const _0x5a63f1=a277_0x3ade;return throwIfAborted(_0x348c0a),_0x39254c[_0x5a63f1(0x1ba)]({..._0x3c61c6,'signal':_0x348c0a});}};}function throwIfAborted(_0x110d44){const _0x255b53=a277_0x3ade;if(_0x110d44?.['aborted'])throw _0x110d44[_0x255b53(0x1bd)]instanceof Error?_0x110d44[_0x255b53(0x1bd)]:new DOMException(_0x255b53(0x1c1),_0x255b53(0x1af));}
|
package/lib/runtime/queue.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a278_0x29f2(){const _0x14f46a=['1557960pvJIDE','11ZAvcfW','1145121DiahJz','7lMDBKO','14920767hMPrtX','1718660XNPSNU','2974794hSqMpq','resolve','7561688uRavBz','catch','15942mqNQFa'];a278_0x29f2=function(){return _0x14f46a;};return a278_0x29f2();}const a278_0xd913d1=a278_0x3cdd;(function(_0x4569aa,_0x371df3){const _0x5db6c5=a278_0x3cdd,_0x170e1d=_0x4569aa();while(!![]){try{const _0x5ce47f=-parseInt(_0x5db6c5(0x1d2))/0x1*(-parseInt(_0x5db6c5(0x1db))/0x2)+-parseInt(_0x5db6c5(0x1d3))/0x3+parseInt(_0x5db6c5(0x1dc))/0x4+parseInt(_0x5db6c5(0x1d6))/0x5+-parseInt(_0x5db6c5(0x1d7))/0x6+-parseInt(_0x5db6c5(0x1d4))/0x7*(parseInt(_0x5db6c5(0x1d9))/0x8)+parseInt(_0x5db6c5(0x1d5))/0x9;if(_0x5ce47f===_0x371df3)break;else _0x170e1d['push'](_0x170e1d['shift']());}catch(_0x39d8fb){_0x170e1d['push'](_0x170e1d['shift']());}}}(a278_0x29f2,0xa02b1));let tail=Promise[a278_0xd913d1(0x1d8)]();function a278_0x3cdd(_0xf013ee,_0x45bfbf){_0xf013ee=_0xf013ee-0x1d2;const _0x29f223=a278_0x29f2();let _0x3cddc4=_0x29f223[_0xf013ee];return _0x3cddc4;}export async function runSerialized(_0x5e2cd4){const _0x29176d=a278_0xd913d1,_0x9796ca=tail;let _0x4f7c22;tail=new Promise(_0x3a844e=>{_0x4f7c22=_0x3a844e;}),await _0x9796ca[_0x29176d(0x1da)](()=>undefined);try{return await _0x5e2cd4();}finally{_0x4f7c22();}}
|
package/lib/runtime/resolve.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x569f8c,_0x10d410){const _0x23b1d1=a279_0x2b80,_0x1069de=_0x569f8c();while(!![]){try{const _0x48006e=parseInt(_0x23b1d1(0x16b))/0x1+parseInt(_0x23b1d1(0x169))/0x2*(parseInt(_0x23b1d1(0x159))/0x3)+-parseInt(_0x23b1d1(0x16a))/0x4+parseInt(_0x23b1d1(0x163))/0x5+-parseInt(_0x23b1d1(0x158))/0x6*(parseInt(_0x23b1d1(0x15b))/0x7)+parseInt(_0x23b1d1(0x162))/0x8*(-parseInt(_0x23b1d1(0x15e))/0x9)+-parseInt(_0x23b1d1(0x16e))/0xa*(-parseInt(_0x23b1d1(0x16c))/0xb);if(_0x48006e===_0x10d410)break;else _0x1069de['push'](_0x1069de['shift']());}catch(_0x3d1a9f){_0x1069de['push'](_0x1069de['shift']());}}}(a279_0x5868,0x4ea79));import a279_0xb8ac18 from'meow';function a279_0x2b80(_0x44c5fe,_0x1e125b){_0x44c5fe=_0x44c5fe-0x158;const _0x58684c=a279_0x5868();let _0x2b802d=_0x58684c[_0x44c5fe];return _0x2b802d;}import{findDefinition,getServiceEntry,isKnownService,resolveRemovedCommand}from'../commands/registry.js';import{buildMeowFlags}from'../constant/cli.js';function a279_0x5868(){const _0x61b455=['Use\x20an\x20explicit\x20shell\x20tool\x20only\x20when\x20script\x20execution\x20is\x20intentionally\x20requested.','defaultCommand','input','Rabetbase\x20argv\x20must\x20include\x20a\x20service\x20and\x20command.','20SNbEFN','945556asGRBs','349368WMkUSB','11lGUfPF','Rabetbase\x20argv\x20must\x20include\x20a\x20command\x20for\x20service\x20\x22','5661870vMZHhq','18nJazeE','82155NpSSAU','`rabetbase\x20run`\x20is\x20unavailable\x20through\x20the\x20embedded\x20runtime\x20because\x20it\x20executes\x20arbitrary\x20package\x20scripts.','1230019ImPTeK','unknownCommand','wildcardDef','6984uFErWY','run','slice','validation','5728jEwyAS','2259600xPxEjY','join'];a279_0x5868=function(){return _0x61b455;};return a279_0x5868();}import{CliErrors}from'../errors.js';export async function resolveRabetbaseInvocation(_0x393b8d){const _0x123f8b=a279_0x2b80,_0x327d2a=a279_0xb8ac18('',{'importMeta':import.meta,'argv':[..._0x393b8d],'flags':buildMeowFlags(),'autoHelp':![],'autoVersion':![]}),_0x39ac04=[..._0x327d2a[_0x123f8b(0x167)]],_0x55f54d=_0x327d2a['flags'],_0x25fb46=_0x39ac04[0x0];if(!_0x25fb46)throw CliErrors[_0x123f8b(0x161)](_0x123f8b(0x168));const _0x4e862e=resolveRemovedCommand(_0x25fb46,_0x39ac04[0x1]);if(_0x4e862e)throw CliErrors[_0x123f8b(0x161)](_0x4e862e['message'],_0x4e862e['hint']);if(_0x25fb46===_0x123f8b(0x15f))throw CliErrors['validation'](_0x123f8b(0x15a),_0x123f8b(0x165));if(!isKnownService(_0x25fb46))throw CliErrors['unknownCommand'](_0x39ac04[_0x123f8b(0x164)]('\x20'));const _0x355413=getServiceEntry(_0x25fb46),_0x38c148=_0x39ac04[0x1],_0x883c7e=_0x38c148||_0x355413[_0x123f8b(0x166)];if(!_0x883c7e){if(_0x355413[_0x123f8b(0x15d)])return{'definition':_0x355413[_0x123f8b(0x15d)],'rawFlags':_0x55f54d,'args':[]};throw CliErrors[_0x123f8b(0x161)](_0x123f8b(0x16d)+_0x25fb46+'\x22.');}const _0x2d9803=findDefinition(_0x25fb46,_0x883c7e);if(_0x2d9803)return{'definition':_0x2d9803,'rawFlags':_0x55f54d,'args':_0x39ac04[_0x123f8b(0x160)](0x2)};if(_0x355413[_0x123f8b(0x15d)])return{'definition':_0x355413[_0x123f8b(0x15d)],'rawFlags':_0x55f54d,'args':[_0x883c7e,..._0x39ac04['slice'](0x2)]};throw CliErrors[_0x123f8b(0x15c)](_0x25fb46+'\x20'+_0x883c7e);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a281_0x626aeb=a281_0x3dc8;(function(_0xf90695,_0x4b8806){const _0x3c8e02=a281_0x3dc8,_0x1ebe6c=_0xf90695();while(!![]){try{const _0x4330c5=parseInt(_0x3c8e02(0x1b1))/0x1+parseInt(_0x3c8e02(0x1d3))/0x2*(-parseInt(_0x3c8e02(0x1b4))/0x3)+parseInt(_0x3c8e02(0x1d8))/0x4*(-parseInt(_0x3c8e02(0x1a1))/0x5)+parseInt(_0x3c8e02(0x1d2))/0x6+-parseInt(_0x3c8e02(0x1cf))/0x7*(parseInt(_0x3c8e02(0x1a2))/0x8)+parseInt(_0x3c8e02(0x1cd))/0x9*(-parseInt(_0x3c8e02(0x1c3))/0xa)+parseInt(_0x3c8e02(0x1be))/0xb*(parseInt(_0x3c8e02(0x1b8))/0xc);if(_0x4330c5===_0x4b8806)break;else _0x1ebe6c['push'](_0x1ebe6c['shift']());}catch(_0x360f90){_0x1ebe6c['push'](_0x1ebe6c['shift']());}}}(a281_0x3568,0x331f0));import{createHash}from'node:crypto';import{lstatSync,readFileSync,readdirSync}from'node:fs';import{homedir}from'node:os';import{dirname,join,relative,resolve,sep}from'node:path';import{fileURLToPath}from'node:url';import{runNpxSkillsAddGlobal}from'../skills/npx-skills-add.js';import{resolveInstalledSkill}from'../skills/skill-presence.js';const DEFAULT_PACKAGE_ROOT=resolve(dirname(fileURLToPath(import.meta.url)),'..','..'),REPAIR_COMMAND=a281_0x626aeb(0x1c1),SKILL_NAME=a281_0x626aeb(0x1c5);function frontmatterValue(_0x4ed9ac,_0x39ad23){const _0x457e23=a281_0x626aeb;return _0x4ed9ac[_0x457e23(0x1db)](new RegExp('^'+_0x39ad23+_0x457e23(0x1b0),'m'))?.[0x1]?.[_0x457e23(0x1a7)]()??'';}function listFiles(_0x47ff05,_0x1431e2=_0x47ff05){const _0x298853=a281_0x626aeb;return readdirSync(_0x1431e2,{'withFileTypes':!![]})['flatMap'](_0x262470=>{const _0x31c1b7=a281_0x3dc8,_0x2be21f=join(_0x1431e2,_0x262470['name']),_0xe4c51=lstatSync(_0x2be21f);if(_0xe4c51[_0x31c1b7(0x1a3)]())throw new Error('Symbolic\x20link\x20is\x20not\x20allowed:\x20'+_0x2be21f);if(_0xe4c51[_0x31c1b7(0x1bd)]())return listFiles(_0x47ff05,_0x2be21f);if(!_0xe4c51[_0x31c1b7(0x1bf)]())throw new Error(_0x31c1b7(0x19f)+_0x2be21f);return[relative(_0x47ff05,_0x2be21f)[_0x31c1b7(0x1a9)](sep)[_0x31c1b7(0x1da)]('/')];})[_0x298853(0x1d6)]((_0x42a0a6,_0x4a5692)=>_0x42a0a6<_0x4a5692?-0x1:_0x42a0a6>_0x4a5692?0x1:0x0);}function digestFiles(_0xddecec,_0x3c7324){const _0x2e5d7a=a281_0x626aeb,_0x13bf0c=createHash(_0x2e5d7a(0x1c6));for(const _0x2c824d of _0x3c7324){if(_0x2c824d[_0x2e5d7a(0x1ab)]('/')||_0x2c824d[_0x2e5d7a(0x1a9)]('/')[_0x2e5d7a(0x1c8)]('..')||_0x2c824d[_0x2e5d7a(0x1c8)]('\x5c'))throw new Error('Unsafe\x20manifest\x20path:\x20'+_0x2c824d);_0x13bf0c[_0x2e5d7a(0x1ce)](_0x2c824d),_0x13bf0c[_0x2e5d7a(0x1ce)]('\x00'),_0x13bf0c[_0x2e5d7a(0x1ce)](readFileSync(join(_0xddecec,..._0x2c824d[_0x2e5d7a(0x1a9)]('/')))),_0x13bf0c[_0x2e5d7a(0x1ce)]('\x00');}return _0x13bf0c[_0x2e5d7a(0x1d9)](_0x2e5d7a(0x1ca));}function sameFiles(_0x308797,_0x5e9e31){const _0x4352de=a281_0x626aeb;return _0x308797[_0x4352de(0x1b2)]===_0x5e9e31[_0x4352de(0x1b2)]&&_0x308797[_0x4352de(0x1a0)]((_0x3b3594,_0x22c0a8)=>_0x3b3594===_0x5e9e31[_0x22c0a8]);}function readSource(_0x272ed5){const _0x44c7f4=a281_0x626aeb,_0x12e8b2=JSON['parse'](readFileSync(join(_0x272ed5,_0x44c7f4(0x1d1)),_0x44c7f4(0x1ad))),_0x74a42e=JSON['parse'](readFileSync(join(_0x272ed5,_0x44c7f4(0x1c0),'rabetbase.manifest.json'),_0x44c7f4(0x1ad))),_0x1d091f=join(_0x272ed5,_0x44c7f4(0x1c0),SKILL_NAME),_0x568d22=frontmatterValue(readFileSync(join(_0x1d091f,_0x44c7f4(0x1d7)),_0x44c7f4(0x1ad)),_0x44c7f4(0x1a5)),_0x2f7b4a=listFiles(_0x1d091f);if(_0x74a42e['schemaVersion']!==0x1||_0x74a42e[_0x44c7f4(0x1ae)]!==SKILL_NAME||!_0x12e8b2['version']||_0x74a42e['packageVersion']!==_0x12e8b2[_0x44c7f4(0x1a5)]||_0x74a42e['skillVersion']!==_0x12e8b2[_0x44c7f4(0x1a5)]||_0x568d22!==_0x12e8b2[_0x44c7f4(0x1a5)]||!sameFiles(_0x2f7b4a,_0x74a42e[_0x44c7f4(0x1c2)])||digestFiles(_0x1d091f,_0x2f7b4a)!==_0x74a42e[_0x44c7f4(0x1d9)])throw new Error(_0x44c7f4(0x1b5));return{'packageVersion':_0x12e8b2['version'],'skillVersion':_0x568d22,'root':_0x1d091f,'manifest':_0x74a42e};}function a281_0x3568(){const _0x346764=['3570ezjrXs','1347816cZhqpN','isSymbolicLink','path','version','INSTALL_FAILED','trim','installedPath','split','unknown','startsWith','skillVersion','utf8','name','manifest',':\x5cs*(.+)$','10236yBsoFX','length','Installed\x20Skill\x20state\x20is\x20','4833FCMxnT','Built-in\x20Skill\x20source\x20does\x20not\x20match\x20its\x20package\x20manifest','status','packageVersion','84BlgeNR','state','root','message','home','isDirectory','2231768bLOkIJ','isFile','skills','rabetbase\x20cli-skill\x20install','files','10fTpRhj','absent','rabetbase','sha256','reason','includes','version_mismatch','hex','unverifiable','current','3060648DhoKUf','update','14OqyyEP','present','package.json','302424gWHyef','332lkmdIH','pipe','missing','sort','SKILL.md','1832IRaeOS','digest','join','match','Unsupported\x20Skill\x20entry:\x20','every'];a281_0x3568=function(){return _0x346764;};return a281_0x3568();}function installedSkillPath(_0x3ad58e){const _0x1c256f=a281_0x626aeb,_0x20cf60=resolveInstalledSkill(SKILL_NAME,{'home':_0x3ad58e});if(_0x20cf60[_0x1c256f(0x1b9)]===_0x1c256f(0x1d0))return{'state':_0x1c256f(0x1d0),'path':dirname(_0x20cf60[_0x1c256f(0x1a4)])};if(_0x20cf60[_0x1c256f(0x1b9)]===_0x1c256f(0x1c4))return{'state':_0x1c256f(0x1d5)};return{'state':_0x1c256f(0x1cb),'reason':_0x20cf60[_0x1c256f(0x1c7)]};}export function inspectInstalledBuiltinSkillVersion(_0x1b3750,_0x5bf0f8={}){const _0x3f7d1c=a281_0x626aeb,_0x2378b4=installedSkillPath(_0x5bf0f8[_0x3f7d1c(0x1bc)]??homedir());if(_0x2378b4[_0x3f7d1c(0x1b9)]==='missing')return{'state':_0x3f7d1c(0x1d5),'expectedVersion':_0x1b3750,'repairCommand':REPAIR_COMMAND};if(_0x2378b4[_0x3f7d1c(0x1b9)]==='unverifiable')return{'state':_0x3f7d1c(0x1cb),'expectedVersion':_0x1b3750,'reason':_0x2378b4[_0x3f7d1c(0x1c7)],'repairCommand':REPAIR_COMMAND};try{const _0x33dd46=frontmatterValue(readFileSync(join(_0x2378b4[_0x3f7d1c(0x1a4)],_0x3f7d1c(0x1d7)),_0x3f7d1c(0x1ad)),_0x3f7d1c(0x1a5));return{'state':_0x33dd46===_0x1b3750?_0x3f7d1c(0x1cc):_0x3f7d1c(0x1c9),'expectedVersion':_0x1b3750,'skillVersion':_0x33dd46,'installedPath':_0x2378b4[_0x3f7d1c(0x1a4)],'repairCommand':REPAIR_COMMAND};}catch(_0x56e5ba){return{'state':_0x3f7d1c(0x1cb),'expectedVersion':_0x1b3750,'installedPath':_0x2378b4[_0x3f7d1c(0x1a4)],'reason':_0x56e5ba instanceof Error?_0x56e5ba[_0x3f7d1c(0x1bb)]:String(_0x56e5ba),'repairCommand':REPAIR_COMMAND};}}export function inspectBuiltinSkill(_0x5b4305={}){const _0x18f628=a281_0x626aeb,_0x2f136b=_0x5b4305['packageRoot']??DEFAULT_PACKAGE_ROOT;let _0x59012d;try{_0x59012d=readSource(_0x2f136b);}catch(_0x4ba396){return{'state':'unverifiable','packageVersion':_0x18f628(0x1aa),'reason':_0x4ba396 instanceof Error?_0x4ba396[_0x18f628(0x1bb)]:String(_0x4ba396),'repairCommand':REPAIR_COMMAND};}const _0xba3dd5=installedSkillPath(_0x5b4305[_0x18f628(0x1bc)]??homedir());if(_0xba3dd5['state']===_0x18f628(0x1d5))return{'state':'missing','packageVersion':_0x59012d[_0x18f628(0x1b7)],'repairCommand':REPAIR_COMMAND};if(_0xba3dd5[_0x18f628(0x1b9)]==='unverifiable')return{'state':_0x18f628(0x1cb),'packageVersion':_0x59012d[_0x18f628(0x1b7)],'reason':_0xba3dd5[_0x18f628(0x1c7)],'repairCommand':REPAIR_COMMAND};try{const _0x268546=frontmatterValue(readFileSync(join(_0xba3dd5[_0x18f628(0x1a4)],_0x18f628(0x1d7)),_0x18f628(0x1ad)),_0x18f628(0x1a5));if(_0x268546!==_0x59012d['skillVersion'])return{'state':_0x18f628(0x1c9),'packageVersion':_0x59012d[_0x18f628(0x1b7)],'skillVersion':_0x268546,'installedPath':_0xba3dd5[_0x18f628(0x1a4)],'repairCommand':REPAIR_COMMAND};const _0x3f6e00=listFiles(_0xba3dd5[_0x18f628(0x1a4)]),_0x47578e=digestFiles(_0xba3dd5['path'],_0x3f6e00);return{'state':sameFiles(_0x3f6e00,_0x59012d[_0x18f628(0x1af)]['files'])&&_0x47578e===_0x59012d['manifest'][_0x18f628(0x1d9)]?'current':'content_mismatch','packageVersion':_0x59012d[_0x18f628(0x1b7)],'skillVersion':_0x268546,'installedPath':_0xba3dd5[_0x18f628(0x1a4)],'digest':_0x47578e,'repairCommand':REPAIR_COMMAND};}catch(_0x1528f7){return{'state':_0x18f628(0x1cb),'packageVersion':_0x59012d[_0x18f628(0x1b7)],'installedPath':_0xba3dd5[_0x18f628(0x1a4)],'reason':_0x1528f7 instanceof Error?_0x1528f7[_0x18f628(0x1bb)]:String(_0x1528f7),'repairCommand':REPAIR_COMMAND};}}function a281_0x3dc8(_0x440899,_0x12f0f6){_0x440899=_0x440899-0x19f;const _0x3568b2=a281_0x3568();let _0x3dc899=_0x3568b2[_0x440899];return _0x3dc899;}function failure(_0x4a9ce2,_0x464abf,_0x292278,_0x4193c0){const _0x134b13=a281_0x626aeb;return{'ok':![],'code':_0x4a9ce2,'packageVersion':_0x464abf['packageVersion'],'skillVersion':_0x464abf[_0x134b13(0x1ac)],'installedPath':_0x4193c0,'changed':![],'repairCommand':REPAIR_COMMAND,'error':_0x292278 instanceof Error?_0x292278[_0x134b13(0x1bb)]:String(_0x292278)};}export function installBuiltinSkill(_0x691a2b={}){const _0x3bc0e4=a281_0x626aeb,_0x190ae6=_0x691a2b['packageRoot']??DEFAULT_PACKAGE_ROOT,_0x58ead5=_0x691a2b[_0x3bc0e4(0x1bc)]??homedir();let _0x252eb3;try{_0x252eb3=readSource(_0x190ae6);}catch(_0x3d8dbc){return failure('SOURCE_INVALID',{'packageVersion':_0x3bc0e4(0x1aa),'skillVersion':_0x3bc0e4(0x1aa)},_0x3d8dbc);}const _0x215a46=inspectBuiltinSkill({'packageRoot':_0x190ae6,'home':_0x58ead5}),_0x24f938=runNpxSkillsAddGlobal(_0x190ae6,_0x252eb3[_0x3bc0e4(0x1ba)],{'stdio':_0x691a2b['stdio']??_0x3bc0e4(0x1d4),'expectedSkillName':SKILL_NAME,'presence':{'home':_0x58ead5}});if(_0x24f938['skipped'])return{'ok':!![],'packageVersion':_0x252eb3[_0x3bc0e4(0x1b7)],'skillVersion':_0x252eb3[_0x3bc0e4(0x1ac)],'installedPath':_0x215a46[_0x3bc0e4(0x1a8)],'changed':![],'repairCommand':REPAIR_COMMAND};if(!_0x24f938['ok'])return failure(_0x3bc0e4(0x1a6),_0x252eb3,_0x24f938['error']??'skills@latest\x20exited\x20'+_0x24f938[_0x3bc0e4(0x1b6)]);const _0x4e495f=inspectBuiltinSkill({'packageRoot':_0x190ae6,'home':_0x58ead5});if(_0x4e495f[_0x3bc0e4(0x1b9)]!==_0x3bc0e4(0x1cc))return failure('VERIFY_FAILED',_0x252eb3,_0x4e495f['reason']??_0x3bc0e4(0x1b3)+_0x4e495f[_0x3bc0e4(0x1b9)],_0x4e495f[_0x3bc0e4(0x1a8)]);return{'ok':!![],'packageVersion':_0x252eb3[_0x3bc0e4(0x1b7)],'skillVersion':_0x252eb3['skillVersion'],'installedPath':_0x4e495f[_0x3bc0e4(0x1a8)],'changed':_0x215a46['state']!=='current','repairCommand':REPAIR_COMMAND};}
|
|
1
|
+
const a281_0x52e31c=a281_0x2343;(function(_0x51c85d,_0x4ff2ac){const _0x39f72a=a281_0x2343,_0x42065a=_0x51c85d();while(!![]){try{const _0x16c410=parseInt(_0x39f72a(0x1c1))/0x1*(-parseInt(_0x39f72a(0x193))/0x2)+parseInt(_0x39f72a(0x1ba))/0x3*(parseInt(_0x39f72a(0x1b8))/0x4)+parseInt(_0x39f72a(0x1b7))/0x5+-parseInt(_0x39f72a(0x1bf))/0x6+parseInt(_0x39f72a(0x1af))/0x7+parseInt(_0x39f72a(0x1b4))/0x8+-parseInt(_0x39f72a(0x1a7))/0x9;if(_0x16c410===_0x4ff2ac)break;else _0x42065a['push'](_0x42065a['shift']());}catch(_0x2d6093){_0x42065a['push'](_0x42065a['shift']());}}}(a281_0x4ac5,0x188dd));function a281_0x4ac5(){const _0x929995=['update','current','includes','hex','home','digest','Unsupported\x20Skill\x20entry:\x20','Symbolic\x20link\x20is\x20not\x20allowed:\x20','Installed\x20Skill\x20state\x20is\x20','length','packageRoot','sha256','unverifiable','46zCTNTk','SKILL.md','content_mismatch','message','files','pipe','split','trim','INSTALL_FAILED','join','manifest','missing','name','unknown','rabetbase.manifest.json','version_mismatch','installedPath','isFile','skillVersion','utf8','179811urquIa','version','startsWith','isDirectory','reason','packageVersion','VERIFY_FAILED','skills@latest\x20exited\x20','627725XUnXmh',':\x5cs*(.+)$','Built-in\x20Skill\x20source\x20does\x20not\x20match\x20its\x20package\x20manifest','isSymbolicLink','root','420416JsPEnu','rabetbase','rabetbase\x20cli-skill\x20install','112845RVhSlX','72836sETGpg','stdio','6FCmlxi','schemaVersion','state','SOURCE_INVALID','present','416214cnPTKY','Unsafe\x20manifest\x20path:\x20','491ZxPckc','flatMap','absent','parse','path'];a281_0x4ac5=function(){return _0x929995;};return a281_0x4ac5();}import{createHash}from'node:crypto';import{lstatSync,readFileSync,readdirSync}from'node:fs';import{homedir}from'node:os';import{dirname,join,relative,resolve,sep}from'node:path';import{fileURLToPath}from'node:url';import{runNpxSkillsAddGlobal}from'../skills/npx-skills-add.js';import{resolveInstalledSkill}from'../skills/skill-presence.js';const DEFAULT_PACKAGE_ROOT=resolve(dirname(fileURLToPath(import.meta.url)),'..','..'),REPAIR_COMMAND=a281_0x52e31c(0x1b6),SKILL_NAME=a281_0x52e31c(0x1b5);function frontmatterValue(_0x37609c,_0xcf6ac7){const _0x4bc2df=a281_0x52e31c;return _0x37609c['match'](new RegExp('^'+_0xcf6ac7+_0x4bc2df(0x1b0),'m'))?.[0x1]?.[_0x4bc2df(0x19a)]()??'';}function listFiles(_0x358aee,_0xcc5c55=_0x358aee){const _0x5724e9=a281_0x52e31c;return readdirSync(_0xcc5c55,{'withFileTypes':!![]})[_0x5724e9(0x1c2)](_0x408883=>{const _0x55acad=_0x5724e9,_0x42f117=join(_0xcc5c55,_0x408883[_0x55acad(0x19f)]),_0x1c9d32=lstatSync(_0x42f117);if(_0x1c9d32[_0x55acad(0x1b2)]())throw new Error(_0x55acad(0x18d)+_0x42f117);if(_0x1c9d32[_0x55acad(0x1aa)]())return listFiles(_0x358aee,_0x42f117);if(!_0x1c9d32[_0x55acad(0x1a4)]())throw new Error(_0x55acad(0x18c)+_0x42f117);return[relative(_0x358aee,_0x42f117)[_0x55acad(0x199)](sep)[_0x55acad(0x19c)]('/')];})['sort']((_0x3e7117,_0x4f86f8)=>_0x3e7117<_0x4f86f8?-0x1:_0x3e7117>_0x4f86f8?0x1:0x0);}function digestFiles(_0x2ae330,_0x26dfc4){const _0x121984=a281_0x52e31c,_0x2d1b57=createHash(_0x121984(0x191));for(const _0x4b03ae of _0x26dfc4){if(_0x4b03ae[_0x121984(0x1a9)]('/')||_0x4b03ae[_0x121984(0x199)]('/')[_0x121984(0x188)]('..')||_0x4b03ae[_0x121984(0x188)]('\x5c'))throw new Error(_0x121984(0x1c0)+_0x4b03ae);_0x2d1b57[_0x121984(0x1c6)](_0x4b03ae),_0x2d1b57[_0x121984(0x1c6)]('\x00'),_0x2d1b57[_0x121984(0x1c6)](readFileSync(join(_0x2ae330,..._0x4b03ae[_0x121984(0x199)]('/')))),_0x2d1b57[_0x121984(0x1c6)]('\x00');}return _0x2d1b57[_0x121984(0x18b)](_0x121984(0x189));}function a281_0x2343(_0x5d538a,_0x460e16){_0x5d538a=_0x5d538a-0x187;const _0x4ac5ac=a281_0x4ac5();let _0x23430c=_0x4ac5ac[_0x5d538a];return _0x23430c;}function sameFiles(_0x15021a,_0x271bc2){const _0xb5ca1e=a281_0x52e31c;return _0x15021a[_0xb5ca1e(0x18f)]===_0x271bc2[_0xb5ca1e(0x18f)]&&_0x15021a['every']((_0xabec,_0x39bfb0)=>_0xabec===_0x271bc2[_0x39bfb0]);}function readSource(_0x5e00aa){const _0xee1cf1=a281_0x52e31c,_0x1488d5=JSON[_0xee1cf1(0x1c4)](readFileSync(join(_0x5e00aa,'package.json'),_0xee1cf1(0x1a6))),_0x12614c=JSON[_0xee1cf1(0x1c4)](readFileSync(join(_0x5e00aa,'skills',_0xee1cf1(0x1a1)),_0xee1cf1(0x1a6))),_0xf9c206=join(_0x5e00aa,'skills',SKILL_NAME),_0x2b364e=frontmatterValue(readFileSync(join(_0xf9c206,_0xee1cf1(0x194)),_0xee1cf1(0x1a6)),'version'),_0x591eac=listFiles(_0xf9c206);if(_0x12614c[_0xee1cf1(0x1bb)]!==0x1||_0x12614c[_0xee1cf1(0x19f)]!==SKILL_NAME||!_0x1488d5[_0xee1cf1(0x1a8)]||_0x12614c[_0xee1cf1(0x1ac)]!==_0x1488d5[_0xee1cf1(0x1a8)]||_0x12614c[_0xee1cf1(0x1a5)]!==_0x1488d5[_0xee1cf1(0x1a8)]||_0x2b364e!==_0x1488d5[_0xee1cf1(0x1a8)]||!sameFiles(_0x591eac,_0x12614c[_0xee1cf1(0x197)])||digestFiles(_0xf9c206,_0x591eac)!==_0x12614c[_0xee1cf1(0x18b)])throw new Error(_0xee1cf1(0x1b1));return{'packageVersion':_0x1488d5[_0xee1cf1(0x1a8)],'skillVersion':_0x2b364e,'root':_0xf9c206,'manifest':_0x12614c};}function installedSkillPath(_0xfd4566){const _0x44322b=a281_0x52e31c,_0x373d85=resolveInstalledSkill(SKILL_NAME,{'home':_0xfd4566});if(_0x373d85[_0x44322b(0x1bc)]===_0x44322b(0x1be))return{'state':_0x44322b(0x1be),'path':dirname(_0x373d85['path'])};if(_0x373d85[_0x44322b(0x1bc)]===_0x44322b(0x1c3))return{'state':_0x44322b(0x19e)};return{'state':_0x44322b(0x192),'reason':_0x373d85[_0x44322b(0x1ab)]};}export function inspectInstalledBuiltinSkillVersion(_0x678e71,_0x12523f={}){const _0x500e00=a281_0x52e31c,_0x220342=installedSkillPath(_0x12523f['home']??homedir());if(_0x220342['state']==='missing')return{'state':'missing','expectedVersion':_0x678e71,'repairCommand':REPAIR_COMMAND};if(_0x220342[_0x500e00(0x1bc)]===_0x500e00(0x192))return{'state':'unverifiable','expectedVersion':_0x678e71,'reason':_0x220342[_0x500e00(0x1ab)],'repairCommand':REPAIR_COMMAND};try{const _0x12e71b=frontmatterValue(readFileSync(join(_0x220342[_0x500e00(0x1c5)],_0x500e00(0x194)),_0x500e00(0x1a6)),_0x500e00(0x1a8));return{'state':_0x12e71b===_0x678e71?_0x500e00(0x187):_0x500e00(0x1a2),'expectedVersion':_0x678e71,'skillVersion':_0x12e71b,'installedPath':_0x220342[_0x500e00(0x1c5)],'repairCommand':REPAIR_COMMAND};}catch(_0x5ea524){return{'state':_0x500e00(0x192),'expectedVersion':_0x678e71,'installedPath':_0x220342[_0x500e00(0x1c5)],'reason':_0x5ea524 instanceof Error?_0x5ea524[_0x500e00(0x196)]:String(_0x5ea524),'repairCommand':REPAIR_COMMAND};}}export function inspectBuiltinSkill(_0x54a032={}){const _0x5e4024=a281_0x52e31c,_0x33df33=_0x54a032[_0x5e4024(0x190)]??DEFAULT_PACKAGE_ROOT;let _0x288ddf;try{_0x288ddf=readSource(_0x33df33);}catch(_0x3c26a6){return{'state':_0x5e4024(0x192),'packageVersion':_0x5e4024(0x1a0),'reason':_0x3c26a6 instanceof Error?_0x3c26a6[_0x5e4024(0x196)]:String(_0x3c26a6),'repairCommand':REPAIR_COMMAND};}const _0x27b9c9=installedSkillPath(_0x54a032[_0x5e4024(0x18a)]??homedir());if(_0x27b9c9['state']===_0x5e4024(0x19e))return{'state':_0x5e4024(0x19e),'packageVersion':_0x288ddf['packageVersion'],'repairCommand':REPAIR_COMMAND};if(_0x27b9c9[_0x5e4024(0x1bc)]===_0x5e4024(0x192))return{'state':_0x5e4024(0x192),'packageVersion':_0x288ddf[_0x5e4024(0x1ac)],'reason':_0x27b9c9[_0x5e4024(0x1ab)],'repairCommand':REPAIR_COMMAND};try{const _0x1c2601=frontmatterValue(readFileSync(join(_0x27b9c9[_0x5e4024(0x1c5)],_0x5e4024(0x194)),_0x5e4024(0x1a6)),_0x5e4024(0x1a8));if(_0x1c2601!==_0x288ddf[_0x5e4024(0x1a5)])return{'state':_0x5e4024(0x1a2),'packageVersion':_0x288ddf[_0x5e4024(0x1ac)],'skillVersion':_0x1c2601,'installedPath':_0x27b9c9[_0x5e4024(0x1c5)],'repairCommand':REPAIR_COMMAND};const _0x4e2b0c=listFiles(_0x27b9c9['path']),_0x54616a=digestFiles(_0x27b9c9[_0x5e4024(0x1c5)],_0x4e2b0c);return{'state':sameFiles(_0x4e2b0c,_0x288ddf[_0x5e4024(0x19d)][_0x5e4024(0x197)])&&_0x54616a===_0x288ddf[_0x5e4024(0x19d)][_0x5e4024(0x18b)]?_0x5e4024(0x187):_0x5e4024(0x195),'packageVersion':_0x288ddf[_0x5e4024(0x1ac)],'skillVersion':_0x1c2601,'installedPath':_0x27b9c9['path'],'digest':_0x54616a,'repairCommand':REPAIR_COMMAND};}catch(_0x5e206c){return{'state':'unverifiable','packageVersion':_0x288ddf[_0x5e4024(0x1ac)],'installedPath':_0x27b9c9[_0x5e4024(0x1c5)],'reason':_0x5e206c instanceof Error?_0x5e206c[_0x5e4024(0x196)]:String(_0x5e206c),'repairCommand':REPAIR_COMMAND};}}function failure(_0x201501,_0xb2eea8,_0x325042,_0x27cf76){const _0x5241a8=a281_0x52e31c;return{'ok':![],'code':_0x201501,'packageVersion':_0xb2eea8[_0x5241a8(0x1ac)],'skillVersion':_0xb2eea8[_0x5241a8(0x1a5)],'installedPath':_0x27cf76,'changed':![],'repairCommand':REPAIR_COMMAND,'error':_0x325042 instanceof Error?_0x325042[_0x5241a8(0x196)]:String(_0x325042)};}export function installBuiltinSkill(_0x8604dc={}){const _0x53c091=a281_0x52e31c,_0x497f59=_0x8604dc[_0x53c091(0x190)]??DEFAULT_PACKAGE_ROOT,_0x39c959=_0x8604dc['home']??homedir();let _0x7cc479;try{_0x7cc479=readSource(_0x497f59);}catch(_0x36bf64){return failure(_0x53c091(0x1bd),{'packageVersion':_0x53c091(0x1a0),'skillVersion':_0x53c091(0x1a0)},_0x36bf64);}const _0x22f3e1=inspectBuiltinSkill({'packageRoot':_0x497f59,'home':_0x39c959}),_0x4fd6d6=runNpxSkillsAddGlobal(_0x497f59,_0x7cc479[_0x53c091(0x1b3)],{'stdio':_0x8604dc[_0x53c091(0x1b9)]??_0x53c091(0x198),'expectedSkillName':SKILL_NAME,'presence':{'home':_0x39c959}});if(_0x4fd6d6['skipped'])return{'ok':!![],'packageVersion':_0x7cc479[_0x53c091(0x1ac)],'skillVersion':_0x7cc479['skillVersion'],'installedPath':_0x22f3e1['installedPath'],'changed':![],'repairCommand':REPAIR_COMMAND};if(!_0x4fd6d6['ok'])return failure(_0x53c091(0x19b),_0x7cc479,_0x4fd6d6['error']??_0x53c091(0x1ae)+_0x4fd6d6['status']);const _0x564480=inspectBuiltinSkill({'packageRoot':_0x497f59,'home':_0x39c959});if(_0x564480[_0x53c091(0x1bc)]!==_0x53c091(0x187))return failure(_0x53c091(0x1ad),_0x7cc479,_0x564480[_0x53c091(0x1ab)]??_0x53c091(0x18e)+_0x564480[_0x53c091(0x1bc)],_0x564480[_0x53c091(0x1a3)]);return{'ok':!![],'packageVersion':_0x7cc479['packageVersion'],'skillVersion':_0x7cc479['skillVersion'],'installedPath':_0x564480[_0x53c091(0x1a3)],'changed':_0x22f3e1[_0x53c091(0x1bc)]!==_0x53c091(0x187),'repairCommand':REPAIR_COMMAND};}
|
package/lib/skills/main.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a282_0x4a08(){const _0x1ec100=['23176ViwTMI','Error:\x20Unsupported\x20command:\x20','423fMQrio','25809rDBpqh','\x0a\x0aNote:\x20cli-skill\x20install\x20uses\x20the\x20npm\x20package-local\x20Skill;\x20the\x20public\x20source\x20is\x20an\x20optional\x20latest\x20mirror.\x0a','enable-bff-save','setLogPath','help','startsWith','--help','4fmwGWs','push','318054WYAPHd','entries','-$1','error','argv','96tljlro','dangerously-bff-save','258DwpoLO','cwd','log','has','\x0aAvailable\x20commands:','add','skill','\x0aRabetbase\x20CLI\x20Skill\x20-\x20Developer\x20Workflow\x20Installation\x20Tool\x0a\x0aUsage:\x0a\x20\x20','exit','Unsupported\x20command:\x20','1074uVlKta','353300kQOtzy','1000WCFPEV','includes','1373870oLXcUz','52691rORBtH'];a282_0x4a08=function(){return _0x1ec100;};return a282_0x4a08();}(function(_0x3e6719,_0x243c66){const _0x46c9a7=a282_0x4cc0,_0x223ccc=_0x3e6719();while(!![]){try{const _0x1c7424=-parseInt(_0x46c9a7(0x76))/0x1+-parseInt(_0x46c9a7(0x73))/0x2*(parseInt(_0x46c9a7(0x71))/0x3)+-parseInt(_0x46c9a7(0x81))/0x4*(-parseInt(_0x46c9a7(0x75))/0x5)+parseInt(_0x46c9a7(0x67))/0x6*(parseInt(_0x46c9a7(0x7a))/0x7)+parseInt(_0x46c9a7(0x77))/0x8*(parseInt(_0x46c9a7(0x79))/0x9)+parseInt(_0x46c9a7(0x72))/0xa+parseInt(_0x46c9a7(0x83))/0xb*(-parseInt(_0x46c9a7(0x65))/0xc);if(_0x1c7424===_0x243c66)break;else _0x223ccc['push'](_0x223ccc['shift']());}catch(_0x47087b){_0x223ccc['push'](_0x223ccc['shift']());}}}(a282_0x4a08,0x229e9));import{logger}from'../utils/logger.js';import{CLI_BIN_NAME}from'../constant/cli.js';import{NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE}from'../skills/npx-skills-add.js';export function camelCaseFlagsToKebab(_0x4fa3b9){const _0x13d610=a282_0x4cc0,_0x37d9b0=[];for(const [_0x18870b,_0x1f9f9c]of Object[_0x13d610(0x84)](_0x4fa3b9)){if(_0x1f9f9c===!![]){const _0x4debc9=_0x18870b['replace'](/([A-Z])/g,_0x13d610(0x85))['toLowerCase']();_0x37d9b0['push'](_0x4debc9);}}return _0x37d9b0;}export function parseDynamicFlags(){const _0xd573db=a282_0x4cc0,_0x4d0917=[];for(let _0x53d6eb=0x3;_0x53d6eb<process[_0xd573db(0x87)]['length'];_0x53d6eb++){const _0x8b05af=process[_0xd573db(0x87)][_0x53d6eb];if(_0x8b05af&&_0x8b05af[_0xd573db(0x7f)]('--')){const _0x4e3981=_0x8b05af['slice'](0x2);_0x4e3981&&!_0x4e3981[_0xd573db(0x74)]('=')&&_0x4d0917[_0xd573db(0x82)](_0x4e3981);}}return _0x4d0917;}function a282_0x4cc0(_0x4d09f4,_0x382a6d){_0x4d09f4=_0x4d09f4-0x65;const _0x4a0805=a282_0x4a08();let _0x4cc02e=_0x4a0805[_0x4d09f4];return _0x4cc02e;}export function getAllProvidedFlags(_0x1c6219){const _0x59203f=camelCaseFlagsToKebab(_0x1c6219),_0xae7f91=parseDynamicFlags(),_0x4ac6d6=new Set([..._0x59203f,..._0xae7f91]);return Array['from'](_0x4ac6d6);}export function normalizeLegacyBffSaveFlags(_0x469d54){const _0x374a4d=a282_0x4cc0,_0x562a9a=new Set(_0x469d54);return _0x562a9a[_0x374a4d(0x6a)](_0x374a4d(0x66))&&_0x562a9a[_0x374a4d(0x6c)](_0x374a4d(0x7c)),Array['from'](_0x562a9a);}const SKILLS_INSTALL_COMMAND_LINE=NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE;export async function skillsCommand(_0x161134,_0x5933f7,_0x4583dc){const _0x10173f=a282_0x4cc0;logger[_0x10173f(0x7d)](process[_0x10173f(0x68)]());if(_0x4583dc?.[_0x10173f(0x7e)]||_0x161134===_0x10173f(0x80)){showHelp();return;}console[_0x10173f(0x86)](_0x10173f(0x78)+(_0x161134||'(empty)')),console[_0x10173f(0x69)](_0x10173f(0x6b)),console[_0x10173f(0x69)]('\x20\x20'+CLI_BIN_NAME+'\x20cli-skill\x20install\x20\x20\x20\x20\x20\x20\x20#\x20Install\x20CLI\x20Built-in\x20Skill'),console[_0x10173f(0x69)](''),console[_0x10173f(0x69)]('Public\x20Open\x20Skill\x20source:\x20'+SKILLS_INSTALL_COMMAND_LINE),logger[_0x10173f(0x86)](_0x10173f(0x6d),_0x10173f(0x70)+_0x161134),process[_0x10173f(0x6f)](0x1);}function showHelp(){const _0x4acb14=a282_0x4cc0;console['log'](_0x4acb14(0x6e)+CLI_BIN_NAME+'\x20cli-skill\x20install\x0a\x0aPublic\x20Open\x20Skill\x20source:\x20'+SKILLS_INSTALL_COMMAND_LINE+_0x4acb14(0x7b));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a283_0x489f3d=a283_0x1ab8;(function(_0x14c360,_0x283a8e){const _0x2ca375=a283_0x1ab8,_0x187281=_0x14c360();while(!![]){try{const _0x2e4fdf=-parseInt(_0x2ca375(0xcf))/0x1*(parseInt(_0x2ca375(0xe2))/0x2)+-parseInt(_0x2ca375(0xea))/0x3+parseInt(_0x2ca375(0xcc))/0x4+-parseInt(_0x2ca375(0xef))/0x5+parseInt(_0x2ca375(0xce))/0x6+parseInt(_0x2ca375(0xf3))/0x7*(parseInt(_0x2ca375(0xf7))/0x8)+-parseInt(_0x2ca375(0xca))/0x9*(-parseInt(_0x2ca375(0xe5))/0xa);if(_0x2e4fdf===_0x283a8e)break;else _0x187281['push'](_0x187281['shift']());}catch(_0x5a86e8){_0x187281['push'](_0x187281['shift']());}}}(a283_0x8365,0x225a7));import{spawnSync}from'node:child_process';import{resolveNpmBin}from'../utils/platform.js';import{resolveInstalledSkill}from'../skills/skill-presence.js';function a283_0x1ab8(_0x6dd4c8,_0x3b1d26){_0x6dd4c8=_0x6dd4c8-0xc1;const _0x836537=a283_0x8365();let _0x1ab804=_0x836537[_0x6dd4c8];return _0x1ab804;}export const NPX_FLAG_YES='-y';export const SKILLS_FLAG_GLOBAL='-g';export const SKILLS_FLAG_YES='-y';export const NPX_SKILLS_CLI=a283_0x489f3d(0xe9);export const NPX_SKILLS_SUBCOMMAND_ADD=a283_0x489f3d(0xd7);export const NPX_SKILLS_FLAG_SKILL='--skill';export const RABETBASE_SKILL_SOURCE='lovrabet/rabetbase';export const LEGACY_RABETBASE_SKILL_SOURCE=a283_0x489f3d(0xc8);export const DEFAULT_RABETBASE_SKILL_NAME=a283_0x489f3d(0xed);export const RABETBASE_GLOBAL_SKILL_NAME='rabetbase';export const RABETBASE_SKILL_GIT_SOURCE=a283_0x489f3d(0xd3);export function resolveGlobalSkillName(_0x2b7d2f){const _0x10c4e1=a283_0x489f3d;switch(_0x2b7d2f[_0x10c4e1(0xdc)]()){case RABETBASE_SKILL_SOURCE:case RABETBASE_SKILL_GIT_SOURCE:return RABETBASE_GLOBAL_SKILL_NAME;default:return undefined;}}export function buildNpxSkillsAddArgv(_0x323adb){const _0x59214a=a283_0x489f3d,_0x1daf35=[NPX_FLAG_YES,NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,RABETBASE_SKILL_SOURCE];return _0x323adb&&_0x1daf35[_0x59214a(0xd9)](NPX_SKILLS_FLAG_SKILL,_0x323adb),_0x1daf35;}export const NPX_SKILLS_ADD_COMMAND_LINE=[a283_0x489f3d(0xe8),...buildNpxSkillsAddArgv()]['join']('\x20');export const NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE=['npx',NPX_FLAG_YES,NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,RABETBASE_SKILL_SOURCE,SKILLS_FLAG_GLOBAL,SKILLS_FLAG_YES][a283_0x489f3d(0xd8)]('\x20');function a283_0x8365(){const _0x14a96b=['push','ENOENT','warn','trim','checked','Skill\x20\x22','!\x20Could\x20not\x20verify\x20\x22','stdout','EACCES','8392OvXSOt','CHILD_EXIT_NONZERO','remove','3830HRrkVl','stdio','message','npx','skills@latest','652992yZfDGX','NPM_CONFIG_GLOBAL','SPAWN_FAILED','Lovrabet','npx\x20terminated\x20by\x20signal\x20','1258415APuqAW','\x22\x20not\x20found\x20after\x20install\x20(checked\x20','error','code','1106PVopty','log','absent','Installer\x20reported\x20','5912uwsZEf','filter','expectedSkillName','unknown','SKILL_NOT_INSTALLED','reason','toString','INSTALL_PARTIAL','match','skill','status','lovrabet/lovrabet-skill','pipe','3573ZCVJaY','unverifiable','378192goIqWQ','inherit','1530534xFjFDd','2tlxfyz','NPX_NOT_FOUND','exit\x20','signal','git@codeup.aliyun.com:yuntoo/open/rabetbase-cli.git','state','yes','PERMISSION_DENIED','add','join'];a283_0x8365=function(){return _0x14a96b;};return a283_0x8365();}const CHILD_OUTPUT_MAX_BUFFER=0x10*0x400*0x400;function failure(_0x1421c2,_0xe73132,_0x44474d){return{'ok':![],'status':_0xe73132,'code':_0x1421c2,'error':'['+_0x1421c2+']\x20'+_0x44474d};}function spawnOptions(_0xf3eb85,_0x486010){const _0xcdf9ce=a283_0x489f3d,_0x57736c={...process.env};return delete _0x57736c['npm_config_global'],delete _0x57736c[_0xcdf9ce(0xeb)],{'cwd':_0xf3eb85,'stdio':_0x486010,'env':_0x57736c,'shell':![],..._0x486010===_0xcdf9ce(0xc9)?{'maxBuffer':CHILD_OUTPUT_MAX_BUFFER}:{}};}function normalizeSpawnResult(_0x1c9844,_0x2e8d2a,_0x3ba5f7,_0x48e0ab){const _0x6a396a=a283_0x489f3d,_0x47bc8a=[_0x1c9844['stdout']?_0x1c9844[_0x6a396a(0xe0)][_0x6a396a(0xc3)]():'',_0x1c9844['stderr']?_0x1c9844['stderr'][_0x6a396a(0xc3)]():''][_0x6a396a(0xf8)](Boolean)['join']('\x0a')[_0x6a396a(0xdc)]();_0x48e0ab!==_0x6a396a(0xc9)&&_0x47bc8a&&console[_0x6a396a(0xf4)](_0x47bc8a);if(_0x1c9844[_0x6a396a(0xf1)]){const _0x2bcd58=_0x1c9844[_0x6a396a(0xf1)],_0xff513f=_0x2bcd58[_0x6a396a(0xf2)]===_0x6a396a(0xda)?_0x6a396a(0xd0):_0x2bcd58[_0x6a396a(0xf2)]==='EPERM'||_0x2bcd58['code']===_0x6a396a(0xe1)?_0x6a396a(0xd6):_0x6a396a(0xec);return failure(_0xff513f,_0x1c9844[_0x6a396a(0xc7)],_0x2bcd58[_0x6a396a(0xe7)]);}if(_0x1c9844[_0x6a396a(0xd2)])return failure('CHILD_TERMINATED',_0x1c9844[_0x6a396a(0xc7)],_0x6a396a(0xee)+_0x1c9844[_0x6a396a(0xd2)]);if(_0x1c9844['status']!==0x0)return failure(_0x6a396a(0xe3),_0x1c9844['status'],_0x47bc8a||_0x6a396a(0xd1)+(_0x1c9844[_0x6a396a(0xc7)]??_0x6a396a(0xfa)));const _0x1e08d2=_0x2e8d2a?resolveInstalledSkill(_0x2e8d2a,_0x3ba5f7):undefined,_0x1d8d90=_0x47bc8a[_0x6a396a(0xc5)](/Failed to install\s+(\d+)/i);if(_0x1d8d90&&Number(_0x1d8d90[0x1])>0x0){const _0xa8613c=_0x6a396a(0xf6)+_0x1d8d90[0x1]+'\x20failed\x20target(s)'+(_0x47bc8a?':\x0a'+_0x47bc8a:'');if(_0x1e08d2?.[_0x6a396a(0xd4)]==='present')return console[_0x6a396a(0xdb)]('!\x20'+_0xa8613c),{'ok':!![],'status':0x0};return failure(_0x6a396a(0xc4),0x0,_0xa8613c);}if(_0x1e08d2){if(_0x1e08d2[_0x6a396a(0xd4)]===_0x6a396a(0xf5))return failure(_0x6a396a(0xc1),0x0,_0x6a396a(0xde)+_0x2e8d2a+_0x6a396a(0xf0)+_0x1e08d2[_0x6a396a(0xdd)][_0x6a396a(0xd8)](',\x20')+')');_0x1e08d2[_0x6a396a(0xd4)]===_0x6a396a(0xcb)&&console[_0x6a396a(0xdb)](_0x6a396a(0xdf)+_0x2e8d2a+'\x22\x20install\x20state:\x20'+_0x1e08d2[_0x6a396a(0xc2)]);}return{'ok':!![],'status':0x0};}export function shouldSkipNpxSkillsAdd(){return process.env.RABETBASE_SKIP_NPX_SKILLS==='1';}export function runNpxSkillsAdd(_0x42acc7,_0x4aaba8){const _0x2a6f3d=a283_0x489f3d;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x80432a=_0x4aaba8?.[_0x2a6f3d(0xe6)]??_0x2a6f3d(0xcd),_0xe43a5a=resolveNpmBin('npx'),_0x44d670=buildNpxSkillsAddArgv(_0x4aaba8?.[_0x2a6f3d(0xc6)]),_0x5f3206=['npx',..._0x44d670][_0x2a6f3d(0xd8)]('\x20');console[_0x2a6f3d(0xf4)]('*\x20'+_0x5f3206);const _0x556a8a=spawnSync(_0xe43a5a,_0x44d670,spawnOptions(_0x42acc7,_0x80432a));return normalizeSpawnResult(_0x556a8a,undefined,undefined,_0x80432a);}export function runNpxSkillsRemove(_0x17f346,_0x5cf982,_0x3486a5=LEGACY_RABETBASE_SKILL_SOURCE){const _0x4ca2f8=a283_0x489f3d;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x4e93c2=_0x5cf982?.['stdio']??'inherit',_0x554b26=resolveNpmBin(_0x4ca2f8(0xe8)),_0x5f2468=[NPX_FLAG_YES,NPX_SKILLS_CLI,_0x4ca2f8(0xe4),_0x3486a5,NPX_SKILLS_FLAG_SKILL,_0x5cf982?.[_0x4ca2f8(0xc6)]??DEFAULT_RABETBASE_SKILL_NAME,..._0x5cf982?.[_0x4ca2f8(0xd5)]?['-y']:[]],_0x2830d2=[_0x554b26,..._0x5f2468][_0x4ca2f8(0xd8)]('\x20');console[_0x4ca2f8(0xf4)]('*\x20'+_0x2830d2);const _0x270cad=spawnSync(_0x554b26,_0x5f2468,spawnOptions(_0x17f346,_0x4e93c2));return normalizeSpawnResult(_0x270cad,undefined,undefined,_0x4e93c2);}export function runNpxSkillsAddGlobal(_0x36d594,_0x257d47,_0x1bae31){const _0x3536aa=a283_0x489f3d;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x1f816a=resolveNpmBin(_0x3536aa(0xe8)),_0x469aa9=[NPX_FLAG_YES,NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,_0x257d47,SKILLS_FLAG_GLOBAL,SKILLS_FLAG_YES],_0x6b4d63=[_0x3536aa(0xe8),NPX_FLAG_YES,NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,_0x257d47,SKILLS_FLAG_GLOBAL,SKILLS_FLAG_YES][_0x3536aa(0xd8)]('\x20');console[_0x3536aa(0xf4)]('*\x20'+_0x6b4d63);const _0x40756b=spawnSync(_0x1f816a,_0x469aa9,spawnOptions(_0x36d594,'pipe'));return normalizeSpawnResult(_0x40756b,_0x1bae31?.[_0x3536aa(0xf9)]??resolveGlobalSkillName(_0x257d47),_0x1bae31?.['presence'],_0x1bae31?.['stdio']);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a284_0x595d65=a284_0x2834;(function(_0x816ab3,_0x4b3a19){const _0x1306a2=a284_0x2834,_0x892401=_0x816ab3();while(!![]){try{const _0x2a59a4=parseInt(_0x1306a2(0x1b6))/0x1*(-parseInt(_0x1306a2(0x1b8))/0x2)+-parseInt(_0x1306a2(0x1a9))/0x3*(-parseInt(_0x1306a2(0x1ca))/0x4)+parseInt(_0x1306a2(0x1be))/0x5+-parseInt(_0x1306a2(0x1bc))/0x6*(parseInt(_0x1306a2(0x1ae))/0x7)+parseInt(_0x1306a2(0x1bf))/0x8*(parseInt(_0x1306a2(0x1ad))/0x9)+parseInt(_0x1306a2(0x1b9))/0xa+parseInt(_0x1306a2(0x1c5))/0xb;if(_0x2a59a4===_0x4b3a19)break;else _0x892401['push'](_0x892401['shift']());}catch(_0x2b6dbf){_0x892401['push'](_0x892401['shift']());}}}(a284_0x3bf7,0xcef88));import{existsSync,readFileSync}from'node:fs';function a284_0x2834(_0x128bb8,_0x263138){_0x128bb8=_0x128bb8-0x1a9;const _0x3bf7d7=a284_0x3bf7();let _0x2834fb=_0x3bf7d7[_0x128bb8];return _0x2834fb;}import{homedir}from'node:os';import{join}from'node:path';export const SKILL_LOCK_RELATIVE_PATH=join(a284_0x595d65(0x1b3),a284_0x595d65(0x1c2));export const GLOBAL_SKILLS_DIR_RELATIVE_PATHS=[join(a284_0x595d65(0x1b3),a284_0x595d65(0x1cb)),join(a284_0x595d65(0x1bb),a284_0x595d65(0x1cb))];const SUPPORTED_LOCK_VERSIONS=[0x3];function readLockLookup(_0xdd5174,_0x491103){const _0x332008=a284_0x595d65;if(!existsSync(_0xdd5174))return{'kind':'not-recorded'};let _0x377fc;try{_0x377fc=JSON['parse'](readFileSync(_0xdd5174,_0x332008(0x1c6)));}catch(_0x2b2c31){return{'kind':'unusable','reason':_0xdd5174+_0x332008(0x1c3)+_0x2b2c31[_0x332008(0x1c9)]};}const _0x3226b6=_0x377fc;if(typeof _0x3226b6?.[_0x332008(0x1b7)]!==_0x332008(0x1c1)||!SUPPORTED_LOCK_VERSIONS[_0x332008(0x1af)](_0x3226b6[_0x332008(0x1b7)]))return{'kind':_0x332008(0x1b2),'reason':_0xdd5174+'\x20uses\x20unsupported\x20version\x20'+String(_0x3226b6?.['version'])};if(!_0x3226b6['skills']||typeof _0x3226b6['skills']!=='object')return{'kind':'unusable','reason':_0xdd5174+_0x332008(0x1b1)};return _0x3226b6[_0x332008(0x1cb)][_0x491103]?{'kind':_0x332008(0x1b4)}:{'kind':_0x332008(0x1bd)};}function a284_0x3bf7(){const _0x3589eb=['87360WMoMEs','present','.claude','342crsBUE','not-recorded','7775810HBaVWz','280AydtcW','\x22\x20but\x20no\x20SKILL.md\x20was\x20found\x20in\x20known\x20layouts\x20','number','.skill-lock.json','\x20is\x20unreadable:\x20','\x20records\x20\x22','932459uWhPtG','utf8','SKILL.md','map','message','156lkQvul','skills','69879URMbvr','find','absent','kind','216378PjeaBv','160867FWhZCu','includes','globalSkillsDirs','\x20has\x20no\x20skills\x20map','unusable','.agents','recorded','reason','1NNEPbF','version','2481790kxRxQt'];a284_0x3bf7=function(){return _0x3589eb;};return a284_0x3bf7();}export function resolveInstalledSkill(_0x2d20a0,_0x4ab89b){const _0x9a4413=a284_0x595d65,_0x58b3ba=_0x4ab89b?.['home']??homedir(),_0x3866db=_0x4ab89b?.[_0x9a4413(0x1b0)]??GLOBAL_SKILLS_DIR_RELATIVE_PATHS[_0x9a4413(0x1c8)](_0x17af30=>join(_0x58b3ba,_0x17af30)),_0x2dd8a9=_0x4ab89b?.['lockFile']??join(_0x58b3ba,SKILL_LOCK_RELATIVE_PATH),_0x306743=_0x3866db[_0x9a4413(0x1c8)](_0x449635=>join(_0x449635,_0x2d20a0,_0x9a4413(0x1c7))),_0x2ed034=_0x306743[_0x9a4413(0x1aa)](_0x7ca79e=>existsSync(_0x7ca79e));if(_0x2ed034)return{'state':_0x9a4413(0x1ba),'path':_0x2ed034};const _0x521df9=readLockLookup(_0x2dd8a9,_0x2d20a0);if(_0x521df9[_0x9a4413(0x1ac)]===_0x9a4413(0x1b2))return{'state':'unverifiable','reason':_0x521df9[_0x9a4413(0x1b5)]};if(_0x521df9[_0x9a4413(0x1ac)]===_0x9a4413(0x1b4))return{'state':'unverifiable','reason':_0x2dd8a9+_0x9a4413(0x1c4)+_0x2d20a0+_0x9a4413(0x1c0)+('('+_0x306743['join'](',\x20')+')')};return{'state':_0x9a4413(0x1ab),'checked':_0x306743};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x25ae58,_0x4a6dce){const _0x541b1c=a285_0x162c,_0x378566=_0x25ae58();while(!![]){try{const _0xae6733=-parseInt(_0x541b1c(0xae))/0x1+-parseInt(_0x541b1c(0xb2))/0x2+parseInt(_0x541b1c(0xa7))/0x3+parseInt(_0x541b1c(0xa5))/0x4*(parseInt(_0x541b1c(0xb4))/0x5)+-parseInt(_0x541b1c(0xa4))/0x6*(-parseInt(_0x541b1c(0xad))/0x7)+-parseInt(_0x541b1c(0xa6))/0x8*(-parseInt(_0x541b1c(0xab))/0x9)+parseInt(_0x541b1c(0xb3))/0xa;if(_0xae6733===_0x4a6dce)break;else _0x378566['push'](_0x378566['shift']());}catch(_0x34ae21){_0x378566['push'](_0x378566['shift']());}}}(a285_0x1153,0x8d878));import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';import{getCliVersion}from'../utils/version.js';const SENSITIVE_PATTERNS=[/cookie/i,/token/i,/password/i,/passwd/i,/secret/i,/auth/i,/session/i,/credential/i,/^value$/i];function isSensitiveKey(_0x37141f){const _0x1690db=a285_0x162c;return SENSITIVE_PATTERNS['some'](_0x7dcff9=>_0x7dcff9[_0x1690db(0xa3)](_0x37141f));}function sanitizeFlags(_0x5f1972){const _0x16e767=a285_0x162c,_0x4ef8af={};for(const [_0x3b5172,_0x5be299]of Object[_0x16e767(0xaa)](_0x5f1972)){isSensitiveKey(_0x3b5172)?_0x4ef8af[_0x3b5172]=_0x5be299!=null&&_0x5be299!==''?_0x16e767(0xa8):_0x5be299:_0x4ef8af[_0x3b5172]=_0x5be299;}return _0x4ef8af;}export async function reportCommandTrace(_0x24c788){const _0x4baa89=a285_0x162c;try{const _0x232bf2=sanitizeFlags(_0x24c788['flags']);await sendCliTraceLog({'spanName':'rabetbase.command','logData':{'command.cli_version':getCliVersion(),'command.service':_0x24c788[_0x4baa89(0xaf)],'command.name':_0x24c788[_0x4baa89(0xb1)],'command.flags':JSON[_0x4baa89(0xac)](_0x232bf2),..._0x24c788[_0x4baa89(0xa9)]!=null?{'command.duration_ms':_0x24c788[_0x4baa89(0xa9)]}:{},..._0x24c788[_0x4baa89(0xb0)]?{'command.error':_0x24c788[_0x4baa89(0xb0)]instanceof Error?_0x24c788[_0x4baa89(0xb0)]['message']:String(_0x24c788[_0x4baa89(0xb0)])}:{}}});}catch{}}function a285_0x162c(_0x5d20c2,_0x2c25e3){_0x5d20c2=_0x5d20c2-0xa3;const _0x11534d=a285_0x1153();let _0x162cc1=_0x11534d[_0x5d20c2];return _0x162cc1;}function a285_0x1153(){const _0x4075bc=['stringify','55951CyTPeG','987442qouaqB','service','error','command','1346046XqKouX','1308880GWZBeR','5rKCYiN','test','474bXWTTD','2884004Phaubu','288VgpMVS','545415pKrjXb','[REDACTED]','durationMs','entries','143757VFSCuA'];a285_0x1153=function(){return _0x4075bc;};return a285_0x1153();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a286_0x21ff(_0x7caf1e,_0x52d187){_0x7caf1e=_0x7caf1e-0xbc;var _0x227464=a286_0x2274();var _0x21ffbf=_0x227464[_0x7caf1e];return _0x21ffbf;}(function(_0x37e930,_0x1920c6){var _0x698b09=a286_0x21ff,_0x4324f2=_0x37e930();while(!![]){try{var _0x3e396e=-parseInt(_0x698b09(0xc2))/0x1+parseInt(_0x698b09(0xc5))/0x2+parseInt(_0x698b09(0xbf))/0x3*(parseInt(_0x698b09(0xbc))/0x4)+-parseInt(_0x698b09(0xbe))/0x5+-parseInt(_0x698b09(0xc1))/0x6*(-parseInt(_0x698b09(0xbd))/0x7)+parseInt(_0x698b09(0xc4))/0x8+parseInt(_0x698b09(0xc6))/0x9*(parseInt(_0x698b09(0xc7))/0xa);if(_0x3e396e===_0x1920c6)break;else _0x4324f2['push'](_0x4324f2['shift']());}catch(_0x3f1f20){_0x4324f2['push'](_0x4324f2['shift']());}}}(a286_0x2274,0x39484));import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';function a286_0x2274(){var _0x39d36a=['144ptKGDx','21440vZdFdV','15668XEVZor','21Wxamwk','825245lxWxxH','165vBnxXn','service','24558svgLhW','69562hqLWcP','error','1159600SIiLQK','124542HMcWuR'];a286_0x2274=function(){return _0x39d36a;};return a286_0x2274();}export async function reportCliHelpTrace(_0x4e8e40,_0x2b81de){var _0xe1ec67=a286_0x21ff;try{await sendCliTraceLog({'spanName':'cli.help','logData':{'rabetbase.help.kind':_0x4e8e40,..._0x2b81de?.[_0xe1ec67(0xc0)]&&{'rabetbase.help.service':_0x2b81de[_0xe1ec67(0xc0)]}}});}catch(_0xbbb2a5){console[_0xe1ec67(0xc3)]('Failed\x20to\x20report\x20CLI\x20help\x20trace:',_0xbbb2a5);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x154e17,_0x28af5e){const _0x550061=a287_0x276b,_0x2c6eb8=_0x154e17();while(!![]){try{const _0xa4cbd0=parseInt(_0x550061(0x1d9))/0x1*(-parseInt(_0x550061(0x1d0))/0x2)+-parseInt(_0x550061(0x1d5))/0x3*(parseInt(_0x550061(0x1d8))/0x4)+-parseInt(_0x550061(0x1db))/0x5+parseInt(_0x550061(0x1d2))/0x6*(-parseInt(_0x550061(0x1df))/0x7)+-parseInt(_0x550061(0x1da))/0x8*(-parseInt(_0x550061(0x1d7))/0x9)+-parseInt(_0x550061(0x1d1))/0xa*(-parseInt(_0x550061(0x1dd))/0xb)+parseInt(_0x550061(0x1d4))/0xc;if(_0xa4cbd0===_0x28af5e)break;else _0x2c6eb8['push'](_0x2c6eb8['shift']());}catch(_0x51da9a){_0x2c6eb8['push'](_0x2c6eb8['shift']());}}}(a287_0x2650,0x694f2));import{VERSION,GIT_COMMIT}from'../generated/build-info.js';import{getSessionUserInfo}from'../auth/get-session-user.js';import{setServiceConfig,setUserContext}from'@lovrabet/otel-logger';function a287_0x2650(){const _0x2e4e3c=['5731OckeKZ','unknown','7AIqKdS','tenant','production','email','tenant_code','nickname','45176sesxvx','2390HOyWVN','720102KWpDws','user','26022324wyfYlf','2343747MBaZsf','username','9hjrKjj','4WyvgUa','32lLYvfL','612568OcuCid','1570945jvFOMs','daily'];a287_0x2650=function(){return _0x2e4e3c;};return a287_0x2650();}import{NPM_PACKAGE_NAME}from'../constant/cli.js';import{getConfigAppCode}from'../utils/config.js';let cliOtelTraceInitialized=![];function a287_0x276b(_0x3760c2,_0x1cf48c){_0x3760c2=_0x3760c2-0x1cb;const _0x265060=a287_0x2650();let _0x276b1c=_0x265060[_0x3760c2];return _0x276b1c;}export async function ensureCliOtelTraceConfig(){const _0x49c257=a287_0x276b,_0x215582=await getSessionUserInfo();if(!cliOtelTraceInitialized){const _0x19ca0c=_0x215582?.[_0x49c257(0x1d3)];setServiceConfig({'serviceName':NPM_PACKAGE_NAME,'serviceVersion':GIT_COMMIT!==_0x49c257(0x1de)?VERSION+'+'+GIT_COMMIT:VERSION,'serviceEnv':process.env.RABETBASE_ENV??(process.env.RABETBASE_E2E_DAILY==='1'?_0x49c257(0x1dc):_0x49c257(0x1cc))}),setUserContext({'id':_0x19ca0c?.['id'],'username':_0x19ca0c?.[_0x49c257(0x1d6)],'nickname':_0x19ca0c?.[_0x49c257(0x1cf)],'email':_0x19ca0c?.[_0x49c257(0x1cd)],'tenantCode':_0x19ca0c?.[_0x49c257(0x1cb)]?.[_0x49c257(0x1ce)],'appCode':getConfigAppCode()}),cliOtelTraceInitialized=!![];}return _0x215582;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x16925f,_0x716e66){const _0x33f2c5=a288_0x36d8,_0x1eccc3=_0x16925f();while(!![]){try{const _0xde52e5=-parseInt(_0x33f2c5(0x1c6))/0x1*(-parseInt(_0x33f2c5(0x1c7))/0x2)+parseInt(_0x33f2c5(0x1c9))/0x3*(parseInt(_0x33f2c5(0x1cf))/0x4)+parseInt(_0x33f2c5(0x1ca))/0x5*(-parseInt(_0x33f2c5(0x1c5))/0x6)+-parseInt(_0x33f2c5(0x1cb))/0x7*(parseInt(_0x33f2c5(0x1cd))/0x8)+-parseInt(_0x33f2c5(0x1cc))/0x9+-parseInt(_0x33f2c5(0x1c8))/0xa*(-parseInt(_0x33f2c5(0x1d2))/0xb)+parseInt(_0x33f2c5(0x1d3))/0xc;if(_0xde52e5===_0x716e66)break;else _0x1eccc3['push'](_0x1eccc3['shift']());}catch(_0x8fba74){_0x1eccc3['push'](_0x1eccc3['shift']());}}}(a288_0x1226,0x7eb19));import{shutdownTraces}from'@lovrabet/otel-logger';function a288_0x1226(){const _0x46152e=['SIGINT','84PyuXTG','1PpduCd','1594078AZuYSs','130PTpvau','21ELQNRN','320715hOmkzA','35dmvYQu','2365533qlEHxY','1370288cZXCNo','once','267032HSPsjc','then','SIGTERM','200013aATbvF','12425784XFzxBQ'];a288_0x1226=function(){return _0x46152e;};return a288_0x1226();}let shutdownPromise=null;export async function flushOtelNodeIfUsed(){if(shutdownPromise)return shutdownPromise;return shutdownPromise=((async()=>{try{await shutdownTraces();}catch{}})()),shutdownPromise;}function a288_0x36d8(_0x1d87d9,_0x1a2847){_0x1d87d9=_0x1d87d9-0x1c4;const _0x122666=a288_0x1226();let _0x36d867=_0x122666[_0x1d87d9];return _0x36d867;}export function registerOtelShutdownOnExit(){const _0x94900b=a288_0x36d8;process[_0x94900b(0x1ce)]('beforeExit',()=>{void flushOtelNodeIfUsed();});const _0x479cdb=()=>{const _0x332fea=_0x94900b;void flushOtelNodeIfUsed()[_0x332fea(0x1d0)](()=>process['exit'](0x0));};process['once'](_0x94900b(0x1c4),_0x479cdb),process[_0x94900b(0x1ce)](_0x94900b(0x1d1),_0x479cdb);}export async function exitWithOtelShutdown(_0x2b6573){await flushOtelNodeIfUsed(),process['exit'](_0x2b6573);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a289_0x3eadad=a289_0x1252;function a289_0x1606(){const _0x4f053a=['81wYkKVz','481160uSMGME','logData','3076869teamKQ','manual','22642704MinWRC','3746446DbmSlA','traceName','2778JaDhUZ','1027760ITHtlr','traceparent','112IxbjfG','1257091SMhRpr','4lpUZvk','rabetbase-cli','2derMWD','1075wfVVSd'];a289_0x1606=function(){return _0x4f053a;};return a289_0x1606();}(function(_0x39f924,_0x112fef){const _0x422ae3=a289_0x1252,_0x526213=_0x39f924();while(!![]){try{const _0x45771d=-parseInt(_0x422ae3(0x1dc))/0x1*(-parseInt(_0x422ae3(0x1df))/0x2)+parseInt(_0x422ae3(0x1e4))/0x3*(parseInt(_0x422ae3(0x1dd))/0x4)+-parseInt(_0x422ae3(0x1e0))/0x5*(parseInt(_0x422ae3(0x1e9))/0x6)+parseInt(_0x422ae3(0x1db))/0x7*(parseInt(_0x422ae3(0x1e2))/0x8)+parseInt(_0x422ae3(0x1e1))/0x9*(-parseInt(_0x422ae3(0x1ea))/0xa)+parseInt(_0x422ae3(0x1e7))/0xb+-parseInt(_0x422ae3(0x1e6))/0xc;if(_0x45771d===_0x112fef)break;else _0x526213['push'](_0x526213['shift']());}catch(_0x560602){_0x526213['push'](_0x526213['shift']());}}}(a289_0x1606,0xa4997));import{sendTraceLog}from'@lovrabet/otel-logger';import{ensureCliOtelTraceConfig}from'../telemetry/ensure-cli-otel-config.js';function a289_0x1252(_0x323348,_0x2601cb){_0x323348=_0x323348-0x1da;const _0x160633=a289_0x1606();let _0x1252c1=_0x160633[_0x323348];return _0x1252c1;}import{getCliVersion}from'../utils/version.js';const DEFAULT_TRACE_NAME=a289_0x3eadad(0x1de);export async function sendCliTraceLog(_0x44e089){const _0x40162a=a289_0x3eadad;await ensureCliOtelTraceConfig(),sendTraceLog({'traceName':_0x44e089[_0x40162a(0x1e8)]??DEFAULT_TRACE_NAME,'version':_0x44e089['version']??getCliVersion(),'spanName':_0x44e089['spanName'],'eventType':_0x40162a(0x1e5),'logData':_0x44e089[_0x40162a(0x1e3)],..._0x44e089[_0x40162a(0x1da)]&&{'traceparent':_0x44e089['traceparent']}});}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a290_0x593bd4=a290_0x15be;function a290_0x42d8(){const _0x27bced=['originalBytes','redactionCount','2994232TlFwiR','825671ciCBgz','6323848zUxSKh','sanitize','3473561GaVdOB','4660752mPOplQ','16tvEkDm','join','issue.log.collect','title','platform-issue-log-collect','101022HlIJlJ','843740vDwEgW','redactionKinds','truncated','9fgwqFp','description'];a290_0x42d8=function(){return _0x27bced;};return a290_0x42d8();}function a290_0x15be(_0x497f47,_0x3cf6a6){_0x497f47=_0x497f47-0x16d;const _0x42d8ac=a290_0x42d8();let _0x15be9a=_0x42d8ac[_0x497f47];return _0x15be9a;}(function(_0x58c1fd,_0x52b8ef){const _0x557f2d=a290_0x15be,_0x455d1a=_0x58c1fd();while(!![]){try{const _0x5d6982=parseInt(_0x557f2d(0x17f))/0x1+-parseInt(_0x557f2d(0x171))/0x2*(-parseInt(_0x557f2d(0x176))/0x3)+parseInt(_0x557f2d(0x17e))/0x4+-parseInt(_0x557f2d(0x177))/0x5+-parseInt(_0x557f2d(0x170))/0x6+parseInt(_0x557f2d(0x16f))/0x7+parseInt(_0x557f2d(0x16d))/0x8*(-parseInt(_0x557f2d(0x17a))/0x9);if(_0x5d6982===_0x52b8ef)break;else _0x455d1a['push'](_0x455d1a['shift']());}catch(_0x24a4e3){_0x455d1a['push'](_0x455d1a['shift']());}}}(a290_0x42d8,0x936af));import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';export const PLATFORM_ISSUE_TRACE_NAME=a290_0x593bd4(0x175);export const PLATFORM_ISSUE_SPAN_NAME=a290_0x593bd4(0x173);export async function sendPlatformIssueCollectLog(_0x5292ea){const _0xd937c7=a290_0x593bd4;await sendCliTraceLog({'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logData':{'issue.title':_0x5292ea[_0xd937c7(0x174)],'issue.description':_0x5292ea[_0xd937c7(0x17b)],..._0x5292ea['sanitize']?{'issue.description_original_bytes':_0x5292ea[_0xd937c7(0x16e)][_0xd937c7(0x17c)],'issue.description_truncated':_0x5292ea['sanitize'][_0xd937c7(0x179)],'issue.description_redactions':_0x5292ea[_0xd937c7(0x16e)][_0xd937c7(0x17d)],'issue.description_redaction_kinds':_0x5292ea['sanitize'][_0xd937c7(0x178)][_0xd937c7(0x172)](',')}:{}}});}
|
package/lib/utils/ai_config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a292_0x186598=a292_0x56db;(function(_0x4ae4af,_0x231702){const _0x485670=a292_0x56db,_0x1ad3a6=_0x4ae4af();while(!![]){try{const _0x3c2af3=parseInt(_0x485670(0x185))/0x1+parseInt(_0x485670(0x182))/0x2*(parseInt(_0x485670(0x1aa))/0x3)+parseInt(_0x485670(0x1a7))/0x4*(-parseInt(_0x485670(0x197))/0x5)+-parseInt(_0x485670(0x19e))/0x6+parseInt(_0x485670(0x198))/0x7+-parseInt(_0x485670(0x1a8))/0x8*(parseInt(_0x485670(0x19f))/0x9)+parseInt(_0x485670(0x183))/0xa*(parseInt(_0x485670(0x18e))/0xb);if(_0x3c2af3===_0x231702)break;else _0x1ad3a6['push'](_0x1ad3a6['shift']());}catch(_0x51f398){_0x1ad3a6['push'](_0x1ad3a6['shift']());}}}(a292_0x32a9,0x49d18));export const CORE_IDE_CONFIGS={'cursor':{'name':a292_0x186598(0x1a9),'description':'Cursor\x20IDE','folders':['.cursorrules','.cursor'],'files':[{'type':a292_0x186598(0x18f),'path':'.cursor/skills/rabetbase.md'}]},'windsurf':{'name':'Windsurf','description':'Windsurf\x20IDE','folders':[a292_0x186598(0x1b2)],'files':[{'type':'file','path':a292_0x186598(0x190)}]},'claude':{'name':a292_0x186598(0x1a4),'description':'Claude\x20Code','folders':[a292_0x186598(0x193)],'files':[{'type':a292_0x186598(0x18f),'path':a292_0x186598(0x1b4)}]},'cline':{'name':a292_0x186598(0x1af),'description':a292_0x186598(0x199),'folders':[a292_0x186598(0x1ad)],'files':[{'type':'file','path':a292_0x186598(0x184)}]},'codex':{'name':a292_0x186598(0x1b0),'description':'Codex\x20IDE','folders':[a292_0x186598(0x1ae)],'files':[{'type':a292_0x186598(0x18f),'path':a292_0x186598(0x19d)}]},'opencode':{'name':a292_0x186598(0x186),'description':a292_0x186598(0x18b),'folders':['.opencode'],'files':[{'type':a292_0x186598(0x18f),'path':'.opencode/skills/lovrabet/SKILL.md'}]},'qoder':{'name':a292_0x186598(0x191),'description':a292_0x186598(0x187),'folders':[a292_0x186598(0x19a)],'files':[{'type':'file','path':a292_0x186598(0x1ab)},{'type':'file','path':a292_0x186598(0x195)}]},'codebuddy':{'name':a292_0x186598(0x194),'description':a292_0x186598(0x1a3),'folders':['.codebuddy'],'files':[{'type':a292_0x186598(0x18f),'path':'.codebuddy/skills/lovrabet/SKILL.md'}]},'trae':{'name':a292_0x186598(0x188),'description':a292_0x186598(0x18d),'folders':['.trae'],'files':[{'type':a292_0x186598(0x18f),'path':a292_0x186598(0x1b1)}]}};export const IDE_CONFIGS={...CORE_IDE_CONFIGS,'agent':{'name':'Other\x20(generic\x20template)','description':a292_0x186598(0x1ac),'folders':[a292_0x186598(0x189)],'files':[{'type':a292_0x186598(0x18f),'path':a292_0x186598(0x192)}]},'antigravity':{'name':a292_0x186598(0x19c),'description':a292_0x186598(0x1a6),'folders':[a292_0x186598(0x189)],'files':[{'type':a292_0x186598(0x18f),'path':a292_0x186598(0x192)}]}};function a292_0x56db(_0x2b1611,_0x3f3054){_0x2b1611=_0x2b1611-0x182;const _0x32a995=a292_0x32a9();let _0x56dbae=_0x32a995[_0x2b1611];return _0x56dbae;}export const CORE_IDE_LIST=[a292_0x186598(0x1b3),a292_0x186598(0x196),a292_0x186598(0x1a0),a292_0x186598(0x19b),'cursor',a292_0x186598(0x18c),a292_0x186598(0x1b5),a292_0x186598(0x1a1),a292_0x186598(0x18a)];function a292_0x32a9(){const _0x4a3f20=['.agent/skills/lovrabet/SKILL.md','.claude','CodeBuddy','.qoder/skills/lovrabet/SKILL.md','cline','525PprlBn','3531794VvDxBa','Cline\x20IDE','.qoder','codex','Antigravity','.codex/skills/lovrabet/SKILL.md','1342512SoDzIT','54ndZjZo','codebuddy','trae','agent','CodeBuddy\x20IDE','Claude\x20Code','cursor','Antigravity\x20IDE','19852wngIaW','164432jJHGKI','Cursor','354WxVTnq','.qoder/rules/rabetbase.md','Generic\x20template\x20fallback','.cline','.codex','Cline','Codex','.trae/skills/lovrabet/SKILL.md','.windsurf','claude','.claude/skills/lovrabet/SKILL.md','qoder','2274qLsdQT','700730Wyzmrl','.cline/skills/lovrabet/SKILL.md','321624augQoL','OpenCode','Qoder\x20IDE','Trae','.agent','windsurf','OpenCode\x20IDE','opencode','Trae\x20IDE','33cnqplr','file','.windsurf/workflows/rabetbase.md','Qoder'];a292_0x32a9=function(){return _0x4a3f20;};return a292_0x32a9();}export const IDE_LIST=['antigravity',a292_0x186598(0x1b3),a292_0x186598(0x196),a292_0x186598(0x1a0),a292_0x186598(0x19b),a292_0x186598(0x1a5),a292_0x186598(0x18c),a292_0x186598(0x1b5),a292_0x186598(0x1a1),a292_0x186598(0x18a),a292_0x186598(0x1a2)];export const ALL_CORE_IDES=[a292_0x186598(0x1a5),'windsurf',a292_0x186598(0x1b3),a292_0x186598(0x196),a292_0x186598(0x19b),'opencode','qoder',a292_0x186598(0x1a0),a292_0x186598(0x1a1)];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1fc92b,_0x5e5ad7){const _0x3fa12a=a293_0x112e,_0x1a7b7d=_0x1fc92b();while(!![]){try{const _0xed4f31=-parseInt(_0x3fa12a(0xe4))/0x1+-parseInt(_0x3fa12a(0xe3))/0x2+-parseInt(_0x3fa12a(0xe1))/0x3*(-parseInt(_0x3fa12a(0xe9))/0x4)+-parseInt(_0x3fa12a(0xe8))/0x5*(-parseInt(_0x3fa12a(0xe7))/0x6)+-parseInt(_0x3fa12a(0xe2))/0x7+parseInt(_0x3fa12a(0xe6))/0x8*(-parseInt(_0x3fa12a(0xe0))/0x9)+parseInt(_0x3fa12a(0xe5))/0xa;if(_0xed4f31===_0x5e5ad7)break;else _0x1a7b7d['push'](_0x1a7b7d['shift']());}catch(_0x5828a8){_0x1a7b7d['push'](_0x1a7b7d['shift']());}}}(a293_0x393c,0xdff57));import{createJqFilter,resolveBundledJqPaths}from'@lovrabet/cli-framework';import{CliErrors}from'../errors.js';function a293_0x393c(){const _0x486da0=['897882odqLhi','38943200WsLjAd','16KwuEBz','24150vqSKxw','380sbvEUo','4fRWtQq','7345638nMXlur','3524262DMDKxI','8932826axhXbx','1302550kYYyvn'];a293_0x393c=function(){return _0x486da0;};return a293_0x393c();}function a293_0x112e(_0x204b3e,_0x511baf){_0x204b3e=_0x204b3e-0xe0;const _0x393cee=a293_0x393c();let _0x112e38=_0x393cee[_0x204b3e];return _0x112e38;}export const applyJqFilter=createJqFilter(CliErrors,{'bundledJqPaths':resolveBundledJqPaths()});
|
package/lib/utils/cdn-config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x28a2c9,_0x42c763){const _0x571882=a294_0x4c59,_0x32d01a=_0x28a2c9();while(!![]){try{const _0x31fb4c=parseInt(_0x571882(0xce))/0x1+-parseInt(_0x571882(0xd5))/0x2*(-parseInt(_0x571882(0xd0))/0x3)+parseInt(_0x571882(0xd7))/0x4+parseInt(_0x571882(0xd1))/0x5+-parseInt(_0x571882(0xd4))/0x6+parseInt(_0x571882(0xd6))/0x7+-parseInt(_0x571882(0xd8))/0x8*(parseInt(_0x571882(0xd2))/0x9);if(_0x31fb4c===_0x42c763)break;else _0x32d01a['push'](_0x32d01a['shift']());}catch(_0x36adca){_0x32d01a['push'](_0x32d01a['shift']());}}}(a294_0x43e4,0x1c42f));import{getTemplateBaseUrl}from'../utils/config.js';export async function fetchCdnConfig(){const _0x452129=a294_0x4c59,_0x15b9b3=getTemplateBaseUrl(),_0x53ba3b=[_0x15b9b3+_0x452129(0xdc),_0x15b9b3+_0x452129(0xdb)];for(const _0x1334ac of _0x53ba3b){try{const _0x36dac6=await fetch(_0x1334ac,{'headers':{'Accept':'application/json'}});if(!_0x36dac6['ok'])continue;const _0x10a76b=await _0x36dac6['json']();if(!_0x10a76b['cli']?.[_0x452129(0xcf)]||!_0x10a76b[_0x452129(0xd3)]?.[_0x452129(0xda)]?.['stableVersion'])continue;return _0x10a76b;}catch{}}return null;}function a294_0x4c59(_0x3c423c,_0x2c3f78){_0x3c423c=_0x3c423c-0xce;const _0x43e49c=a294_0x43e4();let _0x4c5991=_0x43e49c[_0x3c423c];return _0x4c5991;}function a294_0x43e4(){const _0x1756de=['841533yJjkbB','448020pERXsA','96oxHOYW','now','node','/config/index.json','/config.json','59440UXhFIj','stableVersion','158181iLsjNF','113335tPEdyO','182817cBpbno','sdk','361620ZjLQmR','4rXqCPF'];a294_0x43e4=function(){return _0x1756de;};return a294_0x43e4();}let cachedConfig=null,cacheTime=0x0;const CACHE_TTL=0x5*0x3c*0x3e8,FAILURE_CACHE_TTL=0x3c*0x3e8;let hasCachedConfig=![];export async function getCdnConfig(){const _0x4a18c9=a294_0x4c59,_0x15d87a=Date[_0x4a18c9(0xd9)]();if(hasCachedConfig){const _0x224dc=cachedConfig?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x15d87a-cacheTime<_0x224dc)return cachedConfig;}const _0x155ffe=await fetchCdnConfig();return cachedConfig=_0x155ffe,cacheTime=_0x15d87a,hasCachedConfig=!![],_0x155ffe;}export function clearCdnConfigCache(){cachedConfig=null,cacheTime=0x0,hasCachedConfig=![];}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x5cd5fc,_0x2c5e4e){const _0x521278=a295_0x451f,_0x246715=_0x5cd5fc();while(!![]){try{const _0xf36ab7=-parseInt(_0x521278(0xf2))/0x1*(-parseInt(_0x521278(0xf6))/0x2)+parseInt(_0x521278(0xe1))/0x3+-parseInt(_0x521278(0xdf))/0x4*(parseInt(_0x521278(0xdc))/0x5)+parseInt(_0x521278(0xec))/0x6*(parseInt(_0x521278(0xf7))/0x7)+-parseInt(_0x521278(0xf5))/0x8*(parseInt(_0x521278(0xda))/0x9)+-parseInt(_0x521278(0xd6))/0xa*(-parseInt(_0x521278(0xe0))/0xb)+-parseInt(_0x521278(0xdb))/0xc;if(_0xf36ab7===_0x2c5e4e)break;else _0x246715['push'](_0x246715['shift']());}catch(_0x9cbec9){_0x246715['push'](_0x246715['shift']());}}}(a295_0x8203,0xe68c3));function a295_0x451f(_0x2b3122,_0x45d770){_0x2b3122=_0x2b3122-0xd2;const _0x820390=a295_0x8203();let _0x451f6d=_0x820390[_0x2b3122];return _0x451f6d;}import a295_0xc7199b from'node:fs';import a295_0x441eba from'node:path';import a295_0x43664a from'semver';import{getCdnConfig}from'../utils/cdn-config.js';const FALLBACK_MIN_SDK_VERSION='1.2.0';function isNonNumericVersion(_0x501da7){const _0x2a25cc=a295_0x451f,_0x4ba793=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x4ba793[_0x2a25cc(0xd9)](_0x43c932=>_0x43c932[_0x2a25cc(0xde)](_0x501da7));}function getInstalledVersion(_0x3f27c1,_0x44688c){const _0x5b3bbd=a295_0x451f;try{const _0xb8e520=a295_0x441eba[_0x5b3bbd(0xed)](_0x3f27c1,_0x5b3bbd(0xf9),_0x44688c,_0x5b3bbd(0xe5));if(a295_0xc7199b[_0x5b3bbd(0xef)](_0xb8e520)){const _0x27b844=JSON[_0x5b3bbd(0xdd)](a295_0xc7199b[_0x5b3bbd(0xe7)](_0xb8e520,_0x5b3bbd(0xd8)));return _0x27b844[_0x5b3bbd(0xf8)]||null;}}catch{}return null;}function a295_0x8203(){const _0x32cbe8=['1539434EkgJkB','7bdwruI','version','node_modules','latest','stableVersion','packageName','node','17621770ujsdZF','all','utf-8','some','9NYzRdS','20040996DWUvzS','15aMabsb','parse','test','1175772gzQSsZ','11xQrOyU','251382KdWnLP','dependencies','↪\x20SDK\x20update\x20available','\x1b[0m','package.json','coerce','readFileSync','devDependencies','log','sdk','@lovrabet/sdk','6348066vlNFaW','join','npm\x20install\x20','existsSync','utf8','\x1b[1m','1LtnSnm','needsUpgrade','\x20\x20\x20Stable\x20version:\x20','1419712yxZUEz'];a295_0x8203=function(){return _0x32cbe8;};return a295_0x8203();}async function getSdkStableVersion(){const _0x5ee15b=a295_0x451f;try{const _0x5c5b27=await getCdnConfig();return _0x5c5b27?.[_0x5ee15b(0xea)]?.[_0x5ee15b(0xd5)]?.[_0x5ee15b(0xd3)]||null;}catch{return null;}}async function getSdkPackageName(){const _0x4b680f=a295_0x451f;try{const _0xd4c33=await getCdnConfig();return _0xd4c33?.[_0x4b680f(0xea)]?.['node']?.[_0x4b680f(0xd4)]||_0x4b680f(0xeb);}catch{return _0x4b680f(0xeb);}}export async function checkSdkVersion(_0x10538c){const _0x485fc0=a295_0x451f,_0x2ecfcb=a295_0x441eba[_0x485fc0(0xed)](_0x10538c,'package.json'),[_0x46f2ef,_0x1d5b96]=await Promise[_0x485fc0(0xd7)]([getSdkStableVersion(),getSdkPackageName()]),_0x4f2308=_0x46f2ef||FALLBACK_MIN_SDK_VERSION;if(!a295_0xc7199b[_0x485fc0(0xef)](_0x2ecfcb))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x4f2308,'packageName':_0x1d5b96,'stableVersion':_0x46f2ef};try{const _0xb935f=JSON[_0x485fc0(0xdd)](a295_0xc7199b[_0x485fc0(0xe7)](_0x2ecfcb,_0x485fc0(0xf0))),_0x59b418=_0xb935f['dependencies']||{},_0x53fdbb=_0xb935f[_0x485fc0(0xe8)]||{},_0x528072=_0x59b418[_0x1d5b96]||_0x53fdbb[_0x1d5b96];if(!_0x528072)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x4f2308,'packageName':_0x1d5b96,'stableVersion':_0x46f2ef};let _0x5d558b=getInstalledVersion(_0x10538c,_0x1d5b96);!_0x5d558b&&(_0x5d558b=_0x528072);if(isNonNumericVersion(_0x528072))return{'installed':!![],'version':_0x5d558b,'needsUpgrade':![],'minVersion':_0x4f2308,'packageName':_0x1d5b96,'stableVersion':_0x46f2ef};const _0x4e25d6=a295_0x43664a['coerce'](_0x5d558b),_0x4e556b=a295_0x43664a[_0x485fc0(0xe6)](_0x4f2308),_0x2cb9f3=_0x4e25d6&&_0x4e556b?a295_0x43664a['lt'](_0x4e25d6,_0x4e556b):![];return{'installed':!![],'version':_0x5d558b,'needsUpgrade':_0x2cb9f3,'minVersion':_0x4f2308,'packageName':_0x1d5b96,'stableVersion':_0x46f2ef};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x4f2308,'packageName':_0x1d5b96,'stableVersion':_0x46f2ef};}}export function checkSdkVersionSync(_0x2a30ea){const _0x5b92fb=a295_0x451f,_0x231373=a295_0x441eba['join'](_0x2a30ea,_0x5b92fb(0xe5)),_0x2270b2=_0x5b92fb(0xeb);if(!a295_0xc7199b[_0x5b92fb(0xef)](_0x231373))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2270b2,'stableVersion':null};try{const _0x4d07c1=JSON[_0x5b92fb(0xdd)](a295_0xc7199b['readFileSync'](_0x231373,'utf8')),_0x32efdf=_0x4d07c1[_0x5b92fb(0xe2)]||{},_0x523b47=_0x4d07c1['devDependencies']||{},_0x101ac7=_0x32efdf[_0x2270b2]||_0x523b47[_0x2270b2];if(!_0x101ac7)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2270b2,'stableVersion':null};let _0x598f68=getInstalledVersion(_0x2a30ea,_0x2270b2);!_0x598f68&&(_0x598f68=_0x101ac7);if(isNonNumericVersion(_0x101ac7))return{'installed':!![],'version':_0x598f68,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2270b2,'stableVersion':null};const _0x340ad9=a295_0x43664a[_0x5b92fb(0xe6)](_0x598f68),_0x3bae3b=_0x340ad9?a295_0x43664a['lt'](_0x340ad9,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0x598f68,'needsUpgrade':_0x3bae3b,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2270b2,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2270b2,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x10adad){const _0x328ed9=a295_0x451f;if(!_0x10adad[_0x328ed9(0xf3)])return;const _0x5ea6cb='\x1b[33m',_0x3a9576=_0x328ed9(0xe4),_0x1f28fb=_0x328ed9(0xf1),_0x4848c4=_0x10adad[_0x328ed9(0xd4)]||_0x328ed9(0xeb),_0x5a7c8b=_0x10adad[_0x328ed9(0xd3)]||_0x10adad['minVersion'],_0x405e47=_0x328ed9(0xee)+_0x4848c4+'@'+(_0x5a7c8b||_0x328ed9(0xd2));console[_0x328ed9(0xe9)](),console['log'](''+_0x5ea6cb+_0x1f28fb+_0x328ed9(0xe3)+_0x3a9576),console[_0x328ed9(0xe9)](_0x5ea6cb+'\x20\x20\x20Current\x20version:\x20'+_0x4848c4+'@'+_0x10adad['version']+_0x3a9576),console[_0x328ed9(0xe9)](_0x5ea6cb+_0x328ed9(0xf4)+_0x5a7c8b+_0x3a9576),console['log'](_0x5ea6cb+'\x20\x20\x20Upgrade\x20command:\x20'+_0x405e47+_0x3a9576),console[_0x328ed9(0xe9)]();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x155fc6,_0x4e2a21){const _0x2b1d13=a296_0xa334,_0x29e8db=_0x155fc6();while(!![]){try{const _0xae124a=-parseInt(_0x2b1d13(0x186))/0x1+-parseInt(_0x2b1d13(0x1a0))/0x2+-parseInt(_0x2b1d13(0x19a))/0x3*(-parseInt(_0x2b1d13(0x1a5))/0x4)+parseInt(_0x2b1d13(0x194))/0x5+parseInt(_0x2b1d13(0x197))/0x6+-parseInt(_0x2b1d13(0x19c))/0x7+parseInt(_0x2b1d13(0x18a))/0x8*(parseInt(_0x2b1d13(0x19b))/0x9);if(_0xae124a===_0x4e2a21)break;else _0x29e8db['push'](_0x29e8db['shift']());}catch(_0x4a97a8){_0x29e8db['push'](_0x29e8db['shift']());}}}(a296_0x3d23,0xb5170));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';function a296_0x3d23(){const _0x32e645=['minimumVersionMessage','package.json','filter','\x20\x20\x20Stable\x20version:\x20','needsUpgrade','belowMinimum','\x20\x20\x20Recommended\x20stable:\x20','version','443105HNsHEI','log','\x1b[0m','\x20\x20\x20','8zxtEBd','coerce','npm\x20install\x20-g\x20','\x20\x20\x20Current\x20CLI\x20version:\x20','parse','upgradeMessage','↪\x20New\x20version\x20available','../..','Current\x20CLI\x20version\x20is\x20below\x20the\x20service\x20compatibility\x20support\x20line.','join','3279025xcilRL','\x20\x20\x20Minimum\x20supported:\x20','↪\x20Critical\x20CLI\x20upgrade\x20required','6358092EaYEgy','1.0.0','\x1b[1m','189597TtpSBW','2017782OSnHeX','6047440fTTBbg','Upgrade\x20command:\x20','currentVersion','Minimum\x20supported:\x20','793016tqZGVy','validation','utf-8','\x20\x20\x20Upgrade\x20command:\x20','minimumVersion','32wafvms','stableVersion'];a296_0x3d23=function(){return _0x32e645;};return a296_0x3d23();}import a296_0x1587e5 from'semver';import{getCliVersionPolicy}from'../utils/cli-version-policy.js';function a296_0xa334(_0x587c6c,_0x1f066e){_0x587c6c=_0x587c6c-0x186;const _0x3d23be=a296_0x3d23();let _0xa33479=_0x3d23be[_0x587c6c];return _0xa33479;}import{NPM_PACKAGE_NAME}from'../constant/cli.js';import{CliErrors}from'../errors.js';export function getCliUpgradeCommand(_0x22c853){const _0x225f9b=a296_0xa334,_0x2c04f9=_0x22c853[_0x225f9b(0x1a6)]||'latest';return _0x225f9b(0x18c)+NPM_PACKAGE_NAME+'@'+_0x2c04f9;}function getCurrentCliVersion(){const _0x41f636=a296_0xa334;try{const _0x71224f=fileURLToPath(import.meta.url),_0x37adcd=resolve(dirname(_0x71224f),_0x41f636(0x191)),_0x218ddf=resolve(_0x37adcd,_0x41f636(0x1a8)),_0x1a5cd3=JSON[_0x41f636(0x18e)](readFileSync(_0x218ddf,_0x41f636(0x1a2)));return _0x1a5cd3[_0x41f636(0x1ae)]||_0x41f636(0x198);}catch{return _0x41f636(0x198);}}export async function checkCliVersion(){const _0xaeccd3=a296_0xa334,_0xe30fba=getCurrentCliVersion(),_0x5f5c7d=await getCliVersionPolicy(),_0x40575a=_0x5f5c7d?.[_0xaeccd3(0x1a6)]||null,_0x137402=_0x5f5c7d?.[_0xaeccd3(0x1a4)]||null;let _0x1dd0c2=![],_0x572102=![];const _0x37c069=a296_0x1587e5[_0xaeccd3(0x18b)](_0xe30fba);if(_0x37c069&&_0x40575a)try{const _0x52597d=a296_0x1587e5['coerce'](_0x40575a);if(_0x52597d)_0x1dd0c2=a296_0x1587e5['lt'](_0x37c069,_0x52597d);}catch{}if(_0x37c069&&_0x137402)try{const _0x50138b=a296_0x1587e5[_0xaeccd3(0x18b)](_0x137402);if(_0x50138b)_0x572102=a296_0x1587e5['lt'](_0x37c069,_0x50138b);}catch{}return _0x572102&&(_0x1dd0c2=!![]),{'currentVersion':_0xe30fba,'stableVersion':_0x40575a,'minimumVersion':_0x137402,'needsUpgrade':_0x1dd0c2,'belowMinimum':_0x572102,'isPreRelease':![],'upgradeMessage':_0x5f5c7d?.[_0xaeccd3(0x18f)],'minimumVersionMessage':_0x5f5c7d?.[_0xaeccd3(0x1a7)]};}export function printCliUpgradeWarning(_0x3f80f2){const _0x4622e4=a296_0xa334;if(!_0x3f80f2[_0x4622e4(0x1ab)]&&!_0x3f80f2['belowMinimum'])return;const _0xa13cbd='\x1b[31m',_0x1052ac='\x1b[33m',_0x463b46=_0x4622e4(0x188),_0x5ecfcf=_0x4622e4(0x199),_0x35c7d2=getCliUpgradeCommand(_0x3f80f2);console[_0x4622e4(0x187)](),_0x3f80f2[_0x4622e4(0x1ac)]?(console[_0x4622e4(0x187)](''+_0xa13cbd+_0x5ecfcf+_0x4622e4(0x196)+_0x463b46),console['log'](_0xa13cbd+_0x4622e4(0x18d)+_0x3f80f2['currentVersion']+_0x463b46),_0x3f80f2[_0x4622e4(0x1a4)]&&console[_0x4622e4(0x187)](_0xa13cbd+_0x4622e4(0x195)+_0x3f80f2[_0x4622e4(0x1a4)]+_0x463b46),_0x3f80f2['stableVersion']&&_0x3f80f2['stableVersion']!==_0x3f80f2['minimumVersion']&&console['log'](_0xa13cbd+_0x4622e4(0x1ad)+_0x3f80f2[_0x4622e4(0x1a6)]+_0x463b46),_0x3f80f2[_0x4622e4(0x1a7)]&&console[_0x4622e4(0x187)](_0xa13cbd+_0x4622e4(0x189)+_0x3f80f2['minimumVersionMessage']+_0x463b46),console[_0x4622e4(0x187)](_0xa13cbd+_0x4622e4(0x1a3)+_0x35c7d2+_0x463b46)):(console[_0x4622e4(0x187)](''+_0x1052ac+_0x5ecfcf+_0x4622e4(0x190)+_0x463b46),console[_0x4622e4(0x187)](_0x1052ac+_0x4622e4(0x18d)+_0x3f80f2[_0x4622e4(0x19e)]+_0x463b46),console['log'](_0x1052ac+_0x4622e4(0x1aa)+_0x3f80f2['stableVersion']+_0x463b46),_0x3f80f2['upgradeMessage']&&console[_0x4622e4(0x187)](_0x1052ac+_0x4622e4(0x189)+_0x3f80f2[_0x4622e4(0x18f)]+_0x463b46),console[_0x4622e4(0x187)](_0x1052ac+_0x4622e4(0x1a3)+_0x35c7d2+_0x463b46)),console[_0x4622e4(0x187)]();}export function assertCliVersionSupported(_0x4ea2c4){const _0x3ef337=a296_0xa334;if(!_0x4ea2c4[_0x3ef337(0x1ac)])return;const _0x4cd98e=[_0x4ea2c4[_0x3ef337(0x1a7)],'Current\x20version:\x20'+_0x4ea2c4[_0x3ef337(0x19e)],_0x4ea2c4[_0x3ef337(0x1a4)]?_0x3ef337(0x19f)+_0x4ea2c4[_0x3ef337(0x1a4)]:null,_0x3ef337(0x19d)+getCliUpgradeCommand(_0x4ea2c4)][_0x3ef337(0x1a9)](Boolean)[_0x3ef337(0x193)]('\x0a');throw CliErrors[_0x3ef337(0x1a1)](_0x3ef337(0x192),_0x4cd98e);}
|