@lovrabet/rabetbase-cli 2.1.6 → 2.1.7-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/api-doc.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/login-success-html.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/generate.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/add.js +1 -1
- package/lib/commands/app/discover.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/remove.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app/use.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/create.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/data/filter.js +1 -1
- package/lib/commands/data/getOne.js +1 -1
- package/lib/commands/data/index.js +1 -1
- package/lib/commands/data/shared.js +1 -1
- package/lib/commands/dataset/delete.js +1 -0
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/link-create.js +1 -0
- package/lib/commands/dataset/link-delete.js +1 -0
- package/lib/commands/dataset/link-shared.js +1 -0
- package/lib/commands/dataset/link-update.js +1 -0
- package/lib/commands/dataset/links.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.js +1 -1
- package/lib/commands/db/analyze-cancel.js +1 -1
- package/lib/commands/db/analyze-start.js +1 -1
- package/lib/commands/db/analyze-status.js +1 -1
- package/lib/commands/db/create.js +1 -1
- package/lib/commands/db/delete.js +1 -1
- package/lib/commands/db/detail.js +1 -1
- package/lib/commands/db/diff.js +1 -1
- package/lib/commands/db/index.js +1 -1
- package/lib/commands/db/list.js +1 -1
- package/lib/commands/db/shared.js +1 -1
- package/lib/commands/db/tables.js +1 -1
- package/lib/commands/db/test.js +1 -1
- package/lib/commands/db/update.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/init/index.js +1 -1
- package/lib/commands/issue/index.js +1 -0
- package/lib/commands/issue/report.js +1 -0
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/update.js +1 -1
- package/lib/commands/page/generate-start.js +1 -1
- package/lib/commands/page/generate-status.js +1 -1
- package/lib/commands/page/index.js +1 -1
- package/lib/commands/page/pull.js +1 -1
- package/lib/commands/page/push.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/standard-page-status.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/project/create/enhanced-guided-create.js +1 -1
- package/lib/commands/project/create/format-elapsed.js +1 -1
- package/lib/commands/project/create/main.js +1 -1
- package/lib/commands/project/create/non-interactive.js +1 -1
- package/lib/commands/project/create/project-template-path.js +1 -1
- package/lib/commands/project/create/use-copy-project-template.js +1 -1
- package/lib/commands/project/create/use-format-code.js +1 -1
- package/lib/commands/project/create/use-install-dependencies.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/init.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/run/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/skill/index.js +1 -1
- package/lib/commands/sql/create.js +1 -1
- package/lib/commands/sql/delete.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/sql/list.js +1 -1
- package/lib/commands/sql/pull.js +1 -1
- package/lib/commands/sql/push.js +1 -1
- package/lib/commands/sql/save.js +1 -1
- package/lib/commands/sql/shared.js +1 -1
- package/lib/commands/sql/status.js +1 -1
- package/lib/commands/sql/validate.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/cdn.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/paths.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/page/file-system.js +1 -1
- package/lib/core/page/hash.js +1 -1
- package/lib/core/page/lock.js +1 -1
- package/lib/core/sql-sync/config.js +1 -1
- package/lib/core/sql-sync/file-system.js +1 -1
- package/lib/core/sql-sync/hash.js +1 -1
- package/lib/core/sql-sync/lock.js +1 -1
- package/lib/core/sql-sync/utils.js +1 -1
- package/lib/core/sql-validator.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/flags.js +1 -1
- package/lib/framework/help.js +1 -1
- package/lib/framework/index.js +1 -1
- package/lib/framework/output.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-alias.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.js +1 -1
- package/lib/help.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/telemetry/cli-command-trace.js +1 -1
- package/lib/telemetry/cli-help-trace.js +1 -1
- package/lib/telemetry/ensure-cli-otel-config.js +1 -1
- package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
- package/lib/telemetry/send-cli-trace-log.js +1 -1
- package/lib/telemetry/send-platform-issue-collect-log.js +1 -0
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/copy-directory.js +1 -1
- package/lib/utils/entity-with-id.js +1 -1
- package/lib/utils/file-utils.js +1 -1
- package/lib/utils/guides-cdn.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/is-non-interactive.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/rules-cdn.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +2 -1
package/lib/skills/main.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x3c77b3,_0x5f3482){const _0x122f7d=a169_0x14a1,_0x2fc033=_0x3c77b3();while(!![]){try{const _0x40ea82=parseInt(_0x122f7d(0x137))/0x1+parseInt(_0x122f7d(0x14c))/0x2*(parseInt(_0x122f7d(0x148))/0x3)+parseInt(_0x122f7d(0x157))/0x4*(parseInt(_0x122f7d(0x13f))/0x5)+parseInt(_0x122f7d(0x155))/0x6*(parseInt(_0x122f7d(0x13a))/0x7)+-parseInt(_0x122f7d(0x13d))/0x8+-parseInt(_0x122f7d(0x145))/0x9+parseInt(_0x122f7d(0x141))/0xa;if(_0x40ea82===_0x5f3482)break;else _0x2fc033['push'](_0x2fc033['shift']());}catch(_0x391dca){_0x2fc033['push'](_0x2fc033['shift']());}}}(a169_0x21b6,0x24c8e));import{logger}from'../utils/logger.js';import{CLI_BIN_NAME}from'../constant/cli.js';function a169_0x21b6(){const _0x5488c6=['\x20skill\x20--help\x0a\x20\x20','argv','6kVdavP','\x20skill\x20install\x0a\x0aEquivalent\x20command:\x20','4EumCYj','toLowerCase','\x20skill\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Interactive\x20skill\x20installation','--help','(empty)','\x0aLovrabet\x20Skill\x20-\x20Developer\x20Skill\x20Installation\x20Tool\x0a\x0aUsage:\x0a\x20\x20','140065TSExGL','replace','exit','193746rgIpAD','不支持的命令:\x20','length','1980888kIURKq','entries','967965sUARgU','skill','1733060NSeaRg','enable-bff-save','Error:\x20Unsupported\x20command:\x20','add','1773756eiLcpF','error','startsWith','27eqqxrd','-$1','push','setLogPath','13494kCRkzs','log','cwd','\x20skill\x20--help\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20help\x0a','includes','dangerously-bff-save','from'];a169_0x21b6=function(){return _0x5488c6;};return a169_0x21b6();}import{NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE}from'../skills/npx-skills-add.js';export function camelCaseFlagsToKebab(_0x10c65d){const _0xe94f60=a169_0x14a1,_0x516b5b=[];for(const [_0x441035,_0x184718]of Object[_0xe94f60(0x13e)](_0x10c65d)){if(_0x184718===!![]){const _0x3285f3=_0x441035[_0xe94f60(0x138)](/([A-Z])/g,_0xe94f60(0x149))[_0xe94f60(0x158)]();_0x516b5b[_0xe94f60(0x14a)](_0x3285f3);}}return _0x516b5b;}export function parseDynamicFlags(){const _0x945691=a169_0x14a1,_0x125fb8=[];for(let _0x184896=0x3;_0x184896<process[_0x945691(0x154)][_0x945691(0x13c)];_0x184896++){const _0x1b6985=process['argv'][_0x184896];if(_0x1b6985&&_0x1b6985[_0x945691(0x147)]('--')){const _0x365df5=_0x1b6985['slice'](0x2);_0x365df5&&!_0x365df5[_0x945691(0x150)]('=')&&_0x125fb8['push'](_0x365df5);}}return _0x125fb8;}export function getAllProvidedFlags(_0x1cbed8){const _0x3ef4e0=camelCaseFlagsToKebab(_0x1cbed8),_0x2382b4=parseDynamicFlags(),_0x3c6884=new Set([..._0x3ef4e0,..._0x2382b4]);return Array['from'](_0x3c6884);}export function normalizeLegacyBffSaveFlags(_0x242fae){const _0x5acf65=a169_0x14a1,_0x50379b=new Set(_0x242fae);return _0x50379b['has'](_0x5acf65(0x151))&&_0x50379b[_0x5acf65(0x144)](_0x5acf65(0x142)),Array[_0x5acf65(0x152)](_0x50379b);}const SKILLS_INSTALL_COMMAND_LINE=NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE;export async function skillsCommand(_0x1c3435,_0x23e073,_0x266524){const _0x26b3d3=a169_0x14a1;logger[_0x26b3d3(0x14b)](process[_0x26b3d3(0x14e)]());if(_0x266524?.['help']||_0x1c3435===_0x26b3d3(0x15a)){showHelp();return;}console[_0x26b3d3(0x146)](_0x26b3d3(0x143)+(_0x1c3435||_0x26b3d3(0x15b))),console['log']('\x0aAvailable\x20commands:'),console[_0x26b3d3(0x14d)]('\x20\x20'+CLI_BIN_NAME+_0x26b3d3(0x159)),console[_0x26b3d3(0x14d)]('\x20\x20'+CLI_BIN_NAME+_0x26b3d3(0x14f)),console['log'](''),console['log']('Equivalent\x20command:\x20'+SKILLS_INSTALL_COMMAND_LINE),logger[_0x26b3d3(0x146)](_0x26b3d3(0x140),_0x26b3d3(0x13b)+_0x1c3435),process[_0x26b3d3(0x139)](0x1);}function a169_0x14a1(_0x1bbccc,_0x82ff5){_0x1bbccc=_0x1bbccc-0x136;const _0x21b697=a169_0x21b6();let _0x14a17c=_0x21b697[_0x1bbccc];return _0x14a17c;}function showHelp(){const _0x1f6434=a169_0x14a1;console[_0x1f6434(0x14d)](_0x1f6434(0x136)+CLI_BIN_NAME+_0x1f6434(0x153)+CLI_BIN_NAME+_0x1f6434(0x156)+SKILLS_INSTALL_COMMAND_LINE+'\x0a\x0aNote:\x20npx\x20skills\x20selects\x20the\x20agent\x20and\x20writes\x20files;\x20guides\x20live\x20under\x20skills/lovrabet/guides/.\x0a');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a170_0x55b03d=a170_0x15c8;(function(_0x43798f,_0x38128d){const _0x412f5d=a170_0x15c8,_0x32a282=_0x43798f();while(!![]){try{const _0x5c92c9=-parseInt(_0x412f5d(0x95))/0x1*(-parseInt(_0x412f5d(0x97))/0x2)+-parseInt(_0x412f5d(0x98))/0x3*(parseInt(_0x412f5d(0x9d))/0x4)+parseInt(_0x412f5d(0x94))/0x5*(parseInt(_0x412f5d(0x89))/0x6)+parseInt(_0x412f5d(0x88))/0x7*(-parseInt(_0x412f5d(0x8f))/0x8)+-parseInt(_0x412f5d(0x91))/0x9+-parseInt(_0x412f5d(0x9c))/0xa+parseInt(_0x412f5d(0x83))/0xb*(-parseInt(_0x412f5d(0x96))/0xc);if(_0x5c92c9===_0x38128d)break;else _0x32a282['push'](_0x32a282['shift']());}catch(_0x256a9c){_0x32a282['push'](_0x32a282['shift']());}}}(a170_0x33bc,0x217a2));import{spawnSync}from'node:child_process';import{resolveNpmBin}from'../utils/platform.js';function a170_0x33bc(){const _0x396183=['remove','724860jTTwkf','inherit','Lovrabet','5slHpPi','4MhuOoZ','816yIiqek','100140fTUUTe','2670lcFJts','status','exit\x20','stdout','295600EMkexV','452ceHyjH','yes','trim','toString','lovrabet/lovrabet-skill','add','3377JXXGIp','skills','stderr','npx','skill','7SBhgfI','1571466gSRvjz','unknown','log','pipe','join','stdio','748184xrODIQ'];a170_0x33bc=function(){return _0x396183;};return a170_0x33bc();}export const NPX_FLAG_YES='-y';export const SKILLS_FLAG_GLOBAL='-g';export const SKILLS_FLAG_YES='-y';export const NPX_SKILLS_CLI=a170_0x55b03d(0x84);export const NPX_SKILLS_SUBCOMMAND_ADD=a170_0x55b03d(0x82);export const NPX_SKILLS_FLAG_SKILL='--skill';export const RABETBASE_SKILL_SOURCE='lovrabet/rabetbase';export const LEGACY_RABETBASE_SKILL_SOURCE=a170_0x55b03d(0x81);export const DEFAULT_RABETBASE_SKILL_NAME=a170_0x55b03d(0x93);export function buildNpxSkillsAddArgv(_0x32ca8a=DEFAULT_RABETBASE_SKILL_NAME){return[NPX_FLAG_YES,NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,RABETBASE_SKILL_SOURCE,NPX_SKILLS_FLAG_SKILL,_0x32ca8a];}export const NPX_SKILLS_ADD_COMMAND_LINE=['npx',...buildNpxSkillsAddArgv()][a170_0x55b03d(0x8d)]('\x20');export const NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE=['npx',NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,RABETBASE_SKILL_SOURCE,SKILLS_FLAG_GLOBAL,SKILLS_FLAG_YES]['join']('\x20');export function shouldSkipNpxSkillsAdd(){return process.env.RABETBASE_SKIP_NPX_SKILLS==='1';}export function runNpxSkillsAdd(_0x54ebb6,_0x42d535){const _0x888b4b=a170_0x55b03d;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x5a7d79=_0x42d535?.['stdio']??_0x888b4b(0x92),_0x44221c=resolveNpmBin(_0x888b4b(0x86)),_0x115a34=buildNpxSkillsAddArgv(_0x42d535?.['skill']??DEFAULT_RABETBASE_SKILL_NAME),_0x580b9e=['npx',..._0x115a34][_0x888b4b(0x8d)]('\x20');console[_0x888b4b(0x8b)]('*\x20'+_0x580b9e);const _0x5c913f=spawnSync(_0x44221c,_0x115a34,{'cwd':_0x54ebb6,'stdio':_0x5a7d79,'env':process.env,'shell':![]}),_0x4926fb=_0x5c913f[_0x888b4b(0x99)];if(_0x4926fb===0x0)return{'ok':!![],'status':0x0};let _0x1d3408=_0x888b4b(0x9a)+(_0x4926fb??_0x888b4b(0x8a));if(_0x5a7d79===_0x888b4b(0x8c)){const _0x44d03a=_0x5c913f[_0x888b4b(0x85)]?_0x5c913f[_0x888b4b(0x85)][_0x888b4b(0x80)]()[_0x888b4b(0x9f)]():'',_0x1eab34=_0x5c913f[_0x888b4b(0x9b)]?_0x5c913f[_0x888b4b(0x9b)][_0x888b4b(0x80)]()[_0x888b4b(0x9f)]():'';if(_0x44d03a)_0x1d3408=_0x44d03a;else{if(_0x1eab34)_0x1d3408=_0x1eab34;}}return{'ok':![],'status':_0x4926fb??null,'error':_0x1d3408};}function a170_0x15c8(_0x7419f5,_0x19a420){_0x7419f5=_0x7419f5-0x80;const _0x33bc8a=a170_0x33bc();let _0x15c80d=_0x33bc8a[_0x7419f5];return _0x15c80d;}export function runNpxSkillsRemove(_0x5ea089,_0x5c45d8,_0x277987=LEGACY_RABETBASE_SKILL_SOURCE){const _0x2fbcf0=a170_0x55b03d;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0xb584e0=_0x5c45d8?.[_0x2fbcf0(0x8e)]??_0x2fbcf0(0x92),_0x5d5644=resolveNpmBin(_0x2fbcf0(0x86)),_0xab7967=[NPX_FLAG_YES,NPX_SKILLS_CLI,_0x2fbcf0(0x90),_0x277987,NPX_SKILLS_FLAG_SKILL,_0x5c45d8?.[_0x2fbcf0(0x87)]??DEFAULT_RABETBASE_SKILL_NAME,..._0x5c45d8?.[_0x2fbcf0(0x9e)]?['-y']:[]],_0x160ac4=[_0x5d5644,..._0xab7967][_0x2fbcf0(0x8d)]('\x20');console['log']('*\x20'+_0x160ac4);const _0xb64432=spawnSync(_0x5d5644,_0xab7967,{'cwd':_0x5ea089,'stdio':_0xb584e0,'env':process.env,'shell':![]}),_0x3392f0=_0xb64432[_0x2fbcf0(0x99)];if(_0x3392f0===0x0)return{'ok':!![],'status':0x0};let _0x1caf2a='exit\x20'+(_0x3392f0??_0x2fbcf0(0x8a));if(_0xb584e0===_0x2fbcf0(0x8c)){const _0x27b11a=_0xb64432[_0x2fbcf0(0x85)]?_0xb64432['stderr'][_0x2fbcf0(0x80)]()[_0x2fbcf0(0x9f)]():'',_0x194342=_0xb64432[_0x2fbcf0(0x9b)]?_0xb64432['stdout'][_0x2fbcf0(0x80)]()[_0x2fbcf0(0x9f)]():'';if(_0x27b11a)_0x1caf2a=_0x27b11a;else{if(_0x194342)_0x1caf2a=_0x194342;}}return{'ok':![],'status':_0x3392f0??null,'error':_0x1caf2a};}export function runNpxSkillsAddGlobal(_0x627de8,_0x3f3703,_0x7584f1){const _0x40f141=a170_0x55b03d;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x22d52c=_0x7584f1?.[_0x40f141(0x8e)]??_0x40f141(0x92),_0x5aa50e=resolveNpmBin('npx'),_0x20c50a=[NPX_FLAG_YES,NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,_0x3f3703,SKILLS_FLAG_GLOBAL,SKILLS_FLAG_YES],_0x355127=[_0x40f141(0x86),NPX_SKILLS_CLI,NPX_SKILLS_SUBCOMMAND_ADD,_0x3f3703,SKILLS_FLAG_GLOBAL,SKILLS_FLAG_YES][_0x40f141(0x8d)]('\x20');console[_0x40f141(0x8b)]('*\x20'+_0x355127);const _0x5c0c4f=spawnSync(_0x5aa50e,_0x20c50a,{'cwd':_0x627de8,'stdio':_0x22d52c,'env':process.env,'shell':![]}),_0x4a9dc9=_0x5c0c4f[_0x40f141(0x99)];if(_0x4a9dc9===0x0)return{'ok':!![],'status':0x0};let _0x29790f='exit\x20'+(_0x4a9dc9??'unknown');if(_0x22d52c===_0x40f141(0x8c)){const _0x115003=_0x5c0c4f[_0x40f141(0x85)]?_0x5c0c4f[_0x40f141(0x85)]['toString']()[_0x40f141(0x9f)]():'',_0x58173f=_0x5c0c4f[_0x40f141(0x9b)]?_0x5c0c4f['stdout'][_0x40f141(0x80)]()['trim']():'';if(_0x115003)_0x29790f=_0x115003;else{if(_0x58173f)_0x29790f=_0x58173f;}}return{'ok':![],'status':_0x4a9dc9??null,'error':_0x29790f};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x2214c8,_0xb24319){const _0x1a3228=a171_0x5f4e,_0x4ce7c1=_0x2214c8();while(!![]){try{const _0x4b3e00=parseInt(_0x1a3228(0x13e))/0x1*(-parseInt(_0x1a3228(0x146))/0x2)+parseInt(_0x1a3228(0x142))/0x3+parseInt(_0x1a3228(0x13f))/0x4+parseInt(_0x1a3228(0x148))/0x5*(parseInt(_0x1a3228(0x137))/0x6)+-parseInt(_0x1a3228(0x136))/0x7*(-parseInt(_0x1a3228(0x13a))/0x8)+parseInt(_0x1a3228(0x144))/0x9+-parseInt(_0x1a3228(0x135))/0xa*(parseInt(_0x1a3228(0x147))/0xb);if(_0x4b3e00===_0xb24319)break;else _0x4ce7c1['push'](_0x4ce7c1['shift']());}catch(_0x3b8b50){_0x4ce7c1['push'](_0x4ce7c1['shift']());}}}(a171_0x51f9,0xa21e7));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];function a171_0x51f9(){const _0x45f8fe=['7jIiGkM','4812uUBYIc','service','rabetbase.command','6898376kJHhAO','flags','error','some','157uVjDYp','3655376BghMah','test','command','869559iygRiP','entries','9568422jvNzve','durationMs','15074iRCJjE','11Uazhgh','2725CKGjdQ','17188940DpjhIf'];a171_0x51f9=function(){return _0x45f8fe;};return a171_0x51f9();}function isSensitiveKey(_0x3b769f){const _0x5cb46e=a171_0x5f4e;return SENSITIVE_PATTERNS[_0x5cb46e(0x13d)](_0x530dd0=>_0x530dd0[_0x5cb46e(0x140)](_0x3b769f));}function sanitizeFlags(_0x4e6948){const _0x45a6f8=a171_0x5f4e,_0x2efffa={};for(const [_0x4f626f,_0x4f0d92]of Object[_0x45a6f8(0x143)](_0x4e6948)){isSensitiveKey(_0x4f626f)?_0x2efffa[_0x4f626f]=_0x4f0d92!=null&&_0x4f0d92!==''?'[REDACTED]':_0x4f0d92:_0x2efffa[_0x4f626f]=_0x4f0d92;}return _0x2efffa;}function a171_0x5f4e(_0x1cbde7,_0x1bc0ba){_0x1cbde7=_0x1cbde7-0x135;const _0x51f9cd=a171_0x51f9();let _0x5f4ef2=_0x51f9cd[_0x1cbde7];return _0x5f4ef2;}export async function reportCommandTrace(_0x112c31){const _0x32d2f1=a171_0x5f4e;try{const _0x86586b=sanitizeFlags(_0x112c31[_0x32d2f1(0x13b)]);await sendCliTraceLog({'spanName':_0x32d2f1(0x139),'logData':{'command.cli_version':getCliVersion(),'command.service':_0x112c31[_0x32d2f1(0x138)],'command.name':_0x112c31[_0x32d2f1(0x141)],'command.flags':JSON['stringify'](_0x86586b),..._0x112c31[_0x32d2f1(0x145)]!=null?{'command.duration_ms':_0x112c31[_0x32d2f1(0x145)]}:{},..._0x112c31['error']?{'command.error':_0x112c31[_0x32d2f1(0x13c)]instanceof Error?_0x112c31[_0x32d2f1(0x13c)]['message']:String(_0x112c31[_0x32d2f1(0x13c)])}:{}}});}catch{}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a172_0xb715(_0x4992a0,_0x38bd71){_0x4992a0=_0x4992a0-0x126;var _0xfdd6c2=a172_0xfdd6();var _0xb715b0=_0xfdd6c2[_0x4992a0];return _0xb715b0;}function a172_0xfdd6(){var _0x189a34=['519730Rduzrd','3492lSlNeE','2276568OXuUtA','2149008qpbVmh','3JXexFt','service','cli.help','error','102dgvvIv','204820kHKAWe','10330kvuJKb','224neYuwB','18736993tLcchs','426926bKmgil'];a172_0xfdd6=function(){return _0x189a34;};return a172_0xfdd6();}(function(_0x1b517d,_0x41cff7){var _0x4c8806=a172_0xb715,_0x49d177=_0x1b517d();while(!![]){try{var _0x250807=-parseInt(_0x4c8806(0x132))/0x1+-parseInt(_0x4c8806(0x127))/0x2+parseInt(_0x4c8806(0x129))/0x3*(-parseInt(_0x4c8806(0x128))/0x4)+parseInt(_0x4c8806(0x133))/0x5*(parseInt(_0x4c8806(0x12d))/0x6)+-parseInt(_0x4c8806(0x12e))/0x7*(parseInt(_0x4c8806(0x130))/0x8)+-parseInt(_0x4c8806(0x126))/0x9*(-parseInt(_0x4c8806(0x12f))/0xa)+parseInt(_0x4c8806(0x131))/0xb;if(_0x250807===_0x41cff7)break;else _0x49d177['push'](_0x49d177['shift']());}catch(_0x52bb4a){_0x49d177['push'](_0x49d177['shift']());}}}(a172_0xfdd6,0xe7d03));import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';export async function reportCliHelpTrace(_0x459ce5,_0x41121a){var _0x46c74e=a172_0xb715;try{await sendCliTraceLog({'spanName':_0x46c74e(0x12b),'logData':{'rabetbase.help.kind':_0x459ce5,..._0x41121a?.[_0x46c74e(0x12a)]&&{'rabetbase.help.service':_0x41121a['service']}}});}catch(_0x30fa89){console[_0x46c74e(0x12c)]('Failed\x20to\x20report\x20CLI\x20help\x20trace:',_0x30fa89);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x2c9aee,_0x510a09){const _0x3a0b83=a173_0x2ca2,_0x367660=_0x2c9aee();while(!![]){try{const _0x1293bf=parseInt(_0x3a0b83(0xf7))/0x1+parseInt(_0x3a0b83(0xfa))/0x2*(parseInt(_0x3a0b83(0xf9))/0x3)+parseInt(_0x3a0b83(0x103))/0x4+-parseInt(_0x3a0b83(0x102))/0x5*(parseInt(_0x3a0b83(0x101))/0x6)+parseInt(_0x3a0b83(0xff))/0x7*(-parseInt(_0x3a0b83(0xf8))/0x8)+-parseInt(_0x3a0b83(0x100))/0x9+-parseInt(_0x3a0b83(0xfb))/0xa;if(_0x1293bf===_0x510a09)break;else _0x367660['push'](_0x367660['shift']());}catch(_0x5c4eb6){_0x367660['push'](_0x367660['shift']());}}}(a173_0x49ae,0x9f156));import a173_0x826f84 from'node:os';import{VERSION,GIT_COMMIT}from'../generated/build-info.js';function a173_0x49ae(){const _0x4d8884=['nickname','1069947zsgvHG','304HqxTvT','1284225lFUoaF','4UnVcjc','457520dxQGcr','production','username','daily','142709mkwpSt','6760278gCbLOO','6vBgOpU','4605665CLUfLi','4872968rUsPct','userInfo','rabetbase-cli','unknown'];a173_0x49ae=function(){return _0x4d8884;};return a173_0x49ae();}import{getSessionUserInfo}from'../auth/get-session-user.js';import{setTraceConfig,getOtelLoggerVersion}from'@lovrabet/otel-logger';import{NPM_PACKAGE_NAME}from'../constant/cli.js';let cliOtelTraceInitialized=![];function a173_0x2ca2(_0xf28022,_0x4c90dc){_0xf28022=_0xf28022-0xf5;const _0x49aebe=a173_0x49ae();let _0x2ca2b2=_0x49aebe[_0xf28022];return _0x2ca2b2;}export async function ensureCliOtelTraceConfig(){const _0x5f34b3=a173_0x2ca2,_0x52b797=await getSessionUserInfo();if(!cliOtelTraceInitialized){const _0x47790a=_0x52b797?.['user'];setTraceConfig({'otelLoggerVersion':getOtelLoggerVersion(),'serviceName':NPM_PACKAGE_NAME,'serviceVersion':GIT_COMMIT!==_0x5f34b3(0xf5)?VERSION+'+'+GIT_COMMIT:VERSION,'serviceEnv':process.env.RABETBASE_ENV??(process.env.RABETBASE_E2E_DAILY==='1'?_0x5f34b3(0xfe):_0x5f34b3(0xfc)),'username':_0x47790a?.[_0x5f34b3(0xfd)]??a173_0x826f84[_0x5f34b3(0x104)]()[_0x5f34b3(0xfd)]??_0x5f34b3(0x105),..._0x47790a&&{'nickname':_0x47790a[_0x5f34b3(0xf6)]}}),cliOtelTraceInitialized=!![];}return _0x52b797;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5fa81a,_0x13aac6){const _0x5dcabe=a174_0x2983,_0x881ec3=_0x5fa81a();while(!![]){try{const _0x24ce2e=parseInt(_0x5dcabe(0x172))/0x1*(parseInt(_0x5dcabe(0x17a))/0x2)+-parseInt(_0x5dcabe(0x176))/0x3+-parseInt(_0x5dcabe(0x17d))/0x4*(-parseInt(_0x5dcabe(0x175))/0x5)+-parseInt(_0x5dcabe(0x17b))/0x6+-parseInt(_0x5dcabe(0x177))/0x7*(parseInt(_0x5dcabe(0x178))/0x8)+-parseInt(_0x5dcabe(0x170))/0x9+parseInt(_0x5dcabe(0x174))/0xa*(parseInt(_0x5dcabe(0x17c))/0xb);if(_0x24ce2e===_0x13aac6)break;else _0x881ec3['push'](_0x881ec3['shift']());}catch(_0x1bda77){_0x881ec3['push'](_0x881ec3['shift']());}}}(a174_0x1ba7,0x2b08c));import{shutdownTraces}from'@lovrabet/otel-logger';function a174_0x1ba7(){const _0x2df5a4=['SIGTERM','150dkUajQ','36055Zrgktq','811674sXhTXV','7kxcjZL','394824XEvusZ','once','1106PPJgqC','328740NGRQjn','412544UFzRMg','92eeZRDI','SIGINT','exit','2433132SmpVHm','beforeExit','168pOzmEe'];a174_0x1ba7=function(){return _0x2df5a4;};return a174_0x1ba7();}let shutdownPromise=null;export async function flushOtelNodeIfUsed(){if(shutdownPromise)return shutdownPromise;return shutdownPromise=((async()=>{try{await shutdownTraces();}catch{}})()),shutdownPromise;}export function registerOtelShutdownOnExit(){const _0x6fb549=a174_0x2983;process['once'](_0x6fb549(0x171),()=>{void flushOtelNodeIfUsed();});const _0x577e60=()=>{void flushOtelNodeIfUsed()['then'](()=>process['exit'](0x0));};process[_0x6fb549(0x179)](_0x6fb549(0x17e),_0x577e60),process['once'](_0x6fb549(0x173),_0x577e60);}function a174_0x2983(_0x1693a4,_0x1c8c7e){_0x1693a4=_0x1693a4-0x16f;const _0x1ba73a=a174_0x1ba7();let _0x2983bc=_0x1ba73a[_0x1693a4];return _0x2983bc;}export async function exitWithOtelShutdown(_0x3ec66c){const _0x276a69=a174_0x2983;await flushOtelNodeIfUsed(),process[_0x276a69(0x16f)](_0x3ec66c);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a175_0x18e485=a175_0x4223;(function(_0x3b5101,_0x18aa15){const _0x508c65=a175_0x4223,_0x430537=_0x3b5101();while(!![]){try{const _0x5d62a2=parseInt(_0x508c65(0x1e0))/0x1+parseInt(_0x508c65(0x1e5))/0x2*(-parseInt(_0x508c65(0x1e2))/0x3)+-parseInt(_0x508c65(0x1ed))/0x4+-parseInt(_0x508c65(0x1ec))/0x5*(-parseInt(_0x508c65(0x1e7))/0x6)+-parseInt(_0x508c65(0x1e6))/0x7*(-parseInt(_0x508c65(0x1e4))/0x8)+-parseInt(_0x508c65(0x1e9))/0x9*(-parseInt(_0x508c65(0x1de))/0xa)+-parseInt(_0x508c65(0x1e8))/0xb*(-parseInt(_0x508c65(0x1ea))/0xc);if(_0x5d62a2===_0x18aa15)break;else _0x430537['push'](_0x430537['shift']());}catch(_0x1afb2c){_0x430537['push'](_0x430537['shift']());}}}(a175_0x32e3,0x1f41e));import{sendTraceLog}from'@lovrabet/otel-logger';function a175_0x32e3(){const _0xcbd374=['789804jkSpSg','70hsTXIA','version','15178psAHwt','traceparent','122907zrToIZ','logData','8veNkTi','10dSYHXy','296338xSTgaw','6CBVbdI','11aHZMMD','174195ECDecU','2856288qaVKYK','rabetbase-cli','496525NdjtaY'];a175_0x32e3=function(){return _0xcbd374;};return a175_0x32e3();}import{ensureCliOtelTraceConfig}from'../telemetry/ensure-cli-otel-config.js';import{getCliVersion}from'../utils/version.js';const DEFAULT_TRACE_NAME=a175_0x18e485(0x1eb);function a175_0x4223(_0x1c09fc,_0x28b2be){_0x1c09fc=_0x1c09fc-0x1de;const _0x32e397=a175_0x32e3();let _0x4223d2=_0x32e397[_0x1c09fc];return _0x4223d2;}export async function sendCliTraceLog(_0x59c915){const _0x50247a=a175_0x18e485;await ensureCliOtelTraceConfig(),sendTraceLog({'traceName':_0x59c915['traceName']??DEFAULT_TRACE_NAME,'version':_0x59c915[_0x50247a(0x1df)]??getCliVersion(),'spanName':_0x59c915['spanName'],'eventType':'manual','logData':_0x59c915[_0x50247a(0x1e3)],..._0x59c915[_0x50247a(0x1e1)]&&{'traceparent':_0x59c915['traceparent']}});}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const a176_0x5ed276=a176_0x5f50;function a176_0x4ff5(){const _0x50a77f=['12BeBesF','188235CYxSYE','88461XtIkGD','411385igcPjy','7ETASmU','272588ZBpMgs','85657RTwqgu','328AXLuAL','title','544686IVSnAw','250cORlvN','description','platform-issue-log-collect','18783hgODGd'];a176_0x4ff5=function(){return _0x50a77f;};return a176_0x4ff5();}(function(_0x1b6f68,_0x20c3f9){const _0x561d1b=a176_0x5f50,_0x59e4cc=_0x1b6f68();while(!![]){try{const _0x5bc042=-parseInt(_0x561d1b(0x125))/0x1+parseInt(_0x561d1b(0x128))/0x2+-parseInt(_0x561d1b(0x124))/0x3*(-parseInt(_0x561d1b(0x123))/0x4)+-parseInt(_0x561d1b(0x126))/0x5+-parseInt(_0x561d1b(0x11e))/0x6*(-parseInt(_0x561d1b(0x127))/0x7)+parseInt(_0x561d1b(0x12a))/0x8*(parseInt(_0x561d1b(0x122))/0x9)+parseInt(_0x561d1b(0x11f))/0xa*(-parseInt(_0x561d1b(0x129))/0xb);if(_0x5bc042===_0x20c3f9)break;else _0x59e4cc['push'](_0x59e4cc['shift']());}catch(_0x40c6fd){_0x59e4cc['push'](_0x59e4cc['shift']());}}}(a176_0x4ff5,0x21128));import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';export const PLATFORM_ISSUE_TRACE_NAME=a176_0x5ed276(0x121);function a176_0x5f50(_0x282802,_0x29cf4c){_0x282802=_0x282802-0x11e;const _0x4ff527=a176_0x4ff5();let _0x5f500c=_0x4ff527[_0x282802];return _0x5f500c;}export const PLATFORM_ISSUE_SPAN_NAME='issue.log.collect';export async function sendPlatformIssueCollectLog(_0x46cd0b){const _0x661881=a176_0x5ed276;await sendCliTraceLog({'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logData':{'issue.title':_0x46cd0b[_0x661881(0x12b)],'issue.description':_0x46cd0b[_0x661881(0x120)]}});}
|
package/lib/utils/ai_config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a178_0xe3128d=a178_0x1e60;(function(_0x3d0fda,_0x496967){const _0x1f666a=a178_0x1e60,_0x3e473f=_0x3d0fda();while(!![]){try{const _0x17692e=-parseInt(_0x1f666a(0x1a9))/0x1*(parseInt(_0x1f666a(0x1b0))/0x2)+parseInt(_0x1f666a(0x1c4))/0x3+parseInt(_0x1f666a(0x1b9))/0x4+-parseInt(_0x1f666a(0x1c1))/0x5*(parseInt(_0x1f666a(0x1bb))/0x6)+-parseInt(_0x1f666a(0x1a5))/0x7+-parseInt(_0x1f666a(0x1c0))/0x8+parseInt(_0x1f666a(0x1c2))/0x9;if(_0x17692e===_0x496967)break;else _0x3e473f['push'](_0x3e473f['shift']());}catch(_0x4e083a){_0x3e473f['push'](_0x3e473f['shift']());}}}(a178_0x15f8,0x379b6));export const CORE_IDE_CONFIGS={'cursor':{'name':'Cursor','description':a178_0xe3128d(0x1aa),'folders':[a178_0xe3128d(0x1b1),a178_0xe3128d(0x1cc)],'files':[{'type':a178_0xe3128d(0x19a),'path':a178_0xe3128d(0x1c3),'template':a178_0xe3128d(0x1a3)}]},'windsurf':{'name':'Windsurf','description':'Windsurf\x20IDE','folders':[a178_0xe3128d(0x1ac)],'files':[{'type':a178_0xe3128d(0x19a),'path':a178_0xe3128d(0x1b5),'template':a178_0xe3128d(0x1a3)}]},'claude':{'name':a178_0xe3128d(0x19d),'description':a178_0xe3128d(0x19d),'folders':[a178_0xe3128d(0x1b4)],'files':[{'type':a178_0xe3128d(0x19a),'path':a178_0xe3128d(0x1cd),'template':a178_0xe3128d(0x1a3)}]},'cline':{'name':'Cline','description':a178_0xe3128d(0x1cf),'folders':[a178_0xe3128d(0x19f)],'files':[{'type':a178_0xe3128d(0x19a),'path':a178_0xe3128d(0x1a4),'template':'SKILL.md.tpl'}]},'codex':{'name':a178_0xe3128d(0x1a2),'description':'Codex\x20IDE','folders':['.codex'],'files':[{'type':a178_0xe3128d(0x19a),'path':a178_0xe3128d(0x1b3),'template':a178_0xe3128d(0x1a3)}]},'opencode':{'name':a178_0xe3128d(0x199),'description':a178_0xe3128d(0x1bf),'folders':[a178_0xe3128d(0x1af)],'files':[{'type':'file','path':'.opencode/skills/lovrabet/SKILL.md','template':a178_0xe3128d(0x1a3)}]},'qoder':{'name':a178_0xe3128d(0x1ad),'description':a178_0xe3128d(0x1ae),'folders':[a178_0xe3128d(0x1ab)],'files':[{'type':a178_0xe3128d(0x19a),'path':a178_0xe3128d(0x19e),'template':a178_0xe3128d(0x1a3)},{'type':'file','path':a178_0xe3128d(0x19b),'template':a178_0xe3128d(0x1a3)}]},'codebuddy':{'name':a178_0xe3128d(0x19c),'description':'CodeBuddy\x20IDE','folders':[a178_0xe3128d(0x1b2)],'files':[{'type':'file','path':a178_0xe3128d(0x1c6),'template':a178_0xe3128d(0x1a3)}]},'trae':{'name':a178_0xe3128d(0x1cb),'description':a178_0xe3128d(0x1bd),'folders':[a178_0xe3128d(0x1a7)],'files':[{'type':'file','path':'.trae/skills/lovrabet/SKILL.md','template':a178_0xe3128d(0x1a3)}]}};function a178_0x1e60(_0x5bb424,_0x5eeb61){_0x5bb424=_0x5bb424-0x198;const _0x15f849=a178_0x15f8();let _0x1e6050=_0x15f849[_0x5bb424];return _0x1e6050;}export const IDE_CONFIGS={...CORE_IDE_CONFIGS,'agent':{'name':a178_0xe3128d(0x1c7),'description':a178_0xe3128d(0x1a1),'folders':['.agent'],'files':[{'type':a178_0xe3128d(0x19a),'path':a178_0xe3128d(0x1a6),'template':a178_0xe3128d(0x1a3)}]},'antigravity':{'name':a178_0xe3128d(0x1bc),'description':a178_0xe3128d(0x198),'folders':[a178_0xe3128d(0x1b8)],'files':[{'type':'file','path':a178_0xe3128d(0x1a6),'template':a178_0xe3128d(0x1a3)}]}};export const CORE_IDE_LIST=[a178_0xe3128d(0x1ca),a178_0xe3128d(0x1c8),a178_0xe3128d(0x1c5),a178_0xe3128d(0x1ce),a178_0xe3128d(0x1b6),a178_0xe3128d(0x1ba),'qoder','trae',a178_0xe3128d(0x1c9)];function a178_0x15f8(){const _0x207733=['.windsurf/workflows/rabetbase.md','cursor','trae','.agent','1059564qBNiPX','opencode','6EhSmNC','Antigravity','Trae\x20IDE','antigravity','OpenCode\x20IDE','2287680dpXHWv','300170gNCWDl','8058249BblaZW','.cursor/skills/rabetbase.md','12798yvvzFr','codebuddy','.codebuddy/skills/lovrabet/SKILL.md','其他\x20(通用模板)','cline','windsurf','claude','Trae','.cursor','.claude/skills/lovrabet/SKILL.md','codex','Cline\x20IDE','Antigravity\x20IDE','OpenCode','file','.qoder/skills/lovrabet/SKILL.md','CodeBuddy','Claude\x20Code','.qoder/rules/rabetbase.md','.cline','qoder','通用模板\x20-\x20兜底方案','Codex','SKILL.md.tpl','.cline/skills/lovrabet/SKILL.md','2322509LVISBv','.agent/skills/lovrabet/SKILL.md','.trae','agent','258971jdYAqL','Cursor\x20IDE','.qoder','.windsurf','Qoder','Qoder\x20IDE','.opencode','2vpBLyP','.cursorrules','.codebuddy','.codex/skills/lovrabet/SKILL.md','.claude'];a178_0x15f8=function(){return _0x207733;};return a178_0x15f8();}export const IDE_LIST=[a178_0xe3128d(0x1be),a178_0xe3128d(0x1ca),a178_0xe3128d(0x1c8),a178_0xe3128d(0x1c5),a178_0xe3128d(0x1ce),a178_0xe3128d(0x1b6),a178_0xe3128d(0x1ba),a178_0xe3128d(0x1a0),a178_0xe3128d(0x1b7),a178_0xe3128d(0x1c9),a178_0xe3128d(0x1a8)];export const ALL_CORE_IDES=[a178_0xe3128d(0x1b6),'windsurf',a178_0xe3128d(0x1ca),a178_0xe3128d(0x1c8),'codex',a178_0xe3128d(0x1ba),a178_0xe3128d(0x1a0),a178_0xe3128d(0x1c5),'trae'];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5664d6,_0x3d1be3){const _0x1525a4=a179_0xee35,_0x4b2d65=_0x5664d6();while(!![]){try{const _0x22b6f7=parseInt(_0x1525a4(0x1bf))/0x1*(-parseInt(_0x1525a4(0x1c0))/0x2)+parseInt(_0x1525a4(0x1b9))/0x3+-parseInt(_0x1525a4(0x1b5))/0x4*(parseInt(_0x1525a4(0x1bc))/0x5)+-parseInt(_0x1525a4(0x1ba))/0x6*(-parseInt(_0x1525a4(0x1bb))/0x7)+parseInt(_0x1525a4(0x1bd))/0x8*(parseInt(_0x1525a4(0x1b8))/0x9)+-parseInt(_0x1525a4(0x1b6))/0xa+parseInt(_0x1525a4(0x1be))/0xb*(parseInt(_0x1525a4(0x1b7))/0xc);if(_0x22b6f7===_0x3d1be3)break;else _0x4b2d65['push'](_0x4b2d65['shift']());}catch(_0x181fe3){_0x4b2d65['push'](_0x4b2d65['shift']());}}}(a179_0x4929,0x87eef));import{createJqFilter,resolveBundledJqPaths}from'@lovrabet/cli-framework';function a179_0xee35(_0x329012,_0x267209){_0x329012=_0x329012-0x1b5;const _0x4929ad=a179_0x4929();let _0xee356c=_0x4929ad[_0x329012];return _0xee356c;}import{CliErrors}from'../errors.js';function a179_0x4929(){const _0x1cec76=['23SOgcHq','13914fKgDjg','8YioeJv','3821140cGffBr','51588nowYqi','17001opPIyI','2609163ArITHO','6WOxVPV','6217470amdLOL','2359505NwvNnT','496Tczqbc','429QlDSXH'];a179_0x4929=function(){return _0x1cec76;};return a179_0x4929();}export const applyJqFilter=createJqFilter(CliErrors,{'bundledJqPaths':resolveBundledJqPaths()});
|
package/lib/utils/cdn-config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x116e5c,_0x2e4cb7){const _0x31e00f=a180_0x51d4,_0x41c02b=_0x116e5c();while(!![]){try{const _0xbe0f06=parseInt(_0x31e00f(0x14a))/0x1+parseInt(_0x31e00f(0x147))/0x2+parseInt(_0x31e00f(0x150))/0x3*(parseInt(_0x31e00f(0x14b))/0x4)+parseInt(_0x31e00f(0x14f))/0x5+parseInt(_0x31e00f(0x152))/0x6*(parseInt(_0x31e00f(0x14e))/0x7)+-parseInt(_0x31e00f(0x14c))/0x8+-parseInt(_0x31e00f(0x151))/0x9;if(_0xbe0f06===_0x2e4cb7)break;else _0x41c02b['push'](_0x41c02b['shift']());}catch(_0x4d963f){_0x41c02b['push'](_0x41c02b['shift']());}}}(a180_0x39d5,0xb0ec7));import{getTemplateBaseUrl}from'../utils/config.js';export async function fetchCdnConfig(){const _0xc4b27e=a180_0x51d4,_0x327973=getTemplateBaseUrl(),_0x2cf644=[_0x327973+'/config.json',_0x327973+_0xc4b27e(0x148)];for(const _0x281ad2 of _0x2cf644){try{const _0x2f9409=await fetch(_0x281ad2,{'headers':{'Accept':'application/json'}});if(!_0x2f9409['ok'])continue;const _0x262b92=await _0x2f9409['json']();if(!_0x262b92[_0xc4b27e(0x14d)]?.[_0xc4b27e(0x146)]||!_0x262b92[_0xc4b27e(0x145)]?.['node']?.[_0xc4b27e(0x146)])continue;return _0x262b92;}catch{}}return null;}let cachedConfig=null,cacheTime=0x0;function a180_0x51d4(_0x4efec1,_0x5268cb){_0x4efec1=_0x4efec1-0x145;const _0x39d528=a180_0x39d5();let _0x51d431=_0x39d528[_0x4efec1];return _0x51d431;}const CACHE_TTL=0x5*0x3c*0x3e8,FAILURE_CACHE_TTL=0x3c*0x3e8;let hasCachedConfig=![];export async function getCdnConfig(){const _0x529b68=a180_0x51d4,_0x5a1bf6=Date[_0x529b68(0x149)]();if(hasCachedConfig){const _0xaec297=cachedConfig?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x5a1bf6-cacheTime<_0xaec297)return cachedConfig;}const _0x2bcdfb=await fetchCdnConfig();return cachedConfig=_0x2bcdfb,cacheTime=_0x5a1bf6,hasCachedConfig=!![],_0x2bcdfb;}function a180_0x39d5(){const _0x4f16dd=['cli','7GZTccu','2739900ZiSvnp','2995281esovut','25266708CZdIDm','4247556MZYqAF','sdk','stableVersion','1300540CSoNzn','/config/index.json','now','774803jcyxdh','4Lkpowc','1178520mIuPkI'];a180_0x39d5=function(){return _0x4f16dd;};return a180_0x39d5();}export function clearCdnConfigCache(){cachedConfig=null,cacheTime=0x0,hasCachedConfig=![];}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a181_0x14bb64=a181_0x5939;(function(_0x1ea656,_0x34b113){const _0x17e7da=a181_0x5939,_0x5ab607=_0x1ea656();while(!![]){try{const _0x41fd36=-parseInt(_0x17e7da(0xf4))/0x1+parseInt(_0x17e7da(0xe0))/0x2*(parseInt(_0x17e7da(0xe8))/0x3)+-parseInt(_0x17e7da(0xdc))/0x4+parseInt(_0x17e7da(0xed))/0x5*(-parseInt(_0x17e7da(0xd4))/0x6)+parseInt(_0x17e7da(0xf3))/0x7*(-parseInt(_0x17e7da(0xe4))/0x8)+parseInt(_0x17e7da(0xeb))/0x9+parseInt(_0x17e7da(0xf6))/0xa;if(_0x41fd36===_0x34b113)break;else _0x5ab607['push'](_0x5ab607['shift']());}catch(_0x292706){_0x5ab607['push'](_0x5ab607['shift']());}}}(a181_0x5436,0xd954f));import a181_0x54b216 from'node:fs';function a181_0x5436(){const _0x2d1b94=['version','utf8','180320tqfjSD','minVersion','dependencies','devDependencies','2026msQgdC','parse','\x1b[1m','packageName','1736KfpSui','existsSync','join','1.2.0','4371yHMqUv','\x20\x20\x20Upgrade\x20command:\x20','all','236025MyVtVD','node_modules','5sqQAtq','needsUpgrade','coerce','readFileSync','node','package.json','56385QFpolh','1739606bDFAbW','test','46462030XkZVuQ','latest','\x20\x20\x20Current\x20version:\x20','stableVersion','10353342mngTvR','some','npm\x20install\x20','log','sdk','@lovrabet/sdk'];a181_0x5436=function(){return _0x2d1b94;};return a181_0x5436();}import a181_0x116c52 from'node:path';import a181_0x1c6139 from'semver';import{getCdnConfig}from'../utils/cdn-config.js';function a181_0x5939(_0x268e0e,_0x285432){_0x268e0e=_0x268e0e-0xd4;const _0x54368c=a181_0x5436();let _0x593946=_0x54368c[_0x268e0e];return _0x593946;}const FALLBACK_MIN_SDK_VERSION=a181_0x14bb64(0xe7);function isNonNumericVersion(_0x16aff7){const _0x18df57=a181_0x14bb64,_0x4de397=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x4de397[_0x18df57(0xd5)](_0x25ab6e=>_0x25ab6e[_0x18df57(0xf5)](_0x16aff7));}function getInstalledVersion(_0x33e501,_0x1d858d){const _0x214966=a181_0x14bb64;try{const _0x4d938e=a181_0x116c52[_0x214966(0xe6)](_0x33e501,_0x214966(0xec),_0x1d858d,_0x214966(0xf2));if(a181_0x54b216[_0x214966(0xe5)](_0x4d938e)){const _0x5da1a0=JSON[_0x214966(0xe1)](a181_0x54b216[_0x214966(0xf0)](_0x4d938e,'utf-8'));return _0x5da1a0[_0x214966(0xda)]||null;}}catch{}return null;}async function getSdkStableVersion(){const _0x2a5be1=a181_0x14bb64;try{const _0x23577a=await getCdnConfig();return _0x23577a?.['sdk']?.['node']?.[_0x2a5be1(0xf9)]||null;}catch{return null;}}async function getSdkPackageName(){const _0x1170d5=a181_0x14bb64;try{const _0x3fcdbb=await getCdnConfig();return _0x3fcdbb?.[_0x1170d5(0xd8)]?.[_0x1170d5(0xf1)]?.[_0x1170d5(0xe3)]||_0x1170d5(0xd9);}catch{return _0x1170d5(0xd9);}}export async function checkSdkVersion(_0x4bd138){const _0x2d92b0=a181_0x14bb64,_0x401394=a181_0x116c52[_0x2d92b0(0xe6)](_0x4bd138,_0x2d92b0(0xf2)),[_0x39dbc4,_0x38be69]=await Promise[_0x2d92b0(0xea)]([getSdkStableVersion(),getSdkPackageName()]),_0x505922=_0x39dbc4||FALLBACK_MIN_SDK_VERSION;if(!a181_0x54b216[_0x2d92b0(0xe5)](_0x401394))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x505922,'packageName':_0x38be69,'stableVersion':_0x39dbc4};try{const _0x5f3e3e=JSON[_0x2d92b0(0xe1)](a181_0x54b216[_0x2d92b0(0xf0)](_0x401394,'utf8')),_0x16aef7=_0x5f3e3e[_0x2d92b0(0xde)]||{},_0x3d147f=_0x5f3e3e[_0x2d92b0(0xdf)]||{},_0x5b34b0=_0x16aef7[_0x38be69]||_0x3d147f[_0x38be69];if(!_0x5b34b0)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x505922,'packageName':_0x38be69,'stableVersion':_0x39dbc4};let _0x56a457=getInstalledVersion(_0x4bd138,_0x38be69);!_0x56a457&&(_0x56a457=_0x5b34b0);if(isNonNumericVersion(_0x5b34b0))return{'installed':!![],'version':_0x56a457,'needsUpgrade':![],'minVersion':_0x505922,'packageName':_0x38be69,'stableVersion':_0x39dbc4};const _0xe7428e=a181_0x1c6139[_0x2d92b0(0xef)](_0x56a457),_0x42e0d5=a181_0x1c6139['coerce'](_0x505922),_0x743c57=_0xe7428e&&_0x42e0d5?a181_0x1c6139['lt'](_0xe7428e,_0x42e0d5):![];return{'installed':!![],'version':_0x56a457,'needsUpgrade':_0x743c57,'minVersion':_0x505922,'packageName':_0x38be69,'stableVersion':_0x39dbc4};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x505922,'packageName':_0x38be69,'stableVersion':_0x39dbc4};}}export function checkSdkVersionSync(_0x4ba9ed){const _0x527850=a181_0x14bb64,_0x2dfe7f=a181_0x116c52['join'](_0x4ba9ed,_0x527850(0xf2)),_0x2b8663='@lovrabet/sdk';if(!a181_0x54b216['existsSync'](_0x2dfe7f))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2b8663,'stableVersion':null};try{const _0x4a52bd=JSON[_0x527850(0xe1)](a181_0x54b216[_0x527850(0xf0)](_0x2dfe7f,_0x527850(0xdb))),_0x1913cb=_0x4a52bd[_0x527850(0xde)]||{},_0x476222=_0x4a52bd[_0x527850(0xdf)]||{},_0x1c89a0=_0x1913cb[_0x2b8663]||_0x476222[_0x2b8663];if(!_0x1c89a0)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2b8663,'stableVersion':null};let _0x420a87=getInstalledVersion(_0x4ba9ed,_0x2b8663);!_0x420a87&&(_0x420a87=_0x1c89a0);if(isNonNumericVersion(_0x1c89a0))return{'installed':!![],'version':_0x420a87,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2b8663,'stableVersion':null};const _0x174890=a181_0x1c6139[_0x527850(0xef)](_0x420a87),_0x43662c=_0x174890?a181_0x1c6139['lt'](_0x174890,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0x420a87,'needsUpgrade':_0x43662c,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2b8663,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2b8663,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x306cde){const _0x3d6964=a181_0x14bb64;if(!_0x306cde[_0x3d6964(0xee)])return;const _0x1b666a='\x1b[33m',_0xd0e68a='\x1b[0m',_0x10c87c=_0x3d6964(0xe2),_0x29c6c1=_0x306cde[_0x3d6964(0xe3)]||_0x3d6964(0xd9),_0x43e6bb=_0x306cde['stableVersion']||_0x306cde[_0x3d6964(0xdd)],_0x29b518=_0x3d6964(0xd6)+_0x29c6c1+'@'+(_0x43e6bb||_0x3d6964(0xf7));console[_0x3d6964(0xd7)](),console[_0x3d6964(0xd7)](''+_0x1b666a+_0x10c87c+'↪\x20SDK\x20update\x20available'+_0xd0e68a),console['log'](_0x1b666a+_0x3d6964(0xf8)+_0x29c6c1+'@'+_0x306cde['version']+_0xd0e68a),console[_0x3d6964(0xd7)](_0x1b666a+'\x20\x20\x20Stable\x20version:\x20'+_0x43e6bb+_0xd0e68a),console[_0x3d6964(0xd7)](_0x1b666a+_0x3d6964(0xe9)+_0x29b518+_0xd0e68a),console['log']();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x276074,_0x154a98){const _0x3a441a=a182_0x114e,_0x56491c=_0x276074();while(!![]){try{const _0x98ef1f=parseInt(_0x3a441a(0x1a9))/0x1*(-parseInt(_0x3a441a(0x1d1))/0x2)+parseInt(_0x3a441a(0x1c0))/0x3+-parseInt(_0x3a441a(0x1af))/0x4*(-parseInt(_0x3a441a(0x1bd))/0x5)+parseInt(_0x3a441a(0x1c9))/0x6*(-parseInt(_0x3a441a(0x1c2))/0x7)+-parseInt(_0x3a441a(0x1c1))/0x8*(parseInt(_0x3a441a(0x1c4))/0x9)+parseInt(_0x3a441a(0x1b4))/0xa+parseInt(_0x3a441a(0x1b0))/0xb;if(_0x98ef1f===_0x154a98)break;else _0x56491c['push'](_0x56491c['shift']());}catch(_0x276803){_0x56491c['push'](_0x56491c['shift']());}}}(a182_0x286d,0xd12be));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a182_0x4e604a from'semver';import{getCliVersionPolicy}from'../utils/cli-version-policy.js';function a182_0x286d(){const _0x3542e7=['minimumVersionMessage','\x1b[31m','4qeINja','parse','\x20\x20\x20','636806WCDlEj','1.0.0','Minimum\x20required:\x20','\x20\x20\x20Current\x20CLI\x20version:\x20','\x1b[0m','\x20\x20\x20Minimum\x20required:\x20','16mmqByE','9966605CBeyhP','log','join','stableVersion','13414760nlHQhj','\x20\x20\x20Upgrade\x20command:\x20','\x1b[33m','upgradeMessage','↪\x20Critical\x20CLI\x20upgrade\x20required','npm\x20install\x20-g\x20','belowMinimum','\x20\x20\x20Recommended\x20stable:\x20','↪\x20New\x20version\x20available','340980oEDCFq','package.json','minimumVersion','3901644AfwUIM','835912oqGzUT','6713434oZMFmX','coerce','63HjyJyM','Upgrade\x20command:\x20','currentVersion','Current\x20version:\x20','../..','6trVykR','\x1b[1m','filter','\x20\x20\x20Stable\x20version:\x20','needsUpgrade','Current\x20CLI\x20version\x20is\x20below\x20the\x20minimum\x20supported\x20version.'];a182_0x286d=function(){return _0x3542e7;};return a182_0x286d();}import{NPM_PACKAGE_NAME}from'../constant/cli.js';import{CliErrors}from'../errors.js';export function getCliUpgradeCommand(_0x1d5ad4){const _0x4516ad=a182_0x114e,_0x5abada=_0x1d5ad4['stableVersion']||'latest';return _0x4516ad(0x1b9)+NPM_PACKAGE_NAME+'@'+_0x5abada;}function getCurrentCliVersion(){const _0x2f9651=a182_0x114e;try{const _0x4542f5=fileURLToPath(import.meta.url),_0x1252ce=resolve(dirname(_0x4542f5),_0x2f9651(0x1c8)),_0x19d086=resolve(_0x1252ce,_0x2f9651(0x1be)),_0x3e2a87=JSON[_0x2f9651(0x1a7)](readFileSync(_0x19d086,'utf-8'));return _0x3e2a87['version']||_0x2f9651(0x1aa);}catch{return _0x2f9651(0x1aa);}}function a182_0x114e(_0x1fba2a,_0x103f91){_0x1fba2a=_0x1fba2a-0x1a7;const _0x286d17=a182_0x286d();let _0x114e59=_0x286d17[_0x1fba2a];return _0x114e59;}export async function checkCliVersion(){const _0x1a7a84=a182_0x114e,_0x5a6c7b=getCurrentCliVersion(),_0x1e0033=await getCliVersionPolicy(),_0x471791=_0x1e0033?.[_0x1a7a84(0x1b3)]||null,_0x25e967=_0x1e0033?.['minimumVersion']||null;let _0x5c68b9=![],_0x52ddb7=![];const _0xb825c6=a182_0x4e604a[_0x1a7a84(0x1c3)](_0x5a6c7b);if(_0xb825c6&&_0x471791)try{const _0x110186=a182_0x4e604a['coerce'](_0x471791);if(_0x110186)_0x5c68b9=a182_0x4e604a['lt'](_0xb825c6,_0x110186);}catch{}if(_0xb825c6&&_0x25e967)try{const _0x3cf0dd=a182_0x4e604a[_0x1a7a84(0x1c3)](_0x25e967);if(_0x3cf0dd)_0x52ddb7=a182_0x4e604a['lt'](_0xb825c6,_0x3cf0dd);}catch{}return _0x52ddb7&&(_0x5c68b9=!![]),{'currentVersion':_0x5a6c7b,'stableVersion':_0x471791,'minimumVersion':_0x25e967,'needsUpgrade':_0x5c68b9,'belowMinimum':_0x52ddb7,'isPreRelease':![],'upgradeMessage':_0x1e0033?.[_0x1a7a84(0x1b7)],'minimumVersionMessage':_0x1e0033?.[_0x1a7a84(0x1cf)]};}export function printCliUpgradeWarning(_0x3c9c26){const _0x4d4fd2=a182_0x114e;if(!_0x3c9c26[_0x4d4fd2(0x1cd)]&&!_0x3c9c26['belowMinimum'])return;const _0x105624=_0x4d4fd2(0x1d0),_0x18951c=_0x4d4fd2(0x1b6),_0x22c398=_0x4d4fd2(0x1ad),_0x5de5e0=_0x4d4fd2(0x1ca),_0x4066d0=getCliUpgradeCommand(_0x3c9c26);console[_0x4d4fd2(0x1b1)](),_0x3c9c26[_0x4d4fd2(0x1ba)]?(console[_0x4d4fd2(0x1b1)](''+_0x105624+_0x5de5e0+_0x4d4fd2(0x1b8)+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x105624+_0x4d4fd2(0x1ac)+_0x3c9c26[_0x4d4fd2(0x1c6)]+_0x22c398),_0x3c9c26[_0x4d4fd2(0x1bf)]&&console[_0x4d4fd2(0x1b1)](_0x105624+_0x4d4fd2(0x1ae)+_0x3c9c26['minimumVersion']+_0x22c398),_0x3c9c26[_0x4d4fd2(0x1b3)]&&_0x3c9c26[_0x4d4fd2(0x1b3)]!==_0x3c9c26[_0x4d4fd2(0x1bf)]&&console[_0x4d4fd2(0x1b1)](_0x105624+_0x4d4fd2(0x1bb)+_0x3c9c26[_0x4d4fd2(0x1b3)]+_0x22c398),_0x3c9c26[_0x4d4fd2(0x1cf)]&&console['log'](_0x105624+_0x4d4fd2(0x1a8)+_0x3c9c26[_0x4d4fd2(0x1cf)]+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x105624+_0x4d4fd2(0x1b5)+_0x4066d0+_0x22c398)):(console['log'](''+_0x18951c+_0x5de5e0+_0x4d4fd2(0x1bc)+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x18951c+_0x4d4fd2(0x1ac)+_0x3c9c26[_0x4d4fd2(0x1c6)]+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x18951c+_0x4d4fd2(0x1cc)+_0x3c9c26['stableVersion']+_0x22c398),_0x3c9c26[_0x4d4fd2(0x1b7)]&&console['log'](_0x18951c+_0x4d4fd2(0x1a8)+_0x3c9c26[_0x4d4fd2(0x1b7)]+_0x22c398),console[_0x4d4fd2(0x1b1)](_0x18951c+_0x4d4fd2(0x1b5)+_0x4066d0+_0x22c398)),console[_0x4d4fd2(0x1b1)]();}export function assertCliVersionSupported(_0x55d4fa){const _0x4d6641=a182_0x114e;if(!_0x55d4fa[_0x4d6641(0x1ba)])return;const _0x1d4c13=[_0x55d4fa[_0x4d6641(0x1cf)],_0x4d6641(0x1c7)+_0x55d4fa[_0x4d6641(0x1c6)],_0x55d4fa[_0x4d6641(0x1bf)]?_0x4d6641(0x1ab)+_0x55d4fa[_0x4d6641(0x1bf)]:null,_0x4d6641(0x1c5)+getCliUpgradeCommand(_0x55d4fa)][_0x4d6641(0x1cb)](Boolean)[_0x4d6641(0x1b2)]('\x0a');throw CliErrors['validation'](_0x4d6641(0x1ce),_0x1d4c13);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x483688,_0x278565){const _0x5a02e0=a183_0x461a,_0xd4460e=_0x483688();while(!![]){try{const _0xfd256a=-parseInt(_0x5a02e0(0xb7))/0x1+-parseInt(_0x5a02e0(0xcb))/0x2+-parseInt(_0x5a02e0(0xbc))/0x3+parseInt(_0x5a02e0(0xc2))/0x4*(-parseInt(_0x5a02e0(0xc7))/0x5)+parseInt(_0x5a02e0(0xc3))/0x6+parseInt(_0x5a02e0(0xc8))/0x7+-parseInt(_0x5a02e0(0xc1))/0x8*(-parseInt(_0x5a02e0(0xcc))/0x9);if(_0xfd256a===_0x278565)break;else _0xd4460e['push'](_0xd4460e['shift']());}catch(_0x431113){_0xd4460e['push'](_0xd4460e['shift']());}}}(a183_0x57a9,0x90e0b));import{CLI_VERSION_POLICY_URL}from'../constant/cdn.js';const CACHE_TTL=0x5*0x3c*0x3e8,FAILURE_CACHE_TTL=0x3c*0x3e8,FETCH_TIMEOUT_MS=0xbb8;function pickString(_0x3ed030){const _0x39e32b=a183_0x461a;return typeof _0x3ed030===_0x39e32b(0xbd)&&_0x3ed030[_0x39e32b(0xb6)]()[_0x39e32b(0xb4)]>0x0?_0x3ed030['trim']():null;}function normalizeCliVersionPolicy(_0x574ebe){const _0x2331c3=a183_0x461a;if(!_0x574ebe||typeof _0x574ebe!==_0x2331c3(0xc6))return null;const _0x3f6354=_0x574ebe,_0x2b4560=_0x3f6354[_0x2331c3(0xba)]&&typeof _0x3f6354['cli']===_0x2331c3(0xc6)?_0x3f6354[_0x2331c3(0xba)]:_0x3f6354,_0x51247e=pickString(_0x2b4560[_0x2331c3(0xc9)])||pickString(_0x2b4560[_0x2331c3(0xbf)])||pickString(_0x2b4560[_0x2331c3(0xb9)]),_0x371bcc=pickString(_0x2b4560[_0x2331c3(0xc0)])||pickString(_0x2b4560[_0x2331c3(0xb8)]);if(!_0x51247e&&!_0x371bcc)return null;return{'stableVersion':_0x51247e,'minimumVersion':_0x371bcc,'upgradeMessage':pickString(_0x2b4560[_0x2331c3(0xc5)])||undefined,'minimumVersionMessage':pickString(_0x2b4560[_0x2331c3(0xc4)])||undefined};}export async function fetchCliVersionPolicy(){const _0x784f62=a183_0x461a,_0x4f20d7=new AbortController(),_0x57e110=setTimeout(()=>_0x4f20d7[_0x784f62(0xb5)](),FETCH_TIMEOUT_MS);try{const _0x4103cd=await fetch(CLI_VERSION_POLICY_URL,{'headers':{'Accept':_0x784f62(0xca)},'signal':_0x4f20d7[_0x784f62(0xbb)]});if(!_0x4103cd['ok'])return null;const _0x3ff79f=await _0x4103cd['json']();return normalizeCliVersionPolicy(_0x3ff79f);}catch{return null;}finally{clearTimeout(_0x57e110);}}function a183_0x57a9(){const _0xed119f=['now','latestVersion','minimumVersion','11736944gAbGFL','4006808HWnMOQ','1396236xnJglx','minimumVersionMessage','upgradeMessage','object','5OkVKzn','2678109BVkZwR','stableVersion','application/json','765376OZpDau','18jDpgFS','length','abort','trim','676260gWicco','minVersion','recommendedVersion','cli','signal','2686380MjNbGn','string'];a183_0x57a9=function(){return _0xed119f;};return a183_0x57a9();}function a183_0x461a(_0x4222c4,_0x5f5bb5){_0x4222c4=_0x4222c4-0xb4;const _0x57a9d2=a183_0x57a9();let _0x461a84=_0x57a9d2[_0x4222c4];return _0x461a84;}let cachedPolicy=null,cacheTime=0x0,hasCachedPolicy=![];export async function getCliVersionPolicy(){const _0xec87db=a183_0x461a,_0x1cbcb7=Date[_0xec87db(0xbe)]();if(hasCachedPolicy){const _0x49fe0b=cachedPolicy?CACHE_TTL:FAILURE_CACHE_TTL;if(_0x1cbcb7-cacheTime<_0x49fe0b)return cachedPolicy;}const _0x4f232b=await fetchCliVersionPolicy();return cachedPolicy=_0x4f232b,cacheTime=_0x1cbcb7,hasCachedPolicy=!![],_0x4f232b;}export function clearCliVersionPolicyCache(){cachedPolicy=null,cacheTime=0x0,hasCachedPolicy=![];}
|
package/lib/utils/config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a184_0x3057d6=a184_0x4b24;(function(_0x4547b4,_0x3b4c70){const _0x2eed18=a184_0x4b24,_0x61e4a4=_0x4547b4();while(!![]){try{const _0xa105b=parseInt(_0x2eed18(0x1c1))/0x1*(parseInt(_0x2eed18(0x1ba))/0x2)+parseInt(_0x2eed18(0x1b7))/0x3*(parseInt(_0x2eed18(0x1c2))/0x4)+parseInt(_0x2eed18(0x1bb))/0x5+parseInt(_0x2eed18(0x1bf))/0x6+-parseInt(_0x2eed18(0x1b8))/0x7*(parseInt(_0x2eed18(0x1bd))/0x8)+parseInt(_0x2eed18(0x1b6))/0x9+-parseInt(_0x2eed18(0x1b9))/0xa;if(_0xa105b===_0x3b4c70)break;else _0x61e4a4['push'](_0x61e4a4['shift']());}catch(_0x113854){_0x61e4a4['push'](_0x61e4a4['shift']());}}}(a184_0x26af,0x92efb));import{initEnv}from'../constant/env.js';function a184_0x4b24(_0x5140ee,_0x3c3017){_0x5140ee=_0x5140ee-0x1b6;const _0x26afba=a184_0x26af();let _0x4b241b=_0x26afba[_0x5140ee];return _0x4b241b;}import{readRawConfig,getConfigAppCode as a184_0x2187a8,getMultiAppConfigs as a184_0x4d56d8,getTemplateBaseUrl as a184_0x997425}from'../context.js';export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';export{isInProject}from'../context.js';function a184_0x26af(){const _0x4fb73d=['7VLtzJY','28655400jKYibu','1812310FQUfiI','3292160WouCdL','string','481976Oqrsib','project','2124852rhZDXJ','env','1Imhbvp','1432gmOjjb','10359243bXOaVi','3837GamxNB'];a184_0x26af=function(){return _0x4fb73d;};return a184_0x26af();}export function readConfig(_0x5f4ff4){const _0x239304=a184_0x4b24,_0x1d9edc=readRawConfig(_0x5f4ff4);return _0x1d9edc[_0x239304(0x1c0)]&&typeof _0x1d9edc[_0x239304(0x1c0)]===_0x239304(0x1bc)&&initEnv(_0x1d9edc[_0x239304(0x1c0)]),_0x1d9edc;}export function getConfigAppCode(){return a184_0x2187a8();}export function getMultiAppConfigs(_0x5d7865=a184_0x3057d6(0x1be)){return a184_0x4d56d8(_0x5d7865);}export function getTemplateBaseUrl(){return a184_0x997425();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a185_0x9965(){const _0x571767=['20UNaIXm','20030810ItjceJ','446201FrTgpM','10274496KTuWfc','491356QGvyWj','isDirectory','1034208LekBLh','9tzSynZ','name','384242DNmbyq','复制目录时出错:','readdirSync','1LkadRs','368826fgGkdC','join'];a185_0x9965=function(){return _0x571767;};return a185_0x9965();}(function(_0xef9f52,_0x187a20){const _0x134e61=a185_0x4029,_0x172c37=_0xef9f52();while(!![]){try{const _0x365b90=-parseInt(_0x134e61(0xab))/0x1*(parseInt(_0x134e61(0xa8))/0x2)+-parseInt(_0x134e61(0xa5))/0x3+parseInt(_0x134e61(0xa3))/0x4*(parseInt(_0x134e61(0x9f))/0x5)+-parseInt(_0x134e61(0x9d))/0x6+parseInt(_0x134e61(0xa1))/0x7+-parseInt(_0x134e61(0xa2))/0x8+parseInt(_0x134e61(0xa6))/0x9*(parseInt(_0x134e61(0xa0))/0xa);if(_0x365b90===_0x187a20)break;else _0x172c37['push'](_0x172c37['shift']());}catch(_0x59bec9){_0x172c37['push'](_0x172c37['shift']());}}}(a185_0x9965,0xa4ed4));import a185_0x2ead9f from'node:path';function a185_0x4029(_0x2c1901,_0x3dfdf3){_0x2c1901=_0x2c1901-0x9d;const _0x99657b=a185_0x9965();let _0x40294c=_0x99657b[_0x2c1901];return _0x40294c;}import a185_0x240353 from'node:fs';export async function copyDirectory(_0x571fd6,_0x29fb8c){const _0x364dd8=a185_0x4029;try{const _0x499b51=a185_0x240353[_0x364dd8(0xaa)](_0x571fd6,{'withFileTypes':!![]});a185_0x240353['mkdirSync'](_0x29fb8c,{'recursive':!![]});for(const _0x24559b of _0x499b51){const _0x4d3d3e=a185_0x2ead9f[_0x364dd8(0x9e)](_0x571fd6,_0x24559b[_0x364dd8(0xa7)]),_0x5ba628=a185_0x2ead9f[_0x364dd8(0x9e)](_0x29fb8c,_0x24559b[_0x364dd8(0xa7)]);_0x24559b[_0x364dd8(0xa4)]()?await copyDirectory(_0x4d3d3e,_0x5ba628):a185_0x240353['copyFileSync'](_0x4d3d3e,_0x5ba628);}}catch(_0x3fbcea){console['error'](_0x364dd8(0xa9),_0x3fbcea);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a186_0xe7fb(){const _0xe04765=['12021300LGYFey','172109MtGYMO','142MxqPjL','420411OSdDjy','1751305qrQKvm','288387YOBXec','6xjCZQX','4cyTLju','40CGPfpQ','string','70LNjRje','1063xIAirC','trim','38079jnygzi','isFinite'];a186_0xe7fb=function(){return _0xe04765;};return a186_0xe7fb();}(function(_0x2c9ccd,_0x5b8856){const _0xe3311a=a186_0x49fc,_0x2546cf=_0x2c9ccd();while(!![]){try{const _0x3b2694=parseInt(_0xe3311a(0xb1))/0x1*(-parseInt(_0xe3311a(0xb7))/0x2)+-parseInt(_0xe3311a(0xa9))/0x3+-parseInt(_0xe3311a(0xad))/0x4*(parseInt(_0xe3311a(0xaa))/0x5)+parseInt(_0xe3311a(0xac))/0x6*(-parseInt(_0xe3311a(0xb6))/0x7)+parseInt(_0xe3311a(0xae))/0x8*(parseInt(_0xe3311a(0xb3))/0x9)+-parseInt(_0xe3311a(0xb0))/0xa*(parseInt(_0xe3311a(0xab))/0xb)+parseInt(_0xe3311a(0xb5))/0xc;if(_0x3b2694===_0x5b8856)break;else _0x2546cf['push'](_0x2546cf['shift']());}catch(_0x2d5c08){_0x2546cf['push'](_0x2546cf['shift']());}}}(a186_0xe7fb,0x3cc79));function toFiniteNumber(_0x4db6fc){const _0xd8fcb7=a186_0x49fc;if(typeof _0x4db6fc==='number'&&Number[_0xd8fcb7(0xb4)](_0x4db6fc))return _0x4db6fc;if(typeof _0x4db6fc===_0xd8fcb7(0xaf)){const _0x2c3cc6=_0x4db6fc[_0xd8fcb7(0xb2)]();if(!_0x2c3cc6)return undefined;const _0x2ca075=Number(_0x2c3cc6);if(Number[_0xd8fcb7(0xb4)](_0x2ca075))return _0x2ca075;}return undefined;}function a186_0x49fc(_0x40e217,_0x175aac){_0x40e217=_0x40e217-0xa9;const _0xe7fbca=a186_0xe7fb();let _0x49fce0=_0xe7fbca[_0x40e217];return _0x49fce0;}export function normalizeEntityWithIdResponse(_0x154d76){const _0x1486fc=toFiniteNumber(_0x154d76);if(_0x1486fc!==undefined)return{'id':_0x1486fc,'entity':{'id':_0x1486fc}};if(!_0x154d76||typeof _0x154d76!=='object')return{'id':undefined,'entity':{}};const _0x55d675={..._0x154d76},_0xac4906=toFiniteNumber(_0x55d675['id']);return _0xac4906!==undefined&&(_0x55d675['id']=_0xac4906),{'id':_0xac4906,'entity':_0x55d675};}
|
package/lib/utils/file-utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x9d2dc1,_0x41bde0){const _0x51aad9=a187_0x1574,_0x1b4b59=_0x9d2dc1();while(!![]){try{const _0x1976a0=parseInt(_0x51aad9(0xd9))/0x1*(parseInt(_0x51aad9(0xdb))/0x2)+-parseInt(_0x51aad9(0xdf))/0x3+parseInt(_0x51aad9(0xd4))/0x4*(parseInt(_0x51aad9(0xe0))/0x5)+parseInt(_0x51aad9(0xdc))/0x6*(parseInt(_0x51aad9(0xdd))/0x7)+parseInt(_0x51aad9(0xda))/0x8*(-parseInt(_0x51aad9(0xd5))/0x9)+-parseInt(_0x51aad9(0xd8))/0xa*(-parseInt(_0x51aad9(0xd7))/0xb)+parseInt(_0x51aad9(0xde))/0xc*(-parseInt(_0x51aad9(0xd6))/0xd);if(_0x1976a0===_0x41bde0)break;else _0x1b4b59['push'](_0x1b4b59['shift']());}catch(_0x3a25f9){_0x1b4b59['push'](_0x1b4b59['shift']());}}}(a187_0x9c8e,0x2bfdb));import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';function a187_0x9c8e(){const _0x2ee055=['7JzdkIM','96ZoQnXN','303084WuOSjl','69550XhFhhn','isDirectory','20KGVpBr','64026yEnMet','48971ZrjuwJ','38819pCpWeG','270bHhGIj','8065sdNWVx','344QBqQJt','38ERJrFX','1795110nOYjLM'];a187_0x9c8e=function(){return _0x2ee055;};return a187_0x9c8e();}export async function copyDir(_0x28270c,_0x53ff6a){const _0x53b526=a187_0x1574,_0x5697c4=statSync(_0x28270c);if(_0x5697c4[_0x53b526(0xe1)]()){!existsSync(_0x53ff6a)&&mkdirSync(_0x53ff6a,{'recursive':!![]});const _0x21a916=readdirSync(_0x28270c);for(const _0x13e73e of _0x21a916){await copyDir(join(_0x28270c,_0x13e73e),join(_0x53ff6a,_0x13e73e));}}else copyFileSync(_0x28270c,_0x53ff6a);}function a187_0x1574(_0x596d41,_0x24ffe0){_0x596d41=_0x596d41-0xd4;const _0x9c8e29=a187_0x9c8e();let _0x157474=_0x9c8e29[_0x596d41];return _0x157474;}export function ensureDir(_0xd0e8b){!existsSync(_0xd0e8b)&&mkdirSync(_0xd0e8b,{'recursive':!![]});}export function pathExists(_0x2d62e3){return existsSync(_0x2d62e3);}
|
package/lib/utils/guides-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a188_0x5e63(_0x12e112,_0x4748ed){_0x12e112=_0x12e112-0x1d3;const _0x47bf8a=a188_0x47bf();let _0x5e6367=_0x47bf8a[_0x12e112];return _0x5e6367;}const a188_0x13d14b=a188_0x5e63;(function(_0x1f4402,_0x33394e){const _0x187540=a188_0x5e63,_0x2763ee=_0x1f4402();while(!![]){try{const _0x11f74b=parseInt(_0x187540(0x1d6))/0x1+-parseInt(_0x187540(0x1e3))/0x2+-parseInt(_0x187540(0x1de))/0x3+-parseInt(_0x187540(0x1e6))/0x4+-parseInt(_0x187540(0x1d9))/0x5+parseInt(_0x187540(0x1e4))/0x6+parseInt(_0x187540(0x1e8))/0x7*(parseInt(_0x187540(0x1eb))/0x8);if(_0x11f74b===_0x33394e)break;else _0x2763ee['push'](_0x2763ee['shift']());}catch(_0x5ddbb9){_0x2763ee['push'](_0x2763ee['shift']());}}}(a188_0x47bf,0x18859));import{mkdirSync,writeFileSync}from'node:fs';import{dirname,join}from'node:path';import{homedir}from'node:os';import{getTemplateBaseUrl}from'../utils/config.js';function getGuidesCdnUrl(){const _0x178d35=a188_0x5e63,_0x54c968=getTemplateBaseUrl();return _0x54c968+_0x178d35(0x1db);}const CACHE_DIR=join(homedir(),a188_0x13d14b(0x1e1),'cache');export async function fetchGuidesFromCDN(){const _0x3dd58b=a188_0x13d14b,_0x3bfcc2=getGuidesCdnUrl(),_0x47de32=await fetch(_0x3bfcc2,{'headers':{'Accept':_0x3dd58b(0x1dc)}});if(!_0x47de32['ok'])throw new Error(_0x3dd58b(0x1e2)+_0x47de32[_0x3dd58b(0x1ea)]+'\x20'+_0x47de32['statusText']);const _0x81d865=await _0x47de32['json']();if(!_0x81d865[_0x3dd58b(0x1ec)]||typeof _0x81d865[_0x3dd58b(0x1ec)]!=='object')throw new Error(_0x3dd58b(0x1d5));return _0x81d865;}export function writeGuidesToProject(_0xe4efd0,_0x27d15e,_0x3234ad=a188_0x13d14b(0x1e0),_0x5415df){const _0x1b6d7c=a188_0x13d14b,_0x8f42ce=join(_0x27d15e,_0x3234ad);mkdirSync(_0x8f42ce,{'recursive':!![]});for(const [_0x971773,_0x41861f]of Object['entries'](_0xe4efd0['guides'])){let _0x4b1a31=_0x41861f[_0x1b6d7c(0x1dd)];_0x41861f[_0x1b6d7c(0x1df)]&&(_0x4b1a31=appendUpdateTime(_0x4b1a31,_0x41861f[_0x1b6d7c(0x1df)])),writeFileSync(join(_0x8f42ce,_0x971773+_0x1b6d7c(0x1e9)),_0x4b1a31,_0x1b6d7c(0x1da));}}export function appendUpdateTime(_0x128a2a,_0x444f17){const _0x248cdc=a188_0x13d14b;return _0x128a2a=_0x128a2a[_0x248cdc(0x1ef)](/\n*>更新时间:.*$/m,''),_0x128a2a[_0x248cdc(0x1d4)]()+(_0x248cdc(0x1e7)+_0x444f17);}export function getSkillTemplate(_0x451d3d){const _0x501cf5=a188_0x13d14b;return _0x451d3d[_0x501cf5(0x1e5)]?.[_0x501cf5(0x1dd)]||'';}export function appendExtendContents(_0x81c7f1,_0x7c58a,_0xd395a5){const _0x3c64ca=a188_0x13d14b,_0xd38162=[];for(const [,_0x2e0b1e]of Object[_0x3c64ca(0x1d7)](_0x7c58a['guides'])){_0x2e0b1e['extendContent']&&_0xd38162['push'](_0x2e0b1e[_0x3c64ca(0x1ed)][_0x3c64ca(0x1d4)]());}if(_0xd38162['length']===0x0)return _0x81c7f1;return _0x81c7f1[_0x3c64ca(0x1d4)]()+'\x0a\x0a'+_0xd38162['join']('\x0a\x0a')+'\x0a';}function a188_0x47bf(){const _0x43825c=['140570KZwAUN','entries','title','120725LmVIFb','utf-8','/skills/guides.json','application/json','content','377283EuwgJL','lastUpdated','.lovrabet/skill/guides','.lovrabet','CDN\x20请求失败:\x20','58842jMEwPD','669894afxVCS','skillTemplate','344332AQpkYm','\x0a\x0a>更新时间:','56zdaFCA','.md','status','113632AZNmoY','guides','extendContent','CDN\x20数据中缺少\x20skillTemplate','replace','path','trimEnd','CDN\x20返回数据格式错误'];a188_0x47bf=function(){return _0x43825c;};return a188_0x47bf();}export function writeSkillFile(_0xc5e5c,_0xa7be49,_0xb6cddc){const _0x4e84ef=a188_0x13d14b,_0x2367b0=getSkillTemplate(_0xc5e5c);if(!_0x2367b0)throw new Error(_0x4e84ef(0x1ee));const _0x12f043=dirname(_0xa7be49);mkdirSync(_0x12f043,{'recursive':!![]});let _0x3a57eb=_0x2367b0['replace'](/\{\{IDE_NAME\}\}/g,_0xb6cddc);_0x3a57eb=appendExtendContents(_0x3a57eb,_0xc5e5c),_0xc5e5c['skillTemplate'][_0x4e84ef(0x1df)]&&(_0x3a57eb=appendUpdateTime(_0x3a57eb,_0xc5e5c[_0x4e84ef(0x1e5)]['lastUpdated'])),writeFileSync(_0xa7be49,_0x3a57eb,_0x4e84ef(0x1da));}export async function installGuides(_0x40120d){const _0x27f952=a188_0x13d14b,_0x5a3220=await fetchGuidesFromCDN();return writeGuidesToProject(_0x5a3220,_0x40120d),Object['keys'](_0x5a3220[_0x27f952(0x1ec)])['length'];}export function getGuidesSummary(_0x1a4cd0){const _0x28a39e=a188_0x13d14b;return Object['entries'](_0x1a4cd0[_0x28a39e(0x1ec)])['map'](([_0x2bf767,_0x460a50])=>({'key':_0x2bf767,'title':_0x460a50[_0x28a39e(0x1d8)],'path':_0x460a50[_0x28a39e(0x1d3)]}));}
|
package/lib/utils/http-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a189_0x25e0(){const _0x2275c1=['json','9cdzmdP','73jxBUqj','\x20次重试...','411940GMooKl','ms\x20后进行第\x20','log','get','771529oAxyEs','application/json','text','headers','4315308KkwWqX','TypeError','statusText','*\x20请求失败,','33716tidOIT','12FIhkfe','30HVCbmO','signal','2966CZtdkO','Request\x20failed','1727352UplrRI','fetch','includes','url','AbortError','abort','message','status','24GqRkXr','96873MNIVtR'];a189_0x25e0=function(){return _0x2275c1;};return a189_0x25e0();}(function(_0x271d40,_0x4d290c){const _0x268034=a189_0x3922,_0x5ccde9=_0x271d40();while(!![]){try{const _0x4ffc15=-parseInt(_0x268034(0x1cf))/0x1*(parseInt(_0x268034(0x1c1))/0x2)+-parseInt(_0x268034(0x1ce))/0x3*(parseInt(_0x268034(0x1bd))/0x4)+parseInt(_0x268034(0x1d1))/0x5*(parseInt(_0x268034(0x1be))/0x6)+-parseInt(_0x268034(0x1cc))/0x7*(-parseInt(_0x268034(0x1cb))/0x8)+parseInt(_0x268034(0x1c3))/0x9+parseInt(_0x268034(0x1bf))/0xa*(parseInt(_0x268034(0x1b5))/0xb)+-parseInt(_0x268034(0x1b9))/0xc;if(_0x4ffc15===_0x4d290c)break;else _0x5ccde9['push'](_0x5ccde9['shift']());}catch(_0x210b72){_0x5ccde9['push'](_0x5ccde9['shift']());}}}(a189_0x25e0,0x1c31b));export async function httpRequest(_0x4a9c18,_0x195953={}){const _0x58b431=a189_0x3922,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x195953;let _0x11a6d9=null;for(let _0x2968c2=0x0;_0x2968c2<=retries;_0x2968c2++){try{const _0x4f21d4=new AbortController(),_0x20146b=setTimeout(()=>_0x4f21d4[_0x58b431(0x1c8)](),timeout),_0x1e4d20=await fetch(_0x4a9c18,{'headers':headers,'signal':_0x4f21d4[_0x58b431(0x1c0)]});clearTimeout(_0x20146b);let _0x3fc56a;const _0x153b58=_0x1e4d20[_0x58b431(0x1b8)][_0x58b431(0x1b4)]('content-type');return _0x153b58?.[_0x58b431(0x1c5)](_0x58b431(0x1b6))?_0x3fc56a=await _0x1e4d20[_0x58b431(0x1cd)]():_0x3fc56a=await _0x1e4d20[_0x58b431(0x1b7)](),{'ok':_0x1e4d20['ok'],'status':_0x1e4d20[_0x58b431(0x1ca)],'statusText':_0x1e4d20[_0x58b431(0x1bb)],'data':_0x3fc56a,'headers':_0x1e4d20[_0x58b431(0x1b8)],'url':_0x1e4d20[_0x58b431(0x1c6)],'text':()=>_0x1e4d20[_0x58b431(0x1b7)]()};}catch(_0x5ddf12){_0x11a6d9=_0x5ddf12 instanceof Error?_0x5ddf12:new Error(String(_0x5ddf12));if(_0x2968c2===retries)break;if(shouldRetry(_0x5ddf12)){console[_0x58b431(0x1b3)](_0x58b431(0x1bc)+retryDelay+_0x58b431(0x1b2)+(_0x2968c2+0x1)+_0x58b431(0x1d0)),await sleep(retryDelay);continue;}else break;}}throw _0x11a6d9||new Error(_0x58b431(0x1c2));}function a189_0x3922(_0x1598c8,_0x31562c){_0x1598c8=_0x1598c8-0x1b2;const _0x25e02d=a189_0x25e0();let _0x3922b3=_0x25e02d[_0x1598c8];return _0x3922b3;}function shouldRetry(_0x103e1c){const _0x3d87cc=a189_0x3922;if(_0x103e1c instanceof Error){if(_0x103e1c['name']===_0x3d87cc(0x1c7))return![];if(_0x103e1c['name']===_0x3d87cc(0x1ba)&&_0x103e1c[_0x3d87cc(0x1c9)][_0x3d87cc(0x1c5)](_0x3d87cc(0x1c4)))return!![];if(_0x103e1c[_0x3d87cc(0x1c9)][_0x3d87cc(0x1c5)]('ECONNRESET'))return!![];if(_0x103e1c[_0x3d87cc(0x1c9)][_0x3d87cc(0x1c5)]('ENOTFOUND'))return![];}return![];}function sleep(_0x447d81){return new Promise(_0x3619a0=>setTimeout(_0x3619a0,_0x447d81));}export function validateUrl(_0x44ee3a){try{return new URL(_0x44ee3a),!![];}catch{return![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2b31a8,_0x480fb3){const _0x3d950a=a190_0x5199,_0x4f615d=_0x2b31a8();while(!![]){try{const _0x24187a=parseInt(_0x3d950a(0x119))/0x1*(parseInt(_0x3d950a(0x112))/0x2)+-parseInt(_0x3d950a(0x111))/0x3+parseInt(_0x3d950a(0x113))/0x4+parseInt(_0x3d950a(0x116))/0x5*(parseInt(_0x3d950a(0x10e))/0x6)+-parseInt(_0x3d950a(0x114))/0x7*(parseInt(_0x3d950a(0x10c))/0x8)+parseInt(_0x3d950a(0x11a))/0x9*(parseInt(_0x3d950a(0x10b))/0xa)+-parseInt(_0x3d950a(0x117))/0xb;if(_0x24187a===_0x480fb3)break;else _0x4f615d['push'](_0x4f615d['shift']());}catch(_0x120ece){_0x4f615d['push'](_0x4f615d['shift']());}}}(a190_0x5a44,0x7b333));function a190_0x5a44(){const _0x517547=['true','1379555hvIZVA','3716515pplWoo','isTTY','89isDMnb','477NtUsVr','121030EmCfxI','123088iBfENS','isRaw','6CQmmfz','setRawMode','stdin','977907EEXGbx','7992MvwyAk','628036ktSCkj','119iCNHSH'];a190_0x5a44=function(){return _0x517547;};return a190_0x5a44();}function a190_0x5199(_0x5a8949,_0x4a85f7){_0x5a8949=_0x5a8949-0x10b;const _0x5a4419=a190_0x5a44();let _0x519904=_0x5a4419[_0x5a8949];return _0x519904;}function env(_0x4ad253){return process.env[`RABETBASE_${_0x4ad253}`]||process.env[`LOVRABET_${_0x4ad253}`]||undefined;}export function isNonInteractive(_0x11aa58){const _0x70a27b=a190_0x5199;return!!(_0x11aa58['nonInteractive']||_0x11aa58['ci']||env('CI')===_0x70a27b(0x115)||process.env.CI===_0x70a27b(0x115)||!process['stdout'][_0x70a27b(0x118)]||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x4af503=a190_0x5199;if(!process['stdin'][_0x4af503(0x118)])return![];try{const _0x2bc7e0=process[_0x4af503(0x110)][_0x4af503(0x10d)];return process[_0x4af503(0x110)][_0x4af503(0x10f)](!![]),process[_0x4af503(0x110)][_0x4af503(0x10f)](_0x2bc7e0??![]),!![];}catch{return![];}}
|