@lovrabet/cli 1.3.1 → 1.3.2-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. package/lib/add-page/input-page-router.js +1 -1
  2. package/lib/add-page/main.js +1 -1
  3. package/lib/add-page/select-page-template.js +1 -1
  4. package/lib/ai-setup/AISetupUI.js +1 -1
  5. package/lib/ai-setup/config.js +1 -1
  6. package/lib/api/api-doc-ui.js +1 -1
  7. package/lib/api/api-doc.js +1 -1
  8. package/lib/api/api-pull-ui.js +1 -1
  9. package/lib/api/fetch-model-list.js +1 -1
  10. package/lib/api/generate-api-file.js +1 -1
  11. package/lib/api/main.js +1 -1
  12. package/lib/api/pull-silent.js +1 -1
  13. package/lib/app-menu/app-menu-sync-ui.js +1 -1
  14. package/lib/app-menu/create-menu.js +1 -1
  15. package/lib/app-menu/get-local-pages.js +1 -1
  16. package/lib/app-menu/get-online-menu-list.js +1 -1
  17. package/lib/app-menu/use-get-online-menu-list.js +1 -1
  18. package/lib/app-menu/utils.js +1 -1
  19. package/lib/app-menu/valid-url.js +1 -1
  20. package/lib/app-menu-update-cdn/current-content.js +1 -1
  21. package/lib/app-menu-update-cdn/input-cdn-asset.js +1 -1
  22. package/lib/app-menu-update-cdn/main.js +1 -1
  23. package/lib/app-menu-update-cdn/update-menu-cdn-url.js +1 -1
  24. package/lib/auth/auth-server-ui.js +1 -1
  25. package/lib/auth/auth-server.js +1 -1
  26. package/lib/auth/constant.js +1 -1
  27. package/lib/auth/get-cookie.js +1 -1
  28. package/lib/auth/is-session-valid.js +1 -1
  29. package/lib/auth/logout.js +1 -1
  30. package/lib/cli-flags.js +1 -0
  31. package/lib/cli.js +1 -1
  32. package/lib/cmd/build-watch.js +1 -1
  33. package/lib/cmd/build.js +1 -1
  34. package/lib/cmd/logs.js +1 -1
  35. package/lib/cmd/preview.js +1 -1
  36. package/lib/cmd/start.js +1 -1
  37. package/lib/config/config-help.js +1 -1
  38. package/lib/config/main.js +1 -1
  39. package/lib/constant/domain.js +1 -1
  40. package/lib/constant/env.js +1 -1
  41. package/lib/create-app/enhanced-guided-create.js +1 -1
  42. package/lib/create-app/format-elapsed.js +1 -1
  43. package/lib/create-app/main.js +1 -1
  44. package/lib/create-app/non-interactive.js +1 -1
  45. package/lib/create-app/task-finished.js +1 -1
  46. package/lib/create-app/task-loading.js +1 -1
  47. package/lib/create-app/task-running.js +1 -1
  48. package/lib/create-app/task-time.js +1 -1
  49. package/lib/create-app/use-copy-project-template.js +1 -1
  50. package/lib/create-app/use-format-code.js +1 -1
  51. package/lib/create-app/use-install-dependencies.js +1 -1
  52. package/lib/help.js +1 -1
  53. package/lib/init/main.js +1 -1
  54. package/lib/mcp/McpInstallUI.js +1 -1
  55. package/lib/mcp/claude.js +1 -1
  56. package/lib/mcp/cursor.js +1 -1
  57. package/lib/mcp/main.js +1 -1
  58. package/lib/mcp/mcp-install-non-interactive.js +1 -1
  59. package/lib/mcp/mcp-installer.js +1 -1
  60. package/lib/skills/SkillInstallUI.js +1 -1
  61. package/lib/skills/main.js +1 -1
  62. package/lib/skills/skill-install-non-interactive.js +1 -1
  63. package/lib/skills/skill-installer.js +1 -1
  64. package/lib/ui/IDESelector.js +1 -1
  65. package/lib/ui/useIDESelection.js +1 -1
  66. package/lib/utils/ai_config.js +1 -1
  67. package/lib/utils/cdn-config.js +1 -1
  68. package/lib/utils/check-sdk-version.js +1 -1
  69. package/lib/utils/cli-version-check.js +1 -1
  70. package/lib/utils/config.js +1 -1
  71. package/lib/utils/copy-directory.js +1 -1
  72. package/lib/utils/file-utils.js +1 -1
  73. package/lib/utils/guides-cdn.js +1 -1
  74. package/lib/utils/http-client.js +1 -1
  75. package/lib/utils/logger.js +1 -1
  76. package/lib/utils/router-updater.js +1 -1
  77. package/lib/utils/rules-cdn.js +1 -1
  78. package/lib/utils/sleep.js +1 -1
  79. package/lib/utils/template-replacer.js +1 -1
  80. package/package.json +1 -1
@@ -1 +1 @@
1
- (function(_0x10810b,_0xd7223){const _0x1f60ef=a61_0xd72a,_0x279f18=_0x10810b();while(!![]){try{const _0x1f0a52=-parseInt(_0x1f60ef(0x179))/0x1+-parseInt(_0x1f60ef(0x18b))/0x2*(-parseInt(_0x1f60ef(0x19f))/0x3)+parseInt(_0x1f60ef(0x186))/0x4*(-parseInt(_0x1f60ef(0x183))/0x5)+-parseInt(_0x1f60ef(0x1a2))/0x6*(parseInt(_0x1f60ef(0x18c))/0x7)+-parseInt(_0x1f60ef(0x181))/0x8+parseInt(_0x1f60ef(0x17b))/0x9+parseInt(_0x1f60ef(0x176))/0xa;if(_0x1f0a52===_0xd7223)break;else _0x279f18['push'](_0x279f18['shift']());}catch(_0x7fa435){_0x279f18['push'](_0x279f18['shift']());}}}(a61_0xdd68,0x6f346));import{writeFileSync}from'node:fs';import{resolve,join}from'node:path';import{fileURLToPath}from'node:url';import{dirname}from'node:path';import{createInterface}from'node:readline';import{logger}from'../utils/logger.js';import{copyDir}from'../utils/file-utils.js';import{IDE_CONFIGS,CORE_IDE_LIST,ALL_CORE_IDES}from'../utils/ai_config.js';function a61_0xd72a(_0x2e3621,_0x2acbab){_0x2e3621=_0x2e3621-0x166;const _0xdd6833=a61_0xdd68();let _0xd72a1f=_0xdd6833[_0x2e3621];return _0xd72a1f;}import{installSingleIDE}from'./skill-installer.js';import{fetchGuidesFromCDN,writeGuidesToProject}from'../utils/guides-cdn.js';const __dirname=dirname(fileURLToPath(import.meta.url));export async function skillsCommand(_0x4792a4,_0x58a6a4,_0x3a7558){const _0x19783f=a61_0xd72a;logger[_0x19783f(0x1a9)](process[_0x19783f(0x170)]());if(_0x3a7558?.['help']||_0x4792a4===_0x19783f(0x16f)){showHelp();return;}_0x4792a4!==_0x19783f(0x19e)&&(console[_0x19783f(0x17d)](_0x19783f(0x191)+(_0x4792a4||_0x19783f(0x17a))),console[_0x19783f(0x182)](_0x19783f(0x194)),console[_0x19783f(0x182)](_0x19783f(0x1ae)),console[_0x19783f(0x182)]('\x20\x20lovrabet\x20skill\x20install\x20<ide>\x20\x20\x20\x20\x20#\x20直接安装指定\x20IDE\x20的技能包'),console[_0x19783f(0x182)]('\x20\x20lovrabet\x20skill\x20--help\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20显示帮助信息\x0a'),console[_0x19783f(0x182)]('使用示例:'),console['log'](_0x19783f(0x173)),console[_0x19783f(0x182)](_0x19783f(0x1a1)),logger[_0x19783f(0x17d)](_0x19783f(0x1ad),_0x19783f(0x195)+_0x4792a4),process[_0x19783f(0x16a)](0x1)),await installSkill(_0x58a6a4?.[0x0]);}async function selectIDEs(){const _0x19f528=a61_0xd72a;return console[_0x19f528(0x182)](_0x19f528(0x16c)),CORE_IDE_LIST[_0x19f528(0x19a)]((_0xac9be8,_0x1c8c14)=>{const _0x2bc9cb=_0x19f528;console['log']('\x20\x20'+(_0x1c8c14+0x1)+'.\x20'+IDE_CONFIGS[_0xac9be8]['name']+_0x2bc9cb(0x17f)+IDE_CONFIGS[_0xac9be8][_0x2bc9cb(0x193)]);}),console[_0x19f528(0x182)](_0x19f528(0x199)),console[_0x19f528(0x182)]('\x20\x20q.\x20取消\x0a'),console[_0x19f528(0x182)](_0x19f528(0x16b)),console[_0x19f528(0x182)](_0x19f528(0x19c)),new Promise(_0x5cf151=>{const _0x49d1f2=_0x19f528,_0x413385=createInterface({'input':process['stdin'],'output':process[_0x49d1f2(0x180)]});_0x413385[_0x49d1f2(0x16d)]('请选择:\x20',_0x9286de=>{const _0x7290f0=_0x49d1f2;_0x413385['close']();const _0x56e31c=_0x9286de[_0x7290f0(0x198)]()[_0x7290f0(0x185)]();(_0x56e31c==='q'||_0x56e31c===_0x7290f0(0x167)||_0x56e31c==='exit')&&(console['log']('\x0a已取消安装\x0a'),process[_0x7290f0(0x16a)](0x0));if(_0x56e31c==='0'||_0x56e31c===_0x7290f0(0x1aa)){_0x5cf151([_0x7290f0(0x1aa)]);return;}const _0x5e243e=_0x56e31c[_0x7290f0(0x192)](/\s+/)['filter'](Boolean),_0x2b1e1f=[];for(const _0x52c5e3 of _0x5e243e){const _0x35be82=parseInt(_0x52c5e3,0xa);if(!isNaN(_0x35be82)&&_0x35be82>=0x1&&_0x35be82<=CORE_IDE_LIST[_0x7290f0(0x169)]){const _0x54ff26=CORE_IDE_LIST[_0x35be82-0x1];_0x54ff26&&!_0x2b1e1f[_0x7290f0(0x184)](_0x54ff26)&&_0x2b1e1f[_0x7290f0(0x188)](_0x54ff26);}}_0x2b1e1f['length']===0x0&&(console[_0x7290f0(0x182)](_0x7290f0(0x17c)),process[_0x7290f0(0x16a)](0x0)),_0x5cf151(_0x2b1e1f);});});}function showHelp(){const _0x10744b=a61_0xd72a;console['log'](_0x10744b(0x1ab));}function a61_0xdd68(){const _0x2d6cff=['trim','\x20\x200.\x20全部安装','forEach','some','输入\x200\x20安装所有\x20IDE,输入\x20q\x20取消\x0a','2.0.0','install','6GkhLRR','\x20失败:\x20','\x20\x20lovrabet\x20skill\x20install\x20cursor\x20\x20\x20\x20#\x20直接安装\x20Cursor\x20技能包\x0a','6GVBFag','message','startsWith','正在从\x20CDN\x20拉取开发者指南...','通用模板','warn','name','setLogPath','all','\x0aLovrabet\x20Skill\x20-\x20开发者技能包安装工具\x0a\x0a用法:\x0a\x20\x20lovrabet\x20skill\x20--help\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20显示帮助信息\x0a\x20\x20lovrabet\x20skill\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20交互式选择并安装技能包\x0a\x20\x20lovrabet\x20skill\x20install\x20--cursor\x20\x20\x20\x20直接安装指定\x20IDE\x20的技能包\x0a\x20\x20lovrabet\x20skill\x20install\x20--all\x20\x20\x20\x20\x20\x20\x20安装所有技能包\x0a\x0a安装方式:\x0a\x20\x20\x20交互式选择\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20显示\x20IDE\x20列表供选择,支持多选\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x0a\x20\x20\x20\x20→\x20使用\x20↑↓\x20移动光标,空格选中/取消,Enter\x20确认\x0a\x20\x20\x20\x20→\x20按\x20a\x20全选,按\x20i/r\x20反选,按\x20q\x20退出\x0a\x0a\x20\x20直接安装指定\x20IDE\x20(支持多个)\x20\x20\x20\x20\x20\x20\x20-\x20使用\x20--ide\x20标志直接安装\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20安装\x20Cursor\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20--claude\x20\x20#\x20安装多个\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x20--all\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20安装全部\x0a\x0a支持的\x20IDE:\x0a\x20\x20--cursor\x20\x20\x20\x20\x20\x20\x20Cursor\x20IDE\x20(.cursorrules\x20+\x20.cursor/commands/)\x0a\x20\x20--windsurf\x20\x20\x20\x20\x20Windsurf\x20IDE\x20(.windsurf/workflows/)\x0a\x20\x20--claude\x20\x20\x20\x20\x20\x20\x20Claude\x20Code\x20(.claude/skills/)\x0a\x20\x20--cline\x20\x20\x20\x20\x20\x20\x20\x20Cline\x20IDE\x20(.cline/skills/)\x0a\x20\x20--codex\x20\x20\x20\x20\x20\x20\x20\x20Codex\x20IDE\x20(.codex/skills/)\x0a\x20\x20--opencode\x20\x20\x20\x20\x20OpenCode\x20IDE\x20(.opencode/skills/)\x0a\x20\x20--qoder\x20\x20\x20\x20\x20\x20\x20\x20Qoder\x20IDE\x20(.qoder/rules/\x20+\x20.qoder/skills/)\x0a\x20\x20--codebuddy\x20\x20\x20\x20CodeBuddy\x20IDE\x20(.codebuddy/skills/)\x0a\x20\x20--trae\x20\x20\x20\x20\x20\x20\x20\x20\x20Trae\x20IDE\x20(.trae/skills/)\x0a\x20\x20--agent\x20\x20\x20\x20\x20\x20\x20\x20其他\x20(通用模板)\x20(.agent/skills/)\x20-\x20兜底方案\x0a\x20\x20--antigravity\x20\x20Antigravity\x20IDE\x20(.agent/skills/)\x0a\x20\x20--all\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20安装所有\x20IDE\x20技能包(包括通用模板)\x0a\x0a技能包内容包括:\x0a\x20\x20-\x20Filter\x20查询构建规范\x20(10\x20种常见错误对照)\x0a\x20\x20-\x20MCP\x20SQL\x20创建工作流\x20(5\x20步强制流程)\x0a\x20\x20-\x20AntD\x20UI\x20开发规范\x20(禁止\x20AI\x20味道)\x0a\x20\x20-\x20API\x20集成指南\x20(lovrabet\x20api\x20pull\x20流程)\x0a\x20\x20-\x20菜单管理指南\x20(menu\x20sync/update\x20流程)\x0a\x20\x20-\x20Backend\x20Function\x20脚本编写规范\x20(权限过滤、数据脱敏、业务逻辑)\x0a\x0a示例:\x0a\x20\x20$\x20lovrabet\x20skill\x20install\x0a\x20\x20\x20\x20→\x20交互式选择\x20IDE\x0a\x0a\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20--claude\x0a\x20\x20\x20\x20→\x20直接安装\x20Cursor\x20和\x20claude\x20code\x20技能包\x0a\x0a\x20\x20$\x20lovrabet\x20skill\x20install\x20--all\x0a\x20\x20\x20\x20→\x20安装所有\x20IDE\x20技能包\x0a\x0a安装后会在项目中创建:\x0a\x20\x20-\x20IDE\x20特定配置文件\x20(.cursorrules,\x20.windsurf/,\x20.claude/,\x20.cline/,\x20.codex/,\x20.opencode/,\x20.qoder/,\x20.codebuddy/,\x20.trae/)\x0a\x20\x20-\x20.lovrabet/skill/.shared/guides/\x20\x20-\x20开发者技能指南\x0a\x0a开发者指南位置:\x0a\x20\x20.lovrabet/skill/.shared/guides/01-typescript-sdk/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/02-mcp-sql-workflow/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/03-antd-style/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/04-troubleshooting/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/05-api-integration/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/06-menu-management/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/07-backend-function/guide.md\x0a\x20\x20','✓\x20拉取\x20','skill','\x20\x20lovrabet\x20skill\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20交互式选择并安装技能包','开发者指南位置:','quit','安装成功','length','exit','输入格式:\x20输入编号,用空格分隔\x20(例如:\x201\x203\x205)','\x0a请选择要安装技能包的\x20IDE\x20(可多选):\x0a','question','\x20\x20!\x20CDN\x20拉取失败,跳过指南安装:\x20','--help','cwd','path','info','\x20\x20lovrabet\x20skill\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20交互式选择\x20IDE','✓\x20创建\x20.lovrabet/skill-manifest.json','agent','20240340kRjsgs','keys','\x20\x20.lovrabet/skill/.shared/guides/\x20-\x20详细开发指南\x0a','397122HTeDXY','(空)','187119oPImek','\x0a未选择任何\x20IDE,安装取消\x0a','error','files','\x20-\x20','stdout','49096GmXbtP','log','255tLdZGY','includes','toLowerCase','29444hETsvi','\x20\x20✓\x20创建\x20','push','toISOString','\x0a📦\x20正在安装\x20','43144htyXDa','5976635SUJnJI','guides','.lovrabet/skill-manifest.json','folders','../../cdn-source/skills','错误:\x20不支持的命令:\x20','split','description','\x0a可用命令:','不支持的命令:\x20','\x0a没有有效的\x20IDE\x20需要安装\x0a','.lovrabet'];a61_0xdd68=function(){return _0x2d6cff;};return a61_0xdd68();}async function installSkill(_0x5a7e35){const _0x33ee45=a61_0xd72a,_0x471c00=process[_0x33ee45(0x170)](),_0x1d582f=resolve(__dirname,_0x33ee45(0x190));let _0x5b541a=[];!_0x5a7e35?_0x5b541a=await selectIDEs():_0x5b541a=[_0x5a7e35];_0x5b541a[_0x33ee45(0x184)](_0x33ee45(0x1aa))&&(_0x5b541a=[...ALL_CORE_IDES,_0x33ee45(0x175)]);const _0x33b780=[];for(const _0x2c63aa of _0x5b541a){if(_0x2c63aa===_0x33ee45(0x175))_0x33b780[_0x33ee45(0x188)]('agent');else{if(_0x2c63aa===_0x33ee45(0x1aa))continue;else IDE_CONFIGS[_0x2c63aa]?_0x33b780[_0x33ee45(0x188)](_0x2c63aa):(console[_0x33ee45(0x182)]('⚠️\x20\x20未知的平台:\x20'+_0x2c63aa+',使用通用模板'),_0x33b780[_0x33ee45(0x188)](_0x33ee45(0x175)));}}_0x33b780['length']===0x0&&(console[_0x33ee45(0x182)](_0x33ee45(0x196)),process[_0x33ee45(0x16a)](0x0));console[_0x33ee45(0x182)](_0x33ee45(0x1a5));let _0x39690b;try{_0x39690b=await fetchGuidesFromCDN(),console[_0x33ee45(0x182)](_0x33ee45(0x1ac)+Object[_0x33ee45(0x177)](_0x39690b[_0x33ee45(0x18d)])['length']+'\x20个开发者指南');}catch(_0x5ed6de){console[_0x33ee45(0x1a7)](_0x33ee45(0x16e)+(_0x5ed6de instanceof Error?_0x5ed6de[_0x33ee45(0x1a3)]:String(_0x5ed6de)));}let _0x5054ba=0x0;for(const _0x30dda0 of _0x33b780){try{const _0x1bca91=_0x30dda0==='agent'?_0x33ee45(0x1a6):IDE_CONFIGS[_0x30dda0]?.[_0x33ee45(0x1a8)]||_0x30dda0;console[_0x33ee45(0x182)](_0x33ee45(0x18a)+_0x1bca91+'...\x0a');const _0xe70c95=_0x30dda0==='agent'?undefined:IDE_CONFIGS[_0x30dda0],_0x5d4913=await installSingleIDE(_0x30dda0,_0xe70c95,_0x471c00,_0x1d582f,_0x39690b);_0x5054ba+=_0x5d4913;if(_0xe70c95?.[_0x33ee45(0x18f)])for(const _0x1434ca of _0xe70c95[_0x33ee45(0x18f)]){const _0x2307b2=_0xe70c95['files']?.[_0x33ee45(0x19b)](_0x41a9c2=>_0x41a9c2[_0x33ee45(0x171)][_0x33ee45(0x1a4)](_0x1434ca+'/'))??![];_0x2307b2?console[_0x33ee45(0x182)](_0x33ee45(0x187)+_0x1434ca+'/'):console[_0x33ee45(0x182)]('\x20\x20✓\x20创建\x20'+_0x1434ca);}if(_0xe70c95?.[_0x33ee45(0x17e)])for(const _0x10cd94 of _0xe70c95[_0x33ee45(0x17e)]){console[_0x33ee45(0x182)]('\x20\x20✓\x20创建\x20'+_0x10cd94[_0x33ee45(0x171)]);}}catch(_0x256179){console['error']('\x20\x20✗\x20安装\x20'+_0x30dda0+_0x33ee45(0x1a0)+(_0x256179 instanceof Error?_0x256179['message']:String(_0x256179)));}}_0x39690b&&writeGuidesToProject(_0x39690b,_0x471c00);const _0x277a9c={'version':_0x33ee45(0x19d),'installedAt':new Date()[_0x33ee45(0x189)](),'platforms':_0x33b780},_0x2d0cf8=join(_0x471c00,_0x33ee45(0x18e)),_0x563be8=join(_0x471c00,_0x33ee45(0x197));await copyDir(_0x563be8,_0x563be8),writeFileSync(_0x2d0cf8,JSON['stringify'](_0x277a9c,null,0x2),'utf-8'),console[_0x33ee45(0x182)](_0x33ee45(0x174)),console[_0x33ee45(0x182)]('\x0a✓\x20技能包安装成功!共安装\x20'+_0x5054ba+'\x20个目录\x0a'),console['log'](_0x33ee45(0x166)),console[_0x33ee45(0x182)](_0x33ee45(0x178)),logger[_0x33ee45(0x172)]('skill-install',_0x33ee45(0x168),{'projectRoot':_0x471c00,'ides':_0x33b780,'foldersCount':_0x5054ba});}
1
+ (function(_0x2aa9d3,_0x148ec7){const _0x23c919=a62_0x38e0,_0x23af19=_0x2aa9d3();while(!![]){try{const _0x2769ef=parseInt(_0x23c919(0x203))/0x1+-parseInt(_0x23c919(0x1da))/0x2*(-parseInt(_0x23c919(0x1ee))/0x3)+parseInt(_0x23c919(0x1e2))/0x4+-parseInt(_0x23c919(0x207))/0x5*(parseInt(_0x23c919(0x1ed))/0x6)+-parseInt(_0x23c919(0x1d7))/0x7+-parseInt(_0x23c919(0x20c))/0x8+parseInt(_0x23c919(0x215))/0x9*(-parseInt(_0x23c919(0x20f))/0xa);if(_0x2769ef===_0x148ec7)break;else _0x23af19['push'](_0x23af19['shift']());}catch(_0x305303){_0x23af19['push'](_0x23af19['shift']());}}}(a62_0x4d43,0xce022));import{writeFileSync}from'node:fs';import{resolve,join}from'node:path';import{fileURLToPath}from'node:url';import{dirname}from'node:path';function a62_0x38e0(_0x1c41b3,_0x764471){_0x1c41b3=_0x1c41b3-0x1c6;const _0x4d4366=a62_0x4d43();let _0x38e000=_0x4d4366[_0x1c41b3];return _0x38e000;}import{createInterface}from'node:readline';import{logger}from'../utils/logger.js';import{copyDir}from'../utils/file-utils.js';import{IDE_CONFIGS,CORE_IDE_LIST,ALL_CORE_IDES}from'../utils/ai_config.js';import{installSingleIDE}from'./skill-installer.js';function a62_0x4d43(){const _0x351514=['argv','.lovrabet/skill-manifest.json','split','some','-$1','description','filter','forEach','path','utf-8','输入\x200\x20安装所有\x20IDE,输入\x20q\x20取消\x0a','.lovrabet','2.0.0','\x20\x20q.\x20取消\x0a','includes','question','安装成功','\x0aLovrabet\x20Skill\x20-\x20开发者技能包安装工具\x0a\x0a用法:\x0a\x20\x20lovrabet\x20skill\x20--help\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20显示帮助信息\x0a\x20\x20lovrabet\x20skill\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20交互式选择并安装技能包\x0a\x20\x20lovrabet\x20skill\x20install\x20--cursor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20直接安装指定\x20IDE\x20的技能包\x0a\x20\x20lovrabet\x20skill\x20install\x20--all\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20安装所有技能包\x0a\x20\x20lovrabet\x20skill\x20install\x20--dangerously-bff-save\x20\x20包含\x20Backend\x20Function\x20同步工作流\x0a\x0a安装方式:\x0a\x20\x20\x20交互式选择\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20显示\x20IDE\x20列表供选择,支持多选\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x0a\x20\x20\x20\x20→\x20使用\x20↑↓\x20移动光标,空格选中/取消,Enter\x20确认\x0a\x20\x20\x20\x20→\x20按\x20a\x20全选,按\x20i/r\x20反选,按\x20q\x20退出\x0a\x0a\x20\x20直接安装指定\x20IDE\x20(支持多个)\x20\x20\x20\x20\x20\x20\x20-\x20使用\x20--ide\x20标志直接安装\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20安装\x20Cursor\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20--claude\x20\x20#\x20安装多个\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x20--all\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20安装全部\x0a\x0a\x20\x20包含\x20Backend\x20Function\x20同步工作流\x20\x20\x20-\x20使用\x20--dangerously-bff-save\x20标志\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x20--dangerously-bff-save\x0a\x20\x20\x20\x20$\x20lovrabet\x20skill\x20install\x20cursor\x20--dangerously-bff-save\x0a\x0a支持的\x20IDE:\x0a\x20\x20--cursor\x20\x20\x20\x20\x20\x20\x20Cursor\x20IDE\x20(.cursorrules\x20+\x20.cursor/commands/)\x0a\x20\x20--windsurf\x20\x20\x20\x20\x20Windsurf\x20IDE\x20(.windsurf/workflows/)\x0a\x20\x20--claude\x20\x20\x20\x20\x20\x20\x20Claude\x20Code\x20(.claude/skills/)\x0a\x20\x20--cline\x20\x20\x20\x20\x20\x20\x20\x20Cline\x20IDE\x20(.cline/skills/)\x0a\x20\x20--codex\x20\x20\x20\x20\x20\x20\x20\x20Codex\x20IDE\x20(.codex/skills/)\x0a\x20\x20--opencode\x20\x20\x20\x20\x20OpenCode\x20IDE\x20(.opencode/skills/)\x0a\x20\x20--qoder\x20\x20\x20\x20\x20\x20\x20\x20Qoder\x20IDE\x20(.qoder/rules/\x20+\x20.qoder/skills/)\x0a\x20\x20--codebuddy\x20\x20\x20\x20CodeBuddy\x20IDE\x20(.codebuddy/skills/)\x0a\x20\x20--trae\x20\x20\x20\x20\x20\x20\x20\x20\x20Trae\x20IDE\x20(.trae/skills/)\x0a\x20\x20--agent\x20\x20\x20\x20\x20\x20\x20\x20其他\x20(通用模板)\x20(.agent/skills/)\x20-\x20兜底方案\x0a\x20\x20--antigravity\x20\x20Antigravity\x20IDE\x20(.agent/skills/)\x0a\x20\x20--all\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20安装所有\x20IDE\x20技能包(包括通用模板)\x0a\x0a选项:\x0a\x20\x20--dangerously-bff-save\x20\x20\x20\x20包含\x20Backend\x20Function\x20同步工作流指南\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(需要\x20MCP\x20服务器启用相应\x20tools)\x0a\x0a技能包内容包括:\x0a\x20\x20-\x20Filter\x20查询构建规范\x20(10\x20种常见错误对照)\x0a\x20\x20-\x20MCP\x20SQL\x20创建工作流\x20(5\x20步强制流程)\x0a\x20\x20-\x20AntD\x20UI\x20开发规范\x20(禁止\x20AI\x20味道)\x0a\x20\x20-\x20API\x20集成指南\x20(lovrabet\x20api\x20pull\x20流程)\x0a\x20\x20-\x20菜单管理指南\x20(menu\x20sync/update\x20流程)\x0a\x20\x20-\x20Backend\x20Function\x20脚本编写规范\x20(权限过滤、数据脱敏、业务逻辑)\x0a\x20\x20-\x20Backend\x20Function\x20同步工作流\x20(需\x20--dangerously-bff-save\x20启用)\x0a\x0a示例:\x0a\x20\x20$\x20lovrabet\x20skill\x20install\x0a\x20\x20\x20\x20→\x20交互式选择\x20IDE\x0a\x0a\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20--claude\x0a\x20\x20\x20\x20→\x20直接安装\x20Cursor\x20和\x20claude\x20code\x20技能包\x0a\x0a\x20\x20$\x20lovrabet\x20skill\x20install\x20--dangerously-bff-save\x0a\x20\x20\x20\x20→\x20安装技能包并包含\x20Backend\x20Function\x20同步工作流\x0a\x0a\x20\x20$\x20lovrabet\x20skill\x20install\x20--all\x0a\x20\x20\x20\x20→\x20安装所有\x20IDE\x20技能包\x0a\x0a安装后会在项目中创建:\x0a\x20\x20-\x20IDE\x20特定配置文件\x20(.cursorrules,\x20.windsurf/,\x20.claude/,\x20.cline/,\x20.codex/,\x20.opencode/,\x20.qoder/,\x20.codebuddy/,\x20.trae/)\x0a\x20\x20-\x20.lovrabet/skill/.shared/guides/\x20\x20-\x20开发者技能指南\x0a\x0a开发者指南位置:\x0a\x20\x20.lovrabet/skill/.shared/guides/01-typescript-sdk/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/02-mcp-sql-workflow/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/03-antd-style/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/04-troubleshooting/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/05-api-integration/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/06-menu-management/guide.md\x0a\x20\x20.lovrabet/skill/.shared/guides/07-backend-function/guide.md\x0a\x20\x20','warn','1574428EiYxft','from','skill-install','✓\x20拉取\x20','45adsCCe','输入格式:\x20输入编号,用空格分隔\x20(例如:\x201\x203\x205)','message','不支持的命令:\x20','slice','2255224SBRpGm','.lovrabet/skill/.shared/guides','\x0a已取消安装\x0a','20pFdtjy','✓\x20创建\x20.lovrabet/skill-manifest.json','help','exit','\x20\x20lovrabet\x20skill\x20install\x20<ide>\x20\x20\x20\x20\x20#\x20直接安装指定\x20IDE\x20的技能包','\x20-\x20','4442256PGiNbg','agent','install','../../cdn-source/skills','setLogPath','length','keys','\x20\x20lovrabet\x20skill\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20交互式选择并安装技能包','\x20个目录\x0a','log','\x20\x20lovrabet\x20skill\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20交互式选择\x20IDE','push','...\x0a','\x20\x20✓\x20创建\x20','close','skill','error','\x0a没有有效的\x20IDE\x20需要安装\x0a','\x20个开发者指南','\x20\x20.lovrabet/skill/.shared/guides/\x20-\x20详细开发指南\x0a','all','567686aIhUdM','\x0a请选择要安装技能包的\x20IDE\x20(可多选):\x0a','\x0a未选择任何\x20IDE,安装取消\x0a','14218ZcHIXC','(含扩展)','files','guides','name','\x0a可用命令:','\x20\x20lovrabet\x20skill\x20install\x20cursor\x20\x20\x20\x20#\x20直接安装\x20Cursor\x20技能包\x0a','replace','930832kTVULT','⚠️\x20\x20未知的平台:\x20','stringify','\x20\x20✗\x20安装\x20','toLowerCase','cwd','stdout','stdin','...','folders','(空)','102294doVflz','228dUFNpe','startsWith'];a62_0x4d43=function(){return _0x351514;};return a62_0x4d43();}import{fetchGuidesFromCDN,writeGuidesToProject}from'../utils/guides-cdn.js';const __dirname=dirname(fileURLToPath(import.meta.url));export function camelCaseFlagsToKebab(_0x23a11b){const _0x5a939d=a62_0x38e0,_0x31b451=[];for(const [_0x57ff08,_0x51ce3e]of Object['entries'](_0x23a11b)){if(_0x51ce3e===!![]){const _0x25fc2e=_0x57ff08[_0x5a939d(0x1e1)](/([A-Z])/g,_0x5a939d(0x1f4))[_0x5a939d(0x1e6)]();_0x31b451['push'](_0x25fc2e);}}return _0x31b451;}export function parseDynamicFlags(){const _0x167aa1=a62_0x38e0,_0xb21d78=[];for(let _0x37078f=0x3;_0x37078f<process[_0x167aa1(0x1f0)][_0x167aa1(0x1c7)];_0x37078f++){const _0x3d18a2=process[_0x167aa1(0x1f0)][_0x37078f];if(_0x3d18a2&&_0x3d18a2[_0x167aa1(0x1ef)]('--')){const _0x358338=_0x3d18a2[_0x167aa1(0x20b)](0x2);_0x358338&&!_0x358338[_0x167aa1(0x1fe)]('=')&&_0xb21d78['push'](_0x358338);}}return _0xb21d78;}export function getAllProvidedFlags(_0x2b8514){const _0x42f2ca=a62_0x38e0,_0x1ca3b8=camelCaseFlagsToKebab(_0x2b8514),_0x159f85=parseDynamicFlags(),_0x1bca28=new Set([..._0x1ca3b8,..._0x159f85]);return Array[_0x42f2ca(0x204)](_0x1bca28);}export async function skillsCommand(_0x5f06a9,_0x263688,_0x12ad6c){const _0x58cb86=a62_0x38e0;logger[_0x58cb86(0x1c6)](process[_0x58cb86(0x1e7)]());if(_0x12ad6c?.[_0x58cb86(0x211)]||_0x5f06a9==='--help'){showHelp();return;}_0x5f06a9!==_0x58cb86(0x217)&&(console[_0x58cb86(0x1d2)]('错误:\x20不支持的命令:\x20'+(_0x5f06a9||_0x58cb86(0x1ec))),console[_0x58cb86(0x1cb)](_0x58cb86(0x1df)),console['log'](_0x58cb86(0x1c9)),console[_0x58cb86(0x1cb)](_0x58cb86(0x213)),console['log']('\x20\x20lovrabet\x20skill\x20--help\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20显示帮助信息\x0a'),console['log']('使用示例:'),console[_0x58cb86(0x1cb)](_0x58cb86(0x1cc)),console['log'](_0x58cb86(0x1e0)),logger['error'](_0x58cb86(0x1d1),_0x58cb86(0x20a)+_0x5f06a9),process[_0x58cb86(0x212)](0x1));let _0x27b03d=_0x263688?.[0x0];const _0x59e44e=getAllProvidedFlags(_0x12ad6c??{});_0x27b03d?.[_0x58cb86(0x1ef)]('--')&&(_0x27b03d=undefined),await installSkill(_0x27b03d??_0x58cb86(0x216),_0x59e44e);}async function selectIDEs(){const _0x3e4e13=a62_0x38e0;return console[_0x3e4e13(0x1cb)](_0x3e4e13(0x1d8)),CORE_IDE_LIST[_0x3e4e13(0x1f7)]((_0x2be655,_0x417683)=>{const _0x4d7fac=_0x3e4e13;console[_0x4d7fac(0x1cb)]('\x20\x20'+(_0x417683+0x1)+'.\x20'+IDE_CONFIGS[_0x2be655]['name']+_0x4d7fac(0x214)+IDE_CONFIGS[_0x2be655][_0x4d7fac(0x1f5)]);}),console[_0x3e4e13(0x1cb)]('\x20\x200.\x20全部安装'),console['log'](_0x3e4e13(0x1fd)),console[_0x3e4e13(0x1cb)](_0x3e4e13(0x208)),console[_0x3e4e13(0x1cb)](_0x3e4e13(0x1fa)),new Promise(_0x40da42=>{const _0x20abf6=_0x3e4e13,_0x3afb89=createInterface({'input':process[_0x20abf6(0x1e9)],'output':process[_0x20abf6(0x1e8)]});_0x3afb89[_0x20abf6(0x1ff)]('请选择:\x20',_0x5a4790=>{const _0x4b1bc2=_0x20abf6;_0x3afb89[_0x4b1bc2(0x1d0)]();const _0x12a465=_0x5a4790['trim']()[_0x4b1bc2(0x1e6)]();(_0x12a465==='q'||_0x12a465==='quit'||_0x12a465===_0x4b1bc2(0x212))&&(console[_0x4b1bc2(0x1cb)](_0x4b1bc2(0x20e)),process[_0x4b1bc2(0x212)](0x0));if(_0x12a465==='0'||_0x12a465===_0x4b1bc2(0x1d6)){_0x40da42(['all']);return;}const _0xa999d1=_0x12a465[_0x4b1bc2(0x1f2)](/\s+/)[_0x4b1bc2(0x1f6)](Boolean),_0x31928f=[];for(const _0x4427cd of _0xa999d1){const _0x48b51d=parseInt(_0x4427cd,0xa);if(!isNaN(_0x48b51d)&&_0x48b51d>=0x1&&_0x48b51d<=CORE_IDE_LIST[_0x4b1bc2(0x1c7)]){const _0x10b0cb=CORE_IDE_LIST[_0x48b51d-0x1];_0x10b0cb&&!_0x31928f[_0x4b1bc2(0x1fe)](_0x10b0cb)&&_0x31928f['push'](_0x10b0cb);}}_0x31928f['length']===0x0&&(console[_0x4b1bc2(0x1cb)](_0x4b1bc2(0x1d9)),process[_0x4b1bc2(0x212)](0x0)),_0x40da42(_0x31928f);});});}function showHelp(){const _0x55d35b=a62_0x38e0;console[_0x55d35b(0x1cb)](_0x55d35b(0x201));}async function installSkill(_0x2c1980,_0x2d0c71){const _0x21ed81=a62_0x38e0,_0x545f59=process[_0x21ed81(0x1e7)](),_0x3e7548=resolve(__dirname,_0x21ed81(0x218));let _0x1ab5c1=[];!_0x2c1980?_0x1ab5c1=await selectIDEs():_0x1ab5c1=[_0x2c1980];_0x1ab5c1[_0x21ed81(0x1fe)](_0x21ed81(0x1d6))&&(_0x1ab5c1=[...ALL_CORE_IDES,_0x21ed81(0x216)]);const _0x31a9a0=[];for(const _0x1344b4 of _0x1ab5c1){if(_0x1344b4===_0x21ed81(0x216))_0x31a9a0[_0x21ed81(0x1cd)](_0x21ed81(0x216));else{if(_0x1344b4==='all')continue;else IDE_CONFIGS[_0x1344b4]?_0x31a9a0[_0x21ed81(0x1cd)](_0x1344b4):(console[_0x21ed81(0x1cb)](_0x21ed81(0x1e3)+_0x1344b4+',使用通用模板'),_0x31a9a0[_0x21ed81(0x1cd)](_0x21ed81(0x216)));}}_0x31a9a0[_0x21ed81(0x1c7)]===0x0&&(console[_0x21ed81(0x1cb)](_0x21ed81(0x1d3)),process['exit'](0x0));const _0x38e333=_0x2d0c71&&_0x2d0c71[_0x21ed81(0x1c7)]>0x0;console[_0x21ed81(0x1cb)]('正在从\x20CDN\x20拉取开发者指南'+(_0x38e333?_0x21ed81(0x1db):'')+_0x21ed81(0x1ea));let _0x405879;try{_0x405879=await fetchGuidesFromCDN(_0x38e333),console['log'](_0x21ed81(0x206)+Object[_0x21ed81(0x1c8)](_0x405879[_0x21ed81(0x1dd)])[_0x21ed81(0x1c7)]+_0x21ed81(0x1d4));}catch(_0x23abf4){console[_0x21ed81(0x202)]('\x20\x20!\x20CDN\x20拉取失败,跳过指南安装:\x20'+(_0x23abf4 instanceof Error?_0x23abf4[_0x21ed81(0x209)]:String(_0x23abf4)));}let _0x52fee0=0x0;for(const _0x20a1bd of _0x31a9a0){try{const _0x56d855=_0x20a1bd===_0x21ed81(0x216)?'通用模板':IDE_CONFIGS[_0x20a1bd]?.[_0x21ed81(0x1de)]||_0x20a1bd;console['log']('\x0a📦\x20正在安装\x20'+_0x56d855+_0x21ed81(0x1ce));const _0x43f7ee=_0x20a1bd===_0x21ed81(0x216)?undefined:IDE_CONFIGS[_0x20a1bd],_0x53c010=await installSingleIDE(_0x20a1bd,_0x43f7ee,_0x545f59,_0x3e7548,_0x405879,_0x2d0c71);_0x52fee0+=_0x53c010;if(_0x43f7ee?.[_0x21ed81(0x1eb)])for(const _0x50709c of _0x43f7ee[_0x21ed81(0x1eb)]){const _0x20dc4c=_0x43f7ee[_0x21ed81(0x1dc)]?.[_0x21ed81(0x1f3)](_0x5bf487=>_0x5bf487[_0x21ed81(0x1f8)][_0x21ed81(0x1ef)](_0x50709c+'/'))??![];_0x20dc4c?console[_0x21ed81(0x1cb)](_0x21ed81(0x1cf)+_0x50709c+'/'):console[_0x21ed81(0x1cb)](_0x21ed81(0x1cf)+_0x50709c);}if(_0x43f7ee?.[_0x21ed81(0x1dc)])for(const _0x745dd6 of _0x43f7ee[_0x21ed81(0x1dc)]){console[_0x21ed81(0x1cb)]('\x20\x20✓\x20创建\x20'+_0x745dd6[_0x21ed81(0x1f8)]);}}catch(_0xa9b58){console[_0x21ed81(0x1d2)](_0x21ed81(0x1e5)+_0x20a1bd+'\x20失败:\x20'+(_0xa9b58 instanceof Error?_0xa9b58[_0x21ed81(0x209)]:String(_0xa9b58)));}}_0x405879&&writeGuidesToProject(_0x405879,_0x545f59,_0x21ed81(0x20d),_0x2d0c71);const _0x3f6011={'version':_0x21ed81(0x1fc),'installedAt':new Date()['toISOString'](),'platforms':_0x31a9a0},_0x578b14=join(_0x545f59,_0x21ed81(0x1f1)),_0x2a32fd=join(_0x545f59,_0x21ed81(0x1fb));await copyDir(_0x2a32fd,_0x2a32fd),writeFileSync(_0x578b14,JSON[_0x21ed81(0x1e4)](_0x3f6011,null,0x2),_0x21ed81(0x1f9)),console[_0x21ed81(0x1cb)](_0x21ed81(0x210)),console[_0x21ed81(0x1cb)]('\x0a✓\x20技能包安装成功!共安装\x20'+_0x52fee0+_0x21ed81(0x1ca)),console['log']('开发者指南位置:'),console[_0x21ed81(0x1cb)](_0x21ed81(0x1d5)),logger['info'](_0x21ed81(0x205),_0x21ed81(0x200),{'projectRoot':_0x545f59,'ides':_0x31a9a0,'foldersCount':_0x52fee0});}
@@ -1 +1 @@
1
- (function(_0x4ab563,_0x431ccd){const _0x19b7b5=a62_0x1a2b,_0x25ba2f=_0x4ab563();while(!![]){try{const _0x3368ff=parseInt(_0x19b7b5(0xd2))/0x1+-parseInt(_0x19b7b5(0xbc))/0x2+-parseInt(_0x19b7b5(0xc8))/0x3*(parseInt(_0x19b7b5(0xc2))/0x4)+parseInt(_0x19b7b5(0xb8))/0x5+-parseInt(_0x19b7b5(0xc7))/0x6+-parseInt(_0x19b7b5(0xd0))/0x7*(parseInt(_0x19b7b5(0xc0))/0x8)+parseInt(_0x19b7b5(0xc9))/0x9*(parseInt(_0x19b7b5(0xb9))/0xa);if(_0x3368ff===_0x431ccd)break;else _0x25ba2f['push'](_0x25ba2f['shift']());}catch(_0x1d2649){_0x25ba2f['push'](_0x25ba2f['shift']());}}}(a62_0x31e9,0xd2f9e));function a62_0x1a2b(_0x2e4226,_0x9687c){_0x2e4226=_0x2e4226-0xb8;const _0x31e969=a62_0x31e9();let _0x1a2b9c=_0x31e969[_0x2e4226];return _0x1a2b9c;}import{writeFileSync,existsSync,mkdirSync}from'node:fs';import{resolve,join}from'node:path';import{fileURLToPath}from'node:url';import{dirname}from'node:path';import{logger}from'../utils/logger.js';import{IDE_CONFIGS}from'../utils/ai_config.js';function a62_0x31e9(){const _0x50dc7a=['guides','8972rfleSo','✓\x20拉取\x20','utf-8','\x20\x20✗\x20安装\x20','.lovrabet','7062042ffiJvb','33xDHudi','465282QGcDSz','\x20个目录','2.0.0','toISOString','正在从\x20CDN\x20拉取开发者指南...','skill-install-non-interactive','message','7jUOroo','error','213089vwdoXE','log','\x0a✓\x20技能包安装成功!共安装\x20','\x20\x20!\x20CDN\x20拉取失败,跳过指南安装:\x20','keys','../../cdn-source/skills','warn','6278655uTrGKH','660qQZLMA','\x20\x20✓\x20','name','2488558HNYiWG','\x20个开发者指南','.lovrabet/skill-manifest.json','setLogPath','12566168jtvEqm'];a62_0x31e9=function(){return _0x50dc7a;};return a62_0x31e9();}import{installSingleIDE}from'./skill-installer.js';import{fetchGuidesFromCDN,writeGuidesToProject}from'../utils/guides-cdn.js';const __dirname=dirname(fileURLToPath(import.meta.url));export async function installSkillsNonInteractive(_0x172208,_0x4c6274=process['cwd']()){const _0x31acf4=a62_0x1a2b,_0x32fe58=resolve(__dirname,_0x31acf4(0xd7));logger[_0x31acf4(0xbf)](_0x4c6274),logger['info'](_0x31acf4(0xce),'开始安装技能包',{'ides':_0x172208});const _0x2bbaa4=join(_0x4c6274,_0x31acf4(0xc6));!existsSync(_0x2bbaa4)&&mkdirSync(_0x2bbaa4,{'recursive':!![]});console[_0x31acf4(0xd3)](_0x31acf4(0xcd));let _0x36fec0;try{_0x36fec0=await fetchGuidesFromCDN(),console[_0x31acf4(0xd3)](_0x31acf4(0xc3)+Object[_0x31acf4(0xd6)](_0x36fec0[_0x31acf4(0xc1)])['length']+_0x31acf4(0xbd));}catch(_0x431433){console[_0x31acf4(0xd8)](_0x31acf4(0xd5)+(_0x431433 instanceof Error?_0x431433['message']:String(_0x431433)));}let _0x5827fa=0x0;for(const _0x16e4d5 of _0x172208){try{const _0x533261=IDE_CONFIGS[_0x16e4d5];if(!_0x533261){console[_0x31acf4(0xd8)]('\x20\x20✗\x20未知的\x20IDE:\x20'+_0x16e4d5);continue;}const _0x34a5b0=await installSingleIDE(_0x16e4d5,_0x533261,_0x4c6274,_0x32fe58,_0x36fec0);_0x5827fa+=_0x34a5b0,console[_0x31acf4(0xd3)](_0x31acf4(0xba)+(_0x533261[_0x31acf4(0xbb)]||_0x16e4d5));}catch(_0x25a8a5){console[_0x31acf4(0xd1)](_0x31acf4(0xc5)+_0x16e4d5+'\x20失败:\x20'+(_0x25a8a5 instanceof Error?_0x25a8a5[_0x31acf4(0xcf)]:String(_0x25a8a5)));}}_0x36fec0&&writeGuidesToProject(_0x36fec0,_0x4c6274);const _0x2cc682={'version':_0x31acf4(0xcb),'installedAt':new Date()[_0x31acf4(0xcc)](),'platforms':_0x172208},_0x5031d9=join(_0x4c6274,_0x31acf4(0xbe));writeFileSync(_0x5031d9,JSON['stringify'](_0x2cc682,null,0x2),_0x31acf4(0xc4)),logger['info'](_0x31acf4(0xce),'安装成功',{'projectRoot':_0x4c6274,'ides':_0x172208,'foldersCount':_0x5827fa}),console[_0x31acf4(0xd3)](_0x31acf4(0xd4)+_0x5827fa+_0x31acf4(0xca)),console['log']('开发者指南位置:\x20.lovrabet/skill/.shared/guides/');}
1
+ (function(_0xba27e,_0xa1181b){const _0xf679d1=a63_0x27bf,_0x3d7af8=_0xba27e();while(!![]){try{const _0x2699ea=-parseInt(_0xf679d1(0x1d0))/0x1+parseInt(_0xf679d1(0x1c7))/0x2*(-parseInt(_0xf679d1(0x1d1))/0x3)+parseInt(_0xf679d1(0x1be))/0x4*(-parseInt(_0xf679d1(0x1de))/0x5)+parseInt(_0xf679d1(0x1d3))/0x6+-parseInt(_0xf679d1(0x1bd))/0x7*(parseInt(_0xf679d1(0x1cc))/0x8)+parseInt(_0xf679d1(0x1c1))/0x9+parseInt(_0xf679d1(0x1cb))/0xa;if(_0x2699ea===_0xa1181b)break;else _0x3d7af8['push'](_0x3d7af8['shift']());}catch(_0x47537d){_0x3d7af8['push'](_0x3d7af8['shift']());}}}(a63_0x49f1,0x63dbf));import{writeFileSync,existsSync,mkdirSync}from'node:fs';import{resolve,join}from'node:path';function a63_0x27bf(_0x4a27b6,_0x36c992){_0x4a27b6=_0x4a27b6-0x1b8;const _0x49f155=a63_0x49f1();let _0x27bf41=_0x49f155[_0x4a27b6];return _0x27bf41;}import{fileURLToPath}from'node:url';import{dirname}from'node:path';function a63_0x49f1(){const _0x409944=['warn','message','\x0a✓\x20技能包安装成功!共安装\x20','2imlPGv','.lovrabet/skill-manifest.json','error','toISOString','265470USlSRt','88CsCEGZ','utf-8','length','\x20\x20✓\x20','110279GTAQul','144708UemCSp','\x20个开发者指南','3486756SfDmLx','../../cdn-source/skills','setLogPath','...','skill-install-non-interactive','\x20\x20✗\x20未知的\x20IDE:\x20','开始安装技能包','log','guides','.lovrabet/skill/.shared/guides','正在从\x20CDN\x20拉取开发者指南','474645ncgIfF','✓\x20拉取\x20','2.0.0','.lovrabet','安装成功','info','217112hpGziH','4gnsmlI','\x20个目录','keys','3563730RKgbuH','name','\x20失败:\x20'];a63_0x49f1=function(){return _0x409944;};return a63_0x49f1();}import{logger}from'../utils/logger.js';import{IDE_CONFIGS}from'../utils/ai_config.js';import{installSingleIDE}from'./skill-installer.js';import{fetchGuidesFromCDN,writeGuidesToProject}from'../utils/guides-cdn.js';const __dirname=dirname(fileURLToPath(import.meta.url));export async function installSkillsNonInteractive(_0x320e71,_0x56166d,_0x57c4b7=process['cwd']()){const _0x4856ef=a63_0x27bf,_0x6e7fc9=resolve(__dirname,_0x4856ef(0x1d4));logger[_0x4856ef(0x1d5)](_0x57c4b7),logger[_0x4856ef(0x1bc)](_0x4856ef(0x1d7),_0x4856ef(0x1d9),{'ides':_0x320e71});const _0x6b7e5d=join(_0x57c4b7,_0x4856ef(0x1ba));!existsSync(_0x6b7e5d)&&mkdirSync(_0x6b7e5d,{'recursive':!![]});const _0x54f824=_0x56166d&&_0x56166d[_0x4856ef(0x1ce)]>0x0;console[_0x4856ef(0x1da)](_0x4856ef(0x1dd)+(_0x54f824?'(含扩展)':'')+_0x4856ef(0x1d6));let _0x1a380b;try{_0x1a380b=await fetchGuidesFromCDN(_0x54f824),console[_0x4856ef(0x1da)](_0x4856ef(0x1b8)+Object[_0x4856ef(0x1c0)](_0x1a380b[_0x4856ef(0x1db)])[_0x4856ef(0x1ce)]+_0x4856ef(0x1d2));}catch(_0x4cd8ec){console[_0x4856ef(0x1c4)]('\x20\x20!\x20CDN\x20拉取失败,跳过指南安装:\x20'+(_0x4cd8ec instanceof Error?_0x4cd8ec[_0x4856ef(0x1c5)]:String(_0x4cd8ec)));}let _0x614edd=0x0;for(const _0x3b2de8 of _0x320e71){try{const _0x3b83b0=IDE_CONFIGS[_0x3b2de8];if(!_0x3b83b0){console[_0x4856ef(0x1c4)](_0x4856ef(0x1d8)+_0x3b2de8);continue;}const _0xbca1b6=await installSingleIDE(_0x3b2de8,_0x3b83b0,_0x57c4b7,_0x6e7fc9,_0x1a380b,_0x56166d);_0x614edd+=_0xbca1b6,console['log'](_0x4856ef(0x1cf)+(_0x3b83b0[_0x4856ef(0x1c2)]||_0x3b2de8));}catch(_0x3494ae){console[_0x4856ef(0x1c9)]('\x20\x20✗\x20安装\x20'+_0x3b2de8+_0x4856ef(0x1c3)+(_0x3494ae instanceof Error?_0x3494ae[_0x4856ef(0x1c5)]:String(_0x3494ae)));}}_0x1a380b&&writeGuidesToProject(_0x1a380b,_0x57c4b7,_0x4856ef(0x1dc),_0x56166d);const _0x481e8d={'version':_0x4856ef(0x1b9),'installedAt':new Date()[_0x4856ef(0x1ca)](),'platforms':_0x320e71},_0x44d6fa=join(_0x57c4b7,_0x4856ef(0x1c8));writeFileSync(_0x44d6fa,JSON['stringify'](_0x481e8d,null,0x2),_0x4856ef(0x1cd)),logger[_0x4856ef(0x1bc)](_0x4856ef(0x1d7),_0x4856ef(0x1bb),{'projectRoot':_0x57c4b7,'ides':_0x320e71,'foldersCount':_0x614edd}),console[_0x4856ef(0x1da)](_0x4856ef(0x1c6)+_0x614edd+_0x4856ef(0x1bf)),console[_0x4856ef(0x1da)]('开发者指南位置:\x20.lovrabet/skill/.shared/guides/');}
@@ -1 +1 @@
1
- function a63_0x12d3(){const _0x11e93f=['429906CNXvIL','startsWith','utf-8','45cDQvOC','.shared','path','folders','9FTmiYE','some','SKILL.md.tpl','template','105fyxDnJ','272588GFZyuN','26064NvqFwD','2255270OlJqdd','6539197pMSljQ','1994032DwnygT','1310394UkqDnD','files'];a63_0x12d3=function(){return _0x11e93f;};return a63_0x12d3();}(function(_0x5e6023,_0x3c758c){const _0x40a3a0=a63_0x275f,_0x268ee9=_0x5e6023();while(!![]){try{const _0x1fc5b9=parseInt(_0x40a3a0(0x1f0))/0x1+parseInt(_0x40a3a0(0x1fd))/0x2*(parseInt(_0x40a3a0(0x1fb))/0x3)+parseInt(_0x40a3a0(0x1fc))/0x4*(parseInt(_0x40a3a0(0x1f3))/0x5)+-parseInt(_0x40a3a0(0x201))/0x6+-parseInt(_0x40a3a0(0x1ff))/0x7+parseInt(_0x40a3a0(0x200))/0x8+-parseInt(_0x40a3a0(0x1f7))/0x9*(-parseInt(_0x40a3a0(0x1fe))/0xa);if(_0x1fc5b9===_0x3c758c)break;else _0x268ee9['push'](_0x268ee9['shift']());}catch(_0x1f2ae9){_0x268ee9['push'](_0x268ee9['shift']());}}}(a63_0x12d3,0xc8938));import{existsSync,mkdirSync,writeFileSync,readFileSync}from'node:fs';import{dirname,join}from'node:path';function a63_0x275f(_0x12b4ae,_0x25c251){_0x12b4ae=_0x12b4ae-0x1f0;const _0x12d3cf=a63_0x12d3();let _0x275f60=_0x12d3cf[_0x12b4ae];return _0x275f60;}import{writeSkillFile}from'../utils/guides-cdn.js';export async function installSingleIDE(_0x1f5238,_0x45167e,_0x53c011,_0x2cdc64,_0x4011e4){const _0x84dc9=a63_0x275f;let _0x3573db=0x0;const _0xe9c939=_0x45167e?.[_0x84dc9(0x1f6)]??['.'+_0x1f5238];for(const _0x302e6a of _0xe9c939){const _0x11b7fa=join(_0x53c011,_0x302e6a),_0x19ab3d=_0x45167e?.[_0x84dc9(0x202)]?.[_0x84dc9(0x1f8)](_0x573af2=>_0x573af2[_0x84dc9(0x1f5)][_0x84dc9(0x1f1)](_0x302e6a+'/'))??![];_0x19ab3d?!existsSync(_0x11b7fa)&&(mkdirSync(_0x11b7fa,{'recursive':!![]}),_0x3573db++):!existsSync(_0x11b7fa)&&(writeFileSync(_0x11b7fa,'','utf-8'),_0x3573db++);}if(_0x45167e?.[_0x84dc9(0x202)]){const _0x47371e=_0x45167e['name']||_0x1f5238;for(const _0xc63947 of _0x45167e[_0x84dc9(0x202)]){const _0x1c2196=join(_0x53c011,_0xc63947['path']);await createFileFromTemplate(_0xc63947,_0x1c2196,_0x47371e,_0x2cdc64,_0x4011e4),_0x3573db++;}}return _0x3573db;}export async function createFileFromTemplate(_0x3eefe5,_0x2e42d2,_0x13a64e,_0x14aaff,_0x22e374){const _0x265cc0=a63_0x275f,_0x4588ab=dirname(_0x2e42d2);!existsSync(_0x4588ab)&&mkdirSync(_0x4588ab,{'recursive':!![]});if(existsSync(_0x2e42d2))return;if(_0x3eefe5['template']){if(_0x22e374&&_0x3eefe5[_0x265cc0(0x1fa)]===_0x265cc0(0x1f9))try{writeSkillFile(_0x22e374,_0x2e42d2,_0x13a64e);return;}catch{}const _0x2745c8=join(_0x14aaff,_0x265cc0(0x1f4),_0x3eefe5['template']);if(existsSync(_0x2745c8)){let _0x5bf9e0=readFileSync(_0x2745c8,_0x265cc0(0x1f2));_0x5bf9e0=_0x5bf9e0['replace'](/\{\{IDE_NAME\}\}/g,_0x13a64e),writeFileSync(_0x2e42d2,_0x5bf9e0,'utf-8');return;}}writeFileSync(_0x2e42d2,'','utf-8');}
1
+ function a64_0x2972(_0x46a7c4,_0x5f3def){_0x46a7c4=_0x46a7c4-0x1ba;const _0x49f4fd=a64_0x49f4();let _0x2972a2=_0x49f4fd[_0x46a7c4];return _0x2972a2;}(function(_0x4928a5,_0x3b02f1){const _0x585e9e=a64_0x2972,_0x5bb854=_0x4928a5();while(!![]){try{const _0x3b7a3a=parseInt(_0x585e9e(0x1c7))/0x1+-parseInt(_0x585e9e(0x1d6))/0x2+-parseInt(_0x585e9e(0x1cf))/0x3*(-parseInt(_0x585e9e(0x1c1))/0x4)+parseInt(_0x585e9e(0x1da))/0x5*(-parseInt(_0x585e9e(0x1c4))/0x6)+parseInt(_0x585e9e(0x1c9))/0x7*(-parseInt(_0x585e9e(0x1cd))/0x8)+parseInt(_0x585e9e(0x1c5))/0x9*(-parseInt(_0x585e9e(0x1c8))/0xa)+parseInt(_0x585e9e(0x1d0))/0xb;if(_0x3b7a3a===_0x3b02f1)break;else _0x5bb854['push'](_0x5bb854['shift']());}catch(_0x325c66){_0x5bb854['push'](_0x5bb854['shift']());}}}(a64_0x49f4,0xc3a37));import{existsSync,mkdirSync,writeFileSync,readFileSync}from'node:fs';import{dirname,join}from'node:path';import{writeSkillFile,appendExtendContents}from'../utils/guides-cdn.js';export async function installSingleIDE(_0x46c198,_0x1ec7b9,_0x2417d1,_0x205c4f,_0xa561a1,_0x4a1f4c){const _0x1c5463=a64_0x2972;let _0x8a2ec2=0x0;const _0x4bf24e=_0x1ec7b9?.[_0x1c5463(0x1d9)]??['.'+_0x46c198];for(const _0x3b3f50 of _0x4bf24e){const _0x5717db=join(_0x2417d1,_0x3b3f50),_0x4980f5=_0x1ec7b9?.[_0x1c5463(0x1d8)]?.[_0x1c5463(0x1bc)](_0x1e16e9=>_0x1e16e9[_0x1c5463(0x1d1)][_0x1c5463(0x1ce)](_0x3b3f50+'/'))??![];_0x4980f5?!existsSync(_0x5717db)&&(mkdirSync(_0x5717db,{'recursive':!![]}),_0x8a2ec2++):!existsSync(_0x5717db)&&(writeFileSync(_0x5717db,'',_0x1c5463(0x1ba)),_0x8a2ec2++);}if(_0x1ec7b9?.['files']){const _0x5c12cc=_0x1ec7b9[_0x1c5463(0x1cb)]||_0x46c198;for(const _0x41a27d of _0x1ec7b9[_0x1c5463(0x1d8)]){const _0x10f8ad=join(_0x2417d1,_0x41a27d[_0x1c5463(0x1d1)]);await createFileFromTemplate(_0x41a27d,_0x10f8ad,_0x5c12cc,_0x205c4f,_0xa561a1,_0x4a1f4c),_0x8a2ec2++;}}return _0x8a2ec2;}export async function createFileFromTemplate(_0x2577d0,_0x5c78eb,_0x3169a7,_0x6ef4f9,_0x2a02b7,_0xcc5a23){const _0x1c0ca2=a64_0x2972,_0x539139=dirname(_0x5c78eb);!existsSync(_0x539139)&&mkdirSync(_0x539139,{'recursive':!![]});const _0x4af5e0=_0x2577d0['template']===_0x1c0ca2(0x1d4);if(existsSync(_0x5c78eb)&&!_0x4af5e0)return;if(_0x2577d0[_0x1c0ca2(0x1d3)]){const _0x107cd3=join(_0x6ef4f9,_0x2577d0[_0x1c0ca2(0x1d3)]);if(existsSync(_0x107cd3)){let _0x533bfa=readFileSync(_0x107cd3,_0x1c0ca2(0x1ba));_0x533bfa=_0x533bfa[_0x1c0ca2(0x1c3)](/\{\{IDE_NAME\}\}/g,_0x3169a7);_0x2a02b7&&_0x4af5e0&&(_0x533bfa=insertGuidesSection(_0x533bfa,_0x2a02b7,_0xcc5a23),_0x533bfa=appendExtendContents(_0x533bfa,_0x2a02b7,_0xcc5a23));writeFileSync(_0x5c78eb,_0x533bfa,_0x1c0ca2(0x1ba));return;}if(_0x2a02b7&&_0x4af5e0)try{writeSkillFile(_0x2a02b7,_0x5c78eb,_0x3169a7,_0xcc5a23);return;}catch{}}writeFileSync(_0x5c78eb,'',_0x1c0ca2(0x1ba));}function a64_0x49f4(){const _0x47aed0=['SKILL.md.tpl','<!--\x20GUIDES_APPEND\x20-->','1759310bASxXu','length','files','folders','93645HDRNef','utf-8','|\x20`','some','\x0a<!--\x20GUIDES_APPEND\x20-->','test','indexOf','`\x20|\x20','200NPizhN','guides','replace','18qGEgpQ','237078STuDIN','requireFlags','1062658NaeJTP','130piEGRK','49nuMqNz','push','name','includes','1159976IMOeUh','startsWith','59061Midavf','11523534IOrZXw','path','keys','template'];a64_0x49f4=function(){return _0x47aed0;};return a64_0x49f4();}function insertGuidesSection(_0x2b5fda,_0x6d0d36,_0x33e698){const _0x35e9d2=a64_0x2972,_0x57af78=_0x35e9d2(0x1d5),_0x33b8ce=_0x2b5fda[_0x35e9d2(0x1bf)](_0x57af78);if(_0x33b8ce===-0x1)return _0x2b5fda;const _0x5efb77=[],_0x1c2957=Object[_0x35e9d2(0x1d2)](_0x6d0d36['guides'])['sort']();for(const _0x149133 of _0x1c2957){const _0x2d976a=_0x6d0d36[_0x35e9d2(0x1c2)][_0x149133];if(!_0x2d976a)continue;if(/^0[1-6]-/[_0x35e9d2(0x1be)](_0x149133))continue;if(_0x2d976a[_0x35e9d2(0x1c6)]&&_0x2d976a['requireFlags'][_0x35e9d2(0x1d7)]>0x0){const _0x33e4f0=_0x2d976a['requireFlags'][_0x35e9d2(0x1bc)](_0x5e19d4=>_0x33e698?.[_0x35e9d2(0x1cc)](_0x5e19d4));if(!_0x33e4f0)continue;}const _0x309ec0=_0x2d976a['path'][_0x35e9d2(0x1c3)](/^\.lovrabet\/skill\/\.shared\/guides\//,'');_0x5efb77[_0x35e9d2(0x1ca)](_0x35e9d2(0x1bb)+_0x309ec0+_0x35e9d2(0x1c0)+_0x2d976a['title']+'\x20|');}if(_0x5efb77[_0x35e9d2(0x1d7)]===0x0)return _0x2b5fda[_0x35e9d2(0x1c3)](_0x57af78,_0x35e9d2(0x1d5));const _0x24ad27=_0x5efb77['join']('\x0a');return _0x2b5fda['replace'](_0x57af78,_0x24ad27+_0x35e9d2(0x1bd));}
@@ -1 +1 @@
1
- (function(_0x514976,_0x110edd){const _0x57c16e=a65_0x53e3,_0x30922d=_0x514976();while(!![]){try{const _0x1e8472=parseInt(_0x57c16e(0xc1))/0x1*(parseInt(_0x57c16e(0xba))/0x2)+parseInt(_0x57c16e(0xb7))/0x3*(-parseInt(_0x57c16e(0xbb))/0x4)+-parseInt(_0x57c16e(0xb6))/0x5+parseInt(_0x57c16e(0xb5))/0x6+-parseInt(_0x57c16e(0xbf))/0x7+-parseInt(_0x57c16e(0xb3))/0x8+parseInt(_0x57c16e(0xb1))/0x9;if(_0x1e8472===_0x110edd)break;else _0x30922d['push'](_0x30922d['shift']());}catch(_0x57b116){_0x30922d['push'](_0x30922d['shift']());}}}(a65_0x565e,0x6835d));import{jsxs as a65_0xa5b623,jsx as a65_0x16bd7b}from'react/jsx-runtime';import{Text,Box}from'ink';export function IDESelector({ideList:_0x173d2a,title:_0x19c3bb,selection:_0x109d2d}){const _0x3cf3f1=a65_0x53e3,{selectedIndexes:_0x41a6a0,highlightIndex:_0x3cb772,errorMsg:_0xbf52a}=_0x109d2d;return a65_0xa5b623(Box,{'flexDirection':_0x3cf3f1(0xc2),'marginTop':0x1,'children':[a65_0x16bd7b(Box,{'children':a65_0xa5b623(Text,{'color':_0x3cf3f1(0xbc),'children':['*\x20',_0x19c3bb]})}),_0xbf52a&&a65_0x16bd7b(Box,{'marginTop':0x1,'children':a65_0xa5b623(Text,{'color':'red','children':['✗\x20',_0xbf52a]})}),a65_0xa5b623(Box,{'marginTop':0x1,'flexDirection':_0x3cf3f1(0xc2),'children':[a65_0x16bd7b(Text,{'bold':!![],'children':'*\x20请选择要配置的\x20IDE:'}),_0x173d2a[_0x3cf3f1(0xb2)]((_0x58c728,_0x1c2074)=>{const _0x355beb=_0x3cf3f1,_0x24425b=_0x3cb772===_0x1c2074,_0x23c76a=_0x41a6a0[_0x355beb(0xbe)](_0x1c2074);return a65_0x16bd7b(Box,{'children':a65_0xa5b623(Text,{'backgroundColor':_0x24425b?'blue':undefined,'color':_0x24425b?'white':undefined,'children':['\x20\x20',_0x23c76a?_0x355beb(0xb0):_0x355beb(0xb9),'\x20',_0x58c728[_0x355beb(0xc0)],'\x20',a65_0xa5b623(Text,{'color':_0x24425b?_0x355beb(0xb8):'gray','dimColor':!_0x24425b,'children':['-\x20',_0x58c728[_0x355beb(0xb4)]]})]})},_0x58c728['key']);}),a65_0x16bd7b(Box,{'marginTop':0x1,'children':a65_0xa5b623(Text,{'color':_0x3cf3f1(0xbd),'children':['\x20','↑/↓:\x20移动光标\x20空格:\x20切换选中\x20a:\x20全选\x20i/r:\x20反选\x20q:\x20退出\x20Enter:\x20确认']})})]})]});}export{useIDESelection}from'./useIDESelection.js';function a65_0x53e3(_0x14136d,_0x5a9c25){_0x14136d=_0x14136d-0xb0;const _0x565eb3=a65_0x565e();let _0x53e320=_0x565eb3[_0x14136d];return _0x53e320;}function a65_0x565e(){const _0x2003be=['1870145prlowV','1365PULCox','white','[\x20]','4QGtCWj','4932wCzhVv','cyan','gray','has','3511711RICuZn','name','386257XLihgD','column','[✓]','10408545tAjdvi','map','6338904qrlbcF','description','4361436aBsRAE'];a65_0x565e=function(){return _0x2003be;};return a65_0x565e();}
1
+ function a66_0x1c64(_0x37eda0,_0x254ba7){_0x37eda0=_0x37eda0-0x1dd;const _0xa85062=a66_0xa850();let _0x1c6461=_0xa85062[_0x37eda0];return _0x1c6461;}(function(_0x44e981,_0x2c9e26){const _0x56df2f=a66_0x1c64,_0x596c8c=_0x44e981();while(!![]){try{const _0x5d4726=parseInt(_0x56df2f(0x1de))/0x1*(-parseInt(_0x56df2f(0x1e6))/0x2)+-parseInt(_0x56df2f(0x1ec))/0x3+-parseInt(_0x56df2f(0x1e4))/0x4*(parseInt(_0x56df2f(0x1e1))/0x5)+parseInt(_0x56df2f(0x1ed))/0x6+-parseInt(_0x56df2f(0x1e9))/0x7+-parseInt(_0x56df2f(0x1e5))/0x8*(parseInt(_0x56df2f(0x1ea))/0x9)+parseInt(_0x56df2f(0x1df))/0xa;if(_0x5d4726===_0x2c9e26)break;else _0x596c8c['push'](_0x596c8c['shift']());}catch(_0xb72ef4){_0x596c8c['push'](_0x596c8c['shift']());}}}(a66_0xa850,0x5e2f2));import{jsxs as a66_0x3c3a3e,jsx as a66_0x4a7f9e}from'react/jsx-runtime';import{Text,Box}from'ink';export function IDESelector({ideList:_0x240ba5,title:_0x8d4682,selection:_0x44a0c7}){const _0x350df7=a66_0x1c64,{selectedIndexes:_0x4a5791,highlightIndex:_0x35d123,errorMsg:_0x167d77}=_0x44a0c7;return a66_0x3c3a3e(Box,{'flexDirection':'column','marginTop':0x1,'children':[a66_0x4a7f9e(Box,{'children':a66_0x3c3a3e(Text,{'color':_0x350df7(0x1dd),'children':['*\x20',_0x8d4682]})}),_0x167d77&&a66_0x4a7f9e(Box,{'marginTop':0x1,'children':a66_0x3c3a3e(Text,{'color':'red','children':['✗\x20',_0x167d77]})}),a66_0x3c3a3e(Box,{'marginTop':0x1,'flexDirection':_0x350df7(0x1e3),'children':[a66_0x4a7f9e(Text,{'bold':!![],'children':_0x350df7(0x1ef)}),_0x240ba5[_0x350df7(0x1e2)]((_0x55792d,_0x20dc40)=>{const _0x22d134=_0x350df7,_0x428b7e=_0x35d123===_0x20dc40,_0x4fe309=_0x4a5791['has'](_0x20dc40);return a66_0x4a7f9e(Box,{'children':a66_0x3c3a3e(Text,{'backgroundColor':_0x428b7e?'blue':undefined,'color':_0x428b7e?_0x22d134(0x1e8):undefined,'children':['\x20\x20',_0x4fe309?_0x22d134(0x1f0):_0x22d134(0x1ee),'\x20',_0x55792d[_0x22d134(0x1e7)],'\x20',a66_0x3c3a3e(Text,{'color':_0x428b7e?_0x22d134(0x1e8):'gray','dimColor':!_0x428b7e,'children':['-\x20',_0x55792d[_0x22d134(0x1eb)]]})]})},_0x55792d['key']);}),a66_0x4a7f9e(Box,{'marginTop':0x1,'children':a66_0x3c3a3e(Text,{'color':_0x350df7(0x1e0),'children':['\x20','↑/↓:\x20移动光标\x20空格:\x20切换选中\x20a:\x20全选\x20i/r:\x20反选\x20q:\x20退出\x20Enter:\x20确认']})})]})]});}export{useIDESelection}from'./useIDESelection.js';function a66_0xa850(){const _0x15b510=['cyan','1yxcOQC','19237580EStvOw','gray','5ImuUQA','map','column','2926468sjSAYf','819088GtJVIB','872128zwOruT','name','white','1213744SUlzDv','9nbGUSb','description','413874lLkjJn','260622qMZiBN','[\x20]','*\x20请选择要配置的\x20IDE:','[✓]'];a66_0xa850=function(){return _0x15b510;};return a66_0xa850();}
@@ -1 +1 @@
1
- (function(_0x2f287e,_0x1117a5){const _0x511add=a66_0x544c,_0x22d4e1=_0x2f287e();while(!![]){try{const _0x3d6540=parseInt(_0x511add(0x126))/0x1+parseInt(_0x511add(0x12d))/0x2+-parseInt(_0x511add(0x128))/0x3*(-parseInt(_0x511add(0x132))/0x4)+parseInt(_0x511add(0x122))/0x5*(parseInt(_0x511add(0x131))/0x6)+parseInt(_0x511add(0x12a))/0x7+-parseInt(_0x511add(0x11f))/0x8*(parseInt(_0x511add(0x12e))/0x9)+-parseInt(_0x511add(0x12f))/0xa;if(_0x3d6540===_0x1117a5)break;else _0x22d4e1['push'](_0x22d4e1['shift']());}catch(_0x35cfca){_0x22d4e1['push'](_0x22d4e1['shift']());}}}(a66_0x5a61,0x7c82b));import{useState,useCallback}from'react';function a66_0x5a61(){const _0x48e008=['map','5320086nJqvAk','8qhZZhB','key','8NEOeWp','size','length','5dKbEkx','findIndex','add','downArrow','145180AgAQaS','has','861195nZzEeS','from','5177725pDjBRJ','delete','filter','234540JUkgin','8302626aJfcGW','10304270jUdTKz'];a66_0x5a61=function(){return _0x48e008;};return a66_0x5a61();}function a66_0x544c(_0x350bc3,_0x14de01){_0x350bc3=_0x350bc3-0x11f;const _0x5a6191=a66_0x5a61();let _0x544cca=_0x5a6191[_0x350bc3];return _0x544cca;}export function useIDESelection({ideList:_0xe43d3c,preselectedIDEs:preselectedIDEs=[],multiSelect:multiSelect=!![]}){const _0x3e2309=a66_0x544c,[_0x184341,_0x3dc0f9]=useState(new Set(preselectedIDEs[_0x3e2309(0x130)](_0x1a6a04=>_0xe43d3c[_0x3e2309(0x123)](_0x165f73=>_0x165f73[_0x3e2309(0x133)]===_0x1a6a04))[_0x3e2309(0x12c)](_0xfbfa9=>_0xfbfa9>=0x0))),[_0x9949b0,_0x1dc980]=useState(0x0),[_0x562fb0,_0x7510df]=useState(''),_0x6a4bec=useCallback(()=>{const _0x3368de=_0x3e2309;_0x1dc980(_0x3a3af5=>_0x3a3af5>0x0?_0x3a3af5-0x1:_0xe43d3c[_0x3368de(0x121)]-0x1);},[_0xe43d3c[_0x3e2309(0x121)]]),_0x237ef6=useCallback(()=>{_0x1dc980(_0x128af1=>_0x128af1<_0xe43d3c['length']-0x1?_0x128af1+0x1:0x0);},[_0xe43d3c['length']]),_0x567721=useCallback(()=>{if(!multiSelect){_0x3dc0f9(new Set([_0x9949b0]));return;}_0x3dc0f9(_0x5d856d=>{const _0x4ed34d=a66_0x544c,_0x5e12da=new Set(_0x5d856d);return _0x5e12da[_0x4ed34d(0x127)](_0x9949b0)?_0x5e12da[_0x4ed34d(0x12b)](_0x9949b0):_0x5e12da[_0x4ed34d(0x124)](_0x9949b0),_0x5e12da;});},[_0x9949b0,multiSelect]),_0x7b0d7b=useCallback(()=>{const _0x4637a1=_0x3e2309;_0x3dc0f9(new Set(_0xe43d3c[_0x4637a1(0x130)]((_0x44070c,_0x58be04)=>_0x58be04)));},[_0xe43d3c]),_0x5a06c7=useCallback(()=>{_0x3dc0f9(_0x2d3bd6=>{const _0x57cfdb=a66_0x544c,_0x5797ce=new Set();for(let _0x28dff3=0x0;_0x28dff3<_0xe43d3c[_0x57cfdb(0x121)];_0x28dff3++){!_0x2d3bd6[_0x57cfdb(0x127)](_0x28dff3)&&_0x5797ce['add'](_0x28dff3);}return _0x5797ce;});},[_0xe43d3c]),_0x577404=useCallback(()=>{const _0x153199=_0x3e2309;return Array[_0x153199(0x129)](_0x184341)[_0x153199(0x130)](_0x73d418=>_0xe43d3c[_0x73d418]?.[_0x153199(0x133)])['filter'](_0x42c00c=>_0x42c00c!==undefined);},[_0x184341,_0xe43d3c]),_0x427c8f=useCallback(()=>{const _0x14c7eb=_0x3e2309;return _0x184341[_0x14c7eb(0x120)]===_0xe43d3c[_0x14c7eb(0x121)];},[_0x184341,_0xe43d3c]),_0x23f161=useCallback((_0x1eea0b,_0x185223)=>{const _0x57994d=_0x3e2309;if(_0x185223['upArrow'])return _0x6a4bec(),!![];if(_0x185223[_0x57994d(0x125)])return _0x237ef6(),!![];if(_0x1eea0b==='\x20')return _0x567721(),!![];if(_0x1eea0b==='a'||_0x1eea0b==='A')return _0x7b0d7b(),!![];if(_0x1eea0b==='i'||_0x1eea0b==='I'||_0x1eea0b==='r'||_0x1eea0b==='R')return _0x5a06c7(),!![];return![];},[_0x6a4bec,_0x237ef6,_0x567721,_0x7b0d7b,_0x5a06c7]);return{'selectedIndexes':_0x184341,'highlightIndex':_0x9949b0,'errorMsg':_0x562fb0,'setErrorMsg':_0x7510df,'handleKeyDown':_0x23f161,'getSelectedIDEs':_0x577404,'isAllSelected':_0x427c8f,'toggleSelection':_0x567721,'selectAll':_0x7b0d7b,'invertSelection':_0x5a06c7,'moveHighlightUp':_0x6a4bec,'moveHighlightDown':_0x237ef6};}
1
+ function a67_0xba10(_0x387b16,_0x429607){_0x387b16=_0x387b16-0x193;const _0x1715cd=a67_0x1715();let _0xba1076=_0x1715cd[_0x387b16];return _0xba1076;}(function(_0xfbd632,_0x9fd4f4){const _0x1828c2=a67_0xba10,_0x2be6e1=_0xfbd632();while(!![]){try{const _0x29ee4f=parseInt(_0x1828c2(0x19b))/0x1*(parseInt(_0x1828c2(0x1a3))/0x2)+-parseInt(_0x1828c2(0x19d))/0x3*(-parseInt(_0x1828c2(0x198))/0x4)+-parseInt(_0x1828c2(0x1a8))/0x5*(parseInt(_0x1828c2(0x194))/0x6)+-parseInt(_0x1828c2(0x193))/0x7+parseInt(_0x1828c2(0x19c))/0x8+-parseInt(_0x1828c2(0x19f))/0x9*(-parseInt(_0x1828c2(0x19e))/0xa)+parseInt(_0x1828c2(0x196))/0xb;if(_0x29ee4f===_0x9fd4f4)break;else _0x2be6e1['push'](_0x2be6e1['shift']());}catch(_0xde7ce5){_0x2be6e1['push'](_0x2be6e1['shift']());}}}(a67_0x1715,0xa7a22));import{useState,useCallback}from'react';function a67_0x1715(){const _0xb88913=['6bPppBW','length','17225648TsViwv','has','68seIjSX','key','findIndex','1ePPpRx','41776YTizFt','40731sLtVUW','70vrhOCf','450909ekeZFg','downArrow','add','map','939936JnTIEC','size','upArrow','filter','delete','6445895GjdUyq','4528083MZUAEE'];a67_0x1715=function(){return _0xb88913;};return a67_0x1715();}export function useIDESelection({ideList:_0x59eebb,preselectedIDEs:preselectedIDEs=[],multiSelect:multiSelect=!![]}){const _0x4abec4=a67_0xba10,[_0x24c700,_0x182efc]=useState(new Set(preselectedIDEs[_0x4abec4(0x1a2)](_0x465927=>_0x59eebb[_0x4abec4(0x19a)](_0x5540b8=>_0x5540b8[_0x4abec4(0x199)]===_0x465927))[_0x4abec4(0x1a6)](_0x564e3b=>_0x564e3b>=0x0))),[_0x2ba73d,_0x1cf912]=useState(0x0),[_0x4ec0cd,_0x21905b]=useState(''),_0xc7092=useCallback(()=>{_0x1cf912(_0x321f2f=>_0x321f2f>0x0?_0x321f2f-0x1:_0x59eebb['length']-0x1);},[_0x59eebb[_0x4abec4(0x195)]]),_0x3821c9=useCallback(()=>{const _0x2b446a=_0x4abec4;_0x1cf912(_0x5d3d94=>_0x5d3d94<_0x59eebb[_0x2b446a(0x195)]-0x1?_0x5d3d94+0x1:0x0);},[_0x59eebb['length']]),_0x4a1017=useCallback(()=>{if(!multiSelect){_0x182efc(new Set([_0x2ba73d]));return;}_0x182efc(_0x566b1c=>{const _0x2d7b2e=a67_0xba10,_0xaf4760=new Set(_0x566b1c);return _0xaf4760[_0x2d7b2e(0x197)](_0x2ba73d)?_0xaf4760[_0x2d7b2e(0x1a7)](_0x2ba73d):_0xaf4760[_0x2d7b2e(0x1a1)](_0x2ba73d),_0xaf4760;});},[_0x2ba73d,multiSelect]),_0x9f3dea=useCallback(()=>{const _0x8fc95e=_0x4abec4;_0x182efc(new Set(_0x59eebb[_0x8fc95e(0x1a2)]((_0x143979,_0x52ffb7)=>_0x52ffb7)));},[_0x59eebb]),_0x4eebeb=useCallback(()=>{_0x182efc(_0x38457d=>{const _0x302392=a67_0xba10,_0x25580c=new Set();for(let _0x45b799=0x0;_0x45b799<_0x59eebb[_0x302392(0x195)];_0x45b799++){!_0x38457d[_0x302392(0x197)](_0x45b799)&&_0x25580c[_0x302392(0x1a1)](_0x45b799);}return _0x25580c;});},[_0x59eebb]),_0x3f9582=useCallback(()=>{const _0x291e5f=_0x4abec4;return Array['from'](_0x24c700)[_0x291e5f(0x1a2)](_0x6cda8c=>_0x59eebb[_0x6cda8c]?.[_0x291e5f(0x199)])[_0x291e5f(0x1a6)](_0x552341=>_0x552341!==undefined);},[_0x24c700,_0x59eebb]),_0x491436=useCallback(()=>{const _0x3a9e70=_0x4abec4;return _0x24c700[_0x3a9e70(0x1a4)]===_0x59eebb[_0x3a9e70(0x195)];},[_0x24c700,_0x59eebb]),_0xbf506d=useCallback((_0x397111,_0x1e5c13)=>{const _0x3e3ebd=_0x4abec4;if(_0x1e5c13[_0x3e3ebd(0x1a5)])return _0xc7092(),!![];if(_0x1e5c13[_0x3e3ebd(0x1a0)])return _0x3821c9(),!![];if(_0x397111==='\x20')return _0x4a1017(),!![];if(_0x397111==='a'||_0x397111==='A')return _0x9f3dea(),!![];if(_0x397111==='i'||_0x397111==='I'||_0x397111==='r'||_0x397111==='R')return _0x4eebeb(),!![];return![];},[_0xc7092,_0x3821c9,_0x4a1017,_0x9f3dea,_0x4eebeb]);return{'selectedIndexes':_0x24c700,'highlightIndex':_0x2ba73d,'errorMsg':_0x4ec0cd,'setErrorMsg':_0x21905b,'handleKeyDown':_0xbf506d,'getSelectedIDEs':_0x3f9582,'isAllSelected':_0x491436,'toggleSelection':_0x4a1017,'selectAll':_0x9f3dea,'invertSelection':_0x4eebeb,'moveHighlightUp':_0xc7092,'moveHighlightDown':_0x3821c9};}
@@ -1 +1 @@
1
- const a67_0x2156a2=a67_0x1260;(function(_0x31fa09,_0x57dea9){const _0x5535ec=a67_0x1260,_0x5e0eea=_0x31fa09();while(!![]){try{const _0x415c5d=-parseInt(_0x5535ec(0x1c5))/0x1+-parseInt(_0x5535ec(0x1a2))/0x2*(-parseInt(_0x5535ec(0x19e))/0x3)+parseInt(_0x5535ec(0x1b8))/0x4+-parseInt(_0x5535ec(0x1a3))/0x5+parseInt(_0x5535ec(0x1a4))/0x6+-parseInt(_0x5535ec(0x1d1))/0x7+parseInt(_0x5535ec(0x1c9))/0x8*(parseInt(_0x5535ec(0x1ba))/0x9);if(_0x415c5d===_0x57dea9)break;else _0x5e0eea['push'](_0x5e0eea['shift']());}catch(_0x1d5324){_0x5e0eea['push'](_0x5e0eea['shift']());}}}(a67_0xf002,0x2269e));export const CORE_IDE_CONFIGS={'cursor':{'name':'Cursor','description':a67_0x2156a2(0x1b5),'folders':[a67_0x2156a2(0x1bc),a67_0x2156a2(0x1cb)],'files':[{'type':a67_0x2156a2(0x1d0),'path':a67_0x2156a2(0x1cd),'template':'SKILL.md.tpl'}]},'windsurf':{'name':a67_0x2156a2(0x1bb),'description':'Windsurf\x20IDE','folders':[a67_0x2156a2(0x1b0)],'files':[{'type':a67_0x2156a2(0x1d0),'path':a67_0x2156a2(0x1a5),'template':a67_0x2156a2(0x1a0)}]},'claude':{'name':'Claude\x20Code','description':'Claude\x20Code','folders':['.claude'],'files':[{'type':'file','path':a67_0x2156a2(0x1b3),'template':'SKILL.md.tpl'}]},'cline':{'name':a67_0x2156a2(0x1c0),'description':a67_0x2156a2(0x1b7),'folders':[a67_0x2156a2(0x1ca)],'files':[{'type':'file','path':a67_0x2156a2(0x1cc),'template':a67_0x2156a2(0x1a0)}]},'codex':{'name':a67_0x2156a2(0x19f),'description':'Codex\x20IDE','folders':['.codex'],'files':[{'type':a67_0x2156a2(0x1d0),'path':a67_0x2156a2(0x1d3),'template':a67_0x2156a2(0x1a0)}]},'opencode':{'name':a67_0x2156a2(0x1a9),'description':'OpenCode\x20IDE','folders':['.opencode'],'files':[{'type':a67_0x2156a2(0x1d0),'path':a67_0x2156a2(0x1c6),'template':a67_0x2156a2(0x1a0)}]},'qoder':{'name':a67_0x2156a2(0x1c1),'description':a67_0x2156a2(0x1a8),'folders':[a67_0x2156a2(0x1cf)],'files':[{'type':a67_0x2156a2(0x1d0),'path':a67_0x2156a2(0x1af),'template':a67_0x2156a2(0x1a0)},{'type':'file','path':a67_0x2156a2(0x1c7),'template':a67_0x2156a2(0x1a0)}]},'codebuddy':{'name':'CodeBuddy','description':'CodeBuddy\x20IDE','folders':[a67_0x2156a2(0x1be)],'files':[{'type':'file','path':a67_0x2156a2(0x1a1),'template':'SKILL.md.tpl'}]},'trae':{'name':a67_0x2156a2(0x1ce),'description':a67_0x2156a2(0x1c3),'folders':[a67_0x2156a2(0x1bd)],'files':[{'type':'file','path':a67_0x2156a2(0x1b1),'template':a67_0x2156a2(0x1a0)}]}};export const IDE_CONFIGS={...CORE_IDE_CONFIGS,'agent':{'name':a67_0x2156a2(0x1c2),'description':a67_0x2156a2(0x1c4),'folders':[a67_0x2156a2(0x1ab)],'files':[{'type':a67_0x2156a2(0x1d0),'path':a67_0x2156a2(0x1b4),'template':a67_0x2156a2(0x1a0)}]},'antigravity':{'name':'Antigravity','description':a67_0x2156a2(0x1ad),'folders':[a67_0x2156a2(0x1ab)],'files':[{'type':a67_0x2156a2(0x1d0),'path':a67_0x2156a2(0x1b4),'template':a67_0x2156a2(0x1a0)}]}};export const CORE_IDE_LIST=['claude',a67_0x2156a2(0x1aa),a67_0x2156a2(0x1d2),'codex',a67_0x2156a2(0x1a6),a67_0x2156a2(0x1c8),a67_0x2156a2(0x1ae),a67_0x2156a2(0x1b6),'windsurf'];function a67_0x1260(_0x32f40e,_0x466cde){_0x32f40e=_0x32f40e-0x19e;const _0xf0025=a67_0xf002();let _0x126060=_0xf0025[_0x32f40e];return _0x126060;}function a67_0xf002(){const _0x3a481a=['SKILL.md.tpl','.codebuddy/skills/lovrabet/SKILL.md','62418LLlPYU','486780CgUVak','19800RBEmFx','.windsurf/workflows/lovrabet.md','cursor','antigravity','Qoder\x20IDE','OpenCode','cline','.agent','claude','Antigravity\x20IDE','qoder','.qoder/rules/lovrabet.md','.windsurf','.trae/skills/lovrabet/SKILL.md','codex','.claude/skills/lovrabet/SKILL.md','.agent/skills/lovrabet/SKILL.md','Cursor\x20IDE','trae','Cline\x20IDE','787624KHtDWW','windsurf','741249cYWKOc','Windsurf','.cursorrules','.trae','.codebuddy','agent','Cline','Qoder','其他\x20(通用模板)','Trae\x20IDE','通用模板\x20-\x20兜底方案','141991PAbOJw','.opencode/skills/lovrabet/SKILL.md','.qoder/skills/lovrabet/SKILL.md','opencode','8BjzuaB','.cline','.cursor','.cline/skills/lovrabet/SKILL.md','.cursor/skills/lovrabet.md','Trae','.qoder','file','189686KMBfZs','codebuddy','.codex/skills/lovrabet/SKILL.md','12cwpLJb','Codex'];a67_0xf002=function(){return _0x3a481a;};return a67_0xf002();}export const IDE_LIST=[a67_0x2156a2(0x1a7),'claude',a67_0x2156a2(0x1aa),'codebuddy',a67_0x2156a2(0x1b2),a67_0x2156a2(0x1a6),'opencode',a67_0x2156a2(0x1ae),a67_0x2156a2(0x1b6),a67_0x2156a2(0x1b9),a67_0x2156a2(0x1bf)];export const ALL_CORE_IDES=[a67_0x2156a2(0x1a6),a67_0x2156a2(0x1b9),a67_0x2156a2(0x1ac),a67_0x2156a2(0x1aa),a67_0x2156a2(0x1b2),a67_0x2156a2(0x1c8),a67_0x2156a2(0x1ae),'codebuddy',a67_0x2156a2(0x1b6)];export const MCP_IDES=new Set([a67_0x2156a2(0x1a6),'claude']);
1
+ const a68_0x3eaae0=a68_0xa63d;function a68_0x1fd8(){const _0x4fe492=['.codex/skills/lovrabet/SKILL.md','file','1264296XWQAgf','SKILL.md.tpl','windsurf','.trae/skills/lovrabet/SKILL.md','.cline','.qoder/skills/lovrabet/SKILL.md','.cursor','Codex','.codex','Cline','38Tamzfp','.claude','cursor','4985323LOAOEq','97989ztRQsX','772068ctWyCG','Claude\x20Code','Cline\x20IDE','其他\x20(通用模板)','Qoder','.trae','.agent','.cursor/skills/lovrabet.md','.cline/skills/lovrabet/SKILL.md','通用模板\x20-\x20兜底方案','trae','Trae\x20IDE','CodeBuddy','claude','.cursorrules','441861uENXPr','Qoder\x20IDE','.agent/skills/lovrabet/SKILL.md','CodeBuddy\x20IDE','4455070cGKAMV','opencode','27FDlMbD','qoder','.opencode/skills/lovrabet/SKILL.md','cline','.windsurf','.qoder/rules/lovrabet.md','3758862pQKtow','OpenCode','codebuddy','agent','.qoder','codex','antigravity','Trae','.codebuddy/skills/lovrabet/SKILL.md'];a68_0x1fd8=function(){return _0x4fe492;};return a68_0x1fd8();}(function(_0x445924,_0x31a89e){const _0x342e20=a68_0xa63d,_0x5b5bc7=_0x445924();while(!![]){try{const _0x328b7e=parseInt(_0x342e20(0x199))/0x1+parseInt(_0x342e20(0x185))/0x2*(-parseInt(_0x342e20(0x189))/0x3)+parseInt(_0x342e20(0x18a))/0x4+parseInt(_0x342e20(0x19d))/0x5+-parseInt(_0x342e20(0x170))/0x6+parseInt(_0x342e20(0x188))/0x7+-parseInt(_0x342e20(0x17b))/0x8*(parseInt(_0x342e20(0x16a))/0x9);if(_0x328b7e===_0x31a89e)break;else _0x5b5bc7['push'](_0x5b5bc7['shift']());}catch(_0x31b520){_0x5b5bc7['push'](_0x5b5bc7['shift']());}}}(a68_0x1fd8,0x7e320));export const CORE_IDE_CONFIGS={'cursor':{'name':'Cursor','description':'Cursor\x20IDE','folders':[a68_0x3eaae0(0x198),a68_0x3eaae0(0x181)],'files':[{'type':'file','path':a68_0x3eaae0(0x191),'template':'SKILL.md.tpl'}]},'windsurf':{'name':'Windsurf','description':'Windsurf\x20IDE','folders':[a68_0x3eaae0(0x16e)],'files':[{'type':'file','path':'.windsurf/workflows/lovrabet.md','template':a68_0x3eaae0(0x17c)}]},'claude':{'name':a68_0x3eaae0(0x18b),'description':a68_0x3eaae0(0x18b),'folders':[a68_0x3eaae0(0x186)],'files':[{'type':'file','path':'.claude/skills/lovrabet/SKILL.md','template':a68_0x3eaae0(0x17c)}]},'cline':{'name':a68_0x3eaae0(0x184),'description':a68_0x3eaae0(0x18c),'folders':[a68_0x3eaae0(0x17f)],'files':[{'type':a68_0x3eaae0(0x17a),'path':a68_0x3eaae0(0x192),'template':a68_0x3eaae0(0x17c)}]},'codex':{'name':a68_0x3eaae0(0x182),'description':'Codex\x20IDE','folders':[a68_0x3eaae0(0x183)],'files':[{'type':a68_0x3eaae0(0x17a),'path':a68_0x3eaae0(0x179),'template':'SKILL.md.tpl'}]},'opencode':{'name':a68_0x3eaae0(0x171),'description':'OpenCode\x20IDE','folders':['.opencode'],'files':[{'type':'file','path':a68_0x3eaae0(0x16c),'template':a68_0x3eaae0(0x17c)}]},'qoder':{'name':a68_0x3eaae0(0x18e),'description':a68_0x3eaae0(0x19a),'folders':[a68_0x3eaae0(0x174)],'files':[{'type':a68_0x3eaae0(0x17a),'path':a68_0x3eaae0(0x16f),'template':a68_0x3eaae0(0x17c)},{'type':a68_0x3eaae0(0x17a),'path':a68_0x3eaae0(0x180),'template':a68_0x3eaae0(0x17c)}]},'codebuddy':{'name':a68_0x3eaae0(0x196),'description':a68_0x3eaae0(0x19c),'folders':['.codebuddy'],'files':[{'type':a68_0x3eaae0(0x17a),'path':a68_0x3eaae0(0x178),'template':a68_0x3eaae0(0x17c)}]},'trae':{'name':a68_0x3eaae0(0x177),'description':a68_0x3eaae0(0x195),'folders':[a68_0x3eaae0(0x18f)],'files':[{'type':a68_0x3eaae0(0x17a),'path':a68_0x3eaae0(0x17e),'template':a68_0x3eaae0(0x17c)}]}};function a68_0xa63d(_0x3447b2,_0x7194b5){_0x3447b2=_0x3447b2-0x169;const _0x1fd840=a68_0x1fd8();let _0xa63d74=_0x1fd840[_0x3447b2];return _0xa63d74;}export const IDE_CONFIGS={...CORE_IDE_CONFIGS,'agent':{'name':a68_0x3eaae0(0x18d),'description':a68_0x3eaae0(0x193),'folders':[a68_0x3eaae0(0x190)],'files':[{'type':'file','path':'.agent/skills/lovrabet/SKILL.md','template':a68_0x3eaae0(0x17c)}]},'antigravity':{'name':'Antigravity','description':'Antigravity\x20IDE','folders':['.agent'],'files':[{'type':a68_0x3eaae0(0x17a),'path':a68_0x3eaae0(0x19b),'template':a68_0x3eaae0(0x17c)}]}};export const CORE_IDE_LIST=['claude','cline',a68_0x3eaae0(0x172),a68_0x3eaae0(0x175),a68_0x3eaae0(0x187),a68_0x3eaae0(0x169),a68_0x3eaae0(0x16b),a68_0x3eaae0(0x194),a68_0x3eaae0(0x17d)];export const IDE_LIST=[a68_0x3eaae0(0x176),a68_0x3eaae0(0x197),'cline','codebuddy',a68_0x3eaae0(0x175),a68_0x3eaae0(0x187),a68_0x3eaae0(0x169),'qoder','trae',a68_0x3eaae0(0x17d),a68_0x3eaae0(0x173)];export const ALL_CORE_IDES=[a68_0x3eaae0(0x187),a68_0x3eaae0(0x17d),a68_0x3eaae0(0x197),a68_0x3eaae0(0x16d),a68_0x3eaae0(0x175),'opencode','qoder',a68_0x3eaae0(0x172),a68_0x3eaae0(0x194)];export const MCP_IDES=new Set(['cursor','claude']);
@@ -1 +1 @@
1
- (function(_0x22e329,_0x170a5d){const _0x45f0bd=a68_0x5d31,_0x24d24b=_0x22e329();while(!![]){try{const _0x24af85=-parseInt(_0x45f0bd(0x19c))/0x1+parseInt(_0x45f0bd(0x19d))/0x2+parseInt(_0x45f0bd(0x198))/0x3*(parseInt(_0x45f0bd(0x19b))/0x4)+parseInt(_0x45f0bd(0x1a1))/0x5*(-parseInt(_0x45f0bd(0x196))/0x6)+parseInt(_0x45f0bd(0x194))/0x7+parseInt(_0x45f0bd(0x191))/0x8*(parseInt(_0x45f0bd(0x1a0))/0x9)+-parseInt(_0x45f0bd(0x19e))/0xa*(parseInt(_0x45f0bd(0x195))/0xb);if(_0x24af85===_0x170a5d)break;else _0x24d24b['push'](_0x24d24b['shift']());}catch(_0x3aa641){_0x24d24b['push'](_0x24d24b['shift']());}}}(a68_0x1963,0xdefa2));import{getTemplateBaseUrl}from'./config.js';function a68_0x1963(){const _0x48aa4c=['node','stableVersion','2605076EUHtnd','1719808mvXQiu','1939288RDWKNy','677830RpVwMm','/config.json','9NhQBGi','19535WdZwii','now','cli','10010744effwUi','application/json','json','4345432QQYJtB','66vdkrEq','696BIvONi','sdk','3jgYPeA'];a68_0x1963=function(){return _0x48aa4c;};return a68_0x1963();}export async function fetchCdnConfig(){const _0x26a5a2=a68_0x5d31;try{const _0x5d91f7=getTemplateBaseUrl(),_0x2db3db=_0x5d91f7+_0x26a5a2(0x19f),_0x278862=await fetch(_0x2db3db,{'headers':{'Accept':_0x26a5a2(0x192)}});if(!_0x278862['ok'])return null;const _0x919a92=await _0x278862[_0x26a5a2(0x193)]();if(!_0x919a92[_0x26a5a2(0x190)]?.[_0x26a5a2(0x19a)]||!_0x919a92[_0x26a5a2(0x197)]?.[_0x26a5a2(0x199)]?.[_0x26a5a2(0x19a)])return null;return _0x919a92;}catch{return null;}}let cachedConfig=null,cacheTime=0x0;function a68_0x5d31(_0x28dc06,_0x11265d){_0x28dc06=_0x28dc06-0x18f;const _0x196396=a68_0x1963();let _0x5d3176=_0x196396[_0x28dc06];return _0x5d3176;}const CACHE_TTL=0x5*0x3c*0x3e8;export async function getCdnConfig(){const _0x327df1=a68_0x5d31,_0xebad37=Date[_0x327df1(0x18f)]();if(cachedConfig&&_0xebad37-cacheTime<CACHE_TTL)return cachedConfig;const _0x3ef31f=await fetchCdnConfig();return _0x3ef31f&&(cachedConfig=_0x3ef31f,cacheTime=_0xebad37),_0x3ef31f;}export function clearCdnConfigCache(){cachedConfig=null,cacheTime=0x0;}
1
+ (function(_0x1b9b62,_0x172574){const _0x242432=a69_0x5c91,_0x19f9a3=_0x1b9b62();while(!![]){try{const _0x430de8=parseInt(_0x242432(0x1f4))/0x1+-parseInt(_0x242432(0x1f0))/0x2+-parseInt(_0x242432(0x1fd))/0x3*(parseInt(_0x242432(0x1f1))/0x4)+-parseInt(_0x242432(0x1f8))/0x5+parseInt(_0x242432(0x1fa))/0x6*(parseInt(_0x242432(0x1f5))/0x7)+parseInt(_0x242432(0x1f6))/0x8+parseInt(_0x242432(0x1fb))/0x9;if(_0x430de8===_0x172574)break;else _0x19f9a3['push'](_0x19f9a3['shift']());}catch(_0xafbe6d){_0x19f9a3['push'](_0x19f9a3['shift']());}}}(a69_0xef8a,0x2b54d));import{getTemplateBaseUrl}from'./config.js';export async function fetchCdnConfig(){const _0x5a3854=a69_0x5c91;try{const _0x2b68ea=getTemplateBaseUrl(),_0x3168d1=_0x2b68ea+_0x5a3854(0x1fc),_0x21a7d9=await fetch(_0x3168d1,{'headers':{'Accept':'application/json'}});if(!_0x21a7d9['ok'])return null;const _0x47d848=await _0x21a7d9[_0x5a3854(0x1f7)]();if(!_0x47d848[_0x5a3854(0x1fe)]?.[_0x5a3854(0x1f9)]||!_0x47d848['sdk']?.[_0x5a3854(0x1f3)]?.['stableVersion'])return null;return _0x47d848;}catch{return null;}}let cachedConfig=null,cacheTime=0x0;function a69_0xef8a(){const _0x46d626=['105541yFmCZR','830431UxWibS','799800KdyyzA','json','1625925RnmIgj','stableVersion','12tAWlPV','4005954pUncSp','/config.json','866325BIyHAX','cli','192886NSeQWI','4BCYiNF','now','node'];a69_0xef8a=function(){return _0x46d626;};return a69_0xef8a();}function a69_0x5c91(_0x19615d,_0x5acbae){_0x19615d=_0x19615d-0x1f0;const _0xef8a19=a69_0xef8a();let _0x5c91c2=_0xef8a19[_0x19615d];return _0x5c91c2;}const CACHE_TTL=0x5*0x3c*0x3e8;export async function getCdnConfig(){const _0x3742ab=a69_0x5c91,_0x33af06=Date[_0x3742ab(0x1f2)]();if(cachedConfig&&_0x33af06-cacheTime<CACHE_TTL)return cachedConfig;const _0x518fa4=await fetchCdnConfig();return _0x518fa4&&(cachedConfig=_0x518fa4,cacheTime=_0x33af06),_0x518fa4;}export function clearCdnConfigCache(){cachedConfig=null,cacheTime=0x0;}
@@ -1 +1 @@
1
- (function(_0x139dd8,_0x366f15){const _0x1ffb98=a69_0x491b,_0x529f45=_0x139dd8();while(!![]){try{const _0xb83ddc=-parseInt(_0x1ffb98(0x113))/0x1+parseInt(_0x1ffb98(0x12e))/0x2*(-parseInt(_0x1ffb98(0x121))/0x3)+-parseInt(_0x1ffb98(0x11e))/0x4+-parseInt(_0x1ffb98(0x124))/0x5+parseInt(_0x1ffb98(0x11d))/0x6+parseInt(_0x1ffb98(0x11f))/0x7*(-parseInt(_0x1ffb98(0x123))/0x8)+parseInt(_0x1ffb98(0x128))/0x9;if(_0xb83ddc===_0x366f15)break;else _0x529f45['push'](_0x529f45['shift']());}catch(_0x5986f4){_0x529f45['push'](_0x529f45['shift']());}}}(a69_0x1863,0x6ba34));import a69_0x5d3b8f from'node:fs';import a69_0x50b0bf from'node:path';import a69_0x4692ea from'semver';import{getCdnConfig}from'./cdn-config.js';const FALLBACK_MIN_SDK_VERSION='1.2.0';function isNonNumericVersion(_0x53372c){const _0xa1b825=a69_0x491b,_0x1cdfb0=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x1cdfb0[_0xa1b825(0x114)](_0x5662d0=>_0x5662d0['test'](_0x53372c));}function a69_0x491b(_0x5f1c06,_0x40d8eb){_0x5f1c06=_0x5f1c06-0x10b;const _0x1863d6=a69_0x1863();let _0x491b15=_0x1863d6[_0x5f1c06];return _0x491b15;}function getInstalledVersion(_0x20e0d1,_0x447e43){const _0x2b0fac=a69_0x491b;try{const _0x53599f=a69_0x50b0bf[_0x2b0fac(0x117)](_0x20e0d1,_0x2b0fac(0x116),_0x447e43,_0x2b0fac(0x110));if(a69_0x5d3b8f[_0x2b0fac(0x122)](_0x53599f)){const _0x259a04=JSON['parse'](a69_0x5d3b8f[_0x2b0fac(0x10e)](_0x53599f,'utf-8'));return _0x259a04[_0x2b0fac(0x126)]||null;}}catch{}return null;}function a69_0x1863(){const _0x170088=['1428126IffTMZ','1918972mBUGvT','14hMnxDO','log','63183TcUkiV','existsSync','1397072NiWaaP','473775diIAut','minVersion','version','node','15509214btDcpD','sdk','latest','coerce','\x1b[1m','all','38GCKfDk','↪\x20SDK\x20版本更新','dependencies','parse','readFileSync','stableVersion','package.json','\x20\x20\x20稳定版本:\x20','devDependencies','196458DURtPm','some','@lovrabet/sdk','node_modules','join','utf8','needsUpgrade','packageName','\x20\x20\x20当前版本:\x20','\x1b[0m'];a69_0x1863=function(){return _0x170088;};return a69_0x1863();}async function getSdkStableVersion(){const _0x1f3572=a69_0x491b;try{const _0x590c30=await getCdnConfig();return _0x590c30?.[_0x1f3572(0x129)]?.['node']?.[_0x1f3572(0x10f)]||null;}catch{return null;}}async function getSdkPackageName(){const _0x677c9e=a69_0x491b;try{const _0x4bd33a=await getCdnConfig();return _0x4bd33a?.[_0x677c9e(0x129)]?.[_0x677c9e(0x127)]?.[_0x677c9e(0x11a)]||_0x677c9e(0x115);}catch{return _0x677c9e(0x115);}}export async function checkSdkVersion(_0x37e015){const _0x2325be=a69_0x491b,_0x25c198=a69_0x50b0bf[_0x2325be(0x117)](_0x37e015,_0x2325be(0x110)),[_0x5173b5,_0x5a211d]=await Promise[_0x2325be(0x12d)]([getSdkStableVersion(),getSdkPackageName()]),_0x4fa492=_0x5173b5||FALLBACK_MIN_SDK_VERSION;if(!a69_0x5d3b8f[_0x2325be(0x122)](_0x25c198))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x4fa492,'packageName':_0x5a211d,'stableVersion':_0x5173b5};try{const _0x272403=JSON[_0x2325be(0x10d)](a69_0x5d3b8f[_0x2325be(0x10e)](_0x25c198,'utf8')),_0x437e49=_0x272403[_0x2325be(0x10c)]||{},_0x15c64b=_0x272403[_0x2325be(0x112)]||{},_0x464abb=_0x437e49[_0x5a211d]||_0x15c64b[_0x5a211d];if(!_0x464abb)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x4fa492,'packageName':_0x5a211d,'stableVersion':_0x5173b5};let _0x889c0c=getInstalledVersion(_0x37e015,_0x5a211d);!_0x889c0c&&(_0x889c0c=_0x464abb);if(isNonNumericVersion(_0x464abb))return{'installed':!![],'version':_0x889c0c,'needsUpgrade':![],'minVersion':_0x4fa492,'packageName':_0x5a211d,'stableVersion':_0x5173b5};const _0xca09c5=a69_0x4692ea[_0x2325be(0x12b)](_0x889c0c),_0x46a4e1=a69_0x4692ea[_0x2325be(0x12b)](_0x4fa492),_0x39dc97=_0xca09c5&&_0x46a4e1?a69_0x4692ea['lt'](_0xca09c5,_0x46a4e1):![];return{'installed':!![],'version':_0x889c0c,'needsUpgrade':_0x39dc97,'minVersion':_0x4fa492,'packageName':_0x5a211d,'stableVersion':_0x5173b5};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x4fa492,'packageName':_0x5a211d,'stableVersion':_0x5173b5};}}export function checkSdkVersionSync(_0x3ab1cf){const _0x3581f5=a69_0x491b,_0x498155=a69_0x50b0bf['join'](_0x3ab1cf,'package.json'),_0x2872f3=_0x3581f5(0x115);if(!a69_0x5d3b8f[_0x3581f5(0x122)](_0x498155))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2872f3,'stableVersion':null};try{const _0x62b2f5=JSON[_0x3581f5(0x10d)](a69_0x5d3b8f[_0x3581f5(0x10e)](_0x498155,_0x3581f5(0x118))),_0x362d19=_0x62b2f5[_0x3581f5(0x10c)]||{},_0x5892a2=_0x62b2f5[_0x3581f5(0x112)]||{},_0x6e6849=_0x362d19[_0x2872f3]||_0x5892a2[_0x2872f3];if(!_0x6e6849)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2872f3,'stableVersion':null};let _0x5dbe3b=getInstalledVersion(_0x3ab1cf,_0x2872f3);!_0x5dbe3b&&(_0x5dbe3b=_0x6e6849);if(isNonNumericVersion(_0x6e6849))return{'installed':!![],'version':_0x5dbe3b,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2872f3,'stableVersion':null};const _0xdfb5b0=a69_0x4692ea[_0x3581f5(0x12b)](_0x5dbe3b),_0x52c7a6=_0xdfb5b0?a69_0x4692ea['lt'](_0xdfb5b0,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0x5dbe3b,'needsUpgrade':_0x52c7a6,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2872f3,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x2872f3,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x5ec0bc){const _0x30a8de=a69_0x491b;if(!_0x5ec0bc[_0x30a8de(0x119)])return;const _0x212c26='\x1b[33m',_0x23c78b=_0x30a8de(0x11c),_0x3f4672=_0x30a8de(0x12c),_0x1159b8=_0x5ec0bc[_0x30a8de(0x11a)]||_0x30a8de(0x115);console[_0x30a8de(0x120)](),console['log'](''+_0x212c26+_0x3f4672+_0x30a8de(0x10b)+_0x23c78b),console[_0x30a8de(0x120)](_0x212c26+_0x30a8de(0x11b)+_0x1159b8+'@'+_0x5ec0bc['version']+_0x23c78b),console[_0x30a8de(0x120)](_0x212c26+_0x30a8de(0x111)+(_0x5ec0bc['stableVersion']||_0x5ec0bc[_0x30a8de(0x125)])+_0x23c78b),console[_0x30a8de(0x120)](_0x212c26+'\x20\x20\x20升级命令:\x20npm\x20install\x20'+_0x1159b8+'@'+(_0x5ec0bc['stableVersion']||_0x30a8de(0x12a))+_0x23c78b),console['log']();}
1
+ const a70_0x2553d1=a70_0x1071;(function(_0x303c04,_0x445a1d){const _0x3f0575=a70_0x1071,_0x431396=_0x303c04();while(!![]){try{const _0x21b984=-parseInt(_0x3f0575(0xbd))/0x1*(-parseInt(_0x3f0575(0xaf))/0x2)+-parseInt(_0x3f0575(0xa3))/0x3+parseInt(_0x3f0575(0xb4))/0x4+parseInt(_0x3f0575(0xa5))/0x5*(-parseInt(_0x3f0575(0xa2))/0x6)+-parseInt(_0x3f0575(0x99))/0x7*(parseInt(_0x3f0575(0xb1))/0x8)+-parseInt(_0x3f0575(0xb8))/0x9+parseInt(_0x3f0575(0xa0))/0xa*(parseInt(_0x3f0575(0xb5))/0xb);if(_0x21b984===_0x445a1d)break;else _0x431396['push'](_0x431396['shift']());}catch(_0x39f554){_0x431396['push'](_0x431396['shift']());}}}(a70_0x26f2,0x5ce35));import a70_0x1c2639 from'node:fs';import a70_0x29a409 from'node:path';import a70_0x51aaa4 from'semver';import{getCdnConfig}from'./cdn-config.js';const FALLBACK_MIN_SDK_VERSION=a70_0x2553d1(0xb6);function isNonNumericVersion(_0x41a150){const _0x2d3fbc=a70_0x2553d1,_0x5f07d1=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x5f07d1[_0x2d3fbc(0x9b)](_0x5865e6=>_0x5865e6[_0x2d3fbc(0xb7)](_0x41a150));}function getInstalledVersion(_0x80268f,_0x3e0a14){const _0x1df987=a70_0x2553d1;try{const _0x2fc537=a70_0x29a409[_0x1df987(0xaa)](_0x80268f,_0x1df987(0xa4),_0x3e0a14,'package.json');if(a70_0x1c2639[_0x1df987(0xb9)](_0x2fc537)){const _0x45e396=JSON['parse'](a70_0x1c2639['readFileSync'](_0x2fc537,_0x1df987(0x9c)));return _0x45e396[_0x1df987(0x9e)]||null;}}catch{}return null;}function a70_0x1071(_0x32e5e5,_0x5a3631){_0x32e5e5=_0x32e5e5-0x97;const _0x26f295=a70_0x26f2();let _0x107181=_0x26f295[_0x32e5e5];return _0x107181;}async function getSdkStableVersion(){const _0x43625b=a70_0x2553d1;try{const _0x2ba4c3=await getCdnConfig();return _0x2ba4c3?.[_0x43625b(0x97)]?.['node']?.['stableVersion']||null;}catch{return null;}}async function getSdkPackageName(){const _0x2daf2a=a70_0x2553d1;try{const _0x23446c=await getCdnConfig();return _0x23446c?.['sdk']?.[_0x2daf2a(0xa8)]?.[_0x2daf2a(0xad)]||_0x2daf2a(0xbc);}catch{return'@lovrabet/sdk';}}function a70_0x26f2(){const _0x43ee14=['10ifnQyb','↪\x20SDK\x20版本更新','1375086mMQfPW','1293261HkEDiX','node_modules','15lIyEPD','devDependencies','minVersion','node','\x20\x20\x20当前版本:\x20','join','\x20\x20\x20升级命令:\x20npm\x20install\x20','all','packageName','readFileSync','151860YyKNYN','log','8cAzPOZ','package.json','stableVersion','724268KsmRey','16784845obVaBj','1.2.0','test','6268914KqFpyW','existsSync','coerce','needsUpgrade','@lovrabet/sdk','10dKdPJC','parse','sdk','utf8','1894319TeUFvA','dependencies','some','utf-8','latest','version','\x1b[1m'];a70_0x26f2=function(){return _0x43ee14;};return a70_0x26f2();}export async function checkSdkVersion(_0x2be51f){const _0x26a725=a70_0x2553d1,_0x51059f=a70_0x29a409[_0x26a725(0xaa)](_0x2be51f,'package.json'),[_0x5b908c,_0x4c93b7]=await Promise[_0x26a725(0xac)]([getSdkStableVersion(),getSdkPackageName()]),_0x27c69f=_0x5b908c||FALLBACK_MIN_SDK_VERSION;if(!a70_0x1c2639[_0x26a725(0xb9)](_0x51059f))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x27c69f,'packageName':_0x4c93b7,'stableVersion':_0x5b908c};try{const _0x4adcd2=JSON['parse'](a70_0x1c2639[_0x26a725(0xae)](_0x51059f,'utf8')),_0x3b5876=_0x4adcd2[_0x26a725(0x9a)]||{},_0xdc7ef3=_0x4adcd2[_0x26a725(0xa6)]||{},_0x5bfc5c=_0x3b5876[_0x4c93b7]||_0xdc7ef3[_0x4c93b7];if(!_0x5bfc5c)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x27c69f,'packageName':_0x4c93b7,'stableVersion':_0x5b908c};let _0x4625f6=getInstalledVersion(_0x2be51f,_0x4c93b7);!_0x4625f6&&(_0x4625f6=_0x5bfc5c);if(isNonNumericVersion(_0x5bfc5c))return{'installed':!![],'version':_0x4625f6,'needsUpgrade':![],'minVersion':_0x27c69f,'packageName':_0x4c93b7,'stableVersion':_0x5b908c};const _0xbce94c=a70_0x51aaa4['coerce'](_0x4625f6),_0x30d187=a70_0x51aaa4[_0x26a725(0xba)](_0x27c69f),_0x58c3c5=_0xbce94c&&_0x30d187?a70_0x51aaa4['lt'](_0xbce94c,_0x30d187):![];return{'installed':!![],'version':_0x4625f6,'needsUpgrade':_0x58c3c5,'minVersion':_0x27c69f,'packageName':_0x4c93b7,'stableVersion':_0x5b908c};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x27c69f,'packageName':_0x4c93b7,'stableVersion':_0x5b908c};}}export function checkSdkVersionSync(_0x72189f){const _0x1bfa3a=a70_0x2553d1,_0x559145=a70_0x29a409['join'](_0x72189f,_0x1bfa3a(0xb2)),_0x260e5a='@lovrabet/sdk';if(!a70_0x1c2639['existsSync'](_0x559145))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x260e5a,'stableVersion':null};try{const _0x3bb5b9=JSON[_0x1bfa3a(0xbe)](a70_0x1c2639[_0x1bfa3a(0xae)](_0x559145,_0x1bfa3a(0x98))),_0x3bb1b9=_0x3bb5b9[_0x1bfa3a(0x9a)]||{},_0x24d392=_0x3bb5b9['devDependencies']||{},_0x38edb4=_0x3bb1b9[_0x260e5a]||_0x24d392[_0x260e5a];if(!_0x38edb4)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x260e5a,'stableVersion':null};let _0x204023=getInstalledVersion(_0x72189f,_0x260e5a);!_0x204023&&(_0x204023=_0x38edb4);if(isNonNumericVersion(_0x38edb4))return{'installed':!![],'version':_0x204023,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x260e5a,'stableVersion':null};const _0x420f63=a70_0x51aaa4[_0x1bfa3a(0xba)](_0x204023),_0x3e4ba7=_0x420f63?a70_0x51aaa4['lt'](_0x420f63,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0x204023,'needsUpgrade':_0x3e4ba7,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x260e5a,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x260e5a,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x4456ee){const _0x5d5d11=a70_0x2553d1;if(!_0x4456ee[_0x5d5d11(0xbb)])return;const _0x4a53a4='\x1b[33m',_0x460951='\x1b[0m',_0x418475=_0x5d5d11(0x9f),_0xbcfb1a=_0x4456ee['packageName']||'@lovrabet/sdk';console[_0x5d5d11(0xb0)](),console[_0x5d5d11(0xb0)](''+_0x4a53a4+_0x418475+_0x5d5d11(0xa1)+_0x460951),console[_0x5d5d11(0xb0)](_0x4a53a4+_0x5d5d11(0xa9)+_0xbcfb1a+'@'+_0x4456ee['version']+_0x460951),console[_0x5d5d11(0xb0)](_0x4a53a4+'\x20\x20\x20稳定版本:\x20'+(_0x4456ee[_0x5d5d11(0xb3)]||_0x4456ee[_0x5d5d11(0xa7)])+_0x460951),console[_0x5d5d11(0xb0)](_0x4a53a4+_0x5d5d11(0xab)+_0xbcfb1a+'@'+(_0x4456ee['stableVersion']||_0x5d5d11(0x9d))+_0x460951),console['log']();}
@@ -1 +1 @@
1
- (function(_0x5239d1,_0x4ad8aa){const _0x5431b3=a70_0x3e24,_0x1cf9cf=_0x5239d1();while(!![]){try{const _0x2b9f52=-parseInt(_0x5431b3(0x91))/0x1+-parseInt(_0x5431b3(0x7d))/0x2+-parseInt(_0x5431b3(0x88))/0x3+-parseInt(_0x5431b3(0x8e))/0x4+parseInt(_0x5431b3(0x7f))/0x5*(-parseInt(_0x5431b3(0x85))/0x6)+-parseInt(_0x5431b3(0x84))/0x7+parseInt(_0x5431b3(0x81))/0x8*(parseInt(_0x5431b3(0x90))/0x9);if(_0x2b9f52===_0x4ad8aa)break;else _0x1cf9cf['push'](_0x1cf9cf['shift']());}catch(_0x4c0bc4){_0x1cf9cf['push'](_0x1cf9cf['shift']());}}}(a70_0x562a,0x334db));function a70_0x3e24(_0x23763e,_0x5d0b95){_0x23763e=_0x23763e-0x7c;const _0x562a49=a70_0x562a();let _0x3e2460=_0x562a49[_0x23763e];return _0x3e2460;}function a70_0x562a(){const _0xf9ee0f=['240796LWYRsc','log','106055LvXsIT','../..','56WjWDEn','stableVersion','\x20\x20\x20当前\x20CLI\x20版本:\x20','156765rEjhbz','6dpEeDj','\x20\x20\x20稳定版本:\x20','utf-8','27420jKwdcI','↪\x20新版本可用','\x1b[1m','test','coerce','1.0.0','49352IPczWB','parse','701262hciSLa','149805hGqrcL','currentVersion','\x1b[0m','\x20\x20\x20升级命令:\x20npm\x20install\x20-g\x20@lovrabet/cli@latest'];a70_0x562a=function(){return _0xf9ee0f;};return a70_0x562a();}import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a70_0x1934b4 from'semver';import{getCdnConfig}from'./cdn-config.js';function getCurrentCliVersion(){const _0x4f961e=a70_0x3e24;try{const _0x46774d=fileURLToPath(import.meta.url),_0x463cab=resolve(dirname(_0x46774d),_0x4f961e(0x80)),_0x411c1a=resolve(_0x463cab,'package.json'),_0x4ba0dc=JSON[_0x4f961e(0x8f)](readFileSync(_0x411c1a,_0x4f961e(0x87)));return _0x4ba0dc['version']||_0x4f961e(0x8d);}catch{return _0x4f961e(0x8d);}}function isNonNumericVersion(_0x2a7e96){const _0x18d513=a70_0x3e24,_0x434a07=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\^/,/^~/,/^>/,/^</,/^\*/,/^x$/];return _0x434a07['some'](_0xc1b979=>_0xc1b979[_0x18d513(0x8b)](_0x2a7e96));}export async function checkCliVersion(){const _0x3295e=a70_0x3e24,_0x3691d5=getCurrentCliVersion(),_0x3bf7f2=await getCdnConfig(),_0x36795b=_0x3bf7f2?.['cli']?.[_0x3295e(0x82)]||null;let _0x450547=![];if(_0x36795b)try{const _0x386d69=a70_0x1934b4[_0x3295e(0x8c)](_0x3691d5),_0x2e31d9=a70_0x1934b4['coerce'](_0x36795b);_0x386d69&&_0x2e31d9&&(_0x450547=a70_0x1934b4['lt'](_0x386d69,_0x2e31d9));}catch{_0x450547=![];}return{'currentVersion':_0x3691d5,'stableVersion':_0x36795b,'needsUpgrade':_0x450547,'isPreRelease':![]};}export function printCliUpgradeWarning(_0x5dcfbe){const _0x2111de=a70_0x3e24;if(!_0x5dcfbe['needsUpgrade'])return;const _0x230ffa='\x1b[33m',_0x4b2279=_0x2111de(0x93),_0x51b274=_0x2111de(0x8a);console[_0x2111de(0x7e)](),console[_0x2111de(0x7e)](''+_0x230ffa+_0x51b274+_0x2111de(0x89)+_0x4b2279),console['log'](_0x230ffa+_0x2111de(0x83)+_0x5dcfbe[_0x2111de(0x92)]+_0x4b2279),console[_0x2111de(0x7e)](_0x230ffa+_0x2111de(0x86)+_0x5dcfbe[_0x2111de(0x82)]+_0x4b2279),console['log'](_0x230ffa+_0x2111de(0x7c)+_0x4b2279),console[_0x2111de(0x7e)]();}
1
+ (function(_0x1be858,_0x97e944){const _0x34c1fb=a71_0x5bc2,_0x1f70fb=_0x1be858();while(!![]){try{const _0xd9682a=parseInt(_0x34c1fb(0x9d))/0x1*(-parseInt(_0x34c1fb(0xa4))/0x2)+parseInt(_0x34c1fb(0xa5))/0x3+-parseInt(_0x34c1fb(0xad))/0x4*(parseInt(_0x34c1fb(0xaf))/0x5)+-parseInt(_0x34c1fb(0xaa))/0x6*(-parseInt(_0x34c1fb(0xb5))/0x7)+-parseInt(_0x34c1fb(0xa1))/0x8*(parseInt(_0x34c1fb(0xae))/0x9)+-parseInt(_0x34c1fb(0xa9))/0xa*(-parseInt(_0x34c1fb(0xac))/0xb)+-parseInt(_0x34c1fb(0xb0))/0xc*(-parseInt(_0x34c1fb(0xa7))/0xd);if(_0xd9682a===_0x97e944)break;else _0x1f70fb['push'](_0x1f70fb['shift']());}catch(_0x4cf28b){_0x1f70fb['push'](_0x1f70fb['shift']());}}}(a71_0x4d78,0x45895));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a71_0x3af56f from'semver';import{getCdnConfig}from'./cdn-config.js';function getCurrentCliVersion(){const _0x3d7607=a71_0x5bc2;try{const _0x1202e0=fileURLToPath(import.meta.url),_0xc58779=resolve(dirname(_0x1202e0),_0x3d7607(0xa2)),_0x5aa1d0=resolve(_0xc58779,_0x3d7607(0x9a)),_0xdcb6e0=JSON[_0x3d7607(0xa8)](readFileSync(_0x5aa1d0,_0x3d7607(0x9c)));return _0xdcb6e0['version']||'1.0.0';}catch{return'1.0.0';}}function a71_0x5bc2(_0x766f60,_0x2c570f){_0x766f60=_0x766f60-0x98;const _0x4d78a7=a71_0x4d78();let _0x5bc2f3=_0x4d78a7[_0x766f60];return _0x5bc2f3;}function isNonNumericVersion(_0x301786){const _0x86c135=a71_0x5bc2,_0x204f31=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\^/,/^~/,/^>/,/^</,/^\*/,/^x$/];return _0x204f31[_0x86c135(0x9b)](_0xf22bd=>_0xf22bd[_0x86c135(0xb2)](_0x301786));}export async function checkCliVersion(){const _0x2ea2f5=a71_0x5bc2,_0x5f6abd=getCurrentCliVersion(),_0x165ba9=await getCdnConfig(),_0x2498b8=_0x165ba9?.[_0x2ea2f5(0xb1)]?.[_0x2ea2f5(0xab)]||null;let _0x270d25=![];if(_0x2498b8)try{const _0x2b9556=a71_0x3af56f[_0x2ea2f5(0xb4)](_0x5f6abd),_0x3e0982=a71_0x3af56f[_0x2ea2f5(0xb4)](_0x2498b8);_0x2b9556&&_0x3e0982&&(_0x270d25=a71_0x3af56f['lt'](_0x2b9556,_0x3e0982));}catch{_0x270d25=![];}return{'currentVersion':_0x5f6abd,'stableVersion':_0x2498b8,'needsUpgrade':_0x270d25,'isPreRelease':![]};}export function printCliUpgradeWarning(_0x25621f){const _0x4e95cf=a71_0x5bc2;if(!_0x25621f[_0x4e95cf(0x99)])return;const _0x2d2d2f=_0x4e95cf(0x9f),_0x32d59b=_0x4e95cf(0xb6),_0x10f23e=_0x4e95cf(0x98);console[_0x4e95cf(0xa0)](),console[_0x4e95cf(0xa0)](''+_0x2d2d2f+_0x10f23e+_0x4e95cf(0xa6)+_0x32d59b),console[_0x4e95cf(0xa0)](_0x2d2d2f+'\x20\x20\x20当前\x20CLI\x20版本:\x20'+_0x25621f[_0x4e95cf(0x9e)]+_0x32d59b),console[_0x4e95cf(0xa0)](_0x2d2d2f+_0x4e95cf(0xa3)+_0x25621f['stableVersion']+_0x32d59b),console[_0x4e95cf(0xa0)](_0x2d2d2f+_0x4e95cf(0xb3)+_0x32d59b),console[_0x4e95cf(0xa0)]();}function a71_0x4d78(){const _0x3b3ee9=['10DCUezt','522HmuAXi','stableVersion','555775bOjZxi','1772HerEwv','30663OsRNss','2465faHiwj','192KvFrKg','cli','test','\x20\x20\x20升级命令:\x20npm\x20install\x20-g\x20@lovrabet/cli@latest','coerce','30394vcKEkG','\x1b[0m','\x1b[1m','needsUpgrade','package.json','some','utf-8','219971KfIxFM','currentVersion','\x1b[33m','log','1096PRFypx','../..','\x20\x20\x20稳定版本:\x20','4JWSiZE','1015326mdWfLa','↪\x20新版本可用','522600xLhySd','parse'];a71_0x4d78=function(){return _0x3b3ee9;};return a71_0x4d78();}
@@ -1 +1 @@
1
- const a71_0x2da6d4=a71_0x1bac;(function(_0x12a5f8,_0x5bec5a){const _0x5e9732=a71_0x1bac,_0x2cacfb=_0x12a5f8();while(!![]){try{const _0x2db0b3=-parseInt(_0x5e9732(0x131))/0x1*(-parseInt(_0x5e9732(0x13c))/0x2)+parseInt(_0x5e9732(0x133))/0x3+-parseInt(_0x5e9732(0x13a))/0x4*(parseInt(_0x5e9732(0x12d))/0x5)+-parseInt(_0x5e9732(0x139))/0x6+-parseInt(_0x5e9732(0x138))/0x7*(parseInt(_0x5e9732(0x137))/0x8)+-parseInt(_0x5e9732(0x13e))/0x9+parseInt(_0x5e9732(0x130))/0xa;if(_0x2db0b3===_0x5bec5a)break;else _0x2cacfb['push'](_0x2cacfb['shift']());}catch(_0x24d7ff){_0x2cacfb['push'](_0x2cacfb['shift']());}}}(a71_0xe861,0xcbe04));function a71_0xe861(){const _0x6401fb=['106995BmAZfx','3832674CkzChQ','4IGNHjS','string','311632SHBWex','https://g.lovrabet.com/dist/lovrabet-cli','4076946UkoDSC','app','.lovrabetrc','trim','5858255SaEZZM','parse','utf8','18955690CDWXdM','4plhKgP','appcode','3206361MQkWsr','env','template_base_url','replace','256djFlmw'];a71_0xe861=function(){return _0x6401fb;};return a71_0xe861();}import{existsSync,readFileSync}from'node:fs';import{resolve}from'node:path';import{homedir}from'node:os';import{initEnv}from'../constant/env.js';export const projectConfigPath=resolve(process['cwd'](),a71_0x2da6d4(0x140));export const globalConfigPath=resolve(homedir(),a71_0x2da6d4(0x140));export function readConfig(_0x23925){const _0x24deeb=a71_0x2da6d4;let _0x505e21={};try{if(existsSync(globalConfigPath)){const _0x9e01=readFileSync(globalConfigPath,{'encoding':_0x24deeb(0x12f)});_0x9e01&&(_0x505e21=JSON[_0x24deeb(0x12e)](_0x9e01));}}catch(_0x1fa7f4){}try{const _0x26c0b8=_0x23925?resolve(_0x23925,'.lovrabetrc'):projectConfigPath;if(existsSync(_0x26c0b8)){const _0xee2b66=readFileSync(_0x26c0b8,{'encoding':_0x24deeb(0x12f)});if(_0xee2b66){const _0x24ef16=JSON[_0x24deeb(0x12e)](_0xee2b66);_0x505e21={..._0x505e21,..._0x24ef16};}}}catch(_0x1201e4){}return _0x505e21[_0x24deeb(0x134)]&&typeof _0x505e21[_0x24deeb(0x134)]===_0x24deeb(0x13b)&&initEnv(_0x505e21['env']),_0x505e21;}function a71_0x1bac(_0x25ee41,_0x3462b1){_0x25ee41=_0x25ee41-0x12d;const _0xe8610a=a71_0xe861();let _0x1bac3c=_0xe8610a[_0x25ee41];return _0x1bac3c;}export function getConfigAppCode(){const _0x1a0336=a71_0x2da6d4;let _0x1ba84a={},_0x39c7a6={};try{if(existsSync(globalConfigPath)){const _0x336575=readFileSync(globalConfigPath,{'encoding':_0x1a0336(0x12f)});_0x336575&&(_0x39c7a6=JSON[_0x1a0336(0x12e)](_0x336575));}}catch(_0x24bf66){}try{if(existsSync(projectConfigPath)){const _0x39ca10=readFileSync(projectConfigPath,{'encoding':'utf8'});_0x39ca10&&(_0x1ba84a=JSON[_0x1a0336(0x12e)](_0x39ca10));}}catch(_0x2f5731){}let _0x44d468;if(_0x1a0336(0x132)in _0x1ba84a)_0x44d468=_0x1ba84a[_0x1a0336(0x132)];else{if('app'in _0x1ba84a)_0x44d468=_0x1ba84a[_0x1a0336(0x13f)];else{if(_0x1a0336(0x132)in _0x39c7a6)_0x44d468=_0x39c7a6[_0x1a0336(0x132)];else _0x1a0336(0x13f)in _0x39c7a6&&(_0x44d468=_0x39c7a6['app']);}}if(typeof _0x44d468!==_0x1a0336(0x13b)||_0x44d468[_0x1a0336(0x141)]()==='')return undefined;return _0x44d468;}export function isInProject(){return existsSync(projectConfigPath);}export function getTemplateBaseUrl(){const _0x443413=a71_0x2da6d4,_0x614240=readConfig();if(_0x614240[_0x443413(0x135)]&&typeof _0x614240[_0x443413(0x135)]==='string')return _0x614240[_0x443413(0x135)][_0x443413(0x136)](/\/$/,'');return _0x443413(0x13d);}
1
+ const a72_0x144850=a72_0x3e7b;(function(_0x225b1b,_0x5646dd){const _0x3fb9ec=a72_0x3e7b,_0xf2c86b=_0x225b1b();while(!![]){try{const _0x22d16d=-parseInt(_0x3fb9ec(0x169))/0x1*(-parseInt(_0x3fb9ec(0x16b))/0x2)+parseInt(_0x3fb9ec(0x16a))/0x3*(-parseInt(_0x3fb9ec(0x168))/0x4)+-parseInt(_0x3fb9ec(0x177))/0x5*(parseInt(_0x3fb9ec(0x16d))/0x6)+parseInt(_0x3fb9ec(0x164))/0x7+parseInt(_0x3fb9ec(0x16f))/0x8*(-parseInt(_0x3fb9ec(0x170))/0x9)+parseInt(_0x3fb9ec(0x174))/0xa*(parseInt(_0x3fb9ec(0x16e))/0xb)+parseInt(_0x3fb9ec(0x173))/0xc*(-parseInt(_0x3fb9ec(0x17a))/0xd);if(_0x22d16d===_0x5646dd)break;else _0xf2c86b['push'](_0xf2c86b['shift']());}catch(_0x3c9085){_0xf2c86b['push'](_0xf2c86b['shift']());}}}(a72_0x3137,0x5d81b));import{existsSync,readFileSync}from'node:fs';import{resolve}from'node:path';import{homedir}from'node:os';import{initEnv}from'../constant/env.js';function a72_0x3137(){const _0x5b0fc3=['string','trim','278192xuTGqT','1wJsFpG','6EpZixl','580956ZAcemy','replace','6MxoRbT','731434XYSvXq','40rOLxBt','247122DUEmZM','utf8','.lovrabetrc','552204DMDkDt','20ZZikxA','template_base_url','app','382245baJEiG','parse','cwd','65VIEMEw','env','3797199RNlwNn','appcode'];a72_0x3137=function(){return _0x5b0fc3;};return a72_0x3137();}export const projectConfigPath=resolve(process[a72_0x144850(0x179)](),a72_0x144850(0x172));export const globalConfigPath=resolve(homedir(),'.lovrabetrc');export function readConfig(_0x5dbcd0){const _0x41548a=a72_0x144850;let _0x3eee1={};try{if(existsSync(globalConfigPath)){const _0x200c72=readFileSync(globalConfigPath,{'encoding':'utf8'});_0x200c72&&(_0x3eee1=JSON['parse'](_0x200c72));}}catch(_0x5394e5){}try{const _0x504d27=_0x5dbcd0?resolve(_0x5dbcd0,_0x41548a(0x172)):projectConfigPath;if(existsSync(_0x504d27)){const _0x40dd44=readFileSync(_0x504d27,{'encoding':_0x41548a(0x171)});if(_0x40dd44){const _0x2e7b1a=JSON['parse'](_0x40dd44);_0x3eee1={..._0x3eee1,..._0x2e7b1a};}}}catch(_0x338768){}return _0x3eee1[_0x41548a(0x163)]&&typeof _0x3eee1[_0x41548a(0x163)]==='string'&&initEnv(_0x3eee1['env']),_0x3eee1;}export function getConfigAppCode(){const _0x2f4100=a72_0x144850;let _0xbb44eb={},_0x353ff2={};try{if(existsSync(globalConfigPath)){const _0x381075=readFileSync(globalConfigPath,{'encoding':'utf8'});_0x381075&&(_0x353ff2=JSON[_0x2f4100(0x178)](_0x381075));}}catch(_0x12f2b2){}try{if(existsSync(projectConfigPath)){const _0x3ffd3f=readFileSync(projectConfigPath,{'encoding':_0x2f4100(0x171)});_0x3ffd3f&&(_0xbb44eb=JSON[_0x2f4100(0x178)](_0x3ffd3f));}}catch(_0x546e71){}let _0x52da7b;if(_0x2f4100(0x165)in _0xbb44eb)_0x52da7b=_0xbb44eb[_0x2f4100(0x165)];else{if(_0x2f4100(0x176)in _0xbb44eb)_0x52da7b=_0xbb44eb['app'];else{if('appcode'in _0x353ff2)_0x52da7b=_0x353ff2[_0x2f4100(0x165)];else _0x2f4100(0x176)in _0x353ff2&&(_0x52da7b=_0x353ff2[_0x2f4100(0x176)]);}}if(typeof _0x52da7b!==_0x2f4100(0x166)||_0x52da7b[_0x2f4100(0x167)]()==='')return undefined;return _0x52da7b;}export function isInProject(){return existsSync(projectConfigPath);}function a72_0x3e7b(_0x142ce8,_0x339bb3){_0x142ce8=_0x142ce8-0x163;const _0x31375d=a72_0x3137();let _0x3e7b44=_0x31375d[_0x142ce8];return _0x3e7b44;}export function getTemplateBaseUrl(){const _0x37ad2e=a72_0x144850,_0x28bcaf=readConfig();if(_0x28bcaf[_0x37ad2e(0x175)]&&typeof _0x28bcaf[_0x37ad2e(0x175)]==='string')return _0x28bcaf[_0x37ad2e(0x175)][_0x37ad2e(0x16c)](/\/$/,'');return'https://g.lovrabet.com/dist/lovrabet-cli';}
@@ -1 +1 @@
1
- function a72_0x55ed(_0x23377a,_0x3b2ca9){_0x23377a=_0x23377a-0x165;const _0x5913bf=a72_0x5913();let _0x55ed8c=_0x5913bf[_0x23377a];return _0x55ed8c;}function a72_0x5913(){const _0x370ece=['2LedsHZ','487375ClXtmN','14293MMBHOU','176198nlPPow','20yKpVst','55767TLSAGZ','readdirSync','228630GFTFWP','423PXJyff','name','复制目录时出错:','528JLteHy','504160yUaoNu','4xrslbG','isDirectory','error','40632oUNOzC','join','mkdirSync'];a72_0x5913=function(){return _0x370ece;};return a72_0x5913();}(function(_0x4982ab,_0x44137b){const _0x1e44b7=a72_0x55ed,_0x469e1c=_0x4982ab();while(!![]){try{const _0x78ffb3=-parseInt(_0x1e44b7(0x16d))/0x1*(-parseInt(_0x1e44b7(0x16b))/0x2)+-parseInt(_0x1e44b7(0x170))/0x3*(-parseInt(_0x1e44b7(0x165))/0x4)+parseInt(_0x1e44b7(0x16f))/0x5*(-parseInt(_0x1e44b7(0x172))/0x6)+-parseInt(_0x1e44b7(0x16c))/0x7+parseInt(_0x1e44b7(0x168))/0x8*(-parseInt(_0x1e44b7(0x173))/0x9)+-parseInt(_0x1e44b7(0x177))/0xa+-parseInt(_0x1e44b7(0x16e))/0xb*(-parseInt(_0x1e44b7(0x176))/0xc);if(_0x78ffb3===_0x44137b)break;else _0x469e1c['push'](_0x469e1c['shift']());}catch(_0x611926){_0x469e1c['push'](_0x469e1c['shift']());}}}(a72_0x5913,0x374c4));import a72_0x3c49a1 from'node:path';import a72_0x594aaa from'node:fs';export async function copyDirectory(_0x1759f9,_0x5f23c4){const _0x1c339f=a72_0x55ed;try{const _0x397087=a72_0x594aaa[_0x1c339f(0x171)](_0x1759f9,{'withFileTypes':!![]});a72_0x594aaa[_0x1c339f(0x16a)](_0x5f23c4,{'recursive':!![]});for(const _0x50cac1 of _0x397087){const _0x16750a=a72_0x3c49a1[_0x1c339f(0x169)](_0x1759f9,_0x50cac1[_0x1c339f(0x174)]),_0x2ee7ad=a72_0x3c49a1[_0x1c339f(0x169)](_0x5f23c4,_0x50cac1[_0x1c339f(0x174)]);_0x50cac1[_0x1c339f(0x166)]()?await copyDirectory(_0x16750a,_0x2ee7ad):a72_0x594aaa['copyFileSync'](_0x16750a,_0x2ee7ad);}}catch(_0x35f641){console[_0x1c339f(0x167)](_0x1c339f(0x175),_0x35f641);}}
1
+ (function(_0x4d2dbf,_0x4f8280){const _0x395f1d=a73_0x1678,_0x35ee8b=_0x4d2dbf();while(!![]){try{const _0x2685af=parseInt(_0x395f1d(0x157))/0x1*(-parseInt(_0x395f1d(0x152))/0x2)+parseInt(_0x395f1d(0x158))/0x3*(parseInt(_0x395f1d(0x15a))/0x4)+parseInt(_0x395f1d(0x153))/0x5*(parseInt(_0x395f1d(0x150))/0x6)+parseInt(_0x395f1d(0x160))/0x7+parseInt(_0x395f1d(0x155))/0x8*(parseInt(_0x395f1d(0x156))/0x9)+parseInt(_0x395f1d(0x154))/0xa+parseInt(_0x395f1d(0x15f))/0xb*(-parseInt(_0x395f1d(0x15b))/0xc);if(_0x2685af===_0x4f8280)break;else _0x35ee8b['push'](_0x35ee8b['shift']());}catch(_0x507c04){_0x35ee8b['push'](_0x35ee8b['shift']());}}}(a73_0x2221,0xcfe89));function a73_0x2221(){const _0x161247=['isDirectory','4135188ywSbfX','name','6OaTZJX','5tZdUQu','11769700uzGILk','8QmVmvO','1651167Ncivgz','310586XCEOXg','419430rWtLZI','复制目录时出错:','16mFoHNj','1890348sTrAJS','copyFileSync','readdirSync','join','88IfhNvk','3042984zwDNZr','mkdirSync'];a73_0x2221=function(){return _0x161247;};return a73_0x2221();}import a73_0x5e2f40 from'node:path';import a73_0x3c47fa from'node:fs';function a73_0x1678(_0x59233f,_0x9a491b){_0x59233f=_0x59233f-0x150;const _0x222123=a73_0x2221();let _0x167827=_0x222123[_0x59233f];return _0x167827;}export async function copyDirectory(_0x45a22e,_0x4b365e){const _0x15d496=a73_0x1678;try{const _0x52cef2=a73_0x3c47fa[_0x15d496(0x15d)](_0x45a22e,{'withFileTypes':!![]});a73_0x3c47fa[_0x15d496(0x161)](_0x4b365e,{'recursive':!![]});for(const _0x402f9c of _0x52cef2){const _0x57d263=a73_0x5e2f40[_0x15d496(0x15e)](_0x45a22e,_0x402f9c[_0x15d496(0x151)]),_0x2b6a1d=a73_0x5e2f40[_0x15d496(0x15e)](_0x4b365e,_0x402f9c[_0x15d496(0x151)]);_0x402f9c[_0x15d496(0x162)]()?await copyDirectory(_0x57d263,_0x2b6a1d):a73_0x3c47fa[_0x15d496(0x15c)](_0x57d263,_0x2b6a1d);}}catch(_0x31abf8){console['error'](_0x15d496(0x159),_0x31abf8);}}
@@ -1 +1 @@
1
- (function(_0x154cf5,_0xe2e109){const _0x3eb9fa=a73_0x3154,_0x41a13d=_0x154cf5();while(!![]){try{const _0x48df1e=-parseInt(_0x3eb9fa(0x17a))/0x1+-parseInt(_0x3eb9fa(0x17b))/0x2*(-parseInt(_0x3eb9fa(0x177))/0x3)+parseInt(_0x3eb9fa(0x17e))/0x4*(-parseInt(_0x3eb9fa(0x179))/0x5)+-parseInt(_0x3eb9fa(0x17c))/0x6*(parseInt(_0x3eb9fa(0x17d))/0x7)+parseInt(_0x3eb9fa(0x17f))/0x8+parseInt(_0x3eb9fa(0x180))/0x9*(-parseInt(_0x3eb9fa(0x178))/0xa)+parseInt(_0x3eb9fa(0x176))/0xb;if(_0x48df1e===_0xe2e109)break;else _0x41a13d['push'](_0x41a13d['shift']());}catch(_0xb1c00c){_0x41a13d['push'](_0x41a13d['shift']());}}}(a73_0x40f1,0x637e9));function a73_0x40f1(){const _0x5bd961=['15751098KGKSKU','609PUUuSM','830QdLvPg','2585NdXgwo','575271wjWeTX','5302fxZFfL','468258hjzvFd','49LmVNNB','2288seYbvB','1863880uwDSHF','41013akeDfN'];a73_0x40f1=function(){return _0x5bd961;};return a73_0x40f1();}function a73_0x3154(_0x4678e9,_0x59dd28){_0x4678e9=_0x4678e9-0x176;const _0x40f15b=a73_0x40f1();let _0x3154d4=_0x40f15b[_0x4678e9];return _0x3154d4;}import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';export async function copyDir(_0xca903e,_0x5ee63f){const _0x4ed9f4=statSync(_0xca903e);if(_0x4ed9f4['isDirectory']()){!existsSync(_0x5ee63f)&&mkdirSync(_0x5ee63f,{'recursive':!![]});const _0x268aeb=readdirSync(_0xca903e);for(const _0x20226c of _0x268aeb){await copyDir(join(_0xca903e,_0x20226c),join(_0x5ee63f,_0x20226c));}}else copyFileSync(_0xca903e,_0x5ee63f);}export function ensureDir(_0x59cc00){!existsSync(_0x59cc00)&&mkdirSync(_0x59cc00,{'recursive':!![]});}export function pathExists(_0x4c82cb){return existsSync(_0x4c82cb);}
1
+ function a74_0x5875(){const _0x58650d=['5643080Xfbuno','645xSGJLD','5452805fmAaSk','32kpdvhg','41935652MVPBzK','isDirectory','13149346VcBgUr','10988ZGngwT','1593lTHQKc','56054XOYJzX','6576PMpLJO','6HWfsrs'];a74_0x5875=function(){return _0x58650d;};return a74_0x5875();}(function(_0x576bfc,_0x1a79d9){const _0x32bdce=a74_0x1fc0,_0x1b9bd4=_0x576bfc();while(!![]){try{const _0x38c6c5=parseInt(_0x32bdce(0x1a6))/0x1*(-parseInt(_0x32bdce(0x1ac))/0x2)+-parseInt(_0x32bdce(0x1a4))/0x3*(-parseInt(_0x32bdce(0x1aa))/0x4)+parseInt(_0x32bdce(0x1a5))/0x5*(-parseInt(_0x32bdce(0x1a2))/0x6)+-parseInt(_0x32bdce(0x1a9))/0x7+-parseInt(_0x32bdce(0x1a1))/0x8*(parseInt(_0x32bdce(0x1ab))/0x9)+parseInt(_0x32bdce(0x1a3))/0xa+parseInt(_0x32bdce(0x1a7))/0xb;if(_0x38c6c5===_0x1a79d9)break;else _0x1b9bd4['push'](_0x1b9bd4['shift']());}catch(_0x57713c){_0x1b9bd4['push'](_0x1b9bd4['shift']());}}}(a74_0x5875,0xe95c8));function a74_0x1fc0(_0x14842d,_0x2d5ccb){_0x14842d=_0x14842d-0x1a1;const _0x58756e=a74_0x5875();let _0x1fc0b8=_0x58756e[_0x14842d];return _0x1fc0b8;}import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';export async function copyDir(_0x6e5fb9,_0x19d745){const _0x2df0e4=a74_0x1fc0,_0x2f12ba=statSync(_0x6e5fb9);if(_0x2f12ba[_0x2df0e4(0x1a8)]()){!existsSync(_0x19d745)&&mkdirSync(_0x19d745,{'recursive':!![]});const _0x5534b2=readdirSync(_0x6e5fb9);for(const _0x2bd939 of _0x5534b2){await copyDir(join(_0x6e5fb9,_0x2bd939),join(_0x19d745,_0x2bd939));}}else copyFileSync(_0x6e5fb9,_0x19d745);}export function ensureDir(_0x2193d3){!existsSync(_0x2193d3)&&mkdirSync(_0x2193d3,{'recursive':!![]});}export function pathExists(_0x48b6be){return existsSync(_0x48b6be);}
@@ -1 +1 @@
1
- const a74_0x10b6c7=a74_0x16ab;(function(_0x3a00a9,_0x5f55f5){const _0x587457=a74_0x16ab,_0x215fb9=_0x3a00a9();while(!![]){try{const _0x1d8f52=-parseInt(_0x587457(0xbe))/0x1*(-parseInt(_0x587457(0xc9))/0x2)+-parseInt(_0x587457(0xd3))/0x3*(parseInt(_0x587457(0xd0))/0x4)+-parseInt(_0x587457(0xc5))/0x5*(parseInt(_0x587457(0xc2))/0x6)+-parseInt(_0x587457(0xc7))/0x7*(parseInt(_0x587457(0xcc))/0x8)+-parseInt(_0x587457(0xc6))/0x9*(-parseInt(_0x587457(0xcb))/0xa)+parseInt(_0x587457(0xba))/0xb*(parseInt(_0x587457(0xce))/0xc)+-parseInt(_0x587457(0xd1))/0xd*(parseInt(_0x587457(0xc0))/0xe);if(_0x1d8f52===_0x5f55f5)break;else _0x215fb9['push'](_0x215fb9['shift']());}catch(_0x41e7d6){_0x215fb9['push'](_0x215fb9['shift']());}}}(a74_0x2b7c,0x86d3d));import{mkdirSync,writeFileSync}from'node:fs';import{dirname,join}from'node:path';import{getTemplateBaseUrl}from'./config.js';function getGuidesCdnUrl(){const _0x480117=getTemplateBaseUrl();return _0x480117+'/skills/guides.json';}const CACHE_DIR=join(process['env'][a74_0x10b6c7(0xc8)]||process[a74_0x10b6c7(0xc4)][a74_0x10b6c7(0xd6)]||'',a74_0x10b6c7(0xb9),'cache');export async function fetchGuidesFromCDN(){const _0x3aa6c4=a74_0x10b6c7,_0xe356e6=getGuidesCdnUrl(),_0x935655=await fetch(_0xe356e6,{'headers':{'Accept':_0x3aa6c4(0xb7)}});if(!_0x935655['ok'])throw new Error('CDN\x20请求失败:\x20'+_0x935655[_0x3aa6c4(0xbc)]+'\x20'+_0x935655[_0x3aa6c4(0xca)]);const _0xc29048=await _0x935655[_0x3aa6c4(0xcd)]();if(!_0xc29048['guides']||typeof _0xc29048[_0x3aa6c4(0xd2)]!==_0x3aa6c4(0xbf))throw new Error(_0x3aa6c4(0xd4));return _0xc29048;}export function writeGuidesToProject(_0x8b34a8,_0x47a76f,_0xe298c5='.lovrabet/skill/.shared/guides'){const _0x1e0e47=a74_0x10b6c7,_0x5708f3=join(_0x47a76f,_0xe298c5);for(const [_0xd4d62,_0x48d7a6]of Object[_0x1e0e47(0xb6)](_0x8b34a8[_0x1e0e47(0xd2)])){const _0x19a5fe=join(_0x5708f3,_0xd4d62);mkdirSync(_0x19a5fe,{'recursive':!![]});let _0x2e310d=_0x48d7a6[_0x1e0e47(0xc1)];_0x48d7a6['lastUpdated']&&(_0x2e310d=appendUpdateTime(_0x2e310d,_0x48d7a6[_0x1e0e47(0xd7)])),writeFileSync(join(_0x19a5fe,'guide.md'),_0x2e310d,_0x1e0e47(0xb5));}}export function appendUpdateTime(_0x43ff06,_0x33fe22){const _0x5e19df=a74_0x10b6c7;return _0x43ff06=_0x43ff06[_0x5e19df(0xcf)](/\n*>更新时间:.*$/m,''),_0x43ff06['trimEnd']()+(_0x5e19df(0xd8)+_0x33fe22);}function a74_0x2b7c(){const _0x4ec9f0=['HOME','86iUtery','statusText','10FiSprb','195976REHPQJ','json','84WRJdJZ','replace','2579324LlRFQe','26raGuvb','guides','3fzpabd','CDN\x20返回数据格式错误','map','USERPROFILE','lastUpdated','\x0a\x0a>更新时间:','utf-8','entries','application/json','skillTemplate','.lovrabet','729773aiaoVL','title','status','keys','16914JmKZxT','object','459704YlXvwU','content','2352234rbvpsL','CDN\x20数据中缺少\x20skillTemplate','env','5IDNTXp','8356815iNtrlB','133XpXosP'];a74_0x2b7c=function(){return _0x4ec9f0;};return a74_0x2b7c();}export function getSkillTemplate(_0x4e3258){return _0x4e3258['skillTemplate']?.['content']||'';}export function writeSkillFile(_0x2b03f1,_0x3b9bec,_0x4c9069){const _0x250bd5=a74_0x10b6c7,_0x4c1f1b=getSkillTemplate(_0x2b03f1);if(!_0x4c1f1b)throw new Error(_0x250bd5(0xc3));const _0x225613=dirname(_0x3b9bec);mkdirSync(_0x225613,{'recursive':!![]});let _0x58550f=_0x4c1f1b[_0x250bd5(0xcf)](/\{\{IDE_NAME\}\}/g,_0x4c9069);_0x2b03f1[_0x250bd5(0xb8)][_0x250bd5(0xd7)]&&(_0x58550f=appendUpdateTime(_0x58550f,_0x2b03f1[_0x250bd5(0xb8)][_0x250bd5(0xd7)])),writeFileSync(_0x3b9bec,_0x58550f,_0x250bd5(0xb5));}function a74_0x16ab(_0x305307,_0x3b464e){_0x305307=_0x305307-0xb5;const _0x2b7c14=a74_0x2b7c();let _0x16ab71=_0x2b7c14[_0x305307];return _0x16ab71;}export async function installGuides(_0x514846){const _0x4f8795=a74_0x10b6c7,_0x273114=await fetchGuidesFromCDN();return writeGuidesToProject(_0x273114,_0x514846),Object[_0x4f8795(0xbd)](_0x273114[_0x4f8795(0xd2)])['length'];}export function getGuidesSummary(_0x5cbe7f){const _0x19b080=a74_0x10b6c7;return Object[_0x19b080(0xb6)](_0x5cbe7f['guides'])[_0x19b080(0xd5)](([_0x4399ab,_0x4ce250])=>({'key':_0x4399ab,'title':_0x4ce250[_0x19b080(0xbb)],'path':_0x4ce250['path']}));}
1
+ const a75_0x249fe2=a75_0x4bb1;(function(_0x373af5,_0x2aac71){const _0x4fd947=a75_0x4bb1,_0x17a20d=_0x373af5();while(!![]){try{const _0x4862dd=parseInt(_0x4fd947(0x189))/0x1+parseInt(_0x4fd947(0x190))/0x2+parseInt(_0x4fd947(0x199))/0x3+-parseInt(_0x4fd947(0x1a1))/0x4*(parseInt(_0x4fd947(0x192))/0x5)+-parseInt(_0x4fd947(0x1a6))/0x6+-parseInt(_0x4fd947(0x187))/0x7+parseInt(_0x4fd947(0x18e))/0x8*(-parseInt(_0x4fd947(0x17e))/0x9);if(_0x4862dd===_0x2aac71)break;else _0x17a20d['push'](_0x17a20d['shift']());}catch(_0x3dd11d){_0x17a20d['push'](_0x17a20d['shift']());}}}(a75_0x4cc1,0xee5c6));import{mkdirSync,writeFileSync}from'node:fs';import{dirname,join}from'node:path';import{getTemplateBaseUrl}from'./config.js';function getGuidesCdnUrl(){const _0x35b183=getTemplateBaseUrl();return _0x35b183+'/skills/guides.json';}function getGuidesExtendCdnUrl(){const _0x10ffbd=a75_0x4bb1,_0x24e306=getTemplateBaseUrl();return _0x24e306+_0x10ffbd(0x197);}function a75_0x4bb1(_0x4dc7bd,_0x5f24ba){_0x4dc7bd=_0x4dc7bd-0x17d;const _0x4cc1c0=a75_0x4cc1();let _0x4bb1c2=_0x4cc1c0[_0x4dc7bd];return _0x4bb1c2;}const CACHE_DIR=join(process['env'][a75_0x249fe2(0x19c)]||process[a75_0x249fe2(0x181)]['USERPROFILE']||'',a75_0x249fe2(0x18a),a75_0x249fe2(0x1a2));export async function fetchGuidesFromCDN(_0x3d62a8=![]){const _0x514f40=a75_0x249fe2,_0x1cd2b1=getGuidesCdnUrl(),_0xab1ffd=await fetch(_0x1cd2b1,{'headers':{'Accept':'application/json'}});if(!_0xab1ffd['ok'])throw new Error(_0x514f40(0x1a3)+_0xab1ffd['status']+'\x20'+_0xab1ffd[_0x514f40(0x17d)]);const _0x390645=await _0xab1ffd['json']();if(!_0x390645['guides']||typeof _0x390645[_0x514f40(0x19a)]!==_0x514f40(0x1a5))throw new Error('CDN\x20返回数据格式错误');if(!_0x3d62a8)return _0x390645;try{const _0x441e3b=getGuidesExtendCdnUrl(),_0x41cb1e=await fetch(_0x441e3b,{'headers':{'Accept':_0x514f40(0x182)}});if(_0x41cb1e['ok']){const _0xb3dd75=await _0x41cb1e[_0x514f40(0x18d)]();_0xb3dd75[_0x514f40(0x19a)]&&typeof _0xb3dd75[_0x514f40(0x19a)]===_0x514f40(0x1a5)&&(_0x390645[_0x514f40(0x19a)]={..._0x390645[_0x514f40(0x19a)],..._0xb3dd75[_0x514f40(0x19a)]});}}catch{}return _0x390645;}export function writeGuidesToProject(_0x1c2c05,_0x217d35,_0x5caf0f=a75_0x249fe2(0x19f),_0x3a42ca){const _0x73e1b3=a75_0x249fe2,_0x45c114=join(_0x217d35,_0x5caf0f);for(const [_0x51bb22,_0xd34003]of Object[_0x73e1b3(0x18f)](_0x1c2c05['guides'])){if(_0xd34003['requireFlags']&&_0xd34003['requireFlags'][_0x73e1b3(0x1a9)]>0x0){const _0x24312c=_0xd34003[_0x73e1b3(0x188)][_0x73e1b3(0x1a8)](_0x26dcc3=>_0x3a42ca?.['includes'](_0x26dcc3));if(!_0x24312c)continue;}const _0x344d48=join(_0x45c114,_0x51bb22);mkdirSync(_0x344d48,{'recursive':!![]});let _0x33b04b=_0xd34003[_0x73e1b3(0x196)];_0xd34003[_0x73e1b3(0x186)]&&(_0x33b04b=appendUpdateTime(_0x33b04b,_0xd34003[_0x73e1b3(0x186)])),writeFileSync(join(_0x344d48,_0x73e1b3(0x1a7)),_0x33b04b,_0x73e1b3(0x18b));}}export function appendUpdateTime(_0x233e74,_0x43d3a2){const _0x1ae999=a75_0x249fe2;return _0x233e74=_0x233e74[_0x1ae999(0x1a0)](/\n*>更新时间:.*$/m,''),_0x233e74['trimEnd']()+('\x0a\x0a>更新时间:'+_0x43d3a2);}export function getSkillTemplate(_0x43b21f){const _0x23d797=a75_0x249fe2;return _0x43b21f[_0x23d797(0x185)]?.[_0x23d797(0x196)]||'';}export function appendExtendContents(_0x8a8e8f,_0x2ecd92,_0x2b4f5a){const _0x4f6580=a75_0x249fe2,_0x315fec=[];for(const [_0x34d10b,_0x795566]of Object['entries'](_0x2ecd92[_0x4f6580(0x19a)])){if(_0x795566[_0x4f6580(0x188)]&&_0x795566[_0x4f6580(0x188)][_0x4f6580(0x1a9)]>0x0){const _0x4ba05b=_0x795566[_0x4f6580(0x188)][_0x4f6580(0x1a8)](_0x244b97=>_0x2b4f5a?.[_0x4f6580(0x193)](_0x244b97));if(!_0x4ba05b)continue;}_0x795566[_0x4f6580(0x184)]&&_0x315fec['push'](_0x795566[_0x4f6580(0x184)][_0x4f6580(0x194)]());}if(_0x315fec['length']===0x0)return _0x8a8e8f;return _0x8a8e8f[_0x4f6580(0x194)]()+'\x0a\x0a'+_0x315fec[_0x4f6580(0x183)]('\x0a\x0a')+'\x0a';}function a75_0x4cc1(){const _0x3eb3c4=['HOME','\x0a<!--\x20GUIDES_APPEND\x20-->','<!--\x20GUIDES_APPEND\x20-->','.lovrabet/skill/.shared/guides','replace','3656476Rjnbgo','cache','CDN\x20请求失败:\x20','sort','object','3237360yEvgse','guide.md','some','length','statusText','9vkzmZC','|\x20`','path','env','application/json','join','extendContent','skillTemplate','lastUpdated','2367421radqbH','requireFlags','705949JsJWoq','.lovrabet','utf-8','keys','json','11936048qFSrpY','entries','3462192msxSkK','title','5lQTnZC','includes','trimEnd','CDN\x20数据中缺少\x20skillTemplate','content','/skills/guides-extend.json','map','5469507tSfkXV','guides','`\x20|\x20'];a75_0x4cc1=function(){return _0x3eb3c4;};return a75_0x4cc1();}export function writeSkillFile(_0x11b078,_0x5294d3,_0x5d9b3b,_0x3cbb43){const _0x993dbb=a75_0x249fe2,_0x52e00f=getSkillTemplate(_0x11b078);if(!_0x52e00f)throw new Error(_0x993dbb(0x195));const _0x29b6d5=dirname(_0x5294d3);mkdirSync(_0x29b6d5,{'recursive':!![]});let _0x5a02c2=_0x52e00f[_0x993dbb(0x1a0)](/\{\{IDE_NAME\}\}/g,_0x5d9b3b);_0x5a02c2=insertGuidesSection(_0x5a02c2,_0x11b078,_0x3cbb43),_0x5a02c2=appendExtendContents(_0x5a02c2,_0x11b078,_0x3cbb43),_0x11b078[_0x993dbb(0x185)]['lastUpdated']&&(_0x5a02c2=appendUpdateTime(_0x5a02c2,_0x11b078[_0x993dbb(0x185)][_0x993dbb(0x186)])),writeFileSync(_0x5294d3,_0x5a02c2,'utf-8');}export function insertGuidesSection(_0x2997d9,_0x1f7bfc,_0x4f9dbc){const _0x4d1664=a75_0x249fe2,_0x1e7747='<!--\x20GUIDES_APPEND\x20-->',_0x56a742=_0x2997d9['indexOf'](_0x1e7747);if(_0x56a742===-0x1)return _0x2997d9;const _0x50e8ba=[],_0x3e048f=Object[_0x4d1664(0x18c)](_0x1f7bfc[_0x4d1664(0x19a)])[_0x4d1664(0x1a4)]();for(const _0xd9d055 of _0x3e048f){const _0x3dc00d=_0x1f7bfc['guides'][_0xd9d055];if(!_0x3dc00d)continue;if(/^0[1-6]-/['test'](_0xd9d055))continue;if(_0x3dc00d[_0x4d1664(0x188)]&&_0x3dc00d[_0x4d1664(0x188)][_0x4d1664(0x1a9)]>0x0){const _0x12b92a=_0x3dc00d['requireFlags']['some'](_0x4f3cbe=>_0x4f9dbc?.['includes'](_0x4f3cbe));if(!_0x12b92a)continue;}const _0x461972=_0x3dc00d[_0x4d1664(0x180)]['replace'](/^\.lovrabet\/skill\/\.shared\/guides\//,'');_0x50e8ba['push'](_0x4d1664(0x17f)+_0x461972+_0x4d1664(0x19b)+_0x3dc00d[_0x4d1664(0x191)]+'\x20|');}if(_0x50e8ba[_0x4d1664(0x1a9)]===0x0)return _0x2997d9[_0x4d1664(0x1a0)](_0x1e7747,_0x4d1664(0x19e));const _0x1ccefe=_0x50e8ba['join']('\x0a');return _0x2997d9[_0x4d1664(0x1a0)](_0x1e7747,_0x1ccefe+_0x4d1664(0x19d));}export async function installGuides(_0x37e885){const _0x587cb3=a75_0x249fe2,_0x30c406=await fetchGuidesFromCDN();return writeGuidesToProject(_0x30c406,_0x37e885),Object['keys'](_0x30c406[_0x587cb3(0x19a)])[_0x587cb3(0x1a9)];}export function getGuidesSummary(_0x41b643){const _0x1c49c4=a75_0x249fe2;return Object[_0x1c49c4(0x18f)](_0x41b643[_0x1c49c4(0x19a)])[_0x1c49c4(0x198)](([_0x1abfca,_0xe6cfc])=>({'key':_0x1abfca,'title':_0xe6cfc[_0x1c49c4(0x191)],'path':_0xe6cfc[_0x1c49c4(0x180)]}));}
@@ -1 +1 @@
1
- (function(_0x257fb7,_0x489546){const _0x1e67db=a75_0x29b0,_0x5e98f0=_0x257fb7();while(!![]){try{const _0x338e65=parseInt(_0x1e67db(0x167))/0x1+-parseInt(_0x1e67db(0x179))/0x2+parseInt(_0x1e67db(0x15f))/0x3+parseInt(_0x1e67db(0x168))/0x4+parseInt(_0x1e67db(0x170))/0x5*(-parseInt(_0x1e67db(0x176))/0x6)+parseInt(_0x1e67db(0x165))/0x7+-parseInt(_0x1e67db(0x173))/0x8*(parseInt(_0x1e67db(0x16a))/0x9);if(_0x338e65===_0x489546)break;else _0x5e98f0['push'](_0x5e98f0['shift']());}catch(_0x13744c){_0x5e98f0['push'](_0x5e98f0['shift']());}}}(a75_0x2d95,0x1c8af));export async function httpRequest(_0xa3b72d,_0x2fd97d={}){const _0x211c02=a75_0x29b0,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x2fd97d;let _0x4271bc=null;for(let _0x509871=0x0;_0x509871<=retries;_0x509871++){try{const _0x3d63e1=new AbortController(),_0xbea52f=setTimeout(()=>_0x3d63e1[_0x211c02(0x16d)](),timeout),_0x3b0fa2=await fetch(_0xa3b72d,{'headers':headers,'signal':_0x3d63e1[_0x211c02(0x178)]});clearTimeout(_0xbea52f);let _0x1aef4b;const _0x2e048f=_0x3b0fa2['headers'][_0x211c02(0x162)](_0x211c02(0x163));return _0x2e048f?.[_0x211c02(0x175)](_0x211c02(0x169))?_0x1aef4b=await _0x3b0fa2['json']():_0x1aef4b=await _0x3b0fa2[_0x211c02(0x164)](),{'ok':_0x3b0fa2['ok'],'status':_0x3b0fa2[_0x211c02(0x171)],'statusText':_0x3b0fa2['statusText'],'data':_0x1aef4b,'headers':_0x3b0fa2[_0x211c02(0x172)],'url':_0x3b0fa2[_0x211c02(0x16f)],'text':()=>_0x3b0fa2[_0x211c02(0x164)]()};}catch(_0x3ed70c){_0x4271bc=_0x3ed70c instanceof Error?_0x3ed70c:new Error(String(_0x3ed70c));if(_0x509871===retries)break;if(shouldRetry(_0x3ed70c)){console[_0x211c02(0x161)](_0x211c02(0x177)+retryDelay+_0x211c02(0x166)+(_0x509871+0x1)+_0x211c02(0x160)),await sleep(retryDelay);continue;}else break;}}throw _0x4271bc||new Error('Request\x20failed');}function shouldRetry(_0x4f5983){const _0x19b8ae=a75_0x29b0;if(_0x4f5983 instanceof Error){if(_0x4f5983[_0x19b8ae(0x17a)]===_0x19b8ae(0x174))return![];if(_0x4f5983[_0x19b8ae(0x17a)]===_0x19b8ae(0x16e)&&_0x4f5983[_0x19b8ae(0x16c)][_0x19b8ae(0x175)]('fetch'))return!![];if(_0x4f5983[_0x19b8ae(0x16c)][_0x19b8ae(0x175)](_0x19b8ae(0x16b)))return!![];if(_0x4f5983[_0x19b8ae(0x16c)]['includes'](_0x19b8ae(0x15e)))return![];}return![];}function sleep(_0x1a1a40){return new Promise(_0x3f4dcd=>setTimeout(_0x3f4dcd,_0x1a1a40));}function a75_0x29b0(_0x13c9b9,_0x25eb79){_0x13c9b9=_0x13c9b9-0x15e;const _0x2d9548=a75_0x2d95();let _0x29b0a3=_0x2d9548[_0x13c9b9];return _0x29b0a3;}export function validateUrl(_0x1acd9d){try{return new URL(_0x1acd9d),!![];}catch{return![];}}function a75_0x2d95(){const _0x177cde=['TypeError','url','400505ZQYVgr','status','headers','20984SHhaQN','AbortError','includes','6RXJXFj','*\x20请求失败,','signal','171970EXzPSZ','name','ENOTFOUND','14037BHBngl','\x20次重试...','log','get','content-type','text','1561336AUDymf','ms\x20后进行第\x20','229802RtYaOl','917640uCrUVL','application/json','1386qDLTlo','ECONNRESET','message','abort'];a75_0x2d95=function(){return _0x177cde;};return a75_0x2d95();}
1
+ (function(_0x2877a2,_0x1ea011){const _0x131eab=a76_0x4e9b,_0x57e0ef=_0x2877a2();while(!![]){try{const _0x587dc8=-parseInt(_0x131eab(0xbc))/0x1*(parseInt(_0x131eab(0xc0))/0x2)+parseInt(_0x131eab(0xbf))/0x3*(-parseInt(_0x131eab(0xc9))/0x4)+parseInt(_0x131eab(0xb7))/0x5+-parseInt(_0x131eab(0xb9))/0x6*(parseInt(_0x131eab(0xc1))/0x7)+parseInt(_0x131eab(0xbe))/0x8*(parseInt(_0x131eab(0xb5))/0x9)+parseInt(_0x131eab(0xce))/0xa+-parseInt(_0x131eab(0xca))/0xb;if(_0x587dc8===_0x1ea011)break;else _0x57e0ef['push'](_0x57e0ef['shift']());}catch(_0x48aadd){_0x57e0ef['push'](_0x57e0ef['shift']());}}}(a76_0x34cb,0x3a383));export async function httpRequest(_0x10027d,_0x4fe644={}){const _0x7052ea=a76_0x4e9b,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x4fe644;let _0x12458c=null;for(let _0x3b61b8=0x0;_0x3b61b8<=retries;_0x3b61b8++){try{const _0x1e25a0=new AbortController(),_0x4d30f0=setTimeout(()=>_0x1e25a0[_0x7052ea(0xb8)](),timeout),_0x18fe3d=await fetch(_0x10027d,{'headers':headers,'signal':_0x1e25a0['signal']});clearTimeout(_0x4d30f0);let _0x572d0c;const _0x3fd040=_0x18fe3d['headers'][_0x7052ea(0xc2)]('content-type');return _0x3fd040?.['includes'](_0x7052ea(0xd0))?_0x572d0c=await _0x18fe3d[_0x7052ea(0xba)]():_0x572d0c=await _0x18fe3d['text'](),{'ok':_0x18fe3d['ok'],'status':_0x18fe3d['status'],'statusText':_0x18fe3d[_0x7052ea(0xc7)],'data':_0x572d0c,'headers':_0x18fe3d[_0x7052ea(0xcb)],'url':_0x18fe3d[_0x7052ea(0xb6)],'text':()=>_0x18fe3d[_0x7052ea(0xc5)]()};}catch(_0x45929c){_0x12458c=_0x45929c instanceof Error?_0x45929c:new Error(String(_0x45929c));if(_0x3b61b8===retries)break;if(shouldRetry(_0x45929c)){console[_0x7052ea(0xd2)](_0x7052ea(0xc4)+retryDelay+_0x7052ea(0xbd)+(_0x3b61b8+0x1)+_0x7052ea(0xc3)),await sleep(retryDelay);continue;}else break;}}throw _0x12458c||new Error(_0x7052ea(0xcc));}function a76_0x34cb(){const _0x419950=['name','2789250CxgLXg','message','application/json','AbortError','log','9lmbnSr','url','1037180lWpNxn','abort','176178ePAdyp','json','includes','48hdGiXS','ms\x20后进行第\x20','3029984CHYAIS','121713GBFwnV','10694gCuqqa','49WZGDJD','get','\x20次重试...','*\x20请求失败,','text','ENOTFOUND','statusText','fetch','12wCxQKM','470052NJcIHA','headers','Request\x20failed'];a76_0x34cb=function(){return _0x419950;};return a76_0x34cb();}function a76_0x4e9b(_0x54aa5f,_0x1a247a){_0x54aa5f=_0x54aa5f-0xb5;const _0x34cb2f=a76_0x34cb();let _0x4e9b44=_0x34cb2f[_0x54aa5f];return _0x4e9b44;}function shouldRetry(_0x3d4d66){const _0xf0d638=a76_0x4e9b;if(_0x3d4d66 instanceof Error){if(_0x3d4d66[_0xf0d638(0xcd)]===_0xf0d638(0xd1))return![];if(_0x3d4d66['name']==='TypeError'&&_0x3d4d66[_0xf0d638(0xcf)][_0xf0d638(0xbb)](_0xf0d638(0xc8)))return!![];if(_0x3d4d66[_0xf0d638(0xcf)][_0xf0d638(0xbb)]('ECONNRESET'))return!![];if(_0x3d4d66[_0xf0d638(0xcf)][_0xf0d638(0xbb)](_0xf0d638(0xc6)))return![];}return![];}function sleep(_0x17765b){return new Promise(_0x3f4e8e=>setTimeout(_0x3f4e8e,_0x17765b));}export function validateUrl(_0x5c6272){try{return new URL(_0x5c6272),!![];}catch{return![];}}
@@ -1 +1 @@
1
- function a76_0x27b6(_0x1ad8e4,_0x5bcda0){_0x1ad8e4=_0x1ad8e4-0xea;const _0x5ec43c=a76_0x5ec4();let _0x27b61d=_0x5ec43c[_0x1ad8e4];return _0x27b61d;}const a76_0x5a3b7a=a76_0x27b6;(function(_0x400a4e,_0x369a1e){const _0xc731eb=a76_0x27b6,_0x659056=_0x400a4e();while(!![]){try{const _0x234af2=parseInt(_0xc731eb(0x108))/0x1*(parseInt(_0xc731eb(0xf6))/0x2)+parseInt(_0xc731eb(0x117))/0x3*(parseInt(_0xc731eb(0x106))/0x4)+parseInt(_0xc731eb(0x115))/0x5*(parseInt(_0xc731eb(0x104))/0x6)+parseInt(_0xc731eb(0xff))/0x7*(-parseInt(_0xc731eb(0x101))/0x8)+-parseInt(_0xc731eb(0x10a))/0x9+parseInt(_0xc731eb(0x118))/0xa+parseInt(_0xc731eb(0xec))/0xb*(parseInt(_0xc731eb(0x10e))/0xc);if(_0x234af2===_0x369a1e)break;else _0x659056['push'](_0x659056['shift']());}catch(_0x1f0dbb){_0x659056['push'](_0x659056['shift']());}}}(a76_0x5ec4,0xf28ce));function a76_0x5ec4(){const _0x183bf0=['1DLgBwT','File','7143147VERurp','existsSync','clear','split','852RDfNQo','失败:\x20','now','message','log','Failed\x20to\x20read\x20logs:','readFileSync','2908380rrvGjl','duration','2667UqXmyC','6204970KGsyuW','combine','filter','stringify','.lovrabet.log','details','开始执行:\x20','完成:\x20','currentRawCommand','initWinstonLogger','parse','join','map','transports','error','utf8','21901iceqoC','errors','info','timestamp','red','logFilePath','warn','success','mkdirSync','toISOString','2392400Ocudtf','format','dirname','trim','getWinstonInstance','green','unknown','command','logTask','7KXvZJn','winstonLogger','7179776wCEMBh','addColors','createLogger','6dYKNhN','level','652uxbjSG','readLogs'];a76_0x5ec4=function(){return _0x183bf0;};return a76_0x5ec4();}import a76_0x3baf0d from'winston';import a76_0x177835 from'node:fs';import a76_0x167fbe from'node:path';class Logger{[a76_0x5a3b7a(0x100)];[a76_0x5a3b7a(0xf1)];[a76_0x5a3b7a(0x120)]='';constructor(){this['logFilePath']='';}['setRawCommand'](_0x244e2b){const _0x36b839=a76_0x5a3b7a;this[_0x36b839(0x120)]=_0x244e2b;}[a76_0x5a3b7a(0x121)](){const _0x30c5bf=a76_0x5a3b7a,_0x441c3f=a76_0x167fbe[_0x30c5bf(0xf8)](this[_0x30c5bf(0xf1)]);!a76_0x177835[_0x30c5bf(0x10b)](_0x441c3f)&&a76_0x177835[_0x30c5bf(0xf4)](_0x441c3f,{'recursive':!![]});const _0x18382e=a76_0x3baf0d[_0x30c5bf(0xf7)][_0x30c5bf(0x119)](a76_0x3baf0d[_0x30c5bf(0xf7)][_0x30c5bf(0xef)](),a76_0x3baf0d['format'][_0x30c5bf(0xed)]({'stack':!![]}),a76_0x3baf0d[_0x30c5bf(0xf7)]['printf'](_0x32bb91=>{const _0x756a7b=_0x30c5bf,_0x544519={'timestamp':_0x32bb91[_0x756a7b(0xef)]||new Date()[_0x756a7b(0xf5)](),'level':_0x32bb91[_0x756a7b(0x105)]||_0x756a7b(0xee),'command':_0x32bb91[_0x756a7b(0xfd)]||_0x756a7b(0xfc),'rawCommand':_0x32bb91['rawCommand']||this[_0x756a7b(0x120)]||undefined,'message':_0x32bb91['message']||'','duration':_0x32bb91[_0x756a7b(0x116)]||undefined,'details':_0x32bb91[_0x756a7b(0x11d)]||undefined};return JSON[_0x756a7b(0x11b)](_0x544519);}));this[_0x30c5bf(0x100)]=a76_0x3baf0d[_0x30c5bf(0x103)]({'level':'info','format':_0x18382e,'transports':[new a76_0x3baf0d[(_0x30c5bf(0x125))][(_0x30c5bf(0x109))]({'filename':this[_0x30c5bf(0xf1)],'level':_0x30c5bf(0xee)})],'silent':![]}),a76_0x3baf0d[_0x30c5bf(0x102)]({'success':_0x30c5bf(0xfb),'error':_0x30c5bf(0xf0),'warn':'yellow','info':'blue'});}['setLogPath'](_0x5b7480){const _0x48b272=a76_0x5a3b7a;this[_0x48b272(0xf1)]=a76_0x167fbe[_0x48b272(0x123)](_0x5b7480,_0x48b272(0x11c)),this['winstonLogger']&&this[_0x48b272(0x100)][_0x48b272(0x10c)](),this[_0x48b272(0x121)]();}[a76_0x5a3b7a(0xee)](_0x3deae7,_0x1a84fc,_0x1760be){const _0x1f237b=a76_0x5a3b7a;if(!this['logFilePath']||!this[_0x1f237b(0x100)])return;this['winstonLogger']['info'](_0x1a84fc,{'command':_0x3deae7,'details':_0x1760be});}[a76_0x5a3b7a(0xf3)](_0xfa3953,_0x140d7e,_0x1aa295,_0xc7dcb9){const _0x14ff4f=a76_0x5a3b7a;if(!this[_0x14ff4f(0xf1)]||!this[_0x14ff4f(0x100)])return;this['winstonLogger'][_0x14ff4f(0x112)](_0x14ff4f(0xee),_0x140d7e,{'level':_0x14ff4f(0xf3),'command':_0xfa3953,'duration':_0x1aa295,'details':_0xc7dcb9});}[a76_0x5a3b7a(0xea)](_0x2c9d3f,_0x6cff30,_0x2eeebb){const _0x4d5c84=a76_0x5a3b7a;if(!this[_0x4d5c84(0xf1)]||!this['winstonLogger'])return;this['winstonLogger'][_0x4d5c84(0xea)](_0x6cff30,{'command':_0x2c9d3f,'details':_0x2eeebb});}[a76_0x5a3b7a(0xf2)](_0x37719a,_0x478ca3,_0x27a661){const _0xd95ca=a76_0x5a3b7a;if(!this[_0xd95ca(0xf1)]||!this[_0xd95ca(0x100)])return;this[_0xd95ca(0x100)]['warn'](_0x478ca3,{'command':_0x37719a,'details':_0x27a661});}async[a76_0x5a3b7a(0xfe)](_0x508ec8,_0x33acf6,_0x5d1bba){const _0x4cfc3c=a76_0x5a3b7a,_0x515912=Date[_0x4cfc3c(0x110)]();this[_0x4cfc3c(0xee)](_0x508ec8,_0x4cfc3c(0x11e)+_0x33acf6);try{const _0x5425b4=await _0x5d1bba(),_0xdece57=Date[_0x4cfc3c(0x110)]()-_0x515912;return this[_0x4cfc3c(0xf3)](_0x508ec8,_0x4cfc3c(0x11f)+_0x33acf6,_0xdece57),_0x5425b4;}catch(_0x20c1a5){const _0x1a9df2=Date[_0x4cfc3c(0x110)]()-_0x515912;this[_0x4cfc3c(0xea)](_0x508ec8,_0x4cfc3c(0x10f)+_0x33acf6,{'error':_0x20c1a5 instanceof Error?_0x20c1a5[_0x4cfc3c(0x111)]:String(_0x20c1a5),'duration':_0x1a9df2});throw _0x20c1a5;}}[a76_0x5a3b7a(0x107)](){const _0x49fe58=a76_0x5a3b7a;try{if(!a76_0x177835[_0x49fe58(0x10b)](this[_0x49fe58(0xf1)]))return[];const _0x3832c3=a76_0x177835[_0x49fe58(0x114)](this[_0x49fe58(0xf1)],_0x49fe58(0xeb));return _0x3832c3[_0x49fe58(0x10d)]('\x0a')[_0x49fe58(0x11a)](_0x461d5d=>_0x461d5d[_0x49fe58(0xf9)]())[_0x49fe58(0x124)](_0x584ea8=>JSON[_0x49fe58(0x122)](_0x584ea8));}catch(_0x8f6f73){return console[_0x49fe58(0xf2)](_0x49fe58(0x113),_0x8f6f73),[];}}['clearLogs'](){const _0x3db8e9=a76_0x5a3b7a;try{a76_0x177835[_0x3db8e9(0x10b)](this[_0x3db8e9(0xf1)])&&a76_0x177835['writeFileSync'](this[_0x3db8e9(0xf1)],'',_0x3db8e9(0xeb));}catch(_0x27e6d8){console[_0x3db8e9(0xf2)]('Failed\x20to\x20clear\x20logs:',_0x27e6d8);}}[a76_0x5a3b7a(0xfa)](){return this['winstonLogger'];}}export const logger=new Logger();
1
+ const a77_0x183510=a77_0x74ba;(function(_0x44aad2,_0x31849b){const _0x534aa6=a77_0x74ba,_0x15b3b4=_0x44aad2();while(!![]){try{const _0x16c539=parseInt(_0x534aa6(0x1d7))/0x1+parseInt(_0x534aa6(0x201))/0x2*(parseInt(_0x534aa6(0x1e3))/0x3)+-parseInt(_0x534aa6(0x1ea))/0x4+-parseInt(_0x534aa6(0x1f9))/0x5*(-parseInt(_0x534aa6(0x1df))/0x6)+parseInt(_0x534aa6(0x1e4))/0x7+parseInt(_0x534aa6(0x1fb))/0x8+-parseInt(_0x534aa6(0x1d6))/0x9*(parseInt(_0x534aa6(0x1dd))/0xa);if(_0x16c539===_0x31849b)break;else _0x15b3b4['push'](_0x15b3b4['shift']());}catch(_0x58d351){_0x15b3b4['push'](_0x15b3b4['shift']());}}}(a77_0xb454,0x3723a));import a77_0x1439e6 from'winston';import a77_0x2e90c7 from'node:fs';function a77_0xb454(){const _0x2b70b4=['warn','now','setRawCommand','2lBzJFT','trim','logFilePath','log','readFileSync','clearLogs','format','36qPWGIY','320292aebudi','green','Failed\x20to\x20clear\x20logs:','writeFileSync','map','printf','1825410YQasnv','winstonLogger','357438ivwCMJ','info','parse','File','342165jGWNqI','1342278cpSrAJ','join','setLogPath','transports','initWinstonLogger','errors','473080hmpWuU','split','details','logTask','dirname','red','readLogs','level','Failed\x20to\x20read\x20logs:','success','existsSync','getWinstonInstance','error','message','currentRawCommand','10bNHAbO','失败:\x20','2632296uPNBNP','utf8','stringify'];a77_0xb454=function(){return _0x2b70b4;};return a77_0xb454();}function a77_0x74ba(_0x12da8f,_0x2f2569){_0x12da8f=_0x12da8f-0x1d5;const _0xb45424=a77_0xb454();let _0x74bac6=_0xb45424[_0x12da8f];return _0x74bac6;}import a77_0x4c574c from'node:path';class Logger{[a77_0x183510(0x1de)];[a77_0x183510(0x203)];[a77_0x183510(0x1f8)]='';constructor(){const _0x4af998=a77_0x183510;this[_0x4af998(0x203)]='';}[a77_0x183510(0x200)](_0x3f3e2c){const _0x5eb144=a77_0x183510;this[_0x5eb144(0x1f8)]=_0x3f3e2c;}[a77_0x183510(0x1e8)](){const _0x2cba26=a77_0x183510,_0x41dbe8=a77_0x4c574c[_0x2cba26(0x1ee)](this['logFilePath']);!a77_0x2e90c7[_0x2cba26(0x1f4)](_0x41dbe8)&&a77_0x2e90c7['mkdirSync'](_0x41dbe8,{'recursive':!![]});const _0xd42138=a77_0x1439e6[_0x2cba26(0x1d5)]['combine'](a77_0x1439e6['format']['timestamp'](),a77_0x1439e6[_0x2cba26(0x1d5)][_0x2cba26(0x1e9)]({'stack':!![]}),a77_0x1439e6['format'][_0x2cba26(0x1dc)](_0x1a8312=>{const _0x38cbea=_0x2cba26,_0x108ad8={'timestamp':_0x1a8312['timestamp']||new Date()['toISOString'](),'level':_0x1a8312[_0x38cbea(0x1f1)]||_0x38cbea(0x1e0),'command':_0x1a8312['command']||'unknown','rawCommand':_0x1a8312['rawCommand']||this[_0x38cbea(0x1f8)]||undefined,'message':_0x1a8312[_0x38cbea(0x1f7)]||'','duration':_0x1a8312['duration']||undefined,'details':_0x1a8312[_0x38cbea(0x1ec)]||undefined};return JSON[_0x38cbea(0x1fd)](_0x108ad8);}));this['winstonLogger']=a77_0x1439e6['createLogger']({'level':_0x2cba26(0x1e0),'format':_0xd42138,'transports':[new a77_0x1439e6[(_0x2cba26(0x1e7))][(_0x2cba26(0x1e2))]({'filename':this[_0x2cba26(0x203)],'level':'info'})],'silent':![]}),a77_0x1439e6['addColors']({'success':_0x2cba26(0x1d8),'error':_0x2cba26(0x1ef),'warn':'yellow','info':'blue'});}[a77_0x183510(0x1e6)](_0x5d131e){const _0x43d9d9=a77_0x183510;this[_0x43d9d9(0x203)]=a77_0x4c574c[_0x43d9d9(0x1e5)](_0x5d131e,'.lovrabet.log'),this[_0x43d9d9(0x1de)]&&this[_0x43d9d9(0x1de)]['clear'](),this[_0x43d9d9(0x1e8)]();}[a77_0x183510(0x1e0)](_0xfa5046,_0x44f648,_0x41c534){const _0x24085b=a77_0x183510;if(!this['logFilePath']||!this[_0x24085b(0x1de)])return;this['winstonLogger']['info'](_0x44f648,{'command':_0xfa5046,'details':_0x41c534});}[a77_0x183510(0x1f3)](_0xd521c,_0x3c96ed,_0x1224f3,_0x1afccd){const _0x1bd55f=a77_0x183510;if(!this['logFilePath']||!this[_0x1bd55f(0x1de)])return;this[_0x1bd55f(0x1de)][_0x1bd55f(0x204)]('info',_0x3c96ed,{'level':'success','command':_0xd521c,'duration':_0x1224f3,'details':_0x1afccd});}[a77_0x183510(0x1f6)](_0x4654b4,_0x350100,_0x342900){const _0x57b364=a77_0x183510;if(!this[_0x57b364(0x203)]||!this[_0x57b364(0x1de)])return;this[_0x57b364(0x1de)]['error'](_0x350100,{'command':_0x4654b4,'details':_0x342900});}[a77_0x183510(0x1fe)](_0x4cdc84,_0x4ca757,_0x4b5574){const _0x1fee83=a77_0x183510;if(!this[_0x1fee83(0x203)]||!this[_0x1fee83(0x1de)])return;this[_0x1fee83(0x1de)][_0x1fee83(0x1fe)](_0x4ca757,{'command':_0x4cdc84,'details':_0x4b5574});}async[a77_0x183510(0x1ed)](_0x16a619,_0x284c5a,_0x1e278c){const _0x42eec0=a77_0x183510,_0x58bf34=Date[_0x42eec0(0x1ff)]();this['info'](_0x16a619,'开始执行:\x20'+_0x284c5a);try{const _0x47e609=await _0x1e278c(),_0x4465ef=Date['now']()-_0x58bf34;return this[_0x42eec0(0x1f3)](_0x16a619,'完成:\x20'+_0x284c5a,_0x4465ef),_0x47e609;}catch(_0x26e98b){const _0x168331=Date[_0x42eec0(0x1ff)]()-_0x58bf34;this[_0x42eec0(0x1f6)](_0x16a619,_0x42eec0(0x1fa)+_0x284c5a,{'error':_0x26e98b instanceof Error?_0x26e98b['message']:String(_0x26e98b),'duration':_0x168331});throw _0x26e98b;}}[a77_0x183510(0x1f0)](){const _0x425a66=a77_0x183510;try{if(!a77_0x2e90c7[_0x425a66(0x1f4)](this['logFilePath']))return[];const _0x582142=a77_0x2e90c7[_0x425a66(0x205)](this[_0x425a66(0x203)],_0x425a66(0x1fc));return _0x582142[_0x425a66(0x1eb)]('\x0a')['filter'](_0x16ad51=>_0x16ad51[_0x425a66(0x202)]())[_0x425a66(0x1db)](_0x1d1ebf=>JSON[_0x425a66(0x1e1)](_0x1d1ebf));}catch(_0x121396){return console[_0x425a66(0x1fe)](_0x425a66(0x1f2),_0x121396),[];}}[a77_0x183510(0x206)](){const _0x179b27=a77_0x183510;try{a77_0x2e90c7[_0x179b27(0x1f4)](this['logFilePath'])&&a77_0x2e90c7[_0x179b27(0x1da)](this[_0x179b27(0x203)],'','utf8');}catch(_0x2464ba){console[_0x179b27(0x1fe)](_0x179b27(0x1d9),_0x2464ba);}}[a77_0x183510(0x1f5)](){const _0x257317=a77_0x183510;return this[_0x257317(0x1de)];}}export const logger=new Logger();