@lovrabet/cli 1.1.22 → 1.1.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/add-page/input-page-router.js +1 -1
- package/lib/add-page/main.js +1 -1
- package/lib/add-page/select-page-template.js +1 -1
- package/lib/api/api-doc-ui.js +1 -1
- package/lib/api/api-doc.js +1 -1
- package/lib/api/api-pull-ui.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/api/main.js +1 -1
- package/lib/api/pull-silent.js +1 -1
- package/lib/app-menu/app-menu-sync-ui.js +1 -1
- package/lib/app-menu/create-menu.js +1 -1
- package/lib/app-menu/get-local-pages.js +1 -1
- package/lib/app-menu/get-online-menu-list.js +1 -1
- package/lib/app-menu/valid-url.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/cmd/build-watch.js +1 -1
- package/lib/cmd/build.js +1 -1
- package/lib/cmd/logs.js +1 -1
- package/lib/cmd/preview.js +1 -1
- package/lib/cmd/start.js +1 -1
- package/lib/config/config-help.js +1 -1
- package/lib/config/main.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/create-app/enhanced-guided-create.js +1 -1
- package/lib/create-app/format-elapsed.js +1 -1
- package/lib/create-app/main.js +1 -1
- package/lib/create-app/task-finished.js +1 -1
- package/lib/create-app/task-loading.js +1 -1
- package/lib/create-app/task-running.js +1 -1
- package/lib/create-app/task-time.js +1 -1
- package/lib/create-app/use-copy-project-template.js +1 -1
- package/lib/create-app/use-format-code.js +1 -1
- package/lib/create-app/use-install-dependencies.js +1 -1
- package/lib/help.js +1 -1
- package/lib/init/main.js +1 -1
- package/lib/mcp/cursor.js +1 -1
- package/lib/mcp/main.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/copy-directory.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/router-updater.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/package.json +1 -1
- package/templates/projects/sub-app-react-demo/package-lock.json +4 -4
- package/templates/projects/sub-app-react-demo/package.json +1 -1
- package/templates/rules/lovrabet_rules.mdc.tpl +181 -115
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x317fd2,_0x1f4c81){const _0x28896e=a11_0x51cc,_0x2822ba=_0x317fd2();while(!![]){try{const _0x137a5b=-parseInt(_0x28896e(0x20d))/0x1+parseInt(_0x28896e(0x1e9))/0x2+-parseInt(_0x28896e(0x1ef))/0x3+-parseInt(_0x28896e(0x1f0))/0x4*(parseInt(_0x28896e(0x1e7))/0x5)+parseInt(_0x28896e(0x20f))/0x6*(-parseInt(_0x28896e(0x210))/0x7)+parseInt(_0x28896e(0x20c))/0x8*(-parseInt(_0x28896e(0x205))/0x9)+-parseInt(_0x28896e(0x1f1))/0xa*(-parseInt(_0x28896e(0x1ed))/0xb);if(_0x137a5b===_0x1f4c81)break;else _0x2822ba['push'](_0x2822ba['shift']());}catch(_0x3599a9){_0x2822ba['push'](_0x2822ba['shift']());}}}(a11_0x111e,0xec080));import{getCookie}from'../auth/get-cookie.js';import{getApiDomain}from'../constant/domain.js';import{readConfig}from'../utils/config.js';function a11_0x51cc(_0x29417b,_0x51dead){const _0x111e76=a11_0x111e();return a11_0x51cc=function(_0x51ccfe,_0x27dd85){_0x51ccfe=_0x51ccfe-0x1e2;let _0x487872=_0x111e76[_0x51ccfe];return _0x487872;},a11_0x51cc(_0x29417b,_0x51dead);}import{logger}from'../utils/logger.js';const config=readConfig();export async function createMenu(_0xfc213d){const _0x11d579=a11_0x51cc,_0x146600=config?.[_0x11d579(0x1ec)];if(!_0x146600){const _0x519f97=_0x11d579(0x1f7);logger[_0x11d579(0x20e)](_0x11d579(0x1f2),_0x519f97),console[_0x11d579(0x20e)]('×\x20'+_0x519f97),console[_0x11d579(0x202)](_0x11d579(0x203)),console[_0x11d579(0x202)](_0x11d579(0x209)),console[_0x11d579(0x202)](_0x11d579(0x20b));return;}logger[_0x11d579(0x20a)](_0x11d579(0x1f2),_0x11d579(0x200)+_0xfc213d[_0x11d579(0x211)]+'\x20('+_0xfc213d[_0x11d579(0x1ff)]+')');const _0x302a0a={'appCode':_0x146600,'type':'procode','sort':0x0,'extend':{'loadScriptMode':'import','resources':_0xfc213d[_0x11d579(0x1e4)]?JSON[_0x11d579(0x1e6)](_0xfc213d[_0x11d579(0x1e4)]):undefined},..._0xfc213d},_0x2f4c44=await fetch(getApiDomain()+_0x11d579(0x1e8),{'method':_0x11d579(0x208),'body':JSON[_0x11d579(0x1e6)](_0x302a0a),'headers':{'Content-Type':_0x11d579(0x1e5),'Cookie':getCookie()}});if(!_0x2f4c44['ok']){if(_0x2f4c44[_0x11d579(0x1f6)]===0x191){const _0xc4783=_0x11d579(0x1fd);logger['error'](_0x11d579(0x1f2),_0xc4783,{'status':_0x2f4c44[_0x11d579(0x1f6)],'menu':_0xfc213d[_0x11d579(0x211)]});throw new Error(_0xc4783);}const _0x2dcff8=_0x11d579(0x1f9)+_0x2f4c44[_0x11d579(0x1f6)];logger['error'](_0x11d579(0x1f2),_0x2dcff8,{'menu':_0xfc213d[_0x11d579(0x211)]});throw new Error(_0x2dcff8);}const _0xed1c60=await _0x2f4c44['json']();if(!_0xed1c60[_0x11d579(0x1ea)]){const _0x2527fc=_0x11d579(0x204)+(_0xed1c60[_0x11d579(0x1fa)]||_0x11d579(0x201));logger[_0x11d579(0x20e)](_0x11d579(0x1f2),_0x2527fc,{'errorCode':_0xed1c60[_0x11d579(0x206)],'errorMsg':_0xed1c60[_0x11d579(0x1fa)],'menu':_0xfc213d[_0x11d579(0x211)]});throw new Error(_0x2527fc);}logger[_0x11d579(0x20a)](_0x11d579(0x1f2),_0x11d579(0x1eb)+_0xfc213d[_0x11d579(0x211)],_0xed1c60[_0x11d579(0x1f5)]),console[_0x11d579(0x202)](_0x11d579(0x1f3),_0xed1c60[_0x11d579(0x1f5)]);}function a11_0x111e(){const _0x576da1=['status','未提供应用AppCode,且配置中也没有默认值','create-menus','创建菜单失败,HTTP状态码:\x20','errorMsg','includes','json','登录鉴权失败,登录已过期,请使用\x20lovrabet\x20auth\x20重新登录','import','path','正在创建菜单:\x20','未知错误','log','!\x20请使用以下方式之一:','创建菜单失败:\x20','2484972cdCiAW','errorCode','批量创建菜单完成,共\x20','POST','\x20\x20\x201.\x20直接指定:\x20lovrabet\x20api\x20pull\x20<app-code>','info','\x20\x20\x202.\x20配置默认值:\x20lovrabet\x20config\x20set\x20app\x20<app-code>','56fhHlZT','616125LDDkvY','error','4023192VrzuNK','7COfsct','label','map','all','resources','application/json','stringify','3042285mySvbi','/smartapi/menu/create','322624gVxshk','success','菜单创建成功:\x20','appcode','143hmhcxO','procode','5658732XrtuQy','8VAMWQH','5483110TkoAIn','create-menu','创建菜单成功:','开始批量创建菜单,共\x20','data'];a11_0x111e=function(){return _0x576da1;};return a11_0x111e();}async function _createMenu(_0x4616b7,_0x221697){const _0x1803b6=a11_0x51cc,_0x26abaa=config?.[_0x1803b6(0x1ec)];if(!_0x26abaa){const _0x28b38d=_0x1803b6(0x1f7);logger[_0x1803b6(0x20e)](_0x1803b6(0x1f2),_0x28b38d),console[_0x1803b6(0x20e)]('×\x20'+_0x28b38d),console[_0x1803b6(0x202)]('!\x20请使用以下方式之一:'),console[_0x1803b6(0x202)]('\x20\x20\x201.\x20直接指定:\x20lovrabet\x20api\x20pull\x20<app-code>'),console[_0x1803b6(0x202)]('\x20\x20\x202.\x20配置默认值:\x20lovrabet\x20config\x20set\x20app\x20<app-code>');return;}const _0xbb95f8={'appCode':_0x26abaa,'type':_0x1803b6(0x1ee),'sort':0x0,'extend':{'loadScriptMode':_0x1803b6(0x1fe),'resources':_0x221697?JSON[_0x1803b6(0x1e6)](_0x221697):undefined},'label':_0x4616b7['label'],'path':_0x4616b7[_0x1803b6(0x1ff)]},_0x5519da=await fetch(getApiDomain()+_0x1803b6(0x1e8),{'method':'POST','body':JSON[_0x1803b6(0x1e6)](_0xbb95f8),'headers':{'Content-Type':_0x1803b6(0x1e5),'Cookie':getCookie()}});if(!_0x5519da['ok']){if(_0x5519da[_0x1803b6(0x1f6)]===0x191){const _0x1b88ec=_0x1803b6(0x1fd);logger[_0x1803b6(0x20e)](_0x1803b6(0x1f2),_0x1b88ec,{'status':_0x5519da['status'],'menu':_0x4616b7['label']});throw new Error(_0x1b88ec);}const _0xd838ab=_0x1803b6(0x1f9)+_0x5519da[_0x1803b6(0x1f6)];logger['error'](_0x1803b6(0x1f2),_0xd838ab,{'menu':_0x4616b7['label']});throw new Error(_0xd838ab);}const _0x4ece02=await _0x5519da[_0x1803b6(0x1fc)]();if(!_0x4ece02[_0x1803b6(0x1ea)]){if(_0x4ece02[_0x1803b6(0x206)]==='0011'||_0x4ece02['errorMsg']?.[_0x1803b6(0x1fb)]('登录')){const _0x37ccc6='登录态校验失败,请使用\x20lovrabet\x20auth\x20重新登录';logger[_0x1803b6(0x20e)](_0x1803b6(0x1f2),_0x37ccc6,{'errorCode':_0x4ece02[_0x1803b6(0x206)],'errorMsg':_0x4ece02[_0x1803b6(0x1fa)],'menu':_0x4616b7['label']});throw new Error(_0x37ccc6);}const _0x3b179c=_0x1803b6(0x204)+(_0x4ece02['errorMsg']||_0x1803b6(0x201));logger[_0x1803b6(0x20e)](_0x1803b6(0x1f2),_0x3b179c,{'errorCode':_0x4ece02[_0x1803b6(0x206)],'errorMsg':_0x4ece02['errorMsg'],'menu':_0x4616b7['label']});throw new Error(_0x3b179c);}logger['info'](_0x1803b6(0x1f2),_0x1803b6(0x1eb)+_0x4616b7[_0x1803b6(0x211)]);}export async function createMenus(_0x1a82b0,_0x1149f7){const _0x1b2330=a11_0x51cc;logger['info'](_0x1b2330(0x1f8),_0x1b2330(0x1f4)+_0x1a82b0['length']+'\x20个'),await Promise[_0x1b2330(0x1e3)](_0x1a82b0[_0x1b2330(0x1e2)](async _0x1059dd=>{await _createMenu(_0x1059dd,_0x1149f7);})),logger[_0x1b2330(0x20a)](_0x1b2330(0x1f8),_0x1b2330(0x207)+_0x1a82b0['length']+'\x20个');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a12_0x1acd(){const _0x41dd43=['isDirectory','path','2hZXkho','18650547hcPcMk','match','5iIBfib','endsWith','utf-8','1072195DzzjVK','filter','src/pages','slice','forEach','.tsx','2899641WmysPY','index.tsx','7733192gYPzIE','1001024wCZMzN','replace','627990nrZqvZ','5097960DHvMDB'];a12_0x1acd=function(){return _0x41dd43;};return a12_0x1acd();}const a12_0x3de9d2=a12_0x5acf;function a12_0x5acf(_0x295ad9,_0x5d6740){const _0x1acd5c=a12_0x1acd();return a12_0x5acf=function(_0x5acff0,_0x35d1a3){_0x5acff0=_0x5acff0-0x1b2;let _0x4d397b=_0x1acd5c[_0x5acff0];return _0x4d397b;},a12_0x5acf(_0x295ad9,_0x5d6740);}(function(_0x276d1b,_0x2ad324){const _0x501e4d=a12_0x5acf,_0x5e6043=_0x276d1b();while(!![]){try{const _0x5d559c=-parseInt(_0x501e4d(0x1b8))/0x1+parseInt(_0x501e4d(0x1b2))/0x2*(parseInt(_0x501e4d(0x1be))/0x3)+parseInt(_0x501e4d(0x1c1))/0x4*(parseInt(_0x501e4d(0x1b5))/0x5)+parseInt(_0x501e4d(0x1c3))/0x6+-parseInt(_0x501e4d(0x1c4))/0x7+-parseInt(_0x501e4d(0x1c0))/0x8+parseInt(_0x501e4d(0x1b3))/0x9;if(_0x5d559c===_0x2ad324)break;else _0x5e6043['push'](_0x5e6043['shift']());}catch(_0x2c3900){_0x5e6043['push'](_0x5e6043['shift']());}}}(a12_0x1acd,0x98fc3));import{readdirSync,statSync,readFileSync}from'fs';import{join,relative,resolve}from'path';const pagesDir=resolve(process['cwd'](),a12_0x3de9d2(0x1ba));export function extractTitleFromComment(_0x430a86){const _0x568fd2=a12_0x3de9d2;try{const _0x48ae8f=readFileSync(_0x430a86,_0x568fd2(0x1b7)),_0x1deae1=_0x48ae8f[_0x568fd2(0x1b4)](/^\s*\/\*\*?([\s\S]*?)\*\//);if(_0x1deae1&&_0x1deae1[0x1]){const _0xbed207=_0x1deae1[0x1],_0x46e417=_0xbed207[_0x568fd2(0x1b4)](/^\s*\*?\s*title\s*:\s*(.+)/im);if(_0x46e417&&_0x46e417[0x1])return _0x46e417[0x1]['trim']();}let _0x3d30e6=null;const _0x1aa27f=_0x48ae8f[_0x568fd2(0x1b4)](/export\s+default\s+([A-Z][a-zA-Z0-9]*)/);_0x1aa27f&&_0x1aa27f[0x1]&&(_0x3d30e6=_0x1aa27f[0x1]);if(!_0x3d30e6){const _0x10fc60=_0x48ae8f[_0x568fd2(0x1b4)](/export\s+default\s+function\s+([A-Z][a-zA-Z0-9]*)/);_0x10fc60&&_0x10fc60[0x1]&&(_0x3d30e6=_0x10fc60[0x1]);}if(_0x3d30e6){const _0xaa3fb2=new RegExp('\x5cb'+_0x3d30e6+'\x5c.displayName\x5cs*=\x5cs*[\x22\x27]([^\x22\x27]+)[\x22\x27]'),_0x5c5073=_0x48ae8f['match'](_0xaa3fb2);if(_0x5c5073&&_0x5c5073[0x1])return _0x5c5073[0x1];return _0x3d30e6;}return null;}catch(_0x2039b1){return null;}}export function getLocalPages(_0x1d2645=pagesDir,_0x4c8e89=pagesDir){const _0x216494=a12_0x3de9d2;let _0xfbfa28=[];const _0x2d171e=readdirSync(_0x1d2645);return _0x2d171e[_0x216494(0x1bc)](_0x1d8ced=>{const _0x3dc87b=_0x216494,_0x5209c8=join(_0x1d2645,_0x1d8ced),_0x1c4d03=statSync(_0x5209c8);if(_0x1c4d03&&_0x1c4d03[_0x3dc87b(0x1c5)]())_0xfbfa28=_0xfbfa28['concat'](getLocalPages(_0x5209c8,_0x4c8e89));else{if(_0x1d8ced[_0x3dc87b(0x1b6)](_0x3dc87b(0x1bd))){let _0x26a6b5=relative(_0x4c8e89,_0x5209c8);_0x26a6b5[_0x3dc87b(0x1b6)](_0x3dc87b(0x1bf))?_0x26a6b5=_0x26a6b5[_0x3dc87b(0x1c2)](/index\.tsx$/,''):_0x26a6b5=_0x26a6b5[_0x3dc87b(0x1c2)](/\.tsx$/,'');_0x26a6b5['endsWith']('/')&&(_0x26a6b5=_0x26a6b5[_0x3dc87b(0x1bb)](0x0,-0x1));const _0x29e82d=extractTitleFromComment(_0x5209c8),_0x28f326=_0x29e82d||_0x26a6b5;_0xfbfa28['push']({'path':_0x26a6b5,'label':_0x28f326});}}}),_0xfbfa28[_0x216494(0x1b9)](_0x3bcd7c=>_0x3bcd7c[_0x216494(0x1c6)]!=='');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a13_0x38f1(_0x2edc6d,_0x3b73c6){const _0x23ec06=a13_0x23ec();return a13_0x38f1=function(_0x38f1b8,_0x151486){_0x38f1b8=_0x38f1b8-0x1de;let _0x225f8d=_0x23ec06[_0x38f1b8];return _0x225f8d;},a13_0x38f1(_0x2edc6d,_0x3b73c6);}(function(_0x3dc8fe,_0x15875e){const _0x27f18a=a13_0x38f1,_0x1ea459=_0x3dc8fe();while(!![]){try{const _0x5e5d6c=parseInt(_0x27f18a(0x1e4))/0x1*(-parseInt(_0x27f18a(0x1e1))/0x2)+-parseInt(_0x27f18a(0x1e8))/0x3*(parseInt(_0x27f18a(0x1f7))/0x4)+-parseInt(_0x27f18a(0x1fb))/0x5+parseInt(_0x27f18a(0x1ff))/0x6+-parseInt(_0x27f18a(0x1df))/0x7*(-parseInt(_0x27f18a(0x1ea))/0x8)+-parseInt(_0x27f18a(0x1f4))/0x9*(parseInt(_0x27f18a(0x1f5))/0xa)+parseInt(_0x27f18a(0x1f3))/0xb;if(_0x5e5d6c===_0x15875e)break;else _0x1ea459['push'](_0x1ea459['shift']());}catch(_0x3f87ea){_0x1ea459['push'](_0x1ea459['shift']());}}}(a13_0x23ec,0x67df9));import{useEffect,useState}from'react';import{getCookie}from'../auth/get-cookie.js';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 _0x2ebe94=a13_0x38f1,_0x45e799=config?.['appcode'];if(!_0x45e799){const _0x5a7bc1=_0x2ebe94(0x1f0);return logger[_0x2ebe94(0x1f9)](_0x2ebe94(0x1e3),_0x5a7bc1),console[_0x2ebe94(0x1f9)]('×\x20'+_0x5a7bc1),console['log'](_0x2ebe94(0x1ef)),console[_0x2ebe94(0x204)](_0x2ebe94(0x202)),console['log'](_0x2ebe94(0x205)),[];}logger['info']('get-online-menu-list',_0x2ebe94(0x1f6)+_0x45e799+')');const _0x4f45e1=await fetch(getApiDomain()+_0x2ebe94(0x1e9)+_0x45e799,{'method':'GET','headers':{'Content-Type':'application/json','Cookie':getCookie()}});if(!_0x4f45e1['ok']){if(_0x4f45e1[_0x2ebe94(0x203)]===0x191){const _0x4ef687=_0x2ebe94(0x1ed);logger[_0x2ebe94(0x1f9)]('get-online-menu-list',_0x4ef687,{'status':_0x4f45e1['status']});throw new Error(_0x4ef687);}const _0x40fc3d=_0x2ebe94(0x1e2)+_0x4f45e1[_0x2ebe94(0x203)];logger['error'](_0x2ebe94(0x1e3),_0x40fc3d);throw new Error(_0x40fc3d);}const _0x15e3d0=await _0x4f45e1[_0x2ebe94(0x1eb)]();if(!_0x15e3d0['success']){const _0x4c0f10=_0x2ebe94(0x1f2)+(_0x15e3d0['errorMsg']||_0x2ebe94(0x1de));logger[_0x2ebe94(0x1f9)](_0x2ebe94(0x1e3),_0x4c0f10,{'errorCode':_0x15e3d0[_0x2ebe94(0x1fc)],'errorMsg':_0x15e3d0[_0x2ebe94(0x1fe)]});throw new Error(_0x4c0f10);}if(!_0x15e3d0[_0x2ebe94(0x1fa)])return logger[_0x2ebe94(0x1e5)]('get-online-menu-list',_0x2ebe94(0x201)),[];return logger[_0x2ebe94(0x1e5)](_0x2ebe94(0x1e3),_0x2ebe94(0x1ec)+_0x15e3d0[_0x2ebe94(0x1fa)]['length']+_0x2ebe94(0x1fd)),_0x15e3d0['data'][_0x2ebe94(0x1f8)](_0x2a6bff=>({'path':_0x2a6bff[_0x2ebe94(0x1e0)],'label':_0x2a6bff[_0x2ebe94(0x200)]}));}function a13_0x23ec(){const _0x596a41=['26IFZPKZ','获取菜单列表失败,HTTP状态码:\x20','get-online-menu-list','34693rwOZCc','info','message','获取菜单列表失败','417zNKsUZ','/smartapi/menu/find?appCode=','8tHJyYl','json','成功获取\x20','登录鉴权失败,登录已过期,请使用\x20lovrabet\x20auth\x20重新登录','then','!\x20请使用以下方式之一:','未提供应用AppCode,且配置中也没有默认值','finally','获取菜单列表失败:\x20','10194151rDKpad','2286wjkjrn','25210cVhksb','正在获取线上菜单列表...\x20(appCode:\x20','2860GDWHff','map','error','data','3788055rpYVNA','errorCode','\x20个线上菜单','errorMsg','4421136WJPbpF','label','服务端返回空菜单列表','\x20\x20\x201.\x20直接指定:\x20lovrabet\x20api\x20pull\x20<app-code>','status','log','\x20\x20\x202.\x20配置默认值:\x20lovrabet\x20config\x20set\x20app\x20<app-code>','未知错误','4971449KAJpia','path'];a13_0x23ec=function(){return _0x596a41;};return a13_0x23ec();}export function useGetOnlineMenuList(){const [_0x4b87dd,_0x18d987]=useState([]),[_0xa23886,_0x2f3a0d]=useState(!![]),[_0x191a27,_0x116f71]=useState('');return useEffect(()=>{const _0x14d9c4=a13_0x38f1;_0x2f3a0d(!![]),_0x116f71(''),getOnlineMenuList()[_0x14d9c4(0x1ee)](_0x18d987)['catch'](_0x582c72=>{const _0x19d87c=_0x14d9c4;_0x116f71(_0x582c72[_0x19d87c(0x1e6)]||_0x19d87c(0x1e7));})[_0x14d9c4(0x1f1)](()=>_0x2f3a0d(![]));},[]),{'menuList':_0x4b87dd,'loading':_0xa23886,'error':_0x191a27};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x5e25c4,_0x205ca5){const _0x4f28e5=a15_0x209f,_0x20e2b6=_0x5e25c4();while(!![]){try{const _0x48b562=-parseInt(_0x4f28e5(0x149))/0x1*(-parseInt(_0x4f28e5(0x146))/0x2)+-parseInt(_0x4f28e5(0x145))/0x3+-parseInt(_0x4f28e5(0x14d))/0x4+parseInt(_0x4f28e5(0x14e))/0x5+parseInt(_0x4f28e5(0x14a))/0x6+-parseInt(_0x4f28e5(0x14f))/0x7+parseInt(_0x4f28e5(0x144))/0x8*(parseInt(_0x4f28e5(0x148))/0x9);if(_0x48b562===_0x205ca5)break;else _0x20e2b6['push'](_0x20e2b6['shift']());}catch(_0x328e8c){_0x20e2b6['push'](_0x20e2b6['shift']());}}}(a15_0x26b5,0x59ceb));export function isValidJsHttpsUrl(_0x4ff5b5){const _0x42b6aa=a15_0x209f;return/^https:\/\/.+\.js(\?.*)?$/[_0x42b6aa(0x147)](_0x4ff5b5['trim']());}function a15_0x26b5(){const _0x107bf9=['1099348XyFdJb','863735RQejGE','1147888AahuHr','4848568BggciT','1592694RWPpvb','3502jgpmvV','test','9XqgidJ','311eHqQWV','85146GgAyKf','trim','HEAD'];a15_0x26b5=function(){return _0x107bf9;};return a15_0x26b5();}export function isValidCssHttpsUrl(_0x7e5cd8){const _0x561890=a15_0x209f;return/^https:\/\/.+\.css(\?.*)?$/['test'](_0x7e5cd8[_0x561890(0x14b)]());}function a15_0x209f(_0x342f65,_0x1de1fc){const _0x26b5c5=a15_0x26b5();return a15_0x209f=function(_0x209fc8,_0x6fe207){_0x209fc8=_0x209fc8-0x144;let _0x375885=_0x26b5c5[_0x209fc8];return _0x375885;},a15_0x209f(_0x342f65,_0x1de1fc);}export async function isUrlReachable(_0x14a6b0){const _0x44756f=a15_0x209f;try{const _0x534c04=await fetch(_0x14a6b0,{'method':_0x44756f(0x14c)});return _0x534c04['ok'];}catch{return![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x2acc44,_0xb60ff){const _0x2001ed=a16_0x9f8c,_0x52c127=_0x2acc44();while(!![]){try{const _0x348e98=-parseInt(_0x2001ed(0xac))/0x1*(parseInt(_0x2001ed(0xb7))/0x2)+parseInt(_0x2001ed(0xa3))/0x3*(-parseInt(_0x2001ed(0xa2))/0x4)+-parseInt(_0x2001ed(0xa1))/0x5*(-parseInt(_0x2001ed(0xb8))/0x6)+-parseInt(_0x2001ed(0xa9))/0x7*(-parseInt(_0x2001ed(0xb4))/0x8)+parseInt(_0x2001ed(0xaa))/0x9+parseInt(_0x2001ed(0xad))/0xa*(parseInt(_0x2001ed(0xb0))/0xb)+-parseInt(_0x2001ed(0xa6))/0xc*(parseInt(_0x2001ed(0xa7))/0xd);if(_0x348e98===_0xb60ff)break;else _0x52c127['push'](_0x52c127['shift']());}catch(_0x4190a2){_0x52c127['push'](_0x52c127['shift']());}}}(a16_0x2cb5,0x59dee));import{jsx as a16_0x4c0547,jsxs as a16_0x9008ef}from'react/jsx-runtime';import{Text,Box,useInput,useApp}from'ink';function a16_0x2cb5(){const _0x32a22d=['dots','return','2pswNbJ','6sBYQdq','按\x20“q”\x20退出。','1022995TUuIGO','8jLtuJJ','76251xvaAnd','*\x20登录成功!','正在登录...\x20','12AUosAy','6458855JOTEyM','√\x20当前为有效会话,无需重新登录。','48769zCeaLa','6582600ptxoPf','then','609707vhelSD','886360gktkWr','log','gray','55zCmysO','请前往浏览器完成登录。','finally','*\x20按回车开始登录。','168HzJxyy'];a16_0x2cb5=function(){return _0x32a22d;};return a16_0x2cb5();}import{useEffect,useState}from'react';import{getIsSessionValid}from'./is-session-valid.js';function a16_0x9f8c(_0x346515,_0x52bfbb){const _0x2cb532=a16_0x2cb5();return a16_0x9f8c=function(_0x9f8c68,_0x2091a1){_0x9f8c68=_0x9f8c68-0xa0;let _0x18a0cb=_0x2cb532[_0x9f8c68];return _0x18a0cb;},a16_0x9f8c(_0x346515,_0x52bfbb);}import{authServer}from'./auth-server.js';import a16_0x1ccee7 from'ink-spinner';export function AuthServer(){const _0x1dbba3=a16_0x9f8c,{exit:_0x10db36}=useApp(),[_0x3b99a8,_0x7802f1]=useState(![]),[_0x7b7fd8,_0x3bcad9]=useState(!![]),[_0x39bc78,_0x1fbe4a]=useState(![]),[_0x56212d,_0x1dd2d2]=useState(![]);useEffect(()=>{const _0x298f75=a16_0x9f8c;getIsSessionValid()[_0x298f75(0xab)](_0x7802f1)[_0x298f75(0xb2)](()=>_0x3bcad9(![]));},[]),useEffect(()=>{const _0x3abdeb=a16_0x9f8c;!_0x7b7fd8&&_0x3b99a8&&(console[_0x3abdeb(0xae)](_0x3abdeb(0xa8)),_0x10db36());},[_0x7b7fd8,_0x3b99a8,_0x10db36]),useEffect(()=>{const _0x4a32b8=a16_0x9f8c;_0x56212d&&(console['log'](_0x4a32b8(0xa4)),_0x10db36());},[_0x56212d,_0x10db36]),useInput((_0x5a7444,_0x139229)=>{const _0x2e302a=a16_0x9f8c;_0x139229[_0x2e302a(0xb6)]&&(_0x1fbe4a(!![]),authServer({'silent':!![]})[_0x2e302a(0xab)](_0x1c107b=>{_0x1dd2d2(_0x1c107b);})),_0x5a7444==='q'&&_0x10db36();});if(_0x7b7fd8)return null;if(_0x3b99a8||_0x56212d)return null;return a16_0x4c0547(Box,{'flexDirection':'column','marginTop':0x1,'marginBottom':0x1,'children':_0x39bc78?a16_0x9008ef(Box,{'children':[a16_0x4c0547(Box,{'width':'1'}),a16_0x9008ef(Text,{'color':'green','children':[a16_0x4c0547(a16_0x1ccee7,{'type':_0x1dbba3(0xb5)}),'\x20\x20']}),a16_0x4c0547(Text,{'children':_0x1dbba3(0xa5)}),a16_0x4c0547(Text,{'color':_0x1dbba3(0xaf),'children':_0x1dbba3(0xb1)})]}):a16_0x9008ef(Box,{'children':[a16_0x4c0547(Box,{'width':'1'}),a16_0x4c0547(Text,{'children':_0x1dbba3(0xb3)}),a16_0x4c0547(Text,{'color':'gray','children':_0x1dbba3(0xa0)})]})});}
|
package/lib/auth/auth-server.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a17_0x4a3e50=a17_0x4f61;(function(_0x390ea3,_0x40348d){const _0xdbe5f4=a17_0x4f61,_0x372f59=_0x390ea3();while(!![]){try{const _0xf9272f=parseInt(_0xdbe5f4(0xf3))/0x1+-parseInt(_0xdbe5f4(0xf2))/0x2+parseInt(_0xdbe5f4(0x106))/0x3+-parseInt(_0xdbe5f4(0xf7))/0x4+-parseInt(_0xdbe5f4(0xf1))/0x5*(-parseInt(_0xdbe5f4(0xed))/0x6)+parseInt(_0xdbe5f4(0xe9))/0x7+parseInt(_0xdbe5f4(0xfd))/0x8;if(_0xf9272f===_0x40348d)break;else _0x372f59['push'](_0x372f59['shift']());}catch(_0x3c43a6){_0x372f59['push'](_0x372f59['shift']());}}}(a17_0x4222,0x72cf5));function a17_0x4222(){const _0x47eb92=['https://g.yuntooai.com/cert/lovrabet-dev.json','utf-8','🔗\x20请手动复制登录地址到浏览器:','55758IzymIT','close','createServer','/sign-in?redirect=','75uHEfxV','607242enzfNW','188260gplGmq','user','log','json','2882608FlsmBU','win32','⚠️\x20\x20无法自动打开浏览器','darwin','xdg-open\x20\x22','error','1682272jagEXh','port','https://dev.lovrabet.com:','then','cookie','session','✅\x20浏览器已自动打开,请在浏览器中完成登录','end','127.0.0.1','1230495KvcvQf','📍\x20登录地址:','platform','open\x20\x22','object','main','Auth\x20server\x20error:','writeHead','catch','start\x20\x22\x22\x20\x22','address','3825010gxMNWi'];a17_0x4222=function(){return _0x47eb92;};return a17_0x4222();}import{writeFileSync}from'node:fs';import a17_0x43368f 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(_0x1af1ee){const _0x373226=a17_0x4f61,_0x52d2c1=_0x1af1ee?.['silent']||![];if(await getIsSessionValid())return!![];const _0x40f2fc=await(await fetch(_0x373226(0xea)))[_0x373226(0xf6)]();return new Promise(async(_0x41d35b,_0x594b6f)=>{const _0x1175a1=_0x373226;let _0xa90549=0x0;const _0x23cc4d=a17_0x43368f[_0x1175a1(0xef)](_0x40f2fc,async(_0x3e97df,_0x4373b6)=>{const _0x1ddf65=_0x1175a1,_0x388dad=getUserDomain(),_0x46444d=_0x3e97df['headers'][_0x1ddf65(0x101)]||'',_0x2211e1=await fetch(_0x388dad+'/api/auth/get-session',{'headers':{'cookie':_0x46444d}})[_0x1ddf65(0x100)](_0x297efc=>_0x297efc[_0x1ddf65(0xf6)]()),_0x4faea6=_0x2211e1&&_0x2211e1[_0x1ddf65(0x102)]&&_0x2211e1[_0x1ddf65(0xf4)];if(_0x4faea6){writeFileSync(cookieFile,_0x46444d,_0x1ddf65(0xeb)),_0x41d35b(!![]);const _0x5f1f9e='<!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>';_0x4373b6['writeHead'](0xc8,{'Content-Type':'text/html;\x20charset=utf-8'}),_0x4373b6[_0x1ddf65(0x104)](_0x5f1f9e),_0x23cc4d[_0x1ddf65(0xee)]();}else{const _0x14d8a6=''+encodeURIComponent(_0x1ddf65(0xff)+_0xa90549);_0x4373b6[_0x1ddf65(0xe5)](0x12e,{'location':_0x388dad+_0x1ddf65(0xf0)+_0x14d8a6}),_0x4373b6[_0x1ddf65(0x104)]();return;}});_0x23cc4d['listen'](0x0,_0x1175a1(0x105),()=>{const _0x3330db=_0x1175a1,_0x578dfa=_0x23cc4d[_0x3330db(0xe8)]();_0xa90549=typeof _0x578dfa===_0x3330db(0x10a)&&_0x578dfa?_0x578dfa[_0x3330db(0xfe)]:Number(_0x578dfa);const _0x41dc40=_0x3330db(0xff)+_0xa90549;!_0x52d2c1&&(console['log']('🔐\x20正在启动登录服务...'),console[_0x3330db(0xf5)](_0x3330db(0x107),_0x41dc40),console[_0x3330db(0xf5)]('🌐\x20正在尝试自动打开浏览器...'),console[_0x3330db(0xf5)](''),console[_0x3330db(0xf5)]('💡\x20如果浏览器没有自动打开,请手动复制上面的登录地址到浏览器中打开'),console['log']('')),openInBrowser(_0x41dc40)[_0x3330db(0x100)](_0x59c042=>{const _0xeaaebe=_0x3330db;!_0x52d2c1&&(_0x59c042?console['log'](_0xeaaebe(0x103)):(console[_0xeaaebe(0xf5)]('⚠️\x20\x20无法自动打开浏览器'),console[_0xeaaebe(0xf5)](_0xeaaebe(0xec),_0x41dc40)),console[_0xeaaebe(0xf5)](''));})[_0x3330db(0xe6)](()=>{const _0x43307e=_0x3330db;!_0x52d2c1&&(console[_0x43307e(0xf5)](_0x43307e(0xf9)),console[_0x43307e(0xf5)](_0x43307e(0xec),_0x41dc40),console[_0x43307e(0xf5)](''));});}),_0x23cc4d['on'](_0x1175a1(0xfc),_0xf286c=>{const _0x31251d=_0x1175a1;!_0x52d2c1&&console[_0x31251d(0xfc)](_0x31251d(0x10c),_0xf286c),_0x594b6f(_0xf286c);});});}function a17_0x4f61(_0x48fe88,_0x45b228){const _0x42220f=a17_0x4222();return a17_0x4f61=function(_0x4f61a0,_0xffdb28){_0x4f61a0=_0x4f61a0-0xe5;let _0x1c3c7b=_0x42220f[_0x4f61a0];return _0x1c3c7b;},a17_0x4f61(_0x48fe88,_0x45b228);}function openInBrowser(_0x1739ae){return new Promise(_0x46fbee=>{const _0x5a6c6b=a17_0x4f61,_0x42fc43=process[_0x5a6c6b(0x108)];let _0x2afbf9;if(_0x42fc43===_0x5a6c6b(0xf8))_0x2afbf9=_0x5a6c6b(0xe7)+_0x1739ae+'\x22';else _0x42fc43===_0x5a6c6b(0xfa)?_0x2afbf9=_0x5a6c6b(0x109)+_0x1739ae+'\x22':_0x2afbf9=_0x5a6c6b(0xfb)+_0x1739ae+'\x22';exec(_0x2afbf9,_0x5428a8=>{_0x5428a8?_0x46fbee(![]):_0x46fbee(!![]);});});}if(import.meta[a17_0x4a3e50(0x10b)]){const isAuth=await authServer();console[a17_0x4a3e50(0xf5)]('isAuth',isAuth);}
|
package/lib/auth/constant.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a18_0x406254=a18_0x2d95;(function(_0xd179a4,_0x3c23b6){const _0x480393=a18_0x2d95,_0x43beff=_0xd179a4();while(!![]){try{const _0x5c711d=parseInt(_0x480393(0x1d1))/0x1+-parseInt(_0x480393(0x1cf))/0x2+parseInt(_0x480393(0x1cc))/0x3+parseInt(_0x480393(0x1cd))/0x4*(parseInt(_0x480393(0x1ce))/0x5)+parseInt(_0x480393(0x1ca))/0x6*(parseInt(_0x480393(0x1cb))/0x7)+-parseInt(_0x480393(0x1c8))/0x8+-parseInt(_0x480393(0x1c9))/0x9;if(_0x5c711d===_0x3c23b6)break;else _0x43beff['push'](_0x43beff['shift']());}catch(_0x55bd9b){_0x43beff['push'](_0x43beff['shift']());}}}(a18_0x2bd9,0x3c399));import{mkdirSync}from'node:fs';import{homedir}from'node:os';function a18_0x2d95(_0x1f4c31,_0x2db09a){const _0x2bd905=a18_0x2bd9();return a18_0x2d95=function(_0x2d9533,_0x5df8a9){_0x2d9533=_0x2d9533-0x1c8;let _0x59ade3=_0x2bd905[_0x2d9533];return _0x59ade3;},a18_0x2d95(_0x1f4c31,_0x2db09a);}export const configDir=homedir()+'/.lovrabet';export const cookieFile=configDir+a18_0x406254(0x1d0);mkdirSync(configDir,{'recursive':!![]});function a18_0x2bd9(){const _0x396c7f=['227042AJyOov','/cookie','223116lgfCsU','2611048OsoLUN','532332puViIT','174NeYbSl','4410sqmYHW','373002UfFwxB','7204CHEXKI','1055IUbCGT'];a18_0x2bd9=function(){return _0x396c7f;};return a18_0x2bd9();}
|
package/lib/auth/get-cookie.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4107ab,_0x20b439){var _0x29f82c=a19_0x2512,_0x281aa0=_0x4107ab();while(!![]){try{var _0x56a2e3=-parseInt(_0x29f82c(0x1a7))/0x1*(parseInt(_0x29f82c(0x1b0))/0x2)+-parseInt(_0x29f82c(0x1ae))/0x3+-parseInt(_0x29f82c(0x1b1))/0x4*(parseInt(_0x29f82c(0x1af))/0x5)+parseInt(_0x29f82c(0x1ab))/0x6+-parseInt(_0x29f82c(0x1ac))/0x7+-parseInt(_0x29f82c(0x1ad))/0x8*(parseInt(_0x29f82c(0x1aa))/0x9)+parseInt(_0x29f82c(0x1a8))/0xa;if(_0x56a2e3===_0x20b439)break;else _0x281aa0['push'](_0x281aa0['shift']());}catch(_0x5bad31){_0x281aa0['push'](_0x281aa0['shift']());}}}(a19_0x1d37,0x58a44));function a19_0x2512(_0x1d911c,_0x17240d){var _0x1d37a7=a19_0x1d37();return a19_0x2512=function(_0x251298,_0x224a05){_0x251298=_0x251298-0x1a7;var _0x53e746=_0x1d37a7[_0x251298];return _0x53e746;},a19_0x2512(_0x1d911c,_0x17240d);}import{readFileSync}from'node:fs';import{cookieFile}from'./constant.js';function a19_0x1d37(){var _0x32d706=['utf-8','2302821lUPYDb','2049204syROtA','16030unuLYO','8DhjEIc','1113567faWFeH','1685rLMfEt','577820QuDAoR','4036IeYjLk','2kynuxY','15687430puFUoB'];a19_0x1d37=function(){return _0x32d706;};return a19_0x1d37();}export function getCookie(){var _0x3b6190=a19_0x2512;try{return readFileSync(cookieFile,_0x3b6190(0x1a9));}catch{}return'';}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x3ba80c,_0x46ed11){const _0x26a44d=a20_0x1173,_0x4e7363=_0x3ba80c();while(!![]){try{const _0x5c4e11=parseInt(_0x26a44d(0x1e7))/0x1*(-parseInt(_0x26a44d(0x1dc))/0x2)+-parseInt(_0x26a44d(0x1e4))/0x3+parseInt(_0x26a44d(0x1e9))/0x4*(-parseInt(_0x26a44d(0x1e6))/0x5)+-parseInt(_0x26a44d(0x1ec))/0x6*(-parseInt(_0x26a44d(0x1e2))/0x7)+parseInt(_0x26a44d(0x1e1))/0x8*(parseInt(_0x26a44d(0x1de))/0x9)+parseInt(_0x26a44d(0x1e8))/0xa+parseInt(_0x26a44d(0x1eb))/0xb*(-parseInt(_0x26a44d(0x1dd))/0xc);if(_0x5c4e11===_0x46ed11)break;else _0x4e7363['push'](_0x4e7363['shift']());}catch(_0x44719b){_0x4e7363['push'](_0x4e7363['shift']());}}}(a20_0x2b70,0x1dc5c));function a20_0x2b70(){const _0x4e501a=['747qwSgZI','then','/api/auth/get-session','4624OHzpYK','85589SHIoWS','json','6936uqhqWz','session','15lLAFZY','48424vdHDZq','1488340CRdyZc','213604bTByBt','user','520586LFHUou','90KiDEtr','2bYLKxO','12NituUK'];a20_0x2b70=function(){return _0x4e501a;};return a20_0x2b70();}import{existsSync,readFileSync}from'node:fs';import{getUserDomain}from'../constant/domain.js';function a20_0x1173(_0x53fbb3,_0x373f15){const _0x2b704c=a20_0x2b70();return a20_0x1173=function(_0x117310,_0x4aba6f){_0x117310=_0x117310-0x1dc;let _0x7f064a=_0x2b704c[_0x117310];return _0x7f064a;},a20_0x1173(_0x53fbb3,_0x373f15);}import{cookieFile}from'./constant.js';export async function getIsSessionValid(){const _0x413fef=a20_0x1173;try{if(!existsSync(cookieFile))return![];const _0x3c2858=readFileSync(cookieFile,'utf-8'),_0x2ac610=await fetch(getUserDomain()+_0x413fef(0x1e0),{'headers':{'cookie':_0x3c2858}})[_0x413fef(0x1df)](_0x1201b1=>_0x1201b1[_0x413fef(0x1e3)]());return _0x2ac610&&_0x2ac610[_0x413fef(0x1e5)]&&_0x2ac610[_0x413fef(0x1ea)];}catch{}return![];}
|
package/lib/auth/logout.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x252b93,_0x550676){var _0x377b0a=a21_0x3702,_0x1a54bd=_0x252b93();while(!![]){try{var _0x27a03a=parseInt(_0x377b0a(0x134))/0x1+parseInt(_0x377b0a(0x133))/0x2+parseInt(_0x377b0a(0x136))/0x3+-parseInt(_0x377b0a(0x12f))/0x4+parseInt(_0x377b0a(0x135))/0x5+parseInt(_0x377b0a(0x137))/0x6+-parseInt(_0x377b0a(0x131))/0x7;if(_0x27a03a===_0x550676)break;else _0x1a54bd['push'](_0x1a54bd['shift']());}catch(_0x25a2d5){_0x1a54bd['push'](_0x1a54bd['shift']());}}}(a21_0x2571,0x7bc20));import{unlinkSync,existsSync}from'node:fs';function a21_0x2571(){var _0x1add3b=['1896300jVVYnq','!\x20当前未登录','3594476zraDOC','✓\x20已退出登录','3671955BMSbuT','log','1039514SPxySa','147066wxTMqc','3380325GTUCTY','813474YbtIwr'];a21_0x2571=function(){return _0x1add3b;};return a21_0x2571();}function a21_0x3702(_0x164fec,_0x282d27){var _0x257162=a21_0x2571();return a21_0x3702=function(_0x37024f,_0x10ff10){_0x37024f=_0x37024f-0x12f;var _0x50352a=_0x257162[_0x37024f];return _0x50352a;},a21_0x3702(_0x164fec,_0x282d27);}import{cookieFile}from'./constant.js';export function logout(){var _0x7d3d0e=a21_0x3702;existsSync(cookieFile)?(unlinkSync(cookieFile),console[_0x7d3d0e(0x132)](_0x7d3d0e(0x130))):console[_0x7d3d0e(0x132)](_0x7d3d0e(0x138));}
|
package/lib/cli.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
const
|
|
2
|
+
const a22_0x471fa4=a22_0x81e4;(function(_0x2cfaa2,_0x9ce91){const _0x250570=a22_0x81e4,_0x315d3f=_0x2cfaa2();while(!![]){try{const _0x4916da=-parseInt(_0x250570(0x162))/0x1*(-parseInt(_0x250570(0x14c))/0x2)+-parseInt(_0x250570(0x166))/0x3+-parseInt(_0x250570(0x16a))/0x4+-parseInt(_0x250570(0x155))/0x5*(parseInt(_0x250570(0x14f))/0x6)+parseInt(_0x250570(0x16e))/0x7+-parseInt(_0x250570(0x156))/0x8*(parseInt(_0x250570(0x167))/0x9)+parseInt(_0x250570(0x14b))/0xa*(parseInt(_0x250570(0x13e))/0xb);if(_0x4916da===_0x9ce91)break;else _0x315d3f['push'](_0x315d3f['shift']());}catch(_0x4c5b57){_0x315d3f['push'](_0x315d3f['shift']());}}}(a22_0x3af1,0x7c7c5));import{jsx as a22_0x1b6e55}from'react/jsx-runtime';import a22_0x8c19f3 from'meow';import{render}from'ink';import{CreateApp}from'./create-app/main.js';import{AddPage}from'./add-page/main.js';import{Init}from'./init/main.js';import{runStart}from'./cmd/start.js';function a22_0x81e4(_0x433974,_0x5c49ba){const _0x3af1ee=a22_0x3af1();return a22_0x81e4=function(_0x81e42f,_0x421fae){_0x81e42f=_0x81e42f-0x13e;let _0x5d7009=_0x3af1ee[_0x81e42f];return _0x5d7009;},a22_0x81e4(_0x433974,_0x5c49ba);}function a22_0x3af1(){const _0xb02dc1=['clear','info','719442DageOh','7704qccdOH','flags','\x0a\x09Usage\x0a\x09\x20\x20$\x20lovrabet\x0a\x0a\x09Examples\x0a\x09\x20\x20$\x20lovrabet\x20auth\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20登录认证\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\x20mcp\x20cursor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20配置\x20Cursor\x20的\x20MCP\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','3172472shzmrV','api','create','join','3157105PRWPJB','执行初始化配置命令','10411225NKIoSs','build','mcp','boolean','menu-sync','start','add-page','sync','menu','\x20(监听模式)','page','argv','执行启动命令','10NdjQIt','88QqxBhm','all','add','17178ObwXxk','env','slice','error','lovrabet\x20','exit','555SNDzWp','552YqvGWd','config','执行菜单同步命令','watch','trim','preview','input','appcode','init','string','cwd','setLogPath','11868ggqGHg','logs'];a22_0x3af1=function(){return _0xb02dc1;};return a22_0x3af1();}import{runBuild}from'./cmd/build.js';import{runPreview}from'./cmd/preview.js';import{runBuildWatch}from'./cmd/build-watch.js';import{Config}from'./config/main.js';import{apiCli}from'./api/main.js';import{AuthServer}from'./auth/auth-server-ui.js';import{logout}from'./auth/logout.js';import{Help}from'./help.js';import{logger}from'./utils/logger.js';import{showLogs,clearLogs}from'./cmd/logs.js';import{AppMenuSyncUI}from'./app-menu/app-menu-sync-ui.js';import{mcpCommand}from'./mcp/main.js';const cli=a22_0x8c19f3(a22_0x471fa4(0x169),{'importMeta':import.meta,'flags':{'name':{'type':a22_0x471fa4(0x15f)},'clear':{'type':'boolean'},'env':{'type':'string'},'watch':{'type':a22_0x471fa4(0x141)},'help':{'type':a22_0x471fa4(0x141)},'appcode':{'type':a22_0x471fa4(0x15f)},'output':{'type':'string'},'params':{'type':a22_0x471fa4(0x15f)},'datasetcode':{'type':a22_0x471fa4(0x15f)}}});await run();async function run(){const _0x501d5c=a22_0x471fa4,_0x1e550c=cli[_0x501d5c(0x15c)][0x0],_0x36124d=(_0x501d5c(0x153)+process[_0x501d5c(0x149)][_0x501d5c(0x151)](0x2)[_0x501d5c(0x16d)]('\x20'))[_0x501d5c(0x15a)]();logger['setRawCommand'](_0x36124d);switch(_0x1e550c){case _0x501d5c(0x15e):{const _0x4264a1=cli[_0x501d5c(0x168)][_0x501d5c(0x15d)],_0x305979=cli[_0x501d5c(0x168)][_0x501d5c(0x150)];logger['setLogPath'](process[_0x501d5c(0x160)]()),logger[_0x501d5c(0x165)]('init',_0x501d5c(0x16f)),render(a22_0x1b6e55(Init,{'appcode':_0x4264a1,'env':_0x305979}));break;}case _0x501d5c(0x16c):{const _0x10a5ed=cli[_0x501d5c(0x15c)][0x1]?.['trim'](),_0x49e0b6=cli[_0x501d5c(0x168)][_0x501d5c(0x150)];render(a22_0x1b6e55(CreateApp,{'projectCode':_0x10a5ed,'env':_0x49e0b6}));break;}case _0x501d5c(0x14e):{cli['input'][0x1]===_0x501d5c(0x148)&&(logger[_0x501d5c(0x161)](process[_0x501d5c(0x160)]()),logger['info'](_0x501d5c(0x144),'执行添加页面命令'),render(a22_0x1b6e55(AddPage,{})));break;}case'start':{try{logger['setLogPath'](process['cwd']()),logger['info'](_0x501d5c(0x143),_0x501d5c(0x14a)),await runStart();}catch(_0x28ed42){console['error'](_0x28ed42),process[_0x501d5c(0x154)](0x1);}break;}case _0x501d5c(0x13f):{try{logger[_0x501d5c(0x161)](process['cwd']()),logger['info'](_0x501d5c(0x13f),'执行构建命令'),await runBuild();}catch(_0x3c2203){console['error'](_0x3c2203),process['exit'](0x1);}break;}case _0x501d5c(0x15b):{const _0xf54a02=cli[_0x501d5c(0x168)][_0x501d5c(0x159)];logger[_0x501d5c(0x161)](process[_0x501d5c(0x160)]()),logger[_0x501d5c(0x165)](_0x501d5c(0x15b),'执行预览命令'+(_0xf54a02?_0x501d5c(0x147):''));if(_0xf54a02)try{await Promise[_0x501d5c(0x14d)]([runBuildWatch(),runPreview()]);}catch(_0x50e175){console[_0x501d5c(0x152)](_0x50e175),process['exit'](0x1);}else try{await runPreview();}catch(_0x5761f1){console['error'](_0x5761f1),process[_0x501d5c(0x154)](0x1);}break;}case _0x501d5c(0x157):{render(a22_0x1b6e55(Config,{'cli':cli}));break;}case _0x501d5c(0x16b):{await apiCli(cli);break;}case'auth':{render(a22_0x1b6e55(AuthServer,{}));break;}case _0x501d5c(0x146):{const _0x208be4=cli[_0x501d5c(0x15c)][0x1];_0x208be4===_0x501d5c(0x145)&&(logger[_0x501d5c(0x161)](process[_0x501d5c(0x160)]()),logger[_0x501d5c(0x165)](_0x501d5c(0x142),_0x501d5c(0x158)),render(a22_0x1b6e55(AppMenuSyncUI,{})));break;}case'logout':{logout();break;}case _0x501d5c(0x140):{const _0x15a4bd=cli['input'][0x1];await mcpCommand(_0x15a4bd);break;}case _0x501d5c(0x163):{cli['flags'][_0x501d5c(0x164)]?clearLogs():showLogs();break;}default:render(a22_0x1b6e55(Help,{}));break;}}
|
package/lib/cmd/build-watch.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2560e0,_0x12514b){const _0x2378fa=a23_0x5da7,_0x163205=_0x2560e0();while(!![]){try{const _0xa2b702=parseInt(_0x2378fa(0xd2))/0x1*(-parseInt(_0x2378fa(0xca))/0x2)+parseInt(_0x2378fa(0xcb))/0x3+parseInt(_0x2378fa(0xc4))/0x4*(parseInt(_0x2378fa(0xc8))/0x5)+parseInt(_0x2378fa(0xd1))/0x6*(-parseInt(_0x2378fa(0xc0))/0x7)+-parseInt(_0x2378fa(0xcd))/0x8*(parseInt(_0x2378fa(0xc7))/0x9)+parseInt(_0x2378fa(0xc1))/0xa+parseInt(_0x2378fa(0xd0))/0xb;if(_0xa2b702===_0x12514b)break;else _0x163205['push'](_0x163205['shift']());}catch(_0x44bb6b){_0x163205['push'](_0x163205['shift']());}}}(a23_0x14e5,0xaee75));function a23_0x5da7(_0x37d761,_0x38790f){const _0x14e551=a23_0x14e5();return a23_0x5da7=function(_0x5da75c,_0x28ec6f){_0x5da75c=_0x5da75c-0xc0;let _0x27a09e=_0x14e551[_0x5da75c];return _0x27a09e;},a23_0x5da7(_0x37d761,_0x38790f);}import{spawn}from'node:child_process';import{delimiter,join}from'node:path';function a23_0x14e5(){const _0x179094=['2370FjtjvR','2adDlyj','22393WpcPUC','13645980DwpeWI','inherit','--watch','20MwUuXc','build','node_modules','81HCxEuL','203495XpIzzP','vite','165058JXfoAY','1070415hrQuQc','.bin','284904TFJHGr','env','cwd','5947557vuCDzU'];a23_0x14e5=function(){return _0x179094;};return a23_0x14e5();}export function runBuildWatch(){return new Promise((_0x22bca0,_0x11f376)=>{const _0x30bb2e=a23_0x5da7,_0x1ffb4f=spawn(_0x30bb2e(0xc9),[_0x30bb2e(0xc5),_0x30bb2e(0xc3)],{'stdio':_0x30bb2e(0xc2),'shell':!![],'env':{...process[_0x30bb2e(0xce)],'PATH':''+join(process[_0x30bb2e(0xcf)](),_0x30bb2e(0xc6),_0x30bb2e(0xcc))+delimiter+process[_0x30bb2e(0xce)]['PATH']}});_0x1ffb4f['on']('close',_0x4ccb4d=>{if(_0x4ccb4d===0x0||_0x4ccb4d===null)_0x22bca0();else _0x11f376(new Error('npm\x20run\x20build\x20exited\x20with\x20code\x20'+_0x4ccb4d));}),_0x1ffb4f['on']('error',_0x11f376);});}
|
package/lib/cmd/build.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3d9212,_0x580fb9){const _0x2679a2=a24_0x1bf9,_0x374d55=_0x3d9212();while(!![]){try{const _0x1d7d51=-parseInt(_0x2679a2(0x197))/0x1+parseInt(_0x2679a2(0x18b))/0x2*(-parseInt(_0x2679a2(0x17c))/0x3)+-parseInt(_0x2679a2(0x17e))/0x4*(-parseInt(_0x2679a2(0x17d))/0x5)+parseInt(_0x2679a2(0x194))/0x6+-parseInt(_0x2679a2(0x17f))/0x7*(-parseInt(_0x2679a2(0x186))/0x8)+-parseInt(_0x2679a2(0x195))/0x9*(-parseInt(_0x2679a2(0x184))/0xa)+-parseInt(_0x2679a2(0x18f))/0xb*(parseInt(_0x2679a2(0x189))/0xc);if(_0x1d7d51===_0x580fb9)break;else _0x374d55['push'](_0x374d55['shift']());}catch(_0x3b72aa){_0x374d55['push'](_0x374d55['shift']());}}}(a24_0x3708,0x6d466));import{delimiter,join}from'node:path';function a24_0x1bf9(_0x50180a,_0x1c7067){const _0x37088d=a24_0x3708();return a24_0x1bf9=function(_0x1bf90a,_0x2ddfbd){_0x1bf90a=_0x1bf90a-0x179;let _0x1ed6ff=_0x37088d[_0x1bf90a];return _0x1ed6ff;},a24_0x1bf9(_0x50180a,_0x1c7067);}import{spawn}from'node:child_process';function a24_0x3708(){const _0x59a436=['stderr','inherit','98472aEnVUQ','项目构建失败','toString','info','data','5273436XUieyM','92835NCsTDZ','close','180280hvWiBD','build','npm','PATH','now','.bin','pipe','9QKYQbV','805nJImHm','476HzfvWg','28PrUcTJ','项目构建出错','message','npm\x20run\x20build\x20exited\x20with\x20code\x20','cwd','120LapRut','trim','1312968tgipLy','success','项目构建成功','528exgwss','env','437714TpTEUt','node_modules'];a24_0x3708=function(){return _0x59a436;};return a24_0x3708();}import{logger}from'../utils/logger.js';export function runBuild(){return new Promise((_0x52d221,_0x158349)=>{const _0x3b8da3=a24_0x1bf9,_0x1fbdcd=Date['now']();logger[_0x3b8da3(0x192)](_0x3b8da3(0x198),'开始构建项目',{'command':'npm\x20run\x20build'});let _0xe252dc='';const _0x4870b9=spawn(_0x3b8da3(0x199),['run',_0x3b8da3(0x198)],{'stdio':[_0x3b8da3(0x18e),'inherit',_0x3b8da3(0x17b)],'shell':!![],'env':{...process[_0x3b8da3(0x18a)],'PATH':''+join(process[_0x3b8da3(0x183)](),_0x3b8da3(0x18c),_0x3b8da3(0x17a))+delimiter+process[_0x3b8da3(0x18a)][_0x3b8da3(0x19a)]}});_0x4870b9['stderr']?.['on'](_0x3b8da3(0x193),_0x69ccf7=>{const _0x490d2d=_0x3b8da3;_0xe252dc+=_0x69ccf7[_0x490d2d(0x191)]();}),_0x4870b9['on'](_0x3b8da3(0x196),_0x4c6190=>{const _0x5d76f=_0x3b8da3,_0x2f232b=Date[_0x5d76f(0x179)]()-_0x1fbdcd;if(_0x4c6190===0x0||_0x4c6190===null)logger[_0x5d76f(0x187)](_0x5d76f(0x198),_0x5d76f(0x188),_0x2f232b),_0x52d221();else{const _0x14f574={'exitCode':_0x4c6190,'duration':_0x2f232b,'command':'npm\x20run\x20build','cwd':process[_0x5d76f(0x183)]()};_0xe252dc[_0x5d76f(0x185)]()&&(_0x14f574[_0x5d76f(0x18d)]=_0xe252dc[_0x5d76f(0x185)]()),logger['error']('build',_0x5d76f(0x190),_0x14f574),_0x158349(new Error(_0x5d76f(0x182)+_0x4c6190));}}),_0x4870b9['on']('error',_0x33f12b=>{const _0x435e8a=_0x3b8da3,_0x4d4465=Date[_0x435e8a(0x179)]()-_0x1fbdcd;logger['error'](_0x435e8a(0x198),_0x435e8a(0x180),{'error':_0x33f12b[_0x435e8a(0x181)],'duration':_0x4d4465,'stderr':_0xe252dc[_0x435e8a(0x185)]()||undefined}),_0x158349(_0x33f12b);});});}
|
package/lib/cmd/logs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a25_0x82dc(_0x3e4148,_0x3bf8f8){const _0x38c8d7=a25_0x38c8();return a25_0x82dc=function(_0x82dce3,_0x46cad1){_0x82dce3=_0x82dce3-0x116;let _0x2675e1=_0x38c8d7[_0x82dce3];return _0x2675e1;},a25_0x82dc(_0x3e4148,_0x3bf8f8);}(function(_0x159fef,_0x1e1730){const _0x2225cf=a25_0x82dc,_0x5030f1=_0x159fef();while(!![]){try{const _0x16ee68=-parseInt(_0x2225cf(0x119))/0x1+parseInt(_0x2225cf(0x131))/0x2*(-parseInt(_0x2225cf(0x121))/0x3)+-parseInt(_0x2225cf(0x118))/0x4*(-parseInt(_0x2225cf(0x117))/0x5)+parseInt(_0x2225cf(0x11f))/0x6*(parseInt(_0x2225cf(0x123))/0x7)+parseInt(_0x2225cf(0x120))/0x8*(parseInt(_0x2225cf(0x12a))/0x9)+-parseInt(_0x2225cf(0x134))/0xa*(parseInt(_0x2225cf(0x11a))/0xb)+parseInt(_0x2225cf(0x12e))/0xc;if(_0x16ee68===_0x1e1730)break;else _0x5030f1['push'](_0x5030f1['shift']());}catch(_0x41ef0f){_0x5030f1['push'](_0x5030f1['shift']());}}}(a25_0x38c8,0x28d0e));function a25_0x38c8(){const _0x3c3b30=['clearLogs','393327FXjIfj','\x20\x20\x20耗时:\x20','command','message','2205312QBzUVd','error','*\x20暂无日志记录','2nJIEUU','length','*\x20日志已清空','5210EgqqSh','log','timestamp','zh-CN','forEach','170OwKqPw','10696JqWuhG','172909uFPiIv','3223TCJMvS','\x20\x20\x20详情:\x20','toLocaleString','details','duration','24wsKOHy','24zEhVQP','148695RYeDQg','*\x20Lovrabet\x20CLI\x20日志记录:\x0a','238889DYmsHl','level','cwd','keys','warn','readLogs'];a25_0x38c8=function(){return _0x3c3b30;};return a25_0x38c8();}import{logger}from'../utils/logger.js';export function showLogs(){const _0x1b35cd=a25_0x82dc;logger['setLogPath'](process['cwd']());const _0x5bbabe=logger[_0x1b35cd(0x128)]();if(_0x5bbabe[_0x1b35cd(0x132)]===0x0){console[_0x1b35cd(0x135)](_0x1b35cd(0x130));return;}console[_0x1b35cd(0x135)](_0x1b35cd(0x122)),_0x5bbabe[_0x1b35cd(0x116)]((_0x132c8f,_0xaf244)=>{const _0x32273b=_0x1b35cd,_0x55480d=new Date(_0x132c8f[_0x32273b(0x136)])[_0x32273b(0x11c)](_0x32273b(0x137)),_0x3993e3=_0x132c8f[_0x32273b(0x124)]==='success'?'√':_0x132c8f[_0x32273b(0x124)]===_0x32273b(0x12f)?'×':_0x132c8f[_0x32273b(0x124)]===_0x32273b(0x127)?'!':'i';console['log'](_0xaf244+0x1+'.\x20'+_0x3993e3+'\x20['+_0x132c8f[_0x32273b(0x12c)]+']\x20'+_0x132c8f[_0x32273b(0x12d)]),console[_0x32273b(0x135)]('\x20\x20\x20时间:\x20'+_0x55480d),_0x132c8f[_0x32273b(0x11e)]&&console[_0x32273b(0x135)](_0x32273b(0x12b)+_0x132c8f[_0x32273b(0x11e)]+'ms'),_0x132c8f['details']&&Object[_0x32273b(0x126)](_0x132c8f[_0x32273b(0x11d)])[_0x32273b(0x132)]>0x0&&console[_0x32273b(0x135)](_0x32273b(0x11b)+JSON['stringify'](_0x132c8f[_0x32273b(0x11d)],null,0x2)),console['log']('');});}export function clearLogs(){const _0x5dda07=a25_0x82dc;logger['setLogPath'](process[_0x5dda07(0x125)]()),logger[_0x5dda07(0x129)](),console[_0x5dda07(0x135)](_0x5dda07(0x133));}
|
package/lib/cmd/preview.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4b34a1,_0x4ba062){const _0x15cbb4=a26_0x5107,_0x213472=_0x4b34a1();while(!![]){try{const _0x137ce9=parseInt(_0x15cbb4(0xe1))/0x1*(parseInt(_0x15cbb4(0xe0))/0x2)+parseInt(_0x15cbb4(0xe4))/0x3+parseInt(_0x15cbb4(0xdc))/0x4*(parseInt(_0x15cbb4(0xc2))/0x5)+-parseInt(_0x15cbb4(0xda))/0x6*(parseInt(_0x15cbb4(0xc8))/0x7)+parseInt(_0x15cbb4(0xd2))/0x8*(-parseInt(_0x15cbb4(0xc4))/0x9)+parseInt(_0x15cbb4(0xd1))/0xa*(-parseInt(_0x15cbb4(0xdd))/0xb)+-parseInt(_0x15cbb4(0xe5))/0xc*(parseInt(_0x15cbb4(0xd8))/0xd);if(_0x137ce9===_0x4ba062)break;else _0x213472['push'](_0x213472['shift']());}catch(_0xe6d6be){_0x213472['push'](_0x213472['shift']());}}}(a26_0x4e12,0xc7df3));import{delimiter,join}from'node:path';import{spawn}from'node:child_process';import{logger}from'../utils/logger.js';function a26_0x5107(_0x1bacdd,_0x200b0d){const _0x4e127b=a26_0x4e12();return a26_0x5107=function(_0x510732,_0x16ac95){_0x510732=_0x510732-0xc2;let _0x4abc28=_0x4e127b[_0x510732];return _0x4abc28;},a26_0x5107(_0x1bacdd,_0x200b0d);}export function runPreview(){return new Promise((_0x3b2183,_0xdfda31)=>{const _0x4eb88b=a26_0x5107,_0x1af1ac=Date[_0x4eb88b(0xe3)]();logger[_0x4eb88b(0xca)](_0x4eb88b(0xd5),_0x4eb88b(0xdf),{'command':_0x4eb88b(0xd4)});let _0x53ec4b='';const _0x149aad=spawn('vite',[_0x4eb88b(0xd5)],{'stdio':[_0x4eb88b(0xce),_0x4eb88b(0xce),_0x4eb88b(0xcf)],'shell':!![],'env':{...process['env'],'PATH':''+join(process[_0x4eb88b(0xc3)](),'node_modules',_0x4eb88b(0xcc))+delimiter+process[_0x4eb88b(0xdb)][_0x4eb88b(0xd0)]}});_0x149aad[_0x4eb88b(0xc9)]?.['on'](_0x4eb88b(0xcb),_0x4bee09=>{const _0x106987=_0x4eb88b;_0x53ec4b+=_0x4bee09[_0x106987(0xd3)]();}),_0x149aad['on'](_0x4eb88b(0xd6),_0x291b40=>{const _0x23723b=_0x4eb88b,_0x38d9d8=Date[_0x23723b(0xe3)]()-_0x1af1ac;if(_0x291b40===0x0||_0x291b40===null)logger[_0x23723b(0xc6)](_0x23723b(0xd5),_0x23723b(0xcd),_0x38d9d8),_0x3b2183();else{const _0x4194df={'exitCode':_0x291b40,'duration':_0x38d9d8,'command':'vite\x20preview','cwd':process[_0x23723b(0xc3)]()};_0x53ec4b[_0x23723b(0xd9)]()&&(_0x4194df[_0x23723b(0xc9)]=_0x53ec4b[_0x23723b(0xd9)]()),logger[_0x23723b(0xde)]('preview',_0x23723b(0xc7),_0x4194df),_0xdfda31(new Error(_0x23723b(0xe2)+_0x291b40));}}),_0x149aad['on'](_0x4eb88b(0xde),_0x48e63c=>{const _0x3c1a67=_0x4eb88b,_0x124a40=Date[_0x3c1a67(0xe3)]()-_0x1af1ac;logger['error'](_0x3c1a67(0xd5),_0x3c1a67(0xd7),{'error':_0x48e63c[_0x3c1a67(0xc5)],'duration':_0x124a40,'stderr':_0x53ec4b['trim']()||undefined}),_0xdfda31(_0x48e63c);});});}function a26_0x4e12(){const _0x4e0c9f=['stderr','info','data','.bin','预览服务器启动成功','inherit','pipe','PATH','597110xoDswf','60768EWRTqV','toString','vite\x20preview','preview','close','预览服务器启动出错','11187917OwUmhi','trim','1273362purrBj','env','114336eshPvi','143MIkgsP','error','启动预览服务器','50yTvDxA','44035XnxBUo','vite\x20preview\x20exited\x20with\x20code\x20','now','4380417NyHHgo','12TCwvJU','20KwIIcU','cwd','9guUPmj','message','success','预览服务器启动失败','7rCpvnZ'];a26_0x4e12=function(){return _0x4e0c9f;};return a26_0x4e12();}
|
package/lib/cmd/start.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x59f9ba,_0x320270){const _0x310122=a27_0x4671,_0x37fd07=_0x59f9ba();while(!![]){try{const _0x106929=parseInt(_0x310122(0x1ef))/0x1+parseInt(_0x310122(0x1ea))/0x2+parseInt(_0x310122(0x1cf))/0x3*(parseInt(_0x310122(0x1d8))/0x4)+-parseInt(_0x310122(0x1df))/0x5*(-parseInt(_0x310122(0x1d7))/0x6)+-parseInt(_0x310122(0x1d6))/0x7*(-parseInt(_0x310122(0x1d2))/0x8)+-parseInt(_0x310122(0x1eb))/0x9*(parseInt(_0x310122(0x1e1))/0xa)+-parseInt(_0x310122(0x1d9))/0xb;if(_0x106929===_0x320270)break;else _0x37fd07['push'](_0x37fd07['shift']());}catch(_0x42fde8){_0x37fd07['push'](_0x37fd07['shift']());}}}(a27_0x5431,0xa16ad));function a27_0x4671(_0x301d1a,_0x39d5ad){const _0x543153=a27_0x5431();return a27_0x4671=function(_0x467199,_0x4deeeb){_0x467199=_0x467199-0x1ce;let _0x320b82=_0x543153[_0x467199];return _0x320b82;},a27_0x4671(_0x301d1a,_0x39d5ad);}import{delimiter,join}from'node:path';import{spawn}from'node:child_process';function a27_0x5431(){const _0x48db79=['vite\x20exited\x20with\x20code\x20','toString','stderr','node_modules','412976KtNjiV','250659LyzblY','trim','.bin','pipe','328640wTKSSR','start','118512mSsCSU','message','开发服务器启动出错','632SCwawr','error','vite','data','105371ZfxEZb','3954suFYMW','20AApoqv','6333206UdapLP','启动开发服务器','开发服务器启动失败','success','cwd','PATH','4735zWTIlf','inherit','470muShHP','info','env','now','开发服务器启动成功'];a27_0x5431=function(){return _0x48db79;};return a27_0x5431();}import{logger}from'../utils/logger.js';export function runStart(_0x5520b8){return new Promise((_0xed2a72,_0xca1be1)=>{const _0x1370a8=a27_0x4671,_0x2382c7=Date[_0x1370a8(0x1e4)](),_0x1430c0=_0x5520b8||process[_0x1370a8(0x1dd)]();logger[_0x1370a8(0x1e2)](_0x1370a8(0x1ce),_0x1370a8(0x1da),{'command':_0x1370a8(0x1d4),'cwd':_0x1430c0});let _0x4a8bfb='';const _0x4ae952=spawn(_0x1370a8(0x1d4),{'stdio':[_0x1370a8(0x1e0),'inherit',_0x1370a8(0x1ee)],'shell':!![],'cwd':_0x1430c0,'env':{...process[_0x1370a8(0x1e3)],'PATH':''+join(_0x1430c0,_0x1370a8(0x1e9),_0x1370a8(0x1ed))+delimiter+process[_0x1370a8(0x1e3)][_0x1370a8(0x1de)]}});_0x4ae952[_0x1370a8(0x1e8)]?.['on'](_0x1370a8(0x1d5),_0x3c41cd=>{const _0x317f1d=_0x1370a8,_0x18f825=_0x3c41cd[_0x317f1d(0x1e7)]();_0x4a8bfb+=_0x18f825,process['stderr']['write'](_0x18f825);}),_0x4ae952['on']('close',_0xb53053=>{const _0x4e5eb8=_0x1370a8,_0x5be347=Date[_0x4e5eb8(0x1e4)]()-_0x2382c7;if(_0xb53053===0x0||_0xb53053===null)logger[_0x4e5eb8(0x1dc)](_0x4e5eb8(0x1ce),_0x4e5eb8(0x1e5),_0x5be347),_0xed2a72();else{const _0xf2e81={'exitCode':_0xb53053,'duration':_0x5be347,'command':_0x4e5eb8(0x1d4),'cwd':_0x1430c0};_0x4a8bfb[_0x4e5eb8(0x1ec)]()&&(_0xf2e81[_0x4e5eb8(0x1e8)]=_0x4a8bfb[_0x4e5eb8(0x1ec)]()),logger['error']('start',_0x4e5eb8(0x1db),_0xf2e81),_0xca1be1(new Error(_0x4e5eb8(0x1e6)+_0xb53053));}}),_0x4ae952['on'](_0x1370a8(0x1d3),_0x2f2aac=>{const _0xfbc29b=_0x1370a8,_0x3deb1c=Date[_0xfbc29b(0x1e4)]()-_0x2382c7,_0x29e15e={'error':_0x2f2aac[_0xfbc29b(0x1d0)],'duration':_0x3deb1c,'command':_0xfbc29b(0x1d4),'cwd':_0x1430c0};_0x4a8bfb[_0xfbc29b(0x1ec)]()&&(_0x29e15e[_0xfbc29b(0x1e8)]=_0x4a8bfb[_0xfbc29b(0x1ec)]()),logger[_0xfbc29b(0x1d3)]('start',_0xfbc29b(0x1d1),_0x29e15e),_0xca1be1(_0x2f2aac);});});}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x28721f,_0x24f8c1){const _0x553664=a28_0x1445,_0x4f69c4=_0x28721f();while(!![]){try{const _0x23c444=-parseInt(_0x553664(0x173))/0x1+-parseInt(_0x553664(0x17d))/0x2+parseInt(_0x553664(0x16c))/0x3*(-parseInt(_0x553664(0x177))/0x4)+parseInt(_0x553664(0x16e))/0x5+parseInt(_0x553664(0x170))/0x6*(parseInt(_0x553664(0x17b))/0x7)+-parseInt(_0x553664(0x17a))/0x8+parseInt(_0x553664(0x16b))/0x9;if(_0x23c444===_0x24f8c1)break;else _0x4f69c4['push'](_0x4f69c4['shift']());}catch(_0x31d508){_0x4f69c4['push'](_0x4f69c4['shift']());}}}(a28_0x3091,0x796a1));import{jsxs as a28_0x2e0d97,jsx as a28_0x1fe2b8}from'react/jsx-runtime';import{Box,Text}from'ink';function a28_0x3091(){const _0xbcbb0a=['5706288MICVEu','361165IFkdaA','gray','1573794UsxxZh','配置当前项目的\x20App\x20Code','14541795NdVsRP','3RwluBB','command','4014700BOFPDB','获取配置项','6YAPMaP','\x20*\x20配置示例:','lovrabet\x20config\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','406657lAbUiB','\x20\x20\x20\x20','lovrabet\x20config\x20get\x20<key>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','map','264548JTeVKo','列出所有配置项','设置配置项'];a28_0x3091=function(){return _0xbcbb0a;};return a28_0x3091();}function a28_0x1445(_0x3b2592,_0x26ddc1){const _0x3091b3=a28_0x3091();return a28_0x1445=function(_0x1445d8,_0x3f9df3){_0x1445d8=_0x1445d8-0x16a;let _0x2906cd=_0x3091b3[_0x1445d8];return _0x2906cd;},a28_0x1445(_0x3b2592,_0x26ddc1);}export function ConfigHelp(){const _0x47a0a4=a28_0x1445,_0x2e7932=[{'command':'lovrabet\x20config\x20set\x20<key>\x20<value>\x20\x20\x20','description':_0x47a0a4(0x179)},{'command':_0x47a0a4(0x175),'description':_0x47a0a4(0x16f)},{'command':_0x47a0a4(0x172),'description':_0x47a0a4(0x178)}],_0x14d875=[{'command':'lovrabet\x20config\x20set\x20app\x20app-xxxxx\x20\x20\x20','description':_0x47a0a4(0x16a)},{'command':'lovrabet\x20config\x20set\x20env\x20daily\x20\x20\x20\x20\x20\x20\x20','description':'设置环境\x20(online/daily)'}];return a28_0x2e0d97(Box,{'flexDirection':'column','marginTop':0x1,'marginBottom':0x1,'children':[a28_0x1fe2b8(Box,{'marginBottom':0x1,'children':a28_0x2e0d97(Text,{'color':_0x47a0a4(0x17c),'children':['\x20!','\x20\x20','无效的命令,可用命令如下:']})}),_0x2e7932[_0x47a0a4(0x176)](_0x301537=>a28_0x2e0d97(Box,{'children':[a28_0x2e0d97(Text,{'children':[_0x47a0a4(0x174),_0x301537[_0x47a0a4(0x16d)]]}),a28_0x1fe2b8(Text,{'color':_0x47a0a4(0x17c),'children':_0x301537['description']})]},_0x301537[_0x47a0a4(0x16d)])),a28_0x1fe2b8(Box,{'marginTop':0x1,'marginBottom':0x1,'children':a28_0x1fe2b8(Text,{'color':'gray','children':_0x47a0a4(0x171)})}),_0x14d875[_0x47a0a4(0x176)](_0x52ca2e=>a28_0x2e0d97(Box,{'children':[a28_0x2e0d97(Text,{'children':[_0x47a0a4(0x174),_0x52ca2e['command']]}),a28_0x1fe2b8(Text,{'color':_0x47a0a4(0x17c),'children':_0x52ca2e['description']})]},_0x52ca2e['command']))]});}
|
package/lib/config/main.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4afc88,_0x132bac){const _0x330780=a29_0x5362,_0x5e25d5=_0x4afc88();while(!![]){try{const _0x537aec=parseInt(_0x330780(0x178))/0x1+parseInt(_0x330780(0x16c))/0x2+parseInt(_0x330780(0x173))/0x3+parseInt(_0x330780(0x18d))/0x4*(-parseInt(_0x330780(0x17a))/0x5)+parseInt(_0x330780(0x17c))/0x6+parseInt(_0x330780(0x171))/0x7+-parseInt(_0x330780(0x189))/0x8;if(_0x537aec===_0x132bac)break;else _0x5e25d5['push'](_0x5e25d5['shift']());}catch(_0x1398e0){_0x5e25d5['push'](_0x5e25d5['shift']());}}}(a29_0x1e0e,0xbad49));import{jsx as a29_0x4e8dab,jsxs as a29_0x1a7d5f}from'react/jsx-runtime';import{existsSync,readFileSync,writeFileSync}from'node:fs';function a29_0x5362(_0x5764c8,_0x3d206c){const _0x1e0e55=a29_0x1e0e();return a29_0x5362=function(_0x536222,_0x265ba3){_0x536222=_0x536222-0x169;let _0xd5a205=_0x1e0e55[_0x536222];return _0xd5a205;},a29_0x5362(_0x5764c8,_0x3d206c);}import a29_0x23d8fe from'node:fs';import a29_0x1fe477 from'node:path';import{ConfigHelp}from'./config-help.js';function a29_0x1e0e(){const _0x33a4ff=['log','保存配置失败:\x20','error','8617200DxUuDG','list','appcode','length','144IrGioS','string','环境配置已设置为:\x20','env','includes','724508MGmQUm','unlinkSync','red','parse','保存配置失败','6797588PwfWXu','stringify','749247lAXIWb','daily','get','utf8','flags','133442WTsJzZ','--help','64250BPYvcB','input','3530868SswqKX','help','dirname','message','renameSync','undefined','online','app','set','未提供配置值'];a29_0x1e0e=function(){return _0x33a4ff;};return a29_0x1e0e();}import{Box,Text}from'ink';import{readConfig,isInProject,projectConfigPath,globalConfigPath}from'../utils/config.js';import{logger}from'../utils/logger.js';export function Config(_0x9b67a7){const _0x27615f=a29_0x5362,{cli:_0x2f831f}=_0x9b67a7,_0x4ea808=_0x2f831f['input'][0x1],_0x358b40=_0x2f831f['input'][0x2],_0xe6f2a1=[_0x27615f(0x184),_0x27615f(0x175)][_0x27615f(0x16b)](_0x4ea808||''),_0x4a0fb1=_0x2f831f['input'][_0x27615f(0x18c)]>=0x3;if(_0x358b40===_0x27615f(0x179)||_0x2f831f[_0x27615f(0x177)][_0x27615f(0x17d)])return a29_0x4e8dab(ConfigHelp,{});const _0x26b423=readConfig();if(_0x4ea808===_0x27615f(0x184)){if(_0x358b40){const _0x3c4964=_0x2f831f[_0x27615f(0x17b)][0x3];if(typeof _0x3c4964!==_0x27615f(0x181)){if(_0x358b40===_0x27615f(0x16a)&&![_0x27615f(0x182),_0x27615f(0x174)][_0x27615f(0x16b)](_0x3c4964))return a29_0x4e8dab(Box,{'children':a29_0x4e8dab(Text,{'color':_0x27615f(0x16e),'children':'环境配置值只能是\x20\x22online\x22\x20或\x20\x22daily\x22'})});const _0x45e85c=isInProject(),_0x2756e5=_0x45e85c?projectConfigPath:globalConfigPath;let _0x4b62fb={};try{if(existsSync(_0x2756e5)){const _0x29ce1b=readFileSync(_0x2756e5,{'encoding':_0x27615f(0x176)});_0x29ce1b&&(_0x4b62fb=JSON[_0x27615f(0x16f)](_0x29ce1b));}}catch(_0x15c7d5){}if(typeof _0x3c4964!==_0x27615f(0x18e)||_0x3c4964[_0x27615f(0x18c)]>0x1f4)return a29_0x4e8dab(Box,{'children':a29_0x4e8dab(Text,{'color':_0x27615f(0x16e),'children':'配置值无效或过长'})});let _0x238620=_0x358b40;_0x358b40===_0x27615f(0x183)&&(_0x238620=_0x27615f(0x18b),delete _0x4b62fb[_0x27615f(0x183)]);_0x358b40===_0x27615f(0x18b)&&delete _0x4b62fb[_0x27615f(0x183)];_0x4b62fb[_0x238620]=_0x3c4964;try{const _0x2028b0=a29_0x1fe477[_0x27615f(0x17e)](_0x2756e5);!existsSync(_0x2028b0)&&a29_0x23d8fe['mkdirSync'](_0x2028b0,{'recursive':!![]});const _0x1f1933=_0x2756e5+'.tmp';writeFileSync(_0x1f1933,JSON[_0x27615f(0x172)](_0x4b62fb,null,0x2),{'encoding':_0x27615f(0x176),'mode':0x180}),a29_0x23d8fe[_0x27615f(0x180)](_0x1f1933,_0x2756e5);if(_0x358b40===_0x27615f(0x16a)){const _0x50d57f=_0x45e85c?'项目':'全局';console[_0x27615f(0x186)]('✓\x20'+_0x50d57f+_0x27615f(0x169)+_0x3c4964);}}catch(_0x4b8661){const _0x341e9e=_0x2756e5+'.tmp';try{existsSync(_0x341e9e)&&a29_0x23d8fe[_0x27615f(0x16d)](_0x341e9e);}catch(_0x4d2b9b){}return logger[_0x27615f(0x188)]('config',_0x27615f(0x170),{'error':_0x4b8661 instanceof Error?_0x4b8661[_0x27615f(0x17f)]:String(_0x4b8661),'configKey':_0x358b40,'configValue':_0x3c4964,'targetConfigPath':_0x2756e5}),a29_0x4e8dab(Box,{'children':a29_0x1a7d5f(Text,{'color':'red','children':[_0x27615f(0x187),_0x4b8661 instanceof Error?_0x4b8661[_0x27615f(0x17f)]:String(_0x4b8661)]})});}return null;}return a29_0x4e8dab(Box,{'children':a29_0x4e8dab(Text,{'color':'red','children':_0x27615f(0x185)})});}}if(_0x4ea808===_0x27615f(0x175)){if(_0x358b40){let _0x113ca3=_0x358b40;return _0x358b40==='app'&&(_0x113ca3='appcode'),console[_0x27615f(0x186)](_0x26b423[_0x113ca3]||_0x27615f(0x181)),null;}return null;}if(_0x4ea808===_0x27615f(0x18a))return console[_0x27615f(0x186)](JSON[_0x27615f(0x172)](_0x26b423,null,0x2)),null;if(!_0xe6f2a1||!_0x4a0fb1)return a29_0x4e8dab(ConfigHelp,{});return null;}
|
package/lib/constant/domain.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a30_0x4892(_0x5e0e40,_0x4a8be2){const _0x1b4c92=a30_0x1b4c();return a30_0x4892=function(_0x489245,_0x5a4d65){_0x489245=_0x489245-0x13c;let _0x3035c2=_0x1b4c92[_0x489245];return _0x3035c2;},a30_0x4892(_0x5e0e40,_0x4a8be2);}const a30_0x3edadf=a30_0x4892;(function(_0x3b502d,_0xf86cca){const _0x272191=a30_0x4892,_0x60885f=_0x3b502d();while(!![]){try{const _0x9543ec=-parseInt(_0x272191(0x143))/0x1*(-parseInt(_0x272191(0x13c))/0x2)+-parseInt(_0x272191(0x141))/0x3+parseInt(_0x272191(0x14a))/0x4+-parseInt(_0x272191(0x148))/0x5+parseInt(_0x272191(0x145))/0x6*(parseInt(_0x272191(0x149))/0x7)+parseInt(_0x272191(0x144))/0x8*(parseInt(_0x272191(0x13d))/0x9)+-parseInt(_0x272191(0x142))/0xa;if(_0x9543ec===_0xf86cca)break;else _0x60885f['push'](_0x60885f['shift']());}catch(_0x255114){_0x60885f['push'](_0x60885f['shift']());}}}(a30_0x1b4c,0xd7be5));import{getEnv}from'./env.js';export const getUserDomain=()=>getEnv()===a30_0x3edadf(0x140)?a30_0x3edadf(0x13f):a30_0x3edadf(0x13e);function a30_0x1b4c(){const _0x2e48bf=['7944915lDlIqv','308hzFmDZ','3890412rWPkbg','28EmSMMv','1161YkJMVw','https://user-daily.lovrabet.com','https://user.lovrabet.com','online','772416qAycFR','1517680jhmGLs','29387apthYo','21720HdOYaR','156498LHNahJ','https://api.lovrabet.com','https://daily-api.lovrabet.com'];a30_0x1b4c=function(){return _0x2e48bf;};return a30_0x1b4c();}export const getApiDomain=()=>getEnv()===a30_0x3edadf(0x140)?a30_0x3edadf(0x146):a30_0x3edadf(0x147);
|
package/lib/constant/env.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a31_0x232876=a31_0x35a8;(function(_0x5c9f29,_0x53cb80){const _0x1380d2=a31_0x35a8,_0x2c4efb=_0x5c9f29();while(!![]){try{const _0x23f8bf=parseInt(_0x1380d2(0x149))/0x1*(parseInt(_0x1380d2(0x14a))/0x2)+parseInt(_0x1380d2(0x143))/0x3*(-parseInt(_0x1380d2(0x147))/0x4)+parseInt(_0x1380d2(0x148))/0x5+-parseInt(_0x1380d2(0x14c))/0x6+parseInt(_0x1380d2(0x14b))/0x7*(-parseInt(_0x1380d2(0x142))/0x8)+-parseInt(_0x1380d2(0x145))/0x9*(-parseInt(_0x1380d2(0x144))/0xa)+parseInt(_0x1380d2(0x146))/0xb;if(_0x23f8bf===_0x53cb80)break;else _0x2c4efb['push'](_0x2c4efb['shift']());}catch(_0x27bd5a){_0x2c4efb['push'](_0x2c4efb['shift']());}}}(a31_0x55a9,0x32e58));function a31_0x55a9(){const _0x3966d9=['54boGVIz','6312405HnxaoS','4WeRpsr','856315cDCpiK','487Affwjf','998dryOXP','47551IwWmVy','2110284GPICir','LOVRABET_ENV','online','408ZLKWoL','441012SVfEdv','109170GHyJhV'];a31_0x55a9=function(){return _0x3966d9;};return a31_0x55a9();}let env=process['env'][a31_0x232876(0x140)]||a31_0x232876(0x141);function a31_0x35a8(_0x33e43c,_0x2de2ab){const _0x55a931=a31_0x55a9();return a31_0x35a8=function(_0x35a86d,_0x398c66){_0x35a86d=_0x35a86d-0x140;let _0x3c93ad=_0x55a931[_0x35a86d];return _0x3c93ad;},a31_0x35a8(_0x33e43c,_0x2de2ab);}export function getEnv(){return env;}export function initEnv(_0x457733){env=_0x457733;}
|