@lovrabet/cli 1.1.18 → 1.1.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/lib/add-page/input-page-router.js +1 -1
  2. package/lib/add-page/main.js +1 -1
  3. package/lib/add-page/select-page-template.js +1 -1
  4. package/lib/api/api-doc-ui.js +1 -1
  5. package/lib/api/api-doc.js +1 -1
  6. package/lib/api/api-pull-ui.js +1 -1
  7. package/lib/api/fetch-model-list.js +1 -1
  8. package/lib/api/generate-api-file.js +1 -1
  9. package/lib/api/main.js +1 -1
  10. package/lib/api/pull-silent.js +1 -1
  11. package/lib/app-menu/app-menu-sync-ui.js +1 -1
  12. package/lib/app-menu/create-menu.js +1 -1
  13. package/lib/app-menu/get-local-pages.js +1 -1
  14. package/lib/app-menu/get-online-menu-list.js +1 -1
  15. package/lib/app-menu/valid-url.js +1 -1
  16. package/lib/auth/auth-server-ui.js +1 -1
  17. package/lib/auth/auth-server.js +1 -1
  18. package/lib/auth/constant.js +1 -1
  19. package/lib/auth/get-cookie.js +1 -1
  20. package/lib/auth/is-session-valid.js +1 -1
  21. package/lib/auth/logout.js +1 -1
  22. package/lib/cli.js +1 -1
  23. package/lib/cmd/build-watch.js +1 -1
  24. package/lib/cmd/build.js +1 -1
  25. package/lib/cmd/logs.js +1 -1
  26. package/lib/cmd/preview.js +1 -1
  27. package/lib/cmd/start.js +1 -1
  28. package/lib/config/config-help.js +1 -1
  29. package/lib/config/main.js +1 -1
  30. package/lib/constant/domain.js +1 -1
  31. package/lib/constant/env.js +1 -1
  32. package/lib/create-app/enhanced-guided-create.js +1 -1
  33. package/lib/create-app/format-elapsed.js +1 -1
  34. package/lib/create-app/main.js +1 -1
  35. package/lib/create-app/task-finished.js +1 -1
  36. package/lib/create-app/task-loading.js +1 -1
  37. package/lib/create-app/task-running.js +1 -1
  38. package/lib/create-app/task-time.js +1 -1
  39. package/lib/create-app/use-copy-project-template.js +1 -1
  40. package/lib/create-app/use-format-code.js +1 -1
  41. package/lib/create-app/use-install-dependencies.js +1 -1
  42. package/lib/help.js +1 -1
  43. package/lib/init/main.js +1 -1
  44. package/lib/utils/config.js +1 -1
  45. package/lib/utils/copy-directory.js +1 -1
  46. package/lib/utils/http-client.js +1 -1
  47. package/lib/utils/logger.js +1 -1
  48. package/lib/utils/router-updater.js +1 -1
  49. package/lib/utils/sleep.js +1 -1
  50. package/lib/utils/template-replacer.js +1 -1
  51. package/package.json +1 -1
  52. package/templates/projects/sub-app-react-demo/package.json +1 -1
@@ -1 +1 @@
1
- function a12_0x4072(_0x21204e,_0x4cc736){const _0x4d397c=a12_0x4d39();return a12_0x4072=function(_0x407241,_0x398cd2){_0x407241=_0x407241-0x19f;let _0x1aaa34=_0x4d397c[_0x407241];return _0x1aaa34;},a12_0x4072(_0x21204e,_0x4cc736);}const a12_0x401e7a=a12_0x4072;(function(_0x3f6e7a,_0x51a1c4){const _0x26e320=a12_0x4072,_0x13ebd5=_0x3f6e7a();while(!![]){try{const _0x2cece0=parseInt(_0x26e320(0x1a0))/0x1+parseInt(_0x26e320(0x1ab))/0x2*(-parseInt(_0x26e320(0x1b2))/0x3)+-parseInt(_0x26e320(0x1a9))/0x4*(parseInt(_0x26e320(0x1b4))/0x5)+parseInt(_0x26e320(0x1a5))/0x6+-parseInt(_0x26e320(0x1ac))/0x7*(parseInt(_0x26e320(0x1b1))/0x8)+-parseInt(_0x26e320(0x1b3))/0x9*(-parseInt(_0x26e320(0x1af))/0xa)+parseInt(_0x26e320(0x1a8))/0xb;if(_0x2cece0===_0x51a1c4)break;else _0x13ebd5['push'](_0x13ebd5['shift']());}catch(_0x4cc884){_0x13ebd5['push'](_0x13ebd5['shift']());}}}(a12_0x4d39,0x9517d));import{readdirSync,statSync,readFileSync}from'fs';import{join,relative,resolve}from'path';const pagesDir=resolve(process[a12_0x401e7a(0x19f)](),a12_0x401e7a(0x1b0));export function extractTitleFromComment(_0x2b1f00){const _0x436d9d=a12_0x401e7a;try{const _0x428180=readFileSync(_0x2b1f00,_0x436d9d(0x1a3)),_0x436bd8=_0x428180[_0x436d9d(0x1a1)](/^\s*\/\*\*?([\s\S]*?)\*\//);if(_0x436bd8&&_0x436bd8[0x1]){const _0xfb4be3=_0x436bd8[0x1],_0x3161a4=_0xfb4be3[_0x436d9d(0x1a1)](/^\s*\*?\s*title\s*:\s*(.+)/im);if(_0x3161a4&&_0x3161a4[0x1])return _0x3161a4[0x1]['trim']();}let _0x282824=null;const _0x3ad3a0=_0x428180['match'](/export\s+default\s+([A-Z][a-zA-Z0-9]*)/);_0x3ad3a0&&_0x3ad3a0[0x1]&&(_0x282824=_0x3ad3a0[0x1]);if(!_0x282824){const _0x584872=_0x428180['match'](/export\s+default\s+function\s+([A-Z][a-zA-Z0-9]*)/);_0x584872&&_0x584872[0x1]&&(_0x282824=_0x584872[0x1]);}if(_0x282824){const _0x2f626f=new RegExp('\x5cb'+_0x282824+_0x436d9d(0x1a4)),_0x49383a=_0x428180['match'](_0x2f626f);if(_0x49383a&&_0x49383a[0x1])return _0x49383a[0x1];return _0x282824;}return null;}catch(_0x353ecf){return null;}}function a12_0x4d39(){const _0x2f0483=['2552803tjUArS','1132yaPNdb','forEach','754612uivtfn','7vEfxcS','concat','endsWith','10gZewGf','src/pages','4259720YXkIoX','9NLdvlq','9550449tmNjNY','4240sCZbCl','cwd','904524hxezij','match','replace','utf-8','\x5c.displayName\x5cs*=\x5cs*[\x22\x27]([^\x22\x27]+)[\x22\x27]','1903764MIuaDW','push','filter'];a12_0x4d39=function(){return _0x2f0483;};return a12_0x4d39();}export function getLocalPages(_0x25b28c=pagesDir,_0x171cbf=pagesDir){const _0x4c4cb4=a12_0x401e7a;let _0x16b644=[];const _0x164725=readdirSync(_0x25b28c);return _0x164725[_0x4c4cb4(0x1aa)](_0x13c4a9=>{const _0x188b42=_0x4c4cb4,_0x3fd233=join(_0x25b28c,_0x13c4a9),_0x1128dd=statSync(_0x3fd233);if(_0x1128dd&&_0x1128dd['isDirectory']())_0x16b644=_0x16b644[_0x188b42(0x1ad)](getLocalPages(_0x3fd233,_0x171cbf));else{if(_0x13c4a9[_0x188b42(0x1ae)]('.tsx')){let _0x1f7f19=relative(_0x171cbf,_0x3fd233);_0x1f7f19[_0x188b42(0x1ae)]('index.tsx')?_0x1f7f19=_0x1f7f19[_0x188b42(0x1a2)](/index\.tsx$/,''):_0x1f7f19=_0x1f7f19[_0x188b42(0x1a2)](/\.tsx$/,'');_0x1f7f19[_0x188b42(0x1ae)]('/')&&(_0x1f7f19=_0x1f7f19['slice'](0x0,-0x1));const _0x10b1ae=extractTitleFromComment(_0x3fd233),_0x2699fa=_0x10b1ae||_0x1f7f19;_0x16b644[_0x188b42(0x1a6)]({'path':_0x1f7f19,'label':_0x2699fa});}}}),_0x16b644[_0x4c4cb4(0x1a7)](_0x27acb3=>_0x27acb3['path']!=='');}
1
+ const a12_0x1ace1a=a12_0x2429;(function(_0x2b25b,_0x42954f){const _0x43db28=a12_0x2429,_0x3d931a=_0x2b25b();while(!![]){try{const _0x251a65=parseInt(_0x43db28(0xfd))/0x1+parseInt(_0x43db28(0x104))/0x2+-parseInt(_0x43db28(0xfe))/0x3+-parseInt(_0x43db28(0x100))/0x4*(parseInt(_0x43db28(0x103))/0x5)+-parseInt(_0x43db28(0xf4))/0x6+parseInt(_0x43db28(0xff))/0x7*(-parseInt(_0x43db28(0xfb))/0x8)+-parseInt(_0x43db28(0x106))/0x9*(-parseInt(_0x43db28(0x101))/0xa);if(_0x251a65===_0x42954f)break;else _0x3d931a['push'](_0x3d931a['shift']());}catch(_0x89d417){_0x3d931a['push'](_0x3d931a['shift']());}}}(a12_0x2d9e,0xd555e));import{readdirSync,statSync,readFileSync}from'fs';function a12_0x2d9e(){const _0x48c536=['trim','match','2573316ZqSnoJ','forEach','endsWith','\x5c.displayName\x5cs*=\x5cs*[\x22\x27]([^\x22\x27]+)[\x22\x27]','utf-8','push','isDirectory','3607736LjZDgb','index.tsx','483228VStSLu','4865670RdKgDD','21RRaPRX','4SmhIaK','41935090nZfCNa','path','2153465qTkPiu','62910MvUtPr','cwd','9JkzBly','.tsx','concat','replace'];a12_0x2d9e=function(){return _0x48c536;};return a12_0x2d9e();}function a12_0x2429(_0x22f4f0,_0x34816f){const _0x2d9eb1=a12_0x2d9e();return a12_0x2429=function(_0x242964,_0x4e30ae){_0x242964=_0x242964-0xf0;let _0x2e52ff=_0x2d9eb1[_0x242964];return _0x2e52ff;},a12_0x2429(_0x22f4f0,_0x34816f);}import{join,relative,resolve}from'path';const pagesDir=resolve(process[a12_0x1ace1a(0x105)](),'src/pages');export function extractTitleFromComment(_0x453422){const _0x301ce6=a12_0x1ace1a;try{const _0x1bfb7e=readFileSync(_0x453422,_0x301ce6(0xf8)),_0x20495d=_0x1bfb7e[_0x301ce6(0xf3)](/^\s*\/\*\*?([\s\S]*?)\*\//);if(_0x20495d&&_0x20495d[0x1]){const _0x3f4765=_0x20495d[0x1],_0x45a90e=_0x3f4765[_0x301ce6(0xf3)](/^\s*\*?\s*title\s*:\s*(.+)/im);if(_0x45a90e&&_0x45a90e[0x1])return _0x45a90e[0x1][_0x301ce6(0xf2)]();}let _0x4dde6e=null;const _0xf4f3b3=_0x1bfb7e[_0x301ce6(0xf3)](/export\s+default\s+([A-Z][a-zA-Z0-9]*)/);_0xf4f3b3&&_0xf4f3b3[0x1]&&(_0x4dde6e=_0xf4f3b3[0x1]);if(!_0x4dde6e){const _0x47a36e=_0x1bfb7e['match'](/export\s+default\s+function\s+([A-Z][a-zA-Z0-9]*)/);_0x47a36e&&_0x47a36e[0x1]&&(_0x4dde6e=_0x47a36e[0x1]);}if(_0x4dde6e){const _0x413f87=new RegExp('\x5cb'+_0x4dde6e+_0x301ce6(0xf7)),_0x456a51=_0x1bfb7e[_0x301ce6(0xf3)](_0x413f87);if(_0x456a51&&_0x456a51[0x1])return _0x456a51[0x1];return _0x4dde6e;}return null;}catch(_0x931634){return null;}}export function getLocalPages(_0x1f05cc=pagesDir,_0x297f87=pagesDir){const _0x2c37f0=a12_0x1ace1a;let _0x216dc3=[];const _0x5caed4=readdirSync(_0x1f05cc);return _0x5caed4[_0x2c37f0(0xf5)](_0x1863ac=>{const _0x2ea326=_0x2c37f0,_0x23cb97=join(_0x1f05cc,_0x1863ac),_0x4f0d03=statSync(_0x23cb97);if(_0x4f0d03&&_0x4f0d03[_0x2ea326(0xfa)]())_0x216dc3=_0x216dc3[_0x2ea326(0xf0)](getLocalPages(_0x23cb97,_0x297f87));else{if(_0x1863ac[_0x2ea326(0xf6)](_0x2ea326(0x107))){let _0x2395fd=relative(_0x297f87,_0x23cb97);_0x2395fd['endsWith'](_0x2ea326(0xfc))?_0x2395fd=_0x2395fd['replace'](/index\.tsx$/,''):_0x2395fd=_0x2395fd[_0x2ea326(0xf1)](/\.tsx$/,'');_0x2395fd[_0x2ea326(0xf6)]('/')&&(_0x2395fd=_0x2395fd['slice'](0x0,-0x1));const _0x318a05=extractTitleFromComment(_0x23cb97),_0x3f3c93=_0x318a05||_0x2395fd;_0x216dc3[_0x2ea326(0xf9)]({'path':_0x2395fd,'label':_0x3f3c93});}}}),_0x216dc3['filter'](_0x4639fa=>_0x4639fa[_0x2c37f0(0x102)]!=='');}
@@ -1 +1 @@
1
- function a13_0x1071(){const _0x561156=['780352nVlgOL','3430074vMIBcY','then','!\x20请使用以下方式之一:','error','\x20\x20\x202.\x20配置默认值:\x20lovrabet\x20config\x20set\x20app\x20<app-code>','1448935ZKaIDa','path','map','json','567517hbStWo','672875wwDDvx','log','1766004iCLBoW','×\x20未提供应用AppCode,且配置中也没有默认值','GET','label','application/json','1545804yPgzfe','finally','\x20\x20\x201.\x20直接指定:\x20lovrabet\x20api\x20pull\x20<app-code>'];a13_0x1071=function(){return _0x561156;};return a13_0x1071();}(function(_0x12b5c6,_0x3b84cc){const _0x2e762c=a13_0x3b3f,_0x1e08a7=_0x12b5c6();while(!![]){try{const _0x4393ea=-parseInt(_0x2e762c(0xc4))/0x1+parseInt(_0x2e762c(0xba))/0x2+parseInt(_0x2e762c(0xb7))/0x3+parseInt(_0x2e762c(0xb2))/0x4+parseInt(_0x2e762c(0xc0))/0x5+-parseInt(_0x2e762c(0xbb))/0x6+-parseInt(_0x2e762c(0xc5))/0x7;if(_0x4393ea===_0x3b84cc)break;else _0x1e08a7['push'](_0x1e08a7['shift']());}catch(_0x257fe7){_0x1e08a7['push'](_0x1e08a7['shift']());}}}(a13_0x1071,0x62003));import{useEffect,useState}from'react';import{getCookie}from'../auth/get-cookie.js';import{getApiDomain}from'../constant/domain.js';import{readConfig}from'../utils/config.js';function a13_0x3b3f(_0x1f5334,_0x574a36){const _0x107151=a13_0x1071();return a13_0x3b3f=function(_0x3b3fbf,_0xad0c88){_0x3b3fbf=_0x3b3fbf-0xb2;let _0x553699=_0x107151[_0x3b3fbf];return _0x553699;},a13_0x3b3f(_0x1f5334,_0x574a36);}const config=readConfig();export async function getOnlineMenuList(){const _0xbae353=a13_0x3b3f,_0x35e60d=config?.['appcode'];if(!_0x35e60d)return console[_0xbae353(0xbe)](_0xbae353(0xb3)),console[_0xbae353(0xc6)](_0xbae353(0xbd)),console['log'](_0xbae353(0xb9)),console[_0xbae353(0xc6)](_0xbae353(0xbf)),[];const _0x2531c1=await fetch(getApiDomain()+'/smartapi/menu/find?appCode='+_0x35e60d,{'method':_0xbae353(0xb4),'headers':{'Content-Type':_0xbae353(0xb6),'Cookie':getCookie()}});if(_0x2531c1['ok']){const {data:_0x2c9d2b}=await _0x2531c1[_0xbae353(0xc3)]();return _0x2c9d2b[_0xbae353(0xc2)](_0x2d655b=>({'path':_0x2d655b[_0xbae353(0xc1)],'label':_0x2d655b[_0xbae353(0xb5)]}));}return[];}export function useGetOnlineMenuList(){const [_0xcafe5a,_0x78432d]=useState([]),[_0x33132e,_0x3af292]=useState(!![]);return useEffect(()=>{const _0x44465c=a13_0x3b3f;_0x3af292(!![]),getOnlineMenuList()[_0x44465c(0xbc)](_0x78432d)[_0x44465c(0xb8)](()=>_0x3af292(![]));},[]),{'menuList':_0xcafe5a,'loading':_0x33132e};}
1
+ (function(_0x59da33,_0x548df8){const _0x596ed3=a13_0x490c,_0x5dadb8=_0x59da33();while(!![]){try{const _0xc472f7=-parseInt(_0x596ed3(0xad))/0x1*(parseInt(_0x596ed3(0xc1))/0x2)+-parseInt(_0x596ed3(0xbe))/0x3+-parseInt(_0x596ed3(0xc4))/0x4*(-parseInt(_0x596ed3(0xbf))/0x5)+parseInt(_0x596ed3(0xa4))/0x6*(parseInt(_0x596ed3(0xa6))/0x7)+parseInt(_0x596ed3(0xb1))/0x8*(-parseInt(_0x596ed3(0xa8))/0x9)+parseInt(_0x596ed3(0xbd))/0xa*(parseInt(_0x596ed3(0xc0))/0xb)+parseInt(_0x596ed3(0xbb))/0xc*(parseInt(_0x596ed3(0xb4))/0xd);if(_0xc472f7===_0x548df8)break;else _0x5dadb8['push'](_0x5dadb8['shift']());}catch(_0x2fe35e){_0x5dadb8['push'](_0x5dadb8['shift']());}}}(a13_0x192d,0x4b2e4));import{useEffect,useState}from'react';import{getCookie}from'../auth/get-cookie.js';function a13_0x192d(){const _0x392514=['log','13734aSiwqb','正在获取线上菜单列表...\x20(appCode:\x20','9SHAzhW','获取菜单列表失败,HTTP状态码:\x20','errorCode','未知错误','errorMsg','17646CBYewV','application/json','error','status','354184rFKmcE','get-online-menu-list','finally','13mdkSzh','label','\x20\x20\x202.\x20配置默认值:\x20lovrabet\x20config\x20set\x20app\x20<app-code>','map','path','then','length','1859568misQzZ','json','672170CEHVxM','657480GBWSbu','40420ZCzvRW','11nEvJPe','42SCWFXi','\x20个线上菜单','获取菜单列表失败:\x20','128ylqLbG','data','info','1410xgFONV'];a13_0x192d=function(){return _0x392514;};return a13_0x192d();}import{getApiDomain}from'../constant/domain.js';import{readConfig}from'../utils/config.js';import{logger}from'../utils/logger.js';const config=readConfig();export async function getOnlineMenuList(){const _0x5cb194=a13_0x490c,_0x29b149=config?.['appcode'];if(!_0x29b149){const _0x2e52a6='未提供应用AppCode,且配置中也没有默认值';return logger[_0x5cb194(0xaf)](_0x5cb194(0xb2),_0x2e52a6),console[_0x5cb194(0xaf)]('×\x20'+_0x2e52a6),console[_0x5cb194(0xa5)]('!\x20请使用以下方式之一:'),console['log']('\x20\x20\x201.\x20直接指定:\x20lovrabet\x20api\x20pull\x20<app-code>'),console[_0x5cb194(0xa5)](_0x5cb194(0xb6)),[];}logger[_0x5cb194(0xc6)](_0x5cb194(0xb2),_0x5cb194(0xa7)+_0x29b149+')');const _0x283c2e=await fetch(getApiDomain()+'/smartapi/menu/find?appCode='+_0x29b149,{'method':'GET','headers':{'Content-Type':_0x5cb194(0xae),'Cookie':getCookie()}});if(!_0x283c2e['ok']){if(_0x283c2e['status']===0x191){const _0x49f559='登录鉴权失败,登录已过期,请使用\x20lovrabet\x20auth\x20重新登录';logger[_0x5cb194(0xaf)](_0x5cb194(0xb2),_0x49f559,{'status':_0x283c2e[_0x5cb194(0xb0)]});throw new Error(_0x49f559);}const _0x3955a8=_0x5cb194(0xa9)+_0x283c2e['status'];logger['error'](_0x5cb194(0xb2),_0x3955a8);throw new Error(_0x3955a8);}const _0x1e7e4b=await _0x283c2e[_0x5cb194(0xbc)]();if(!_0x1e7e4b['success']){const _0x3d720f=_0x5cb194(0xc3)+(_0x1e7e4b[_0x5cb194(0xac)]||_0x5cb194(0xab));logger[_0x5cb194(0xaf)](_0x5cb194(0xb2),_0x3d720f,{'errorCode':_0x1e7e4b[_0x5cb194(0xaa)],'errorMsg':_0x1e7e4b[_0x5cb194(0xac)]});throw new Error(_0x3d720f);}if(!_0x1e7e4b[_0x5cb194(0xc5)])return logger[_0x5cb194(0xc6)](_0x5cb194(0xb2),'服务端返回空菜单列表'),[];return logger[_0x5cb194(0xc6)](_0x5cb194(0xb2),'成功获取\x20'+_0x1e7e4b[_0x5cb194(0xc5)][_0x5cb194(0xba)]+_0x5cb194(0xc2)),_0x1e7e4b['data'][_0x5cb194(0xb7)](_0x379447=>({'path':_0x379447[_0x5cb194(0xb8)],'label':_0x379447[_0x5cb194(0xb5)]}));}function a13_0x490c(_0x4e1dc8,_0x1decab){const _0x192d2b=a13_0x192d();return a13_0x490c=function(_0x490caa,_0x35eaa9){_0x490caa=_0x490caa-0xa4;let _0x27fab2=_0x192d2b[_0x490caa];return _0x27fab2;},a13_0x490c(_0x4e1dc8,_0x1decab);}export function useGetOnlineMenuList(){const [_0x5ce743,_0x5ecdf6]=useState([]),[_0x1386c6,_0x4360a0]=useState(!![]),[_0x4fc39f,_0x2538cc]=useState('');return useEffect(()=>{const _0x1b18cb=a13_0x490c;_0x4360a0(!![]),_0x2538cc(''),getOnlineMenuList()[_0x1b18cb(0xb9)](_0x5ecdf6)['catch'](_0x2bc14e=>{_0x2538cc(_0x2bc14e['message']||'获取菜单列表失败');})[_0x1b18cb(0xb3)](()=>_0x4360a0(![]));},[]),{'menuList':_0x5ce743,'loading':_0x1386c6,'error':_0x4fc39f};}
@@ -1 +1 @@
1
- (function(_0x5091a7,_0x41e17b){const _0x1d3cea=a15_0x29da,_0x4dab50=_0x5091a7();while(!![]){try{const _0x3b7334=-parseInt(_0x1d3cea(0xd7))/0x1*(parseInt(_0x1d3cea(0xdb))/0x2)+parseInt(_0x1d3cea(0xd8))/0x3*(-parseInt(_0x1d3cea(0xda))/0x4)+-parseInt(_0x1d3cea(0xd1))/0x5+-parseInt(_0x1d3cea(0xd3))/0x6+-parseInt(_0x1d3cea(0xd4))/0x7+parseInt(_0x1d3cea(0xd0))/0x8*(parseInt(_0x1d3cea(0xd2))/0x9)+parseInt(_0x1d3cea(0xdc))/0xa*(parseInt(_0x1d3cea(0xdd))/0xb);if(_0x3b7334===_0x41e17b)break;else _0x4dab50['push'](_0x4dab50['shift']());}catch(_0x5f082b){_0x4dab50['push'](_0x4dab50['shift']());}}}(a15_0x3bae,0xb82c0));export function isValidJsHttpsUrl(_0x12d041){const _0x580ca6=a15_0x29da;return/^https:\/\/.+\.js(\?.*)?$/[_0x580ca6(0xd6)](_0x12d041[_0x580ca6(0xd9)]());}function a15_0x29da(_0x37f4cc,_0x1089e8){const _0x3bae41=a15_0x3bae();return a15_0x29da=function(_0x29da8a,_0x25e2e6){_0x29da8a=_0x29da8a-0xd0;let _0x316646=_0x3bae41[_0x29da8a];return _0x316646;},a15_0x29da(_0x37f4cc,_0x1089e8);}export function isValidCssHttpsUrl(_0x290281){const _0x44c446=a15_0x29da;return/^https:\/\/.+\.css(\?.*)?$/[_0x44c446(0xd6)](_0x290281['trim']());}function a15_0x3bae(){const _0x66aef3=['trim','4689964wOeNDh','76078zblqKu','1450fQggpZ','329197pewFTK','12744BqGYnx','2574830jKqEFr','2043qUyrYj','5586648EVVkCS','3704918oMYjCz','HEAD','test','21YUfaAX','3NmWZtW'];a15_0x3bae=function(){return _0x66aef3;};return a15_0x3bae();}export async function isUrlReachable(_0x380ae4){const _0x36cbb9=a15_0x29da;try{const _0x4dd033=await fetch(_0x380ae4,{'method':_0x36cbb9(0xd5)});return _0x4dd033['ok'];}catch{return![];}}
1
+ (function(_0x4e3734,_0x57adec){const _0x25cd9b=a15_0x1b90,_0x14d95e=_0x4e3734();while(!![]){try{const _0x185a88=parseInt(_0x25cd9b(0x1e6))/0x1+parseInt(_0x25cd9b(0x1e3))/0x2+-parseInt(_0x25cd9b(0x1e7))/0x3*(parseInt(_0x25cd9b(0x1e0))/0x4)+-parseInt(_0x25cd9b(0x1e2))/0x5+-parseInt(_0x25cd9b(0x1e1))/0x6*(-parseInt(_0x25cd9b(0x1dd))/0x7)+parseInt(_0x25cd9b(0x1de))/0x8*(parseInt(_0x25cd9b(0x1dc))/0x9)+-parseInt(_0x25cd9b(0x1e4))/0xa;if(_0x185a88===_0x57adec)break;else _0x14d95e['push'](_0x14d95e['shift']());}catch(_0x1d5e20){_0x14d95e['push'](_0x14d95e['shift']());}}}(a15_0xf624,0x90514));export function isValidJsHttpsUrl(_0x30b5ec){const _0x3eedab=a15_0x1b90;return/^https:\/\/.+\.js(\?.*)?$/[_0x3eedab(0x1e5)](_0x30b5ec['trim']());}export function isValidCssHttpsUrl(_0x27c7bb){const _0x14264c=a15_0x1b90;return/^https:\/\/.+\.css(\?.*)?$/[_0x14264c(0x1e5)](_0x27c7bb[_0x14264c(0x1db)]());}function a15_0x1b90(_0x1c7cbc,_0x5136a5){const _0xf624db=a15_0xf624();return a15_0x1b90=function(_0x1b9004,_0x50038e){_0x1b9004=_0x1b9004-0x1db;let _0x30a0ca=_0xf624db[_0x1b9004];return _0x30a0ca;},a15_0x1b90(_0x1c7cbc,_0x5136a5);}export async function isUrlReachable(_0x517dfc){const _0x141afa=a15_0x1b90;try{const _0x4c2abe=await fetch(_0x517dfc,{'method':_0x141afa(0x1df)});return _0x4c2abe['ok'];}catch{return![];}}function a15_0xf624(){const _0x46beb9=['758268aWILJZ','3731670HdibOC','test','243851yYCgeC','996171nTQaIe','trim','747PDdOBa','154xRaWeC','18776XvhpQj','HEAD','4jKIBrV','175008WrquBg','815670xjQFXL'];a15_0xf624=function(){return _0x46beb9;};return a15_0xf624();}
@@ -1 +1 @@
1
- (function(_0x2d4524,_0x283f90){const _0x3e786d=a16_0x5042,_0x45d61b=_0x2d4524();while(!![]){try{const _0x1ac4a5=-parseInt(_0x3e786d(0x155))/0x1+-parseInt(_0x3e786d(0x150))/0x2*(parseInt(_0x3e786d(0x15d))/0x3)+-parseInt(_0x3e786d(0x158))/0x4*(-parseInt(_0x3e786d(0x156))/0x5)+-parseInt(_0x3e786d(0x14e))/0x6+parseInt(_0x3e786d(0x15e))/0x7*(parseInt(_0x3e786d(0x154))/0x8)+-parseInt(_0x3e786d(0x15b))/0x9+parseInt(_0x3e786d(0x152))/0xa*(parseInt(_0x3e786d(0x153))/0xb);if(_0x1ac4a5===_0x283f90)break;else _0x45d61b['push'](_0x45d61b['shift']());}catch(_0x440c4a){_0x45d61b['push'](_0x45d61b['shift']());}}}(a16_0x20a2,0x74150));import{jsx as a16_0x4cdc62,jsxs as a16_0x3df568}from'react/jsx-runtime';import{Text,Box,useInput,useApp}from'ink';function a16_0x5042(_0x306665,_0x576266){const _0x20a21e=a16_0x20a2();return a16_0x5042=function(_0x50424b,_0x51b569){_0x50424b=_0x50424b-0x14c;let _0x1776b1=_0x20a21e[_0x50424b];return _0x1776b1;},a16_0x5042(_0x306665,_0x576266);}import{useEffect,useState}from'react';import{getIsSessionValid}from'./is-session-valid.js';import{authServer}from'./auth-server.js';import a16_0x3dec05 from'ink-spinner';export function AuthServer(){const _0x2f86ca=a16_0x5042,{exit:_0x318556}=useApp(),[_0x55c181,_0x42e6e4]=useState(![]),[_0x35b2f0,_0x5b3995]=useState(!![]),[_0x2cca3f,_0x271ede]=useState(![]),[_0x5573a0,_0x56bd9b]=useState(![]);useEffect(()=>{const _0x448c7a=a16_0x5042;getIsSessionValid()['then'](_0x42e6e4)[_0x448c7a(0x15f)](()=>_0x5b3995(![]));},[]),useEffect(()=>{!_0x35b2f0&&_0x55c181&&(console['log']('√\x20当前为有效会话,无需重新登录。'),_0x318556());},[_0x35b2f0,_0x55c181,_0x318556]),useEffect(()=>{const _0x4a4c16=a16_0x5042;_0x5573a0&&(console[_0x4a4c16(0x157)](_0x4a4c16(0x15a)),_0x318556());},[_0x5573a0,_0x318556]),useInput((_0x209dc0,_0x46e9bb)=>{const _0x390923=a16_0x5042;_0x46e9bb[_0x390923(0x159)]&&(_0x271ede(!![]),authServer({'silent':!![]})['then'](_0x50d303=>{_0x56bd9b(_0x50d303);})),_0x209dc0==='q'&&_0x318556();});if(_0x35b2f0)return null;if(_0x55c181||_0x5573a0)return null;return a16_0x4cdc62(Box,{'flexDirection':_0x2f86ca(0x14c),'marginTop':0x1,'marginBottom':0x1,'children':_0x2cca3f?a16_0x3df568(Box,{'children':[a16_0x4cdc62(Box,{'width':'1'}),a16_0x3df568(Text,{'color':'green','children':[a16_0x4cdc62(a16_0x3dec05,{'type':'dots'}),'\x20\x20']}),a16_0x4cdc62(Text,{'children':_0x2f86ca(0x14f)}),a16_0x4cdc62(Text,{'color':_0x2f86ca(0x15c),'children':'请前往浏览器完成登录。'})]}):a16_0x3df568(Box,{'children':[a16_0x4cdc62(Box,{'width':'1'}),a16_0x4cdc62(Text,{'children':_0x2f86ca(0x151)}),a16_0x4cdc62(Text,{'color':'gray','children':_0x2f86ca(0x14d)})]})});}function a16_0x20a2(){const _0x4a9245=['4313992OttceK','855127ZPMlFk','250vsRPhq','log','20444EtMdCz','return','*\x20登录成功!','6657804KKXdQb','gray','49782RFlXtv','7FRaQaq','finally','column','按\x20“q”\x20退出。','3494268RkEIJn','正在登录...\x20','110LCiYhQ','*\x20按回车开始登录。','27706040TcJQnw','11OXFxJZ'];a16_0x20a2=function(){return _0x4a9245;};return a16_0x20a2();}
1
+ (function(_0x39082d,_0x56748e){const _0x4ed400=a16_0x4451,_0xaa96ff=_0x39082d();while(!![]){try{const _0x127cf2=-parseInt(_0x4ed400(0x73))/0x1*(-parseInt(_0x4ed400(0x82))/0x2)+-parseInt(_0x4ed400(0x7d))/0x3+parseInt(_0x4ed400(0x6f))/0x4*(-parseInt(_0x4ed400(0x6e))/0x5)+parseInt(_0x4ed400(0x76))/0x6+-parseInt(_0x4ed400(0x7b))/0x7+parseInt(_0x4ed400(0x75))/0x8*(parseInt(_0x4ed400(0x7e))/0x9)+parseInt(_0x4ed400(0x77))/0xa*(parseInt(_0x4ed400(0x7f))/0xb);if(_0x127cf2===_0x56748e)break;else _0xaa96ff['push'](_0xaa96ff['shift']());}catch(_0x2553d6){_0xaa96ff['push'](_0xaa96ff['shift']());}}}(a16_0x3c9a,0xba5f9));import{jsx as a16_0x500c9e,jsxs as a16_0x46a187}from'react/jsx-runtime';function a16_0x4451(_0x163d8a,_0x203dac){const _0x3c9ac3=a16_0x3c9a();return a16_0x4451=function(_0x445137,_0xd9b510){_0x445137=_0x445137-0x6c;let _0x46bff4=_0x3c9ac3[_0x445137];return _0x46bff4;},a16_0x4451(_0x163d8a,_0x203dac);}function a16_0x3c9a(){const _0x3cc490=['1150Aavsbu','green','gray','√\x20当前为有效会话,无需重新登录。','4573100ASPifP','column','607299dptDwW','3921813wkMeTK','20867WfWMWR','*\x20登录成功!','then','226328rdXEpm','log','dots','72265FRLrvF','272yUqBvn','return','*\x20按回车开始登录。','finally','9TaTMJY','请前往浏览器完成登录。','16CQCLOi','2962662oaTeyR'];a16_0x3c9a=function(){return _0x3cc490;};return a16_0x3c9a();}import{Text,Box,useInput,useApp}from'ink';import{useEffect,useState}from'react';import{getIsSessionValid}from'./is-session-valid.js';import{authServer}from'./auth-server.js';import a16_0x5c80b1 from'ink-spinner';export function AuthServer(){const _0x51df09=a16_0x4451,{exit:_0x3215f4}=useApp(),[_0x421d87,_0x543e16]=useState(![]),[_0x3d3c9d,_0x1112fd]=useState(!![]),[_0x36a67d,_0x2b1b22]=useState(![]),[_0x3fe5ab,_0x5c6877]=useState(![]);useEffect(()=>{const _0x13c815=a16_0x4451;getIsSessionValid()[_0x13c815(0x81)](_0x543e16)[_0x13c815(0x72)](()=>_0x1112fd(![]));},[]),useEffect(()=>{const _0x308122=a16_0x4451;!_0x3d3c9d&&_0x421d87&&(console[_0x308122(0x6c)](_0x308122(0x7a)),_0x3215f4());},[_0x3d3c9d,_0x421d87,_0x3215f4]),useEffect(()=>{const _0x472af5=a16_0x4451;_0x3fe5ab&&(console[_0x472af5(0x6c)](_0x472af5(0x80)),_0x3215f4());},[_0x3fe5ab,_0x3215f4]),useInput((_0xbb15cb,_0x2db29a)=>{const _0x59e0f6=a16_0x4451;_0x2db29a[_0x59e0f6(0x70)]&&(_0x2b1b22(!![]),authServer({'silent':!![]})[_0x59e0f6(0x81)](_0x44d071=>{_0x5c6877(_0x44d071);})),_0xbb15cb==='q'&&_0x3215f4();});if(_0x3d3c9d)return null;if(_0x421d87||_0x3fe5ab)return null;return a16_0x500c9e(Box,{'flexDirection':_0x51df09(0x7c),'marginTop':0x1,'marginBottom':0x1,'children':_0x36a67d?a16_0x46a187(Box,{'children':[a16_0x500c9e(Box,{'width':'1'}),a16_0x46a187(Text,{'color':_0x51df09(0x78),'children':[a16_0x500c9e(a16_0x5c80b1,{'type':_0x51df09(0x6d)}),'\x20\x20']}),a16_0x500c9e(Text,{'children':'正在登录...\x20'}),a16_0x500c9e(Text,{'color':_0x51df09(0x79),'children':_0x51df09(0x74)})]}):a16_0x46a187(Box,{'children':[a16_0x500c9e(Box,{'width':'1'}),a16_0x500c9e(Text,{'children':_0x51df09(0x71)}),a16_0x500c9e(Text,{'color':_0x51df09(0x79),'children':'按\x20“q”\x20退出。'})]})});}
@@ -1 +1 @@
1
- const a17_0x1f7cd7=a17_0x3f5f;(function(_0x23d47c,_0x4281e0){const _0x137e62=a17_0x3f5f,_0x255c5c=_0x23d47c();while(!![]){try{const _0x32df43=parseInt(_0x137e62(0x1b3))/0x1*(parseInt(_0x137e62(0x19b))/0x2)+parseInt(_0x137e62(0x1b2))/0x3*(parseInt(_0x137e62(0x1a4))/0x4)+-parseInt(_0x137e62(0x1af))/0x5+-parseInt(_0x137e62(0x1ae))/0x6*(-parseInt(_0x137e62(0x1ad))/0x7)+-parseInt(_0x137e62(0x1a3))/0x8+-parseInt(_0x137e62(0x1a0))/0x9+-parseInt(_0x137e62(0x1bf))/0xa;if(_0x32df43===_0x4281e0)break;else _0x255c5c['push'](_0x255c5c['shift']());}catch(_0x569c63){_0x255c5c['push'](_0x255c5c['shift']());}}}(a17_0x1752,0x4b844));import{writeFileSync}from'node:fs';import a17_0x20fd4b from'node:https';import{getUserDomain}from'../constant/domain.js';function a17_0x3f5f(_0x443fdd,_0x1393a7){const _0x1752ff=a17_0x1752();return a17_0x3f5f=function(_0x3f5f30,_0x50b244){_0x3f5f30=_0x3f5f30-0x196;let _0xddad9d=_0x1752ff[_0x3f5f30];return _0xddad9d;},a17_0x3f5f(_0x443fdd,_0x1393a7);}import{exec}from'node:child_process';function a17_0x1752(){const _0xa25d0d=['1609504EpZyyJ','567860DtJTMe','listen','https://dev.lovrabet.com:','address','💡\x20如果浏览器没有自动打开,请手动复制上面的登录地址到浏览器中打开','/api/auth/get-session','object','silent','✅\x20浏览器已自动打开,请在浏览器中完成登录','56kBVSYv','171366kYiHwY','1979345dWTUUz','session','text/html;\x20charset=utf-8','9rSEgGq','327hFUpeL','/sign-in?redirect=','utf-8','writeHead','127.0.0.1','error','cookie','🔗\x20请手动复制登录地址到浏览器:','<!doctype\x20html>\x0a<html>\x0a<head><meta\x20charset=\x22utf-8\x22><title>登录成功</title></head>\x0a<body>\x0a\x20\x20<div>登录成功,请返回命令行继续操作。当前窗口将在\x20<span\x20id=\x22t\x22>5</span>\x20秒内关闭。</div>\x0a\x20\x20<div\x20id=\x22manualMsg\x22\x20style=\x22display:none;margin-top:10px;color:#d00;\x22>无法自动关闭窗口,请手动关闭此标签页或窗口。</div>\x0a\x20\x20<script>\x0a\x20\x20(function(){\x0a\x20\x20\x20\x20var\x20t\x20=\x205;\x0a\x20\x20\x20\x20var\x20el\x20=\x20document.getElementById(\x27t\x27);\x0a\x20\x20\x20\x20var\x20manual\x20=\x20document.getElementById(\x27manualMsg\x27);\x0a\x20\x20\x20\x20var\x20id\x20=\x20setInterval(function(){\x0a\x20\x20\x20\x20\x20\x20t--;\x0a\x20\x20\x20\x20\x20\x20if\x20(t\x20<=\x200)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20clearInterval(id);\x0a\x20\x20\x20\x20\x20\x20\x20\x20el.textContent\x20=\x20\x270\x27;\x0a\x20\x20\x20\x20\x20\x20\x20\x20try\x20{\x20window.close();\x20}\x20catch(e)\x20{}\x0a\x20\x20\x20\x20\x20\x20\x20\x20//\x20如果自动关闭无效,显示文本提示让用户手动关闭\x0a\x20\x20\x20\x20\x20\x20\x20\x20setTimeout(function(){\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if\x20(!window.closed)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20manual.style.display\x20=\x20\x27block\x27;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20},\x20300);\x0a\x20\x20\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20el.textContent\x20=\x20String(t);\x0a\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20},\x201000);\x0a\x20\x20})();\x0a\x20\x20</script>\x0a</body>\x0a</html>','isAuth','port','end','295790SWAkFp','log','json','open\x20\x22','createServer','close','catch','Auth\x20server\x20error:','🌐\x20正在尝试自动打开浏览器...','headers','2160cMOkFR','then','darwin','user','🔐\x20正在启动登录服务...','644319IiIIpO','⚠️\x20\x20无法自动打开浏览器','https://g.yuntooai.com/cert/lovrabet-dev.json'];a17_0x1752=function(){return _0xa25d0d;};return a17_0x1752();}import{getIsSessionValid}from'./is-session-valid.js';import{cookieFile}from'./constant.js';export async function authServer(_0x23eece){const _0x17cbaf=a17_0x3f5f,_0x3d7337=_0x23eece?.[_0x17cbaf(0x1ab)]||![];if(await getIsSessionValid())return!![];const _0x2cae21=await(await fetch(_0x17cbaf(0x1a2)))[_0x17cbaf(0x1c1)]();return new Promise(async(_0x32a24f,_0x1caa66)=>{const _0x27a05a=_0x17cbaf;let _0x35ceba=0x0;const _0x4f6a19=a17_0x20fd4b[_0x27a05a(0x1c3)](_0x2cae21,async(_0x417418,_0x54cb94)=>{const _0xcd7c48=_0x27a05a,_0xaf5ab7=getUserDomain(),_0xe53922=_0x417418[_0xcd7c48(0x19a)][_0xcd7c48(0x1b9)]||'',_0x19e8e4=await fetch(_0xaf5ab7+_0xcd7c48(0x1a9),{'headers':{'cookie':_0xe53922}})[_0xcd7c48(0x19c)](_0x24308e=>_0x24308e[_0xcd7c48(0x1c1)]()),_0x52ae0e=_0x19e8e4&&_0x19e8e4[_0xcd7c48(0x1b0)]&&_0x19e8e4[_0xcd7c48(0x19e)];if(_0x52ae0e){writeFileSync(cookieFile,_0xe53922,_0xcd7c48(0x1b5)),_0x32a24f(!![]);const _0xc8fd4f=_0xcd7c48(0x1bb);_0x54cb94[_0xcd7c48(0x1b6)](0xc8,{'Content-Type':_0xcd7c48(0x1b1)}),_0x54cb94[_0xcd7c48(0x1be)](_0xc8fd4f),_0x4f6a19[_0xcd7c48(0x196)]();}else{const _0x145eb1=''+encodeURIComponent(_0xcd7c48(0x1a6)+_0x35ceba);_0x54cb94[_0xcd7c48(0x1b6)](0x12e,{'location':_0xaf5ab7+_0xcd7c48(0x1b4)+_0x145eb1}),_0x54cb94[_0xcd7c48(0x1be)]();return;}});_0x4f6a19[_0x27a05a(0x1a5)](0x0,_0x27a05a(0x1b7),()=>{const _0x59b0bf=_0x27a05a,_0x10ed8b=_0x4f6a19[_0x59b0bf(0x1a7)]();_0x35ceba=typeof _0x10ed8b===_0x59b0bf(0x1aa)&&_0x10ed8b?_0x10ed8b[_0x59b0bf(0x1bd)]:Number(_0x10ed8b);const _0x36b733=_0x59b0bf(0x1a6)+_0x35ceba;!_0x3d7337&&(console['log'](_0x59b0bf(0x19f)),console['log']('📍\x20登录地址:',_0x36b733),console[_0x59b0bf(0x1c0)](_0x59b0bf(0x199)),console[_0x59b0bf(0x1c0)](''),console[_0x59b0bf(0x1c0)](_0x59b0bf(0x1a8)),console[_0x59b0bf(0x1c0)]('')),openInBrowser(_0x36b733)[_0x59b0bf(0x19c)](_0x1675d3=>{const _0xc4d6b7=_0x59b0bf;!_0x3d7337&&(_0x1675d3?console['log'](_0xc4d6b7(0x1ac)):(console[_0xc4d6b7(0x1c0)]('⚠️\x20\x20无法自动打开浏览器'),console['log'](_0xc4d6b7(0x1ba),_0x36b733)),console[_0xc4d6b7(0x1c0)](''));})[_0x59b0bf(0x197)](()=>{const _0x5e24c0=_0x59b0bf;!_0x3d7337&&(console['log'](_0x5e24c0(0x1a1)),console[_0x5e24c0(0x1c0)]('🔗\x20请手动复制登录地址到浏览器:',_0x36b733),console['log'](''));});}),_0x4f6a19['on'](_0x27a05a(0x1b8),_0x93d1a2=>{const _0x388347=_0x27a05a;!_0x3d7337&&console[_0x388347(0x1b8)](_0x388347(0x198),_0x93d1a2),_0x1caa66(_0x93d1a2);});});}function openInBrowser(_0x57ba4e){return new Promise(_0x1faa70=>{const _0x31d559=a17_0x3f5f,_0x15a79a=process['platform'];let _0x4725c6;if(_0x15a79a==='win32')_0x4725c6='start\x20\x22\x22\x20\x22'+_0x57ba4e+'\x22';else _0x15a79a===_0x31d559(0x19d)?_0x4725c6=_0x31d559(0x1c2)+_0x57ba4e+'\x22':_0x4725c6='xdg-open\x20\x22'+_0x57ba4e+'\x22';exec(_0x4725c6,_0x186384=>{_0x186384?_0x1faa70(![]):_0x1faa70(!![]);});});}if(import.meta['main']){const isAuth=await authServer();console[a17_0x1f7cd7(0x1c0)](a17_0x1f7cd7(0x1bc),isAuth);}
1
+ const a17_0x71a32=a17_0x59ed;function a17_0x59ed(_0x56ad94,_0x820494){const _0x3291de=a17_0x3291();return a17_0x59ed=function(_0x59ed71,_0x1be569){_0x59ed71=_0x59ed71-0x160;let _0x3c4b5c=_0x3291de[_0x59ed71];return _0x3c4b5c;},a17_0x59ed(_0x56ad94,_0x820494);}(function(_0x45178b,_0x19bcae){const _0x5b6c51=a17_0x59ed,_0xd57822=_0x45178b();while(!![]){try{const _0xf2d0cd=-parseInt(_0x5b6c51(0x184))/0x1+-parseInt(_0x5b6c51(0x177))/0x2*(-parseInt(_0x5b6c51(0x176))/0x3)+parseInt(_0x5b6c51(0x18c))/0x4+-parseInt(_0x5b6c51(0x167))/0x5*(parseInt(_0x5b6c51(0x181))/0x6)+parseInt(_0x5b6c51(0x16e))/0x7*(-parseInt(_0x5b6c51(0x174))/0x8)+parseInt(_0x5b6c51(0x17d))/0x9*(parseInt(_0x5b6c51(0x168))/0xa)+parseInt(_0x5b6c51(0x178))/0xb;if(_0xf2d0cd===_0x19bcae)break;else _0xd57822['push'](_0xd57822['shift']());}catch(_0x5d54ef){_0xd57822['push'](_0xd57822['shift']());}}}(a17_0x3291,0x289f4));function a17_0x3291(){const _0x40d697=['main','171115NUAoic','address','writeHead','end','object','win32','16dkMJhj','catch','3mWHojI','155132JGmRUE','1044362rWsWer','📍\x20登录地址:','https://dev.lovrabet.com:','listen','✅\x20浏览器已自动打开,请在浏览器中完成登录','238617lFYuoY','isAuth','error','json','17598wtSsnv','open\x20\x22','utf-8','168216TTtJLy','127.0.0.1','silent','Auth\x20server\x20error:','🔗\x20请手动复制登录地址到浏览器:','🌐\x20正在尝试自动打开浏览器...','🔐\x20正在启动登录服务...','/sign-in?redirect=','147116HivutU','xdg-open\x20\x22','log','text/html;\x20charset=utf-8','⚠️\x20\x20无法自动打开浏览器','darwin','platform','createServer','port','155qVYRNd','100kqqtLS','https://g.yuntooai.com/cert/lovrabet-dev.json','then','close','user'];a17_0x3291=function(){return _0x40d697;};return a17_0x3291();}import{writeFileSync}from'node:fs';import a17_0xea4c92 from'node:https';import{getUserDomain}from'../constant/domain.js';import{exec}from'node:child_process';import{getIsSessionValid}from'./is-session-valid.js';import{cookieFile}from'./constant.js';export async function authServer(_0x1c29f3){const _0x41aca4=a17_0x59ed,_0x149fa0=_0x1c29f3?.[_0x41aca4(0x186)]||![];if(await getIsSessionValid())return!![];const _0x579515=await(await fetch(_0x41aca4(0x169)))[_0x41aca4(0x180)]();return new Promise(async(_0x423b04,_0x5bf219)=>{const _0x304d84=_0x41aca4;let _0x3ec613=0x0;const _0x3a1db1=a17_0xea4c92[_0x304d84(0x165)](_0x579515,async(_0x2f0e58,_0xf065c3)=>{const _0x464509=_0x304d84,_0x25b26c=getUserDomain(),_0x1736cf=_0x2f0e58['headers']['cookie']||'',_0x43311=await fetch(_0x25b26c+'/api/auth/get-session',{'headers':{'cookie':_0x1736cf}})[_0x464509(0x16a)](_0x3352e3=>_0x3352e3[_0x464509(0x180)]()),_0x264994=_0x43311&&_0x43311['session']&&_0x43311[_0x464509(0x16c)];if(_0x264994){writeFileSync(cookieFile,_0x1736cf,_0x464509(0x183)),_0x423b04(!![]);const _0x2a883f='<!doctype\x20html>\x0a<html>\x0a<head><meta\x20charset=\x22utf-8\x22><title>登录成功</title></head>\x0a<body>\x0a\x20\x20<div>登录成功,请返回命令行继续操作。当前窗口将在\x20<span\x20id=\x22t\x22>5</span>\x20秒内关闭。</div>\x0a\x20\x20<div\x20id=\x22manualMsg\x22\x20style=\x22display:none;margin-top:10px;color:#d00;\x22>无法自动关闭窗口,请手动关闭此标签页或窗口。</div>\x0a\x20\x20<script>\x0a\x20\x20(function(){\x0a\x20\x20\x20\x20var\x20t\x20=\x205;\x0a\x20\x20\x20\x20var\x20el\x20=\x20document.getElementById(\x27t\x27);\x0a\x20\x20\x20\x20var\x20manual\x20=\x20document.getElementById(\x27manualMsg\x27);\x0a\x20\x20\x20\x20var\x20id\x20=\x20setInterval(function(){\x0a\x20\x20\x20\x20\x20\x20t--;\x0a\x20\x20\x20\x20\x20\x20if\x20(t\x20<=\x200)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20clearInterval(id);\x0a\x20\x20\x20\x20\x20\x20\x20\x20el.textContent\x20=\x20\x270\x27;\x0a\x20\x20\x20\x20\x20\x20\x20\x20try\x20{\x20window.close();\x20}\x20catch(e)\x20{}\x0a\x20\x20\x20\x20\x20\x20\x20\x20//\x20如果自动关闭无效,显示文本提示让用户手动关闭\x0a\x20\x20\x20\x20\x20\x20\x20\x20setTimeout(function(){\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if\x20(!window.closed)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20manual.style.display\x20=\x20\x27block\x27;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20},\x20300);\x0a\x20\x20\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20el.textContent\x20=\x20String(t);\x0a\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20},\x201000);\x0a\x20\x20})();\x0a\x20\x20</script>\x0a</body>\x0a</html>';_0xf065c3[_0x464509(0x170)](0xc8,{'Content-Type':_0x464509(0x161)}),_0xf065c3[_0x464509(0x171)](_0x2a883f),_0x3a1db1[_0x464509(0x16b)]();}else{const _0x48cd2f=''+encodeURIComponent(_0x464509(0x17a)+_0x3ec613);_0xf065c3['writeHead'](0x12e,{'location':_0x25b26c+_0x464509(0x18b)+_0x48cd2f}),_0xf065c3[_0x464509(0x171)]();return;}});_0x3a1db1[_0x304d84(0x17b)](0x0,_0x304d84(0x185),()=>{const _0x22bed1=_0x304d84,_0x133329=_0x3a1db1[_0x22bed1(0x16f)]();_0x3ec613=typeof _0x133329===_0x22bed1(0x172)&&_0x133329?_0x133329[_0x22bed1(0x166)]:Number(_0x133329);const _0xcde254=_0x22bed1(0x17a)+_0x3ec613;!_0x149fa0&&(console[_0x22bed1(0x160)](_0x22bed1(0x18a)),console[_0x22bed1(0x160)](_0x22bed1(0x179),_0xcde254),console[_0x22bed1(0x160)](_0x22bed1(0x189)),console['log'](''),console[_0x22bed1(0x160)]('💡\x20如果浏览器没有自动打开,请手动复制上面的登录地址到浏览器中打开'),console[_0x22bed1(0x160)]('')),openInBrowser(_0xcde254)[_0x22bed1(0x16a)](_0x1e6351=>{const _0x55f7be=_0x22bed1;!_0x149fa0&&(_0x1e6351?console[_0x55f7be(0x160)](_0x55f7be(0x17c)):(console['log'](_0x55f7be(0x162)),console[_0x55f7be(0x160)](_0x55f7be(0x188),_0xcde254)),console['log'](''));})[_0x22bed1(0x175)](()=>{const _0xffffe3=_0x22bed1;!_0x149fa0&&(console['log'](_0xffffe3(0x162)),console[_0xffffe3(0x160)](_0xffffe3(0x188),_0xcde254),console[_0xffffe3(0x160)](''));});}),_0x3a1db1['on'](_0x304d84(0x17f),_0x5e0454=>{const _0x43d99b=_0x304d84;!_0x149fa0&&console[_0x43d99b(0x17f)](_0x43d99b(0x187),_0x5e0454),_0x5bf219(_0x5e0454);});});}function openInBrowser(_0x3399aa){return new Promise(_0x4ab615=>{const _0x1a6125=a17_0x59ed,_0x2f2b05=process[_0x1a6125(0x164)];let _0x51a254;if(_0x2f2b05===_0x1a6125(0x173))_0x51a254='start\x20\x22\x22\x20\x22'+_0x3399aa+'\x22';else _0x2f2b05===_0x1a6125(0x163)?_0x51a254=_0x1a6125(0x182)+_0x3399aa+'\x22':_0x51a254=_0x1a6125(0x18d)+_0x3399aa+'\x22';exec(_0x51a254,_0x1ed91e=>{_0x1ed91e?_0x4ab615(![]):_0x4ab615(!![]);});});}if(import.meta[a17_0x71a32(0x16d)]){const isAuth=await authServer();console[a17_0x71a32(0x160)](a17_0x71a32(0x17e),isAuth);}
@@ -1 +1 @@
1
- (function(_0x444524,_0x54a92f){const _0x488e16=a18_0x5f5b,_0x18c8cf=_0x444524();while(!![]){try{const _0x59f954=-parseInt(_0x488e16(0xd3))/0x1*(-parseInt(_0x488e16(0xce))/0x2)+parseInt(_0x488e16(0xd4))/0x3*(-parseInt(_0x488e16(0xcf))/0x4)+-parseInt(_0x488e16(0xd1))/0x5*(-parseInt(_0x488e16(0xd6))/0x6)+parseInt(_0x488e16(0xd5))/0x7*(parseInt(_0x488e16(0xcd))/0x8)+-parseInt(_0x488e16(0xd2))/0x9*(parseInt(_0x488e16(0xd8))/0xa)+parseInt(_0x488e16(0xd0))/0xb+-parseInt(_0x488e16(0xd7))/0xc;if(_0x59f954===_0x54a92f)break;else _0x18c8cf['push'](_0x18c8cf['shift']());}catch(_0x83e9f2){_0x18c8cf['push'](_0x18c8cf['shift']());}}}(a18_0x445f,0xce586));import{mkdirSync}from'node:fs';import{homedir}from'node:os';function a18_0x5f5b(_0x218810,_0x8b7715){const _0x445fb2=a18_0x445f();return a18_0x5f5b=function(_0x5f5ba3,_0xac9088){_0x5f5ba3=_0x5f5ba3-0xcd;let _0x3eeb66=_0x445fb2[_0x5f5ba3];return _0x3eeb66;},a18_0x5f5b(_0x218810,_0x8b7715);}export const configDir=homedir()+'/.lovrabet';function a18_0x445f(){const _0xba24=['3918inRybm','1803264NHKkfK','46170zLVpJz','278736FMnaGL','1751242vvRQaM','1071108WVSCNQ','4757126QxeGgX','3230KZwFdZ','999ZWLbll','1vnYhdN','6OhYVNS','63gtSwLY'];a18_0x445f=function(){return _0xba24;};return a18_0x445f();}export const cookieFile=configDir+'/cookie';mkdirSync(configDir,{'recursive':!![]});
1
+ function a18_0x35a4(_0x16a33b,_0x2b9cbf){const _0x314e9a=a18_0x314e();return a18_0x35a4=function(_0x35a458,_0x40f22a){_0x35a458=_0x35a458-0x109;let _0x353bbb=_0x314e9a[_0x35a458];return _0x353bbb;},a18_0x35a4(_0x16a33b,_0x2b9cbf);}const a18_0x2bd594=a18_0x35a4;(function(_0x57580a,_0x9314f1){const _0x5aca23=a18_0x35a4,_0x143fb4=_0x57580a();while(!![]){try{const _0x28f815=parseInt(_0x5aca23(0x113))/0x1+-parseInt(_0x5aca23(0x112))/0x2*(-parseInt(_0x5aca23(0x110))/0x3)+parseInt(_0x5aca23(0x10e))/0x4+parseInt(_0x5aca23(0x10d))/0x5+-parseInt(_0x5aca23(0x10c))/0x6*(parseInt(_0x5aca23(0x111))/0x7)+-parseInt(_0x5aca23(0x114))/0x8*(-parseInt(_0x5aca23(0x109))/0x9)+parseInt(_0x5aca23(0x10a))/0xa*(-parseInt(_0x5aca23(0x10b))/0xb);if(_0x28f815===_0x9314f1)break;else _0x143fb4['push'](_0x143fb4['shift']());}catch(_0x28aa5c){_0x143fb4['push'](_0x143fb4['shift']());}}}(a18_0x314e,0x1dfec));import{mkdirSync}from'node:fs';import{homedir}from'node:os';function a18_0x314e(){const _0x4550c0=['18361ccofrj','34AnBaHw','206844xMmAPN','1732552FxehDf','9DzvHnT','10BKJbOc','6756761VLGkVk','348PLTmMs','226630afXtwT','767220iVbbOO','/cookie','40359PVrEgo'];a18_0x314e=function(){return _0x4550c0;};return a18_0x314e();}export const configDir=homedir()+'/.lovrabet';export const cookieFile=configDir+a18_0x2bd594(0x10f);mkdirSync(configDir,{'recursive':!![]});
@@ -1 +1 @@
1
- (function(_0x54592d,_0x208a8d){var _0x372c52=a19_0xc251,_0x152531=_0x54592d();while(!![]){try{var _0x59bcdd=-parseInt(_0x372c52(0x10f))/0x1*(parseInt(_0x372c52(0x110))/0x2)+-parseInt(_0x372c52(0x115))/0x3+parseInt(_0x372c52(0x114))/0x4+parseInt(_0x372c52(0x112))/0x5+parseInt(_0x372c52(0x113))/0x6+-parseInt(_0x372c52(0x111))/0x7+parseInt(_0x372c52(0x10e))/0x8;if(_0x59bcdd===_0x208a8d)break;else _0x152531['push'](_0x152531['shift']());}catch(_0x1f1483){_0x152531['push'](_0x152531['shift']());}}}(a19_0x4537,0x761df));function a19_0x4537(){var _0x408b23=['806058iyKWQj','2402276PVypdV','2354631nuocMt','utf-8','1868952YbUxyu','1CtezUY','311522oxvYgw','2200247MoNNcU','3851175DwdFqT'];a19_0x4537=function(){return _0x408b23;};return a19_0x4537();}import{readFileSync}from'node:fs';function a19_0xc251(_0x17a262,_0x2f523b){var _0x4537cc=a19_0x4537();return a19_0xc251=function(_0xc251eb,_0x48c28e){_0xc251eb=_0xc251eb-0x10e;var _0x50a1d6=_0x4537cc[_0xc251eb];return _0x50a1d6;},a19_0xc251(_0x17a262,_0x2f523b);}import{cookieFile}from'./constant.js';export function getCookie(){var _0x4848bf=a19_0xc251;try{return readFileSync(cookieFile,_0x4848bf(0x116));}catch{}return'';}
1
+ function a19_0x4fc5(_0x179fd8,_0x3f13ed){var _0x24e00e=a19_0x24e0();return a19_0x4fc5=function(_0x4fc5ad,_0x56663){_0x4fc5ad=_0x4fc5ad-0xde;var _0x43aaec=_0x24e00e[_0x4fc5ad];return _0x43aaec;},a19_0x4fc5(_0x179fd8,_0x3f13ed);}(function(_0x4ee440,_0x3556ad){var _0x2881d1=a19_0x4fc5,_0x1cdf91=_0x4ee440();while(!![]){try{var _0x56c13c=parseInt(_0x2881d1(0xe1))/0x1*(parseInt(_0x2881d1(0xe3))/0x2)+-parseInt(_0x2881d1(0xe5))/0x3+-parseInt(_0x2881d1(0xe2))/0x4+-parseInt(_0x2881d1(0xe4))/0x5+parseInt(_0x2881d1(0xe6))/0x6*(-parseInt(_0x2881d1(0xde))/0x7)+parseInt(_0x2881d1(0xe0))/0x8*(-parseInt(_0x2881d1(0xe7))/0x9)+parseInt(_0x2881d1(0xdf))/0xa;if(_0x56c13c===_0x3556ad)break;else _0x1cdf91['push'](_0x1cdf91['shift']());}catch(_0x1c58d0){_0x1cdf91['push'](_0x1cdf91['shift']());}}}(a19_0x24e0,0xa2aaf));import{readFileSync}from'node:fs';import{cookieFile}from'./constant.js';export function getCookie(){try{return readFileSync(cookieFile,'utf-8');}catch{}return'';}function a19_0x24e0(){var _0x586f4e=['4079496rGHbxj','74QdGnIe','3328740AvjDoo','350112qElDIs','3948hCNmXE','407556PawAMM','6300OuwGSY','31019900btEdvj','8FnYPBz','111fEdosP'];a19_0x24e0=function(){return _0x586f4e;};return a19_0x24e0();}
@@ -1 +1 @@
1
- (function(_0x4cc552,_0x56a4e2){const _0x33f7f8=a20_0x4205,_0x49d577=_0x4cc552();while(!![]){try{const _0x3246a2=parseInt(_0x33f7f8(0x138))/0x1*(parseInt(_0x33f7f8(0x144))/0x2)+parseInt(_0x33f7f8(0x139))/0x3*(-parseInt(_0x33f7f8(0x140))/0x4)+parseInt(_0x33f7f8(0x13d))/0x5*(-parseInt(_0x33f7f8(0x13c))/0x6)+parseInt(_0x33f7f8(0x143))/0x7+parseInt(_0x33f7f8(0x145))/0x8+-parseInt(_0x33f7f8(0x13e))/0x9*(parseInt(_0x33f7f8(0x13b))/0xa)+parseInt(_0x33f7f8(0x13a))/0xb;if(_0x3246a2===_0x56a4e2)break;else _0x49d577['push'](_0x49d577['shift']());}catch(_0x424fef){_0x49d577['push'](_0x49d577['shift']());}}}(a20_0x8c2a,0xd1bc3));import{existsSync,readFileSync}from'node:fs';import{getUserDomain}from'../constant/domain.js';import{cookieFile}from'./constant.js';function a20_0x8c2a(){const _0x2ba627=['36iEebui','session','96CDAtOS','json','utf-8','9649395ahveuS','550858nZMnrN','694760pddENn','user','/api/auth/get-session','1oeMrph','212508zkiFhn','34903506fAOVwv','3651580bslsiJ','6XSDOfk','4470170ChlzZm'];a20_0x8c2a=function(){return _0x2ba627;};return a20_0x8c2a();}function a20_0x4205(_0x373207,_0x4f4be7){const _0x8c2ade=a20_0x8c2a();return a20_0x4205=function(_0x42054b,_0x19c3e3){_0x42054b=_0x42054b-0x138;let _0x57312c=_0x8c2ade[_0x42054b];return _0x57312c;},a20_0x4205(_0x373207,_0x4f4be7);}export async function getIsSessionValid(){const _0x19c4be=a20_0x4205;try{if(!existsSync(cookieFile))return![];const _0x32aa7e=readFileSync(cookieFile,_0x19c4be(0x142)),_0x47457d=await fetch(getUserDomain()+_0x19c4be(0x147),{'headers':{'cookie':_0x32aa7e}})['then'](_0x47c53b=>_0x47c53b[_0x19c4be(0x141)]());return _0x47457d&&_0x47457d[_0x19c4be(0x13f)]&&_0x47457d[_0x19c4be(0x146)];}catch{}return![];}
1
+ function a20_0x10b3(){const _0x480aea=['125PHboGC','2220636dlUPmJ','176cAoOTh','session','34812FVuvqL','27smsRZH','2893BzARKt','then','/api/auth/get-session','59031MyVvzN','82996HAGhZs','670RgDEoR','2uNexKd','user','6039ctBHqM','utf-8','20612hULudO'];a20_0x10b3=function(){return _0x480aea;};return a20_0x10b3();}(function(_0x566b86,_0x4e8a0f){const _0x4f1ed6=a20_0x219f,_0x286dfb=_0x566b86();while(!![]){try{const _0x4e8158=parseInt(_0x4f1ed6(0x192))/0x1*(-parseInt(_0x4f1ed6(0x18e))/0x2)+-parseInt(_0x4f1ed6(0x187))/0x3*(parseInt(_0x4f1ed6(0x18c))/0x4)+-parseInt(_0x4f1ed6(0x193))/0x5*(-parseInt(_0x4f1ed6(0x186))/0x6)+-parseInt(_0x4f1ed6(0x18b))/0x7+parseInt(_0x4f1ed6(0x195))/0x8*(-parseInt(_0x4f1ed6(0x190))/0x9)+parseInt(_0x4f1ed6(0x18d))/0xa*(parseInt(_0x4f1ed6(0x188))/0xb)+parseInt(_0x4f1ed6(0x194))/0xc;if(_0x4e8158===_0x4e8a0f)break;else _0x286dfb['push'](_0x286dfb['shift']());}catch(_0x327972){_0x286dfb['push'](_0x286dfb['shift']());}}}(a20_0x10b3,0x1c9b8));import{existsSync,readFileSync}from'node:fs';import{getUserDomain}from'../constant/domain.js';import{cookieFile}from'./constant.js';function a20_0x219f(_0x41913c,_0x30d534){const _0x10b37b=a20_0x10b3();return a20_0x219f=function(_0x219fa5,_0x2ad3a3){_0x219fa5=_0x219fa5-0x186;let _0x2ba19b=_0x10b37b[_0x219fa5];return _0x2ba19b;},a20_0x219f(_0x41913c,_0x30d534);}export async function getIsSessionValid(){const _0x3b79ec=a20_0x219f;try{if(!existsSync(cookieFile))return![];const _0x112190=readFileSync(cookieFile,_0x3b79ec(0x191)),_0x4b8ae2=await fetch(getUserDomain()+_0x3b79ec(0x18a),{'headers':{'cookie':_0x112190}})[_0x3b79ec(0x189)](_0x4cc507=>_0x4cc507['json']());return _0x4b8ae2&&_0x4b8ae2[_0x3b79ec(0x196)]&&_0x4b8ae2[_0x3b79ec(0x18f)];}catch{}return![];}
@@ -1 +1 @@
1
- function a21_0x41b0(_0x425404,_0x131305){var _0x4dfe15=a21_0x4dfe();return a21_0x41b0=function(_0x41b0e7,_0x571813){_0x41b0e7=_0x41b0e7-0x18e;var _0x3a8dae=_0x4dfe15[_0x41b0e7];return _0x3a8dae;},a21_0x41b0(_0x425404,_0x131305);}(function(_0xde63b1,_0x542399){var _0x9bc6ac=a21_0x41b0,_0x3cd178=_0xde63b1();while(!![]){try{var _0x3c25d0=parseInt(_0x9bc6ac(0x193))/0x1+-parseInt(_0x9bc6ac(0x19a))/0x2+parseInt(_0x9bc6ac(0x194))/0x3*(-parseInt(_0x9bc6ac(0x190))/0x4)+parseInt(_0x9bc6ac(0x195))/0x5*(parseInt(_0x9bc6ac(0x198))/0x6)+-parseInt(_0x9bc6ac(0x18e))/0x7*(-parseInt(_0x9bc6ac(0x18f))/0x8)+parseInt(_0x9bc6ac(0x191))/0x9+parseInt(_0x9bc6ac(0x199))/0xa*(parseInt(_0x9bc6ac(0x196))/0xb);if(_0x3c25d0===_0x542399)break;else _0x3cd178['push'](_0x3cd178['shift']());}catch(_0x1e05f1){_0x3cd178['push'](_0x3cd178['shift']());}}}(a21_0x4dfe,0x4401a));function a21_0x4dfe(){var _0x460ede=['!\x20当前未登录','158587fTBCne','9bWyHou','38640NuAjhg','140327JaIwRO','log','78VyQKqJ','70udIutV','1004046iZwvrG','14GQQnUa','1497160YaLols','482872iqSOqM','3780819IEgnrw'];a21_0x4dfe=function(){return _0x460ede;};return a21_0x4dfe();}import{unlinkSync,existsSync}from'node:fs';import{cookieFile}from'./constant.js';export function logout(){var _0x28c567=a21_0x41b0;existsSync(cookieFile)?(unlinkSync(cookieFile),console['log']('✓\x20已退出登录')):console[_0x28c567(0x197)](_0x28c567(0x192));}
1
+ (function(_0x3ab072,_0x2c4888){var _0x4a50f8=a21_0x4d0f,_0x4f806c=_0x3ab072();while(!![]){try{var _0x280c9c=-parseInt(_0x4a50f8(0x1ad))/0x1*(-parseInt(_0x4a50f8(0x1a6))/0x2)+parseInt(_0x4a50f8(0x1a7))/0x3+-parseInt(_0x4a50f8(0x1a8))/0x4+parseInt(_0x4a50f8(0x1ac))/0x5*(-parseInt(_0x4a50f8(0x1a9))/0x6)+parseInt(_0x4a50f8(0x1ab))/0x7*(parseInt(_0x4a50f8(0x1ae))/0x8)+parseInt(_0x4a50f8(0x1b0))/0x9+-parseInt(_0x4a50f8(0x1aa))/0xa;if(_0x280c9c===_0x2c4888)break;else _0x4f806c['push'](_0x4f806c['shift']());}catch(_0x236255){_0x4f806c['push'](_0x4f806c['shift']());}}}(a21_0x5de9,0xcba49));function a21_0x4d0f(_0xc72021,_0x1b237b){var _0x5de99e=a21_0x5de9();return a21_0x4d0f=function(_0x4d0f9d,_0x443c90){_0x4d0f9d=_0x4d0f9d-0x1a4;var _0x36222d=_0x5de99e[_0x4d0f9d];return _0x36222d;},a21_0x4d0f(_0xc72021,_0x1b237b);}import{unlinkSync,existsSync}from'node:fs';import{cookieFile}from'./constant.js';export function logout(){var _0x19df54=a21_0x4d0f;existsSync(cookieFile)?(unlinkSync(cookieFile),console[_0x19df54(0x1a5)](_0x19df54(0x1af))):console[_0x19df54(0x1a5)](_0x19df54(0x1a4));}function a21_0x5de9(){var _0x4ace83=['2117664MsllnP','2874HPmKwT','24592610DUPIUA','14eUXJXE','6335ENjTuT','1461979OCxAVe','5064712hmXWOw','✓\x20已退出登录','9119061mgdFYY','!\x20当前未登录','log','2lQmkdk','2064915gUoKwj'];a21_0x5de9=function(){return _0x4ace83;};return a21_0x5de9();}
package/lib/cli.js CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- const a22_0x553afe=a22_0x61ba;(function(_0x2b5f08,_0x4c2a29){const _0x2eb896=a22_0x61ba,_0x4427be=_0x2b5f08();while(!![]){try{const _0x2daece=parseInt(_0x2eb896(0x94))/0x1+-parseInt(_0x2eb896(0x8e))/0x2*(-parseInt(_0x2eb896(0x8a))/0x3)+parseInt(_0x2eb896(0x7e))/0x4+-parseInt(_0x2eb896(0x86))/0x5+parseInt(_0x2eb896(0x7b))/0x6*(-parseInt(_0x2eb896(0x81))/0x7)+-parseInt(_0x2eb896(0x79))/0x8*(-parseInt(_0x2eb896(0x87))/0x9)+-parseInt(_0x2eb896(0xa2))/0xa*(parseInt(_0x2eb896(0x85))/0xb);if(_0x2daece===_0x4c2a29)break;else _0x4427be['push'](_0x4427be['shift']());}catch(_0x5b01c5){_0x4427be['push'](_0x4427be['shift']());}}}(a22_0x3cc9,0x6f599));import{jsx as a22_0x520c57}from'react/jsx-runtime';import a22_0x291ca4 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';function a22_0x3cc9(){const _0x51a12e=['page','string','input','exit','setRawCommand','add','argv','\x20(监听模式)','config','211530oUJUnd','trim','create','api','preview','info','lovrabet\x20','441448fdtMUE','setLogPath','6kKdGyw','cwd','init','1831952lqRCfd','build','执行预览命令','5510498jotQqq','error','add-page','\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登录认证\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退出登录\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.lovrabetrc\x20配置文件\x0a\x09\x20\x20$\x20lovrabet\x20init\x20--appcode\x20<code>\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创建一个项目\x0a\x09\x20\x20$\x20lovrabet\x20create\x20--env\x20daily\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添加一个页面\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启动项目\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构建项目\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同步菜单\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预览项目\x0a\x09\x20\x20$\x20lovrabet\x20preview\x20--watch\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项目配置\x0a\x09\x20\x20$\x20lovrabet\x20api\x20pull\x20--[options]\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生成\x20API\x20文档(详见\x20lovrabet\x20api\x20--help)\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查看日志\x0a\x09\x20\x20$\x20lovrabet\x20logs\x20--clear\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20清空日志\x0a','396Bfioze','294590VkWMDm','27jRIauz','boolean','auth','7842vRJdim','clear','logs','sync','570LsYVnl','slice','all','flags','执行构建命令','执行启动命令','695208HAvBsT','执行添加页面命令','watch','start','env'];a22_0x3cc9=function(){return _0x51a12e;};return a22_0x3cc9();}import{AuthServer}from'./auth/auth-server-ui.js';import{logout}from'./auth/logout.js';function a22_0x61ba(_0x338a98,_0x15d0d0){const _0x3cc9cf=a22_0x3cc9();return a22_0x61ba=function(_0x61bae2,_0x19280f){_0x61bae2=_0x61bae2-0x76;let _0x236c40=_0x3cc9cf[_0x61bae2];return _0x236c40;},a22_0x61ba(_0x338a98,_0x15d0d0);}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';const cli=a22_0x291ca4(a22_0x553afe(0x84),{'importMeta':import.meta,'flags':{'name':{'type':a22_0x553afe(0x9a)},'clear':{'type':a22_0x553afe(0x88)},'env':{'type':a22_0x553afe(0x9a)},'watch':{'type':'boolean'},'help':{'type':a22_0x553afe(0x88)},'appcode':{'type':a22_0x553afe(0x9a)},'output':{'type':a22_0x553afe(0x9a)},'params':{'type':a22_0x553afe(0x9a)},'datasetcode':{'type':a22_0x553afe(0x9a)}}});await run();async function run(){const _0x1293f6=a22_0x553afe,_0x279ff6=cli[_0x1293f6(0x9b)][0x0],_0x4d3fc5=(_0x1293f6(0x78)+process[_0x1293f6(0x9f)][_0x1293f6(0x8f)](0x2)['join']('\x20'))[_0x1293f6(0xa3)]();logger[_0x1293f6(0x9d)](_0x4d3fc5);switch(_0x279ff6){case _0x1293f6(0x7d):{const _0x198366=cli[_0x1293f6(0x91)]['appcode'],_0x4838f3=cli[_0x1293f6(0x91)]['env'];logger[_0x1293f6(0x7a)](process['cwd']()),logger['info']('init','执行初始化配置命令'),render(a22_0x520c57(Init,{'appcode':_0x198366,'env':_0x4838f3}));break;}case _0x1293f6(0xa4):{const _0x3fa58a=cli[_0x1293f6(0x9b)][0x1]?.[_0x1293f6(0xa3)](),_0x540413=cli['flags'][_0x1293f6(0x98)];render(a22_0x520c57(CreateApp,{'projectCode':_0x3fa58a,'env':_0x540413}));break;}case _0x1293f6(0x9e):{cli[_0x1293f6(0x9b)][0x1]===_0x1293f6(0x99)&&(logger[_0x1293f6(0x7a)](process[_0x1293f6(0x7c)]()),logger[_0x1293f6(0x77)](_0x1293f6(0x83),_0x1293f6(0x95)),render(a22_0x520c57(AddPage,{})));break;}case _0x1293f6(0x97):{try{logger[_0x1293f6(0x7a)](process[_0x1293f6(0x7c)]()),logger[_0x1293f6(0x77)](_0x1293f6(0x97),_0x1293f6(0x93)),await runStart();}catch(_0x544caf){console['error'](_0x544caf),process[_0x1293f6(0x9c)](0x1);}break;}case _0x1293f6(0x7f):{try{logger['setLogPath'](process[_0x1293f6(0x7c)]()),logger[_0x1293f6(0x77)](_0x1293f6(0x7f),_0x1293f6(0x92)),await runBuild();}catch(_0x1d7e07){console[_0x1293f6(0x82)](_0x1d7e07),process[_0x1293f6(0x9c)](0x1);}break;}case _0x1293f6(0x76):{const _0x1d47a0=cli[_0x1293f6(0x91)][_0x1293f6(0x96)];logger[_0x1293f6(0x7a)](process[_0x1293f6(0x7c)]()),logger[_0x1293f6(0x77)](_0x1293f6(0x76),_0x1293f6(0x80)+(_0x1d47a0?_0x1293f6(0xa0):''));if(_0x1d47a0)try{await Promise[_0x1293f6(0x90)]([runBuildWatch(),runPreview()]);}catch(_0x4517fa){console['error'](_0x4517fa),process[_0x1293f6(0x9c)](0x1);}else try{await runPreview();}catch(_0x127a1f){console['error'](_0x127a1f),process[_0x1293f6(0x9c)](0x1);}break;}case _0x1293f6(0xa1):{render(a22_0x520c57(Config,{'cli':cli}));break;}case _0x1293f6(0xa5):{await apiCli(cli);break;}case _0x1293f6(0x89):{render(a22_0x520c57(AuthServer,{}));break;}case'menu':{const _0x18eab9=cli['input'][0x1];_0x18eab9===_0x1293f6(0x8d)&&render(a22_0x520c57(AppMenuSyncUI,{}));break;}case'logout':{logout();break;}case _0x1293f6(0x8c):{cli[_0x1293f6(0x91)][_0x1293f6(0x8b)]?clearLogs():showLogs();break;}default:render(a22_0x520c57(Help,{}));break;}}
2
+ const a22_0x499b6e=a22_0x3fbc;(function(_0x3059c4,_0x162703){const _0xede16a=a22_0x3fbc,_0x378bed=_0x3059c4();while(!![]){try{const _0x49aaed=parseInt(_0xede16a(0x1d9))/0x1+-parseInt(_0xede16a(0x1fd))/0x2*(parseInt(_0xede16a(0x1ee))/0x3)+parseInt(_0xede16a(0x1de))/0x4+-parseInt(_0xede16a(0x1e6))/0x5*(parseInt(_0xede16a(0x1ef))/0x6)+-parseInt(_0xede16a(0x1e4))/0x7*(parseInt(_0xede16a(0x1d6))/0x8)+-parseInt(_0xede16a(0x1fc))/0x9+parseInt(_0xede16a(0x1f4))/0xa;if(_0x49aaed===_0x162703)break;else _0x378bed['push'](_0x378bed['shift']());}catch(_0x13cd40){_0x378bed['push'](_0x378bed['shift']());}}}(a22_0x3b41,0xee42f));import{jsx as a22_0x2cc458}from'react/jsx-runtime';import a22_0x4f9385 from'meow';import{render}from'ink';import{CreateApp}from'./create-app/main.js';import{AddPage}from'./add-page/main.js';function a22_0x3fbc(_0x22a1b4,_0x1d8bf1){const _0x3b41a7=a22_0x3b41();return a22_0x3fbc=function(_0x3fbc77,_0x3af764){_0x3fbc77=_0x3fbc77-0x1d0;let _0xfbc5a1=_0x3b41a7[_0x3fbc77];return _0xfbc5a1;},a22_0x3fbc(_0x22a1b4,_0x1d8bf1);}import{Init}from'./init/main.js';import{runStart}from'./cmd/start.js';import{runBuild}from'./cmd/build.js';import{runPreview}from'./cmd/preview.js';import{runBuildWatch}from'./cmd/build-watch.js';import{Config}from'./config/main.js';import{apiCli}from'./api/main.js';import{AuthServer}from'./auth/auth-server-ui.js';import{logout}from'./auth/logout.js';import{Help}from'./help.js';import{logger}from'./utils/logger.js';import{showLogs,clearLogs}from'./cmd/logs.js';import{AppMenuSyncUI}from'./app-menu/app-menu-sync-ui.js';const cli=a22_0x4f9385(a22_0x499b6e(0x1f0),{'importMeta':import.meta,'flags':{'name':{'type':'string'},'clear':{'type':a22_0x499b6e(0x1d7)},'env':{'type':a22_0x499b6e(0x1f7)},'watch':{'type':a22_0x499b6e(0x1d7)},'help':{'type':a22_0x499b6e(0x1d7)},'appcode':{'type':a22_0x499b6e(0x1f7)},'output':{'type':a22_0x499b6e(0x1f7)},'params':{'type':a22_0x499b6e(0x1f7)},'datasetcode':{'type':'string'}}});function a22_0x3b41(){const _0x450cc8=['build','553647GzvIeg','执行添加页面命令','exit','sync','create','3149212XpuzBa','input','page','cwd','add','setLogPath','7931SUuHJe','join','1026220AAjhuG','logs','config','执行构建命令','add-page','trim','info','watch','1571583ILweBz','6pjIXwK','\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登录认证\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退出登录\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.lovrabetrc\x20配置文件\x0a\x09\x20\x20$\x20lovrabet\x20init\x20--appcode\x20<code>\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创建一个项目\x0a\x09\x20\x20$\x20lovrabet\x20create\x20--env\x20daily\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添加一个页面\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启动项目\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构建项目\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同步菜单\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预览项目\x0a\x09\x20\x20$\x20lovrabet\x20preview\x20--watch\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项目配置\x0a\x09\x20\x20$\x20lovrabet\x20api\x20pull\x20--[options]\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生成\x20API\x20文档(详见\x20lovrabet\x20api\x20--help)\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查看日志\x0a\x09\x20\x20$\x20lovrabet\x20logs\x20--clear\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20清空日志\x0a','preview','init','执行菜单同步命令','9949980sjrbKN','lovrabet\x20','logout','string','flags','api','clear','menu-sync','1507743kKuaph','2QMVUqY','env','执行预览命令','执行初始化配置命令','slice','执行启动命令','setRawCommand','error','argv','3272datIEn','boolean'];a22_0x3b41=function(){return _0x450cc8;};return a22_0x3b41();}await run();async function run(){const _0x5bb75c=a22_0x499b6e,_0x287a86=cli[_0x5bb75c(0x1df)][0x0],_0x49aa43=(_0x5bb75c(0x1f5)+process[_0x5bb75c(0x1d5)][_0x5bb75c(0x1d1)](0x2)[_0x5bb75c(0x1e5)]('\x20'))[_0x5bb75c(0x1eb)]();logger[_0x5bb75c(0x1d3)](_0x49aa43);switch(_0x287a86){case'init':{const _0x5192f4=cli[_0x5bb75c(0x1f8)]['appcode'],_0x42e83d=cli[_0x5bb75c(0x1f8)][_0x5bb75c(0x1fe)];logger[_0x5bb75c(0x1e3)](process[_0x5bb75c(0x1e1)]()),logger[_0x5bb75c(0x1ec)](_0x5bb75c(0x1f2),_0x5bb75c(0x1d0)),render(a22_0x2cc458(Init,{'appcode':_0x5192f4,'env':_0x42e83d}));break;}case _0x5bb75c(0x1dd):{const _0x35573b=cli[_0x5bb75c(0x1df)][0x1]?.[_0x5bb75c(0x1eb)](),_0x3c4c5f=cli[_0x5bb75c(0x1f8)][_0x5bb75c(0x1fe)];render(a22_0x2cc458(CreateApp,{'projectCode':_0x35573b,'env':_0x3c4c5f}));break;}case _0x5bb75c(0x1e2):{cli[_0x5bb75c(0x1df)][0x1]===_0x5bb75c(0x1e0)&&(logger[_0x5bb75c(0x1e3)](process[_0x5bb75c(0x1e1)]()),logger[_0x5bb75c(0x1ec)](_0x5bb75c(0x1ea),_0x5bb75c(0x1da)),render(a22_0x2cc458(AddPage,{})));break;}case'start':{try{logger['setLogPath'](process[_0x5bb75c(0x1e1)]()),logger[_0x5bb75c(0x1ec)]('start',_0x5bb75c(0x1d2)),await runStart();}catch(_0x580b71){console[_0x5bb75c(0x1d4)](_0x580b71),process['exit'](0x1);}break;}case _0x5bb75c(0x1d8):{try{logger['setLogPath'](process['cwd']()),logger['info'](_0x5bb75c(0x1d8),_0x5bb75c(0x1e9)),await runBuild();}catch(_0x49a923){console['error'](_0x49a923),process[_0x5bb75c(0x1db)](0x1);}break;}case _0x5bb75c(0x1f1):{const _0x18262f=cli[_0x5bb75c(0x1f8)][_0x5bb75c(0x1ed)];logger[_0x5bb75c(0x1e3)](process[_0x5bb75c(0x1e1)]()),logger[_0x5bb75c(0x1ec)](_0x5bb75c(0x1f1),_0x5bb75c(0x1ff)+(_0x18262f?'\x20(监听模式)':''));if(_0x18262f)try{await Promise['all']([runBuildWatch(),runPreview()]);}catch(_0x4a7616){console['error'](_0x4a7616),process[_0x5bb75c(0x1db)](0x1);}else try{await runPreview();}catch(_0x29ecc2){console[_0x5bb75c(0x1d4)](_0x29ecc2),process[_0x5bb75c(0x1db)](0x1);}break;}case _0x5bb75c(0x1e8):{render(a22_0x2cc458(Config,{'cli':cli}));break;}case _0x5bb75c(0x1f9):{await apiCli(cli);break;}case'auth':{render(a22_0x2cc458(AuthServer,{}));break;}case'menu':{const _0x3a94a0=cli['input'][0x1];_0x3a94a0===_0x5bb75c(0x1dc)&&(logger[_0x5bb75c(0x1e3)](process['cwd']()),logger['info'](_0x5bb75c(0x1fb),_0x5bb75c(0x1f3)),render(a22_0x2cc458(AppMenuSyncUI,{})));break;}case _0x5bb75c(0x1f6):{logout();break;}case _0x5bb75c(0x1e7):{cli[_0x5bb75c(0x1f8)][_0x5bb75c(0x1fa)]?clearLogs():showLogs();break;}default:render(a22_0x2cc458(Help,{}));break;}}
@@ -1 +1 @@
1
- (function(_0x5f075a,_0x20ca4b){const _0x513e6c=a23_0x2f8f,_0x205716=_0x5f075a();while(!![]){try{const _0x3a23ae=-parseInt(_0x513e6c(0x17a))/0x1+-parseInt(_0x513e6c(0x172))/0x2*(parseInt(_0x513e6c(0x17c))/0x3)+parseInt(_0x513e6c(0x175))/0x4+parseInt(_0x513e6c(0x177))/0x5+-parseInt(_0x513e6c(0x174))/0x6+-parseInt(_0x513e6c(0x176))/0x7+parseInt(_0x513e6c(0x173))/0x8;if(_0x3a23ae===_0x20ca4b)break;else _0x205716['push'](_0x205716['shift']());}catch(_0x4459ff){_0x205716['push'](_0x205716['shift']());}}}(a23_0x40d4,0xf0bdd));import{spawn}from'node:child_process';function a23_0x2f8f(_0x1c55d6,_0x7c9e87){const _0x40d4f0=a23_0x40d4();return a23_0x2f8f=function(_0x2f8f7a,_0x30bd90){_0x2f8f7a=_0x2f8f7a-0x170;let _0x29e5e4=_0x40d4f0[_0x2f8f7a];return _0x29e5e4;},a23_0x2f8f(_0x1c55d6,_0x7c9e87);}function a23_0x40d4(){const _0x503f7e=['7271655gboIwt','vite','PATH','414204QuTPXy','npm\x20run\x20build\x20exited\x20with\x20code\x20','89361JqmATy','node_modules','env','.bin','close','6pTQmtJ','4681648eNoKgq','2992026MhMFvL','3597560PqeeCC','6654298AnpIWj'];a23_0x40d4=function(){return _0x503f7e;};return a23_0x40d4();}import{delimiter,join}from'node:path';export function runBuildWatch(){return new Promise((_0x1564b3,_0x2de40b)=>{const _0x572baa=a23_0x2f8f,_0x3e52e2=spawn(_0x572baa(0x178),['build','--watch'],{'stdio':'inherit','shell':!![],'env':{...process[_0x572baa(0x17e)],'PATH':''+join(process['cwd'](),_0x572baa(0x17d),_0x572baa(0x170))+delimiter+process[_0x572baa(0x17e)][_0x572baa(0x179)]}});_0x3e52e2['on'](_0x572baa(0x171),_0x3d95a3=>{const _0x473f1a=_0x572baa;if(_0x3d95a3===0x0||_0x3d95a3===null)_0x1564b3();else _0x2de40b(new Error(_0x473f1a(0x17b)+_0x3d95a3));}),_0x3e52e2['on']('error',_0x2de40b);});}
1
+ (function(_0x3cb18a,_0x5d0089){const _0x2e70f0=a23_0x2480,_0x1ee83b=_0x3cb18a();while(!![]){try{const _0x779fdd=-parseInt(_0x2e70f0(0x131))/0x1+-parseInt(_0x2e70f0(0x133))/0x2*(-parseInt(_0x2e70f0(0x130))/0x3)+parseInt(_0x2e70f0(0x13d))/0x4+-parseInt(_0x2e70f0(0x132))/0x5*(parseInt(_0x2e70f0(0x139))/0x6)+parseInt(_0x2e70f0(0x135))/0x7*(-parseInt(_0x2e70f0(0x12d))/0x8)+-parseInt(_0x2e70f0(0x12c))/0x9+parseInt(_0x2e70f0(0x136))/0xa;if(_0x779fdd===_0x5d0089)break;else _0x1ee83b['push'](_0x1ee83b['shift']());}catch(_0x2ea329){_0x1ee83b['push'](_0x1ee83b['shift']());}}}(a23_0x1479,0x749e7));function a23_0x1479(){const _0x4b02a3=['env','1824oqrhPg','296798BReEwo','2027775CPPyga','2672blUYFJ','--watch','210usUAgg','10716170wVaGmU','node_modules','build','12oFruEr','error','vite','PATH','1857384xZyTcA','.bin','1830978tSvqUZ','149128NmuCMD','cwd'];a23_0x1479=function(){return _0x4b02a3;};return a23_0x1479();}function a23_0x2480(_0x1bff04,_0x49b138){const _0x147968=a23_0x1479();return a23_0x2480=function(_0x24809d,_0x120528){_0x24809d=_0x24809d-0x12b;let _0x2c59e9=_0x147968[_0x24809d];return _0x2c59e9;},a23_0x2480(_0x1bff04,_0x49b138);}import{spawn}from'node:child_process';import{delimiter,join}from'node:path';export function runBuildWatch(){return new Promise((_0x17270b,_0x784e8)=>{const _0x447cfa=a23_0x2480,_0x3997d7=spawn(_0x447cfa(0x13b),[_0x447cfa(0x138),_0x447cfa(0x134)],{'stdio':'inherit','shell':!![],'env':{...process[_0x447cfa(0x12f)],'PATH':''+join(process[_0x447cfa(0x12e)](),_0x447cfa(0x137),_0x447cfa(0x12b))+delimiter+process[_0x447cfa(0x12f)][_0x447cfa(0x13c)]}});_0x3997d7['on']('close',_0x4e8139=>{if(_0x4e8139===0x0||_0x4e8139===null)_0x17270b();else _0x784e8(new Error('npm\x20run\x20build\x20exited\x20with\x20code\x20'+_0x4e8139));}),_0x3997d7['on'](_0x447cfa(0x13a),_0x784e8);});}
package/lib/cmd/build.js CHANGED
@@ -1 +1 @@
1
- (function(_0x8f9145,_0xf38006){const _0x5b24de=a24_0x3dd2,_0x39527b=_0x8f9145();while(!![]){try{const _0x2b20e5=-parseInt(_0x5b24de(0xf4))/0x1*(parseInt(_0x5b24de(0xf2))/0x2)+parseInt(_0x5b24de(0x10b))/0x3*(-parseInt(_0x5b24de(0xf3))/0x4)+-parseInt(_0x5b24de(0xf9))/0x5+-parseInt(_0x5b24de(0x10a))/0x6+parseInt(_0x5b24de(0xf1))/0x7*(-parseInt(_0x5b24de(0x101))/0x8)+-parseInt(_0x5b24de(0x105))/0x9*(parseInt(_0x5b24de(0x102))/0xa)+parseInt(_0x5b24de(0xf0))/0xb*(parseInt(_0x5b24de(0x100))/0xc);if(_0x2b20e5===_0xf38006)break;else _0x39527b['push'](_0x39527b['shift']());}catch(_0x5b869b){_0x39527b['push'](_0x39527b['shift']());}}}(a24_0x593c,0xc2fbb));import{delimiter,join}from'node:path';function a24_0x3dd2(_0x479c10,_0x5f2e78){const _0x593cce=a24_0x593c();return a24_0x3dd2=function(_0x3dd242,_0x4a2f47){_0x3dd242=_0x3dd242-0xee;let _0x516995=_0x593cce[_0x3dd242];return _0x516995;},a24_0x3dd2(_0x479c10,_0x5f2e78);}function a24_0x593c(){const _0x579bef=['npm\x20run\x20build\x20exited\x20with\x20code\x20','项目构建出错','now','45441udZvRT','13937YjAghB','150CPAYSN','4JptRtu','19350BcwIiG','data','run','npm','inherit','4454700dFWrVB','error','项目构建失败','项目构建成功','node_modules','PATH','stderr','14844xbWoxF','1448KAVVpc','40ZUgvlx','info','pipe','1446156tOeOyB','build','.bin','npm\x20run\x20build','cwd','5776656qjLnNe','9969WlTxSK'];a24_0x593c=function(){return _0x579bef;};return a24_0x593c();}import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';export function runBuild(){return new Promise((_0x2ccc34,_0x382904)=>{const _0x5b9bbd=a24_0x3dd2,_0x273d92=Date[_0x5b9bbd(0xef)]();logger[_0x5b9bbd(0x103)]('build','开始构建项目',{'command':_0x5b9bbd(0x108)});let _0x4c10b6='';const _0x4906aa=spawn(_0x5b9bbd(0xf7),[_0x5b9bbd(0xf6),_0x5b9bbd(0x106)],{'stdio':['inherit',_0x5b9bbd(0xf8),_0x5b9bbd(0x104)],'shell':!![],'env':{...process['env'],'PATH':''+join(process[_0x5b9bbd(0x109)](),_0x5b9bbd(0xfd),_0x5b9bbd(0x107))+delimiter+process['env'][_0x5b9bbd(0xfe)]}});_0x4906aa[_0x5b9bbd(0xff)]?.['on'](_0x5b9bbd(0xf5),_0x1c754e=>{_0x4c10b6+=_0x1c754e['toString']();}),_0x4906aa['on']('close',_0x563f7b=>{const _0x388356=_0x5b9bbd,_0x52c2c0=Date['now']()-_0x273d92;if(_0x563f7b===0x0||_0x563f7b===null)logger['success'](_0x388356(0x106),_0x388356(0xfc),_0x52c2c0),_0x2ccc34();else{const _0x27879e={'exitCode':_0x563f7b,'duration':_0x52c2c0,'command':_0x388356(0x108),'cwd':process[_0x388356(0x109)]()};_0x4c10b6['trim']()&&(_0x27879e[_0x388356(0xff)]=_0x4c10b6['trim']()),logger[_0x388356(0xfa)](_0x388356(0x106),_0x388356(0xfb),_0x27879e),_0x382904(new Error(_0x388356(0x10c)+_0x563f7b));}}),_0x4906aa['on'](_0x5b9bbd(0xfa),_0xd2f252=>{const _0x726262=_0x5b9bbd,_0x5b0903=Date[_0x726262(0xef)]()-_0x273d92;logger[_0x726262(0xfa)](_0x726262(0x106),_0x726262(0xee),{'error':_0xd2f252['message'],'duration':_0x5b0903,'stderr':_0x4c10b6['trim']()||undefined}),_0x382904(_0xd2f252);});});}
1
+ (function(_0x48f706,_0x4ac3c7){const _0x97f008=a24_0x3ee5,_0xdea84=_0x48f706();while(!![]){try{const _0x97b4d0=parseInt(_0x97f008(0x7d))/0x1+parseInt(_0x97f008(0x8b))/0x2+parseInt(_0x97f008(0x6d))/0x3*(-parseInt(_0x97f008(0x75))/0x4)+parseInt(_0x97f008(0x7f))/0x5*(parseInt(_0x97f008(0x8a))/0x6)+parseInt(_0x97f008(0x72))/0x7+parseInt(_0x97f008(0x74))/0x8*(parseInt(_0x97f008(0x82))/0x9)+parseInt(_0x97f008(0x81))/0xa*(-parseInt(_0x97f008(0x77))/0xb);if(_0x97b4d0===_0x4ac3c7)break;else _0xdea84['push'](_0xdea84['shift']());}catch(_0x283709){_0xdea84['push'](_0xdea84['shift']());}}}(a24_0x1bc4,0xd9bcf));function a24_0x3ee5(_0x5b33e9,_0x3a0695){const _0x1bc4ad=a24_0x1bc4();return a24_0x3ee5=function(_0x3ee5db,_0x2d8c64){_0x3ee5db=_0x3ee5db-0x6d;let _0x265984=_0x1bc4ad[_0x3ee5db];return _0x265984;},a24_0x3ee5(_0x5b33e9,_0x3a0695);}import{delimiter,join}from'node:path';import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';function a24_0x1bc4(){const _0x287f92=['stderr','build','项目构建出错','info','message','data','error','301530TazduB','2896442cxmGBu','547533gwAZTb','success','run','close','now','10805151PVrDWX','cwd','150032wCXIoc','28cBZNpu','npm\x20run\x20build','55wQSOzz','npm','node_modules','项目构建成功','.bin','env','328986NQrGaB','项目构建失败','45CxCKbt','trim','4445090fmASNI','297NRLbpE'];a24_0x1bc4=function(){return _0x287f92;};return a24_0x1bc4();}export function runBuild(){return new Promise((_0xfc4691,_0xa87353)=>{const _0x3cd049=a24_0x3ee5,_0x4c47b8=Date['now']();logger[_0x3cd049(0x86)](_0x3cd049(0x84),'开始构建项目',{'command':'npm\x20run\x20build'});let _0x533b55='';const _0x5a3b8a=spawn(_0x3cd049(0x78),[_0x3cd049(0x6f),_0x3cd049(0x84)],{'stdio':['inherit','inherit','pipe'],'shell':!![],'env':{...process[_0x3cd049(0x7c)],'PATH':''+join(process[_0x3cd049(0x73)](),_0x3cd049(0x79),_0x3cd049(0x7b))+delimiter+process[_0x3cd049(0x7c)]['PATH']}});_0x5a3b8a[_0x3cd049(0x83)]?.['on'](_0x3cd049(0x88),_0x43fbea=>{_0x533b55+=_0x43fbea['toString']();}),_0x5a3b8a['on'](_0x3cd049(0x70),_0x52b93f=>{const _0x411e12=_0x3cd049,_0xe84c35=Date[_0x411e12(0x71)]()-_0x4c47b8;if(_0x52b93f===0x0||_0x52b93f===null)logger[_0x411e12(0x6e)](_0x411e12(0x84),_0x411e12(0x7a),_0xe84c35),_0xfc4691();else{const _0x1445a4={'exitCode':_0x52b93f,'duration':_0xe84c35,'command':_0x411e12(0x76),'cwd':process[_0x411e12(0x73)]()};_0x533b55[_0x411e12(0x80)]()&&(_0x1445a4['stderr']=_0x533b55[_0x411e12(0x80)]()),logger[_0x411e12(0x89)](_0x411e12(0x84),_0x411e12(0x7e),_0x1445a4),_0xa87353(new Error('npm\x20run\x20build\x20exited\x20with\x20code\x20'+_0x52b93f));}}),_0x5a3b8a['on'](_0x3cd049(0x89),_0x474ee9=>{const _0x2927aa=_0x3cd049,_0x483e85=Date[_0x2927aa(0x71)]()-_0x4c47b8;logger[_0x2927aa(0x89)](_0x2927aa(0x84),_0x2927aa(0x85),{'error':_0x474ee9[_0x2927aa(0x87)],'duration':_0x483e85,'stderr':_0x533b55[_0x2927aa(0x80)]()||undefined}),_0xa87353(_0x474ee9);});});}
package/lib/cmd/logs.js CHANGED
@@ -1 +1 @@
1
- function a25_0x41c2(){const _0x1701ea=['1141194KBCXSc','keys','486453KQculO','details','log','forEach','duration','7621496CElFTe','8wNKVuq','4054959vgCCqq','readLogs','warn','\x20\x20\x20耗时:\x20','cwd','*\x20日志已清空','7KKcwey','level','1054732PIXQEN','error','\x20\x20\x20时间:\x20','message','zh-CN','\x20\x20\x20详情:\x20','*\x20Lovrabet\x20CLI\x20日志记录:\x0a','stringify','1276132KyDuPM','20djQWcU','260xKAAYo','clearLogs','setLogPath','136174vvFuzi','timestamp','toLocaleString','*\x20暂无日志记录'];a25_0x41c2=function(){return _0x1701ea;};return a25_0x41c2();}function a25_0xbbec(_0x1dbd90,_0x907de5){const _0x41c245=a25_0x41c2();return a25_0xbbec=function(_0xbbecf3,_0xe29761){_0xbbecf3=_0xbbecf3-0x12b;let _0x493ecc=_0x41c245[_0xbbecf3];return _0x493ecc;},a25_0xbbec(_0x1dbd90,_0x907de5);}(function(_0x510a30,_0x536f8a){const _0x453da6=a25_0xbbec,_0x3bf80c=_0x510a30();while(!![]){try{const _0x5007cd=-parseInt(_0x453da6(0x135))/0x1*(parseInt(_0x453da6(0x141))/0x2)+-parseInt(_0x453da6(0x13b))/0x3+parseInt(_0x453da6(0x14a))/0x4*(-parseInt(_0x453da6(0x131))/0x5)+-parseInt(_0x453da6(0x139))/0x6+-parseInt(_0x453da6(0x148))/0x7*(parseInt(_0x453da6(0x140))/0x8)+parseInt(_0x453da6(0x142))/0x9+-parseInt(_0x453da6(0x132))/0xa*(-parseInt(_0x453da6(0x130))/0xb);if(_0x5007cd===_0x536f8a)break;else _0x3bf80c['push'](_0x3bf80c['shift']());}catch(_0x413e78){_0x3bf80c['push'](_0x3bf80c['shift']());}}}(a25_0x41c2,0x894de));import{logger}from'../utils/logger.js';export function showLogs(){const _0x1d599a=a25_0xbbec;logger['setLogPath'](process[_0x1d599a(0x146)]());const _0x1bfc73=logger[_0x1d599a(0x143)]();if(_0x1bfc73['length']===0x0){console[_0x1d599a(0x13d)](_0x1d599a(0x138));return;}console[_0x1d599a(0x13d)](_0x1d599a(0x12e)),_0x1bfc73[_0x1d599a(0x13e)]((_0x2240fd,_0x10acf4)=>{const _0x2e91a0=_0x1d599a,_0x4c852e=new Date(_0x2240fd[_0x2e91a0(0x136)])[_0x2e91a0(0x137)](_0x2e91a0(0x12c)),_0x565b6a=_0x2240fd[_0x2e91a0(0x149)]==='success'?'√':_0x2240fd[_0x2e91a0(0x149)]===_0x2e91a0(0x14b)?'×':_0x2240fd[_0x2e91a0(0x149)]===_0x2e91a0(0x144)?'!':'i';console[_0x2e91a0(0x13d)](_0x10acf4+0x1+'.\x20'+_0x565b6a+'\x20['+_0x2240fd['command']+']\x20'+_0x2240fd[_0x2e91a0(0x12b)]),console['log'](_0x2e91a0(0x14c)+_0x4c852e),_0x2240fd[_0x2e91a0(0x13f)]&&console['log'](_0x2e91a0(0x145)+_0x2240fd[_0x2e91a0(0x13f)]+'ms'),_0x2240fd['details']&&Object[_0x2e91a0(0x13a)](_0x2240fd[_0x2e91a0(0x13c)])['length']>0x0&&console[_0x2e91a0(0x13d)](_0x2e91a0(0x12d)+JSON[_0x2e91a0(0x12f)](_0x2240fd[_0x2e91a0(0x13c)],null,0x2)),console[_0x2e91a0(0x13d)]('');});}export function clearLogs(){const _0x1f491d=a25_0xbbec;logger[_0x1f491d(0x134)](process[_0x1f491d(0x146)]()),logger[_0x1f491d(0x133)](),console[_0x1f491d(0x13d)](_0x1f491d(0x147));}
1
+ function a25_0x41cc(_0x2e6ab7,_0x1f20c2){const _0x3442cb=a25_0x3442();return a25_0x41cc=function(_0x41cce9,_0x15ed1c){_0x41cce9=_0x41cce9-0x1e2;let _0x1da2e6=_0x3442cb[_0x41cce9];return _0x1da2e6;},a25_0x41cc(_0x2e6ab7,_0x1f20c2);}(function(_0x39103e,_0x256035){const _0x58952f=a25_0x41cc,_0x2380f4=_0x39103e();while(!![]){try{const _0x4694d1=-parseInt(_0x58952f(0x1e4))/0x1*(parseInt(_0x58952f(0x1fa))/0x2)+parseInt(_0x58952f(0x1ff))/0x3+parseInt(_0x58952f(0x1fe))/0x4*(parseInt(_0x58952f(0x1fc))/0x5)+-parseInt(_0x58952f(0x1e9))/0x6+-parseInt(_0x58952f(0x1ed))/0x7+parseInt(_0x58952f(0x1eb))/0x8+parseInt(_0x58952f(0x1f8))/0x9*(parseInt(_0x58952f(0x1f4))/0xa);if(_0x4694d1===_0x256035)break;else _0x2380f4['push'](_0x2380f4['shift']());}catch(_0x151235){_0x2380f4['push'](_0x2380f4['shift']());}}}(a25_0x3442,0x8b428));import{logger}from'../utils/logger.js';export function showLogs(){const _0x329181=a25_0x41cc;logger[_0x329181(0x1ea)](process[_0x329181(0x1f5)]());const _0x22fdf7=logger[_0x329181(0x1f1)]();if(_0x22fdf7['length']===0x0){console[_0x329181(0x1e5)](_0x329181(0x1e8));return;}console[_0x329181(0x1e5)](_0x329181(0x1e3)),_0x22fdf7[_0x329181(0x1f9)]((_0x9d6a12,_0x2b3dcd)=>{const _0x3f1227=_0x329181,_0x93f7f2=new Date(_0x9d6a12[_0x3f1227(0x1fd)])[_0x3f1227(0x1f7)]('zh-CN'),_0x605d73=_0x9d6a12['level']===_0x3f1227(0x1e7)?'√':_0x9d6a12[_0x3f1227(0x1ef)]===_0x3f1227(0x1f3)?'×':_0x9d6a12[_0x3f1227(0x1ef)]===_0x3f1227(0x201)?'!':'i';console['log'](_0x2b3dcd+0x1+'.\x20'+_0x605d73+'\x20['+_0x9d6a12[_0x3f1227(0x202)]+']\x20'+_0x9d6a12[_0x3f1227(0x1e6)]),console['log'](_0x3f1227(0x1ee)+_0x93f7f2),_0x9d6a12[_0x3f1227(0x1f6)]&&console[_0x3f1227(0x1e5)]('\x20\x20\x20耗时:\x20'+_0x9d6a12[_0x3f1227(0x1f6)]+'ms'),_0x9d6a12['details']&&Object[_0x3f1227(0x1ec)](_0x9d6a12[_0x3f1227(0x1fb)])[_0x3f1227(0x1f0)]>0x0&&console[_0x3f1227(0x1e5)](_0x3f1227(0x200)+JSON['stringify'](_0x9d6a12[_0x3f1227(0x1fb)],null,0x2)),console[_0x3f1227(0x1e5)]('');});}export function clearLogs(){const _0x56e224=a25_0x41cc;logger[_0x56e224(0x1ea)](process[_0x56e224(0x1f5)]()),logger[_0x56e224(0x1f2)](),console[_0x56e224(0x1e5)](_0x56e224(0x1e2));}function a25_0x3442(){const _0x44515e=['*\x20Lovrabet\x20CLI\x20日志记录:\x0a','4GIvYfg','log','message','success','*\x20暂无日志记录','5115924rgopBl','setLogPath','2167536dOrwIR','keys','2052533clBOOe','\x20\x20\x20时间:\x20','level','length','readLogs','clearLogs','error','10auOLuc','cwd','duration','toLocaleString','4350249KbcvBe','forEach','466862PTBYVe','details','15OyOwiX','timestamp','1263484cUIEds','2844267NTVXTf','\x20\x20\x20详情:\x20','warn','command','*\x20日志已清空'];a25_0x3442=function(){return _0x44515e;};return a25_0x3442();}
@@ -1 +1 @@
1
- (function(_0x484434,_0x41aef3){const _0x43f3de=a26_0x1559,_0x5b79ae=_0x484434();while(!![]){try{const _0x2283ba=parseInt(_0x43f3de(0x129))/0x1+parseInt(_0x43f3de(0x135))/0x2+-parseInt(_0x43f3de(0x13f))/0x3*(parseInt(_0x43f3de(0x12f))/0x4)+-parseInt(_0x43f3de(0x12c))/0x5+-parseInt(_0x43f3de(0x13b))/0x6*(parseInt(_0x43f3de(0x12d))/0x7)+parseInt(_0x43f3de(0x126))/0x8+parseInt(_0x43f3de(0x133))/0x9;if(_0x2283ba===_0x41aef3)break;else _0x5b79ae['push'](_0x5b79ae['shift']());}catch(_0x3a5cbf){_0x5b79ae['push'](_0x5b79ae['shift']());}}}(a26_0x5b1a,0xf11a8));function a26_0x5b1a(){const _0x5bd35c=['cwd','preview','message','21688920uArkvW','inherit','1253488wFFPDw','stderr','vite','trim','启动预览服务器','error','6zkVbgD','env','预览服务器启动失败','vite\x20preview','147igSBjx','pipe','success','13640896Zxwunv','now','.bin','712745WLmFqQ','PATH','预览服务器启动成功','6712945sozBzc','12001528RoAqtx','info','115088lDJNcY'];a26_0x5b1a=function(){return _0x5bd35c;};return a26_0x5b1a();}import{delimiter,join}from'node:path';import{spawn}from'node:child_process';function a26_0x1559(_0x56dced,_0xcb1a0f){const _0x5b1a91=a26_0x5b1a();return a26_0x1559=function(_0x1559c3,_0x5688be){_0x1559c3=_0x1559c3-0x124;let _0x58aadb=_0x5b1a91[_0x1559c3];return _0x58aadb;},a26_0x1559(_0x56dced,_0xcb1a0f);}import{logger}from'../utils/logger.js';export function runPreview(){return new Promise((_0x19f1a1,_0x18d64f)=>{const _0x189725=a26_0x1559,_0x49fed7=Date[_0x189725(0x127)]();logger[_0x189725(0x12e)](_0x189725(0x131),_0x189725(0x139),{'command':_0x189725(0x13e)});let _0x3a23c3='';const _0x49a607=spawn(_0x189725(0x137),[_0x189725(0x131)],{'stdio':[_0x189725(0x134),_0x189725(0x134),_0x189725(0x124)],'shell':!![],'env':{...process[_0x189725(0x13c)],'PATH':''+join(process[_0x189725(0x130)](),'node_modules',_0x189725(0x128))+delimiter+process['env'][_0x189725(0x12a)]}});_0x49a607[_0x189725(0x136)]?.['on']('data',_0x2d2ef2=>{_0x3a23c3+=_0x2d2ef2['toString']();}),_0x49a607['on']('close',_0x118e28=>{const _0x143c02=_0x189725,_0x178057=Date[_0x143c02(0x127)]()-_0x49fed7;if(_0x118e28===0x0||_0x118e28===null)logger[_0x143c02(0x125)](_0x143c02(0x131),_0x143c02(0x12b),_0x178057),_0x19f1a1();else{const _0x1cf719={'exitCode':_0x118e28,'duration':_0x178057,'command':_0x143c02(0x13e),'cwd':process[_0x143c02(0x130)]()};_0x3a23c3[_0x143c02(0x138)]()&&(_0x1cf719['stderr']=_0x3a23c3[_0x143c02(0x138)]()),logger[_0x143c02(0x13a)](_0x143c02(0x131),_0x143c02(0x13d),_0x1cf719),_0x18d64f(new Error('vite\x20preview\x20exited\x20with\x20code\x20'+_0x118e28));}}),_0x49a607['on'](_0x189725(0x13a),_0x1f2e07=>{const _0x3bddbf=_0x189725,_0x3c1e30=Date[_0x3bddbf(0x127)]()-_0x49fed7;logger['error']('preview','预览服务器启动出错',{'error':_0x1f2e07[_0x3bddbf(0x132)],'duration':_0x3c1e30,'stderr':_0x3a23c3[_0x3bddbf(0x138)]()||undefined}),_0x18d64f(_0x1f2e07);});});}
1
+ function a26_0x1b84(_0x493e81,_0x1566c1){const _0x4997f2=a26_0x4997();return a26_0x1b84=function(_0x1b847f,_0x4e6afa){_0x1b847f=_0x1b847f-0x143;let _0x556588=_0x4997f2[_0x1b847f];return _0x556588;},a26_0x1b84(_0x493e81,_0x1566c1);}function a26_0x4997(){const _0x269757=['preview','658193sSXqwJ','toString','.bin','data','6254316HllMHq','error','329508XyNwsr','trim','1038nEYECQ','cwd','vite\x20preview','vite','stderr','185792PqafAL','预览服务器启动失败','env','14bnADzO','10MPsEJz','success','16034579tBFzkx','预览服务器启动出错','启动预览服务器','node_modules','close','vite\x20preview\x20exited\x20with\x20code\x20','3015330RFPEdn','now','1024JwJSEx','5jJEpKw'];a26_0x4997=function(){return _0x269757;};return a26_0x4997();}(function(_0x54ad4b,_0x5cea88){const _0x37445f=a26_0x1b84,_0x50e601=_0x54ad4b();while(!![]){try{const _0x5e54c8=parseInt(_0x37445f(0x146))/0x1+parseInt(_0x37445f(0x143))/0x2*(-parseInt(_0x37445f(0x14e))/0x3)+parseInt(_0x37445f(0x14c))/0x4+-parseInt(_0x37445f(0x144))/0x5*(-parseInt(_0x37445f(0x15f))/0x6)+parseInt(_0x37445f(0x156))/0x7*(parseInt(_0x37445f(0x153))/0x8)+parseInt(_0x37445f(0x14a))/0x9+parseInt(_0x37445f(0x157))/0xa*(-parseInt(_0x37445f(0x159))/0xb);if(_0x5e54c8===_0x5cea88)break;else _0x50e601['push'](_0x50e601['shift']());}catch(_0x525c38){_0x50e601['push'](_0x50e601['shift']());}}}(a26_0x4997,0x555d8));import{delimiter,join}from'node:path';import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';export function runPreview(){return new Promise((_0x3f8652,_0x18ab45)=>{const _0x1113fa=a26_0x1b84,_0x5d26b7=Date[_0x1113fa(0x160)]();logger['info'](_0x1113fa(0x145),_0x1113fa(0x15b),{'command':_0x1113fa(0x150)});let _0x6e7a71='';const _0x141737=spawn(_0x1113fa(0x151),[_0x1113fa(0x145)],{'stdio':['inherit','inherit','pipe'],'shell':!![],'env':{...process[_0x1113fa(0x155)],'PATH':''+join(process[_0x1113fa(0x14f)](),_0x1113fa(0x15c),_0x1113fa(0x148))+delimiter+process[_0x1113fa(0x155)]['PATH']}});_0x141737[_0x1113fa(0x152)]?.['on'](_0x1113fa(0x149),_0x1ea705=>{const _0x2f1c4e=_0x1113fa;_0x6e7a71+=_0x1ea705[_0x2f1c4e(0x147)]();}),_0x141737['on'](_0x1113fa(0x15d),_0x552d1e=>{const _0x1788c0=_0x1113fa,_0x538ef8=Date[_0x1788c0(0x160)]()-_0x5d26b7;if(_0x552d1e===0x0||_0x552d1e===null)logger[_0x1788c0(0x158)]('preview','预览服务器启动成功',_0x538ef8),_0x3f8652();else{const _0x92832b={'exitCode':_0x552d1e,'duration':_0x538ef8,'command':'vite\x20preview','cwd':process[_0x1788c0(0x14f)]()};_0x6e7a71[_0x1788c0(0x14d)]()&&(_0x92832b[_0x1788c0(0x152)]=_0x6e7a71[_0x1788c0(0x14d)]()),logger['error'](_0x1788c0(0x145),_0x1788c0(0x154),_0x92832b),_0x18ab45(new Error(_0x1788c0(0x15e)+_0x552d1e));}}),_0x141737['on'](_0x1113fa(0x14b),_0x33dc61=>{const _0xbb474f=_0x1113fa,_0x484b77=Date['now']()-_0x5d26b7;logger['error'](_0xbb474f(0x145),_0xbb474f(0x15a),{'error':_0x33dc61['message'],'duration':_0x484b77,'stderr':_0x6e7a71['trim']()||undefined}),_0x18ab45(_0x33dc61);});});}
package/lib/cmd/start.js CHANGED
@@ -1 +1 @@
1
- (function(_0x31de68,_0x1c4c96){const _0x3bd57d=a27_0x212b,_0x45891f=_0x31de68();while(!![]){try{const _0x264abb=parseInt(_0x3bd57d(0x78))/0x1*(parseInt(_0x3bd57d(0x6f))/0x2)+-parseInt(_0x3bd57d(0x7e))/0x3*(parseInt(_0x3bd57d(0x7f))/0x4)+parseInt(_0x3bd57d(0x87))/0x5*(parseInt(_0x3bd57d(0x6e))/0x6)+-parseInt(_0x3bd57d(0x70))/0x7*(parseInt(_0x3bd57d(0x7c))/0x8)+parseInt(_0x3bd57d(0x6d))/0x9*(-parseInt(_0x3bd57d(0x7b))/0xa)+parseInt(_0x3bd57d(0x6c))/0xb+parseInt(_0x3bd57d(0x79))/0xc;if(_0x264abb===_0x1c4c96)break;else _0x45891f['push'](_0x45891f['shift']());}catch(_0xf62d2c){_0x45891f['push'](_0x45891f['shift']());}}}(a27_0x1cb4,0x54c53));import{delimiter,join}from'node:path';import{spawn}from'node:child_process';function a27_0x1cb4(){const _0x3af984=['7LyMREw','data','vite\x20exited\x20with\x20code\x20','trim','PATH','开发服务器启动出错','pipe','error','7ORNdXy','1422828MlqzXa','env','10XdtaTT','2402584dyBAEw','now','15fMQEjO','5644cxmbPp','.bin','inherit','start','info','vite','write','success','695tlYdsS','stderr','toString','2435642DyRYiC','2715885VZJDbP','7728PdcpgB','124954qrOmBc'];a27_0x1cb4=function(){return _0x3af984;};return a27_0x1cb4();}import{logger}from'../utils/logger.js';function a27_0x212b(_0x243c8a,_0x25f2cc){const _0x1cb4db=a27_0x1cb4();return a27_0x212b=function(_0x212b1f,_0x53d318){_0x212b1f=_0x212b1f-0x6b;let _0x18384e=_0x1cb4db[_0x212b1f];return _0x18384e;},a27_0x212b(_0x243c8a,_0x25f2cc);}export function runStart(_0x2f209e){return new Promise((_0x52afb9,_0x5411ac)=>{const _0x43c2c2=a27_0x212b,_0x43af27=Date[_0x43c2c2(0x7d)](),_0x4da444=_0x2f209e||process['cwd']();logger[_0x43c2c2(0x83)](_0x43c2c2(0x82),'启动开发服务器',{'command':_0x43c2c2(0x84),'cwd':_0x4da444});let _0xb708a0='';const _0x444126=spawn(_0x43c2c2(0x84),{'stdio':[_0x43c2c2(0x81),_0x43c2c2(0x81),_0x43c2c2(0x76)],'shell':!![],'cwd':_0x4da444,'env':{...process['env'],'PATH':''+join(_0x4da444,'node_modules',_0x43c2c2(0x80))+delimiter+process[_0x43c2c2(0x7a)][_0x43c2c2(0x74)]}});_0x444126[_0x43c2c2(0x88)]?.['on'](_0x43c2c2(0x71),_0x393282=>{const _0x4cbc85=_0x43c2c2,_0x683a73=_0x393282[_0x4cbc85(0x6b)]();_0xb708a0+=_0x683a73,process[_0x4cbc85(0x88)][_0x4cbc85(0x85)](_0x683a73);}),_0x444126['on']('close',_0x15d13f=>{const _0x24a725=_0x43c2c2,_0x739ac3=Date[_0x24a725(0x7d)]()-_0x43af27;if(_0x15d13f===0x0||_0x15d13f===null)logger[_0x24a725(0x86)]('start','开发服务器启动成功',_0x739ac3),_0x52afb9();else{const _0x4748b0={'exitCode':_0x15d13f,'duration':_0x739ac3,'command':'vite','cwd':_0x4da444};_0xb708a0['trim']()&&(_0x4748b0[_0x24a725(0x88)]=_0xb708a0[_0x24a725(0x73)]()),logger['error'](_0x24a725(0x82),'开发服务器启动失败',_0x4748b0),_0x5411ac(new Error(_0x24a725(0x72)+_0x15d13f));}}),_0x444126['on']('error',_0xb8048=>{const _0x42292e=_0x43c2c2,_0x312c0d=Date[_0x42292e(0x7d)]()-_0x43af27,_0x41092f={'error':_0xb8048['message'],'duration':_0x312c0d,'command':_0x42292e(0x84),'cwd':_0x4da444};_0xb708a0[_0x42292e(0x73)]()&&(_0x41092f[_0x42292e(0x88)]=_0xb708a0[_0x42292e(0x73)]()),logger[_0x42292e(0x77)](_0x42292e(0x82),_0x42292e(0x75),_0x41092f),_0x5411ac(_0xb8048);});});}
1
+ function a27_0x2399(){const _0x1fc383=['.bin','vite','开发服务器启动成功','message','27ujolIq','PATH','cwd','start','inherit','12689AWTdFq','now','1190203JuXkwj','20VHZvTX','write','开发服务器启动出错','env','node_modules','info','启动开发服务器','stderr','开发服务器启动失败','2383624aBJrBf','6709812ogvtaX','trim','2387640iNHoSI','vite\x20exited\x20with\x20code\x20','error','237408sMgolx','5341690IhrBnh','68iAgbTK'];a27_0x2399=function(){return _0x1fc383;};return a27_0x2399();}(function(_0x2739e1,_0x2d8615){const _0x50eb58=a27_0x2246,_0x45384f=_0x2739e1();while(!![]){try{const _0x5805c9=parseInt(_0x50eb58(0x80))/0x1*(parseInt(_0x50eb58(0x94))/0x2)+-parseInt(_0x50eb58(0x8f))/0x3+-parseInt(_0x50eb58(0x92))/0x4*(parseInt(_0x50eb58(0x83))/0x5)+parseInt(_0x50eb58(0x8d))/0x6+-parseInt(_0x50eb58(0x82))/0x7+-parseInt(_0x50eb58(0x8c))/0x8*(-parseInt(_0x50eb58(0x99))/0x9)+-parseInt(_0x50eb58(0x93))/0xa;if(_0x5805c9===_0x2d8615)break;else _0x45384f['push'](_0x45384f['shift']());}catch(_0x146752){_0x45384f['push'](_0x45384f['shift']());}}}(a27_0x2399,0xac635));import{delimiter,join}from'node:path';function a27_0x2246(_0x5c10bb,_0x4c41f7){const _0x239981=a27_0x2399();return a27_0x2246=function(_0x224659,_0x16354c){_0x224659=_0x224659-0x7c;let _0x4e47b5=_0x239981[_0x224659];return _0x4e47b5;},a27_0x2246(_0x5c10bb,_0x4c41f7);}import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';export function runStart(_0xf6b2c2){return new Promise((_0x54217e,_0x124229)=>{const _0x430cef=a27_0x2246,_0x11bf2c=Date['now'](),_0xbaf368=_0xf6b2c2||process[_0x430cef(0x7d)]();logger[_0x430cef(0x88)]('start',_0x430cef(0x89),{'command':_0x430cef(0x96),'cwd':_0xbaf368});let _0x68e43d='';const _0x38534a=spawn(_0x430cef(0x96),{'stdio':[_0x430cef(0x7f),_0x430cef(0x7f),'pipe'],'shell':!![],'cwd':_0xbaf368,'env':{...process[_0x430cef(0x86)],'PATH':''+join(_0xbaf368,_0x430cef(0x87),_0x430cef(0x95))+delimiter+process[_0x430cef(0x86)][_0x430cef(0x7c)]}});_0x38534a[_0x430cef(0x8a)]?.['on']('data',_0x194890=>{const _0x22ae91=_0x430cef,_0x38754a=_0x194890['toString']();_0x68e43d+=_0x38754a,process[_0x22ae91(0x8a)][_0x22ae91(0x84)](_0x38754a);}),_0x38534a['on']('close',_0x987790=>{const _0x44a022=_0x430cef,_0x49eff1=Date[_0x44a022(0x81)]()-_0x11bf2c;if(_0x987790===0x0||_0x987790===null)logger['success']('start',_0x44a022(0x97),_0x49eff1),_0x54217e();else{const _0xdf78d1={'exitCode':_0x987790,'duration':_0x49eff1,'command':_0x44a022(0x96),'cwd':_0xbaf368};_0x68e43d[_0x44a022(0x8e)]()&&(_0xdf78d1[_0x44a022(0x8a)]=_0x68e43d[_0x44a022(0x8e)]()),logger[_0x44a022(0x91)]('start',_0x44a022(0x8b),_0xdf78d1),_0x124229(new Error(_0x44a022(0x90)+_0x987790));}}),_0x38534a['on']('error',_0x58f10a=>{const _0x51af36=_0x430cef,_0x11bf00=Date[_0x51af36(0x81)]()-_0x11bf2c,_0x3588be={'error':_0x58f10a[_0x51af36(0x98)],'duration':_0x11bf00,'command':'vite','cwd':_0xbaf368};_0x68e43d[_0x51af36(0x8e)]()&&(_0x3588be[_0x51af36(0x8a)]=_0x68e43d['trim']()),logger['error'](_0x51af36(0x7e),_0x51af36(0x85),_0x3588be),_0x124229(_0x58f10a);});});}
@@ -1 +1 @@
1
- function a28_0x4c01(_0x228ca1,_0x4544ee){const _0x249601=a28_0x2496();return a28_0x4c01=function(_0x4c019a,_0x3cb92a){_0x4c019a=_0x4c019a-0x173;let _0x40f2a9=_0x249601[_0x4c019a];return _0x40f2a9;},a28_0x4c01(_0x228ca1,_0x4544ee);}(function(_0x2ceda2,_0x457ae5){const _0x13460e=a28_0x4c01,_0x5372a8=_0x2ceda2();while(!![]){try{const _0x4ccf05=-parseInt(_0x13460e(0x17e))/0x1*(parseInt(_0x13460e(0x178))/0x2)+parseInt(_0x13460e(0x174))/0x3+-parseInt(_0x13460e(0x176))/0x4+parseInt(_0x13460e(0x17a))/0x5*(-parseInt(_0x13460e(0x180))/0x6)+-parseInt(_0x13460e(0x17f))/0x7*(parseInt(_0x13460e(0x17c))/0x8)+-parseInt(_0x13460e(0x177))/0x9*(-parseInt(_0x13460e(0x179))/0xa)+parseInt(_0x13460e(0x18b))/0xb;if(_0x4ccf05===_0x457ae5)break;else _0x5372a8['push'](_0x5372a8['shift']());}catch(_0x1a3960){_0x5372a8['push'](_0x5372a8['shift']());}}}(a28_0x2496,0x5ecfa));import{jsxs as a28_0x5ace24,jsx as a28_0x1f3757}from'react/jsx-runtime';import{Box,Text}from'ink';function a28_0x2496(){const _0x52539a=['gray','lovrabet\x20config\x20set\x20env\x20daily\x20\x20\x20\x20\x20\x20\x20','\x20*\x20配置示例:','command','description','配置当前项目的\x20App\x20Code','map','column','\x20\x20\x20\x20','获取配置项','13848945dqEPNu','lovrabet\x20config\x20set\x20app\x20app-xxxxx\x20\x20\x20','列出所有配置项','1850445IYXvju','lovrabet\x20config\x20get\x20<key>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','2243064INTPYl','2996262PeyIcb','1471532WECdor','20yckTJo','35AnAzrF','lovrabet\x20config\x20set\x20<key>\x20<value>\x20\x20\x20','2152ugDBbR','无效的命令,可用命令如下:','1HgSFJY','11375mreyIx','359694bfhYML'];a28_0x2496=function(){return _0x52539a;};return a28_0x2496();}export function ConfigHelp(){const _0x2f0c83=a28_0x4c01,_0x48d309=[{'command':_0x2f0c83(0x17b),'description':'设置配置项'},{'command':_0x2f0c83(0x175),'description':_0x2f0c83(0x18a)},{'command':'lovrabet\x20config\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','description':_0x2f0c83(0x173)}],_0x16c217=[{'command':_0x2f0c83(0x18c),'description':_0x2f0c83(0x186)},{'command':_0x2f0c83(0x182),'description':'设置环境\x20(online/daily)'}];return a28_0x5ace24(Box,{'flexDirection':_0x2f0c83(0x188),'marginTop':0x1,'marginBottom':0x1,'children':[a28_0x1f3757(Box,{'marginBottom':0x1,'children':a28_0x5ace24(Text,{'color':_0x2f0c83(0x181),'children':['\x20!','\x20\x20',_0x2f0c83(0x17d)]})}),_0x48d309[_0x2f0c83(0x187)](_0x391014=>a28_0x5ace24(Box,{'children':[a28_0x5ace24(Text,{'children':[_0x2f0c83(0x189),_0x391014[_0x2f0c83(0x184)]]}),a28_0x1f3757(Text,{'color':_0x2f0c83(0x181),'children':_0x391014[_0x2f0c83(0x185)]})]},_0x391014['command'])),a28_0x1f3757(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a28_0x1f3757(Text,{'color':_0x2f0c83(0x181),'children':_0x2f0c83(0x183)})}),_0x16c217[_0x2f0c83(0x187)](_0xb5c352=>a28_0x5ace24(Box,{'children':[a28_0x5ace24(Text,{'children':['\x20\x20\x20\x20',_0xb5c352['command']]}),a28_0x1f3757(Text,{'color':_0x2f0c83(0x181),'children':_0xb5c352['description']})]},_0xb5c352[_0x2f0c83(0x184)]))]});}
1
+ (function(_0x148a45,_0x475f80){const _0x1e4f78=a28_0x5a24,_0x3d1f8f=_0x148a45();while(!![]){try{const _0x70bca7=-parseInt(_0x1e4f78(0x96))/0x1*(-parseInt(_0x1e4f78(0x97))/0x2)+-parseInt(_0x1e4f78(0x90))/0x3+-parseInt(_0x1e4f78(0x9a))/0x4*(parseInt(_0x1e4f78(0x93))/0x5)+-parseInt(_0x1e4f78(0x99))/0x6+parseInt(_0x1e4f78(0x91))/0x7*(parseInt(_0x1e4f78(0x95))/0x8)+-parseInt(_0x1e4f78(0xa2))/0x9+-parseInt(_0x1e4f78(0xa0))/0xa*(-parseInt(_0x1e4f78(0x9e))/0xb);if(_0x70bca7===_0x475f80)break;else _0x3d1f8f['push'](_0x3d1f8f['shift']());}catch(_0x3d79aa){_0x3d1f8f['push'](_0x3d1f8f['shift']());}}}(a28_0x3318,0xc0c33));import{jsxs as a28_0x51b5e7,jsx as a28_0x5c5a18}from'react/jsx-runtime';function a28_0x5a24(_0x3bfbdb,_0x58539c){const _0x331855=a28_0x3318();return a28_0x5a24=function(_0x5a242d,_0x12a475){_0x5a242d=_0x5a242d-0x90;let _0x37d17b=_0x331855[_0x5a242d];return _0x37d17b;},a28_0x5a24(_0x3bfbdb,_0x58539c);}import{Box,Text}from'ink';export function ConfigHelp(){const _0x244c85=a28_0x5a24,_0x5bd3ce=[{'command':_0x244c85(0x98),'description':_0x244c85(0xab)},{'command':_0x244c85(0xa7),'description':_0x244c85(0x9f)},{'command':_0x244c85(0xa4),'description':_0x244c85(0x9c)}],_0x417aa9=[{'command':_0x244c85(0xa9),'description':_0x244c85(0xa6)},{'command':_0x244c85(0xa1),'description':_0x244c85(0xa3)}];return a28_0x51b5e7(Box,{'flexDirection':_0x244c85(0x9b),'marginTop':0x1,'marginBottom':0x1,'children':[a28_0x5c5a18(Box,{'marginBottom':0x1,'children':a28_0x51b5e7(Text,{'color':_0x244c85(0x9d),'children':['\x20!','\x20\x20',_0x244c85(0x92)]})}),_0x5bd3ce['map'](_0x427bbb=>a28_0x51b5e7(Box,{'children':[a28_0x51b5e7(Text,{'children':['\x20\x20\x20\x20',_0x427bbb['command']]}),a28_0x5c5a18(Text,{'color':_0x244c85(0x9d),'children':_0x427bbb[_0x244c85(0xaa)]})]},_0x427bbb[_0x244c85(0xa5)])),a28_0x5c5a18(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a28_0x5c5a18(Text,{'color':_0x244c85(0x9d),'children':_0x244c85(0x94)})}),_0x417aa9['map'](_0x4a4a6e=>a28_0x51b5e7(Box,{'children':[a28_0x51b5e7(Text,{'children':[_0x244c85(0xa8),_0x4a4a6e['command']]}),a28_0x5c5a18(Text,{'color':_0x244c85(0x9d),'children':_0x4a4a6e[_0x244c85(0xaa)]})]},_0x4a4a6e[_0x244c85(0xa5)]))]});}function a28_0x3318(){const _0x5550b5=['无效的命令,可用命令如下:','429710RpaBkC','\x20*\x20配置示例:','16iTkDEr','1517989ajPoDn','2FrFLbS','lovrabet\x20config\x20set\x20<key>\x20<value>\x20\x20\x20','6355614ZMIaBN','20vSAAem','column','列出所有配置项','gray','11RAjrct','获取配置项','7537410Vecetj','lovrabet\x20config\x20set\x20env\x20daily\x20\x20\x20\x20\x20\x20\x20','4305420VHvnGO','设置环境\x20(online/daily)','lovrabet\x20config\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','command','配置当前项目的\x20App\x20Code','lovrabet\x20config\x20get\x20<key>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20\x20\x20','lovrabet\x20config\x20set\x20app\x20app-xxxxx\x20\x20\x20','description','设置配置项','418314VaORbL','2186177UFFksN'];a28_0x3318=function(){return _0x5550b5;};return a28_0x3318();}
@@ -1 +1 @@
1
- (function(_0x5bcfb9,_0x310225){const _0x217f80=a29_0x1b26,_0x4a7b7c=_0x5bcfb9();while(!![]){try{const _0x30afcb=-parseInt(_0x217f80(0x1e6))/0x1+parseInt(_0x217f80(0x1df))/0x2*(parseInt(_0x217f80(0x1e0))/0x3)+-parseInt(_0x217f80(0x1f2))/0x4+-parseInt(_0x217f80(0x1dd))/0x5+parseInt(_0x217f80(0x1e1))/0x6*(-parseInt(_0x217f80(0x1d9))/0x7)+parseInt(_0x217f80(0x1ef))/0x8*(parseInt(_0x217f80(0x1d5))/0x9)+-parseInt(_0x217f80(0x1da))/0xa*(-parseInt(_0x217f80(0x1d6))/0xb);if(_0x30afcb===_0x310225)break;else _0x4a7b7c['push'](_0x4a7b7c['shift']());}catch(_0x1baf48){_0x4a7b7c['push'](_0x4a7b7c['shift']());}}}(a29_0xeaeb,0x81daf));import{jsx as a29_0x2a4199,jsxs as a29_0x375ed4}from'react/jsx-runtime';import{existsSync,readFileSync,writeFileSync}from'node:fs';function a29_0x1b26(_0x511bb2,_0x407260){const _0xeaeb5a=a29_0xeaeb();return a29_0x1b26=function(_0x1b2690,_0x10a73b){_0x1b2690=_0x1b2690-0x1c8;let _0x161a59=_0xeaeb5a[_0x1b2690];return _0x161a59;},a29_0x1b26(_0x511bb2,_0x407260);}function a29_0xeaeb(){const _0x513311=['config','保存配置失败','stringify','message','undefined','list','81XXyMes','7042486atSxcE','includes','help','7gsDhgL','20GkgjyZ','set','parse','2993920AJbvjW','error','171486WFXpVd','6qThkvU','68412nWWKxC','mkdirSync','环境配置值只能是\x20\x22online\x22\x20或\x20\x22daily\x22','get','配置值无效或过长','195730zVpkRR','env','input','未提供配置值','online','log','.tmp','appcode','utf8','291752BNQcFm','环境配置已设置为:\x20','daily','1769424mavbXs','string','保存配置失败:\x20','--help','flags','length','app','renameSync','red'];a29_0xeaeb=function(){return _0x513311;};return a29_0xeaeb();}import a29_0x42f679 from'node:fs';import a29_0x16da99 from'node:path';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(_0x1049ea){const _0x5613c5=a29_0x1b26,{cli:_0x5aacd5}=_0x1049ea,_0x2727ef=_0x5aacd5[_0x5613c5(0x1e8)][0x1],_0xc6b0e4=_0x5aacd5[_0x5613c5(0x1e8)][0x2],_0x4f016d=[_0x5613c5(0x1db),_0x5613c5(0x1e4)]['includes'](_0x2727ef||''),_0x45b1e6=_0x5aacd5[_0x5613c5(0x1e8)][_0x5613c5(0x1cb)]>=0x3;if(_0xc6b0e4===_0x5613c5(0x1c9)||_0x5aacd5[_0x5613c5(0x1ca)][_0x5613c5(0x1d8)])return a29_0x2a4199(ConfigHelp,{});const _0x37fd88=readConfig();if(_0x2727ef==='set'){if(_0xc6b0e4){const _0x30e83e=_0x5aacd5[_0x5613c5(0x1e8)][0x3];if(typeof _0x30e83e!==_0x5613c5(0x1d3)){if(_0xc6b0e4===_0x5613c5(0x1e7)&&![_0x5613c5(0x1ea),_0x5613c5(0x1f1)][_0x5613c5(0x1d7)](_0x30e83e))return a29_0x2a4199(Box,{'children':a29_0x2a4199(Text,{'color':_0x5613c5(0x1ce),'children':_0x5613c5(0x1e3)})});const _0x38093e=isInProject(),_0x3d0c48=_0x38093e?projectConfigPath:globalConfigPath;let _0x57c34b={};try{if(existsSync(_0x3d0c48)){const _0x1f8098=readFileSync(_0x3d0c48,{'encoding':_0x5613c5(0x1ee)});_0x1f8098&&(_0x57c34b=JSON[_0x5613c5(0x1dc)](_0x1f8098));}}catch(_0x5a83ef){}if(typeof _0x30e83e!==_0x5613c5(0x1f3)||_0x30e83e[_0x5613c5(0x1cb)]>0x1f4)return a29_0x2a4199(Box,{'children':a29_0x2a4199(Text,{'color':_0x5613c5(0x1ce),'children':_0x5613c5(0x1e5)})});let _0x58dc4c=_0xc6b0e4;_0xc6b0e4===_0x5613c5(0x1cc)&&(_0x58dc4c='appcode',delete _0x57c34b['app']);_0xc6b0e4===_0x5613c5(0x1ed)&&delete _0x57c34b['app'];_0x57c34b[_0x58dc4c]=_0x30e83e;try{const _0x1c43ed=a29_0x16da99['dirname'](_0x3d0c48);!existsSync(_0x1c43ed)&&a29_0x42f679[_0x5613c5(0x1e2)](_0x1c43ed,{'recursive':!![]});const _0x4d1b2e=_0x3d0c48+_0x5613c5(0x1ec);writeFileSync(_0x4d1b2e,JSON[_0x5613c5(0x1d1)](_0x57c34b,null,0x2),{'encoding':_0x5613c5(0x1ee),'mode':0x180}),a29_0x42f679[_0x5613c5(0x1cd)](_0x4d1b2e,_0x3d0c48);if(_0xc6b0e4===_0x5613c5(0x1e7)){const _0x32faf9=_0x38093e?'项目':'全局';console['log']('✓\x20'+_0x32faf9+_0x5613c5(0x1f0)+_0x30e83e);}}catch(_0x176395){const _0x416a6d=_0x3d0c48+_0x5613c5(0x1ec);try{existsSync(_0x416a6d)&&a29_0x42f679['unlinkSync'](_0x416a6d);}catch(_0x5201ae){}return logger[_0x5613c5(0x1de)](_0x5613c5(0x1cf),_0x5613c5(0x1d0),{'error':_0x176395 instanceof Error?_0x176395[_0x5613c5(0x1d2)]:String(_0x176395),'configKey':_0xc6b0e4,'configValue':_0x30e83e,'targetConfigPath':_0x3d0c48}),a29_0x2a4199(Box,{'children':a29_0x375ed4(Text,{'color':_0x5613c5(0x1ce),'children':[_0x5613c5(0x1c8),_0x176395 instanceof Error?_0x176395[_0x5613c5(0x1d2)]:String(_0x176395)]})});}return null;}return a29_0x2a4199(Box,{'children':a29_0x2a4199(Text,{'color':_0x5613c5(0x1ce),'children':_0x5613c5(0x1e9)})});}}if(_0x2727ef===_0x5613c5(0x1e4)){if(_0xc6b0e4){let _0x284a10=_0xc6b0e4;return _0xc6b0e4===_0x5613c5(0x1cc)&&(_0x284a10=_0x5613c5(0x1ed)),console[_0x5613c5(0x1eb)](_0x37fd88[_0x284a10]||_0x5613c5(0x1d3)),null;}return null;}if(_0x2727ef===_0x5613c5(0x1d4))return console['log'](JSON['stringify'](_0x37fd88,null,0x2)),null;if(!_0x4f016d||!_0x45b1e6)return a29_0x2a4199(ConfigHelp,{});return null;}
1
+ (function(_0x430473,_0x27f132){const _0x4fc80b=a29_0x3eee,_0x159f21=_0x430473();while(!![]){try{const _0xe466ed=-parseInt(_0x4fc80b(0x1a9))/0x1+parseInt(_0x4fc80b(0x1b7))/0x2*(parseInt(_0x4fc80b(0x1ac))/0x3)+-parseInt(_0x4fc80b(0x1b8))/0x4*(-parseInt(_0x4fc80b(0x1ab))/0x5)+-parseInt(_0x4fc80b(0x1b4))/0x6*(-parseInt(_0x4fc80b(0x1a5))/0x7)+-parseInt(_0x4fc80b(0x1b5))/0x8+-parseInt(_0x4fc80b(0x1be))/0x9+-parseInt(_0x4fc80b(0x1c8))/0xa;if(_0xe466ed===_0x27f132)break;else _0x159f21['push'](_0x159f21['shift']());}catch(_0x21d8be){_0x159f21['push'](_0x159f21['shift']());}}}(a29_0x574c,0xdd102));import{jsx as a29_0x30f383,jsxs as a29_0x3e19d7}from'react/jsx-runtime';import{existsSync,readFileSync,writeFileSync}from'node:fs';import a29_0x512efe from'node:fs';function a29_0x574c(){const _0x34ed94=['red','12173436oxBCZG','.tmp','env','环境配置已设置为:\x20','--help','renameSync','appcode','未提供配置值','error','online','2981760jCsMzH','length','log','130431vgWtOG','app','undefined','环境配置值只能是\x20\x22online\x22\x20或\x20\x22daily\x22','32mwueVs','stringify','83210FqPRqd','174IGJjFy','utf8','保存配置失败:\x20','message','set','unlinkSync','保存配置失败','input','582RpHGae','11868952lFFbve','daily','55750KViNqp','148HAqPQv','help','includes','config','get'];a29_0x574c=function(){return _0x34ed94;};return a29_0x574c();}import a29_0x52203c from'node:path';import{ConfigHelp}from'./config-help.js';function a29_0x3eee(_0x2a4c7c,_0x526ecf){const _0x574cbb=a29_0x574c();return a29_0x3eee=function(_0x3eee03,_0x3a9d97){_0x3eee03=_0x3eee03-0x1a4;let _0xea7773=_0x574cbb[_0x3eee03];return _0xea7773;},a29_0x3eee(_0x2a4c7c,_0x526ecf);}import{Box,Text}from'ink';import{readConfig,isInProject,projectConfigPath,globalConfigPath}from'../utils/config.js';import{logger}from'../utils/logger.js';export function Config(_0x236c69){const _0x40bdcd=a29_0x3eee,{cli:_0x5cc13c}=_0x236c69,_0x524a19=_0x5cc13c[_0x40bdcd(0x1b3)][0x1],_0x146bd4=_0x5cc13c[_0x40bdcd(0x1b3)][0x2],_0x37011d=[_0x40bdcd(0x1b0),_0x40bdcd(0x1bc)][_0x40bdcd(0x1ba)](_0x524a19||''),_0x2590e9=_0x5cc13c[_0x40bdcd(0x1b3)][_0x40bdcd(0x1c9)]>=0x3;if(_0x146bd4===_0x40bdcd(0x1c2)||_0x5cc13c['flags'][_0x40bdcd(0x1b9)])return a29_0x30f383(ConfigHelp,{});const _0x1b6349=readConfig();if(_0x524a19===_0x40bdcd(0x1b0)){if(_0x146bd4){const _0x182d2e=_0x5cc13c[_0x40bdcd(0x1b3)][0x3];if(typeof _0x182d2e!==_0x40bdcd(0x1a7)){if(_0x146bd4===_0x40bdcd(0x1c0)&&![_0x40bdcd(0x1c7),_0x40bdcd(0x1b6)]['includes'](_0x182d2e))return a29_0x30f383(Box,{'children':a29_0x30f383(Text,{'color':'red','children':_0x40bdcd(0x1a8)})});const _0x27a2d9=isInProject(),_0x3b1a86=_0x27a2d9?projectConfigPath:globalConfigPath;let _0x2a53f2={};try{if(existsSync(_0x3b1a86)){const _0x76fcd4=readFileSync(_0x3b1a86,{'encoding':'utf8'});_0x76fcd4&&(_0x2a53f2=JSON['parse'](_0x76fcd4));}}catch(_0xa2f5a){}if(typeof _0x182d2e!=='string'||_0x182d2e[_0x40bdcd(0x1c9)]>0x1f4)return a29_0x30f383(Box,{'children':a29_0x30f383(Text,{'color':_0x40bdcd(0x1bd),'children':'配置值无效或过长'})});let _0x48b1e8=_0x146bd4;_0x146bd4===_0x40bdcd(0x1a6)&&(_0x48b1e8=_0x40bdcd(0x1c4),delete _0x2a53f2[_0x40bdcd(0x1a6)]);_0x146bd4==='appcode'&&delete _0x2a53f2[_0x40bdcd(0x1a6)];_0x2a53f2[_0x48b1e8]=_0x182d2e;try{const _0x4689b9=a29_0x52203c['dirname'](_0x3b1a86);!existsSync(_0x4689b9)&&a29_0x512efe['mkdirSync'](_0x4689b9,{'recursive':!![]});const _0x36b2b7=_0x3b1a86+_0x40bdcd(0x1bf);writeFileSync(_0x36b2b7,JSON[_0x40bdcd(0x1aa)](_0x2a53f2,null,0x2),{'encoding':_0x40bdcd(0x1ad),'mode':0x180}),a29_0x512efe[_0x40bdcd(0x1c3)](_0x36b2b7,_0x3b1a86);if(_0x146bd4===_0x40bdcd(0x1c0)){const _0x4f8102=_0x27a2d9?'项目':'全局';console[_0x40bdcd(0x1a4)]('✓\x20'+_0x4f8102+_0x40bdcd(0x1c1)+_0x182d2e);}}catch(_0x59c322){const _0x539514=_0x3b1a86+'.tmp';try{existsSync(_0x539514)&&a29_0x512efe[_0x40bdcd(0x1b1)](_0x539514);}catch(_0x21f336){}return logger[_0x40bdcd(0x1c6)](_0x40bdcd(0x1bb),_0x40bdcd(0x1b2),{'error':_0x59c322 instanceof Error?_0x59c322['message']:String(_0x59c322),'configKey':_0x146bd4,'configValue':_0x182d2e,'targetConfigPath':_0x3b1a86}),a29_0x30f383(Box,{'children':a29_0x3e19d7(Text,{'color':'red','children':[_0x40bdcd(0x1ae),_0x59c322 instanceof Error?_0x59c322[_0x40bdcd(0x1af)]:String(_0x59c322)]})});}return null;}return a29_0x30f383(Box,{'children':a29_0x30f383(Text,{'color':_0x40bdcd(0x1bd),'children':_0x40bdcd(0x1c5)})});}}if(_0x524a19===_0x40bdcd(0x1bc)){if(_0x146bd4){let _0x44800=_0x146bd4;return _0x146bd4===_0x40bdcd(0x1a6)&&(_0x44800=_0x40bdcd(0x1c4)),console[_0x40bdcd(0x1a4)](_0x1b6349[_0x44800]||_0x40bdcd(0x1a7)),null;}return null;}if(_0x524a19==='list')return console[_0x40bdcd(0x1a4)](JSON[_0x40bdcd(0x1aa)](_0x1b6349,null,0x2)),null;if(!_0x37011d||!_0x2590e9)return a29_0x30f383(ConfigHelp,{});return null;}
@@ -1 +1 @@
1
- const a30_0xd069e0=a30_0x4ba4;function a30_0x291f(){const _0x40321f=['1456364Rvtcwm','59829708sKjCBd','369HzKApU','47200KWNadm','11rZRJkb','4146pjsLlk','https://user-daily.lovrabet.com','44093CeNuBC','1498haCgIV','online','https://api.lovrabet.com','7745tNkuyX','368TUQqcH','3339312tvuwym','2985PfBsyg'];a30_0x291f=function(){return _0x40321f;};return a30_0x291f();}(function(_0x477ae5,_0x4815a0){const _0x4a6bf1=a30_0x4ba4,_0x544da1=_0x477ae5();while(!![]){try{const _0x502384=-parseInt(_0x4a6bf1(0xac))/0x1+parseInt(_0x4a6bf1(0xa5))/0x2*(-parseInt(_0x4a6bf1(0xab))/0x3)+-parseInt(_0x4a6bf1(0xaa))/0x4+parseInt(_0x4a6bf1(0xa8))/0x5*(-parseInt(_0x4a6bf1(0xa2))/0x6)+-parseInt(_0x4a6bf1(0xa4))/0x7*(-parseInt(_0x4a6bf1(0xa9))/0x8)+parseInt(_0x4a6bf1(0xae))/0x9*(-parseInt(_0x4a6bf1(0xaf))/0xa)+parseInt(_0x4a6bf1(0xa1))/0xb*(parseInt(_0x4a6bf1(0xad))/0xc);if(_0x502384===_0x4815a0)break;else _0x544da1['push'](_0x544da1['shift']());}catch(_0x30cbc5){_0x544da1['push'](_0x544da1['shift']());}}}(a30_0x291f,0xee185));import{getEnv}from'./env.js';function a30_0x4ba4(_0x20136e,_0x202c91){const _0x291f88=a30_0x291f();return a30_0x4ba4=function(_0x4ba4ec,_0x3f6c53){_0x4ba4ec=_0x4ba4ec-0xa1;let _0x1feed6=_0x291f88[_0x4ba4ec];return _0x1feed6;},a30_0x4ba4(_0x20136e,_0x202c91);}export const getUserDomain=()=>getEnv()===a30_0xd069e0(0xa6)?'https://user.lovrabet.com':a30_0xd069e0(0xa3);export const getApiDomain=()=>getEnv()===a30_0xd069e0(0xa6)?a30_0xd069e0(0xa7):'https://daily-api.lovrabet.com';
1
+ const a30_0x513c41=a30_0x2fb3;(function(_0x5ca26f,_0x44684e){const _0x126f87=a30_0x2fb3,_0x47bb71=_0x5ca26f();while(!![]){try{const _0x50f78e=parseInt(_0x126f87(0x12f))/0x1*(-parseInt(_0x126f87(0x12d))/0x2)+-parseInt(_0x126f87(0x128))/0x3+-parseInt(_0x126f87(0x125))/0x4+-parseInt(_0x126f87(0x130))/0x5*(parseInt(_0x126f87(0x12b))/0x6)+parseInt(_0x126f87(0x127))/0x7*(-parseInt(_0x126f87(0x124))/0x8)+-parseInt(_0x126f87(0x12c))/0x9+parseInt(_0x126f87(0x12e))/0xa*(parseInt(_0x126f87(0x129))/0xb);if(_0x50f78e===_0x44684e)break;else _0x47bb71['push'](_0x47bb71['shift']());}catch(_0x122d74){_0x47bb71['push'](_0x47bb71['shift']());}}}(a30_0x2ea9,0x3adf1));function a30_0x2fb3(_0x47fd2c,_0x1dfa05){const _0x2ea9ec=a30_0x2ea9();return a30_0x2fb3=function(_0x2fb3b0,_0x55bf1c){_0x2fb3b0=_0x2fb3b0-0x124;let _0x2cd288=_0x2ea9ec[_0x2fb3b0];return _0x2cd288;},a30_0x2fb3(_0x47fd2c,_0x1dfa05);}import{getEnv}from'./env.js';export const getUserDomain=()=>getEnv()==='online'?'https://user.lovrabet.com':a30_0x513c41(0x126);function a30_0x2ea9(){const _0x1f4521=['280vkWXFe','84492YcpqqU','35tsJcGi','online','8TqXcMi','219060nMZvVi','https://user-daily.lovrabet.com','1504377pTOtIS','1168209tLGVUt','636130SygOAu','https://daily-api.lovrabet.com','69636AhGNQL','2698326VyaSwr','8qjzttn'];a30_0x2ea9=function(){return _0x1f4521;};return a30_0x2ea9();}export const getApiDomain=()=>getEnv()===a30_0x513c41(0x131)?'https://api.lovrabet.com':a30_0x513c41(0x12a);
@@ -1 +1 @@
1
- const a31_0x334b3a=a31_0x5d9d;function a31_0x5d9d(_0x506ecb,_0x374d7d){const _0x266720=a31_0x2667();return a31_0x5d9d=function(_0x5d9d2e,_0x3e2a41){_0x5d9d2e=_0x5d9d2e-0x128;let _0x10407c=_0x266720[_0x5d9d2e];return _0x10407c;},a31_0x5d9d(_0x506ecb,_0x374d7d);}function a31_0x2667(){const _0x4c3d6c=['313122cuHRga','online','1786347rmrvrA','888BWYiGT','28114LaVNUh','LOVRABET_ENV','24FLeocR','11810aUuTUy','1012398jQoRku','425901eogdsl','1095716vOIrSK','env'];a31_0x2667=function(){return _0x4c3d6c;};return a31_0x2667();}(function(_0xd6fb21,_0x81710){const _0x26c870=a31_0x5d9d,_0x4096e6=_0xd6fb21();while(!![]){try{const _0x1e0631=parseInt(_0x26c870(0x133))/0x1+-parseInt(_0x26c870(0x12b))/0x2+parseInt(_0x26c870(0x12f))/0x3+-parseInt(_0x26c870(0x131))/0x4+-parseInt(_0x26c870(0x12e))/0x5*(-parseInt(_0x26c870(0x12a))/0x6)+parseInt(_0x26c870(0x130))/0x7+parseInt(_0x26c870(0x12d))/0x8*(-parseInt(_0x26c870(0x129))/0x9);if(_0x1e0631===_0x81710)break;else _0x4096e6['push'](_0x4096e6['shift']());}catch(_0x579e12){_0x4096e6['push'](_0x4096e6['shift']());}}}(a31_0x2667,0x2b5a4));let env=process[a31_0x334b3a(0x132)][a31_0x334b3a(0x12c)]||a31_0x334b3a(0x128);export function getEnv(){return env;}export function initEnv(_0x4e79ad){env=_0x4e79ad;}
1
+ const a31_0x594d1c=a31_0x46b3;function a31_0x46b3(_0x39c47f,_0x516c86){const _0x4dfdfe=a31_0x4dfd();return a31_0x46b3=function(_0x46b3c6,_0x29dde3){_0x46b3c6=_0x46b3c6-0x133;let _0x4c1525=_0x4dfdfe[_0x46b3c6];return _0x4c1525;},a31_0x46b3(_0x39c47f,_0x516c86);}(function(_0x2963a9,_0x4fd29e){const _0x10da08=a31_0x46b3,_0x419945=_0x2963a9();while(!![]){try{const _0x3aa689=-parseInt(_0x10da08(0x13a))/0x1*(-parseInt(_0x10da08(0x133))/0x2)+-parseInt(_0x10da08(0x139))/0x3+parseInt(_0x10da08(0x135))/0x4*(-parseInt(_0x10da08(0x13b))/0x5)+parseInt(_0x10da08(0x136))/0x6+-parseInt(_0x10da08(0x140))/0x7*(parseInt(_0x10da08(0x138))/0x8)+-parseInt(_0x10da08(0x13f))/0x9*(parseInt(_0x10da08(0x137))/0xa)+parseInt(_0x10da08(0x13e))/0xb;if(_0x3aa689===_0x4fd29e)break;else _0x419945['push'](_0x419945['shift']());}catch(_0x4cc768){_0x419945['push'](_0x419945['shift']());}}}(a31_0x4dfd,0x9128a));function a31_0x4dfd(){const _0x5f1c7c=['32fFkItA','2389140edndVj','225643velSiD','2085130mRtLQB','env','LOVRABET_ENV','26568322ScvARj','27477XtWIto','1402289lWSVAn','2yNmskW','online','8vfwGIu','4675212TeyBPK','1290UKplDl'];a31_0x4dfd=function(){return _0x5f1c7c;};return a31_0x4dfd();}let env=process[a31_0x594d1c(0x13c)][a31_0x594d1c(0x13d)]||a31_0x594d1c(0x134);export function getEnv(){return env;}export function initEnv(_0x20dc73){env=_0x20dc73;}
@@ -1 +1 @@
1
- (function(_0x2abeef,_0x5d2d41){const _0x37df63=a32_0x2b57,_0x291179=_0x2abeef();while(!![]){try{const _0x5c6a7e=parseInt(_0x37df63(0x1b8))/0x1*(-parseInt(_0x37df63(0x1c4))/0x2)+-parseInt(_0x37df63(0x1d2))/0x3+-parseInt(_0x37df63(0x1b1))/0x4*(-parseInt(_0x37df63(0x19a))/0x5)+parseInt(_0x37df63(0x1bb))/0x6*(-parseInt(_0x37df63(0x1ab))/0x7)+-parseInt(_0x37df63(0x199))/0x8+-parseInt(_0x37df63(0x198))/0x9+parseInt(_0x37df63(0x1b2))/0xa*(parseInt(_0x37df63(0x1a4))/0xb);if(_0x5c6a7e===_0x5d2d41)break;else _0x291179['push'](_0x291179['shift']());}catch(_0x21349b){_0x291179['push'](_0x291179['shift']());}}}(a32_0x5835,0xed5e9));import{jsx as a32_0x69b5cc,jsxs as a32_0x42aea9,Fragment as a32_0x5a05c4}from'react/jsx-runtime';function a32_0x2b57(_0x2f7183,_0x46acb3){const _0x583518=a32_0x5835();return a32_0x2b57=function(_0x2b5709,_0x55c77d){_0x2b5709=_0x2b5709-0x195;let _0x316a93=_0x583518[_0x2b5709];return _0x316a93;},a32_0x2b57(_0x2f7183,_0x46acb3);}import{useState}from'react';import{Text,Box,useInput}from'ink';import{getIsSessionValid}from'../auth/is-session-valid.js';function a32_0x5835(){const _0xe930c=['login-process','green','confirm-api-pull','绑定应用AppCode可自动配置\x20API,如:\x20app-c4c89304\x20(直接回车跳过)','\x20\x20使用\x20←→\x20选择,回车确认','includes','return','√\x20检测到有效登录状态','432447LyGAmI','应用AppCode','label','cyan','leftArrow','应用AppCode长度不能超过\x20100\x20个字符','7634610PsASTv','7576624ikftfO','7650EeOvWs','项目名','login','yellow','\x20\x20推荐选择\x20Yes,登录后可自动拉取并配置\x20API\x20接口','gray','column','登录失败','project-name','app-code','3059419yMYHlS','trim','跳过登录','\x20检查中...','creating','*\x20是否要先登录以便拉取\x20API\x20配置?','env','1876hTOhmt','api-pull','\x20直接回车确认,或输入自定义名称','login-check','slice','!\x20未检测到有效登录','208mgfNOF','160rYNWDR','[可选]:\x20','应用AppCode不合法','登录状态','\x20登录中...','backspace','821614xOzHdQ','rightArrow','\x20←\x20','17826rtUDNr','*\x20创建新项目','项目名只能以字母或数字开头,且只包含字母、数字、-\x20和\x20_','项目名不合法','my-app','*\x20正在登录,请前往浏览器完成登录...','online','login-prompt','length','2DVVvrf','red','应用AppCode只能包含字母、数字、连字符和下划线,且必须以字母或数字开头','delete','*\x20应用AppCode\x20','已登录'];a32_0x5835=function(){return _0xe930c;};return a32_0x5835();}import{authServer}from'../auth/auth-server.js';import{readConfig}from'../utils/config.js';export function EnhancedGuidedCreate(_0x524ad1){const _0x29e139=a32_0x2b57,{onCreate:_0x10cb49,env:_0xb43e40}=_0x524ad1,[_0x3944cd,_0x41aaee]=useState('project-name'),[_0x35aaa5,_0x218c14]=useState(''),[_0x2340e4,_0x3f6c44]=useState(''),[_0x4cd4db,_0x411143]=useState(''),[_0xb58d6d,_0x8c6a3b]=useState(''),[_0x5c5284,_0x4c6bd3]=useState([]),[_0x488509,_0x513797]=useState(null),[_0x1ca217,_0x1af4c1]=useState(![]),[_0x1c5c98,_0x4fb16e]=useState(![]),[_0x6791ba,_0x5bee78]=useState(![]),[_0x2b84c8,_0x5f195d]=useState(0x0),[_0x31ace5,_0x354492]=useState(0x0),_0xabf112=_0x29e139(0x1bf),_0x4c4e65=readConfig(),_0x29d2db=typeof _0x4c4e65[_0x29e139(0x1aa)]==='string'?_0x4c4e65[_0x29e139(0x1aa)]:undefined;function _0x1ac175(_0x30da97){const _0x183f0c=_0x29e139;if(_0x30da97[_0x183f0c(0x1c3)]>0x32)return{'valid':![],'message':'项目名长度不能超过\x2050\x20个字符'};const _0x4c848d=/^[A-Za-z0-9][A-Za-z0-9_-]*$/;if(_0x30da97?.[_0x183f0c(0x1a5)]()&&!_0x4c848d['test'](_0x30da97))return{'valid':![],'message':_0x183f0c(0x1bd)};return{'valid':!![]};}function _0x20f717(_0x1482d5){const _0x527e32=_0x29e139;if(!_0x1482d5[_0x527e32(0x1a5)]())return{'valid':!![]};if(_0x1482d5[_0x527e32(0x1c3)]>0x64)return{'valid':![],'message':_0x527e32(0x197)};const _0x58763a=/^[a-zA-Z0-9][a-zA-Z0-9_-]*$/;if(!_0x58763a['test'](_0x1482d5))return{'valid':![],'message':_0x527e32(0x1c6)};return{'valid':!![]};}async function _0x553971(){_0x1af4c1(!![]);try{const _0x3e2200=await getIsSessionValid();return _0x513797(_0x3e2200),_0x3e2200;}catch(_0x1f1943){return _0x513797(![]),![];}finally{_0x1af4c1(![]);}}async function _0x3ed879(){_0x4fb16e(!![]);try{const _0x4130e7=await authServer({'silent':!![]});return _0x513797(_0x4130e7),_0x4130e7;}catch(_0x1fc481){return _0x513797(![]),![];}finally{_0x4fb16e(![]);}}return useInput(async(_0x55d695,_0x45a39d)=>{const _0x155fd6=_0x29e139;if(_0x45a39d[_0x155fd6(0x196)]||_0x45a39d[_0x155fd6(0x1b9)]){if(_0x3944cd===_0x155fd6(0x1cc)){_0x5f195d(_0x4728f1=>_0x4728f1===0x0?0x1:0x0);return;}if(_0x3944cd===_0x155fd6(0x1c2)){_0x354492(_0x3cd78e=>_0x3cd78e===0x0?0x1:0x0);return;}}if(_0x45a39d[_0x155fd6(0x1d0)]){if(_0x3944cd===_0x155fd6(0x1a2)){const _0x356582=_0x4cd4db['trim']()||_0xabf112;if(_0xb58d6d)return;_0x218c14(_0x356582),_0x4c6bd3([{'step':_0x155fd6(0x1a2),'label':_0x155fd6(0x19b),'value':_0x356582}]),_0x411143(''),_0x8c6a3b(''),_0x41aaee(_0x155fd6(0x1a3));return;}if(_0x3944cd===_0x155fd6(0x1a3)){if(_0xb58d6d)return;const _0x4fc8e1=_0x4cd4db[_0x155fd6(0x1a5)]();_0x3f6c44(_0x4fc8e1),_0x4c6bd3(_0x50d1d5=>[..._0x50d1d5,{'step':'app-code','label':_0x155fd6(0x1d3),'value':_0x4fc8e1||'未设置'}]),_0x411143(''),_0x8c6a3b('');if(_0x4fc8e1){_0x41aaee(_0x155fd6(0x1ae));const _0x5e7636=await _0x553971();_0x5e7636?_0x41aaee(_0x155fd6(0x1cc)):_0x41aaee(_0x155fd6(0x1c2));}else{const _0x131b0c=_0xb43e40||_0x29d2db||_0x155fd6(0x1c1);_0x10cb49({'projectName':_0x35aaa5,'appCode':undefined,'pullApi':![],'env':_0x131b0c}),_0x41aaee(_0x155fd6(0x1a8));}return;}if(_0x3944cd==='confirm-api-pull'){const _0x20b11a=_0x2b84c8===0x0;_0x5bee78(_0x20b11a),_0x4c6bd3(_0x593cfd=>[..._0x593cfd,{'step':_0x155fd6(0x1ac),'label':'拉取API配置','value':_0x20b11a?'是':'否'}]);const _0xf58b34=_0xb43e40||_0x29d2db||_0x155fd6(0x1c1);_0x10cb49({'projectName':_0x35aaa5,'appCode':_0x2340e4,'pullApi':_0x20b11a,'env':_0xf58b34}),_0x41aaee(_0x155fd6(0x1a8));return;}if(_0x3944cd===_0x155fd6(0x1c2)){const _0x549076=_0x31ace5===0x0;if(_0x549076){_0x41aaee('login-process');const _0x1d844b=await _0x3ed879();if(_0x1d844b)_0x4c6bd3(_0x277713=>[..._0x277713,{'step':'login','label':_0x155fd6(0x1b5),'value':_0x155fd6(0x1c9)}]),_0x41aaee(_0x155fd6(0x1cc));else{_0x4c6bd3(_0x56979b=>[..._0x56979b,{'step':'login','label':_0x155fd6(0x1b5),'value':_0x155fd6(0x1a1)}]);const _0x5278ab=_0xb43e40||_0x29d2db||'online';_0x10cb49({'projectName':_0x35aaa5,'appCode':_0x2340e4,'pullApi':![],'env':_0x5278ab}),_0x41aaee(_0x155fd6(0x1a8));}}else{_0x4c6bd3(_0x1af85e=>[..._0x1af85e,{'step':_0x155fd6(0x19c),'label':_0x155fd6(0x1b5),'value':_0x155fd6(0x1a6)}]);const _0x4acd98=_0xb43e40||_0x29d2db||'online';_0x10cb49({'projectName':_0x35aaa5,'appCode':_0x2340e4,'pullApi':![],'env':_0x4acd98}),_0x41aaee(_0x155fd6(0x1a8));}return;}}if(_0x45a39d[_0x155fd6(0x1b7)]||_0x45a39d[_0x155fd6(0x1c7)]){_0x411143(_0x4de2fd=>{const _0x494f08=_0x155fd6,_0x351f0a=_0x4de2fd[_0x494f08(0x1af)](0x0,-0x1);if(_0x3944cd===_0x494f08(0x1a2)){const {valid:_0x1fd128,message:_0x36be5c}=_0x1ac175(_0x351f0a);_0x8c6a3b(_0x1fd128?'':_0x36be5c||_0x494f08(0x1be));}else{if(_0x3944cd===_0x494f08(0x1a3)){const {valid:_0x4063ee,message:_0x4f3f1c}=_0x20f717(_0x351f0a);_0x8c6a3b(_0x4063ee?'':_0x4f3f1c||_0x494f08(0x1b4));}}return _0x351f0a;});return;}if([_0x155fd6(0x1a8),_0x155fd6(0x1ae),_0x155fd6(0x1ca)][_0x155fd6(0x1cf)](_0x3944cd))return;if(_0x3944cd===_0x155fd6(0x1cc)||_0x3944cd===_0x155fd6(0x1c2))return;_0x411143(_0x183a5e=>{const _0x57758e=_0x155fd6,_0x162394=_0x183a5e+_0x55d695;if(_0x3944cd==='project-name'){const {valid:_0x3cac75,message:_0x3345bd}=_0x1ac175(_0x162394);_0x8c6a3b(_0x3cac75?'':_0x3345bd||_0x57758e(0x1be));}else{if(_0x3944cd===_0x57758e(0x1a3)){const {valid:_0xb21f5c,message:_0x5e23ec}=_0x20f717(_0x162394);_0x8c6a3b(_0xb21f5c?'':_0x5e23ec||_0x57758e(0x1b4));}}return _0x162394;});}),a32_0x42aea9(Box,{'flexDirection':_0x29e139(0x1a0),'marginTop':0x1,'children':[_0x5c5284['length']===0x0&&a32_0x69b5cc(Box,{'children':a32_0x69b5cc(Text,{'color':_0x29e139(0x195),'children':_0x29e139(0x1bc)})}),_0x5c5284['map'](_0x342f62=>a32_0x42aea9(Box,{'children':[a32_0x42aea9(Text,{'color':'green','children':['√\x20',_0x342f62[_0x29e139(0x1d4)],':\x20']}),a32_0x69b5cc(Text,{'color':_0x29e139(0x195),'children':_0x342f62['value']})]},_0x342f62['step'])),_0x3944cd===_0x29e139(0x1a2)&&a32_0x42aea9(a32_0x5a05c4,{'children':[a32_0x42aea9(Box,{'children':[a32_0x69b5cc(Text,{'children':'*\x20项目名:\x20'}),_0x4cd4db?a32_0x69b5cc(Text,{'color':'green','children':_0x4cd4db}):a32_0x69b5cc(Text,{'color':'gray','children':_0xabf112}),_0xb58d6d&&a32_0x42aea9(Text,{'color':_0x29e139(0x1c5),'children':[_0x29e139(0x1ba),_0xb58d6d]})]}),!_0xb58d6d&&!_0x4cd4db&&a32_0x69b5cc(Box,{'children':a32_0x69b5cc(Text,{'color':_0x29e139(0x19f),'children':_0x29e139(0x1ad)})})]}),_0x3944cd===_0x29e139(0x1a3)&&a32_0x42aea9(a32_0x5a05c4,{'children':[a32_0x42aea9(Box,{'children':[a32_0x69b5cc(Text,{'children':_0x29e139(0x1c8)}),a32_0x69b5cc(Text,{'color':_0x29e139(0x19f),'children':_0x29e139(0x1b3)}),a32_0x69b5cc(Text,{'color':'green','children':_0x4cd4db}),_0xb58d6d&&a32_0x42aea9(Text,{'color':_0x29e139(0x1c5),'children':['\x20←\x20',_0xb58d6d]})]}),!_0xb58d6d&&a32_0x69b5cc(Box,{'children':a32_0x42aea9(Text,{'color':_0x29e139(0x19f),'children':['\x20',_0x29e139(0x1cd)]})})]}),_0x3944cd==='login-check'&&a32_0x42aea9(Box,{'children':[a32_0x69b5cc(Text,{'children':'*\x20正在检查登录状态...'}),_0x1ca217&&a32_0x69b5cc(Text,{'color':'gray','children':_0x29e139(0x1a7)})]}),_0x3944cd==='confirm-api-pull'&&a32_0x42aea9(a32_0x5a05c4,{'children':[a32_0x69b5cc(Box,{'children':a32_0x69b5cc(Text,{'color':_0x29e139(0x1cb),'children':_0x29e139(0x1d1)})}),a32_0x69b5cc(Box,{'marginTop':0x1,'children':a32_0x69b5cc(Text,{'children':'*\x20是否要自动拉取\x20API\x20配置?'})}),a32_0x42aea9(Box,{'marginLeft':0x2,'children':[a32_0x42aea9(Text,{'color':_0x2b84c8===0x0?_0x29e139(0x1cb):_0x29e139(0x19f),'children':[_0x2b84c8===0x0?'▶\x20':'\x20\x20','Yes']}),a32_0x69b5cc(Text,{'children':'\x20'}),a32_0x42aea9(Text,{'color':_0x2b84c8===0x1?'green':_0x29e139(0x19f),'children':[_0x2b84c8===0x1?'▶\x20':'\x20\x20','No']})]}),a32_0x69b5cc(Box,{'children':a32_0x69b5cc(Text,{'color':_0x29e139(0x19f),'children':_0x29e139(0x1ce)})}),a32_0x69b5cc(Box,{'children':a32_0x69b5cc(Text,{'color':_0x29e139(0x19d),'children':'\x20\x20推荐选择\x20Yes,可自动配置\x20API\x20接口'})})]}),_0x3944cd===_0x29e139(0x1c2)&&a32_0x42aea9(a32_0x5a05c4,{'children':[a32_0x69b5cc(Box,{'children':a32_0x69b5cc(Text,{'color':'yellow','children':_0x29e139(0x1b0)})}),a32_0x69b5cc(Box,{'marginTop':0x1,'children':a32_0x69b5cc(Text,{'children':_0x29e139(0x1a9)})}),a32_0x42aea9(Box,{'marginLeft':0x2,'children':[a32_0x42aea9(Text,{'color':_0x31ace5===0x0?_0x29e139(0x1cb):_0x29e139(0x19f),'children':[_0x31ace5===0x0?'▶\x20':'\x20\x20','Yes']}),a32_0x69b5cc(Text,{'children':'\x20'}),a32_0x42aea9(Text,{'color':_0x31ace5===0x1?'green':_0x29e139(0x19f),'children':[_0x31ace5===0x1?'▶\x20':'\x20\x20','No']})]}),a32_0x69b5cc(Box,{'children':a32_0x69b5cc(Text,{'color':_0x29e139(0x19f),'children':_0x29e139(0x1ce)})}),a32_0x69b5cc(Box,{'children':a32_0x69b5cc(Text,{'color':_0x29e139(0x19d),'children':_0x29e139(0x19e)})})]}),_0x3944cd==='login-process'&&a32_0x42aea9(Box,{'children':[a32_0x69b5cc(Text,{'children':_0x29e139(0x1c0)}),_0x1c5c98&&a32_0x69b5cc(Text,{'color':_0x29e139(0x19f),'children':_0x29e139(0x1b6)})]})]});}
1
+ function a32_0x1ca0(){const _0xb01b83=['42jnMqZj','trim','2707146CUVKdn','\x20←\x20','return','string','项目名','my-app','243970ilAHeo','登录失败','项目名不合法','52EwaCwC','red','login-prompt','gray','应用AppCode不合法','[可选]:\x20','green','*\x20正在检查登录状态...','test','*\x20项目名:\x20','length','24CdJGVh','\x20直接回车确认,或输入自定义名称','delete','应用AppCode','cyan','4796496uXQEGS','绑定应用AppCode可自动配置\x20API,如:\x20app-c4c89304\x20(直接回车跳过)','online','项目名只能以字母或数字开头,且只包含字母、数字、-\x20和\x20_','5851417TPmxUi','project-name','\x20\x20使用\x20←→\x20选择,回车确认','leftArrow','app-code','36474OgawOL','426668nslKDH','10APohNj','confirm-api-pull','login-process','*\x20是否要自动拉取\x20API\x20配置?','*\x20创建新项目','step','Yes','login','login-check','creating','*\x20正在登录,请前往浏览器完成登录...','\x20\x20推荐选择\x20Yes,可自动配置\x20API\x20接口','登录状态','56276OZMpVb','env','yellow','!\x20未检测到有效登录','项目名长度不能超过\x2050\x20个字符','\x20检查中...','跳过登录','应用AppCode只能包含字母、数字、连字符和下划线,且必须以字母或数字开头','\x20登录中...','\x20\x20推荐选择\x20Yes,登录后可自动拉取并配置\x20API\x20接口','value','column','slice','rightArrow','未设置','拉取API配置','已登录','√\x20检测到有效登录状态'];a32_0x1ca0=function(){return _0xb01b83;};return a32_0x1ca0();}(function(_0x44d507,_0xd51d2){const _0x51e61d=a32_0x4e2d,_0xb89e64=_0x44d507();while(!![]){try{const _0x35254d=-parseInt(_0x51e61d(0xff))/0x1*(-parseInt(_0x51e61d(0xe2))/0x2)+parseInt(_0x51e61d(0x10a))/0x3*(-parseInt(_0x51e61d(0xd4))/0x4)+-parseInt(_0x51e61d(0xfc))/0x5+parseInt(_0x51e61d(0xd3))/0x6*(parseInt(_0x51e61d(0xf4))/0x7)+-parseInt(_0x51e61d(0xca))/0x8+-parseInt(_0x51e61d(0xf6))/0x9*(-parseInt(_0x51e61d(0xd5))/0xa)+parseInt(_0x51e61d(0xce))/0xb;if(_0x35254d===_0xd51d2)break;else _0xb89e64['push'](_0xb89e64['shift']());}catch(_0x15d47d){_0xb89e64['push'](_0xb89e64['shift']());}}}(a32_0x1ca0,0xcaceb));import{jsx as a32_0xeb34ff,jsxs as a32_0x28e62d,Fragment as a32_0x3d8b73}from'react/jsx-runtime';function a32_0x4e2d(_0x36fb20,_0x2ed09b){const _0x1ca053=a32_0x1ca0();return a32_0x4e2d=function(_0x4e2d3c,_0xb0691e){_0x4e2d3c=_0x4e2d3c-0xc9;let _0x275727=_0x1ca053[_0x4e2d3c];return _0x275727;},a32_0x4e2d(_0x36fb20,_0x2ed09b);}import{useState}from'react';import{Text,Box,useInput}from'ink';import{getIsSessionValid}from'../auth/is-session-valid.js';import{authServer}from'../auth/auth-server.js';import{readConfig}from'../utils/config.js';export function EnhancedGuidedCreate(_0x9a7a89){const _0x8028f7=a32_0x4e2d,{onCreate:_0x2caba7,env:_0x313320}=_0x9a7a89,[_0x7ff5ad,_0x268871]=useState('project-name'),[_0x46a61a,_0x185915]=useState(''),[_0x11cf59,_0x18b5d9]=useState(''),[_0x1c17ed,_0x5f6274]=useState(''),[_0x5a9a96,_0x2e05f7]=useState(''),[_0x40ea3d,_0x31a745]=useState([]),[_0xb8949b,_0x538613]=useState(null),[_0x5f2131,_0x39c0eb]=useState(![]),[_0x3adaa1,_0x80837d]=useState(![]),[_0x50e9dc,_0x2a821a]=useState(![]),[_0x36d412,_0x2d8bda]=useState(0x0),[_0x2362a0,_0x412192]=useState(0x0),_0x39cf10=_0x8028f7(0xfb),_0x664b00=readConfig(),_0x11a0bb=typeof _0x664b00['env']===_0x8028f7(0xf9)?_0x664b00[_0x8028f7(0xe3)]:undefined;function _0x29e07a(_0x5ea850){const _0x203e1b=_0x8028f7;if(_0x5ea850[_0x203e1b(0x109)]>0x32)return{'valid':![],'message':_0x203e1b(0xe6)};const _0x2ff0c2=/^[A-Za-z0-9][A-Za-z0-9_-]*$/;if(_0x5ea850?.[_0x203e1b(0xf5)]()&&!_0x2ff0c2[_0x203e1b(0x107)](_0x5ea850))return{'valid':![],'message':_0x203e1b(0xcd)};return{'valid':!![]};}function _0x4a1d38(_0x3b055c){const _0x25d5fd=_0x8028f7;if(!_0x3b055c[_0x25d5fd(0xf5)]())return{'valid':!![]};if(_0x3b055c[_0x25d5fd(0x109)]>0x64)return{'valid':![],'message':'应用AppCode长度不能超过\x20100\x20个字符'};const _0x5b037b=/^[a-zA-Z0-9][a-zA-Z0-9_-]*$/;if(!_0x5b037b['test'](_0x3b055c))return{'valid':![],'message':_0x25d5fd(0xe9)};return{'valid':!![]};}async function _0xffedd1(){_0x39c0eb(!![]);try{const _0x245b7c=await getIsSessionValid();return _0x538613(_0x245b7c),_0x245b7c;}catch(_0x53df40){return _0x538613(![]),![];}finally{_0x39c0eb(![]);}}async function _0xae48d4(){_0x80837d(!![]);try{const _0x39e365=await authServer({'silent':!![]});return _0x538613(_0x39e365),_0x39e365;}catch(_0x4a60f2){return _0x538613(![]),![];}finally{_0x80837d(![]);}}return useInput(async(_0xcf5661,_0x3a4ac6)=>{const _0x335d0e=_0x8028f7;if(_0x3a4ac6[_0x335d0e(0xd1)]||_0x3a4ac6[_0x335d0e(0xef)]){if(_0x7ff5ad===_0x335d0e(0xd6)){_0x2d8bda(_0x1cde02=>_0x1cde02===0x0?0x1:0x0);return;}if(_0x7ff5ad===_0x335d0e(0x101)){_0x412192(_0x58eff3=>_0x58eff3===0x0?0x1:0x0);return;}}if(_0x3a4ac6[_0x335d0e(0xf8)]){if(_0x7ff5ad==='project-name'){const _0x5dd89d=_0x1c17ed[_0x335d0e(0xf5)]()||_0x39cf10;if(_0x5a9a96)return;_0x185915(_0x5dd89d),_0x31a745([{'step':'project-name','label':_0x335d0e(0xfa),'value':_0x5dd89d}]),_0x5f6274(''),_0x2e05f7(''),_0x268871('app-code');return;}if(_0x7ff5ad===_0x335d0e(0xd2)){if(_0x5a9a96)return;const _0x80c505=_0x1c17ed[_0x335d0e(0xf5)]();_0x18b5d9(_0x80c505),_0x31a745(_0x55c537=>[..._0x55c537,{'step':_0x335d0e(0xd2),'label':_0x335d0e(0x10d),'value':_0x80c505||_0x335d0e(0xf0)}]),_0x5f6274(''),_0x2e05f7('');if(_0x80c505){_0x268871(_0x335d0e(0xdd));const _0x51a888=await _0xffedd1();_0x51a888?_0x268871(_0x335d0e(0xd6)):_0x268871('login-prompt');}else{const _0x190715=_0x313320||_0x11a0bb||_0x335d0e(0xcc);_0x2caba7({'projectName':_0x46a61a,'appCode':undefined,'pullApi':![],'env':_0x190715}),_0x268871('creating');}return;}if(_0x7ff5ad==='confirm-api-pull'){const _0x379495=_0x36d412===0x0;_0x2a821a(_0x379495),_0x31a745(_0x59767d=>[..._0x59767d,{'step':'api-pull','label':_0x335d0e(0xf1),'value':_0x379495?'是':'否'}]);const _0x49cffb=_0x313320||_0x11a0bb||'online';_0x2caba7({'projectName':_0x46a61a,'appCode':_0x11cf59,'pullApi':_0x379495,'env':_0x49cffb}),_0x268871(_0x335d0e(0xde));return;}if(_0x7ff5ad==='login-prompt'){const _0x11340e=_0x2362a0===0x0;if(_0x11340e){_0x268871('login-process');const _0x29b6b1=await _0xae48d4();if(_0x29b6b1)_0x31a745(_0x2c3a73=>[..._0x2c3a73,{'step':_0x335d0e(0xdc),'label':_0x335d0e(0xe1),'value':_0x335d0e(0xf2)}]),_0x268871(_0x335d0e(0xd6));else{_0x31a745(_0x28d87d=>[..._0x28d87d,{'step':_0x335d0e(0xdc),'label':_0x335d0e(0xe1),'value':_0x335d0e(0xfd)}]);const _0xebf2b7=_0x313320||_0x11a0bb||_0x335d0e(0xcc);_0x2caba7({'projectName':_0x46a61a,'appCode':_0x11cf59,'pullApi':![],'env':_0xebf2b7}),_0x268871('creating');}}else{_0x31a745(_0x3d2763=>[..._0x3d2763,{'step':'login','label':_0x335d0e(0xe1),'value':_0x335d0e(0xe8)}]);const _0x1ee91c=_0x313320||_0x11a0bb||'online';_0x2caba7({'projectName':_0x46a61a,'appCode':_0x11cf59,'pullApi':![],'env':_0x1ee91c}),_0x268871('creating');}return;}}if(_0x3a4ac6['backspace']||_0x3a4ac6[_0x335d0e(0x10c)]){_0x5f6274(_0x22ac61=>{const _0x20ee22=_0x335d0e,_0x263ed5=_0x22ac61[_0x20ee22(0xee)](0x0,-0x1);if(_0x7ff5ad==='project-name'){const {valid:_0x1d339f,message:_0x3d1524}=_0x29e07a(_0x263ed5);_0x2e05f7(_0x1d339f?'':_0x3d1524||_0x20ee22(0xfe));}else{if(_0x7ff5ad===_0x20ee22(0xd2)){const {valid:_0x44db05,message:_0x1df750}=_0x4a1d38(_0x263ed5);_0x2e05f7(_0x44db05?'':_0x1df750||_0x20ee22(0x103));}}return _0x263ed5;});return;}if([_0x335d0e(0xde),_0x335d0e(0xdd),_0x335d0e(0xd7)]['includes'](_0x7ff5ad))return;if(_0x7ff5ad==='confirm-api-pull'||_0x7ff5ad===_0x335d0e(0x101))return;_0x5f6274(_0x4d4aa8=>{const _0x299d76=_0x335d0e,_0x51e6f1=_0x4d4aa8+_0xcf5661;if(_0x7ff5ad===_0x299d76(0xcf)){const {valid:_0x41fa7b,message:_0x14a0b3}=_0x29e07a(_0x51e6f1);_0x2e05f7(_0x41fa7b?'':_0x14a0b3||_0x299d76(0xfe));}else{if(_0x7ff5ad===_0x299d76(0xd2)){const {valid:_0x256cab,message:_0x30531f}=_0x4a1d38(_0x51e6f1);_0x2e05f7(_0x256cab?'':_0x30531f||_0x299d76(0x103));}}return _0x51e6f1;});}),a32_0x28e62d(Box,{'flexDirection':_0x8028f7(0xed),'marginTop':0x1,'children':[_0x40ea3d[_0x8028f7(0x109)]===0x0&&a32_0xeb34ff(Box,{'children':a32_0xeb34ff(Text,{'color':_0x8028f7(0xc9),'children':_0x8028f7(0xd9)})}),_0x40ea3d['map'](_0x4daa69=>a32_0x28e62d(Box,{'children':[a32_0x28e62d(Text,{'color':_0x8028f7(0x105),'children':['√\x20',_0x4daa69['label'],':\x20']}),a32_0xeb34ff(Text,{'color':'cyan','children':_0x4daa69[_0x8028f7(0xec)]})]},_0x4daa69[_0x8028f7(0xda)])),_0x7ff5ad==='project-name'&&a32_0x28e62d(a32_0x3d8b73,{'children':[a32_0x28e62d(Box,{'children':[a32_0xeb34ff(Text,{'children':_0x8028f7(0x108)}),_0x1c17ed?a32_0xeb34ff(Text,{'color':_0x8028f7(0x105),'children':_0x1c17ed}):a32_0xeb34ff(Text,{'color':'gray','children':_0x39cf10}),_0x5a9a96&&a32_0x28e62d(Text,{'color':_0x8028f7(0x100),'children':['\x20←\x20',_0x5a9a96]})]}),!_0x5a9a96&&!_0x1c17ed&&a32_0xeb34ff(Box,{'children':a32_0xeb34ff(Text,{'color':'gray','children':_0x8028f7(0x10b)})})]}),_0x7ff5ad===_0x8028f7(0xd2)&&a32_0x28e62d(a32_0x3d8b73,{'children':[a32_0x28e62d(Box,{'children':[a32_0xeb34ff(Text,{'children':'*\x20应用AppCode\x20'}),a32_0xeb34ff(Text,{'color':_0x8028f7(0x102),'children':_0x8028f7(0x104)}),a32_0xeb34ff(Text,{'color':_0x8028f7(0x105),'children':_0x1c17ed}),_0x5a9a96&&a32_0x28e62d(Text,{'color':_0x8028f7(0x100),'children':[_0x8028f7(0xf7),_0x5a9a96]})]}),!_0x5a9a96&&a32_0xeb34ff(Box,{'children':a32_0x28e62d(Text,{'color':_0x8028f7(0x102),'children':['\x20',_0x8028f7(0xcb)]})})]}),_0x7ff5ad===_0x8028f7(0xdd)&&a32_0x28e62d(Box,{'children':[a32_0xeb34ff(Text,{'children':_0x8028f7(0x106)}),_0x5f2131&&a32_0xeb34ff(Text,{'color':_0x8028f7(0x102),'children':_0x8028f7(0xe7)})]}),_0x7ff5ad===_0x8028f7(0xd6)&&a32_0x28e62d(a32_0x3d8b73,{'children':[a32_0xeb34ff(Box,{'children':a32_0xeb34ff(Text,{'color':_0x8028f7(0x105),'children':_0x8028f7(0xf3)})}),a32_0xeb34ff(Box,{'marginTop':0x1,'children':a32_0xeb34ff(Text,{'children':_0x8028f7(0xd8)})}),a32_0x28e62d(Box,{'marginLeft':0x2,'children':[a32_0x28e62d(Text,{'color':_0x36d412===0x0?_0x8028f7(0x105):_0x8028f7(0x102),'children':[_0x36d412===0x0?'▶\x20':'\x20\x20','Yes']}),a32_0xeb34ff(Text,{'children':'\x20'}),a32_0x28e62d(Text,{'color':_0x36d412===0x1?_0x8028f7(0x105):_0x8028f7(0x102),'children':[_0x36d412===0x1?'▶\x20':'\x20\x20','No']})]}),a32_0xeb34ff(Box,{'children':a32_0xeb34ff(Text,{'color':_0x8028f7(0x102),'children':_0x8028f7(0xd0)})}),a32_0xeb34ff(Box,{'children':a32_0xeb34ff(Text,{'color':'yellow','children':_0x8028f7(0xe0)})})]}),_0x7ff5ad===_0x8028f7(0x101)&&a32_0x28e62d(a32_0x3d8b73,{'children':[a32_0xeb34ff(Box,{'children':a32_0xeb34ff(Text,{'color':_0x8028f7(0xe4),'children':_0x8028f7(0xe5)})}),a32_0xeb34ff(Box,{'marginTop':0x1,'children':a32_0xeb34ff(Text,{'children':'*\x20是否要先登录以便拉取\x20API\x20配置?'})}),a32_0x28e62d(Box,{'marginLeft':0x2,'children':[a32_0x28e62d(Text,{'color':_0x2362a0===0x0?'green':'gray','children':[_0x2362a0===0x0?'▶\x20':'\x20\x20',_0x8028f7(0xdb)]}),a32_0xeb34ff(Text,{'children':'\x20'}),a32_0x28e62d(Text,{'color':_0x2362a0===0x1?_0x8028f7(0x105):_0x8028f7(0x102),'children':[_0x2362a0===0x1?'▶\x20':'\x20\x20','No']})]}),a32_0xeb34ff(Box,{'children':a32_0xeb34ff(Text,{'color':_0x8028f7(0x102),'children':_0x8028f7(0xd0)})}),a32_0xeb34ff(Box,{'children':a32_0xeb34ff(Text,{'color':_0x8028f7(0xe4),'children':_0x8028f7(0xeb)})})]}),_0x7ff5ad===_0x8028f7(0xd7)&&a32_0x28e62d(Box,{'children':[a32_0xeb34ff(Text,{'children':_0x8028f7(0xdf)}),_0x3adaa1&&a32_0xeb34ff(Text,{'color':_0x8028f7(0x102),'children':_0x8028f7(0xea)})]})]});}