@lovrabet/cli 1.3.2-beta.1 → 1.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/add-page/input-page-router.js +1 -1
- package/lib/add-page/main.js +1 -1
- package/lib/add-page/select-page-template.js +1 -1
- package/lib/ai-setup/AISetupUI.js +1 -1
- package/lib/ai-setup/config.js +1 -1
- package/lib/api/api-doc-ui.js +1 -1
- package/lib/api/api-doc.js +1 -1
- package/lib/api/api-pull-ui.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/api/main.js +1 -1
- package/lib/api/pull-silent.js +1 -1
- package/lib/app-menu/app-menu-sync-ui.js +1 -1
- package/lib/app-menu/create-menu.js +1 -1
- package/lib/app-menu/get-local-pages.js +1 -1
- package/lib/app-menu/get-online-menu-list.js +1 -1
- package/lib/app-menu/use-get-online-menu-list.js +1 -1
- package/lib/app-menu/utils.js +1 -1
- package/lib/app-menu/valid-url.js +1 -1
- package/lib/app-menu-update-cdn/current-content.js +1 -1
- package/lib/app-menu-update-cdn/input-cdn-asset.js +1 -1
- package/lib/app-menu-update-cdn/main.js +1 -1
- package/lib/app-menu-update-cdn/update-menu-cdn-url.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/cmd/build-watch.js +1 -1
- package/lib/cmd/build.js +1 -1
- package/lib/cmd/logs.js +1 -1
- package/lib/cmd/preview.js +1 -1
- package/lib/cmd/start.js +1 -1
- package/lib/config/config-help.js +1 -1
- package/lib/config/main.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/create-app/enhanced-guided-create.js +1 -1
- package/lib/create-app/format-elapsed.js +1 -1
- package/lib/create-app/main.js +1 -1
- package/lib/create-app/non-interactive.js +1 -1
- package/lib/create-app/task-finished.js +1 -1
- package/lib/create-app/task-loading.js +1 -1
- package/lib/create-app/task-running.js +1 -1
- package/lib/create-app/task-time.js +1 -1
- package/lib/create-app/use-copy-project-template.js +1 -1
- package/lib/create-app/use-format-code.js +1 -1
- package/lib/create-app/use-install-dependencies.js +1 -1
- package/lib/help.js +1 -1
- package/lib/init/main.js +1 -1
- package/lib/mcp/McpInstallUI.js +1 -1
- package/lib/mcp/claude.js +1 -1
- package/lib/mcp/cursor.js +1 -1
- package/lib/mcp/main.js +1 -1
- package/lib/mcp/mcp-install-non-interactive.js +1 -1
- package/lib/mcp/mcp-installer.js +1 -1
- package/lib/skills/SkillInstallUI.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/skill-install-non-interactive.js +1 -1
- package/lib/skills/skill-installer.js +1 -1
- package/lib/ui/IDESelector.js +1 -1
- package/lib/ui/useIDESelection.js +1 -1
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/copy-directory.js +1 -1
- package/lib/utils/file-utils.js +1 -1
- package/lib/utils/guides-cdn.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/router-updater.js +1 -1
- package/lib/utils/rules-cdn.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/package.json +1 -1
package/lib/cli-flags.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a31_0x23c084=a31_0x5ad8;function a31_0x5ad8(_0x24321e,_0x2efd11){_0x24321e=_0x24321e-0xb9;const _0x56c995=a31_0x56c9();let _0x5ad810=_0x56c995[_0x24321e];return _0x5ad810;}(function(_0x1f84b6,_0xd9bb4){const _0x58b0b9=a31_0x5ad8,_0x15808d=_0x1f84b6();while(!![]){try{const _0x47fec1=parseInt(_0x58b0b9(0xc2))/0x1+-parseInt(_0x58b0b9(0xc0))/0x2*(-parseInt(_0x58b0b9(0xc5))/0x3)+parseInt(_0x58b0b9(0xbf))/0x4*(parseInt(_0x58b0b9(0xbb))/0x5)+parseInt(_0x58b0b9(0xc6))/0x6*(-parseInt(_0x58b0b9(0xbd))/0x7)+parseInt(_0x58b0b9(0xc3))/0x8*(-parseInt(_0x58b0b9(0xc1))/0x9)+parseInt(_0x58b0b9(0xb9))/0xa*(-parseInt(_0x58b0b9(0xba))/0xb)+-parseInt(_0x58b0b9(0xbc))/0xc*(-parseInt(_0x58b0b9(0xbe))/0xd);if(_0x47fec1===_0xd9bb4)break;else _0x15808d['push'](_0x15808d['shift']());}catch(_0x1e5a34){_0x15808d['push'](_0x15808d['shift']());}}}(a31_0x56c9,0x44267));export const dynamicCliFlags={'dangerouslyBffSave':{'type':a31_0x23c084(0xc4)}};function a31_0x56c9(){const _0x674d99=['259cAvVbR','25272LfBiol','1564iSbZxI','180710eeFKxW','116307ghIQIW','52681KziYch','264Qebtib','boolean','18Bqvtzf','43248pfOtdP','10whYGsx','1024738wHrnyc','2215XQpcSv','1836gFRodw'];a31_0x56c9=function(){return _0x674d99;};return a31_0x56c9();}
|
package/lib/cli.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
const a32_0xb58d90=a32_0x16ca;(function(_0x2cd9bd,_0x5864d2){const _0x225554=a32_0x16ca,_0x32d00b=_0x2cd9bd();while(!![]){try{const _0x21a4ff=parseInt(_0x225554(0x95))/0x1*(-parseInt(_0x225554(0x92))/0x2)+-parseInt(_0x225554(0x86))/0x3*(-parseInt(_0x225554(0xac))/0x4)+parseInt(_0x225554(0xaf))/0x5+-parseInt(_0x225554(0xb9))/0x6+parseInt(_0x225554(0x9a))/0x7*(-parseInt(_0x225554(0x94))/0x8)+-parseInt(_0x225554(0xbc))/0x9+parseInt(_0x225554(0xca))/0xa;if(_0x21a4ff===_0x5864d2)break;else _0x32d00b['push'](_0x32d00b['shift']());}catch(_0x12d86b){_0x32d00b['push'](_0x32d00b['shift']());}}}(a32_0x1cc0,0xa7463));import{jsx as a32_0x2be163}from'react/jsx-runtime';import a32_0x1e819e 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';function a32_0x16ca(_0x322eb8,_0x38cbf5){_0x322eb8=_0x322eb8-0x84;const _0x1cc0c0=a32_0x1cc0();let _0x16ca03=_0x1cc0c0[_0x322eb8];return _0x16ca03;}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';import{SkillInstallUI}from'./skills/SkillInstallUI.js';import{McpInstallUI}from'./mcp/McpInstallUI.js';let dynamicCliFlags=null;function a32_0x1cc0(){const _0x141668=['\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\x20skill\x20install\x20--dangerously-bff-save\x20//\x20包含\x20Backend\x20Function\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','length','exit','appcode','mcpClaude','codebuddy','menu','nonInteractive','page','clear','argv','执行预览命令','codex','setLogPath','180SiZTCU','logout','all','3327910QeQXcI','help','./create-app/non-interactive.js','install','skill-install','start','执行更新菜单\x20CDN\x20资源命令','./mcp/mcp-install-non-interactive.js','执行启动命令','cline','4975026wDDmEc','mcpCursor','boolean','10929366RJzWmq','menu-sync','build','trim','执行配置\x20MCP\x20命令','auth','执行初始化配置命令','env','lovrabet\x20','create','isTTY','init','push','antigravity','27845570Txhpjg','claude','mcpOther','skill','执行构建命令','info','./skills/skill-install-non-interactive.js','setRawCommand','opencode','./cli-flags.js','preview','执行安装技能包命令','32061jHRIJT','config','./skills/main.js','flags','windsurf','mcp','qoder','非交互模式创建项目:\x20','error','cursor','menu-update-cdn','--help','4218ltIpBw','input','8WMAnlf','263atqhxr','api','执行添加页面命令','cwd','trae','4533809ogAcdL','update','agent','string'];a32_0x1cc0=function(){return _0x141668;};return a32_0x1cc0();}try{dynamicCliFlags=(await import(a32_0xb58d90(0xd3)))['dynamicCliFlags'];}catch{}const mergedFlags={...dynamicCliFlags||{}};function isNonInteractiveMode(_0x25d89d){const _0x193fca=a32_0xb58d90;return!!(_0x25d89d[_0x193fca(0xa5)]||_0x25d89d['ci']||process[_0x193fca(0xc3)]['LOVRABET_CI']==='true'||process[_0x193fca(0xc3)]['CI']==='true'||!process['stdout'][_0x193fca(0xc6)]);}const cli=a32_0x1e819e(a32_0xb58d90(0x9e),{'importMeta':import.meta,'flags':{'name':{'type':a32_0xb58d90(0x9d)},'clear':{'type':'boolean'},'env':{'type':a32_0xb58d90(0x9d)},'watch':{'type':a32_0xb58d90(0xbb)},'help':{'type':a32_0xb58d90(0xbb)},'appcode':{'type':'string'},'output':{'type':a32_0xb58d90(0x9d)},'params':{'type':a32_0xb58d90(0x9d)},'datasetcode':{'type':a32_0xb58d90(0x9d)},'mcpCursor':{'type':a32_0xb58d90(0xbb)},'mcpClaude':{'type':a32_0xb58d90(0xbb)},'mcpOther':{'type':'boolean'},'cursor':{'type':'boolean'},'windsurf':{'type':'boolean'},'claude':{'type':a32_0xb58d90(0xbb)},'cline':{'type':'boolean'},'codex':{'type':a32_0xb58d90(0xbb)},'opencode':{'type':a32_0xb58d90(0xbb)},'qoder':{'type':a32_0xb58d90(0xbb)},'codebuddy':{'type':'boolean'},'trae':{'type':a32_0xb58d90(0xbb)},'agent':{'type':a32_0xb58d90(0xbb)},'antigravity':{'type':a32_0xb58d90(0xbb)},'all':{'type':a32_0xb58d90(0xbb)},'nonInteractive':{'type':a32_0xb58d90(0xbb)},'ci':{'type':'boolean'},...mergedFlags},'autoVersion':!![]});await run();async function run(){const _0x131c13=a32_0xb58d90,_0x5a7d39=cli[_0x131c13(0x93)][0x0],_0xf7a9fe=cli[_0x131c13(0x93)][0x1],_0x624b8b=cli[_0x131c13(0x93)][0x2],_0x1e1ed3=(_0x131c13(0xc4)+process[_0x131c13(0xa8)]['slice'](0x2)['join']('\x20'))['trim']();logger[_0x131c13(0xd1)](_0x1e1ed3);switch(_0x5a7d39){case _0x131c13(0xc7):{const _0x21f1d3=cli[_0x131c13(0x89)][_0x131c13(0xa1)],_0x10be4f=cli[_0x131c13(0x89)][_0x131c13(0xc3)];logger[_0x131c13(0xab)](process[_0x131c13(0x98)]()),logger['info'](_0x131c13(0xc7),_0x131c13(0xc2)),render(a32_0x2be163(Init,{'appcode':_0x21f1d3,'env':_0x10be4f}));break;}case'create':{const _0xfa5d45=cli['input'][0x1]?.[_0x131c13(0xbf)](),_0xb2dda5=cli['flags'][_0x131c13(0xc3)],_0x559a4e=isNonInteractiveMode(cli[_0x131c13(0x89)]);if(_0x559a4e&&_0xfa5d45){logger[_0x131c13(0xab)](process[_0x131c13(0x98)]()),logger['info'](_0x131c13(0xc5),_0x131c13(0x8d)+_0xfa5d45);const {createProjectNonInteractive:_0x181dcc}=await import(_0x131c13(0xb1));await _0x181dcc(_0xfa5d45,_0xb2dda5);}else render(a32_0x2be163(CreateApp,{'projectCode':_0xfa5d45,'env':_0xb2dda5}));break;}case'add':{cli['input'][0x1]===_0x131c13(0xa6)&&(logger[_0x131c13(0xab)](process[_0x131c13(0x98)]()),logger[_0x131c13(0xcf)]('add-page',_0x131c13(0x97)),render(a32_0x2be163(AddPage,{})));break;}case _0x131c13(0xb4):{try{logger[_0x131c13(0xab)](process[_0x131c13(0x98)]()),logger[_0x131c13(0xcf)](_0x131c13(0xb4),_0x131c13(0xb7)),await runStart();}catch(_0xf2cc9e){console[_0x131c13(0x8e)](_0xf2cc9e),process[_0x131c13(0xa0)](0x1);}break;}case _0x131c13(0xbe):{try{logger[_0x131c13(0xab)](process['cwd']()),logger[_0x131c13(0xcf)](_0x131c13(0xbe),_0x131c13(0xce)),await runBuild();}catch(_0x2367e6){console[_0x131c13(0x8e)](_0x2367e6),process[_0x131c13(0xa0)](0x1);}break;}case _0x131c13(0x84):{const _0x1ad1b5=cli[_0x131c13(0x89)]['watch'];logger[_0x131c13(0xab)](process[_0x131c13(0x98)]()),logger[_0x131c13(0xcf)]('preview',_0x131c13(0xa9)+(_0x1ad1b5?'\x20(监听模式)':''));if(_0x1ad1b5)try{await Promise[_0x131c13(0xae)]([runBuildWatch(),runPreview()]);}catch(_0x3d5d4c){console[_0x131c13(0x8e)](_0x3d5d4c),process[_0x131c13(0xa0)](0x1);}else try{await runPreview();}catch(_0x5bb426){console['error'](_0x5bb426),process['exit'](0x1);}break;}case _0x131c13(0x87):{render(a32_0x2be163(Config,{'cli':cli}));break;}case _0x131c13(0x96):{await apiCli(cli);break;}case _0x131c13(0xc1):{render(a32_0x2be163(AuthServer,{}));break;}case _0x131c13(0xa4):{if(_0xf7a9fe===_0x131c13(0x9b)){logger['setLogPath'](process[_0x131c13(0x98)]()),logger['info'](_0x131c13(0x90),_0x131c13(0xb5)),render(a32_0x2be163(AppMenuUpdateCdn,{}));break;}else logger[_0x131c13(0xab)](process['cwd']()),logger[_0x131c13(0xcf)](_0x131c13(0xbd),'同步菜单命令'),render(a32_0x2be163(AppMenuSyncUI,{}));break;}case _0x131c13(0xad):{logout();break;}case _0x131c13(0x8b):{const _0x470d3d=cli[_0x131c13(0x93)][0x1];logger['setLogPath'](process['cwd']());if(_0x470d3d===_0x131c13(0xb2)){const _0x47a10f=[];if(cli[_0x131c13(0x89)][_0x131c13(0xba)]||cli[_0x131c13(0x89)][_0x131c13(0x8f)])_0x47a10f[_0x131c13(0xc8)](_0x131c13(0x8f));if(cli[_0x131c13(0x89)][_0x131c13(0xa2)]||cli[_0x131c13(0x89)][_0x131c13(0xcb)])_0x47a10f['push'](_0x131c13(0xcb));if(cli[_0x131c13(0x89)][_0x131c13(0xcc)])_0x47a10f[_0x131c13(0xc8)]('other');logger[_0x131c13(0xcf)]('mcp-install',_0x131c13(0xc0),{'preselected':_0x47a10f});if(isNonInteractiveMode(cli['flags'])&&_0x47a10f['length']>0x0){const {installMcpNonInteractive:_0x2268e6}=await import(_0x131c13(0xb6));await _0x2268e6(_0x47a10f);}else render(a32_0x2be163(McpInstallUI,{'preselectedIDEs':_0x47a10f}));}else _0x470d3d===_0x131c13(0x91)||cli[_0x131c13(0x89)][_0x131c13(0xb0)]?await mcpCommand(_0x470d3d,[],{'help':!![]}):await mcpCommand(_0x470d3d,[],cli['flags']);break;}case _0x131c13(0xcd):{const _0x4b1df5=cli[_0x131c13(0x93)][0x1];logger[_0x131c13(0xab)](process[_0x131c13(0x98)]());if(_0x4b1df5===_0x131c13(0xb2)){const _0x17a076=[];if(cli[_0x131c13(0x89)][_0x131c13(0xae)])_0x17a076[_0x131c13(0xc8)](_0x131c13(0x8f),_0x131c13(0x8a),'claude',_0x131c13(0xb8),'codex',_0x131c13(0xd2),_0x131c13(0x8c),_0x131c13(0xa3),_0x131c13(0x99),'agent',_0x131c13(0xc9));else{if(cli[_0x131c13(0x89)]['cursor'])_0x17a076['push'](_0x131c13(0x8f));if(cli[_0x131c13(0x89)]['windsurf'])_0x17a076['push']('windsurf');if(cli['flags'][_0x131c13(0xcb)])_0x17a076[_0x131c13(0xc8)](_0x131c13(0xcb));if(cli['flags']['cline'])_0x17a076['push'](_0x131c13(0xb8));if(cli[_0x131c13(0x89)]['codex'])_0x17a076[_0x131c13(0xc8)](_0x131c13(0xaa));if(cli['flags'][_0x131c13(0xd2)])_0x17a076[_0x131c13(0xc8)](_0x131c13(0xd2));if(cli[_0x131c13(0x89)]['qoder'])_0x17a076['push'](_0x131c13(0x8c));if(cli[_0x131c13(0x89)][_0x131c13(0xa3)])_0x17a076['push'](_0x131c13(0xa3));if(cli[_0x131c13(0x89)][_0x131c13(0x99)])_0x17a076[_0x131c13(0xc8)](_0x131c13(0x99));if(cli[_0x131c13(0x89)][_0x131c13(0x9c)])_0x17a076[_0x131c13(0xc8)](_0x131c13(0x9c));if(cli[_0x131c13(0x89)][_0x131c13(0xc9)])_0x17a076[_0x131c13(0xc8)](_0x131c13(0xc9));}const {getAllProvidedFlags:_0x313929}=await import(_0x131c13(0x88)),_0x191fcb=_0x313929(cli[_0x131c13(0x89)]);logger['info'](_0x131c13(0xb3),_0x131c13(0x85),{'preselected':_0x17a076,'providedFlags':_0x191fcb});if(isNonInteractiveMode(cli['flags'])&&_0x17a076[_0x131c13(0x9f)]>0x0){const {installSkillsNonInteractive:_0x13f5d0}=await import(_0x131c13(0xd0));await _0x13f5d0(_0x17a076,_0x191fcb);}else render(a32_0x2be163(SkillInstallUI,{'preselectedIDEs':_0x17a076,'providedFlags':_0x191fcb}));}else _0x4b1df5===_0x131c13(0x91)||cli[_0x131c13(0x89)][_0x131c13(0xb0)]?await skillsCommand(_0x4b1df5,[],{'help':!![]}):await skillsCommand(_0x4b1df5,[],cli[_0x131c13(0x89)]);break;}case'logs':{cli[_0x131c13(0x89)][_0x131c13(0xa7)]?clearLogs():showLogs();break;}default:render(a32_0x2be163(Help,{}));break;}}
|
|
2
|
+
const a32_0x271113=a32_0x15eb;(function(_0x1f9862,_0x573cc9){const _0x23f479=a32_0x15eb,_0x7f73f8=_0x1f9862();while(!![]){try{const _0x10575a=-parseInt(_0x23f479(0x15f))/0x1+parseInt(_0x23f479(0x184))/0x2+parseInt(_0x23f479(0x17b))/0x3*(parseInt(_0x23f479(0x175))/0x4)+-parseInt(_0x23f479(0x171))/0x5*(-parseInt(_0x23f479(0x15c))/0x6)+-parseInt(_0x23f479(0x18e))/0x7*(-parseInt(_0x23f479(0x153))/0x8)+-parseInt(_0x23f479(0x172))/0x9+-parseInt(_0x23f479(0x156))/0xa;if(_0x10575a===_0x573cc9)break;else _0x7f73f8['push'](_0x7f73f8['shift']());}catch(_0x4175f3){_0x7f73f8['push'](_0x7f73f8['shift']());}}}(a32_0x467e,0x6884c));import{jsx as a32_0x5dfcd7}from'react/jsx-runtime';import a32_0x52e7aa 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';function a32_0x15eb(_0xde451a,_0x567a19){_0xde451a=_0xde451a-0x140;const _0x467e95=a32_0x467e();let _0x15ebab=_0x467e95[_0xde451a];return _0x15ebab;}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';let dynamicCliFlags=null;try{dynamicCliFlags=(await import(a32_0x271113(0x18b)))['dynamicCliFlags'];}catch{}const mergedFlags={...dynamicCliFlags||{}};function isNonInteractiveMode(_0xa712df){const _0x4f5a20=a32_0x271113;return!!(_0xa712df[_0x4f5a20(0x145)]||_0xa712df['ci']||process['env']['LOVRABET_CI']==='true'||process[_0x4f5a20(0x185)]['CI']===_0x4f5a20(0x181)||!process[_0x4f5a20(0x16a)][_0x4f5a20(0x16e)]);}const cli=a32_0x52e7aa(a32_0x271113(0x191),{'importMeta':import.meta,'flags':{'name':{'type':a32_0x271113(0x157)},'clear':{'type':'boolean'},'env':{'type':a32_0x271113(0x157)},'watch':{'type':a32_0x271113(0x143)},'help':{'type':a32_0x271113(0x143)},'appcode':{'type':a32_0x271113(0x157)},'output':{'type':a32_0x271113(0x157)},'params':{'type':'string'},'datasetcode':{'type':a32_0x271113(0x157)},'mcpCursor':{'type':a32_0x271113(0x143)},'mcpClaude':{'type':a32_0x271113(0x143)},'mcpOther':{'type':a32_0x271113(0x143)},'cursor':{'type':a32_0x271113(0x143)},'windsurf':{'type':a32_0x271113(0x143)},'claude':{'type':a32_0x271113(0x143)},'cline':{'type':a32_0x271113(0x143)},'codex':{'type':'boolean'},'opencode':{'type':a32_0x271113(0x143)},'qoder':{'type':'boolean'},'codebuddy':{'type':'boolean'},'trae':{'type':a32_0x271113(0x143)},'agent':{'type':a32_0x271113(0x143)},'antigravity':{'type':a32_0x271113(0x143)},'all':{'type':'boolean'},'nonInteractive':{'type':a32_0x271113(0x143)},'ci':{'type':a32_0x271113(0x143)},...mergedFlags},'autoVersion':!![]});function a32_0x467e(){const _0x14e7ef=['claude','执行预览命令','15035nhnOCZ','join','./create-app/non-interactive.js','input','mcpClaude','非交互模式创建项目:\x20','menu-update-cdn','执行配置\x20MCP\x20命令','preview','cline','qoder','stdout','\x20(监听模式)','start','./mcp/mcp-install-non-interactive.js','isTTY','info','opencode','1303465kynRSM','3189492iBOxui','执行启动命令','trim','7220gdHjzE','agent','setLogPath','trae','flags','mcpOther','1083mCdmuV','logs','cursor','setRawCommand','clear','push','true','appcode','all','37060CqMOUS','env','help','api','config','menu-sync','other','./cli-flags.js','./skills/skill-install-non-interactive.js','codex','7yiiXfc','create','menu','\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\x20skill\x20install\x20--dangerously-bff-save\x20//\x20包含\x20Backend\x20Function\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','update','antigravity','slice','auth','boolean','执行添加页面命令','nonInteractive','同步菜单命令','--help','windsurf','add-page','install','lovrabet\x20','exit','build','logout','page','skill','mcp','cwd','1919032YQUnWU','add','执行更新菜单\x20CDN\x20资源命令','6338690KCzLRB','string','codebuddy','length','mcpCursor','error','12UatZlk'];a32_0x467e=function(){return _0x14e7ef;};return a32_0x467e();}await run();async function run(){const _0x40238f=a32_0x271113,_0x9288b3=cli[_0x40238f(0x162)][0x0],_0x373d39=cli[_0x40238f(0x162)][0x1],_0x138a6a=cli['input'][0x2],_0x494a84=(_0x40238f(0x14b)+process['argv'][_0x40238f(0x141)](0x2)[_0x40238f(0x160)]('\x20'))[_0x40238f(0x174)]();logger[_0x40238f(0x17e)](_0x494a84);switch(_0x9288b3){case'init':{const _0x5398c8=cli['flags'][_0x40238f(0x182)],_0x145b78=cli[_0x40238f(0x179)][_0x40238f(0x185)];logger[_0x40238f(0x177)](process[_0x40238f(0x152)]()),logger[_0x40238f(0x16f)]('init','执行初始化配置命令'),render(a32_0x5dfcd7(Init,{'appcode':_0x5398c8,'env':_0x145b78}));break;}case _0x40238f(0x18f):{const _0x3e77bd=cli[_0x40238f(0x162)][0x1]?.[_0x40238f(0x174)](),_0x24a330=cli[_0x40238f(0x179)][_0x40238f(0x185)],_0x2649c5=isNonInteractiveMode(cli[_0x40238f(0x179)]);if(_0x2649c5&&_0x3e77bd){logger['setLogPath'](process[_0x40238f(0x152)]()),logger[_0x40238f(0x16f)]('create',_0x40238f(0x164)+_0x3e77bd);const {createProjectNonInteractive:_0x1acbcd}=await import(_0x40238f(0x161));await _0x1acbcd(_0x3e77bd,_0x24a330);}else render(a32_0x5dfcd7(CreateApp,{'projectCode':_0x3e77bd,'env':_0x24a330}));break;}case _0x40238f(0x154):{cli[_0x40238f(0x162)][0x1]===_0x40238f(0x14f)&&(logger[_0x40238f(0x177)](process[_0x40238f(0x152)]()),logger[_0x40238f(0x16f)](_0x40238f(0x149),_0x40238f(0x144)),render(a32_0x5dfcd7(AddPage,{})));break;}case _0x40238f(0x16c):{try{logger[_0x40238f(0x177)](process['cwd']()),logger['info'](_0x40238f(0x16c),_0x40238f(0x173)),await runStart();}catch(_0x18be36){console[_0x40238f(0x15b)](_0x18be36),process['exit'](0x1);}break;}case _0x40238f(0x14d):{try{logger[_0x40238f(0x177)](process[_0x40238f(0x152)]()),logger['info'](_0x40238f(0x14d),'执行构建命令'),await runBuild();}catch(_0x10826a){console[_0x40238f(0x15b)](_0x10826a),process[_0x40238f(0x14c)](0x1);}break;}case _0x40238f(0x167):{const _0x2d5cb9=cli['flags']['watch'];logger[_0x40238f(0x177)](process[_0x40238f(0x152)]()),logger[_0x40238f(0x16f)](_0x40238f(0x167),_0x40238f(0x15e)+(_0x2d5cb9?_0x40238f(0x16b):''));if(_0x2d5cb9)try{await Promise[_0x40238f(0x183)]([runBuildWatch(),runPreview()]);}catch(_0x4173af){console[_0x40238f(0x15b)](_0x4173af),process[_0x40238f(0x14c)](0x1);}else try{await runPreview();}catch(_0x1ebe68){console['error'](_0x1ebe68),process[_0x40238f(0x14c)](0x1);}break;}case _0x40238f(0x188):{render(a32_0x5dfcd7(Config,{'cli':cli}));break;}case _0x40238f(0x187):{await apiCli(cli);break;}case _0x40238f(0x142):{render(a32_0x5dfcd7(AuthServer,{}));break;}case _0x40238f(0x190):{if(_0x373d39===_0x40238f(0x192)){logger[_0x40238f(0x177)](process['cwd']()),logger[_0x40238f(0x16f)](_0x40238f(0x165),_0x40238f(0x155)),render(a32_0x5dfcd7(AppMenuUpdateCdn,{}));break;}else logger[_0x40238f(0x177)](process['cwd']()),logger[_0x40238f(0x16f)](_0x40238f(0x189),_0x40238f(0x146)),render(a32_0x5dfcd7(AppMenuSyncUI,{}));break;}case _0x40238f(0x14e):{logout();break;}case _0x40238f(0x151):{const _0x2a8de8=cli[_0x40238f(0x162)][0x1];logger[_0x40238f(0x177)](process[_0x40238f(0x152)]());if(_0x2a8de8===_0x40238f(0x14a)){const _0x27caa6=[];if(cli[_0x40238f(0x179)][_0x40238f(0x15a)]||cli[_0x40238f(0x179)][_0x40238f(0x17d)])_0x27caa6[_0x40238f(0x180)](_0x40238f(0x17d));if(cli[_0x40238f(0x179)][_0x40238f(0x163)]||cli['flags']['claude'])_0x27caa6[_0x40238f(0x180)]('claude');if(cli[_0x40238f(0x179)][_0x40238f(0x17a)])_0x27caa6[_0x40238f(0x180)](_0x40238f(0x18a));logger[_0x40238f(0x16f)]('mcp-install',_0x40238f(0x166),{'preselected':_0x27caa6});if(isNonInteractiveMode(cli['flags'])&&_0x27caa6[_0x40238f(0x159)]>0x0){const {installMcpNonInteractive:_0x1b9b71}=await import(_0x40238f(0x16d));await _0x1b9b71(_0x27caa6);}else render(a32_0x5dfcd7(McpInstallUI,{'preselectedIDEs':_0x27caa6}));}else _0x2a8de8===_0x40238f(0x147)||cli[_0x40238f(0x179)][_0x40238f(0x186)]?await mcpCommand(_0x2a8de8,[],{'help':!![]}):await mcpCommand(_0x2a8de8,[],cli[_0x40238f(0x179)]);break;}case _0x40238f(0x150):{const _0x4e041d=cli['input'][0x1];logger[_0x40238f(0x177)](process[_0x40238f(0x152)]());if(_0x4e041d==='install'){const _0x2f9767=[];if(cli[_0x40238f(0x179)]['all'])_0x2f9767['push'](_0x40238f(0x17d),_0x40238f(0x148),_0x40238f(0x15d),_0x40238f(0x168),'codex',_0x40238f(0x170),_0x40238f(0x169),_0x40238f(0x158),_0x40238f(0x178),_0x40238f(0x176),_0x40238f(0x140));else{if(cli['flags'][_0x40238f(0x17d)])_0x2f9767['push']('cursor');if(cli[_0x40238f(0x179)][_0x40238f(0x148)])_0x2f9767[_0x40238f(0x180)]('windsurf');if(cli['flags'][_0x40238f(0x15d)])_0x2f9767['push'](_0x40238f(0x15d));if(cli[_0x40238f(0x179)]['cline'])_0x2f9767[_0x40238f(0x180)](_0x40238f(0x168));if(cli[_0x40238f(0x179)][_0x40238f(0x18d)])_0x2f9767['push'](_0x40238f(0x18d));if(cli['flags'][_0x40238f(0x170)])_0x2f9767[_0x40238f(0x180)](_0x40238f(0x170));if(cli['flags']['qoder'])_0x2f9767['push'](_0x40238f(0x169));if(cli['flags'][_0x40238f(0x158)])_0x2f9767[_0x40238f(0x180)](_0x40238f(0x158));if(cli[_0x40238f(0x179)][_0x40238f(0x178)])_0x2f9767['push'](_0x40238f(0x178));if(cli[_0x40238f(0x179)]['agent'])_0x2f9767[_0x40238f(0x180)](_0x40238f(0x176));if(cli[_0x40238f(0x179)][_0x40238f(0x140)])_0x2f9767[_0x40238f(0x180)](_0x40238f(0x140));}const {getAllProvidedFlags:_0x1a2b2d}=await import('./skills/main.js'),_0x3ef788=_0x1a2b2d(cli['flags']);logger[_0x40238f(0x16f)]('skill-install','执行安装技能包命令',{'preselected':_0x2f9767,'providedFlags':_0x3ef788});if(isNonInteractiveMode(cli[_0x40238f(0x179)])&&_0x2f9767[_0x40238f(0x159)]>0x0){const {installSkillsNonInteractive:_0x17d09a}=await import(_0x40238f(0x18c));await _0x17d09a(_0x2f9767,_0x3ef788);}else render(a32_0x5dfcd7(SkillInstallUI,{'preselectedIDEs':_0x2f9767,'providedFlags':_0x3ef788}));}else _0x4e041d===_0x40238f(0x147)||cli[_0x40238f(0x179)][_0x40238f(0x186)]?await skillsCommand(_0x4e041d,[],{'help':!![]}):await skillsCommand(_0x4e041d,[],cli[_0x40238f(0x179)]);break;}case _0x40238f(0x17c):{cli[_0x40238f(0x179)][_0x40238f(0x17f)]?clearLogs():showLogs();break;}default:render(a32_0x5dfcd7(Help,{}));break;}}
|
package/lib/cmd/build-watch.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a33_0x3e16(_0x4fca8,_0xff14ab){_0x4fca8=_0x4fca8-0x70;const _0x292a96=a33_0x292a();let _0x3e168d=_0x292a96[_0x4fca8];return _0x3e168d;}(function(_0x1785c2,_0xbe51a4){const _0x2de650=a33_0x3e16,_0x1a86c5=_0x1785c2();while(!![]){try{const _0x23f6fd=parseInt(_0x2de650(0x74))/0x1*(parseInt(_0x2de650(0x70))/0x2)+-parseInt(_0x2de650(0x72))/0x3*(parseInt(_0x2de650(0x7a))/0x4)+-parseInt(_0x2de650(0x7b))/0x5*(parseInt(_0x2de650(0x80))/0x6)+parseInt(_0x2de650(0x7e))/0x7*(-parseInt(_0x2de650(0x77))/0x8)+-parseInt(_0x2de650(0x7c))/0x9+parseInt(_0x2de650(0x82))/0xa+parseInt(_0x2de650(0x84))/0xb;if(_0x23f6fd===_0xbe51a4)break;else _0x1a86c5['push'](_0x1a86c5['shift']());}catch(_0x178980){_0x1a86c5['push'](_0x1a86c5['shift']());}}}(a33_0x292a,0xeb2f6));function a33_0x292a(){const _0x4c6b06=['1208001cffMzG','--watch','2uIrpke','close','npm\x20run\x20build\x20exited\x20with\x20code\x20','2299808SFwXEQ','PATH','cwd','8QFGTHh','5KxLikf','8152128tjmVVw','vite','7AatetT','node_modules','11234352jjQXbY','build','13862000zCYhxJ','error','23240514WqcLEM','env','1335338WRcBbk','inherit'];a33_0x292a=function(){return _0x4c6b06;};return a33_0x292a();}import{spawn}from'node:child_process';import{delimiter,join}from'node:path';export function runBuildWatch(){return new Promise((_0x30671d,_0x148477)=>{const _0x16b74a=a33_0x3e16,_0x401a1f=spawn(_0x16b74a(0x7d),[_0x16b74a(0x81),_0x16b74a(0x73)],{'stdio':_0x16b74a(0x71),'shell':!![],'env':{...process[_0x16b74a(0x85)],'PATH':''+join(process[_0x16b74a(0x79)](),_0x16b74a(0x7f),'.bin')+delimiter+process[_0x16b74a(0x85)][_0x16b74a(0x78)]}});_0x401a1f['on'](_0x16b74a(0x75),_0x47a9b8=>{const _0x5798dd=_0x16b74a;if(_0x47a9b8===0x0||_0x47a9b8===null)_0x30671d();else _0x148477(new Error(_0x5798dd(0x76)+_0x47a9b8));}),_0x401a1f['on'](_0x16b74a(0x83),_0x148477);});}
|
package/lib/cmd/build.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x14b039,_0x3b1aae){const _0x1c9e65=a34_0x5c79,_0x103da7=_0x14b039();while(!![]){try{const _0x4a7050=-parseInt(_0x1c9e65(0x81))/0x1+parseInt(_0x1c9e65(0x73))/0x2+parseInt(_0x1c9e65(0x71))/0x3+parseInt(_0x1c9e65(0x82))/0x4+parseInt(_0x1c9e65(0x83))/0x5*(-parseInt(_0x1c9e65(0x75))/0x6)+-parseInt(_0x1c9e65(0x74))/0x7+parseInt(_0x1c9e65(0x79))/0x8;if(_0x4a7050===_0x3b1aae)break;else _0x103da7['push'](_0x103da7['shift']());}catch(_0x464345){_0x103da7['push'](_0x103da7['shift']());}}}(a34_0x2ab8,0xa718b));import{delimiter,join}from'node:path';function a34_0x5c79(_0x16ac7f,_0x20c314){_0x16ac7f=_0x16ac7f-0x6a;const _0x2ab83a=a34_0x2ab8();let _0x5c796b=_0x2ab83a[_0x16ac7f];return _0x5c796b;}function a34_0x2ab8(){const _0x1fed47=['run','node_modules','info','close','项目构建出错','项目构建成功','error','1203947UKVNff','466872cBioCA','167070ljhQJD','cwd','开始构建项目','trim','message','npm','env','toString','inherit','stderr','success','npm\x20run\x20build','2385072nqdSdm','npm\x20run\x20build\x20exited\x20with\x20code\x20','1897246VsIyXz','7876673nuNKLX','138TwvgUw','项目构建失败','now','build','15374160lEwQWd'];a34_0x2ab8=function(){return _0x1fed47;};return a34_0x2ab8();}import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';export function runBuild(){return new Promise((_0x4335ef,_0x2d1e26)=>{const _0x28c15f=a34_0x5c79,_0x1bf7fd=Date[_0x28c15f(0x77)]();logger[_0x28c15f(0x7c)](_0x28c15f(0x78),_0x28c15f(0x85),{'command':_0x28c15f(0x70)});let _0x45fc35='';const _0x40fd45=spawn(_0x28c15f(0x6a),[_0x28c15f(0x7a),_0x28c15f(0x78)],{'stdio':[_0x28c15f(0x6d),_0x28c15f(0x6d),'pipe'],'shell':!![],'env':{...process[_0x28c15f(0x6b)],'PATH':''+join(process[_0x28c15f(0x84)](),_0x28c15f(0x7b),'.bin')+delimiter+process[_0x28c15f(0x6b)]['PATH']}});_0x40fd45[_0x28c15f(0x6e)]?.['on']('data',_0x485ac0=>{const _0x49167e=_0x28c15f;_0x45fc35+=_0x485ac0[_0x49167e(0x6c)]();}),_0x40fd45['on'](_0x28c15f(0x7d),_0x2212ff=>{const _0x21ee09=_0x28c15f,_0x29735c=Date['now']()-_0x1bf7fd;if(_0x2212ff===0x0||_0x2212ff===null)logger[_0x21ee09(0x6f)](_0x21ee09(0x78),_0x21ee09(0x7f),_0x29735c),_0x4335ef();else{const _0xad7ebd={'exitCode':_0x2212ff,'duration':_0x29735c,'command':'npm\x20run\x20build','cwd':process['cwd']()};_0x45fc35[_0x21ee09(0x86)]()&&(_0xad7ebd[_0x21ee09(0x6e)]=_0x45fc35[_0x21ee09(0x86)]()),logger[_0x21ee09(0x80)](_0x21ee09(0x78),_0x21ee09(0x76),_0xad7ebd),_0x2d1e26(new Error(_0x21ee09(0x72)+_0x2212ff));}}),_0x40fd45['on'](_0x28c15f(0x80),_0x4ed1ee=>{const _0x42170d=_0x28c15f,_0x4f4464=Date[_0x42170d(0x77)]()-_0x1bf7fd;logger[_0x42170d(0x80)](_0x42170d(0x78),_0x42170d(0x7e),{'error':_0x4ed1ee[_0x42170d(0x87)],'duration':_0x4f4464,'stderr':_0x45fc35[_0x42170d(0x86)]()||undefined}),_0x2d1e26(_0x4ed1ee);});});}
|
package/lib/cmd/logs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4485dc,_0x52e62f){const _0xc682fd=a35_0x1d49,_0x5cadfd=_0x4485dc();while(!![]){try{const _0x457e2a=-parseInt(_0xc682fd(0x17e))/0x1+parseInt(_0xc682fd(0x182))/0x2+-parseInt(_0xc682fd(0x185))/0x3+-parseInt(_0xc682fd(0x192))/0x4+-parseInt(_0xc682fd(0x189))/0x5*(parseInt(_0xc682fd(0x195))/0x6)+parseInt(_0xc682fd(0x184))/0x7+-parseInt(_0xc682fd(0x194))/0x8*(-parseInt(_0xc682fd(0x18b))/0x9);if(_0x457e2a===_0x52e62f)break;else _0x5cadfd['push'](_0x5cadfd['shift']());}catch(_0x2de34c){_0x5cadfd['push'](_0x5cadfd['shift']());}}}(a35_0x4168,0x96b60));import{logger}from'../utils/logger.js';export function showLogs(){const _0x4fe9a6=a35_0x1d49;logger['setLogPath'](process[_0x4fe9a6(0x18f)]());const _0x43f67a=logger[_0x4fe9a6(0x18c)]();if(_0x43f67a[_0x4fe9a6(0x17f)]===0x0){console['log'](_0x4fe9a6(0x196));return;}console[_0x4fe9a6(0x18a)](_0x4fe9a6(0x197)),_0x43f67a[_0x4fe9a6(0x181)]((_0xad944b,_0x18c69e)=>{const _0x653fde=_0x4fe9a6,_0x5c06c3=new Date(_0xad944b[_0x653fde(0x186)])['toLocaleString'](_0x653fde(0x188)),_0x4206f6=_0xad944b[_0x653fde(0x180)]===_0x653fde(0x193)?'√':_0xad944b[_0x653fde(0x180)]===_0x653fde(0x18d)?'×':_0xad944b[_0x653fde(0x180)]==='warn'?'!':'i';console[_0x653fde(0x18a)](_0x18c69e+0x1+'.\x20'+_0x4206f6+'\x20['+_0xad944b[_0x653fde(0x17d)]+']\x20'+_0xad944b[_0x653fde(0x190)]),console['log'](_0x653fde(0x191)+_0x5c06c3),_0xad944b[_0x653fde(0x187)]&&console['log']('\x20\x20\x20耗时:\x20'+_0xad944b[_0x653fde(0x187)]+'ms'),_0xad944b[_0x653fde(0x18e)]&&Object['keys'](_0xad944b['details'])['length']>0x0&&console['log']('\x20\x20\x20详情:\x20'+JSON[_0x653fde(0x183)](_0xad944b[_0x653fde(0x18e)],null,0x2)),console[_0x653fde(0x18a)]('');});}export function clearLogs(){const _0x3b2d2c=a35_0x1d49;logger[_0x3b2d2c(0x198)](process[_0x3b2d2c(0x18f)]()),logger['clearLogs'](),console[_0x3b2d2c(0x18a)](_0x3b2d2c(0x199));}function a35_0x1d49(_0x6dc5d,_0x118ef8){_0x6dc5d=_0x6dc5d-0x17d;const _0x4168ff=a35_0x4168();let _0x1d4903=_0x4168ff[_0x6dc5d];return _0x1d4903;}function a35_0x4168(){const _0x26a656=['3534270SrcPFg','timestamp','duration','zh-CN','138155oXRoGC','log','1398726VqCums','readLogs','error','details','cwd','message','\x20\x20\x20时间:\x20','327108QJPAvb','success','144mPAQWE','246IJAxet','*\x20暂无日志记录','*\x20Lovrabet\x20CLI\x20日志记录:\x0a','setLogPath','*\x20日志已清空','command','154716pPlSbF','length','level','forEach','362040vDzopF','stringify','1304058pcvdAX'];a35_0x4168=function(){return _0x26a656;};return a35_0x4168();}
|
package/lib/cmd/preview.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4bdd50,_0x1e5bdd){const _0x193830=a36_0x37ec,_0x434608=_0x4bdd50();while(!![]){try{const _0x15b6af=parseInt(_0x193830(0x13c))/0x1*(-parseInt(_0x193830(0x133))/0x2)+-parseInt(_0x193830(0x13e))/0x3*(parseInt(_0x193830(0x13f))/0x4)+-parseInt(_0x193830(0x146))/0x5+parseInt(_0x193830(0x14b))/0x6+parseInt(_0x193830(0x144))/0x7*(parseInt(_0x193830(0x148))/0x8)+-parseInt(_0x193830(0x147))/0x9+parseInt(_0x193830(0x14c))/0xa;if(_0x15b6af===_0x1e5bdd)break;else _0x434608['push'](_0x434608['shift']());}catch(_0x27ffd8){_0x434608['push'](_0x434608['shift']());}}}(a36_0x3dba,0xea82f));function a36_0x37ec(_0x148fcd,_0x370ed9){_0x148fcd=_0x148fcd-0x12a;const _0x3dbabc=a36_0x3dba();let _0x37ec8c=_0x3dbabc[_0x148fcd];return _0x37ec8c;}import{delimiter,join}from'node:path';import{spawn}from'node:child_process';function a36_0x3dba(){const _0x20a11b=['启动预览服务器','cwd','toString','预览服务器启动成功','431025zbqCtq','vite\x20preview\x20exited\x20with\x20code\x20','2362075rsiGYC','12286926BnTTfU','40cRjbta','error','pipe','9732156DwNsnh','33261000wNVfDQ','close','vite','now','预览服务器启动出错','预览服务器启动失败','env','vite\x20preview','preview','node_modules','15834bntxXw','data','stderr','success','info','.bin','PATH','trim','inherit','123cOmrBc','message','3DdvzXx','5936088zPBsRe'];a36_0x3dba=function(){return _0x20a11b;};return a36_0x3dba();}import{logger}from'../utils/logger.js';export function runPreview(){return new Promise((_0x2e8aff,_0xa5ee10)=>{const _0x50c06e=a36_0x37ec,_0x4dd57a=Date['now']();logger[_0x50c06e(0x137)](_0x50c06e(0x131),_0x50c06e(0x140),{'command':_0x50c06e(0x130)});let _0x24743f='';const _0x528235=spawn(_0x50c06e(0x12b),['preview'],{'stdio':[_0x50c06e(0x13b),_0x50c06e(0x13b),_0x50c06e(0x14a)],'shell':!![],'env':{...process['env'],'PATH':''+join(process[_0x50c06e(0x141)](),_0x50c06e(0x132),_0x50c06e(0x138))+delimiter+process[_0x50c06e(0x12f)][_0x50c06e(0x139)]}});_0x528235[_0x50c06e(0x135)]?.['on'](_0x50c06e(0x134),_0xa5a062=>{const _0x48a919=_0x50c06e;_0x24743f+=_0xa5a062[_0x48a919(0x142)]();}),_0x528235['on'](_0x50c06e(0x12a),_0x99ba6c=>{const _0x480837=_0x50c06e,_0x2b5238=Date[_0x480837(0x12c)]()-_0x4dd57a;if(_0x99ba6c===0x0||_0x99ba6c===null)logger[_0x480837(0x136)](_0x480837(0x131),_0x480837(0x143),_0x2b5238),_0x2e8aff();else{const _0x1aa758={'exitCode':_0x99ba6c,'duration':_0x2b5238,'command':'vite\x20preview','cwd':process[_0x480837(0x141)]()};_0x24743f[_0x480837(0x13a)]()&&(_0x1aa758[_0x480837(0x135)]=_0x24743f['trim']()),logger[_0x480837(0x149)](_0x480837(0x131),_0x480837(0x12e),_0x1aa758),_0xa5ee10(new Error(_0x480837(0x145)+_0x99ba6c));}}),_0x528235['on'](_0x50c06e(0x149),_0x34251b=>{const _0x5215fb=_0x50c06e,_0x1ed430=Date[_0x5215fb(0x12c)]()-_0x4dd57a;logger[_0x5215fb(0x149)](_0x5215fb(0x131),_0x5215fb(0x12d),{'error':_0x34251b[_0x5215fb(0x13d)],'duration':_0x1ed430,'stderr':_0x24743f[_0x5215fb(0x13a)]()||undefined}),_0xa5ee10(_0x34251b);});});}
|
package/lib/cmd/start.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x30c546,_0x37cf01){const _0x3a2b85=a37_0x20da,_0x3a9c43=_0x30c546();while(!![]){try{const _0x38d523=parseInt(_0x3a2b85(0x150))/0x1+parseInt(_0x3a2b85(0x151))/0x2*(parseInt(_0x3a2b85(0x166))/0x3)+-parseInt(_0x3a2b85(0x14c))/0x4*(-parseInt(_0x3a2b85(0x157))/0x5)+parseInt(_0x3a2b85(0x155))/0x6+-parseInt(_0x3a2b85(0x156))/0x7*(-parseInt(_0x3a2b85(0x144))/0x8)+parseInt(_0x3a2b85(0x149))/0x9+-parseInt(_0x3a2b85(0x15e))/0xa;if(_0x38d523===_0x37cf01)break;else _0x3a9c43['push'](_0x3a9c43['shift']());}catch(_0x4f57c4){_0x3a9c43['push'](_0x3a9c43['shift']());}}}(a37_0x393d,0x6ee38));import{delimiter,join}from'node:path';import{spawn}from'node:child_process';function a37_0x393d(){const _0x8f3e2b=['pipe','PATH','144099TOOsol','开发服务器启动成功','CLI\x20版本有更新','16wiUAYw','start','env','stderr','554969QLUsWB','5062VEciPz','version','vite','warn','5104134AuwtBd','7noLPbO','940mekCNn','inherit','close','success','data','now','SDK\x20版本有更新','14825310tiOlMg','cwd','trim','node_modules','.bin','开发服务器启动出错','stableVersion','开发服务器启动失败','69HzzuYu','info','3648776lancYf','write','启动开发服务器'];a37_0x393d=function(){return _0x8f3e2b;};return a37_0x393d();}import{logger}from'../utils/logger.js';import{checkSdkVersion,printSdkUpgradeWarning}from'../utils/check-sdk-version.js';function a37_0x20da(_0x3abc26,_0x2c129a){_0x3abc26=_0x3abc26-0x144;const _0x393dab=a37_0x393d();let _0x20da6a=_0x393dab[_0x3abc26];return _0x20da6a;}import{checkCliVersion,printCliUpgradeWarning}from'../utils/cli-version-check.js';export async function runStart(_0x138048){const _0x77c89d=a37_0x20da,_0x457319=Date[_0x77c89d(0x15c)](),_0x3a42db=_0x138048||process[_0x77c89d(0x15f)](),_0x2e71e6=await checkCliVersion();_0x2e71e6['needsUpgrade']&&(printCliUpgradeWarning(_0x2e71e6),logger[_0x77c89d(0x154)]('start',_0x77c89d(0x14b),{'currentVersion':_0x2e71e6['currentVersion'],'stableVersion':_0x2e71e6[_0x77c89d(0x164)]}));const _0x400580=await checkSdkVersion(_0x3a42db);_0x400580['needsUpgrade']&&(printSdkUpgradeWarning(_0x400580),logger['warn'](_0x77c89d(0x14d),_0x77c89d(0x15d),{'currentVersion':_0x400580[_0x77c89d(0x152)],'stableVersion':_0x400580['stableVersion']}));logger[_0x77c89d(0x167)](_0x77c89d(0x14d),_0x77c89d(0x146),{'command':_0x77c89d(0x153),'cwd':_0x3a42db});let _0x7272e3='';const _0x482849=spawn(_0x77c89d(0x153),{'stdio':[_0x77c89d(0x158),'inherit',_0x77c89d(0x147)],'shell':!![],'cwd':_0x3a42db,'env':{...process[_0x77c89d(0x14e)],'PATH':''+join(_0x3a42db,_0x77c89d(0x161),_0x77c89d(0x162))+delimiter+process[_0x77c89d(0x14e)][_0x77c89d(0x148)]}});return _0x482849['stderr']?.['on'](_0x77c89d(0x15b),_0xd53a20=>{const _0x2a0a3a=_0x77c89d,_0x466c09=_0xd53a20['toString']();_0x7272e3+=_0x466c09,process[_0x2a0a3a(0x14f)][_0x2a0a3a(0x145)](_0x466c09);}),new Promise((_0xf38e97,_0x5d74bf)=>{const _0x58d8e5=_0x77c89d;_0x482849['on'](_0x58d8e5(0x159),_0x53f58d=>{const _0x19c344=_0x58d8e5,_0x27c8ea=Date['now']()-_0x457319;if(_0x53f58d===0x0||_0x53f58d===null)logger[_0x19c344(0x15a)](_0x19c344(0x14d),_0x19c344(0x14a),_0x27c8ea),_0xf38e97();else{const _0x4f2382={'exitCode':_0x53f58d,'duration':_0x27c8ea,'command':_0x19c344(0x153),'cwd':_0x3a42db};_0x7272e3[_0x19c344(0x160)]()&&(_0x4f2382[_0x19c344(0x14f)]=_0x7272e3[_0x19c344(0x160)]()),logger['error']('start',_0x19c344(0x165),_0x4f2382),_0x5d74bf(new Error('vite\x20exited\x20with\x20code\x20'+_0x53f58d));}}),_0x482849['on']('error',_0x249c36=>{const _0x42dde3=_0x58d8e5,_0x498d82=Date[_0x42dde3(0x15c)]()-_0x457319,_0x3fc5a3={'error':_0x249c36['message'],'duration':_0x498d82,'command':_0x42dde3(0x153),'cwd':_0x3a42db};_0x7272e3[_0x42dde3(0x160)]()&&(_0x3fc5a3[_0x42dde3(0x14f)]=_0x7272e3[_0x42dde3(0x160)]()),logger['error'](_0x42dde3(0x14d),_0x42dde3(0x163),_0x3fc5a3),_0x5d74bf(_0x249c36);});});}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x52d4f9,_0x565f05){const _0x2f5520=a38_0x4a60,_0x5d8482=_0x52d4f9();while(!![]){try{const _0x3c9092=parseInt(_0x2f5520(0x8f))/0x1*(parseInt(_0x2f5520(0x97))/0x2)+parseInt(_0x2f5520(0x96))/0x3*(parseInt(_0x2f5520(0xa4))/0x4)+-parseInt(_0x2f5520(0xa5))/0x5*(-parseInt(_0x2f5520(0x9b))/0x6)+-parseInt(_0x2f5520(0x9a))/0x7+parseInt(_0x2f5520(0xa6))/0x8*(-parseInt(_0x2f5520(0x9f))/0x9)+-parseInt(_0x2f5520(0x9d))/0xa+-parseInt(_0x2f5520(0xa7))/0xb*(-parseInt(_0x2f5520(0x99))/0xc);if(_0x3c9092===_0x565f05)break;else _0x5d8482['push'](_0x5d8482['shift']());}catch(_0x1af934){_0x5d8482['push'](_0x5d8482['shift']());}}}(a38_0x5011,0x225a3));function a38_0x5011(){const _0x4f8088=['44152SasJnD','2509177AXdYed','lovrabet\x20config\x20set\x20<key>\x20<value>\x20\x20\x20','description','获取配置项','设置环境\x20(online/daily)','1iDsVpY','gray','column','lovrabet\x20config\x20set\x20env\x20daily\x20\x20\x20\x20\x20\x20\x20','lovrabet\x20config\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20\x20\x20','map','80196uPOYPT','431754MGHRaU','lovrabet\x20config\x20get\x20<key>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','12sVlAhd','1406531RcBrWi','138CFrzEC','列出所有配置项','1025400QYRtrL','配置当前项目的\x20App\x20Code','207FjRdZI','无效的命令,可用命令如下:','lovrabet\x20config\x20set\x20app\x20app-xxxxx\x20\x20\x20','command','设置配置项','8acuvwP','16015jztNbE'];a38_0x5011=function(){return _0x4f8088;};return a38_0x5011();}function a38_0x4a60(_0xbc1698,_0x44961c){_0xbc1698=_0xbc1698-0x8c;const _0x50116b=a38_0x5011();let _0x4a607c=_0x50116b[_0xbc1698];return _0x4a607c;}import{jsxs as a38_0x4c4790,jsx as a38_0x3d84e2}from'react/jsx-runtime';import{Box,Text}from'ink';export function ConfigHelp(){const _0x2c914e=a38_0x4a60,_0x252fe0=[{'command':_0x2c914e(0xa8),'description':_0x2c914e(0xa3)},{'command':_0x2c914e(0x98),'description':_0x2c914e(0x8d)},{'command':_0x2c914e(0x93),'description':_0x2c914e(0x9c)}],_0x2ff052=[{'command':_0x2c914e(0xa1),'description':_0x2c914e(0x9e)},{'command':_0x2c914e(0x92),'description':_0x2c914e(0x8e)}];return a38_0x4c4790(Box,{'flexDirection':_0x2c914e(0x91),'marginTop':0x1,'marginBottom':0x1,'children':[a38_0x3d84e2(Box,{'marginBottom':0x1,'children':a38_0x4c4790(Text,{'color':_0x2c914e(0x90),'children':['\x20!','\x20\x20',_0x2c914e(0xa0)]})}),_0x252fe0['map'](_0x6a0506=>a38_0x4c4790(Box,{'children':[a38_0x4c4790(Text,{'children':[_0x2c914e(0x94),_0x6a0506['command']]}),a38_0x3d84e2(Text,{'color':_0x2c914e(0x90),'children':_0x6a0506['description']})]},_0x6a0506[_0x2c914e(0xa2)])),a38_0x3d84e2(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a38_0x3d84e2(Text,{'color':_0x2c914e(0x90),'children':'\x20*\x20配置示例:'})}),_0x2ff052[_0x2c914e(0x95)](_0x4e3283=>a38_0x4c4790(Box,{'children':[a38_0x4c4790(Text,{'children':[_0x2c914e(0x94),_0x4e3283[_0x2c914e(0xa2)]]}),a38_0x3d84e2(Text,{'color':_0x2c914e(0x90),'children':_0x4e3283[_0x2c914e(0x8c)]})]},_0x4e3283[_0x2c914e(0xa2)]))]});}
|
package/lib/config/main.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3caa0d,_0x1bf2c5){const _0x40bbfa=a39_0x5653,_0x39c9cc=_0x3caa0d();while(!![]){try{const _0x2a45c1=-parseInt(_0x40bbfa(0x19e))/0x1*(-parseInt(_0x40bbfa(0x1a2))/0x2)+parseInt(_0x40bbfa(0x1b4))/0x3*(parseInt(_0x40bbfa(0x191))/0x4)+parseInt(_0x40bbfa(0x194))/0x5*(parseInt(_0x40bbfa(0x1a4))/0x6)+-parseInt(_0x40bbfa(0x1a9))/0x7*(-parseInt(_0x40bbfa(0x1ae))/0x8)+parseInt(_0x40bbfa(0x198))/0x9+parseInt(_0x40bbfa(0x192))/0xa+-parseInt(_0x40bbfa(0x1a3))/0xb;if(_0x2a45c1===_0x1bf2c5)break;else _0x39c9cc['push'](_0x39c9cc['shift']());}catch(_0x21e485){_0x39c9cc['push'](_0x39c9cc['shift']());}}}(a39_0x3b17,0xa777d));import{jsx as a39_0x12bef6,jsxs as a39_0x1de45f}from'react/jsx-runtime';import{existsSync,readFileSync,writeFileSync}from'node:fs';function a39_0x3b17(){const _0x2750eb=['456210RnqIIp','unlinkSync','log','保存配置失败:\x20','get','parse','1EqNOlr','环境配置已设置为:\x20','undefined','includes','1498194TdLeHT','28116737ccNEim','24anYSQq','help','stringify','online','list','210oyItMw','input','red','mkdirSync','utf8','21936JSDuDu','未提供配置值','flags','error','config','length','318LTHgFJ','message','--help','保存配置失败','环境配置值只能是\x20\x22online\x22\x20或\x20\x22daily\x22','appcode','daily','env','app','25156ccftBE','7232510IQLpeS','.tmp','1212605rNyfjN','renameSync','set','配置值无效或过长'];a39_0x3b17=function(){return _0x2750eb;};return a39_0x3b17();}import a39_0x2f6331 from'node:fs';import a39_0x154508 from'node:path';function a39_0x5653(_0x4eefa1,_0xdc018d){_0x4eefa1=_0x4eefa1-0x18b;const _0x3b17e8=a39_0x3b17();let _0x565395=_0x3b17e8[_0x4eefa1];return _0x565395;}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(_0x577a04){const _0x3e1c13=a39_0x5653,{cli:_0x286dad}=_0x577a04,_0xa106a9=_0x286dad[_0x3e1c13(0x1aa)][0x1],_0x106911=_0x286dad['input'][0x2],_0x2c3aff=[_0x3e1c13(0x196),_0x3e1c13(0x19c)]['includes'](_0xa106a9||''),_0x74c9fd=_0x286dad[_0x3e1c13(0x1aa)]['length']>=0x3;if(_0x106911===_0x3e1c13(0x1b6)||_0x286dad[_0x3e1c13(0x1b0)][_0x3e1c13(0x1a5)])return a39_0x12bef6(ConfigHelp,{});const _0xc591db=readConfig();if(_0xa106a9===_0x3e1c13(0x196)){if(_0x106911){const _0x455c1d=_0x286dad[_0x3e1c13(0x1aa)][0x3];if(typeof _0x455c1d!==_0x3e1c13(0x1a0)){if(_0x106911==='env'&&![_0x3e1c13(0x1a7),_0x3e1c13(0x18e)][_0x3e1c13(0x1a1)](_0x455c1d))return a39_0x12bef6(Box,{'children':a39_0x12bef6(Text,{'color':'red','children':_0x3e1c13(0x18c)})});const _0x4dc118=isInProject(),_0x3686dc=_0x4dc118?projectConfigPath:globalConfigPath;let _0x4a5493={};try{if(existsSync(_0x3686dc)){const _0x453755=readFileSync(_0x3686dc,{'encoding':_0x3e1c13(0x1ad)});_0x453755&&(_0x4a5493=JSON[_0x3e1c13(0x19d)](_0x453755));}}catch(_0x3de8ed){}if(typeof _0x455c1d!=='string'||_0x455c1d[_0x3e1c13(0x1b3)]>0x1f4)return a39_0x12bef6(Box,{'children':a39_0x12bef6(Text,{'color':_0x3e1c13(0x1ab),'children':_0x3e1c13(0x197)})});let _0x14a112=_0x106911;_0x106911==='app'&&(_0x14a112=_0x3e1c13(0x18d),delete _0x4a5493[_0x3e1c13(0x190)]);_0x106911==='appcode'&&delete _0x4a5493[_0x3e1c13(0x190)];_0x4a5493[_0x14a112]=_0x455c1d;try{const _0x2d51fb=a39_0x154508['dirname'](_0x3686dc);!existsSync(_0x2d51fb)&&a39_0x2f6331[_0x3e1c13(0x1ac)](_0x2d51fb,{'recursive':!![]});const _0x117427=_0x3686dc+_0x3e1c13(0x193);writeFileSync(_0x117427,JSON[_0x3e1c13(0x1a6)](_0x4a5493,null,0x2),{'encoding':'utf8','mode':0x180}),a39_0x2f6331[_0x3e1c13(0x195)](_0x117427,_0x3686dc);if(_0x106911===_0x3e1c13(0x18f)){const _0x4161f7=_0x4dc118?'项目':'全局';console[_0x3e1c13(0x19a)]('✓\x20'+_0x4161f7+_0x3e1c13(0x19f)+_0x455c1d);}}catch(_0x2a9573){const _0x2b6b7d=_0x3686dc+_0x3e1c13(0x193);try{existsSync(_0x2b6b7d)&&a39_0x2f6331[_0x3e1c13(0x199)](_0x2b6b7d);}catch(_0x1469ee){}return logger[_0x3e1c13(0x1b1)](_0x3e1c13(0x1b2),_0x3e1c13(0x18b),{'error':_0x2a9573 instanceof Error?_0x2a9573[_0x3e1c13(0x1b5)]:String(_0x2a9573),'configKey':_0x106911,'configValue':_0x455c1d,'targetConfigPath':_0x3686dc}),a39_0x12bef6(Box,{'children':a39_0x1de45f(Text,{'color':_0x3e1c13(0x1ab),'children':[_0x3e1c13(0x19b),_0x2a9573 instanceof Error?_0x2a9573['message']:String(_0x2a9573)]})});}return null;}return a39_0x12bef6(Box,{'children':a39_0x12bef6(Text,{'color':_0x3e1c13(0x1ab),'children':_0x3e1c13(0x1af)})});}}if(_0xa106a9===_0x3e1c13(0x19c)){if(_0x106911){let _0x1e966f=_0x106911;return _0x106911===_0x3e1c13(0x190)&&(_0x1e966f=_0x3e1c13(0x18d)),console[_0x3e1c13(0x19a)](_0xc591db[_0x1e966f]||_0x3e1c13(0x1a0)),null;}return null;}if(_0xa106a9===_0x3e1c13(0x1a8))return console[_0x3e1c13(0x19a)](JSON[_0x3e1c13(0x1a6)](_0xc591db,null,0x2)),null;if(!_0x2c3aff||!_0x74c9fd)return a39_0x12bef6(ConfigHelp,{});return null;}
|
package/lib/constant/domain.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a40_0x4983(){const _0x5cc8d5=['39554NvCknw','2375616ModaQr','https://api.lovrabet.com','https://daily-api.lovrabet.com','330FtFoUI','1531458DAovvc','8478BBduAJ','https://user-daily.lovrabet.com','85130mXietR','https://user.lovrabet.com','42ABFHIY','online','8XpBGli','81529sWKgTq','75sutemv','130110eRfXbp','44ljVHFq'];a40_0x4983=function(){return _0x5cc8d5;};return a40_0x4983();}const a40_0x31bac8=a40_0x347d;function a40_0x347d(_0x2f8726,_0x539c11){_0x2f8726=_0x2f8726-0x99;const _0x498334=a40_0x4983();let _0x347d11=_0x498334[_0x2f8726];return _0x347d11;}(function(_0x5c567e,_0x3ccad0){const _0x576037=a40_0x347d,_0x3d5a68=_0x5c567e();while(!![]){try{const _0x416609=-parseInt(_0x576037(0xa0))/0x1+-parseInt(_0x576037(0xa6))/0x2*(-parseInt(_0x576037(0x9d))/0x3)+parseInt(_0x576037(0x9f))/0x4*(parseInt(_0x576037(0x9e))/0x5)+parseInt(_0x576037(0x99))/0x6*(parseInt(_0x576037(0x9c))/0x7)+-parseInt(_0x576037(0x9b))/0x8*(parseInt(_0x576037(0xa5))/0x9)+-parseInt(_0x576037(0xa8))/0xa*(parseInt(_0x576037(0xa4))/0xb)+parseInt(_0x576037(0xa1))/0xc;if(_0x416609===_0x3ccad0)break;else _0x3d5a68['push'](_0x3d5a68['shift']());}catch(_0x48d2ab){_0x3d5a68['push'](_0x3d5a68['shift']());}}}(a40_0x4983,0x32710));import{getEnv}from'./env.js';export const getUserDomain=()=>getEnv()===a40_0x31bac8(0x9a)?a40_0x31bac8(0xa9):a40_0x31bac8(0xa7);export const getApiDomain=()=>getEnv()===a40_0x31bac8(0x9a)?a40_0x31bac8(0xa2):a40_0x31bac8(0xa3);
|
package/lib/constant/env.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a41_0x49dbac=a41_0x4e6c;function a41_0x55c1(){const _0x253ee7=['388lNNvuA','464583LJdsDu','11685990qaRtvM','1876330MUVoHQ','4939CVynfA','env','356902VwecBD','8tBYZIE','12UcqrcN','LOVRABET_ENV','5485632EYBjgn','4025790qATYxj'];a41_0x55c1=function(){return _0x253ee7;};return a41_0x55c1();}(function(_0x393271,_0x335f19){const _0x1ea3b=a41_0x4e6c,_0xfb3014=_0x393271();while(!![]){try{const _0x1560a6=-parseInt(_0x1ea3b(0x101))/0x1*(parseInt(_0x1ea3b(0xfd))/0x2)+parseInt(_0x1ea3b(0xfe))/0x3*(-parseInt(_0x1ea3b(0x105))/0x4)+parseInt(_0x1ea3b(0x100))/0x5+parseInt(_0x1ea3b(0xfb))/0x6+-parseInt(_0x1ea3b(0x103))/0x7+parseInt(_0x1ea3b(0x104))/0x8*(-parseInt(_0x1ea3b(0xfc))/0x9)+parseInt(_0x1ea3b(0xff))/0xa;if(_0x1560a6===_0x335f19)break;else _0xfb3014['push'](_0xfb3014['shift']());}catch(_0x35daa2){_0xfb3014['push'](_0xfb3014['shift']());}}}(a41_0x55c1,0x83204));let env=process[a41_0x49dbac(0x102)][a41_0x49dbac(0x106)]||'online';export function getEnv(){return env;}function a41_0x4e6c(_0x44d1f2,_0x3d455c){_0x44d1f2=_0x44d1f2-0xfb;const _0x55c1d0=a41_0x55c1();let _0x4e6c8e=_0x55c1d0[_0x44d1f2];return _0x4e6c8e;}export function initEnv(_0x527379){env=_0x527379;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a42_0x165fe3=a42_0x2381;(function(_0x382644,_0x2b05fd){const _0x1c8410=a42_0x2381,_0xeca4fe=_0x382644();while(!![]){try{const _0x3999b2=-parseInt(_0x1c8410(0xee))/0x1+-parseInt(_0x1c8410(0xb2))/0x2*(-parseInt(_0x1c8410(0x10d))/0x3)+parseInt(_0x1c8410(0xf8))/0x4*(parseInt(_0x1c8410(0xbf))/0x5)+-parseInt(_0x1c8410(0xf5))/0x6*(-parseInt(_0x1c8410(0xb5))/0x7)+-parseInt(_0x1c8410(0xe9))/0x8*(-parseInt(_0x1c8410(0x10c))/0x9)+parseInt(_0x1c8410(0xb9))/0xa+parseInt(_0x1c8410(0xf4))/0xb*(-parseInt(_0x1c8410(0x10b))/0xc);if(_0x3999b2===_0x2b05fd)break;else _0xeca4fe['push'](_0xeca4fe['shift']());}catch(_0x201ff0){_0xeca4fe['push'](_0xeca4fe['shift']());}}}(a42_0x3047,0x9358c));import{jsx as a42_0x3682b7,jsxs as a42_0x23f7a1,Fragment as a42_0x5793d9}from'react/jsx-runtime';import{useState}from'react';function a42_0x3047(){const _0x189460=['已登录','\x20个\x20IDE','737cfjGrZ','624oIesQC','has','[✓]','21468hTLNbI','red','add','string','rightArrow','项目名长度不能超过\x2050\x20个字符','选择要配置的\x20IDE:','project-name','*\x20项目名:\x20','\x20←\x20','test','confirm-api-pull','Yes','login-check','请至少选择一个\x20IDE','cursor','cwd','login-process','env','332328lIBwhi','1819341odSbtz','3nKoXok','登录失败','gray','未设置','green','MCP\x20和\x20Skill','绑定应用AppCode可自动配置\x20API,如:\x20app-c4c89304\x20(直接回车跳过)','login','\x20登录中...','*\x20创建新项目','1248178LxPpES','filter','slice','78477vHeRVg','agent','qoder','√\x20检测到有效登录状态','11516310EVnkPj','blue','online','项目名只能以字母或数字开头,且只包含字母、数字、-\x20和\x20_','\x20\x20使用\x20←→\x20选择,回车确认','value','335XKzMZX','yellow','app-code','backspace','\x22\x20已存在,请使用其他名称','white','my-app','\x20\x20推荐选择\x20Yes,可自动配置\x20API\x20接口','upArrow','creating','\x20+MCP','↑/↓:\x20移动\x20空格:\x20切换\x20a:\x20全选\x20i/r:\x20反选\x20Enter:\x20确认','codex','\x20直接回车确认,或输入自定义名称','\x22\x20已存在','trim','*\x20是否配置\x20Lovrabet\x20MCP\x20和\x20Skill?','lovrabet-setup','跳过登录','trae','应用AppCode只能包含字母、数字、连字符和下划线,且必须以字母或数字开头','codebuddy','resolve','[可选]:\x20','应用AppCode','opencode','*\x20正在创建项目...','map','*\x20是否要先登录以便拉取\x20API\x20配置?','应用AppCode不合法','*\x20正在检查登录状态...','目录\x20\x22','lovrabet-setup-selection','!\x20未检测到有效登录','includes','return','*\x20正在登录,请前往浏览器完成登录...','claude','项目名不合法','login-prompt','登录状态','windsurf','8FMyIcz','[\x20]','leftArrow','step','delete','1044372QmeepO','length','cyan','项目名'];a42_0x3047=function(){return _0x189460;};return a42_0x3047();}function a42_0x2381(_0x3081fe,_0xe1135b){_0x3081fe=_0x3081fe-0xb1;const _0x304723=a42_0x3047();let _0x23813a=_0x304723[_0x3081fe];return _0x23813a;}import{Text,Box,useInput}from'ink';import{existsSync}from'node:fs';import a42_0x4a1ebb from'node:path';import{getIsSessionValid}from'../auth/is-session-valid.js';import{authServer}from'../auth/auth-server.js';import{readConfig}from'../utils/config.js';import{IDE_CONFIGS,MCP_IDES}from'../utils/ai_config.js';const UI_IDE_CONFIGS=IDE_CONFIGS,UI_IDE_LIST=['antigravity',a42_0x165fe3(0xe4),'cline',a42_0x165fe3(0xd4),a42_0x165fe3(0xcb),a42_0x165fe3(0x107),a42_0x165fe3(0xd8),a42_0x165fe3(0xb7),a42_0x165fe3(0xd2),a42_0x165fe3(0xe8),a42_0x165fe3(0xb6)],UI_MCP_IDES=new Set(Array['from'](MCP_IDES));export function EnhancedGuidedCreate(_0x5c9ff7){const _0x20da98=a42_0x165fe3,{onCreate:_0x21f893,env:_0x36e3ee}=_0x5c9ff7,[_0x2746bd,_0x53dfbb]=useState(_0x20da98(0xff)),[_0x1924ec,_0x798d72]=useState(''),[_0x211aeb,_0x2ce83c]=useState(''),[_0xae2c3c,_0x51779f]=useState(''),[_0x3fd234,_0x195a5d]=useState(''),[_0x561bd9,_0x79d5f7]=useState([]),[_0x31bccb,_0x295c0b]=useState(null),[_0x1cc6b8,_0x3d476b]=useState(![]),[_0x1884a0,_0x2992d3]=useState(![]),[_0x299daa,_0x1ba3bb]=useState(![]),[_0xf09981,_0x794a99]=useState(0x0),[_0x24404d,_0x32ac13]=useState(0x0),[_0x231d9d,_0x5a4cc2]=useState(0x0),[_0x41039f,_0x16933d]=useState(![]),[_0x17cf5f,_0xf6608c]=useState(new Set()),[_0x99a01c,_0x394f29]=useState(0x0),[_0x5e7305,_0x30cfba]=useState(''),_0x706c3d=_0x20da98(0xc5),_0x264d9b=readConfig(),_0x295c16=typeof _0x264d9b['env']===_0x20da98(0xfb)?_0x264d9b[_0x20da98(0x10a)]:undefined;function _0x492d45(_0x27f7d4){const _0x44f35c=_0x20da98,_0x4071b2=_0x27f7d4||_0x706c3d,_0x66d4ad=a42_0x4a1ebb[_0x44f35c(0xd5)](process[_0x44f35c(0x108)](),_0x4071b2);return existsSync(_0x66d4ad);}function _0x2e6514(_0x5e1c53){const _0x2b7ed3=_0x20da98;if(_0x5e1c53['length']>0x32)return{'valid':![],'message':_0x2b7ed3(0xfd)};const _0x35fe5e=/^[A-Za-z0-9][A-Za-z0-9_-]*$/;if(_0x5e1c53?.[_0x2b7ed3(0xce)]()&&!_0x35fe5e['test'](_0x5e1c53))return{'valid':![],'message':_0x2b7ed3(0xbc)};return{'valid':!![]};}function _0x73d8df(_0x2d553d){const _0x20fea5=_0x20da98;if(!_0x2d553d['trim']())return{'valid':!![]};if(_0x2d553d[_0x20fea5(0xef)]>0x64)return{'valid':![],'message':'应用AppCode长度不能超过\x20100\x20个字符'};const _0x355ed4=/^[a-zA-Z0-9][a-zA-Z0-9_-]*$/;if(!_0x355ed4[_0x20fea5(0x102)](_0x2d553d))return{'valid':![],'message':_0x20fea5(0xd3)};return{'valid':!![]};}async function _0x2c91fa(){_0x3d476b(!![]);try{const _0x5e2878=await getIsSessionValid();return _0x295c0b(_0x5e2878),_0x5e2878;}catch(_0x2e38ce){return _0x295c0b(![]),![];}finally{_0x3d476b(![]);}}async function _0xdeb939(){_0x2992d3(!![]);try{const _0x46b740=await authServer({'silent':!![]});return _0x295c0b(_0x46b740),_0x46b740;}catch(_0x5b763d){return _0x295c0b(![]),![];}finally{_0x2992d3(![]);}}return useInput(async(_0x51862e,_0x27075d)=>{const _0x2d7ab5=_0x20da98;if(_0x27075d[_0x2d7ab5(0xeb)]||_0x27075d[_0x2d7ab5(0xfc)]){if(_0x2746bd==='confirm-api-pull'){_0x794a99(_0x52016f=>_0x52016f===0x0?0x1:0x0);return;}if(_0x2746bd===_0x2d7ab5(0xdf)){if(!_0x41039f){_0x5a4cc2(_0xe9add9=>_0xe9add9===0x0?0x1:0x0);return;}_0x16933d(![]);return;}if(_0x2746bd==='login-prompt'){_0x32ac13(_0x31db40=>_0x31db40===0x0?0x1:0x0);return;}}if(_0x2746bd===_0x2d7ab5(0xdf)&&_0x41039f&&_0x231d9d===0x0){if(_0x27075d[_0x2d7ab5(0xc7)]){_0x394f29(_0x3f18a8=>_0x3f18a8>0x0?_0x3f18a8-0x1:UI_IDE_LIST[_0x2d7ab5(0xef)]-0x1);return;}if(_0x27075d['downArrow']){_0x394f29(_0x573048=>_0x573048<UI_IDE_LIST[_0x2d7ab5(0xef)]-0x1?_0x573048+0x1:0x0);return;}}if(_0x51862e==='\x20'&&_0x2746bd===_0x2d7ab5(0xdf)&&_0x41039f&&_0x231d9d===0x0){_0xf6608c(_0x4a555b=>{const _0x53e2aa=_0x2d7ab5,_0x45916c=new Set(_0x4a555b);return _0x45916c[_0x53e2aa(0xf6)](_0x99a01c)?_0x45916c[_0x53e2aa(0xed)](_0x99a01c):_0x45916c[_0x53e2aa(0xfa)](_0x99a01c),_0x45916c;}),_0x195a5d('');return;}if((_0x51862e==='a'||_0x51862e==='A')&&_0x2746bd===_0x2d7ab5(0xdf)&&_0x41039f&&_0x231d9d===0x0){_0xf6608c(new Set(UI_IDE_LIST[_0x2d7ab5(0xda)]((_0x38f94d,_0x2c4826)=>_0x2c4826))),_0x195a5d('');return;}if((_0x51862e==='i'||_0x51862e==='I'||_0x51862e==='r'||_0x51862e==='R')&&_0x2746bd===_0x2d7ab5(0xdf)&&_0x41039f&&_0x231d9d===0x0){_0xf6608c(_0x5313eb=>{const _0x229909=_0x2d7ab5,_0x55a5b5=new Set();for(let _0x137d85=0x0;_0x137d85<UI_IDE_LIST[_0x229909(0xef)];_0x137d85++){!_0x5313eb['has'](_0x137d85)&&_0x55a5b5[_0x229909(0xfa)](_0x137d85);}return _0x55a5b5;});return;}if(_0x27075d[_0x2d7ab5(0xe2)]){if(_0x2746bd===_0x2d7ab5(0xff)){const _0x2979e2=_0xae2c3c[_0x2d7ab5(0xce)]()||_0x706c3d;if(_0x3fd234)return;if(_0x492d45(_0x2979e2)){_0x30cfba('目录\x20\x22'+_0x2979e2+_0x2d7ab5(0xc3));return;}_0x798d72(_0x2979e2),_0x79d5f7([{'step':_0x2d7ab5(0xff),'label':_0x2d7ab5(0xf1),'value':_0x2979e2}]),_0x51779f(''),_0x195a5d(''),_0x30cfba(''),_0x53dfbb(_0x2d7ab5(0xc1));return;}if(_0x2746bd===_0x2d7ab5(0xc1)){if(_0x3fd234)return;const _0x4ae068=_0xae2c3c[_0x2d7ab5(0xce)]();_0x2ce83c(_0x4ae068),_0x79d5f7(_0x5e5ca9=>[..._0x5e5ca9,{'step':_0x2d7ab5(0xc1),'label':_0x2d7ab5(0xd7),'value':_0x4ae068||_0x2d7ab5(0x110)}]),_0x51779f(''),_0x195a5d('');if(_0x4ae068){_0x53dfbb(_0x2d7ab5(0x105));const _0x390739=await _0x2c91fa();_0x390739?_0x53dfbb(_0x2d7ab5(0x103)):_0x53dfbb(_0x2d7ab5(0xe6));}else{const _0x32d468=_0x36e3ee||_0x295c16||'online';_0x21f893({'projectName':_0x1924ec,'appCode':undefined,'pullApi':![],'aiSetup':![],'selectedIDEs':[],'env':_0x32d468}),_0x53dfbb(_0x2d7ab5(0xc8));}return;}if(_0x2746bd===_0x2d7ab5(0x103)){const _0x459e9f=_0xf09981===0x0;_0x1ba3bb(_0x459e9f),_0x79d5f7(_0x4ed7bb=>[..._0x4ed7bb,{'step':'api-pull','label':'拉取API配置','value':_0x459e9f?'是':'否'}]),_0x53dfbb(_0x2d7ab5(0xdf));return;}if(_0x2746bd===_0x2d7ab5(0xdf)){if(!_0x41039f){_0x16933d(!![]);if(_0x231d9d===0x1){_0x79d5f7(_0x33e8cc=>[..._0x33e8cc,{'step':_0x2d7ab5(0xd0),'label':_0x2d7ab5(0x112),'value':'否'}]);const _0x341ca0=_0x36e3ee||_0x295c16||_0x2d7ab5(0xbb);_0x21f893({'projectName':_0x1924ec,'appCode':_0x211aeb,'pullApi':_0x299daa,'aiSetup':![],'selectedIDEs':[],'env':_0x341ca0}),_0x53dfbb(_0x2d7ab5(0xc8));}return;}if(_0x17cf5f['size']===0x0){_0x195a5d(_0x2d7ab5(0x106));return;}const _0x182b2c=Array['from'](_0x17cf5f)[_0x2d7ab5(0xda)](_0x47094c=>UI_IDE_LIST[_0x47094c])[_0x2d7ab5(0xb3)](_0x1a5265=>_0x1a5265!==undefined);_0x79d5f7(_0x544893=>[..._0x544893,{'step':_0x2d7ab5(0xd0),'label':'MCP\x20和\x20Skill','value':_0x182b2c[_0x2d7ab5(0xef)]+_0x2d7ab5(0xf3)}]);const _0xf256d4=_0x36e3ee||_0x295c16||_0x2d7ab5(0xbb);_0x21f893({'projectName':_0x1924ec,'appCode':_0x211aeb,'pullApi':_0x299daa,'aiSetup':!![],'selectedIDEs':_0x182b2c,'env':_0xf256d4}),_0x53dfbb(_0x2d7ab5(0xc8));return;}if(_0x2746bd===_0x2d7ab5(0xe6)){const _0x433440=_0x24404d===0x0;if(_0x433440){_0x53dfbb(_0x2d7ab5(0x109));const _0x1dfdff=await _0xdeb939();_0x1dfdff?(_0x79d5f7(_0x4cf550=>[..._0x4cf550,{'step':_0x2d7ab5(0x114),'label':'登录状态','value':_0x2d7ab5(0xf2)}]),_0x53dfbb(_0x2d7ab5(0x103))):(_0x79d5f7(_0x423420=>[..._0x423420,{'step':_0x2d7ab5(0x114),'label':_0x2d7ab5(0xe7),'value':_0x2d7ab5(0x10e)}]),_0x53dfbb(_0x2d7ab5(0xdf)));}else _0x79d5f7(_0x216d3d=>[..._0x216d3d,{'step':_0x2d7ab5(0x114),'label':_0x2d7ab5(0xe7),'value':_0x2d7ab5(0xd1)}]),_0x53dfbb(_0x2d7ab5(0xdf));return;}}if(_0x27075d[_0x2d7ab5(0xc2)]||_0x27075d[_0x2d7ab5(0xed)]){_0x51779f(_0x2871d0=>{const _0x4ab00d=_0x2d7ab5,_0x14c78f=_0x2871d0[_0x4ab00d(0xb4)](0x0,-0x1);if(_0x2746bd===_0x4ab00d(0xff)){const {valid:_0x5e2c66,message:_0x13ba0c}=_0x2e6514(_0x14c78f);_0x195a5d(_0x5e2c66?'':_0x13ba0c||'项目名不合法');if(_0x5e2c66&&!_0x3fd234){const _0x23f486=_0x14c78f||_0x706c3d;_0x492d45(_0x23f486)?_0x30cfba(_0x4ab00d(0xde)+_0x23f486+'\x22\x20已存在'):_0x30cfba('');}}else{if(_0x2746bd==='app-code'){const {valid:_0x4c6cc4,message:_0x18446d}=_0x73d8df(_0x14c78f);_0x195a5d(_0x4c6cc4?'':_0x18446d||_0x4ab00d(0xdc));}}return _0x14c78f;});return;}if([_0x2d7ab5(0xc8),_0x2d7ab5(0x105),_0x2d7ab5(0x109)][_0x2d7ab5(0xe1)](_0x2746bd))return;if(_0x2746bd==='confirm-api-pull'||_0x2746bd===_0x2d7ab5(0xe6)||_0x2746bd===_0x2d7ab5(0xdf))return;_0x51779f(_0xf5b34d=>{const _0x478d8a=_0x2d7ab5,_0x140ed9=_0xf5b34d+_0x51862e;if(_0x2746bd===_0x478d8a(0xff)){const {valid:_0xfaae5a,message:_0x3807e7}=_0x2e6514(_0x140ed9);_0x195a5d(_0xfaae5a?'':_0x3807e7||_0x478d8a(0xe5));if(_0xfaae5a&&!_0x3fd234){const _0x24f36e=_0x140ed9||_0x706c3d;_0x492d45(_0x24f36e)?_0x30cfba(_0x478d8a(0xde)+_0x24f36e+_0x478d8a(0xcd)):_0x30cfba('');}}else{if(_0x2746bd===_0x478d8a(0xc1)){const {valid:_0x28da00,message:_0x145d50}=_0x73d8df(_0x140ed9);_0x195a5d(_0x28da00?'':_0x145d50||_0x478d8a(0xdc));}}return _0x140ed9;});}),a42_0x23f7a1(Box,{'flexDirection':'column','marginTop':0x1,'children':[_0x561bd9[_0x20da98(0xef)]===0x0&&a42_0x3682b7(Box,{'children':a42_0x3682b7(Text,{'color':_0x20da98(0xf0),'children':_0x20da98(0xb1)})}),_0x561bd9['map'](_0x4dbbbf=>a42_0x23f7a1(Box,{'children':[a42_0x23f7a1(Text,{'color':'green','children':['√\x20',_0x4dbbbf['label'],':\x20']}),a42_0x3682b7(Text,{'color':'cyan','children':_0x4dbbbf[_0x20da98(0xbe)]})]},_0x4dbbbf[_0x20da98(0xec)])),_0x2746bd===_0x20da98(0xff)&&a42_0x23f7a1(a42_0x5793d9,{'children':[a42_0x23f7a1(Box,{'children':[a42_0x3682b7(Text,{'children':_0x20da98(0x100)}),_0xae2c3c?a42_0x3682b7(Text,{'color':_0x20da98(0x111),'children':_0xae2c3c}):a42_0x3682b7(Text,{'color':_0x20da98(0x10f),'children':_0x706c3d}),_0x3fd234&&a42_0x23f7a1(Text,{'color':_0x20da98(0xf9),'children':[_0x20da98(0x101),_0x3fd234]}),_0x5e7305&&a42_0x23f7a1(Text,{'color':'red','children':['\x20←\x20',_0x5e7305]})]}),!_0x3fd234&&!_0x5e7305&&!_0xae2c3c&&a42_0x3682b7(Box,{'children':a42_0x3682b7(Text,{'color':_0x20da98(0x10f),'children':_0x20da98(0xcc)})})]}),_0x2746bd===_0x20da98(0xc1)&&a42_0x23f7a1(a42_0x5793d9,{'children':[a42_0x23f7a1(Box,{'children':[a42_0x3682b7(Text,{'children':'*\x20应用AppCode\x20'}),a42_0x3682b7(Text,{'color':_0x20da98(0x10f),'children':_0x20da98(0xd6)}),a42_0x3682b7(Text,{'color':_0x20da98(0x111),'children':_0xae2c3c}),_0x3fd234&&a42_0x23f7a1(Text,{'color':_0x20da98(0xf9),'children':[_0x20da98(0x101),_0x3fd234]})]}),!_0x3fd234&&a42_0x3682b7(Box,{'children':a42_0x23f7a1(Text,{'color':_0x20da98(0x10f),'children':['\x20',_0x20da98(0x113)]})})]}),_0x2746bd==='login-check'&&a42_0x23f7a1(Box,{'children':[a42_0x3682b7(Text,{'children':_0x20da98(0xdd)}),_0x1cc6b8&&a42_0x3682b7(Text,{'color':_0x20da98(0x10f),'children':'\x20检查中...'})]}),_0x2746bd===_0x20da98(0x103)&&a42_0x23f7a1(a42_0x5793d9,{'children':[a42_0x3682b7(Box,{'children':a42_0x3682b7(Text,{'color':_0x20da98(0x111),'children':_0x20da98(0xb8)})}),a42_0x3682b7(Box,{'marginTop':0x1,'children':a42_0x3682b7(Text,{'children':'*\x20是否要自动拉取\x20API\x20配置?'})}),a42_0x23f7a1(Box,{'marginLeft':0x2,'children':[a42_0x23f7a1(Text,{'color':_0xf09981===0x0?_0x20da98(0x111):_0x20da98(0x10f),'children':[_0xf09981===0x0?'▶\x20':'\x20\x20',_0x20da98(0x104)]}),a42_0x3682b7(Text,{'children':'\x20'}),a42_0x23f7a1(Text,{'color':_0xf09981===0x1?_0x20da98(0x111):_0x20da98(0x10f),'children':[_0xf09981===0x1?'▶\x20':'\x20\x20','No']})]}),a42_0x3682b7(Box,{'children':a42_0x3682b7(Text,{'color':_0x20da98(0x10f),'children':_0x20da98(0xbd)})}),a42_0x3682b7(Box,{'children':a42_0x3682b7(Text,{'color':_0x20da98(0xc0),'children':_0x20da98(0xc6)})})]}),_0x2746bd===_0x20da98(0xdf)&&a42_0x23f7a1(a42_0x5793d9,{'children':[a42_0x3682b7(Box,{'children':a42_0x3682b7(Text,{'color':_0x20da98(0x111),'children':'√'})}),a42_0x3682b7(Box,{'marginTop':0x1,'children':a42_0x3682b7(Text,{'children':_0x20da98(0xcf)})}),a42_0x23f7a1(Box,{'marginLeft':0x2,'children':[a42_0x23f7a1(Text,{'color':_0x231d9d===0x0?'green':_0x20da98(0x10f),'children':[_0x231d9d===0x0?'▶\x20':'\x20\x20',_0x20da98(0x104)]}),a42_0x3682b7(Text,{'children':'\x20'}),a42_0x23f7a1(Text,{'color':_0x231d9d===0x1?'green':_0x20da98(0x10f),'children':[_0x231d9d===0x1?'▶\x20':'\x20\x20','No']})]}),_0x41039f&&_0x231d9d===0x0&&a42_0x23f7a1(a42_0x5793d9,{'children':[a42_0x3682b7(Box,{'marginTop':0x1,'children':a42_0x3682b7(Text,{'color':_0x20da98(0x10f),'children':'\x20\x20使用\x20←→\x20返回修改选择,回车确认\x20IDE'})}),a42_0x23f7a1(Box,{'marginTop':0x1,'flexDirection':'column','children':[a42_0x3682b7(Text,{'bold':!![],'color':'yellow','children':_0x20da98(0xfe)}),UI_IDE_LIST['map']((_0x263dba,_0x128c71)=>{const _0xab97e0=_0x20da98,_0x21c8eb=_0x99a01c===_0x128c71,_0x2a5ed8=_0x17cf5f['has'](_0x128c71),_0x6135df=UI_MCP_IDES[_0xab97e0(0xf6)](_0x263dba);return a42_0x3682b7(Box,{'children':a42_0x23f7a1(Text,{'backgroundColor':_0x21c8eb?_0xab97e0(0xba):undefined,'color':_0x21c8eb?'white':undefined,'children':['\x20\x20',_0x2a5ed8?_0xab97e0(0xf7):_0xab97e0(0xea),'\x20',UI_IDE_CONFIGS[_0x263dba]['name'],_0x6135df&&a42_0x3682b7(Text,{'color':_0x21c8eb?'white':_0xab97e0(0xf0),'children':_0xab97e0(0xc9)}),'\x20',a42_0x23f7a1(Text,{'color':_0x21c8eb?_0xab97e0(0xc4):_0xab97e0(0x10f),'dimColor':!_0x21c8eb,'children':['-\x20',UI_IDE_CONFIGS[_0x263dba]['description']]})]})},_0x263dba);}),a42_0x3682b7(Box,{'marginTop':0x1,'children':a42_0x23f7a1(Text,{'color':_0x20da98(0x10f),'children':['\x20',_0x20da98(0xca)]})})]})]}),!_0x41039f&&a42_0x3682b7(Box,{'marginTop':0x1,'children':a42_0x3682b7(Text,{'color':_0x20da98(0x10f),'children':_0x20da98(0xbd)})}),_0x3fd234&&a42_0x3682b7(Box,{'marginTop':0x1,'children':a42_0x23f7a1(Text,{'color':_0x20da98(0xf9),'children':['✗\x20',_0x3fd234]})})]}),_0x2746bd===_0x20da98(0xe6)&&a42_0x23f7a1(a42_0x5793d9,{'children':[a42_0x3682b7(Box,{'children':a42_0x3682b7(Text,{'color':_0x20da98(0xc0),'children':_0x20da98(0xe0)})}),a42_0x3682b7(Box,{'marginTop':0x1,'children':a42_0x3682b7(Text,{'children':_0x20da98(0xdb)})}),a42_0x23f7a1(Box,{'marginLeft':0x2,'children':[a42_0x23f7a1(Text,{'color':_0x24404d===0x0?'green':'gray','children':[_0x24404d===0x0?'▶\x20':'\x20\x20','Yes']}),a42_0x3682b7(Text,{'children':'\x20'}),a42_0x23f7a1(Text,{'color':_0x24404d===0x1?_0x20da98(0x111):_0x20da98(0x10f),'children':[_0x24404d===0x1?'▶\x20':'\x20\x20','No']})]}),a42_0x3682b7(Box,{'children':a42_0x3682b7(Text,{'color':_0x20da98(0x10f),'children':_0x20da98(0xbd)})})]}),_0x2746bd===_0x20da98(0x109)&&a42_0x23f7a1(Box,{'children':[a42_0x3682b7(Text,{'children':_0x20da98(0xe3)}),_0x1884a0&&a42_0x3682b7(Text,{'color':_0x20da98(0x10f),'children':_0x20da98(0x115)})]}),_0x2746bd==='creating'&&a42_0x3682b7(Box,{'children':a42_0x3682b7(Text,{'color':_0x20da98(0x111),'children':_0x20da98(0xd9)})})]});}
|
|
1
|
+
const a42_0x5423e9=a42_0x1814;(function(_0x37b59f,_0x171d97){const _0x2f42d7=a42_0x1814,_0x5585f0=_0x37b59f();while(!![]){try{const _0x4856bf=parseInt(_0x2f42d7(0x1bf))/0x1+-parseInt(_0x2f42d7(0x189))/0x2*(parseInt(_0x2f42d7(0x1d2))/0x3)+parseInt(_0x2f42d7(0x191))/0x4+parseInt(_0x2f42d7(0x1ad))/0x5*(-parseInt(_0x2f42d7(0x1d3))/0x6)+-parseInt(_0x2f42d7(0x1e0))/0x7+-parseInt(_0x2f42d7(0x1ca))/0x8+parseInt(_0x2f42d7(0x1c0))/0x9;if(_0x4856bf===_0x171d97)break;else _0x5585f0['push'](_0x5585f0['shift']());}catch(_0x1b4c06){_0x5585f0['push'](_0x5585f0['shift']());}}}(a42_0x110e,0x428f5));import{jsx as a42_0x39a007,jsxs as a42_0x106683,Fragment as a42_0x38992f}from'react/jsx-runtime';import{useState}from'react';import{Text,Box,useInput}from'ink';function a42_0x110e(){const _0x339c40=['应用AppCode不合法','*\x20是否要自动拉取\x20API\x20配置?','filter','lovrabet-setup','trim','cursor','add','leftArrow','gray','1716896yGQPza','login-prompt','test','项目名长度不能超过\x2050\x20个字符','应用AppCode只能包含字母、数字、连字符和下划线,且必须以字母或数字开头','project-name','from','green','3jpxJDP','22482VbgOMS','*\x20创建新项目','应用AppCode长度不能超过\x20100\x20个字符','cwd','跳过登录','[\x20]','slice','blue','my-app','value','opencode','\x20←\x20','登录失败','650979bficnO','*\x20是否要先登录以便拉取\x20API\x20配置?','\x22\x20已存在,请使用其他名称','description','online','codebuddy','login','*\x20正在检查登录状态...','↑/↓:\x20移动\x20空格:\x20切换\x20a:\x20全选\x20i/r:\x20反选\x20Enter:\x20确认','*\x20是否配置\x20Lovrabet\x20MCP\x20和\x20Skill?','1056722rXGIQU','env','[✓]','login-process','codex','绑定应用AppCode可自动配置\x20API,如:\x20app-c4c89304\x20(直接回车跳过)','登录状态','length','177584HTuNLr','*\x20应用AppCode\x20','MCP\x20和\x20Skill','cyan','\x20\x20使用\x20←→\x20选择,回车确认','confirm-api-pull','red','app-code','*\x20项目名:\x20','has','选择要配置的\x20IDE:','backspace','项目名只能以字母或数字开头,且只包含字母、数字、-\x20和\x20_','antigravity','agent','api-pull','delete','\x22\x20已存在','login-check','rightArrow','creating','*\x20正在登录,请前往浏览器完成登录...','已登录','\x20\x20推荐选择\x20Yes,可自动配置\x20API\x20接口','\x20检查中...','!\x20未检测到有效登录','windsurf','lovrabet-setup-selection','460bOiQss','downArrow','[可选]:\x20','*\x20正在创建项目...','includes','yellow','string','目录\x20\x22','upArrow','map','请至少选择一个\x20IDE','Yes','claude','column','\x20+MCP','拉取API配置','resolve','white','39472rXVGaW','12325095xXDopt'];a42_0x110e=function(){return _0x339c40;};return a42_0x110e();}import{existsSync}from'node:fs';import a42_0x17034e from'node:path';import{getIsSessionValid}from'../auth/is-session-valid.js';import{authServer}from'../auth/auth-server.js';function a42_0x1814(_0x3b4ba5,_0x4893aa){_0x3b4ba5=_0x3b4ba5-0x181;const _0x110eec=a42_0x110e();let _0x18149c=_0x110eec[_0x3b4ba5];return _0x18149c;}import{readConfig}from'../utils/config.js';import{IDE_CONFIGS,MCP_IDES}from'../utils/ai_config.js';const UI_IDE_CONFIGS=IDE_CONFIGS,UI_IDE_LIST=[a42_0x5423e9(0x19e),a42_0x5423e9(0x1b9),'cline',a42_0x5423e9(0x184),a42_0x5423e9(0x18d),a42_0x5423e9(0x1c6),a42_0x5423e9(0x1dd),'qoder','trae',a42_0x5423e9(0x1ab),a42_0x5423e9(0x19f)],UI_MCP_IDES=new Set(Array[a42_0x5423e9(0x1d0)](MCP_IDES));export function EnhancedGuidedCreate(_0x540ceb){const _0x12b557=a42_0x5423e9,{onCreate:_0x951e1e,env:_0x50dcbd}=_0x540ceb,[_0x2a8a9b,_0x5d3d98]=useState('project-name'),[_0x4f7273,_0x2e880a]=useState(''),[_0x291920,_0x360dd5]=useState(''),[_0x437744,_0x91b738]=useState(''),[_0x3a327a,_0x5dec5f]=useState(''),[_0x361e83,_0x5dcc3a]=useState([]),[_0x27d580,_0x2ffe87]=useState(null),[_0x1a547d,_0x37443b]=useState(![]),[_0x319e0a,_0x57c83b]=useState(![]),[_0x14bd3a,_0x5261f5]=useState(![]),[_0x3e121d,_0x57f607]=useState(0x0),[_0x396b7b,_0x18e727]=useState(0x0),[_0x48ce36,_0x3396f4]=useState(0x0),[_0x132f79,_0x55ac2b]=useState(![]),[_0x39d907,_0x4b7864]=useState(new Set()),[_0x5bf870,_0x23cfd4]=useState(0x0),[_0x5046a7,_0x5976ff]=useState(''),_0x2947ea=_0x12b557(0x1db),_0x5cfa10=readConfig(),_0x1f73d9=typeof _0x5cfa10[_0x12b557(0x18a)]===_0x12b557(0x1b3)?_0x5cfa10[_0x12b557(0x18a)]:undefined;function _0xe4a9de(_0xf6b8d0){const _0xa67f7e=_0x12b557,_0x3acd69=_0xf6b8d0||_0x2947ea,_0x49f24f=a42_0x17034e[_0xa67f7e(0x1bd)](process[_0xa67f7e(0x1d6)](),_0x3acd69);return existsSync(_0x49f24f);}function _0x535b00(_0x450af7){const _0x4e5d9f=_0x12b557;if(_0x450af7[_0x4e5d9f(0x190)]>0x32)return{'valid':![],'message':_0x4e5d9f(0x1cd)};const _0x26d28b=/^[A-Za-z0-9][A-Za-z0-9_-]*$/;if(_0x450af7?.[_0x4e5d9f(0x1c5)]()&&!_0x26d28b[_0x4e5d9f(0x1cc)](_0x450af7))return{'valid':![],'message':_0x4e5d9f(0x19d)};return{'valid':!![]};}function _0x1c0e58(_0x280be7){const _0x5e9b02=_0x12b557;if(!_0x280be7['trim']())return{'valid':!![]};if(_0x280be7[_0x5e9b02(0x190)]>0x64)return{'valid':![],'message':_0x5e9b02(0x1d5)};const _0x20022e=/^[a-zA-Z0-9][a-zA-Z0-9_-]*$/;if(!_0x20022e[_0x5e9b02(0x1cc)](_0x280be7))return{'valid':![],'message':_0x5e9b02(0x1ce)};return{'valid':!![]};}async function _0x2829fe(){_0x37443b(!![]);try{const _0xb1e03f=await getIsSessionValid();return _0x2ffe87(_0xb1e03f),_0xb1e03f;}catch(_0x5c9dee){return _0x2ffe87(![]),![];}finally{_0x37443b(![]);}}async function _0x36f8e2(){_0x57c83b(!![]);try{const _0x46c183=await authServer({'silent':!![]});return _0x2ffe87(_0x46c183),_0x46c183;}catch(_0x37cdd5){return _0x2ffe87(![]),![];}finally{_0x57c83b(![]);}}return useInput(async(_0x3ca42d,_0x18b796)=>{const _0x2bea9e=_0x12b557;if(_0x18b796[_0x2bea9e(0x1c8)]||_0x18b796[_0x2bea9e(0x1a4)]){if(_0x2a8a9b===_0x2bea9e(0x196)){_0x57f607(_0x2f0429=>_0x2f0429===0x0?0x1:0x0);return;}if(_0x2a8a9b==='lovrabet-setup-selection'){if(!_0x132f79){_0x3396f4(_0x217c55=>_0x217c55===0x0?0x1:0x0);return;}_0x55ac2b(![]);return;}if(_0x2a8a9b===_0x2bea9e(0x1cb)){_0x18e727(_0x398561=>_0x398561===0x0?0x1:0x0);return;}}if(_0x2a8a9b===_0x2bea9e(0x1ac)&&_0x132f79&&_0x48ce36===0x0){if(_0x18b796[_0x2bea9e(0x1b5)]){_0x23cfd4(_0x5ed403=>_0x5ed403>0x0?_0x5ed403-0x1:UI_IDE_LIST['length']-0x1);return;}if(_0x18b796[_0x2bea9e(0x1ae)]){_0x23cfd4(_0x5f0956=>_0x5f0956<UI_IDE_LIST[_0x2bea9e(0x190)]-0x1?_0x5f0956+0x1:0x0);return;}}if(_0x3ca42d==='\x20'&&_0x2a8a9b===_0x2bea9e(0x1ac)&&_0x132f79&&_0x48ce36===0x0){_0x4b7864(_0x2c7432=>{const _0x529efe=_0x2bea9e,_0x50f14d=new Set(_0x2c7432);return _0x50f14d[_0x529efe(0x19a)](_0x5bf870)?_0x50f14d[_0x529efe(0x1a1)](_0x5bf870):_0x50f14d['add'](_0x5bf870),_0x50f14d;}),_0x5dec5f('');return;}if((_0x3ca42d==='a'||_0x3ca42d==='A')&&_0x2a8a9b===_0x2bea9e(0x1ac)&&_0x132f79&&_0x48ce36===0x0){_0x4b7864(new Set(UI_IDE_LIST['map']((_0x34b166,_0x250fd5)=>_0x250fd5))),_0x5dec5f('');return;}if((_0x3ca42d==='i'||_0x3ca42d==='I'||_0x3ca42d==='r'||_0x3ca42d==='R')&&_0x2a8a9b===_0x2bea9e(0x1ac)&&_0x132f79&&_0x48ce36===0x0){_0x4b7864(_0x3c353c=>{const _0x1ef159=_0x2bea9e,_0x2b8640=new Set();for(let _0x582089=0x0;_0x582089<UI_IDE_LIST[_0x1ef159(0x190)];_0x582089++){!_0x3c353c['has'](_0x582089)&&_0x2b8640[_0x1ef159(0x1c7)](_0x582089);}return _0x2b8640;});return;}if(_0x18b796['return']){if(_0x2a8a9b===_0x2bea9e(0x1cf)){const _0x530ad3=_0x437744[_0x2bea9e(0x1c5)]()||_0x2947ea;if(_0x3a327a)return;if(_0xe4a9de(_0x530ad3)){_0x5976ff(_0x2bea9e(0x1b4)+_0x530ad3+_0x2bea9e(0x181));return;}_0x2e880a(_0x530ad3),_0x5dcc3a([{'step':_0x2bea9e(0x1cf),'label':'项目名','value':_0x530ad3}]),_0x91b738(''),_0x5dec5f(''),_0x5976ff(''),_0x5d3d98(_0x2bea9e(0x198));return;}if(_0x2a8a9b===_0x2bea9e(0x198)){if(_0x3a327a)return;const _0x4087a0=_0x437744[_0x2bea9e(0x1c5)]();_0x360dd5(_0x4087a0),_0x5dcc3a(_0x495729=>[..._0x495729,{'step':_0x2bea9e(0x198),'label':'应用AppCode','value':_0x4087a0||'未设置'}]),_0x91b738(''),_0x5dec5f('');if(_0x4087a0){_0x5d3d98(_0x2bea9e(0x1a3));const _0x5aced8=await _0x2829fe();_0x5aced8?_0x5d3d98(_0x2bea9e(0x196)):_0x5d3d98('login-prompt');}else{const _0x49be4f=_0x50dcbd||_0x1f73d9||_0x2bea9e(0x183);_0x951e1e({'projectName':_0x4f7273,'appCode':undefined,'pullApi':![],'aiSetup':![],'selectedIDEs':[],'env':_0x49be4f}),_0x5d3d98('creating');}return;}if(_0x2a8a9b===_0x2bea9e(0x196)){const _0x137eb0=_0x3e121d===0x0;_0x5261f5(_0x137eb0),_0x5dcc3a(_0x4effc5=>[..._0x4effc5,{'step':_0x2bea9e(0x1a0),'label':_0x2bea9e(0x1bc),'value':_0x137eb0?'是':'否'}]),_0x5d3d98(_0x2bea9e(0x1ac));return;}if(_0x2a8a9b===_0x2bea9e(0x1ac)){if(!_0x132f79){_0x55ac2b(!![]);if(_0x48ce36===0x1){_0x5dcc3a(_0x222c65=>[..._0x222c65,{'step':'lovrabet-setup','label':_0x2bea9e(0x193),'value':'否'}]);const _0x42c901=_0x50dcbd||_0x1f73d9||_0x2bea9e(0x183);_0x951e1e({'projectName':_0x4f7273,'appCode':_0x291920,'pullApi':_0x14bd3a,'aiSetup':![],'selectedIDEs':[],'env':_0x42c901}),_0x5d3d98(_0x2bea9e(0x1a5));}return;}if(_0x39d907['size']===0x0){_0x5dec5f(_0x2bea9e(0x1b7));return;}const _0x14b94b=Array['from'](_0x39d907)['map'](_0x366075=>UI_IDE_LIST[_0x366075])[_0x2bea9e(0x1c3)](_0x1a4b13=>_0x1a4b13!==undefined);_0x5dcc3a(_0x1aab17=>[..._0x1aab17,{'step':_0x2bea9e(0x1c4),'label':_0x2bea9e(0x193),'value':_0x14b94b[_0x2bea9e(0x190)]+'\x20个\x20IDE'}]);const _0x2ea6fe=_0x50dcbd||_0x1f73d9||'online';_0x951e1e({'projectName':_0x4f7273,'appCode':_0x291920,'pullApi':_0x14bd3a,'aiSetup':!![],'selectedIDEs':_0x14b94b,'env':_0x2ea6fe}),_0x5d3d98('creating');return;}if(_0x2a8a9b===_0x2bea9e(0x1cb)){const _0x18ffb1=_0x396b7b===0x0;if(_0x18ffb1){_0x5d3d98(_0x2bea9e(0x18c));const _0x4979c4=await _0x36f8e2();_0x4979c4?(_0x5dcc3a(_0xce0208=>[..._0xce0208,{'step':_0x2bea9e(0x185),'label':_0x2bea9e(0x18f),'value':_0x2bea9e(0x1a7)}]),_0x5d3d98(_0x2bea9e(0x196))):(_0x5dcc3a(_0x358cc0=>[..._0x358cc0,{'step':_0x2bea9e(0x185),'label':_0x2bea9e(0x18f),'value':_0x2bea9e(0x1df)}]),_0x5d3d98(_0x2bea9e(0x1ac)));}else _0x5dcc3a(_0x28dc17=>[..._0x28dc17,{'step':_0x2bea9e(0x185),'label':'登录状态','value':_0x2bea9e(0x1d7)}]),_0x5d3d98('lovrabet-setup-selection');return;}}if(_0x18b796[_0x2bea9e(0x19c)]||_0x18b796[_0x2bea9e(0x1a1)]){_0x91b738(_0x2974d0=>{const _0x257990=_0x2bea9e,_0x293acc=_0x2974d0[_0x257990(0x1d9)](0x0,-0x1);if(_0x2a8a9b===_0x257990(0x1cf)){const {valid:_0x5dcb20,message:_0x27c61b}=_0x535b00(_0x293acc);_0x5dec5f(_0x5dcb20?'':_0x27c61b||'项目名不合法');if(_0x5dcb20&&!_0x3a327a){const _0x1f7da0=_0x293acc||_0x2947ea;_0xe4a9de(_0x1f7da0)?_0x5976ff(_0x257990(0x1b4)+_0x1f7da0+'\x22\x20已存在'):_0x5976ff('');}}else{if(_0x2a8a9b===_0x257990(0x198)){const {valid:_0x498274,message:_0x253568}=_0x1c0e58(_0x293acc);_0x5dec5f(_0x498274?'':_0x253568||'应用AppCode不合法');}}return _0x293acc;});return;}if([_0x2bea9e(0x1a5),_0x2bea9e(0x1a3),'login-process'][_0x2bea9e(0x1b1)](_0x2a8a9b))return;if(_0x2a8a9b===_0x2bea9e(0x196)||_0x2a8a9b===_0x2bea9e(0x1cb)||_0x2a8a9b===_0x2bea9e(0x1ac))return;_0x91b738(_0x1f6b16=>{const _0x484b7d=_0x2bea9e,_0x1c39a4=_0x1f6b16+_0x3ca42d;if(_0x2a8a9b==='project-name'){const {valid:_0x24daf0,message:_0x1a22bd}=_0x535b00(_0x1c39a4);_0x5dec5f(_0x24daf0?'':_0x1a22bd||'项目名不合法');if(_0x24daf0&&!_0x3a327a){const _0x494e56=_0x1c39a4||_0x2947ea;_0xe4a9de(_0x494e56)?_0x5976ff(_0x484b7d(0x1b4)+_0x494e56+_0x484b7d(0x1a2)):_0x5976ff('');}}else{if(_0x2a8a9b==='app-code'){const {valid:_0xfe3306,message:_0x5814c5}=_0x1c0e58(_0x1c39a4);_0x5dec5f(_0xfe3306?'':_0x5814c5||_0x484b7d(0x1c1));}}return _0x1c39a4;});}),a42_0x106683(Box,{'flexDirection':_0x12b557(0x1ba),'marginTop':0x1,'children':[_0x361e83[_0x12b557(0x190)]===0x0&&a42_0x39a007(Box,{'children':a42_0x39a007(Text,{'color':_0x12b557(0x194),'children':_0x12b557(0x1d4)})}),_0x361e83[_0x12b557(0x1b6)](_0x57be14=>a42_0x106683(Box,{'children':[a42_0x106683(Text,{'color':'green','children':['√\x20',_0x57be14['label'],':\x20']}),a42_0x39a007(Text,{'color':_0x12b557(0x194),'children':_0x57be14[_0x12b557(0x1dc)]})]},_0x57be14['step'])),_0x2a8a9b===_0x12b557(0x1cf)&&a42_0x106683(a42_0x38992f,{'children':[a42_0x106683(Box,{'children':[a42_0x39a007(Text,{'children':_0x12b557(0x199)}),_0x437744?a42_0x39a007(Text,{'color':'green','children':_0x437744}):a42_0x39a007(Text,{'color':'gray','children':_0x2947ea}),_0x3a327a&&a42_0x106683(Text,{'color':_0x12b557(0x197),'children':[_0x12b557(0x1de),_0x3a327a]}),_0x5046a7&&a42_0x106683(Text,{'color':_0x12b557(0x197),'children':[_0x12b557(0x1de),_0x5046a7]})]}),!_0x3a327a&&!_0x5046a7&&!_0x437744&&a42_0x39a007(Box,{'children':a42_0x39a007(Text,{'color':_0x12b557(0x1c9),'children':'\x20直接回车确认,或输入自定义名称'})})]}),_0x2a8a9b===_0x12b557(0x198)&&a42_0x106683(a42_0x38992f,{'children':[a42_0x106683(Box,{'children':[a42_0x39a007(Text,{'children':_0x12b557(0x192)}),a42_0x39a007(Text,{'color':_0x12b557(0x1c9),'children':_0x12b557(0x1af)}),a42_0x39a007(Text,{'color':_0x12b557(0x1d1),'children':_0x437744}),_0x3a327a&&a42_0x106683(Text,{'color':_0x12b557(0x197),'children':[_0x12b557(0x1de),_0x3a327a]})]}),!_0x3a327a&&a42_0x39a007(Box,{'children':a42_0x106683(Text,{'color':'gray','children':['\x20',_0x12b557(0x18e)]})})]}),_0x2a8a9b===_0x12b557(0x1a3)&&a42_0x106683(Box,{'children':[a42_0x39a007(Text,{'children':_0x12b557(0x186)}),_0x1a547d&&a42_0x39a007(Text,{'color':_0x12b557(0x1c9),'children':_0x12b557(0x1a9)})]}),_0x2a8a9b===_0x12b557(0x196)&&a42_0x106683(a42_0x38992f,{'children':[a42_0x39a007(Box,{'children':a42_0x39a007(Text,{'color':_0x12b557(0x1d1),'children':'√\x20检测到有效登录状态'})}),a42_0x39a007(Box,{'marginTop':0x1,'children':a42_0x39a007(Text,{'children':_0x12b557(0x1c2)})}),a42_0x106683(Box,{'marginLeft':0x2,'children':[a42_0x106683(Text,{'color':_0x3e121d===0x0?_0x12b557(0x1d1):_0x12b557(0x1c9),'children':[_0x3e121d===0x0?'▶\x20':'\x20\x20',_0x12b557(0x1b8)]}),a42_0x39a007(Text,{'children':'\x20'}),a42_0x106683(Text,{'color':_0x3e121d===0x1?_0x12b557(0x1d1):'gray','children':[_0x3e121d===0x1?'▶\x20':'\x20\x20','No']})]}),a42_0x39a007(Box,{'children':a42_0x39a007(Text,{'color':'gray','children':'\x20\x20使用\x20←→\x20选择,回车确认'})}),a42_0x39a007(Box,{'children':a42_0x39a007(Text,{'color':_0x12b557(0x1b2),'children':_0x12b557(0x1a8)})})]}),_0x2a8a9b===_0x12b557(0x1ac)&&a42_0x106683(a42_0x38992f,{'children':[a42_0x39a007(Box,{'children':a42_0x39a007(Text,{'color':_0x12b557(0x1d1),'children':'√'})}),a42_0x39a007(Box,{'marginTop':0x1,'children':a42_0x39a007(Text,{'children':_0x12b557(0x188)})}),a42_0x106683(Box,{'marginLeft':0x2,'children':[a42_0x106683(Text,{'color':_0x48ce36===0x0?_0x12b557(0x1d1):_0x12b557(0x1c9),'children':[_0x48ce36===0x0?'▶\x20':'\x20\x20',_0x12b557(0x1b8)]}),a42_0x39a007(Text,{'children':'\x20'}),a42_0x106683(Text,{'color':_0x48ce36===0x1?_0x12b557(0x1d1):_0x12b557(0x1c9),'children':[_0x48ce36===0x1?'▶\x20':'\x20\x20','No']})]}),_0x132f79&&_0x48ce36===0x0&&a42_0x106683(a42_0x38992f,{'children':[a42_0x39a007(Box,{'marginTop':0x1,'children':a42_0x39a007(Text,{'color':_0x12b557(0x1c9),'children':'\x20\x20使用\x20←→\x20返回修改选择,回车确认\x20IDE'})}),a42_0x106683(Box,{'marginTop':0x1,'flexDirection':_0x12b557(0x1ba),'children':[a42_0x39a007(Text,{'bold':!![],'color':_0x12b557(0x1b2),'children':_0x12b557(0x19b)}),UI_IDE_LIST[_0x12b557(0x1b6)]((_0x169a88,_0x19e000)=>{const _0x378aad=_0x12b557,_0x130432=_0x5bf870===_0x19e000,_0x3f759e=_0x39d907['has'](_0x19e000),_0x3207b9=UI_MCP_IDES[_0x378aad(0x19a)](_0x169a88);return a42_0x39a007(Box,{'children':a42_0x106683(Text,{'backgroundColor':_0x130432?_0x378aad(0x1da):undefined,'color':_0x130432?'white':undefined,'children':['\x20\x20',_0x3f759e?_0x378aad(0x18b):_0x378aad(0x1d8),'\x20',UI_IDE_CONFIGS[_0x169a88]['name'],_0x3207b9&&a42_0x39a007(Text,{'color':_0x130432?_0x378aad(0x1be):_0x378aad(0x194),'children':_0x378aad(0x1bb)}),'\x20',a42_0x106683(Text,{'color':_0x130432?_0x378aad(0x1be):_0x378aad(0x1c9),'dimColor':!_0x130432,'children':['-\x20',UI_IDE_CONFIGS[_0x169a88][_0x378aad(0x182)]]})]})},_0x169a88);}),a42_0x39a007(Box,{'marginTop':0x1,'children':a42_0x106683(Text,{'color':_0x12b557(0x1c9),'children':['\x20',_0x12b557(0x187)]})})]})]}),!_0x132f79&&a42_0x39a007(Box,{'marginTop':0x1,'children':a42_0x39a007(Text,{'color':'gray','children':'\x20\x20使用\x20←→\x20选择,回车确认'})}),_0x3a327a&&a42_0x39a007(Box,{'marginTop':0x1,'children':a42_0x106683(Text,{'color':_0x12b557(0x197),'children':['✗\x20',_0x3a327a]})})]}),_0x2a8a9b===_0x12b557(0x1cb)&&a42_0x106683(a42_0x38992f,{'children':[a42_0x39a007(Box,{'children':a42_0x39a007(Text,{'color':_0x12b557(0x1b2),'children':_0x12b557(0x1aa)})}),a42_0x39a007(Box,{'marginTop':0x1,'children':a42_0x39a007(Text,{'children':_0x12b557(0x1e1)})}),a42_0x106683(Box,{'marginLeft':0x2,'children':[a42_0x106683(Text,{'color':_0x396b7b===0x0?'green':'gray','children':[_0x396b7b===0x0?'▶\x20':'\x20\x20','Yes']}),a42_0x39a007(Text,{'children':'\x20'}),a42_0x106683(Text,{'color':_0x396b7b===0x1?_0x12b557(0x1d1):_0x12b557(0x1c9),'children':[_0x396b7b===0x1?'▶\x20':'\x20\x20','No']})]}),a42_0x39a007(Box,{'children':a42_0x39a007(Text,{'color':_0x12b557(0x1c9),'children':_0x12b557(0x195)})})]}),_0x2a8a9b==='login-process'&&a42_0x106683(Box,{'children':[a42_0x39a007(Text,{'children':_0x12b557(0x1a6)}),_0x319e0a&&a42_0x39a007(Text,{'color':'gray','children':'\x20登录中...'})]}),_0x2a8a9b==='creating'&&a42_0x39a007(Box,{'children':a42_0x39a007(Text,{'color':'green','children':_0x12b557(0x1b0)})})]});}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x5095bd,_0x3e94d4){const _0x28aa7f=a43_0x5411,_0x5b8592=_0x5095bd();while(!![]){try{const _0x43e670=parseInt(_0x28aa7f(0x1b4))/0x1*(parseInt(_0x28aa7f(0x1b0))/0x2)+parseInt(_0x28aa7f(0x1b5))/0x3+parseInt(_0x28aa7f(0x1ad))/0x4*(-parseInt(_0x28aa7f(0x1b7))/0x5)+-parseInt(_0x28aa7f(0x1b3))/0x6*(-parseInt(_0x28aa7f(0x1b2))/0x7)+-parseInt(_0x28aa7f(0x1af))/0x8+parseInt(_0x28aa7f(0x1ac))/0x9+-parseInt(_0x28aa7f(0x1b6))/0xa;if(_0x43e670===_0x3e94d4)break;else _0x5b8592['push'](_0x5b8592['shift']());}catch(_0x7876b9){_0x5b8592['push'](_0x5b8592['shift']());}}}(a43_0x4782,0x8dffc));export function formatElapsed(_0x3bfb22){const _0x51e7cd=a43_0x5411,_0x7504ad=Date[_0x51e7cd(0x1b1)]()-_0x3bfb22;if(_0x7504ad<0x3e8)return _0x7504ad+'ms';const _0x2cb0e1=(_0x7504ad/0x3e8)[_0x51e7cd(0x1ab)](0x2),_0x42dec8=_0x2cb0e1[_0x51e7cd(0x1ae)](/\.?0+$/u,'');return _0x42dec8+'s';}function a43_0x5411(_0x1313ad,_0x4b5810){_0x1313ad=_0x1313ad-0x1ab;const _0x478296=a43_0x4782();let _0x54116e=_0x478296[_0x1313ad];return _0x54116e;}function a43_0x4782(){const _0x50317b=['toFixed','1652085PPPxrz','8KGABLO','replace','3994368bNCsDo','381540EbZBNw','now','798egvbiG','23802RPkpCj','6oSIaxS','1886682BIESEP','2944390iPpjnz','2584885TWlmZI'];a43_0x4782=function(){return _0x50317b;};return a43_0x4782();}
|
package/lib/create-app/main.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0xb9c312,_0xb49978){const _0x487b1d=a44_0x3e2c,_0x46a773=_0xb9c312();while(!![]){try{const _0x2a86c0=-parseInt(_0x487b1d(0x1b5))/0x1*(-parseInt(_0x487b1d(0x1db))/0x2)+parseInt(_0x487b1d(0x1d7))/0x3+-parseInt(_0x487b1d(0x1ae))/0x4+parseInt(_0x487b1d(0x20d))/0x5+-parseInt(_0x487b1d(0x1b7))/0x6*(parseInt(_0x487b1d(0x1af))/0x7)+parseInt(_0x487b1d(0x20b))/0x8+-parseInt(_0x487b1d(0x1f6))/0x9*(parseInt(_0x487b1d(0x1ad))/0xa);if(_0x2a86c0===_0xb49978)break;else _0x46a773['push'](_0x46a773['shift']());}catch(_0xf90a9d){_0x46a773['push'](_0x46a773['shift']());}}}(a44_0x1605,0xcfe80));function a44_0x3e2c(_0x24744f,_0x5c4696){_0x24744f=_0x24744f-0x1a4;const _0x160526=a44_0x1605();let _0x3e2c32=_0x160526[_0x24744f];return _0x3e2c32;}import{jsx as a44_0xbe8c02,Fragment as a44_0x150414,jsxs as a44_0x338d1e}from'react/jsx-runtime';import a44_0xe78125 from'path';import a44_0x2a742a 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';function a44_0x1605(){const _0x1f1321=['API\x20配置拉取异常','ide','resolve','manual','parse','env','filter','4413152VHfJbY','Claude\x20Code','4337485vNyNsk','description','拉取API配置:\x20','lovrabet\x20mcp\x20install','项目创建完成:\x20','lovrabet\x20config\x20set\x20appcode\x20[app-code]','test','info','red','×\x20项目创建失败:\x20','cwd','CLI\x20版本检查','.lovrabetrc','*\x20清理失败的项目目录:\x20','lovrabet\x20api\x20pull\x20--appcode\x20[app-code]','success','*\x20正在为项目\x20','trim','appCode','1.\x20配置\x20Lovrabet\x20MCP\x20和\x20Skill','log','cyan','has','warn','项目创建失败:\x20','配置AppCode:\x20','21990YfUJag','1573064ymXibA','7iNwoqc','version','*\x20正在拉取\x20API\x20配置...','cd\x20','cursor','utf8','15427jMwsnC','√\x20package.json\x20已更新:\x20name=','8834934JiJRdn','\x20MCP\x20','\x20创建配置文件','stringify','启动项目:\x20','2.\x20','1.\x20','online','skill-','pullApi','setLogPath','更新\x20package.json\x20name','√\x20配置文件已创建,应用AppCode:\x20','string','readFileSync','dirname','writeFileSync','lovrabet\x20api\x20pull','message','配置应用AppCode失败','stableVersion','selectedIDEs','projectCode','error','W_OK','\x20配置应用AppCode:\x20','3.\x20','×\x20项目名不能为空','\x20\x20✗\x20MCP\x20','\x20\x20•\x20Skill:\x20','✓\x20Skill\x20安装完成:','green','4644408XKTVqx','\x20&&\x20lovrabet\x20start','rmSync','skill','44RPGNUN','mcp','length','gray','constants','API\x20配置拉取成功:\x20','join','\x20√\x20','\x20\x20✗\x20Skill\x20','column','√\x20Lovrabet\x20MCP\x20和\x20Skill\x20配置完成','Cursor','√\x20API\x20配置拉取完成','repeat','1.0.0','existsSync','lovrabet\x20skill\x20install','create','\x20Skill\x20','push','项目名称:\x20','API\x20配置拉取失败:\x20','\x20\x20•\x20MCP\x20服务器:\x20','\x20|\x20应用AppCode:\x20','../..','配置应用AppCode:\x20','status','2412PxFouF','map','aiSetup','package.json','\x20Generated\x20by\x20lovrabet\x20cli\x20','accessSync','doTask','needsUpgrade','projectName','name','清理项目目录失败:\x20','white','🚀\x20接下来:','yellow'];a44_0x1605=function(){return _0x1f1321;};return a44_0x1605();}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';import{MCP_IDES}from'../utils/ai_config.js';import{checkCliVersion,printCliUpgradeWarning}from'../utils/cli-version-check.js';export function CreateApp(_0x5551e8){const _0x769fae=a44_0x3e2c,[_0x2f1ef6,_0x25fdc1]=useState(![]),[_0x17a11e,_0x4e3d4c]=useState(![]),[_0x4bced4,_0x5db7be]=useState(null),[_0x3e4afe,_0x4cf3ec]=useState(null),_0x81da42=useCopyProjectTemplate(),_0x5887c1=useInstallDependencies(),_0x3745a4=useFormatCode();useEffect(()=>{checkCliVersion()['then'](_0x43b874=>{const _0xefa274=a44_0x3e2c;_0x43b874[_0xefa274(0x1fd)]&&(printCliUpgradeWarning(_0x43b874),logger['info'](_0xefa274(0x1ec),_0xefa274(0x218),{'currentVersion':_0x43b874['currentVersion'],'stableVersion':_0x43b874[_0xefa274(0x1cb)],'needsUpgrade':_0x43b874[_0xefa274(0x1fd)]}));});},[]);const _0x34cedd=async _0x3c77d2=>{const _0x20bc1f=a44_0x3e2c;if(!_0x3c77d2[_0x20bc1f(0x1fe)]||_0x3c77d2['projectName'][_0x20bc1f(0x1a4)]()===''){console[_0x20bc1f(0x1ce)](_0x20bc1f(0x1d2));return;}const _0x28b0b8=/[<>:"|?*\x00-\x1f\x7f]/;if(_0x28b0b8[_0x20bc1f(0x213)](_0x3c77d2[_0x20bc1f(0x1fe)])){console[_0x20bc1f(0x1ce)]('×\x20项目名包含非法字符,不允许使用:\x20<\x20>\x20:\x20\x22\x20|\x20?\x20*\x20及控制字符');return;}if(_0x3c77d2[_0x20bc1f(0x1fe)][_0x20bc1f(0x1dd)]>0x64){console[_0x20bc1f(0x1ce)]('×\x20项目名过长,最多支持\x20100\x20个字符');return;}const _0x4cb663=a44_0xe78125[_0x20bc1f(0x206)](process['cwd'](),_0x3c77d2[_0x20bc1f(0x1fe)]);if(a44_0x2a742a[_0x20bc1f(0x1ea)](_0x4cb663)){console[_0x20bc1f(0x1ce)]('×\x20项目目录\x20'+_0x3c77d2[_0x20bc1f(0x1fe)]+'\x20已存在,请使用其他项目名');return;}try{const _0x11b72b=a44_0xe78125[_0x20bc1f(0x1c6)](_0x4cb663);a44_0x2a742a[_0x20bc1f(0x1fb)](_0x11b72b,a44_0x2a742a[_0x20bc1f(0x1df)][_0x20bc1f(0x1cf)]);}catch(_0x532d8a){console[_0x20bc1f(0x1ce)]('×\x20无法在当前目录创建项目,请检查目录权限');return;}_0x5db7be(_0x3c77d2),_0x25fdc1(!![]),logger[_0x20bc1f(0x1c1)](_0x4cb663),logger['info'](_0x20bc1f(0x1ec),'开始创建项目:\x20'+_0x3c77d2[_0x20bc1f(0x1fe)],{'projectDir':_0x4cb663,'appCode':_0x3c77d2[_0x20bc1f(0x1a5)]});try{await _0x81da42[_0x20bc1f(0x1fc)](_0x3c77d2[_0x20bc1f(0x1fe)]),await _0x1e5897(_0x3c77d2['projectName']),await _0x5887c1[_0x20bc1f(0x1fc)](_0x3c77d2[_0x20bc1f(0x1fe)]),await _0x3745a4['doTask'](_0x3c77d2['projectName']),await _0x27856f(_0x3c77d2['projectName'],_0x3c77d2['appCode']||'',_0x3c77d2[_0x20bc1f(0x209)]);if(_0x3c77d2[_0x20bc1f(0x1c0)]&&_0x3c77d2['appCode']){console[_0x20bc1f(0x1a7)](_0x20bc1f(0x1b1));try{const _0x3be549=await pullApiSilent(_0x3c77d2[_0x20bc1f(0x1a5)],undefined,_0x4cb663,_0x3c77d2[_0x20bc1f(0x209)]);_0x3be549?(console['log'](_0x20bc1f(0x1e7)),logger['info'](_0x20bc1f(0x1ec),_0x20bc1f(0x1e0)+_0x3c77d2[_0x20bc1f(0x1a5)])):(console['log']('!\x20API\x20配置拉取失败,可稍后手动执行:\x20lovrabet\x20api\x20pull'),logger[_0x20bc1f(0x1aa)](_0x20bc1f(0x1ec),_0x20bc1f(0x1f0)+_0x3c77d2[_0x20bc1f(0x1a5)]));}catch(_0x10b302){console[_0x20bc1f(0x1a7)]('!\x20API\x20配置拉取异常,项目已创建,可稍后手动执行:\x20lovrabet\x20api\x20pull'),logger[_0x20bc1f(0x1aa)](_0x20bc1f(0x1ec),_0x20bc1f(0x204),{'error':_0x10b302 instanceof Error?_0x10b302[_0x20bc1f(0x1c9)]:String(_0x10b302)});}}if(_0x3c77d2[_0x20bc1f(0x1f8)]&&_0x3c77d2[_0x20bc1f(0x1cc)]&&_0x3c77d2['selectedIDEs'][_0x20bc1f(0x1dd)]>0x0&&_0x3c77d2[_0x20bc1f(0x1a5)]){console['log']('*\x20正在配置\x20Lovrabet\x20MCP\x20和\x20Skill...');const _0x23290c=[],_0x4fa1a9=[],_0x1a5b08=_0x3c77d2['selectedIDEs']['filter'](_0x8b89e3=>MCP_IDES[_0x20bc1f(0x1a9)](_0x8b89e3)),_0x21618a=_0x3c77d2[_0x20bc1f(0x1cc)];for(const _0x29d8da of _0x1a5b08){try{const _0x4af95f=await configureMcp(_0x29d8da,_0x4cb663);_0x23290c[_0x20bc1f(0x1ee)]({'ide':_0x29d8da===_0x20bc1f(0x1b3)?_0x20bc1f(0x1e6):'Claude\x20Code','status':_0x4af95f[_0x20bc1f(0x1f5)],'message':_0x4af95f[_0x20bc1f(0x1c9)]}),console['log']('\x20\x20'+(_0x4af95f['status']==='success'?'✓':_0x4af95f[_0x20bc1f(0x1f5)]===_0x20bc1f(0x207)?'⚠️':'✗')+_0x20bc1f(0x1b8)+_0x29d8da+':\x20'+_0x4af95f[_0x20bc1f(0x1c9)]);}catch(_0x4001a4){_0x23290c[_0x20bc1f(0x1ee)]({'ide':_0x29d8da==='cursor'?'Cursor':_0x20bc1f(0x20c),'status':_0x20bc1f(0x1ce),'message':_0x4001a4 instanceof Error?_0x4001a4['message']:String(_0x4001a4)}),console[_0x20bc1f(0x1a7)](_0x20bc1f(0x1d3)+_0x29d8da+':\x20'+(_0x4001a4 instanceof Error?_0x4001a4[_0x20bc1f(0x1c9)]:String(_0x4001a4)));}}await copySharedSkills(_0x4cb663);for(const _0x428f3a of _0x21618a){try{const _0x5caf5a=await installSkill(_0x428f3a,_0x4cb663);_0x4fa1a9['push']({'ide':_0x5caf5a[_0x20bc1f(0x205)],'status':_0x5caf5a[_0x20bc1f(0x1f5)],'message':_0x5caf5a[_0x20bc1f(0x1c9)]}),console[_0x20bc1f(0x1a7)]('\x20\x20'+(_0x5caf5a[_0x20bc1f(0x1f5)]==='success'?'✓':'✗')+_0x20bc1f(0x1ed)+_0x5caf5a[_0x20bc1f(0x205)]+':\x20'+_0x5caf5a[_0x20bc1f(0x1c9)]);}catch(_0x5a6042){_0x4fa1a9[_0x20bc1f(0x1ee)]({'ide':_0x428f3a,'status':_0x20bc1f(0x1ce),'message':_0x5a6042 instanceof Error?_0x5a6042[_0x20bc1f(0x1c9)]:String(_0x5a6042)}),console[_0x20bc1f(0x1a7)](_0x20bc1f(0x1e3)+_0x428f3a+':\x20'+(_0x5a6042 instanceof Error?_0x5a6042[_0x20bc1f(0x1c9)]:String(_0x5a6042)));}}if(_0x4fa1a9[_0x20bc1f(0x1dd)]>0x0){const _0x4820ef=_0x4fa1a9[_0x20bc1f(0x20a)](_0x80dc5e=>_0x80dc5e[_0x20bc1f(0x1f5)]===_0x20bc1f(0x21c))[_0x20bc1f(0x1f7)](_0x45a322=>_0x45a322[_0x20bc1f(0x205)]);_0x4820ef['length']>0x0&&createSkillManifest(_0x4cb663,_0x4820ef);}_0x4cf3ec({'mcp':_0x23290c,'skill':_0x4fa1a9}),console[_0x20bc1f(0x1a7)](_0x20bc1f(0x1e5));}logger[_0x20bc1f(0x21c)]('create',_0x20bc1f(0x211)+_0x3c77d2[_0x20bc1f(0x1fe)]),_0x4e3d4c(!![]),_0x25fdc1(![]);}catch(_0x55443f){logger[_0x20bc1f(0x1ce)](_0x20bc1f(0x1ec),_0x20bc1f(0x1ab)+_0x3c77d2[_0x20bc1f(0x1fe)],{'error':_0x55443f instanceof Error?_0x55443f[_0x20bc1f(0x1c9)]:String(_0x55443f)});try{a44_0x2a742a['existsSync'](_0x4cb663)&&(console[_0x20bc1f(0x1a7)](_0x20bc1f(0x21a)+_0x4cb663),a44_0x2a742a[_0x20bc1f(0x1d9)](_0x4cb663,{'recursive':!![],'force':!![]}));}catch(_0x2ffc70){logger[_0x20bc1f(0x1aa)](_0x20bc1f(0x1ec),_0x20bc1f(0x200)+_0x4cb663);}_0x25fdc1(![]),console['error'](_0x20bc1f(0x216)+(_0x55443f instanceof Error?_0x55443f[_0x20bc1f(0x1c9)]:String(_0x55443f)));}},_0x823c2d=async _0x5db3a6=>{const _0x256258=a44_0x3e2c;await _0x34cedd({'projectName':_0x5db3a6,'env':_0x5551e8[_0x256258(0x209)]});},_0x1e5897=async _0x2315c0=>{const _0x5623e7=a44_0x3e2c,_0x525496=a44_0xe78125[_0x5623e7(0x206)](process[_0x5623e7(0x217)](),_0x2315c0),_0x4390dd=a44_0xe78125['join'](_0x525496,_0x5623e7(0x1f9));try{console[_0x5623e7(0x1a7)]('*\x20正在更新\x20package.json\x20的\x20name\x20和\x20description\x20字段');const _0x213c3d=fileURLToPath(import.meta.url),_0x3d5acf=a44_0xe78125['resolve'](a44_0xe78125[_0x5623e7(0x1c6)](_0x213c3d),_0x5623e7(0x1f3)),_0x259fcb=a44_0xe78125[_0x5623e7(0x1e1)](_0x3d5acf,_0x5623e7(0x1f9));let _0x4d8881='1.0.0';try{const _0x301929=JSON[_0x5623e7(0x208)](a44_0x2a742a[_0x5623e7(0x1c5)](_0x259fcb,_0x5623e7(0x1b4)));_0x4d8881=_0x301929[_0x5623e7(0x1b0)]||_0x5623e7(0x1e9);}catch(_0x28d708){}const _0x51781a=a44_0x2a742a[_0x5623e7(0x1c5)](_0x4390dd,_0x5623e7(0x1b4)),_0x47f6c4=JSON[_0x5623e7(0x208)](_0x51781a);_0x47f6c4[_0x5623e7(0x1ff)]=_0x2315c0,_0x47f6c4[_0x5623e7(0x20e)]=_0x2315c0+_0x5623e7(0x1fa)+_0x4d8881,a44_0x2a742a[_0x5623e7(0x1c7)](_0x4390dd,JSON['stringify'](_0x47f6c4,null,0x2)+'\x0a',_0x5623e7(0x1b4)),console[_0x5623e7(0x1a7)](_0x5623e7(0x1b6)+_0x2315c0),logger[_0x5623e7(0x214)](_0x5623e7(0x1ec),_0x5623e7(0x1c2));}catch(_0x6cd7aa){logger['error'](_0x5623e7(0x1ec),'更新\x20package.json\x20失败');throw _0x6cd7aa;}},_0x27856f=async(_0x491ec1,_0x4ac23b,_0x23fe6f)=>{const _0x15cb10=a44_0x3e2c,_0x46a620=a44_0xe78125[_0x15cb10(0x206)](process[_0x15cb10(0x217)](),_0x491ec1),_0x106466=a44_0xe78125[_0x15cb10(0x1e1)](_0x46a620,_0x15cb10(0x219));try{_0x4ac23b?console[_0x15cb10(0x1a7)]('*\x20正在为项目\x20'+_0x491ec1+_0x15cb10(0x1d0)+_0x4ac23b):console[_0x15cb10(0x1a7)](_0x15cb10(0x21d)+_0x491ec1+_0x15cb10(0x1b9));const _0x1ef2c3=fileURLToPath(import.meta.url),_0x174139=a44_0xe78125[_0x15cb10(0x206)](a44_0xe78125[_0x15cb10(0x1c6)](_0x1ef2c3),_0x15cb10(0x1f3)),_0x3c8cfa=a44_0xe78125[_0x15cb10(0x1e1)](_0x174139,_0x15cb10(0x1f9));let _0x280c11=_0x15cb10(0x1e9);try{const _0x1c5156=JSON[_0x15cb10(0x208)](a44_0x2a742a[_0x15cb10(0x1c5)](_0x3c8cfa,'utf8'));_0x280c11=_0x1c5156[_0x15cb10(0x1b0)]||_0x15cb10(0x1e9);}catch(_0x47cfd9){}const _0x321720=readConfig(),_0x46e2df=typeof _0x321720[_0x15cb10(0x209)]===_0x15cb10(0x1c4)?_0x321720[_0x15cb10(0x209)]:undefined,{app:_0x3ba0ff,appcode:_0x223dc0,..._0x4795a9}=_0x321720,_0x44f8f3={..._0x4795a9,'appcode':_0x4ac23b||'','env':_0x23fe6f||_0x46e2df||_0x15cb10(0x1be),'createdAt':new Date()['toLocaleString'](),'version':_0x280c11};a44_0x2a742a[_0x15cb10(0x1c7)](_0x106466,JSON[_0x15cb10(0x1ba)](_0x44f8f3,null,0x2),_0x15cb10(0x1b4)),_0x4ac23b?console[_0x15cb10(0x1a7)](_0x15cb10(0x1c3)+_0x4ac23b):console[_0x15cb10(0x1a7)]('√\x20配置文件已创建,可稍后使用\x20\x27lovrabet\x20config\x20set\x20appcode\x20<app-code>\x27\x20配置'),logger['info'](_0x15cb10(0x1ec),_0x15cb10(0x1f4)+_0x4ac23b);}catch(_0x43842f){logger['error'](_0x15cb10(0x1ec),_0x15cb10(0x1ca));}};useEffect(()=>{const _0x29f1df=a44_0x3e2c;_0x5551e8[_0x29f1df(0x1cd)]&&_0x823c2d(_0x5551e8['projectCode']);},[_0x5551e8[_0x769fae(0x1cd)]]);if(!_0x2f1ef6&&!_0x17a11e&&!_0x5551e8[_0x769fae(0x1cd)])return a44_0xbe8c02(EnhancedGuidedCreate,{'onCreate':_0x34cedd,'env':_0x5551e8[_0x769fae(0x209)]});if(_0x2f1ef6)return a44_0x338d1e(a44_0x150414,{'children':[a44_0x338d1e(Box,{'marginTop':0x1,'children':[a44_0xbe8c02(Box,{'width':'1'}),a44_0xbe8c02(Text,{'color':'green','children':_0x769fae(0x1e2)}),a44_0xbe8c02(Text,{'children':'项目名称:\x20'}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1d6),'children':_0x4bced4?.['projectName']}),_0x4bced4?.[_0x769fae(0x1a5)]&&a44_0x338d1e(a44_0x150414,{'children':[a44_0xbe8c02(Text,{'children':_0x769fae(0x1f2)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1a8),'children':_0x4bced4[_0x769fae(0x1a5)]})]})]}),a44_0xbe8c02(TaskRunning,{..._0x81da42}),a44_0xbe8c02(TaskRunning,{..._0x5887c1}),a44_0xbe8c02(TaskRunning,{..._0x3745a4})]});if(_0x17a11e){const _0x2b8c42=_0x3e4afe&&(_0x3e4afe[_0x769fae(0x1dc)][_0x769fae(0x1dd)]>0x0||_0x3e4afe[_0x769fae(0x1da)]['length']>0x0);return a44_0x338d1e(a44_0x150414,{'children':[a44_0x338d1e(Box,{'marginTop':0x1,'children':[a44_0xbe8c02(Box,{'width':'1'}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1d6),'children':'\x20√\x20'}),a44_0xbe8c02(Text,{'children':_0x769fae(0x1ef)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1d6),'children':_0x4bced4?.['projectName']}),_0x4bced4?.[_0x769fae(0x1a5)]&&a44_0x338d1e(a44_0x150414,{'children':[a44_0xbe8c02(Text,{'children':_0x769fae(0x1f2)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1a8),'children':_0x4bced4[_0x769fae(0x1a5)]})]})]}),a44_0xbe8c02(TaskFinished,{..._0x81da42}),a44_0xbe8c02(TaskFinished,{..._0x5887c1}),a44_0xbe8c02(TaskFinished,{..._0x3745a4}),a44_0xbe8c02(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a44_0xbe8c02(Text,{'color':_0x769fae(0x1d6),'children':'─'[_0x769fae(0x1e8)](0x3c)})}),_0x2b8c42&&a44_0x338d1e(a44_0x150414,{'children':[_0x3e4afe[_0x769fae(0x1dc)][_0x769fae(0x1dd)]>0x0&&a44_0x338d1e(a44_0x150414,{'children':[a44_0xbe8c02(Box,{'marginTop':0x1,'children':a44_0xbe8c02(Text,{'color':_0x769fae(0x1d6),'bold':!![],'children':'✓\x20MCP\x20服务器配置完成:'})}),_0x3e4afe['mcp'][_0x769fae(0x1f7)]((_0x2ee78c,_0xa5c9bf)=>a44_0xbe8c02(Box,{'marginLeft':0x2,'children':a44_0x338d1e(Text,{'color':_0x2ee78c[_0x769fae(0x1f5)]===_0x769fae(0x21c)?'white':_0x2ee78c[_0x769fae(0x1f5)]===_0x769fae(0x207)?_0x769fae(0x203):_0x769fae(0x215),'children':[_0x2ee78c['ide'],':\x20',_0x2ee78c[_0x769fae(0x1c9)]]})},'mcp-'+_0xa5c9bf))]}),_0x3e4afe['skill']['length']>0x0&&a44_0x338d1e(a44_0x150414,{'children':[a44_0xbe8c02(Box,{'marginTop':_0x3e4afe['mcp'][_0x769fae(0x1dd)]>0x0?0x1:0x0,'children':a44_0xbe8c02(Text,{'color':'green','bold':!![],'children':_0x769fae(0x1d5)})}),_0x3e4afe[_0x769fae(0x1da)][_0x769fae(0x1f7)]((_0x31f52b,_0xfe6666)=>a44_0xbe8c02(Box,{'marginLeft':0x2,'children':a44_0x338d1e(Text,{'color':_0x31f52b['status']===_0x769fae(0x21c)?_0x769fae(0x201):_0x769fae(0x215),'children':[_0x31f52b[_0x769fae(0x205)],':\x20',_0x31f52b[_0x769fae(0x1c9)]]})},_0x769fae(0x1bf)+_0xfe6666))]}),a44_0xbe8c02(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a44_0xbe8c02(Text,{'color':'green','children':'─'[_0x769fae(0x1e8)](0x3c)})})]}),a44_0xbe8c02(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a44_0xbe8c02(Text,{'color':_0x769fae(0x1a8),'bold':!![],'children':_0x769fae(0x202)})}),a44_0x338d1e(Box,{'marginLeft':0x2,'flexDirection':_0x769fae(0x1e4),'children':[_0x2b8c42?a44_0x338d1e(a44_0x150414,{'children':[a44_0x338d1e(Box,{'children':[a44_0xbe8c02(Text,{'color':'green','children':_0x769fae(0x1bd)}),a44_0xbe8c02(Text,{'color':'white','children':'启动项目:\x20'}),a44_0xbe8c02(Text,{'color':'cyan','bold':!![],'children':_0x769fae(0x1b2)+_0x4bced4?.[_0x769fae(0x1fe)]+_0x769fae(0x1d8)})]}),_0x4bced4?.[_0x769fae(0x1a5)]&&!_0x4bced4?.[_0x769fae(0x1c0)]&&a44_0x338d1e(Box,{'children':[a44_0xbe8c02(Text,{'color':'yellow','children':_0x769fae(0x1bc)}),a44_0xbe8c02(Text,{'color':'white','children':_0x769fae(0x20f)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1a8),'bold':!![],'children':_0x769fae(0x1c8)})]})]}):a44_0x338d1e(a44_0x150414,{'children':[a44_0xbe8c02(Box,{'children':a44_0xbe8c02(Text,{'color':_0x769fae(0x203),'bold':!![],'children':_0x769fae(0x1a6)})}),a44_0x338d1e(Box,{'marginLeft':0x2,'marginTop':0x1,'children':[a44_0xbe8c02(Text,{'color':_0x769fae(0x201),'children':_0x769fae(0x1d4)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1a8),'bold':!![],'children':_0x769fae(0x1eb)})]}),a44_0x338d1e(Box,{'marginLeft':0x2,'children':[a44_0xbe8c02(Text,{'color':_0x769fae(0x201),'children':_0x769fae(0x1f1)}),a44_0xbe8c02(Text,{'color':'cyan','bold':!![],'children':_0x769fae(0x210)})]}),a44_0x338d1e(Box,{'marginTop':0x1,'children':[a44_0xbe8c02(Text,{'color':_0x769fae(0x1d6),'children':_0x769fae(0x1bc)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x201),'children':_0x769fae(0x1bb)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1a8),'bold':!![],'children':_0x769fae(0x1b2)+_0x4bced4?.[_0x769fae(0x1fe)]+_0x769fae(0x1d8)})]}),_0x4bced4?.[_0x769fae(0x1a5)]&&!_0x4bced4?.[_0x769fae(0x1c0)]&&a44_0x338d1e(Box,{'children':[a44_0xbe8c02(Text,{'color':_0x769fae(0x203),'children':_0x769fae(0x1d1)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x201),'children':_0x769fae(0x20f)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1a8),'bold':!![],'children':'lovrabet\x20api\x20pull'})]})]}),!_0x4bced4?.['appCode']&&a44_0x338d1e(a44_0x150414,{'children':[a44_0x338d1e(Box,{'children':[a44_0xbe8c02(Text,{'color':_0x769fae(0x1de),'children':_0x769fae(0x1bc)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x201),'children':_0x769fae(0x1ac)}),a44_0xbe8c02(Text,{'color':'cyan','bold':!![],'children':_0x769fae(0x212)})]}),a44_0x338d1e(Box,{'children':[a44_0xbe8c02(Text,{'color':'gray','children':_0x769fae(0x1d1)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x201),'children':_0x769fae(0x20f)}),a44_0xbe8c02(Text,{'color':_0x769fae(0x1a8),'bold':!![],'children':_0x769fae(0x21b)})]})]})]}),a44_0xbe8c02(Box,{'marginTop':0x1,'children':a44_0xbe8c02(Text,{'color':'green','children':'─'[_0x769fae(0x1e8)](0x3c)})})]});}return null;}
|
|
1
|
+
(function(_0x556f76,_0x581e98){const _0x48b0d0=a44_0x3c97,_0x18301e=_0x556f76();while(!![]){try{const _0x1d4303=parseInt(_0x48b0d0(0x132))/0x1+parseInt(_0x48b0d0(0x13e))/0x2+-parseInt(_0x48b0d0(0x143))/0x3+-parseInt(_0x48b0d0(0x151))/0x4+-parseInt(_0x48b0d0(0x13d))/0x5*(parseInt(_0x48b0d0(0x17e))/0x6)+-parseInt(_0x48b0d0(0x170))/0x7*(parseInt(_0x48b0d0(0x172))/0x8)+parseInt(_0x48b0d0(0x12f))/0x9;if(_0x1d4303===_0x581e98)break;else _0x18301e['push'](_0x18301e['shift']());}catch(_0x2616ba){_0x18301e['push'](_0x18301e['shift']());}}}(a44_0x4dee,0xeba14));import{jsx as a44_0x47b470,Fragment as a44_0x5e98d8,jsxs as a44_0x28b5d1}from'react/jsx-runtime';import a44_0x2f616d from'path';import a44_0x18f95e from'fs';import{fileURLToPath}from'node:url';import{Box,Text}from'ink';import{useEffect,useState}from'react';function a44_0x3c97(_0x67306f,_0x40e2c3){_0x67306f=_0x67306f-0x112;const _0x4dee99=a44_0x4dee();let _0x3c97c7=_0x4dee99[_0x67306f];return _0x3c97c7;}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';function a44_0x4dee(){const _0x3b1adc=['更新\x20package.json\x20失败','Claude\x20Code','warn','needsUpgrade','map','API\x20配置拉取成功:\x20','../..','push','*\x20清理失败的项目目录:\x20','projectName','配置AppCode:\x20','online','cyan','\x20\x20✗\x20Skill\x20','\x20\x20•\x20Skill:\x20','lovrabet\x20skill\x20install','currentVersion','\x20&&\x20lovrabet\x20start','\x20MCP\x20','√\x20API\x20配置拉取完成','stableVersion','√\x20package.json\x20已更新:\x20name=','description','\x20已存在,请使用其他项目名','21729789eyERoR','yellow','W_OK','1438471qvAIJN','lovrabet\x20api\x20pull\x20--appcode\x20[app-code]','cd\x20','CLI\x20版本检查','*\x20正在为项目\x20','name','manual','\x20|\x20应用AppCode:\x20','doTask','gray','create','5777405TEVfhL','3074758YJxbgw','1.\x20配置\x20Lovrabet\x20MCP\x20和\x20Skill','√\x20配置文件已创建,可稍后使用\x20\x27lovrabet\x20config\x20set\x20appcode\x20<app-code>\x27\x20配置','\x20Generated\x20by\x20lovrabet\x20cli\x20','toLocaleString','2425569VuJxLu','writeFileSync','cursor','更新\x20package.json\x20name','projectCode','项目创建失败:\x20','trim','开始创建项目:\x20','skill-','utf8','status','log','join','×\x20项目创建失败:\x20','6387236nfIBEH','拉取API配置:\x20','✓\x20MCP\x20服务器配置完成:','API\x20配置拉取失败:\x20','green','×\x20项目名不能为空','启动项目:\x20','version','!\x20API\x20配置拉取失败,可稍后手动执行:\x20lovrabet\x20api\x20pull','dirname','message','appCode','1.0.0','cwd','selectedIDEs','error','repeat','parse','\x20√\x20','ide','red','mcp','env','2.\x20','√\x20配置文件已创建,应用AppCode:\x20','\x20Skill\x20','skill','white','配置应用AppCode失败','\x20\x20✗\x20MCP\x20','info','42nNxLXE','existsSync','1152424OesSMq','×\x20项目名包含非法字符,不允许使用:\x20<\x20>\x20:\x20\x22\x20|\x20?\x20*\x20及控制字符','lovrabet\x20config\x20set\x20appcode\x20[app-code]','stringify','*\x20正在配置\x20Lovrabet\x20MCP\x20和\x20Skill...','\x20配置应用AppCode:\x20','🚀\x20接下来:','Cursor','then','lovrabet\x20mcp\x20install','length','lovrabet\x20api\x20pull','6YGboiL','resolve','*\x20正在拉取\x20API\x20配置...','×\x20无法在当前目录创建项目,请检查目录权限','readFileSync','package.json','清理项目目录失败:\x20','pullApi','filter','\x20创建配置文件','!\x20API\x20配置拉取异常,项目已创建,可稍后手动执行:\x20lovrabet\x20api\x20pull','*\x20正在更新\x20package.json\x20的\x20name\x20和\x20description\x20字段','setLogPath','项目名称:\x20','\x20\x20•\x20MCP\x20服务器:\x20','success','3.\x20','×\x20项目名过长,最多支持\x20100\x20个字符','.lovrabetrc'];a44_0x4dee=function(){return _0x3b1adc;};return a44_0x4dee();}import{configureMcp,copySharedSkills,installSkill,createSkillManifest}from'../ai-setup/config.js';import{MCP_IDES}from'../utils/ai_config.js';import{checkCliVersion,printCliUpgradeWarning}from'../utils/cli-version-check.js';export function CreateApp(_0x2c38c8){const _0x1b4b59=a44_0x3c97,[_0x4079cb,_0x5edd57]=useState(![]),[_0x5bc5df,_0x3f332c]=useState(![]),[_0x44113c,_0x2417c1]=useState(null),[_0x585443,_0x53b016]=useState(null),_0x216194=useCopyProjectTemplate(),_0x273e90=useInstallDependencies(),_0x4a4446=useFormatCode();useEffect(()=>{const _0x4b7b33=a44_0x3c97;checkCliVersion()[_0x4b7b33(0x17a)](_0x57e9c6=>{const _0x11fd71=_0x4b7b33;_0x57e9c6[_0x11fd71(0x11a)]&&(printCliUpgradeWarning(_0x57e9c6),logger[_0x11fd71(0x16f)](_0x11fd71(0x13c),_0x11fd71(0x135),{'currentVersion':_0x57e9c6[_0x11fd71(0x127)],'stableVersion':_0x57e9c6[_0x11fd71(0x12b)],'needsUpgrade':_0x57e9c6[_0x11fd71(0x11a)]}));});},[]);const _0xe31ece=async _0x153e74=>{const _0x3d016f=a44_0x3c97;if(!_0x153e74[_0x3d016f(0x120)]||_0x153e74['projectName'][_0x3d016f(0x149)]()===''){console[_0x3d016f(0x160)](_0x3d016f(0x156));return;}const _0x34f591=/[<>:"|?*\x00-\x1f\x7f]/;if(_0x34f591['test'](_0x153e74['projectName'])){console[_0x3d016f(0x160)](_0x3d016f(0x173));return;}if(_0x153e74[_0x3d016f(0x120)][_0x3d016f(0x17c)]>0x64){console[_0x3d016f(0x160)](_0x3d016f(0x115));return;}const _0x4d45a6=a44_0x2f616d[_0x3d016f(0x17f)](process['cwd'](),_0x153e74[_0x3d016f(0x120)]);if(a44_0x18f95e[_0x3d016f(0x171)](_0x4d45a6)){console[_0x3d016f(0x160)]('×\x20项目目录\x20'+_0x153e74[_0x3d016f(0x120)]+_0x3d016f(0x12e));return;}try{const _0x250248=a44_0x2f616d[_0x3d016f(0x15a)](_0x4d45a6);a44_0x18f95e['accessSync'](_0x250248,a44_0x18f95e['constants'][_0x3d016f(0x131)]);}catch(_0x3cb1ba){console['error'](_0x3d016f(0x181));return;}_0x2417c1(_0x153e74),_0x5edd57(!![]),logger[_0x3d016f(0x18a)](_0x4d45a6),logger['info'](_0x3d016f(0x13c),_0x3d016f(0x14a)+_0x153e74[_0x3d016f(0x120)],{'projectDir':_0x4d45a6,'appCode':_0x153e74[_0x3d016f(0x15c)]});try{await _0x216194['doTask'](_0x153e74[_0x3d016f(0x120)]),await _0x13f58d(_0x153e74[_0x3d016f(0x120)]),await _0x273e90[_0x3d016f(0x13a)](_0x153e74[_0x3d016f(0x120)]),await _0x4a4446[_0x3d016f(0x13a)](_0x153e74['projectName']),await _0x3e9432(_0x153e74['projectName'],_0x153e74[_0x3d016f(0x15c)]||'',_0x153e74[_0x3d016f(0x167)]);if(_0x153e74['pullApi']&&_0x153e74['appCode']){console[_0x3d016f(0x14e)](_0x3d016f(0x180));try{const _0x3d4fd4=await pullApiSilent(_0x153e74[_0x3d016f(0x15c)],undefined,_0x4d45a6,_0x153e74[_0x3d016f(0x167)]);_0x3d4fd4?(console[_0x3d016f(0x14e)](_0x3d016f(0x12a)),logger['info']('create',_0x3d016f(0x11c)+_0x153e74[_0x3d016f(0x15c)])):(console['log'](_0x3d016f(0x159)),logger[_0x3d016f(0x119)](_0x3d016f(0x13c),_0x3d016f(0x154)+_0x153e74[_0x3d016f(0x15c)]));}catch(_0x2e45df){console['log'](_0x3d016f(0x188)),logger[_0x3d016f(0x119)](_0x3d016f(0x13c),'API\x20配置拉取异常',{'error':_0x2e45df instanceof Error?_0x2e45df[_0x3d016f(0x15b)]:String(_0x2e45df)});}}if(_0x153e74['aiSetup']&&_0x153e74[_0x3d016f(0x15f)]&&_0x153e74[_0x3d016f(0x15f)][_0x3d016f(0x17c)]>0x0&&_0x153e74['appCode']){console[_0x3d016f(0x14e)](_0x3d016f(0x176));const _0x31db9e=[],_0x242b9d=[],_0x51311a=_0x153e74[_0x3d016f(0x15f)][_0x3d016f(0x186)](_0x201596=>MCP_IDES['has'](_0x201596)),_0xbf32bd=_0x153e74[_0x3d016f(0x15f)];for(const _0x5789b8 of _0x51311a){try{const _0x5ed53f=await configureMcp(_0x5789b8,_0x4d45a6);_0x31db9e[_0x3d016f(0x11e)]({'ide':_0x5789b8===_0x3d016f(0x145)?_0x3d016f(0x179):'Claude\x20Code','status':_0x5ed53f['status'],'message':_0x5ed53f['message']}),console[_0x3d016f(0x14e)]('\x20\x20'+(_0x5ed53f[_0x3d016f(0x14d)]===_0x3d016f(0x113)?'✓':_0x5ed53f[_0x3d016f(0x14d)]===_0x3d016f(0x138)?'⚠️':'✗')+_0x3d016f(0x129)+_0x5789b8+':\x20'+_0x5ed53f[_0x3d016f(0x15b)]);}catch(_0x298156){_0x31db9e['push']({'ide':_0x5789b8===_0x3d016f(0x145)?'Cursor':_0x3d016f(0x118),'status':_0x3d016f(0x160),'message':_0x298156 instanceof Error?_0x298156[_0x3d016f(0x15b)]:String(_0x298156)}),console[_0x3d016f(0x14e)](_0x3d016f(0x16e)+_0x5789b8+':\x20'+(_0x298156 instanceof Error?_0x298156[_0x3d016f(0x15b)]:String(_0x298156)));}}await copySharedSkills(_0x4d45a6);for(const _0x29b629 of _0xbf32bd){try{const _0x5c10d0=await installSkill(_0x29b629,_0x4d45a6);_0x242b9d['push']({'ide':_0x5c10d0[_0x3d016f(0x164)],'status':_0x5c10d0[_0x3d016f(0x14d)],'message':_0x5c10d0[_0x3d016f(0x15b)]}),console[_0x3d016f(0x14e)]('\x20\x20'+(_0x5c10d0[_0x3d016f(0x14d)]===_0x3d016f(0x113)?'✓':'✗')+_0x3d016f(0x16a)+_0x5c10d0[_0x3d016f(0x164)]+':\x20'+_0x5c10d0[_0x3d016f(0x15b)]);}catch(_0xefabf0){_0x242b9d['push']({'ide':_0x29b629,'status':_0x3d016f(0x160),'message':_0xefabf0 instanceof Error?_0xefabf0['message']:String(_0xefabf0)}),console['log'](_0x3d016f(0x124)+_0x29b629+':\x20'+(_0xefabf0 instanceof Error?_0xefabf0[_0x3d016f(0x15b)]:String(_0xefabf0)));}}if(_0x242b9d[_0x3d016f(0x17c)]>0x0){const _0x3e764d=_0x242b9d[_0x3d016f(0x186)](_0x770db9=>_0x770db9[_0x3d016f(0x14d)]===_0x3d016f(0x113))[_0x3d016f(0x11b)](_0x334f4f=>_0x334f4f[_0x3d016f(0x164)]);_0x3e764d[_0x3d016f(0x17c)]>0x0&&createSkillManifest(_0x4d45a6,_0x3e764d);}_0x53b016({'mcp':_0x31db9e,'skill':_0x242b9d}),console[_0x3d016f(0x14e)]('√\x20Lovrabet\x20MCP\x20和\x20Skill\x20配置完成');}logger['success'](_0x3d016f(0x13c),'项目创建完成:\x20'+_0x153e74[_0x3d016f(0x120)]),_0x3f332c(!![]),_0x5edd57(![]);}catch(_0x1d535b){logger['error'](_0x3d016f(0x13c),_0x3d016f(0x148)+_0x153e74[_0x3d016f(0x120)],{'error':_0x1d535b instanceof Error?_0x1d535b['message']:String(_0x1d535b)});try{a44_0x18f95e[_0x3d016f(0x171)](_0x4d45a6)&&(console[_0x3d016f(0x14e)](_0x3d016f(0x11f)+_0x4d45a6),a44_0x18f95e['rmSync'](_0x4d45a6,{'recursive':!![],'force':!![]}));}catch(_0x577955){logger[_0x3d016f(0x119)](_0x3d016f(0x13c),_0x3d016f(0x184)+_0x4d45a6);}_0x5edd57(![]),console[_0x3d016f(0x160)](_0x3d016f(0x150)+(_0x1d535b instanceof Error?_0x1d535b[_0x3d016f(0x15b)]:String(_0x1d535b)));}},_0x5c241a=async _0xb365e9=>{const _0x1667db=a44_0x3c97;await _0xe31ece({'projectName':_0xb365e9,'env':_0x2c38c8[_0x1667db(0x167)]});},_0x13f58d=async _0x1753f3=>{const _0x3860c=a44_0x3c97,_0x1bfa1b=a44_0x2f616d['resolve'](process[_0x3860c(0x15e)](),_0x1753f3),_0x44309b=a44_0x2f616d[_0x3860c(0x14f)](_0x1bfa1b,_0x3860c(0x183));try{console[_0x3860c(0x14e)](_0x3860c(0x189));const _0x172a4e=fileURLToPath(import.meta.url),_0x25de95=a44_0x2f616d['resolve'](a44_0x2f616d['dirname'](_0x172a4e),_0x3860c(0x11d)),_0x14eac9=a44_0x2f616d['join'](_0x25de95,'package.json');let _0x551cf3='1.0.0';try{const _0x3aaaa8=JSON[_0x3860c(0x162)](a44_0x18f95e[_0x3860c(0x182)](_0x14eac9,'utf8'));_0x551cf3=_0x3aaaa8[_0x3860c(0x158)]||_0x3860c(0x15d);}catch(_0x1e7079){}const _0x26fd25=a44_0x18f95e[_0x3860c(0x182)](_0x44309b,'utf8'),_0x14b1d8=JSON[_0x3860c(0x162)](_0x26fd25);_0x14b1d8[_0x3860c(0x137)]=_0x1753f3,_0x14b1d8[_0x3860c(0x12d)]=_0x1753f3+_0x3860c(0x141)+_0x551cf3,a44_0x18f95e[_0x3860c(0x144)](_0x44309b,JSON[_0x3860c(0x175)](_0x14b1d8,null,0x2)+'\x0a',_0x3860c(0x14c)),console[_0x3860c(0x14e)](_0x3860c(0x12c)+_0x1753f3),logger[_0x3860c(0x16f)]('create',_0x3860c(0x146));}catch(_0x3ad5c2){logger['error'](_0x3860c(0x13c),_0x3860c(0x117));throw _0x3ad5c2;}},_0x3e9432=async(_0x2a2646,_0x5c54a0,_0x33a3cf)=>{const _0x25e493=a44_0x3c97,_0x454ba9=a44_0x2f616d['resolve'](process[_0x25e493(0x15e)](),_0x2a2646),_0x1ae573=a44_0x2f616d[_0x25e493(0x14f)](_0x454ba9,_0x25e493(0x116));try{_0x5c54a0?console[_0x25e493(0x14e)]('*\x20正在为项目\x20'+_0x2a2646+_0x25e493(0x177)+_0x5c54a0):console[_0x25e493(0x14e)](_0x25e493(0x136)+_0x2a2646+_0x25e493(0x187));const _0x517044=fileURLToPath(import.meta.url),_0x40a2b0=a44_0x2f616d[_0x25e493(0x17f)](a44_0x2f616d[_0x25e493(0x15a)](_0x517044),_0x25e493(0x11d)),_0x33a33f=a44_0x2f616d[_0x25e493(0x14f)](_0x40a2b0,_0x25e493(0x183));let _0x4a0f5a='1.0.0';try{const _0x327153=JSON['parse'](a44_0x18f95e[_0x25e493(0x182)](_0x33a33f,_0x25e493(0x14c)));_0x4a0f5a=_0x327153[_0x25e493(0x158)]||_0x25e493(0x15d);}catch(_0x3dc150){}const _0x193cd6=readConfig(),_0x1780f4=typeof _0x193cd6[_0x25e493(0x167)]==='string'?_0x193cd6[_0x25e493(0x167)]:undefined,{app:_0x3ff52b,appcode:_0x22d1de,..._0x12778a}=_0x193cd6,_0x45c576={..._0x12778a,'appcode':_0x5c54a0||'','env':_0x33a3cf||_0x1780f4||_0x25e493(0x122),'createdAt':new Date()[_0x25e493(0x142)](),'version':_0x4a0f5a};a44_0x18f95e[_0x25e493(0x144)](_0x1ae573,JSON[_0x25e493(0x175)](_0x45c576,null,0x2),'utf8'),_0x5c54a0?console[_0x25e493(0x14e)](_0x25e493(0x169)+_0x5c54a0):console['log'](_0x25e493(0x140)),logger['info'](_0x25e493(0x13c),'配置应用AppCode:\x20'+_0x5c54a0);}catch(_0x5752e2){logger[_0x25e493(0x160)](_0x25e493(0x13c),_0x25e493(0x16d));}};useEffect(()=>{const _0x2a7ddc=a44_0x3c97;_0x2c38c8[_0x2a7ddc(0x147)]&&_0x5c241a(_0x2c38c8[_0x2a7ddc(0x147)]);},[_0x2c38c8[_0x1b4b59(0x147)]]);if(!_0x4079cb&&!_0x5bc5df&&!_0x2c38c8[_0x1b4b59(0x147)])return a44_0x47b470(EnhancedGuidedCreate,{'onCreate':_0xe31ece,'env':_0x2c38c8['env']});if(_0x4079cb)return a44_0x28b5d1(a44_0x5e98d8,{'children':[a44_0x28b5d1(Box,{'marginTop':0x1,'children':[a44_0x47b470(Box,{'width':'1'}),a44_0x47b470(Text,{'color':_0x1b4b59(0x155),'children':'\x20√\x20'}),a44_0x47b470(Text,{'children':_0x1b4b59(0x18b)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x155),'children':_0x44113c?.['projectName']}),_0x44113c?.['appCode']&&a44_0x28b5d1(a44_0x5e98d8,{'children':[a44_0x47b470(Text,{'children':_0x1b4b59(0x139)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x123),'children':_0x44113c[_0x1b4b59(0x15c)]})]})]}),a44_0x47b470(TaskRunning,{..._0x216194}),a44_0x47b470(TaskRunning,{..._0x273e90}),a44_0x47b470(TaskRunning,{..._0x4a4446})]});if(_0x5bc5df){const _0x1d883b=_0x585443&&(_0x585443[_0x1b4b59(0x166)][_0x1b4b59(0x17c)]>0x0||_0x585443[_0x1b4b59(0x16b)][_0x1b4b59(0x17c)]>0x0);return a44_0x28b5d1(a44_0x5e98d8,{'children':[a44_0x28b5d1(Box,{'marginTop':0x1,'children':[a44_0x47b470(Box,{'width':'1'}),a44_0x47b470(Text,{'color':'green','children':_0x1b4b59(0x163)}),a44_0x47b470(Text,{'children':_0x1b4b59(0x18b)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x155),'children':_0x44113c?.['projectName']}),_0x44113c?.[_0x1b4b59(0x15c)]&&a44_0x28b5d1(a44_0x5e98d8,{'children':[a44_0x47b470(Text,{'children':_0x1b4b59(0x139)}),a44_0x47b470(Text,{'color':'cyan','children':_0x44113c['appCode']})]})]}),a44_0x47b470(TaskFinished,{..._0x216194}),a44_0x47b470(TaskFinished,{..._0x273e90}),a44_0x47b470(TaskFinished,{..._0x4a4446}),a44_0x47b470(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a44_0x47b470(Text,{'color':'green','children':'─'[_0x1b4b59(0x161)](0x3c)})}),_0x1d883b&&a44_0x28b5d1(a44_0x5e98d8,{'children':[_0x585443['mcp'][_0x1b4b59(0x17c)]>0x0&&a44_0x28b5d1(a44_0x5e98d8,{'children':[a44_0x47b470(Box,{'marginTop':0x1,'children':a44_0x47b470(Text,{'color':_0x1b4b59(0x155),'bold':!![],'children':_0x1b4b59(0x153)})}),_0x585443[_0x1b4b59(0x166)][_0x1b4b59(0x11b)]((_0x4922c2,_0x1e3c50)=>a44_0x47b470(Box,{'marginLeft':0x2,'children':a44_0x28b5d1(Text,{'color':_0x4922c2[_0x1b4b59(0x14d)]===_0x1b4b59(0x113)?_0x1b4b59(0x16c):_0x4922c2[_0x1b4b59(0x14d)]===_0x1b4b59(0x138)?_0x1b4b59(0x130):_0x1b4b59(0x165),'children':[_0x4922c2[_0x1b4b59(0x164)],':\x20',_0x4922c2[_0x1b4b59(0x15b)]]})},'mcp-'+_0x1e3c50))]}),_0x585443['skill']['length']>0x0&&a44_0x28b5d1(a44_0x5e98d8,{'children':[a44_0x47b470(Box,{'marginTop':_0x585443[_0x1b4b59(0x166)][_0x1b4b59(0x17c)]>0x0?0x1:0x0,'children':a44_0x47b470(Text,{'color':'green','bold':!![],'children':'✓\x20Skill\x20安装完成:'})}),_0x585443['skill']['map']((_0x1ca311,_0x14f59d)=>a44_0x47b470(Box,{'marginLeft':0x2,'children':a44_0x28b5d1(Text,{'color':_0x1ca311[_0x1b4b59(0x14d)]===_0x1b4b59(0x113)?_0x1b4b59(0x16c):'red','children':[_0x1ca311[_0x1b4b59(0x164)],':\x20',_0x1ca311[_0x1b4b59(0x15b)]]})},_0x1b4b59(0x14b)+_0x14f59d))]}),a44_0x47b470(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a44_0x47b470(Text,{'color':'green','children':'─'[_0x1b4b59(0x161)](0x3c)})})]}),a44_0x47b470(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a44_0x47b470(Text,{'color':_0x1b4b59(0x123),'bold':!![],'children':_0x1b4b59(0x178)})}),a44_0x28b5d1(Box,{'marginLeft':0x2,'flexDirection':'column','children':[_0x1d883b?a44_0x28b5d1(a44_0x5e98d8,{'children':[a44_0x28b5d1(Box,{'children':[a44_0x47b470(Text,{'color':_0x1b4b59(0x155),'children':'1.\x20'}),a44_0x47b470(Text,{'color':_0x1b4b59(0x16c),'children':_0x1b4b59(0x157)}),a44_0x47b470(Text,{'color':'cyan','bold':!![],'children':'cd\x20'+_0x44113c?.[_0x1b4b59(0x120)]+_0x1b4b59(0x128)})]}),_0x44113c?.[_0x1b4b59(0x15c)]&&!_0x44113c?.[_0x1b4b59(0x185)]&&a44_0x28b5d1(Box,{'children':[a44_0x47b470(Text,{'color':_0x1b4b59(0x130),'children':_0x1b4b59(0x168)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x16c),'children':_0x1b4b59(0x152)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x123),'bold':!![],'children':_0x1b4b59(0x17d)})]})]}):a44_0x28b5d1(a44_0x5e98d8,{'children':[a44_0x47b470(Box,{'children':a44_0x47b470(Text,{'color':'yellow','bold':!![],'children':_0x1b4b59(0x13f)})}),a44_0x28b5d1(Box,{'marginLeft':0x2,'marginTop':0x1,'children':[a44_0x47b470(Text,{'color':_0x1b4b59(0x16c),'children':_0x1b4b59(0x125)}),a44_0x47b470(Text,{'color':'cyan','bold':!![],'children':_0x1b4b59(0x126)})]}),a44_0x28b5d1(Box,{'marginLeft':0x2,'children':[a44_0x47b470(Text,{'color':_0x1b4b59(0x16c),'children':_0x1b4b59(0x112)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x123),'bold':!![],'children':_0x1b4b59(0x17b)})]}),a44_0x28b5d1(Box,{'marginTop':0x1,'children':[a44_0x47b470(Text,{'color':_0x1b4b59(0x155),'children':_0x1b4b59(0x168)}),a44_0x47b470(Text,{'color':'white','children':'启动项目:\x20'}),a44_0x47b470(Text,{'color':'cyan','bold':!![],'children':_0x1b4b59(0x134)+_0x44113c?.[_0x1b4b59(0x120)]+_0x1b4b59(0x128)})]}),_0x44113c?.[_0x1b4b59(0x15c)]&&!_0x44113c?.[_0x1b4b59(0x185)]&&a44_0x28b5d1(Box,{'children':[a44_0x47b470(Text,{'color':_0x1b4b59(0x130),'children':_0x1b4b59(0x114)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x16c),'children':_0x1b4b59(0x152)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x123),'bold':!![],'children':_0x1b4b59(0x17d)})]})]}),!_0x44113c?.[_0x1b4b59(0x15c)]&&a44_0x28b5d1(a44_0x5e98d8,{'children':[a44_0x28b5d1(Box,{'children':[a44_0x47b470(Text,{'color':_0x1b4b59(0x13b),'children':_0x1b4b59(0x168)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x16c),'children':_0x1b4b59(0x121)}),a44_0x47b470(Text,{'color':'cyan','bold':!![],'children':_0x1b4b59(0x174)})]}),a44_0x28b5d1(Box,{'children':[a44_0x47b470(Text,{'color':_0x1b4b59(0x13b),'children':_0x1b4b59(0x114)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x16c),'children':_0x1b4b59(0x152)}),a44_0x47b470(Text,{'color':_0x1b4b59(0x123),'bold':!![],'children':_0x1b4b59(0x133)})]})]})]}),a44_0x47b470(Box,{'marginTop':0x1,'children':a44_0x47b470(Text,{'color':_0x1b4b59(0x155),'children':'─'[_0x1b4b59(0x161)](0x3c)})})]});}return null;}
|