@lovrabet/cli 1.2.5-beta.3 → 1.2.5-beta.4

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 (66) 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.js +1 -1
  31. package/lib/cmd/build-watch.js +1 -1
  32. package/lib/cmd/build.js +1 -1
  33. package/lib/cmd/logs.js +1 -1
  34. package/lib/cmd/preview.js +1 -1
  35. package/lib/cmd/start.js +1 -1
  36. package/lib/config/config-help.js +1 -1
  37. package/lib/config/main.js +1 -1
  38. package/lib/constant/domain.js +1 -1
  39. package/lib/constant/env.js +1 -1
  40. package/lib/create-app/enhanced-guided-create.js +1 -1
  41. package/lib/create-app/format-elapsed.js +1 -1
  42. package/lib/create-app/main.js +1 -1
  43. package/lib/create-app/task-finished.js +1 -1
  44. package/lib/create-app/task-loading.js +1 -1
  45. package/lib/create-app/task-running.js +1 -1
  46. package/lib/create-app/task-time.js +1 -1
  47. package/lib/create-app/use-copy-project-template.js +1 -1
  48. package/lib/create-app/use-format-code.js +1 -1
  49. package/lib/create-app/use-install-dependencies.js +1 -1
  50. package/lib/help.js +1 -1
  51. package/lib/init/main.js +1 -1
  52. package/lib/mcp/McpInstallUI.js +1 -1
  53. package/lib/mcp/claude.js +1 -1
  54. package/lib/mcp/cursor.js +1 -1
  55. package/lib/mcp/main.js +1 -1
  56. package/lib/skills/SkillInstallUI.js +1 -1
  57. package/lib/skills/main.js +1 -1
  58. package/lib/utils/check-sdk-version.js +1 -1
  59. package/lib/utils/config.js +1 -1
  60. package/lib/utils/copy-directory.js +1 -1
  61. package/lib/utils/http-client.js +1 -1
  62. package/lib/utils/logger.js +1 -1
  63. package/lib/utils/router-updater.js +1 -1
  64. package/lib/utils/sleep.js +1 -1
  65. package/lib/utils/template-replacer.js +1 -1
  66. package/package.json +1 -1
package/lib/cli.js CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- const a31_0xff26ca=a31_0x4b3e;(function(_0x23eaea,_0x47e53b){const _0x23df0b=a31_0x4b3e,_0x132780=_0x23eaea();while(!![]){try{const _0x3b2602=parseInt(_0x23df0b(0x16a))/0x1*(parseInt(_0x23df0b(0x187))/0x2)+parseInt(_0x23df0b(0x16f))/0x3+parseInt(_0x23df0b(0x162))/0x4*(parseInt(_0x23df0b(0x191))/0x5)+parseInt(_0x23df0b(0x177))/0x6+parseInt(_0x23df0b(0x164))/0x7*(-parseInt(_0x23df0b(0x19b))/0x8)+parseInt(_0x23df0b(0x19e))/0x9*(-parseInt(_0x23df0b(0x19c))/0xa)+-parseInt(_0x23df0b(0x1a0))/0xb*(parseInt(_0x23df0b(0x198))/0xc);if(_0x3b2602===_0x47e53b)break;else _0x132780['push'](_0x132780['shift']());}catch(_0x16b63a){_0x132780['push'](_0x132780['shift']());}}}(a31_0xa7bd,0xc87ff));function a31_0x4b3e(_0x5d95d5,_0x428741){_0x5d95d5=_0x5d95d5-0x160;const _0xa7bd82=a31_0xa7bd();let _0x4b3ec9=_0xa7bd82[_0x5d95d5];return _0x4b3ec9;}import{jsx as a31_0x232585}from'react/jsx-runtime';import a31_0x4bb642 from'meow';import{render}from'ink';import{CreateApp}from'./create-app/main.js';import{AddPage}from'./add-page/main.js';import{Init}from'./init/main.js';import{runStart}from'./cmd/start.js';import{runBuild}from'./cmd/build.js';import{runPreview}from'./cmd/preview.js';import{runBuildWatch}from'./cmd/build-watch.js';import{Config}from'./config/main.js';import{apiCli}from'./api/main.js';import{AuthServer}from'./auth/auth-server-ui.js';import{logout}from'./auth/logout.js';import{Help}from'./help.js';import{logger}from'./utils/logger.js';import{showLogs,clearLogs}from'./cmd/logs.js';import{AppMenuSyncUI}from'./app-menu/app-menu-sync-ui.js';import{mcpCommand}from'./mcp/main.js';import{AppMenuUpdateCdn}from'./app-menu-update-cdn/main.js';import{skillsCommand}from'./skills/main.js';function a31_0xa7bd(){const _0x1af084=['slice','windsurf','执行配置\x20MCP\x20命令','env','323542mlIoFC','执行构建命令','exit','setRawCommand','auth','install','执行安装技能包命令','cwd','all','error','355775LlVOyh','flags','info','trae','mcp','cursor','other','108CVkFFF','\x0a\x09Usage\x0a\x09\x20\x20$\x20lovrabet\x0a\x0a\x09Examples\x0a\x09\x20\x20$\x20lovrabet\x20auth\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//\x20登录认证\x0a\x09\x20\x20$\x20lovrabet\x20logout\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退出登录\x0a\x09\x20\x20$\x20lovrabet\x20init\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//\x20在现有项目中初始化\x20.lovrabetrc\x20配置文件\x0a\x09\x20\x20$\x20lovrabet\x20init\x20--appcode\x20<code>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20使用指定的\x20appcode\x20初始化配置文件\x0a\x09\x20\x20$\x20lovrabet\x20create\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创建一个项目\x0a\x09\x20\x20$\x20lovrabet\x20create\x20--env\x20daily\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20创建项目并指定环境\x0a\x09\x20\x20$\x20lovrabet\x20add\x20page\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20添加一个页面\x0a\x09\x20\x20$\x20lovrabet\x20start\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启动项目\x0a\x09\x20\x20$\x20lovrabet\x20build\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构建项目\x0a\x09\x20\x20$\x20lovrabet\x20menu\x20sync\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20同步菜单\x0a\x09\x20\x20$\x20lovrabet\x20menu\x20update\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20更新菜单\x20CDN\x20资源\x0a\x09\x20\x20$\x20lovrabet\x20preview\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预览项目\x0a\x09\x20\x20$\x20lovrabet\x20preview\x20--watch\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20监听文件变化并自动构建预览\x0a\x09\x20\x20$\x20lovrabet\x20config\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项目配置\x0a\x09\x20\x20$\x20lovrabet\x20api\x20pull\x20--[options]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20拉取并生成\x20API\x20配置文件(详见\x20lovrabet\x20api\x20--help)\x0a\x09\x20\x20$\x20lovrabet\x20api\x20doc\x20--[options]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20生成\x20API\x20文档(详见\x20lovrabet\x20api\x20--help)\x0a\x09\x20\x20$\x20lovrabet\x20mcp\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20交互式选择并配置\x20MCP\x0a\x09\x20\x20$\x20lovrabet\x20mcp\x20install\x20--cursor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20直接配置\x20Cursor\x20MCP\x0a\x09\x20\x20$\x20lovrabet\x20skill\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20交互式选择并安装技能包\x0a\x09\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20直接安装\x20Cursor\x20技能包\x0a\x09\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20--claude\x20//\x20安装多个技能包\x0a\x09\x20\x20$\x20lovrabet\x20skill\x20install\x20--all\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20安装所有技能包\x0a\x09\x20\x20$\x20lovrabet\x20logs\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//\x20查看日志\x0a\x09\x20\x20$\x20lovrabet\x20logs\x20--clear\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20清空日志\x0a','setLogPath','33224OjrJhH','10tosREr','lovrabet\x20','9756549EDfwJH','create','345972nppiNR','build','init','boolean','input','40zCtigw','执行更新菜单\x20CDN\x20资源命令','518lrFhRw','string','start','trim','codex','page','1sBRLGb','argv','执行启动命令','执行添加页面命令','help','2331864qdkvRq','push','claude','appcode','agent','logout','codebuddy','join','5070534pnnJtl','clear','qoder','opencode','--help','add-page','skill','antigravity','update','add','mcpCursor','mcpOther'];a31_0xa7bd=function(){return _0x1af084;};return a31_0xa7bd();}import{SkillInstallUI}from'./skills/SkillInstallUI.js';import{McpInstallUI}from'./mcp/McpInstallUI.js';const cli=a31_0x4bb642(a31_0xff26ca(0x199),{'importMeta':import.meta,'flags':{'name':{'type':a31_0xff26ca(0x165)},'clear':{'type':a31_0xff26ca(0x160)},'env':{'type':a31_0xff26ca(0x165)},'watch':{'type':a31_0xff26ca(0x160)},'help':{'type':'boolean'},'appcode':{'type':'string'},'output':{'type':a31_0xff26ca(0x165)},'params':{'type':a31_0xff26ca(0x165)},'datasetcode':{'type':'string'},'mcpCursor':{'type':a31_0xff26ca(0x160)},'mcpClaude':{'type':a31_0xff26ca(0x160)},'mcpOther':{'type':a31_0xff26ca(0x160)},'cursor':{'type':a31_0xff26ca(0x160)},'windsurf':{'type':'boolean'},'claude':{'type':a31_0xff26ca(0x160)},'codex':{'type':'boolean'},'opencode':{'type':a31_0xff26ca(0x160)},'qoder':{'type':a31_0xff26ca(0x160)},'codebuddy':{'type':a31_0xff26ca(0x160)},'trae':{'type':a31_0xff26ca(0x160)},'agent':{'type':'boolean'},'antigravity':{'type':a31_0xff26ca(0x160)},'all':{'type':a31_0xff26ca(0x160)}},'autoVersion':!![]});await run();async function run(){const _0x49be42=a31_0xff26ca,_0x51db30=cli[_0x49be42(0x161)][0x0],_0x1ddf35=cli[_0x49be42(0x161)][0x1],_0x1f8b24=cli[_0x49be42(0x161)][0x2],_0x504840=(_0x49be42(0x19d)+process[_0x49be42(0x16b)][_0x49be42(0x183)](0x2)[_0x49be42(0x176)]('\x20'))[_0x49be42(0x167)]();logger[_0x49be42(0x18a)](_0x504840);switch(_0x51db30){case'init':{const _0x3d4083=cli[_0x49be42(0x192)][_0x49be42(0x172)],_0x362d36=cli[_0x49be42(0x192)][_0x49be42(0x186)];logger[_0x49be42(0x19a)](process[_0x49be42(0x18e)]()),logger[_0x49be42(0x193)](_0x49be42(0x1a2),'执行初始化配置命令'),render(a31_0x232585(Init,{'appcode':_0x3d4083,'env':_0x362d36}));break;}case _0x49be42(0x19f):{const _0x2fab7a=cli[_0x49be42(0x161)][0x1]?.[_0x49be42(0x167)](),_0x52f17e=cli[_0x49be42(0x192)]['env'];render(a31_0x232585(CreateApp,{'projectCode':_0x2fab7a,'env':_0x52f17e}));break;}case _0x49be42(0x180):{cli['input'][0x1]===_0x49be42(0x169)&&(logger['setLogPath'](process[_0x49be42(0x18e)]()),logger['info'](_0x49be42(0x17c),_0x49be42(0x16d)),render(a31_0x232585(AddPage,{})));break;}case _0x49be42(0x166):{try{logger[_0x49be42(0x19a)](process[_0x49be42(0x18e)]()),logger[_0x49be42(0x193)](_0x49be42(0x166),_0x49be42(0x16c)),await runStart();}catch(_0x1edb2f){console[_0x49be42(0x190)](_0x1edb2f),process[_0x49be42(0x189)](0x1);}break;}case _0x49be42(0x1a1):{try{logger[_0x49be42(0x19a)](process['cwd']()),logger['info'](_0x49be42(0x1a1),_0x49be42(0x188)),await runBuild();}catch(_0x5204fb){console[_0x49be42(0x190)](_0x5204fb),process[_0x49be42(0x189)](0x1);}break;}case'preview':{const _0x260e72=cli[_0x49be42(0x192)]['watch'];logger[_0x49be42(0x19a)](process[_0x49be42(0x18e)]()),logger[_0x49be42(0x193)]('preview','执行预览命令'+(_0x260e72?'\x20(监听模式)':''));if(_0x260e72)try{await Promise[_0x49be42(0x18f)]([runBuildWatch(),runPreview()]);}catch(_0x116e5f){console[_0x49be42(0x190)](_0x116e5f),process[_0x49be42(0x189)](0x1);}else try{await runPreview();}catch(_0x5e8241){console[_0x49be42(0x190)](_0x5e8241),process['exit'](0x1);}break;}case'config':{render(a31_0x232585(Config,{'cli':cli}));break;}case'api':{await apiCli(cli);break;}case _0x49be42(0x18b):{render(a31_0x232585(AuthServer,{}));break;}case'menu':{if(_0x1ddf35===_0x49be42(0x17f)){logger[_0x49be42(0x19a)](process[_0x49be42(0x18e)]()),logger[_0x49be42(0x193)]('menu-update-cdn',_0x49be42(0x163)),render(a31_0x232585(AppMenuUpdateCdn,{}));break;}else render(a31_0x232585(AppMenuSyncUI,{}));break;}case _0x49be42(0x174):{logout();break;}case _0x49be42(0x195):{const _0x769a8=cli[_0x49be42(0x161)][0x1];logger[_0x49be42(0x19a)](process['cwd']());if(_0x769a8==='install'){const _0x2890d6=[];if(cli['flags'][_0x49be42(0x181)])_0x2890d6['push']('cursor');if(cli[_0x49be42(0x192)]['mcpClaude'])_0x2890d6[_0x49be42(0x170)](_0x49be42(0x171));if(cli[_0x49be42(0x192)][_0x49be42(0x182)])_0x2890d6['push'](_0x49be42(0x197));logger[_0x49be42(0x193)]('mcp-install',_0x49be42(0x185),{'preselected':_0x2890d6}),render(a31_0x232585(McpInstallUI,{'preselectedIDEs':_0x2890d6}));}else _0x769a8===_0x49be42(0x17b)||cli['flags'][_0x49be42(0x16e)]?await mcpCommand(_0x769a8,[],{'help':!![]}):await mcpCommand(_0x769a8,[],cli[_0x49be42(0x192)]);break;}case _0x49be42(0x17d):{const _0x4baf90=cli[_0x49be42(0x161)][0x1];logger[_0x49be42(0x19a)](process[_0x49be42(0x18e)]());if(_0x4baf90===_0x49be42(0x18c)){const _0x1815c3=[];if(cli[_0x49be42(0x192)][_0x49be42(0x18f)])_0x1815c3[_0x49be42(0x170)]('cursor',_0x49be42(0x184),_0x49be42(0x171),_0x49be42(0x168),_0x49be42(0x17a),_0x49be42(0x179),_0x49be42(0x175),'trae',_0x49be42(0x173),'antigravity');else{if(cli[_0x49be42(0x192)][_0x49be42(0x196)])_0x1815c3[_0x49be42(0x170)]('cursor');if(cli['flags'][_0x49be42(0x184)])_0x1815c3[_0x49be42(0x170)](_0x49be42(0x184));if(cli[_0x49be42(0x192)][_0x49be42(0x171)])_0x1815c3[_0x49be42(0x170)](_0x49be42(0x171));if(cli[_0x49be42(0x192)][_0x49be42(0x168)])_0x1815c3[_0x49be42(0x170)](_0x49be42(0x168));if(cli[_0x49be42(0x192)][_0x49be42(0x17a)])_0x1815c3[_0x49be42(0x170)](_0x49be42(0x17a));if(cli[_0x49be42(0x192)][_0x49be42(0x179)])_0x1815c3['push']('qoder');if(cli[_0x49be42(0x192)][_0x49be42(0x175)])_0x1815c3[_0x49be42(0x170)](_0x49be42(0x175));if(cli[_0x49be42(0x192)][_0x49be42(0x194)])_0x1815c3[_0x49be42(0x170)]('trae');if(cli[_0x49be42(0x192)]['agent'])_0x1815c3[_0x49be42(0x170)](_0x49be42(0x173));if(cli['flags'][_0x49be42(0x17e)])_0x1815c3[_0x49be42(0x170)](_0x49be42(0x17e));}logger[_0x49be42(0x193)]('skill-install',_0x49be42(0x18d),{'preselected':_0x1815c3}),render(a31_0x232585(SkillInstallUI,{'preselectedIDEs':_0x1815c3}));}else _0x4baf90===_0x49be42(0x17b)||cli[_0x49be42(0x192)][_0x49be42(0x16e)]?await skillsCommand(_0x4baf90,[],{'help':!![]}):await skillsCommand(_0x4baf90,[],cli['flags']);break;}case'logs':{cli['flags'][_0x49be42(0x178)]?clearLogs():showLogs();break;}default:render(a31_0x232585(Help,{}));break;}}
2
+ const a31_0x534ad3=a31_0xef70;(function(_0x45c7bd,_0x2482f0){const _0x5c5a31=a31_0xef70,_0x41975b=_0x45c7bd();while(!![]){try{const _0x3c0947=-parseInt(_0x5c5a31(0x123))/0x1*(parseInt(_0x5c5a31(0xed))/0x2)+-parseInt(_0x5c5a31(0xfb))/0x3+-parseInt(_0x5c5a31(0x10b))/0x4+-parseInt(_0x5c5a31(0x106))/0x5+parseInt(_0x5c5a31(0xf8))/0x6*(parseInt(_0x5c5a31(0xef))/0x7)+parseInt(_0x5c5a31(0x102))/0x8+parseInt(_0x5c5a31(0xec))/0x9*(parseInt(_0x5c5a31(0xe8))/0xa);if(_0x3c0947===_0x2482f0)break;else _0x41975b['push'](_0x41975b['shift']());}catch(_0x2b673f){_0x41975b['push'](_0x41975b['shift']());}}}(a31_0x15fe,0x8648b));import{jsx as a31_0x3ce456}from'react/jsx-runtime';import a31_0x4de045 from'meow';import{render}from'ink';import{CreateApp}from'./create-app/main.js';import{AddPage}from'./add-page/main.js';import{Init}from'./init/main.js';import{runStart}from'./cmd/start.js';import{runBuild}from'./cmd/build.js';import{runPreview}from'./cmd/preview.js';import{runBuildWatch}from'./cmd/build-watch.js';import{Config}from'./config/main.js';function a31_0x15fe(){const _0x5b025e=['logout','api','trim','setLogPath','mcpOther','cursor','opencode','boolean','18DEiCyo','env','update','2676420DWYuiO','string','mcpCursor','antigravity','cwd','trae','qoder','4502224XRonFw','push','windsurf','create','5207110udQRjw','skill','page','\x20(监听模式)','add-page','2466600cNoPNJ','lovrabet\x20','input','auth','--help','mcp','error','mcp-install','执行配置\x20MCP\x20命令','info','执行启动命令','slice','init','codebuddy','执行安装技能包命令','clear','all','mcpClaude','start','menu-sync','claude','执行初始化配置命令','执行构建命令','preview','3944GbfAkZ','执行预览命令','flags','\x0a\x09Usage\x0a\x09\x20\x20$\x20lovrabet\x0a\x0a\x09Examples\x0a\x09\x20\x20$\x20lovrabet\x20auth\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//\x20登录认证\x0a\x09\x20\x20$\x20lovrabet\x20logout\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退出登录\x0a\x09\x20\x20$\x20lovrabet\x20init\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//\x20在现有项目中初始化\x20.lovrabetrc\x20配置文件\x0a\x09\x20\x20$\x20lovrabet\x20init\x20--appcode\x20<code>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20使用指定的\x20appcode\x20初始化配置文件\x0a\x09\x20\x20$\x20lovrabet\x20create\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创建一个项目\x0a\x09\x20\x20$\x20lovrabet\x20create\x20--env\x20daily\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20创建项目并指定环境\x0a\x09\x20\x20$\x20lovrabet\x20add\x20page\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20添加一个页面\x0a\x09\x20\x20$\x20lovrabet\x20start\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启动项目\x0a\x09\x20\x20$\x20lovrabet\x20build\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构建项目\x0a\x09\x20\x20$\x20lovrabet\x20menu\x20sync\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20同步菜单\x0a\x09\x20\x20$\x20lovrabet\x20menu\x20update\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20更新菜单\x20CDN\x20资源\x0a\x09\x20\x20$\x20lovrabet\x20preview\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预览项目\x0a\x09\x20\x20$\x20lovrabet\x20preview\x20--watch\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20监听文件变化并自动构建预览\x0a\x09\x20\x20$\x20lovrabet\x20config\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项目配置\x0a\x09\x20\x20$\x20lovrabet\x20api\x20pull\x20--[options]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20拉取并生成\x20API\x20配置文件(详见\x20lovrabet\x20api\x20--help)\x0a\x09\x20\x20$\x20lovrabet\x20api\x20doc\x20--[options]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20生成\x20API\x20文档(详见\x20lovrabet\x20api\x20--help)\x0a\x09\x20\x20$\x20lovrabet\x20mcp\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20交互式选择并配置\x20MCP\x0a\x09\x20\x20$\x20lovrabet\x20mcp\x20install\x20--cursor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20直接配置\x20Cursor\x20MCP\x0a\x09\x20\x20$\x20lovrabet\x20skill\x20install\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20交互式选择并安装技能包\x0a\x09\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20直接安装\x20Cursor\x20技能包\x0a\x09\x20\x20$\x20lovrabet\x20skill\x20install\x20--cursor\x20--claude\x20//\x20安装多个技能包\x0a\x09\x20\x20$\x20lovrabet\x20skill\x20install\x20--all\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20安装所有技能包\x0a\x09\x20\x20$\x20lovrabet\x20logs\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//\x20查看日志\x0a\x09\x20\x20$\x20lovrabet\x20logs\x20--clear\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20清空日志\x0a','exit','install','other','1888010BRbJiJ','join','codex','agent','99fVuYfl','270wZOICX','build','2317210ClIwHC'];a31_0x15fe=function(){return _0x5b025e;};return a31_0x15fe();}import{apiCli}from'./api/main.js';function a31_0xef70(_0x5d739a,_0x526bbe){_0x5d739a=_0x5d739a-0xe7;const _0x15fed4=a31_0x15fe();let _0xef707b=_0x15fed4[_0x5d739a];return _0xef707b;}import{AuthServer}from'./auth/auth-server-ui.js';import{logout}from'./auth/logout.js';import{Help}from'./help.js';import{logger}from'./utils/logger.js';import{showLogs,clearLogs}from'./cmd/logs.js';import{AppMenuSyncUI}from'./app-menu/app-menu-sync-ui.js';import{mcpCommand}from'./mcp/main.js';import{AppMenuUpdateCdn}from'./app-menu-update-cdn/main.js';import{skillsCommand}from'./skills/main.js';import{SkillInstallUI}from'./skills/SkillInstallUI.js';import{McpInstallUI}from'./mcp/McpInstallUI.js';const cli=a31_0x4de045(a31_0x534ad3(0x126),{'importMeta':import.meta,'flags':{'name':{'type':a31_0x534ad3(0xfc)},'clear':{'type':a31_0x534ad3(0xf7)},'env':{'type':'string'},'watch':{'type':a31_0x534ad3(0xf7)},'help':{'type':a31_0x534ad3(0xf7)},'appcode':{'type':a31_0x534ad3(0xfc)},'output':{'type':a31_0x534ad3(0xfc)},'params':{'type':a31_0x534ad3(0xfc)},'datasetcode':{'type':a31_0x534ad3(0xfc)},'mcpCursor':{'type':a31_0x534ad3(0xf7)},'mcpClaude':{'type':a31_0x534ad3(0xf7)},'mcpOther':{'type':'boolean'},'cursor':{'type':a31_0x534ad3(0xf7)},'windsurf':{'type':a31_0x534ad3(0xf7)},'claude':{'type':a31_0x534ad3(0xf7)},'codex':{'type':a31_0x534ad3(0xf7)},'opencode':{'type':'boolean'},'qoder':{'type':a31_0x534ad3(0xf7)},'codebuddy':{'type':'boolean'},'trae':{'type':a31_0x534ad3(0xf7)},'agent':{'type':'boolean'},'antigravity':{'type':a31_0x534ad3(0xf7)},'all':{'type':a31_0x534ad3(0xf7)}},'autoVersion':!![]});await run();async function run(){const _0x411265=a31_0x534ad3,_0x579d30=cli[_0x411265(0x10d)][0x0],_0x591ef3=cli[_0x411265(0x10d)][0x1],_0x214db1=cli[_0x411265(0x10d)][0x2],_0x569eea=(_0x411265(0x10c)+process['argv'][_0x411265(0x116)](0x2)[_0x411265(0xe9)]('\x20'))[_0x411265(0xf2)]();logger['setRawCommand'](_0x569eea);switch(_0x579d30){case _0x411265(0x117):{const _0x117519=cli[_0x411265(0x125)]['appcode'],_0x275541=cli[_0x411265(0x125)][_0x411265(0xf9)];logger[_0x411265(0xf3)](process['cwd']()),logger[_0x411265(0x114)](_0x411265(0x117),_0x411265(0x120)),render(a31_0x3ce456(Init,{'appcode':_0x117519,'env':_0x275541}));break;}case _0x411265(0x105):{const _0x40e2ee=cli[_0x411265(0x10d)][0x1]?.['trim'](),_0x4563be=cli[_0x411265(0x125)][_0x411265(0xf9)];render(a31_0x3ce456(CreateApp,{'projectCode':_0x40e2ee,'env':_0x4563be}));break;}case'add':{cli[_0x411265(0x10d)][0x1]===_0x411265(0x108)&&(logger[_0x411265(0xf3)](process[_0x411265(0xff)]()),logger[_0x411265(0x114)](_0x411265(0x10a),'执行添加页面命令'),render(a31_0x3ce456(AddPage,{})));break;}case _0x411265(0x11d):{try{logger[_0x411265(0xf3)](process[_0x411265(0xff)]()),logger[_0x411265(0x114)](_0x411265(0x11d),_0x411265(0x115)),await runStart();}catch(_0x4870b5){console[_0x411265(0x111)](_0x4870b5),process[_0x411265(0x127)](0x1);}break;}case _0x411265(0xee):{try{logger['setLogPath'](process[_0x411265(0xff)]()),logger[_0x411265(0x114)](_0x411265(0xee),_0x411265(0x121)),await runBuild();}catch(_0x3b14ad){console[_0x411265(0x111)](_0x3b14ad),process['exit'](0x1);}break;}case'preview':{const _0x1d971c=cli['flags']['watch'];logger[_0x411265(0xf3)](process[_0x411265(0xff)]()),logger['info'](_0x411265(0x122),_0x411265(0x124)+(_0x1d971c?_0x411265(0x109):''));if(_0x1d971c)try{await Promise[_0x411265(0x11b)]([runBuildWatch(),runPreview()]);}catch(_0x28e55d){console[_0x411265(0x111)](_0x28e55d),process[_0x411265(0x127)](0x1);}else try{await runPreview();}catch(_0x12147e){console['error'](_0x12147e),process[_0x411265(0x127)](0x1);}break;}case'config':{render(a31_0x3ce456(Config,{'cli':cli}));break;}case _0x411265(0xf1):{await apiCli(cli);break;}case _0x411265(0x10e):{render(a31_0x3ce456(AuthServer,{}));break;}case'menu':{if(_0x591ef3===_0x411265(0xfa)){logger[_0x411265(0xf3)](process[_0x411265(0xff)]()),logger[_0x411265(0x114)]('menu-update-cdn','执行更新菜单\x20CDN\x20资源命令'),render(a31_0x3ce456(AppMenuUpdateCdn,{}));break;}else logger['setLogPath'](process[_0x411265(0xff)]()),logger['info'](_0x411265(0x11e),'同步菜单命令'),render(a31_0x3ce456(AppMenuSyncUI,{}));break;}case _0x411265(0xf0):{logout();break;}case _0x411265(0x110):{const _0x18bf4e=cli[_0x411265(0x10d)][0x1];logger[_0x411265(0xf3)](process['cwd']());if(_0x18bf4e===_0x411265(0x128)){const _0x49032d=[];if(cli[_0x411265(0x125)][_0x411265(0xfd)])_0x49032d[_0x411265(0x103)](_0x411265(0xf5));if(cli[_0x411265(0x125)][_0x411265(0x11c)])_0x49032d[_0x411265(0x103)](_0x411265(0x11f));if(cli[_0x411265(0x125)][_0x411265(0xf4)])_0x49032d[_0x411265(0x103)](_0x411265(0xe7));logger[_0x411265(0x114)](_0x411265(0x112),_0x411265(0x113),{'preselected':_0x49032d}),render(a31_0x3ce456(McpInstallUI,{'preselectedIDEs':_0x49032d}));}else _0x18bf4e===_0x411265(0x10f)||cli['flags']['help']?await mcpCommand(_0x18bf4e,[],{'help':!![]}):await mcpCommand(_0x18bf4e,[],cli['flags']);break;}case _0x411265(0x107):{const _0x5dee71=cli['input'][0x1];logger['setLogPath'](process[_0x411265(0xff)]());if(_0x5dee71==='install'){const _0x1ce7a8=[];if(cli[_0x411265(0x125)][_0x411265(0x11b)])_0x1ce7a8[_0x411265(0x103)]('cursor',_0x411265(0x104),_0x411265(0x11f),_0x411265(0xea),_0x411265(0xf6),_0x411265(0x101),_0x411265(0x118),_0x411265(0x100),'agent',_0x411265(0xfe));else{if(cli['flags'][_0x411265(0xf5)])_0x1ce7a8[_0x411265(0x103)](_0x411265(0xf5));if(cli[_0x411265(0x125)][_0x411265(0x104)])_0x1ce7a8[_0x411265(0x103)]('windsurf');if(cli[_0x411265(0x125)][_0x411265(0x11f)])_0x1ce7a8['push']('claude');if(cli[_0x411265(0x125)][_0x411265(0xea)])_0x1ce7a8[_0x411265(0x103)](_0x411265(0xea));if(cli[_0x411265(0x125)]['opencode'])_0x1ce7a8[_0x411265(0x103)]('opencode');if(cli[_0x411265(0x125)][_0x411265(0x101)])_0x1ce7a8[_0x411265(0x103)]('qoder');if(cli[_0x411265(0x125)]['codebuddy'])_0x1ce7a8[_0x411265(0x103)]('codebuddy');if(cli[_0x411265(0x125)]['trae'])_0x1ce7a8['push'](_0x411265(0x100));if(cli[_0x411265(0x125)][_0x411265(0xeb)])_0x1ce7a8['push'](_0x411265(0xeb));if(cli['flags'][_0x411265(0xfe)])_0x1ce7a8['push'](_0x411265(0xfe));}logger[_0x411265(0x114)]('skill-install',_0x411265(0x119),{'preselected':_0x1ce7a8}),render(a31_0x3ce456(SkillInstallUI,{'preselectedIDEs':_0x1ce7a8}));}else _0x5dee71===_0x411265(0x10f)||cli[_0x411265(0x125)]['help']?await skillsCommand(_0x5dee71,[],{'help':!![]}):await skillsCommand(_0x5dee71,[],cli[_0x411265(0x125)]);break;}case'logs':{cli[_0x411265(0x125)][_0x411265(0x11a)]?clearLogs():showLogs();break;}default:render(a31_0x3ce456(Help,{}));break;}}
@@ -1 +1 @@
1
- (function(_0x18b1d9,_0x4cbe3a){const _0x334580=a32_0x7e9a,_0x575036=_0x18b1d9();while(!![]){try{const _0x4d38ed=-parseInt(_0x334580(0x19b))/0x1*(-parseInt(_0x334580(0x193))/0x2)+-parseInt(_0x334580(0x197))/0x3+-parseInt(_0x334580(0x1a0))/0x4+-parseInt(_0x334580(0x1a1))/0x5+-parseInt(_0x334580(0x198))/0x6+-parseInt(_0x334580(0x19f))/0x7+parseInt(_0x334580(0x195))/0x8;if(_0x4d38ed===_0x4cbe3a)break;else _0x575036['push'](_0x575036['shift']());}catch(_0x5510c6){_0x575036['push'](_0x575036['shift']());}}}(a32_0x4122,0xe28bf));function a32_0x7e9a(_0x5dcd65,_0x5c6237){_0x5dcd65=_0x5dcd65-0x193;const _0x4122bc=a32_0x4122();let _0x7e9a14=_0x4122bc[_0x5dcd65];return _0x7e9a14;}import{spawn}from'node:child_process';function a32_0x4122(){const _0x4ef17d=['PATH','234943WrOBGX','node_modules','--watch','build','1518321JQYyiz','2013532thUCsk','6495305rJRLLI','npm\x20run\x20build\x20exited\x20with\x20code\x20','4TLyQzo','cwd','44455416jJFGFE','vite','3729990MVyVxz','11017206UCuCHM','error'];a32_0x4122=function(){return _0x4ef17d;};return a32_0x4122();}import{delimiter,join}from'node:path';export function runBuildWatch(){return new Promise((_0x527e4f,_0xdd535c)=>{const _0x31d744=a32_0x7e9a,_0x3ece4d=spawn(_0x31d744(0x196),[_0x31d744(0x19e),_0x31d744(0x19d)],{'stdio':'inherit','shell':!![],'env':{...process['env'],'PATH':''+join(process[_0x31d744(0x194)](),_0x31d744(0x19c),'.bin')+delimiter+process['env'][_0x31d744(0x19a)]}});_0x3ece4d['on']('close',_0x3c36fa=>{const _0x460fbc=_0x31d744;if(_0x3c36fa===0x0||_0x3c36fa===null)_0x527e4f();else _0xdd535c(new Error(_0x460fbc(0x1a2)+_0x3c36fa));}),_0x3ece4d['on'](_0x31d744(0x199),_0xdd535c);});}
1
+ (function(_0x2681f5,_0x14b7ac){const _0x322ca9=a32_0x4045,_0x4fb813=_0x2681f5();while(!![]){try{const _0xe1dc7=parseInt(_0x322ca9(0xc4))/0x1*(-parseInt(_0x322ca9(0xc2))/0x2)+-parseInt(_0x322ca9(0xbd))/0x3*(parseInt(_0x322ca9(0xbf))/0x4)+parseInt(_0x322ca9(0xbc))/0x5+-parseInt(_0x322ca9(0xc6))/0x6+parseInt(_0x322ca9(0xcc))/0x7+parseInt(_0x322ca9(0xc3))/0x8+parseInt(_0x322ca9(0xcd))/0x9*(parseInt(_0x322ca9(0xca))/0xa);if(_0xe1dc7===_0x14b7ac)break;else _0x4fb813['push'](_0x4fb813['shift']());}catch(_0x283939){_0x4fb813['push'](_0x4fb813['shift']());}}}(a32_0x144d,0xcaf21));function a32_0x4045(_0x4cf10e,_0x3c48dc){_0x4cf10e=_0x4cf10e-0xbb;const _0x144d09=a32_0x144d();let _0x4045be=_0x144d09[_0x4cf10e];return _0x4045be;}import{spawn}from'node:child_process';import{delimiter,join}from'node:path';export function runBuildWatch(){return new Promise((_0x4f51e7,_0x43b46b)=>{const _0x5bb3ba=a32_0x4045,_0x24d09a=spawn(_0x5bb3ba(0xbe),[_0x5bb3ba(0xc5),'--watch'],{'stdio':_0x5bb3ba(0xcb),'shell':!![],'env':{...process[_0x5bb3ba(0xc1)],'PATH':''+join(process[_0x5bb3ba(0xbb)](),'node_modules',_0x5bb3ba(0xc0))+delimiter+process[_0x5bb3ba(0xc1)][_0x5bb3ba(0xc8)]}});_0x24d09a['on'](_0x5bb3ba(0xc9),_0x3ebd0f=>{const _0x102fc2=_0x5bb3ba;if(_0x3ebd0f===0x0||_0x3ebd0f===null)_0x4f51e7();else _0x43b46b(new Error(_0x102fc2(0xc7)+_0x3ebd0f));}),_0x24d09a['on']('error',_0x43b46b);});}function a32_0x144d(){const _0x10d27f=['env','218dtqCIg','11700888SWgWkb','10373fpJPYu','build','1737252HqSBKT','npm\x20run\x20build\x20exited\x20with\x20code\x20','PATH','close','10reeRAH','inherit','4396273bavioE','3574521hVsJOD','cwd','3177545yFkMLo','84mNRMRq','vite','124552LbpmsH','.bin'];a32_0x144d=function(){return _0x10d27f;};return a32_0x144d();}
package/lib/cmd/build.js CHANGED
@@ -1 +1 @@
1
- (function(_0x4600e0,_0x3417ab){const _0x4d5a59=a33_0x4f3b,_0x56780b=_0x4600e0();while(!![]){try{const _0x381faa=-parseInt(_0x4d5a59(0x118))/0x1*(-parseInt(_0x4d5a59(0x117))/0x2)+parseInt(_0x4d5a59(0x124))/0x3+-parseInt(_0x4d5a59(0x10a))/0x4+-parseInt(_0x4d5a59(0x10e))/0x5*(parseInt(_0x4d5a59(0x121))/0x6)+-parseInt(_0x4d5a59(0x122))/0x7+parseInt(_0x4d5a59(0x120))/0x8+parseInt(_0x4d5a59(0x11b))/0x9;if(_0x381faa===_0x3417ab)break;else _0x56780b['push'](_0x56780b['shift']());}catch(_0x94c86e){_0x56780b['push'](_0x56780b['shift']());}}}(a33_0x5598,0x96f9e));function a33_0x4f3b(_0x141202,_0x18acac){_0x141202=_0x141202-0x10a;const _0x559813=a33_0x5598();let _0x4f3b3e=_0x559813[_0x141202];return _0x4f3b3e;}import{delimiter,join}from'node:path';import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';function a33_0x5598(){const _0x596800=['2dJVDRj','518233rISSeq','error','npm','2542410BOvtpu','cwd','开始构建项目','.bin','pipe','6678440RtiiVX','12294HumPPi','2312352bjktHK','stderr','1826433sdBgKW','npm\x20run\x20build','info','now','trim','3723532lIcEHy','node_modules','run','npm\x20run\x20build\x20exited\x20with\x20code\x20','890mZNJZN','PATH','build','env','项目构建出错','data','inherit','message','success'];a33_0x5598=function(){return _0x596800;};return a33_0x5598();}export function runBuild(){return new Promise((_0x3a2f7b,_0x5238e8)=>{const _0x458e54=a33_0x4f3b,_0x17dbbd=Date[_0x458e54(0x127)]();logger[_0x458e54(0x126)](_0x458e54(0x110),_0x458e54(0x11d),{'command':_0x458e54(0x125)});let _0x20b494='';const _0x3a6e4b=spawn(_0x458e54(0x11a),[_0x458e54(0x10c),_0x458e54(0x110)],{'stdio':[_0x458e54(0x114),_0x458e54(0x114),_0x458e54(0x11f)],'shell':!![],'env':{...process[_0x458e54(0x111)],'PATH':''+join(process[_0x458e54(0x11c)](),_0x458e54(0x10b),_0x458e54(0x11e))+delimiter+process[_0x458e54(0x111)][_0x458e54(0x10f)]}});_0x3a6e4b[_0x458e54(0x123)]?.['on'](_0x458e54(0x113),_0x4810b6=>{_0x20b494+=_0x4810b6['toString']();}),_0x3a6e4b['on']('close',_0x243bb7=>{const _0x332b99=_0x458e54,_0x2718d0=Date[_0x332b99(0x127)]()-_0x17dbbd;if(_0x243bb7===0x0||_0x243bb7===null)logger[_0x332b99(0x116)]('build','项目构建成功',_0x2718d0),_0x3a2f7b();else{const _0x5a8572={'exitCode':_0x243bb7,'duration':_0x2718d0,'command':_0x332b99(0x125),'cwd':process[_0x332b99(0x11c)]()};_0x20b494['trim']()&&(_0x5a8572[_0x332b99(0x123)]=_0x20b494[_0x332b99(0x128)]()),logger[_0x332b99(0x119)](_0x332b99(0x110),'项目构建失败',_0x5a8572),_0x5238e8(new Error(_0x332b99(0x10d)+_0x243bb7));}}),_0x3a6e4b['on'](_0x458e54(0x119),_0x202180=>{const _0x17104e=_0x458e54,_0x58ad02=Date[_0x17104e(0x127)]()-_0x17dbbd;logger['error']('build',_0x17104e(0x112),{'error':_0x202180[_0x17104e(0x115)],'duration':_0x58ad02,'stderr':_0x20b494[_0x17104e(0x128)]()||undefined}),_0x5238e8(_0x202180);});});}
1
+ (function(_0x49cf40,_0x42e63a){const _0x3a4d7f=a33_0x177b,_0x33b846=_0x49cf40();while(!![]){try{const _0x35d4fc=-parseInt(_0x3a4d7f(0xd1))/0x1*(-parseInt(_0x3a4d7f(0xb8))/0x2)+-parseInt(_0x3a4d7f(0xb4))/0x3+parseInt(_0x3a4d7f(0xd0))/0x4+-parseInt(_0x3a4d7f(0xc9))/0x5*(-parseInt(_0x3a4d7f(0xb3))/0x6)+-parseInt(_0x3a4d7f(0xb9))/0x7*(-parseInt(_0x3a4d7f(0xbd))/0x8)+parseInt(_0x3a4d7f(0xbe))/0x9+-parseInt(_0x3a4d7f(0xcb))/0xa*(parseInt(_0x3a4d7f(0xb6))/0xb);if(_0x35d4fc===_0x42e63a)break;else _0x33b846['push'](_0x33b846['shift']());}catch(_0x141031){_0x33b846['push'](_0x33b846['shift']());}}}(a33_0x192e,0xdb374));function a33_0x192e(){const _0x5668ed=['stderr','inherit','npm\x20run\x20build\x20exited\x20with\x20code\x20','error','.bin','PATH','env','项目构建失败','33185nZidjY','cwd','10LkZZvD','npm\x20run\x20build','trim','message','项目构建成功','441244nwtVxP','14099sRVFTQ','438TCgMuO','502212KyZPQO','now','21505044iWJbyb','toString','122SIYnNm','4109XVSjGG','node_modules','info','build','13016zLDjnR','5493744BjdmXN','npm','success'];a33_0x192e=function(){return _0x5668ed;};return a33_0x192e();}import{delimiter,join}from'node:path';import{spawn}from'node:child_process';function a33_0x177b(_0x8fe252,_0x4aa902){_0x8fe252=_0x8fe252-0xb3;const _0x192ef9=a33_0x192e();let _0x177b90=_0x192ef9[_0x8fe252];return _0x177b90;}import{logger}from'../utils/logger.js';export function runBuild(){return new Promise((_0x105ef7,_0x4b4a39)=>{const _0x3129c3=a33_0x177b,_0x2b0f93=Date[_0x3129c3(0xb5)]();logger[_0x3129c3(0xbb)](_0x3129c3(0xbc),'开始构建项目',{'command':_0x3129c3(0xcc)});let _0x17cd5c='';const _0x3dfaf9=spawn(_0x3129c3(0xbf),['run','build'],{'stdio':['inherit',_0x3129c3(0xc2),'pipe'],'shell':!![],'env':{...process[_0x3129c3(0xc7)],'PATH':''+join(process['cwd'](),_0x3129c3(0xba),_0x3129c3(0xc5))+delimiter+process[_0x3129c3(0xc7)][_0x3129c3(0xc6)]}});_0x3dfaf9[_0x3129c3(0xc1)]?.['on']('data',_0x5d5f3e=>{const _0x5cb31d=_0x3129c3;_0x17cd5c+=_0x5d5f3e[_0x5cb31d(0xb7)]();}),_0x3dfaf9['on']('close',_0x2e4123=>{const _0x2ef7fb=_0x3129c3,_0x2a9e17=Date[_0x2ef7fb(0xb5)]()-_0x2b0f93;if(_0x2e4123===0x0||_0x2e4123===null)logger[_0x2ef7fb(0xc0)]('build',_0x2ef7fb(0xcf),_0x2a9e17),_0x105ef7();else{const _0xb9e8f3={'exitCode':_0x2e4123,'duration':_0x2a9e17,'command':'npm\x20run\x20build','cwd':process[_0x2ef7fb(0xca)]()};_0x17cd5c[_0x2ef7fb(0xcd)]()&&(_0xb9e8f3[_0x2ef7fb(0xc1)]=_0x17cd5c['trim']()),logger['error']('build',_0x2ef7fb(0xc8),_0xb9e8f3),_0x4b4a39(new Error(_0x2ef7fb(0xc3)+_0x2e4123));}}),_0x3dfaf9['on']('error',_0x18eab8=>{const _0x35f6ab=_0x3129c3,_0x2d5bf4=Date[_0x35f6ab(0xb5)]()-_0x2b0f93;logger[_0x35f6ab(0xc4)](_0x35f6ab(0xbc),'项目构建出错',{'error':_0x18eab8[_0x35f6ab(0xce)],'duration':_0x2d5bf4,'stderr':_0x17cd5c['trim']()||undefined}),_0x4b4a39(_0x18eab8);});});}
package/lib/cmd/logs.js CHANGED
@@ -1 +1 @@
1
- function a34_0x1450(_0xc32da2,_0x82edf8){_0xc32da2=_0xc32da2-0x70;const _0x5956f2=a34_0x5956();let _0x14500d=_0x5956f2[_0xc32da2];return _0x14500d;}(function(_0x12e7a7,_0x49aaa2){const _0x4b263c=a34_0x1450,_0x4ae245=_0x12e7a7();while(!![]){try{const _0x4a0ccc=-parseInt(_0x4b263c(0x83))/0x1*(-parseInt(_0x4b263c(0x85))/0x2)+parseInt(_0x4b263c(0x7c))/0x3*(parseInt(_0x4b263c(0x86))/0x4)+-parseInt(_0x4b263c(0x77))/0x5+parseInt(_0x4b263c(0x79))/0x6*(-parseInt(_0x4b263c(0x88))/0x7)+-parseInt(_0x4b263c(0x90))/0x8+parseInt(_0x4b263c(0x7a))/0x9*(-parseInt(_0x4b263c(0x8d))/0xa)+-parseInt(_0x4b263c(0x72))/0xb*(-parseInt(_0x4b263c(0x74))/0xc);if(_0x4a0ccc===_0x49aaa2)break;else _0x4ae245['push'](_0x4ae245['shift']());}catch(_0x2cbd23){_0x4ae245['push'](_0x4ae245['shift']());}}}(a34_0x5956,0xe839f));function a34_0x5956(){const _0x498179=['details','forEach','stringify','1177FdnQGO','length','205752cVMOdz','level','clearLogs','5633545lsjoag','log','5991474qXrOJz','459OVPEYB','cwd','207JsqOfz','\x20\x20\x20详情:\x20','duration','*\x20暂无日志记录','keys','readLogs','message','1ycBHGh','error','2279482SIiJyi','74632NeFDad','setLogPath','7mgotwY','timestamp','success','command','\x20\x20\x20耗时:\x20','186470tesNjB','\x20\x20\x20时间:\x20','warn','1874248keNJMy'];a34_0x5956=function(){return _0x498179;};return a34_0x5956();}import{logger}from'../utils/logger.js';export function showLogs(){const _0x307879=a34_0x1450;logger[_0x307879(0x87)](process['cwd']());const _0x62d00c=logger[_0x307879(0x81)]();if(_0x62d00c[_0x307879(0x73)]===0x0){console[_0x307879(0x78)](_0x307879(0x7f));return;}console['log']('*\x20Lovrabet\x20CLI\x20日志记录:\x0a'),_0x62d00c[_0x307879(0x70)]((_0x52da66,_0x25f60c)=>{const _0x2fa9f8=_0x307879,_0x5838b1=new Date(_0x52da66[_0x2fa9f8(0x89)])['toLocaleString']('zh-CN'),_0x314cfd=_0x52da66[_0x2fa9f8(0x75)]===_0x2fa9f8(0x8a)?'√':_0x52da66[_0x2fa9f8(0x75)]===_0x2fa9f8(0x84)?'×':_0x52da66['level']===_0x2fa9f8(0x8f)?'!':'i';console[_0x2fa9f8(0x78)](_0x25f60c+0x1+'.\x20'+_0x314cfd+'\x20['+_0x52da66[_0x2fa9f8(0x8b)]+']\x20'+_0x52da66[_0x2fa9f8(0x82)]),console['log'](_0x2fa9f8(0x8e)+_0x5838b1),_0x52da66[_0x2fa9f8(0x7e)]&&console[_0x2fa9f8(0x78)](_0x2fa9f8(0x8c)+_0x52da66['duration']+'ms'),_0x52da66[_0x2fa9f8(0x91)]&&Object[_0x2fa9f8(0x80)](_0x52da66[_0x2fa9f8(0x91)])['length']>0x0&&console[_0x2fa9f8(0x78)](_0x2fa9f8(0x7d)+JSON[_0x2fa9f8(0x71)](_0x52da66[_0x2fa9f8(0x91)],null,0x2)),console[_0x2fa9f8(0x78)]('');});}export function clearLogs(){const _0x3dc40c=a34_0x1450;logger['setLogPath'](process[_0x3dc40c(0x7b)]()),logger[_0x3dc40c(0x76)](),console['log']('*\x20日志已清空');}
1
+ (function(_0x87fa9e,_0x9d209a){const _0x48d4ed=a34_0x1b54,_0xa85775=_0x87fa9e();while(!![]){try{const _0x40a171=parseInt(_0x48d4ed(0x121))/0x1+parseInt(_0x48d4ed(0x128))/0x2*(parseInt(_0x48d4ed(0x113))/0x3)+parseInt(_0x48d4ed(0x116))/0x4+-parseInt(_0x48d4ed(0x111))/0x5+-parseInt(_0x48d4ed(0x127))/0x6+parseInt(_0x48d4ed(0x115))/0x7+-parseInt(_0x48d4ed(0x10d))/0x8*(parseInt(_0x48d4ed(0x10e))/0x9);if(_0x40a171===_0x9d209a)break;else _0xa85775['push'](_0xa85775['shift']());}catch(_0x2fc221){_0xa85775['push'](_0xa85775['shift']());}}}(a34_0x4a5e,0xe7d93));import{logger}from'../utils/logger.js';export function showLogs(){const _0x19fe0d=a34_0x1b54;logger[_0x19fe0d(0x110)](process['cwd']());const _0x888667=logger[_0x19fe0d(0x119)]();if(_0x888667['length']===0x0){console['log']('*\x20暂无日志记录');return;}console[_0x19fe0d(0x126)](_0x19fe0d(0x112)),_0x888667[_0x19fe0d(0x120)]((_0x2e96fc,_0x841098)=>{const _0x41cfa3=_0x19fe0d,_0x48f19c=new Date(_0x2e96fc[_0x41cfa3(0x114)])[_0x41cfa3(0x125)](_0x41cfa3(0x123)),_0x154286=_0x2e96fc[_0x41cfa3(0x124)]===_0x41cfa3(0x12a)?'√':_0x2e96fc[_0x41cfa3(0x124)]===_0x41cfa3(0x11a)?'×':_0x2e96fc[_0x41cfa3(0x124)]===_0x41cfa3(0x11e)?'!':'i';console[_0x41cfa3(0x126)](_0x841098+0x1+'.\x20'+_0x154286+'\x20['+_0x2e96fc['command']+']\x20'+_0x2e96fc[_0x41cfa3(0x11d)]),console['log'](_0x41cfa3(0x122)+_0x48f19c),_0x2e96fc[_0x41cfa3(0x10f)]&&console['log']('\x20\x20\x20耗时:\x20'+_0x2e96fc[_0x41cfa3(0x10f)]+'ms'),_0x2e96fc[_0x41cfa3(0x117)]&&Object[_0x41cfa3(0x118)](_0x2e96fc['details'])[_0x41cfa3(0x11f)]>0x0&&console[_0x41cfa3(0x126)]('\x20\x20\x20详情:\x20'+JSON[_0x41cfa3(0x11b)](_0x2e96fc['details'],null,0x2)),console[_0x41cfa3(0x126)]('');});}function a34_0x4a5e(){const _0x206384=['\x20\x20\x20时间:\x20','zh-CN','level','toLocaleString','log','6280260jLCcDQ','619146RErMnu','clearLogs','success','17786504wxSZbQ','9qtGaMG','duration','setLogPath','3672800LAXDbz','*\x20Lovrabet\x20CLI\x20日志记录:\x0a','15raLtRE','timestamp','11005701XZIJUF','541720PHlDum','details','keys','readLogs','error','stringify','*\x20日志已清空','message','warn','length','forEach','1698696BnbOCI'];a34_0x4a5e=function(){return _0x206384;};return a34_0x4a5e();}function a34_0x1b54(_0x1cadae,_0x3d4852){_0x1cadae=_0x1cadae-0x10d;const _0x4a5e77=a34_0x4a5e();let _0x1b54ab=_0x4a5e77[_0x1cadae];return _0x1b54ab;}export function clearLogs(){const _0x4ad863=a34_0x1b54;logger[_0x4ad863(0x110)](process['cwd']()),logger[_0x4ad863(0x129)](),console[_0x4ad863(0x126)](_0x4ad863(0x11c));}
@@ -1 +1 @@
1
- (function(_0xaf48ed,_0x5b79c1){const _0x513d09=a35_0x562f,_0x1f2114=_0xaf48ed();while(!![]){try{const _0x5cbfcd=-parseInt(_0x513d09(0x9b))/0x1*(parseInt(_0x513d09(0x8a))/0x2)+-parseInt(_0x513d09(0xa6))/0x3*(parseInt(_0x513d09(0x8f))/0x4)+-parseInt(_0x513d09(0x9d))/0x5*(parseInt(_0x513d09(0xa7))/0x6)+parseInt(_0x513d09(0x96))/0x7+parseInt(_0x513d09(0x88))/0x8*(-parseInt(_0x513d09(0x9c))/0x9)+parseInt(_0x513d09(0x94))/0xa+parseInt(_0x513d09(0xa5))/0xb;if(_0x5cbfcd===_0x5b79c1)break;else _0x1f2114['push'](_0x1f2114['shift']());}catch(_0x54cdc4){_0x1f2114['push'](_0x1f2114['shift']());}}}(a35_0x3293,0xec6a2));function a35_0x562f(_0x4a2a67,_0x16c9e2){_0x4a2a67=_0x4a2a67-0x88;const _0x32938e=a35_0x3293();let _0x562f8b=_0x32938e[_0x4a2a67];return _0x562f8b;}function a35_0x3293(){const _0x2fefc9=['vite','vite\x20preview','env','预览服务器启动出错','756AkoeFA','now','message','.bin','stderr','13922380hPTMVn','vite\x20preview\x20exited\x20with\x20code\x20','9512699mfNVmP','data','preview','cwd','close','97vklwWT','9585MsEBWU','265oEOGCY','error','success','预览服务器启动失败','info','启动预览服务器','node_modules','trim','25931422PMJJTP','14001LdFJNi','194730NCYJSk','inherit','7240EbnOdk','预览服务器启动成功','11840kuBXJL'];a35_0x3293=function(){return _0x2fefc9;};return a35_0x3293();}import{delimiter,join}from'node:path';import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';export function runPreview(){return new Promise((_0x13cdb0,_0x451c55)=>{const _0x2f810d=a35_0x562f,_0xfd2be3=Date[_0x2f810d(0x90)]();logger[_0x2f810d(0xa1)](_0x2f810d(0x98),_0x2f810d(0xa2),{'command':_0x2f810d(0x8c)});let _0x92607d='';const _0x5317a5=spawn(_0x2f810d(0x8b),[_0x2f810d(0x98)],{'stdio':['inherit',_0x2f810d(0xa8),'pipe'],'shell':!![],'env':{...process['env'],'PATH':''+join(process[_0x2f810d(0x99)](),_0x2f810d(0xa3),_0x2f810d(0x92))+delimiter+process[_0x2f810d(0x8d)]['PATH']}});_0x5317a5[_0x2f810d(0x93)]?.['on'](_0x2f810d(0x97),_0x300807=>{_0x92607d+=_0x300807['toString']();}),_0x5317a5['on'](_0x2f810d(0x9a),_0x36fc4d=>{const _0x401d47=_0x2f810d,_0xb06249=Date[_0x401d47(0x90)]()-_0xfd2be3;if(_0x36fc4d===0x0||_0x36fc4d===null)logger[_0x401d47(0x9f)]('preview',_0x401d47(0x89),_0xb06249),_0x13cdb0();else{const _0x47cf81={'exitCode':_0x36fc4d,'duration':_0xb06249,'command':'vite\x20preview','cwd':process[_0x401d47(0x99)]()};_0x92607d[_0x401d47(0xa4)]()&&(_0x47cf81['stderr']=_0x92607d[_0x401d47(0xa4)]()),logger[_0x401d47(0x9e)](_0x401d47(0x98),_0x401d47(0xa0),_0x47cf81),_0x451c55(new Error(_0x401d47(0x95)+_0x36fc4d));}}),_0x5317a5['on'](_0x2f810d(0x9e),_0x4bf9ee=>{const _0x328551=_0x2f810d,_0x34bb03=Date[_0x328551(0x90)]()-_0xfd2be3;logger[_0x328551(0x9e)](_0x328551(0x98),_0x328551(0x8e),{'error':_0x4bf9ee[_0x328551(0x91)],'duration':_0x34bb03,'stderr':_0x92607d[_0x328551(0xa4)]()||undefined}),_0x451c55(_0x4bf9ee);});});}
1
+ (function(_0x552fde,_0x4b651e){const _0x16e789=a35_0xb597,_0x84ef81=_0x552fde();while(!![]){try{const _0x254994=parseInt(_0x16e789(0x198))/0x1*(parseInt(_0x16e789(0x18e))/0x2)+-parseInt(_0x16e789(0x18a))/0x3+-parseInt(_0x16e789(0x187))/0x4+parseInt(_0x16e789(0x19d))/0x5+-parseInt(_0x16e789(0x1a1))/0x6*(-parseInt(_0x16e789(0x18c))/0x7)+-parseInt(_0x16e789(0x193))/0x8*(parseInt(_0x16e789(0x186))/0x9)+-parseInt(_0x16e789(0x19e))/0xa;if(_0x254994===_0x4b651e)break;else _0x84ef81['push'](_0x84ef81['shift']());}catch(_0x4ba603){_0x84ef81['push'](_0x84ef81['shift']());}}}(a35_0x1c46,0xb49dc));import{delimiter,join}from'node:path';import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';function a35_0xb597(_0x3d661c,_0x1809e0){_0x3d661c=_0x3d661c-0x186;const _0x1c46b9=a35_0x1c46();let _0xb59786=_0x1c46b9[_0x3d661c];return _0xb59786;}function a35_0x1c46(){const _0x22d717=['30720jluONP','stderr','预览服务器启动出错','preview','message','11tQqjxz','预览服务器启动成功','now','env','vite','2347195BplPtt','6017700ehfXIc','vite\x20preview','info','786WAMqvi','666OZhpbl','1396080HOxEuq','vite\x20preview\x20exited\x20with\x20code\x20','inherit','96504VcQAws','error','34636GcTHCo','success','161690Xlxfbn','启动预览服务器','node_modules','trim','pipe'];a35_0x1c46=function(){return _0x22d717;};return a35_0x1c46();}export function runPreview(){return new Promise((_0x366137,_0x542c19)=>{const _0x2f2da5=a35_0xb597,_0x337cc8=Date[_0x2f2da5(0x19a)]();logger[_0x2f2da5(0x1a0)](_0x2f2da5(0x196),_0x2f2da5(0x18f),{'command':_0x2f2da5(0x19f)});let _0x28d7f3='';const _0x2dcc4b=spawn(_0x2f2da5(0x19c),[_0x2f2da5(0x196)],{'stdio':['inherit',_0x2f2da5(0x189),_0x2f2da5(0x192)],'shell':!![],'env':{...process[_0x2f2da5(0x19b)],'PATH':''+join(process['cwd'](),_0x2f2da5(0x190),'.bin')+delimiter+process[_0x2f2da5(0x19b)]['PATH']}});_0x2dcc4b[_0x2f2da5(0x194)]?.['on']('data',_0x566430=>{_0x28d7f3+=_0x566430['toString']();}),_0x2dcc4b['on']('close',_0x2f8850=>{const _0x5cf871=_0x2f2da5,_0x5ed38a=Date['now']()-_0x337cc8;if(_0x2f8850===0x0||_0x2f8850===null)logger[_0x5cf871(0x18d)](_0x5cf871(0x196),_0x5cf871(0x199),_0x5ed38a),_0x366137();else{const _0x2e4ba5={'exitCode':_0x2f8850,'duration':_0x5ed38a,'command':_0x5cf871(0x19f),'cwd':process['cwd']()};_0x28d7f3[_0x5cf871(0x191)]()&&(_0x2e4ba5[_0x5cf871(0x194)]=_0x28d7f3[_0x5cf871(0x191)]()),logger[_0x5cf871(0x18b)](_0x5cf871(0x196),'预览服务器启动失败',_0x2e4ba5),_0x542c19(new Error(_0x5cf871(0x188)+_0x2f8850));}}),_0x2dcc4b['on'](_0x2f2da5(0x18b),_0x29e738=>{const _0x27be55=_0x2f2da5,_0x201179=Date[_0x27be55(0x19a)]()-_0x337cc8;logger[_0x27be55(0x18b)]('preview',_0x27be55(0x195),{'error':_0x29e738[_0x27be55(0x197)],'duration':_0x201179,'stderr':_0x28d7f3[_0x27be55(0x191)]()||undefined}),_0x542c19(_0x29e738);});});}
package/lib/cmd/start.js CHANGED
@@ -1 +1 @@
1
- (function(_0x35de44,_0x165bed){const _0x31fc0b=a36_0x290d,_0x411e74=_0x35de44();while(!![]){try{const _0x9aac8f=parseInt(_0x31fc0b(0x1ab))/0x1*(parseInt(_0x31fc0b(0x1b6))/0x2)+-parseInt(_0x31fc0b(0x1cd))/0x3+parseInt(_0x31fc0b(0x1ce))/0x4*(parseInt(_0x31fc0b(0x1c4))/0x5)+parseInt(_0x31fc0b(0x1af))/0x6+parseInt(_0x31fc0b(0x1cc))/0x7+-parseInt(_0x31fc0b(0x1b7))/0x8*(-parseInt(_0x31fc0b(0x1c5))/0x9)+parseInt(_0x31fc0b(0x1bc))/0xa*(-parseInt(_0x31fc0b(0x1cf))/0xb);if(_0x9aac8f===_0x165bed)break;else _0x411e74['push'](_0x411e74['shift']());}catch(_0x2369ae){_0x411e74['push'](_0x411e74['shift']());}}}(a36_0x2bc0,0xcdf68));function a36_0x2bc0(){const _0x469c24=['minVersion','trim','message','5hUtyNG','234288BvDKzt','needsUpgrade','data','now','start','开发服务器启动出错','info','216321FZAOdc','3314187ZkKuZM','5034248erjDiH','10187188cVzeeE','422439OcXnea','cwd','vite\x20exited\x20with\x20code\x20','vite','1040046aQiUOP','version','inherit','SDK\x20版本低于推荐版本','.bin','error','success','2DueFJO','304FYLwst','PATH','warn','pipe','stderr','10qwOsRh','close','开发服务器启动成功','write','env'];a36_0x2bc0=function(){return _0x469c24;};return a36_0x2bc0();}import{delimiter,join}from'node:path';import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';function a36_0x290d(_0x436c36,_0x58bd54){_0x436c36=_0x436c36-0x1ab;const _0x2bc09b=a36_0x2bc0();let _0x290dcc=_0x2bc09b[_0x436c36];return _0x290dcc;}import{checkSdkVersion,printSdkUpgradeWarning}from'../utils/check-sdk-version.js';export function runStart(_0x348151){return new Promise((_0x588fcf,_0x587175)=>{const _0x587f56=a36_0x290d,_0x527364=Date['now'](),_0x430048=_0x348151||process[_0x587f56(0x1ac)](),_0x2a7064=checkSdkVersion(_0x430048);_0x2a7064[_0x587f56(0x1c6)]&&(printSdkUpgradeWarning(_0x2a7064),logger[_0x587f56(0x1b9)](_0x587f56(0x1c9),_0x587f56(0x1b2),{'currentVersion':_0x2a7064[_0x587f56(0x1b0)],'minVersion':_0x2a7064[_0x587f56(0x1c1)]}));logger[_0x587f56(0x1cb)](_0x587f56(0x1c9),'启动开发服务器',{'command':_0x587f56(0x1ae),'cwd':_0x430048});let _0x2c9b39='';const _0x5b32a8=spawn(_0x587f56(0x1ae),{'stdio':['inherit',_0x587f56(0x1b1),_0x587f56(0x1ba)],'shell':!![],'cwd':_0x430048,'env':{...process['env'],'PATH':''+join(_0x430048,'node_modules',_0x587f56(0x1b3))+delimiter+process[_0x587f56(0x1c0)][_0x587f56(0x1b8)]}});_0x5b32a8[_0x587f56(0x1bb)]?.['on'](_0x587f56(0x1c7),_0x5d9edc=>{const _0x5373f3=_0x587f56,_0x17ba2a=_0x5d9edc['toString']();_0x2c9b39+=_0x17ba2a,process['stderr'][_0x5373f3(0x1bf)](_0x17ba2a);}),_0x5b32a8['on'](_0x587f56(0x1bd),_0x2d1e02=>{const _0x1f28dc=_0x587f56,_0x88a9b5=Date[_0x1f28dc(0x1c8)]()-_0x527364;if(_0x2d1e02===0x0||_0x2d1e02===null)logger[_0x1f28dc(0x1b5)](_0x1f28dc(0x1c9),_0x1f28dc(0x1be),_0x88a9b5),_0x588fcf();else{const _0x16750f={'exitCode':_0x2d1e02,'duration':_0x88a9b5,'command':_0x1f28dc(0x1ae),'cwd':_0x430048};_0x2c9b39[_0x1f28dc(0x1c2)]()&&(_0x16750f[_0x1f28dc(0x1bb)]=_0x2c9b39[_0x1f28dc(0x1c2)]()),logger[_0x1f28dc(0x1b4)]('start','开发服务器启动失败',_0x16750f),_0x587175(new Error(_0x1f28dc(0x1ad)+_0x2d1e02));}}),_0x5b32a8['on'](_0x587f56(0x1b4),_0xaecafe=>{const _0x49e727=_0x587f56,_0x585528=Date['now']()-_0x527364,_0x47b26b={'error':_0xaecafe[_0x49e727(0x1c3)],'duration':_0x585528,'command':_0x49e727(0x1ae),'cwd':_0x430048};_0x2c9b39['trim']()&&(_0x47b26b['stderr']=_0x2c9b39['trim']()),logger[_0x49e727(0x1b4)]('start',_0x49e727(0x1ca),_0x47b26b),_0x587175(_0xaecafe);});});}
1
+ function a36_0xd12a(_0x4f8bdd,_0x15122e){_0x4f8bdd=_0x4f8bdd-0x14f;const _0x4b948f=a36_0x4b94();let _0xd12a61=_0x4b948f[_0x4f8bdd];return _0xd12a61;}(function(_0x53dd64,_0x539eca){const _0x5179a3=a36_0xd12a,_0x4e0b89=_0x53dd64();while(!![]){try{const _0x38163f=-parseInt(_0x5179a3(0x15b))/0x1+-parseInt(_0x5179a3(0x150))/0x2*(parseInt(_0x5179a3(0x16b))/0x3)+-parseInt(_0x5179a3(0x14f))/0x4+parseInt(_0x5179a3(0x165))/0x5*(-parseInt(_0x5179a3(0x153))/0x6)+parseInt(_0x5179a3(0x15a))/0x7+parseInt(_0x5179a3(0x168))/0x8+parseInt(_0x5179a3(0x15f))/0x9;if(_0x38163f===_0x539eca)break;else _0x4e0b89['push'](_0x4e0b89['shift']());}catch(_0x2df672){_0x4e0b89['push'](_0x4e0b89['shift']());}}}(a36_0x4b94,0x93019));import{delimiter,join}from'node:path';function a36_0x4b94(){const _0x162bb2=['70502pVClBN','success','start','642222wUqTbM','inherit','write','toString','now','env','data','6139574apyyHA','449413FMdQUn','trim','stderr','开发服务器启动出错','22796082siTqzp','vite\x20exited\x20with\x20code\x20','minVersion','close','message','vite','45KZTFaZ','开发服务器启动失败','error','5462600MXCMJx','warn','开发服务器启动成功','96ZXbsWO','pipe','cwd','3799560JeIZYv'];a36_0x4b94=function(){return _0x162bb2;};return a36_0x4b94();}import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';import{checkSdkVersion,printSdkUpgradeWarning}from'../utils/check-sdk-version.js';export function runStart(_0x452171){return new Promise((_0x1f687b,_0xebfb62)=>{const _0x140e5b=a36_0xd12a,_0x54749b=Date['now'](),_0x4c8479=_0x452171||process[_0x140e5b(0x16d)](),_0x42bdb9=checkSdkVersion(_0x4c8479);_0x42bdb9['needsUpgrade']&&(printSdkUpgradeWarning(_0x42bdb9),logger[_0x140e5b(0x169)](_0x140e5b(0x152),'SDK\x20版本低于推荐版本',{'currentVersion':_0x42bdb9['version'],'minVersion':_0x42bdb9[_0x140e5b(0x161)]}));logger['info'](_0x140e5b(0x152),'启动开发服务器',{'command':_0x140e5b(0x164),'cwd':_0x4c8479});let _0x599605='';const _0x533dce=spawn(_0x140e5b(0x164),{'stdio':[_0x140e5b(0x154),_0x140e5b(0x154),_0x140e5b(0x16c)],'shell':!![],'cwd':_0x4c8479,'env':{...process[_0x140e5b(0x158)],'PATH':''+join(_0x4c8479,'node_modules','.bin')+delimiter+process['env']['PATH']}});_0x533dce[_0x140e5b(0x15d)]?.['on'](_0x140e5b(0x159),_0x4d7cfb=>{const _0x215187=_0x140e5b,_0x161aa1=_0x4d7cfb[_0x215187(0x156)]();_0x599605+=_0x161aa1,process[_0x215187(0x15d)][_0x215187(0x155)](_0x161aa1);}),_0x533dce['on'](_0x140e5b(0x162),_0xda695=>{const _0x486fb3=_0x140e5b,_0x17136a=Date['now']()-_0x54749b;if(_0xda695===0x0||_0xda695===null)logger[_0x486fb3(0x151)](_0x486fb3(0x152),_0x486fb3(0x16a),_0x17136a),_0x1f687b();else{const _0x632cb2={'exitCode':_0xda695,'duration':_0x17136a,'command':_0x486fb3(0x164),'cwd':_0x4c8479};_0x599605[_0x486fb3(0x15c)]()&&(_0x632cb2[_0x486fb3(0x15d)]=_0x599605[_0x486fb3(0x15c)]()),logger[_0x486fb3(0x167)](_0x486fb3(0x152),_0x486fb3(0x166),_0x632cb2),_0xebfb62(new Error(_0x486fb3(0x160)+_0xda695));}}),_0x533dce['on'](_0x140e5b(0x167),_0x355dd8=>{const _0x1056d9=_0x140e5b,_0x4b1d59=Date[_0x1056d9(0x157)]()-_0x54749b,_0x4c7e00={'error':_0x355dd8[_0x1056d9(0x163)],'duration':_0x4b1d59,'command':_0x1056d9(0x164),'cwd':_0x4c8479};_0x599605[_0x1056d9(0x15c)]()&&(_0x4c7e00[_0x1056d9(0x15d)]=_0x599605['trim']()),logger[_0x1056d9(0x167)]('start',_0x1056d9(0x15e),_0x4c7e00),_0xebfb62(_0x355dd8);});});}
@@ -1 +1 @@
1
- function a37_0x3c24(_0x36a93a,_0x502de0){_0x36a93a=_0x36a93a-0x1b3;const _0x2570e6=a37_0x2570();let _0x3c2424=_0x2570e6[_0x36a93a];return _0x3c2424;}(function(_0x25614a,_0x318a21){const _0x57fd36=a37_0x3c24,_0x2c545e=_0x25614a();while(!![]){try{const _0x27cc02=parseInt(_0x57fd36(0x1c5))/0x1*(-parseInt(_0x57fd36(0x1c1))/0x2)+-parseInt(_0x57fd36(0x1b6))/0x3*(-parseInt(_0x57fd36(0x1c9))/0x4)+-parseInt(_0x57fd36(0x1c3))/0x5+-parseInt(_0x57fd36(0x1b4))/0x6*(parseInt(_0x57fd36(0x1ca))/0x7)+parseInt(_0x57fd36(0x1b3))/0x8*(-parseInt(_0x57fd36(0x1bc))/0x9)+-parseInt(_0x57fd36(0x1c7))/0xa*(-parseInt(_0x57fd36(0x1cb))/0xb)+parseInt(_0x57fd36(0x1ba))/0xc;if(_0x27cc02===_0x318a21)break;else _0x2c545e['push'](_0x2c545e['shift']());}catch(_0x4b9a27){_0x2c545e['push'](_0x2c545e['shift']());}}}(a37_0x2570,0xd6d48));function a37_0x2570(){const _0x1c8b9b=['lovrabet\x20config\x20set\x20app\x20app-xxxxx\x20\x20\x20','3735kyOBWu','description','\x20*\x20配置示例:','gray','lovrabet\x20config\x20set\x20env\x20daily\x20\x20\x20\x20\x20\x20\x20','6YmmfRI','配置当前项目的\x20App\x20Code','4341555HgphjC','lovrabet\x20config\x20set\x20<key>\x20<value>\x20\x20\x20','243781ihyIWY','\x20\x20\x20\x20','54690OChfhq','获取配置项','4EhPOWv','246778sOzEcU','638nCRweU','lovrabet\x20config\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','22472lOotau','150WqrsQE','command','3807417SDsXYz','列出所有配置项','column','map','35284104MMfsdU'];a37_0x2570=function(){return _0x1c8b9b;};return a37_0x2570();}import{jsxs as a37_0x3823cc,jsx as a37_0x3099e1}from'react/jsx-runtime';import{Box,Text}from'ink';export function ConfigHelp(){const _0x3d75f1=a37_0x3c24,_0x1ef0e9=[{'command':_0x3d75f1(0x1c4),'description':'设置配置项'},{'command':'lovrabet\x20config\x20get\x20<key>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','description':_0x3d75f1(0x1c8)},{'command':_0x3d75f1(0x1cc),'description':_0x3d75f1(0x1b7)}],_0xacb1c2=[{'command':_0x3d75f1(0x1bb),'description':_0x3d75f1(0x1c2)},{'command':_0x3d75f1(0x1c0),'description':'设置环境\x20(online/daily)'}];return a37_0x3823cc(Box,{'flexDirection':_0x3d75f1(0x1b8),'marginTop':0x1,'marginBottom':0x1,'children':[a37_0x3099e1(Box,{'marginBottom':0x1,'children':a37_0x3823cc(Text,{'color':_0x3d75f1(0x1bf),'children':['\x20!','\x20\x20','无效的命令,可用命令如下:']})}),_0x1ef0e9[_0x3d75f1(0x1b9)](_0x2eb245=>a37_0x3823cc(Box,{'children':[a37_0x3823cc(Text,{'children':[_0x3d75f1(0x1c6),_0x2eb245[_0x3d75f1(0x1b5)]]}),a37_0x3099e1(Text,{'color':_0x3d75f1(0x1bf),'children':_0x2eb245[_0x3d75f1(0x1bd)]})]},_0x2eb245[_0x3d75f1(0x1b5)])),a37_0x3099e1(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a37_0x3099e1(Text,{'color':_0x3d75f1(0x1bf),'children':_0x3d75f1(0x1be)})}),_0xacb1c2[_0x3d75f1(0x1b9)](_0xef4c59=>a37_0x3823cc(Box,{'children':[a37_0x3823cc(Text,{'children':[_0x3d75f1(0x1c6),_0xef4c59[_0x3d75f1(0x1b5)]]}),a37_0x3099e1(Text,{'color':_0x3d75f1(0x1bf),'children':_0xef4c59[_0x3d75f1(0x1bd)]})]},_0xef4c59[_0x3d75f1(0x1b5)]))]});}
1
+ (function(_0x4420d2,_0x3e00fa){const _0x67dd02=a37_0xf903,_0x5e30d3=_0x4420d2();while(!![]){try{const _0x49d7a0=-parseInt(_0x67dd02(0xed))/0x1*(parseInt(_0x67dd02(0xee))/0x2)+-parseInt(_0x67dd02(0xf6))/0x3+parseInt(_0x67dd02(0xf3))/0x4+-parseInt(_0x67dd02(0xf0))/0x5+parseInt(_0x67dd02(0xfd))/0x6*(-parseInt(_0x67dd02(0x100))/0x7)+parseInt(_0x67dd02(0xfb))/0x8*(-parseInt(_0x67dd02(0xec))/0x9)+parseInt(_0x67dd02(0xf2))/0xa;if(_0x49d7a0===_0x3e00fa)break;else _0x5e30d3['push'](_0x5e30d3['shift']());}catch(_0x2cf3f1){_0x5e30d3['push'](_0x5e30d3['shift']());}}}(a37_0x1c65,0x30667));import{jsxs as a37_0xeb22f8,jsx as a37_0x45d373}from'react/jsx-runtime';import{Box,Text}from'ink';function a37_0xf903(_0x10fe2f,_0x47b919){_0x10fe2f=_0x10fe2f-0xec;const _0x1c652a=a37_0x1c65();let _0xf903f7=_0x1c652a[_0x10fe2f];return _0xf903f7;}function a37_0x1c65(){const _0x35b791=['lovrabet\x20config\x20set\x20<key>\x20<value>\x20\x20\x20','1987839MOGIHd','65445GcbLsp','6jOUrSZ','\x20*\x20配置示例:','17390pnMmqX','command','7728810DsJrYO','424336MkJlkY','无效的命令,可用命令如下:','获取配置项','206592AkMMut','gray','column','\x20\x20\x20\x20','设置环境\x20(online/daily)','8NOpezx','map','6DdIFxm','配置当前项目的\x20App\x20Code','lovrabet\x20config\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','1338190KRLbPF','description','lovrabet\x20config\x20get\x20<key>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'];a37_0x1c65=function(){return _0x35b791;};return a37_0x1c65();}export function ConfigHelp(){const _0x54be5a=a37_0xf903,_0x113993=[{'command':_0x54be5a(0x103),'description':'设置配置项'},{'command':_0x54be5a(0x102),'description':_0x54be5a(0xf5)},{'command':_0x54be5a(0xff),'description':'列出所有配置项'}],_0x21689b=[{'command':'lovrabet\x20config\x20set\x20app\x20app-xxxxx\x20\x20\x20','description':_0x54be5a(0xfe)},{'command':'lovrabet\x20config\x20set\x20env\x20daily\x20\x20\x20\x20\x20\x20\x20','description':_0x54be5a(0xfa)}];return a37_0xeb22f8(Box,{'flexDirection':_0x54be5a(0xf8),'marginTop':0x1,'marginBottom':0x1,'children':[a37_0x45d373(Box,{'marginBottom':0x1,'children':a37_0xeb22f8(Text,{'color':'gray','children':['\x20!','\x20\x20',_0x54be5a(0xf4)]})}),_0x113993['map'](_0x5e2b4f=>a37_0xeb22f8(Box,{'children':[a37_0xeb22f8(Text,{'children':[_0x54be5a(0xf9),_0x5e2b4f[_0x54be5a(0xf1)]]}),a37_0x45d373(Text,{'color':_0x54be5a(0xf7),'children':_0x5e2b4f[_0x54be5a(0x101)]})]},_0x5e2b4f[_0x54be5a(0xf1)])),a37_0x45d373(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a37_0x45d373(Text,{'color':_0x54be5a(0xf7),'children':_0x54be5a(0xef)})}),_0x21689b[_0x54be5a(0xfc)](_0x3cf513=>a37_0xeb22f8(Box,{'children':[a37_0xeb22f8(Text,{'children':[_0x54be5a(0xf9),_0x3cf513[_0x54be5a(0xf1)]]}),a37_0x45d373(Text,{'color':_0x54be5a(0xf7),'children':_0x3cf513[_0x54be5a(0x101)]})]},_0x3cf513[_0x54be5a(0xf1)]))]});}
@@ -1 +1 @@
1
- function a38_0x4e09(){const _0x481422=['3650UDsUOB','appcode','utf8','input','环境配置已设置为:\x20','length','dirname','4347510DQnQgh','1548780iFnctt','70McHFDM','6IXfQQS','3toSGJX','list','get','parse','stringify','undefined','.tmp','39018tRhZyC','1AsoGui','set','8359uVzWjy','保存配置失败','includes','配置值无效或过长','log','flags','renameSync','mkdirSync','red','23705UVrKjr','unlinkSync','396FkUbaD','--help','env','15048sEYrbp','help','保存配置失败:\x20','config','3704188SiHMMs','message','app','环境配置值只能是\x20\x22online\x22\x20或\x20\x22daily\x22','753224GcHHeo'];a38_0x4e09=function(){return _0x481422;};return a38_0x4e09();}(function(_0x242968,_0x2e1cb7){const _0x2a1717=a38_0x582b,_0x1e29ad=_0x242968();while(!![]){try{const _0x182f0b=parseInt(_0x2a1717(0x90))/0x1*(-parseInt(_0x2a1717(0x85))/0x2)+parseInt(_0x2a1717(0x88))/0x3*(-parseInt(_0x2a1717(0x78))/0x4)+-parseInt(_0x2a1717(0x84))/0x5*(parseInt(_0x2a1717(0x87))/0x6)+parseInt(_0x2a1717(0x86))/0x7*(parseInt(_0x2a1717(0x7c))/0x8)+parseInt(_0x2a1717(0x74))/0x9*(parseInt(_0x2a1717(0x7d))/0xa)+parseInt(_0x2a1717(0x6f))/0xb*(parseInt(_0x2a1717(0x71))/0xc)+parseInt(_0x2a1717(0x92))/0xd*(parseInt(_0x2a1717(0x8f))/0xe);if(_0x182f0b===_0x2e1cb7)break;else _0x1e29ad['push'](_0x1e29ad['shift']());}catch(_0x3fb967){_0x1e29ad['push'](_0x1e29ad['shift']());}}}(a38_0x4e09,0xce4e3));import{jsx as a38_0x43e4a7,jsxs as a38_0x5cccc6}from'react/jsx-runtime';import{existsSync,readFileSync,writeFileSync}from'node:fs';import a38_0x23ed31 from'node:fs';import a38_0xba4440 from'node:path';function a38_0x582b(_0x20dd3c,_0x2b7048){_0x20dd3c=_0x20dd3c-0x68;const _0x4e09b9=a38_0x4e09();let _0x582bf6=_0x4e09b9[_0x20dd3c];return _0x582bf6;}import{ConfigHelp}from'./config-help.js';import{Box,Text}from'ink';import{readConfig,isInProject,projectConfigPath,globalConfigPath}from'../utils/config.js';import{logger}from'../utils/logger.js';export function Config(_0xb90611){const _0x5aa29d=a38_0x582b,{cli:_0x59ffba}=_0xb90611,_0x9c7866=_0x59ffba['input'][0x1],_0x28f1e4=_0x59ffba[_0x5aa29d(0x80)][0x2],_0x3585e2=['set',_0x5aa29d(0x8a)][_0x5aa29d(0x68)](_0x9c7866||''),_0x19fc23=_0x59ffba[_0x5aa29d(0x80)]['length']>=0x3;if(_0x28f1e4===_0x5aa29d(0x72)||_0x59ffba[_0x5aa29d(0x6b)][_0x5aa29d(0x75)])return a38_0x43e4a7(ConfigHelp,{});const _0x277678=readConfig();if(_0x9c7866===_0x5aa29d(0x91)){if(_0x28f1e4){const _0x10d782=_0x59ffba['input'][0x3];if(typeof _0x10d782!==_0x5aa29d(0x8d)){if(_0x28f1e4===_0x5aa29d(0x73)&&!['online','daily'][_0x5aa29d(0x68)](_0x10d782))return a38_0x43e4a7(Box,{'children':a38_0x43e4a7(Text,{'color':'red','children':_0x5aa29d(0x7b)})});const _0x3c128c=isInProject(),_0x589330=_0x3c128c?projectConfigPath:globalConfigPath;let _0x3aef79={};try{if(existsSync(_0x589330)){const _0x5d18f7=readFileSync(_0x589330,{'encoding':_0x5aa29d(0x7f)});_0x5d18f7&&(_0x3aef79=JSON[_0x5aa29d(0x8b)](_0x5d18f7));}}catch(_0x36d07b){}if(typeof _0x10d782!=='string'||_0x10d782[_0x5aa29d(0x82)]>0x1f4)return a38_0x43e4a7(Box,{'children':a38_0x43e4a7(Text,{'color':_0x5aa29d(0x6e),'children':_0x5aa29d(0x69)})});let _0x408ad8=_0x28f1e4;_0x28f1e4===_0x5aa29d(0x7a)&&(_0x408ad8=_0x5aa29d(0x7e),delete _0x3aef79[_0x5aa29d(0x7a)]);_0x28f1e4===_0x5aa29d(0x7e)&&delete _0x3aef79[_0x5aa29d(0x7a)];_0x3aef79[_0x408ad8]=_0x10d782;try{const _0x2133ba=a38_0xba4440[_0x5aa29d(0x83)](_0x589330);!existsSync(_0x2133ba)&&a38_0x23ed31[_0x5aa29d(0x6d)](_0x2133ba,{'recursive':!![]});const _0x8cdc48=_0x589330+_0x5aa29d(0x8e);writeFileSync(_0x8cdc48,JSON[_0x5aa29d(0x8c)](_0x3aef79,null,0x2),{'encoding':_0x5aa29d(0x7f),'mode':0x180}),a38_0x23ed31[_0x5aa29d(0x6c)](_0x8cdc48,_0x589330);if(_0x28f1e4===_0x5aa29d(0x73)){const _0x1ae830=_0x3c128c?'项目':'全局';console[_0x5aa29d(0x6a)]('✓\x20'+_0x1ae830+_0x5aa29d(0x81)+_0x10d782);}}catch(_0x5d147e){const _0xfee8f5=_0x589330+_0x5aa29d(0x8e);try{existsSync(_0xfee8f5)&&a38_0x23ed31[_0x5aa29d(0x70)](_0xfee8f5);}catch(_0x15ac68){}return logger['error'](_0x5aa29d(0x77),_0x5aa29d(0x93),{'error':_0x5d147e instanceof Error?_0x5d147e['message']:String(_0x5d147e),'configKey':_0x28f1e4,'configValue':_0x10d782,'targetConfigPath':_0x589330}),a38_0x43e4a7(Box,{'children':a38_0x5cccc6(Text,{'color':_0x5aa29d(0x6e),'children':[_0x5aa29d(0x76),_0x5d147e instanceof Error?_0x5d147e[_0x5aa29d(0x79)]:String(_0x5d147e)]})});}return null;}return a38_0x43e4a7(Box,{'children':a38_0x43e4a7(Text,{'color':_0x5aa29d(0x6e),'children':'未提供配置值'})});}}if(_0x9c7866===_0x5aa29d(0x8a)){if(_0x28f1e4){let _0x4746ba=_0x28f1e4;return _0x28f1e4===_0x5aa29d(0x7a)&&(_0x4746ba=_0x5aa29d(0x7e)),console[_0x5aa29d(0x6a)](_0x277678[_0x4746ba]||_0x5aa29d(0x8d)),null;}return null;}if(_0x9c7866===_0x5aa29d(0x89))return console[_0x5aa29d(0x6a)](JSON[_0x5aa29d(0x8c)](_0x277678,null,0x2)),null;if(!_0x3585e2||!_0x19fc23)return a38_0x43e4a7(ConfigHelp,{});return null;}
1
+ (function(_0x4251b9,_0x56ac69){const _0x1faac1=a38_0x112d,_0x4a6f35=_0x4251b9();while(!![]){try{const _0x555577=parseInt(_0x1faac1(0x150))/0x1+parseInt(_0x1faac1(0x159))/0x2+parseInt(_0x1faac1(0x14e))/0x3+parseInt(_0x1faac1(0x148))/0x4+-parseInt(_0x1faac1(0x149))/0x5*(-parseInt(_0x1faac1(0x151))/0x6)+parseInt(_0x1faac1(0x14a))/0x7*(-parseInt(_0x1faac1(0x142))/0x8)+-parseInt(_0x1faac1(0x13c))/0x9*(parseInt(_0x1faac1(0x14b))/0xa);if(_0x555577===_0x56ac69)break;else _0x4a6f35['push'](_0x4a6f35['shift']());}catch(_0x3e6c70){_0x4a6f35['push'](_0x4a6f35['shift']());}}}(a38_0x48e9,0x83073));function a38_0x48e9(){const _0x4d1721=['renameSync','18JsExsb','input','保存配置失败:\x20','未提供配置值','env','string','8EoAvBY','get','list','dirname','includes','set','2941248oCjpME','510ufBLZq','3315242kUjxrE','8944330sfgPjH','stringify','length','2508723Cqlwsl','daily','343721qcoOuj','27264jSepgx','red','appcode','环境配置值只能是\x20\x22online\x22\x20或\x20\x22daily\x22','环境配置已设置为:\x20','error','utf8','保存配置失败','840802txaiMc','log','app','help','unlinkSync','config','--help','flags','parse','message'];a38_0x48e9=function(){return _0x4d1721;};return a38_0x48e9();}import{jsx as a38_0x5b2fb1,jsxs as a38_0x3749ce}from'react/jsx-runtime';import{existsSync,readFileSync,writeFileSync}from'node:fs';import a38_0x53cf6b from'node:fs';import a38_0x5b3079 from'node:path';import{ConfigHelp}from'./config-help.js';import{Box,Text}from'ink';function a38_0x112d(_0x5490bb,_0xde2216){_0x5490bb=_0x5490bb-0x138;const _0x48e90b=a38_0x48e9();let _0x112dcf=_0x48e90b[_0x5490bb];return _0x112dcf;}import{readConfig,isInProject,projectConfigPath,globalConfigPath}from'../utils/config.js';import{logger}from'../utils/logger.js';export function Config(_0x50f3c1){const _0x582e00=a38_0x112d,{cli:_0x59652b}=_0x50f3c1,_0x26c4aa=_0x59652b[_0x582e00(0x13d)][0x1],_0x414f08=_0x59652b[_0x582e00(0x13d)][0x2],_0x413b39=[_0x582e00(0x147),_0x582e00(0x143)]['includes'](_0x26c4aa||''),_0x35c325=_0x59652b['input'][_0x582e00(0x14d)]>=0x3;if(_0x414f08===_0x582e00(0x15f)||_0x59652b[_0x582e00(0x138)][_0x582e00(0x15c)])return a38_0x5b2fb1(ConfigHelp,{});const _0x5a7cd1=readConfig();if(_0x26c4aa===_0x582e00(0x147)){if(_0x414f08){const _0x42ca2d=_0x59652b[_0x582e00(0x13d)][0x3];if(typeof _0x42ca2d!=='undefined'){if(_0x414f08===_0x582e00(0x140)&&!['online',_0x582e00(0x14f)][_0x582e00(0x146)](_0x42ca2d))return a38_0x5b2fb1(Box,{'children':a38_0x5b2fb1(Text,{'color':_0x582e00(0x152),'children':_0x582e00(0x154)})});const _0x618561=isInProject(),_0xb68e18=_0x618561?projectConfigPath:globalConfigPath;let _0x59fd49={};try{if(existsSync(_0xb68e18)){const _0x1a38c6=readFileSync(_0xb68e18,{'encoding':_0x582e00(0x157)});_0x1a38c6&&(_0x59fd49=JSON[_0x582e00(0x139)](_0x1a38c6));}}catch(_0x3481a6){}if(typeof _0x42ca2d!==_0x582e00(0x141)||_0x42ca2d[_0x582e00(0x14d)]>0x1f4)return a38_0x5b2fb1(Box,{'children':a38_0x5b2fb1(Text,{'color':'red','children':'配置值无效或过长'})});let _0x526746=_0x414f08;_0x414f08===_0x582e00(0x15b)&&(_0x526746=_0x582e00(0x153),delete _0x59fd49[_0x582e00(0x15b)]);_0x414f08==='appcode'&&delete _0x59fd49['app'];_0x59fd49[_0x526746]=_0x42ca2d;try{const _0x44f154=a38_0x5b3079[_0x582e00(0x145)](_0xb68e18);!existsSync(_0x44f154)&&a38_0x53cf6b['mkdirSync'](_0x44f154,{'recursive':!![]});const _0x3da3d9=_0xb68e18+'.tmp';writeFileSync(_0x3da3d9,JSON[_0x582e00(0x14c)](_0x59fd49,null,0x2),{'encoding':_0x582e00(0x157),'mode':0x180}),a38_0x53cf6b[_0x582e00(0x13b)](_0x3da3d9,_0xb68e18);if(_0x414f08===_0x582e00(0x140)){const _0x155cdc=_0x618561?'项目':'全局';console[_0x582e00(0x15a)]('✓\x20'+_0x155cdc+_0x582e00(0x155)+_0x42ca2d);}}catch(_0x53003e){const _0x2c3e56=_0xb68e18+'.tmp';try{existsSync(_0x2c3e56)&&a38_0x53cf6b[_0x582e00(0x15d)](_0x2c3e56);}catch(_0x39cbc1){}return logger[_0x582e00(0x156)](_0x582e00(0x15e),_0x582e00(0x158),{'error':_0x53003e instanceof Error?_0x53003e['message']:String(_0x53003e),'configKey':_0x414f08,'configValue':_0x42ca2d,'targetConfigPath':_0xb68e18}),a38_0x5b2fb1(Box,{'children':a38_0x3749ce(Text,{'color':_0x582e00(0x152),'children':[_0x582e00(0x13e),_0x53003e instanceof Error?_0x53003e[_0x582e00(0x13a)]:String(_0x53003e)]})});}return null;}return a38_0x5b2fb1(Box,{'children':a38_0x5b2fb1(Text,{'color':'red','children':_0x582e00(0x13f)})});}}if(_0x26c4aa===_0x582e00(0x143)){if(_0x414f08){let _0x2f5751=_0x414f08;return _0x414f08===_0x582e00(0x15b)&&(_0x2f5751=_0x582e00(0x153)),console[_0x582e00(0x15a)](_0x5a7cd1[_0x2f5751]||'undefined'),null;}return null;}if(_0x26c4aa===_0x582e00(0x144))return console[_0x582e00(0x15a)](JSON[_0x582e00(0x14c)](_0x5a7cd1,null,0x2)),null;if(!_0x413b39||!_0x35c325)return a38_0x5b2fb1(ConfigHelp,{});return null;}
@@ -1 +1 @@
1
- function a39_0x50f4(_0x2d672f,_0x1c4a04){_0x2d672f=_0x2d672f-0x1a9;const _0x30cf50=a39_0x30cf();let _0x50f424=_0x30cf50[_0x2d672f];return _0x50f424;}const a39_0x37df67=a39_0x50f4;function a39_0x30cf(){const _0x526657=['online','832845meUtqc','682648eTibJK','187dMXtfr','125ODYXYD','https://user-daily.lovrabet.com','469064kaQoLc','https://api.lovrabet.com','21YbiLzJ','4tjakKO','423uJXqcd','364BYhiuZ','788988WbYrCS','34422bJhTpi','https://user.lovrabet.com','15cvbOzB','313970mKWATc','149759GNIBuM'];a39_0x30cf=function(){return _0x526657;};return a39_0x30cf();}(function(_0x2abdd3,_0x54dcbe){const _0xafd509=a39_0x50f4,_0x152176=_0x2abdd3();while(!![]){try{const _0x380298=parseInt(_0xafd509(0x1b8))/0x1*(-parseInt(_0xafd509(0x1b0))/0x2)+-parseInt(_0xafd509(0x1b6))/0x3*(parseInt(_0xafd509(0x1ad))/0x4)+parseInt(_0xafd509(0x1ab))/0x5*(-parseInt(_0xafd509(0x1b4))/0x6)+parseInt(_0xafd509(0x1af))/0x7*(-parseInt(_0xafd509(0x1a9))/0x8)+-parseInt(_0xafd509(0x1b1))/0x9*(-parseInt(_0xafd509(0x1b7))/0xa)+parseInt(_0xafd509(0x1aa))/0xb*(-parseInt(_0xafd509(0x1b3))/0xc)+parseInt(_0xafd509(0x1ba))/0xd*(parseInt(_0xafd509(0x1b2))/0xe);if(_0x380298===_0x54dcbe)break;else _0x152176['push'](_0x152176['shift']());}catch(_0x42156f){_0x152176['push'](_0x152176['shift']());}}}(a39_0x30cf,0xb442e));import{getEnv}from'./env.js';export const getUserDomain=()=>getEnv()===a39_0x37df67(0x1b9)?a39_0x37df67(0x1b5):a39_0x37df67(0x1ac);export const getApiDomain=()=>getEnv()===a39_0x37df67(0x1b9)?a39_0x37df67(0x1ae):'https://daily-api.lovrabet.com';
1
+ function a39_0x3e22(_0x42cc49,_0x582183){_0x42cc49=_0x42cc49-0x115;const _0x1a85f5=a39_0x1a85();let _0x3e226d=_0x1a85f5[_0x42cc49];return _0x3e226d;}function a39_0x1a85(){const _0x225354=['6OtMYWO','15339643ICfMzv','online','1045968wIkSKu','1375034VYIQpZ','9NiiGNI','3688ybzVTN','102636tYLDXx','500IFDrJc','https://api.lovrabet.com','5383255WwaEjq','https://daily-api.lovrabet.com','1576144djtuXx','3241thFULO'];a39_0x1a85=function(){return _0x225354;};return a39_0x1a85();}const a39_0x25223e=a39_0x3e22;(function(_0x27a182,_0x4c7e0f){const _0x36ee01=a39_0x3e22,_0x214b52=_0x27a182();while(!![]){try{const _0x10df43=parseInt(_0x36ee01(0x11f))/0x1+-parseInt(_0x36ee01(0x11e))/0x2+parseInt(_0x36ee01(0x120))/0x3*(-parseInt(_0x36ee01(0x119))/0x4)+parseInt(_0x36ee01(0x117))/0x5*(-parseInt(_0x36ee01(0x11b))/0x6)+parseInt(_0x36ee01(0x11a))/0x7*(parseInt(_0x36ee01(0x121))/0x8)+-parseInt(_0x36ee01(0x122))/0x9*(-parseInt(_0x36ee01(0x115))/0xa)+parseInt(_0x36ee01(0x11c))/0xb;if(_0x10df43===_0x4c7e0f)break;else _0x214b52['push'](_0x214b52['shift']());}catch(_0x46b08e){_0x214b52['push'](_0x214b52['shift']());}}}(a39_0x1a85,0xbc577));import{getEnv}from'./env.js';export const getUserDomain=()=>getEnv()==='online'?'https://user.lovrabet.com':'https://user-daily.lovrabet.com';export const getApiDomain=()=>getEnv()===a39_0x25223e(0x11d)?a39_0x25223e(0x116):a39_0x25223e(0x118);
@@ -1 +1 @@
1
- const a40_0x4e4606=a40_0x1e2e;function a40_0x1ad6(){const _0x586ebc=['199365cdXSTQ','127443ECbWTz','8675220XlCezp','1906040asHUJz','44QgLymI','207966LcyQaA','161PrDEIw','5331970UdbEWs','2gppdgl','26339784oVgSER','11PeqVSm','9UhJqma','env'];a40_0x1ad6=function(){return _0x586ebc;};return a40_0x1ad6();}(function(_0x45ee39,_0x5cabb2){const _0xb4292e=a40_0x1e2e,_0x32ba12=_0x45ee39();while(!![]){try{const _0x35f41b=-parseInt(_0xb4292e(0xe6))/0x1*(-parseInt(_0xb4292e(0xe0))/0x2)+parseInt(_0xb4292e(0xe5))/0x3*(-parseInt(_0xb4292e(0xe9))/0x4)+-parseInt(_0xb4292e(0xdf))/0x5+parseInt(_0xb4292e(0xdd))/0x6*(-parseInt(_0xb4292e(0xde))/0x7)+-parseInt(_0xb4292e(0xe8))/0x8*(-parseInt(_0xb4292e(0xe3))/0x9)+parseInt(_0xb4292e(0xe7))/0xa+parseInt(_0xb4292e(0xe2))/0xb*(parseInt(_0xb4292e(0xe1))/0xc);if(_0x35f41b===_0x5cabb2)break;else _0x32ba12['push'](_0x32ba12['shift']());}catch(_0x286e32){_0x32ba12['push'](_0x32ba12['shift']());}}}(a40_0x1ad6,0xcb840));let env=process[a40_0x4e4606(0xe4)]['LOVRABET_ENV']||'online';function a40_0x1e2e(_0x253585,_0x5d42e3){_0x253585=_0x253585-0xdd;const _0x1ad608=a40_0x1ad6();let _0x1e2e82=_0x1ad608[_0x253585];return _0x1e2e82;}export function getEnv(){return env;}export function initEnv(_0x32ec3f){env=_0x32ec3f;}
1
+ const a40_0x5b12f6=a40_0x5373;function a40_0x5373(_0x15d505,_0x336006){_0x15d505=_0x15d505-0x1bd;const _0x42cadd=a40_0x42ca();let _0x53737a=_0x42cadd[_0x15d505];return _0x53737a;}function a40_0x42ca(){const _0x4f7194=['10QehKVV','online','204845iXULWl','24qjXsWF','4414069NRjwqd','env','32yBGFVm','24369mvmSYJ','414312ooofoE','3396564gGvQuy','28HOIfSo','985353kWjFic','LOVRABET_ENV','4466493FaNCDh'];a40_0x42ca=function(){return _0x4f7194;};return a40_0x42ca();}(function(_0x5de112,_0x45a3f3){const _0x383a37=a40_0x5373,_0x237084=_0x5de112();while(!![]){try{const _0x50ba27=-parseInt(_0x383a37(0x1c7))/0x1*(-parseInt(_0x383a37(0x1c3))/0x2)+-parseInt(_0x383a37(0x1bd))/0x3+-parseInt(_0x383a37(0x1c6))/0x4*(parseInt(_0x383a37(0x1c2))/0x5)+parseInt(_0x383a37(0x1c9))/0x6+-parseInt(_0x383a37(0x1ca))/0x7*(-parseInt(_0x383a37(0x1c8))/0x8)+parseInt(_0x383a37(0x1bf))/0x9*(parseInt(_0x383a37(0x1c0))/0xa)+-parseInt(_0x383a37(0x1c4))/0xb;if(_0x50ba27===_0x45a3f3)break;else _0x237084['push'](_0x237084['shift']());}catch(_0x2685ca){_0x237084['push'](_0x237084['shift']());}}}(a40_0x42ca,0x7b299));let env=process[a40_0x5b12f6(0x1c5)][a40_0x5b12f6(0x1be)]||a40_0x5b12f6(0x1c1);export function getEnv(){return env;}export function initEnv(_0xb2f466){env=_0xb2f466;}
@@ -1 +1 @@
1
- const a41_0x15051a=a41_0x295a;(function(_0x2b5161,_0x45bd00){const _0x566a4f=a41_0x295a,_0x437488=_0x2b5161();while(!![]){try{const _0x5c3bb4=-parseInt(_0x566a4f(0x211))/0x1*(parseInt(_0x566a4f(0x1b7))/0x2)+parseInt(_0x566a4f(0x1bb))/0x3*(-parseInt(_0x566a4f(0x1ca))/0x4)+parseInt(_0x566a4f(0x1e8))/0x5*(parseInt(_0x566a4f(0x20c))/0x6)+-parseInt(_0x566a4f(0x1e2))/0x7*(-parseInt(_0x566a4f(0x1d6))/0x8)+-parseInt(_0x566a4f(0x21b))/0x9*(-parseInt(_0x566a4f(0x1e0))/0xa)+parseInt(_0x566a4f(0x1de))/0xb+-parseInt(_0x566a4f(0x1c6))/0xc;if(_0x5c3bb4===_0x45bd00)break;else _0x437488['push'](_0x437488['shift']());}catch(_0x36e9a9){_0x437488['push'](_0x437488['shift']());}}}(a41_0x24b8,0x31807));import{jsx as a41_0x4492c3,jsxs as a41_0x198c89,Fragment as a41_0x3e123d}from'react/jsx-runtime';import{useState}from'react';import{Text,Box,useInput}from'ink';import{existsSync}from'node:fs';function a41_0x24b8(){const _0x3d4aa2=['\x20+MCP','has','项目名只能以字母或数字开头,且只包含字母、数字、-\x20和\x20_','return','登录失败','from','748AXgVqX','[✓]','项目名长度不能超过\x2050\x20个字符','[\x20]','9qSTtuU','confirm-api-pull','lovrabet-setup','Cursor','description','!\x20未检测到有效登录','请至少选择一个\x20IDE','*\x20正在登录,请前往浏览器完成登录...','length','add','map','1144632HqnfZi','windsurf','test','跳过登录','413360WtWLMk','rightArrow','目录\x20\x22','backspace','项目名不合法','cursor','yellow','name','green','codebuddy','拉取API配置','includes','4264ZgPYGK','qoder','Antigravity\x20IDE\x20(.agent/skills/)','codex','选择要配置的\x20IDE:','*\x20应用AppCode\x20','其他\x20(通用模板)','*\x20正在检查登录状态...','2090869wQaJlO','value','281150NXFpWY','Yes','4291gzNcIh','claude','未设置','\x22\x20已存在','OpenCode','MCP\x20和\x20Skill','8420thzCGa','\x20\x20使用\x20←→\x20选择,回车确认','\x20登录中...','Windsurf\x20IDE\x20(.windsurf/workflows/)','login-prompt','CodeBuddy\x20IDE\x20(.codebuddy/skills/)','*\x20是否配置\x20Lovrabet\x20MCP\x20和\x20Skill?','\x20直接回车确认,或输入自定义名称','slice','string','Claude\x20Code\x20(.claude/skills/\x20+\x20MCP\x20服务器)','lovrabet-setup-selection','red','delete','Codex','login-check','filter','*\x20是否要先登录以便拉取\x20API\x20配置?','login-process','*\x20正在创建项目...','white','column','*\x20项目名:\x20','label','online','通用模板\x20(.agent/skills/)\x20-\x20兜底方案','api-pull','env','leftArrow','creating','login','应用AppCode只能包含字母、数字、连字符和下划线,且必须以字母或数字开头','cwd','gray','blue','downArrow','462kkCRFn','step','trim','Qoder','*\x20是否要自动拉取\x20API\x20配置?','779FnNKKU','project-name','my-app','Trae','\x20←\x20','OpenCode\x20IDE\x20(.opencode/skills/)','cyan','登录状态','*\x20创建新项目','trae','81uvFsnb','\x22\x20已存在,请使用其他名称','Codex\x20IDE\x20(.codex/skills/)','\x20个\x20IDE','app-code','应用AppCode不合法'];a41_0x24b8=function(){return _0x3d4aa2;};return a41_0x24b8();}import a41_0x129496 from'node:path';import{getIsSessionValid}from'../auth/is-session-valid.js';import{authServer}from'../auth/auth-server.js';function a41_0x295a(_0x97a014,_0x2f48ac){_0x97a014=_0x97a014-0x1b2;const _0x24b847=a41_0x24b8();let _0x295a25=_0x24b847[_0x97a014];return _0x295a25;}import{readConfig}from'../utils/config.js';const IDE_CONFIGS={'cursor':{'name':a41_0x15051a(0x1be),'description':'Cursor\x20IDE\x20(.cursorrules\x20+\x20MCP\x20服务器)'},'windsurf':{'name':'Windsurf','description':a41_0x15051a(0x1eb)},'claude':{'name':'Claude\x20Code','description':a41_0x15051a(0x1f2)},'codex':{'name':a41_0x15051a(0x1f6),'description':a41_0x15051a(0x21d)},'opencode':{'name':a41_0x15051a(0x1e6),'description':a41_0x15051a(0x216)},'qoder':{'name':a41_0x15051a(0x20f),'description':'Qoder\x20IDE\x20(.qoder/rules/\x20+\x20.qoder/skills/)'},'codebuddy':{'name':'CodeBuddy','description':a41_0x15051a(0x1ed)},'trae':{'name':a41_0x15051a(0x214),'description':'Trae\x20IDE\x20(.trae/skills/)'},'antigravity':{'name':'Antigravity','description':a41_0x15051a(0x1d8)},'agent':{'name':a41_0x15051a(0x1dc),'description':a41_0x15051a(0x201)}},IDE_LIST=['antigravity',a41_0x15051a(0x1e3),a41_0x15051a(0x1d3),a41_0x15051a(0x1d9),a41_0x15051a(0x1cf),'opencode',a41_0x15051a(0x1d7),a41_0x15051a(0x21a),a41_0x15051a(0x1c7),'agent'],MCP_IDES=new Set(['cursor',a41_0x15051a(0x1e3)]);export function EnhancedGuidedCreate(_0x94c0d7){const _0xcc52e2=a41_0x15051a,{onCreate:_0x3e82ef,env:_0x322346}=_0x94c0d7,[_0x3d9b41,_0x192c42]=useState(_0xcc52e2(0x212)),[_0x5ec152,_0x2abe7f]=useState(''),[_0x20ed40,_0x45e36e]=useState(''),[_0x5b51b5,_0x8bc1ea]=useState(''),[_0x45d882,_0x3702f2]=useState(''),[_0x2d64a2,_0x56db27]=useState([]),[_0x2e7dff,_0x44517c]=useState(null),[_0x57d751,_0x516cb0]=useState(![]),[_0x4ee5ea,_0x142afc]=useState(![]),[_0x158220,_0x267ccb]=useState(![]),[_0x1e1093,_0x25ffe2]=useState(0x0),[_0x5c36fe,_0x4fbaec]=useState(0x0),[_0x3ff843,_0x1f83e1]=useState(0x0),[_0xe081b1,_0x355e12]=useState(![]),[_0x33732e,_0x359b83]=useState(new Set()),[_0x2f157d,_0x436da6]=useState(0x0),[_0x784d0b,_0x2d0c12]=useState(''),_0x21ec2c=_0xcc52e2(0x213),_0x31ff88=readConfig(),_0x51b9a0=typeof _0x31ff88[_0xcc52e2(0x203)]===_0xcc52e2(0x1f1)?_0x31ff88[_0xcc52e2(0x203)]:undefined;function _0xbe5147(_0x5a49d5){const _0x4fca03=_0xcc52e2,_0x24d273=_0x5a49d5||_0x21ec2c,_0x3d6bab=a41_0x129496['resolve'](process[_0x4fca03(0x208)](),_0x24d273);return existsSync(_0x3d6bab);}function _0x17f886(_0x2144dc){const _0x5c8c1b=_0xcc52e2;if(_0x2144dc['length']>0x32)return{'valid':![],'message':_0x5c8c1b(0x1b9)};const _0x462d04=/^[A-Za-z0-9][A-Za-z0-9_-]*$/;if(_0x2144dc?.[_0x5c8c1b(0x20e)]()&&!_0x462d04['test'](_0x2144dc))return{'valid':![],'message':_0x5c8c1b(0x1b3)};return{'valid':!![]};}function _0x1c9a6e(_0x3d604f){const _0x303687=_0xcc52e2;if(!_0x3d604f[_0x303687(0x20e)]())return{'valid':!![]};if(_0x3d604f['length']>0x64)return{'valid':![],'message':'应用AppCode长度不能超过\x20100\x20个字符'};const _0x30ae6e=/^[a-zA-Z0-9][a-zA-Z0-9_-]*$/;if(!_0x30ae6e[_0x303687(0x1c8)](_0x3d604f))return{'valid':![],'message':_0x303687(0x207)};return{'valid':!![]};}async function _0x32f44d(){_0x516cb0(!![]);try{const _0x2c712e=await getIsSessionValid();return _0x44517c(_0x2c712e),_0x2c712e;}catch(_0x2bc7e3){return _0x44517c(![]),![];}finally{_0x516cb0(![]);}}async function _0x1ef75f(){_0x142afc(!![]);try{const _0x142ac4=await authServer({'silent':!![]});return _0x44517c(_0x142ac4),_0x142ac4;}catch(_0x509867){return _0x44517c(![]),![];}finally{_0x142afc(![]);}}return useInput(async(_0x2d48d0,_0x5eabb1)=>{const _0x2d41cf=_0xcc52e2;if(_0x5eabb1[_0x2d41cf(0x204)]||_0x5eabb1[_0x2d41cf(0x1cb)]){if(_0x3d9b41===_0x2d41cf(0x1bc)){_0x25ffe2(_0x4f9143=>_0x4f9143===0x0?0x1:0x0);return;}if(_0x3d9b41==='lovrabet-setup-selection'){if(!_0xe081b1){_0x1f83e1(_0x1e390c=>_0x1e390c===0x0?0x1:0x0);return;}_0x355e12(![]);return;}if(_0x3d9b41===_0x2d41cf(0x1ec)){_0x4fbaec(_0x29cbd8=>_0x29cbd8===0x0?0x1:0x0);return;}}if(_0x3d9b41==='lovrabet-setup-selection'&&_0xe081b1&&_0x3ff843===0x0){if(_0x5eabb1['upArrow']){_0x436da6(_0x354205=>_0x354205>0x0?_0x354205-0x1:IDE_LIST[_0x2d41cf(0x1c3)]-0x1);return;}if(_0x5eabb1[_0x2d41cf(0x20b)]){_0x436da6(_0x3c4adb=>_0x3c4adb<IDE_LIST['length']-0x1?_0x3c4adb+0x1:0x0);return;}}if(_0x2d48d0==='\x20'&&_0x3d9b41===_0x2d41cf(0x1f3)&&_0xe081b1&&_0x3ff843===0x0){_0x359b83(_0x3afc94=>{const _0x554f6b=_0x2d41cf,_0x16984a=new Set(_0x3afc94);return _0x16984a[_0x554f6b(0x1b2)](_0x2f157d)?_0x16984a[_0x554f6b(0x1f5)](_0x2f157d):_0x16984a[_0x554f6b(0x1c4)](_0x2f157d),_0x16984a;}),_0x3702f2('');return;}if((_0x2d48d0==='a'||_0x2d48d0==='A')&&_0x3d9b41===_0x2d41cf(0x1f3)&&_0xe081b1&&_0x3ff843===0x0){_0x359b83(new Set(IDE_LIST[_0x2d41cf(0x1c5)]((_0x249353,_0x1ace60)=>_0x1ace60))),_0x3702f2('');return;}if((_0x2d48d0==='i'||_0x2d48d0==='I'||_0x2d48d0==='r'||_0x2d48d0==='R')&&_0x3d9b41===_0x2d41cf(0x1f3)&&_0xe081b1&&_0x3ff843===0x0){_0x359b83(_0x2af1b7=>{const _0x5cd8bf=_0x2d41cf,_0x35f8c4=new Set();for(let _0x30343e=0x0;_0x30343e<IDE_LIST[_0x5cd8bf(0x1c3)];_0x30343e++){!_0x2af1b7[_0x5cd8bf(0x1b2)](_0x30343e)&&_0x35f8c4['add'](_0x30343e);}return _0x35f8c4;});return;}if(_0x5eabb1[_0x2d41cf(0x1b4)]){if(_0x3d9b41===_0x2d41cf(0x212)){const _0x3d9186=_0x5b51b5[_0x2d41cf(0x20e)]()||_0x21ec2c;if(_0x45d882)return;if(_0xbe5147(_0x3d9186)){_0x2d0c12(_0x2d41cf(0x1cc)+_0x3d9186+_0x2d41cf(0x21c));return;}_0x2abe7f(_0x3d9186),_0x56db27([{'step':'project-name','label':'项目名','value':_0x3d9186}]),_0x8bc1ea(''),_0x3702f2(''),_0x2d0c12(''),_0x192c42(_0x2d41cf(0x21f));return;}if(_0x3d9b41===_0x2d41cf(0x21f)){if(_0x45d882)return;const _0x168982=_0x5b51b5[_0x2d41cf(0x20e)]();_0x45e36e(_0x168982),_0x56db27(_0x4109cc=>[..._0x4109cc,{'step':_0x2d41cf(0x21f),'label':'应用AppCode','value':_0x168982||_0x2d41cf(0x1e4)}]),_0x8bc1ea(''),_0x3702f2('');if(_0x168982){_0x192c42(_0x2d41cf(0x1f7));const _0x49b988=await _0x32f44d();_0x49b988?_0x192c42(_0x2d41cf(0x1bc)):_0x192c42(_0x2d41cf(0x1ec));}else{const _0x5242f5=_0x322346||_0x51b9a0||_0x2d41cf(0x200);_0x3e82ef({'projectName':_0x5ec152,'appCode':undefined,'pullApi':![],'aiSetup':![],'selectedIDEs':[],'env':_0x5242f5}),_0x192c42(_0x2d41cf(0x205));}return;}if(_0x3d9b41===_0x2d41cf(0x1bc)){const _0x254b47=_0x1e1093===0x0;_0x267ccb(_0x254b47),_0x56db27(_0x4996da=>[..._0x4996da,{'step':_0x2d41cf(0x202),'label':_0x2d41cf(0x1d4),'value':_0x254b47?'是':'否'}]),_0x192c42(_0x2d41cf(0x1f3));return;}if(_0x3d9b41==='lovrabet-setup-selection'){if(!_0xe081b1){_0x355e12(!![]);if(_0x3ff843===0x1){_0x56db27(_0x4d54bb=>[..._0x4d54bb,{'step':_0x2d41cf(0x1bd),'label':_0x2d41cf(0x1e7),'value':'否'}]);const _0x54a2cb=_0x322346||_0x51b9a0||_0x2d41cf(0x200);_0x3e82ef({'projectName':_0x5ec152,'appCode':_0x20ed40,'pullApi':_0x158220,'aiSetup':![],'selectedIDEs':[],'env':_0x54a2cb}),_0x192c42('creating');}return;}const _0x47d047=_0x3ff843===0x0;if(_0x47d047){if(_0x33732e['size']===0x0){_0x3702f2(_0x2d41cf(0x1c1));return;}const _0x5324ee=Array[_0x2d41cf(0x1b6)](_0x33732e)[_0x2d41cf(0x1c5)](_0x1e30a1=>IDE_LIST[_0x1e30a1])[_0x2d41cf(0x1f8)](_0x96caa4=>_0x96caa4!==undefined);_0x56db27(_0xe4ad0e=>[..._0xe4ad0e,{'step':_0x2d41cf(0x1bd),'label':_0x2d41cf(0x1e7),'value':_0x5324ee[_0x2d41cf(0x1c3)]+_0x2d41cf(0x21e)}]);const _0x2536bf=_0x322346||_0x51b9a0||_0x2d41cf(0x200);_0x3e82ef({'projectName':_0x5ec152,'appCode':_0x20ed40,'pullApi':_0x158220,'aiSetup':!![],'selectedIDEs':_0x5324ee,'env':_0x2536bf}),_0x192c42(_0x2d41cf(0x205));}else{_0x56db27(_0x193776=>[..._0x193776,{'step':_0x2d41cf(0x1bd),'label':_0x2d41cf(0x1e7),'value':'否'}]);const _0x59f5d9=_0x322346||_0x51b9a0||_0x2d41cf(0x200);_0x3e82ef({'projectName':_0x5ec152,'appCode':_0x20ed40,'pullApi':_0x158220,'aiSetup':![],'selectedIDEs':[],'env':_0x59f5d9}),_0x192c42(_0x2d41cf(0x205));}return;}if(_0x3d9b41===_0x2d41cf(0x1ec)){const _0x18bf06=_0x5c36fe===0x0;if(_0x18bf06){_0x192c42(_0x2d41cf(0x1fa));const _0x183970=await _0x1ef75f();_0x183970?(_0x56db27(_0x42cd3c=>[..._0x42cd3c,{'step':_0x2d41cf(0x206),'label':_0x2d41cf(0x218),'value':'已登录'}]),_0x192c42(_0x2d41cf(0x1bc))):(_0x56db27(_0x273652=>[..._0x273652,{'step':'login','label':_0x2d41cf(0x218),'value':_0x2d41cf(0x1b5)}]),_0x192c42('lovrabet-setup-selection'));}else _0x56db27(_0x2d18e8=>[..._0x2d18e8,{'step':_0x2d41cf(0x206),'label':_0x2d41cf(0x218),'value':_0x2d41cf(0x1c9)}]),_0x192c42(_0x2d41cf(0x1f3));return;}}if(_0x5eabb1[_0x2d41cf(0x1cd)]||_0x5eabb1['delete']){_0x8bc1ea(_0x252a8d=>{const _0xeb762=_0x2d41cf,_0x23ac95=_0x252a8d[_0xeb762(0x1f0)](0x0,-0x1);if(_0x3d9b41==='project-name'){const {valid:_0x4f5419,message:_0x3e10c6}=_0x17f886(_0x23ac95);_0x3702f2(_0x4f5419?'':_0x3e10c6||_0xeb762(0x1ce));if(_0x4f5419&&!_0x45d882){const _0x479a04=_0x23ac95||_0x21ec2c;_0xbe5147(_0x479a04)?_0x2d0c12(_0xeb762(0x1cc)+_0x479a04+_0xeb762(0x1e5)):_0x2d0c12('');}}else{if(_0x3d9b41===_0xeb762(0x21f)){const {valid:_0x5ef585,message:_0x50b7e5}=_0x1c9a6e(_0x23ac95);_0x3702f2(_0x5ef585?'':_0x50b7e5||_0xeb762(0x220));}}return _0x23ac95;});return;}if([_0x2d41cf(0x205),_0x2d41cf(0x1f7),_0x2d41cf(0x1fa)][_0x2d41cf(0x1d5)](_0x3d9b41))return;if(_0x3d9b41===_0x2d41cf(0x1bc)||_0x3d9b41==='login-prompt'||_0x3d9b41===_0x2d41cf(0x1f3))return;_0x8bc1ea(_0x23bf57=>{const _0x5d02a2=_0x2d41cf,_0x5b2b99=_0x23bf57+_0x2d48d0;if(_0x3d9b41===_0x5d02a2(0x212)){const {valid:_0x41293c,message:_0x276ed4}=_0x17f886(_0x5b2b99);_0x3702f2(_0x41293c?'':_0x276ed4||_0x5d02a2(0x1ce));if(_0x41293c&&!_0x45d882){const _0x4d0789=_0x5b2b99||_0x21ec2c;_0xbe5147(_0x4d0789)?_0x2d0c12(_0x5d02a2(0x1cc)+_0x4d0789+_0x5d02a2(0x1e5)):_0x2d0c12('');}}else{if(_0x3d9b41==='app-code'){const {valid:_0x2634d0,message:_0x9eb56}=_0x1c9a6e(_0x5b2b99);_0x3702f2(_0x2634d0?'':_0x9eb56||_0x5d02a2(0x220));}}return _0x5b2b99;});}),a41_0x198c89(Box,{'flexDirection':_0xcc52e2(0x1fd),'marginTop':0x1,'children':[_0x2d64a2[_0xcc52e2(0x1c3)]===0x0&&a41_0x4492c3(Box,{'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x217),'children':_0xcc52e2(0x219)})}),_0x2d64a2['map'](_0xb743b1=>a41_0x198c89(Box,{'children':[a41_0x198c89(Text,{'color':'green','children':['√\x20',_0xb743b1[_0xcc52e2(0x1ff)],':\x20']}),a41_0x4492c3(Text,{'color':_0xcc52e2(0x217),'children':_0xb743b1[_0xcc52e2(0x1df)]})]},_0xb743b1[_0xcc52e2(0x20d)])),_0x3d9b41===_0xcc52e2(0x212)&&a41_0x198c89(a41_0x3e123d,{'children':[a41_0x198c89(Box,{'children':[a41_0x4492c3(Text,{'children':_0xcc52e2(0x1fe)}),_0x5b51b5?a41_0x4492c3(Text,{'color':'green','children':_0x5b51b5}):a41_0x4492c3(Text,{'color':_0xcc52e2(0x209),'children':_0x21ec2c}),_0x45d882&&a41_0x198c89(Text,{'color':'red','children':[_0xcc52e2(0x215),_0x45d882]}),_0x784d0b&&a41_0x198c89(Text,{'color':_0xcc52e2(0x1f4),'children':['\x20←\x20',_0x784d0b]})]}),!_0x45d882&&!_0x784d0b&&!_0x5b51b5&&a41_0x4492c3(Box,{'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x209),'children':_0xcc52e2(0x1ef)})})]}),_0x3d9b41===_0xcc52e2(0x21f)&&a41_0x198c89(a41_0x3e123d,{'children':[a41_0x198c89(Box,{'children':[a41_0x4492c3(Text,{'children':_0xcc52e2(0x1db)}),a41_0x4492c3(Text,{'color':_0xcc52e2(0x209),'children':'[可选]:\x20'}),a41_0x4492c3(Text,{'color':'green','children':_0x5b51b5}),_0x45d882&&a41_0x198c89(Text,{'color':'red','children':[_0xcc52e2(0x215),_0x45d882]})]}),!_0x45d882&&a41_0x4492c3(Box,{'children':a41_0x198c89(Text,{'color':_0xcc52e2(0x209),'children':['\x20','绑定应用AppCode可自动配置\x20API,如:\x20app-c4c89304\x20(直接回车跳过)']})})]}),_0x3d9b41===_0xcc52e2(0x1f7)&&a41_0x198c89(Box,{'children':[a41_0x4492c3(Text,{'children':_0xcc52e2(0x1dd)}),_0x57d751&&a41_0x4492c3(Text,{'color':_0xcc52e2(0x209),'children':'\x20检查中...'})]}),_0x3d9b41==='confirm-api-pull'&&a41_0x198c89(a41_0x3e123d,{'children':[a41_0x4492c3(Box,{'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x1d2),'children':'√\x20检测到有效登录状态'})}),a41_0x4492c3(Box,{'marginTop':0x1,'children':a41_0x4492c3(Text,{'children':_0xcc52e2(0x210)})}),a41_0x198c89(Box,{'marginLeft':0x2,'children':[a41_0x198c89(Text,{'color':_0x1e1093===0x0?_0xcc52e2(0x1d2):'gray','children':[_0x1e1093===0x0?'▶\x20':'\x20\x20',_0xcc52e2(0x1e1)]}),a41_0x4492c3(Text,{'children':'\x20'}),a41_0x198c89(Text,{'color':_0x1e1093===0x1?'green':'gray','children':[_0x1e1093===0x1?'▶\x20':'\x20\x20','No']})]}),a41_0x4492c3(Box,{'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x209),'children':_0xcc52e2(0x1e9)})}),a41_0x4492c3(Box,{'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x1d0),'children':'\x20\x20推荐选择\x20Yes,可自动配置\x20API\x20接口'})})]}),_0x3d9b41===_0xcc52e2(0x1f3)&&a41_0x198c89(a41_0x3e123d,{'children':[a41_0x4492c3(Box,{'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x1d2),'children':'√'})}),a41_0x4492c3(Box,{'marginTop':0x1,'children':a41_0x4492c3(Text,{'children':_0xcc52e2(0x1ee)})}),a41_0x198c89(Box,{'marginLeft':0x2,'children':[a41_0x198c89(Text,{'color':_0x3ff843===0x0?_0xcc52e2(0x1d2):_0xcc52e2(0x209),'children':[_0x3ff843===0x0?'▶\x20':'\x20\x20','Yes']}),a41_0x4492c3(Text,{'children':'\x20'}),a41_0x198c89(Text,{'color':_0x3ff843===0x1?_0xcc52e2(0x1d2):_0xcc52e2(0x209),'children':[_0x3ff843===0x1?'▶\x20':'\x20\x20','No']})]}),_0xe081b1&&_0x3ff843===0x0&&a41_0x198c89(a41_0x3e123d,{'children':[a41_0x4492c3(Box,{'marginTop':0x1,'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x209),'children':'\x20\x20使用\x20←→\x20返回修改选择,回车确认\x20IDE'})}),a41_0x198c89(Box,{'marginTop':0x1,'flexDirection':_0xcc52e2(0x1fd),'children':[a41_0x4492c3(Text,{'bold':!![],'color':_0xcc52e2(0x1d0),'children':_0xcc52e2(0x1da)}),IDE_LIST[_0xcc52e2(0x1c5)]((_0x51e6dc,_0xab60c9)=>{const _0x3a9cf4=_0xcc52e2,_0x2654b4=_0x2f157d===_0xab60c9,_0x18c247=_0x33732e[_0x3a9cf4(0x1b2)](_0xab60c9),_0x3968b3=MCP_IDES['has'](_0x51e6dc);return a41_0x4492c3(Box,{'children':a41_0x198c89(Text,{'backgroundColor':_0x2654b4?_0x3a9cf4(0x20a):undefined,'color':_0x2654b4?_0x3a9cf4(0x1fc):undefined,'children':['\x20\x20',_0x18c247?_0x3a9cf4(0x1b8):_0x3a9cf4(0x1ba),'\x20',IDE_CONFIGS[_0x51e6dc][_0x3a9cf4(0x1d1)],_0x3968b3&&a41_0x4492c3(Text,{'color':_0x2654b4?'white':'cyan','children':_0x3a9cf4(0x221)}),'\x20',a41_0x198c89(Text,{'color':_0x2654b4?'white':_0x3a9cf4(0x209),'dimColor':!_0x2654b4,'children':['-\x20',IDE_CONFIGS[_0x51e6dc][_0x3a9cf4(0x1bf)]]})]})},_0x51e6dc);}),a41_0x4492c3(Box,{'marginTop':0x1,'children':a41_0x198c89(Text,{'color':_0xcc52e2(0x209),'children':['\x20','↑/↓:\x20移动\x20空格:\x20切换\x20a:\x20全选\x20i/r:\x20反选\x20Enter:\x20确认']})})]})]}),!_0xe081b1&&a41_0x4492c3(Box,{'marginTop':0x1,'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x209),'children':_0xcc52e2(0x1e9)})}),_0x45d882&&a41_0x4492c3(Box,{'marginTop':0x1,'children':a41_0x198c89(Text,{'color':_0xcc52e2(0x1f4),'children':['✗\x20',_0x45d882]})})]}),_0x3d9b41===_0xcc52e2(0x1ec)&&a41_0x198c89(a41_0x3e123d,{'children':[a41_0x4492c3(Box,{'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x1d0),'children':_0xcc52e2(0x1c0)})}),a41_0x4492c3(Box,{'marginTop':0x1,'children':a41_0x4492c3(Text,{'children':_0xcc52e2(0x1f9)})}),a41_0x198c89(Box,{'marginLeft':0x2,'children':[a41_0x198c89(Text,{'color':_0x5c36fe===0x0?_0xcc52e2(0x1d2):_0xcc52e2(0x209),'children':[_0x5c36fe===0x0?'▶\x20':'\x20\x20',_0xcc52e2(0x1e1)]}),a41_0x4492c3(Text,{'children':'\x20'}),a41_0x198c89(Text,{'color':_0x5c36fe===0x1?_0xcc52e2(0x1d2):_0xcc52e2(0x209),'children':[_0x5c36fe===0x1?'▶\x20':'\x20\x20','No']})]}),a41_0x4492c3(Box,{'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x209),'children':_0xcc52e2(0x1e9)})})]}),_0x3d9b41==='login-process'&&a41_0x198c89(Box,{'children':[a41_0x4492c3(Text,{'children':_0xcc52e2(0x1c2)}),_0x4ee5ea&&a41_0x4492c3(Text,{'color':_0xcc52e2(0x209),'children':_0xcc52e2(0x1ea)})]}),_0x3d9b41===_0xcc52e2(0x205)&&a41_0x4492c3(Box,{'children':a41_0x4492c3(Text,{'color':_0xcc52e2(0x1d2),'children':_0xcc52e2(0x1fb)})})]});}
1
+ const a41_0x970f9c=a41_0x5792;(function(_0x54cb09,_0x5bfa0a){const _0x2c0c58=a41_0x5792,_0x4fa642=_0x54cb09();while(!![]){try{const _0x156063=parseInt(_0x2c0c58(0x1f7))/0x1*(parseInt(_0x2c0c58(0x1e1))/0x2)+parseInt(_0x2c0c58(0x22d))/0x3*(parseInt(_0x2c0c58(0x205))/0x4)+-parseInt(_0x2c0c58(0x1c6))/0x5*(-parseInt(_0x2c0c58(0x1da))/0x6)+-parseInt(_0x2c0c58(0x21f))/0x7*(-parseInt(_0x2c0c58(0x21a))/0x8)+-parseInt(_0x2c0c58(0x1d9))/0x9+-parseInt(_0x2c0c58(0x1ed))/0xa+-parseInt(_0x2c0c58(0x1e9))/0xb;if(_0x156063===_0x5bfa0a)break;else _0x4fa642['push'](_0x4fa642['shift']());}catch(_0x1c9068){_0x4fa642['push'](_0x4fa642['shift']());}}}(a41_0x2f7a,0x5f1dc));function a41_0x5792(_0x1c8e33,_0x4af5dd){_0x1c8e33=_0x1c8e33-0x1c0;const _0x2f7a38=a41_0x2f7a();let _0x5792ef=_0x2f7a38[_0x1c8e33];return _0x5792ef;}import{jsx as a41_0x51266c,jsxs as a41_0x26a188,Fragment as a41_0x10654c}from'react/jsx-runtime';import{useState}from'react';import{Text,Box,useInput}from'ink';import{existsSync}from'node:fs';import a41_0x52aa9d from'node:path';import{getIsSessionValid}from'../auth/is-session-valid.js';import{authServer}from'../auth/auth-server.js';import{readConfig}from'../utils/config.js';const IDE_CONFIGS={'cursor':{'name':'Cursor','description':a41_0x970f9c(0x226)},'windsurf':{'name':a41_0x970f9c(0x1cf),'description':a41_0x970f9c(0x1f2)},'claude':{'name':a41_0x970f9c(0x223),'description':a41_0x970f9c(0x212)},'codex':{'name':a41_0x970f9c(0x1e7),'description':a41_0x970f9c(0x227)},'opencode':{'name':a41_0x970f9c(0x1ef),'description':a41_0x970f9c(0x1c4)},'qoder':{'name':a41_0x970f9c(0x210),'description':a41_0x970f9c(0x1cd)},'codebuddy':{'name':a41_0x970f9c(0x1c9),'description':'CodeBuddy\x20IDE\x20(.codebuddy/skills/)'},'trae':{'name':'Trae','description':a41_0x970f9c(0x1ea)},'antigravity':{'name':a41_0x970f9c(0x207),'description':a41_0x970f9c(0x1d3)},'agent':{'name':a41_0x970f9c(0x1ca),'description':a41_0x970f9c(0x21c)}},IDE_LIST=[a41_0x970f9c(0x1ee),a41_0x970f9c(0x225),a41_0x970f9c(0x1e0),a41_0x970f9c(0x1dc),a41_0x970f9c(0x1e4),'opencode',a41_0x970f9c(0x200),a41_0x970f9c(0x1d6),a41_0x970f9c(0x1f3),'agent'],MCP_IDES=new Set([a41_0x970f9c(0x1e4),a41_0x970f9c(0x225)]);export function EnhancedGuidedCreate(_0x76120d){const _0x66eae1=a41_0x970f9c,{onCreate:_0x3f3a01,env:_0x1023a0}=_0x76120d,[_0x29605b,_0x158a70]=useState('project-name'),[_0x55cefb,_0x45b75c]=useState(''),[_0x586bd5,_0x4a525b]=useState(''),[_0x97e78e,_0x1878ad]=useState(''),[_0x46f705,_0x55a882]=useState(''),[_0x4f818e,_0x12edd7]=useState([]),[_0x3180b5,_0x25a628]=useState(null),[_0x4383a1,_0x3b276f]=useState(![]),[_0x2a700e,_0x537e40]=useState(![]),[_0x412590,_0x2c4aca]=useState(![]),[_0x2fc428,_0x3b5df9]=useState(0x0),[_0x1c7dba,_0x15b0e4]=useState(0x0),[_0x3f063f,_0x2c24e5]=useState(0x0),[_0x587465,_0x2f55e0]=useState(![]),[_0x5488c7,_0x211827]=useState(new Set()),[_0x2f22cf,_0x21853b]=useState(0x0),[_0x4932c7,_0x408476]=useState(''),_0x33b476=_0x66eae1(0x1fd),_0x35dfe0=readConfig(),_0x37e43b=typeof _0x35dfe0[_0x66eae1(0x1fa)]==='string'?_0x35dfe0['env']:undefined;function _0x568609(_0x3e8845){const _0x5f5bce=_0x66eae1,_0x190dc0=_0x3e8845||_0x33b476,_0x4d7a40=a41_0x52aa9d['resolve'](process[_0x5f5bce(0x211)](),_0x190dc0);return existsSync(_0x4d7a40);}function _0x5c90da(_0x467eec){const _0x21b039=_0x66eae1;if(_0x467eec['length']>0x32)return{'valid':![],'message':_0x21b039(0x1ec)};const _0x4bf581=/^[A-Za-z0-9][A-Za-z0-9_-]*$/;if(_0x467eec?.[_0x21b039(0x1c7)]()&&!_0x4bf581[_0x21b039(0x219)](_0x467eec))return{'valid':![],'message':_0x21b039(0x213)};return{'valid':!![]};}function _0x2f07cc(_0x282861){const _0x1cdc52=_0x66eae1;if(!_0x282861[_0x1cdc52(0x1c7)]())return{'valid':!![]};if(_0x282861[_0x1cdc52(0x21e)]>0x64)return{'valid':![],'message':'应用AppCode长度不能超过\x20100\x20个字符'};const _0x283324=/^[a-zA-Z0-9][a-zA-Z0-9_-]*$/;if(!_0x283324['test'](_0x282861))return{'valid':![],'message':_0x1cdc52(0x203)};return{'valid':!![]};}async function _0x3ec4ea(){_0x3b276f(!![]);try{const _0x3a0cc6=await getIsSessionValid();return _0x25a628(_0x3a0cc6),_0x3a0cc6;}catch(_0x386da0){return _0x25a628(![]),![];}finally{_0x3b276f(![]);}}async function _0x2dd2e1(){_0x537e40(!![]);try{const _0x412c99=await authServer({'silent':!![]});return _0x25a628(_0x412c99),_0x412c99;}catch(_0x56f7a9){return _0x25a628(![]),![];}finally{_0x537e40(![]);}}return useInput(async(_0x9d3fe9,_0x2f7022)=>{const _0x267330=_0x66eae1;if(_0x2f7022[_0x267330(0x1cb)]||_0x2f7022[_0x267330(0x221)]){if(_0x29605b===_0x267330(0x20c)){_0x3b5df9(_0x41663b=>_0x41663b===0x0?0x1:0x0);return;}if(_0x29605b==='lovrabet-setup-selection'){if(!_0x587465){_0x2c24e5(_0x2ae8f1=>_0x2ae8f1===0x0?0x1:0x0);return;}_0x2f55e0(![]);return;}if(_0x29605b===_0x267330(0x21d)){_0x15b0e4(_0x2fe77c=>_0x2fe77c===0x0?0x1:0x0);return;}}if(_0x29605b===_0x267330(0x22b)&&_0x587465&&_0x3f063f===0x0){if(_0x2f7022['upArrow']){_0x21853b(_0x154f57=>_0x154f57>0x0?_0x154f57-0x1:IDE_LIST[_0x267330(0x21e)]-0x1);return;}if(_0x2f7022[_0x267330(0x229)]){_0x21853b(_0x50f8c1=>_0x50f8c1<IDE_LIST[_0x267330(0x21e)]-0x1?_0x50f8c1+0x1:0x0);return;}}if(_0x9d3fe9==='\x20'&&_0x29605b===_0x267330(0x22b)&&_0x587465&&_0x3f063f===0x0){_0x211827(_0x5187d4=>{const _0x1e7ff3=_0x267330,_0x4c5625=new Set(_0x5187d4);return _0x4c5625[_0x1e7ff3(0x1f5)](_0x2f22cf)?_0x4c5625[_0x1e7ff3(0x1de)](_0x2f22cf):_0x4c5625[_0x1e7ff3(0x1c5)](_0x2f22cf),_0x4c5625;}),_0x55a882('');return;}if((_0x9d3fe9==='a'||_0x9d3fe9==='A')&&_0x29605b===_0x267330(0x22b)&&_0x587465&&_0x3f063f===0x0){_0x211827(new Set(IDE_LIST[_0x267330(0x1e8)]((_0x1478ec,_0x4da160)=>_0x4da160))),_0x55a882('');return;}if((_0x9d3fe9==='i'||_0x9d3fe9==='I'||_0x9d3fe9==='r'||_0x9d3fe9==='R')&&_0x29605b==='lovrabet-setup-selection'&&_0x587465&&_0x3f063f===0x0){_0x211827(_0x475a98=>{const _0x5809e4=_0x267330,_0x253ff1=new Set();for(let _0x63a820=0x0;_0x63a820<IDE_LIST[_0x5809e4(0x21e)];_0x63a820++){!_0x475a98['has'](_0x63a820)&&_0x253ff1[_0x5809e4(0x1c5)](_0x63a820);}return _0x253ff1;});return;}if(_0x2f7022[_0x267330(0x1fc)]){if(_0x29605b===_0x267330(0x202)){const _0x28ebf0=_0x97e78e[_0x267330(0x1c7)]()||_0x33b476;if(_0x46f705)return;if(_0x568609(_0x28ebf0)){_0x408476(_0x267330(0x1c3)+_0x28ebf0+'\x22\x20已存在,请使用其他名称');return;}_0x45b75c(_0x28ebf0),_0x12edd7([{'step':_0x267330(0x202),'label':_0x267330(0x20d),'value':_0x28ebf0}]),_0x1878ad(''),_0x55a882(''),_0x408476(''),_0x158a70(_0x267330(0x1d7));return;}if(_0x29605b==='app-code'){if(_0x46f705)return;const _0x1f59c2=_0x97e78e[_0x267330(0x1c7)]();_0x4a525b(_0x1f59c2),_0x12edd7(_0x343ce9=>[..._0x343ce9,{'step':'app-code','label':_0x267330(0x20f),'value':_0x1f59c2||'未设置'}]),_0x1878ad(''),_0x55a882('');if(_0x1f59c2){_0x158a70(_0x267330(0x1d8));const _0x31a6a1=await _0x3ec4ea();_0x31a6a1?_0x158a70(_0x267330(0x20c)):_0x158a70(_0x267330(0x21d));}else{const _0x5a4cea=_0x1023a0||_0x37e43b||_0x267330(0x1c1);_0x3f3a01({'projectName':_0x55cefb,'appCode':undefined,'pullApi':![],'aiSetup':![],'selectedIDEs':[],'env':_0x5a4cea}),_0x158a70('creating');}return;}if(_0x29605b==='confirm-api-pull'){const _0x19fec9=_0x2fc428===0x0;_0x2c4aca(_0x19fec9),_0x12edd7(_0x277bf1=>[..._0x277bf1,{'step':_0x267330(0x1d4),'label':_0x267330(0x1f9),'value':_0x19fec9?'是':'否'}]),_0x158a70('lovrabet-setup-selection');return;}if(_0x29605b==='lovrabet-setup-selection'){if(!_0x587465){_0x2f55e0(!![]);if(_0x3f063f===0x1){_0x12edd7(_0x2cc008=>[..._0x2cc008,{'step':_0x267330(0x218),'label':_0x267330(0x20b),'value':'否'}]);const _0x1c6b10=_0x1023a0||_0x37e43b||_0x267330(0x1c1);_0x3f3a01({'projectName':_0x55cefb,'appCode':_0x586bd5,'pullApi':_0x412590,'aiSetup':![],'selectedIDEs':[],'env':_0x1c6b10}),_0x158a70(_0x267330(0x201));}return;}const _0x4009db=_0x3f063f===0x0;if(_0x4009db){if(_0x5488c7['size']===0x0){_0x55a882(_0x267330(0x1cc));return;}const _0x364a64=Array['from'](_0x5488c7)[_0x267330(0x1e8)](_0x57b423=>IDE_LIST[_0x57b423])['filter'](_0x4470d4=>_0x4470d4!==undefined);_0x12edd7(_0x4ecef1=>[..._0x4ecef1,{'step':_0x267330(0x218),'label':_0x267330(0x20b),'value':_0x364a64['length']+_0x267330(0x1d0)}]);const _0x2f0198=_0x1023a0||_0x37e43b||_0x267330(0x1c1);_0x3f3a01({'projectName':_0x55cefb,'appCode':_0x586bd5,'pullApi':_0x412590,'aiSetup':!![],'selectedIDEs':_0x364a64,'env':_0x2f0198}),_0x158a70(_0x267330(0x201));}else{_0x12edd7(_0x4cd398=>[..._0x4cd398,{'step':'lovrabet-setup','label':_0x267330(0x20b),'value':'否'}]);const _0x1302dd=_0x1023a0||_0x37e43b||_0x267330(0x1c1);_0x3f3a01({'projectName':_0x55cefb,'appCode':_0x586bd5,'pullApi':_0x412590,'aiSetup':![],'selectedIDEs':[],'env':_0x1302dd}),_0x158a70(_0x267330(0x201));}return;}if(_0x29605b===_0x267330(0x21d)){const _0x2e8051=_0x1c7dba===0x0;if(_0x2e8051){_0x158a70('login-process');const _0x4d5985=await _0x2dd2e1();_0x4d5985?(_0x12edd7(_0x2ea2b3=>[..._0x2ea2b3,{'step':_0x267330(0x1c8),'label':_0x267330(0x214),'value':_0x267330(0x1d2)}]),_0x158a70(_0x267330(0x20c))):(_0x12edd7(_0x9facdf=>[..._0x9facdf,{'step':_0x267330(0x1c8),'label':_0x267330(0x214),'value':'登录失败'}]),_0x158a70('lovrabet-setup-selection'));}else _0x12edd7(_0x29c2ff=>[..._0x29c2ff,{'step':_0x267330(0x1c8),'label':_0x267330(0x214),'value':_0x267330(0x1c2)}]),_0x158a70(_0x267330(0x22b));return;}}if(_0x2f7022[_0x267330(0x217)]||_0x2f7022['delete']){_0x1878ad(_0x5be15d=>{const _0x2288a1=_0x267330,_0x5bd2fb=_0x5be15d['slice'](0x0,-0x1);if(_0x29605b==='project-name'){const {valid:_0xfd5a40,message:_0x15d0e9}=_0x5c90da(_0x5bd2fb);_0x55a882(_0xfd5a40?'':_0x15d0e9||_0x2288a1(0x22e));if(_0xfd5a40&&!_0x46f705){const _0x2555ac=_0x5bd2fb||_0x33b476;_0x568609(_0x2555ac)?_0x408476(_0x2288a1(0x1c3)+_0x2555ac+_0x2288a1(0x1df)):_0x408476('');}}else{if(_0x29605b===_0x2288a1(0x1d7)){const {valid:_0x27e0b5,message:_0xbc13d2}=_0x2f07cc(_0x5bd2fb);_0x55a882(_0x27e0b5?'':_0xbc13d2||_0x2288a1(0x1f8));}}return _0x5bd2fb;});return;}if([_0x267330(0x201),_0x267330(0x1d8),'login-process']['includes'](_0x29605b))return;if(_0x29605b===_0x267330(0x20c)||_0x29605b===_0x267330(0x21d)||_0x29605b==='lovrabet-setup-selection')return;_0x1878ad(_0x1038c2=>{const _0x403392=_0x267330,_0x182aa3=_0x1038c2+_0x9d3fe9;if(_0x29605b===_0x403392(0x202)){const {valid:_0x245c5d,message:_0x2099c2}=_0x5c90da(_0x182aa3);_0x55a882(_0x245c5d?'':_0x2099c2||_0x403392(0x22e));if(_0x245c5d&&!_0x46f705){const _0xb68bb0=_0x182aa3||_0x33b476;_0x568609(_0xb68bb0)?_0x408476(_0x403392(0x1c3)+_0xb68bb0+_0x403392(0x1df)):_0x408476('');}}else{if(_0x29605b===_0x403392(0x1d7)){const {valid:_0x190ca5,message:_0x18c402}=_0x2f07cc(_0x182aa3);_0x55a882(_0x190ca5?'':_0x18c402||'应用AppCode不合法');}}return _0x182aa3;});}),a41_0x26a188(Box,{'flexDirection':_0x66eae1(0x222),'marginTop':0x1,'children':[_0x4f818e['length']===0x0&&a41_0x51266c(Box,{'children':a41_0x51266c(Text,{'color':_0x66eae1(0x1eb),'children':_0x66eae1(0x1d1)})}),_0x4f818e[_0x66eae1(0x1e8)](_0x34cfe2=>a41_0x26a188(Box,{'children':[a41_0x26a188(Text,{'color':'green','children':['√\x20',_0x34cfe2[_0x66eae1(0x21b)],':\x20']}),a41_0x51266c(Text,{'color':_0x66eae1(0x1eb),'children':_0x34cfe2['value']})]},_0x34cfe2['step'])),_0x29605b==='project-name'&&a41_0x26a188(a41_0x10654c,{'children':[a41_0x26a188(Box,{'children':[a41_0x51266c(Text,{'children':_0x66eae1(0x1e6)}),_0x97e78e?a41_0x51266c(Text,{'color':_0x66eae1(0x206),'children':_0x97e78e}):a41_0x51266c(Text,{'color':'gray','children':_0x33b476}),_0x46f705&&a41_0x26a188(Text,{'color':_0x66eae1(0x204),'children':[_0x66eae1(0x1f1),_0x46f705]}),_0x4932c7&&a41_0x26a188(Text,{'color':_0x66eae1(0x204),'children':[_0x66eae1(0x1f1),_0x4932c7]})]}),!_0x46f705&&!_0x4932c7&&!_0x97e78e&&a41_0x51266c(Box,{'children':a41_0x51266c(Text,{'color':_0x66eae1(0x1db),'children':_0x66eae1(0x1e3)})})]}),_0x29605b==='app-code'&&a41_0x26a188(a41_0x10654c,{'children':[a41_0x26a188(Box,{'children':[a41_0x51266c(Text,{'children':_0x66eae1(0x20a)}),a41_0x51266c(Text,{'color':_0x66eae1(0x1db),'children':_0x66eae1(0x22a)}),a41_0x51266c(Text,{'color':_0x66eae1(0x206),'children':_0x97e78e}),_0x46f705&&a41_0x26a188(Text,{'color':'red','children':[_0x66eae1(0x1f1),_0x46f705]})]}),!_0x46f705&&a41_0x51266c(Box,{'children':a41_0x26a188(Text,{'color':'gray','children':['\x20',_0x66eae1(0x224)]})})]}),_0x29605b==='login-check'&&a41_0x26a188(Box,{'children':[a41_0x51266c(Text,{'children':_0x66eae1(0x1fe)}),_0x4383a1&&a41_0x51266c(Text,{'color':_0x66eae1(0x1db),'children':_0x66eae1(0x1e2)})]}),_0x29605b==='confirm-api-pull'&&a41_0x26a188(a41_0x10654c,{'children':[a41_0x51266c(Box,{'children':a41_0x51266c(Text,{'color':'green','children':_0x66eae1(0x1fb)})}),a41_0x51266c(Box,{'marginTop':0x1,'children':a41_0x51266c(Text,{'children':'*\x20是否要自动拉取\x20API\x20配置?'})}),a41_0x26a188(Box,{'marginLeft':0x2,'children':[a41_0x26a188(Text,{'color':_0x2fc428===0x0?_0x66eae1(0x206):_0x66eae1(0x1db),'children':[_0x2fc428===0x0?'▶\x20':'\x20\x20',_0x66eae1(0x1dd)]}),a41_0x51266c(Text,{'children':'\x20'}),a41_0x26a188(Text,{'color':_0x2fc428===0x1?_0x66eae1(0x206):'gray','children':[_0x2fc428===0x1?'▶\x20':'\x20\x20','No']})]}),a41_0x51266c(Box,{'children':a41_0x51266c(Text,{'color':_0x66eae1(0x1db),'children':_0x66eae1(0x208)})}),a41_0x51266c(Box,{'children':a41_0x51266c(Text,{'color':'yellow','children':_0x66eae1(0x1f0)})})]}),_0x29605b===_0x66eae1(0x22b)&&a41_0x26a188(a41_0x10654c,{'children':[a41_0x51266c(Box,{'children':a41_0x51266c(Text,{'color':_0x66eae1(0x206),'children':'√'})}),a41_0x51266c(Box,{'marginTop':0x1,'children':a41_0x51266c(Text,{'children':_0x66eae1(0x209)})}),a41_0x26a188(Box,{'marginLeft':0x2,'children':[a41_0x26a188(Text,{'color':_0x3f063f===0x0?'green':_0x66eae1(0x1db),'children':[_0x3f063f===0x0?'▶\x20':'\x20\x20','Yes']}),a41_0x51266c(Text,{'children':'\x20'}),a41_0x26a188(Text,{'color':_0x3f063f===0x1?_0x66eae1(0x206):_0x66eae1(0x1db),'children':[_0x3f063f===0x1?'▶\x20':'\x20\x20','No']})]}),_0x587465&&_0x3f063f===0x0&&a41_0x26a188(a41_0x10654c,{'children':[a41_0x51266c(Box,{'marginTop':0x1,'children':a41_0x51266c(Text,{'color':_0x66eae1(0x1db),'children':_0x66eae1(0x215)})}),a41_0x26a188(Box,{'marginTop':0x1,'flexDirection':_0x66eae1(0x222),'children':[a41_0x51266c(Text,{'bold':!![],'color':'yellow','children':_0x66eae1(0x1ff)}),IDE_LIST[_0x66eae1(0x1e8)]((_0x40910f,_0x252584)=>{const _0x4c6d18=_0x66eae1,_0x35640f=_0x2f22cf===_0x252584,_0x2d95f7=_0x5488c7[_0x4c6d18(0x1f5)](_0x252584),_0x505468=MCP_IDES['has'](_0x40910f);return a41_0x51266c(Box,{'children':a41_0x26a188(Text,{'backgroundColor':_0x35640f?'blue':undefined,'color':_0x35640f?'white':undefined,'children':['\x20\x20',_0x2d95f7?'[✓]':_0x4c6d18(0x1f6),'\x20',IDE_CONFIGS[_0x40910f][_0x4c6d18(0x22c)],_0x505468&&a41_0x51266c(Text,{'color':_0x35640f?_0x4c6d18(0x1e5):_0x4c6d18(0x1eb),'children':_0x4c6d18(0x1c0)}),'\x20',a41_0x26a188(Text,{'color':_0x35640f?'white':_0x4c6d18(0x1db),'dimColor':!_0x35640f,'children':['-\x20',IDE_CONFIGS[_0x40910f][_0x4c6d18(0x228)]]})]})},_0x40910f);}),a41_0x51266c(Box,{'marginTop':0x1,'children':a41_0x26a188(Text,{'color':'gray','children':['\x20',_0x66eae1(0x1f4)]})})]})]}),!_0x587465&&a41_0x51266c(Box,{'marginTop':0x1,'children':a41_0x51266c(Text,{'color':_0x66eae1(0x1db),'children':'\x20\x20使用\x20←→\x20选择,回车确认'})}),_0x46f705&&a41_0x51266c(Box,{'marginTop':0x1,'children':a41_0x26a188(Text,{'color':_0x66eae1(0x204),'children':['✗\x20',_0x46f705]})})]}),_0x29605b===_0x66eae1(0x21d)&&a41_0x26a188(a41_0x10654c,{'children':[a41_0x51266c(Box,{'children':a41_0x51266c(Text,{'color':_0x66eae1(0x1d5),'children':'!\x20未检测到有效登录'})}),a41_0x51266c(Box,{'marginTop':0x1,'children':a41_0x51266c(Text,{'children':_0x66eae1(0x20e)})}),a41_0x26a188(Box,{'marginLeft':0x2,'children':[a41_0x26a188(Text,{'color':_0x1c7dba===0x0?_0x66eae1(0x206):_0x66eae1(0x1db),'children':[_0x1c7dba===0x0?'▶\x20':'\x20\x20','Yes']}),a41_0x51266c(Text,{'children':'\x20'}),a41_0x26a188(Text,{'color':_0x1c7dba===0x1?_0x66eae1(0x206):_0x66eae1(0x1db),'children':[_0x1c7dba===0x1?'▶\x20':'\x20\x20','No']})]}),a41_0x51266c(Box,{'children':a41_0x51266c(Text,{'color':_0x66eae1(0x1db),'children':'\x20\x20使用\x20←→\x20选择,回车确认'})})]}),_0x29605b===_0x66eae1(0x1ce)&&a41_0x26a188(Box,{'children':[a41_0x51266c(Text,{'children':_0x66eae1(0x216)}),_0x2a700e&&a41_0x51266c(Text,{'color':_0x66eae1(0x1db),'children':'\x20登录中...'})]}),_0x29605b==='creating'&&a41_0x51266c(Box,{'children':a41_0x51266c(Text,{'color':'green','children':_0x66eae1(0x220)})})]});}function a41_0x2f7a(){const _0x2dc9f0=['2QFKaeL','\x20检查中...','\x20直接回车确认,或输入自定义名称','cursor','white','*\x20项目名:\x20','Codex','map','9267104ASPair','Trae\x20IDE\x20(.trae/skills/)','cyan','项目名长度不能超过\x2050\x20个字符','4531060ioVEwI','antigravity','OpenCode','\x20\x20推荐选择\x20Yes,可自动配置\x20API\x20接口','\x20←\x20','Windsurf\x20IDE\x20(.windsurf/workflows/)','windsurf','↑/↓:\x20移动\x20空格:\x20切换\x20a:\x20全选\x20i/r:\x20反选\x20Enter:\x20确认','has','[\x20]','274076tfvuDn','应用AppCode不合法','拉取API配置','env','√\x20检测到有效登录状态','return','my-app','*\x20正在检查登录状态...','选择要配置的\x20IDE:','qoder','creating','project-name','应用AppCode只能包含字母、数字、连字符和下划线,且必须以字母或数字开头','red','4BJdfpP','green','Antigravity','\x20\x20使用\x20←→\x20选择,回车确认','*\x20是否配置\x20Lovrabet\x20MCP\x20和\x20Skill?','*\x20应用AppCode\x20','MCP\x20和\x20Skill','confirm-api-pull','项目名','*\x20是否要先登录以便拉取\x20API\x20配置?','应用AppCode','Qoder','cwd','Claude\x20Code\x20(.claude/skills/\x20+\x20MCP\x20服务器)','项目名只能以字母或数字开头,且只包含字母、数字、-\x20和\x20_','登录状态','\x20\x20使用\x20←→\x20返回修改选择,回车确认\x20IDE','*\x20正在登录,请前往浏览器完成登录...','backspace','lovrabet-setup','test','8XamQgv','label','通用模板\x20(.agent/skills/)\x20-\x20兜底方案','login-prompt','length','3939873vRBxGb','*\x20正在创建项目...','rightArrow','column','Claude\x20Code','绑定应用AppCode可自动配置\x20API,如:\x20app-c4c89304\x20(直接回车跳过)','claude','Cursor\x20IDE\x20(.cursorrules\x20+\x20MCP\x20服务器)','Codex\x20IDE\x20(.codex/skills/)','description','downArrow','[可选]:\x20','lovrabet-setup-selection','name','1014459isCqmZ','项目名不合法','\x20+MCP','online','跳过登录','目录\x20\x22','OpenCode\x20IDE\x20(.opencode/skills/)','add','15cEjtHZ','trim','login','CodeBuddy','其他\x20(通用模板)','leftArrow','请至少选择一个\x20IDE','Qoder\x20IDE\x20(.qoder/rules/\x20+\x20.qoder/skills/)','login-process','Windsurf','\x20个\x20IDE','*\x20创建新项目','已登录','Antigravity\x20IDE\x20(.agent/skills/)','api-pull','yellow','trae','app-code','login-check','1461006QJtqnP','1344864aznwjj','gray','codex','Yes','delete','\x22\x20已存在','codebuddy'];a41_0x2f7a=function(){return _0x2dc9f0;};return a41_0x2f7a();}
@@ -1 +1 @@
1
- (function(_0x5b0803,_0x345992){const _0x463bea=a42_0x317e,_0x4dc10d=_0x5b0803();while(!![]){try{const _0x399efa=-parseInt(_0x463bea(0x1ad))/0x1*(parseInt(_0x463bea(0x1ac))/0x2)+-parseInt(_0x463bea(0x1a4))/0x3+parseInt(_0x463bea(0x1a7))/0x4*(parseInt(_0x463bea(0x1ab))/0x5)+-parseInt(_0x463bea(0x1a5))/0x6+-parseInt(_0x463bea(0x1a3))/0x7*(parseInt(_0x463bea(0x1af))/0x8)+-parseInt(_0x463bea(0x1ae))/0x9+parseInt(_0x463bea(0x1aa))/0xa*(parseInt(_0x463bea(0x1a8))/0xb);if(_0x399efa===_0x345992)break;else _0x4dc10d['push'](_0x4dc10d['shift']());}catch(_0x2d1238){_0x4dc10d['push'](_0x4dc10d['shift']());}}}(a42_0x56bf,0x9c2cf));export function formatElapsed(_0x3f175a){const _0x3167be=a42_0x317e,_0x57bc7f=Date[_0x3167be(0x1a6)]()-_0x3f175a;if(_0x57bc7f<0x3e8)return _0x57bc7f+'ms';const _0x508f08=(_0x57bc7f/0x3e8)['toFixed'](0x2),_0x3d5658=_0x508f08[_0x3167be(0x1a9)](/\.?0+$/u,'');return _0x3d5658+'s';}function a42_0x317e(_0x3c2bdc,_0x3239db){_0x3c2bdc=_0x3c2bdc-0x1a3;const _0x56bf86=a42_0x56bf();let _0x317ee6=_0x56bf86[_0x3c2bdc];return _0x317ee6;}function a42_0x56bf(){const _0x34bb43=['1255190DPZXVK','917170gcKusZ','86XnVDds','17332bmTVic','265149VspmNO','640akPeDe','58303DXxFLD','487191yUyIUp','5716446MDHdSv','now','4zOvWiI','264hglFEJ','replace'];a42_0x56bf=function(){return _0x34bb43;};return a42_0x56bf();}
1
+ (function(_0xffdeab,_0xedfd9e){const _0x4da06d=a42_0x1df1,_0x56b870=_0xffdeab();while(!![]){try{const _0x4b3024=parseInt(_0x4da06d(0x7f))/0x1+-parseInt(_0x4da06d(0x88))/0x2*(-parseInt(_0x4da06d(0x8c))/0x3)+parseInt(_0x4da06d(0x8a))/0x4*(-parseInt(_0x4da06d(0x84))/0x5)+-parseInt(_0x4da06d(0x85))/0x6*(parseInt(_0x4da06d(0x81))/0x7)+-parseInt(_0x4da06d(0x83))/0x8*(parseInt(_0x4da06d(0x89))/0x9)+-parseInt(_0x4da06d(0x82))/0xa*(-parseInt(_0x4da06d(0x8b))/0xb)+parseInt(_0x4da06d(0x86))/0xc;if(_0x4b3024===_0xedfd9e)break;else _0x56b870['push'](_0x56b870['shift']());}catch(_0x26d87e){_0x56b870['push'](_0x56b870['shift']());}}}(a42_0x3799,0x5bfe0));function a42_0x3799(){const _0x33c71e=['4073148JGOrcY','now','324GphQNX','2637rIEQwV','4BXOEam','297ghYEzv','12219mASrWp','26652ufFcHq','replace','13867ZHCqZd','187010mYMKXw','11536xHTRVc','1349775PXRVjH','1398PtPWsY'];a42_0x3799=function(){return _0x33c71e;};return a42_0x3799();}function a42_0x1df1(_0x2f04bd,_0x41c484){_0x2f04bd=_0x2f04bd-0x7f;const _0x3799b8=a42_0x3799();let _0x1df1ed=_0x3799b8[_0x2f04bd];return _0x1df1ed;}export function formatElapsed(_0x357474){const _0x3568d0=a42_0x1df1,_0x344674=Date[_0x3568d0(0x87)]()-_0x357474;if(_0x344674<0x3e8)return _0x344674+'ms';const _0x2530cf=(_0x344674/0x3e8)['toFixed'](0x2),_0x47330e=_0x2530cf[_0x3568d0(0x80)](/\.?0+$/u,'');return _0x47330e+'s';}
@@ -1 +1 @@
1
- const a43_0x7dd26=a43_0x3696;(function(_0x1ee963,_0x15db06){const _0x326bac=a43_0x3696,_0xb8356a=_0x1ee963();while(!![]){try{const _0x154d56=-parseInt(_0x326bac(0x10e))/0x1+parseInt(_0x326bac(0x109))/0x2+parseInt(_0x326bac(0xfc))/0x3*(parseInt(_0x326bac(0xec))/0x4)+parseInt(_0x326bac(0xe0))/0x5+-parseInt(_0x326bac(0x144))/0x6*(parseInt(_0x326bac(0x127))/0x7)+-parseInt(_0x326bac(0xef))/0x8*(-parseInt(_0x326bac(0xf8))/0x9)+parseInt(_0x326bac(0x13b))/0xa*(-parseInt(_0x326bac(0x105))/0xb);if(_0x154d56===_0x15db06)break;else _0xb8356a['push'](_0xb8356a['shift']());}catch(_0x48355e){_0xb8356a['push'](_0xb8356a['shift']());}}}(a43_0x293a,0x1d957));import{jsx as a43_0x2e7a81,Fragment as a43_0x3d6ea5,jsxs as a43_0x46344a}from'react/jsx-runtime';import a43_0x2ba865 from'path';import a43_0x42c93d from'fs';import{fileURLToPath}from'node:url';import{Box,Text}from'ink';import{useEffect,useState}from'react';import{EnhancedGuidedCreate}from'./enhanced-guided-create.js';import{pullApiSilent}from'../api/pull-silent.js';import{readConfig}from'../utils/config.js';import{useCopyProjectTemplate}from'./use-copy-project-template.js';import{useInstallDependencies}from'./use-install-dependencies.js';import{useFormatCode}from'./use-format-code.js';import{TaskFinished}from'./task-finished.js';import{TaskRunning}from'./task-running.js';import{logger}from'../utils/logger.js';import{configureMcp,copySharedSkills,installSkill,createSkillManifest}from'../ai-setup/config.js';function a43_0x3696(_0x274be5,_0x5f09e8){_0x274be5=_0x274be5-0xd5;const _0x293ab1=a43_0x293a();let _0x369664=_0x293ab1[_0x274be5];return _0x369664;}function a43_0x293a(){const _0x315f05=['green','online','lovrabet\x20api\x20pull','*\x20清理失败的项目目录:\x20','1.\x20','env','join','error','writeFileSync','\x20\x20•\x20MCP\x20服务器:\x20','项目创建完成:\x20','resolve','×\x20项目名过长,最多支持\x20100\x20个字符','项目名称:\x20','warn','length','×\x20项目目录\x20','252745VUmOTa','Claude\x20Code','\x20MCP\x20','API\x20配置拉取成功:\x20','\x20Skill\x20','doTask','\x20&&\x20lovrabet\x20start','utf8','log','has','lovrabet\x20config\x20set\x20appcode\x20[app-code]','skill','2048SWPNwl','manual','parse','32qMXjqG','lovrabet\x20api\x20pull\x20--appcode\x20[app-code]','accessSync','repeat','status','constants','!\x20API\x20配置拉取失败,可稍后手动执行:\x20lovrabet\x20api\x20pull','package.json','√\x20package.json\x20已更新:\x20name=','176868CjWzUR','√\x20Lovrabet\x20MCP\x20和\x20Skill\x20配置完成','*\x20正在配置\x20Lovrabet\x20MCP\x20和\x20Skill...','配置应用AppCode:\x20','1167NUasJo','.lovrabetrc','\x20\x20✗\x20MCP\x20','red','项目创建失败:\x20','readFileSync','1.\x20配置\x20Lovrabet\x20MCP\x20和\x20Skill','√\x20配置文件已创建,可稍后使用\x20\x27lovrabet\x20config\x20set\x20appcode\x20<app-code>\x27\x20配置','清理项目目录失败:\x20','1507hvtRLD','\x20已存在,请使用其他项目名','gray','启动项目:\x20','71494Awagvd','trim','×\x20项目名包含非法字符,不允许使用:\x20<\x20>\x20:\x20\x22\x20|\x20?\x20*\x20及控制字符','mcp','√\x20API\x20配置拉取完成','125096DliFKU','cd\x20','*\x20正在为项目\x20','✓\x20Skill\x20安装完成:','map','\x20|\x20应用AppCode:\x20','Cursor','yellow','push','filter','existsSync','setLogPath','×\x20无法在当前目录创建项目,请检查目录权限','3.\x20','!\x20API\x20配置拉取异常,项目已创建,可稍后手动执行:\x20lovrabet\x20api\x20pull','cwd','pullApi','W_OK','toLocaleString','success','version','projectCode','开始创建项目:\x20','×\x20项目名不能为空','selectedIDEs','7AmwwJX','更新\x20package.json\x20name','appCode','API\x20配置拉取失败:\x20','aiSetup','dirname','拉取API配置:\x20','\x20√\x20','stringify','skill-','../..','cursor','更新\x20package.json\x20失败','message','1.0.0','\x20\x20✗\x20Skill\x20','column','✓\x20MCP\x20服务器配置完成:','ide','\x20创建配置文件','4910hebzvm','\x20配置应用AppCode:\x20','cyan','🚀\x20接下来:','white','2.\x20','description','name','*\x20正在拉取\x20API\x20配置...','303204aBznFP','create','info','projectName','\x20Generated\x20by\x20lovrabet\x20cli\x20','claude','string'];a43_0x293a=function(){return _0x315f05;};return a43_0x293a();}const MCP_IDES=new Set([a43_0x7dd26(0x132),a43_0x7dd26(0x149)]);export function CreateApp(_0x357243){const _0x3cf7f9=a43_0x7dd26,[_0x2a5a31,_0xea32f4]=useState(![]),[_0x84548e,_0xf1c6b0]=useState(![]),[_0x25d940,_0x2e27b4]=useState(null),[_0x3bd517,_0x5addfe]=useState(null),_0x2cfccc=useCopyProjectTemplate(),_0x494093=useInstallDependencies(),_0x39df13=useFormatCode(),_0x328f58=async _0x4c2c5b=>{const _0x5042f4=a43_0x3696;if(!_0x4c2c5b[_0x5042f4(0x147)]||_0x4c2c5b[_0x5042f4(0x147)][_0x5042f4(0x10a)]()===''){console['error'](_0x5042f4(0x125));return;}const _0x26f00e=/[<>:"|?*\x00-\x1f\x7f]/;if(_0x26f00e['test'](_0x4c2c5b['projectName'])){console[_0x5042f4(0xd6)](_0x5042f4(0x10b));return;}if(_0x4c2c5b[_0x5042f4(0x147)][_0x5042f4(0xde)]>0x64){console[_0x5042f4(0xd6)](_0x5042f4(0xdb));return;}const _0x29e262=a43_0x2ba865[_0x5042f4(0xda)](process[_0x5042f4(0x11d)](),_0x4c2c5b[_0x5042f4(0x147)]);if(a43_0x42c93d[_0x5042f4(0x118)](_0x29e262)){console['error'](_0x5042f4(0xdf)+_0x4c2c5b[_0x5042f4(0x147)]+_0x5042f4(0x106));return;}try{const _0x90f31b=a43_0x2ba865[_0x5042f4(0x12c)](_0x29e262);a43_0x42c93d[_0x5042f4(0xf1)](_0x90f31b,a43_0x42c93d[_0x5042f4(0xf4)][_0x5042f4(0x11f)]);}catch(_0xfda1c){console[_0x5042f4(0xd6)](_0x5042f4(0x11a));return;}_0x2e27b4(_0x4c2c5b),_0xea32f4(!![]),logger[_0x5042f4(0x119)](_0x29e262),logger[_0x5042f4(0x146)](_0x5042f4(0x145),_0x5042f4(0x124)+_0x4c2c5b[_0x5042f4(0x147)],{'projectDir':_0x29e262,'appCode':_0x4c2c5b[_0x5042f4(0x129)]});try{await _0x2cfccc[_0x5042f4(0xe5)](_0x4c2c5b[_0x5042f4(0x147)]),await _0x450c29(_0x4c2c5b['projectName']),await _0x494093['doTask'](_0x4c2c5b[_0x5042f4(0x147)]),await _0x39df13[_0x5042f4(0xe5)](_0x4c2c5b[_0x5042f4(0x147)]),await _0x395e5c(_0x4c2c5b[_0x5042f4(0x147)],_0x4c2c5b['appCode']||'',_0x4c2c5b[_0x5042f4(0x150)]);if(_0x4c2c5b[_0x5042f4(0x11e)]&&_0x4c2c5b[_0x5042f4(0x129)]){console['log'](_0x5042f4(0x143));try{const _0x3e5023=await pullApiSilent(_0x4c2c5b[_0x5042f4(0x129)],undefined,_0x29e262,_0x4c2c5b[_0x5042f4(0x150)]);_0x3e5023?(console[_0x5042f4(0xe8)](_0x5042f4(0x10d)),logger[_0x5042f4(0x146)](_0x5042f4(0x145),_0x5042f4(0xe3)+_0x4c2c5b[_0x5042f4(0x129)])):(console[_0x5042f4(0xe8)](_0x5042f4(0xf5)),logger[_0x5042f4(0xdd)](_0x5042f4(0x145),_0x5042f4(0x12a)+_0x4c2c5b[_0x5042f4(0x129)]));}catch(_0x47bf89){console[_0x5042f4(0xe8)](_0x5042f4(0x11c)),logger[_0x5042f4(0xdd)]('create','API\x20配置拉取异常',{'error':_0x47bf89 instanceof Error?_0x47bf89['message']:String(_0x47bf89)});}}if(_0x4c2c5b[_0x5042f4(0x12b)]&&_0x4c2c5b['selectedIDEs']&&_0x4c2c5b[_0x5042f4(0x126)][_0x5042f4(0xde)]>0x0&&_0x4c2c5b[_0x5042f4(0x129)]){console[_0x5042f4(0xe8)](_0x5042f4(0xfa));const _0x6dbbb2=[],_0x5515f8=[],_0x47f1a9=_0x4c2c5b[_0x5042f4(0x126)][_0x5042f4(0x117)](_0xe96a47=>MCP_IDES[_0x5042f4(0xe9)](_0xe96a47)),_0x32c0e2=_0x4c2c5b['selectedIDEs'];for(const _0x4a4e3f of _0x47f1a9){try{const _0x22b7c9=await configureMcp(_0x4a4e3f,_0x29e262);_0x6dbbb2[_0x5042f4(0x116)]({'ide':_0x4a4e3f===_0x5042f4(0x132)?_0x5042f4(0x114):_0x5042f4(0xe1),'status':_0x22b7c9['status'],'message':_0x22b7c9[_0x5042f4(0x134)]}),console[_0x5042f4(0xe8)]('\x20\x20'+(_0x22b7c9[_0x5042f4(0xf3)]==='success'?'✓':_0x22b7c9[_0x5042f4(0xf3)]===_0x5042f4(0xed)?'⚠️':'✗')+_0x5042f4(0xe2)+_0x4a4e3f+':\x20'+_0x22b7c9[_0x5042f4(0x134)]);}catch(_0x2ad094){_0x6dbbb2['push']({'ide':_0x4a4e3f===_0x5042f4(0x132)?_0x5042f4(0x114):'Claude\x20Code','status':_0x5042f4(0xd6),'message':_0x2ad094 instanceof Error?_0x2ad094[_0x5042f4(0x134)]:String(_0x2ad094)}),console[_0x5042f4(0xe8)](_0x5042f4(0xfe)+_0x4a4e3f+':\x20'+(_0x2ad094 instanceof Error?_0x2ad094[_0x5042f4(0x134)]:String(_0x2ad094)));}}await copySharedSkills(_0x29e262);for(const _0x56eed9 of _0x32c0e2){try{const _0x27d096=await installSkill(_0x56eed9,_0x29e262);_0x5515f8['push']({'ide':_0x27d096[_0x5042f4(0x139)],'status':_0x27d096[_0x5042f4(0xf3)],'message':_0x27d096[_0x5042f4(0x134)]}),console[_0x5042f4(0xe8)]('\x20\x20'+(_0x27d096[_0x5042f4(0xf3)]===_0x5042f4(0x121)?'✓':'✗')+_0x5042f4(0xe4)+_0x27d096[_0x5042f4(0x139)]+':\x20'+_0x27d096[_0x5042f4(0x134)]);}catch(_0x57bb41){_0x5515f8['push']({'ide':_0x56eed9,'status':_0x5042f4(0xd6),'message':_0x57bb41 instanceof Error?_0x57bb41['message']:String(_0x57bb41)}),console[_0x5042f4(0xe8)](_0x5042f4(0x136)+_0x56eed9+':\x20'+(_0x57bb41 instanceof Error?_0x57bb41[_0x5042f4(0x134)]:String(_0x57bb41)));}}if(_0x5515f8[_0x5042f4(0xde)]>0x0){const _0x5bb4aa=_0x5515f8[_0x5042f4(0x117)](_0x533a11=>_0x533a11[_0x5042f4(0xf3)]===_0x5042f4(0x121))[_0x5042f4(0x112)](_0x13e556=>_0x13e556[_0x5042f4(0x139)]);_0x5bb4aa[_0x5042f4(0xde)]>0x0&&createSkillManifest(_0x29e262,_0x5bb4aa);}_0x5addfe({'mcp':_0x6dbbb2,'skill':_0x5515f8}),console[_0x5042f4(0xe8)](_0x5042f4(0xf9));}logger[_0x5042f4(0x121)](_0x5042f4(0x145),_0x5042f4(0xd9)+_0x4c2c5b['projectName']),_0xf1c6b0(!![]),_0xea32f4(![]);}catch(_0x41f1d0){logger[_0x5042f4(0xd6)](_0x5042f4(0x145),_0x5042f4(0x100)+_0x4c2c5b['projectName'],{'error':_0x41f1d0 instanceof Error?_0x41f1d0[_0x5042f4(0x134)]:String(_0x41f1d0)});try{a43_0x42c93d[_0x5042f4(0x118)](_0x29e262)&&(console[_0x5042f4(0xe8)](_0x5042f4(0x14e)+_0x29e262),a43_0x42c93d['rmSync'](_0x29e262,{'recursive':!![],'force':!![]}));}catch(_0x57c98d){logger[_0x5042f4(0xdd)]('create',_0x5042f4(0x104)+_0x29e262);}_0xea32f4(![]),console['error']('×\x20项目创建失败:\x20'+(_0x41f1d0 instanceof Error?_0x41f1d0[_0x5042f4(0x134)]:String(_0x41f1d0)));}},_0x1ffc09=async _0x2665a=>{const _0x2f47a0=a43_0x3696;await _0x328f58({'projectName':_0x2665a,'env':_0x357243[_0x2f47a0(0x150)]});},_0x450c29=async _0x11a790=>{const _0x8996d0=a43_0x3696,_0x28f219=a43_0x2ba865[_0x8996d0(0xda)](process[_0x8996d0(0x11d)](),_0x11a790),_0x5e828b=a43_0x2ba865[_0x8996d0(0xd5)](_0x28f219,'package.json');try{console[_0x8996d0(0xe8)]('*\x20正在更新\x20package.json\x20的\x20name\x20和\x20description\x20字段');const _0x10ac16=fileURLToPath(import.meta.url),_0x5b2365=a43_0x2ba865[_0x8996d0(0xda)](a43_0x2ba865[_0x8996d0(0x12c)](_0x10ac16),_0x8996d0(0x131)),_0x17458f=a43_0x2ba865['join'](_0x5b2365,_0x8996d0(0xf6));let _0x3eb904=_0x8996d0(0x135);try{const _0x4900fd=JSON['parse'](a43_0x42c93d['readFileSync'](_0x17458f,'utf8'));_0x3eb904=_0x4900fd[_0x8996d0(0x122)]||_0x8996d0(0x135);}catch(_0x4be237){}const _0x124ca8=a43_0x42c93d[_0x8996d0(0x101)](_0x5e828b,_0x8996d0(0xe7)),_0xddf74c=JSON['parse'](_0x124ca8);_0xddf74c[_0x8996d0(0x142)]=_0x11a790,_0xddf74c[_0x8996d0(0x141)]=_0x11a790+_0x8996d0(0x148)+_0x3eb904,a43_0x42c93d[_0x8996d0(0xd7)](_0x5e828b,JSON[_0x8996d0(0x12f)](_0xddf74c,null,0x2)+'\x0a',_0x8996d0(0xe7)),console['log'](_0x8996d0(0xf7)+_0x11a790),logger[_0x8996d0(0x146)](_0x8996d0(0x145),_0x8996d0(0x128));}catch(_0x13a650){logger[_0x8996d0(0xd6)](_0x8996d0(0x145),_0x8996d0(0x133));throw _0x13a650;}},_0x395e5c=async(_0x3615a6,_0x2dffd0,_0x33d820)=>{const _0x4f5377=a43_0x3696,_0x1410c3=a43_0x2ba865[_0x4f5377(0xda)](process[_0x4f5377(0x11d)](),_0x3615a6),_0x48d743=a43_0x2ba865[_0x4f5377(0xd5)](_0x1410c3,_0x4f5377(0xfd));try{_0x2dffd0?console['log']('*\x20正在为项目\x20'+_0x3615a6+_0x4f5377(0x13c)+_0x2dffd0):console[_0x4f5377(0xe8)](_0x4f5377(0x110)+_0x3615a6+_0x4f5377(0x13a));const _0x38ec05=fileURLToPath(import.meta.url),_0x1cf56e=a43_0x2ba865[_0x4f5377(0xda)](a43_0x2ba865[_0x4f5377(0x12c)](_0x38ec05),_0x4f5377(0x131)),_0x3f0221=a43_0x2ba865[_0x4f5377(0xd5)](_0x1cf56e,_0x4f5377(0xf6));let _0x498398='1.0.0';try{const _0x8a8482=JSON[_0x4f5377(0xee)](a43_0x42c93d['readFileSync'](_0x3f0221,_0x4f5377(0xe7)));_0x498398=_0x8a8482[_0x4f5377(0x122)]||'1.0.0';}catch(_0x34ceb2){}const _0x5d30ae=readConfig(),_0x49dc4f=typeof _0x5d30ae[_0x4f5377(0x150)]===_0x4f5377(0x14a)?_0x5d30ae[_0x4f5377(0x150)]:undefined,{app:_0x4cabe9,appcode:_0x296019,..._0x1bde33}=_0x5d30ae,_0xf7de43={..._0x1bde33,'appcode':_0x2dffd0||'','env':_0x33d820||_0x49dc4f||_0x4f5377(0x14c),'createdAt':new Date()[_0x4f5377(0x120)](),'version':_0x498398};a43_0x42c93d[_0x4f5377(0xd7)](_0x48d743,JSON[_0x4f5377(0x12f)](_0xf7de43,null,0x2),_0x4f5377(0xe7)),_0x2dffd0?console[_0x4f5377(0xe8)]('√\x20配置文件已创建,应用AppCode:\x20'+_0x2dffd0):console[_0x4f5377(0xe8)](_0x4f5377(0x103)),logger[_0x4f5377(0x146)]('create',_0x4f5377(0xfb)+_0x2dffd0);}catch(_0x50dc22){logger[_0x4f5377(0xd6)]('create','配置应用AppCode失败');}};useEffect(()=>{const _0x5bda2c=a43_0x3696;_0x357243[_0x5bda2c(0x123)]&&_0x1ffc09(_0x357243[_0x5bda2c(0x123)]);},[_0x357243[_0x3cf7f9(0x123)]]);if(!_0x2a5a31&&!_0x84548e&&!_0x357243[_0x3cf7f9(0x123)])return a43_0x2e7a81(EnhancedGuidedCreate,{'onCreate':_0x328f58,'env':_0x357243[_0x3cf7f9(0x150)]});if(_0x2a5a31)return a43_0x46344a(a43_0x3d6ea5,{'children':[a43_0x46344a(Box,{'marginTop':0x1,'children':[a43_0x2e7a81(Box,{'width':'1'}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'children':_0x3cf7f9(0x12e)}),a43_0x2e7a81(Text,{'children':_0x3cf7f9(0xdc)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'children':_0x25d940?.[_0x3cf7f9(0x147)]}),_0x25d940?.[_0x3cf7f9(0x129)]&&a43_0x46344a(a43_0x3d6ea5,{'children':[a43_0x2e7a81(Text,{'children':'\x20|\x20应用AppCode:\x20'}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13d),'children':_0x25d940[_0x3cf7f9(0x129)]})]})]}),a43_0x2e7a81(TaskRunning,{..._0x2cfccc}),a43_0x2e7a81(TaskRunning,{..._0x494093}),a43_0x2e7a81(TaskRunning,{..._0x39df13})]});if(_0x84548e){const _0x11e7fb=_0x3bd517&&(_0x3bd517[_0x3cf7f9(0x10c)][_0x3cf7f9(0xde)]>0x0||_0x3bd517[_0x3cf7f9(0xeb)][_0x3cf7f9(0xde)]>0x0);return a43_0x46344a(a43_0x3d6ea5,{'children':[a43_0x46344a(Box,{'marginTop':0x1,'children':[a43_0x2e7a81(Box,{'width':'1'}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'children':_0x3cf7f9(0x12e)}),a43_0x2e7a81(Text,{'children':_0x3cf7f9(0xdc)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'children':_0x25d940?.['projectName']}),_0x25d940?.[_0x3cf7f9(0x129)]&&a43_0x46344a(a43_0x3d6ea5,{'children':[a43_0x2e7a81(Text,{'children':_0x3cf7f9(0x113)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13d),'children':_0x25d940[_0x3cf7f9(0x129)]})]})]}),a43_0x2e7a81(TaskFinished,{..._0x2cfccc}),a43_0x2e7a81(TaskFinished,{..._0x494093}),a43_0x2e7a81(TaskFinished,{..._0x39df13}),a43_0x2e7a81(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'children':'─'[_0x3cf7f9(0xf2)](0x3c)})}),_0x11e7fb&&a43_0x46344a(a43_0x3d6ea5,{'children':[_0x3bd517[_0x3cf7f9(0x10c)]['length']>0x0&&a43_0x46344a(a43_0x3d6ea5,{'children':[a43_0x2e7a81(Box,{'marginTop':0x1,'children':a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'bold':!![],'children':_0x3cf7f9(0x138)})}),_0x3bd517[_0x3cf7f9(0x10c)][_0x3cf7f9(0x112)]((_0x1969a8,_0x457ef2)=>a43_0x2e7a81(Box,{'marginLeft':0x2,'children':a43_0x46344a(Text,{'color':_0x1969a8[_0x3cf7f9(0xf3)]==='success'?_0x3cf7f9(0x13f):_0x1969a8[_0x3cf7f9(0xf3)]===_0x3cf7f9(0xed)?_0x3cf7f9(0x115):_0x3cf7f9(0xff),'children':[_0x1969a8[_0x3cf7f9(0x139)],':\x20',_0x1969a8['message']]})},'mcp-'+_0x457ef2))]}),_0x3bd517[_0x3cf7f9(0xeb)][_0x3cf7f9(0xde)]>0x0&&a43_0x46344a(a43_0x3d6ea5,{'children':[a43_0x2e7a81(Box,{'marginTop':_0x3bd517[_0x3cf7f9(0x10c)][_0x3cf7f9(0xde)]>0x0?0x1:0x0,'children':a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'bold':!![],'children':_0x3cf7f9(0x111)})}),_0x3bd517['skill'][_0x3cf7f9(0x112)]((_0x2250bd,_0x3c4649)=>a43_0x2e7a81(Box,{'marginLeft':0x2,'children':a43_0x46344a(Text,{'color':_0x2250bd[_0x3cf7f9(0xf3)]===_0x3cf7f9(0x121)?_0x3cf7f9(0x13f):_0x3cf7f9(0xff),'children':[_0x2250bd[_0x3cf7f9(0x139)],':\x20',_0x2250bd['message']]})},_0x3cf7f9(0x130)+_0x3c4649))]}),a43_0x2e7a81(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'children':'─'[_0x3cf7f9(0xf2)](0x3c)})})]}),a43_0x2e7a81(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13d),'bold':!![],'children':_0x3cf7f9(0x13e)})}),a43_0x46344a(Box,{'marginLeft':0x2,'flexDirection':_0x3cf7f9(0x137),'children':[_0x11e7fb?a43_0x46344a(a43_0x3d6ea5,{'children':[a43_0x46344a(Box,{'children':[a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'children':_0x3cf7f9(0x14f)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13f),'children':_0x3cf7f9(0x108)}),a43_0x2e7a81(Text,{'color':'cyan','bold':!![],'children':_0x3cf7f9(0x10f)+_0x25d940?.[_0x3cf7f9(0x147)]+_0x3cf7f9(0xe6)})]}),_0x25d940?.[_0x3cf7f9(0x129)]&&!_0x25d940?.[_0x3cf7f9(0x11e)]&&a43_0x46344a(Box,{'children':[a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x115),'children':_0x3cf7f9(0x140)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13f),'children':_0x3cf7f9(0x12d)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13d),'bold':!![],'children':'lovrabet\x20api\x20pull'})]})]}):a43_0x46344a(a43_0x3d6ea5,{'children':[a43_0x2e7a81(Box,{'children':a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x115),'bold':!![],'children':_0x3cf7f9(0x102)})}),a43_0x46344a(Box,{'marginLeft':0x2,'marginTop':0x1,'children':[a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13f),'children':'\x20\x20•\x20Skill:\x20'}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13d),'bold':!![],'children':'lovrabet\x20skill\x20install'})]}),a43_0x46344a(Box,{'marginLeft':0x2,'children':[a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13f),'children':_0x3cf7f9(0xd8)}),a43_0x2e7a81(Text,{'color':'cyan','bold':!![],'children':'lovrabet\x20mcp\x20install'})]}),a43_0x46344a(Box,{'marginTop':0x1,'children':[a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'children':_0x3cf7f9(0x140)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13f),'children':_0x3cf7f9(0x108)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13d),'bold':!![],'children':_0x3cf7f9(0x10f)+_0x25d940?.[_0x3cf7f9(0x147)]+_0x3cf7f9(0xe6)})]}),_0x25d940?.['appCode']&&!_0x25d940?.[_0x3cf7f9(0x11e)]&&a43_0x46344a(Box,{'children':[a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x115),'children':_0x3cf7f9(0x11b)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13f),'children':_0x3cf7f9(0x12d)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13d),'bold':!![],'children':_0x3cf7f9(0x14d)})]})]}),!_0x25d940?.[_0x3cf7f9(0x129)]&&a43_0x46344a(a43_0x3d6ea5,{'children':[a43_0x46344a(Box,{'children':[a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x107),'children':_0x3cf7f9(0x140)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13f),'children':'配置AppCode:\x20'}),a43_0x2e7a81(Text,{'color':'cyan','bold':!![],'children':_0x3cf7f9(0xea)})]}),a43_0x46344a(Box,{'children':[a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x107),'children':'3.\x20'}),a43_0x2e7a81(Text,{'color':'white','children':_0x3cf7f9(0x12d)}),a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x13d),'bold':!![],'children':_0x3cf7f9(0xf0)})]})]})]}),a43_0x2e7a81(Box,{'marginTop':0x1,'children':a43_0x2e7a81(Text,{'color':_0x3cf7f9(0x14b),'children':'─'[_0x3cf7f9(0xf2)](0x3c)})})]});}return null;}
1
+ const a43_0x2754f5=a43_0x5158;function a43_0x33ac(){const _0x2ada43=['开始创建项目:\x20','71695tpvurI','aiSetup','Claude\x20Code','.lovrabetrc','lovrabet\x20api\x20pull\x20--appcode\x20[app-code]','1.\x20配置\x20Lovrabet\x20MCP\x20和\x20Skill','\x20配置应用AppCode:\x20','√\x20API\x20配置拉取完成','manual','2.\x20','!\x20API\x20配置拉取异常,项目已创建,可稍后手动执行:\x20lovrabet\x20api\x20pull','../..','repeat','test','1.0.0','5882XCqxUO','claude','version','×\x20项目名过长,最多支持\x20100\x20个字符','filter','yellow','status','skill','项目名称:\x20','API\x20配置拉取失败:\x20','拉取API配置:\x20','280643txTjSh','\x20\x20✗\x20MCP\x20','dirname','length','配置应用AppCode:\x20','trim','accessSync','5887084fcuUqj','100uRQnnz','message','existsSync','ide','warn','log','info','create','\x20√\x20','constants','\x20\x20•\x20Skill:\x20','error','\x20创建配置文件','appCode','✓\x20MCP\x20服务器配置完成:','gray','×\x20项目目录\x20','env','3.\x20','*\x20正在为项目\x20','utf8','42075clZaIm','mcp','\x20|\x20应用AppCode:\x20','mcp-','清理项目目录失败:\x20','toLocaleString','cursor','projectCode','white','cwd','741XZEZTN','description','\x20\x20•\x20MCP\x20服务器:\x20','5577300dKfKtt','cyan','cd\x20','lovrabet\x20skill\x20install','lovrabet\x20mcp\x20install','stringify','map','join','启动项目:\x20','doTask','API\x20配置拉取异常','success','parse','name','93256eFoNof','selectedIDEs','push','lovrabet\x20api\x20pull','项目创建完成:\x20','W_OK','√\x20package.json\x20已更新:\x20name=','\x20Generated\x20by\x20lovrabet\x20cli\x20','online','🚀\x20接下来:','\x20\x20✗\x20Skill\x20','!\x20API\x20配置拉取失败,可稍后手动执行:\x20lovrabet\x20api\x20pull','711GRphdr','package.json','readFileSync','projectName','590zkwrKn','*\x20正在配置\x20Lovrabet\x20MCP\x20和\x20Skill...','√\x20配置文件已创建,应用AppCode:\x20','column','√\x20配置文件已创建,可稍后使用\x20\x27lovrabet\x20config\x20set\x20appcode\x20<app-code>\x27\x20配置','API\x20配置拉取成功:\x20','配置AppCode:\x20','red','pullApi','Cursor','green','resolve','\x20Skill\x20','\x20&&\x20lovrabet\x20start','writeFileSync'];a43_0x33ac=function(){return _0x2ada43;};return a43_0x33ac();}(function(_0x3a0798,_0x22aac6){const _0x31b342=a43_0x5158,_0x2f885e=_0x3a0798();while(!![]){try{const _0x54bfdf=parseInt(_0x31b342(0x1e4))/0x1+-parseInt(_0x31b342(0x22e))/0x2*(-parseInt(_0x31b342(0x1ee))/0x3)+-parseInt(_0x31b342(0x241))/0x4*(-parseInt(_0x31b342(0x21f))/0x5)+parseInt(_0x31b342(0x1f1))/0x6+-parseInt(_0x31b342(0x240))/0x7+parseInt(_0x31b342(0x1ff))/0x8*(parseInt(_0x31b342(0x20b))/0x9)+parseInt(_0x31b342(0x20f))/0xa*(-parseInt(_0x31b342(0x239))/0xb);if(_0x54bfdf===_0x22aac6)break;else _0x2f885e['push'](_0x2f885e['shift']());}catch(_0x5e6bbe){_0x2f885e['push'](_0x2f885e['shift']());}}}(a43_0x33ac,0x9a16f));import{jsx as a43_0xbc8784,Fragment as a43_0x4fb693,jsxs as a43_0x558d49}from'react/jsx-runtime';import a43_0x3424e0 from'path';import a43_0x25e17f from'fs';import{fileURLToPath}from'node:url';import{Box,Text}from'ink';import{useEffect,useState}from'react';import{EnhancedGuidedCreate}from'./enhanced-guided-create.js';import{pullApiSilent}from'../api/pull-silent.js';import{readConfig}from'../utils/config.js';import{useCopyProjectTemplate}from'./use-copy-project-template.js';function a43_0x5158(_0x3234b3,_0x5574fe){_0x3234b3=_0x3234b3-0x1db;const _0x33acd3=a43_0x33ac();let _0x515825=_0x33acd3[_0x3234b3];return _0x515825;}import{useInstallDependencies}from'./use-install-dependencies.js';import{useFormatCode}from'./use-format-code.js';import{TaskFinished}from'./task-finished.js';import{TaskRunning}from'./task-running.js';import{logger}from'../utils/logger.js';import{configureMcp,copySharedSkills,installSkill,createSkillManifest}from'../ai-setup/config.js';const MCP_IDES=new Set([a43_0x2754f5(0x1ea),a43_0x2754f5(0x22f)]);export function CreateApp(_0xe2f9){const _0x234667=a43_0x2754f5,[_0x563e8a,_0x24ec72]=useState(![]),[_0x246388,_0xf707ee]=useState(![]),[_0x350165,_0x1c5578]=useState(null),[_0x13304a,_0x4c1cd5]=useState(null),_0x57893d=useCopyProjectTemplate(),_0x2ebfc0=useInstallDependencies(),_0x513dc3=useFormatCode(),_0x4e7edb=async _0x573b20=>{const _0x555cff=a43_0x5158;if(!_0x573b20['projectName']||_0x573b20[_0x555cff(0x20e)][_0x555cff(0x23e)]()===''){console[_0x555cff(0x24c)]('×\x20项目名不能为空');return;}const _0x564154=/[<>:"|?*\x00-\x1f\x7f]/;if(_0x564154[_0x555cff(0x22c)](_0x573b20[_0x555cff(0x20e)])){console[_0x555cff(0x24c)]('×\x20项目名包含非法字符,不允许使用:\x20<\x20>\x20:\x20\x22\x20|\x20?\x20*\x20及控制字符');return;}if(_0x573b20['projectName'][_0x555cff(0x23c)]>0x64){console[_0x555cff(0x24c)](_0x555cff(0x231));return;}const _0xe107bd=a43_0x3424e0[_0x555cff(0x21a)](process[_0x555cff(0x1ed)](),_0x573b20[_0x555cff(0x20e)]);if(a43_0x25e17f[_0x555cff(0x243)](_0xe107bd)){console['error'](_0x555cff(0x1df)+_0x573b20['projectName']+'\x20已存在,请使用其他项目名');return;}try{const _0x2fd902=a43_0x3424e0[_0x555cff(0x23b)](_0xe107bd);a43_0x25e17f[_0x555cff(0x23f)](_0x2fd902,a43_0x25e17f[_0x555cff(0x24a)][_0x555cff(0x204)]);}catch(_0xc7bbb6){console[_0x555cff(0x24c)]('×\x20无法在当前目录创建项目,请检查目录权限');return;}_0x1c5578(_0x573b20),_0x24ec72(!![]),logger['setLogPath'](_0xe107bd),logger[_0x555cff(0x247)]('create',_0x555cff(0x21e)+_0x573b20[_0x555cff(0x20e)],{'projectDir':_0xe107bd,'appCode':_0x573b20[_0x555cff(0x1dc)]});try{await _0x57893d[_0x555cff(0x1fa)](_0x573b20[_0x555cff(0x20e)]),await _0xc7999e(_0x573b20['projectName']),await _0x2ebfc0['doTask'](_0x573b20[_0x555cff(0x20e)]),await _0x513dc3['doTask'](_0x573b20[_0x555cff(0x20e)]),await _0x22c23e(_0x573b20['projectName'],_0x573b20[_0x555cff(0x1dc)]||'',_0x573b20[_0x555cff(0x1e0)]);if(_0x573b20['pullApi']&&_0x573b20['appCode']){console['log']('*\x20正在拉取\x20API\x20配置...');try{const _0x2ef475=await pullApiSilent(_0x573b20['appCode'],undefined,_0xe107bd,_0x573b20[_0x555cff(0x1e0)]);_0x2ef475?(console[_0x555cff(0x246)](_0x555cff(0x226)),logger['info'](_0x555cff(0x248),_0x555cff(0x214)+_0x573b20[_0x555cff(0x1dc)])):(console[_0x555cff(0x246)](_0x555cff(0x20a)),logger[_0x555cff(0x245)]('create',_0x555cff(0x237)+_0x573b20[_0x555cff(0x1dc)]));}catch(_0xce9afc){console[_0x555cff(0x246)](_0x555cff(0x229)),logger['warn'](_0x555cff(0x248),_0x555cff(0x1fb),{'error':_0xce9afc instanceof Error?_0xce9afc[_0x555cff(0x242)]:String(_0xce9afc)});}}if(_0x573b20[_0x555cff(0x220)]&&_0x573b20[_0x555cff(0x200)]&&_0x573b20[_0x555cff(0x200)][_0x555cff(0x23c)]>0x0&&_0x573b20[_0x555cff(0x1dc)]){console['log'](_0x555cff(0x210));const _0xa9b46c=[],_0x2bd1d8=[],_0x116eda=_0x573b20[_0x555cff(0x200)][_0x555cff(0x232)](_0x210f8a=>MCP_IDES['has'](_0x210f8a)),_0x2214ee=_0x573b20[_0x555cff(0x200)];for(const _0x3b0bbb of _0x116eda){try{const _0x878751=await configureMcp(_0x3b0bbb,_0xe107bd);_0xa9b46c[_0x555cff(0x201)]({'ide':_0x3b0bbb===_0x555cff(0x1ea)?_0x555cff(0x218):_0x555cff(0x221),'status':_0x878751[_0x555cff(0x234)],'message':_0x878751['message']}),console[_0x555cff(0x246)]('\x20\x20'+(_0x878751['status']===_0x555cff(0x1fc)?'✓':_0x878751[_0x555cff(0x234)]===_0x555cff(0x227)?'⚠️':'✗')+'\x20MCP\x20'+_0x3b0bbb+':\x20'+_0x878751[_0x555cff(0x242)]);}catch(_0x3ec0ec){_0xa9b46c['push']({'ide':_0x3b0bbb==='cursor'?_0x555cff(0x218):_0x555cff(0x221),'status':'error','message':_0x3ec0ec instanceof Error?_0x3ec0ec[_0x555cff(0x242)]:String(_0x3ec0ec)}),console[_0x555cff(0x246)](_0x555cff(0x23a)+_0x3b0bbb+':\x20'+(_0x3ec0ec instanceof Error?_0x3ec0ec[_0x555cff(0x242)]:String(_0x3ec0ec)));}}await copySharedSkills(_0xe107bd);for(const _0x373a6f of _0x2214ee){try{const _0x38ef11=await installSkill(_0x373a6f,_0xe107bd);_0x2bd1d8[_0x555cff(0x201)]({'ide':_0x38ef11[_0x555cff(0x244)],'status':_0x38ef11[_0x555cff(0x234)],'message':_0x38ef11[_0x555cff(0x242)]}),console[_0x555cff(0x246)]('\x20\x20'+(_0x38ef11[_0x555cff(0x234)]===_0x555cff(0x1fc)?'✓':'✗')+_0x555cff(0x21b)+_0x38ef11[_0x555cff(0x244)]+':\x20'+_0x38ef11[_0x555cff(0x242)]);}catch(_0x5c822a){_0x2bd1d8[_0x555cff(0x201)]({'ide':_0x373a6f,'status':_0x555cff(0x24c),'message':_0x5c822a instanceof Error?_0x5c822a[_0x555cff(0x242)]:String(_0x5c822a)}),console['log'](_0x555cff(0x209)+_0x373a6f+':\x20'+(_0x5c822a instanceof Error?_0x5c822a['message']:String(_0x5c822a)));}}if(_0x2bd1d8[_0x555cff(0x23c)]>0x0){const _0x514334=_0x2bd1d8[_0x555cff(0x232)](_0x4536e0=>_0x4536e0[_0x555cff(0x234)]===_0x555cff(0x1fc))[_0x555cff(0x1f7)](_0x3db71f=>_0x3db71f[_0x555cff(0x244)]);_0x514334[_0x555cff(0x23c)]>0x0&&createSkillManifest(_0xe107bd,_0x514334);}_0x4c1cd5({'mcp':_0xa9b46c,'skill':_0x2bd1d8}),console[_0x555cff(0x246)]('√\x20Lovrabet\x20MCP\x20和\x20Skill\x20配置完成');}logger[_0x555cff(0x1fc)](_0x555cff(0x248),_0x555cff(0x203)+_0x573b20[_0x555cff(0x20e)]),_0xf707ee(!![]),_0x24ec72(![]);}catch(_0xc3fe7f){logger[_0x555cff(0x24c)](_0x555cff(0x248),'项目创建失败:\x20'+_0x573b20[_0x555cff(0x20e)],{'error':_0xc3fe7f instanceof Error?_0xc3fe7f[_0x555cff(0x242)]:String(_0xc3fe7f)});try{a43_0x25e17f[_0x555cff(0x243)](_0xe107bd)&&(console['log']('*\x20清理失败的项目目录:\x20'+_0xe107bd),a43_0x25e17f['rmSync'](_0xe107bd,{'recursive':!![],'force':!![]}));}catch(_0x16b7e8){logger[_0x555cff(0x245)](_0x555cff(0x248),_0x555cff(0x1e8)+_0xe107bd);}_0x24ec72(![]),console[_0x555cff(0x24c)]('×\x20项目创建失败:\x20'+(_0xc3fe7f instanceof Error?_0xc3fe7f['message']:String(_0xc3fe7f)));}},_0x3a114b=async _0x451115=>{const _0x4b21b7=a43_0x5158;await _0x4e7edb({'projectName':_0x451115,'env':_0xe2f9[_0x4b21b7(0x1e0)]});},_0xc7999e=async _0x350132=>{const _0x1062f6=a43_0x5158,_0x4e6463=a43_0x3424e0[_0x1062f6(0x21a)](process[_0x1062f6(0x1ed)](),_0x350132),_0x29df97=a43_0x3424e0[_0x1062f6(0x1f8)](_0x4e6463,_0x1062f6(0x20c));try{console[_0x1062f6(0x246)]('*\x20正在更新\x20package.json\x20的\x20name\x20和\x20description\x20字段');const _0x2f53b1=fileURLToPath(import.meta.url),_0xe7f63e=a43_0x3424e0[_0x1062f6(0x21a)](a43_0x3424e0['dirname'](_0x2f53b1),_0x1062f6(0x22a)),_0x35939d=a43_0x3424e0['join'](_0xe7f63e,_0x1062f6(0x20c));let _0xcb18aa=_0x1062f6(0x22d);try{const _0x2c5a3c=JSON[_0x1062f6(0x1fd)](a43_0x25e17f[_0x1062f6(0x20d)](_0x35939d,'utf8'));_0xcb18aa=_0x2c5a3c[_0x1062f6(0x230)]||'1.0.0';}catch(_0x1c973d){}const _0x246253=a43_0x25e17f[_0x1062f6(0x20d)](_0x29df97,_0x1062f6(0x1e3)),_0x5d2223=JSON[_0x1062f6(0x1fd)](_0x246253);_0x5d2223[_0x1062f6(0x1fe)]=_0x350132,_0x5d2223[_0x1062f6(0x1ef)]=_0x350132+_0x1062f6(0x206)+_0xcb18aa,a43_0x25e17f[_0x1062f6(0x21d)](_0x29df97,JSON[_0x1062f6(0x1f6)](_0x5d2223,null,0x2)+'\x0a',_0x1062f6(0x1e3)),console['log'](_0x1062f6(0x205)+_0x350132),logger[_0x1062f6(0x247)](_0x1062f6(0x248),'更新\x20package.json\x20name');}catch(_0x52ec4b){logger[_0x1062f6(0x24c)](_0x1062f6(0x248),'更新\x20package.json\x20失败');throw _0x52ec4b;}},_0x22c23e=async(_0xea41c7,_0x408112,_0x264ed9)=>{const _0x20b7ea=a43_0x5158,_0x309484=a43_0x3424e0[_0x20b7ea(0x21a)](process['cwd'](),_0xea41c7),_0x33d7fb=a43_0x3424e0['join'](_0x309484,_0x20b7ea(0x222));try{_0x408112?console[_0x20b7ea(0x246)](_0x20b7ea(0x1e2)+_0xea41c7+_0x20b7ea(0x225)+_0x408112):console['log']('*\x20正在为项目\x20'+_0xea41c7+_0x20b7ea(0x1db));const _0x5ed6e7=fileURLToPath(import.meta.url),_0x292465=a43_0x3424e0['resolve'](a43_0x3424e0[_0x20b7ea(0x23b)](_0x5ed6e7),_0x20b7ea(0x22a)),_0x301279=a43_0x3424e0[_0x20b7ea(0x1f8)](_0x292465,_0x20b7ea(0x20c));let _0x37bfcf=_0x20b7ea(0x22d);try{const _0x2629ec=JSON[_0x20b7ea(0x1fd)](a43_0x25e17f['readFileSync'](_0x301279,_0x20b7ea(0x1e3)));_0x37bfcf=_0x2629ec['version']||'1.0.0';}catch(_0x85dc3e){}const _0x4e107e=readConfig(),_0x171f27=typeof _0x4e107e[_0x20b7ea(0x1e0)]==='string'?_0x4e107e[_0x20b7ea(0x1e0)]:undefined,{app:_0x4b0ebc,appcode:_0x2fa254,..._0x300d89}=_0x4e107e,_0x5ba3cf={..._0x300d89,'appcode':_0x408112||'','env':_0x264ed9||_0x171f27||_0x20b7ea(0x207),'createdAt':new Date()[_0x20b7ea(0x1e9)](),'version':_0x37bfcf};a43_0x25e17f[_0x20b7ea(0x21d)](_0x33d7fb,JSON[_0x20b7ea(0x1f6)](_0x5ba3cf,null,0x2),_0x20b7ea(0x1e3)),_0x408112?console[_0x20b7ea(0x246)](_0x20b7ea(0x211)+_0x408112):console[_0x20b7ea(0x246)](_0x20b7ea(0x213)),logger[_0x20b7ea(0x247)](_0x20b7ea(0x248),_0x20b7ea(0x23d)+_0x408112);}catch(_0x1bd00c){logger[_0x20b7ea(0x24c)]('create','配置应用AppCode失败');}};useEffect(()=>{const _0x7bbc5f=a43_0x5158;_0xe2f9[_0x7bbc5f(0x1eb)]&&_0x3a114b(_0xe2f9['projectCode']);},[_0xe2f9[_0x234667(0x1eb)]]);if(!_0x563e8a&&!_0x246388&&!_0xe2f9[_0x234667(0x1eb)])return a43_0xbc8784(EnhancedGuidedCreate,{'onCreate':_0x4e7edb,'env':_0xe2f9[_0x234667(0x1e0)]});if(_0x563e8a)return a43_0x558d49(a43_0x4fb693,{'children':[a43_0x558d49(Box,{'marginTop':0x1,'children':[a43_0xbc8784(Box,{'width':'1'}),a43_0xbc8784(Text,{'color':_0x234667(0x219),'children':'\x20√\x20'}),a43_0xbc8784(Text,{'children':'项目名称:\x20'}),a43_0xbc8784(Text,{'color':_0x234667(0x219),'children':_0x350165?.[_0x234667(0x20e)]}),_0x350165?.['appCode']&&a43_0x558d49(a43_0x4fb693,{'children':[a43_0xbc8784(Text,{'children':_0x234667(0x1e6)}),a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'children':_0x350165[_0x234667(0x1dc)]})]})]}),a43_0xbc8784(TaskRunning,{..._0x57893d}),a43_0xbc8784(TaskRunning,{..._0x2ebfc0}),a43_0xbc8784(TaskRunning,{..._0x513dc3})]});if(_0x246388){const _0x43c494=_0x13304a&&(_0x13304a[_0x234667(0x1e5)][_0x234667(0x23c)]>0x0||_0x13304a[_0x234667(0x235)]['length']>0x0);return a43_0x558d49(a43_0x4fb693,{'children':[a43_0x558d49(Box,{'marginTop':0x1,'children':[a43_0xbc8784(Box,{'width':'1'}),a43_0xbc8784(Text,{'color':'green','children':_0x234667(0x249)}),a43_0xbc8784(Text,{'children':_0x234667(0x236)}),a43_0xbc8784(Text,{'color':_0x234667(0x219),'children':_0x350165?.[_0x234667(0x20e)]}),_0x350165?.[_0x234667(0x1dc)]&&a43_0x558d49(a43_0x4fb693,{'children':[a43_0xbc8784(Text,{'children':_0x234667(0x1e6)}),a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'children':_0x350165[_0x234667(0x1dc)]})]})]}),a43_0xbc8784(TaskFinished,{..._0x57893d}),a43_0xbc8784(TaskFinished,{..._0x2ebfc0}),a43_0xbc8784(TaskFinished,{..._0x513dc3}),a43_0xbc8784(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a43_0xbc8784(Text,{'color':_0x234667(0x219),'children':'─'['repeat'](0x3c)})}),_0x43c494&&a43_0x558d49(a43_0x4fb693,{'children':[_0x13304a['mcp']['length']>0x0&&a43_0x558d49(a43_0x4fb693,{'children':[a43_0xbc8784(Box,{'marginTop':0x1,'children':a43_0xbc8784(Text,{'color':_0x234667(0x219),'bold':!![],'children':_0x234667(0x1dd)})}),_0x13304a[_0x234667(0x1e5)][_0x234667(0x1f7)]((_0x72cf70,_0x19515b)=>a43_0xbc8784(Box,{'marginLeft':0x2,'children':a43_0x558d49(Text,{'color':_0x72cf70[_0x234667(0x234)]===_0x234667(0x1fc)?_0x234667(0x1ec):_0x72cf70[_0x234667(0x234)]===_0x234667(0x227)?_0x234667(0x233):_0x234667(0x216),'children':[_0x72cf70['ide'],':\x20',_0x72cf70[_0x234667(0x242)]]})},_0x234667(0x1e7)+_0x19515b))]}),_0x13304a[_0x234667(0x235)][_0x234667(0x23c)]>0x0&&a43_0x558d49(a43_0x4fb693,{'children':[a43_0xbc8784(Box,{'marginTop':_0x13304a[_0x234667(0x1e5)][_0x234667(0x23c)]>0x0?0x1:0x0,'children':a43_0xbc8784(Text,{'color':'green','bold':!![],'children':'✓\x20Skill\x20安装完成:'})}),_0x13304a[_0x234667(0x235)]['map']((_0x67d48f,_0x314d15)=>a43_0xbc8784(Box,{'marginLeft':0x2,'children':a43_0x558d49(Text,{'color':_0x67d48f[_0x234667(0x234)]==='success'?_0x234667(0x1ec):_0x234667(0x216),'children':[_0x67d48f[_0x234667(0x244)],':\x20',_0x67d48f[_0x234667(0x242)]]})},'skill-'+_0x314d15))]}),a43_0xbc8784(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a43_0xbc8784(Text,{'color':_0x234667(0x219),'children':'─'[_0x234667(0x22b)](0x3c)})})]}),a43_0xbc8784(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'bold':!![],'children':_0x234667(0x208)})}),a43_0x558d49(Box,{'marginLeft':0x2,'flexDirection':_0x234667(0x212),'children':[_0x43c494?a43_0x558d49(a43_0x4fb693,{'children':[a43_0x558d49(Box,{'children':[a43_0xbc8784(Text,{'color':'green','children':'1.\x20'}),a43_0xbc8784(Text,{'color':_0x234667(0x1ec),'children':_0x234667(0x1f9)}),a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'bold':!![],'children':'cd\x20'+_0x350165?.[_0x234667(0x20e)]+_0x234667(0x21c)})]}),_0x350165?.['appCode']&&!_0x350165?.['pullApi']&&a43_0x558d49(Box,{'children':[a43_0xbc8784(Text,{'color':_0x234667(0x233),'children':'2.\x20'}),a43_0xbc8784(Text,{'color':_0x234667(0x1ec),'children':'拉取API配置:\x20'}),a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'bold':!![],'children':_0x234667(0x202)})]})]}):a43_0x558d49(a43_0x4fb693,{'children':[a43_0xbc8784(Box,{'children':a43_0xbc8784(Text,{'color':_0x234667(0x233),'bold':!![],'children':_0x234667(0x224)})}),a43_0x558d49(Box,{'marginLeft':0x2,'marginTop':0x1,'children':[a43_0xbc8784(Text,{'color':_0x234667(0x1ec),'children':_0x234667(0x24b)}),a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'bold':!![],'children':_0x234667(0x1f4)})]}),a43_0x558d49(Box,{'marginLeft':0x2,'children':[a43_0xbc8784(Text,{'color':'white','children':_0x234667(0x1f0)}),a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'bold':!![],'children':_0x234667(0x1f5)})]}),a43_0x558d49(Box,{'marginTop':0x1,'children':[a43_0xbc8784(Text,{'color':_0x234667(0x219),'children':_0x234667(0x228)}),a43_0xbc8784(Text,{'color':_0x234667(0x1ec),'children':_0x234667(0x1f9)}),a43_0xbc8784(Text,{'color':'cyan','bold':!![],'children':_0x234667(0x1f3)+_0x350165?.[_0x234667(0x20e)]+_0x234667(0x21c)})]}),_0x350165?.['appCode']&&!_0x350165?.[_0x234667(0x217)]&&a43_0x558d49(Box,{'children':[a43_0xbc8784(Text,{'color':_0x234667(0x233),'children':'3.\x20'}),a43_0xbc8784(Text,{'color':_0x234667(0x1ec),'children':_0x234667(0x238)}),a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'bold':!![],'children':_0x234667(0x202)})]})]}),!_0x350165?.['appCode']&&a43_0x558d49(a43_0x4fb693,{'children':[a43_0x558d49(Box,{'children':[a43_0xbc8784(Text,{'color':_0x234667(0x1de),'children':'2.\x20'}),a43_0xbc8784(Text,{'color':_0x234667(0x1ec),'children':_0x234667(0x215)}),a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'bold':!![],'children':'lovrabet\x20config\x20set\x20appcode\x20[app-code]'})]}),a43_0x558d49(Box,{'children':[a43_0xbc8784(Text,{'color':_0x234667(0x1de),'children':_0x234667(0x1e1)}),a43_0xbc8784(Text,{'color':_0x234667(0x1ec),'children':'拉取API配置:\x20'}),a43_0xbc8784(Text,{'color':_0x234667(0x1f2),'bold':!![],'children':_0x234667(0x223)})]})]})]}),a43_0xbc8784(Box,{'marginTop':0x1,'children':a43_0xbc8784(Text,{'color':_0x234667(0x219),'children':'─'['repeat'](0x3c)})})]});}return null;}
@@ -1 +1 @@
1
- (function(_0x58b94e,_0xe85141){var _0xd834e4=a44_0x15f7,_0x5bb28c=_0x58b94e();while(!![]){try{var _0x28dd27=-parseInt(_0xd834e4(0x104))/0x1*(parseInt(_0xd834e4(0x101))/0x2)+-parseInt(_0xd834e4(0x10b))/0x3*(parseInt(_0xd834e4(0x106))/0x4)+-parseInt(_0xd834e4(0x108))/0x5+parseInt(_0xd834e4(0x109))/0x6*(-parseInt(_0xd834e4(0x105))/0x7)+-parseInt(_0xd834e4(0x10d))/0x8*(-parseInt(_0xd834e4(0x100))/0x9)+parseInt(_0xd834e4(0x107))/0xa*(parseInt(_0xd834e4(0x10a))/0xb)+-parseInt(_0xd834e4(0x102))/0xc*(-parseInt(_0xd834e4(0x10e))/0xd);if(_0x28dd27===_0xe85141)break;else _0x5bb28c['push'](_0x5bb28c['shift']());}catch(_0xdfcbf8){_0x5bb28c['push'](_0x5bb28c['shift']());}}}(a44_0x1565,0x7275d));function a44_0x15f7(_0x865e02,_0x335c8d){_0x865e02=_0x865e02-0xff;var _0x15653a=a44_0x1565();var _0x15f797=_0x15653a[_0x865e02];return _0x15f797;}import{jsx as a44_0xfe6e20,jsxs as a44_0x3178d4}from'react/jsx-runtime';import{Box,Text}from'ink';import{TaskTime}from'./task-time.js';function a44_0x1565(){var _0x2027ea=['11drEiOG','5043ZKGKDy','taskName','27672aLXhVn','13tfIyZK','green','\x20√\x20','1161VasRge','180CebIxj','25450644Fuaqco','elapsed','7729oImIhI','252399XopoAY','1224hQwYic','4910830QTglGg','3831935QCVsNP','102IQtkKW'];a44_0x1565=function(){return _0x2027ea;};return a44_0x1565();}export function TaskFinished(_0x182ce1){var _0x52a8e6=a44_0x15f7;return a44_0x3178d4(Box,{'children':[a44_0xfe6e20(Box,{'width':'1'}),a44_0xfe6e20(Text,{'color':_0x52a8e6(0x10f),'children':_0x52a8e6(0xff)}),a44_0xfe6e20(Text,{'children':_0x182ce1[_0x52a8e6(0x10c)]}),a44_0xfe6e20(TaskTime,{'elapsed':_0x182ce1[_0x52a8e6(0x103)]})]});}
1
+ (function(_0x5c71c9,_0x33aa7a){var _0x5dcf95=a44_0x2bd4,_0x252e11=_0x5c71c9();while(!![]){try{var _0x3439bf=-parseInt(_0x5dcf95(0x1d3))/0x1*(parseInt(_0x5dcf95(0x1de))/0x2)+-parseInt(_0x5dcf95(0x1d6))/0x3+parseInt(_0x5dcf95(0x1d7))/0x4*(-parseInt(_0x5dcf95(0x1da))/0x5)+parseInt(_0x5dcf95(0x1dc))/0x6+parseInt(_0x5dcf95(0x1d9))/0x7+parseInt(_0x5dcf95(0x1d4))/0x8+parseInt(_0x5dcf95(0x1d8))/0x9;if(_0x3439bf===_0x33aa7a)break;else _0x252e11['push'](_0x252e11['shift']());}catch(_0x511e71){_0x252e11['push'](_0x252e11['shift']());}}}(a44_0x1f7f,0x551c6));import{jsx as a44_0x3278ba,jsxs as a44_0x3e983e}from'react/jsx-runtime';function a44_0x1f7f(){var _0x35819d=['elapsed','478350xSoHmN','417836DVsioP','6355854gnlZHD','3185567YzHpdu','10qXriOc','taskName','903342NVDHST','\x20√\x20','1280038TcKBzo','1tQbKZl','361256jJAdDR'];a44_0x1f7f=function(){return _0x35819d;};return a44_0x1f7f();}function a44_0x2bd4(_0x274097,_0x20f15e){_0x274097=_0x274097-0x1d3;var _0x1f7f62=a44_0x1f7f();var _0x2bd4af=_0x1f7f62[_0x274097];return _0x2bd4af;}import{Box,Text}from'ink';import{TaskTime}from'./task-time.js';export function TaskFinished(_0x20e309){var _0x9cfa88=a44_0x2bd4;return a44_0x3e983e(Box,{'children':[a44_0x3278ba(Box,{'width':'1'}),a44_0x3278ba(Text,{'color':'green','children':_0x9cfa88(0x1dd)}),a44_0x3278ba(Text,{'children':_0x20e309[_0x9cfa88(0x1db)]}),a44_0x3278ba(TaskTime,{'elapsed':_0x20e309[_0x9cfa88(0x1d5)]})]});}
@@ -1 +1 @@
1
- (function(_0x3c3908,_0x3ffbf0){var _0x3f17ad=a45_0x2f8f,_0x17669c=_0x3c3908();while(!![]){try{var _0x52c606=-parseInt(_0x3f17ad(0x1d1))/0x1*(parseInt(_0x3f17ad(0x1d5))/0x2)+-parseInt(_0x3f17ad(0x1c6))/0x3+-parseInt(_0x3f17ad(0x1c9))/0x4*(-parseInt(_0x3f17ad(0x1d4))/0x5)+parseInt(_0x3f17ad(0x1ca))/0x6+-parseInt(_0x3f17ad(0x1cd))/0x7*(-parseInt(_0x3f17ad(0x1cf))/0x8)+-parseInt(_0x3f17ad(0x1cc))/0x9+parseInt(_0x3f17ad(0x1cb))/0xa*(parseInt(_0x3f17ad(0x1d0))/0xb);if(_0x52c606===_0x3ffbf0)break;else _0x17669c['push'](_0x17669c['shift']());}catch(_0x4f2af6){_0x17669c['push'](_0x17669c['shift']());}}}(a45_0x220b,0x4610c));function a45_0x2f8f(_0x1771ea,_0x7c4caf){_0x1771ea=_0x1771ea-0x1c6;var _0x220bec=a45_0x220b();var _0x2f8f54=_0x220bec[_0x1771ea];return _0x2f8f54;}import{jsx as a45_0x3bb666,jsxs as a45_0x45bafc}from'react/jsx-runtime';import{Text}from'ink';function a45_0x220b(){var _0x15f81a=['\x20√\x20','217468oFSNFB','1245774tdOekK','190lcSkte','3020265AxeElx','7lJyTQm','loading','1157616rQatcR','344597nlhnDJ','179743NbkZOd','finished','green','15Eojiow','2jmzJBC','924987oVlhIe','dots'];a45_0x220b=function(){return _0x15f81a;};return a45_0x220b();}import a45_0x26cd3c from'ink-spinner';export function TaskLoading(_0x1e05ca){var _0x5a0e98=a45_0x2f8f;if(_0x1e05ca[_0x5a0e98(0x1d2)])return a45_0x3bb666(Text,{'color':_0x5a0e98(0x1d3),'children':_0x5a0e98(0x1c8)});if(_0x1e05ca[_0x5a0e98(0x1ce)])return a45_0x45bafc(Text,{'color':_0x5a0e98(0x1d3),'children':['\x20',a45_0x3bb666(a45_0x26cd3c,{'type':_0x5a0e98(0x1c7)}),'\x20']});return a45_0x3bb666(Text,{'children':'\x20\x20\x20'});}
1
+ (function(_0x5d9c37,_0x331c88){var _0x43e7c2=a45_0x16a6,_0x38f978=_0x5d9c37();while(!![]){try{var _0x548b15=-parseInt(_0x43e7c2(0x134))/0x1*(-parseInt(_0x43e7c2(0x13b))/0x2)+parseInt(_0x43e7c2(0x132))/0x3*(-parseInt(_0x43e7c2(0x133))/0x4)+-parseInt(_0x43e7c2(0x137))/0x5*(parseInt(_0x43e7c2(0x135))/0x6)+parseInt(_0x43e7c2(0x13c))/0x7*(-parseInt(_0x43e7c2(0x139))/0x8)+-parseInt(_0x43e7c2(0x13e))/0x9+parseInt(_0x43e7c2(0x13d))/0xa+parseInt(_0x43e7c2(0x13f))/0xb;if(_0x548b15===_0x331c88)break;else _0x38f978['push'](_0x38f978['shift']());}catch(_0x52a2b9){_0x38f978['push'](_0x38f978['shift']());}}}(a45_0xbcb4,0xbd0c6));import{jsx as a45_0x17758a,jsxs as a45_0x48fba0}from'react/jsx-runtime';function a45_0x16a6(_0x3a3607,_0x2683be){_0x3a3607=_0x3a3607-0x131;var _0xbcb46f=a45_0xbcb4();var _0x16a686=_0xbcb46f[_0x3a3607];return _0x16a686;}function a45_0xbcb4(){var _0x4ecafb=['16FSmhaC','296858AmDqqI','1752rmkuSx','loading','3470QbKtHI','dots','58568JMcdSq','\x20\x20\x20','2TsOSEQ','1211topRyW','3750640begHpm','11733084GbPQUp','35372799WmEgHz','green','\x20√\x20','255324pIGseI'];a45_0xbcb4=function(){return _0x4ecafb;};return a45_0xbcb4();}import{Text}from'ink';import a45_0x1fc693 from'ink-spinner';export function TaskLoading(_0x765e07){var _0x22ca05=a45_0x16a6;if(_0x765e07['finished'])return a45_0x17758a(Text,{'color':_0x22ca05(0x140),'children':_0x22ca05(0x131)});if(_0x765e07[_0x22ca05(0x136)])return a45_0x48fba0(Text,{'color':'green','children':['\x20',a45_0x17758a(a45_0x1fc693,{'type':_0x22ca05(0x138)}),'\x20']});return a45_0x17758a(Text,{'children':_0x22ca05(0x13a)});}